diff --git a/pilot/scene/chat_data/chat_excel/excel_learning/prompt.py b/pilot/scene/chat_data/chat_excel/excel_learning/prompt.py index 205b9afba..d2d35b4c6 100644 --- a/pilot/scene/chat_data/chat_excel/excel_learning/prompt.py +++ b/pilot/scene/chat_data/chat_excel/excel_learning/prompt.py @@ -15,10 +15,11 @@ The following is part of the data of the user file {file_name}. Please learn to understand the structure and content of the data and output the parsing results as required: {data_example} Explain the meaning and function of each column, and give a simple and clear explanation of the technical terms, If it is a Date column, please summarize the Date format like: yyyy-MM-dd HH:MM:ss. +Use the column name as the attribute name and the analysis explanation as the attribute value to form a json array and output it in the ColumnAnalysis attribute that returns the json content. Please do not modify or translate the column names, make sure they are consistent with the given data column names. -Provide some analysis options,please think step by step. +Provide some useful analysis ideas to users from different dimensions for data. -Please return your answer in JSON format, the return format is as follows: +Please think step by step and give your answer. Make sure to answer only in JSON format,the format is as follows: {response} """ diff --git a/pilot/scene/chat_db/auto_execute/prompt.py b/pilot/scene/chat_db/auto_execute/prompt.py index 7aad683f5..3d7242624 100644 --- a/pilot/scene/chat_db/auto_execute/prompt.py +++ b/pilot/scene/chat_db/auto_execute/prompt.py @@ -20,10 +20,11 @@ {table_info} Constraint: - 1.Unless the user specifies in his question a specific number of examples he wishes to obtain, always limit your query to at most {top_k} results. - 2.Please do not use columns that do not appear in the tables schema. Also be careful not to misunderstand the relationship between fields and tables in SQL. - 3.Use as few tables as possible when querying. - 4.Please check the correctness of the SQL and ensure that the query performance is optimized under correct conditions. + 1.Please understand the user's intention based on the user's question, and use the given table structure definition to create a grammatically correct {dialect} sql. If sql is not required, answer the user's question directly.. + 2.Always limit the query to a maximum of {top_k} results unless the user specifies in the question the specific number of rows of data he wishes to obtain. + 3.You can only use the tables provided in the table structure information to generate sql. If you cannot generate sql based on the provided table structure, please say: "The table structure information provided is not enough to generate sql queries." It is prohibited to fabricate information at will. + 4.Please be careful not to mistake the relationship between tables and columns when generating SQL. + 5.Please check the correctness of the SQL and ensure that the query performance is optimized under correct conditions. User Question: {user_input} @@ -41,11 +42,11 @@ {table_info} 约束: - 1. 请理解用户意图根据用户输入问题,使用给出表结构定义创建一个语法正确的 {dialect} sql,如果不需要sql,则直接回答用户问题。 - 1. 除非用户在问题中指定了他希望获得的具体数据行数,否则始终将查询限制为最多 {top_k} 个结果。 - 2. 只能使用表结构信息中提供的表来生成 sql,如果无法根据提供的表结构中生成 sql ,请说:“提供的表结构信息不足以生成 sql 查询。” 禁止随意捏造信息。 - 3. 请注意生成SQL时不要弄错表和列的关系 - 4. 请检查SQL的正确性,并保证正确的情况下优化查询性能 + 1. 请根据用户问题理解用户意图,使用给出表结构定义创建一个语法正确的 {dialect} sql,如果不需要sql,则直接回答用户问题。 + 2. 除非用户在问题中指定了他希望获得的具体数据行数,否则始终将查询限制为最多 {top_k} 个结果。 + 3. 只能使用表结构信息中提供的表来生成 sql,如果无法根据提供的表结构中生成 sql ,请说:“提供的表结构信息不足以生成 sql 查询。” 禁止随意捏造信息。 + 4. 请注意生成SQL时不要弄错表和列的关系 + 5. 请检查SQL的正确性,并保证正确的情况下优化查询性能 用户问题: {user_input} 请一步步思考并按照以下JSON格式回复: diff --git a/pilot/server/static/404.html b/pilot/server/static/404.html index 27710ebef..eda6327dc 100644 --- a/pilot/server/static/404.html +++ b/pilot/server/static/404.html @@ -1 +1 @@ -404: This page could not be found

404

This page could not be found.

\ No newline at end of file +404: This page could not be found

404

This page could not be found.

\ No newline at end of file diff --git a/pilot/server/static/404/index.html b/pilot/server/static/404/index.html index 27710ebef..eda6327dc 100644 --- a/pilot/server/static/404/index.html +++ b/pilot/server/static/404/index.html @@ -1 +1 @@ -404: This page could not be found

404

This page could not be found.

\ No newline at end of file +404: This page could not be found

404

This page could not be found.

\ No newline at end of file diff --git a/pilot/server/static/_next/static/8DLUDtzfrUUv_4HYlGW9p/_buildManifest.js b/pilot/server/static/_next/static/2q-l6r8HvaIRu4wIDc1Eu/_buildManifest.js similarity index 56% rename from pilot/server/static/_next/static/8DLUDtzfrUUv_4HYlGW9p/_buildManifest.js rename to pilot/server/static/_next/static/2q-l6r8HvaIRu4wIDc1Eu/_buildManifest.js index 67f4ccd65..5313444ce 100644 --- a/pilot/server/static/_next/static/8DLUDtzfrUUv_4HYlGW9p/_buildManifest.js +++ b/pilot/server/static/_next/static/2q-l6r8HvaIRu4wIDc1Eu/_buildManifest.js @@ -1 +1 @@ -self.__BUILD_MANIFEST=function(s,c,a,e,t,d,n,k,b,h,f,i){return{__rewrites:{beforeFiles:[],afterFiles:[],fallback:[]},"/":["static/chunks/29107295-90b90cb30c825230.js",s,c,a,d,n,k,"static/chunks/539-dcd22f1f6b99ebee.js","static/chunks/pages/index-b1c8f59fe7e5d7df.js"],"/_error":["static/chunks/pages/_error-dee72aff9b2e2c12.js"],"/agent":[s,c,e,b,t,d,"static/chunks/pages/agent-762425b419303d9d.js"],"/chat":["static/chunks/pages/chat-12498cfa4a376095.js"],"/chat/[scene]/[id]":["static/chunks/pages/chat/[scene]/[id]-39a3901132926636.js"],"/database":[s,c,a,e,t,n,h,"static/chunks/643-d8f53f40dd3c5b40.js","static/chunks/pages/database-b4f32916b9d484a7.js"],"/knowledge":[f,s,c,e,b,t,d,n,"static/chunks/109-0dace28dd2667396.js","static/chunks/pages/knowledge-fbe0df9d6a60a0b5.js"],"/knowledge/chunk":[e,t,"static/chunks/pages/knowledge/chunk-765a4b202d79ac28.js"],"/models":[f,s,c,a,i,h,"static/chunks/pages/models-cb9ab490969e70dd.js"],"/prompt":[s,c,a,i,"static/chunks/837-e6d4d1eb9e057050.js",k,"static/chunks/607-b224c640f6907e4b.js","static/chunks/pages/prompt-7f839dfd56bc4c20.js"],sortedPages:["/","/_app","/_error","/agent","/chat","/chat/[scene]/[id]","/database","/knowledge","/knowledge/chunk","/models","/prompt"]}}("static/chunks/64-91b49d45b9846775.js","static/chunks/479-b20198841f9a6a1e.js","static/chunks/9-bb2c54d5c06ba4bf.js","static/chunks/442-197e6cbc1e54109a.js","static/chunks/813-cce9482e33f2430c.js","static/chunks/924-ba8e16df4d61ff5c.js","static/chunks/411-d9eba2657c72f766.js","static/chunks/270-2f094a936d056513.js","static/chunks/365-a224ec0807392b35.js","static/chunks/928-74244889bd7f2699.js","static/chunks/75fc9c18-a784766a129ec5fb.js","static/chunks/947-5980a3ff49069ddd.js"),self.__BUILD_MANIFEST_CB&&self.__BUILD_MANIFEST_CB(); \ No newline at end of file +self.__BUILD_MANIFEST=function(s,c,a,e,t,d,n,b,f,k,h,i){return{__rewrites:{beforeFiles:[],afterFiles:[],fallback:[]},"/":["static/chunks/29107295-90b90cb30c825230.js",s,c,a,d,n,b,"static/chunks/539-dcd22f1f6b99ebee.js","static/chunks/pages/index-b1c8f59fe7e5d7df.js"],"/_error":["static/chunks/pages/_error-dee72aff9b2e2c12.js"],"/agent":[s,c,e,f,t,d,"static/chunks/pages/agent-762425b419303d9d.js"],"/chat":["static/chunks/pages/chat-b1a399159cf29d92.js"],"/chat/[scene]/[id]":["static/chunks/pages/chat/[scene]/[id]-760bb41f43cab145.js"],"/database":[s,c,a,e,t,n,k,"static/chunks/643-d8f53f40dd3c5b40.js","static/chunks/pages/database-b4f32916b9d484a7.js"],"/knowledge":[h,s,c,e,f,t,d,n,"static/chunks/109-0dace28dd2667396.js","static/chunks/pages/knowledge-dc52dba3c1c37db4.js"],"/knowledge/chunk":[e,t,"static/chunks/pages/knowledge/chunk-765a4b202d79ac28.js"],"/models":[h,s,c,a,i,k,"static/chunks/pages/models-fa9ad76f43cc7a5f.js"],"/prompt":[s,c,a,i,"static/chunks/837-e6d4d1eb9e057050.js",b,"static/chunks/607-b224c640f6907e4b.js","static/chunks/pages/prompt-7f839dfd56bc4c20.js"],sortedPages:["/","/_app","/_error","/agent","/chat","/chat/[scene]/[id]","/database","/knowledge","/knowledge/chunk","/models","/prompt"]}}("static/chunks/64-91b49d45b9846775.js","static/chunks/479-b20198841f9a6a1e.js","static/chunks/9-bb2c54d5c06ba4bf.js","static/chunks/442-197e6cbc1e54109a.js","static/chunks/813-cce9482e33f2430c.js","static/chunks/924-ba8e16df4d61ff5c.js","static/chunks/411-d9eba2657c72f766.js","static/chunks/270-2f094a936d056513.js","static/chunks/365-a224ec0807392b35.js","static/chunks/928-74244889bd7f2699.js","static/chunks/75fc9c18-a784766a129ec5fb.js","static/chunks/947-5980a3ff49069ddd.js"),self.__BUILD_MANIFEST_CB&&self.__BUILD_MANIFEST_CB(); \ No newline at end of file diff --git a/pilot/server/static/_next/static/8DLUDtzfrUUv_4HYlGW9p/_ssgManifest.js b/pilot/server/static/_next/static/2q-l6r8HvaIRu4wIDc1Eu/_ssgManifest.js similarity index 100% rename from pilot/server/static/_next/static/8DLUDtzfrUUv_4HYlGW9p/_ssgManifest.js rename to pilot/server/static/_next/static/2q-l6r8HvaIRu4wIDc1Eu/_ssgManifest.js diff --git a/pilot/server/static/_next/static/chunks/355a6ca7.6a7668307202b4ab.js b/pilot/server/static/_next/static/chunks/355a6ca7.6a7668307202b4ab.js deleted file mode 100644 index 52e2a27e6..000000000 --- a/pilot/server/static/_next/static/chunks/355a6ca7.6a7668307202b4ab.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[34],{4559:function(t,e,n){n.d(e,{$6:function(){return j},$p:function(){return nK},Aw:function(){return rE},Cd:function(){return rQ},Cm:function(){return I},Dk:function(){return H},E9:function(){return tW},Ee:function(){return r5},F6:function(){return tC},G$:function(){return na},G0:function(){return nL},GL:function(){return U},GZ:function(){return rG},I8:function(){return tw},L1:function(){return nQ},N1:function(){return nx},NB:function(){return rb},O4:function(){return tL},Oi:function(){return nz},Pj:function(){return r1},R:function(){return eR},RV:function(){return rX},Rr:function(){return X},Rx:function(){return ex},UL:function(){return r7},V1:function(){return t$},Vl:function(){return tI},Xz:function(){return iv},YR:function(){return e9},ZA:function(){return r2},_O:function(){return tO},aH:function(){return r6},b_:function(){return r0},bn:function(){return M},gz:function(){return eK},h0:function(){return Y},iM:function(){return A},jU:function(){return nj},jd:function(){return rw},jf:function(){return tK},k9:function(){return r3},lu:function(){return eO},mN:function(){return tX},mg:function(){return r8},o6:function(){return eb},qA:function(){return eA},s$:function(){return rJ},ux:function(){return r$},x1:function(){return r4},xA:function(){return rv},xv:function(){return it},y$:function(){return r9}});var r,i,o,a,s,l,c,u,h,p,f,d,v,y,g,m,E,x,b,T,P,S,N,C,w,M,k,R,A,O,L,I,D,G,_,F,B,U,Z,V,Y,X,H,j,W=n(97582),z=n(54146),K=n(77160),q=n(85975),J=n(35600),$=n(98333),Q=n(32945),tt=n(31437),te=n(68797),tn=n(6393),tr=n(37377),ti=n(4663),to=n(53984),ta=n(72888),ts=n(58133),tl=n(26380),tc=n(76703),tu=n(25995),th=n(28024),tp=n(75066),tf=n(10353),td=n(49958),tv=n(49908),ty=n(8699),tg=n(88154),tm=n(63725),tE=n(72614),tx=n(36522),tb=n(80431),tT=n(33439),tP=n(73743),tS=("undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==n.g?n.g:"undefined"!=typeof self&&self,{exports:{}});tS.exports=function(){function t(t,e,n){var r=t[e];t[e]=t[n],t[n]=r}function e(t,e){return te?1:0}var n=function(t){void 0===t&&(t=9),this._maxEntries=Math.max(4,t),this._minEntries=Math.max(2,Math.ceil(.4*this._maxEntries)),this.clear()};function r(t,e){i(t,0,t.children.length,e,t)}function i(t,e,n,r,i){i||(i=p(null)),i.minX=1/0,i.minY=1/0,i.maxX=-1/0,i.maxY=-1/0;for(var a=e;a=t.minX&&e.maxY>=t.minY}function p(t){return{children:t,height:1,leaf:!0,minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0}}function f(n,r,i,o,a){for(var s=[r,i];s.length;)if(i=s.pop(),r=s.pop(),!(i-r<=o)){var l=r+Math.ceil((i-r)/o/2)*o;(function e(n,r,i,o,a){for(;o>i;){if(o-i>600){var s=o-i+1,l=r-i+1,c=Math.log(s),u=.5*Math.exp(2*c/3),h=.5*Math.sqrt(c*u*(s-u)/s)*(l-s/2<0?-1:1),p=Math.max(i,Math.floor(r-l*u/s+h)),f=Math.min(o,Math.floor(r+(s-l)*u/s+h));e(n,r,p,f,a)}var d=n[r],v=i,y=o;for(t(n,i,r),a(n[o],d)>0&&t(n,i,o);va(n[v],d);)v++;for(;a(n[y],d)>0;)y--}0===a(n[i],d)?t(n,i,y):t(n,++y,o),y<=r&&(i=y+1),r<=y&&(o=y-1)}})(n,l,r||0,i||n.length-1,a||e),s.push(r,l,l,i)}}return n.prototype.all=function(){return this._all(this.data,[])},n.prototype.search=function(t){var e=this.data,n=[];if(!h(t,e))return n;for(var r=this.toBBox,i=[];e;){for(var o=0;o=0;)if(i[e].children.length>this._maxEntries)this._split(i,e),e--;else break;this._adjustParentBBoxes(r,i,e)},n.prototype._split=function(t,e){var n=t[e],i=n.children.length,o=this._minEntries;this._chooseSplitAxis(n,o,i);var a=this._chooseSplitIndex(n,o,i),s=p(n.children.splice(a,n.children.length-a));s.height=n.height,s.leaf=n.leaf,r(n,this.toBBox),r(s,this.toBBox),e?t[e-1].children.push(s):this._splitRoot(n,s)},n.prototype._splitRoot=function(t,e){this.data=p([t,e]),this.data.height=t.height+1,this.data.leaf=!1,r(this.data,this.toBBox)},n.prototype._chooseSplitIndex=function(t,e,n){for(var r,o=1/0,a=1/0,s=e;s<=n-e;s++){var c=i(t,0,s,this.toBBox),u=i(t,s,n,this.toBBox),h=function(t,e){var n=Math.max(t.minX,e.minX),r=Math.max(t.minY,e.minY);return Math.max(0,Math.min(t.maxX,e.maxX)-n)*Math.max(0,Math.min(t.maxY,e.maxY)-r)}(c,u),p=l(c)+l(u);h=e;f--){var d=t.children[f];o(l,t.leaf?a(d):d),u+=c(l)}return u},n.prototype._adjustParentBBoxes=function(t,e,n){for(var r=n;r>=0;r--)o(e[r],t)},n.prototype._condense=function(t){for(var e=t.length-1,n=void 0;e>=0;e--)0===t[e].children.length?e>0?(n=t[e-1].children).splice(n.indexOf(t[e]),1):this.clear():r(t[e],this.toBBox)},n}();var tN=tS.exports;(r=M||(M={})).GROUP="g",r.CIRCLE="circle",r.ELLIPSE="ellipse",r.IMAGE="image",r.RECT="rect",r.LINE="line",r.POLYLINE="polyline",r.POLYGON="polygon",r.TEXT="text",r.PATH="path",r.HTML="html",r.MESH="mesh",(i=k||(k={}))[i.ZERO=0]="ZERO",i[i.NEGATIVE_ONE=1]="NEGATIVE_ONE";var tC=function(){function t(){this.plugins=[]}return t.prototype.addRenderingPlugin=function(t){this.plugins.push(t),this.context.renderingPlugins.push(t)},t.prototype.removeAllRenderingPlugins=function(){var t=this;this.plugins.forEach(function(e){var n=t.context.renderingPlugins.indexOf(e);n>=0&&t.context.renderingPlugins.splice(n,1)})},t}(),tw=function(){function t(t){this.clipSpaceNearZ=k.NEGATIVE_ONE,this.plugins=[],this.config=(0,W.pi)({enableDirtyCheck:!0,enableCulling:!1,enableAutoRendering:!0,enableDirtyRectangleRendering:!0,enableDirtyRectangleRenderingDebug:!1},t)}return t.prototype.registerPlugin=function(t){-1===this.plugins.findIndex(function(e){return e===t})&&this.plugins.push(t)},t.prototype.unregisterPlugin=function(t){var e=this.plugins.findIndex(function(e){return e===t});e>-1&&this.plugins.splice(e,1)},t.prototype.getPlugins=function(){return this.plugins},t.prototype.getPlugin=function(t){return this.plugins.find(function(e){return e.name===t})},t.prototype.getConfig=function(){return this.config},t.prototype.setConfig=function(t){Object.assign(this.config,t)},t}();function tM(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t}function tk(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t[2]=e[2]-n[2],t}function tR(t,e,n){return t[0]=e[0]+n[0],t[1]=e[1]+n[1],t[2]=e[2]+n[2],t}function tA(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t[2]=e[2]*n,t}function tO(t){return void 0===t?0:t>360||t<-360?t%360:t}function tL(t,e,n){return(void 0===e&&(e=0),void 0===n&&(n=0),Array.isArray(t)&&3===t.length)?K.d9(t):(0,te.Z)(t)?K.al(t,e,n):K.al(t[0],t[1]||e,t[2]||n)}function tI(t){return t*(Math.PI/180)}function tD(t){return t*(180/Math.PI)}function tG(t,e){var n,r,i,o,a,s,l,c,u,h,p,f,d,v,y,g,m;return 16===e.length?(i=.5*Math.PI,a=(o=(0,W.CR)(q.getScaling(K.Ue(),e),3))[0],s=o[1],l=o[2],(c=Math.asin(-e[2]/a))-i?(n=Math.atan2(e[6]/s,e[10]/l),r=Math.atan2(e[1]/a,e[0]/a)):(r=0,n=-Math.atan2(e[4]/s,e[5]/s)):(r=0,n=Math.atan2(e[4]/s,e[5]/s)),t[0]=n,t[1]=c,t[2]=r,t):(u=e[0],h=e[1],p=e[2],f=e[3],g=u*u+(d=h*h)+(v=p*p)+(y=f*f),(m=u*f-h*p)>.499995*g?(t[0]=Math.PI/2,t[1]=2*Math.atan2(h,u),t[2]=0):m<-.499995*g?(t[0]=-Math.PI/2,t[1]=2*Math.atan2(h,u),t[2]=0):(t[0]=Math.asin(2*(u*p-f*h)),t[1]=Math.atan2(2*(u*f+h*p),1-2*(v+y)),t[2]=Math.atan2(2*(u*h+p*f),1-2*(d+v))),t)}function t_(t){var e=t[0],n=t[1],r=t[3],i=t[4],o=Math.sqrt(e*e+n*n),a=Math.sqrt(r*r+i*i);e*i-n*r<0&&(eh&&(h=N),Cf&&(f=w),Mv&&(v=k),n[0]=(u+h)*.5,n[1]=(p+f)*.5,n[2]=(d+v)*.5,a[0]=(h-u)*.5,a[1]=(f-p)*.5,a[2]=(v-d)*.5,this.min[0]=u,this.min[1]=p,this.min[2]=d,this.max[0]=h,this.max[1]=f,this.max[2]=v}},t.prototype.setFromTransformedAABB=function(t,e){var n=this.center,r=this.halfExtents,i=t.center,o=t.halfExtents,a=e[0],s=e[4],l=e[8],c=e[1],u=e[5],h=e[9],p=e[2],f=e[6],d=e[10],v=Math.abs(a),y=Math.abs(s),g=Math.abs(l),m=Math.abs(c),E=Math.abs(u),x=Math.abs(h),b=Math.abs(p),T=Math.abs(f),P=Math.abs(d);n[0]=e[12]+a*i[0]+s*i[1]+l*i[2],n[1]=e[13]+c*i[0]+u*i[1]+h*i[2],n[2]=e[14]+p*i[0]+f*i[1]+d*i[2],r[0]=v*o[0]+y*o[1]+g*o[2],r[1]=m*o[0]+E*o[1]+x*o[2],r[2]=b*o[0]+T*o[1]+P*o[2],tk(this.min,n,r),tR(this.max,n,r)},t.prototype.intersects=function(t){var e=this.getMax(),n=this.getMin(),r=t.getMax(),i=t.getMin();return n[0]<=r[0]&&e[0]>=i[0]&&n[1]<=r[1]&&e[1]>=i[1]&&n[2]<=r[2]&&e[2]>=i[2]},t.prototype.intersection=function(e){if(!this.intersects(e))return null;var n,r,i,o,a,s,l=new t,c=(n=[0,0,0],r=this.getMin(),i=e.getMin(),n[0]=Math.max(r[0],i[0]),n[1]=Math.max(r[1],i[1]),n[2]=Math.max(r[2],i[2]),n),u=(o=[0,0,0],a=this.getMax(),s=e.getMax(),o[0]=Math.min(a[0],s[0]),o[1]=Math.min(a[1],s[1]),o[2]=Math.min(a[2],s[2]),o);return l.setMinMax(c,u),l},t.prototype.getNegativeFarPoint=function(t){if(273===t.pnVertexFlag)return tM([0,0,0],this.min);if(272===t.pnVertexFlag)return[this.min[0],this.min[1],this.max[2]];if(257===t.pnVertexFlag)return[this.min[0],this.max[1],this.min[2]];if(256===t.pnVertexFlag)return[this.min[0],this.max[1],this.max[2]];if(17===t.pnVertexFlag)return[this.max[0],this.min[1],this.min[2]];if(16===t.pnVertexFlag)return[this.max[0],this.min[1],this.max[2]];if(1===t.pnVertexFlag)return[this.max[0],this.max[1],this.min[2]];else return[this.max[0],this.max[1],this.max[2]]},t.prototype.getPositiveFarPoint=function(t){if(273===t.pnVertexFlag)return tM([0,0,0],this.max);if(272===t.pnVertexFlag)return[this.max[0],this.max[1],this.min[2]];if(257===t.pnVertexFlag)return[this.max[0],this.min[1],this.max[2]];if(256===t.pnVertexFlag)return[this.max[0],this.min[1],this.min[2]];if(17===t.pnVertexFlag)return[this.min[0],this.max[1],this.max[2]];if(16===t.pnVertexFlag)return[this.min[0],this.max[1],this.min[2]];if(1===t.pnVertexFlag)return[this.min[0],this.min[1],this.max[2]];else return[this.min[0],this.min[1],this.min[2]]},t}(),tH=function(){function t(t,e){this.distance=t||0,this.normal=e||K.al(0,1,0),this.updatePNVertexFlag()}return t.prototype.updatePNVertexFlag=function(){this.pnVertexFlag=(Number(this.normal[0]>=0)<<8)+(Number(this.normal[1]>=0)<<4)+Number(this.normal[2]>=0)},t.prototype.distanceToPoint=function(t){return K.AK(t,this.normal)-this.distance},t.prototype.normalize=function(){var t=1/K.Zh(this.normal);K.bA(this.normal,this.normal,t),this.distance*=t},t.prototype.intersectsLine=function(t,e,n){var r=this.distanceToPoint(t),i=r/(r-this.distanceToPoint(e)),o=i>=0&&i<=1;return o&&n&&K.t7(n,t,e,i),o},t}();(o=R||(R={}))[o.OUTSIDE=4294967295]="OUTSIDE",o[o.INSIDE=0]="INSIDE",o[o.INDETERMINATE=2147483647]="INDETERMINATE";var tj=function(){function t(t){if(this.planes=[],t)this.planes=t;else for(var e=0;e<6;e++)this.planes.push(new tH)}return t.prototype.extractFromVPMatrix=function(t){var e=(0,W.CR)(t,16),n=e[0],r=e[1],i=e[2],o=e[3],a=e[4],s=e[5],l=e[6],c=e[7],u=e[8],h=e[9],p=e[10],f=e[11],d=e[12],v=e[13],y=e[14],g=e[15];K.t8(this.planes[0].normal,o-n,c-a,f-u),this.planes[0].distance=g-d,K.t8(this.planes[1].normal,o+n,c+a,f+u),this.planes[1].distance=g+d,K.t8(this.planes[2].normal,o+r,c+s,f+h),this.planes[2].distance=g+v,K.t8(this.planes[3].normal,o-r,c-s,f-h),this.planes[3].distance=g-v,K.t8(this.planes[4].normal,o-i,c-l,f-p),this.planes[4].distance=g-y,K.t8(this.planes[5].normal,o+i,c+l,f+p),this.planes[5].distance=g+y,this.planes.forEach(function(t){t.normalize(),t.updatePNVertexFlag()})},t}(),tW=function(){function t(t,e){void 0===t&&(t=0),void 0===e&&(e=0),this.x=0,this.y=0,this.x=t,this.y=e}return t.prototype.clone=function(){return new t(this.x,this.y)},t.prototype.copyFrom=function(t){this.x=t.x,this.y=t.y},t}(),tz=function(){function t(t,e,n,r){this.x=t,this.y=e,this.width=n,this.height=r,this.left=t,this.right=t+n,this.top=e,this.bottom=e+r}return t.prototype.toJSON=function(){},t}(),tK="Method not implemented.",tq="Use document.documentElement instead.";(a=A||(A={}))[a.ORBITING=0]="ORBITING",a[a.EXPLORING=1]="EXPLORING",a[a.TRACKING=2]="TRACKING",(s=O||(O={}))[s.DEFAULT=0]="DEFAULT",s[s.ROTATIONAL=1]="ROTATIONAL",s[s.TRANSLATIONAL=2]="TRANSLATIONAL",s[s.CINEMATIC=3]="CINEMATIC",(l=L||(L={}))[l.ORTHOGRAPHIC=0]="ORTHOGRAPHIC",l[l.PERSPECTIVE=1]="PERSPECTIVE";var tJ={UPDATED:"updated"},t$=function(){function t(){this.clipSpaceNearZ=k.NEGATIVE_ONE,this.eventEmitter=new z.Z,this.matrix=q.create(),this.right=K.al(1,0,0),this.up=K.al(0,1,0),this.forward=K.al(0,0,1),this.position=K.al(0,0,1),this.focalPoint=K.al(0,0,0),this.distanceVector=K.al(0,0,-1),this.distance=1,this.azimuth=0,this.elevation=0,this.roll=0,this.relAzimuth=0,this.relElevation=0,this.relRoll=0,this.dollyingStep=0,this.maxDistance=1/0,this.minDistance=-1/0,this.zoom=1,this.rotateWorld=!1,this.fov=30,this.near=.1,this.far=1e3,this.aspect=1,this.projectionMatrix=q.create(),this.projectionMatrixInverse=q.create(),this.jitteredProjectionMatrix=void 0,this.enableUpdate=!0,this.type=A.EXPLORING,this.trackingMode=O.DEFAULT,this.projectionMode=L.PERSPECTIVE,this.frustum=new tj,this.orthoMatrix=q.create()}return t.prototype.isOrtho=function(){return this.projectionMode===L.ORTHOGRAPHIC},t.prototype.getProjectionMode=function(){return this.projectionMode},t.prototype.getPerspective=function(){return this.jitteredProjectionMatrix||this.projectionMatrix},t.prototype.getPerspectiveInverse=function(){return this.projectionMatrixInverse},t.prototype.getFrustum=function(){return this.frustum},t.prototype.getPosition=function(){return this.position},t.prototype.getFocalPoint=function(){return this.focalPoint},t.prototype.getDollyingStep=function(){return this.dollyingStep},t.prototype.getNear=function(){return this.near},t.prototype.getFar=function(){return this.far},t.prototype.getZoom=function(){return this.zoom},t.prototype.getOrthoMatrix=function(){return this.orthoMatrix},t.prototype.getView=function(){return this.view},t.prototype.setEnableUpdate=function(t){this.enableUpdate=t},t.prototype.setType=function(t,e){return this.type=t,this.type===A.EXPLORING?this.setWorldRotation(!0):this.setWorldRotation(!1),this._getAngles(),this.type===A.TRACKING&&void 0!==e&&this.setTrackingMode(e),this},t.prototype.setProjectionMode=function(t){return this.projectionMode=t,this},t.prototype.setTrackingMode=function(t){if(this.type!==A.TRACKING)throw Error("Impossible to set a tracking mode if the camera is not of tracking type");return this.trackingMode=t,this},t.prototype.setWorldRotation=function(t){return this.rotateWorld=t,this._getAngles(),this},t.prototype.getViewTransform=function(){return q.invert(q.create(),this.matrix)},t.prototype.getWorldTransform=function(){return this.matrix},t.prototype.jitterProjectionMatrix=function(t,e){var n=q.fromTranslation(q.create(),[t,e,0]);this.jitteredProjectionMatrix=q.multiply(q.create(),n,this.projectionMatrix)},t.prototype.clearJitterProjectionMatrix=function(){this.jitteredProjectionMatrix=void 0},t.prototype.setMatrix=function(t){return this.matrix=t,this._update(),this},t.prototype.setFov=function(t){return this.setPerspective(this.near,this.far,t,this.aspect),this},t.prototype.setAspect=function(t){return this.setPerspective(this.near,this.far,this.fov,t),this},t.prototype.setNear=function(t){return this.projectionMode===L.PERSPECTIVE?this.setPerspective(t,this.far,this.fov,this.aspect):this.setOrthographic(this.left,this.rright,this.top,this.bottom,t,this.far),this},t.prototype.setFar=function(t){return this.projectionMode===L.PERSPECTIVE?this.setPerspective(this.near,t,this.fov,this.aspect):this.setOrthographic(this.left,this.rright,this.top,this.bottom,this.near,t),this},t.prototype.setViewOffset=function(t,e,n,r,i,o){return this.aspect=t/e,void 0===this.view&&(this.view={enabled:!0,fullWidth:1,fullHeight:1,offsetX:0,offsetY:0,width:1,height:1}),this.view.enabled=!0,this.view.fullWidth=t,this.view.fullHeight=e,this.view.offsetX=n,this.view.offsetY=r,this.view.width=i,this.view.height=o,this.projectionMode===L.PERSPECTIVE?this.setPerspective(this.near,this.far,this.fov,this.aspect):this.setOrthographic(this.left,this.rright,this.top,this.bottom,this.near,this.far),this},t.prototype.clearViewOffset=function(){return void 0!==this.view&&(this.view.enabled=!1),this.projectionMode===L.PERSPECTIVE?this.setPerspective(this.near,this.far,this.fov,this.aspect):this.setOrthographic(this.left,this.rright,this.top,this.bottom,this.near,this.far),this},t.prototype.setZoom=function(t){return this.zoom=t,this.projectionMode===L.ORTHOGRAPHIC?this.setOrthographic(this.left,this.rright,this.top,this.bottom,this.near,this.far):this.projectionMode===L.PERSPECTIVE&&this.setPerspective(this.near,this.far,this.fov,this.aspect),this},t.prototype.setZoomByViewportPoint=function(t,e){var n=this.canvas.viewport2Canvas({x:e[0],y:e[1]}),r=n.x,i=n.y,o=this.roll;this.rotate(0,0,-o),this.setPosition(r,i),this.setFocalPoint(r,i),this.setZoom(t),this.rotate(0,0,o);var a=this.canvas.viewport2Canvas({x:e[0],y:e[1]}),s=a.x,l=a.y,c=K.al(s-r,l-i,0),u=K.AK(c,this.right)/K.kE(this.right),h=K.AK(c,this.up)/K.kE(this.up);return this.pan(-u,-h),this},t.prototype.setPerspective=function(t,e,n,r){this.projectionMode=L.PERSPECTIVE,this.fov=n,this.near=t,this.far=e,this.aspect=r;var i,o,a,s,l,c,u,h,p,f=this.near*Math.tan(tI(.5*this.fov))/this.zoom,d=2*f,v=this.aspect*d,y=-.5*v;if(null===(p=this.view)||void 0===p?void 0:p.enabled){var g=this.view.fullWidth,m=this.view.fullHeight;y+=this.view.offsetX*v/g,f-=this.view.offsetY*d/m,v*=this.view.width/g,d*=this.view.height/m}return i=this.projectionMatrix,o=y,a=y+v,s=f,l=f-d,c=this.far,this.clipSpaceNearZ===k.ZERO?(u=-c/(c-t),h=-c*t/(c-t)):(u=-(c+t)/(c-t),h=-2*c*t/(c-t)),i[0]=2*t/(a-o),i[1]=0,i[2]=0,i[3]=0,i[4]=0,i[5]=2*t/(s-l),i[6]=0,i[7]=0,i[8]=(a+o)/(a-o),i[9]=(s+l)/(s-l),i[10]=u,i[11]=-1,i[12]=0,i[13]=0,i[14]=h,i[15]=0,q.scale(this.projectionMatrix,this.projectionMatrix,K.al(1,-1,1)),q.invert(this.projectionMatrixInverse,this.projectionMatrix),this.triggerUpdate(),this},t.prototype.setOrthographic=function(t,e,n,r,i,o){this.projectionMode=L.ORTHOGRAPHIC,this.rright=e,this.left=t,this.top=n,this.bottom=r,this.near=i,this.far=o;var a,s=(this.rright-this.left)/(2*this.zoom),l=(this.top-this.bottom)/(2*this.zoom),c=(this.rright+this.left)/2,u=(this.top+this.bottom)/2,h=c-s,p=c+s,f=u+l,d=u-l;if(null===(a=this.view)||void 0===a?void 0:a.enabled){var v=(this.rright-this.left)/this.view.fullWidth/this.zoom,y=(this.top-this.bottom)/this.view.fullHeight/this.zoom;h+=v*this.view.offsetX,p=h+v*this.view.width,f-=y*this.view.offsetY,d=f-y*this.view.height}return this.clipSpaceNearZ===k.NEGATIVE_ONE?q.ortho(this.projectionMatrix,h,p,d,f,i,o):q.orthoZO(this.projectionMatrix,h,p,d,f,i,o),q.scale(this.projectionMatrix,this.projectionMatrix,K.al(1,-1,1)),q.invert(this.projectionMatrixInverse,this.projectionMatrix),this._getOrthoMatrix(),this.triggerUpdate(),this},t.prototype.setPosition=function(t,e,n){void 0===e&&(e=this.position[1]),void 0===n&&(n=this.position[2]);var r=tL(t,e,n);return this._setPosition(r),this.setFocalPoint(this.focalPoint),this.triggerUpdate(),this},t.prototype.setFocalPoint=function(t,e,n){void 0===e&&(e=this.focalPoint[1]),void 0===n&&(n=this.focalPoint[2]);var r=K.al(0,1,0);if(this.focalPoint=tL(t,e,n),this.trackingMode===O.CINEMATIC){var i=K.$X(K.Ue(),this.focalPoint,this.position);t=i[0],e=i[1],n=i[2];var o=tD(Math.asin(e/K.kE(i))),a=90+tD(Math.atan2(n,t)),s=q.create();q.rotateY(s,s,tI(a)),q.rotateX(s,s,tI(o)),r=K.fF(K.Ue(),[0,1,0],s)}return q.invert(this.matrix,q.lookAt(q.create(),this.position,this.focalPoint,r)),this._getAxes(),this._getDistance(),this._getAngles(),this.triggerUpdate(),this},t.prototype.getDistance=function(){return this.distance},t.prototype.getDistanceVector=function(){return this.distanceVector},t.prototype.setDistance=function(t){if(this.distance===t||t<0)return this;this.distance=t,this.distance<2e-4&&(this.distance=2e-4),this.dollyingStep=this.distance/100;var e=K.Ue();t=this.distance;var n=this.forward,r=this.focalPoint;return e[0]=t*n[0]+r[0],e[1]=t*n[1]+r[1],e[2]=t*n[2]+r[2],this._setPosition(e),this.triggerUpdate(),this},t.prototype.setMaxDistance=function(t){return this.maxDistance=t,this},t.prototype.setMinDistance=function(t){return this.minDistance=t,this},t.prototype.setAzimuth=function(t){return this.azimuth=tO(t),this.computeMatrix(),this._getAxes(),this.type===A.ORBITING||this.type===A.EXPLORING?this._getPosition():this.type===A.TRACKING&&this._getFocalPoint(),this.triggerUpdate(),this},t.prototype.getAzimuth=function(){return this.azimuth},t.prototype.setElevation=function(t){return this.elevation=tO(t),this.computeMatrix(),this._getAxes(),this.type===A.ORBITING||this.type===A.EXPLORING?this._getPosition():this.type===A.TRACKING&&this._getFocalPoint(),this.triggerUpdate(),this},t.prototype.getElevation=function(){return this.elevation},t.prototype.setRoll=function(t){return this.roll=tO(t),this.computeMatrix(),this._getAxes(),this.type===A.ORBITING||this.type===A.EXPLORING?this._getPosition():this.type===A.TRACKING&&this._getFocalPoint(),this.triggerUpdate(),this},t.prototype.getRoll=function(){return this.roll},t.prototype._update=function(){this._getAxes(),this._getPosition(),this._getDistance(),this._getAngles(),this._getOrthoMatrix(),this.triggerUpdate()},t.prototype.computeMatrix=function(){var t=Q.yY(Q.Ue(),[0,0,1],tI(this.roll));q.identity(this.matrix);var e=Q.yY(Q.Ue(),[1,0,0],tI((this.rotateWorld&&this.type!==A.TRACKING||this.type===A.TRACKING?1:-1)*this.elevation)),n=Q.yY(Q.Ue(),[0,1,0],tI((this.rotateWorld&&this.type!==A.TRACKING||this.type===A.TRACKING?1:-1)*this.azimuth)),r=Q.Jp(Q.Ue(),n,e);r=Q.Jp(Q.Ue(),r,t);var i=q.fromQuat(q.create(),r);this.type===A.ORBITING||this.type===A.EXPLORING?(q.translate(this.matrix,this.matrix,this.focalPoint),q.multiply(this.matrix,this.matrix,i),q.translate(this.matrix,this.matrix,[0,0,this.distance])):this.type===A.TRACKING&&(q.translate(this.matrix,this.matrix,this.position),q.multiply(this.matrix,this.matrix,i))},t.prototype._setPosition=function(t,e,n){this.position=tL(t,e,n);var r=this.matrix;r[12]=this.position[0],r[13]=this.position[1],r[14]=this.position[2],r[15]=1,this._getOrthoMatrix()},t.prototype._getAxes=function(){K.JG(this.right,tL($.fF($.Ue(),[1,0,0,0],this.matrix))),K.JG(this.up,tL($.fF($.Ue(),[0,1,0,0],this.matrix))),K.JG(this.forward,tL($.fF($.Ue(),[0,0,1,0],this.matrix))),K.Fv(this.right,this.right),K.Fv(this.up,this.up),K.Fv(this.forward,this.forward)},t.prototype._getAngles=function(){var t=this.distanceVector[0],e=this.distanceVector[1],n=this.distanceVector[2],r=K.kE(this.distanceVector);if(0===r){this.elevation=0,this.azimuth=0;return}this.type===A.TRACKING?(this.elevation=tD(Math.asin(e/r)),this.azimuth=tD(Math.atan2(-t,-n))):this.rotateWorld?(this.elevation=tD(Math.asin(e/r)),this.azimuth=tD(Math.atan2(-t,-n))):(this.elevation=-tD(Math.asin(e/r)),this.azimuth=-tD(Math.atan2(-t,-n)))},t.prototype._getPosition=function(){K.JG(this.position,tL($.fF($.Ue(),[0,0,0,1],this.matrix))),this._getDistance()},t.prototype._getFocalPoint=function(){K.kK(this.distanceVector,[0,0,-this.distance],J.xO(J.Ue(),this.matrix)),K.IH(this.focalPoint,this.position,this.distanceVector),this._getDistance()},t.prototype._getDistance=function(){this.distanceVector=K.$X(K.Ue(),this.focalPoint,this.position),this.distance=K.kE(this.distanceVector),this.dollyingStep=this.distance/100},t.prototype._getOrthoMatrix=function(){if(this.projectionMode===L.ORTHOGRAPHIC){var t=this.position,e=Q.yY(Q.Ue(),[0,0,1],-this.roll*Math.PI/180);q.fromRotationTranslationScaleOrigin(this.orthoMatrix,e,K.al((this.rright-this.left)/2-t[0],(this.top-this.bottom)/2-t[1],0),K.al(this.zoom,this.zoom,1),t)}},t.prototype.triggerUpdate=function(){if(this.enableUpdate){var t=this.getViewTransform(),e=q.multiply(q.create(),this.getPerspective(),t);this.getFrustum().extractFromVPMatrix(e),this.eventEmitter.emit(tJ.UPDATED)}},t.prototype.rotate=function(t,e,n){throw Error(tK)},t.prototype.pan=function(t,e){throw Error(tK)},t.prototype.dolly=function(t){throw Error(tK)},t.prototype.createLandmark=function(t,e){throw Error(tK)},t.prototype.gotoLandmark=function(t,e){throw Error(tK)},t.prototype.cancelLandmarkAnimation=function(){throw Error(tK)},t}();function tQ(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw TypeError("Expected a function");var n=function(){for(var r=[],i=0;i=I.kEms&&t=B.kUnitType&&this.getType()<=B.kClampType},t}(),t9=function(t){function e(e){var n=t.call(this)||this;return n.colorSpace=e,n}return(0,W.ZT)(e,t),e.prototype.getType=function(){return B.kColorType},e.prototype.to=function(t){return this},e}(t4);(v=U||(U={}))[v.Constant=0]="Constant",v[v.LinearGradient=1]="LinearGradient",v[v.RadialGradient=2]="RadialGradient";var t8=function(t){function e(e,n){var r=t.call(this)||this;return r.type=e,r.value=n,r}return(0,W.ZT)(e,t),e.prototype.clone=function(){return new e(this.type,this.value)},e.prototype.buildCSSText=function(t,e,n){return n},e.prototype.getType=function(){return B.kColorType},e}(t4),t6=function(t){function e(e){var n=t.call(this)||this;return n.value=e,n}return(0,W.ZT)(e,t),e.prototype.clone=function(){return new e(this.value)},e.prototype.getType=function(){return B.kKeywordType},e.prototype.buildCSSText=function(t,e,n){return n+this.value},e}(t4),t7=tQ(function(t){return void 0===t&&(t=""),t.replace(/-([a-z])/g,function(t){return t[1].toUpperCase()})}),et=function(t){return t.split("").map(function(t,e){return t.toUpperCase()===t?"".concat(0!==e?"-":"").concat(t.toLowerCase()):t}).join("")};function ee(t){return"function"==typeof t}var en={d:{alias:"path"},strokeDasharray:{alias:"lineDash"},strokeWidth:{alias:"lineWidth"},textAnchor:{alias:"textAlign"},src:{alias:"img"}},er=tQ(function(t){var e=t7(t),n=en[e];return(null==n?void 0:n.alias)||e}),ei=function(t,e){void 0===e&&(e="");var n="";return Number.isFinite(t)?(function(t){if(!t)throw Error()}(Number.isNaN(t)),n="NaN"):n=t>0?"infinity":"-infinity",n+e},eo=function(t){return t2(t1(t))},ea=function(t){function e(e,n){void 0===n&&(n=I.kNumber);var r,i,o=t.call(this)||this;return i="string"==typeof n?(r=n)?"number"===r?I.kNumber:"percent"===r||"%"===r?I.kPercentage:t0.find(function(t){return t.name===r}).unit_type:I.kUnknown:n,o.unit=i,o.value=e,o}return(0,W.ZT)(e,t),e.prototype.clone=function(){return new e(this.value,this.unit)},e.prototype.equals=function(t){return this.value===t.value&&this.unit===t.unit},e.prototype.getType=function(){return B.kUnitType},e.prototype.convertTo=function(t){if(this.unit===t)return new e(this.value,this.unit);var n=eo(this.unit);if(n!==eo(t)||n===I.kUnknown)return null;var r=t3(this.unit)/t3(t);return new e(this.value*r,t)},e.prototype.buildCSSText=function(t,e,n){var r;switch(this.unit){case I.kUnknown:break;case I.kInteger:r=Number(this.value).toFixed(0);break;case I.kNumber:case I.kPercentage:case I.kEms:case I.kRems:case I.kPixels:case I.kDegrees:case I.kRadians:case I.kGradians:case I.kMilliseconds:case I.kSeconds:case I.kTurns:var i=this.value,o=t5(this.unit);if(i<-999999||i>999999){var a=t5(this.unit);r=!Number.isFinite(i)||Number.isNaN(i)?ei(i,a):i+(a||"")}else r="".concat(i).concat(o)}return n+r},e}(t4),es=new ea(0,"px");new ea(1,"px");var el=new ea(0,"deg"),ec=function(t){function e(e,n,r,i,o){void 0===i&&(i=1),void 0===o&&(o=!1);var a=t.call(this,"rgb")||this;return a.r=e,a.g=n,a.b=r,a.alpha=i,a.isNone=o,a}return(0,W.ZT)(e,t),e.prototype.clone=function(){return new e(this.r,this.g,this.b,this.alpha)},e.prototype.buildCSSText=function(t,e,n){return n+"rgba(".concat(this.r,",").concat(this.g,",").concat(this.b,",").concat(this.alpha,")")},e}(t9),eu=new t6("unset"),eh={"":eu,unset:eu,initial:new t6("initial"),inherit:new t6("inherit")},ep=function(t){return eh[t]||(eh[t]=new t6(t)),eh[t]},ef=new ec(0,0,0,0,!0),ed=new ec(0,0,0,0),ev=tQ(function(t,e,n,r){return new ec(t,e,n,r)},function(t,e,n,r){return"rgba(".concat(t,",").concat(e,",").concat(n,",").concat(r,")")}),ey=function(t,e){return void 0===e&&(e=I.kNumber),new ea(t,e)},eg=new ea(50,"%");(y=Z||(Z={}))[y.Standard=0]="Standard",(g=V||(V={}))[g.ADDED=0]="ADDED",g[g.REMOVED=1]="REMOVED",g[g.Z_INDEX_CHANGED=2]="Z_INDEX_CHANGED";var em={absolutePath:[],hasArc:!1,segments:[],polygons:[],polylines:[],curve:null,totalLength:0,rect:new tz(0,0,0,0)};(m=Y||(Y={})).COORDINATE="",m.COLOR="",m.PAINT="",m.NUMBER="",m.ANGLE="",m.OPACITY_VALUE="",m.SHADOW_BLUR="",m.LENGTH="",m.PERCENTAGE="",m.LENGTH_PERCENTAGE=" | ",m.LENGTH_PERCENTAGE_12="[ | ]{1,2}",m.LENGTH_PERCENTAGE_14="[ | ]{1,4}",m.LIST_OF_POINTS="",m.PATH="",m.FILTER="",m.Z_INDEX="",m.OFFSET_DISTANCE="",m.DEFINED_PATH="",m.MARKER="",m.TRANSFORM="",m.TRANSFORM_ORIGIN="",m.TEXT="",m.TEXT_TRANSFORM="";var eE=function(){var t={linearGradient:/^(linear\-gradient)/i,repeatingLinearGradient:/^(repeating\-linear\-gradient)/i,radialGradient:/^(radial\-gradient)/i,repeatingRadialGradient:/^(repeating\-radial\-gradient)/i,conicGradient:/^(conic\-gradient)/i,sideOrCorner:/^to (left (top|bottom)|right (top|bottom)|top (left|right)|bottom (left|right)|left|right|top|bottom)/i,extentKeywords:/^(closest\-side|closest\-corner|farthest\-side|farthest\-corner|contain|cover)/,positionKeywords:/^(left|center|right|top|bottom)/i,pixelValue:/^(-?(([0-9]*\.[0-9]+)|([0-9]+\.?)))px/,percentageValue:/^(-?(([0-9]*\.[0-9]+)|([0-9]+\.?)))\%/,emValue:/^(-?(([0-9]*\.[0-9]+)|([0-9]+\.?)))em/,angleValue:/^(-?(([0-9]*\.[0-9]+)|([0-9]+\.?)))deg/,startCall:/^\(/,endCall:/^\)/,comma:/^,/,hexColor:/^\#([0-9a-fA-F]+)/,literalColor:/^([a-zA-Z]+)/,rgbColor:/^rgb/i,rgbaColor:/^rgba/i,number:/^(([0-9]*\.[0-9]+)|([0-9]+\.?))/},e="";function n(t){throw Error(e+": "+t)}function r(){return i("linear-gradient",t.linearGradient,a)||i("repeating-linear-gradient",t.repeatingLinearGradient,a)||i("radial-gradient",t.radialGradient,s)||i("repeating-radial-gradient",t.repeatingRadialGradient,s)||i("conic-gradient",t.conicGradient,s)}function i(e,r,i){return o(r,function(r){var o=i();return o&&!m(t.comma)&&n("Missing comma before color stops"),{type:e,orientation:o,colorStops:p(f)}})}function o(e,r){var i=m(e);if(i){m(t.startCall)||n("Missing (");var o=r(i);return m(t.endCall)||n("Missing )"),o}}function a(){return g("directional",t.sideOrCorner,1)||g("angular",t.angleValue,1)}function s(){var n,r,i=l();return i&&((n=[]).push(i),r=e,m(t.comma)&&((i=l())?n.push(i):e=r)),n}function l(){var t,e,n=((t=g("shape",/^(circle)/i,0))&&(t.style=y()||c()),t||((e=g("shape",/^(ellipse)/i,0))&&(e.style=v()||c()),e));if(n)n.at=u();else{var r=c();if(r){n=r;var i=u();i&&(n.at=i)}else{var o=h();o&&(n={type:"default-radial",at:o})}}return n}function c(){return g("extent-keyword",t.extentKeywords,1)}function u(){if(g("position",/^at/,0)){var t=h();return t||n("Missing positioning value"),t}}function h(){var t={x:v(),y:v()};if(t.x||t.y)return{type:"position",value:t}}function p(e){var r=e(),i=[];if(r)for(i.push(r);m(t.comma);)(r=e())?i.push(r):n("One extra comma");return i}function f(){var e=g("hex",t.hexColor,1)||o(t.rgbaColor,function(){return{type:"rgba",value:p(d)}})||o(t.rgbColor,function(){return{type:"rgb",value:p(d)}})||g("literal",t.literalColor,0);return e||n("Expected color definition"),e.length=v(),e}function d(){return m(t.number)[1]}function v(){return g("%",t.percentageValue,1)||g("position-keyword",t.positionKeywords,1)||y()}function y(){return g("px",t.pixelValue,1)||g("em",t.emValue,1)}function g(t,e,n){var r=m(e);if(r)return{type:t,value:r[n]}}function m(t){var n=/^[\n\r\t\s]+/.exec(e);n&&E(n[0].length);var r=t.exec(e);return r&&E(r[0].length),r}function E(t){e=e.substring(t)}return function(t){var i;return e=t,i=p(r),e.length>0&&n("Invalid input not EOF"),i}}();function ex(t,e,n){var r=tI(n.value),i=0+t/2,o=0+e/2,a=Math.abs(t*Math.cos(r))+Math.abs(e*Math.sin(r));return{x1:i-Math.cos(r)*a/2,y1:o-Math.sin(r)*a/2,x2:i+Math.cos(r)*a/2,y2:o+Math.sin(r)*a/2}}function eb(t,e,n,r,i){var o=n.value,a=r.value;n.unit===I.kPercentage&&(o=n.value/100*t),r.unit===I.kPercentage&&(a=r.value/100*e);var s=Math.max((0,tn.y)([0,0],[o,a]),(0,tn.y)([0,e],[o,a]),(0,tn.y)([t,e],[o,a]),(0,tn.y)([t,0],[o,a]));return i&&(i instanceof ea?s=i.value:i instanceof t6&&("closest-side"===i.value?s=Math.min(o,t-o,a,e-a):"farthest-side"===i.value?s=Math.max(o,t-o,a,e-a):"closest-corner"===i.value&&(s=Math.min((0,tn.y)([0,0],[o,a]),(0,tn.y)([0,e],[o,a]),(0,tn.y)([t,e],[o,a]),(0,tn.y)([t,0],[o,a]))))),{x:o,y:a,r:s}}var eT=/^l\s*\(\s*([\d.]+)\s*\)\s*(.*)/i,eP=/^r\s*\(\s*([\d.]+)\s*,\s*([\d.]+)\s*,\s*([\d.]+)\s*\)\s*(.*)/i,eS=/^p\s*\(\s*([axyn])\s*\)\s*(.*)/i,eN=/[\d.]+:(#[^\s]+|[^\)]+\))/gi,eC={left:180,top:-90,bottom:90,right:0,"left top":225,"top left":225,"left bottom":135,"bottom left":135,"right top":-45,"top right":-45,"right bottom":45,"bottom right":45},ew=tQ(function(t){return ey("angular"===t.type?Number(t.value):eC[t.value]||0,"deg")}),eM=tQ(function(t){var e=50,n=50,r="%",i="%";if((null==t?void 0:t.type)==="position"){var o=t.value,a=o.x,s=o.y;(null==a?void 0:a.type)==="position-keyword"&&("left"===a.value?e=0:"center"===a.value?e=50:"right"===a.value?e=100:"top"===a.value?n=0:"bottom"===a.value&&(n=100)),(null==s?void 0:s.type)==="position-keyword"&&("left"===s.value?e=0:"center"===s.value?n=50:"right"===s.value?e=100:"top"===s.value?n=0:"bottom"===s.value&&(n=100)),((null==a?void 0:a.type)==="px"||(null==a?void 0:a.type)==="%"||(null==a?void 0:a.type)==="em")&&(r=null==a?void 0:a.type,e=Number(a.value)),((null==s?void 0:s.type)==="px"||(null==s?void 0:s.type)==="%"||(null==s?void 0:s.type)==="em")&&(i=null==s?void 0:s.type,n=Number(s.value))}return{cx:ey(e,r),cy:ey(n,i)}}),ek=tQ(function(t){if(t.indexOf("linear")>-1||t.indexOf("radial")>-1){var e;return eE(t).map(function(t){var e=t.type,n=t.orientation,r=t.colorStops;!function(t){var e,n,r,i=t.length;t[i-1].length=null!==(e=t[i-1].length)&&void 0!==e?e:{type:"%",value:"100"},i>1&&(t[0].length=null!==(n=t[0].length)&&void 0!==n?n:{type:"%",value:"0"});for(var o=0,a=Number(t[0].length.value),s=1;s=0)return ey(Number(e),"px");if("deg".search(t)>=0)return ey(Number(e),"deg")}var n=[];e=e.replace(t,function(t){return n.push(t),"U"+t});var r="U("+t.source+")";return n.map(function(t){return ey(Number(e.replace(RegExp("U"+t,"g"),"").replace(RegExp(r,"g"),"*0")),t)})[0]}var eD=tQ(function(t){return eI(/px/g,t)});tQ(function(t){return eI(RegExp("%","g"),t)});var eG=function(t){return(0,te.Z)(t)||isFinite(Number(t))?ey(Number(t)||0,"px"):eI(RegExp("px|%|em|rem","g"),t)},e_=tQ(function(t){return eI(RegExp("deg|rad|grad|turn","g"),t)});function eF(t){var e=0;return t.unit===I.kDegrees?e=t.value:t.unit===I.kRadians?e=tD(Number(t.value)):t.unit===I.kTurns&&(e=360*Number(t.value)),e}function eB(t,e){var n;return(Array.isArray(t)?n=t.map(function(t){return Number(t)}):(0,ti.Z)(t)?n=t.split(" ").map(function(t){return Number(t)}):(0,te.Z)(t)&&(n=[t]),2===e)?1===n.length?[n[0],n[0]]:[n[0],n[1]]:1===n.length?[n[0],n[0],n[0],n[0]]:2===n.length?[n[0],n[1],n[0],n[1]]:3===n.length?[n[0],n[1],n[2],n[1]]:[n[0],n[1],n[2],n[3]]}function eU(t){return(0,ti.Z)(t)?t.split(" ").map(function(t){return eG(t)}):t.map(function(t){return eG(t.toString())})}function eZ(t,e,n){if(0===t.value)return 0;if(t.unit===I.kPixels)return Number(t.value);if(t.unit===I.kPercentage&&n){var r=n.nodeName===M.GROUP?n.getLocalBounds():n.geometry.contentBounds;return t.value/100*r.halfExtents[e]*2}return 0}var eV=["blur","brightness","drop-shadow","contrast","grayscale","sepia","saturate","hue-rotate","invert"];function eY(t){if(void 0===t&&(t=""),"none"===(t=t.toLowerCase().trim()))return[];for(var e,n=/\s*([\w-]+)\(([^)]*)\)/g,r=[],i=0;(e=n.exec(t))&&e.index===i;)if(i=e.index+e[0].length,eV.indexOf(e[1])>-1&&r.push({name:e[1],params:e[2].split(" ").map(function(t){return eI(/deg|rad|grad|turn|px|%/g,t)||eO(t)})}),n.lastIndex===t.length)return r;return[]}function eX(t){return t.toString()}var eH=tQ(function(t){return"number"==typeof t?ey(t):/^\s*[-+]?(\d*\.)?\d+\s*$/.test(t)?ey(Number(t)):ey(0)});function ej(t,e){return[t,e,eX]}function eW(t,e){return function(n,r){return[n,r,function(n){return eX((0,to.Z)(n,t,e))}]}}function ez(t,e){if(t.length===e.length)return[t,e,function(t){return t}]}function eK(t){return 0===t.parsedStyle.path.totalLength&&(t.parsedStyle.path.totalLength=(0,ta.D)(t.parsedStyle.path.absolutePath)),t.parsedStyle.path.totalLength}function eq(t,e){return t[0]===e[0]&&t[1]===e[1]}function eJ(t,e){var n=t.prePoint,r=t.currentPoint,i=t.nextPoint,o=Math.pow(r[0]-n[0],2)+Math.pow(r[1]-n[1],2),a=Math.pow(r[0]-i[0],2)+Math.pow(r[1]-i[1],2),s=Math.acos((o+a-(Math.pow(n[0]-i[0],2)+Math.pow(n[1]-i[1],2)))/(2*Math.sqrt(o)*Math.sqrt(a)));if(!s||0===Math.sin(s)||(0,tc.Z)(s,0))return{xExtra:0,yExtra:0};var l=Math.abs(Math.atan2(i[1]-r[1],i[0]-r[0])),c=Math.abs(Math.atan2(i[0]-r[0],i[1]-r[1]));return{xExtra:Math.cos(s/2-(l=l>Math.PI/2?Math.PI-l:l))*(e/2*(1/Math.sin(s/2)))-e/2||0,yExtra:Math.cos((c=c>Math.PI/2?Math.PI-c:c)-s/2)*(e/2*(1/Math.sin(s/2)))-e/2||0}}function e$(t,e){return[e[0]+(e[0]-t[0]),e[1]+(e[1]-t[1])]}tQ(function(t){return(0,ti.Z)(t)?t.split(" ").map(eH):t.map(eH)});var eQ=function(t,e){var n=t.x*e.x+t.y*e.y,r=Math.sqrt((Math.pow(t.x,2)+Math.pow(t.y,2))*(Math.pow(e.x,2)+Math.pow(e.y,2)));return(t.x*e.y-t.y*e.x<0?-1:1)*Math.acos(n/r)},e0=function(t,e,n,r,i,o,a,s){e=Math.abs(e),n=Math.abs(n);var l=tI(r=(0,tu.Z)(r,360));if(t.x===a.x&&t.y===a.y)return{x:t.x,y:t.y,ellipticalArcAngle:0};if(0===e||0===n)return{x:0,y:0,ellipticalArcAngle:0};var c=(t.x-a.x)/2,u=(t.y-a.y)/2,h={x:Math.cos(l)*c+Math.sin(l)*u,y:-Math.sin(l)*c+Math.cos(l)*u},p=Math.pow(h.x,2)/Math.pow(e,2)+Math.pow(h.y,2)/Math.pow(n,2);p>1&&(e=Math.sqrt(p)*e,n=Math.sqrt(p)*n);var f=(Math.pow(e,2)*Math.pow(n,2)-Math.pow(e,2)*Math.pow(h.y,2)-Math.pow(n,2)*Math.pow(h.x,2))/(Math.pow(e,2)*Math.pow(h.y,2)+Math.pow(n,2)*Math.pow(h.x,2)),d=(i!==o?1:-1)*Math.sqrt(f=f<0?0:f),v={x:d*(e*h.y/n),y:d*(-(n*h.x)/e)},y={x:Math.cos(l)*v.x-Math.sin(l)*v.y+(t.x+a.x)/2,y:Math.sin(l)*v.x+Math.cos(l)*v.y+(t.y+a.y)/2},g={x:(h.x-v.x)/e,y:(h.y-v.y)/n},m=eQ({x:1,y:0},g),E=eQ(g,{x:(-h.x-v.x)/e,y:(-h.y-v.y)/n});!o&&E>0?E-=2*Math.PI:o&&E<0&&(E+=2*Math.PI);var x=m+(E%=2*Math.PI)*s,b=e*Math.cos(x),T=n*Math.sin(x);return{x:Math.cos(l)*b-Math.sin(l)*T+y.x,y:Math.sin(l)*b+Math.cos(l)*T+y.y,ellipticalArcStartAngle:m,ellipticalArcEndAngle:m+E,ellipticalArcAngle:x,ellipticalArcCenter:y,resultantRx:e,resultantRy:n}};function e1(t,e,n){void 0===n&&(n=!0);var r=t.arcParams,i=r.rx,o=void 0===i?0:i,a=r.ry,s=void 0===a?0:a,l=r.xRotation,c=r.arcFlag,u=r.sweepFlag,h=e0({x:t.prePoint[0],y:t.prePoint[1]},o,s,l,!!c,!!u,{x:t.currentPoint[0],y:t.currentPoint[1]},e),p=e0({x:t.prePoint[0],y:t.prePoint[1]},o,s,l,!!c,!!u,{x:t.currentPoint[0],y:t.currentPoint[1]},n?e+.005:e-.005),f=p.x-h.x,d=p.y-h.y,v=Math.sqrt(f*f+d*d);return{x:-f/v,y:-d/v}}function e2(t){return Math.sqrt(t[0]*t[0]+t[1]*t[1])}function e3(t,e){return e2(t)*e2(e)?(t[0]*e[0]+t[1]*e[1])/(e2(t)*e2(e)):1}function e5(t,e){return(t[0]*e[1]0?1:-1,h=e>0?1:-1,p=u+h!==0?1:0;return[["M",u*a+n,r],["L",t-u*s+n,r],s?["A",s,s,0,0,p,t+n,h*s+r]:null,["L",t+n,e-h*l+r],l?["A",l,l,0,0,p,t+n-u*l,e+r]:null,["L",n+u*c,e+r],c?["A",c,c,0,0,p,n,e+r-h*c]:null,["L",n,h*a+r],a?["A",a,a,0,0,p,u*a+n,r]:null,["Z"]].filter(function(t){return t})}return[["M",n,r],["L",n+t,r],["L",n+t,r+e],["L",n,r+e],["Z"]]}(D,_,B,Z,V&&V.some(function(t){return 0!==t})&&V.map(function(t){return(0,to.Z)(t,0,Math.min(Math.abs(D)/2,Math.abs(_)/2))}));break;case M.PATH:var Y=t.parsedStyle.path.absolutePath;p=(0,W.ev)([],(0,W.CR)(Y),!1)}if(p.length)return o=p,a=e,c=void 0===(l=(s=t.parsedStyle).defX)?0:l,h=void 0===(u=s.defY)?0:u,o.reduce(function(t,e){var n="";if("M"===e[0]||"L"===e[0]){var r=K.al(e[1]-c,e[2]-h,0);a&&K.fF(r,r,a),n="".concat(e[0]).concat(r[0],",").concat(r[1])}else if("Z"===e[0])n=e[0];else if("C"===e[0]){var i=K.al(e[1]-c,e[2]-h,0),o=K.al(e[3]-c,e[4]-h,0),s=K.al(e[5]-c,e[6]-h,0);a&&(K.fF(i,i,a),K.fF(o,o,a),K.fF(s,s,a)),n="".concat(e[0]).concat(i[0],",").concat(i[1],",").concat(o[0],",").concat(o[1],",").concat(s[0],",").concat(s[1])}else if("A"===e[0]){var l=K.al(e[6]-c,e[7]-h,0);a&&K.fF(l,l,a),n="".concat(e[0]).concat(e[1],",").concat(e[2],",").concat(e[3],",").concat(e[4],",").concat(e[5],",").concat(l[0],",").concat(l[1])}else if("Q"===e[0]){var i=K.al(e[1]-c,e[2]-h,0),o=K.al(e[3]-c,e[4]-h,0);a&&(K.fF(i,i,a),K.fF(o,o,a)),n="".concat(e[0]).concat(e[1],",").concat(e[2],",").concat(e[3],",").concat(e[4],"}")}return t+n},"")}var e8=function(t){if(""===t||Array.isArray(t)&&0===t.length)return{absolutePath:[],hasArc:!1,segments:[],polygons:[],polylines:[],curve:null,totalLength:0,rect:{x:0,y:0,width:0,height:0}};try{e=(0,th.A)(t)}catch(n){e=(0,th.A)(""),console.error("[g]: Invalid SVG Path definition: ".concat(t))}!function(t){for(var e=0;e0&&n.push(r),{polygons:e,polylines:n}}(e),i=r.polygons,o=r.polylines,a=function(t){for(var e=[],n=null,r=null,i=null,o=0,a=t.length,s=0;s1&&(n*=Math.sqrt(f),r*=Math.sqrt(f));var d=n*n*(p*p)+r*r*(h*h),v=d?Math.sqrt((n*n*(r*r)-d)/d):1;o===a&&(v*=-1),isNaN(v)&&(v=0);var y=r?v*n*p/r:0,g=n?-(v*r)*h/n:0,m=(s+c)/2+Math.cos(i)*y-Math.sin(i)*g,E=(l+u)/2+Math.sin(i)*y+Math.cos(i)*g,x=[(h-y)/n,(p-g)/r],b=[(-1*h-y)/n,(-1*p-g)/r],T=e5([1,0],x),P=e5(x,b);return -1>=e3(x,b)&&(P=Math.PI),e3(x,b)>=1&&(P=0),0===a&&P>0&&(P-=2*Math.PI),1===a&&P<0&&(P+=2*Math.PI),{cx:m,cy:E,rx:eq(t,[c,u])?0:n,ry:eq(t,[c,u])?0:r,startAngle:T,endAngle:T+P,xRotation:i,arcFlag:o,sweepFlag:a}}(n,l);u.arcParams=h}if("Z"===c)n=i,r=t[o+1];else{var p=l.length;n=[l[p-2],l[p-1]]}r&&"Z"===r[0]&&(r=t[o],e[o]&&(e[o].prePoint=n)),u.currentPoint=n,e[o]&&eq(n,e[o].currentPoint)&&(e[o].prePoint=u.prePoint);var f=r?[r[r.length-2],r[r.length-1]]:null;u.nextPoint=f;var d=u.prePoint;if(["L","H","V"].includes(c))u.startTangent=[d[0]-n[0],d[1]-n[1]],u.endTangent=[n[0]-d[0],n[1]-d[1]];else if("Q"===c){var v=[l[1],l[2]];u.startTangent=[d[0]-v[0],d[1]-v[1]],u.endTangent=[n[0]-v[0],n[1]-v[1]]}else if("T"===c){var y=e[s-1],v=e$(y.currentPoint,d);"Q"===y.command?(u.command="Q",u.startTangent=[d[0]-v[0],d[1]-v[1]],u.endTangent=[n[0]-v[0],n[1]-v[1]]):(u.command="TL",u.startTangent=[d[0]-n[0],d[1]-n[1]],u.endTangent=[n[0]-d[0],n[1]-d[1]])}else if("C"===c){var g=[l[1],l[2]],m=[l[3],l[4]];u.startTangent=[d[0]-g[0],d[1]-g[1]],u.endTangent=[n[0]-m[0],n[1]-m[1]],0===u.startTangent[0]&&0===u.startTangent[1]&&(u.startTangent=[g[0]-m[0],g[1]-m[1]]),0===u.endTangent[0]&&0===u.endTangent[1]&&(u.endTangent=[m[0]-g[0],m[1]-g[1]])}else if("S"===c){var y=e[s-1],g=e$(y.currentPoint,d),m=[l[1],l[2]];"C"===y.command?(u.command="C",u.startTangent=[d[0]-g[0],d[1]-g[1]],u.endTangent=[n[0]-m[0],n[1]-m[1]]):(u.command="SQ",u.startTangent=[d[0]-m[0],d[1]-m[1]],u.endTangent=[n[0]-m[0],n[1]-m[1]])}else if("A"===c){var E=e1(u,0),x=E.x,b=E.y,T=e1(u,1,!1),P=T.x,S=T.y;u.startTangent=[x,b],u.endTangent=[P,S]}e.push(u)}return e}(e),s=function(t,e){for(var n=[],r=[],i=[],o=0;oMath.abs(q.determinant(tB))))){var a=tF[3],s=tF[7],l=tF[11],c=tF[12],u=tF[13],h=tF[14],p=tF[15];if(0!==a||0!==s||0!==l){if(tU[0]=a,tU[1]=s,tU[2]=l,tU[3]=p,!q.invert(tB,tB))return;q.transpose(tB,tB),$.fF(i,tU,tB)}else i[0]=i[1]=i[2]=0,i[3]=1;if(e[0]=c,e[1]=u,e[2]=h,tZ[0][0]=tF[0],tZ[0][1]=tF[1],tZ[0][2]=tF[2],tZ[1][0]=tF[4],tZ[1][1]=tF[5],tZ[1][2]=tF[6],tZ[2][0]=tF[8],tZ[2][1]=tF[9],tZ[2][2]=tF[10],n[0]=K.kE(tZ[0]),K.Fv(tZ[0],tZ[0]),r[0]=K.AK(tZ[0],tZ[1]),tY(tZ[1],tZ[1],tZ[0],1,-r[0]),n[1]=K.kE(tZ[1]),K.Fv(tZ[1],tZ[1]),r[0]/=n[1],r[1]=K.AK(tZ[0],tZ[2]),tY(tZ[2],tZ[2],tZ[0],1,-r[1]),r[2]=K.AK(tZ[1],tZ[2]),tY(tZ[2],tZ[2],tZ[1],1,-r[2]),n[2]=K.kE(tZ[2]),K.Fv(tZ[2],tZ[2]),r[1]/=n[2],r[2]/=n[2],K.kC(tV,tZ[1],tZ[2]),0>K.AK(tZ[0],tV))for(var f=0;f<3;f++)n[f]*=-1,tZ[f][0]*=-1,tZ[f][1]*=-1,tZ[f][2]*=-1;o[0]=.5*Math.sqrt(Math.max(1+tZ[0][0]-tZ[1][1]-tZ[2][2],0)),o[1]=.5*Math.sqrt(Math.max(1-tZ[0][0]+tZ[1][1]-tZ[2][2],0)),o[2]=.5*Math.sqrt(Math.max(1-tZ[0][0]-tZ[1][1]+tZ[2][2],0)),o[3]=.5*Math.sqrt(Math.max(1+tZ[0][0]+tZ[1][1]+tZ[2][2],0)),tZ[2][1]>tZ[1][2]&&(o[0]=-o[0]),tZ[0][2]>tZ[2][0]&&(o[1]=-o[1]),tZ[1][0]>tZ[0][1]&&(o[2]=-o[2])}}(0===t.length?[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]:t.map(ns).reduce(nl),e,n,r,i,o),[[e,n,r,o,i]]}var nu=function(){function t(t,e){for(var n=[[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0]],r=0;r<4;r++)for(var i=0;i<4;i++)for(var o=0;o<4;o++)n[r][i]+=e[r][o]*t[o][i];return n}return function(e,n,r,i,o){for(var a,s=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]],l=0;l<4;l++)s[l][3]=o[l];for(var l=0;l<3;l++)for(var c=0;c<3;c++)s[3][l]+=e[c]*s[c][l];var u=i[0],h=i[1],p=i[2],f=i[3],d=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]];d[0][0]=1-2*(h*h+p*p),d[0][1]=2*(u*h-p*f),d[0][2]=2*(u*p+h*f),d[1][0]=2*(u*h+p*f),d[1][1]=1-2*(u*u+p*p),d[1][2]=2*(h*p-u*f),d[2][0]=2*(u*p-h*f),d[2][1]=2*(h*p+u*f),d[2][2]=1-2*(u*u+h*h),s=t(s,d);var v=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]];r[2]&&(v[2][1]=r[2],s=t(s,v)),r[1]&&(v[2][1]=0,v[2][0]=r[0],s=t(s,v)),r[0]&&(v[2][0]=0,v[1][0]=r[0],s=t(s,v));for(var l=0;l<3;l++)for(var c=0;c<3;c++)s[l][c]*=n[l];return 0==(a=s)[0][2]&&0==a[0][3]&&0==a[1][2]&&0==a[1][3]&&0==a[2][0]&&0==a[2][1]&&1==a[2][2]&&0==a[2][3]&&0==a[3][2]&&1==a[3][3]?[s[0][0],s[0][1],s[1][0],s[1][1],s[3][0],s[3][1]]:s[0].concat(s[1],s[2],s[3])}}();function nh(t){return t.toFixed(6).replace(".000000","")}function np(t,e){var n,r;return(t.decompositionPair!==e&&(t.decompositionPair=e,n=nc(t)),e.decompositionPair!==t&&(e.decompositionPair=t,r=nc(e)),null===n[0]||null===r[0])?[[!1],[!0],function(n){return n?e[0].d:t[0].d}]:(n[0].push(0),r[0].push(1),[n,r,function(t){var e=function(t,e,n){var r=function(t,e){for(var n=0,r=0;r"].calculator(null,null,{value:e.textTransform},t,null),e.clipPath&&this.runtime.CSSPropertySyntaxFactory[""].calculator("clipPath",o,e.clipPath,t,this.runtime),e.offsetPath&&this.runtime.CSSPropertySyntaxFactory[""].calculator("offsetPath",a,e.offsetPath,t,this.runtime),e.anchor&&(t.parsedStyle.anchor=eB(e.anchor,2)),e.transform&&(t.parsedStyle.transform=na(e.transform)),e.transformOrigin&&(t.parsedStyle.transformOrigin=ny(e.transformOrigin)),e.markerStart&&(t.parsedStyle.markerStart=this.runtime.CSSPropertySyntaxFactory[""].calculator(null,e.markerStart,e.markerStart,null,null)),e.markerEnd&&(t.parsedStyle.markerEnd=this.runtime.CSSPropertySyntaxFactory[""].calculator(null,e.markerEnd,e.markerEnd,null,null)),e.markerMid&&(t.parsedStyle.markerMid=this.runtime.CSSPropertySyntaxFactory[""].calculator("",e.markerMid,e.markerMid,null,null)),(t.nodeName!==M.CIRCLE&&t.nodeName!==M.ELLIPSE||(0,tr.Z)(e.cx)&&(0,tr.Z)(e.cy))&&(t.nodeName!==M.RECT&&t.nodeName!==M.IMAGE&&t.nodeName!==M.GROUP&&t.nodeName!==M.HTML&&t.nodeName!==M.TEXT&&t.nodeName!==M.MESH||(0,tr.Z)(e.x)&&(0,tr.Z)(e.y)&&(0,tr.Z)(e.z))&&(t.nodeName!==M.LINE||(0,tr.Z)(e.x1)&&(0,tr.Z)(e.y1)&&(0,tr.Z)(e.z1)&&(0,tr.Z)(e.x2)&&(0,tr.Z)(e.y2)&&(0,tr.Z)(e.z2))||this.runtime.CSSPropertySyntaxFactory[""].postProcessor(t,i),(0,tr.Z)(e.zIndex)||this.runtime.CSSPropertySyntaxFactory[""].postProcessor(t,i),e.path&&this.runtime.CSSPropertySyntaxFactory[""].postProcessor(t,i),e.points&&this.runtime.CSSPropertySyntaxFactory[""].postProcessor(t,i),(0,tr.Z)(e.offsetDistance)||this.runtime.CSSPropertySyntaxFactory[""].postProcessor(t,i),e.transform&&this.runtime.CSSPropertySyntaxFactory[""].postProcessor(t,i),s&&this.updateGeometry(t);return}var c=n.skipUpdateAttribute,u=n.skipParse,h=n.forceUpdateGeometry,p=n.usedAttributes,f=h,d=Object.keys(e);d.forEach(function(n){var r;c||(t.attributes[n]=e[n]),!f&&(null===(r=nx[n])||void 0===r?void 0:r.l)&&(f=!0)}),u||d.forEach(function(e){t.computedStyle[e]=r.parseProperty(e,t.attributes[e],t)}),(null==p?void 0:p.length)&&(d=Array.from(new Set(d.concat(p)))),d.forEach(function(e){e in t.computedStyle&&(t.parsedStyle[e]=r.computeProperty(e,t.computedStyle[e],t))}),f&&this.updateGeometry(t),d.forEach(function(e){e in t.parsedStyle&&r.postProcessProperty(e,t,d)}),this.runtime.enableCSSParsing&&t.children.length&&d.forEach(function(e){e in t.parsedStyle&&r.isPropertyInheritable(e)&&t.children.forEach(function(t){t.internalSetAttribute(e,null,{skipUpdateAttribute:!0,skipParse:!0})})})},t.prototype.parseProperty=function(t,e,n){var r=nx[t],i=e;if((""===e||(0,tr.Z)(e))&&(e="unset"),"unset"===e||"initial"===e||"inherit"===e)i=ep(e);else if(r){var o=r.k,a=r.syntax,s=a&&this.getPropertySyntax(a);o&&o.indexOf(e)>-1?i=ep(e):s&&s.parser&&(i=s.parser(e,n))}return i},t.prototype.computeProperty=function(t,e,n){var r=nx[t],i="g-root"===n.id,o=e;if(r){var a=r.syntax,s=r.inh,l=r.d;if(e instanceof t6){var c=e.value;if("unset"===c&&(c=s&&!i?"inherit":"initial"),"initial"===c)(0,tr.Z)(l)||(e=this.parseProperty(t,ee(l)?l(n.nodeName):l,n));else if("inherit"===c){var u=this.tryToResolveProperty(n,t,{inherited:!0});return(0,tr.Z)(u)?void this.addUnresolveProperty(n,t):u}}var h=a&&this.getPropertySyntax(a);if(h&&h.calculator){var p=n.parsedStyle[t];o=h.calculator(t,p,e,n,this.runtime)}else o=e instanceof t6?e.value:e}return o},t.prototype.postProcessProperty=function(t,e,n){var r=nx[t];if(r&&r.syntax){var i=r.syntax&&this.getPropertySyntax(r.syntax);i&&i.postProcessor&&i.postProcessor(e,n)}},t.prototype.addUnresolveProperty=function(t,e){var n=nb.get(t);n||(nb.set(t,[]),n=nb.get(t)),-1===n.indexOf(e)&&n.push(e)},t.prototype.tryToResolveProperty=function(t,e,n){if(void 0===n&&(n={}),n.inherited&&t.parentElement&&nT(t.parentElement,e)){var r=t.parentElement.parsedStyle[e];if("unset"!==r&&"initial"!==r&&"inherit"!==r)return r}},t.prototype.recalc=function(t){var e=nb.get(t);if(e&&e.length){var n={};e.forEach(function(e){n[e]=t.attributes[e]}),this.processProperties(t,n),nb.delete(t)}},t.prototype.updateGeometry=function(t){var e=t.nodeName,n=this.runtime.geometryUpdaterFactory[e];if(n){var r=t.geometry;r.contentBounds||(r.contentBounds=new tX),r.renderBounds||(r.renderBounds=new tX);var i=t.parsedStyle,o=n.update(i,t),a=o.width,s=o.height,l=o.depth,c=o.offsetX,u=o.offsetY,h=o.offsetZ,p=[Math.abs(a)/2,Math.abs(s)/2,(void 0===l?0:l)/2],f=i.stroke,d=i.lineWidth,v=i.increasedLineWidthForHitTesting,y=i.shadowType,g=i.shadowColor,m=i.filter,E=i.transformOrigin,x=i.anchor;e===M.TEXT?delete i.anchor:e===M.MESH&&(i.anchor[2]=.5);var b=[(1-2*(x&&x[0]||0))*a/2+(void 0===c?0:c),(1-2*(x&&x[1]||0))*s/2+(void 0===u?0:u),(1-2*(x&&x[2]||0))*p[2]+(void 0===h?0:h)];r.contentBounds.update(b,p);var T=e===M.POLYLINE||e===M.POLYGON||e===M.PATH?Math.SQRT2:.5;if(f&&!f.isNone){var P=((d||0)+(v||0))*T;p[0]+=P,p[1]+=P}if(r.renderBounds.update(b,p),g&&y&&"inner"!==y){var S=r.renderBounds,N=S.min,C=S.max,w=i.shadowBlur,k=i.shadowOffsetX,R=i.shadowOffsetY,A=w||0,O=k||0,L=R||0,I=N[0]-A+O,D=C[0]+A+O,G=N[1]-A+L,_=C[1]+A+L;N[0]=Math.min(N[0],I),C[0]=Math.max(C[0],D),N[1]=Math.min(N[1],G),C[1]=Math.max(C[1],_),r.renderBounds.setMinMax(N,C)}(void 0===m?[]:m).forEach(function(t){var e=t.name,n=t.params;if("blur"===e){var i=n[0].value;r.renderBounds.update(r.renderBounds.center,tR(r.renderBounds.halfExtents,r.renderBounds.halfExtents,[i,i,0]))}else if("drop-shadow"===e){var o=n[0].value,a=n[1].value,s=n[2].value,l=r.renderBounds,c=l.min,u=l.max,h=c[0]-s+o,p=u[0]+s+o,f=c[1]-s+a,d=u[1]+s+a;c[0]=Math.min(c[0],h),u[0]=Math.max(u[0],p),c[1]=Math.min(c[1],f),u[1]=Math.max(u[1],d),r.renderBounds.setMinMax(c,u)}}),x=i.anchor;var F=a<0,B=s<0,U=(F?-1:1)*(E?eZ(E[0],0,t):0),Z=(B?-1:1)*(E?eZ(E[1],1,t):0);U-=(F?-1:1)*(x&&x[0]||0)*r.contentBounds.halfExtents[0]*2,Z-=(B?-1:1)*(x&&x[1]||0)*r.contentBounds.halfExtents[1]*2,t.setOrigin(U,Z),this.runtime.sceneGraphService.dirtifyToRoot(t)}},t.prototype.isPropertyInheritable=function(t){var e=nx[t];return!!e&&e.inh},t}(),nS=function(){function t(){this.parser=e_,this.parserWithCSSDisabled=null,this.mixer=ej}return t.prototype.calculator=function(t,e,n,r){return eF(n)},t}(),nN=function(){function t(){}return t.prototype.calculator=function(t,e,n,r,i){return n instanceof t6&&(n=null),i.sceneGraphService.updateDisplayObjectDependency(t,e,n,r),"clipPath"===t&&r.forEach(function(t){0===t.childNodes.length&&i.sceneGraphService.dirtifyToRoot(t)}),n},t}(),nC=function(){function t(){this.parser=eO,this.parserWithCSSDisabled=eO,this.mixer=eL}return t.prototype.calculator=function(t,e,n,r){return n instanceof t6?"none"===n.value?ef:ed:n},t}(),nw=function(){function t(){this.parser=eY}return t.prototype.calculator=function(t,e,n){return n instanceof t6?[]:n},t}();function nM(t){var e=t.parsedStyle.fontSize;return(0,tr.Z)(e)?null:e}var nk=function(){function t(){this.parser=eG,this.parserWithCSSDisabled=null,this.mixer=ej}return t.prototype.calculator=function(t,e,n,r,i){if((0,te.Z)(n))return n;if(!ea.isRelativeUnit(n.unit))return n.value;var o,a=i.styleValueRegistry;if(n.unit===I.kPercentage)return 0;if(n.unit===I.kEms){if(r.parentNode){var s=nM(r.parentNode);if(s)return s*n.value;a.addUnresolveProperty(r,t)}else a.addUnresolveProperty(r,t);return 0}if(n.unit===I.kRems){if(null===(o=null==r?void 0:r.ownerDocument)||void 0===o?void 0:o.documentElement){var s=nM(r.ownerDocument.documentElement);if(s)return s*n.value;a.addUnresolveProperty(r,t)}else a.addUnresolveProperty(r,t);return 0}},t}(),nR=function(){function t(){this.mixer=ez}return t.prototype.parser=function(t){var e=eU((0,te.Z)(t)?[t]:t);return 1===e.length?[e[0],e[0]]:[e[0],e[1]]},t.prototype.calculator=function(t,e,n){return n.map(function(t){return t.value})},t}(),nA=function(){function t(){this.mixer=ez}return t.prototype.parser=function(t){var e=eU((0,te.Z)(t)?[t]:t);return 1===e.length?[e[0],e[0],e[0],e[0]]:2===e.length?[e[0],e[1],e[0],e[1]]:3===e.length?[e[0],e[1],e[2],e[1]]:[e[0],e[1],e[2],e[3]]},t.prototype.calculator=function(t,e,n){return n.map(function(t){return t.value})},t}(),nO=q.create();function nL(t,e){var n=e.parsedStyle.defX||0,r=e.parsedStyle.defY||0;return e.resetLocalTransform(),e.setLocalPosition(n,r),t.forEach(function(t){var i=t.t,o=t.d;if("scale"===i){var a=(null==o?void 0:o.map(function(t){return t.value}))||[1,1];e.scaleLocal(a[0],a[1],1)}else if("scalex"===i){var a=(null==o?void 0:o.map(function(t){return t.value}))||[1];e.scaleLocal(a[0],1,1)}else if("scaley"===i){var a=(null==o?void 0:o.map(function(t){return t.value}))||[1];e.scaleLocal(1,a[0],1)}else if("scalez"===i){var a=(null==o?void 0:o.map(function(t){return t.value}))||[1];e.scaleLocal(1,1,a[0])}else if("scale3d"===i){var a=(null==o?void 0:o.map(function(t){return t.value}))||[1,1,1];e.scaleLocal(a[0],a[1],a[2])}else if("translate"===i){var s=o||[es,es];e.translateLocal(s[0].value,s[1].value,0)}else if("translatex"===i){var s=o||[es];e.translateLocal(s[0].value,0,0)}else if("translatey"===i){var s=o||[es];e.translateLocal(0,s[0].value,0)}else if("translatez"===i){var s=o||[es];e.translateLocal(0,0,s[0].value)}else if("translate3d"===i){var s=o||[es,es,es];e.translateLocal(s[0].value,s[1].value,s[2].value)}else if("rotate"===i){var l=o||[el];e.rotateLocal(0,0,eF(l[0]))}else if("rotatex"===i){var l=o||[el];e.rotateLocal(eF(l[0]),0,0)}else if("rotatey"===i){var l=o||[el];e.rotateLocal(0,eF(l[0]),0)}else if("rotatez"===i){var l=o||[el];e.rotateLocal(0,0,eF(l[0]))}else if("rotate3d"===i);else if("skew"===i){var c=(null==o?void 0:o.map(function(t){return t.value}))||[0,0];e.setLocalSkew(tI(c[0]),tI(c[1]))}else if("skewx"===i){var c=(null==o?void 0:o.map(function(t){return t.value}))||[0];e.setLocalSkew(tI(c[0]),e.getLocalSkew()[1])}else if("skewy"===i){var c=(null==o?void 0:o.map(function(t){return t.value}))||[0];e.setLocalSkew(e.getLocalSkew()[0],tI(c[0]))}else if("matrix"===i){var u=(0,W.CR)(o.map(function(t){return t.value}),6),h=u[0],p=u[1],f=u[2],d=u[3],v=u[4],y=u[5];e.setLocalTransform(q.set(nO,h,p,0,0,f,d,0,0,0,0,1,0,v+n,y+r,0,1))}else"matrix3d"===i&&(q.set.apply(q,(0,W.ev)([nO],(0,W.CR)(o.map(function(t){return t.value})),!1)),nO[12]+=n,nO[13]+=r,e.setLocalTransform(nO))}),e.getLocalTransform()}var nI=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,W.ZT)(e,t),e.prototype.postProcessor=function(t,e){switch(t.nodeName){case M.CIRCLE:case M.ELLIPSE:var n,r,i,o=t.parsedStyle,a=o.cx,s=o.cy,l=o.cz;(0,tr.Z)(a)||(n=a),(0,tr.Z)(s)||(r=s),(0,tr.Z)(l)||(i=l);break;case M.LINE:var c=t.parsedStyle,u=c.x1,h=c.x2,p=Math.min(c.y1,c.y2);n=Math.min(u,h),r=p,i=0;break;case M.RECT:case M.IMAGE:case M.GROUP:case M.HTML:case M.TEXT:case M.MESH:(0,tr.Z)(t.parsedStyle.x)||(n=t.parsedStyle.x),(0,tr.Z)(t.parsedStyle.y)||(r=t.parsedStyle.y),(0,tr.Z)(t.parsedStyle.z)||(i=t.parsedStyle.z)}if(t.nodeName!==M.PATH&&t.nodeName!==M.POLYLINE&&t.nodeName!==M.POLYGON&&(t.parsedStyle.defX=n||0,t.parsedStyle.defY=r||0),(!(0,tr.Z)(n)||!(0,tr.Z)(r)||!(0,tr.Z)(i))&&-1===e.indexOf("transform")){var f=t.parsedStyle.transform;if(f&&f.length)nL(f,t);else{var d=(0,W.CR)(t.getLocalPosition(),3),v=d[0],y=d[1],g=d[2];t.setLocalPosition((0,tr.Z)(n)?v:n,(0,tr.Z)(r)?y:r,(0,tr.Z)(i)?g:i)}}},e}(nk),nD=function(){function t(){}return t.prototype.calculator=function(t,e,n,r){n instanceof t6&&(n=null);var i=null==n?void 0:n.cloneNode(!0);return i&&(i.style.isMarker=!0),i},t}(),nG=function(){function t(){this.mixer=ej,this.parser=eH,this.parserWithCSSDisabled=null}return t.prototype.calculator=function(t,e,n){return n.value},t}(),n_=function(){function t(){this.parser=eH,this.parserWithCSSDisabled=null,this.mixer=eW(0,1)}return t.prototype.calculator=function(t,e,n){return n.value},t.prototype.postProcessor=function(t){var e=t.parsedStyle,n=e.offsetPath,r=e.offsetDistance;if(n){var i=n.nodeName;if(i===M.LINE||i===M.PATH||i===M.POLYLINE){var o=n.getPoint(r);o&&(t.parsedStyle.defX=o.x,t.parsedStyle.defY=o.y,t.setLocalPosition(o.x,o.y))}}},t}(),nF=function(){function t(){this.parser=eH,this.parserWithCSSDisabled=null,this.mixer=eW(0,1)}return t.prototype.calculator=function(t,e,n){return n.value},t}(),nB=function(){function t(){this.parser=e7,this.parserWithCSSDisabled=e7,this.mixer=nt}return t.prototype.calculator=function(t,e,n){return n instanceof t6&&"unset"===n.value?{absolutePath:[],hasArc:!1,segments:[],polygons:[],polylines:[],curve:null,totalLength:0,rect:new tz(0,0,0,0)}:n},t.prototype.postProcessor=function(t,e){if(t.parsedStyle.defX=t.parsedStyle.path.rect.x,t.parsedStyle.defY=t.parsedStyle.path.rect.y,t.nodeName===M.PATH&&-1===e.indexOf("transform")){var n=t.parsedStyle,r=n.defX,i=void 0===r?0:r,o=n.defY,a=void 0===o?0:o;t.setLocalPosition(i,a)}},t}(),nU=function(){function t(){this.parser=ne,this.mixer=nn}return t.prototype.postProcessor=function(t,e){if((t.nodeName===M.POLYGON||t.nodeName===M.POLYLINE)&&-1===e.indexOf("transform")){var n=t.parsedStyle,r=n.defX,i=n.defY;t.setLocalPosition(r,i)}},t}(),nZ=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.mixer=eW(0,1/0),e}return(0,W.ZT)(e,t),e}(nk),nV=function(){function t(){}return t.prototype.calculator=function(t,e,n,r){return n instanceof t6?"unset"===n.value?"":n.value:"".concat(n)},t.prototype.postProcessor=function(t){t.nodeValue="".concat(t.parsedStyle.text)||""},t}(),nY=function(){function t(){}return t.prototype.calculator=function(t,e,n,r){var i=r.getAttribute("text");if(i){var o=i;"capitalize"===n.value?o=i.charAt(0).toUpperCase()+i.slice(1):"lowercase"===n.value?o=i.toLowerCase():"uppercase"===n.value&&(o=i.toUpperCase()),r.parsedStyle.text=o}return n.value},t}(),nX={},nH=0,nj="undefined"!=typeof window&&void 0!==window.document;function nW(t,e){var n=Number(t.parsedStyle.zIndex),r=Number(e.parsedStyle.zIndex);if(n===r){var i=t.parentNode;if(i){var o=i.childNodes||[];return o.indexOf(t)-o.indexOf(e)}}return n-r}function nz(t){var e,n=t;do{if(null===(e=n.parsedStyle)||void 0===e?void 0:e.clipPath)return n;n=n.parentElement}while(null!==n);return null}function nK(t,e,n){nj&&t.style&&(t.style.width=e+"px",t.style.height=n+"px")}function nq(t,e){if(nj)return document.defaultView.getComputedStyle(t,null).getPropertyValue(e)}var nJ={touchstart:"pointerdown",touchend:"pointerup",touchendoutside:"pointerupoutside",touchmove:"pointermove",touchcancel:"pointercancel"},n$="object"==typeof performance&&performance.now?performance:Date;function nQ(t,e,n){var r=!1,i=!1,o=!!e&&!e.isNone,a=!!n&&!n.isNone;return"visiblepainted"===t||"painted"===t||"auto"===t?(r=o,i=a):"visiblefill"===t||"fill"===t?r=!0:"visiblestroke"===t||"stroke"===t?i=!0:("visible"===t||"all"===t)&&(r=!0,i=!0),[r,i]}var n0=1,n1="object"==typeof self&&self.self==self?self:"object"==typeof n.g&&n.g.global==n.g?n.g:{},n2=Date.now(),n3={},n5=Date.now(),n4=function(t){if("function"!=typeof t)throw TypeError(t+" is not a function");var e=Date.now(),n=e-n5,r=n0++;return n3[r]=t,Object.keys(n3).length>1||setTimeout(function(){n5=e;var t=n3;n3={},Object.keys(t).forEach(function(e){return t[e](n1.performance&&"function"==typeof n1.performance.now?n1.performance.now():Date.now()-n2)})},n>16?0:16-n),r},n9=function(t){return"string"!=typeof t?n4:""===t?n1.requestAnimationFrame:n1[t+"RequestAnimationFrame"]},n8=function(t,e){for(var n=0;void 0!==t[n];){if(e(t[n]))return t[n];n+=1}}(["","webkit","moz","ms","o"],function(t){return!!n9(t)}),n6=n9(n8),n7="string"!=typeof n8?function(t){delete n3[t]}:""===n8?n1.cancelAnimationFrame:n1[n8+"CancelAnimationFrame"]||n1[n8+"CancelRequestAnimationFrame"];n1.requestAnimationFrame=n6,n1.cancelAnimationFrame=n7;var rt=function(){function t(){this.callbacks=[]}return t.prototype.getCallbacksNum=function(){return this.callbacks.length},t.prototype.tapPromise=function(t,e){this.callbacks.push(e)},t.prototype.promise=function(){for(var t=[],e=0;e-1){var l=(0,W.CR)(t.split(":"),2),c=l[0];t=l[1],s=c,a=!0}if(t=r?"".concat(t,"capture"):t,e=ee(e)?e:e.handleEvent,a){var u=e;e=function(){for(var t,e=[],n=0;n0},e.prototype.isDefaultNamespace=function(t){throw Error(tK)},e.prototype.lookupNamespaceURI=function(t){throw Error(tK)},e.prototype.lookupPrefix=function(t){throw Error(tK)},e.prototype.normalize=function(){throw Error(tK)},e.prototype.isEqualNode=function(t){return this===t},e.prototype.isSameNode=function(t){return this.isEqualNode(t)},Object.defineProperty(e.prototype,"parent",{get:function(){return this.parentNode},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"parentElement",{get:function(){return null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"nextSibling",{get:function(){return null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"previousSibling",{get:function(){return null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"firstChild",{get:function(){return this.childNodes.length>0?this.childNodes[0]:null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"lastChild",{get:function(){return this.childNodes.length>0?this.childNodes[this.childNodes.length-1]:null},enumerable:!1,configurable:!0}),e.prototype.compareDocumentPosition=function(t){if(t===this)return 0;for(var n,r=t,i=this,o=[r],a=[i];null!==(n=r.parentNode)&&void 0!==n?n:i.parentNode;)r=r.parentNode?(o.push(r.parentNode),r.parentNode):r,i=i.parentNode?(a.push(i.parentNode),i.parentNode):i;if(r!==i)return e.DOCUMENT_POSITION_DISCONNECTED|e.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC|e.DOCUMENT_POSITION_PRECEDING;var s=o.length>a.length?o:a,l=s===o?a:o;if(s[s.length-l.length]===l[0])return s===o?e.DOCUMENT_POSITION_CONTAINED_BY|e.DOCUMENT_POSITION_FOLLOWING:e.DOCUMENT_POSITION_CONTAINS|e.DOCUMENT_POSITION_PRECEDING;for(var c=s.length-l.length,u=l.length-1;u>=0;u--){var h=l[u],p=s[c+u];if(p!==h){var f=h.parentNode.childNodes;if(f.indexOf(h)0&&e;)e=e.parentNode,t--;return e},e.prototype.forEach=function(t,e){void 0===e&&(e=!1),t(this)||(e?this.childNodes.slice():this.childNodes).forEach(function(e){e.forEach(t)})},e.DOCUMENT_POSITION_DISCONNECTED=1,e.DOCUMENT_POSITION_PRECEDING=2,e.DOCUMENT_POSITION_FOLLOWING=4,e.DOCUMENT_POSITION_CONTAINS=8,e.DOCUMENT_POSITION_CONTAINED_BY=16,e.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC=32,e}(rx),rT=function(){function t(t,e){var n=this;this.globalRuntime=t,this.context=e,this.emitter=new z.Z,this.cursor="default",this.mappingTable={},this.mappingState={trackingData:{}},this.eventPool=new Map,this.tmpMatrix=q.create(),this.tmpVec3=K.Ue(),this.onPointerDown=function(t){var e=n.createPointerEvent(t);if(n.dispatchEvent(e,"pointerdown"),"touch"===e.pointerType)n.dispatchEvent(e,"touchstart");else if("mouse"===e.pointerType||"pen"===e.pointerType){var r=2===e.button;n.dispatchEvent(e,r?"rightdown":"mousedown")}n.trackingData(t.pointerId).pressTargetsByButton[t.button]=e.composedPath(),n.freeEvent(e)},this.onPointerUp=function(t){var e,r=n$.now(),i=n.createPointerEvent(t,void 0,void 0,n.context.config.alwaysTriggerPointerEventOnCanvas?n.rootTarget:void 0);if(n.dispatchEvent(i,"pointerup"),"touch"===i.pointerType)n.dispatchEvent(i,"touchend");else if("mouse"===i.pointerType||"pen"===i.pointerType){var o=2===i.button;n.dispatchEvent(i,o?"rightup":"mouseup")}var a=n.trackingData(t.pointerId),s=n.findMountedTarget(a.pressTargetsByButton[t.button]),l=s;if(s&&!i.composedPath().includes(s)){for(var c=s;c&&!i.composedPath().includes(c);){if(i.currentTarget=c,n.notifyTarget(i,"pointerupoutside"),"touch"===i.pointerType)n.notifyTarget(i,"touchendoutside");else if("mouse"===i.pointerType||"pen"===i.pointerType){var o=2===i.button;n.notifyTarget(i,o?"rightupoutside":"mouseupoutside")}rb.isNode(c)&&(c=c.parentNode)}delete a.pressTargetsByButton[t.button],l=c}if(l){var u=n.clonePointerEvent(i,"click");u.target=l,u.path=[],a.clicksByButton[t.button]||(a.clicksByButton[t.button]={clickCount:0,target:u.target,timeStamp:r});var h=a.clicksByButton[t.button];h.target===u.target&&r-h.timeStamp<200?++h.clickCount:h.clickCount=1,h.target=u.target,h.timeStamp=r,u.detail=h.clickCount,(null===(e=i.detail)||void 0===e?void 0:e.preventClick)||(n.context.config.useNativeClickEvent||"mouse"!==u.pointerType&&"touch"!==u.pointerType||n.dispatchEvent(u,"click"),n.dispatchEvent(u,"pointertap")),n.freeEvent(u)}n.freeEvent(i)},this.onPointerMove=function(t){var e=n.createPointerEvent(t,void 0,void 0,n.context.config.alwaysTriggerPointerEventOnCanvas?n.rootTarget:void 0),r="mouse"===e.pointerType||"pen"===e.pointerType,i=n.trackingData(t.pointerId),o=n.findMountedTarget(i.overTargets);if(i.overTargets&&o!==e.target){var a="mousemove"===t.type?"mouseout":"pointerout",s=n.createPointerEvent(t,a,o||void 0);if(n.dispatchEvent(s,"pointerout"),r&&n.dispatchEvent(s,"mouseout"),!e.composedPath().includes(o)){var l=n.createPointerEvent(t,"pointerleave",o||void 0);for(l.eventPhase=l.AT_TARGET;l.target&&!e.composedPath().includes(l.target);)l.currentTarget=l.target,n.notifyTarget(l),r&&n.notifyTarget(l,"mouseleave"),rb.isNode(l.target)&&(l.target=l.target.parentNode);n.freeEvent(l)}n.freeEvent(s)}if(o!==e.target){var c="mousemove"===t.type?"mouseover":"pointerover",u=n.clonePointerEvent(e,c);n.dispatchEvent(u,"pointerover"),r&&n.dispatchEvent(u,"mouseover");for(var h=o&&rb.isNode(o)&&o.parentNode;h&&h!==(rb.isNode(n.rootTarget)&&n.rootTarget.parentNode)&&h!==e.target;)h=h.parentNode;if(!h||h===(rb.isNode(n.rootTarget)&&n.rootTarget.parentNode)){var p=n.clonePointerEvent(e,"pointerenter");for(p.eventPhase=p.AT_TARGET;p.target&&p.target!==o&&p.target!==(rb.isNode(n.rootTarget)&&n.rootTarget.parentNode);)p.currentTarget=p.target,n.notifyTarget(p),r&&n.notifyTarget(p,"mouseenter"),rb.isNode(p.target)&&(p.target=p.target.parentNode);n.freeEvent(p)}n.freeEvent(u)}n.dispatchEvent(e,"pointermove"),"touch"===e.pointerType&&n.dispatchEvent(e,"touchmove"),r&&(n.dispatchEvent(e,"mousemove"),n.cursor=n.getCursor(e.target)),i.overTargets=e.composedPath(),n.freeEvent(e)},this.onPointerOut=function(t){var e=n.trackingData(t.pointerId);if(e.overTargets){var r="mouse"===t.pointerType||"pen"===t.pointerType,i=n.findMountedTarget(e.overTargets),o=n.createPointerEvent(t,"pointerout",i||void 0);n.dispatchEvent(o),r&&n.dispatchEvent(o,"mouseout");var a=n.createPointerEvent(t,"pointerleave",i||void 0);for(a.eventPhase=a.AT_TARGET;a.target&&a.target!==(rb.isNode(n.rootTarget)&&n.rootTarget.parentNode);)a.currentTarget=a.target,n.notifyTarget(a),r&&n.notifyTarget(a,"mouseleave"),rb.isNode(a.target)&&(a.target=a.target.parentNode);e.overTargets=null,n.freeEvent(o),n.freeEvent(a)}n.cursor=null},this.onPointerOver=function(t){var e=n.trackingData(t.pointerId),r=n.createPointerEvent(t),i="mouse"===r.pointerType||"pen"===r.pointerType;n.dispatchEvent(r,"pointerover"),i&&n.dispatchEvent(r,"mouseover"),"mouse"===r.pointerType&&(n.cursor=n.getCursor(r.target));var o=n.clonePointerEvent(r,"pointerenter");for(o.eventPhase=o.AT_TARGET;o.target&&o.target!==(rb.isNode(n.rootTarget)&&n.rootTarget.parentNode);)o.currentTarget=o.target,n.notifyTarget(o),i&&n.notifyTarget(o,"mouseenter"),rb.isNode(o.target)&&(o.target=o.target.parentNode);e.overTargets=r.composedPath(),n.freeEvent(r),n.freeEvent(o)},this.onPointerUpOutside=function(t){var e=n.trackingData(t.pointerId),r=n.findMountedTarget(e.pressTargetsByButton[t.button]),i=n.createPointerEvent(t);if(r){for(var o=r;o;)i.currentTarget=o,n.notifyTarget(i,"pointerupoutside"),"touch"===i.pointerType||("mouse"===i.pointerType||"pen"===i.pointerType)&&n.notifyTarget(i,2===i.button?"rightupoutside":"mouseupoutside"),rb.isNode(o)&&(o=o.parentNode);delete e.pressTargetsByButton[t.button]}n.freeEvent(i)},this.onWheel=function(t){var e=n.createWheelEvent(t);n.dispatchEvent(e),n.freeEvent(e)},this.onClick=function(t){if(n.context.config.useNativeClickEvent){var e=n.createPointerEvent(t);n.dispatchEvent(e),n.freeEvent(e)}},this.onPointerCancel=function(t){var e=n.createPointerEvent(t,void 0,void 0,n.context.config.alwaysTriggerPointerEventOnCanvas?n.rootTarget:void 0);n.dispatchEvent(e),n.freeEvent(e)}}return t.prototype.init=function(){this.rootTarget=this.context.renderingContext.root.parentNode,this.addEventMapping("pointerdown",this.onPointerDown),this.addEventMapping("pointerup",this.onPointerUp),this.addEventMapping("pointermove",this.onPointerMove),this.addEventMapping("pointerout",this.onPointerOut),this.addEventMapping("pointerleave",this.onPointerOut),this.addEventMapping("pointercancel",this.onPointerCancel),this.addEventMapping("pointerover",this.onPointerOver),this.addEventMapping("pointerupoutside",this.onPointerUpOutside),this.addEventMapping("wheel",this.onWheel),this.addEventMapping("click",this.onClick)},t.prototype.destroy=function(){this.emitter.removeAllListeners(),this.mappingTable={},this.mappingState={},this.eventPool.clear()},t.prototype.client2Viewport=function(t){var e=this.context.contextService.getBoundingClientRect();return new tW(t.x-((null==e?void 0:e.left)||0),t.y-((null==e?void 0:e.top)||0))},t.prototype.viewport2Client=function(t){var e=this.context.contextService.getBoundingClientRect();return new tW(t.x+((null==e?void 0:e.left)||0),t.y+((null==e?void 0:e.top)||0))},t.prototype.viewport2Canvas=function(t){var e=t.x,n=t.y,r=this.rootTarget.defaultView.getCamera(),i=this.context.config,o=i.width,a=i.height,s=r.getPerspectiveInverse(),l=r.getWorldTransform(),c=q.multiply(this.tmpMatrix,l,s),u=K.t8(this.tmpVec3,e/o*2-1,(1-n/a)*2-1,0);return K.fF(u,u,c),new tW(u[0],u[1])},t.prototype.canvas2Viewport=function(t){var e=this.rootTarget.defaultView.getCamera(),n=e.getPerspective(),r=e.getViewTransform(),i=q.multiply(this.tmpMatrix,n,r),o=K.t8(this.tmpVec3,t.x,t.y,0);K.fF(this.tmpVec3,this.tmpVec3,i);var a=this.context.config,s=a.width,l=a.height;return new tW((o[0]+1)/2*s,(1-(o[1]+1)/2)*l)},t.prototype.setPickHandler=function(t){this.pickHandler=t},t.prototype.addEventMapping=function(t,e){this.mappingTable[t]||(this.mappingTable[t]=[]),this.mappingTable[t].push({fn:e,priority:0}),this.mappingTable[t].sort(function(t,e){return t.priority-e.priority})},t.prototype.mapEvent=function(t){if(this.rootTarget){var e=this.mappingTable[t.type];if(e)for(var n=0,r=e.length;n=1;r--)if(t.currentTarget=n[r],this.notifyTarget(t,e),t.propagationStopped||t.propagationImmediatelyStopped)return;if(t.eventPhase=t.AT_TARGET,t.currentTarget=t.target,this.notifyTarget(t,e),!t.propagationStopped&&!t.propagationImmediatelyStopped){var i=n.indexOf(t.currentTarget);t.eventPhase=t.BUBBLING_PHASE;for(var r=i+1;ri||n>o?null:!a&&this.pickHandler(t)||this.rootTarget||null},t.prototype.isNativeEventFromCanvas=function(t){var e,n=this.context.contextService.getDomElement(),r=null===(e=t.nativeEvent)||void 0===e?void 0:e.target;if(r){if(r===n)return!0;if(n&&n.contains)return n.contains(r)}return!!t.nativeEvent.composedPath&&t.nativeEvent.composedPath().indexOf(n)>-1},t.prototype.getExistedHTML=function(t){var e,n;if(t.nativeEvent.composedPath)try{for(var r=(0,W.XA)(t.nativeEvent.composedPath()),i=r.next();!i.done;i=r.next()){var o=i.value,a=this.globalRuntime.nativeHTMLMap.get(o);if(a)return a}}catch(t){e={error:t}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(e)throw e.error}}return null},t.prototype.pickTarget=function(t){return this.hitTest({clientX:t.clientX,clientY:t.clientY,viewportX:t.viewportX,viewportY:t.viewportY,x:t.canvasX,y:t.canvasY})},t.prototype.createPointerEvent=function(t,e,n,r){var i=this.allocateEvent(rg);this.copyPointerData(t,i),this.copyMouseData(t,i),this.copyData(t,i),i.nativeEvent=t.nativeEvent,i.originalEvent=t;var o=this.getExistedHTML(i);return i.target=null!=n?n:o||this.isNativeEventFromCanvas(i)&&this.pickTarget(i)||r,"string"==typeof e&&(i.type=e),i},t.prototype.createWheelEvent=function(t){var e=this.allocateEvent(rm);this.copyWheelData(t,e),this.copyMouseData(t,e),this.copyData(t,e),e.nativeEvent=t.nativeEvent,e.originalEvent=t;var n=this.getExistedHTML(e);return e.target=n||this.isNativeEventFromCanvas(e)&&this.pickTarget(e),e},t.prototype.trackingData=function(t){return this.mappingState.trackingData[t]||(this.mappingState.trackingData[t]={pressTargetsByButton:{},clicksByButton:{},overTarget:null}),this.mappingState.trackingData[t]},t.prototype.cloneWheelEvent=function(t){var e=this.allocateEvent(rm);return e.nativeEvent=t.nativeEvent,e.originalEvent=t.originalEvent,this.copyWheelData(t,e),this.copyMouseData(t,e),this.copyData(t,e),e.target=t.target,e.path=t.composedPath().slice(),e.type=t.type,e},t.prototype.clonePointerEvent=function(t,e){var n=this.allocateEvent(rg);return n.nativeEvent=t.nativeEvent,n.originalEvent=t.originalEvent,this.copyPointerData(t,n),this.copyMouseData(t,n),this.copyData(t,n),n.target=t.target,n.path=t.composedPath().slice(),n.type=null!=e?e:n.type,n},t.prototype.copyPointerData=function(t,e){e.pointerId=t.pointerId,e.width=t.width,e.height=t.height,e.isPrimary=t.isPrimary,e.pointerType=t.pointerType,e.pressure=t.pressure,e.tangentialPressure=t.tangentialPressure,e.tiltX=t.tiltX,e.tiltY=t.tiltY,e.twist=t.twist},t.prototype.copyMouseData=function(t,e){e.altKey=t.altKey,e.button=t.button,e.buttons=t.buttons,e.ctrlKey=t.ctrlKey,e.metaKey=t.metaKey,e.shiftKey=t.shiftKey,e.client.copyFrom(t.client),e.movement.copyFrom(t.movement),e.canvas.copyFrom(t.canvas),e.screen.copyFrom(t.screen),e.global.copyFrom(t.global),e.offset.copyFrom(t.offset)},t.prototype.copyWheelData=function(t,e){e.deltaMode=t.deltaMode,e.deltaX=t.deltaX,e.deltaY=t.deltaY,e.deltaZ=t.deltaZ},t.prototype.copyData=function(t,e){e.isTrusted=t.isTrusted,e.timeStamp=n$.now(),e.type=t.type,e.detail=t.detail,e.view=t.view,e.page.copyFrom(t.page),e.viewport.copyFrom(t.viewport)},t.prototype.allocateEvent=function(t){this.eventPool.has(t)||this.eventPool.set(t,[]);var e=this.eventPool.get(t).pop()||new t(this);return e.eventPhase=e.NONE,e.currentTarget=null,e.path=[],e.target=null,e},t.prototype.freeEvent=function(t){if(t.manager!==this)throw Error("It is illegal to free an event not managed by this EventBoundary!");var e=t.constructor;this.eventPool.has(e)||this.eventPool.set(e,[]),this.eventPool.get(e).push(t)},t.prototype.notifyTarget=function(t,e){e=null!=e?e:t.type;var n=t.eventPhase===t.CAPTURING_PHASE||t.eventPhase===t.AT_TARGET?"".concat(e,"capture"):e;this.notifyListeners(t,n),t.eventPhase===t.AT_TARGET&&this.notifyListeners(t,e)},t.prototype.notifyListeners=function(t,e){var n=t.currentTarget.emitter,r=n._events[e];if(r){if("fn"in r)r.once&&n.removeListener(e,r.fn,void 0,!0),r.fn.call(t.currentTarget||r.context,t);else for(var i=0;i=0;n--){var r=t[n];if(r===this.rootTarget||rb.isNode(r)&&r.parentNode===e)e=t[n];else break}return e},t.prototype.getCursor=function(t){for(var e=t;e;){var n=!!e.getAttribute&&e.getAttribute("cursor");if(n)return n;e=rb.isNode(e)&&e.parentNode}},t}(),rP=function(){function t(){}return t.prototype.getOrCreateCanvas=function(t,e){if(this.canvas)return this.canvas;if(t||rG.offscreenCanvas)this.canvas=t||rG.offscreenCanvas,this.context=this.canvas.getContext("2d",e);else try{this.canvas=new window.OffscreenCanvas(0,0),this.context=this.canvas.getContext("2d",e),this.context&&this.context.measureText||(this.canvas=document.createElement("canvas"),this.context=this.canvas.getContext("2d"))}catch(t){this.canvas=document.createElement("canvas"),this.context=this.canvas.getContext("2d",e)}return this.canvas.width=10,this.canvas.height=10,this.canvas},t.prototype.getOrCreateContext=function(t,e){return this.context||this.getOrCreateCanvas(t,e),this.context},t}();(E=X||(X={}))[E.CAMERA_CHANGED=0]="CAMERA_CHANGED",E[E.DISPLAY_OBJECT_CHANGED=1]="DISPLAY_OBJECT_CHANGED",E[E.NONE=2]="NONE";var rS=function(){function t(t,e){this.globalRuntime=t,this.context=e,this.inited=!1,this.stats={total:0,rendered:0},this.zIndexCounter=0,this.hooks={init:new rn,initAsync:new rt,dirtycheck:new rr,cull:new rr,beginFrame:new rn,beforeRender:new rn,render:new rn,afterRender:new rn,endFrame:new rn,destroy:new rn,pick:new re,pickSync:new rr,pointerDown:new rn,pointerUp:new rn,pointerMove:new rn,pointerOut:new rn,pointerOver:new rn,pointerWheel:new rn,pointerCancel:new rn,click:new rn}}return t.prototype.init=function(t){var e=this,n=(0,W.pi)((0,W.pi)({},this.globalRuntime),this.context);this.context.renderingPlugins.forEach(function(t){t.apply(n,e.globalRuntime)}),this.hooks.init.call(),0===this.hooks.initAsync.getCallbacksNum()?(this.inited=!0,t()):this.hooks.initAsync.promise().then(function(){e.inited=!0,t()})},t.prototype.getStats=function(){return this.stats},t.prototype.disableDirtyRectangleRendering=function(){return!this.context.config.renderer.getConfig().enableDirtyRectangleRendering||this.context.renderingContext.renderReasons.has(X.CAMERA_CHANGED)},t.prototype.render=function(t,e){var n=this;this.stats.total=0,this.stats.rendered=0,this.zIndexCounter=0;var r=this.context.renderingContext;if(this.globalRuntime.sceneGraphService.syncHierarchy(r.root),this.globalRuntime.sceneGraphService.triggerPendingEvents(),r.renderReasons.size&&this.inited){r.dirtyRectangleRenderingDisabled=this.disableDirtyRectangleRendering();var i=1===r.renderReasons.size&&r.renderReasons.has(X.CAMERA_CHANGED),o=!t.disableRenderHooks||!(t.disableRenderHooks&&i);o&&this.renderDisplayObject(r.root,t,r),this.hooks.beginFrame.call(),o&&r.renderListCurrentFrame.forEach(function(t){n.hooks.beforeRender.call(t),n.hooks.render.call(t),n.hooks.afterRender.call(t)}),this.hooks.endFrame.call(),r.renderListCurrentFrame=[],r.renderReasons.clear(),e()}},t.prototype.renderDisplayObject=function(t,e,n){var r=this,i=e.renderer.getConfig(),o=i.enableDirtyCheck,a=i.enableCulling;this.globalRuntime.enableCSSParsing&&this.globalRuntime.styleValueRegistry.recalc(t);var s=t.renderable,l=o?s.dirty||n.dirtyRectangleRenderingDisabled?t:null:t;if(l){var c=a?this.hooks.cull.call(l,this.context.camera):l;c&&(this.stats.rendered++,n.renderListCurrentFrame.push(c))}t.renderable.dirty=!1,t.sortable.renderOrder=this.zIndexCounter++,this.stats.total++;var u=t.sortable;u.dirty&&(this.sort(t,u),u.dirty=!1,u.dirtyChildren=[],u.dirtyReason=void 0),(u.sorted||t.childNodes).forEach(function(t){r.renderDisplayObject(t,e,n)})},t.prototype.sort=function(t,e){e.sorted&&e.dirtyReason!==V.Z_INDEX_CHANGED?e.dirtyChildren.forEach(function(n){if(-1===t.childNodes.indexOf(n)){var r=e.sorted.indexOf(n);r>=0&&e.sorted.splice(r,1)}else if(0===e.sorted.length)e.sorted.push(n);else{var i=function(t,e){for(var n=0,r=t.length;n>>1;0>nW(t[i],e)?n=i+1:r=i}return n}(e.sorted,n);e.sorted.splice(i,0,n)}}):e.sorted=t.childNodes.slice().sort(nW)},t.prototype.destroy=function(){this.inited=!1,this.hooks.destroy.call(),this.globalRuntime.sceneGraphService.clearPendingEvents()},t.prototype.dirtify=function(){this.context.renderingContext.renderReasons.add(X.DISPLAY_OBJECT_CHANGED)},t}(),rN=/\[\s*(.*)=(.*)\s*\]/,rC=function(){function t(){}return t.prototype.selectOne=function(t,e){var n=this;if(t.startsWith("."))return e.find(function(e){return((null==e?void 0:e.classList)||[]).indexOf(n.getIdOrClassname(t))>-1});if(t.startsWith("#"))return e.find(function(e){return e.id===n.getIdOrClassname(t)});if(!t.startsWith("["))return e.find(function(n){return e!==n&&n.nodeName===t});var r=this.getAttribute(t),i=r.name,o=r.value;return i?e.find(function(t){return e!==t&&("name"===i?t.name===o:n.attributeToString(t,i)===o)}):null},t.prototype.selectAll=function(t,e){var n=this;if(t.startsWith("."))return e.findAll(function(r){return e!==r&&((null==r?void 0:r.classList)||[]).indexOf(n.getIdOrClassname(t))>-1});if(t.startsWith("#"))return e.findAll(function(r){return e!==r&&r.id===n.getIdOrClassname(t)});if(!t.startsWith("["))return e.findAll(function(n){return e!==n&&n.nodeName===t});var r=this.getAttribute(t),i=r.name,o=r.value;return i?e.findAll(function(t){return e!==t&&("name"===i?t.name===o:n.attributeToString(t,i)===o)}):[]},t.prototype.is=function(t,e){if(t.startsWith("."))return e.className===this.getIdOrClassname(t);if(t.startsWith("#"))return e.id===this.getIdOrClassname(t);if(!t.startsWith("["))return e.nodeName===t;var n=this.getAttribute(t),r=n.name,i=n.value;return"name"===r?e.name===i:this.attributeToString(e,r)===i},t.prototype.getIdOrClassname=function(t){return t.substring(1)},t.prototype.getAttribute=function(t){var e=t.match(rN),n="",r="";return e&&e.length>2&&(n=e[1].replace(/"/g,""),r=e[2].replace(/"/g,"")),{name:n,value:r}},t.prototype.attributeToString=function(t,e){if(!t.getAttribute)return"";var n=t.getAttribute(e);return(0,tr.Z)(n)?"":n.toString?n.toString():""},t}(),rw=function(t){function e(e,n,r,i,o,a,s,l){var c=t.call(this,null)||this;return c.relatedNode=n,c.prevValue=r,c.newValue=i,c.attrName=o,c.attrChange=a,c.prevParsedValue=s,c.newParsedValue=l,c.type=e,c}return(0,W.ZT)(e,t),e.ADDITION=2,e.MODIFICATION=1,e.REMOVAL=3,e}(rv);function rM(t){var e=t.renderable;e&&(e.renderBoundsDirty=!0,e.boundsDirty=!0)}(x=H||(H={})).REPARENT="reparent",x.DESTROY="destroy",x.ATTR_MODIFIED="DOMAttrModified",x.INSERTED="DOMNodeInserted",x.REMOVED="removed",x.MOUNTED="DOMNodeInsertedIntoDocument",x.UNMOUNTED="DOMNodeRemovedFromDocument",x.BOUNDS_CHANGED="bounds-changed",x.CULLED="culled";var rk=new rw(H.REPARENT,null,"","","",0,"",""),rR=function(){function t(t){var e,n,r,i,o,a,s,l,c,u,h,p,f=this;this.runtime=t,this.pendingEvents=[],this.boundsChangedEvent=new rE(H.BOUNDS_CHANGED),this.rotate=(e=Q.Ue(),function(t,n,r,i){void 0===r&&(r=0),void 0===i&&(i=0),"number"==typeof n&&(n=K.al(n,r,i));var o=t.transformable;if(null!==t.parentNode&&t.parentNode.transformable){var a=Q.Ue();Q.Su(a,n[0],n[1],n[2]);var s=f.getRotation(t),l=f.getRotation(t.parentNode);Q.JG(e,l),Q.U_(e,e),Q.Jp(a,e,a),Q.Jp(o.localRotation,a,s),Q.Fv(o.localRotation,o.localRotation),f.dirtifyLocal(t,o)}else f.rotateLocal(t,n)}),this.rotateLocal=(n=Q.Ue(),function(t,e,r,i){void 0===r&&(r=0),void 0===i&&(i=0),"number"==typeof e&&(e=K.al(e,r,i));var o=t.transformable;Q.Su(n,e[0],e[1],e[2]),Q.dC(o.localRotation,o.localRotation,n),f.dirtifyLocal(t,o)}),this.setEulerAngles=(r=Q.Ue(),function(t,e,n,i){void 0===n&&(n=0),void 0===i&&(i=0),"number"==typeof e&&(e=K.al(e,n,i));var o=t.transformable;if(null!==t.parentNode&&t.parentNode.transformable){Q.Su(o.localRotation,e[0],e[1],e[2]);var a=f.getRotation(t.parentNode);Q.JG(r,Q.U_(Q.Ue(),a)),Q.dC(o.localRotation,o.localRotation,r),f.dirtifyLocal(t,o)}else f.setLocalEulerAngles(t,e)}),this.translateLocal=function(t,e,n,r){void 0===n&&(n=0),void 0===r&&(r=0),"number"==typeof e&&(e=K.al(e,n,r));var i=t.transformable;K.fS(e,K.Ue())||(K.VC(e,e,i.localRotation),K.IH(i.localPosition,i.localPosition,e),f.dirtifyLocal(t,i))},this.setPosition=(i=q.create(),o=K.Ue(),function(t,e){var n=t.transformable;if(o[0]=e[0],o[1]=e[1],o[2]=e[2]||0,!K.fS(f.getPosition(t),o)){if(K.JG(n.position,o),null!==t.parentNode&&t.parentNode.transformable){var r=t.parentNode.transformable;q.copy(i,r.worldTransform),q.invert(i,i),K.fF(n.localPosition,o,i)}else K.JG(n.localPosition,o);f.dirtifyLocal(t,n)}}),this.setLocalPosition=(a=K.Ue(),function(t,e){var n=t.transformable;a[0]=e[0],a[1]=e[1],a[2]=e[2]||0,K.fS(n.localPosition,a)||(K.JG(n.localPosition,a),f.dirtifyLocal(t,n))}),this.translate=(s=K.Ue(),l=K.Ue(),c=K.Ue(),function(t,e,n,r){void 0===n&&(n=0),void 0===r&&(r=0),"number"==typeof e&&(e=K.t8(l,e,n,r)),K.fS(e,s)||(K.IH(c,f.getPosition(t),e),f.setPosition(t,c))}),this.setRotation=function(){var t=Q.Ue();return function(e,n,r,i,o){var a=e.transformable;if("number"==typeof n&&(n=Q.al(n,r,i,o)),null!==e.parentNode&&e.parentNode.transformable){var s=f.getRotation(e.parentNode);Q.JG(t,s),Q.U_(t,t),Q.Jp(a.localRotation,t,n),Q.Fv(a.localRotation,a.localRotation),f.dirtifyLocal(e,a)}else f.setLocalRotation(e,n)}},this.displayObjectDependencyMap=new WeakMap,this.calcLocalTransform=(u=q.create(),h=K.Ue(),p=Q.al(0,0,0,1),function(t){if(0!==t.localSkew[0]||0!==t.localSkew[1]){if(q.fromRotationTranslationScaleOrigin(t.localTransform,t.localRotation,t.localPosition,K.al(1,1,1),t.origin),0!==t.localSkew[0]||0!==t.localSkew[1]){var e=q.identity(u);e[4]=Math.tan(t.localSkew[0]),e[1]=Math.tan(t.localSkew[1]),q.multiply(t.localTransform,t.localTransform,e)}var n=q.fromRotationTranslationScaleOrigin(u,p,h,t.localScale,t.origin);q.multiply(t.localTransform,t.localTransform,n)}else q.fromRotationTranslationScaleOrigin(t.localTransform,t.localRotation,t.localPosition,t.localScale,t.origin)})}return t.prototype.matches=function(t,e){return this.runtime.sceneGraphSelector.is(t,e)},t.prototype.querySelector=function(t,e){return this.runtime.sceneGraphSelector.selectOne(t,e)},t.prototype.querySelectorAll=function(t,e){return this.runtime.sceneGraphSelector.selectAll(t,e)},t.prototype.attach=function(t,e,n){var r,i,o=!1;t.parentNode&&(o=t.parentNode!==e,this.detach(t)),t.parentNode=e,(0,tr.Z)(n)?t.parentNode.childNodes.push(t):t.parentNode.childNodes.splice(n,0,t);var a=e.sortable;((null===(r=null==a?void 0:a.sorted)||void 0===r?void 0:r.length)||(null===(i=t.style)||void 0===i?void 0:i.zIndex))&&(-1===a.dirtyChildren.indexOf(t)&&a.dirtyChildren.push(t),a.dirty=!0,a.dirtyReason=V.ADDED);var s=t.transformable;s&&this.dirtifyWorld(t,s),s.frozen&&this.unfreezeParentToRoot(t),o&&t.dispatchEvent(rk)},t.prototype.detach=function(t){var e,n;if(t.parentNode){var r=t.transformable,i=t.parentNode.sortable;((null===(e=null==i?void 0:i.sorted)||void 0===e?void 0:e.length)||(null===(n=t.style)||void 0===n?void 0:n.zIndex))&&(-1===i.dirtyChildren.indexOf(t)&&i.dirtyChildren.push(t),i.dirty=!0,i.dirtyReason=V.REMOVED);var o=t.parentNode.childNodes.indexOf(t);o>-1&&t.parentNode.childNodes.splice(o,1),r&&this.dirtifyWorld(t,r),t.parentNode=null}},t.prototype.getOrigin=function(t){return t.transformable.origin},t.prototype.setOrigin=function(t,e,n,r){void 0===n&&(n=0),void 0===r&&(r=0),"number"==typeof e&&(e=[e,n,r]);var i=t.transformable;if(e[0]!==i.origin[0]||e[1]!==i.origin[1]||e[2]!==i.origin[2]){var o=i.origin;o[0]=e[0],o[1]=e[1],o[2]=e[2]||0,this.dirtifyLocal(t,i)}},t.prototype.setLocalEulerAngles=function(t,e,n,r){void 0===n&&(n=0),void 0===r&&(r=0),"number"==typeof e&&(e=K.al(e,n,r));var i=t.transformable;Q.Su(i.localRotation,e[0],e[1],e[2]),this.dirtifyLocal(t,i)},t.prototype.scaleLocal=function(t,e){var n=t.transformable;K.Jp(n.localScale,n.localScale,K.al(e[0],e[1],e[2]||1)),this.dirtifyLocal(t,n)},t.prototype.setLocalScale=function(t,e){var n=t.transformable,r=K.al(e[0],e[1],e[2]||n.localScale[2]);K.fS(r,n.localScale)||(K.JG(n.localScale,r),this.dirtifyLocal(t,n))},t.prototype.setLocalRotation=function(t,e,n,r,i){"number"==typeof e&&(e=Q.al(e,n,r,i));var o=t.transformable;Q.JG(o.localRotation,e),this.dirtifyLocal(t,o)},t.prototype.setLocalSkew=function(t,e,n){"number"==typeof e&&(e=tt.al(e,n));var r=t.transformable;tt.JG(r.localSkew,e),this.dirtifyLocal(t,r)},t.prototype.dirtifyLocal=function(t,e){e.localDirtyFlag||(e.localDirtyFlag=!0,e.dirtyFlag||this.dirtifyWorld(t,e))},t.prototype.dirtifyWorld=function(t,e){e.dirtyFlag||this.unfreezeParentToRoot(t),this.dirtifyWorldInternal(t,e),this.dirtifyToRoot(t,!0)},t.prototype.triggerPendingEvents=function(){var t=this,e=new Set,n=function(n,r){n.isConnected&&!e.has(n.entity)&&(t.boundsChangedEvent.detail=r,t.boundsChangedEvent.target=n,n.isMutationObserved?n.dispatchEvent(t.boundsChangedEvent):n.ownerDocument.defaultView.dispatchEvent(t.boundsChangedEvent,!0),e.add(n.entity))};this.pendingEvents.forEach(function(t){var e=(0,W.CR)(t,2),r=e[0],i=e[1];i.affectChildren?r.forEach(function(t){n(t,i)}):n(r,i)}),this.clearPendingEvents(),e.clear()},t.prototype.clearPendingEvents=function(){this.pendingEvents=[]},t.prototype.dirtifyToRoot=function(t,e){void 0===e&&(e=!1);var n=t;for(n.renderable&&(n.renderable.dirty=!0);n;)rM(n),n=n.parentNode;e&&t.forEach(function(t){rM(t)}),this.informDependentDisplayObjects(t),this.pendingEvents.push([t,{affectChildren:e}])},t.prototype.updateDisplayObjectDependency=function(t,e,n,r){if(e&&e!==n){var i=this.displayObjectDependencyMap.get(e);if(i&&i[t]){var o=i[t].indexOf(r);i[t].splice(o,1)}}if(n){var a=this.displayObjectDependencyMap.get(n);a||(this.displayObjectDependencyMap.set(n,{}),a=this.displayObjectDependencyMap.get(n)),a[t]||(a[t]=[]),a[t].push(r)}},t.prototype.informDependentDisplayObjects=function(t){var e=this,n=this.displayObjectDependencyMap.get(t);n&&Object.keys(n).forEach(function(t){n[t].forEach(function(n){e.dirtifyToRoot(n,!0),n.dispatchEvent(new rw(H.ATTR_MODIFIED,n,e,e,t,rw.MODIFICATION,e,e)),n.isCustomElement&&n.isConnected&&n.attributeChangedCallback&&n.attributeChangedCallback(t,e,e)})})},t.prototype.getPosition=function(t){var e=t.transformable;return q.getTranslation(e.position,this.getWorldTransform(t,e))},t.prototype.getRotation=function(t){var e=t.transformable;return q.getRotation(e.rotation,this.getWorldTransform(t,e))},t.prototype.getScale=function(t){var e=t.transformable;return q.getScaling(e.scaling,this.getWorldTransform(t,e))},t.prototype.getWorldTransform=function(t,e){return void 0===e&&(e=t.transformable),(e.localDirtyFlag||e.dirtyFlag)&&(t.parentNode&&t.parentNode.transformable&&this.getWorldTransform(t.parentNode),this.sync(t,e)),e.worldTransform},t.prototype.getLocalPosition=function(t){return t.transformable.localPosition},t.prototype.getLocalRotation=function(t){return t.transformable.localRotation},t.prototype.getLocalScale=function(t){return t.transformable.localScale},t.prototype.getLocalSkew=function(t){return t.transformable.localSkew},t.prototype.getLocalTransform=function(t){var e=t.transformable;return e.localDirtyFlag&&(this.calcLocalTransform(e),e.localDirtyFlag=!1),e.localTransform},t.prototype.setLocalTransform=function(t,e){var n=q.getTranslation(K.Ue(),e),r=q.getRotation(Q.Ue(),e),i=q.getScaling(K.Ue(),e);this.setLocalScale(t,i),this.setLocalPosition(t,n),this.setLocalRotation(t,r)},t.prototype.resetLocalTransform=function(t){this.setLocalScale(t,[1,1,1]),this.setLocalPosition(t,[0,0,0]),this.setLocalEulerAngles(t,[0,0,0]),this.setLocalSkew(t,[0,0])},t.prototype.getTransformedGeometryBounds=function(t,e,n){void 0===e&&(e=!1);var r=this.getGeometryBounds(t,e);if(tX.isEmpty(r))return null;var i=n||new tX;return i.setFromTransformedAABB(r,this.getWorldTransform(t)),i},t.prototype.getGeometryBounds=function(t,e){void 0===e&&(e=!1);var n=t.geometry;return(e?n.renderBounds:n.contentBounds||null)||new tX},t.prototype.getBounds=function(t,e){var n=this;void 0===e&&(e=!1);var r=t.renderable;if(!r.boundsDirty&&!e&&r.bounds)return r.bounds;if(!r.renderBoundsDirty&&e&&r.renderBounds)return r.renderBounds;var i=e?r.renderBounds:r.bounds,o=this.getTransformedGeometryBounds(t,e,i);if(t.childNodes.forEach(function(t){var r=n.getBounds(t,e);r&&(o?o.add(r):(o=i||new tX).update(r.center,r.halfExtents))}),e){var a=nz(t);if(a){var s=a.parsedStyle.clipPath.getBounds(e);o?s&&(o=s.intersection(o)):o=s}}return o||(o=new tX),o&&(e?r.renderBounds=o:r.bounds=o),e?r.renderBoundsDirty=!1:r.boundsDirty=!1,o},t.prototype.getLocalBounds=function(t){if(t.parentNode){var e=q.create();t.parentNode.transformable&&(e=q.invert(q.create(),this.getWorldTransform(t.parentNode)));var n=this.getBounds(t);if(!tX.isEmpty(n)){var r=new tX;return r.setFromTransformedAABB(n,e),r}}return this.getBounds(t)},t.prototype.getBoundingClientRect=function(t){var e,n,r,i=this.getGeometryBounds(t);tX.isEmpty(i)||(r=new tX).setFromTransformedAABB(i,this.getWorldTransform(t));var o=null===(n=null===(e=t.ownerDocument)||void 0===e?void 0:e.defaultView)||void 0===n?void 0:n.getContextService().getBoundingClientRect();if(r){var a=(0,W.CR)(r.getMin(),2),s=a[0],l=a[1],c=(0,W.CR)(r.getMax(),2),u=c[0],h=c[1];return new tz(s+((null==o?void 0:o.left)||0),l+((null==o?void 0:o.top)||0),u-s,h-l)}return new tz((null==o?void 0:o.left)||0,(null==o?void 0:o.top)||0,0,0)},t.prototype.dirtifyWorldInternal=function(t,e){var n=this;if(!e.dirtyFlag){e.dirtyFlag=!0,e.frozen=!1,t.childNodes.forEach(function(t){var e=t.transformable;e.dirtyFlag||n.dirtifyWorldInternal(t,e)});var r=t.renderable;r&&(r.renderBoundsDirty=!0,r.boundsDirty=!0,r.dirty=!0)}},t.prototype.syncHierarchy=function(t){var e=t.transformable;if(!e.frozen){e.frozen=!0,(e.localDirtyFlag||e.dirtyFlag)&&this.sync(t,e);for(var n=t.childNodes,r=0;rs;--p){for(var v=0;v=0;l--){var c=s[l].trim();!ro.test(c)&&0>ri.indexOf(c)&&(c='"'.concat(c,'"')),s[l]=c}return"".concat(r," ").concat(i," ").concat(o," ").concat(a," ").concat(s.join(","))}(e),d=this.measureFont(f,n);0===d.fontSize&&(d.fontSize=r,d.ascent=r);var v=this.runtime.offscreenCanvasCreator.getOrCreateContext(n);v.font=f,e.isOverflowing=!1;var y=(i?this.wordWrap(t,e,n):t).split(/(?:\r\n|\r|\n)/),g=Array(y.length),m=0;if(u){u.getTotalLength();for(var E=0;E=s){e.isOverflowing=!0;break}d=0,p[f]="";continue}if(d>0&&d+P>u){if(f+1>=s){if(e.isOverflowing=!0,g>0&&g<=u){for(var S=p[f].length,N=0,C=S,w=0;wu){C=w;break}N+=M}p[f]=(p[f]||"").slice(0,C)+h}break}if(d=0,p[++f]="",this.isBreakingSpace(x))continue;this.canBreakInLastChar(x)||(p=this.trimToBreakable(p),d=this.sumTextWidthByCache(p[f]||"",v)),this.shouldBreakByKinsokuShorui(x,T)&&(p=this.trimByKinsokuShorui(p),d+=y(b||""))}d+=P,p[f]=(p[f]||"")+x}return p.join("\n")},t.prototype.isBreakingSpace=function(t){return"string"==typeof t&&rA.BreakingSpaces.indexOf(t.charCodeAt(0))>=0},t.prototype.isNewline=function(t){return"string"==typeof t&&rA.Newlines.indexOf(t.charCodeAt(0))>=0},t.prototype.trimToBreakable=function(t){var e=(0,W.ev)([],(0,W.CR)(t),!1),n=e[e.length-2],r=this.findBreakableIndex(n);if(-1===r||!n)return e;var i=n.slice(r,r+1),o=this.isBreakingSpace(i),a=r+1,s=r+(o?0:1);return e[e.length-1]+=n.slice(a,n.length),e[e.length-2]=n.slice(0,s),e},t.prototype.canBreakInLastChar=function(t){return!(t&&rO.test(t))},t.prototype.sumTextWidthByCache=function(t,e){return t.split("").reduce(function(t,n){if(!e[n])throw Error("cannot count the word without cache");return t+e[n]},0)},t.prototype.findBreakableIndex=function(t){for(var e=t.length-1;e>=0;e--)if(!rO.test(t[e]))return e;return -1},t.prototype.getFromCache=function(t,e,n,r){var i=n[t];if("number"!=typeof i){var o=t.length*e;i=r.measureText(t).width+o,n[t]=i}return i},t}(),rG={},r_=(T=new rf,P=new rp,(b={})[M.CIRCLE]=new rl,b[M.ELLIPSE]=new rc,b[M.RECT]=T,b[M.IMAGE]=T,b[M.GROUP]=T,b[M.LINE]=new ru,b[M.TEXT]=new rd(rG),b[M.POLYLINE]=P,b[M.POLYGON]=P,b[M.PATH]=new rh,b[M.HTML]=null,b[M.MESH]=null,b),rF=(N=new nC,C=new nk,(S={})[Y.PERCENTAGE]=null,S[Y.NUMBER]=new nG,S[Y.ANGLE]=new nS,S[Y.DEFINED_PATH]=new nN,S[Y.PAINT]=N,S[Y.COLOR]=N,S[Y.FILTER]=new nw,S[Y.LENGTH]=C,S[Y.LENGTH_PERCENTAGE]=C,S[Y.LENGTH_PERCENTAGE_12]=new nR,S[Y.LENGTH_PERCENTAGE_14]=new nA,S[Y.COORDINATE]=new nI,S[Y.OFFSET_DISTANCE]=new n_,S[Y.OPACITY_VALUE]=new nF,S[Y.PATH]=new nB,S[Y.LIST_OF_POINTS]=new nU,S[Y.SHADOW_BLUR]=new nZ,S[Y.TEXT]=new nV,S[Y.TEXT_TRANSFORM]=new nY,S[Y.TRANSFORM]=new ra,S[Y.TRANSFORM_ORIGIN]=new function(){this.parser=ny},S[Y.Z_INDEX]=new rs,S[Y.MARKER]=new nD,S);rG.CameraContribution=t$,rG.AnimationTimeline=null,rG.EasingFunction=null,rG.offscreenCanvasCreator=new rP,rG.nativeHTMLMap=new WeakMap,rG.sceneGraphSelector=new rC,rG.sceneGraphService=new rR(rG),rG.textService=new rD(rG),rG.geometryUpdaterFactory=r_,rG.CSSPropertySyntaxFactory=rF,rG.styleValueRegistry=new nP(rG),rG.layoutRegistry=null,rG.globalThis="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0!==n.g?n.g:{},rG.enableCSSParsing=!0,rG.enableDataset=!1,rG.enableStyleSyntax=!0;var rB=0,rU=new rw(H.INSERTED,null,"","","",0,"",""),rZ=new rw(H.REMOVED,null,"","","",0,"",""),rV=new rE(H.DESTROY),rY=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.entity=rB++,e.renderable={bounds:void 0,boundsDirty:!0,renderBounds:void 0,renderBoundsDirty:!0,dirtyRenderBounds:void 0,dirty:!1},e.cullable={strategy:Z.Standard,visibilityPlaneMask:-1,visible:!0,enable:!0},e.transformable={dirtyFlag:!1,localDirtyFlag:!1,frozen:!1,localPosition:[0,0,0],localRotation:[0,0,0,1],localScale:[1,1,1],localTransform:[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1],localSkew:[0,0],position:[0,0,0],rotation:[0,0,0,1],scaling:[1,1,1],worldTransform:[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1],origin:[0,0,0]},e.sortable={dirty:!1,sorted:void 0,renderOrder:0,dirtyChildren:[],dirtyReason:void 0},e.geometry={contentBounds:void 0,renderBounds:void 0},e.rBushNode={aabb:void 0},e.namespaceURI="g",e.scrollLeft=0,e.scrollTop=0,e.clientTop=0,e.clientLeft=0,e.destroyed=!1,e.style={},e.computedStyle=rG.enableCSSParsing?{anchor:eu,opacity:eu,fillOpacity:eu,strokeOpacity:eu,fill:eu,stroke:eu,transform:eu,transformOrigin:eu,visibility:eu,pointerEvents:eu,lineWidth:eu,lineCap:eu,lineJoin:eu,increasedLineWidthForHitTesting:eu,fontSize:eu,fontFamily:eu,fontStyle:eu,fontWeight:eu,fontVariant:eu,textAlign:eu,textBaseline:eu,textTransform:eu,zIndex:eu,filter:eu,shadowType:eu}:null,e.parsedStyle={},e.attributes={},e}return(0,W.ZT)(e,t),Object.defineProperty(e.prototype,"className",{get:function(){return this.getAttribute("class")||""},set:function(t){this.setAttribute("class",t)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"classList",{get:function(){return this.className.split(" ").filter(function(t){return""!==t})},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tagName",{get:function(){return this.nodeName},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"children",{get:function(){return this.childNodes},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"childElementCount",{get:function(){return this.childNodes.length},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"firstElementChild",{get:function(){return this.firstChild},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"lastElementChild",{get:function(){return this.lastChild},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"parentElement",{get:function(){return this.parentNode},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"nextSibling",{get:function(){if(this.parentNode){var t=this.parentNode.childNodes.indexOf(this);return this.parentNode.childNodes[t+1]||null}return null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"previousSibling",{get:function(){if(this.parentNode){var t=this.parentNode.childNodes.indexOf(this);return this.parentNode.childNodes[t-1]||null}return null},enumerable:!1,configurable:!0}),e.prototype.cloneNode=function(t){throw Error(tK)},e.prototype.appendChild=function(t,e){var n;if(t.destroyed)throw Error("Cannot append a destroyed element.");return rG.sceneGraphService.attach(t,this,e),(null===(n=this.ownerDocument)||void 0===n?void 0:n.defaultView)&&this.ownerDocument.defaultView.mountChildren(t),rU.relatedNode=this,t.dispatchEvent(rU),t},e.prototype.insertBefore=function(t,e){if(e){var n=this.childNodes.indexOf(e);this.appendChild(t,n-1)}else this.appendChild(t);return t},e.prototype.replaceChild=function(t,e){var n=this.childNodes.indexOf(e);return this.removeChild(e),this.appendChild(t,n),e},e.prototype.removeChild=function(t){var e;return rZ.relatedNode=this,t.dispatchEvent(rZ),(null===(e=t.ownerDocument)||void 0===e?void 0:e.defaultView)&&t.ownerDocument.defaultView.unmountChildren(t),rG.sceneGraphService.detach(t),t},e.prototype.removeChildren=function(){for(var t=this.childNodes.length-1;t>=0;t--){var e=this.childNodes[t];this.removeChild(e)}},e.prototype.destroyChildren=function(){for(var t=this.childNodes.length-1;t>=0;t--){var e=this.childNodes[t];e.childNodes.length&&e.destroyChildren(),e.destroy()}},e.prototype.matches=function(t){return rG.sceneGraphService.matches(t,this)},e.prototype.getElementById=function(t){return rG.sceneGraphService.querySelector("#".concat(t),this)},e.prototype.getElementsByName=function(t){return rG.sceneGraphService.querySelectorAll('[name="'.concat(t,'"]'),this)},e.prototype.getElementsByClassName=function(t){return rG.sceneGraphService.querySelectorAll(".".concat(t),this)},e.prototype.getElementsByTagName=function(t){return rG.sceneGraphService.querySelectorAll(t,this)},e.prototype.querySelector=function(t){return rG.sceneGraphService.querySelector(t,this)},e.prototype.querySelectorAll=function(t){return rG.sceneGraphService.querySelectorAll(t,this)},e.prototype.closest=function(t){var e=this;do{if(rG.sceneGraphService.matches(t,e))return e;e=e.parentElement}while(null!==e);return null},e.prototype.find=function(t){var e=this,n=null;return this.forEach(function(r){return!!(r!==e&&t(r))&&(n=r,!0)}),n},e.prototype.findAll=function(t){var e=this,n=[];return this.forEach(function(r){r!==e&&t(r)&&n.push(r)}),n},e.prototype.after=function(){for(var t=this,e=[],n=0;n1){var n=t[0].currentPoint,r=t[1].currentPoint,i=t[1].startTangent;e=[],i?(e.push([n[0]-i[0],n[1]-i[1]]),e.push([n[0],n[1]])):(e.push([r[0],r[1]]),e.push([n[0],n[1]]))}return e},e.prototype.getEndTangent=function(){var t=this.parsedStyle.path.segments,e=t.length,n=[];if(e>1){var r=t[e-2].currentPoint,i=t[e-1].currentPoint,o=t[e-1].endTangent;n=[],o?(n.push([i[0]-o[0],i[1]-o[1]]),n.push([i[0],i[1]])):(n.push([r[0],r[1]]),n.push([i[0],i[1]]))}return n},e}(rJ),r8=function(t){function e(e){var n=this;void 0===e&&(e={});var r=e.style,i=(0,W._T)(e,["style"]);(n=t.call(this,(0,W.pi)({type:M.POLYGON,style:rG.enableCSSParsing?(0,W.pi)({points:"",miterLimit:"",isClosed:!0},r):(0,W.pi)({},r),initialParsedStyle:rG.enableCSSParsing?null:{points:{points:[],totalLength:0,segments:[]},miterLimit:4,isClosed:!0}},i))||this).markerStartAngle=0,n.markerEndAngle=0,n.markerMidList=[];var o=n.parsedStyle,a=o.markerStart,s=o.markerEnd,l=o.markerMid;return a&&rX(a)&&(n.markerStartAngle=a.getLocalEulerAngles(),n.appendChild(a)),l&&rX(l)&&n.placeMarkerMid(l),s&&rX(s)&&(n.markerEndAngle=s.getLocalEulerAngles(),n.appendChild(s)),n.transformMarker(!0),n.transformMarker(!1),n}return(0,W.ZT)(e,t),e.prototype.attributeChangedCallback=function(t,e,n,r,i){"points"===t?(this.transformMarker(!0),this.transformMarker(!1),this.placeMarkerMid(this.parsedStyle.markerMid)):"markerStartOffset"===t||"markerEndOffset"===t?(this.transformMarker(!0),this.transformMarker(!1)):"markerStart"===t?(r&&rX(r)&&(this.markerStartAngle=0,r.remove()),i&&rX(i)&&(this.markerStartAngle=i.getLocalEulerAngles(),this.appendChild(i),this.transformMarker(!0))):"markerEnd"===t?(r&&rX(r)&&(this.markerEndAngle=0,r.remove()),i&&rX(i)&&(this.markerEndAngle=i.getLocalEulerAngles(),this.appendChild(i),this.transformMarker(!1))):"markerMid"===t&&this.placeMarkerMid(i)},e.prototype.transformMarker=function(t){var e,n,r,i,o,a,s=this.parsedStyle,l=s.markerStart,c=s.markerEnd,u=s.markerStartOffset,h=s.markerEndOffset,p=s.points.points,f=s.defX,d=s.defY,v=t?l:c;if(v&&rX(v)){var y=0;if(r=p[0][0]-f,i=p[0][1]-d,t)e=p[1][0]-p[0][0],n=p[1][1]-p[0][1],o=u||0,a=this.markerStartAngle;else{var g=p.length;this.parsedStyle.isClosed?(e=p[g-1][0]-p[0][0],n=p[g-1][1]-p[0][1]):(r=p[g-1][0]-f,i=p[g-1][1]-d,e=p[g-2][0]-p[g-1][0],n=p[g-2][1]-p[g-1][1]),o=h||0,a=this.markerEndAngle}y=Math.atan2(n,e),v.setLocalEulerAngles(180*y/Math.PI+a),v.setLocalPosition(r+Math.cos(y)*o,i+Math.sin(y)*o)}},e.prototype.placeMarkerMid=function(t){var e=this.parsedStyle,n=e.points.points,r=e.defX,i=e.defY;if(this.markerMidList.forEach(function(t){t.remove()}),this.markerMidList=[],t&&rX(t))for(var o=1;o<(this.parsedStyle.isClosed?n.length:n.length-1);o++){var a=n[o][0]-r,s=n[o][1]-i,l=1===o?t:t.cloneNode(!0);this.markerMidList.push(l),this.appendChild(l),l.setLocalPosition(a,s)}},e}(rJ),r6=function(t){function e(e){void 0===e&&(e={});var n=e.style,r=(0,W._T)(e,["style"]);return t.call(this,(0,W.pi)({type:M.POLYLINE,style:rG.enableCSSParsing?(0,W.pi)({points:"",miterLimit:"",isClosed:!1},n):(0,W.pi)({},n),initialParsedStyle:rG.enableCSSParsing?null:{points:{points:[],totalLength:0,segments:[]},miterLimit:4,isClosed:!1}},r))||this}return(0,W.ZT)(e,t),e.prototype.getTotalLength=function(){return this.parsedStyle.points.totalLength},e.prototype.getPointAtLength=function(t,e){return void 0===e&&(e=!1),this.getPoint(t/this.getTotalLength(),e)},e.prototype.getPoint=function(t,e){void 0===e&&(e=!1);var n=this.parsedStyle,r=n.defX,i=n.defY,o=n.points,a=o.points,s=o.segments,l=0,c=0;s.forEach(function(e,n){t>=e[0]&&t<=e[1]&&(l=(t-e[0])/(e[1]-e[0]),c=n)});var u=(0,tP.U4)(a[c][0],a[c][1],a[c+1][0],a[c+1][1],l),h=u.x,p=u.y,f=K.fF(K.Ue(),K.al(h-r,p-i,0),e?this.getWorldTransform():this.getLocalTransform());return new tW(f[0],f[1])},e.prototype.getStartTangent=function(){var t=this.parsedStyle.points.points,e=[];return e.push([t[1][0],t[1][1]]),e.push([t[0][0],t[0][1]]),e},e.prototype.getEndTangent=function(){var t=this.parsedStyle.points.points,e=t.length-1,n=[];return n.push([t[e-1][0],t[e-1][1]]),n.push([t[e][0],t[e][1]]),n},e}(r8),r7=function(t){function e(e){void 0===e&&(e={});var n=e.style,r=(0,W._T)(e,["style"]);return t.call(this,(0,W.pi)({type:M.RECT,style:rG.enableCSSParsing?(0,W.pi)({x:"",y:"",width:"",height:"",radius:""},n):(0,W.pi)({},n)},r))||this}return(0,W.ZT)(e,t),e}(rJ),it=function(t){function e(e){void 0===e&&(e={});var n=e.style,r=(0,W._T)(e,["style"]);return t.call(this,(0,W.pi)({type:M.TEXT,style:rG.enableCSSParsing?(0,W.pi)({x:"",y:"",text:"",fontSize:"",fontFamily:"",fontStyle:"",fontWeight:"",fontVariant:"",textAlign:"",textBaseline:"",textTransform:"",fill:"black",letterSpacing:"",lineHeight:"",miterLimit:"",wordWrap:!1,wordWrapWidth:0,leading:0,dx:"",dy:""},n):(0,W.pi)({fill:"black"},n),initialParsedStyle:rG.enableCSSParsing?{}:{x:0,y:0,fontSize:16,fontFamily:"sans-serif",fontStyle:"normal",fontWeight:"normal",fontVariant:"normal",lineHeight:0,letterSpacing:0,textBaseline:"alphabetic",textAlign:"start",wordWrap:!1,wordWrapWidth:0,leading:0,dx:0,dy:0}},r))||this}return(0,W.ZT)(e,t),e.prototype.getComputedTextLength=function(){var t;return(null===(t=this.parsedStyle.metrics)||void 0===t?void 0:t.maxLineWidth)||0},e.prototype.getLineBoundingRects=function(){var t;return(null===(t=this.parsedStyle.metrics)||void 0===t?void 0:t.lineMetrics)||[]},e.prototype.isOverflowing=function(){return!!this.parsedStyle.isOverflowing},e}(rJ),ie=function(){function t(){this.registry={},this.define(M.CIRCLE,rQ),this.define(M.ELLIPSE,r1),this.define(M.RECT,r7),this.define(M.IMAGE,r5),this.define(M.LINE,r4),this.define(M.GROUP,r2),this.define(M.PATH,r9),this.define(M.POLYGON,r8),this.define(M.POLYLINE,r6),this.define(M.TEXT,it),this.define(M.HTML,r3)}return t.prototype.define=function(t,e){this.registry[t]=e},t.prototype.get=function(t){return this.registry[t]},t}(),ir=function(t){function e(){var e=t.call(this)||this;e.defaultView=null,e.ownerDocument=null,e.nodeName="document";try{e.timeline=new rG.AnimationTimeline(e)}catch(t){}var n={};return nm.forEach(function(t){var e=t.n,r=t.inh,i=t.d;r&&i&&(n[e]=ee(i)?i(M.GROUP):i)}),e.documentElement=new r2({id:"g-root",style:n}),e.documentElement.ownerDocument=e,e.documentElement.parentNode=e,e.childNodes=[e.documentElement],e}return(0,W.ZT)(e,t),Object.defineProperty(e.prototype,"children",{get:function(){return this.childNodes},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"childElementCount",{get:function(){return this.childNodes.length},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"firstElementChild",{get:function(){return this.firstChild},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"lastElementChild",{get:function(){return this.lastChild},enumerable:!1,configurable:!0}),e.prototype.createElement=function(t,e){if("svg"===t)return this.documentElement;var n=this.defaultView.customElements.get(t);n||(console.warn("Unsupported tagName: ",t),n="tspan"===t?it:r2);var r=new n(e);return r.ownerDocument=this,r},e.prototype.createElementNS=function(t,e,n){return this.createElement(e,n)},e.prototype.cloneNode=function(t){throw Error(tK)},e.prototype.destroy=function(){try{this.documentElement.destroyChildren(),this.timeline.destroy()}catch(t){}},e.prototype.elementsFromBBox=function(t,e,n,r){var i=this.defaultView.context.rBushRoot.search({minX:t,minY:e,maxX:n,maxY:r}),o=[];return i.forEach(function(t){var e=t.displayObject,n=["auto","visiblepainted","visiblefill","visiblestroke","visible"].includes(e.parsedStyle.pointerEvents);(!n||n&&e.isVisible())&&!e.isCulled()&&e.isInteractive()&&o.push(e)}),o.sort(function(t,e){return e.sortable.renderOrder-t.sortable.renderOrder}),o},e.prototype.elementFromPointSync=function(t,e){var n=this.defaultView.canvas2Viewport({x:t,y:e}),r=n.x,i=n.y,o=this.defaultView.getConfig(),a=o.width,s=o.height;if(r<0||i<0||r>a||i>s)return null;var l=this.defaultView.viewport2Client({x:r,y:i}),c=l.x,u=l.y,h=this.defaultView.getRenderingService().hooks.pickSync.call({topmost:!0,position:{x:t,y:e,viewportX:r,viewportY:i,clientX:c,clientY:u},picked:[]}).picked;return h&&h[0]||this.documentElement},e.prototype.elementFromPoint=function(t,e){return(0,W.mG)(this,void 0,void 0,function(){var n,r,i,o,a,s,l,c,u,h;return(0,W.Jh)(this,function(p){switch(p.label){case 0:if(r=(n=this.defaultView.canvas2Viewport({x:t,y:e})).x,i=n.y,a=(o=this.defaultView.getConfig()).width,s=o.height,r<0||i<0||r>a||i>s)return[2,null];return c=(l=this.defaultView.viewport2Client({x:r,y:i})).x,u=l.y,[4,this.defaultView.getRenderingService().hooks.pick.promise({topmost:!0,position:{x:t,y:e,viewportX:r,viewportY:i,clientX:c,clientY:u},picked:[]})];case 1:return[2,(h=p.sent().picked)&&h[0]||this.documentElement]}})})},e.prototype.elementsFromPointSync=function(t,e){var n=this.defaultView.canvas2Viewport({x:t,y:e}),r=n.x,i=n.y,o=this.defaultView.getConfig(),a=o.width,s=o.height;if(r<0||i<0||r>a||i>s)return[];var l=this.defaultView.viewport2Client({x:r,y:i}),c=l.x,u=l.y,h=this.defaultView.getRenderingService().hooks.pickSync.call({topmost:!1,position:{x:t,y:e,viewportX:r,viewportY:i,clientX:c,clientY:u},picked:[]}).picked;return h[h.length-1]!==this.documentElement&&h.push(this.documentElement),h},e.prototype.elementsFromPoint=function(t,e){return(0,W.mG)(this,void 0,void 0,function(){var n,r,i,o,a,s,l,c,u,h;return(0,W.Jh)(this,function(p){switch(p.label){case 0:if(r=(n=this.defaultView.canvas2Viewport({x:t,y:e})).x,i=n.y,a=(o=this.defaultView.getConfig()).width,s=o.height,r<0||i<0||r>a||i>s)return[2,[]];return c=(l=this.defaultView.viewport2Client({x:r,y:i})).x,u=l.y,[4,this.defaultView.getRenderingService().hooks.pick.promise({topmost:!1,position:{x:t,y:e,viewportX:r,viewportY:i,clientX:c,clientY:u},picked:[]})];case 1:return(h=p.sent().picked)[h.length-1]!==this.documentElement&&h.push(this.documentElement),[2,h]}})})},e.prototype.appendChild=function(t,e){throw Error(tq)},e.prototype.insertBefore=function(t,e){throw Error(tq)},e.prototype.removeChild=function(t,e){throw Error(tq)},e.prototype.replaceChild=function(t,e,n){throw Error(tq)},e.prototype.append=function(){throw Error(tq)},e.prototype.prepend=function(){throw Error(tq)},e.prototype.getElementById=function(t){return this.documentElement.getElementById(t)},e.prototype.getElementsByName=function(t){return this.documentElement.getElementsByName(t)},e.prototype.getElementsByTagName=function(t){return this.documentElement.getElementsByTagName(t)},e.prototype.getElementsByClassName=function(t){return this.documentElement.getElementsByClassName(t)},e.prototype.querySelector=function(t){return this.documentElement.querySelector(t)},e.prototype.querySelectorAll=function(t){return this.documentElement.querySelectorAll(t)},e.prototype.find=function(t){return this.documentElement.find(t)},e.prototype.findAll=function(t){return this.documentElement.findAll(t)},e}(rb),ii=function(){function t(t){this.strategies=t}return t.prototype.apply=function(e){var n=e.camera,r=e.renderingService,i=e.renderingContext,o=this.strategies;r.hooks.cull.tap(t.tag,function(t){if(t){var e=t.cullable;return(0===o.length?e.visible=i.unculledEntities.indexOf(t.entity)>-1:e.visible=o.every(function(e){return e.isVisible(n,t)}),!t.isCulled()&&t.isVisible())?t:(t.dispatchEvent(new rE(H.CULLED)),null)}return t}),r.hooks.afterRender.tap(t.tag,function(t){t.cullable.visibilityPlaneMask=-1})},t.tag="Culling",t}(),io=function(){function t(){var t=this;this.autoPreventDefault=!1,this.rootPointerEvent=new rg(null),this.rootWheelEvent=new rm(null),this.onPointerMove=function(e){var n,r,i,o,a=null===(o=null===(i=t.context.renderingContext.root)||void 0===i?void 0:i.ownerDocument)||void 0===o?void 0:o.defaultView;if(!a.supportsTouchEvents||"touch"!==e.pointerType){var s=t.normalizeToPointerEvent(e,a);try{for(var l=(0,W.XA)(s),c=l.next();!c.done;c=l.next()){var u=c.value,h=t.bootstrapEvent(t.rootPointerEvent,u,a,e);t.context.eventService.mapEvent(h)}}catch(t){n={error:t}}finally{try{c&&!c.done&&(r=l.return)&&r.call(l)}finally{if(n)throw n.error}}t.setCursor(t.context.eventService.cursor)}},this.onClick=function(e){var n,r,i,o,a=null===(o=null===(i=t.context.renderingContext.root)||void 0===i?void 0:i.ownerDocument)||void 0===o?void 0:o.defaultView,s=t.normalizeToPointerEvent(e,a);try{for(var l=(0,W.XA)(s),c=l.next();!c.done;c=l.next()){var u=c.value,h=t.bootstrapEvent(t.rootPointerEvent,u,a,e);t.context.eventService.mapEvent(h)}}catch(t){n={error:t}}finally{try{c&&!c.done&&(r=l.return)&&r.call(l)}finally{if(n)throw n.error}}t.setCursor(t.context.eventService.cursor)}}return t.prototype.apply=function(e){var n=this;this.context=e;var r=e.renderingService,i=this.context.renderingContext.root.ownerDocument.defaultView;this.context.eventService.setPickHandler(function(t){return n.context.renderingService.hooks.pickSync.call({position:t,picked:[],topmost:!0}).picked[0]||null}),r.hooks.pointerWheel.tap(t.tag,function(t){var e=n.normalizeWheelEvent(t);n.context.eventService.mapEvent(e)}),r.hooks.pointerDown.tap(t.tag,function(t){if(!i.supportsTouchEvents||"touch"!==t.pointerType){var e,r,o=n.normalizeToPointerEvent(t,i);n.autoPreventDefault&&o[0].isNormalized&&(t.cancelable||!("cancelable"in t))&&t.preventDefault();try{for(var a=(0,W.XA)(o),s=a.next();!s.done;s=a.next()){var l=s.value,c=n.bootstrapEvent(n.rootPointerEvent,l,i,t);n.context.eventService.mapEvent(c)}}catch(t){e={error:t}}finally{try{s&&!s.done&&(r=a.return)&&r.call(a)}finally{if(e)throw e.error}}n.setCursor(n.context.eventService.cursor)}}),r.hooks.pointerUp.tap(t.tag,function(t){if(!i.supportsTouchEvents||"touch"!==t.pointerType){var e,r,o=n.context.contextService.getDomElement(),a="outside";try{a=o&&t.target&&t.target!==o&&o.contains&&!o.contains(t.target)?"outside":""}catch(t){}var s=n.normalizeToPointerEvent(t,i);try{for(var l=(0,W.XA)(s),c=l.next();!c.done;c=l.next()){var u=c.value,h=n.bootstrapEvent(n.rootPointerEvent,u,i,t);h.type+=a,n.context.eventService.mapEvent(h)}}catch(t){e={error:t}}finally{try{c&&!c.done&&(r=l.return)&&r.call(l)}finally{if(e)throw e.error}}n.setCursor(n.context.eventService.cursor)}}),r.hooks.pointerMove.tap(t.tag,this.onPointerMove),r.hooks.pointerOver.tap(t.tag,this.onPointerMove),r.hooks.pointerOut.tap(t.tag,this.onPointerMove),r.hooks.click.tap(t.tag,this.onClick),r.hooks.pointerCancel.tap(t.tag,function(t){var e,r,o=n.normalizeToPointerEvent(t,i);try{for(var a=(0,W.XA)(o),s=a.next();!s.done;s=a.next()){var l=s.value,c=n.bootstrapEvent(n.rootPointerEvent,l,i,t);n.context.eventService.mapEvent(c)}}catch(t){e={error:t}}finally{try{s&&!s.done&&(r=a.return)&&r.call(a)}finally{if(e)throw e.error}}n.setCursor(n.context.eventService.cursor)})},t.prototype.getViewportXY=function(t){var e,n,r=t.offsetX,i=t.offsetY,o=t.clientX,a=t.clientY;if(!this.context.config.supportsCSSTransform||(0,tr.Z)(r)||(0,tr.Z)(i)){var s=this.context.eventService.client2Viewport(new tW(o,a));e=s.x,n=s.y}else e=r,n=i;return{x:e,y:n}},t.prototype.bootstrapEvent=function(t,e,n,r){t.view=n,t.originalEvent=null,t.nativeEvent=r,t.pointerId=e.pointerId,t.width=e.width,t.height=e.height,t.isPrimary=e.isPrimary,t.pointerType=e.pointerType,t.pressure=e.pressure,t.tangentialPressure=e.tangentialPressure,t.tiltX=e.tiltX,t.tiltY=e.tiltY,t.twist=e.twist,this.transferMouseData(t,e);var i=this.getViewportXY(e),o=i.x,a=i.y;t.viewport.x=o,t.viewport.y=a;var s=this.context.eventService.viewport2Canvas(t.viewport),l=s.x,c=s.y;return t.canvas.x=l,t.canvas.y=c,t.global.copyFrom(t.canvas),t.offset.copyFrom(t.canvas),t.isTrusted=r.isTrusted,"pointerleave"===t.type&&(t.type="pointerout"),t.type.startsWith("mouse")&&(t.type=t.type.replace("mouse","pointer")),t.type.startsWith("touch")&&(t.type=nJ[t.type]||t.type),t},t.prototype.normalizeWheelEvent=function(t){var e=this.rootWheelEvent;this.transferMouseData(e,t),e.deltaMode=t.deltaMode,e.deltaX=t.deltaX,e.deltaY=t.deltaY,e.deltaZ=t.deltaZ;var n=this.getViewportXY(t),r=n.x,i=n.y;e.viewport.x=r,e.viewport.y=i;var o=this.context.eventService.viewport2Canvas(e.viewport),a=o.x,s=o.y;return e.canvas.x=a,e.canvas.y=s,e.global.copyFrom(e.canvas),e.offset.copyFrom(e.canvas),e.nativeEvent=t,e.type=t.type,e},t.prototype.transferMouseData=function(t,e){t.isTrusted=e.isTrusted,t.srcElement=e.srcElement,t.timeStamp=n$.now(),t.type=e.type,t.altKey=e.altKey,t.metaKey=e.metaKey,t.shiftKey=e.shiftKey,t.ctrlKey=e.ctrlKey,t.button=e.button,t.buttons=e.buttons,t.client.x=e.clientX,t.client.y=e.clientY,t.movement.x=e.movementX,t.movement.y=e.movementY,t.page.x=e.pageX,t.page.y=e.pageY,t.screen.x=e.screenX,t.screen.y=e.screenY,t.relatedTarget=null},t.prototype.setCursor=function(t){this.context.contextService.applyCursorStyle(t||this.context.config.cursor||"default")},t.prototype.normalizeToPointerEvent=function(t,e){var n=[];if(e.isTouchEvent(t))for(var r=0;r-1,a=0,s=r.length;a=1?Math.ceil(M):1,C=l||("auto"===(n=nq(a,"width"))?a.offsetWidth:parseFloat(n))||a.width/M,w=c||("auto"===(r=nq(a,"height"))?a.offsetHeight:parseFloat(r))||a.height/M),s&&(rG.offscreenCanvas=s),i.devicePixelRatio=M,i.requestAnimationFrame=null!=v?v:n6.bind(rG.globalThis),i.cancelAnimationFrame=null!=y?y:n7.bind(rG.globalThis),i.supportsTouchEvents=null!=E?E:"ontouchstart"in rG.globalThis,i.supportsPointerEvents=null!=m?m:!!rG.globalThis.PointerEvent,i.isTouchEvent=null!=S?S:function(t){return i.supportsTouchEvents&&t instanceof rG.globalThis.TouchEvent},i.isMouseEvent=null!=N?N:function(t){return!rG.globalThis.MouseEvent||t instanceof rG.globalThis.MouseEvent&&(!i.supportsPointerEvents||!(t instanceof rG.globalThis.PointerEvent))},i.initRenderingContext({container:o,canvas:a,width:C,height:w,renderer:h,offscreenCanvas:s,devicePixelRatio:M,cursor:f||"default",background:p||"transparent",createImage:g,document:d,supportsCSSTransform:x,useNativeClickEvent:T,alwaysTriggerPointerEventOnCanvas:P}),i.initDefaultCamera(C,w,h.clipSpaceNearZ),i.initRenderer(h,!0),i}return(0,W.ZT)(e,t),e.prototype.initRenderingContext=function(t){this.context.config=t,this.context.renderingContext={root:this.document.documentElement,renderListCurrentFrame:[],unculledEntities:[],renderReasons:new Set,force:!1,dirty:!1}},e.prototype.initDefaultCamera=function(t,e,n){var r=this,i=new rG.CameraContribution;i.clipSpaceNearZ=n,i.setType(A.EXPLORING,O.DEFAULT).setPosition(t/2,e/2,500).setFocalPoint(t/2,e/2,0).setOrthographic(-(t/2),t/2,e/2,-(e/2),.1,1e3),i.canvas=this,i.eventEmitter.on(tJ.UPDATED,function(){r.context.renderingContext.renderReasons.add(X.CAMERA_CHANGED)}),this.context.camera=i},e.prototype.getConfig=function(){return this.context.config},e.prototype.getRoot=function(){return this.document.documentElement},e.prototype.getCamera=function(){return this.context.camera},e.prototype.getContextService=function(){return this.context.contextService},e.prototype.getEventService=function(){return this.context.eventService},e.prototype.getRenderingService=function(){return this.context.renderingService},e.prototype.getRenderingContext=function(){return this.context.renderingContext},e.prototype.getStats=function(){return this.getRenderingService().getStats()},Object.defineProperty(e.prototype,"ready",{get:function(){var t=this;return!this.readyPromise&&(this.readyPromise=new Promise(function(e){t.resolveReadyPromise=function(){e(t)}}),this.inited&&this.resolveReadyPromise()),this.readyPromise},enumerable:!1,configurable:!0}),e.prototype.destroy=function(t,e){void 0===t&&(t=!0),void 0===e&&(e=!1),e||this.dispatchEvent(new rE(j.BEFORE_DESTROY)),this.frameId&&(this.getConfig().cancelAnimationFrame||cancelAnimationFrame)(this.frameId);var n=this.getRoot();this.unmountChildren(n),t&&(this.document.destroy(),this.getEventService().destroy()),this.getRenderingService().destroy(),this.getContextService().destroy(),t&&this.context.rBushRoot&&(this.context.rBushRoot.clear(),this.context.rBushRoot=null,this.context.renderingContext.root=null),e||this.dispatchEvent(new rE(j.AFTER_DESTROY))},e.prototype.changeSize=function(t,e){this.resize(t,e)},e.prototype.resize=function(t,e){var n=this.context.config;n.width=t,n.height=e,this.getContextService().resize(t,e);var r=this.context.camera,i=r.getProjectionMode();r.setPosition(t/2,e/2,500).setFocalPoint(t/2,e/2,0),i===L.ORTHOGRAPHIC?r.setOrthographic(-(t/2),t/2,e/2,-(e/2),r.getNear(),r.getFar()):r.setAspect(t/e),this.dispatchEvent(new rE(j.RESIZE,{width:t,height:e}))},e.prototype.appendChild=function(t,e){return this.document.documentElement.appendChild(t,e)},e.prototype.insertBefore=function(t,e){return this.document.documentElement.insertBefore(t,e)},e.prototype.removeChild=function(t){return this.document.documentElement.removeChild(t)},e.prototype.removeChildren=function(){this.document.documentElement.removeChildren()},e.prototype.destroyChildren=function(){this.document.documentElement.destroyChildren()},e.prototype.render=function(){var t=this;this.dispatchEvent(ih),this.getRenderingService().render(this.getConfig(),function(){t.dispatchEvent(ip)}),this.dispatchEvent(id)},e.prototype.run=function(){var t=this,e=function(){t.render(),t.frameId=t.requestAnimationFrame(e)};e()},e.prototype.initRenderer=function(t,e){var n=this;if(void 0===e&&(e=!1),!t)throw Error("Renderer is required.");this.inited=!1,this.readyPromise=void 0,this.context.rBushRoot=new tN,this.context.renderingPlugins=[],this.context.renderingPlugins.push(new io,new il,new ii([new is])),this.loadRendererContainerModule(t),this.context.contextService=new this.context.ContextService((0,W.pi)((0,W.pi)({},rG),this.context)),this.context.renderingService=new rS(rG,this.context),this.context.eventService=new rT(rG,this.context),this.context.eventService.init(),this.context.contextService.init?(this.context.contextService.init(),this.initRenderingService(t,e,!0)):this.context.contextService.initAsync().then(function(){n.initRenderingService(t,e)})},e.prototype.initRenderingService=function(t,e,n){var r=this;void 0===e&&(e=!1),void 0===n&&(n=!1),this.context.renderingService.init(function(){r.inited=!0,e?(n?r.requestAnimationFrame(function(){r.dispatchEvent(new rE(j.READY))}):r.dispatchEvent(new rE(j.READY)),r.readyPromise&&r.resolveReadyPromise()):r.dispatchEvent(new rE(j.RENDERER_CHANGED)),e||r.getRoot().forEach(function(t){var e=t.renderable;e&&(e.renderBoundsDirty=!0,e.boundsDirty=!0,e.dirty=!0)}),r.mountChildren(r.getRoot()),t.getConfig().enableAutoRendering&&r.run()})},e.prototype.loadRendererContainerModule=function(t){var e=this;t.getPlugins().forEach(function(t){t.context=e.context,t.init(rG)})},e.prototype.setRenderer=function(t){var e=this.getConfig();if(e.renderer!==t){var n=e.renderer;e.renderer=t,this.destroy(!1,!0),(0,W.ev)([],(0,W.CR)(null==n?void 0:n.getPlugins()),!1).reverse().forEach(function(t){t.destroy(rG)}),this.initRenderer(t)}},e.prototype.setCursor=function(t){this.getConfig().cursor=t,this.getContextService().applyCursorStyle(t)},e.prototype.unmountChildren=function(t){var e=this;t.childNodes.forEach(function(t){e.unmountChildren(t)}),this.inited&&(t.isMutationObserved?t.dispatchEvent(iu):(iu.target=t,this.dispatchEvent(iu,!0)),t!==this.document.documentElement&&(t.ownerDocument=null),t.isConnected=!1),t.isCustomElement&&t.disconnectedCallback&&t.disconnectedCallback()},e.prototype.mountChildren=function(t){var e=this;this.inited?t.isConnected||(t.ownerDocument=this.document,t.isConnected=!0,t.isMutationObserved?t.dispatchEvent(ic):(ic.target=t,this.dispatchEvent(ic,!0))):console.warn("[g]: You are trying to call `canvas.appendChild` before canvas' initialization finished. You can either await `canvas.ready` or listen to `CanvasEvent.READY` manually.","appended child: ",t.nodeName),t.childNodes.forEach(function(t){e.mountChildren(t)}),t.isCustomElement&&t.connectedCallback&&t.connectedCallback()},e.prototype.client2Viewport=function(t){return this.getEventService().client2Viewport(t)},e.prototype.viewport2Client=function(t){return this.getEventService().viewport2Client(t)},e.prototype.viewport2Canvas=function(t){return this.getEventService().viewport2Canvas(t)},e.prototype.canvas2Viewport=function(t){return this.getEventService().canvas2Viewport(t)},e.prototype.getPointByClient=function(t,e){return this.client2Viewport({x:t,y:e})},e.prototype.getClientByPoint=function(t,e){return this.viewport2Client({x:t,y:e})},e}(rx)}}]); \ No newline at end of file diff --git a/pilot/server/static/_next/static/chunks/355a6ca7.e6035af22360251e.js b/pilot/server/static/_next/static/chunks/355a6ca7.e6035af22360251e.js new file mode 100644 index 000000000..49316754a --- /dev/null +++ b/pilot/server/static/_next/static/chunks/355a6ca7.e6035af22360251e.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[34],{4559:function(t,e,n){n.d(e,{$6:function(){return j},$p:function(){return nq},Aw:function(){return rx},Cd:function(){return r0},Cm:function(){return I},Dk:function(){return H},E9:function(){return tz},Ee:function(){return r4},F6:function(){return tw},G$:function(){return ns},G0:function(){return nI},GL:function(){return U},GZ:function(){return r_},I8:function(){return tM},L1:function(){return n0},N1:function(){return nb},NB:function(){return rT},O4:function(){return tI},Oi:function(){return nK},Pj:function(){return r2},R:function(){return eA},RV:function(){return rH},Rr:function(){return X},Rx:function(){return eb},UL:function(){return it},V1:function(){return tQ},Vl:function(){return tD},Xz:function(){return iy},YR:function(){return e8},ZA:function(){return r3},_O:function(){return tL},aH:function(){return r7},b_:function(){return r1},bn:function(){return M},gz:function(){return eq},h0:function(){return Y},iM:function(){return A},jU:function(){return nW},jd:function(){return rM},jf:function(){return tq},k9:function(){return r5},lu:function(){return eL},mN:function(){return tH},mg:function(){return r6},o6:function(){return eT},qA:function(){return eO},s$:function(){return r$},ux:function(){return rQ},x1:function(){return r9},xA:function(){return ry},xv:function(){return ie},y$:function(){return r8}});var r,i,o,a,s,l,c,u,h,p,f,d,v,y,g,m,E,x,b,T,P,S,N,C,w,M,k,R,A,O,L,I,D,G,_,F,B,U,Z,V,Y,X,H,j,W=n(97582),z=n(54146),K=n(77160),q=n(85975),J=n(35600),$=n(98333),Q=n(32945),tt=n(31437),te=n(68797),tn=n(6393),tr=n(37377),ti=n(4663),to=n(53984),ta=n(72888),ts=n(58133),tl=n(26380),tc=n(76703),tu=n(25995),th=n(28024),tp=n(75066),tf=n(10353),td=n(49958),tv=n(49908),ty=n(8699),tg=n(88154),tm=n(47427),tE=n(63725),tx=n(72614),tb=n(36522),tT=n(80431),tP=n(33439),tS=n(73743),tN=("undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==n.g?n.g:"undefined"!=typeof self&&self,{exports:{}});tN.exports=function(){function t(t,e,n){var r=t[e];t[e]=t[n],t[n]=r}function e(t,e){return te?1:0}var n=function(t){void 0===t&&(t=9),this._maxEntries=Math.max(4,t),this._minEntries=Math.max(2,Math.ceil(.4*this._maxEntries)),this.clear()};function r(t,e){i(t,0,t.children.length,e,t)}function i(t,e,n,r,i){i||(i=p(null)),i.minX=1/0,i.minY=1/0,i.maxX=-1/0,i.maxY=-1/0;for(var a=e;a=t.minX&&e.maxY>=t.minY}function p(t){return{children:t,height:1,leaf:!0,minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0}}function f(n,r,i,o,a){for(var s=[r,i];s.length;)if(i=s.pop(),r=s.pop(),!(i-r<=o)){var l=r+Math.ceil((i-r)/o/2)*o;(function e(n,r,i,o,a){for(;o>i;){if(o-i>600){var s=o-i+1,l=r-i+1,c=Math.log(s),u=.5*Math.exp(2*c/3),h=.5*Math.sqrt(c*u*(s-u)/s)*(l-s/2<0?-1:1),p=Math.max(i,Math.floor(r-l*u/s+h)),f=Math.min(o,Math.floor(r+(s-l)*u/s+h));e(n,r,p,f,a)}var d=n[r],v=i,y=o;for(t(n,i,r),a(n[o],d)>0&&t(n,i,o);va(n[v],d);)v++;for(;a(n[y],d)>0;)y--}0===a(n[i],d)?t(n,i,y):t(n,++y,o),y<=r&&(i=y+1),r<=y&&(o=y-1)}})(n,l,r||0,i||n.length-1,a||e),s.push(r,l,l,i)}}return n.prototype.all=function(){return this._all(this.data,[])},n.prototype.search=function(t){var e=this.data,n=[];if(!h(t,e))return n;for(var r=this.toBBox,i=[];e;){for(var o=0;o=0;)if(i[e].children.length>this._maxEntries)this._split(i,e),e--;else break;this._adjustParentBBoxes(r,i,e)},n.prototype._split=function(t,e){var n=t[e],i=n.children.length,o=this._minEntries;this._chooseSplitAxis(n,o,i);var a=this._chooseSplitIndex(n,o,i),s=p(n.children.splice(a,n.children.length-a));s.height=n.height,s.leaf=n.leaf,r(n,this.toBBox),r(s,this.toBBox),e?t[e-1].children.push(s):this._splitRoot(n,s)},n.prototype._splitRoot=function(t,e){this.data=p([t,e]),this.data.height=t.height+1,this.data.leaf=!1,r(this.data,this.toBBox)},n.prototype._chooseSplitIndex=function(t,e,n){for(var r,o=1/0,a=1/0,s=e;s<=n-e;s++){var c=i(t,0,s,this.toBBox),u=i(t,s,n,this.toBBox),h=function(t,e){var n=Math.max(t.minX,e.minX),r=Math.max(t.minY,e.minY);return Math.max(0,Math.min(t.maxX,e.maxX)-n)*Math.max(0,Math.min(t.maxY,e.maxY)-r)}(c,u),p=l(c)+l(u);h=e;f--){var d=t.children[f];o(l,t.leaf?a(d):d),u+=c(l)}return u},n.prototype._adjustParentBBoxes=function(t,e,n){for(var r=n;r>=0;r--)o(e[r],t)},n.prototype._condense=function(t){for(var e=t.length-1,n=void 0;e>=0;e--)0===t[e].children.length?e>0?(n=t[e-1].children).splice(n.indexOf(t[e]),1):this.clear():r(t[e],this.toBBox)},n}();var tC=tN.exports;(r=M||(M={})).GROUP="g",r.CIRCLE="circle",r.ELLIPSE="ellipse",r.IMAGE="image",r.RECT="rect",r.LINE="line",r.POLYLINE="polyline",r.POLYGON="polygon",r.TEXT="text",r.PATH="path",r.HTML="html",r.MESH="mesh",(i=k||(k={}))[i.ZERO=0]="ZERO",i[i.NEGATIVE_ONE=1]="NEGATIVE_ONE";var tw=function(){function t(){this.plugins=[]}return t.prototype.addRenderingPlugin=function(t){this.plugins.push(t),this.context.renderingPlugins.push(t)},t.prototype.removeAllRenderingPlugins=function(){var t=this;this.plugins.forEach(function(e){var n=t.context.renderingPlugins.indexOf(e);n>=0&&t.context.renderingPlugins.splice(n,1)})},t}(),tM=function(){function t(t){this.clipSpaceNearZ=k.NEGATIVE_ONE,this.plugins=[],this.config=(0,W.pi)({enableDirtyCheck:!0,enableCulling:!1,enableAutoRendering:!0,enableDirtyRectangleRendering:!0,enableDirtyRectangleRenderingDebug:!1},t)}return t.prototype.registerPlugin=function(t){-1===this.plugins.findIndex(function(e){return e===t})&&this.plugins.push(t)},t.prototype.unregisterPlugin=function(t){var e=this.plugins.findIndex(function(e){return e===t});e>-1&&this.plugins.splice(e,1)},t.prototype.getPlugins=function(){return this.plugins},t.prototype.getPlugin=function(t){return this.plugins.find(function(e){return e.name===t})},t.prototype.getConfig=function(){return this.config},t.prototype.setConfig=function(t){Object.assign(this.config,t)},t}();function tk(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t}function tR(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t[2]=e[2]-n[2],t}function tA(t,e,n){return t[0]=e[0]+n[0],t[1]=e[1]+n[1],t[2]=e[2]+n[2],t}function tO(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t[2]=e[2]*n,t}function tL(t){return void 0===t?0:t>360||t<-360?t%360:t}function tI(t,e,n){return(void 0===e&&(e=0),void 0===n&&(n=0),Array.isArray(t)&&3===t.length)?K.d9(t):(0,te.Z)(t)?K.al(t,e,n):K.al(t[0],t[1]||e,t[2]||n)}function tD(t){return t*(Math.PI/180)}function tG(t){return t*(180/Math.PI)}function t_(t,e){var n,r,i,o,a,s,l,c,u,h,p,f,d,v,y,g,m;return 16===e.length?(i=.5*Math.PI,a=(o=(0,W.CR)(q.getScaling(K.Ue(),e),3))[0],s=o[1],l=o[2],(c=Math.asin(-e[2]/a))-i?(n=Math.atan2(e[6]/s,e[10]/l),r=Math.atan2(e[1]/a,e[0]/a)):(r=0,n=-Math.atan2(e[4]/s,e[5]/s)):(r=0,n=Math.atan2(e[4]/s,e[5]/s)),t[0]=n,t[1]=c,t[2]=r,t):(u=e[0],h=e[1],p=e[2],f=e[3],g=u*u+(d=h*h)+(v=p*p)+(y=f*f),(m=u*f-h*p)>.499995*g?(t[0]=Math.PI/2,t[1]=2*Math.atan2(h,u),t[2]=0):m<-.499995*g?(t[0]=-Math.PI/2,t[1]=2*Math.atan2(h,u),t[2]=0):(t[0]=Math.asin(2*(u*p-f*h)),t[1]=Math.atan2(2*(u*f+h*p),1-2*(v+y)),t[2]=Math.atan2(2*(u*h+p*f),1-2*(d+v))),t)}function tF(t){var e=t[0],n=t[1],r=t[3],i=t[4],o=Math.sqrt(e*e+n*n),a=Math.sqrt(r*r+i*i);e*i-n*r<0&&(eh&&(h=N),Cf&&(f=w),Mv&&(v=k),n[0]=(u+h)*.5,n[1]=(p+f)*.5,n[2]=(d+v)*.5,a[0]=(h-u)*.5,a[1]=(f-p)*.5,a[2]=(v-d)*.5,this.min[0]=u,this.min[1]=p,this.min[2]=d,this.max[0]=h,this.max[1]=f,this.max[2]=v}},t.prototype.setFromTransformedAABB=function(t,e){var n=this.center,r=this.halfExtents,i=t.center,o=t.halfExtents,a=e[0],s=e[4],l=e[8],c=e[1],u=e[5],h=e[9],p=e[2],f=e[6],d=e[10],v=Math.abs(a),y=Math.abs(s),g=Math.abs(l),m=Math.abs(c),E=Math.abs(u),x=Math.abs(h),b=Math.abs(p),T=Math.abs(f),P=Math.abs(d);n[0]=e[12]+a*i[0]+s*i[1]+l*i[2],n[1]=e[13]+c*i[0]+u*i[1]+h*i[2],n[2]=e[14]+p*i[0]+f*i[1]+d*i[2],r[0]=v*o[0]+y*o[1]+g*o[2],r[1]=m*o[0]+E*o[1]+x*o[2],r[2]=b*o[0]+T*o[1]+P*o[2],tR(this.min,n,r),tA(this.max,n,r)},t.prototype.intersects=function(t){var e=this.getMax(),n=this.getMin(),r=t.getMax(),i=t.getMin();return n[0]<=r[0]&&e[0]>=i[0]&&n[1]<=r[1]&&e[1]>=i[1]&&n[2]<=r[2]&&e[2]>=i[2]},t.prototype.intersection=function(e){if(!this.intersects(e))return null;var n,r,i,o,a,s,l=new t,c=(n=[0,0,0],r=this.getMin(),i=e.getMin(),n[0]=Math.max(r[0],i[0]),n[1]=Math.max(r[1],i[1]),n[2]=Math.max(r[2],i[2]),n),u=(o=[0,0,0],a=this.getMax(),s=e.getMax(),o[0]=Math.min(a[0],s[0]),o[1]=Math.min(a[1],s[1]),o[2]=Math.min(a[2],s[2]),o);return l.setMinMax(c,u),l},t.prototype.getNegativeFarPoint=function(t){if(273===t.pnVertexFlag)return tk([0,0,0],this.min);if(272===t.pnVertexFlag)return[this.min[0],this.min[1],this.max[2]];if(257===t.pnVertexFlag)return[this.min[0],this.max[1],this.min[2]];if(256===t.pnVertexFlag)return[this.min[0],this.max[1],this.max[2]];if(17===t.pnVertexFlag)return[this.max[0],this.min[1],this.min[2]];if(16===t.pnVertexFlag)return[this.max[0],this.min[1],this.max[2]];if(1===t.pnVertexFlag)return[this.max[0],this.max[1],this.min[2]];else return[this.max[0],this.max[1],this.max[2]]},t.prototype.getPositiveFarPoint=function(t){if(273===t.pnVertexFlag)return tk([0,0,0],this.max);if(272===t.pnVertexFlag)return[this.max[0],this.max[1],this.min[2]];if(257===t.pnVertexFlag)return[this.max[0],this.min[1],this.max[2]];if(256===t.pnVertexFlag)return[this.max[0],this.min[1],this.min[2]];if(17===t.pnVertexFlag)return[this.min[0],this.max[1],this.max[2]];if(16===t.pnVertexFlag)return[this.min[0],this.max[1],this.min[2]];if(1===t.pnVertexFlag)return[this.min[0],this.min[1],this.max[2]];else return[this.min[0],this.min[1],this.min[2]]},t}(),tj=function(){function t(t,e){this.distance=t||0,this.normal=e||K.al(0,1,0),this.updatePNVertexFlag()}return t.prototype.updatePNVertexFlag=function(){this.pnVertexFlag=(Number(this.normal[0]>=0)<<8)+(Number(this.normal[1]>=0)<<4)+Number(this.normal[2]>=0)},t.prototype.distanceToPoint=function(t){return K.AK(t,this.normal)-this.distance},t.prototype.normalize=function(){var t=1/K.Zh(this.normal);K.bA(this.normal,this.normal,t),this.distance*=t},t.prototype.intersectsLine=function(t,e,n){var r=this.distanceToPoint(t),i=r/(r-this.distanceToPoint(e)),o=i>=0&&i<=1;return o&&n&&K.t7(n,t,e,i),o},t}();(o=R||(R={}))[o.OUTSIDE=4294967295]="OUTSIDE",o[o.INSIDE=0]="INSIDE",o[o.INDETERMINATE=2147483647]="INDETERMINATE";var tW=function(){function t(t){if(this.planes=[],t)this.planes=t;else for(var e=0;e<6;e++)this.planes.push(new tj)}return t.prototype.extractFromVPMatrix=function(t){var e=(0,W.CR)(t,16),n=e[0],r=e[1],i=e[2],o=e[3],a=e[4],s=e[5],l=e[6],c=e[7],u=e[8],h=e[9],p=e[10],f=e[11],d=e[12],v=e[13],y=e[14],g=e[15];K.t8(this.planes[0].normal,o-n,c-a,f-u),this.planes[0].distance=g-d,K.t8(this.planes[1].normal,o+n,c+a,f+u),this.planes[1].distance=g+d,K.t8(this.planes[2].normal,o+r,c+s,f+h),this.planes[2].distance=g+v,K.t8(this.planes[3].normal,o-r,c-s,f-h),this.planes[3].distance=g-v,K.t8(this.planes[4].normal,o-i,c-l,f-p),this.planes[4].distance=g-y,K.t8(this.planes[5].normal,o+i,c+l,f+p),this.planes[5].distance=g+y,this.planes.forEach(function(t){t.normalize(),t.updatePNVertexFlag()})},t}(),tz=function(){function t(t,e){void 0===t&&(t=0),void 0===e&&(e=0),this.x=0,this.y=0,this.x=t,this.y=e}return t.prototype.clone=function(){return new t(this.x,this.y)},t.prototype.copyFrom=function(t){this.x=t.x,this.y=t.y},t}(),tK=function(){function t(t,e,n,r){this.x=t,this.y=e,this.width=n,this.height=r,this.left=t,this.right=t+n,this.top=e,this.bottom=e+r}return t.prototype.toJSON=function(){},t}(),tq="Method not implemented.",tJ="Use document.documentElement instead.";(a=A||(A={}))[a.ORBITING=0]="ORBITING",a[a.EXPLORING=1]="EXPLORING",a[a.TRACKING=2]="TRACKING",(s=O||(O={}))[s.DEFAULT=0]="DEFAULT",s[s.ROTATIONAL=1]="ROTATIONAL",s[s.TRANSLATIONAL=2]="TRANSLATIONAL",s[s.CINEMATIC=3]="CINEMATIC",(l=L||(L={}))[l.ORTHOGRAPHIC=0]="ORTHOGRAPHIC",l[l.PERSPECTIVE=1]="PERSPECTIVE";var t$={UPDATED:"updated"},tQ=function(){function t(){this.clipSpaceNearZ=k.NEGATIVE_ONE,this.eventEmitter=new z.Z,this.matrix=q.create(),this.right=K.al(1,0,0),this.up=K.al(0,1,0),this.forward=K.al(0,0,1),this.position=K.al(0,0,1),this.focalPoint=K.al(0,0,0),this.distanceVector=K.al(0,0,-1),this.distance=1,this.azimuth=0,this.elevation=0,this.roll=0,this.relAzimuth=0,this.relElevation=0,this.relRoll=0,this.dollyingStep=0,this.maxDistance=1/0,this.minDistance=-1/0,this.zoom=1,this.rotateWorld=!1,this.fov=30,this.near=.1,this.far=1e3,this.aspect=1,this.projectionMatrix=q.create(),this.projectionMatrixInverse=q.create(),this.jitteredProjectionMatrix=void 0,this.enableUpdate=!0,this.type=A.EXPLORING,this.trackingMode=O.DEFAULT,this.projectionMode=L.PERSPECTIVE,this.frustum=new tW,this.orthoMatrix=q.create()}return t.prototype.isOrtho=function(){return this.projectionMode===L.ORTHOGRAPHIC},t.prototype.getProjectionMode=function(){return this.projectionMode},t.prototype.getPerspective=function(){return this.jitteredProjectionMatrix||this.projectionMatrix},t.prototype.getPerspectiveInverse=function(){return this.projectionMatrixInverse},t.prototype.getFrustum=function(){return this.frustum},t.prototype.getPosition=function(){return this.position},t.prototype.getFocalPoint=function(){return this.focalPoint},t.prototype.getDollyingStep=function(){return this.dollyingStep},t.prototype.getNear=function(){return this.near},t.prototype.getFar=function(){return this.far},t.prototype.getZoom=function(){return this.zoom},t.prototype.getOrthoMatrix=function(){return this.orthoMatrix},t.prototype.getView=function(){return this.view},t.prototype.setEnableUpdate=function(t){this.enableUpdate=t},t.prototype.setType=function(t,e){return this.type=t,this.type===A.EXPLORING?this.setWorldRotation(!0):this.setWorldRotation(!1),this._getAngles(),this.type===A.TRACKING&&void 0!==e&&this.setTrackingMode(e),this},t.prototype.setProjectionMode=function(t){return this.projectionMode=t,this},t.prototype.setTrackingMode=function(t){if(this.type!==A.TRACKING)throw Error("Impossible to set a tracking mode if the camera is not of tracking type");return this.trackingMode=t,this},t.prototype.setWorldRotation=function(t){return this.rotateWorld=t,this._getAngles(),this},t.prototype.getViewTransform=function(){return q.invert(q.create(),this.matrix)},t.prototype.getWorldTransform=function(){return this.matrix},t.prototype.jitterProjectionMatrix=function(t,e){var n=q.fromTranslation(q.create(),[t,e,0]);this.jitteredProjectionMatrix=q.multiply(q.create(),n,this.projectionMatrix)},t.prototype.clearJitterProjectionMatrix=function(){this.jitteredProjectionMatrix=void 0},t.prototype.setMatrix=function(t){return this.matrix=t,this._update(),this},t.prototype.setFov=function(t){return this.setPerspective(this.near,this.far,t,this.aspect),this},t.prototype.setAspect=function(t){return this.setPerspective(this.near,this.far,this.fov,t),this},t.prototype.setNear=function(t){return this.projectionMode===L.PERSPECTIVE?this.setPerspective(t,this.far,this.fov,this.aspect):this.setOrthographic(this.left,this.rright,this.top,this.bottom,t,this.far),this},t.prototype.setFar=function(t){return this.projectionMode===L.PERSPECTIVE?this.setPerspective(this.near,t,this.fov,this.aspect):this.setOrthographic(this.left,this.rright,this.top,this.bottom,this.near,t),this},t.prototype.setViewOffset=function(t,e,n,r,i,o){return this.aspect=t/e,void 0===this.view&&(this.view={enabled:!0,fullWidth:1,fullHeight:1,offsetX:0,offsetY:0,width:1,height:1}),this.view.enabled=!0,this.view.fullWidth=t,this.view.fullHeight=e,this.view.offsetX=n,this.view.offsetY=r,this.view.width=i,this.view.height=o,this.projectionMode===L.PERSPECTIVE?this.setPerspective(this.near,this.far,this.fov,this.aspect):this.setOrthographic(this.left,this.rright,this.top,this.bottom,this.near,this.far),this},t.prototype.clearViewOffset=function(){return void 0!==this.view&&(this.view.enabled=!1),this.projectionMode===L.PERSPECTIVE?this.setPerspective(this.near,this.far,this.fov,this.aspect):this.setOrthographic(this.left,this.rright,this.top,this.bottom,this.near,this.far),this},t.prototype.setZoom=function(t){return this.zoom=t,this.projectionMode===L.ORTHOGRAPHIC?this.setOrthographic(this.left,this.rright,this.top,this.bottom,this.near,this.far):this.projectionMode===L.PERSPECTIVE&&this.setPerspective(this.near,this.far,this.fov,this.aspect),this},t.prototype.setZoomByViewportPoint=function(t,e){var n=this.canvas.viewport2Canvas({x:e[0],y:e[1]}),r=n.x,i=n.y,o=this.roll;this.rotate(0,0,-o),this.setPosition(r,i),this.setFocalPoint(r,i),this.setZoom(t),this.rotate(0,0,o);var a=this.canvas.viewport2Canvas({x:e[0],y:e[1]}),s=a.x,l=a.y,c=K.al(s-r,l-i,0),u=K.AK(c,this.right)/K.kE(this.right),h=K.AK(c,this.up)/K.kE(this.up);return this.pan(-u,-h),this},t.prototype.setPerspective=function(t,e,n,r){this.projectionMode=L.PERSPECTIVE,this.fov=n,this.near=t,this.far=e,this.aspect=r;var i,o,a,s,l,c,u,h,p,f=this.near*Math.tan(tD(.5*this.fov))/this.zoom,d=2*f,v=this.aspect*d,y=-.5*v;if(null===(p=this.view)||void 0===p?void 0:p.enabled){var g=this.view.fullWidth,m=this.view.fullHeight;y+=this.view.offsetX*v/g,f-=this.view.offsetY*d/m,v*=this.view.width/g,d*=this.view.height/m}return i=this.projectionMatrix,o=y,a=y+v,s=f,l=f-d,c=this.far,this.clipSpaceNearZ===k.ZERO?(u=-c/(c-t),h=-c*t/(c-t)):(u=-(c+t)/(c-t),h=-2*c*t/(c-t)),i[0]=2*t/(a-o),i[1]=0,i[2]=0,i[3]=0,i[4]=0,i[5]=2*t/(s-l),i[6]=0,i[7]=0,i[8]=(a+o)/(a-o),i[9]=(s+l)/(s-l),i[10]=u,i[11]=-1,i[12]=0,i[13]=0,i[14]=h,i[15]=0,q.scale(this.projectionMatrix,this.projectionMatrix,K.al(1,-1,1)),q.invert(this.projectionMatrixInverse,this.projectionMatrix),this.triggerUpdate(),this},t.prototype.setOrthographic=function(t,e,n,r,i,o){this.projectionMode=L.ORTHOGRAPHIC,this.rright=e,this.left=t,this.top=n,this.bottom=r,this.near=i,this.far=o;var a,s=(this.rright-this.left)/(2*this.zoom),l=(this.top-this.bottom)/(2*this.zoom),c=(this.rright+this.left)/2,u=(this.top+this.bottom)/2,h=c-s,p=c+s,f=u+l,d=u-l;if(null===(a=this.view)||void 0===a?void 0:a.enabled){var v=(this.rright-this.left)/this.view.fullWidth/this.zoom,y=(this.top-this.bottom)/this.view.fullHeight/this.zoom;h+=v*this.view.offsetX,p=h+v*this.view.width,f-=y*this.view.offsetY,d=f-y*this.view.height}return this.clipSpaceNearZ===k.NEGATIVE_ONE?q.ortho(this.projectionMatrix,h,p,d,f,i,o):q.orthoZO(this.projectionMatrix,h,p,d,f,i,o),q.scale(this.projectionMatrix,this.projectionMatrix,K.al(1,-1,1)),q.invert(this.projectionMatrixInverse,this.projectionMatrix),this._getOrthoMatrix(),this.triggerUpdate(),this},t.prototype.setPosition=function(t,e,n){void 0===e&&(e=this.position[1]),void 0===n&&(n=this.position[2]);var r=tI(t,e,n);return this._setPosition(r),this.setFocalPoint(this.focalPoint),this.triggerUpdate(),this},t.prototype.setFocalPoint=function(t,e,n){void 0===e&&(e=this.focalPoint[1]),void 0===n&&(n=this.focalPoint[2]);var r=K.al(0,1,0);if(this.focalPoint=tI(t,e,n),this.trackingMode===O.CINEMATIC){var i=K.$X(K.Ue(),this.focalPoint,this.position);t=i[0],e=i[1],n=i[2];var o=tG(Math.asin(e/K.kE(i))),a=90+tG(Math.atan2(n,t)),s=q.create();q.rotateY(s,s,tD(a)),q.rotateX(s,s,tD(o)),r=K.fF(K.Ue(),[0,1,0],s)}return q.invert(this.matrix,q.lookAt(q.create(),this.position,this.focalPoint,r)),this._getAxes(),this._getDistance(),this._getAngles(),this.triggerUpdate(),this},t.prototype.getDistance=function(){return this.distance},t.prototype.getDistanceVector=function(){return this.distanceVector},t.prototype.setDistance=function(t){if(this.distance===t||t<0)return this;this.distance=t,this.distance<2e-4&&(this.distance=2e-4),this.dollyingStep=this.distance/100;var e=K.Ue();t=this.distance;var n=this.forward,r=this.focalPoint;return e[0]=t*n[0]+r[0],e[1]=t*n[1]+r[1],e[2]=t*n[2]+r[2],this._setPosition(e),this.triggerUpdate(),this},t.prototype.setMaxDistance=function(t){return this.maxDistance=t,this},t.prototype.setMinDistance=function(t){return this.minDistance=t,this},t.prototype.setAzimuth=function(t){return this.azimuth=tL(t),this.computeMatrix(),this._getAxes(),this.type===A.ORBITING||this.type===A.EXPLORING?this._getPosition():this.type===A.TRACKING&&this._getFocalPoint(),this.triggerUpdate(),this},t.prototype.getAzimuth=function(){return this.azimuth},t.prototype.setElevation=function(t){return this.elevation=tL(t),this.computeMatrix(),this._getAxes(),this.type===A.ORBITING||this.type===A.EXPLORING?this._getPosition():this.type===A.TRACKING&&this._getFocalPoint(),this.triggerUpdate(),this},t.prototype.getElevation=function(){return this.elevation},t.prototype.setRoll=function(t){return this.roll=tL(t),this.computeMatrix(),this._getAxes(),this.type===A.ORBITING||this.type===A.EXPLORING?this._getPosition():this.type===A.TRACKING&&this._getFocalPoint(),this.triggerUpdate(),this},t.prototype.getRoll=function(){return this.roll},t.prototype._update=function(){this._getAxes(),this._getPosition(),this._getDistance(),this._getAngles(),this._getOrthoMatrix(),this.triggerUpdate()},t.prototype.computeMatrix=function(){var t=Q.yY(Q.Ue(),[0,0,1],tD(this.roll));q.identity(this.matrix);var e=Q.yY(Q.Ue(),[1,0,0],tD((this.rotateWorld&&this.type!==A.TRACKING||this.type===A.TRACKING?1:-1)*this.elevation)),n=Q.yY(Q.Ue(),[0,1,0],tD((this.rotateWorld&&this.type!==A.TRACKING||this.type===A.TRACKING?1:-1)*this.azimuth)),r=Q.Jp(Q.Ue(),n,e);r=Q.Jp(Q.Ue(),r,t);var i=q.fromQuat(q.create(),r);this.type===A.ORBITING||this.type===A.EXPLORING?(q.translate(this.matrix,this.matrix,this.focalPoint),q.multiply(this.matrix,this.matrix,i),q.translate(this.matrix,this.matrix,[0,0,this.distance])):this.type===A.TRACKING&&(q.translate(this.matrix,this.matrix,this.position),q.multiply(this.matrix,this.matrix,i))},t.prototype._setPosition=function(t,e,n){this.position=tI(t,e,n);var r=this.matrix;r[12]=this.position[0],r[13]=this.position[1],r[14]=this.position[2],r[15]=1,this._getOrthoMatrix()},t.prototype._getAxes=function(){K.JG(this.right,tI($.fF($.Ue(),[1,0,0,0],this.matrix))),K.JG(this.up,tI($.fF($.Ue(),[0,1,0,0],this.matrix))),K.JG(this.forward,tI($.fF($.Ue(),[0,0,1,0],this.matrix))),K.Fv(this.right,this.right),K.Fv(this.up,this.up),K.Fv(this.forward,this.forward)},t.prototype._getAngles=function(){var t=this.distanceVector[0],e=this.distanceVector[1],n=this.distanceVector[2],r=K.kE(this.distanceVector);if(0===r){this.elevation=0,this.azimuth=0;return}this.type===A.TRACKING?(this.elevation=tG(Math.asin(e/r)),this.azimuth=tG(Math.atan2(-t,-n))):this.rotateWorld?(this.elevation=tG(Math.asin(e/r)),this.azimuth=tG(Math.atan2(-t,-n))):(this.elevation=-tG(Math.asin(e/r)),this.azimuth=-tG(Math.atan2(-t,-n)))},t.prototype._getPosition=function(){K.JG(this.position,tI($.fF($.Ue(),[0,0,0,1],this.matrix))),this._getDistance()},t.prototype._getFocalPoint=function(){K.kK(this.distanceVector,[0,0,-this.distance],J.xO(J.Ue(),this.matrix)),K.IH(this.focalPoint,this.position,this.distanceVector),this._getDistance()},t.prototype._getDistance=function(){this.distanceVector=K.$X(K.Ue(),this.focalPoint,this.position),this.distance=K.kE(this.distanceVector),this.dollyingStep=this.distance/100},t.prototype._getOrthoMatrix=function(){if(this.projectionMode===L.ORTHOGRAPHIC){var t=this.position,e=Q.yY(Q.Ue(),[0,0,1],-this.roll*Math.PI/180);q.fromRotationTranslationScaleOrigin(this.orthoMatrix,e,K.al((this.rright-this.left)/2-t[0],(this.top-this.bottom)/2-t[1],0),K.al(this.zoom,this.zoom,1),t)}},t.prototype.triggerUpdate=function(){if(this.enableUpdate){var t=this.getViewTransform(),e=q.multiply(q.create(),this.getPerspective(),t);this.getFrustum().extractFromVPMatrix(e),this.eventEmitter.emit(t$.UPDATED)}},t.prototype.rotate=function(t,e,n){throw Error(tq)},t.prototype.pan=function(t,e){throw Error(tq)},t.prototype.dolly=function(t){throw Error(tq)},t.prototype.createLandmark=function(t,e){throw Error(tq)},t.prototype.gotoLandmark=function(t,e){throw Error(tq)},t.prototype.cancelLandmarkAnimation=function(){throw Error(tq)},t}();function t0(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw TypeError("Expected a function");var n=function(){for(var r=[],i=0;i=I.kEms&&t=B.kUnitType&&this.getType()<=B.kClampType},t}(),t8=function(t){function e(e){var n=t.call(this)||this;return n.colorSpace=e,n}return(0,W.ZT)(e,t),e.prototype.getType=function(){return B.kColorType},e.prototype.to=function(t){return this},e}(t9);(v=U||(U={}))[v.Constant=0]="Constant",v[v.LinearGradient=1]="LinearGradient",v[v.RadialGradient=2]="RadialGradient";var t6=function(t){function e(e,n){var r=t.call(this)||this;return r.type=e,r.value=n,r}return(0,W.ZT)(e,t),e.prototype.clone=function(){return new e(this.type,this.value)},e.prototype.buildCSSText=function(t,e,n){return n},e.prototype.getType=function(){return B.kColorType},e}(t9),t7=function(t){function e(e){var n=t.call(this)||this;return n.value=e,n}return(0,W.ZT)(e,t),e.prototype.clone=function(){return new e(this.value)},e.prototype.getType=function(){return B.kKeywordType},e.prototype.buildCSSText=function(t,e,n){return n+this.value},e}(t9),et=t0(function(t){return void 0===t&&(t=""),t.replace(/-([a-z])/g,function(t){return t[1].toUpperCase()})}),ee=function(t){return t.split("").map(function(t,e){return t.toUpperCase()===t?"".concat(0!==e?"-":"").concat(t.toLowerCase()):t}).join("")};function en(t){return"function"==typeof t}var er={d:{alias:"path"},strokeDasharray:{alias:"lineDash"},strokeWidth:{alias:"lineWidth"},textAnchor:{alias:"textAlign"},src:{alias:"img"}},ei=t0(function(t){var e=et(t),n=er[e];return(null==n?void 0:n.alias)||e}),eo=function(t,e){void 0===e&&(e="");var n="";return Number.isFinite(t)?(function(t){if(!t)throw Error()}(Number.isNaN(t)),n="NaN"):n=t>0?"infinity":"-infinity",n+e},ea=function(t){return t3(t2(t))},es=function(t){function e(e,n){void 0===n&&(n=I.kNumber);var r,i,o=t.call(this)||this;return i="string"==typeof n?(r=n)?"number"===r?I.kNumber:"percent"===r||"%"===r?I.kPercentage:t1.find(function(t){return t.name===r}).unit_type:I.kUnknown:n,o.unit=i,o.value=e,o}return(0,W.ZT)(e,t),e.prototype.clone=function(){return new e(this.value,this.unit)},e.prototype.equals=function(t){return this.value===t.value&&this.unit===t.unit},e.prototype.getType=function(){return B.kUnitType},e.prototype.convertTo=function(t){if(this.unit===t)return new e(this.value,this.unit);var n=ea(this.unit);if(n!==ea(t)||n===I.kUnknown)return null;var r=t5(this.unit)/t5(t);return new e(this.value*r,t)},e.prototype.buildCSSText=function(t,e,n){var r;switch(this.unit){case I.kUnknown:break;case I.kInteger:r=Number(this.value).toFixed(0);break;case I.kNumber:case I.kPercentage:case I.kEms:case I.kRems:case I.kPixels:case I.kDegrees:case I.kRadians:case I.kGradians:case I.kMilliseconds:case I.kSeconds:case I.kTurns:var i=this.value,o=t4(this.unit);if(i<-999999||i>999999){var a=t4(this.unit);r=!Number.isFinite(i)||Number.isNaN(i)?eo(i,a):i+(a||"")}else r="".concat(i).concat(o)}return n+r},e}(t9),el=new es(0,"px");new es(1,"px");var ec=new es(0,"deg"),eu=function(t){function e(e,n,r,i,o){void 0===i&&(i=1),void 0===o&&(o=!1);var a=t.call(this,"rgb")||this;return a.r=e,a.g=n,a.b=r,a.alpha=i,a.isNone=o,a}return(0,W.ZT)(e,t),e.prototype.clone=function(){return new e(this.r,this.g,this.b,this.alpha)},e.prototype.buildCSSText=function(t,e,n){return n+"rgba(".concat(this.r,",").concat(this.g,",").concat(this.b,",").concat(this.alpha,")")},e}(t8),eh=new t7("unset"),ep={"":eh,unset:eh,initial:new t7("initial"),inherit:new t7("inherit")},ef=function(t){return ep[t]||(ep[t]=new t7(t)),ep[t]},ed=new eu(0,0,0,0,!0),ev=new eu(0,0,0,0),ey=t0(function(t,e,n,r){return new eu(t,e,n,r)},function(t,e,n,r){return"rgba(".concat(t,",").concat(e,",").concat(n,",").concat(r,")")}),eg=function(t,e){return void 0===e&&(e=I.kNumber),new es(t,e)},em=new es(50,"%");(y=Z||(Z={}))[y.Standard=0]="Standard",(g=V||(V={}))[g.ADDED=0]="ADDED",g[g.REMOVED=1]="REMOVED",g[g.Z_INDEX_CHANGED=2]="Z_INDEX_CHANGED";var eE={absolutePath:[],hasArc:!1,segments:[],polygons:[],polylines:[],curve:null,totalLength:0,rect:new tK(0,0,0,0)};(m=Y||(Y={})).COORDINATE="",m.COLOR="",m.PAINT="",m.NUMBER="",m.ANGLE="",m.OPACITY_VALUE="",m.SHADOW_BLUR="",m.LENGTH="",m.PERCENTAGE="",m.LENGTH_PERCENTAGE=" | ",m.LENGTH_PERCENTAGE_12="[ | ]{1,2}",m.LENGTH_PERCENTAGE_14="[ | ]{1,4}",m.LIST_OF_POINTS="",m.PATH="",m.FILTER="",m.Z_INDEX="",m.OFFSET_DISTANCE="",m.DEFINED_PATH="",m.MARKER="",m.TRANSFORM="",m.TRANSFORM_ORIGIN="",m.TEXT="",m.TEXT_TRANSFORM="";var ex=function(){var t={linearGradient:/^(linear\-gradient)/i,repeatingLinearGradient:/^(repeating\-linear\-gradient)/i,radialGradient:/^(radial\-gradient)/i,repeatingRadialGradient:/^(repeating\-radial\-gradient)/i,conicGradient:/^(conic\-gradient)/i,sideOrCorner:/^to (left (top|bottom)|right (top|bottom)|top (left|right)|bottom (left|right)|left|right|top|bottom)/i,extentKeywords:/^(closest\-side|closest\-corner|farthest\-side|farthest\-corner|contain|cover)/,positionKeywords:/^(left|center|right|top|bottom)/i,pixelValue:/^(-?(([0-9]*\.[0-9]+)|([0-9]+\.?)))px/,percentageValue:/^(-?(([0-9]*\.[0-9]+)|([0-9]+\.?)))\%/,emValue:/^(-?(([0-9]*\.[0-9]+)|([0-9]+\.?)))em/,angleValue:/^(-?(([0-9]*\.[0-9]+)|([0-9]+\.?)))deg/,startCall:/^\(/,endCall:/^\)/,comma:/^,/,hexColor:/^\#([0-9a-fA-F]+)/,literalColor:/^([a-zA-Z]+)/,rgbColor:/^rgb/i,rgbaColor:/^rgba/i,number:/^(([0-9]*\.[0-9]+)|([0-9]+\.?))/},e="";function n(t){throw Error(e+": "+t)}function r(){return i("linear-gradient",t.linearGradient,a)||i("repeating-linear-gradient",t.repeatingLinearGradient,a)||i("radial-gradient",t.radialGradient,s)||i("repeating-radial-gradient",t.repeatingRadialGradient,s)||i("conic-gradient",t.conicGradient,s)}function i(e,r,i){return o(r,function(r){var o=i();return o&&!m(t.comma)&&n("Missing comma before color stops"),{type:e,orientation:o,colorStops:p(f)}})}function o(e,r){var i=m(e);if(i){m(t.startCall)||n("Missing (");var o=r(i);return m(t.endCall)||n("Missing )"),o}}function a(){return g("directional",t.sideOrCorner,1)||g("angular",t.angleValue,1)}function s(){var n,r,i=l();return i&&((n=[]).push(i),r=e,m(t.comma)&&((i=l())?n.push(i):e=r)),n}function l(){var t,e,n=((t=g("shape",/^(circle)/i,0))&&(t.style=y()||c()),t||((e=g("shape",/^(ellipse)/i,0))&&(e.style=v()||c()),e));if(n)n.at=u();else{var r=c();if(r){n=r;var i=u();i&&(n.at=i)}else{var o=h();o&&(n={type:"default-radial",at:o})}}return n}function c(){return g("extent-keyword",t.extentKeywords,1)}function u(){if(g("position",/^at/,0)){var t=h();return t||n("Missing positioning value"),t}}function h(){var t={x:v(),y:v()};if(t.x||t.y)return{type:"position",value:t}}function p(e){var r=e(),i=[];if(r)for(i.push(r);m(t.comma);)(r=e())?i.push(r):n("One extra comma");return i}function f(){var e=g("hex",t.hexColor,1)||o(t.rgbaColor,function(){return{type:"rgba",value:p(d)}})||o(t.rgbColor,function(){return{type:"rgb",value:p(d)}})||g("literal",t.literalColor,0);return e||n("Expected color definition"),e.length=v(),e}function d(){return m(t.number)[1]}function v(){return g("%",t.percentageValue,1)||g("position-keyword",t.positionKeywords,1)||y()}function y(){return g("px",t.pixelValue,1)||g("em",t.emValue,1)}function g(t,e,n){var r=m(e);if(r)return{type:t,value:r[n]}}function m(t){var n=/^[\n\r\t\s]+/.exec(e);n&&E(n[0].length);var r=t.exec(e);return r&&E(r[0].length),r}function E(t){e=e.substring(t)}return function(t){var i;return e=t,i=p(r),e.length>0&&n("Invalid input not EOF"),i}}();function eb(t,e,n){var r=tD(n.value),i=0+t/2,o=0+e/2,a=Math.abs(t*Math.cos(r))+Math.abs(e*Math.sin(r));return{x1:i-Math.cos(r)*a/2,y1:o-Math.sin(r)*a/2,x2:i+Math.cos(r)*a/2,y2:o+Math.sin(r)*a/2}}function eT(t,e,n,r,i){var o=n.value,a=r.value;n.unit===I.kPercentage&&(o=n.value/100*t),r.unit===I.kPercentage&&(a=r.value/100*e);var s=Math.max((0,tn.y)([0,0],[o,a]),(0,tn.y)([0,e],[o,a]),(0,tn.y)([t,e],[o,a]),(0,tn.y)([t,0],[o,a]));return i&&(i instanceof es?s=i.value:i instanceof t7&&("closest-side"===i.value?s=Math.min(o,t-o,a,e-a):"farthest-side"===i.value?s=Math.max(o,t-o,a,e-a):"closest-corner"===i.value&&(s=Math.min((0,tn.y)([0,0],[o,a]),(0,tn.y)([0,e],[o,a]),(0,tn.y)([t,e],[o,a]),(0,tn.y)([t,0],[o,a]))))),{x:o,y:a,r:s}}var eP=/^l\s*\(\s*([\d.]+)\s*\)\s*(.*)/i,eS=/^r\s*\(\s*([\d.]+)\s*,\s*([\d.]+)\s*,\s*([\d.]+)\s*\)\s*(.*)/i,eN=/^p\s*\(\s*([axyn])\s*\)\s*(.*)/i,eC=/[\d.]+:(#[^\s]+|[^\)]+\))/gi,ew={left:180,top:-90,bottom:90,right:0,"left top":225,"top left":225,"left bottom":135,"bottom left":135,"right top":-45,"top right":-45,"right bottom":45,"bottom right":45},eM=t0(function(t){return eg("angular"===t.type?Number(t.value):ew[t.value]||0,"deg")}),ek=t0(function(t){var e=50,n=50,r="%",i="%";if((null==t?void 0:t.type)==="position"){var o=t.value,a=o.x,s=o.y;(null==a?void 0:a.type)==="position-keyword"&&("left"===a.value?e=0:"center"===a.value?e=50:"right"===a.value?e=100:"top"===a.value?n=0:"bottom"===a.value&&(n=100)),(null==s?void 0:s.type)==="position-keyword"&&("left"===s.value?e=0:"center"===s.value?n=50:"right"===s.value?e=100:"top"===s.value?n=0:"bottom"===s.value&&(n=100)),((null==a?void 0:a.type)==="px"||(null==a?void 0:a.type)==="%"||(null==a?void 0:a.type)==="em")&&(r=null==a?void 0:a.type,e=Number(a.value)),((null==s?void 0:s.type)==="px"||(null==s?void 0:s.type)==="%"||(null==s?void 0:s.type)==="em")&&(i=null==s?void 0:s.type,n=Number(s.value))}return{cx:eg(e,r),cy:eg(n,i)}}),eR=t0(function(t){if(t.indexOf("linear")>-1||t.indexOf("radial")>-1){var e;return ex(t).map(function(t){var e=t.type,n=t.orientation,r=t.colorStops;!function(t){var e,n,r,i=t.length;t[i-1].length=null!==(e=t[i-1].length)&&void 0!==e?e:{type:"%",value:"100"},i>1&&(t[0].length=null!==(n=t[0].length)&&void 0!==n?n:{type:"%",value:"0"});for(var o=0,a=Number(t[0].length.value),s=1;s=0)return eg(Number(e),"px");if("deg".search(t)>=0)return eg(Number(e),"deg")}var n=[];e=e.replace(t,function(t){return n.push(t),"U"+t});var r="U("+t.source+")";return n.map(function(t){return eg(Number(e.replace(RegExp("U"+t,"g"),"").replace(RegExp(r,"g"),"*0")),t)})[0]}var eG=t0(function(t){return eD(/px/g,t)});t0(function(t){return eD(RegExp("%","g"),t)});var e_=function(t){return(0,te.Z)(t)||isFinite(Number(t))?eg(Number(t)||0,"px"):eD(RegExp("px|%|em|rem","g"),t)},eF=t0(function(t){return eD(RegExp("deg|rad|grad|turn","g"),t)});function eB(t){var e=0;return t.unit===I.kDegrees?e=t.value:t.unit===I.kRadians?e=tG(Number(t.value)):t.unit===I.kTurns&&(e=360*Number(t.value)),e}function eU(t,e){var n;return(Array.isArray(t)?n=t.map(function(t){return Number(t)}):(0,ti.Z)(t)?n=t.split(" ").map(function(t){return Number(t)}):(0,te.Z)(t)&&(n=[t]),2===e)?1===n.length?[n[0],n[0]]:[n[0],n[1]]:1===n.length?[n[0],n[0],n[0],n[0]]:2===n.length?[n[0],n[1],n[0],n[1]]:3===n.length?[n[0],n[1],n[2],n[1]]:[n[0],n[1],n[2],n[3]]}function eZ(t){return(0,ti.Z)(t)?t.split(" ").map(function(t){return e_(t)}):t.map(function(t){return e_(t.toString())})}function eV(t,e,n){if(0===t.value)return 0;if(t.unit===I.kPixels)return Number(t.value);if(t.unit===I.kPercentage&&n){var r=n.nodeName===M.GROUP?n.getLocalBounds():n.geometry.contentBounds;return t.value/100*r.halfExtents[e]*2}return 0}var eY=["blur","brightness","drop-shadow","contrast","grayscale","sepia","saturate","hue-rotate","invert"];function eX(t){if(void 0===t&&(t=""),"none"===(t=t.toLowerCase().trim()))return[];for(var e,n=/\s*([\w-]+)\(([^)]*)\)/g,r=[],i=0;(e=n.exec(t))&&e.index===i;)if(i=e.index+e[0].length,eY.indexOf(e[1])>-1&&r.push({name:e[1],params:e[2].split(" ").map(function(t){return eD(/deg|rad|grad|turn|px|%/g,t)||eL(t)})}),n.lastIndex===t.length)return r;return[]}function eH(t){return t.toString()}var ej=t0(function(t){return"number"==typeof t?eg(t):/^\s*[-+]?(\d*\.)?\d+\s*$/.test(t)?eg(Number(t)):eg(0)});function eW(t,e){return[t,e,eH]}function ez(t,e){return function(n,r){return[n,r,function(n){return eH((0,to.Z)(n,t,e))}]}}function eK(t,e){if(t.length===e.length)return[t,e,function(t){return t}]}function eq(t){return 0===t.parsedStyle.path.totalLength&&(t.parsedStyle.path.totalLength=(0,ta.D)(t.parsedStyle.path.absolutePath)),t.parsedStyle.path.totalLength}function eJ(t,e){return t[0]===e[0]&&t[1]===e[1]}function e$(t,e){var n=t.prePoint,r=t.currentPoint,i=t.nextPoint,o=Math.pow(r[0]-n[0],2)+Math.pow(r[1]-n[1],2),a=Math.pow(r[0]-i[0],2)+Math.pow(r[1]-i[1],2),s=Math.acos((o+a-(Math.pow(n[0]-i[0],2)+Math.pow(n[1]-i[1],2)))/(2*Math.sqrt(o)*Math.sqrt(a)));if(!s||0===Math.sin(s)||(0,tc.Z)(s,0))return{xExtra:0,yExtra:0};var l=Math.abs(Math.atan2(i[1]-r[1],i[0]-r[0])),c=Math.abs(Math.atan2(i[0]-r[0],i[1]-r[1]));return{xExtra:Math.cos(s/2-(l=l>Math.PI/2?Math.PI-l:l))*(e/2*(1/Math.sin(s/2)))-e/2||0,yExtra:Math.cos((c=c>Math.PI/2?Math.PI-c:c)-s/2)*(e/2*(1/Math.sin(s/2)))-e/2||0}}function eQ(t,e){return[e[0]+(e[0]-t[0]),e[1]+(e[1]-t[1])]}t0(function(t){return(0,ti.Z)(t)?t.split(" ").map(ej):t.map(ej)});var e0=function(t,e){var n=t.x*e.x+t.y*e.y,r=Math.sqrt((Math.pow(t.x,2)+Math.pow(t.y,2))*(Math.pow(e.x,2)+Math.pow(e.y,2)));return(t.x*e.y-t.y*e.x<0?-1:1)*Math.acos(n/r)},e1=function(t,e,n,r,i,o,a,s){e=Math.abs(e),n=Math.abs(n);var l=tD(r=(0,tu.Z)(r,360));if(t.x===a.x&&t.y===a.y)return{x:t.x,y:t.y,ellipticalArcAngle:0};if(0===e||0===n)return{x:0,y:0,ellipticalArcAngle:0};var c=(t.x-a.x)/2,u=(t.y-a.y)/2,h={x:Math.cos(l)*c+Math.sin(l)*u,y:-Math.sin(l)*c+Math.cos(l)*u},p=Math.pow(h.x,2)/Math.pow(e,2)+Math.pow(h.y,2)/Math.pow(n,2);p>1&&(e=Math.sqrt(p)*e,n=Math.sqrt(p)*n);var f=(Math.pow(e,2)*Math.pow(n,2)-Math.pow(e,2)*Math.pow(h.y,2)-Math.pow(n,2)*Math.pow(h.x,2))/(Math.pow(e,2)*Math.pow(h.y,2)+Math.pow(n,2)*Math.pow(h.x,2)),d=(i!==o?1:-1)*Math.sqrt(f=f<0?0:f),v={x:d*(e*h.y/n),y:d*(-(n*h.x)/e)},y={x:Math.cos(l)*v.x-Math.sin(l)*v.y+(t.x+a.x)/2,y:Math.sin(l)*v.x+Math.cos(l)*v.y+(t.y+a.y)/2},g={x:(h.x-v.x)/e,y:(h.y-v.y)/n},m=e0({x:1,y:0},g),E=e0(g,{x:(-h.x-v.x)/e,y:(-h.y-v.y)/n});!o&&E>0?E-=2*Math.PI:o&&E<0&&(E+=2*Math.PI);var x=m+(E%=2*Math.PI)*s,b=e*Math.cos(x),T=n*Math.sin(x);return{x:Math.cos(l)*b-Math.sin(l)*T+y.x,y:Math.sin(l)*b+Math.cos(l)*T+y.y,ellipticalArcStartAngle:m,ellipticalArcEndAngle:m+E,ellipticalArcAngle:x,ellipticalArcCenter:y,resultantRx:e,resultantRy:n}};function e2(t,e,n){void 0===n&&(n=!0);var r=t.arcParams,i=r.rx,o=void 0===i?0:i,a=r.ry,s=void 0===a?0:a,l=r.xRotation,c=r.arcFlag,u=r.sweepFlag,h=e1({x:t.prePoint[0],y:t.prePoint[1]},o,s,l,!!c,!!u,{x:t.currentPoint[0],y:t.currentPoint[1]},e),p=e1({x:t.prePoint[0],y:t.prePoint[1]},o,s,l,!!c,!!u,{x:t.currentPoint[0],y:t.currentPoint[1]},n?e+.005:e-.005),f=p.x-h.x,d=p.y-h.y,v=Math.sqrt(f*f+d*d);return{x:-f/v,y:-d/v}}function e3(t){return Math.sqrt(t[0]*t[0]+t[1]*t[1])}function e5(t,e){return e3(t)*e3(e)?(t[0]*e[0]+t[1]*e[1])/(e3(t)*e3(e)):1}function e4(t,e){return(t[0]*e[1]0?1:-1,h=e>0?1:-1,p=u+h!==0?1:0;return[["M",u*a+n,r],["L",t-u*s+n,r],s?["A",s,s,0,0,p,t+n,h*s+r]:null,["L",t+n,e-h*l+r],l?["A",l,l,0,0,p,t+n-u*l,e+r]:null,["L",n+u*c,e+r],c?["A",c,c,0,0,p,n,e+r-h*c]:null,["L",n,h*a+r],a?["A",a,a,0,0,p,u*a+n,r]:null,["Z"]].filter(function(t){return t})}return[["M",n,r],["L",n+t,r],["L",n+t,r+e],["L",n,r+e],["Z"]]}(D,_,B,Z,V&&V.some(function(t){return 0!==t})&&V.map(function(t){return(0,to.Z)(t,0,Math.min(Math.abs(D)/2,Math.abs(_)/2))}));break;case M.PATH:var Y=t.parsedStyle.path.absolutePath;p=(0,W.ev)([],(0,W.CR)(Y),!1)}if(p.length)return o=p,a=e,c=void 0===(l=(s=t.parsedStyle).defX)?0:l,h=void 0===(u=s.defY)?0:u,o.reduce(function(t,e){var n="";if("M"===e[0]||"L"===e[0]){var r=K.al(e[1]-c,e[2]-h,0);a&&K.fF(r,r,a),n="".concat(e[0]).concat(r[0],",").concat(r[1])}else if("Z"===e[0])n=e[0];else if("C"===e[0]){var i=K.al(e[1]-c,e[2]-h,0),o=K.al(e[3]-c,e[4]-h,0),s=K.al(e[5]-c,e[6]-h,0);a&&(K.fF(i,i,a),K.fF(o,o,a),K.fF(s,s,a)),n="".concat(e[0]).concat(i[0],",").concat(i[1],",").concat(o[0],",").concat(o[1],",").concat(s[0],",").concat(s[1])}else if("A"===e[0]){var l=K.al(e[6]-c,e[7]-h,0);a&&K.fF(l,l,a),n="".concat(e[0]).concat(e[1],",").concat(e[2],",").concat(e[3],",").concat(e[4],",").concat(e[5],",").concat(l[0],",").concat(l[1])}else if("Q"===e[0]){var i=K.al(e[1]-c,e[2]-h,0),o=K.al(e[3]-c,e[4]-h,0);a&&(K.fF(i,i,a),K.fF(o,o,a)),n="".concat(e[0]).concat(e[1],",").concat(e[2],",").concat(e[3],",").concat(e[4],"}")}return t+n},"")}var e6=function(t){if(""===t||Array.isArray(t)&&0===t.length)return{absolutePath:[],hasArc:!1,segments:[],polygons:[],polylines:[],curve:null,totalLength:0,rect:{x:0,y:0,width:0,height:0}};try{e=(0,th.A)(t)}catch(n){e=(0,th.A)(""),console.error("[g]: Invalid SVG Path definition: ".concat(t))}!function(t){for(var e=0;e0&&n.push(r),{polygons:e,polylines:n}}(e),i=r.polygons,o=r.polylines,a=function(t){for(var e=[],n=null,r=null,i=null,o=0,a=t.length,s=0;s1&&(n*=Math.sqrt(f),r*=Math.sqrt(f));var d=n*n*(p*p)+r*r*(h*h),v=d?Math.sqrt((n*n*(r*r)-d)/d):1;o===a&&(v*=-1),isNaN(v)&&(v=0);var y=r?v*n*p/r:0,g=n?-(v*r)*h/n:0,m=(s+c)/2+Math.cos(i)*y-Math.sin(i)*g,E=(l+u)/2+Math.sin(i)*y+Math.cos(i)*g,x=[(h-y)/n,(p-g)/r],b=[(-1*h-y)/n,(-1*p-g)/r],T=e4([1,0],x),P=e4(x,b);return -1>=e5(x,b)&&(P=Math.PI),e5(x,b)>=1&&(P=0),0===a&&P>0&&(P-=2*Math.PI),1===a&&P<0&&(P+=2*Math.PI),{cx:m,cy:E,rx:eJ(t,[c,u])?0:n,ry:eJ(t,[c,u])?0:r,startAngle:T,endAngle:T+P,xRotation:i,arcFlag:o,sweepFlag:a}}(n,l);u.arcParams=h}if("Z"===c)n=i,r=t[o+1];else{var p=l.length;n=[l[p-2],l[p-1]]}r&&"Z"===r[0]&&(r=t[o],e[o]&&(e[o].prePoint=n)),u.currentPoint=n,e[o]&&eJ(n,e[o].currentPoint)&&(e[o].prePoint=u.prePoint);var f=r?[r[r.length-2],r[r.length-1]]:null;u.nextPoint=f;var d=u.prePoint;if(["L","H","V"].includes(c))u.startTangent=[d[0]-n[0],d[1]-n[1]],u.endTangent=[n[0]-d[0],n[1]-d[1]];else if("Q"===c){var v=[l[1],l[2]];u.startTangent=[d[0]-v[0],d[1]-v[1]],u.endTangent=[n[0]-v[0],n[1]-v[1]]}else if("T"===c){var y=e[s-1],v=eQ(y.currentPoint,d);"Q"===y.command?(u.command="Q",u.startTangent=[d[0]-v[0],d[1]-v[1]],u.endTangent=[n[0]-v[0],n[1]-v[1]]):(u.command="TL",u.startTangent=[d[0]-n[0],d[1]-n[1]],u.endTangent=[n[0]-d[0],n[1]-d[1]])}else if("C"===c){var g=[l[1],l[2]],m=[l[3],l[4]];u.startTangent=[d[0]-g[0],d[1]-g[1]],u.endTangent=[n[0]-m[0],n[1]-m[1]],0===u.startTangent[0]&&0===u.startTangent[1]&&(u.startTangent=[g[0]-m[0],g[1]-m[1]]),0===u.endTangent[0]&&0===u.endTangent[1]&&(u.endTangent=[m[0]-g[0],m[1]-g[1]])}else if("S"===c){var y=e[s-1],g=eQ(y.currentPoint,d),m=[l[1],l[2]];"C"===y.command?(u.command="C",u.startTangent=[d[0]-g[0],d[1]-g[1]],u.endTangent=[n[0]-m[0],n[1]-m[1]]):(u.command="SQ",u.startTangent=[d[0]-m[0],d[1]-m[1]],u.endTangent=[n[0]-m[0],n[1]-m[1]])}else if("A"===c){var E=e2(u,0),x=E.x,b=E.y,T=e2(u,1,!1),P=T.x,S=T.y;u.startTangent=[x,b],u.endTangent=[P,S]}e.push(u)}return e}(e),s=function(t,e){for(var n=[],r=[],i=[],o=0;oMath.abs(q.determinant(tU))))){var a=tB[3],s=tB[7],l=tB[11],c=tB[12],u=tB[13],h=tB[14],p=tB[15];if(0!==a||0!==s||0!==l){if(tZ[0]=a,tZ[1]=s,tZ[2]=l,tZ[3]=p,!q.invert(tU,tU))return;q.transpose(tU,tU),$.fF(i,tZ,tU)}else i[0]=i[1]=i[2]=0,i[3]=1;if(e[0]=c,e[1]=u,e[2]=h,tV[0][0]=tB[0],tV[0][1]=tB[1],tV[0][2]=tB[2],tV[1][0]=tB[4],tV[1][1]=tB[5],tV[1][2]=tB[6],tV[2][0]=tB[8],tV[2][1]=tB[9],tV[2][2]=tB[10],n[0]=K.kE(tV[0]),K.Fv(tV[0],tV[0]),r[0]=K.AK(tV[0],tV[1]),tX(tV[1],tV[1],tV[0],1,-r[0]),n[1]=K.kE(tV[1]),K.Fv(tV[1],tV[1]),r[0]/=n[1],r[1]=K.AK(tV[0],tV[2]),tX(tV[2],tV[2],tV[0],1,-r[1]),r[2]=K.AK(tV[1],tV[2]),tX(tV[2],tV[2],tV[1],1,-r[2]),n[2]=K.kE(tV[2]),K.Fv(tV[2],tV[2]),r[1]/=n[2],r[2]/=n[2],K.kC(tY,tV[1],tV[2]),0>K.AK(tV[0],tY))for(var f=0;f<3;f++)n[f]*=-1,tV[f][0]*=-1,tV[f][1]*=-1,tV[f][2]*=-1;o[0]=.5*Math.sqrt(Math.max(1+tV[0][0]-tV[1][1]-tV[2][2],0)),o[1]=.5*Math.sqrt(Math.max(1-tV[0][0]+tV[1][1]-tV[2][2],0)),o[2]=.5*Math.sqrt(Math.max(1-tV[0][0]-tV[1][1]+tV[2][2],0)),o[3]=.5*Math.sqrt(Math.max(1+tV[0][0]+tV[1][1]+tV[2][2],0)),tV[2][1]>tV[1][2]&&(o[0]=-o[0]),tV[0][2]>tV[2][0]&&(o[1]=-o[1]),tV[1][0]>tV[0][1]&&(o[2]=-o[2])}}(0===t.length?[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]:t.map(nl).reduce(nc),e,n,r,i,o),[[e,n,r,o,i]]}var nh=function(){function t(t,e){for(var n=[[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0]],r=0;r<4;r++)for(var i=0;i<4;i++)for(var o=0;o<4;o++)n[r][i]+=e[r][o]*t[o][i];return n}return function(e,n,r,i,o){for(var a,s=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]],l=0;l<4;l++)s[l][3]=o[l];for(var l=0;l<3;l++)for(var c=0;c<3;c++)s[3][l]+=e[c]*s[c][l];var u=i[0],h=i[1],p=i[2],f=i[3],d=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]];d[0][0]=1-2*(h*h+p*p),d[0][1]=2*(u*h-p*f),d[0][2]=2*(u*p+h*f),d[1][0]=2*(u*h+p*f),d[1][1]=1-2*(u*u+p*p),d[1][2]=2*(h*p-u*f),d[2][0]=2*(u*p-h*f),d[2][1]=2*(h*p+u*f),d[2][2]=1-2*(u*u+h*h),s=t(s,d);var v=[[1,0,0,0],[0,1,0,0],[0,0,1,0],[0,0,0,1]];r[2]&&(v[2][1]=r[2],s=t(s,v)),r[1]&&(v[2][1]=0,v[2][0]=r[0],s=t(s,v)),r[0]&&(v[2][0]=0,v[1][0]=r[0],s=t(s,v));for(var l=0;l<3;l++)for(var c=0;c<3;c++)s[l][c]*=n[l];return 0==(a=s)[0][2]&&0==a[0][3]&&0==a[1][2]&&0==a[1][3]&&0==a[2][0]&&0==a[2][1]&&1==a[2][2]&&0==a[2][3]&&0==a[3][2]&&1==a[3][3]?[s[0][0],s[0][1],s[1][0],s[1][1],s[3][0],s[3][1]]:s[0].concat(s[1],s[2],s[3])}}();function np(t){return t.toFixed(6).replace(".000000","")}function nf(t,e){var n,r;return(t.decompositionPair!==e&&(t.decompositionPair=e,n=nu(t)),e.decompositionPair!==t&&(e.decompositionPair=t,r=nu(e)),null===n[0]||null===r[0])?[[!1],[!0],function(n){return n?e[0].d:t[0].d}]:(n[0].push(0),r[0].push(1),[n,r,function(t){var e=function(t,e,n){var r=function(t,e){for(var n=0,r=0;r"].calculator(null,null,{value:e.textTransform},t,null),e.clipPath&&this.runtime.CSSPropertySyntaxFactory[""].calculator("clipPath",o,e.clipPath,t,this.runtime),e.offsetPath&&this.runtime.CSSPropertySyntaxFactory[""].calculator("offsetPath",a,e.offsetPath,t,this.runtime),e.anchor&&(t.parsedStyle.anchor=eU(e.anchor,2)),e.transform&&(t.parsedStyle.transform=ns(e.transform)),e.transformOrigin&&(t.parsedStyle.transformOrigin=ng(e.transformOrigin)),e.markerStart&&(t.parsedStyle.markerStart=this.runtime.CSSPropertySyntaxFactory[""].calculator(null,e.markerStart,e.markerStart,null,null)),e.markerEnd&&(t.parsedStyle.markerEnd=this.runtime.CSSPropertySyntaxFactory[""].calculator(null,e.markerEnd,e.markerEnd,null,null)),e.markerMid&&(t.parsedStyle.markerMid=this.runtime.CSSPropertySyntaxFactory[""].calculator("",e.markerMid,e.markerMid,null,null)),(t.nodeName!==M.CIRCLE&&t.nodeName!==M.ELLIPSE||(0,tr.Z)(e.cx)&&(0,tr.Z)(e.cy))&&(t.nodeName!==M.RECT&&t.nodeName!==M.IMAGE&&t.nodeName!==M.GROUP&&t.nodeName!==M.HTML&&t.nodeName!==M.TEXT&&t.nodeName!==M.MESH||(0,tr.Z)(e.x)&&(0,tr.Z)(e.y)&&(0,tr.Z)(e.z))&&(t.nodeName!==M.LINE||(0,tr.Z)(e.x1)&&(0,tr.Z)(e.y1)&&(0,tr.Z)(e.z1)&&(0,tr.Z)(e.x2)&&(0,tr.Z)(e.y2)&&(0,tr.Z)(e.z2))||this.runtime.CSSPropertySyntaxFactory[""].postProcessor(t,i),(0,tr.Z)(e.zIndex)||this.runtime.CSSPropertySyntaxFactory[""].postProcessor(t,i),e.path&&this.runtime.CSSPropertySyntaxFactory[""].postProcessor(t,i),e.points&&this.runtime.CSSPropertySyntaxFactory[""].postProcessor(t,i),(0,tr.Z)(e.offsetDistance)||this.runtime.CSSPropertySyntaxFactory[""].postProcessor(t,i),e.transform&&this.runtime.CSSPropertySyntaxFactory[""].postProcessor(t,i),s&&this.updateGeometry(t);return}var c=n.skipUpdateAttribute,u=n.skipParse,h=n.forceUpdateGeometry,p=n.usedAttributes,f=h,d=Object.keys(e);d.forEach(function(n){var r;c||(t.attributes[n]=e[n]),!f&&(null===(r=nb[n])||void 0===r?void 0:r.l)&&(f=!0)}),u||d.forEach(function(e){t.computedStyle[e]=r.parseProperty(e,t.attributes[e],t)}),(null==p?void 0:p.length)&&(d=Array.from(new Set(d.concat(p)))),d.forEach(function(e){e in t.computedStyle&&(t.parsedStyle[e]=r.computeProperty(e,t.computedStyle[e],t))}),f&&this.updateGeometry(t),d.forEach(function(e){e in t.parsedStyle&&r.postProcessProperty(e,t,d)}),this.runtime.enableCSSParsing&&t.children.length&&d.forEach(function(e){e in t.parsedStyle&&r.isPropertyInheritable(e)&&t.children.forEach(function(t){t.internalSetAttribute(e,null,{skipUpdateAttribute:!0,skipParse:!0})})})},t.prototype.parseProperty=function(t,e,n){var r=nb[t],i=e;if((""===e||(0,tr.Z)(e))&&(e="unset"),"unset"===e||"initial"===e||"inherit"===e)i=ef(e);else if(r){var o=r.k,a=r.syntax,s=a&&this.getPropertySyntax(a);o&&o.indexOf(e)>-1?i=ef(e):s&&s.parser&&(i=s.parser(e,n))}return i},t.prototype.computeProperty=function(t,e,n){var r=nb[t],i="g-root"===n.id,o=e;if(r){var a=r.syntax,s=r.inh,l=r.d;if(e instanceof t7){var c=e.value;if("unset"===c&&(c=s&&!i?"inherit":"initial"),"initial"===c)(0,tr.Z)(l)||(e=this.parseProperty(t,en(l)?l(n.nodeName):l,n));else if("inherit"===c){var u=this.tryToResolveProperty(n,t,{inherited:!0});return(0,tr.Z)(u)?void this.addUnresolveProperty(n,t):u}}var h=a&&this.getPropertySyntax(a);if(h&&h.calculator){var p=n.parsedStyle[t];o=h.calculator(t,p,e,n,this.runtime)}else o=e instanceof t7?e.value:e}return o},t.prototype.postProcessProperty=function(t,e,n){var r=nb[t];if(r&&r.syntax){var i=r.syntax&&this.getPropertySyntax(r.syntax);i&&i.postProcessor&&i.postProcessor(e,n)}},t.prototype.addUnresolveProperty=function(t,e){var n=nT.get(t);n||(nT.set(t,[]),n=nT.get(t)),-1===n.indexOf(e)&&n.push(e)},t.prototype.tryToResolveProperty=function(t,e,n){if(void 0===n&&(n={}),n.inherited&&t.parentElement&&nP(t.parentElement,e)){var r=t.parentElement.parsedStyle[e];if("unset"!==r&&"initial"!==r&&"inherit"!==r)return r}},t.prototype.recalc=function(t){var e=nT.get(t);if(e&&e.length){var n={};e.forEach(function(e){n[e]=t.attributes[e]}),this.processProperties(t,n),nT.delete(t)}},t.prototype.updateGeometry=function(t){var e=t.nodeName,n=this.runtime.geometryUpdaterFactory[e];if(n){var r=t.geometry;r.contentBounds||(r.contentBounds=new tH),r.renderBounds||(r.renderBounds=new tH);var i=t.parsedStyle,o=n.update(i,t),a=o.width,s=o.height,l=o.depth,c=o.offsetX,u=o.offsetY,h=o.offsetZ,p=[Math.abs(a)/2,Math.abs(s)/2,(void 0===l?0:l)/2],f=i.stroke,d=i.lineWidth,v=i.increasedLineWidthForHitTesting,y=i.shadowType,g=i.shadowColor,m=i.filter,E=i.transformOrigin,x=i.anchor;e===M.TEXT?delete i.anchor:e===M.MESH&&(i.anchor[2]=.5);var b=[(1-2*(x&&x[0]||0))*a/2+(void 0===c?0:c),(1-2*(x&&x[1]||0))*s/2+(void 0===u?0:u),(1-2*(x&&x[2]||0))*p[2]+(void 0===h?0:h)];r.contentBounds.update(b,p);var T=e===M.POLYLINE||e===M.POLYGON||e===M.PATH?Math.SQRT2:.5;if(f&&!f.isNone){var P=((d||0)+(v||0))*T;p[0]+=P,p[1]+=P}if(r.renderBounds.update(b,p),g&&y&&"inner"!==y){var S=r.renderBounds,N=S.min,C=S.max,w=i.shadowBlur,k=i.shadowOffsetX,R=i.shadowOffsetY,A=w||0,O=k||0,L=R||0,I=N[0]-A+O,D=C[0]+A+O,G=N[1]-A+L,_=C[1]+A+L;N[0]=Math.min(N[0],I),C[0]=Math.max(C[0],D),N[1]=Math.min(N[1],G),C[1]=Math.max(C[1],_),r.renderBounds.setMinMax(N,C)}(void 0===m?[]:m).forEach(function(t){var e=t.name,n=t.params;if("blur"===e){var i=n[0].value;r.renderBounds.update(r.renderBounds.center,tA(r.renderBounds.halfExtents,r.renderBounds.halfExtents,[i,i,0]))}else if("drop-shadow"===e){var o=n[0].value,a=n[1].value,s=n[2].value,l=r.renderBounds,c=l.min,u=l.max,h=c[0]-s+o,p=u[0]+s+o,f=c[1]-s+a,d=u[1]+s+a;c[0]=Math.min(c[0],h),u[0]=Math.max(u[0],p),c[1]=Math.min(c[1],f),u[1]=Math.max(u[1],d),r.renderBounds.setMinMax(c,u)}}),x=i.anchor;var F=a<0,B=s<0,U=(F?-1:1)*(E?eV(E[0],0,t):0),Z=(B?-1:1)*(E?eV(E[1],1,t):0);U-=(F?-1:1)*(x&&x[0]||0)*r.contentBounds.halfExtents[0]*2,Z-=(B?-1:1)*(x&&x[1]||0)*r.contentBounds.halfExtents[1]*2,t.setOrigin(U,Z),this.runtime.sceneGraphService.dirtifyToRoot(t)}},t.prototype.isPropertyInheritable=function(t){var e=nb[t];return!!e&&e.inh},t}(),nN=function(){function t(){this.parser=eF,this.parserWithCSSDisabled=null,this.mixer=eW}return t.prototype.calculator=function(t,e,n,r){return eB(n)},t}(),nC=function(){function t(){}return t.prototype.calculator=function(t,e,n,r,i){return n instanceof t7&&(n=null),i.sceneGraphService.updateDisplayObjectDependency(t,e,n,r),"clipPath"===t&&r.forEach(function(t){0===t.childNodes.length&&i.sceneGraphService.dirtifyToRoot(t)}),n},t}(),nw=function(){function t(){this.parser=eL,this.parserWithCSSDisabled=eL,this.mixer=eI}return t.prototype.calculator=function(t,e,n,r){return n instanceof t7?"none"===n.value?ed:ev:n},t}(),nM=function(){function t(){this.parser=eX}return t.prototype.calculator=function(t,e,n){return n instanceof t7?[]:n},t}();function nk(t){var e=t.parsedStyle.fontSize;return(0,tr.Z)(e)?null:e}var nR=function(){function t(){this.parser=e_,this.parserWithCSSDisabled=null,this.mixer=eW}return t.prototype.calculator=function(t,e,n,r,i){if((0,te.Z)(n))return n;if(!es.isRelativeUnit(n.unit))return n.value;var o,a=i.styleValueRegistry;if(n.unit===I.kPercentage)return 0;if(n.unit===I.kEms){if(r.parentNode){var s=nk(r.parentNode);if(s)return s*n.value;a.addUnresolveProperty(r,t)}else a.addUnresolveProperty(r,t);return 0}if(n.unit===I.kRems){if(null===(o=null==r?void 0:r.ownerDocument)||void 0===o?void 0:o.documentElement){var s=nk(r.ownerDocument.documentElement);if(s)return s*n.value;a.addUnresolveProperty(r,t)}else a.addUnresolveProperty(r,t);return 0}},t}(),nA=function(){function t(){this.mixer=eK}return t.prototype.parser=function(t){var e=eZ((0,te.Z)(t)?[t]:t);return 1===e.length?[e[0],e[0]]:[e[0],e[1]]},t.prototype.calculator=function(t,e,n){return n.map(function(t){return t.value})},t}(),nO=function(){function t(){this.mixer=eK}return t.prototype.parser=function(t){var e=eZ((0,te.Z)(t)?[t]:t);return 1===e.length?[e[0],e[0],e[0],e[0]]:2===e.length?[e[0],e[1],e[0],e[1]]:3===e.length?[e[0],e[1],e[2],e[1]]:[e[0],e[1],e[2],e[3]]},t.prototype.calculator=function(t,e,n){return n.map(function(t){return t.value})},t}(),nL=q.create();function nI(t,e){var n=e.parsedStyle.defX||0,r=e.parsedStyle.defY||0;return e.resetLocalTransform(),e.setLocalPosition(n,r),t.forEach(function(t){var i=t.t,o=t.d;if("scale"===i){var a=(null==o?void 0:o.map(function(t){return t.value}))||[1,1];e.scaleLocal(a[0],a[1],1)}else if("scalex"===i){var a=(null==o?void 0:o.map(function(t){return t.value}))||[1];e.scaleLocal(a[0],1,1)}else if("scaley"===i){var a=(null==o?void 0:o.map(function(t){return t.value}))||[1];e.scaleLocal(1,a[0],1)}else if("scalez"===i){var a=(null==o?void 0:o.map(function(t){return t.value}))||[1];e.scaleLocal(1,1,a[0])}else if("scale3d"===i){var a=(null==o?void 0:o.map(function(t){return t.value}))||[1,1,1];e.scaleLocal(a[0],a[1],a[2])}else if("translate"===i){var s=o||[el,el];e.translateLocal(s[0].value,s[1].value,0)}else if("translatex"===i){var s=o||[el];e.translateLocal(s[0].value,0,0)}else if("translatey"===i){var s=o||[el];e.translateLocal(0,s[0].value,0)}else if("translatez"===i){var s=o||[el];e.translateLocal(0,0,s[0].value)}else if("translate3d"===i){var s=o||[el,el,el];e.translateLocal(s[0].value,s[1].value,s[2].value)}else if("rotate"===i){var l=o||[ec];e.rotateLocal(0,0,eB(l[0]))}else if("rotatex"===i){var l=o||[ec];e.rotateLocal(eB(l[0]),0,0)}else if("rotatey"===i){var l=o||[ec];e.rotateLocal(0,eB(l[0]),0)}else if("rotatez"===i){var l=o||[ec];e.rotateLocal(0,0,eB(l[0]))}else if("rotate3d"===i);else if("skew"===i){var c=(null==o?void 0:o.map(function(t){return t.value}))||[0,0];e.setLocalSkew(tD(c[0]),tD(c[1]))}else if("skewx"===i){var c=(null==o?void 0:o.map(function(t){return t.value}))||[0];e.setLocalSkew(tD(c[0]),e.getLocalSkew()[1])}else if("skewy"===i){var c=(null==o?void 0:o.map(function(t){return t.value}))||[0];e.setLocalSkew(e.getLocalSkew()[0],tD(c[0]))}else if("matrix"===i){var u=(0,W.CR)(o.map(function(t){return t.value}),6),h=u[0],p=u[1],f=u[2],d=u[3],v=u[4],y=u[5];e.setLocalTransform(q.set(nL,h,p,0,0,f,d,0,0,0,0,1,0,v+n,y+r,0,1))}else"matrix3d"===i&&(q.set.apply(q,(0,W.ev)([nL],(0,W.CR)(o.map(function(t){return t.value})),!1)),nL[12]+=n,nL[13]+=r,e.setLocalTransform(nL))}),e.getLocalTransform()}var nD=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,W.ZT)(e,t),e.prototype.postProcessor=function(t,e){switch(t.nodeName){case M.CIRCLE:case M.ELLIPSE:var n,r,i,o=t.parsedStyle,a=o.cx,s=o.cy,l=o.cz;(0,tr.Z)(a)||(n=a),(0,tr.Z)(s)||(r=s),(0,tr.Z)(l)||(i=l);break;case M.LINE:var c=t.parsedStyle,u=c.x1,h=c.x2,p=Math.min(c.y1,c.y2);n=Math.min(u,h),r=p,i=0;break;case M.RECT:case M.IMAGE:case M.GROUP:case M.HTML:case M.TEXT:case M.MESH:(0,tr.Z)(t.parsedStyle.x)||(n=t.parsedStyle.x),(0,tr.Z)(t.parsedStyle.y)||(r=t.parsedStyle.y),(0,tr.Z)(t.parsedStyle.z)||(i=t.parsedStyle.z)}if(t.nodeName!==M.PATH&&t.nodeName!==M.POLYLINE&&t.nodeName!==M.POLYGON&&(t.parsedStyle.defX=n||0,t.parsedStyle.defY=r||0),(!(0,tr.Z)(n)||!(0,tr.Z)(r)||!(0,tr.Z)(i))&&-1===e.indexOf("transform")){var f=t.parsedStyle.transform;if(f&&f.length)nI(f,t);else{var d=(0,W.CR)(t.getLocalPosition(),3),v=d[0],y=d[1],g=d[2];t.setLocalPosition((0,tr.Z)(n)?v:n,(0,tr.Z)(r)?y:r,(0,tr.Z)(i)?g:i)}}},e}(nR),nG=function(){function t(){}return t.prototype.calculator=function(t,e,n,r){n instanceof t7&&(n=null);var i=null==n?void 0:n.cloneNode(!0);return i&&(i.style.isMarker=!0),i},t}(),n_=function(){function t(){this.mixer=eW,this.parser=ej,this.parserWithCSSDisabled=null}return t.prototype.calculator=function(t,e,n){return n.value},t}(),nF=function(){function t(){this.parser=ej,this.parserWithCSSDisabled=null,this.mixer=ez(0,1)}return t.prototype.calculator=function(t,e,n){return n.value},t.prototype.postProcessor=function(t){var e=t.parsedStyle,n=e.offsetPath,r=e.offsetDistance;if(n){var i=n.nodeName;if(i===M.LINE||i===M.PATH||i===M.POLYLINE){var o=n.getPoint(r);o&&(t.parsedStyle.defX=o.x,t.parsedStyle.defY=o.y,t.setLocalPosition(o.x,o.y))}}},t}(),nB=function(){function t(){this.parser=ej,this.parserWithCSSDisabled=null,this.mixer=ez(0,1)}return t.prototype.calculator=function(t,e,n){return n.value},t}(),nU=function(){function t(){this.parser=nt,this.parserWithCSSDisabled=nt,this.mixer=ne}return t.prototype.calculator=function(t,e,n){return n instanceof t7&&"unset"===n.value?{absolutePath:[],hasArc:!1,segments:[],polygons:[],polylines:[],curve:null,totalLength:0,rect:new tK(0,0,0,0)}:n},t.prototype.postProcessor=function(t,e){if(t.parsedStyle.defX=t.parsedStyle.path.rect.x,t.parsedStyle.defY=t.parsedStyle.path.rect.y,t.nodeName===M.PATH&&-1===e.indexOf("transform")){var n=t.parsedStyle,r=n.defX,i=void 0===r?0:r,o=n.defY,a=void 0===o?0:o;t.setLocalPosition(i,a)}},t}(),nZ=function(){function t(){this.parser=nn,this.mixer=nr}return t.prototype.postProcessor=function(t,e){if((t.nodeName===M.POLYGON||t.nodeName===M.POLYLINE)&&-1===e.indexOf("transform")){var n=t.parsedStyle,r=n.defX,i=n.defY;t.setLocalPosition(r,i)}},t}(),nV=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.mixer=ez(0,1/0),e}return(0,W.ZT)(e,t),e}(nR),nY=function(){function t(){}return t.prototype.calculator=function(t,e,n,r){return n instanceof t7?"unset"===n.value?"":n.value:"".concat(n)},t.prototype.postProcessor=function(t){t.nodeValue="".concat(t.parsedStyle.text)||""},t}(),nX=function(){function t(){}return t.prototype.calculator=function(t,e,n,r){var i=r.getAttribute("text");if(i){var o=i;"capitalize"===n.value?o=i.charAt(0).toUpperCase()+i.slice(1):"lowercase"===n.value?o=i.toLowerCase():"uppercase"===n.value&&(o=i.toUpperCase()),r.parsedStyle.text=o}return n.value},t}(),nH={},nj=0,nW="undefined"!=typeof window&&void 0!==window.document;function nz(t,e){var n=Number(t.parsedStyle.zIndex),r=Number(e.parsedStyle.zIndex);if(n===r){var i=t.parentNode;if(i){var o=i.childNodes||[];return o.indexOf(t)-o.indexOf(e)}}return n-r}function nK(t){var e,n=t;do{if(null===(e=n.parsedStyle)||void 0===e?void 0:e.clipPath)return n;n=n.parentElement}while(null!==n);return null}function nq(t,e,n){nW&&t.style&&(t.style.width=e+"px",t.style.height=n+"px")}function nJ(t,e){if(nW)return document.defaultView.getComputedStyle(t,null).getPropertyValue(e)}var n$={touchstart:"pointerdown",touchend:"pointerup",touchendoutside:"pointerupoutside",touchmove:"pointermove",touchcancel:"pointercancel"},nQ="object"==typeof performance&&performance.now?performance:Date;function n0(t,e,n){var r=!1,i=!1,o=!!e&&!e.isNone,a=!!n&&!n.isNone;return"visiblepainted"===t||"painted"===t||"auto"===t?(r=o,i=a):"visiblefill"===t||"fill"===t?r=!0:"visiblestroke"===t||"stroke"===t?i=!0:("visible"===t||"all"===t)&&(r=!0,i=!0),[r,i]}var n1=1,n2="object"==typeof self&&self.self==self?self:"object"==typeof n.g&&n.g.global==n.g?n.g:{},n3=Date.now(),n5={},n4=Date.now(),n9=function(t){if("function"!=typeof t)throw TypeError(t+" is not a function");var e=Date.now(),n=e-n4,r=n1++;return n5[r]=t,Object.keys(n5).length>1||setTimeout(function(){n4=e;var t=n5;n5={},Object.keys(t).forEach(function(e){return t[e](n2.performance&&"function"==typeof n2.performance.now?n2.performance.now():Date.now()-n3)})},n>16?0:16-n),r},n8=function(t){return"string"!=typeof t?n9:""===t?n2.requestAnimationFrame:n2[t+"RequestAnimationFrame"]},n6=function(t,e){for(var n=0;void 0!==t[n];){if(e(t[n]))return t[n];n+=1}}(["","webkit","moz","ms","o"],function(t){return!!n8(t)}),n7=n8(n6),rt="string"!=typeof n6?function(t){delete n5[t]}:""===n6?n2.cancelAnimationFrame:n2[n6+"CancelAnimationFrame"]||n2[n6+"CancelRequestAnimationFrame"];n2.requestAnimationFrame=n7,n2.cancelAnimationFrame=rt;var re=function(){function t(){this.callbacks=[]}return t.prototype.getCallbacksNum=function(){return this.callbacks.length},t.prototype.tapPromise=function(t,e){this.callbacks.push(e)},t.prototype.promise=function(){for(var t=[],e=0;e-1){var l=(0,W.CR)(t.split(":"),2),c=l[0];t=l[1],s=c,a=!0}if(t=r?"".concat(t,"capture"):t,e=en(e)?e:e.handleEvent,a){var u=e;e=function(){for(var t,e=[],n=0;n0},e.prototype.isDefaultNamespace=function(t){throw Error(tq)},e.prototype.lookupNamespaceURI=function(t){throw Error(tq)},e.prototype.lookupPrefix=function(t){throw Error(tq)},e.prototype.normalize=function(){throw Error(tq)},e.prototype.isEqualNode=function(t){return this===t},e.prototype.isSameNode=function(t){return this.isEqualNode(t)},Object.defineProperty(e.prototype,"parent",{get:function(){return this.parentNode},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"parentElement",{get:function(){return null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"nextSibling",{get:function(){return null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"previousSibling",{get:function(){return null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"firstChild",{get:function(){return this.childNodes.length>0?this.childNodes[0]:null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"lastChild",{get:function(){return this.childNodes.length>0?this.childNodes[this.childNodes.length-1]:null},enumerable:!1,configurable:!0}),e.prototype.compareDocumentPosition=function(t){if(t===this)return 0;for(var n,r=t,i=this,o=[r],a=[i];null!==(n=r.parentNode)&&void 0!==n?n:i.parentNode;)r=r.parentNode?(o.push(r.parentNode),r.parentNode):r,i=i.parentNode?(a.push(i.parentNode),i.parentNode):i;if(r!==i)return e.DOCUMENT_POSITION_DISCONNECTED|e.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC|e.DOCUMENT_POSITION_PRECEDING;var s=o.length>a.length?o:a,l=s===o?a:o;if(s[s.length-l.length]===l[0])return s===o?e.DOCUMENT_POSITION_CONTAINED_BY|e.DOCUMENT_POSITION_FOLLOWING:e.DOCUMENT_POSITION_CONTAINS|e.DOCUMENT_POSITION_PRECEDING;for(var c=s.length-l.length,u=l.length-1;u>=0;u--){var h=l[u],p=s[c+u];if(p!==h){var f=h.parentNode.childNodes;if(f.indexOf(h)0&&e;)e=e.parentNode,t--;return e},e.prototype.forEach=function(t,e){void 0===e&&(e=!1),t(this)||(e?this.childNodes.slice():this.childNodes).forEach(function(e){e.forEach(t)})},e.DOCUMENT_POSITION_DISCONNECTED=1,e.DOCUMENT_POSITION_PRECEDING=2,e.DOCUMENT_POSITION_FOLLOWING=4,e.DOCUMENT_POSITION_CONTAINS=8,e.DOCUMENT_POSITION_CONTAINED_BY=16,e.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC=32,e}(rb),rP=function(){function t(t,e){var n=this;this.globalRuntime=t,this.context=e,this.emitter=new z.Z,this.cursor="default",this.mappingTable={},this.mappingState={trackingData:{}},this.eventPool=new Map,this.tmpMatrix=q.create(),this.tmpVec3=K.Ue(),this.onPointerDown=function(t){var e=n.createPointerEvent(t);if(n.dispatchEvent(e,"pointerdown"),"touch"===e.pointerType)n.dispatchEvent(e,"touchstart");else if("mouse"===e.pointerType||"pen"===e.pointerType){var r=2===e.button;n.dispatchEvent(e,r?"rightdown":"mousedown")}n.trackingData(t.pointerId).pressTargetsByButton[t.button]=e.composedPath(),n.freeEvent(e)},this.onPointerUp=function(t){var e,r=nQ.now(),i=n.createPointerEvent(t,void 0,void 0,n.context.config.alwaysTriggerPointerEventOnCanvas?n.rootTarget:void 0);if(n.dispatchEvent(i,"pointerup"),"touch"===i.pointerType)n.dispatchEvent(i,"touchend");else if("mouse"===i.pointerType||"pen"===i.pointerType){var o=2===i.button;n.dispatchEvent(i,o?"rightup":"mouseup")}var a=n.trackingData(t.pointerId),s=n.findMountedTarget(a.pressTargetsByButton[t.button]),l=s;if(s&&!i.composedPath().includes(s)){for(var c=s;c&&!i.composedPath().includes(c);){if(i.currentTarget=c,n.notifyTarget(i,"pointerupoutside"),"touch"===i.pointerType)n.notifyTarget(i,"touchendoutside");else if("mouse"===i.pointerType||"pen"===i.pointerType){var o=2===i.button;n.notifyTarget(i,o?"rightupoutside":"mouseupoutside")}rT.isNode(c)&&(c=c.parentNode)}delete a.pressTargetsByButton[t.button],l=c}if(l){var u=n.clonePointerEvent(i,"click");u.target=l,u.path=[],a.clicksByButton[t.button]||(a.clicksByButton[t.button]={clickCount:0,target:u.target,timeStamp:r});var h=a.clicksByButton[t.button];h.target===u.target&&r-h.timeStamp<200?++h.clickCount:h.clickCount=1,h.target=u.target,h.timeStamp=r,u.detail=h.clickCount,(null===(e=i.detail)||void 0===e?void 0:e.preventClick)||(n.context.config.useNativeClickEvent||"mouse"!==u.pointerType&&"touch"!==u.pointerType||n.dispatchEvent(u,"click"),n.dispatchEvent(u,"pointertap")),n.freeEvent(u)}n.freeEvent(i)},this.onPointerMove=function(t){var e=n.createPointerEvent(t,void 0,void 0,n.context.config.alwaysTriggerPointerEventOnCanvas?n.rootTarget:void 0),r="mouse"===e.pointerType||"pen"===e.pointerType,i=n.trackingData(t.pointerId),o=n.findMountedTarget(i.overTargets);if(i.overTargets&&o!==e.target){var a="mousemove"===t.type?"mouseout":"pointerout",s=n.createPointerEvent(t,a,o||void 0);if(n.dispatchEvent(s,"pointerout"),r&&n.dispatchEvent(s,"mouseout"),!e.composedPath().includes(o)){var l=n.createPointerEvent(t,"pointerleave",o||void 0);for(l.eventPhase=l.AT_TARGET;l.target&&!e.composedPath().includes(l.target);)l.currentTarget=l.target,n.notifyTarget(l),r&&n.notifyTarget(l,"mouseleave"),rT.isNode(l.target)&&(l.target=l.target.parentNode);n.freeEvent(l)}n.freeEvent(s)}if(o!==e.target){var c="mousemove"===t.type?"mouseover":"pointerover",u=n.clonePointerEvent(e,c);n.dispatchEvent(u,"pointerover"),r&&n.dispatchEvent(u,"mouseover");for(var h=o&&rT.isNode(o)&&o.parentNode;h&&h!==(rT.isNode(n.rootTarget)&&n.rootTarget.parentNode)&&h!==e.target;)h=h.parentNode;if(!h||h===(rT.isNode(n.rootTarget)&&n.rootTarget.parentNode)){var p=n.clonePointerEvent(e,"pointerenter");for(p.eventPhase=p.AT_TARGET;p.target&&p.target!==o&&p.target!==(rT.isNode(n.rootTarget)&&n.rootTarget.parentNode);)p.currentTarget=p.target,n.notifyTarget(p),r&&n.notifyTarget(p,"mouseenter"),rT.isNode(p.target)&&(p.target=p.target.parentNode);n.freeEvent(p)}n.freeEvent(u)}n.dispatchEvent(e,"pointermove"),"touch"===e.pointerType&&n.dispatchEvent(e,"touchmove"),r&&(n.dispatchEvent(e,"mousemove"),n.cursor=n.getCursor(e.target)),i.overTargets=e.composedPath(),n.freeEvent(e)},this.onPointerOut=function(t){var e=n.trackingData(t.pointerId);if(e.overTargets){var r="mouse"===t.pointerType||"pen"===t.pointerType,i=n.findMountedTarget(e.overTargets),o=n.createPointerEvent(t,"pointerout",i||void 0);n.dispatchEvent(o),r&&n.dispatchEvent(o,"mouseout");var a=n.createPointerEvent(t,"pointerleave",i||void 0);for(a.eventPhase=a.AT_TARGET;a.target&&a.target!==(rT.isNode(n.rootTarget)&&n.rootTarget.parentNode);)a.currentTarget=a.target,n.notifyTarget(a),r&&n.notifyTarget(a,"mouseleave"),rT.isNode(a.target)&&(a.target=a.target.parentNode);e.overTargets=null,n.freeEvent(o),n.freeEvent(a)}n.cursor=null},this.onPointerOver=function(t){var e=n.trackingData(t.pointerId),r=n.createPointerEvent(t),i="mouse"===r.pointerType||"pen"===r.pointerType;n.dispatchEvent(r,"pointerover"),i&&n.dispatchEvent(r,"mouseover"),"mouse"===r.pointerType&&(n.cursor=n.getCursor(r.target));var o=n.clonePointerEvent(r,"pointerenter");for(o.eventPhase=o.AT_TARGET;o.target&&o.target!==(rT.isNode(n.rootTarget)&&n.rootTarget.parentNode);)o.currentTarget=o.target,n.notifyTarget(o),i&&n.notifyTarget(o,"mouseenter"),rT.isNode(o.target)&&(o.target=o.target.parentNode);e.overTargets=r.composedPath(),n.freeEvent(r),n.freeEvent(o)},this.onPointerUpOutside=function(t){var e=n.trackingData(t.pointerId),r=n.findMountedTarget(e.pressTargetsByButton[t.button]),i=n.createPointerEvent(t);if(r){for(var o=r;o;)i.currentTarget=o,n.notifyTarget(i,"pointerupoutside"),"touch"===i.pointerType||("mouse"===i.pointerType||"pen"===i.pointerType)&&n.notifyTarget(i,2===i.button?"rightupoutside":"mouseupoutside"),rT.isNode(o)&&(o=o.parentNode);delete e.pressTargetsByButton[t.button]}n.freeEvent(i)},this.onWheel=function(t){var e=n.createWheelEvent(t);n.dispatchEvent(e),n.freeEvent(e)},this.onClick=function(t){if(n.context.config.useNativeClickEvent){var e=n.createPointerEvent(t);n.dispatchEvent(e),n.freeEvent(e)}},this.onPointerCancel=function(t){var e=n.createPointerEvent(t,void 0,void 0,n.context.config.alwaysTriggerPointerEventOnCanvas?n.rootTarget:void 0);n.dispatchEvent(e),n.freeEvent(e)}}return t.prototype.init=function(){this.rootTarget=this.context.renderingContext.root.parentNode,this.addEventMapping("pointerdown",this.onPointerDown),this.addEventMapping("pointerup",this.onPointerUp),this.addEventMapping("pointermove",this.onPointerMove),this.addEventMapping("pointerout",this.onPointerOut),this.addEventMapping("pointerleave",this.onPointerOut),this.addEventMapping("pointercancel",this.onPointerCancel),this.addEventMapping("pointerover",this.onPointerOver),this.addEventMapping("pointerupoutside",this.onPointerUpOutside),this.addEventMapping("wheel",this.onWheel),this.addEventMapping("click",this.onClick)},t.prototype.destroy=function(){this.emitter.removeAllListeners(),this.mappingTable={},this.mappingState={},this.eventPool.clear()},t.prototype.client2Viewport=function(t){var e=this.context.contextService.getBoundingClientRect();return new tz(t.x-((null==e?void 0:e.left)||0),t.y-((null==e?void 0:e.top)||0))},t.prototype.viewport2Client=function(t){var e=this.context.contextService.getBoundingClientRect();return new tz(t.x+((null==e?void 0:e.left)||0),t.y+((null==e?void 0:e.top)||0))},t.prototype.viewport2Canvas=function(t){var e=t.x,n=t.y,r=this.rootTarget.defaultView.getCamera(),i=this.context.config,o=i.width,a=i.height,s=r.getPerspectiveInverse(),l=r.getWorldTransform(),c=q.multiply(this.tmpMatrix,l,s),u=K.t8(this.tmpVec3,e/o*2-1,(1-n/a)*2-1,0);return K.fF(u,u,c),new tz(u[0],u[1])},t.prototype.canvas2Viewport=function(t){var e=this.rootTarget.defaultView.getCamera(),n=e.getPerspective(),r=e.getViewTransform(),i=q.multiply(this.tmpMatrix,n,r),o=K.t8(this.tmpVec3,t.x,t.y,0);K.fF(this.tmpVec3,this.tmpVec3,i);var a=this.context.config,s=a.width,l=a.height;return new tz((o[0]+1)/2*s,(1-(o[1]+1)/2)*l)},t.prototype.setPickHandler=function(t){this.pickHandler=t},t.prototype.addEventMapping=function(t,e){this.mappingTable[t]||(this.mappingTable[t]=[]),this.mappingTable[t].push({fn:e,priority:0}),this.mappingTable[t].sort(function(t,e){return t.priority-e.priority})},t.prototype.mapEvent=function(t){if(this.rootTarget){var e=this.mappingTable[t.type];if(e)for(var n=0,r=e.length;n=1;r--)if(t.currentTarget=n[r],this.notifyTarget(t,e),t.propagationStopped||t.propagationImmediatelyStopped)return;if(t.eventPhase=t.AT_TARGET,t.currentTarget=t.target,this.notifyTarget(t,e),!t.propagationStopped&&!t.propagationImmediatelyStopped){var i=n.indexOf(t.currentTarget);t.eventPhase=t.BUBBLING_PHASE;for(var r=i+1;ri||n>o?null:!a&&this.pickHandler(t)||this.rootTarget||null},t.prototype.isNativeEventFromCanvas=function(t){var e,n=this.context.contextService.getDomElement(),r=null===(e=t.nativeEvent)||void 0===e?void 0:e.target;if(r){if(r===n)return!0;if(n&&n.contains)return n.contains(r)}return!!t.nativeEvent.composedPath&&t.nativeEvent.composedPath().indexOf(n)>-1},t.prototype.getExistedHTML=function(t){var e,n;if(t.nativeEvent.composedPath)try{for(var r=(0,W.XA)(t.nativeEvent.composedPath()),i=r.next();!i.done;i=r.next()){var o=i.value,a=this.globalRuntime.nativeHTMLMap.get(o);if(a)return a}}catch(t){e={error:t}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(e)throw e.error}}return null},t.prototype.pickTarget=function(t){return this.hitTest({clientX:t.clientX,clientY:t.clientY,viewportX:t.viewportX,viewportY:t.viewportY,x:t.canvasX,y:t.canvasY})},t.prototype.createPointerEvent=function(t,e,n,r){var i=this.allocateEvent(rm);this.copyPointerData(t,i),this.copyMouseData(t,i),this.copyData(t,i),i.nativeEvent=t.nativeEvent,i.originalEvent=t;var o=this.getExistedHTML(i);return i.target=null!=n?n:o||this.isNativeEventFromCanvas(i)&&this.pickTarget(i)||r,"string"==typeof e&&(i.type=e),i},t.prototype.createWheelEvent=function(t){var e=this.allocateEvent(rE);this.copyWheelData(t,e),this.copyMouseData(t,e),this.copyData(t,e),e.nativeEvent=t.nativeEvent,e.originalEvent=t;var n=this.getExistedHTML(e);return e.target=n||this.isNativeEventFromCanvas(e)&&this.pickTarget(e),e},t.prototype.trackingData=function(t){return this.mappingState.trackingData[t]||(this.mappingState.trackingData[t]={pressTargetsByButton:{},clicksByButton:{},overTarget:null}),this.mappingState.trackingData[t]},t.prototype.cloneWheelEvent=function(t){var e=this.allocateEvent(rE);return e.nativeEvent=t.nativeEvent,e.originalEvent=t.originalEvent,this.copyWheelData(t,e),this.copyMouseData(t,e),this.copyData(t,e),e.target=t.target,e.path=t.composedPath().slice(),e.type=t.type,e},t.prototype.clonePointerEvent=function(t,e){var n=this.allocateEvent(rm);return n.nativeEvent=t.nativeEvent,n.originalEvent=t.originalEvent,this.copyPointerData(t,n),this.copyMouseData(t,n),this.copyData(t,n),n.target=t.target,n.path=t.composedPath().slice(),n.type=null!=e?e:n.type,n},t.prototype.copyPointerData=function(t,e){e.pointerId=t.pointerId,e.width=t.width,e.height=t.height,e.isPrimary=t.isPrimary,e.pointerType=t.pointerType,e.pressure=t.pressure,e.tangentialPressure=t.tangentialPressure,e.tiltX=t.tiltX,e.tiltY=t.tiltY,e.twist=t.twist},t.prototype.copyMouseData=function(t,e){e.altKey=t.altKey,e.button=t.button,e.buttons=t.buttons,e.ctrlKey=t.ctrlKey,e.metaKey=t.metaKey,e.shiftKey=t.shiftKey,e.client.copyFrom(t.client),e.movement.copyFrom(t.movement),e.canvas.copyFrom(t.canvas),e.screen.copyFrom(t.screen),e.global.copyFrom(t.global),e.offset.copyFrom(t.offset)},t.prototype.copyWheelData=function(t,e){e.deltaMode=t.deltaMode,e.deltaX=t.deltaX,e.deltaY=t.deltaY,e.deltaZ=t.deltaZ},t.prototype.copyData=function(t,e){e.isTrusted=t.isTrusted,e.timeStamp=nQ.now(),e.type=t.type,e.detail=t.detail,e.view=t.view,e.page.copyFrom(t.page),e.viewport.copyFrom(t.viewport)},t.prototype.allocateEvent=function(t){this.eventPool.has(t)||this.eventPool.set(t,[]);var e=this.eventPool.get(t).pop()||new t(this);return e.eventPhase=e.NONE,e.currentTarget=null,e.path=[],e.target=null,e},t.prototype.freeEvent=function(t){if(t.manager!==this)throw Error("It is illegal to free an event not managed by this EventBoundary!");var e=t.constructor;this.eventPool.has(e)||this.eventPool.set(e,[]),this.eventPool.get(e).push(t)},t.prototype.notifyTarget=function(t,e){e=null!=e?e:t.type;var n=t.eventPhase===t.CAPTURING_PHASE||t.eventPhase===t.AT_TARGET?"".concat(e,"capture"):e;this.notifyListeners(t,n),t.eventPhase===t.AT_TARGET&&this.notifyListeners(t,e)},t.prototype.notifyListeners=function(t,e){var n=t.currentTarget.emitter,r=n._events[e];if(r){if("fn"in r)r.once&&n.removeListener(e,r.fn,void 0,!0),r.fn.call(t.currentTarget||r.context,t);else for(var i=0;i=0;n--){var r=t[n];if(r===this.rootTarget||rT.isNode(r)&&r.parentNode===e)e=t[n];else break}return e},t.prototype.getCursor=function(t){for(var e=t;e;){var n=!!e.getAttribute&&e.getAttribute("cursor");if(n)return n;e=rT.isNode(e)&&e.parentNode}},t}(),rS=function(){function t(){}return t.prototype.getOrCreateCanvas=function(t,e){if(this.canvas)return this.canvas;if(t||r_.offscreenCanvas)this.canvas=t||r_.offscreenCanvas,this.context=this.canvas.getContext("2d",e);else try{this.canvas=new window.OffscreenCanvas(0,0),this.context=this.canvas.getContext("2d",e),this.context&&this.context.measureText||(this.canvas=document.createElement("canvas"),this.context=this.canvas.getContext("2d"))}catch(t){this.canvas=document.createElement("canvas"),this.context=this.canvas.getContext("2d",e)}return this.canvas.width=10,this.canvas.height=10,this.canvas},t.prototype.getOrCreateContext=function(t,e){return this.context||this.getOrCreateCanvas(t,e),this.context},t}();(E=X||(X={}))[E.CAMERA_CHANGED=0]="CAMERA_CHANGED",E[E.DISPLAY_OBJECT_CHANGED=1]="DISPLAY_OBJECT_CHANGED",E[E.NONE=2]="NONE";var rN=function(){function t(t,e){this.globalRuntime=t,this.context=e,this.inited=!1,this.stats={total:0,rendered:0},this.zIndexCounter=0,this.hooks={init:new rr,initAsync:new re,dirtycheck:new ri,cull:new ri,beginFrame:new rr,beforeRender:new rr,render:new rr,afterRender:new rr,endFrame:new rr,destroy:new rr,pick:new rn,pickSync:new ri,pointerDown:new rr,pointerUp:new rr,pointerMove:new rr,pointerOut:new rr,pointerOver:new rr,pointerWheel:new rr,pointerCancel:new rr,click:new rr}}return t.prototype.init=function(t){var e=this,n=(0,W.pi)((0,W.pi)({},this.globalRuntime),this.context);this.context.renderingPlugins.forEach(function(t){t.apply(n,e.globalRuntime)}),this.hooks.init.call(),0===this.hooks.initAsync.getCallbacksNum()?(this.inited=!0,t()):this.hooks.initAsync.promise().then(function(){e.inited=!0,t()})},t.prototype.getStats=function(){return this.stats},t.prototype.disableDirtyRectangleRendering=function(){return!this.context.config.renderer.getConfig().enableDirtyRectangleRendering||this.context.renderingContext.renderReasons.has(X.CAMERA_CHANGED)},t.prototype.render=function(t,e){var n=this;this.stats.total=0,this.stats.rendered=0,this.zIndexCounter=0;var r=this.context.renderingContext;if(this.globalRuntime.sceneGraphService.syncHierarchy(r.root),this.globalRuntime.sceneGraphService.triggerPendingEvents(),r.renderReasons.size&&this.inited){r.dirtyRectangleRenderingDisabled=this.disableDirtyRectangleRendering();var i=1===r.renderReasons.size&&r.renderReasons.has(X.CAMERA_CHANGED),o=!t.disableRenderHooks||!(t.disableRenderHooks&&i);o&&this.renderDisplayObject(r.root,t,r),this.hooks.beginFrame.call(),o&&r.renderListCurrentFrame.forEach(function(t){n.hooks.beforeRender.call(t),n.hooks.render.call(t),n.hooks.afterRender.call(t)}),this.hooks.endFrame.call(),r.renderListCurrentFrame=[],r.renderReasons.clear(),e()}},t.prototype.renderDisplayObject=function(t,e,n){var r=this,i=e.renderer.getConfig(),o=i.enableDirtyCheck,a=i.enableCulling;this.globalRuntime.enableCSSParsing&&this.globalRuntime.styleValueRegistry.recalc(t);var s=t.renderable,l=o?s.dirty||n.dirtyRectangleRenderingDisabled?t:null:t;if(l){var c=a?this.hooks.cull.call(l,this.context.camera):l;c&&(this.stats.rendered++,n.renderListCurrentFrame.push(c))}t.renderable.dirty=!1,t.sortable.renderOrder=this.zIndexCounter++,this.stats.total++;var u=t.sortable;u.dirty&&(this.sort(t,u),u.dirty=!1,u.dirtyChildren=[],u.dirtyReason=void 0),(u.sorted||t.childNodes).forEach(function(t){r.renderDisplayObject(t,e,n)})},t.prototype.sort=function(t,e){e.sorted&&e.dirtyReason!==V.Z_INDEX_CHANGED?e.dirtyChildren.forEach(function(n){if(-1===t.childNodes.indexOf(n)){var r=e.sorted.indexOf(n);r>=0&&e.sorted.splice(r,1)}else if(0===e.sorted.length)e.sorted.push(n);else{var i=function(t,e){for(var n=0,r=t.length;n>>1;0>nz(t[i],e)?n=i+1:r=i}return n}(e.sorted,n);e.sorted.splice(i,0,n)}}):e.sorted=t.childNodes.slice().sort(nz)},t.prototype.destroy=function(){this.inited=!1,this.hooks.destroy.call(),this.globalRuntime.sceneGraphService.clearPendingEvents()},t.prototype.dirtify=function(){this.context.renderingContext.renderReasons.add(X.DISPLAY_OBJECT_CHANGED)},t}(),rC=/\[\s*(.*)=(.*)\s*\]/,rw=function(){function t(){}return t.prototype.selectOne=function(t,e){var n=this;if(t.startsWith("."))return e.find(function(e){return((null==e?void 0:e.classList)||[]).indexOf(n.getIdOrClassname(t))>-1});if(t.startsWith("#"))return e.find(function(e){return e.id===n.getIdOrClassname(t)});if(!t.startsWith("["))return e.find(function(n){return e!==n&&n.nodeName===t});var r=this.getAttribute(t),i=r.name,o=r.value;return i?e.find(function(t){return e!==t&&("name"===i?t.name===o:n.attributeToString(t,i)===o)}):null},t.prototype.selectAll=function(t,e){var n=this;if(t.startsWith("."))return e.findAll(function(r){return e!==r&&((null==r?void 0:r.classList)||[]).indexOf(n.getIdOrClassname(t))>-1});if(t.startsWith("#"))return e.findAll(function(r){return e!==r&&r.id===n.getIdOrClassname(t)});if(!t.startsWith("["))return e.findAll(function(n){return e!==n&&n.nodeName===t});var r=this.getAttribute(t),i=r.name,o=r.value;return i?e.findAll(function(t){return e!==t&&("name"===i?t.name===o:n.attributeToString(t,i)===o)}):[]},t.prototype.is=function(t,e){if(t.startsWith("."))return e.className===this.getIdOrClassname(t);if(t.startsWith("#"))return e.id===this.getIdOrClassname(t);if(!t.startsWith("["))return e.nodeName===t;var n=this.getAttribute(t),r=n.name,i=n.value;return"name"===r?e.name===i:this.attributeToString(e,r)===i},t.prototype.getIdOrClassname=function(t){return t.substring(1)},t.prototype.getAttribute=function(t){var e=t.match(rC),n="",r="";return e&&e.length>2&&(n=e[1].replace(/"/g,""),r=e[2].replace(/"/g,"")),{name:n,value:r}},t.prototype.attributeToString=function(t,e){if(!t.getAttribute)return"";var n=t.getAttribute(e);return(0,tr.Z)(n)?"":n.toString?n.toString():""},t}(),rM=function(t){function e(e,n,r,i,o,a,s,l){var c=t.call(this,null)||this;return c.relatedNode=n,c.prevValue=r,c.newValue=i,c.attrName=o,c.attrChange=a,c.prevParsedValue=s,c.newParsedValue=l,c.type=e,c}return(0,W.ZT)(e,t),e.ADDITION=2,e.MODIFICATION=1,e.REMOVAL=3,e}(ry);function rk(t){var e=t.renderable;e&&(e.renderBoundsDirty=!0,e.boundsDirty=!0)}(x=H||(H={})).REPARENT="reparent",x.DESTROY="destroy",x.ATTR_MODIFIED="DOMAttrModified",x.INSERTED="DOMNodeInserted",x.REMOVED="removed",x.MOUNTED="DOMNodeInsertedIntoDocument",x.UNMOUNTED="DOMNodeRemovedFromDocument",x.BOUNDS_CHANGED="bounds-changed",x.CULLED="culled";var rR=new rM(H.REPARENT,null,"","","",0,"",""),rA=function(){function t(t){var e,n,r,i,o,a,s,l,c,u,h,p,f=this;this.runtime=t,this.pendingEvents=[],this.boundsChangedEvent=new rx(H.BOUNDS_CHANGED),this.rotate=(e=Q.Ue(),function(t,n,r,i){void 0===r&&(r=0),void 0===i&&(i=0),"number"==typeof n&&(n=K.al(n,r,i));var o=t.transformable;if(null!==t.parentNode&&t.parentNode.transformable){var a=Q.Ue();Q.Su(a,n[0],n[1],n[2]);var s=f.getRotation(t),l=f.getRotation(t.parentNode);Q.JG(e,l),Q.U_(e,e),Q.Jp(a,e,a),Q.Jp(o.localRotation,a,s),Q.Fv(o.localRotation,o.localRotation),f.dirtifyLocal(t,o)}else f.rotateLocal(t,n)}),this.rotateLocal=(n=Q.Ue(),function(t,e,r,i){void 0===r&&(r=0),void 0===i&&(i=0),"number"==typeof e&&(e=K.al(e,r,i));var o=t.transformable;Q.Su(n,e[0],e[1],e[2]),Q.dC(o.localRotation,o.localRotation,n),f.dirtifyLocal(t,o)}),this.setEulerAngles=(r=Q.Ue(),function(t,e,n,i){void 0===n&&(n=0),void 0===i&&(i=0),"number"==typeof e&&(e=K.al(e,n,i));var o=t.transformable;if(null!==t.parentNode&&t.parentNode.transformable){Q.Su(o.localRotation,e[0],e[1],e[2]);var a=f.getRotation(t.parentNode);Q.JG(r,Q.U_(Q.Ue(),a)),Q.dC(o.localRotation,o.localRotation,r),f.dirtifyLocal(t,o)}else f.setLocalEulerAngles(t,e)}),this.translateLocal=function(t,e,n,r){void 0===n&&(n=0),void 0===r&&(r=0),"number"==typeof e&&(e=K.al(e,n,r));var i=t.transformable;K.fS(e,K.Ue())||(K.VC(e,e,i.localRotation),K.IH(i.localPosition,i.localPosition,e),f.dirtifyLocal(t,i))},this.setPosition=(i=q.create(),o=K.Ue(),function(t,e){var n=t.transformable;if(o[0]=e[0],o[1]=e[1],o[2]=e[2]||0,!K.fS(f.getPosition(t),o)){if(K.JG(n.position,o),null!==t.parentNode&&t.parentNode.transformable){var r=t.parentNode.transformable;q.copy(i,r.worldTransform),q.invert(i,i),K.fF(n.localPosition,o,i)}else K.JG(n.localPosition,o);f.dirtifyLocal(t,n)}}),this.setLocalPosition=(a=K.Ue(),function(t,e){var n=t.transformable;a[0]=e[0],a[1]=e[1],a[2]=e[2]||0,K.fS(n.localPosition,a)||(K.JG(n.localPosition,a),f.dirtifyLocal(t,n))}),this.translate=(s=K.Ue(),l=K.Ue(),c=K.Ue(),function(t,e,n,r){void 0===n&&(n=0),void 0===r&&(r=0),"number"==typeof e&&(e=K.t8(l,e,n,r)),K.fS(e,s)||(K.IH(c,f.getPosition(t),e),f.setPosition(t,c))}),this.setRotation=function(){var t=Q.Ue();return function(e,n,r,i,o){var a=e.transformable;if("number"==typeof n&&(n=Q.al(n,r,i,o)),null!==e.parentNode&&e.parentNode.transformable){var s=f.getRotation(e.parentNode);Q.JG(t,s),Q.U_(t,t),Q.Jp(a.localRotation,t,n),Q.Fv(a.localRotation,a.localRotation),f.dirtifyLocal(e,a)}else f.setLocalRotation(e,n)}},this.displayObjectDependencyMap=new WeakMap,this.calcLocalTransform=(u=q.create(),h=K.Ue(),p=Q.al(0,0,0,1),function(t){if(0!==t.localSkew[0]||0!==t.localSkew[1]){if(q.fromRotationTranslationScaleOrigin(t.localTransform,t.localRotation,t.localPosition,K.al(1,1,1),t.origin),0!==t.localSkew[0]||0!==t.localSkew[1]){var e=q.identity(u);e[4]=Math.tan(t.localSkew[0]),e[1]=Math.tan(t.localSkew[1]),q.multiply(t.localTransform,t.localTransform,e)}var n=q.fromRotationTranslationScaleOrigin(u,p,h,t.localScale,t.origin);q.multiply(t.localTransform,t.localTransform,n)}else q.fromRotationTranslationScaleOrigin(t.localTransform,t.localRotation,t.localPosition,t.localScale,t.origin)})}return t.prototype.matches=function(t,e){return this.runtime.sceneGraphSelector.is(t,e)},t.prototype.querySelector=function(t,e){return this.runtime.sceneGraphSelector.selectOne(t,e)},t.prototype.querySelectorAll=function(t,e){return this.runtime.sceneGraphSelector.selectAll(t,e)},t.prototype.attach=function(t,e,n){var r,i,o=!1;t.parentNode&&(o=t.parentNode!==e,this.detach(t)),t.parentNode=e,(0,tr.Z)(n)?t.parentNode.childNodes.push(t):t.parentNode.childNodes.splice(n,0,t);var a=e.sortable;((null===(r=null==a?void 0:a.sorted)||void 0===r?void 0:r.length)||(null===(i=t.style)||void 0===i?void 0:i.zIndex))&&(-1===a.dirtyChildren.indexOf(t)&&a.dirtyChildren.push(t),a.dirty=!0,a.dirtyReason=V.ADDED);var s=t.transformable;s&&this.dirtifyWorld(t,s),s.frozen&&this.unfreezeParentToRoot(t),o&&t.dispatchEvent(rR)},t.prototype.detach=function(t){var e,n;if(t.parentNode){var r=t.transformable,i=t.parentNode.sortable;((null===(e=null==i?void 0:i.sorted)||void 0===e?void 0:e.length)||(null===(n=t.style)||void 0===n?void 0:n.zIndex))&&(-1===i.dirtyChildren.indexOf(t)&&i.dirtyChildren.push(t),i.dirty=!0,i.dirtyReason=V.REMOVED);var o=t.parentNode.childNodes.indexOf(t);o>-1&&t.parentNode.childNodes.splice(o,1),r&&this.dirtifyWorld(t,r),t.parentNode=null}},t.prototype.getOrigin=function(t){return t.transformable.origin},t.prototype.setOrigin=function(t,e,n,r){void 0===n&&(n=0),void 0===r&&(r=0),"number"==typeof e&&(e=[e,n,r]);var i=t.transformable;if(e[0]!==i.origin[0]||e[1]!==i.origin[1]||e[2]!==i.origin[2]){var o=i.origin;o[0]=e[0],o[1]=e[1],o[2]=e[2]||0,this.dirtifyLocal(t,i)}},t.prototype.setLocalEulerAngles=function(t,e,n,r){void 0===n&&(n=0),void 0===r&&(r=0),"number"==typeof e&&(e=K.al(e,n,r));var i=t.transformable;Q.Su(i.localRotation,e[0],e[1],e[2]),this.dirtifyLocal(t,i)},t.prototype.scaleLocal=function(t,e){var n=t.transformable;K.Jp(n.localScale,n.localScale,K.al(e[0],e[1],e[2]||1)),this.dirtifyLocal(t,n)},t.prototype.setLocalScale=function(t,e){var n=t.transformable,r=K.al(e[0],e[1],e[2]||n.localScale[2]);K.fS(r,n.localScale)||(K.JG(n.localScale,r),this.dirtifyLocal(t,n))},t.prototype.setLocalRotation=function(t,e,n,r,i){"number"==typeof e&&(e=Q.al(e,n,r,i));var o=t.transformable;Q.JG(o.localRotation,e),this.dirtifyLocal(t,o)},t.prototype.setLocalSkew=function(t,e,n){"number"==typeof e&&(e=tt.al(e,n));var r=t.transformable;tt.JG(r.localSkew,e),this.dirtifyLocal(t,r)},t.prototype.dirtifyLocal=function(t,e){e.localDirtyFlag||(e.localDirtyFlag=!0,e.dirtyFlag||this.dirtifyWorld(t,e))},t.prototype.dirtifyWorld=function(t,e){e.dirtyFlag||this.unfreezeParentToRoot(t),this.dirtifyWorldInternal(t,e),this.dirtifyToRoot(t,!0)},t.prototype.triggerPendingEvents=function(){var t=this,e=new Set,n=function(n,r){n.isConnected&&!e.has(n.entity)&&(t.boundsChangedEvent.detail=r,t.boundsChangedEvent.target=n,n.isMutationObserved?n.dispatchEvent(t.boundsChangedEvent):n.ownerDocument.defaultView.dispatchEvent(t.boundsChangedEvent,!0),e.add(n.entity))};this.pendingEvents.forEach(function(t){var e=(0,W.CR)(t,2),r=e[0],i=e[1];i.affectChildren?r.forEach(function(t){n(t,i)}):n(r,i)}),this.clearPendingEvents(),e.clear()},t.prototype.clearPendingEvents=function(){this.pendingEvents=[]},t.prototype.dirtifyToRoot=function(t,e){void 0===e&&(e=!1);var n=t;for(n.renderable&&(n.renderable.dirty=!0);n;)rk(n),n=n.parentNode;e&&t.forEach(function(t){rk(t)}),this.informDependentDisplayObjects(t),this.pendingEvents.push([t,{affectChildren:e}])},t.prototype.updateDisplayObjectDependency=function(t,e,n,r){if(e&&e!==n){var i=this.displayObjectDependencyMap.get(e);if(i&&i[t]){var o=i[t].indexOf(r);i[t].splice(o,1)}}if(n){var a=this.displayObjectDependencyMap.get(n);a||(this.displayObjectDependencyMap.set(n,{}),a=this.displayObjectDependencyMap.get(n)),a[t]||(a[t]=[]),a[t].push(r)}},t.prototype.informDependentDisplayObjects=function(t){var e=this,n=this.displayObjectDependencyMap.get(t);n&&Object.keys(n).forEach(function(t){n[t].forEach(function(n){e.dirtifyToRoot(n,!0),n.dispatchEvent(new rM(H.ATTR_MODIFIED,n,e,e,t,rM.MODIFICATION,e,e)),n.isCustomElement&&n.isConnected&&n.attributeChangedCallback&&n.attributeChangedCallback(t,e,e)})})},t.prototype.getPosition=function(t){var e=t.transformable;return q.getTranslation(e.position,this.getWorldTransform(t,e))},t.prototype.getRotation=function(t){var e=t.transformable;return q.getRotation(e.rotation,this.getWorldTransform(t,e))},t.prototype.getScale=function(t){var e=t.transformable;return q.getScaling(e.scaling,this.getWorldTransform(t,e))},t.prototype.getWorldTransform=function(t,e){return void 0===e&&(e=t.transformable),(e.localDirtyFlag||e.dirtyFlag)&&(t.parentNode&&t.parentNode.transformable&&this.getWorldTransform(t.parentNode),this.sync(t,e)),e.worldTransform},t.prototype.getLocalPosition=function(t){return t.transformable.localPosition},t.prototype.getLocalRotation=function(t){return t.transformable.localRotation},t.prototype.getLocalScale=function(t){return t.transformable.localScale},t.prototype.getLocalSkew=function(t){return t.transformable.localSkew},t.prototype.getLocalTransform=function(t){var e=t.transformable;return e.localDirtyFlag&&(this.calcLocalTransform(e),e.localDirtyFlag=!1),e.localTransform},t.prototype.setLocalTransform=function(t,e){var n=q.getTranslation(K.Ue(),e),r=q.getRotation(Q.Ue(),e),i=q.getScaling(K.Ue(),e);this.setLocalScale(t,i),this.setLocalPosition(t,n),this.setLocalRotation(t,r)},t.prototype.resetLocalTransform=function(t){this.setLocalScale(t,[1,1,1]),this.setLocalPosition(t,[0,0,0]),this.setLocalEulerAngles(t,[0,0,0]),this.setLocalSkew(t,[0,0])},t.prototype.getTransformedGeometryBounds=function(t,e,n){void 0===e&&(e=!1);var r=this.getGeometryBounds(t,e);if(tH.isEmpty(r))return null;var i=n||new tH;return i.setFromTransformedAABB(r,this.getWorldTransform(t)),i},t.prototype.getGeometryBounds=function(t,e){void 0===e&&(e=!1);var n=t.geometry;return(e?n.renderBounds:n.contentBounds||null)||new tH},t.prototype.getBounds=function(t,e){var n=this;void 0===e&&(e=!1);var r=t.renderable;if(!r.boundsDirty&&!e&&r.bounds)return r.bounds;if(!r.renderBoundsDirty&&e&&r.renderBounds)return r.renderBounds;var i=e?r.renderBounds:r.bounds,o=this.getTransformedGeometryBounds(t,e,i);if(t.childNodes.forEach(function(t){var r=n.getBounds(t,e);r&&(o?o.add(r):(o=i||new tH).update(r.center,r.halfExtents))}),e){var a=nK(t);if(a){var s=a.parsedStyle.clipPath.getBounds(e);o?s&&(o=s.intersection(o)):o=s}}return o||(o=new tH),o&&(e?r.renderBounds=o:r.bounds=o),e?r.renderBoundsDirty=!1:r.boundsDirty=!1,o},t.prototype.getLocalBounds=function(t){if(t.parentNode){var e=q.create();t.parentNode.transformable&&(e=q.invert(q.create(),this.getWorldTransform(t.parentNode)));var n=this.getBounds(t);if(!tH.isEmpty(n)){var r=new tH;return r.setFromTransformedAABB(n,e),r}}return this.getBounds(t)},t.prototype.getBoundingClientRect=function(t){var e,n,r,i=this.getGeometryBounds(t);tH.isEmpty(i)||(r=new tH).setFromTransformedAABB(i,this.getWorldTransform(t));var o=null===(n=null===(e=t.ownerDocument)||void 0===e?void 0:e.defaultView)||void 0===n?void 0:n.getContextService().getBoundingClientRect();if(r){var a=(0,W.CR)(r.getMin(),2),s=a[0],l=a[1],c=(0,W.CR)(r.getMax(),2),u=c[0],h=c[1];return new tK(s+((null==o?void 0:o.left)||0),l+((null==o?void 0:o.top)||0),u-s,h-l)}return new tK((null==o?void 0:o.left)||0,(null==o?void 0:o.top)||0,0,0)},t.prototype.dirtifyWorldInternal=function(t,e){var n=this;if(!e.dirtyFlag){e.dirtyFlag=!0,e.frozen=!1,t.childNodes.forEach(function(t){var e=t.transformable;e.dirtyFlag||n.dirtifyWorldInternal(t,e)});var r=t.renderable;r&&(r.renderBoundsDirty=!0,r.boundsDirty=!0,r.dirty=!0)}},t.prototype.syncHierarchy=function(t){var e=t.transformable;if(!e.frozen){e.frozen=!0,(e.localDirtyFlag||e.dirtyFlag)&&this.sync(t,e);for(var n=t.childNodes,r=0;rs;--p){for(var v=0;v=0;l--){var c=s[l].trim();!ra.test(c)&&0>ro.indexOf(c)&&(c='"'.concat(c,'"')),s[l]=c}return"".concat(r," ").concat(i," ").concat(o," ").concat(a," ").concat(s.join(","))}(e),d=this.measureFont(f,n);0===d.fontSize&&(d.fontSize=r,d.ascent=r);var v=this.runtime.offscreenCanvasCreator.getOrCreateContext(n);v.font=f,e.isOverflowing=!1;var y=(i?this.wordWrap(t,e,n):t).split(/(?:\r\n|\r|\n)/),g=Array(y.length),m=0;if(u){u.getTotalLength();for(var E=0;E=s){e.isOverflowing=!0;break}d=0,p[f]="";continue}if(d>0&&d+P>u){if(f+1>=s){if(e.isOverflowing=!0,g>0&&g<=u){for(var S=p[f].length,N=0,C=S,w=0;wu){C=w;break}N+=M}p[f]=(p[f]||"").slice(0,C)+h}break}if(d=0,p[++f]="",this.isBreakingSpace(x))continue;this.canBreakInLastChar(x)||(p=this.trimToBreakable(p),d=this.sumTextWidthByCache(p[f]||"",v)),this.shouldBreakByKinsokuShorui(x,T)&&(p=this.trimByKinsokuShorui(p),d+=y(b||""))}d+=P,p[f]=(p[f]||"")+x}return p.join("\n")},t.prototype.isBreakingSpace=function(t){return"string"==typeof t&&rO.BreakingSpaces.indexOf(t.charCodeAt(0))>=0},t.prototype.isNewline=function(t){return"string"==typeof t&&rO.Newlines.indexOf(t.charCodeAt(0))>=0},t.prototype.trimToBreakable=function(t){var e=(0,W.ev)([],(0,W.CR)(t),!1),n=e[e.length-2],r=this.findBreakableIndex(n);if(-1===r||!n)return e;var i=n.slice(r,r+1),o=this.isBreakingSpace(i),a=r+1,s=r+(o?0:1);return e[e.length-1]+=n.slice(a,n.length),e[e.length-2]=n.slice(0,s),e},t.prototype.canBreakInLastChar=function(t){return!(t&&rL.test(t))},t.prototype.sumTextWidthByCache=function(t,e){return t.split("").reduce(function(t,n){if(!e[n])throw Error("cannot count the word without cache");return t+e[n]},0)},t.prototype.findBreakableIndex=function(t){for(var e=t.length-1;e>=0;e--)if(!rL.test(t[e]))return e;return -1},t.prototype.getFromCache=function(t,e,n,r){var i=n[t];if("number"!=typeof i){var o=t.length*e;i=r.measureText(t).width+o,n[t]=i}return i},t}(),r_={},rF=(T=new rd,P=new rf,(b={})[M.CIRCLE]=new rc,b[M.ELLIPSE]=new ru,b[M.RECT]=T,b[M.IMAGE]=T,b[M.GROUP]=T,b[M.LINE]=new rh,b[M.TEXT]=new rv(r_),b[M.POLYLINE]=P,b[M.POLYGON]=P,b[M.PATH]=new rp,b[M.HTML]=null,b[M.MESH]=null,b),rB=(N=new nw,C=new nR,(S={})[Y.PERCENTAGE]=null,S[Y.NUMBER]=new n_,S[Y.ANGLE]=new nN,S[Y.DEFINED_PATH]=new nC,S[Y.PAINT]=N,S[Y.COLOR]=N,S[Y.FILTER]=new nM,S[Y.LENGTH]=C,S[Y.LENGTH_PERCENTAGE]=C,S[Y.LENGTH_PERCENTAGE_12]=new nA,S[Y.LENGTH_PERCENTAGE_14]=new nO,S[Y.COORDINATE]=new nD,S[Y.OFFSET_DISTANCE]=new nF,S[Y.OPACITY_VALUE]=new nB,S[Y.PATH]=new nU,S[Y.LIST_OF_POINTS]=new nZ,S[Y.SHADOW_BLUR]=new nV,S[Y.TEXT]=new nY,S[Y.TEXT_TRANSFORM]=new nX,S[Y.TRANSFORM]=new rs,S[Y.TRANSFORM_ORIGIN]=new function(){this.parser=ng},S[Y.Z_INDEX]=new rl,S[Y.MARKER]=new nG,S);r_.CameraContribution=tQ,r_.AnimationTimeline=null,r_.EasingFunction=null,r_.offscreenCanvasCreator=new rS,r_.nativeHTMLMap=new WeakMap,r_.sceneGraphSelector=new rw,r_.sceneGraphService=new rA(r_),r_.textService=new rG(r_),r_.geometryUpdaterFactory=rF,r_.CSSPropertySyntaxFactory=rB,r_.styleValueRegistry=new nS(r_),r_.layoutRegistry=null,r_.globalThis="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0!==n.g?n.g:{},r_.enableCSSParsing=!0,r_.enableDataset=!1,r_.enableStyleSyntax=!0;var rU=0,rZ=new rM(H.INSERTED,null,"","","",0,"",""),rV=new rM(H.REMOVED,null,"","","",0,"",""),rY=new rx(H.DESTROY),rX=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.entity=rU++,e.renderable={bounds:void 0,boundsDirty:!0,renderBounds:void 0,renderBoundsDirty:!0,dirtyRenderBounds:void 0,dirty:!1},e.cullable={strategy:Z.Standard,visibilityPlaneMask:-1,visible:!0,enable:!0},e.transformable={dirtyFlag:!1,localDirtyFlag:!1,frozen:!1,localPosition:[0,0,0],localRotation:[0,0,0,1],localScale:[1,1,1],localTransform:[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1],localSkew:[0,0],position:[0,0,0],rotation:[0,0,0,1],scaling:[1,1,1],worldTransform:[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1],origin:[0,0,0]},e.sortable={dirty:!1,sorted:void 0,renderOrder:0,dirtyChildren:[],dirtyReason:void 0},e.geometry={contentBounds:void 0,renderBounds:void 0},e.rBushNode={aabb:void 0},e.namespaceURI="g",e.scrollLeft=0,e.scrollTop=0,e.clientTop=0,e.clientLeft=0,e.destroyed=!1,e.style={},e.computedStyle=r_.enableCSSParsing?{anchor:eh,opacity:eh,fillOpacity:eh,strokeOpacity:eh,fill:eh,stroke:eh,transform:eh,transformOrigin:eh,visibility:eh,pointerEvents:eh,lineWidth:eh,lineCap:eh,lineJoin:eh,increasedLineWidthForHitTesting:eh,fontSize:eh,fontFamily:eh,fontStyle:eh,fontWeight:eh,fontVariant:eh,textAlign:eh,textBaseline:eh,textTransform:eh,zIndex:eh,filter:eh,shadowType:eh}:null,e.parsedStyle={},e.attributes={},e}return(0,W.ZT)(e,t),Object.defineProperty(e.prototype,"className",{get:function(){return this.getAttribute("class")||""},set:function(t){this.setAttribute("class",t)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"classList",{get:function(){return this.className.split(" ").filter(function(t){return""!==t})},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tagName",{get:function(){return this.nodeName},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"children",{get:function(){return this.childNodes},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"childElementCount",{get:function(){return this.childNodes.length},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"firstElementChild",{get:function(){return this.firstChild},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"lastElementChild",{get:function(){return this.lastChild},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"parentElement",{get:function(){return this.parentNode},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"nextSibling",{get:function(){if(this.parentNode){var t=this.parentNode.childNodes.indexOf(this);return this.parentNode.childNodes[t+1]||null}return null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"previousSibling",{get:function(){if(this.parentNode){var t=this.parentNode.childNodes.indexOf(this);return this.parentNode.childNodes[t-1]||null}return null},enumerable:!1,configurable:!0}),e.prototype.cloneNode=function(t){throw Error(tq)},e.prototype.appendChild=function(t,e){var n;if(t.destroyed)throw Error("Cannot append a destroyed element.");return r_.sceneGraphService.attach(t,this,e),(null===(n=this.ownerDocument)||void 0===n?void 0:n.defaultView)&&this.ownerDocument.defaultView.mountChildren(t),rZ.relatedNode=this,t.dispatchEvent(rZ),t},e.prototype.insertBefore=function(t,e){if(e){t.parentElement&&t.parentElement.removeChild(t);var n=this.childNodes.indexOf(e);-1===n?this.appendChild(t):this.appendChild(t,n)}else this.appendChild(t);return t},e.prototype.replaceChild=function(t,e){var n=this.childNodes.indexOf(e);return this.removeChild(e),this.appendChild(t,n),e},e.prototype.removeChild=function(t){var e;return rV.relatedNode=this,t.dispatchEvent(rV),(null===(e=t.ownerDocument)||void 0===e?void 0:e.defaultView)&&t.ownerDocument.defaultView.unmountChildren(t),r_.sceneGraphService.detach(t),t},e.prototype.removeChildren=function(){for(var t=this.childNodes.length-1;t>=0;t--){var e=this.childNodes[t];this.removeChild(e)}},e.prototype.destroyChildren=function(){for(var t=this.childNodes.length-1;t>=0;t--){var e=this.childNodes[t];e.childNodes.length&&e.destroyChildren(),e.destroy()}},e.prototype.matches=function(t){return r_.sceneGraphService.matches(t,this)},e.prototype.getElementById=function(t){return r_.sceneGraphService.querySelector("#".concat(t),this)},e.prototype.getElementsByName=function(t){return r_.sceneGraphService.querySelectorAll('[name="'.concat(t,'"]'),this)},e.prototype.getElementsByClassName=function(t){return r_.sceneGraphService.querySelectorAll(".".concat(t),this)},e.prototype.getElementsByTagName=function(t){return r_.sceneGraphService.querySelectorAll(t,this)},e.prototype.querySelector=function(t){return r_.sceneGraphService.querySelector(t,this)},e.prototype.querySelectorAll=function(t){return r_.sceneGraphService.querySelectorAll(t,this)},e.prototype.closest=function(t){var e=this;do{if(r_.sceneGraphService.matches(t,e))return e;e=e.parentElement}while(null!==e);return null},e.prototype.find=function(t){var e=this,n=null;return this.forEach(function(r){return!!(r!==e&&t(r))&&(n=r,!0)}),n},e.prototype.findAll=function(t){var e=this,n=[];return this.forEach(function(r){r!==e&&t(r)&&n.push(r)}),n},e.prototype.after=function(){for(var t=this,e=[],n=0;n1){var n=t[0].currentPoint,r=t[1].currentPoint,i=t[1].startTangent;e=[],i?(e.push([n[0]-i[0],n[1]-i[1]]),e.push([n[0],n[1]])):(e.push([r[0],r[1]]),e.push([n[0],n[1]]))}return e},e.prototype.getEndTangent=function(){var t=this.parsedStyle.path.segments,e=t.length,n=[];if(e>1){var r=t[e-2].currentPoint,i=t[e-1].currentPoint,o=t[e-1].endTangent;n=[],o?(n.push([i[0]-o[0],i[1]-o[1]]),n.push([i[0],i[1]])):(n.push([r[0],r[1]]),n.push([i[0],i[1]]))}return n},e}(r$),r6=function(t){function e(e){var n=this;void 0===e&&(e={});var r=e.style,i=(0,W._T)(e,["style"]);(n=t.call(this,(0,W.pi)({type:M.POLYGON,style:r_.enableCSSParsing?(0,W.pi)({points:"",miterLimit:"",isClosed:!0},r):(0,W.pi)({},r),initialParsedStyle:r_.enableCSSParsing?null:{points:{points:[],totalLength:0,segments:[]},miterLimit:4,isClosed:!0}},i))||this).markerStartAngle=0,n.markerEndAngle=0,n.markerMidList=[];var o=n.parsedStyle,a=o.markerStart,s=o.markerEnd,l=o.markerMid;return a&&rH(a)&&(n.markerStartAngle=a.getLocalEulerAngles(),n.appendChild(a)),l&&rH(l)&&n.placeMarkerMid(l),s&&rH(s)&&(n.markerEndAngle=s.getLocalEulerAngles(),n.appendChild(s)),n.transformMarker(!0),n.transformMarker(!1),n}return(0,W.ZT)(e,t),e.prototype.attributeChangedCallback=function(t,e,n,r,i){"points"===t?(this.transformMarker(!0),this.transformMarker(!1),this.placeMarkerMid(this.parsedStyle.markerMid)):"markerStartOffset"===t||"markerEndOffset"===t?(this.transformMarker(!0),this.transformMarker(!1)):"markerStart"===t?(r&&rH(r)&&(this.markerStartAngle=0,r.remove()),i&&rH(i)&&(this.markerStartAngle=i.getLocalEulerAngles(),this.appendChild(i),this.transformMarker(!0))):"markerEnd"===t?(r&&rH(r)&&(this.markerEndAngle=0,r.remove()),i&&rH(i)&&(this.markerEndAngle=i.getLocalEulerAngles(),this.appendChild(i),this.transformMarker(!1))):"markerMid"===t&&this.placeMarkerMid(i)},e.prototype.transformMarker=function(t){var e,n,r,i,o,a,s=this.parsedStyle,l=s.markerStart,c=s.markerEnd,u=s.markerStartOffset,h=s.markerEndOffset,p=s.points,f=s.defX,d=s.defY,v=(p||{}).points,y=t?l:c;if(y&&rH(y)&&v){var g=0;if(r=v[0][0]-f,i=v[0][1]-d,t)e=v[1][0]-v[0][0],n=v[1][1]-v[0][1],o=u||0,a=this.markerStartAngle;else{var m=v.length;this.parsedStyle.isClosed?(e=v[m-1][0]-v[0][0],n=v[m-1][1]-v[0][1]):(r=v[m-1][0]-f,i=v[m-1][1]-d,e=v[m-2][0]-v[m-1][0],n=v[m-2][1]-v[m-1][1]),o=h||0,a=this.markerEndAngle}g=Math.atan2(n,e),y.setLocalEulerAngles(180*g/Math.PI+a),y.setLocalPosition(r+Math.cos(g)*o,i+Math.sin(g)*o)}},e.prototype.placeMarkerMid=function(t){var e=this.parsedStyle,n=e.points,r=e.defX,i=e.defY,o=(n||{}).points;if(this.markerMidList.forEach(function(t){t.remove()}),this.markerMidList=[],t&&rH(t)&&o)for(var a=1;a<(this.parsedStyle.isClosed?o.length:o.length-1);a++){var s=o[a][0]-r,l=o[a][1]-i,c=1===a?t:t.cloneNode(!0);this.markerMidList.push(c),this.appendChild(c),c.setLocalPosition(s,l)}},e}(r$),r7=function(t){function e(e){void 0===e&&(e={});var n=e.style,r=(0,W._T)(e,["style"]);return t.call(this,(0,W.pi)({type:M.POLYLINE,style:r_.enableCSSParsing?(0,W.pi)({points:"",miterLimit:"",isClosed:!1},n):(0,W.pi)({},n),initialParsedStyle:r_.enableCSSParsing?null:{points:{points:[],totalLength:0,segments:[]},miterLimit:4,isClosed:!1}},r))||this}return(0,W.ZT)(e,t),e.prototype.getTotalLength=function(){return this.parsedStyle.points.totalLength},e.prototype.getPointAtLength=function(t,e){return void 0===e&&(e=!1),this.getPoint(t/this.getTotalLength(),e)},e.prototype.getPoint=function(t,e){void 0===e&&(e=!1);var n=this.parsedStyle,r=n.defX,i=n.defY,o=n.points,a=o.points,s=o.segments,l=0,c=0;s.forEach(function(e,n){t>=e[0]&&t<=e[1]&&(l=(t-e[0])/(e[1]-e[0]),c=n)});var u=(0,tS.U4)(a[c][0],a[c][1],a[c+1][0],a[c+1][1],l),h=u.x,p=u.y,f=K.fF(K.Ue(),K.al(h-r,p-i,0),e?this.getWorldTransform():this.getLocalTransform());return new tz(f[0],f[1])},e.prototype.getStartTangent=function(){var t=this.parsedStyle.points.points,e=[];return e.push([t[1][0],t[1][1]]),e.push([t[0][0],t[0][1]]),e},e.prototype.getEndTangent=function(){var t=this.parsedStyle.points.points,e=t.length-1,n=[];return n.push([t[e-1][0],t[e-1][1]]),n.push([t[e][0],t[e][1]]),n},e}(r6),it=function(t){function e(e){void 0===e&&(e={});var n=e.style,r=(0,W._T)(e,["style"]);return t.call(this,(0,W.pi)({type:M.RECT,style:r_.enableCSSParsing?(0,W.pi)({x:"",y:"",width:"",height:"",radius:""},n):(0,W.pi)({},n)},r))||this}return(0,W.ZT)(e,t),e}(r$),ie=function(t){function e(e){void 0===e&&(e={});var n=e.style,r=(0,W._T)(e,["style"]);return t.call(this,(0,W.pi)({type:M.TEXT,style:r_.enableCSSParsing?(0,W.pi)({x:"",y:"",text:"",fontSize:"",fontFamily:"",fontStyle:"",fontWeight:"",fontVariant:"",textAlign:"",textBaseline:"",textTransform:"",fill:"black",letterSpacing:"",lineHeight:"",miterLimit:"",wordWrap:!1,wordWrapWidth:0,leading:0,dx:"",dy:""},n):(0,W.pi)({fill:"black"},n),initialParsedStyle:r_.enableCSSParsing?{}:{x:0,y:0,fontSize:16,fontFamily:"sans-serif",fontStyle:"normal",fontWeight:"normal",fontVariant:"normal",lineHeight:0,letterSpacing:0,textBaseline:"alphabetic",textAlign:"start",wordWrap:!1,wordWrapWidth:0,leading:0,dx:0,dy:0}},r))||this}return(0,W.ZT)(e,t),e.prototype.getComputedTextLength=function(){var t;return(null===(t=this.parsedStyle.metrics)||void 0===t?void 0:t.maxLineWidth)||0},e.prototype.getLineBoundingRects=function(){var t;return(null===(t=this.parsedStyle.metrics)||void 0===t?void 0:t.lineMetrics)||[]},e.prototype.isOverflowing=function(){return!!this.parsedStyle.isOverflowing},e}(r$),ir=function(){function t(){this.registry={},this.define(M.CIRCLE,r0),this.define(M.ELLIPSE,r2),this.define(M.RECT,it),this.define(M.IMAGE,r4),this.define(M.LINE,r9),this.define(M.GROUP,r3),this.define(M.PATH,r8),this.define(M.POLYGON,r6),this.define(M.POLYLINE,r7),this.define(M.TEXT,ie),this.define(M.HTML,r5)}return t.prototype.define=function(t,e){this.registry[t]=e},t.prototype.get=function(t){return this.registry[t]},t}(),ii=function(t){function e(){var e=t.call(this)||this;e.defaultView=null,e.ownerDocument=null,e.nodeName="document";try{e.timeline=new r_.AnimationTimeline(e)}catch(t){}var n={};return nE.forEach(function(t){var e=t.n,r=t.inh,i=t.d;r&&i&&(n[e]=en(i)?i(M.GROUP):i)}),e.documentElement=new r3({id:"g-root",style:n}),e.documentElement.ownerDocument=e,e.documentElement.parentNode=e,e.childNodes=[e.documentElement],e}return(0,W.ZT)(e,t),Object.defineProperty(e.prototype,"children",{get:function(){return this.childNodes},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"childElementCount",{get:function(){return this.childNodes.length},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"firstElementChild",{get:function(){return this.firstChild},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"lastElementChild",{get:function(){return this.lastChild},enumerable:!1,configurable:!0}),e.prototype.createElement=function(t,e){if("svg"===t)return this.documentElement;var n=this.defaultView.customElements.get(t);n||(console.warn("Unsupported tagName: ",t),n="tspan"===t?ie:r3);var r=new n(e);return r.ownerDocument=this,r},e.prototype.createElementNS=function(t,e,n){return this.createElement(e,n)},e.prototype.cloneNode=function(t){throw Error(tq)},e.prototype.destroy=function(){try{this.documentElement.destroyChildren(),this.timeline.destroy()}catch(t){}},e.prototype.elementsFromBBox=function(t,e,n,r){var i=this.defaultView.context.rBushRoot.search({minX:t,minY:e,maxX:n,maxY:r}),o=[];return i.forEach(function(t){var e=t.displayObject,n=["auto","visiblepainted","visiblefill","visiblestroke","visible"].includes(e.parsedStyle.pointerEvents);(!n||n&&e.isVisible())&&!e.isCulled()&&e.isInteractive()&&o.push(e)}),o.sort(function(t,e){return e.sortable.renderOrder-t.sortable.renderOrder}),o},e.prototype.elementFromPointSync=function(t,e){var n=this.defaultView.canvas2Viewport({x:t,y:e}),r=n.x,i=n.y,o=this.defaultView.getConfig(),a=o.width,s=o.height;if(r<0||i<0||r>a||i>s)return null;var l=this.defaultView.viewport2Client({x:r,y:i}),c=l.x,u=l.y,h=this.defaultView.getRenderingService().hooks.pickSync.call({topmost:!0,position:{x:t,y:e,viewportX:r,viewportY:i,clientX:c,clientY:u},picked:[]}).picked;return h&&h[0]||this.documentElement},e.prototype.elementFromPoint=function(t,e){return(0,W.mG)(this,void 0,void 0,function(){var n,r,i,o,a,s,l,c,u,h;return(0,W.Jh)(this,function(p){switch(p.label){case 0:if(r=(n=this.defaultView.canvas2Viewport({x:t,y:e})).x,i=n.y,a=(o=this.defaultView.getConfig()).width,s=o.height,r<0||i<0||r>a||i>s)return[2,null];return c=(l=this.defaultView.viewport2Client({x:r,y:i})).x,u=l.y,[4,this.defaultView.getRenderingService().hooks.pick.promise({topmost:!0,position:{x:t,y:e,viewportX:r,viewportY:i,clientX:c,clientY:u},picked:[]})];case 1:return[2,(h=p.sent().picked)&&h[0]||this.documentElement]}})})},e.prototype.elementsFromPointSync=function(t,e){var n=this.defaultView.canvas2Viewport({x:t,y:e}),r=n.x,i=n.y,o=this.defaultView.getConfig(),a=o.width,s=o.height;if(r<0||i<0||r>a||i>s)return[];var l=this.defaultView.viewport2Client({x:r,y:i}),c=l.x,u=l.y,h=this.defaultView.getRenderingService().hooks.pickSync.call({topmost:!1,position:{x:t,y:e,viewportX:r,viewportY:i,clientX:c,clientY:u},picked:[]}).picked;return h[h.length-1]!==this.documentElement&&h.push(this.documentElement),h},e.prototype.elementsFromPoint=function(t,e){return(0,W.mG)(this,void 0,void 0,function(){var n,r,i,o,a,s,l,c,u,h;return(0,W.Jh)(this,function(p){switch(p.label){case 0:if(r=(n=this.defaultView.canvas2Viewport({x:t,y:e})).x,i=n.y,a=(o=this.defaultView.getConfig()).width,s=o.height,r<0||i<0||r>a||i>s)return[2,[]];return c=(l=this.defaultView.viewport2Client({x:r,y:i})).x,u=l.y,[4,this.defaultView.getRenderingService().hooks.pick.promise({topmost:!1,position:{x:t,y:e,viewportX:r,viewportY:i,clientX:c,clientY:u},picked:[]})];case 1:return(h=p.sent().picked)[h.length-1]!==this.documentElement&&h.push(this.documentElement),[2,h]}})})},e.prototype.appendChild=function(t,e){throw Error(tJ)},e.prototype.insertBefore=function(t,e){throw Error(tJ)},e.prototype.removeChild=function(t,e){throw Error(tJ)},e.prototype.replaceChild=function(t,e,n){throw Error(tJ)},e.prototype.append=function(){throw Error(tJ)},e.prototype.prepend=function(){throw Error(tJ)},e.prototype.getElementById=function(t){return this.documentElement.getElementById(t)},e.prototype.getElementsByName=function(t){return this.documentElement.getElementsByName(t)},e.prototype.getElementsByTagName=function(t){return this.documentElement.getElementsByTagName(t)},e.prototype.getElementsByClassName=function(t){return this.documentElement.getElementsByClassName(t)},e.prototype.querySelector=function(t){return this.documentElement.querySelector(t)},e.prototype.querySelectorAll=function(t){return this.documentElement.querySelectorAll(t)},e.prototype.find=function(t){return this.documentElement.find(t)},e.prototype.findAll=function(t){return this.documentElement.findAll(t)},e}(rT),io=function(){function t(t){this.strategies=t}return t.prototype.apply=function(e){var n=e.camera,r=e.renderingService,i=e.renderingContext,o=this.strategies;r.hooks.cull.tap(t.tag,function(t){if(t){var e=t.cullable;return(0===o.length?e.visible=i.unculledEntities.indexOf(t.entity)>-1:e.visible=o.every(function(e){return e.isVisible(n,t)}),!t.isCulled()&&t.isVisible())?t:(t.dispatchEvent(new rx(H.CULLED)),null)}return t}),r.hooks.afterRender.tap(t.tag,function(t){t.cullable.visibilityPlaneMask=-1})},t.tag="Culling",t}(),ia=function(){function t(){var t=this;this.autoPreventDefault=!1,this.rootPointerEvent=new rm(null),this.rootWheelEvent=new rE(null),this.onPointerMove=function(e){var n,r,i,o,a=null===(o=null===(i=t.context.renderingContext.root)||void 0===i?void 0:i.ownerDocument)||void 0===o?void 0:o.defaultView;if(!a.supportsTouchEvents||"touch"!==e.pointerType){var s=t.normalizeToPointerEvent(e,a);try{for(var l=(0,W.XA)(s),c=l.next();!c.done;c=l.next()){var u=c.value,h=t.bootstrapEvent(t.rootPointerEvent,u,a,e);t.context.eventService.mapEvent(h)}}catch(t){n={error:t}}finally{try{c&&!c.done&&(r=l.return)&&r.call(l)}finally{if(n)throw n.error}}t.setCursor(t.context.eventService.cursor)}},this.onClick=function(e){var n,r,i,o,a=null===(o=null===(i=t.context.renderingContext.root)||void 0===i?void 0:i.ownerDocument)||void 0===o?void 0:o.defaultView,s=t.normalizeToPointerEvent(e,a);try{for(var l=(0,W.XA)(s),c=l.next();!c.done;c=l.next()){var u=c.value,h=t.bootstrapEvent(t.rootPointerEvent,u,a,e);t.context.eventService.mapEvent(h)}}catch(t){n={error:t}}finally{try{c&&!c.done&&(r=l.return)&&r.call(l)}finally{if(n)throw n.error}}t.setCursor(t.context.eventService.cursor)}}return t.prototype.apply=function(e){var n=this;this.context=e;var r=e.renderingService,i=this.context.renderingContext.root.ownerDocument.defaultView;this.context.eventService.setPickHandler(function(t){return n.context.renderingService.hooks.pickSync.call({position:t,picked:[],topmost:!0}).picked[0]||null}),r.hooks.pointerWheel.tap(t.tag,function(t){var e=n.normalizeWheelEvent(t);n.context.eventService.mapEvent(e)}),r.hooks.pointerDown.tap(t.tag,function(t){if(!i.supportsTouchEvents||"touch"!==t.pointerType){var e,r,o=n.normalizeToPointerEvent(t,i);n.autoPreventDefault&&o[0].isNormalized&&(t.cancelable||!("cancelable"in t))&&t.preventDefault();try{for(var a=(0,W.XA)(o),s=a.next();!s.done;s=a.next()){var l=s.value,c=n.bootstrapEvent(n.rootPointerEvent,l,i,t);n.context.eventService.mapEvent(c)}}catch(t){e={error:t}}finally{try{s&&!s.done&&(r=a.return)&&r.call(a)}finally{if(e)throw e.error}}n.setCursor(n.context.eventService.cursor)}}),r.hooks.pointerUp.tap(t.tag,function(t){if(!i.supportsTouchEvents||"touch"!==t.pointerType){var e,r,o=n.context.contextService.getDomElement(),a="outside";try{a=o&&t.target&&t.target!==o&&o.contains&&!o.contains(t.target)?"outside":""}catch(t){}var s=n.normalizeToPointerEvent(t,i);try{for(var l=(0,W.XA)(s),c=l.next();!c.done;c=l.next()){var u=c.value,h=n.bootstrapEvent(n.rootPointerEvent,u,i,t);h.type+=a,n.context.eventService.mapEvent(h)}}catch(t){e={error:t}}finally{try{c&&!c.done&&(r=l.return)&&r.call(l)}finally{if(e)throw e.error}}n.setCursor(n.context.eventService.cursor)}}),r.hooks.pointerMove.tap(t.tag,this.onPointerMove),r.hooks.pointerOver.tap(t.tag,this.onPointerMove),r.hooks.pointerOut.tap(t.tag,this.onPointerMove),r.hooks.click.tap(t.tag,this.onClick),r.hooks.pointerCancel.tap(t.tag,function(t){var e,r,o=n.normalizeToPointerEvent(t,i);try{for(var a=(0,W.XA)(o),s=a.next();!s.done;s=a.next()){var l=s.value,c=n.bootstrapEvent(n.rootPointerEvent,l,i,t);n.context.eventService.mapEvent(c)}}catch(t){e={error:t}}finally{try{s&&!s.done&&(r=a.return)&&r.call(a)}finally{if(e)throw e.error}}n.setCursor(n.context.eventService.cursor)})},t.prototype.getViewportXY=function(t){var e,n,r=t.offsetX,i=t.offsetY,o=t.clientX,a=t.clientY;if(!this.context.config.supportsCSSTransform||(0,tr.Z)(r)||(0,tr.Z)(i)){var s=this.context.eventService.client2Viewport(new tz(o,a));e=s.x,n=s.y}else e=r,n=i;return{x:e,y:n}},t.prototype.bootstrapEvent=function(t,e,n,r){t.view=n,t.originalEvent=null,t.nativeEvent=r,t.pointerId=e.pointerId,t.width=e.width,t.height=e.height,t.isPrimary=e.isPrimary,t.pointerType=e.pointerType,t.pressure=e.pressure,t.tangentialPressure=e.tangentialPressure,t.tiltX=e.tiltX,t.tiltY=e.tiltY,t.twist=e.twist,this.transferMouseData(t,e);var i=this.getViewportXY(e),o=i.x,a=i.y;t.viewport.x=o,t.viewport.y=a;var s=this.context.eventService.viewport2Canvas(t.viewport),l=s.x,c=s.y;return t.canvas.x=l,t.canvas.y=c,t.global.copyFrom(t.canvas),t.offset.copyFrom(t.canvas),t.isTrusted=r.isTrusted,"pointerleave"===t.type&&(t.type="pointerout"),t.type.startsWith("mouse")&&(t.type=t.type.replace("mouse","pointer")),t.type.startsWith("touch")&&(t.type=n$[t.type]||t.type),t},t.prototype.normalizeWheelEvent=function(t){var e=this.rootWheelEvent;this.transferMouseData(e,t),e.deltaMode=t.deltaMode,e.deltaX=t.deltaX,e.deltaY=t.deltaY,e.deltaZ=t.deltaZ;var n=this.getViewportXY(t),r=n.x,i=n.y;e.viewport.x=r,e.viewport.y=i;var o=this.context.eventService.viewport2Canvas(e.viewport),a=o.x,s=o.y;return e.canvas.x=a,e.canvas.y=s,e.global.copyFrom(e.canvas),e.offset.copyFrom(e.canvas),e.nativeEvent=t,e.type=t.type,e},t.prototype.transferMouseData=function(t,e){t.isTrusted=e.isTrusted,t.srcElement=e.srcElement,t.timeStamp=nQ.now(),t.type=e.type,t.altKey=e.altKey,t.metaKey=e.metaKey,t.shiftKey=e.shiftKey,t.ctrlKey=e.ctrlKey,t.button=e.button,t.buttons=e.buttons,t.client.x=e.clientX,t.client.y=e.clientY,t.movement.x=e.movementX,t.movement.y=e.movementY,t.page.x=e.pageX,t.page.y=e.pageY,t.screen.x=e.screenX,t.screen.y=e.screenY,t.relatedTarget=null},t.prototype.setCursor=function(t){this.context.contextService.applyCursorStyle(t||this.context.config.cursor||"default")},t.prototype.normalizeToPointerEvent=function(t,e){var n=[];if(e.isTouchEvent(t))for(var r=0;r-1,a=0,s=r.length;a=1?Math.ceil(M):1,C=l||("auto"===(n=nJ(a,"width"))?a.offsetWidth:parseFloat(n))||a.width/M,w=c||("auto"===(r=nJ(a,"height"))?a.offsetHeight:parseFloat(r))||a.height/M),s&&(r_.offscreenCanvas=s),i.devicePixelRatio=M,i.requestAnimationFrame=null!=v?v:n7.bind(r_.globalThis),i.cancelAnimationFrame=null!=y?y:rt.bind(r_.globalThis),i.supportsTouchEvents=null!=E?E:"ontouchstart"in r_.globalThis,i.supportsPointerEvents=null!=m?m:!!r_.globalThis.PointerEvent,i.isTouchEvent=null!=S?S:function(t){return i.supportsTouchEvents&&t instanceof r_.globalThis.TouchEvent},i.isMouseEvent=null!=N?N:function(t){return!r_.globalThis.MouseEvent||t instanceof r_.globalThis.MouseEvent&&(!i.supportsPointerEvents||!(t instanceof r_.globalThis.PointerEvent))},i.initRenderingContext({container:o,canvas:a,width:C,height:w,renderer:h,offscreenCanvas:s,devicePixelRatio:M,cursor:f||"default",background:p||"transparent",createImage:g,document:d,supportsCSSTransform:x,useNativeClickEvent:T,alwaysTriggerPointerEventOnCanvas:P}),i.initDefaultCamera(C,w,h.clipSpaceNearZ),i.initRenderer(h,!0),i}return(0,W.ZT)(e,t),e.prototype.initRenderingContext=function(t){this.context.config=t,this.context.renderingContext={root:this.document.documentElement,renderListCurrentFrame:[],unculledEntities:[],renderReasons:new Set,force:!1,dirty:!1}},e.prototype.initDefaultCamera=function(t,e,n){var r=this,i=new r_.CameraContribution;i.clipSpaceNearZ=n,i.setType(A.EXPLORING,O.DEFAULT).setPosition(t/2,e/2,500).setFocalPoint(t/2,e/2,0).setOrthographic(-(t/2),t/2,e/2,-(e/2),.1,1e3),i.canvas=this,i.eventEmitter.on(t$.UPDATED,function(){r.context.renderingContext.renderReasons.add(X.CAMERA_CHANGED)}),this.context.camera=i},e.prototype.getConfig=function(){return this.context.config},e.prototype.getRoot=function(){return this.document.documentElement},e.prototype.getCamera=function(){return this.context.camera},e.prototype.getContextService=function(){return this.context.contextService},e.prototype.getEventService=function(){return this.context.eventService},e.prototype.getRenderingService=function(){return this.context.renderingService},e.prototype.getRenderingContext=function(){return this.context.renderingContext},e.prototype.getStats=function(){return this.getRenderingService().getStats()},Object.defineProperty(e.prototype,"ready",{get:function(){var t=this;return!this.readyPromise&&(this.readyPromise=new Promise(function(e){t.resolveReadyPromise=function(){e(t)}}),this.inited&&this.resolveReadyPromise()),this.readyPromise},enumerable:!1,configurable:!0}),e.prototype.destroy=function(t,e){void 0===t&&(t=!0),void 0===e&&(e=!1),e||this.dispatchEvent(new rx(j.BEFORE_DESTROY)),this.frameId&&(this.getConfig().cancelAnimationFrame||cancelAnimationFrame)(this.frameId);var n=this.getRoot();this.unmountChildren(n),t&&(this.document.destroy(),this.getEventService().destroy()),this.getRenderingService().destroy(),this.getContextService().destroy(),t&&this.context.rBushRoot&&(this.context.rBushRoot.clear(),this.context.rBushRoot=null,this.context.renderingContext.root=null),e||this.dispatchEvent(new rx(j.AFTER_DESTROY))},e.prototype.changeSize=function(t,e){this.resize(t,e)},e.prototype.resize=function(t,e){var n=this.context.config;n.width=t,n.height=e,this.getContextService().resize(t,e);var r=this.context.camera,i=r.getProjectionMode();r.setPosition(t/2,e/2,500).setFocalPoint(t/2,e/2,0),i===L.ORTHOGRAPHIC?r.setOrthographic(-(t/2),t/2,e/2,-(e/2),r.getNear(),r.getFar()):r.setAspect(t/e),this.dispatchEvent(new rx(j.RESIZE,{width:t,height:e}))},e.prototype.appendChild=function(t,e){return this.document.documentElement.appendChild(t,e)},e.prototype.insertBefore=function(t,e){return this.document.documentElement.insertBefore(t,e)},e.prototype.removeChild=function(t){return this.document.documentElement.removeChild(t)},e.prototype.removeChildren=function(){this.document.documentElement.removeChildren()},e.prototype.destroyChildren=function(){this.document.documentElement.destroyChildren()},e.prototype.render=function(){var t=this;this.dispatchEvent(ip),this.getRenderingService().render(this.getConfig(),function(){t.dispatchEvent(id)}),this.dispatchEvent(iv)},e.prototype.run=function(){var t=this,e=function(){t.render(),t.frameId=t.requestAnimationFrame(e)};e()},e.prototype.initRenderer=function(t,e){var n=this;if(void 0===e&&(e=!1),!t)throw Error("Renderer is required.");this.inited=!1,this.readyPromise=void 0,this.context.rBushRoot=new tC,this.context.renderingPlugins=[],this.context.renderingPlugins.push(new ia,new ic,new io([new il])),this.loadRendererContainerModule(t),this.context.contextService=new this.context.ContextService((0,W.pi)((0,W.pi)({},r_),this.context)),this.context.renderingService=new rN(r_,this.context),this.context.eventService=new rP(r_,this.context),this.context.eventService.init(),this.context.contextService.init?(this.context.contextService.init(),this.initRenderingService(t,e,!0)):this.context.contextService.initAsync().then(function(){n.initRenderingService(t,e)})},e.prototype.initRenderingService=function(t,e,n){var r=this;void 0===e&&(e=!1),void 0===n&&(n=!1),this.context.renderingService.init(function(){r.inited=!0,e?(n?r.requestAnimationFrame(function(){r.dispatchEvent(new rx(j.READY))}):r.dispatchEvent(new rx(j.READY)),r.readyPromise&&r.resolveReadyPromise()):r.dispatchEvent(new rx(j.RENDERER_CHANGED)),e||r.getRoot().forEach(function(t){var e=t.renderable;e&&(e.renderBoundsDirty=!0,e.boundsDirty=!0,e.dirty=!0)}),r.mountChildren(r.getRoot()),t.getConfig().enableAutoRendering&&r.run()})},e.prototype.loadRendererContainerModule=function(t){var e=this;t.getPlugins().forEach(function(t){t.context=e.context,t.init(r_)})},e.prototype.setRenderer=function(t){var e=this.getConfig();if(e.renderer!==t){var n=e.renderer;e.renderer=t,this.destroy(!1,!0),(0,W.ev)([],(0,W.CR)(null==n?void 0:n.getPlugins()),!1).reverse().forEach(function(t){t.destroy(r_)}),this.initRenderer(t)}},e.prototype.setCursor=function(t){this.getConfig().cursor=t,this.getContextService().applyCursorStyle(t)},e.prototype.unmountChildren=function(t){var e=this;t.childNodes.forEach(function(t){e.unmountChildren(t)}),this.inited&&(t.isMutationObserved?t.dispatchEvent(ih):(ih.target=t,this.dispatchEvent(ih,!0)),t!==this.document.documentElement&&(t.ownerDocument=null),t.isConnected=!1),t.isCustomElement&&t.disconnectedCallback&&t.disconnectedCallback()},e.prototype.mountChildren=function(t){var e=this;this.inited?t.isConnected||(t.ownerDocument=this.document,t.isConnected=!0,t.isMutationObserved?t.dispatchEvent(iu):(iu.target=t,this.dispatchEvent(iu,!0))):console.warn("[g]: You are trying to call `canvas.appendChild` before canvas' initialization finished. You can either await `canvas.ready` or listen to `CanvasEvent.READY` manually.","appended child: ",t.nodeName),t.childNodes.forEach(function(t){e.mountChildren(t)}),t.isCustomElement&&t.connectedCallback&&t.connectedCallback()},e.prototype.client2Viewport=function(t){return this.getEventService().client2Viewport(t)},e.prototype.viewport2Client=function(t){return this.getEventService().viewport2Client(t)},e.prototype.viewport2Canvas=function(t){return this.getEventService().viewport2Canvas(t)},e.prototype.canvas2Viewport=function(t){return this.getEventService().canvas2Viewport(t)},e.prototype.getPointByClient=function(t,e){return this.client2Viewport({x:t,y:e})},e.prototype.getClientByPoint=function(t,e){return this.viewport2Client({x:t,y:e})},e}(rb)}}]); \ No newline at end of file diff --git a/pilot/server/static/_next/static/chunks/564.159424dfb5aaf8dc.js b/pilot/server/static/_next/static/chunks/739.985aeeb0618c336c.js similarity index 77% rename from pilot/server/static/_next/static/chunks/564.159424dfb5aaf8dc.js rename to pilot/server/static/_next/static/chunks/739.985aeeb0618c336c.js index 09fc82876..6671288bf 100644 --- a/pilot/server/static/_next/static/chunks/564.159424dfb5aaf8dc.js +++ b/pilot/server/static/_next/static/chunks/739.985aeeb0618c336c.js @@ -1,4 +1,4 @@ -(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[564],{96991:function(e,t,i){"use strict";i.d(t,{Z:function(){return a}});var n=i(87462),r=i(67294),o={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M864 144H560c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V160c0-8.8-7.2-16-16-16zm0 400H560c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V560c0-8.8-7.2-16-16-16zM464 144H160c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V160c0-8.8-7.2-16-16-16zm0 400H160c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V560c0-8.8-7.2-16-16-16z"}}]},name:"appstore",theme:"filled"},s=i(84089),a=r.forwardRef(function(e,t){return r.createElement(s.Z,(0,n.Z)({},e,{ref:t,icon:o}))})},29158:function(e,t,i){"use strict";i.d(t,{Z:function(){return a}});var n=i(87462),r=i(67294),o={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M574 665.4a8.03 8.03 0 00-11.3 0L446.5 781.6c-53.8 53.8-144.6 59.5-204 0-59.5-59.5-53.8-150.2 0-204l116.2-116.2c3.1-3.1 3.1-8.2 0-11.3l-39.8-39.8a8.03 8.03 0 00-11.3 0L191.4 526.5c-84.6 84.6-84.6 221.5 0 306s221.5 84.6 306 0l116.2-116.2c3.1-3.1 3.1-8.2 0-11.3L574 665.4zm258.6-474c-84.6-84.6-221.5-84.6-306 0L410.3 307.6a8.03 8.03 0 000 11.3l39.7 39.7c3.1 3.1 8.2 3.1 11.3 0l116.2-116.2c53.8-53.8 144.6-59.5 204 0 59.5 59.5 53.8 150.2 0 204L665.3 562.6a8.03 8.03 0 000 11.3l39.8 39.8c3.1 3.1 8.2 3.1 11.3 0l116.2-116.2c84.5-84.6 84.5-221.5 0-306.1zM610.1 372.3a8.03 8.03 0 00-11.3 0L372.3 598.7a8.03 8.03 0 000 11.3l39.6 39.6c3.1 3.1 8.2 3.1 11.3 0l226.4-226.4c3.1-3.1 3.1-8.2 0-11.3l-39.5-39.6z"}}]},name:"link",theme:"outlined"},s=i(84089),a=r.forwardRef(function(e,t){return r.createElement(s.Z,(0,n.Z)({},e,{ref:t,icon:o}))})},49591:function(e,t,i){"use strict";i.d(t,{Z:function(){return a}});var n=i(87462),r=i(67294),o={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M880 112H144c-17.7 0-32 14.3-32 32v736c0 17.7 14.3 32 32 32h360c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8H184V184h656v320c0 4.4 3.6 8 8 8h56c4.4 0 8-3.6 8-8V144c0-17.7-14.3-32-32-32zM653.3 599.4l52.2-52.2a8.01 8.01 0 00-4.7-13.6l-179.4-21c-5.1-.6-9.5 3.7-8.9 8.9l21 179.4c.8 6.6 8.9 9.4 13.6 4.7l52.4-52.4 256.2 256.2c3.1 3.1 8.2 3.1 11.3 0l42.4-42.4c3.1-3.1 3.1-8.2 0-11.3L653.3 599.4z"}}]},name:"select",theme:"outlined"},s=i(84089),a=r.forwardRef(function(e,t){return r.createElement(s.Z,(0,n.Z)({},e,{ref:t,icon:o}))})},88484:function(e,t,i){"use strict";i.d(t,{Z:function(){return a}});var n=i(87462),r=i(67294),o={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M400 317.7h73.9V656c0 4.4 3.6 8 8 8h60c4.4 0 8-3.6 8-8V317.7H624c6.7 0 10.4-7.7 6.3-12.9L518.3 163a8 8 0 00-12.6 0l-112 141.7c-4.1 5.3-.4 13 6.3 13zM878 626h-60c-4.4 0-8 3.6-8 8v154H214V634c0-4.4-3.6-8-8-8h-60c-4.4 0-8 3.6-8 8v198c0 17.7 14.3 32 32 32h684c17.7 0 32-14.3 32-32V634c0-4.4-3.6-8-8-8z"}}]},name:"upload",theme:"outlined"},s=i(84089),a=r.forwardRef(function(e,t){return r.createElement(s.Z,(0,n.Z)({},e,{ref:t,icon:o}))})},5165:function(e,t,i){"use strict";i.d(t,{w:function(){return tK}});var n=i(97582),r={line_chart:{id:"line_chart",name:"Line Chart",alias:["Lines"],family:["LineCharts"],def:"A line chart uses lines with segments to show changes in data in a ordinal dimension.",purpose:["Comparison","Trend","Anomaly"],coord:["Cartesian2D"],category:["Statistic"],shape:["Lines"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Time","Ordinal"]},{minQty:0,maxQty:1,fieldConditions:["Nominal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position","Direction"],recRate:"Recommended"},step_line_chart:{id:"step_line_chart",name:"Step Line Chart",alias:["Step Lines"],family:["LineCharts"],def:"A step line chart is a line chart in which points of each line are connected by horizontal and vertical line segments, looking like steps of a staircase.",purpose:["Comparison","Trend"],coord:["Cartesian2D"],category:["Statistic"],shape:["Lines"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Time","Ordinal"]},{minQty:0,maxQty:1,fieldConditions:["Nominal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position","Direction"],recRate:"Recommended"},area_chart:{id:"area_chart",name:"Area Chart",alias:[],family:["AreaCharts"],def:"An area chart uses series of line segments with overlapped areas to show the change in data in a ordinal dimension.",purpose:["Comparison","Trend","Anomaly"],coord:["Cartesian2D"],category:["Statistic"],shape:["Area"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Time","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]},{minQty:0,maxQty:1,fieldConditions:["Nominal"]}],channel:["Color","Position"],recRate:"Recommended"},stacked_area_chart:{id:"stacked_area_chart",name:"Stacked Area Chart",alias:[],family:["AreaCharts"],def:"A stacked area chart uses layered line segments with different styles of padding regions to display how multiple sets of data change in the same ordinal dimension, and the endpoint heights of the segments on the same dimension tick are accumulated by value.",purpose:["Composition","Trend"],coord:["Cartesian2D"],category:["Statistic"],shape:["Area"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Time","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]},{minQty:1,maxQty:1,fieldConditions:["Nominal"]}],channel:["Color","Length"],recRate:"Recommended"},percent_stacked_area_chart:{id:"percent_stacked_area_chart",name:"Percent Stacked Area Chart",alias:["Percent Stacked Area","% Stacked Area","100% Stacked Area"],family:["AreaCharts"],def:"A percent stacked area chart is an extented stacked area chart in which the height of the endpoints of the line segment on the same dimension tick is the accumulated proportion of the ratio, which is 100% of the total.",purpose:["Comparison","Composition","Proportion","Trend"],coord:["Cartesian2D"],category:["Statistic"],shape:["Area"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Time","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]},{minQty:1,maxQty:1,fieldConditions:["Nominal"]}],channel:["Color","Length"],recRate:"Recommended"},column_chart:{id:"column_chart",name:"Column Chart",alias:["Columns"],family:["ColumnCharts"],def:"A column chart uses series of columns to display the value of the dimension. The horizontal axis shows the classification dimension and the vertical axis shows the corresponding value.",purpose:["Comparison","Distribution","Rank"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:1,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position","Color"],recRate:"Recommended"},grouped_column_chart:{id:"grouped_column_chart",name:"Grouped Column Chart",alias:["Grouped Column"],family:["ColumnCharts"],def:"A grouped column chart uses columns of different colors to form a group to display the values of dimensions. The horizontal axis indicates the grouping of categories, the color indicates the categories, and the vertical axis shows the corresponding value.",purpose:["Comparison","Distribution","Rank"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Position"],recRate:"Recommended"},stacked_column_chart:{id:"stacked_column_chart",name:"Stacked Column Chart",alias:["Stacked Column"],family:["ColumnCharts"],def:"A stacked column chart uses stacked bars of different colors to display the values for each dimension. The horizontal axis indicates the first classification dimension, the color indicates the second classification dimension, and the vertical axis shows the corresponding value.",purpose:["Comparison","Composition","Distribution","Rank"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Length","Position"],recRate:"Recommended"},percent_stacked_column_chart:{id:"percent_stacked_column_chart",name:"Percent Stacked Column Chart",alias:["Percent Stacked Column","% Stacked Column","100% Stacked Column"],family:["ColumnCharts"],def:"A percent stacked column chart uses stacked bars of different colors to display the values for each dimension. The horizontal axis indicates the first classification dimension, the color indicates the second classification dimension, and the vertical axis shows the percentage of the corresponding classification.",purpose:["Comparison","Composition","Distribution","Proportion"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Length"],recRate:"Recommended"},range_column_chart:{id:"range_column_chart",name:"Range Column Chart",alias:[],family:["ColumnCharts"],def:"A column chart that does not have to start from zero axis.",purpose:["Comparison"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Interval","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Nominal"]}],channel:["Length"],recRate:"Recommended"},waterfall_chart:{id:"waterfall_chart",name:"Waterfall Chart",alias:["Flying Bricks Chart","Mario Chart","Bridge Chart","Cascade Chart"],family:["ColumnCharts"],def:"A waterfall chart is used to portray how an initial value is affected by a series of intermediate positive or negative values",purpose:["Comparison","Trend"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Ordinal","Time","Nominal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Length","Position"],recRate:"Recommended"},histogram:{id:"histogram",name:"Histogram",alias:[],family:["ColumnCharts"],def:"A histogram is an accurate representation of the distribution of numerical data.",purpose:["Distribution"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position"],recRate:"Recommended"},bar_chart:{id:"bar_chart",name:"Bar Chart",alias:["Bars"],family:["BarCharts"],def:"A bar chart uses series of bars to display the value of the dimension. The vertical axis shows the classification dimension and the horizontal axis shows the corresponding value.",purpose:["Comparison","Distribution","Rank"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:1,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position","Color"],recRate:"Recommended"},stacked_bar_chart:{id:"stacked_bar_chart",name:"Stacked Bar Chart",alias:["Stacked Bar"],family:["BarCharts"],def:"A stacked bar chart uses stacked bars of different colors to display the values for each dimension. The vertical axis indicates the first classification dimension, the color indicates the second classification dimension, and the horizontal axis shows the corresponding value.",purpose:["Comparison","Composition","Distribution","Rank"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Length","Position"],recRate:"Recommended"},percent_stacked_bar_chart:{id:"percent_stacked_bar_chart",name:"Percent Stacked Bar Chart",alias:["Percent Stacked Bar","% Stacked Bar","100% Stacked Bar"],family:["BarCharts"],def:"A percent stacked column chart uses stacked bars of different colors to display the values for each dimension. The vertical axis indicates the first classification dimension, the color indicates the second classification dimension, and the horizontal axis shows the percentage of the corresponding classification.",purpose:["Comparison","Composition","Distribution","Proportion"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Length"],recRate:"Recommended"},grouped_bar_chart:{id:"grouped_bar_chart",name:"Grouped Bar Chart",alias:["Grouped Bar"],family:["BarCharts"],def:"A grouped bar chart uses bars of different colors to form a group to display the values of the dimensions. The vertical axis indicates the grouping of categories, the color indicates the categories, and the horizontal axis shows the corresponding value.",purpose:["Comparison","Distribution","Rank"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Position"],recRate:"Recommended"},range_bar_chart:{id:"range_bar_chart",name:"Range Bar Chart",alias:[],family:["BarCharts"],def:"A bar chart that does not have to start from zero axis.",purpose:["Comparison"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Interval"]},{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]}],channel:["Length"],recRate:"Recommended"},radial_bar_chart:{id:"radial_bar_chart",name:"Radial Bar Chart",alias:["Radial Column Chart"],family:["BarCharts"],def:"A bar chart that is plotted in the polar coordinate system. The axis along radius shows the classification dimension and the angle shows the corresponding value.",purpose:["Comparison","Distribution","Rank"],coord:["Polar"],category:["Statistic"],shape:["Round"],dataPres:[{minQty:1,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Angle","Color"],recRate:"Recommended"},bullet_chart:{id:"bullet_chart",name:"Bullet Chart",alias:[],family:["BarCharts"],def:"A bullet graph is a variation of a bar graph developed by Stephen Few. Seemingly inspired by the traditional thermometer charts and progress bars found in many dashboards, the bullet graph serves as a replacement for dashboard gauges and meters.",purpose:["Proportion"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:3,maxQty:3,fieldConditions:["Interval"]},{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]}],channel:["Position","Color"],recRate:"Recommended"},pie_chart:{id:"pie_chart",name:"Pie Chart",alias:["Circle Chart","Pie"],family:["PieCharts"],def:"A pie chart is a chart that the classification and proportion of data are represented by the color and arc length (angle, area) of the sector.",purpose:["Comparison","Composition","Proportion"],coord:["Polar"],category:["Statistic"],shape:["Round"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Angle","Area","Color"],recRate:"Use with Caution"},donut_chart:{id:"donut_chart",name:"Donut Chart",alias:["Donut","Doughnut","Doughnut Chart","Ring Chart"],family:["PieCharts"],def:"A donut chart is a variation on a Pie chart except it has a round hole in the center which makes it look like a donut.",purpose:["Comparison","Composition","Proportion"],coord:["Polar"],category:["Statistic"],shape:["Round"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["ArcLength"],recRate:"Recommended"},nested_pie_chart:{id:"nested_pie_chart",name:"Nested Pie Chart",alias:["Nested Circle Chart","Nested Pie","Nested Donut Chart"],family:["PieCharts"],def:"A nested pie chart is a chart that contains several donut charts, where all the donut charts share the same center in position.",purpose:["Comparison","Composition","Proportion"],coord:["Polar"],category:["Statistic"],shape:["Round"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:"*",fieldConditions:["Interval"]}],channel:["Angle","Area","Color","Position"],recRate:"Use with Caution"},rose_chart:{id:"rose_chart",name:"Rose Chart",alias:["Nightingale Chart","Polar Area Chart","Coxcomb Chart"],family:["PieCharts"],def:"Nightingale Rose Chart is a peculiar combination of the Radar Chart and Stacked Column Chart types of data visualization.",purpose:["Comparison","Composition","Proportion"],coord:["Polar"],category:["Statistic"],shape:["Round"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Angle","Color","Length"],recRate:"Use with Caution"},scatter_plot:{id:"scatter_plot",name:"Scatter Plot",alias:["Scatter Chart","Scatterplot"],family:["ScatterCharts"],def:"A scatter plot is a type of plot or mathematical diagram using Cartesian coordinates to display values for typically two variables for series of data.",purpose:["Comparison","Distribution","Anomaly"],coord:["Cartesian2D"],category:["Statistic"],shape:["Scatter"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Interval"]},{minQty:0,maxQty:1,fieldConditions:["Nominal"]}],channel:["Color","Position"],recRate:"Recommended"},bubble_chart:{id:"bubble_chart",name:"Bubble Chart",alias:["Bubble Chart"],family:["ScatterCharts"],def:"A bubble chart is a type of chart that displays four dimensions of data with x, y positions, circle size and circle color.",purpose:["Comparison","Distribution"],coord:["Cartesian2D"],category:["Statistic"],shape:["Scatter"],dataPres:[{minQty:3,maxQty:3,fieldConditions:["Interval"]},{minQty:0,maxQty:1,fieldConditions:["Nominal"]}],channel:["Color","Position","Size"],recRate:"Recommended"},non_ribbon_chord_diagram:{id:"non_ribbon_chord_diagram",name:"Non-Ribbon Chord Diagram",alias:[],family:["GeneralGraph"],def:"A stripped-down version of a Chord Diagram, with only the connection lines showing. This provides more emphasis on the connections within the data.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},arc_diagram:{id:"arc_diagram",name:"Arc Diagram",alias:[],family:["GeneralGraph"],def:"A graph where the edges are represented as arcs.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},chord_diagram:{id:"chord_diagram",name:"Chord Diagram",alias:[],family:["GeneralGraph"],def:"A graphical method of displaying the inter-relationships between data in a matrix. The data are arranged radially around a circle with the relationships between the data points typically drawn as arcs connecting the data.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},treemap:{id:"treemap",name:"Treemap",alias:[],family:["TreeGraph"],def:"A visual representation of a data tree with nodes. Each node is displayed as a rectangle, sized and colored according to values that you assign.",purpose:["Composition","Comparison","Hierarchy"],coord:["Cartesian2D"],category:["Statistic"],shape:["Square"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Area"],recRate:"Recommended"},sankey_diagram:{id:"sankey_diagram",name:"Sankey Diagram",alias:[],family:["GeneralGraph"],def:"A graph shows the flows with weights between objects.",purpose:["Flow","Trend","Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},funnel_chart:{id:"funnel_chart",name:"Funnel Chart",alias:[],family:["FunnelCharts"],def:"A funnel chart is often used to represent stages in a sales process and show the amount of potential revenue for each stage.",purpose:["Trend"],coord:["SymmetricCartesian"],category:["Statistic"],shape:["Symmetric"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Length"],recRate:"Recommended"},mirror_funnel_chart:{id:"mirror_funnel_chart",name:"Mirror Funnel Chart",alias:["Contrast Funnel Chart"],family:["FunnelCharts"],def:"A mirror funnel chart is a funnel chart divided into two series by a central axis.",purpose:["Comparison","Trend"],coord:["SymmetricCartesian"],category:["Statistic"],shape:["Symmetric"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]},{minQty:1,maxQty:1,fieldConditions:["Nominal"]}],channel:["Color","Length","Direction"],recRate:"Recommended"},box_plot:{id:"box_plot",name:"Box Plot",alias:["Box and Whisker Plot","boxplot"],family:["BarCharts"],def:"A box plot is often used to graphically depict groups of numerical data through their quartiles. Box plots may also have lines extending from the boxes indicating variability outside the upper and lower quartiles. Outliers may be plotted as individual points.",purpose:["Distribution","Anomaly"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position"],recRate:"Recommended"},heatmap:{id:"heatmap",name:"Heatmap",alias:[],family:["HeatmapCharts"],def:"A heatmap is a graphical representation of data where the individual values contained in a matrix are represented as colors.",purpose:["Distribution"],coord:["Cartesian2D"],category:["Statistic"],shape:["Square"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Position"],recRate:"Recommended"},density_heatmap:{id:"density_heatmap",name:"Density Heatmap",alias:["Heatmap"],family:["HeatmapCharts"],def:"A density heatmap is a heatmap for representing the density of dots.",purpose:["Distribution"],coord:["Cartesian2D"],category:["Statistic"],shape:["Area"],dataPres:[{minQty:3,maxQty:3,fieldConditions:["Interval"]}],channel:["Color","Position","Area"],recRate:"Recommended"},radar_chart:{id:"radar_chart",name:"Radar Chart",alias:["Web Chart","Spider Chart","Star Chart","Cobweb Chart","Irregular Polygon","Kiviat diagram"],family:["RadarCharts"],def:"A radar chart maps series of data volume of multiple dimensions onto the axes. Starting at the same center point, usually ending at the edge of the circle, connecting the same set of points using lines.",purpose:["Comparison"],coord:["Radar"],category:["Statistic"],shape:["Round"],dataPres:[{minQty:1,maxQty:2,fieldConditions:["Nominal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Position"],recRate:"Recommended"},wordcloud:{id:"wordcloud",name:"Word Cloud",alias:["Wordle","Tag Cloud","Text Cloud"],family:["Others"],def:"A word cloud is a collection, or cluster, of words depicted in different sizes, colors, and shapes, which takes a piece of text as input. Typically, the font size in the word cloud is encoded as the word frequency in the input text.",purpose:["Proportion"],coord:["Cartesian2D"],category:["Diagram"],shape:["Scatter"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Nominal"]},{minQty:0,maxQty:1,fieldConditions:["Interval"]}],channel:["Size","Position","Color"],recRate:"Recommended"},candlestick_chart:{id:"candlestick_chart",name:"Candlestick Chart",alias:["Japanese Candlestick Chart)"],family:["BarCharts"],def:"A candlestick chart is a specific version of box plot, which is a style of financial chart used to describe price movements of a security, derivative, or currency.",purpose:["Trend","Distribution"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Time"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position"],recRate:"Recommended"},compact_box_tree:{id:"compact_box_tree",name:"CompactBox Tree",alias:[],family:["TreeGraph"],def:"A type of tree graph layout which arranges the nodes with same depth on the same level.",purpose:["Relation","Hierarchy"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},dendrogram:{id:"dendrogram",name:"Dendrogram",alias:[],family:["TreeGraph"],def:"A type of tree graph layout which arranges the leaves on the same level.",purpose:["Relation","Hierarchy"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},indented_tree:{id:"indented_tree",name:"Indented Tree Layout",alias:[],family:["TreeGraph"],def:"A type of tree graph layout where the hierarchy of tree is represented by the horizontal indentation, and each element will occupy one row/column. It is commonly used to represent the file directory structure.",purpose:["Relation","Hierarchy"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},radial_tree:{id:"radial_tree",name:"Radial Tree Layout",alias:[],family:["TreeGraph"],def:"A type of tree graph layout which places the root at the center, and the branches around the root radially.",purpose:["Relation","Hierarchy"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},flow_diagram:{id:"flow_diagram",name:"Flow Diagram",alias:["Dagre Graph Layout","Dagre","Flow Chart"],family:["GeneralGraph"],def:"Directed flow graph.",purpose:["Relation","Flow"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},fruchterman_layout_graph:{id:"fruchterman_layout_graph",name:"Fruchterman Graph Layout",alias:[],family:["GeneralGraph"],def:"A type of force directed graph layout.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},force_directed_layout_graph:{id:"force_directed_layout_graph",name:"Force Directed Graph Layout",alias:[],family:["GeneralGraph"],def:"The classical force directed graph layout.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},fa2_layout_graph:{id:"fa2_layout_graph",name:"Force Atlas 2 Graph Layout",alias:["FA2 Layout"],family:["GeneralGraph"],def:"A type of force directed graph layout algorithm. It focuses more on the degree of the node when calculating the force than the classical force-directed algorithm .",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},mds_layout_graph:{id:"mds_layout_graph",name:"Multi-Dimensional Scaling Layout",alias:["MDS Layout"],family:["GeneralGraph"],def:"A type of dimension reduction algorithm that could be used for calculating graph layout. MDS (Multidimensional scaling) is used for project high dimensional data onto low dimensional space.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},circular_layout_graph:{id:"circular_layout_graph",name:"Circular Graph Layout",alias:[],family:["GeneralGraph"],def:"A type of graph layout which arranges all the nodes on a circle.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},spiral_layout_graph:{id:"spiral_layout_graph",name:"Spiral Graph Layout",alias:[],family:["GeneralGraph"],def:"A type of graph layout which arranges all the nodes along a spiral line.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},radial_layout_graph:{id:"radial_layout_graph",name:"Radial Graph Layout",alias:[],family:["GeneralGraph"],def:"A type of graph layout which places a focus node on the center and the others on the concentrics centered at the focus node according to the shortest path length to the it.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},concentric_layout_graph:{id:"concentric_layout_graph",name:"Concentric Graph Layout",alias:[],family:["GeneralGraph"],def:"A type of graph layout which arranges the nodes on concentrics.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},grid_layout_graph:{id:"grid_layout_graph",name:"Grid Graph Layout",alias:[],family:["GeneralGraph"],def:"A type of graph layout arranges the nodes on grids.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"}};function o(e,t){return t.every(function(t){return e.includes(t)})}var s=["bar_chart","grouped_bar_chart","stacked_bar_chart","percent_stacked_bar_chart","column_chart","grouped_column_chart","stacked_column_chart","percent_stacked_column_chart"],a=["bar_chart","grouped_bar_chart","stacked_bar_chart","percent_stacked_bar_chart","column_chart","grouped_column_chart","stacked_column_chart","percent_stacked_column_chart"];function l(e,t){return t.some(function(t){return e.includes(t)})}function h(e,t){return e.distinctt.distinct?-1:0}var u={"bar-series-qty":.5,"data-check":1,"data-field-qty":1,"diff-pie-sector":.5,"landscape-or-portrait":.3,"limit-series":1,"line-field-time-ordinal":1,"no-redundant-field":1,"nominal-enum-combinatorial":1,"purpose-check":1,"series-qty-limit":.8},d=function(e,t,i,r,o,s){var a=1;return Object.values(i).filter(function(i){var s,a,l,h=(null===(s=i.option)||void 0===s?void 0:s.weight)||u[i.id]||1,d=null===(a=i.option)||void 0===a?void 0:a.extra;return i.type===r&&i.trigger((0,n.pi)((0,n.pi)((0,n.pi)((0,n.pi)({},o),{weight:h}),d),{chartType:e,chartWIKI:t}))&&!(null===(l=i.option)||void 0===l?void 0:l.off)}).forEach(function(i){var l,h,d=(null===(l=i.option)||void 0===l?void 0:l.weight)||u[i.id]||1,c=null===(h=i.option)||void 0===h?void 0:h.extra,f=i.validator((0,n.pi)((0,n.pi)((0,n.pi)((0,n.pi)({},o),{weight:d}),c),{chartType:e,chartWIKI:t})),g=d*f;a*=g,s.push({phase:"ADVISE",ruleId:i.id,score:g,base:f,weight:d,ruleType:r})}),a},c=["pie_chart","donut_chart"],f=["bar_chart","grouped_bar_chart","stacked_bar_chart","percent_stacked_bar_chart","column_chart","grouped_column_chart","stacked_column_chart","percent_stacked_column_chart"];function g(e){var t=e.chartType,i=e.dataProps,n=e.preferences;return!!(i&&t&&n&&n.canvasLayout)}var p=["line_chart","area_chart","stacked_area_chart","percent_stacked_area_chart"],m=["bar_chart","column_chart","grouped_bar_chart","grouped_column_chart","stacked_bar_chart","stacked_column_chart"];function _(e){return e.filter(function(e){return o(e.levelOfMeasurements,["Nominal"])})}var E=["pie_chart","donut_chart","radar_chart","rose_chart"],v=i(96486);function b(e){return"number"==typeof e}function C(e){return"string"==typeof e||"boolean"==typeof e}function S(e){return e instanceof Date}function y(e){var t=e.encode,i=e.data,r=e.scale,o=(0,v.mapValues)(t,function(e,t){var n,o,s;return{field:e,type:void 0!==(n=null==r?void 0:r[t].type)?function(e){switch(e){case"linear":case"log":case"pow":case"sqrt":case"qunatile":case"threshold":case"quantize":case"sequential":return"quantitative";case"time":return"temporal";case"ordinal":case"point":case"band":return"categorical";default:throw Error("Unkonwn scale type: ".concat(e,"."))}}(n):function(e){if(e.some(b))return"quantitative";if(e.some(C))return"categorical";if(e.some(S))return"temporal";throw Error("Unknown type: ".concat(typeof e[0]))}((o=i,"function"==typeof(s=e)?o.map(s):"string"==typeof s&&o.some(function(e){return void 0!==e[s]})?o.map(function(e){return e[s]}):o.map(function(){return s})))}});return(0,n.pi)((0,n.pi)({},e),{encode:o})}var T=["line_chart"],R={"bar-series-qty":{id:"bar-series-qty",type:"SOFT",docs:{lintText:"Bar chart should has proper number of bars or bar groups."},trigger:function(e){var t=e.chartType;return s.includes(t)},validator:function(e){var t=1,i=e.dataProps,n=e.chartType;if(i&&n){var r=i.find(function(e){return o(e.levelOfMeasurements,["Nominal"])}),s=r&&r.count?r.count:0;s>20&&(t=20/s)}return t<.1?.1:t}},"bar-without-axis-min":{id:"bar-without-axis-min",type:"DESIGN",docs:{lintText:"It is not recommended to set the minimum value of axis for the bar or column chart.",fixText:"Remove the minimum value config of axis."},trigger:function(e){var t=e.chartType;return a.includes(t)},optimizer:function(e,t){var i,n,r=t.scale;if(!r)return{};var o=null===(i=r.x)||void 0===i?void 0:i.domainMin,s=null===(n=r.y)||void 0===n?void 0:n.domainMin;if(o||s){var a=JSON.parse(JSON.stringify(r));return o&&(a.x.domainMin=0),s&&(a.y.domainMin=0),{scale:a}}return{}}},"data-check":{id:"data-check",type:"HARD",docs:{lintText:"Data must satisfy the data prerequisites."},trigger:function(){return!0},validator:function(e){var t=0,i=e.dataProps,n=e.chartType,r=e.chartWIKI;if(i&&n&&r[n]){t=1;var o=r[n].dataPres||[];o.forEach(function(e){!function(e,t){var i=t.map(function(e){return e.levelOfMeasurements});if(i){var n=0;if(i.forEach(function(t){t&&l(t,e.fieldConditions)&&(n+=1)}),n>=e.minQty&&(n<=e.maxQty||"*"===e.maxQty))return!0}return!1}(e,i)&&(t=0)}),i.map(function(e){return e.levelOfMeasurements}).forEach(function(e){var i=!1;o.forEach(function(t){e&&l(e,t.fieldConditions)&&(i=!0)}),i||(t=0)})}return t}},"data-field-qty":{id:"data-field-qty",type:"HARD",docs:{lintText:"Data must have at least the min qty of the prerequisite."},trigger:function(){return!0},validator:function(e){var t=0,i=e.dataProps,n=e.chartType,r=e.chartWIKI;if(i&&n&&r[n]){t=1;var o=(r[n].dataPres||[]).map(function(e){return e.minQty}).reduce(function(e,t){return e+t});i.length&&i.length>=o&&(t=1)}return t}},"diff-pie-sector":{id:"diff-pie-sector",type:"SOFT",docs:{lintText:"The difference between sectors of a pie chart should be large enough."},trigger:function(e){var t=e.chartType;return c.includes(t)},validator:function(e){var t=1,i=e.dataProps;if(i){var n=i.find(function(e){return o(e.levelOfMeasurements,["Interval"])});if(n&&n.sum&&n.rawData){var r=1/n.sum,s=n.rawData.map(function(e){return e*r}).reduce(function(e,t){return e*t}),a=n.rawData.length,l=Math.pow(1/a,a);t=2*(Math.abs(l-Math.abs(s))/l)}}return t<.1?.1:t}},"landscape-or-portrait":{id:"landscape-or-portrait",type:"SOFT",docs:{lintText:"Recommend column charts for landscape layout and bar charts for portrait layout."},trigger:function(e){return f.includes(e.chartType)&&g(e)},validator:function(e){var t=1,i=e.chartType,n=e.preferences;return g(e)&&("portrait"===n.canvasLayout&&["bar_chart","grouped_bar_chart","stacked_bar_chart","percent_stacked_bar_chart"].includes(i)?t=5:"landscape"===n.canvasLayout&&["column_chart","grouped_column_chart","stacked_column_chart","percent_stacked_column_chart"].includes(i)&&(t=5)),t}},"limit-series":{id:"limit-series",type:"SOFT",docs:{lintText:"Avoid too many values in one series."},trigger:function(e){return e.dataProps.filter(function(e){return l(e.levelOfMeasurements,["Nominal","Ordinal"])}).length>=2},validator:function(e){var t=1,i=e.dataProps,n=e.chartType;if(i){var r=i.filter(function(e){return l(e.levelOfMeasurements,["Nominal","Ordinal"])});if(r.length>=2){var o=r.sort(h)[1];o.distinct&&(t=o.distinct>10?.1:1/o.distinct,o.distinct>6&&"heatmap"===n?t=5:"heatmap"===n&&(t=1))}}return t}},"line-field-time-ordinal":{id:"line-field-time-ordinal",type:"SOFT",docs:{lintText:"Data containing time or ordinal fields are suitable for line or area charts."},trigger:function(e){var t=e.chartType;return p.includes(t)},validator:function(e){var t=1,i=e.dataProps;return i&&i.find(function(e){return l(e.levelOfMeasurements,["Ordinal","Time"])})&&(t=5),t}},"no-redundant-field":{id:"no-redundant-field",type:"HARD",docs:{lintText:"No redundant field."},trigger:function(){return!0},validator:function(e){var t=0,i=e.dataProps,n=e.chartType,r=e.chartWIKI;if(i&&n&&r[n]){var o=(r[n].dataPres||[]).map(function(e){return"*"===e.maxQty?99:e.maxQty}).reduce(function(e,t){return e+t});i.length&&i.length<=o&&(t=1)}return t}},"nominal-enum-combinatorial":{id:"nominal-enum-combinatorial",type:"SOFT",docs:{lintText:"Single (Basic) and Multi (Stacked, Grouped,...) charts should be optimized recommended by nominal enums combinatorial numbers."},trigger:function(e){var t=e.chartType,i=e.dataProps;return m.includes(t)&&_(i).length>=2},validator:function(e){var t=1,i=e.dataProps,n=e.chartType;if(i){var r=_(i);if(r.length>=2){var o=r.sort(h),s=o[0],a=o[1];s.distinct===s.count&&["bar_chart","column_chart"].includes(n)&&(t=5),s.count&&s.distinct&&a.distinct&&s.count>s.distinct&&["grouped_bar_chart","grouped_column_chart","stacked_bar_chart","stacked_column_chart"].includes(n)&&(t=5)}}return t}},"purpose-check":{id:"purpose-check",type:"HARD",docs:{lintText:"Choose chart types that satisfy the purpose, if purpose is defined."},trigger:function(){return!0},validator:function(e){var t=0,i=e.chartType,n=e.purpose,r=e.chartWIKI;return n?(i&&r[i]&&n&&(r[i].purpose||"").includes(n)&&(t=1),t):t=1}},"series-qty-limit":{id:"series-qty-limit",type:"SOFT",docs:{lintText:"Some charts should has at most N values for the series."},trigger:function(e){var t=e.chartType;return E.includes(t)},validator:function(e){var t=1,i=e.dataProps,n=e.chartType,r=e.limit;if((!Number.isInteger(r)||r<=0)&&(r=6,("pie_chart"===n||"donut_chart"===n||"rose_chart"===n)&&(r=6),"radar_chart"===n&&(r=8)),i){var s=i.find(function(e){return o(e.levelOfMeasurements,["Nominal"])}),a=s&&s.count?s.count:0;a>=2&&a<=r&&(t=5+2/a)}return t}},"x-axis-line-fading":{id:"x-axis-line-fading",type:"DESIGN",docs:{lintText:"Adjust axis to make it prettier"},trigger:function(e){var t=e.chartType;return T.includes(t)},optimizer:function(e,t){var i,n=y(t).encode;if(n&&(null===(i=n.y)||void 0===i?void 0:i.type)==="quantitative"){var r=e.find(function(e){var t;return e.name===(null===(t=n.y)||void 0===t?void 0:t.field)});if(r){var o=r.maximum-r.minimum;if(r.minimum&&r.maximum&&o<2*r.maximum/3){var s=Math.floor(r.minimum-o/5);return{axis:{x:{tick:!1}},scale:{y:{domainMin:s>0?s:0}},clip:!0}}}}return{}}}},A=Object.keys(R),N=function(e){var t={};return e.forEach(function(e){Object.keys(R).includes(e)&&(t[e]=R[e])}),t},O=function(e){if(!e)return N(A);var t=N(A);if(e.exclude&&e.exclude.forEach(function(e){Object.keys(t).includes(e)&&delete t[e]}),e.include){var i=e.include;Object.keys(t).forEach(function(e){i.includes(e)||delete t[e]})}var r=(0,n.pi)((0,n.pi)({},t),e.custom),o=e.options;return o&&Object.keys(o).forEach(function(e){if(Object.keys(r).includes(e)){var t=o[e];r[e]=(0,n.pi)((0,n.pi)({},r[e]),{option:t})}}),r},L=[[!0,!1],[0,1],["true","false"],["Yes","No"],["True","False"],["0","1"],["是","否"]],I="([-_./\\s])",w="(18|19|20)\\d{2}",D="(0?[1-9]|1[012])",x="(0?[1-9]|[12]\\d|3[01])",M="(0?\\d|1\\d|2[0-4])",k="(0?\\d|[012345]\\d)",P="(Z|[+-]".concat(M,"(:").concat(k,")?)");function F(e){return null==e||""===e||Number.isNaN(e)||"null"===e}function B(e){return"string"==typeof e}function U(e){return"number"==typeof e}function H(e){if(B(e)){var t=!1,i=e;/^[+-]/.test(i)&&(i=i.slice(1));for(var n=0;n0&&t<100,"The percent cannot be between (0, 100)."),(i?e:e.sort(function(e,t){return e>t?1:-1}))[Math.ceil(e.length*t/100)-1]}function eo(e){var t=en(e),i=J(e,"variance");return void 0!==i?i:Q(e,"variance",e.reduce(function(e,i){return e+Math.pow(i-t,2)},0)/e.length)}function es(e){return Math.sqrt(eo(e))}function ea(e){var t={};return e.forEach(function(e){var i="".concat(e);t[i]?t[i]+=1:t[i]=1}),t}var el=function(e){var t,i,r=(void 0===(t=e)&&(t=!0),["".concat(w),"".concat(w).concat(I).concat(t?"":"?","W").concat("([0-4]\\d|5[0-2])","(").concat(I).concat(t?"":"?").concat("([1-7])",")?"),"".concat(D).concat(I).concat(t?"":"?").concat(x).concat(I).concat(t?"":"?").concat(w),"".concat(w).concat(I).concat(t?"":"?").concat(D).concat(I).concat(t?"":"?").concat(x),"".concat(w).concat(I).concat(t?"":"?").concat(D),"".concat(w).concat(I).concat(t?"":"?").concat("((([0-2]\\d|3[0-5])\\d)|36[0-6])")]),o=(void 0===(i=e)&&(i=!0),["".concat(M,":").concat(i?"":"?").concat(k,":").concat(i?"":"?").concat(k,"([.,]").concat("\\d{1,4}",")?").concat(P,"?"),"".concat(M,":").concat(i?"":"?").concat(k,"?").concat(P)]),s=(0,n.ev)((0,n.ev)([],(0,n.CR)(r),!1),(0,n.CR)(o),!1);return r.forEach(function(e){o.forEach(function(t){s.push("".concat(e,"[T\\s]").concat(t))})}),s.map(function(e){return new RegExp("^".concat(e,"$"))})};function eh(e,t){if(B(e)){for(var i=el(t),n=0;n0&&(c.generateColumns([0],null==i?void 0:i.columns),c.colData=[c.data],c.data=c.data.map(function(e){return[e]})),Y(g)){var p=q(g.length);c.generateDataAndColDataFromArray(!1,t,p,null==i?void 0:i.fillValue,null==i?void 0:i.columnTypes),c.generateColumns(p,null==i?void 0:i.columns)}if(K(g)){for(var m=[],f=0;f=0&&m>=0||_.length>0,"The rowLoc is not found in the indexes."),p>=0&&m>=0&&(A=this.data.slice(p,m),N=this.indexes.slice(p,m)),_.length>0)for(var a=0;a<_.length;a+=1){var C=_[a];A.push(this.data[C]),N.push(this.indexes[C])}if(E>=0&&v>=0){for(var a=0;a0){for(var O=[],L=A.slice(),a=0;a=0&&p>=0||m.length>0,"The colLoc is illegal"),V(i)&&q(this.columns.length).includes(i)&&(_=i,E=i+1),Y(i))for(var a=0;a=0&&p>=0||m.length>0,"The rowLoc is not found in the indexes.");var R=[],A=[];if(g>=0&&p>=0)R=this.data.slice(g,p),A=this.indexes.slice(g,p);else if(m.length>0)for(var a=0;a=0&&E>=0||v.length>0,"The colLoc is not found in the columns index."),_>=0&&E>=0){for(var a=0;a0){for(var N=[],O=R.slice(),a=0;a1){var E={},v=f;g.forEach(function(t){"date"===t?(E.date=e(v.filter(function(e){return eh(e)}),i),v=v.filter(function(e){return!eh(e)})):"integer"===t?(E.integer=e(v.filter(function(e){return W(e)}),i),v=v.filter(function(e){return!W(e)})):"float"===t?(E.float=e(v.filter(function(e){return G(e)}),i),v=v.filter(function(e){return!G(e)})):"string"===t&&(E.string=e(v.filter(function(e){return"string"===ed(e,i)})),v=v.filter(function(e){return"string"!==ed(e,i)}))}),_.meta=E}2===_.distinct&&"date"!==_.recommendation&&(d.length>=100?_.recommendation="boolean":z(m,!0)&&(_.recommendation="boolean")),"string"===u&&Object.assign(_,{maxLength:et(r=(n=f.map(function(e){return"".concat(e)})).map(function(e){return e.length})),minLength:ee(r),meanLength:en(r),containsChar:n.some(function(e){return/[A-z]/.test(e)}),containsDigit:n.some(function(e){return/[0-9]/.test(e)}),containsSpace:n.some(function(e){return/\s/.test(e)})}),("integer"===u||"float"===u)&&Object.assign(_,{minimum:ee(o=f.map(function(e){return 1*e})),maximum:et(o),mean:en(o),percentile5:er(o,5),percentile25:er(o,25),percentile50:er(o,50),percentile75:er(o,75),percentile95:er(o,95),sum:ei(o),variance:eo(o),standardDeviation:es(o),zeros:o.filter(function(e){return 0===e}).length}),"date"===u&&Object.assign(_,(s="integer"===_.type,a=f.map(function(e){if(s){var t="".concat(e);if(8===t.length)return new Date("".concat(t.substring(0,4),"/").concat(t.substring(4,2),"/").concat(t.substring(6,2))).getTime()}return new Date(e).getTime()}),{minimum:f[void 0!==(l=J(a,"minIndex"))?l:Q(a,"minIndex",function(e){for(var t=e[0],i=0,n=0;nt&&(i=n,t=e[n]);return i}(a))]}));var b=[];return"boolean"!==_.recommendation&&("string"!==_.recommendation||eu(_))||b.push("Nominal"),eu(_)&&b.push("Ordinal"),("integer"===_.recommendation||"float"===_.recommendation)&&b.push("Interval"),"integer"===_.recommendation&&b.push("Discrete"),"float"===_.recommendation&&b.push("Continuous"),"date"===_.recommendation&&b.push("Time"),_.levelOfMeasurements=b,_}(this.colData[i],this.extra.strictDatePattern)),{name:String(r)}))}return t},t.prototype.toString=function(){for(var e=this,t=Array(this.columns.length+1).fill(0),i=0;it[0]&&(t[0]=n)}for(var i=0;it[i+1]&&(t[i+1]=n)}for(var i=0;it[i+1]&&(t[i+1]=n)}return"".concat(ep(t[0])).concat(this.columns.map(function(i,n){return"".concat(i).concat(n!==e.columns.length?ep(t[n+1]-e_(i)+2):"")}).join(""),"\n").concat(this.indexes.map(function(i,n){var r;return"".concat(i).concat(ep(t[0]-e_(i))).concat(null===(r=e.data[n])||void 0===r?void 0:r.map(function(i,n){return"".concat(em(i)).concat(n!==e.columns.length?ep(t[n+1]-e_(i)):"")}).join("")).concat(n!==e.indexes.length?"\n":"")}).join(""))},t}(ev),eS=function(e){if("object"!=typeof e||null===e)return e;if(Array.isArray(e)){t=[];for(var t,i=0,n=e.length;i!!eA().valid(e);function eO(e){let{value:t}=e;return eN(t)?eA()(t).hex():""}let eL={lab:{l:[0,100],a:[-86.185,98.254],b:[-107.863,94.482]},lch:{l:[0,100],c:[0,100],h:[0,360]},rgb:{r:[0,255],g:[0,255],b:[0,255]},rgba:{r:[0,255],g:[0,255],b:[0,255],a:[0,1]},hsl:{h:[0,360],s:[0,1],l:[0,1]},hsv:{h:[0,360],s:[0,1],v:[0,1]},hsi:{h:[0,360],s:[0,1],i:[0,1]},cmyk:{c:[0,1],m:[0,1],y:[0,1],k:[0,1]}},eI=e=>!!eA().valid(e),ew=e=>{let{value:t}=e;return eI(t)?eA()(t):eA()("#000")},eD=(e,t=e.model)=>{let i=ew(e);return i?i[t]():[0,0,0]},ex=(e,t=4===e.length?"rgba":"rgb")=>{let i={};if(1===e.length){let[n]=e;for(let e=0;ee*t/255,eB=(e,t)=>e+t-e*t/255,eU=(e,t)=>e<128?eF(2*e,t):eB(2*e-255,t),eH={normal:e=>e,darken:(e,t)=>Math.min(e,t),multiply:eF,colorBurn:(e,t)=>0===e?0:Math.max(0,255*(1-(255-t)/e)),lighten:(e,t)=>Math.max(e,t),screen:eB,colorDodge:(e,t)=>255===e?255:Math.min(255,255*(t/(255-e))),overlay:(e,t)=>eU(t,e),softLight:(e,t)=>{if(e<128)return t-(1-2*e/255)*t*(1-t/255);let i=t<64?((16*(t/255)-12)*(t/255)+4)*(t/255):Math.sqrt(t/255);return t+255*(2*e/255-1)*(i-t/255)},hardLight:eU,difference:(e,t)=>Math.abs(e-t),exclusion:(e,t)=>e+t-2*e*t/255,linearBurn:(e,t)=>Math.max(e+t-255,0),linearDodge:(e,t)=>Math.min(255,e+t),linearLight:(e,t)=>Math.max(t+2*e-255,0),vividLight:(e,t)=>e<128?255*(1-(1-t/255)/(2*e/255)):255*(t/2/(255-e)),pinLight:(e,t)=>e<128?Math.min(t,2*e):Math.max(t,2*e-255)},eV=e=>.3*e[0]+.58*e[1]+.11*e[2],eW=e=>{let t=eV(e),i=Math.min(...e),n=Math.max(...e),r=[...e];return i<0&&(r=r.map(e=>t+(e-t)*t/(t-i))),n>255&&(r=r.map(e=>t+(e-t)*(255-t)/(n-t))),r},eG=(e,t)=>{let i=t-eV(e);return eW(e.map(e=>e+i))},ej=e=>Math.max(...e)-Math.min(...e),ez=(e,t)=>{let i=e.map((e,t)=>({value:e,index:t}));i.sort((e,t)=>e.value-t.value);let n=i[0].index,r=i[1].index,o=i[2].index,s=[...e];return s[o]>s[n]?(s[r]=(s[r]-s[n])*t/(s[o]-s[n]),s[o]=t):(s[r]=0,s[o]=0),s[n]=0,s},eK={hue:(e,t)=>eG(ez(e,ej(t)),eV(t)),saturation:(e,t)=>eG(ez(t,ej(e)),eV(t)),color:(e,t)=>eG(e,eV(t)),luminosity:(e,t)=>eG(t,eV(e))},eY=(e,t,i="normal")=>{let n;let[r,o,s,a]=eD(e,"rgba"),[l,h,u,d]=eD(t,"rgba"),c=[r,o,s],f=[l,h,u];if(eT.includes(i)){let e=eH[i];n=c.map((t,i)=>Math.floor(e(t,f[i])))}else n=eK[i](c,f);let g=a+d*(1-a),p=Math.round((a*(1-d)*r+a*d*n[0]+(1-a)*d*l)/g),m=Math.round((a*(1-d)*o+a*d*n[1]+(1-a)*d*h)/g),_=Math.round((a*(1-d)*s+a*d*n[2]+(1-a)*d*u)/g);return 1===g?{model:"rgb",value:{r:p,g:m,b:_}}:{model:"rgba",value:{r:p,g:m,b:_,a:g}}},e$=(e,t)=>{let i=(e+t)%360;return i<0?i+=360:i>=360&&(i-=360),i},eq=(e=1,t=0)=>{let i=Math.min(e,t),n=Math.max(e,t);return i+Math.random()*(n-i)},eX=(e=1,t=0)=>{let i=Math.ceil(Math.min(e,t)),n=Math.floor(Math.max(e,t));return Math.floor(i+Math.random()*(n-i+1))},eZ=e=>{if(e&&"object"==typeof e){let t=Array.isArray(e);if(t){let t=e.map(e=>eZ(e));return t}let i={},n=Object.keys(e);return n.forEach(t=>{i[t]=eZ(e[t])}),i}return e};function eQ(e){return e*(Math.PI/180)}var eJ=i(56917),e0=i.n(eJ);let e1=(e,t="normal")=>{if("normal"===t)return{...e};let i=eO(e),n=e0()[t](i);return eP(n)},e2=e=>{let t=eM(e),[,,,i=1]=eD(e,"rgba");return ek(t,i)},e5=(e,t="normal")=>"grayscale"===t?e2(e):e1(e,t),e4=(e,t,i=[eX(5,10),eX(90,95)])=>{let[n,r,o]=eD(e,"lab"),s=n<=15?n:i[0],a=n>=85?n:i[1],l=(a-s)/(t-1),h=Math.ceil((n-s)/l);return l=0===h?l:(n-s)/h,Array(t).fill(0).map((e,t)=>ex([l*t+s,r,o],"lab"))},e3=e=>{let{count:t,color:i,tendency:n}=e,r=e4(i,t),o={name:"monochromatic",semantic:null,type:"discrete-scale",colors:"tint"===n?r:r.reverse()};return o},e6={model:"rgb",value:{r:0,g:0,b:0}},e9={model:"rgb",value:{r:255,g:255,b:255}},e8=(e,t,i="lab")=>eA().distance(ew(e),ew(t),i),e7=(e,t)=>{let i=Math.atan2(e,t)*(180/Math.PI);return i>=0?i:i+360},te=(e,t)=>{let i,n;let[r,o,s]=eD(e,"lab"),[a,l,h]=eD(t,"lab"),u=Math.sqrt(o**2+s**2),d=Math.sqrt(l**2+h**2),c=(u+d)/2,f=.5*(1-Math.sqrt(c**7/(c**7+6103515625))),g=(1+f)*o,p=(1+f)*l,m=Math.sqrt(g**2+s**2),_=Math.sqrt(p**2+h**2),E=e7(s,g),v=e7(h,p),b=_-m;i=180>=Math.abs(v-E)?v-E:v-E<-180?v-E+360:v-E-360;let C=2*Math.sqrt(m*_)*Math.sin(eQ(i)/2);n=180>=Math.abs(E-v)?(E+v)/2:Math.abs(E-v)>180&&E+v<360?(E+v+360)/2:(E+v-360)/2;let S=(r+a)/2,y=(m+_)/2,T=1-.17*Math.cos(eQ(n-30))+.24*Math.cos(eQ(2*n))+.32*Math.cos(eQ(3*n+6))-.2*Math.cos(eQ(4*n-63)),R=1+.015*(S-50)**2/Math.sqrt(20+(S-50)**2),A=1+.045*y,N=1+.015*y*T,O=-2*Math.sqrt(y**7/(y**7+6103515625))*Math.sin(eQ(60*Math.exp(-(((n-275)/25)**2)))),L=Math.sqrt(((a-r)/(1*R))**2+(b/(1*A))**2+(C/(1*N))**2+O*(b/(1*A))*(C/(1*N)));return L},tt=e=>{let t=e/255;return t<=.03928?t/12.92:((t+.055)/1.055)**2.4},ti=e=>{let[t,i,n]=eD(e);return .2126*tt(t)+.7152*tt(i)+.0722*tt(n)},tn=(e,t)=>{let i=ti(e),n=ti(t);return n>i?(n+.05)/(i+.05):(i+.05)/(n+.05)},tr=(e,t,i={measure:"euclidean"})=>{let{measure:n="euclidean",backgroundColor:r=ey}=i,o=eY(e,r),s=eY(t,r);switch(n){case"CIEDE2000":return te(o,s);case"euclidean":return e8(o,s,i.colorModel);case"contrastRatio":return tn(o,s);default:return e8(o,s)}},to=[.8,1.2],ts={rouletteWheel:e=>{let t=e.reduce((e,t)=>e+t),i=0,n=eq(t),r=0;for(let t=0;t{let t=-1,i=0;for(let n=0;n<3;n+=1){let r=eX(e.length-1);e[r]>i&&(t=n,i=e[r])}return t}},ta=(e,t="tournament")=>ts[t](e),tl=(e,t)=>{let i=eZ(e),n=eZ(t);for(let r=1;r{let r=eZ(e),o=t[eX(t.length-1)],s=eX(e[0].length-1),a=r[o][s]*eq(...to),l=[15,240];"grayscale"!==i&&(l=eL[n][n.split("")[s]]);let[h,u]=l;return au&&(a=u),r[o][s]=a,r},tu=(e,t,i,n,r,o)=>{let s;s="grayscale"===i?e.map(([e])=>ek(e)):e.map(e=>e5(ex(e,n),i));let a=1/0;for(let e=0;e{if(Math.round(tu(e,t,i,r,o,s))>n)return e;let a=Array(e.length).fill(0).map((e,t)=>t).filter((e,i)=>!t[i]),l=Array(50).fill(0).map(()=>th(e,a,i,r)),h=l.map(e=>tu(e,t,i,r,o,s)),u=Math.max(...h),d=l[h.findIndex(e=>e===u)],c=1;for(;c<100&&Math.round(u)eq()?tl(t,n):[t,n];o=o.map(e=>.1>eq()?th(e,a,i,r):e),e.push(...o)}h=(l=e).map(e=>tu(e,t,i,r,o,s));let n=Math.max(...h);u=n,d=l[h.findIndex(e=>e===n)],c+=1}return d},tc={euclidean:30,CIEDE2000:20,contrastRatio:4.5},tf={euclidean:291.48,CIEDE2000:100,contrastRatio:21},tg=(e,t={})=>{let{locked:i=[],simulationType:n="normal",threshold:r,colorModel:o="hsv",colorDifferenceMeasure:s="euclidean",backgroundColor:a=ey}=t,l=r;if(l||(l=tc[s]),"grayscale"===n){let t=tf[s];l=Math.min(l,t/e.colors.length)}let h=eZ(e);if("matrix"!==h.type&&"continuous-scale"!==h.type){if("grayscale"===n){let e=h.colors.map(e=>[eM(e)]),t=td(e,i,n,l,o,s,a);h.colors.forEach((e,i)=>Object.assign(e,function(e,t){let i;let[,n,r]=eD(t,"lab"),[,,,o=1]=eD(t,"rgba"),s=100*e,a=Math.round(s),l=eM(ex([a,n,r],"lab")),h=25;for(;Math.round(s)!==Math.round(l/255*100)&&h>0;)s>l/255*100?a+=1:a-=1,h-=1,l=eM(ex([a,n,r],"lab"));if(Math.round(s)eD(e,o)),t=td(e,i,n,l,o,s,a);h.colors.forEach((e,i)=>{Object.assign(e,ex(t[i],o))})}}return h},tp=[.3,.9],tm=[.5,1],t_=(e,t,i,n=[])=>{let[r]=eD(e,"hsv"),o=Array(i).fill(!1),s=-1===n.findIndex(t=>t&&t.model===e.model&&t.value===e.value),a=Array(i).fill(0).map((i,a)=>{let l=n[a];return l?(o[a]=!0,l):s?(s=!1,o[a]=!0,e):ex([e$(r,t*a),eq(...tp),eq(...tm)],"hsv")});return{newColors:a,locked:o}};function tE(){let e=eX(255),t=eX(255),i=eX(255);return ex([e,t,i],"rgb")}let tv=e=>{let{count:t,colors:i}=e,n=[],r={name:"random",semantic:null,type:"categorical",colors:Array(t).fill(0).map((e,t)=>{let r=i[t];return r?(n[t]=!0,r):tE()})};return tg(r,{locked:n})},tb=["monochromatic"],tC=(e,t)=>{let{count:i=8,tendency:n="tint"}=t,{colors:r=[],color:o}=t;return o||(o=r.find(e=>!!e&&!!e.model&&!!e.value)||tE()),tb.includes(e)&&(r=[]),{color:o,colors:r,count:i,tendency:n}},tS={monochromatic:e3,analogous:e=>{let{count:t,color:i,tendency:n}=e,[r,o,s]=eD(i,"hsv"),a=Math.floor(t/2),l=60/(t-1);r>=60&&r<=240&&(l=-l);let h=(o-.1)/3/(t-a-1),u=(s-.4)/3/a,d=Array(t).fill(0).map((e,t)=>{let i=e$(r,l*(t-a)),n=t<=a?Math.min(o+h*(a-t),1):o+3*h*(a-t),d=t<=a?s-3*u*(a-t):Math.min(s-u*(a-t),1);return ex([i,n,d],"hsv")}),c={name:"analogous",semantic:null,type:"discrete-scale",colors:"tint"===n?d:d.reverse()};return c},achromatic:e=>{let{tendency:t}=e,i={...e,color:"tint"===t?e6:e9},n=e3(i);return{...n,name:"achromatic"}},complementary:e=>{let t;let{count:i,color:n}=e,[r,o,s]=eD(n,"hsv"),a=ex([e$(r,180),o,s],"hsv"),l=eX(80,90),h=eX(15,25),u=Math.floor(i/2),d=e4(n,u,[h,l]),c=e4(a,u,[h,l]).reverse();if(i%2==1){let e=ex([(e$(r,180)+r)/2,eq(.05,.1),eq(.9,.95)],"hsv");t=[...d,e,...c]}else t=[...d,...c];let f={name:"complementary",semantic:null,type:"discrete-scale",colors:t};return f},"split-complementary":e=>{let{count:t,color:i,colors:n}=e,{newColors:r,locked:o}=t_(i,180,t,n);return tg({name:"tetradic",semantic:null,type:"categorical",colors:r},{locked:o})},triadic:e=>{let{count:t,color:i,colors:n}=e,{newColors:r,locked:o}=t_(i,120,t,n);return tg({name:"tetradic",semantic:null,type:"categorical",colors:r},{locked:o})},tetradic:e=>{let{count:t,color:i,colors:n}=e,{newColors:r,locked:o}=t_(i,90,t,n);return tg({name:"tetradic",semantic:null,type:"categorical",colors:r},{locked:o})},polychromatic:e=>{let{count:t,color:i,colors:n}=e,r=360/t,{newColors:o,locked:s}=t_(i,r,t,n);return tg({name:"tetradic",semantic:null,type:"categorical",colors:o},{locked:s})},customized:tv},ty=(e="monochromatic",t={})=>{let i=tC(e,t);try{return tS[e](i)}catch(e){return tv(i)}};i(16243);var tT={}.toString,tR=function(e,t){return tT.call(e)==="[object ".concat(t,"]")},tA=function(e){if(!("object"==typeof e&&null!==e)||!tR(e,"Object"))return!1;if(null===Object.getPrototypeOf(e))return!0;for(var t=e;null!==Object.getPrototypeOf(t);)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t},tN=function(e){for(var t=[],i=1;it.distinct)return -1}return 0};function tw(e){return[e.find(function(e){return o(e.levelOfMeasurements,["Nominal"])}),e.find(function(e){return o(e.levelOfMeasurements,["Interval"])})]}function tD(e,t){var i=t.find(function(t){return t.name===e});return(null==i?void 0:i.recommendation)==="date"?function(t){return new Date(t[e])}:e}function tx(e){return[e.find(function(e){return l(e.levelOfMeasurements,["Time","Ordinal"])}),e.find(function(e){return o(e.levelOfMeasurements,["Interval"])}),e.find(function(e){return o(e.levelOfMeasurements,["Nominal"])})]}function tM(e){var t=e.find(function(e){return l(e.levelOfMeasurements,["Time","Ordinal"])}),i=e.find(function(e){return o(e.levelOfMeasurements,["Nominal"])});return[t,e.find(function(e){return o(e.levelOfMeasurements,["Interval"])}),i]}function tk(e){var t=e.filter(function(e){return o(e.levelOfMeasurements,["Nominal"])}).sort(tI),i=t[0],n=t[1];return[e.find(function(e){return o(e.levelOfMeasurements,["Interval"])}),i,n]}function tP(e){var t,i,r,s,a,l,h=e.filter(function(e){return o(e.levelOfMeasurements,["Nominal"])}).sort(tI);return!function(e,t){if(!Y(e)||0===e.length||!Y(t)||0===t.length||e.length!==t.length)return!1;for(var i={},n=0;nr.corr&&(r.x=i[e],r.y=i[t],r.corr=a,r.size=i[(0,n.ev)([],(0,n.CR)(Array(i.length).keys()),!1).find(function(i){return i!==e&&i!==t})||0])},o=e+1;o0&&(!_||e.spec)}).sort(function(e,t){return e.scoret.score?-1:0}),log:v}}catch(e){return console.error("error: ",e),null}}var tH=function(e){var t,i=e.coordinate;if((null==i?void 0:i.type)==="theta")return(null==i?void 0:i.innerRadius)?"donut_chart":"pie_chart";var n=e.transform,r=null===(t=null==i?void 0:i.transform)||void 0===t?void 0:t.some(function(e){return"transpose"===e.type}),o=null==n?void 0:n.some(function(e){return"normalizeY"===e.type}),s=null==n?void 0:n.some(function(e){return"stackY"===e.type}),a=null==n?void 0:n.some(function(e){return"dodgeX"===e.type});return r?a?"grouped_bar_chart":o?"stacked_bar_chart":s?"percent_stacked_bar_chart":"bar_chart":a?"grouped_column_chart":o?"stacked_column_chart":s?"percent_stacked_column_chart":"column_chart"},tV=function(e){var t=e.transform,i=null==t?void 0:t.some(function(e){return"stackY"===e.type}),n=null==t?void 0:t.some(function(e){return"normalizeY"===e.type});return i?n?"percent_stacked_area_chart":"stacked_area_chart":"area_chart"},tW=function(e){var t=e.encode;return t.shape&&"hvh"===t.shape?"step_line_chart":"line_chart"},tG=function(e){var t;switch(e.type){case"area":t=tV(e);break;case"interval":t=tH(e);break;case"line":t=tW(e);break;case"point":t=e.encode.size?"bubble_chart":"scatter_plot";break;case"rect":t="histogram";break;case"cell":t="heatmap";break;default:t=""}return t};function tj(e,t,i,r,o,s,a){Object.values(e).filter(function(e){var r,o,a=e.option||{},l=a.weight,h=a.extra;return r=e.type,("DESIGN"===t?"DESIGN"===r:"DESIGN"!==r)&&!(null===(o=e.option)||void 0===o?void 0:o.off)&&e.trigger((0,n.pi)((0,n.pi)((0,n.pi)((0,n.pi)({},i),{weight:l}),h),{chartWIKI:s}))}).forEach(function(e){var l,h=e.type,u=e.id,d=e.docs;if("DESIGN"===t){var c=e.optimizer(i.dataProps,a);l=0===Object.keys(c).length?1:0,o.push({type:h,id:u,score:l,fix:c,docs:d})}else{var f=e.option||{},g=f.weight,p=f.extra;l=e.validator((0,n.pi)((0,n.pi)((0,n.pi)((0,n.pi)({},i),{weight:g}),p),{chartWIKI:s})),o.push({type:h,id:u,score:l,docs:d})}r.push({phase:"LINT",ruleId:u,score:l,base:l,weight:1,ruleType:h})})}function tz(e,t,i){var n=e.spec,r=e.options,o=e.dataProps,s=null==r?void 0:r.purpose,a=null==r?void 0:r.preferences,l=tG(n),h=[],u=[];if(!n||!l)return{lints:h,log:u};if(!o||!o.length)try{o=new eC(n.data).info()}catch(e){return console.error("error: ",e),{lints:h,log:u}}var d={dataProps:o,chartType:l,purpose:s,preferences:a};return tj(t,"notDESIGN",d,u,h,i),tj(t,"DESIGN",d,u,h,i,n),{lints:h=h.filter(function(e){return e.score<1}),log:u}}var tK=function(){function e(e){var t,i,o,s,a;void 0===e&&(e={}),this.ckb=(t=e.ckbCfg,i=JSON.parse(JSON.stringify(r)),t?(o=t.exclude,s=t.include,a=t.custom,o&&o.forEach(function(e){Object.keys(i).includes(e)&&delete i[e]}),s&&Object.keys(i).forEach(function(e){s.includes(e)||delete i[e]}),(0,n.pi)((0,n.pi)({},i),a)):i),this.ruleBase=O(e.ruleCfg)}return e.prototype.advise=function(e){return tU(e,this.ckb,this.ruleBase).advices},e.prototype.adviseWithLog=function(e){return tU(e,this.ckb,this.ruleBase)},e.prototype.lint=function(e){return tz(e,this.ruleBase,this.ckb).lints},e.prototype.lintWithLog=function(e){return tz(e,this.ruleBase,this.ckb)},e}()},17816:function(e,t){!function(e){"use strict";function t(e){var t="function"==typeof Symbol&&Symbol.iterator,i=t&&e[t],n=0;if(i)return i.call(e);if(e&&"number"==typeof e.length)return{next:function(){return{value:(e=e&&n>=e.length?void 0:e)&&e[n++],done:!e}}};throw TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function i(e,t){var i="function"==typeof Symbol&&e[Symbol.iterator];if(!i)return e;var n,r,o=i.call(e),s=[];try{for(;(void 0===t||0i=>e(t(i)),e)}function T(e,t){return t-e?i=>(i-e)/(t-e):e=>.5}x=new g(3),g!=Float32Array&&(x[0]=0,x[1]=0,x[2]=0),x=new g(4),g!=Float32Array&&(x[0]=0,x[1]=0,x[2]=0,x[3]=0);let R=Math.sqrt(50),A=Math.sqrt(10),N=Math.sqrt(2);function O(e,t,i){return e=Math.floor(Math.log(t=(t-e)/Math.max(0,i))/Math.LN10),i=t/10**e,0<=e?(i>=R?10:i>=A?5:i>=N?2:1)*10**e:-(10**-e)/(i>=R?10:i>=A?5:i>=N?2:1)}let L=(e,t,i=5)=>{let n=0,r=(e=[e,t]).length-1,o=e[n],s=e[r],a;return s{i.prototype.rescale=function(){this.initRange(),this.nice();var[e]=this.chooseTransforms();this.composeOutput(e,this.chooseClamp(e))},i.prototype.initRange=function(){var t=this.options.interpolator;this.options.range=e(t)},i.prototype.composeOutput=function(e,i){var{domain:n,interpolator:r,round:o}=this.getOptions(),n=t(n.map(e)),o=o?e=>a(e=r(e),"Number")?Math.round(e):e:r;this.output=y(o,n,i,e)},i.prototype.invert=void 0}}var D,x={exports:{}},M={exports:{}},k=Array.prototype.concat,P=Array.prototype.slice,F=M.exports=function(e){for(var t=[],i=0,n=e.length;ii=>e*(1-i)+t*i,q=(e,t)=>{if("number"==typeof e&&"number"==typeof t)return $(e,t);if("string"!=typeof e||"string"!=typeof t)return()=>e;{let i=Y(e),n=Y(t);return null===i||null===n?i?()=>e:()=>t:e=>{var t=[,,,,];for(let s=0;s<4;s+=1){var r=i[s],o=n[s];t[s]=r*(1-e)+o*e}var[s,a,l,h]=t;return`rgba(${Math.round(s)}, ${Math.round(a)}, ${Math.round(l)}, ${h})`}}},X=(e,t)=>{let i=$(e,t);return e=>Math.round(i(e))};function Z({map:e,initKey:t},i){return t=t(i),e.has(t)?e.get(t):i}function Q(e){return"object"==typeof e?e.valueOf():e}class J extends Map{constructor(e){if(super(),this.map=new Map,this.initKey=Q,null!==e)for(var[t,i]of e)this.set(t,i)}get(e){return super.get(Z({map:this.map,initKey:this.initKey},e))}has(e){return super.has(Z({map:this.map,initKey:this.initKey},e))}set(e,t){var i,n;return super.set(([{map:e,initKey:i},n]=[{map:this.map,initKey:this.initKey},e],i=i(n),e.has(i)?e.get(i):(e.set(i,n),n)),t)}delete(e){var t,i;return super.delete(([{map:e,initKey:t},i]=[{map:this.map,initKey:this.initKey},e],t=t(i),e.has(t)&&(i=e.get(t),e.delete(t)),i))}}class ee{constructor(e){this.options=d({},this.getDefaultOptions()),this.update(e)}getOptions(){return this.options}update(e={}){this.options=d({},this.options,e),this.rescale(e)}rescale(e){}}let et=Symbol("defaultUnknown");function ei(e,t,i){for(let n=0;n""+e:"object"==typeof e?e=>JSON.stringify(e):e=>e}class eo extends ee{getDefaultOptions(){return{domain:[],range:[],unknown:et}}constructor(e){super(e)}map(e){return 0===this.domainIndexMap.size&&ei(this.domainIndexMap,this.getDomain(),this.domainKey),en({value:this.domainKey(e),mapper:this.domainIndexMap,from:this.getDomain(),to:this.getRange(),notFoundReturn:this.options.unknown})}invert(e){return 0===this.rangeIndexMap.size&&ei(this.rangeIndexMap,this.getRange(),this.rangeKey),en({value:this.rangeKey(e),mapper:this.rangeIndexMap,from:this.getRange(),to:this.getDomain(),notFoundReturn:this.options.unknown})}rescale(e){var[t]=this.options.domain,[i]=this.options.range;this.domainKey=er(t),this.rangeKey=er(i),this.rangeIndexMap?(e&&!e.range||this.rangeIndexMap.clear(),(!e||e.domain||e.compare)&&(this.domainIndexMap.clear(),this.sortedDomain=void 0)):(this.rangeIndexMap=new Map,this.domainIndexMap=new Map)}clone(){return new eo(this.options)}getRange(){return this.options.range}getDomain(){var e,t;return this.sortedDomain||({domain:e,compare:t}=this.options,this.sortedDomain=t?[...e].sort(t):e),this.sortedDomain}}class es extends eo{getDefaultOptions(){return{domain:[],range:[0,1],align:.5,round:!1,paddingInner:0,paddingOuter:0,padding:0,unknown:et,flex:[]}}constructor(e){super(e)}clone(){return new es(this.options)}getStep(e){return void 0===this.valueStep?1:"number"==typeof this.valueStep?this.valueStep:void 0===e?Array.from(this.valueStep.values())[0]:this.valueStep.get(e)}getBandWidth(e){return void 0===this.valueBandWidth?1:"number"==typeof this.valueBandWidth?this.valueBandWidth:void 0===e?Array.from(this.valueBandWidth.values())[0]:this.valueBandWidth.get(e)}getRange(){return this.adjustedRange}getPaddingInner(){var{padding:e,paddingInner:t}=this.options;return 0e/t)}(h),g=d/f.reduce((e,t)=>e+t);var h=new J(t.map((e,t)=>(t=f[t]*g,[e,s?Math.floor(t):t]))),p=new J(t.map((e,t)=>(t=f[t]*g+c,[e,s?Math.floor(t):t]))),d=Array.from(p.values()).reduce((e,t)=>e+t),e=e+(u-(d-d/l*r))*a;let m=s?Math.round(e):e;var _=Array(l);for(let e=0;el+t*s),{valueStep:s,valueBandWidth:a,adjustedRange:e}}({align:e,range:i,round:n,flex:r,paddingInner:this.getPaddingInner(),paddingOuter:this.getPaddingOuter(),domain:t});this.valueStep=n,this.valueBandWidth=i,this.adjustedRange=e}}let ea=(e,t,i)=>{let n,r,o=e,s=t;if(o===s&&0{let n;var[e,r]=e,[t,o]=t;return y(e{let n=Math.min(e.length,t.length)-1,r=Array(n),o=Array(n);var s=e[0]>e[n],a=s?[...e].reverse():e,l=s?[...t].reverse():t;for(let e=0;e{var i=function(e,t,i,n,r){let o=1,s=n||e.length;for(var a=e=>e;ot?s=l:o=l+1}return o}(e,t,0,n)-1,s=r[i];return y(o[i],s)(t)}},eu=(e,t,i,n)=>(2Math.min(Math.max(n,e),r)}return c}composeOutput(e,t){var{domain:i,range:n,round:r,interpolate:o}=this.options,i=eu(i.map(e),n,o,r);this.output=y(i,t,e)}composeInput(e,t,i){var{domain:n,range:r}=this.options,r=eu(r,n.map(e),$);this.input=y(t,i,r)}}class ec extends ed{getDefaultOptions(){return{domain:[0,1],range:[0,1],unknown:void 0,nice:!1,clamp:!1,round:!1,interpolate:q,tickMethod:ea,tickCount:5}}chooseTransforms(){return[c,c]}clone(){return new ec(this.options)}}class ef extends es{getDefaultOptions(){return{domain:[],range:[0,1],align:.5,round:!1,padding:0,unknown:et,paddingInner:1,paddingOuter:0}}constructor(e){super(e)}getPaddingInner(){return 1}clone(){return new ef(this.options)}update(e){super.update(e)}getPaddingOuter(){return this.options.padding}}function eg(e,t){for(var i=[],n=0,r=e.length;n{var[e,t]=e;return y($(0,1),T(e,t))})],e_);let eE=o=class extends ec{getDefaultOptions(){return{domain:[0,.5,1],unknown:void 0,nice:!1,clamp:!1,round:!1,interpolator:c,tickMethod:ea,tickCount:5}}constructor(e){super(e)}clone(){return new o(this.options)}};function ev(e,t,n,r,o){var s=new ec({range:[t,t+r]}),a=new ec({range:[n,n+o]});return{transform:function(e){var e=i(e,2),t=e[0],e=e[1];return[s.map(t),a.map(e)]},untransform:function(e){var e=i(e,2),t=e[0],e=e[1];return[s.invert(t),a.invert(e)]}}}function eb(e,t,n,r,o){return(0,i(e,1)[0])(t,n,r,o)}function eC(e,t,n,r,o){return i(e,1)[0]}function eS(e,t,n,r,o){var s=(e=i(e,4))[0],a=e[1],l=e[2],e=e[3],h=new ec({range:[l,e]}),u=new ec({range:[s,a]}),d=1<(l=o/r)?1:l,c=1{let[t,i,n]=e,r=y($(0,.5),T(t,i)),o=y($(.5,1),T(i,n));return e=>(t>n?eh&&(h=g)}for(var p=Math.atan(n/(i*Math.tan(r))),m=1/0,_=-1/0,E=[o,s],d=-(2*Math.PI);d<=2*Math.PI;d+=Math.PI){var v=p+d;o_&&(_=C)}return{x:l,y:m,width:h-l,height:_-m}}function l(e,t,i,n){return o(e,t,i,n)}function h(e,t,i,n,r){return{x:(1-r)*e+r*i,y:(1-r)*t+r*n}}function u(e,t,i,n,r){var o=1-r;return o*o*o*e+3*t*r*o*o+3*i*r*r*o+n*r*r*r}function d(e,t,i,n){var o,s,a,l=-3*e+9*t-9*i+3*n,h=6*e-12*t+6*i,u=3*t-3*e,d=[];if((0,r.Z)(l,0))!(0,r.Z)(h,0)&&(o=-u/h)>=0&&o<=1&&d.push(o);else{var c=h*h-4*l*u;(0,r.Z)(c,0)?d.push(-h/(2*l)):c>0&&(o=(-h+(a=Math.sqrt(c)))/(2*l),s=(-h-a)/(2*l),o>=0&&o<=1&&d.push(o),s>=0&&s<=1&&d.push(s))}return d}function c(e,t,i,n,r,o,a,l){for(var h=[e,a],c=[t,l],f=d(e,i,r,a),g=d(t,n,o,l),p=0;p=0?[o]:[]}function m(e,t,i,n,r,o){var a=p(e,i,r)[0],l=p(t,n,o)[0],h=[e,r],u=[t,o];return void 0!==a&&h.push(g(e,i,r,a)),void 0!==l&&u.push(g(t,n,o,l)),s(h,u)}},53984:function(e,t){"use strict";t.Z=function(e,t,i){return ei?i:e}},47427:function(e,t,i){"use strict";var n=i(10410);t.Z=function(e){return Array.isArray?Array.isArray(e):(0,n.Z)(e,"Array")}},63725:function(e,t,i){"use strict";var n=i(10410);t.Z=function(e){return(0,n.Z)(e,"Boolean")}},37377:function(e,t){"use strict";t.Z=function(e){return null==e}},76703:function(e,t,i){"use strict";function n(e,t,i){return void 0===i&&(i=1e-5),Math.abs(e-t)1&&(v*=O=Math.sqrt(O),b*=O);var L=v*v,I=b*b,w=(s===l?-1:1)*Math.sqrt(Math.abs((L*I-L*N*N-I*A*A)/(L*N*N+I*A*A)));p=w*v*N/b+(_+C)/2,m=-(w*b)*A/v+(E+S)/2,f=Math.asin(((E-m)/b*1e9>>0)/1e9),g=Math.asin(((S-m)/b*1e9>>0)/1e9),f=_g&&(f-=2*Math.PI),!l&&g>f&&(g-=2*Math.PI)}var D=g-f;if(Math.abs(D)>y){var x=g,M=C,k=S;R=e(C=p+v*Math.cos(g=f+y*(l&&g>f?1:-1)),S=m+b*Math.sin(g),v,b,o,0,l,M,k,[g,x,p,m])}D=g-f;var P=Math.cos(f),F=Math.cos(g),B=Math.tan(D/4),U=4/3*v*B,H=4/3*b*B,V=[_,E],W=[_+U*Math.sin(f),E-H*P],G=[C+U*Math.sin(g),S-H*F],j=[C,S];if(W[0]=2*V[0]-W[0],W[1]=2*V[1]-W[1],d)return W.concat(G,j,R);R=W.concat(G,j,R);for(var z=[],K=0,Y=R.length;K7){e[i].shift();for(var n=e[i],r=i;n.length;)t[i]="A",e.splice(r+=1,0,["C"].concat(n.splice(0,6)));e.splice(i,1)}}(d,f,_),p=d.length,"Z"===g&&m.push(_),l=(i=d[_]).length,c.x1=+i[l-2],c.y1=+i[l-1],c.x2=+i[l-4]||c.x1,c.y2=+i[l-3]||c.y1}return t?[d,m]:d}},63893:function(e,t,i){"use strict";i.d(t,{R:function(){return n}});var n={a:7,c:6,h:1,l:2,m:2,r:4,q:4,s:4,t:2,v:1,z:0}},54109:function(e,t,i){"use strict";i.d(t,{z:function(){return n}});var n={x1:0,y1:0,x2:0,y2:0,x:0,y:0,qx:null,qy:null}},8699:function(e,t,i){"use strict";function n(e){return e.map(function(e){return Array.isArray(e)?[].concat(e):e})}i.d(t,{U:function(){return n}})},28024:function(e,t,i){"use strict";i.d(t,{A:function(){return f}});var n=i(97582),r=i(12884),o=i(54109),s=i(41793),a=i(66141),l=i(63893);function h(e){for(var t=e.pathValue[e.segmentStart],i=t.toLowerCase(),n=e.data;n.length>=l.R[i]&&("m"===i&&n.length>2?(e.segments.push([t].concat(n.splice(0,2))),i="l",t="m"===t?"l":"L"):e.segments.push([t].concat(n.splice(0,l.R[i]))),l.R[i]););}function u(e){return e>=48&&e<=57}function d(e){for(var t,i=e.pathValue,n=e.max;e.index=5760&&[5760,6158,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8239,8287,12288,65279].includes(t));)e.index+=1}var c=function(e){this.pathValue=e,this.segments=[],this.max=e.length,this.index=0,this.param=0,this.segmentStart=0,this.data=[],this.err=""};function f(e){if((0,r.y)(e))return[].concat(e);for(var t=function(e){if((0,s.b)(e))return[].concat(e);var t=function(e){if((0,a.n)(e))return[].concat(e);var t=new c(e);for(d(t);t.index0;a-=1){if((32|r)==97&&(3===a||4===a)?function(e){var t=e.index,i=e.pathValue,n=i.charCodeAt(t);if(48===n){e.param=0,e.index+=1;return}if(49===n){e.param=1,e.index+=1;return}e.err='[path-util]: invalid Arc flag "'+i[t]+'", expecting 0 or 1 at index '+t}(e):function(e){var t,i=e.max,n=e.pathValue,r=e.index,o=r,s=!1,a=!1,l=!1,h=!1;if(o>=i){e.err="[path-util]: Invalid path value at index "+o+', "pathValue" is missing param';return}if((43===(t=n.charCodeAt(o))||45===t)&&(o+=1,t=n.charCodeAt(o)),!u(t)&&46!==t){e.err="[path-util]: Invalid path value at index "+o+', "'+n[o]+'" is not a number';return}if(46!==t){if(s=48===t,o+=1,t=n.charCodeAt(o),s&&o=e.max||!((s=i.charCodeAt(e.index))>=48&&s<=57||43===s||45===s||46===s))break}h(e)}(t);return t.err?t.err:t.segments}(e),i=0,n=0,r=0,o=0;return t.map(function(e){var t,s=e.slice(1).map(Number),a=e[0],l=a.toUpperCase();if("M"===a)return i=s[0],n=s[1],r=i,o=n,["M",i,n];if(a!==l)switch(l){case"A":t=[l,s[0],s[1],s[2],s[3],s[4],s[5]+i,s[6]+n];break;case"V":t=[l,s[0]+n];break;case"H":t=[l,s[0]+i];break;default:t=[l].concat(s.map(function(e,t){return e+(t%2?n:i)}))}else t=[l].concat(s);var h=t.length;switch(l){case"Z":i=r,n=o;break;case"H":i=t[1];break;case"V":n=t[1];break;default:i=t[h-2],n=t[h-1],"M"===l&&(r=i,o=n)}return t})}(e),i=(0,n.pi)({},o.z),f=0;f=g[t],p[t]-=m?1:0,m?e.ss:[e.s]}).flat()});return _[0].length===_[1].length?_:e(_[0],_[1],f)}}});var n=i(47852),r=i(31427);function o(e){return e.map(function(e,t,i){var o,s,a,l,h,u,d,c,f,g,p,m,_=t&&i[t-1].slice(-2).concat(e.slice(1)),E=t?(0,r.S)(_[0],_[1],_[2],_[3],_[4],_[5],_[6],_[7],_[8],{bbox:!1}).length:0;return m=t?E?(void 0===o&&(o=.5),s=_.slice(0,2),a=_.slice(2,4),l=_.slice(4,6),h=_.slice(6,8),u=(0,n.k)(s,a,o),d=(0,n.k)(a,l,o),c=(0,n.k)(l,h,o),f=(0,n.k)(u,d,o),g=(0,n.k)(d,c,o),p=(0,n.k)(f,g,o),[["C"].concat(u,f,p),["C"].concat(g,c,h)]):[e,e]:[e],{s:e,ss:m,l:E}})}},49958:function(e,t,i){"use strict";i.d(t,{b:function(){return r}});var n=i(75066);function r(e){var t,i,r;return t=0,i=0,r=0,(0,n.Y)(e).map(function(e){if("M"===e[0])return t=e[1],i=e[2],0;var n,o,s,a=e.slice(1),l=a[0],h=a[1],u=a[2],d=a[3],c=a[4],f=a[5];return o=t,r=3*((f-(s=i))*(l+u)-(c-o)*(h+d)+h*(o-u)-l*(s-d)+f*(u+o/3)-c*(d+s/3))/20,t=(n=e.slice(-2))[0],i=n[1],r}).reduce(function(e,t){return e+t},0)>=0}},80431:function(e,t,i){"use strict";i.d(t,{r:function(){return o}});var n=i(97582),r=i(12369);function o(e,t,i){return(0,r.s)(e,t,(0,n.pi)((0,n.pi)({},i),{bbox:!1,length:!0})).point}},88154:function(e,t,i){"use strict";i.d(t,{g:function(){return r}});var n=i(6393);function r(e,t){var i,r,o=e.length-1,s=[],a=0,l=(r=(i=e.length)-1,e.map(function(t,n){return e.map(function(t,o){var s=n+o;return 0===o||e[s]&&"M"===e[s][0]?["M"].concat(e[s].slice(-2)):(s>=i&&(s-=r),e[s])})}));return l.forEach(function(i,r){e.slice(1).forEach(function(i,s){a+=(0,n.y)(e[(r+s)%o].slice(-2),t[s%o].slice(-2))}),s[r]=a,a=0}),l[s.indexOf(Math.min.apply(null,s))]}},72888:function(e,t,i){"use strict";i.d(t,{D:function(){return o}});var n=i(97582),r=i(12369);function o(e,t){return(0,r.s)(e,void 0,(0,n.pi)((0,n.pi)({},t),{bbox:!1,length:!0})).length}},41793:function(e,t,i){"use strict";i.d(t,{b:function(){return r}});var n=i(66141);function r(e){return(0,n.n)(e)&&e.every(function(e){var t=e[0];return t===t.toUpperCase()})}},12884:function(e,t,i){"use strict";i.d(t,{y:function(){return r}});var n=i(41793);function r(e){return(0,n.b)(e)&&e.every(function(e){var t=e[0];return"ACLMQZ".includes(t)})}},66141:function(e,t,i){"use strict";i.d(t,{n:function(){return r}});var n=i(63893);function r(e){return Array.isArray(e)&&e.every(function(e){var t=e[0].toLowerCase();return n.R[t]===e.length-1&&"achlmqstvz".includes(t)})}},47852:function(e,t,i){"use strict";function n(e,t,i){var n=e[0],r=e[1];return[n+(t[0]-n)*i,r+(t[1]-r)*i]}i.d(t,{k:function(){return n}})},12369:function(e,t,i){"use strict";i.d(t,{s:function(){return h}});var n=i(28024),r=i(47852),o=i(6393);function s(e,t,i,n,s){var a=(0,o.y)([e,t],[i,n]),l={x:0,y:0};if("number"==typeof s){if(s<=0)l={x:e,y:t};else if(s>=a)l={x:i,y:n};else{var h=(0,r.k)([e,t],[i,n],s/a);l={x:h[0],y:h[1]}}}return{length:a,point:l,min:{x:Math.min(e,i),y:Math.min(t,n)},max:{x:Math.max(e,i),y:Math.max(t,n)}}}function a(e,t){var i=e.x,n=e.y,r=t.x,o=t.y,s=Math.sqrt((Math.pow(i,2)+Math.pow(n,2))*(Math.pow(r,2)+Math.pow(o,2)));return(i*o-n*r<0?-1:1)*Math.acos((i*r+n*o)/s)}var l=i(31427);function h(e,t,i){for(var r,h,u,d,c,f,g,p,m,_=(0,n.A)(e),E="number"==typeof t,v=[],b=0,C=0,S=0,y=0,T=[],R=[],A=0,N={x:0,y:0},O=N,L=N,I=N,w=0,D=0,x=_.length;D1&&(_*=p(y),E*=p(y));var T=(Math.pow(_,2)*Math.pow(E,2)-Math.pow(_,2)*Math.pow(S.y,2)-Math.pow(E,2)*Math.pow(S.x,2))/(Math.pow(_,2)*Math.pow(S.y,2)+Math.pow(E,2)*Math.pow(S.x,2)),R=(o!==l?1:-1)*p(T=T<0?0:T),A={x:R*(_*S.y/E),y:R*(-(E*S.x)/_)},N={x:g(v)*A.x-f(v)*A.y+(e+h)/2,y:f(v)*A.x+g(v)*A.y+(t+u)/2},O={x:(S.x-A.x)/_,y:(S.y-A.y)/E},L=a({x:1,y:0},O),I=a(O,{x:(-S.x-A.x)/_,y:(-S.y-A.y)/E});!l&&I>0?I-=2*m:l&&I<0&&(I+=2*m);var w=L+(I%=2*m)*d,D=_*g(w),x=E*f(w);return{x:g(v)*D-f(v)*x+N.x,y:f(v)*D+g(v)*x+N.y}}(e,t,i,n,r,l,h,u,d,L/b)).x,y=g.y,m&&O.push({x:S,y:y}),E&&(T+=(0,o.y)(A,[S,y])),A=[S,y],C&&T>=c&&c>R[2]){var I=(T-c)/(T-R[2]);N={x:A[0]*(1-I)+R[0]*I,y:A[1]*(1-I)+R[1]*I}}R=[S,y,T]}return C&&c>=T&&(N={x:u,y:d}),{length:T,point:N,min:{x:Math.min.apply(null,O.map(function(e){return e.x})),y:Math.min.apply(null,O.map(function(e){return e.y}))},max:{x:Math.max.apply(null,O.map(function(e){return e.x})),y:Math.max.apply(null,O.map(function(e){return e.y}))}}}(v[0],v[1],v[2],v[3],v[4],v[5],v[6],v[7],v[8],(t||0)-w,i||{})).length,N=h.min,O=h.max,L=h.point):"C"===p?(A=(u=(0,l.S)(v[0],v[1],v[2],v[3],v[4],v[5],v[6],v[7],(t||0)-w,i||{})).length,N=u.min,O=u.max,L=u.point):"Q"===p?(A=(d=function(e,t,i,n,r,s,a,l){var h,u=l.bbox,d=void 0===u||u,c=l.length,f=void 0===c||c,g=l.sampleSize,p=void 0===g?10:g,m="number"==typeof a,_=e,E=t,v=0,b=[_,E,0],C=[_,E],S={x:0,y:0},y=[{x:_,y:E}];m&&a<=0&&(S={x:_,y:E});for(var T=0;T<=p;T+=1){if(_=(h=function(e,t,i,n,r,o,s){var a=1-s;return{x:Math.pow(a,2)*e+2*a*s*i+Math.pow(s,2)*r,y:Math.pow(a,2)*t+2*a*s*n+Math.pow(s,2)*o}}(e,t,i,n,r,s,T/p)).x,E=h.y,d&&y.push({x:_,y:E}),f&&(v+=(0,o.y)(C,[_,E])),C=[_,E],m&&v>=a&&a>b[2]){var R=(v-a)/(v-b[2]);S={x:C[0]*(1-R)+b[0]*R,y:C[1]*(1-R)+b[1]*R}}b=[_,E,v]}return m&&a>=v&&(S={x:r,y:s}),{length:v,point:S,min:{x:Math.min.apply(null,y.map(function(e){return e.x})),y:Math.min.apply(null,y.map(function(e){return e.y}))},max:{x:Math.max.apply(null,y.map(function(e){return e.x})),y:Math.max.apply(null,y.map(function(e){return e.y}))}}}(v[0],v[1],v[2],v[3],v[4],v[5],(t||0)-w,i||{})).length,N=d.min,O=d.max,L=d.point):"Z"===p&&(A=(c=s((v=[b,C,S,y])[0],v[1],v[2],v[3],(t||0)-w)).length,N=c.min,O=c.max,L=c.point),E&&w=t&&(I=L),R.push(O),T.push(N),w+=A,b=(f="Z"!==p?m.slice(-2):[S,y])[0],C=f[1];return E&&t>=w&&(I={x:b,y:C}),{length:w,point:I,min:{x:Math.min.apply(null,T.map(function(e){return e.x})),y:Math.min.apply(null,T.map(function(e){return e.y}))},max:{x:Math.max.apply(null,R.map(function(e){return e.x})),y:Math.max.apply(null,R.map(function(e){return e.y}))}}}},31427:function(e,t,i){"use strict";i.d(t,{S:function(){return r}});var n=i(6393);function r(e,t,i,r,o,s,a,l,h,u){var d,c=u.bbox,f=void 0===c||c,g=u.length,p=void 0===g||g,m=u.sampleSize,_=void 0===m?10:m,E="number"==typeof h,v=e,b=t,C=0,S=[v,b,0],y=[v,b],T={x:0,y:0},R=[{x:v,y:b}];E&&h<=0&&(T={x:v,y:b});for(var A=0;A<=_;A+=1){if(v=(d=function(e,t,i,n,r,o,s,a,l){var h=1-l;return{x:Math.pow(h,3)*e+3*Math.pow(h,2)*l*i+3*h*Math.pow(l,2)*r+Math.pow(l,3)*s,y:Math.pow(h,3)*t+3*Math.pow(h,2)*l*n+3*h*Math.pow(l,2)*o+Math.pow(l,3)*a}}(e,t,i,r,o,s,a,l,A/_)).x,b=d.y,f&&R.push({x:v,y:b}),p&&(C+=(0,n.y)(y,[v,b])),y=[v,b],E&&C>=h&&h>S[2]){var N=(C-h)/(C-S[2]);T={x:y[0]*(1-N)+S[0]*N,y:y[1]*(1-N)+S[1]*N}}S=[v,b,C]}return E&&h>=C&&(T={x:a,y:l}),{length:C,point:T,min:{x:Math.min.apply(null,R.map(function(e){return e.x})),y:Math.min.apply(null,R.map(function(e){return e.y}))},max:{x:Math.max.apply(null,R.map(function(e){return e.x})),y:Math.max.apply(null,R.map(function(e){return e.y}))}}}},33439:function(e,t,i){"use strict";function n(e,t,i){e.prototype=t.prototype=i,i.constructor=e}function r(e,t){var i=Object.create(e.prototype);for(var n in t)i[n]=t[n];return i}function o(){}i.d(t,{ZP:function(){return v}});var s="\\s*([+-]?\\d+)\\s*",a="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)\\s*",l="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)%\\s*",h=/^#([0-9a-f]{3,8})$/,u=RegExp("^rgb\\("+[s,s,s]+"\\)$"),d=RegExp("^rgb\\("+[l,l,l]+"\\)$"),c=RegExp("^rgba\\("+[s,s,s,a]+"\\)$"),f=RegExp("^rgba\\("+[l,l,l,a]+"\\)$"),g=RegExp("^hsl\\("+[a,l,l]+"\\)$"),p=RegExp("^hsla\\("+[a,l,l,a]+"\\)$"),m={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function _(){return this.rgb().formatHex()}function E(){return this.rgb().formatRgb()}function v(e){var t,i;return e=(e+"").trim().toLowerCase(),(t=h.exec(e))?(i=t[1].length,t=parseInt(t[1],16),6===i?b(t):3===i?new S(t>>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):8===i?C(t>>24&255,t>>16&255,t>>8&255,(255&t)/255):4===i?C(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|240&t,((15&t)<<4|15&t)/255):null):(t=u.exec(e))?new S(t[1],t[2],t[3],1):(t=d.exec(e))?new S(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=c.exec(e))?C(t[1],t[2],t[3],t[4]):(t=f.exec(e))?C(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=g.exec(e))?A(t[1],t[2]/100,t[3]/100,1):(t=p.exec(e))?A(t[1],t[2]/100,t[3]/100,t[4]):m.hasOwnProperty(e)?b(m[e]):"transparent"===e?new S(NaN,NaN,NaN,0):null}function b(e){return new S(e>>16&255,e>>8&255,255&e,1)}function C(e,t,i,n){return n<=0&&(e=t=i=NaN),new S(e,t,i,n)}function S(e,t,i,n){this.r=+e,this.g=+t,this.b=+i,this.opacity=+n}function y(){return"#"+R(this.r)+R(this.g)+R(this.b)}function T(){var e=this.opacity;return(1===(e=isNaN(e)?1:Math.max(0,Math.min(1,e)))?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(1===e?")":", "+e+")")}function R(e){return((e=Math.max(0,Math.min(255,Math.round(e)||0)))<16?"0":"")+e.toString(16)}function A(e,t,i,n){return n<=0?e=t=i=NaN:i<=0||i>=1?e=t=NaN:t<=0&&(e=NaN),new O(e,t,i,n)}function N(e){if(e instanceof O)return new O(e.h,e.s,e.l,e.opacity);if(e instanceof o||(e=v(e)),!e)return new O;if(e instanceof O)return e;var t=(e=e.rgb()).r/255,i=e.g/255,n=e.b/255,r=Math.min(t,i,n),s=Math.max(t,i,n),a=NaN,l=s-r,h=(s+r)/2;return l?(a=t===s?(i-n)/l+(i0&&h<1?0:a,new O(a,l,h,e.opacity)}function O(e,t,i,n){this.h=+e,this.s=+t,this.l=+i,this.opacity=+n}function L(e,t,i){return(e<60?t+(i-t)*e/60:e<180?i:e<240?t+(i-t)*(240-e)/60:t)*255}n(o,v,{copy:function(e){return Object.assign(new this.constructor,this,e)},displayable:function(){return this.rgb().displayable()},hex:_,formatHex:_,formatHsl:function(){return N(this).formatHsl()},formatRgb:E,toString:E}),n(S,function(e,t,i,n){var r;return 1==arguments.length?((r=e)instanceof o||(r=v(r)),r)?(r=r.rgb(),new S(r.r,r.g,r.b,r.opacity)):new S:new S(e,t,i,null==n?1:n)},r(o,{brighter:function(e){return e=null==e?1.4285714285714286:Math.pow(1.4285714285714286,e),new S(this.r*e,this.g*e,this.b*e,this.opacity)},darker:function(e){return e=null==e?.7:Math.pow(.7,e),new S(this.r*e,this.g*e,this.b*e,this.opacity)},rgb:function(){return this},displayable:function(){return -.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:y,formatHex:y,formatRgb:T,toString:T})),n(O,function(e,t,i,n){return 1==arguments.length?N(e):new O(e,t,i,null==n?1:n)},r(o,{brighter:function(e){return e=null==e?1.4285714285714286:Math.pow(1.4285714285714286,e),new O(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=null==e?.7:Math.pow(.7,e),new O(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,i=this.l,n=i+(i<.5?i:1-i)*t,r=2*i-n;return new S(L(e>=240?e-240:e+120,r,n),L(e,r,n),L(e<120?e+240:e-120,r,n),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl:function(){var e=this.opacity;return(1===(e=isNaN(e)?1:Math.max(0,Math.min(1,e)))?"hsl(":"hsla(")+(this.h||0)+", "+100*(this.s||0)+"%, "+100*(this.l||0)+"%"+(1===e?")":", "+e+")")}}))},53406:function(e,t,i){"use strict";i.d(t,{r:function(){return ew}});var n,r,o,s,a,l=i(87462),h=i(63366),u=i(67294),d=i(33703),c=i(73546),f=i(82690);function g(e){if(null==e)return window;if("[object Window]"!==e.toString()){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function p(e){var t=g(e).Element;return e instanceof t||e instanceof Element}function m(e){var t=g(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function _(e){if("undefined"==typeof ShadowRoot)return!1;var t=g(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}var E=Math.max,v=Math.min,b=Math.round;function C(){var e=navigator.userAgentData;return null!=e&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(e){return e.brand+"/"+e.version}).join(" "):navigator.userAgent}function S(){return!/^((?!chrome|android).)*safari/i.test(C())}function y(e,t,i){void 0===t&&(t=!1),void 0===i&&(i=!1);var n=e.getBoundingClientRect(),r=1,o=1;t&&m(e)&&(r=e.offsetWidth>0&&b(n.width)/e.offsetWidth||1,o=e.offsetHeight>0&&b(n.height)/e.offsetHeight||1);var s=(p(e)?g(e):window).visualViewport,a=!S()&&i,l=(n.left+(a&&s?s.offsetLeft:0))/r,h=(n.top+(a&&s?s.offsetTop:0))/o,u=n.width/r,d=n.height/o;return{width:u,height:d,top:h,right:l+u,bottom:h+d,left:l,x:l,y:h}}function T(e){var t=g(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function R(e){return e?(e.nodeName||"").toLowerCase():null}function A(e){return((p(e)?e.ownerDocument:e.document)||window.document).documentElement}function N(e){return y(A(e)).left+T(e).scrollLeft}function O(e){return g(e).getComputedStyle(e)}function L(e){var t=O(e),i=t.overflow,n=t.overflowX,r=t.overflowY;return/auto|scroll|overlay|hidden/.test(i+r+n)}function I(e){var t=y(e),i=e.offsetWidth,n=e.offsetHeight;return 1>=Math.abs(t.width-i)&&(i=t.width),1>=Math.abs(t.height-n)&&(n=t.height),{x:e.offsetLeft,y:e.offsetTop,width:i,height:n}}function w(e){return"html"===R(e)?e:e.assignedSlot||e.parentNode||(_(e)?e.host:null)||A(e)}function D(e,t){void 0===t&&(t=[]);var i,n=function e(t){return["html","body","#document"].indexOf(R(t))>=0?t.ownerDocument.body:m(t)&&L(t)?t:e(w(t))}(e),r=n===(null==(i=e.ownerDocument)?void 0:i.body),o=g(n),s=r?[o].concat(o.visualViewport||[],L(n)?n:[]):n,a=t.concat(s);return r?a:a.concat(D(w(s)))}function x(e){return m(e)&&"fixed"!==O(e).position?e.offsetParent:null}function M(e){for(var t=g(e),i=x(e);i&&["table","td","th"].indexOf(R(i))>=0&&"static"===O(i).position;)i=x(i);return i&&("html"===R(i)||"body"===R(i)&&"static"===O(i).position)?t:i||function(e){var t=/firefox/i.test(C());if(/Trident/i.test(C())&&m(e)&&"fixed"===O(e).position)return null;var i=w(e);for(_(i)&&(i=i.host);m(i)&&0>["html","body"].indexOf(R(i));){var n=O(i);if("none"!==n.transform||"none"!==n.perspective||"paint"===n.contain||-1!==["transform","perspective"].indexOf(n.willChange)||t&&"filter"===n.willChange||t&&n.filter&&"none"!==n.filter)return i;i=i.parentNode}return null}(e)||t}var k="bottom",P="right",F="left",B="auto",U=["top",k,P,F],H="start",V="viewport",W="popper",G=U.reduce(function(e,t){return e.concat([t+"-"+H,t+"-end"])},[]),j=[].concat(U,[B]).reduce(function(e,t){return e.concat([t,t+"-"+H,t+"-end"])},[]),z=["beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite"],K={placement:"bottom",modifiers:[],strategy:"absolute"};function Y(){for(var e=arguments.length,t=Array(e),i=0;i=0?"x":"y"}function Q(e){var t,i=e.reference,n=e.element,r=e.placement,o=r?q(r):null,s=r?X(r):null,a=i.x+i.width/2-n.width/2,l=i.y+i.height/2-n.height/2;switch(o){case"top":t={x:a,y:i.y-n.height};break;case k:t={x:a,y:i.y+i.height};break;case P:t={x:i.x+i.width,y:l};break;case F:t={x:i.x-n.width,y:l};break;default:t={x:i.x,y:i.y}}var h=o?Z(o):null;if(null!=h){var u="y"===h?"height":"width";switch(s){case H:t[h]=t[h]-(i[u]/2-n[u]/2);break;case"end":t[h]=t[h]+(i[u]/2-n[u]/2)}}return t}var J={top:"auto",right:"auto",bottom:"auto",left:"auto"};function ee(e){var t,i,n,r,o,s,a,l=e.popper,h=e.popperRect,u=e.placement,d=e.variation,c=e.offsets,f=e.position,p=e.gpuAcceleration,m=e.adaptive,_=e.roundOffsets,E=e.isFixed,v=c.x,C=void 0===v?0:v,S=c.y,y=void 0===S?0:S,T="function"==typeof _?_({x:C,y:y}):{x:C,y:y};C=T.x,y=T.y;var R=c.hasOwnProperty("x"),N=c.hasOwnProperty("y"),L=F,I="top",w=window;if(m){var D=M(l),x="clientHeight",B="clientWidth";D===g(l)&&"static"!==O(D=A(l)).position&&"absolute"===f&&(x="scrollHeight",B="scrollWidth"),("top"===u||(u===F||u===P)&&"end"===d)&&(I=k,y-=(E&&D===w&&w.visualViewport?w.visualViewport.height:D[x])-h.height,y*=p?1:-1),(u===F||("top"===u||u===k)&&"end"===d)&&(L=P,C-=(E&&D===w&&w.visualViewport?w.visualViewport.width:D[B])-h.width,C*=p?1:-1)}var U=Object.assign({position:f},m&&J),H=!0===_?(t={x:C,y:y},i=g(l),n=t.x,r=t.y,{x:b(n*(o=i.devicePixelRatio||1))/o||0,y:b(r*o)/o||0}):{x:C,y:y};return(C=H.x,y=H.y,p)?Object.assign({},U,((a={})[I]=N?"0":"",a[L]=R?"0":"",a.transform=1>=(w.devicePixelRatio||1)?"translate("+C+"px, "+y+"px)":"translate3d("+C+"px, "+y+"px, 0)",a)):Object.assign({},U,((s={})[I]=N?y+"px":"",s[L]=R?C+"px":"",s.transform="",s))}var et={left:"right",right:"left",bottom:"top",top:"bottom"};function ei(e){return e.replace(/left|right|bottom|top/g,function(e){return et[e]})}var en={start:"end",end:"start"};function er(e){return e.replace(/start|end/g,function(e){return en[e]})}function eo(e,t){var i=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(i&&_(i)){var n=t;do{if(n&&e.isSameNode(n))return!0;n=n.parentNode||n.host}while(n)}return!1}function es(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function ea(e,t,i){var n,r,o,s,a,l,h,u,d,c;return t===V?es(function(e,t){var i=g(e),n=A(e),r=i.visualViewport,o=n.clientWidth,s=n.clientHeight,a=0,l=0;if(r){o=r.width,s=r.height;var h=S();(h||!h&&"fixed"===t)&&(a=r.offsetLeft,l=r.offsetTop)}return{width:o,height:s,x:a+N(e),y:l}}(e,i)):p(t)?((n=y(t,!1,"fixed"===i)).top=n.top+t.clientTop,n.left=n.left+t.clientLeft,n.bottom=n.top+t.clientHeight,n.right=n.left+t.clientWidth,n.width=t.clientWidth,n.height=t.clientHeight,n.x=n.left,n.y=n.top,n):es((r=A(e),s=A(r),a=T(r),l=null==(o=r.ownerDocument)?void 0:o.body,h=E(s.scrollWidth,s.clientWidth,l?l.scrollWidth:0,l?l.clientWidth:0),u=E(s.scrollHeight,s.clientHeight,l?l.scrollHeight:0,l?l.clientHeight:0),d=-a.scrollLeft+N(r),c=-a.scrollTop,"rtl"===O(l||s).direction&&(d+=E(s.clientWidth,l?l.clientWidth:0)-h),{width:h,height:u,x:d,y:c}))}function el(){return{top:0,right:0,bottom:0,left:0}}function eh(e){return Object.assign({},el(),e)}function eu(e,t){return t.reduce(function(t,i){return t[i]=e,t},{})}function ed(e,t){void 0===t&&(t={});var i,n,r,o,s,a,l,h=t,u=h.placement,d=void 0===u?e.placement:u,c=h.strategy,f=void 0===c?e.strategy:c,g=h.boundary,_=h.rootBoundary,b=h.elementContext,C=void 0===b?W:b,S=h.altBoundary,T=h.padding,N=void 0===T?0:T,L=eh("number"!=typeof N?N:eu(N,U)),I=e.rects.popper,x=e.elements[void 0!==S&&S?C===W?"reference":W:C],F=(i=p(x)?x:x.contextElement||A(e.elements.popper),a=(s=[].concat("clippingParents"===(n=void 0===g?"clippingParents":g)?(r=D(w(i)),p(o=["absolute","fixed"].indexOf(O(i).position)>=0&&m(i)?M(i):i)?r.filter(function(e){return p(e)&&eo(e,o)&&"body"!==R(e)}):[]):[].concat(n),[void 0===_?V:_]))[0],(l=s.reduce(function(e,t){var n=ea(i,t,f);return e.top=E(n.top,e.top),e.right=v(n.right,e.right),e.bottom=v(n.bottom,e.bottom),e.left=E(n.left,e.left),e},ea(i,a,f))).width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l),B=y(e.elements.reference),H=Q({reference:B,element:I,strategy:"absolute",placement:d}),G=es(Object.assign({},I,H)),j=C===W?G:B,z={top:F.top-j.top+L.top,bottom:j.bottom-F.bottom+L.bottom,left:F.left-j.left+L.left,right:j.right-F.right+L.right},K=e.modifiersData.offset;if(C===W&&K){var Y=K[d];Object.keys(z).forEach(function(e){var t=[P,k].indexOf(e)>=0?1:-1,i=["top",k].indexOf(e)>=0?"y":"x";z[e]+=Y[i]*t})}return z}function ec(e,t,i){return E(e,v(t,i))}function ef(e,t,i){return void 0===i&&(i={x:0,y:0}),{top:e.top-t.height-i.y,right:e.right-t.width+i.x,bottom:e.bottom-t.height+i.y,left:e.left-t.width-i.x}}function eg(e){return["top",P,k,F].some(function(t){return e[t]>=0})}var ep=(o=void 0===(r=(n={defaultModifiers:[{name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:function(e){var t=e.state,i=e.instance,n=e.options,r=n.scroll,o=void 0===r||r,s=n.resize,a=void 0===s||s,l=g(t.elements.popper),h=[].concat(t.scrollParents.reference,t.scrollParents.popper);return o&&h.forEach(function(e){e.addEventListener("scroll",i.update,$)}),a&&l.addEventListener("resize",i.update,$),function(){o&&h.forEach(function(e){e.removeEventListener("scroll",i.update,$)}),a&&l.removeEventListener("resize",i.update,$)}},data:{}},{name:"popperOffsets",enabled:!0,phase:"read",fn:function(e){var t=e.state,i=e.name;t.modifiersData[i]=Q({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})},data:{}},{name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:function(e){var t=e.state,i=e.options,n=i.gpuAcceleration,r=i.adaptive,o=i.roundOffsets,s=void 0===o||o,a={placement:q(t.placement),variation:X(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:void 0===n||n,isFixed:"fixed"===t.options.strategy};null!=t.modifiersData.popperOffsets&&(t.styles.popper=Object.assign({},t.styles.popper,ee(Object.assign({},a,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:void 0===r||r,roundOffsets:s})))),null!=t.modifiersData.arrow&&(t.styles.arrow=Object.assign({},t.styles.arrow,ee(Object.assign({},a,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:s})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})},data:{}},{name:"applyStyles",enabled:!0,phase:"write",fn:function(e){var t=e.state;Object.keys(t.elements).forEach(function(e){var i=t.styles[e]||{},n=t.attributes[e]||{},r=t.elements[e];m(r)&&R(r)&&(Object.assign(r.style,i),Object.keys(n).forEach(function(e){var t=n[e];!1===t?r.removeAttribute(e):r.setAttribute(e,!0===t?"":t)}))})},effect:function(e){var t=e.state,i={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,i.popper),t.styles=i,t.elements.arrow&&Object.assign(t.elements.arrow.style,i.arrow),function(){Object.keys(t.elements).forEach(function(e){var n=t.elements[e],r=t.attributes[e]||{},o=Object.keys(t.styles.hasOwnProperty(e)?t.styles[e]:i[e]).reduce(function(e,t){return e[t]="",e},{});m(n)&&R(n)&&(Object.assign(n.style,o),Object.keys(r).forEach(function(e){n.removeAttribute(e)}))})}},requires:["computeStyles"]},{name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:function(e){var t=e.state,i=e.options,n=e.name,r=i.offset,o=void 0===r?[0,0]:r,s=j.reduce(function(e,i){var n,r,s,a,l,h;return e[i]=(n=t.rects,s=[F,"top"].indexOf(r=q(i))>=0?-1:1,l=(a="function"==typeof o?o(Object.assign({},n,{placement:i})):o)[0],h=a[1],l=l||0,h=(h||0)*s,[F,P].indexOf(r)>=0?{x:h,y:l}:{x:l,y:h}),e},{}),a=s[t.placement],l=a.x,h=a.y;null!=t.modifiersData.popperOffsets&&(t.modifiersData.popperOffsets.x+=l,t.modifiersData.popperOffsets.y+=h),t.modifiersData[n]=s}},{name:"flip",enabled:!0,phase:"main",fn:function(e){var t=e.state,i=e.options,n=e.name;if(!t.modifiersData[n]._skip){for(var r=i.mainAxis,o=void 0===r||r,s=i.altAxis,a=void 0===s||s,l=i.fallbackPlacements,h=i.padding,u=i.boundary,d=i.rootBoundary,c=i.altBoundary,f=i.flipVariations,g=void 0===f||f,p=i.allowedAutoPlacements,m=t.options.placement,_=q(m)===m,E=l||(_||!g?[ei(m)]:function(e){if(q(e)===B)return[];var t=ei(e);return[er(e),t,er(t)]}(m)),v=[m].concat(E).reduce(function(e,i){var n,r,o,s,a,l,c,f,m,_,E,v;return e.concat(q(i)===B?(r=(n={placement:i,boundary:u,rootBoundary:d,padding:h,flipVariations:g,allowedAutoPlacements:p}).placement,o=n.boundary,s=n.rootBoundary,a=n.padding,l=n.flipVariations,f=void 0===(c=n.allowedAutoPlacements)?j:c,0===(E=(_=(m=X(r))?l?G:G.filter(function(e){return X(e)===m}):U).filter(function(e){return f.indexOf(e)>=0})).length&&(E=_),Object.keys(v=E.reduce(function(e,i){return e[i]=ed(t,{placement:i,boundary:o,rootBoundary:s,padding:a})[q(i)],e},{})).sort(function(e,t){return v[e]-v[t]})):i)},[]),b=t.rects.reference,C=t.rects.popper,S=new Map,y=!0,T=v[0],R=0;R=0,I=L?"width":"height",w=ed(t,{placement:A,boundary:u,rootBoundary:d,altBoundary:c,padding:h}),D=L?O?P:F:O?k:"top";b[I]>C[I]&&(D=ei(D));var x=ei(D),M=[];if(o&&M.push(w[N]<=0),a&&M.push(w[D]<=0,w[x]<=0),M.every(function(e){return e})){T=A,y=!1;break}S.set(A,M)}if(y)for(var V=g?3:1,W=function(e){var t=v.find(function(t){var i=S.get(t);if(i)return i.slice(0,e).every(function(e){return e})});if(t)return T=t,"break"},z=V;z>0&&"break"!==W(z);z--);t.placement!==T&&(t.modifiersData[n]._skip=!0,t.placement=T,t.reset=!0)}},requiresIfExists:["offset"],data:{_skip:!1}},{name:"preventOverflow",enabled:!0,phase:"main",fn:function(e){var t=e.state,i=e.options,n=e.name,r=i.mainAxis,o=i.altAxis,s=i.boundary,a=i.rootBoundary,l=i.altBoundary,h=i.padding,u=i.tether,d=void 0===u||u,c=i.tetherOffset,f=void 0===c?0:c,g=ed(t,{boundary:s,rootBoundary:a,padding:h,altBoundary:l}),p=q(t.placement),m=X(t.placement),_=!m,b=Z(p),C="x"===b?"y":"x",S=t.modifiersData.popperOffsets,y=t.rects.reference,T=t.rects.popper,R="function"==typeof f?f(Object.assign({},t.rects,{placement:t.placement})):f,A="number"==typeof R?{mainAxis:R,altAxis:R}:Object.assign({mainAxis:0,altAxis:0},R),N=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,O={x:0,y:0};if(S){if(void 0===r||r){var L,w="y"===b?"top":F,D="y"===b?k:P,x="y"===b?"height":"width",B=S[b],U=B+g[w],V=B-g[D],W=d?-T[x]/2:0,G=m===H?y[x]:T[x],j=m===H?-T[x]:-y[x],z=t.elements.arrow,K=d&&z?I(z):{width:0,height:0},Y=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:el(),$=Y[w],Q=Y[D],J=ec(0,y[x],K[x]),ee=_?y[x]/2-W-J-$-A.mainAxis:G-J-$-A.mainAxis,et=_?-y[x]/2+W+J+Q+A.mainAxis:j+J+Q+A.mainAxis,ei=t.elements.arrow&&M(t.elements.arrow),en=ei?"y"===b?ei.clientTop||0:ei.clientLeft||0:0,er=null!=(L=null==N?void 0:N[b])?L:0,eo=B+ee-er-en,es=B+et-er,ea=ec(d?v(U,eo):U,B,d?E(V,es):V);S[b]=ea,O[b]=ea-B}if(void 0!==o&&o){var eh,eu,ef="x"===b?"top":F,eg="x"===b?k:P,ep=S[C],em="y"===C?"height":"width",e_=ep+g[ef],eE=ep-g[eg],ev=-1!==["top",F].indexOf(p),eb=null!=(eu=null==N?void 0:N[C])?eu:0,eC=ev?e_:ep-y[em]-T[em]-eb+A.altAxis,eS=ev?ep+y[em]+T[em]-eb-A.altAxis:eE,ey=d&&ev?(eh=ec(eC,ep,eS))>eS?eS:eh:ec(d?eC:e_,ep,d?eS:eE);S[C]=ey,O[C]=ey-ep}t.modifiersData[n]=O}},requiresIfExists:["offset"]},{name:"arrow",enabled:!0,phase:"main",fn:function(e){var t,i,n=e.state,r=e.name,o=e.options,s=n.elements.arrow,a=n.modifiersData.popperOffsets,l=q(n.placement),h=Z(l),u=[F,P].indexOf(l)>=0?"height":"width";if(s&&a){var d=eh("number"!=typeof(t="function"==typeof(t=o.padding)?t(Object.assign({},n.rects,{placement:n.placement})):t)?t:eu(t,U)),c=I(s),f="y"===h?"top":F,g="y"===h?k:P,p=n.rects.reference[u]+n.rects.reference[h]-a[h]-n.rects.popper[u],m=a[h]-n.rects.reference[h],_=M(s),E=_?"y"===h?_.clientHeight||0:_.clientWidth||0:0,v=d[f],b=E-c[u]-d[g],C=E/2-c[u]/2+(p/2-m/2),S=ec(v,C,b);n.modifiersData[r]=((i={})[h]=S,i.centerOffset=S-C,i)}},effect:function(e){var t=e.state,i=e.options.element,n=void 0===i?"[data-popper-arrow]":i;null!=n&&("string"!=typeof n||(n=t.elements.popper.querySelector(n)))&&eo(t.elements.popper,n)&&(t.elements.arrow=n)},requires:["popperOffsets"],requiresIfExists:["preventOverflow"]},{name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:function(e){var t=e.state,i=e.name,n=t.rects.reference,r=t.rects.popper,o=t.modifiersData.preventOverflow,s=ed(t,{elementContext:"reference"}),a=ed(t,{altBoundary:!0}),l=ef(s,n),h=ef(a,r,o),u=eg(l),d=eg(h);t.modifiersData[i]={referenceClippingOffsets:l,popperEscapeOffsets:h,isReferenceHidden:u,hasPopperEscaped:d},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":d})}}]}).defaultModifiers)?[]:r,a=void 0===(s=n.defaultOptions)?K:s,function(e,t,i){void 0===i&&(i=a);var n,r={placement:"bottom",orderedModifiers:[],options:Object.assign({},K,a),modifiersData:{},elements:{reference:e,popper:t},attributes:{},styles:{}},s=[],l=!1,h={state:r,setOptions:function(i){var n,l,d,c,f,g="function"==typeof i?i(r.options):i;u(),r.options=Object.assign({},a,r.options,g),r.scrollParents={reference:p(e)?D(e):e.contextElement?D(e.contextElement):[],popper:D(t)};var m=(l=Object.keys(n=[].concat(o,r.options.modifiers).reduce(function(e,t){var i=e[t.name];return e[t.name]=i?Object.assign({},i,t,{options:Object.assign({},i.options,t.options),data:Object.assign({},i.data,t.data)}):t,e},{})).map(function(e){return n[e]}),d=new Map,c=new Set,f=[],l.forEach(function(e){d.set(e.name,e)}),l.forEach(function(e){c.has(e.name)||function e(t){c.add(t.name),[].concat(t.requires||[],t.requiresIfExists||[]).forEach(function(t){if(!c.has(t)){var i=d.get(t);i&&e(i)}}),f.push(t)}(e)}),z.reduce(function(e,t){return e.concat(f.filter(function(e){return e.phase===t}))},[]));return r.orderedModifiers=m.filter(function(e){return e.enabled}),r.orderedModifiers.forEach(function(e){var t=e.name,i=e.options,n=e.effect;if("function"==typeof n){var o=n({state:r,name:t,instance:h,options:void 0===i?{}:i});s.push(o||function(){})}}),h.update()},forceUpdate:function(){if(!l){var e,t,i,n,o,s,a,u,d,c,f,p,_=r.elements,E=_.reference,v=_.popper;if(Y(E,v)){r.rects={reference:(t=M(v),i="fixed"===r.options.strategy,n=m(t),u=m(t)&&(s=b((o=t.getBoundingClientRect()).width)/t.offsetWidth||1,a=b(o.height)/t.offsetHeight||1,1!==s||1!==a),d=A(t),c=y(E,u,i),f={scrollLeft:0,scrollTop:0},p={x:0,y:0},(n||!n&&!i)&&(("body"!==R(t)||L(d))&&(f=(e=t)!==g(e)&&m(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:T(e)),m(t)?(p=y(t,!0),p.x+=t.clientLeft,p.y+=t.clientTop):d&&(p.x=N(d))),{x:c.left+f.scrollLeft-p.x,y:c.top+f.scrollTop-p.y,width:c.width,height:c.height}),popper:I(v)},r.reset=!1,r.placement=r.options.placement,r.orderedModifiers.forEach(function(e){return r.modifiersData[e.name]=Object.assign({},e.data)});for(var C=0;C{!r&&s(("function"==typeof n?n():n)||document.body)},[n,r]),(0,c.Z)(()=>{if(o&&!r)return(0,eE.Z)(t,o),()=>{(0,eE.Z)(t,null)}},[t,o,r]),r)?u.isValidElement(i)?u.cloneElement(i,{ref:a}):(0,ev.jsx)(u.Fragment,{children:i}):(0,ev.jsx)(u.Fragment,{children:o?e_.createPortal(i,o):o})});var eC=i(34867);function eS(e){return(0,eC.Z)("MuiPopper",e)}(0,i(1588).Z)("MuiPopper",["root"]);var ey=i(7293);let eT=u.createContext({disableDefaultClasses:!1}),eR=["anchorEl","children","direction","disablePortal","modifiers","open","placement","popperOptions","popperRef","slotProps","slots","TransitionProps","ownerState"],eA=["anchorEl","children","container","direction","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","style","transition","slotProps","slots"];function eN(e){return"function"==typeof e?e():e}let eO=()=>(0,em.Z)({root:["root"]},function(e){let{disableDefaultClasses:t}=u.useContext(eT);return i=>t?"":e(i)}(eS)),eL={},eI=u.forwardRef(function(e,t){var i;let{anchorEl:n,children:r,direction:o,disablePortal:s,modifiers:a,open:f,placement:g,popperOptions:p,popperRef:m,slotProps:_={},slots:E={},TransitionProps:v}=e,b=(0,h.Z)(e,eR),C=u.useRef(null),S=(0,d.Z)(C,t),y=u.useRef(null),T=(0,d.Z)(y,m),R=u.useRef(T);(0,c.Z)(()=>{R.current=T},[T]),u.useImperativeHandle(m,()=>y.current,[]);let A=function(e,t){if("ltr"===t)return e;switch(e){case"bottom-end":return"bottom-start";case"bottom-start":return"bottom-end";case"top-end":return"top-start";case"top-start":return"top-end";default:return e}}(g,o),[N,O]=u.useState(A),[L,I]=u.useState(eN(n));u.useEffect(()=>{y.current&&y.current.forceUpdate()}),u.useEffect(()=>{n&&I(eN(n))},[n]),(0,c.Z)(()=>{if(!L||!f)return;let e=e=>{O(e.placement)},t=[{name:"preventOverflow",options:{altBoundary:s}},{name:"flip",options:{altBoundary:s}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:t})=>{e(t)}}];null!=a&&(t=t.concat(a)),p&&null!=p.modifiers&&(t=t.concat(p.modifiers));let i=ep(L,C.current,(0,l.Z)({placement:A},p,{modifiers:t}));return R.current(i),()=>{i.destroy(),R.current(null)}},[L,s,a,f,p,A]);let w={placement:N};null!==v&&(w.TransitionProps=v);let D=eO(),x=null!=(i=E.root)?i:"div",M=(0,ey.y)({elementType:x,externalSlotProps:_.root,externalForwardedProps:b,additionalProps:{role:"tooltip",ref:S},ownerState:e,className:D.root});return(0,ev.jsx)(x,(0,l.Z)({},M,{children:"function"==typeof r?r(w):r}))}),ew=u.forwardRef(function(e,t){let i;let{anchorEl:n,children:r,container:o,direction:s="ltr",disablePortal:a=!1,keepMounted:d=!1,modifiers:c,open:g,placement:p="bottom",popperOptions:m=eL,popperRef:_,style:E,transition:v=!1,slotProps:b={},slots:C={}}=e,S=(0,h.Z)(e,eA),[y,T]=u.useState(!0);if(!d&&!g&&(!v||y))return null;if(o)i=o;else if(n){let e=eN(n);i=e&&void 0!==e.nodeType?(0,f.Z)(e).body:(0,f.Z)(null).body}let R=!g&&d&&(!v||y)?"none":void 0;return(0,ev.jsx)(eb,{disablePortal:a,container:i,children:(0,ev.jsx)(eI,(0,l.Z)({anchorEl:n,direction:s,disablePortal:a,modifiers:c,ref:t,open:v?!y:g,placement:p,popperOptions:m,popperRef:_,slotProps:b,slots:C},S,{style:(0,l.Z)({position:"fixed",top:0,left:0,display:R},E),TransitionProps:v?{in:g,onEnter:()=>{T(!1)},onExited:()=>{T(!0)}}:void 0,children:r}))})})},70758:function(e,t,i){"use strict";i.d(t,{U:function(){return l}});var n=i(87462),r=i(67294),o=i(99962),s=i(33703),a=i(30437);function l(e={}){let{disabled:t=!1,focusableWhenDisabled:i,href:l,rootRef:h,tabIndex:u,to:d,type:c}=e,f=r.useRef(),[g,p]=r.useState(!1),{isFocusVisibleRef:m,onFocus:_,onBlur:E,ref:v}=(0,o.Z)(),[b,C]=r.useState(!1);t&&!i&&b&&C(!1),r.useEffect(()=>{m.current=b},[b,m]);let[S,y]=r.useState(""),T=e=>t=>{var i;b&&t.preventDefault(),null==(i=e.onMouseLeave)||i.call(e,t)},R=e=>t=>{var i;E(t),!1===m.current&&C(!1),null==(i=e.onBlur)||i.call(e,t)},A=e=>t=>{var i,n;f.current||(f.current=t.currentTarget),_(t),!0===m.current&&(C(!0),null==(n=e.onFocusVisible)||n.call(e,t)),null==(i=e.onFocus)||i.call(e,t)},N=()=>{let e=f.current;return"BUTTON"===S||"INPUT"===S&&["button","submit","reset"].includes(null==e?void 0:e.type)||"A"===S&&(null==e?void 0:e.href)},O=e=>i=>{if(!t){var n;null==(n=e.onClick)||n.call(e,i)}},L=e=>i=>{var n;t||(p(!0),document.addEventListener("mouseup",()=>{p(!1)},{once:!0})),null==(n=e.onMouseDown)||n.call(e,i)},I=e=>i=>{var n,r;null==(n=e.onKeyDown)||n.call(e,i),!i.defaultMuiPrevented&&(i.target!==i.currentTarget||N()||" "!==i.key||i.preventDefault(),i.target!==i.currentTarget||" "!==i.key||t||p(!0),i.target!==i.currentTarget||N()||"Enter"!==i.key||t||(null==(r=e.onClick)||r.call(e,i),i.preventDefault()))},w=e=>i=>{var n,r;i.target===i.currentTarget&&p(!1),null==(n=e.onKeyUp)||n.call(e,i),i.target!==i.currentTarget||N()||t||" "!==i.key||i.defaultMuiPrevented||null==(r=e.onClick)||r.call(e,i)},D=r.useCallback(e=>{var t;y(null!=(t=null==e?void 0:e.tagName)?t:"")},[]),x=(0,s.Z)(D,h,v,f),M={};return void 0!==u&&(M.tabIndex=u),"BUTTON"===S?(M.type=null!=c?c:"button",i?M["aria-disabled"]=t:M.disabled=t):""!==S&&(l||d||(M.role="button",M.tabIndex=null!=u?u:0),t&&(M["aria-disabled"]=t,M.tabIndex=i?null!=u?u:0:-1)),{getRootProps:(t={})=>{let i=(0,n.Z)({},(0,a._)(e),(0,a._)(t)),r=(0,n.Z)({type:c},i,M,t,{onBlur:R(i),onClick:O(i),onFocus:A(i),onKeyDown:I(i),onKeyUp:w(i),onMouseDown:L(i),onMouseLeave:T(i),ref:x});return delete r.onFocusVisible,r},focusVisible:b,setFocusVisible:C,active:g,rootRef:x}}},26558:function(e,t,i){"use strict";i.d(t,{Z:function(){return r}});var n=i(67294);let r=n.createContext(null)},22644:function(e,t,i){"use strict";i.d(t,{F:function(){return n}});let n={blur:"list:blur",focus:"list:focus",itemClick:"list:itemClick",itemHover:"list:itemHover",itemsChange:"list:itemsChange",keyDown:"list:keyDown",resetHighlight:"list:resetHighlight",textNavigation:"list:textNavigation"}},7333:function(e,t,i){"use strict";i.d(t,{R$:function(){return a},Rl:function(){return o}});var n=i(87462),r=i(22644);function o(e,t,i){var n;let r,o;let{items:s,isItemDisabled:a,disableListWrap:l,disabledItemsFocusable:h,itemComparer:u,focusManagement:d}=i,c=s.length-1,f=null==e?-1:s.findIndex(t=>u(t,e)),g=!l;switch(t){case"reset":if(-1==("DOM"===d?0:-1))return null;r=0,o="next",g=!1;break;case"start":r=0,o="next",g=!1;break;case"end":r=c,o="previous",g=!1;break;default:{let e=f+t;e<0?!g&&-1!==f||Math.abs(t)>1?(r=0,o="next"):(r=c,o="previous"):e>c?!g||Math.abs(t)>1?(r=c,o="previous"):(r=0,o="next"):(r=e,o=t>=0?"next":"previous")}}let p=function(e,t,i,n,r,o){if(0===i.length||!n&&i.every((e,t)=>r(e,t)))return -1;let s=e;for(;;){if(!o&&"next"===t&&s===i.length||!o&&"previous"===t&&-1===s)return -1;let e=!n&&r(i[s],s);if(!e)return s;s+="next"===t?1:-1,o&&(s=(s+i.length)%i.length)}}(r,o,s,h,a,g);return -1!==p||null===e||a(e,f)?null!=(n=s[p])?n:null:e}function s(e,t,i){let{itemComparer:r,isItemDisabled:o,selectionMode:s,items:a}=i,{selectedValues:l}=t,h=a.findIndex(t=>r(e,t));if(o(e,h))return t;let u="none"===s?[]:"single"===s?r(l[0],e)?l:[e]:l.some(t=>r(t,e))?l.filter(t=>!r(t,e)):[...l,e];return(0,n.Z)({},t,{selectedValues:u,highlightedValue:e})}function a(e,t){let{type:i,context:a}=t;switch(i){case r.F.keyDown:return function(e,t,i){let r=t.highlightedValue,{orientation:a,pageSize:l}=i;switch(e){case"Home":return(0,n.Z)({},t,{highlightedValue:o(r,"start",i)});case"End":return(0,n.Z)({},t,{highlightedValue:o(r,"end",i)});case"PageUp":return(0,n.Z)({},t,{highlightedValue:o(r,-l,i)});case"PageDown":return(0,n.Z)({},t,{highlightedValue:o(r,l,i)});case"ArrowUp":if("vertical"!==a)break;return(0,n.Z)({},t,{highlightedValue:o(r,-1,i)});case"ArrowDown":if("vertical"!==a)break;return(0,n.Z)({},t,{highlightedValue:o(r,1,i)});case"ArrowLeft":if("vertical"===a)break;return(0,n.Z)({},t,{highlightedValue:o(r,"horizontal-ltr"===a?-1:1,i)});case"ArrowRight":if("vertical"===a)break;return(0,n.Z)({},t,{highlightedValue:o(r,"horizontal-ltr"===a?1:-1,i)});case"Enter":case" ":if(null===t.highlightedValue)break;return s(t.highlightedValue,t,i)}return t}(t.key,e,a);case r.F.itemClick:return s(t.item,e,a);case r.F.blur:return"DOM"===a.focusManagement?e:(0,n.Z)({},e,{highlightedValue:null});case r.F.textNavigation:return function(e,t,i){let{items:r,isItemDisabled:s,disabledItemsFocusable:a,getItemAsString:l}=i,h=t.length>1,u=h?e.highlightedValue:o(e.highlightedValue,1,i);for(let d=0;dl(e,i.highlightedValue)))?a:null:"DOM"===h&&0===t.length&&(u=o(null,"reset",r));let d=null!=(s=i.selectedValues)?s:[],c=d.filter(t=>e.some(e=>l(e,t)));return(0,n.Z)({},i,{highlightedValue:u,selectedValues:c})}(t.items,t.previousItems,e,a);case r.F.resetHighlight:return(0,n.Z)({},e,{highlightedValue:o(null,"reset",a)});default:return e}}},96592:function(e,t,i){"use strict";i.d(t,{s:function(){return v}});var n=i(87462),r=i(67294),o=i(33703),s=i(22644),a=i(7333);let l="select:change-selection",h="select:change-highlight";var u=i(78031),d=i(6414);function c(e,t){let i=r.useRef(e);return r.useEffect(()=>{i.current=e},null!=t?t:[e]),i}let f={},g=()=>{},p=(e,t)=>e===t,m=()=>!1,_=e=>"string"==typeof e?e:String(e),E=()=>({highlightedValue:null,selectedValues:[]});function v(e){let{controlledProps:t=f,disabledItemsFocusable:i=!1,disableListWrap:v=!1,focusManagement:b="activeDescendant",getInitialState:C=E,getItemDomElement:S,getItemId:y,isItemDisabled:T=m,rootRef:R,onStateChange:A=g,items:N,itemComparer:O=p,getItemAsString:L=_,onChange:I,onHighlightChange:w,onItemsChange:D,orientation:x="vertical",pageSize:M=5,reducerActionContext:k=f,selectionMode:P="single",stateReducer:F}=e,B=r.useRef(null),U=(0,o.Z)(R,B),H=r.useCallback((e,t,i)=>{if(null==w||w(e,t,i),"DOM"===b&&null!=t&&(i===s.F.itemClick||i===s.F.keyDown||i===s.F.textNavigation)){var n;null==S||null==(n=S(t))||n.focus()}},[S,w,b]),V=r.useMemo(()=>({highlightedValue:O,selectedValues:(e,t)=>(0,d.H)(e,t,O)}),[O]),W=r.useCallback((e,t,i,n,r)=>{switch(null==A||A(e,t,i,n,r),t){case"highlightedValue":H(e,i,n);break;case"selectedValues":null==I||I(e,i,n)}},[H,I,A]),G=r.useMemo(()=>({disabledItemsFocusable:i,disableListWrap:v,focusManagement:b,isItemDisabled:T,itemComparer:O,items:N,getItemAsString:L,onHighlightChange:H,orientation:x,pageSize:M,selectionMode:P,stateComparers:V}),[i,v,b,T,O,N,L,H,x,M,P,V]),j=C(),z=null!=F?F:a.R$,K=r.useMemo(()=>(0,n.Z)({},k,G),[k,G]),[Y,$]=(0,u.r)({reducer:z,actionContext:K,initialState:j,controlledProps:t,stateComparers:V,onStateChange:W}),{highlightedValue:q,selectedValues:X}=Y,Z=function(e){let t=r.useRef({searchString:"",lastTime:null});return r.useCallback(i=>{if(1===i.key.length&&" "!==i.key){let n=t.current,r=i.key.toLowerCase(),o=performance.now();n.searchString.length>0&&n.lastTime&&o-n.lastTime>500?n.searchString=r:(1!==n.searchString.length||r!==n.searchString)&&(n.searchString+=r),n.lastTime=o,e(n.searchString,i)}},[e])}((e,t)=>$({type:s.F.textNavigation,event:t,searchString:e})),Q=c(X),J=c(q),ee=r.useRef([]);r.useEffect(()=>{(0,d.H)(ee.current,N,O)||($({type:s.F.itemsChange,event:null,items:N,previousItems:ee.current}),ee.current=N,null==D||D(N))},[N,O,$,D]);let{notifySelectionChanged:et,notifyHighlightChanged:ei,registerHighlightChangeHandler:en,registerSelectionChangeHandler:er}=function(){let e=function(){let e=r.useRef();return e.current||(e.current=function(){let e=new Map;return{subscribe:function(t,i){let n=e.get(t);return n?n.add(i):(n=new Set([i]),e.set(t,n)),()=>{n.delete(i),0===n.size&&e.delete(t)}},publish:function(t,...i){let n=e.get(t);n&&n.forEach(e=>e(...i))}}}()),e.current}(),t=r.useCallback(t=>{e.publish(l,t)},[e]),i=r.useCallback(t=>{e.publish(h,t)},[e]),n=r.useCallback(t=>e.subscribe(l,t),[e]),o=r.useCallback(t=>e.subscribe(h,t),[e]);return{notifySelectionChanged:t,notifyHighlightChanged:i,registerSelectionChangeHandler:n,registerHighlightChangeHandler:o}}();r.useEffect(()=>{et(X)},[X,et]),r.useEffect(()=>{ei(q)},[q,ei]);let eo=e=>t=>{var i;if(null==(i=e.onKeyDown)||i.call(e,t),t.defaultMuiPrevented)return;let n=["Home","End","PageUp","PageDown"];"vertical"===x?n.push("ArrowUp","ArrowDown"):n.push("ArrowLeft","ArrowRight"),"activeDescendant"===b&&n.push(" ","Enter"),n.includes(t.key)&&t.preventDefault(),$({type:s.F.keyDown,key:t.key,event:t}),Z(t)},es=e=>t=>{var i,n;null==(i=e.onBlur)||i.call(e,t),t.defaultMuiPrevented||null!=(n=B.current)&&n.contains(t.relatedTarget)||$({type:s.F.blur,event:t})},ea=r.useCallback(e=>{var t;let i=N.findIndex(t=>O(t,e)),n=(null!=(t=Q.current)?t:[]).some(t=>null!=t&&O(e,t)),r=T(e,i),o=null!=J.current&&O(e,J.current),s="DOM"===b;return{disabled:r,focusable:s,highlighted:o,index:i,selected:n}},[N,T,O,Q,J,b]),el=r.useMemo(()=>({dispatch:$,getItemState:ea,registerHighlightChangeHandler:en,registerSelectionChangeHandler:er}),[$,ea,en,er]);return r.useDebugValue({state:Y}),{contextValue:el,dispatch:$,getRootProps:(e={})=>(0,n.Z)({},e,{"aria-activedescendant":"activeDescendant"===b&&null!=q?y(q):void 0,onBlur:es(e),onKeyDown:eo(e),tabIndex:"DOM"===b?-1:0,ref:U}),rootRef:U,state:Y}}},43069:function(e,t,i){"use strict";i.d(t,{J:function(){return h}});var n=i(87462),r=i(67294),o=i(33703),s=i(73546),a=i(22644),l=i(26558);function h(e){let t;let{handlePointerOverEvents:i=!1,item:h,rootRef:u}=e,d=r.useRef(null),c=(0,o.Z)(d,u),f=r.useContext(l.Z);if(!f)throw Error("useListItem must be used within a ListProvider");let{dispatch:g,getItemState:p,registerHighlightChangeHandler:m,registerSelectionChangeHandler:_}=f,{highlighted:E,selected:v,focusable:b}=p(h),C=function(){let[,e]=r.useState({});return r.useCallback(()=>{e({})},[])}();(0,s.Z)(()=>m(function(e){e!==h||E?e!==h&&E&&C():C()})),(0,s.Z)(()=>_(function(e){v?e.includes(h)||C():e.includes(h)&&C()}),[_,C,v,h]);let S=r.useCallback(e=>t=>{var i;null==(i=e.onClick)||i.call(e,t),t.defaultPrevented||g({type:a.F.itemClick,item:h,event:t})},[g,h]),y=r.useCallback(e=>t=>{var i;null==(i=e.onMouseOver)||i.call(e,t),t.defaultPrevented||g({type:a.F.itemHover,item:h,event:t})},[g,h]);return b&&(t=E?0:-1),{getRootProps:(e={})=>(0,n.Z)({},e,{onClick:S(e),onPointerOver:i?y(e):void 0,ref:c,tabIndex:t}),highlighted:E,rootRef:c,selected:v}}},10238:function(e,t,i){"use strict";i.d(t,{$:function(){return o}});var n=i(87462),r=i(28442);function o(e,t,i){return void 0===e||(0,r.X)(e)?t:(0,n.Z)({},t,{ownerState:(0,n.Z)({},t.ownerState,i)})}},6414:function(e,t,i){"use strict";function n(e,t,i=(e,t)=>e===t){return e.length===t.length&&e.every((e,n)=>i(e,t[n]))}i.d(t,{H:function(){return n}})},2900:function(e,t,i){"use strict";i.d(t,{f:function(){return r}});var n=i(87462);function r(e,t){return function(i={}){let r=(0,n.Z)({},i,e(i)),o=(0,n.Z)({},r,t(r));return o}}},30437:function(e,t,i){"use strict";function n(e,t=[]){if(void 0===e)return{};let i={};return Object.keys(e).filter(i=>i.match(/^on[A-Z]/)&&"function"==typeof e[i]&&!t.includes(i)).forEach(t=>{i[t]=e[t]}),i}i.d(t,{_:function(){return n}})},28442:function(e,t,i){"use strict";function n(e){return"string"==typeof e}i.d(t,{X:function(){return n}})},24407:function(e,t,i){"use strict";i.d(t,{L:function(){return a}});var n=i(87462),r=i(90512),o=i(30437);function s(e){if(void 0===e)return{};let t={};return Object.keys(e).filter(t=>!(t.match(/^on[A-Z]/)&&"function"==typeof e[t])).forEach(i=>{t[i]=e[i]}),t}function a(e){let{getSlotProps:t,additionalProps:i,externalSlotProps:a,externalForwardedProps:l,className:h}=e;if(!t){let e=(0,r.Z)(null==l?void 0:l.className,null==a?void 0:a.className,h,null==i?void 0:i.className),t=(0,n.Z)({},null==i?void 0:i.style,null==l?void 0:l.style,null==a?void 0:a.style),o=(0,n.Z)({},i,l,a);return e.length>0&&(o.className=e),Object.keys(t).length>0&&(o.style=t),{props:o,internalRef:void 0}}let u=(0,o._)((0,n.Z)({},l,a)),d=s(a),c=s(l),f=t(u),g=(0,r.Z)(null==f?void 0:f.className,null==i?void 0:i.className,h,null==l?void 0:l.className,null==a?void 0:a.className),p=(0,n.Z)({},null==f?void 0:f.style,null==i?void 0:i.style,null==l?void 0:l.style,null==a?void 0:a.style),m=(0,n.Z)({},f,i,c,d);return g.length>0&&(m.className=g),Object.keys(p).length>0&&(m.style=p),{props:m,internalRef:f.ref}}},71276:function(e,t,i){"use strict";function n(e,t,i){return"function"==typeof e?e(t,i):e}i.d(t,{x:function(){return n}})},12247:function(e,t,i){"use strict";i.d(t,{Y:function(){return o},s:function(){return r}});var n=i(67294);let r=n.createContext(null);function o(){let[e,t]=n.useState(new Map),i=n.useRef(new Set),r=n.useCallback(function(e){i.current.delete(e),t(t=>{let i=new Map(t);return i.delete(e),i})},[]),o=n.useCallback(function(e,n){let o;return o="function"==typeof e?e(i.current):e,i.current.add(o),t(e=>{let t=new Map(e);return t.set(o,n),t}),{id:o,deregister:()=>r(o)}},[r]),s=n.useMemo(()=>(function(e){let t=Array.from(e.keys()).map(t=>{let i=e.get(t);return{key:t,subitem:i}});return t.sort((e,t)=>{let i=e.subitem.ref.current,n=t.subitem.ref.current;return null===i||null===n||i===n?0:i.compareDocumentPosition(n)&Node.DOCUMENT_POSITION_PRECEDING?1:-1}),new Map(t.map(e=>[e.key,e.subitem]))})(e),[e]),a=n.useCallback(function(e){return Array.from(s.keys()).indexOf(e)},[s]),l=n.useMemo(()=>({getItemIndex:a,registerItem:o,totalSubitemCount:e.size}),[a,o,e.size]);return{contextValue:l,subitems:s}}r.displayName="CompoundComponentContext"},14072:function(e,t,i){"use strict";i.d(t,{B:function(){return s}});var n=i(67294),r=i(73546),o=i(12247);function s(e,t){let i=n.useContext(o.s);if(null===i)throw Error("useCompoundItem must be used within a useCompoundParent");let{registerItem:s}=i,[a,l]=n.useState("function"==typeof e?void 0:e);return(0,r.Z)(()=>{let{id:i,deregister:n}=s(e,t);return l(i),n},[s,t,e]),{id:a,index:void 0!==a?i.getItemIndex(a):-1,totalItemCount:i.totalSubitemCount}}},78031:function(e,t,i){"use strict";i.d(t,{r:function(){return h}});var n=i(87462),r=i(67294);function o(e,t){return e===t}let s={},a=()=>{};function l(e,t){let i=(0,n.Z)({},e);return Object.keys(t).forEach(e=>{void 0!==t[e]&&(i[e]=t[e])}),i}function h(e){let t=r.useRef(null),{reducer:i,initialState:h,controlledProps:u=s,stateComparers:d=s,onStateChange:c=a,actionContext:f}=e,g=r.useCallback((e,n)=>{t.current=n;let r=l(e,u),o=i(r,n);return o},[u,i]),[p,m]=r.useReducer(g,h),_=r.useCallback(e=>{m((0,n.Z)({},e,{context:f}))},[f]);return!function(e){let{nextState:t,initialState:i,stateComparers:n,onStateChange:s,controlledProps:a,lastActionRef:h}=e,u=r.useRef(i);r.useEffect(()=>{if(null===h.current)return;let e=l(u.current,a);Object.keys(t).forEach(i=>{var r,a,l;let u=null!=(r=n[i])?r:o,d=t[i],c=e[i];(null!=c||null==d)&&(null==c||null!=d)&&(null==c||null==d||u(d,c))||null==s||s(null!=(a=h.current.event)?a:null,i,d,null!=(l=h.current.type)?l:"",t)}),u.current=t,h.current=null},[u,t,h,s,n,a])}({nextState:p,initialState:h,stateComparers:null!=d?d:s,onStateChange:null!=c?c:a,controlledProps:u,lastActionRef:t}),[l(p,u),_]}},7293:function(e,t,i){"use strict";i.d(t,{y:function(){return u}});var n=i(87462),r=i(63366),o=i(33703),s=i(10238),a=i(24407),l=i(71276);let h=["elementType","externalSlotProps","ownerState","skipResolvingSlotProps"];function u(e){var t;let{elementType:i,externalSlotProps:u,ownerState:d,skipResolvingSlotProps:c=!1}=e,f=(0,r.Z)(e,h),g=c?{}:(0,l.x)(u,d),{props:p,internalRef:m}=(0,a.L)((0,n.Z)({},f,{externalSlotProps:g})),_=(0,o.Z)(m,null==g?void 0:g.ref,null==(t=e.additionalProps)?void 0:t.ref),E=(0,s.$)(i,(0,n.Z)({},p,{ref:_}),d);return E}},48665:function(e,t,i){"use strict";i.d(t,{Z:function(){return _}});var n=i(87462),r=i(63366),o=i(67294),s=i(90512),a=i(49731),l=i(86523),h=i(39707),u=i(96682),d=i(85893);let c=["className","component"];var f=i(37078),g=i(1812),p=i(2548);let m=function(e={}){let{themeId:t,defaultTheme:i,defaultClassName:f="MuiBox-root",generateClassName:g}=e,p=(0,a.ZP)("div",{shouldForwardProp:e=>"theme"!==e&&"sx"!==e&&"as"!==e})(l.Z),m=o.forwardRef(function(e,o){let a=(0,u.Z)(i),l=(0,h.Z)(e),{className:m,component:_="div"}=l,E=(0,r.Z)(l,c);return(0,d.jsx)(p,(0,n.Z)({as:_,ref:o,className:(0,s.Z)(m,g?g(f):f),theme:t&&a[t]||a},E))});return m}({themeId:p.Z,defaultTheme:g.Z,defaultClassName:"MuiBox-root",generateClassName:f.Z.generate});var _=m},41118:function(e,t,i){"use strict";i.d(t,{Z:function(){return S}});var n=i(63366),r=i(87462),o=i(67294),s=i(90512),a=i(94780),l=i(14142),h=i(18719),u=i(20407),d=i(74312),c=i(78653),f=i(26821);function g(e){return(0,f.d6)("MuiCard",e)}(0,f.sI)("MuiCard",["root","colorPrimary","colorNeutral","colorDanger","colorSuccess","colorWarning","colorContext","variantPlain","variantOutlined","variantSoft","variantSolid","sizeSm","sizeMd","sizeLg","horizontal","vertical"]);var p=i(58859),m=i(30220),_=i(85893);let E=["className","color","component","invertedColors","size","variant","children","orientation","slots","slotProps"],v=e=>{let{size:t,variant:i,color:n,orientation:r}=e,o={root:["root",r,i&&`variant${(0,l.Z)(i)}`,n&&`color${(0,l.Z)(n)}`,t&&`size${(0,l.Z)(t)}`]};return(0,a.Z)(o,g,{})},b=(0,d.Z)("div",{name:"JoyCard",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e,ownerState:t})=>{var i,n;let{p:o,padding:s,borderRadius:a}=(0,p.V)({theme:e,ownerState:t},["p","padding","borderRadius"]);return[(0,r.Z)({"--Icon-color":"neutral"!==t.color||"solid"===t.variant?"currentColor":e.vars.palette.text.icon,"--Card-childRadius":"max((var(--Card-radius) - var(--variant-borderWidth, 0px)) - var(--Card-padding), min(var(--Card-padding) / 2, (var(--Card-radius) - var(--variant-borderWidth, 0px)) / 2))","--AspectRatio-radius":"var(--Card-childRadius)","--unstable_actionMargin":"calc(-1 * var(--variant-borderWidth, 0px))","--unstable_actionRadius":"var(--Card-radius)","--CardCover-radius":"calc(var(--Card-radius) - var(--variant-borderWidth, 0px))","--CardOverflow-offset":"calc(-1 * var(--Card-padding))","--CardOverflow-radius":"calc(var(--Card-radius) - var(--variant-borderWidth, 0px))","--Divider-inset":"calc(-1 * var(--Card-padding))"},"sm"===t.size&&{"--Card-radius":e.vars.radius.sm,"--Card-padding":"0.625rem",gap:"0.5rem"},"md"===t.size&&{"--Card-radius":e.vars.radius.md,"--Card-padding":"1rem",gap:"0.75rem 1rem"},"lg"===t.size&&{"--Card-radius":e.vars.radius.lg,"--Card-padding":"1.5rem",gap:"1rem 1.5rem"},{padding:"var(--Card-padding)",borderRadius:"var(--Card-radius)",backgroundColor:e.vars.palette.background.surface,position:"relative",display:"flex",flexDirection:"horizontal"===t.orientation?"row":"column"},e.typography[`body-${t.size}`],null==(i=e.variants[t.variant])?void 0:i[t.color]),"context"!==t.color&&t.invertedColors&&(null==(n=e.colorInversion[t.variant])?void 0:n[t.color]),void 0!==o&&{"--Card-padding":o},void 0!==s&&{"--Card-padding":s},void 0!==a&&{"--Card-radius":a}]}),C=o.forwardRef(function(e,t){let i=(0,u.Z)({props:e,name:"JoyCard"}),{className:a,color:l="neutral",component:d="div",invertedColors:f=!1,size:g="md",variant:p="outlined",children:C,orientation:S="vertical",slots:y={},slotProps:T={}}=i,R=(0,n.Z)(i,E),{getColor:A}=(0,c.VT)(p),N=A(e.color,l),O=(0,r.Z)({},i,{color:N,component:d,orientation:S,size:g,variant:p}),L=v(O),I=(0,r.Z)({},R,{component:d,slots:y,slotProps:T}),[w,D]=(0,m.Z)("root",{ref:t,className:(0,s.Z)(L.root,a),elementType:b,externalForwardedProps:I,ownerState:O}),x=(0,_.jsx)(w,(0,r.Z)({},D,{children:o.Children.map(C,(e,t)=>{if(!o.isValidElement(e))return e;let i={};if((0,h.Z)(e,["Divider"])){i.inset="inset"in e.props?e.props.inset:"context";let t="vertical"===S?"horizontal":"vertical";i.orientation="orientation"in e.props?e.props.orientation:t}return(0,h.Z)(e,["CardOverflow"])&&("horizontal"===S&&(i["data-parent"]="Card-horizontal"),"vertical"===S&&(i["data-parent"]="Card-vertical")),0===t&&(i["data-first-child"]=""),t===o.Children.count(C)-1&&(i["data-last-child"]=""),o.cloneElement(e,i)})}));return f?(0,_.jsx)(c.do,{variant:p,children:x}):x});var S=C},30208:function(e,t,i){"use strict";i.d(t,{Z:function(){return v}});var n=i(87462),r=i(63366),o=i(67294),s=i(90512),a=i(94780),l=i(20407),h=i(74312),u=i(26821);function d(e){return(0,u.d6)("MuiCardContent",e)}(0,u.sI)("MuiCardContent",["root"]);let c=(0,u.sI)("MuiCardOverflow",["root","colorPrimary","colorNeutral","colorDanger","colorSuccess","colorWarning","colorContext","variantPlain","variantOutlined","variantSoft","variantSolid"]);var f=i(30220),g=i(85893);let p=["className","component","children","orientation","slots","slotProps"],m=()=>(0,a.Z)({root:["root"]},d,{}),_=(0,h.Z)("div",{name:"JoyCardContent",slot:"Root",overridesResolver:(e,t)=>t.root})(({ownerState:e})=>({display:"flex",flexDirection:"horizontal"===e.orientation?"row":"column",flex:9999,zIndex:1,columnGap:"var(--Card-padding)",rowGap:"max(2px, calc(0.1875 * var(--Card-padding)))",padding:"var(--unstable_padding)",[`.${c.root} > &`]:{"--unstable_padding":"calc(var(--Card-padding) * 0.75) 0px"}})),E=o.forwardRef(function(e,t){let i=(0,l.Z)({props:e,name:"JoyCardContent"}),{className:o,component:a="div",children:h,orientation:u="vertical",slots:d={},slotProps:c={}}=i,E=(0,r.Z)(i,p),v=(0,n.Z)({},E,{component:a,slots:d,slotProps:c}),b=(0,n.Z)({},i,{component:a,orientation:u}),C=m(),[S,y]=(0,f.Z)("root",{ref:t,className:(0,s.Z)(C.root,o),elementType:_,externalForwardedProps:v,ownerState:b});return(0,g.jsx)(S,(0,n.Z)({},y,{children:h}))});var v=E},76043:function(e,t,i){"use strict";var n=i(67294);let r=n.createContext(void 0);t.Z=r},43614:function(e,t,i){"use strict";var n=i(67294);let r=n.createContext(void 0);t.Z=r},50984:function(e,t,i){"use strict";i.d(t,{C:function(){return s}});var n=i(87462);i(67294);var r=i(74312),o=i(58859);i(85893);let s=(0,r.Z)("ul")(({theme:e,ownerState:t})=>{var i;let{p:r,padding:s,borderRadius:a}=(0,o.V)({theme:e,ownerState:t},["p","padding","borderRadius"]);function l(i){return"sm"===i?{"--ListDivider-gap":"0.25rem","--ListItem-minHeight":"2rem","--ListItem-paddingY":"0.25rem","--ListItem-paddingX":"0.5rem","--ListItemDecorator-size":"horizontal"===t.orientation?"1.5rem":"2rem","--Icon-fontSize":e.vars.fontSize.lg}:"md"===i?{"--ListDivider-gap":"0.375rem","--ListItem-minHeight":"2.5rem","--ListItem-paddingY":"0.375rem","--ListItem-paddingX":"0.75rem","--ListItemDecorator-size":"horizontal"===t.orientation?"1.75rem":"2.5rem","--Icon-fontSize":e.vars.fontSize.xl}:"lg"===i?{"--ListDivider-gap":"0.5rem","--ListItem-minHeight":"3rem","--ListItem-paddingY":"0.5rem","--ListItem-paddingX":"1rem","--ListItemDecorator-size":"horizontal"===t.orientation?"2.25rem":"3rem","--Icon-fontSize":e.vars.fontSize.xl2}:{}}return[t.nesting&&(0,n.Z)({},l(t.instanceSize),{"--ListItem-paddingRight":"var(--ListItem-paddingX)","--ListItem-paddingLeft":"var(--NestedListItem-paddingLeft)","--ListItemButton-marginBlock":"0px","--ListItemButton-marginInline":"0px","--ListItem-marginBlock":"0px","--ListItem-marginInline":"0px",padding:0,marginInlineStart:"var(--NestedList-marginLeft)",marginInlineEnd:"var(--NestedList-marginRight)",marginBlockStart:"var(--List-gap)",marginBlockEnd:"initial"}),!t.nesting&&(0,n.Z)({},l(t.size),{"--List-gap":"0px","--List-nestedInsetStart":"0px","--ListItem-paddingLeft":"var(--ListItem-paddingX)","--ListItem-paddingRight":"var(--ListItem-paddingX)","--unstable_List-childRadius":"calc(max(var(--List-radius) - var(--List-padding), min(var(--List-padding) / 2, var(--List-radius) / 2)) - var(--variant-borderWidth, 0px))","--ListItem-radius":"var(--unstable_List-childRadius)","--ListItem-startActionTranslateX":"calc(0.5 * var(--ListItem-paddingLeft))","--ListItem-endActionTranslateX":"calc(-0.5 * var(--ListItem-paddingRight))",margin:"initial"},e.typography[`body-${t.size}`],"horizontal"===t.orientation?(0,n.Z)({},t.wrap?{padding:"var(--List-padding)",marginInlineStart:"calc(-1 * var(--List-gap))",marginBlockStart:"calc(-1 * var(--List-gap))"}:{paddingInline:"var(--List-padding, var(--ListDivider-gap))",paddingBlock:"var(--List-padding)"}):{paddingBlock:"var(--List-padding, var(--ListDivider-gap))",paddingInline:"var(--List-padding)"}),(0,n.Z)({boxSizing:"border-box",borderRadius:"var(--List-radius)",listStyle:"none",display:"flex",flexDirection:"horizontal"===t.orientation?"row":"column"},t.wrap&&{flexWrap:"wrap"},{flexGrow:1,position:"relative"},null==(i=e.variants[t.variant])?void 0:i[t.color],{"--unstable_List-borderWidth":"var(--variant-borderWidth, 0px)"},void 0!==a&&{"--List-radius":a},void 0!==r&&{"--List-padding":r},void 0!==s&&{"--List-padding":s})]});(0,r.Z)(s,{name:"JoyList",slot:"Root",overridesResolver:(e,t)=>t.root})({})},3419:function(e,t,i){"use strict";i.d(t,{Z:function(){return u},M:function(){return h}});var n=i(87462),r=i(67294),o=i(40780);let s=r.createContext(!1),a=r.createContext(!1);var l=i(85893);let h={"--NestedList-marginRight":"0px","--NestedList-marginLeft":"0px","--NestedListItem-paddingLeft":"var(--ListItem-paddingX)","--ListItemButton-marginBlock":"0px","--ListItemButton-marginInline":"0px","--ListItem-marginBlock":"0px","--ListItem-marginInline":"0px"};var u=function(e){let{children:t,nested:i,row:h=!1,wrap:u=!1}=e,d=(0,l.jsx)(o.Z.Provider,{value:h,children:(0,l.jsx)(s.Provider,{value:u,children:r.Children.map(t,(e,i)=>r.isValidElement(e)?r.cloneElement(e,(0,n.Z)({},0===i&&{"data-first-child":""},i===r.Children.count(t)-1&&{"data-last-child":""})):e)})});return void 0===i?d:(0,l.jsx)(a.Provider,{value:i,children:d})}},40780:function(e,t,i){"use strict";var n=i(67294);let r=n.createContext(!1);t.Z=r},39984:function(e,t,i){"use strict";i.d(t,{r:function(){return l}});var n=i(87462);i(67294);var r=i(74312),o=i(26821);let s=(0,o.sI)("MuiListItem",["root","startAction","endAction","nested","nesting","sticky","colorPrimary","colorNeutral","colorDanger","colorSuccess","colorWarning","colorContext","variantPlain","variantSoft","variantOutlined","variantSolid"]),a=(0,o.sI)("MuiListItemButton",["root","horizontal","vertical","colorPrimary","colorNeutral","colorDanger","colorSuccess","colorWarning","colorContext","focusVisible","disabled","selected","variantPlain","variantSoft","variantOutlined","variantSolid"]);i(85893);let l=(0,r.Z)("div")(({theme:e,ownerState:t})=>{var i,r,o,l,h;return(0,n.Z)({"--Icon-margin":"initial","--Icon-color":"neutral"!==t.color||"solid"===t.variant?"currentColor":e.vars.palette.text.icon,WebkitTapHighlightColor:"transparent",boxSizing:"border-box",position:"relative",font:"inherit",display:"flex",flexDirection:"row",alignItems:"center",alignSelf:"stretch"},"vertical"===t.orientation&&{flexDirection:"column",justifyContent:"center"},{textAlign:"initial",textDecoration:"initial",backgroundColor:"initial",cursor:"pointer",marginInline:"var(--ListItemButton-marginInline)",marginBlock:"var(--ListItemButton-marginBlock)"},void 0===t["data-first-child"]&&{marginInlineStart:t.row?"var(--List-gap)":void 0,marginBlockStart:t.row?void 0:"var(--List-gap)"},{paddingBlock:"calc(var(--ListItem-paddingY) - var(--variant-borderWidth, 0px))",paddingInlineStart:"calc(var(--ListItem-paddingLeft) + var(--ListItem-startActionWidth, var(--unstable_startActionWidth, 0px)))",paddingInlineEnd:"calc(var(--ListItem-paddingRight) + var(--ListItem-endActionWidth, var(--unstable_endActionWidth, 0px)))",minBlockSize:"var(--ListItem-minHeight)",border:"1px solid transparent",borderRadius:"var(--ListItem-radius)",flex:"var(--unstable_ListItem-flex, none)",fontSize:"inherit",lineHeight:"inherit",minInlineSize:0,[e.focus.selector]:(0,n.Z)({},e.focus.default,{zIndex:1})},null==(i=e.variants[t.variant])?void 0:i[t.color],{[`.${s.root} > &`]:{"--unstable_ListItem-flex":"1 0 0%"},[`&.${a.selected}`]:(0,n.Z)({},null==(r=e.variants[`${t.variant}Active`])?void 0:r[t.color],{"--Icon-color":"currentColor"}),[`&:not(.${a.selected}, [aria-selected="true"])`]:{"&:hover":null==(o=e.variants[`${t.variant}Hover`])?void 0:o[t.color],"&:active":null==(l=e.variants[`${t.variant}Active`])?void 0:l[t.color]},[`&.${a.disabled}`]:(0,n.Z)({},null==(h=e.variants[`${t.variant}Disabled`])?void 0:h[t.color])})});(0,r.Z)(l,{name:"JoyListItemButton",slot:"Root",overridesResolver:(e,t)=>t.root})(({ownerState:e,theme:t})=>(0,n.Z)({},!e.row&&{[`&.${a.selected}`]:{fontWeight:t.vars.fontWeight.md}}))},57814:function(e,t,i){"use strict";i.d(t,{Z:function(){return A}});var n=i(87462),r=i(63366),o=i(67294),s=i(94780),a=i(92996),l=i(33703),h=i(43069),u=i(14072),d=i(30220),c=i(39984),f=i(74312),g=i(20407),p=i(78653),m=i(55907),_=i(26821);function E(e){return(0,_.d6)("MuiOption",e)}let v=(0,_.sI)("MuiOption",["root","colorPrimary","colorNeutral","colorDanger","colorSuccess","colorWarning","colorContext","focusVisible","disabled","selected","highlighted","variantPlain","variantSoft","variantOutlined","variantSolid"]);var b=i(40780),C=i(85893);let S=["component","children","disabled","value","label","variant","color","slots","slotProps"],y=e=>{let{disabled:t,highlighted:i,selected:n}=e;return(0,s.Z)({root:["root",t&&"disabled",i&&"highlighted",n&&"selected"]},E,{})},T=(0,f.Z)(c.r,{name:"JoyOption",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e,ownerState:t})=>{var i;let n=null==(i=e.variants[`${t.variant}Hover`])?void 0:i[t.color];return{[`&.${v.highlighted}:not([aria-selected="true"])`]:{backgroundColor:null==n?void 0:n.backgroundColor}}}),R=o.forwardRef(function(e,t){var i;let s=(0,g.Z)({props:e,name:"JoyOption"}),{component:c="li",children:f,disabled:_=!1,value:E,label:v,variant:R="plain",color:A="neutral",slots:N={},slotProps:O={}}=s,L=(0,r.Z)(s,S),I=o.useContext(b.Z),{variant:w=R,color:D=A}=(0,m.yP)(e.variant,e.color),x=o.useRef(null),M=(0,l.Z)(x,t),k=null!=v?v:"string"==typeof f?f:null==(i=x.current)?void 0:i.innerText,{getRootProps:P,selected:F,highlighted:B,index:U}=function(e){let{value:t,label:i,disabled:r,rootRef:s,id:d}=e,{getRootProps:c,rootRef:f,highlighted:g,selected:p}=(0,h.J)({item:t}),m=(0,a.Z)(d),_=o.useRef(null),E=o.useMemo(()=>({disabled:r,label:i,value:t,ref:_,id:m}),[r,i,t,m]),{index:v}=(0,u.B)(t,E),b=(0,l.Z)(s,_,f);return{getRootProps:(e={})=>(0,n.Z)({},e,c(e),{id:m,ref:b,role:"option","aria-selected":p}),highlighted:g,index:v,selected:p,rootRef:b}}({disabled:_,label:k,value:E,rootRef:M}),{getColor:H}=(0,p.VT)(w),V=H(e.color,D),W=(0,n.Z)({},s,{disabled:_,selected:F,highlighted:B,index:U,component:c,variant:w,color:V,row:I}),G=y(W),j=(0,n.Z)({},L,{component:c,slots:N,slotProps:O}),[z,K]=(0,d.Z)("root",{ref:t,getSlotProps:P,elementType:T,externalForwardedProps:j,className:G.root,ownerState:W});return(0,C.jsx)(z,(0,n.Z)({},K,{children:f}))});var A=R},99056:function(e,t,i){"use strict";i.d(t,{Z:function(){return ea}});var n,r=i(63366),o=i(87462),s=i(67294),a=i(90512),l=i(14142),h=i(33703),u=i(53406),d=i(92996),c=i(73546),f=i(70758);let g={buttonClick:"buttonClick"};var p=i(96592);let m=e=>{let{label:t,value:i}=e;return"string"==typeof t?t:"string"==typeof i?i:String(e)};var _=i(12247),E=i(7333),v=i(22644);function b(e,t){var i,n,r;let{open:s}=e,{context:{selectionMode:a}}=t;if(t.type===g.buttonClick){let n=null!=(i=e.selectedValues[0])?i:(0,E.Rl)(null,"start",t.context);return(0,o.Z)({},e,{open:!s,highlightedValue:s?null:n})}let l=(0,E.R$)(e,t);switch(t.type){case v.F.keyDown:if(e.open){if("Escape"===t.event.key||"single"===a&&("Enter"===t.event.key||" "===t.event.key))return(0,o.Z)({},l,{open:!1})}else{if("Enter"===t.event.key||" "===t.event.key||"ArrowDown"===t.event.key)return(0,o.Z)({},e,{open:!0,highlightedValue:null!=(n=e.selectedValues[0])?n:(0,E.Rl)(null,"start",t.context)});if("ArrowUp"===t.event.key)return(0,o.Z)({},e,{open:!0,highlightedValue:null!=(r=e.selectedValues[0])?r:(0,E.Rl)(null,"end",t.context)})}break;case v.F.itemClick:if("single"===a)return(0,o.Z)({},l,{open:!1});break;case v.F.blur:return(0,o.Z)({},l,{open:!1})}return l}var C=i(2900);let S={clip:"rect(1px, 1px, 1px, 1px)",clipPath:"inset(50%)",height:"1px",width:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"absolute",left:"50%",bottom:0},y=()=>{};function T(e){return Array.isArray(e)?0===e.length?"":JSON.stringify(e.map(e=>e.value)):(null==e?void 0:e.value)==null?"":"string"==typeof e.value||"number"==typeof e.value?e.value:JSON.stringify(e.value)}function R(e){e.preventDefault()}var A=i(26558),N=i(85893);function O(e){let{value:t,children:i}=e,{dispatch:n,getItemIndex:r,getItemState:o,registerHighlightChangeHandler:a,registerSelectionChangeHandler:l,registerItem:h,totalSubitemCount:u}=t,d=s.useMemo(()=>({dispatch:n,getItemState:o,getItemIndex:r,registerHighlightChangeHandler:a,registerSelectionChangeHandler:l}),[n,r,o,a,l]),c=s.useMemo(()=>({getItemIndex:r,registerItem:h,totalSubitemCount:u}),[h,r,u]);return(0,N.jsx)(_.s.Provider,{value:c,children:(0,N.jsx)(A.Z.Provider,{value:d,children:i})})}var L=i(94780),I=i(50984),w=i(3419),D=i(43614),x=i(74312),M=i(20407),k=i(30220),P=i(26821);function F(e){return(0,P.d6)("MuiSvgIcon",e)}(0,P.sI)("MuiSvgIcon",["root","colorInherit","colorPrimary","colorNeutral","colorDanger","colorSuccess","colorWarning","fontSizeInherit","fontSizeXs","fontSizeSm","fontSizeMd","fontSizeLg","fontSizeXl","fontSizeXl2","fontSizeXl3","fontSizeXl4","sizeSm","sizeMd","sizeLg"]);let B=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox","size","slots","slotProps"],U=e=>{let{color:t,size:i,fontSize:n}=e,r={root:["root",t&&"inherit"!==t&&`color${(0,l.Z)(t)}`,i&&`size${(0,l.Z)(i)}`,n&&`fontSize${(0,l.Z)(n)}`]};return(0,L.Z)(r,F,{})},H={sm:"xl",md:"xl2",lg:"xl3"},V=(0,x.Z)("svg",{name:"JoySvgIcon",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e,ownerState:t})=>{var i;return(0,o.Z)({},t.instanceSize&&{"--Icon-fontSize":e.vars.fontSize[H[t.instanceSize]]},t.instanceFontSize&&"inherit"!==t.instanceFontSize&&{"--Icon-fontSize":e.vars.fontSize[t.instanceFontSize]},{userSelect:"none",margin:"var(--Icon-margin)",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,fontSize:`var(--Icon-fontSize, ${e.vars.fontSize[H[t.size]]||"unset"})`},t.fontSize&&"inherit"!==t.fontSize&&{fontSize:`var(--Icon-fontSize, ${e.fontSize[t.fontSize]})`},!t.htmlColor&&(0,o.Z)({color:`var(--Icon-color, ${e.vars.palette.text.icon})`},"inherit"===t.color&&{color:"inherit"},"inherit"!==t.color&&"context"!==t.color&&e.vars.palette[t.color]&&{color:`rgba(${null==(i=e.vars.palette[t.color])?void 0:i.mainChannel} / 1)`}))}),W=s.forwardRef(function(e,t){let i=(0,M.Z)({props:e,name:"JoySvgIcon"}),{children:n,className:l,color:h,component:u="svg",fontSize:d,htmlColor:c,inheritViewBox:f=!1,titleAccess:g,viewBox:p="0 0 24 24",size:m="md",slots:_={},slotProps:E={}}=i,v=(0,r.Z)(i,B),b=s.isValidElement(n)&&"svg"===n.type,C=(0,o.Z)({},i,{color:h,component:u,size:m,instanceSize:e.size,fontSize:d,instanceFontSize:e.fontSize,inheritViewBox:f,viewBox:p,hasSvgAsChild:b}),S=U(C),y=(0,o.Z)({},v,{component:u,slots:_,slotProps:E}),[T,R]=(0,k.Z)("root",{ref:t,className:(0,a.Z)(S.root,l),elementType:V,externalForwardedProps:y,ownerState:C,additionalProps:(0,o.Z)({color:c,focusable:!1},g&&{role:"img"},!g&&{"aria-hidden":!0},!f&&{viewBox:p},b&&n.props)});return(0,N.jsxs)(T,(0,o.Z)({},R,{children:[b?n.props.children:n,g?(0,N.jsx)("title",{children:g}):null]}))});var G=function(e,t){function i(i,n){return(0,N.jsx)(W,(0,o.Z)({"data-testid":`${t}Icon`,ref:n},i,{children:e}))}return i.muiName=W.muiName,s.memo(s.forwardRef(i))}((0,N.jsx)("path",{d:"m12 5.83 2.46 2.46c.39.39 1.02.39 1.41 0 .39-.39.39-1.02 0-1.41L12.7 3.7a.9959.9959 0 0 0-1.41 0L8.12 6.88c-.39.39-.39 1.02 0 1.41.39.39 1.02.39 1.41 0L12 5.83zm0 12.34-2.46-2.46a.9959.9959 0 0 0-1.41 0c-.39.39-.39 1.02 0 1.41l3.17 3.18c.39.39 1.02.39 1.41 0l3.17-3.17c.39-.39.39-1.02 0-1.41a.9959.9959 0 0 0-1.41 0L12 18.17z"}),"Unfold"),j=i(78653),z=i(58859);function K(e){return(0,P.d6)("MuiSelect",e)}let Y=(0,P.sI)("MuiSelect",["root","button","indicator","startDecorator","endDecorator","popper","listbox","colorPrimary","colorNeutral","colorDanger","colorSuccess","colorWarning","colorContext","variantPlain","variantOutlined","variantSoft","variantSolid","sizeSm","sizeMd","sizeLg","focusVisible","disabled","expanded"]);var $=i(76043),q=i(55907);let X=["action","autoFocus","children","defaultValue","defaultListboxOpen","disabled","getSerializedValue","placeholder","listboxId","listboxOpen","onChange","onListboxOpenChange","onClose","renderValue","required","value","size","variant","color","startDecorator","endDecorator","indicator","aria-describedby","aria-label","aria-labelledby","id","name","slots","slotProps"];function Z(e){var t;return null!=(t=null==e?void 0:e.label)?t:""}let Q=[{name:"offset",options:{offset:[0,4]}},{name:"equalWidth",enabled:!0,phase:"beforeWrite",requires:["computeStyles"],fn:({state:e})=>{e.styles.popper.width=`${e.rects.reference.width}px`}}],J=e=>{let{color:t,disabled:i,focusVisible:n,size:r,variant:o,open:s}=e,a={root:["root",i&&"disabled",n&&"focusVisible",s&&"expanded",o&&`variant${(0,l.Z)(o)}`,t&&`color${(0,l.Z)(t)}`,r&&`size${(0,l.Z)(r)}`],button:["button"],startDecorator:["startDecorator"],endDecorator:["endDecorator"],indicator:["indicator",s&&"expanded"],listbox:["listbox",s&&"expanded",i&&"disabled"]};return(0,L.Z)(a,K,{})},ee=(0,x.Z)("div",{name:"JoySelect",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e,ownerState:t})=>{var i,n,r,s;let a=null==(i=e.variants[`${t.variant}`])?void 0:i[t.color],{borderRadius:l}=(0,z.V)({theme:e,ownerState:t},["borderRadius"]);return[(0,o.Z)({"--Select-radius":e.vars.radius.sm,"--Select-gap":"0.5rem","--Select-placeholderOpacity":.64,"--Select-decoratorColor":e.vars.palette.text.icon,"--Select-focusedThickness":e.vars.focus.thickness},"context"===t.color?{"--Select-focusedHighlight":e.vars.palette.focusVisible}:{"--Select-focusedHighlight":null==(n=e.vars.palette["neutral"===t.color?"primary":t.color])?void 0:n[500]},{"--Select-indicatorColor":null!=a&&a.backgroundColor?null==a?void 0:a.color:e.vars.palette.text.tertiary},"sm"===t.size&&{"--Select-minHeight":"2rem","--Select-paddingInline":"0.5rem","--Select-decoratorChildHeight":"min(1.5rem, var(--Select-minHeight))","--Icon-fontSize":e.vars.fontSize.xl},"md"===t.size&&{"--Select-minHeight":"2.5rem","--Select-paddingInline":"0.75rem","--Select-decoratorChildHeight":"min(2rem, var(--Select-minHeight))","--Icon-fontSize":e.vars.fontSize.xl2},"lg"===t.size&&{"--Select-minHeight":"3rem","--Select-paddingInline":"1rem","--Select-decoratorChildHeight":"min(2.375rem, var(--Select-minHeight))","--Icon-fontSize":e.vars.fontSize.xl2},{"--Select-decoratorChildOffset":"min(calc(var(--Select-paddingInline) - (var(--Select-minHeight) - 2 * var(--variant-borderWidth, 0px) - var(--Select-decoratorChildHeight)) / 2), var(--Select-paddingInline))","--_Select-paddingBlock":"max((var(--Select-minHeight) - 2 * var(--variant-borderWidth, 0px) - var(--Select-decoratorChildHeight)) / 2, 0px)","--Select-decoratorChildRadius":"max(var(--Select-radius) - var(--variant-borderWidth, 0px) - var(--_Select-paddingBlock), min(var(--_Select-paddingBlock) + var(--variant-borderWidth, 0px), var(--Select-radius) / 2))","--Button-minHeight":"var(--Select-decoratorChildHeight)","--IconButton-size":"var(--Select-decoratorChildHeight)","--Button-radius":"var(--Select-decoratorChildRadius)","--IconButton-radius":"var(--Select-decoratorChildRadius)",boxSizing:"border-box"},"plain"!==t.variant&&{boxShadow:e.shadow.xs},{minWidth:0,minHeight:"var(--Select-minHeight)",position:"relative",display:"flex",alignItems:"center",borderRadius:"var(--Select-radius)",cursor:"pointer"},!(null!=a&&a.backgroundColor)&&{backgroundColor:e.vars.palette.background.surface},t.size&&{paddingBlock:({sm:2,md:3,lg:4})[t.size]},{paddingInline:"var(--Select-paddingInline)"},e.typography[`body-${t.size}`],a,{"&::before":{boxSizing:"border-box",content:'""',display:"block",position:"absolute",pointerEvents:"none",top:0,left:0,right:0,bottom:0,zIndex:1,borderRadius:"inherit",margin:"calc(var(--variant-borderWidth, 0px) * -1)"},[`&.${Y.focusVisible}`]:{"--Select-indicatorColor":null==a?void 0:a.color,"&::before":{boxShadow:"inset 0 0 0 var(--Select-focusedThickness) var(--Select-focusedHighlight)"}},[`&.${Y.disabled}`]:{"--Select-indicatorColor":"inherit"}}),{"&:hover":null==(r=e.variants[`${t.variant}Hover`])?void 0:r[t.color],[`&.${Y.disabled}`]:null==(s=e.variants[`${t.variant}Disabled`])?void 0:s[t.color]},void 0!==l&&{"--Select-radius":l}]}),et=(0,x.Z)("button",{name:"JoySelect",slot:"Button",overridesResolver:(e,t)=>t.button})(({ownerState:e})=>(0,o.Z)({border:0,outline:0,background:"none",padding:0,fontSize:"inherit",color:"inherit",alignSelf:"stretch",display:"flex",alignItems:"center",flex:1,fontFamily:"inherit",cursor:"pointer",whiteSpace:"nowrap",overflow:"hidden"},(null===e.value||void 0===e.value)&&{opacity:"var(--Select-placeholderOpacity)"},{"&::before":{content:'""',display:"block",position:"absolute",top:"calc(-1 * var(--variant-borderWidth, 0px))",left:"calc(-1 * var(--variant-borderWidth, 0px))",right:"calc(-1 * var(--variant-borderWidth, 0px))",bottom:"calc(-1 * var(--variant-borderWidth, 0px))",borderRadius:"var(--Select-radius)"}})),ei=(0,x.Z)(I.C,{name:"JoySelect",slot:"Listbox",overridesResolver:(e,t)=>t.listbox})(({theme:e,ownerState:t})=>{var i;let n="context"===t.color?void 0:null==(i=e.variants[t.variant])?void 0:i[t.color];return(0,o.Z)({"--focus-outline-offset":`calc(${e.vars.focus.thickness} * -1)`,"--ListItem-stickyBackground":(null==n?void 0:n.backgroundColor)||(null==n?void 0:n.background)||e.vars.palette.background.popup,"--ListItem-stickyTop":"calc(var(--List-padding, var(--ListDivider-gap)) * -1)"},w.M,{minWidth:"max-content",maxHeight:"44vh",overflow:"auto",outline:0,boxShadow:e.shadow.md,borderRadius:`var(--List-radius, ${e.vars.radius.sm})`,zIndex:`var(--unstable_popup-zIndex, ${e.vars.zIndex.popup})`},!(null!=n&&n.backgroundColor)&&{backgroundColor:e.vars.palette.background.popup})}),en=(0,x.Z)("span",{name:"JoySelect",slot:"StartDecorator",overridesResolver:(e,t)=>t.startDecorator})({"--Button-margin":"0 0 0 calc(var(--Select-decoratorChildOffset) * -1)","--IconButton-margin":"0 0 0 calc(var(--Select-decoratorChildOffset) * -1)","--Icon-margin":"0 0 0 calc(var(--Select-paddingInline) / -4)",display:"inherit",alignItems:"center",color:"var(--Select-decoratorColor)",marginInlineEnd:"var(--Select-gap)"}),er=(0,x.Z)("span",{name:"JoySelect",slot:"EndDecorator",overridesResolver:(e,t)=>t.endDecorator})({"--Button-margin":"0 calc(var(--Select-decoratorChildOffset) * -1) 0 0","--IconButton-margin":"0 calc(var(--Select-decoratorChildOffset) * -1) 0 0","--Icon-margin":"0 calc(var(--Select-paddingInline) / -4) 0 0",display:"inherit",alignItems:"center",color:"var(--Select-decoratorColor)",marginInlineStart:"var(--Select-gap)"}),eo=(0,x.Z)("span",{name:"JoySelect",slot:"Indicator"})(({ownerState:e,theme:t})=>(0,o.Z)({},"sm"===e.size&&{"--Icon-fontSize":t.vars.fontSize.lg},"md"===e.size&&{"--Icon-fontSize":t.vars.fontSize.xl},"lg"===e.size&&{"--Icon-fontSize":t.vars.fontSize.xl2},{"--Icon-color":"neutral"!==e.color||"solid"===e.variant?"currentColor":t.vars.palette.text.icon,display:"inherit",alignItems:"center",marginInlineStart:"var(--Select-gap)",marginInlineEnd:"calc(var(--Select-paddingInline) / -4)",[`.${Y.endDecorator} + &`]:{marginInlineStart:"calc(var(--Select-gap) / 2)"},[`&.${Y.expanded}, .${Y.disabled} > &`]:{"--Icon-color":"currentColor"}})),es=s.forwardRef(function(e,t){var i,l,E,v,A,L,I;let x=(0,M.Z)({props:e,name:"JoySelect"}),{action:P,autoFocus:F,children:B,defaultValue:U,defaultListboxOpen:H=!1,disabled:V,getSerializedValue:W,placeholder:z,listboxId:K,listboxOpen:es,onChange:ea,onListboxOpenChange:el,onClose:eh,renderValue:eu,required:ed=!1,value:ec,size:ef="md",variant:eg="outlined",color:ep="neutral",startDecorator:em,endDecorator:e_,indicator:eE=n||(n=(0,N.jsx)(G,{})),"aria-describedby":ev,"aria-label":eb,"aria-labelledby":eC,id:eS,name:ey,slots:eT={},slotProps:eR={}}=x,eA=(0,r.Z)(x,X),eN=s.useContext($.Z),eO=null!=(i=null!=(l=e.disabled)?l:null==eN?void 0:eN.disabled)?i:V,eL=null!=(E=null!=(v=e.size)?v:null==eN?void 0:eN.size)?E:ef,{getColor:eI}=(0,j.VT)(eg),ew=eI(e.color,null!=eN&&eN.error?"danger":null!=(A=null==eN?void 0:eN.color)?A:ep),eD=null!=eu?eu:Z,[ex,eM]=s.useState(null),ek=s.useRef(null),eP=s.useRef(null),eF=s.useRef(null),eB=(0,h.Z)(t,ek);s.useImperativeHandle(P,()=>({focusVisible:()=>{var e;null==(e=eP.current)||e.focus()}}),[]),s.useEffect(()=>{eM(ek.current)},[]),s.useEffect(()=>{F&&eP.current.focus()},[F]);let eU=s.useCallback(e=>{null==el||el(e),e||null==eh||eh()},[eh,el]),{buttonActive:eH,buttonFocusVisible:eV,contextValue:eW,disabled:eG,getButtonProps:ej,getListboxProps:ez,getHiddenInputProps:eK,getOptionMetadata:eY,open:e$,value:eq}=function(e){let t,i,n;let{areOptionsEqual:r,buttonRef:a,defaultOpen:l=!1,defaultValue:u,disabled:E=!1,listboxId:v,listboxRef:A,multiple:N=!1,name:O,required:L,onChange:I,onHighlightChange:w,onOpenChange:D,open:x,options:M,getOptionAsString:k=m,getSerializedValue:P=T,value:F}=e,B=s.useRef(null),U=(0,h.Z)(a,B),H=s.useRef(null),V=(0,d.Z)(v);void 0===F&&void 0===u?t=[]:void 0!==u&&(t=N?u:null==u?[]:[u]);let W=s.useMemo(()=>{if(void 0!==F)return N?F:null==F?[]:[F]},[F,N]),{subitems:G,contextValue:j}=(0,_.Y)(),z=s.useMemo(()=>null!=M?new Map(M.map((e,t)=>[e.value,{value:e.value,label:e.label,disabled:e.disabled,ref:s.createRef(),id:`${V}_${t}`}])):G,[M,G,V]),K=(0,h.Z)(A,H),{getRootProps:Y,active:$,focusVisible:q,rootRef:X}=(0,f.U)({disabled:E,rootRef:U}),Z=s.useMemo(()=>Array.from(z.keys()),[z]),Q=s.useCallback(e=>{if(void 0!==r){let t=Z.find(t=>r(t,e));return z.get(t)}return z.get(e)},[z,r,Z]),J=s.useCallback(e=>{var t;let i=Q(e);return null!=(t=null==i?void 0:i.disabled)&&t},[Q]),ee=s.useCallback(e=>{let t=Q(e);return t?k(t):""},[Q,k]),et=s.useMemo(()=>({selectedValues:W,open:x}),[W,x]),ei=s.useCallback(e=>{var t;return null==(t=z.get(e))?void 0:t.id},[z]),en=s.useCallback((e,t)=>{if(N)null==I||I(e,t);else{var i;null==I||I(e,null!=(i=t[0])?i:null)}},[N,I]),er=s.useCallback((e,t)=>{null==w||w(e,null!=t?t:null)},[w]),eo=s.useCallback((e,t,i)=>{if("open"===t&&(null==D||D(i),!1===i&&(null==e?void 0:e.type)!=="blur")){var n;null==(n=B.current)||n.focus()}},[D]),es={getInitialState:()=>{var e;return{highlightedValue:null,selectedValues:null!=(e=t)?e:[],open:l}},getItemId:ei,controlledProps:et,itemComparer:r,isItemDisabled:J,rootRef:X,onChange:en,onHighlightChange:er,onStateChange:eo,reducerActionContext:s.useMemo(()=>({multiple:N}),[N]),items:Z,getItemAsString:ee,selectionMode:N?"multiple":"single",stateReducer:b},{dispatch:ea,getRootProps:el,contextValue:eh,state:{open:eu,highlightedValue:ed,selectedValues:ec},rootRef:ef}=(0,p.s)(es),eg=e=>t=>{var i;if(null==e||null==(i=e.onMouseDown)||i.call(e,t),!t.defaultMuiPrevented){let e={type:g.buttonClick,event:t};ea(e)}};(0,c.Z)(()=>{if(null!=ed){var e;let t=null==(e=Q(ed))?void 0:e.ref;if(!H.current||!(null!=t&&t.current))return;let i=H.current.getBoundingClientRect(),n=t.current.getBoundingClientRect();n.topi.bottom&&(H.current.scrollTop+=n.bottom-i.bottom)}},[ed,Q]);let ep=s.useCallback(e=>Q(e),[Q]),em=(e={})=>(0,o.Z)({},e,{onMouseDown:eg(e),ref:ef,role:"combobox","aria-expanded":eu,"aria-controls":V});s.useDebugValue({selectedOptions:ec,highlightedOption:ed,open:eu});let e_=s.useMemo(()=>(0,o.Z)({},eh,j),[eh,j]);if(i=e.multiple?ec:ec.length>0?ec[0]:null,N)n=i.map(e=>ep(e)).filter(e=>void 0!==e);else{var eE;n=null!=(eE=ep(i))?eE:null}return{buttonActive:$,buttonFocusVisible:q,buttonRef:X,contextValue:e_,disabled:E,dispatch:ea,getButtonProps:(e={})=>{let t=(0,C.f)(Y,el),i=(0,C.f)(t,em);return i(e)},getHiddenInputProps:(e={})=>(0,o.Z)({name:O,tabIndex:-1,"aria-hidden":!0,required:!!L||void 0,value:P(n),onChange:y,style:S},e),getListboxProps:(e={})=>(0,o.Z)({},e,{id:V,role:"listbox","aria-multiselectable":N?"true":void 0,ref:K,onMouseDown:R}),getOptionMetadata:ep,listboxRef:ef,open:eu,options:Z,value:i,highlightedOption:ed}}({buttonRef:eP,defaultOpen:H,defaultValue:U,disabled:eO,getSerializedValue:W,listboxId:K,multiple:!1,name:ey,required:ed,onChange:ea,onOpenChange:eU,open:es,value:ec}),eX=(0,o.Z)({},x,{active:eH,defaultListboxOpen:H,disabled:eG,focusVisible:eV,open:e$,renderValue:eD,value:eq,size:eL,variant:eg,color:ew}),eZ=J(eX),eQ=(0,o.Z)({},eA,{slots:eT,slotProps:eR}),eJ=s.useMemo(()=>{var e;return null!=(e=eY(eq))?e:null},[eY,eq]),[e0,e1]=(0,k.Z)("root",{ref:eB,className:eZ.root,elementType:ee,externalForwardedProps:eQ,ownerState:eX}),[e2,e5]=(0,k.Z)("button",{additionalProps:{"aria-describedby":null!=ev?ev:null==eN?void 0:eN["aria-describedby"],"aria-label":eb,"aria-labelledby":null!=eC?eC:null==eN?void 0:eN.labelId,"aria-required":ed?"true":void 0,id:null!=eS?eS:null==eN?void 0:eN.htmlFor,name:ey},className:eZ.button,elementType:et,externalForwardedProps:eQ,getSlotProps:ej,ownerState:eX}),[e4,e3]=(0,k.Z)("listbox",{additionalProps:{ref:eF,anchorEl:ex,open:e$,placement:"bottom",keepMounted:!0},className:eZ.listbox,elementType:ei,externalForwardedProps:eQ,getSlotProps:ez,ownerState:(0,o.Z)({},eX,{nesting:!1,row:!1,wrap:!1}),getSlotOwnerState:e=>({size:e.size||eL,variant:e.variant||eg,color:e.color||(e.disablePortal?ew:ep),disableColorInversion:!e.disablePortal})}),[e6,e9]=(0,k.Z)("startDecorator",{className:eZ.startDecorator,elementType:en,externalForwardedProps:eQ,ownerState:eX}),[e8,e7]=(0,k.Z)("endDecorator",{className:eZ.endDecorator,elementType:er,externalForwardedProps:eQ,ownerState:eX}),[te,tt]=(0,k.Z)("indicator",{className:eZ.indicator,elementType:eo,externalForwardedProps:eQ,ownerState:eX}),ti=s.useMemo(()=>[...Q,...e3.modifiers||[]],[e3.modifiers]),tn=null;return ex&&(tn=(0,N.jsx)(e4,(0,o.Z)({},e3,{className:(0,a.Z)(e3.className,(null==(L=e3.ownerState)?void 0:L.color)==="context"&&Y.colorContext),modifiers:ti},!(null!=(I=x.slots)&&I.listbox)&&{as:u.r,slots:{root:e3.as||"ul"}},{children:(0,N.jsx)(O,{value:eW,children:(0,N.jsx)(q.Yb,{variant:eg,color:ep,children:(0,N.jsx)(D.Z.Provider,{value:"select",children:(0,N.jsx)(w.Z,{nested:!0,children:B})})})})})),e3.disablePortal||(tn=(0,N.jsx)(j.ZP.Provider,{value:void 0,children:tn}))),(0,N.jsxs)(s.Fragment,{children:[(0,N.jsxs)(e0,(0,o.Z)({},e1,{children:[em&&(0,N.jsx)(e6,(0,o.Z)({},e9,{children:em})),(0,N.jsx)(e2,(0,o.Z)({},e5,{children:eJ?eD(eJ):z})),e_&&(0,N.jsx)(e8,(0,o.Z)({},e7,{children:e_})),eE&&(0,N.jsx)(te,(0,o.Z)({},tt,{children:eE})),(0,N.jsx)("input",(0,o.Z)({},eK()))]})),tn]})});var ea=es},61685:function(e,t,i){"use strict";i.d(t,{Z:function(){return S}});var n=i(63366),r=i(87462),o=i(67294),s=i(90512),a=i(14142),l=i(94780),h=i(20407),u=i(78653),d=i(74312),c=i(26821);function f(e){return(0,c.d6)("MuiTable",e)}(0,c.sI)("MuiTable",["root","colorPrimary","colorNeutral","colorDanger","colorSuccess","colorWarning","colorContext","variantPlain","variantOutlined","variantSoft","variantSolid","sizeSm","sizeMd","sizeLg","stickyHeader","stickyFooter","noWrap","hoverRow","borderAxisNone","borderAxisX","borderAxisXBetween","borderAxisY","borderAxisYBetween","borderAxisBoth","borderAxisBothBetween"]);var g=i(40911),p=i(30220),m=i(85893);let _=["className","component","children","borderAxis","hoverRow","noWrap","size","variant","color","stripe","stickyHeader","stickyFooter","slots","slotProps"],E=e=>{let{size:t,variant:i,color:n,borderAxis:r,stickyHeader:o,stickyFooter:s,noWrap:h,hoverRow:u}=e,d={root:["root",o&&"stickyHeader",s&&"stickyFooter",h&&"noWrap",u&&"hoverRow",r&&`borderAxis${(0,a.Z)(r)}`,i&&`variant${(0,a.Z)(i)}`,n&&`color${(0,a.Z)(n)}`,t&&`size${(0,a.Z)(t)}`]};return(0,l.Z)(d,f,{})},v={getColumnExceptFirst:()=>"& tr > *:not(:first-of-type), & tr > th + td, & tr > td + th",getCell:()=>"& th, & td",getHeadCell:()=>"& th",getHeaderCell:()=>"& thead th",getHeaderCellOfRow:e=>`& thead tr:nth-of-type(${e}) th`,getBottomHeaderCell:()=>"& thead th:not([colspan])",getHeaderNestedFirstColumn:()=>"& thead tr:not(:first-of-type) th:not([colspan]):first-of-type",getDataCell:()=>"& td",getDataCellExceptLastRow:()=>"& tr:not(:last-of-type) > td",getBodyCellExceptLastRow(){return`${this.getDataCellExceptLastRow()}, & tr:not(:last-of-type) > th[scope="row"]`},getBodyCellOfRow:e=>"number"==typeof e&&e<0?`& tbody tr:nth-last-of-type(${Math.abs(e)}) td, & tbody tr:nth-last-of-type(${Math.abs(e)}) th[scope="row"]`:`& tbody tr:nth-of-type(${e}) td, & tbody tr:nth-of-type(${e}) th[scope="row"]`,getBodyRow:e=>void 0===e?"& tbody tr":`& tbody tr:nth-of-type(${e})`,getFooterCell:()=>"& tfoot th, & tfoot td",getFooterFirstRowCell:()=>"& tfoot tr:not(:last-of-type) th, & tfoot tr:not(:last-of-type) td"},b=(0,d.Z)("table",{name:"JoyTable",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e,ownerState:t})=>{var i,n,o,s,a,l,h;let u=null==(i=e.variants[t.variant])?void 0:i[t.color];return[(0,r.Z)({"--Table-headerUnderlineThickness":"2px","--TableCell-borderColor":null!=(n=null==u?void 0:u.borderColor)?n:e.vars.palette.divider,"--TableCell-headBackground":`var(--Sheet-background, ${e.vars.palette.background.surface})`},"sm"===t.size&&{"--unstable_TableCell-height":"var(--TableCell-height, 32px)","--TableCell-paddingX":"0.25rem","--TableCell-paddingY":"0.25rem"},"md"===t.size&&{"--unstable_TableCell-height":"var(--TableCell-height, 40px)","--TableCell-paddingX":"0.5rem","--TableCell-paddingY":"0.375rem"},"lg"===t.size&&{"--unstable_TableCell-height":"var(--TableCell-height, 48px)","--TableCell-paddingX":"0.75rem","--TableCell-paddingY":"0.5rem"},{tableLayout:"fixed",width:"100%",borderSpacing:"0px",borderCollapse:"separate",borderRadius:"var(--TableCell-cornerRadius, var(--unstable_actionRadius))"},e.typography[`body-${({sm:"xs",md:"sm",lg:"md"})[t.size]}`],null==(o=e.variants[t.variant])?void 0:o[t.color],{"& caption":{color:e.vars.palette.text.tertiary,padding:"calc(2 * var(--TableCell-paddingY)) var(--TableCell-paddingX)"},[v.getDataCell()]:(0,r.Z)({padding:"var(--TableCell-paddingY) var(--TableCell-paddingX)",height:"var(--unstable_TableCell-height)",borderColor:"var(--TableCell-borderColor)",backgroundColor:"var(--TableCell-dataBackground)"},t.noWrap&&{textOverflow:"ellipsis",whiteSpace:"nowrap",overflow:"hidden"}),[v.getHeadCell()]:{textAlign:"left",padding:"var(--TableCell-paddingY) var(--TableCell-paddingX)",backgroundColor:"var(--TableCell-headBackground)",height:"var(--unstable_TableCell-height)",fontWeight:e.vars.fontWeight.lg,borderColor:"var(--TableCell-borderColor)",color:e.vars.palette.text.secondary,textOverflow:"ellipsis",whiteSpace:"nowrap",overflow:"hidden"},[v.getHeaderCell()]:{verticalAlign:"bottom","&:first-of-type":{borderTopLeftRadius:"var(--TableCell-cornerRadius, var(--unstable_actionRadius))"},"&:last-of-type":{borderTopRightRadius:"var(--TableCell-cornerRadius, var(--unstable_actionRadius))"}},"& tfoot tr > *":{backgroundColor:`var(--TableCell-footBackground, ${e.vars.palette.background.level1})`,"&:first-of-type":{borderBottomLeftRadius:"var(--TableCell-cornerRadius, var(--unstable_actionRadius))"},"&:last-of-type":{borderBottomRightRadius:"var(--TableCell-cornerRadius, var(--unstable_actionRadius))"}}}),((null==(s=t.borderAxis)?void 0:s.startsWith("x"))||(null==(a=t.borderAxis)?void 0:a.startsWith("both")))&&{[v.getHeaderCell()]:{borderBottomWidth:1,borderBottomStyle:"solid"},[v.getBottomHeaderCell()]:{borderBottomWidth:"var(--Table-headerUnderlineThickness)",borderBottomStyle:"solid"},[v.getBodyCellExceptLastRow()]:{borderBottomWidth:1,borderBottomStyle:"solid"},[v.getFooterCell()]:{borderTopWidth:1,borderTopStyle:"solid"}},((null==(l=t.borderAxis)?void 0:l.startsWith("y"))||(null==(h=t.borderAxis)?void 0:h.startsWith("both")))&&{[`${v.getColumnExceptFirst()}, ${v.getHeaderNestedFirstColumn()}`]:{borderLeftWidth:1,borderLeftStyle:"solid"}},("x"===t.borderAxis||"both"===t.borderAxis)&&{[v.getHeaderCellOfRow(1)]:{borderTopWidth:1,borderTopStyle:"solid"},[v.getBodyCellOfRow(-1)]:{borderBottomWidth:1,borderBottomStyle:"solid"},[v.getFooterCell()]:{borderBottomWidth:1,borderBottomStyle:"solid"}},("y"===t.borderAxis||"both"===t.borderAxis)&&{"& tr > *:first-of-type":{borderLeftWidth:1,borderLeftStyle:"solid"},"& tr > *:last-of-type:not(:first-of-type)":{borderRightWidth:1,borderRightStyle:"solid"}},t.stripe&&{[v.getBodyRow(t.stripe)]:{background:`var(--TableRow-stripeBackground, ${e.vars.palette.background.level2})`,color:e.vars.palette.text.primary}},t.hoverRow&&{[v.getBodyRow()]:{"&:hover":{background:`var(--TableRow-hoverBackground, ${e.vars.palette.background.level3})`}}},t.stickyHeader&&{[v.getHeaderCell()]:{position:"sticky",top:0,zIndex:e.vars.zIndex.table},[v.getHeaderCellOfRow(2)]:{top:"var(--unstable_TableCell-height)"}},t.stickyFooter&&{[v.getFooterCell()]:{position:"sticky",bottom:0,zIndex:e.vars.zIndex.table,color:e.vars.palette.text.secondary,fontWeight:e.vars.fontWeight.lg},[v.getFooterFirstRowCell()]:{bottom:"var(--unstable_TableCell-height)"}}]}),C=o.forwardRef(function(e,t){let i=(0,h.Z)({props:e,name:"JoyTable"}),{className:o,component:a,children:l,borderAxis:d="xBetween",hoverRow:c=!1,noWrap:f=!1,size:v="md",variant:C="plain",color:S="neutral",stripe:y,stickyHeader:T=!1,stickyFooter:R=!1,slots:A={},slotProps:N={}}=i,O=(0,n.Z)(i,_),{getColor:L}=(0,u.VT)(C),I=L(e.color,S),w=(0,r.Z)({},i,{borderAxis:d,hoverRow:c,noWrap:f,component:a,size:v,color:I,variant:C,stripe:y,stickyHeader:T,stickyFooter:R}),D=E(w),x=(0,r.Z)({},O,{component:a,slots:A,slotProps:N}),[M,k]=(0,p.Z)("root",{ref:t,className:(0,s.Z)(D.root,o),elementType:b,externalForwardedProps:x,ownerState:w});return(0,m.jsx)(g.eu.Provider,{value:!0,children:(0,m.jsx)(M,(0,r.Z)({},k,{children:l}))})});var S=C},40911:function(e,t,i){"use strict";i.d(t,{eu:function(){return b},ZP:function(){return N}});var n=i(63366),r=i(87462),o=i(67294),s=i(14142),a=i(18719),l=i(39707),h=i(94780),u=i(74312),d=i(20407),c=i(78653),f=i(30220),g=i(26821);function p(e){return(0,g.d6)("MuiTypography",e)}(0,g.sI)("MuiTypography",["root","h1","h2","h3","h4","title-lg","title-md","title-sm","body-lg","body-md","body-sm","body-xs","noWrap","gutterBottom","startDecorator","endDecorator","colorPrimary","colorNeutral","colorDanger","colorSuccess","colorWarning","colorContext","variantPlain","variantOutlined","variantSoft","variantSolid"]);var m=i(85893);let _=["color","textColor"],E=["component","gutterBottom","noWrap","level","levelMapping","children","endDecorator","startDecorator","variant","slots","slotProps"],v=o.createContext(!1),b=o.createContext(!1),C=e=>{let{gutterBottom:t,noWrap:i,level:n,color:r,variant:o}=e,a={root:["root",n,t&&"gutterBottom",i&&"noWrap",r&&`color${(0,s.Z)(r)}`,o&&`variant${(0,s.Z)(o)}`],startDecorator:["startDecorator"],endDecorator:["endDecorator"]};return(0,h.Z)(a,p,{})},S=(0,u.Z)("span",{name:"JoyTypography",slot:"StartDecorator",overridesResolver:(e,t)=>t.startDecorator})({display:"inline-flex",marginInlineEnd:"clamp(4px, var(--Typography-gap, 0.375em), 0.75rem)"}),y=(0,u.Z)("span",{name:"JoyTypography",slot:"endDecorator",overridesResolver:(e,t)=>t.endDecorator})({display:"inline-flex",marginInlineStart:"clamp(4px, var(--Typography-gap, 0.375em), 0.75rem)"}),T=(0,u.Z)("span",{name:"JoyTypography",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e,ownerState:t})=>{var i,n,o,s,a;let l="inherit"!==t.level?null==(i=e.typography[t.level])?void 0:i.lineHeight:"1";return(0,r.Z)({"--Icon-fontSize":`calc(1em * ${l})`},t.color&&{"--Icon-color":"currentColor"},{margin:"var(--Typography-margin, 0px)"},t.nesting?{display:"inline"}:(0,r.Z)({display:"block"},t.unstable_hasSkeleton&&{position:"relative"}),(t.startDecorator||t.endDecorator)&&(0,r.Z)({display:"flex",alignItems:"center"},t.nesting&&(0,r.Z)({display:"inline-flex"},t.startDecorator&&{verticalAlign:"bottom"})),t.level&&"inherit"!==t.level&&e.typography[t.level],{fontSize:`var(--Typography-fontSize, ${t.level&&"inherit"!==t.level&&null!=(n=null==(o=e.typography[t.level])?void 0:o.fontSize)?n:"inherit"})`},t.noWrap&&{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},t.gutterBottom&&{marginBottom:"0.35em"},t.color&&"context"!==t.color&&{color:`rgba(${null==(s=e.vars.palette[t.color])?void 0:s.mainChannel} / 1)`},t.variant&&(0,r.Z)({borderRadius:e.vars.radius.xs,paddingBlock:"min(0.1em, 4px)",paddingInline:"0.25em"},!t.nesting&&{marginInline:"-0.25em"},null==(a=e.variants[t.variant])?void 0:a[t.color]))}),R={h1:"h1",h2:"h2",h3:"h3",h4:"h4","title-lg":"p","title-md":"p","title-sm":"p","body-lg":"p","body-md":"p","body-sm":"p","body-xs":"span",inherit:"p"},A=o.forwardRef(function(e,t){let i=(0,d.Z)({props:e,name:"JoyTypography"}),{color:s,textColor:h}=i,u=(0,n.Z)(i,_),g=o.useContext(v),p=o.useContext(b),A=(0,l.Z)((0,r.Z)({},u,{color:h})),{component:N,gutterBottom:O=!1,noWrap:L=!1,level:I="body-md",levelMapping:w=R,children:D,endDecorator:x,startDecorator:M,variant:k,slots:P={},slotProps:F={}}=A,B=(0,n.Z)(A,E),{getColor:U}=(0,c.VT)(k),H=U(e.color,k?null!=s?s:"neutral":s),V=g||p?e.level||"inherit":I,W=(0,a.Z)(D,["Skeleton"]),G=N||(g?"span":w[V]||R[V]||"span"),j=(0,r.Z)({},A,{level:V,component:G,color:H,gutterBottom:O,noWrap:L,nesting:g,variant:k,unstable_hasSkeleton:W}),z=C(j),K=(0,r.Z)({},B,{component:G,slots:P,slotProps:F}),[Y,$]=(0,f.Z)("root",{ref:t,className:z.root,elementType:T,externalForwardedProps:K,ownerState:j}),[q,X]=(0,f.Z)("startDecorator",{className:z.startDecorator,elementType:S,externalForwardedProps:K,ownerState:j}),[Z,Q]=(0,f.Z)("endDecorator",{className:z.endDecorator,elementType:y,externalForwardedProps:K,ownerState:j});return(0,m.jsx)(v.Provider,{value:!0,children:(0,m.jsxs)(Y,(0,r.Z)({},$,{children:[M&&(0,m.jsx)(q,(0,r.Z)({},X,{children:M})),W?o.cloneElement(D,{variant:D.props.variant||"inline"}):D,x&&(0,m.jsx)(Z,(0,r.Z)({},Q,{children:x}))]}))})});A.muiName="Typography";var N=A},78653:function(e,t,i){"use strict";i.d(t,{VT:function(){return l},do:function(){return h}});var n=i(67294),r=i(38629),o=i(1812),s=i(85893);let a=n.createContext(void 0),l=e=>{let t=n.useContext(a);return{getColor:(i,n)=>t&&e&&t.includes(e)?i||"context":i||n}};function h({children:e,variant:t}){var i;let n=(0,r.F)();return(0,s.jsx)(a.Provider,{value:t?(null!=(i=n.colorInversionConfig)?i:o.Z.colorInversionConfig)[t]:void 0,children:e})}t.ZP=a},58859:function(e,t,i){"use strict";i.d(t,{V:function(){return r}});var n=i(87462);let r=({theme:e,ownerState:t},i)=>{let r={};return t.sx&&(function t(i){if("function"==typeof i){let n=i(e);t(n)}else Array.isArray(i)?i.forEach(e=>{"boolean"!=typeof e&&t(e)}):"object"==typeof i&&(r=(0,n.Z)({},r,i))}(t.sx),i.forEach(t=>{let i=r[t];if("string"==typeof i||"number"==typeof i){if("borderRadius"===t){if("number"==typeof i)r[t]=`${i}px`;else{var n;r[t]=(null==(n=e.vars)?void 0:n.radius[i])||i}}else -1!==["p","padding","m","margin"].indexOf(t)&&"number"==typeof i?r[t]=e.spacing(i):r[t]=i}else"function"==typeof i?r[t]=i(e):r[t]=void 0})),r}},74312:function(e,t,i){"use strict";var n=i(70182),r=i(1812),o=i(2548);let s=(0,n.ZP)({defaultTheme:r.Z,themeId:o.Z});t.Z=s},20407:function(e,t,i){"use strict";i.d(t,{Z:function(){return a}});var n=i(87462),r=i(39214),o=i(1812),s=i(2548);function a({props:e,name:t}){return(0,r.Z)({props:e,name:t,defaultTheme:(0,n.Z)({},o.Z,{components:{}}),themeId:s.Z})}},55907:function(e,t,i){"use strict";i.d(t,{Yb:function(){return a},yP:function(){return s}});var n=i(67294),r=i(85893);let o=n.createContext(void 0);function s(e,t){var i;let r,s;let a=n.useContext(o),[l,h]="string"==typeof a?a.split(":"):[],u=(i=l||void 0,r=h||void 0,s=i,"outlined"===i&&(r="neutral",s="plain"),"plain"===i&&(r="neutral"),{variant:s,color:r});return u.variant=e||u.variant,u.color=t||u.color,u}function a({children:e,color:t,variant:i}){return(0,r.jsx)(o.Provider,{value:`${i||""}:${t||""}`,children:e})}},30220:function(e,t,i){"use strict";i.d(t,{Z:function(){return g}});var n=i(87462),r=i(63366),o=i(33703),s=i(71276),a=i(24407),l=i(10238),h=i(78653);let u=["className","elementType","ownerState","externalForwardedProps","getSlotOwnerState","internalForwardedProps"],d=["component","slots","slotProps"],c=["component"],f=["disableColorInversion"];function g(e,t){let{className:i,elementType:g,ownerState:p,externalForwardedProps:m,getSlotOwnerState:_,internalForwardedProps:E}=t,v=(0,r.Z)(t,u),{component:b,slots:C={[e]:void 0},slotProps:S={[e]:void 0}}=m,y=(0,r.Z)(m,d),T=C[e]||g,R=(0,s.x)(S[e],p),A=(0,a.L)((0,n.Z)({className:i},v,{externalForwardedProps:"root"===e?y:void 0,externalSlotProps:R})),{props:{component:N},internalRef:O}=A,L=(0,r.Z)(A.props,c),I=(0,o.Z)(O,null==R?void 0:R.ref,t.ref),w=_?_(L):{},{disableColorInversion:D=!1}=w,x=(0,r.Z)(w,f),M=(0,n.Z)({},p,x),{getColor:k}=(0,h.VT)(M.variant);if("root"===e){var P;M.color=null!=(P=L.color)?P:p.color}else D||(M.color=k(L.color,M.color));let F="root"===e?N||b:N,B=(0,l.$)(T,(0,n.Z)({},"root"===e&&!b&&!C[e]&&E,"root"!==e&&!C[e]&&E,L,F&&{as:F},{ref:I}),M);return Object.keys(x).forEach(e=>{delete B[e]}),[T,B]}},39707:function(e,t,i){"use strict";i.d(t,{Z:function(){return h}});var n=i(87462),r=i(63366),o=i(59766),s=i(44920);let a=["sx"],l=e=>{var t,i;let n={systemProps:{},otherProps:{}},r=null!=(t=null==e||null==(i=e.theme)?void 0:i.unstable_sxConfig)?t:s.Z;return Object.keys(e).forEach(t=>{r[t]?n.systemProps[t]=e[t]:n.otherProps[t]=e[t]}),n};function h(e){let t;let{sx:i}=e,s=(0,r.Z)(e,a),{systemProps:h,otherProps:u}=l(s);return t=Array.isArray(i)?[h,...i]:"function"==typeof i?(...e)=>{let t=i(...e);return(0,o.P)(t)?(0,n.Z)({},h,t):h}:(0,n.Z)({},h,i),(0,n.Z)({},u,{sx:t})}},2093:function(e,t,i){"use strict";var n=i(97582),r=i(67294),o=i(92770);t.Z=function(e,t){(0,r.useEffect)(function(){var t=e(),i=!1;return!function(){(0,n.mG)(this,void 0,void 0,function(){return(0,n.Jh)(this,function(e){switch(e.label){case 0:if(!(0,o.mf)(t[Symbol.asyncIterator]))return[3,4];e.label=1;case 1:return[4,t.next()];case 2:if(e.sent().done||i)return[3,3];return[3,1];case 3:return[3,6];case 4:return[4,t];case 5:e.sent(),e.label=6;case 6:return[2]}})})}(),function(){i=!0}},t)}},15746:function(e,t,i){"use strict";var n=i(21584);t.Z=n.Z},71230:function(e,t,i){"use strict";var n=i(92820);t.Z=n.Z},87760:function(e,t){"use strict";var i={protan:{x:.7465,y:.2535,m:1.273463,yi:-.073894},deutan:{x:1.4,y:-.4,m:.968437,yi:.003331},tritan:{x:.1748,y:0,m:.062921,yi:.292119},custom:{x:.735,y:.265,m:-1.059259,yi:1.026914}},n=function(e){var t={},i=e.R/255,n=e.G/255,r=e.B/255;return i=i>.04045?Math.pow((i+.055)/1.055,2.4):i/12.92,n=n>.04045?Math.pow((n+.055)/1.055,2.4):n/12.92,r=r>.04045?Math.pow((r+.055)/1.055,2.4):r/12.92,t.X=.41242371206635076*i+.3575793401363035*n+.1804662232369621*r,t.Y=.21265606784927693*i+.715157818248362*n+.0721864539171564*r,t.Z=.019331987577444885*i+.11919267420354762*n+.9504491124870351*r,t},r=function(e){var t=e.X+e.Y+e.Z;return 0===t?{x:0,y:0,Y:e.Y}:{x:e.X/t,y:e.Y/t,Y:e.Y}};t.a=function(e,t,o){var s,a,l,h,u,d,c,f,g,p,m,_,E,v,b,C,S,y,T,R;return"achroma"===t?(s={R:s=.212656*e.R+.715158*e.G+.072186*e.B,G:s,B:s},o&&(l=(a=1.75)+1,s.R=(a*s.R+e.R)/l,s.G=(a*s.G+e.G)/l,s.B=(a*s.B+e.B)/l),s):(h=i[t],d=((u=r(n(e))).y-h.y)/(u.x-h.x),c=u.y-u.x*d,f=(h.yi-c)/(d-h.m),g=d*f+c,(s={}).X=f*u.Y/g,s.Y=u.Y,s.Z=(1-(f+g))*u.Y/g,y=.312713*u.Y/.329016,T=.358271*u.Y/.329016,_=3.240712470389558*(p=y-s.X)+-0+-.49857440415943116*(m=T-s.Z),E=-.969259258688888*p+0+.041556132211625726*m,v=.05563600315398933*p+-0+1.0570636917433989*m,s.R=3.240712470389558*s.X+-1.5372626602963142*s.Y+-.49857440415943116*s.Z,s.G=-.969259258688888*s.X+1.875996969313966*s.Y+.041556132211625726*s.Z,s.B=.05563600315398933*s.X+-.2039948802843549*s.Y+1.0570636917433989*s.Z,b=((s.R<0?0:1)-s.R)/_,C=((s.G<0?0:1)-s.G)/E,(S=(S=((s.B<0?0:1)-s.B)/v)>1||S<0?0:S)>(R=(b=b>1||b<0?0:b)>(C=C>1||C<0?0:C)?b:C)&&(R=S),s.R+=R*_,s.G+=R*E,s.B+=R*v,s.R=255*(s.R<=0?0:s.R>=1?1:Math.pow(s.R,.45454545454545453)),s.G=255*(s.G<=0?0:s.G>=1?1:Math.pow(s.G,.45454545454545453)),s.B=255*(s.B<=0?0:s.B>=1?1:Math.pow(s.B,.45454545454545453)),o&&(l=(a=1.75)+1,s.R=(a*s.R+e.R)/l,s.G=(a*s.G+e.G)/l,s.B=(a*s.B+e.B)/l),s)}},56917:function(e,t,i){"use strict";var n=i(74314),r=i(87760).a,o={protanomaly:{type:"protan",anomalize:!0},protanopia:{type:"protan"},deuteranomaly:{type:"deutan",anomalize:!0},deuteranopia:{type:"deutan"},tritanomaly:{type:"tritan",anomalize:!0},tritanopia:{type:"tritan"},achromatomaly:{type:"achroma",anomalize:!0},achromatopsia:{type:"achroma"}},s=function(e){return Math.round(255*e)},a=function(e){return function(t,i){var a=n(t);if(!a)return i?{R:0,G:0,B:0}:"#000000";var l=new r({R:s(a.red()||0),G:s(a.green()||0),B:s(a.blue()||0)},o[e].type,o[e].anomalize);return(l.R=l.R||0,l.G=l.G||0,l.B=l.B||0,i)?(delete l.X,delete l.Y,delete l.Z,l):new n.RGB(l.R%256/255,l.G%256/255,l.B%256/255,1).hex()}};for(var l in o)t[l]=a(l)},8874:function(e){"use strict";e.exports={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]}},19818:function(e,t,i){var n=i(8874),r=i(86851),o=Object.hasOwnProperty,s=Object.create(null);for(var a in n)o.call(n,a)&&(s[n[a]]=a);var l=e.exports={to:{},get:{}};function h(e,t,i){return Math.min(Math.max(t,e),i)}function u(e){var t=Math.round(e).toString(16).toUpperCase();return t.length<2?"0"+t:t}l.get=function(e){var t,i;switch(e.substring(0,3).toLowerCase()){case"hsl":t=l.get.hsl(e),i="hsl";break;case"hwb":t=l.get.hwb(e),i="hwb";break;default:t=l.get.rgb(e),i="rgb"}return t?{model:i,value:t}:null},l.get.rgb=function(e){if(!e)return null;var t,i,r,s=[0,0,0,1];if(t=e.match(/^#([a-f0-9]{6})([a-f0-9]{2})?$/i)){for(i=0,r=t[2],t=t[1];i<3;i++){var a=2*i;s[i]=parseInt(t.slice(a,a+2),16)}r&&(s[3]=parseInt(r,16)/255)}else if(t=e.match(/^#([a-f0-9]{3,4})$/i)){for(i=0,r=(t=t[1])[3];i<3;i++)s[i]=parseInt(t[i]+t[i],16);r&&(s[3]=parseInt(r+r,16)/255)}else if(t=e.match(/^rgba?\(\s*([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)\s*(?:[,|\/]\s*([+-]?[\d\.]+)(%?)\s*)?\)$/)){for(i=0;i<3;i++)s[i]=parseInt(t[i+1],0);t[4]&&(t[5]?s[3]=.01*parseFloat(t[4]):s[3]=parseFloat(t[4]))}else if(t=e.match(/^rgba?\(\s*([+-]?[\d\.]+)\%\s*,?\s*([+-]?[\d\.]+)\%\s*,?\s*([+-]?[\d\.]+)\%\s*(?:[,|\/]\s*([+-]?[\d\.]+)(%?)\s*)?\)$/)){for(i=0;i<3;i++)s[i]=Math.round(2.55*parseFloat(t[i+1]));t[4]&&(t[5]?s[3]=.01*parseFloat(t[4]):s[3]=parseFloat(t[4]))}else if(!(t=e.match(/^(\w+)$/)))return null;else return"transparent"===t[1]?[0,0,0,0]:o.call(n,t[1])?((s=n[t[1]])[3]=1,s):null;for(i=0;i<3;i++)s[i]=h(s[i],0,255);return s[3]=h(s[3],0,1),s},l.get.hsl=function(e){if(!e)return null;var t=e.match(/^hsla?\(\s*([+-]?(?:\d{0,3}\.)?\d+)(?:deg)?\s*,?\s*([+-]?[\d\.]+)%\s*,?\s*([+-]?[\d\.]+)%\s*(?:[,|\/]\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/);if(t){var i=parseFloat(t[4]);return[(parseFloat(t[1])%360+360)%360,h(parseFloat(t[2]),0,100),h(parseFloat(t[3]),0,100),h(isNaN(i)?1:i,0,1)]}return null},l.get.hwb=function(e){if(!e)return null;var t=e.match(/^hwb\(\s*([+-]?\d{0,3}(?:\.\d+)?)(?:deg)?\s*,\s*([+-]?[\d\.]+)%\s*,\s*([+-]?[\d\.]+)%\s*(?:,\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/);if(t){var i=parseFloat(t[4]);return[(parseFloat(t[1])%360+360)%360,h(parseFloat(t[2]),0,100),h(parseFloat(t[3]),0,100),h(isNaN(i)?1:i,0,1)]}return null},l.to.hex=function(){var e=r(arguments);return"#"+u(e[0])+u(e[1])+u(e[2])+(e[3]<1?u(Math.round(255*e[3])):"")},l.to.rgb=function(){var e=r(arguments);return e.length<4||1===e[3]?"rgb("+Math.round(e[0])+", "+Math.round(e[1])+", "+Math.round(e[2])+")":"rgba("+Math.round(e[0])+", "+Math.round(e[1])+", "+Math.round(e[2])+", "+e[3]+")"},l.to.rgb.percent=function(){var e=r(arguments),t=Math.round(e[0]/255*100),i=Math.round(e[1]/255*100),n=Math.round(e[2]/255*100);return e.length<4||1===e[3]?"rgb("+t+"%, "+i+"%, "+n+"%)":"rgba("+t+"%, "+i+"%, "+n+"%, "+e[3]+")"},l.to.hsl=function(){var e=r(arguments);return e.length<4||1===e[3]?"hsl("+e[0]+", "+e[1]+"%, "+e[2]+"%)":"hsla("+e[0]+", "+e[1]+"%, "+e[2]+"%, "+e[3]+")"},l.to.hwb=function(){var e=r(arguments),t="";return e.length>=4&&1!==e[3]&&(t=", "+e[3]),"hwb("+e[0]+", "+e[1]+"%, "+e[2]+"%"+t+")"},l.to.keyword=function(e){return s[e.slice(0,3)]}},26729:function(e){"use strict";var t=Object.prototype.hasOwnProperty,i="~";function n(){}function r(e,t,i){this.fn=e,this.context=t,this.once=i||!1}function o(e,t,n,o,s){if("function"!=typeof n)throw TypeError("The listener must be a function");var a=new r(n,o||e,s),l=i?i+t:t;return e._events[l]?e._events[l].fn?e._events[l]=[e._events[l],a]:e._events[l].push(a):(e._events[l]=a,e._eventsCount++),e}function s(e,t){0==--e._eventsCount?e._events=new n:delete e._events[t]}function a(){this._events=new n,this._eventsCount=0}Object.create&&(n.prototype=Object.create(null),new n().__proto__||(i=!1)),a.prototype.eventNames=function(){var e,n,r=[];if(0===this._eventsCount)return r;for(n in e=this._events)t.call(e,n)&&r.push(i?n.slice(1):n);return Object.getOwnPropertySymbols?r.concat(Object.getOwnPropertySymbols(e)):r},a.prototype.listeners=function(e){var t=i?i+e:e,n=this._events[t];if(!n)return[];if(n.fn)return[n.fn];for(var r=0,o=n.length,s=Array(o);rh+a*s*u||d>=p)g=s;else{if(Math.abs(f)<=-l*u)return s;f*(g-c)>=0&&(g=c),c=s,p=d}return 0}s=s||1,a=a||1e-6,l=l||.1;for(var m=0;m<10;++m){if(o(r.x,1,n.x,s,t),d=r.fx=e(r.x,r.fxprime),f=i(r.fxprime,t),d>h+a*s*u||m&&d>=c)return p(g,s,c);if(Math.abs(f)<=-l*u)break;if(f>=0)return p(s,g,d);c=d,g=s,s*=2}return s}e.bisect=function(e,t,i,n){var r=(n=n||{}).maxIterations||100,o=n.tolerance||1e-10,s=e(t),a=e(i),l=i-t;if(s*a>0)throw"Initial bisect points must have opposite signs";if(0===s)return t;if(0===a)return i;for(var h=0;h=0&&(t=u),Math.abs(l)=p[g-1].fx){var O=!1;if(C.fx>N.fx?(o(S,1+c,b,-c,N),S.fx=e(S),S.fx=1)break;for(m=1;m=n(d.fxprime))break}return a.history&&a.history.push({x:d.x.slice(),fx:d.fx,fxprime:d.fxprime.slice(),alpha:g}),d},e.gradientDescent=function(e,t,i){for(var r=(i=i||{}).maxIterations||100*t.length,s=i.learnRate||.001,a={x:t.slice(),fx:0,fxprime:t.slice()},l=0;l=n(a.fxprime)));++l);return a},e.gradientDescentLineSearch=function(e,t,i){i=i||{};var o,a={x:t.slice(),fx:0,fxprime:t.slice()},l={x:t.slice(),fx:0,fxprime:t.slice()},h=i.maxIterations||100*t.length,u=i.learnRate||1,d=t.slice(),c=i.c1||.001,f=i.c2||.1,g=[];if(i.history){var p=e;e=function(e,t){return g.push(e.slice()),p(e,t)}}a.fx=e(a.x,a.fxprime);for(var m=0;mn(a.fxprime)));++m);return a},e.zeros=t,e.zerosM=function(e,i){return t(e).map(function(){return t(i)})},e.norm2=n,e.weightedSum=o,e.scale=r}(t)},49685:function(e,t,i){"use strict";i.d(t,{Ib:function(){return n},WT:function(){return r}});var n=1e-6,r="undefined"!=typeof Float32Array?Float32Array:Array;Math.hypot||(Math.hypot=function(){for(var e=0,t=arguments.length;t--;)e+=arguments[t]*arguments[t];return Math.sqrt(e)})},35600:function(e,t,i){"use strict";i.d(t,{Ue:function(){return r},al:function(){return s},xO:function(){return o}});var n=i(49685);function r(){var e=new n.WT(9);return n.WT!=Float32Array&&(e[1]=0,e[2]=0,e[3]=0,e[5]=0,e[6]=0,e[7]=0),e[0]=1,e[4]=1,e[8]=1,e}function o(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[4],e[4]=t[5],e[5]=t[6],e[6]=t[8],e[7]=t[9],e[8]=t[10],e}function s(e,t,i,r,o,s,a,l,h){var u=new n.WT(9);return u[0]=e,u[1]=t,u[2]=i,u[3]=r,u[4]=o,u[5]=s,u[6]=a,u[7]=l,u[8]=h,u}},85975:function(e,t,i){"use strict";i.r(t),i.d(t,{add:function(){return Y},adjoint:function(){return c},clone:function(){return o},copy:function(){return s},create:function(){return r},determinant:function(){return f},equals:function(){return Q},exactEquals:function(){return Z},frob:function(){return K},fromQuat:function(){return M},fromQuat2:function(){return O},fromRotation:function(){return y},fromRotationTranslation:function(){return N},fromRotationTranslationScale:function(){return D},fromRotationTranslationScaleOrigin:function(){return x},fromScaling:function(){return S},fromTranslation:function(){return C},fromValues:function(){return a},fromXRotation:function(){return T},fromYRotation:function(){return R},fromZRotation:function(){return A},frustum:function(){return k},getRotation:function(){return w},getScaling:function(){return I},getTranslation:function(){return L},identity:function(){return h},invert:function(){return d},lookAt:function(){return G},mul:function(){return J},multiply:function(){return g},multiplyScalar:function(){return q},multiplyScalarAndAdd:function(){return X},ortho:function(){return V},orthoNO:function(){return H},orthoZO:function(){return W},perspective:function(){return F},perspectiveFromFieldOfView:function(){return U},perspectiveNO:function(){return P},perspectiveZO:function(){return B},rotate:function(){return _},rotateX:function(){return E},rotateY:function(){return v},rotateZ:function(){return b},scale:function(){return m},set:function(){return l},str:function(){return z},sub:function(){return ee},subtract:function(){return $},targetTo:function(){return j},translate:function(){return p},transpose:function(){return u}});var n=i(49685);function r(){var e=new n.WT(16);return n.WT!=Float32Array&&(e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[11]=0,e[12]=0,e[13]=0,e[14]=0),e[0]=1,e[5]=1,e[10]=1,e[15]=1,e}function o(e){var t=new n.WT(16);return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4],t[5]=e[5],t[6]=e[6],t[7]=e[7],t[8]=e[8],t[9]=e[9],t[10]=e[10],t[11]=e[11],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15],t}function s(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[8]=t[8],e[9]=t[9],e[10]=t[10],e[11]=t[11],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15],e}function a(e,t,i,r,o,s,a,l,h,u,d,c,f,g,p,m){var _=new n.WT(16);return _[0]=e,_[1]=t,_[2]=i,_[3]=r,_[4]=o,_[5]=s,_[6]=a,_[7]=l,_[8]=h,_[9]=u,_[10]=d,_[11]=c,_[12]=f,_[13]=g,_[14]=p,_[15]=m,_}function l(e,t,i,n,r,o,s,a,l,h,u,d,c,f,g,p,m){return e[0]=t,e[1]=i,e[2]=n,e[3]=r,e[4]=o,e[5]=s,e[6]=a,e[7]=l,e[8]=h,e[9]=u,e[10]=d,e[11]=c,e[12]=f,e[13]=g,e[14]=p,e[15]=m,e}function h(e){return e[0]=1,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=1,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=1,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e}function u(e,t){if(e===t){var i=t[1],n=t[2],r=t[3],o=t[6],s=t[7],a=t[11];e[1]=t[4],e[2]=t[8],e[3]=t[12],e[4]=i,e[6]=t[9],e[7]=t[13],e[8]=n,e[9]=o,e[11]=t[14],e[12]=r,e[13]=s,e[14]=a}else e[0]=t[0],e[1]=t[4],e[2]=t[8],e[3]=t[12],e[4]=t[1],e[5]=t[5],e[6]=t[9],e[7]=t[13],e[8]=t[2],e[9]=t[6],e[10]=t[10],e[11]=t[14],e[12]=t[3],e[13]=t[7],e[14]=t[11],e[15]=t[15];return e}function d(e,t){var i=t[0],n=t[1],r=t[2],o=t[3],s=t[4],a=t[5],l=t[6],h=t[7],u=t[8],d=t[9],c=t[10],f=t[11],g=t[12],p=t[13],m=t[14],_=t[15],E=i*a-n*s,v=i*l-r*s,b=i*h-o*s,C=n*l-r*a,S=n*h-o*a,y=r*h-o*l,T=u*p-d*g,R=u*m-c*g,A=u*_-f*g,N=d*m-c*p,O=d*_-f*p,L=c*_-f*m,I=E*L-v*O+b*N+C*A-S*R+y*T;return I?(I=1/I,e[0]=(a*L-l*O+h*N)*I,e[1]=(r*O-n*L-o*N)*I,e[2]=(p*y-m*S+_*C)*I,e[3]=(c*S-d*y-f*C)*I,e[4]=(l*A-s*L-h*R)*I,e[5]=(i*L-r*A+o*R)*I,e[6]=(m*b-g*y-_*v)*I,e[7]=(u*y-c*b+f*v)*I,e[8]=(s*O-a*A+h*T)*I,e[9]=(n*A-i*O-o*T)*I,e[10]=(g*S-p*b+_*E)*I,e[11]=(d*b-u*S-f*E)*I,e[12]=(a*R-s*N-l*T)*I,e[13]=(i*N-n*R+r*T)*I,e[14]=(p*v-g*C-m*E)*I,e[15]=(u*C-d*v+c*E)*I,e):null}function c(e,t){var i=t[0],n=t[1],r=t[2],o=t[3],s=t[4],a=t[5],l=t[6],h=t[7],u=t[8],d=t[9],c=t[10],f=t[11],g=t[12],p=t[13],m=t[14],_=t[15];return e[0]=a*(c*_-f*m)-d*(l*_-h*m)+p*(l*f-h*c),e[1]=-(n*(c*_-f*m)-d*(r*_-o*m)+p*(r*f-o*c)),e[2]=n*(l*_-h*m)-a*(r*_-o*m)+p*(r*h-o*l),e[3]=-(n*(l*f-h*c)-a*(r*f-o*c)+d*(r*h-o*l)),e[4]=-(s*(c*_-f*m)-u*(l*_-h*m)+g*(l*f-h*c)),e[5]=i*(c*_-f*m)-u*(r*_-o*m)+g*(r*f-o*c),e[6]=-(i*(l*_-h*m)-s*(r*_-o*m)+g*(r*h-o*l)),e[7]=i*(l*f-h*c)-s*(r*f-o*c)+u*(r*h-o*l),e[8]=s*(d*_-f*p)-u*(a*_-h*p)+g*(a*f-h*d),e[9]=-(i*(d*_-f*p)-u*(n*_-o*p)+g*(n*f-o*d)),e[10]=i*(a*_-h*p)-s*(n*_-o*p)+g*(n*h-o*a),e[11]=-(i*(a*f-h*d)-s*(n*f-o*d)+u*(n*h-o*a)),e[12]=-(s*(d*m-c*p)-u*(a*m-l*p)+g*(a*c-l*d)),e[13]=i*(d*m-c*p)-u*(n*m-r*p)+g*(n*c-r*d),e[14]=-(i*(a*m-l*p)-s*(n*m-r*p)+g*(n*l-r*a)),e[15]=i*(a*c-l*d)-s*(n*c-r*d)+u*(n*l-r*a),e}function f(e){var t=e[0],i=e[1],n=e[2],r=e[3],o=e[4],s=e[5],a=e[6],l=e[7],h=e[8],u=e[9],d=e[10],c=e[11],f=e[12],g=e[13],p=e[14],m=e[15];return(t*s-i*o)*(d*m-c*p)-(t*a-n*o)*(u*m-c*g)+(t*l-r*o)*(u*p-d*g)+(i*a-n*s)*(h*m-c*f)-(i*l-r*s)*(h*p-d*f)+(n*l-r*a)*(h*g-u*f)}function g(e,t,i){var n=t[0],r=t[1],o=t[2],s=t[3],a=t[4],l=t[5],h=t[6],u=t[7],d=t[8],c=t[9],f=t[10],g=t[11],p=t[12],m=t[13],_=t[14],E=t[15],v=i[0],b=i[1],C=i[2],S=i[3];return e[0]=v*n+b*a+C*d+S*p,e[1]=v*r+b*l+C*c+S*m,e[2]=v*o+b*h+C*f+S*_,e[3]=v*s+b*u+C*g+S*E,v=i[4],b=i[5],C=i[6],S=i[7],e[4]=v*n+b*a+C*d+S*p,e[5]=v*r+b*l+C*c+S*m,e[6]=v*o+b*h+C*f+S*_,e[7]=v*s+b*u+C*g+S*E,v=i[8],b=i[9],C=i[10],S=i[11],e[8]=v*n+b*a+C*d+S*p,e[9]=v*r+b*l+C*c+S*m,e[10]=v*o+b*h+C*f+S*_,e[11]=v*s+b*u+C*g+S*E,v=i[12],b=i[13],C=i[14],S=i[15],e[12]=v*n+b*a+C*d+S*p,e[13]=v*r+b*l+C*c+S*m,e[14]=v*o+b*h+C*f+S*_,e[15]=v*s+b*u+C*g+S*E,e}function p(e,t,i){var n,r,o,s,a,l,h,u,d,c,f,g,p=i[0],m=i[1],_=i[2];return t===e?(e[12]=t[0]*p+t[4]*m+t[8]*_+t[12],e[13]=t[1]*p+t[5]*m+t[9]*_+t[13],e[14]=t[2]*p+t[6]*m+t[10]*_+t[14],e[15]=t[3]*p+t[7]*m+t[11]*_+t[15]):(n=t[0],r=t[1],o=t[2],s=t[3],a=t[4],l=t[5],h=t[6],u=t[7],d=t[8],c=t[9],f=t[10],g=t[11],e[0]=n,e[1]=r,e[2]=o,e[3]=s,e[4]=a,e[5]=l,e[6]=h,e[7]=u,e[8]=d,e[9]=c,e[10]=f,e[11]=g,e[12]=n*p+a*m+d*_+t[12],e[13]=r*p+l*m+c*_+t[13],e[14]=o*p+h*m+f*_+t[14],e[15]=s*p+u*m+g*_+t[15]),e}function m(e,t,i){var n=i[0],r=i[1],o=i[2];return e[0]=t[0]*n,e[1]=t[1]*n,e[2]=t[2]*n,e[3]=t[3]*n,e[4]=t[4]*r,e[5]=t[5]*r,e[6]=t[6]*r,e[7]=t[7]*r,e[8]=t[8]*o,e[9]=t[9]*o,e[10]=t[10]*o,e[11]=t[11]*o,e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15],e}function _(e,t,i,r){var o,s,a,l,h,u,d,c,f,g,p,m,_,E,v,b,C,S,y,T,R,A,N,O,L=r[0],I=r[1],w=r[2],D=Math.hypot(L,I,w);return D0?(i[0]=(l*a+d*r+h*s-u*o)*2/c,i[1]=(h*a+d*o+u*r-l*s)*2/c,i[2]=(u*a+d*s+l*o-h*r)*2/c):(i[0]=(l*a+d*r+h*s-u*o)*2,i[1]=(h*a+d*o+u*r-l*s)*2,i[2]=(u*a+d*s+l*o-h*r)*2),N(e,t,i),e}function L(e,t){return e[0]=t[12],e[1]=t[13],e[2]=t[14],e}function I(e,t){var i=t[0],n=t[1],r=t[2],o=t[4],s=t[5],a=t[6],l=t[8],h=t[9],u=t[10];return e[0]=Math.hypot(i,n,r),e[1]=Math.hypot(o,s,a),e[2]=Math.hypot(l,h,u),e}function w(e,t){var i=new n.WT(3);I(i,t);var r=1/i[0],o=1/i[1],s=1/i[2],a=t[0]*r,l=t[1]*o,h=t[2]*s,u=t[4]*r,d=t[5]*o,c=t[6]*s,f=t[8]*r,g=t[9]*o,p=t[10]*s,m=a+d+p,_=0;return m>0?(_=2*Math.sqrt(m+1),e[3]=.25*_,e[0]=(c-g)/_,e[1]=(f-h)/_,e[2]=(l-u)/_):a>d&&a>p?(_=2*Math.sqrt(1+a-d-p),e[3]=(c-g)/_,e[0]=.25*_,e[1]=(l+u)/_,e[2]=(f+h)/_):d>p?(_=2*Math.sqrt(1+d-a-p),e[3]=(f-h)/_,e[0]=(l+u)/_,e[1]=.25*_,e[2]=(c+g)/_):(_=2*Math.sqrt(1+p-a-d),e[3]=(l-u)/_,e[0]=(f+h)/_,e[1]=(c+g)/_,e[2]=.25*_),e}function D(e,t,i,n){var r=t[0],o=t[1],s=t[2],a=t[3],l=r+r,h=o+o,u=s+s,d=r*l,c=r*h,f=r*u,g=o*h,p=o*u,m=s*u,_=a*l,E=a*h,v=a*u,b=n[0],C=n[1],S=n[2];return e[0]=(1-(g+m))*b,e[1]=(c+v)*b,e[2]=(f-E)*b,e[3]=0,e[4]=(c-v)*C,e[5]=(1-(d+m))*C,e[6]=(p+_)*C,e[7]=0,e[8]=(f+E)*S,e[9]=(p-_)*S,e[10]=(1-(d+g))*S,e[11]=0,e[12]=i[0],e[13]=i[1],e[14]=i[2],e[15]=1,e}function x(e,t,i,n,r){var o=t[0],s=t[1],a=t[2],l=t[3],h=o+o,u=s+s,d=a+a,c=o*h,f=o*u,g=o*d,p=s*u,m=s*d,_=a*d,E=l*h,v=l*u,b=l*d,C=n[0],S=n[1],y=n[2],T=r[0],R=r[1],A=r[2],N=(1-(p+_))*C,O=(f+b)*C,L=(g-v)*C,I=(f-b)*S,w=(1-(c+_))*S,D=(m+E)*S,x=(g+v)*y,M=(m-E)*y,k=(1-(c+p))*y;return e[0]=N,e[1]=O,e[2]=L,e[3]=0,e[4]=I,e[5]=w,e[6]=D,e[7]=0,e[8]=x,e[9]=M,e[10]=k,e[11]=0,e[12]=i[0]+T-(N*T+I*R+x*A),e[13]=i[1]+R-(O*T+w*R+M*A),e[14]=i[2]+A-(L*T+D*R+k*A),e[15]=1,e}function M(e,t){var i=t[0],n=t[1],r=t[2],o=t[3],s=i+i,a=n+n,l=r+r,h=i*s,u=n*s,d=n*a,c=r*s,f=r*a,g=r*l,p=o*s,m=o*a,_=o*l;return e[0]=1-d-g,e[1]=u+_,e[2]=c-m,e[3]=0,e[4]=u-_,e[5]=1-h-g,e[6]=f+p,e[7]=0,e[8]=c+m,e[9]=f-p,e[10]=1-h-d,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e}function k(e,t,i,n,r,o,s){var a=1/(i-t),l=1/(r-n),h=1/(o-s);return e[0]=2*o*a,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=2*o*l,e[6]=0,e[7]=0,e[8]=(i+t)*a,e[9]=(r+n)*l,e[10]=(s+o)*h,e[11]=-1,e[12]=0,e[13]=0,e[14]=s*o*2*h,e[15]=0,e}function P(e,t,i,n,r){var o,s=1/Math.tan(t/2);return e[0]=s/i,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=s,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[11]=-1,e[12]=0,e[13]=0,e[15]=0,null!=r&&r!==1/0?(o=1/(n-r),e[10]=(r+n)*o,e[14]=2*r*n*o):(e[10]=-1,e[14]=-2*n),e}var F=P;function B(e,t,i,n,r){var o,s=1/Math.tan(t/2);return e[0]=s/i,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=s,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[11]=-1,e[12]=0,e[13]=0,e[15]=0,null!=r&&r!==1/0?(o=1/(n-r),e[10]=r*o,e[14]=r*n*o):(e[10]=-1,e[14]=-n),e}function U(e,t,i,n){var r=Math.tan(t.upDegrees*Math.PI/180),o=Math.tan(t.downDegrees*Math.PI/180),s=Math.tan(t.leftDegrees*Math.PI/180),a=Math.tan(t.rightDegrees*Math.PI/180),l=2/(s+a),h=2/(r+o);return e[0]=l,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=h,e[6]=0,e[7]=0,e[8]=-((s-a)*l*.5),e[9]=(r-o)*h*.5,e[10]=n/(i-n),e[11]=-1,e[12]=0,e[13]=0,e[14]=n*i/(i-n),e[15]=0,e}function H(e,t,i,n,r,o,s){var a=1/(t-i),l=1/(n-r),h=1/(o-s);return e[0]=-2*a,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=-2*l,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=2*h,e[11]=0,e[12]=(t+i)*a,e[13]=(r+n)*l,e[14]=(s+o)*h,e[15]=1,e}var V=H;function W(e,t,i,n,r,o,s){var a=1/(t-i),l=1/(n-r),h=1/(o-s);return e[0]=-2*a,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=-2*l,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=h,e[11]=0,e[12]=(t+i)*a,e[13]=(r+n)*l,e[14]=o*h,e[15]=1,e}function G(e,t,i,r){var o,s,a,l,u,d,c,f,g,p,m=t[0],_=t[1],E=t[2],v=r[0],b=r[1],C=r[2],S=i[0],y=i[1],T=i[2];return Math.abs(m-S)0&&(u*=f=1/Math.sqrt(f),d*=f,c*=f);var g=l*c-h*d,p=h*u-a*c,m=a*d-l*u;return(f=g*g+p*p+m*m)>0&&(g*=f=1/Math.sqrt(f),p*=f,m*=f),e[0]=g,e[1]=p,e[2]=m,e[3]=0,e[4]=d*m-c*p,e[5]=c*g-u*m,e[6]=u*p-d*g,e[7]=0,e[8]=u,e[9]=d,e[10]=c,e[11]=0,e[12]=r,e[13]=o,e[14]=s,e[15]=1,e}function z(e){return"mat4("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+", "+e[4]+", "+e[5]+", "+e[6]+", "+e[7]+", "+e[8]+", "+e[9]+", "+e[10]+", "+e[11]+", "+e[12]+", "+e[13]+", "+e[14]+", "+e[15]+")"}function K(e){return Math.hypot(e[0],e[1],e[2],e[3],e[4],e[5],e[6],e[7],e[8],e[9],e[10],e[11],e[12],e[13],e[14],e[15])}function Y(e,t,i){return e[0]=t[0]+i[0],e[1]=t[1]+i[1],e[2]=t[2]+i[2],e[3]=t[3]+i[3],e[4]=t[4]+i[4],e[5]=t[5]+i[5],e[6]=t[6]+i[6],e[7]=t[7]+i[7],e[8]=t[8]+i[8],e[9]=t[9]+i[9],e[10]=t[10]+i[10],e[11]=t[11]+i[11],e[12]=t[12]+i[12],e[13]=t[13]+i[13],e[14]=t[14]+i[14],e[15]=t[15]+i[15],e}function $(e,t,i){return e[0]=t[0]-i[0],e[1]=t[1]-i[1],e[2]=t[2]-i[2],e[3]=t[3]-i[3],e[4]=t[4]-i[4],e[5]=t[5]-i[5],e[6]=t[6]-i[6],e[7]=t[7]-i[7],e[8]=t[8]-i[8],e[9]=t[9]-i[9],e[10]=t[10]-i[10],e[11]=t[11]-i[11],e[12]=t[12]-i[12],e[13]=t[13]-i[13],e[14]=t[14]-i[14],e[15]=t[15]-i[15],e}function q(e,t,i){return e[0]=t[0]*i,e[1]=t[1]*i,e[2]=t[2]*i,e[3]=t[3]*i,e[4]=t[4]*i,e[5]=t[5]*i,e[6]=t[6]*i,e[7]=t[7]*i,e[8]=t[8]*i,e[9]=t[9]*i,e[10]=t[10]*i,e[11]=t[11]*i,e[12]=t[12]*i,e[13]=t[13]*i,e[14]=t[14]*i,e[15]=t[15]*i,e}function X(e,t,i,n){return e[0]=t[0]+i[0]*n,e[1]=t[1]+i[1]*n,e[2]=t[2]+i[2]*n,e[3]=t[3]+i[3]*n,e[4]=t[4]+i[4]*n,e[5]=t[5]+i[5]*n,e[6]=t[6]+i[6]*n,e[7]=t[7]+i[7]*n,e[8]=t[8]+i[8]*n,e[9]=t[9]+i[9]*n,e[10]=t[10]+i[10]*n,e[11]=t[11]+i[11]*n,e[12]=t[12]+i[12]*n,e[13]=t[13]+i[13]*n,e[14]=t[14]+i[14]*n,e[15]=t[15]+i[15]*n,e}function Z(e,t){return e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]&&e[3]===t[3]&&e[4]===t[4]&&e[5]===t[5]&&e[6]===t[6]&&e[7]===t[7]&&e[8]===t[8]&&e[9]===t[9]&&e[10]===t[10]&&e[11]===t[11]&&e[12]===t[12]&&e[13]===t[13]&&e[14]===t[14]&&e[15]===t[15]}function Q(e,t){var i=e[0],r=e[1],o=e[2],s=e[3],a=e[4],l=e[5],h=e[6],u=e[7],d=e[8],c=e[9],f=e[10],g=e[11],p=e[12],m=e[13],_=e[14],E=e[15],v=t[0],b=t[1],C=t[2],S=t[3],y=t[4],T=t[5],R=t[6],A=t[7],N=t[8],O=t[9],L=t[10],I=t[11],w=t[12],D=t[13],x=t[14],M=t[15];return Math.abs(i-v)<=n.Ib*Math.max(1,Math.abs(i),Math.abs(v))&&Math.abs(r-b)<=n.Ib*Math.max(1,Math.abs(r),Math.abs(b))&&Math.abs(o-C)<=n.Ib*Math.max(1,Math.abs(o),Math.abs(C))&&Math.abs(s-S)<=n.Ib*Math.max(1,Math.abs(s),Math.abs(S))&&Math.abs(a-y)<=n.Ib*Math.max(1,Math.abs(a),Math.abs(y))&&Math.abs(l-T)<=n.Ib*Math.max(1,Math.abs(l),Math.abs(T))&&Math.abs(h-R)<=n.Ib*Math.max(1,Math.abs(h),Math.abs(R))&&Math.abs(u-A)<=n.Ib*Math.max(1,Math.abs(u),Math.abs(A))&&Math.abs(d-N)<=n.Ib*Math.max(1,Math.abs(d),Math.abs(N))&&Math.abs(c-O)<=n.Ib*Math.max(1,Math.abs(c),Math.abs(O))&&Math.abs(f-L)<=n.Ib*Math.max(1,Math.abs(f),Math.abs(L))&&Math.abs(g-I)<=n.Ib*Math.max(1,Math.abs(g),Math.abs(I))&&Math.abs(p-w)<=n.Ib*Math.max(1,Math.abs(p),Math.abs(w))&&Math.abs(m-D)<=n.Ib*Math.max(1,Math.abs(m),Math.abs(D))&&Math.abs(_-x)<=n.Ib*Math.max(1,Math.abs(_),Math.abs(x))&&Math.abs(E-M)<=n.Ib*Math.max(1,Math.abs(E),Math.abs(M))}var J=g,ee=$},32945:function(e,t,i){"use strict";i.d(t,{Fv:function(){return p},JG:function(){return f},Jp:function(){return h},Su:function(){return d},U_:function(){return u},Ue:function(){return a},al:function(){return c},dC:function(){return g},yY:function(){return l}});var n=i(49685),r=i(35600),o=i(77160),s=i(98333);function a(){var e=new n.WT(4);return n.WT!=Float32Array&&(e[0]=0,e[1]=0,e[2]=0),e[3]=1,e}function l(e,t,i){var n=Math.sin(i*=.5);return e[0]=n*t[0],e[1]=n*t[1],e[2]=n*t[2],e[3]=Math.cos(i),e}function h(e,t,i){var n=t[0],r=t[1],o=t[2],s=t[3],a=i[0],l=i[1],h=i[2],u=i[3];return e[0]=n*u+s*a+r*h-o*l,e[1]=r*u+s*l+o*a-n*h,e[2]=o*u+s*h+n*l-r*a,e[3]=s*u-n*a-r*l-o*h,e}function u(e,t){var i=t[0],n=t[1],r=t[2],o=t[3],s=i*i+n*n+r*r+o*o,a=s?1/s:0;return e[0]=-i*a,e[1]=-n*a,e[2]=-r*a,e[3]=o*a,e}function d(e,t,i,n){var r=.5*Math.PI/180,o=Math.sin(t*=r),s=Math.cos(t),a=Math.sin(i*=r),l=Math.cos(i),h=Math.sin(n*=r),u=Math.cos(n);return e[0]=o*l*u-s*a*h,e[1]=s*a*u+o*l*h,e[2]=s*l*h-o*a*u,e[3]=s*l*u+o*a*h,e}s.d9;var c=s.al,f=s.JG;s.t8,s.IH;var g=h;s.bA,s.AK,s.t7,s.kE,s.we;var p=s.Fv;s.I6,s.fS,o.Ue(),o.al(1,0,0),o.al(0,1,0),a(),a(),r.Ue()},31437:function(e,t,i){"use strict";i.d(t,{AK:function(){return l},Fv:function(){return a},I6:function(){return h},JG:function(){return s},al:function(){return o}});var n,r=i(49685);function o(e,t){var i=new r.WT(2);return i[0]=e,i[1]=t,i}function s(e,t){return e[0]=t[0],e[1]=t[1],e}function a(e,t){var i=t[0],n=t[1],r=i*i+n*n;return r>0&&(r=1/Math.sqrt(r)),e[0]=t[0]*r,e[1]=t[1]*r,e}function l(e,t){return e[0]*t[0]+e[1]*t[1]}function h(e,t){return e[0]===t[0]&&e[1]===t[1]}n=new r.WT(2),r.WT!=Float32Array&&(n[0]=0,n[1]=0)},77160:function(e,t,i){"use strict";i.d(t,{$X:function(){return d},AK:function(){return p},Fv:function(){return g},IH:function(){return u},JG:function(){return l},Jp:function(){return c},TK:function(){return S},Ue:function(){return r},VC:function(){return b},Zh:function(){return y},al:function(){return a},bA:function(){return f},d9:function(){return o},fF:function(){return E},fS:function(){return C},kC:function(){return m},kE:function(){return s},kK:function(){return v},t7:function(){return _},t8:function(){return h}});var n=i(49685);function r(){var e=new n.WT(3);return n.WT!=Float32Array&&(e[0]=0,e[1]=0,e[2]=0),e}function o(e){var t=new n.WT(3);return t[0]=e[0],t[1]=e[1],t[2]=e[2],t}function s(e){return Math.hypot(e[0],e[1],e[2])}function a(e,t,i){var r=new n.WT(3);return r[0]=e,r[1]=t,r[2]=i,r}function l(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e}function h(e,t,i,n){return e[0]=t,e[1]=i,e[2]=n,e}function u(e,t,i){return e[0]=t[0]+i[0],e[1]=t[1]+i[1],e[2]=t[2]+i[2],e}function d(e,t,i){return e[0]=t[0]-i[0],e[1]=t[1]-i[1],e[2]=t[2]-i[2],e}function c(e,t,i){return e[0]=t[0]*i[0],e[1]=t[1]*i[1],e[2]=t[2]*i[2],e}function f(e,t,i){return e[0]=t[0]*i,e[1]=t[1]*i,e[2]=t[2]*i,e}function g(e,t){var i=t[0],n=t[1],r=t[2],o=i*i+n*n+r*r;return o>0&&(o=1/Math.sqrt(o)),e[0]=t[0]*o,e[1]=t[1]*o,e[2]=t[2]*o,e}function p(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]}function m(e,t,i){var n=t[0],r=t[1],o=t[2],s=i[0],a=i[1],l=i[2];return e[0]=r*l-o*a,e[1]=o*s-n*l,e[2]=n*a-r*s,e}function _(e,t,i,n){var r=t[0],o=t[1],s=t[2];return e[0]=r+n*(i[0]-r),e[1]=o+n*(i[1]-o),e[2]=s+n*(i[2]-s),e}function E(e,t,i){var n=t[0],r=t[1],o=t[2],s=i[3]*n+i[7]*r+i[11]*o+i[15];return s=s||1,e[0]=(i[0]*n+i[4]*r+i[8]*o+i[12])/s,e[1]=(i[1]*n+i[5]*r+i[9]*o+i[13])/s,e[2]=(i[2]*n+i[6]*r+i[10]*o+i[14])/s,e}function v(e,t,i){var n=t[0],r=t[1],o=t[2];return e[0]=n*i[0]+r*i[3]+o*i[6],e[1]=n*i[1]+r*i[4]+o*i[7],e[2]=n*i[2]+r*i[5]+o*i[8],e}function b(e,t,i){var n=i[0],r=i[1],o=i[2],s=i[3],a=t[0],l=t[1],h=t[2],u=r*h-o*l,d=o*a-n*h,c=n*l-r*a,f=r*c-o*d,g=o*u-n*c,p=n*d-r*u,m=2*s;return u*=m,d*=m,c*=m,f*=2,g*=2,p*=2,e[0]=a+u+f,e[1]=l+d+g,e[2]=h+c+p,e}function C(e,t){var i=e[0],r=e[1],o=e[2],s=t[0],a=t[1],l=t[2];return Math.abs(i-s)<=n.Ib*Math.max(1,Math.abs(i),Math.abs(s))&&Math.abs(r-a)<=n.Ib*Math.max(1,Math.abs(r),Math.abs(a))&&Math.abs(o-l)<=n.Ib*Math.max(1,Math.abs(o),Math.abs(l))}var S=function(e,t){return Math.hypot(t[0]-e[0],t[1]-e[1],t[2]-e[2])},y=s;r()},98333:function(e,t,i){"use strict";i.d(t,{AK:function(){return g},Fv:function(){return f},I6:function(){return _},IH:function(){return h},JG:function(){return a},Ue:function(){return r},al:function(){return s},bA:function(){return u},d9:function(){return o},fF:function(){return m},fS:function(){return E},kE:function(){return d},t7:function(){return p},t8:function(){return l},we:function(){return c}});var n=i(49685);function r(){var e=new n.WT(4);return n.WT!=Float32Array&&(e[0]=0,e[1]=0,e[2]=0,e[3]=0),e}function o(e){var t=new n.WT(4);return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t}function s(e,t,i,r){var o=new n.WT(4);return o[0]=e,o[1]=t,o[2]=i,o[3]=r,o}function a(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e}function l(e,t,i,n,r){return e[0]=t,e[1]=i,e[2]=n,e[3]=r,e}function h(e,t,i){return e[0]=t[0]+i[0],e[1]=t[1]+i[1],e[2]=t[2]+i[2],e[3]=t[3]+i[3],e}function u(e,t,i){return e[0]=t[0]*i,e[1]=t[1]*i,e[2]=t[2]*i,e[3]=t[3]*i,e}function d(e){return Math.hypot(e[0],e[1],e[2],e[3])}function c(e){var t=e[0],i=e[1],n=e[2],r=e[3];return t*t+i*i+n*n+r*r}function f(e,t){var i=t[0],n=t[1],r=t[2],o=t[3],s=i*i+n*n+r*r+o*o;return s>0&&(s=1/Math.sqrt(s)),e[0]=i*s,e[1]=n*s,e[2]=r*s,e[3]=o*s,e}function g(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]+e[3]*t[3]}function p(e,t,i,n){var r=t[0],o=t[1],s=t[2],a=t[3];return e[0]=r+n*(i[0]-r),e[1]=o+n*(i[1]-o),e[2]=s+n*(i[2]-s),e[3]=a+n*(i[3]-a),e}function m(e,t,i){var n=t[0],r=t[1],o=t[2],s=t[3];return e[0]=i[0]*n+i[4]*r+i[8]*o+i[12]*s,e[1]=i[1]*n+i[5]*r+i[9]*o+i[13]*s,e[2]=i[2]*n+i[6]*r+i[10]*o+i[14]*s,e[3]=i[3]*n+i[7]*r+i[11]*o+i[15]*s,e}function _(e,t){return e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]&&e[3]===t[3]}function E(e,t){var i=e[0],r=e[1],o=e[2],s=e[3],a=t[0],l=t[1],h=t[2],u=t[3];return Math.abs(i-a)<=n.Ib*Math.max(1,Math.abs(i),Math.abs(a))&&Math.abs(r-l)<=n.Ib*Math.max(1,Math.abs(r),Math.abs(l))&&Math.abs(o-h)<=n.Ib*Math.max(1,Math.abs(o),Math.abs(h))&&Math.abs(s-u)<=n.Ib*Math.max(1,Math.abs(s),Math.abs(u))}r()},9488:function(e,t,i){"use strict";var n,r;function o(e,t=0){return e[e.length-(1+t)]}function s(e){if(0===e.length)throw Error("Invalid tail call");return[e.slice(0,e.length-1),e[e.length-1]]}function a(e,t,i=(e,t)=>e===t){if(e===t)return!0;if(!e||!t||e.length!==t.length)return!1;for(let n=0,r=e.length;n0))return e;n=e-1}}return-(i+1)}(e.length,n=>i(e[n],t))}function u(e){return e.filter(e=>!!e)}function d(e){return!Array.isArray(e)||0===e.length}function c(e){return Array.isArray(e)&&e.length>0}function f(e,t=e=>e){let i=new Set;return e.filter(e=>{let n=t(e);return!i.has(n)&&(i.add(n),!0)})}function g(e,t){let i=function(e,t){for(let i=e.length-1;i>=0;i--){let n=e[i];if(t(n))return i}return -1}(e,t);if(-1!==i)return e[i]}function p(e,t){return e.length>0?e[0]:t}function m(e,t){let i="number"==typeof t?e:0;"number"==typeof t?i=e:(i=0,t=e);let n=[];if(i<=t)for(let e=i;et;e--)n.push(e);return n}function _(e,t,i){let n=e.slice(0,t),r=e.slice(t);return n.concat(i,r)}function E(e,t){let i=e.indexOf(t);i>-1&&(e.splice(i,1),e.unshift(t))}function v(e,t){let i=e.indexOf(t);i>-1&&(e.splice(i,1),e.push(t))}function b(e,t){for(let i of t)e.push(i)}function C(e,t,i,n){let r=S(e,t),o=e.splice(r,i);return!function(e,t,i){let n=S(e,t),r=e.length,o=i.length;e.length=r+o;for(let t=r-1;t>=n;t--)e[t+o]=e[t];for(let t=0;tt(e(i),e(n))}function T(e,t){if(0===e.length)return;let i=e[0];for(let n=1;n=0&&(i=r)}return i}function R(e,t){return function(e,t){if(0===e.length)return;let i=e[0];for(let n=1;n0&&(i=r)}return i}(e,(e,i)=>-t(e,i))}i.d(t,{EB:function(){return f},Gb:function(){return o},H9:function(){return A},JH:function(){return s},LS:function(){return l},Of:function(){return c},VJ:function(){return R},W$:function(){return N},XY:function(){return d},Xh:function(){return p},Zv:function(){return _},al:function(){return v},dF:function(){return g},db:function(){return C},fS:function(){return a},jV:function(){return T},kX:function(){return u},ry:function(){return h},tT:function(){return y},vA:function(){return b},w6:function(){return m},zI:function(){return E}}),(r=n||(n={})).isLessThan=function(e){return e<0},r.isGreaterThan=function(e){return e>0},r.isNeitherLessOrGreaterThan=function(e){return 0===e},r.greaterThan=1,r.lessThan=-1,r.neitherLessOrGreaterThan=0;class A{constructor(e){this.items=e,this.firstIdx=0,this.lastIdx=this.items.length-1}get length(){return this.lastIdx-this.firstIdx+1}takeWhile(e){let t=this.firstIdx;for(;t=0&&e(this.items[t]);)t--;let i=t===this.lastIdx?null:this.items.slice(t+1,this.lastIdx+1);return this.lastIdx=t,i}peek(){if(0!==this.length)return this.items[this.firstIdx]}dequeue(){let e=this.items[this.firstIdx];return this.firstIdx++,e}takeCount(e){let t=this.items.slice(this.firstIdx,this.firstIdx+e);return this.firstIdx+=e,t}}class N{constructor(e){this.iterate=e}toArray(){let e=[];return this.iterate(t=>(e.push(t),!0)),e}filter(e){return new N(t=>this.iterate(i=>!e(i)||t(i)))}map(e){return new N(t=>this.iterate(i=>t(e(i))))}findLast(e){let t;return this.iterate(i=>(e(i)&&(t=i),!0)),t}findLastMaxBy(e){let t;let i=!0;return this.iterate(r=>((i||n.isGreaterThan(e(r,t)))&&(i=!1,t=r),!0)),t}}N.empty=new N(e=>{})},53725:function(e,t,i){"use strict";var n;i.d(t,{$:function(){return n}}),function(e){function t(e){return e&&"object"==typeof e&&"function"==typeof e[Symbol.iterator]}e.is=t;let i=Object.freeze([]);function*n(e){yield e}e.empty=function(){return i},e.single=n,e.wrap=function(e){return t(e)?e:n(e)},e.from=function(e){return e||i},e.isEmpty=function(e){return!e||!0===e[Symbol.iterator]().next().done},e.first=function(e){return e[Symbol.iterator]().next().value},e.some=function(e,t){for(let i of e)if(t(i))return!0;return!1},e.find=function(e,t){for(let i of e)if(t(i))return i},e.filter=function*(e,t){for(let i of e)t(i)&&(yield i)},e.map=function*(e,t){let i=0;for(let n of e)yield t(n,i++)},e.concat=function*(...e){for(let t of e)for(let e of t)yield e},e.reduce=function(e,t,i){let n=i;for(let i of e)n=t(n,i);return n},e.slice=function*(e,t,i=e.length){for(t<0&&(t+=e.length),i<0?i+=e.length:i>e.length&&(i=e.length);tr}]}}(n||(n={}))},91741:function(e,t,i){"use strict";i.d(t,{S:function(){return r}});class n{constructor(e){this.element=e,this.next=n.Undefined,this.prev=n.Undefined}}n.Undefined=new n(void 0);class r{constructor(){this._first=n.Undefined,this._last=n.Undefined,this._size=0}get size(){return this._size}isEmpty(){return this._first===n.Undefined}clear(){let e=this._first;for(;e!==n.Undefined;){let t=e.next;e.prev=n.Undefined,e.next=n.Undefined,e=t}this._first=n.Undefined,this._last=n.Undefined,this._size=0}unshift(e){return this._insert(e,!1)}push(e){return this._insert(e,!0)}_insert(e,t){let i=new n(e);if(this._first===n.Undefined)this._first=i,this._last=i;else if(t){let e=this._last;this._last=i,i.prev=e,e.next=i}else{let e=this._first;this._first=i,i.next=e,e.prev=i}this._size+=1;let r=!1;return()=>{r||(r=!0,this._remove(i))}}shift(){if(this._first!==n.Undefined){let e=this._first.element;return this._remove(this._first),e}}pop(){if(this._last!==n.Undefined){let e=this._last.element;return this._remove(this._last),e}}_remove(e){if(e.prev!==n.Undefined&&e.next!==n.Undefined){let t=e.prev;t.next=e.next,e.next.prev=t}else e.prev===n.Undefined&&e.next===n.Undefined?(this._first=n.Undefined,this._last=n.Undefined):e.next===n.Undefined?(this._last=this._last.prev,this._last.next=n.Undefined):e.prev===n.Undefined&&(this._first=this._first.next,this._first.prev=n.Undefined);this._size-=1}*[Symbol.iterator](){let e=this._first;for(;e!==n.Undefined;)yield e.element,e=e.next}}},36248:function(e,t,i){"use strict";i.d(t,{$E:function(){return a},I8:function(){return function e(t){if(!t||"object"!=typeof t||t instanceof RegExp)return t;let i=Array.isArray(t)?[]:{};return Object.entries(t).forEach(([t,n])=>{i[t]=n&&"object"==typeof n?e(n):n}),i}},IU:function(){return l},_A:function(){return r},fS:function(){return function e(t,i){let n,r;if(t===i)return!0;if(null==t||null==i||typeof t!=typeof i||"object"!=typeof t||Array.isArray(t)!==Array.isArray(i))return!1;if(Array.isArray(t)){if(t.length!==i.length)return!1;for(n=0;n{o in t?r&&((0,n.Kn)(t[o])&&(0,n.Kn)(i[o])?e(t[o],i[o],r):t[o]=i[o]):t[o]=i[o]}),t):i}},rs:function(){return s}});var n=i(98401);function r(e){if(!e||"object"!=typeof e)return e;let t=[e];for(;t.length>0;){let e=t.shift();for(let i in Object.freeze(e),e)if(o.call(e,i)){let r=e[i];"object"!=typeof r||Object.isFrozen(r)||(0,n.fU)(r)||t.push(r)}}return e}let o=Object.prototype.hasOwnProperty;function s(e,t){return function e(t,i,r){if((0,n.Jp)(t))return t;let s=i(t);if(void 0!==s)return s;if(Array.isArray(t)){let n=[];for(let o of t)n.push(e(o,i,r));return n}if((0,n.Kn)(t)){if(r.has(t))throw Error("Cannot clone recursive data-structure");r.add(t);let n={};for(let s in t)o.call(t,s)&&(n[s]=e(t[s],i,r));return r.delete(t),n}return t}(e,t,new Set)}function a(e){let t=[];for(let i of function(e){let t=[];for(;Object.prototype!==e;)t=t.concat(Object.getOwnPropertyNames(e)),e=Object.getPrototypeOf(e);return t}(e))"function"==typeof e[i]&&t.push(i);return t}function l(e,t){let i=e=>function(){let i=Array.prototype.slice.call(arguments,0);return t(e,i)},n={};for(let t of e)n[t]=i(t);return n}},1432:function(e,t,i){"use strict";let n,r;i.d(t,{$L:function(){return S},ED:function(){return E},G6:function(){return k},IJ:function(){return b},OS:function(){return L},dz:function(){return v},fn:function(){return O},gn:function(){return T},i7:function(){return x},li:function(){return p},n2:function(){return y},r:function(){return D},tY:function(){return C},tq:function(){return R},un:function(){return P},vU:function(){return M}});var o,s=i(63580),a=i(83454);let l=!1,h=!1,u=!1,d=!1,c=!1,f=!1,g=!1,p="object"==typeof self?self:"object"==typeof i.g?i.g:{};void 0!==p.vscode&&void 0!==p.vscode.process?r=p.vscode.process:void 0!==a&&(r=a);let m="string"==typeof(null===(o=null==r?void 0:r.versions)||void 0===o?void 0:o.electron),_=m&&(null==r?void 0:r.type)==="renderer";if("object"!=typeof navigator||_){if("object"==typeof r){l="win32"===r.platform,h="darwin"===r.platform,(u="linux"===r.platform)&&r.env.SNAP&&r.env.SNAP_REVISION,r.env.CI||r.env.BUILD_ARTIFACTSTAGINGDIRECTORY;let e=r.env.VSCODE_NLS_CONFIG;if(e)try{let t=JSON.parse(e);t.availableLanguages["*"],t.locale,t.osLocale,t._translationsConfigFile}catch(e){}d=!0}else console.error("Unable to resolve platform.")}else l=(n=navigator.userAgent).indexOf("Windows")>=0,h=n.indexOf("Macintosh")>=0,f=(n.indexOf("Macintosh")>=0||n.indexOf("iPad")>=0||n.indexOf("iPhone")>=0)&&!!navigator.maxTouchPoints&&navigator.maxTouchPoints>0,u=n.indexOf("Linux")>=0,g=(null==n?void 0:n.indexOf("Mobi"))>=0,c=!0,s.aj(s.NC({key:"ensureLoaderPluginIsLoaded",comment:["{Locked}"]},"_")),navigator.language;let E=l,v=h,b=u,C=d,S=c,y=c&&"function"==typeof p.importScripts,T=f,R=g,A=n,N="function"==typeof p.postMessage&&!p.importScripts,O=(()=>{if(N){let e=[];p.addEventListener("message",t=>{if(t.data&&t.data.vscodeScheduleAsyncWork)for(let i=0,n=e.length;i{let n=++t;e.push({id:n,callback:i}),p.postMessage({vscodeScheduleAsyncWork:n},"*")}}return e=>setTimeout(e)})(),L=h||f?2:l?1:3,I=!0,w=!1;function D(){if(!w){w=!0;let e=new Uint8Array(2);e[0]=1,e[1]=2;let t=new Uint16Array(e.buffer);I=513===t[0]}return I}let x=!!(A&&A.indexOf("Chrome")>=0),M=!!(A&&A.indexOf("Firefox")>=0),k=!!(!x&&A&&A.indexOf("Safari")>=0),P=!!(A&&A.indexOf("Edg/")>=0);A&&A.indexOf("Android")},98401:function(e,t,i){"use strict";function n(e){return"string"==typeof e}function r(e){return"object"==typeof e&&null!==e&&!Array.isArray(e)&&!(e instanceof RegExp)&&!(e instanceof Date)}function o(e){let t=Object.getPrototypeOf(Uint8Array);return"object"==typeof e&&e instanceof t}function s(e){return"number"==typeof e&&!isNaN(e)}function a(e){return!!e&&"function"==typeof e[Symbol.iterator]}function l(e){return!0===e||!1===e}function h(e){return void 0===e}function u(e){return!d(e)}function d(e){return h(e)||null===e}function c(e,t){if(!e)throw Error(t?`Unexpected type, expected '${t}'`:"Unexpected type")}function f(e){if(d(e))throw Error("Assertion Failed: argument is undefined or null");return e}function g(e){return"function"==typeof e}function p(e,t){let i=Math.min(e.length,t.length);for(let r=0;rs.maxLen){let n=t-s.maxLen/2;return n<0?n=0:o+=n,r=r.substring(n,t+s.maxLen/2),e(t,i,r,o,s)}let a=Date.now(),h=t-1-o,u=-1,d=null;for(let e=1;!(Date.now()-a>=s.timeBudget);e++){let t=h-s.windowSize*e;i.lastIndex=Math.max(0,t);let n=function(e,t,i,n){let r;for(;r=e.exec(t);){let t=r.index||0;if(t<=i&&e.lastIndex>=i)return r;if(n>0&&t>n)break}return null}(i,r,h,u);if(!n&&d||(d=n,t<=0))break;u=t}if(d){let e={word:d[0],startColumn:o+1+d.index,endColumn:o+1+d.index+d[0].length};return i.lastIndex=0,e}return null}},vu:function(){return o}});var n=i(53725),r=i(91741);let o="`~!@#$%^&*()-=+[{]}\\|;:'\",.<>/?",s=function(e=""){let t="(-?\\d*\\.\\d\\w*)|([^";for(let i of o)e.indexOf(i)>=0||(t+="\\"+i);return RegExp(t+="\\s]+)","g")}();function a(e){let t=s;if(e&&e instanceof RegExp){if(e.global)t=e;else{let i="g";e.ignoreCase&&(i+="i"),e.multiline&&(i+="m"),e.unicode&&(i+="u"),t=new RegExp(e.source,i)}}return t.lastIndex=0,t}let l=new r.S;l.unshift({maxLen:1e3,windowSize:15,timeBudget:150})},77119:function(e,t,i){"use strict";let n,r,o,s,a,l,h,u,d,c,f,g,p,m,_,E,v,b;i.r(t),i.d(t,{CancellationTokenSource:function(){return k1},Emitter:function(){return k2},KeyCode:function(){return k5},KeyMod:function(){return k4},MarkerSeverity:function(){return k7},MarkerTag:function(){return Pe},Position:function(){return k3},Range:function(){return k6},Selection:function(){return k9},SelectionDirection:function(){return k8},Token:function(){return Pi},Uri:function(){return Pt},editor:function(){return Pn},languages:function(){return Pr}});var C,S,y,T,R,A,N,O,L,I,w,D,x,M,k,P,F,B,U,H,V,W,G,j,z,K,Y,$,q,X,Z,Q,J,ee,et,ei,en,er,eo,es,ea,el,eh,eu,ed,ec,ef,eg,ep,em,e_,eE,ev,eb,eC,eS,ey,eT,eR,eA,eN,eO,eL,eI,ew,eD,ex,eM,ek,eP,eF,eB,eU,eH,eV,eW,eG,ej,ez,eK,eY,e$,eq,eX,eZ,eQ,eJ,e0,e1,e2,e5,e4,e3,e6,e9,e8,e7,te,tt,ti,tn,tr,to,ts,ta,tl,th,tu,td,tc,tf,tg,tp,tm,t_,tE,tv,tb,tC,tS,ty,tT,tR,tA,tN,tO,tL,tI,tw,tD,tx,tM,tk,tP,tF,tB,tU,tH,tV,tW,tG,tj,tz,tK,tY,t$,tq,tX,tZ,tQ,tJ,t0,t1,t2,t5,t4,t3,t6,t9,t8,t7,ie,it,ii,ir,io,is,ia,il,ih,iu,id,ic,ig,ip,im,i_,iE,iv,ib,iC,iS,iy,iT,iR,iA,iN,iO,iL,iI,iw,iD,ix,iM,ik,iP,iF,iB,iU,iH,iV,iW,iG,ij,iz,iK,iY,i$,iq,iX,iZ,iQ,iJ=i(64141);let i0=new class{constructor(){this.listeners=[],this.unexpectedErrorHandler=function(e){setTimeout(()=>{if(e.stack){if(ne.isErrorNoTelemetry(e))throw new ne(e.message+"\n\n"+e.stack);throw Error(e.message+"\n\n"+e.stack)}throw e},0)}}emit(e){this.listeners.forEach(t=>{t(e)})}onUnexpectedError(e){this.unexpectedErrorHandler(e),this.emit(e)}onUnexpectedExternalError(e){this.unexpectedErrorHandler(e)}};function i1(e){i3(e)||i0.onUnexpectedError(e)}function i2(e){i3(e)||i0.onUnexpectedExternalError(e)}function i5(e){if(e instanceof Error){let{name:t,message:i}=e,n=e.stacktrace||e.stack;return{$isError:!0,name:t,message:i,stack:n,noTelemetry:ne.isErrorNoTelemetry(e)}}return e}let i4="Canceled";function i3(e){return e instanceof i6||e instanceof Error&&e.name===i4&&e.message===i4}class i6 extends Error{constructor(){super(i4),this.name=this.message}}function i9(e){return e?Error(`Illegal argument: ${e}`):Error("Illegal argument")}function i8(e){return e?Error(`Illegal state: ${e}`):Error("Illegal state")}class i7 extends Error{constructor(e){super("NotSupported"),e&&(this.message=e)}}class ne extends Error{constructor(e){super(e),this.name="CodeExpectedError"}static fromError(e){if(e instanceof ne)return e;let t=new ne;return t.message=e.message,t.stack=e.stack,t}static isErrorNoTelemetry(e){return"CodeExpectedError"===e.name}}class nt extends Error{constructor(e){super(e||"An unexpected bug occurred."),Object.setPrototypeOf(this,nt.prototype)}}function ni(e){let t;let i=this,n=!1;return function(){return n?t:(n=!0,t=e.apply(i,arguments))}}var nn=i(53725);function nr(e){return e}function no(e){}function ns(e,t){}function na(e){return e}function nl(e){if(nn.$.is(e)){let t=[];for(let i of e)if(i)try{i.dispose()}catch(e){t.push(e)}if(1===t.length)throw t[0];if(t.length>1)throw AggregateError(t,"Encountered errors while disposing of store");return Array.isArray(e)?[]:e}if(e)return e.dispose(),e}function nh(...e){let t=nu(()=>nl(e));return t}function nu(e){let t={dispose:ni(()=>{e()})};return t}class nd{constructor(){var e;this._toDispose=new Set,this._isDisposed=!1,e=this}dispose(){this._isDisposed||(this._isDisposed=!0,this.clear())}get isDisposed(){return this._isDisposed}clear(){if(0!==this._toDispose.size)try{nl(this._toDispose)}finally{this._toDispose.clear()}}add(e){if(!e)return e;if(e===this)throw Error("Cannot register a disposable on itself!");return this._isDisposed?nd.DISABLE_DISPOSED_WARNING||console.warn(Error("Trying to add a disposable to a DisposableStore that has already been disposed of. The added object will be leaked!").stack):this._toDispose.add(e),e}}nd.DISABLE_DISPOSED_WARNING=!1;class nc{constructor(){var e;this._store=new nd,e=this,this._store}dispose(){this._store.dispose()}_register(e){if(e===this)throw Error("Cannot register a disposable on itself!");return this._store.add(e)}}nc.None=Object.freeze({dispose(){}});class nf{constructor(){var e;this._isDisposed=!1,e=this}get value(){return this._isDisposed?void 0:this._value}set value(e){var t;this._isDisposed||e===this._value||(null===(t=this._value)||void 0===t||t.dispose(),this._value=e)}clear(){this.value=void 0}dispose(){var e;this._isDisposed=!0,null===(e=this._value)||void 0===e||e.dispose(),this._value=void 0}}class ng{constructor(e){this.object=e}dispose(){}}class np{constructor(){var e;this._store=new Map,this._isDisposed=!1,e=this}dispose(){this._isDisposed=!0,this.clearAndDisposeAll()}clearAndDisposeAll(){if(this._store.size)try{nl(this._store.values())}finally{this._store.clear()}}get(e){return this._store.get(e)}set(e,t,i=!1){var n;this._isDisposed&&console.warn(Error("Trying to add a disposable to a DisposableMap that has already been disposed of. The added object will be leaked!").stack),i||null===(n=this._store.get(e))||void 0===n||n.dispose(),this._store.set(e,t)}deleteAndDispose(e){var t;null===(t=this._store.get(e))||void 0===t||t.dispose(),this._store.delete(e)}[Symbol.iterator](){return this._store[Symbol.iterator]()}}var nm=i(91741);let n_=globalThis.performance&&"function"==typeof globalThis.performance.now;class nE{static create(e){return new nE(e)}constructor(e){this._now=n_&&!1===e?Date.now:globalThis.performance.now.bind(globalThis.performance),this._startTime=this._now(),this._stopTime=-1}stop(){this._stopTime=this._now()}elapsed(){return -1!==this._stopTime?this._stopTime-this._startTime:this._now()-this._startTime}}!function(e){function t(e){return(t,i=null,n)=>{let r,o=!1;return r=e(e=>o?void 0:(r?r.dispose():o=!0,t.call(i,e)),null,n),o&&r.dispose(),r}}function i(e,t,i){return s((i,n=null,r)=>e(e=>i.call(n,t(e)),null,r),i)}function n(e,t,i){return s((i,n=null,r)=>e(e=>{t(e),i.call(n,e)},null,r),i)}function r(e,t,i){return s((i,n=null,r)=>e(e=>t(e)&&i.call(n,e),null,r),i)}function o(e,t,n,r){let o=n;return i(e,e=>o=t(o,e),r)}function s(e,t){let i;let n=new ny({onWillAddFirstListener(){i=e(n.fire,n)},onDidRemoveLastListener(){null==i||i.dispose()}});return null==t||t.add(n),n.event}function a(e,t,i=100,n=!1,r=!1,o,s){let a,l,h,u;let d=0,c=new ny({leakWarningThreshold:o,onWillAddFirstListener(){a=e(e=>{d++,h=t(h,e),n&&!u&&(c.fire(h),h=void 0),l=()=>{let e=h;h=void 0,u=void 0,(!n||d>1)&&c.fire(e),d=0},"number"==typeof i?(clearTimeout(u),u=setTimeout(l,i)):void 0===u&&(u=0,queueMicrotask(l))})},onWillRemoveListener(){r&&d>0&&(null==l||l())},onDidRemoveLastListener(){l=void 0,a.dispose()}});return null==s||s.add(c),c.event}function l(e,t=(e,t)=>e===t,i){let n,o=!0;return r(e,e=>{let i=o||!t(e,n);return o=!1,n=e,i},i)}e.None=()=>nc.None,e.defer=function(e,t){return a(e,()=>void 0,0,void 0,!0,void 0,t)},e.once=t,e.map=i,e.forEach=n,e.filter=r,e.signal=function(e){return e},e.any=function(...e){return(t,i=null,n)=>nh(...e.map(e=>e(e=>t.call(i,e),null,n)))},e.reduce=o,e.debounce=a,e.accumulate=function(t,i=0,n){return e.debounce(t,(e,t)=>e?(e.push(t),e):[t],i,void 0,!0,void 0,n)},e.latch=l,e.split=function(t,i,n){return[e.filter(t,i,n),e.filter(t,e=>!i(e),n)]},e.buffer=function(e,t=!1,i=[]){let n=i.slice(),r=e(e=>{n?n.push(e):s.fire(e)}),o=()=>{null==n||n.forEach(e=>s.fire(e)),n=null},s=new ny({onWillAddFirstListener(){r||(r=e(e=>s.fire(e)))},onDidAddFirstListener(){n&&(t?setTimeout(o):o())},onDidRemoveLastListener(){r&&r.dispose(),r=null}});return s.event};class h{constructor(e){this.event=e,this.disposables=new nd}map(e){return new h(i(this.event,e,this.disposables))}forEach(e){return new h(n(this.event,e,this.disposables))}filter(e){return new h(r(this.event,e,this.disposables))}reduce(e,t){return new h(o(this.event,e,t,this.disposables))}latch(){return new h(l(this.event,void 0,this.disposables))}debounce(e,t=100,i=!1,n=!1,r){return new h(a(this.event,e,t,i,n,r,this.disposables))}on(e,t,i){return this.event(e,t,i)}once(e,i,n){return t(this.event)(e,i,n)}dispose(){this.disposables.dispose()}}e.chain=function(e){return new h(e)},e.fromNodeEventEmitter=function(e,t,i=e=>e){let n=(...e)=>r.fire(i(...e)),r=new ny({onWillAddFirstListener:()=>e.on(t,n),onDidRemoveLastListener:()=>e.removeListener(t,n)});return r.event},e.fromDOMEventEmitter=function(e,t,i=e=>e){let n=(...e)=>r.fire(i(...e)),r=new ny({onWillAddFirstListener:()=>e.addEventListener(t,n),onDidRemoveLastListener:()=>e.removeEventListener(t,n)});return r.event},e.toPromise=function(e){return new Promise(i=>t(e)(i))},e.runAndSubscribe=function(e,t){return t(void 0),e(e=>t(e))},e.runAndSubscribeWithStore=function(e,t){let i=null;function n(e){null==i||i.dispose(),t(e,i=new nd)}n(void 0);let r=e(e=>n(e));return nu(()=>{r.dispose(),null==i||i.dispose()})};class u{constructor(e,t){this._observable=e,this._counter=0,this._hasChanged=!1;this.emitter=new ny({onWillAddFirstListener:()=>{e.addObserver(this)},onDidRemoveLastListener:()=>{e.removeObserver(this)}}),t&&t.add(this.emitter)}beginUpdate(e){this._counter++}handlePossibleChange(e){}handleChange(e,t){this._hasChanged=!0}endUpdate(e){this._counter--,0===this._counter&&(this._observable.reportChanges(),this._hasChanged&&(this._hasChanged=!1,this.emitter.fire(this._observable.get())))}}e.fromObservable=function(e,t){let i=new u(e,t);return i.emitter.event},e.fromObservableLight=function(e){return t=>{let i=0,n=!1,r={beginUpdate(){i++},endUpdate(){0==--i&&(e.reportChanges(),n&&(n=!1,t()))},handlePossibleChange(){},handleChange(){n=!0}};return e.addObserver(r),e.reportChanges(),{dispose(){e.removeObserver(r)}}}}}(e8||(e8={}));class nv{constructor(e){this.listenerCount=0,this.invocationCount=0,this.elapsedOverall=0,this.durations=[],this.name=`${e}_${nv._idPool++}`,nv.all.add(this)}start(e){this._stopWatch=new nE,this.listenerCount=e}stop(){if(this._stopWatch){let e=this._stopWatch.elapsed();this.durations.push(e),this.elapsedOverall+=e,this.invocationCount+=1,this._stopWatch=void 0}}}nv.all=new Set,nv._idPool=0;class nb{constructor(e,t=Math.random().toString(18).slice(2,5)){this.threshold=e,this.name=t,this._warnCountdown=0}dispose(){var e;null===(e=this._stacks)||void 0===e||e.clear()}check(e,t){let i=this.threshold;if(i<=0||t{let t=this._stacks.get(e.value)||0;this._stacks.set(e.value,t-1)}}}class nC{static create(){var e;return new nC(null!==(e=Error().stack)&&void 0!==e?e:"")}constructor(e){this.value=e}print(){console.warn(this.value.split("\n").slice(2).join("\n"))}}class nS{constructor(e){this.value=e}}class ny{constructor(e){var t,i,n,r,o;this._size=0,this._options=e,this._leakageMon=(null===(t=this._options)||void 0===t?void 0:t.leakWarningThreshold)?new nb(null!==(n=null===(i=this._options)||void 0===i?void 0:i.leakWarningThreshold)&&void 0!==n?n:-1):void 0,this._perfMon=(null===(r=this._options)||void 0===r?void 0:r._profName)?new nv(this._options._profName):void 0,this._deliveryQueue=null===(o=this._options)||void 0===o?void 0:o.deliveryQueue}dispose(){var e,t,i,n;this._disposed||(this._disposed=!0,(null===(e=this._deliveryQueue)||void 0===e?void 0:e.current)===this&&this._deliveryQueue.reset(),this._listeners&&(this._listeners=void 0,this._size=0),null===(i=null===(t=this._options)||void 0===t?void 0:t.onDidRemoveLastListener)||void 0===i||i.call(t),null===(n=this._leakageMon)||void 0===n||n.dispose())}get event(){var e;return null!==(e=this._event)&&void 0!==e||(this._event=(e,t,i)=>{var n,r,o,s,a;let l;if(this._leakageMon&&this._size>3*this._leakageMon.threshold)return console.warn(`[${this._leakageMon.name}] REFUSES to accept new listeners because it exceeded its threshold by far`),nc.None;if(this._disposed)return nc.None;t&&(e=e.bind(t));let h=new nS(e);this._leakageMon&&this._size>=Math.ceil(.2*this._leakageMon.threshold)&&(h.stack=nC.create(),l=this._leakageMon.check(h.stack,this._size+1)),this._listeners?this._listeners instanceof nS?(null!==(a=this._deliveryQueue)&&void 0!==a||(this._deliveryQueue=new nR),this._listeners=[this._listeners,h]):this._listeners.push(h):(null===(r=null===(n=this._options)||void 0===n?void 0:n.onWillAddFirstListener)||void 0===r||r.call(n,this),this._listeners=h,null===(s=null===(o=this._options)||void 0===o?void 0:o.onDidAddFirstListener)||void 0===s||s.call(o,this)),this._size++;let u=nu(()=>{null==l||l(),this._removeListener(h)});return i instanceof nd?i.add(u):Array.isArray(i)&&i.push(u),u}),this._event}_removeListener(e){var t,i,n,r;if(null===(i=null===(t=this._options)||void 0===t?void 0:t.onWillRemoveListener)||void 0===i||i.call(t,this),!this._listeners)return;if(1===this._size){this._listeners=void 0,null===(r=null===(n=this._options)||void 0===n?void 0:n.onDidRemoveLastListener)||void 0===r||r.call(n,this),this._size=0;return}let o=this._listeners,s=o.indexOf(e);if(-1===s)throw console.log("disposed?",this._disposed),console.log("size?",this._size),console.log("arr?",JSON.stringify(this._listeners)),Error("Attempted to dispose unknown listener");this._size--,o[s]=void 0;let a=this._deliveryQueue.current===this;if(2*this._size<=o.length){let e=0;for(let t=0;t0}}let nT=()=>new nR;class nR{constructor(){this.i=-1,this.end=0}enqueue(e,t,i){this.i=0,this.end=i,this.current=e,this.value=t}reset(){this.i=this.end,this.current=void 0,this.value=void 0}}class nA extends ny{constructor(e){super(e),this._isPaused=0,this._eventQueue=new nm.S,this._mergeFn=null==e?void 0:e.merge}pause(){this._isPaused++}resume(){if(0!==this._isPaused&&0==--this._isPaused){if(this._mergeFn){if(this._eventQueue.size>0){let e=Array.from(this._eventQueue);this._eventQueue.clear(),super.fire(this._mergeFn(e))}}else for(;!this._isPaused&&0!==this._eventQueue.size;)super.fire(this._eventQueue.shift())}}fire(e){this._size&&(0!==this._isPaused?this._eventQueue.push(e):super.fire(e))}}class nN extends nA{constructor(e){var t;super(e),this._delay=null!==(t=e.delay)&&void 0!==t?t:100}fire(e){this._handle||(this.pause(),this._handle=setTimeout(()=>{this._handle=void 0,this.resume()},this._delay)),super.fire(e)}}class nO extends ny{constructor(e){super(e),this._queuedEvents=[],this._mergeFn=null==e?void 0:e.merge}fire(e){this.hasListeners()&&(this._queuedEvents.push(e),1===this._queuedEvents.length&&queueMicrotask(()=>{this._mergeFn?super.fire(this._mergeFn(this._queuedEvents)):this._queuedEvents.forEach(e=>super.fire(e)),this._queuedEvents=[]}))}}class nL{constructor(){this.buffers=[]}wrapEvent(e){return(t,i,n)=>e(e=>{let n=this.buffers[this.buffers.length-1];n?n.push(()=>t.call(i,e)):t.call(i,e)},void 0,n)}bufferEvents(e){let t=[];this.buffers.push(t);let i=e();return this.buffers.pop(),t.forEach(e=>e()),i}}class nI{constructor(){this.listening=!1,this.inputEvent=e8.None,this.inputEventListener=nc.None,this.emitter=new ny({onDidAddFirstListener:()=>{this.listening=!0,this.inputEventListener=this.inputEvent(this.emitter.fire,this.emitter)},onDidRemoveLastListener:()=>{this.listening=!1,this.inputEventListener.dispose()}}),this.event=this.emitter.event}set input(e){this.inputEvent=e,this.listening&&(this.inputEventListener.dispose(),this.inputEventListener=e(this.emitter.fire,this.emitter))}dispose(){this.inputEventListener.dispose(),this.emitter.dispose()}}let nw=Object.freeze(function(e,t){let i=setTimeout(e.bind(t),0);return{dispose(){clearTimeout(i)}}});(S=e7||(e7={})).isCancellationToken=function(e){return e===S.None||e===S.Cancelled||e instanceof nD||!!e&&"object"==typeof e&&"boolean"==typeof e.isCancellationRequested&&"function"==typeof e.onCancellationRequested},S.None=Object.freeze({isCancellationRequested:!1,onCancellationRequested:e8.None}),S.Cancelled=Object.freeze({isCancellationRequested:!0,onCancellationRequested:nw});class nD{constructor(){this._isCancelled=!1,this._emitter=null}cancel(){!this._isCancelled&&(this._isCancelled=!0,this._emitter&&(this._emitter.fire(void 0),this.dispose()))}get isCancellationRequested(){return this._isCancelled}get onCancellationRequested(){return this._isCancelled?nw:(this._emitter||(this._emitter=new ny),this._emitter.event)}dispose(){this._emitter&&(this._emitter.dispose(),this._emitter=null)}}class nx{constructor(e){this._token=void 0,this._parentListener=void 0,this._parentListener=e&&e.onCancellationRequested(this.cancel,this)}get token(){return this._token||(this._token=new nD),this._token}cancel(){this._token?this._token instanceof nD&&this._token.cancel():this._token=e7.Cancelled}dispose(e=!1){var t;e&&this.cancel(),null===(t=this._parentListener)||void 0===t||t.dispose(),this._token?this._token instanceof nD&&this._token.dispose():this._token=e7.None}}class nM{constructor(){this._keyCodeToStr=[],this._strToKeyCode=Object.create(null)}define(e,t){this._keyCodeToStr[e]=t,this._strToKeyCode[t.toLowerCase()]=e}keyCodeToStr(e){return this._keyCodeToStr[e]}strToKeyCode(e){return this._strToKeyCode[e.toLowerCase()]||0}}let nk=new nM,nP=new nM,nF=new nM,nB=Array(230),nU={},nH=[],nV=Object.create(null),nW=Object.create(null),nG=[],nj=[];for(let e=0;e<=193;e++)nG[e]=-1;for(let e=0;e<=132;e++)nj[e]=-1;!function(){let e=[],t=[];for(let i of[[1,0,"None",0,"unknown",0,"VK_UNKNOWN","",""],[1,1,"Hyper",0,"",0,"","",""],[1,2,"Super",0,"",0,"","",""],[1,3,"Fn",0,"",0,"","",""],[1,4,"FnLock",0,"",0,"","",""],[1,5,"Suspend",0,"",0,"","",""],[1,6,"Resume",0,"",0,"","",""],[1,7,"Turbo",0,"",0,"","",""],[1,8,"Sleep",0,"",0,"VK_SLEEP","",""],[1,9,"WakeUp",0,"",0,"","",""],[0,10,"KeyA",31,"A",65,"VK_A","",""],[0,11,"KeyB",32,"B",66,"VK_B","",""],[0,12,"KeyC",33,"C",67,"VK_C","",""],[0,13,"KeyD",34,"D",68,"VK_D","",""],[0,14,"KeyE",35,"E",69,"VK_E","",""],[0,15,"KeyF",36,"F",70,"VK_F","",""],[0,16,"KeyG",37,"G",71,"VK_G","",""],[0,17,"KeyH",38,"H",72,"VK_H","",""],[0,18,"KeyI",39,"I",73,"VK_I","",""],[0,19,"KeyJ",40,"J",74,"VK_J","",""],[0,20,"KeyK",41,"K",75,"VK_K","",""],[0,21,"KeyL",42,"L",76,"VK_L","",""],[0,22,"KeyM",43,"M",77,"VK_M","",""],[0,23,"KeyN",44,"N",78,"VK_N","",""],[0,24,"KeyO",45,"O",79,"VK_O","",""],[0,25,"KeyP",46,"P",80,"VK_P","",""],[0,26,"KeyQ",47,"Q",81,"VK_Q","",""],[0,27,"KeyR",48,"R",82,"VK_R","",""],[0,28,"KeyS",49,"S",83,"VK_S","",""],[0,29,"KeyT",50,"T",84,"VK_T","",""],[0,30,"KeyU",51,"U",85,"VK_U","",""],[0,31,"KeyV",52,"V",86,"VK_V","",""],[0,32,"KeyW",53,"W",87,"VK_W","",""],[0,33,"KeyX",54,"X",88,"VK_X","",""],[0,34,"KeyY",55,"Y",89,"VK_Y","",""],[0,35,"KeyZ",56,"Z",90,"VK_Z","",""],[0,36,"Digit1",22,"1",49,"VK_1","",""],[0,37,"Digit2",23,"2",50,"VK_2","",""],[0,38,"Digit3",24,"3",51,"VK_3","",""],[0,39,"Digit4",25,"4",52,"VK_4","",""],[0,40,"Digit5",26,"5",53,"VK_5","",""],[0,41,"Digit6",27,"6",54,"VK_6","",""],[0,42,"Digit7",28,"7",55,"VK_7","",""],[0,43,"Digit8",29,"8",56,"VK_8","",""],[0,44,"Digit9",30,"9",57,"VK_9","",""],[0,45,"Digit0",21,"0",48,"VK_0","",""],[1,46,"Enter",3,"Enter",13,"VK_RETURN","",""],[1,47,"Escape",9,"Escape",27,"VK_ESCAPE","",""],[1,48,"Backspace",1,"Backspace",8,"VK_BACK","",""],[1,49,"Tab",2,"Tab",9,"VK_TAB","",""],[1,50,"Space",10,"Space",32,"VK_SPACE","",""],[0,51,"Minus",88,"-",189,"VK_OEM_MINUS","-","OEM_MINUS"],[0,52,"Equal",86,"=",187,"VK_OEM_PLUS","=","OEM_PLUS"],[0,53,"BracketLeft",92,"[",219,"VK_OEM_4","[","OEM_4"],[0,54,"BracketRight",94,"]",221,"VK_OEM_6","]","OEM_6"],[0,55,"Backslash",93,"\\",220,"VK_OEM_5","\\","OEM_5"],[0,56,"IntlHash",0,"",0,"","",""],[0,57,"Semicolon",85,";",186,"VK_OEM_1",";","OEM_1"],[0,58,"Quote",95,"'",222,"VK_OEM_7","'","OEM_7"],[0,59,"Backquote",91,"`",192,"VK_OEM_3","`","OEM_3"],[0,60,"Comma",87,",",188,"VK_OEM_COMMA",",","OEM_COMMA"],[0,61,"Period",89,".",190,"VK_OEM_PERIOD",".","OEM_PERIOD"],[0,62,"Slash",90,"/",191,"VK_OEM_2","/","OEM_2"],[1,63,"CapsLock",8,"CapsLock",20,"VK_CAPITAL","",""],[1,64,"F1",59,"F1",112,"VK_F1","",""],[1,65,"F2",60,"F2",113,"VK_F2","",""],[1,66,"F3",61,"F3",114,"VK_F3","",""],[1,67,"F4",62,"F4",115,"VK_F4","",""],[1,68,"F5",63,"F5",116,"VK_F5","",""],[1,69,"F6",64,"F6",117,"VK_F6","",""],[1,70,"F7",65,"F7",118,"VK_F7","",""],[1,71,"F8",66,"F8",119,"VK_F8","",""],[1,72,"F9",67,"F9",120,"VK_F9","",""],[1,73,"F10",68,"F10",121,"VK_F10","",""],[1,74,"F11",69,"F11",122,"VK_F11","",""],[1,75,"F12",70,"F12",123,"VK_F12","",""],[1,76,"PrintScreen",0,"",0,"","",""],[1,77,"ScrollLock",84,"ScrollLock",145,"VK_SCROLL","",""],[1,78,"Pause",7,"PauseBreak",19,"VK_PAUSE","",""],[1,79,"Insert",19,"Insert",45,"VK_INSERT","",""],[1,80,"Home",14,"Home",36,"VK_HOME","",""],[1,81,"PageUp",11,"PageUp",33,"VK_PRIOR","",""],[1,82,"Delete",20,"Delete",46,"VK_DELETE","",""],[1,83,"End",13,"End",35,"VK_END","",""],[1,84,"PageDown",12,"PageDown",34,"VK_NEXT","",""],[1,85,"ArrowRight",17,"RightArrow",39,"VK_RIGHT","Right",""],[1,86,"ArrowLeft",15,"LeftArrow",37,"VK_LEFT","Left",""],[1,87,"ArrowDown",18,"DownArrow",40,"VK_DOWN","Down",""],[1,88,"ArrowUp",16,"UpArrow",38,"VK_UP","Up",""],[1,89,"NumLock",83,"NumLock",144,"VK_NUMLOCK","",""],[1,90,"NumpadDivide",113,"NumPad_Divide",111,"VK_DIVIDE","",""],[1,91,"NumpadMultiply",108,"NumPad_Multiply",106,"VK_MULTIPLY","",""],[1,92,"NumpadSubtract",111,"NumPad_Subtract",109,"VK_SUBTRACT","",""],[1,93,"NumpadAdd",109,"NumPad_Add",107,"VK_ADD","",""],[1,94,"NumpadEnter",3,"",0,"","",""],[1,95,"Numpad1",99,"NumPad1",97,"VK_NUMPAD1","",""],[1,96,"Numpad2",100,"NumPad2",98,"VK_NUMPAD2","",""],[1,97,"Numpad3",101,"NumPad3",99,"VK_NUMPAD3","",""],[1,98,"Numpad4",102,"NumPad4",100,"VK_NUMPAD4","",""],[1,99,"Numpad5",103,"NumPad5",101,"VK_NUMPAD5","",""],[1,100,"Numpad6",104,"NumPad6",102,"VK_NUMPAD6","",""],[1,101,"Numpad7",105,"NumPad7",103,"VK_NUMPAD7","",""],[1,102,"Numpad8",106,"NumPad8",104,"VK_NUMPAD8","",""],[1,103,"Numpad9",107,"NumPad9",105,"VK_NUMPAD9","",""],[1,104,"Numpad0",98,"NumPad0",96,"VK_NUMPAD0","",""],[1,105,"NumpadDecimal",112,"NumPad_Decimal",110,"VK_DECIMAL","",""],[0,106,"IntlBackslash",97,"OEM_102",226,"VK_OEM_102","",""],[1,107,"ContextMenu",58,"ContextMenu",93,"","",""],[1,108,"Power",0,"",0,"","",""],[1,109,"NumpadEqual",0,"",0,"","",""],[1,110,"F13",71,"F13",124,"VK_F13","",""],[1,111,"F14",72,"F14",125,"VK_F14","",""],[1,112,"F15",73,"F15",126,"VK_F15","",""],[1,113,"F16",74,"F16",127,"VK_F16","",""],[1,114,"F17",75,"F17",128,"VK_F17","",""],[1,115,"F18",76,"F18",129,"VK_F18","",""],[1,116,"F19",77,"F19",130,"VK_F19","",""],[1,117,"F20",78,"F20",131,"VK_F20","",""],[1,118,"F21",79,"F21",132,"VK_F21","",""],[1,119,"F22",80,"F22",133,"VK_F22","",""],[1,120,"F23",81,"F23",134,"VK_F23","",""],[1,121,"F24",82,"F24",135,"VK_F24","",""],[1,122,"Open",0,"",0,"","",""],[1,123,"Help",0,"",0,"","",""],[1,124,"Select",0,"",0,"","",""],[1,125,"Again",0,"",0,"","",""],[1,126,"Undo",0,"",0,"","",""],[1,127,"Cut",0,"",0,"","",""],[1,128,"Copy",0,"",0,"","",""],[1,129,"Paste",0,"",0,"","",""],[1,130,"Find",0,"",0,"","",""],[1,131,"AudioVolumeMute",117,"AudioVolumeMute",173,"VK_VOLUME_MUTE","",""],[1,132,"AudioVolumeUp",118,"AudioVolumeUp",175,"VK_VOLUME_UP","",""],[1,133,"AudioVolumeDown",119,"AudioVolumeDown",174,"VK_VOLUME_DOWN","",""],[1,134,"NumpadComma",110,"NumPad_Separator",108,"VK_SEPARATOR","",""],[0,135,"IntlRo",115,"ABNT_C1",193,"VK_ABNT_C1","",""],[1,136,"KanaMode",0,"",0,"","",""],[0,137,"IntlYen",0,"",0,"","",""],[1,138,"Convert",0,"",0,"","",""],[1,139,"NonConvert",0,"",0,"","",""],[1,140,"Lang1",0,"",0,"","",""],[1,141,"Lang2",0,"",0,"","",""],[1,142,"Lang3",0,"",0,"","",""],[1,143,"Lang4",0,"",0,"","",""],[1,144,"Lang5",0,"",0,"","",""],[1,145,"Abort",0,"",0,"","",""],[1,146,"Props",0,"",0,"","",""],[1,147,"NumpadParenLeft",0,"",0,"","",""],[1,148,"NumpadParenRight",0,"",0,"","",""],[1,149,"NumpadBackspace",0,"",0,"","",""],[1,150,"NumpadMemoryStore",0,"",0,"","",""],[1,151,"NumpadMemoryRecall",0,"",0,"","",""],[1,152,"NumpadMemoryClear",0,"",0,"","",""],[1,153,"NumpadMemoryAdd",0,"",0,"","",""],[1,154,"NumpadMemorySubtract",0,"",0,"","",""],[1,155,"NumpadClear",131,"Clear",12,"VK_CLEAR","",""],[1,156,"NumpadClearEntry",0,"",0,"","",""],[1,0,"",5,"Ctrl",17,"VK_CONTROL","",""],[1,0,"",4,"Shift",16,"VK_SHIFT","",""],[1,0,"",6,"Alt",18,"VK_MENU","",""],[1,0,"",57,"Meta",91,"VK_COMMAND","",""],[1,157,"ControlLeft",5,"",0,"VK_LCONTROL","",""],[1,158,"ShiftLeft",4,"",0,"VK_LSHIFT","",""],[1,159,"AltLeft",6,"",0,"VK_LMENU","",""],[1,160,"MetaLeft",57,"",0,"VK_LWIN","",""],[1,161,"ControlRight",5,"",0,"VK_RCONTROL","",""],[1,162,"ShiftRight",4,"",0,"VK_RSHIFT","",""],[1,163,"AltRight",6,"",0,"VK_RMENU","",""],[1,164,"MetaRight",57,"",0,"VK_RWIN","",""],[1,165,"BrightnessUp",0,"",0,"","",""],[1,166,"BrightnessDown",0,"",0,"","",""],[1,167,"MediaPlay",0,"",0,"","",""],[1,168,"MediaRecord",0,"",0,"","",""],[1,169,"MediaFastForward",0,"",0,"","",""],[1,170,"MediaRewind",0,"",0,"","",""],[1,171,"MediaTrackNext",124,"MediaTrackNext",176,"VK_MEDIA_NEXT_TRACK","",""],[1,172,"MediaTrackPrevious",125,"MediaTrackPrevious",177,"VK_MEDIA_PREV_TRACK","",""],[1,173,"MediaStop",126,"MediaStop",178,"VK_MEDIA_STOP","",""],[1,174,"Eject",0,"",0,"","",""],[1,175,"MediaPlayPause",127,"MediaPlayPause",179,"VK_MEDIA_PLAY_PAUSE","",""],[1,176,"MediaSelect",128,"LaunchMediaPlayer",181,"VK_MEDIA_LAUNCH_MEDIA_SELECT","",""],[1,177,"LaunchMail",129,"LaunchMail",180,"VK_MEDIA_LAUNCH_MAIL","",""],[1,178,"LaunchApp2",130,"LaunchApp2",183,"VK_MEDIA_LAUNCH_APP2","",""],[1,179,"LaunchApp1",0,"",0,"VK_MEDIA_LAUNCH_APP1","",""],[1,180,"SelectTask",0,"",0,"","",""],[1,181,"LaunchScreenSaver",0,"",0,"","",""],[1,182,"BrowserSearch",120,"BrowserSearch",170,"VK_BROWSER_SEARCH","",""],[1,183,"BrowserHome",121,"BrowserHome",172,"VK_BROWSER_HOME","",""],[1,184,"BrowserBack",122,"BrowserBack",166,"VK_BROWSER_BACK","",""],[1,185,"BrowserForward",123,"BrowserForward",167,"VK_BROWSER_FORWARD","",""],[1,186,"BrowserStop",0,"",0,"VK_BROWSER_STOP","",""],[1,187,"BrowserRefresh",0,"",0,"VK_BROWSER_REFRESH","",""],[1,188,"BrowserFavorites",0,"",0,"VK_BROWSER_FAVORITES","",""],[1,189,"ZoomToggle",0,"",0,"","",""],[1,190,"MailReply",0,"",0,"","",""],[1,191,"MailForward",0,"",0,"","",""],[1,192,"MailSend",0,"",0,"","",""],[1,0,"",114,"KeyInComposition",229,"","",""],[1,0,"",116,"ABNT_C2",194,"VK_ABNT_C2","",""],[1,0,"",96,"OEM_8",223,"VK_OEM_8","",""],[1,0,"",0,"",0,"VK_KANA","",""],[1,0,"",0,"",0,"VK_HANGUL","",""],[1,0,"",0,"",0,"VK_JUNJA","",""],[1,0,"",0,"",0,"VK_FINAL","",""],[1,0,"",0,"",0,"VK_HANJA","",""],[1,0,"",0,"",0,"VK_KANJI","",""],[1,0,"",0,"",0,"VK_CONVERT","",""],[1,0,"",0,"",0,"VK_NONCONVERT","",""],[1,0,"",0,"",0,"VK_ACCEPT","",""],[1,0,"",0,"",0,"VK_MODECHANGE","",""],[1,0,"",0,"",0,"VK_SELECT","",""],[1,0,"",0,"",0,"VK_PRINT","",""],[1,0,"",0,"",0,"VK_EXECUTE","",""],[1,0,"",0,"",0,"VK_SNAPSHOT","",""],[1,0,"",0,"",0,"VK_HELP","",""],[1,0,"",0,"",0,"VK_APPS","",""],[1,0,"",0,"",0,"VK_PROCESSKEY","",""],[1,0,"",0,"",0,"VK_PACKET","",""],[1,0,"",0,"",0,"VK_DBE_SBCSCHAR","",""],[1,0,"",0,"",0,"VK_DBE_DBCSCHAR","",""],[1,0,"",0,"",0,"VK_ATTN","",""],[1,0,"",0,"",0,"VK_CRSEL","",""],[1,0,"",0,"",0,"VK_EXSEL","",""],[1,0,"",0,"",0,"VK_EREOF","",""],[1,0,"",0,"",0,"VK_PLAY","",""],[1,0,"",0,"",0,"VK_ZOOM","",""],[1,0,"",0,"",0,"VK_NONAME","",""],[1,0,"",0,"",0,"VK_PA1","",""],[1,0,"",0,"",0,"VK_OEM_CLEAR","",""]]){let[n,r,o,s,a,l,h,u,d]=i;if(!t[r]&&(t[r]=!0,nH[r]=o,nV[o]=r,nW[o.toLowerCase()]=r,n&&(nG[r]=s,0!==s&&3!==s&&5!==s&&4!==s&&6!==s&&57!==s&&(nj[s]=r))),!e[s]){if(e[s]=!0,!a)throw Error(`String representation missing for key code ${s} around scan code ${o}`);nk.define(s,a),nP.define(s,u||a),nF.define(s,d||u||a)}l&&(nB[l]=s),h&&(nU[h]=s)}nj[3]=46}(),(y=te||(te={})).toString=function(e){return nk.keyCodeToStr(e)},y.fromString=function(e){return nk.strToKeyCode(e)},y.toUserSettingsUS=function(e){return nP.keyCodeToStr(e)},y.toUserSettingsGeneral=function(e){return nF.keyCodeToStr(e)},y.fromUserSettings=function(e){return nP.strToKeyCode(e)||nF.strToKeyCode(e)},y.toElectronAccelerator=function(e){if(e>=98&&e<=113)return null;switch(e){case 16:return"Up";case 18:return"Down";case 15:return"Left";case 17:return"Right"}return nk.keyCodeToStr(e)};var nz=i(1432),nK=i(83454);if(void 0!==nz.li.vscode&&void 0!==nz.li.vscode.process){let e=nz.li.vscode.process;n={get platform(){return e.platform},get arch(){return e.arch},get env(){return e.env},cwd:()=>e.cwd()}}else n=void 0!==nK?{get platform(){return nK.platform},get arch(){return nK.arch},get env(){return nK.env},cwd:()=>nK.env.VSCODE_CWD||nK.cwd()}:{get platform(){return nz.ED?"win32":nz.dz?"darwin":"linux"},get arch(){return},get env(){return{}},cwd:()=>"/"};let nY=n.cwd,n$=n.env,nq=n.platform;class nX extends Error{constructor(e,t,i){let n;"string"==typeof t&&0===t.indexOf("not ")?(n="must not be",t=t.replace(/^not /,"")):n="must be";let r=-1!==e.indexOf(".")?"property":"argument",o=`The "${e}" ${r} ${n} of type ${t}`;super(o+=`. Received type ${typeof i}`),this.code="ERR_INVALID_ARG_TYPE"}}function nZ(e,t){if("string"!=typeof e)throw new nX(t,"string",e)}let nQ="win32"===nq;function nJ(e){return 47===e||92===e}function n0(e){return 47===e}function n1(e){return e>=65&&e<=90||e>=97&&e<=122}function n2(e,t,i,n){let r="",o=0,s=-1,a=0,l=0;for(let h=0;h<=e.length;++h){if(h2){let e=r.lastIndexOf(i);-1===e?(r="",o=0):o=(r=r.slice(0,e)).length-1-r.lastIndexOf(i),s=h,a=0;continue}if(0!==r.length){r="",o=0,s=h,a=0;continue}}t&&(r+=r.length>0?`${i}..`:"..",o=2)}else r.length>0?r+=`${i}${e.slice(s+1,h)}`:r=e.slice(s+1,h),o=h-s-1;s=h,a=0}else 46===l&&-1!==a?++a:a=-1}return r}function n5(e,t){!function(e,t){if(null===e||"object"!=typeof e)throw new nX(t,"Object",e)}(t,"pathObject");let i=t.dir||t.root,n=t.base||`${t.name||""}${t.ext||""}`;return i?i===t.root?`${i}${n}`:`${i}${e}${n}`:n}let n4={resolve(...e){let t="",i="",n=!1;for(let r=e.length-1;r>=-1;r--){let o;if(r>=0){if(nZ(o=e[r],"path"),0===o.length)continue}else 0===t.length?o=nY():(void 0===(o=n$[`=${t}`]||nY())||o.slice(0,2).toLowerCase()!==t.toLowerCase()&&92===o.charCodeAt(2))&&(o=`${t}\\`);let s=o.length,a=0,l="",h=!1,u=o.charCodeAt(0);if(1===s)nJ(u)&&(a=1,h=!0);else if(nJ(u)){if(h=!0,nJ(o.charCodeAt(1))){let e=2,t=2;for(;e2&&nJ(o.charCodeAt(2))&&(h=!0,a=3));if(l.length>0){if(t.length>0){if(l.toLowerCase()!==t.toLowerCase())continue}else t=l}if(n){if(t.length>0)break}else if(i=`${o.slice(a)}\\${i}`,n=h,h&&t.length>0)break}return i=n2(i,!n,"\\",nJ),n?`${t}\\${i}`:`${t}${i}`||"."},normalize(e){let t;nZ(e,"path");let i=e.length;if(0===i)return".";let n=0,r=!1,o=e.charCodeAt(0);if(1===i)return n0(o)?"\\":e;if(nJ(o)){if(r=!0,nJ(e.charCodeAt(1))){let r=2,o=2;for(;r2&&nJ(e.charCodeAt(2))&&(r=!0,n=3));let s=n0&&nJ(e.charCodeAt(i-1))&&(s+="\\"),void 0===t)?r?`\\${s}`:s:r?`${t}\\${s}`:`${t}${s}`},isAbsolute(e){nZ(e,"path");let t=e.length;if(0===t)return!1;let i=e.charCodeAt(0);return nJ(i)||t>2&&n1(i)&&58===e.charCodeAt(1)&&nJ(e.charCodeAt(2))},join(...e){let t,i;if(0===e.length)return".";for(let n=0;n0&&(void 0===t?t=i=r:t+=`\\${r}`)}if(void 0===t)return".";let n=!0,r=0;if("string"==typeof i&&nJ(i.charCodeAt(0))){++r;let e=i.length;e>1&&nJ(i.charCodeAt(1))&&(++r,e>2&&(nJ(i.charCodeAt(2))?++r:n=!1))}if(n){for(;r=2&&(t=`\\${t.slice(r)}`)}return n4.normalize(t)},relative(e,t){if(nZ(e,"from"),nZ(t,"to"),e===t)return"";let i=n4.resolve(e),n=n4.resolve(t);if(i===n||(e=i.toLowerCase())===(t=n.toLowerCase()))return"";let r=0;for(;rr&&92===e.charCodeAt(o-1);)o--;let s=o-r,a=0;for(;aa&&92===t.charCodeAt(l-1);)l--;let h=l-a,u=su){if(92===t.charCodeAt(a+c))return n.slice(a+c+1);if(2===c)return n.slice(a+c)}s>u&&(92===e.charCodeAt(r+c)?d=c:2===c&&(d=3)),-1===d&&(d=0)}let f="";for(c=r+d+1;c<=o;++c)(c===o||92===e.charCodeAt(c))&&(f+=0===f.length?"..":"\\..");return(a+=d,f.length>0)?`${f}${n.slice(a,l)}`:(92===n.charCodeAt(a)&&++a,n.slice(a,l))},toNamespacedPath(e){if("string"!=typeof e||0===e.length)return e;let t=n4.resolve(e);if(t.length<=2)return e;if(92===t.charCodeAt(0)){if(92===t.charCodeAt(1)){let e=t.charCodeAt(2);if(63!==e&&46!==e)return`\\\\?\\UNC\\${t.slice(2)}`}}else if(n1(t.charCodeAt(0))&&58===t.charCodeAt(1)&&92===t.charCodeAt(2))return`\\\\?\\${t}`;return e},dirname(e){nZ(e,"path");let t=e.length;if(0===t)return".";let i=-1,n=0,r=e.charCodeAt(0);if(1===t)return nJ(r)?e:".";if(nJ(r)){if(i=n=1,nJ(e.charCodeAt(1))){let r=2,o=2;for(;r2&&nJ(e.charCodeAt(2))?3:2);let o=-1,s=!0;for(let i=t-1;i>=n;--i)if(nJ(e.charCodeAt(i))){if(!s){o=i;break}}else s=!1;if(-1===o){if(-1===i)return".";o=i}return e.slice(0,o)},basename(e,t){let i;void 0!==t&&nZ(t,"ext"),nZ(e,"path");let n=0,r=-1,o=!0;if(e.length>=2&&n1(e.charCodeAt(0))&&58===e.charCodeAt(1)&&(n=2),void 0!==t&&t.length>0&&t.length<=e.length){if(t===e)return"";let s=t.length-1,a=-1;for(i=e.length-1;i>=n;--i){let l=e.charCodeAt(i);if(nJ(l)){if(!o){n=i+1;break}}else -1===a&&(o=!1,a=i+1),s>=0&&(l===t.charCodeAt(s)?-1==--s&&(r=i):(s=-1,r=a))}return n===r?r=a:-1===r&&(r=e.length),e.slice(n,r)}for(i=e.length-1;i>=n;--i)if(nJ(e.charCodeAt(i))){if(!o){n=i+1;break}}else -1===r&&(o=!1,r=i+1);return -1===r?"":e.slice(n,r)},extname(e){nZ(e,"path");let t=0,i=-1,n=0,r=-1,o=!0,s=0;e.length>=2&&58===e.charCodeAt(1)&&n1(e.charCodeAt(0))&&(t=n=2);for(let a=e.length-1;a>=t;--a){let t=e.charCodeAt(a);if(nJ(t)){if(!o){n=a+1;break}continue}-1===r&&(o=!1,r=a+1),46===t?-1===i?i=a:1!==s&&(s=1):-1!==i&&(s=-1)}return -1===i||-1===r||0===s||1===s&&i===r-1&&i===n+1?"":e.slice(i,r)},format:n5.bind(null,"\\"),parse(e){nZ(e,"path");let t={root:"",dir:"",base:"",ext:"",name:""};if(0===e.length)return t;let i=e.length,n=0,r=e.charCodeAt(0);if(1===i)return nJ(r)?(t.root=t.dir=e,t):(t.base=t.name=e,t);if(nJ(r)){if(n=1,nJ(e.charCodeAt(1))){let t=2,r=2;for(;t0&&(t.root=e.slice(0,n));let o=-1,s=n,a=-1,l=!0,h=e.length-1,u=0;for(;h>=n;--h){if(nJ(r=e.charCodeAt(h))){if(!l){s=h+1;break}continue}-1===a&&(l=!1,a=h+1),46===r?-1===o?o=h:1!==u&&(u=1):-1!==o&&(u=-1)}return -1!==a&&(-1===o||0===u||1===u&&o===a-1&&o===s+1?t.base=t.name=e.slice(s,a):(t.name=e.slice(s,o),t.base=e.slice(s,a),t.ext=e.slice(o,a))),s>0&&s!==n?t.dir=e.slice(0,s-1):t.dir=t.root,t},sep:"\\",delimiter:";",win32:null,posix:null},n3=(()=>{if(nQ){let e=/\\/g;return()=>{let t=nY().replace(e,"/");return t.slice(t.indexOf("/"))}}return()=>nY()})(),n6={resolve(...e){let t="",i=!1;for(let n=e.length-1;n>=-1&&!i;n--){let r=n>=0?e[n]:n3();nZ(r,"path"),0!==r.length&&(t=`${r}/${t}`,i=47===r.charCodeAt(0))}return(t=n2(t,!i,"/",n0),i)?`/${t}`:t.length>0?t:"."},normalize(e){if(nZ(e,"path"),0===e.length)return".";let t=47===e.charCodeAt(0),i=47===e.charCodeAt(e.length-1);return 0===(e=n2(e,!t,"/",n0)).length?t?"/":i?"./":".":(i&&(e+="/"),t?`/${e}`:e)},isAbsolute:e=>(nZ(e,"path"),e.length>0&&47===e.charCodeAt(0)),join(...e){let t;if(0===e.length)return".";for(let i=0;i0&&(void 0===t?t=n:t+=`/${n}`)}return void 0===t?".":n6.normalize(t)},relative(e,t){if(nZ(e,"from"),nZ(t,"to"),e===t||(e=n6.resolve(e))===(t=n6.resolve(t)))return"";let i=e.length,n=i-1,r=t.length-1,o=no){if(47===t.charCodeAt(1+a))return t.slice(1+a+1);if(0===a)return t.slice(1+a)}else n>o&&(47===e.charCodeAt(1+a)?s=a:0===a&&(s=0))}let l="";for(a=1+s+1;a<=i;++a)(a===i||47===e.charCodeAt(a))&&(l+=0===l.length?"..":"/..");return`${l}${t.slice(1+s)}`},toNamespacedPath:e=>e,dirname(e){if(nZ(e,"path"),0===e.length)return".";let t=47===e.charCodeAt(0),i=-1,n=!0;for(let t=e.length-1;t>=1;--t)if(47===e.charCodeAt(t)){if(!n){i=t;break}}else n=!1;return -1===i?t?"/":".":t&&1===i?"//":e.slice(0,i)},basename(e,t){let i;void 0!==t&&nZ(t,"ext"),nZ(e,"path");let n=0,r=-1,o=!0;if(void 0!==t&&t.length>0&&t.length<=e.length){if(t===e)return"";let s=t.length-1,a=-1;for(i=e.length-1;i>=0;--i){let l=e.charCodeAt(i);if(47===l){if(!o){n=i+1;break}}else -1===a&&(o=!1,a=i+1),s>=0&&(l===t.charCodeAt(s)?-1==--s&&(r=i):(s=-1,r=a))}return n===r?r=a:-1===r&&(r=e.length),e.slice(n,r)}for(i=e.length-1;i>=0;--i)if(47===e.charCodeAt(i)){if(!o){n=i+1;break}}else -1===r&&(o=!1,r=i+1);return -1===r?"":e.slice(n,r)},extname(e){nZ(e,"path");let t=-1,i=0,n=-1,r=!0,o=0;for(let s=e.length-1;s>=0;--s){let a=e.charCodeAt(s);if(47===a){if(!r){i=s+1;break}continue}-1===n&&(r=!1,n=s+1),46===a?-1===t?t=s:1!==o&&(o=1):-1!==t&&(o=-1)}return -1===t||-1===n||0===o||1===o&&t===n-1&&t===i+1?"":e.slice(t,n)},format:n5.bind(null,"/"),parse(e){let t;nZ(e,"path");let i={root:"",dir:"",base:"",ext:"",name:""};if(0===e.length)return i;let n=47===e.charCodeAt(0);n?(i.root="/",t=1):t=0;let r=-1,o=0,s=-1,a=!0,l=e.length-1,h=0;for(;l>=t;--l){let t=e.charCodeAt(l);if(47===t){if(!a){o=l+1;break}continue}-1===s&&(a=!1,s=l+1),46===t?-1===r?r=l:1!==h&&(h=1):-1!==r&&(h=-1)}if(-1!==s){let t=0===o&&n?1:o;-1===r||0===h||1===h&&r===s-1&&r===o+1?i.base=i.name=e.slice(t,s):(i.name=e.slice(t,r),i.base=e.slice(t,s),i.ext=e.slice(r,s))}return o>0?i.dir=e.slice(0,o-1):n&&(i.dir="/"),i},sep:"/",delimiter:":",win32:null,posix:null};n6.win32=n4.win32=n4,n6.posix=n4.posix=n6;let n9=nQ?n4.normalize:n6.normalize,n8=nQ?n4.resolve:n6.resolve,n7=nQ?n4.relative:n6.relative,re=nQ?n4.dirname:n6.dirname,rt=nQ?n4.basename:n6.basename,ri=nQ?n4.extname:n6.extname,rn=nQ?n4.sep:n6.sep,rr=/^\w[\w\d+.-]*$/,ro=/^\//,rs=/^\/\//,ra=/^(([^:/?#]+?):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?/;class rl{static isUri(e){return e instanceof rl||!!e&&"string"==typeof e.authority&&"string"==typeof e.fragment&&"string"==typeof e.path&&"string"==typeof e.query&&"string"==typeof e.scheme&&"string"==typeof e.fsPath&&"function"==typeof e.with&&"function"==typeof e.toString}constructor(e,t,i,n,r,o=!1){"object"==typeof e?(this.scheme=e.scheme||"",this.authority=e.authority||"",this.path=e.path||"",this.query=e.query||"",this.fragment=e.fragment||""):(this.scheme=e||o?e:"file",this.authority=t||"",this.path=function(e,t){switch(e){case"https":case"http":case"file":t?"/"!==t[0]&&(t="/"+t):t="/"}return t}(this.scheme,i||""),this.query=n||"",this.fragment=r||"",function(e,t){if(!e.scheme&&t)throw Error(`[UriError]: Scheme is missing: {scheme: "", authority: "${e.authority}", path: "${e.path}", query: "${e.query}", fragment: "${e.fragment}"}`);if(e.scheme&&!rr.test(e.scheme))throw Error("[UriError]: Scheme contains illegal characters.");if(e.path){if(e.authority){if(!ro.test(e.path))throw Error('[UriError]: If a URI contains an authority component, then the path component must either be empty or begin with a slash ("/") character')}else if(rs.test(e.path))throw Error('[UriError]: If a URI does not contain an authority component, then the path cannot begin with two slash characters ("//")')}}(this,o))}get fsPath(){return rg(this,!1)}with(e){if(!e)return this;let{scheme:t,authority:i,path:n,query:r,fragment:o}=e;return(void 0===t?t=this.scheme:null===t&&(t=""),void 0===i?i=this.authority:null===i&&(i=""),void 0===n?n=this.path:null===n&&(n=""),void 0===r?r=this.query:null===r&&(r=""),void 0===o?o=this.fragment:null===o&&(o=""),t===this.scheme&&i===this.authority&&n===this.path&&r===this.query&&o===this.fragment)?this:new ru(t,i,n,r,o)}static parse(e,t=!1){let i=ra.exec(e);return i?new ru(i[2]||"",r_(i[4]||""),r_(i[5]||""),r_(i[7]||""),r_(i[9]||""),t):new ru("","","","","")}static file(e){let t="";if(nz.ED&&(e=e.replace(/\\/g,"/")),"/"===e[0]&&"/"===e[1]){let i=e.indexOf("/",2);-1===i?(t=e.substring(2),e="/"):(t=e.substring(2,i),e=e.substring(i)||"/")}return new ru("file",t,e,"","")}static from(e,t){let i=new ru(e.scheme,e.authority,e.path,e.query,e.fragment,t);return i}static joinPath(e,...t){let i;if(!e.path)throw Error("[UriError]: cannot call joinPath on URI without path");return i=nz.ED&&"file"===e.scheme?rl.file(n4.join(rg(e,!0),...t)).path:n6.join(e.path,...t),e.with({path:i})}toString(e=!1){return rp(this,e)}toJSON(){return this}static revive(e){var t,i;if(!e||e instanceof rl)return e;{let n=new ru(e);return n._formatted=null!==(t=e.external)&&void 0!==t?t:null,n._fsPath=e._sep===rh&&null!==(i=e.fsPath)&&void 0!==i?i:null,n}}}let rh=nz.ED?1:void 0;class ru extends rl{constructor(){super(...arguments),this._formatted=null,this._fsPath=null}get fsPath(){return this._fsPath||(this._fsPath=rg(this,!1)),this._fsPath}toString(e=!1){return e?rp(this,!0):(this._formatted||(this._formatted=rp(this,!1)),this._formatted)}toJSON(){let e={$mid:1};return this._fsPath&&(e.fsPath=this._fsPath,e._sep=rh),this._formatted&&(e.external=this._formatted),this.path&&(e.path=this.path),this.scheme&&(e.scheme=this.scheme),this.authority&&(e.authority=this.authority),this.query&&(e.query=this.query),this.fragment&&(e.fragment=this.fragment),e}}let rd={58:"%3A",47:"%2F",63:"%3F",35:"%23",91:"%5B",93:"%5D",64:"%40",33:"%21",36:"%24",38:"%26",39:"%27",40:"%28",41:"%29",42:"%2A",43:"%2B",44:"%2C",59:"%3B",61:"%3D",32:"%20"};function rc(e,t,i){let n;let r=-1;for(let o=0;o=97&&s<=122||s>=65&&s<=90||s>=48&&s<=57||45===s||46===s||95===s||126===s||t&&47===s||i&&91===s||i&&93===s||i&&58===s)-1!==r&&(n+=encodeURIComponent(e.substring(r,o)),r=-1),void 0!==n&&(n+=e.charAt(o));else{void 0===n&&(n=e.substr(0,o));let t=rd[s];void 0!==t?(-1!==r&&(n+=encodeURIComponent(e.substring(r,o)),r=-1),n+=t):-1===r&&(r=o)}}return -1!==r&&(n+=encodeURIComponent(e.substring(r))),void 0!==n?n:e}function rf(e){let t;for(let i=0;i1&&"file"===e.scheme?`//${e.authority}${e.path}`:47===e.path.charCodeAt(0)&&(e.path.charCodeAt(1)>=65&&90>=e.path.charCodeAt(1)||e.path.charCodeAt(1)>=97&&122>=e.path.charCodeAt(1))&&58===e.path.charCodeAt(2)?t?e.path.substr(1):e.path[1].toLowerCase()+e.path.substr(2):e.path,nz.ED&&(i=i.replace(/\//g,"\\")),i}function rp(e,t){let i=t?rf:rc,n="",{scheme:r,authority:o,path:s,query:a,fragment:l}=e;if(r&&(n+=r+":"),(o||"file"===r)&&(n+="//"),o){let e=o.indexOf("@");if(-1!==e){let t=o.substr(0,e);o=o.substr(e+1),-1===(e=t.lastIndexOf(":"))?n+=i(t,!1,!1):n+=i(t.substr(0,e),!1,!1)+":"+i(t.substr(e+1),!1,!0),n+="@"}-1===(e=(o=o.toLowerCase()).lastIndexOf(":"))?n+=i(o,!1,!0):n+=i(o.substr(0,e),!1,!0)+o.substr(e)}if(s){if(s.length>=3&&47===s.charCodeAt(0)&&58===s.charCodeAt(2)){let e=s.charCodeAt(1);e>=65&&e<=90&&(s=`/${String.fromCharCode(e+32)}:${s.substr(3)}`)}else if(s.length>=2&&58===s.charCodeAt(1)){let e=s.charCodeAt(0);e>=65&&e<=90&&(s=`${String.fromCharCode(e+32)}:${s.substr(2)}`)}n+=i(s,!0,!1)}return a&&(n+="?"+i(a,!1,!1)),l&&(n+="#"+(t?l:rc(l,!1,!1))),n}let rm=/(%[0-9A-Za-z][0-9A-Za-z])+/g;function r_(e){return e.match(rm)?e.replace(rm,e=>(function e(t){try{return decodeURIComponent(t)}catch(i){if(t.length>3)return t.substr(0,3)+e(t.substr(3));return t}})(e)):e}class rE{constructor(e,t){this.lineNumber=e,this.column=t}with(e=this.lineNumber,t=this.column){return e===this.lineNumber&&t===this.column?this:new rE(e,t)}delta(e=0,t=0){return this.with(this.lineNumber+e,this.column+t)}equals(e){return rE.equals(this,e)}static equals(e,t){return!e&&!t||!!e&&!!t&&e.lineNumber===t.lineNumber&&e.column===t.column}isBefore(e){return rE.isBefore(this,e)}static isBefore(e,t){return e.lineNumberi||e===i&&t>n?(this.startLineNumber=i,this.startColumn=n,this.endLineNumber=e,this.endColumn=t):(this.startLineNumber=e,this.startColumn=t,this.endLineNumber=i,this.endColumn=n)}isEmpty(){return rv.isEmpty(this)}static isEmpty(e){return e.startLineNumber===e.endLineNumber&&e.startColumn===e.endColumn}containsPosition(e){return rv.containsPosition(this,e)}static containsPosition(e,t){return!(t.lineNumbere.endLineNumber)&&(t.lineNumber!==e.startLineNumber||!(t.columne.endColumn))}static strictContainsPosition(e,t){return!(t.lineNumbere.endLineNumber)&&(t.lineNumber!==e.startLineNumber||!(t.column<=e.startColumn))&&(t.lineNumber!==e.endLineNumber||!(t.column>=e.endColumn))}containsRange(e){return rv.containsRange(this,e)}static containsRange(e,t){return!(t.startLineNumbere.endLineNumber)&&!(t.endLineNumber>e.endLineNumber)&&(t.startLineNumber!==e.startLineNumber||!(t.startColumne.endColumn))}strictContainsRange(e){return rv.strictContainsRange(this,e)}static strictContainsRange(e,t){return!(t.startLineNumbere.endLineNumber)&&!(t.endLineNumber>e.endLineNumber)&&(t.startLineNumber!==e.startLineNumber||!(t.startColumn<=e.startColumn))&&(t.endLineNumber!==e.endLineNumber||!(t.endColumn>=e.endColumn))}plusRange(e){return rv.plusRange(this,e)}static plusRange(e,t){let i,n,r,o;return t.startLineNumbere.endLineNumber?(r=t.endLineNumber,o=t.endColumn):t.endLineNumber===e.endLineNumber?(r=t.endLineNumber,o=Math.max(t.endColumn,e.endColumn)):(r=e.endLineNumber,o=e.endColumn),new rv(i,n,r,o)}intersectRanges(e){return rv.intersectRanges(this,e)}static intersectRanges(e,t){let i=e.startLineNumber,n=e.startColumn,r=e.endLineNumber,o=e.endColumn,s=t.startLineNumber,a=t.startColumn,l=t.endLineNumber,h=t.endColumn;return(il?(r=l,o=h):r===l&&(o=Math.min(o,h)),i>r||i===r&&n>o)?null:new rv(i,n,r,o)}equalsRange(e){return rv.equalsRange(this,e)}static equalsRange(e,t){return!e&&!t||!!e&&!!t&&e.startLineNumber===t.startLineNumber&&e.startColumn===t.startColumn&&e.endLineNumber===t.endLineNumber&&e.endColumn===t.endColumn}getEndPosition(){return rv.getEndPosition(this)}static getEndPosition(e){return new rE(e.endLineNumber,e.endColumn)}getStartPosition(){return rv.getStartPosition(this)}static getStartPosition(e){return new rE(e.startLineNumber,e.startColumn)}toString(){return"["+this.startLineNumber+","+this.startColumn+" -> "+this.endLineNumber+","+this.endColumn+"]"}setEndPosition(e,t){return new rv(this.startLineNumber,this.startColumn,e,t)}setStartPosition(e,t){return new rv(e,t,this.endLineNumber,this.endColumn)}collapseToStart(){return rv.collapseToStart(this)}static collapseToStart(e){return new rv(e.startLineNumber,e.startColumn,e.startLineNumber,e.startColumn)}collapseToEnd(){return rv.collapseToEnd(this)}static collapseToEnd(e){return new rv(e.endLineNumber,e.endColumn,e.endLineNumber,e.endColumn)}delta(e){return new rv(this.startLineNumber+e,this.startColumn,this.endLineNumber+e,this.endColumn)}static fromPositions(e,t=e){return new rv(e.lineNumber,e.column,t.lineNumber,t.column)}static lift(e){return e?new rv(e.startLineNumber,e.startColumn,e.endLineNumber,e.endColumn):null}static isIRange(e){return e&&"number"==typeof e.startLineNumber&&"number"==typeof e.startColumn&&"number"==typeof e.endLineNumber&&"number"==typeof e.endColumn}static areIntersectingOrTouching(e,t){return!(e.endLineNumbere.startLineNumber}toJSON(){return this}}class rb extends rv{constructor(e,t,i,n){super(e,t,i,n),this.selectionStartLineNumber=e,this.selectionStartColumn=t,this.positionLineNumber=i,this.positionColumn=n}toString(){return"["+this.selectionStartLineNumber+","+this.selectionStartColumn+" -> "+this.positionLineNumber+","+this.positionColumn+"]"}equalsSelection(e){return rb.selectionsEqual(this,e)}static selectionsEqual(e,t){return e.selectionStartLineNumber===t.selectionStartLineNumber&&e.selectionStartColumn===t.selectionStartColumn&&e.positionLineNumber===t.positionLineNumber&&e.positionColumn===t.positionColumn}getDirection(){return this.selectionStartLineNumber===this.startLineNumber&&this.selectionStartColumn===this.startColumn?0:1}setEndPosition(e,t){return 0===this.getDirection()?new rb(this.startLineNumber,this.startColumn,e,t):new rb(e,t,this.startLineNumber,this.startColumn)}getPosition(){return new rE(this.positionLineNumber,this.positionColumn)}getSelectionStart(){return new rE(this.selectionStartLineNumber,this.selectionStartColumn)}setStartPosition(e,t){return 0===this.getDirection()?new rb(e,t,this.endLineNumber,this.endColumn):new rb(this.endLineNumber,this.endColumn,e,t)}static fromPositions(e,t=e){return new rb(e.lineNumber,e.column,t.lineNumber,t.column)}static fromRange(e,t){return 0===t?new rb(e.startLineNumber,e.startColumn,e.endLineNumber,e.endColumn):new rb(e.endLineNumber,e.endColumn,e.startLineNumber,e.startColumn)}static liftSelection(e){return new rb(e.selectionStartLineNumber,e.selectionStartColumn,e.positionLineNumber,e.positionColumn)}static selectionsArrEqual(e,t){if(e&&!t||!e&&t)return!1;if(!e&&!t)return!0;if(e.length!==t.length)return!1;for(let i=0,n=e.length;i{e&&e.dispose()})}get tokenizationSupport(){return this._tokenizationSupport||(this._tokenizationSupport=this.createSupport()),this._tokenizationSupport}}let rx=new class{constructor(){this._tokenizationSupports=new Map,this._factories=new Map,this._onDidChange=new ny,this.onDidChange=this._onDidChange.event,this._colorMap=null}handleChange(e){this._onDidChange.fire({changedLanguages:e,changedColorMap:!1})}register(e,t){return this._tokenizationSupports.set(e,t),this.handleChange([e]),nu(()=>{this._tokenizationSupports.get(e)===t&&(this._tokenizationSupports.delete(e),this.handleChange([e]))})}get(e){return this._tokenizationSupports.get(e)||null}registerFactory(e,t){var i;null===(i=this._factories.get(e))||void 0===i||i.dispose();let n=new rA(this,e,t);return this._factories.set(e,n),nu(()=>{let t=this._factories.get(e);t&&t===n&&(this._factories.delete(e),t.dispose())})}getOrCreate(e){return rR(this,void 0,void 0,function*(){let t=this.get(e);if(t)return t;let i=this._factories.get(e);return!i||i.isResolved?null:(yield i.resolve(),this.get(e))})}isResolved(e){let t=this.get(e);if(t)return!0;let i=this._factories.get(e);return!i||!!i.isResolved}setColorMap(e){this._colorMap=e,this._onDidChange.fire({changedLanguages:Array.from(this._tokenizationSupports.keys()),changedColorMap:!0})}getColorMap(){return this._colorMap}getDefaultBackground(){return this._colorMap&&this._colorMap.length>2?this._colorMap[2]:null}};(O=tl||(tl={}))[O.Unknown=0]="Unknown",O[O.Disabled=1]="Disabled",O[O.Enabled=2]="Enabled",(L=th||(th={}))[L.Invoke=1]="Invoke",L[L.Auto=2]="Auto",(I=tu||(tu={}))[I.None=0]="None",I[I.KeepWhitespace=1]="KeepWhitespace",I[I.InsertAsSnippet=4]="InsertAsSnippet",(w=td||(td={}))[w.Method=0]="Method",w[w.Function=1]="Function",w[w.Constructor=2]="Constructor",w[w.Field=3]="Field",w[w.Variable=4]="Variable",w[w.Class=5]="Class",w[w.Struct=6]="Struct",w[w.Interface=7]="Interface",w[w.Module=8]="Module",w[w.Property=9]="Property",w[w.Event=10]="Event",w[w.Operator=11]="Operator",w[w.Unit=12]="Unit",w[w.Value=13]="Value",w[w.Constant=14]="Constant",w[w.Enum=15]="Enum",w[w.EnumMember=16]="EnumMember",w[w.Keyword=17]="Keyword",w[w.Text=18]="Text",w[w.Color=19]="Color",w[w.File=20]="File",w[w.Reference=21]="Reference",w[w.Customcolor=22]="Customcolor",w[w.Folder=23]="Folder",w[w.TypeParameter=24]="TypeParameter",w[w.User=25]="User",w[w.Issue=26]="Issue",w[w.Snippet=27]="Snippet",(D=tc||(tc={}))[D.Deprecated=1]="Deprecated",(x=tf||(tf={}))[x.Invoke=0]="Invoke",x[x.TriggerCharacter=1]="TriggerCharacter",x[x.TriggerForIncompleteCompletions=2]="TriggerForIncompleteCompletions",(M=tg||(tg={}))[M.EXACT=0]="EXACT",M[M.ABOVE=1]="ABOVE",M[M.BELOW=2]="BELOW",(k=tp||(tp={}))[k.NotSet=0]="NotSet",k[k.ContentFlush=1]="ContentFlush",k[k.RecoverFromMarkers=2]="RecoverFromMarkers",k[k.Explicit=3]="Explicit",k[k.Paste=4]="Paste",k[k.Undo=5]="Undo",k[k.Redo=6]="Redo",(P=tm||(tm={}))[P.LF=1]="LF",P[P.CRLF=2]="CRLF",(F=t_||(t_={}))[F.Text=0]="Text",F[F.Read=1]="Read",F[F.Write=2]="Write",(B=tE||(tE={}))[B.None=0]="None",B[B.Keep=1]="Keep",B[B.Brackets=2]="Brackets",B[B.Advanced=3]="Advanced",B[B.Full=4]="Full",(U=tv||(tv={}))[U.acceptSuggestionOnCommitCharacter=0]="acceptSuggestionOnCommitCharacter",U[U.acceptSuggestionOnEnter=1]="acceptSuggestionOnEnter",U[U.accessibilitySupport=2]="accessibilitySupport",U[U.accessibilityPageSize=3]="accessibilityPageSize",U[U.ariaLabel=4]="ariaLabel",U[U.ariaRequired=5]="ariaRequired",U[U.autoClosingBrackets=6]="autoClosingBrackets",U[U.screenReaderAnnounceInlineSuggestion=7]="screenReaderAnnounceInlineSuggestion",U[U.autoClosingDelete=8]="autoClosingDelete",U[U.autoClosingOvertype=9]="autoClosingOvertype",U[U.autoClosingQuotes=10]="autoClosingQuotes",U[U.autoIndent=11]="autoIndent",U[U.automaticLayout=12]="automaticLayout",U[U.autoSurround=13]="autoSurround",U[U.bracketPairColorization=14]="bracketPairColorization",U[U.guides=15]="guides",U[U.codeLens=16]="codeLens",U[U.codeLensFontFamily=17]="codeLensFontFamily",U[U.codeLensFontSize=18]="codeLensFontSize",U[U.colorDecorators=19]="colorDecorators",U[U.colorDecoratorsLimit=20]="colorDecoratorsLimit",U[U.columnSelection=21]="columnSelection",U[U.comments=22]="comments",U[U.contextmenu=23]="contextmenu",U[U.copyWithSyntaxHighlighting=24]="copyWithSyntaxHighlighting",U[U.cursorBlinking=25]="cursorBlinking",U[U.cursorSmoothCaretAnimation=26]="cursorSmoothCaretAnimation",U[U.cursorStyle=27]="cursorStyle",U[U.cursorSurroundingLines=28]="cursorSurroundingLines",U[U.cursorSurroundingLinesStyle=29]="cursorSurroundingLinesStyle",U[U.cursorWidth=30]="cursorWidth",U[U.disableLayerHinting=31]="disableLayerHinting",U[U.disableMonospaceOptimizations=32]="disableMonospaceOptimizations",U[U.domReadOnly=33]="domReadOnly",U[U.dragAndDrop=34]="dragAndDrop",U[U.dropIntoEditor=35]="dropIntoEditor",U[U.emptySelectionClipboard=36]="emptySelectionClipboard",U[U.experimentalWhitespaceRendering=37]="experimentalWhitespaceRendering",U[U.extraEditorClassName=38]="extraEditorClassName",U[U.fastScrollSensitivity=39]="fastScrollSensitivity",U[U.find=40]="find",U[U.fixedOverflowWidgets=41]="fixedOverflowWidgets",U[U.folding=42]="folding",U[U.foldingStrategy=43]="foldingStrategy",U[U.foldingHighlight=44]="foldingHighlight",U[U.foldingImportsByDefault=45]="foldingImportsByDefault",U[U.foldingMaximumRegions=46]="foldingMaximumRegions",U[U.unfoldOnClickAfterEndOfLine=47]="unfoldOnClickAfterEndOfLine",U[U.fontFamily=48]="fontFamily",U[U.fontInfo=49]="fontInfo",U[U.fontLigatures=50]="fontLigatures",U[U.fontSize=51]="fontSize",U[U.fontWeight=52]="fontWeight",U[U.fontVariations=53]="fontVariations",U[U.formatOnPaste=54]="formatOnPaste",U[U.formatOnType=55]="formatOnType",U[U.glyphMargin=56]="glyphMargin",U[U.gotoLocation=57]="gotoLocation",U[U.hideCursorInOverviewRuler=58]="hideCursorInOverviewRuler",U[U.hover=59]="hover",U[U.inDiffEditor=60]="inDiffEditor",U[U.inlineSuggest=61]="inlineSuggest",U[U.letterSpacing=62]="letterSpacing",U[U.lightbulb=63]="lightbulb",U[U.lineDecorationsWidth=64]="lineDecorationsWidth",U[U.lineHeight=65]="lineHeight",U[U.lineNumbers=66]="lineNumbers",U[U.lineNumbersMinChars=67]="lineNumbersMinChars",U[U.linkedEditing=68]="linkedEditing",U[U.links=69]="links",U[U.matchBrackets=70]="matchBrackets",U[U.minimap=71]="minimap",U[U.mouseStyle=72]="mouseStyle",U[U.mouseWheelScrollSensitivity=73]="mouseWheelScrollSensitivity",U[U.mouseWheelZoom=74]="mouseWheelZoom",U[U.multiCursorMergeOverlapping=75]="multiCursorMergeOverlapping",U[U.multiCursorModifier=76]="multiCursorModifier",U[U.multiCursorPaste=77]="multiCursorPaste",U[U.multiCursorLimit=78]="multiCursorLimit",U[U.occurrencesHighlight=79]="occurrencesHighlight",U[U.overviewRulerBorder=80]="overviewRulerBorder",U[U.overviewRulerLanes=81]="overviewRulerLanes",U[U.padding=82]="padding",U[U.pasteAs=83]="pasteAs",U[U.parameterHints=84]="parameterHints",U[U.peekWidgetDefaultFocus=85]="peekWidgetDefaultFocus",U[U.definitionLinkOpensInPeek=86]="definitionLinkOpensInPeek",U[U.quickSuggestions=87]="quickSuggestions",U[U.quickSuggestionsDelay=88]="quickSuggestionsDelay",U[U.readOnly=89]="readOnly",U[U.readOnlyMessage=90]="readOnlyMessage",U[U.renameOnType=91]="renameOnType",U[U.renderControlCharacters=92]="renderControlCharacters",U[U.renderFinalNewline=93]="renderFinalNewline",U[U.renderLineHighlight=94]="renderLineHighlight",U[U.renderLineHighlightOnlyWhenFocus=95]="renderLineHighlightOnlyWhenFocus",U[U.renderValidationDecorations=96]="renderValidationDecorations",U[U.renderWhitespace=97]="renderWhitespace",U[U.revealHorizontalRightPadding=98]="revealHorizontalRightPadding",U[U.roundedSelection=99]="roundedSelection",U[U.rulers=100]="rulers",U[U.scrollbar=101]="scrollbar",U[U.scrollBeyondLastColumn=102]="scrollBeyondLastColumn",U[U.scrollBeyondLastLine=103]="scrollBeyondLastLine",U[U.scrollPredominantAxis=104]="scrollPredominantAxis",U[U.selectionClipboard=105]="selectionClipboard",U[U.selectionHighlight=106]="selectionHighlight",U[U.selectOnLineNumbers=107]="selectOnLineNumbers",U[U.showFoldingControls=108]="showFoldingControls",U[U.showUnused=109]="showUnused",U[U.snippetSuggestions=110]="snippetSuggestions",U[U.smartSelect=111]="smartSelect",U[U.smoothScrolling=112]="smoothScrolling",U[U.stickyScroll=113]="stickyScroll",U[U.stickyTabStops=114]="stickyTabStops",U[U.stopRenderingLineAfter=115]="stopRenderingLineAfter",U[U.suggest=116]="suggest",U[U.suggestFontSize=117]="suggestFontSize",U[U.suggestLineHeight=118]="suggestLineHeight",U[U.suggestOnTriggerCharacters=119]="suggestOnTriggerCharacters",U[U.suggestSelection=120]="suggestSelection",U[U.tabCompletion=121]="tabCompletion",U[U.tabIndex=122]="tabIndex",U[U.unicodeHighlighting=123]="unicodeHighlighting",U[U.unusualLineTerminators=124]="unusualLineTerminators",U[U.useShadowDOM=125]="useShadowDOM",U[U.useTabStops=126]="useTabStops",U[U.wordBreak=127]="wordBreak",U[U.wordSeparators=128]="wordSeparators",U[U.wordWrap=129]="wordWrap",U[U.wordWrapBreakAfterCharacters=130]="wordWrapBreakAfterCharacters",U[U.wordWrapBreakBeforeCharacters=131]="wordWrapBreakBeforeCharacters",U[U.wordWrapColumn=132]="wordWrapColumn",U[U.wordWrapOverride1=133]="wordWrapOverride1",U[U.wordWrapOverride2=134]="wordWrapOverride2",U[U.wrappingIndent=135]="wrappingIndent",U[U.wrappingStrategy=136]="wrappingStrategy",U[U.showDeprecated=137]="showDeprecated",U[U.inlayHints=138]="inlayHints",U[U.editorClassName=139]="editorClassName",U[U.pixelRatio=140]="pixelRatio",U[U.tabFocusMode=141]="tabFocusMode",U[U.layoutInfo=142]="layoutInfo",U[U.wrappingInfo=143]="wrappingInfo",U[U.defaultColorDecorators=144]="defaultColorDecorators",U[U.colorDecoratorsActivatedOn=145]="colorDecoratorsActivatedOn",(H=tb||(tb={}))[H.TextDefined=0]="TextDefined",H[H.LF=1]="LF",H[H.CRLF=2]="CRLF",(V=tC||(tC={}))[V.LF=0]="LF",V[V.CRLF=1]="CRLF",(W=tS||(tS={}))[W.Left=1]="Left",W[W.Right=2]="Right",(G=ty||(ty={}))[G.None=0]="None",G[G.Indent=1]="Indent",G[G.IndentOutdent=2]="IndentOutdent",G[G.Outdent=3]="Outdent",(j=tT||(tT={}))[j.Both=0]="Both",j[j.Right=1]="Right",j[j.Left=2]="Left",j[j.None=3]="None",(z=tR||(tR={}))[z.Type=1]="Type",z[z.Parameter=2]="Parameter",(K=tA||(tA={}))[K.Automatic=0]="Automatic",K[K.Explicit=1]="Explicit",(Y=tN||(tN={}))[Y.DependsOnKbLayout=-1]="DependsOnKbLayout",Y[Y.Unknown=0]="Unknown",Y[Y.Backspace=1]="Backspace",Y[Y.Tab=2]="Tab",Y[Y.Enter=3]="Enter",Y[Y.Shift=4]="Shift",Y[Y.Ctrl=5]="Ctrl",Y[Y.Alt=6]="Alt",Y[Y.PauseBreak=7]="PauseBreak",Y[Y.CapsLock=8]="CapsLock",Y[Y.Escape=9]="Escape",Y[Y.Space=10]="Space",Y[Y.PageUp=11]="PageUp",Y[Y.PageDown=12]="PageDown",Y[Y.End=13]="End",Y[Y.Home=14]="Home",Y[Y.LeftArrow=15]="LeftArrow",Y[Y.UpArrow=16]="UpArrow",Y[Y.RightArrow=17]="RightArrow",Y[Y.DownArrow=18]="DownArrow",Y[Y.Insert=19]="Insert",Y[Y.Delete=20]="Delete",Y[Y.Digit0=21]="Digit0",Y[Y.Digit1=22]="Digit1",Y[Y.Digit2=23]="Digit2",Y[Y.Digit3=24]="Digit3",Y[Y.Digit4=25]="Digit4",Y[Y.Digit5=26]="Digit5",Y[Y.Digit6=27]="Digit6",Y[Y.Digit7=28]="Digit7",Y[Y.Digit8=29]="Digit8",Y[Y.Digit9=30]="Digit9",Y[Y.KeyA=31]="KeyA",Y[Y.KeyB=32]="KeyB",Y[Y.KeyC=33]="KeyC",Y[Y.KeyD=34]="KeyD",Y[Y.KeyE=35]="KeyE",Y[Y.KeyF=36]="KeyF",Y[Y.KeyG=37]="KeyG",Y[Y.KeyH=38]="KeyH",Y[Y.KeyI=39]="KeyI",Y[Y.KeyJ=40]="KeyJ",Y[Y.KeyK=41]="KeyK",Y[Y.KeyL=42]="KeyL",Y[Y.KeyM=43]="KeyM",Y[Y.KeyN=44]="KeyN",Y[Y.KeyO=45]="KeyO",Y[Y.KeyP=46]="KeyP",Y[Y.KeyQ=47]="KeyQ",Y[Y.KeyR=48]="KeyR",Y[Y.KeyS=49]="KeyS",Y[Y.KeyT=50]="KeyT",Y[Y.KeyU=51]="KeyU",Y[Y.KeyV=52]="KeyV",Y[Y.KeyW=53]="KeyW",Y[Y.KeyX=54]="KeyX",Y[Y.KeyY=55]="KeyY",Y[Y.KeyZ=56]="KeyZ",Y[Y.Meta=57]="Meta",Y[Y.ContextMenu=58]="ContextMenu",Y[Y.F1=59]="F1",Y[Y.F2=60]="F2",Y[Y.F3=61]="F3",Y[Y.F4=62]="F4",Y[Y.F5=63]="F5",Y[Y.F6=64]="F6",Y[Y.F7=65]="F7",Y[Y.F8=66]="F8",Y[Y.F9=67]="F9",Y[Y.F10=68]="F10",Y[Y.F11=69]="F11",Y[Y.F12=70]="F12",Y[Y.F13=71]="F13",Y[Y.F14=72]="F14",Y[Y.F15=73]="F15",Y[Y.F16=74]="F16",Y[Y.F17=75]="F17",Y[Y.F18=76]="F18",Y[Y.F19=77]="F19",Y[Y.F20=78]="F20",Y[Y.F21=79]="F21",Y[Y.F22=80]="F22",Y[Y.F23=81]="F23",Y[Y.F24=82]="F24",Y[Y.NumLock=83]="NumLock",Y[Y.ScrollLock=84]="ScrollLock",Y[Y.Semicolon=85]="Semicolon",Y[Y.Equal=86]="Equal",Y[Y.Comma=87]="Comma",Y[Y.Minus=88]="Minus",Y[Y.Period=89]="Period",Y[Y.Slash=90]="Slash",Y[Y.Backquote=91]="Backquote",Y[Y.BracketLeft=92]="BracketLeft",Y[Y.Backslash=93]="Backslash",Y[Y.BracketRight=94]="BracketRight",Y[Y.Quote=95]="Quote",Y[Y.OEM_8=96]="OEM_8",Y[Y.IntlBackslash=97]="IntlBackslash",Y[Y.Numpad0=98]="Numpad0",Y[Y.Numpad1=99]="Numpad1",Y[Y.Numpad2=100]="Numpad2",Y[Y.Numpad3=101]="Numpad3",Y[Y.Numpad4=102]="Numpad4",Y[Y.Numpad5=103]="Numpad5",Y[Y.Numpad6=104]="Numpad6",Y[Y.Numpad7=105]="Numpad7",Y[Y.Numpad8=106]="Numpad8",Y[Y.Numpad9=107]="Numpad9",Y[Y.NumpadMultiply=108]="NumpadMultiply",Y[Y.NumpadAdd=109]="NumpadAdd",Y[Y.NUMPAD_SEPARATOR=110]="NUMPAD_SEPARATOR",Y[Y.NumpadSubtract=111]="NumpadSubtract",Y[Y.NumpadDecimal=112]="NumpadDecimal",Y[Y.NumpadDivide=113]="NumpadDivide",Y[Y.KEY_IN_COMPOSITION=114]="KEY_IN_COMPOSITION",Y[Y.ABNT_C1=115]="ABNT_C1",Y[Y.ABNT_C2=116]="ABNT_C2",Y[Y.AudioVolumeMute=117]="AudioVolumeMute",Y[Y.AudioVolumeUp=118]="AudioVolumeUp",Y[Y.AudioVolumeDown=119]="AudioVolumeDown",Y[Y.BrowserSearch=120]="BrowserSearch",Y[Y.BrowserHome=121]="BrowserHome",Y[Y.BrowserBack=122]="BrowserBack",Y[Y.BrowserForward=123]="BrowserForward",Y[Y.MediaTrackNext=124]="MediaTrackNext",Y[Y.MediaTrackPrevious=125]="MediaTrackPrevious",Y[Y.MediaStop=126]="MediaStop",Y[Y.MediaPlayPause=127]="MediaPlayPause",Y[Y.LaunchMediaPlayer=128]="LaunchMediaPlayer",Y[Y.LaunchMail=129]="LaunchMail",Y[Y.LaunchApp2=130]="LaunchApp2",Y[Y.Clear=131]="Clear",Y[Y.MAX_VALUE=132]="MAX_VALUE",($=tO||(tO={}))[$.Hint=1]="Hint",$[$.Info=2]="Info",$[$.Warning=4]="Warning",$[$.Error=8]="Error",(q=tL||(tL={}))[q.Unnecessary=1]="Unnecessary",q[q.Deprecated=2]="Deprecated",(X=tI||(tI={}))[X.Inline=1]="Inline",X[X.Gutter=2]="Gutter",(Z=tw||(tw={}))[Z.UNKNOWN=0]="UNKNOWN",Z[Z.TEXTAREA=1]="TEXTAREA",Z[Z.GUTTER_GLYPH_MARGIN=2]="GUTTER_GLYPH_MARGIN",Z[Z.GUTTER_LINE_NUMBERS=3]="GUTTER_LINE_NUMBERS",Z[Z.GUTTER_LINE_DECORATIONS=4]="GUTTER_LINE_DECORATIONS",Z[Z.GUTTER_VIEW_ZONE=5]="GUTTER_VIEW_ZONE",Z[Z.CONTENT_TEXT=6]="CONTENT_TEXT",Z[Z.CONTENT_EMPTY=7]="CONTENT_EMPTY",Z[Z.CONTENT_VIEW_ZONE=8]="CONTENT_VIEW_ZONE",Z[Z.CONTENT_WIDGET=9]="CONTENT_WIDGET",Z[Z.OVERVIEW_RULER=10]="OVERVIEW_RULER",Z[Z.SCROLLBAR=11]="SCROLLBAR",Z[Z.OVERLAY_WIDGET=12]="OVERLAY_WIDGET",Z[Z.OUTSIDE_EDITOR=13]="OUTSIDE_EDITOR",(Q=tD||(tD={}))[Q.TOP_RIGHT_CORNER=0]="TOP_RIGHT_CORNER",Q[Q.BOTTOM_RIGHT_CORNER=1]="BOTTOM_RIGHT_CORNER",Q[Q.TOP_CENTER=2]="TOP_CENTER",(J=tx||(tx={}))[J.Left=1]="Left",J[J.Center=2]="Center",J[J.Right=4]="Right",J[J.Full=7]="Full",(ee=tM||(tM={}))[ee.Left=0]="Left",ee[ee.Right=1]="Right",ee[ee.None=2]="None",ee[ee.LeftOfInjectedText=3]="LeftOfInjectedText",ee[ee.RightOfInjectedText=4]="RightOfInjectedText",(et=tk||(tk={}))[et.Off=0]="Off",et[et.On=1]="On",et[et.Relative=2]="Relative",et[et.Interval=3]="Interval",et[et.Custom=4]="Custom",(ei=tP||(tP={}))[ei.None=0]="None",ei[ei.Text=1]="Text",ei[ei.Blocks=2]="Blocks",(en=tF||(tF={}))[en.Smooth=0]="Smooth",en[en.Immediate=1]="Immediate",(er=tB||(tB={}))[er.Auto=1]="Auto",er[er.Hidden=2]="Hidden",er[er.Visible=3]="Visible",(eo=tU||(tU={}))[eo.LTR=0]="LTR",eo[eo.RTL=1]="RTL",(es=tH||(tH={}))[es.Invoke=1]="Invoke",es[es.TriggerCharacter=2]="TriggerCharacter",es[es.ContentChange=3]="ContentChange",(ea=tV||(tV={}))[ea.File=0]="File",ea[ea.Module=1]="Module",ea[ea.Namespace=2]="Namespace",ea[ea.Package=3]="Package",ea[ea.Class=4]="Class",ea[ea.Method=5]="Method",ea[ea.Property=6]="Property",ea[ea.Field=7]="Field",ea[ea.Constructor=8]="Constructor",ea[ea.Enum=9]="Enum",ea[ea.Interface=10]="Interface",ea[ea.Function=11]="Function",ea[ea.Variable=12]="Variable",ea[ea.Constant=13]="Constant",ea[ea.String=14]="String",ea[ea.Number=15]="Number",ea[ea.Boolean=16]="Boolean",ea[ea.Array=17]="Array",ea[ea.Object=18]="Object",ea[ea.Key=19]="Key",ea[ea.Null=20]="Null",ea[ea.EnumMember=21]="EnumMember",ea[ea.Struct=22]="Struct",ea[ea.Event=23]="Event",ea[ea.Operator=24]="Operator",ea[ea.TypeParameter=25]="TypeParameter",(el=tW||(tW={}))[el.Deprecated=1]="Deprecated",(eh=tG||(tG={}))[eh.Hidden=0]="Hidden",eh[eh.Blink=1]="Blink",eh[eh.Smooth=2]="Smooth",eh[eh.Phase=3]="Phase",eh[eh.Expand=4]="Expand",eh[eh.Solid=5]="Solid",(eu=tj||(tj={}))[eu.Line=1]="Line",eu[eu.Block=2]="Block",eu[eu.Underline=3]="Underline",eu[eu.LineThin=4]="LineThin",eu[eu.BlockOutline=5]="BlockOutline",eu[eu.UnderlineThin=6]="UnderlineThin",(ed=tz||(tz={}))[ed.AlwaysGrowsWhenTypingAtEdges=0]="AlwaysGrowsWhenTypingAtEdges",ed[ed.NeverGrowsWhenTypingAtEdges=1]="NeverGrowsWhenTypingAtEdges",ed[ed.GrowsOnlyWhenTypingBefore=2]="GrowsOnlyWhenTypingBefore",ed[ed.GrowsOnlyWhenTypingAfter=3]="GrowsOnlyWhenTypingAfter",(ec=tK||(tK={}))[ec.None=0]="None",ec[ec.Same=1]="Same",ec[ec.Indent=2]="Indent",ec[ec.DeepIndent=3]="DeepIndent";class rM{static chord(e,t){return(e|(65535&t)<<16>>>0)>>>0}}function rk(){return{editor:void 0,languages:void 0,CancellationTokenSource:nx,Emitter:ny,KeyCode:tN,KeyMod:rM,Position:rE,Range:rv,Selection:rb,SelectionDirection:tU,MarkerSeverity:tO,MarkerTag:tL,Uri:rl,Token:rO}}rM.CtrlCmd=2048,rM.Shift=1024,rM.Alt=512,rM.WinCtrl=256,i(95656);class rP{get cachedValues(){return this._map}constructor(e){this.fn=e,this._map=new Map}get(e){if(this._map.has(e))return this._map.get(e);let t=this.fn(e);return this._map.set(e,t),t}}class rF{constructor(e){this.executor=e,this._didRun=!1}get value(){if(!this._didRun)try{this._value=this.executor()}catch(e){this._error=e}finally{this._didRun=!0}if(this._error)throw this._error;return this._value}get rawValue(){return this._value}}let rB=/{(\d+)}/g;function rU(e,...t){return 0===t.length?e:e.replace(rB,function(e,i){let n=parseInt(i,10);return isNaN(n)||n<0||n>=t.length?e:t[n]})}function rH(e){return e.replace(/[<>&]/g,function(e){switch(e){case"<":return"<";case">":return">";case"&":return"&";default:return e}})}function rV(e){return e.replace(/[\\\{\}\*\+\?\|\^\$\.\[\]\(\)]/g,"\\$&")}function rW(e,t){if(!e||!t)return e;let i=t.length;if(0===i||0===e.length)return e;let n=0;for(;e.indexOf(t,n)===n;)n+=i;return e.substring(n)}function rG(e,t,i={}){if(!e)throw Error("Cannot create regex from empty string");t||(e=rV(e)),i.wholeWord&&(/\B/.test(e.charAt(0))||(e="\\b"+e),/\B/.test(e.charAt(e.length-1))||(e+="\\b"));let n="";return i.global&&(n+="g"),i.matchCase||(n+="i"),i.multiline&&(n+="m"),i.unicode&&(n+="u"),new RegExp(e,n)}function rj(e){return(e.global?"g":"")+(e.ignoreCase?"i":"")+(e.multiline?"m":"")+(e.unicode?"u":"")}function rz(e){return e.split(/\r\n|\r|\n/)}function rK(e){for(let t=0,i=e.length;t=0;i--){let t=e.charCodeAt(i);if(32!==t&&9!==t)return i}return -1}function rq(e,t){return et?1:0}function rX(e,t,i=0,n=e.length,r=0,o=t.length){for(;io)return 1}let s=n-i,a=o-r;return sa?1:0}function rZ(e,t){return rQ(e,t,0,e.length,0,t.length)}function rQ(e,t,i=0,n=e.length,r=0,o=t.length){for(;i=128||a>=128)return rX(e.toLowerCase(),t.toLowerCase(),i,n,r,o);r0(s)&&(s-=32),r0(a)&&(a-=32);let l=s-a;if(0!==l)return l}let s=n-i,a=o-r;return sa?1:0}function rJ(e){return e>=48&&e<=57}function r0(e){return e>=97&&e<=122}function r1(e){return e>=65&&e<=90}function r2(e,t){return e.length===t.length&&0===rQ(e,t)}function r5(e,t){let i=t.length;return!(t.length>e.length)&&0===rQ(e,t,0,i)}function r4(e,t){let i;let n=Math.min(e.length,t.length);for(i=0;i1){let n=e.charCodeAt(t-2);if(r6(n))return r8(n,i)}return i}(this._str,this._offset);return this._offset-=e>=65536?2:1,e}nextCodePoint(){let e=r7(this._str,this._len,this._offset);return this._offset+=e>=65536?2:1,e}eol(){return this._offset>=this._len}}class ot{get offset(){return this._iterator.offset}constructor(e,t=0){this._iterator=new oe(e,t)}nextGraphemeLength(){let e=og.getInstance(),t=this._iterator,i=t.offset,n=e.getGraphemeBreakType(t.nextCodePoint());for(;!t.eol();){let i=t.offset,r=e.getGraphemeBreakType(t.nextCodePoint());if(of(n,r)){t.setOffset(i);break}n=r}return t.offset-i}prevGraphemeLength(){let e=og.getInstance(),t=this._iterator,i=t.offset,n=e.getGraphemeBreakType(t.prevCodePoint());for(;t.offset>0;){let i=t.offset,r=e.getGraphemeBreakType(t.prevCodePoint());if(of(r,n)){t.setOffset(i);break}n=r}return i-t.offset}eol(){return this._iterator.eol()}}function oi(e,t){let i=new ot(e,t);return i.nextGraphemeLength()}function on(e,t){let i=new ot(e,t);return i.prevGraphemeLength()}function or(e){return E||(E=/(?:[\u05BE\u05C0\u05C3\u05C6\u05D0-\u05F4\u0608\u060B\u060D\u061B-\u064A\u066D-\u066F\u0671-\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u0710\u0712-\u072F\u074D-\u07A5\u07B1-\u07EA\u07F4\u07F5\u07FA\u07FE-\u0815\u081A\u0824\u0828\u0830-\u0858\u085E-\u088E\u08A0-\u08C9\u200F\uFB1D\uFB1F-\uFB28\uFB2A-\uFD3D\uFD50-\uFDC7\uFDF0-\uFDFC\uFE70-\uFEFC]|\uD802[\uDC00-\uDD1B\uDD20-\uDE00\uDE10-\uDE35\uDE40-\uDEE4\uDEEB-\uDF35\uDF40-\uDFFF]|\uD803[\uDC00-\uDD23\uDE80-\uDEA9\uDEAD-\uDF45\uDF51-\uDF81\uDF86-\uDFF6]|\uD83A[\uDC00-\uDCCF\uDD00-\uDD43\uDD4B-\uDFFF]|\uD83B[\uDC00-\uDEBB])/),E.test(e)}let oo=/^[\t\n\r\x20-\x7E]*$/;function os(e){return oo.test(e)}let oa=/[\u2028\u2029]/;function ol(e){return e>=11904&&e<=55215||e>=63744&&e<=64255||e>=65281&&e<=65374}function oh(e){return e>=127462&&e<=127487||8986===e||8987===e||9200===e||9203===e||e>=9728&&e<=10175||11088===e||11093===e||e>=127744&&e<=128591||e>=128640&&e<=128764||e>=128992&&e<=129008||e>=129280&&e<=129535||e>=129648&&e<=129782}let ou=String.fromCharCode(65279);function od(e){return!!(e&&e.length>0&&65279===e.charCodeAt(0))}function oc(e){return(e%=52)<26?String.fromCharCode(97+e):String.fromCharCode(65+e-26)}function of(e,t){return 0===e?5!==t&&7!==t:(2!==e||3!==t)&&(4===e||2===e||3===e||4===t||2===t||3===t||(8!==e||8!==t&&9!==t&&11!==t&&12!==t)&&(11!==e&&9!==e||9!==t&&10!==t)&&(12!==e&&10!==e||10!==t)&&5!==t&&13!==t&&7!==t&&1!==e&&(13!==e||14!==t)&&(6!==e||6!==t))}class og{static getInstance(){return og._INSTANCE||(og._INSTANCE=new og),og._INSTANCE}constructor(){this._data=JSON.parse("[0,0,0,51229,51255,12,44061,44087,12,127462,127487,6,7083,7085,5,47645,47671,12,54813,54839,12,128678,128678,14,3270,3270,5,9919,9923,14,45853,45879,12,49437,49463,12,53021,53047,12,71216,71218,7,128398,128399,14,129360,129374,14,2519,2519,5,4448,4519,9,9742,9742,14,12336,12336,14,44957,44983,12,46749,46775,12,48541,48567,12,50333,50359,12,52125,52151,12,53917,53943,12,69888,69890,5,73018,73018,5,127990,127990,14,128558,128559,14,128759,128760,14,129653,129655,14,2027,2035,5,2891,2892,7,3761,3761,5,6683,6683,5,8293,8293,4,9825,9826,14,9999,9999,14,43452,43453,5,44509,44535,12,45405,45431,12,46301,46327,12,47197,47223,12,48093,48119,12,48989,49015,12,49885,49911,12,50781,50807,12,51677,51703,12,52573,52599,12,53469,53495,12,54365,54391,12,65279,65279,4,70471,70472,7,72145,72147,7,119173,119179,5,127799,127818,14,128240,128244,14,128512,128512,14,128652,128652,14,128721,128722,14,129292,129292,14,129445,129450,14,129734,129743,14,1476,1477,5,2366,2368,7,2750,2752,7,3076,3076,5,3415,3415,5,4141,4144,5,6109,6109,5,6964,6964,5,7394,7400,5,9197,9198,14,9770,9770,14,9877,9877,14,9968,9969,14,10084,10084,14,43052,43052,5,43713,43713,5,44285,44311,12,44733,44759,12,45181,45207,12,45629,45655,12,46077,46103,12,46525,46551,12,46973,46999,12,47421,47447,12,47869,47895,12,48317,48343,12,48765,48791,12,49213,49239,12,49661,49687,12,50109,50135,12,50557,50583,12,51005,51031,12,51453,51479,12,51901,51927,12,52349,52375,12,52797,52823,12,53245,53271,12,53693,53719,12,54141,54167,12,54589,54615,12,55037,55063,12,69506,69509,5,70191,70193,5,70841,70841,7,71463,71467,5,72330,72342,5,94031,94031,5,123628,123631,5,127763,127765,14,127941,127941,14,128043,128062,14,128302,128317,14,128465,128467,14,128539,128539,14,128640,128640,14,128662,128662,14,128703,128703,14,128745,128745,14,129004,129007,14,129329,129330,14,129402,129402,14,129483,129483,14,129686,129704,14,130048,131069,14,173,173,4,1757,1757,1,2200,2207,5,2434,2435,7,2631,2632,5,2817,2817,5,3008,3008,5,3201,3201,5,3387,3388,5,3542,3542,5,3902,3903,7,4190,4192,5,6002,6003,5,6439,6440,5,6765,6770,7,7019,7027,5,7154,7155,7,8205,8205,13,8505,8505,14,9654,9654,14,9757,9757,14,9792,9792,14,9852,9853,14,9890,9894,14,9937,9937,14,9981,9981,14,10035,10036,14,11035,11036,14,42654,42655,5,43346,43347,7,43587,43587,5,44006,44007,7,44173,44199,12,44397,44423,12,44621,44647,12,44845,44871,12,45069,45095,12,45293,45319,12,45517,45543,12,45741,45767,12,45965,45991,12,46189,46215,12,46413,46439,12,46637,46663,12,46861,46887,12,47085,47111,12,47309,47335,12,47533,47559,12,47757,47783,12,47981,48007,12,48205,48231,12,48429,48455,12,48653,48679,12,48877,48903,12,49101,49127,12,49325,49351,12,49549,49575,12,49773,49799,12,49997,50023,12,50221,50247,12,50445,50471,12,50669,50695,12,50893,50919,12,51117,51143,12,51341,51367,12,51565,51591,12,51789,51815,12,52013,52039,12,52237,52263,12,52461,52487,12,52685,52711,12,52909,52935,12,53133,53159,12,53357,53383,12,53581,53607,12,53805,53831,12,54029,54055,12,54253,54279,12,54477,54503,12,54701,54727,12,54925,54951,12,55149,55175,12,68101,68102,5,69762,69762,7,70067,70069,7,70371,70378,5,70720,70721,7,71087,71087,5,71341,71341,5,71995,71996,5,72249,72249,7,72850,72871,5,73109,73109,5,118576,118598,5,121505,121519,5,127245,127247,14,127568,127569,14,127777,127777,14,127872,127891,14,127956,127967,14,128015,128016,14,128110,128172,14,128259,128259,14,128367,128368,14,128424,128424,14,128488,128488,14,128530,128532,14,128550,128551,14,128566,128566,14,128647,128647,14,128656,128656,14,128667,128673,14,128691,128693,14,128715,128715,14,128728,128732,14,128752,128752,14,128765,128767,14,129096,129103,14,129311,129311,14,129344,129349,14,129394,129394,14,129413,129425,14,129466,129471,14,129511,129535,14,129664,129666,14,129719,129722,14,129760,129767,14,917536,917631,5,13,13,2,1160,1161,5,1564,1564,4,1807,1807,1,2085,2087,5,2307,2307,7,2382,2383,7,2497,2500,5,2563,2563,7,2677,2677,5,2763,2764,7,2879,2879,5,2914,2915,5,3021,3021,5,3142,3144,5,3263,3263,5,3285,3286,5,3398,3400,7,3530,3530,5,3633,3633,5,3864,3865,5,3974,3975,5,4155,4156,7,4229,4230,5,5909,5909,7,6078,6085,7,6277,6278,5,6451,6456,7,6744,6750,5,6846,6846,5,6972,6972,5,7074,7077,5,7146,7148,7,7222,7223,5,7416,7417,5,8234,8238,4,8417,8417,5,9000,9000,14,9203,9203,14,9730,9731,14,9748,9749,14,9762,9763,14,9776,9783,14,9800,9811,14,9831,9831,14,9872,9873,14,9882,9882,14,9900,9903,14,9929,9933,14,9941,9960,14,9974,9974,14,9989,9989,14,10006,10006,14,10062,10062,14,10160,10160,14,11647,11647,5,12953,12953,14,43019,43019,5,43232,43249,5,43443,43443,5,43567,43568,7,43696,43696,5,43765,43765,7,44013,44013,5,44117,44143,12,44229,44255,12,44341,44367,12,44453,44479,12,44565,44591,12,44677,44703,12,44789,44815,12,44901,44927,12,45013,45039,12,45125,45151,12,45237,45263,12,45349,45375,12,45461,45487,12,45573,45599,12,45685,45711,12,45797,45823,12,45909,45935,12,46021,46047,12,46133,46159,12,46245,46271,12,46357,46383,12,46469,46495,12,46581,46607,12,46693,46719,12,46805,46831,12,46917,46943,12,47029,47055,12,47141,47167,12,47253,47279,12,47365,47391,12,47477,47503,12,47589,47615,12,47701,47727,12,47813,47839,12,47925,47951,12,48037,48063,12,48149,48175,12,48261,48287,12,48373,48399,12,48485,48511,12,48597,48623,12,48709,48735,12,48821,48847,12,48933,48959,12,49045,49071,12,49157,49183,12,49269,49295,12,49381,49407,12,49493,49519,12,49605,49631,12,49717,49743,12,49829,49855,12,49941,49967,12,50053,50079,12,50165,50191,12,50277,50303,12,50389,50415,12,50501,50527,12,50613,50639,12,50725,50751,12,50837,50863,12,50949,50975,12,51061,51087,12,51173,51199,12,51285,51311,12,51397,51423,12,51509,51535,12,51621,51647,12,51733,51759,12,51845,51871,12,51957,51983,12,52069,52095,12,52181,52207,12,52293,52319,12,52405,52431,12,52517,52543,12,52629,52655,12,52741,52767,12,52853,52879,12,52965,52991,12,53077,53103,12,53189,53215,12,53301,53327,12,53413,53439,12,53525,53551,12,53637,53663,12,53749,53775,12,53861,53887,12,53973,53999,12,54085,54111,12,54197,54223,12,54309,54335,12,54421,54447,12,54533,54559,12,54645,54671,12,54757,54783,12,54869,54895,12,54981,55007,12,55093,55119,12,55243,55291,10,66045,66045,5,68325,68326,5,69688,69702,5,69817,69818,5,69957,69958,7,70089,70092,5,70198,70199,5,70462,70462,5,70502,70508,5,70750,70750,5,70846,70846,7,71100,71101,5,71230,71230,7,71351,71351,5,71737,71738,5,72000,72000,7,72160,72160,5,72273,72278,5,72752,72758,5,72882,72883,5,73031,73031,5,73461,73462,7,94192,94193,7,119149,119149,7,121403,121452,5,122915,122916,5,126980,126980,14,127358,127359,14,127535,127535,14,127759,127759,14,127771,127771,14,127792,127793,14,127825,127867,14,127897,127899,14,127945,127945,14,127985,127986,14,128000,128007,14,128021,128021,14,128066,128100,14,128184,128235,14,128249,128252,14,128266,128276,14,128335,128335,14,128379,128390,14,128407,128419,14,128444,128444,14,128481,128481,14,128499,128499,14,128526,128526,14,128536,128536,14,128543,128543,14,128556,128556,14,128564,128564,14,128577,128580,14,128643,128645,14,128649,128649,14,128654,128654,14,128660,128660,14,128664,128664,14,128675,128675,14,128686,128689,14,128695,128696,14,128705,128709,14,128717,128719,14,128725,128725,14,128736,128741,14,128747,128748,14,128755,128755,14,128762,128762,14,128981,128991,14,129009,129023,14,129160,129167,14,129296,129304,14,129320,129327,14,129340,129342,14,129356,129356,14,129388,129392,14,129399,129400,14,129404,129407,14,129432,129442,14,129454,129455,14,129473,129474,14,129485,129487,14,129648,129651,14,129659,129660,14,129671,129679,14,129709,129711,14,129728,129730,14,129751,129753,14,129776,129782,14,917505,917505,4,917760,917999,5,10,10,3,127,159,4,768,879,5,1471,1471,5,1536,1541,1,1648,1648,5,1767,1768,5,1840,1866,5,2070,2073,5,2137,2139,5,2274,2274,1,2363,2363,7,2377,2380,7,2402,2403,5,2494,2494,5,2507,2508,7,2558,2558,5,2622,2624,7,2641,2641,5,2691,2691,7,2759,2760,5,2786,2787,5,2876,2876,5,2881,2884,5,2901,2902,5,3006,3006,5,3014,3016,7,3072,3072,5,3134,3136,5,3157,3158,5,3260,3260,5,3266,3266,5,3274,3275,7,3328,3329,5,3391,3392,7,3405,3405,5,3457,3457,5,3536,3537,7,3551,3551,5,3636,3642,5,3764,3772,5,3895,3895,5,3967,3967,7,3993,4028,5,4146,4151,5,4182,4183,7,4226,4226,5,4253,4253,5,4957,4959,5,5940,5940,7,6070,6070,7,6087,6088,7,6158,6158,4,6432,6434,5,6448,6449,7,6679,6680,5,6742,6742,5,6754,6754,5,6783,6783,5,6912,6915,5,6966,6970,5,6978,6978,5,7042,7042,7,7080,7081,5,7143,7143,7,7150,7150,7,7212,7219,5,7380,7392,5,7412,7412,5,8203,8203,4,8232,8232,4,8265,8265,14,8400,8412,5,8421,8432,5,8617,8618,14,9167,9167,14,9200,9200,14,9410,9410,14,9723,9726,14,9733,9733,14,9745,9745,14,9752,9752,14,9760,9760,14,9766,9766,14,9774,9774,14,9786,9786,14,9794,9794,14,9823,9823,14,9828,9828,14,9833,9850,14,9855,9855,14,9875,9875,14,9880,9880,14,9885,9887,14,9896,9897,14,9906,9916,14,9926,9927,14,9935,9935,14,9939,9939,14,9962,9962,14,9972,9972,14,9978,9978,14,9986,9986,14,9997,9997,14,10002,10002,14,10017,10017,14,10055,10055,14,10071,10071,14,10133,10135,14,10548,10549,14,11093,11093,14,12330,12333,5,12441,12442,5,42608,42610,5,43010,43010,5,43045,43046,5,43188,43203,7,43302,43309,5,43392,43394,5,43446,43449,5,43493,43493,5,43571,43572,7,43597,43597,7,43703,43704,5,43756,43757,5,44003,44004,7,44009,44010,7,44033,44059,12,44089,44115,12,44145,44171,12,44201,44227,12,44257,44283,12,44313,44339,12,44369,44395,12,44425,44451,12,44481,44507,12,44537,44563,12,44593,44619,12,44649,44675,12,44705,44731,12,44761,44787,12,44817,44843,12,44873,44899,12,44929,44955,12,44985,45011,12,45041,45067,12,45097,45123,12,45153,45179,12,45209,45235,12,45265,45291,12,45321,45347,12,45377,45403,12,45433,45459,12,45489,45515,12,45545,45571,12,45601,45627,12,45657,45683,12,45713,45739,12,45769,45795,12,45825,45851,12,45881,45907,12,45937,45963,12,45993,46019,12,46049,46075,12,46105,46131,12,46161,46187,12,46217,46243,12,46273,46299,12,46329,46355,12,46385,46411,12,46441,46467,12,46497,46523,12,46553,46579,12,46609,46635,12,46665,46691,12,46721,46747,12,46777,46803,12,46833,46859,12,46889,46915,12,46945,46971,12,47001,47027,12,47057,47083,12,47113,47139,12,47169,47195,12,47225,47251,12,47281,47307,12,47337,47363,12,47393,47419,12,47449,47475,12,47505,47531,12,47561,47587,12,47617,47643,12,47673,47699,12,47729,47755,12,47785,47811,12,47841,47867,12,47897,47923,12,47953,47979,12,48009,48035,12,48065,48091,12,48121,48147,12,48177,48203,12,48233,48259,12,48289,48315,12,48345,48371,12,48401,48427,12,48457,48483,12,48513,48539,12,48569,48595,12,48625,48651,12,48681,48707,12,48737,48763,12,48793,48819,12,48849,48875,12,48905,48931,12,48961,48987,12,49017,49043,12,49073,49099,12,49129,49155,12,49185,49211,12,49241,49267,12,49297,49323,12,49353,49379,12,49409,49435,12,49465,49491,12,49521,49547,12,49577,49603,12,49633,49659,12,49689,49715,12,49745,49771,12,49801,49827,12,49857,49883,12,49913,49939,12,49969,49995,12,50025,50051,12,50081,50107,12,50137,50163,12,50193,50219,12,50249,50275,12,50305,50331,12,50361,50387,12,50417,50443,12,50473,50499,12,50529,50555,12,50585,50611,12,50641,50667,12,50697,50723,12,50753,50779,12,50809,50835,12,50865,50891,12,50921,50947,12,50977,51003,12,51033,51059,12,51089,51115,12,51145,51171,12,51201,51227,12,51257,51283,12,51313,51339,12,51369,51395,12,51425,51451,12,51481,51507,12,51537,51563,12,51593,51619,12,51649,51675,12,51705,51731,12,51761,51787,12,51817,51843,12,51873,51899,12,51929,51955,12,51985,52011,12,52041,52067,12,52097,52123,12,52153,52179,12,52209,52235,12,52265,52291,12,52321,52347,12,52377,52403,12,52433,52459,12,52489,52515,12,52545,52571,12,52601,52627,12,52657,52683,12,52713,52739,12,52769,52795,12,52825,52851,12,52881,52907,12,52937,52963,12,52993,53019,12,53049,53075,12,53105,53131,12,53161,53187,12,53217,53243,12,53273,53299,12,53329,53355,12,53385,53411,12,53441,53467,12,53497,53523,12,53553,53579,12,53609,53635,12,53665,53691,12,53721,53747,12,53777,53803,12,53833,53859,12,53889,53915,12,53945,53971,12,54001,54027,12,54057,54083,12,54113,54139,12,54169,54195,12,54225,54251,12,54281,54307,12,54337,54363,12,54393,54419,12,54449,54475,12,54505,54531,12,54561,54587,12,54617,54643,12,54673,54699,12,54729,54755,12,54785,54811,12,54841,54867,12,54897,54923,12,54953,54979,12,55009,55035,12,55065,55091,12,55121,55147,12,55177,55203,12,65024,65039,5,65520,65528,4,66422,66426,5,68152,68154,5,69291,69292,5,69633,69633,5,69747,69748,5,69811,69814,5,69826,69826,5,69932,69932,7,70016,70017,5,70079,70080,7,70095,70095,5,70196,70196,5,70367,70367,5,70402,70403,7,70464,70464,5,70487,70487,5,70709,70711,7,70725,70725,7,70833,70834,7,70843,70844,7,70849,70849,7,71090,71093,5,71103,71104,5,71227,71228,7,71339,71339,5,71344,71349,5,71458,71461,5,71727,71735,5,71985,71989,7,71998,71998,5,72002,72002,7,72154,72155,5,72193,72202,5,72251,72254,5,72281,72283,5,72344,72345,5,72766,72766,7,72874,72880,5,72885,72886,5,73023,73029,5,73104,73105,5,73111,73111,5,92912,92916,5,94095,94098,5,113824,113827,4,119142,119142,7,119155,119162,4,119362,119364,5,121476,121476,5,122888,122904,5,123184,123190,5,125252,125258,5,127183,127183,14,127340,127343,14,127377,127386,14,127491,127503,14,127548,127551,14,127744,127756,14,127761,127761,14,127769,127769,14,127773,127774,14,127780,127788,14,127796,127797,14,127820,127823,14,127869,127869,14,127894,127895,14,127902,127903,14,127943,127943,14,127947,127950,14,127972,127972,14,127988,127988,14,127992,127994,14,128009,128011,14,128019,128019,14,128023,128041,14,128064,128064,14,128102,128107,14,128174,128181,14,128238,128238,14,128246,128247,14,128254,128254,14,128264,128264,14,128278,128299,14,128329,128330,14,128348,128359,14,128371,128377,14,128392,128393,14,128401,128404,14,128421,128421,14,128433,128434,14,128450,128452,14,128476,128478,14,128483,128483,14,128495,128495,14,128506,128506,14,128519,128520,14,128528,128528,14,128534,128534,14,128538,128538,14,128540,128542,14,128544,128549,14,128552,128555,14,128557,128557,14,128560,128563,14,128565,128565,14,128567,128576,14,128581,128591,14,128641,128642,14,128646,128646,14,128648,128648,14,128650,128651,14,128653,128653,14,128655,128655,14,128657,128659,14,128661,128661,14,128663,128663,14,128665,128666,14,128674,128674,14,128676,128677,14,128679,128685,14,128690,128690,14,128694,128694,14,128697,128702,14,128704,128704,14,128710,128714,14,128716,128716,14,128720,128720,14,128723,128724,14,128726,128727,14,128733,128735,14,128742,128744,14,128746,128746,14,128749,128751,14,128753,128754,14,128756,128758,14,128761,128761,14,128763,128764,14,128884,128895,14,128992,129003,14,129008,129008,14,129036,129039,14,129114,129119,14,129198,129279,14,129293,129295,14,129305,129310,14,129312,129319,14,129328,129328,14,129331,129338,14,129343,129343,14,129351,129355,14,129357,129359,14,129375,129387,14,129393,129393,14,129395,129398,14,129401,129401,14,129403,129403,14,129408,129412,14,129426,129431,14,129443,129444,14,129451,129453,14,129456,129465,14,129472,129472,14,129475,129482,14,129484,129484,14,129488,129510,14,129536,129647,14,129652,129652,14,129656,129658,14,129661,129663,14,129667,129670,14,129680,129685,14,129705,129708,14,129712,129718,14,129723,129727,14,129731,129733,14,129744,129750,14,129754,129759,14,129768,129775,14,129783,129791,14,917504,917504,4,917506,917535,4,917632,917759,4,918000,921599,4,0,9,4,11,12,4,14,31,4,169,169,14,174,174,14,1155,1159,5,1425,1469,5,1473,1474,5,1479,1479,5,1552,1562,5,1611,1631,5,1750,1756,5,1759,1764,5,1770,1773,5,1809,1809,5,1958,1968,5,2045,2045,5,2075,2083,5,2089,2093,5,2192,2193,1,2250,2273,5,2275,2306,5,2362,2362,5,2364,2364,5,2369,2376,5,2381,2381,5,2385,2391,5,2433,2433,5,2492,2492,5,2495,2496,7,2503,2504,7,2509,2509,5,2530,2531,5,2561,2562,5,2620,2620,5,2625,2626,5,2635,2637,5,2672,2673,5,2689,2690,5,2748,2748,5,2753,2757,5,2761,2761,7,2765,2765,5,2810,2815,5,2818,2819,7,2878,2878,5,2880,2880,7,2887,2888,7,2893,2893,5,2903,2903,5,2946,2946,5,3007,3007,7,3009,3010,7,3018,3020,7,3031,3031,5,3073,3075,7,3132,3132,5,3137,3140,7,3146,3149,5,3170,3171,5,3202,3203,7,3262,3262,7,3264,3265,7,3267,3268,7,3271,3272,7,3276,3277,5,3298,3299,5,3330,3331,7,3390,3390,5,3393,3396,5,3402,3404,7,3406,3406,1,3426,3427,5,3458,3459,7,3535,3535,5,3538,3540,5,3544,3550,7,3570,3571,7,3635,3635,7,3655,3662,5,3763,3763,7,3784,3789,5,3893,3893,5,3897,3897,5,3953,3966,5,3968,3972,5,3981,3991,5,4038,4038,5,4145,4145,7,4153,4154,5,4157,4158,5,4184,4185,5,4209,4212,5,4228,4228,7,4237,4237,5,4352,4447,8,4520,4607,10,5906,5908,5,5938,5939,5,5970,5971,5,6068,6069,5,6071,6077,5,6086,6086,5,6089,6099,5,6155,6157,5,6159,6159,5,6313,6313,5,6435,6438,7,6441,6443,7,6450,6450,5,6457,6459,5,6681,6682,7,6741,6741,7,6743,6743,7,6752,6752,5,6757,6764,5,6771,6780,5,6832,6845,5,6847,6862,5,6916,6916,7,6965,6965,5,6971,6971,7,6973,6977,7,6979,6980,7,7040,7041,5,7073,7073,7,7078,7079,7,7082,7082,7,7142,7142,5,7144,7145,5,7149,7149,5,7151,7153,5,7204,7211,7,7220,7221,7,7376,7378,5,7393,7393,7,7405,7405,5,7415,7415,7,7616,7679,5,8204,8204,5,8206,8207,4,8233,8233,4,8252,8252,14,8288,8292,4,8294,8303,4,8413,8416,5,8418,8420,5,8482,8482,14,8596,8601,14,8986,8987,14,9096,9096,14,9193,9196,14,9199,9199,14,9201,9202,14,9208,9210,14,9642,9643,14,9664,9664,14,9728,9729,14,9732,9732,14,9735,9741,14,9743,9744,14,9746,9746,14,9750,9751,14,9753,9756,14,9758,9759,14,9761,9761,14,9764,9765,14,9767,9769,14,9771,9773,14,9775,9775,14,9784,9785,14,9787,9791,14,9793,9793,14,9795,9799,14,9812,9822,14,9824,9824,14,9827,9827,14,9829,9830,14,9832,9832,14,9851,9851,14,9854,9854,14,9856,9861,14,9874,9874,14,9876,9876,14,9878,9879,14,9881,9881,14,9883,9884,14,9888,9889,14,9895,9895,14,9898,9899,14,9904,9905,14,9917,9918,14,9924,9925,14,9928,9928,14,9934,9934,14,9936,9936,14,9938,9938,14,9940,9940,14,9961,9961,14,9963,9967,14,9970,9971,14,9973,9973,14,9975,9977,14,9979,9980,14,9982,9985,14,9987,9988,14,9992,9996,14,9998,9998,14,10000,10001,14,10004,10004,14,10013,10013,14,10024,10024,14,10052,10052,14,10060,10060,14,10067,10069,14,10083,10083,14,10085,10087,14,10145,10145,14,10175,10175,14,11013,11015,14,11088,11088,14,11503,11505,5,11744,11775,5,12334,12335,5,12349,12349,14,12951,12951,14,42607,42607,5,42612,42621,5,42736,42737,5,43014,43014,5,43043,43044,7,43047,43047,7,43136,43137,7,43204,43205,5,43263,43263,5,43335,43345,5,43360,43388,8,43395,43395,7,43444,43445,7,43450,43451,7,43454,43456,7,43561,43566,5,43569,43570,5,43573,43574,5,43596,43596,5,43644,43644,5,43698,43700,5,43710,43711,5,43755,43755,7,43758,43759,7,43766,43766,5,44005,44005,5,44008,44008,5,44012,44012,7,44032,44032,11,44060,44060,11,44088,44088,11,44116,44116,11,44144,44144,11,44172,44172,11,44200,44200,11,44228,44228,11,44256,44256,11,44284,44284,11,44312,44312,11,44340,44340,11,44368,44368,11,44396,44396,11,44424,44424,11,44452,44452,11,44480,44480,11,44508,44508,11,44536,44536,11,44564,44564,11,44592,44592,11,44620,44620,11,44648,44648,11,44676,44676,11,44704,44704,11,44732,44732,11,44760,44760,11,44788,44788,11,44816,44816,11,44844,44844,11,44872,44872,11,44900,44900,11,44928,44928,11,44956,44956,11,44984,44984,11,45012,45012,11,45040,45040,11,45068,45068,11,45096,45096,11,45124,45124,11,45152,45152,11,45180,45180,11,45208,45208,11,45236,45236,11,45264,45264,11,45292,45292,11,45320,45320,11,45348,45348,11,45376,45376,11,45404,45404,11,45432,45432,11,45460,45460,11,45488,45488,11,45516,45516,11,45544,45544,11,45572,45572,11,45600,45600,11,45628,45628,11,45656,45656,11,45684,45684,11,45712,45712,11,45740,45740,11,45768,45768,11,45796,45796,11,45824,45824,11,45852,45852,11,45880,45880,11,45908,45908,11,45936,45936,11,45964,45964,11,45992,45992,11,46020,46020,11,46048,46048,11,46076,46076,11,46104,46104,11,46132,46132,11,46160,46160,11,46188,46188,11,46216,46216,11,46244,46244,11,46272,46272,11,46300,46300,11,46328,46328,11,46356,46356,11,46384,46384,11,46412,46412,11,46440,46440,11,46468,46468,11,46496,46496,11,46524,46524,11,46552,46552,11,46580,46580,11,46608,46608,11,46636,46636,11,46664,46664,11,46692,46692,11,46720,46720,11,46748,46748,11,46776,46776,11,46804,46804,11,46832,46832,11,46860,46860,11,46888,46888,11,46916,46916,11,46944,46944,11,46972,46972,11,47000,47000,11,47028,47028,11,47056,47056,11,47084,47084,11,47112,47112,11,47140,47140,11,47168,47168,11,47196,47196,11,47224,47224,11,47252,47252,11,47280,47280,11,47308,47308,11,47336,47336,11,47364,47364,11,47392,47392,11,47420,47420,11,47448,47448,11,47476,47476,11,47504,47504,11,47532,47532,11,47560,47560,11,47588,47588,11,47616,47616,11,47644,47644,11,47672,47672,11,47700,47700,11,47728,47728,11,47756,47756,11,47784,47784,11,47812,47812,11,47840,47840,11,47868,47868,11,47896,47896,11,47924,47924,11,47952,47952,11,47980,47980,11,48008,48008,11,48036,48036,11,48064,48064,11,48092,48092,11,48120,48120,11,48148,48148,11,48176,48176,11,48204,48204,11,48232,48232,11,48260,48260,11,48288,48288,11,48316,48316,11,48344,48344,11,48372,48372,11,48400,48400,11,48428,48428,11,48456,48456,11,48484,48484,11,48512,48512,11,48540,48540,11,48568,48568,11,48596,48596,11,48624,48624,11,48652,48652,11,48680,48680,11,48708,48708,11,48736,48736,11,48764,48764,11,48792,48792,11,48820,48820,11,48848,48848,11,48876,48876,11,48904,48904,11,48932,48932,11,48960,48960,11,48988,48988,11,49016,49016,11,49044,49044,11,49072,49072,11,49100,49100,11,49128,49128,11,49156,49156,11,49184,49184,11,49212,49212,11,49240,49240,11,49268,49268,11,49296,49296,11,49324,49324,11,49352,49352,11,49380,49380,11,49408,49408,11,49436,49436,11,49464,49464,11,49492,49492,11,49520,49520,11,49548,49548,11,49576,49576,11,49604,49604,11,49632,49632,11,49660,49660,11,49688,49688,11,49716,49716,11,49744,49744,11,49772,49772,11,49800,49800,11,49828,49828,11,49856,49856,11,49884,49884,11,49912,49912,11,49940,49940,11,49968,49968,11,49996,49996,11,50024,50024,11,50052,50052,11,50080,50080,11,50108,50108,11,50136,50136,11,50164,50164,11,50192,50192,11,50220,50220,11,50248,50248,11,50276,50276,11,50304,50304,11,50332,50332,11,50360,50360,11,50388,50388,11,50416,50416,11,50444,50444,11,50472,50472,11,50500,50500,11,50528,50528,11,50556,50556,11,50584,50584,11,50612,50612,11,50640,50640,11,50668,50668,11,50696,50696,11,50724,50724,11,50752,50752,11,50780,50780,11,50808,50808,11,50836,50836,11,50864,50864,11,50892,50892,11,50920,50920,11,50948,50948,11,50976,50976,11,51004,51004,11,51032,51032,11,51060,51060,11,51088,51088,11,51116,51116,11,51144,51144,11,51172,51172,11,51200,51200,11,51228,51228,11,51256,51256,11,51284,51284,11,51312,51312,11,51340,51340,11,51368,51368,11,51396,51396,11,51424,51424,11,51452,51452,11,51480,51480,11,51508,51508,11,51536,51536,11,51564,51564,11,51592,51592,11,51620,51620,11,51648,51648,11,51676,51676,11,51704,51704,11,51732,51732,11,51760,51760,11,51788,51788,11,51816,51816,11,51844,51844,11,51872,51872,11,51900,51900,11,51928,51928,11,51956,51956,11,51984,51984,11,52012,52012,11,52040,52040,11,52068,52068,11,52096,52096,11,52124,52124,11,52152,52152,11,52180,52180,11,52208,52208,11,52236,52236,11,52264,52264,11,52292,52292,11,52320,52320,11,52348,52348,11,52376,52376,11,52404,52404,11,52432,52432,11,52460,52460,11,52488,52488,11,52516,52516,11,52544,52544,11,52572,52572,11,52600,52600,11,52628,52628,11,52656,52656,11,52684,52684,11,52712,52712,11,52740,52740,11,52768,52768,11,52796,52796,11,52824,52824,11,52852,52852,11,52880,52880,11,52908,52908,11,52936,52936,11,52964,52964,11,52992,52992,11,53020,53020,11,53048,53048,11,53076,53076,11,53104,53104,11,53132,53132,11,53160,53160,11,53188,53188,11,53216,53216,11,53244,53244,11,53272,53272,11,53300,53300,11,53328,53328,11,53356,53356,11,53384,53384,11,53412,53412,11,53440,53440,11,53468,53468,11,53496,53496,11,53524,53524,11,53552,53552,11,53580,53580,11,53608,53608,11,53636,53636,11,53664,53664,11,53692,53692,11,53720,53720,11,53748,53748,11,53776,53776,11,53804,53804,11,53832,53832,11,53860,53860,11,53888,53888,11,53916,53916,11,53944,53944,11,53972,53972,11,54000,54000,11,54028,54028,11,54056,54056,11,54084,54084,11,54112,54112,11,54140,54140,11,54168,54168,11,54196,54196,11,54224,54224,11,54252,54252,11,54280,54280,11,54308,54308,11,54336,54336,11,54364,54364,11,54392,54392,11,54420,54420,11,54448,54448,11,54476,54476,11,54504,54504,11,54532,54532,11,54560,54560,11,54588,54588,11,54616,54616,11,54644,54644,11,54672,54672,11,54700,54700,11,54728,54728,11,54756,54756,11,54784,54784,11,54812,54812,11,54840,54840,11,54868,54868,11,54896,54896,11,54924,54924,11,54952,54952,11,54980,54980,11,55008,55008,11,55036,55036,11,55064,55064,11,55092,55092,11,55120,55120,11,55148,55148,11,55176,55176,11,55216,55238,9,64286,64286,5,65056,65071,5,65438,65439,5,65529,65531,4,66272,66272,5,68097,68099,5,68108,68111,5,68159,68159,5,68900,68903,5,69446,69456,5,69632,69632,7,69634,69634,7,69744,69744,5,69759,69761,5,69808,69810,7,69815,69816,7,69821,69821,1,69837,69837,1,69927,69931,5,69933,69940,5,70003,70003,5,70018,70018,7,70070,70078,5,70082,70083,1,70094,70094,7,70188,70190,7,70194,70195,7,70197,70197,7,70206,70206,5,70368,70370,7,70400,70401,5,70459,70460,5,70463,70463,7,70465,70468,7,70475,70477,7,70498,70499,7,70512,70516,5,70712,70719,5,70722,70724,5,70726,70726,5,70832,70832,5,70835,70840,5,70842,70842,5,70845,70845,5,70847,70848,5,70850,70851,5,71088,71089,7,71096,71099,7,71102,71102,7,71132,71133,5,71219,71226,5,71229,71229,5,71231,71232,5,71340,71340,7,71342,71343,7,71350,71350,7,71453,71455,5,71462,71462,7,71724,71726,7,71736,71736,7,71984,71984,5,71991,71992,7,71997,71997,7,71999,71999,1,72001,72001,1,72003,72003,5,72148,72151,5,72156,72159,7,72164,72164,7,72243,72248,5,72250,72250,1,72263,72263,5,72279,72280,7,72324,72329,1,72343,72343,7,72751,72751,7,72760,72765,5,72767,72767,5,72873,72873,7,72881,72881,7,72884,72884,7,73009,73014,5,73020,73021,5,73030,73030,1,73098,73102,7,73107,73108,7,73110,73110,7,73459,73460,5,78896,78904,4,92976,92982,5,94033,94087,7,94180,94180,5,113821,113822,5,118528,118573,5,119141,119141,5,119143,119145,5,119150,119154,5,119163,119170,5,119210,119213,5,121344,121398,5,121461,121461,5,121499,121503,5,122880,122886,5,122907,122913,5,122918,122922,5,123566,123566,5,125136,125142,5,126976,126979,14,126981,127182,14,127184,127231,14,127279,127279,14,127344,127345,14,127374,127374,14,127405,127461,14,127489,127490,14,127514,127514,14,127538,127546,14,127561,127567,14,127570,127743,14,127757,127758,14,127760,127760,14,127762,127762,14,127766,127768,14,127770,127770,14,127772,127772,14,127775,127776,14,127778,127779,14,127789,127791,14,127794,127795,14,127798,127798,14,127819,127819,14,127824,127824,14,127868,127868,14,127870,127871,14,127892,127893,14,127896,127896,14,127900,127901,14,127904,127940,14,127942,127942,14,127944,127944,14,127946,127946,14,127951,127955,14,127968,127971,14,127973,127984,14,127987,127987,14,127989,127989,14,127991,127991,14,127995,127999,5,128008,128008,14,128012,128014,14,128017,128018,14,128020,128020,14,128022,128022,14,128042,128042,14,128063,128063,14,128065,128065,14,128101,128101,14,128108,128109,14,128173,128173,14,128182,128183,14,128236,128237,14,128239,128239,14,128245,128245,14,128248,128248,14,128253,128253,14,128255,128258,14,128260,128263,14,128265,128265,14,128277,128277,14,128300,128301,14,128326,128328,14,128331,128334,14,128336,128347,14,128360,128366,14,128369,128370,14,128378,128378,14,128391,128391,14,128394,128397,14,128400,128400,14,128405,128406,14,128420,128420,14,128422,128423,14,128425,128432,14,128435,128443,14,128445,128449,14,128453,128464,14,128468,128475,14,128479,128480,14,128482,128482,14,128484,128487,14,128489,128494,14,128496,128498,14,128500,128505,14,128507,128511,14,128513,128518,14,128521,128525,14,128527,128527,14,128529,128529,14,128533,128533,14,128535,128535,14,128537,128537,14]")}getGraphemeBreakType(e){if(e<32)return 10===e?3:13===e?2:4;if(e<127)return 0;let t=this._data,i=t.length/3,n=1;for(;n<=i;)if(et[3*n+1]))return t[3*n+2];n=2*n+1}return 0}}og._INSTANCE=null;class op{static getInstance(e){return op.cache.get(Array.from(e))}static getLocales(){return op._locales.value}constructor(e){this.confusableDictionary=e}isAmbiguous(e){return this.confusableDictionary.has(e)}getPrimaryConfusable(e){return this.confusableDictionary.get(e)}getConfusableCodePoints(){return new Set(this.confusableDictionary.keys())}}op.ambiguousCharacterData=new rF(()=>JSON.parse('{"_common":[8232,32,8233,32,5760,32,8192,32,8193,32,8194,32,8195,32,8196,32,8197,32,8198,32,8200,32,8201,32,8202,32,8287,32,8199,32,8239,32,2042,95,65101,95,65102,95,65103,95,8208,45,8209,45,8210,45,65112,45,1748,45,8259,45,727,45,8722,45,10134,45,11450,45,1549,44,1643,44,8218,44,184,44,42233,44,894,59,2307,58,2691,58,1417,58,1795,58,1796,58,5868,58,65072,58,6147,58,6153,58,8282,58,1475,58,760,58,42889,58,8758,58,720,58,42237,58,451,33,11601,33,660,63,577,63,2429,63,5038,63,42731,63,119149,46,8228,46,1793,46,1794,46,42510,46,68176,46,1632,46,1776,46,42232,46,1373,96,65287,96,8219,96,8242,96,1370,96,1523,96,8175,96,65344,96,900,96,8189,96,8125,96,8127,96,8190,96,697,96,884,96,712,96,714,96,715,96,756,96,699,96,701,96,700,96,702,96,42892,96,1497,96,2036,96,2037,96,5194,96,5836,96,94033,96,94034,96,65339,91,10088,40,10098,40,12308,40,64830,40,65341,93,10089,41,10099,41,12309,41,64831,41,10100,123,119060,123,10101,125,65342,94,8270,42,1645,42,8727,42,66335,42,5941,47,8257,47,8725,47,8260,47,9585,47,10187,47,10744,47,119354,47,12755,47,12339,47,11462,47,20031,47,12035,47,65340,92,65128,92,8726,92,10189,92,10741,92,10745,92,119311,92,119355,92,12756,92,20022,92,12034,92,42872,38,708,94,710,94,5869,43,10133,43,66203,43,8249,60,10094,60,706,60,119350,60,5176,60,5810,60,5120,61,11840,61,12448,61,42239,61,8250,62,10095,62,707,62,119351,62,5171,62,94015,62,8275,126,732,126,8128,126,8764,126,65372,124,65293,45,120784,50,120794,50,120804,50,120814,50,120824,50,130034,50,42842,50,423,50,1000,50,42564,50,5311,50,42735,50,119302,51,120785,51,120795,51,120805,51,120815,51,120825,51,130035,51,42923,51,540,51,439,51,42858,51,11468,51,1248,51,94011,51,71882,51,120786,52,120796,52,120806,52,120816,52,120826,52,130036,52,5070,52,71855,52,120787,53,120797,53,120807,53,120817,53,120827,53,130037,53,444,53,71867,53,120788,54,120798,54,120808,54,120818,54,120828,54,130038,54,11474,54,5102,54,71893,54,119314,55,120789,55,120799,55,120809,55,120819,55,120829,55,130039,55,66770,55,71878,55,2819,56,2538,56,2666,56,125131,56,120790,56,120800,56,120810,56,120820,56,120830,56,130040,56,547,56,546,56,66330,56,2663,57,2920,57,2541,57,3437,57,120791,57,120801,57,120811,57,120821,57,120831,57,130041,57,42862,57,11466,57,71884,57,71852,57,71894,57,9082,97,65345,97,119834,97,119886,97,119938,97,119990,97,120042,97,120094,97,120146,97,120198,97,120250,97,120302,97,120354,97,120406,97,120458,97,593,97,945,97,120514,97,120572,97,120630,97,120688,97,120746,97,65313,65,119808,65,119860,65,119912,65,119964,65,120016,65,120068,65,120120,65,120172,65,120224,65,120276,65,120328,65,120380,65,120432,65,913,65,120488,65,120546,65,120604,65,120662,65,120720,65,5034,65,5573,65,42222,65,94016,65,66208,65,119835,98,119887,98,119939,98,119991,98,120043,98,120095,98,120147,98,120199,98,120251,98,120303,98,120355,98,120407,98,120459,98,388,98,5071,98,5234,98,5551,98,65314,66,8492,66,119809,66,119861,66,119913,66,120017,66,120069,66,120121,66,120173,66,120225,66,120277,66,120329,66,120381,66,120433,66,42932,66,914,66,120489,66,120547,66,120605,66,120663,66,120721,66,5108,66,5623,66,42192,66,66178,66,66209,66,66305,66,65347,99,8573,99,119836,99,119888,99,119940,99,119992,99,120044,99,120096,99,120148,99,120200,99,120252,99,120304,99,120356,99,120408,99,120460,99,7428,99,1010,99,11429,99,43951,99,66621,99,128844,67,71922,67,71913,67,65315,67,8557,67,8450,67,8493,67,119810,67,119862,67,119914,67,119966,67,120018,67,120174,67,120226,67,120278,67,120330,67,120382,67,120434,67,1017,67,11428,67,5087,67,42202,67,66210,67,66306,67,66581,67,66844,67,8574,100,8518,100,119837,100,119889,100,119941,100,119993,100,120045,100,120097,100,120149,100,120201,100,120253,100,120305,100,120357,100,120409,100,120461,100,1281,100,5095,100,5231,100,42194,100,8558,68,8517,68,119811,68,119863,68,119915,68,119967,68,120019,68,120071,68,120123,68,120175,68,120227,68,120279,68,120331,68,120383,68,120435,68,5024,68,5598,68,5610,68,42195,68,8494,101,65349,101,8495,101,8519,101,119838,101,119890,101,119942,101,120046,101,120098,101,120150,101,120202,101,120254,101,120306,101,120358,101,120410,101,120462,101,43826,101,1213,101,8959,69,65317,69,8496,69,119812,69,119864,69,119916,69,120020,69,120072,69,120124,69,120176,69,120228,69,120280,69,120332,69,120384,69,120436,69,917,69,120492,69,120550,69,120608,69,120666,69,120724,69,11577,69,5036,69,42224,69,71846,69,71854,69,66182,69,119839,102,119891,102,119943,102,119995,102,120047,102,120099,102,120151,102,120203,102,120255,102,120307,102,120359,102,120411,102,120463,102,43829,102,42905,102,383,102,7837,102,1412,102,119315,70,8497,70,119813,70,119865,70,119917,70,120021,70,120073,70,120125,70,120177,70,120229,70,120281,70,120333,70,120385,70,120437,70,42904,70,988,70,120778,70,5556,70,42205,70,71874,70,71842,70,66183,70,66213,70,66853,70,65351,103,8458,103,119840,103,119892,103,119944,103,120048,103,120100,103,120152,103,120204,103,120256,103,120308,103,120360,103,120412,103,120464,103,609,103,7555,103,397,103,1409,103,119814,71,119866,71,119918,71,119970,71,120022,71,120074,71,120126,71,120178,71,120230,71,120282,71,120334,71,120386,71,120438,71,1292,71,5056,71,5107,71,42198,71,65352,104,8462,104,119841,104,119945,104,119997,104,120049,104,120101,104,120153,104,120205,104,120257,104,120309,104,120361,104,120413,104,120465,104,1211,104,1392,104,5058,104,65320,72,8459,72,8460,72,8461,72,119815,72,119867,72,119919,72,120023,72,120179,72,120231,72,120283,72,120335,72,120387,72,120439,72,919,72,120494,72,120552,72,120610,72,120668,72,120726,72,11406,72,5051,72,5500,72,42215,72,66255,72,731,105,9075,105,65353,105,8560,105,8505,105,8520,105,119842,105,119894,105,119946,105,119998,105,120050,105,120102,105,120154,105,120206,105,120258,105,120310,105,120362,105,120414,105,120466,105,120484,105,618,105,617,105,953,105,8126,105,890,105,120522,105,120580,105,120638,105,120696,105,120754,105,1110,105,42567,105,1231,105,43893,105,5029,105,71875,105,65354,106,8521,106,119843,106,119895,106,119947,106,119999,106,120051,106,120103,106,120155,106,120207,106,120259,106,120311,106,120363,106,120415,106,120467,106,1011,106,1112,106,65322,74,119817,74,119869,74,119921,74,119973,74,120025,74,120077,74,120129,74,120181,74,120233,74,120285,74,120337,74,120389,74,120441,74,42930,74,895,74,1032,74,5035,74,5261,74,42201,74,119844,107,119896,107,119948,107,120000,107,120052,107,120104,107,120156,107,120208,107,120260,107,120312,107,120364,107,120416,107,120468,107,8490,75,65323,75,119818,75,119870,75,119922,75,119974,75,120026,75,120078,75,120130,75,120182,75,120234,75,120286,75,120338,75,120390,75,120442,75,922,75,120497,75,120555,75,120613,75,120671,75,120729,75,11412,75,5094,75,5845,75,42199,75,66840,75,1472,108,8739,73,9213,73,65512,73,1633,108,1777,73,66336,108,125127,108,120783,73,120793,73,120803,73,120813,73,120823,73,130033,73,65321,73,8544,73,8464,73,8465,73,119816,73,119868,73,119920,73,120024,73,120128,73,120180,73,120232,73,120284,73,120336,73,120388,73,120440,73,65356,108,8572,73,8467,108,119845,108,119897,108,119949,108,120001,108,120053,108,120105,73,120157,73,120209,73,120261,73,120313,73,120365,73,120417,73,120469,73,448,73,120496,73,120554,73,120612,73,120670,73,120728,73,11410,73,1030,73,1216,73,1493,108,1503,108,1575,108,126464,108,126592,108,65166,108,65165,108,1994,108,11599,73,5825,73,42226,73,93992,73,66186,124,66313,124,119338,76,8556,76,8466,76,119819,76,119871,76,119923,76,120027,76,120079,76,120131,76,120183,76,120235,76,120287,76,120339,76,120391,76,120443,76,11472,76,5086,76,5290,76,42209,76,93974,76,71843,76,71858,76,66587,76,66854,76,65325,77,8559,77,8499,77,119820,77,119872,77,119924,77,120028,77,120080,77,120132,77,120184,77,120236,77,120288,77,120340,77,120392,77,120444,77,924,77,120499,77,120557,77,120615,77,120673,77,120731,77,1018,77,11416,77,5047,77,5616,77,5846,77,42207,77,66224,77,66321,77,119847,110,119899,110,119951,110,120003,110,120055,110,120107,110,120159,110,120211,110,120263,110,120315,110,120367,110,120419,110,120471,110,1400,110,1404,110,65326,78,8469,78,119821,78,119873,78,119925,78,119977,78,120029,78,120081,78,120185,78,120237,78,120289,78,120341,78,120393,78,120445,78,925,78,120500,78,120558,78,120616,78,120674,78,120732,78,11418,78,42208,78,66835,78,3074,111,3202,111,3330,111,3458,111,2406,111,2662,111,2790,111,3046,111,3174,111,3302,111,3430,111,3664,111,3792,111,4160,111,1637,111,1781,111,65359,111,8500,111,119848,111,119900,111,119952,111,120056,111,120108,111,120160,111,120212,111,120264,111,120316,111,120368,111,120420,111,120472,111,7439,111,7441,111,43837,111,959,111,120528,111,120586,111,120644,111,120702,111,120760,111,963,111,120532,111,120590,111,120648,111,120706,111,120764,111,11423,111,4351,111,1413,111,1505,111,1607,111,126500,111,126564,111,126596,111,65259,111,65260,111,65258,111,65257,111,1726,111,64428,111,64429,111,64427,111,64426,111,1729,111,64424,111,64425,111,64423,111,64422,111,1749,111,3360,111,4125,111,66794,111,71880,111,71895,111,66604,111,1984,79,2534,79,2918,79,12295,79,70864,79,71904,79,120782,79,120792,79,120802,79,120812,79,120822,79,130032,79,65327,79,119822,79,119874,79,119926,79,119978,79,120030,79,120082,79,120134,79,120186,79,120238,79,120290,79,120342,79,120394,79,120446,79,927,79,120502,79,120560,79,120618,79,120676,79,120734,79,11422,79,1365,79,11604,79,4816,79,2848,79,66754,79,42227,79,71861,79,66194,79,66219,79,66564,79,66838,79,9076,112,65360,112,119849,112,119901,112,119953,112,120005,112,120057,112,120109,112,120161,112,120213,112,120265,112,120317,112,120369,112,120421,112,120473,112,961,112,120530,112,120544,112,120588,112,120602,112,120646,112,120660,112,120704,112,120718,112,120762,112,120776,112,11427,112,65328,80,8473,80,119823,80,119875,80,119927,80,119979,80,120031,80,120083,80,120187,80,120239,80,120291,80,120343,80,120395,80,120447,80,929,80,120504,80,120562,80,120620,80,120678,80,120736,80,11426,80,5090,80,5229,80,42193,80,66197,80,119850,113,119902,113,119954,113,120006,113,120058,113,120110,113,120162,113,120214,113,120266,113,120318,113,120370,113,120422,113,120474,113,1307,113,1379,113,1382,113,8474,81,119824,81,119876,81,119928,81,119980,81,120032,81,120084,81,120188,81,120240,81,120292,81,120344,81,120396,81,120448,81,11605,81,119851,114,119903,114,119955,114,120007,114,120059,114,120111,114,120163,114,120215,114,120267,114,120319,114,120371,114,120423,114,120475,114,43847,114,43848,114,7462,114,11397,114,43905,114,119318,82,8475,82,8476,82,8477,82,119825,82,119877,82,119929,82,120033,82,120189,82,120241,82,120293,82,120345,82,120397,82,120449,82,422,82,5025,82,5074,82,66740,82,5511,82,42211,82,94005,82,65363,115,119852,115,119904,115,119956,115,120008,115,120060,115,120112,115,120164,115,120216,115,120268,115,120320,115,120372,115,120424,115,120476,115,42801,115,445,115,1109,115,43946,115,71873,115,66632,115,65331,83,119826,83,119878,83,119930,83,119982,83,120034,83,120086,83,120138,83,120190,83,120242,83,120294,83,120346,83,120398,83,120450,83,1029,83,1359,83,5077,83,5082,83,42210,83,94010,83,66198,83,66592,83,119853,116,119905,116,119957,116,120009,116,120061,116,120113,116,120165,116,120217,116,120269,116,120321,116,120373,116,120425,116,120477,116,8868,84,10201,84,128872,84,65332,84,119827,84,119879,84,119931,84,119983,84,120035,84,120087,84,120139,84,120191,84,120243,84,120295,84,120347,84,120399,84,120451,84,932,84,120507,84,120565,84,120623,84,120681,84,120739,84,11430,84,5026,84,42196,84,93962,84,71868,84,66199,84,66225,84,66325,84,119854,117,119906,117,119958,117,120010,117,120062,117,120114,117,120166,117,120218,117,120270,117,120322,117,120374,117,120426,117,120478,117,42911,117,7452,117,43854,117,43858,117,651,117,965,117,120534,117,120592,117,120650,117,120708,117,120766,117,1405,117,66806,117,71896,117,8746,85,8899,85,119828,85,119880,85,119932,85,119984,85,120036,85,120088,85,120140,85,120192,85,120244,85,120296,85,120348,85,120400,85,120452,85,1357,85,4608,85,66766,85,5196,85,42228,85,94018,85,71864,85,8744,118,8897,118,65366,118,8564,118,119855,118,119907,118,119959,118,120011,118,120063,118,120115,118,120167,118,120219,118,120271,118,120323,118,120375,118,120427,118,120479,118,7456,118,957,118,120526,118,120584,118,120642,118,120700,118,120758,118,1141,118,1496,118,71430,118,43945,118,71872,118,119309,86,1639,86,1783,86,8548,86,119829,86,119881,86,119933,86,119985,86,120037,86,120089,86,120141,86,120193,86,120245,86,120297,86,120349,86,120401,86,120453,86,1140,86,11576,86,5081,86,5167,86,42719,86,42214,86,93960,86,71840,86,66845,86,623,119,119856,119,119908,119,119960,119,120012,119,120064,119,120116,119,120168,119,120220,119,120272,119,120324,119,120376,119,120428,119,120480,119,7457,119,1121,119,1309,119,1377,119,71434,119,71438,119,71439,119,43907,119,71919,87,71910,87,119830,87,119882,87,119934,87,119986,87,120038,87,120090,87,120142,87,120194,87,120246,87,120298,87,120350,87,120402,87,120454,87,1308,87,5043,87,5076,87,42218,87,5742,120,10539,120,10540,120,10799,120,65368,120,8569,120,119857,120,119909,120,119961,120,120013,120,120065,120,120117,120,120169,120,120221,120,120273,120,120325,120,120377,120,120429,120,120481,120,5441,120,5501,120,5741,88,9587,88,66338,88,71916,88,65336,88,8553,88,119831,88,119883,88,119935,88,119987,88,120039,88,120091,88,120143,88,120195,88,120247,88,120299,88,120351,88,120403,88,120455,88,42931,88,935,88,120510,88,120568,88,120626,88,120684,88,120742,88,11436,88,11613,88,5815,88,42219,88,66192,88,66228,88,66327,88,66855,88,611,121,7564,121,65369,121,119858,121,119910,121,119962,121,120014,121,120066,121,120118,121,120170,121,120222,121,120274,121,120326,121,120378,121,120430,121,120482,121,655,121,7935,121,43866,121,947,121,8509,121,120516,121,120574,121,120632,121,120690,121,120748,121,1199,121,4327,121,71900,121,65337,89,119832,89,119884,89,119936,89,119988,89,120040,89,120092,89,120144,89,120196,89,120248,89,120300,89,120352,89,120404,89,120456,89,933,89,978,89,120508,89,120566,89,120624,89,120682,89,120740,89,11432,89,1198,89,5033,89,5053,89,42220,89,94019,89,71844,89,66226,89,119859,122,119911,122,119963,122,120015,122,120067,122,120119,122,120171,122,120223,122,120275,122,120327,122,120379,122,120431,122,120483,122,7458,122,43923,122,71876,122,66293,90,71909,90,65338,90,8484,90,8488,90,119833,90,119885,90,119937,90,119989,90,120041,90,120197,90,120249,90,120301,90,120353,90,120405,90,120457,90,918,90,120493,90,120551,90,120609,90,120667,90,120725,90,5059,90,42204,90,71849,90,65282,34,65284,36,65285,37,65286,38,65290,42,65291,43,65294,46,65295,47,65296,48,65297,49,65298,50,65299,51,65300,52,65301,53,65302,54,65303,55,65304,56,65305,57,65308,60,65309,61,65310,62,65312,64,65316,68,65318,70,65319,71,65324,76,65329,81,65330,82,65333,85,65334,86,65335,87,65343,95,65346,98,65348,100,65350,102,65355,107,65357,109,65358,110,65361,113,65362,114,65364,116,65365,117,65367,119,65370,122,65371,123,65373,125,119846,109],"_default":[160,32,8211,45,65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"cs":[65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"de":[65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"es":[8211,45,65374,126,65306,58,65281,33,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"fr":[65374,126,65306,58,65281,33,8216,96,8245,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"it":[160,32,8211,45,65374,126,65306,58,65281,33,8216,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"ja":[8211,45,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65292,44,65307,59],"ko":[8211,45,65374,126,65306,58,65281,33,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"pl":[65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"pt-BR":[65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"qps-ploc":[160,32,8211,45,65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"ru":[65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,305,105,921,73,1009,112,215,120,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"tr":[160,32,8211,45,65374,126,65306,58,65281,33,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"zh-hans":[65374,126,65306,58,65281,33,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65288,40,65289,41],"zh-hant":[8211,45,65374,126,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65307,59]}')),op.cache=new class{constructor(e){this.fn=e,this.lastCache=void 0,this.lastArgKey=void 0}get(e){let t=JSON.stringify(e);return this.lastArgKey!==t&&(this.lastArgKey=t,this.lastCache=this.fn(e)),this.lastCache}}(e=>{let t;function i(e){let t=new Map;for(let i=0;i!e.startsWith("_")&&e in n);for(let e of(0===r.length&&(r=["_default"]),r)){let r=i(n[e]);t=function(e,t){if(!e)return t;let i=new Map;for(let[n,r]of e)t.has(n)&&i.set(n,r);return i}(t,r)}let o=i(n._common),s=function(e,t){let i=new Map(e);for(let[e,n]of t)i.set(e,n);return i}(o,t);return new op(s)}),op._locales=new rF(()=>Object.keys(op.ambiguousCharacterData.value).filter(e=>!e.startsWith("_")));class om{static getRawData(){return JSON.parse("[9,10,11,12,13,32,127,160,173,847,1564,4447,4448,6068,6069,6155,6156,6157,6158,7355,7356,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8203,8204,8205,8206,8207,8234,8235,8236,8237,8238,8239,8287,8288,8289,8290,8291,8292,8293,8294,8295,8296,8297,8298,8299,8300,8301,8302,8303,10240,12288,12644,65024,65025,65026,65027,65028,65029,65030,65031,65032,65033,65034,65035,65036,65037,65038,65039,65279,65440,65520,65521,65522,65523,65524,65525,65526,65527,65528,65532,78844,119155,119156,119157,119158,119159,119160,119161,119162,917504,917505,917506,917507,917508,917509,917510,917511,917512,917513,917514,917515,917516,917517,917518,917519,917520,917521,917522,917523,917524,917525,917526,917527,917528,917529,917530,917531,917532,917533,917534,917535,917536,917537,917538,917539,917540,917541,917542,917543,917544,917545,917546,917547,917548,917549,917550,917551,917552,917553,917554,917555,917556,917557,917558,917559,917560,917561,917562,917563,917564,917565,917566,917567,917568,917569,917570,917571,917572,917573,917574,917575,917576,917577,917578,917579,917580,917581,917582,917583,917584,917585,917586,917587,917588,917589,917590,917591,917592,917593,917594,917595,917596,917597,917598,917599,917600,917601,917602,917603,917604,917605,917606,917607,917608,917609,917610,917611,917612,917613,917614,917615,917616,917617,917618,917619,917620,917621,917622,917623,917624,917625,917626,917627,917628,917629,917630,917631,917760,917761,917762,917763,917764,917765,917766,917767,917768,917769,917770,917771,917772,917773,917774,917775,917776,917777,917778,917779,917780,917781,917782,917783,917784,917785,917786,917787,917788,917789,917790,917791,917792,917793,917794,917795,917796,917797,917798,917799,917800,917801,917802,917803,917804,917805,917806,917807,917808,917809,917810,917811,917812,917813,917814,917815,917816,917817,917818,917819,917820,917821,917822,917823,917824,917825,917826,917827,917828,917829,917830,917831,917832,917833,917834,917835,917836,917837,917838,917839,917840,917841,917842,917843,917844,917845,917846,917847,917848,917849,917850,917851,917852,917853,917854,917855,917856,917857,917858,917859,917860,917861,917862,917863,917864,917865,917866,917867,917868,917869,917870,917871,917872,917873,917874,917875,917876,917877,917878,917879,917880,917881,917882,917883,917884,917885,917886,917887,917888,917889,917890,917891,917892,917893,917894,917895,917896,917897,917898,917899,917900,917901,917902,917903,917904,917905,917906,917907,917908,917909,917910,917911,917912,917913,917914,917915,917916,917917,917918,917919,917920,917921,917922,917923,917924,917925,917926,917927,917928,917929,917930,917931,917932,917933,917934,917935,917936,917937,917938,917939,917940,917941,917942,917943,917944,917945,917946,917947,917948,917949,917950,917951,917952,917953,917954,917955,917956,917957,917958,917959,917960,917961,917962,917963,917964,917965,917966,917967,917968,917969,917970,917971,917972,917973,917974,917975,917976,917977,917978,917979,917980,917981,917982,917983,917984,917985,917986,917987,917988,917989,917990,917991,917992,917993,917994,917995,917996,917997,917998,917999]")}static getData(){return this._data||(this._data=new Set(om.getRawData())),this._data}static isInvisibleCharacter(e){return om.getData().has(e)}static get codePoints(){return om.getData()}}om._data=void 0;class o_{constructor(){this._zoomFactor=1}getZoomFactor(){return this._zoomFactor}}o_.INSTANCE=new o_;class oE extends nc{constructor(){super(),this._onDidChange=this._register(new ny),this.onDidChange=this._onDidChange.event,this._listener=()=>this._handleChange(!0),this._mediaQueryList=null,this._handleChange(!1)}_handleChange(e){var t;null===(t=this._mediaQueryList)||void 0===t||t.removeEventListener("change",this._listener),this._mediaQueryList=window.matchMedia(`(resolution: ${window.devicePixelRatio}dppx)`),this._mediaQueryList.addEventListener("change",this._listener),e&&this._onDidChange.fire()}}class ov extends nc{get value(){return this._value}constructor(){super(),this._onDidChange=this._register(new ny),this.onDidChange=this._onDidChange.event,this._value=this._getPixelRatio();let e=this._register(new oE);this._register(e.onDidChange(()=>{this._value=this._getPixelRatio(),this._onDidChange.fire(this._value)}))}_getPixelRatio(){let e=document.createElement("canvas").getContext("2d"),t=window.devicePixelRatio||1,i=e.webkitBackingStorePixelRatio||e.mozBackingStorePixelRatio||e.msBackingStorePixelRatio||e.oBackingStorePixelRatio||e.backingStorePixelRatio||1;return t/i}}function ob(e,t){"string"==typeof e&&(e=window.matchMedia(e)),e.addEventListener("change",t)}let oC=new class{constructor(){this._pixelRatioMonitor=null}_getOrCreatePixelRatioMonitor(){return this._pixelRatioMonitor||(this._pixelRatioMonitor=new ov),this._pixelRatioMonitor}get value(){return this._getOrCreatePixelRatioMonitor().value}get onDidChange(){return this._getOrCreatePixelRatioMonitor().onDidChange}},oS=navigator.userAgent,oy=oS.indexOf("Firefox")>=0,oT=oS.indexOf("AppleWebKit")>=0,oR=oS.indexOf("Chrome")>=0,oA=!oR&&oS.indexOf("Safari")>=0,oN=!oR&&!oA&&oT;oS.indexOf("Electron/");let oO=oS.indexOf("Android")>=0,oL=!1;if(window.matchMedia){let e=window.matchMedia("(display-mode: standalone) or (display-mode: window-controls-overlay)"),t=window.matchMedia("(display-mode: fullscreen)");oL=e.matches,ob(e,({matches:e})=>{oL&&t.matches||(oL=e)})}class oI{constructor(e){this.domNode=e,this._maxWidth="",this._width="",this._height="",this._top="",this._left="",this._bottom="",this._right="",this._paddingLeft="",this._fontFamily="",this._fontWeight="",this._fontSize="",this._fontStyle="",this._fontFeatureSettings="",this._fontVariationSettings="",this._textDecoration="",this._lineHeight="",this._letterSpacing="",this._className="",this._display="",this._position="",this._visibility="",this._color="",this._backgroundColor="",this._layerHint=!1,this._contain="none",this._boxShadow=""}setMaxWidth(e){let t=ow(e);this._maxWidth!==t&&(this._maxWidth=t,this.domNode.style.maxWidth=this._maxWidth)}setWidth(e){let t=ow(e);this._width!==t&&(this._width=t,this.domNode.style.width=this._width)}setHeight(e){let t=ow(e);this._height!==t&&(this._height=t,this.domNode.style.height=this._height)}setTop(e){let t=ow(e);this._top!==t&&(this._top=t,this.domNode.style.top=this._top)}setLeft(e){let t=ow(e);this._left!==t&&(this._left=t,this.domNode.style.left=this._left)}setBottom(e){let t=ow(e);this._bottom!==t&&(this._bottom=t,this.domNode.style.bottom=this._bottom)}setRight(e){let t=ow(e);this._right!==t&&(this._right=t,this.domNode.style.right=this._right)}setPaddingLeft(e){let t=ow(e);this._paddingLeft!==t&&(this._paddingLeft=t,this.domNode.style.paddingLeft=this._paddingLeft)}setFontFamily(e){this._fontFamily!==e&&(this._fontFamily=e,this.domNode.style.fontFamily=this._fontFamily)}setFontWeight(e){this._fontWeight!==e&&(this._fontWeight=e,this.domNode.style.fontWeight=this._fontWeight)}setFontSize(e){let t=ow(e);this._fontSize!==t&&(this._fontSize=t,this.domNode.style.fontSize=this._fontSize)}setFontStyle(e){this._fontStyle!==e&&(this._fontStyle=e,this.domNode.style.fontStyle=this._fontStyle)}setFontFeatureSettings(e){this._fontFeatureSettings!==e&&(this._fontFeatureSettings=e,this.domNode.style.fontFeatureSettings=this._fontFeatureSettings)}setFontVariationSettings(e){this._fontVariationSettings!==e&&(this._fontVariationSettings=e,this.domNode.style.fontVariationSettings=this._fontVariationSettings)}setTextDecoration(e){this._textDecoration!==e&&(this._textDecoration=e,this.domNode.style.textDecoration=this._textDecoration)}setLineHeight(e){let t=ow(e);this._lineHeight!==t&&(this._lineHeight=t,this.domNode.style.lineHeight=this._lineHeight)}setLetterSpacing(e){let t=ow(e);this._letterSpacing!==t&&(this._letterSpacing=t,this.domNode.style.letterSpacing=this._letterSpacing)}setClassName(e){this._className!==e&&(this._className=e,this.domNode.className=this._className)}toggleClassName(e,t){this.domNode.classList.toggle(e,t),this._className=this.domNode.className}setDisplay(e){this._display!==e&&(this._display=e,this.domNode.style.display=this._display)}setPosition(e){this._position!==e&&(this._position=e,this.domNode.style.position=this._position)}setVisibility(e){this._visibility!==e&&(this._visibility=e,this.domNode.style.visibility=this._visibility)}setColor(e){this._color!==e&&(this._color=e,this.domNode.style.color=this._color)}setBackgroundColor(e){this._backgroundColor!==e&&(this._backgroundColor=e,this.domNode.style.backgroundColor=this._backgroundColor)}setLayerHinting(e){this._layerHint!==e&&(this._layerHint=e,this.domNode.style.transform=this._layerHint?"translate3d(0px, 0px, 0px)":"")}setBoxShadow(e){this._boxShadow!==e&&(this._boxShadow=e,this.domNode.style.boxShadow=e)}setContain(e){this._contain!==e&&(this._contain=e,this.domNode.style.contain=this._contain)}setAttribute(e,t){this.domNode.setAttribute(e,t)}removeAttribute(e){this.domNode.removeAttribute(e)}appendChild(e){this.domNode.appendChild(e.domNode)}removeChild(e){this.domNode.removeChild(e.domNode)}}function ow(e){return"number"==typeof e?`${e}px`:e}function oD(e){return new oI(e)}function ox(e,t){e instanceof oI?(e.setFontFamily(t.getMassagedFontFamily()),e.setFontWeight(t.fontWeight),e.setFontSize(t.fontSize),e.setFontFeatureSettings(t.fontFeatureSettings),e.setFontVariationSettings(t.fontVariationSettings),e.setLineHeight(t.lineHeight),e.setLetterSpacing(t.letterSpacing)):(e.style.fontFamily=t.getMassagedFontFamily(),e.style.fontWeight=t.fontWeight,e.style.fontSize=t.fontSize+"px",e.style.fontFeatureSettings=t.fontFeatureSettings,e.style.fontVariationSettings=t.fontVariationSettings,e.style.lineHeight=t.lineHeight+"px",e.style.letterSpacing=t.letterSpacing+"px")}class oM{constructor(e,t){this.chr=e,this.type=t,this.width=0}fulfill(e){this.width=e}}class ok{constructor(e,t){this._bareFontInfo=e,this._requests=t,this._container=null,this._testElements=null}read(){this._createDomElements(),document.body.appendChild(this._container),this._readFromDomElements(),document.body.removeChild(this._container),this._container=null,this._testElements=null}_createDomElements(){let e=document.createElement("div");e.style.position="absolute",e.style.top="-50000px",e.style.width="50000px";let t=document.createElement("div");ox(t,this._bareFontInfo),e.appendChild(t);let i=document.createElement("div");ox(i,this._bareFontInfo),i.style.fontWeight="bold",e.appendChild(i);let n=document.createElement("div");ox(n,this._bareFontInfo),n.style.fontStyle="italic",e.appendChild(n);let r=[];for(let e of this._requests){let o;0===e.type&&(o=t),2===e.type&&(o=i),1===e.type&&(o=n),o.appendChild(document.createElement("br"));let s=document.createElement("span");ok._render(s,e),o.appendChild(s),r.push(s)}this._container=e,this._testElements=r}static _render(e,t){if(" "===t.chr){let t="\xa0";for(let e=0;e<8;e++)t+=t;e.innerText=t}else{let i=t.chr;for(let e=0;e<8;e++)i+=i;e.textContent=i}}_readFromDomElements(){for(let e=0,t=this._requests.length;ethis._values[e])}}let oV=new class extends nc{constructor(){super(),this._onDidChange=this._register(new ny),this.onDidChange=this._onDidChange.event,this._cache=new oH,this._evictUntrustedReadingsTimeout=-1}dispose(){-1!==this._evictUntrustedReadingsTimeout&&(window.clearTimeout(this._evictUntrustedReadingsTimeout),this._evictUntrustedReadingsTimeout=-1),super.dispose()}clearAllFontInfos(){this._cache=new oH,this._onDidChange.fire()}_writeToCache(e,t){this._cache.put(e,t),t.isTrusted||-1!==this._evictUntrustedReadingsTimeout||(this._evictUntrustedReadingsTimeout=window.setTimeout(()=>{this._evictUntrustedReadingsTimeout=-1,this._evictUntrustedReadings()},5e3))}_evictUntrustedReadings(){let e=this._cache.getValues(),t=!1;for(let i of e)i.isTrusted||(t=!0,this._cache.remove(i));t&&this._onDidChange.fire()}readFontInfo(e){if(!this._cache.has(e)){let t=this._actualReadFontInfo(e);(t.typicalHalfwidthCharacterWidth<=2||t.typicalFullwidthCharacterWidth<=2||t.spaceWidth<=2||t.maxDigitWidth<=2)&&(t=new oU({pixelRatio:oC.value,fontFamily:t.fontFamily,fontWeight:t.fontWeight,fontSize:t.fontSize,fontFeatureSettings:t.fontFeatureSettings,fontVariationSettings:t.fontVariationSettings,lineHeight:t.lineHeight,letterSpacing:t.letterSpacing,isMonospace:t.isMonospace,typicalHalfwidthCharacterWidth:Math.max(t.typicalHalfwidthCharacterWidth,5),typicalFullwidthCharacterWidth:Math.max(t.typicalFullwidthCharacterWidth,5),canUseHalfwidthRightwardsArrow:t.canUseHalfwidthRightwardsArrow,spaceWidth:Math.max(t.spaceWidth,5),middotWidth:Math.max(t.middotWidth,5),wsmiddotWidth:Math.max(t.wsmiddotWidth,5),maxDigitWidth:Math.max(t.maxDigitWidth,5)},!1)),this._writeToCache(e,t)}return this._cache.get(e)}_createRequest(e,t,i,n){let r=new oM(e,t);return i.push(r),null==n||n.push(r),r}_actualReadFontInfo(e){let t=[],i=[],n=this._createRequest("n",0,t,i),r=this._createRequest("m",0,t,null),o=this._createRequest(" ",0,t,i),s=this._createRequest("0",0,t,i),a=this._createRequest("1",0,t,i),l=this._createRequest("2",0,t,i),h=this._createRequest("3",0,t,i),u=this._createRequest("4",0,t,i),d=this._createRequest("5",0,t,i),c=this._createRequest("6",0,t,i),f=this._createRequest("7",0,t,i),g=this._createRequest("8",0,t,i),p=this._createRequest("9",0,t,i),m=this._createRequest("→",0,t,i),_=this._createRequest("→",0,t,null),E=this._createRequest("\xb7",0,t,i),v=this._createRequest(String.fromCharCode(11825),0,t,null),b="|/-_ilm%";for(let e=0,n=b.length;e.001){S=!1;break}}let T=!0;return S&&_.width!==y&&(T=!1),_.width>m.width&&(T=!1),new oU({pixelRatio:oC.value,fontFamily:e.fontFamily,fontWeight:e.fontWeight,fontSize:e.fontSize,fontFeatureSettings:e.fontFeatureSettings,fontVariationSettings:e.fontVariationSettings,lineHeight:e.lineHeight,letterSpacing:e.letterSpacing,isMonospace:S,typicalHalfwidthCharacterWidth:n.width,typicalFullwidthCharacterWidth:r.width,canUseHalfwidthRightwardsArrow:T,spaceWidth:o.width,middotWidth:E.width,wsmiddotWidth:v.width,maxDigitWidth:C},!0)}};(ef=tY||(tY={})).serviceIds=new Map,ef.DI_TARGET="$di$target",ef.DI_DEPENDENCIES="$di$dependencies",ef.getServiceDependencies=function(e){return e[ef.DI_DEPENDENCIES]||[]};let oW=oG("instantiationService");function oG(e){if(tY.serviceIds.has(e))return tY.serviceIds.get(e);let t=function(e,i,n){if(3!=arguments.length)throw Error("@IServiceName-decorator can only be used to decorate a parameter");e[tY.DI_TARGET]===e?e[tY.DI_DEPENDENCIES].push({id:t,index:n}):(e[tY.DI_DEPENDENCIES]=[{id:t,index:n}],e[tY.DI_TARGET]=e)};return t.toString=()=>e,tY.serviceIds.set(e,t),t}let oj=oG("codeEditorService");function oz(e,t){if(!e)throw Error(t?`Assertion failed (${t})`:"Assertion Failed")}function oK(e,t="Unreachable"){throw Error(t)}function oY(e){e()||(e(),i1(new nt("Assertion Failed")))}function o$(e,t){let i=0;for(;i\-\./\\:\*\?\+\[\]\^,#@;"%\$\p{L}-]+/uy}static getLexeme(e){switch(e.type){case 0:return"(";case 1:return")";case 2:return"!";case 3:return e.isTripleEq?"===":"==";case 4:return e.isTripleEq?"!==":"!=";case 5:return"<";case 6:return"<=";case 7:case 8:return">=";case 9:return"=~";case 10:case 17:case 18:case 19:return e.lexeme;case 11:return"true";case 12:return"false";case 13:return"in";case 14:return"not";case 15:return"&&";case 16:return"||";case 20:return"EOF";default:throw i8(`unhandled token type: ${JSON.stringify(e)}; have you forgotten to add a case?`)}}reset(e){return this._input=e,this._start=0,this._current=0,this._tokens=[],this._errors=[],this}scan(){for(;!this._isAtEnd();){this._start=this._current;let e=this._advance();switch(e){case 40:this._addToken(0);break;case 41:this._addToken(1);break;case 33:if(this._match(61)){let e=this._match(61);this._tokens.push({type:4,offset:this._start,isTripleEq:e})}else this._addToken(2);break;case 39:this._quotedString();break;case 47:this._regex();break;case 61:if(this._match(61)){let e=this._match(61);this._tokens.push({type:3,offset:this._start,isTripleEq:e})}else this._match(126)?this._addToken(9):this._error(o0("==","=~"));break;case 60:this._addToken(this._match(61)?6:5);break;case 62:this._addToken(this._match(61)?8:7);break;case 38:this._match(38)?this._addToken(15):this._error(o0("&&"));break;case 124:this._match(124)?this._addToken(16):this._error(o0("||"));break;case 32:case 13:case 9:case 10:case 160:break;default:this._string()}}return this._start=this._current,this._addToken(20),Array.from(this._tokens)}_match(e){return!this._isAtEnd()&&this._input.charCodeAt(this._current)===e&&(this._current++,!0)}_advance(){return this._input.charCodeAt(this._current++)}_peek(){return this._isAtEnd()?0:this._input.charCodeAt(this._current)}_addToken(e){this._tokens.push({type:e,offset:this._start})}_error(e){let t=this._start,i=this._input.substring(this._start,this._current),n={type:19,offset:this._start,lexeme:i};this._errors.push({offset:t,lexeme:i,additionalInfo:e}),this._tokens.push(n)}_string(){this.stringRe.lastIndex=this._start;let e=this.stringRe.exec(this._input);if(e){this._current=this._start+e[0].length;let t=this._input.substring(this._start,this._current),i=o5._keywords.get(t);i?this._addToken(i):this._tokens.push({type:17,lexeme:t,offset:this._start})}}_quotedString(){for(;39!==this._peek()&&!this._isAtEnd();)this._advance();if(this._isAtEnd()){this._error(o1);return}this._advance(),this._tokens.push({type:18,lexeme:this._input.substring(this._start+1,this._current-1),offset:this._start+1})}_regex(){let e=this._current,t=!1,i=!1;for(;;){if(e>=this._input.length){this._current=e,this._error(o2);return}let n=this._input.charCodeAt(e);if(t)t=!1;else if(47!==n||i)91===n?i=!0:92===n?t=!0:93===n&&(i=!1);else{e++;break}e++}for(;e=this._input.length}}o5._regexFlags=new Set(["i","g","s","m","y","u"].map(e=>e.charCodeAt(0))),o5._keywords=new Map([["not",14],["in",13],["false",12],["true",11]]);let o4=new Map;o4.set("false",!1),o4.set("true",!0),o4.set("isMac",nz.dz),o4.set("isLinux",nz.IJ),o4.set("isWindows",nz.ED),o4.set("isWeb",nz.$L),o4.set("isMacNative",nz.dz&&!nz.$L),o4.set("isEdge",nz.un),o4.set("isFirefox",nz.vU),o4.set("isChrome",nz.i7),o4.set("isSafari",nz.G6);let o3=Object.prototype.hasOwnProperty,o6={regexParsingWithErrorRecovery:!0},o9=(0,rN.NC)("contextkey.parser.error.emptyString","Empty context key expression"),o8=(0,rN.NC)("contextkey.parser.error.emptyString.hint","Did you forget to write an expression? You can also put 'false' or 'true' to always evaluate to false or true, respectively."),o7=(0,rN.NC)("contextkey.parser.error.noInAfterNot","'in' after 'not'."),se=(0,rN.NC)("contextkey.parser.error.closingParenthesis","closing parenthesis ')'"),st=(0,rN.NC)("contextkey.parser.error.unexpectedToken","Unexpected token"),si=(0,rN.NC)("contextkey.parser.error.unexpectedToken.hint","Did you forget to put && or || before the token?"),sn=(0,rN.NC)("contextkey.parser.error.unexpectedEOF","Unexpected end of expression"),sr=(0,rN.NC)("contextkey.parser.error.unexpectedEOF.hint","Did you forget to put a context key?");class so{constructor(e=o6){this._config=e,this._scanner=new o5,this._tokens=[],this._current=0,this._parsingErrors=[],this._flagsGYRe=/g|y/g}parse(e){if(""===e){this._parsingErrors.push({message:o9,offset:0,lexeme:"",additionalInfo:o8});return}this._tokens=this._scanner.reset(e).scan(),this._current=0,this._parsingErrors=[];try{let e=this._expr();if(!this._isAtEnd()){let e=this._peek(),t=17===e.type?si:void 0;throw this._parsingErrors.push({message:st,offset:e.offset,lexeme:o5.getLexeme(e),additionalInfo:t}),so._parseError}return e}catch(e){if(e!==so._parseError)throw e;return}}_expr(){return this._or()}_or(){let e=[this._and()];for(;this._matchOne(16);){let t=this._and();e.push(t)}return 1===e.length?e[0]:ss.or(...e)}_and(){let e=[this._term()];for(;this._matchOne(15);){let t=this._term();e.push(t)}return 1===e.length?e[0]:ss.and(...e)}_term(){if(this._matchOne(2)){let e=this._peek();switch(e.type){case 11:return this._advance(),sl.INSTANCE;case 12:return this._advance(),sh.INSTANCE;case 0:{this._advance();let e=this._expr();return this._consume(1,se),null==e?void 0:e.negate()}case 17:return this._advance(),sp.create(e.lexeme);default:throw this._errExpectedButGot("KEY | true | false | '(' expression ')'",e)}}return this._primary()}_primary(){let e=this._peek();switch(e.type){case 11:return this._advance(),ss.true();case 12:return this._advance(),ss.false();case 0:{this._advance();let e=this._expr();return this._consume(1,se),e}case 17:{let t=e.lexeme;if(this._advance(),this._matchOne(9)){let e=this._peek();if(!this._config.regexParsingWithErrorRecovery){let i;if(this._advance(),10!==e.type)throw this._errExpectedButGot("REGEX",e);let n=e.lexeme,r=n.lastIndexOf("/"),o=r===n.length-1?void 0:this._removeFlagsGY(n.substring(r+1));try{i=new RegExp(n.substring(1,r),o)}catch(t){throw this._errExpectedButGot("REGEX",e)}return sC.create(t,i)}switch(e.type){case 10:case 19:{let i;let n=[e.lexeme];this._advance();let r=this._peek(),o=0;for(let t=0;t=0){let o=i.slice(t+1,r),s="i"===i[r+1]?"i":"";try{n=new RegExp(o,s)}catch(t){throw this._errExpectedButGot("REGEX",e)}}}if(null===n)throw this._errExpectedButGot("REGEX",e);return sC.create(t,n)}default:throw this._errExpectedButGot("REGEX",this._peek())}}if(this._matchOne(14)){this._consume(13,o7);let e=this._value();return ss.notIn(t,e)}let i=this._peek().type;switch(i){case 3:{this._advance();let e=this._value();if(18===this._previous().type)return ss.equals(t,e);switch(e){case"true":return ss.has(t);case"false":return ss.not(t);default:return ss.equals(t,e)}}case 4:{this._advance();let e=this._value();if(18===this._previous().type)return ss.notEquals(t,e);switch(e){case"true":return ss.not(t);case"false":return ss.has(t);default:return ss.notEquals(t,e)}}case 5:return this._advance(),sv.create(t,this._value());case 6:return this._advance(),sb.create(t,this._value());case 7:return this._advance(),s_.create(t,this._value());case 8:return this._advance(),sE.create(t,this._value());case 13:return this._advance(),ss.in(t,this._value());default:return ss.has(t)}}case 20:throw this._parsingErrors.push({message:sn,offset:e.offset,lexeme:"",additionalInfo:sr}),so._parseError;default:throw this._errExpectedButGot(`true | false | KEY +(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[739],{96991:function(e,t,i){"use strict";i.d(t,{Z:function(){return a}});var n=i(87462),r=i(67294),o={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M864 144H560c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V160c0-8.8-7.2-16-16-16zm0 400H560c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V560c0-8.8-7.2-16-16-16zM464 144H160c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V160c0-8.8-7.2-16-16-16zm0 400H160c-8.8 0-16 7.2-16 16v304c0 8.8 7.2 16 16 16h304c8.8 0 16-7.2 16-16V560c0-8.8-7.2-16-16-16z"}}]},name:"appstore",theme:"filled"},s=i(84089),a=r.forwardRef(function(e,t){return r.createElement(s.Z,(0,n.Z)({},e,{ref:t,icon:o}))})},29158:function(e,t,i){"use strict";i.d(t,{Z:function(){return a}});var n=i(87462),r=i(67294),o={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M574 665.4a8.03 8.03 0 00-11.3 0L446.5 781.6c-53.8 53.8-144.6 59.5-204 0-59.5-59.5-53.8-150.2 0-204l116.2-116.2c3.1-3.1 3.1-8.2 0-11.3l-39.8-39.8a8.03 8.03 0 00-11.3 0L191.4 526.5c-84.6 84.6-84.6 221.5 0 306s221.5 84.6 306 0l116.2-116.2c3.1-3.1 3.1-8.2 0-11.3L574 665.4zm258.6-474c-84.6-84.6-221.5-84.6-306 0L410.3 307.6a8.03 8.03 0 000 11.3l39.7 39.7c3.1 3.1 8.2 3.1 11.3 0l116.2-116.2c53.8-53.8 144.6-59.5 204 0 59.5 59.5 53.8 150.2 0 204L665.3 562.6a8.03 8.03 0 000 11.3l39.8 39.8c3.1 3.1 8.2 3.1 11.3 0l116.2-116.2c84.5-84.6 84.5-221.5 0-306.1zM610.1 372.3a8.03 8.03 0 00-11.3 0L372.3 598.7a8.03 8.03 0 000 11.3l39.6 39.6c3.1 3.1 8.2 3.1 11.3 0l226.4-226.4c3.1-3.1 3.1-8.2 0-11.3l-39.5-39.6z"}}]},name:"link",theme:"outlined"},s=i(84089),a=r.forwardRef(function(e,t){return r.createElement(s.Z,(0,n.Z)({},e,{ref:t,icon:o}))})},49591:function(e,t,i){"use strict";i.d(t,{Z:function(){return a}});var n=i(87462),r=i(67294),o={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M880 112H144c-17.7 0-32 14.3-32 32v736c0 17.7 14.3 32 32 32h360c4.4 0 8-3.6 8-8v-56c0-4.4-3.6-8-8-8H184V184h656v320c0 4.4 3.6 8 8 8h56c4.4 0 8-3.6 8-8V144c0-17.7-14.3-32-32-32zM653.3 599.4l52.2-52.2a8.01 8.01 0 00-4.7-13.6l-179.4-21c-5.1-.6-9.5 3.7-8.9 8.9l21 179.4c.8 6.6 8.9 9.4 13.6 4.7l52.4-52.4 256.2 256.2c3.1 3.1 8.2 3.1 11.3 0l42.4-42.4c3.1-3.1 3.1-8.2 0-11.3L653.3 599.4z"}}]},name:"select",theme:"outlined"},s=i(84089),a=r.forwardRef(function(e,t){return r.createElement(s.Z,(0,n.Z)({},e,{ref:t,icon:o}))})},88484:function(e,t,i){"use strict";i.d(t,{Z:function(){return a}});var n=i(87462),r=i(67294),o={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M400 317.7h73.9V656c0 4.4 3.6 8 8 8h60c4.4 0 8-3.6 8-8V317.7H624c6.7 0 10.4-7.7 6.3-12.9L518.3 163a8 8 0 00-12.6 0l-112 141.7c-4.1 5.3-.4 13 6.3 13zM878 626h-60c-4.4 0-8 3.6-8 8v154H214V634c0-4.4-3.6-8-8-8h-60c-4.4 0-8 3.6-8 8v198c0 17.7 14.3 32 32 32h684c17.7 0 32-14.3 32-32V634c0-4.4-3.6-8-8-8z"}}]},name:"upload",theme:"outlined"},s=i(84089),a=r.forwardRef(function(e,t){return r.createElement(s.Z,(0,n.Z)({},e,{ref:t,icon:o}))})},5165:function(e,t,i){"use strict";i.d(t,{w:function(){return tK}});var n=i(97582),r={line_chart:{id:"line_chart",name:"Line Chart",alias:["Lines"],family:["LineCharts"],def:"A line chart uses lines with segments to show changes in data in a ordinal dimension.",purpose:["Comparison","Trend","Anomaly"],coord:["Cartesian2D"],category:["Statistic"],shape:["Lines"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Time","Ordinal"]},{minQty:0,maxQty:1,fieldConditions:["Nominal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position","Direction"],recRate:"Recommended"},step_line_chart:{id:"step_line_chart",name:"Step Line Chart",alias:["Step Lines"],family:["LineCharts"],def:"A step line chart is a line chart in which points of each line are connected by horizontal and vertical line segments, looking like steps of a staircase.",purpose:["Comparison","Trend"],coord:["Cartesian2D"],category:["Statistic"],shape:["Lines"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Time","Ordinal"]},{minQty:0,maxQty:1,fieldConditions:["Nominal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position","Direction"],recRate:"Recommended"},area_chart:{id:"area_chart",name:"Area Chart",alias:[],family:["AreaCharts"],def:"An area chart uses series of line segments with overlapped areas to show the change in data in a ordinal dimension.",purpose:["Comparison","Trend","Anomaly"],coord:["Cartesian2D"],category:["Statistic"],shape:["Area"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Time","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]},{minQty:0,maxQty:1,fieldConditions:["Nominal"]}],channel:["Color","Position"],recRate:"Recommended"},stacked_area_chart:{id:"stacked_area_chart",name:"Stacked Area Chart",alias:[],family:["AreaCharts"],def:"A stacked area chart uses layered line segments with different styles of padding regions to display how multiple sets of data change in the same ordinal dimension, and the endpoint heights of the segments on the same dimension tick are accumulated by value.",purpose:["Composition","Trend"],coord:["Cartesian2D"],category:["Statistic"],shape:["Area"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Time","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]},{minQty:1,maxQty:1,fieldConditions:["Nominal"]}],channel:["Color","Length"],recRate:"Recommended"},percent_stacked_area_chart:{id:"percent_stacked_area_chart",name:"Percent Stacked Area Chart",alias:["Percent Stacked Area","% Stacked Area","100% Stacked Area"],family:["AreaCharts"],def:"A percent stacked area chart is an extented stacked area chart in which the height of the endpoints of the line segment on the same dimension tick is the accumulated proportion of the ratio, which is 100% of the total.",purpose:["Comparison","Composition","Proportion","Trend"],coord:["Cartesian2D"],category:["Statistic"],shape:["Area"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Time","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]},{minQty:1,maxQty:1,fieldConditions:["Nominal"]}],channel:["Color","Length"],recRate:"Recommended"},column_chart:{id:"column_chart",name:"Column Chart",alias:["Columns"],family:["ColumnCharts"],def:"A column chart uses series of columns to display the value of the dimension. The horizontal axis shows the classification dimension and the vertical axis shows the corresponding value.",purpose:["Comparison","Distribution","Rank"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:1,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position","Color"],recRate:"Recommended"},grouped_column_chart:{id:"grouped_column_chart",name:"Grouped Column Chart",alias:["Grouped Column"],family:["ColumnCharts"],def:"A grouped column chart uses columns of different colors to form a group to display the values of dimensions. The horizontal axis indicates the grouping of categories, the color indicates the categories, and the vertical axis shows the corresponding value.",purpose:["Comparison","Distribution","Rank"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Position"],recRate:"Recommended"},stacked_column_chart:{id:"stacked_column_chart",name:"Stacked Column Chart",alias:["Stacked Column"],family:["ColumnCharts"],def:"A stacked column chart uses stacked bars of different colors to display the values for each dimension. The horizontal axis indicates the first classification dimension, the color indicates the second classification dimension, and the vertical axis shows the corresponding value.",purpose:["Comparison","Composition","Distribution","Rank"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Length","Position"],recRate:"Recommended"},percent_stacked_column_chart:{id:"percent_stacked_column_chart",name:"Percent Stacked Column Chart",alias:["Percent Stacked Column","% Stacked Column","100% Stacked Column"],family:["ColumnCharts"],def:"A percent stacked column chart uses stacked bars of different colors to display the values for each dimension. The horizontal axis indicates the first classification dimension, the color indicates the second classification dimension, and the vertical axis shows the percentage of the corresponding classification.",purpose:["Comparison","Composition","Distribution","Proportion"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Length"],recRate:"Recommended"},range_column_chart:{id:"range_column_chart",name:"Range Column Chart",alias:[],family:["ColumnCharts"],def:"A column chart that does not have to start from zero axis.",purpose:["Comparison"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Interval","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Nominal"]}],channel:["Length"],recRate:"Recommended"},waterfall_chart:{id:"waterfall_chart",name:"Waterfall Chart",alias:["Flying Bricks Chart","Mario Chart","Bridge Chart","Cascade Chart"],family:["ColumnCharts"],def:"A waterfall chart is used to portray how an initial value is affected by a series of intermediate positive or negative values",purpose:["Comparison","Trend"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Ordinal","Time","Nominal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Length","Position"],recRate:"Recommended"},histogram:{id:"histogram",name:"Histogram",alias:[],family:["ColumnCharts"],def:"A histogram is an accurate representation of the distribution of numerical data.",purpose:["Distribution"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position"],recRate:"Recommended"},bar_chart:{id:"bar_chart",name:"Bar Chart",alias:["Bars"],family:["BarCharts"],def:"A bar chart uses series of bars to display the value of the dimension. The vertical axis shows the classification dimension and the horizontal axis shows the corresponding value.",purpose:["Comparison","Distribution","Rank"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:1,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position","Color"],recRate:"Recommended"},stacked_bar_chart:{id:"stacked_bar_chart",name:"Stacked Bar Chart",alias:["Stacked Bar"],family:["BarCharts"],def:"A stacked bar chart uses stacked bars of different colors to display the values for each dimension. The vertical axis indicates the first classification dimension, the color indicates the second classification dimension, and the horizontal axis shows the corresponding value.",purpose:["Comparison","Composition","Distribution","Rank"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Length","Position"],recRate:"Recommended"},percent_stacked_bar_chart:{id:"percent_stacked_bar_chart",name:"Percent Stacked Bar Chart",alias:["Percent Stacked Bar","% Stacked Bar","100% Stacked Bar"],family:["BarCharts"],def:"A percent stacked column chart uses stacked bars of different colors to display the values for each dimension. The vertical axis indicates the first classification dimension, the color indicates the second classification dimension, and the horizontal axis shows the percentage of the corresponding classification.",purpose:["Comparison","Composition","Distribution","Proportion"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Length"],recRate:"Recommended"},grouped_bar_chart:{id:"grouped_bar_chart",name:"Grouped Bar Chart",alias:["Grouped Bar"],family:["BarCharts"],def:"A grouped bar chart uses bars of different colors to form a group to display the values of the dimensions. The vertical axis indicates the grouping of categories, the color indicates the categories, and the horizontal axis shows the corresponding value.",purpose:["Comparison","Distribution","Rank"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Position"],recRate:"Recommended"},range_bar_chart:{id:"range_bar_chart",name:"Range Bar Chart",alias:[],family:["BarCharts"],def:"A bar chart that does not have to start from zero axis.",purpose:["Comparison"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Interval"]},{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]}],channel:["Length"],recRate:"Recommended"},radial_bar_chart:{id:"radial_bar_chart",name:"Radial Bar Chart",alias:["Radial Column Chart"],family:["BarCharts"],def:"A bar chart that is plotted in the polar coordinate system. The axis along radius shows the classification dimension and the angle shows the corresponding value.",purpose:["Comparison","Distribution","Rank"],coord:["Polar"],category:["Statistic"],shape:["Round"],dataPres:[{minQty:1,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Angle","Color"],recRate:"Recommended"},bullet_chart:{id:"bullet_chart",name:"Bullet Chart",alias:[],family:["BarCharts"],def:"A bullet graph is a variation of a bar graph developed by Stephen Few. Seemingly inspired by the traditional thermometer charts and progress bars found in many dashboards, the bullet graph serves as a replacement for dashboard gauges and meters.",purpose:["Proportion"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:3,maxQty:3,fieldConditions:["Interval"]},{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]}],channel:["Position","Color"],recRate:"Recommended"},pie_chart:{id:"pie_chart",name:"Pie Chart",alias:["Circle Chart","Pie"],family:["PieCharts"],def:"A pie chart is a chart that the classification and proportion of data are represented by the color and arc length (angle, area) of the sector.",purpose:["Comparison","Composition","Proportion"],coord:["Polar"],category:["Statistic"],shape:["Round"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Angle","Area","Color"],recRate:"Use with Caution"},donut_chart:{id:"donut_chart",name:"Donut Chart",alias:["Donut","Doughnut","Doughnut Chart","Ring Chart"],family:["PieCharts"],def:"A donut chart is a variation on a Pie chart except it has a round hole in the center which makes it look like a donut.",purpose:["Comparison","Composition","Proportion"],coord:["Polar"],category:["Statistic"],shape:["Round"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["ArcLength"],recRate:"Recommended"},nested_pie_chart:{id:"nested_pie_chart",name:"Nested Pie Chart",alias:["Nested Circle Chart","Nested Pie","Nested Donut Chart"],family:["PieCharts"],def:"A nested pie chart is a chart that contains several donut charts, where all the donut charts share the same center in position.",purpose:["Comparison","Composition","Proportion"],coord:["Polar"],category:["Statistic"],shape:["Round"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:"*",fieldConditions:["Interval"]}],channel:["Angle","Area","Color","Position"],recRate:"Use with Caution"},rose_chart:{id:"rose_chart",name:"Rose Chart",alias:["Nightingale Chart","Polar Area Chart","Coxcomb Chart"],family:["PieCharts"],def:"Nightingale Rose Chart is a peculiar combination of the Radar Chart and Stacked Column Chart types of data visualization.",purpose:["Comparison","Composition","Proportion"],coord:["Polar"],category:["Statistic"],shape:["Round"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Angle","Color","Length"],recRate:"Use with Caution"},scatter_plot:{id:"scatter_plot",name:"Scatter Plot",alias:["Scatter Chart","Scatterplot"],family:["ScatterCharts"],def:"A scatter plot is a type of plot or mathematical diagram using Cartesian coordinates to display values for typically two variables for series of data.",purpose:["Comparison","Distribution","Anomaly"],coord:["Cartesian2D"],category:["Statistic"],shape:["Scatter"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Interval"]},{minQty:0,maxQty:1,fieldConditions:["Nominal"]}],channel:["Color","Position"],recRate:"Recommended"},bubble_chart:{id:"bubble_chart",name:"Bubble Chart",alias:["Bubble Chart"],family:["ScatterCharts"],def:"A bubble chart is a type of chart that displays four dimensions of data with x, y positions, circle size and circle color.",purpose:["Comparison","Distribution"],coord:["Cartesian2D"],category:["Statistic"],shape:["Scatter"],dataPres:[{minQty:3,maxQty:3,fieldConditions:["Interval"]},{minQty:0,maxQty:1,fieldConditions:["Nominal"]}],channel:["Color","Position","Size"],recRate:"Recommended"},non_ribbon_chord_diagram:{id:"non_ribbon_chord_diagram",name:"Non-Ribbon Chord Diagram",alias:[],family:["GeneralGraph"],def:"A stripped-down version of a Chord Diagram, with only the connection lines showing. This provides more emphasis on the connections within the data.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},arc_diagram:{id:"arc_diagram",name:"Arc Diagram",alias:[],family:["GeneralGraph"],def:"A graph where the edges are represented as arcs.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},chord_diagram:{id:"chord_diagram",name:"Chord Diagram",alias:[],family:["GeneralGraph"],def:"A graphical method of displaying the inter-relationships between data in a matrix. The data are arranged radially around a circle with the relationships between the data points typically drawn as arcs connecting the data.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},treemap:{id:"treemap",name:"Treemap",alias:[],family:["TreeGraph"],def:"A visual representation of a data tree with nodes. Each node is displayed as a rectangle, sized and colored according to values that you assign.",purpose:["Composition","Comparison","Hierarchy"],coord:["Cartesian2D"],category:["Statistic"],shape:["Square"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Area"],recRate:"Recommended"},sankey_diagram:{id:"sankey_diagram",name:"Sankey Diagram",alias:[],family:["GeneralGraph"],def:"A graph shows the flows with weights between objects.",purpose:["Flow","Trend","Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},funnel_chart:{id:"funnel_chart",name:"Funnel Chart",alias:[],family:["FunnelCharts"],def:"A funnel chart is often used to represent stages in a sales process and show the amount of potential revenue for each stage.",purpose:["Trend"],coord:["SymmetricCartesian"],category:["Statistic"],shape:["Symmetric"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Length"],recRate:"Recommended"},mirror_funnel_chart:{id:"mirror_funnel_chart",name:"Mirror Funnel Chart",alias:["Contrast Funnel Chart"],family:["FunnelCharts"],def:"A mirror funnel chart is a funnel chart divided into two series by a central axis.",purpose:["Comparison","Trend"],coord:["SymmetricCartesian"],category:["Statistic"],shape:["Symmetric"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]},{minQty:1,maxQty:1,fieldConditions:["Nominal"]}],channel:["Color","Length","Direction"],recRate:"Recommended"},box_plot:{id:"box_plot",name:"Box Plot",alias:["Box and Whisker Plot","boxplot"],family:["BarCharts"],def:"A box plot is often used to graphically depict groups of numerical data through their quartiles. Box plots may also have lines extending from the boxes indicating variability outside the upper and lower quartiles. Outliers may be plotted as individual points.",purpose:["Distribution","Anomaly"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position"],recRate:"Recommended"},heatmap:{id:"heatmap",name:"Heatmap",alias:[],family:["HeatmapCharts"],def:"A heatmap is a graphical representation of data where the individual values contained in a matrix are represented as colors.",purpose:["Distribution"],coord:["Cartesian2D"],category:["Statistic"],shape:["Square"],dataPres:[{minQty:2,maxQty:2,fieldConditions:["Nominal","Ordinal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Position"],recRate:"Recommended"},density_heatmap:{id:"density_heatmap",name:"Density Heatmap",alias:["Heatmap"],family:["HeatmapCharts"],def:"A density heatmap is a heatmap for representing the density of dots.",purpose:["Distribution"],coord:["Cartesian2D"],category:["Statistic"],shape:["Area"],dataPres:[{minQty:3,maxQty:3,fieldConditions:["Interval"]}],channel:["Color","Position","Area"],recRate:"Recommended"},radar_chart:{id:"radar_chart",name:"Radar Chart",alias:["Web Chart","Spider Chart","Star Chart","Cobweb Chart","Irregular Polygon","Kiviat diagram"],family:["RadarCharts"],def:"A radar chart maps series of data volume of multiple dimensions onto the axes. Starting at the same center point, usually ending at the edge of the circle, connecting the same set of points using lines.",purpose:["Comparison"],coord:["Radar"],category:["Statistic"],shape:["Round"],dataPres:[{minQty:1,maxQty:2,fieldConditions:["Nominal"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Color","Position"],recRate:"Recommended"},wordcloud:{id:"wordcloud",name:"Word Cloud",alias:["Wordle","Tag Cloud","Text Cloud"],family:["Others"],def:"A word cloud is a collection, or cluster, of words depicted in different sizes, colors, and shapes, which takes a piece of text as input. Typically, the font size in the word cloud is encoded as the word frequency in the input text.",purpose:["Proportion"],coord:["Cartesian2D"],category:["Diagram"],shape:["Scatter"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Nominal"]},{minQty:0,maxQty:1,fieldConditions:["Interval"]}],channel:["Size","Position","Color"],recRate:"Recommended"},candlestick_chart:{id:"candlestick_chart",name:"Candlestick Chart",alias:["Japanese Candlestick Chart)"],family:["BarCharts"],def:"A candlestick chart is a specific version of box plot, which is a style of financial chart used to describe price movements of a security, derivative, or currency.",purpose:["Trend","Distribution"],coord:["Cartesian2D"],category:["Statistic"],shape:["Bars"],dataPres:[{minQty:1,maxQty:1,fieldConditions:["Time"]},{minQty:1,maxQty:1,fieldConditions:["Interval"]}],channel:["Position"],recRate:"Recommended"},compact_box_tree:{id:"compact_box_tree",name:"CompactBox Tree",alias:[],family:["TreeGraph"],def:"A type of tree graph layout which arranges the nodes with same depth on the same level.",purpose:["Relation","Hierarchy"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},dendrogram:{id:"dendrogram",name:"Dendrogram",alias:[],family:["TreeGraph"],def:"A type of tree graph layout which arranges the leaves on the same level.",purpose:["Relation","Hierarchy"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},indented_tree:{id:"indented_tree",name:"Indented Tree Layout",alias:[],family:["TreeGraph"],def:"A type of tree graph layout where the hierarchy of tree is represented by the horizontal indentation, and each element will occupy one row/column. It is commonly used to represent the file directory structure.",purpose:["Relation","Hierarchy"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},radial_tree:{id:"radial_tree",name:"Radial Tree Layout",alias:[],family:["TreeGraph"],def:"A type of tree graph layout which places the root at the center, and the branches around the root radially.",purpose:["Relation","Hierarchy"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},flow_diagram:{id:"flow_diagram",name:"Flow Diagram",alias:["Dagre Graph Layout","Dagre","Flow Chart"],family:["GeneralGraph"],def:"Directed flow graph.",purpose:["Relation","Flow"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},fruchterman_layout_graph:{id:"fruchterman_layout_graph",name:"Fruchterman Graph Layout",alias:[],family:["GeneralGraph"],def:"A type of force directed graph layout.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},force_directed_layout_graph:{id:"force_directed_layout_graph",name:"Force Directed Graph Layout",alias:[],family:["GeneralGraph"],def:"The classical force directed graph layout.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},fa2_layout_graph:{id:"fa2_layout_graph",name:"Force Atlas 2 Graph Layout",alias:["FA2 Layout"],family:["GeneralGraph"],def:"A type of force directed graph layout algorithm. It focuses more on the degree of the node when calculating the force than the classical force-directed algorithm .",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},mds_layout_graph:{id:"mds_layout_graph",name:"Multi-Dimensional Scaling Layout",alias:["MDS Layout"],family:["GeneralGraph"],def:"A type of dimension reduction algorithm that could be used for calculating graph layout. MDS (Multidimensional scaling) is used for project high dimensional data onto low dimensional space.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},circular_layout_graph:{id:"circular_layout_graph",name:"Circular Graph Layout",alias:[],family:["GeneralGraph"],def:"A type of graph layout which arranges all the nodes on a circle.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},spiral_layout_graph:{id:"spiral_layout_graph",name:"Spiral Graph Layout",alias:[],family:["GeneralGraph"],def:"A type of graph layout which arranges all the nodes along a spiral line.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},radial_layout_graph:{id:"radial_layout_graph",name:"Radial Graph Layout",alias:[],family:["GeneralGraph"],def:"A type of graph layout which places a focus node on the center and the others on the concentrics centered at the focus node according to the shortest path length to the it.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},concentric_layout_graph:{id:"concentric_layout_graph",name:"Concentric Graph Layout",alias:[],family:["GeneralGraph"],def:"A type of graph layout which arranges the nodes on concentrics.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"},grid_layout_graph:{id:"grid_layout_graph",name:"Grid Graph Layout",alias:[],family:["GeneralGraph"],def:"A type of graph layout arranges the nodes on grids.",purpose:["Relation"],coord:["Cartesian2D"],category:["Graph"],shape:["Network"],dataPres:[{minQty:1,maxQty:"*",fieldConditions:["Nominal"]}],channel:["Color","Size","Opacity","Stroke","LineWidth"],recRate:"Recommended"}};function o(e,t){return t.every(function(t){return e.includes(t)})}var s=["bar_chart","grouped_bar_chart","stacked_bar_chart","percent_stacked_bar_chart","column_chart","grouped_column_chart","stacked_column_chart","percent_stacked_column_chart"],a=["bar_chart","grouped_bar_chart","stacked_bar_chart","percent_stacked_bar_chart","column_chart","grouped_column_chart","stacked_column_chart","percent_stacked_column_chart"];function l(e,t){return t.some(function(t){return e.includes(t)})}function h(e,t){return e.distinctt.distinct?-1:0}var u={"bar-series-qty":.5,"data-check":1,"data-field-qty":1,"diff-pie-sector":.5,"landscape-or-portrait":.3,"limit-series":1,"line-field-time-ordinal":1,"no-redundant-field":1,"nominal-enum-combinatorial":1,"purpose-check":1,"series-qty-limit":.8},d=function(e,t,i,r,o,s){var a=1;return Object.values(i).filter(function(i){var s,a,l,h=(null===(s=i.option)||void 0===s?void 0:s.weight)||u[i.id]||1,d=null===(a=i.option)||void 0===a?void 0:a.extra;return i.type===r&&i.trigger((0,n.pi)((0,n.pi)((0,n.pi)((0,n.pi)({},o),{weight:h}),d),{chartType:e,chartWIKI:t}))&&!(null===(l=i.option)||void 0===l?void 0:l.off)}).forEach(function(i){var l,h,d=(null===(l=i.option)||void 0===l?void 0:l.weight)||u[i.id]||1,c=null===(h=i.option)||void 0===h?void 0:h.extra,f=i.validator((0,n.pi)((0,n.pi)((0,n.pi)((0,n.pi)({},o),{weight:d}),c),{chartType:e,chartWIKI:t})),g=d*f;a*=g,s.push({phase:"ADVISE",ruleId:i.id,score:g,base:f,weight:d,ruleType:r})}),a},c=["pie_chart","donut_chart"],f=["bar_chart","grouped_bar_chart","stacked_bar_chart","percent_stacked_bar_chart","column_chart","grouped_column_chart","stacked_column_chart","percent_stacked_column_chart"];function g(e){var t=e.chartType,i=e.dataProps,n=e.preferences;return!!(i&&t&&n&&n.canvasLayout)}var p=["line_chart","area_chart","stacked_area_chart","percent_stacked_area_chart"],m=["bar_chart","column_chart","grouped_bar_chart","grouped_column_chart","stacked_bar_chart","stacked_column_chart"];function _(e){return e.filter(function(e){return o(e.levelOfMeasurements,["Nominal"])})}var E=["pie_chart","donut_chart","radar_chart","rose_chart"],v=i(96486);function b(e){return"number"==typeof e}function C(e){return"string"==typeof e||"boolean"==typeof e}function S(e){return e instanceof Date}function y(e){var t=e.encode,i=e.data,r=e.scale,o=(0,v.mapValues)(t,function(e,t){var n,o,s;return{field:e,type:void 0!==(n=null==r?void 0:r[t].type)?function(e){switch(e){case"linear":case"log":case"pow":case"sqrt":case"qunatile":case"threshold":case"quantize":case"sequential":return"quantitative";case"time":return"temporal";case"ordinal":case"point":case"band":return"categorical";default:throw Error("Unkonwn scale type: ".concat(e,"."))}}(n):function(e){if(e.some(b))return"quantitative";if(e.some(C))return"categorical";if(e.some(S))return"temporal";throw Error("Unknown type: ".concat(typeof e[0]))}((o=i,"function"==typeof(s=e)?o.map(s):"string"==typeof s&&o.some(function(e){return void 0!==e[s]})?o.map(function(e){return e[s]}):o.map(function(){return s})))}});return(0,n.pi)((0,n.pi)({},e),{encode:o})}var T=["line_chart"],R={"bar-series-qty":{id:"bar-series-qty",type:"SOFT",docs:{lintText:"Bar chart should has proper number of bars or bar groups."},trigger:function(e){var t=e.chartType;return s.includes(t)},validator:function(e){var t=1,i=e.dataProps,n=e.chartType;if(i&&n){var r=i.find(function(e){return o(e.levelOfMeasurements,["Nominal"])}),s=r&&r.count?r.count:0;s>20&&(t=20/s)}return t<.1?.1:t}},"bar-without-axis-min":{id:"bar-without-axis-min",type:"DESIGN",docs:{lintText:"It is not recommended to set the minimum value of axis for the bar or column chart.",fixText:"Remove the minimum value config of axis."},trigger:function(e){var t=e.chartType;return a.includes(t)},optimizer:function(e,t){var i,n,r=t.scale;if(!r)return{};var o=null===(i=r.x)||void 0===i?void 0:i.domainMin,s=null===(n=r.y)||void 0===n?void 0:n.domainMin;if(o||s){var a=JSON.parse(JSON.stringify(r));return o&&(a.x.domainMin=0),s&&(a.y.domainMin=0),{scale:a}}return{}}},"data-check":{id:"data-check",type:"HARD",docs:{lintText:"Data must satisfy the data prerequisites."},trigger:function(){return!0},validator:function(e){var t=0,i=e.dataProps,n=e.chartType,r=e.chartWIKI;if(i&&n&&r[n]){t=1;var o=r[n].dataPres||[];o.forEach(function(e){!function(e,t){var i=t.map(function(e){return e.levelOfMeasurements});if(i){var n=0;if(i.forEach(function(t){t&&l(t,e.fieldConditions)&&(n+=1)}),n>=e.minQty&&(n<=e.maxQty||"*"===e.maxQty))return!0}return!1}(e,i)&&(t=0)}),i.map(function(e){return e.levelOfMeasurements}).forEach(function(e){var i=!1;o.forEach(function(t){e&&l(e,t.fieldConditions)&&(i=!0)}),i||(t=0)})}return t}},"data-field-qty":{id:"data-field-qty",type:"HARD",docs:{lintText:"Data must have at least the min qty of the prerequisite."},trigger:function(){return!0},validator:function(e){var t=0,i=e.dataProps,n=e.chartType,r=e.chartWIKI;if(i&&n&&r[n]){t=1;var o=(r[n].dataPres||[]).map(function(e){return e.minQty}).reduce(function(e,t){return e+t});i.length&&i.length>=o&&(t=1)}return t}},"diff-pie-sector":{id:"diff-pie-sector",type:"SOFT",docs:{lintText:"The difference between sectors of a pie chart should be large enough."},trigger:function(e){var t=e.chartType;return c.includes(t)},validator:function(e){var t=1,i=e.dataProps;if(i){var n=i.find(function(e){return o(e.levelOfMeasurements,["Interval"])});if(n&&n.sum&&n.rawData){var r=1/n.sum,s=n.rawData.map(function(e){return e*r}).reduce(function(e,t){return e*t}),a=n.rawData.length,l=Math.pow(1/a,a);t=2*(Math.abs(l-Math.abs(s))/l)}}return t<.1?.1:t}},"landscape-or-portrait":{id:"landscape-or-portrait",type:"SOFT",docs:{lintText:"Recommend column charts for landscape layout and bar charts for portrait layout."},trigger:function(e){return f.includes(e.chartType)&&g(e)},validator:function(e){var t=1,i=e.chartType,n=e.preferences;return g(e)&&("portrait"===n.canvasLayout&&["bar_chart","grouped_bar_chart","stacked_bar_chart","percent_stacked_bar_chart"].includes(i)?t=5:"landscape"===n.canvasLayout&&["column_chart","grouped_column_chart","stacked_column_chart","percent_stacked_column_chart"].includes(i)&&(t=5)),t}},"limit-series":{id:"limit-series",type:"SOFT",docs:{lintText:"Avoid too many values in one series."},trigger:function(e){return e.dataProps.filter(function(e){return l(e.levelOfMeasurements,["Nominal","Ordinal"])}).length>=2},validator:function(e){var t=1,i=e.dataProps,n=e.chartType;if(i){var r=i.filter(function(e){return l(e.levelOfMeasurements,["Nominal","Ordinal"])});if(r.length>=2){var o=r.sort(h)[1];o.distinct&&(t=o.distinct>10?.1:1/o.distinct,o.distinct>6&&"heatmap"===n?t=5:"heatmap"===n&&(t=1))}}return t}},"line-field-time-ordinal":{id:"line-field-time-ordinal",type:"SOFT",docs:{lintText:"Data containing time or ordinal fields are suitable for line or area charts."},trigger:function(e){var t=e.chartType;return p.includes(t)},validator:function(e){var t=1,i=e.dataProps;return i&&i.find(function(e){return l(e.levelOfMeasurements,["Ordinal","Time"])})&&(t=5),t}},"no-redundant-field":{id:"no-redundant-field",type:"HARD",docs:{lintText:"No redundant field."},trigger:function(){return!0},validator:function(e){var t=0,i=e.dataProps,n=e.chartType,r=e.chartWIKI;if(i&&n&&r[n]){var o=(r[n].dataPres||[]).map(function(e){return"*"===e.maxQty?99:e.maxQty}).reduce(function(e,t){return e+t});i.length&&i.length<=o&&(t=1)}return t}},"nominal-enum-combinatorial":{id:"nominal-enum-combinatorial",type:"SOFT",docs:{lintText:"Single (Basic) and Multi (Stacked, Grouped,...) charts should be optimized recommended by nominal enums combinatorial numbers."},trigger:function(e){var t=e.chartType,i=e.dataProps;return m.includes(t)&&_(i).length>=2},validator:function(e){var t=1,i=e.dataProps,n=e.chartType;if(i){var r=_(i);if(r.length>=2){var o=r.sort(h),s=o[0],a=o[1];s.distinct===s.count&&["bar_chart","column_chart"].includes(n)&&(t=5),s.count&&s.distinct&&a.distinct&&s.count>s.distinct&&["grouped_bar_chart","grouped_column_chart","stacked_bar_chart","stacked_column_chart"].includes(n)&&(t=5)}}return t}},"purpose-check":{id:"purpose-check",type:"HARD",docs:{lintText:"Choose chart types that satisfy the purpose, if purpose is defined."},trigger:function(){return!0},validator:function(e){var t=0,i=e.chartType,n=e.purpose,r=e.chartWIKI;return n?(i&&r[i]&&n&&(r[i].purpose||"").includes(n)&&(t=1),t):t=1}},"series-qty-limit":{id:"series-qty-limit",type:"SOFT",docs:{lintText:"Some charts should has at most N values for the series."},trigger:function(e){var t=e.chartType;return E.includes(t)},validator:function(e){var t=1,i=e.dataProps,n=e.chartType,r=e.limit;if((!Number.isInteger(r)||r<=0)&&(r=6,("pie_chart"===n||"donut_chart"===n||"rose_chart"===n)&&(r=6),"radar_chart"===n&&(r=8)),i){var s=i.find(function(e){return o(e.levelOfMeasurements,["Nominal"])}),a=s&&s.count?s.count:0;a>=2&&a<=r&&(t=5+2/a)}return t}},"x-axis-line-fading":{id:"x-axis-line-fading",type:"DESIGN",docs:{lintText:"Adjust axis to make it prettier"},trigger:function(e){var t=e.chartType;return T.includes(t)},optimizer:function(e,t){var i,n=y(t).encode;if(n&&(null===(i=n.y)||void 0===i?void 0:i.type)==="quantitative"){var r=e.find(function(e){var t;return e.name===(null===(t=n.y)||void 0===t?void 0:t.field)});if(r){var o=r.maximum-r.minimum;if(r.minimum&&r.maximum&&o<2*r.maximum/3){var s=Math.floor(r.minimum-o/5);return{axis:{x:{tick:!1}},scale:{y:{domainMin:s>0?s:0}},clip:!0}}}}return{}}}},A=Object.keys(R),N=function(e){var t={};return e.forEach(function(e){Object.keys(R).includes(e)&&(t[e]=R[e])}),t},O=function(e){if(!e)return N(A);var t=N(A);if(e.exclude&&e.exclude.forEach(function(e){Object.keys(t).includes(e)&&delete t[e]}),e.include){var i=e.include;Object.keys(t).forEach(function(e){i.includes(e)||delete t[e]})}var r=(0,n.pi)((0,n.pi)({},t),e.custom),o=e.options;return o&&Object.keys(o).forEach(function(e){if(Object.keys(r).includes(e)){var t=o[e];r[e]=(0,n.pi)((0,n.pi)({},r[e]),{option:t})}}),r},L=[[!0,!1],[0,1],["true","false"],["Yes","No"],["True","False"],["0","1"],["是","否"]],I="([-_./\\s])",w="(18|19|20)\\d{2}",D="(0?[1-9]|1[012])",x="(0?[1-9]|[12]\\d|3[01])",M="(0?\\d|1\\d|2[0-4])",k="(0?\\d|[012345]\\d)",P="(Z|[+-]".concat(M,"(:").concat(k,")?)");function F(e){return null==e||""===e||Number.isNaN(e)||"null"===e}function B(e){return"string"==typeof e}function U(e){return"number"==typeof e}function H(e){if(B(e)){var t=!1,i=e;/^[+-]/.test(i)&&(i=i.slice(1));for(var n=0;n0&&t<100,"The percent cannot be between (0, 100)."),(i?e:e.sort(function(e,t){return e>t?1:-1}))[Math.ceil(e.length*t/100)-1]}function eo(e){var t=en(e),i=J(e,"variance");return void 0!==i?i:Q(e,"variance",e.reduce(function(e,i){return e+Math.pow(i-t,2)},0)/e.length)}function es(e){return Math.sqrt(eo(e))}function ea(e){var t={};return e.forEach(function(e){var i="".concat(e);t[i]?t[i]+=1:t[i]=1}),t}var el=function(e){var t,i,r=(void 0===(t=e)&&(t=!0),["".concat(w),"".concat(w).concat(I).concat(t?"":"?","W").concat("([0-4]\\d|5[0-2])","(").concat(I).concat(t?"":"?").concat("([1-7])",")?"),"".concat(D).concat(I).concat(t?"":"?").concat(x).concat(I).concat(t?"":"?").concat(w),"".concat(w).concat(I).concat(t?"":"?").concat(D).concat(I).concat(t?"":"?").concat(x),"".concat(w).concat(I).concat(t?"":"?").concat(D),"".concat(w).concat(I).concat(t?"":"?").concat("((([0-2]\\d|3[0-5])\\d)|36[0-6])")]),o=(void 0===(i=e)&&(i=!0),["".concat(M,":").concat(i?"":"?").concat(k,":").concat(i?"":"?").concat(k,"([.,]").concat("\\d{1,4}",")?").concat(P,"?"),"".concat(M,":").concat(i?"":"?").concat(k,"?").concat(P)]),s=(0,n.ev)((0,n.ev)([],(0,n.CR)(r),!1),(0,n.CR)(o),!1);return r.forEach(function(e){o.forEach(function(t){s.push("".concat(e,"[T\\s]").concat(t))})}),s.map(function(e){return new RegExp("^".concat(e,"$"))})};function eh(e,t){if(B(e)){for(var i=el(t),n=0;n0&&(c.generateColumns([0],null==i?void 0:i.columns),c.colData=[c.data],c.data=c.data.map(function(e){return[e]})),Y(g)){var p=q(g.length);c.generateDataAndColDataFromArray(!1,t,p,null==i?void 0:i.fillValue,null==i?void 0:i.columnTypes),c.generateColumns(p,null==i?void 0:i.columns)}if(K(g)){for(var m=[],f=0;f=0&&m>=0||_.length>0,"The rowLoc is not found in the indexes."),p>=0&&m>=0&&(A=this.data.slice(p,m),N=this.indexes.slice(p,m)),_.length>0)for(var a=0;a<_.length;a+=1){var C=_[a];A.push(this.data[C]),N.push(this.indexes[C])}if(E>=0&&v>=0){for(var a=0;a0){for(var O=[],L=A.slice(),a=0;a=0&&p>=0||m.length>0,"The colLoc is illegal"),V(i)&&q(this.columns.length).includes(i)&&(_=i,E=i+1),Y(i))for(var a=0;a=0&&p>=0||m.length>0,"The rowLoc is not found in the indexes.");var R=[],A=[];if(g>=0&&p>=0)R=this.data.slice(g,p),A=this.indexes.slice(g,p);else if(m.length>0)for(var a=0;a=0&&E>=0||v.length>0,"The colLoc is not found in the columns index."),_>=0&&E>=0){for(var a=0;a0){for(var N=[],O=R.slice(),a=0;a1){var E={},v=f;g.forEach(function(t){"date"===t?(E.date=e(v.filter(function(e){return eh(e)}),i),v=v.filter(function(e){return!eh(e)})):"integer"===t?(E.integer=e(v.filter(function(e){return W(e)}),i),v=v.filter(function(e){return!W(e)})):"float"===t?(E.float=e(v.filter(function(e){return G(e)}),i),v=v.filter(function(e){return!G(e)})):"string"===t&&(E.string=e(v.filter(function(e){return"string"===ed(e,i)})),v=v.filter(function(e){return"string"!==ed(e,i)}))}),_.meta=E}2===_.distinct&&"date"!==_.recommendation&&(d.length>=100?_.recommendation="boolean":z(m,!0)&&(_.recommendation="boolean")),"string"===u&&Object.assign(_,{maxLength:et(r=(n=f.map(function(e){return"".concat(e)})).map(function(e){return e.length})),minLength:ee(r),meanLength:en(r),containsChar:n.some(function(e){return/[A-z]/.test(e)}),containsDigit:n.some(function(e){return/[0-9]/.test(e)}),containsSpace:n.some(function(e){return/\s/.test(e)})}),("integer"===u||"float"===u)&&Object.assign(_,{minimum:ee(o=f.map(function(e){return 1*e})),maximum:et(o),mean:en(o),percentile5:er(o,5),percentile25:er(o,25),percentile50:er(o,50),percentile75:er(o,75),percentile95:er(o,95),sum:ei(o),variance:eo(o),standardDeviation:es(o),zeros:o.filter(function(e){return 0===e}).length}),"date"===u&&Object.assign(_,(s="integer"===_.type,a=f.map(function(e){if(s){var t="".concat(e);if(8===t.length)return new Date("".concat(t.substring(0,4),"/").concat(t.substring(4,2),"/").concat(t.substring(6,2))).getTime()}return new Date(e).getTime()}),{minimum:f[void 0!==(l=J(a,"minIndex"))?l:Q(a,"minIndex",function(e){for(var t=e[0],i=0,n=0;nt&&(i=n,t=e[n]);return i}(a))]}));var b=[];return"boolean"!==_.recommendation&&("string"!==_.recommendation||eu(_))||b.push("Nominal"),eu(_)&&b.push("Ordinal"),("integer"===_.recommendation||"float"===_.recommendation)&&b.push("Interval"),"integer"===_.recommendation&&b.push("Discrete"),"float"===_.recommendation&&b.push("Continuous"),"date"===_.recommendation&&b.push("Time"),_.levelOfMeasurements=b,_}(this.colData[i],this.extra.strictDatePattern)),{name:String(r)}))}return t},t.prototype.toString=function(){for(var e=this,t=Array(this.columns.length+1).fill(0),i=0;it[0]&&(t[0]=n)}for(var i=0;it[i+1]&&(t[i+1]=n)}for(var i=0;it[i+1]&&(t[i+1]=n)}return"".concat(ep(t[0])).concat(this.columns.map(function(i,n){return"".concat(i).concat(n!==e.columns.length?ep(t[n+1]-e_(i)+2):"")}).join(""),"\n").concat(this.indexes.map(function(i,n){var r;return"".concat(i).concat(ep(t[0]-e_(i))).concat(null===(r=e.data[n])||void 0===r?void 0:r.map(function(i,n){return"".concat(em(i)).concat(n!==e.columns.length?ep(t[n+1]-e_(i)):"")}).join("")).concat(n!==e.indexes.length?"\n":"")}).join(""))},t}(ev),eS=function(e){if("object"!=typeof e||null===e)return e;if(Array.isArray(e)){t=[];for(var t,i=0,n=e.length;i!!eA().valid(e);function eO(e){let{value:t}=e;return eN(t)?eA()(t).hex():""}let eL={lab:{l:[0,100],a:[-86.185,98.254],b:[-107.863,94.482]},lch:{l:[0,100],c:[0,100],h:[0,360]},rgb:{r:[0,255],g:[0,255],b:[0,255]},rgba:{r:[0,255],g:[0,255],b:[0,255],a:[0,1]},hsl:{h:[0,360],s:[0,1],l:[0,1]},hsv:{h:[0,360],s:[0,1],v:[0,1]},hsi:{h:[0,360],s:[0,1],i:[0,1]},cmyk:{c:[0,1],m:[0,1],y:[0,1],k:[0,1]}},eI=e=>!!eA().valid(e),ew=e=>{let{value:t}=e;return eI(t)?eA()(t):eA()("#000")},eD=(e,t=e.model)=>{let i=ew(e);return i?i[t]():[0,0,0]},ex=(e,t=4===e.length?"rgba":"rgb")=>{let i={};if(1===e.length){let[n]=e;for(let e=0;ee*t/255,eB=(e,t)=>e+t-e*t/255,eU=(e,t)=>e<128?eF(2*e,t):eB(2*e-255,t),eH={normal:e=>e,darken:(e,t)=>Math.min(e,t),multiply:eF,colorBurn:(e,t)=>0===e?0:Math.max(0,255*(1-(255-t)/e)),lighten:(e,t)=>Math.max(e,t),screen:eB,colorDodge:(e,t)=>255===e?255:Math.min(255,255*(t/(255-e))),overlay:(e,t)=>eU(t,e),softLight:(e,t)=>{if(e<128)return t-(1-2*e/255)*t*(1-t/255);let i=t<64?((16*(t/255)-12)*(t/255)+4)*(t/255):Math.sqrt(t/255);return t+255*(2*e/255-1)*(i-t/255)},hardLight:eU,difference:(e,t)=>Math.abs(e-t),exclusion:(e,t)=>e+t-2*e*t/255,linearBurn:(e,t)=>Math.max(e+t-255,0),linearDodge:(e,t)=>Math.min(255,e+t),linearLight:(e,t)=>Math.max(t+2*e-255,0),vividLight:(e,t)=>e<128?255*(1-(1-t/255)/(2*e/255)):255*(t/2/(255-e)),pinLight:(e,t)=>e<128?Math.min(t,2*e):Math.max(t,2*e-255)},eV=e=>.3*e[0]+.58*e[1]+.11*e[2],eW=e=>{let t=eV(e),i=Math.min(...e),n=Math.max(...e),r=[...e];return i<0&&(r=r.map(e=>t+(e-t)*t/(t-i))),n>255&&(r=r.map(e=>t+(e-t)*(255-t)/(n-t))),r},eG=(e,t)=>{let i=t-eV(e);return eW(e.map(e=>e+i))},ej=e=>Math.max(...e)-Math.min(...e),ez=(e,t)=>{let i=e.map((e,t)=>({value:e,index:t}));i.sort((e,t)=>e.value-t.value);let n=i[0].index,r=i[1].index,o=i[2].index,s=[...e];return s[o]>s[n]?(s[r]=(s[r]-s[n])*t/(s[o]-s[n]),s[o]=t):(s[r]=0,s[o]=0),s[n]=0,s},eK={hue:(e,t)=>eG(ez(e,ej(t)),eV(t)),saturation:(e,t)=>eG(ez(t,ej(e)),eV(t)),color:(e,t)=>eG(e,eV(t)),luminosity:(e,t)=>eG(t,eV(e))},eY=(e,t,i="normal")=>{let n;let[r,o,s,a]=eD(e,"rgba"),[l,h,u,d]=eD(t,"rgba"),c=[r,o,s],f=[l,h,u];if(eT.includes(i)){let e=eH[i];n=c.map((t,i)=>Math.floor(e(t,f[i])))}else n=eK[i](c,f);let g=a+d*(1-a),p=Math.round((a*(1-d)*r+a*d*n[0]+(1-a)*d*l)/g),m=Math.round((a*(1-d)*o+a*d*n[1]+(1-a)*d*h)/g),_=Math.round((a*(1-d)*s+a*d*n[2]+(1-a)*d*u)/g);return 1===g?{model:"rgb",value:{r:p,g:m,b:_}}:{model:"rgba",value:{r:p,g:m,b:_,a:g}}},e$=(e,t)=>{let i=(e+t)%360;return i<0?i+=360:i>=360&&(i-=360),i},eq=(e=1,t=0)=>{let i=Math.min(e,t),n=Math.max(e,t);return i+Math.random()*(n-i)},eX=(e=1,t=0)=>{let i=Math.ceil(Math.min(e,t)),n=Math.floor(Math.max(e,t));return Math.floor(i+Math.random()*(n-i+1))},eZ=e=>{if(e&&"object"==typeof e){let t=Array.isArray(e);if(t){let t=e.map(e=>eZ(e));return t}let i={},n=Object.keys(e);return n.forEach(t=>{i[t]=eZ(e[t])}),i}return e};function eQ(e){return e*(Math.PI/180)}var eJ=i(56917),e0=i.n(eJ);let e1=(e,t="normal")=>{if("normal"===t)return{...e};let i=eO(e),n=e0()[t](i);return eP(n)},e2=e=>{let t=eM(e),[,,,i=1]=eD(e,"rgba");return ek(t,i)},e5=(e,t="normal")=>"grayscale"===t?e2(e):e1(e,t),e4=(e,t,i=[eX(5,10),eX(90,95)])=>{let[n,r,o]=eD(e,"lab"),s=n<=15?n:i[0],a=n>=85?n:i[1],l=(a-s)/(t-1),h=Math.ceil((n-s)/l);return l=0===h?l:(n-s)/h,Array(t).fill(0).map((e,t)=>ex([l*t+s,r,o],"lab"))},e3=e=>{let{count:t,color:i,tendency:n}=e,r=e4(i,t),o={name:"monochromatic",semantic:null,type:"discrete-scale",colors:"tint"===n?r:r.reverse()};return o},e6={model:"rgb",value:{r:0,g:0,b:0}},e9={model:"rgb",value:{r:255,g:255,b:255}},e8=(e,t,i="lab")=>eA().distance(ew(e),ew(t),i),e7=(e,t)=>{let i=Math.atan2(e,t)*(180/Math.PI);return i>=0?i:i+360},te=(e,t)=>{let i,n;let[r,o,s]=eD(e,"lab"),[a,l,h]=eD(t,"lab"),u=Math.sqrt(o**2+s**2),d=Math.sqrt(l**2+h**2),c=(u+d)/2,f=.5*(1-Math.sqrt(c**7/(c**7+6103515625))),g=(1+f)*o,p=(1+f)*l,m=Math.sqrt(g**2+s**2),_=Math.sqrt(p**2+h**2),E=e7(s,g),v=e7(h,p),b=_-m;i=180>=Math.abs(v-E)?v-E:v-E<-180?v-E+360:v-E-360;let C=2*Math.sqrt(m*_)*Math.sin(eQ(i)/2);n=180>=Math.abs(E-v)?(E+v)/2:Math.abs(E-v)>180&&E+v<360?(E+v+360)/2:(E+v-360)/2;let S=(r+a)/2,y=(m+_)/2,T=1-.17*Math.cos(eQ(n-30))+.24*Math.cos(eQ(2*n))+.32*Math.cos(eQ(3*n+6))-.2*Math.cos(eQ(4*n-63)),R=1+.015*(S-50)**2/Math.sqrt(20+(S-50)**2),A=1+.045*y,N=1+.015*y*T,O=-2*Math.sqrt(y**7/(y**7+6103515625))*Math.sin(eQ(60*Math.exp(-(((n-275)/25)**2)))),L=Math.sqrt(((a-r)/(1*R))**2+(b/(1*A))**2+(C/(1*N))**2+O*(b/(1*A))*(C/(1*N)));return L},tt=e=>{let t=e/255;return t<=.03928?t/12.92:((t+.055)/1.055)**2.4},ti=e=>{let[t,i,n]=eD(e);return .2126*tt(t)+.7152*tt(i)+.0722*tt(n)},tn=(e,t)=>{let i=ti(e),n=ti(t);return n>i?(n+.05)/(i+.05):(i+.05)/(n+.05)},tr=(e,t,i={measure:"euclidean"})=>{let{measure:n="euclidean",backgroundColor:r=ey}=i,o=eY(e,r),s=eY(t,r);switch(n){case"CIEDE2000":return te(o,s);case"euclidean":return e8(o,s,i.colorModel);case"contrastRatio":return tn(o,s);default:return e8(o,s)}},to=[.8,1.2],ts={rouletteWheel:e=>{let t=e.reduce((e,t)=>e+t),i=0,n=eq(t),r=0;for(let t=0;t{let t=-1,i=0;for(let n=0;n<3;n+=1){let r=eX(e.length-1);e[r]>i&&(t=n,i=e[r])}return t}},ta=(e,t="tournament")=>ts[t](e),tl=(e,t)=>{let i=eZ(e),n=eZ(t);for(let r=1;r{let r=eZ(e),o=t[eX(t.length-1)],s=eX(e[0].length-1),a=r[o][s]*eq(...to),l=[15,240];"grayscale"!==i&&(l=eL[n][n.split("")[s]]);let[h,u]=l;return au&&(a=u),r[o][s]=a,r},tu=(e,t,i,n,r,o)=>{let s;s="grayscale"===i?e.map(([e])=>ek(e)):e.map(e=>e5(ex(e,n),i));let a=1/0;for(let e=0;e{if(Math.round(tu(e,t,i,r,o,s))>n)return e;let a=Array(e.length).fill(0).map((e,t)=>t).filter((e,i)=>!t[i]),l=Array(50).fill(0).map(()=>th(e,a,i,r)),h=l.map(e=>tu(e,t,i,r,o,s)),u=Math.max(...h),d=l[h.findIndex(e=>e===u)],c=1;for(;c<100&&Math.round(u)eq()?tl(t,n):[t,n];o=o.map(e=>.1>eq()?th(e,a,i,r):e),e.push(...o)}h=(l=e).map(e=>tu(e,t,i,r,o,s));let n=Math.max(...h);u=n,d=l[h.findIndex(e=>e===n)],c+=1}return d},tc={euclidean:30,CIEDE2000:20,contrastRatio:4.5},tf={euclidean:291.48,CIEDE2000:100,contrastRatio:21},tg=(e,t={})=>{let{locked:i=[],simulationType:n="normal",threshold:r,colorModel:o="hsv",colorDifferenceMeasure:s="euclidean",backgroundColor:a=ey}=t,l=r;if(l||(l=tc[s]),"grayscale"===n){let t=tf[s];l=Math.min(l,t/e.colors.length)}let h=eZ(e);if("matrix"!==h.type&&"continuous-scale"!==h.type){if("grayscale"===n){let e=h.colors.map(e=>[eM(e)]),t=td(e,i,n,l,o,s,a);h.colors.forEach((e,i)=>Object.assign(e,function(e,t){let i;let[,n,r]=eD(t,"lab"),[,,,o=1]=eD(t,"rgba"),s=100*e,a=Math.round(s),l=eM(ex([a,n,r],"lab")),h=25;for(;Math.round(s)!==Math.round(l/255*100)&&h>0;)s>l/255*100?a+=1:a-=1,h-=1,l=eM(ex([a,n,r],"lab"));if(Math.round(s)eD(e,o)),t=td(e,i,n,l,o,s,a);h.colors.forEach((e,i)=>{Object.assign(e,ex(t[i],o))})}}return h},tp=[.3,.9],tm=[.5,1],t_=(e,t,i,n=[])=>{let[r]=eD(e,"hsv"),o=Array(i).fill(!1),s=-1===n.findIndex(t=>t&&t.model===e.model&&t.value===e.value),a=Array(i).fill(0).map((i,a)=>{let l=n[a];return l?(o[a]=!0,l):s?(s=!1,o[a]=!0,e):ex([e$(r,t*a),eq(...tp),eq(...tm)],"hsv")});return{newColors:a,locked:o}};function tE(){let e=eX(255),t=eX(255),i=eX(255);return ex([e,t,i],"rgb")}let tv=e=>{let{count:t,colors:i}=e,n=[],r={name:"random",semantic:null,type:"categorical",colors:Array(t).fill(0).map((e,t)=>{let r=i[t];return r?(n[t]=!0,r):tE()})};return tg(r,{locked:n})},tb=["monochromatic"],tC=(e,t)=>{let{count:i=8,tendency:n="tint"}=t,{colors:r=[],color:o}=t;return o||(o=r.find(e=>!!e&&!!e.model&&!!e.value)||tE()),tb.includes(e)&&(r=[]),{color:o,colors:r,count:i,tendency:n}},tS={monochromatic:e3,analogous:e=>{let{count:t,color:i,tendency:n}=e,[r,o,s]=eD(i,"hsv"),a=Math.floor(t/2),l=60/(t-1);r>=60&&r<=240&&(l=-l);let h=(o-.1)/3/(t-a-1),u=(s-.4)/3/a,d=Array(t).fill(0).map((e,t)=>{let i=e$(r,l*(t-a)),n=t<=a?Math.min(o+h*(a-t),1):o+3*h*(a-t),d=t<=a?s-3*u*(a-t):Math.min(s-u*(a-t),1);return ex([i,n,d],"hsv")}),c={name:"analogous",semantic:null,type:"discrete-scale",colors:"tint"===n?d:d.reverse()};return c},achromatic:e=>{let{tendency:t}=e,i={...e,color:"tint"===t?e6:e9},n=e3(i);return{...n,name:"achromatic"}},complementary:e=>{let t;let{count:i,color:n}=e,[r,o,s]=eD(n,"hsv"),a=ex([e$(r,180),o,s],"hsv"),l=eX(80,90),h=eX(15,25),u=Math.floor(i/2),d=e4(n,u,[h,l]),c=e4(a,u,[h,l]).reverse();if(i%2==1){let e=ex([(e$(r,180)+r)/2,eq(.05,.1),eq(.9,.95)],"hsv");t=[...d,e,...c]}else t=[...d,...c];let f={name:"complementary",semantic:null,type:"discrete-scale",colors:t};return f},"split-complementary":e=>{let{count:t,color:i,colors:n}=e,{newColors:r,locked:o}=t_(i,180,t,n);return tg({name:"tetradic",semantic:null,type:"categorical",colors:r},{locked:o})},triadic:e=>{let{count:t,color:i,colors:n}=e,{newColors:r,locked:o}=t_(i,120,t,n);return tg({name:"tetradic",semantic:null,type:"categorical",colors:r},{locked:o})},tetradic:e=>{let{count:t,color:i,colors:n}=e,{newColors:r,locked:o}=t_(i,90,t,n);return tg({name:"tetradic",semantic:null,type:"categorical",colors:r},{locked:o})},polychromatic:e=>{let{count:t,color:i,colors:n}=e,r=360/t,{newColors:o,locked:s}=t_(i,r,t,n);return tg({name:"tetradic",semantic:null,type:"categorical",colors:o},{locked:s})},customized:tv},ty=(e="monochromatic",t={})=>{let i=tC(e,t);try{return tS[e](i)}catch(e){return tv(i)}};i(16243);var tT={}.toString,tR=function(e,t){return tT.call(e)==="[object ".concat(t,"]")},tA=function(e){if(!("object"==typeof e&&null!==e)||!tR(e,"Object"))return!1;if(null===Object.getPrototypeOf(e))return!0;for(var t=e;null!==Object.getPrototypeOf(t);)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t},tN=function(e){for(var t=[],i=1;it.distinct)return -1}return 0};function tw(e){return[e.find(function(e){return o(e.levelOfMeasurements,["Nominal"])}),e.find(function(e){return o(e.levelOfMeasurements,["Interval"])})]}function tD(e,t){var i=t.find(function(t){return t.name===e});return(null==i?void 0:i.recommendation)==="date"?function(t){return new Date(t[e])}:e}function tx(e){return[e.find(function(e){return l(e.levelOfMeasurements,["Time","Ordinal"])}),e.find(function(e){return o(e.levelOfMeasurements,["Interval"])}),e.find(function(e){return o(e.levelOfMeasurements,["Nominal"])})]}function tM(e){var t=e.find(function(e){return l(e.levelOfMeasurements,["Time","Ordinal"])}),i=e.find(function(e){return o(e.levelOfMeasurements,["Nominal"])});return[t,e.find(function(e){return o(e.levelOfMeasurements,["Interval"])}),i]}function tk(e){var t=e.filter(function(e){return o(e.levelOfMeasurements,["Nominal"])}).sort(tI),i=t[0],n=t[1];return[e.find(function(e){return o(e.levelOfMeasurements,["Interval"])}),i,n]}function tP(e){var t,i,r,s,a,l,h=e.filter(function(e){return o(e.levelOfMeasurements,["Nominal"])}).sort(tI);return!function(e,t){if(!Y(e)||0===e.length||!Y(t)||0===t.length||e.length!==t.length)return!1;for(var i={},n=0;nr.corr&&(r.x=i[e],r.y=i[t],r.corr=a,r.size=i[(0,n.ev)([],(0,n.CR)(Array(i.length).keys()),!1).find(function(i){return i!==e&&i!==t})||0])},o=e+1;o0&&(!_||e.spec)}).sort(function(e,t){return e.scoret.score?-1:0}),log:v}}catch(e){return console.error("error: ",e),null}}var tH=function(e){var t,i=e.coordinate;if((null==i?void 0:i.type)==="theta")return(null==i?void 0:i.innerRadius)?"donut_chart":"pie_chart";var n=e.transform,r=null===(t=null==i?void 0:i.transform)||void 0===t?void 0:t.some(function(e){return"transpose"===e.type}),o=null==n?void 0:n.some(function(e){return"normalizeY"===e.type}),s=null==n?void 0:n.some(function(e){return"stackY"===e.type}),a=null==n?void 0:n.some(function(e){return"dodgeX"===e.type});return r?a?"grouped_bar_chart":o?"stacked_bar_chart":s?"percent_stacked_bar_chart":"bar_chart":a?"grouped_column_chart":o?"stacked_column_chart":s?"percent_stacked_column_chart":"column_chart"},tV=function(e){var t=e.transform,i=null==t?void 0:t.some(function(e){return"stackY"===e.type}),n=null==t?void 0:t.some(function(e){return"normalizeY"===e.type});return i?n?"percent_stacked_area_chart":"stacked_area_chart":"area_chart"},tW=function(e){var t=e.encode;return t.shape&&"hvh"===t.shape?"step_line_chart":"line_chart"},tG=function(e){var t;switch(e.type){case"area":t=tV(e);break;case"interval":t=tH(e);break;case"line":t=tW(e);break;case"point":t=e.encode.size?"bubble_chart":"scatter_plot";break;case"rect":t="histogram";break;case"cell":t="heatmap";break;default:t=""}return t};function tj(e,t,i,r,o,s,a){Object.values(e).filter(function(e){var r,o,a=e.option||{},l=a.weight,h=a.extra;return r=e.type,("DESIGN"===t?"DESIGN"===r:"DESIGN"!==r)&&!(null===(o=e.option)||void 0===o?void 0:o.off)&&e.trigger((0,n.pi)((0,n.pi)((0,n.pi)((0,n.pi)({},i),{weight:l}),h),{chartWIKI:s}))}).forEach(function(e){var l,h=e.type,u=e.id,d=e.docs;if("DESIGN"===t){var c=e.optimizer(i.dataProps,a);l=0===Object.keys(c).length?1:0,o.push({type:h,id:u,score:l,fix:c,docs:d})}else{var f=e.option||{},g=f.weight,p=f.extra;l=e.validator((0,n.pi)((0,n.pi)((0,n.pi)((0,n.pi)({},i),{weight:g}),p),{chartWIKI:s})),o.push({type:h,id:u,score:l,docs:d})}r.push({phase:"LINT",ruleId:u,score:l,base:l,weight:1,ruleType:h})})}function tz(e,t,i){var n=e.spec,r=e.options,o=e.dataProps,s=null==r?void 0:r.purpose,a=null==r?void 0:r.preferences,l=tG(n),h=[],u=[];if(!n||!l)return{lints:h,log:u};if(!o||!o.length)try{o=new eC(n.data).info()}catch(e){return console.error("error: ",e),{lints:h,log:u}}var d={dataProps:o,chartType:l,purpose:s,preferences:a};return tj(t,"notDESIGN",d,u,h,i),tj(t,"DESIGN",d,u,h,i,n),{lints:h=h.filter(function(e){return e.score<1}),log:u}}var tK=function(){function e(e){var t,i,o,s,a;void 0===e&&(e={}),this.ckb=(t=e.ckbCfg,i=JSON.parse(JSON.stringify(r)),t?(o=t.exclude,s=t.include,a=t.custom,o&&o.forEach(function(e){Object.keys(i).includes(e)&&delete i[e]}),s&&Object.keys(i).forEach(function(e){s.includes(e)||delete i[e]}),(0,n.pi)((0,n.pi)({},i),a)):i),this.ruleBase=O(e.ruleCfg)}return e.prototype.advise=function(e){return tU(e,this.ckb,this.ruleBase).advices},e.prototype.adviseWithLog=function(e){return tU(e,this.ckb,this.ruleBase)},e.prototype.lint=function(e){return tz(e,this.ruleBase,this.ckb).lints},e.prototype.lintWithLog=function(e){return tz(e,this.ruleBase,this.ckb)},e}()},17816:function(e,t){!function(e){"use strict";function t(e){var t="function"==typeof Symbol&&Symbol.iterator,i=t&&e[t],n=0;if(i)return i.call(e);if(e&&"number"==typeof e.length)return{next:function(){return{value:(e=e&&n>=e.length?void 0:e)&&e[n++],done:!e}}};throw TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function i(e,t){var i="function"==typeof Symbol&&e[Symbol.iterator];if(!i)return e;var n,r,o=i.call(e),s=[];try{for(;(void 0===t||0i=>e(t(i)),e)}function T(e,t){return t-e?i=>(i-e)/(t-e):e=>.5}x=new g(3),g!=Float32Array&&(x[0]=0,x[1]=0,x[2]=0),x=new g(4),g!=Float32Array&&(x[0]=0,x[1]=0,x[2]=0,x[3]=0);let R=Math.sqrt(50),A=Math.sqrt(10),N=Math.sqrt(2);function O(e,t,i){return e=Math.floor(Math.log(t=(t-e)/Math.max(0,i))/Math.LN10),i=t/10**e,0<=e?(i>=R?10:i>=A?5:i>=N?2:1)*10**e:-(10**-e)/(i>=R?10:i>=A?5:i>=N?2:1)}let L=(e,t,i=5)=>{let n=0,r=(e=[e,t]).length-1,o=e[n],s=e[r],a;return s{i.prototype.rescale=function(){this.initRange(),this.nice();var[e]=this.chooseTransforms();this.composeOutput(e,this.chooseClamp(e))},i.prototype.initRange=function(){var t=this.options.interpolator;this.options.range=e(t)},i.prototype.composeOutput=function(e,i){var{domain:n,interpolator:r,round:o}=this.getOptions(),n=t(n.map(e)),o=o?e=>a(e=r(e),"Number")?Math.round(e):e:r;this.output=y(o,n,i,e)},i.prototype.invert=void 0}}var D,x={exports:{}},M={exports:{}},k=Array.prototype.concat,P=Array.prototype.slice,F=M.exports=function(e){for(var t=[],i=0,n=e.length;ii=>e*(1-i)+t*i,q=(e,t)=>{if("number"==typeof e&&"number"==typeof t)return $(e,t);if("string"!=typeof e||"string"!=typeof t)return()=>e;{let i=Y(e),n=Y(t);return null===i||null===n?i?()=>e:()=>t:e=>{var t=[,,,,];for(let s=0;s<4;s+=1){var r=i[s],o=n[s];t[s]=r*(1-e)+o*e}var[s,a,l,h]=t;return`rgba(${Math.round(s)}, ${Math.round(a)}, ${Math.round(l)}, ${h})`}}},X=(e,t)=>{let i=$(e,t);return e=>Math.round(i(e))};function Z({map:e,initKey:t},i){return t=t(i),e.has(t)?e.get(t):i}function Q(e){return"object"==typeof e?e.valueOf():e}class J extends Map{constructor(e){if(super(),this.map=new Map,this.initKey=Q,null!==e)for(var[t,i]of e)this.set(t,i)}get(e){return super.get(Z({map:this.map,initKey:this.initKey},e))}has(e){return super.has(Z({map:this.map,initKey:this.initKey},e))}set(e,t){var i,n;return super.set(([{map:e,initKey:i},n]=[{map:this.map,initKey:this.initKey},e],i=i(n),e.has(i)?e.get(i):(e.set(i,n),n)),t)}delete(e){var t,i;return super.delete(([{map:e,initKey:t},i]=[{map:this.map,initKey:this.initKey},e],t=t(i),e.has(t)&&(i=e.get(t),e.delete(t)),i))}}class ee{constructor(e){this.options=d({},this.getDefaultOptions()),this.update(e)}getOptions(){return this.options}update(e={}){this.options=d({},this.options,e),this.rescale(e)}rescale(e){}}let et=Symbol("defaultUnknown");function ei(e,t,i){for(let n=0;n""+e:"object"==typeof e?e=>JSON.stringify(e):e=>e}class eo extends ee{getDefaultOptions(){return{domain:[],range:[],unknown:et}}constructor(e){super(e)}map(e){return 0===this.domainIndexMap.size&&ei(this.domainIndexMap,this.getDomain(),this.domainKey),en({value:this.domainKey(e),mapper:this.domainIndexMap,from:this.getDomain(),to:this.getRange(),notFoundReturn:this.options.unknown})}invert(e){return 0===this.rangeIndexMap.size&&ei(this.rangeIndexMap,this.getRange(),this.rangeKey),en({value:this.rangeKey(e),mapper:this.rangeIndexMap,from:this.getRange(),to:this.getDomain(),notFoundReturn:this.options.unknown})}rescale(e){var[t]=this.options.domain,[i]=this.options.range;this.domainKey=er(t),this.rangeKey=er(i),this.rangeIndexMap?(e&&!e.range||this.rangeIndexMap.clear(),(!e||e.domain||e.compare)&&(this.domainIndexMap.clear(),this.sortedDomain=void 0)):(this.rangeIndexMap=new Map,this.domainIndexMap=new Map)}clone(){return new eo(this.options)}getRange(){return this.options.range}getDomain(){var e,t;return this.sortedDomain||({domain:e,compare:t}=this.options,this.sortedDomain=t?[...e].sort(t):e),this.sortedDomain}}class es extends eo{getDefaultOptions(){return{domain:[],range:[0,1],align:.5,round:!1,paddingInner:0,paddingOuter:0,padding:0,unknown:et,flex:[]}}constructor(e){super(e)}clone(){return new es(this.options)}getStep(e){return void 0===this.valueStep?1:"number"==typeof this.valueStep?this.valueStep:void 0===e?Array.from(this.valueStep.values())[0]:this.valueStep.get(e)}getBandWidth(e){return void 0===this.valueBandWidth?1:"number"==typeof this.valueBandWidth?this.valueBandWidth:void 0===e?Array.from(this.valueBandWidth.values())[0]:this.valueBandWidth.get(e)}getRange(){return this.adjustedRange}getPaddingInner(){var{padding:e,paddingInner:t}=this.options;return 0e/t)}(h),g=d/f.reduce((e,t)=>e+t);var h=new J(t.map((e,t)=>(t=f[t]*g,[e,s?Math.floor(t):t]))),p=new J(t.map((e,t)=>(t=f[t]*g+c,[e,s?Math.floor(t):t]))),d=Array.from(p.values()).reduce((e,t)=>e+t),e=e+(u-(d-d/l*r))*a;let m=s?Math.round(e):e;var _=Array(l);for(let e=0;el+t*s),{valueStep:s,valueBandWidth:a,adjustedRange:e}}({align:e,range:i,round:n,flex:r,paddingInner:this.getPaddingInner(),paddingOuter:this.getPaddingOuter(),domain:t});this.valueStep=n,this.valueBandWidth=i,this.adjustedRange=e}}let ea=(e,t,i)=>{let n,r,o=e,s=t;if(o===s&&0{let n;var[e,r]=e,[t,o]=t;return y(e{let n=Math.min(e.length,t.length)-1,r=Array(n),o=Array(n);var s=e[0]>e[n],a=s?[...e].reverse():e,l=s?[...t].reverse():t;for(let e=0;e{var i=function(e,t,i,n,r){let o=1,s=n||e.length;for(var a=e=>e;ot?s=l:o=l+1}return o}(e,t,0,n)-1,s=r[i];return y(o[i],s)(t)}},eu=(e,t,i,n)=>(2Math.min(Math.max(n,e),r)}return c}composeOutput(e,t){var{domain:i,range:n,round:r,interpolate:o}=this.options,i=eu(i.map(e),n,o,r);this.output=y(i,t,e)}composeInput(e,t,i){var{domain:n,range:r}=this.options,r=eu(r,n.map(e),$);this.input=y(t,i,r)}}class ec extends ed{getDefaultOptions(){return{domain:[0,1],range:[0,1],unknown:void 0,nice:!1,clamp:!1,round:!1,interpolate:q,tickMethod:ea,tickCount:5}}chooseTransforms(){return[c,c]}clone(){return new ec(this.options)}}class ef extends es{getDefaultOptions(){return{domain:[],range:[0,1],align:.5,round:!1,padding:0,unknown:et,paddingInner:1,paddingOuter:0}}constructor(e){super(e)}getPaddingInner(){return 1}clone(){return new ef(this.options)}update(e){super.update(e)}getPaddingOuter(){return this.options.padding}}function eg(e,t){for(var i=[],n=0,r=e.length;n{var[e,t]=e;return y($(0,1),T(e,t))})],e_);let eE=o=class extends ec{getDefaultOptions(){return{domain:[0,.5,1],unknown:void 0,nice:!1,clamp:!1,round:!1,interpolator:c,tickMethod:ea,tickCount:5}}constructor(e){super(e)}clone(){return new o(this.options)}};function ev(e,t,n,r,o){var s=new ec({range:[t,t+r]}),a=new ec({range:[n,n+o]});return{transform:function(e){var e=i(e,2),t=e[0],e=e[1];return[s.map(t),a.map(e)]},untransform:function(e){var e=i(e,2),t=e[0],e=e[1];return[s.invert(t),a.invert(e)]}}}function eb(e,t,n,r,o){return(0,i(e,1)[0])(t,n,r,o)}function eC(e,t,n,r,o){return i(e,1)[0]}function eS(e,t,n,r,o){var s=(e=i(e,4))[0],a=e[1],l=e[2],e=e[3],h=new ec({range:[l,e]}),u=new ec({range:[s,a]}),d=1<(l=o/r)?1:l,c=1{let[t,i,n]=e,r=y($(0,.5),T(t,i)),o=y($(.5,1),T(i,n));return e=>(t>n?eh&&(h=g)}for(var p=Math.atan(n/(i*Math.tan(r))),m=1/0,_=-1/0,E=[o,s],d=-(2*Math.PI);d<=2*Math.PI;d+=Math.PI){var v=p+d;o_&&(_=C)}return{x:l,y:m,width:h-l,height:_-m}}function l(e,t,i,n){return o(e,t,i,n)}function h(e,t,i,n,r){return{x:(1-r)*e+r*i,y:(1-r)*t+r*n}}function u(e,t,i,n,r){var o=1-r;return o*o*o*e+3*t*r*o*o+3*i*r*r*o+n*r*r*r}function d(e,t,i,n){var o,s,a,l=-3*e+9*t-9*i+3*n,h=6*e-12*t+6*i,u=3*t-3*e,d=[];if((0,r.Z)(l,0))!(0,r.Z)(h,0)&&(o=-u/h)>=0&&o<=1&&d.push(o);else{var c=h*h-4*l*u;(0,r.Z)(c,0)?d.push(-h/(2*l)):c>0&&(o=(-h+(a=Math.sqrt(c)))/(2*l),s=(-h-a)/(2*l),o>=0&&o<=1&&d.push(o),s>=0&&s<=1&&d.push(s))}return d}function c(e,t,i,n,r,o,a,l){for(var h=[e,a],c=[t,l],f=d(e,i,r,a),g=d(t,n,o,l),p=0;p=0?[o]:[]}function m(e,t,i,n,r,o){var a=p(e,i,r)[0],l=p(t,n,o)[0],h=[e,r],u=[t,o];return void 0!==a&&h.push(g(e,i,r,a)),void 0!==l&&u.push(g(t,n,o,l)),s(h,u)}},53984:function(e,t){"use strict";t.Z=function(e,t,i){return ei?i:e}},47427:function(e,t,i){"use strict";var n=i(10410);t.Z=function(e){return Array.isArray?Array.isArray(e):(0,n.Z)(e,"Array")}},63725:function(e,t,i){"use strict";var n=i(10410);t.Z=function(e){return(0,n.Z)(e,"Boolean")}},37377:function(e,t){"use strict";t.Z=function(e){return null==e}},76703:function(e,t,i){"use strict";function n(e,t,i){return void 0===i&&(i=1e-5),Math.abs(e-t)1&&(v*=O=Math.sqrt(O),b*=O);var L=v*v,I=b*b,w=(s===l?-1:1)*Math.sqrt(Math.abs((L*I-L*N*N-I*A*A)/(L*N*N+I*A*A)));p=w*v*N/b+(_+C)/2,m=-(w*b)*A/v+(E+S)/2,f=Math.asin(((E-m)/b*1e9>>0)/1e9),g=Math.asin(((S-m)/b*1e9>>0)/1e9),f=_g&&(f-=2*Math.PI),!l&&g>f&&(g-=2*Math.PI)}var D=g-f;if(Math.abs(D)>y){var x=g,M=C,k=S;R=e(C=p+v*Math.cos(g=f+y*(l&&g>f?1:-1)),S=m+b*Math.sin(g),v,b,o,0,l,M,k,[g,x,p,m])}D=g-f;var P=Math.cos(f),F=Math.cos(g),B=Math.tan(D/4),U=4/3*v*B,H=4/3*b*B,V=[_,E],W=[_+U*Math.sin(f),E-H*P],G=[C+U*Math.sin(g),S-H*F],j=[C,S];if(W[0]=2*V[0]-W[0],W[1]=2*V[1]-W[1],d)return W.concat(G,j,R);R=W.concat(G,j,R);for(var z=[],K=0,Y=R.length;K7){e[i].shift();for(var n=e[i],r=i;n.length;)t[i]="A",e.splice(r+=1,0,["C"].concat(n.splice(0,6)));e.splice(i,1)}}(d,f,_),p=d.length,"Z"===g&&m.push(_),l=(i=d[_]).length,c.x1=+i[l-2],c.y1=+i[l-1],c.x2=+i[l-4]||c.x1,c.y2=+i[l-3]||c.y1}return t?[d,m]:d}},63893:function(e,t,i){"use strict";i.d(t,{R:function(){return n}});var n={a:7,c:6,h:1,l:2,m:2,r:4,q:4,s:4,t:2,v:1,z:0}},54109:function(e,t,i){"use strict";i.d(t,{z:function(){return n}});var n={x1:0,y1:0,x2:0,y2:0,x:0,y:0,qx:null,qy:null}},8699:function(e,t,i){"use strict";function n(e){return e.map(function(e){return Array.isArray(e)?[].concat(e):e})}i.d(t,{U:function(){return n}})},28024:function(e,t,i){"use strict";i.d(t,{A:function(){return f}});var n=i(97582),r=i(12884),o=i(54109),s=i(41793),a=i(66141),l=i(63893);function h(e){for(var t=e.pathValue[e.segmentStart],i=t.toLowerCase(),n=e.data;n.length>=l.R[i]&&("m"===i&&n.length>2?(e.segments.push([t].concat(n.splice(0,2))),i="l",t="m"===t?"l":"L"):e.segments.push([t].concat(n.splice(0,l.R[i]))),l.R[i]););}function u(e){return e>=48&&e<=57}function d(e){for(var t,i=e.pathValue,n=e.max;e.index=5760&&[5760,6158,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8239,8287,12288,65279].includes(t));)e.index+=1}var c=function(e){this.pathValue=e,this.segments=[],this.max=e.length,this.index=0,this.param=0,this.segmentStart=0,this.data=[],this.err=""};function f(e){if((0,r.y)(e))return[].concat(e);for(var t=function(e){if((0,s.b)(e))return[].concat(e);var t=function(e){if((0,a.n)(e))return[].concat(e);var t=new c(e);for(d(t);t.index0;a-=1){if((32|r)==97&&(3===a||4===a)?function(e){var t=e.index,i=e.pathValue,n=i.charCodeAt(t);if(48===n){e.param=0,e.index+=1;return}if(49===n){e.param=1,e.index+=1;return}e.err='[path-util]: invalid Arc flag "'+i[t]+'", expecting 0 or 1 at index '+t}(e):function(e){var t,i=e.max,n=e.pathValue,r=e.index,o=r,s=!1,a=!1,l=!1,h=!1;if(o>=i){e.err="[path-util]: Invalid path value at index "+o+', "pathValue" is missing param';return}if((43===(t=n.charCodeAt(o))||45===t)&&(o+=1,t=n.charCodeAt(o)),!u(t)&&46!==t){e.err="[path-util]: Invalid path value at index "+o+', "'+n[o]+'" is not a number';return}if(46!==t){if(s=48===t,o+=1,t=n.charCodeAt(o),s&&o=e.max||!((s=i.charCodeAt(e.index))>=48&&s<=57||43===s||45===s||46===s))break}h(e)}(t);return t.err?t.err:t.segments}(e),i=0,n=0,r=0,o=0;return t.map(function(e){var t,s=e.slice(1).map(Number),a=e[0],l=a.toUpperCase();if("M"===a)return i=s[0],n=s[1],r=i,o=n,["M",i,n];if(a!==l)switch(l){case"A":t=[l,s[0],s[1],s[2],s[3],s[4],s[5]+i,s[6]+n];break;case"V":t=[l,s[0]+n];break;case"H":t=[l,s[0]+i];break;default:t=[l].concat(s.map(function(e,t){return e+(t%2?n:i)}))}else t=[l].concat(s);var h=t.length;switch(l){case"Z":i=r,n=o;break;case"H":i=t[1];break;case"V":n=t[1];break;default:i=t[h-2],n=t[h-1],"M"===l&&(r=i,o=n)}return t})}(e),i=(0,n.pi)({},o.z),f=0;f=g[t],p[t]-=m?1:0,m?e.ss:[e.s]}).flat()});return _[0].length===_[1].length?_:e(_[0],_[1],f)}}});var n=i(47852),r=i(31427);function o(e){return e.map(function(e,t,i){var o,s,a,l,h,u,d,c,f,g,p,m,_=t&&i[t-1].slice(-2).concat(e.slice(1)),E=t?(0,r.S)(_[0],_[1],_[2],_[3],_[4],_[5],_[6],_[7],_[8],{bbox:!1}).length:0;return m=t?E?(void 0===o&&(o=.5),s=_.slice(0,2),a=_.slice(2,4),l=_.slice(4,6),h=_.slice(6,8),u=(0,n.k)(s,a,o),d=(0,n.k)(a,l,o),c=(0,n.k)(l,h,o),f=(0,n.k)(u,d,o),g=(0,n.k)(d,c,o),p=(0,n.k)(f,g,o),[["C"].concat(u,f,p),["C"].concat(g,c,h)]):[e,e]:[e],{s:e,ss:m,l:E}})}},49958:function(e,t,i){"use strict";i.d(t,{b:function(){return r}});var n=i(75066);function r(e){var t,i,r;return t=0,i=0,r=0,(0,n.Y)(e).map(function(e){if("M"===e[0])return t=e[1],i=e[2],0;var n,o,s,a=e.slice(1),l=a[0],h=a[1],u=a[2],d=a[3],c=a[4],f=a[5];return o=t,r=3*((f-(s=i))*(l+u)-(c-o)*(h+d)+h*(o-u)-l*(s-d)+f*(u+o/3)-c*(d+s/3))/20,t=(n=e.slice(-2))[0],i=n[1],r}).reduce(function(e,t){return e+t},0)>=0}},80431:function(e,t,i){"use strict";i.d(t,{r:function(){return o}});var n=i(97582),r=i(12369);function o(e,t,i){return(0,r.s)(e,t,(0,n.pi)((0,n.pi)({},i),{bbox:!1,length:!0})).point}},88154:function(e,t,i){"use strict";i.d(t,{g:function(){return r}});var n=i(6393);function r(e,t){var i,r,o=e.length-1,s=[],a=0,l=(r=(i=e.length)-1,e.map(function(t,n){return e.map(function(t,o){var s=n+o;return 0===o||e[s]&&"M"===e[s][0]?["M"].concat(e[s].slice(-2)):(s>=i&&(s-=r),e[s])})}));return l.forEach(function(i,r){e.slice(1).forEach(function(i,s){a+=(0,n.y)(e[(r+s)%o].slice(-2),t[s%o].slice(-2))}),s[r]=a,a=0}),l[s.indexOf(Math.min.apply(null,s))]}},72888:function(e,t,i){"use strict";i.d(t,{D:function(){return o}});var n=i(97582),r=i(12369);function o(e,t){return(0,r.s)(e,void 0,(0,n.pi)((0,n.pi)({},t),{bbox:!1,length:!0})).length}},41793:function(e,t,i){"use strict";i.d(t,{b:function(){return r}});var n=i(66141);function r(e){return(0,n.n)(e)&&e.every(function(e){var t=e[0];return t===t.toUpperCase()})}},12884:function(e,t,i){"use strict";i.d(t,{y:function(){return r}});var n=i(41793);function r(e){return(0,n.b)(e)&&e.every(function(e){var t=e[0];return"ACLMQZ".includes(t)})}},66141:function(e,t,i){"use strict";i.d(t,{n:function(){return r}});var n=i(63893);function r(e){return Array.isArray(e)&&e.every(function(e){var t=e[0].toLowerCase();return n.R[t]===e.length-1&&"achlmqstvz".includes(t)})}},47852:function(e,t,i){"use strict";function n(e,t,i){var n=e[0],r=e[1];return[n+(t[0]-n)*i,r+(t[1]-r)*i]}i.d(t,{k:function(){return n}})},12369:function(e,t,i){"use strict";i.d(t,{s:function(){return h}});var n=i(28024),r=i(47852),o=i(6393);function s(e,t,i,n,s){var a=(0,o.y)([e,t],[i,n]),l={x:0,y:0};if("number"==typeof s){if(s<=0)l={x:e,y:t};else if(s>=a)l={x:i,y:n};else{var h=(0,r.k)([e,t],[i,n],s/a);l={x:h[0],y:h[1]}}}return{length:a,point:l,min:{x:Math.min(e,i),y:Math.min(t,n)},max:{x:Math.max(e,i),y:Math.max(t,n)}}}function a(e,t){var i=e.x,n=e.y,r=t.x,o=t.y,s=Math.sqrt((Math.pow(i,2)+Math.pow(n,2))*(Math.pow(r,2)+Math.pow(o,2)));return(i*o-n*r<0?-1:1)*Math.acos((i*r+n*o)/s)}var l=i(31427);function h(e,t,i){for(var r,h,u,d,c,f,g,p,m,_=(0,n.A)(e),E="number"==typeof t,v=[],b=0,C=0,S=0,y=0,T=[],R=[],A=0,N={x:0,y:0},O=N,L=N,I=N,w=0,D=0,x=_.length;D1&&(_*=p(y),E*=p(y));var T=(Math.pow(_,2)*Math.pow(E,2)-Math.pow(_,2)*Math.pow(S.y,2)-Math.pow(E,2)*Math.pow(S.x,2))/(Math.pow(_,2)*Math.pow(S.y,2)+Math.pow(E,2)*Math.pow(S.x,2)),R=(o!==l?1:-1)*p(T=T<0?0:T),A={x:R*(_*S.y/E),y:R*(-(E*S.x)/_)},N={x:g(v)*A.x-f(v)*A.y+(e+h)/2,y:f(v)*A.x+g(v)*A.y+(t+u)/2},O={x:(S.x-A.x)/_,y:(S.y-A.y)/E},L=a({x:1,y:0},O),I=a(O,{x:(-S.x-A.x)/_,y:(-S.y-A.y)/E});!l&&I>0?I-=2*m:l&&I<0&&(I+=2*m);var w=L+(I%=2*m)*d,D=_*g(w),x=E*f(w);return{x:g(v)*D-f(v)*x+N.x,y:f(v)*D+g(v)*x+N.y}}(e,t,i,n,r,l,h,u,d,L/b)).x,y=g.y,m&&O.push({x:S,y:y}),E&&(T+=(0,o.y)(A,[S,y])),A=[S,y],C&&T>=c&&c>R[2]){var I=(T-c)/(T-R[2]);N={x:A[0]*(1-I)+R[0]*I,y:A[1]*(1-I)+R[1]*I}}R=[S,y,T]}return C&&c>=T&&(N={x:u,y:d}),{length:T,point:N,min:{x:Math.min.apply(null,O.map(function(e){return e.x})),y:Math.min.apply(null,O.map(function(e){return e.y}))},max:{x:Math.max.apply(null,O.map(function(e){return e.x})),y:Math.max.apply(null,O.map(function(e){return e.y}))}}}(v[0],v[1],v[2],v[3],v[4],v[5],v[6],v[7],v[8],(t||0)-w,i||{})).length,N=h.min,O=h.max,L=h.point):"C"===p?(A=(u=(0,l.S)(v[0],v[1],v[2],v[3],v[4],v[5],v[6],v[7],(t||0)-w,i||{})).length,N=u.min,O=u.max,L=u.point):"Q"===p?(A=(d=function(e,t,i,n,r,s,a,l){var h,u=l.bbox,d=void 0===u||u,c=l.length,f=void 0===c||c,g=l.sampleSize,p=void 0===g?10:g,m="number"==typeof a,_=e,E=t,v=0,b=[_,E,0],C=[_,E],S={x:0,y:0},y=[{x:_,y:E}];m&&a<=0&&(S={x:_,y:E});for(var T=0;T<=p;T+=1){if(_=(h=function(e,t,i,n,r,o,s){var a=1-s;return{x:Math.pow(a,2)*e+2*a*s*i+Math.pow(s,2)*r,y:Math.pow(a,2)*t+2*a*s*n+Math.pow(s,2)*o}}(e,t,i,n,r,s,T/p)).x,E=h.y,d&&y.push({x:_,y:E}),f&&(v+=(0,o.y)(C,[_,E])),C=[_,E],m&&v>=a&&a>b[2]){var R=(v-a)/(v-b[2]);S={x:C[0]*(1-R)+b[0]*R,y:C[1]*(1-R)+b[1]*R}}b=[_,E,v]}return m&&a>=v&&(S={x:r,y:s}),{length:v,point:S,min:{x:Math.min.apply(null,y.map(function(e){return e.x})),y:Math.min.apply(null,y.map(function(e){return e.y}))},max:{x:Math.max.apply(null,y.map(function(e){return e.x})),y:Math.max.apply(null,y.map(function(e){return e.y}))}}}(v[0],v[1],v[2],v[3],v[4],v[5],(t||0)-w,i||{})).length,N=d.min,O=d.max,L=d.point):"Z"===p&&(A=(c=s((v=[b,C,S,y])[0],v[1],v[2],v[3],(t||0)-w)).length,N=c.min,O=c.max,L=c.point),E&&w=t&&(I=L),R.push(O),T.push(N),w+=A,b=(f="Z"!==p?m.slice(-2):[S,y])[0],C=f[1];return E&&t>=w&&(I={x:b,y:C}),{length:w,point:I,min:{x:Math.min.apply(null,T.map(function(e){return e.x})),y:Math.min.apply(null,T.map(function(e){return e.y}))},max:{x:Math.max.apply(null,R.map(function(e){return e.x})),y:Math.max.apply(null,R.map(function(e){return e.y}))}}}},31427:function(e,t,i){"use strict";i.d(t,{S:function(){return r}});var n=i(6393);function r(e,t,i,r,o,s,a,l,h,u){var d,c=u.bbox,f=void 0===c||c,g=u.length,p=void 0===g||g,m=u.sampleSize,_=void 0===m?10:m,E="number"==typeof h,v=e,b=t,C=0,S=[v,b,0],y=[v,b],T={x:0,y:0},R=[{x:v,y:b}];E&&h<=0&&(T={x:v,y:b});for(var A=0;A<=_;A+=1){if(v=(d=function(e,t,i,n,r,o,s,a,l){var h=1-l;return{x:Math.pow(h,3)*e+3*Math.pow(h,2)*l*i+3*h*Math.pow(l,2)*r+Math.pow(l,3)*s,y:Math.pow(h,3)*t+3*Math.pow(h,2)*l*n+3*h*Math.pow(l,2)*o+Math.pow(l,3)*a}}(e,t,i,r,o,s,a,l,A/_)).x,b=d.y,f&&R.push({x:v,y:b}),p&&(C+=(0,n.y)(y,[v,b])),y=[v,b],E&&C>=h&&h>S[2]){var N=(C-h)/(C-S[2]);T={x:y[0]*(1-N)+S[0]*N,y:y[1]*(1-N)+S[1]*N}}S=[v,b,C]}return E&&h>=C&&(T={x:a,y:l}),{length:C,point:T,min:{x:Math.min.apply(null,R.map(function(e){return e.x})),y:Math.min.apply(null,R.map(function(e){return e.y}))},max:{x:Math.max.apply(null,R.map(function(e){return e.x})),y:Math.max.apply(null,R.map(function(e){return e.y}))}}}},33439:function(e,t,i){"use strict";function n(e,t,i){e.prototype=t.prototype=i,i.constructor=e}function r(e,t){var i=Object.create(e.prototype);for(var n in t)i[n]=t[n];return i}function o(){}i.d(t,{ZP:function(){return v}});var s="\\s*([+-]?\\d+)\\s*",a="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)\\s*",l="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)%\\s*",h=/^#([0-9a-f]{3,8})$/,u=RegExp("^rgb\\("+[s,s,s]+"\\)$"),d=RegExp("^rgb\\("+[l,l,l]+"\\)$"),c=RegExp("^rgba\\("+[s,s,s,a]+"\\)$"),f=RegExp("^rgba\\("+[l,l,l,a]+"\\)$"),g=RegExp("^hsl\\("+[a,l,l]+"\\)$"),p=RegExp("^hsla\\("+[a,l,l,a]+"\\)$"),m={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function _(){return this.rgb().formatHex()}function E(){return this.rgb().formatRgb()}function v(e){var t,i;return e=(e+"").trim().toLowerCase(),(t=h.exec(e))?(i=t[1].length,t=parseInt(t[1],16),6===i?b(t):3===i?new S(t>>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):8===i?C(t>>24&255,t>>16&255,t>>8&255,(255&t)/255):4===i?C(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|240&t,((15&t)<<4|15&t)/255):null):(t=u.exec(e))?new S(t[1],t[2],t[3],1):(t=d.exec(e))?new S(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=c.exec(e))?C(t[1],t[2],t[3],t[4]):(t=f.exec(e))?C(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=g.exec(e))?A(t[1],t[2]/100,t[3]/100,1):(t=p.exec(e))?A(t[1],t[2]/100,t[3]/100,t[4]):m.hasOwnProperty(e)?b(m[e]):"transparent"===e?new S(NaN,NaN,NaN,0):null}function b(e){return new S(e>>16&255,e>>8&255,255&e,1)}function C(e,t,i,n){return n<=0&&(e=t=i=NaN),new S(e,t,i,n)}function S(e,t,i,n){this.r=+e,this.g=+t,this.b=+i,this.opacity=+n}function y(){return"#"+R(this.r)+R(this.g)+R(this.b)}function T(){var e=this.opacity;return(1===(e=isNaN(e)?1:Math.max(0,Math.min(1,e)))?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(1===e?")":", "+e+")")}function R(e){return((e=Math.max(0,Math.min(255,Math.round(e)||0)))<16?"0":"")+e.toString(16)}function A(e,t,i,n){return n<=0?e=t=i=NaN:i<=0||i>=1?e=t=NaN:t<=0&&(e=NaN),new O(e,t,i,n)}function N(e){if(e instanceof O)return new O(e.h,e.s,e.l,e.opacity);if(e instanceof o||(e=v(e)),!e)return new O;if(e instanceof O)return e;var t=(e=e.rgb()).r/255,i=e.g/255,n=e.b/255,r=Math.min(t,i,n),s=Math.max(t,i,n),a=NaN,l=s-r,h=(s+r)/2;return l?(a=t===s?(i-n)/l+(i0&&h<1?0:a,new O(a,l,h,e.opacity)}function O(e,t,i,n){this.h=+e,this.s=+t,this.l=+i,this.opacity=+n}function L(e,t,i){return(e<60?t+(i-t)*e/60:e<180?i:e<240?t+(i-t)*(240-e)/60:t)*255}n(o,v,{copy:function(e){return Object.assign(new this.constructor,this,e)},displayable:function(){return this.rgb().displayable()},hex:_,formatHex:_,formatHsl:function(){return N(this).formatHsl()},formatRgb:E,toString:E}),n(S,function(e,t,i,n){var r;return 1==arguments.length?((r=e)instanceof o||(r=v(r)),r)?(r=r.rgb(),new S(r.r,r.g,r.b,r.opacity)):new S:new S(e,t,i,null==n?1:n)},r(o,{brighter:function(e){return e=null==e?1.4285714285714286:Math.pow(1.4285714285714286,e),new S(this.r*e,this.g*e,this.b*e,this.opacity)},darker:function(e){return e=null==e?.7:Math.pow(.7,e),new S(this.r*e,this.g*e,this.b*e,this.opacity)},rgb:function(){return this},displayable:function(){return -.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:y,formatHex:y,formatRgb:T,toString:T})),n(O,function(e,t,i,n){return 1==arguments.length?N(e):new O(e,t,i,null==n?1:n)},r(o,{brighter:function(e){return e=null==e?1.4285714285714286:Math.pow(1.4285714285714286,e),new O(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=null==e?.7:Math.pow(.7,e),new O(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,i=this.l,n=i+(i<.5?i:1-i)*t,r=2*i-n;return new S(L(e>=240?e-240:e+120,r,n),L(e,r,n),L(e<120?e+240:e-120,r,n),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl:function(){var e=this.opacity;return(1===(e=isNaN(e)?1:Math.max(0,Math.min(1,e)))?"hsl(":"hsla(")+(this.h||0)+", "+100*(this.s||0)+"%, "+100*(this.l||0)+"%"+(1===e?")":", "+e+")")}}))},53406:function(e,t,i){"use strict";i.d(t,{r:function(){return ew}});var n,r,o,s,a,l=i(87462),h=i(63366),u=i(67294),d=i(33703),c=i(73546),f=i(82690);function g(e){if(null==e)return window;if("[object Window]"!==e.toString()){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function p(e){var t=g(e).Element;return e instanceof t||e instanceof Element}function m(e){var t=g(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function _(e){if("undefined"==typeof ShadowRoot)return!1;var t=g(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}var E=Math.max,v=Math.min,b=Math.round;function C(){var e=navigator.userAgentData;return null!=e&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(e){return e.brand+"/"+e.version}).join(" "):navigator.userAgent}function S(){return!/^((?!chrome|android).)*safari/i.test(C())}function y(e,t,i){void 0===t&&(t=!1),void 0===i&&(i=!1);var n=e.getBoundingClientRect(),r=1,o=1;t&&m(e)&&(r=e.offsetWidth>0&&b(n.width)/e.offsetWidth||1,o=e.offsetHeight>0&&b(n.height)/e.offsetHeight||1);var s=(p(e)?g(e):window).visualViewport,a=!S()&&i,l=(n.left+(a&&s?s.offsetLeft:0))/r,h=(n.top+(a&&s?s.offsetTop:0))/o,u=n.width/r,d=n.height/o;return{width:u,height:d,top:h,right:l+u,bottom:h+d,left:l,x:l,y:h}}function T(e){var t=g(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function R(e){return e?(e.nodeName||"").toLowerCase():null}function A(e){return((p(e)?e.ownerDocument:e.document)||window.document).documentElement}function N(e){return y(A(e)).left+T(e).scrollLeft}function O(e){return g(e).getComputedStyle(e)}function L(e){var t=O(e),i=t.overflow,n=t.overflowX,r=t.overflowY;return/auto|scroll|overlay|hidden/.test(i+r+n)}function I(e){var t=y(e),i=e.offsetWidth,n=e.offsetHeight;return 1>=Math.abs(t.width-i)&&(i=t.width),1>=Math.abs(t.height-n)&&(n=t.height),{x:e.offsetLeft,y:e.offsetTop,width:i,height:n}}function w(e){return"html"===R(e)?e:e.assignedSlot||e.parentNode||(_(e)?e.host:null)||A(e)}function D(e,t){void 0===t&&(t=[]);var i,n=function e(t){return["html","body","#document"].indexOf(R(t))>=0?t.ownerDocument.body:m(t)&&L(t)?t:e(w(t))}(e),r=n===(null==(i=e.ownerDocument)?void 0:i.body),o=g(n),s=r?[o].concat(o.visualViewport||[],L(n)?n:[]):n,a=t.concat(s);return r?a:a.concat(D(w(s)))}function x(e){return m(e)&&"fixed"!==O(e).position?e.offsetParent:null}function M(e){for(var t=g(e),i=x(e);i&&["table","td","th"].indexOf(R(i))>=0&&"static"===O(i).position;)i=x(i);return i&&("html"===R(i)||"body"===R(i)&&"static"===O(i).position)?t:i||function(e){var t=/firefox/i.test(C());if(/Trident/i.test(C())&&m(e)&&"fixed"===O(e).position)return null;var i=w(e);for(_(i)&&(i=i.host);m(i)&&0>["html","body"].indexOf(R(i));){var n=O(i);if("none"!==n.transform||"none"!==n.perspective||"paint"===n.contain||-1!==["transform","perspective"].indexOf(n.willChange)||t&&"filter"===n.willChange||t&&n.filter&&"none"!==n.filter)return i;i=i.parentNode}return null}(e)||t}var k="bottom",P="right",F="left",B="auto",U=["top",k,P,F],H="start",V="viewport",W="popper",G=U.reduce(function(e,t){return e.concat([t+"-"+H,t+"-end"])},[]),j=[].concat(U,[B]).reduce(function(e,t){return e.concat([t,t+"-"+H,t+"-end"])},[]),z=["beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite"],K={placement:"bottom",modifiers:[],strategy:"absolute"};function Y(){for(var e=arguments.length,t=Array(e),i=0;i=0?"x":"y"}function Q(e){var t,i=e.reference,n=e.element,r=e.placement,o=r?q(r):null,s=r?X(r):null,a=i.x+i.width/2-n.width/2,l=i.y+i.height/2-n.height/2;switch(o){case"top":t={x:a,y:i.y-n.height};break;case k:t={x:a,y:i.y+i.height};break;case P:t={x:i.x+i.width,y:l};break;case F:t={x:i.x-n.width,y:l};break;default:t={x:i.x,y:i.y}}var h=o?Z(o):null;if(null!=h){var u="y"===h?"height":"width";switch(s){case H:t[h]=t[h]-(i[u]/2-n[u]/2);break;case"end":t[h]=t[h]+(i[u]/2-n[u]/2)}}return t}var J={top:"auto",right:"auto",bottom:"auto",left:"auto"};function ee(e){var t,i,n,r,o,s,a,l=e.popper,h=e.popperRect,u=e.placement,d=e.variation,c=e.offsets,f=e.position,p=e.gpuAcceleration,m=e.adaptive,_=e.roundOffsets,E=e.isFixed,v=c.x,C=void 0===v?0:v,S=c.y,y=void 0===S?0:S,T="function"==typeof _?_({x:C,y:y}):{x:C,y:y};C=T.x,y=T.y;var R=c.hasOwnProperty("x"),N=c.hasOwnProperty("y"),L=F,I="top",w=window;if(m){var D=M(l),x="clientHeight",B="clientWidth";D===g(l)&&"static"!==O(D=A(l)).position&&"absolute"===f&&(x="scrollHeight",B="scrollWidth"),("top"===u||(u===F||u===P)&&"end"===d)&&(I=k,y-=(E&&D===w&&w.visualViewport?w.visualViewport.height:D[x])-h.height,y*=p?1:-1),(u===F||("top"===u||u===k)&&"end"===d)&&(L=P,C-=(E&&D===w&&w.visualViewport?w.visualViewport.width:D[B])-h.width,C*=p?1:-1)}var U=Object.assign({position:f},m&&J),H=!0===_?(t={x:C,y:y},i=g(l),n=t.x,r=t.y,{x:b(n*(o=i.devicePixelRatio||1))/o||0,y:b(r*o)/o||0}):{x:C,y:y};return(C=H.x,y=H.y,p)?Object.assign({},U,((a={})[I]=N?"0":"",a[L]=R?"0":"",a.transform=1>=(w.devicePixelRatio||1)?"translate("+C+"px, "+y+"px)":"translate3d("+C+"px, "+y+"px, 0)",a)):Object.assign({},U,((s={})[I]=N?y+"px":"",s[L]=R?C+"px":"",s.transform="",s))}var et={left:"right",right:"left",bottom:"top",top:"bottom"};function ei(e){return e.replace(/left|right|bottom|top/g,function(e){return et[e]})}var en={start:"end",end:"start"};function er(e){return e.replace(/start|end/g,function(e){return en[e]})}function eo(e,t){var i=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(i&&_(i)){var n=t;do{if(n&&e.isSameNode(n))return!0;n=n.parentNode||n.host}while(n)}return!1}function es(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function ea(e,t,i){var n,r,o,s,a,l,h,u,d,c;return t===V?es(function(e,t){var i=g(e),n=A(e),r=i.visualViewport,o=n.clientWidth,s=n.clientHeight,a=0,l=0;if(r){o=r.width,s=r.height;var h=S();(h||!h&&"fixed"===t)&&(a=r.offsetLeft,l=r.offsetTop)}return{width:o,height:s,x:a+N(e),y:l}}(e,i)):p(t)?((n=y(t,!1,"fixed"===i)).top=n.top+t.clientTop,n.left=n.left+t.clientLeft,n.bottom=n.top+t.clientHeight,n.right=n.left+t.clientWidth,n.width=t.clientWidth,n.height=t.clientHeight,n.x=n.left,n.y=n.top,n):es((r=A(e),s=A(r),a=T(r),l=null==(o=r.ownerDocument)?void 0:o.body,h=E(s.scrollWidth,s.clientWidth,l?l.scrollWidth:0,l?l.clientWidth:0),u=E(s.scrollHeight,s.clientHeight,l?l.scrollHeight:0,l?l.clientHeight:0),d=-a.scrollLeft+N(r),c=-a.scrollTop,"rtl"===O(l||s).direction&&(d+=E(s.clientWidth,l?l.clientWidth:0)-h),{width:h,height:u,x:d,y:c}))}function el(){return{top:0,right:0,bottom:0,left:0}}function eh(e){return Object.assign({},el(),e)}function eu(e,t){return t.reduce(function(t,i){return t[i]=e,t},{})}function ed(e,t){void 0===t&&(t={});var i,n,r,o,s,a,l,h=t,u=h.placement,d=void 0===u?e.placement:u,c=h.strategy,f=void 0===c?e.strategy:c,g=h.boundary,_=h.rootBoundary,b=h.elementContext,C=void 0===b?W:b,S=h.altBoundary,T=h.padding,N=void 0===T?0:T,L=eh("number"!=typeof N?N:eu(N,U)),I=e.rects.popper,x=e.elements[void 0!==S&&S?C===W?"reference":W:C],F=(i=p(x)?x:x.contextElement||A(e.elements.popper),a=(s=[].concat("clippingParents"===(n=void 0===g?"clippingParents":g)?(r=D(w(i)),p(o=["absolute","fixed"].indexOf(O(i).position)>=0&&m(i)?M(i):i)?r.filter(function(e){return p(e)&&eo(e,o)&&"body"!==R(e)}):[]):[].concat(n),[void 0===_?V:_]))[0],(l=s.reduce(function(e,t){var n=ea(i,t,f);return e.top=E(n.top,e.top),e.right=v(n.right,e.right),e.bottom=v(n.bottom,e.bottom),e.left=E(n.left,e.left),e},ea(i,a,f))).width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l),B=y(e.elements.reference),H=Q({reference:B,element:I,strategy:"absolute",placement:d}),G=es(Object.assign({},I,H)),j=C===W?G:B,z={top:F.top-j.top+L.top,bottom:j.bottom-F.bottom+L.bottom,left:F.left-j.left+L.left,right:j.right-F.right+L.right},K=e.modifiersData.offset;if(C===W&&K){var Y=K[d];Object.keys(z).forEach(function(e){var t=[P,k].indexOf(e)>=0?1:-1,i=["top",k].indexOf(e)>=0?"y":"x";z[e]+=Y[i]*t})}return z}function ec(e,t,i){return E(e,v(t,i))}function ef(e,t,i){return void 0===i&&(i={x:0,y:0}),{top:e.top-t.height-i.y,right:e.right-t.width+i.x,bottom:e.bottom-t.height+i.y,left:e.left-t.width-i.x}}function eg(e){return["top",P,k,F].some(function(t){return e[t]>=0})}var ep=(o=void 0===(r=(n={defaultModifiers:[{name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:function(e){var t=e.state,i=e.instance,n=e.options,r=n.scroll,o=void 0===r||r,s=n.resize,a=void 0===s||s,l=g(t.elements.popper),h=[].concat(t.scrollParents.reference,t.scrollParents.popper);return o&&h.forEach(function(e){e.addEventListener("scroll",i.update,$)}),a&&l.addEventListener("resize",i.update,$),function(){o&&h.forEach(function(e){e.removeEventListener("scroll",i.update,$)}),a&&l.removeEventListener("resize",i.update,$)}},data:{}},{name:"popperOffsets",enabled:!0,phase:"read",fn:function(e){var t=e.state,i=e.name;t.modifiersData[i]=Q({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})},data:{}},{name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:function(e){var t=e.state,i=e.options,n=i.gpuAcceleration,r=i.adaptive,o=i.roundOffsets,s=void 0===o||o,a={placement:q(t.placement),variation:X(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:void 0===n||n,isFixed:"fixed"===t.options.strategy};null!=t.modifiersData.popperOffsets&&(t.styles.popper=Object.assign({},t.styles.popper,ee(Object.assign({},a,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:void 0===r||r,roundOffsets:s})))),null!=t.modifiersData.arrow&&(t.styles.arrow=Object.assign({},t.styles.arrow,ee(Object.assign({},a,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:s})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})},data:{}},{name:"applyStyles",enabled:!0,phase:"write",fn:function(e){var t=e.state;Object.keys(t.elements).forEach(function(e){var i=t.styles[e]||{},n=t.attributes[e]||{},r=t.elements[e];m(r)&&R(r)&&(Object.assign(r.style,i),Object.keys(n).forEach(function(e){var t=n[e];!1===t?r.removeAttribute(e):r.setAttribute(e,!0===t?"":t)}))})},effect:function(e){var t=e.state,i={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,i.popper),t.styles=i,t.elements.arrow&&Object.assign(t.elements.arrow.style,i.arrow),function(){Object.keys(t.elements).forEach(function(e){var n=t.elements[e],r=t.attributes[e]||{},o=Object.keys(t.styles.hasOwnProperty(e)?t.styles[e]:i[e]).reduce(function(e,t){return e[t]="",e},{});m(n)&&R(n)&&(Object.assign(n.style,o),Object.keys(r).forEach(function(e){n.removeAttribute(e)}))})}},requires:["computeStyles"]},{name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:function(e){var t=e.state,i=e.options,n=e.name,r=i.offset,o=void 0===r?[0,0]:r,s=j.reduce(function(e,i){var n,r,s,a,l,h;return e[i]=(n=t.rects,s=[F,"top"].indexOf(r=q(i))>=0?-1:1,l=(a="function"==typeof o?o(Object.assign({},n,{placement:i})):o)[0],h=a[1],l=l||0,h=(h||0)*s,[F,P].indexOf(r)>=0?{x:h,y:l}:{x:l,y:h}),e},{}),a=s[t.placement],l=a.x,h=a.y;null!=t.modifiersData.popperOffsets&&(t.modifiersData.popperOffsets.x+=l,t.modifiersData.popperOffsets.y+=h),t.modifiersData[n]=s}},{name:"flip",enabled:!0,phase:"main",fn:function(e){var t=e.state,i=e.options,n=e.name;if(!t.modifiersData[n]._skip){for(var r=i.mainAxis,o=void 0===r||r,s=i.altAxis,a=void 0===s||s,l=i.fallbackPlacements,h=i.padding,u=i.boundary,d=i.rootBoundary,c=i.altBoundary,f=i.flipVariations,g=void 0===f||f,p=i.allowedAutoPlacements,m=t.options.placement,_=q(m)===m,E=l||(_||!g?[ei(m)]:function(e){if(q(e)===B)return[];var t=ei(e);return[er(e),t,er(t)]}(m)),v=[m].concat(E).reduce(function(e,i){var n,r,o,s,a,l,c,f,m,_,E,v;return e.concat(q(i)===B?(r=(n={placement:i,boundary:u,rootBoundary:d,padding:h,flipVariations:g,allowedAutoPlacements:p}).placement,o=n.boundary,s=n.rootBoundary,a=n.padding,l=n.flipVariations,f=void 0===(c=n.allowedAutoPlacements)?j:c,0===(E=(_=(m=X(r))?l?G:G.filter(function(e){return X(e)===m}):U).filter(function(e){return f.indexOf(e)>=0})).length&&(E=_),Object.keys(v=E.reduce(function(e,i){return e[i]=ed(t,{placement:i,boundary:o,rootBoundary:s,padding:a})[q(i)],e},{})).sort(function(e,t){return v[e]-v[t]})):i)},[]),b=t.rects.reference,C=t.rects.popper,S=new Map,y=!0,T=v[0],R=0;R=0,I=L?"width":"height",w=ed(t,{placement:A,boundary:u,rootBoundary:d,altBoundary:c,padding:h}),D=L?O?P:F:O?k:"top";b[I]>C[I]&&(D=ei(D));var x=ei(D),M=[];if(o&&M.push(w[N]<=0),a&&M.push(w[D]<=0,w[x]<=0),M.every(function(e){return e})){T=A,y=!1;break}S.set(A,M)}if(y)for(var V=g?3:1,W=function(e){var t=v.find(function(t){var i=S.get(t);if(i)return i.slice(0,e).every(function(e){return e})});if(t)return T=t,"break"},z=V;z>0&&"break"!==W(z);z--);t.placement!==T&&(t.modifiersData[n]._skip=!0,t.placement=T,t.reset=!0)}},requiresIfExists:["offset"],data:{_skip:!1}},{name:"preventOverflow",enabled:!0,phase:"main",fn:function(e){var t=e.state,i=e.options,n=e.name,r=i.mainAxis,o=i.altAxis,s=i.boundary,a=i.rootBoundary,l=i.altBoundary,h=i.padding,u=i.tether,d=void 0===u||u,c=i.tetherOffset,f=void 0===c?0:c,g=ed(t,{boundary:s,rootBoundary:a,padding:h,altBoundary:l}),p=q(t.placement),m=X(t.placement),_=!m,b=Z(p),C="x"===b?"y":"x",S=t.modifiersData.popperOffsets,y=t.rects.reference,T=t.rects.popper,R="function"==typeof f?f(Object.assign({},t.rects,{placement:t.placement})):f,A="number"==typeof R?{mainAxis:R,altAxis:R}:Object.assign({mainAxis:0,altAxis:0},R),N=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,O={x:0,y:0};if(S){if(void 0===r||r){var L,w="y"===b?"top":F,D="y"===b?k:P,x="y"===b?"height":"width",B=S[b],U=B+g[w],V=B-g[D],W=d?-T[x]/2:0,G=m===H?y[x]:T[x],j=m===H?-T[x]:-y[x],z=t.elements.arrow,K=d&&z?I(z):{width:0,height:0},Y=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:el(),$=Y[w],Q=Y[D],J=ec(0,y[x],K[x]),ee=_?y[x]/2-W-J-$-A.mainAxis:G-J-$-A.mainAxis,et=_?-y[x]/2+W+J+Q+A.mainAxis:j+J+Q+A.mainAxis,ei=t.elements.arrow&&M(t.elements.arrow),en=ei?"y"===b?ei.clientTop||0:ei.clientLeft||0:0,er=null!=(L=null==N?void 0:N[b])?L:0,eo=B+ee-er-en,es=B+et-er,ea=ec(d?v(U,eo):U,B,d?E(V,es):V);S[b]=ea,O[b]=ea-B}if(void 0!==o&&o){var eh,eu,ef="x"===b?"top":F,eg="x"===b?k:P,ep=S[C],em="y"===C?"height":"width",e_=ep+g[ef],eE=ep-g[eg],ev=-1!==["top",F].indexOf(p),eb=null!=(eu=null==N?void 0:N[C])?eu:0,eC=ev?e_:ep-y[em]-T[em]-eb+A.altAxis,eS=ev?ep+y[em]+T[em]-eb-A.altAxis:eE,ey=d&&ev?(eh=ec(eC,ep,eS))>eS?eS:eh:ec(d?eC:e_,ep,d?eS:eE);S[C]=ey,O[C]=ey-ep}t.modifiersData[n]=O}},requiresIfExists:["offset"]},{name:"arrow",enabled:!0,phase:"main",fn:function(e){var t,i,n=e.state,r=e.name,o=e.options,s=n.elements.arrow,a=n.modifiersData.popperOffsets,l=q(n.placement),h=Z(l),u=[F,P].indexOf(l)>=0?"height":"width";if(s&&a){var d=eh("number"!=typeof(t="function"==typeof(t=o.padding)?t(Object.assign({},n.rects,{placement:n.placement})):t)?t:eu(t,U)),c=I(s),f="y"===h?"top":F,g="y"===h?k:P,p=n.rects.reference[u]+n.rects.reference[h]-a[h]-n.rects.popper[u],m=a[h]-n.rects.reference[h],_=M(s),E=_?"y"===h?_.clientHeight||0:_.clientWidth||0:0,v=d[f],b=E-c[u]-d[g],C=E/2-c[u]/2+(p/2-m/2),S=ec(v,C,b);n.modifiersData[r]=((i={})[h]=S,i.centerOffset=S-C,i)}},effect:function(e){var t=e.state,i=e.options.element,n=void 0===i?"[data-popper-arrow]":i;null!=n&&("string"!=typeof n||(n=t.elements.popper.querySelector(n)))&&eo(t.elements.popper,n)&&(t.elements.arrow=n)},requires:["popperOffsets"],requiresIfExists:["preventOverflow"]},{name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:function(e){var t=e.state,i=e.name,n=t.rects.reference,r=t.rects.popper,o=t.modifiersData.preventOverflow,s=ed(t,{elementContext:"reference"}),a=ed(t,{altBoundary:!0}),l=ef(s,n),h=ef(a,r,o),u=eg(l),d=eg(h);t.modifiersData[i]={referenceClippingOffsets:l,popperEscapeOffsets:h,isReferenceHidden:u,hasPopperEscaped:d},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":d})}}]}).defaultModifiers)?[]:r,a=void 0===(s=n.defaultOptions)?K:s,function(e,t,i){void 0===i&&(i=a);var n,r={placement:"bottom",orderedModifiers:[],options:Object.assign({},K,a),modifiersData:{},elements:{reference:e,popper:t},attributes:{},styles:{}},s=[],l=!1,h={state:r,setOptions:function(i){var n,l,d,c,f,g="function"==typeof i?i(r.options):i;u(),r.options=Object.assign({},a,r.options,g),r.scrollParents={reference:p(e)?D(e):e.contextElement?D(e.contextElement):[],popper:D(t)};var m=(l=Object.keys(n=[].concat(o,r.options.modifiers).reduce(function(e,t){var i=e[t.name];return e[t.name]=i?Object.assign({},i,t,{options:Object.assign({},i.options,t.options),data:Object.assign({},i.data,t.data)}):t,e},{})).map(function(e){return n[e]}),d=new Map,c=new Set,f=[],l.forEach(function(e){d.set(e.name,e)}),l.forEach(function(e){c.has(e.name)||function e(t){c.add(t.name),[].concat(t.requires||[],t.requiresIfExists||[]).forEach(function(t){if(!c.has(t)){var i=d.get(t);i&&e(i)}}),f.push(t)}(e)}),z.reduce(function(e,t){return e.concat(f.filter(function(e){return e.phase===t}))},[]));return r.orderedModifiers=m.filter(function(e){return e.enabled}),r.orderedModifiers.forEach(function(e){var t=e.name,i=e.options,n=e.effect;if("function"==typeof n){var o=n({state:r,name:t,instance:h,options:void 0===i?{}:i});s.push(o||function(){})}}),h.update()},forceUpdate:function(){if(!l){var e,t,i,n,o,s,a,u,d,c,f,p,_=r.elements,E=_.reference,v=_.popper;if(Y(E,v)){r.rects={reference:(t=M(v),i="fixed"===r.options.strategy,n=m(t),u=m(t)&&(s=b((o=t.getBoundingClientRect()).width)/t.offsetWidth||1,a=b(o.height)/t.offsetHeight||1,1!==s||1!==a),d=A(t),c=y(E,u,i),f={scrollLeft:0,scrollTop:0},p={x:0,y:0},(n||!n&&!i)&&(("body"!==R(t)||L(d))&&(f=(e=t)!==g(e)&&m(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:T(e)),m(t)?(p=y(t,!0),p.x+=t.clientLeft,p.y+=t.clientTop):d&&(p.x=N(d))),{x:c.left+f.scrollLeft-p.x,y:c.top+f.scrollTop-p.y,width:c.width,height:c.height}),popper:I(v)},r.reset=!1,r.placement=r.options.placement,r.orderedModifiers.forEach(function(e){return r.modifiersData[e.name]=Object.assign({},e.data)});for(var C=0;C{!r&&s(("function"==typeof n?n():n)||document.body)},[n,r]),(0,c.Z)(()=>{if(o&&!r)return(0,eE.Z)(t,o),()=>{(0,eE.Z)(t,null)}},[t,o,r]),r)?u.isValidElement(i)?u.cloneElement(i,{ref:a}):(0,ev.jsx)(u.Fragment,{children:i}):(0,ev.jsx)(u.Fragment,{children:o?e_.createPortal(i,o):o})});var eC=i(34867);function eS(e){return(0,eC.Z)("MuiPopper",e)}(0,i(1588).Z)("MuiPopper",["root"]);var ey=i(7293);let eT=u.createContext({disableDefaultClasses:!1}),eR=["anchorEl","children","direction","disablePortal","modifiers","open","placement","popperOptions","popperRef","slotProps","slots","TransitionProps","ownerState"],eA=["anchorEl","children","container","direction","disablePortal","keepMounted","modifiers","open","placement","popperOptions","popperRef","style","transition","slotProps","slots"];function eN(e){return"function"==typeof e?e():e}let eO=()=>(0,em.Z)({root:["root"]},function(e){let{disableDefaultClasses:t}=u.useContext(eT);return i=>t?"":e(i)}(eS)),eL={},eI=u.forwardRef(function(e,t){var i;let{anchorEl:n,children:r,direction:o,disablePortal:s,modifiers:a,open:f,placement:g,popperOptions:p,popperRef:m,slotProps:_={},slots:E={},TransitionProps:v}=e,b=(0,h.Z)(e,eR),C=u.useRef(null),S=(0,d.Z)(C,t),y=u.useRef(null),T=(0,d.Z)(y,m),R=u.useRef(T);(0,c.Z)(()=>{R.current=T},[T]),u.useImperativeHandle(m,()=>y.current,[]);let A=function(e,t){if("ltr"===t)return e;switch(e){case"bottom-end":return"bottom-start";case"bottom-start":return"bottom-end";case"top-end":return"top-start";case"top-start":return"top-end";default:return e}}(g,o),[N,O]=u.useState(A),[L,I]=u.useState(eN(n));u.useEffect(()=>{y.current&&y.current.forceUpdate()}),u.useEffect(()=>{n&&I(eN(n))},[n]),(0,c.Z)(()=>{if(!L||!f)return;let e=e=>{O(e.placement)},t=[{name:"preventOverflow",options:{altBoundary:s}},{name:"flip",options:{altBoundary:s}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:t})=>{e(t)}}];null!=a&&(t=t.concat(a)),p&&null!=p.modifiers&&(t=t.concat(p.modifiers));let i=ep(L,C.current,(0,l.Z)({placement:A},p,{modifiers:t}));return R.current(i),()=>{i.destroy(),R.current(null)}},[L,s,a,f,p,A]);let w={placement:N};null!==v&&(w.TransitionProps=v);let D=eO(),x=null!=(i=E.root)?i:"div",M=(0,ey.y)({elementType:x,externalSlotProps:_.root,externalForwardedProps:b,additionalProps:{role:"tooltip",ref:S},ownerState:e,className:D.root});return(0,ev.jsx)(x,(0,l.Z)({},M,{children:"function"==typeof r?r(w):r}))}),ew=u.forwardRef(function(e,t){let i;let{anchorEl:n,children:r,container:o,direction:s="ltr",disablePortal:a=!1,keepMounted:d=!1,modifiers:c,open:g,placement:p="bottom",popperOptions:m=eL,popperRef:_,style:E,transition:v=!1,slotProps:b={},slots:C={}}=e,S=(0,h.Z)(e,eA),[y,T]=u.useState(!0);if(!d&&!g&&(!v||y))return null;if(o)i=o;else if(n){let e=eN(n);i=e&&void 0!==e.nodeType?(0,f.Z)(e).body:(0,f.Z)(null).body}let R=!g&&d&&(!v||y)?"none":void 0;return(0,ev.jsx)(eb,{disablePortal:a,container:i,children:(0,ev.jsx)(eI,(0,l.Z)({anchorEl:n,direction:s,disablePortal:a,modifiers:c,ref:t,open:v?!y:g,placement:p,popperOptions:m,popperRef:_,slotProps:b,slots:C},S,{style:(0,l.Z)({position:"fixed",top:0,left:0,display:R},E),TransitionProps:v?{in:g,onEnter:()=>{T(!1)},onExited:()=>{T(!0)}}:void 0,children:r}))})})},70758:function(e,t,i){"use strict";i.d(t,{U:function(){return l}});var n=i(87462),r=i(67294),o=i(99962),s=i(33703),a=i(30437);function l(e={}){let{disabled:t=!1,focusableWhenDisabled:i,href:l,rootRef:h,tabIndex:u,to:d,type:c}=e,f=r.useRef(),[g,p]=r.useState(!1),{isFocusVisibleRef:m,onFocus:_,onBlur:E,ref:v}=(0,o.Z)(),[b,C]=r.useState(!1);t&&!i&&b&&C(!1),r.useEffect(()=>{m.current=b},[b,m]);let[S,y]=r.useState(""),T=e=>t=>{var i;b&&t.preventDefault(),null==(i=e.onMouseLeave)||i.call(e,t)},R=e=>t=>{var i;E(t),!1===m.current&&C(!1),null==(i=e.onBlur)||i.call(e,t)},A=e=>t=>{var i,n;f.current||(f.current=t.currentTarget),_(t),!0===m.current&&(C(!0),null==(n=e.onFocusVisible)||n.call(e,t)),null==(i=e.onFocus)||i.call(e,t)},N=()=>{let e=f.current;return"BUTTON"===S||"INPUT"===S&&["button","submit","reset"].includes(null==e?void 0:e.type)||"A"===S&&(null==e?void 0:e.href)},O=e=>i=>{if(!t){var n;null==(n=e.onClick)||n.call(e,i)}},L=e=>i=>{var n;t||(p(!0),document.addEventListener("mouseup",()=>{p(!1)},{once:!0})),null==(n=e.onMouseDown)||n.call(e,i)},I=e=>i=>{var n,r;null==(n=e.onKeyDown)||n.call(e,i),!i.defaultMuiPrevented&&(i.target!==i.currentTarget||N()||" "!==i.key||i.preventDefault(),i.target!==i.currentTarget||" "!==i.key||t||p(!0),i.target!==i.currentTarget||N()||"Enter"!==i.key||t||(null==(r=e.onClick)||r.call(e,i),i.preventDefault()))},w=e=>i=>{var n,r;i.target===i.currentTarget&&p(!1),null==(n=e.onKeyUp)||n.call(e,i),i.target!==i.currentTarget||N()||t||" "!==i.key||i.defaultMuiPrevented||null==(r=e.onClick)||r.call(e,i)},D=r.useCallback(e=>{var t;y(null!=(t=null==e?void 0:e.tagName)?t:"")},[]),x=(0,s.Z)(D,h,v,f),M={};return void 0!==u&&(M.tabIndex=u),"BUTTON"===S?(M.type=null!=c?c:"button",i?M["aria-disabled"]=t:M.disabled=t):""!==S&&(l||d||(M.role="button",M.tabIndex=null!=u?u:0),t&&(M["aria-disabled"]=t,M.tabIndex=i?null!=u?u:0:-1)),{getRootProps:(t={})=>{let i=(0,n.Z)({},(0,a._)(e),(0,a._)(t)),r=(0,n.Z)({type:c},i,M,t,{onBlur:R(i),onClick:O(i),onFocus:A(i),onKeyDown:I(i),onKeyUp:w(i),onMouseDown:L(i),onMouseLeave:T(i),ref:x});return delete r.onFocusVisible,r},focusVisible:b,setFocusVisible:C,active:g,rootRef:x}}},26558:function(e,t,i){"use strict";i.d(t,{Z:function(){return r}});var n=i(67294);let r=n.createContext(null)},22644:function(e,t,i){"use strict";i.d(t,{F:function(){return n}});let n={blur:"list:blur",focus:"list:focus",itemClick:"list:itemClick",itemHover:"list:itemHover",itemsChange:"list:itemsChange",keyDown:"list:keyDown",resetHighlight:"list:resetHighlight",textNavigation:"list:textNavigation"}},7333:function(e,t,i){"use strict";i.d(t,{R$:function(){return a},Rl:function(){return o}});var n=i(87462),r=i(22644);function o(e,t,i){var n;let r,o;let{items:s,isItemDisabled:a,disableListWrap:l,disabledItemsFocusable:h,itemComparer:u,focusManagement:d}=i,c=s.length-1,f=null==e?-1:s.findIndex(t=>u(t,e)),g=!l;switch(t){case"reset":if(-1==("DOM"===d?0:-1))return null;r=0,o="next",g=!1;break;case"start":r=0,o="next",g=!1;break;case"end":r=c,o="previous",g=!1;break;default:{let e=f+t;e<0?!g&&-1!==f||Math.abs(t)>1?(r=0,o="next"):(r=c,o="previous"):e>c?!g||Math.abs(t)>1?(r=c,o="previous"):(r=0,o="next"):(r=e,o=t>=0?"next":"previous")}}let p=function(e,t,i,n,r,o){if(0===i.length||!n&&i.every((e,t)=>r(e,t)))return -1;let s=e;for(;;){if(!o&&"next"===t&&s===i.length||!o&&"previous"===t&&-1===s)return -1;let e=!n&&r(i[s],s);if(!e)return s;s+="next"===t?1:-1,o&&(s=(s+i.length)%i.length)}}(r,o,s,h,a,g);return -1!==p||null===e||a(e,f)?null!=(n=s[p])?n:null:e}function s(e,t,i){let{itemComparer:r,isItemDisabled:o,selectionMode:s,items:a}=i,{selectedValues:l}=t,h=a.findIndex(t=>r(e,t));if(o(e,h))return t;let u="none"===s?[]:"single"===s?r(l[0],e)?l:[e]:l.some(t=>r(t,e))?l.filter(t=>!r(t,e)):[...l,e];return(0,n.Z)({},t,{selectedValues:u,highlightedValue:e})}function a(e,t){let{type:i,context:a}=t;switch(i){case r.F.keyDown:return function(e,t,i){let r=t.highlightedValue,{orientation:a,pageSize:l}=i;switch(e){case"Home":return(0,n.Z)({},t,{highlightedValue:o(r,"start",i)});case"End":return(0,n.Z)({},t,{highlightedValue:o(r,"end",i)});case"PageUp":return(0,n.Z)({},t,{highlightedValue:o(r,-l,i)});case"PageDown":return(0,n.Z)({},t,{highlightedValue:o(r,l,i)});case"ArrowUp":if("vertical"!==a)break;return(0,n.Z)({},t,{highlightedValue:o(r,-1,i)});case"ArrowDown":if("vertical"!==a)break;return(0,n.Z)({},t,{highlightedValue:o(r,1,i)});case"ArrowLeft":if("vertical"===a)break;return(0,n.Z)({},t,{highlightedValue:o(r,"horizontal-ltr"===a?-1:1,i)});case"ArrowRight":if("vertical"===a)break;return(0,n.Z)({},t,{highlightedValue:o(r,"horizontal-ltr"===a?1:-1,i)});case"Enter":case" ":if(null===t.highlightedValue)break;return s(t.highlightedValue,t,i)}return t}(t.key,e,a);case r.F.itemClick:return s(t.item,e,a);case r.F.blur:return"DOM"===a.focusManagement?e:(0,n.Z)({},e,{highlightedValue:null});case r.F.textNavigation:return function(e,t,i){let{items:r,isItemDisabled:s,disabledItemsFocusable:a,getItemAsString:l}=i,h=t.length>1,u=h?e.highlightedValue:o(e.highlightedValue,1,i);for(let d=0;dl(e,i.highlightedValue)))?a:null:"DOM"===h&&0===t.length&&(u=o(null,"reset",r));let d=null!=(s=i.selectedValues)?s:[],c=d.filter(t=>e.some(e=>l(e,t)));return(0,n.Z)({},i,{highlightedValue:u,selectedValues:c})}(t.items,t.previousItems,e,a);case r.F.resetHighlight:return(0,n.Z)({},e,{highlightedValue:o(null,"reset",a)});default:return e}}},96592:function(e,t,i){"use strict";i.d(t,{s:function(){return v}});var n=i(87462),r=i(67294),o=i(33703),s=i(22644),a=i(7333);let l="select:change-selection",h="select:change-highlight";var u=i(78031),d=i(6414);function c(e,t){let i=r.useRef(e);return r.useEffect(()=>{i.current=e},null!=t?t:[e]),i}let f={},g=()=>{},p=(e,t)=>e===t,m=()=>!1,_=e=>"string"==typeof e?e:String(e),E=()=>({highlightedValue:null,selectedValues:[]});function v(e){let{controlledProps:t=f,disabledItemsFocusable:i=!1,disableListWrap:v=!1,focusManagement:b="activeDescendant",getInitialState:C=E,getItemDomElement:S,getItemId:y,isItemDisabled:T=m,rootRef:R,onStateChange:A=g,items:N,itemComparer:O=p,getItemAsString:L=_,onChange:I,onHighlightChange:w,onItemsChange:D,orientation:x="vertical",pageSize:M=5,reducerActionContext:k=f,selectionMode:P="single",stateReducer:F}=e,B=r.useRef(null),U=(0,o.Z)(R,B),H=r.useCallback((e,t,i)=>{if(null==w||w(e,t,i),"DOM"===b&&null!=t&&(i===s.F.itemClick||i===s.F.keyDown||i===s.F.textNavigation)){var n;null==S||null==(n=S(t))||n.focus()}},[S,w,b]),V=r.useMemo(()=>({highlightedValue:O,selectedValues:(e,t)=>(0,d.H)(e,t,O)}),[O]),W=r.useCallback((e,t,i,n,r)=>{switch(null==A||A(e,t,i,n,r),t){case"highlightedValue":H(e,i,n);break;case"selectedValues":null==I||I(e,i,n)}},[H,I,A]),G=r.useMemo(()=>({disabledItemsFocusable:i,disableListWrap:v,focusManagement:b,isItemDisabled:T,itemComparer:O,items:N,getItemAsString:L,onHighlightChange:H,orientation:x,pageSize:M,selectionMode:P,stateComparers:V}),[i,v,b,T,O,N,L,H,x,M,P,V]),j=C(),z=null!=F?F:a.R$,K=r.useMemo(()=>(0,n.Z)({},k,G),[k,G]),[Y,$]=(0,u.r)({reducer:z,actionContext:K,initialState:j,controlledProps:t,stateComparers:V,onStateChange:W}),{highlightedValue:q,selectedValues:X}=Y,Z=function(e){let t=r.useRef({searchString:"",lastTime:null});return r.useCallback(i=>{if(1===i.key.length&&" "!==i.key){let n=t.current,r=i.key.toLowerCase(),o=performance.now();n.searchString.length>0&&n.lastTime&&o-n.lastTime>500?n.searchString=r:(1!==n.searchString.length||r!==n.searchString)&&(n.searchString+=r),n.lastTime=o,e(n.searchString,i)}},[e])}((e,t)=>$({type:s.F.textNavigation,event:t,searchString:e})),Q=c(X),J=c(q),ee=r.useRef([]);r.useEffect(()=>{(0,d.H)(ee.current,N,O)||($({type:s.F.itemsChange,event:null,items:N,previousItems:ee.current}),ee.current=N,null==D||D(N))},[N,O,$,D]);let{notifySelectionChanged:et,notifyHighlightChanged:ei,registerHighlightChangeHandler:en,registerSelectionChangeHandler:er}=function(){let e=function(){let e=r.useRef();return e.current||(e.current=function(){let e=new Map;return{subscribe:function(t,i){let n=e.get(t);return n?n.add(i):(n=new Set([i]),e.set(t,n)),()=>{n.delete(i),0===n.size&&e.delete(t)}},publish:function(t,...i){let n=e.get(t);n&&n.forEach(e=>e(...i))}}}()),e.current}(),t=r.useCallback(t=>{e.publish(l,t)},[e]),i=r.useCallback(t=>{e.publish(h,t)},[e]),n=r.useCallback(t=>e.subscribe(l,t),[e]),o=r.useCallback(t=>e.subscribe(h,t),[e]);return{notifySelectionChanged:t,notifyHighlightChanged:i,registerSelectionChangeHandler:n,registerHighlightChangeHandler:o}}();r.useEffect(()=>{et(X)},[X,et]),r.useEffect(()=>{ei(q)},[q,ei]);let eo=e=>t=>{var i;if(null==(i=e.onKeyDown)||i.call(e,t),t.defaultMuiPrevented)return;let n=["Home","End","PageUp","PageDown"];"vertical"===x?n.push("ArrowUp","ArrowDown"):n.push("ArrowLeft","ArrowRight"),"activeDescendant"===b&&n.push(" ","Enter"),n.includes(t.key)&&t.preventDefault(),$({type:s.F.keyDown,key:t.key,event:t}),Z(t)},es=e=>t=>{var i,n;null==(i=e.onBlur)||i.call(e,t),t.defaultMuiPrevented||null!=(n=B.current)&&n.contains(t.relatedTarget)||$({type:s.F.blur,event:t})},ea=r.useCallback(e=>{var t;let i=N.findIndex(t=>O(t,e)),n=(null!=(t=Q.current)?t:[]).some(t=>null!=t&&O(e,t)),r=T(e,i),o=null!=J.current&&O(e,J.current),s="DOM"===b;return{disabled:r,focusable:s,highlighted:o,index:i,selected:n}},[N,T,O,Q,J,b]),el=r.useMemo(()=>({dispatch:$,getItemState:ea,registerHighlightChangeHandler:en,registerSelectionChangeHandler:er}),[$,ea,en,er]);return r.useDebugValue({state:Y}),{contextValue:el,dispatch:$,getRootProps:(e={})=>(0,n.Z)({},e,{"aria-activedescendant":"activeDescendant"===b&&null!=q?y(q):void 0,onBlur:es(e),onKeyDown:eo(e),tabIndex:"DOM"===b?-1:0,ref:U}),rootRef:U,state:Y}}},43069:function(e,t,i){"use strict";i.d(t,{J:function(){return h}});var n=i(87462),r=i(67294),o=i(33703),s=i(73546),a=i(22644),l=i(26558);function h(e){let t;let{handlePointerOverEvents:i=!1,item:h,rootRef:u}=e,d=r.useRef(null),c=(0,o.Z)(d,u),f=r.useContext(l.Z);if(!f)throw Error("useListItem must be used within a ListProvider");let{dispatch:g,getItemState:p,registerHighlightChangeHandler:m,registerSelectionChangeHandler:_}=f,{highlighted:E,selected:v,focusable:b}=p(h),C=function(){let[,e]=r.useState({});return r.useCallback(()=>{e({})},[])}();(0,s.Z)(()=>m(function(e){e!==h||E?e!==h&&E&&C():C()})),(0,s.Z)(()=>_(function(e){v?e.includes(h)||C():e.includes(h)&&C()}),[_,C,v,h]);let S=r.useCallback(e=>t=>{var i;null==(i=e.onClick)||i.call(e,t),t.defaultPrevented||g({type:a.F.itemClick,item:h,event:t})},[g,h]),y=r.useCallback(e=>t=>{var i;null==(i=e.onMouseOver)||i.call(e,t),t.defaultPrevented||g({type:a.F.itemHover,item:h,event:t})},[g,h]);return b&&(t=E?0:-1),{getRootProps:(e={})=>(0,n.Z)({},e,{onClick:S(e),onPointerOver:i?y(e):void 0,ref:c,tabIndex:t}),highlighted:E,rootRef:c,selected:v}}},10238:function(e,t,i){"use strict";i.d(t,{$:function(){return o}});var n=i(87462),r=i(28442);function o(e,t,i){return void 0===e||(0,r.X)(e)?t:(0,n.Z)({},t,{ownerState:(0,n.Z)({},t.ownerState,i)})}},6414:function(e,t,i){"use strict";function n(e,t,i=(e,t)=>e===t){return e.length===t.length&&e.every((e,n)=>i(e,t[n]))}i.d(t,{H:function(){return n}})},2900:function(e,t,i){"use strict";i.d(t,{f:function(){return r}});var n=i(87462);function r(e,t){return function(i={}){let r=(0,n.Z)({},i,e(i)),o=(0,n.Z)({},r,t(r));return o}}},30437:function(e,t,i){"use strict";function n(e,t=[]){if(void 0===e)return{};let i={};return Object.keys(e).filter(i=>i.match(/^on[A-Z]/)&&"function"==typeof e[i]&&!t.includes(i)).forEach(t=>{i[t]=e[t]}),i}i.d(t,{_:function(){return n}})},28442:function(e,t,i){"use strict";function n(e){return"string"==typeof e}i.d(t,{X:function(){return n}})},24407:function(e,t,i){"use strict";i.d(t,{L:function(){return a}});var n=i(87462),r=i(90512),o=i(30437);function s(e){if(void 0===e)return{};let t={};return Object.keys(e).filter(t=>!(t.match(/^on[A-Z]/)&&"function"==typeof e[t])).forEach(i=>{t[i]=e[i]}),t}function a(e){let{getSlotProps:t,additionalProps:i,externalSlotProps:a,externalForwardedProps:l,className:h}=e;if(!t){let e=(0,r.Z)(null==l?void 0:l.className,null==a?void 0:a.className,h,null==i?void 0:i.className),t=(0,n.Z)({},null==i?void 0:i.style,null==l?void 0:l.style,null==a?void 0:a.style),o=(0,n.Z)({},i,l,a);return e.length>0&&(o.className=e),Object.keys(t).length>0&&(o.style=t),{props:o,internalRef:void 0}}let u=(0,o._)((0,n.Z)({},l,a)),d=s(a),c=s(l),f=t(u),g=(0,r.Z)(null==f?void 0:f.className,null==i?void 0:i.className,h,null==l?void 0:l.className,null==a?void 0:a.className),p=(0,n.Z)({},null==f?void 0:f.style,null==i?void 0:i.style,null==l?void 0:l.style,null==a?void 0:a.style),m=(0,n.Z)({},f,i,c,d);return g.length>0&&(m.className=g),Object.keys(p).length>0&&(m.style=p),{props:m,internalRef:f.ref}}},71276:function(e,t,i){"use strict";function n(e,t,i){return"function"==typeof e?e(t,i):e}i.d(t,{x:function(){return n}})},12247:function(e,t,i){"use strict";i.d(t,{Y:function(){return o},s:function(){return r}});var n=i(67294);let r=n.createContext(null);function o(){let[e,t]=n.useState(new Map),i=n.useRef(new Set),r=n.useCallback(function(e){i.current.delete(e),t(t=>{let i=new Map(t);return i.delete(e),i})},[]),o=n.useCallback(function(e,n){let o;return o="function"==typeof e?e(i.current):e,i.current.add(o),t(e=>{let t=new Map(e);return t.set(o,n),t}),{id:o,deregister:()=>r(o)}},[r]),s=n.useMemo(()=>(function(e){let t=Array.from(e.keys()).map(t=>{let i=e.get(t);return{key:t,subitem:i}});return t.sort((e,t)=>{let i=e.subitem.ref.current,n=t.subitem.ref.current;return null===i||null===n||i===n?0:i.compareDocumentPosition(n)&Node.DOCUMENT_POSITION_PRECEDING?1:-1}),new Map(t.map(e=>[e.key,e.subitem]))})(e),[e]),a=n.useCallback(function(e){return Array.from(s.keys()).indexOf(e)},[s]),l=n.useMemo(()=>({getItemIndex:a,registerItem:o,totalSubitemCount:e.size}),[a,o,e.size]);return{contextValue:l,subitems:s}}r.displayName="CompoundComponentContext"},14072:function(e,t,i){"use strict";i.d(t,{B:function(){return s}});var n=i(67294),r=i(73546),o=i(12247);function s(e,t){let i=n.useContext(o.s);if(null===i)throw Error("useCompoundItem must be used within a useCompoundParent");let{registerItem:s}=i,[a,l]=n.useState("function"==typeof e?void 0:e);return(0,r.Z)(()=>{let{id:i,deregister:n}=s(e,t);return l(i),n},[s,t,e]),{id:a,index:void 0!==a?i.getItemIndex(a):-1,totalItemCount:i.totalSubitemCount}}},78031:function(e,t,i){"use strict";i.d(t,{r:function(){return h}});var n=i(87462),r=i(67294);function o(e,t){return e===t}let s={},a=()=>{};function l(e,t){let i=(0,n.Z)({},e);return Object.keys(t).forEach(e=>{void 0!==t[e]&&(i[e]=t[e])}),i}function h(e){let t=r.useRef(null),{reducer:i,initialState:h,controlledProps:u=s,stateComparers:d=s,onStateChange:c=a,actionContext:f}=e,g=r.useCallback((e,n)=>{t.current=n;let r=l(e,u),o=i(r,n);return o},[u,i]),[p,m]=r.useReducer(g,h),_=r.useCallback(e=>{m((0,n.Z)({},e,{context:f}))},[f]);return!function(e){let{nextState:t,initialState:i,stateComparers:n,onStateChange:s,controlledProps:a,lastActionRef:h}=e,u=r.useRef(i);r.useEffect(()=>{if(null===h.current)return;let e=l(u.current,a);Object.keys(t).forEach(i=>{var r,a,l;let u=null!=(r=n[i])?r:o,d=t[i],c=e[i];(null!=c||null==d)&&(null==c||null!=d)&&(null==c||null==d||u(d,c))||null==s||s(null!=(a=h.current.event)?a:null,i,d,null!=(l=h.current.type)?l:"",t)}),u.current=t,h.current=null},[u,t,h,s,n,a])}({nextState:p,initialState:h,stateComparers:null!=d?d:s,onStateChange:null!=c?c:a,controlledProps:u,lastActionRef:t}),[l(p,u),_]}},7293:function(e,t,i){"use strict";i.d(t,{y:function(){return u}});var n=i(87462),r=i(63366),o=i(33703),s=i(10238),a=i(24407),l=i(71276);let h=["elementType","externalSlotProps","ownerState","skipResolvingSlotProps"];function u(e){var t;let{elementType:i,externalSlotProps:u,ownerState:d,skipResolvingSlotProps:c=!1}=e,f=(0,r.Z)(e,h),g=c?{}:(0,l.x)(u,d),{props:p,internalRef:m}=(0,a.L)((0,n.Z)({},f,{externalSlotProps:g})),_=(0,o.Z)(m,null==g?void 0:g.ref,null==(t=e.additionalProps)?void 0:t.ref),E=(0,s.$)(i,(0,n.Z)({},p,{ref:_}),d);return E}},48665:function(e,t,i){"use strict";i.d(t,{Z:function(){return _}});var n=i(87462),r=i(63366),o=i(67294),s=i(90512),a=i(49731),l=i(86523),h=i(39707),u=i(96682),d=i(85893);let c=["className","component"];var f=i(37078),g=i(1812),p=i(2548);let m=function(e={}){let{themeId:t,defaultTheme:i,defaultClassName:f="MuiBox-root",generateClassName:g}=e,p=(0,a.ZP)("div",{shouldForwardProp:e=>"theme"!==e&&"sx"!==e&&"as"!==e})(l.Z),m=o.forwardRef(function(e,o){let a=(0,u.Z)(i),l=(0,h.Z)(e),{className:m,component:_="div"}=l,E=(0,r.Z)(l,c);return(0,d.jsx)(p,(0,n.Z)({as:_,ref:o,className:(0,s.Z)(m,g?g(f):f),theme:t&&a[t]||a},E))});return m}({themeId:p.Z,defaultTheme:g.Z,defaultClassName:"MuiBox-root",generateClassName:f.Z.generate});var _=m},41118:function(e,t,i){"use strict";i.d(t,{Z:function(){return S}});var n=i(63366),r=i(87462),o=i(67294),s=i(90512),a=i(94780),l=i(14142),h=i(18719),u=i(20407),d=i(74312),c=i(78653),f=i(26821);function g(e){return(0,f.d6)("MuiCard",e)}(0,f.sI)("MuiCard",["root","colorPrimary","colorNeutral","colorDanger","colorSuccess","colorWarning","colorContext","variantPlain","variantOutlined","variantSoft","variantSolid","sizeSm","sizeMd","sizeLg","horizontal","vertical"]);var p=i(58859),m=i(30220),_=i(85893);let E=["className","color","component","invertedColors","size","variant","children","orientation","slots","slotProps"],v=e=>{let{size:t,variant:i,color:n,orientation:r}=e,o={root:["root",r,i&&`variant${(0,l.Z)(i)}`,n&&`color${(0,l.Z)(n)}`,t&&`size${(0,l.Z)(t)}`]};return(0,a.Z)(o,g,{})},b=(0,d.Z)("div",{name:"JoyCard",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e,ownerState:t})=>{var i,n;let{p:o,padding:s,borderRadius:a}=(0,p.V)({theme:e,ownerState:t},["p","padding","borderRadius"]);return[(0,r.Z)({"--Icon-color":"neutral"!==t.color||"solid"===t.variant?"currentColor":e.vars.palette.text.icon,"--Card-childRadius":"max((var(--Card-radius) - var(--variant-borderWidth, 0px)) - var(--Card-padding), min(var(--Card-padding) / 2, (var(--Card-radius) - var(--variant-borderWidth, 0px)) / 2))","--AspectRatio-radius":"var(--Card-childRadius)","--unstable_actionMargin":"calc(-1 * var(--variant-borderWidth, 0px))","--unstable_actionRadius":"var(--Card-radius)","--CardCover-radius":"calc(var(--Card-radius) - var(--variant-borderWidth, 0px))","--CardOverflow-offset":"calc(-1 * var(--Card-padding))","--CardOverflow-radius":"calc(var(--Card-radius) - var(--variant-borderWidth, 0px))","--Divider-inset":"calc(-1 * var(--Card-padding))"},"sm"===t.size&&{"--Card-radius":e.vars.radius.sm,"--Card-padding":"0.625rem",gap:"0.5rem"},"md"===t.size&&{"--Card-radius":e.vars.radius.md,"--Card-padding":"1rem",gap:"0.75rem 1rem"},"lg"===t.size&&{"--Card-radius":e.vars.radius.lg,"--Card-padding":"1.5rem",gap:"1rem 1.5rem"},{padding:"var(--Card-padding)",borderRadius:"var(--Card-radius)",backgroundColor:e.vars.palette.background.surface,position:"relative",display:"flex",flexDirection:"horizontal"===t.orientation?"row":"column"},e.typography[`body-${t.size}`],null==(i=e.variants[t.variant])?void 0:i[t.color]),"context"!==t.color&&t.invertedColors&&(null==(n=e.colorInversion[t.variant])?void 0:n[t.color]),void 0!==o&&{"--Card-padding":o},void 0!==s&&{"--Card-padding":s},void 0!==a&&{"--Card-radius":a}]}),C=o.forwardRef(function(e,t){let i=(0,u.Z)({props:e,name:"JoyCard"}),{className:a,color:l="neutral",component:d="div",invertedColors:f=!1,size:g="md",variant:p="outlined",children:C,orientation:S="vertical",slots:y={},slotProps:T={}}=i,R=(0,n.Z)(i,E),{getColor:A}=(0,c.VT)(p),N=A(e.color,l),O=(0,r.Z)({},i,{color:N,component:d,orientation:S,size:g,variant:p}),L=v(O),I=(0,r.Z)({},R,{component:d,slots:y,slotProps:T}),[w,D]=(0,m.Z)("root",{ref:t,className:(0,s.Z)(L.root,a),elementType:b,externalForwardedProps:I,ownerState:O}),x=(0,_.jsx)(w,(0,r.Z)({},D,{children:o.Children.map(C,(e,t)=>{if(!o.isValidElement(e))return e;let i={};if((0,h.Z)(e,["Divider"])){i.inset="inset"in e.props?e.props.inset:"context";let t="vertical"===S?"horizontal":"vertical";i.orientation="orientation"in e.props?e.props.orientation:t}return(0,h.Z)(e,["CardOverflow"])&&("horizontal"===S&&(i["data-parent"]="Card-horizontal"),"vertical"===S&&(i["data-parent"]="Card-vertical")),0===t&&(i["data-first-child"]=""),t===o.Children.count(C)-1&&(i["data-last-child"]=""),o.cloneElement(e,i)})}));return f?(0,_.jsx)(c.do,{variant:p,children:x}):x});var S=C},30208:function(e,t,i){"use strict";i.d(t,{Z:function(){return v}});var n=i(87462),r=i(63366),o=i(67294),s=i(90512),a=i(94780),l=i(20407),h=i(74312),u=i(26821);function d(e){return(0,u.d6)("MuiCardContent",e)}(0,u.sI)("MuiCardContent",["root"]);let c=(0,u.sI)("MuiCardOverflow",["root","colorPrimary","colorNeutral","colorDanger","colorSuccess","colorWarning","colorContext","variantPlain","variantOutlined","variantSoft","variantSolid"]);var f=i(30220),g=i(85893);let p=["className","component","children","orientation","slots","slotProps"],m=()=>(0,a.Z)({root:["root"]},d,{}),_=(0,h.Z)("div",{name:"JoyCardContent",slot:"Root",overridesResolver:(e,t)=>t.root})(({ownerState:e})=>({display:"flex",flexDirection:"horizontal"===e.orientation?"row":"column",flex:9999,zIndex:1,columnGap:"var(--Card-padding)",rowGap:"max(2px, calc(0.1875 * var(--Card-padding)))",padding:"var(--unstable_padding)",[`.${c.root} > &`]:{"--unstable_padding":"calc(var(--Card-padding) * 0.75) 0px"}})),E=o.forwardRef(function(e,t){let i=(0,l.Z)({props:e,name:"JoyCardContent"}),{className:o,component:a="div",children:h,orientation:u="vertical",slots:d={},slotProps:c={}}=i,E=(0,r.Z)(i,p),v=(0,n.Z)({},E,{component:a,slots:d,slotProps:c}),b=(0,n.Z)({},i,{component:a,orientation:u}),C=m(),[S,y]=(0,f.Z)("root",{ref:t,className:(0,s.Z)(C.root,o),elementType:_,externalForwardedProps:v,ownerState:b});return(0,g.jsx)(S,(0,n.Z)({},y,{children:h}))});var v=E},76043:function(e,t,i){"use strict";var n=i(67294);let r=n.createContext(void 0);t.Z=r},43614:function(e,t,i){"use strict";var n=i(67294);let r=n.createContext(void 0);t.Z=r},50984:function(e,t,i){"use strict";i.d(t,{C:function(){return s}});var n=i(87462);i(67294);var r=i(74312),o=i(58859);i(85893);let s=(0,r.Z)("ul")(({theme:e,ownerState:t})=>{var i;let{p:r,padding:s,borderRadius:a}=(0,o.V)({theme:e,ownerState:t},["p","padding","borderRadius"]);function l(i){return"sm"===i?{"--ListDivider-gap":"0.25rem","--ListItem-minHeight":"2rem","--ListItem-paddingY":"0.25rem","--ListItem-paddingX":"0.5rem","--ListItemDecorator-size":"horizontal"===t.orientation?"1.5rem":"2rem","--Icon-fontSize":e.vars.fontSize.lg}:"md"===i?{"--ListDivider-gap":"0.375rem","--ListItem-minHeight":"2.5rem","--ListItem-paddingY":"0.375rem","--ListItem-paddingX":"0.75rem","--ListItemDecorator-size":"horizontal"===t.orientation?"1.75rem":"2.5rem","--Icon-fontSize":e.vars.fontSize.xl}:"lg"===i?{"--ListDivider-gap":"0.5rem","--ListItem-minHeight":"3rem","--ListItem-paddingY":"0.5rem","--ListItem-paddingX":"1rem","--ListItemDecorator-size":"horizontal"===t.orientation?"2.25rem":"3rem","--Icon-fontSize":e.vars.fontSize.xl2}:{}}return[t.nesting&&(0,n.Z)({},l(t.instanceSize),{"--ListItem-paddingRight":"var(--ListItem-paddingX)","--ListItem-paddingLeft":"var(--NestedListItem-paddingLeft)","--ListItemButton-marginBlock":"0px","--ListItemButton-marginInline":"0px","--ListItem-marginBlock":"0px","--ListItem-marginInline":"0px",padding:0,marginInlineStart:"var(--NestedList-marginLeft)",marginInlineEnd:"var(--NestedList-marginRight)",marginBlockStart:"var(--List-gap)",marginBlockEnd:"initial"}),!t.nesting&&(0,n.Z)({},l(t.size),{"--List-gap":"0px","--List-nestedInsetStart":"0px","--ListItem-paddingLeft":"var(--ListItem-paddingX)","--ListItem-paddingRight":"var(--ListItem-paddingX)","--unstable_List-childRadius":"calc(max(var(--List-radius) - var(--List-padding), min(var(--List-padding) / 2, var(--List-radius) / 2)) - var(--variant-borderWidth, 0px))","--ListItem-radius":"var(--unstable_List-childRadius)","--ListItem-startActionTranslateX":"calc(0.5 * var(--ListItem-paddingLeft))","--ListItem-endActionTranslateX":"calc(-0.5 * var(--ListItem-paddingRight))",margin:"initial"},e.typography[`body-${t.size}`],"horizontal"===t.orientation?(0,n.Z)({},t.wrap?{padding:"var(--List-padding)",marginInlineStart:"calc(-1 * var(--List-gap))",marginBlockStart:"calc(-1 * var(--List-gap))"}:{paddingInline:"var(--List-padding, var(--ListDivider-gap))",paddingBlock:"var(--List-padding)"}):{paddingBlock:"var(--List-padding, var(--ListDivider-gap))",paddingInline:"var(--List-padding)"}),(0,n.Z)({boxSizing:"border-box",borderRadius:"var(--List-radius)",listStyle:"none",display:"flex",flexDirection:"horizontal"===t.orientation?"row":"column"},t.wrap&&{flexWrap:"wrap"},{flexGrow:1,position:"relative"},null==(i=e.variants[t.variant])?void 0:i[t.color],{"--unstable_List-borderWidth":"var(--variant-borderWidth, 0px)"},void 0!==a&&{"--List-radius":a},void 0!==r&&{"--List-padding":r},void 0!==s&&{"--List-padding":s})]});(0,r.Z)(s,{name:"JoyList",slot:"Root",overridesResolver:(e,t)=>t.root})({})},3419:function(e,t,i){"use strict";i.d(t,{Z:function(){return u},M:function(){return h}});var n=i(87462),r=i(67294),o=i(40780);let s=r.createContext(!1),a=r.createContext(!1);var l=i(85893);let h={"--NestedList-marginRight":"0px","--NestedList-marginLeft":"0px","--NestedListItem-paddingLeft":"var(--ListItem-paddingX)","--ListItemButton-marginBlock":"0px","--ListItemButton-marginInline":"0px","--ListItem-marginBlock":"0px","--ListItem-marginInline":"0px"};var u=function(e){let{children:t,nested:i,row:h=!1,wrap:u=!1}=e,d=(0,l.jsx)(o.Z.Provider,{value:h,children:(0,l.jsx)(s.Provider,{value:u,children:r.Children.map(t,(e,i)=>r.isValidElement(e)?r.cloneElement(e,(0,n.Z)({},0===i&&{"data-first-child":""},i===r.Children.count(t)-1&&{"data-last-child":""})):e)})});return void 0===i?d:(0,l.jsx)(a.Provider,{value:i,children:d})}},40780:function(e,t,i){"use strict";var n=i(67294);let r=n.createContext(!1);t.Z=r},39984:function(e,t,i){"use strict";i.d(t,{r:function(){return l}});var n=i(87462);i(67294);var r=i(74312),o=i(26821);let s=(0,o.sI)("MuiListItem",["root","startAction","endAction","nested","nesting","sticky","colorPrimary","colorNeutral","colorDanger","colorSuccess","colorWarning","colorContext","variantPlain","variantSoft","variantOutlined","variantSolid"]),a=(0,o.sI)("MuiListItemButton",["root","horizontal","vertical","colorPrimary","colorNeutral","colorDanger","colorSuccess","colorWarning","colorContext","focusVisible","disabled","selected","variantPlain","variantSoft","variantOutlined","variantSolid"]);i(85893);let l=(0,r.Z)("div")(({theme:e,ownerState:t})=>{var i,r,o,l,h;return(0,n.Z)({"--Icon-margin":"initial","--Icon-color":"neutral"!==t.color||"solid"===t.variant?"currentColor":e.vars.palette.text.icon,WebkitTapHighlightColor:"transparent",boxSizing:"border-box",position:"relative",font:"inherit",display:"flex",flexDirection:"row",alignItems:"center",alignSelf:"stretch"},"vertical"===t.orientation&&{flexDirection:"column",justifyContent:"center"},{textAlign:"initial",textDecoration:"initial",backgroundColor:"initial",cursor:"pointer",marginInline:"var(--ListItemButton-marginInline)",marginBlock:"var(--ListItemButton-marginBlock)"},void 0===t["data-first-child"]&&{marginInlineStart:t.row?"var(--List-gap)":void 0,marginBlockStart:t.row?void 0:"var(--List-gap)"},{paddingBlock:"calc(var(--ListItem-paddingY) - var(--variant-borderWidth, 0px))",paddingInlineStart:"calc(var(--ListItem-paddingLeft) + var(--ListItem-startActionWidth, var(--unstable_startActionWidth, 0px)))",paddingInlineEnd:"calc(var(--ListItem-paddingRight) + var(--ListItem-endActionWidth, var(--unstable_endActionWidth, 0px)))",minBlockSize:"var(--ListItem-minHeight)",border:"1px solid transparent",borderRadius:"var(--ListItem-radius)",flex:"var(--unstable_ListItem-flex, none)",fontSize:"inherit",lineHeight:"inherit",minInlineSize:0,[e.focus.selector]:(0,n.Z)({},e.focus.default,{zIndex:1})},null==(i=e.variants[t.variant])?void 0:i[t.color],{[`.${s.root} > &`]:{"--unstable_ListItem-flex":"1 0 0%"},[`&.${a.selected}`]:(0,n.Z)({},null==(r=e.variants[`${t.variant}Active`])?void 0:r[t.color],{"--Icon-color":"currentColor"}),[`&:not(.${a.selected}, [aria-selected="true"])`]:{"&:hover":null==(o=e.variants[`${t.variant}Hover`])?void 0:o[t.color],"&:active":null==(l=e.variants[`${t.variant}Active`])?void 0:l[t.color]},[`&.${a.disabled}`]:(0,n.Z)({},null==(h=e.variants[`${t.variant}Disabled`])?void 0:h[t.color])})});(0,r.Z)(l,{name:"JoyListItemButton",slot:"Root",overridesResolver:(e,t)=>t.root})(({ownerState:e,theme:t})=>(0,n.Z)({},!e.row&&{[`&.${a.selected}`]:{fontWeight:t.vars.fontWeight.md}}))},57814:function(e,t,i){"use strict";i.d(t,{Z:function(){return A}});var n=i(87462),r=i(63366),o=i(67294),s=i(94780),a=i(92996),l=i(33703),h=i(43069),u=i(14072),d=i(30220),c=i(39984),f=i(74312),g=i(20407),p=i(78653),m=i(55907),_=i(26821);function E(e){return(0,_.d6)("MuiOption",e)}let v=(0,_.sI)("MuiOption",["root","colorPrimary","colorNeutral","colorDanger","colorSuccess","colorWarning","colorContext","focusVisible","disabled","selected","highlighted","variantPlain","variantSoft","variantOutlined","variantSolid"]);var b=i(40780),C=i(85893);let S=["component","children","disabled","value","label","variant","color","slots","slotProps"],y=e=>{let{disabled:t,highlighted:i,selected:n}=e;return(0,s.Z)({root:["root",t&&"disabled",i&&"highlighted",n&&"selected"]},E,{})},T=(0,f.Z)(c.r,{name:"JoyOption",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e,ownerState:t})=>{var i;let n=null==(i=e.variants[`${t.variant}Hover`])?void 0:i[t.color];return{[`&.${v.highlighted}:not([aria-selected="true"])`]:{backgroundColor:null==n?void 0:n.backgroundColor}}}),R=o.forwardRef(function(e,t){var i;let s=(0,g.Z)({props:e,name:"JoyOption"}),{component:c="li",children:f,disabled:_=!1,value:E,label:v,variant:R="plain",color:A="neutral",slots:N={},slotProps:O={}}=s,L=(0,r.Z)(s,S),I=o.useContext(b.Z),{variant:w=R,color:D=A}=(0,m.yP)(e.variant,e.color),x=o.useRef(null),M=(0,l.Z)(x,t),k=null!=v?v:"string"==typeof f?f:null==(i=x.current)?void 0:i.innerText,{getRootProps:P,selected:F,highlighted:B,index:U}=function(e){let{value:t,label:i,disabled:r,rootRef:s,id:d}=e,{getRootProps:c,rootRef:f,highlighted:g,selected:p}=(0,h.J)({item:t}),m=(0,a.Z)(d),_=o.useRef(null),E=o.useMemo(()=>({disabled:r,label:i,value:t,ref:_,id:m}),[r,i,t,m]),{index:v}=(0,u.B)(t,E),b=(0,l.Z)(s,_,f);return{getRootProps:(e={})=>(0,n.Z)({},e,c(e),{id:m,ref:b,role:"option","aria-selected":p}),highlighted:g,index:v,selected:p,rootRef:b}}({disabled:_,label:k,value:E,rootRef:M}),{getColor:H}=(0,p.VT)(w),V=H(e.color,D),W=(0,n.Z)({},s,{disabled:_,selected:F,highlighted:B,index:U,component:c,variant:w,color:V,row:I}),G=y(W),j=(0,n.Z)({},L,{component:c,slots:N,slotProps:O}),[z,K]=(0,d.Z)("root",{ref:t,getSlotProps:P,elementType:T,externalForwardedProps:j,className:G.root,ownerState:W});return(0,C.jsx)(z,(0,n.Z)({},K,{children:f}))});var A=R},99056:function(e,t,i){"use strict";i.d(t,{Z:function(){return ea}});var n,r=i(63366),o=i(87462),s=i(67294),a=i(90512),l=i(14142),h=i(33703),u=i(53406),d=i(92996),c=i(73546),f=i(70758);let g={buttonClick:"buttonClick"};var p=i(96592);let m=e=>{let{label:t,value:i}=e;return"string"==typeof t?t:"string"==typeof i?i:String(e)};var _=i(12247),E=i(7333),v=i(22644);function b(e,t){var i,n,r;let{open:s}=e,{context:{selectionMode:a}}=t;if(t.type===g.buttonClick){let n=null!=(i=e.selectedValues[0])?i:(0,E.Rl)(null,"start",t.context);return(0,o.Z)({},e,{open:!s,highlightedValue:s?null:n})}let l=(0,E.R$)(e,t);switch(t.type){case v.F.keyDown:if(e.open){if("Escape"===t.event.key||"single"===a&&("Enter"===t.event.key||" "===t.event.key))return(0,o.Z)({},l,{open:!1})}else{if("Enter"===t.event.key||" "===t.event.key||"ArrowDown"===t.event.key)return(0,o.Z)({},e,{open:!0,highlightedValue:null!=(n=e.selectedValues[0])?n:(0,E.Rl)(null,"start",t.context)});if("ArrowUp"===t.event.key)return(0,o.Z)({},e,{open:!0,highlightedValue:null!=(r=e.selectedValues[0])?r:(0,E.Rl)(null,"end",t.context)})}break;case v.F.itemClick:if("single"===a)return(0,o.Z)({},l,{open:!1});break;case v.F.blur:return(0,o.Z)({},l,{open:!1})}return l}var C=i(2900);let S={clip:"rect(1px, 1px, 1px, 1px)",clipPath:"inset(50%)",height:"1px",width:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"absolute",left:"50%",bottom:0},y=()=>{};function T(e){return Array.isArray(e)?0===e.length?"":JSON.stringify(e.map(e=>e.value)):(null==e?void 0:e.value)==null?"":"string"==typeof e.value||"number"==typeof e.value?e.value:JSON.stringify(e.value)}function R(e){e.preventDefault()}var A=i(26558),N=i(85893);function O(e){let{value:t,children:i}=e,{dispatch:n,getItemIndex:r,getItemState:o,registerHighlightChangeHandler:a,registerSelectionChangeHandler:l,registerItem:h,totalSubitemCount:u}=t,d=s.useMemo(()=>({dispatch:n,getItemState:o,getItemIndex:r,registerHighlightChangeHandler:a,registerSelectionChangeHandler:l}),[n,r,o,a,l]),c=s.useMemo(()=>({getItemIndex:r,registerItem:h,totalSubitemCount:u}),[h,r,u]);return(0,N.jsx)(_.s.Provider,{value:c,children:(0,N.jsx)(A.Z.Provider,{value:d,children:i})})}var L=i(94780),I=i(50984),w=i(3419),D=i(43614),x=i(74312),M=i(20407),k=i(30220),P=i(26821);function F(e){return(0,P.d6)("MuiSvgIcon",e)}(0,P.sI)("MuiSvgIcon",["root","colorInherit","colorPrimary","colorNeutral","colorDanger","colorSuccess","colorWarning","fontSizeInherit","fontSizeXs","fontSizeSm","fontSizeMd","fontSizeLg","fontSizeXl","fontSizeXl2","fontSizeXl3","fontSizeXl4","sizeSm","sizeMd","sizeLg"]);let B=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox","size","slots","slotProps"],U=e=>{let{color:t,size:i,fontSize:n}=e,r={root:["root",t&&"inherit"!==t&&`color${(0,l.Z)(t)}`,i&&`size${(0,l.Z)(i)}`,n&&`fontSize${(0,l.Z)(n)}`]};return(0,L.Z)(r,F,{})},H={sm:"xl",md:"xl2",lg:"xl3"},V=(0,x.Z)("svg",{name:"JoySvgIcon",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e,ownerState:t})=>{var i;return(0,o.Z)({},t.instanceSize&&{"--Icon-fontSize":e.vars.fontSize[H[t.instanceSize]]},t.instanceFontSize&&"inherit"!==t.instanceFontSize&&{"--Icon-fontSize":e.vars.fontSize[t.instanceFontSize]},{userSelect:"none",margin:"var(--Icon-margin)",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,fontSize:`var(--Icon-fontSize, ${e.vars.fontSize[H[t.size]]||"unset"})`},t.fontSize&&"inherit"!==t.fontSize&&{fontSize:`var(--Icon-fontSize, ${e.fontSize[t.fontSize]})`},!t.htmlColor&&(0,o.Z)({color:`var(--Icon-color, ${e.vars.palette.text.icon})`},"inherit"===t.color&&{color:"inherit"},"inherit"!==t.color&&"context"!==t.color&&e.vars.palette[t.color]&&{color:`rgba(${null==(i=e.vars.palette[t.color])?void 0:i.mainChannel} / 1)`}))}),W=s.forwardRef(function(e,t){let i=(0,M.Z)({props:e,name:"JoySvgIcon"}),{children:n,className:l,color:h,component:u="svg",fontSize:d,htmlColor:c,inheritViewBox:f=!1,titleAccess:g,viewBox:p="0 0 24 24",size:m="md",slots:_={},slotProps:E={}}=i,v=(0,r.Z)(i,B),b=s.isValidElement(n)&&"svg"===n.type,C=(0,o.Z)({},i,{color:h,component:u,size:m,instanceSize:e.size,fontSize:d,instanceFontSize:e.fontSize,inheritViewBox:f,viewBox:p,hasSvgAsChild:b}),S=U(C),y=(0,o.Z)({},v,{component:u,slots:_,slotProps:E}),[T,R]=(0,k.Z)("root",{ref:t,className:(0,a.Z)(S.root,l),elementType:V,externalForwardedProps:y,ownerState:C,additionalProps:(0,o.Z)({color:c,focusable:!1},g&&{role:"img"},!g&&{"aria-hidden":!0},!f&&{viewBox:p},b&&n.props)});return(0,N.jsxs)(T,(0,o.Z)({},R,{children:[b?n.props.children:n,g?(0,N.jsx)("title",{children:g}):null]}))});var G=function(e,t){function i(i,n){return(0,N.jsx)(W,(0,o.Z)({"data-testid":`${t}Icon`,ref:n},i,{children:e}))}return i.muiName=W.muiName,s.memo(s.forwardRef(i))}((0,N.jsx)("path",{d:"m12 5.83 2.46 2.46c.39.39 1.02.39 1.41 0 .39-.39.39-1.02 0-1.41L12.7 3.7a.9959.9959 0 0 0-1.41 0L8.12 6.88c-.39.39-.39 1.02 0 1.41.39.39 1.02.39 1.41 0L12 5.83zm0 12.34-2.46-2.46a.9959.9959 0 0 0-1.41 0c-.39.39-.39 1.02 0 1.41l3.17 3.18c.39.39 1.02.39 1.41 0l3.17-3.17c.39-.39.39-1.02 0-1.41a.9959.9959 0 0 0-1.41 0L12 18.17z"}),"Unfold"),j=i(78653),z=i(58859);function K(e){return(0,P.d6)("MuiSelect",e)}let Y=(0,P.sI)("MuiSelect",["root","button","indicator","startDecorator","endDecorator","popper","listbox","colorPrimary","colorNeutral","colorDanger","colorSuccess","colorWarning","colorContext","variantPlain","variantOutlined","variantSoft","variantSolid","sizeSm","sizeMd","sizeLg","focusVisible","disabled","expanded"]);var $=i(76043),q=i(55907);let X=["action","autoFocus","children","defaultValue","defaultListboxOpen","disabled","getSerializedValue","placeholder","listboxId","listboxOpen","onChange","onListboxOpenChange","onClose","renderValue","required","value","size","variant","color","startDecorator","endDecorator","indicator","aria-describedby","aria-label","aria-labelledby","id","name","slots","slotProps"];function Z(e){var t;return null!=(t=null==e?void 0:e.label)?t:""}let Q=[{name:"offset",options:{offset:[0,4]}},{name:"equalWidth",enabled:!0,phase:"beforeWrite",requires:["computeStyles"],fn:({state:e})=>{e.styles.popper.width=`${e.rects.reference.width}px`}}],J=e=>{let{color:t,disabled:i,focusVisible:n,size:r,variant:o,open:s}=e,a={root:["root",i&&"disabled",n&&"focusVisible",s&&"expanded",o&&`variant${(0,l.Z)(o)}`,t&&`color${(0,l.Z)(t)}`,r&&`size${(0,l.Z)(r)}`],button:["button"],startDecorator:["startDecorator"],endDecorator:["endDecorator"],indicator:["indicator",s&&"expanded"],listbox:["listbox",s&&"expanded",i&&"disabled"]};return(0,L.Z)(a,K,{})},ee=(0,x.Z)("div",{name:"JoySelect",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e,ownerState:t})=>{var i,n,r,s;let a=null==(i=e.variants[`${t.variant}`])?void 0:i[t.color],{borderRadius:l}=(0,z.V)({theme:e,ownerState:t},["borderRadius"]);return[(0,o.Z)({"--Select-radius":e.vars.radius.sm,"--Select-gap":"0.5rem","--Select-placeholderOpacity":.64,"--Select-decoratorColor":e.vars.palette.text.icon,"--Select-focusedThickness":e.vars.focus.thickness},"context"===t.color?{"--Select-focusedHighlight":e.vars.palette.focusVisible}:{"--Select-focusedHighlight":null==(n=e.vars.palette["neutral"===t.color?"primary":t.color])?void 0:n[500]},{"--Select-indicatorColor":null!=a&&a.backgroundColor?null==a?void 0:a.color:e.vars.palette.text.tertiary},"sm"===t.size&&{"--Select-minHeight":"2rem","--Select-paddingInline":"0.5rem","--Select-decoratorChildHeight":"min(1.5rem, var(--Select-minHeight))","--Icon-fontSize":e.vars.fontSize.xl},"md"===t.size&&{"--Select-minHeight":"2.5rem","--Select-paddingInline":"0.75rem","--Select-decoratorChildHeight":"min(2rem, var(--Select-minHeight))","--Icon-fontSize":e.vars.fontSize.xl2},"lg"===t.size&&{"--Select-minHeight":"3rem","--Select-paddingInline":"1rem","--Select-decoratorChildHeight":"min(2.375rem, var(--Select-minHeight))","--Icon-fontSize":e.vars.fontSize.xl2},{"--Select-decoratorChildOffset":"min(calc(var(--Select-paddingInline) - (var(--Select-minHeight) - 2 * var(--variant-borderWidth, 0px) - var(--Select-decoratorChildHeight)) / 2), var(--Select-paddingInline))","--_Select-paddingBlock":"max((var(--Select-minHeight) - 2 * var(--variant-borderWidth, 0px) - var(--Select-decoratorChildHeight)) / 2, 0px)","--Select-decoratorChildRadius":"max(var(--Select-radius) - var(--variant-borderWidth, 0px) - var(--_Select-paddingBlock), min(var(--_Select-paddingBlock) + var(--variant-borderWidth, 0px), var(--Select-radius) / 2))","--Button-minHeight":"var(--Select-decoratorChildHeight)","--IconButton-size":"var(--Select-decoratorChildHeight)","--Button-radius":"var(--Select-decoratorChildRadius)","--IconButton-radius":"var(--Select-decoratorChildRadius)",boxSizing:"border-box"},"plain"!==t.variant&&{boxShadow:e.shadow.xs},{minWidth:0,minHeight:"var(--Select-minHeight)",position:"relative",display:"flex",alignItems:"center",borderRadius:"var(--Select-radius)",cursor:"pointer"},!(null!=a&&a.backgroundColor)&&{backgroundColor:e.vars.palette.background.surface},t.size&&{paddingBlock:({sm:2,md:3,lg:4})[t.size]},{paddingInline:"var(--Select-paddingInline)"},e.typography[`body-${t.size}`],a,{"&::before":{boxSizing:"border-box",content:'""',display:"block",position:"absolute",pointerEvents:"none",top:0,left:0,right:0,bottom:0,zIndex:1,borderRadius:"inherit",margin:"calc(var(--variant-borderWidth, 0px) * -1)"},[`&.${Y.focusVisible}`]:{"--Select-indicatorColor":null==a?void 0:a.color,"&::before":{boxShadow:"inset 0 0 0 var(--Select-focusedThickness) var(--Select-focusedHighlight)"}},[`&.${Y.disabled}`]:{"--Select-indicatorColor":"inherit"}}),{"&:hover":null==(r=e.variants[`${t.variant}Hover`])?void 0:r[t.color],[`&.${Y.disabled}`]:null==(s=e.variants[`${t.variant}Disabled`])?void 0:s[t.color]},void 0!==l&&{"--Select-radius":l}]}),et=(0,x.Z)("button",{name:"JoySelect",slot:"Button",overridesResolver:(e,t)=>t.button})(({ownerState:e})=>(0,o.Z)({border:0,outline:0,background:"none",padding:0,fontSize:"inherit",color:"inherit",alignSelf:"stretch",display:"flex",alignItems:"center",flex:1,fontFamily:"inherit",cursor:"pointer",whiteSpace:"nowrap",overflow:"hidden"},(null===e.value||void 0===e.value)&&{opacity:"var(--Select-placeholderOpacity)"},{"&::before":{content:'""',display:"block",position:"absolute",top:"calc(-1 * var(--variant-borderWidth, 0px))",left:"calc(-1 * var(--variant-borderWidth, 0px))",right:"calc(-1 * var(--variant-borderWidth, 0px))",bottom:"calc(-1 * var(--variant-borderWidth, 0px))",borderRadius:"var(--Select-radius)"}})),ei=(0,x.Z)(I.C,{name:"JoySelect",slot:"Listbox",overridesResolver:(e,t)=>t.listbox})(({theme:e,ownerState:t})=>{var i;let n="context"===t.color?void 0:null==(i=e.variants[t.variant])?void 0:i[t.color];return(0,o.Z)({"--focus-outline-offset":`calc(${e.vars.focus.thickness} * -1)`,"--ListItem-stickyBackground":(null==n?void 0:n.backgroundColor)||(null==n?void 0:n.background)||e.vars.palette.background.popup,"--ListItem-stickyTop":"calc(var(--List-padding, var(--ListDivider-gap)) * -1)"},w.M,{minWidth:"max-content",maxHeight:"44vh",overflow:"auto",outline:0,boxShadow:e.shadow.md,borderRadius:`var(--List-radius, ${e.vars.radius.sm})`,zIndex:`var(--unstable_popup-zIndex, ${e.vars.zIndex.popup})`},!(null!=n&&n.backgroundColor)&&{backgroundColor:e.vars.palette.background.popup})}),en=(0,x.Z)("span",{name:"JoySelect",slot:"StartDecorator",overridesResolver:(e,t)=>t.startDecorator})({"--Button-margin":"0 0 0 calc(var(--Select-decoratorChildOffset) * -1)","--IconButton-margin":"0 0 0 calc(var(--Select-decoratorChildOffset) * -1)","--Icon-margin":"0 0 0 calc(var(--Select-paddingInline) / -4)",display:"inherit",alignItems:"center",color:"var(--Select-decoratorColor)",marginInlineEnd:"var(--Select-gap)"}),er=(0,x.Z)("span",{name:"JoySelect",slot:"EndDecorator",overridesResolver:(e,t)=>t.endDecorator})({"--Button-margin":"0 calc(var(--Select-decoratorChildOffset) * -1) 0 0","--IconButton-margin":"0 calc(var(--Select-decoratorChildOffset) * -1) 0 0","--Icon-margin":"0 calc(var(--Select-paddingInline) / -4) 0 0",display:"inherit",alignItems:"center",color:"var(--Select-decoratorColor)",marginInlineStart:"var(--Select-gap)"}),eo=(0,x.Z)("span",{name:"JoySelect",slot:"Indicator"})(({ownerState:e,theme:t})=>(0,o.Z)({},"sm"===e.size&&{"--Icon-fontSize":t.vars.fontSize.lg},"md"===e.size&&{"--Icon-fontSize":t.vars.fontSize.xl},"lg"===e.size&&{"--Icon-fontSize":t.vars.fontSize.xl2},{"--Icon-color":"neutral"!==e.color||"solid"===e.variant?"currentColor":t.vars.palette.text.icon,display:"inherit",alignItems:"center",marginInlineStart:"var(--Select-gap)",marginInlineEnd:"calc(var(--Select-paddingInline) / -4)",[`.${Y.endDecorator} + &`]:{marginInlineStart:"calc(var(--Select-gap) / 2)"},[`&.${Y.expanded}, .${Y.disabled} > &`]:{"--Icon-color":"currentColor"}})),es=s.forwardRef(function(e,t){var i,l,E,v,A,L,I;let x=(0,M.Z)({props:e,name:"JoySelect"}),{action:P,autoFocus:F,children:B,defaultValue:U,defaultListboxOpen:H=!1,disabled:V,getSerializedValue:W,placeholder:z,listboxId:K,listboxOpen:es,onChange:ea,onListboxOpenChange:el,onClose:eh,renderValue:eu,required:ed=!1,value:ec,size:ef="md",variant:eg="outlined",color:ep="neutral",startDecorator:em,endDecorator:e_,indicator:eE=n||(n=(0,N.jsx)(G,{})),"aria-describedby":ev,"aria-label":eb,"aria-labelledby":eC,id:eS,name:ey,slots:eT={},slotProps:eR={}}=x,eA=(0,r.Z)(x,X),eN=s.useContext($.Z),eO=null!=(i=null!=(l=e.disabled)?l:null==eN?void 0:eN.disabled)?i:V,eL=null!=(E=null!=(v=e.size)?v:null==eN?void 0:eN.size)?E:ef,{getColor:eI}=(0,j.VT)(eg),ew=eI(e.color,null!=eN&&eN.error?"danger":null!=(A=null==eN?void 0:eN.color)?A:ep),eD=null!=eu?eu:Z,[ex,eM]=s.useState(null),ek=s.useRef(null),eP=s.useRef(null),eF=s.useRef(null),eB=(0,h.Z)(t,ek);s.useImperativeHandle(P,()=>({focusVisible:()=>{var e;null==(e=eP.current)||e.focus()}}),[]),s.useEffect(()=>{eM(ek.current)},[]),s.useEffect(()=>{F&&eP.current.focus()},[F]);let eU=s.useCallback(e=>{null==el||el(e),e||null==eh||eh()},[eh,el]),{buttonActive:eH,buttonFocusVisible:eV,contextValue:eW,disabled:eG,getButtonProps:ej,getListboxProps:ez,getHiddenInputProps:eK,getOptionMetadata:eY,open:e$,value:eq}=function(e){let t,i,n;let{areOptionsEqual:r,buttonRef:a,defaultOpen:l=!1,defaultValue:u,disabled:E=!1,listboxId:v,listboxRef:A,multiple:N=!1,name:O,required:L,onChange:I,onHighlightChange:w,onOpenChange:D,open:x,options:M,getOptionAsString:k=m,getSerializedValue:P=T,value:F}=e,B=s.useRef(null),U=(0,h.Z)(a,B),H=s.useRef(null),V=(0,d.Z)(v);void 0===F&&void 0===u?t=[]:void 0!==u&&(t=N?u:null==u?[]:[u]);let W=s.useMemo(()=>{if(void 0!==F)return N?F:null==F?[]:[F]},[F,N]),{subitems:G,contextValue:j}=(0,_.Y)(),z=s.useMemo(()=>null!=M?new Map(M.map((e,t)=>[e.value,{value:e.value,label:e.label,disabled:e.disabled,ref:s.createRef(),id:`${V}_${t}`}])):G,[M,G,V]),K=(0,h.Z)(A,H),{getRootProps:Y,active:$,focusVisible:q,rootRef:X}=(0,f.U)({disabled:E,rootRef:U}),Z=s.useMemo(()=>Array.from(z.keys()),[z]),Q=s.useCallback(e=>{if(void 0!==r){let t=Z.find(t=>r(t,e));return z.get(t)}return z.get(e)},[z,r,Z]),J=s.useCallback(e=>{var t;let i=Q(e);return null!=(t=null==i?void 0:i.disabled)&&t},[Q]),ee=s.useCallback(e=>{let t=Q(e);return t?k(t):""},[Q,k]),et=s.useMemo(()=>({selectedValues:W,open:x}),[W,x]),ei=s.useCallback(e=>{var t;return null==(t=z.get(e))?void 0:t.id},[z]),en=s.useCallback((e,t)=>{if(N)null==I||I(e,t);else{var i;null==I||I(e,null!=(i=t[0])?i:null)}},[N,I]),er=s.useCallback((e,t)=>{null==w||w(e,null!=t?t:null)},[w]),eo=s.useCallback((e,t,i)=>{if("open"===t&&(null==D||D(i),!1===i&&(null==e?void 0:e.type)!=="blur")){var n;null==(n=B.current)||n.focus()}},[D]),es={getInitialState:()=>{var e;return{highlightedValue:null,selectedValues:null!=(e=t)?e:[],open:l}},getItemId:ei,controlledProps:et,itemComparer:r,isItemDisabled:J,rootRef:X,onChange:en,onHighlightChange:er,onStateChange:eo,reducerActionContext:s.useMemo(()=>({multiple:N}),[N]),items:Z,getItemAsString:ee,selectionMode:N?"multiple":"single",stateReducer:b},{dispatch:ea,getRootProps:el,contextValue:eh,state:{open:eu,highlightedValue:ed,selectedValues:ec},rootRef:ef}=(0,p.s)(es),eg=e=>t=>{var i;if(null==e||null==(i=e.onMouseDown)||i.call(e,t),!t.defaultMuiPrevented){let e={type:g.buttonClick,event:t};ea(e)}};(0,c.Z)(()=>{if(null!=ed){var e;let t=null==(e=Q(ed))?void 0:e.ref;if(!H.current||!(null!=t&&t.current))return;let i=H.current.getBoundingClientRect(),n=t.current.getBoundingClientRect();n.topi.bottom&&(H.current.scrollTop+=n.bottom-i.bottom)}},[ed,Q]);let ep=s.useCallback(e=>Q(e),[Q]),em=(e={})=>(0,o.Z)({},e,{onMouseDown:eg(e),ref:ef,role:"combobox","aria-expanded":eu,"aria-controls":V});s.useDebugValue({selectedOptions:ec,highlightedOption:ed,open:eu});let e_=s.useMemo(()=>(0,o.Z)({},eh,j),[eh,j]);if(i=e.multiple?ec:ec.length>0?ec[0]:null,N)n=i.map(e=>ep(e)).filter(e=>void 0!==e);else{var eE;n=null!=(eE=ep(i))?eE:null}return{buttonActive:$,buttonFocusVisible:q,buttonRef:X,contextValue:e_,disabled:E,dispatch:ea,getButtonProps:(e={})=>{let t=(0,C.f)(Y,el),i=(0,C.f)(t,em);return i(e)},getHiddenInputProps:(e={})=>(0,o.Z)({name:O,tabIndex:-1,"aria-hidden":!0,required:!!L||void 0,value:P(n),onChange:y,style:S},e),getListboxProps:(e={})=>(0,o.Z)({},e,{id:V,role:"listbox","aria-multiselectable":N?"true":void 0,ref:K,onMouseDown:R}),getOptionMetadata:ep,listboxRef:ef,open:eu,options:Z,value:i,highlightedOption:ed}}({buttonRef:eP,defaultOpen:H,defaultValue:U,disabled:eO,getSerializedValue:W,listboxId:K,multiple:!1,name:ey,required:ed,onChange:ea,onOpenChange:eU,open:es,value:ec}),eX=(0,o.Z)({},x,{active:eH,defaultListboxOpen:H,disabled:eG,focusVisible:eV,open:e$,renderValue:eD,value:eq,size:eL,variant:eg,color:ew}),eZ=J(eX),eQ=(0,o.Z)({},eA,{slots:eT,slotProps:eR}),eJ=s.useMemo(()=>{var e;return null!=(e=eY(eq))?e:null},[eY,eq]),[e0,e1]=(0,k.Z)("root",{ref:eB,className:eZ.root,elementType:ee,externalForwardedProps:eQ,ownerState:eX}),[e2,e5]=(0,k.Z)("button",{additionalProps:{"aria-describedby":null!=ev?ev:null==eN?void 0:eN["aria-describedby"],"aria-label":eb,"aria-labelledby":null!=eC?eC:null==eN?void 0:eN.labelId,"aria-required":ed?"true":void 0,id:null!=eS?eS:null==eN?void 0:eN.htmlFor,name:ey},className:eZ.button,elementType:et,externalForwardedProps:eQ,getSlotProps:ej,ownerState:eX}),[e4,e3]=(0,k.Z)("listbox",{additionalProps:{ref:eF,anchorEl:ex,open:e$,placement:"bottom",keepMounted:!0},className:eZ.listbox,elementType:ei,externalForwardedProps:eQ,getSlotProps:ez,ownerState:(0,o.Z)({},eX,{nesting:!1,row:!1,wrap:!1}),getSlotOwnerState:e=>({size:e.size||eL,variant:e.variant||eg,color:e.color||(e.disablePortal?ew:ep),disableColorInversion:!e.disablePortal})}),[e6,e9]=(0,k.Z)("startDecorator",{className:eZ.startDecorator,elementType:en,externalForwardedProps:eQ,ownerState:eX}),[e8,e7]=(0,k.Z)("endDecorator",{className:eZ.endDecorator,elementType:er,externalForwardedProps:eQ,ownerState:eX}),[te,tt]=(0,k.Z)("indicator",{className:eZ.indicator,elementType:eo,externalForwardedProps:eQ,ownerState:eX}),ti=s.useMemo(()=>[...Q,...e3.modifiers||[]],[e3.modifiers]),tn=null;return ex&&(tn=(0,N.jsx)(e4,(0,o.Z)({},e3,{className:(0,a.Z)(e3.className,(null==(L=e3.ownerState)?void 0:L.color)==="context"&&Y.colorContext),modifiers:ti},!(null!=(I=x.slots)&&I.listbox)&&{as:u.r,slots:{root:e3.as||"ul"}},{children:(0,N.jsx)(O,{value:eW,children:(0,N.jsx)(q.Yb,{variant:eg,color:ep,children:(0,N.jsx)(D.Z.Provider,{value:"select",children:(0,N.jsx)(w.Z,{nested:!0,children:B})})})})})),e3.disablePortal||(tn=(0,N.jsx)(j.ZP.Provider,{value:void 0,children:tn}))),(0,N.jsxs)(s.Fragment,{children:[(0,N.jsxs)(e0,(0,o.Z)({},e1,{children:[em&&(0,N.jsx)(e6,(0,o.Z)({},e9,{children:em})),(0,N.jsx)(e2,(0,o.Z)({},e5,{children:eJ?eD(eJ):z})),e_&&(0,N.jsx)(e8,(0,o.Z)({},e7,{children:e_})),eE&&(0,N.jsx)(te,(0,o.Z)({},tt,{children:eE})),(0,N.jsx)("input",(0,o.Z)({},eK()))]})),tn]})});var ea=es},61685:function(e,t,i){"use strict";i.d(t,{Z:function(){return S}});var n=i(63366),r=i(87462),o=i(67294),s=i(90512),a=i(14142),l=i(94780),h=i(20407),u=i(78653),d=i(74312),c=i(26821);function f(e){return(0,c.d6)("MuiTable",e)}(0,c.sI)("MuiTable",["root","colorPrimary","colorNeutral","colorDanger","colorSuccess","colorWarning","colorContext","variantPlain","variantOutlined","variantSoft","variantSolid","sizeSm","sizeMd","sizeLg","stickyHeader","stickyFooter","noWrap","hoverRow","borderAxisNone","borderAxisX","borderAxisXBetween","borderAxisY","borderAxisYBetween","borderAxisBoth","borderAxisBothBetween"]);var g=i(40911),p=i(30220),m=i(85893);let _=["className","component","children","borderAxis","hoverRow","noWrap","size","variant","color","stripe","stickyHeader","stickyFooter","slots","slotProps"],E=e=>{let{size:t,variant:i,color:n,borderAxis:r,stickyHeader:o,stickyFooter:s,noWrap:h,hoverRow:u}=e,d={root:["root",o&&"stickyHeader",s&&"stickyFooter",h&&"noWrap",u&&"hoverRow",r&&`borderAxis${(0,a.Z)(r)}`,i&&`variant${(0,a.Z)(i)}`,n&&`color${(0,a.Z)(n)}`,t&&`size${(0,a.Z)(t)}`]};return(0,l.Z)(d,f,{})},v={getColumnExceptFirst:()=>"& tr > *:not(:first-of-type), & tr > th + td, & tr > td + th",getCell:()=>"& th, & td",getHeadCell:()=>"& th",getHeaderCell:()=>"& thead th",getHeaderCellOfRow:e=>`& thead tr:nth-of-type(${e}) th`,getBottomHeaderCell:()=>"& thead th:not([colspan])",getHeaderNestedFirstColumn:()=>"& thead tr:not(:first-of-type) th:not([colspan]):first-of-type",getDataCell:()=>"& td",getDataCellExceptLastRow:()=>"& tr:not(:last-of-type) > td",getBodyCellExceptLastRow(){return`${this.getDataCellExceptLastRow()}, & tr:not(:last-of-type) > th[scope="row"]`},getBodyCellOfRow:e=>"number"==typeof e&&e<0?`& tbody tr:nth-last-of-type(${Math.abs(e)}) td, & tbody tr:nth-last-of-type(${Math.abs(e)}) th[scope="row"]`:`& tbody tr:nth-of-type(${e}) td, & tbody tr:nth-of-type(${e}) th[scope="row"]`,getBodyRow:e=>void 0===e?"& tbody tr":`& tbody tr:nth-of-type(${e})`,getFooterCell:()=>"& tfoot th, & tfoot td",getFooterFirstRowCell:()=>"& tfoot tr:not(:last-of-type) th, & tfoot tr:not(:last-of-type) td"},b=(0,d.Z)("table",{name:"JoyTable",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e,ownerState:t})=>{var i,n,o,s,a,l,h;let u=null==(i=e.variants[t.variant])?void 0:i[t.color];return[(0,r.Z)({"--Table-headerUnderlineThickness":"2px","--TableCell-borderColor":null!=(n=null==u?void 0:u.borderColor)?n:e.vars.palette.divider,"--TableCell-headBackground":`var(--Sheet-background, ${e.vars.palette.background.surface})`},"sm"===t.size&&{"--unstable_TableCell-height":"var(--TableCell-height, 32px)","--TableCell-paddingX":"0.25rem","--TableCell-paddingY":"0.25rem"},"md"===t.size&&{"--unstable_TableCell-height":"var(--TableCell-height, 40px)","--TableCell-paddingX":"0.5rem","--TableCell-paddingY":"0.375rem"},"lg"===t.size&&{"--unstable_TableCell-height":"var(--TableCell-height, 48px)","--TableCell-paddingX":"0.75rem","--TableCell-paddingY":"0.5rem"},{tableLayout:"fixed",width:"100%",borderSpacing:"0px",borderCollapse:"separate",borderRadius:"var(--TableCell-cornerRadius, var(--unstable_actionRadius))"},e.typography[`body-${({sm:"xs",md:"sm",lg:"md"})[t.size]}`],null==(o=e.variants[t.variant])?void 0:o[t.color],{"& caption":{color:e.vars.palette.text.tertiary,padding:"calc(2 * var(--TableCell-paddingY)) var(--TableCell-paddingX)"},[v.getDataCell()]:(0,r.Z)({padding:"var(--TableCell-paddingY) var(--TableCell-paddingX)",height:"var(--unstable_TableCell-height)",borderColor:"var(--TableCell-borderColor)",backgroundColor:"var(--TableCell-dataBackground)"},t.noWrap&&{textOverflow:"ellipsis",whiteSpace:"nowrap",overflow:"hidden"}),[v.getHeadCell()]:{textAlign:"left",padding:"var(--TableCell-paddingY) var(--TableCell-paddingX)",backgroundColor:"var(--TableCell-headBackground)",height:"var(--unstable_TableCell-height)",fontWeight:e.vars.fontWeight.lg,borderColor:"var(--TableCell-borderColor)",color:e.vars.palette.text.secondary,textOverflow:"ellipsis",whiteSpace:"nowrap",overflow:"hidden"},[v.getHeaderCell()]:{verticalAlign:"bottom","&:first-of-type":{borderTopLeftRadius:"var(--TableCell-cornerRadius, var(--unstable_actionRadius))"},"&:last-of-type":{borderTopRightRadius:"var(--TableCell-cornerRadius, var(--unstable_actionRadius))"}},"& tfoot tr > *":{backgroundColor:`var(--TableCell-footBackground, ${e.vars.palette.background.level1})`,"&:first-of-type":{borderBottomLeftRadius:"var(--TableCell-cornerRadius, var(--unstable_actionRadius))"},"&:last-of-type":{borderBottomRightRadius:"var(--TableCell-cornerRadius, var(--unstable_actionRadius))"}}}),((null==(s=t.borderAxis)?void 0:s.startsWith("x"))||(null==(a=t.borderAxis)?void 0:a.startsWith("both")))&&{[v.getHeaderCell()]:{borderBottomWidth:1,borderBottomStyle:"solid"},[v.getBottomHeaderCell()]:{borderBottomWidth:"var(--Table-headerUnderlineThickness)",borderBottomStyle:"solid"},[v.getBodyCellExceptLastRow()]:{borderBottomWidth:1,borderBottomStyle:"solid"},[v.getFooterCell()]:{borderTopWidth:1,borderTopStyle:"solid"}},((null==(l=t.borderAxis)?void 0:l.startsWith("y"))||(null==(h=t.borderAxis)?void 0:h.startsWith("both")))&&{[`${v.getColumnExceptFirst()}, ${v.getHeaderNestedFirstColumn()}`]:{borderLeftWidth:1,borderLeftStyle:"solid"}},("x"===t.borderAxis||"both"===t.borderAxis)&&{[v.getHeaderCellOfRow(1)]:{borderTopWidth:1,borderTopStyle:"solid"},[v.getBodyCellOfRow(-1)]:{borderBottomWidth:1,borderBottomStyle:"solid"},[v.getFooterCell()]:{borderBottomWidth:1,borderBottomStyle:"solid"}},("y"===t.borderAxis||"both"===t.borderAxis)&&{"& tr > *:first-of-type":{borderLeftWidth:1,borderLeftStyle:"solid"},"& tr > *:last-of-type:not(:first-of-type)":{borderRightWidth:1,borderRightStyle:"solid"}},t.stripe&&{[v.getBodyRow(t.stripe)]:{background:`var(--TableRow-stripeBackground, ${e.vars.palette.background.level2})`,color:e.vars.palette.text.primary}},t.hoverRow&&{[v.getBodyRow()]:{"&:hover":{background:`var(--TableRow-hoverBackground, ${e.vars.palette.background.level3})`}}},t.stickyHeader&&{[v.getHeaderCell()]:{position:"sticky",top:0,zIndex:e.vars.zIndex.table},[v.getHeaderCellOfRow(2)]:{top:"var(--unstable_TableCell-height)"}},t.stickyFooter&&{[v.getFooterCell()]:{position:"sticky",bottom:0,zIndex:e.vars.zIndex.table,color:e.vars.palette.text.secondary,fontWeight:e.vars.fontWeight.lg},[v.getFooterFirstRowCell()]:{bottom:"var(--unstable_TableCell-height)"}}]}),C=o.forwardRef(function(e,t){let i=(0,h.Z)({props:e,name:"JoyTable"}),{className:o,component:a,children:l,borderAxis:d="xBetween",hoverRow:c=!1,noWrap:f=!1,size:v="md",variant:C="plain",color:S="neutral",stripe:y,stickyHeader:T=!1,stickyFooter:R=!1,slots:A={},slotProps:N={}}=i,O=(0,n.Z)(i,_),{getColor:L}=(0,u.VT)(C),I=L(e.color,S),w=(0,r.Z)({},i,{borderAxis:d,hoverRow:c,noWrap:f,component:a,size:v,color:I,variant:C,stripe:y,stickyHeader:T,stickyFooter:R}),D=E(w),x=(0,r.Z)({},O,{component:a,slots:A,slotProps:N}),[M,k]=(0,p.Z)("root",{ref:t,className:(0,s.Z)(D.root,o),elementType:b,externalForwardedProps:x,ownerState:w});return(0,m.jsx)(g.eu.Provider,{value:!0,children:(0,m.jsx)(M,(0,r.Z)({},k,{children:l}))})});var S=C},40911:function(e,t,i){"use strict";i.d(t,{eu:function(){return b},ZP:function(){return N}});var n=i(63366),r=i(87462),o=i(67294),s=i(14142),a=i(18719),l=i(39707),h=i(94780),u=i(74312),d=i(20407),c=i(78653),f=i(30220),g=i(26821);function p(e){return(0,g.d6)("MuiTypography",e)}(0,g.sI)("MuiTypography",["root","h1","h2","h3","h4","title-lg","title-md","title-sm","body-lg","body-md","body-sm","body-xs","noWrap","gutterBottom","startDecorator","endDecorator","colorPrimary","colorNeutral","colorDanger","colorSuccess","colorWarning","colorContext","variantPlain","variantOutlined","variantSoft","variantSolid"]);var m=i(85893);let _=["color","textColor"],E=["component","gutterBottom","noWrap","level","levelMapping","children","endDecorator","startDecorator","variant","slots","slotProps"],v=o.createContext(!1),b=o.createContext(!1),C=e=>{let{gutterBottom:t,noWrap:i,level:n,color:r,variant:o}=e,a={root:["root",n,t&&"gutterBottom",i&&"noWrap",r&&`color${(0,s.Z)(r)}`,o&&`variant${(0,s.Z)(o)}`],startDecorator:["startDecorator"],endDecorator:["endDecorator"]};return(0,h.Z)(a,p,{})},S=(0,u.Z)("span",{name:"JoyTypography",slot:"StartDecorator",overridesResolver:(e,t)=>t.startDecorator})({display:"inline-flex",marginInlineEnd:"clamp(4px, var(--Typography-gap, 0.375em), 0.75rem)"}),y=(0,u.Z)("span",{name:"JoyTypography",slot:"endDecorator",overridesResolver:(e,t)=>t.endDecorator})({display:"inline-flex",marginInlineStart:"clamp(4px, var(--Typography-gap, 0.375em), 0.75rem)"}),T=(0,u.Z)("span",{name:"JoyTypography",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e,ownerState:t})=>{var i,n,o,s,a;let l="inherit"!==t.level?null==(i=e.typography[t.level])?void 0:i.lineHeight:"1";return(0,r.Z)({"--Icon-fontSize":`calc(1em * ${l})`},t.color&&{"--Icon-color":"currentColor"},{margin:"var(--Typography-margin, 0px)"},t.nesting?{display:"inline"}:(0,r.Z)({display:"block"},t.unstable_hasSkeleton&&{position:"relative"}),(t.startDecorator||t.endDecorator)&&(0,r.Z)({display:"flex",alignItems:"center"},t.nesting&&(0,r.Z)({display:"inline-flex"},t.startDecorator&&{verticalAlign:"bottom"})),t.level&&"inherit"!==t.level&&e.typography[t.level],{fontSize:`var(--Typography-fontSize, ${t.level&&"inherit"!==t.level&&null!=(n=null==(o=e.typography[t.level])?void 0:o.fontSize)?n:"inherit"})`},t.noWrap&&{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},t.gutterBottom&&{marginBottom:"0.35em"},t.color&&"context"!==t.color&&{color:`rgba(${null==(s=e.vars.palette[t.color])?void 0:s.mainChannel} / 1)`},t.variant&&(0,r.Z)({borderRadius:e.vars.radius.xs,paddingBlock:"min(0.1em, 4px)",paddingInline:"0.25em"},!t.nesting&&{marginInline:"-0.25em"},null==(a=e.variants[t.variant])?void 0:a[t.color]))}),R={h1:"h1",h2:"h2",h3:"h3",h4:"h4","title-lg":"p","title-md":"p","title-sm":"p","body-lg":"p","body-md":"p","body-sm":"p","body-xs":"span",inherit:"p"},A=o.forwardRef(function(e,t){let i=(0,d.Z)({props:e,name:"JoyTypography"}),{color:s,textColor:h}=i,u=(0,n.Z)(i,_),g=o.useContext(v),p=o.useContext(b),A=(0,l.Z)((0,r.Z)({},u,{color:h})),{component:N,gutterBottom:O=!1,noWrap:L=!1,level:I="body-md",levelMapping:w=R,children:D,endDecorator:x,startDecorator:M,variant:k,slots:P={},slotProps:F={}}=A,B=(0,n.Z)(A,E),{getColor:U}=(0,c.VT)(k),H=U(e.color,k?null!=s?s:"neutral":s),V=g||p?e.level||"inherit":I,W=(0,a.Z)(D,["Skeleton"]),G=N||(g?"span":w[V]||R[V]||"span"),j=(0,r.Z)({},A,{level:V,component:G,color:H,gutterBottom:O,noWrap:L,nesting:g,variant:k,unstable_hasSkeleton:W}),z=C(j),K=(0,r.Z)({},B,{component:G,slots:P,slotProps:F}),[Y,$]=(0,f.Z)("root",{ref:t,className:z.root,elementType:T,externalForwardedProps:K,ownerState:j}),[q,X]=(0,f.Z)("startDecorator",{className:z.startDecorator,elementType:S,externalForwardedProps:K,ownerState:j}),[Z,Q]=(0,f.Z)("endDecorator",{className:z.endDecorator,elementType:y,externalForwardedProps:K,ownerState:j});return(0,m.jsx)(v.Provider,{value:!0,children:(0,m.jsxs)(Y,(0,r.Z)({},$,{children:[M&&(0,m.jsx)(q,(0,r.Z)({},X,{children:M})),W?o.cloneElement(D,{variant:D.props.variant||"inline"}):D,x&&(0,m.jsx)(Z,(0,r.Z)({},Q,{children:x}))]}))})});A.muiName="Typography";var N=A},78653:function(e,t,i){"use strict";i.d(t,{VT:function(){return l},do:function(){return h}});var n=i(67294),r=i(38629),o=i(1812),s=i(85893);let a=n.createContext(void 0),l=e=>{let t=n.useContext(a);return{getColor:(i,n)=>t&&e&&t.includes(e)?i||"context":i||n}};function h({children:e,variant:t}){var i;let n=(0,r.F)();return(0,s.jsx)(a.Provider,{value:t?(null!=(i=n.colorInversionConfig)?i:o.Z.colorInversionConfig)[t]:void 0,children:e})}t.ZP=a},58859:function(e,t,i){"use strict";i.d(t,{V:function(){return r}});var n=i(87462);let r=({theme:e,ownerState:t},i)=>{let r={};return t.sx&&(function t(i){if("function"==typeof i){let n=i(e);t(n)}else Array.isArray(i)?i.forEach(e=>{"boolean"!=typeof e&&t(e)}):"object"==typeof i&&(r=(0,n.Z)({},r,i))}(t.sx),i.forEach(t=>{let i=r[t];if("string"==typeof i||"number"==typeof i){if("borderRadius"===t){if("number"==typeof i)r[t]=`${i}px`;else{var n;r[t]=(null==(n=e.vars)?void 0:n.radius[i])||i}}else -1!==["p","padding","m","margin"].indexOf(t)&&"number"==typeof i?r[t]=e.spacing(i):r[t]=i}else"function"==typeof i?r[t]=i(e):r[t]=void 0})),r}},74312:function(e,t,i){"use strict";var n=i(70182),r=i(1812),o=i(2548);let s=(0,n.ZP)({defaultTheme:r.Z,themeId:o.Z});t.Z=s},20407:function(e,t,i){"use strict";i.d(t,{Z:function(){return a}});var n=i(87462),r=i(39214),o=i(1812),s=i(2548);function a({props:e,name:t}){return(0,r.Z)({props:e,name:t,defaultTheme:(0,n.Z)({},o.Z,{components:{}}),themeId:s.Z})}},55907:function(e,t,i){"use strict";i.d(t,{Yb:function(){return a},yP:function(){return s}});var n=i(67294),r=i(85893);let o=n.createContext(void 0);function s(e,t){var i;let r,s;let a=n.useContext(o),[l,h]="string"==typeof a?a.split(":"):[],u=(i=l||void 0,r=h||void 0,s=i,"outlined"===i&&(r="neutral",s="plain"),"plain"===i&&(r="neutral"),{variant:s,color:r});return u.variant=e||u.variant,u.color=t||u.color,u}function a({children:e,color:t,variant:i}){return(0,r.jsx)(o.Provider,{value:`${i||""}:${t||""}`,children:e})}},30220:function(e,t,i){"use strict";i.d(t,{Z:function(){return g}});var n=i(87462),r=i(63366),o=i(33703),s=i(71276),a=i(24407),l=i(10238),h=i(78653);let u=["className","elementType","ownerState","externalForwardedProps","getSlotOwnerState","internalForwardedProps"],d=["component","slots","slotProps"],c=["component"],f=["disableColorInversion"];function g(e,t){let{className:i,elementType:g,ownerState:p,externalForwardedProps:m,getSlotOwnerState:_,internalForwardedProps:E}=t,v=(0,r.Z)(t,u),{component:b,slots:C={[e]:void 0},slotProps:S={[e]:void 0}}=m,y=(0,r.Z)(m,d),T=C[e]||g,R=(0,s.x)(S[e],p),A=(0,a.L)((0,n.Z)({className:i},v,{externalForwardedProps:"root"===e?y:void 0,externalSlotProps:R})),{props:{component:N},internalRef:O}=A,L=(0,r.Z)(A.props,c),I=(0,o.Z)(O,null==R?void 0:R.ref,t.ref),w=_?_(L):{},{disableColorInversion:D=!1}=w,x=(0,r.Z)(w,f),M=(0,n.Z)({},p,x),{getColor:k}=(0,h.VT)(M.variant);if("root"===e){var P;M.color=null!=(P=L.color)?P:p.color}else D||(M.color=k(L.color,M.color));let F="root"===e?N||b:N,B=(0,l.$)(T,(0,n.Z)({},"root"===e&&!b&&!C[e]&&E,"root"!==e&&!C[e]&&E,L,F&&{as:F},{ref:I}),M);return Object.keys(x).forEach(e=>{delete B[e]}),[T,B]}},39707:function(e,t,i){"use strict";i.d(t,{Z:function(){return h}});var n=i(87462),r=i(63366),o=i(59766),s=i(44920);let a=["sx"],l=e=>{var t,i;let n={systemProps:{},otherProps:{}},r=null!=(t=null==e||null==(i=e.theme)?void 0:i.unstable_sxConfig)?t:s.Z;return Object.keys(e).forEach(t=>{r[t]?n.systemProps[t]=e[t]:n.otherProps[t]=e[t]}),n};function h(e){let t;let{sx:i}=e,s=(0,r.Z)(e,a),{systemProps:h,otherProps:u}=l(s);return t=Array.isArray(i)?[h,...i]:"function"==typeof i?(...e)=>{let t=i(...e);return(0,o.P)(t)?(0,n.Z)({},h,t):h}:(0,n.Z)({},h,i),(0,n.Z)({},u,{sx:t})}},2093:function(e,t,i){"use strict";var n=i(97582),r=i(67294),o=i(92770);t.Z=function(e,t){(0,r.useEffect)(function(){var t=e(),i=!1;return!function(){(0,n.mG)(this,void 0,void 0,function(){return(0,n.Jh)(this,function(e){switch(e.label){case 0:if(!(0,o.mf)(t[Symbol.asyncIterator]))return[3,4];e.label=1;case 1:return[4,t.next()];case 2:if(e.sent().done||i)return[3,3];return[3,1];case 3:return[3,6];case 4:return[4,t];case 5:e.sent(),e.label=6;case 6:return[2]}})})}(),function(){i=!0}},t)}},15746:function(e,t,i){"use strict";var n=i(21584);t.Z=n.Z},71230:function(e,t,i){"use strict";var n=i(92820);t.Z=n.Z},87760:function(e,t){"use strict";var i={protan:{x:.7465,y:.2535,m:1.273463,yi:-.073894},deutan:{x:1.4,y:-.4,m:.968437,yi:.003331},tritan:{x:.1748,y:0,m:.062921,yi:.292119},custom:{x:.735,y:.265,m:-1.059259,yi:1.026914}},n=function(e){var t={},i=e.R/255,n=e.G/255,r=e.B/255;return i=i>.04045?Math.pow((i+.055)/1.055,2.4):i/12.92,n=n>.04045?Math.pow((n+.055)/1.055,2.4):n/12.92,r=r>.04045?Math.pow((r+.055)/1.055,2.4):r/12.92,t.X=.41242371206635076*i+.3575793401363035*n+.1804662232369621*r,t.Y=.21265606784927693*i+.715157818248362*n+.0721864539171564*r,t.Z=.019331987577444885*i+.11919267420354762*n+.9504491124870351*r,t},r=function(e){var t=e.X+e.Y+e.Z;return 0===t?{x:0,y:0,Y:e.Y}:{x:e.X/t,y:e.Y/t,Y:e.Y}};t.a=function(e,t,o){var s,a,l,h,u,d,c,f,g,p,m,_,E,v,b,C,S,y,T,R;return"achroma"===t?(s={R:s=.212656*e.R+.715158*e.G+.072186*e.B,G:s,B:s},o&&(l=(a=1.75)+1,s.R=(a*s.R+e.R)/l,s.G=(a*s.G+e.G)/l,s.B=(a*s.B+e.B)/l),s):(h=i[t],d=((u=r(n(e))).y-h.y)/(u.x-h.x),c=u.y-u.x*d,f=(h.yi-c)/(d-h.m),g=d*f+c,(s={}).X=f*u.Y/g,s.Y=u.Y,s.Z=(1-(f+g))*u.Y/g,y=.312713*u.Y/.329016,T=.358271*u.Y/.329016,_=3.240712470389558*(p=y-s.X)+-0+-.49857440415943116*(m=T-s.Z),E=-.969259258688888*p+0+.041556132211625726*m,v=.05563600315398933*p+-0+1.0570636917433989*m,s.R=3.240712470389558*s.X+-1.5372626602963142*s.Y+-.49857440415943116*s.Z,s.G=-.969259258688888*s.X+1.875996969313966*s.Y+.041556132211625726*s.Z,s.B=.05563600315398933*s.X+-.2039948802843549*s.Y+1.0570636917433989*s.Z,b=((s.R<0?0:1)-s.R)/_,C=((s.G<0?0:1)-s.G)/E,(S=(S=((s.B<0?0:1)-s.B)/v)>1||S<0?0:S)>(R=(b=b>1||b<0?0:b)>(C=C>1||C<0?0:C)?b:C)&&(R=S),s.R+=R*_,s.G+=R*E,s.B+=R*v,s.R=255*(s.R<=0?0:s.R>=1?1:Math.pow(s.R,.45454545454545453)),s.G=255*(s.G<=0?0:s.G>=1?1:Math.pow(s.G,.45454545454545453)),s.B=255*(s.B<=0?0:s.B>=1?1:Math.pow(s.B,.45454545454545453)),o&&(l=(a=1.75)+1,s.R=(a*s.R+e.R)/l,s.G=(a*s.G+e.G)/l,s.B=(a*s.B+e.B)/l),s)}},56917:function(e,t,i){"use strict";var n=i(74314),r=i(87760).a,o={protanomaly:{type:"protan",anomalize:!0},protanopia:{type:"protan"},deuteranomaly:{type:"deutan",anomalize:!0},deuteranopia:{type:"deutan"},tritanomaly:{type:"tritan",anomalize:!0},tritanopia:{type:"tritan"},achromatomaly:{type:"achroma",anomalize:!0},achromatopsia:{type:"achroma"}},s=function(e){return Math.round(255*e)},a=function(e){return function(t,i){var a=n(t);if(!a)return i?{R:0,G:0,B:0}:"#000000";var l=new r({R:s(a.red()||0),G:s(a.green()||0),B:s(a.blue()||0)},o[e].type,o[e].anomalize);return(l.R=l.R||0,l.G=l.G||0,l.B=l.B||0,i)?(delete l.X,delete l.Y,delete l.Z,l):new n.RGB(l.R%256/255,l.G%256/255,l.B%256/255,1).hex()}};for(var l in o)t[l]=a(l)},8874:function(e){"use strict";e.exports={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]}},19818:function(e,t,i){var n=i(8874),r=i(86851),o=Object.hasOwnProperty,s=Object.create(null);for(var a in n)o.call(n,a)&&(s[n[a]]=a);var l=e.exports={to:{},get:{}};function h(e,t,i){return Math.min(Math.max(t,e),i)}function u(e){var t=Math.round(e).toString(16).toUpperCase();return t.length<2?"0"+t:t}l.get=function(e){var t,i;switch(e.substring(0,3).toLowerCase()){case"hsl":t=l.get.hsl(e),i="hsl";break;case"hwb":t=l.get.hwb(e),i="hwb";break;default:t=l.get.rgb(e),i="rgb"}return t?{model:i,value:t}:null},l.get.rgb=function(e){if(!e)return null;var t,i,r,s=[0,0,0,1];if(t=e.match(/^#([a-f0-9]{6})([a-f0-9]{2})?$/i)){for(i=0,r=t[2],t=t[1];i<3;i++){var a=2*i;s[i]=parseInt(t.slice(a,a+2),16)}r&&(s[3]=parseInt(r,16)/255)}else if(t=e.match(/^#([a-f0-9]{3,4})$/i)){for(i=0,r=(t=t[1])[3];i<3;i++)s[i]=parseInt(t[i]+t[i],16);r&&(s[3]=parseInt(r+r,16)/255)}else if(t=e.match(/^rgba?\(\s*([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)\s*(?:[,|\/]\s*([+-]?[\d\.]+)(%?)\s*)?\)$/)){for(i=0;i<3;i++)s[i]=parseInt(t[i+1],0);t[4]&&(t[5]?s[3]=.01*parseFloat(t[4]):s[3]=parseFloat(t[4]))}else if(t=e.match(/^rgba?\(\s*([+-]?[\d\.]+)\%\s*,?\s*([+-]?[\d\.]+)\%\s*,?\s*([+-]?[\d\.]+)\%\s*(?:[,|\/]\s*([+-]?[\d\.]+)(%?)\s*)?\)$/)){for(i=0;i<3;i++)s[i]=Math.round(2.55*parseFloat(t[i+1]));t[4]&&(t[5]?s[3]=.01*parseFloat(t[4]):s[3]=parseFloat(t[4]))}else if(!(t=e.match(/^(\w+)$/)))return null;else return"transparent"===t[1]?[0,0,0,0]:o.call(n,t[1])?((s=n[t[1]])[3]=1,s):null;for(i=0;i<3;i++)s[i]=h(s[i],0,255);return s[3]=h(s[3],0,1),s},l.get.hsl=function(e){if(!e)return null;var t=e.match(/^hsla?\(\s*([+-]?(?:\d{0,3}\.)?\d+)(?:deg)?\s*,?\s*([+-]?[\d\.]+)%\s*,?\s*([+-]?[\d\.]+)%\s*(?:[,|\/]\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/);if(t){var i=parseFloat(t[4]);return[(parseFloat(t[1])%360+360)%360,h(parseFloat(t[2]),0,100),h(parseFloat(t[3]),0,100),h(isNaN(i)?1:i,0,1)]}return null},l.get.hwb=function(e){if(!e)return null;var t=e.match(/^hwb\(\s*([+-]?\d{0,3}(?:\.\d+)?)(?:deg)?\s*,\s*([+-]?[\d\.]+)%\s*,\s*([+-]?[\d\.]+)%\s*(?:,\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/);if(t){var i=parseFloat(t[4]);return[(parseFloat(t[1])%360+360)%360,h(parseFloat(t[2]),0,100),h(parseFloat(t[3]),0,100),h(isNaN(i)?1:i,0,1)]}return null},l.to.hex=function(){var e=r(arguments);return"#"+u(e[0])+u(e[1])+u(e[2])+(e[3]<1?u(Math.round(255*e[3])):"")},l.to.rgb=function(){var e=r(arguments);return e.length<4||1===e[3]?"rgb("+Math.round(e[0])+", "+Math.round(e[1])+", "+Math.round(e[2])+")":"rgba("+Math.round(e[0])+", "+Math.round(e[1])+", "+Math.round(e[2])+", "+e[3]+")"},l.to.rgb.percent=function(){var e=r(arguments),t=Math.round(e[0]/255*100),i=Math.round(e[1]/255*100),n=Math.round(e[2]/255*100);return e.length<4||1===e[3]?"rgb("+t+"%, "+i+"%, "+n+"%)":"rgba("+t+"%, "+i+"%, "+n+"%, "+e[3]+")"},l.to.hsl=function(){var e=r(arguments);return e.length<4||1===e[3]?"hsl("+e[0]+", "+e[1]+"%, "+e[2]+"%)":"hsla("+e[0]+", "+e[1]+"%, "+e[2]+"%, "+e[3]+")"},l.to.hwb=function(){var e=r(arguments),t="";return e.length>=4&&1!==e[3]&&(t=", "+e[3]),"hwb("+e[0]+", "+e[1]+"%, "+e[2]+"%"+t+")"},l.to.keyword=function(e){return s[e.slice(0,3)]}},26729:function(e){"use strict";var t=Object.prototype.hasOwnProperty,i="~";function n(){}function r(e,t,i){this.fn=e,this.context=t,this.once=i||!1}function o(e,t,n,o,s){if("function"!=typeof n)throw TypeError("The listener must be a function");var a=new r(n,o||e,s),l=i?i+t:t;return e._events[l]?e._events[l].fn?e._events[l]=[e._events[l],a]:e._events[l].push(a):(e._events[l]=a,e._eventsCount++),e}function s(e,t){0==--e._eventsCount?e._events=new n:delete e._events[t]}function a(){this._events=new n,this._eventsCount=0}Object.create&&(n.prototype=Object.create(null),new n().__proto__||(i=!1)),a.prototype.eventNames=function(){var e,n,r=[];if(0===this._eventsCount)return r;for(n in e=this._events)t.call(e,n)&&r.push(i?n.slice(1):n);return Object.getOwnPropertySymbols?r.concat(Object.getOwnPropertySymbols(e)):r},a.prototype.listeners=function(e){var t=i?i+e:e,n=this._events[t];if(!n)return[];if(n.fn)return[n.fn];for(var r=0,o=n.length,s=Array(o);rh+a*s*u||d>=p)g=s;else{if(Math.abs(f)<=-l*u)return s;f*(g-c)>=0&&(g=c),c=s,p=d}return 0}s=s||1,a=a||1e-6,l=l||.1;for(var m=0;m<10;++m){if(o(r.x,1,n.x,s,t),d=r.fx=e(r.x,r.fxprime),f=i(r.fxprime,t),d>h+a*s*u||m&&d>=c)return p(g,s,c);if(Math.abs(f)<=-l*u)break;if(f>=0)return p(s,g,d);c=d,g=s,s*=2}return s}e.bisect=function(e,t,i,n){var r=(n=n||{}).maxIterations||100,o=n.tolerance||1e-10,s=e(t),a=e(i),l=i-t;if(s*a>0)throw"Initial bisect points must have opposite signs";if(0===s)return t;if(0===a)return i;for(var h=0;h=0&&(t=u),Math.abs(l)=p[g-1].fx){var O=!1;if(C.fx>N.fx?(o(S,1+c,b,-c,N),S.fx=e(S),S.fx=1)break;for(m=1;m=n(d.fxprime))break}return a.history&&a.history.push({x:d.x.slice(),fx:d.fx,fxprime:d.fxprime.slice(),alpha:g}),d},e.gradientDescent=function(e,t,i){for(var r=(i=i||{}).maxIterations||100*t.length,s=i.learnRate||.001,a={x:t.slice(),fx:0,fxprime:t.slice()},l=0;l=n(a.fxprime)));++l);return a},e.gradientDescentLineSearch=function(e,t,i){i=i||{};var o,a={x:t.slice(),fx:0,fxprime:t.slice()},l={x:t.slice(),fx:0,fxprime:t.slice()},h=i.maxIterations||100*t.length,u=i.learnRate||1,d=t.slice(),c=i.c1||.001,f=i.c2||.1,g=[];if(i.history){var p=e;e=function(e,t){return g.push(e.slice()),p(e,t)}}a.fx=e(a.x,a.fxprime);for(var m=0;mn(a.fxprime)));++m);return a},e.zeros=t,e.zerosM=function(e,i){return t(e).map(function(){return t(i)})},e.norm2=n,e.weightedSum=o,e.scale=r}(t)},49685:function(e,t,i){"use strict";i.d(t,{Ib:function(){return n},WT:function(){return r}});var n=1e-6,r="undefined"!=typeof Float32Array?Float32Array:Array;Math.hypot||(Math.hypot=function(){for(var e=0,t=arguments.length;t--;)e+=arguments[t]*arguments[t];return Math.sqrt(e)})},35600:function(e,t,i){"use strict";i.d(t,{Ue:function(){return r},al:function(){return s},xO:function(){return o}});var n=i(49685);function r(){var e=new n.WT(9);return n.WT!=Float32Array&&(e[1]=0,e[2]=0,e[3]=0,e[5]=0,e[6]=0,e[7]=0),e[0]=1,e[4]=1,e[8]=1,e}function o(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[4],e[4]=t[5],e[5]=t[6],e[6]=t[8],e[7]=t[9],e[8]=t[10],e}function s(e,t,i,r,o,s,a,l,h){var u=new n.WT(9);return u[0]=e,u[1]=t,u[2]=i,u[3]=r,u[4]=o,u[5]=s,u[6]=a,u[7]=l,u[8]=h,u}},85975:function(e,t,i){"use strict";i.r(t),i.d(t,{add:function(){return Y},adjoint:function(){return c},clone:function(){return o},copy:function(){return s},create:function(){return r},determinant:function(){return f},equals:function(){return Q},exactEquals:function(){return Z},frob:function(){return K},fromQuat:function(){return M},fromQuat2:function(){return O},fromRotation:function(){return y},fromRotationTranslation:function(){return N},fromRotationTranslationScale:function(){return D},fromRotationTranslationScaleOrigin:function(){return x},fromScaling:function(){return S},fromTranslation:function(){return C},fromValues:function(){return a},fromXRotation:function(){return T},fromYRotation:function(){return R},fromZRotation:function(){return A},frustum:function(){return k},getRotation:function(){return w},getScaling:function(){return I},getTranslation:function(){return L},identity:function(){return h},invert:function(){return d},lookAt:function(){return G},mul:function(){return J},multiply:function(){return g},multiplyScalar:function(){return q},multiplyScalarAndAdd:function(){return X},ortho:function(){return V},orthoNO:function(){return H},orthoZO:function(){return W},perspective:function(){return F},perspectiveFromFieldOfView:function(){return U},perspectiveNO:function(){return P},perspectiveZO:function(){return B},rotate:function(){return _},rotateX:function(){return E},rotateY:function(){return v},rotateZ:function(){return b},scale:function(){return m},set:function(){return l},str:function(){return z},sub:function(){return ee},subtract:function(){return $},targetTo:function(){return j},translate:function(){return p},transpose:function(){return u}});var n=i(49685);function r(){var e=new n.WT(16);return n.WT!=Float32Array&&(e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[11]=0,e[12]=0,e[13]=0,e[14]=0),e[0]=1,e[5]=1,e[10]=1,e[15]=1,e}function o(e){var t=new n.WT(16);return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4],t[5]=e[5],t[6]=e[6],t[7]=e[7],t[8]=e[8],t[9]=e[9],t[10]=e[10],t[11]=e[11],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15],t}function s(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[8]=t[8],e[9]=t[9],e[10]=t[10],e[11]=t[11],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15],e}function a(e,t,i,r,o,s,a,l,h,u,d,c,f,g,p,m){var _=new n.WT(16);return _[0]=e,_[1]=t,_[2]=i,_[3]=r,_[4]=o,_[5]=s,_[6]=a,_[7]=l,_[8]=h,_[9]=u,_[10]=d,_[11]=c,_[12]=f,_[13]=g,_[14]=p,_[15]=m,_}function l(e,t,i,n,r,o,s,a,l,h,u,d,c,f,g,p,m){return e[0]=t,e[1]=i,e[2]=n,e[3]=r,e[4]=o,e[5]=s,e[6]=a,e[7]=l,e[8]=h,e[9]=u,e[10]=d,e[11]=c,e[12]=f,e[13]=g,e[14]=p,e[15]=m,e}function h(e){return e[0]=1,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=1,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=1,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e}function u(e,t){if(e===t){var i=t[1],n=t[2],r=t[3],o=t[6],s=t[7],a=t[11];e[1]=t[4],e[2]=t[8],e[3]=t[12],e[4]=i,e[6]=t[9],e[7]=t[13],e[8]=n,e[9]=o,e[11]=t[14],e[12]=r,e[13]=s,e[14]=a}else e[0]=t[0],e[1]=t[4],e[2]=t[8],e[3]=t[12],e[4]=t[1],e[5]=t[5],e[6]=t[9],e[7]=t[13],e[8]=t[2],e[9]=t[6],e[10]=t[10],e[11]=t[14],e[12]=t[3],e[13]=t[7],e[14]=t[11],e[15]=t[15];return e}function d(e,t){var i=t[0],n=t[1],r=t[2],o=t[3],s=t[4],a=t[5],l=t[6],h=t[7],u=t[8],d=t[9],c=t[10],f=t[11],g=t[12],p=t[13],m=t[14],_=t[15],E=i*a-n*s,v=i*l-r*s,b=i*h-o*s,C=n*l-r*a,S=n*h-o*a,y=r*h-o*l,T=u*p-d*g,R=u*m-c*g,A=u*_-f*g,N=d*m-c*p,O=d*_-f*p,L=c*_-f*m,I=E*L-v*O+b*N+C*A-S*R+y*T;return I?(I=1/I,e[0]=(a*L-l*O+h*N)*I,e[1]=(r*O-n*L-o*N)*I,e[2]=(p*y-m*S+_*C)*I,e[3]=(c*S-d*y-f*C)*I,e[4]=(l*A-s*L-h*R)*I,e[5]=(i*L-r*A+o*R)*I,e[6]=(m*b-g*y-_*v)*I,e[7]=(u*y-c*b+f*v)*I,e[8]=(s*O-a*A+h*T)*I,e[9]=(n*A-i*O-o*T)*I,e[10]=(g*S-p*b+_*E)*I,e[11]=(d*b-u*S-f*E)*I,e[12]=(a*R-s*N-l*T)*I,e[13]=(i*N-n*R+r*T)*I,e[14]=(p*v-g*C-m*E)*I,e[15]=(u*C-d*v+c*E)*I,e):null}function c(e,t){var i=t[0],n=t[1],r=t[2],o=t[3],s=t[4],a=t[5],l=t[6],h=t[7],u=t[8],d=t[9],c=t[10],f=t[11],g=t[12],p=t[13],m=t[14],_=t[15];return e[0]=a*(c*_-f*m)-d*(l*_-h*m)+p*(l*f-h*c),e[1]=-(n*(c*_-f*m)-d*(r*_-o*m)+p*(r*f-o*c)),e[2]=n*(l*_-h*m)-a*(r*_-o*m)+p*(r*h-o*l),e[3]=-(n*(l*f-h*c)-a*(r*f-o*c)+d*(r*h-o*l)),e[4]=-(s*(c*_-f*m)-u*(l*_-h*m)+g*(l*f-h*c)),e[5]=i*(c*_-f*m)-u*(r*_-o*m)+g*(r*f-o*c),e[6]=-(i*(l*_-h*m)-s*(r*_-o*m)+g*(r*h-o*l)),e[7]=i*(l*f-h*c)-s*(r*f-o*c)+u*(r*h-o*l),e[8]=s*(d*_-f*p)-u*(a*_-h*p)+g*(a*f-h*d),e[9]=-(i*(d*_-f*p)-u*(n*_-o*p)+g*(n*f-o*d)),e[10]=i*(a*_-h*p)-s*(n*_-o*p)+g*(n*h-o*a),e[11]=-(i*(a*f-h*d)-s*(n*f-o*d)+u*(n*h-o*a)),e[12]=-(s*(d*m-c*p)-u*(a*m-l*p)+g*(a*c-l*d)),e[13]=i*(d*m-c*p)-u*(n*m-r*p)+g*(n*c-r*d),e[14]=-(i*(a*m-l*p)-s*(n*m-r*p)+g*(n*l-r*a)),e[15]=i*(a*c-l*d)-s*(n*c-r*d)+u*(n*l-r*a),e}function f(e){var t=e[0],i=e[1],n=e[2],r=e[3],o=e[4],s=e[5],a=e[6],l=e[7],h=e[8],u=e[9],d=e[10],c=e[11],f=e[12],g=e[13],p=e[14],m=e[15];return(t*s-i*o)*(d*m-c*p)-(t*a-n*o)*(u*m-c*g)+(t*l-r*o)*(u*p-d*g)+(i*a-n*s)*(h*m-c*f)-(i*l-r*s)*(h*p-d*f)+(n*l-r*a)*(h*g-u*f)}function g(e,t,i){var n=t[0],r=t[1],o=t[2],s=t[3],a=t[4],l=t[5],h=t[6],u=t[7],d=t[8],c=t[9],f=t[10],g=t[11],p=t[12],m=t[13],_=t[14],E=t[15],v=i[0],b=i[1],C=i[2],S=i[3];return e[0]=v*n+b*a+C*d+S*p,e[1]=v*r+b*l+C*c+S*m,e[2]=v*o+b*h+C*f+S*_,e[3]=v*s+b*u+C*g+S*E,v=i[4],b=i[5],C=i[6],S=i[7],e[4]=v*n+b*a+C*d+S*p,e[5]=v*r+b*l+C*c+S*m,e[6]=v*o+b*h+C*f+S*_,e[7]=v*s+b*u+C*g+S*E,v=i[8],b=i[9],C=i[10],S=i[11],e[8]=v*n+b*a+C*d+S*p,e[9]=v*r+b*l+C*c+S*m,e[10]=v*o+b*h+C*f+S*_,e[11]=v*s+b*u+C*g+S*E,v=i[12],b=i[13],C=i[14],S=i[15],e[12]=v*n+b*a+C*d+S*p,e[13]=v*r+b*l+C*c+S*m,e[14]=v*o+b*h+C*f+S*_,e[15]=v*s+b*u+C*g+S*E,e}function p(e,t,i){var n,r,o,s,a,l,h,u,d,c,f,g,p=i[0],m=i[1],_=i[2];return t===e?(e[12]=t[0]*p+t[4]*m+t[8]*_+t[12],e[13]=t[1]*p+t[5]*m+t[9]*_+t[13],e[14]=t[2]*p+t[6]*m+t[10]*_+t[14],e[15]=t[3]*p+t[7]*m+t[11]*_+t[15]):(n=t[0],r=t[1],o=t[2],s=t[3],a=t[4],l=t[5],h=t[6],u=t[7],d=t[8],c=t[9],f=t[10],g=t[11],e[0]=n,e[1]=r,e[2]=o,e[3]=s,e[4]=a,e[5]=l,e[6]=h,e[7]=u,e[8]=d,e[9]=c,e[10]=f,e[11]=g,e[12]=n*p+a*m+d*_+t[12],e[13]=r*p+l*m+c*_+t[13],e[14]=o*p+h*m+f*_+t[14],e[15]=s*p+u*m+g*_+t[15]),e}function m(e,t,i){var n=i[0],r=i[1],o=i[2];return e[0]=t[0]*n,e[1]=t[1]*n,e[2]=t[2]*n,e[3]=t[3]*n,e[4]=t[4]*r,e[5]=t[5]*r,e[6]=t[6]*r,e[7]=t[7]*r,e[8]=t[8]*o,e[9]=t[9]*o,e[10]=t[10]*o,e[11]=t[11]*o,e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15],e}function _(e,t,i,r){var o,s,a,l,h,u,d,c,f,g,p,m,_,E,v,b,C,S,y,T,R,A,N,O,L=r[0],I=r[1],w=r[2],D=Math.hypot(L,I,w);return D0?(i[0]=(l*a+d*r+h*s-u*o)*2/c,i[1]=(h*a+d*o+u*r-l*s)*2/c,i[2]=(u*a+d*s+l*o-h*r)*2/c):(i[0]=(l*a+d*r+h*s-u*o)*2,i[1]=(h*a+d*o+u*r-l*s)*2,i[2]=(u*a+d*s+l*o-h*r)*2),N(e,t,i),e}function L(e,t){return e[0]=t[12],e[1]=t[13],e[2]=t[14],e}function I(e,t){var i=t[0],n=t[1],r=t[2],o=t[4],s=t[5],a=t[6],l=t[8],h=t[9],u=t[10];return e[0]=Math.hypot(i,n,r),e[1]=Math.hypot(o,s,a),e[2]=Math.hypot(l,h,u),e}function w(e,t){var i=new n.WT(3);I(i,t);var r=1/i[0],o=1/i[1],s=1/i[2],a=t[0]*r,l=t[1]*o,h=t[2]*s,u=t[4]*r,d=t[5]*o,c=t[6]*s,f=t[8]*r,g=t[9]*o,p=t[10]*s,m=a+d+p,_=0;return m>0?(_=2*Math.sqrt(m+1),e[3]=.25*_,e[0]=(c-g)/_,e[1]=(f-h)/_,e[2]=(l-u)/_):a>d&&a>p?(_=2*Math.sqrt(1+a-d-p),e[3]=(c-g)/_,e[0]=.25*_,e[1]=(l+u)/_,e[2]=(f+h)/_):d>p?(_=2*Math.sqrt(1+d-a-p),e[3]=(f-h)/_,e[0]=(l+u)/_,e[1]=.25*_,e[2]=(c+g)/_):(_=2*Math.sqrt(1+p-a-d),e[3]=(l-u)/_,e[0]=(f+h)/_,e[1]=(c+g)/_,e[2]=.25*_),e}function D(e,t,i,n){var r=t[0],o=t[1],s=t[2],a=t[3],l=r+r,h=o+o,u=s+s,d=r*l,c=r*h,f=r*u,g=o*h,p=o*u,m=s*u,_=a*l,E=a*h,v=a*u,b=n[0],C=n[1],S=n[2];return e[0]=(1-(g+m))*b,e[1]=(c+v)*b,e[2]=(f-E)*b,e[3]=0,e[4]=(c-v)*C,e[5]=(1-(d+m))*C,e[6]=(p+_)*C,e[7]=0,e[8]=(f+E)*S,e[9]=(p-_)*S,e[10]=(1-(d+g))*S,e[11]=0,e[12]=i[0],e[13]=i[1],e[14]=i[2],e[15]=1,e}function x(e,t,i,n,r){var o=t[0],s=t[1],a=t[2],l=t[3],h=o+o,u=s+s,d=a+a,c=o*h,f=o*u,g=o*d,p=s*u,m=s*d,_=a*d,E=l*h,v=l*u,b=l*d,C=n[0],S=n[1],y=n[2],T=r[0],R=r[1],A=r[2],N=(1-(p+_))*C,O=(f+b)*C,L=(g-v)*C,I=(f-b)*S,w=(1-(c+_))*S,D=(m+E)*S,x=(g+v)*y,M=(m-E)*y,k=(1-(c+p))*y;return e[0]=N,e[1]=O,e[2]=L,e[3]=0,e[4]=I,e[5]=w,e[6]=D,e[7]=0,e[8]=x,e[9]=M,e[10]=k,e[11]=0,e[12]=i[0]+T-(N*T+I*R+x*A),e[13]=i[1]+R-(O*T+w*R+M*A),e[14]=i[2]+A-(L*T+D*R+k*A),e[15]=1,e}function M(e,t){var i=t[0],n=t[1],r=t[2],o=t[3],s=i+i,a=n+n,l=r+r,h=i*s,u=n*s,d=n*a,c=r*s,f=r*a,g=r*l,p=o*s,m=o*a,_=o*l;return e[0]=1-d-g,e[1]=u+_,e[2]=c-m,e[3]=0,e[4]=u-_,e[5]=1-h-g,e[6]=f+p,e[7]=0,e[8]=c+m,e[9]=f-p,e[10]=1-h-d,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e}function k(e,t,i,n,r,o,s){var a=1/(i-t),l=1/(r-n),h=1/(o-s);return e[0]=2*o*a,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=2*o*l,e[6]=0,e[7]=0,e[8]=(i+t)*a,e[9]=(r+n)*l,e[10]=(s+o)*h,e[11]=-1,e[12]=0,e[13]=0,e[14]=s*o*2*h,e[15]=0,e}function P(e,t,i,n,r){var o,s=1/Math.tan(t/2);return e[0]=s/i,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=s,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[11]=-1,e[12]=0,e[13]=0,e[15]=0,null!=r&&r!==1/0?(o=1/(n-r),e[10]=(r+n)*o,e[14]=2*r*n*o):(e[10]=-1,e[14]=-2*n),e}var F=P;function B(e,t,i,n,r){var o,s=1/Math.tan(t/2);return e[0]=s/i,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=s,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[11]=-1,e[12]=0,e[13]=0,e[15]=0,null!=r&&r!==1/0?(o=1/(n-r),e[10]=r*o,e[14]=r*n*o):(e[10]=-1,e[14]=-n),e}function U(e,t,i,n){var r=Math.tan(t.upDegrees*Math.PI/180),o=Math.tan(t.downDegrees*Math.PI/180),s=Math.tan(t.leftDegrees*Math.PI/180),a=Math.tan(t.rightDegrees*Math.PI/180),l=2/(s+a),h=2/(r+o);return e[0]=l,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=h,e[6]=0,e[7]=0,e[8]=-((s-a)*l*.5),e[9]=(r-o)*h*.5,e[10]=n/(i-n),e[11]=-1,e[12]=0,e[13]=0,e[14]=n*i/(i-n),e[15]=0,e}function H(e,t,i,n,r,o,s){var a=1/(t-i),l=1/(n-r),h=1/(o-s);return e[0]=-2*a,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=-2*l,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=2*h,e[11]=0,e[12]=(t+i)*a,e[13]=(r+n)*l,e[14]=(s+o)*h,e[15]=1,e}var V=H;function W(e,t,i,n,r,o,s){var a=1/(t-i),l=1/(n-r),h=1/(o-s);return e[0]=-2*a,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=-2*l,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=h,e[11]=0,e[12]=(t+i)*a,e[13]=(r+n)*l,e[14]=o*h,e[15]=1,e}function G(e,t,i,r){var o,s,a,l,u,d,c,f,g,p,m=t[0],_=t[1],E=t[2],v=r[0],b=r[1],C=r[2],S=i[0],y=i[1],T=i[2];return Math.abs(m-S)0&&(u*=f=1/Math.sqrt(f),d*=f,c*=f);var g=l*c-h*d,p=h*u-a*c,m=a*d-l*u;return(f=g*g+p*p+m*m)>0&&(g*=f=1/Math.sqrt(f),p*=f,m*=f),e[0]=g,e[1]=p,e[2]=m,e[3]=0,e[4]=d*m-c*p,e[5]=c*g-u*m,e[6]=u*p-d*g,e[7]=0,e[8]=u,e[9]=d,e[10]=c,e[11]=0,e[12]=r,e[13]=o,e[14]=s,e[15]=1,e}function z(e){return"mat4("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+", "+e[4]+", "+e[5]+", "+e[6]+", "+e[7]+", "+e[8]+", "+e[9]+", "+e[10]+", "+e[11]+", "+e[12]+", "+e[13]+", "+e[14]+", "+e[15]+")"}function K(e){return Math.hypot(e[0],e[1],e[2],e[3],e[4],e[5],e[6],e[7],e[8],e[9],e[10],e[11],e[12],e[13],e[14],e[15])}function Y(e,t,i){return e[0]=t[0]+i[0],e[1]=t[1]+i[1],e[2]=t[2]+i[2],e[3]=t[3]+i[3],e[4]=t[4]+i[4],e[5]=t[5]+i[5],e[6]=t[6]+i[6],e[7]=t[7]+i[7],e[8]=t[8]+i[8],e[9]=t[9]+i[9],e[10]=t[10]+i[10],e[11]=t[11]+i[11],e[12]=t[12]+i[12],e[13]=t[13]+i[13],e[14]=t[14]+i[14],e[15]=t[15]+i[15],e}function $(e,t,i){return e[0]=t[0]-i[0],e[1]=t[1]-i[1],e[2]=t[2]-i[2],e[3]=t[3]-i[3],e[4]=t[4]-i[4],e[5]=t[5]-i[5],e[6]=t[6]-i[6],e[7]=t[7]-i[7],e[8]=t[8]-i[8],e[9]=t[9]-i[9],e[10]=t[10]-i[10],e[11]=t[11]-i[11],e[12]=t[12]-i[12],e[13]=t[13]-i[13],e[14]=t[14]-i[14],e[15]=t[15]-i[15],e}function q(e,t,i){return e[0]=t[0]*i,e[1]=t[1]*i,e[2]=t[2]*i,e[3]=t[3]*i,e[4]=t[4]*i,e[5]=t[5]*i,e[6]=t[6]*i,e[7]=t[7]*i,e[8]=t[8]*i,e[9]=t[9]*i,e[10]=t[10]*i,e[11]=t[11]*i,e[12]=t[12]*i,e[13]=t[13]*i,e[14]=t[14]*i,e[15]=t[15]*i,e}function X(e,t,i,n){return e[0]=t[0]+i[0]*n,e[1]=t[1]+i[1]*n,e[2]=t[2]+i[2]*n,e[3]=t[3]+i[3]*n,e[4]=t[4]+i[4]*n,e[5]=t[5]+i[5]*n,e[6]=t[6]+i[6]*n,e[7]=t[7]+i[7]*n,e[8]=t[8]+i[8]*n,e[9]=t[9]+i[9]*n,e[10]=t[10]+i[10]*n,e[11]=t[11]+i[11]*n,e[12]=t[12]+i[12]*n,e[13]=t[13]+i[13]*n,e[14]=t[14]+i[14]*n,e[15]=t[15]+i[15]*n,e}function Z(e,t){return e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]&&e[3]===t[3]&&e[4]===t[4]&&e[5]===t[5]&&e[6]===t[6]&&e[7]===t[7]&&e[8]===t[8]&&e[9]===t[9]&&e[10]===t[10]&&e[11]===t[11]&&e[12]===t[12]&&e[13]===t[13]&&e[14]===t[14]&&e[15]===t[15]}function Q(e,t){var i=e[0],r=e[1],o=e[2],s=e[3],a=e[4],l=e[5],h=e[6],u=e[7],d=e[8],c=e[9],f=e[10],g=e[11],p=e[12],m=e[13],_=e[14],E=e[15],v=t[0],b=t[1],C=t[2],S=t[3],y=t[4],T=t[5],R=t[6],A=t[7],N=t[8],O=t[9],L=t[10],I=t[11],w=t[12],D=t[13],x=t[14],M=t[15];return Math.abs(i-v)<=n.Ib*Math.max(1,Math.abs(i),Math.abs(v))&&Math.abs(r-b)<=n.Ib*Math.max(1,Math.abs(r),Math.abs(b))&&Math.abs(o-C)<=n.Ib*Math.max(1,Math.abs(o),Math.abs(C))&&Math.abs(s-S)<=n.Ib*Math.max(1,Math.abs(s),Math.abs(S))&&Math.abs(a-y)<=n.Ib*Math.max(1,Math.abs(a),Math.abs(y))&&Math.abs(l-T)<=n.Ib*Math.max(1,Math.abs(l),Math.abs(T))&&Math.abs(h-R)<=n.Ib*Math.max(1,Math.abs(h),Math.abs(R))&&Math.abs(u-A)<=n.Ib*Math.max(1,Math.abs(u),Math.abs(A))&&Math.abs(d-N)<=n.Ib*Math.max(1,Math.abs(d),Math.abs(N))&&Math.abs(c-O)<=n.Ib*Math.max(1,Math.abs(c),Math.abs(O))&&Math.abs(f-L)<=n.Ib*Math.max(1,Math.abs(f),Math.abs(L))&&Math.abs(g-I)<=n.Ib*Math.max(1,Math.abs(g),Math.abs(I))&&Math.abs(p-w)<=n.Ib*Math.max(1,Math.abs(p),Math.abs(w))&&Math.abs(m-D)<=n.Ib*Math.max(1,Math.abs(m),Math.abs(D))&&Math.abs(_-x)<=n.Ib*Math.max(1,Math.abs(_),Math.abs(x))&&Math.abs(E-M)<=n.Ib*Math.max(1,Math.abs(E),Math.abs(M))}var J=g,ee=$},32945:function(e,t,i){"use strict";i.d(t,{Fv:function(){return p},JG:function(){return f},Jp:function(){return h},Su:function(){return d},U_:function(){return u},Ue:function(){return a},al:function(){return c},dC:function(){return g},yY:function(){return l}});var n=i(49685),r=i(35600),o=i(77160),s=i(98333);function a(){var e=new n.WT(4);return n.WT!=Float32Array&&(e[0]=0,e[1]=0,e[2]=0),e[3]=1,e}function l(e,t,i){var n=Math.sin(i*=.5);return e[0]=n*t[0],e[1]=n*t[1],e[2]=n*t[2],e[3]=Math.cos(i),e}function h(e,t,i){var n=t[0],r=t[1],o=t[2],s=t[3],a=i[0],l=i[1],h=i[2],u=i[3];return e[0]=n*u+s*a+r*h-o*l,e[1]=r*u+s*l+o*a-n*h,e[2]=o*u+s*h+n*l-r*a,e[3]=s*u-n*a-r*l-o*h,e}function u(e,t){var i=t[0],n=t[1],r=t[2],o=t[3],s=i*i+n*n+r*r+o*o,a=s?1/s:0;return e[0]=-i*a,e[1]=-n*a,e[2]=-r*a,e[3]=o*a,e}function d(e,t,i,n){var r=.5*Math.PI/180,o=Math.sin(t*=r),s=Math.cos(t),a=Math.sin(i*=r),l=Math.cos(i),h=Math.sin(n*=r),u=Math.cos(n);return e[0]=o*l*u-s*a*h,e[1]=s*a*u+o*l*h,e[2]=s*l*h-o*a*u,e[3]=s*l*u+o*a*h,e}s.d9;var c=s.al,f=s.JG;s.t8,s.IH;var g=h;s.bA,s.AK,s.t7,s.kE,s.we;var p=s.Fv;s.I6,s.fS,o.Ue(),o.al(1,0,0),o.al(0,1,0),a(),a(),r.Ue()},31437:function(e,t,i){"use strict";i.d(t,{AK:function(){return l},Fv:function(){return a},I6:function(){return h},JG:function(){return s},al:function(){return o}});var n,r=i(49685);function o(e,t){var i=new r.WT(2);return i[0]=e,i[1]=t,i}function s(e,t){return e[0]=t[0],e[1]=t[1],e}function a(e,t){var i=t[0],n=t[1],r=i*i+n*n;return r>0&&(r=1/Math.sqrt(r)),e[0]=t[0]*r,e[1]=t[1]*r,e}function l(e,t){return e[0]*t[0]+e[1]*t[1]}function h(e,t){return e[0]===t[0]&&e[1]===t[1]}n=new r.WT(2),r.WT!=Float32Array&&(n[0]=0,n[1]=0)},77160:function(e,t,i){"use strict";i.d(t,{$X:function(){return d},AK:function(){return p},Fv:function(){return g},IH:function(){return u},JG:function(){return l},Jp:function(){return c},TK:function(){return S},Ue:function(){return r},VC:function(){return b},Zh:function(){return y},al:function(){return a},bA:function(){return f},d9:function(){return o},fF:function(){return E},fS:function(){return C},kC:function(){return m},kE:function(){return s},kK:function(){return v},t7:function(){return _},t8:function(){return h}});var n=i(49685);function r(){var e=new n.WT(3);return n.WT!=Float32Array&&(e[0]=0,e[1]=0,e[2]=0),e}function o(e){var t=new n.WT(3);return t[0]=e[0],t[1]=e[1],t[2]=e[2],t}function s(e){return Math.hypot(e[0],e[1],e[2])}function a(e,t,i){var r=new n.WT(3);return r[0]=e,r[1]=t,r[2]=i,r}function l(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e}function h(e,t,i,n){return e[0]=t,e[1]=i,e[2]=n,e}function u(e,t,i){return e[0]=t[0]+i[0],e[1]=t[1]+i[1],e[2]=t[2]+i[2],e}function d(e,t,i){return e[0]=t[0]-i[0],e[1]=t[1]-i[1],e[2]=t[2]-i[2],e}function c(e,t,i){return e[0]=t[0]*i[0],e[1]=t[1]*i[1],e[2]=t[2]*i[2],e}function f(e,t,i){return e[0]=t[0]*i,e[1]=t[1]*i,e[2]=t[2]*i,e}function g(e,t){var i=t[0],n=t[1],r=t[2],o=i*i+n*n+r*r;return o>0&&(o=1/Math.sqrt(o)),e[0]=t[0]*o,e[1]=t[1]*o,e[2]=t[2]*o,e}function p(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]}function m(e,t,i){var n=t[0],r=t[1],o=t[2],s=i[0],a=i[1],l=i[2];return e[0]=r*l-o*a,e[1]=o*s-n*l,e[2]=n*a-r*s,e}function _(e,t,i,n){var r=t[0],o=t[1],s=t[2];return e[0]=r+n*(i[0]-r),e[1]=o+n*(i[1]-o),e[2]=s+n*(i[2]-s),e}function E(e,t,i){var n=t[0],r=t[1],o=t[2],s=i[3]*n+i[7]*r+i[11]*o+i[15];return s=s||1,e[0]=(i[0]*n+i[4]*r+i[8]*o+i[12])/s,e[1]=(i[1]*n+i[5]*r+i[9]*o+i[13])/s,e[2]=(i[2]*n+i[6]*r+i[10]*o+i[14])/s,e}function v(e,t,i){var n=t[0],r=t[1],o=t[2];return e[0]=n*i[0]+r*i[3]+o*i[6],e[1]=n*i[1]+r*i[4]+o*i[7],e[2]=n*i[2]+r*i[5]+o*i[8],e}function b(e,t,i){var n=i[0],r=i[1],o=i[2],s=i[3],a=t[0],l=t[1],h=t[2],u=r*h-o*l,d=o*a-n*h,c=n*l-r*a,f=r*c-o*d,g=o*u-n*c,p=n*d-r*u,m=2*s;return u*=m,d*=m,c*=m,f*=2,g*=2,p*=2,e[0]=a+u+f,e[1]=l+d+g,e[2]=h+c+p,e}function C(e,t){var i=e[0],r=e[1],o=e[2],s=t[0],a=t[1],l=t[2];return Math.abs(i-s)<=n.Ib*Math.max(1,Math.abs(i),Math.abs(s))&&Math.abs(r-a)<=n.Ib*Math.max(1,Math.abs(r),Math.abs(a))&&Math.abs(o-l)<=n.Ib*Math.max(1,Math.abs(o),Math.abs(l))}var S=function(e,t){return Math.hypot(t[0]-e[0],t[1]-e[1],t[2]-e[2])},y=s;r()},98333:function(e,t,i){"use strict";i.d(t,{AK:function(){return g},Fv:function(){return f},I6:function(){return _},IH:function(){return h},JG:function(){return a},Ue:function(){return r},al:function(){return s},bA:function(){return u},d9:function(){return o},fF:function(){return m},fS:function(){return E},kE:function(){return d},t7:function(){return p},t8:function(){return l},we:function(){return c}});var n=i(49685);function r(){var e=new n.WT(4);return n.WT!=Float32Array&&(e[0]=0,e[1]=0,e[2]=0,e[3]=0),e}function o(e){var t=new n.WT(4);return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t}function s(e,t,i,r){var o=new n.WT(4);return o[0]=e,o[1]=t,o[2]=i,o[3]=r,o}function a(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e}function l(e,t,i,n,r){return e[0]=t,e[1]=i,e[2]=n,e[3]=r,e}function h(e,t,i){return e[0]=t[0]+i[0],e[1]=t[1]+i[1],e[2]=t[2]+i[2],e[3]=t[3]+i[3],e}function u(e,t,i){return e[0]=t[0]*i,e[1]=t[1]*i,e[2]=t[2]*i,e[3]=t[3]*i,e}function d(e){return Math.hypot(e[0],e[1],e[2],e[3])}function c(e){var t=e[0],i=e[1],n=e[2],r=e[3];return t*t+i*i+n*n+r*r}function f(e,t){var i=t[0],n=t[1],r=t[2],o=t[3],s=i*i+n*n+r*r+o*o;return s>0&&(s=1/Math.sqrt(s)),e[0]=i*s,e[1]=n*s,e[2]=r*s,e[3]=o*s,e}function g(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]+e[3]*t[3]}function p(e,t,i,n){var r=t[0],o=t[1],s=t[2],a=t[3];return e[0]=r+n*(i[0]-r),e[1]=o+n*(i[1]-o),e[2]=s+n*(i[2]-s),e[3]=a+n*(i[3]-a),e}function m(e,t,i){var n=t[0],r=t[1],o=t[2],s=t[3];return e[0]=i[0]*n+i[4]*r+i[8]*o+i[12]*s,e[1]=i[1]*n+i[5]*r+i[9]*o+i[13]*s,e[2]=i[2]*n+i[6]*r+i[10]*o+i[14]*s,e[3]=i[3]*n+i[7]*r+i[11]*o+i[15]*s,e}function _(e,t){return e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]&&e[3]===t[3]}function E(e,t){var i=e[0],r=e[1],o=e[2],s=e[3],a=t[0],l=t[1],h=t[2],u=t[3];return Math.abs(i-a)<=n.Ib*Math.max(1,Math.abs(i),Math.abs(a))&&Math.abs(r-l)<=n.Ib*Math.max(1,Math.abs(r),Math.abs(l))&&Math.abs(o-h)<=n.Ib*Math.max(1,Math.abs(o),Math.abs(h))&&Math.abs(s-u)<=n.Ib*Math.max(1,Math.abs(s),Math.abs(u))}r()},9488:function(e,t,i){"use strict";var n,r;function o(e,t=0){return e[e.length-(1+t)]}function s(e){if(0===e.length)throw Error("Invalid tail call");return[e.slice(0,e.length-1),e[e.length-1]]}function a(e,t,i=(e,t)=>e===t){if(e===t)return!0;if(!e||!t||e.length!==t.length)return!1;for(let n=0,r=e.length;n0))return e;n=e-1}}return-(i+1)}(e.length,n=>i(e[n],t))}function u(e){return e.filter(e=>!!e)}function d(e){return!Array.isArray(e)||0===e.length}function c(e){return Array.isArray(e)&&e.length>0}function f(e,t=e=>e){let i=new Set;return e.filter(e=>{let n=t(e);return!i.has(n)&&(i.add(n),!0)})}function g(e,t){let i=function(e,t){for(let i=e.length-1;i>=0;i--){let n=e[i];if(t(n))return i}return -1}(e,t);if(-1!==i)return e[i]}function p(e,t){return e.length>0?e[0]:t}function m(e,t){let i="number"==typeof t?e:0;"number"==typeof t?i=e:(i=0,t=e);let n=[];if(i<=t)for(let e=i;et;e--)n.push(e);return n}function _(e,t,i){let n=e.slice(0,t),r=e.slice(t);return n.concat(i,r)}function E(e,t){let i=e.indexOf(t);i>-1&&(e.splice(i,1),e.unshift(t))}function v(e,t){let i=e.indexOf(t);i>-1&&(e.splice(i,1),e.push(t))}function b(e,t){for(let i of t)e.push(i)}function C(e,t,i,n){let r=S(e,t),o=e.splice(r,i);return!function(e,t,i){let n=S(e,t),r=e.length,o=i.length;e.length=r+o;for(let t=r-1;t>=n;t--)e[t+o]=e[t];for(let t=0;tt(e(i),e(n))}function T(e,t){if(0===e.length)return;let i=e[0];for(let n=1;n=0&&(i=r)}return i}function R(e,t){return function(e,t){if(0===e.length)return;let i=e[0];for(let n=1;n0&&(i=r)}return i}(e,(e,i)=>-t(e,i))}i.d(t,{EB:function(){return f},Gb:function(){return o},H9:function(){return A},JH:function(){return s},LS:function(){return l},Of:function(){return c},VJ:function(){return R},W$:function(){return N},XY:function(){return d},Xh:function(){return p},Zv:function(){return _},al:function(){return v},dF:function(){return g},db:function(){return C},fS:function(){return a},jV:function(){return T},kX:function(){return u},ry:function(){return h},tT:function(){return y},vA:function(){return b},w6:function(){return m},zI:function(){return E}}),(r=n||(n={})).isLessThan=function(e){return e<0},r.isGreaterThan=function(e){return e>0},r.isNeitherLessOrGreaterThan=function(e){return 0===e},r.greaterThan=1,r.lessThan=-1,r.neitherLessOrGreaterThan=0;class A{constructor(e){this.items=e,this.firstIdx=0,this.lastIdx=this.items.length-1}get length(){return this.lastIdx-this.firstIdx+1}takeWhile(e){let t=this.firstIdx;for(;t=0&&e(this.items[t]);)t--;let i=t===this.lastIdx?null:this.items.slice(t+1,this.lastIdx+1);return this.lastIdx=t,i}peek(){if(0!==this.length)return this.items[this.firstIdx]}dequeue(){let e=this.items[this.firstIdx];return this.firstIdx++,e}takeCount(e){let t=this.items.slice(this.firstIdx,this.firstIdx+e);return this.firstIdx+=e,t}}class N{constructor(e){this.iterate=e}toArray(){let e=[];return this.iterate(t=>(e.push(t),!0)),e}filter(e){return new N(t=>this.iterate(i=>!e(i)||t(i)))}map(e){return new N(t=>this.iterate(i=>t(e(i))))}findLast(e){let t;return this.iterate(i=>(e(i)&&(t=i),!0)),t}findLastMaxBy(e){let t;let i=!0;return this.iterate(r=>((i||n.isGreaterThan(e(r,t)))&&(i=!1,t=r),!0)),t}}N.empty=new N(e=>{})},53725:function(e,t,i){"use strict";var n;i.d(t,{$:function(){return n}}),function(e){function t(e){return e&&"object"==typeof e&&"function"==typeof e[Symbol.iterator]}e.is=t;let i=Object.freeze([]);function*n(e){yield e}e.empty=function(){return i},e.single=n,e.wrap=function(e){return t(e)?e:n(e)},e.from=function(e){return e||i},e.isEmpty=function(e){return!e||!0===e[Symbol.iterator]().next().done},e.first=function(e){return e[Symbol.iterator]().next().value},e.some=function(e,t){for(let i of e)if(t(i))return!0;return!1},e.find=function(e,t){for(let i of e)if(t(i))return i},e.filter=function*(e,t){for(let i of e)t(i)&&(yield i)},e.map=function*(e,t){let i=0;for(let n of e)yield t(n,i++)},e.concat=function*(...e){for(let t of e)for(let e of t)yield e},e.reduce=function(e,t,i){let n=i;for(let i of e)n=t(n,i);return n},e.slice=function*(e,t,i=e.length){for(t<0&&(t+=e.length),i<0?i+=e.length:i>e.length&&(i=e.length);tr}]}}(n||(n={}))},91741:function(e,t,i){"use strict";i.d(t,{S:function(){return r}});class n{constructor(e){this.element=e,this.next=n.Undefined,this.prev=n.Undefined}}n.Undefined=new n(void 0);class r{constructor(){this._first=n.Undefined,this._last=n.Undefined,this._size=0}get size(){return this._size}isEmpty(){return this._first===n.Undefined}clear(){let e=this._first;for(;e!==n.Undefined;){let t=e.next;e.prev=n.Undefined,e.next=n.Undefined,e=t}this._first=n.Undefined,this._last=n.Undefined,this._size=0}unshift(e){return this._insert(e,!1)}push(e){return this._insert(e,!0)}_insert(e,t){let i=new n(e);if(this._first===n.Undefined)this._first=i,this._last=i;else if(t){let e=this._last;this._last=i,i.prev=e,e.next=i}else{let e=this._first;this._first=i,i.next=e,e.prev=i}this._size+=1;let r=!1;return()=>{r||(r=!0,this._remove(i))}}shift(){if(this._first!==n.Undefined){let e=this._first.element;return this._remove(this._first),e}}pop(){if(this._last!==n.Undefined){let e=this._last.element;return this._remove(this._last),e}}_remove(e){if(e.prev!==n.Undefined&&e.next!==n.Undefined){let t=e.prev;t.next=e.next,e.next.prev=t}else e.prev===n.Undefined&&e.next===n.Undefined?(this._first=n.Undefined,this._last=n.Undefined):e.next===n.Undefined?(this._last=this._last.prev,this._last.next=n.Undefined):e.prev===n.Undefined&&(this._first=this._first.next,this._first.prev=n.Undefined);this._size-=1}*[Symbol.iterator](){let e=this._first;for(;e!==n.Undefined;)yield e.element,e=e.next}}},36248:function(e,t,i){"use strict";i.d(t,{$E:function(){return a},I8:function(){return function e(t){if(!t||"object"!=typeof t||t instanceof RegExp)return t;let i=Array.isArray(t)?[]:{};return Object.entries(t).forEach(([t,n])=>{i[t]=n&&"object"==typeof n?e(n):n}),i}},IU:function(){return l},_A:function(){return r},fS:function(){return function e(t,i){let n,r;if(t===i)return!0;if(null==t||null==i||typeof t!=typeof i||"object"!=typeof t||Array.isArray(t)!==Array.isArray(i))return!1;if(Array.isArray(t)){if(t.length!==i.length)return!1;for(n=0;n{o in t?r&&((0,n.Kn)(t[o])&&(0,n.Kn)(i[o])?e(t[o],i[o],r):t[o]=i[o]):t[o]=i[o]}),t):i}},rs:function(){return s}});var n=i(98401);function r(e){if(!e||"object"!=typeof e)return e;let t=[e];for(;t.length>0;){let e=t.shift();for(let i in Object.freeze(e),e)if(o.call(e,i)){let r=e[i];"object"!=typeof r||Object.isFrozen(r)||(0,n.fU)(r)||t.push(r)}}return e}let o=Object.prototype.hasOwnProperty;function s(e,t){return function e(t,i,r){if((0,n.Jp)(t))return t;let s=i(t);if(void 0!==s)return s;if(Array.isArray(t)){let n=[];for(let o of t)n.push(e(o,i,r));return n}if((0,n.Kn)(t)){if(r.has(t))throw Error("Cannot clone recursive data-structure");r.add(t);let n={};for(let s in t)o.call(t,s)&&(n[s]=e(t[s],i,r));return r.delete(t),n}return t}(e,t,new Set)}function a(e){let t=[];for(let i of function(e){let t=[];for(;Object.prototype!==e;)t=t.concat(Object.getOwnPropertyNames(e)),e=Object.getPrototypeOf(e);return t}(e))"function"==typeof e[i]&&t.push(i);return t}function l(e,t){let i=e=>function(){let i=Array.prototype.slice.call(arguments,0);return t(e,i)},n={};for(let t of e)n[t]=i(t);return n}},1432:function(e,t,i){"use strict";let n,r;i.d(t,{$L:function(){return S},ED:function(){return E},G6:function(){return k},IJ:function(){return b},OS:function(){return L},dz:function(){return v},fn:function(){return O},gn:function(){return T},i7:function(){return x},li:function(){return p},n2:function(){return y},r:function(){return D},tY:function(){return C},tq:function(){return R},un:function(){return P},vU:function(){return M}});var o,s=i(63580),a=i(83454);let l=!1,h=!1,u=!1,d=!1,c=!1,f=!1,g=!1,p="object"==typeof self?self:"object"==typeof i.g?i.g:{};void 0!==p.vscode&&void 0!==p.vscode.process?r=p.vscode.process:void 0!==a&&(r=a);let m="string"==typeof(null===(o=null==r?void 0:r.versions)||void 0===o?void 0:o.electron),_=m&&(null==r?void 0:r.type)==="renderer";if("object"!=typeof navigator||_){if("object"==typeof r){l="win32"===r.platform,h="darwin"===r.platform,(u="linux"===r.platform)&&r.env.SNAP&&r.env.SNAP_REVISION,r.env.CI||r.env.BUILD_ARTIFACTSTAGINGDIRECTORY;let e=r.env.VSCODE_NLS_CONFIG;if(e)try{let t=JSON.parse(e);t.availableLanguages["*"],t.locale,t.osLocale,t._translationsConfigFile}catch(e){}d=!0}else console.error("Unable to resolve platform.")}else l=(n=navigator.userAgent).indexOf("Windows")>=0,h=n.indexOf("Macintosh")>=0,f=(n.indexOf("Macintosh")>=0||n.indexOf("iPad")>=0||n.indexOf("iPhone")>=0)&&!!navigator.maxTouchPoints&&navigator.maxTouchPoints>0,u=n.indexOf("Linux")>=0,g=(null==n?void 0:n.indexOf("Mobi"))>=0,c=!0,s.aj(s.NC({key:"ensureLoaderPluginIsLoaded",comment:["{Locked}"]},"_")),navigator.language;let E=l,v=h,b=u,C=d,S=c,y=c&&"function"==typeof p.importScripts,T=f,R=g,A=n,N="function"==typeof p.postMessage&&!p.importScripts,O=(()=>{if(N){let e=[];p.addEventListener("message",t=>{if(t.data&&t.data.vscodeScheduleAsyncWork)for(let i=0,n=e.length;i{let n=++t;e.push({id:n,callback:i}),p.postMessage({vscodeScheduleAsyncWork:n},"*")}}return e=>setTimeout(e)})(),L=h||f?2:l?1:3,I=!0,w=!1;function D(){if(!w){w=!0;let e=new Uint8Array(2);e[0]=1,e[1]=2;let t=new Uint16Array(e.buffer);I=513===t[0]}return I}let x=!!(A&&A.indexOf("Chrome")>=0),M=!!(A&&A.indexOf("Firefox")>=0),k=!!(!x&&A&&A.indexOf("Safari")>=0),P=!!(A&&A.indexOf("Edg/")>=0);A&&A.indexOf("Android")},98401:function(e,t,i){"use strict";function n(e){return"string"==typeof e}function r(e){return"object"==typeof e&&null!==e&&!Array.isArray(e)&&!(e instanceof RegExp)&&!(e instanceof Date)}function o(e){let t=Object.getPrototypeOf(Uint8Array);return"object"==typeof e&&e instanceof t}function s(e){return"number"==typeof e&&!isNaN(e)}function a(e){return!!e&&"function"==typeof e[Symbol.iterator]}function l(e){return!0===e||!1===e}function h(e){return void 0===e}function u(e){return!d(e)}function d(e){return h(e)||null===e}function c(e,t){if(!e)throw Error(t?`Unexpected type, expected '${t}'`:"Unexpected type")}function f(e){if(d(e))throw Error("Assertion Failed: argument is undefined or null");return e}function g(e){return"function"==typeof e}function p(e,t){let i=Math.min(e.length,t.length);for(let r=0;rs.maxLen){let n=t-s.maxLen/2;return n<0?n=0:o+=n,r=r.substring(n,t+s.maxLen/2),e(t,i,r,o,s)}let a=Date.now(),h=t-1-o,u=-1,d=null;for(let e=1;!(Date.now()-a>=s.timeBudget);e++){let t=h-s.windowSize*e;i.lastIndex=Math.max(0,t);let n=function(e,t,i,n){let r;for(;r=e.exec(t);){let t=r.index||0;if(t<=i&&e.lastIndex>=i)return r;if(n>0&&t>n)break}return null}(i,r,h,u);if(!n&&d||(d=n,t<=0))break;u=t}if(d){let e={word:d[0],startColumn:o+1+d.index,endColumn:o+1+d.index+d[0].length};return i.lastIndex=0,e}return null}},vu:function(){return o}});var n=i(53725),r=i(91741);let o="`~!@#$%^&*()-=+[{]}\\|;:'\",.<>/?",s=function(e=""){let t="(-?\\d*\\.\\d\\w*)|([^";for(let i of o)e.indexOf(i)>=0||(t+="\\"+i);return RegExp(t+="\\s]+)","g")}();function a(e){let t=s;if(e&&e instanceof RegExp){if(e.global)t=e;else{let i="g";e.ignoreCase&&(i+="i"),e.multiline&&(i+="m"),e.unicode&&(i+="u"),t=new RegExp(e.source,i)}}return t.lastIndex=0,t}let l=new r.S;l.unshift({maxLen:1e3,windowSize:15,timeBudget:150})},77119:function(e,t,i){"use strict";let n,r,o,s,a,l,h,u,d,c,f,g,p,m,_,E,v,b;i.r(t),i.d(t,{CancellationTokenSource:function(){return k1},Emitter:function(){return k2},KeyCode:function(){return k5},KeyMod:function(){return k4},MarkerSeverity:function(){return k7},MarkerTag:function(){return Pe},Position:function(){return k3},Range:function(){return k6},Selection:function(){return k9},SelectionDirection:function(){return k8},Token:function(){return Pi},Uri:function(){return Pt},editor:function(){return Pn},languages:function(){return Pr}});var C,S,y,T,R,A,N,O,L,I,w,D,x,M,k,P,F,B,U,H,V,W,G,j,z,K,Y,$,q,X,Z,Q,J,ee,et,ei,en,er,eo,es,ea,el,eh,eu,ed,ec,ef,eg,ep,em,e_,eE,ev,eb,eC,eS,ey,eT,eR,eA,eN,eO,eL,eI,ew,eD,ex,eM,ek,eP,eF,eB,eU,eH,eV,eW,eG,ej,ez,eK,eY,e$,eq,eX,eZ,eQ,eJ,e0,e1,e2,e5,e4,e3,e6,e9,e8,e7,te,tt,ti,tn,tr,to,ts,ta,tl,th,tu,td,tc,tf,tg,tp,tm,t_,tE,tv,tb,tC,tS,ty,tT,tR,tA,tN,tO,tL,tI,tw,tD,tx,tM,tk,tP,tF,tB,tU,tH,tV,tW,tG,tj,tz,tK,tY,t$,tq,tX,tZ,tQ,tJ,t0,t1,t2,t5,t4,t3,t6,t9,t8,t7,ie,it,ii,ir,io,is,ia,il,ih,iu,id,ic,ig,ip,im,i_,iE,iv,ib,iC,iS,iy,iT,iR,iA,iN,iO,iL,iI,iw,iD,ix,iM,ik,iP,iF,iB,iU,iH,iV,iW,iG,ij,iz,iK,iY,i$,iq,iX,iZ,iQ,iJ=i(64141);let i0=new class{constructor(){this.listeners=[],this.unexpectedErrorHandler=function(e){setTimeout(()=>{if(e.stack){if(ne.isErrorNoTelemetry(e))throw new ne(e.message+"\n\n"+e.stack);throw Error(e.message+"\n\n"+e.stack)}throw e},0)}}emit(e){this.listeners.forEach(t=>{t(e)})}onUnexpectedError(e){this.unexpectedErrorHandler(e),this.emit(e)}onUnexpectedExternalError(e){this.unexpectedErrorHandler(e)}};function i1(e){i3(e)||i0.onUnexpectedError(e)}function i2(e){i3(e)||i0.onUnexpectedExternalError(e)}function i5(e){if(e instanceof Error){let{name:t,message:i}=e,n=e.stacktrace||e.stack;return{$isError:!0,name:t,message:i,stack:n,noTelemetry:ne.isErrorNoTelemetry(e)}}return e}let i4="Canceled";function i3(e){return e instanceof i6||e instanceof Error&&e.name===i4&&e.message===i4}class i6 extends Error{constructor(){super(i4),this.name=this.message}}function i9(e){return e?Error(`Illegal argument: ${e}`):Error("Illegal argument")}function i8(e){return e?Error(`Illegal state: ${e}`):Error("Illegal state")}class i7 extends Error{constructor(e){super("NotSupported"),e&&(this.message=e)}}class ne extends Error{constructor(e){super(e),this.name="CodeExpectedError"}static fromError(e){if(e instanceof ne)return e;let t=new ne;return t.message=e.message,t.stack=e.stack,t}static isErrorNoTelemetry(e){return"CodeExpectedError"===e.name}}class nt extends Error{constructor(e){super(e||"An unexpected bug occurred."),Object.setPrototypeOf(this,nt.prototype)}}function ni(e){let t;let i=this,n=!1;return function(){return n?t:(n=!0,t=e.apply(i,arguments))}}var nn=i(53725);function nr(e){return e}function no(e){}function ns(e,t){}function na(e){return e}function nl(e){if(nn.$.is(e)){let t=[];for(let i of e)if(i)try{i.dispose()}catch(e){t.push(e)}if(1===t.length)throw t[0];if(t.length>1)throw AggregateError(t,"Encountered errors while disposing of store");return Array.isArray(e)?[]:e}if(e)return e.dispose(),e}function nh(...e){let t=nu(()=>nl(e));return t}function nu(e){let t={dispose:ni(()=>{e()})};return t}class nd{constructor(){var e;this._toDispose=new Set,this._isDisposed=!1,e=this}dispose(){this._isDisposed||(this._isDisposed=!0,this.clear())}get isDisposed(){return this._isDisposed}clear(){if(0!==this._toDispose.size)try{nl(this._toDispose)}finally{this._toDispose.clear()}}add(e){if(!e)return e;if(e===this)throw Error("Cannot register a disposable on itself!");return this._isDisposed?nd.DISABLE_DISPOSED_WARNING||console.warn(Error("Trying to add a disposable to a DisposableStore that has already been disposed of. The added object will be leaked!").stack):this._toDispose.add(e),e}}nd.DISABLE_DISPOSED_WARNING=!1;class nc{constructor(){var e;this._store=new nd,e=this,this._store}dispose(){this._store.dispose()}_register(e){if(e===this)throw Error("Cannot register a disposable on itself!");return this._store.add(e)}}nc.None=Object.freeze({dispose(){}});class nf{constructor(){var e;this._isDisposed=!1,e=this}get value(){return this._isDisposed?void 0:this._value}set value(e){var t;this._isDisposed||e===this._value||(null===(t=this._value)||void 0===t||t.dispose(),this._value=e)}clear(){this.value=void 0}dispose(){var e;this._isDisposed=!0,null===(e=this._value)||void 0===e||e.dispose(),this._value=void 0}}class ng{constructor(e){this.object=e}dispose(){}}class np{constructor(){var e;this._store=new Map,this._isDisposed=!1,e=this}dispose(){this._isDisposed=!0,this.clearAndDisposeAll()}clearAndDisposeAll(){if(this._store.size)try{nl(this._store.values())}finally{this._store.clear()}}get(e){return this._store.get(e)}set(e,t,i=!1){var n;this._isDisposed&&console.warn(Error("Trying to add a disposable to a DisposableMap that has already been disposed of. The added object will be leaked!").stack),i||null===(n=this._store.get(e))||void 0===n||n.dispose(),this._store.set(e,t)}deleteAndDispose(e){var t;null===(t=this._store.get(e))||void 0===t||t.dispose(),this._store.delete(e)}[Symbol.iterator](){return this._store[Symbol.iterator]()}}var nm=i(91741);let n_=globalThis.performance&&"function"==typeof globalThis.performance.now;class nE{static create(e){return new nE(e)}constructor(e){this._now=n_&&!1===e?Date.now:globalThis.performance.now.bind(globalThis.performance),this._startTime=this._now(),this._stopTime=-1}stop(){this._stopTime=this._now()}elapsed(){return -1!==this._stopTime?this._stopTime-this._startTime:this._now()-this._startTime}}!function(e){function t(e){return(t,i=null,n)=>{let r,o=!1;return r=e(e=>o?void 0:(r?r.dispose():o=!0,t.call(i,e)),null,n),o&&r.dispose(),r}}function i(e,t,i){return s((i,n=null,r)=>e(e=>i.call(n,t(e)),null,r),i)}function n(e,t,i){return s((i,n=null,r)=>e(e=>{t(e),i.call(n,e)},null,r),i)}function r(e,t,i){return s((i,n=null,r)=>e(e=>t(e)&&i.call(n,e),null,r),i)}function o(e,t,n,r){let o=n;return i(e,e=>o=t(o,e),r)}function s(e,t){let i;let n=new ny({onWillAddFirstListener(){i=e(n.fire,n)},onDidRemoveLastListener(){null==i||i.dispose()}});return null==t||t.add(n),n.event}function a(e,t,i=100,n=!1,r=!1,o,s){let a,l,h,u;let d=0,c=new ny({leakWarningThreshold:o,onWillAddFirstListener(){a=e(e=>{d++,h=t(h,e),n&&!u&&(c.fire(h),h=void 0),l=()=>{let e=h;h=void 0,u=void 0,(!n||d>1)&&c.fire(e),d=0},"number"==typeof i?(clearTimeout(u),u=setTimeout(l,i)):void 0===u&&(u=0,queueMicrotask(l))})},onWillRemoveListener(){r&&d>0&&(null==l||l())},onDidRemoveLastListener(){l=void 0,a.dispose()}});return null==s||s.add(c),c.event}function l(e,t=(e,t)=>e===t,i){let n,o=!0;return r(e,e=>{let i=o||!t(e,n);return o=!1,n=e,i},i)}e.None=()=>nc.None,e.defer=function(e,t){return a(e,()=>void 0,0,void 0,!0,void 0,t)},e.once=t,e.map=i,e.forEach=n,e.filter=r,e.signal=function(e){return e},e.any=function(...e){return(t,i=null,n)=>nh(...e.map(e=>e(e=>t.call(i,e),null,n)))},e.reduce=o,e.debounce=a,e.accumulate=function(t,i=0,n){return e.debounce(t,(e,t)=>e?(e.push(t),e):[t],i,void 0,!0,void 0,n)},e.latch=l,e.split=function(t,i,n){return[e.filter(t,i,n),e.filter(t,e=>!i(e),n)]},e.buffer=function(e,t=!1,i=[]){let n=i.slice(),r=e(e=>{n?n.push(e):s.fire(e)}),o=()=>{null==n||n.forEach(e=>s.fire(e)),n=null},s=new ny({onWillAddFirstListener(){r||(r=e(e=>s.fire(e)))},onDidAddFirstListener(){n&&(t?setTimeout(o):o())},onDidRemoveLastListener(){r&&r.dispose(),r=null}});return s.event};class h{constructor(e){this.event=e,this.disposables=new nd}map(e){return new h(i(this.event,e,this.disposables))}forEach(e){return new h(n(this.event,e,this.disposables))}filter(e){return new h(r(this.event,e,this.disposables))}reduce(e,t){return new h(o(this.event,e,t,this.disposables))}latch(){return new h(l(this.event,void 0,this.disposables))}debounce(e,t=100,i=!1,n=!1,r){return new h(a(this.event,e,t,i,n,r,this.disposables))}on(e,t,i){return this.event(e,t,i)}once(e,i,n){return t(this.event)(e,i,n)}dispose(){this.disposables.dispose()}}e.chain=function(e){return new h(e)},e.fromNodeEventEmitter=function(e,t,i=e=>e){let n=(...e)=>r.fire(i(...e)),r=new ny({onWillAddFirstListener:()=>e.on(t,n),onDidRemoveLastListener:()=>e.removeListener(t,n)});return r.event},e.fromDOMEventEmitter=function(e,t,i=e=>e){let n=(...e)=>r.fire(i(...e)),r=new ny({onWillAddFirstListener:()=>e.addEventListener(t,n),onDidRemoveLastListener:()=>e.removeEventListener(t,n)});return r.event},e.toPromise=function(e){return new Promise(i=>t(e)(i))},e.runAndSubscribe=function(e,t){return t(void 0),e(e=>t(e))},e.runAndSubscribeWithStore=function(e,t){let i=null;function n(e){null==i||i.dispose(),t(e,i=new nd)}n(void 0);let r=e(e=>n(e));return nu(()=>{r.dispose(),null==i||i.dispose()})};class u{constructor(e,t){this._observable=e,this._counter=0,this._hasChanged=!1;this.emitter=new ny({onWillAddFirstListener:()=>{e.addObserver(this)},onDidRemoveLastListener:()=>{e.removeObserver(this)}}),t&&t.add(this.emitter)}beginUpdate(e){this._counter++}handlePossibleChange(e){}handleChange(e,t){this._hasChanged=!0}endUpdate(e){this._counter--,0===this._counter&&(this._observable.reportChanges(),this._hasChanged&&(this._hasChanged=!1,this.emitter.fire(this._observable.get())))}}e.fromObservable=function(e,t){let i=new u(e,t);return i.emitter.event},e.fromObservableLight=function(e){return t=>{let i=0,n=!1,r={beginUpdate(){i++},endUpdate(){0==--i&&(e.reportChanges(),n&&(n=!1,t()))},handlePossibleChange(){},handleChange(){n=!0}};return e.addObserver(r),e.reportChanges(),{dispose(){e.removeObserver(r)}}}}}(e8||(e8={}));class nv{constructor(e){this.listenerCount=0,this.invocationCount=0,this.elapsedOverall=0,this.durations=[],this.name=`${e}_${nv._idPool++}`,nv.all.add(this)}start(e){this._stopWatch=new nE,this.listenerCount=e}stop(){if(this._stopWatch){let e=this._stopWatch.elapsed();this.durations.push(e),this.elapsedOverall+=e,this.invocationCount+=1,this._stopWatch=void 0}}}nv.all=new Set,nv._idPool=0;class nb{constructor(e,t=Math.random().toString(18).slice(2,5)){this.threshold=e,this.name=t,this._warnCountdown=0}dispose(){var e;null===(e=this._stacks)||void 0===e||e.clear()}check(e,t){let i=this.threshold;if(i<=0||t{let t=this._stacks.get(e.value)||0;this._stacks.set(e.value,t-1)}}}class nC{static create(){var e;return new nC(null!==(e=Error().stack)&&void 0!==e?e:"")}constructor(e){this.value=e}print(){console.warn(this.value.split("\n").slice(2).join("\n"))}}class nS{constructor(e){this.value=e}}class ny{constructor(e){var t,i,n,r,o;this._size=0,this._options=e,this._leakageMon=(null===(t=this._options)||void 0===t?void 0:t.leakWarningThreshold)?new nb(null!==(n=null===(i=this._options)||void 0===i?void 0:i.leakWarningThreshold)&&void 0!==n?n:-1):void 0,this._perfMon=(null===(r=this._options)||void 0===r?void 0:r._profName)?new nv(this._options._profName):void 0,this._deliveryQueue=null===(o=this._options)||void 0===o?void 0:o.deliveryQueue}dispose(){var e,t,i,n;this._disposed||(this._disposed=!0,(null===(e=this._deliveryQueue)||void 0===e?void 0:e.current)===this&&this._deliveryQueue.reset(),this._listeners&&(this._listeners=void 0,this._size=0),null===(i=null===(t=this._options)||void 0===t?void 0:t.onDidRemoveLastListener)||void 0===i||i.call(t),null===(n=this._leakageMon)||void 0===n||n.dispose())}get event(){var e;return null!==(e=this._event)&&void 0!==e||(this._event=(e,t,i)=>{var n,r,o,s,a;let l;if(this._leakageMon&&this._size>3*this._leakageMon.threshold)return console.warn(`[${this._leakageMon.name}] REFUSES to accept new listeners because it exceeded its threshold by far`),nc.None;if(this._disposed)return nc.None;t&&(e=e.bind(t));let h=new nS(e);this._leakageMon&&this._size>=Math.ceil(.2*this._leakageMon.threshold)&&(h.stack=nC.create(),l=this._leakageMon.check(h.stack,this._size+1)),this._listeners?this._listeners instanceof nS?(null!==(a=this._deliveryQueue)&&void 0!==a||(this._deliveryQueue=new nR),this._listeners=[this._listeners,h]):this._listeners.push(h):(null===(r=null===(n=this._options)||void 0===n?void 0:n.onWillAddFirstListener)||void 0===r||r.call(n,this),this._listeners=h,null===(s=null===(o=this._options)||void 0===o?void 0:o.onDidAddFirstListener)||void 0===s||s.call(o,this)),this._size++;let u=nu(()=>{null==l||l(),this._removeListener(h)});return i instanceof nd?i.add(u):Array.isArray(i)&&i.push(u),u}),this._event}_removeListener(e){var t,i,n,r;if(null===(i=null===(t=this._options)||void 0===t?void 0:t.onWillRemoveListener)||void 0===i||i.call(t,this),!this._listeners)return;if(1===this._size){this._listeners=void 0,null===(r=null===(n=this._options)||void 0===n?void 0:n.onDidRemoveLastListener)||void 0===r||r.call(n,this),this._size=0;return}let o=this._listeners,s=o.indexOf(e);if(-1===s)throw console.log("disposed?",this._disposed),console.log("size?",this._size),console.log("arr?",JSON.stringify(this._listeners)),Error("Attempted to dispose unknown listener");this._size--,o[s]=void 0;let a=this._deliveryQueue.current===this;if(2*this._size<=o.length){let e=0;for(let t=0;t0}}let nT=()=>new nR;class nR{constructor(){this.i=-1,this.end=0}enqueue(e,t,i){this.i=0,this.end=i,this.current=e,this.value=t}reset(){this.i=this.end,this.current=void 0,this.value=void 0}}class nA extends ny{constructor(e){super(e),this._isPaused=0,this._eventQueue=new nm.S,this._mergeFn=null==e?void 0:e.merge}pause(){this._isPaused++}resume(){if(0!==this._isPaused&&0==--this._isPaused){if(this._mergeFn){if(this._eventQueue.size>0){let e=Array.from(this._eventQueue);this._eventQueue.clear(),super.fire(this._mergeFn(e))}}else for(;!this._isPaused&&0!==this._eventQueue.size;)super.fire(this._eventQueue.shift())}}fire(e){this._size&&(0!==this._isPaused?this._eventQueue.push(e):super.fire(e))}}class nN extends nA{constructor(e){var t;super(e),this._delay=null!==(t=e.delay)&&void 0!==t?t:100}fire(e){this._handle||(this.pause(),this._handle=setTimeout(()=>{this._handle=void 0,this.resume()},this._delay)),super.fire(e)}}class nO extends ny{constructor(e){super(e),this._queuedEvents=[],this._mergeFn=null==e?void 0:e.merge}fire(e){this.hasListeners()&&(this._queuedEvents.push(e),1===this._queuedEvents.length&&queueMicrotask(()=>{this._mergeFn?super.fire(this._mergeFn(this._queuedEvents)):this._queuedEvents.forEach(e=>super.fire(e)),this._queuedEvents=[]}))}}class nL{constructor(){this.buffers=[]}wrapEvent(e){return(t,i,n)=>e(e=>{let n=this.buffers[this.buffers.length-1];n?n.push(()=>t.call(i,e)):t.call(i,e)},void 0,n)}bufferEvents(e){let t=[];this.buffers.push(t);let i=e();return this.buffers.pop(),t.forEach(e=>e()),i}}class nI{constructor(){this.listening=!1,this.inputEvent=e8.None,this.inputEventListener=nc.None,this.emitter=new ny({onDidAddFirstListener:()=>{this.listening=!0,this.inputEventListener=this.inputEvent(this.emitter.fire,this.emitter)},onDidRemoveLastListener:()=>{this.listening=!1,this.inputEventListener.dispose()}}),this.event=this.emitter.event}set input(e){this.inputEvent=e,this.listening&&(this.inputEventListener.dispose(),this.inputEventListener=e(this.emitter.fire,this.emitter))}dispose(){this.inputEventListener.dispose(),this.emitter.dispose()}}let nw=Object.freeze(function(e,t){let i=setTimeout(e.bind(t),0);return{dispose(){clearTimeout(i)}}});(S=e7||(e7={})).isCancellationToken=function(e){return e===S.None||e===S.Cancelled||e instanceof nD||!!e&&"object"==typeof e&&"boolean"==typeof e.isCancellationRequested&&"function"==typeof e.onCancellationRequested},S.None=Object.freeze({isCancellationRequested:!1,onCancellationRequested:e8.None}),S.Cancelled=Object.freeze({isCancellationRequested:!0,onCancellationRequested:nw});class nD{constructor(){this._isCancelled=!1,this._emitter=null}cancel(){!this._isCancelled&&(this._isCancelled=!0,this._emitter&&(this._emitter.fire(void 0),this.dispose()))}get isCancellationRequested(){return this._isCancelled}get onCancellationRequested(){return this._isCancelled?nw:(this._emitter||(this._emitter=new ny),this._emitter.event)}dispose(){this._emitter&&(this._emitter.dispose(),this._emitter=null)}}class nx{constructor(e){this._token=void 0,this._parentListener=void 0,this._parentListener=e&&e.onCancellationRequested(this.cancel,this)}get token(){return this._token||(this._token=new nD),this._token}cancel(){this._token?this._token instanceof nD&&this._token.cancel():this._token=e7.Cancelled}dispose(e=!1){var t;e&&this.cancel(),null===(t=this._parentListener)||void 0===t||t.dispose(),this._token?this._token instanceof nD&&this._token.dispose():this._token=e7.None}}class nM{constructor(){this._keyCodeToStr=[],this._strToKeyCode=Object.create(null)}define(e,t){this._keyCodeToStr[e]=t,this._strToKeyCode[t.toLowerCase()]=e}keyCodeToStr(e){return this._keyCodeToStr[e]}strToKeyCode(e){return this._strToKeyCode[e.toLowerCase()]||0}}let nk=new nM,nP=new nM,nF=new nM,nB=Array(230),nU={},nH=[],nV=Object.create(null),nW=Object.create(null),nG=[],nj=[];for(let e=0;e<=193;e++)nG[e]=-1;for(let e=0;e<=132;e++)nj[e]=-1;!function(){let e=[],t=[];for(let i of[[1,0,"None",0,"unknown",0,"VK_UNKNOWN","",""],[1,1,"Hyper",0,"",0,"","",""],[1,2,"Super",0,"",0,"","",""],[1,3,"Fn",0,"",0,"","",""],[1,4,"FnLock",0,"",0,"","",""],[1,5,"Suspend",0,"",0,"","",""],[1,6,"Resume",0,"",0,"","",""],[1,7,"Turbo",0,"",0,"","",""],[1,8,"Sleep",0,"",0,"VK_SLEEP","",""],[1,9,"WakeUp",0,"",0,"","",""],[0,10,"KeyA",31,"A",65,"VK_A","",""],[0,11,"KeyB",32,"B",66,"VK_B","",""],[0,12,"KeyC",33,"C",67,"VK_C","",""],[0,13,"KeyD",34,"D",68,"VK_D","",""],[0,14,"KeyE",35,"E",69,"VK_E","",""],[0,15,"KeyF",36,"F",70,"VK_F","",""],[0,16,"KeyG",37,"G",71,"VK_G","",""],[0,17,"KeyH",38,"H",72,"VK_H","",""],[0,18,"KeyI",39,"I",73,"VK_I","",""],[0,19,"KeyJ",40,"J",74,"VK_J","",""],[0,20,"KeyK",41,"K",75,"VK_K","",""],[0,21,"KeyL",42,"L",76,"VK_L","",""],[0,22,"KeyM",43,"M",77,"VK_M","",""],[0,23,"KeyN",44,"N",78,"VK_N","",""],[0,24,"KeyO",45,"O",79,"VK_O","",""],[0,25,"KeyP",46,"P",80,"VK_P","",""],[0,26,"KeyQ",47,"Q",81,"VK_Q","",""],[0,27,"KeyR",48,"R",82,"VK_R","",""],[0,28,"KeyS",49,"S",83,"VK_S","",""],[0,29,"KeyT",50,"T",84,"VK_T","",""],[0,30,"KeyU",51,"U",85,"VK_U","",""],[0,31,"KeyV",52,"V",86,"VK_V","",""],[0,32,"KeyW",53,"W",87,"VK_W","",""],[0,33,"KeyX",54,"X",88,"VK_X","",""],[0,34,"KeyY",55,"Y",89,"VK_Y","",""],[0,35,"KeyZ",56,"Z",90,"VK_Z","",""],[0,36,"Digit1",22,"1",49,"VK_1","",""],[0,37,"Digit2",23,"2",50,"VK_2","",""],[0,38,"Digit3",24,"3",51,"VK_3","",""],[0,39,"Digit4",25,"4",52,"VK_4","",""],[0,40,"Digit5",26,"5",53,"VK_5","",""],[0,41,"Digit6",27,"6",54,"VK_6","",""],[0,42,"Digit7",28,"7",55,"VK_7","",""],[0,43,"Digit8",29,"8",56,"VK_8","",""],[0,44,"Digit9",30,"9",57,"VK_9","",""],[0,45,"Digit0",21,"0",48,"VK_0","",""],[1,46,"Enter",3,"Enter",13,"VK_RETURN","",""],[1,47,"Escape",9,"Escape",27,"VK_ESCAPE","",""],[1,48,"Backspace",1,"Backspace",8,"VK_BACK","",""],[1,49,"Tab",2,"Tab",9,"VK_TAB","",""],[1,50,"Space",10,"Space",32,"VK_SPACE","",""],[0,51,"Minus",88,"-",189,"VK_OEM_MINUS","-","OEM_MINUS"],[0,52,"Equal",86,"=",187,"VK_OEM_PLUS","=","OEM_PLUS"],[0,53,"BracketLeft",92,"[",219,"VK_OEM_4","[","OEM_4"],[0,54,"BracketRight",94,"]",221,"VK_OEM_6","]","OEM_6"],[0,55,"Backslash",93,"\\",220,"VK_OEM_5","\\","OEM_5"],[0,56,"IntlHash",0,"",0,"","",""],[0,57,"Semicolon",85,";",186,"VK_OEM_1",";","OEM_1"],[0,58,"Quote",95,"'",222,"VK_OEM_7","'","OEM_7"],[0,59,"Backquote",91,"`",192,"VK_OEM_3","`","OEM_3"],[0,60,"Comma",87,",",188,"VK_OEM_COMMA",",","OEM_COMMA"],[0,61,"Period",89,".",190,"VK_OEM_PERIOD",".","OEM_PERIOD"],[0,62,"Slash",90,"/",191,"VK_OEM_2","/","OEM_2"],[1,63,"CapsLock",8,"CapsLock",20,"VK_CAPITAL","",""],[1,64,"F1",59,"F1",112,"VK_F1","",""],[1,65,"F2",60,"F2",113,"VK_F2","",""],[1,66,"F3",61,"F3",114,"VK_F3","",""],[1,67,"F4",62,"F4",115,"VK_F4","",""],[1,68,"F5",63,"F5",116,"VK_F5","",""],[1,69,"F6",64,"F6",117,"VK_F6","",""],[1,70,"F7",65,"F7",118,"VK_F7","",""],[1,71,"F8",66,"F8",119,"VK_F8","",""],[1,72,"F9",67,"F9",120,"VK_F9","",""],[1,73,"F10",68,"F10",121,"VK_F10","",""],[1,74,"F11",69,"F11",122,"VK_F11","",""],[1,75,"F12",70,"F12",123,"VK_F12","",""],[1,76,"PrintScreen",0,"",0,"","",""],[1,77,"ScrollLock",84,"ScrollLock",145,"VK_SCROLL","",""],[1,78,"Pause",7,"PauseBreak",19,"VK_PAUSE","",""],[1,79,"Insert",19,"Insert",45,"VK_INSERT","",""],[1,80,"Home",14,"Home",36,"VK_HOME","",""],[1,81,"PageUp",11,"PageUp",33,"VK_PRIOR","",""],[1,82,"Delete",20,"Delete",46,"VK_DELETE","",""],[1,83,"End",13,"End",35,"VK_END","",""],[1,84,"PageDown",12,"PageDown",34,"VK_NEXT","",""],[1,85,"ArrowRight",17,"RightArrow",39,"VK_RIGHT","Right",""],[1,86,"ArrowLeft",15,"LeftArrow",37,"VK_LEFT","Left",""],[1,87,"ArrowDown",18,"DownArrow",40,"VK_DOWN","Down",""],[1,88,"ArrowUp",16,"UpArrow",38,"VK_UP","Up",""],[1,89,"NumLock",83,"NumLock",144,"VK_NUMLOCK","",""],[1,90,"NumpadDivide",113,"NumPad_Divide",111,"VK_DIVIDE","",""],[1,91,"NumpadMultiply",108,"NumPad_Multiply",106,"VK_MULTIPLY","",""],[1,92,"NumpadSubtract",111,"NumPad_Subtract",109,"VK_SUBTRACT","",""],[1,93,"NumpadAdd",109,"NumPad_Add",107,"VK_ADD","",""],[1,94,"NumpadEnter",3,"",0,"","",""],[1,95,"Numpad1",99,"NumPad1",97,"VK_NUMPAD1","",""],[1,96,"Numpad2",100,"NumPad2",98,"VK_NUMPAD2","",""],[1,97,"Numpad3",101,"NumPad3",99,"VK_NUMPAD3","",""],[1,98,"Numpad4",102,"NumPad4",100,"VK_NUMPAD4","",""],[1,99,"Numpad5",103,"NumPad5",101,"VK_NUMPAD5","",""],[1,100,"Numpad6",104,"NumPad6",102,"VK_NUMPAD6","",""],[1,101,"Numpad7",105,"NumPad7",103,"VK_NUMPAD7","",""],[1,102,"Numpad8",106,"NumPad8",104,"VK_NUMPAD8","",""],[1,103,"Numpad9",107,"NumPad9",105,"VK_NUMPAD9","",""],[1,104,"Numpad0",98,"NumPad0",96,"VK_NUMPAD0","",""],[1,105,"NumpadDecimal",112,"NumPad_Decimal",110,"VK_DECIMAL","",""],[0,106,"IntlBackslash",97,"OEM_102",226,"VK_OEM_102","",""],[1,107,"ContextMenu",58,"ContextMenu",93,"","",""],[1,108,"Power",0,"",0,"","",""],[1,109,"NumpadEqual",0,"",0,"","",""],[1,110,"F13",71,"F13",124,"VK_F13","",""],[1,111,"F14",72,"F14",125,"VK_F14","",""],[1,112,"F15",73,"F15",126,"VK_F15","",""],[1,113,"F16",74,"F16",127,"VK_F16","",""],[1,114,"F17",75,"F17",128,"VK_F17","",""],[1,115,"F18",76,"F18",129,"VK_F18","",""],[1,116,"F19",77,"F19",130,"VK_F19","",""],[1,117,"F20",78,"F20",131,"VK_F20","",""],[1,118,"F21",79,"F21",132,"VK_F21","",""],[1,119,"F22",80,"F22",133,"VK_F22","",""],[1,120,"F23",81,"F23",134,"VK_F23","",""],[1,121,"F24",82,"F24",135,"VK_F24","",""],[1,122,"Open",0,"",0,"","",""],[1,123,"Help",0,"",0,"","",""],[1,124,"Select",0,"",0,"","",""],[1,125,"Again",0,"",0,"","",""],[1,126,"Undo",0,"",0,"","",""],[1,127,"Cut",0,"",0,"","",""],[1,128,"Copy",0,"",0,"","",""],[1,129,"Paste",0,"",0,"","",""],[1,130,"Find",0,"",0,"","",""],[1,131,"AudioVolumeMute",117,"AudioVolumeMute",173,"VK_VOLUME_MUTE","",""],[1,132,"AudioVolumeUp",118,"AudioVolumeUp",175,"VK_VOLUME_UP","",""],[1,133,"AudioVolumeDown",119,"AudioVolumeDown",174,"VK_VOLUME_DOWN","",""],[1,134,"NumpadComma",110,"NumPad_Separator",108,"VK_SEPARATOR","",""],[0,135,"IntlRo",115,"ABNT_C1",193,"VK_ABNT_C1","",""],[1,136,"KanaMode",0,"",0,"","",""],[0,137,"IntlYen",0,"",0,"","",""],[1,138,"Convert",0,"",0,"","",""],[1,139,"NonConvert",0,"",0,"","",""],[1,140,"Lang1",0,"",0,"","",""],[1,141,"Lang2",0,"",0,"","",""],[1,142,"Lang3",0,"",0,"","",""],[1,143,"Lang4",0,"",0,"","",""],[1,144,"Lang5",0,"",0,"","",""],[1,145,"Abort",0,"",0,"","",""],[1,146,"Props",0,"",0,"","",""],[1,147,"NumpadParenLeft",0,"",0,"","",""],[1,148,"NumpadParenRight",0,"",0,"","",""],[1,149,"NumpadBackspace",0,"",0,"","",""],[1,150,"NumpadMemoryStore",0,"",0,"","",""],[1,151,"NumpadMemoryRecall",0,"",0,"","",""],[1,152,"NumpadMemoryClear",0,"",0,"","",""],[1,153,"NumpadMemoryAdd",0,"",0,"","",""],[1,154,"NumpadMemorySubtract",0,"",0,"","",""],[1,155,"NumpadClear",131,"Clear",12,"VK_CLEAR","",""],[1,156,"NumpadClearEntry",0,"",0,"","",""],[1,0,"",5,"Ctrl",17,"VK_CONTROL","",""],[1,0,"",4,"Shift",16,"VK_SHIFT","",""],[1,0,"",6,"Alt",18,"VK_MENU","",""],[1,0,"",57,"Meta",91,"VK_COMMAND","",""],[1,157,"ControlLeft",5,"",0,"VK_LCONTROL","",""],[1,158,"ShiftLeft",4,"",0,"VK_LSHIFT","",""],[1,159,"AltLeft",6,"",0,"VK_LMENU","",""],[1,160,"MetaLeft",57,"",0,"VK_LWIN","",""],[1,161,"ControlRight",5,"",0,"VK_RCONTROL","",""],[1,162,"ShiftRight",4,"",0,"VK_RSHIFT","",""],[1,163,"AltRight",6,"",0,"VK_RMENU","",""],[1,164,"MetaRight",57,"",0,"VK_RWIN","",""],[1,165,"BrightnessUp",0,"",0,"","",""],[1,166,"BrightnessDown",0,"",0,"","",""],[1,167,"MediaPlay",0,"",0,"","",""],[1,168,"MediaRecord",0,"",0,"","",""],[1,169,"MediaFastForward",0,"",0,"","",""],[1,170,"MediaRewind",0,"",0,"","",""],[1,171,"MediaTrackNext",124,"MediaTrackNext",176,"VK_MEDIA_NEXT_TRACK","",""],[1,172,"MediaTrackPrevious",125,"MediaTrackPrevious",177,"VK_MEDIA_PREV_TRACK","",""],[1,173,"MediaStop",126,"MediaStop",178,"VK_MEDIA_STOP","",""],[1,174,"Eject",0,"",0,"","",""],[1,175,"MediaPlayPause",127,"MediaPlayPause",179,"VK_MEDIA_PLAY_PAUSE","",""],[1,176,"MediaSelect",128,"LaunchMediaPlayer",181,"VK_MEDIA_LAUNCH_MEDIA_SELECT","",""],[1,177,"LaunchMail",129,"LaunchMail",180,"VK_MEDIA_LAUNCH_MAIL","",""],[1,178,"LaunchApp2",130,"LaunchApp2",183,"VK_MEDIA_LAUNCH_APP2","",""],[1,179,"LaunchApp1",0,"",0,"VK_MEDIA_LAUNCH_APP1","",""],[1,180,"SelectTask",0,"",0,"","",""],[1,181,"LaunchScreenSaver",0,"",0,"","",""],[1,182,"BrowserSearch",120,"BrowserSearch",170,"VK_BROWSER_SEARCH","",""],[1,183,"BrowserHome",121,"BrowserHome",172,"VK_BROWSER_HOME","",""],[1,184,"BrowserBack",122,"BrowserBack",166,"VK_BROWSER_BACK","",""],[1,185,"BrowserForward",123,"BrowserForward",167,"VK_BROWSER_FORWARD","",""],[1,186,"BrowserStop",0,"",0,"VK_BROWSER_STOP","",""],[1,187,"BrowserRefresh",0,"",0,"VK_BROWSER_REFRESH","",""],[1,188,"BrowserFavorites",0,"",0,"VK_BROWSER_FAVORITES","",""],[1,189,"ZoomToggle",0,"",0,"","",""],[1,190,"MailReply",0,"",0,"","",""],[1,191,"MailForward",0,"",0,"","",""],[1,192,"MailSend",0,"",0,"","",""],[1,0,"",114,"KeyInComposition",229,"","",""],[1,0,"",116,"ABNT_C2",194,"VK_ABNT_C2","",""],[1,0,"",96,"OEM_8",223,"VK_OEM_8","",""],[1,0,"",0,"",0,"VK_KANA","",""],[1,0,"",0,"",0,"VK_HANGUL","",""],[1,0,"",0,"",0,"VK_JUNJA","",""],[1,0,"",0,"",0,"VK_FINAL","",""],[1,0,"",0,"",0,"VK_HANJA","",""],[1,0,"",0,"",0,"VK_KANJI","",""],[1,0,"",0,"",0,"VK_CONVERT","",""],[1,0,"",0,"",0,"VK_NONCONVERT","",""],[1,0,"",0,"",0,"VK_ACCEPT","",""],[1,0,"",0,"",0,"VK_MODECHANGE","",""],[1,0,"",0,"",0,"VK_SELECT","",""],[1,0,"",0,"",0,"VK_PRINT","",""],[1,0,"",0,"",0,"VK_EXECUTE","",""],[1,0,"",0,"",0,"VK_SNAPSHOT","",""],[1,0,"",0,"",0,"VK_HELP","",""],[1,0,"",0,"",0,"VK_APPS","",""],[1,0,"",0,"",0,"VK_PROCESSKEY","",""],[1,0,"",0,"",0,"VK_PACKET","",""],[1,0,"",0,"",0,"VK_DBE_SBCSCHAR","",""],[1,0,"",0,"",0,"VK_DBE_DBCSCHAR","",""],[1,0,"",0,"",0,"VK_ATTN","",""],[1,0,"",0,"",0,"VK_CRSEL","",""],[1,0,"",0,"",0,"VK_EXSEL","",""],[1,0,"",0,"",0,"VK_EREOF","",""],[1,0,"",0,"",0,"VK_PLAY","",""],[1,0,"",0,"",0,"VK_ZOOM","",""],[1,0,"",0,"",0,"VK_NONAME","",""],[1,0,"",0,"",0,"VK_PA1","",""],[1,0,"",0,"",0,"VK_OEM_CLEAR","",""]]){let[n,r,o,s,a,l,h,u,d]=i;if(!t[r]&&(t[r]=!0,nH[r]=o,nV[o]=r,nW[o.toLowerCase()]=r,n&&(nG[r]=s,0!==s&&3!==s&&5!==s&&4!==s&&6!==s&&57!==s&&(nj[s]=r))),!e[s]){if(e[s]=!0,!a)throw Error(`String representation missing for key code ${s} around scan code ${o}`);nk.define(s,a),nP.define(s,u||a),nF.define(s,d||u||a)}l&&(nB[l]=s),h&&(nU[h]=s)}nj[3]=46}(),(y=te||(te={})).toString=function(e){return nk.keyCodeToStr(e)},y.fromString=function(e){return nk.strToKeyCode(e)},y.toUserSettingsUS=function(e){return nP.keyCodeToStr(e)},y.toUserSettingsGeneral=function(e){return nF.keyCodeToStr(e)},y.fromUserSettings=function(e){return nP.strToKeyCode(e)||nF.strToKeyCode(e)},y.toElectronAccelerator=function(e){if(e>=98&&e<=113)return null;switch(e){case 16:return"Up";case 18:return"Down";case 15:return"Left";case 17:return"Right"}return nk.keyCodeToStr(e)};var nz=i(1432),nK=i(83454);if(void 0!==nz.li.vscode&&void 0!==nz.li.vscode.process){let e=nz.li.vscode.process;n={get platform(){return e.platform},get arch(){return e.arch},get env(){return e.env},cwd:()=>e.cwd()}}else n=void 0!==nK?{get platform(){return nK.platform},get arch(){return nK.arch},get env(){return nK.env},cwd:()=>nK.env.VSCODE_CWD||nK.cwd()}:{get platform(){return nz.ED?"win32":nz.dz?"darwin":"linux"},get arch(){return},get env(){return{}},cwd:()=>"/"};let nY=n.cwd,n$=n.env,nq=n.platform;class nX extends Error{constructor(e,t,i){let n;"string"==typeof t&&0===t.indexOf("not ")?(n="must not be",t=t.replace(/^not /,"")):n="must be";let r=-1!==e.indexOf(".")?"property":"argument",o=`The "${e}" ${r} ${n} of type ${t}`;super(o+=`. Received type ${typeof i}`),this.code="ERR_INVALID_ARG_TYPE"}}function nZ(e,t){if("string"!=typeof e)throw new nX(t,"string",e)}let nQ="win32"===nq;function nJ(e){return 47===e||92===e}function n0(e){return 47===e}function n1(e){return e>=65&&e<=90||e>=97&&e<=122}function n2(e,t,i,n){let r="",o=0,s=-1,a=0,l=0;for(let h=0;h<=e.length;++h){if(h2){let e=r.lastIndexOf(i);-1===e?(r="",o=0):o=(r=r.slice(0,e)).length-1-r.lastIndexOf(i),s=h,a=0;continue}if(0!==r.length){r="",o=0,s=h,a=0;continue}}t&&(r+=r.length>0?`${i}..`:"..",o=2)}else r.length>0?r+=`${i}${e.slice(s+1,h)}`:r=e.slice(s+1,h),o=h-s-1;s=h,a=0}else 46===l&&-1!==a?++a:a=-1}return r}function n5(e,t){!function(e,t){if(null===e||"object"!=typeof e)throw new nX(t,"Object",e)}(t,"pathObject");let i=t.dir||t.root,n=t.base||`${t.name||""}${t.ext||""}`;return i?i===t.root?`${i}${n}`:`${i}${e}${n}`:n}let n4={resolve(...e){let t="",i="",n=!1;for(let r=e.length-1;r>=-1;r--){let o;if(r>=0){if(nZ(o=e[r],"path"),0===o.length)continue}else 0===t.length?o=nY():(void 0===(o=n$[`=${t}`]||nY())||o.slice(0,2).toLowerCase()!==t.toLowerCase()&&92===o.charCodeAt(2))&&(o=`${t}\\`);let s=o.length,a=0,l="",h=!1,u=o.charCodeAt(0);if(1===s)nJ(u)&&(a=1,h=!0);else if(nJ(u)){if(h=!0,nJ(o.charCodeAt(1))){let e=2,t=2;for(;e2&&nJ(o.charCodeAt(2))&&(h=!0,a=3));if(l.length>0){if(t.length>0){if(l.toLowerCase()!==t.toLowerCase())continue}else t=l}if(n){if(t.length>0)break}else if(i=`${o.slice(a)}\\${i}`,n=h,h&&t.length>0)break}return i=n2(i,!n,"\\",nJ),n?`${t}\\${i}`:`${t}${i}`||"."},normalize(e){let t;nZ(e,"path");let i=e.length;if(0===i)return".";let n=0,r=!1,o=e.charCodeAt(0);if(1===i)return n0(o)?"\\":e;if(nJ(o)){if(r=!0,nJ(e.charCodeAt(1))){let r=2,o=2;for(;r2&&nJ(e.charCodeAt(2))&&(r=!0,n=3));let s=n0&&nJ(e.charCodeAt(i-1))&&(s+="\\"),void 0===t)?r?`\\${s}`:s:r?`${t}\\${s}`:`${t}${s}`},isAbsolute(e){nZ(e,"path");let t=e.length;if(0===t)return!1;let i=e.charCodeAt(0);return nJ(i)||t>2&&n1(i)&&58===e.charCodeAt(1)&&nJ(e.charCodeAt(2))},join(...e){let t,i;if(0===e.length)return".";for(let n=0;n0&&(void 0===t?t=i=r:t+=`\\${r}`)}if(void 0===t)return".";let n=!0,r=0;if("string"==typeof i&&nJ(i.charCodeAt(0))){++r;let e=i.length;e>1&&nJ(i.charCodeAt(1))&&(++r,e>2&&(nJ(i.charCodeAt(2))?++r:n=!1))}if(n){for(;r=2&&(t=`\\${t.slice(r)}`)}return n4.normalize(t)},relative(e,t){if(nZ(e,"from"),nZ(t,"to"),e===t)return"";let i=n4.resolve(e),n=n4.resolve(t);if(i===n||(e=i.toLowerCase())===(t=n.toLowerCase()))return"";let r=0;for(;rr&&92===e.charCodeAt(o-1);)o--;let s=o-r,a=0;for(;aa&&92===t.charCodeAt(l-1);)l--;let h=l-a,u=su){if(92===t.charCodeAt(a+c))return n.slice(a+c+1);if(2===c)return n.slice(a+c)}s>u&&(92===e.charCodeAt(r+c)?d=c:2===c&&(d=3)),-1===d&&(d=0)}let f="";for(c=r+d+1;c<=o;++c)(c===o||92===e.charCodeAt(c))&&(f+=0===f.length?"..":"\\..");return(a+=d,f.length>0)?`${f}${n.slice(a,l)}`:(92===n.charCodeAt(a)&&++a,n.slice(a,l))},toNamespacedPath(e){if("string"!=typeof e||0===e.length)return e;let t=n4.resolve(e);if(t.length<=2)return e;if(92===t.charCodeAt(0)){if(92===t.charCodeAt(1)){let e=t.charCodeAt(2);if(63!==e&&46!==e)return`\\\\?\\UNC\\${t.slice(2)}`}}else if(n1(t.charCodeAt(0))&&58===t.charCodeAt(1)&&92===t.charCodeAt(2))return`\\\\?\\${t}`;return e},dirname(e){nZ(e,"path");let t=e.length;if(0===t)return".";let i=-1,n=0,r=e.charCodeAt(0);if(1===t)return nJ(r)?e:".";if(nJ(r)){if(i=n=1,nJ(e.charCodeAt(1))){let r=2,o=2;for(;r2&&nJ(e.charCodeAt(2))?3:2);let o=-1,s=!0;for(let i=t-1;i>=n;--i)if(nJ(e.charCodeAt(i))){if(!s){o=i;break}}else s=!1;if(-1===o){if(-1===i)return".";o=i}return e.slice(0,o)},basename(e,t){let i;void 0!==t&&nZ(t,"ext"),nZ(e,"path");let n=0,r=-1,o=!0;if(e.length>=2&&n1(e.charCodeAt(0))&&58===e.charCodeAt(1)&&(n=2),void 0!==t&&t.length>0&&t.length<=e.length){if(t===e)return"";let s=t.length-1,a=-1;for(i=e.length-1;i>=n;--i){let l=e.charCodeAt(i);if(nJ(l)){if(!o){n=i+1;break}}else -1===a&&(o=!1,a=i+1),s>=0&&(l===t.charCodeAt(s)?-1==--s&&(r=i):(s=-1,r=a))}return n===r?r=a:-1===r&&(r=e.length),e.slice(n,r)}for(i=e.length-1;i>=n;--i)if(nJ(e.charCodeAt(i))){if(!o){n=i+1;break}}else -1===r&&(o=!1,r=i+1);return -1===r?"":e.slice(n,r)},extname(e){nZ(e,"path");let t=0,i=-1,n=0,r=-1,o=!0,s=0;e.length>=2&&58===e.charCodeAt(1)&&n1(e.charCodeAt(0))&&(t=n=2);for(let a=e.length-1;a>=t;--a){let t=e.charCodeAt(a);if(nJ(t)){if(!o){n=a+1;break}continue}-1===r&&(o=!1,r=a+1),46===t?-1===i?i=a:1!==s&&(s=1):-1!==i&&(s=-1)}return -1===i||-1===r||0===s||1===s&&i===r-1&&i===n+1?"":e.slice(i,r)},format:n5.bind(null,"\\"),parse(e){nZ(e,"path");let t={root:"",dir:"",base:"",ext:"",name:""};if(0===e.length)return t;let i=e.length,n=0,r=e.charCodeAt(0);if(1===i)return nJ(r)?(t.root=t.dir=e,t):(t.base=t.name=e,t);if(nJ(r)){if(n=1,nJ(e.charCodeAt(1))){let t=2,r=2;for(;t0&&(t.root=e.slice(0,n));let o=-1,s=n,a=-1,l=!0,h=e.length-1,u=0;for(;h>=n;--h){if(nJ(r=e.charCodeAt(h))){if(!l){s=h+1;break}continue}-1===a&&(l=!1,a=h+1),46===r?-1===o?o=h:1!==u&&(u=1):-1!==o&&(u=-1)}return -1!==a&&(-1===o||0===u||1===u&&o===a-1&&o===s+1?t.base=t.name=e.slice(s,a):(t.name=e.slice(s,o),t.base=e.slice(s,a),t.ext=e.slice(o,a))),s>0&&s!==n?t.dir=e.slice(0,s-1):t.dir=t.root,t},sep:"\\",delimiter:";",win32:null,posix:null},n3=(()=>{if(nQ){let e=/\\/g;return()=>{let t=nY().replace(e,"/");return t.slice(t.indexOf("/"))}}return()=>nY()})(),n6={resolve(...e){let t="",i=!1;for(let n=e.length-1;n>=-1&&!i;n--){let r=n>=0?e[n]:n3();nZ(r,"path"),0!==r.length&&(t=`${r}/${t}`,i=47===r.charCodeAt(0))}return(t=n2(t,!i,"/",n0),i)?`/${t}`:t.length>0?t:"."},normalize(e){if(nZ(e,"path"),0===e.length)return".";let t=47===e.charCodeAt(0),i=47===e.charCodeAt(e.length-1);return 0===(e=n2(e,!t,"/",n0)).length?t?"/":i?"./":".":(i&&(e+="/"),t?`/${e}`:e)},isAbsolute:e=>(nZ(e,"path"),e.length>0&&47===e.charCodeAt(0)),join(...e){let t;if(0===e.length)return".";for(let i=0;i0&&(void 0===t?t=n:t+=`/${n}`)}return void 0===t?".":n6.normalize(t)},relative(e,t){if(nZ(e,"from"),nZ(t,"to"),e===t||(e=n6.resolve(e))===(t=n6.resolve(t)))return"";let i=e.length,n=i-1,r=t.length-1,o=no){if(47===t.charCodeAt(1+a))return t.slice(1+a+1);if(0===a)return t.slice(1+a)}else n>o&&(47===e.charCodeAt(1+a)?s=a:0===a&&(s=0))}let l="";for(a=1+s+1;a<=i;++a)(a===i||47===e.charCodeAt(a))&&(l+=0===l.length?"..":"/..");return`${l}${t.slice(1+s)}`},toNamespacedPath:e=>e,dirname(e){if(nZ(e,"path"),0===e.length)return".";let t=47===e.charCodeAt(0),i=-1,n=!0;for(let t=e.length-1;t>=1;--t)if(47===e.charCodeAt(t)){if(!n){i=t;break}}else n=!1;return -1===i?t?"/":".":t&&1===i?"//":e.slice(0,i)},basename(e,t){let i;void 0!==t&&nZ(t,"ext"),nZ(e,"path");let n=0,r=-1,o=!0;if(void 0!==t&&t.length>0&&t.length<=e.length){if(t===e)return"";let s=t.length-1,a=-1;for(i=e.length-1;i>=0;--i){let l=e.charCodeAt(i);if(47===l){if(!o){n=i+1;break}}else -1===a&&(o=!1,a=i+1),s>=0&&(l===t.charCodeAt(s)?-1==--s&&(r=i):(s=-1,r=a))}return n===r?r=a:-1===r&&(r=e.length),e.slice(n,r)}for(i=e.length-1;i>=0;--i)if(47===e.charCodeAt(i)){if(!o){n=i+1;break}}else -1===r&&(o=!1,r=i+1);return -1===r?"":e.slice(n,r)},extname(e){nZ(e,"path");let t=-1,i=0,n=-1,r=!0,o=0;for(let s=e.length-1;s>=0;--s){let a=e.charCodeAt(s);if(47===a){if(!r){i=s+1;break}continue}-1===n&&(r=!1,n=s+1),46===a?-1===t?t=s:1!==o&&(o=1):-1!==t&&(o=-1)}return -1===t||-1===n||0===o||1===o&&t===n-1&&t===i+1?"":e.slice(t,n)},format:n5.bind(null,"/"),parse(e){let t;nZ(e,"path");let i={root:"",dir:"",base:"",ext:"",name:""};if(0===e.length)return i;let n=47===e.charCodeAt(0);n?(i.root="/",t=1):t=0;let r=-1,o=0,s=-1,a=!0,l=e.length-1,h=0;for(;l>=t;--l){let t=e.charCodeAt(l);if(47===t){if(!a){o=l+1;break}continue}-1===s&&(a=!1,s=l+1),46===t?-1===r?r=l:1!==h&&(h=1):-1!==r&&(h=-1)}if(-1!==s){let t=0===o&&n?1:o;-1===r||0===h||1===h&&r===s-1&&r===o+1?i.base=i.name=e.slice(t,s):(i.name=e.slice(t,r),i.base=e.slice(t,s),i.ext=e.slice(r,s))}return o>0?i.dir=e.slice(0,o-1):n&&(i.dir="/"),i},sep:"/",delimiter:":",win32:null,posix:null};n6.win32=n4.win32=n4,n6.posix=n4.posix=n6;let n9=nQ?n4.normalize:n6.normalize,n8=nQ?n4.resolve:n6.resolve,n7=nQ?n4.relative:n6.relative,re=nQ?n4.dirname:n6.dirname,rt=nQ?n4.basename:n6.basename,ri=nQ?n4.extname:n6.extname,rn=nQ?n4.sep:n6.sep,rr=/^\w[\w\d+.-]*$/,ro=/^\//,rs=/^\/\//,ra=/^(([^:/?#]+?):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?/;class rl{static isUri(e){return e instanceof rl||!!e&&"string"==typeof e.authority&&"string"==typeof e.fragment&&"string"==typeof e.path&&"string"==typeof e.query&&"string"==typeof e.scheme&&"string"==typeof e.fsPath&&"function"==typeof e.with&&"function"==typeof e.toString}constructor(e,t,i,n,r,o=!1){"object"==typeof e?(this.scheme=e.scheme||"",this.authority=e.authority||"",this.path=e.path||"",this.query=e.query||"",this.fragment=e.fragment||""):(this.scheme=e||o?e:"file",this.authority=t||"",this.path=function(e,t){switch(e){case"https":case"http":case"file":t?"/"!==t[0]&&(t="/"+t):t="/"}return t}(this.scheme,i||""),this.query=n||"",this.fragment=r||"",function(e,t){if(!e.scheme&&t)throw Error(`[UriError]: Scheme is missing: {scheme: "", authority: "${e.authority}", path: "${e.path}", query: "${e.query}", fragment: "${e.fragment}"}`);if(e.scheme&&!rr.test(e.scheme))throw Error("[UriError]: Scheme contains illegal characters.");if(e.path){if(e.authority){if(!ro.test(e.path))throw Error('[UriError]: If a URI contains an authority component, then the path component must either be empty or begin with a slash ("/") character')}else if(rs.test(e.path))throw Error('[UriError]: If a URI does not contain an authority component, then the path cannot begin with two slash characters ("//")')}}(this,o))}get fsPath(){return rg(this,!1)}with(e){if(!e)return this;let{scheme:t,authority:i,path:n,query:r,fragment:o}=e;return(void 0===t?t=this.scheme:null===t&&(t=""),void 0===i?i=this.authority:null===i&&(i=""),void 0===n?n=this.path:null===n&&(n=""),void 0===r?r=this.query:null===r&&(r=""),void 0===o?o=this.fragment:null===o&&(o=""),t===this.scheme&&i===this.authority&&n===this.path&&r===this.query&&o===this.fragment)?this:new ru(t,i,n,r,o)}static parse(e,t=!1){let i=ra.exec(e);return i?new ru(i[2]||"",r_(i[4]||""),r_(i[5]||""),r_(i[7]||""),r_(i[9]||""),t):new ru("","","","","")}static file(e){let t="";if(nz.ED&&(e=e.replace(/\\/g,"/")),"/"===e[0]&&"/"===e[1]){let i=e.indexOf("/",2);-1===i?(t=e.substring(2),e="/"):(t=e.substring(2,i),e=e.substring(i)||"/")}return new ru("file",t,e,"","")}static from(e,t){let i=new ru(e.scheme,e.authority,e.path,e.query,e.fragment,t);return i}static joinPath(e,...t){let i;if(!e.path)throw Error("[UriError]: cannot call joinPath on URI without path");return i=nz.ED&&"file"===e.scheme?rl.file(n4.join(rg(e,!0),...t)).path:n6.join(e.path,...t),e.with({path:i})}toString(e=!1){return rp(this,e)}toJSON(){return this}static revive(e){var t,i;if(!e||e instanceof rl)return e;{let n=new ru(e);return n._formatted=null!==(t=e.external)&&void 0!==t?t:null,n._fsPath=e._sep===rh&&null!==(i=e.fsPath)&&void 0!==i?i:null,n}}}let rh=nz.ED?1:void 0;class ru extends rl{constructor(){super(...arguments),this._formatted=null,this._fsPath=null}get fsPath(){return this._fsPath||(this._fsPath=rg(this,!1)),this._fsPath}toString(e=!1){return e?rp(this,!0):(this._formatted||(this._formatted=rp(this,!1)),this._formatted)}toJSON(){let e={$mid:1};return this._fsPath&&(e.fsPath=this._fsPath,e._sep=rh),this._formatted&&(e.external=this._formatted),this.path&&(e.path=this.path),this.scheme&&(e.scheme=this.scheme),this.authority&&(e.authority=this.authority),this.query&&(e.query=this.query),this.fragment&&(e.fragment=this.fragment),e}}let rd={58:"%3A",47:"%2F",63:"%3F",35:"%23",91:"%5B",93:"%5D",64:"%40",33:"%21",36:"%24",38:"%26",39:"%27",40:"%28",41:"%29",42:"%2A",43:"%2B",44:"%2C",59:"%3B",61:"%3D",32:"%20"};function rc(e,t,i){let n;let r=-1;for(let o=0;o=97&&s<=122||s>=65&&s<=90||s>=48&&s<=57||45===s||46===s||95===s||126===s||t&&47===s||i&&91===s||i&&93===s||i&&58===s)-1!==r&&(n+=encodeURIComponent(e.substring(r,o)),r=-1),void 0!==n&&(n+=e.charAt(o));else{void 0===n&&(n=e.substr(0,o));let t=rd[s];void 0!==t?(-1!==r&&(n+=encodeURIComponent(e.substring(r,o)),r=-1),n+=t):-1===r&&(r=o)}}return -1!==r&&(n+=encodeURIComponent(e.substring(r))),void 0!==n?n:e}function rf(e){let t;for(let i=0;i1&&"file"===e.scheme?`//${e.authority}${e.path}`:47===e.path.charCodeAt(0)&&(e.path.charCodeAt(1)>=65&&90>=e.path.charCodeAt(1)||e.path.charCodeAt(1)>=97&&122>=e.path.charCodeAt(1))&&58===e.path.charCodeAt(2)?t?e.path.substr(1):e.path[1].toLowerCase()+e.path.substr(2):e.path,nz.ED&&(i=i.replace(/\//g,"\\")),i}function rp(e,t){let i=t?rf:rc,n="",{scheme:r,authority:o,path:s,query:a,fragment:l}=e;if(r&&(n+=r+":"),(o||"file"===r)&&(n+="//"),o){let e=o.indexOf("@");if(-1!==e){let t=o.substr(0,e);o=o.substr(e+1),-1===(e=t.lastIndexOf(":"))?n+=i(t,!1,!1):n+=i(t.substr(0,e),!1,!1)+":"+i(t.substr(e+1),!1,!0),n+="@"}-1===(e=(o=o.toLowerCase()).lastIndexOf(":"))?n+=i(o,!1,!0):n+=i(o.substr(0,e),!1,!0)+o.substr(e)}if(s){if(s.length>=3&&47===s.charCodeAt(0)&&58===s.charCodeAt(2)){let e=s.charCodeAt(1);e>=65&&e<=90&&(s=`/${String.fromCharCode(e+32)}:${s.substr(3)}`)}else if(s.length>=2&&58===s.charCodeAt(1)){let e=s.charCodeAt(0);e>=65&&e<=90&&(s=`${String.fromCharCode(e+32)}:${s.substr(2)}`)}n+=i(s,!0,!1)}return a&&(n+="?"+i(a,!1,!1)),l&&(n+="#"+(t?l:rc(l,!1,!1))),n}let rm=/(%[0-9A-Za-z][0-9A-Za-z])+/g;function r_(e){return e.match(rm)?e.replace(rm,e=>(function e(t){try{return decodeURIComponent(t)}catch(i){if(t.length>3)return t.substr(0,3)+e(t.substr(3));return t}})(e)):e}class rE{constructor(e,t){this.lineNumber=e,this.column=t}with(e=this.lineNumber,t=this.column){return e===this.lineNumber&&t===this.column?this:new rE(e,t)}delta(e=0,t=0){return this.with(this.lineNumber+e,this.column+t)}equals(e){return rE.equals(this,e)}static equals(e,t){return!e&&!t||!!e&&!!t&&e.lineNumber===t.lineNumber&&e.column===t.column}isBefore(e){return rE.isBefore(this,e)}static isBefore(e,t){return e.lineNumberi||e===i&&t>n?(this.startLineNumber=i,this.startColumn=n,this.endLineNumber=e,this.endColumn=t):(this.startLineNumber=e,this.startColumn=t,this.endLineNumber=i,this.endColumn=n)}isEmpty(){return rv.isEmpty(this)}static isEmpty(e){return e.startLineNumber===e.endLineNumber&&e.startColumn===e.endColumn}containsPosition(e){return rv.containsPosition(this,e)}static containsPosition(e,t){return!(t.lineNumbere.endLineNumber)&&(t.lineNumber!==e.startLineNumber||!(t.columne.endColumn))}static strictContainsPosition(e,t){return!(t.lineNumbere.endLineNumber)&&(t.lineNumber!==e.startLineNumber||!(t.column<=e.startColumn))&&(t.lineNumber!==e.endLineNumber||!(t.column>=e.endColumn))}containsRange(e){return rv.containsRange(this,e)}static containsRange(e,t){return!(t.startLineNumbere.endLineNumber)&&!(t.endLineNumber>e.endLineNumber)&&(t.startLineNumber!==e.startLineNumber||!(t.startColumne.endColumn))}strictContainsRange(e){return rv.strictContainsRange(this,e)}static strictContainsRange(e,t){return!(t.startLineNumbere.endLineNumber)&&!(t.endLineNumber>e.endLineNumber)&&(t.startLineNumber!==e.startLineNumber||!(t.startColumn<=e.startColumn))&&(t.endLineNumber!==e.endLineNumber||!(t.endColumn>=e.endColumn))}plusRange(e){return rv.plusRange(this,e)}static plusRange(e,t){let i,n,r,o;return t.startLineNumbere.endLineNumber?(r=t.endLineNumber,o=t.endColumn):t.endLineNumber===e.endLineNumber?(r=t.endLineNumber,o=Math.max(t.endColumn,e.endColumn)):(r=e.endLineNumber,o=e.endColumn),new rv(i,n,r,o)}intersectRanges(e){return rv.intersectRanges(this,e)}static intersectRanges(e,t){let i=e.startLineNumber,n=e.startColumn,r=e.endLineNumber,o=e.endColumn,s=t.startLineNumber,a=t.startColumn,l=t.endLineNumber,h=t.endColumn;return(il?(r=l,o=h):r===l&&(o=Math.min(o,h)),i>r||i===r&&n>o)?null:new rv(i,n,r,o)}equalsRange(e){return rv.equalsRange(this,e)}static equalsRange(e,t){return!e&&!t||!!e&&!!t&&e.startLineNumber===t.startLineNumber&&e.startColumn===t.startColumn&&e.endLineNumber===t.endLineNumber&&e.endColumn===t.endColumn}getEndPosition(){return rv.getEndPosition(this)}static getEndPosition(e){return new rE(e.endLineNumber,e.endColumn)}getStartPosition(){return rv.getStartPosition(this)}static getStartPosition(e){return new rE(e.startLineNumber,e.startColumn)}toString(){return"["+this.startLineNumber+","+this.startColumn+" -> "+this.endLineNumber+","+this.endColumn+"]"}setEndPosition(e,t){return new rv(this.startLineNumber,this.startColumn,e,t)}setStartPosition(e,t){return new rv(e,t,this.endLineNumber,this.endColumn)}collapseToStart(){return rv.collapseToStart(this)}static collapseToStart(e){return new rv(e.startLineNumber,e.startColumn,e.startLineNumber,e.startColumn)}collapseToEnd(){return rv.collapseToEnd(this)}static collapseToEnd(e){return new rv(e.endLineNumber,e.endColumn,e.endLineNumber,e.endColumn)}delta(e){return new rv(this.startLineNumber+e,this.startColumn,this.endLineNumber+e,this.endColumn)}static fromPositions(e,t=e){return new rv(e.lineNumber,e.column,t.lineNumber,t.column)}static lift(e){return e?new rv(e.startLineNumber,e.startColumn,e.endLineNumber,e.endColumn):null}static isIRange(e){return e&&"number"==typeof e.startLineNumber&&"number"==typeof e.startColumn&&"number"==typeof e.endLineNumber&&"number"==typeof e.endColumn}static areIntersectingOrTouching(e,t){return!(e.endLineNumbere.startLineNumber}toJSON(){return this}}class rb extends rv{constructor(e,t,i,n){super(e,t,i,n),this.selectionStartLineNumber=e,this.selectionStartColumn=t,this.positionLineNumber=i,this.positionColumn=n}toString(){return"["+this.selectionStartLineNumber+","+this.selectionStartColumn+" -> "+this.positionLineNumber+","+this.positionColumn+"]"}equalsSelection(e){return rb.selectionsEqual(this,e)}static selectionsEqual(e,t){return e.selectionStartLineNumber===t.selectionStartLineNumber&&e.selectionStartColumn===t.selectionStartColumn&&e.positionLineNumber===t.positionLineNumber&&e.positionColumn===t.positionColumn}getDirection(){return this.selectionStartLineNumber===this.startLineNumber&&this.selectionStartColumn===this.startColumn?0:1}setEndPosition(e,t){return 0===this.getDirection()?new rb(this.startLineNumber,this.startColumn,e,t):new rb(e,t,this.startLineNumber,this.startColumn)}getPosition(){return new rE(this.positionLineNumber,this.positionColumn)}getSelectionStart(){return new rE(this.selectionStartLineNumber,this.selectionStartColumn)}setStartPosition(e,t){return 0===this.getDirection()?new rb(e,t,this.endLineNumber,this.endColumn):new rb(this.endLineNumber,this.endColumn,e,t)}static fromPositions(e,t=e){return new rb(e.lineNumber,e.column,t.lineNumber,t.column)}static fromRange(e,t){return 0===t?new rb(e.startLineNumber,e.startColumn,e.endLineNumber,e.endColumn):new rb(e.endLineNumber,e.endColumn,e.startLineNumber,e.startColumn)}static liftSelection(e){return new rb(e.selectionStartLineNumber,e.selectionStartColumn,e.positionLineNumber,e.positionColumn)}static selectionsArrEqual(e,t){if(e&&!t||!e&&t)return!1;if(!e&&!t)return!0;if(e.length!==t.length)return!1;for(let i=0,n=e.length;i{e&&e.dispose()})}get tokenizationSupport(){return this._tokenizationSupport||(this._tokenizationSupport=this.createSupport()),this._tokenizationSupport}}let rx=new class{constructor(){this._tokenizationSupports=new Map,this._factories=new Map,this._onDidChange=new ny,this.onDidChange=this._onDidChange.event,this._colorMap=null}handleChange(e){this._onDidChange.fire({changedLanguages:e,changedColorMap:!1})}register(e,t){return this._tokenizationSupports.set(e,t),this.handleChange([e]),nu(()=>{this._tokenizationSupports.get(e)===t&&(this._tokenizationSupports.delete(e),this.handleChange([e]))})}get(e){return this._tokenizationSupports.get(e)||null}registerFactory(e,t){var i;null===(i=this._factories.get(e))||void 0===i||i.dispose();let n=new rA(this,e,t);return this._factories.set(e,n),nu(()=>{let t=this._factories.get(e);t&&t===n&&(this._factories.delete(e),t.dispose())})}getOrCreate(e){return rR(this,void 0,void 0,function*(){let t=this.get(e);if(t)return t;let i=this._factories.get(e);return!i||i.isResolved?null:(yield i.resolve(),this.get(e))})}isResolved(e){let t=this.get(e);if(t)return!0;let i=this._factories.get(e);return!i||!!i.isResolved}setColorMap(e){this._colorMap=e,this._onDidChange.fire({changedLanguages:Array.from(this._tokenizationSupports.keys()),changedColorMap:!0})}getColorMap(){return this._colorMap}getDefaultBackground(){return this._colorMap&&this._colorMap.length>2?this._colorMap[2]:null}};(O=tl||(tl={}))[O.Unknown=0]="Unknown",O[O.Disabled=1]="Disabled",O[O.Enabled=2]="Enabled",(L=th||(th={}))[L.Invoke=1]="Invoke",L[L.Auto=2]="Auto",(I=tu||(tu={}))[I.None=0]="None",I[I.KeepWhitespace=1]="KeepWhitespace",I[I.InsertAsSnippet=4]="InsertAsSnippet",(w=td||(td={}))[w.Method=0]="Method",w[w.Function=1]="Function",w[w.Constructor=2]="Constructor",w[w.Field=3]="Field",w[w.Variable=4]="Variable",w[w.Class=5]="Class",w[w.Struct=6]="Struct",w[w.Interface=7]="Interface",w[w.Module=8]="Module",w[w.Property=9]="Property",w[w.Event=10]="Event",w[w.Operator=11]="Operator",w[w.Unit=12]="Unit",w[w.Value=13]="Value",w[w.Constant=14]="Constant",w[w.Enum=15]="Enum",w[w.EnumMember=16]="EnumMember",w[w.Keyword=17]="Keyword",w[w.Text=18]="Text",w[w.Color=19]="Color",w[w.File=20]="File",w[w.Reference=21]="Reference",w[w.Customcolor=22]="Customcolor",w[w.Folder=23]="Folder",w[w.TypeParameter=24]="TypeParameter",w[w.User=25]="User",w[w.Issue=26]="Issue",w[w.Snippet=27]="Snippet",(D=tc||(tc={}))[D.Deprecated=1]="Deprecated",(x=tf||(tf={}))[x.Invoke=0]="Invoke",x[x.TriggerCharacter=1]="TriggerCharacter",x[x.TriggerForIncompleteCompletions=2]="TriggerForIncompleteCompletions",(M=tg||(tg={}))[M.EXACT=0]="EXACT",M[M.ABOVE=1]="ABOVE",M[M.BELOW=2]="BELOW",(k=tp||(tp={}))[k.NotSet=0]="NotSet",k[k.ContentFlush=1]="ContentFlush",k[k.RecoverFromMarkers=2]="RecoverFromMarkers",k[k.Explicit=3]="Explicit",k[k.Paste=4]="Paste",k[k.Undo=5]="Undo",k[k.Redo=6]="Redo",(P=tm||(tm={}))[P.LF=1]="LF",P[P.CRLF=2]="CRLF",(F=t_||(t_={}))[F.Text=0]="Text",F[F.Read=1]="Read",F[F.Write=2]="Write",(B=tE||(tE={}))[B.None=0]="None",B[B.Keep=1]="Keep",B[B.Brackets=2]="Brackets",B[B.Advanced=3]="Advanced",B[B.Full=4]="Full",(U=tv||(tv={}))[U.acceptSuggestionOnCommitCharacter=0]="acceptSuggestionOnCommitCharacter",U[U.acceptSuggestionOnEnter=1]="acceptSuggestionOnEnter",U[U.accessibilitySupport=2]="accessibilitySupport",U[U.accessibilityPageSize=3]="accessibilityPageSize",U[U.ariaLabel=4]="ariaLabel",U[U.ariaRequired=5]="ariaRequired",U[U.autoClosingBrackets=6]="autoClosingBrackets",U[U.screenReaderAnnounceInlineSuggestion=7]="screenReaderAnnounceInlineSuggestion",U[U.autoClosingDelete=8]="autoClosingDelete",U[U.autoClosingOvertype=9]="autoClosingOvertype",U[U.autoClosingQuotes=10]="autoClosingQuotes",U[U.autoIndent=11]="autoIndent",U[U.automaticLayout=12]="automaticLayout",U[U.autoSurround=13]="autoSurround",U[U.bracketPairColorization=14]="bracketPairColorization",U[U.guides=15]="guides",U[U.codeLens=16]="codeLens",U[U.codeLensFontFamily=17]="codeLensFontFamily",U[U.codeLensFontSize=18]="codeLensFontSize",U[U.colorDecorators=19]="colorDecorators",U[U.colorDecoratorsLimit=20]="colorDecoratorsLimit",U[U.columnSelection=21]="columnSelection",U[U.comments=22]="comments",U[U.contextmenu=23]="contextmenu",U[U.copyWithSyntaxHighlighting=24]="copyWithSyntaxHighlighting",U[U.cursorBlinking=25]="cursorBlinking",U[U.cursorSmoothCaretAnimation=26]="cursorSmoothCaretAnimation",U[U.cursorStyle=27]="cursorStyle",U[U.cursorSurroundingLines=28]="cursorSurroundingLines",U[U.cursorSurroundingLinesStyle=29]="cursorSurroundingLinesStyle",U[U.cursorWidth=30]="cursorWidth",U[U.disableLayerHinting=31]="disableLayerHinting",U[U.disableMonospaceOptimizations=32]="disableMonospaceOptimizations",U[U.domReadOnly=33]="domReadOnly",U[U.dragAndDrop=34]="dragAndDrop",U[U.dropIntoEditor=35]="dropIntoEditor",U[U.emptySelectionClipboard=36]="emptySelectionClipboard",U[U.experimentalWhitespaceRendering=37]="experimentalWhitespaceRendering",U[U.extraEditorClassName=38]="extraEditorClassName",U[U.fastScrollSensitivity=39]="fastScrollSensitivity",U[U.find=40]="find",U[U.fixedOverflowWidgets=41]="fixedOverflowWidgets",U[U.folding=42]="folding",U[U.foldingStrategy=43]="foldingStrategy",U[U.foldingHighlight=44]="foldingHighlight",U[U.foldingImportsByDefault=45]="foldingImportsByDefault",U[U.foldingMaximumRegions=46]="foldingMaximumRegions",U[U.unfoldOnClickAfterEndOfLine=47]="unfoldOnClickAfterEndOfLine",U[U.fontFamily=48]="fontFamily",U[U.fontInfo=49]="fontInfo",U[U.fontLigatures=50]="fontLigatures",U[U.fontSize=51]="fontSize",U[U.fontWeight=52]="fontWeight",U[U.fontVariations=53]="fontVariations",U[U.formatOnPaste=54]="formatOnPaste",U[U.formatOnType=55]="formatOnType",U[U.glyphMargin=56]="glyphMargin",U[U.gotoLocation=57]="gotoLocation",U[U.hideCursorInOverviewRuler=58]="hideCursorInOverviewRuler",U[U.hover=59]="hover",U[U.inDiffEditor=60]="inDiffEditor",U[U.inlineSuggest=61]="inlineSuggest",U[U.letterSpacing=62]="letterSpacing",U[U.lightbulb=63]="lightbulb",U[U.lineDecorationsWidth=64]="lineDecorationsWidth",U[U.lineHeight=65]="lineHeight",U[U.lineNumbers=66]="lineNumbers",U[U.lineNumbersMinChars=67]="lineNumbersMinChars",U[U.linkedEditing=68]="linkedEditing",U[U.links=69]="links",U[U.matchBrackets=70]="matchBrackets",U[U.minimap=71]="minimap",U[U.mouseStyle=72]="mouseStyle",U[U.mouseWheelScrollSensitivity=73]="mouseWheelScrollSensitivity",U[U.mouseWheelZoom=74]="mouseWheelZoom",U[U.multiCursorMergeOverlapping=75]="multiCursorMergeOverlapping",U[U.multiCursorModifier=76]="multiCursorModifier",U[U.multiCursorPaste=77]="multiCursorPaste",U[U.multiCursorLimit=78]="multiCursorLimit",U[U.occurrencesHighlight=79]="occurrencesHighlight",U[U.overviewRulerBorder=80]="overviewRulerBorder",U[U.overviewRulerLanes=81]="overviewRulerLanes",U[U.padding=82]="padding",U[U.pasteAs=83]="pasteAs",U[U.parameterHints=84]="parameterHints",U[U.peekWidgetDefaultFocus=85]="peekWidgetDefaultFocus",U[U.definitionLinkOpensInPeek=86]="definitionLinkOpensInPeek",U[U.quickSuggestions=87]="quickSuggestions",U[U.quickSuggestionsDelay=88]="quickSuggestionsDelay",U[U.readOnly=89]="readOnly",U[U.readOnlyMessage=90]="readOnlyMessage",U[U.renameOnType=91]="renameOnType",U[U.renderControlCharacters=92]="renderControlCharacters",U[U.renderFinalNewline=93]="renderFinalNewline",U[U.renderLineHighlight=94]="renderLineHighlight",U[U.renderLineHighlightOnlyWhenFocus=95]="renderLineHighlightOnlyWhenFocus",U[U.renderValidationDecorations=96]="renderValidationDecorations",U[U.renderWhitespace=97]="renderWhitespace",U[U.revealHorizontalRightPadding=98]="revealHorizontalRightPadding",U[U.roundedSelection=99]="roundedSelection",U[U.rulers=100]="rulers",U[U.scrollbar=101]="scrollbar",U[U.scrollBeyondLastColumn=102]="scrollBeyondLastColumn",U[U.scrollBeyondLastLine=103]="scrollBeyondLastLine",U[U.scrollPredominantAxis=104]="scrollPredominantAxis",U[U.selectionClipboard=105]="selectionClipboard",U[U.selectionHighlight=106]="selectionHighlight",U[U.selectOnLineNumbers=107]="selectOnLineNumbers",U[U.showFoldingControls=108]="showFoldingControls",U[U.showUnused=109]="showUnused",U[U.snippetSuggestions=110]="snippetSuggestions",U[U.smartSelect=111]="smartSelect",U[U.smoothScrolling=112]="smoothScrolling",U[U.stickyScroll=113]="stickyScroll",U[U.stickyTabStops=114]="stickyTabStops",U[U.stopRenderingLineAfter=115]="stopRenderingLineAfter",U[U.suggest=116]="suggest",U[U.suggestFontSize=117]="suggestFontSize",U[U.suggestLineHeight=118]="suggestLineHeight",U[U.suggestOnTriggerCharacters=119]="suggestOnTriggerCharacters",U[U.suggestSelection=120]="suggestSelection",U[U.tabCompletion=121]="tabCompletion",U[U.tabIndex=122]="tabIndex",U[U.unicodeHighlighting=123]="unicodeHighlighting",U[U.unusualLineTerminators=124]="unusualLineTerminators",U[U.useShadowDOM=125]="useShadowDOM",U[U.useTabStops=126]="useTabStops",U[U.wordBreak=127]="wordBreak",U[U.wordSeparators=128]="wordSeparators",U[U.wordWrap=129]="wordWrap",U[U.wordWrapBreakAfterCharacters=130]="wordWrapBreakAfterCharacters",U[U.wordWrapBreakBeforeCharacters=131]="wordWrapBreakBeforeCharacters",U[U.wordWrapColumn=132]="wordWrapColumn",U[U.wordWrapOverride1=133]="wordWrapOverride1",U[U.wordWrapOverride2=134]="wordWrapOverride2",U[U.wrappingIndent=135]="wrappingIndent",U[U.wrappingStrategy=136]="wrappingStrategy",U[U.showDeprecated=137]="showDeprecated",U[U.inlayHints=138]="inlayHints",U[U.editorClassName=139]="editorClassName",U[U.pixelRatio=140]="pixelRatio",U[U.tabFocusMode=141]="tabFocusMode",U[U.layoutInfo=142]="layoutInfo",U[U.wrappingInfo=143]="wrappingInfo",U[U.defaultColorDecorators=144]="defaultColorDecorators",U[U.colorDecoratorsActivatedOn=145]="colorDecoratorsActivatedOn",(H=tb||(tb={}))[H.TextDefined=0]="TextDefined",H[H.LF=1]="LF",H[H.CRLF=2]="CRLF",(V=tC||(tC={}))[V.LF=0]="LF",V[V.CRLF=1]="CRLF",(W=tS||(tS={}))[W.Left=1]="Left",W[W.Right=2]="Right",(G=ty||(ty={}))[G.None=0]="None",G[G.Indent=1]="Indent",G[G.IndentOutdent=2]="IndentOutdent",G[G.Outdent=3]="Outdent",(j=tT||(tT={}))[j.Both=0]="Both",j[j.Right=1]="Right",j[j.Left=2]="Left",j[j.None=3]="None",(z=tR||(tR={}))[z.Type=1]="Type",z[z.Parameter=2]="Parameter",(K=tA||(tA={}))[K.Automatic=0]="Automatic",K[K.Explicit=1]="Explicit",(Y=tN||(tN={}))[Y.DependsOnKbLayout=-1]="DependsOnKbLayout",Y[Y.Unknown=0]="Unknown",Y[Y.Backspace=1]="Backspace",Y[Y.Tab=2]="Tab",Y[Y.Enter=3]="Enter",Y[Y.Shift=4]="Shift",Y[Y.Ctrl=5]="Ctrl",Y[Y.Alt=6]="Alt",Y[Y.PauseBreak=7]="PauseBreak",Y[Y.CapsLock=8]="CapsLock",Y[Y.Escape=9]="Escape",Y[Y.Space=10]="Space",Y[Y.PageUp=11]="PageUp",Y[Y.PageDown=12]="PageDown",Y[Y.End=13]="End",Y[Y.Home=14]="Home",Y[Y.LeftArrow=15]="LeftArrow",Y[Y.UpArrow=16]="UpArrow",Y[Y.RightArrow=17]="RightArrow",Y[Y.DownArrow=18]="DownArrow",Y[Y.Insert=19]="Insert",Y[Y.Delete=20]="Delete",Y[Y.Digit0=21]="Digit0",Y[Y.Digit1=22]="Digit1",Y[Y.Digit2=23]="Digit2",Y[Y.Digit3=24]="Digit3",Y[Y.Digit4=25]="Digit4",Y[Y.Digit5=26]="Digit5",Y[Y.Digit6=27]="Digit6",Y[Y.Digit7=28]="Digit7",Y[Y.Digit8=29]="Digit8",Y[Y.Digit9=30]="Digit9",Y[Y.KeyA=31]="KeyA",Y[Y.KeyB=32]="KeyB",Y[Y.KeyC=33]="KeyC",Y[Y.KeyD=34]="KeyD",Y[Y.KeyE=35]="KeyE",Y[Y.KeyF=36]="KeyF",Y[Y.KeyG=37]="KeyG",Y[Y.KeyH=38]="KeyH",Y[Y.KeyI=39]="KeyI",Y[Y.KeyJ=40]="KeyJ",Y[Y.KeyK=41]="KeyK",Y[Y.KeyL=42]="KeyL",Y[Y.KeyM=43]="KeyM",Y[Y.KeyN=44]="KeyN",Y[Y.KeyO=45]="KeyO",Y[Y.KeyP=46]="KeyP",Y[Y.KeyQ=47]="KeyQ",Y[Y.KeyR=48]="KeyR",Y[Y.KeyS=49]="KeyS",Y[Y.KeyT=50]="KeyT",Y[Y.KeyU=51]="KeyU",Y[Y.KeyV=52]="KeyV",Y[Y.KeyW=53]="KeyW",Y[Y.KeyX=54]="KeyX",Y[Y.KeyY=55]="KeyY",Y[Y.KeyZ=56]="KeyZ",Y[Y.Meta=57]="Meta",Y[Y.ContextMenu=58]="ContextMenu",Y[Y.F1=59]="F1",Y[Y.F2=60]="F2",Y[Y.F3=61]="F3",Y[Y.F4=62]="F4",Y[Y.F5=63]="F5",Y[Y.F6=64]="F6",Y[Y.F7=65]="F7",Y[Y.F8=66]="F8",Y[Y.F9=67]="F9",Y[Y.F10=68]="F10",Y[Y.F11=69]="F11",Y[Y.F12=70]="F12",Y[Y.F13=71]="F13",Y[Y.F14=72]="F14",Y[Y.F15=73]="F15",Y[Y.F16=74]="F16",Y[Y.F17=75]="F17",Y[Y.F18=76]="F18",Y[Y.F19=77]="F19",Y[Y.F20=78]="F20",Y[Y.F21=79]="F21",Y[Y.F22=80]="F22",Y[Y.F23=81]="F23",Y[Y.F24=82]="F24",Y[Y.NumLock=83]="NumLock",Y[Y.ScrollLock=84]="ScrollLock",Y[Y.Semicolon=85]="Semicolon",Y[Y.Equal=86]="Equal",Y[Y.Comma=87]="Comma",Y[Y.Minus=88]="Minus",Y[Y.Period=89]="Period",Y[Y.Slash=90]="Slash",Y[Y.Backquote=91]="Backquote",Y[Y.BracketLeft=92]="BracketLeft",Y[Y.Backslash=93]="Backslash",Y[Y.BracketRight=94]="BracketRight",Y[Y.Quote=95]="Quote",Y[Y.OEM_8=96]="OEM_8",Y[Y.IntlBackslash=97]="IntlBackslash",Y[Y.Numpad0=98]="Numpad0",Y[Y.Numpad1=99]="Numpad1",Y[Y.Numpad2=100]="Numpad2",Y[Y.Numpad3=101]="Numpad3",Y[Y.Numpad4=102]="Numpad4",Y[Y.Numpad5=103]="Numpad5",Y[Y.Numpad6=104]="Numpad6",Y[Y.Numpad7=105]="Numpad7",Y[Y.Numpad8=106]="Numpad8",Y[Y.Numpad9=107]="Numpad9",Y[Y.NumpadMultiply=108]="NumpadMultiply",Y[Y.NumpadAdd=109]="NumpadAdd",Y[Y.NUMPAD_SEPARATOR=110]="NUMPAD_SEPARATOR",Y[Y.NumpadSubtract=111]="NumpadSubtract",Y[Y.NumpadDecimal=112]="NumpadDecimal",Y[Y.NumpadDivide=113]="NumpadDivide",Y[Y.KEY_IN_COMPOSITION=114]="KEY_IN_COMPOSITION",Y[Y.ABNT_C1=115]="ABNT_C1",Y[Y.ABNT_C2=116]="ABNT_C2",Y[Y.AudioVolumeMute=117]="AudioVolumeMute",Y[Y.AudioVolumeUp=118]="AudioVolumeUp",Y[Y.AudioVolumeDown=119]="AudioVolumeDown",Y[Y.BrowserSearch=120]="BrowserSearch",Y[Y.BrowserHome=121]="BrowserHome",Y[Y.BrowserBack=122]="BrowserBack",Y[Y.BrowserForward=123]="BrowserForward",Y[Y.MediaTrackNext=124]="MediaTrackNext",Y[Y.MediaTrackPrevious=125]="MediaTrackPrevious",Y[Y.MediaStop=126]="MediaStop",Y[Y.MediaPlayPause=127]="MediaPlayPause",Y[Y.LaunchMediaPlayer=128]="LaunchMediaPlayer",Y[Y.LaunchMail=129]="LaunchMail",Y[Y.LaunchApp2=130]="LaunchApp2",Y[Y.Clear=131]="Clear",Y[Y.MAX_VALUE=132]="MAX_VALUE",($=tO||(tO={}))[$.Hint=1]="Hint",$[$.Info=2]="Info",$[$.Warning=4]="Warning",$[$.Error=8]="Error",(q=tL||(tL={}))[q.Unnecessary=1]="Unnecessary",q[q.Deprecated=2]="Deprecated",(X=tI||(tI={}))[X.Inline=1]="Inline",X[X.Gutter=2]="Gutter",(Z=tw||(tw={}))[Z.UNKNOWN=0]="UNKNOWN",Z[Z.TEXTAREA=1]="TEXTAREA",Z[Z.GUTTER_GLYPH_MARGIN=2]="GUTTER_GLYPH_MARGIN",Z[Z.GUTTER_LINE_NUMBERS=3]="GUTTER_LINE_NUMBERS",Z[Z.GUTTER_LINE_DECORATIONS=4]="GUTTER_LINE_DECORATIONS",Z[Z.GUTTER_VIEW_ZONE=5]="GUTTER_VIEW_ZONE",Z[Z.CONTENT_TEXT=6]="CONTENT_TEXT",Z[Z.CONTENT_EMPTY=7]="CONTENT_EMPTY",Z[Z.CONTENT_VIEW_ZONE=8]="CONTENT_VIEW_ZONE",Z[Z.CONTENT_WIDGET=9]="CONTENT_WIDGET",Z[Z.OVERVIEW_RULER=10]="OVERVIEW_RULER",Z[Z.SCROLLBAR=11]="SCROLLBAR",Z[Z.OVERLAY_WIDGET=12]="OVERLAY_WIDGET",Z[Z.OUTSIDE_EDITOR=13]="OUTSIDE_EDITOR",(Q=tD||(tD={}))[Q.TOP_RIGHT_CORNER=0]="TOP_RIGHT_CORNER",Q[Q.BOTTOM_RIGHT_CORNER=1]="BOTTOM_RIGHT_CORNER",Q[Q.TOP_CENTER=2]="TOP_CENTER",(J=tx||(tx={}))[J.Left=1]="Left",J[J.Center=2]="Center",J[J.Right=4]="Right",J[J.Full=7]="Full",(ee=tM||(tM={}))[ee.Left=0]="Left",ee[ee.Right=1]="Right",ee[ee.None=2]="None",ee[ee.LeftOfInjectedText=3]="LeftOfInjectedText",ee[ee.RightOfInjectedText=4]="RightOfInjectedText",(et=tk||(tk={}))[et.Off=0]="Off",et[et.On=1]="On",et[et.Relative=2]="Relative",et[et.Interval=3]="Interval",et[et.Custom=4]="Custom",(ei=tP||(tP={}))[ei.None=0]="None",ei[ei.Text=1]="Text",ei[ei.Blocks=2]="Blocks",(en=tF||(tF={}))[en.Smooth=0]="Smooth",en[en.Immediate=1]="Immediate",(er=tB||(tB={}))[er.Auto=1]="Auto",er[er.Hidden=2]="Hidden",er[er.Visible=3]="Visible",(eo=tU||(tU={}))[eo.LTR=0]="LTR",eo[eo.RTL=1]="RTL",(es=tH||(tH={}))[es.Invoke=1]="Invoke",es[es.TriggerCharacter=2]="TriggerCharacter",es[es.ContentChange=3]="ContentChange",(ea=tV||(tV={}))[ea.File=0]="File",ea[ea.Module=1]="Module",ea[ea.Namespace=2]="Namespace",ea[ea.Package=3]="Package",ea[ea.Class=4]="Class",ea[ea.Method=5]="Method",ea[ea.Property=6]="Property",ea[ea.Field=7]="Field",ea[ea.Constructor=8]="Constructor",ea[ea.Enum=9]="Enum",ea[ea.Interface=10]="Interface",ea[ea.Function=11]="Function",ea[ea.Variable=12]="Variable",ea[ea.Constant=13]="Constant",ea[ea.String=14]="String",ea[ea.Number=15]="Number",ea[ea.Boolean=16]="Boolean",ea[ea.Array=17]="Array",ea[ea.Object=18]="Object",ea[ea.Key=19]="Key",ea[ea.Null=20]="Null",ea[ea.EnumMember=21]="EnumMember",ea[ea.Struct=22]="Struct",ea[ea.Event=23]="Event",ea[ea.Operator=24]="Operator",ea[ea.TypeParameter=25]="TypeParameter",(el=tW||(tW={}))[el.Deprecated=1]="Deprecated",(eh=tG||(tG={}))[eh.Hidden=0]="Hidden",eh[eh.Blink=1]="Blink",eh[eh.Smooth=2]="Smooth",eh[eh.Phase=3]="Phase",eh[eh.Expand=4]="Expand",eh[eh.Solid=5]="Solid",(eu=tj||(tj={}))[eu.Line=1]="Line",eu[eu.Block=2]="Block",eu[eu.Underline=3]="Underline",eu[eu.LineThin=4]="LineThin",eu[eu.BlockOutline=5]="BlockOutline",eu[eu.UnderlineThin=6]="UnderlineThin",(ed=tz||(tz={}))[ed.AlwaysGrowsWhenTypingAtEdges=0]="AlwaysGrowsWhenTypingAtEdges",ed[ed.NeverGrowsWhenTypingAtEdges=1]="NeverGrowsWhenTypingAtEdges",ed[ed.GrowsOnlyWhenTypingBefore=2]="GrowsOnlyWhenTypingBefore",ed[ed.GrowsOnlyWhenTypingAfter=3]="GrowsOnlyWhenTypingAfter",(ec=tK||(tK={}))[ec.None=0]="None",ec[ec.Same=1]="Same",ec[ec.Indent=2]="Indent",ec[ec.DeepIndent=3]="DeepIndent";class rM{static chord(e,t){return(e|(65535&t)<<16>>>0)>>>0}}function rk(){return{editor:void 0,languages:void 0,CancellationTokenSource:nx,Emitter:ny,KeyCode:tN,KeyMod:rM,Position:rE,Range:rv,Selection:rb,SelectionDirection:tU,MarkerSeverity:tO,MarkerTag:tL,Uri:rl,Token:rO}}rM.CtrlCmd=2048,rM.Shift=1024,rM.Alt=512,rM.WinCtrl=256,i(95656);class rP{get cachedValues(){return this._map}constructor(e){this.fn=e,this._map=new Map}get(e){if(this._map.has(e))return this._map.get(e);let t=this.fn(e);return this._map.set(e,t),t}}class rF{constructor(e){this.executor=e,this._didRun=!1}get value(){if(!this._didRun)try{this._value=this.executor()}catch(e){this._error=e}finally{this._didRun=!0}if(this._error)throw this._error;return this._value}get rawValue(){return this._value}}let rB=/{(\d+)}/g;function rU(e,...t){return 0===t.length?e:e.replace(rB,function(e,i){let n=parseInt(i,10);return isNaN(n)||n<0||n>=t.length?e:t[n]})}function rH(e){return e.replace(/[<>&]/g,function(e){switch(e){case"<":return"<";case">":return">";case"&":return"&";default:return e}})}function rV(e){return e.replace(/[\\\{\}\*\+\?\|\^\$\.\[\]\(\)]/g,"\\$&")}function rW(e,t){if(!e||!t)return e;let i=t.length;if(0===i||0===e.length)return e;let n=0;for(;e.indexOf(t,n)===n;)n+=i;return e.substring(n)}function rG(e,t,i={}){if(!e)throw Error("Cannot create regex from empty string");t||(e=rV(e)),i.wholeWord&&(/\B/.test(e.charAt(0))||(e="\\b"+e),/\B/.test(e.charAt(e.length-1))||(e+="\\b"));let n="";return i.global&&(n+="g"),i.matchCase||(n+="i"),i.multiline&&(n+="m"),i.unicode&&(n+="u"),new RegExp(e,n)}function rj(e){return(e.global?"g":"")+(e.ignoreCase?"i":"")+(e.multiline?"m":"")+(e.unicode?"u":"")}function rz(e){return e.split(/\r\n|\r|\n/)}function rK(e){for(let t=0,i=e.length;t=0;i--){let t=e.charCodeAt(i);if(32!==t&&9!==t)return i}return -1}function rq(e,t){return et?1:0}function rX(e,t,i=0,n=e.length,r=0,o=t.length){for(;io)return 1}let s=n-i,a=o-r;return sa?1:0}function rZ(e,t){return rQ(e,t,0,e.length,0,t.length)}function rQ(e,t,i=0,n=e.length,r=0,o=t.length){for(;i=128||a>=128)return rX(e.toLowerCase(),t.toLowerCase(),i,n,r,o);r0(s)&&(s-=32),r0(a)&&(a-=32);let l=s-a;if(0!==l)return l}let s=n-i,a=o-r;return sa?1:0}function rJ(e){return e>=48&&e<=57}function r0(e){return e>=97&&e<=122}function r1(e){return e>=65&&e<=90}function r2(e,t){return e.length===t.length&&0===rQ(e,t)}function r5(e,t){let i=t.length;return!(t.length>e.length)&&0===rQ(e,t,0,i)}function r4(e,t){let i;let n=Math.min(e.length,t.length);for(i=0;i1){let n=e.charCodeAt(t-2);if(r6(n))return r8(n,i)}return i}(this._str,this._offset);return this._offset-=e>=65536?2:1,e}nextCodePoint(){let e=r7(this._str,this._len,this._offset);return this._offset+=e>=65536?2:1,e}eol(){return this._offset>=this._len}}class ot{get offset(){return this._iterator.offset}constructor(e,t=0){this._iterator=new oe(e,t)}nextGraphemeLength(){let e=og.getInstance(),t=this._iterator,i=t.offset,n=e.getGraphemeBreakType(t.nextCodePoint());for(;!t.eol();){let i=t.offset,r=e.getGraphemeBreakType(t.nextCodePoint());if(of(n,r)){t.setOffset(i);break}n=r}return t.offset-i}prevGraphemeLength(){let e=og.getInstance(),t=this._iterator,i=t.offset,n=e.getGraphemeBreakType(t.prevCodePoint());for(;t.offset>0;){let i=t.offset,r=e.getGraphemeBreakType(t.prevCodePoint());if(of(r,n)){t.setOffset(i);break}n=r}return i-t.offset}eol(){return this._iterator.eol()}}function oi(e,t){let i=new ot(e,t);return i.nextGraphemeLength()}function on(e,t){let i=new ot(e,t);return i.prevGraphemeLength()}function or(e){return E||(E=/(?:[\u05BE\u05C0\u05C3\u05C6\u05D0-\u05F4\u0608\u060B\u060D\u061B-\u064A\u066D-\u066F\u0671-\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u0710\u0712-\u072F\u074D-\u07A5\u07B1-\u07EA\u07F4\u07F5\u07FA\u07FE-\u0815\u081A\u0824\u0828\u0830-\u0858\u085E-\u088E\u08A0-\u08C9\u200F\uFB1D\uFB1F-\uFB28\uFB2A-\uFD3D\uFD50-\uFDC7\uFDF0-\uFDFC\uFE70-\uFEFC]|\uD802[\uDC00-\uDD1B\uDD20-\uDE00\uDE10-\uDE35\uDE40-\uDEE4\uDEEB-\uDF35\uDF40-\uDFFF]|\uD803[\uDC00-\uDD23\uDE80-\uDEA9\uDEAD-\uDF45\uDF51-\uDF81\uDF86-\uDFF6]|\uD83A[\uDC00-\uDCCF\uDD00-\uDD43\uDD4B-\uDFFF]|\uD83B[\uDC00-\uDEBB])/),E.test(e)}let oo=/^[\t\n\r\x20-\x7E]*$/;function os(e){return oo.test(e)}let oa=/[\u2028\u2029]/;function ol(e){return e>=11904&&e<=55215||e>=63744&&e<=64255||e>=65281&&e<=65374}function oh(e){return e>=127462&&e<=127487||8986===e||8987===e||9200===e||9203===e||e>=9728&&e<=10175||11088===e||11093===e||e>=127744&&e<=128591||e>=128640&&e<=128764||e>=128992&&e<=129008||e>=129280&&e<=129535||e>=129648&&e<=129782}let ou=String.fromCharCode(65279);function od(e){return!!(e&&e.length>0&&65279===e.charCodeAt(0))}function oc(e){return(e%=52)<26?String.fromCharCode(97+e):String.fromCharCode(65+e-26)}function of(e,t){return 0===e?5!==t&&7!==t:(2!==e||3!==t)&&(4===e||2===e||3===e||4===t||2===t||3===t||(8!==e||8!==t&&9!==t&&11!==t&&12!==t)&&(11!==e&&9!==e||9!==t&&10!==t)&&(12!==e&&10!==e||10!==t)&&5!==t&&13!==t&&7!==t&&1!==e&&(13!==e||14!==t)&&(6!==e||6!==t))}class og{static getInstance(){return og._INSTANCE||(og._INSTANCE=new og),og._INSTANCE}constructor(){this._data=JSON.parse("[0,0,0,51229,51255,12,44061,44087,12,127462,127487,6,7083,7085,5,47645,47671,12,54813,54839,12,128678,128678,14,3270,3270,5,9919,9923,14,45853,45879,12,49437,49463,12,53021,53047,12,71216,71218,7,128398,128399,14,129360,129374,14,2519,2519,5,4448,4519,9,9742,9742,14,12336,12336,14,44957,44983,12,46749,46775,12,48541,48567,12,50333,50359,12,52125,52151,12,53917,53943,12,69888,69890,5,73018,73018,5,127990,127990,14,128558,128559,14,128759,128760,14,129653,129655,14,2027,2035,5,2891,2892,7,3761,3761,5,6683,6683,5,8293,8293,4,9825,9826,14,9999,9999,14,43452,43453,5,44509,44535,12,45405,45431,12,46301,46327,12,47197,47223,12,48093,48119,12,48989,49015,12,49885,49911,12,50781,50807,12,51677,51703,12,52573,52599,12,53469,53495,12,54365,54391,12,65279,65279,4,70471,70472,7,72145,72147,7,119173,119179,5,127799,127818,14,128240,128244,14,128512,128512,14,128652,128652,14,128721,128722,14,129292,129292,14,129445,129450,14,129734,129743,14,1476,1477,5,2366,2368,7,2750,2752,7,3076,3076,5,3415,3415,5,4141,4144,5,6109,6109,5,6964,6964,5,7394,7400,5,9197,9198,14,9770,9770,14,9877,9877,14,9968,9969,14,10084,10084,14,43052,43052,5,43713,43713,5,44285,44311,12,44733,44759,12,45181,45207,12,45629,45655,12,46077,46103,12,46525,46551,12,46973,46999,12,47421,47447,12,47869,47895,12,48317,48343,12,48765,48791,12,49213,49239,12,49661,49687,12,50109,50135,12,50557,50583,12,51005,51031,12,51453,51479,12,51901,51927,12,52349,52375,12,52797,52823,12,53245,53271,12,53693,53719,12,54141,54167,12,54589,54615,12,55037,55063,12,69506,69509,5,70191,70193,5,70841,70841,7,71463,71467,5,72330,72342,5,94031,94031,5,123628,123631,5,127763,127765,14,127941,127941,14,128043,128062,14,128302,128317,14,128465,128467,14,128539,128539,14,128640,128640,14,128662,128662,14,128703,128703,14,128745,128745,14,129004,129007,14,129329,129330,14,129402,129402,14,129483,129483,14,129686,129704,14,130048,131069,14,173,173,4,1757,1757,1,2200,2207,5,2434,2435,7,2631,2632,5,2817,2817,5,3008,3008,5,3201,3201,5,3387,3388,5,3542,3542,5,3902,3903,7,4190,4192,5,6002,6003,5,6439,6440,5,6765,6770,7,7019,7027,5,7154,7155,7,8205,8205,13,8505,8505,14,9654,9654,14,9757,9757,14,9792,9792,14,9852,9853,14,9890,9894,14,9937,9937,14,9981,9981,14,10035,10036,14,11035,11036,14,42654,42655,5,43346,43347,7,43587,43587,5,44006,44007,7,44173,44199,12,44397,44423,12,44621,44647,12,44845,44871,12,45069,45095,12,45293,45319,12,45517,45543,12,45741,45767,12,45965,45991,12,46189,46215,12,46413,46439,12,46637,46663,12,46861,46887,12,47085,47111,12,47309,47335,12,47533,47559,12,47757,47783,12,47981,48007,12,48205,48231,12,48429,48455,12,48653,48679,12,48877,48903,12,49101,49127,12,49325,49351,12,49549,49575,12,49773,49799,12,49997,50023,12,50221,50247,12,50445,50471,12,50669,50695,12,50893,50919,12,51117,51143,12,51341,51367,12,51565,51591,12,51789,51815,12,52013,52039,12,52237,52263,12,52461,52487,12,52685,52711,12,52909,52935,12,53133,53159,12,53357,53383,12,53581,53607,12,53805,53831,12,54029,54055,12,54253,54279,12,54477,54503,12,54701,54727,12,54925,54951,12,55149,55175,12,68101,68102,5,69762,69762,7,70067,70069,7,70371,70378,5,70720,70721,7,71087,71087,5,71341,71341,5,71995,71996,5,72249,72249,7,72850,72871,5,73109,73109,5,118576,118598,5,121505,121519,5,127245,127247,14,127568,127569,14,127777,127777,14,127872,127891,14,127956,127967,14,128015,128016,14,128110,128172,14,128259,128259,14,128367,128368,14,128424,128424,14,128488,128488,14,128530,128532,14,128550,128551,14,128566,128566,14,128647,128647,14,128656,128656,14,128667,128673,14,128691,128693,14,128715,128715,14,128728,128732,14,128752,128752,14,128765,128767,14,129096,129103,14,129311,129311,14,129344,129349,14,129394,129394,14,129413,129425,14,129466,129471,14,129511,129535,14,129664,129666,14,129719,129722,14,129760,129767,14,917536,917631,5,13,13,2,1160,1161,5,1564,1564,4,1807,1807,1,2085,2087,5,2307,2307,7,2382,2383,7,2497,2500,5,2563,2563,7,2677,2677,5,2763,2764,7,2879,2879,5,2914,2915,5,3021,3021,5,3142,3144,5,3263,3263,5,3285,3286,5,3398,3400,7,3530,3530,5,3633,3633,5,3864,3865,5,3974,3975,5,4155,4156,7,4229,4230,5,5909,5909,7,6078,6085,7,6277,6278,5,6451,6456,7,6744,6750,5,6846,6846,5,6972,6972,5,7074,7077,5,7146,7148,7,7222,7223,5,7416,7417,5,8234,8238,4,8417,8417,5,9000,9000,14,9203,9203,14,9730,9731,14,9748,9749,14,9762,9763,14,9776,9783,14,9800,9811,14,9831,9831,14,9872,9873,14,9882,9882,14,9900,9903,14,9929,9933,14,9941,9960,14,9974,9974,14,9989,9989,14,10006,10006,14,10062,10062,14,10160,10160,14,11647,11647,5,12953,12953,14,43019,43019,5,43232,43249,5,43443,43443,5,43567,43568,7,43696,43696,5,43765,43765,7,44013,44013,5,44117,44143,12,44229,44255,12,44341,44367,12,44453,44479,12,44565,44591,12,44677,44703,12,44789,44815,12,44901,44927,12,45013,45039,12,45125,45151,12,45237,45263,12,45349,45375,12,45461,45487,12,45573,45599,12,45685,45711,12,45797,45823,12,45909,45935,12,46021,46047,12,46133,46159,12,46245,46271,12,46357,46383,12,46469,46495,12,46581,46607,12,46693,46719,12,46805,46831,12,46917,46943,12,47029,47055,12,47141,47167,12,47253,47279,12,47365,47391,12,47477,47503,12,47589,47615,12,47701,47727,12,47813,47839,12,47925,47951,12,48037,48063,12,48149,48175,12,48261,48287,12,48373,48399,12,48485,48511,12,48597,48623,12,48709,48735,12,48821,48847,12,48933,48959,12,49045,49071,12,49157,49183,12,49269,49295,12,49381,49407,12,49493,49519,12,49605,49631,12,49717,49743,12,49829,49855,12,49941,49967,12,50053,50079,12,50165,50191,12,50277,50303,12,50389,50415,12,50501,50527,12,50613,50639,12,50725,50751,12,50837,50863,12,50949,50975,12,51061,51087,12,51173,51199,12,51285,51311,12,51397,51423,12,51509,51535,12,51621,51647,12,51733,51759,12,51845,51871,12,51957,51983,12,52069,52095,12,52181,52207,12,52293,52319,12,52405,52431,12,52517,52543,12,52629,52655,12,52741,52767,12,52853,52879,12,52965,52991,12,53077,53103,12,53189,53215,12,53301,53327,12,53413,53439,12,53525,53551,12,53637,53663,12,53749,53775,12,53861,53887,12,53973,53999,12,54085,54111,12,54197,54223,12,54309,54335,12,54421,54447,12,54533,54559,12,54645,54671,12,54757,54783,12,54869,54895,12,54981,55007,12,55093,55119,12,55243,55291,10,66045,66045,5,68325,68326,5,69688,69702,5,69817,69818,5,69957,69958,7,70089,70092,5,70198,70199,5,70462,70462,5,70502,70508,5,70750,70750,5,70846,70846,7,71100,71101,5,71230,71230,7,71351,71351,5,71737,71738,5,72000,72000,7,72160,72160,5,72273,72278,5,72752,72758,5,72882,72883,5,73031,73031,5,73461,73462,7,94192,94193,7,119149,119149,7,121403,121452,5,122915,122916,5,126980,126980,14,127358,127359,14,127535,127535,14,127759,127759,14,127771,127771,14,127792,127793,14,127825,127867,14,127897,127899,14,127945,127945,14,127985,127986,14,128000,128007,14,128021,128021,14,128066,128100,14,128184,128235,14,128249,128252,14,128266,128276,14,128335,128335,14,128379,128390,14,128407,128419,14,128444,128444,14,128481,128481,14,128499,128499,14,128526,128526,14,128536,128536,14,128543,128543,14,128556,128556,14,128564,128564,14,128577,128580,14,128643,128645,14,128649,128649,14,128654,128654,14,128660,128660,14,128664,128664,14,128675,128675,14,128686,128689,14,128695,128696,14,128705,128709,14,128717,128719,14,128725,128725,14,128736,128741,14,128747,128748,14,128755,128755,14,128762,128762,14,128981,128991,14,129009,129023,14,129160,129167,14,129296,129304,14,129320,129327,14,129340,129342,14,129356,129356,14,129388,129392,14,129399,129400,14,129404,129407,14,129432,129442,14,129454,129455,14,129473,129474,14,129485,129487,14,129648,129651,14,129659,129660,14,129671,129679,14,129709,129711,14,129728,129730,14,129751,129753,14,129776,129782,14,917505,917505,4,917760,917999,5,10,10,3,127,159,4,768,879,5,1471,1471,5,1536,1541,1,1648,1648,5,1767,1768,5,1840,1866,5,2070,2073,5,2137,2139,5,2274,2274,1,2363,2363,7,2377,2380,7,2402,2403,5,2494,2494,5,2507,2508,7,2558,2558,5,2622,2624,7,2641,2641,5,2691,2691,7,2759,2760,5,2786,2787,5,2876,2876,5,2881,2884,5,2901,2902,5,3006,3006,5,3014,3016,7,3072,3072,5,3134,3136,5,3157,3158,5,3260,3260,5,3266,3266,5,3274,3275,7,3328,3329,5,3391,3392,7,3405,3405,5,3457,3457,5,3536,3537,7,3551,3551,5,3636,3642,5,3764,3772,5,3895,3895,5,3967,3967,7,3993,4028,5,4146,4151,5,4182,4183,7,4226,4226,5,4253,4253,5,4957,4959,5,5940,5940,7,6070,6070,7,6087,6088,7,6158,6158,4,6432,6434,5,6448,6449,7,6679,6680,5,6742,6742,5,6754,6754,5,6783,6783,5,6912,6915,5,6966,6970,5,6978,6978,5,7042,7042,7,7080,7081,5,7143,7143,7,7150,7150,7,7212,7219,5,7380,7392,5,7412,7412,5,8203,8203,4,8232,8232,4,8265,8265,14,8400,8412,5,8421,8432,5,8617,8618,14,9167,9167,14,9200,9200,14,9410,9410,14,9723,9726,14,9733,9733,14,9745,9745,14,9752,9752,14,9760,9760,14,9766,9766,14,9774,9774,14,9786,9786,14,9794,9794,14,9823,9823,14,9828,9828,14,9833,9850,14,9855,9855,14,9875,9875,14,9880,9880,14,9885,9887,14,9896,9897,14,9906,9916,14,9926,9927,14,9935,9935,14,9939,9939,14,9962,9962,14,9972,9972,14,9978,9978,14,9986,9986,14,9997,9997,14,10002,10002,14,10017,10017,14,10055,10055,14,10071,10071,14,10133,10135,14,10548,10549,14,11093,11093,14,12330,12333,5,12441,12442,5,42608,42610,5,43010,43010,5,43045,43046,5,43188,43203,7,43302,43309,5,43392,43394,5,43446,43449,5,43493,43493,5,43571,43572,7,43597,43597,7,43703,43704,5,43756,43757,5,44003,44004,7,44009,44010,7,44033,44059,12,44089,44115,12,44145,44171,12,44201,44227,12,44257,44283,12,44313,44339,12,44369,44395,12,44425,44451,12,44481,44507,12,44537,44563,12,44593,44619,12,44649,44675,12,44705,44731,12,44761,44787,12,44817,44843,12,44873,44899,12,44929,44955,12,44985,45011,12,45041,45067,12,45097,45123,12,45153,45179,12,45209,45235,12,45265,45291,12,45321,45347,12,45377,45403,12,45433,45459,12,45489,45515,12,45545,45571,12,45601,45627,12,45657,45683,12,45713,45739,12,45769,45795,12,45825,45851,12,45881,45907,12,45937,45963,12,45993,46019,12,46049,46075,12,46105,46131,12,46161,46187,12,46217,46243,12,46273,46299,12,46329,46355,12,46385,46411,12,46441,46467,12,46497,46523,12,46553,46579,12,46609,46635,12,46665,46691,12,46721,46747,12,46777,46803,12,46833,46859,12,46889,46915,12,46945,46971,12,47001,47027,12,47057,47083,12,47113,47139,12,47169,47195,12,47225,47251,12,47281,47307,12,47337,47363,12,47393,47419,12,47449,47475,12,47505,47531,12,47561,47587,12,47617,47643,12,47673,47699,12,47729,47755,12,47785,47811,12,47841,47867,12,47897,47923,12,47953,47979,12,48009,48035,12,48065,48091,12,48121,48147,12,48177,48203,12,48233,48259,12,48289,48315,12,48345,48371,12,48401,48427,12,48457,48483,12,48513,48539,12,48569,48595,12,48625,48651,12,48681,48707,12,48737,48763,12,48793,48819,12,48849,48875,12,48905,48931,12,48961,48987,12,49017,49043,12,49073,49099,12,49129,49155,12,49185,49211,12,49241,49267,12,49297,49323,12,49353,49379,12,49409,49435,12,49465,49491,12,49521,49547,12,49577,49603,12,49633,49659,12,49689,49715,12,49745,49771,12,49801,49827,12,49857,49883,12,49913,49939,12,49969,49995,12,50025,50051,12,50081,50107,12,50137,50163,12,50193,50219,12,50249,50275,12,50305,50331,12,50361,50387,12,50417,50443,12,50473,50499,12,50529,50555,12,50585,50611,12,50641,50667,12,50697,50723,12,50753,50779,12,50809,50835,12,50865,50891,12,50921,50947,12,50977,51003,12,51033,51059,12,51089,51115,12,51145,51171,12,51201,51227,12,51257,51283,12,51313,51339,12,51369,51395,12,51425,51451,12,51481,51507,12,51537,51563,12,51593,51619,12,51649,51675,12,51705,51731,12,51761,51787,12,51817,51843,12,51873,51899,12,51929,51955,12,51985,52011,12,52041,52067,12,52097,52123,12,52153,52179,12,52209,52235,12,52265,52291,12,52321,52347,12,52377,52403,12,52433,52459,12,52489,52515,12,52545,52571,12,52601,52627,12,52657,52683,12,52713,52739,12,52769,52795,12,52825,52851,12,52881,52907,12,52937,52963,12,52993,53019,12,53049,53075,12,53105,53131,12,53161,53187,12,53217,53243,12,53273,53299,12,53329,53355,12,53385,53411,12,53441,53467,12,53497,53523,12,53553,53579,12,53609,53635,12,53665,53691,12,53721,53747,12,53777,53803,12,53833,53859,12,53889,53915,12,53945,53971,12,54001,54027,12,54057,54083,12,54113,54139,12,54169,54195,12,54225,54251,12,54281,54307,12,54337,54363,12,54393,54419,12,54449,54475,12,54505,54531,12,54561,54587,12,54617,54643,12,54673,54699,12,54729,54755,12,54785,54811,12,54841,54867,12,54897,54923,12,54953,54979,12,55009,55035,12,55065,55091,12,55121,55147,12,55177,55203,12,65024,65039,5,65520,65528,4,66422,66426,5,68152,68154,5,69291,69292,5,69633,69633,5,69747,69748,5,69811,69814,5,69826,69826,5,69932,69932,7,70016,70017,5,70079,70080,7,70095,70095,5,70196,70196,5,70367,70367,5,70402,70403,7,70464,70464,5,70487,70487,5,70709,70711,7,70725,70725,7,70833,70834,7,70843,70844,7,70849,70849,7,71090,71093,5,71103,71104,5,71227,71228,7,71339,71339,5,71344,71349,5,71458,71461,5,71727,71735,5,71985,71989,7,71998,71998,5,72002,72002,7,72154,72155,5,72193,72202,5,72251,72254,5,72281,72283,5,72344,72345,5,72766,72766,7,72874,72880,5,72885,72886,5,73023,73029,5,73104,73105,5,73111,73111,5,92912,92916,5,94095,94098,5,113824,113827,4,119142,119142,7,119155,119162,4,119362,119364,5,121476,121476,5,122888,122904,5,123184,123190,5,125252,125258,5,127183,127183,14,127340,127343,14,127377,127386,14,127491,127503,14,127548,127551,14,127744,127756,14,127761,127761,14,127769,127769,14,127773,127774,14,127780,127788,14,127796,127797,14,127820,127823,14,127869,127869,14,127894,127895,14,127902,127903,14,127943,127943,14,127947,127950,14,127972,127972,14,127988,127988,14,127992,127994,14,128009,128011,14,128019,128019,14,128023,128041,14,128064,128064,14,128102,128107,14,128174,128181,14,128238,128238,14,128246,128247,14,128254,128254,14,128264,128264,14,128278,128299,14,128329,128330,14,128348,128359,14,128371,128377,14,128392,128393,14,128401,128404,14,128421,128421,14,128433,128434,14,128450,128452,14,128476,128478,14,128483,128483,14,128495,128495,14,128506,128506,14,128519,128520,14,128528,128528,14,128534,128534,14,128538,128538,14,128540,128542,14,128544,128549,14,128552,128555,14,128557,128557,14,128560,128563,14,128565,128565,14,128567,128576,14,128581,128591,14,128641,128642,14,128646,128646,14,128648,128648,14,128650,128651,14,128653,128653,14,128655,128655,14,128657,128659,14,128661,128661,14,128663,128663,14,128665,128666,14,128674,128674,14,128676,128677,14,128679,128685,14,128690,128690,14,128694,128694,14,128697,128702,14,128704,128704,14,128710,128714,14,128716,128716,14,128720,128720,14,128723,128724,14,128726,128727,14,128733,128735,14,128742,128744,14,128746,128746,14,128749,128751,14,128753,128754,14,128756,128758,14,128761,128761,14,128763,128764,14,128884,128895,14,128992,129003,14,129008,129008,14,129036,129039,14,129114,129119,14,129198,129279,14,129293,129295,14,129305,129310,14,129312,129319,14,129328,129328,14,129331,129338,14,129343,129343,14,129351,129355,14,129357,129359,14,129375,129387,14,129393,129393,14,129395,129398,14,129401,129401,14,129403,129403,14,129408,129412,14,129426,129431,14,129443,129444,14,129451,129453,14,129456,129465,14,129472,129472,14,129475,129482,14,129484,129484,14,129488,129510,14,129536,129647,14,129652,129652,14,129656,129658,14,129661,129663,14,129667,129670,14,129680,129685,14,129705,129708,14,129712,129718,14,129723,129727,14,129731,129733,14,129744,129750,14,129754,129759,14,129768,129775,14,129783,129791,14,917504,917504,4,917506,917535,4,917632,917759,4,918000,921599,4,0,9,4,11,12,4,14,31,4,169,169,14,174,174,14,1155,1159,5,1425,1469,5,1473,1474,5,1479,1479,5,1552,1562,5,1611,1631,5,1750,1756,5,1759,1764,5,1770,1773,5,1809,1809,5,1958,1968,5,2045,2045,5,2075,2083,5,2089,2093,5,2192,2193,1,2250,2273,5,2275,2306,5,2362,2362,5,2364,2364,5,2369,2376,5,2381,2381,5,2385,2391,5,2433,2433,5,2492,2492,5,2495,2496,7,2503,2504,7,2509,2509,5,2530,2531,5,2561,2562,5,2620,2620,5,2625,2626,5,2635,2637,5,2672,2673,5,2689,2690,5,2748,2748,5,2753,2757,5,2761,2761,7,2765,2765,5,2810,2815,5,2818,2819,7,2878,2878,5,2880,2880,7,2887,2888,7,2893,2893,5,2903,2903,5,2946,2946,5,3007,3007,7,3009,3010,7,3018,3020,7,3031,3031,5,3073,3075,7,3132,3132,5,3137,3140,7,3146,3149,5,3170,3171,5,3202,3203,7,3262,3262,7,3264,3265,7,3267,3268,7,3271,3272,7,3276,3277,5,3298,3299,5,3330,3331,7,3390,3390,5,3393,3396,5,3402,3404,7,3406,3406,1,3426,3427,5,3458,3459,7,3535,3535,5,3538,3540,5,3544,3550,7,3570,3571,7,3635,3635,7,3655,3662,5,3763,3763,7,3784,3789,5,3893,3893,5,3897,3897,5,3953,3966,5,3968,3972,5,3981,3991,5,4038,4038,5,4145,4145,7,4153,4154,5,4157,4158,5,4184,4185,5,4209,4212,5,4228,4228,7,4237,4237,5,4352,4447,8,4520,4607,10,5906,5908,5,5938,5939,5,5970,5971,5,6068,6069,5,6071,6077,5,6086,6086,5,6089,6099,5,6155,6157,5,6159,6159,5,6313,6313,5,6435,6438,7,6441,6443,7,6450,6450,5,6457,6459,5,6681,6682,7,6741,6741,7,6743,6743,7,6752,6752,5,6757,6764,5,6771,6780,5,6832,6845,5,6847,6862,5,6916,6916,7,6965,6965,5,6971,6971,7,6973,6977,7,6979,6980,7,7040,7041,5,7073,7073,7,7078,7079,7,7082,7082,7,7142,7142,5,7144,7145,5,7149,7149,5,7151,7153,5,7204,7211,7,7220,7221,7,7376,7378,5,7393,7393,7,7405,7405,5,7415,7415,7,7616,7679,5,8204,8204,5,8206,8207,4,8233,8233,4,8252,8252,14,8288,8292,4,8294,8303,4,8413,8416,5,8418,8420,5,8482,8482,14,8596,8601,14,8986,8987,14,9096,9096,14,9193,9196,14,9199,9199,14,9201,9202,14,9208,9210,14,9642,9643,14,9664,9664,14,9728,9729,14,9732,9732,14,9735,9741,14,9743,9744,14,9746,9746,14,9750,9751,14,9753,9756,14,9758,9759,14,9761,9761,14,9764,9765,14,9767,9769,14,9771,9773,14,9775,9775,14,9784,9785,14,9787,9791,14,9793,9793,14,9795,9799,14,9812,9822,14,9824,9824,14,9827,9827,14,9829,9830,14,9832,9832,14,9851,9851,14,9854,9854,14,9856,9861,14,9874,9874,14,9876,9876,14,9878,9879,14,9881,9881,14,9883,9884,14,9888,9889,14,9895,9895,14,9898,9899,14,9904,9905,14,9917,9918,14,9924,9925,14,9928,9928,14,9934,9934,14,9936,9936,14,9938,9938,14,9940,9940,14,9961,9961,14,9963,9967,14,9970,9971,14,9973,9973,14,9975,9977,14,9979,9980,14,9982,9985,14,9987,9988,14,9992,9996,14,9998,9998,14,10000,10001,14,10004,10004,14,10013,10013,14,10024,10024,14,10052,10052,14,10060,10060,14,10067,10069,14,10083,10083,14,10085,10087,14,10145,10145,14,10175,10175,14,11013,11015,14,11088,11088,14,11503,11505,5,11744,11775,5,12334,12335,5,12349,12349,14,12951,12951,14,42607,42607,5,42612,42621,5,42736,42737,5,43014,43014,5,43043,43044,7,43047,43047,7,43136,43137,7,43204,43205,5,43263,43263,5,43335,43345,5,43360,43388,8,43395,43395,7,43444,43445,7,43450,43451,7,43454,43456,7,43561,43566,5,43569,43570,5,43573,43574,5,43596,43596,5,43644,43644,5,43698,43700,5,43710,43711,5,43755,43755,7,43758,43759,7,43766,43766,5,44005,44005,5,44008,44008,5,44012,44012,7,44032,44032,11,44060,44060,11,44088,44088,11,44116,44116,11,44144,44144,11,44172,44172,11,44200,44200,11,44228,44228,11,44256,44256,11,44284,44284,11,44312,44312,11,44340,44340,11,44368,44368,11,44396,44396,11,44424,44424,11,44452,44452,11,44480,44480,11,44508,44508,11,44536,44536,11,44564,44564,11,44592,44592,11,44620,44620,11,44648,44648,11,44676,44676,11,44704,44704,11,44732,44732,11,44760,44760,11,44788,44788,11,44816,44816,11,44844,44844,11,44872,44872,11,44900,44900,11,44928,44928,11,44956,44956,11,44984,44984,11,45012,45012,11,45040,45040,11,45068,45068,11,45096,45096,11,45124,45124,11,45152,45152,11,45180,45180,11,45208,45208,11,45236,45236,11,45264,45264,11,45292,45292,11,45320,45320,11,45348,45348,11,45376,45376,11,45404,45404,11,45432,45432,11,45460,45460,11,45488,45488,11,45516,45516,11,45544,45544,11,45572,45572,11,45600,45600,11,45628,45628,11,45656,45656,11,45684,45684,11,45712,45712,11,45740,45740,11,45768,45768,11,45796,45796,11,45824,45824,11,45852,45852,11,45880,45880,11,45908,45908,11,45936,45936,11,45964,45964,11,45992,45992,11,46020,46020,11,46048,46048,11,46076,46076,11,46104,46104,11,46132,46132,11,46160,46160,11,46188,46188,11,46216,46216,11,46244,46244,11,46272,46272,11,46300,46300,11,46328,46328,11,46356,46356,11,46384,46384,11,46412,46412,11,46440,46440,11,46468,46468,11,46496,46496,11,46524,46524,11,46552,46552,11,46580,46580,11,46608,46608,11,46636,46636,11,46664,46664,11,46692,46692,11,46720,46720,11,46748,46748,11,46776,46776,11,46804,46804,11,46832,46832,11,46860,46860,11,46888,46888,11,46916,46916,11,46944,46944,11,46972,46972,11,47000,47000,11,47028,47028,11,47056,47056,11,47084,47084,11,47112,47112,11,47140,47140,11,47168,47168,11,47196,47196,11,47224,47224,11,47252,47252,11,47280,47280,11,47308,47308,11,47336,47336,11,47364,47364,11,47392,47392,11,47420,47420,11,47448,47448,11,47476,47476,11,47504,47504,11,47532,47532,11,47560,47560,11,47588,47588,11,47616,47616,11,47644,47644,11,47672,47672,11,47700,47700,11,47728,47728,11,47756,47756,11,47784,47784,11,47812,47812,11,47840,47840,11,47868,47868,11,47896,47896,11,47924,47924,11,47952,47952,11,47980,47980,11,48008,48008,11,48036,48036,11,48064,48064,11,48092,48092,11,48120,48120,11,48148,48148,11,48176,48176,11,48204,48204,11,48232,48232,11,48260,48260,11,48288,48288,11,48316,48316,11,48344,48344,11,48372,48372,11,48400,48400,11,48428,48428,11,48456,48456,11,48484,48484,11,48512,48512,11,48540,48540,11,48568,48568,11,48596,48596,11,48624,48624,11,48652,48652,11,48680,48680,11,48708,48708,11,48736,48736,11,48764,48764,11,48792,48792,11,48820,48820,11,48848,48848,11,48876,48876,11,48904,48904,11,48932,48932,11,48960,48960,11,48988,48988,11,49016,49016,11,49044,49044,11,49072,49072,11,49100,49100,11,49128,49128,11,49156,49156,11,49184,49184,11,49212,49212,11,49240,49240,11,49268,49268,11,49296,49296,11,49324,49324,11,49352,49352,11,49380,49380,11,49408,49408,11,49436,49436,11,49464,49464,11,49492,49492,11,49520,49520,11,49548,49548,11,49576,49576,11,49604,49604,11,49632,49632,11,49660,49660,11,49688,49688,11,49716,49716,11,49744,49744,11,49772,49772,11,49800,49800,11,49828,49828,11,49856,49856,11,49884,49884,11,49912,49912,11,49940,49940,11,49968,49968,11,49996,49996,11,50024,50024,11,50052,50052,11,50080,50080,11,50108,50108,11,50136,50136,11,50164,50164,11,50192,50192,11,50220,50220,11,50248,50248,11,50276,50276,11,50304,50304,11,50332,50332,11,50360,50360,11,50388,50388,11,50416,50416,11,50444,50444,11,50472,50472,11,50500,50500,11,50528,50528,11,50556,50556,11,50584,50584,11,50612,50612,11,50640,50640,11,50668,50668,11,50696,50696,11,50724,50724,11,50752,50752,11,50780,50780,11,50808,50808,11,50836,50836,11,50864,50864,11,50892,50892,11,50920,50920,11,50948,50948,11,50976,50976,11,51004,51004,11,51032,51032,11,51060,51060,11,51088,51088,11,51116,51116,11,51144,51144,11,51172,51172,11,51200,51200,11,51228,51228,11,51256,51256,11,51284,51284,11,51312,51312,11,51340,51340,11,51368,51368,11,51396,51396,11,51424,51424,11,51452,51452,11,51480,51480,11,51508,51508,11,51536,51536,11,51564,51564,11,51592,51592,11,51620,51620,11,51648,51648,11,51676,51676,11,51704,51704,11,51732,51732,11,51760,51760,11,51788,51788,11,51816,51816,11,51844,51844,11,51872,51872,11,51900,51900,11,51928,51928,11,51956,51956,11,51984,51984,11,52012,52012,11,52040,52040,11,52068,52068,11,52096,52096,11,52124,52124,11,52152,52152,11,52180,52180,11,52208,52208,11,52236,52236,11,52264,52264,11,52292,52292,11,52320,52320,11,52348,52348,11,52376,52376,11,52404,52404,11,52432,52432,11,52460,52460,11,52488,52488,11,52516,52516,11,52544,52544,11,52572,52572,11,52600,52600,11,52628,52628,11,52656,52656,11,52684,52684,11,52712,52712,11,52740,52740,11,52768,52768,11,52796,52796,11,52824,52824,11,52852,52852,11,52880,52880,11,52908,52908,11,52936,52936,11,52964,52964,11,52992,52992,11,53020,53020,11,53048,53048,11,53076,53076,11,53104,53104,11,53132,53132,11,53160,53160,11,53188,53188,11,53216,53216,11,53244,53244,11,53272,53272,11,53300,53300,11,53328,53328,11,53356,53356,11,53384,53384,11,53412,53412,11,53440,53440,11,53468,53468,11,53496,53496,11,53524,53524,11,53552,53552,11,53580,53580,11,53608,53608,11,53636,53636,11,53664,53664,11,53692,53692,11,53720,53720,11,53748,53748,11,53776,53776,11,53804,53804,11,53832,53832,11,53860,53860,11,53888,53888,11,53916,53916,11,53944,53944,11,53972,53972,11,54000,54000,11,54028,54028,11,54056,54056,11,54084,54084,11,54112,54112,11,54140,54140,11,54168,54168,11,54196,54196,11,54224,54224,11,54252,54252,11,54280,54280,11,54308,54308,11,54336,54336,11,54364,54364,11,54392,54392,11,54420,54420,11,54448,54448,11,54476,54476,11,54504,54504,11,54532,54532,11,54560,54560,11,54588,54588,11,54616,54616,11,54644,54644,11,54672,54672,11,54700,54700,11,54728,54728,11,54756,54756,11,54784,54784,11,54812,54812,11,54840,54840,11,54868,54868,11,54896,54896,11,54924,54924,11,54952,54952,11,54980,54980,11,55008,55008,11,55036,55036,11,55064,55064,11,55092,55092,11,55120,55120,11,55148,55148,11,55176,55176,11,55216,55238,9,64286,64286,5,65056,65071,5,65438,65439,5,65529,65531,4,66272,66272,5,68097,68099,5,68108,68111,5,68159,68159,5,68900,68903,5,69446,69456,5,69632,69632,7,69634,69634,7,69744,69744,5,69759,69761,5,69808,69810,7,69815,69816,7,69821,69821,1,69837,69837,1,69927,69931,5,69933,69940,5,70003,70003,5,70018,70018,7,70070,70078,5,70082,70083,1,70094,70094,7,70188,70190,7,70194,70195,7,70197,70197,7,70206,70206,5,70368,70370,7,70400,70401,5,70459,70460,5,70463,70463,7,70465,70468,7,70475,70477,7,70498,70499,7,70512,70516,5,70712,70719,5,70722,70724,5,70726,70726,5,70832,70832,5,70835,70840,5,70842,70842,5,70845,70845,5,70847,70848,5,70850,70851,5,71088,71089,7,71096,71099,7,71102,71102,7,71132,71133,5,71219,71226,5,71229,71229,5,71231,71232,5,71340,71340,7,71342,71343,7,71350,71350,7,71453,71455,5,71462,71462,7,71724,71726,7,71736,71736,7,71984,71984,5,71991,71992,7,71997,71997,7,71999,71999,1,72001,72001,1,72003,72003,5,72148,72151,5,72156,72159,7,72164,72164,7,72243,72248,5,72250,72250,1,72263,72263,5,72279,72280,7,72324,72329,1,72343,72343,7,72751,72751,7,72760,72765,5,72767,72767,5,72873,72873,7,72881,72881,7,72884,72884,7,73009,73014,5,73020,73021,5,73030,73030,1,73098,73102,7,73107,73108,7,73110,73110,7,73459,73460,5,78896,78904,4,92976,92982,5,94033,94087,7,94180,94180,5,113821,113822,5,118528,118573,5,119141,119141,5,119143,119145,5,119150,119154,5,119163,119170,5,119210,119213,5,121344,121398,5,121461,121461,5,121499,121503,5,122880,122886,5,122907,122913,5,122918,122922,5,123566,123566,5,125136,125142,5,126976,126979,14,126981,127182,14,127184,127231,14,127279,127279,14,127344,127345,14,127374,127374,14,127405,127461,14,127489,127490,14,127514,127514,14,127538,127546,14,127561,127567,14,127570,127743,14,127757,127758,14,127760,127760,14,127762,127762,14,127766,127768,14,127770,127770,14,127772,127772,14,127775,127776,14,127778,127779,14,127789,127791,14,127794,127795,14,127798,127798,14,127819,127819,14,127824,127824,14,127868,127868,14,127870,127871,14,127892,127893,14,127896,127896,14,127900,127901,14,127904,127940,14,127942,127942,14,127944,127944,14,127946,127946,14,127951,127955,14,127968,127971,14,127973,127984,14,127987,127987,14,127989,127989,14,127991,127991,14,127995,127999,5,128008,128008,14,128012,128014,14,128017,128018,14,128020,128020,14,128022,128022,14,128042,128042,14,128063,128063,14,128065,128065,14,128101,128101,14,128108,128109,14,128173,128173,14,128182,128183,14,128236,128237,14,128239,128239,14,128245,128245,14,128248,128248,14,128253,128253,14,128255,128258,14,128260,128263,14,128265,128265,14,128277,128277,14,128300,128301,14,128326,128328,14,128331,128334,14,128336,128347,14,128360,128366,14,128369,128370,14,128378,128378,14,128391,128391,14,128394,128397,14,128400,128400,14,128405,128406,14,128420,128420,14,128422,128423,14,128425,128432,14,128435,128443,14,128445,128449,14,128453,128464,14,128468,128475,14,128479,128480,14,128482,128482,14,128484,128487,14,128489,128494,14,128496,128498,14,128500,128505,14,128507,128511,14,128513,128518,14,128521,128525,14,128527,128527,14,128529,128529,14,128533,128533,14,128535,128535,14,128537,128537,14]")}getGraphemeBreakType(e){if(e<32)return 10===e?3:13===e?2:4;if(e<127)return 0;let t=this._data,i=t.length/3,n=1;for(;n<=i;)if(et[3*n+1]))return t[3*n+2];n=2*n+1}return 0}}og._INSTANCE=null;class op{static getInstance(e){return op.cache.get(Array.from(e))}static getLocales(){return op._locales.value}constructor(e){this.confusableDictionary=e}isAmbiguous(e){return this.confusableDictionary.has(e)}getPrimaryConfusable(e){return this.confusableDictionary.get(e)}getConfusableCodePoints(){return new Set(this.confusableDictionary.keys())}}op.ambiguousCharacterData=new rF(()=>JSON.parse('{"_common":[8232,32,8233,32,5760,32,8192,32,8193,32,8194,32,8195,32,8196,32,8197,32,8198,32,8200,32,8201,32,8202,32,8287,32,8199,32,8239,32,2042,95,65101,95,65102,95,65103,95,8208,45,8209,45,8210,45,65112,45,1748,45,8259,45,727,45,8722,45,10134,45,11450,45,1549,44,1643,44,8218,44,184,44,42233,44,894,59,2307,58,2691,58,1417,58,1795,58,1796,58,5868,58,65072,58,6147,58,6153,58,8282,58,1475,58,760,58,42889,58,8758,58,720,58,42237,58,451,33,11601,33,660,63,577,63,2429,63,5038,63,42731,63,119149,46,8228,46,1793,46,1794,46,42510,46,68176,46,1632,46,1776,46,42232,46,1373,96,65287,96,8219,96,8242,96,1370,96,1523,96,8175,96,65344,96,900,96,8189,96,8125,96,8127,96,8190,96,697,96,884,96,712,96,714,96,715,96,756,96,699,96,701,96,700,96,702,96,42892,96,1497,96,2036,96,2037,96,5194,96,5836,96,94033,96,94034,96,65339,91,10088,40,10098,40,12308,40,64830,40,65341,93,10089,41,10099,41,12309,41,64831,41,10100,123,119060,123,10101,125,65342,94,8270,42,1645,42,8727,42,66335,42,5941,47,8257,47,8725,47,8260,47,9585,47,10187,47,10744,47,119354,47,12755,47,12339,47,11462,47,20031,47,12035,47,65340,92,65128,92,8726,92,10189,92,10741,92,10745,92,119311,92,119355,92,12756,92,20022,92,12034,92,42872,38,708,94,710,94,5869,43,10133,43,66203,43,8249,60,10094,60,706,60,119350,60,5176,60,5810,60,5120,61,11840,61,12448,61,42239,61,8250,62,10095,62,707,62,119351,62,5171,62,94015,62,8275,126,732,126,8128,126,8764,126,65372,124,65293,45,120784,50,120794,50,120804,50,120814,50,120824,50,130034,50,42842,50,423,50,1000,50,42564,50,5311,50,42735,50,119302,51,120785,51,120795,51,120805,51,120815,51,120825,51,130035,51,42923,51,540,51,439,51,42858,51,11468,51,1248,51,94011,51,71882,51,120786,52,120796,52,120806,52,120816,52,120826,52,130036,52,5070,52,71855,52,120787,53,120797,53,120807,53,120817,53,120827,53,130037,53,444,53,71867,53,120788,54,120798,54,120808,54,120818,54,120828,54,130038,54,11474,54,5102,54,71893,54,119314,55,120789,55,120799,55,120809,55,120819,55,120829,55,130039,55,66770,55,71878,55,2819,56,2538,56,2666,56,125131,56,120790,56,120800,56,120810,56,120820,56,120830,56,130040,56,547,56,546,56,66330,56,2663,57,2920,57,2541,57,3437,57,120791,57,120801,57,120811,57,120821,57,120831,57,130041,57,42862,57,11466,57,71884,57,71852,57,71894,57,9082,97,65345,97,119834,97,119886,97,119938,97,119990,97,120042,97,120094,97,120146,97,120198,97,120250,97,120302,97,120354,97,120406,97,120458,97,593,97,945,97,120514,97,120572,97,120630,97,120688,97,120746,97,65313,65,119808,65,119860,65,119912,65,119964,65,120016,65,120068,65,120120,65,120172,65,120224,65,120276,65,120328,65,120380,65,120432,65,913,65,120488,65,120546,65,120604,65,120662,65,120720,65,5034,65,5573,65,42222,65,94016,65,66208,65,119835,98,119887,98,119939,98,119991,98,120043,98,120095,98,120147,98,120199,98,120251,98,120303,98,120355,98,120407,98,120459,98,388,98,5071,98,5234,98,5551,98,65314,66,8492,66,119809,66,119861,66,119913,66,120017,66,120069,66,120121,66,120173,66,120225,66,120277,66,120329,66,120381,66,120433,66,42932,66,914,66,120489,66,120547,66,120605,66,120663,66,120721,66,5108,66,5623,66,42192,66,66178,66,66209,66,66305,66,65347,99,8573,99,119836,99,119888,99,119940,99,119992,99,120044,99,120096,99,120148,99,120200,99,120252,99,120304,99,120356,99,120408,99,120460,99,7428,99,1010,99,11429,99,43951,99,66621,99,128844,67,71922,67,71913,67,65315,67,8557,67,8450,67,8493,67,119810,67,119862,67,119914,67,119966,67,120018,67,120174,67,120226,67,120278,67,120330,67,120382,67,120434,67,1017,67,11428,67,5087,67,42202,67,66210,67,66306,67,66581,67,66844,67,8574,100,8518,100,119837,100,119889,100,119941,100,119993,100,120045,100,120097,100,120149,100,120201,100,120253,100,120305,100,120357,100,120409,100,120461,100,1281,100,5095,100,5231,100,42194,100,8558,68,8517,68,119811,68,119863,68,119915,68,119967,68,120019,68,120071,68,120123,68,120175,68,120227,68,120279,68,120331,68,120383,68,120435,68,5024,68,5598,68,5610,68,42195,68,8494,101,65349,101,8495,101,8519,101,119838,101,119890,101,119942,101,120046,101,120098,101,120150,101,120202,101,120254,101,120306,101,120358,101,120410,101,120462,101,43826,101,1213,101,8959,69,65317,69,8496,69,119812,69,119864,69,119916,69,120020,69,120072,69,120124,69,120176,69,120228,69,120280,69,120332,69,120384,69,120436,69,917,69,120492,69,120550,69,120608,69,120666,69,120724,69,11577,69,5036,69,42224,69,71846,69,71854,69,66182,69,119839,102,119891,102,119943,102,119995,102,120047,102,120099,102,120151,102,120203,102,120255,102,120307,102,120359,102,120411,102,120463,102,43829,102,42905,102,383,102,7837,102,1412,102,119315,70,8497,70,119813,70,119865,70,119917,70,120021,70,120073,70,120125,70,120177,70,120229,70,120281,70,120333,70,120385,70,120437,70,42904,70,988,70,120778,70,5556,70,42205,70,71874,70,71842,70,66183,70,66213,70,66853,70,65351,103,8458,103,119840,103,119892,103,119944,103,120048,103,120100,103,120152,103,120204,103,120256,103,120308,103,120360,103,120412,103,120464,103,609,103,7555,103,397,103,1409,103,119814,71,119866,71,119918,71,119970,71,120022,71,120074,71,120126,71,120178,71,120230,71,120282,71,120334,71,120386,71,120438,71,1292,71,5056,71,5107,71,42198,71,65352,104,8462,104,119841,104,119945,104,119997,104,120049,104,120101,104,120153,104,120205,104,120257,104,120309,104,120361,104,120413,104,120465,104,1211,104,1392,104,5058,104,65320,72,8459,72,8460,72,8461,72,119815,72,119867,72,119919,72,120023,72,120179,72,120231,72,120283,72,120335,72,120387,72,120439,72,919,72,120494,72,120552,72,120610,72,120668,72,120726,72,11406,72,5051,72,5500,72,42215,72,66255,72,731,105,9075,105,65353,105,8560,105,8505,105,8520,105,119842,105,119894,105,119946,105,119998,105,120050,105,120102,105,120154,105,120206,105,120258,105,120310,105,120362,105,120414,105,120466,105,120484,105,618,105,617,105,953,105,8126,105,890,105,120522,105,120580,105,120638,105,120696,105,120754,105,1110,105,42567,105,1231,105,43893,105,5029,105,71875,105,65354,106,8521,106,119843,106,119895,106,119947,106,119999,106,120051,106,120103,106,120155,106,120207,106,120259,106,120311,106,120363,106,120415,106,120467,106,1011,106,1112,106,65322,74,119817,74,119869,74,119921,74,119973,74,120025,74,120077,74,120129,74,120181,74,120233,74,120285,74,120337,74,120389,74,120441,74,42930,74,895,74,1032,74,5035,74,5261,74,42201,74,119844,107,119896,107,119948,107,120000,107,120052,107,120104,107,120156,107,120208,107,120260,107,120312,107,120364,107,120416,107,120468,107,8490,75,65323,75,119818,75,119870,75,119922,75,119974,75,120026,75,120078,75,120130,75,120182,75,120234,75,120286,75,120338,75,120390,75,120442,75,922,75,120497,75,120555,75,120613,75,120671,75,120729,75,11412,75,5094,75,5845,75,42199,75,66840,75,1472,108,8739,73,9213,73,65512,73,1633,108,1777,73,66336,108,125127,108,120783,73,120793,73,120803,73,120813,73,120823,73,130033,73,65321,73,8544,73,8464,73,8465,73,119816,73,119868,73,119920,73,120024,73,120128,73,120180,73,120232,73,120284,73,120336,73,120388,73,120440,73,65356,108,8572,73,8467,108,119845,108,119897,108,119949,108,120001,108,120053,108,120105,73,120157,73,120209,73,120261,73,120313,73,120365,73,120417,73,120469,73,448,73,120496,73,120554,73,120612,73,120670,73,120728,73,11410,73,1030,73,1216,73,1493,108,1503,108,1575,108,126464,108,126592,108,65166,108,65165,108,1994,108,11599,73,5825,73,42226,73,93992,73,66186,124,66313,124,119338,76,8556,76,8466,76,119819,76,119871,76,119923,76,120027,76,120079,76,120131,76,120183,76,120235,76,120287,76,120339,76,120391,76,120443,76,11472,76,5086,76,5290,76,42209,76,93974,76,71843,76,71858,76,66587,76,66854,76,65325,77,8559,77,8499,77,119820,77,119872,77,119924,77,120028,77,120080,77,120132,77,120184,77,120236,77,120288,77,120340,77,120392,77,120444,77,924,77,120499,77,120557,77,120615,77,120673,77,120731,77,1018,77,11416,77,5047,77,5616,77,5846,77,42207,77,66224,77,66321,77,119847,110,119899,110,119951,110,120003,110,120055,110,120107,110,120159,110,120211,110,120263,110,120315,110,120367,110,120419,110,120471,110,1400,110,1404,110,65326,78,8469,78,119821,78,119873,78,119925,78,119977,78,120029,78,120081,78,120185,78,120237,78,120289,78,120341,78,120393,78,120445,78,925,78,120500,78,120558,78,120616,78,120674,78,120732,78,11418,78,42208,78,66835,78,3074,111,3202,111,3330,111,3458,111,2406,111,2662,111,2790,111,3046,111,3174,111,3302,111,3430,111,3664,111,3792,111,4160,111,1637,111,1781,111,65359,111,8500,111,119848,111,119900,111,119952,111,120056,111,120108,111,120160,111,120212,111,120264,111,120316,111,120368,111,120420,111,120472,111,7439,111,7441,111,43837,111,959,111,120528,111,120586,111,120644,111,120702,111,120760,111,963,111,120532,111,120590,111,120648,111,120706,111,120764,111,11423,111,4351,111,1413,111,1505,111,1607,111,126500,111,126564,111,126596,111,65259,111,65260,111,65258,111,65257,111,1726,111,64428,111,64429,111,64427,111,64426,111,1729,111,64424,111,64425,111,64423,111,64422,111,1749,111,3360,111,4125,111,66794,111,71880,111,71895,111,66604,111,1984,79,2534,79,2918,79,12295,79,70864,79,71904,79,120782,79,120792,79,120802,79,120812,79,120822,79,130032,79,65327,79,119822,79,119874,79,119926,79,119978,79,120030,79,120082,79,120134,79,120186,79,120238,79,120290,79,120342,79,120394,79,120446,79,927,79,120502,79,120560,79,120618,79,120676,79,120734,79,11422,79,1365,79,11604,79,4816,79,2848,79,66754,79,42227,79,71861,79,66194,79,66219,79,66564,79,66838,79,9076,112,65360,112,119849,112,119901,112,119953,112,120005,112,120057,112,120109,112,120161,112,120213,112,120265,112,120317,112,120369,112,120421,112,120473,112,961,112,120530,112,120544,112,120588,112,120602,112,120646,112,120660,112,120704,112,120718,112,120762,112,120776,112,11427,112,65328,80,8473,80,119823,80,119875,80,119927,80,119979,80,120031,80,120083,80,120187,80,120239,80,120291,80,120343,80,120395,80,120447,80,929,80,120504,80,120562,80,120620,80,120678,80,120736,80,11426,80,5090,80,5229,80,42193,80,66197,80,119850,113,119902,113,119954,113,120006,113,120058,113,120110,113,120162,113,120214,113,120266,113,120318,113,120370,113,120422,113,120474,113,1307,113,1379,113,1382,113,8474,81,119824,81,119876,81,119928,81,119980,81,120032,81,120084,81,120188,81,120240,81,120292,81,120344,81,120396,81,120448,81,11605,81,119851,114,119903,114,119955,114,120007,114,120059,114,120111,114,120163,114,120215,114,120267,114,120319,114,120371,114,120423,114,120475,114,43847,114,43848,114,7462,114,11397,114,43905,114,119318,82,8475,82,8476,82,8477,82,119825,82,119877,82,119929,82,120033,82,120189,82,120241,82,120293,82,120345,82,120397,82,120449,82,422,82,5025,82,5074,82,66740,82,5511,82,42211,82,94005,82,65363,115,119852,115,119904,115,119956,115,120008,115,120060,115,120112,115,120164,115,120216,115,120268,115,120320,115,120372,115,120424,115,120476,115,42801,115,445,115,1109,115,43946,115,71873,115,66632,115,65331,83,119826,83,119878,83,119930,83,119982,83,120034,83,120086,83,120138,83,120190,83,120242,83,120294,83,120346,83,120398,83,120450,83,1029,83,1359,83,5077,83,5082,83,42210,83,94010,83,66198,83,66592,83,119853,116,119905,116,119957,116,120009,116,120061,116,120113,116,120165,116,120217,116,120269,116,120321,116,120373,116,120425,116,120477,116,8868,84,10201,84,128872,84,65332,84,119827,84,119879,84,119931,84,119983,84,120035,84,120087,84,120139,84,120191,84,120243,84,120295,84,120347,84,120399,84,120451,84,932,84,120507,84,120565,84,120623,84,120681,84,120739,84,11430,84,5026,84,42196,84,93962,84,71868,84,66199,84,66225,84,66325,84,119854,117,119906,117,119958,117,120010,117,120062,117,120114,117,120166,117,120218,117,120270,117,120322,117,120374,117,120426,117,120478,117,42911,117,7452,117,43854,117,43858,117,651,117,965,117,120534,117,120592,117,120650,117,120708,117,120766,117,1405,117,66806,117,71896,117,8746,85,8899,85,119828,85,119880,85,119932,85,119984,85,120036,85,120088,85,120140,85,120192,85,120244,85,120296,85,120348,85,120400,85,120452,85,1357,85,4608,85,66766,85,5196,85,42228,85,94018,85,71864,85,8744,118,8897,118,65366,118,8564,118,119855,118,119907,118,119959,118,120011,118,120063,118,120115,118,120167,118,120219,118,120271,118,120323,118,120375,118,120427,118,120479,118,7456,118,957,118,120526,118,120584,118,120642,118,120700,118,120758,118,1141,118,1496,118,71430,118,43945,118,71872,118,119309,86,1639,86,1783,86,8548,86,119829,86,119881,86,119933,86,119985,86,120037,86,120089,86,120141,86,120193,86,120245,86,120297,86,120349,86,120401,86,120453,86,1140,86,11576,86,5081,86,5167,86,42719,86,42214,86,93960,86,71840,86,66845,86,623,119,119856,119,119908,119,119960,119,120012,119,120064,119,120116,119,120168,119,120220,119,120272,119,120324,119,120376,119,120428,119,120480,119,7457,119,1121,119,1309,119,1377,119,71434,119,71438,119,71439,119,43907,119,71919,87,71910,87,119830,87,119882,87,119934,87,119986,87,120038,87,120090,87,120142,87,120194,87,120246,87,120298,87,120350,87,120402,87,120454,87,1308,87,5043,87,5076,87,42218,87,5742,120,10539,120,10540,120,10799,120,65368,120,8569,120,119857,120,119909,120,119961,120,120013,120,120065,120,120117,120,120169,120,120221,120,120273,120,120325,120,120377,120,120429,120,120481,120,5441,120,5501,120,5741,88,9587,88,66338,88,71916,88,65336,88,8553,88,119831,88,119883,88,119935,88,119987,88,120039,88,120091,88,120143,88,120195,88,120247,88,120299,88,120351,88,120403,88,120455,88,42931,88,935,88,120510,88,120568,88,120626,88,120684,88,120742,88,11436,88,11613,88,5815,88,42219,88,66192,88,66228,88,66327,88,66855,88,611,121,7564,121,65369,121,119858,121,119910,121,119962,121,120014,121,120066,121,120118,121,120170,121,120222,121,120274,121,120326,121,120378,121,120430,121,120482,121,655,121,7935,121,43866,121,947,121,8509,121,120516,121,120574,121,120632,121,120690,121,120748,121,1199,121,4327,121,71900,121,65337,89,119832,89,119884,89,119936,89,119988,89,120040,89,120092,89,120144,89,120196,89,120248,89,120300,89,120352,89,120404,89,120456,89,933,89,978,89,120508,89,120566,89,120624,89,120682,89,120740,89,11432,89,1198,89,5033,89,5053,89,42220,89,94019,89,71844,89,66226,89,119859,122,119911,122,119963,122,120015,122,120067,122,120119,122,120171,122,120223,122,120275,122,120327,122,120379,122,120431,122,120483,122,7458,122,43923,122,71876,122,66293,90,71909,90,65338,90,8484,90,8488,90,119833,90,119885,90,119937,90,119989,90,120041,90,120197,90,120249,90,120301,90,120353,90,120405,90,120457,90,918,90,120493,90,120551,90,120609,90,120667,90,120725,90,5059,90,42204,90,71849,90,65282,34,65284,36,65285,37,65286,38,65290,42,65291,43,65294,46,65295,47,65296,48,65297,49,65298,50,65299,51,65300,52,65301,53,65302,54,65303,55,65304,56,65305,57,65308,60,65309,61,65310,62,65312,64,65316,68,65318,70,65319,71,65324,76,65329,81,65330,82,65333,85,65334,86,65335,87,65343,95,65346,98,65348,100,65350,102,65355,107,65357,109,65358,110,65361,113,65362,114,65364,116,65365,117,65367,119,65370,122,65371,123,65373,125,119846,109],"_default":[160,32,8211,45,65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"cs":[65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"de":[65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"es":[8211,45,65374,126,65306,58,65281,33,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"fr":[65374,126,65306,58,65281,33,8216,96,8245,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"it":[160,32,8211,45,65374,126,65306,58,65281,33,8216,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"ja":[8211,45,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65292,44,65307,59],"ko":[8211,45,65374,126,65306,58,65281,33,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"pl":[65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"pt-BR":[65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"qps-ploc":[160,32,8211,45,65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"ru":[65374,126,65306,58,65281,33,8216,96,8217,96,8245,96,180,96,12494,47,305,105,921,73,1009,112,215,120,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"tr":[160,32,8211,45,65374,126,65306,58,65281,33,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65288,40,65289,41,65292,44,65307,59,65311,63],"zh-hans":[65374,126,65306,58,65281,33,8245,96,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65288,40,65289,41],"zh-hant":[8211,45,65374,126,180,96,12494,47,1047,51,1073,54,1072,97,1040,65,1068,98,1042,66,1089,99,1057,67,1077,101,1045,69,1053,72,305,105,1050,75,921,73,1052,77,1086,111,1054,79,1009,112,1088,112,1056,80,1075,114,1058,84,215,120,1093,120,1061,88,1091,121,1059,89,65283,35,65307,59]}')),op.cache=new class{constructor(e){this.fn=e,this.lastCache=void 0,this.lastArgKey=void 0}get(e){let t=JSON.stringify(e);return this.lastArgKey!==t&&(this.lastArgKey=t,this.lastCache=this.fn(e)),this.lastCache}}(e=>{let t;function i(e){let t=new Map;for(let i=0;i!e.startsWith("_")&&e in n);for(let e of(0===r.length&&(r=["_default"]),r)){let r=i(n[e]);t=function(e,t){if(!e)return t;let i=new Map;for(let[n,r]of e)t.has(n)&&i.set(n,r);return i}(t,r)}let o=i(n._common),s=function(e,t){let i=new Map(e);for(let[e,n]of t)i.set(e,n);return i}(o,t);return new op(s)}),op._locales=new rF(()=>Object.keys(op.ambiguousCharacterData.value).filter(e=>!e.startsWith("_")));class om{static getRawData(){return JSON.parse("[9,10,11,12,13,32,127,160,173,847,1564,4447,4448,6068,6069,6155,6156,6157,6158,7355,7356,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8203,8204,8205,8206,8207,8234,8235,8236,8237,8238,8239,8287,8288,8289,8290,8291,8292,8293,8294,8295,8296,8297,8298,8299,8300,8301,8302,8303,10240,12288,12644,65024,65025,65026,65027,65028,65029,65030,65031,65032,65033,65034,65035,65036,65037,65038,65039,65279,65440,65520,65521,65522,65523,65524,65525,65526,65527,65528,65532,78844,119155,119156,119157,119158,119159,119160,119161,119162,917504,917505,917506,917507,917508,917509,917510,917511,917512,917513,917514,917515,917516,917517,917518,917519,917520,917521,917522,917523,917524,917525,917526,917527,917528,917529,917530,917531,917532,917533,917534,917535,917536,917537,917538,917539,917540,917541,917542,917543,917544,917545,917546,917547,917548,917549,917550,917551,917552,917553,917554,917555,917556,917557,917558,917559,917560,917561,917562,917563,917564,917565,917566,917567,917568,917569,917570,917571,917572,917573,917574,917575,917576,917577,917578,917579,917580,917581,917582,917583,917584,917585,917586,917587,917588,917589,917590,917591,917592,917593,917594,917595,917596,917597,917598,917599,917600,917601,917602,917603,917604,917605,917606,917607,917608,917609,917610,917611,917612,917613,917614,917615,917616,917617,917618,917619,917620,917621,917622,917623,917624,917625,917626,917627,917628,917629,917630,917631,917760,917761,917762,917763,917764,917765,917766,917767,917768,917769,917770,917771,917772,917773,917774,917775,917776,917777,917778,917779,917780,917781,917782,917783,917784,917785,917786,917787,917788,917789,917790,917791,917792,917793,917794,917795,917796,917797,917798,917799,917800,917801,917802,917803,917804,917805,917806,917807,917808,917809,917810,917811,917812,917813,917814,917815,917816,917817,917818,917819,917820,917821,917822,917823,917824,917825,917826,917827,917828,917829,917830,917831,917832,917833,917834,917835,917836,917837,917838,917839,917840,917841,917842,917843,917844,917845,917846,917847,917848,917849,917850,917851,917852,917853,917854,917855,917856,917857,917858,917859,917860,917861,917862,917863,917864,917865,917866,917867,917868,917869,917870,917871,917872,917873,917874,917875,917876,917877,917878,917879,917880,917881,917882,917883,917884,917885,917886,917887,917888,917889,917890,917891,917892,917893,917894,917895,917896,917897,917898,917899,917900,917901,917902,917903,917904,917905,917906,917907,917908,917909,917910,917911,917912,917913,917914,917915,917916,917917,917918,917919,917920,917921,917922,917923,917924,917925,917926,917927,917928,917929,917930,917931,917932,917933,917934,917935,917936,917937,917938,917939,917940,917941,917942,917943,917944,917945,917946,917947,917948,917949,917950,917951,917952,917953,917954,917955,917956,917957,917958,917959,917960,917961,917962,917963,917964,917965,917966,917967,917968,917969,917970,917971,917972,917973,917974,917975,917976,917977,917978,917979,917980,917981,917982,917983,917984,917985,917986,917987,917988,917989,917990,917991,917992,917993,917994,917995,917996,917997,917998,917999]")}static getData(){return this._data||(this._data=new Set(om.getRawData())),this._data}static isInvisibleCharacter(e){return om.getData().has(e)}static get codePoints(){return om.getData()}}om._data=void 0;class o_{constructor(){this._zoomFactor=1}getZoomFactor(){return this._zoomFactor}}o_.INSTANCE=new o_;class oE extends nc{constructor(){super(),this._onDidChange=this._register(new ny),this.onDidChange=this._onDidChange.event,this._listener=()=>this._handleChange(!0),this._mediaQueryList=null,this._handleChange(!1)}_handleChange(e){var t;null===(t=this._mediaQueryList)||void 0===t||t.removeEventListener("change",this._listener),this._mediaQueryList=window.matchMedia(`(resolution: ${window.devicePixelRatio}dppx)`),this._mediaQueryList.addEventListener("change",this._listener),e&&this._onDidChange.fire()}}class ov extends nc{get value(){return this._value}constructor(){super(),this._onDidChange=this._register(new ny),this.onDidChange=this._onDidChange.event,this._value=this._getPixelRatio();let e=this._register(new oE);this._register(e.onDidChange(()=>{this._value=this._getPixelRatio(),this._onDidChange.fire(this._value)}))}_getPixelRatio(){let e=document.createElement("canvas").getContext("2d"),t=window.devicePixelRatio||1,i=e.webkitBackingStorePixelRatio||e.mozBackingStorePixelRatio||e.msBackingStorePixelRatio||e.oBackingStorePixelRatio||e.backingStorePixelRatio||1;return t/i}}function ob(e,t){"string"==typeof e&&(e=window.matchMedia(e)),e.addEventListener("change",t)}let oC=new class{constructor(){this._pixelRatioMonitor=null}_getOrCreatePixelRatioMonitor(){return this._pixelRatioMonitor||(this._pixelRatioMonitor=new ov),this._pixelRatioMonitor}get value(){return this._getOrCreatePixelRatioMonitor().value}get onDidChange(){return this._getOrCreatePixelRatioMonitor().onDidChange}},oS=navigator.userAgent,oy=oS.indexOf("Firefox")>=0,oT=oS.indexOf("AppleWebKit")>=0,oR=oS.indexOf("Chrome")>=0,oA=!oR&&oS.indexOf("Safari")>=0,oN=!oR&&!oA&&oT;oS.indexOf("Electron/");let oO=oS.indexOf("Android")>=0,oL=!1;if(window.matchMedia){let e=window.matchMedia("(display-mode: standalone) or (display-mode: window-controls-overlay)"),t=window.matchMedia("(display-mode: fullscreen)");oL=e.matches,ob(e,({matches:e})=>{oL&&t.matches||(oL=e)})}class oI{constructor(e){this.domNode=e,this._maxWidth="",this._width="",this._height="",this._top="",this._left="",this._bottom="",this._right="",this._paddingLeft="",this._fontFamily="",this._fontWeight="",this._fontSize="",this._fontStyle="",this._fontFeatureSettings="",this._fontVariationSettings="",this._textDecoration="",this._lineHeight="",this._letterSpacing="",this._className="",this._display="",this._position="",this._visibility="",this._color="",this._backgroundColor="",this._layerHint=!1,this._contain="none",this._boxShadow=""}setMaxWidth(e){let t=ow(e);this._maxWidth!==t&&(this._maxWidth=t,this.domNode.style.maxWidth=this._maxWidth)}setWidth(e){let t=ow(e);this._width!==t&&(this._width=t,this.domNode.style.width=this._width)}setHeight(e){let t=ow(e);this._height!==t&&(this._height=t,this.domNode.style.height=this._height)}setTop(e){let t=ow(e);this._top!==t&&(this._top=t,this.domNode.style.top=this._top)}setLeft(e){let t=ow(e);this._left!==t&&(this._left=t,this.domNode.style.left=this._left)}setBottom(e){let t=ow(e);this._bottom!==t&&(this._bottom=t,this.domNode.style.bottom=this._bottom)}setRight(e){let t=ow(e);this._right!==t&&(this._right=t,this.domNode.style.right=this._right)}setPaddingLeft(e){let t=ow(e);this._paddingLeft!==t&&(this._paddingLeft=t,this.domNode.style.paddingLeft=this._paddingLeft)}setFontFamily(e){this._fontFamily!==e&&(this._fontFamily=e,this.domNode.style.fontFamily=this._fontFamily)}setFontWeight(e){this._fontWeight!==e&&(this._fontWeight=e,this.domNode.style.fontWeight=this._fontWeight)}setFontSize(e){let t=ow(e);this._fontSize!==t&&(this._fontSize=t,this.domNode.style.fontSize=this._fontSize)}setFontStyle(e){this._fontStyle!==e&&(this._fontStyle=e,this.domNode.style.fontStyle=this._fontStyle)}setFontFeatureSettings(e){this._fontFeatureSettings!==e&&(this._fontFeatureSettings=e,this.domNode.style.fontFeatureSettings=this._fontFeatureSettings)}setFontVariationSettings(e){this._fontVariationSettings!==e&&(this._fontVariationSettings=e,this.domNode.style.fontVariationSettings=this._fontVariationSettings)}setTextDecoration(e){this._textDecoration!==e&&(this._textDecoration=e,this.domNode.style.textDecoration=this._textDecoration)}setLineHeight(e){let t=ow(e);this._lineHeight!==t&&(this._lineHeight=t,this.domNode.style.lineHeight=this._lineHeight)}setLetterSpacing(e){let t=ow(e);this._letterSpacing!==t&&(this._letterSpacing=t,this.domNode.style.letterSpacing=this._letterSpacing)}setClassName(e){this._className!==e&&(this._className=e,this.domNode.className=this._className)}toggleClassName(e,t){this.domNode.classList.toggle(e,t),this._className=this.domNode.className}setDisplay(e){this._display!==e&&(this._display=e,this.domNode.style.display=this._display)}setPosition(e){this._position!==e&&(this._position=e,this.domNode.style.position=this._position)}setVisibility(e){this._visibility!==e&&(this._visibility=e,this.domNode.style.visibility=this._visibility)}setColor(e){this._color!==e&&(this._color=e,this.domNode.style.color=this._color)}setBackgroundColor(e){this._backgroundColor!==e&&(this._backgroundColor=e,this.domNode.style.backgroundColor=this._backgroundColor)}setLayerHinting(e){this._layerHint!==e&&(this._layerHint=e,this.domNode.style.transform=this._layerHint?"translate3d(0px, 0px, 0px)":"")}setBoxShadow(e){this._boxShadow!==e&&(this._boxShadow=e,this.domNode.style.boxShadow=e)}setContain(e){this._contain!==e&&(this._contain=e,this.domNode.style.contain=this._contain)}setAttribute(e,t){this.domNode.setAttribute(e,t)}removeAttribute(e){this.domNode.removeAttribute(e)}appendChild(e){this.domNode.appendChild(e.domNode)}removeChild(e){this.domNode.removeChild(e.domNode)}}function ow(e){return"number"==typeof e?`${e}px`:e}function oD(e){return new oI(e)}function ox(e,t){e instanceof oI?(e.setFontFamily(t.getMassagedFontFamily()),e.setFontWeight(t.fontWeight),e.setFontSize(t.fontSize),e.setFontFeatureSettings(t.fontFeatureSettings),e.setFontVariationSettings(t.fontVariationSettings),e.setLineHeight(t.lineHeight),e.setLetterSpacing(t.letterSpacing)):(e.style.fontFamily=t.getMassagedFontFamily(),e.style.fontWeight=t.fontWeight,e.style.fontSize=t.fontSize+"px",e.style.fontFeatureSettings=t.fontFeatureSettings,e.style.fontVariationSettings=t.fontVariationSettings,e.style.lineHeight=t.lineHeight+"px",e.style.letterSpacing=t.letterSpacing+"px")}class oM{constructor(e,t){this.chr=e,this.type=t,this.width=0}fulfill(e){this.width=e}}class ok{constructor(e,t){this._bareFontInfo=e,this._requests=t,this._container=null,this._testElements=null}read(){this._createDomElements(),document.body.appendChild(this._container),this._readFromDomElements(),document.body.removeChild(this._container),this._container=null,this._testElements=null}_createDomElements(){let e=document.createElement("div");e.style.position="absolute",e.style.top="-50000px",e.style.width="50000px";let t=document.createElement("div");ox(t,this._bareFontInfo),e.appendChild(t);let i=document.createElement("div");ox(i,this._bareFontInfo),i.style.fontWeight="bold",e.appendChild(i);let n=document.createElement("div");ox(n,this._bareFontInfo),n.style.fontStyle="italic",e.appendChild(n);let r=[];for(let e of this._requests){let o;0===e.type&&(o=t),2===e.type&&(o=i),1===e.type&&(o=n),o.appendChild(document.createElement("br"));let s=document.createElement("span");ok._render(s,e),o.appendChild(s),r.push(s)}this._container=e,this._testElements=r}static _render(e,t){if(" "===t.chr){let t="\xa0";for(let e=0;e<8;e++)t+=t;e.innerText=t}else{let i=t.chr;for(let e=0;e<8;e++)i+=i;e.textContent=i}}_readFromDomElements(){for(let e=0,t=this._requests.length;ethis._values[e])}}let oV=new class extends nc{constructor(){super(),this._onDidChange=this._register(new ny),this.onDidChange=this._onDidChange.event,this._cache=new oH,this._evictUntrustedReadingsTimeout=-1}dispose(){-1!==this._evictUntrustedReadingsTimeout&&(window.clearTimeout(this._evictUntrustedReadingsTimeout),this._evictUntrustedReadingsTimeout=-1),super.dispose()}clearAllFontInfos(){this._cache=new oH,this._onDidChange.fire()}_writeToCache(e,t){this._cache.put(e,t),t.isTrusted||-1!==this._evictUntrustedReadingsTimeout||(this._evictUntrustedReadingsTimeout=window.setTimeout(()=>{this._evictUntrustedReadingsTimeout=-1,this._evictUntrustedReadings()},5e3))}_evictUntrustedReadings(){let e=this._cache.getValues(),t=!1;for(let i of e)i.isTrusted||(t=!0,this._cache.remove(i));t&&this._onDidChange.fire()}readFontInfo(e){if(!this._cache.has(e)){let t=this._actualReadFontInfo(e);(t.typicalHalfwidthCharacterWidth<=2||t.typicalFullwidthCharacterWidth<=2||t.spaceWidth<=2||t.maxDigitWidth<=2)&&(t=new oU({pixelRatio:oC.value,fontFamily:t.fontFamily,fontWeight:t.fontWeight,fontSize:t.fontSize,fontFeatureSettings:t.fontFeatureSettings,fontVariationSettings:t.fontVariationSettings,lineHeight:t.lineHeight,letterSpacing:t.letterSpacing,isMonospace:t.isMonospace,typicalHalfwidthCharacterWidth:Math.max(t.typicalHalfwidthCharacterWidth,5),typicalFullwidthCharacterWidth:Math.max(t.typicalFullwidthCharacterWidth,5),canUseHalfwidthRightwardsArrow:t.canUseHalfwidthRightwardsArrow,spaceWidth:Math.max(t.spaceWidth,5),middotWidth:Math.max(t.middotWidth,5),wsmiddotWidth:Math.max(t.wsmiddotWidth,5),maxDigitWidth:Math.max(t.maxDigitWidth,5)},!1)),this._writeToCache(e,t)}return this._cache.get(e)}_createRequest(e,t,i,n){let r=new oM(e,t);return i.push(r),null==n||n.push(r),r}_actualReadFontInfo(e){let t=[],i=[],n=this._createRequest("n",0,t,i),r=this._createRequest("m",0,t,null),o=this._createRequest(" ",0,t,i),s=this._createRequest("0",0,t,i),a=this._createRequest("1",0,t,i),l=this._createRequest("2",0,t,i),h=this._createRequest("3",0,t,i),u=this._createRequest("4",0,t,i),d=this._createRequest("5",0,t,i),c=this._createRequest("6",0,t,i),f=this._createRequest("7",0,t,i),g=this._createRequest("8",0,t,i),p=this._createRequest("9",0,t,i),m=this._createRequest("→",0,t,i),_=this._createRequest("→",0,t,null),E=this._createRequest("\xb7",0,t,i),v=this._createRequest(String.fromCharCode(11825),0,t,null),b="|/-_ilm%";for(let e=0,n=b.length;e.001){S=!1;break}}let T=!0;return S&&_.width!==y&&(T=!1),_.width>m.width&&(T=!1),new oU({pixelRatio:oC.value,fontFamily:e.fontFamily,fontWeight:e.fontWeight,fontSize:e.fontSize,fontFeatureSettings:e.fontFeatureSettings,fontVariationSettings:e.fontVariationSettings,lineHeight:e.lineHeight,letterSpacing:e.letterSpacing,isMonospace:S,typicalHalfwidthCharacterWidth:n.width,typicalFullwidthCharacterWidth:r.width,canUseHalfwidthRightwardsArrow:T,spaceWidth:o.width,middotWidth:E.width,wsmiddotWidth:v.width,maxDigitWidth:C},!0)}};(ef=tY||(tY={})).serviceIds=new Map,ef.DI_TARGET="$di$target",ef.DI_DEPENDENCIES="$di$dependencies",ef.getServiceDependencies=function(e){return e[ef.DI_DEPENDENCIES]||[]};let oW=oG("instantiationService");function oG(e){if(tY.serviceIds.has(e))return tY.serviceIds.get(e);let t=function(e,i,n){if(3!=arguments.length)throw Error("@IServiceName-decorator can only be used to decorate a parameter");e[tY.DI_TARGET]===e?e[tY.DI_DEPENDENCIES].push({id:t,index:n}):(e[tY.DI_DEPENDENCIES]=[{id:t,index:n}],e[tY.DI_TARGET]=e)};return t.toString=()=>e,tY.serviceIds.set(e,t),t}let oj=oG("codeEditorService");function oz(e,t){if(!e)throw Error(t?`Assertion failed (${t})`:"Assertion Failed")}function oK(e,t="Unreachable"){throw Error(t)}function oY(e){e()||(e(),i1(new nt("Assertion Failed")))}function o$(e,t){let i=0;for(;i\-\./\\:\*\?\+\[\]\^,#@;"%\$\p{L}-]+/uy}static getLexeme(e){switch(e.type){case 0:return"(";case 1:return")";case 2:return"!";case 3:return e.isTripleEq?"===":"==";case 4:return e.isTripleEq?"!==":"!=";case 5:return"<";case 6:return"<=";case 7:case 8:return">=";case 9:return"=~";case 10:case 17:case 18:case 19:return e.lexeme;case 11:return"true";case 12:return"false";case 13:return"in";case 14:return"not";case 15:return"&&";case 16:return"||";case 20:return"EOF";default:throw i8(`unhandled token type: ${JSON.stringify(e)}; have you forgotten to add a case?`)}}reset(e){return this._input=e,this._start=0,this._current=0,this._tokens=[],this._errors=[],this}scan(){for(;!this._isAtEnd();){this._start=this._current;let e=this._advance();switch(e){case 40:this._addToken(0);break;case 41:this._addToken(1);break;case 33:if(this._match(61)){let e=this._match(61);this._tokens.push({type:4,offset:this._start,isTripleEq:e})}else this._addToken(2);break;case 39:this._quotedString();break;case 47:this._regex();break;case 61:if(this._match(61)){let e=this._match(61);this._tokens.push({type:3,offset:this._start,isTripleEq:e})}else this._match(126)?this._addToken(9):this._error(o0("==","=~"));break;case 60:this._addToken(this._match(61)?6:5);break;case 62:this._addToken(this._match(61)?8:7);break;case 38:this._match(38)?this._addToken(15):this._error(o0("&&"));break;case 124:this._match(124)?this._addToken(16):this._error(o0("||"));break;case 32:case 13:case 9:case 10:case 160:break;default:this._string()}}return this._start=this._current,this._addToken(20),Array.from(this._tokens)}_match(e){return!this._isAtEnd()&&this._input.charCodeAt(this._current)===e&&(this._current++,!0)}_advance(){return this._input.charCodeAt(this._current++)}_peek(){return this._isAtEnd()?0:this._input.charCodeAt(this._current)}_addToken(e){this._tokens.push({type:e,offset:this._start})}_error(e){let t=this._start,i=this._input.substring(this._start,this._current),n={type:19,offset:this._start,lexeme:i};this._errors.push({offset:t,lexeme:i,additionalInfo:e}),this._tokens.push(n)}_string(){this.stringRe.lastIndex=this._start;let e=this.stringRe.exec(this._input);if(e){this._current=this._start+e[0].length;let t=this._input.substring(this._start,this._current),i=o5._keywords.get(t);i?this._addToken(i):this._tokens.push({type:17,lexeme:t,offset:this._start})}}_quotedString(){for(;39!==this._peek()&&!this._isAtEnd();)this._advance();if(this._isAtEnd()){this._error(o1);return}this._advance(),this._tokens.push({type:18,lexeme:this._input.substring(this._start+1,this._current-1),offset:this._start+1})}_regex(){let e=this._current,t=!1,i=!1;for(;;){if(e>=this._input.length){this._current=e,this._error(o2);return}let n=this._input.charCodeAt(e);if(t)t=!1;else if(47!==n||i)91===n?i=!0:92===n?t=!0:93===n&&(i=!1);else{e++;break}e++}for(;e=this._input.length}}o5._regexFlags=new Set(["i","g","s","m","y","u"].map(e=>e.charCodeAt(0))),o5._keywords=new Map([["not",14],["in",13],["false",12],["true",11]]);let o4=new Map;o4.set("false",!1),o4.set("true",!0),o4.set("isMac",nz.dz),o4.set("isLinux",nz.IJ),o4.set("isWindows",nz.ED),o4.set("isWeb",nz.$L),o4.set("isMacNative",nz.dz&&!nz.$L),o4.set("isEdge",nz.un),o4.set("isFirefox",nz.vU),o4.set("isChrome",nz.i7),o4.set("isSafari",nz.G6);let o3=Object.prototype.hasOwnProperty,o6={regexParsingWithErrorRecovery:!0},o9=(0,rN.NC)("contextkey.parser.error.emptyString","Empty context key expression"),o8=(0,rN.NC)("contextkey.parser.error.emptyString.hint","Did you forget to write an expression? You can also put 'false' or 'true' to always evaluate to false or true, respectively."),o7=(0,rN.NC)("contextkey.parser.error.noInAfterNot","'in' after 'not'."),se=(0,rN.NC)("contextkey.parser.error.closingParenthesis","closing parenthesis ')'"),st=(0,rN.NC)("contextkey.parser.error.unexpectedToken","Unexpected token"),si=(0,rN.NC)("contextkey.parser.error.unexpectedToken.hint","Did you forget to put && or || before the token?"),sn=(0,rN.NC)("contextkey.parser.error.unexpectedEOF","Unexpected end of expression"),sr=(0,rN.NC)("contextkey.parser.error.unexpectedEOF.hint","Did you forget to put a context key?");class so{constructor(e=o6){this._config=e,this._scanner=new o5,this._tokens=[],this._current=0,this._parsingErrors=[],this._flagsGYRe=/g|y/g}parse(e){if(""===e){this._parsingErrors.push({message:o9,offset:0,lexeme:"",additionalInfo:o8});return}this._tokens=this._scanner.reset(e).scan(),this._current=0,this._parsingErrors=[];try{let e=this._expr();if(!this._isAtEnd()){let e=this._peek(),t=17===e.type?si:void 0;throw this._parsingErrors.push({message:st,offset:e.offset,lexeme:o5.getLexeme(e),additionalInfo:t}),so._parseError}return e}catch(e){if(e!==so._parseError)throw e;return}}_expr(){return this._or()}_or(){let e=[this._and()];for(;this._matchOne(16);){let t=this._and();e.push(t)}return 1===e.length?e[0]:ss.or(...e)}_and(){let e=[this._term()];for(;this._matchOne(15);){let t=this._term();e.push(t)}return 1===e.length?e[0]:ss.and(...e)}_term(){if(this._matchOne(2)){let e=this._peek();switch(e.type){case 11:return this._advance(),sl.INSTANCE;case 12:return this._advance(),sh.INSTANCE;case 0:{this._advance();let e=this._expr();return this._consume(1,se),null==e?void 0:e.negate()}case 17:return this._advance(),sp.create(e.lexeme);default:throw this._errExpectedButGot("KEY | true | false | '(' expression ')'",e)}}return this._primary()}_primary(){let e=this._peek();switch(e.type){case 11:return this._advance(),ss.true();case 12:return this._advance(),ss.false();case 0:{this._advance();let e=this._expr();return this._consume(1,se),e}case 17:{let t=e.lexeme;if(this._advance(),this._matchOne(9)){let e=this._peek();if(!this._config.regexParsingWithErrorRecovery){let i;if(this._advance(),10!==e.type)throw this._errExpectedButGot("REGEX",e);let n=e.lexeme,r=n.lastIndexOf("/"),o=r===n.length-1?void 0:this._removeFlagsGY(n.substring(r+1));try{i=new RegExp(n.substring(1,r),o)}catch(t){throw this._errExpectedButGot("REGEX",e)}return sC.create(t,i)}switch(e.type){case 10:case 19:{let i;let n=[e.lexeme];this._advance();let r=this._peek(),o=0;for(let t=0;t=0){let o=i.slice(t+1,r),s="i"===i[r+1]?"i":"";try{n=new RegExp(o,s)}catch(t){throw this._errExpectedButGot("REGEX",e)}}}if(null===n)throw this._errExpectedButGot("REGEX",e);return sC.create(t,n)}default:throw this._errExpectedButGot("REGEX",this._peek())}}if(this._matchOne(14)){this._consume(13,o7);let e=this._value();return ss.notIn(t,e)}let i=this._peek().type;switch(i){case 3:{this._advance();let e=this._value();if(18===this._previous().type)return ss.equals(t,e);switch(e){case"true":return ss.has(t);case"false":return ss.not(t);default:return ss.equals(t,e)}}case 4:{this._advance();let e=this._value();if(18===this._previous().type)return ss.notEquals(t,e);switch(e){case"true":return ss.not(t);case"false":return ss.has(t);default:return ss.notEquals(t,e)}}case 5:return this._advance(),sv.create(t,this._value());case 6:return this._advance(),sb.create(t,this._value());case 7:return this._advance(),s_.create(t,this._value());case 8:return this._advance(),sE.create(t,this._value());case 13:return this._advance(),ss.in(t,this._value());default:return ss.has(t)}}case 20:throw this._parsingErrors.push({message:sn,offset:e.offset,lexeme:"",additionalInfo:sr}),so._parseError;default:throw this._errExpectedButGot(`true | false | KEY | KEY '=~' REGEX | KEY ('==' | '!=' | '<' | '<=' | '>' | '>=' | 'in' | 'not' 'in') value`,this._peek())}}_value(){let e=this._peek();switch(e.type){case 17:case 18:return this._advance(),e.lexeme;case 11:return this._advance(),"true";case 12:return this._advance(),"false";case 13:return this._advance(),"in";default:return""}}_removeFlagsGY(e){return e.replaceAll(this._flagsGYRe,"")}_previous(){return this._tokens[this._current-1]}_matchOne(e){return!!this._check(e)&&(this._advance(),!0)}_advance(){return!this._isAtEnd()&&this._current++,this._previous()}_consume(e,t){if(this._check(e))return this._advance();throw this._errExpectedButGot(t,this._peek())}_errExpectedButGot(e,t,i){let n=(0,rN.NC)("contextkey.parser.error.expectedButGot","Expected: {0}\nReceived: '{1}'.",e,o5.getLexeme(t)),r=t.offset,o=o5.getLexeme(t);return this._parsingErrors.push({message:n,offset:r,lexeme:o,additionalInfo:i}),so._parseError}_check(e){return this._peek().type===e}_peek(){return this._tokens[this._current]}_isAtEnd(){return 20===this._peek().type}}so._parseError=Error();class ss{static false(){return sl.INSTANCE}static true(){return sh.INSTANCE}static has(e){return su.create(e)}static equals(e,t){return sd.create(e,t)}static notEquals(e,t){return sg.create(e,t)}static regex(e,t){return sC.create(e,t)}static in(e,t){return sc.create(e,t)}static notIn(e,t){return sf.create(e,t)}static not(e){return sp.create(e)}static and(...e){return sT.create(e,null,!0)}static or(...e){return sR.create(e,null,!0)}static deserialize(e){if(null==e)return;let t=this._parser.parse(e);return t}}function sa(e,t){return e.cmp(t)}ss._parser=new so({regexParsingWithErrorRecovery:!1});class sl{constructor(){this.type=0}cmp(e){return this.type-e.type}equals(e){return e.type===this.type}substituteConstants(){return this}evaluate(e){return!1}serialize(){return"false"}keys(){return[]}negate(){return sh.INSTANCE}}sl.INSTANCE=new sl;class sh{constructor(){this.type=1}cmp(e){return this.type-e.type}equals(e){return e.type===this.type}substituteConstants(){return this}evaluate(e){return!0}serialize(){return"true"}keys(){return[]}negate(){return sl.INSTANCE}}sh.INSTANCE=new sh;class su{static create(e,t=null){let i=o4.get(e);return"boolean"==typeof i?i?sh.INSTANCE:sl.INSTANCE:new su(e,t)}constructor(e,t){this.key=e,this.negated=t,this.type=2}cmp(e){var t,i;return e.type!==this.type?this.type-e.type:(t=this.key,t<(i=e.key)?-1:t>i?1:0)}equals(e){return e.type===this.type&&this.key===e.key}substituteConstants(){let e=o4.get(this.key);return"boolean"==typeof e?e?sh.INSTANCE:sl.INSTANCE:this}evaluate(e){return!!e.getValue(this.key)}serialize(){return this.key}keys(){return[this.key]}negate(){return this.negated||(this.negated=sp.create(this.key,this)),this.negated}}class sd{static create(e,t,i=null){if("boolean"==typeof t)return t?su.create(e,i):sp.create(e,i);let n=o4.get(e);return"boolean"==typeof n?t===(n?"true":"false")?sh.INSTANCE:sl.INSTANCE:new sd(e,t,i)}constructor(e,t,i){this.key=e,this.value=t,this.negated=i,this.type=4}cmp(e){return e.type!==this.type?this.type-e.type:sO(this.key,this.value,e.key,e.value)}equals(e){return e.type===this.type&&this.key===e.key&&this.value===e.value}substituteConstants(){let e=o4.get(this.key);return"boolean"==typeof e?this.value===(e?"true":"false")?sh.INSTANCE:sl.INSTANCE:this}evaluate(e){return e.getValue(this.key)==this.value}serialize(){return`${this.key} == '${this.value}'`}keys(){return[this.key]}negate(){return this.negated||(this.negated=sg.create(this.key,this.value,this)),this.negated}}class sc{static create(e,t){return new sc(e,t)}constructor(e,t){this.key=e,this.valueKey=t,this.type=10,this.negated=null}cmp(e){return e.type!==this.type?this.type-e.type:sO(this.key,this.valueKey,e.key,e.valueKey)}equals(e){return e.type===this.type&&this.key===e.key&&this.valueKey===e.valueKey}substituteConstants(){return this}evaluate(e){let t=e.getValue(this.valueKey),i=e.getValue(this.key);return Array.isArray(t)?t.includes(i):"string"==typeof i&&"object"==typeof t&&null!==t&&o3.call(t,i)}serialize(){return`${this.key} in '${this.valueKey}'`}keys(){return[this.key,this.valueKey]}negate(){return this.negated||(this.negated=sf.create(this.key,this.valueKey)),this.negated}}class sf{static create(e,t){return new sf(e,t)}constructor(e,t){this.key=e,this.valueKey=t,this.type=11,this._negated=sc.create(e,t)}cmp(e){return e.type!==this.type?this.type-e.type:this._negated.cmp(e._negated)}equals(e){return e.type===this.type&&this._negated.equals(e._negated)}substituteConstants(){return this}evaluate(e){return!this._negated.evaluate(e)}serialize(){return`${this.key} not in '${this.valueKey}'`}keys(){return this._negated.keys()}negate(){return this._negated}}class sg{static create(e,t,i=null){if("boolean"==typeof t)return t?sp.create(e,i):su.create(e,i);let n=o4.get(e);return"boolean"==typeof n?t===(n?"true":"false")?sl.INSTANCE:sh.INSTANCE:new sg(e,t,i)}constructor(e,t,i){this.key=e,this.value=t,this.negated=i,this.type=5}cmp(e){return e.type!==this.type?this.type-e.type:sO(this.key,this.value,e.key,e.value)}equals(e){return e.type===this.type&&this.key===e.key&&this.value===e.value}substituteConstants(){let e=o4.get(this.key);return"boolean"==typeof e?this.value===(e?"true":"false")?sl.INSTANCE:sh.INSTANCE:this}evaluate(e){return e.getValue(this.key)!=this.value}serialize(){return`${this.key} != '${this.value}'`}keys(){return[this.key]}negate(){return this.negated||(this.negated=sd.create(this.key,this.value,this)),this.negated}}class sp{static create(e,t=null){let i=o4.get(e);return"boolean"==typeof i?i?sl.INSTANCE:sh.INSTANCE:new sp(e,t)}constructor(e,t){this.key=e,this.negated=t,this.type=3}cmp(e){var t,i;return e.type!==this.type?this.type-e.type:(t=this.key,t<(i=e.key)?-1:t>i?1:0)}equals(e){return e.type===this.type&&this.key===e.key}substituteConstants(){let e=o4.get(this.key);return"boolean"==typeof e?e?sl.INSTANCE:sh.INSTANCE:this}evaluate(e){return!e.getValue(this.key)}serialize(){return`!${this.key}`}keys(){return[this.key]}negate(){return this.negated||(this.negated=su.create(this.key,this)),this.negated}}function sm(e,t){if("string"==typeof e){let t=parseFloat(e);isNaN(t)||(e=t)}return"string"==typeof e||"number"==typeof e?t(e):sl.INSTANCE}class s_{static create(e,t,i=null){return sm(t,t=>new s_(e,t,i))}constructor(e,t,i){this.key=e,this.value=t,this.negated=i,this.type=12}cmp(e){return e.type!==this.type?this.type-e.type:sO(this.key,this.value,e.key,e.value)}equals(e){return e.type===this.type&&this.key===e.key&&this.value===e.value}substituteConstants(){return this}evaluate(e){return"string"!=typeof this.value&&parseFloat(e.getValue(this.key))>this.value}serialize(){return`${this.key} > ${this.value}`}keys(){return[this.key]}negate(){return this.negated||(this.negated=sb.create(this.key,this.value,this)),this.negated}}class sE{static create(e,t,i=null){return sm(t,t=>new sE(e,t,i))}constructor(e,t,i){this.key=e,this.value=t,this.negated=i,this.type=13}cmp(e){return e.type!==this.type?this.type-e.type:sO(this.key,this.value,e.key,e.value)}equals(e){return e.type===this.type&&this.key===e.key&&this.value===e.value}substituteConstants(){return this}evaluate(e){return"string"!=typeof this.value&&parseFloat(e.getValue(this.key))>=this.value}serialize(){return`${this.key} >= ${this.value}`}keys(){return[this.key]}negate(){return this.negated||(this.negated=sv.create(this.key,this.value,this)),this.negated}}class sv{static create(e,t,i=null){return sm(t,t=>new sv(e,t,i))}constructor(e,t,i){this.key=e,this.value=t,this.negated=i,this.type=14}cmp(e){return e.type!==this.type?this.type-e.type:sO(this.key,this.value,e.key,e.value)}equals(e){return e.type===this.type&&this.key===e.key&&this.value===e.value}substituteConstants(){return this}evaluate(e){return"string"!=typeof this.value&&parseFloat(e.getValue(this.key))new sb(e,t,i))}constructor(e,t,i){this.key=e,this.value=t,this.negated=i,this.type=15}cmp(e){return e.type!==this.type?this.type-e.type:sO(this.key,this.value,e.key,e.value)}equals(e){return e.type===this.type&&this.key===e.key&&this.value===e.value}substituteConstants(){return this}evaluate(e){return"string"!=typeof this.value&&parseFloat(e.getValue(this.key))<=this.value}serialize(){return`${this.key} <= ${this.value}`}keys(){return[this.key]}negate(){return this.negated||(this.negated=s_.create(this.key,this.value,this)),this.negated}}class sC{static create(e,t){return new sC(e,t)}constructor(e,t){this.key=e,this.regexp=t,this.type=7,this.negated=null}cmp(e){if(e.type!==this.type)return this.type-e.type;if(this.keye.key)return 1;let t=this.regexp?this.regexp.source:"",i=e.regexp?e.regexp.source:"";return ti?1:0}equals(e){if(e.type===this.type){let t=this.regexp?this.regexp.source:"",i=e.regexp?e.regexp.source:"";return this.key===e.key&&t===i}return!1}substituteConstants(){return this}evaluate(e){let t=e.getValue(this.key);return!!this.regexp&&this.regexp.test(t)}serialize(){let e=this.regexp?`/${this.regexp.source}/${this.regexp.flags}`:"/invalid/";return`${this.key} =~ ${e}`}keys(){return[this.key]}negate(){return this.negated||(this.negated=sS.create(this)),this.negated}}class sS{static create(e){return new sS(e)}constructor(e){this._actual=e,this.type=8}cmp(e){return e.type!==this.type?this.type-e.type:this._actual.cmp(e._actual)}equals(e){return e.type===this.type&&this._actual.equals(e._actual)}substituteConstants(){return this}evaluate(e){return!this._actual.evaluate(e)}serialize(){return`!(${this._actual.serialize()})`}keys(){return this._actual.keys()}negate(){return this._actual}}function sy(e){let t=null;for(let i=0,n=e.length;ie.expr.length)return 1;for(let t=0,i=this.expr.length;t1;){let e=n[n.length-1];if(9!==e.type)break;n.pop();let t=n.pop(),r=0===n.length,o=sR.create(e.expr.map(e=>sT.create([e,t],null,i)),null,r);o&&(n.push(o),n.sort(sa))}if(1===n.length)return n[0];if(i){for(let e=0;ee.serialize()).join(" && ")}keys(){let e=[];for(let t of this.expr)e.push(...t.keys());return e}negate(){if(!this.negated){let e=[];for(let t of this.expr)e.push(t.negate());this.negated=sR.create(e,this,!0)}return this.negated}}class sR{static create(e,t,i){return sR._normalizeArr(e,t,i)}constructor(e,t){this.expr=e,this.negated=t,this.type=9}cmp(e){if(e.type!==this.type)return this.type-e.type;if(this.expr.lengthe.expr.length)return 1;for(let t=0,i=this.expr.length;te.serialize()).join(" || ")}keys(){let e=[];for(let t of this.expr)e.push(...t.keys());return e}negate(){if(!this.negated){let e=[];for(let t of this.expr)e.push(t.negate());for(;e.length>1;){let t=e.shift(),i=e.shift(),n=[];for(let e of sI(t))for(let t of sI(i))n.push(sT.create([e,t],null,!1));e.unshift(sR.create(n,null,!1))}this.negated=sR.create(e,this,!0)}return this.negated}}class sA extends su{static all(){return sA._info.values()}constructor(e,t,i){super(e,null),this._defaultValue=t,"object"==typeof i?sA._info.push(Object.assign(Object.assign({},i),{key:e})):!0!==i&&sA._info.push({key:e,description:i,type:null!=t?typeof t:void 0})}bindTo(e){return e.createKey(this.key,this._defaultValue)}getValue(e){return e.getContextKeyValue(this.key)}toNegated(){return this.negate()}isEqualTo(e){return sd.create(this.key,e)}}sA._info=[];let sN=oG("contextKeyService");function sO(e,t,i,n){return ei?1:tn?1:0}function sL(e,t){let i=0,n=0;for(;ithis._onDiffUpdated())),this._options.followsCaret&&this._register(this._editor.getModifiedEditor().onDidChangeCursorPosition(e=>{this.ignoreSelectionChange||(this._updateAccessibilityState(e.position.lineNumber),this.nextIdx=-1)})),this._init()}_init(){let e=this._editor.getLineChanges();if(!e)return}_onDiffUpdated(){this._init(),this._compute(this._editor.getLineChanges()),this.revealFirst&&null!==this._editor.getLineChanges()&&(this.revealFirst=!1,this.nextIdx=-1,this.next(1))}_compute(e){this.ranges=[],e&&e.forEach(e=>{!this._options.ignoreCharChanges&&e.charChanges?e.charChanges.forEach(e=>{this.ranges.push({rhs:!0,range:new rv(e.modifiedStartLineNumber,e.modifiedStartColumn,e.modifiedEndLineNumber,e.modifiedEndColumn)})}):0===e.modifiedEndLineNumber?this.ranges.push({rhs:!0,range:new rv(e.modifiedStartLineNumber,1,e.modifiedStartLineNumber+1,1)}):this.ranges.push({rhs:!0,range:new rv(e.modifiedStartLineNumber,1,e.modifiedEndLineNumber+1,1)})}),this.ranges.sort((e,t)=>rv.compareRangesUsingStarts(e.range,t.range)),this._onDidUpdate.fire(this)}_initIdx(e){let t=!1,i=this._editor.getPosition();if(!i){this.nextIdx=0;return}for(let n=0,r=this.ranges.length;n=this.ranges.length&&(this.nextIdx=0)):(this.nextIdx-=1,this.nextIdx<0&&(this.nextIdx=this.ranges.length-1));let i=this.ranges[this.nextIdx];this.ignoreSelectionChange=!0;try{let e=i.range.getStartPosition();this._editor.setPosition(e),this._editor.revealRangeInCenter(i.range,t),this._updateAccessibilityState(e.lineNumber,!0)}finally{this.ignoreSelectionChange=!1}}_updateAccessibilityState(e,t){var i;let n=null===(i=this._editor.getModel())||void 0===i?void 0:i.modified;if(!n)return;let r=n.getLineDecorations(e).find(e=>"line-insert"===e.options.className);if(r)this._audioCueService.playAudioCue(oJ.diffLineModified,!0);else{if(!t)return;this._audioCueService.playAudioCue(oJ.diffLineDeleted,!0)}let o=this._codeEditorService.getActiveCodeEditor();t&&o&&r&&this._accessibilityService.isScreenReaderOptimized()&&(o.setSelection({startLineNumber:e,startColumn:0,endLineNumber:e,endColumn:Number.MAX_VALUE}),o.writeScreenReaderContent("diff-navigation"))}canNavigate(){return this.ranges&&this.ranges.length>0}next(e=0){this.canNavigateNext()&&this._move(!0,e)}previous(e=0){this.canNavigatePrevious()&&this._move(!1,e)}canNavigateNext(){return this.canNavigateLoop()||this.nextIdx=0;a--)(r=e[a])&&(s=(o<3?r(s):o>3?r(t,i,s):r(t,i))||s);return o>3&&s&&Object.defineProperty(t,i,s),s}([sx(2,oX),sx(3,oj),sx(4,sw)],sk);let sP={ICodeEditor:"vs.editor.ICodeEditor",IDiffEditor:"vs.editor.IDiffEditor"};(eg=t$||(t$={}))[eg.Left=1]="Left",eg[eg.Center=2]="Center",eg[eg.Right=4]="Right",eg[eg.Full=7]="Full",(ep=tq||(tq={}))[ep.Left=1]="Left",ep[ep.Right=2]="Right",(em=tX||(tX={}))[em.Inline=1]="Inline",em[em.Gutter=2]="Gutter",(e_=tZ||(tZ={}))[e_.Both=0]="Both",e_[e_.Right=1]="Right",e_[e_.Left=2]="Left",e_[e_.None=3]="None";class sF{get originalIndentSize(){return this._indentSizeIsTabSize?"tabSize":this.indentSize}constructor(e){this._textModelResolvedOptionsBrand=void 0,this.tabSize=Math.max(1,0|e.tabSize),"tabSize"===e.indentSize?(this.indentSize=this.tabSize,this._indentSizeIsTabSize=!0):(this.indentSize=Math.max(1,0|e.indentSize),this._indentSizeIsTabSize=!1),this.insertSpaces=!!e.insertSpaces,this.defaultEOL=0|e.defaultEOL,this.trimAutoWhitespace=!!e.trimAutoWhitespace,this.bracketPairColorizationOptions=e.bracketPairColorizationOptions}equals(e){return this.tabSize===e.tabSize&&this._indentSizeIsTabSize===e._indentSizeIsTabSize&&this.indentSize===e.indentSize&&this.insertSpaces===e.insertSpaces&&this.defaultEOL===e.defaultEOL&&this.trimAutoWhitespace===e.trimAutoWhitespace&&(0,oq.fS)(this.bracketPairColorizationOptions,e.bracketPairColorizationOptions)}createChangeEvent(e){return{tabSize:this.tabSize!==e.tabSize,indentSize:this.indentSize!==e.indentSize,insertSpaces:this.insertSpaces!==e.insertSpaces,trimAutoWhitespace:this.trimAutoWhitespace!==e.trimAutoWhitespace}}}class sB{constructor(e,t){this._findMatchBrand=void 0,this.range=e,this.matches=t}}class sU{constructor(e,t,i,n,r,o){this.identifier=e,this.range=t,this.text=i,this.forceMoveMarkers=n,this.isAutoWhitespaceEdit=r,this._isTracked=o}}class sH{constructor(e,t,i){this.regex=e,this.wordSeparators=t,this.simpleSearch=i}}class sV{constructor(e,t,i){this.reverseEdits=e,this.changes=t,this.trimAutoWhitespaceLineNumbers=i}}var sW=i(270);(eE=tQ||(tQ={}))[eE.None=0]="None",eE[eE.Indent=1]="Indent",eE[eE.IndentOutdent=2]="IndentOutdent",eE[eE.Outdent=3]="Outdent";class sG{constructor(e){if(this._neutralCharacter=null,this._neutralCharacterSearched=!1,this.open=e.open,this.close=e.close,this._inString=!0,this._inComment=!0,this._inRegEx=!0,Array.isArray(e.notIn))for(let t=0,i=e.notIn.length;t0&&e.getLanguageId(s-1)===r;)s--;return new sY(e,r,s,o+1,e.getStartOffset(s),e.getEndOffset(o))}class sY{constructor(e,t,i,n,r,o){this._scopedLineTokensBrand=void 0,this._actual=e,this.languageId=t,this._firstTokenIndex=i,this._lastTokenIndex=n,this.firstCharOffset=r,this._lastCharOffset=o}getLineContent(){let e=this._actual.getLineContent();return e.substring(this.firstCharOffset,this._lastCharOffset)}getActualLineContentBefore(e){let t=this._actual.getLineContent();return t.substring(0,this.firstCharOffset+e)}getTokenCount(){return this._lastTokenIndex-this._firstTokenIndex}findTokenIndexAtOffset(e){return this._actual.findTokenIndexAtOffset(e+this.firstCharOffset)-this._firstTokenIndex}getStandardTokenType(e){return this._actual.getStandardTokenType(e+this._firstTokenIndex)}}function s$(e){return(3&e)!=0}class sq{constructor(e){if(e.autoClosingPairs?this._autoClosingPairs=e.autoClosingPairs.map(e=>new sG(e)):e.brackets?this._autoClosingPairs=e.brackets.map(e=>new sG({open:e[0],close:e[1]})):this._autoClosingPairs=[],e.__electricCharacterSupport&&e.__electricCharacterSupport.docComment){let t=e.__electricCharacterSupport.docComment;this._autoClosingPairs.push(new sG({open:t.open,close:t.close||""}))}this._autoCloseBeforeForQuotes="string"==typeof e.autoCloseBefore?e.autoCloseBefore:sq.DEFAULT_AUTOCLOSE_BEFORE_LANGUAGE_DEFINED_QUOTES,this._autoCloseBeforeForBrackets="string"==typeof e.autoCloseBefore?e.autoCloseBefore:sq.DEFAULT_AUTOCLOSE_BEFORE_LANGUAGE_DEFINED_BRACKETS,this._surroundingPairs=e.surroundingPairs||this._autoClosingPairs}getAutoClosingPairs(){return this._autoClosingPairs}getAutoCloseBeforeSet(e){return e?this._autoCloseBeforeForQuotes:this._autoCloseBeforeForBrackets}getSurroundingPairs(){return this._surroundingPairs}}sq.DEFAULT_AUTOCLOSE_BEFORE_LANGUAGE_DEFINED_QUOTES=";:.,=}])> \n ",sq.DEFAULT_AUTOCLOSE_BEFORE_LANGUAGE_DEFINED_BRACKETS="'\"`;:.,=}])> \n ";var sX=i(9488),sZ=i(21876).Buffer;let sQ=void 0!==sZ;new rF(()=>new Uint8Array(256));class sJ{static wrap(e){return sQ&&!sZ.isBuffer(e)&&(e=sZ.from(e.buffer,e.byteOffset,e.byteLength)),new sJ(e)}constructor(e){this.buffer=e,this.byteLength=this.buffer.byteLength}toString(){return sQ?this.buffer.toString():(r||(r=new TextDecoder),r.decode(this.buffer))}}function s0(e,t){return 16777216*e[t]+65536*e[t+1]+256*e[t+2]+e[t+3]}function s1(e,t,i){e[i+3]=t,t>>>=8,e[i+2]=t,t>>>=8,e[i+1]=t,t>>>=8,e[i]=t}function s2(){return o||(o=new TextDecoder("UTF-16LE")),o}function s5(){return a||(a=nz.r()?s2():(s||(s=new TextDecoder("UTF-16BE")),s)),a}class s4{constructor(e){this._capacity=0|e,this._buffer=new Uint16Array(this._capacity),this._completedStrings=null,this._bufferLength=0}reset(){this._completedStrings=null,this._bufferLength=0}build(){return null!==this._completedStrings?(this._flushBuffer(),this._completedStrings.join("")):this._buildBuffer()}_buildBuffer(){if(0===this._bufferLength)return"";let e=new Uint16Array(this._buffer.buffer,0,this._bufferLength);return s5().decode(e)}_flushBuffer(){let e=this._buildBuffer();this._bufferLength=0,null===this._completedStrings?this._completedStrings=[e]:this._completedStrings[this._completedStrings.length]=e}appendCharCode(e){let t=this._capacity-this._bufferLength;t<=1&&(0===t||r6(e))&&this._flushBuffer(),this._buffer[this._bufferLength++]=e}appendASCIICharCode(e){this._bufferLength===this._capacity&&this._flushBuffer(),this._buffer[this._bufferLength++]=e}appendString(e){let t=e.length;if(this._bufferLength+t>=this._capacity){this._flushBuffer(),this._completedStrings[this._completedStrings.length]=e;return}for(let i=0;i[e[0].toLowerCase(),e[1].toLowerCase()]);let i=[];for(let e=0;e{let[i,n]=e,[r,o]=t;return i===r||i===o||n===r||n===o},r=(e,n)=>{let r=Math.min(e,n),o=Math.max(e,n);for(let e=0;e0&&o.push({open:r,close:s})}return o}(t);for(let t of(this.brackets=i.map((t,n)=>new s3(e,n,t.open,t.close,function(e,t,i,n){let r=[];r=(r=r.concat(e)).concat(t);for(let e=0,t=r.length;e=0&&n.push(t);for(let t of o.close)t.indexOf(e)>=0&&n.push(t)}}function s8(e,t){return e.length-t.length}function s7(e){if(e.length<=1)return e;let t=[],i=new Set;for(let n of e)i.has(n)||(t.push(n),i.add(n));return t}function ae(e){let t=/^[\w ]+$/.test(e);return e=rV(e),t?`\\b${e}\\b`:e}function at(e){let t=`(${e.map(ae).join(")|(")})`;return rG(t,!0)}let ai=(v=null,b=null,function(e){return v!==e&&(b=function(e){let t=new Uint16Array(e.length),i=0;for(let n=e.length-1;n>=0;n--)t[i++]=e.charCodeAt(n);return s5().decode(t)}(v=e)),b});class an{static _findPrevBracketInText(e,t,i,n){let r=i.match(e);if(!r)return null;let o=i.length-(r.index||0),s=r[0].length,a=n+o;return new rv(t,a-s+1,t,a+1)}static findPrevBracketInRange(e,t,i,n,r){let o=ai(i),s=o.substring(i.length-r,i.length-n);return this._findPrevBracketInText(e,t,s,n)}static findNextBracketInText(e,t,i,n){let r=i.match(e);if(!r)return null;let o=r.index||0,s=r[0].length;if(0===s)return null;let a=n+o;return new rv(t,a+1,t,a+1+s)}static findNextBracketInRange(e,t,i,n,r){let o=i.substring(n,r);return this.findNextBracketInText(e,t,o,n)}}class ar{constructor(e){this._richEditBrackets=e}getElectricCharacters(){let e=[];if(this._richEditBrackets)for(let t of this._richEditBrackets.brackets)for(let i of t.close){let t=i.charAt(i.length-1);e.push(t)}return(0,sX.EB)(e)}onElectricCharacter(e,t,i){if(!this._richEditBrackets||0===this._richEditBrackets.brackets.length)return null;let n=t.findTokenIndexAtOffset(i-1);if(s$(t.getStandardTokenType(n)))return null;let r=this._richEditBrackets.reversedRegex,o=t.getLineContent().substring(0,i-1)+e,s=an.findPrevBracketInRange(r,1,o,0,o.length);if(!s)return null;let a=o.substring(s.startColumn-1,s.endColumn-1).toLowerCase(),l=this._richEditBrackets.textIsOpenBracket[a];if(l)return null;let h=t.getActualLineContentBefore(s.startColumn-1);return/^\s*$/.test(h)?{matchOpenBracket:a}:null}}function ao(e){return e.global&&(e.lastIndex=0),!0}class as{constructor(e){this._indentationRules=e}shouldIncrease(e){return!!(this._indentationRules&&this._indentationRules.increaseIndentPattern&&ao(this._indentationRules.increaseIndentPattern)&&this._indentationRules.increaseIndentPattern.test(e))}shouldDecrease(e){return!!(this._indentationRules&&this._indentationRules.decreaseIndentPattern&&ao(this._indentationRules.decreaseIndentPattern)&&this._indentationRules.decreaseIndentPattern.test(e))}shouldIndentNextLine(e){return!!(this._indentationRules&&this._indentationRules.indentNextLinePattern&&ao(this._indentationRules.indentNextLinePattern)&&this._indentationRules.indentNextLinePattern.test(e))}shouldIgnore(e){return!!(this._indentationRules&&this._indentationRules.unIndentedLinePattern&&ao(this._indentationRules.unIndentedLinePattern)&&this._indentationRules.unIndentedLinePattern.test(e))}getIndentMetadata(e){let t=0;return this.shouldIncrease(e)&&(t+=1),this.shouldDecrease(e)&&(t+=2),this.shouldIndentNextLine(e)&&(t+=4),this.shouldIgnore(e)&&(t+=8),t}}class aa{constructor(e){(e=e||{}).brackets=e.brackets||[["(",")"],["{","}"],["[","]"]],this._brackets=[],e.brackets.forEach(e=>{let t=aa._createOpenBracketRegExp(e[0]),i=aa._createCloseBracketRegExp(e[1]);t&&i&&this._brackets.push({open:e[0],openRegExp:t,close:e[1],closeRegExp:i})}),this._regExpRules=e.onEnterRules||[]}onEnter(e,t,i,n){if(e>=3)for(let e=0,r=this._regExpRules.length;e!e.reg||(e.reg.lastIndex=0,e.reg.test(e.text)));if(o)return r.action}if(e>=2&&i.length>0&&n.length>0)for(let e=0,t=this._brackets.length;e=2&&i.length>0)for(let e=0,t=this._brackets.length;e0&&"#"===e.charAt(e.length-1)?e.substring(0,e.length-1):e]=t,this._onDidChangeSchema.fire(e)}notifySchemaChanged(e){this._onDidChangeSchema.fire(e)}};am.add(aE.JSONContribution,av);let ab={Configuration:"base.contributions.configuration"},aC={properties:{},patternProperties:{}},aS={properties:{},patternProperties:{}},ay={properties:{},patternProperties:{}},aT={properties:{},patternProperties:{}},aR={properties:{},patternProperties:{}},aA={properties:{},patternProperties:{}},aN="vscode://schemas/settings/resourceLanguage",aO=am.as(aE.JSONContribution),aL="\\[([^\\]]+)\\]",aI=RegExp(aL,"g"),aw=`^(${aL})+$`,aD=new RegExp(aw);function ax(e){let t=[];if(aD.test(e)){let i=aI.exec(e);for(;null==i?void 0:i.length;){let n=i[1].trim();n&&t.push(n),i=aI.exec(e)}}return(0,sX.EB)(t)}let aM=new class{constructor(){this.overrideIdentifiers=new Set,this._onDidSchemaChange=new ny,this._onDidUpdateConfiguration=new ny,this.configurationDefaultsOverrides=new Map,this.defaultLanguageConfigurationOverridesNode={id:"defaultOverrides",title:rN.NC("defaultLanguageConfigurationOverrides.title","Default Language Configuration Overrides"),properties:{}},this.configurationContributors=[this.defaultLanguageConfigurationOverridesNode],this.resourceLanguageSettingsSchema={properties:{},patternProperties:{},additionalProperties:!0,allowTrailingCommas:!0,allowComments:!0},this.configurationProperties={},this.policyConfigurations=new Map,this.excludedConfigurationProperties={},aO.registerSchema(aN,this.resourceLanguageSettingsSchema),this.registerOverridePropertyPatternKey()}registerConfiguration(e,t=!0){this.registerConfigurations([e],t)}registerConfigurations(e,t=!0){let i=new Set;this.doRegisterConfigurations(e,t,i),aO.registerSchema(aN,this.resourceLanguageSettingsSchema),this._onDidSchemaChange.fire(),this._onDidUpdateConfiguration.fire({properties:i})}registerDefaultConfigurations(e){let t=new Set;this.doRegisterDefaultConfigurations(e,t),this._onDidSchemaChange.fire(),this._onDidUpdateConfiguration.fire({properties:t,defaultsOverrides:!0})}doRegisterDefaultConfigurations(e,t){var i;let n=[];for(let{overrides:r,source:o}of e)for(let e in r)if(t.add(e),aD.test(e)){let t=this.configurationDefaultsOverrides.get(e),s=null!==(i=null==t?void 0:t.valuesSources)&&void 0!==i?i:new Map;if(o)for(let t of Object.keys(r[e]))s.set(t,o);let a=Object.assign(Object.assign({},(null==t?void 0:t.value)||{}),r[e]);this.configurationDefaultsOverrides.set(e,{source:o,value:a,valuesSources:s});let l=e.replace(/[\[\]]/g,""),h={type:"object",default:a,description:rN.NC("defaultLanguageConfiguration.description","Configure settings to be overridden for the {0} language.",l),$ref:aN,defaultDefaultValue:a,source:rC.HD(o)?void 0:o,defaultValueSource:o};n.push(...ax(e)),this.configurationProperties[e]=h,this.defaultLanguageConfigurationOverridesNode.properties[e]=h}else{this.configurationDefaultsOverrides.set(e,{value:r[e],source:o});let t=this.configurationProperties[e];t&&(this.updatePropertyDefaultValue(e,t),this.updateSchema(e,t))}this.doRegisterOverrideIdentifiers(n)}registerOverrideIdentifiers(e){this.doRegisterOverrideIdentifiers(e),this._onDidSchemaChange.fire()}doRegisterOverrideIdentifiers(e){for(let t of e)this.overrideIdentifiers.add(t);this.updateOverridePropertyPatternKey()}doRegisterConfigurations(e,t,i){e.forEach(e=>{this.validateAndRegisterProperties(e,t,e.extensionInfo,e.restrictedProperties,void 0,i),this.configurationContributors.push(e),this.registerJSONConfiguration(e)})}validateAndRegisterProperties(e,t=!0,i,n,r=3,o){var s;r=rC.Jp(e.scope)?r:e.scope;let a=e.properties;if(a)for(let e in a){let l=a[e];if(t&&function(e,t){var i,n,r,o;return e.trim()?aD.test(e)?rN.NC("config.property.languageDefault","Cannot register '{0}'. This matches property pattern '\\\\[.*\\\\]$' for describing language specific editor settings. Use 'configurationDefaults' contribution.",e):void 0!==aM.getConfigurationProperties()[e]?rN.NC("config.property.duplicate","Cannot register '{0}'. This property is already registered.",e):(null===(i=t.policy)||void 0===i?void 0:i.name)&&void 0!==aM.getPolicyConfigurations().get(null===(n=t.policy)||void 0===n?void 0:n.name)?rN.NC("config.policy.duplicate","Cannot register '{0}'. The associated policy {1} is already registered with {2}.",e,null===(r=t.policy)||void 0===r?void 0:r.name,aM.getPolicyConfigurations().get(null===(o=t.policy)||void 0===o?void 0:o.name)):null:rN.NC("config.property.empty","Cannot register an empty property")}(e,l)){delete a[e];continue}if(l.source=i,l.defaultDefaultValue=a[e].default,this.updatePropertyDefaultValue(e,l),aD.test(e)?l.scope=void 0:(l.scope=rC.Jp(l.scope)?r:l.scope,l.restricted=rC.Jp(l.restricted)?!!(null==n?void 0:n.includes(e)):l.restricted),a[e].hasOwnProperty("included")&&!a[e].included){this.excludedConfigurationProperties[e]=a[e],delete a[e];continue}this.configurationProperties[e]=a[e],(null===(s=a[e].policy)||void 0===s?void 0:s.name)&&this.policyConfigurations.set(a[e].policy.name,e),!a[e].deprecationMessage&&a[e].markdownDeprecationMessage&&(a[e].deprecationMessage=a[e].markdownDeprecationMessage),o.add(e)}let l=e.allOf;if(l)for(let e of l)this.validateAndRegisterProperties(e,t,i,n,r,o)}getConfigurationProperties(){return this.configurationProperties}getPolicyConfigurations(){return this.policyConfigurations}registerJSONConfiguration(e){let t=e=>{let i=e.properties;if(i)for(let e in i)this.updateSchema(e,i[e]);let n=e.allOf;null==n||n.forEach(t)};t(e)}updateSchema(e,t){switch(aC.properties[e]=t,t.scope){case 1:aS.properties[e]=t;break;case 2:ay.properties[e]=t;break;case 6:aT.properties[e]=t;break;case 3:aR.properties[e]=t;break;case 4:aA.properties[e]=t;break;case 5:aA.properties[e]=t,this.resourceLanguageSettingsSchema.properties[e]=t}}updateOverridePropertyPatternKey(){for(let e of this.overrideIdentifiers.values()){let t=`[${e}]`,i={type:"object",description:rN.NC("overrideSettings.defaultDescription","Configure editor settings to be overridden for a language."),errorMessage:rN.NC("overrideSettings.errorMessage","This setting does not support per-language configuration."),$ref:aN};this.updatePropertyDefaultValue(t,i),aC.properties[t]=i,aS.properties[t]=i,ay.properties[t]=i,aT.properties[t]=i,aR.properties[t]=i,aA.properties[t]=i}}registerOverridePropertyPatternKey(){let e={type:"object",description:rN.NC("overrideSettings.defaultDescription","Configure editor settings to be overridden for a language."),errorMessage:rN.NC("overrideSettings.errorMessage","This setting does not support per-language configuration."),$ref:aN};aC.patternProperties[aw]=e,aS.patternProperties[aw]=e,ay.patternProperties[aw]=e,aT.patternProperties[aw]=e,aR.patternProperties[aw]=e,aA.patternProperties[aw]=e,this._onDidSchemaChange.fire()}updatePropertyDefaultValue(e,t){let i=this.configurationDefaultsOverrides.get(e),n=null==i?void 0:i.value,r=null==i?void 0:i.source;rC.o8(n)&&(n=t.defaultDefaultValue,r=void 0),rC.o8(n)&&(n=function(e){let t=Array.isArray(e)?e[0]:e;switch(t){case"boolean":return!1;case"integer":case"number":return 0;case"string":return"";case"array":return[];case"object":return{};default:return null}}(t.type)),t.default=n,t.defaultValueSource=r}};am.add(ab.Configuration,aM);let ak=new class{constructor(){this._onDidChangeLanguages=new ny,this.onDidChangeLanguages=this._onDidChangeLanguages.event,this._languages=[]}registerLanguage(e){return this._languages.push(e),this._onDidChangeLanguages.fire(void 0),{dispose:()=>{for(let t=0,i=this._languages.length;t{let t=new Set;return{info:new aH(this,e,t),closing:t}}),r=new rP(e=>{let t=new Set,i=new Set;return{info:new aV(this,e,t,i),opening:t,openingColorized:i}});for(let[e,t]of i){let i=n.get(e),o=r.get(t);i.closing.add(o.info),o.opening.add(i.info)}let o=t.colorizedBracketPairs?aB(t.colorizedBracketPairs):i.filter(e=>!("<"===e[0]&&">"===e[1]));for(let[e,t]of o){let i=n.get(e),o=r.get(t);i.closing.add(o.info),o.openingColorized.add(i.info),o.opening.add(i.info)}this._openingBrackets=new Map([...n.cachedValues].map(([e,t])=>[e,t.info])),this._closingBrackets=new Map([...r.cachedValues].map(([e,t])=>[e,t.info]))}get openingBrackets(){return[...this._openingBrackets.values()]}get closingBrackets(){return[...this._closingBrackets.values()]}getOpeningBracketInfo(e){return this._openingBrackets.get(e)}getClosingBracketInfo(e){return this._closingBrackets.get(e)}getBracketInfo(e){return this.getOpeningBracketInfo(e)||this.getClosingBracketInfo(e)}}function aB(e){return e.filter(([e,t])=>""!==e&&""!==t)}class aU{constructor(e,t){this.config=e,this.bracketText=t}get languageId(){return this.config.languageId}}class aH extends aU{constructor(e,t,i){super(e,t),this.openedBrackets=i,this.isOpeningBracket=!0}}class aV extends aU{constructor(e,t,i,n){super(e,t),this.openingBrackets=i,this.openingColorizedBrackets=n,this.isOpeningBracket=!1}closes(e){return e.config===this.config&&this.openingBrackets.has(e)}closesColorized(e){return e.config===this.config&&this.openingColorizedBrackets.has(e)}getOpeningBrackets(){return[...this.openingBrackets]}}var aW=function(e,t){return function(i,n){t(i,n,e)}};class aG{constructor(e){this.languageId=e}affects(e){return!this.languageId||this.languageId===e}}let aj=oG("languageConfigurationService"),az=class extends nc{constructor(e,t){super(),this.configurationService=e,this.languageService=t,this._registry=this._register(new a0),this.onDidChangeEmitter=this._register(new ny),this.onDidChange=this.onDidChangeEmitter.event,this.configurations=new Map;let i=new Set(Object.values(aK));this._register(this.configurationService.onDidChangeConfiguration(e=>{let t=e.change.keys.some(e=>i.has(e)),n=e.change.overrides.filter(([e,t])=>t.some(e=>i.has(e))).map(([e])=>e);if(t)this.configurations.clear(),this.onDidChangeEmitter.fire(new aG(void 0));else for(let e of n)this.languageService.isRegisteredLanguageId(e)&&(this.configurations.delete(e),this.onDidChangeEmitter.fire(new aG(e)))})),this._register(this._registry.onDidChange(e=>{this.configurations.delete(e.languageId),this.onDidChangeEmitter.fire(new aG(e.languageId))}))}register(e,t,i){return this._registry.register(e,t,i)}getLanguageConfiguration(e){let t=this.configurations.get(e);return t||(t=function(e,t,i,n){let r=t.getLanguageConfiguration(e);if(!r){if(!n.isRegisteredLanguageId(e))return new a1(e,{});r=new a1(e,{})}let o=function(e,t){let i=t.getValue(aK.brackets,{overrideIdentifier:e}),n=t.getValue(aK.colorizedBracketPairs,{overrideIdentifier:e});return{brackets:aY(i),colorizedBracketPairs:aY(n)}}(r.languageId,i),s=aZ([r.underlyingConfig,o]),a=new a1(r.languageId,s);return a}(e,this._registry,this.configurationService,this.languageService),this.configurations.set(e,t)),t}};az=function(e,t,i,n){var r,o=arguments.length,s=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(s=(o<3?r(s):o>3?r(t,i,s):r(t,i))||s);return o>3&&s&&Object.defineProperty(t,i,s),s}([aW(0,al),aW(1,ac)],az);let aK={brackets:"editor.language.brackets",colorizedBracketPairs:"editor.language.colorizedBracketPairs"};function aY(e){if(Array.isArray(e))return e.map(e=>{if(Array.isArray(e)&&2===e.length)return[e[0],e[1]]}).filter(e=>!!e)}function a$(e,t,i){let n=e.getLineContent(t),r=rY(n);return r.length>i-1&&(r=r.substring(0,i-1)),r}function aq(e,t,i){e.tokenization.forceTokenization(t);let n=e.tokenization.getLineTokens(t),r=void 0===i?e.getLineMaxColumn(t)-1:i-1;return sK(n,r)}class aX{constructor(e){this.languageId=e,this._resolved=null,this._entries=[],this._order=0,this._resolved=null}register(e,t){let i=new aQ(e,t,++this._order);return this._entries.push(i),this._resolved=null,nu(()=>{for(let e=0;ee.configuration)))}}function aZ(e){let t={comments:void 0,brackets:void 0,wordPattern:void 0,indentationRules:void 0,onEnterRules:void 0,autoClosingPairs:void 0,surroundingPairs:void 0,autoCloseBefore:void 0,folding:void 0,colorizedBracketPairs:void 0,__electricCharacterSupport:void 0};for(let i of e)t={comments:i.comments||t.comments,brackets:i.brackets||t.brackets,wordPattern:i.wordPattern||t.wordPattern,indentationRules:i.indentationRules||t.indentationRules,onEnterRules:i.onEnterRules||t.onEnterRules,autoClosingPairs:i.autoClosingPairs||t.autoClosingPairs,surroundingPairs:i.surroundingPairs||t.surroundingPairs,autoCloseBefore:i.autoCloseBefore||t.autoCloseBefore,folding:i.folding||t.folding,colorizedBracketPairs:i.colorizedBracketPairs||t.colorizedBracketPairs,__electricCharacterSupport:i.__electricCharacterSupport||t.__electricCharacterSupport};return t}class aQ{constructor(e,t,i){this.configuration=e,this.priority=t,this.order=i}static cmp(e,t){return e.priority===t.priority?e.order-t.order:e.priority-t.priority}}class aJ{constructor(e){this.languageId=e}}class a0 extends nc{constructor(){super(),this._entries=new Map,this._onDidChange=this._register(new ny),this.onDidChange=this._onDidChange.event,this._register(this.register(aP,{brackets:[["(",")"],["[","]"],["{","}"]],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"`",close:"`"}],colorizedBracketPairs:[],folding:{offSide:!0}},0))}register(e,t,i=0){let n=this._entries.get(e);n||(n=new aX(e),this._entries.set(e,n));let r=n.register(t,i);return this._onDidChange.fire(new aJ(e)),nu(()=>{r.dispose(),this._onDidChange.fire(new aJ(e))})}getLanguageConfiguration(e){let t=this._entries.get(e);return(null==t?void 0:t.getResolvedConfiguration())||null}}class a1{constructor(e,t){this.languageId=e,this.underlyingConfig=t,this._brackets=null,this._electricCharacter=null,this._onEnterSupport=this.underlyingConfig.brackets||this.underlyingConfig.indentationRules||this.underlyingConfig.onEnterRules?new aa(this.underlyingConfig):null,this.comments=a1._handleComments(this.underlyingConfig),this.characterPair=new sq(this.underlyingConfig),this.wordDefinition=this.underlyingConfig.wordPattern||sW.Af,this.indentationRules=this.underlyingConfig.indentationRules,this.underlyingConfig.indentationRules?this.indentRulesSupport=new as(this.underlyingConfig.indentationRules):this.indentRulesSupport=null,this.foldingRules=this.underlyingConfig.folding||{},this.bracketsNew=new aF(e,this.underlyingConfig)}getWordDefinition(){return(0,sW.eq)(this.wordDefinition)}get brackets(){return!this._brackets&&this.underlyingConfig.brackets&&(this._brackets=new s6(this.languageId,this.underlyingConfig.brackets)),this._brackets}get electricCharacter(){return this._electricCharacter||(this._electricCharacter=new ar(this.brackets)),this._electricCharacter}onEnter(e,t,i,n){return this._onEnterSupport?this._onEnterSupport.onEnter(e,t,i,n):null}getAutoClosingPairs(){return new sj(this.characterPair.getAutoClosingPairs())}getAutoCloseBeforeSet(e){return this.characterPair.getAutoCloseBeforeSet(e)}getSurroundingPairs(){return this.characterPair.getSurroundingPairs()}static _handleComments(e){let t=e.comments;if(!t)return null;let i={};if(t.lineComment&&(i.lineCommentToken=t.lineComment),t.blockComment){let[e,n]=t.blockComment;i.blockCommentStartToken=e,i.blockCommentEndToken=n}return i}}ap(aj,az,1);let a2=new class{clone(){return this}equals(e){return this===e}};function a5(e,t){return new rL([new rO(0,"",e)],t)}function a4(e,t){let i=new Uint32Array(2);return i[0]=0,i[1]=(e<<0|33587200)>>>0,new rI(i,null===t?a2:t)}let a3=oG("modelService"),a6=Symbol("MicrotaskDelay");var a9=function(e,t,i,n){return new(i||(i=Promise))(function(r,o){function s(e){try{l(n.next(e))}catch(e){o(e)}}function a(e){try{l(n.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?r(e.value):((t=e.value)instanceof i?t:new i(function(e){e(t)})).then(s,a)}l((n=n.apply(e,t||[])).next())})},a8=function(e){if(!Symbol.asyncIterator)throw TypeError("Symbol.asyncIterator is not defined.");var t,i=e[Symbol.asyncIterator];return i?i.call(e):(e="function"==typeof __values?__values(e):e[Symbol.iterator](),t={},n("next"),n("throw"),n("return"),t[Symbol.asyncIterator]=function(){return this},t);function n(i){t[i]=e[i]&&function(t){return new Promise(function(n,r){!function(e,t,i,n){Promise.resolve(n).then(function(t){e({value:t,done:i})},t)}(n,r,(t=e[i](t)).done,t.value)})}}};function a7(e){return!!e&&"function"==typeof e.then}function le(e){let t=new nx,i=e(t.token),n=new Promise((e,n)=>{let r=t.token.onCancellationRequested(()=>{r.dispose(),t.dispose(),n(new i6)});Promise.resolve(i).then(i=>{r.dispose(),t.dispose(),e(i)},e=>{r.dispose(),t.dispose(),n(e)})});return new class{cancel(){t.cancel()}then(e,t){return n.then(e,t)}catch(e){return this.then(void 0,e)}finally(e){return n.finally(e)}}}class lt{constructor(){this.isDisposed=!1,this.activePromise=null,this.queuedPromise=null,this.queuedPromiseFactory=null}queue(e){if(this.isDisposed)throw Error("Throttler is disposed");if(this.activePromise){if(this.queuedPromiseFactory=e,!this.queuedPromise){let e=()=>{if(this.queuedPromise=null,this.isDisposed)return;let e=this.queue(this.queuedPromiseFactory);return this.queuedPromiseFactory=null,e};this.queuedPromise=new Promise(t=>{this.activePromise.then(e,e).then(t)})}return new Promise((e,t)=>{this.queuedPromise.then(e,t)})}return this.activePromise=e(),new Promise((e,t)=>{this.activePromise.then(t=>{this.activePromise=null,e(t)},e=>{this.activePromise=null,t(e)})})}dispose(){this.isDisposed=!0}}let li=(e,t)=>{let i=!0,n=setTimeout(()=>{i=!1,t()},e);return{isTriggered:()=>i,dispose:()=>{clearTimeout(n),i=!1}}},ln=e=>{let t=!0;return queueMicrotask(()=>{t&&(t=!1,e())}),{isTriggered:()=>t,dispose:()=>{t=!1}}};class lr{constructor(e){this.defaultDelay=e,this.deferred=null,this.completionPromise=null,this.doResolve=null,this.doReject=null,this.task=null}trigger(e,t=this.defaultDelay){this.task=e,this.cancelTimeout(),this.completionPromise||(this.completionPromise=new Promise((e,t)=>{this.doResolve=e,this.doReject=t}).then(()=>{if(this.completionPromise=null,this.doResolve=null,this.task){let e=this.task;return this.task=null,e()}}));let i=()=>{var e;this.deferred=null,null===(e=this.doResolve)||void 0===e||e.call(this,null)};return this.deferred=t===a6?ln(i):li(t,i),this.completionPromise}isTriggered(){var e;return!!(null===(e=this.deferred)||void 0===e?void 0:e.isTriggered())}cancel(){var e;this.cancelTimeout(),this.completionPromise&&(null===(e=this.doReject)||void 0===e||e.call(this,new i6),this.completionPromise=null)}cancelTimeout(){var e;null===(e=this.deferred)||void 0===e||e.dispose(),this.deferred=null}dispose(){this.cancel()}}class lo{constructor(e){this.delayer=new lr(e),this.throttler=new lt}trigger(e,t){return this.delayer.trigger(()=>this.throttler.queue(e),t)}cancel(){this.delayer.cancel()}dispose(){this.delayer.dispose(),this.throttler.dispose()}}function ls(e,t){return t?new Promise((i,n)=>{let r=setTimeout(()=>{o.dispose(),i()},e),o=t.onCancellationRequested(()=>{clearTimeout(r),o.dispose(),n(new i6)})}):le(t=>ls(e,t))}function la(e,t=0){let i=setTimeout(e,t);return nu(()=>clearTimeout(i))}class ll{constructor(e,t){this._token=-1,"function"==typeof e&&"number"==typeof t&&this.setIfNotSet(e,t)}dispose(){this.cancel()}cancel(){-1!==this._token&&(clearTimeout(this._token),this._token=-1)}cancelAndSet(e,t){this.cancel(),this._token=setTimeout(()=>{this._token=-1,e()},t)}setIfNotSet(e,t){-1===this._token&&(this._token=setTimeout(()=>{this._token=-1,e()},t))}}class lh{constructor(){this._token=-1}dispose(){this.cancel()}cancel(){-1!==this._token&&(clearInterval(this._token),this._token=-1)}cancelAndSet(e,t){this.cancel(),this._token=setInterval(()=>{e()},t)}}class lu{constructor(e,t){this.timeoutToken=-1,this.runner=e,this.timeout=t,this.timeoutHandler=this.onTimeout.bind(this)}dispose(){this.cancel(),this.runner=null}cancel(){this.isScheduled()&&(clearTimeout(this.timeoutToken),this.timeoutToken=-1)}schedule(e=this.timeout){this.cancel(),this.timeoutToken=setTimeout(this.timeoutHandler,e)}get delay(){return this.timeout}set delay(e){this.timeout=e}isScheduled(){return -1!==this.timeoutToken}onTimeout(){this.timeoutToken=-1,this.runner&&this.doRun()}doRun(){var e;null===(e=this.runner)||void 0===e||e.call(this)}}l="function"!=typeof requestIdleCallback||"function"!=typeof cancelIdleCallback?e=>{(0,nz.fn)(()=>{if(t)return;let i=Date.now()+15;e(Object.freeze({didTimeout:!0,timeRemaining:()=>Math.max(0,i-Date.now())}))});let t=!1;return{dispose(){t||(t=!0)}}}:(e,t)=>{let i=requestIdleCallback(e,"number"==typeof t?{timeout:t}:void 0),n=!1;return{dispose(){n||(n=!0,cancelIdleCallback(i))}}};class ld{constructor(e){this._didRun=!1,this._executor=()=>{try{this._value=e()}catch(e){this._error=e}finally{this._didRun=!0}},this._handle=l(()=>this._executor())}dispose(){this._handle.dispose()}get value(){if(this._didRun||(this._handle.dispose(),this._executor()),this._error)throw this._error;return this._value}get isInitialized(){return this._didRun}}class lc{get isRejected(){var e;return(null===(e=this.outcome)||void 0===e?void 0:e.outcome)===1}get isSettled(){return!!this.outcome}constructor(){this.p=new Promise((e,t)=>{this.completeCallback=e,this.errorCallback=t})}complete(e){return new Promise(t=>{this.completeCallback(e),this.outcome={outcome:0,value:e},t()})}error(e){return new Promise(t=>{this.errorCallback(e),this.outcome={outcome:1,value:e},t()})}cancel(){return this.error(new i6)}}(ev=tJ||(tJ={})).settled=function(e){return a9(this,void 0,void 0,function*(){let t;let i=yield Promise.all(e.map(e=>e.then(e=>e,e=>{t||(t=e)})));if(void 0!==t)throw t;return i})},ev.withAsyncBody=function(e){return new Promise((t,i)=>a9(this,void 0,void 0,function*(){try{yield e(t,i)}catch(e){i(e)}}))};class lf{static fromArray(e){return new lf(t=>{t.emitMany(e)})}static fromPromise(e){return new lf(t=>a9(this,void 0,void 0,function*(){t.emitMany((yield e))}))}static fromPromises(e){return new lf(t=>a9(this,void 0,void 0,function*(){yield Promise.all(e.map(e=>a9(this,void 0,void 0,function*(){return t.emitOne((yield e))})))}))}static merge(e){return new lf(t=>a9(this,void 0,void 0,function*(){yield Promise.all(e.map(e=>{var i,n,r;return a9(this,void 0,void 0,function*(){var o,s,a,l;try{for(i=!0,n=a8(e);!(o=(r=yield n.next()).done);i=!0)l=r.value,i=!1,t.emitOne(l)}catch(e){s={error:e}}finally{try{!i&&!o&&(a=n.return)&&(yield a.call(n))}finally{if(s)throw s.error}}})}))}))}constructor(e){this._state=0,this._results=[],this._error=null,this._onStateChanged=new ny,queueMicrotask(()=>a9(this,void 0,void 0,function*(){let t={emitOne:e=>this.emitOne(e),emitMany:e=>this.emitMany(e),reject:e=>this.reject(e)};try{yield Promise.resolve(e(t)),this.resolve()}catch(e){this.reject(e)}finally{t.emitOne=void 0,t.emitMany=void 0,t.reject=void 0}}))}[Symbol.asyncIterator](){let e=0;return{next:()=>a9(this,void 0,void 0,function*(){for(;;){if(2===this._state)throw this._error;if(ea9(this,void 0,void 0,function*(){var n,r,o,s;try{for(var a,l=!0,h=a8(e);!(n=(a=yield h.next()).done);l=!0)s=a.value,l=!1,i.emitOne(t(s))}catch(e){r={error:e}}finally{try{!l&&!n&&(o=h.return)&&(yield o.call(h))}finally{if(r)throw r.error}}}))}map(e){return lf.map(this,e)}static filter(e,t){return new lf(i=>a9(this,void 0,void 0,function*(){var n,r,o,s;try{for(var a,l=!0,h=a8(e);!(n=(a=yield h.next()).done);l=!0)s=a.value,l=!1,t(s)&&i.emitOne(s)}catch(e){r={error:e}}finally{try{!l&&!n&&(o=h.return)&&(yield o.call(h))}finally{if(r)throw r.error}}}))}filter(e){return lf.filter(this,e)}static coalesce(e){return lf.filter(e,e=>!!e)}coalesce(){return lf.coalesce(this)}static toPromise(e){var t,i,n,r,o,s,a;return a9(this,void 0,void 0,function*(){let l=[];try{for(t=!0,i=a8(e);!(r=(n=yield i.next()).done);t=!0)a=n.value,t=!1,l.push(a)}catch(e){o={error:e}}finally{try{!t&&!r&&(s=i.return)&&(yield s.call(i))}finally{if(o)throw o.error}}return l})}toPromise(){return lf.toPromise(this)}emitOne(e){0===this._state&&(this._results.push(e),this._onStateChanged.fire())}emitMany(e){0===this._state&&(this._results=this._results.concat(e),this._onStateChanged.fire())}resolve(){0===this._state&&(this._state=1,this._onStateChanged.fire())}reject(e){0===this._state&&(this._state=2,this._error=e,this._onStateChanged.fire())}}lf.EMPTY=lf.fromArray([]);let lg=!1;function lp(e){nz.$L&&(lg||(lg=!0,console.warn("Could not create web worker(s). Falling back to loading web worker code in main thread, which might cause UI freezes. Please see https://github.com/microsoft/monaco-editor#faq")),console.warn(e.message))}class lm{constructor(e,t,i,n){this.vsWorker=e,this.req=t,this.method=i,this.args=n,this.type=0}}class l_{constructor(e,t,i,n){this.vsWorker=e,this.seq=t,this.res=i,this.err=n,this.type=1}}class lE{constructor(e,t,i,n){this.vsWorker=e,this.req=t,this.eventName=i,this.arg=n,this.type=2}}class lv{constructor(e,t,i){this.vsWorker=e,this.req=t,this.event=i,this.type=3}}class lb{constructor(e,t){this.vsWorker=e,this.req=t,this.type=4}}class lC{constructor(e){this._workerId=-1,this._handler=e,this._lastSentReq=0,this._pendingReplies=Object.create(null),this._pendingEmitters=new Map,this._pendingEvents=new Map}setWorkerId(e){this._workerId=e}sendMessage(e,t){let i=String(++this._lastSentReq);return new Promise((n,r)=>{this._pendingReplies[i]={resolve:n,reject:r},this._send(new lm(this._workerId,i,e,t))})}listen(e,t){let i=null,n=new ny({onWillAddFirstListener:()=>{i=String(++this._lastSentReq),this._pendingEmitters.set(i,n),this._send(new lE(this._workerId,i,e,t))},onDidRemoveLastListener:()=>{this._pendingEmitters.delete(i),this._send(new lb(this._workerId,i)),i=null}});return n.event}handleMessage(e){e&&e.vsWorker&&(-1===this._workerId||e.vsWorker===this._workerId)&&this._handleMessage(e)}_handleMessage(e){switch(e.type){case 1:return this._handleReplyMessage(e);case 0:return this._handleRequestMessage(e);case 2:return this._handleSubscribeEventMessage(e);case 3:return this._handleEventMessage(e);case 4:return this._handleUnsubscribeEventMessage(e)}}_handleReplyMessage(e){if(!this._pendingReplies[e.seq]){console.warn("Got reply to unknown seq");return}let t=this._pendingReplies[e.seq];if(delete this._pendingReplies[e.seq],e.err){let i=e.err;e.err.$isError&&((i=Error()).name=e.err.name,i.message=e.err.message,i.stack=e.err.stack),t.reject(i);return}t.resolve(e.res)}_handleRequestMessage(e){let t=e.req,i=this._handler.handleMessage(e.method,e.args);i.then(e=>{this._send(new l_(this._workerId,t,e,void 0))},e=>{e.detail instanceof Error&&(e.detail=i5(e.detail)),this._send(new l_(this._workerId,t,void 0,i5(e)))})}_handleSubscribeEventMessage(e){let t=e.req,i=this._handler.handleEvent(e.eventName,e.arg)(e=>{this._send(new lv(this._workerId,t,e))});this._pendingEvents.set(t,i)}_handleEventMessage(e){if(!this._pendingEmitters.has(e.req)){console.warn("Got event for unknown req");return}this._pendingEmitters.get(e.req).fire(e.event)}_handleUnsubscribeEventMessage(e){if(!this._pendingEvents.has(e.req)){console.warn("Got unsubscribe for unknown req");return}this._pendingEvents.get(e.req).dispose(),this._pendingEvents.delete(e.req)}_send(e){let t=[];if(0===e.type)for(let i=0;i{this._protocol.handleMessage(e)},e=>{null==n||n(e)})),this._protocol=new lC({sendMessage:(e,t)=>{this._worker.postMessage(e,t)},handleMessage:(e,t)=>{if("function"!=typeof i[e])return Promise.reject(Error("Missing method "+e+" on main thread host."));try{return Promise.resolve(i[e].apply(i,t))}catch(e){return Promise.reject(e)}},handleEvent:(e,t)=>{if(lT(e)){let n=i[e].call(i,t);if("function"!=typeof n)throw Error(`Missing dynamic event ${e} on main thread host.`);return n}if(ly(e)){let t=i[e];if("function"!=typeof t)throw Error(`Missing event ${e} on main thread host.`);return t}throw Error(`Malformed event name ${e}`)}}),this._protocol.setWorkerId(this._worker.getId());let r=null,o=globalThis.require;void 0!==o&&"function"==typeof o.getConfig?r=o.getConfig():void 0!==globalThis.requirejs&&(r=globalThis.requirejs.s.contexts._.config);let s=(0,oq.$E)(i);this._onModuleLoaded=this._protocol.sendMessage("$initialize",[this._worker.getId(),JSON.parse(JSON.stringify(r)),t,s]);let a=(e,t)=>this._request(e,t),l=(e,t)=>this._protocol.listen(e,t);this._lazyProxy=new Promise((e,i)=>{n=i,this._onModuleLoaded.then(t=>{e(function(e,t,i){let n=e=>function(){let i=Array.prototype.slice.call(arguments,0);return t(e,i)},r=e=>function(t){return i(e,t)},o={};for(let t of e){if(lT(t)){o[t]=r(t);continue}if(ly(t)){o[t]=i(t,void 0);continue}o[t]=n(t)}return o}(t,a,l))},e=>{i(e),this._onError("Worker failed to load "+t,e)})})}getProxyObject(){return this._lazyProxy}_request(e,t){return new Promise((i,n)=>{this._onModuleLoaded.then(()=>{this._protocol.sendMessage(e,t).then(i,n)},n)})}_onError(e,t){console.error(e),console.info(t)}}function ly(e){return"o"===e[0]&&"n"===e[1]&&r1(e.charCodeAt(2))}function lT(e){return/^onDynamic/.test(e)&&r1(e.charCodeAt(9))}function lR(e,t){var i;let n=globalThis.MonacoEnvironment;if(null==n?void 0:n.createTrustedTypesPolicy)try{return n.createTrustedTypesPolicy(e,t)}catch(e){i1(e);return}try{return null===(i=window.trustedTypes)||void 0===i?void 0:i.createPolicy(e,t)}catch(e){i1(e);return}}let lA=lR("defaultWorkerFactory",{createScriptURL:e=>e});class lN{constructor(e,t,i,n,r){this.id=t;let o=function(e){let t=globalThis.MonacoEnvironment;if(t){if("function"==typeof t.getWorker)return t.getWorker("workerMain.js",e);if("function"==typeof t.getWorkerUrl){let i=t.getWorkerUrl("workerMain.js",e);return new Worker(lA?lA.createScriptURL(i):i,{name:e})}}throw Error("You must define a function MonacoEnvironment.getWorkerUrl or MonacoEnvironment.getWorker")}(i);("function"==typeof o.then?0:1)?this.worker=Promise.resolve(o):this.worker=o,this.postMessage(e,[]),this.worker.then(e=>{e.onmessage=function(e){n(e.data)},e.onmessageerror=r,"function"==typeof e.addEventListener&&e.addEventListener("error",r)})}getId(){return this.id}postMessage(e,t){var i;null===(i=this.worker)||void 0===i||i.then(i=>i.postMessage(e,t))}dispose(){var e;null===(e=this.worker)||void 0===e||e.then(e=>e.terminate()),this.worker=null}}class lO{constructor(e){this._label=e,this._webWorkerFailedBeforeError=!1}create(e,t,i){let n=++lO.LAST_WORKER_ID;if(this._webWorkerFailedBeforeError)throw this._webWorkerFailedBeforeError;return new lN(e,n,this._label||"anonymous"+n,t,e=>{lp(e),this._webWorkerFailedBeforeError=e,i(e)})}}lO.LAST_WORKER_ID=0;class lL{constructor(e,t,i,n){this.originalStart=e,this.originalLength=t,this.modifiedStart=i,this.modifiedLength=n}getOriginalEnd(){return this.originalStart+this.originalLength}getModifiedEnd(){return this.modifiedStart+this.modifiedLength}}function lI(e,t){return(t<<5)-t+e|0}function lw(e,t){t=lI(149417,t);for(let i=0,n=e.length;i>>n)>>>0}function lx(e,t=0,i=e.byteLength,n=0){for(let r=0;re.toString(16).padStart(2,"0")).join(""):function(e,t,i="0"){for(;e.length>>0).toString(16),t/4)}class lk{constructor(){this._h0=1732584193,this._h1=4023233417,this._h2=2562383102,this._h3=271733878,this._h4=3285377520,this._buff=new Uint8Array(67),this._buffDV=new DataView(this._buff.buffer),this._buffLen=0,this._totalLen=0,this._leftoverHighSurrogate=0,this._finished=!1}update(e){let t,i;let n=e.length;if(0===n)return;let r=this._buff,o=this._buffLen,s=this._leftoverHighSurrogate;for(0!==s?(t=s,i=-1,s=0):(t=e.charCodeAt(0),i=0);;){let a=t;if(r6(t)){if(i+1>>6,e[t++]=128|(63&i)>>>0):i<65536?(e[t++]=224|(61440&i)>>>12,e[t++]=128|(4032&i)>>>6,e[t++]=128|(63&i)>>>0):(e[t++]=240|(1835008&i)>>>18,e[t++]=128|(258048&i)>>>12,e[t++]=128|(4032&i)>>>6,e[t++]=128|(63&i)>>>0),t>=64&&(this._step(),t-=64,this._totalLen+=64,e[0]=e[64],e[1]=e[65],e[2]=e[66]),t}digest(){return this._finished||(this._finished=!0,this._leftoverHighSurrogate&&(this._leftoverHighSurrogate=0,this._buffLen=this._push(this._buff,this._buffLen,65533)),this._totalLen+=this._buffLen,this._wrapUp()),lM(this._h0)+lM(this._h1)+lM(this._h2)+lM(this._h3)+lM(this._h4)}_wrapUp(){this._buff[this._buffLen++]=128,lx(this._buff,this._buffLen),this._buffLen>56&&(this._step(),lx(this._buff));let e=8*this._totalLen;this._buffDV.setUint32(56,Math.floor(e/4294967296),!1),this._buffDV.setUint32(60,e%4294967296,!1),this._step()}_step(){let e,t,i;let n=lk._bigBlock32,r=this._buffDV;for(let e=0;e<64;e+=4)n.setUint32(e,r.getUint32(e,!1),!1);for(let e=64;e<320;e+=4)n.setUint32(e,lD(n.getUint32(e-12,!1)^n.getUint32(e-32,!1)^n.getUint32(e-56,!1)^n.getUint32(e-64,!1),1),!1);let o=this._h0,s=this._h1,a=this._h2,l=this._h3,h=this._h4;for(let r=0;r<80;r++)r<20?(e=s&a|~s&l,t=1518500249):r<40?(e=s^a^l,t=1859775393):r<60?(e=s&a|s&l|a&l,t=2400959708):(e=s^a^l,t=3395469782),i=lD(o,5)+e+h+t+n.getUint32(4*r,!1)&4294967295,h=l,l=a,a=lD(s,30),s=o,o=i;this._h0=this._h0+o&4294967295,this._h1=this._h1+s&4294967295,this._h2=this._h2+a&4294967295,this._h3=this._h3+l&4294967295,this._h4=this._h4+h&4294967295}}lk._bigBlock32=new DataView(new ArrayBuffer(320));class lP{constructor(e){this.source=e}getElements(){let e=this.source,t=new Int32Array(e.length);for(let i=0,n=e.length;i0||this.m_modifiedCount>0)&&this.m_changes.push(new lL(this.m_originalStart,this.m_originalCount,this.m_modifiedStart,this.m_modifiedCount)),this.m_originalCount=0,this.m_modifiedCount=0,this.m_originalStart=1073741824,this.m_modifiedStart=1073741824}AddOriginalElement(e,t){this.m_originalStart=Math.min(this.m_originalStart,e),this.m_modifiedStart=Math.min(this.m_modifiedStart,t),this.m_originalCount++}AddModifiedElement(e,t){this.m_originalStart=Math.min(this.m_originalStart,e),this.m_modifiedStart=Math.min(this.m_modifiedStart,t),this.m_modifiedCount++}getChanges(){return(this.m_originalCount>0||this.m_modifiedCount>0)&&this.MarkNextChange(),this.m_changes}getReverseChanges(){return(this.m_originalCount>0||this.m_modifiedCount>0)&&this.MarkNextChange(),this.m_changes.reverse(),this.m_changes}}class lH{constructor(e,t,i=null){this.ContinueProcessingPredicate=i,this._originalSequence=e,this._modifiedSequence=t;let[n,r,o]=lH._getElements(e),[s,a,l]=lH._getElements(t);this._hasStrings=o&&l,this._originalStringElements=n,this._originalElementsOrHash=r,this._modifiedStringElements=s,this._modifiedElementsOrHash=a,this.m_forwardHistory=[],this.m_reverseHistory=[]}static _isStringArray(e){return e.length>0&&"string"==typeof e[0]}static _getElements(e){let t=e.getElements();if(lH._isStringArray(t)){let e=new Int32Array(t.length);for(let i=0,n=t.length;i=e&&n>=i&&this.ElementsAreEqual(t,n);)t--,n--;if(e>t||i>n){let r;return i<=n?(lF.Assert(e===t+1,"originalStart should only be one more than originalEnd"),r=[new lL(e,0,i,n-i+1)]):e<=t?(lF.Assert(i===n+1,"modifiedStart should only be one more than modifiedEnd"),r=[new lL(e,t-e+1,i,0)]):(lF.Assert(e===t+1,"originalStart should only be one more than originalEnd"),lF.Assert(i===n+1,"modifiedStart should only be one more than modifiedEnd"),r=[]),r}let o=[0],s=[0],a=this.ComputeRecursionPoint(e,t,i,n,o,s,r),l=o[0],h=s[0];if(null!==a)return a;if(!r[0]){let o=this.ComputeDiffRecursive(e,l,i,h,r),s=[];return s=r[0]?[new lL(l+1,t-(l+1)+1,h+1,n-(h+1)+1)]:this.ComputeDiffRecursive(l+1,t,h+1,n,r),this.ConcatenateChanges(o,s)}return[new lL(e,t-e+1,i,n-i+1)]}WALKTRACE(e,t,i,n,r,o,s,a,l,h,u,d,c,f,g,p,m,_){let E=null,v=null,b=new lU,C=t,S=i,y=c[0]-p[0]-n,T=-1073741824,R=this.m_forwardHistory.length-1;do{let t=y+e;t===C||t=0&&(e=(l=this.m_forwardHistory[R])[0],C=1,S=l.length-1)}while(--R>=-1);if(E=b.getReverseChanges(),_[0]){let e=c[0]+1,t=p[0]+1;if(null!==E&&E.length>0){let i=E[E.length-1];e=Math.max(e,i.getOriginalEnd()),t=Math.max(t,i.getModifiedEnd())}v=[new lL(e,d-e+1,t,g-t+1)]}else{b=new lU,C=o,S=s,y=c[0]-p[0]-a,T=1073741824,R=m?this.m_reverseHistory.length-1:this.m_reverseHistory.length-2;do{let e=y+r;e===C||e=h[e+1]?(f=(u=h[e+1]-1)-y-a,u>T&&b.MarkNextChange(),T=u+1,b.AddOriginalElement(u+1,f+1),y=e+1-r):(f=(u=h[e-1])-y-a,u>T&&b.MarkNextChange(),T=u,b.AddModifiedElement(u+1,f+1),y=e-1-r),R>=0&&(r=(h=this.m_reverseHistory[R])[0],C=1,S=h.length-1)}while(--R>=-1);v=b.getChanges()}return this.ConcatenateChanges(E,v)}ComputeRecursionPoint(e,t,i,n,r,o,s){let a=0,l=0,h=0,u=0,d=0,c=0;e--,i--,r[0]=0,o[0]=0,this.m_forwardHistory=[],this.m_reverseHistory=[];let f=t-e+(n-i),g=f+1,p=new Int32Array(g),m=new Int32Array(g),_=n-i,E=t-e,v=e-i,b=t-n,C=E-_,S=C%2==0;p[_]=e,m[E]=t,s[0]=!1;for(let C=1;C<=f/2+1;C++){let f=0,y=0;h=this.ClipDiagonalBound(_-C,C,_,g),u=this.ClipDiagonalBound(_+C,C,_,g);for(let e=h;e<=u;e+=2){l=(a=e===h||ef+y&&(f=a,y=l),!S&&Math.abs(e-E)<=C-1&&a>=m[e]){if(r[0]=a,o[0]=l,i<=m[e]&&C<=1448)return this.WALKTRACE(_,h,u,v,E,d,c,b,p,m,a,t,r,l,n,o,S,s);return null}}let T=(f-e+(y-i)-C)/2;if(null!==this.ContinueProcessingPredicate&&!this.ContinueProcessingPredicate(f,T)){if(s[0]=!0,r[0]=f,o[0]=y,!(T>0)||!(C<=1448))return e++,i++,[new lL(e,t-e+1,i,n-i+1)];break}d=this.ClipDiagonalBound(E-C,C,E,g),c=this.ClipDiagonalBound(E+C,C,E,g);for(let f=d;f<=c;f+=2){l=(a=f===d||f=m[f+1]?m[f+1]-1:m[f-1])-(f-E)-b;let g=a;for(;a>e&&l>i&&this.ElementsAreEqual(a,l);)a--,l--;if(m[f]=a,S&&Math.abs(f-_)<=C&&a<=p[f]){if(r[0]=a,o[0]=l,g>=p[f]&&C<=1448)return this.WALKTRACE(_,h,u,v,E,d,c,b,p,m,a,t,r,l,n,o,S,s);return null}}if(C<=1447){let e=new Int32Array(u-h+2);e[0]=_-h+1,lB.Copy2(p,h,e,1,u-h+1),this.m_forwardHistory.push(e),(e=new Int32Array(c-d+2))[0]=E-d+1,lB.Copy2(m,d,e,1,c-d+1),this.m_reverseHistory.push(e)}}return this.WALKTRACE(_,h,u,v,E,d,c,b,p,m,a,t,r,l,n,o,S,s)}PrettifyChanges(e){for(let t=0;t0,s=i.modifiedLength>0;for(;i.originalStart+i.originalLength=0;t--){let i=e[t],n=0,r=0;if(t>0){let i=e[t-1];n=i.originalStart+i.originalLength,r=i.modifiedStart+i.modifiedLength}let o=i.originalLength>0,s=i.modifiedLength>0,a=0,l=this._boundaryScore(i.originalStart,i.originalLength,i.modifiedStart,i.modifiedLength);for(let e=1;;e++){let t=i.originalStart-e,h=i.modifiedStart-e;if(tl&&(l=d,a=e)}i.originalStart-=a,i.modifiedStart-=a;let h=[null];if(t>0&&this.ChangesOverlap(e[t-1],e[t],h)){e[t-1]=h[0],e.splice(t,1),t++;continue}}if(this._hasStrings)for(let t=1,i=e.length;t0&&i>a&&(a=i,l=t,h=e)}return a>0?[l,h]:null}_contiguousSequenceScore(e,t,i){let n=0;for(let r=0;r=this._originalElementsOrHash.length-1||this._hasStrings&&/^\s*$/.test(this._originalStringElements[e])}_OriginalRegionIsBoundary(e,t){if(this._OriginalIsBoundary(e)||this._OriginalIsBoundary(e-1))return!0;if(t>0){let i=e+t;if(this._OriginalIsBoundary(i-1)||this._OriginalIsBoundary(i))return!0}return!1}_ModifiedIsBoundary(e){return e<=0||e>=this._modifiedElementsOrHash.length-1||this._hasStrings&&/^\s*$/.test(this._modifiedStringElements[e])}_ModifiedRegionIsBoundary(e,t){if(this._ModifiedIsBoundary(e)||this._ModifiedIsBoundary(e-1))return!0;if(t>0){let i=e+t;if(this._ModifiedIsBoundary(i-1)||this._ModifiedIsBoundary(i))return!0}return!1}_boundaryScore(e,t,i,n){let r=this._OriginalRegionIsBoundary(e,t)?1:0,o=this._ModifiedRegionIsBoundary(i,n)?1:0;return r+o}ConcatenateChanges(e,t){let i=[];if(0===e.length||0===t.length)return t.length>0?t:e;if(this.ChangesOverlap(e[e.length-1],t[0],i)){let n=Array(e.length+t.length-1);return lB.Copy(e,0,n,0,e.length-1),n[e.length-1]=i[0],lB.Copy(t,1,n,e.length,t.length-1),n}{let i=Array(e.length+t.length);return lB.Copy(e,0,i,0,e.length),lB.Copy(t,0,i,e.length,t.length),i}}ChangesOverlap(e,t,i){if(lF.Assert(e.originalStart<=t.originalStart,"Left change is not less than or equal to right change"),lF.Assert(e.modifiedStart<=t.modifiedStart,"Left change is not less than or equal to right change"),!(e.originalStart+e.originalLength>=t.originalStart)&&!(e.modifiedStart+e.modifiedLength>=t.modifiedStart))return i[0]=null,!1;{let n=e.originalStart,r=e.originalLength,o=e.modifiedStart,s=e.modifiedLength;return e.originalStart+e.originalLength>=t.originalStart&&(r=t.originalStart+t.originalLength-e.originalStart),e.modifiedStart+e.modifiedLength>=t.modifiedStart&&(s=t.modifiedStart+t.modifiedLength-e.modifiedStart),i[0]=new lL(n,r,o,s),!0}}ClipDiagonalBound(e,t,i,n){if(e>=0&&e255?255:0|e}function lW(e){return e<0?0:e>4294967295?4294967295:0|e}class lG{constructor(e){this.values=e,this.prefixSum=new Uint32Array(e.length),this.prefixSumValidIndex=new Int32Array(1),this.prefixSumValidIndex[0]=-1}insertValues(e,t){e=lW(e);let i=this.values,n=this.prefixSum,r=t.length;return 0!==r&&(this.values=new Uint32Array(i.length+r),this.values.set(i.subarray(0,e),0),this.values.set(i.subarray(e),e+r),this.values.set(t,e),e-1=0&&this.prefixSum.set(n.subarray(0,this.prefixSumValidIndex[0]+1)),!0)}setValue(e,t){return e=lW(e),t=lW(t),this.values[e]!==t&&(this.values[e]=t,e-1=i.length)return!1;let r=i.length-e;return t>=r&&(t=r),0!==t&&(this.values=new Uint32Array(i.length-t),this.values.set(i.subarray(0,e),0),this.values.set(i.subarray(e+t),e),this.prefixSum=new Uint32Array(this.values.length),e-1=0&&this.prefixSum.set(n.subarray(0,this.prefixSumValidIndex[0]+1)),!0)}getTotalSum(){return 0===this.values.length?0:this._getPrefixSum(this.values.length-1)}getPrefixSum(e){return e<0?0:(e=lW(e),this._getPrefixSum(e))}_getPrefixSum(e){if(e<=this.prefixSumValidIndex[0])return this.prefixSum[e];let t=this.prefixSumValidIndex[0]+1;0===t&&(this.prefixSum[0]=this.values[0],t++),e>=this.values.length&&(e=this.values.length-1);for(let i=t;i<=e;i++)this.prefixSum[i]=this.prefixSum[i-1]+this.values[i];return this.prefixSumValidIndex[0]=Math.max(this.prefixSumValidIndex[0],e),this.prefixSum[e]}getIndexOf(e){e=Math.floor(e),this.getTotalSum();let t=0,i=this.values.length-1,n=0,r=0,o=0;for(;t<=i;)if(n=t+(i-t)/2|0,e<(o=(r=this.prefixSum[n])-this.values[n]))i=n-1;else if(e>=r)t=n+1;else break;return new lz(n,e-o)}}class lj{constructor(e){this._values=e,this._isValid=!1,this._validEndIndex=-1,this._prefixSum=[],this._indexBySum=[]}getTotalSum(){return this._ensureValid(),this._indexBySum.length}getPrefixSum(e){return(this._ensureValid(),0===e)?0:this._prefixSum[e-1]}getIndexOf(e){this._ensureValid();let t=this._indexBySum[e],i=t>0?this._prefixSum[t-1]:0;return new lz(t,e-i)}removeValues(e,t){this._values.splice(e,t),this._invalidate(e)}insertValues(e,t){this._values=(0,sX.Zv)(this._values,e,t),this._invalidate(e)}_invalidate(e){this._isValid=!1,this._validEndIndex=Math.min(this._validEndIndex,e-1)}_ensureValid(){if(!this._isValid){for(let e=this._validEndIndex+1,t=this._values.length;e0?this._prefixSum[e-1]:0;this._prefixSum[e]=i+t;for(let n=0;n=0&&e<256?this._asciiMap[e]=i:this._map.set(e,i)}get(e){return e>=0&&e<256?this._asciiMap[e]:this._map.get(e)||this._defaultValue}clear(){this._asciiMap.fill(this._defaultValue),this._map.clear()}}class l${constructor(e,t,i){let n=new Uint8Array(e*t);for(let r=0,o=e*t;rt&&(t=o),r>i&&(i=r),s>i&&(i=s)}t++,i++;let n=new l$(i,t,0);for(let t=0,i=e.length;t=this._maxCharCode?0:this._states.get(e,t)}}let lX=null;function lZ(){return null===lX&&(lX=new lq([[1,104,2],[1,72,2],[1,102,6],[1,70,6],[2,116,3],[2,84,3],[3,116,4],[3,84,4],[4,112,5],[4,80,5],[5,115,9],[5,83,9],[5,58,10],[6,105,7],[6,73,7],[7,108,8],[7,76,8],[8,101,9],[8,69,9],[9,58,10],[10,47,11],[11,47,12]])),lX}let lQ=null;class lJ{static _createLink(e,t,i,n,r){let o=r-1;do{let i=t.charCodeAt(o),n=e.get(i);if(2!==n)break;o--}while(o>n);if(n>0){let e=t.charCodeAt(n-1),i=t.charCodeAt(o);(40===e&&41===i||91===e&&93===i||123===e&&125===i)&&o--}return{range:{startLineNumber:i,startColumn:n+1,endLineNumber:i,endColumn:o+2},url:t.substring(n,o+1)}}static computeLinks(e,t=lZ()){let i=function(){if(null===lQ){lQ=new lY(0);let e=" <>'\"、。。、,.:;‘〈「『〔([{「」}])〕』」〉’`~…";for(let t=0;t=0?((n+=i?1:-1)<0?n=e.length-1:n%=e.length,e[n]):null}}l0.INSTANCE=new l0;class l1 extends lY{constructor(e){super(0);for(let t=0,i=e.length;t(t.hasOwnProperty(i)||(t[i]=e(i)),t[i])}(e=>new l1(e));class l5{constructor(e,t,i,n){this.searchString=e,this.isRegex=t,this.matchCase=i,this.wordSeparators=n}parseSearchRequest(){let e;if(""===this.searchString)return null;e=this.isRegex?function(e){if(!e||0===e.length)return!1;for(let t=0,i=e.length;t=i)break;let n=e.charCodeAt(t);if(110===n||114===n||87===n)return!0}}return!1}(this.searchString):this.searchString.indexOf("\n")>=0;let t=null;try{t=rG(this.searchString,this.isRegex,{matchCase:this.matchCase,wholeWord:!1,multiline:e,global:!0,unicode:!0})}catch(e){return null}if(!t)return null;let i=!this.isRegex&&!e;return i&&this.searchString.toLowerCase()!==this.searchString.toUpperCase()&&(i=this.matchCase),new sH(t,this.wordSeparators?l2(this.wordSeparators):null,i?this.searchString:null)}}function l4(e,t,i){if(!i)return new sB(e,null);let n=[];for(let e=0,i=t.length;e>0);t[r]>=e?n=r-1:t[r+1]>=e?(i=r,n=r):i=r+1}return i+1}}class l6{static findMatches(e,t,i,n,r){let o=t.parseSearchRequest();return o?o.regex.multiline?this._doFindMatchesMultiline(e,i,new l8(o.wordSeparators,o.regex),n,r):this._doFindMatchesLineByLine(e,i,o,n,r):[]}static _getMultilineMatchRange(e,t,i,n,r,o){let s,a;let l=0;if(n?(l=n.findLineFeedCountBeforeOffset(r),s=t+r+l):s=t+r,n){let e=n.findLineFeedCountBeforeOffset(r+o.length),t=e-l;a=s+o.length+t}else a=s+o.length;let h=e.getPositionAt(s),u=e.getPositionAt(a);return new rv(h.lineNumber,h.column,u.lineNumber,u.column)}static _doFindMatchesMultiline(e,t,i,n,r){let o;let s=e.getOffsetAt(t.getStartPosition()),a=e.getValueInRange(t,1),l="\r\n"===e.getEOL()?new l3(a):null,h=[],u=0;for(i.reset(0);(o=i.next(a))&&(h[u++]=l4(this._getMultilineMatchRange(e,s,a,l,o.index,o[0]),o,n),!(u>=r)););return h}static _doFindMatchesLineByLine(e,t,i,n,r){let o=[],s=0;if(t.startLineNumber===t.endLineNumber){let a=e.getLineContent(t.startLineNumber).substring(t.startColumn-1,t.endColumn-1);return s=this._findMatchesInLine(i,a,t.startLineNumber,t.startColumn-1,s,o,n,r),o}let a=e.getLineContent(t.startLineNumber).substring(t.startColumn-1);s=this._findMatchesInLine(i,a,t.startLineNumber,t.startColumn-1,s,o,n,r);for(let a=t.startLineNumber+1;a=a))););return r}let u=new l8(e.wordSeparators,e.regex);u.reset(0);do if((l=u.next(t))&&(o[r++]=l4(new rv(i,l.index+1+n,i,l.index+1+l[0].length+n),l,s),r>=a))break;while(l);return r}static findNextMatch(e,t,i,n){let r=t.parseSearchRequest();if(!r)return null;let o=new l8(r.wordSeparators,r.regex);return r.regex.multiline?this._doFindNextMatchMultiline(e,i,o,n):this._doFindNextMatchLineByLine(e,i,o,n)}static _doFindNextMatchMultiline(e,t,i,n){let r=new rE(t.lineNumber,1),o=e.getOffsetAt(r),s=e.getLineCount(),a=e.getValueInRange(new rv(r.lineNumber,r.column,s,e.getLineMaxColumn(s)),1),l="\r\n"===e.getEOL()?new l3(a):null;i.reset(t.column-1);let h=i.next(a);return h?l4(this._getMultilineMatchRange(e,o,a,l,h.index,h[0]),h,n):1!==t.lineNumber||1!==t.column?this._doFindNextMatchMultiline(e,new rE(1,1),i,n):null}static _doFindNextMatchLineByLine(e,t,i,n){let r=e.getLineCount(),o=t.lineNumber,s=e.getLineContent(o),a=this._findFirstMatchInLine(i,s,o,t.column,n);if(a)return a;for(let t=1;t<=r;t++){let s=(o+t-1)%r,a=e.getLineContent(s+1),l=this._findFirstMatchInLine(i,a,s+1,1,n);if(l)return l}return null}static _findFirstMatchInLine(e,t,i,n,r){e.reset(n-1);let o=e.next(t);return o?l4(new rv(i,o.index+1,i,o.index+1+o[0].length),o,r):null}static findPreviousMatch(e,t,i,n){let r=t.parseSearchRequest();if(!r)return null;let o=new l8(r.wordSeparators,r.regex);return r.regex.multiline?this._doFindPreviousMatchMultiline(e,i,o,n):this._doFindPreviousMatchLineByLine(e,i,o,n)}static _doFindPreviousMatchMultiline(e,t,i,n){let r=this._doFindMatchesMultiline(e,new rv(1,1,t.lineNumber,t.column),i,n,9990);if(r.length>0)return r[r.length-1];let o=e.getLineCount();return t.lineNumber!==o||t.column!==e.getLineMaxColumn(o)?this._doFindPreviousMatchMultiline(e,new rE(o,e.getLineMaxColumn(o)),i,n):null}static _doFindPreviousMatchLineByLine(e,t,i,n){let r=e.getLineCount(),o=t.lineNumber,s=e.getLineContent(o).substring(0,t.column-1),a=this._findLastMatchInLine(i,s,o,n);if(a)return a;for(let t=1;t<=r;t++){let s=(r+o-t-1)%r,a=e.getLineContent(s+1),l=this._findLastMatchInLine(i,a,s+1,n);if(l)return l}return null}static _findLastMatchInLine(e,t,i,n){let r,o=null;for(e.reset(0);r=e.next(t);)o=l4(new rv(i,r.index+1,i,r.index+1+r[0].length),r,n);return o}}function l9(e,t,i,n,r){return function(e,t,i,n,r){if(0===n)return!0;let o=t.charCodeAt(n-1);if(0!==e.get(o)||13===o||10===o)return!0;if(r>0){let i=t.charCodeAt(n);if(0!==e.get(i))return!0}return!1}(e,t,0,n,r)&&function(e,t,i,n,r){if(n+r===i)return!0;let o=t.charCodeAt(n+r);if(0!==e.get(o)||13===o||10===o)return!0;if(r>0){let i=t.charCodeAt(n+r-1);if(0!==e.get(i))return!0}return!1}(e,t,i,n,r)}class l8{constructor(e,t){this._wordSeparators=e,this._searchRegex=t,this._prevMatchStartIndex=-1,this._prevMatchLength=0}reset(e){this._searchRegex.lastIndex=e,this._prevMatchStartIndex=-1,this._prevMatchLength=0}next(e){let t;let i=e.length;do{if(this._prevMatchStartIndex+this._prevMatchLength===i||!(t=this._searchRegex.exec(e)))break;let n=t.index,r=t[0].length;if(n===this._prevMatchStartIndex&&r===this._prevMatchLength){if(0===r){r7(e,i,this._searchRegex.lastIndex)>65535?this._searchRegex.lastIndex+=2:this._searchRegex.lastIndex+=1;continue}break}if(this._prevMatchStartIndex=n,this._prevMatchLength=r,!this._wordSeparators||l9(this._wordSeparators,e,i,n,r))return t}while(t);return null}}class l7{static computeUnicodeHighlights(e,t,i){let n,r;let o=i?i.startLineNumber:1,s=i?i.endLineNumber:e.getLineCount(),a=new he(t),l=a.getCandidateCodePoints();n="allNonBasicAscii"===l?RegExp("[^\\t\\n\\r\\x20-\\x7E]","g"):RegExp(`${function(e,t){let i=`[${rV(e.map(e=>String.fromCodePoint(e)).join(""))}]`;return i}(Array.from(l))}`,"g");let h=new l8(null,n),u=[],d=!1,c=0,f=0,g=0;e:for(let t=o;t<=s;t++){let i=e.getLineContent(t),n=i.length;h.reset(0);do if(r=h.next(i)){let e=r.index,o=r.index+r[0].length;if(e>0){let t=i.charCodeAt(e-1);r6(t)&&e--}if(o+1=1e3){d=!0;break e}u.push(new rv(t,e+1,t,o+1))}}while(r)}return{ranges:u,hasMore:d,ambiguousCharacterCount:c,invisibleCharacterCount:f,nonBasicAsciiCharacterCount:g}}static computeUnicodeHighlightReason(e,t){let i=new he(t),n=i.shouldHighlightNonBasicASCII(e,null);switch(n){case 0:return null;case 2:return{kind:1};case 3:{let n=e.codePointAt(0),r=i.ambiguousCharacters.getPrimaryConfusable(n),o=op.getLocales().filter(e=>!op.getInstance(new Set([...t.allowedLocales,e])).isAmbiguous(n));return{kind:0,confusableWith:String.fromCodePoint(r),notAmbiguousInLocales:o}}case 1:return{kind:2}}}}class he{constructor(e){this.options=e,this.allowedCodePoints=new Set(e.allowedCodePoints),this.ambiguousCharacters=op.getInstance(new Set(e.allowedLocales))}getCandidateCodePoints(){if(this.options.nonBasicASCII)return"allNonBasicAscii";let e=new Set;if(this.options.invisibleCharacters)for(let t of om.codePoints)ht(String.fromCodePoint(t))||e.add(t);if(this.options.ambiguousCharacters)for(let t of this.ambiguousCharacters.getConfusableCodePoints())e.add(t);for(let t of this.allowedCodePoints)e.delete(t);return e}shouldHighlightNonBasicASCII(e,t){let i=e.codePointAt(0);if(this.allowedCodePoints.has(i))return 0;if(this.options.nonBasicASCII)return 1;let n=!1,r=!1;if(t)for(let e of t){let t=e.codePointAt(0),i=os(e);n=n||i,i||this.ambiguousCharacters.isAmbiguous(t)||om.isInvisibleCharacter(t)||(r=!0)}return!n&&r?0:this.options.invisibleCharacters&&!ht(e)&&om.isInvisibleCharacter(i)?2:this.options.ambiguousCharacters&&this.ambiguousCharacters.isAmbiguous(i)?3:0}}function ht(e){return" "===e||"\n"===e||" "===e}class hi{static fromRange(e){return new hi(e.startLineNumber,e.endLineNumber)}static subtract(e,t){return t?e.startLineNumber=s.startLineNumber?o=new hi(o.startLineNumber,Math.max(o.endLineNumberExclusive,s.endLineNumberExclusive)):(i.push(o),o=s)}return null!==o&&i.push(o),i}static ofLength(e,t){return new hi(e,e+t)}static deserialize(e){return new hi(e[0],e[1])}constructor(e,t){if(e>t)throw new nt(`startLineNumber ${e} cannot be after endLineNumberExclusive ${t}`);this.startLineNumber=e,this.endLineNumberExclusive=t}contains(e){return this.startLineNumber<=e&&e${this.modifiedRange.toString()}}`}get changedLineCount(){return Math.max(this.originalRange.length,this.modifiedRange.length)}flip(){var e;return new hr(this.modifiedRange,this.originalRange,null===(e=this.innerChanges)||void 0===e?void 0:e.map(e=>e.flip()))}}class ho{constructor(e,t){this.originalRange=e,this.modifiedRange=t}toString(){return`{${this.originalRange.toString()}->${this.modifiedRange.toString()}}`}flip(){return new ho(this.modifiedRange,this.originalRange)}}class hs{constructor(e,t){this.original=e,this.modified=t}toString(){return`{${this.original.toString()}->${this.modified.toString()}}`}flip(){return new hs(this.modified,this.original)}}class ha{constructor(e,t){this.lineRangeMapping=e,this.changes=t}flip(){return new ha(this.lineRangeMapping.flip(),this.changes.map(e=>e.flip()))}}class hl{computeDiff(e,t,i){var n;let r=new hg(e,t,{maxComputationTime:i.maxComputationTimeMs,shouldIgnoreTrimWhitespace:i.ignoreTrimWhitespace,shouldComputeCharChanges:!0,shouldMakePrettyDiff:!0,shouldPostProcessCharChanges:!0}),o=r.computeDiff(),s=[],a=null;for(let e of o.changes){let t,i;t=0===e.originalEndLineNumber?new hi(e.originalStartLineNumber+1,e.originalStartLineNumber+1):new hi(e.originalStartLineNumber,e.originalEndLineNumber+1),i=0===e.modifiedEndLineNumber?new hi(e.modifiedStartLineNumber+1,e.modifiedStartLineNumber+1):new hi(e.modifiedStartLineNumber,e.modifiedEndLineNumber+1);let r=new hr(t,i,null===(n=e.charChanges)||void 0===n?void 0:n.map(e=>new ho(new rv(e.originalStartLineNumber,e.originalStartColumn,e.originalEndLineNumber,e.originalEndColumn),new rv(e.modifiedStartLineNumber,e.modifiedStartColumn,e.modifiedEndLineNumber,e.modifiedEndColumn))));a&&(a.modifiedRange.endLineNumberExclusive===r.modifiedRange.startLineNumber||a.originalRange.endLineNumberExclusive===r.originalRange.startLineNumber)&&(r=new hr(a.originalRange.join(r.originalRange),a.modifiedRange.join(r.modifiedRange),a.innerChanges&&r.innerChanges?a.innerChanges.concat(r.innerChanges):void 0),s.pop()),s.push(r),a=r}return oY(()=>o$(s,(e,t)=>t.originalRange.startLineNumber-e.originalRange.endLineNumberExclusive==t.modifiedRange.startLineNumber-e.modifiedRange.endLineNumberExclusive&&e.originalRange.endLineNumberExclusive(10===e?"\\n":String.fromCharCode(e))+`-(${this._lineNumbers[t]},${this._columns[t]})`).join(", ")+"]"}_assertIndex(e,t){if(e<0||e>=t.length)throw Error("Illegal index")}getElements(){return this._charCodes}getStartLineNumber(e){return e>0&&e===this._lineNumbers.length?this.getEndLineNumber(e-1):(this._assertIndex(e,this._lineNumbers),this._lineNumbers[e])}getEndLineNumber(e){return -1===e?this.getStartLineNumber(e+1):(this._assertIndex(e,this._lineNumbers),10===this._charCodes[e])?this._lineNumbers[e]+1:this._lineNumbers[e]}getStartColumn(e){return e>0&&e===this._columns.length?this.getEndColumn(e-1):(this._assertIndex(e,this._columns),this._columns[e])}getEndColumn(e){return -1===e?this.getStartColumn(e+1):(this._assertIndex(e,this._columns),10===this._charCodes[e])?1:this._columns[e]+1}}class hc{constructor(e,t,i,n,r,o,s,a){this.originalStartLineNumber=e,this.originalStartColumn=t,this.originalEndLineNumber=i,this.originalEndColumn=n,this.modifiedStartLineNumber=r,this.modifiedStartColumn=o,this.modifiedEndLineNumber=s,this.modifiedEndColumn=a}static createFromDiffChange(e,t,i){let n=t.getStartLineNumber(e.originalStart),r=t.getStartColumn(e.originalStart),o=t.getEndLineNumber(e.originalStart+e.originalLength-1),s=t.getEndColumn(e.originalStart+e.originalLength-1),a=i.getStartLineNumber(e.modifiedStart),l=i.getStartColumn(e.modifiedStart),h=i.getEndLineNumber(e.modifiedStart+e.modifiedLength-1),u=i.getEndColumn(e.modifiedStart+e.modifiedLength-1);return new hc(n,r,o,s,a,l,h,u)}}class hf{constructor(e,t,i,n,r){this.originalStartLineNumber=e,this.originalEndLineNumber=t,this.modifiedStartLineNumber=i,this.modifiedEndLineNumber=n,this.charChanges=r}static createFromDiffResult(e,t,i,n,r,o,s){let a,l,h,u,d;if(0===t.originalLength?(a=i.getStartLineNumber(t.originalStart)-1,l=0):(a=i.getStartLineNumber(t.originalStart),l=i.getEndLineNumber(t.originalStart+t.originalLength-1)),0===t.modifiedLength?(h=n.getStartLineNumber(t.modifiedStart)-1,u=0):(h=n.getStartLineNumber(t.modifiedStart),u=n.getEndLineNumber(t.modifiedStart+t.modifiedLength-1)),o&&t.originalLength>0&&t.originalLength<20&&t.modifiedLength>0&&t.modifiedLength<20&&r()){let o=i.createCharSequence(e,t.originalStart,t.originalStart+t.originalLength-1),a=n.createCharSequence(e,t.modifiedStart,t.modifiedStart+t.modifiedLength-1);if(o.getElements().length>0&&a.getElements().length>0){let e=hh(o,a,r,!0).changes;s&&(e=function(e){if(e.length<=1)return e;let t=[e[0]],i=t[0];for(let n=1,r=e.length;n1&&s>1;){let n=e.charCodeAt(i-2),r=t.charCodeAt(s-2);if(n!==r)break;i--,s--}(i>1||s>1)&&this._pushTrimWhitespaceCharChange(n,r+1,1,i,o+1,1,s)}{let i=hm(e,1),s=hm(t,1),a=e.length+1,l=t.length+1;for(;i!0;let t=Date.now();return()=>Date.now()-tt))return new hE(e,t)}constructor(e,t){if(this.start=e,this.endExclusive=t,e>t)throw new nt(`Invalid range: ${this.toString()}`)}get isEmpty(){return this.start===this.endExclusive}delta(e){return new hE(this.start+e,this.endExclusive+e)}get length(){return this.endExclusive-this.start}toString(){return`[${this.start}, ${this.endExclusive})`}equals(e){return this.start===e.start&&this.endExclusive===e.endExclusive}containsRange(e){return this.start<=e.start&&e.endExclusive<=this.endExclusive}contains(e){return this.start<=e&&e ${this.seq2Range}`}join(e){return new hb(this.seq1Range.join(e.seq1Range),this.seq2Range.join(e.seq2Range))}delta(e){return 0===e?this:new hb(this.seq1Range.delta(e),this.seq2Range.delta(e))}}class hC{isValid(){return!0}}hC.instance=new hC;class hS{constructor(e){if(this.timeout=e,this.startTime=Date.now(),this.valid=!0,e<=0)throw new nt("timeout must be positive")}isValid(){let e=Date.now()-this.startTime0&&l>0&&3===o.get(a-1,l-1)&&(h+=s.get(a-1,l-1)),h+=n?n(a,l):1):h=-1;let c=Math.max(u,d,h);if(c===h){let e=a>0&&l>0?s.get(a-1,l-1):0;s.set(a,l,e+1),o.set(a,l,3)}else c===u?(s.set(a,l,0),o.set(a,l,1)):c===d&&(s.set(a,l,0),o.set(a,l,2));r.set(a,l,c)}let a=[],l=e.length,h=t.length;function u(e,t){(e+1!==l||t+1!==h)&&a.push(new hb(new hE(e+1,l),new hE(t+1,h))),l=e,h=t}let d=e.length-1,c=t.length-1;for(;d>=0&&c>=0;)3===o.get(d,c)?(u(d,c),d--,c--):1===o.get(d,c)?d--:c--;return u(-1,-1),a.reverse(),new hv(a,!1)}}function hR(e,t,i){let n=i;return n=function(e,t,i){if(0===i.length)return i;let n=[];n.push(i[0]);for(let r=1;r0&&(s=s.delta(r))}r.push(s)}return n.length>0&&r.push(n[n.length-1]),r}(e,t,n),n=function(e,t,i){if(!e.getBoundaryScore||!t.getBoundaryScore)return i;for(let n=0;n0?i[n-1]:void 0,o=i[n],s=n+1=n.start&&e.seq2Range.start-o>=r.start&&i.getElement(e.seq2Range.start-o)===i.getElement(e.seq2Range.endExclusive-o)&&o<100;)o++;o--;let s=0;for(;e.seq1Range.start+sl&&(l=h,a=n)}return e.delta(a)}class hN{compute(e,t,i=hC.instance){if(0===e.length||0===t.length)return hv.trivial(e,t);function n(i,n){for(;ie.length||d>t.length)continue;let c=n(u,d);o.set(a,c);let f=u===i?s.get(a+1):s.get(a-1);if(s.set(a,c!==u?new hO(f,u,d,c-u):f),o.get(a)===e.length&&o.get(a)-a===t.length)break t}}let l=s.get(a),h=[],u=e.length,d=t.length;for(;;){let e=l?l.x+l.length:0,t=l?l.y+l.length:0;if((e!==u||t!==d)&&h.push(new hb(new hE(e,u),new hE(t,d))),!l)break;u=l.x,d=l.y,l=l.prev}return h.reverse(),new hv(h,!1)}}class hO{constructor(e,t,i,n){this.prev=e,this.x=t,this.y=i,this.length=n}}class hL{constructor(){this.positiveArr=new Int32Array(10),this.negativeArr=new Int32Array(10)}get(e){return e<0?(e=-e-1,this.negativeArr[e]):this.positiveArr[e]}set(e,t){if(e<0){if((e=-e-1)>=this.negativeArr.length){let e=this.negativeArr;this.negativeArr=new Int32Array(2*e.length),this.negativeArr.set(e)}this.negativeArr[e]=t}else{if(e>=this.positiveArr.length){let e=this.positiveArr;this.positiveArr=new Int32Array(2*e.length),this.positiveArr.set(e)}this.positiveArr[e]=t}}}class hI{constructor(){this.positiveArr=[],this.negativeArr=[]}get(e){return e<0?(e=-e-1,this.negativeArr[e]):this.positiveArr[e]}set(e,t){e<0?(e=-e-1,this.negativeArr[e]=t):this.positiveArr[e]=t}}class hw{constructor(){this.dynamicProgrammingDiffing=new hT,this.myersDiffingAlgorithm=new hN}computeDiff(e,t,i){if(1===e.length&&0===e[0].length||1===t.length&&0===t[0].length)return{changes:[new hr(new hi(1,e.length+1),new hi(1,t.length+1),[new ho(new rv(1,1,e.length,e[0].length+1),new rv(1,1,t.length,t[0].length+1))])],hitTimeout:!1,moves:[]};let n=0===i.maxComputationTimeMs?hC.instance:new hS(i.maxComputationTimeMs),r=!i.ignoreTrimWhitespace,o=new Map;function s(e){let t=o.get(e);return void 0===t&&(t=o.size,o.set(e,t)),t}let a=e.map(e=>s(e.trim())),l=t.map(e=>s(e.trim())),h=new hx(a,e),u=new hx(l,t),d=h.length+u.length<1500?this.dynamicProgrammingDiffing.compute(h,u,n,(i,n)=>e[i]===t[n]?0===t[n].length?.1:1+Math.log(1+t[n].length):.99):this.myersDiffingAlgorithm.compute(h,u),c=d.diffs,f=d.hitTimeout;c=hR(h,u,c);let g=[],p=i=>{if(r)for(let o=0;oi.seq1Range.start-m==i.seq2Range.start-_);let o=i.seq1Range.start-m;p(o),m=i.seq1Range.endExclusive,_=i.seq2Range.endExclusive;let s=this.refineDiff(e,t,i,n,r);for(let e of(s.hitTimeout&&(f=!0),s.mappings))g.push(e)}p(e.length-m);let E=hD(g,e,t),v=[];if(i.computeMoves){let i=E.filter(e=>e.modifiedRange.isEmpty&&e.originalRange.length>=3).map(t=>new hV(t.originalRange,e)),o=new Set(E.filter(e=>e.originalRange.isEmpty&&e.modifiedRange.length>=3).map(e=>new hV(e.modifiedRange,t)));for(let s of i){let i,a=-1;for(let e of o){let t=s.computeSimilarity(e);t>a&&(a=t,i=e)}if(a>.9&&i){let a=this.refineDiff(e,t,new hb(new hE(s.range.startLineNumber-1,s.range.endLineNumberExclusive-1),new hE(i.range.startLineNumber-1,i.range.endLineNumberExclusive-1)),n,r),l=hD(a.mappings,e,t,!0);o.delete(i),v.push(new ha(new hs(s.range,i.range),l))}}}return oY(()=>{function i(e,t){if(e.lineNumber<1||e.lineNumber>t.length)return!1;let i=t[e.lineNumber-1];return!(e.column<1)&&!(e.column>i.length+1)}function n(e,t){return!(e.startLineNumber<1)&&!(e.startLineNumber>t.length+1)&&!(e.endLineNumberExclusive<1)&&!(e.endLineNumberExclusive>t.length+1)}for(let r of E){if(!r.innerChanges)return!1;for(let n of r.innerChanges){let r=i(n.modifiedRange.getStartPosition(),t)&&i(n.modifiedRange.getEndPosition(),t)&&i(n.originalRange.getStartPosition(),e)&&i(n.originalRange.getEndPosition(),e);if(!r)return!1}if(!n(r.modifiedRange,t)||!n(r.originalRange,e))return!1}return!0}),new hn(E,v,f)}refineDiff(e,t,i,n,r){let o=new hk(e,i.seq1Range,r),s=new hk(t,i.seq2Range,r),a=o.length+s.length<500?this.dynamicProgrammingDiffing.compute(o,s,n):this.myersDiffingAlgorithm.compute(o,s,n),l=a.diffs;l=hR(o,s,l),l=function(e,t,i){let n=[];for(let e of i){let t=n[n.length-1];if(!t){n.push(e);continue}e.seq1Range.start-t.seq1Range.endExclusive<=2||e.seq2Range.start-t.seq2Range.endExclusive<=2?n[n.length-1]=new hb(t.seq1Range.join(e.seq1Range),t.seq2Range.join(e.seq2Range)):n.push(e)}return n}(0,0,l=function(e,t,i){let n;let r=[];function o(){if(!n)return;let e=n.s1Range.length-n.deleted;n.s2Range.length,n.added,Math.max(n.deleted,n.added)+(n.count-1)>e&&r.push(new hb(n.s1Range,n.s2Range)),n=void 0}for(let r of i){function s(e,t){var i,s,a,l;if(!n||!n.s1Range.containsRange(e)||!n.s2Range.containsRange(t)){if(n&&!(n.s1Range.endExclusive0||t.length>0;){let n;let r=e[0],o=t[0];n=r&&(!o||r.seq1Range.start0&&i[i.length-1].seq1Range.endExclusive>=n.seq1Range.start?i[i.length-1]=i[i.length-1].join(n):i.push(n)}return i}(i,r);return a}(o,s,l)),l=function(e,t,i){let n,r=i;if(0===r.length)return r;let o=0;do{n=!1;let i=[r[0]];for(let o=1;o5||r.length>500)return!1;let l=e.getText(r).trim();if(l.length>20||l.split(/\r\n|\r|\n/).length>1)return!1;let h=e.countLinesIn(i.seq1Range),u=i.seq1Range.length,d=t.countLinesIn(i.seq2Range),c=i.seq2Range.length,f=e.countLinesIn(n.seq1Range),g=n.seq1Range.length,p=t.countLinesIn(n.seq2Range),m=n.seq2Range.length;function _(e){return Math.min(e,130)}return Math.pow(Math.pow(_(40*h+u),1.5)+Math.pow(_(40*d+c),1.5),1.5)+Math.pow(Math.pow(_(40*f+g),1.5)+Math.pow(_(40*p+m),1.5),1.5)>74184.96480721243}(a,s);l?(n=!0,i[i.length-1]=i[i.length-1].join(s)):i.push(s)}r=i}while(o++<10&&n);return r}(o,s,l);let h=l.map(e=>new ho(o.translateRange(e.seq1Range),s.translateRange(e.seq2Range)));return{mappings:h,hitTimeout:a.hitTimeout}}}function hD(e,t,i,n=!1){let r=[];for(let n of function*(e,t){let i,n;for(let r of e)void 0!==n&&t(n,r)?i.push(r):(i&&(yield i),i=[r]),n=r;i&&(yield i)}(e.map(e=>(function(e,t,i){let n=0,r=0;1===e.modifiedRange.endColumn&&1===e.originalRange.endColumn&&e.originalRange.startLineNumber+n<=e.originalRange.endLineNumber&&e.modifiedRange.startLineNumber+n<=e.modifiedRange.endLineNumber&&(r=-1),e.modifiedRange.startColumn-1>=i[e.modifiedRange.startLineNumber-1].length&&e.originalRange.startColumn-1>=t[e.originalRange.startLineNumber-1].length&&e.originalRange.startLineNumber<=e.originalRange.endLineNumber+r&&e.modifiedRange.startLineNumber<=e.modifiedRange.endLineNumber+r&&(n=1);let o=new hi(e.originalRange.startLineNumber+n,e.originalRange.endLineNumber+1+r),s=new hi(e.modifiedRange.startLineNumber+n,e.modifiedRange.endLineNumber+1+r);return new hr(o,s,[e])})(e,t,i)),(e,t)=>e.originalRange.overlapOrTouch(t.originalRange)||e.modifiedRange.overlapOrTouch(t.modifiedRange))){let e=n[0],t=n[n.length-1];r.push(new hr(e.originalRange.join(t.originalRange),e.modifiedRange.join(t.modifiedRange),n.map(e=>e.innerChanges[0])))}return oY(()=>(!!n||!(r.length>0)||r[0].originalRange.startLineNumber===r[0].modifiedRange.startLineNumber)&&o$(r,(e,t)=>t.originalRange.startLineNumber-e.originalRange.endLineNumberExclusive==t.modifiedRange.startLineNumber-e.modifiedRange.endLineNumberExclusive&&e.originalRange.endLineNumberExclusive0&&t.endExclusive>=e.length&&(t=new hE(t.start-1,t.endExclusive),n=!0),this.lineRange=t;for(let t=this.lineRange.start;tString.fromCharCode(e)).join("")}getElement(e){return this.elements[e]}get length(){return this.elements.length}getBoundaryScore(e){let t=hB(e>0?this.elements[e-1]:-1),i=hB(ee?i=n:t=n+1}let n=0===t?0:this.firstCharOffsetByLineMinusOne[t-1];return new rE(this.lineRange.start+t+1,e-n+1+this.offsetByLine[t])}translateRange(e){return rv.fromPositions(this.translateOffset(e.start),this.translateOffset(e.endExclusive))}findWordContaining(e){if(e<0||e>=this.elements.length||!hP(this.elements[e]))return;let t=e;for(;t>0&&hP(this.elements[t-1]);)t--;let i=e;for(;i=97&&e<=122||e>=65&&e<=90||e>=48&&e<=57}let hF={0:0,1:0,2:0,3:10,4:2,5:3,6:10,7:10};function hB(e){if(10===e)return 7;if(13===e)return 6;if(32===e||9===e)return 5;if(e>=97&&e<=122)return 0;if(e>=65&&e<=90)return 1;if(e>=48&&e<=57)return 2;if(-1===e)return 3;else return 4}let hU=new Map;function hH(e){let t=hU.get(e);return void 0===t&&(t=hU.size,hU.set(e,t)),t}class hV{constructor(e,t){this.range=e,this.lines=t,this.histogram=[];let i=0;for(let n=e.startLineNumber-1;nnew hl,getAdvanced:()=>new hw};function hG(e,t){let i=Math.pow(10,t);return Math.round(e*i)/i}class hj{constructor(e,t,i,n=1){this._rgbaBrand=void 0,this.r=0|Math.min(255,Math.max(0,e)),this.g=0|Math.min(255,Math.max(0,t)),this.b=0|Math.min(255,Math.max(0,i)),this.a=hG(Math.max(Math.min(1,n),0),3)}static equals(e,t){return e.r===t.r&&e.g===t.g&&e.b===t.b&&e.a===t.a}}class hz{constructor(e,t,i,n){this._hslaBrand=void 0,this.h=0|Math.max(Math.min(360,e),0),this.s=hG(Math.max(Math.min(1,t),0),3),this.l=hG(Math.max(Math.min(1,i),0),3),this.a=hG(Math.max(Math.min(1,n),0),3)}static equals(e,t){return e.h===t.h&&e.s===t.s&&e.l===t.l&&e.a===t.a}static fromRGBA(e){let t=e.r/255,i=e.g/255,n=e.b/255,r=e.a,o=Math.max(t,i,n),s=Math.min(t,i,n),a=0,l=0,h=(s+o)/2,u=o-s;if(u>0){switch(l=Math.min(h<=.5?u/(2*h):u/(2-2*h),1),o){case t:a=(i-n)/u+(i1&&(i-=1),i<1/6)?e+(t-e)*6*i:i<.5?t:i<2/3?e+(t-e)*(2/3-i)*6:e}static toRGBA(e){let t,i,n;let r=e.h/360,{s:o,l:s,a}=e;if(0===o)t=i=n=s;else{let e=s<.5?s*(1+o):s+o-s*o,a=2*s-e;t=hz._hue2rgb(a,e,r+1/3),i=hz._hue2rgb(a,e,r),n=hz._hue2rgb(a,e,r-1/3)}return new hj(Math.round(255*t),Math.round(255*i),Math.round(255*n),a)}}class hK{constructor(e,t,i,n){this._hsvaBrand=void 0,this.h=0|Math.max(Math.min(360,e),0),this.s=hG(Math.max(Math.min(1,t),0),3),this.v=hG(Math.max(Math.min(1,i),0),3),this.a=hG(Math.max(Math.min(1,n),0),3)}static equals(e,t){return e.h===t.h&&e.s===t.s&&e.v===t.v&&e.a===t.a}static fromRGBA(e){let t;let i=e.r/255,n=e.g/255,r=e.b/255,o=Math.max(i,n,r),s=Math.min(i,n,r),a=o-s,l=0===o?0:a/o;return t=0===a?0:o===i?((n-r)/a%6+6)%6:o===n?(r-i)/a+2:(i-n)/a+4,new hK(Math.round(60*t),l,o,e.a)}static toRGBA(e){let{h:t,s:i,v:n,a:r}=e,o=n*i,s=o*(1-Math.abs(t/60%2-1)),a=n-o,[l,h,u]=[0,0,0];return t<60?(l=o,h=s):t<120?(l=s,h=o):t<180?(h=o,u=s):t<240?(h=s,u=o):t<300?(l=s,u=o):t<=360&&(l=o,u=s),l=Math.round((l+a)*255),h=Math.round((h+a)*255),u=Math.round((u+a)*255),new hj(l,h,u,r)}}class hY{static fromHex(e){return hY.Format.CSS.parseHex(e)||hY.red}static equals(e,t){return!e&&!t||!!e&&!!t&&e.equals(t)}get hsla(){return this._hsla?this._hsla:hz.fromRGBA(this.rgba)}get hsva(){return this._hsva?this._hsva:hK.fromRGBA(this.rgba)}constructor(e){if(e){if(e instanceof hj)this.rgba=e;else if(e instanceof hz)this._hsla=e,this.rgba=hz.toRGBA(e);else if(e instanceof hK)this._hsva=e,this.rgba=hK.toRGBA(e);else throw Error("Invalid color ctor argument")}else throw Error("Color needs a value")}equals(e){return!!e&&hj.equals(this.rgba,e.rgba)&&hz.equals(this.hsla,e.hsla)&&hK.equals(this.hsva,e.hsva)}getRelativeLuminance(){let e=hY._relativeLuminanceForComponent(this.rgba.r),t=hY._relativeLuminanceForComponent(this.rgba.g),i=hY._relativeLuminanceForComponent(this.rgba.b);return hG(.2126*e+.7152*t+.0722*i,4)}static _relativeLuminanceForComponent(e){let t=e/255;return t<=.03928?t/12.92:Math.pow((t+.055)/1.055,2.4)}isLighter(){let e=(299*this.rgba.r+587*this.rgba.g+114*this.rgba.b)/1e3;return e>=128}isLighterThan(e){let t=this.getRelativeLuminance(),i=e.getRelativeLuminance();return t>i}isDarkerThan(e){let t=this.getRelativeLuminance(),i=e.getRelativeLuminance();return tthis._lines.length)t=this._lines.length,i=this._lines[t-1].length+1,n=!0;else{let e=this._lines[t-1].length+1;i<1?(i=1,n=!0):i>e&&(i=e,n=!0)}return n?{lineNumber:t,column:i}:e}}class h2{constructor(e,t){this._host=e,this._models=Object.create(null),this._foreignModuleFactory=t,this._foreignModule=null}dispose(){this._models=Object.create(null)}_getModel(e){return this._models[e]}_getModels(){let e=[];return Object.keys(this._models).forEach(t=>e.push(this._models[t])),e}acceptNewModel(e){this._models[e.url]=new h1(rl.parse(e.url),e.lines,e.EOL,e.versionId)}acceptModelChanged(e,t){if(!this._models[e])return;let i=this._models[e];i.onEvents(t)}acceptRemovedModel(e){this._models[e]&&delete this._models[e]}computeUnicodeHighlights(e,t,i){return h0(this,void 0,void 0,function*(){let n=this._getModel(e);return n?l7.computeUnicodeHighlights(n,t,i):{ranges:[],hasMore:!1,ambiguousCharacterCount:0,invisibleCharacterCount:0,nonBasicAsciiCharacterCount:0}})}computeDiff(e,t,i,n){return h0(this,void 0,void 0,function*(){let r=this._getModel(e),o=this._getModel(t);return r&&o?h2.computeDiff(r,o,i,n):null})}static computeDiff(e,t,i,n){let r="advanced"===n?hW.getAdvanced():hW.getLegacy(),o=e.getLinesContent(),s=t.getLinesContent(),a=r.computeDiff(o,s,i),l=!(a.changes.length>0)&&this._modelsAreIdentical(e,t);function h(e){return e.map(e=>{var t;return[e.originalRange.startLineNumber,e.originalRange.endLineNumberExclusive,e.modifiedRange.startLineNumber,e.modifiedRange.endLineNumberExclusive,null===(t=e.innerChanges)||void 0===t?void 0:t.map(e=>[e.originalRange.startLineNumber,e.originalRange.startColumn,e.originalRange.endLineNumber,e.originalRange.endColumn,e.modifiedRange.startLineNumber,e.modifiedRange.startColumn,e.modifiedRange.endLineNumber,e.modifiedRange.endColumn])]})}return{identical:l,quitEarly:a.hitTimeout,changes:h(a.changes),moves:a.moves.map(e=>[e.lineRangeMapping.original.startLineNumber,e.lineRangeMapping.original.endLineNumberExclusive,e.lineRangeMapping.modified.startLineNumber,e.lineRangeMapping.modified.endLineNumberExclusive,h(e.changes)])}}static _modelsAreIdentical(e,t){let i=e.getLineCount(),n=t.getLineCount();if(i!==n)return!1;for(let n=1;n<=i;n++){let i=e.getLineContent(n),r=t.getLineContent(n);if(i!==r)return!1}return!0}computeMoreMinimalEdits(e,t,i){return h0(this,void 0,void 0,function*(){let n;let r=this._getModel(e);if(!r)return t;let o=[];for(let{range:e,text:a,eol:l}of t=t.slice(0).sort((e,t)=>{if(e.range&&t.range)return rv.compareRangesUsingStarts(e.range,t.range);let i=e.range?0:1,n=t.range?0:1;return i-n})){var s;if("number"==typeof l&&(n=l),rv.isEmpty(e)&&!a)continue;let t=r.getValueInRange(e);if(t===(a=a.replace(/\r\n|\n|\r/g,r.eol)))continue;if(Math.max(a.length,t.length)>h2._diffLimit){o.push({range:e,text:a});continue}let h=(s=a,new lH(new lP(t),new lP(s)).ComputeDiff(i).changes),u=r.offsetAt(rv.lift(e).getStartPosition());for(let e of h){let t=r.positionAt(u+e.originalStart),i=r.positionAt(u+e.originalStart+e.originalLength),n={text:a.substr(e.modifiedStart,e.modifiedLength),range:{startLineNumber:t.lineNumber,startColumn:t.column,endLineNumber:i.lineNumber,endColumn:i.column}};r.getValueInRange(n.range)!==n.text&&o.push(n)}}return"number"==typeof n&&o.push({eol:n,text:"",range:{startLineNumber:0,startColumn:0,endLineNumber:0,endColumn:0}}),o})}computeLinks(e){return h0(this,void 0,void 0,function*(){let t=this._getModel(e);return t?t&&"function"==typeof t.getLineCount&&"function"==typeof t.getLineContent?lJ.computeLinks(t):[]:null})}computeDefaultDocumentColors(e){return h0(this,void 0,void 0,function*(){let t=this._getModel(e);return t?t&&"function"==typeof t.getValue&&"function"==typeof t.positionAt?function(e){let t=[],i=hJ(e,/\b(rgb|rgba|hsl|hsla)(\([0-9\s,.\%]*\))|(#)([A-Fa-f0-9]{3})\b|(#)([A-Fa-f0-9]{4})\b|(#)([A-Fa-f0-9]{6})\b|(#)([A-Fa-f0-9]{8})\b/gm);if(i.length>0)for(let n of i){let i;let r=n.filter(e=>void 0!==e),o=r[1],s=r[2];if(s){if("rgb"===o){let t=/^\(\s*(25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9][0-9]|[0-9])\s*,\s*(25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9][0-9]|[0-9])\s*,\s*(25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9][0-9]|[0-9])\s*\)$/gm;i=hZ(hX(e,n),hJ(s,t),!1)}else if("rgba"===o){let t=/^\(\s*(25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9][0-9]|[0-9])\s*,\s*(25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9][0-9]|[0-9])\s*,\s*(25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9][0-9]|[0-9])\s*,\s*(0[.][0-9]+|[.][0-9]+|[01][.]|[01])\s*\)$/gm;i=hZ(hX(e,n),hJ(s,t),!0)}else if("hsl"===o){let t=/^\(\s*(36[0]|3[0-5][0-9]|[12][0-9][0-9]|[1-9]?[0-9])\s*,\s*(100|\d{1,2}[.]\d*|\d{1,2})%\s*,\s*(100|\d{1,2}[.]\d*|\d{1,2})%\s*\)$/gm;i=hQ(hX(e,n),hJ(s,t),!1)}else if("hsla"===o){let t=/^\(\s*(36[0]|3[0-5][0-9]|[12][0-9][0-9]|[1-9]?[0-9])\s*,\s*(100|\d{1,2}[.]\d*|\d{1,2})%\s*,\s*(100|\d{1,2}[.]\d*|\d{1,2})%\s*,\s*(0[.][0-9]+|[.][0-9]+|[01][.]|[01])\s*\)$/gm;i=hQ(hX(e,n),hJ(s,t),!0)}else"#"===o&&(i=function(e,t){if(!e)return;let i=hY.Format.CSS.parseHex(t);if(i)return{range:e,color:hq(i.rgba.r,i.rgba.g,i.rgba.b,i.rgba.a)}}(hX(e,n),o+s));i&&t.push(i)}}return t}(t):[]:null})}textualSuggest(e,t,i,n){return h0(this,void 0,void 0,function*(){let r=new nE,o=new RegExp(i,n),s=new Set;i:for(let i of e){let e=this._getModel(i);if(e){for(let i of e.words(o))if(i!==t&&isNaN(Number(i))&&(s.add(i),s.size>h2._suggestionsLimit))break i}}return{words:Array.from(s),duration:r.elapsed()}})}computeWordRanges(e,t,i,n){return h0(this,void 0,void 0,function*(){let r=this._getModel(e);if(!r)return Object.create(null);let o=new RegExp(i,n),s=Object.create(null);for(let e=t.startLineNumber;ethis._host.fhr(e,t));return this._foreignModuleFactory?(this._foreignModule=this._foreignModuleFactory({host:n,getMirrorModels:()=>this._getModels()},t),Promise.resolve((0,oq.$E)(this._foreignModule))):Promise.reject(Error("Unexpected usage"))}fmr(e,t){if(!this._foreignModule||"function"!=typeof this._foreignModule[e])return Promise.reject(Error("Missing requestHandler or method: "+e));try{return Promise.resolve(this._foreignModule[e].apply(this._foreignModule,t))}catch(e){return Promise.reject(e)}}}h2._diffLimit=1e5,h2._suggestionsLimit=1e4,"function"==typeof importScripts&&(globalThis.monaco=rk());let h5=oG("textResourceConfigurationService"),h4=oG("textResourcePropertiesService"),h3=oG("logService");(eS=t0||(t0={}))[eS.Off=0]="Off",eS[eS.Trace=1]="Trace",eS[eS.Debug=2]="Debug",eS[eS.Info=3]="Info",eS[eS.Warning=4]="Warning",eS[eS.Error=5]="Error";let h6=t0.Info;class h9 extends nc{constructor(){super(...arguments),this.level=h6,this._onDidChangeLogLevel=this._register(new ny),this.onDidChangeLogLevel=this._onDidChangeLogLevel.event}setLevel(e){this.level!==e&&(this.level=e,this._onDidChangeLogLevel.fire(this.level))}getLevel(){return this.level}checkLogLevel(e){return this.level!==t0.Off&&this.level<=e}}class h8 extends h9{constructor(e=h6,t=!0){super(),this.useColors=t,this.setLevel(e)}trace(e,...t){this.checkLogLevel(t0.Trace)&&(this.useColors?console.log("%cTRACE","color: #888",e,...t):console.log(e,...t))}debug(e,...t){this.checkLogLevel(t0.Debug)&&(this.useColors?console.log("%cDEBUG","background: #eee; color: #888",e,...t):console.log(e,...t))}info(e,...t){this.checkLogLevel(t0.Info)&&(this.useColors?console.log("%c INFO","color: #33f",e,...t):console.log(e,...t))}warn(e,...t){this.checkLogLevel(t0.Warning)&&(this.useColors?console.log("%c WARN","color: #993",e,...t):console.log(e,...t))}error(e,...t){this.checkLogLevel(t0.Error)&&(this.useColors?console.log("%c ERR","color: #f33",e,...t):console.error(e,...t))}dispose(){}}class h7 extends h9{constructor(e){super(),this.loggers=e,e.length&&this.setLevel(e[0].getLevel())}setLevel(e){for(let t of this.loggers)t.setLevel(e);super.setLevel(e)}trace(e,...t){for(let i of this.loggers)i.trace(e,...t)}debug(e,...t){for(let i of this.loggers)i.debug(e,...t)}info(e,...t){for(let i of this.loggers)i.info(e,...t)}warn(e,...t){for(let i of this.loggers)i.warn(e,...t)}error(e,...t){for(let i of this.loggers)i.error(e,...t)}dispose(){for(let e of this.loggers)e.dispose()}}new sA("logLevel",function(e){switch(e){case t0.Trace:return"trace";case t0.Debug:return"debug";case t0.Info:return"info";case t0.Warning:return"warn";case t0.Error:return"error";case t0.Off:return"off"}}(t0.Info));let ue=oG("ILanguageFeaturesService");var ut=function(e,t){return function(i,n){t(i,n,e)}},ui=function(e,t,i,n){return new(i||(i=Promise))(function(r,o){function s(e){try{l(n.next(e))}catch(e){o(e)}}function a(e){try{l(n.throw(e))}catch(e){o(e)}}function l(e){var t;e.done?r(e.value):((t=e.value)instanceof i?t:new i(function(e){e(t)})).then(s,a)}l((n=n.apply(e,t||[])).next())})};function un(e,t){let i=e.getModel(t);return!(!i||i.isTooLargeForSyncing())}let ur=class extends nc{constructor(e,t,i,n,r){super(),this._modelService=e,this._workerManager=this._register(new us(this._modelService,n)),this._logService=i,this._register(r.linkProvider.register({language:"*",hasAccessToAllModels:!0},{provideLinks:(e,t)=>un(this._modelService,e.uri)?this._workerManager.withWorker().then(t=>t.computeLinks(e.uri)).then(e=>e&&{links:e}):Promise.resolve({links:[]})})),this._register(r.completionProvider.register("*",new uo(this._workerManager,t,this._modelService,n)))}dispose(){super.dispose()}canComputeUnicodeHighlights(e){return un(this._modelService,e)}computedUnicodeHighlights(e,t,i){return this._workerManager.withWorker().then(n=>n.computedUnicodeHighlights(e,t,i))}computeDiff(e,t,i,n){return ui(this,void 0,void 0,function*(){let r=yield this._workerManager.withWorker().then(r=>r.computeDiff(e,t,i,n));if(!r)return null;let o={identical:r.identical,quitEarly:r.quitEarly,changes:s(r.changes),moves:r.moves.map(e=>new ha(new hs(new hi(e[0],e[1]),new hi(e[2],e[3])),s(e[4])))};return o;function s(e){return e.map(e=>{var t;return new hr(new hi(e[0],e[1]),new hi(e[2],e[3]),null===(t=e[4])||void 0===t?void 0:t.map(e=>new ho(new rv(e[0],e[1],e[2],e[3]),new rv(e[4],e[5],e[6],e[7]))))})}})}computeMoreMinimalEdits(e,t,i=!1){if(!(0,sX.Of)(t))return Promise.resolve(void 0);{if(!un(this._modelService,e))return Promise.resolve(t);let n=nE.create(),r=this._workerManager.withWorker().then(n=>n.computeMoreMinimalEdits(e,t,i));return r.finally(()=>this._logService.trace("FORMAT#computeMoreMinimalEdits",e.toString(!0),n.elapsed())),Promise.race([r,ls(1e3).then(()=>t)])}}canNavigateValueSet(e){return un(this._modelService,e)}navigateValueSet(e,t,i){return this._workerManager.withWorker().then(n=>n.navigateValueSet(e,t,i))}canComputeWordRanges(e){return un(this._modelService,e)}computeWordRanges(e,t){return this._workerManager.withWorker().then(i=>i.computeWordRanges(e,t))}};ur=function(e,t,i,n){var r,o=arguments.length,s=o<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,i,n);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(s=(o<3?r(s):o>3?r(t,i,s):r(t,i))||s);return o>3&&s&&Object.defineProperty(t,i,s),s}([ut(0,a3),ut(1,h5),ut(2,h3),ut(3,aj),ut(4,ue)],ur);class uo{constructor(e,t,i,n){this.languageConfigurationService=n,this._debugDisplayName="wordbasedCompletions",this._workerManager=e,this._configurationService=t,this._modelService=i}provideCompletionItems(e,t){return ui(this,void 0,void 0,function*(){let i=this._configurationService.getValue(e.uri,t,"editor");if(!i.wordBasedSuggestions)return;let n=[];if("currentDocument"===i.wordBasedSuggestionsMode)un(this._modelService,e.uri)&&n.push(e.uri);else for(let t of this._modelService.getModels())un(this._modelService,t.uri)&&(t===e?n.unshift(t.uri):("allDocuments"===i.wordBasedSuggestionsMode||t.getLanguageId()===e.getLanguageId())&&n.push(t.uri));if(0===n.length)return;let r=this.languageConfigurationService.getLanguageConfiguration(e.getLanguageId()).getWordDefinition(),o=e.getWordAtPosition(t),s=o?new rv(t.lineNumber,o.startColumn,t.lineNumber,o.endColumn):rv.fromPositions(t),a=s.setEndPosition(t.lineNumber,t.column),l=yield this._workerManager.withWorker(),h=yield l.textualSuggest(n,null==o?void 0:o.word,r);if(h)return{duration:h.duration,suggestions:h.words.map(e=>({kind:18,label:e,insertText:e,range:{insert:a,replace:s}}))}})}}class us extends nc{constructor(e,t){super(),this.languageConfigurationService=t,this._modelService=e,this._editorWorkerClient=null,this._lastWorkerUsedTime=new Date().getTime();let i=this._register(new lh);i.cancelAndSet(()=>this._checkStopIdleWorker(),Math.round(15e4)),this._register(this._modelService.onModelRemoved(e=>this._checkStopEmptyWorker()))}dispose(){this._editorWorkerClient&&(this._editorWorkerClient.dispose(),this._editorWorkerClient=null),super.dispose()}_checkStopEmptyWorker(){if(!this._editorWorkerClient)return;let e=this._modelService.getModels();0===e.length&&(this._editorWorkerClient.dispose(),this._editorWorkerClient=null)}_checkStopIdleWorker(){if(!this._editorWorkerClient)return;let e=new Date().getTime()-this._lastWorkerUsedTime;e>3e5&&(this._editorWorkerClient.dispose(),this._editorWorkerClient=null)}withWorker(){return this._lastWorkerUsedTime=new Date().getTime(),this._editorWorkerClient||(this._editorWorkerClient=new uu(this._modelService,!1,"editorWorkerService",this.languageConfigurationService)),Promise.resolve(this._editorWorkerClient)}}class ua extends nc{constructor(e,t,i){if(super(),this._syncedModels=Object.create(null),this._syncedModelsLastUsedTime=Object.create(null),this._proxy=e,this._modelService=t,!i){let e=new lh;e.cancelAndSet(()=>this._checkStopModelSync(),Math.round(3e4)),this._register(e)}}dispose(){for(let e in this._syncedModels)nl(this._syncedModels[e]);this._syncedModels=Object.create(null),this._syncedModelsLastUsedTime=Object.create(null),super.dispose()}ensureSyncedResources(e,t){for(let i of e){let e=i.toString();this._syncedModels[e]||this._beginModelSync(i,t),this._syncedModels[e]&&(this._syncedModelsLastUsedTime[e]=new Date().getTime())}}_checkStopModelSync(){let e=new Date().getTime(),t=[];for(let i in this._syncedModelsLastUsedTime){let n=e-this._syncedModelsLastUsedTime[i];n>6e4&&t.push(i)}for(let e of t)this._stopModelSync(e)}_beginModelSync(e,t){let i=this._modelService.getModel(e);if(!i||!t&&i.isTooLargeForSyncing())return;let n=e.toString();this._proxy.acceptNewModel({url:i.uri.toString(),lines:i.getLinesContent(),EOL:i.getEOL(),versionId:i.getVersionId()});let r=new nd;r.add(i.onDidChangeContent(e=>{this._proxy.acceptModelChanged(n.toString(),e)})),r.add(i.onWillDispose(()=>{this._stopModelSync(n)})),r.add(nu(()=>{this._proxy.acceptRemovedModel(n)})),this._syncedModels[n]=r}_stopModelSync(e){let t=this._syncedModels[e];delete this._syncedModels[e],delete this._syncedModelsLastUsedTime[e],nl(t)}}class ul{constructor(e){this._instance=e,this._proxyObj=Promise.resolve(this._instance)}dispose(){this._instance.dispose()}getProxyObject(){return this._proxyObj}}class uh{constructor(e){this._workerClient=e}fhr(e,t){return this._workerClient.fhr(e,t)}}class uu extends nc{constructor(e,t,i,n){super(),this.languageConfigurationService=n,this._disposed=!1,this._modelService=e,this._keepIdleModels=t,this._workerFactory=new lO(i),this._worker=null,this._modelManager=null}fhr(e,t){throw Error("Not implemented!")}_getOrCreateWorker(){if(!this._worker)try{this._worker=this._register(new lS(this._workerFactory,"vs/editor/common/services/editorSimpleWorker",new uh(this)))}catch(e){lp(e),this._worker=new ul(new h2(new uh(this),null))}return this._worker}_getProxy(){return this._getOrCreateWorker().getProxyObject().then(void 0,e=>(lp(e),this._worker=new ul(new h2(new uh(this),null)),this._getOrCreateWorker().getProxyObject()))}_getOrCreateModelManager(e){return this._modelManager||(this._modelManager=this._register(new ua(e,this._modelService,this._keepIdleModels))),this._modelManager}_withSyncedResources(e,t=!1){return ui(this,void 0,void 0,function*(){return this._disposed?Promise.reject(function(){let e=Error(i4);return e.name=e.message,e}()):this._getProxy().then(i=>(this._getOrCreateModelManager(i).ensureSyncedResources(e,t),i))})}computedUnicodeHighlights(e,t,i){return this._withSyncedResources([e]).then(n=>n.computeUnicodeHighlights(e.toString(),t,i))}computeDiff(e,t,i,n){return this._withSyncedResources([e,t],!0).then(r=>r.computeDiff(e.toString(),t.toString(),i,n))}computeMoreMinimalEdits(e,t,i){return this._withSyncedResources([e]).then(n=>n.computeMoreMinimalEdits(e.toString(),t,i))}computeLinks(e){return this._withSyncedResources([e]).then(t=>t.computeLinks(e.toString()))}computeDefaultDocumentColors(e){return this._withSyncedResources([e]).then(t=>t.computeDefaultDocumentColors(e.toString()))}textualSuggest(e,t,i){return ui(this,void 0,void 0,function*(){let n=yield this._withSyncedResources(e),r=i.source,o=rj(i);return n.textualSuggest(e.map(e=>e.toString()),t,r,o)})}computeWordRanges(e,t){return this._withSyncedResources([e]).then(i=>{let n=this._modelService.getModel(e);if(!n)return Promise.resolve(null);let r=this.languageConfigurationService.getLanguageConfiguration(n.getLanguageId()).getWordDefinition(),o=r.source,s=rj(r);return i.computeWordRanges(e.toString(),t,o,s)})}navigateValueSet(e,t,i){return this._withSyncedResources([e]).then(n=>{let r=this._modelService.getModel(e);if(!r)return null;let o=this.languageConfigurationService.getLanguageConfiguration(r.getLanguageId()).getWordDefinition(),s=o.source,a=rj(o);return n.navigateValueSet(e.toString(),t,i,s,a)})}dispose(){super.dispose(),this._disposed=!0}}class ud extends uu{constructor(e,t,i){super(e,i.keepIdleModels||!1,i.label,t),this._foreignModuleId=i.moduleId,this._foreignModuleCreateData=i.createData||null,this._foreignModuleHost=i.host||null,this._foreignProxy=null}fhr(e,t){if(!this._foreignModuleHost||"function"!=typeof this._foreignModuleHost[e])return Promise.reject(Error("Missing method "+e+" or missing main thread foreign host."));try{return Promise.resolve(this._foreignModuleHost[e].apply(this._foreignModuleHost,t))}catch(e){return Promise.reject(e)}}_getForeignProxy(){return this._foreignProxy||(this._foreignProxy=this._getProxy().then(e=>{let t=this._foreignModuleHost?(0,oq.$E)(this._foreignModuleHost):[];return e.loadForeignModule(this._foreignModuleId,this._foreignModuleCreateData,t).then(t=>{this._foreignModuleCreateData=null;let i=(t,i)=>e.fmr(t,i),n=(e,t)=>function(){let i=Array.prototype.slice.call(arguments,0);return t(e,i)},r={};for(let e of t)r[e]=n(e,i);return r})})),this._foreignProxy}getProxy(){return this._getForeignProxy()}withSyncedResources(e){return this._withSyncedResources(e).then(e=>this.getProxy())}}class uc{static getLanguageId(e){return(255&e)>>>0}static getTokenType(e){return(768&e)>>>8}static containsBalancedBrackets(e){return(1024&e)!=0}static getFontStyle(e){return(30720&e)>>>11}static getForeground(e){return(16744448&e)>>>15}static getBackground(e){return(4278190080&e)>>>24}static getClassNameFromMetadata(e){let t=this.getForeground(e),i="mtk"+t,n=this.getFontStyle(e);return 1&n&&(i+=" mtki"),2&n&&(i+=" mtkb"),4&n&&(i+=" mtku"),8&n&&(i+=" mtks"),i}static getInlineStyleFromMetadata(e,t){let i=this.getForeground(e),n=this.getFontStyle(e),r=`color: ${t[i]};`;1&n&&(r+="font-style: italic;"),2&n&&(r+="font-weight: bold;");let o="";return 4&n&&(o+=" underline"),8&n&&(o+=" line-through"),o&&(r+=`text-decoration:${o};`),r}static getPresentationFromMetadata(e){let t=this.getForeground(e),i=this.getFontStyle(e);return{foreground:t,italic:!!(1&i),bold:!!(2&i),underline:!!(4&i),strikethrough:!!(8&i)}}}class uf{static createEmpty(e,t){let i=uf.defaultTokenMetadata,n=new Uint32Array(2);return n[0]=e.length,n[1]=i,new uf(n,e,t)}constructor(e,t,i){this._lineTokensBrand=void 0,this._tokens=e,this._tokensCount=this._tokens.length>>>1,this._text=t,this._languageIdCodec=i}equals(e){return e instanceof uf&&this.slicedEquals(e,0,this._tokensCount)}slicedEquals(e,t,i){if(this._text!==e._text||this._tokensCount!==e._tokensCount)return!1;let n=t<<1,r=n+(i<<1);for(let t=n;t0?this._tokens[e-1<<1]:0}getMetadata(e){let t=this._tokens[(e<<1)+1];return t}getLanguageId(e){let t=this._tokens[(e<<1)+1],i=uc.getLanguageId(t);return this._languageIdCodec.decodeLanguageId(i)}getStandardTokenType(e){let t=this._tokens[(e<<1)+1];return uc.getTokenType(t)}getForeground(e){let t=this._tokens[(e<<1)+1];return uc.getForeground(t)}getClassName(e){let t=this._tokens[(e<<1)+1];return uc.getClassNameFromMetadata(t)}getInlineStyle(e,t){let i=this._tokens[(e<<1)+1];return uc.getInlineStyleFromMetadata(i,t)}getPresentation(e){let t=this._tokens[(e<<1)+1];return uc.getPresentationFromMetadata(t)}getEndOffset(e){return this._tokens[e<<1]}findTokenIndexAtOffset(e){return uf.findIndexInTokensArray(this._tokens,e)}inflate(){return this}sliceAndInflate(e,t,i){return new ug(this,e,t,i)}static convertToEndOffset(e,t){let i=e.length>>>1,n=i-1;for(let t=0;t>>1)-1;for(;it&&(n=r)}return i}withInserted(e){if(0===e.length)return this;let t=0,i=0,n="",r=[],o=0;for(;;){let s=to){n+=this._text.substring(o,a.offset);let e=this._tokens[(t<<1)+1];r.push(n.length,e),o=a.offset}n+=a.text,r.push(n.length,a.tokenMetadata),i++}else break}return new uf(new Uint32Array(r),n,this._languageIdCodec)}}uf.defaultTokenMetadata=33587200;class ug{constructor(e,t,i,n){this._source=e,this._startOffset=t,this._endOffset=i,this._deltaOffset=n,this._firstTokenIndex=e.findTokenIndexAtOffset(t),this._tokensCount=0;for(let t=this._firstTokenIndex,n=e.getCount();t=i)break;this._tokensCount++}}getMetadata(e){return this._source.getMetadata(this._firstTokenIndex+e)}getLanguageId(e){return this._source.getLanguageId(this._firstTokenIndex+e)}getLineContent(){return this._source.getLineContent().substring(this._startOffset,this._endOffset)}equals(e){return e instanceof ug&&this._startOffset===e._startOffset&&this._endOffset===e._endOffset&&this._deltaOffset===e._deltaOffset&&this._source.slicedEquals(e._source,this._firstTokenIndex,this._tokensCount)}getCount(){return this._tokensCount}getForeground(e){return this._source.getForeground(this._firstTokenIndex+e)}getEndOffset(e){let t=this._source.getEndOffset(this._firstTokenIndex+e);return Math.min(this._endOffset,t)-this._startOffset+this._deltaOffset}getClassName(e){return this._source.getClassName(this._firstTokenIndex+e)}getInlineStyle(e,t){return this._source.getInlineStyle(this._firstTokenIndex+e,t)}getPresentation(e){return this._source.getPresentation(this._firstTokenIndex+e)}findTokenIndexAtOffset(e){return this._source.findTokenIndexAtOffset(e+this._startOffset-this._deltaOffset)-this._firstTokenIndex}}class up{constructor(e,t,i,n){this.startColumn=e,this.endColumn=t,this.className=i,this.type=n,this._lineDecorationBrand=void 0}static _equals(e,t){return e.startColumn===t.startColumn&&e.endColumn===t.endColumn&&e.className===t.className&&e.type===t.type}static equalsArr(e,t){let i=e.length,n=t.length;if(i!==n)return!1;for(let n=0;n=r||(s[a++]=new up(Math.max(1,t.startColumn-n+1),Math.min(o+1,t.endColumn-n+1),t.className,t.type));return s}static filter(e,t,i,n){if(0===e.length)return[];let r=[],o=0;for(let s=0,a=e.length;st||l.isEmpty()&&(0===a.type||3===a.type))continue;let h=l.startLineNumber===t?l.startColumn:i,u=l.endLineNumber===t?l.endColumn:n;r[o++]=new up(h,u,a.inlineClassName,a.type)}return r}static _typeCompare(e,t){let i=[2,0,1,3];return i[e]-i[t]}static compare(e,t){if(e.startColumn!==t.startColumn)return e.startColumn-t.startColumn;if(e.endColumn!==t.endColumn)return e.endColumn-t.endColumn;let i=up._typeCompare(e.type,t.type);return 0!==i?i:e.className!==t.className?e.className0&&this.stopOffsets[0]0&&t=e){this.stopOffsets.splice(n,0,e),this.classNames.splice(n,0,t),this.metadata.splice(n,0,i);break}this.count++}}class uE{static normalize(e,t){if(0===t.length)return[];let i=[],n=new u_,r=0;for(let o=0,s=t.length;o1){let t=e.charCodeAt(a-2);r6(t)&&a--}if(l>1){let t=e.charCodeAt(l-2);r6(t)&&l--}let d=a-1,c=l-2;r=n.consumeLowerThan(d,r,i),0===n.count&&(r=d),n.insert(c,h,u)}return n.consumeLowerThan(1073741824,r,i),i}}class uv{constructor(e,t,i,n){this.endIndex=e,this.type=t,this.metadata=i,this.containsRTL=n,this._linePartBrand=void 0}isWhitespace(){return!!(1&this.metadata)}isPseudoAfter(){return!!(4&this.metadata)}}class ub{constructor(e,t){this.startOffset=e,this.endOffset=t}equals(e){return this.startOffset===e.startOffset&&this.endOffset===e.endOffset}}class uC{constructor(e,t,i,n,r,o,s,a,l,h,u,d,c,f,g,p,m,_,E){this.useMonospaceOptimizations=e,this.canUseHalfwidthRightwardsArrow=t,this.lineContent=i,this.continuesWithWrappedLine=n,this.isBasicASCII=r,this.containsRTL=o,this.fauxIndentLength=s,this.lineTokens=a,this.lineDecorations=l.sort(up.compare),this.tabSize=h,this.startVisibleColumn=u,this.spaceWidth=d,this.stopRenderingLineAfter=g,this.renderWhitespace="all"===p?4:"boundary"===p?1:"selection"===p?2:"trailing"===p?3:0,this.renderControlCharacters=m,this.fontLigatures=_,this.selectionsOnLine=E&&E.sort((e,t)=>e.startOffset>>16}static getCharIndex(e){return(65535&e)>>>0}constructor(e,t){this.length=e,this._data=new Uint32Array(this.length),this._horizontalOffset=new Uint32Array(this.length)}setColumnInfo(e,t,i,n){this._data[e-1]=(t<<16|i<<0)>>>0,this._horizontalOffset[e-1]=n}getHorizontalOffset(e){return 0===this._horizontalOffset.length?0:this._horizontalOffset[e-1]}charOffsetToPartData(e){return 0===this.length?0:e<0?this._data[0]:e>=this.length?this._data[this.length-1]:this._data[e]}getDomPosition(e){let t=this.charOffsetToPartData(e-1),i=uy.getPartIndex(t),n=uy.getCharIndex(t);return new uS(i,n)}getColumn(e,t){let i=this.partDataToCharOffset(e.partIndex,t,e.charIndex);return i+1}partDataToCharOffset(e,t,i){if(0===this.length)return 0;let n=(e<<16|i<<0)>>>0,r=0,o=this.length-1;for(;r+1>>1,t=this._data[e];if(t===n)return e;t>n?o=e:r=e}if(r===o)return r;let s=this._data[r],a=this._data[o];if(s===n)return r;if(a===n)return o;let l=uy.getPartIndex(s),h=uy.getCharIndex(s),u=uy.getPartIndex(a);return i-h<=(l!==u?t:uy.getCharIndex(a))-i?r:o}}class uT{constructor(e,t,i){this._renderLineOutputBrand=void 0,this.characterMapping=e,this.containsRTL=t,this.containsForeignElements=i}}function uR(e,t){if(0===e.lineContent.length){if(e.lineDecorations.length>0){t.appendString("");let i=0,n=0,r=0;for(let o of e.lineDecorations)(1===o.type||2===o.type)&&(t.appendString(''),1===o.type&&(r|=1,i++),2===o.type&&(r|=2,n++));t.appendString("");let o=new uy(1,i+n);return o.setColumnInfo(1,i,0,0),new uT(o,!1,r)}return t.appendString(""),new uT(new uy(0,0),!1,0)}return function(e,t){let i=e.fontIsMonospace,n=e.canUseHalfwidthRightwardsArrow,r=e.containsForeignElements,o=e.lineContent,s=e.len,a=e.isOverflowing,l=e.overflowingCharCount,h=e.parts,u=e.fauxIndentLength,d=e.tabSize,c=e.startVisibleColumn,f=e.containsRTL,g=e.spaceWidth,p=e.renderSpaceCharCode,m=e.renderWhitespace,_=e.renderControlCharacters,E=new uy(s+1,h.length),v=!1,b=0,C=c,S=0,y=0,T=0;f?t.appendString(''):t.appendString("");for(let e=0,a=h.length;e=u&&(t+=r)}}for(A&&(t.appendString(' style="width:'),t.appendString(String(g*i)),t.appendString('px"')),t.appendASCIICharCode(62);b1?t.appendCharCode(8594):t.appendCharCode(65515);for(let e=2;e<=r;e++)t.appendCharCode(160)}else i=2,r=1,t.appendCharCode(p),t.appendCharCode(8204);S+=i,y+=r,b>=u&&(C+=r)}}else for(t.appendASCIICharCode(62);b=u&&(C+=r)}N?T++:T=0,b>=s&&!v&&a.isPseudoAfter()&&(v=!0,E.setColumnInfo(b+1,e,S,y)),t.appendString("")}return v||E.setColumnInfo(s+1,h.length-1,S,y),a&&(t.appendString(''),t.appendString(rN.NC("showMore","Show more ({0})",l<1024?rN.NC("overflow.chars","{0} chars",l):l<1048576?`${(l/1024).toFixed(1)} KB`:`${(l/1024/1024).toFixed(1)} MB`)),t.appendString("")),t.appendString(""),new uT(E,f,r)}(function(e){let t,i,n;let r=e.lineContent;-1!==e.stopRenderingLineAfter&&e.stopRenderingLineAfter0&&(o[s++]=new uv(n,"",0,!1));let a=n;for(let l=0,h=i.getCount();l=r){let i=!!t&&or(e.substring(a,r));o[s++]=new uv(r,u,0,i);break}let d=!!t&&or(e.substring(a,h));o[s++]=new uv(h,u,0,d),a=h}return o}(r,e.containsRTL,e.lineTokens,e.fauxIndentLength,n);e.renderControlCharacters&&!e.isBasicASCII&&(o=function(e,t){let i=[],n=new uv(0,"",0,!1),r=0;for(let o of t){let t=o.endIndex;for(;rn.endIndex&&(n=new uv(r,o.type,o.metadata,o.containsRTL),i.push(n)),n=new uv(r+1,"mtkcontrol",o.metadata,!1),i.push(n))}r>n.endIndex&&(n=new uv(t,o.type,o.metadata,o.containsRTL),i.push(n))}return i}(r,o)),(4===e.renderWhitespace||1===e.renderWhitespace||2===e.renderWhitespace&&e.selectionsOnLine||3===e.renderWhitespace&&!e.continuesWithWrappedLine)&&(o=function(e,t,i,n){let r;let o=e.continuesWithWrappedLine,s=e.fauxIndentLength,a=e.tabSize,l=e.startVisibleColumn,h=e.useMonospaceOptimizations,u=e.selectionsOnLine,d=1===e.renderWhitespace,c=3===e.renderWhitespace,f=e.renderSpaceWidth!==e.spaceWidth,g=[],p=0,m=0,_=n[0].type,E=n[m].containsRTL,v=n[m].endIndex,b=n.length,C=!1,S=rK(t);-1===S?(C=!0,S=i,r=i):r=r$(t);let y=!1,T=0,R=u&&u[T],A=l%a;for(let e=s;e=R.endOffset&&(T++,R=u&&u[T]),er)o=!0;else if(9===l)o=!0;else if(32===l){if(d){if(y)o=!0;else{let n=e+1e),o&&c&&(o=C||e>r),o&&E&&e>=S&&e<=r&&(o=!1),y){if(!o||!h&&A>=a){if(f){let t=p>0?g[p-1].endIndex:s;for(let i=t+1;i<=e;i++)g[p++]=new uv(i,"mtkw",1,!1)}else g[p++]=new uv(e,"mtkw",1,!1);A%=a}}else(e===v||o&&e>s)&&(g[p++]=new uv(e,_,0,E),A%=a);for(9===l?A=a:ol(l)?A+=2:A++,y=o;e===v;)if(++m0?t.charCodeAt(i-1):0,n=i>1?t.charCodeAt(i-2):0;32===e&&32!==n&&9!==n||(N=!0)}else N=!0}if(N){if(f){let e=p>0?g[p-1].endIndex:s;for(let t=e+1;t<=i;t++)g[p++]=new uv(t,"mtkw",1,!1)}else g[p++]=new uv(i,"mtkw",1,!1)}else g[p++]=new uv(i,_,0,E);return g}(e,r,n,o));let s=0;if(e.lineDecorations.length>0){for(let t=0,i=e.lineDecorations.length;th&&(h=e.startOffset,a[l++]=new uv(h,u,d,c)),e.endOffset+1<=n)h=e.endOffset+1,a[l++]=new uv(h,u+" "+e.className,d|e.metadata,c),s++;else{h=n,a[l++]=new uv(h,u+" "+e.className,d|e.metadata,c);break}}n>h&&(h=n,a[l++]=new uv(h,u,d,c))}let u=i[i.length-1].endIndex;if(s=50&&(r[o++]=new uv(h+1,t,i,l),u=h+1,h=-1);u!==a&&(r[o++]=new uv(a,t,i,l))}else r[o++]=s;n=a}else for(let e=0,i=t.length;e50){let e=i.type,t=i.metadata,l=i.containsRTL,h=Math.ceil(a/50);for(let i=1;i=8234&&e<=8238||e>=8294&&e<=8297||e>=8206&&e<=8207||1564===e}class uI{constructor(e,t,i,n){this._viewportBrand=void 0,this.top=0|e,this.left=0|t,this.width=0|i,this.height=0|n}}class uw{constructor(e,t){this.tabSize=e,this.data=t}}class uD{constructor(e,t,i,n,r,o,s){this._viewLineDataBrand=void 0,this.content=e,this.continuesWithWrappedLine=t,this.minColumn=i,this.maxColumn=n,this.startVisibleColumn=r,this.tokens=o,this.inlineDecorations=s}}class ux{constructor(e,t,i,n,r,o,s,a,l,h){this.minColumn=e,this.maxColumn=t,this.content=i,this.continuesWithWrappedLine=n,this.isBasicASCII=ux.isBasicASCII(i,o),this.containsRTL=ux.containsRTL(i,this.isBasicASCII,r),this.tokens=s,this.inlineDecorations=a,this.tabSize=l,this.startVisibleColumn=h}static isBasicASCII(e,t){return!t||os(e)}static containsRTL(e,t,i){return!t&&!!i&&or(e)}}class uM{constructor(e,t,i){this.range=e,this.inlineClassName=t,this.type=i}}class uk{constructor(e,t,i,n){this.startOffset=e,this.endOffset=t,this.inlineClassName=i,this.inlineClassNameAffectsLetterSpacing=n}toInlineDecoration(e){return new uM(new rv(e,this.startOffset+1,e,this.endOffset+1),this.inlineClassName,this.inlineClassNameAffectsLetterSpacing?3:0)}}class uP{constructor(e,t){this._viewModelDecorationBrand=void 0,this.range=e,this.options=t}}class uF{constructor(e,t,i){this.color=e,this.zIndex=t,this.data=i}static cmp(e,t){return e.zIndex===t.zIndex?e.colort.color?1:0:e.zIndex-t.zIndex}}function uB(e){return"string"==typeof e}function uU(e,t){return e.ignoreCase&&t?t.toLowerCase():t}function uH(e){return e.replace(/[&<>'"_]/g,"-")}function uV(e,t){return Error(`${e.languageId}: ${t}`)}function uW(e,t,i,n,r){let o=null;return t.replace(/\$((\$)|(#)|(\d\d?)|[sS](\d\d?)|@(\w+))/g,function(t,s,a,l,h,u,d,c,f){return a?"$":l?uU(e,i):h&&h0;){let t=e.tokenizer[i];if(t)return t;let n=i.lastIndexOf(".");i=n<0?null:i.substr(0,n)}return null}class uj{static create(e,t){return this._INSTANCE.create(e,t)}constructor(e){this._maxCacheDepth=e,this._entries=Object.create(null)}create(e,t){if(null!==e&&e.depth>=this._maxCacheDepth)return new uz(e,t);let i=uz.getStackElementId(e);i.length>0&&(i+="|"),i+=t;let n=this._entries[i];return n||(n=new uz(e,t),this._entries[i]=n),n}}uj._INSTANCE=new uj(5);class uz{constructor(e,t){this.parent=e,this.state=t,this.depth=(this.parent?this.parent.depth:0)+1}static getStackElementId(e){let t="";for(;null!==e;)t.length>0&&(t+="|"),t+=e.state,e=e.parent;return t}static _equals(e,t){for(;null!==e&&null!==t;){if(e===t)return!0;if(e.state!==t.state)return!1;e=e.parent,t=t.parent}return null===e&&null===t}equals(e){return uz._equals(this,e)}push(e){return uj.create(this,e)}pop(){return this.parent}popall(){let e=this;for(;e.parent;)e=e.parent;return e}switchTo(e){return uj.create(this.parent,e)}}class uK{constructor(e,t){this.languageId=e,this.state=t}equals(e){return this.languageId===e.languageId&&this.state.equals(e.state)}clone(){let e=this.state.clone();return e===this.state?this:new uK(this.languageId,this.state)}}class uY{static create(e,t){return this._INSTANCE.create(e,t)}constructor(e){this._maxCacheDepth=e,this._entries=Object.create(null)}create(e,t){if(null!==t||null!==e&&e.depth>=this._maxCacheDepth)return new u$(e,t);let i=uz.getStackElementId(e),n=this._entries[i];return n||(n=new u$(e,null),this._entries[i]=n),n}}uY._INSTANCE=new uY(5);class u${constructor(e,t){this.stack=e,this.embeddedLanguageData=t}clone(){let e=this.embeddedLanguageData?this.embeddedLanguageData.clone():null;return e===this.embeddedLanguageData?this:uY.create(this.stack,this.embeddedLanguageData)}equals(e){return!!(e instanceof u$&&this.stack.equals(e.stack))&&(null===this.embeddedLanguageData&&null===e.embeddedLanguageData||null!==this.embeddedLanguageData&&null!==e.embeddedLanguageData&&this.embeddedLanguageData.equals(e.embeddedLanguageData))}}class uq{constructor(){this._tokens=[],this._languageId=null,this._lastTokenType=null,this._lastTokenLanguage=null}enterLanguage(e){this._languageId=e}emit(e,t){(this._lastTokenType!==t||this._lastTokenLanguage!==this._languageId)&&(this._lastTokenType=t,this._lastTokenLanguage=this._languageId,this._tokens.push(new rO(e,t,this._languageId)))}nestedLanguageTokenize(e,t,i,n){let r=i.languageId,o=i.state,s=rx.get(r);if(!s)return this.enterLanguage(r),this.emit(n,""),o;let a=s.tokenize(e,t,o);if(0!==n)for(let e of a.tokens)this._tokens.push(new rO(e.offset+n,e.type,e.language));else this._tokens=this._tokens.concat(a.tokens);return this._lastTokenType=null,this._lastTokenLanguage=null,this._languageId=null,a.endState}finalize(e){return new rL(this._tokens,e)}}class uX{constructor(e,t){this._languageService=e,this._theme=t,this._prependTokens=null,this._tokens=[],this._currentLanguageId=0,this._lastTokenMetadata=0}enterLanguage(e){this._currentLanguageId=this._languageService.languageIdCodec.encodeLanguageId(e)}emit(e,t){let i=1024|this._theme.match(this._currentLanguageId,t);this._lastTokenMetadata!==i&&(this._lastTokenMetadata=i,this._tokens.push(e),this._tokens.push(i))}static _merge(e,t,i){let n=null!==e?e.length:0,r=t.length,o=null!==i?i.length:0;if(0===n&&0===r&&0===o)return new Uint32Array(0);if(0===n&&0===r)return i;if(0===r&&0===o)return e;let s=new Uint32Array(n+r+o);null!==e&&s.set(e);for(let e=0;e{if(o)return;let t=!1;for(let i=0,n=e.changedLanguages.length;i{e.affectsConfiguration("editor.maxTokenizationLineLength")&&(this._maxTokenizationLineLength=this._configurationService.getValue("editor.maxTokenizationLineLength",{overrideIdentifier:this._languageId}))})}dispose(){this._tokenizationRegistryListener.dispose()}getLoadStatus(){let t=[];for(let i in this._embeddedLanguages){let n=rx.get(i);if(n){if(n instanceof e){let e=n.getLoadStatus();!1===e.loaded&&t.push(e.promise)}continue}rx.isResolved(i)||t.push(rx.getOrCreate(i))}return 0===t.length?{loaded:!0}:{loaded:!1,promise:Promise.all(t).then(e=>void 0)}}getInitialState(){let e=uj.create(null,this._lexer.start);return uY.create(e,null)}tokenize(e,t,i){if(e.length>=this._maxTokenizationLineLength)return a5(this._languageId,i);let n=new uq,r=this._tokenize(e,t,i,n);return n.finalize(r)}tokenizeEncoded(e,t,i){if(e.length>=this._maxTokenizationLineLength)return a4(this._languageService.languageIdCodec.encodeLanguageId(this._languageId),i);let n=new uX(this._languageService,this._standaloneThemeService.getColorTheme().tokenTheme),r=this._tokenize(e,t,i,n);return n.finalize(r)}_tokenize(e,t,i,n){return i.embeddedLanguageData?this._nestedTokenize(e,t,i,0,n):this._myTokenize(e,t,i,0,n)}_findLeavingNestedLanguageOffset(e,t){let i=this._lexer.tokenizer[t.stack.state];if(!i&&!(i=uG(this._lexer,t.stack.state)))throw uV(this._lexer,"tokenizer state is not defined: "+t.stack.state);let n=-1,r=!1;for(let t of i){if(uB(t.action)||"@pop"!==t.action.nextEmbedded)continue;r=!0;let i=t.regex,o=t.regex.source;if("^(?:"===o.substr(0,4)&&")"===o.substr(o.length-1,1)){let e=(i.ignoreCase?"i":"")+(i.unicode?"u":"");i=new RegExp(o.substr(4,o.length-5),e)}let s=e.search(i);-1!==s&&(0===s||!t.matchOnlyAtLineStart)&&(-1===n||s0&&r.nestedLanguageTokenize(s,!1,i.embeddedLanguageData,n);let a=e.substring(o);return this._myTokenize(a,t,i,n+o,r)}_safeRuleName(e){return e?e.name:"(unknown)"}_myTokenize(e,t,i,n,r){r.enterLanguage(this._languageId);let o=e.length,s=t&&this._lexer.includeLF?e+"\n":e,a=s.length,l=i.embeddedLanguageData,h=i.stack,u=0,d=null,c=!0;for(;c||u=a)break;c=!1;let e=this._lexer.tokenizer[p];if(!e&&!(e=uG(this._lexer,p)))throw uV(this._lexer,"tokenizer state is not defined: "+p);let t=s.substr(u);for(let i of e)if((0===u||!i.matchOnlyAtLineStart)&&(m=t.match(i.regex))){_=m[0],E=i.action;break}}if(m||(m=[""],_=""),E||(u=this._lexer.maxStack)throw uV(this._lexer,"maximum tokenizer stack size reached: ["+h.state+","+h.parent.state+",...]");h=h.push(p)}else if("@pop"===E.next){if(h.depth<=1)throw uV(this._lexer,"trying to pop an empty stack in rule: "+this._safeRuleName(v));h=h.pop()}else if("@popall"===E.next)h=h.popall();else{let e=uW(this._lexer,E.next,_,m,p);if("@"===e[0]&&(e=e.substr(1)),uG(this._lexer,e))h=h.push(e);else throw uV(this._lexer,"trying to set a next state '"+e+"' that is undefined in rule: "+this._safeRuleName(v))}}E.log&&"string"==typeof E.log&&console.log(`${this._lexer.languageId}: ${this._lexer.languageId+": "+uW(this._lexer,E.log,_,m,p)}`)}if(null===C)throw uV(this._lexer,"lexer rule has no well-defined action in rule: "+this._safeRuleName(v));let S=i=>{let o=this._languageService.getLanguageIdByLanguageName(i)||this._languageService.getLanguageIdByMimeType(i)||i,s=this._getNestedEmbeddedLanguageData(o);if(!(u0)throw uV(this._lexer,"groups cannot be nested: "+this._safeRuleName(v));if(m.length!==C.length+1)throw uV(this._lexer,"matched number of groups does not match the number of actions in rule: "+this._safeRuleName(v));let e=0;for(let t=1;t=0;a--)(r=e[a])&&(s=(o<3?r(s):o>3?r(t,i,s):r(t,i))||s);return o>3&&s&&Object.defineProperty(t,i,s),s}([function(e,t){al(e,t,4)}],uZ);let uQ=lR("standaloneColorizer",{createHTML:e=>e});class uJ{static colorizeElement(e,t,i,n){n=n||{};let r=n.theme||"vs",o=n.mimeType||i.getAttribute("lang")||i.getAttribute("data-lang");if(!o)return console.error("Mode not detected"),Promise.resolve();let s=t.getLanguageIdByMimeType(o)||o;e.setTheme(r);let a=i.firstChild?i.firstChild.nodeValue:"";return i.className+=" "+r,this.colorize(t,a||"",s,n).then(e=>{var t;let n=null!==(t=null==uQ?void 0:uQ.createHTML(e))&&void 0!==t?t:e;i.innerHTML=n},e=>console.error(e))}static colorize(e,t,i,n){var r,o,s,a;return r=this,o=void 0,s=void 0,a=function*(){var r;let o=e.languageIdCodec,s=4;n&&"number"==typeof n.tabSize&&(s=n.tabSize),od(t)&&(t=t.substr(1));let a=rz(t);if(!e.isRegisteredLanguageId(i))return u0(a,s,o);let l=yield rx.getOrCreate(i);return l?(r=s,new Promise((e,t)=>{let i=()=>{let n=function(e,t,i,n){let r=[],o=i.getInitialState();for(let s=0,a=e.length;s"),o=l.endState}return r.join("")}(a,r,l,o);if(l instanceof uZ){let e=l.getLoadStatus();if(!1===e.loaded){e.promise.then(i,t);return}}e(n)};i()})):u0(a,s,o)},new(s||(s=Promise))(function(e,t){function i(e){try{l(a.next(e))}catch(e){t(e)}}function n(e){try{l(a.throw(e))}catch(e){t(e)}}function l(t){var r;t.done?e(t.value):((r=t.value)instanceof s?r:new s(function(e){e(r)})).then(i,n)}l((a=a.apply(r,o||[])).next())})}static colorizeLine(e,t,i,n,r=4){let o=ux.isBasicASCII(e,t),s=ux.containsRTL(e,o,i),a=uN(new uC(!1,!0,e,!1,o,s,0,n,[],r,0,0,0,0,-1,"none",!1,!1,null));return a.html}static colorizeModelLine(e,t,i=4){let n=e.getLineContent(t);e.tokenization.forceTokenization(t);let r=e.tokenization.getLineTokens(t),o=r.inflate();return this.colorizeLine(n,e.mightContainNonBasicASCII(),e.mightContainRTL(),o,i)}}function u0(e,t,i){let n=[],r=new Uint32Array(2);r[0]=0,r[1]=33587200;for(let o=0,s=e.length;o")}return n.join("")}let u1={clipboard:{writeText:nz.tY||document.queryCommandSupported&&document.queryCommandSupported("copy")||!!(navigator&&navigator.clipboard&&navigator.clipboard.writeText),readText:nz.tY||!!(navigator&&navigator.clipboard&&navigator.clipboard.readText)},keyboard:nz.tY||oL?0:navigator.keyboard||oA?1:2,touch:"ontouchstart"in window||navigator.maxTouchPoints>0,pointerEvents:window.PointerEvent&&("ontouchstart"in window||window.navigator.maxTouchPoints>0||navigator.maxTouchPoints>0)};function u2(e,t){if("number"==typeof e){if(0===e)return null;let i=(65535&e)>>>0,n=(4294901760&e)>>>16;return new u3(0!==n?[u5(i,t),u5(n,t)]:[u5(i,t)])}{let i=[];for(let n=0;n1?i-1:0),r=1;r/gm),dj=dc(/^data-[\-\w.\u00B7-\uFFFF]/),dz=dc(/^aria-[\-\w]+$/),dK=dc(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),dY=dc(/^(?:\w+script|data):/i),d$=dc(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),dq="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};function dX(e){if(!Array.isArray(e))return Array.from(e);for(var t=0,i=Array(e.length);t0&&void 0!==arguments[0]?arguments[0]:"undefined"==typeof window?null:window,i=function(t){return e(t)};if(i.version="2.3.1",i.removed=[],!t||!t.document||9!==t.document.nodeType)return i.isSupported=!1,i;var n=t.document,r=t.document,o=t.DocumentFragment,s=t.HTMLTemplateElement,a=t.Node,l=t.Element,h=t.NodeFilter,u=t.NamedNodeMap,d=void 0===u?t.NamedNodeMap||t.MozNamedAttrMap:u,c=t.Text,f=t.Comment,g=t.DOMParser,p=t.trustedTypes,m=l.prototype,_=dI(m,"cloneNode"),E=dI(m,"nextSibling"),v=dI(m,"childNodes"),b=dI(m,"parentNode");if("function"==typeof s){var C=r.createElement("template");C.content&&C.content.ownerDocument&&(r=C.content.ownerDocument)}var S=dZ(p,n),y=S&&q?S.createHTML(""):"",T=r,R=T.implementation,A=T.createNodeIterator,N=T.createDocumentFragment,O=T.getElementsByTagName,L=n.importNode,I={};try{I=dL(r).documentMode?r.documentMode:{}}catch(e){}var w={};i.isSupported="function"==typeof b&&R&&void 0!==R.createHTMLDocument&&9!==I;var D=dK,x=null,M=dO({},[].concat(dX(dw),dX(dD),dX(dx),dX(dk),dX(dF))),k=null,P=dO({},[].concat(dX(dB),dX(dU),dX(dH),dX(dV))),F=null,B=null,U=!0,H=!0,V=!1,W=!1,G=!1,j=!1,z=!1,K=!1,Y=!1,$=!0,q=!1,X=!0,Z=!0,Q=!1,J={},ee=null,et=dO({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]),ei=null,en=dO({},["audio","video","img","source","image","track"]),er=null,eo=dO({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),es="http://www.w3.org/1998/Math/MathML",ea="http://www.w3.org/2000/svg",el="http://www.w3.org/1999/xhtml",eh=el,eu=!1,ed=null,ec=r.createElement("form"),ef=function(e){ed&&ed===e||(e&&(void 0===e?"undefined":dq(e))==="object"||(e={}),x="ALLOWED_TAGS"in(e=dL(e))?dO({},e.ALLOWED_TAGS):M,k="ALLOWED_ATTR"in e?dO({},e.ALLOWED_ATTR):P,er="ADD_URI_SAFE_ATTR"in e?dO(dL(eo),e.ADD_URI_SAFE_ATTR):eo,ei="ADD_DATA_URI_TAGS"in e?dO(dL(en),e.ADD_DATA_URI_TAGS):en,ee="FORBID_CONTENTS"in e?dO({},e.FORBID_CONTENTS):et,F="FORBID_TAGS"in e?dO({},e.FORBID_TAGS):{},B="FORBID_ATTR"in e?dO({},e.FORBID_ATTR):{},J="USE_PROFILES"in e&&e.USE_PROFILES,U=!1!==e.ALLOW_ARIA_ATTR,H=!1!==e.ALLOW_DATA_ATTR,V=e.ALLOW_UNKNOWN_PROTOCOLS||!1,W=e.SAFE_FOR_TEMPLATES||!1,G=e.WHOLE_DOCUMENT||!1,K=e.RETURN_DOM||!1,Y=e.RETURN_DOM_FRAGMENT||!1,$=!1!==e.RETURN_DOM_IMPORT,q=e.RETURN_TRUSTED_TYPE||!1,z=e.FORCE_BODY||!1,X=!1!==e.SANITIZE_DOM,Z=!1!==e.KEEP_CONTENT,Q=e.IN_PLACE||!1,D=e.ALLOWED_URI_REGEXP||D,eh=e.NAMESPACE||el,W&&(H=!1),Y&&(K=!0),J&&(x=dO({},[].concat(dX(dF))),k=[],!0===J.html&&(dO(x,dw),dO(k,dB)),!0===J.svg&&(dO(x,dD),dO(k,dU),dO(k,dV)),!0===J.svgFilters&&(dO(x,dx),dO(k,dU),dO(k,dV)),!0===J.mathMl&&(dO(x,dk),dO(k,dH),dO(k,dV))),e.ADD_TAGS&&(x===M&&(x=dL(x)),dO(x,e.ADD_TAGS)),e.ADD_ATTR&&(k===P&&(k=dL(k)),dO(k,e.ADD_ATTR)),e.ADD_URI_SAFE_ATTR&&dO(er,e.ADD_URI_SAFE_ATTR),e.FORBID_CONTENTS&&(ee===et&&(ee=dL(ee)),dO(ee,e.FORBID_CONTENTS)),Z&&(x["#text"]=!0),G&&dO(x,["html","head","body"]),x.table&&(dO(x,["tbody"]),delete F.tbody),dd&&dd(e),ed=e)},eg=dO({},["mi","mo","mn","ms","mtext"]),ep=dO({},["foreignobject","desc","title","annotation-xml"]),em=dO({},dD);dO(em,dx),dO(em,dM);var e_=dO({},dk);dO(e_,dP);var eE=function(e){var t=b(e);t&&t.tagName||(t={namespaceURI:el,tagName:"template"});var i=db(e.tagName),n=db(t.tagName);if(e.namespaceURI===ea)return t.namespaceURI===el?"svg"===i:t.namespaceURI===es?"svg"===i&&("annotation-xml"===n||eg[n]):!!em[i];if(e.namespaceURI===es)return t.namespaceURI===el?"math"===i:t.namespaceURI===ea?"math"===i&&ep[n]:!!e_[i];if(e.namespaceURI===el){if(t.namespaceURI===ea&&!ep[n]||t.namespaceURI===es&&!eg[n])return!1;var r=dO({},["title","style","font","a","script"]);return!e_[i]&&(r[i]||!em[i])}return!1},ev=function(e){dv(i.removed,{element:e});try{e.parentNode.removeChild(e)}catch(t){try{e.outerHTML=y}catch(t){e.remove()}}},eb=function(e,t){try{dv(i.removed,{attribute:t.getAttributeNode(e),from:t})}catch(e){dv(i.removed,{attribute:null,from:t})}if(t.removeAttribute(e),"is"===e&&!k[e]){if(K||Y)try{ev(t)}catch(e){}else try{t.setAttribute(e,"")}catch(e){}}},eC=function(e){var t=void 0,i=void 0;if(z)e=""+e;else{var n=dC(e,/^[\r\n\t ]+/);i=n&&n[0]}var o=S?S.createHTML(e):e;if(eh===el)try{t=new g().parseFromString(o,"text/html")}catch(e){}if(!t||!t.documentElement){t=R.createDocument(eh,"template",null);try{t.documentElement.innerHTML=eu?"":o}catch(e){}}var s=t.body||t.documentElement;return(e&&i&&s.insertBefore(r.createTextNode(i),s.childNodes[0]||null),eh===el)?O.call(t,G?"html":"body")[0]:G?t.documentElement:s},eS=function(e){return A.call(e.ownerDocument||e,e,h.SHOW_ELEMENT|h.SHOW_COMMENT|h.SHOW_TEXT,null,!1)},ey=function(e){return(void 0===a?"undefined":dq(a))==="object"?e instanceof a:e&&(void 0===e?"undefined":dq(e))==="object"&&"number"==typeof e.nodeType&&"string"==typeof e.nodeName},eT=function(e,t,n){w[e]&&d_(w[e],function(e){e.call(i,t,n,ed)})},eR=function(e){var t=void 0;if(eT("beforeSanitizeElements",e,null),!(e instanceof c)&&!(e instanceof f)&&("string"!=typeof e.nodeName||"string"!=typeof e.textContent||"function"!=typeof e.removeChild||!(e.attributes instanceof d)||"function"!=typeof e.removeAttribute||"function"!=typeof e.setAttribute||"string"!=typeof e.namespaceURI||"function"!=typeof e.insertBefore)||dC(e.nodeName,/[\u0080-\uFFFF]/))return ev(e),!0;var n=db(e.nodeName);if(eT("uponSanitizeElement",e,{tagName:n,allowedTags:x}),!ey(e.firstElementChild)&&(!ey(e.content)||!ey(e.content.firstElementChild))&&dR(/<[/\w]/g,e.innerHTML)&&dR(/<[/\w]/g,e.textContent)||"select"===n&&dR(/