react-msaview 5.2.1 → 5.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundle/index.js +1 -1
- package/bundle/index.js.map +1 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +3 -3
- package/src/version.ts +1 -1
package/bundle/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*! For license information please see index.js.LICENSE.txt */
|
|
2
|
-
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.ReactMSAView=t():e.ReactMSAView=t()}(self,()=>(()=>{var e,t,n={8371(e,t,n){"use strict";function r(e){var t=Object.create(null);return function(n){return void 0===t[n]&&(t[n]=e(n)),t[n]}}n.d(t,{A:()=>r})},1733(e,t,n){"use strict";n.d(t,{E:()=>me,T:()=>de,_:()=>ce,c:()=>he,h:()=>fe,w:()=>ue});var r=n(405),o=function(){function e(e){var t=this;this._insertTag=function(e){var n;n=0===t.tags.length?t.insertionPoint?t.insertionPoint.nextSibling:t.prepend?t.container.firstChild:t.before:t.tags[t.tags.length-1].nextSibling,t.container.insertBefore(e,n),t.tags.push(e)},this.isSpeedy=void 0===e.speedy||e.speedy,this.tags=[],this.ctr=0,this.nonce=e.nonce,this.key=e.key,this.container=e.container,this.prepend=e.prepend,this.insertionPoint=e.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(e){e.forEach(this._insertTag)},t.insert=function(e){this.ctr%(this.isSpeedy?65e3:1)==0&&this._insertTag(function(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),void 0!==e.nonce&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}(this));var t=this.tags[this.tags.length-1];if(this.isSpeedy){var n=function(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}(t);try{n.insertRule(e,n.cssRules.length)}catch(e){}}else t.appendChild(document.createTextNode(e));this.ctr++},t.flush=function(){this.tags.forEach(function(e){var t;return null==(t=e.parentNode)?void 0:t.removeChild(e)}),this.tags=[],this.ctr=0},e}(),i=Math.abs,a=String.fromCharCode,l=Object.assign;function s(e){return e.trim()}function c(e,t,n){return e.replace(t,n)}function u(e,t){return e.indexOf(t)}function d(e,t){return 0|e.charCodeAt(t)}function f(e,t,n){return e.slice(t,n)}function p(e){return e.length}function h(e){return e.length}function g(e,t){return t.push(e),e}var m=1,A=1,b=0,v=0,y=0,w="";function C(e,t,n,r,o,i,a){return{value:e,root:t,parent:n,type:r,props:o,children:i,line:m,column:A,length:a,return:""}}function S(e,t){return l(C("",null,null,"",null,null,0),e,{length:-e.length},t)}function x(){return y=v>0?d(w,--v):0,A--,10===y&&(A=1,m--),y}function E(){return y=v<b?d(w,v++):0,A++,10===y&&(A=1,m++),y}function I(){return d(w,v)}function k(){return v}function R(e,t){return f(w,e,t)}function M(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function P(e){return m=A=1,b=p(w=e),v=0,[]}function B(e){return w="",e}function _(e){return s(R(v-1,D(91===e?e+2:40===e?e+1:e)))}function T(e){for(;(y=I())&&y<33;)E();return M(e)>2||M(y)>3?"":" "}function O(e,t){for(;--t&&E()&&!(y<48||y>102||y>57&&y<65||y>70&&y<97););return R(e,k()+(t<6&&32==I()&&32==E()))}function D(e){for(;E();)switch(y){case e:return v;case 34:case 39:34!==e&&39!==e&&D(y);break;case 40:41===e&&D(e);break;case 92:E()}return v}function N(e,t){for(;E()&&e+y!==57&&(e+y!==84||47!==I()););return"/*"+R(t,v-1)+"*"+a(47===e?e:E())}function L(e){for(;!M(I());)E();return R(e,v)}var F="-ms-",Q="-moz-",j="-webkit-",z="comm",$="rule",H="decl",G="@keyframes";function V(e,t){for(var n="",r=h(e),o=0;o<r;o++)n+=t(e[o],o,e,t)||"";return n}function W(e,t,n,r){switch(e.type){case"@layer":if(e.children.length)break;case"@import":case H:return e.return=e.return||e.value;case z:return"";case G:return e.return=e.value+"{"+V(e.children,r)+"}";case $:e.value=e.props.join(",")}return p(n=V(e.children,r))?e.return=e.value+"{"+n+"}":""}function U(e){return B(q("",null,null,null,[""],e=P(e),0,[0],e))}function q(e,t,n,r,o,i,l,s,f){for(var h=0,m=0,A=l,b=0,v=0,y=0,w=1,C=1,S=1,R=0,M="",P=o,B=i,D=r,F=M;C;)switch(y=R,R=E()){case 40:if(108!=y&&58==d(F,A-1)){-1!=u(F+=c(_(R),"&","&\f"),"&\f")&&(S=-1);break}case 34:case 39:case 91:F+=_(R);break;case 9:case 10:case 13:case 32:F+=T(y);break;case 92:F+=O(k()-1,7);continue;case 47:switch(I()){case 42:case 47:g(K(N(E(),k()),t,n),f);break;default:F+="/"}break;case 123*w:s[h++]=p(F)*S;case 125*w:case 59:case 0:switch(R){case 0:case 125:C=0;case 59+m:-1==S&&(F=c(F,/\f/g,"")),v>0&&p(F)-A&&g(v>32?J(F+";",r,n,A-1):J(c(F," ","")+";",r,n,A-2),f);break;case 59:F+=";";default:if(g(D=Y(F,t,n,h,m,o,s,M,P=[],B=[],A),i),123===R)if(0===m)q(F,t,D,D,P,i,A,s,B);else switch(99===b&&110===d(F,3)?100:b){case 100:case 108:case 109:case 115:q(e,D,D,r&&g(Y(e,D,D,0,0,o,s,M,o,P=[],A),B),o,B,A,s,r?P:B);break;default:q(F,D,D,D,[""],B,0,s,B)}}h=m=v=0,w=S=1,M=F="",A=l;break;case 58:A=1+p(F),v=y;default:if(w<1)if(123==R)--w;else if(125==R&&0==w++&&125==x())continue;switch(F+=a(R),R*w){case 38:S=m>0?1:(F+="\f",-1);break;case 44:s[h++]=(p(F)-1)*S,S=1;break;case 64:45===I()&&(F+=_(E())),b=I(),m=A=p(M=F+=L(k())),R++;break;case 45:45===y&&2==p(F)&&(w=0)}}return i}function Y(e,t,n,r,o,a,l,u,d,p,g){for(var m=o-1,A=0===o?a:[""],b=h(A),v=0,y=0,w=0;v<r;++v)for(var S=0,x=f(e,m+1,m=i(y=l[v])),E=e;S<b;++S)(E=s(y>0?A[S]+" "+x:c(x,/&\f/g,A[S])))&&(d[w++]=E);return C(e,t,n,0===o?$:u,d,p,g)}function K(e,t,n){return C(e,t,n,z,a(y),f(e,2,-2),0)}function J(e,t,n,r){return C(e,t,n,H,f(e,0,r),f(e,r+1,-1),r)}var X=function(e,t,n){for(var r=0,o=0;r=o,o=I(),38===r&&12===o&&(t[n]=1),!M(o);)E();return R(e,v)},Z=new WeakMap,ee=function(e){if("rule"===e.type&&e.parent&&!(e.length<1)){for(var t=e.value,n=e.parent,r=e.column===n.column&&e.line===n.line;"rule"!==n.type;)if(!(n=n.parent))return;if((1!==e.props.length||58===t.charCodeAt(0)||Z.get(n))&&!r){Z.set(e,!0);for(var o=[],i=function(e,t){return B(function(e,t){var n=-1,r=44;do{switch(M(r)){case 0:38===r&&12===I()&&(t[n]=1),e[n]+=X(v-1,t,n);break;case 2:e[n]+=_(r);break;case 4:if(44===r){e[++n]=58===I()?"&\f":"",t[n]=e[n].length;break}default:e[n]+=a(r)}}while(r=E());return e}(P(e),t))}(t,o),l=n.props,s=0,c=0;s<i.length;s++)for(var u=0;u<l.length;u++,c++)e.props[c]=o[s]?i[s].replace(/&\f/g,l[u]):l[u]+" "+i[s]}}},te=function(e){if("decl"===e.type){var t=e.value;108===t.charCodeAt(0)&&98===t.charCodeAt(2)&&(e.return="",e.value="")}};function ne(e,t){switch(function(e,t){return 45^d(e,0)?(((t<<2^d(e,0))<<2^d(e,1))<<2^d(e,2))<<2^d(e,3):0}(e,t)){case 5103:return j+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return j+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return j+e+Q+e+F+e+e;case 6828:case 4268:return j+e+F+e+e;case 6165:return j+e+F+"flex-"+e+e;case 5187:return j+e+c(e,/(\w+).+(:[^]+)/,j+"box-$1$2"+F+"flex-$1$2")+e;case 5443:return j+e+F+"flex-item-"+c(e,/flex-|-self/,"")+e;case 4675:return j+e+F+"flex-line-pack"+c(e,/align-content|flex-|-self/,"")+e;case 5548:return j+e+F+c(e,"shrink","negative")+e;case 5292:return j+e+F+c(e,"basis","preferred-size")+e;case 6060:return j+"box-"+c(e,"-grow","")+j+e+F+c(e,"grow","positive")+e;case 4554:return j+c(e,/([^-])(transform)/g,"$1"+j+"$2")+e;case 6187:return c(c(c(e,/(zoom-|grab)/,j+"$1"),/(image-set)/,j+"$1"),e,"")+e;case 5495:case 3959:return c(e,/(image-set\([^]*)/,j+"$1$`$1");case 4968:return c(c(e,/(.+:)(flex-)?(.*)/,j+"box-pack:$3"+F+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+j+e+e;case 4095:case 3583:case 4068:case 2532:return c(e,/(.+)-inline(.+)/,j+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(p(e)-1-t>6)switch(d(e,t+1)){case 109:if(45!==d(e,t+4))break;case 102:return c(e,/(.+:)(.+)-([^]+)/,"$1"+j+"$2-$3$1"+Q+(108==d(e,t+3)?"$3":"$2-$3"))+e;case 115:return~u(e,"stretch")?ne(c(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(115!==d(e,t+1))break;case 6444:switch(d(e,p(e)-3-(~u(e,"!important")&&10))){case 107:return c(e,":",":"+j)+e;case 101:return c(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+j+(45===d(e,14)?"inline-":"")+"box$3$1"+j+"$2$3$1"+F+"$2box$3")+e}break;case 5936:switch(d(e,t+11)){case 114:return j+e+F+c(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return j+e+F+c(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return j+e+F+c(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return j+e+F+e+e}return e}var re=[function(e,t,n,r){if(e.length>-1&&!e.return)switch(e.type){case H:e.return=ne(e.value,e.length);break;case G:return V([S(e,{value:c(e.value,"@","@"+j)})],r);case $:if(e.length)return function(e,t){return e.map(t).join("")}(e.props,function(t){switch(function(e){return(e=/(::plac\w+|:read-\w+)/.exec(e))?e[0]:e}(t)){case":read-only":case":read-write":return V([S(e,{props:[c(t,/:(read-\w+)/,":-moz-$1")]})],r);case"::placeholder":return V([S(e,{props:[c(t,/:(plac\w+)/,":"+j+"input-$1")]}),S(e,{props:[c(t,/:(plac\w+)/,":-moz-$1")]}),S(e,{props:[c(t,/:(plac\w+)/,F+"input-$1")]})],r)}return""})}}],oe=function(e){var t=e.key;if("css"===t){var n=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(n,function(e){-1!==e.getAttribute("data-emotion").indexOf(" ")&&(document.head.appendChild(e),e.setAttribute("data-s",""))})}var r,i,a=e.stylisPlugins||re,l={},s=[];r=e.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+t+' "]'),function(e){for(var t=e.getAttribute("data-emotion").split(" "),n=1;n<t.length;n++)l[t[n]]=!0;s.push(e)});var c,u,d,f,p=[W,(f=function(e){c.insert(e)},function(e){e.root||(e=e.return)&&f(e)})],g=(u=[ee,te].concat(a,p),d=h(u),function(e,t,n,r){for(var o="",i=0;i<d;i++)o+=u[i](e,t,n,r)||"";return o});i=function(e,t,n,r){c=n,V(U(e?e+"{"+t.styles+"}":t.styles),g),r&&(m.inserted[t.name]=!0)};var m={key:t,sheet:new o({key:t,container:r,nonce:e.nonce,speedy:e.speedy,prepend:e.prepend,insertionPoint:e.insertionPoint}),nonce:e.nonce,inserted:l,registered:{},insert:i};return m.sheet.hydrate(s),m},ie=n(966),ae=n(2855),le=n(6126),se=r.createContext("undefined"!=typeof HTMLElement?oe({key:"css"}):null),ce=(se.Provider,function(){return(0,r.useContext)(se)}),ue=function(e){return(0,r.forwardRef)(function(t,n){var o=(0,r.useContext)(se);return e(t,o,n)})},de=r.createContext({}),fe={}.hasOwnProperty,pe="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",he=function(e,t){var n={};for(var r in t)fe.call(t,r)&&(n[r]=t[r]);return n[pe]=e,n},ge=function(e){var t=e.cache,n=e.serialized,r=e.isStringTag;return(0,ie.SF)(t,n,r),(0,le.s)(function(){return(0,ie.sk)(t,n,r)}),null},me=ue(function(e,t,n){var o=e.css;"string"==typeof o&&void 0!==t.registered[o]&&(o=t.registered[o]);var i=e[pe],a=[o],l="";"string"==typeof e.className?l=(0,ie.Rk)(t.registered,a,e.className):null!=e.className&&(l=e.className+" ");var s=(0,ae.J)(a,void 0,r.useContext(de));l+=t.key+"-"+s.name;var c={};for(var u in e)fe.call(e,u)&&"css"!==u&&u!==pe&&(c[u]=e[u]);return c.className=l,n&&(c.ref=n),r.createElement(r.Fragment,null,r.createElement(ge,{cache:t,serialized:s,isStringTag:"string"==typeof i}),r.createElement(i,c))})},553(e,t,n){"use strict";n.d(t,{AH:()=>f,i7:()=>p,mL:()=>d});var r,o,i=n(1733),a=n(405),l=n(966),s=n(6126),c=n(2855),u=(n(4674),function(e,t){var n=arguments;if(null==t||!i.h.call(t,"css"))return a.createElement.apply(void 0,n);var r=n.length,o=new Array(r);o[0]=i.E,o[1]=(0,i.c)(e,t);for(var l=2;l<r;l++)o[l]=n[l];return a.createElement.apply(null,o)});r=u||(u={}),o||(o=r.JSX||(r.JSX={}));var d=(0,i.w)(function(e,t){var n=e.styles,r=(0,c.J)([n],void 0,a.useContext(i.T)),o=a.useRef();return(0,s.i)(function(){var e=t.key+"-global",n=new t.sheet.constructor({key:e,nonce:t.sheet.nonce,container:t.sheet.container,speedy:t.sheet.isSpeedy}),i=!1,a=document.querySelector('style[data-emotion="'+e+" "+r.name+'"]');return t.sheet.tags.length&&(n.before=t.sheet.tags[0]),null!==a&&(i=!0,a.setAttribute("data-emotion",e),n.hydrate([a])),o.current=[n,i],function(){n.flush()}},[t]),(0,s.i)(function(){var e=o.current,n=e[0];if(e[1])e[1]=!1;else{if(void 0!==r.next&&(0,l.sk)(t,r.next,!0),n.tags.length){var i=n.tags[n.tags.length-1].nextElementSibling;n.before=i,n.flush()}t.insert("",r,n,!1)}},[t,r.name]),null});function f(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return(0,c.J)(t)}function p(){var e=f.apply(void 0,arguments),t="animation-"+e.name;return{name:t,styles:"@keyframes "+t+"{"+e.styles+"}",anim:1,toString:function(){return"_EMO_"+this.name+"_"+this.styles+"_EMO_"}}}},2855(e,t,n){"use strict";n.d(t,{J:()=>h});var r={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},o=n(8371),i=/[A-Z]|^ms/g,a=/_EMO_([^_]+?)_([^]*?)_EMO_/g,l=function(e){return 45===e.charCodeAt(1)},s=function(e){return null!=e&&"boolean"!=typeof e},c=(0,o.A)(function(e){return l(e)?e:e.replace(i,"-$&").toLowerCase()}),u=function(e,t){switch(e){case"animation":case"animationName":if("string"==typeof t)return t.replace(a,function(e,t,n){return f={name:t,styles:n,next:f},t})}return 1===r[e]||l(e)||"number"!=typeof t||0===t?t:t+"px"};function d(e,t,n){if(null==n)return"";var r=n;if(void 0!==r.__emotion_styles)return r;switch(typeof n){case"boolean":return"";case"object":var o=n;if(1===o.anim)return f={name:o.name,styles:o.styles,next:f},o.name;var i=n;if(void 0!==i.styles){var a=i.next;if(void 0!==a)for(;void 0!==a;)f={name:a.name,styles:a.styles,next:f},a=a.next;return i.styles+";"}return function(e,t,n){var r="";if(Array.isArray(n))for(var o=0;o<n.length;o++)r+=d(e,t,n[o])+";";else for(var i in n){var a=n[i];if("object"!=typeof a){var l=a;null!=t&&void 0!==t[l]?r+=i+"{"+t[l]+"}":s(l)&&(r+=c(i)+":"+u(i,l)+";")}else if(!Array.isArray(a)||"string"!=typeof a[0]||null!=t&&void 0!==t[a[0]]){var f=d(e,t,a);switch(i){case"animation":case"animationName":r+=c(i)+":"+f+";";break;default:r+=i+"{"+f+"}"}}else for(var p=0;p<a.length;p++)s(a[p])&&(r+=c(i)+":"+u(i,a[p])+";")}return r}(e,t,n);case"function":if(void 0!==e){var l=f,p=n(e);return f=l,d(e,t,p)}}var h=n;if(null==t)return h;var g=t[h];return void 0!==g?g:h}var f,p=/label:\s*([^\s;{]+)\s*(;|$)/g;function h(e,t,n){if(1===e.length&&"object"==typeof e[0]&&null!==e[0]&&void 0!==e[0].styles)return e[0];var r=!0,o="";f=void 0;var i=e[0];null==i||void 0===i.raw?(r=!1,o+=d(n,t,i)):o+=i[0];for(var a=1;a<e.length;a++)o+=d(n,t,e[a]),r&&(o+=i[a]);p.lastIndex=0;for(var l,s="";null!==(l=p.exec(o));)s+="-"+l[1];var c=function(e){for(var t,n=0,r=0,o=e.length;o>=4;++r,o-=4)t=1540483477*(65535&(t=255&e.charCodeAt(r)|(255&e.charCodeAt(++r))<<8|(255&e.charCodeAt(++r))<<16|(255&e.charCodeAt(++r))<<24))+(59797*(t>>>16)<<16),n=1540483477*(65535&(t^=t>>>24))+(59797*(t>>>16)<<16)^1540483477*(65535&n)+(59797*(n>>>16)<<16);switch(o){case 3:n^=(255&e.charCodeAt(r+2))<<16;case 2:n^=(255&e.charCodeAt(r+1))<<8;case 1:n=1540483477*(65535&(n^=255&e.charCodeAt(r)))+(59797*(n>>>16)<<16)}return(((n=1540483477*(65535&(n^=n>>>13))+(59797*(n>>>16)<<16))^n>>>15)>>>0).toString(36)}(o)+s;return{name:c,styles:o,next:f}}},6126(e,t,n){"use strict";var r;n.d(t,{i:()=>l,s:()=>a});var o=n(405),i=!!(r||(r=n.t(o,2))).useInsertionEffect&&(r||(r=n.t(o,2))).useInsertionEffect,a=i||function(e){return e()},l=i||o.useLayoutEffect},966(e,t,n){"use strict";function r(e,t,n){var r="";return n.split(" ").forEach(function(n){void 0!==e[n]?t.push(e[n]+";"):n&&(r+=n+" ")}),r}n.d(t,{Rk:()=>r,SF:()=>o,sk:()=>i});var o=function(e,t,n){var r=e.key+"-"+t.name;!1===n&&void 0===e.registered[r]&&(e.registered[r]=t.styles)},i=function(e,t,n){o(e,t,n);var r=e.key+"-"+t.name;if(void 0===e.inserted[t.name]){var i=t;do{e.insert(t===i?"."+r:"",i,e.sheet,!0),i=i.next}while(void 0!==i)}}},7085(e,t,n){"use strict";function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function o(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function i(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?o(Object(n),!0).forEach(function(t){a(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):o(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function a(e,t,n){return(t=d(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e){return l="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},l(e)}function s(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function c(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,d(r.key),r)}}function u(e,t,n){return t&&c(e.prototype,t),n&&c(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function d(e){var t=function(e){if("object"!=l(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=l(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==l(t)?t:t+""}function f(e){return e?"string"==typeof e?e:e+"":e}function p(e,t){for(var n=0,r=Object.keys(t);n<r.length;n++){var o=r[n];e=e.replace(new RegExp("\\{"+o+"\\}","gi"),t[o])}return e}function h(e){if(!e)throw new Error("cannot create a random attribute name for an undefined object");var t="";do{t="";for(var n=0;n<12;n++)t+="ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz"[Math.floor(51*Math.random())]}while(e[t]);return t}function g(e){var t={alphabetic:"alphabetic",hanging:"hanging",top:"text-before-edge",bottom:"text-after-edge",middle:"central"};return t[e]||t.alphabetic}n.r(t),n.d(t,{Context:()=>y});var m=function(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:10,n={},r=e.split(","),o=0;o<r.length;o+=2){var i="&"+r[o+1]+";",a=parseInt(r[o],t);n[i]="&#"+a+";"}return n["\\xa0"]=" ",n}("50,nbsp,51,iexcl,52,cent,53,pound,54,curren,55,yen,56,brvbar,57,sect,58,uml,59,copy,5a,ordf,5b,laquo,5c,not,5d,shy,5e,reg,5f,macr,5g,deg,5h,plusmn,5i,sup2,5j,sup3,5k,acute,5l,micro,5m,para,5n,middot,5o,cedil,5p,sup1,5q,ordm,5r,raquo,5s,frac14,5t,frac12,5u,frac34,5v,iquest,60,Agrave,61,Aacute,62,Acirc,63,Atilde,64,Auml,65,Aring,66,AElig,67,Ccedil,68,Egrave,69,Eacute,6a,Ecirc,6b,Euml,6c,Igrave,6d,Iacute,6e,Icirc,6f,Iuml,6g,ETH,6h,Ntilde,6i,Ograve,6j,Oacute,6k,Ocirc,6l,Otilde,6m,Ouml,6n,times,6o,Oslash,6p,Ugrave,6q,Uacute,6r,Ucirc,6s,Uuml,6t,Yacute,6u,THORN,6v,szlig,70,agrave,71,aacute,72,acirc,73,atilde,74,auml,75,aring,76,aelig,77,ccedil,78,egrave,79,eacute,7a,ecirc,7b,euml,7c,igrave,7d,iacute,7e,icirc,7f,iuml,7g,eth,7h,ntilde,7i,ograve,7j,oacute,7k,ocirc,7l,otilde,7m,ouml,7n,divide,7o,oslash,7p,ugrave,7q,uacute,7r,ucirc,7s,uuml,7t,yacute,7u,thorn,7v,yuml,ci,fnof,sh,Alpha,si,Beta,sj,Gamma,sk,Delta,sl,Epsilon,sm,Zeta,sn,Eta,so,Theta,sp,Iota,sq,Kappa,sr,Lambda,ss,Mu,st,Nu,su,Xi,sv,Omicron,t0,Pi,t1,Rho,t3,Sigma,t4,Tau,t5,Upsilon,t6,Phi,t7,Chi,t8,Psi,t9,Omega,th,alpha,ti,beta,tj,gamma,tk,delta,tl,epsilon,tm,zeta,tn,eta,to,theta,tp,iota,tq,kappa,tr,lambda,ts,mu,tt,nu,tu,xi,tv,omicron,u0,pi,u1,rho,u2,sigmaf,u3,sigma,u4,tau,u5,upsilon,u6,phi,u7,chi,u8,psi,u9,omega,uh,thetasym,ui,upsih,um,piv,812,bull,816,hellip,81i,prime,81j,Prime,81u,oline,824,frasl,88o,weierp,88h,image,88s,real,892,trade,89l,alefsym,8cg,larr,8ch,uarr,8ci,rarr,8cj,darr,8ck,harr,8dl,crarr,8eg,lArr,8eh,uArr,8ei,rArr,8ej,dArr,8ek,hArr,8g0,forall,8g2,part,8g3,exist,8g5,empty,8g7,nabla,8g8,isin,8g9,notin,8gb,ni,8gf,prod,8gh,sum,8gi,minus,8gn,lowast,8gq,radic,8gt,prop,8gu,infin,8h0,ang,8h7,and,8h8,or,8h9,cap,8ha,cup,8hb,int,8hk,there4,8hs,sim,8i5,cong,8i8,asymp,8j0,ne,8j1,equiv,8j4,le,8j5,ge,8k2,sub,8k3,sup,8k4,nsub,8k6,sube,8k7,supe,8kl,oplus,8kn,otimes,8l5,perp,8m5,sdot,8o8,lceil,8o9,rceil,8oa,lfloor,8ob,rfloor,8p9,lang,8pa,rang,9ea,loz,9j0,spades,9j3,clubs,9j5,hearts,9j6,diams,ai,OElig,aj,oelig,b0,Scaron,b1,scaron,bo,Yuml,m6,circ,ms,tilde,802,ensp,803,emsp,809,thinsp,80c,zwnj,80d,zwj,80e,lrm,80f,rlm,80j,ndash,80k,mdash,80o,lsquo,80p,rsquo,80q,sbquo,80s,ldquo,80t,rdquo,80u,bdquo,810,dagger,811,Dagger,81g,permil,81p,lsaquo,81q,rsaquo,85c,euro",32),A={strokeStyle:{svgAttr:"stroke",canvas:"#000000",svg:"none",apply:"stroke"},fillStyle:{svgAttr:"fill",canvas:"#000000",svg:null,apply:"fill"},lineCap:{svgAttr:"stroke-linecap",canvas:"butt",svg:"butt",apply:"stroke"},lineJoin:{svgAttr:"stroke-linejoin",canvas:"miter",svg:"miter",apply:"stroke"},miterLimit:{svgAttr:"stroke-miterlimit",canvas:10,svg:4,apply:"stroke"},lineWidth:{svgAttr:"stroke-width",canvas:1,svg:1,apply:"stroke"},globalAlpha:{svgAttr:"opacity",canvas:1,svg:1,apply:"fill stroke"},font:{canvas:"10px sans-serif"},shadowColor:{canvas:"#000000"},shadowOffsetX:{canvas:0},shadowOffsetY:{canvas:0},shadowBlur:{canvas:0},textAlign:{canvas:"start"},textBaseline:{canvas:"alphabetic"},lineDash:{svgAttr:"stroke-dasharray",canvas:[],svg:null,apply:"stroke"}},b=function(){return u(function e(t,n){s(this,e),this.__root=t,this.__ctx=n},[{key:"addColorStop",value:function(e,t){var n=this.__ctx.__createElement("stop");if(n.setAttribute("offset",String(e)),f(t).includes("rgba")){var r=/rgba\(\s*(\d*\.?\d+)\s*,\s*(\d*\.?\d+)\s*,\s*(\d*\.?\d+)\s*,\s*(\d?\.?\d*)\s*\)/gi.exec(t);r&&(n.setAttribute("stop-color",p("rgb({r},{g},{b})",{r:r[1],g:r[2],b:r[3]})),n.setAttribute("stop-opacity",r[4]))}else n.setAttribute("stop-color",f(t));this.__root.appendChild(n)}}])}(),v=u(function e(t,n){s(this,e),this.__root=t,this.__ctx=n}),y=function(){return u(function e(t,n){s(this,e);var r,o={width:500,height:500,enableMirroring:!1};r="number"==typeof t&&void 0!==n?i(i({},o),{},{width:t,height:n}):t&&"object"===l(t)?t:o,this.width=r.width||o.width,this.height=r.height||o.height,this.enableMirroring=void 0!==r.enableMirroring?r.enableMirroring:o.enableMirroring,this.canvas=this,this.__document=r.document||document,r.ctx?this.__ctx=r.ctx:(this.__canvas=this.__document.createElement("canvas"),this.__ctx=this.__canvas.getContext("2d")),this.__setDefaultStyles(),this.__styleStack=[this.__getStyleState()],this.__groupStack=[],this.__root=this.__document.createElementNS("http://www.w3.org/2000/svg","svg"),this.__root.setAttribute("version","1.1"),this.__root.setAttribute("xmlns","http://www.w3.org/2000/svg"),this.__root.setAttributeNS("http://www.w3.org/2000/xmlns/","xmlns:xlink","http://www.w3.org/1999/xlink"),this.__root.setAttribute("width",String(this.width)),this.__root.setAttribute("height",String(this.height)),this.__ids={},this.__defs=this.__document.createElementNS("http://www.w3.org/2000/svg","defs"),this.__root.appendChild(this.__defs),this.__currentElement=this.__document.createElementNS("http://www.w3.org/2000/svg","g"),this.__root.appendChild(this.__currentElement),this.__currentDefaultPath="",this.__currentPosition={},this.__transformMatrix=new DOMMatrix,this.resetTransform(),this.__options=r,this.__id=Math.random().toString(16).substring(2,8)},[{key:"__createElement",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0,r=this.__document.createElementNS("http://www.w3.org/2000/svg",e);n&&(r.setAttribute("fill","none"),r.setAttribute("stroke","none"));for(var o=0,i=Object.keys(t);o<i.length;o++){var a=i[o];r.setAttribute(a,t[a])}return r}},{key:"__setDefaultStyles",value:function(){for(var e=0,t=Object.keys(A);e<t.length;e++){var n=t[e];this[n]=A[n].canvas}}},{key:"__applyStyleState",value:function(e){for(var t=0,n=Object.keys(e);t<n.length;t++){var r=n[t];this[r]=e[r]}}},{key:"__getStyleState",value:function(){for(var e={},t=0,n=Object.keys(A);t<n.length;t++){var r=n[t];e[r]=this[r]}return e}},{key:"__applyTransformation",value:function(e,t){var n=t||this.getTransform(),r=n.a,o=n.b,i=n.c,a=n.d,l=n.e,s=n.f;e.setAttribute("transform","matrix(".concat(r," ").concat(o," ").concat(i," ").concat(a," ").concat(l," ").concat(s,")"))}},{key:"__applyStyleToCurrentElement",value:function(e){var t=this.__currentElement,n=this.__currentElementsToStyle;if(n){t.setAttribute(e,""),t=n.element;var o,i=function(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return r(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var o=0,i=function(){};return{s:i,n:function(){return o>=e.length?{done:!0}:{done:!1,value:e[o++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,l=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return l=e.done,e},e:function(e){s=!0,a=e},f:function(){try{l||null==n.return||n.return()}finally{if(s)throw a}}}}(n.children);try{for(i.s();!(o=i.n()).done;)o.value.setAttribute(e,"")}catch(e){i.e(e)}finally{i.f()}}for(var a=0,l=Object.keys(A);a<l.length;a++){var s=l[a],c=A[s],u=this[s];if(c.apply)if(u instanceof v){if(u.__ctx)for(var d=0,f=Array.from(u.__ctx.__defs.childNodes);d<f.length;d++){var h=f[d],g=h.getAttribute("id");g&&(this.__ids[g]=g,this.__defs.appendChild(h))}t.setAttribute(c.apply,p("url(#{id})",{id:u.__root.getAttribute("id")}))}else if(u instanceof b)t.setAttribute(c.apply,p("url(#{id})",{id:u.__root.getAttribute("id")}));else if(c.apply.includes(e)&&c.svg!==u)if(("stroke"===c.svgAttr||"fill"===c.svgAttr)&&u&&u.includes("rgba")){var m=/rgba\(\s*(\d*\.?\d+)\s*,\s*(\d*\.?\d+)\s*,\s*(\d*\.?\d+)\s*,\s*(\d?\.?\d*)\s*\)/gi.exec(u);if(m){t.setAttribute(c.svgAttr,p("rgb({r},{g},{b})",{r:m[1],g:m[2],b:m[3]}));var y=Number(m[4]),w=this.globalAlpha;null!=w&&(y*=w),t.setAttribute(c.svgAttr+"-opacity",String(y))}}else{var C=c.svgAttr,S=u;if("globalAlpha"===s){if(C=e+"-"+c.svgAttr,t.getAttribute(C))continue}else if("lineWidth"===s){var x=this.__getTransformScale();S=u*Math.max(x.x,x.y)}t.setAttribute(C,S)}}}},{key:"__closestGroupOrSvg",value:function(e){return"g"===(e=e||this.__currentElement).nodeName||"svg"===e.nodeName?e:this.__closestGroupOrSvg(e.parentNode)}},{key:"getSerializedSvg",value:function(e){var t=(new XMLSerializer).serializeToString(this.__root);if(/xmlns="http:\/\/www\.w3\.org\/2000\/svg".+xmlns="http:\/\/www\.w3\.org\/2000\/svg/gi.test(t)&&(t=t.replace('xmlns="http://www.w3.org/2000/svg','xmlns:xlink="http://www.w3.org/1999/xlink')),e)for(var n=0,r=Object.keys(m);n<r.length;n++){var o=r[n],i=new RegExp(o,"gi");i.test(t)&&(t=t.replace(i,m[o]))}return t}},{key:"getSvg",value:function(){return this.__root}},{key:"save",value:function(){var e=this.__createElement("g"),t=this.__closestGroupOrSvg();this.__groupStack.push(t),t.appendChild(e),this.__currentElement=e;var n=this.__getStyleState();this.__styleStack.push(n),this.__transformMatrixStack||(this.__transformMatrixStack=[]),this.__transformMatrixStack.push(this.getTransform())}},{key:"restore",value:function(){this.__currentElement=this.__groupStack.pop(),this.__currentElementsToStyle=void 0,this.__currentElement||(this.__currentElement=this.__root.childNodes[1]);var e=this.__styleStack.pop();this.__applyStyleState(e),this.__transformMatrixStack&&this.__transformMatrixStack.length>0&&this.setTransform(this.__transformMatrixStack.pop())}},{key:"beginPath",value:function(){this.__currentDefaultPath="",this.__currentPosition={};var e=this.__createElement("path",{},!0);this.__closestGroupOrSvg().appendChild(e),this.__currentElement=e}},{key:"__applyCurrentDefaultPath",value:function(){var e=this.__currentElement;"path"===e.nodeName&&e.setAttribute("d",this.__currentDefaultPath)}},{key:"__addPathCommand",value:function(e){this.__currentDefaultPath+=" ",this.__currentDefaultPath+=e}},{key:"moveTo",value:function(e,t){"path"!==this.__currentElement.nodeName&&this.beginPath(),this.__currentPosition={x:e,y:t},this.__addPathCommand(p("M {x} {y}",{x:this.__matrixTransform(e,t).x,y:this.__matrixTransform(e,t).y}))}},{key:"closePath",value:function(){this.__currentDefaultPath&&this.__addPathCommand("Z")}},{key:"lineTo",value:function(e,t){this.__currentPosition={x:e,y:t},this.__currentDefaultPath.includes("M")?this.__addPathCommand(p("L {x} {y}",{x:this.__matrixTransform(e,t).x,y:this.__matrixTransform(e,t).y})):this.__addPathCommand(p("M {x} {y}",{x:this.__matrixTransform(e,t).x,y:this.__matrixTransform(e,t).y}))}},{key:"bezierCurveTo",value:function(e,t,n,r,o,i){this.__currentPosition={x:o,y:i},this.__addPathCommand(p("C {cp1x} {cp1y} {cp2x} {cp2y} {x} {y}",{cp1x:this.__matrixTransform(e,t).x,cp1y:this.__matrixTransform(e,t).y,cp2x:this.__matrixTransform(n,r).x,cp2y:this.__matrixTransform(n,r).y,x:this.__matrixTransform(o,i).x,y:this.__matrixTransform(o,i).y}))}},{key:"quadraticCurveTo",value:function(e,t,n,r){this.__currentPosition={x:n,y:r},this.__addPathCommand(p("Q {cpx} {cpy} {x} {y}",{cpx:this.__matrixTransform(e,t).x,cpy:this.__matrixTransform(e,t).y,x:this.__matrixTransform(n,r).x,y:this.__matrixTransform(n,r).y}))}},{key:"stroke",value:function(){"path"===this.__currentElement.nodeName&&this.__currentElement.setAttribute("paint-order","fill stroke markers"),this.__applyCurrentDefaultPath(),this.__applyStyleToCurrentElement("stroke")}},{key:"fill",value:function(){"path"===this.__currentElement.nodeName&&this.__currentElement.setAttribute("paint-order","stroke fill markers"),this.__applyCurrentDefaultPath(),this.__applyStyleToCurrentElement("fill")}},{key:"rect",value:function(e,t,n,r){"path"!==this.__currentElement.nodeName&&this.beginPath(),this.moveTo(e,t),this.lineTo(e+n,t),this.lineTo(e+n,t+r),this.lineTo(e,t+r),this.lineTo(e,t),this.closePath()}},{key:"__clearCanvas",value:function(){var e=this.__root.childNodes[1];this.__root.removeChild(e),this.__currentElement=this.__document.createElementNS("http://www.w3.org/2000/svg","g"),this.__root.appendChild(this.__currentElement),this.__groupStack=[]}},{key:"fillRect",value:function(e,t,n,r){var o=this.getTransform(),i=o.a,a=o.b,l=o.c,s=o.d,c=o.e,u=o.f;JSON.stringify([i,a,l,s,c,u])===JSON.stringify([1,0,0,1,0,0])&&0===e&&0===t&&n===this.width&&r===this.height&&this.__clearCanvas();var d=this.__createElement("rect",{x:e,y:t,width:n,height:r},!0);this.__closestGroupOrSvg().appendChild(d),this.__currentElement=d,this.__applyTransformation(d),this.__applyStyleToCurrentElement("fill")}},{key:"strokeRect",value:function(e,t,n,r){var o=this.__createElement("rect",{x:e,y:t,width:n,height:r},!0);this.__closestGroupOrSvg().appendChild(o),this.__currentElement=o,this.__applyTransformation(o),this.__applyStyleToCurrentElement("stroke")}},{key:"clearRect",value:function(e,t,n,r){var o=this.getTransform(),i=o.a,a=o.b,l=o.c,s=o.d,c=o.e,u=o.f;if(JSON.stringify([i,a,l,s,c,u])!==JSON.stringify([1,0,0,1,0,0])||0!==e||0!==t||n!==this.width||r!==this.height){var d=this.__createElement("rect",{x:e,y:t,width:n,height:r,fill:"#FFFFFF"},!0);this.__applyTransformation(d),this.__closestGroupOrSvg().appendChild(d)}else this.__clearCanvas()}},{key:"createLinearGradient",value:function(e,t,n,r){var o=this.__createElement("linearGradient",{id:h(this.__ids),x1:e+"px",x2:n+"px",y1:t+"px",y2:r+"px",gradientUnits:"userSpaceOnUse"});return this.__defs.appendChild(o),new b(o,this)}},{key:"createRadialGradient",value:function(e,t,n,r,o,i){var a=this.__createElement("radialGradient",{id:h(this.__ids),cx:r+"px",cy:o+"px",r:i+"px",fx:e+"px",fy:t+"px",gradientUnits:"userSpaceOnUse"});return this.__defs.appendChild(a),new b(a,this)}},{key:"__applyText",value:function(e,t,n,r){var o=document.createElement("span");o.setAttribute("style","font:"+this.font);var i,a,l=o.style,s=this.__closestGroupOrSvg(),c=this.__createElement("text",{"font-family":l.fontFamily,"font-size":l.fontSize,"font-style":l.fontStyle,"font-weight":l.fontWeight,"text-decoration":this.__fontUnderline,x:t,y:n,"text-anchor":(i=this.textAlign,a={left:"start",right:"end",center:"middle",start:"start",end:"end"},a[i]||a.start),"dominant-baseline":g(this.textBaseline)},!0);c.appendChild(this.__document.createTextNode(e)),this.__currentElement=c,this.__applyTransformation(c),this.__applyStyleToCurrentElement(r);var u=c;if(this.__fontHref){var d=this.__createElement("a");d.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",this.__fontHref),d.appendChild(c),u=d}s.appendChild(u)}},{key:"fillText",value:function(e,t,n){this.__applyText(e,t,n,"fill")}},{key:"strokeText",value:function(e,t,n){this.__applyText(e,t,n,"stroke")}},{key:"measureText",value:function(e){return this.__ctx.font=this.font,this.__ctx.measureText(e)}},{key:"arc",value:function(e,t,n,r,o,i){if(r!==o){(r%=2*Math.PI)==(o%=2*Math.PI)&&(o=(o+2*Math.PI-.001*(i?-1:1))%(2*Math.PI));var a,l=e+n*Math.cos(o),s=t+n*Math.sin(o),c=e+n*Math.cos(r),u=t+n*Math.sin(r),d=i?0:1,f=o-r;f<0&&(f+=2*Math.PI),a=i?f>Math.PI?0:1:f>Math.PI?1:0;var h=Math.hypot(this.__transformMatrix.a,this.__transformMatrix.b),g=Math.hypot(this.__transformMatrix.c,this.__transformMatrix.d);this.lineTo(c,u),this.__addPathCommand(p("A {rx} {ry} {xAxisRotation} {largeArcFlag} {sweepFlag} {endX} {endY}",{rx:n*h,ry:n*g,xAxisRotation:0,largeArcFlag:a,sweepFlag:d,endX:this.__matrixTransform(l,s).x,endY:this.__matrixTransform(l,s).y})),this.__currentPosition={x:l,y:s}}}},{key:"clip",value:function(){var e=this.__closestGroupOrSvg(),t=this.__createElement("clipPath"),n=h(this.__ids),r=this.__createElement("g");this.__applyCurrentDefaultPath(),e.removeChild(this.__currentElement),t.setAttribute("id",n),t.appendChild(this.__currentElement),this.__defs.appendChild(t),e.setAttribute("clip-path",p("url(#{id})",{id:n})),e.appendChild(r),this.__currentElement=r}},{key:"setLineDash",value:function(e){e&&e.length>0?this.lineDash=e.join(","):this.lineDash=null}},{key:"setTransform",value:function(e,t,n,r,o,i){e instanceof DOMMatrix?this.__transformMatrix=new DOMMatrix([e.a,e.b,e.c,e.d,e.e,e.f]):this.__transformMatrix=new DOMMatrix([e,t,n,r,o,i])}},{key:"getTransform",value:function(){var e=this.__transformMatrix,t=e.a,n=e.b,r=e.c,o=e.d,i=e.e,a=e.f;return new DOMMatrix([t,n,r,o,i,a])}},{key:"resetTransform",value:function(){this.setTransform(1,0,0,1,0,0)}},{key:"scale",value:function(e,t){if(void 0===t&&(t=e),!isNaN(e)&&!isNaN(t)&&isFinite(e)&&isFinite(t)){var n=this.getTransform().scale(e,t);this.setTransform(n)}}},{key:"rotate",value:function(e){var t=this.getTransform().multiply(new DOMMatrix([Math.cos(e),Math.sin(e),-Math.sin(e),Math.cos(e),0,0]));this.setTransform(t)}},{key:"translate",value:function(e,t){var n=this.getTransform().translate(e,t);this.setTransform(n)}},{key:"transform",value:function(e,t,n,r,o,i){var a=this.getTransform().multiply(new DOMMatrix([e,t,n,r,o,i]));this.setTransform(a)}},{key:"__matrixTransform",value:function(e,t){return new DOMPoint(e,t).matrixTransform(this.__transformMatrix)}},{key:"__getTransformScale",value:function(){return{x:Math.hypot(this.__transformMatrix.a,this.__transformMatrix.b),y:Math.hypot(this.__transformMatrix.c,this.__transformMatrix.d)}}},{key:"__getTransformRotation",value:function(){return Math.atan2(this.__transformMatrix.b,this.__transformMatrix.a)}},{key:"drawFocusRing",value:function(){}},{key:"createImageData",value:function(){}},{key:"putImageData",value:function(){}},{key:"globalCompositeOperation",value:function(){}},{key:"drawImage",value:function(){}},{key:"createPattern",value:function(){return null}}])}()},6439(e,t,n){"use strict";n.d(t,{A:()=>p});var r=n(7330),o=n(2765),i=n(3710),a=n(1683),l=n(5070),s=n(711),c=n(9168);function u(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,l=[],s=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw o}}return l}}(e,t)||function(e,t){if(e){if("string"==typeof e)return d(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?d(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function d(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}(0,l.X$)([s.A]);var f={none:{},clustal:{G:"orange",P:"orange",S:"orange",T:"orange",H:"red",K:"red",R:"red",F:"blue",W:"blue",Y:"blue",I:"green",L:"green",M:"green",V:"green"},lesk:{G:"orange",A:"orange",S:"orange",T:"orange",C:"green",V:"green",I:"green",L:"green",P:"green",F:"green",Y:"green",M:"green",W:"green",N:"magenta",Q:"magenta",H:"magenta",D:"red",E:"red",K:"blue",R:"blue"},maeditor:{A:"lightgreen",G:"lightgreen",C:"green",D:"darkgreen",E:"darkgreen",N:"darkgreen",Q:"darkgreen",I:"blue",L:"blue",M:"blue",V:"blue",F:"#c8a2c8",W:"#c8a2c8",Y:"#c8a2c8",H:"darkblue",K:"orange",R:"orange",P:"pink",S:"red",T:"red"},percent_identity_dynamic:{},flower:{A:"#b18a51",C:"#ff5701",D:"#01a578",E:"#2da0a1",F:"#fa559d",G:"#b1c23c",H:"#0194f9",I:"#f27663",K:"#7fc3d7",L:"#df6e75",M:"#fe9daf",N:"#0bcec6",P:"#4fa32a",Q:"#7295ae",R:"#83bff1",S:"#b4bd9b",T:"#d2b576",V:"#fd997b",W:"#ff2ded",Y:"#c96ecf"},rainbow_dna:{A:"#3737f5",C:"#37f537",G:"#f5f537",T:"#f53737",U:"#f53737"},clustalx_protein:{A:"#197fe5",C:"#e57f7f",D:"#cc4ccc",E:"#cc4ccc",F:"#197fe5",G:"#e5994c",H:"#19b2b2",I:"#197fe5",K:"#e53319",L:"#197fe5",M:"#197fe5",N:"#19cc19",P:"#cccc00",Q:"#19cc19",R:"#e53319",S:"#19cc19",T:"#19cc19",V:"#197fe5",W:"#197fe5",Y:"#19b2b2"},clustalx_protein_dynamic:{},clustalx_dna:{A:"#e53319",C:"#197fe5",G:"#e5994c",T:"#19cc19",U:"#19cc19"},jbrowse_dna:{A:i.A[500],C:o.A[500],G:a.A[500],T:r.A[500],U:r.A[500]},jalview_buried:{A:"#00a35c",R:"#00fc03",N:"#00eb14",D:"#00eb14",C:"#0000ff",Q:"#00f10e",E:"#00f10e",G:"#009d62",H:"#00d52a",I:"#0054ab",L:"#007b84",K:"#00ff00",M:"#009768",F:"#008778",P:"#00e01f",S:"#00d52a",T:"#00db24",W:"#00a857",Y:"#00e619",V:"#005fa0",B:"#00eb14",X:"#00b649",Z:"#00f10e"},jalview_hydrophobicity:{A:"#ad0052",R:"#0000ff",N:"#0c00f3",D:"#0c00f3",C:"#c2003d",Q:"#0c00f3",E:"#0c00f3",G:"#6a0095",H:"#1500ea",I:"#ff0000",L:"#ea0015",K:"#0000ff",M:"#b0004f",F:"#cb0034",P:"#4600b9",S:"#5e00a1",T:"#61009e",W:"#5b00a4",Y:"#4f00b0",V:"#f60009",B:"#0c00f3",X:"#680097",Z:"#0c00f3"},jalview_prophelix:{A:"#e718e7",R:"#6f906f",N:"#1be41b",D:"#778877",C:"#23dc23",Q:"#926d92",E:"#ff00ff",G:"#00ff00",H:"#758a75",I:"#8a758a",L:"#ae51ae",K:"#a05fa0",M:"#ef10ef",F:"#986798",P:"#00ff00",S:"#36c936",T:"#47b847",W:"#8a758a",Y:"#21de21",V:"#857a85",B:"#49b649",X:"#758a75",Z:"#c936c9"},jalview_propstrand:{A:"#5858a7",R:"#6b6b94",N:"#64649b",D:"#2121de",C:"#9d9d62",Q:"#8c8c73",E:"#0000ff",G:"#4949b6",H:"#60609f",I:"#ecec13",L:"#b2b24d",K:"#4747b8",M:"#82827d",F:"#c2c23d",P:"#2323dc",S:"#4949b6",T:"#9d9d62",W:"#c0c03f",Y:"#d3d32c",V:"#ffff00",B:"#4343bc",X:"#797986",Z:"#4747b8"},jalview_propturn:{A:"#2cd3d3",R:"#708f8f",N:"#ff0000",D:"#e81717",C:"#a85757",Q:"#3fc0c0",E:"#778888",G:"#ff0000",H:"#708f8f",I:"#00ffff",L:"#1ce3e3",K:"#7e8181",M:"#1ee1e1",F:"#1ee1e1",P:"#f60909",S:"#e11e1e",T:"#738c8c",W:"#738c8c",Y:"#9d6262",V:"#07f8f8",B:"#f30c0c",X:"#7c8383",Z:"#5ba4a4"},jalview_taylor:{A:"#ccff00",R:"#0000ff",N:"#cc00ff",D:"#ff0000",C:"#ffff00",Q:"#ff00cc",E:"#ff0066",G:"#ff9900",H:"#0066ff",I:"#66ff00",L:"#33ff00",K:"#6600ff",M:"#00ff00",F:"#00ff66",P:"#ffcc00",S:"#ff3300",T:"#ff6600",W:"#00ccff",Y:"#00ffcc",V:"#99ff00"},jalview_zappo:{A:"#ffafaf",R:"#6464ff",N:"#00ff00",D:"#ff0000",C:"#ffff00",Q:"#00ff00",E:"#ff0000",G:"#ff00ff",H:"#6464ff",I:"#ffafaf",L:"#ffafaf",K:"#6464ff",M:"#ffafaf",F:"#ffc800",P:"#ff00ff",S:"#00ff00",T:"#00ff00",W:"#ffc800",Y:"#ffc800",V:"#ffafaf"},cinema:{H:"blue",K:"blue",R:"blue",D:"red",E:"red",S:"green",T:"green",N:"green",Q:"green",A:"white",V:"white",L:"white",I:"white",M:"white",F:"magenta",W:"magenta",Y:"magenta",P:"brown",G:"brown",C:"yellow",B:"gray",Z:"gray",X:"gray","-":"gray",".":"gray"}};const p=(0,c.pd)(f,function(e){var t=u(e,2),n=t[0],r=t[1];return[n,(0,c.pd)(r,function(e){var t=u(e,2),n=t[0],r=t[1];return[n,(0,l.Mj)(r).toHex()]})]})},4760(e,t,n){"use strict";n.d(t,{A:()=>a});var r=n(405),o=n(6807),i=n(548);function a(e){var t=e.checked,n=e.label,a=e.disabled,l=e.onChange;return r.createElement("div",null,r.createElement(o.A,{control:r.createElement(i.A,{disabled:a,checked:t,onChange:l}),label:n}))}},9446(e,t,n){"use strict";n.d(t,{A:()=>f});var r=n(405),o=n(7346),i=n(2509),a=n(8998),l=n(4760),s=n(8053);function c(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,l=[],s=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw o}}return l}}(e,t)||function(e,t){if(e){if("string"==typeof e)return u(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?u(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function u(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var d=(0,a.n9)()({textAreaFont:{fontFamily:"Courier New",wordWrap:"break-word"},dialogContent:{background:"lightgrey",margin:4,minWidth:"80em"}});function f(e){var t=e.str,n=d().classes,a=c((0,r.useState)(!1),2),u=a[0],f=a[1],p=c((0,r.useState)(!1),2),h=p[0],g=p[1],m=c((0,r.useState)(!1),2),A=m[0],b=m[1],v=t.map(function(e){var t,n=c(e,2),r=n[0],o=n[1];return[r,h?o:(t=o,t.replaceAll("-","").replaceAll(".",""))]}).filter(function(e){var t=c(e,2)[1];return A||!!t}).map(function(e){var t=c(e,2),n=t[0],r=t[1];return">".concat(n,"\n").concat(r)}).join("\n");return r.createElement(r.Fragment,null,r.createElement(o.A,{color:"primary",variant:"contained",onClick:function(){(0,s.A)(v),f(!0),setTimeout(function(){f(!1)},500)}},u?"Copied!":"Copy to clipboard"),r.createElement(l.A,{label:"Show gaps",checked:h,onChange:function(){g(!h)}}),r.createElement(l.A,{label:"Show empty",checked:A,onChange:function(){b(!A)}}),r.createElement(i.A,{variant:"outlined",multiline:!0,className:n.dialogContent,minRows:5,maxRows:10,fullWidth:!0,value:v,slotProps:{input:{readOnly:!0,className:n.textAreaFont}}}))}},102(e,t,n){"use strict";n.r(t),n.d(t,{default:()=>s});var r=n(405),o=n(9936),i=n(8647),a=n(4871),l=n(4417);function s(e){var t=e.onClose;return r.createElement(o.A,{open:!0,title:"About",onClose:function(){t()}},r.createElement(i.A,null,r.createElement(a.A,null,"MSAView ","5.2.1"," (",r.createElement(l.A,{href:"https://github.com/gmod/react-msaview"},"Github"),")"),r.createElement("ul",null,r.createElement("li",null,r.createElement(a.A,null,"We use some color schemes from the"," ",r.createElement(l.A,{href:"https://github.com/biotite-dev/biotite"},"biotite")," ","project, and their license is reproduced"," ",r.createElement(l.A,{href:"https://github.com/biotite-dev/biotite/blob/master/LICENSE.rst"},"here"))),r.createElement("li",null,r.createElement(a.A,null,"See this page for some information on jalview colorings"," ",r.createElement(l.A,{href:"https://www.jalview.org/help/html/colourSchemes/"},"here"))),r.createElement("li",null,r.createElement(a.A,null,"See this page for some info on the clustal, cinema, maeditor, and lesk color schemes"," ",r.createElement(l.A,{href:"http://www.bioinformatics.nl/~berndb/aacolour.html"},"here"))),r.createElement("li",null,r.createElement(a.A,null,"See this paper about the flower color scheme"," ",r.createElement(l.A,{href:"https://www.ncbi.nlm.nih.gov/pmc/articles/PMC7245768/"},"here"))))))}},9304(e,t,n){"use strict";n.r(t),n.d(t,{default:()=>W});var r=n(405),o=n(9936),i=n(6677),a=n(5835),l=n(8647),s=n(4871),c=n(3186),u=n(6259),d=n(8450),f=n(6807),p=n(719),h=n(851),g=n(941),m=n(912),A=n(9861),b=n(8717),v=n(2369),y=n(8650),w=n(3724),C=n(6376),S=n(8783),x=n(643);function E(e){return(0,x.Ay)("MuiAlert",e)}const I=(0,S.A)("MuiAlert",["root","action","icon","message","filled","colorSuccess","colorInfo","colorWarning","colorError","filledSuccess","filledInfo","filledWarning","filledError","outlined","outlinedSuccess","outlinedInfo","outlinedWarning","outlinedError","standard","standardSuccess","standardInfo","standardWarning","standardError"]);var k=n(8199),R=n(6493),M=n(9793);const P=(0,R.A)((0,M.jsx)("path",{d:"M20,12A8,8 0 0,1 12,20A8,8 0 0,1 4,12A8,8 0 0,1 12,4C12.76,4 13.5,4.11 14.2, 4.31L15.77,2.74C14.61,2.26 13.34,2 12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0, 0 22,12M7.91,10.08L6.5,11.5L11,16L21,6L19.59,4.58L11,13.17L7.91,10.08Z"}),"SuccessOutlined"),B=(0,R.A)((0,M.jsx)("path",{d:"M12 5.99L19.53 19H4.47L12 5.99M12 2L1 21h22L12 2zm1 14h-2v2h2v-2zm0-6h-2v4h2v-4z"}),"ReportProblemOutlined"),_=(0,R.A)((0,M.jsx)("path",{d:"M11 15h2v2h-2zm0-8h2v6h-2zm.99-5C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"}),"ErrorOutline"),T=(0,R.A)((0,M.jsx)("path",{d:"M11,9H13V7H11M12,20C7.59,20 4,16.41 4,12C4,7.59 7.59,4 12,4C16.41,4 20,7.59 20, 12C20,16.41 16.41,20 12,20M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10, 10 0 0,0 12,2M11,17H13V11H11V17Z"}),"InfoOutlined");var O=n(3118);const D=(0,m.Ay)(C.A,{name:"MuiAlert",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[n.variant],t[`${n.variant}${(0,y.A)(n.color||n.severity)}`]]}})((0,A.A)(({theme:e})=>{const t="light"===e.palette.mode?e.darken:e.lighten,n="light"===e.palette.mode?e.lighten:e.darken;return{...e.typography.body2,backgroundColor:"transparent",display:"flex",padding:"6px 16px",variants:[...Object.entries(e.palette).filter((0,w.A)(["light"])).map(([r])=>({props:{colorSeverity:r,variant:"standard"},style:{color:e.vars?e.vars.palette.Alert[`${r}Color`]:t(e.palette[r].light,.6),backgroundColor:e.vars?e.vars.palette.Alert[`${r}StandardBg`]:n(e.palette[r].light,.9),[`& .${I.icon}`]:e.vars?{color:e.vars.palette.Alert[`${r}IconColor`]}:{color:e.palette[r].main}}})),...Object.entries(e.palette).filter((0,w.A)(["light"])).map(([n])=>({props:{colorSeverity:n,variant:"outlined"},style:{color:e.vars?e.vars.palette.Alert[`${n}Color`]:t(e.palette[n].light,.6),border:`1px solid ${(e.vars||e).palette[n].light}`,[`& .${I.icon}`]:e.vars?{color:e.vars.palette.Alert[`${n}IconColor`]}:{color:e.palette[n].main}}})),...Object.entries(e.palette).filter((0,w.A)(["dark"])).map(([t])=>({props:{colorSeverity:t,variant:"filled"},style:{fontWeight:e.typography.fontWeightMedium,...e.vars?{color:e.vars.palette.Alert[`${t}FilledColor`],backgroundColor:e.vars.palette.Alert[`${t}FilledBg`]}:{backgroundColor:"dark"===e.palette.mode?e.palette[t].dark:e.palette[t].main,color:e.palette.getContrastText(e.palette[t].main)}}}))]}})),N=(0,m.Ay)("div",{name:"MuiAlert",slot:"Icon"})({marginRight:12,padding:"7px 0",display:"flex",fontSize:22,opacity:.9}),L=(0,m.Ay)("div",{name:"MuiAlert",slot:"Message"})({padding:"8px 0",minWidth:0,overflow:"auto"}),F=(0,m.Ay)("div",{name:"MuiAlert",slot:"Action"})({display:"flex",alignItems:"flex-start",padding:"4px 0 0 16px",marginLeft:"auto",marginRight:-8}),Q={success:(0,M.jsx)(P,{fontSize:"inherit"}),warning:(0,M.jsx)(B,{fontSize:"inherit"}),error:(0,M.jsx)(_,{fontSize:"inherit"}),info:(0,M.jsx)(T,{fontSize:"inherit"})},j=r.forwardRef(function(e,t){const n=(0,b.b)({props:e,name:"MuiAlert"}),{action:r,children:o,className:i,closeText:a="Close",color:l,components:s={},componentsProps:c={},icon:u,iconMapping:d=Q,onClose:f,role:p="alert",severity:m="success",slotProps:A={},slots:w={},variant:C="standard",...S}=n,x={...n,color:l,severity:m,variant:C,colorSeverity:l||m},I=(e=>{const{variant:t,color:n,severity:r,classes:o}=e,i={root:["root",`color${(0,y.A)(n||r)}`,`${t}${(0,y.A)(n||r)}`,`${t}`],icon:["icon"],message:["message"],action:["action"]};return(0,g.A)(i,E,o)})(x),R={slots:{closeButton:s.CloseButton,closeIcon:s.CloseIcon,...w},slotProps:{...c,...A}},[P,B]=(0,v.A)("root",{ref:t,shouldForwardComponentProp:!0,className:(0,h.A)(I.root,i),elementType:D,externalForwardedProps:{...R,...S},ownerState:x,additionalProps:{role:p,elevation:0}}),[_,T]=(0,v.A)("icon",{className:I.icon,elementType:N,externalForwardedProps:R,ownerState:x}),[j,z]=(0,v.A)("message",{className:I.message,elementType:L,externalForwardedProps:R,ownerState:x}),[$,H]=(0,v.A)("action",{className:I.action,elementType:F,externalForwardedProps:R,ownerState:x}),[G,V]=(0,v.A)("closeButton",{elementType:k.A,externalForwardedProps:R,ownerState:x}),[W,U]=(0,v.A)("closeIcon",{elementType:O.A,externalForwardedProps:R,ownerState:x});return(0,M.jsxs)(P,{...B,children:[!1!==u?(0,M.jsx)(_,{...T,children:u||d[m]||Q[m]}):null,(0,M.jsx)(j,{...z,children:o}),null!=r?(0,M.jsx)($,{...H,children:r}):null,null==r&&f?(0,M.jsx)($,{...H,children:(0,M.jsx)(G,{size:"small","aria-label":a,title:a,color:"inherit",onClick:f,...V,children:(0,M.jsx)(W,{fontSize:"small",...U})})}):null]})});var z=n(7252),$=n(7346),H=n(4760);function G(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,l=[],s=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw o}}return l}}(e,t)||function(e,t){if(e){if("string"==typeof e)return V(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?V(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function V(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function W(e){var t=e.model,n=e.onClose,h=G((0,r.useState)(!0),2),g=h[0],m=h[1],A=G((0,r.useState)(!0),2),b=A[0],v=A[1],y=G((0,r.useState)("viewport"),2),w=y[0],C=y[1],S=G((0,r.useState)(),2),x=S[0],E=S[1],I=(0,a.A)(),k=t.totalWidth,R=t.totalHeight,M=t.treeAreaWidth,P=t.turnedOnTracks,B=t.totalTrackAreaHeight,_=P.length>0,T=k+M,O=R+(b?B:0),D="entire"===w&&(T>1e4||O>1e4);return r.createElement(o.A,{onClose:function(){n()},open:!0,title:"Export SVG"},r.createElement(l.A,null,x?r.createElement(i.A,{error:x}):null,r.createElement(s.A,null,"Settings:"),r.createElement(H.A,{label:"Include minimap?",disabled:"entire"===w,checked:g,onChange:function(){m(!g)}}),_?r.createElement(H.A,{label:"Include tracks?",checked:b,onChange:function(){v(!b)}}):null,r.createElement("div",null,r.createElement(c.A,null,r.createElement(u.A,null,"Export type"),r.createElement(d.A,{value:w,onChange:function(e){var t=e.target.value;"entire"!==t&&"viewport"!==t||C(t)}},r.createElement(f.A,{value:"entire",control:r.createElement(p.A,null),label:"Entire MSA"}),r.createElement(f.A,{value:"viewport",control:r.createElement(p.A,null),label:"Current viewport only"})))),D?r.createElement(j,{severity:"warning",style:{marginTop:8}},"The entire MSA is very large (",Math.round(T),"x",Math.round(O)," pixels). Export may be slow or fail."):null),r.createElement(z.A,null,r.createElement($.A,{variant:"contained",color:"primary",onClick:function(){t.exportSVG({theme:I,includeMinimap:"entire"!==w&&g,includeTracks:_&&b,exportType:w}).then(function(){n()}).catch(function(e){console.error(e),E(e)})}},"Submit"),r.createElement($.A,{variant:"contained",color:"secondary",onClick:function(){n()}},"Cancel")))}},2820(e,t,n){"use strict";n.r(t),n.d(t,{default:()=>h});var r=n(405),o=n(9936),i=n(7346),a=n(8647),l=n(2020),s=n(3431);function c(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=u(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,l=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){l=!0,i=e},f:function(){try{a||null==n.return||n.return()}finally{if(l)throw i}}}}function u(e,t){if(e){if("string"==typeof e)return d(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?d(e,t):void 0}}function d(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var f=(0,l.PA)(function(e){var t=e.model,n=t.featureFilters;return r.createElement("div",null,r.createElement(i.A,{onClick:function(){var e,r=c(n.keys());try{for(r.s();!(e=r.n()).done;){var o=e.value;t.setFilter(o,!0)}}catch(e){r.e(e)}finally{r.f()}}},"Toggle all on"),r.createElement(i.A,{onClick:function(){var e,r=c(n.keys());try{for(r.s();!(e=r.n()).done;){var o=e.value;t.setFilter(o,!1)}}catch(e){r.e(e)}finally{r.f()}}},"Toggle all off"))}),p=(0,l.PA)(function(e){var t,n=e.model,o=n.tidyInterProAnnotationTypes,i=n.featureFilters,a=function(e){if(Array.isArray(e))return d(e)}(t=o.values())||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(t)||u(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),l=(0,s.S)(a.length-1);return r.createElement(r.Fragment,null,r.createElement(f,{model:n}),r.createElement("table",null,r.createElement("thead",null,r.createElement("tr",null,r.createElement("td",null),r.createElement("td",null,"accession"),r.createElement("td",null,"name"),r.createElement("td",null,"description"))),r.createElement("tbody",null,a.map(function(e,t){var o,a=e.accession,s=e.name,c=e.description;return r.createElement("tr",{key:a},r.createElement("td",null,r.createElement("input",{type:"checkbox",checked:null!==(o=i.get(a))&&void 0!==o&&o,onChange:function(){n.setFilter(a,!n.featureFilters.get(a))}})),r.createElement("td",null,a),r.createElement("td",null,s),r.createElement("td",null,c),r.createElement("td",null,r.createElement("div",{style:{width:20,height:20,background:l[t]||"black"}})))}))))});const h=(0,l.PA)(function(e){var t=e.onClose,n=e.model;return r.createElement(o.A,{onClose:function(){t()},open:!0,title:"Feature filters",maxWidth:"xl"},r.createElement(a.A,null,r.createElement(p,{model:n})))})},6574(e,t,n){"use strict";n.r(t),n.d(t,{default:()=>N});var r=n(405),o=n(9936),i=n(6081),a=n(8647),l=n(4871),s=n(7346),c=n(7252),u=n(2020),d=n(4567);function f(){var e,t,n="function"==typeof Symbol?Symbol:{},r=n.iterator||"@@iterator",o=n.toStringTag||"@@toStringTag";function i(n,r,o,i){var s=r&&r.prototype instanceof l?r:l,c=Object.create(s.prototype);return p(c,"_invoke",function(n,r,o){var i,l,s,c=0,u=o||[],d=!1,f={p:0,n:0,v:e,a:p,f:p.bind(e,4),d:function(t,n){return i=t,l=0,s=e,f.n=n,a}};function p(n,r){for(l=n,s=r,t=0;!d&&c&&!o&&t<u.length;t++){var o,i=u[t],p=f.p,h=i[2];n>3?(o=h===r)&&(s=i[(l=i[4])?5:(l=3,3)],i[4]=i[5]=e):i[0]<=p&&((o=n<2&&p<i[1])?(l=0,f.v=r,f.n=i[1]):p<h&&(o=n<3||i[0]>r||r>h)&&(i[4]=n,i[5]=r,f.n=h,l=0))}if(o||n>1)return a;throw d=!0,r}return function(o,u,h){if(c>1)throw TypeError("Generator is already running");for(d&&1===u&&p(u,h),l=u,s=h;(t=l<2?e:s)||!d;){i||(l?l<3?(l>1&&(f.n=-1),p(l,s)):f.n=s:f.v=s);try{if(c=2,i){if(l||(o="next"),t=i[o]){if(!(t=t.call(i,s)))throw TypeError("iterator result is not an object");if(!t.done)return t;s=t.value,l<2&&(l=0)}else 1===l&&(t=i.return)&&t.call(i),l<2&&(s=TypeError("The iterator does not provide a '"+o+"' method"),l=1);i=e}else if((t=(d=f.n<0)?s:n.call(r,f))!==a)break}catch(t){i=e,l=1,s=t}finally{c=1}}return{value:t,done:d}}}(n,o,i),!0),c}var a={};function l(){}function s(){}function c(){}t=Object.getPrototypeOf;var u=[][r]?t(t([][r]())):(p(t={},r,function(){return this}),t),d=c.prototype=l.prototype=Object.create(u);function h(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,c):(e.__proto__=c,p(e,o,"GeneratorFunction")),e.prototype=Object.create(d),e}return s.prototype=c,p(d,"constructor",c),p(c,"constructor",s),s.displayName="GeneratorFunction",p(c,o,"GeneratorFunction"),p(d),p(d,o,"Generator"),p(d,r,function(){return this}),p(d,"toString",function(){return"[object Generator]"}),(f=function(){return{w:i,m:h}})()}function p(e,t,n,r){var o=Object.defineProperty;try{o({},"",{})}catch(e){o=0}p=function(e,t,n,r){function i(t,n){p(e,t,function(e){return this._invoke(t,n,e)})}t?o?o(e,t,{value:n,enumerable:!r,configurable:!r,writable:!r}):e[t]=n:(i("next",0),i("throw",1),i("return",2))},p(e,t,n,r)}function h(e,t,n,r,o,i,a){try{var l=e[i](a),s=l.value}catch(e){return void n(e)}l.done?t(s):Promise.resolve(s).then(r,o)}function g(e){return function(){var t=this,n=arguments;return new Promise(function(r,o){var i=e.apply(t,n);function a(e){h(i,r,o,a,l,"next",e)}function l(e){h(i,r,o,a,l,"throw",e)}a(void 0)})}}var m="https://www.ebi.ac.uk/Tools/services/rest";function A(e){return b.apply(this,arguments)}function b(){return(b=g(f().m(function e(t){var n,r,o,i,a,l,s;return f().w(function(e){for(;;)switch(e.n){case 0:return n=t.seq,r=t.onProgress,o=t.onJobId,i=t.programs,a=t.model,l=t.signal,e.n=1,(0,d.y1)("".concat(m,"/iprscan5/run"),{method:"POST",body:new URLSearchParams({email:"colin.diesh@gmail.com",sequence:n,programs:i.join(",")}),signal:l});case 1:return s=e.v,null==o||o(s),e.n=2,y({jobId:s,onProgress:r,signal:l});case 2:return e.n=3,x({jobId:s,model:a,onProgress:r,signal:l});case 3:return e.a(2)}},e)}))).apply(this,arguments)}function v(e,t){return(0,d.jT)("".concat(m,"/iprscan5/result/").concat(e,"/json"),{signal:t})}function y(e){return w.apply(this,arguments)}function w(){return(w=g(f().m(function e(t){var n,r,o,i,a,l,s,c,u;return f().w(function(e){for(;;)switch(e.p=e.n){case 0:n=t.onProgress,r=t.jobId,o=t.signal,i="".concat(m,"/iprscan5/status/").concat(r),a=360,e.p=1,l=!1,s=0;case 2:if(!(s<a)||l){e.n=10;break}c=0;case 3:if(!(c<10)){e.n=6;break}return e.n=4,(0,d.wR)(1e3,o);case 4:n({msg:"Checking status ".concat(10-c),url:i});case 5:c++,e.n=3;break;case 6:return e.n=7,(0,d.y1)(i,{signal:o});case 7:if("FINISHED"!==(u=e.v.trim())){e.n=8;break}l=!0,e.n=9;break;case 8:if("FAILURE"!==u&&"ERROR"!==u&&"NOT_FOUND"!==u){e.n=9;break}throw new Error("InterProScan job ".concat(r," ended with status: ").concat(u));case 9:s++,e.n=2;break;case 10:if(l){e.n=11;break}throw new Error("InterProScan job ".concat(r," did not finish after ").concat(a," status checks"));case 11:return e.p=11,n(),e.f(11);case 12:return e.a(2)}},e,null,[[1,,11,12]])}))).apply(this,arguments)}function C(e){return S.apply(this,arguments)}function S(){return(S=g(f().m(function e(t){var n,r,o,a,l,s,c,u;return f().w(function(e){for(;;)switch(e.p=e.n){case 0:if(n=t.algorithm,r=t.seq,o=t.programs,a=t.onJobId,l=t.onProgress,s=t.model,c=t.signal,e.p=1,l({msg:"Launching ".concat(n," MSA")}),"interproscan"!==n){e.n=3;break}return e.n=2,A({seq:r,onJobId:a,onProgress:l,programs:o,model:s,signal:c});case 2:e.n=4;break;case 3:throw new Error("unknown algorithm");case 4:e.n=7;break;case 5:if(e.p=5,u=e.v,!(0,d.zf)(u)){e.n=6;break}(0,i.HtM)(s).notify("Cancelled InterProScan query","info"),e.n=7;break;case 6:throw u;case 7:return e.p=7,l(),e.f(7);case 8:return e.a(2)}},e,null,[[1,5,7,8]])}))).apply(this,arguments)}function x(e){return E.apply(this,arguments)}function E(){return(E=g(f().m(function e(t){var n,r,o,a,l,s;return f().w(function(e){for(;;)switch(e.p=e.n){case 0:return n=t.jobId,r=t.model,o=t.onProgress,a=t.signal,e.p=1,o({msg:"Downloading results of ".concat(n," (for larger sequences this can be slow, click status to download and upload in the manual tab)"),url:"https://www.ebi.ac.uk/Tools/services/rest/iprscan5/result/".concat(n,"/json")}),e.n=2,v(n,a);case 2:l=e.v,r.setDomains(Object.fromEntries(l.results.map(function(e){var t;return[null===(t=e.xref[0])||void 0===t?void 0:t.id,e]}).filter(function(e){return void 0!==e[0]}))),(0,i.HtM)(r).notify("Loaded interproscan ".concat(n," results"),"success"),e.n=4;break;case 3:e.p=3,s=e.v,(0,d.zf)(s)?(0,i.HtM)(r).notify("Cancelled InterProScan query","info"):(console.error(s),(0,i.HtM)(r).notifyError("".concat(s),s));case 4:return e.p=4,o(),e.f(4);case 5:return e.a(2)}},e,null,[[1,3,4,5]])}))).apply(this,arguments)}function I(e){return I="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},I(e)}function k(){var e,t,n="function"==typeof Symbol?Symbol:{},r=n.iterator||"@@iterator",o=n.toStringTag||"@@toStringTag";function i(n,r,o,i){var s=r&&r.prototype instanceof l?r:l,c=Object.create(s.prototype);return R(c,"_invoke",function(n,r,o){var i,l,s,c=0,u=o||[],d=!1,f={p:0,n:0,v:e,a:p,f:p.bind(e,4),d:function(t,n){return i=t,l=0,s=e,f.n=n,a}};function p(n,r){for(l=n,s=r,t=0;!d&&c&&!o&&t<u.length;t++){var o,i=u[t],p=f.p,h=i[2];n>3?(o=h===r)&&(s=i[(l=i[4])?5:(l=3,3)],i[4]=i[5]=e):i[0]<=p&&((o=n<2&&p<i[1])?(l=0,f.v=r,f.n=i[1]):p<h&&(o=n<3||i[0]>r||r>h)&&(i[4]=n,i[5]=r,f.n=h,l=0))}if(o||n>1)return a;throw d=!0,r}return function(o,u,h){if(c>1)throw TypeError("Generator is already running");for(d&&1===u&&p(u,h),l=u,s=h;(t=l<2?e:s)||!d;){i||(l?l<3?(l>1&&(f.n=-1),p(l,s)):f.n=s:f.v=s);try{if(c=2,i){if(l||(o="next"),t=i[o]){if(!(t=t.call(i,s)))throw TypeError("iterator result is not an object");if(!t.done)return t;s=t.value,l<2&&(l=0)}else 1===l&&(t=i.return)&&t.call(i),l<2&&(s=TypeError("The iterator does not provide a '"+o+"' method"),l=1);i=e}else if((t=(d=f.n<0)?s:n.call(r,f))!==a)break}catch(t){i=e,l=1,s=t}finally{c=1}}return{value:t,done:d}}}(n,o,i),!0),c}var a={};function l(){}function s(){}function c(){}t=Object.getPrototypeOf;var u=[][r]?t(t([][r]())):(R(t={},r,function(){return this}),t),d=c.prototype=l.prototype=Object.create(u);function f(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,c):(e.__proto__=c,R(e,o,"GeneratorFunction")),e.prototype=Object.create(d),e}return s.prototype=c,R(d,"constructor",c),R(c,"constructor",s),s.displayName="GeneratorFunction",R(c,o,"GeneratorFunction"),R(d),R(d,o,"Generator"),R(d,r,function(){return this}),R(d,"toString",function(){return"[object Generator]"}),(k=function(){return{w:i,m:f}})()}function R(e,t,n,r){var o=Object.defineProperty;try{o({},"",{})}catch(e){o=0}R=function(e,t,n,r){function i(t,n){R(e,t,function(e){return this._invoke(t,n,e)})}t?o?o(e,t,{value:n,enumerable:!r,configurable:!r,writable:!r}):e[t]=n:(i("next",0),i("throw",1),i("return",2))},R(e,t,n,r)}function M(e,t,n,r,o,i,a){try{var l=e[i](a),s=l.value}catch(e){return void n(e)}l.done?t(s):Promise.resolve(s).then(r,o)}function P(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function B(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?P(Object(n),!0).forEach(function(t){_(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):P(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function _(e,t,n){return(t=function(e){var t=function(e){if("object"!=I(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=I(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==I(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function T(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,l=[],s=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw o}}return l}}(e,t)||function(e,t){if(e){if("string"==typeof e)return O(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?O(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function O(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var D=(0,u.PA)(function(e){var t=e.handleClose,n=e.model,u=T((0,r.useState)([{name:"NCBIfam",description:"NCBI RefSeq FAMs including TIGRFAMs",category:"Families, domains, sites & repeats",checked:!0},{name:"SFLD",description:"Structure function linkage database",category:"Families, domains, sites & repeats",checked:!0},{name:"Phobius",checked:!0,description:"A combined transmembrane topology and signal peptide predictor",category:"Other sequence features"},{name:"SignalP",checked:!0,category:"Other sequence features"},{name:"SignalP_EUK",category:"Other category",checked:!0},{name:"SignalP_GRAM_POSITIVE",category:"Other category",checked:!0},{name:"SignalP_GRAM_NEGATIVE",checked:!0,category:"Other category"},{name:"SuperFamily",category:"Structural domains",checked:!0},{name:"Panther",category:"Families, domains, sites & repeats",checked:!0},{name:"Gene3d",category:"Structural domains",checked:!0},{name:"HAMAP",category:"Families, domains, sites & repeats",checked:!0},{name:"PrositeProfiles",category:"Families, domains, sites & repeats",checked:!0},{name:"PrositePatterns",category:"Families, domains, sites & repeats",checked:!0},{name:"Coils",category:"Other sequence features",checked:!0},{name:"SMART",category:"Families, domains, sites & repeats",checked:!0},{name:"CDD",description:"Conserved Domains Database",category:"Families, domains, sites & repeats",checked:!0},{name:"PRINTS",category:"Families, domains, sites & repeats",checked:!0},{name:"PfamA",category:"Families, domains, sites & repeats",checked:!0},{name:"MobiDBLite",checked:!0,category:"Other sequence features"},{name:"PIRSF",checked:!0,category:"Other category"},{name:"TMHMM",checked:!0,category:"Other sequence features"},{name:"AntiFam",checked:!0,category:"Other category"},{name:"FunFam",checked:!0,category:"Other category"},{name:"PIRSR",checked:!0,category:"Families, domains, sites & repeats"}]),2),d=u[0],f=u[1],p=d.filter(function(e){return e.checked}).map(function(e){return e.name}),h=T((0,r.useState)(!1),2),g=h[0],m=h[1];return r.createElement(o.A,{maxWidth:"xl",title:"Query InterProScan API for domains",onClose:function(){t()},open:!0},r.createElement(a.A,null,r.createElement(l.A,null,"This will run InterProScan via the InterProScan API on all rows of the current MSA"),r.createElement(s.A,{onClick:function(){m(!g)}},g?"Hide":"Show"," advanced options"),g?r.createElement("div",null,r.createElement(l.A,null,"Select algorithms for InterProScan to run"),r.createElement("div",null,r.createElement(s.A,{variant:"contained",color:"secondary",onClick:function(){f(d.map(function(e){return B(B({},e),{},{checked:!1})}))}},"Select none"),r.createElement(s.A,{variant:"contained",color:"primary",onClick:function(){f(d.map(function(e){return B(B({},e),{},{checked:!0})}))}},"Select all")),r.createElement("table",null,r.createElement("tbody",null,d.toSorted(function(e,t){return e.category.localeCompare(t.category)}).map(function(e){var t=e.name,n=e.checked,o=e.category;return r.createElement("tr",{key:t},r.createElement("td",null,r.createElement("input",{type:"checkbox",key:t,checked:n,onChange:function(){f(d.map(function(e){return e.name===t?B(B({},e),{},{checked:!e.checked}):e}))}})),r.createElement("td",null,t),r.createElement("td",null,o))})))):null),r.createElement(c.A,null,r.createElement(s.A,{variant:"contained",color:"secondary",onClick:function(){t()}},"Cancel"),r.createElement(s.A,{variant:"contained",color:"primary",onClick:function(){var e,r=new AbortController;(e=k().m(function e(){var t,o;return k().w(function(e){for(;;)switch(e.p=e.n){case 0:if(e.p=0,!((t=n.rows).length>140)){e.n=1;break}throw new Error("Too many sequences, please run InterProScan offline");case 1:return e.n=2,C({algorithm:"interproscan",programs:p,seq:t.map(function(e){return[e[0],e[1].replaceAll("-","")]}).filter(function(e){return!!e[1]}).map(function(e){return">".concat(e[0],"\n").concat(e[1])}).join("\n"),onProgress:function(e){n.setStatus(e?B(B({},e),{},{onCancel:function(){r.abort()}}):void 0)},model:n,signal:r.signal});case 2:e.n=4;break;case 3:e.p=3,o=e.v,console.error(o),(0,i.HtM)(n).notifyError("".concat(o),o);case 4:return e.p=4,n.setStatus(),e.f(4);case 5:return e.a(2)}},e,null,[[0,3,4,5]])}),function(){var t=this,n=arguments;return new Promise(function(r,o){var i=e.apply(t,n);function a(e){M(i,r,o,a,l,"next",e)}function l(e){M(i,r,o,a,l,"throw",e)}a(void 0)})})(),t()}},"Send sequences to InterProScan")))});const N=D},390(e,t,n){"use strict";n.r(t),n.d(t,{default:()=>u});var r=n(405),o=n(7434),i=n(6584),a=n(9936),l=n(8647),s=n(2020),c=n(9446);const u=(0,s.PA)(function(e){var t=e.model,n=e.onClose,s=t.header;return r.createElement(a.A,{onClose:function(){n()},open:!0,title:"Metadata",maxWidth:"xl"},r.createElement(l.A,null,r.createElement(o.A,{attributes:s}),r.createElement(i.A,{title:"sequence"},r.createElement(c.A,{str:t.rows}))))})},4262(e,t,n){"use strict";n.r(t),n.d(t,{default:()=>w});var r=n(405),o=n(9936),i=n(4871),a=n(937),l=n(2509),s=n(9406),c=n(8647),u=n(7252),d=n(7346),f=n(2020),p=n(8998),h=n(6439),g=n(4760),m=(0,p.n9)()(function(e){return{field:{margin:e.spacing(4)},flex:{display:"flex"},minw:{width:"80em"}}}),A=function(){return+(arguments.length>0&&void 0!==arguments[0]?arguments[0]:0).toFixed(1)},b=(0,f.PA)(function(e){var t=e.model;return r.createElement(r.Fragment,null,r.createElement(v,{model:t}),r.createElement(y,{model:t}))}),v=(0,f.PA)(function(e){var t=e.model,n=t.drawTree,o=t.drawLabels,i=t.drawNodeBubbles,a=t.labelsAlignRight,l=t.showBranchLen;return r.createElement("div",null,r.createElement("h1",null,"Tree options"),r.createElement(g.A,{checked:l,label:"Show branch length?",onChange:function(){t.setShowBranchLen(!l)}}),r.createElement(g.A,{checked:i,label:"Draw clickable bubbles on tree branches?",onChange:function(){t.setDrawNodeBubbles(!i)}}),r.createElement(g.A,{checked:n,label:"Show tree?",onChange:function(){t.setDrawTree(!n)}}),r.createElement(g.A,{checked:a,label:"Tree labels align right?",onChange:function(){t.setLabelsAlignRight(!a)}}),r.createElement(g.A,{checked:o,label:"Draw labels",onChange:function(){t.setDrawLabels(!o)}}))}),y=(0,f.PA)(function(e){var t=e.model,n=m().classes,o=t.bgColor,c=t.colWidth,u=t.allowedGappyness,d=t.drawMsaLetters,f=t.colorSchemeName,p=t.hideGaps,b=t.rowHeight;return r.createElement("div",null,r.createElement("h1",null,"MSA options"),r.createElement(g.A,{checked:d,label:"Draw letters",onChange:function(){t.setDrawMsaLetters(!d)}}),r.createElement(g.A,{checked:o,label:"Color letters instead of background of tiles",onChange:function(){t.setBgColor(!o)}}),r.createElement(g.A,{checked:p,label:"Enable hiding gappy columns?",onChange:function(){t.setHideGaps(!p)}}),p?r.createElement("div",{className:n.flex},r.createElement(i.A,null,"Hide columns w/ >",u,"% gaps"),r.createElement(a.Ay,{className:n.field,min:1,max:100,value:u,onChange:function(e,n){t.setAllowedGappyness(n)}})):null,r.createElement("div",{className:n.flex},r.createElement(i.A,null,"Column width (",A(c),"px)"),r.createElement(a.Ay,{className:n.field,min:1,max:50,value:c,onChange:function(e,n){t.setColWidth(n)}})),r.createElement("div",{className:n.flex},r.createElement(i.A,null,"Row height (",A(b),"px)"),r.createElement(a.Ay,{className:n.field,min:1,max:50,value:b,onChange:function(e,n){t.setRowHeight(n)}})),r.createElement(l.A,{select:!0,label:"Color scheme",value:f,onChange:function(e){t.setColorSchemeName(e.target.value)}},Object.keys(h.A).map(function(e){return r.createElement(s.A,{key:e,value:e},e)})))});const w=(0,f.PA)(function(e){var t=e.model,n=e.onClose,i=m().classes;return r.createElement(o.A,{open:!0,title:"Settings",maxWidth:"xl",onClose:function(){n()}},r.createElement(c.A,{className:i.minw},r.createElement(b,{model:t}),r.createElement(u.A,null,r.createElement(d.A,{variant:"contained",color:"primary",onClick:function(){n()}},"Submit"))))})},4916(e,t,n){"use strict";n.r(t),n.d(t,{default:()=>p});var r=n(405),o=n(9936),i=n(8647),a=n(7346),l=n(7252),s=n(2020),c=n(8998),u=n(8053);function d(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var f=(0,c.n9)()(function(e){return{textArea:{padding:e.spacing(2),overflow:"auto",background:"#ddd",wordBreak:"break-word"}}});const p=(0,s.PA)(function(e){var t,n,s=e.model,c=e.onClose,p=(t=(0,r.useState)("Copy to clipboard"),n=2,function(e){if(Array.isArray(e))return e}(t)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,l=[],s=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw o}}return l}}(t,n)||function(e,t){if(e){if("string"==typeof e)return d(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?d(e,t):void 0}}(t,n)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),h=p[0],g=p[1],m=f().classes;return r.createElement(o.A,{open:!0,onClose:c,fullWidth:!0,maxWidth:"lg",title:"Track info - ".concat(s.name)},r.createElement(i.A,null,r.createElement(a.A,{variant:"contained",color:"primary",onClick:function(){(0,u.A)(s.data),g("Copied!"),setTimeout(function(){g("Copy to clipboard")},300)}},h),r.createElement("pre",{className:m.textArea},s.data)),r.createElement(l.A,null,r.createElement(a.A,{variant:"contained",onClick:c,color:"secondary"},"Close")))})},2802(e,t,n){"use strict";n.r(t),n.d(t,{default:()=>S});var r=n(405),o=n(9936),i=n(6081),a=n(8647),l=n(4871),s=n(3186),c=n(8450),u=n(6807),d=n(719),f=n(2509),p=n(7346),h=n(7252),g=n(2020),m=n(4567);function A(){var e,t,n="function"==typeof Symbol?Symbol:{},r=n.iterator||"@@iterator",o=n.toStringTag||"@@toStringTag";function i(n,r,o,i){var s=r&&r.prototype instanceof l?r:l,c=Object.create(s.prototype);return b(c,"_invoke",function(n,r,o){var i,l,s,c=0,u=o||[],d=!1,f={p:0,n:0,v:e,a:p,f:p.bind(e,4),d:function(t,n){return i=t,l=0,s=e,f.n=n,a}};function p(n,r){for(l=n,s=r,t=0;!d&&c&&!o&&t<u.length;t++){var o,i=u[t],p=f.p,h=i[2];n>3?(o=h===r)&&(s=i[(l=i[4])?5:(l=3,3)],i[4]=i[5]=e):i[0]<=p&&((o=n<2&&p<i[1])?(l=0,f.v=r,f.n=i[1]):p<h&&(o=n<3||i[0]>r||r>h)&&(i[4]=n,i[5]=r,f.n=h,l=0))}if(o||n>1)return a;throw d=!0,r}return function(o,u,h){if(c>1)throw TypeError("Generator is already running");for(d&&1===u&&p(u,h),l=u,s=h;(t=l<2?e:s)||!d;){i||(l?l<3?(l>1&&(f.n=-1),p(l,s)):f.n=s:f.v=s);try{if(c=2,i){if(l||(o="next"),t=i[o]){if(!(t=t.call(i,s)))throw TypeError("iterator result is not an object");if(!t.done)return t;s=t.value,l<2&&(l=0)}else 1===l&&(t=i.return)&&t.call(i),l<2&&(s=TypeError("The iterator does not provide a '"+o+"' method"),l=1);i=e}else if((t=(d=f.n<0)?s:n.call(r,f))!==a)break}catch(t){i=e,l=1,s=t}finally{c=1}}return{value:t,done:d}}}(n,o,i),!0),c}var a={};function l(){}function s(){}function c(){}t=Object.getPrototypeOf;var u=[][r]?t(t([][r]())):(b(t={},r,function(){return this}),t),d=c.prototype=l.prototype=Object.create(u);function f(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,c):(e.__proto__=c,b(e,o,"GeneratorFunction")),e.prototype=Object.create(d),e}return s.prototype=c,b(d,"constructor",c),b(c,"constructor",s),s.displayName="GeneratorFunction",b(c,o,"GeneratorFunction"),b(d),b(d,o,"Generator"),b(d,r,function(){return this}),b(d,"toString",function(){return"[object Generator]"}),(A=function(){return{w:i,m:f}})()}function b(e,t,n,r){var o=Object.defineProperty;try{o({},"",{})}catch(e){o=0}b=function(e,t,n,r){function i(t,n){b(e,t,function(e){return this._invoke(t,n,e)})}t?o?o(e,t,{value:n,enumerable:!r,configurable:!r,writable:!r}):e[t]=n:(i("next",0),i("throw",1),i("return",2))},b(e,t,n,r)}function v(e,t,n,r,o,i,a){try{var l=e[i](a),s=l.value}catch(e){return void n(e)}l.done?t(s):Promise.resolve(s).then(r,o)}function y(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,l=[],s=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw o}}return l}}(e,t)||function(e,t){if(e){if("string"==typeof e)return w(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?w(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function w(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var C=(0,g.PA)(function(e){var t=e.handleClose,n=e.model,g=y((0,r.useState)(),2),b=g[0],w=g[1],C=y((0,r.useState)("file"),2),S=C[0],x=C[1],E=y((0,r.useState)(""),2),I=E[0],k=E[1];return r.createElement(o.A,{maxWidth:"xl",title:"Open protein domains from file",onClose:function(){t()},open:!0},r.createElement(a.A,null,r.createElement("div",null,r.createElement(l.A,null,"Open a JSON file of InterProScan results that you run remotely on EBI servers or locally"),r.createElement("div",{style:{display:"flex",margin:30}},r.createElement(s.A,{component:"fieldset"},r.createElement(c.A,{value:S,onChange:function(e){x(e.target.value)}},r.createElement(u.A,{value:"url",control:r.createElement(d.A,null),label:"URL"}),r.createElement(u.A,{value:"file",control:r.createElement(d.A,null),label:"File"}))),"url"===S?r.createElement("div",null,r.createElement(l.A,null,"Open a InterProScan JSON file remote URL"),r.createElement(f.A,{label:"URL",value:I,onChange:function(e){k(e.target.value)}})):null,"file"===S?r.createElement("div",{style:{paddingTop:20}},r.createElement(l.A,null,"Open a InterProScan JSON file file from your local drive"),r.createElement(p.A,{variant:"outlined",component:"label"},"Choose File",r.createElement("input",{type:"file",hidden:!0,onChange:function(e){var t,n=null===(t=e.target.files)||void 0===t?void 0:t[0];n&&w(n)}}))):null))),r.createElement(h.A,null,r.createElement(p.A,{variant:"contained",color:"primary",onClick:function(){var e;(e=A().m(function e(){var t,r,o,a;return A().w(function(e){for(;;)switch(e.p=e.n){case 0:if(e.p=0,!b){e.n=2;break}return o=JSON,e.n=1,b.text();case 1:r=o.parse.call(o,e.v),e.n=4;break;case 2:return e.n=3,(0,m.jT)(I);case 3:r=e.v;case 4:t=r,n.setDomains(Object.fromEntries(t.results.map(function(e){return[e.xref[0].id,e]}))),(0,i.HtM)(n).notify("Loaded interproscan results","success"),e.n=6;break;case 5:e.p=5,a=e.v,console.error(a),(0,i.HtM)(n).notifyError("".concat(a),a);case 6:return e.p=6,n.setStatus(),e.f(6);case 7:return e.a(2)}},e,null,[[0,5,6,7]])}),function(){var t=this,n=arguments;return new Promise(function(r,o){var i=e.apply(t,n);function a(e){v(i,r,o,a,l,"next",e)}function l(e){v(i,r,o,a,l,"throw",e)}a(void 0)})})(),t()}},"Open results")))});const S=C},2700(e,t,n){"use strict";n.d(t,{S:()=>r,a:()=>o});var r=12;function o(e){var t=e.scrollX,n=e.msaAreaWidth,o=e.minimapHeight,i=e.colWidth,a=n/e.numColumns/i,l=-t,s=l*a,c=(l+n)*a,u=Math.max(c-s,20),d=o-r;return{unit:a,s,w:u,polygonHeight:d,polygonPoints:"".concat(s+u,",0 ").concat(s,",0 0,").concat(d," ").concat(n,",").concat(d)}}},1755(e,t,n){"use strict";function r(e){var t=e.model,n=e.offsetY,r=e.blockSizeY,o=t.leaves,i=t.rowHeight,a=Math.max(0,Math.floor((n-i)/i)),l=Math.max(0,Math.ceil((n+r+i)/i));return o.slice(a,l)}n.d(t,{t:()=>r})},1739(e,t,n){"use strict";n.d(t,{X:()=>o});var r=n(1755);function o(e){var t=e.model,n=e.offsetX,o=e.offsetY,i=e.ctx,a=e.highResScaleFactorOverride,l=e.blockSizeYOverride,s=t.blockSize,c=t.rowHeight,u=t.highResScaleFactor;if(t.showDomains){var d=null!=a?a:u,f=null!=l?l:s;i.resetTransform(),i.scale(d,d),i.translate(-n,c/2-o),function(e){for(var t=e.model,n=e.ctx,r=e.visibleLeaves,o=t.subFeatureRows,i=t.colWidth,a=t.rowHeight,l=t.fillPalette,s=t.strokePalette,c=t.tidyFilteredGatheredInterProAnnotations,u=0,d=r.length;u<d;u++){var f=r[u],p=f.x,h=f.data.name,g=p,m=c[h];if(m)for(var A=0,b=m.length;A<b;A++){var v=m[A],y=v.start,w=v.end,C=v.accession,S=t.seqPosToVisibleCol(h,y-1),x=t.seqPosToVisibleCol(h,w);if(void 0!==S&&void 0!==x){var E=S*i;n.fillStyle=l[C],n.strokeStyle=s[C];var I=o?4:a,k=g-a+(o?A*I:0),R=i*(x-S);n.fillRect(E,k,R,I),n.strokeRect(E,k,R,I)}}}}({model:t,ctx:i,visibleLeaves:(0,r.t)({model:t,offsetY:o,blockSizeY:f})})}}},5374(e,t,n){"use strict";n.d(t,{H:()=>c});var r=n(1755),o=n(988),i=n(9444),a=n(9168);function l(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return s(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?s(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,l=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){l=!0,i=e},f:function(){try{a||null==n.return||n.return()}finally{if(l)throw i}}}}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function c(e){var t,n=e.model,l=e.offsetX,s=e.offsetY,c=e.contrastScheme,d=e.ctx,f=e.theme,p=e.highResScaleFactorOverride,h=e.blockSizeXOverride,g=e.blockSizeYOverride,m=n.colWidth,A=n.blockSize,b=n.rowHeight,v=n.fontSize,y=n.highResScaleFactor,w=n.actuallyShowDomains,C=n.bgColor,S=null!=p?p:y,x=null!=h?h:A,E=null!=g?g:A;d.resetTransform(),d.scale(S,S),d.translate(-l,b/2-s),d.textAlign="center",(0,i.X)(d,v,!C);var I=(0,o.U)({offsetX:l,blockWidth:x,colWidth:m}),k=I.xStart,R=I.xEnd,M=(0,r.t)({model:n,offsetY:s,blockSizeY:E}),P=n.relativeTo,B=n.columns,_=P?null===(t=B.get(P))||void 0===t?void 0:t.slice(k,R):null;w?function(e){var t=e.model,n=e.offsetX,r=e.ctx,o=e.visibleLeaves,i=e.xStart,a=e.xEnd,l=e.referenceSeq,s=t.showMsaLetters,c=t.columns,u=t.colWidth,d=t.rowHeight,f=t.relativeTo;if(s){var p=n-n%u,h=u/2,g=d/4;r.fillStyle="black";for(var m=0,A=o.length;m<A;m++){var b,v=o[m],y=v.data.name,w=v.x-g,C=null===(b=c.get(y))||void 0===b?void 0:b.slice(i,a);if(C)for(var S=0,x=C.length;S<x;S++){var E=C[S],I=l&&y!==f&&E===l[S];r.fillText(I?".":E,S*u+p+h,w)}}}}({model:n,ctx:d,offsetX:l,xStart:k,xEnd:R,visibleLeaves:M,referenceSeq:_}):function(e){var t=e.model,n=e.offsetX,r=e.ctx,o=e.theme,i=e.contrastScheme,l=e.visibleLeaves,s=e.xStart,c=e.xEnd,u=e.referenceSeq,d=t.bgColor,f=t.colorSchemeName,p=t.colorScheme,h=t.columns,g=t.colWidth,m=t.rowHeight,A=t.relativeTo,b=t.showMsaLetters,v=t.colClustalX,y=t.colConsensus,w="clustalx_protein_dynamic"===f,C="percent_identity_dynamic"===f,S=d||w||C;if(S||b)for(var x=n-n%g,E=g/2,I=m/4,k=0,R=l.length;k<R;k++){var M,P=l[k],B=P.data.name,_=P.x,T=null===(M=h.get(B))||void 0===M?void 0:M.slice(s,c);if(T)for(var O=_-m,D=_-I,N=0,L=T.length;N<L;N++){var F,Q=T[N],j=N*g+x,z=u&&B!==A&&Q===u[N],$=void 0;if(w)$=v[s+N][Q];else if(C){var H=y[s+N];$=Q===H.letter?H.color:void 0}else $=p[Q];S&&(r.fillStyle=z?o.palette.action.hover:$||o.palette.background.default,r.fillRect(j,O,g,m)),b&&(r.fillStyle=d?null!==(F=i[Q])&&void 0!==F?F:"black":$?(0,a.uL)($,o.palette.background.default):o.palette.text.primary,r.fillText(z?".":Q,j+E,D))}}}({model:n,ctx:d,theme:f,contrastScheme:c,offsetX:l,xStart:k,xEnd:R,visibleLeaves:M,referenceSeq:_}),function(e){var t=e.model,n=e.ctx,r=e.visibleLeaves,o=e.xStart,i=e.xEnd,a=t.bgColor;t.hideGapsEffective&&(n.lineWidth=1,n.strokeStyle="#f0f",u({visibleLeaves:r,xStart:o,ctx:n,model:t,xEnd:i,offset:0}),n.strokeStyle=a?"#fff":"#000",u({visibleLeaves:r,xStart:o,ctx:n,model:t,xEnd:i,offset:-1}))}({model:n,ctx:d,xStart:k,xEnd:R,visibleLeaves:M}),d.resetTransform()}function u(e){var t,n=e.model,r=e.ctx,o=e.visibleLeaves,i=e.xStart,a=e.xEnd,s=e.offset,c=n.colWidth,u=n.rowHeight,d=n.insertionPositions,f=l(o);try{for(f.s();!(t=f.n()).done;){var p=t.value,h=p.data.name,g=d.get(h);if(g){var m,A=p.x,b=l(g);try{for(b.s();!(m=b.n()).done;){var v=m.value.pos;if(v>=i&&v<a){var y=v*c,w=A-u,C=A;r.beginPath(),r.moveTo(y+s,w+s);for(var S=w,x=!0;S<C;){var E=Math.min(S+2,C),I=x?y+1:y-1;r.lineTo(I+s,E+s),S=E,x=!x}r.stroke()}}}catch(e){b.e(e)}finally{b.f()}}}}catch(e){f.e(e)}finally{f.f()}}},988(e,t,n){"use strict";function r(e){var t=e.offsetX,n=e.blockWidth,r=e.colWidth;return{xStart:Math.max(0,Math.floor(t/r)),xEnd:Math.max(0,Math.ceil((t+n)/r))}}n.d(t,{U:()=>r})},2012(e,t,n){"use strict";n.d(t,{ay:()=>u,kt:()=>a,qM:()=>l});var r=n(9444),o=n(988);function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function a(e){var t=e.ctx,n=e.conservation,r=e.colWidth,i=e.trackHeight,a=e.offsetX,l=e.blockSize,s=(0,o.U)({offsetX:a,blockWidth:l,colWidth:r}),c=s.xStart,u=s.xEnd;t.fillStyle="gray";for(var d=c;d<u&&d<n.length;d++){var f=n[d]*i,p=d*r;t.fillRect(p,i-f,r,f)}}function l(e){for(var t=e.ctx,n=e.data,r=e.colorScheme,i=e.contrastScheme,a=e.bgColor,l=e.colWidth,s=e.rowHeight,c=e.offsetX,u=e.blockSize,d=(0,o.U)({offsetX:c,blockWidth:u,colWidth:l}),f=d.xStart,p=d.xEnd,h=null==n?void 0:n.slice(f,p),g=0;h&&g<h.length;g++){var m=h[g],A=r[m.toUpperCase()];if(a){var b=g*l+c-c%l;t.fillStyle=A||"white",t.fillRect(b,0,l,s),s>=10&&l>=s/2&&(t.fillStyle=i[m.toUpperCase()]||"black",t.fillText(m,b+l/2,s/2+1))}}}function s(e){var t=e.model,n=e.ctx,r=e.offsetX,o=e.offsetY,i=e.trackHeight,l=e.blockSizeXOverride,s=e.highResScaleFactorOverride,c=t.blockSize,u=t.colWidth,d=t.highResScaleFactor,f=t.conservation,p=null!=l?l:c,h=null!=s?s:d;n.resetTransform(),n.scale(h,h),n.translate(-r,o),a({ctx:n,conservation:f,colWidth:u,trackHeight:i,offsetX:r,blockSize:p}),n.resetTransform()}function c(e){var t=e.model,n=e.ctx,o=e.track,i=e.offsetX,a=e.offsetY,s=e.contrastScheme,c=e.blockSizeXOverride,u=e.highResScaleFactorOverride,d=t.blockSize,f=t.bgColor,p=t.colorScheme,h=t.colWidth,g=t.fontSize,m=t.rowHeight,A=t.highResScaleFactor,b=o.model,v=b.customColorScheme,y=b.data,w=null!=v?v:p,C=null!=c?c:d,S=null!=u?u:A;n.resetTransform(),n.scale(S,S),n.translate(-i,a),n.textAlign="center",(0,r.X)(n,g),l({ctx:n,data:y,colorScheme:w,contrastScheme:s,bgColor:f,colWidth:h,rowHeight:m,offsetX:i,blockSize:C}),n.resetTransform()}function u(e){var t,n=e.model,r=e.ctx,o=e.offsetX,a=e.contrastScheme,l=e.blockSizeXOverride,u=e.highResScaleFactorOverride,d=0,f=function(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return i(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?i(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,l=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return l=e.done,e},e:function(e){s=!0,a=e},f:function(){try{l||null==n.return||n.return()}finally{if(s)throw a}}}}(n.turnedOnTracks);try{for(f.s();!(t=f.n()).done;){var p=t.value,h=p.model.height;"conservation"===p.model.id?s({model:n,ctx:r,offsetX:o,offsetY:d,trackHeight:h,blockSizeXOverride:l,highResScaleFactorOverride:u}):c({model:n,ctx:r,track:p,offsetX:o,offsetY:d,contrastScheme:a,blockSizeXOverride:l,highResScaleFactorOverride:u}),d+=h}}catch(e){f.e(e)}finally{f.f()}}},7058(e,t,n){"use strict";n.r(t),n.d(t,{default:()=>h});var r=n(405),o=n(7434),i=n(6584),a=n(9936),l=n(8647),s=n(2020),c=n(9446);function u(e){return u="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},u(e)}function d(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function f(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?d(Object(n),!0).forEach(function(t){p(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):d(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function p(e,t,n){return(t=function(e){var t=function(e){if("object"!=u(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=u(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==u(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const h=(0,s.PA)(function(e){var t=e.info,n=e.model,s=e.nodeName,u=e.onClose,d=n.treeMetadata,p=n.rows,h=d[s],g=p.find(function(e){return e[0]===s});return r.createElement(a.A,{onClose:function(){u()},open:!0,title:"Tree node info",maxWidth:"xl"},r.createElement(l.A,null,r.createElement(i.A,{title:"Attributes"},r.createElement(o.A,{attributes:f({nodeName:s},t)})),r.createElement(i.A,{title:"Sequence"},g?r.createElement(c.A,{str:[g]}):r.createElement("div",null,"Sequence not found")),h?r.createElement(i.A,{title:"Extra metadata"},r.createElement(o.A,{attributes:h})):null))})},1856(e,t,n){"use strict";n.d(t,{Ms:()=>a,t0:()=>c});var r=n(7335),o=n(9444);function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var a=600,l=2.5;function s(e,t,n,o){return t?e.len:(o-(0,r.wt)(e))/o*n}function c(e){var t=e.model,n=e.clickMap,a=e.ctx,c=e.offsetY,u=e.theme,d=e.highResScaleFactorOverride,f=e.blockSizeYOverride;null==n||n.clear();var p=t.noTree,h=t.drawTree,g=t.drawNodeBubbles,m=t.highResScaleFactor,A=t.fontSize,b=t.showTreeText,v=t.marginLeft;t.rowHeight,a.resetTransform();var y=null!=d?d:m;a.scale(y,y),a.translate(v,-c),(0,o.X)(a,A);var w=t.maxBranchLength,C=t.maxDepthToLeaf;!p&&h&&(function(e){var t=e.offsetY,n=e.ctx,o=e.model,i=e.theme,a=e.maxBranchLen,l=e.maxDepthToLeaf,c=e.blockSizeYOverride,u=o.hierarchy,d=o.showBranchLenEffective,f=o.blockSize,p=null!=c?c:f;n.strokeStyle=i.palette.text.primary,(0,r.rX)(u,function(e,r){var o=e.x,i=r.x,c=s(r,d,a,l),u=s(e,d,a,l);if(void 0!==c&&void 0!==u){var f=Math.min(o,i),h=Math.max(o,i);t+p>=f&&h>=t&&(n.beginPath(),n.moveTo(u,o),n.lineTo(u,i),n.lineTo(c,i),n.stroke())}})}({ctx:a,offsetY:c,model:t,theme:u,maxBranchLen:w,maxDepthToLeaf:C,blockSizeYOverride:f}),g&&function(e){var t=e.ctx,n=e.clickMap,o=e.offsetY,i=e.model,a=e.maxBranchLen,c=e.maxDepthToLeaf,u=e.blockSizeYOverride,d=i.hierarchy,f=i.showBranchLenEffective,p=i.collapsed,h=i.blockSize,g=i.marginLeft,m=null!=u?u:h;(0,r.ul)(d,function(e){var r=s(e,f,a,c);if(void 0!==r){var i=e.data,u=e.x,d=i.id,h=i.name;e.height>=1&&u>o-5&&u<o+m+5&&(t.strokeStyle="black",t.fillStyle=p.includes(d)?"black":"white",t.beginPath(),t.arc(r,u,l,0,2*Math.PI),t.fill(),t.stroke(),null==n||n.insert({minX:r-l+g,maxX:r-l+5+g,minY:u-l,maxY:u-l+5,branch:!0,id:d,name:h}))}})}({ctx:a,offsetY:c,clickMap:n,model:t,maxBranchLen:w,maxDepthToLeaf:C,blockSizeYOverride:f})),b&&function(e){var t=e.theme,n=e.model,r=e.offsetY,o=e.ctx,a=e.clickMap,c=e.maxBranchLen,u=e.maxDepthToLeaf,d=e.blockSizeYOverride,f=n.fontSize,p=n.showBranchLenEffective,h=n.treeMetadata,g=n.blockSize,m=n.labelsAlignRight,A=n.drawTree,b=n.treeAreaWidth,v=n.treeAreaWidthMinusMargin,y=n.marginLeft,w=n.leaves,C=n.noTree,S=n.labelWidthMap,x=null!=d?d:g,E=o.measureText("M").width;m?(o.textAlign="right",o.setLineDash([1,3])):o.textAlign="start";var I,k=function(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return i(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?i(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,l=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return l=e.done,e},e:function(e){s=!0,a=e},f:function(){try{l||null==n.return||n.return()}finally{if(s)throw a}}}}(w);try{for(k.s();!(I=k.n()).done;){var R,M=I.value,P=M.data,B=P.name,_=P.id,T=M.x,O=(null===(R=h[B])||void 0===R?void 0:R.genome)||B;if(T>r-5&&T<r+x+5){var D,N,L=T+f/4,F=0;C||(F=null!==(N=s(M,p,c,u))&&void 0!==N?N:0);var Q=null!==(D=S.get(B))&&void 0!==D?D:o.measureText(O).width;if(o.fillStyle=t.palette.text.primary,m){var j=v-2;A&&!C&&(o.moveTo(F+l+2,T),o.lineTo(j-2-Q,T),o.stroke()),o.fillText(O,j,L),null==a||a.insert({minX:b-Q,maxX:b,minY:L-E,maxY:L,name:B,id:_})}else{var z=C?2:F+5;o.fillText(O,z,L),null==a||a.insert({minX:z+y,maxX:z+Q+y,minY:L-E,maxY:L,name:B,id:_})}}}}catch(e){k.e(e)}finally{k.f()}o.setLineDash([])}({ctx:a,offsetY:c,model:t,clickMap:n,theme:u,maxBranchLen:w,maxDepthToLeaf:C,blockSizeYOverride:f}),null==n||n.finish()}},4567(e,t,n){"use strict";function r(){var e,t,n="function"==typeof Symbol?Symbol:{},i=n.iterator||"@@iterator",a=n.toStringTag||"@@toStringTag";function l(n,r,i,a){var l=r&&r.prototype instanceof c?r:c,u=Object.create(l.prototype);return o(u,"_invoke",function(n,r,o){var i,a,l,c=0,u=o||[],d=!1,f={p:0,n:0,v:e,a:p,f:p.bind(e,4),d:function(t,n){return i=t,a=0,l=e,f.n=n,s}};function p(n,r){for(a=n,l=r,t=0;!d&&c&&!o&&t<u.length;t++){var o,i=u[t],p=f.p,h=i[2];n>3?(o=h===r)&&(l=i[(a=i[4])?5:(a=3,3)],i[4]=i[5]=e):i[0]<=p&&((o=n<2&&p<i[1])?(a=0,f.v=r,f.n=i[1]):p<h&&(o=n<3||i[0]>r||r>h)&&(i[4]=n,i[5]=r,f.n=h,a=0))}if(o||n>1)return s;throw d=!0,r}return function(o,u,h){if(c>1)throw TypeError("Generator is already running");for(d&&1===u&&p(u,h),a=u,l=h;(t=a<2?e:l)||!d;){i||(a?a<3?(a>1&&(f.n=-1),p(a,l)):f.n=l:f.v=l);try{if(c=2,i){if(a||(o="next"),t=i[o]){if(!(t=t.call(i,l)))throw TypeError("iterator result is not an object");if(!t.done)return t;l=t.value,a<2&&(a=0)}else 1===a&&(t=i.return)&&t.call(i),a<2&&(l=TypeError("The iterator does not provide a '"+o+"' method"),a=1);i=e}else if((t=(d=f.n<0)?l:n.call(r,f))!==s)break}catch(t){i=e,a=1,l=t}finally{c=1}}return{value:t,done:d}}}(n,i,a),!0),u}var s={};function c(){}function u(){}function d(){}t=Object.getPrototypeOf;var f=[][i]?t(t([][i]())):(o(t={},i,function(){return this}),t),p=d.prototype=c.prototype=Object.create(f);function h(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,d):(e.__proto__=d,o(e,a,"GeneratorFunction")),e.prototype=Object.create(p),e}return u.prototype=d,o(p,"constructor",d),o(d,"constructor",u),u.displayName="GeneratorFunction",o(d,a,"GeneratorFunction"),o(p),o(p,a,"Generator"),o(p,i,function(){return this}),o(p,"toString",function(){return"[object Generator]"}),(r=function(){return{w:l,m:h}})()}function o(e,t,n,r){var i=Object.defineProperty;try{i({},"",{})}catch(e){i=0}o=function(e,t,n,r){function a(t,n){o(e,t,function(e){return this._invoke(t,n,e)})}t?i?i(e,t,{value:n,enumerable:!r,configurable:!r,writable:!r}):e[t]=n:(a("next",0),a("throw",1),a("return",2))},o(e,t,n,r)}function i(e,t,n,r,o,i,a){try{var l=e[i](a),s=l.value}catch(e){return void n(e)}l.done?t(s):Promise.resolve(s).then(r,o)}function a(e){return function(){var t=this,n=arguments;return new Promise(function(r,o){var a=e.apply(t,n);function l(e){i(a,r,o,l,s,"next",e)}function s(e){i(a,r,o,l,s,"throw",e)}l(void 0)})}}function l(e,t){return s.apply(this,arguments)}function s(){return(s=a(r().m(function e(t,n){var o,i,a,l;return r().w(function(e){for(;;)switch(e.n){case 0:return e.n=1,fetch(t,n);case 1:if((o=e.v).ok){e.n=3;break}return i=Error,a="HTTP ".concat(o.status," fetching ").concat(t," "),e.n=2,o.text();case 2:throw l=a.concat.call(a,e.v),new i(l);case 3:return e.a(2,o)}},e)}))).apply(this,arguments)}function c(e,t){return u.apply(this,arguments)}function u(){return(u=a(r().m(function e(t,n){var o;return r().w(function(e){for(;;)switch(e.n){case 0:return e.n=1,l(t,n);case 1:return o=e.v,e.a(2,o.text())}},e)}))).apply(this,arguments)}function d(e,t){return f.apply(this,arguments)}function f(){return(f=a(r().m(function e(t,n){var o;return r().w(function(e){for(;;)switch(e.n){case 0:return e.n=1,l(t,n);case 1:return o=e.v,e.a(2,o.json())}},e)}))).apply(this,arguments)}function p(e,t){return new Promise(function(n,r){if(null!=t&&t.aborted)r(new DOMException("Aborted","AbortError"));else{var o=setTimeout(n,e);null==t||t.addEventListener("abort",function(){clearTimeout(o),r(new DOMException("Aborted","AbortError"))})}})}function h(e){return e instanceof DOMException&&"AbortError"===e.name}n.d(t,{jT:()=>d,wR:()=>p,y1:()=>c,zf:()=>h})},3431(e,t,n){"use strict";n.d(t,{A:()=>i,S:()=>o});var r=[["#F8766D"],["#F8766D","#00BFC4"],["#F8766D","#00BA38","#619CFF"],["#F8766D","#7CAE00","#00BFC4","#C77CFF"],["#F8766D","#A3A500","#00BF7D","#00B0F6","#E76BF3"],["#F8766D","#B79F00","#00BA38","#00BFC4","#619CFF","#F564E3"],["#F8766D","#C49A00","#53B400","#00C094","#00B6EB","#A58AFF","#FB61D7"],["#F8766D","#CD9600","#7CAE00","#00BE67","#00BFC4","#00A9FF","#C77CFF","#FF61CC"]];function o(e){return r[Math.min(e,r.length-1)]}const i=r},7335(e,t,n){"use strict";function r(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return o(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?o(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,l=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return l=e.done,e},e:function(e){s=!0,a=e},f:function(){try{l||null==n.return||n.return()}finally{if(s)throw a}}}}function o(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function i(e){for(var t=[],n=[e];n.length>0;){var r=n.pop();if(t.push(r),r.children)for(var o=r.children.length-1;o>=0;o--)n.push(r.children[o])}return t}function a(e,t){for(var n={data:e,children:null,parent:null,depth:0,height:0},o=[n],a=function(){var e=o.pop(),n=t(e.data);if(null!=n&&n.length){e.children=n.map(function(t){return{data:t,children:null,parent:e,depth:e.depth+1,height:0}});var i,a=r(e.children);try{for(a.s();!(i=a.n()).done;){var l=i.value;o.push(l)}}catch(e){a.e(e)}finally{a.f()}}};o.length>0;)a();return function(e){for(var t=i(e),n=t.length-1;n>=0;n--){var o=t[n],a=0;if(o.children){var l,s=r(o.children);try{for(s.s();!(l=s.n()).done;){var c=l.value;c.height+1>a&&(a=c.height+1)}}catch(e){s.e(e)}finally{s.f()}}o.height=a}}(n),n}function l(e,t){for(var n=i(e),o=n.length-1;o>=0;o--){var a=n[o],l=t(a.data);if(a.children){var s,c=r(a.children);try{for(c.s();!(s=c.n()).done;)l+=s.value.value}catch(e){c.e(e)}finally{c.f()}}a.value=l}return e}function s(e,t){for(var n=[e];n.length>0;){var o=n.pop();if(o.children){o.children.sort(t);var i,a=r(o.children);try{for(a.s();!(i=a.n()).done;){var l=i.value;n.push(l)}}catch(e){a.e(e)}finally{a.f()}}}return e}function c(e,t){for(var n,r=[e];r.length>0&&void 0===n;){var o=r.pop();if(t(o))n=o;else if(o.children)for(var i=o.children.length-1;i>=0;i--)r.push(o.children[i])}return n}function u(e){for(var t=[],n=[e];n.length>0;){var r=n.pop();if(r.children)for(var o=r.children.length-1;o>=0;o--)n.push(r.children[o]);else t.push(r)}return t}function d(e){var t=[];return f(e,function(e,n){t.push({source:e,target:n})}),t}function f(e,t){for(var n=[e];n.length>0;){var r=n.pop();if(r.children)for(var o=r.children.length-1;o>=0;o--){var i=r.children[o];t(r,i),n.push(i)}}}function p(e,t){var n,o=r(i(e));try{for(o.s();!(n=o.n()).done;)t(n.value)}catch(e){o.e(e)}finally{o.f()}}function h(e,t,n){for(var o=u(e),a=o.length,l=t/a,s=0;s<a;s++)o[s].x=(s+.5)*l;for(var c=i(e),d=c.length-1;d>=0;d--){var f=c[d];if(f.children){var p,h=0,g=r(f.children);try{for(g.s();!(p=g.n()).done;)h+=p.value.x}catch(e){g.e(e)}finally{g.f()}f.x=h/f.children.length}}for(var m=e.height,A=[{node:e,depth:0}];A.length>0;){var b=A.pop(),v=b.node,y=b.depth;if(v.y=0===m?n:y/m*n,v.children){var w,C=r(v.children);try{for(C.s();!(w=C.n()).done;){var S=w.value;A.push({node:S,depth:y+1})}}catch(e){C.e(e)}finally{C.f()}}}}function g(e){e.children&&(e._children=e.children,e.children=null)}function m(e){for(var t=i(e),n=t.length-1;n>=0;n--){var o=t[n];if(void 0===o.depthToLeaf){var a=0;if(o.children){var l,s=r(o.children);try{for(s.s();!(l=s.n()).done;){var c=l.value;a=Math.max(a,1+c.depthToLeaf)}}catch(e){s.e(e)}finally{s.f()}}o.depthToLeaf=a}}return e.depthToLeaf}function A(e){var t,n=0,o=r(i(e));try{for(o.s();!(t=o.n()).done;){var a=t.value;n=Math.max(n,a.len||0)}}catch(e){o.e(e)}finally{o.f()}return n}function b(e){for(var t=i(e),n=new Map,o=t.length-1;o>=0;o--){var a=t[o],l=0;if(a.children){var s,c=r(a.children);try{for(c.s();!(s=c.n()).done;){var u=s.value;l=Math.max(l,n.get(u))}}catch(e){c.e(e)}finally{c.f()}}n.set(a,(a.data.length||0)+l)}return n.get(e)}function v(e,t,n){for(var o=[{node:e,y0:t}];o.length>0;){var i=o.pop(),a=i.node,l=i.y0+Math.max(a.data.length||0,0);if(a.len=l*n,a.children){var s,c=r(a.children);try{for(c.s();!(s=c.n()).done;){var u=s.value;o.push({node:u,y0:l})}}catch(e){c.e(e)}finally{c.f()}}}}n.d(t,{FQ:()=>u,Fj:()=>h,I6:()=>c,Ru:()=>b,Sk:()=>a,ap:()=>g,cz:()=>l,di:()=>s,jm:()=>A,rX:()=>f,ul:()=>p,wt:()=>m,yJ:()=>d,zu:()=>v})},3714(e,t,n){"use strict";n.r(t),n.d(t,{renderToSvg:()=>b});var r=n(405),o=n(6081),i=n(5597),a=n(2020),l=n(2700);const s=(0,a.PA)(function(e){var t=e.model,n=t.msaAreaWidth,o=(0,l.a)(t),i=o.s,a=o.w,s=o.polygonPoints,c="rgb(66, 119, 127)";return r.createElement(r.Fragment,null,r.createElement("rect",{x:0,y:0,width:n,height:l.S,stroke:"#555",fill:"none"}),r.createElement("rect",{x:Math.max(0,i),y:0,width:a,height:l.S,fill:c,fillOpacity:.3,stroke:"#555"}),r.createElement("g",{transform:"translate(0 ".concat(l.S,")")},r.createElement("polygon",{fill:c,fillOpacity:.3,points:s})))});var c=n(1739),u=n(5374),d=n(2012),f=n(1856),p=n(9168);function h(){var e,t,n="function"==typeof Symbol?Symbol:{},r=n.iterator||"@@iterator",o=n.toStringTag||"@@toStringTag";function i(n,r,o,i){var s=r&&r.prototype instanceof l?r:l,c=Object.create(s.prototype);return g(c,"_invoke",function(n,r,o){var i,l,s,c=0,u=o||[],d=!1,f={p:0,n:0,v:e,a:p,f:p.bind(e,4),d:function(t,n){return i=t,l=0,s=e,f.n=n,a}};function p(n,r){for(l=n,s=r,t=0;!d&&c&&!o&&t<u.length;t++){var o,i=u[t],p=f.p,h=i[2];n>3?(o=h===r)&&(s=i[(l=i[4])?5:(l=3,3)],i[4]=i[5]=e):i[0]<=p&&((o=n<2&&p<i[1])?(l=0,f.v=r,f.n=i[1]):p<h&&(o=n<3||i[0]>r||r>h)&&(i[4]=n,i[5]=r,f.n=h,l=0))}if(o||n>1)return a;throw d=!0,r}return function(o,u,h){if(c>1)throw TypeError("Generator is already running");for(d&&1===u&&p(u,h),l=u,s=h;(t=l<2?e:s)||!d;){i||(l?l<3?(l>1&&(f.n=-1),p(l,s)):f.n=s:f.v=s);try{if(c=2,i){if(l||(o="next"),t=i[o]){if(!(t=t.call(i,s)))throw TypeError("iterator result is not an object");if(!t.done)return t;s=t.value,l<2&&(l=0)}else 1===l&&(t=i.return)&&t.call(i),l<2&&(s=TypeError("The iterator does not provide a '"+o+"' method"),l=1);i=e}else if((t=(d=f.n<0)?s:n.call(r,f))!==a)break}catch(t){i=e,l=1,s=t}finally{c=1}}return{value:t,done:d}}}(n,o,i),!0),c}var a={};function l(){}function s(){}function c(){}t=Object.getPrototypeOf;var u=[][r]?t(t([][r]())):(g(t={},r,function(){return this}),t),d=c.prototype=l.prototype=Object.create(u);function f(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,c):(e.__proto__=c,g(e,o,"GeneratorFunction")),e.prototype=Object.create(d),e}return s.prototype=c,g(d,"constructor",c),g(c,"constructor",s),s.displayName="GeneratorFunction",g(c,o,"GeneratorFunction"),g(d),g(d,o,"Generator"),g(d,r,function(){return this}),g(d,"toString",function(){return"[object Generator]"}),(h=function(){return{w:i,m:f}})()}function g(e,t,n,r){var o=Object.defineProperty;try{o({},"",{})}catch(e){o=0}g=function(e,t,n,r){function i(t,n){g(e,t,function(e){return this._invoke(t,n,e)})}t?o?o(e,t,{value:n,enumerable:!r,configurable:!r,writable:!r}):e[t]=n:(i("next",0),i("throw",1),i("return",2))},g(e,t,n,r)}function m(e,t,n,r,o,i,a){try{var l=e[i](a),s=l.value}catch(e){return void n(e)}l.done?t(s):Promise.resolve(s).then(r,o)}function A(e){return function(){var t=this,n=arguments;return new Promise(function(r,o){var i=e.apply(t,n);function a(e){m(i,r,o,a,l,"next",e)}function l(e){m(i,r,o,a,l,"throw",e)}a(void 0)})}}function b(e,t){return v.apply(this,arguments)}function v(){return(v=A(h().m(function e(t,n){var r,o,a,l,s,c,u,d,f,p,g;return h().w(function(e){for(;;)switch(e.n){case 0:return e.n=1,(0,i.z7)(function(){return t.dataInitialized});case 1:if(r=t.width,o=t.height,a=t.scrollX,l=t.scrollY,s=t.totalTrackAreaHeight,c=t.minimapHeight,u=n.exportType,d=n.theme,f=n.includeTracks,p=f?s:0,g="viewport"===u&&!!n.includeMinimap,"entire"!==u){e.n=2;break}return e.a(2,y({width:t.totalWidth+t.treeAreaWidth,height:t.totalHeight+p,contentHeight:t.totalHeight,trackHeight:p,theme:d,model:t,offsetY:0,offsetX:0,includeMinimap:g,includeTracks:f}));case 2:return e.a(2,y({width:r,height:o+(g?c:0)+p,contentHeight:o,trackHeight:p,theme:d,model:t,offsetY:-l,offsetX:-a,includeMinimap:g,includeTracks:f}))}},e)}))).apply(this,arguments)}function y(e){return w.apply(this,arguments)}function w(){return(w=A(h().m(function e(t){var i,a,l,c,u,d,f,p,g,m,A,b,v,y,w;return h().w(function(e){for(;;)switch(e.n){case 0:return i=t.width,a=t.height,l=t.contentHeight,c=t.trackHeight,u=t.offsetX,d=t.offsetY,f=t.theme,p=t.model,g=t.includeMinimap,m=t.includeTracks,e.n=1,Promise.resolve().then(n.bind(n,7085));case 1:return A=e.v,b=A.Context,v=p.treeAreaWidth,y=p.minimapHeight,w=r.createElement(r.Fragment,null,m&&c>0?r.createElement(x,{Context:b,model:p,theme:f,offsetX:u,msaAreaWidth:i-v,trackHeight:c}):null,r.createElement("g",{transform:c>0?"translate(0 ".concat(c,")"):void 0},r.createElement(C,{Context:b,model:p,theme:f,offsetX:u,offsetY:d,msaAreaWidth:i-v,contentHeight:l}))),e.a(2,(0,o.qVg)(r.createElement(E,{width:i,height:a},g?r.createElement(r.Fragment,null,r.createElement("g",{transform:"translate(".concat(v," 0)")},r.createElement(s,{model:p})),r.createElement("g",{transform:"translate(0 ".concat(y,")")},w)):w)))}},e)}))).apply(this,arguments)}function C(e){var t=e.model,n=e.theme,o=e.msaAreaWidth,i=e.contentHeight,a=e.offsetX,l=e.offsetY,s=e.Context,d=t.treeAreaWidth,h=t.colorScheme,g=t.id,m="tree-".concat(g),A="msa-".concat(g),b=(0,p.Sl)(h,n),v=new s(d,i),y=new s(o,i);return(0,c.X)({ctx:y,offsetX:a,offsetY:l,model:t,blockSizeYOverride:i,highResScaleFactorOverride:1}),(0,f.t0)({model:t,offsetY:l,ctx:v,theme:n,blockSizeYOverride:i,highResScaleFactorOverride:1}),(0,u.H)({model:t,theme:n,offsetY:l,offsetX:a,contrastScheme:b,ctx:y,blockSizeXOverride:o,blockSizeYOverride:i,highResScaleFactorOverride:1}),r.createElement(r.Fragment,null,r.createElement("defs",null,r.createElement("clipPath",{id:m},r.createElement("rect",{x:0,y:0,width:d,height:i})),r.createElement("clipPath",{id:A},r.createElement("rect",{x:0,y:0,width:o,height:i}))),r.createElement(S,{clipId:m,html:v.getSvg().innerHTML}),r.createElement(S,{clipId:A,transform:"translate(".concat(d," 0)"),html:y.getSvg().innerHTML}))}function S(e){var t=e.clipId,n=e.html,o=e.transform;return r.createElement("g",{clipPath:"url(#".concat(t,")"),transform:o,dangerouslySetInnerHTML:{__html:n}})}function x(e){var t=e.model,n=e.theme,o=e.msaAreaWidth,i=e.trackHeight,a=e.offsetX,l=e.Context,s=t.treeAreaWidth,c=t.colorScheme,u=t.id,f="tracks-".concat(u),h=(0,p.Sl)(c,n),g=new l(o,i);return(0,d.ay)({model:t,ctx:g,offsetX:a,contrastScheme:h,blockSizeXOverride:o,highResScaleFactorOverride:1}),r.createElement("g",{transform:"translate(".concat(s," 0)")},r.createElement("defs",null,r.createElement("clipPath",{id:f},r.createElement("rect",{x:0,y:0,width:o,height:i}))),r.createElement(S,{clipId:f,html:g.getSvg().innerHTML}))}function E(e){var t=e.width,n=e.height,o=e.children;return r.createElement("svg",{width:t,height:n,xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",viewBox:"0 0 ".concat(t," ").concat(n)},r.createElement("rect",{width:"100%",height:"100%",fill:"white"}),o)}},9444(e,t,n){"use strict";function r(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];e.font=e.font.replace(/(?:bold )?[\d.]+px/,"".concat(n?"bold ":"").concat(t,"px"))}n.d(t,{X:()=>r})},9168(e,t,n){"use strict";n.d(t,{uL:()=>u,Sl:()=>f,i8:()=>h,z3:()=>m,Il:()=>g,pw:()=>p,pd:()=>d});var r=n(5070),o=function(e){var t=e/255;return t<.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)},i=function(e){return.2126*o(e.r)+.7152*o(e.g)+.0722*o(e.b)},a=n(711);function l(e,t){if(e){if("string"==typeof e)return s(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?s(e,t):void 0}}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}(0,r.X$)([a.A,function(e){e.prototype.luminance=function(){return e=i(this.rgba),void 0===(t=2)&&(t=0),void 0===n&&(n=Math.pow(10,t)),Math.round(n*e)/n+0;var e,t,n},e.prototype.contrast=function(t){void 0===t&&(t="#FFF");var n,r,o,a,l,s,c,u=t instanceof e?t:new e(t);return a=this.rgba,l=u.toRgb(),n=(s=i(a))>(c=i(l))?(s+.05)/(c+.05):(c+.05)/(s+.05),void 0===(r=2)&&(r=0),void 0===o&&(o=Math.pow(10,r)),Math.floor(o*n)/o+0},e.prototype.isReadable=function(e,t){return void 0===e&&(e="#FFF"),void 0===t&&(t={}),this.contrast(e)>=(a=void 0===(i=(n=t).size)?"normal":i,"AAA"===(o=void 0===(r=n.level)?"AA":r)&&"normal"===a?7:"AA"===o&&"large"===a?3:4.5);var n,r,o,i,a}}]);var c=new Map;function u(e,t){var n="".concat(e,"|").concat(t),o=c.get(n);if(void 0!==o)return o;var i=(0,r.Mj)(e);if(!i.isReadable(t))for(var a=(0,r.Mj)(t).luminance()<.5,l=0;l<40&&!i.isReadable(t);l++)i=a?i.lighten(.05):i.darken(.05);var s=i.toHex();return c.set(n,s),s}function d(e,t){return Object.fromEntries(Object.entries(e).map(t))}function f(e,t){return d(e,function(e){var n,o,i=(o=2,function(e){if(Array.isArray(e))return e}(n=e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,l=[],s=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw o}}return l}}(n,o)||l(n,o)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),a=i[0],s=i[1];return[a,t.palette.getContrastText((0,r.Mj)(s).toHex())]})}function p(e,t){if(0===e.length)return t;var n,r=[],o=0,i=function(e){var t="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!t){if(Array.isArray(e)||(t=l(e))){t&&(e=t);var n=0,r=function(){};return{s:r,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:r}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,i=!0,a=!1;return{s:function(){t=t.call(e)},n:function(){var e=t.next();return i=e.done,e},e:function(e){a=!0,o=e},f:function(){try{i||null==t.return||t.return()}finally{if(a)throw o}}}}(e);try{for(i.s();!(n=i.n()).done;){var a=n.value;a>o&&r.push(t.slice(o,a)),o=a+1}}catch(e){i.e(e)}finally{i.f()}return o<t.length&&r.push(t.slice(o)),r.join("")}function h(e,t){for(var n=[],r=e.length,o=0,i=0,a=-1,l=[],s=0;s<t.length;s++)i<r&&e[i]===s?(t.charCodeAt(s)-45>>>0<=1||(a===o?l.push(t[s]):(l.length>0&&n.push({pos:a,letters:l.join("")}),a=o,l=[t[s]])),i++):o++;return l.length>0&&n.push({pos:a,letters:l.join("")}),n}function g(e){return e.end-e.start}function m(e){return"-"===e||"."===e}},8053(e,t,n){"use strict";function r(e){var t=navigator.clipboard;if(null!=t&&t.writeText)t.writeText(e).catch(function(e){console.error("Failed to copy to clipboard:",e)});else{var n=document.createElement("textarea");n.value=e,n.style.position="fixed",n.style.opacity="0",document.body.append(n),n.select(),document.execCommand("copy"),n.remove()}}n.d(t,{A:()=>r})},9585(e,t,n){"use strict";var r=n(9687),o={"text/plain":"Text","text/html":"Url",default:"Text"};e.exports=function(e,t){var n,i,a,l,s,c,u=!1;t||(t={}),n=t.debug||!1;try{if(a=r(),l=document.createRange(),s=document.getSelection(),(c=document.createElement("span")).textContent=e,c.ariaHidden="true",c.style.all="unset",c.style.position="fixed",c.style.top=0,c.style.clip="rect(0, 0, 0, 0)",c.style.whiteSpace="pre",c.style.webkitUserSelect="text",c.style.MozUserSelect="text",c.style.msUserSelect="text",c.style.userSelect="text",c.addEventListener("copy",function(r){if(r.stopPropagation(),t.format)if(r.preventDefault(),void 0===r.clipboardData){n&&console.warn("unable to use e.clipboardData"),n&&console.warn("trying IE specific stuff"),window.clipboardData.clearData();var i=o[t.format]||o.default;window.clipboardData.setData(i,e)}else r.clipboardData.clearData(),r.clipboardData.setData(t.format,e);t.onCopy&&(r.preventDefault(),t.onCopy(r.clipboardData))}),document.body.appendChild(c),l.selectNodeContents(c),s.addRange(l),!document.execCommand("copy"))throw new Error("copy command was unsuccessful");u=!0}catch(r){n&&console.error("unable to copy using execCommand: ",r),n&&console.warn("trying IE specific stuff");try{window.clipboardData.setData(t.format||"text",e),t.onCopy&&t.onCopy(window.clipboardData),u=!0}catch(r){n&&console.error("unable to copy using clipboardData: ",r),n&&console.error("falling back to prompt"),i=function(e){var t=(/mac os x/i.test(navigator.userAgent)?"⌘":"Ctrl")+"+C";return e.replace(/#{\s*key\s*}/g,t)}("message"in t?t.message:"Copy to clipboard: #{key}, Enter"),window.prompt(i,e)}}finally{s&&("function"==typeof s.removeRange?s.removeRange(l):s.removeAllRanges()),c&&document.body.removeChild(c),a()}return u}},8361(e){e.exports=!1},8018(e){"use strict";var t=/["'&<>]/;e.exports=function(e){var n,r=""+e,o=t.exec(r);if(!o)return r;var i="",a=0,l=0;for(a=o.index;a<r.length;a++){switch(r.charCodeAt(a)){case 34:n=""";break;case 38:n="&";break;case 39:n="'";break;case 60:n="<";break;case 62:n=">";break;default:continue}l!==a&&(i+=r.substring(l,a)),l=a+1,i+=n}return l!==a?i+r.substring(l,a):i}},4674(e,t,n){"use strict";var r=n(7020),o={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},i={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},a={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},l={};function s(e){return r.isMemo(e)?a:l[e.$$typeof]||o}l[r.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},l[r.Memo]=a;var c=Object.defineProperty,u=Object.getOwnPropertyNames,d=Object.getOwnPropertySymbols,f=Object.getOwnPropertyDescriptor,p=Object.getPrototypeOf,h=Object.prototype;e.exports=function e(t,n,r){if("string"!=typeof n){if(h){var o=p(n);o&&o!==h&&e(t,o,r)}var a=u(n);d&&(a=a.concat(d(n)));for(var l=s(t),g=s(n),m=0;m<a.length;++m){var A=a[m];if(!(i[A]||r&&r[A]||g&&g[A]||l&&l[A])){var b=f(n,A);try{c(t,A,b)}catch(e){}}}}return t}},2020(e,t,n){"use strict";n.d(t,{PA:()=>T});var r=n(5597),o=n(405);if(!o.useState)throw new Error("mobx-react-lite requires React with Hooks support");if(!r.Gn)throw new Error("mobx-react-lite@3 requires mobx at least version 6 to be available");var i=n(7868);function a(e){return(0,r.yl)(e)}var l,s,c=function(){function e(e){var t=this;Object.defineProperty(this,"finalize",{enumerable:!0,configurable:!0,writable:!0,value:e}),Object.defineProperty(this,"registrations",{enumerable:!0,configurable:!0,writable:!0,value:new Map}),Object.defineProperty(this,"sweepTimeout",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"sweep",{enumerable:!0,configurable:!0,writable:!0,value:function(e){void 0===e&&(e=1e4),clearTimeout(t.sweepTimeout),t.sweepTimeout=void 0;var n=Date.now();t.registrations.forEach(function(r,o){n-r.registeredAt>=e&&(t.finalize(r.value),t.registrations.delete(o))}),t.registrations.size>0&&t.scheduleSweep()}}),Object.defineProperty(this,"finalizeAllImmediately",{enumerable:!0,configurable:!0,writable:!0,value:function(){t.sweep(0)}})}return Object.defineProperty(e.prototype,"register",{enumerable:!1,configurable:!0,writable:!0,value:function(e,t,n){this.registrations.set(n,{value:t,registeredAt:Date.now()}),this.scheduleSweep()}}),Object.defineProperty(e.prototype,"unregister",{enumerable:!1,configurable:!0,writable:!0,value:function(e){this.registrations.delete(e)}}),Object.defineProperty(e.prototype,"scheduleSweep",{enumerable:!1,configurable:!0,writable:!0,value:function(){void 0===this.sweepTimeout&&(this.sweepTimeout=setTimeout(this.sweep,1e4))}}),e}(),u=new("undefined"!=typeof FinalizationRegistry?FinalizationRegistry:c)(function(e){var t;null===(t=e.reaction)||void 0===t||t.dispose(),e.reaction=null}),d=n(524);function f(e){e.reaction=new r.qT("observer".concat(e.name),function(){var t;e.stateVersion=Symbol(),null===(t=e.onStoreChange)||void 0===t||t.call(e)})}var p="function"==typeof Symbol&&Symbol.for,h=null!==(s=null===(l=Object.getOwnPropertyDescriptor(function(){},"name"))||void 0===l?void 0:l.configurable)&&void 0!==s&&s,g=p?Symbol.for("react.forward_ref"):"function"==typeof o.forwardRef&&(0,o.forwardRef)(function(e){return null}).$$typeof,m=p?Symbol.for("react.memo"):"function"==typeof o.memo&&(0,o.memo)(function(e){return null}).$$typeof;function A(e,t){var n;if(m&&e.$$typeof===m)throw new Error("[mobx-react-lite] You are trying to use `observer` on a function component wrapped in either another `observer` or `React.memo`. The observer already applies 'React.memo' for you.");var r=null!==(n=null==t?void 0:t.forwardRef)&&void 0!==n&&n,i=e,l=e.displayName||e.name;if(g&&e.$$typeof===g&&(r=!0,"function"!=typeof(i=e.render)))throw new Error("[mobx-react-lite] `render` property of ForwardRef was not a function");var s,c,p=function(e,t){return function(e,t){void 0===t&&(t="observed");var n=o.useRef(null);if(!n.current){var r={reaction:null,onStoreChange:null,stateVersion:Symbol(),name:t,subscribe:function(e){return u.unregister(r),r.onStoreChange=e,r.reaction||(f(r),r.stateVersion=Symbol()),function(){var e;r.onStoreChange=null,null===(e=r.reaction)||void 0===e||e.dispose(),r.reaction=null}},getSnapshot:function(){return r.stateVersion}};n.current=r}var i,l,s=n.current;if(s.reaction||(f(s),u.register(n,s,s)),o.useDebugValue(s.reaction,a),(0,d.useSyncExternalStore)(s.subscribe,s.getSnapshot,s.getSnapshot),s.reaction.track(function(){try{i=e()}catch(e){l=e}}),l)throw l;return i}(function(){return i(e,t)},l)};return p.displayName=e.displayName,h&&Object.defineProperty(p,"name",{value:e.name,writable:!0,configurable:!0}),e.contextTypes&&(p.contextTypes=e.contextTypes),r&&(p=(0,o.forwardRef)(p)),p=(0,o.memo)(p),s=e,c=p,Object.keys(s).forEach(function(e){v[e]||Object.defineProperty(c,e,Object.getOwnPropertyDescriptor(s,e))}),p}var b,v={$$typeof:!0,render:!0,compare:!0,type:!0,displayName:!0};function y(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}(b=i.unstable_batchedUpdates)||(b=function(e){e()}),(0,r.jK)({reactionScheduler:b}),u.finalizeAllImmediately;var w=Symbol("patchMixins"),C=Symbol("patchedDefinition");function S(e,t){for(var n=this,r=arguments.length,o=new Array(r>2?r-2:0),i=2;i<r;i++)o[i-2]=arguments[i];t.locks++;try{var a;return null!=e&&(a=e.apply(this,o)),a}finally{t.locks--,0===t.locks&&t.methods.forEach(function(e){e.apply(n,o)})}}function x(e,t){return function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];S.call.apply(S,[this,e,t].concat(r))}}function E(e,t,n){var r=function(e,t){var n=e[w]=e[w]||{},r=n[t]=n[t]||{};return r.locks=r.locks||0,r.methods=r.methods||[],r}(e,t);r.methods.indexOf(n)<0&&r.methods.push(n);var o=Object.getOwnPropertyDescriptor(e,t);if(!o||!o[C]){var i=e[t],a=I(e,t,o?o.enumerable:void 0,r,i);Object.defineProperty(e,t,a)}}function I(e,t,n,r,o){var i,a=x(o,r);return(i={})[C]=!0,i.get=function(){return a},i.set=function(o){if(this===e)a=x(o,r);else{var i=I(this,t,n,r,o);Object.defineProperty(this,t,i)}},i.configurable=!0,i.enumerable=n,i}var k=Symbol("ObserverAdministration"),R=Symbol("isMobXReactObserver");function M(e){var t;return null!=(t=e[k])?t:e[k]={reaction:null,mounted:!1,reactionInvalidatedBeforeMount:!1,forceUpdate:null,name:P(e.constructor),state:void 0,props:void 0,context:void 0}}function P(e){return e.displayName||e.name||"<component>"}function B(e){var t=e.bind(this),n=M(this);return function(){n.reaction||(n.reaction=function(e){return new r.qT(e.name+".render()",function(){if(e.mounted)try{null==e.forceUpdate||e.forceUpdate()}catch(n){var t;null==(t=e.reaction)||t.dispose(),e.reaction=null}else e.reactionInvalidatedBeforeMount=!0})}(n),n.mounted||u.register(this,n,this));var e=void 0,o=void 0;if(n.reaction.track(function(){try{o=(0,r.vx)(!1,t)}catch(t){e=t}}),e)throw e;return o}}function _(e,t){return this.state!==t||!function(e,t){if(y(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(var o=0;o<n.length;o++)if(!Object.hasOwnProperty.call(t,n[o])||!y(e[n[o]],t[n[o]]))return!1;return!0}(this.props,e)}function T(e,t){if(t&&"class"!==t.kind)throw new Error("The @observer decorator can be used on classes only");return!0===e.isMobxInjector&&console.warn("Mobx observer: You are trying to use `observer` on a component that already has `inject`. Please apply `observer` before applying `inject`"),Object.prototype.isPrototypeOf.call(o.Component,e)||Object.prototype.isPrototypeOf.call(o.PureComponent,e)?function(e){var t=e.prototype;if(e[R]){var n=P(e);throw new Error("The provided component class ("+n+") has already been declared as an observer component.")}if(e[R]=!0,t.componentWillReact)throw new Error("The componentWillReact life-cycle event is no longer supported");if(e.__proto__!==o.PureComponent)if(t.shouldComponentUpdate){if(t.shouldComponentUpdate!==_)throw new Error("It is not allowed to use shouldComponentUpdate in observer based components.")}else t.shouldComponentUpdate=_;var r=t.render;if("function"!=typeof r){var i=P(e);throw new Error("[mobx-react] class component ("+i+") is missing `render` method.\n`observer` requires `render` being a function defined on prototype.\n`render = () => {}` or `render = function() {}` is not supported.")}t.render=function(){return Object.defineProperty(this,"render",{configurable:!1,writable:!1,value:B.call(this,r)}),this.render()};var a=t.componentDidMount;return t.componentDidMount=function(){var e=this,t=M(this);return t.mounted=!0,u.unregister(this),t.forceUpdate=function(){return e.forceUpdate()},t.reaction&&!t.reactionInvalidatedBeforeMount||t.forceUpdate(),null==a?void 0:a.apply(this,arguments)},E(t,"componentWillUnmount",function(){var e,t=M(this);null==(e=t.reaction)||e.dispose(),t.reaction=null,t.forceUpdate=null,t.mounted=!1,t.reactionInvalidatedBeforeMount=!1}),e}(e):A(e)}if(o.version,!o.Component)throw new Error("mobx-react requires React to be available");if(!r.sH)throw new Error("mobx-react requires mobx to be available")},5597(e,t,n){"use strict";function r(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];throw new Error("number"==typeof e?"[MobX] minified error nr: "+e+(n.length?" "+n.map(String).join(","):"")+". Find the full error at: https://github.com/mobxjs/mobx/blob/main/packages/mobx/src/errors.ts":"[MobX] "+e)}n.d(t,{EW:()=>$e,Es:()=>Gn,Fq:()=>jn,Gn:()=>Rn,MN:()=>Z,Mr:()=>Ar,OB:()=>rr,Rn:()=>An,XI:()=>Qt,Zc:()=>cn,_t:()=>zt,fm:()=>Ht,go:()=>mr,hZ:()=>hn,jK:()=>Jt,jO:()=>pn,lB:()=>mn,mJ:()=>Wt,n8:()=>gn,pA:()=>sn,qT:()=>kt,sG:()=>vt,sH:()=>Fe,vx:()=>Ye,yl:()=>Xt,z7:()=>bn,zu:()=>fn});var o={};function i(){return"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==n.g?n.g:"undefined"!=typeof self?self:o}var a=Object.assign,l=Object.getOwnPropertyDescriptor,s=Object.defineProperty,c=Object.prototype,u=[];Object.freeze(u);var d={};Object.freeze(d);var f="undefined"!=typeof Proxy,p=Object.toString();function h(){f||r("Proxy not available")}function g(e){var t=!1;return function(){if(!t)return t=!0,e.apply(this,arguments)}}var m=function(){};function A(e){return"function"==typeof e}function b(e){switch(typeof e){case"string":case"symbol":case"number":return!0}return!1}function v(e){return null!==e&&"object"==typeof e}function y(e){if(!v(e))return!1;var t=Object.getPrototypeOf(e);if(null==t)return!0;var n=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n.toString()===p}function w(e){var t=null==e?void 0:e.constructor;return!!t&&("GeneratorFunction"===t.name||"GeneratorFunction"===t.displayName)}function C(e,t,n){s(e,t,{enumerable:!1,writable:!0,configurable:!0,value:n})}function S(e,t,n){s(e,t,{enumerable:!1,writable:!1,configurable:!0,value:n})}function x(e,t){var n="isMobX"+e;return t.prototype[n]=!0,function(e){return v(e)&&!0===e[n]}}function E(e){return null!=e&&"[object Map]"===Object.prototype.toString.call(e)}function I(e){return null!=e&&"[object Set]"===Object.prototype.toString.call(e)}var k=void 0!==Object.getOwnPropertySymbols,R="undefined"!=typeof Reflect&&Reflect.ownKeys?Reflect.ownKeys:k?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:Object.getOwnPropertyNames;function M(e){return null===e?null:"object"==typeof e?""+e:e}function P(e,t){return c.hasOwnProperty.call(e,t)}var B=Object.getOwnPropertyDescriptors||function(e){var t={};return R(e).forEach(function(n){t[n]=l(e,n)}),t};function _(e,t){return!!(e&t)}function T(e,t,n){return n?e|=t:e&=~t,e}function O(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function D(e,t,n){if($())return Reflect.construct.apply(null,arguments);var r=[null];r.push.apply(r,t);var o=new(e.bind.apply(e,r));return n&&H(o,n.prototype),o}function N(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,G(r.key),r)}}function L(e,t,n){return t&&N(e.prototype,t),n&&N(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function F(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(n)return(n=n.call(e)).next.bind(n);if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return O(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?O(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function Q(){return Q=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Q.apply(null,arguments)}function j(e){return j=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},j(e)}function z(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,H(e,t)}function $(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return($=function(){return!!e})()}function H(e,t){return H=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},H(e,t)}function G(e){var t=function(e){if("object"!=typeof e||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=typeof n)return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:t+""}function V(e){var t="function"==typeof Map?new Map:void 0;return V=function(e){if(null===e||!function(e){try{return-1!==Function.toString.call(e).indexOf("[native code]")}catch(t){return"function"==typeof e}}(e))return e;if("function"!=typeof e)throw new TypeError("Super expression must either be null or a function");if(void 0!==t){if(t.has(e))return t.get(e);t.set(e,n)}function n(){return D(e,arguments,j(this).constructor)}return n.prototype=Object.create(e.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),H(n,e)},V(e)}var W=Symbol("mobx-stored-annotations");function U(e){return Object.assign(function(t,n){if(Y(n))return e.decorate_20223_(t,n);q(t,n,e)},e)}function q(e,t,n){P(e,W)||C(e,W,Q({},e[W])),function(e){return e.annotationType_===re}(n)||(e[W][t]=n)}function Y(e){return"object"==typeof e&&"string"==typeof e.kind}var K=Symbol("mobx administration"),J=function(){function e(e){void 0===e&&(e="Atom"),this.name_=void 0,this.flags_=0,this.observers_=new Set,this.lastAccessedBy_=0,this.lowestObserverState_=tt.NOT_TRACKING_,this.onBOL=void 0,this.onBUOL=void 0,this.name_=e}var t=e.prototype;return t.onBO=function(){this.onBOL&&this.onBOL.forEach(function(e){return e()})},t.onBUO=function(){this.onBUOL&&this.onBUOL.forEach(function(e){return e()})},t.reportObserved=function(){return Et(this)},t.reportChanged=function(){St(),It(this),xt()},t.toString=function(){return this.name_},L(e,[{key:"isBeingObserved",get:function(){return _(this.flags_,e.isBeingObservedMask_)},set:function(t){this.flags_=T(this.flags_,e.isBeingObservedMask_,t)}},{key:"isPendingUnobservation",get:function(){return _(this.flags_,e.isPendingUnobservationMask_)},set:function(t){this.flags_=T(this.flags_,e.isPendingUnobservationMask_,t)}},{key:"diffValue",get:function(){return _(this.flags_,e.diffValueMask_)?1:0},set:function(t){this.flags_=T(this.flags_,e.diffValueMask_,1===t)}}])}();J.isBeingObservedMask_=1,J.isPendingUnobservationMask_=2,J.diffValueMask_=4;var X=x("Atom",J);function Z(e,t,n){void 0===t&&(t=m),void 0===n&&(n=m);var r=new J(e);return t!==m&&Yt(Ut,r,t,void 0),n!==m&&qt(r,n),r}var ee={identity:function(e,t){return e===t},structural:function(e,t){return Cr(e,t)},default:function(e,t){return Object.is?Object.is(e,t):e===t?0!==e||1/e==1/t:e!=e&&t!=t},shallow:function(e,t){return Cr(e,t,1)}};function te(e,t,n){return un(e)?e:Array.isArray(e)?Fe.array(e,{name:n}):y(e)?Fe.object(e,void 0,{name:n}):E(e)?Fe.map(e,{name:n}):I(e)?Fe.set(e,{name:n}):"function"!=typeof e||$t(e)||ln(e)?e:w(e)?on(e):jt(n,e)}function ne(e){return e}var re="override";function oe(e,t){return{annotationType_:e,options_:t,make_:ie,extend_:ae,decorate_20223_:le}}function ie(e,t,n,r){var o;if(null!=(o=this.options_)&&o.bound)return null===this.extend_(e,t,n,!1)?0:1;if(r===e.target_)return null===this.extend_(e,t,n,!1)?0:2;if($t(n.value))return 1;var i=se(e,this,t,n,!1);return s(r,t,i),2}function ae(e,t,n,r){var o=se(e,this,t,n);return e.defineProperty_(t,o,r)}function le(e,t){var n,o=t.kind,i=t.name,a=t.addInitializer,l=this,s=function(e){var t,n,r,o;return Ue(null!=(t=null==(n=l.options_)?void 0:n.name)?t:i.toString(),e,null!=(r=null==(o=l.options_)?void 0:o.autoAction)&&r)};return"field"==o?function(e){var t,n=e;return $t(n)||(n=s(n)),null!=(t=l.options_)&&t.bound&&((n=n.bind(this)).isMobxAction=!0),n}:"method"==o?($t(e)||(e=s(e)),null!=(n=this.options_)&&n.bound&&a(function(){var e=this,t=e[i].bind(e);t.isMobxAction=!0,e[i]=t}),e):void r("Cannot apply '"+l.annotationType_+"' to '"+String(i)+"' (kind: "+o+"):\n'"+l.annotationType_+"' can only be used on properties with a function value.")}function se(e,t,n,r,o){var i,a,l,s,c,u,d,f;void 0===o&&(o=bt.safeDescriptors),f=r,t.annotationType_,f.value;var p,h=r.value;return null!=(i=t.options_)&&i.bound&&(h=h.bind(null!=(p=e.proxy_)?p:e.target_)),{value:Ue(null!=(a=null==(l=t.options_)?void 0:l.name)?a:n.toString(),h,null!=(s=null==(c=t.options_)?void 0:c.autoAction)&&s,null!=(u=t.options_)&&u.bound?null!=(d=e.proxy_)?d:e.target_:void 0),configurable:!o||e.isPlainObject_,enumerable:!1,writable:!o}}function ce(e,t){return{annotationType_:e,options_:t,make_:ue,extend_:de,decorate_20223_:fe}}function ue(e,t,n,r){var o;if(r===e.target_)return null===this.extend_(e,t,n,!1)?0:2;if(null!=(o=this.options_)&&o.bound&&(!P(e.target_,t)||!ln(e.target_[t]))&&null===this.extend_(e,t,n,!1))return 0;if(ln(n.value))return 1;var i=pe(e,this,0,n,!1,!1);return s(r,t,i),2}function de(e,t,n,r){var o,i=pe(e,this,0,n,null==(o=this.options_)?void 0:o.bound);return e.defineProperty_(t,i,r)}function fe(e,t){var n,r=t.name,o=t.addInitializer;return ln(e)||(e=on(e)),null!=(n=this.options_)&&n.bound&&o(function(){var e=this,t=e[r].bind(e);t.isMobXFlow=!0,e[r]=t}),e}function pe(e,t,n,r,o,i){var a;void 0===i&&(i=bt.safeDescriptors),a=r,t.annotationType_,a.value;var l,s=r.value;return ln(s)||(s=on(s)),o&&((s=s.bind(null!=(l=e.proxy_)?l:e.target_)).isMobXFlow=!0),{value:s,configurable:!i||e.isPlainObject_,enumerable:!1,writable:!i}}function he(e,t){return{annotationType_:e,options_:t,make_:ge,extend_:me,decorate_20223_:Ae}}function ge(e,t,n){return null===this.extend_(e,t,n,!1)?0:1}function me(e,t,n,r){return o=n,this.annotationType_,o.get,e.defineComputedProperty_(t,Q({},this.options_,{get:n.get,set:n.set}),r);var o}function Ae(e,t){var n,r=this,o=t.name;function i(t,n){var i=Q({},r.options_,{get:e,context:t});return i.name||(i.name="ObservableObject."+o.toString()),new et(i)}return(0,t.addInitializer)(function(){var t,n=er(this)[K],r=this,a=n.values_.get(o);a instanceof et&&a.derivation!==e&&n.values_.delete(o),(null!=(t=n.lazyComputedKeys_)?t:n.lazyComputedKeys_=new Map).set(o,function(){return i(r)})}),function(){var t=this[K],r=t.values_.get(o);if(r instanceof et&&r.derivation!==e){var a,l,s=null==(a=n)?void 0:a.get(this);return s||(s=i(this),(null!=(l=n)?l:n=new WeakMap).set(this,s)),s.get()}return t.getObservablePropValue_(o)}}function be(e,t){return{annotationType_:e,options_:t,make_:ve,extend_:ye,decorate_20223_:we}}function ve(e,t,n){return null===this.extend_(e,t,n,!1)?0:1}function ye(e,t,n,r){var o,i;return this.annotationType_,e.defineObservableProperty_(t,n.value,null!=(o=null==(i=this.options_)?void 0:i.enhancer)?o:te,r)}function we(e,t){var n=this,r=t.kind,o=t.name;if("accessor"===r)return{get:function(){var t;return(null!=(t=this[K])?t:i(this,e.get.call(this))).getObservablePropValue_(o)},set:function(e){var t;return(null!=(t=this[K])?t:i(this,e)).setObservablePropValue_(o,e)},init:function(e){return i(this,e),e}};function i(e,t){var r,i=er(e)[K];return(null!=(r=i.lazyObservableKeys_)?r:i.lazyObservableKeys_=new Map).set(o,function(){var e,r;return new Xe(t,null!=(e=null==(r=n.options_)?void 0:r.enhancer)?e:te,"ObservableObject."+o.toString(),!1)}),i}}var Ce=Se();function Se(e){return{annotationType_:"true",options_:e,make_:xe,extend_:Ee,decorate_20223_:Ie}}function xe(e,t,n,r){var o,i,a,l;if(n.get)return $e.make_(e,t,n,r);if(n.set){var c=$t(n.set)?n.set:Ue(t.toString(),n.set);return r===e.target_?null===e.defineProperty_(t,{configurable:!bt.safeDescriptors||e.isPlainObject_,set:c})?0:2:(s(r,t,{configurable:!0,set:c}),2)}if(r!==e.target_&&"function"==typeof n.value)return w(n.value)?(null!=(l=this.options_)&&l.autoBind?on.bound:on).make_(e,t,n,r):(null!=(a=this.options_)&&a.autoBind?jt.bound:jt).make_(e,t,n,r);var u,d=!1===(null==(o=this.options_)?void 0:o.deep)?Fe.ref:Fe;return"function"==typeof n.value&&null!=(i=this.options_)&&i.autoBind&&(n.value=n.value.bind(null!=(u=e.proxy_)?u:e.target_)),d.make_(e,t,n,r)}function Ee(e,t,n,r){var o,i,a;return n.get?$e.extend_(e,t,n,r):n.set?e.defineProperty_(t,{configurable:!bt.safeDescriptors||e.isPlainObject_,set:Ue(t.toString(),n.set)},r):("function"==typeof n.value&&null!=(o=this.options_)&&o.autoBind&&(n.value=n.value.bind(null!=(a=e.proxy_)?a:e.target_)),(!1===(null==(i=this.options_)?void 0:i.deep)?Fe.ref:Fe).extend_(e,t,n,r))}function Ie(e,t){r("'"+this.annotationType_+"' cannot be used as a decorator")}var ke={deep:!0,name:void 0,defaultDecorator:void 0,proxy:!0};function Re(e){return e||ke}Object.freeze(ke);var Me=be("observable"),Pe=be("observable.ref",{enhancer:ne}),Be=be("observable.shallow",{enhancer:function(e,t,n){return null==e||rr(e)||jn(e)||Vn(e)||Yn(e)?e:Array.isArray(e)?Fe.array(e,{name:n,deep:!1}):y(e)?Fe.object(e,void 0,{name:n,deep:!1}):E(e)?Fe.map(e,{name:n,deep:!1}):I(e)?Fe.set(e,{name:n,deep:!1}):void 0}}),_e=be("observable.struct",{enhancer:function(e,t){return Cr(e,t)?t:e}}),Te=U(Me);function Oe(e){return!0===e.deep?te:!1===e.deep?ne:(t=e.defaultDecorator)&&null!=(n=null==(r=t.options_)?void 0:r.enhancer)?n:te;var t,n,r}function De(e,t,n){return Y(t)?Me.decorate_20223_(e,t):b(t)?void q(e,t,Me):un(e)?e:y(e)?Fe.object(e,t,n):Array.isArray(e)?Fe.array(e,t):E(e)?Fe.map(e,t):I(e)?Fe.set(e,t):"object"==typeof e&&null!==e?e:Fe.box(e,t)}a(De,Te);var Ne,Le,Fe=a(De,{box:function(e,t){var n=Re(t);return new Xe(e,Oe(n),n.name,!0,n.equals)},array:function(e,t){var n=Re(t);return(!1===bt.useProxies||!1===n.proxy?gr:Tn)(e,Oe(n),n.name)},map:function(e,t){var n=Re(t);return new Gn(e,Oe(n),n.name)},set:function(e,t){var n=Re(t);return new qn(e,Oe(n),n.name)},object:function(e,t,n){return vr(function(){return function(e,t,n,r){var o=B(t);return vr(function(){var t=er(e,r)[K];R(o).forEach(function(e){t.extend_(e,o[e],!n||!(e in n)||n[e])})}),e}(!1===bt.useProxies||!1===(null==n?void 0:n.proxy)?er({},n):function(e,t){var n,r;return h(),null!=(r=(n=(e=er(e,t))[K]).proxy_)?r:n.proxy_=new Proxy(e,wn)}({},n),e,t)})},ref:U(Pe),shallow:U(Be),deep:Te,struct:U(_e)}),Qe="computed",je=he(Qe),ze=he("computed.struct",{equals:ee.structural}),$e=function(e,t){if(Y(t))return je.decorate_20223_(e,t);if(b(t))return q(e,t,je);if(y(e))return U(he(Qe,e));var n=y(t)?t:{};return n.get=e,n.name||(n.name=e.name||""),new et(n)};Object.assign($e,je),$e.struct=U(ze);var He=0,Ge=1,Ve=null!=(Ne=null==(Le=l(function(){},"name"))?void 0:Le.configurable)&&Ne,We={value:"action",configurable:!0,writable:!1,enumerable:!1};function Ue(e,t,n,r){function o(){return qe(0,n,t,r||this,arguments)}return void 0===n&&(n=!1),o.isMobxAction=!0,o.toString=function(){return t.toString()},Ve&&(We.value=e,s(o,"name",We)),o}function qe(e,t,n,o,i){var a=function(e,t){var n=bt.trackingDerivation,r=!t||!n;St();var o=bt.allowStateChanges;r&&(ut(),o=Ke(!0));var i={runAsAction_:r,prevDerivation_:n,prevAllowStateChanges_:o,prevAllowStateReads_:ft(!0),notifySpy_:!1,startTime_:0,actionId_:Ge++,parentActionId_:He};return He=i.actionId_,i}(0,t);try{return n.apply(o,i)}catch(e){throw a.error_=e,e}finally{!function(e){He!==e.actionId_&&r(30),He=e.parentActionId_,void 0!==e.error_&&(bt.suppressReactionErrors=!0),Je(e.prevAllowStateChanges_),pt(e.prevAllowStateReads_),xt(),e.runAsAction_&&dt(e.prevDerivation_),bt.suppressReactionErrors=!1}(a)}}function Ye(e,t){var n=Ke(e);try{return t()}finally{Je(n)}}function Ke(e){var t=bt.allowStateChanges;return bt.allowStateChanges=e,t}function Je(e){bt.allowStateChanges=e}var Xe=function(e){function t(t,n,r,o,i){var a;return void 0===r&&(r="ObservableValue"),void 0===o&&(o=!0),void 0===i&&(i=ee.default),(a=e.call(this,r)||this).enhancer=void 0,a.name_=void 0,a.equals=void 0,a.hasUnreportedChange_=!1,a.interceptors_=void 0,a.changeListeners_=void 0,a.value_=void 0,a.dehancer=void 0,a.enhancer=n,a.name_=r,a.equals=i,a.value_=n(t,void 0,r),a}z(t,e);var n=t.prototype;return n.dehanceValue=function(e){return void 0!==this.dehancer?this.dehancer(e):e},n.set=function(e){this.value_,(e=this.prepareNewValue_(e))!==bt.UNCHANGED&&this.setNewValue_(e)},n.prepareNewValue_=function(e){if(Cn(this)){var t=xn(this,{object:this,type:Pn,newValue:e});if(!t)return bt.UNCHANGED;e=t.newValue}return e=this.enhancer(e,this.value_,this.name_),this.equals(this.value_,e)?bt.UNCHANGED:e},n.setNewValue_=function(e){var t=this.value_;this.value_=e,this.reportChanged(),En(this)&&kn(this,{type:Pn,object:this,newValue:e,oldValue:t})},n.get=function(){return this.reportObserved(),this.dehanceValue(this.value_)},n.intercept_=function(e){return Sn(this,e)},n.observe_=function(e,t){return t&&e({observableKind:"value",debugObjectName:this.name_,object:this,type:Pn,newValue:this.value_,oldValue:void 0}),In(this,e)},n.raw=function(){return this.value_},n.toJSON=function(){return this.get()},n.toString=function(){return this.name_+"["+this.value_+"]"},n.valueOf=function(){return M(this.get())},n[Symbol.toPrimitive]=function(){return this.valueOf()},t}(J),Ze=x("ObservableValue",Xe),et=function(){function e(e){this.dependenciesState_=tt.NOT_TRACKING_,this.observing_=[],this.newObserving_=null,this.observers_=new Set,this.runId_=0,this.lastAccessedBy_=0,this.lowestObserverState_=tt.UP_TO_DATE_,this.unboundDepsCount_=0,this.value_=new ot(null),this.name_=void 0,this.triggeredBy_=void 0,this.flags_=0,this.derivation=void 0,this.setter_=void 0,this.isTracing_=nt.NONE,this.scope_=void 0,this.equals_=void 0,this.requiresReaction_=void 0,this.keepAlive_=void 0,this.onBOL=void 0,this.onBUOL=void 0,e.get||r(31),this.derivation=e.get,this.name_=e.name||"ComputedValue",e.set&&(this.setter_=Ue("ComputedValue-setter",e.set)),this.equals_=e.equals||(e.compareStructural||e.struct?ee.structural:ee.default),this.scope_=e.context,this.requiresReaction_=e.requiresReaction,this.keepAlive_=!!e.keepAlive}var t=e.prototype;return t.onBecomeStale_=function(){!function(e){e.lowestObserverState_===tt.UP_TO_DATE_&&(e.lowestObserverState_=tt.POSSIBLY_STALE_,e.observers_.forEach(function(e){e.dependenciesState_===tt.UP_TO_DATE_&&(e.dependenciesState_=tt.POSSIBLY_STALE_,e.onBecomeStale_())}))}(this)},t.onBO=function(){this.onBOL&&this.onBOL.forEach(function(e){return e()})},t.onBUO=function(){this.onBUOL&&this.onBUOL.forEach(function(e){return e()})},t.get=function(){if(this.isComputing&&r(32,this.name_,this.derivation),0!==bt.inBatch||0!==this.observers_.size||this.keepAlive_){if(Et(this),at(this)){var e=bt.trackingContext;this.keepAlive_&&!e&&(bt.trackingContext=this),this.trackAndCompute()&&function(e){e.lowestObserverState_!==tt.STALE_&&(e.lowestObserverState_=tt.STALE_,e.observers_.forEach(function(t){t.dependenciesState_===tt.POSSIBLY_STALE_?t.dependenciesState_=tt.STALE_:t.dependenciesState_===tt.UP_TO_DATE_&&(e.lowestObserverState_=tt.UP_TO_DATE_)}))}(this),bt.trackingContext=e}}else at(this)&&(this.warnAboutUntrackedRead_(),St(),this.value_=this.computeValue_(!1),xt());var t=this.value_;if(it(t))throw t.cause;return t},t.set=function(e){if(this.setter_){this.isRunningSetter&&r(33,this.name_),this.isRunningSetter=!0;try{this.setter_.call(this.scope_,e)}finally{this.isRunningSetter=!1}}else r(34,this.name_)},t.trackAndCompute=function(){var e=this.value_,t=this.dependenciesState_===tt.NOT_TRACKING_,n=this.computeValue_(!0),r=t||it(e)||it(n)||!this.equals_(e,n);return r&&(this.value_=n),r},t.computeValue_=function(e){this.isComputing=!0;var t,n=Ke(!1);if(e)t=lt(this,this.derivation,this.scope_);else if(!0===bt.disableErrorBoundaries)t=this.derivation.call(this.scope_);else try{t=this.derivation.call(this.scope_)}catch(e){t=new ot(e)}return Je(n),this.isComputing=!1,t},t.suspend_=function(){this.keepAlive_||(st(this),this.value_=void 0)},t.observe_=function(e,t){var n=this,r=!0,o=void 0;return Ht(function(){var i=n.get();if(!r||t){var a=ut();e({observableKind:"computed",debugObjectName:n.name_,type:Pn,object:n,newValue:i,oldValue:o}),dt(a)}r=!1,o=i})},t.warnAboutUntrackedRead_=function(){},t.toString=function(){return this.name_+"["+this.derivation.toString()+"]"},t.valueOf=function(){return M(this.get())},t[Symbol.toPrimitive]=function(){return this.valueOf()},L(e,[{key:"isComputing",get:function(){return _(this.flags_,e.isComputingMask_)},set:function(t){this.flags_=T(this.flags_,e.isComputingMask_,t)}},{key:"isRunningSetter",get:function(){return _(this.flags_,e.isRunningSetterMask_)},set:function(t){this.flags_=T(this.flags_,e.isRunningSetterMask_,t)}},{key:"isBeingObserved",get:function(){return _(this.flags_,e.isBeingObservedMask_)},set:function(t){this.flags_=T(this.flags_,e.isBeingObservedMask_,t)}},{key:"isPendingUnobservation",get:function(){return _(this.flags_,e.isPendingUnobservationMask_)},set:function(t){this.flags_=T(this.flags_,e.isPendingUnobservationMask_,t)}},{key:"diffValue",get:function(){return _(this.flags_,e.diffValueMask_)?1:0},set:function(t){this.flags_=T(this.flags_,e.diffValueMask_,1===t)}}])}();et.isComputingMask_=1,et.isRunningSetterMask_=2,et.isBeingObservedMask_=4,et.isPendingUnobservationMask_=8,et.diffValueMask_=16;var tt,nt,rt=x("ComputedValue",et);!function(e){e[e.NOT_TRACKING_=-1]="NOT_TRACKING_",e[e.UP_TO_DATE_=0]="UP_TO_DATE_",e[e.POSSIBLY_STALE_=1]="POSSIBLY_STALE_",e[e.STALE_=2]="STALE_"}(tt||(tt={})),function(e){e[e.NONE=0]="NONE",e[e.LOG=1]="LOG",e[e.BREAK=2]="BREAK"}(nt||(nt={}));var ot=function(e){this.cause=void 0,this.cause=e};function it(e){return e instanceof ot}function at(e){switch(e.dependenciesState_){case tt.UP_TO_DATE_:return!1;case tt.NOT_TRACKING_:case tt.STALE_:return!0;case tt.POSSIBLY_STALE_:for(var t=ft(!0),n=ut(),r=e.observing_,o=r.length,i=0;i<o;i++){var a=r[i];if(rt(a)){if(bt.disableErrorBoundaries)a.get();else try{a.get()}catch(e){return dt(n),pt(t),!0}if(e.dependenciesState_===tt.STALE_)return dt(n),pt(t),!0}}return ht(e),dt(n),pt(t),!1}}function lt(e,t,n){var r=ft(!0);ht(e),e.newObserving_=new Array(0===e.runId_?100:e.observing_.length),e.unboundDepsCount_=0,e.runId_=++bt.runId;var o,i=bt.trackingDerivation;if(bt.trackingDerivation=e,bt.inBatch++,!0===bt.disableErrorBoundaries)o=t.call(n);else try{o=t.call(n)}catch(e){o=new ot(e)}return bt.inBatch--,bt.trackingDerivation=i,function(e){for(var t=e.observing_,n=e.observing_=e.newObserving_,r=tt.UP_TO_DATE_,o=0,i=e.unboundDepsCount_,a=0;a<i;a++){var l=n[a];0===l.diffValue&&(l.diffValue=1,o!==a&&(n[o]=l),o++),l.dependenciesState_>r&&(r=l.dependenciesState_)}for(n.length=o,e.newObserving_=null,i=t.length;i--;){var s=t[i];0===s.diffValue&&wt(s,e),s.diffValue=0}for(;o--;){var c=n[o];1===c.diffValue&&(c.diffValue=0,yt(c,e))}r!==tt.UP_TO_DATE_&&(e.dependenciesState_=r,e.onBecomeStale_())}(e),pt(r),o}function st(e){var t=e.observing_;e.observing_=[];for(var n=t.length;n--;)wt(t[n],e);e.dependenciesState_=tt.NOT_TRACKING_}function ct(e){var t=ut();try{return e()}finally{dt(t)}}function ut(){var e=bt.trackingDerivation;return bt.trackingDerivation=null,e}function dt(e){bt.trackingDerivation=e}function ft(e){var t=bt.allowStateReads;return bt.allowStateReads=e,t}function pt(e){bt.allowStateReads=e}function ht(e){if(e.dependenciesState_!==tt.UP_TO_DATE_){e.dependenciesState_=tt.UP_TO_DATE_;for(var t=e.observing_,n=t.length;n--;)t[n].lowestObserverState_=tt.UP_TO_DATE_}}var gt=function(){this.version=6,this.UNCHANGED={},this.trackingDerivation=null,this.trackingContext=null,this.runId=0,this.mobxGuid=0,this.inBatch=0,this.pendingUnobservations=[],this.pendingReactions=[],this.isRunningReactions=!1,this.allowStateChanges=!1,this.allowStateReads=!0,this.enforceActions=!0,this.spyListeners=[],this.globalReactionErrorHandlers=[],this.computedRequiresReaction=!1,this.reactionRequiresObservable=!1,this.observableRequiresReaction=!1,this.disableErrorBoundaries=!1,this.suppressReactionErrors=!1,this.useProxies=!0,this.verifyProxies=!1,this.safeDescriptors=!0},mt=!0,At=!1,bt=function(){var e=i();return e.__mobxInstanceCount>0&&!e.__mobxGlobals&&(mt=!1),e.__mobxGlobals&&e.__mobxGlobals.version!==(new gt).version&&(mt=!1),mt?e.__mobxGlobals?(e.__mobxInstanceCount+=1,e.__mobxGlobals.UNCHANGED||(e.__mobxGlobals.UNCHANGED={}),e.__mobxGlobals):(e.__mobxInstanceCount=1,e.__mobxGlobals=new gt):(setTimeout(function(){At||r(35)},1),new gt)}();function vt(){return bt}function yt(e,t){e.observers_.add(t),e.lowestObserverState_>t.dependenciesState_&&(e.lowestObserverState_=t.dependenciesState_)}function wt(e,t){e.observers_.delete(t),0===e.observers_.size&&Ct(e)}function Ct(e){!1===e.isPendingUnobservation&&(e.isPendingUnobservation=!0,bt.pendingUnobservations.push(e))}function St(){bt.inBatch++}function xt(){if(0===--bt.inBatch){Mt();for(var e=bt.pendingUnobservations,t=0;t<e.length;t++){var n=e[t];n.isPendingUnobservation=!1,0===n.observers_.size&&(n.isBeingObserved&&(n.isBeingObserved=!1,n.onBUO()),n instanceof et&&n.suspend_())}bt.pendingUnobservations=[]}}function Et(e){var t=bt.trackingDerivation;return null!==t?(t.runId_!==e.lastAccessedBy_&&(e.lastAccessedBy_=t.runId_,t.newObserving_[t.unboundDepsCount_++]=e,!e.isBeingObserved&&bt.trackingContext&&(e.isBeingObserved=!0,e.onBO())),e.isBeingObserved):(0===e.observers_.size&&bt.inBatch>0&&Ct(e),!1)}function It(e){e.lowestObserverState_!==tt.STALE_&&(e.lowestObserverState_=tt.STALE_,e.observers_.forEach(function(e){e.dependenciesState_===tt.UP_TO_DATE_&&e.onBecomeStale_(),e.dependenciesState_=tt.STALE_}))}var kt=function(){function e(e,t,n,r){void 0===e&&(e="Reaction"),this.name_=void 0,this.onInvalidate_=void 0,this.errorHandler_=void 0,this.requiresObservable_=void 0,this.observing_=[],this.newObserving_=[],this.dependenciesState_=tt.NOT_TRACKING_,this.runId_=0,this.unboundDepsCount_=0,this.flags_=0,this.isTracing_=nt.NONE,this.name_=e,this.onInvalidate_=t,this.errorHandler_=n,this.requiresObservable_=r}var t=e.prototype;return t.onBecomeStale_=function(){this.schedule_()},t.schedule_=function(){this.isScheduled||(this.isScheduled=!0,bt.pendingReactions.push(this),Mt())},t.runReaction_=function(){if(!this.isDisposed){St(),this.isScheduled=!1;var e=bt.trackingContext;if(bt.trackingContext=this,at(this)){this.isTrackPending=!0;try{this.onInvalidate_()}catch(e){this.reportExceptionInDerivation_(e)}}bt.trackingContext=e,xt()}},t.track=function(e){if(!this.isDisposed){St(),this.isRunning=!0;var t=bt.trackingContext;bt.trackingContext=this;var n=lt(this,e,void 0);bt.trackingContext=t,this.isRunning=!1,this.isTrackPending=!1,this.isDisposed&&st(this),it(n)&&this.reportExceptionInDerivation_(n.cause),xt()}},t.reportExceptionInDerivation_=function(e){var t=this;if(this.errorHandler_)this.errorHandler_(e,this);else{if(bt.disableErrorBoundaries)throw e;var n="[mobx] uncaught error in '"+this+"'";bt.suppressReactionErrors||console.error(n,e),bt.globalReactionErrorHandlers.forEach(function(n){return n(e,t)})}},t.dispose=function(){this.isDisposed||(this.isDisposed=!0,this.isRunning||(St(),st(this),xt()))},t.getDisposer_=function(e){var t=this,n=function n(){t.dispose(),null==e||null==e.removeEventListener||e.removeEventListener("abort",n)};return null==e||null==e.addEventListener||e.addEventListener("abort",n),n[K]=this,"dispose"in Symbol&&"symbol"==typeof Symbol.dispose&&(n[Symbol.dispose]=n),n},t.toString=function(){return"Reaction["+this.name_+"]"},t.trace=function(e){void 0===e&&(e=!1)},L(e,[{key:"isDisposed",get:function(){return _(this.flags_,e.isDisposedMask_)},set:function(t){this.flags_=T(this.flags_,e.isDisposedMask_,t)}},{key:"isScheduled",get:function(){return _(this.flags_,e.isScheduledMask_)},set:function(t){this.flags_=T(this.flags_,e.isScheduledMask_,t)}},{key:"isTrackPending",get:function(){return _(this.flags_,e.isTrackPendingMask_)},set:function(t){this.flags_=T(this.flags_,e.isTrackPendingMask_,t)}},{key:"isRunning",get:function(){return _(this.flags_,e.isRunningMask_)},set:function(t){this.flags_=T(this.flags_,e.isRunningMask_,t)}},{key:"diffValue",get:function(){return _(this.flags_,e.diffValueMask_)?1:0},set:function(t){this.flags_=T(this.flags_,e.diffValueMask_,1===t)}}])}();kt.isDisposedMask_=1,kt.isScheduledMask_=2,kt.isTrackPendingMask_=4,kt.isRunningMask_=8,kt.diffValueMask_=16;var Rt=function(e){return e()};function Mt(){bt.inBatch>0||bt.isRunningReactions||Rt(Pt)}function Pt(){bt.isRunningReactions=!0;for(var e=bt.pendingReactions,t=0;e.length>0;){100===++t&&(console.error("[mobx] cycle in reaction: "+e[0]),e.splice(0));for(var n=e.splice(0),r=0,o=n.length;r<o;r++)n[r].runReaction_()}bt.isRunningReactions=!1}var Bt=x("Reaction",kt),_t="action",Tt="autoAction",Ot=oe(_t),Dt=oe("action.bound",{bound:!0}),Nt=oe(Tt,{autoAction:!0}),Lt=oe("autoAction.bound",{autoAction:!0,bound:!0});function Ft(e){return function(t,n){return A(t)?Ue(t.name||"<unnamed action>",t,e):A(n)?Ue(t,n,e):Y(n)?(e?Nt:Ot).decorate_20223_(t,n):b(n)?q(t,n,e?Nt:Ot):b(t)?U(oe(e?Tt:_t,{name:t,autoAction:e})):void 0}}var Qt=Ft(!1);Object.assign(Qt,Ot);var jt=Ft(!0);function zt(e){return qe(e.name,!1,e,this,void 0)}function $t(e){return A(e)&&!0===e.isMobxAction}function Ht(e,t){var n,r,o,i;void 0===t&&(t=d);var a,l=null!=(n=null==(r=t)?void 0:r.name)?n:"Autorun";if(t.scheduler||t.delay){var s=Vt(t),c=!1;a=new kt(l,function(){c||(c=!0,s(function(){c=!1,a.isDisposed||a.track(u)}))},t.onError,t.requiresObservable)}else a=new kt(l,function(){this.track(u)},t.onError,t.requiresObservable);function u(){e(a)}return null!=(o=t)&&null!=(o=o.signal)&&o.aborted||a.schedule_(),a.getDisposer_(null==(i=t)?void 0:i.signal)}Object.assign(jt,Nt),Qt.bound=U(Dt),jt.bound=U(Lt);var Gt=function(e){return e()};function Vt(e){return e.scheduler?e.scheduler:e.delay?function(t){return setTimeout(t,e.delay)}:Gt}function Wt(e,t,n){var r,o,i;void 0===n&&(n=d);var a,l,s,c=null!=(r=n.name)?r:"Reaction",u=Qt(c,n.onError?(a=n.onError,l=t,function(){try{return l.apply(this,arguments)}catch(e){a.call(this,e)}}):t),f=!n.scheduler&&!n.delay,p=Vt(n),h=!0,g=!1,m=n.compareStructural?ee.structural:n.equals||ee.default,A=new kt(c,function(){h||f?b():g||(g=!0,p(b))},n.onError,n.requiresObservable);function b(){if(g=!1,!A.isDisposed){var t=!1,r=s;A.track(function(){var n=Ye(!1,function(){return e(A)});t=h||!m(s,n),s=n}),(h&&n.fireImmediately||!h&&t)&&u(s,r,A),h=!1}}return null!=(o=n)&&null!=(o=o.signal)&&o.aborted||A.schedule_(),A.getDisposer_(null==(i=n)?void 0:i.signal)}var Ut="onBO";function qt(e,t,n){return Yt("onBUO",e,t,n)}function Yt(e,t,n,r){var o="function"==typeof r?mr(t,n):mr(t),i=A(r)?r:n,a=e+"L";return o[a]?o[a].add(i):o[a]=new Set([i]),function(){var e=o[a];e&&(e.delete(i),0===e.size&&delete o[a])}}var Kt="always";function Jt(e){!0===e.isolateGlobalState&&function(){if((bt.pendingReactions.length||bt.inBatch||bt.isRunningReactions)&&r(36),At=!0,mt){var e=i();0===--e.__mobxInstanceCount&&(e.__mobxGlobals=void 0),bt=new gt}}();var t,n,o=e.useProxies,a=e.enforceActions;if(void 0!==o&&(bt.useProxies=o===Kt||"never"!==o&&"undefined"!=typeof Proxy),"ifavailable"===o&&(bt.verifyProxies=!0),void 0!==a){var l=a===Kt?Kt:"observed"===a;bt.enforceActions=l,bt.allowStateChanges=!0!==l&&l!==Kt}["computedRequiresReaction","reactionRequiresObservable","observableRequiresReaction","disableErrorBoundaries","safeDescriptors"].forEach(function(t){t in e&&(bt[t]=!!e[t])}),bt.allowStateReads=!bt.observableRequiresReaction,e.reactionScheduler&&(t=e.reactionScheduler,n=Rt,Rt=function(e){return t(function(){return n(e)})})}function Xt(e,t){return Zt(mr(e,t))}function Zt(e){var t,n={name:e.name_};return e.observing_&&e.observing_.length>0&&(n.dependencies=(t=e.observing_,Array.from(new Set(t))).map(Zt)),n}var en=0,tn=function(e){function t(){var n;return n=e.call(this,"FLOW_CANCELLED")||this,Object.setPrototypeOf(n,(this instanceof t?this.constructor:void 0).prototype),n.name="FlowCancellationError",n}return z(t,e),t.prototype.toString=function(){return"Error: "+this.message},t}(V(Error)),nn=ce("flow"),rn=ce("flow.bound",{bound:!0}),on=Object.assign(function(e,t){if(Y(t))return nn.decorate_20223_(e,t);if(b(t))return q(e,t,nn);var n=e,r=n.name||"<unnamed flow>",o=function(){var e,t=arguments,o=++en,i=Qt(r+" - runid: "+o+" - init",n).apply(this,t),a=void 0,l=new Promise(function(t,n){var l=0;function s(e){var t;a=void 0;try{t=Qt(r+" - runid: "+o+" - yield "+l++,i.next).call(i,e)}catch(e){return n(e)}u(t)}function c(e){var t;a=void 0;try{t=Qt(r+" - runid: "+o+" - yield "+l++,i.throw).call(i,e)}catch(e){return n(e)}u(t)}function u(e){if(!A(null==e?void 0:e.then))return e.done?t(e.value):(a=Promise.resolve(e.value)).then(s,c);e.then(u,n)}e=n,s(void 0)});return l.cancel=Qt(r+" - runid: "+o+" - cancel",function(){try{a&&an(a);var t=i.return(void 0),n=Promise.resolve(t.value);n.then(m,m),an(n),e(new tn)}catch(t){e(t)}}),l};return o.isMobXFlow=!0,o},nn);function an(e){A(e.cancel)&&e.cancel()}function ln(e){return!0===(null==e?void 0:e.isMobXFlow)}function sn(e,t,n){var r;return Vn(e)||jn(e)||Ze(e)?r=Ar(e):rr(e)&&(r=Ar(e,t)),r.dehancer="function"==typeof t?t:n,function(){r.dehancer=void 0}}function cn(e,t,n){return A(n)?function(e,t,n){return Ar(e,t).intercept_(n)}(e,t,n):function(e,t){return Ar(e).intercept_(t)}(e,t)}function un(e){return function(e,t){if(!e)return!1;if(void 0!==t){if(rr(e)){var n,r,o=e[K];return o.values_.has(t)||!(null==(n=o.lazyComputedKeys_)||!n.has(t))||!(null==(r=o.lazyObservableKeys_)||!r.has(t))}return!1}return rr(e)||!!e[K]||X(e)||Bt(e)||rt(e)}(e)}function dn(e){return rr(e)?e[K].keys_():Vn(e)||Yn(e)?Array.from(e.keys()):jn(e)?e.map(function(e,t){return t}):void r(5)}function fn(e){return rr(e)?dn(e).map(function(t){return e[t]}):Vn(e)?dn(e).map(function(t){return e.get(t)}):Yn(e)?Array.from(e.values()):jn(e)?e.slice():void r(6)}function pn(e){return rr(e)?dn(e).map(function(t){return[t,e[t]]}):Vn(e)?dn(e).map(function(t){return[t,e.get(t)]}):Yn(e)?Array.from(e.entries()):jn(e)?e.map(function(e,t){return[t,e]}):void r(7)}function hn(e,t,n){if(2!==arguments.length||Yn(e))rr(e)?e[K].set_(t,n):Vn(e)?e.set(t,n):Yn(e)?e.add(t):jn(e)?("number"!=typeof t&&(t=parseInt(t,10)),t<0&&r("Invalid index: '"+t+"'"),St(),t>=e.length&&(e.length=t+1),e[t]=n,xt()):r(8);else{St();var o=t;try{for(var i in o)hn(e,i,o[i])}finally{xt()}}}function gn(e,t,n){if(rr(e))return e[K].defineProperty_(t,n);r(39)}function mn(e,t,n,r){return A(n)?function(e,t,n,r){return Ar(e,t).observe_(n,r)}(e,t,n,r):function(e,t,n){return Ar(e).observe_(t,n)}(e,t,n)}function An(e,t){void 0===t&&(t=void 0),St();try{return e.apply(t)}finally{xt()}}function bn(e,t,n){return 1===arguments.length||t&&"object"==typeof t?function(e,t){var n,r,o;if(null!=t&&null!=(n=t.signal)&&n.aborted)return Object.assign(Promise.reject(new Error("WHEN_ABORTED")),{cancel:function(){return null}});var i=new Promise(function(n,i){var a,l=vn(e,n,Q({},t,{onError:i}));r=function(){l(),i(new Error("WHEN_CANCELLED"))},o=function(){l(),i(new Error("WHEN_ABORTED"))},null==t||null==(a=t.signal)||null==a.addEventListener||a.addEventListener("abort",o)}).finally(function(){var e;return null==t||null==(e=t.signal)||null==e.removeEventListener?void 0:e.removeEventListener("abort",o)});return i.cancel=r,i}(e,t):vn(e,t,n||{})}function vn(e,t,n){var r;if("number"==typeof n.timeout){var o=new Error("WHEN_TIMEOUT");r=setTimeout(function(){if(!a[K].isDisposed){if(a(),!n.onError)throw o;n.onError(o)}},n.timeout)}n.name="When";var i=Ue("When-effect",t),a=Ht(function(t){Ye(!1,e)&&(t.dispose(),r&&clearTimeout(r),i())},n);return a}function yn(e){return e[K]}on.bound=U(rn);var wn={has:function(e,t){return yn(e).has_(t)},get:function(e,t){return yn(e).get_(t)},set:function(e,t,n){var r;return!!b(t)&&(null==(r=yn(e).set_(t,n,!0))||r)},deleteProperty:function(e,t){var n;return!!b(t)&&(null==(n=yn(e).delete_(t,!0))||n)},defineProperty:function(e,t,n){var r;return null==(r=yn(e).defineProperty_(t,n))||r},ownKeys:function(e){return yn(e).ownKeys_()},preventExtensions:function(e){r(13)}};function Cn(e){return void 0!==e.interceptors_&&e.interceptors_.length>0}function Sn(e,t){var n=e.interceptors_||(e.interceptors_=[]);return n.push(t),g(function(){var e=n.indexOf(t);-1!==e&&n.splice(e,1)})}function xn(e,t){var n=ut();try{for(var o=[].concat(e.interceptors_||[]),i=0,a=o.length;i<a&&((t=o[i](t))&&!t.type&&r(14),t);i++);return t}finally{dt(n)}}function En(e){return void 0!==e.changeListeners_&&e.changeListeners_.length>0}function In(e,t){var n=e.changeListeners_||(e.changeListeners_=[]);return n.push(t),g(function(){var e=n.indexOf(t);-1!==e&&n.splice(e,1)})}function kn(e,t){var n=ut(),r=e.changeListeners_;if(r){for(var o=0,i=(r=r.slice()).length;o<i;o++)r[o](t);dt(n)}}function Rn(e,t,n){return vr(function(){var r=er(e,n)[K];null!=t||(t=function(e){return P(e,W)||C(e,W,Q({},e[W])),e[W]}(e)),R(t).forEach(function(e){return r.make_(e,t[e])})}),e}var Mn="splice",Pn="update",Bn={get:function(e,t){var n=e[K];return t===K?n:"length"===t?n.getArrayLength_():"string"!=typeof t||isNaN(t)?P(On,t)?On[t]:e[t]:n.get_(parseInt(t))},set:function(e,t,n){var r=e[K];return"length"===t&&r.setArrayLength_(n),"symbol"==typeof t||isNaN(t)?e[t]=n:r.set_(parseInt(t),n),!0},preventExtensions:function(){r(15)}},_n=function(){function e(e,t,n,r){void 0===e&&(e="ObservableArray"),this.owned_=void 0,this.legacyMode_=void 0,this.atom_=void 0,this.values_=[],this.interceptors_=void 0,this.changeListeners_=void 0,this.enhancer_=void 0,this.dehancer=void 0,this.proxy_=void 0,this.lastKnownLength_=0,this.owned_=n,this.legacyMode_=r,this.atom_=new J(e),this.enhancer_=function(e,n){return t(e,n,"ObservableArray[..]")}}var t=e.prototype;return t.dehanceValue_=function(e){return void 0!==this.dehancer?this.dehancer(e):e},t.dehanceValues_=function(e){return void 0!==this.dehancer&&e.length>0?e.map(this.dehancer):e},t.intercept_=function(e){return Sn(this,e)},t.observe_=function(e,t){return void 0===t&&(t=!1),t&&e({observableKind:"array",object:this.proxy_,debugObjectName:this.atom_.name_,type:"splice",index:0,added:this.values_.slice(),addedCount:this.values_.length,removed:[],removedCount:0}),In(this,e)},t.getArrayLength_=function(){return this.atom_.reportObserved(),this.values_.length},t.setArrayLength_=function(e){("number"!=typeof e||isNaN(e)||e<0)&&r("Out of range: "+e);var t=this.values_.length;if(e!==t)if(e>t){for(var n=new Array(e-t),o=0;o<e-t;o++)n[o]=void 0;this.spliceWithArray_(t,0,n)}else this.spliceWithArray_(e,t-e)},t.updateArrayLength_=function(e,t){e!==this.lastKnownLength_&&r(16),this.lastKnownLength_+=t,this.legacyMode_&&t>0&&hr(e+t+1)},t.spliceWithArray_=function(e,t,n){var r=this;this.atom_;var o=this.values_.length;if(void 0===e?e=0:e>o?e=o:e<0&&(e=Math.max(0,o+e)),t=1===arguments.length?o-e:null==t?0:Math.max(0,Math.min(t,o-e)),void 0===n&&(n=u),Cn(this)){var i=xn(this,{object:this.proxy_,type:Mn,index:e,removedCount:t,added:n});if(!i)return u;t=i.removedCount,n=i.added}if(n=0===n.length?n:n.map(function(e){return r.enhancer_(e,void 0)}),this.legacyMode_){var a=n.length-t;this.updateArrayLength_(o,a)}var l=this.spliceItemsIntoValues_(e,t,n);return 0===t&&0===n.length||this.notifyArraySplice_(e,n,l),this.dehanceValues_(l)},t.spliceItemsIntoValues_=function(e,t,n){var r;if(n.length<1e4)return(r=this.values_).splice.apply(r,[e,t].concat(n));var o=this.values_.slice(e,e+t),i=this.values_.slice(e+t);this.values_.length+=n.length-t;for(var a=0;a<n.length;a++)this.values_[e+a]=n[a];for(var l=0;l<i.length;l++)this.values_[e+n.length+l]=i[l];return o},t.notifyArrayChildUpdate_=function(e,t,n){var r=!this.owned_&&!1,o=En(this),i=o||r?{observableKind:"array",object:this.proxy_,type:Pn,debugObjectName:this.atom_.name_,index:e,newValue:t,oldValue:n}:null;this.atom_.reportChanged(),o&&kn(this,i)},t.notifyArraySplice_=function(e,t,n){var r=!this.owned_&&!1,o=En(this),i=o||r?{observableKind:"array",object:this.proxy_,debugObjectName:this.atom_.name_,type:Mn,index:e,removed:n,added:t,removedCount:n.length,addedCount:t.length}:null;this.atom_.reportChanged(),o&&kn(this,i)},t.get_=function(e){if(!(this.legacyMode_&&e>=this.values_.length))return this.atom_.reportObserved(),this.dehanceValue_(this.values_[e]);console.warn("[mobx] Out of bounds read: "+e)},t.set_=function(e,t){var n=this.values_;if(this.legacyMode_&&e>n.length&&r(17,e,n.length),e<n.length){this.atom_;var o=n[e];if(Cn(this)){var i=xn(this,{type:Pn,object:this.proxy_,index:e,newValue:t});if(!i)return;t=i.newValue}(t=this.enhancer_(t,o))!==o&&(n[e]=t,this.notifyArrayChildUpdate_(e,t,o))}else{for(var a=new Array(e+1-n.length),l=0;l<a.length-1;l++)a[l]=void 0;a[a.length-1]=t,this.spliceWithArray_(n.length,0,a)}},e}();function Tn(e,t,n,r){return void 0===n&&(n="ObservableArray"),void 0===r&&(r=!1),h(),vr(function(){var o=new _n(n,t,r,!1);S(o.values_,K,o);var i=new Proxy(o.values_,Bn);return o.proxy_=i,e&&e.length&&o.spliceWithArray_(0,0,e),i})}var On={clear:function(){return this.splice(0)},replace:function(e){var t=this[K];return t.spliceWithArray_(0,t.values_.length,e)},toJSON:function(){return this.slice()},splice:function(e,t){for(var n=arguments.length,r=new Array(n>2?n-2:0),o=2;o<n;o++)r[o-2]=arguments[o];var i=this[K];switch(arguments.length){case 0:return[];case 1:return i.spliceWithArray_(e);case 2:return i.spliceWithArray_(e,t)}return i.spliceWithArray_(e,t,r)},spliceWithArray:function(e,t,n){return this[K].spliceWithArray_(e,t,n)},push:function(){for(var e=this[K],t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return e.spliceWithArray_(e.values_.length,0,n),e.values_.length},pop:function(){return this.splice(Math.max(this[K].values_.length-1,0),1)[0]},shift:function(){return this.splice(0,1)[0]},unshift:function(){for(var e=this[K],t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return e.spliceWithArray_(0,0,n),e.values_.length},reverse:function(){return bt.trackingDerivation&&r(37,"reverse"),this.replace(this.slice().reverse()),this},sort:function(){bt.trackingDerivation&&r(37,"sort");var e=this.slice();return e.sort.apply(e,arguments),this.replace(e),this},remove:function(e){var t=this[K],n=t.dehanceValues_(t.values_).indexOf(e);return n>-1&&(this.splice(n,1),!0)}};function Dn(e,t){"function"==typeof Array.prototype[e]&&(On[e]=t(e))}function Nn(e){return function(){var t=this[K];t.atom_.reportObserved();var n=t.dehanceValues_(t.values_);return n[e].apply(n,arguments)}}function Ln(e){return function(t,n){var r=this,o=this[K];return o.atom_.reportObserved(),o.dehanceValues_(o.values_)[e](function(e,o){return t.call(n,e,o,r)})}}function Fn(e){return function(){var t=this,n=this[K];n.atom_.reportObserved();var r=n.dehanceValues_(n.values_),o=arguments[0];return arguments[0]=function(e,n,r){return o(e,n,r,t)},r[e].apply(r,arguments)}}Dn("at",Nn),Dn("concat",Nn),Dn("flat",Nn),Dn("includes",Nn),Dn("indexOf",Nn),Dn("join",Nn),Dn("lastIndexOf",Nn),Dn("slice",Nn),Dn("toString",Nn),Dn("toLocaleString",Nn),Dn("toSorted",Nn),Dn("toSpliced",Nn),Dn("with",Nn),Dn("every",Ln),Dn("filter",Ln),Dn("find",Ln),Dn("findIndex",Ln),Dn("findLast",Ln),Dn("findLastIndex",Ln),Dn("flatMap",Ln),Dn("forEach",Ln),Dn("map",Ln),Dn("some",Ln),Dn("toReversed",Ln),Dn("reduce",Fn),Dn("reduceRight",Fn);var Qn=x("ObservableArrayAdministration",_n);function jn(e){return v(e)&&Qn(e[K])}var zn={},$n="add",Hn="delete",Gn=function(){function e(e,t,n){var o=this;void 0===t&&(t=te),void 0===n&&(n="ObservableMap"),this.enhancer_=void 0,this.name_=void 0,this[K]=zn,this.data_=void 0,this.hasMap_=void 0,this.keysAtom_=void 0,this.interceptors_=void 0,this.changeListeners_=void 0,this.dehancer=void 0,this.enhancer_=t,this.name_=n,A(Map)||r(18),vr(function(){o.keysAtom_=Z("ObservableMap.keys()"),o.data_=new Map,o.hasMap_=new Map,e&&o.merge(e)})}var t=e.prototype;return t.has_=function(e){return this.data_.has(e)},t.has=function(e){var t=this;if(!bt.trackingDerivation)return this.has_(e);var n=this.hasMap_.get(e);if(!n){var r=n=new Xe(this.has_(e),ne,"ObservableMap.key?",!1);this.hasMap_.set(e,r),qt(r,function(){return t.hasMap_.delete(e)})}return n.get()},t.set=function(e,t){var n=this.has_(e);if(Cn(this)){var r=xn(this,{type:n?Pn:$n,object:this,newValue:t,name:e});if(!r)return this;t=r.newValue}return n?this.updateValue_(e,t):this.addValue_(e,t),this},t.delete=function(e){var t=this;if(this.keysAtom_,Cn(this)&&!xn(this,{type:Hn,object:this,name:e}))return!1;if(this.has_(e)){var n=En(this),r=n?{observableKind:"map",debugObjectName:this.name_,type:Hn,object:this,oldValue:this.data_.get(e).value_,name:e}:null;return An(function(){var n;t.keysAtom_.reportChanged(),null==(n=t.hasMap_.get(e))||n.setNewValue_(!1),t.data_.get(e).setNewValue_(void 0),t.data_.delete(e)}),n&&kn(this,r),!0}return!1},t.updateValue_=function(e,t){var n=this.data_.get(e);if((t=n.prepareNewValue_(t))!==bt.UNCHANGED){var r=En(this),o=r?{observableKind:"map",debugObjectName:this.name_,type:Pn,object:this,oldValue:n.value_,name:e,newValue:t}:null;n.setNewValue_(t),r&&kn(this,o)}},t.addValue_=function(e,t){var n=this;this.keysAtom_,An(function(){var r,o=new Xe(t,n.enhancer_,"ObservableMap.key",!1);n.data_.set(e,o),t=o.value_,null==(r=n.hasMap_.get(e))||r.setNewValue_(!0),n.keysAtom_.reportChanged()});var r=En(this),o=r?{observableKind:"map",debugObjectName:this.name_,type:$n,object:this,name:e,newValue:t}:null;r&&kn(this,o)},t.get=function(e){return this.has(e)?this.dehanceValue_(this.data_.get(e).get()):this.dehanceValue_(void 0)},t.getOrInsert=function(e,t){return this.has(e)||this.set(e,t),this.get(e)},t.getOrInsertComputed=function(e,t){return this.has(e)||this.set(e,t(e)),this.get(e)},t.dehanceValue_=function(e){return void 0!==this.dehancer?this.dehancer(e):e},t.keys=function(){return this.keysAtom_.reportObserved(),this.data_.keys()},t.values=function(){var e=this,t=this.keys();return Wn({next:function(){var n=t.next(),r=n.done,o=n.value;return{done:r,value:r?void 0:e.get(o)}}})},t.entries=function(){var e=this,t=this.keys();return Wn({next:function(){var n=t.next(),r=n.done,o=n.value;return{done:r,value:r?void 0:[o,e.get(o)]}}})},t[Symbol.iterator]=function(){return this.entries()},t.forEach=function(e,t){for(var n,r=F(this);!(n=r()).done;){var o=n.value,i=o[0],a=o[1];e.call(t,a,i,this)}},t.merge=function(e){var t=this;return Vn(e)&&(e=new Map(e)),An(function(){var n,o,i;y(e)?function(e){var t=Object.keys(e);if(!k)return t;var n=Object.getOwnPropertySymbols(e);return n.length?[].concat(t,n.filter(function(t){return c.propertyIsEnumerable.call(e,t)})):t}(e).forEach(function(n){return t.set(n,e[n])}):Array.isArray(e)?e.forEach(function(e){var n=e[0],r=e[1];return t.set(n,r)}):E(e)?(n=e,o=Object.getPrototypeOf(n),i=Object.getPrototypeOf(o),null!==Object.getPrototypeOf(i)&&r(19,e),e.forEach(function(e,n){return t.set(n,e)})):null!=e&&r(20,e)}),this},t.clear=function(){var e=this;An(function(){ct(function(){for(var t,n=F(e.keys());!(t=n()).done;){var r=t.value;e.delete(r)}})})},t.replace=function(e){var t=this;return An(function(){for(var n,o=function(e){if(E(e)||Vn(e))return e;if(Array.isArray(e))return new Map(e);if(y(e)){var t=new Map;for(var n in e)t.set(n,e[n]);return t}return r(21,e)}(e),i=new Map,a=!1,l=F(t.data_.keys());!(n=l()).done;){var s=n.value;if(!o.has(s))if(t.delete(s))a=!0;else{var c=t.data_.get(s);i.set(s,c)}}for(var u,d=F(o.entries());!(u=d()).done;){var f=u.value,p=f[0],h=f[1],g=t.data_.has(p);if(t.set(p,h),t.data_.has(p)){var m=t.data_.get(p);i.set(p,m),g||(a=!0)}}if(!a)if(t.data_.size!==i.size)t.keysAtom_.reportChanged();else for(var A=t.data_.keys(),b=i.keys(),v=A.next(),w=b.next();!v.done;){if(v.value!==w.value){t.keysAtom_.reportChanged();break}v=A.next(),w=b.next()}t.data_=i}),this},t.toString=function(){return"[object ObservableMap]"},t.toJSON=function(){return Array.from(this)},t.observe_=function(e,t){return In(this,e)},t.intercept_=function(e){return Sn(this,e)},L(e,[{key:"size",get:function(){return this.keysAtom_.reportObserved(),this.data_.size}},{key:Symbol.toStringTag,get:function(){return"Map"}}])}(),Vn=x("ObservableMap",Gn);function Wn(e){return e[Symbol.toStringTag]="MapIterator",Ir(e)}var Un={},qn=function(){function e(e,t,n){var o=this;void 0===t&&(t=te),void 0===n&&(n="ObservableSet"),this.name_=void 0,this[K]=Un,this.data_=new Set,this.atom_=void 0,this.changeListeners_=void 0,this.interceptors_=void 0,this.dehancer=void 0,this.enhancer_=void 0,this.name_=n,A(Set)||r(22),this.enhancer_=function(e,r){return t(e,r,n)},vr(function(){o.atom_=Z(o.name_),e&&o.replace(e)})}var t=e.prototype;return t.dehanceValue_=function(e){return void 0!==this.dehancer?this.dehancer(e):e},t.clear=function(){var e=this;An(function(){ct(function(){for(var t,n=F(e.data_.values());!(t=n()).done;){var r=t.value;e.delete(r)}})})},t.forEach=function(e,t){for(var n,r=F(this);!(n=r()).done;){var o=n.value;e.call(t,o,o,this)}},t.add=function(e){var t=this;if(this.atom_,Cn(this)){var n=xn(this,{type:$n,object:this,newValue:e});if(!n)return this;e=n.newValue}if(!this.has(e)){An(function(){t.data_.add(t.enhancer_(e,void 0)),t.atom_.reportChanged()});var r=En(this),o=r?{observableKind:"set",debugObjectName:this.name_,type:$n,object:this,newValue:e}:null;r&&kn(this,o)}return this},t.delete=function(e){var t=this;if(Cn(this)&&!xn(this,{type:Hn,object:this,oldValue:e}))return!1;if(this.has(e)){var n=En(this),r=n?{observableKind:"set",debugObjectName:this.name_,type:Hn,object:this,oldValue:e}:null;return An(function(){t.atom_.reportChanged(),t.data_.delete(e)}),n&&kn(this,r),!0}return!1},t.has=function(e){return this.atom_.reportObserved(),this.data_.has(this.dehanceValue_(e))},t.entries=function(){var e=this.values();return Kn({next:function(){var t=e.next(),n=t.value,r=t.done;return r?{value:void 0,done:r}:{value:[n,n],done:r}}})},t.keys=function(){return this.values()},t.values=function(){this.atom_.reportObserved();var e=this,t=this.data_.values();return Kn({next:function(){var n=t.next(),r=n.value,o=n.done;return o?{value:void 0,done:o}:{value:e.dehanceValue_(r),done:o}}})},t.intersection=function(e){return I(e)&&!Yn(e)?e.intersection(this):new Set(this).intersection(e)},t.union=function(e){return I(e)&&!Yn(e)?e.union(this):new Set(this).union(e)},t.difference=function(e){return new Set(this).difference(e)},t.symmetricDifference=function(e){return I(e)&&!Yn(e)?e.symmetricDifference(this):new Set(this).symmetricDifference(e)},t.isSubsetOf=function(e){return new Set(this).isSubsetOf(e)},t.isSupersetOf=function(e){return new Set(this).isSupersetOf(e)},t.isDisjointFrom=function(e){return I(e)&&!Yn(e)?e.isDisjointFrom(this):new Set(this).isDisjointFrom(e)},t.replace=function(e){var t=this;return Yn(e)&&(e=new Set(e)),An(function(){Array.isArray(e)||I(e)?(t.clear(),e.forEach(function(e){return t.add(e)})):null!=e&&r("Cannot initialize set from "+e)}),this},t.observe_=function(e,t){return In(this,e)},t.intercept_=function(e){return Sn(this,e)},t.toJSON=function(){return Array.from(this)},t.toString=function(){return"[object ObservableSet]"},t[Symbol.iterator]=function(){return this.values()},L(e,[{key:"size",get:function(){return this.atom_.reportObserved(),this.data_.size}},{key:Symbol.toStringTag,get:function(){return"Set"}}])}(),Yn=x("ObservableSet",qn);function Kn(e){return e[Symbol.toStringTag]="SetIterator",Ir(e)}var Jn=Object.create(null),Xn="remove",Zn=function(){function e(e,t,n,r){void 0===t&&(t=new Map),void 0===r&&(r=Ce),this.target_=void 0,this.values_=void 0,this.name_=void 0,this.defaultAnnotation_=void 0,this.keysAtom_=void 0,this.changeListeners_=void 0,this.interceptors_=void 0,this.proxy_=void 0,this.isPlainObject_=void 0,this.appliedAnnotations_=void 0,this.pendingKeys_=void 0,this.lazyComputedKeys_=void 0,this.lazyObservableKeys_=void 0,this.target_=e,this.values_=t,this.name_=n,this.defaultAnnotation_=r,this.keysAtom_=new J("ObservableObject.keys"),this.isPlainObject_=y(this.target_)}var t=e.prototype;return t.getObservablePropValue_=function(e){var t,n;return(null!=(t=null!=(n=this.values_.get(e))?n:this.materializeLazyComputed_(e))?t:this.materializeLazyObservable_(e)).get()},t.materializeLazyComputed_=function(e){var t,n=null==(t=this.lazyComputedKeys_)?void 0:t.get(e);if(n){this.lazyComputedKeys_.delete(e),0===this.lazyComputedKeys_.size&&(this.lazyComputedKeys_=void 0);var r=n();return this.values_.set(e,r),r}},t.materializeLazyObservable_=function(e){var t,n=null==(t=this.lazyObservableKeys_)?void 0:t.get(e);if(n){this.lazyObservableKeys_.delete(e),0===this.lazyObservableKeys_.size&&(this.lazyObservableKeys_=void 0);var r=n();return this.values_.set(e,r),r}},t.setObservablePropValue_=function(e,t){var n,r,o=null!=(n=null!=(r=this.values_.get(e))?r:this.materializeLazyComputed_(e))?n:this.materializeLazyObservable_(e);if(o instanceof et)return o.set(t),!0;if(Cn(this)){var i=xn(this,{type:Pn,object:this.proxy_||this.target_,name:e,newValue:t});if(!i)return null;t=i.newValue}if((t=o.prepareNewValue_(t))!==bt.UNCHANGED){var a=En(this),l=a?{type:Pn,observableKind:"object",debugObjectName:this.name_,object:this.proxy_||this.target_,oldValue:o.value_,name:e,newValue:t}:null;o.setNewValue_(t),a&&kn(this,l)}return!0},t.get_=function(e){return bt.trackingDerivation&&!P(this.target_,e)&&this.has_(e),this.target_[e]},t.set_=function(e,t,n){return void 0===n&&(n=!1),P(this.target_,e)?this.values_.has(e)?this.setObservablePropValue_(e,t):n?Reflect.set(this.target_,e,t):(this.target_[e]=t,!0):this.extend_(e,{value:t,enumerable:!0,writable:!0,configurable:!0},this.defaultAnnotation_,n)},t.has_=function(e){if(!bt.trackingDerivation)return e in this.target_;this.pendingKeys_||(this.pendingKeys_=new Map);var t=this.pendingKeys_.get(e);return t||(t=new Xe(e in this.target_,ne,"ObservableObject.key?",!1),this.pendingKeys_.set(e,t)),t.get()},t.make_=function(e,t){if(!0===t&&(t=this.defaultAnnotation_),!1!==t){if(!(e in this.target_)){var n;if(null!=(n=this.target_[W])&&n[e])return;r(1,t.annotationType_,this.name_+"."+e.toString())}for(var o=this.target_;o&&o!==c;){var i=l(o,e);if(i){var a=t.make_(this,e,i,o);if(0===a)return;if(1===a)break}o=Object.getPrototypeOf(o)}or(this,0,e)}},t.extend_=function(e,t,n,r){if(void 0===r&&(r=!1),!0===n&&(n=this.defaultAnnotation_),!1===n)return this.defineProperty_(e,t,r);var o=n.extend_(this,e,t,r);return o&&or(this,0,e),o},t.defineProperty_=function(e,t,n){void 0===n&&(n=!1),this.keysAtom_;try{St();var r=this.delete_(e);if(!r)return r;if(Cn(this)){var o=xn(this,{object:this.proxy_||this.target_,name:e,type:$n,newValue:t.value});if(!o)return null;var i=o.newValue;t.value!==i&&(t=Q({},t,{value:i}))}if(n){if(!Reflect.defineProperty(this.target_,e,t))return!1}else s(this.target_,e,t);this.notifyPropertyAddition_(e,t.value)}finally{xt()}return!0},t.defineObservableProperty_=function(e,t,n,r){void 0===r&&(r=!1),this.keysAtom_;try{St();var o=this.delete_(e);if(!o)return o;if(Cn(this)){var i=xn(this,{object:this.proxy_||this.target_,name:e,type:$n,newValue:t});if(!i)return null;t=i.newValue}var a=nr(e),l={configurable:!bt.safeDescriptors||this.isPlainObject_,enumerable:!0,get:a.get,set:a.set};if(r){if(!Reflect.defineProperty(this.target_,e,l))return!1}else s(this.target_,e,l);var c=new Xe(t,n,"ObservableObject.key",!1);this.values_.set(e,c),this.notifyPropertyAddition_(e,c.value_)}finally{xt()}return!0},t.defineComputedProperty_=function(e,t,n){void 0===n&&(n=!1),this.keysAtom_;try{St();var r=this.delete_(e);if(!r)return r;if(Cn(this)&&!xn(this,{object:this.proxy_||this.target_,name:e,type:$n,newValue:void 0}))return null;t.name||(t.name="ObservableObject.key"),t.context=this.proxy_||this.target_;var o=nr(e),i={configurable:!bt.safeDescriptors||this.isPlainObject_,enumerable:!1,get:o.get,set:o.set};if(n){if(!Reflect.defineProperty(this.target_,e,i))return!1}else s(this.target_,e,i);this.values_.set(e,new et(t)),this.notifyPropertyAddition_(e,void 0)}finally{xt()}return!0},t.delete_=function(e,t){if(void 0===t&&(t=!1),this.keysAtom_,!P(this.target_,e))return!0;if(Cn(this)&&!xn(this,{object:this.proxy_||this.target_,name:e,type:Xn}))return null;try{var n;St();var r,o=En(this),i=this.values_.get(e),a=void 0;if(!i&&o&&(a=null==(r=l(this.target_,e))?void 0:r.value),t){if(!Reflect.deleteProperty(this.target_,e))return!1}else delete this.target_[e];if(i&&(this.values_.delete(e),i instanceof Xe&&(a=i.value_),It(i)),this.keysAtom_.reportChanged(),null==(n=this.pendingKeys_)||null==(n=n.get(e))||n.set(e in this.target_),o){var s={type:Xn,observableKind:"object",object:this.proxy_||this.target_,debugObjectName:this.name_,oldValue:a,name:e};o&&kn(this,s)}}finally{xt()}return!0},t.observe_=function(e,t){return In(this,e)},t.intercept_=function(e){return Sn(this,e)},t.notifyPropertyAddition_=function(e,t){var n,r=En(this);if(r){var o=r?{type:$n,observableKind:"object",debugObjectName:this.name_,object:this.proxy_||this.target_,name:e,newValue:t}:null;r&&kn(this,o)}null==(n=this.pendingKeys_)||null==(n=n.get(e))||n.set(!0),this.keysAtom_.reportChanged()},t.ownKeys_=function(){return this.keysAtom_.reportObserved(),R(this.target_)},t.keys_=function(){return this.keysAtom_.reportObserved(),Object.keys(this.target_)},e}();function er(e,t){var n;if(P(e,K))return e;var r=null!=(n=null==t?void 0:t.name)?n:"ObservableObject",o=new Zn(e,new Map,String(r),function(e){var t;return e?null!=(t=e.defaultDecorator)?t:Se(e):void 0}(t));return C(e,K,o),e}var tr=x("ObservableObjectAdministration",Zn);function nr(e){return Jn[e]||(Jn[e]={get:function(){return this[K].getObservablePropValue_(e)},set:function(t){return this[K].setObservablePropValue_(e,t)}})}function rr(e){return!!v(e)&&tr(e[K])}function or(e,t,n){var r;null==(r=e.target_[W])||delete r[n]}var ir,ar,lr=fr(0),sr=function(){var e=!1,t={};return Object.defineProperty(t,"0",{set:function(){e=!0}}),Object.create(t)[0]=1,!1===e}(),cr=0,ur=function(){};ir=ur,ar=Array.prototype,Object.setPrototypeOf?Object.setPrototypeOf(ir.prototype,ar):void 0!==ir.prototype.__proto__?ir.prototype.__proto__=ar:ir.prototype=ar;var dr=function(e){function t(t,n,r,o){var i;return void 0===r&&(r="ObservableArray"),void 0===o&&(o=!1),i=e.call(this)||this,vr(function(){var e=new _n(r,n,o,!0);e.proxy_=i,S(i,K,e),t&&t.length&&i.spliceWithArray(0,0,t),sr&&Object.defineProperty(i,"0",lr)}),i}z(t,e);var n=t.prototype;return n.concat=function(){this[K].atom_.reportObserved();for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return Array.prototype.concat.apply(this.slice(),t.map(function(e){return jn(e)?e.slice():e}))},n[Symbol.iterator]=function(){var e=this,t=0;return Ir({next:function(){return t<e.length?{value:e[t++],done:!1}:{done:!0,value:void 0}}})},L(t,[{key:"length",get:function(){return this[K].getArrayLength_()},set:function(e){this[K].setArrayLength_(e)}},{key:Symbol.toStringTag,get:function(){return"Array"}}])}(ur);function fr(e){return{enumerable:!1,configurable:!0,get:function(){return this[K].get_(e)},set:function(t){this[K].set_(e,t)}}}function pr(e){s(dr.prototype,""+e,fr(e))}function hr(e){if(e>cr){for(var t=cr;t<e+100;t++)pr(t);cr=e}}function gr(e,t,n){return new dr(e,t,n)}function mr(e,t){if("object"==typeof e&&null!==e){if(jn(e))return void 0!==t&&r(23),e[K].atom_;if(Yn(e))return e.atom_;if(Vn(e)){if(void 0===t)return e.keysAtom_;var n=e.data_.get(t)||e.hasMap_.get(t);return n||r(25,t,br(e)),n}if(rr(e)){var o,i;if(!t)return r(26);var a=e[K],l=null!=(o=null!=(i=a.values_.get(t))?i:a.materializeLazyComputed_(t))?o:a.materializeLazyObservable_(t);return l||r(27,t,br(e)),l}if(X(e)||rt(e)||Bt(e))return e}else if(A(e)&&Bt(e[K]))return e[K];r(28)}function Ar(e,t){return e||r(29),void 0!==t?Ar(mr(e,t)):X(e)||rt(e)||Bt(e)||Vn(e)||Yn(e)?e:e[K]?e[K]:void r(24,e)}function br(e,t){var n;if(void 0!==t)n=mr(e,t);else{if($t(e))return e.name;n=rr(e)||Vn(e)||Yn(e)?Ar(e):mr(e)}return n.name_}function vr(e){var t=ut(),n=Ke(!0);St();try{return e()}finally{xt(),Je(n),dt(t)}}Object.entries(On).forEach(function(e){var t=e[0],n=e[1];"concat"!==t&&C(dr.prototype,t,n)}),hr(1e3);var yr,wr=c.toString;function Cr(e,t,n){return void 0===n&&(n=-1),Sr(e,t,n)}function Sr(e,t,n,r,o){if(e===t)return 0!==e||1/e==1/t;if(null==e||null==t)return!1;if(e!=e)return t!=t;var i=typeof e;if("function"!==i&&"object"!==i&&"object"!=typeof t)return!1;var a=wr.call(e);if(a!==wr.call(t))return!1;switch(a){case"[object RegExp]":case"[object String]":return""+e==""+t;case"[object Number]":return+e!=+e?+t!=+t:0===+e?1/+e==1/t:+e===+t;case"[object Date]":case"[object Boolean]":return+e===+t;case"[object Symbol]":return"undefined"!=typeof Symbol&&Symbol.valueOf.call(e)===Symbol.valueOf.call(t);case"[object Map]":case"[object Set]":n>=0&&n++}e=xr(e),t=xr(t);var l="[object Array]"===a;if(!l){if("object"!=typeof e||"object"!=typeof t)return!1;var s=e.constructor,c=t.constructor;if(s!==c&&!(A(s)&&s instanceof s&&A(c)&&c instanceof c)&&"constructor"in e&&"constructor"in t)return!1}if(0===n)return!1;n<0&&(n=-1),o=o||[];for(var u=(r=r||[]).length;u--;)if(r[u]===e)return o[u]===t;if(r.push(e),o.push(t),l){if((u=e.length)!==t.length)return!1;for(;u--;)if(!Sr(e[u],t[u],n-1,r,o))return!1}else{var d=Object.keys(e),f=d.length;if(Object.keys(t).length!==f)return!1;for(var p=0;p<f;p++){var h=d[p];if(!P(t,h)||!Sr(e[h],t[h],n-1,r,o))return!1}}return r.pop(),o.pop(),!0}function xr(e){return jn(e)?e.slice():E(e)||Vn(e)||I(e)||Yn(e)?Array.from(e.entries()):e}var Er=(null==(yr=i().Iterator)?void 0:yr.prototype)||{};function Ir(e){return e[Symbol.iterator]=kr,Object.assign(Object.create(Er),e)}function kr(){return this}["Symbol","Map","Set"].forEach(function(e){void 0===i()[e]&&r("MobX requires global '"+e+"' to be available or polyfilled")}),"object"==typeof __MOBX_DEVTOOLS_GLOBAL_HOOK__&&__MOBX_DEVTOOLS_GLOBAL_HOOK__.injectMobx({spy:function(e){return console.warn("[mobx.spy] Is a no-op in production builds"),function(){}},extras:{getDebugName:br},$mobx:K})},7265(e,t,n){"use strict";var r=n(3034);function o(){}function i(){}i.resetWarningCache=o,e.exports=function(){function e(e,t,n,o,i,a){if(a!==r){var l=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw l.name="Invariant Violation",l}}function t(){return e}e.isRequired=e;var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:i,resetWarningCache:o};return n.PropTypes=n,n}},5821(e,t,n){e.exports=n(7265)()},3034(e){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},4482(e,t,n){"use strict";var r=n(3480),o=n(405),i=n(7868);function a(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n])}return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function l(e){return!(!e||1!==e.nodeType&&9!==e.nodeType&&11!==e.nodeType)}function s(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do{!!(4098&(t=e).flags)&&(n=t.return),e=t.return}while(e)}return 3===t.tag?n:null}function c(e){if(13===e.tag){var t=e.memoizedState;if(null===t&&null!==(e=e.alternate)&&(t=e.memoizedState),null!==t)return t.dehydrated}return null}function u(e){if(31===e.tag){var t=e.memoizedState;if(null===t&&null!==(e=e.alternate)&&(t=e.memoizedState),null!==t)return t.dehydrated}return null}function d(e){if(s(e)!==e)throw Error(a(188))}function f(e){var t=e.tag;if(5===t||26===t||27===t||6===t)return e;for(e=e.child;null!==e;){if(null!==(t=f(e)))return t;e=e.sibling}return null}var p=Object.assign,h=Symbol.for("react.element"),g=Symbol.for("react.transitional.element"),m=Symbol.for("react.portal"),A=Symbol.for("react.fragment"),b=Symbol.for("react.strict_mode"),v=Symbol.for("react.profiler"),y=Symbol.for("react.consumer"),w=Symbol.for("react.context"),C=Symbol.for("react.forward_ref"),S=Symbol.for("react.suspense"),x=Symbol.for("react.suspense_list"),E=Symbol.for("react.memo"),I=Symbol.for("react.lazy");Symbol.for("react.scope");var k=Symbol.for("react.activity");Symbol.for("react.legacy_hidden"),Symbol.for("react.tracing_marker");var R=Symbol.for("react.memo_cache_sentinel");Symbol.for("react.view_transition");var M=Symbol.iterator;function P(e){return null===e||"object"!=typeof e?null:"function"==typeof(e=M&&e[M]||e["@@iterator"])?e:null}var B=Symbol.for("react.client.reference");function _(e){if(null==e)return null;if("function"==typeof e)return e.$$typeof===B?null:e.displayName||e.name||null;if("string"==typeof e)return e;switch(e){case A:return"Fragment";case v:return"Profiler";case b:return"StrictMode";case S:return"Suspense";case x:return"SuspenseList";case k:return"Activity"}if("object"==typeof e)switch(e.$$typeof){case m:return"Portal";case w:return e.displayName||"Context";case y:return(e._context.displayName||"Context")+".Consumer";case C:var t=e.render;return(e=e.displayName)||(e=""!==(e=t.displayName||t.name||"")?"ForwardRef("+e+")":"ForwardRef"),e;case E:return null!==(t=e.displayName||null)?t:_(e.type)||"Memo";case I:t=e._payload,e=e._init;try{return _(e(t))}catch(e){}}return null}var T=Array.isArray,O=o.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,D=i.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,N={pending:!1,data:null,method:null,action:null},L=[],F=-1;function Q(e){return{current:e}}function j(e){0>F||(e.current=L[F],L[F]=null,F--)}function z(e,t){F++,L[F]=e.current,e.current=t}var $,H,G=Q(null),V=Q(null),W=Q(null),U=Q(null);function q(e,t){switch(z(W,t),z(V,e),z(G,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Ad(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)e=bd(t=Ad(t),e);else switch(e){case"svg":e=1;break;case"math":e=2;break;default:e=0}}j(G),z(G,e)}function Y(){j(G),j(V),j(W)}function K(e){null!==e.memoizedState&&z(U,e);var t=G.current,n=bd(t,e.type);t!==n&&(z(V,e),z(G,n))}function J(e){V.current===e&&(j(G),j(V)),U.current===e&&(j(U),df._currentValue=N)}function X(e){if(void 0===$)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);$=t&&t[1]||"",H=-1<e.stack.indexOf("\n at")?" (<anonymous>)":-1<e.stack.indexOf("@")?"@unknown:0:0":""}return"\n"+$+e+H}var Z=!1;function ee(e,t){if(!e||Z)return"";Z=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var r={DetermineComponentFrameRoot:function(){try{if(t){var n=function(){throw Error()};if(Object.defineProperty(n.prototype,"props",{set:function(){throw Error()}}),"object"==typeof Reflect&&Reflect.construct){try{Reflect.construct(n,[])}catch(e){var r=e}Reflect.construct(e,[],n)}else{try{n.call()}catch(e){r=e}e.call(n.prototype)}}else{try{throw Error()}catch(e){r=e}(n=e())&&"function"==typeof n.catch&&n.catch(function(){})}}catch(e){if(e&&r&&"string"==typeof e.stack)return[e.stack,r.stack]}return[null,null]}};r.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var o=Object.getOwnPropertyDescriptor(r.DetermineComponentFrameRoot,"name");o&&o.configurable&&Object.defineProperty(r.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var i=r.DetermineComponentFrameRoot(),a=i[0],l=i[1];if(a&&l){var s=a.split("\n"),c=l.split("\n");for(o=r=0;r<s.length&&!s[r].includes("DetermineComponentFrameRoot");)r++;for(;o<c.length&&!c[o].includes("DetermineComponentFrameRoot");)o++;if(r===s.length||o===c.length)for(r=s.length-1,o=c.length-1;1<=r&&0<=o&&s[r]!==c[o];)o--;for(;1<=r&&0<=o;r--,o--)if(s[r]!==c[o]){if(1!==r||1!==o)do{if(r--,0>--o||s[r]!==c[o]){var u="\n"+s[r].replace(" at new "," at ");return e.displayName&&u.includes("<anonymous>")&&(u=u.replace("<anonymous>",e.displayName)),u}}while(1<=r&&0<=o);break}}}finally{Z=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:"")?X(n):""}function te(e,t){switch(e.tag){case 26:case 27:case 5:return X(e.type);case 16:return X("Lazy");case 13:return e.child!==t&&null!==t?X("Suspense Fallback"):X("Suspense");case 19:return X("SuspenseList");case 0:case 15:return ee(e.type,!1);case 11:return ee(e.type.render,!1);case 1:return ee(e.type,!0);case 31:return X("Activity");default:return""}}function ne(e){try{var t="",n=null;do{t+=te(e,n),n=e,e=e.return}while(e);return t}catch(e){return"\nError generating stack: "+e.message+"\n"+e.stack}}var re=Object.prototype.hasOwnProperty,oe=r.unstable_scheduleCallback,ie=r.unstable_cancelCallback,ae=r.unstable_shouldYield,le=r.unstable_requestPaint,se=r.unstable_now,ce=r.unstable_getCurrentPriorityLevel,ue=r.unstable_ImmediatePriority,de=r.unstable_UserBlockingPriority,fe=r.unstable_NormalPriority,pe=r.unstable_LowPriority,he=r.unstable_IdlePriority,ge=r.log,me=r.unstable_setDisableYieldValue,Ae=null,be=null;function ve(e){if("function"==typeof ge&&me(e),be&&"function"==typeof be.setStrictMode)try{be.setStrictMode(Ae,e)}catch(e){}}var ye=Math.clz32?Math.clz32:function(e){return 0==(e>>>=0)?32:31-(we(e)/Ce|0)|0},we=Math.log,Ce=Math.LN2,Se=256,xe=262144,Ee=4194304;function Ie(e){var t=42&e;if(0!==t)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return 261888&e;case 262144:case 524288:case 1048576:case 2097152:return 3932160&e;case 4194304:case 8388608:case 16777216:case 33554432:return 62914560&e;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function ke(e,t,n){var r=e.pendingLanes;if(0===r)return 0;var o=0,i=e.suspendedLanes,a=e.pingedLanes;e=e.warmLanes;var l=134217727&r;return 0!==l?0!==(r=l&~i)?o=Ie(r):0!==(a&=l)?o=Ie(a):n||0!==(n=l&~e)&&(o=Ie(n)):0!==(l=r&~i)?o=Ie(l):0!==a?o=Ie(a):n||0!==(n=r&~e)&&(o=Ie(n)),0===o?0:0!==t&&t!==o&&0===(t&i)&&((i=o&-o)>=(n=t&-t)||32===i&&4194048&n)?t:o}function Re(e,t){return 0===(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)}function Me(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;default:return-1}}function Pe(){var e=Ee;return!(62914560&(Ee<<=1))&&(Ee=4194304),e}function Be(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function _e(e,t){e.pendingLanes|=t,268435456!==t&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function Te(e,t,n){e.pendingLanes|=t,e.suspendedLanes&=~t;var r=31-ye(t);e.entangledLanes|=t,e.entanglements[r]=1073741824|e.entanglements[r]|261930&n}function Oe(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-ye(n),o=1<<r;o&t|e[r]&t&&(e[r]|=t),n&=~o}}function De(e,t){var n=t&-t;return 0!==((n=42&n?1:Ne(n))&(e.suspendedLanes|t))?0:n}function Ne(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function Le(e){return 2<(e&=-e)?8<e?134217727&e?32:268435456:8:2}function Fe(){var e=D.p;return 0!==e?e:void 0===(e=window.event)?32:kf(e.type)}function Qe(e,t){var n=D.p;try{return D.p=e,t()}finally{D.p=n}}var je=Math.random().toString(36).slice(2),ze="__reactFiber$"+je,$e="__reactProps$"+je,He="__reactContainer$"+je,Ge="__reactEvents$"+je,Ve="__reactListeners$"+je,We="__reactHandles$"+je,Ue="__reactResources$"+je,qe="__reactMarker$"+je;function Ye(e){delete e[ze],delete e[$e],delete e[Ge],delete e[Ve],delete e[We]}function Ke(e){var t=e[ze];if(t)return t;for(var n=e.parentNode;n;){if(t=n[He]||n[ze]){if(n=t.alternate,null!==t.child||null!==n&&null!==n.child)for(e=Nd(e);null!==e;){if(n=e[ze])return n;e=Nd(e)}return t}n=(e=n).parentNode}return null}function Je(e){if(e=e[ze]||e[He]){var t=e.tag;if(5===t||6===t||13===t||31===t||26===t||27===t||3===t)return e}return null}function Xe(e){var t=e.tag;if(5===t||26===t||27===t||6===t)return e.stateNode;throw Error(a(33))}function Ze(e){var t=e[Ue];return t||(t=e[Ue]={hoistableStyles:new Map,hoistableScripts:new Map}),t}function et(e){e[qe]=!0}var tt=new Set,nt={};function rt(e,t){ot(e,t),ot(e+"Capture",t)}function ot(e,t){for(nt[e]=t,e=0;e<t.length;e++)tt.add(t[e])}var it=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),at={},lt={};function st(e,t,n){if(o=t,re.call(lt,o)||!re.call(at,o)&&(it.test(o)?lt[o]=!0:(at[o]=!0,0)))if(null===n)e.removeAttribute(t);else{switch(typeof n){case"undefined":case"function":case"symbol":return void e.removeAttribute(t);case"boolean":var r=t.toLowerCase().slice(0,5);if("data-"!==r&&"aria-"!==r)return void e.removeAttribute(t)}e.setAttribute(t,""+n)}var o}function ct(e,t,n){if(null===n)e.removeAttribute(t);else{switch(typeof n){case"undefined":case"function":case"symbol":case"boolean":return void e.removeAttribute(t)}e.setAttribute(t,""+n)}}function ut(e,t,n,r){if(null===r)e.removeAttribute(n);else{switch(typeof r){case"undefined":case"function":case"symbol":case"boolean":return void e.removeAttribute(n)}e.setAttributeNS(t,n,""+r)}}function dt(e){switch(typeof e){case"bigint":case"boolean":case"number":case"string":case"undefined":case"object":return e;default:return""}}function ft(e){var t=e.type;return(e=e.nodeName)&&"input"===e.toLowerCase()&&("checkbox"===t||"radio"===t)}function pt(e){if(!e._valueTracker){var t=ft(e)?"checked":"value";e._valueTracker=function(e,t,n){var r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t);if(!e.hasOwnProperty(t)&&void 0!==r&&"function"==typeof r.get&&"function"==typeof r.set){var o=r.get,i=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return o.call(this)},set:function(e){n=""+e,i.call(this,e)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(e){n=""+e},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}(e,t,""+e[t])}}function ht(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=ft(e)?e.checked?"true":"false":e.value),(e=r)!==n&&(t.setValue(e),!0)}function gt(e){if(void 0===(e=e||("undefined"!=typeof document?document:void 0)))return null;try{return e.activeElement||e.body}catch(t){return e.body}}var mt=/[\n"\\]/g;function At(e){return e.replace(mt,function(e){return"\\"+e.charCodeAt(0).toString(16)+" "})}function bt(e,t,n,r,o,i,a,l){e.name="",null!=a&&"function"!=typeof a&&"symbol"!=typeof a&&"boolean"!=typeof a?e.type=a:e.removeAttribute("type"),null!=t?"number"===a?(0===t&&""===e.value||e.value!=t)&&(e.value=""+dt(t)):e.value!==""+dt(t)&&(e.value=""+dt(t)):"submit"!==a&&"reset"!==a||e.removeAttribute("value"),null!=t?yt(e,a,dt(t)):null!=n?yt(e,a,dt(n)):null!=r&&e.removeAttribute("value"),null==o&&null!=i&&(e.defaultChecked=!!i),null!=o&&(e.checked=o&&"function"!=typeof o&&"symbol"!=typeof o),null!=l&&"function"!=typeof l&&"symbol"!=typeof l&&"boolean"!=typeof l?e.name=""+dt(l):e.removeAttribute("name")}function vt(e,t,n,r,o,i,a,l){if(null!=i&&"function"!=typeof i&&"symbol"!=typeof i&&"boolean"!=typeof i&&(e.type=i),null!=t||null!=n){if(("submit"===i||"reset"===i)&&null==t)return void pt(e);n=null!=n?""+dt(n):"",t=null!=t?""+dt(t):n,l||t===e.value||(e.value=t),e.defaultValue=t}r="function"!=typeof(r=null!=r?r:o)&&"symbol"!=typeof r&&!!r,e.checked=l?e.checked:!!r,e.defaultChecked=!!r,null!=a&&"function"!=typeof a&&"symbol"!=typeof a&&"boolean"!=typeof a&&(e.name=a),pt(e)}function yt(e,t,n){"number"===t&>(e.ownerDocument)===e||e.defaultValue===""+n||(e.defaultValue=""+n)}function wt(e,t,n,r){if(e=e.options,t){t={};for(var o=0;o<n.length;o++)t["$"+n[o]]=!0;for(n=0;n<e.length;n++)o=t.hasOwnProperty("$"+e[n].value),e[n].selected!==o&&(e[n].selected=o),o&&r&&(e[n].defaultSelected=!0)}else{for(n=""+dt(n),t=null,o=0;o<e.length;o++){if(e[o].value===n)return e[o].selected=!0,void(r&&(e[o].defaultSelected=!0));null!==t||e[o].disabled||(t=e[o])}null!==t&&(t.selected=!0)}}function Ct(e,t,n){null==t||((t=""+dt(t))!==e.value&&(e.value=t),null!=n)?e.defaultValue=null!=n?""+dt(n):"":e.defaultValue!==t&&(e.defaultValue=t)}function St(e,t,n,r){if(null==t){if(null!=r){if(null!=n)throw Error(a(92));if(T(r)){if(1<r.length)throw Error(a(93));r=r[0]}n=r}null==n&&(n=""),t=n}n=dt(t),e.defaultValue=n,(r=e.textContent)===n&&""!==r&&null!==r&&(e.value=r),pt(e)}function xt(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&3===n.nodeType)return void(n.nodeValue=t)}e.textContent=t}var Et=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function It(e,t,n){var r=0===t.indexOf("--");null==n||"boolean"==typeof n||""===n?r?e.setProperty(t,""):"float"===t?e.cssFloat="":e[t]="":r?e.setProperty(t,n):"number"!=typeof n||0===n||Et.has(t)?"float"===t?e.cssFloat=n:e[t]=(""+n).trim():e[t]=n+"px"}function kt(e,t,n){if(null!=t&&"object"!=typeof t)throw Error(a(62));if(e=e.style,null!=n){for(var r in n)!n.hasOwnProperty(r)||null!=t&&t.hasOwnProperty(r)||(0===r.indexOf("--")?e.setProperty(r,""):"float"===r?e.cssFloat="":e[r]="");for(var o in t)r=t[o],t.hasOwnProperty(o)&&n[o]!==r&&It(e,o,r)}else for(var i in t)t.hasOwnProperty(i)&&It(e,i,t[i])}function Rt(e){if(-1===e.indexOf("-"))return!1;switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Mt=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),Pt=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function Bt(e){return Pt.test(""+e)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":e}function _t(){}var Tt=null;function Ot(e){return(e=e.target||e.srcElement||window).correspondingUseElement&&(e=e.correspondingUseElement),3===e.nodeType?e.parentNode:e}var Dt=null,Nt=null;function Lt(e){var t=Je(e);if(t&&(e=t.stateNode)){var n=e[$e]||null;e:switch(e=t.stateNode,t.type){case"input":if(bt(e,n.value,n.defaultValue,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name),t=n.name,"radio"===n.type&&null!=t){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll('input[name="'+At(""+t)+'"][type="radio"]'),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var o=r[$e]||null;if(!o)throw Error(a(90));bt(r,o.value,o.defaultValue,o.defaultValue,o.checked,o.defaultChecked,o.type,o.name)}}for(t=0;t<n.length;t++)(r=n[t]).form===e.form&&ht(r)}break e;case"textarea":Ct(e,n.value,n.defaultValue);break e;case"select":null!=(t=n.value)&&wt(e,!!n.multiple,t,!1)}}}var Ft=!1;function Qt(e,t,n){if(Ft)return e(t,n);Ft=!0;try{return e(t)}finally{if(Ft=!1,(null!==Dt||null!==Nt)&&(Zc(),Dt&&(t=Dt,e=Nt,Nt=Dt=null,Lt(t),e)))for(t=0;t<e.length;t++)Lt(e[t])}}function jt(e,t){var n=e.stateNode;if(null===n)return null;var r=n[$e]||null;if(null===r)return null;n=r[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(r=!r.disabled)||(r=!("button"===(e=e.type)||"input"===e||"select"===e||"textarea"===e)),e=!r;break e;default:e=!1}if(e)return null;if(n&&"function"!=typeof n)throw Error(a(231,t,typeof n));return n}var zt=!("undefined"==typeof window||void 0===window.document||void 0===window.document.createElement),$t=!1;if(zt)try{var Ht={};Object.defineProperty(Ht,"passive",{get:function(){$t=!0}}),window.addEventListener("test",Ht,Ht),window.removeEventListener("test",Ht,Ht)}catch(e){$t=!1}var Gt=null,Vt=null,Wt=null;function Ut(){if(Wt)return Wt;var e,t,n=Vt,r=n.length,o="value"in Gt?Gt.value:Gt.textContent,i=o.length;for(e=0;e<r&&n[e]===o[e];e++);var a=r-e;for(t=1;t<=a&&n[r-t]===o[i-t];t++);return Wt=o.slice(e,1<t?1-t:void 0)}function qt(e){var t=e.keyCode;return"charCode"in e?0===(e=e.charCode)&&13===t&&(e=13):e=t,10===e&&(e=13),32<=e||13===e?e:0}function Yt(){return!0}function Kt(){return!1}function Jt(e){function t(t,n,r,o,i){for(var a in this._reactName=t,this._targetInst=r,this.type=n,this.nativeEvent=o,this.target=i,this.currentTarget=null,e)e.hasOwnProperty(a)&&(t=e[a],this[a]=t?t(o):o[a]);return this.isDefaultPrevented=(null!=o.defaultPrevented?o.defaultPrevented:!1===o.returnValue)?Yt:Kt,this.isPropagationStopped=Kt,this}return p(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():"unknown"!=typeof e.returnValue&&(e.returnValue=!1),this.isDefaultPrevented=Yt)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():"unknown"!=typeof e.cancelBubble&&(e.cancelBubble=!0),this.isPropagationStopped=Yt)},persist:function(){},isPersistent:Yt}),t}var Xt,Zt,en,tn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},nn=Jt(tn),rn=p({},tn,{view:0,detail:0}),on=Jt(rn),an=p({},rn,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:An,button:0,buttons:0,relatedTarget:function(e){return void 0===e.relatedTarget?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==en&&(en&&"mousemove"===e.type?(Xt=e.screenX-en.screenX,Zt=e.screenY-en.screenY):Zt=Xt=0,en=e),Xt)},movementY:function(e){return"movementY"in e?e.movementY:Zt}}),ln=Jt(an),sn=Jt(p({},an,{dataTransfer:0})),cn=Jt(p({},rn,{relatedTarget:0})),un=Jt(p({},tn,{animationName:0,elapsedTime:0,pseudoElement:0})),dn=Jt(p({},tn,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}})),fn=Jt(p({},tn,{data:0})),pn={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},hn={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},gn={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function mn(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):!!(e=gn[e])&&!!t[e]}function An(){return mn}var bn=Jt(p({},rn,{key:function(e){if(e.key){var t=pn[e.key]||e.key;if("Unidentified"!==t)return t}return"keypress"===e.type?13===(e=qt(e))?"Enter":String.fromCharCode(e):"keydown"===e.type||"keyup"===e.type?hn[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:An,charCode:function(e){return"keypress"===e.type?qt(e):0},keyCode:function(e){return"keydown"===e.type||"keyup"===e.type?e.keyCode:0},which:function(e){return"keypress"===e.type?qt(e):"keydown"===e.type||"keyup"===e.type?e.keyCode:0}})),vn=Jt(p({},an,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0})),yn=Jt(p({},rn,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:An})),wn=Jt(p({},tn,{propertyName:0,elapsedTime:0,pseudoElement:0})),Cn=Jt(p({},an,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0})),Sn=Jt(p({},tn,{newState:0,oldState:0})),xn=[9,13,27,32],En=zt&&"CompositionEvent"in window,In=null;zt&&"documentMode"in document&&(In=document.documentMode);var kn=zt&&"TextEvent"in window&&!In,Rn=zt&&(!En||In&&8<In&&11>=In),Mn=String.fromCharCode(32),Pn=!1;function Bn(e,t){switch(e){case"keyup":return-1!==xn.indexOf(t.keyCode);case"keydown":return 229!==t.keyCode;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function _n(e){return"object"==typeof(e=e.detail)&&"data"in e?e.data:null}var Tn=!1,On={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function Dn(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return"input"===t?!!On[e.type]:"textarea"===t}function Nn(e,t,n,r){Dt?Nt?Nt.push(r):Nt=[r]:Dt=r,0<(t=rd(t,"onChange")).length&&(n=new nn("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var Ln=null,Fn=null;function Qn(e){Yu(e,0)}function jn(e){if(ht(Xe(e)))return e}function zn(e,t){if("change"===e)return t}var $n=!1;if(zt){var Hn;if(zt){var Gn="oninput"in document;if(!Gn){var Vn=document.createElement("div");Vn.setAttribute("oninput","return;"),Gn="function"==typeof Vn.oninput}Hn=Gn}else Hn=!1;$n=Hn&&(!document.documentMode||9<document.documentMode)}function Wn(){Ln&&(Ln.detachEvent("onpropertychange",Un),Fn=Ln=null)}function Un(e){if("value"===e.propertyName&&jn(Fn)){var t=[];Nn(t,Fn,e,Ot(e)),Qt(Qn,t)}}function qn(e,t,n){"focusin"===e?(Wn(),Fn=n,(Ln=t).attachEvent("onpropertychange",Un)):"focusout"===e&&Wn()}function Yn(e){if("selectionchange"===e||"keyup"===e||"keydown"===e)return jn(Fn)}function Kn(e,t){if("click"===e)return jn(t)}function Jn(e,t){if("input"===e||"change"===e)return jn(t)}var Xn="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t};function Zn(e,t){if(Xn(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var o=n[r];if(!re.call(t,o)||!Xn(e[o],t[o]))return!1}return!0}function er(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function tr(e,t){var n,r=er(e);for(e=0;r;){if(3===r.nodeType){if(n=e+r.textContent.length,e<=t&&n>=t)return{node:r,offset:t-e};e=n}e:{for(;r;){if(r.nextSibling){r=r.nextSibling;break e}r=r.parentNode}r=void 0}r=er(r)}}function nr(e,t){return!(!e||!t)&&(e===t||(!e||3!==e.nodeType)&&(t&&3===t.nodeType?nr(e,t.parentNode):"contains"in e?e.contains(t):!!e.compareDocumentPosition&&!!(16&e.compareDocumentPosition(t))))}function rr(e){for(var t=gt((e=null!=e&&null!=e.ownerDocument&&null!=e.ownerDocument.defaultView?e.ownerDocument.defaultView:window).document);t instanceof e.HTMLIFrameElement;){try{var n="string"==typeof t.contentWindow.location.href}catch(e){n=!1}if(!n)break;t=gt((e=t.contentWindow).document)}return t}function or(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&("input"===t&&("text"===e.type||"search"===e.type||"tel"===e.type||"url"===e.type||"password"===e.type)||"textarea"===t||"true"===e.contentEditable)}var ir=zt&&"documentMode"in document&&11>=document.documentMode,ar=null,lr=null,sr=null,cr=!1;function ur(e,t,n){var r=n.window===n?n.document:9===n.nodeType?n:n.ownerDocument;cr||null==ar||ar!==gt(r)||(r="selectionStart"in(r=ar)&&or(r)?{start:r.selectionStart,end:r.selectionEnd}:{anchorNode:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection()).anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset},sr&&Zn(sr,r)||(sr=r,0<(r=rd(lr,"onSelect")).length&&(t=new nn("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=ar)))}function dr(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var fr={animationend:dr("Animation","AnimationEnd"),animationiteration:dr("Animation","AnimationIteration"),animationstart:dr("Animation","AnimationStart"),transitionrun:dr("Transition","TransitionRun"),transitionstart:dr("Transition","TransitionStart"),transitioncancel:dr("Transition","TransitionCancel"),transitionend:dr("Transition","TransitionEnd")},pr={},hr={};function gr(e){if(pr[e])return pr[e];if(!fr[e])return e;var t,n=fr[e];for(t in n)if(n.hasOwnProperty(t)&&t in hr)return pr[e]=n[t];return e}zt&&(hr=document.createElement("div").style,"AnimationEvent"in window||(delete fr.animationend.animation,delete fr.animationiteration.animation,delete fr.animationstart.animation),"TransitionEvent"in window||delete fr.transitionend.transition);var mr=gr("animationend"),Ar=gr("animationiteration"),br=gr("animationstart"),vr=gr("transitionrun"),yr=gr("transitionstart"),wr=gr("transitioncancel"),Cr=gr("transitionend"),Sr=new Map,xr="abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function Er(e,t){Sr.set(e,t),rt(t,[e])}xr.push("scrollEnd");var Ir="function"==typeof reportError?reportError:function(e){if("object"==typeof window&&"function"==typeof window.ErrorEvent){var t=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:"object"==typeof e&&null!==e&&"string"==typeof e.message?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if("object"==typeof process&&"function"==typeof process.emit)return void process.emit("uncaughtException",e);console.error(e)},kr=[],Rr=0,Mr=0;function Pr(){for(var e=Rr,t=Mr=Rr=0;t<e;){var n=kr[t];kr[t++]=null;var r=kr[t];kr[t++]=null;var o=kr[t];kr[t++]=null;var i=kr[t];if(kr[t++]=null,null!==r&&null!==o){var a=r.pending;null===a?o.next=o:(o.next=a.next,a.next=o),r.pending=o}0!==i&&Or(n,o,i)}}function Br(e,t,n,r){kr[Rr++]=e,kr[Rr++]=t,kr[Rr++]=n,kr[Rr++]=r,Mr|=r,e.lanes|=r,null!==(e=e.alternate)&&(e.lanes|=r)}function _r(e,t,n,r){return Br(e,t,n,r),Dr(e)}function Tr(e,t){return Br(e,null,null,t),Dr(e)}function Or(e,t,n){e.lanes|=n;var r=e.alternate;null!==r&&(r.lanes|=n);for(var o=!1,i=e.return;null!==i;)i.childLanes|=n,null!==(r=i.alternate)&&(r.childLanes|=n),22===i.tag&&(null===(e=i.stateNode)||1&e._visibility||(o=!0)),e=i,i=i.return;return 3===e.tag?(i=e.stateNode,o&&null!==t&&(o=31-ye(n),null===(r=(e=i.hiddenUpdates)[o])?e[o]=[t]:r.push(t),t.lane=536870912|n),i):null}function Dr(e){if(50<Gc)throw Gc=0,Vc=null,Error(a(185));for(var t=e.return;null!==t;)t=(e=t).return;return 3===e.tag?e.stateNode:null}var Nr={};function Lr(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Fr(e,t,n,r){return new Lr(e,t,n,r)}function Qr(e){return!(!(e=e.prototype)||!e.isReactComponent)}function jr(e,t){var n=e.alternate;return null===n?((n=Fr(e.tag,t,e.key,e.mode)).elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=65011712&e.flags,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=null===t?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n.refCleanup=e.refCleanup,n}function zr(e,t){e.flags&=65011714;var n=e.alternate;return null===n?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=n.childLanes,e.lanes=n.lanes,e.child=n.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=n.memoizedProps,e.memoizedState=n.memoizedState,e.updateQueue=n.updateQueue,e.type=n.type,t=n.dependencies,e.dependencies=null===t?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function $r(e,t,n,r,o,i){var l=0;if(r=e,"function"==typeof e)Qr(e)&&(l=1);else if("string"==typeof e)l=function(e,t,n){if(1===n||null!=t.itemProp)return!1;switch(e){case"meta":case"title":return!0;case"style":if("string"!=typeof t.precedence||"string"!=typeof t.href||""===t.href)break;return!0;case"link":if("string"!=typeof t.rel||"string"!=typeof t.href||""===t.href||t.onLoad||t.onError)break;return"stylesheet"!==t.rel||(e=t.disabled,"string"==typeof t.precedence&&null==e);case"script":if(t.async&&"function"!=typeof t.async&&"symbol"!=typeof t.async&&!t.onLoad&&!t.onError&&t.src&&"string"==typeof t.src)return!0}return!1}(e,n,G.current)?26:"html"===e||"head"===e||"body"===e?27:5;else e:switch(e){case k:return(e=Fr(31,n,t,o)).elementType=k,e.lanes=i,e;case A:return Hr(n.children,o,i,t);case b:l=8,o|=24;break;case v:return(e=Fr(12,n,t,2|o)).elementType=v,e.lanes=i,e;case S:return(e=Fr(13,n,t,o)).elementType=S,e.lanes=i,e;case x:return(e=Fr(19,n,t,o)).elementType=x,e.lanes=i,e;default:if("object"==typeof e&&null!==e)switch(e.$$typeof){case w:l=10;break e;case y:l=9;break e;case C:l=11;break e;case E:l=14;break e;case I:l=16,r=null;break e}l=29,n=Error(a(130,null===e?"null":typeof e,"")),r=null}return(t=Fr(l,n,t,o)).elementType=e,t.type=r,t.lanes=i,t}function Hr(e,t,n,r){return(e=Fr(7,e,r,t)).lanes=n,e}function Gr(e,t,n){return(e=Fr(6,e,null,t)).lanes=n,e}function Vr(e){var t=Fr(18,null,null,0);return t.stateNode=e,t}function Wr(e,t,n){return(t=Fr(4,null!==e.children?e.children:[],e.key,t)).lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var Ur=new WeakMap;function qr(e,t){if("object"==typeof e&&null!==e){var n=Ur.get(e);return void 0!==n?n:(t={value:e,source:t,stack:ne(t)},Ur.set(e,t),t)}return{value:e,source:t,stack:ne(t)}}var Yr=[],Kr=0,Jr=null,Xr=0,Zr=[],eo=0,to=null,no=1,ro="";function oo(e,t){Yr[Kr++]=Xr,Yr[Kr++]=Jr,Jr=e,Xr=t}function io(e,t,n){Zr[eo++]=no,Zr[eo++]=ro,Zr[eo++]=to,to=e;var r=no;e=ro;var o=32-ye(r)-1;r&=~(1<<o),n+=1;var i=32-ye(t)+o;if(30<i){var a=o-o%5;i=(r&(1<<a)-1).toString(32),r>>=a,o-=a,no=1<<32-ye(t)+o|n<<o|r,ro=i+e}else no=1<<i|n<<o|r,ro=e}function ao(e){null!==e.return&&(oo(e,1),io(e,1,0))}function lo(e){for(;e===Jr;)Jr=Yr[--Kr],Yr[Kr]=null,Xr=Yr[--Kr],Yr[Kr]=null;for(;e===to;)to=Zr[--eo],Zr[eo]=null,ro=Zr[--eo],Zr[eo]=null,no=Zr[--eo],Zr[eo]=null}function so(e,t){Zr[eo++]=no,Zr[eo++]=ro,Zr[eo++]=to,no=t.id,ro=t.overflow,to=e}var co=null,uo=null,fo=!1,po=null,ho=!1,go=Error(a(519));function mo(e){throw Co(qr(Error(a(418,1<arguments.length&&void 0!==arguments[1]&&arguments[1]?"text":"HTML","")),e)),go}function Ao(e){var t=e.stateNode,n=e.type,r=e.memoizedProps;switch(t[ze]=e,t[$e]=r,n){case"dialog":Ku("cancel",t),Ku("close",t);break;case"iframe":case"object":case"embed":Ku("load",t);break;case"video":case"audio":for(n=0;n<Uu.length;n++)Ku(Uu[n],t);break;case"source":Ku("error",t);break;case"img":case"image":case"link":Ku("error",t),Ku("load",t);break;case"details":Ku("toggle",t);break;case"input":Ku("invalid",t),vt(t,r.value,r.defaultValue,r.checked,r.defaultChecked,r.type,r.name,!0);break;case"select":Ku("invalid",t);break;case"textarea":Ku("invalid",t),St(t,r.value,r.defaultValue,r.children)}"string"!=typeof(n=r.children)&&"number"!=typeof n&&"bigint"!=typeof n||t.textContent===""+n||!0===r.suppressHydrationWarning||cd(t.textContent,n)?(null!=r.popover&&(Ku("beforetoggle",t),Ku("toggle",t)),null!=r.onScroll&&Ku("scroll",t),null!=r.onScrollEnd&&Ku("scrollend",t),null!=r.onClick&&(t.onclick=_t),t=!0):t=!1,t||mo(e,!0)}function bo(e){for(co=e.return;co;)switch(co.tag){case 5:case 31:case 13:return void(ho=!1);case 27:case 3:return void(ho=!0);default:co=co.return}}function vo(e){if(e!==co)return!1;if(!fo)return bo(e),fo=!0,!1;var t,n=e.tag;if((t=3!==n&&27!==n)&&((t=5===n)&&(t=!("form"!==(t=e.type)&&"button"!==t)||vd(e.type,e.memoizedProps)),t=!t),t&&uo&&mo(e),bo(e),13===n){if(!(e=null!==(e=e.memoizedState)?e.dehydrated:null))throw Error(a(317));uo=Dd(e)}else if(31===n){if(!(e=null!==(e=e.memoizedState)?e.dehydrated:null))throw Error(a(317));uo=Dd(e)}else 27===n?(n=uo,Id(e.type)?(e=Od,Od=null,uo=e):uo=n):uo=co?Td(e.stateNode.nextSibling):null;return!0}function yo(){uo=co=null,fo=!1}function wo(){var e=po;return null!==e&&(null===Pc?Pc=e:Pc.push.apply(Pc,e),po=null),e}function Co(e){null===po?po=[e]:po.push(e)}var So=Q(null),xo=null,Eo=null;function Io(e,t,n){z(So,t._currentValue),t._currentValue=n}function ko(e){e._currentValue=So.current,j(So)}function Ro(e,t,n){for(;null!==e;){var r=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,null!==r&&(r.childLanes|=t)):null!==r&&(r.childLanes&t)!==t&&(r.childLanes|=t),e===n)break;e=e.return}}function Mo(e,t,n,r){var o=e.child;for(null!==o&&(o.return=e);null!==o;){var i=o.dependencies;if(null!==i){var l=o.child;i=i.firstContext;e:for(;null!==i;){var s=i;i=o;for(var c=0;c<t.length;c++)if(s.context===t[c]){i.lanes|=n,null!==(s=i.alternate)&&(s.lanes|=n),Ro(i.return,n,e),r||(l=null);break e}i=s.next}}else if(18===o.tag){if(null===(l=o.return))throw Error(a(341));l.lanes|=n,null!==(i=l.alternate)&&(i.lanes|=n),Ro(l,n,e),l=null}else l=o.child;if(null!==l)l.return=o;else for(l=o;null!==l;){if(l===e){l=null;break}if(null!==(o=l.sibling)){o.return=l.return,l=o;break}l=l.return}o=l}}function Po(e,t,n,r){e=null;for(var o=t,i=!1;null!==o;){if(!i)if(524288&o.flags)i=!0;else if(262144&o.flags)break;if(10===o.tag){var l=o.alternate;if(null===l)throw Error(a(387));if(null!==(l=l.memoizedProps)){var s=o.type;Xn(o.pendingProps.value,l.value)||(null!==e?e.push(s):e=[s])}}else if(o===U.current){if(null===(l=o.alternate))throw Error(a(387));l.memoizedState.memoizedState!==o.memoizedState.memoizedState&&(null!==e?e.push(df):e=[df])}o=o.return}null!==e&&Mo(t,e,n,r),t.flags|=262144}function Bo(e){for(e=e.firstContext;null!==e;){if(!Xn(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function _o(e){xo=e,Eo=null,null!==(e=e.dependencies)&&(e.firstContext=null)}function To(e){return Do(xo,e)}function Oo(e,t){return null===xo&&_o(e),Do(e,t)}function Do(e,t){var n=t._currentValue;if(t={context:t,memoizedValue:n,next:null},null===Eo){if(null===e)throw Error(a(308));Eo=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else Eo=Eo.next=t;return n}var No="undefined"!=typeof AbortController?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(t,n){e.push(n)}};this.abort=function(){t.aborted=!0,e.forEach(function(e){return e()})}},Lo=r.unstable_scheduleCallback,Fo=r.unstable_NormalPriority,Qo={$$typeof:w,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function jo(){return{controller:new No,data:new Map,refCount:0}}function zo(e){e.refCount--,0===e.refCount&&Lo(Fo,function(){e.controller.abort()})}var $o=null,Ho=0,Go=0,Vo=null;function Wo(){if(0===--Ho&&null!==$o){null!==Vo&&(Vo.status="fulfilled");var e=$o;$o=null,Go=0,Vo=null;for(var t=0;t<e.length;t++)(0,e[t])()}}var Uo=O.S;O.S=function(e,t){Tc=se(),"object"==typeof t&&null!==t&&"function"==typeof t.then&&function(e,t){if(null===$o){var n=$o=[];Ho=0,Go=$u(),Vo={status:"pending",value:void 0,then:function(e){n.push(e)}}}Ho++,t.then(Wo,Wo)}(0,t),null!==Uo&&Uo(e,t)};var qo=Q(null);function Yo(){var e=qo.current;return null!==e?e:hc.pooledCache}function Ko(e,t){z(qo,null===t?qo.current:t.pool)}function Jo(){var e=Yo();return null===e?null:{parent:Qo._currentValue,pool:e}}var Xo=Error(a(460)),Zo=Error(a(474)),ei=Error(a(542)),ti={then:function(){}};function ni(e){return"fulfilled"===(e=e.status)||"rejected"===e}function ri(e,t,n){switch(void 0===(n=e[n])?e.push(t):n!==t&&(t.then(_t,_t),t=n),t.status){case"fulfilled":return t.value;case"rejected":throw li(e=t.reason),e;default:if("string"==typeof t.status)t.then(_t,_t);else{if(null!==(e=hc)&&100<e.shellSuspendCounter)throw Error(a(482));(e=t).status="pending",e.then(function(e){if("pending"===t.status){var n=t;n.status="fulfilled",n.value=e}},function(e){if("pending"===t.status){var n=t;n.status="rejected",n.reason=e}})}switch(t.status){case"fulfilled":return t.value;case"rejected":throw li(e=t.reason),e}throw ii=t,Xo}}function oi(e){try{return(0,e._init)(e._payload)}catch(e){if(null!==e&&"object"==typeof e&&"function"==typeof e.then)throw ii=e,Xo;throw e}}var ii=null;function ai(){if(null===ii)throw Error(a(459));var e=ii;return ii=null,e}function li(e){if(e===Xo||e===ei)throw Error(a(483))}var si=null,ci=0;function ui(e){var t=ci;return ci+=1,null===si&&(si=[]),ri(si,e,t)}function di(e,t){t=t.props.ref,e.ref=void 0!==t?t:null}function fi(e,t){if(t.$$typeof===h)throw Error(a(525));throw e=Object.prototype.toString.call(t),Error(a(31,"[object Object]"===e?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function pi(e){function t(t,n){if(e){var r=t.deletions;null===r?(t.deletions=[n],t.flags|=16):r.push(n)}}function n(n,r){if(!e)return null;for(;null!==r;)t(n,r),r=r.sibling;return null}function r(e){for(var t=new Map;null!==e;)null!==e.key?t.set(e.key,e):t.set(e.index,e),e=e.sibling;return t}function o(e,t){return(e=jr(e,t)).index=0,e.sibling=null,e}function i(t,n,r){return t.index=r,e?null!==(r=t.alternate)?(r=r.index)<n?(t.flags|=67108866,n):r:(t.flags|=67108866,n):(t.flags|=1048576,n)}function l(t){return e&&null===t.alternate&&(t.flags|=67108866),t}function s(e,t,n,r){return null===t||6!==t.tag?((t=Gr(n,e.mode,r)).return=e,t):((t=o(t,n)).return=e,t)}function c(e,t,n,r){var i=n.type;return i===A?d(e,t,n.props.children,r,n.key):null!==t&&(t.elementType===i||"object"==typeof i&&null!==i&&i.$$typeof===I&&oi(i)===t.type)?(di(t=o(t,n.props),n),t.return=e,t):(di(t=$r(n.type,n.key,n.props,null,e.mode,r),n),t.return=e,t)}function u(e,t,n,r){return null===t||4!==t.tag||t.stateNode.containerInfo!==n.containerInfo||t.stateNode.implementation!==n.implementation?((t=Wr(n,e.mode,r)).return=e,t):((t=o(t,n.children||[])).return=e,t)}function d(e,t,n,r,i){return null===t||7!==t.tag?((t=Hr(n,e.mode,r,i)).return=e,t):((t=o(t,n)).return=e,t)}function f(e,t,n){if("string"==typeof t&&""!==t||"number"==typeof t||"bigint"==typeof t)return(t=Gr(""+t,e.mode,n)).return=e,t;if("object"==typeof t&&null!==t){switch(t.$$typeof){case g:return di(n=$r(t.type,t.key,t.props,null,e.mode,n),t),n.return=e,n;case m:return(t=Wr(t,e.mode,n)).return=e,t;case I:return f(e,t=oi(t),n)}if(T(t)||P(t))return(t=Hr(t,e.mode,n,null)).return=e,t;if("function"==typeof t.then)return f(e,ui(t),n);if(t.$$typeof===w)return f(e,Oo(e,t),n);fi(e,t)}return null}function p(e,t,n,r){var o=null!==t?t.key:null;if("string"==typeof n&&""!==n||"number"==typeof n||"bigint"==typeof n)return null!==o?null:s(e,t,""+n,r);if("object"==typeof n&&null!==n){switch(n.$$typeof){case g:return n.key===o?c(e,t,n,r):null;case m:return n.key===o?u(e,t,n,r):null;case I:return p(e,t,n=oi(n),r)}if(T(n)||P(n))return null!==o?null:d(e,t,n,r,null);if("function"==typeof n.then)return p(e,t,ui(n),r);if(n.$$typeof===w)return p(e,t,Oo(e,n),r);fi(e,n)}return null}function h(e,t,n,r,o){if("string"==typeof r&&""!==r||"number"==typeof r||"bigint"==typeof r)return s(t,e=e.get(n)||null,""+r,o);if("object"==typeof r&&null!==r){switch(r.$$typeof){case g:return c(t,e=e.get(null===r.key?n:r.key)||null,r,o);case m:return u(t,e=e.get(null===r.key?n:r.key)||null,r,o);case I:return h(e,t,n,r=oi(r),o)}if(T(r)||P(r))return d(t,e=e.get(n)||null,r,o,null);if("function"==typeof r.then)return h(e,t,n,ui(r),o);if(r.$$typeof===w)return h(e,t,n,Oo(t,r),o);fi(t,r)}return null}function b(s,c,u,d){if("object"==typeof u&&null!==u&&u.type===A&&null===u.key&&(u=u.props.children),"object"==typeof u&&null!==u){switch(u.$$typeof){case g:e:{for(var v=u.key;null!==c;){if(c.key===v){if((v=u.type)===A){if(7===c.tag){n(s,c.sibling),(d=o(c,u.props.children)).return=s,s=d;break e}}else if(c.elementType===v||"object"==typeof v&&null!==v&&v.$$typeof===I&&oi(v)===c.type){n(s,c.sibling),di(d=o(c,u.props),u),d.return=s,s=d;break e}n(s,c);break}t(s,c),c=c.sibling}u.type===A?((d=Hr(u.props.children,s.mode,d,u.key)).return=s,s=d):(di(d=$r(u.type,u.key,u.props,null,s.mode,d),u),d.return=s,s=d)}return l(s);case m:e:{for(v=u.key;null!==c;){if(c.key===v){if(4===c.tag&&c.stateNode.containerInfo===u.containerInfo&&c.stateNode.implementation===u.implementation){n(s,c.sibling),(d=o(c,u.children||[])).return=s,s=d;break e}n(s,c);break}t(s,c),c=c.sibling}(d=Wr(u,s.mode,d)).return=s,s=d}return l(s);case I:return b(s,c,u=oi(u),d)}if(T(u))return function(o,a,l,s){for(var c=null,u=null,d=a,g=a=0,m=null;null!==d&&g<l.length;g++){d.index>g?(m=d,d=null):m=d.sibling;var A=p(o,d,l[g],s);if(null===A){null===d&&(d=m);break}e&&d&&null===A.alternate&&t(o,d),a=i(A,a,g),null===u?c=A:u.sibling=A,u=A,d=m}if(g===l.length)return n(o,d),fo&&oo(o,g),c;if(null===d){for(;g<l.length;g++)null!==(d=f(o,l[g],s))&&(a=i(d,a,g),null===u?c=d:u.sibling=d,u=d);return fo&&oo(o,g),c}for(d=r(d);g<l.length;g++)null!==(m=h(d,o,g,l[g],s))&&(e&&null!==m.alternate&&d.delete(null===m.key?g:m.key),a=i(m,a,g),null===u?c=m:u.sibling=m,u=m);return e&&d.forEach(function(e){return t(o,e)}),fo&&oo(o,g),c}(s,c,u,d);if(P(u)){if("function"!=typeof(v=P(u)))throw Error(a(150));return function(o,l,s,c){if(null==s)throw Error(a(151));for(var u=null,d=null,g=l,m=l=0,A=null,b=s.next();null!==g&&!b.done;m++,b=s.next()){g.index>m?(A=g,g=null):A=g.sibling;var v=p(o,g,b.value,c);if(null===v){null===g&&(g=A);break}e&&g&&null===v.alternate&&t(o,g),l=i(v,l,m),null===d?u=v:d.sibling=v,d=v,g=A}if(b.done)return n(o,g),fo&&oo(o,m),u;if(null===g){for(;!b.done;m++,b=s.next())null!==(b=f(o,b.value,c))&&(l=i(b,l,m),null===d?u=b:d.sibling=b,d=b);return fo&&oo(o,m),u}for(g=r(g);!b.done;m++,b=s.next())null!==(b=h(g,o,m,b.value,c))&&(e&&null!==b.alternate&&g.delete(null===b.key?m:b.key),l=i(b,l,m),null===d?u=b:d.sibling=b,d=b);return e&&g.forEach(function(e){return t(o,e)}),fo&&oo(o,m),u}(s,c,u=v.call(u),d)}if("function"==typeof u.then)return b(s,c,ui(u),d);if(u.$$typeof===w)return b(s,c,Oo(s,u),d);fi(s,u)}return"string"==typeof u&&""!==u||"number"==typeof u||"bigint"==typeof u?(u=""+u,null!==c&&6===c.tag?(n(s,c.sibling),(d=o(c,u)).return=s,s=d):(n(s,c),(d=Gr(u,s.mode,d)).return=s,s=d),l(s)):n(s,c)}return function(e,t,n,r){try{ci=0;var o=b(e,t,n,r);return si=null,o}catch(t){if(t===Xo||t===ei)throw t;var i=Fr(29,t,null,e.mode);return i.lanes=r,i.return=e,i}}}var hi=pi(!0),gi=pi(!1),mi=!1;function Ai(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function bi(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function vi(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function yi(e,t,n){var r=e.updateQueue;if(null===r)return null;if(r=r.shared,2&pc){var o=r.pending;return null===o?t.next=t:(t.next=o.next,o.next=t),r.pending=t,t=Dr(e),Or(e,null,n),t}return Br(e,r,t,n),Dr(e)}function wi(e,t,n){if(null!==(t=t.updateQueue)&&(t=t.shared,4194048&n)){var r=t.lanes;n|=r&=e.pendingLanes,t.lanes=n,Oe(e,n)}}function Ci(e,t){var n=e.updateQueue,r=e.alternate;if(null!==r&&n===(r=r.updateQueue)){var o=null,i=null;if(null!==(n=n.firstBaseUpdate)){do{var a={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};null===i?o=i=a:i=i.next=a,n=n.next}while(null!==n);null===i?o=i=t:i=i.next=t}else o=i=t;return n={baseState:r.baseState,firstBaseUpdate:o,lastBaseUpdate:i,shared:r.shared,callbacks:r.callbacks},void(e.updateQueue=n)}null===(e=n.lastBaseUpdate)?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}var Si=!1;function xi(){if(Si&&null!==Vo)throw Vo}function Ei(e,t,n,r){Si=!1;var o=e.updateQueue;mi=!1;var i=o.firstBaseUpdate,a=o.lastBaseUpdate,l=o.shared.pending;if(null!==l){o.shared.pending=null;var s=l,c=s.next;s.next=null,null===a?i=c:a.next=c,a=s;var u=e.alternate;null!==u&&(l=(u=u.updateQueue).lastBaseUpdate)!==a&&(null===l?u.firstBaseUpdate=c:l.next=c,u.lastBaseUpdate=s)}if(null!==i){var d=o.baseState;for(a=0,u=c=s=null,l=i;;){var f=-536870913&l.lane,h=f!==l.lane;if(h?(mc&f)===f:(r&f)===f){0!==f&&f===Go&&(Si=!0),null!==u&&(u=u.next={lane:0,tag:l.tag,payload:l.payload,callback:null,next:null});e:{var g=e,m=l;f=t;var A=n;switch(m.tag){case 1:if("function"==typeof(g=m.payload)){d=g.call(A,d,f);break e}d=g;break e;case 3:g.flags=-65537&g.flags|128;case 0:if(null==(f="function"==typeof(g=m.payload)?g.call(A,d,f):g))break e;d=p({},d,f);break e;case 2:mi=!0}}null!==(f=l.callback)&&(e.flags|=64,h&&(e.flags|=8192),null===(h=o.callbacks)?o.callbacks=[f]:h.push(f))}else h={lane:f,tag:l.tag,payload:l.payload,callback:l.callback,next:null},null===u?(c=u=h,s=d):u=u.next=h,a|=f;if(null===(l=l.next)){if(null===(l=o.shared.pending))break;l=(h=l).next,h.next=null,o.lastBaseUpdate=h,o.shared.pending=null}}null===u&&(s=d),o.baseState=s,o.firstBaseUpdate=c,o.lastBaseUpdate=u,null===i&&(o.shared.lanes=0),xc|=a,e.lanes=a,e.memoizedState=d}}function Ii(e,t){if("function"!=typeof e)throw Error(a(191,e));e.call(t)}function ki(e,t){var n=e.callbacks;if(null!==n)for(e.callbacks=null,e=0;e<n.length;e++)Ii(n[e],t)}var Ri=Q(null),Mi=Q(0);function Pi(e,t){z(Mi,e=Cc),z(Ri,t),Cc=e|t.baseLanes}function Bi(){z(Mi,Cc),z(Ri,Ri.current)}function _i(){Cc=Mi.current,j(Ri),j(Mi)}var Ti=Q(null),Oi=null;function Di(e){var t=e.alternate;z(ji,1&ji.current),z(Ti,e),null===Oi&&(null===t||null!==Ri.current||null!==t.memoizedState)&&(Oi=e)}function Ni(e){z(ji,ji.current),z(Ti,e),null===Oi&&(Oi=e)}function Li(e){22===e.tag?(z(ji,ji.current),z(Ti,e),null===Oi&&(Oi=e)):Fi()}function Fi(){z(ji,ji.current),z(Ti,Ti.current)}function Qi(e){j(Ti),Oi===e&&(Oi=null),j(ji)}var ji=Q(0);function zi(e){for(var t=e;null!==t;){if(13===t.tag){var n=t.memoizedState;if(null!==n&&(null===(n=n.dehydrated)||Bd(n)||_d(n)))return t}else if(19!==t.tag||"forwards"!==t.memoizedProps.revealOrder&&"backwards"!==t.memoizedProps.revealOrder&&"unstable_legacy-backwards"!==t.memoizedProps.revealOrder&&"together"!==t.memoizedProps.revealOrder){if(null!==t.child){t.child.return=t,t=t.child;continue}}else if(128&t.flags)return t;if(t===e)break;for(;null===t.sibling;){if(null===t.return||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var $i=0,Hi=null,Gi=null,Vi=null,Wi=!1,Ui=!1,qi=!1,Yi=0,Ki=0,Ji=null,Xi=0;function Zi(){throw Error(a(321))}function ea(e,t){if(null===t)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!Xn(e[n],t[n]))return!1;return!0}function ta(e,t,n,r,o,i){return $i=i,Hi=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,O.H=null===e||null===e.memoizedState?ml:Al,qi=!1,i=n(r,o),qi=!1,Ui&&(i=ra(t,n,r,o)),na(e),i}function na(e){O.H=gl;var t=null!==Gi&&null!==Gi.next;if($i=0,Vi=Gi=Hi=null,Wi=!1,Ki=0,Ji=null,t)throw Error(a(300));null===e||Tl||null!==(e=e.dependencies)&&Bo(e)&&(Tl=!0)}function ra(e,t,n,r){Hi=e;var o=0;do{if(Ui&&(Ji=null),Ki=0,Ui=!1,25<=o)throw Error(a(301));if(o+=1,Vi=Gi=null,null!=e.updateQueue){var i=e.updateQueue;i.lastEffect=null,i.events=null,i.stores=null,null!=i.memoCache&&(i.memoCache.index=0)}O.H=bl,i=t(n,r)}while(Ui);return i}function oa(){var e=O.H,t=e.useState()[0];return t="function"==typeof t.then?ua(t):t,e=e.useState()[0],(null!==Gi?Gi.memoizedState:null)!==e&&(Hi.flags|=1024),t}function ia(){var e=0!==Yi;return Yi=0,e}function aa(e,t,n){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~n}function la(e){if(Wi){for(e=e.memoizedState;null!==e;){var t=e.queue;null!==t&&(t.pending=null),e=e.next}Wi=!1}$i=0,Vi=Gi=Hi=null,Ui=!1,Ki=Yi=0,Ji=null}function sa(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return null===Vi?Hi.memoizedState=Vi=e:Vi=Vi.next=e,Vi}function ca(){if(null===Gi){var e=Hi.alternate;e=null!==e?e.memoizedState:null}else e=Gi.next;var t=null===Vi?Hi.memoizedState:Vi.next;if(null!==t)Vi=t,Gi=e;else{if(null===e){if(null===Hi.alternate)throw Error(a(467));throw Error(a(310))}e={memoizedState:(Gi=e).memoizedState,baseState:Gi.baseState,baseQueue:Gi.baseQueue,queue:Gi.queue,next:null},null===Vi?Hi.memoizedState=Vi=e:Vi=Vi.next=e}return Vi}function ua(e){var t=Ki;return Ki+=1,null===Ji&&(Ji=[]),e=ri(Ji,e,t),t=Hi,null===(null===Vi?t.memoizedState:Vi.next)&&(t=t.alternate,O.H=null===t||null===t.memoizedState?ml:Al),e}function da(e){if(null!==e&&"object"==typeof e){if("function"==typeof e.then)return ua(e);if(e.$$typeof===w)return To(e)}throw Error(a(438,String(e)))}function fa(e){var t=null,n=Hi.updateQueue;if(null!==n&&(t=n.memoCache),null==t){var r=Hi.alternate;null!==r&&null!==(r=r.updateQueue)&&null!=(r=r.memoCache)&&(t={data:r.data.map(function(e){return e.slice()}),index:0})}if(null==t&&(t={data:[],index:0}),null===n&&(n={lastEffect:null,events:null,stores:null,memoCache:null},Hi.updateQueue=n),n.memoCache=t,void 0===(n=t.data[t.index]))for(n=t.data[t.index]=Array(e),r=0;r<e;r++)n[r]=R;return t.index++,n}function pa(e,t){return"function"==typeof t?t(e):t}function ha(e){return ga(ca(),Gi,e)}function ga(e,t,n){var r=e.queue;if(null===r)throw Error(a(311));r.lastRenderedReducer=n;var o=e.baseQueue,i=r.pending;if(null!==i){if(null!==o){var l=o.next;o.next=i.next,i.next=l}t.baseQueue=o=i,r.pending=null}if(i=e.baseState,null===o)e.memoizedState=i;else{var s=l=null,c=null,u=t=o.next,d=!1;do{var f=-536870913&u.lane;if(f!==u.lane?(mc&f)===f:($i&f)===f){var p=u.revertLane;if(0===p)null!==c&&(c=c.next={lane:0,revertLane:0,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),f===Go&&(d=!0);else{if(($i&p)===p){u=u.next,p===Go&&(d=!0);continue}f={lane:0,revertLane:u.revertLane,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},null===c?(s=c=f,l=i):c=c.next=f,Hi.lanes|=p,xc|=p}f=u.action,qi&&n(i,f),i=u.hasEagerState?u.eagerState:n(i,f)}else p={lane:f,revertLane:u.revertLane,gesture:u.gesture,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},null===c?(s=c=p,l=i):c=c.next=p,Hi.lanes|=f,xc|=f;u=u.next}while(null!==u&&u!==t);if(null===c?l=i:c.next=s,!Xn(i,e.memoizedState)&&(Tl=!0,d&&null!==(n=Vo)))throw n;e.memoizedState=i,e.baseState=l,e.baseQueue=c,r.lastRenderedState=i}return null===o&&(r.lanes=0),[e.memoizedState,r.dispatch]}function ma(e){var t=ca(),n=t.queue;if(null===n)throw Error(a(311));n.lastRenderedReducer=e;var r=n.dispatch,o=n.pending,i=t.memoizedState;if(null!==o){n.pending=null;var l=o=o.next;do{i=e(i,l.action),l=l.next}while(l!==o);Xn(i,t.memoizedState)||(Tl=!0),t.memoizedState=i,null===t.baseQueue&&(t.baseState=i),n.lastRenderedState=i}return[i,r]}function Aa(e,t,n){var r=Hi,o=ca(),i=fo;if(i){if(void 0===n)throw Error(a(407));n=n()}else n=t();var l=!Xn((Gi||o).memoizedState,n);if(l&&(o.memoizedState=n,Tl=!0),o=o.queue,$a(ya.bind(null,r,o,e),[e]),o.getSnapshot!==t||l||null!==Vi&&1&Vi.memoizedState.tag){if(r.flags|=2048,La(9,{destroy:void 0},va.bind(null,r,o,n,t),null),null===hc)throw Error(a(349));i||127&$i||ba(r,t,n)}return n}function ba(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},null===(t=Hi.updateQueue)?(t={lastEffect:null,events:null,stores:null,memoCache:null},Hi.updateQueue=t,t.stores=[e]):null===(n=t.stores)?t.stores=[e]:n.push(e)}function va(e,t,n,r){t.value=n,t.getSnapshot=r,wa(t)&&Ca(e)}function ya(e,t,n){return n(function(){wa(t)&&Ca(e)})}function wa(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!Xn(e,n)}catch(e){return!0}}function Ca(e){var t=Tr(e,2);null!==t&&qc(t,0,2)}function Sa(e){var t=sa();if("function"==typeof e){var n=e;if(e=n(),qi){ve(!0);try{n()}finally{ve(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:pa,lastRenderedState:e},t}function xa(e,t,n,r){return e.baseState=n,ga(e,Gi,"function"==typeof r?r:pa)}function Ea(e,t,n,r,o){if(fl(e))throw Error(a(485));if(null!==(e=t.action)){var i={payload:o,action:e,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(e){i.listeners.push(e)}};null!==O.T?n(!0):i.isTransition=!1,r(i),null===(n=t.pending)?(i.next=t.pending=i,Ia(t,i)):(i.next=n.next,t.pending=n.next=i)}}function Ia(e,t){var n=t.action,r=t.payload,o=e.state;if(t.isTransition){var i=O.T,a={};O.T=a;try{var l=n(o,r),s=O.S;null!==s&&s(a,l),ka(e,t,l)}catch(n){Ma(e,t,n)}finally{null!==i&&null!==a.types&&(i.types=a.types),O.T=i}}else try{ka(e,t,i=n(o,r))}catch(n){Ma(e,t,n)}}function ka(e,t,n){null!==n&&"object"==typeof n&&"function"==typeof n.then?n.then(function(n){Ra(e,t,n)},function(n){return Ma(e,t,n)}):Ra(e,t,n)}function Ra(e,t,n){t.status="fulfilled",t.value=n,Pa(t),e.state=n,null!==(t=e.pending)&&((n=t.next)===t?e.pending=null:(n=n.next,t.next=n,Ia(e,n)))}function Ma(e,t,n){var r=e.pending;if(e.pending=null,null!==r){r=r.next;do{t.status="rejected",t.reason=n,Pa(t),t=t.next}while(t!==r)}e.action=null}function Pa(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function Ba(e,t){return t}function _a(e,t){if(fo){var n=hc.formState;if(null!==n){e:{var r=Hi;if(fo){if(uo){t:{for(var o=uo,i=ho;8!==o.nodeType;){if(!i){o=null;break t}if(null===(o=Td(o.nextSibling))){o=null;break t}}o="F!"===(i=o.data)||"F"===i?o:null}if(o){uo=Td(o.nextSibling),r="F!"===o.data;break e}}mo(r)}r=!1}r&&(t=n[0])}}return(n=sa()).memoizedState=n.baseState=t,r={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ba,lastRenderedState:t},n.queue=r,n=cl.bind(null,Hi,r),r.dispatch=n,r=Sa(!1),i=dl.bind(null,Hi,!1,r.queue),o={state:t,dispatch:null,action:e,pending:null},(r=sa()).queue=o,n=Ea.bind(null,Hi,o,i,n),o.dispatch=n,r.memoizedState=e,[t,n,!1]}function Ta(e){return Oa(ca(),Gi,e)}function Oa(e,t,n){if(t=ga(e,t,Ba)[0],e=ha(pa)[0],"object"==typeof t&&null!==t&&"function"==typeof t.then)try{var r=ua(t)}catch(e){if(e===Xo)throw ei;throw e}else r=t;var o=(t=ca()).queue,i=o.dispatch;return n!==t.memoizedState&&(Hi.flags|=2048,La(9,{destroy:void 0},Da.bind(null,o,n),null)),[r,i,e]}function Da(e,t){e.action=t}function Na(e){var t=ca(),n=Gi;if(null!==n)return Oa(t,n,e);ca(),t=t.memoizedState;var r=(n=ca()).queue.dispatch;return n.memoizedState=e,[t,r,!1]}function La(e,t,n,r){return e={tag:e,create:n,deps:r,inst:t,next:null},null===(t=Hi.updateQueue)&&(t={lastEffect:null,events:null,stores:null,memoCache:null},Hi.updateQueue=t),null===(n=t.lastEffect)?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e),e}function Fa(){return ca().memoizedState}function Qa(e,t,n,r){var o=sa();Hi.flags|=e,o.memoizedState=La(1|t,{destroy:void 0},n,void 0===r?null:r)}function ja(e,t,n,r){var o=ca();r=void 0===r?null:r;var i=o.memoizedState.inst;null!==Gi&&null!==r&&ea(r,Gi.memoizedState.deps)?o.memoizedState=La(t,i,n,r):(Hi.flags|=e,o.memoizedState=La(1|t,i,n,r))}function za(e,t){Qa(8390656,8,e,t)}function $a(e,t){ja(2048,8,e,t)}function Ha(e){var t=ca().memoizedState;return function(e){Hi.flags|=4;var t=Hi.updateQueue;if(null===t)t={lastEffect:null,events:null,stores:null,memoCache:null},Hi.updateQueue=t,t.events=[e];else{var n=t.events;null===n?t.events=[e]:n.push(e)}}({ref:t,nextImpl:e}),function(){if(2&pc)throw Error(a(440));return t.impl.apply(void 0,arguments)}}function Ga(e,t){return ja(4,2,e,t)}function Va(e,t){return ja(4,4,e,t)}function Wa(e,t){if("function"==typeof t){e=e();var n=t(e);return function(){"function"==typeof n?n():t(null)}}if(null!=t)return e=e(),t.current=e,function(){t.current=null}}function Ua(e,t,n){n=null!=n?n.concat([e]):null,ja(4,4,Wa.bind(null,t,e),n)}function qa(){}function Ya(e,t){var n=ca();t=void 0===t?null:t;var r=n.memoizedState;return null!==t&&ea(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function Ka(e,t){var n=ca();t=void 0===t?null:t;var r=n.memoizedState;if(null!==t&&ea(t,r[1]))return r[0];if(r=e(),qi){ve(!0);try{e()}finally{ve(!1)}}return n.memoizedState=[r,t],r}function Ja(e,t,n){return void 0===n||1073741824&$i&&!(261930&mc)?e.memoizedState=t:(e.memoizedState=n,e=Uc(),Hi.lanes|=e,xc|=e,n)}function Xa(e,t,n,r){return Xn(n,t)?n:null!==Ri.current?(e=Ja(e,n,r),Xn(e,t)||(Tl=!0),e):42&$i&&(!(1073741824&$i)||261930&mc)?(e=Uc(),Hi.lanes|=e,xc|=e,t):(Tl=!0,e.memoizedState=n)}function Za(e,t,n,r,o){var i=D.p;D.p=0!==i&&8>i?i:8;var a,l,s,c=O.T,u={};O.T=u,dl(e,!1,t,n);try{var d=o(),f=O.S;null!==f&&f(u,d),null!==d&&"object"==typeof d&&"function"==typeof d.then?ul(e,t,(a=r,l=[],s={status:"pending",value:null,reason:null,then:function(e){l.push(e)}},d.then(function(){s.status="fulfilled",s.value=a;for(var e=0;e<l.length;e++)(0,l[e])(a)},function(e){for(s.status="rejected",s.reason=e,e=0;e<l.length;e++)(0,l[e])(void 0)}),s),Wc()):ul(e,t,r,Wc())}catch(n){ul(e,t,{then:function(){},status:"rejected",reason:n},Wc())}finally{D.p=i,null!==c&&null!==u.types&&(c.types=u.types),O.T=c}}function el(){}function tl(e,t,n,r){if(5!==e.tag)throw Error(a(476));var o=nl(e).queue;Za(e,o,t,N,null===n?el:function(){return rl(e),n(r)})}function nl(e){var t=e.memoizedState;if(null!==t)return t;var n={};return(t={memoizedState:N,baseState:N,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:pa,lastRenderedState:N},next:null}).next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:pa,lastRenderedState:n},next:null},e.memoizedState=t,null!==(e=e.alternate)&&(e.memoizedState=t),t}function rl(e){var t=nl(e);null===t.next&&(t=e.alternate.memoizedState),ul(e,t.next.queue,{},Wc())}function ol(){return To(df)}function il(){return ca().memoizedState}function al(){return ca().memoizedState}function ll(e){for(var t=e.return;null!==t;){switch(t.tag){case 24:case 3:var n=Wc(),r=yi(t,e=vi(n),n);return null!==r&&(qc(r,0,n),wi(r,t,n)),t={cache:jo()},void(e.payload=t)}t=t.return}}function sl(e,t,n){var r=Wc();n={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},fl(e)?pl(t,n):null!==(n=_r(e,t,n,r))&&(qc(n,0,r),hl(n,t,r))}function cl(e,t,n){ul(e,t,n,Wc())}function ul(e,t,n,r){var o={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(fl(e))pl(t,o);else{var i=e.alternate;if(0===e.lanes&&(null===i||0===i.lanes)&&null!==(i=t.lastRenderedReducer))try{var a=t.lastRenderedState,l=i(a,n);if(o.hasEagerState=!0,o.eagerState=l,Xn(l,a))return Br(e,t,o,0),null===hc&&Pr(),!1}catch(e){}if(null!==(n=_r(e,t,o,r)))return qc(n,0,r),hl(n,t,r),!0}return!1}function dl(e,t,n,r){if(r={lane:2,revertLane:$u(),gesture:null,action:r,hasEagerState:!1,eagerState:null,next:null},fl(e)){if(t)throw Error(a(479))}else null!==(t=_r(e,n,r,2))&&qc(t,0,2)}function fl(e){var t=e.alternate;return e===Hi||null!==t&&t===Hi}function pl(e,t){Ui=Wi=!0;var n=e.pending;null===n?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function hl(e,t,n){if(4194048&n){var r=t.lanes;n|=r&=e.pendingLanes,t.lanes=n,Oe(e,n)}}var gl={readContext:To,use:da,useCallback:Zi,useContext:Zi,useEffect:Zi,useImperativeHandle:Zi,useLayoutEffect:Zi,useInsertionEffect:Zi,useMemo:Zi,useReducer:Zi,useRef:Zi,useState:Zi,useDebugValue:Zi,useDeferredValue:Zi,useTransition:Zi,useSyncExternalStore:Zi,useId:Zi,useHostTransitionStatus:Zi,useFormState:Zi,useActionState:Zi,useOptimistic:Zi,useMemoCache:Zi,useCacheRefresh:Zi};gl.useEffectEvent=Zi;var ml={readContext:To,use:da,useCallback:function(e,t){return sa().memoizedState=[e,void 0===t?null:t],e},useContext:To,useEffect:za,useImperativeHandle:function(e,t,n){n=null!=n?n.concat([e]):null,Qa(4194308,4,Wa.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Qa(4194308,4,e,t)},useInsertionEffect:function(e,t){Qa(4,2,e,t)},useMemo:function(e,t){var n=sa();t=void 0===t?null:t;var r=e();if(qi){ve(!0);try{e()}finally{ve(!1)}}return n.memoizedState=[r,t],r},useReducer:function(e,t,n){var r=sa();if(void 0!==n){var o=n(t);if(qi){ve(!0);try{n(t)}finally{ve(!1)}}}else o=t;return r.memoizedState=r.baseState=o,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:o},r.queue=e,e=e.dispatch=sl.bind(null,Hi,e),[r.memoizedState,e]},useRef:function(e){return e={current:e},sa().memoizedState=e},useState:function(e){var t=(e=Sa(e)).queue,n=cl.bind(null,Hi,t);return t.dispatch=n,[e.memoizedState,n]},useDebugValue:qa,useDeferredValue:function(e,t){return Ja(sa(),e,t)},useTransition:function(){var e=Sa(!1);return e=Za.bind(null,Hi,e.queue,!0,!1),sa().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,n){var r=Hi,o=sa();if(fo){if(void 0===n)throw Error(a(407));n=n()}else{if(n=t(),null===hc)throw Error(a(349));127&mc||ba(r,t,n)}o.memoizedState=n;var i={value:n,getSnapshot:t};return o.queue=i,za(ya.bind(null,r,i,e),[e]),r.flags|=2048,La(9,{destroy:void 0},va.bind(null,r,i,n,t),null),n},useId:function(){var e=sa(),t=hc.identifierPrefix;if(fo){var n=ro;t="_"+t+"R_"+(n=(no&~(1<<32-ye(no)-1)).toString(32)+n),0<(n=Yi++)&&(t+="H"+n.toString(32)),t+="_"}else t="_"+t+"r_"+(n=Xi++).toString(32)+"_";return e.memoizedState=t},useHostTransitionStatus:ol,useFormState:_a,useActionState:_a,useOptimistic:function(e){var t=sa();t.memoizedState=t.baseState=e;var n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=n,t=dl.bind(null,Hi,!0,n),n.dispatch=t,[e,t]},useMemoCache:fa,useCacheRefresh:function(){return sa().memoizedState=ll.bind(null,Hi)},useEffectEvent:function(e){var t=sa(),n={impl:e};return t.memoizedState=n,function(){if(2&pc)throw Error(a(440));return n.impl.apply(void 0,arguments)}}},Al={readContext:To,use:da,useCallback:Ya,useContext:To,useEffect:$a,useImperativeHandle:Ua,useInsertionEffect:Ga,useLayoutEffect:Va,useMemo:Ka,useReducer:ha,useRef:Fa,useState:function(){return ha(pa)},useDebugValue:qa,useDeferredValue:function(e,t){return Xa(ca(),Gi.memoizedState,e,t)},useTransition:function(){var e=ha(pa)[0],t=ca().memoizedState;return["boolean"==typeof e?e:ua(e),t]},useSyncExternalStore:Aa,useId:il,useHostTransitionStatus:ol,useFormState:Ta,useActionState:Ta,useOptimistic:function(e,t){return xa(ca(),0,e,t)},useMemoCache:fa,useCacheRefresh:al};Al.useEffectEvent=Ha;var bl={readContext:To,use:da,useCallback:Ya,useContext:To,useEffect:$a,useImperativeHandle:Ua,useInsertionEffect:Ga,useLayoutEffect:Va,useMemo:Ka,useReducer:ma,useRef:Fa,useState:function(){return ma(pa)},useDebugValue:qa,useDeferredValue:function(e,t){var n=ca();return null===Gi?Ja(n,e,t):Xa(n,Gi.memoizedState,e,t)},useTransition:function(){var e=ma(pa)[0],t=ca().memoizedState;return["boolean"==typeof e?e:ua(e),t]},useSyncExternalStore:Aa,useId:il,useHostTransitionStatus:ol,useFormState:Na,useActionState:Na,useOptimistic:function(e,t){var n=ca();return null!==Gi?xa(n,0,e,t):(n.baseState=e,[e,n.queue.dispatch])},useMemoCache:fa,useCacheRefresh:al};function vl(e,t,n,r){n=null==(n=n(r,t=e.memoizedState))?t:p({},t,n),e.memoizedState=n,0===e.lanes&&(e.updateQueue.baseState=n)}bl.useEffectEvent=Ha;var yl={enqueueSetState:function(e,t,n){e=e._reactInternals;var r=Wc(),o=vi(r);o.payload=t,null!=n&&(o.callback=n),null!==(t=yi(e,o,r))&&(qc(t,0,r),wi(t,e,r))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=Wc(),o=vi(r);o.tag=1,o.payload=t,null!=n&&(o.callback=n),null!==(t=yi(e,o,r))&&(qc(t,0,r),wi(t,e,r))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=Wc(),r=vi(n);r.tag=2,null!=t&&(r.callback=t),null!==(t=yi(e,r,n))&&(qc(t,0,n),wi(t,e,n))}};function wl(e,t,n,r,o,i,a){return"function"==typeof(e=e.stateNode).shouldComponentUpdate?e.shouldComponentUpdate(r,i,a):!(t.prototype&&t.prototype.isPureReactComponent&&Zn(n,r)&&Zn(o,i))}function Cl(e,t,n,r){e=t.state,"function"==typeof t.componentWillReceiveProps&&t.componentWillReceiveProps(n,r),"function"==typeof t.UNSAFE_componentWillReceiveProps&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&yl.enqueueReplaceState(t,t.state,null)}function Sl(e,t){var n=t;if("ref"in t)for(var r in n={},t)"ref"!==r&&(n[r]=t[r]);if(e=e.defaultProps)for(var o in n===t&&(n=p({},n)),e)void 0===n[o]&&(n[o]=e[o]);return n}function xl(e){Ir(e)}function El(e){console.error(e)}function Il(e){Ir(e)}function kl(e,t){try{(0,e.onUncaughtError)(t.value,{componentStack:t.stack})}catch(e){setTimeout(function(){throw e})}}function Rl(e,t,n){try{(0,e.onCaughtError)(n.value,{componentStack:n.stack,errorBoundary:1===t.tag?t.stateNode:null})}catch(e){setTimeout(function(){throw e})}}function Ml(e,t,n){return(n=vi(n)).tag=3,n.payload={element:null},n.callback=function(){kl(e,t)},n}function Pl(e){return(e=vi(e)).tag=3,e}function Bl(e,t,n,r){var o=n.type.getDerivedStateFromError;if("function"==typeof o){var i=r.value;e.payload=function(){return o(i)},e.callback=function(){Rl(t,n,r)}}var a=n.stateNode;null!==a&&"function"==typeof a.componentDidCatch&&(e.callback=function(){Rl(t,n,r),"function"!=typeof o&&(null===Nc?Nc=new Set([this]):Nc.add(this));var e=r.stack;this.componentDidCatch(r.value,{componentStack:null!==e?e:""})})}var _l=Error(a(461)),Tl=!1;function Ol(e,t,n,r){t.child=null===e?gi(t,null,n,r):hi(t,e.child,n,r)}function Dl(e,t,n,r,o){n=n.render;var i=t.ref;if("ref"in r){var a={};for(var l in r)"ref"!==l&&(a[l]=r[l])}else a=r;return _o(t),r=ta(e,t,n,a,i,o),l=ia(),null===e||Tl?(fo&&l&&ao(t),t.flags|=1,Ol(e,t,r,o),t.child):(aa(e,t,o),os(e,t,o))}function Nl(e,t,n,r,o){if(null===e){var i=n.type;return"function"!=typeof i||Qr(i)||void 0!==i.defaultProps||null!==n.compare?((e=$r(n.type,null,r,t,t.mode,o)).ref=t.ref,e.return=t,t.child=e):(t.tag=15,t.type=i,Ll(e,t,i,r,o))}if(i=e.child,!is(e,o)){var a=i.memoizedProps;if((n=null!==(n=n.compare)?n:Zn)(a,r)&&e.ref===t.ref)return os(e,t,o)}return t.flags|=1,(e=jr(i,r)).ref=t.ref,e.return=t,t.child=e}function Ll(e,t,n,r,o){if(null!==e){var i=e.memoizedProps;if(Zn(i,r)&&e.ref===t.ref){if(Tl=!1,t.pendingProps=r=i,!is(e,o))return t.lanes=e.lanes,os(e,t,o);131072&e.flags&&(Tl=!0)}}return Gl(e,t,n,r,o)}function Fl(e,t,n,r){var o=r.children,i=null!==e?e.memoizedState:null;if(null===e&&null===t.stateNode&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),"hidden"===r.mode){if(128&t.flags){if(i=null!==i?i.baseLanes|n:n,null!==e){for(r=t.child=e.child,o=0;null!==r;)o=o|r.lanes|r.childLanes,r=r.sibling;r=o&~i}else r=0,t.child=null;return jl(e,t,i,n,r)}if(!(536870912&n))return r=t.lanes=536870912,jl(e,t,null!==i?i.baseLanes|n:n,n,r);t.memoizedState={baseLanes:0,cachePool:null},null!==e&&Ko(0,null!==i?i.cachePool:null),null!==i?Pi(t,i):Bi(),Li(t)}else null!==i?(Ko(0,i.cachePool),Pi(t,i),Fi(),t.memoizedState=null):(null!==e&&Ko(0,null),Bi(),Fi());return Ol(e,t,o,n),t.child}function Ql(e,t){return null!==e&&22===e.tag||null!==t.stateNode||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function jl(e,t,n,r,o){var i=Yo();return i=null===i?null:{parent:Qo._currentValue,pool:i},t.memoizedState={baseLanes:n,cachePool:i},null!==e&&Ko(0,null),Bi(),Li(t),null!==e&&Po(e,t,r,!0),t.childLanes=o,null}function zl(e,t){return(t=Zl({mode:t.mode,children:t.children},e.mode)).ref=e.ref,e.child=t,t.return=e,t}function $l(e,t,n){return hi(t,e.child,null,n),(e=zl(t,t.pendingProps)).flags|=2,Qi(t),t.memoizedState=null,e}function Hl(e,t){var n=t.ref;if(null===n)null!==e&&null!==e.ref&&(t.flags|=4194816);else{if("function"!=typeof n&&"object"!=typeof n)throw Error(a(284));null!==e&&e.ref===n||(t.flags|=4194816)}}function Gl(e,t,n,r,o){return _o(t),n=ta(e,t,n,r,void 0,o),r=ia(),null===e||Tl?(fo&&r&&ao(t),t.flags|=1,Ol(e,t,n,o),t.child):(aa(e,t,o),os(e,t,o))}function Vl(e,t,n,r,o,i){return _o(t),t.updateQueue=null,n=ra(t,r,n,o),na(e),r=ia(),null===e||Tl?(fo&&r&&ao(t),t.flags|=1,Ol(e,t,n,i),t.child):(aa(e,t,i),os(e,t,i))}function Wl(e,t,n,r,o){if(_o(t),null===t.stateNode){var i=Nr,a=n.contextType;"object"==typeof a&&null!==a&&(i=To(a)),i=new n(r,i),t.memoizedState=null!==i.state&&void 0!==i.state?i.state:null,i.updater=yl,t.stateNode=i,i._reactInternals=t,(i=t.stateNode).props=r,i.state=t.memoizedState,i.refs={},Ai(t),a=n.contextType,i.context="object"==typeof a&&null!==a?To(a):Nr,i.state=t.memoizedState,"function"==typeof(a=n.getDerivedStateFromProps)&&(vl(t,n,a,r),i.state=t.memoizedState),"function"==typeof n.getDerivedStateFromProps||"function"==typeof i.getSnapshotBeforeUpdate||"function"!=typeof i.UNSAFE_componentWillMount&&"function"!=typeof i.componentWillMount||(a=i.state,"function"==typeof i.componentWillMount&&i.componentWillMount(),"function"==typeof i.UNSAFE_componentWillMount&&i.UNSAFE_componentWillMount(),a!==i.state&&yl.enqueueReplaceState(i,i.state,null),Ei(t,r,i,o),xi(),i.state=t.memoizedState),"function"==typeof i.componentDidMount&&(t.flags|=4194308),r=!0}else if(null===e){i=t.stateNode;var l=t.memoizedProps,s=Sl(n,l);i.props=s;var c=i.context,u=n.contextType;a=Nr,"object"==typeof u&&null!==u&&(a=To(u));var d=n.getDerivedStateFromProps;u="function"==typeof d||"function"==typeof i.getSnapshotBeforeUpdate,l=t.pendingProps!==l,u||"function"!=typeof i.UNSAFE_componentWillReceiveProps&&"function"!=typeof i.componentWillReceiveProps||(l||c!==a)&&Cl(t,i,r,a),mi=!1;var f=t.memoizedState;i.state=f,Ei(t,r,i,o),xi(),c=t.memoizedState,l||f!==c||mi?("function"==typeof d&&(vl(t,n,d,r),c=t.memoizedState),(s=mi||wl(t,n,s,r,f,c,a))?(u||"function"!=typeof i.UNSAFE_componentWillMount&&"function"!=typeof i.componentWillMount||("function"==typeof i.componentWillMount&&i.componentWillMount(),"function"==typeof i.UNSAFE_componentWillMount&&i.UNSAFE_componentWillMount()),"function"==typeof i.componentDidMount&&(t.flags|=4194308)):("function"==typeof i.componentDidMount&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=c),i.props=r,i.state=c,i.context=a,r=s):("function"==typeof i.componentDidMount&&(t.flags|=4194308),r=!1)}else{i=t.stateNode,bi(e,t),u=Sl(n,a=t.memoizedProps),i.props=u,d=t.pendingProps,f=i.context,c=n.contextType,s=Nr,"object"==typeof c&&null!==c&&(s=To(c)),(c="function"==typeof(l=n.getDerivedStateFromProps)||"function"==typeof i.getSnapshotBeforeUpdate)||"function"!=typeof i.UNSAFE_componentWillReceiveProps&&"function"!=typeof i.componentWillReceiveProps||(a!==d||f!==s)&&Cl(t,i,r,s),mi=!1,f=t.memoizedState,i.state=f,Ei(t,r,i,o),xi();var p=t.memoizedState;a!==d||f!==p||mi||null!==e&&null!==e.dependencies&&Bo(e.dependencies)?("function"==typeof l&&(vl(t,n,l,r),p=t.memoizedState),(u=mi||wl(t,n,u,r,f,p,s)||null!==e&&null!==e.dependencies&&Bo(e.dependencies))?(c||"function"!=typeof i.UNSAFE_componentWillUpdate&&"function"!=typeof i.componentWillUpdate||("function"==typeof i.componentWillUpdate&&i.componentWillUpdate(r,p,s),"function"==typeof i.UNSAFE_componentWillUpdate&&i.UNSAFE_componentWillUpdate(r,p,s)),"function"==typeof i.componentDidUpdate&&(t.flags|=4),"function"==typeof i.getSnapshotBeforeUpdate&&(t.flags|=1024)):("function"!=typeof i.componentDidUpdate||a===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),"function"!=typeof i.getSnapshotBeforeUpdate||a===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=p),i.props=r,i.state=p,i.context=s,r=u):("function"!=typeof i.componentDidUpdate||a===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),"function"!=typeof i.getSnapshotBeforeUpdate||a===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),r=!1)}return i=r,Hl(e,t),r=!!(128&t.flags),i||r?(i=t.stateNode,n=r&&"function"!=typeof n.getDerivedStateFromError?null:i.render(),t.flags|=1,null!==e&&r?(t.child=hi(t,e.child,null,o),t.child=hi(t,null,n,o)):Ol(e,t,n,o),t.memoizedState=i.state,e=t.child):e=os(e,t,o),e}function Ul(e,t,n,r){return yo(),t.flags|=256,Ol(e,t,n,r),t.child}var ql={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function Yl(e){return{baseLanes:e,cachePool:Jo()}}function Kl(e,t,n){return e=null!==e?e.childLanes&~n:0,t&&(e|=kc),e}function Jl(e,t,n){var r,o=t.pendingProps,i=!1,l=!!(128&t.flags);if((r=l)||(r=(null===e||null!==e.memoizedState)&&!!(2&ji.current)),r&&(i=!0,t.flags&=-129),r=!!(32&t.flags),t.flags&=-33,null===e){if(fo){if(i?Di(t):Fi(),(e=uo)?null!==(e=null!==(e=Pd(e,ho))&&"&"!==e.data?e:null)&&(t.memoizedState={dehydrated:e,treeContext:null!==to?{id:no,overflow:ro}:null,retryLane:536870912,hydrationErrors:null},(n=Vr(e)).return=t,t.child=n,co=t,uo=null):e=null,null===e)throw mo(t);return _d(e)?t.lanes=32:t.lanes=536870912,null}var s=o.children;return o=o.fallback,i?(Fi(),s=Zl({mode:"hidden",children:s},i=t.mode),o=Hr(o,i,n,null),s.return=t,o.return=t,s.sibling=o,t.child=s,(o=t.child).memoizedState=Yl(n),o.childLanes=Kl(e,r,n),t.memoizedState=ql,Ql(null,o)):(Di(t),Xl(t,s))}var c=e.memoizedState;if(null!==c&&null!==(s=c.dehydrated)){if(l)256&t.flags?(Di(t),t.flags&=-257,t=es(e,t,n)):null!==t.memoizedState?(Fi(),t.child=e.child,t.flags|=128,t=null):(Fi(),s=o.fallback,i=t.mode,o=Zl({mode:"visible",children:o.children},i),(s=Hr(s,i,n,null)).flags|=2,o.return=t,s.return=t,o.sibling=s,t.child=o,hi(t,e.child,null,n),(o=t.child).memoizedState=Yl(n),o.childLanes=Kl(e,r,n),t.memoizedState=ql,t=Ql(null,o));else if(Di(t),_d(s)){if(r=s.nextSibling&&s.nextSibling.dataset)var u=r.dgst;r=u,(o=Error(a(419))).stack="",o.digest=r,Co({value:o,source:null,stack:null}),t=es(e,t,n)}else if(Tl||Po(e,t,n,!1),r=0!==(n&e.childLanes),Tl||r){if(null!==(r=hc)&&0!==(o=De(r,n))&&o!==c.retryLane)throw c.retryLane=o,Tr(e,o),qc(r,0,o),_l;Bd(s)||au(),t=es(e,t,n)}else Bd(s)?(t.flags|=192,t.child=e.child,t=null):(e=c.treeContext,uo=Td(s.nextSibling),co=t,fo=!0,po=null,ho=!1,null!==e&&so(t,e),(t=Xl(t,o.children)).flags|=4096);return t}return i?(Fi(),s=o.fallback,i=t.mode,u=(c=e.child).sibling,(o=jr(c,{mode:"hidden",children:o.children})).subtreeFlags=65011712&c.subtreeFlags,null!==u?s=jr(u,s):(s=Hr(s,i,n,null)).flags|=2,s.return=t,o.return=t,o.sibling=s,t.child=o,Ql(null,o),o=t.child,null===(s=e.child.memoizedState)?s=Yl(n):(null!==(i=s.cachePool)?(c=Qo._currentValue,i=i.parent!==c?{parent:c,pool:c}:i):i=Jo(),s={baseLanes:s.baseLanes|n,cachePool:i}),o.memoizedState=s,o.childLanes=Kl(e,r,n),t.memoizedState=ql,Ql(e.child,o)):(Di(t),e=(n=e.child).sibling,(n=jr(n,{mode:"visible",children:o.children})).return=t,n.sibling=null,null!==e&&(null===(r=t.deletions)?(t.deletions=[e],t.flags|=16):r.push(e)),t.child=n,t.memoizedState=null,n)}function Xl(e,t){return(t=Zl({mode:"visible",children:t},e.mode)).return=e,e.child=t}function Zl(e,t){return(e=Fr(22,e,null,t)).lanes=0,e}function es(e,t,n){return hi(t,e.child,null,n),(e=Xl(t,t.pendingProps.children)).flags|=2,t.memoizedState=null,e}function ts(e,t,n){e.lanes|=t;var r=e.alternate;null!==r&&(r.lanes|=t),Ro(e.return,t,n)}function ns(e,t,n,r,o,i){var a=e.memoizedState;null===a?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:o,treeForkCount:i}:(a.isBackwards=t,a.rendering=null,a.renderingStartTime=0,a.last=r,a.tail=n,a.tailMode=o,a.treeForkCount=i)}function rs(e,t,n){var r=t.pendingProps,o=r.revealOrder,i=r.tail;r=r.children;var a=ji.current,l=!!(2&a);if(l?(a=1&a|2,t.flags|=128):a&=1,z(ji,a),Ol(e,t,r,n),r=fo?Xr:0,!l&&null!==e&&128&e.flags)e:for(e=t.child;null!==e;){if(13===e.tag)null!==e.memoizedState&&ts(e,n,t);else if(19===e.tag)ts(e,n,t);else if(null!==e.child){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;null===e.sibling;){if(null===e.return||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(o){case"forwards":for(n=t.child,o=null;null!==n;)null!==(e=n.alternate)&&null===zi(e)&&(o=n),n=n.sibling;null===(n=o)?(o=t.child,t.child=null):(o=n.sibling,n.sibling=null),ns(t,!1,o,n,i,r);break;case"backwards":case"unstable_legacy-backwards":for(n=null,o=t.child,t.child=null;null!==o;){if(null!==(e=o.alternate)&&null===zi(e)){t.child=o;break}e=o.sibling,o.sibling=n,n=o,o=e}ns(t,!0,n,null,i,r);break;case"together":ns(t,!1,null,null,void 0,r);break;default:t.memoizedState=null}return t.child}function os(e,t,n){if(null!==e&&(t.dependencies=e.dependencies),xc|=t.lanes,0===(n&t.childLanes)){if(null===e)return null;if(Po(e,t,n,!1),0===(n&t.childLanes))return null}if(null!==e&&t.child!==e.child)throw Error(a(153));if(null!==t.child){for(n=jr(e=t.child,e.pendingProps),t.child=n,n.return=t;null!==e.sibling;)e=e.sibling,(n=n.sibling=jr(e,e.pendingProps)).return=t;n.sibling=null}return t.child}function is(e,t){return 0!==(e.lanes&t)||!(null===(e=e.dependencies)||!Bo(e))}function as(e,t,n){if(null!==e)if(e.memoizedProps!==t.pendingProps)Tl=!0;else{if(!(is(e,n)||128&t.flags))return Tl=!1,function(e,t,n){switch(t.tag){case 3:q(t,t.stateNode.containerInfo),Io(0,Qo,e.memoizedState.cache),yo();break;case 27:case 5:K(t);break;case 4:q(t,t.stateNode.containerInfo);break;case 10:Io(0,t.type,t.memoizedProps.value);break;case 31:if(null!==t.memoizedState)return t.flags|=128,Ni(t),null;break;case 13:var r=t.memoizedState;if(null!==r)return null!==r.dehydrated?(Di(t),t.flags|=128,null):0!==(n&t.child.childLanes)?Jl(e,t,n):(Di(t),null!==(e=os(e,t,n))?e.sibling:null);Di(t);break;case 19:var o=!!(128&e.flags);if((r=0!==(n&t.childLanes))||(Po(e,t,n,!1),r=0!==(n&t.childLanes)),o){if(r)return rs(e,t,n);t.flags|=128}if(null!==(o=t.memoizedState)&&(o.rendering=null,o.tail=null,o.lastEffect=null),z(ji,ji.current),r)break;return null;case 22:return t.lanes=0,Fl(e,t,n,t.pendingProps);case 24:Io(0,Qo,e.memoizedState.cache)}return os(e,t,n)}(e,t,n);Tl=!!(131072&e.flags)}else Tl=!1,fo&&1048576&t.flags&&io(t,Xr,t.index);switch(t.lanes=0,t.tag){case 16:e:{var r=t.pendingProps;if(e=oi(t.elementType),t.type=e,"function"!=typeof e){if(null!=e){var o=e.$$typeof;if(o===C){t.tag=11,t=Dl(null,t,e,r,n);break e}if(o===E){t.tag=14,t=Nl(null,t,e,r,n);break e}}throw t=_(e)||e,Error(a(306,t,""))}Qr(e)?(r=Sl(e,r),t.tag=1,t=Wl(null,t,e,r,n)):(t.tag=0,t=Gl(null,t,e,r,n))}return t;case 0:return Gl(e,t,t.type,t.pendingProps,n);case 1:return Wl(e,t,r=t.type,o=Sl(r,t.pendingProps),n);case 3:e:{if(q(t,t.stateNode.containerInfo),null===e)throw Error(a(387));r=t.pendingProps;var i=t.memoizedState;o=i.element,bi(e,t),Ei(t,r,null,n);var l=t.memoizedState;if(r=l.cache,Io(0,Qo,r),r!==i.cache&&Mo(t,[Qo],n,!0),xi(),r=l.element,i.isDehydrated){if(i={element:r,isDehydrated:!1,cache:l.cache},t.updateQueue.baseState=i,t.memoizedState=i,256&t.flags){t=Ul(e,t,r,n);break e}if(r!==o){Co(o=qr(Error(a(424)),t)),t=Ul(e,t,r,n);break e}for(e=9===(e=t.stateNode.containerInfo).nodeType?e.body:"HTML"===e.nodeName?e.ownerDocument.body:e,uo=Td(e.firstChild),co=t,fo=!0,po=null,ho=!0,n=gi(t,null,r,n),t.child=n;n;)n.flags=-3&n.flags|4096,n=n.sibling}else{if(yo(),r===o){t=os(e,t,n);break e}Ol(e,t,r,n)}t=t.child}return t;case 26:return Hl(e,t),null===e?(n=Vd(t.type,null,t.pendingProps,null))?t.memoizedState=n:fo||(n=t.type,e=t.pendingProps,(r=md(W.current).createElement(n))[ze]=t,r[$e]=e,fd(r,n,e),et(r),t.stateNode=r):t.memoizedState=Vd(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return K(t),null===e&&fo&&(r=t.stateNode=Ld(t.type,t.pendingProps,W.current),co=t,ho=!0,o=uo,Id(t.type)?(Od=o,uo=Td(r.firstChild)):uo=o),Ol(e,t,t.pendingProps.children,n),Hl(e,t),null===e&&(t.flags|=4194304),t.child;case 5:return null===e&&fo&&((o=r=uo)&&(null!==(r=function(e,t,n,r){for(;1===e.nodeType;){var o=n;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!r&&("INPUT"!==e.nodeName||"hidden"!==e.type))break}else if(r){if(!e[qe])switch(t){case"meta":if(!e.hasAttribute("itemprop"))break;return e;case"link":if("stylesheet"===(i=e.getAttribute("rel"))&&e.hasAttribute("data-precedence"))break;if(i!==o.rel||e.getAttribute("href")!==(null==o.href||""===o.href?null:o.href)||e.getAttribute("crossorigin")!==(null==o.crossOrigin?null:o.crossOrigin)||e.getAttribute("title")!==(null==o.title?null:o.title))break;return e;case"style":if(e.hasAttribute("data-precedence"))break;return e;case"script":if(((i=e.getAttribute("src"))!==(null==o.src?null:o.src)||e.getAttribute("type")!==(null==o.type?null:o.type)||e.getAttribute("crossorigin")!==(null==o.crossOrigin?null:o.crossOrigin))&&i&&e.hasAttribute("async")&&!e.hasAttribute("itemprop"))break;return e;default:return e}}else{if("input"!==t||"hidden"!==e.type)return e;var i=null==o.name?null:""+o.name;if("hidden"===o.type&&e.getAttribute("name")===i)return e}if(null===(e=Td(e.nextSibling)))break}return null}(r,t.type,t.pendingProps,ho))?(t.stateNode=r,co=t,uo=Td(r.firstChild),ho=!1,o=!0):o=!1),o||mo(t)),K(t),o=t.type,i=t.pendingProps,l=null!==e?e.memoizedProps:null,r=i.children,vd(o,i)?r=null:null!==l&&vd(o,l)&&(t.flags|=32),null!==t.memoizedState&&(o=ta(e,t,oa,null,null,n),df._currentValue=o),Hl(e,t),Ol(e,t,r,n),t.child;case 6:return null===e&&fo&&((e=n=uo)&&(null!==(n=function(e,t,n){if(""===t)return null;for(;3!==e.nodeType;){if((1!==e.nodeType||"INPUT"!==e.nodeName||"hidden"!==e.type)&&!n)return null;if(null===(e=Td(e.nextSibling)))return null}return e}(n,t.pendingProps,ho))?(t.stateNode=n,co=t,uo=null,e=!0):e=!1),e||mo(t)),null;case 13:return Jl(e,t,n);case 4:return q(t,t.stateNode.containerInfo),r=t.pendingProps,null===e?t.child=hi(t,null,r,n):Ol(e,t,r,n),t.child;case 11:return Dl(e,t,t.type,t.pendingProps,n);case 7:return Ol(e,t,t.pendingProps,n),t.child;case 8:case 12:return Ol(e,t,t.pendingProps.children,n),t.child;case 10:return r=t.pendingProps,Io(0,t.type,r.value),Ol(e,t,r.children,n),t.child;case 9:return o=t.type._context,r=t.pendingProps.children,_o(t),r=r(o=To(o)),t.flags|=1,Ol(e,t,r,n),t.child;case 14:return Nl(e,t,t.type,t.pendingProps,n);case 15:return Ll(e,t,t.type,t.pendingProps,n);case 19:return rs(e,t,n);case 31:return function(e,t,n){var r=t.pendingProps,o=!!(128&t.flags);if(t.flags&=-129,null===e){if(fo){if("hidden"===r.mode)return e=zl(t,r),t.lanes=536870912,Ql(null,e);if(Ni(t),(e=uo)?null!==(e=null!==(e=Pd(e,ho))&&"&"===e.data?e:null)&&(t.memoizedState={dehydrated:e,treeContext:null!==to?{id:no,overflow:ro}:null,retryLane:536870912,hydrationErrors:null},(n=Vr(e)).return=t,t.child=n,co=t,uo=null):e=null,null===e)throw mo(t);return t.lanes=536870912,null}return zl(t,r)}var i=e.memoizedState;if(null!==i){var l=i.dehydrated;if(Ni(t),o)if(256&t.flags)t.flags&=-257,t=$l(e,t,n);else{if(null===t.memoizedState)throw Error(a(558));t.child=e.child,t.flags|=128,t=null}else if(Tl||Po(e,t,n,!1),o=0!==(n&e.childLanes),Tl||o){if(null!==(r=hc)&&0!==(l=De(r,n))&&l!==i.retryLane)throw i.retryLane=l,Tr(e,l),qc(r,0,l),_l;au(),t=$l(e,t,n)}else e=i.treeContext,uo=Td(l.nextSibling),co=t,fo=!0,po=null,ho=!1,null!==e&&so(t,e),(t=zl(t,r)).flags|=4096;return t}return(e=jr(e.child,{mode:r.mode,children:r.children})).ref=t.ref,t.child=e,e.return=t,e}(e,t,n);case 22:return Fl(e,t,n,t.pendingProps);case 24:return _o(t),r=To(Qo),null===e?(null===(o=Yo())&&(o=hc,i=jo(),o.pooledCache=i,i.refCount++,null!==i&&(o.pooledCacheLanes|=n),o=i),t.memoizedState={parent:r,cache:o},Ai(t),Io(0,Qo,o)):(0!==(e.lanes&n)&&(bi(e,t),Ei(t,null,null,n),xi()),o=e.memoizedState,i=t.memoizedState,o.parent!==r?(o={parent:r,cache:r},t.memoizedState=o,0===t.lanes&&(t.memoizedState=t.updateQueue.baseState=o),Io(0,Qo,r)):(r=i.cache,Io(0,Qo,r),r!==o.cache&&Mo(t,[Qo],n,!0))),Ol(e,t,t.pendingProps.children,n),t.child;case 29:throw t.pendingProps}throw Error(a(156,t.tag))}function ls(e){e.flags|=4}function ss(e,t,n,r,o){if((t=!!(32&e.mode))&&(t=!1),t){if(e.flags|=16777216,(335544128&o)===o)if(e.stateNode.complete)e.flags|=8192;else{if(!ru())throw ii=ti,Zo;e.flags|=8192}}else e.flags&=-16777217}function cs(e,t){if("stylesheet"!==t.type||4&t.state.loading)e.flags&=-16777217;else if(e.flags|=16777216,!of(t)){if(!ru())throw ii=ti,Zo;e.flags|=8192}}function us(e,t){null!==t&&(e.flags|=4),16384&e.flags&&(t=22!==e.tag?Pe():536870912,e.lanes|=t,Rc|=t)}function ds(e,t){if(!fo)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;null!==t;)null!==t.alternate&&(n=t),t=t.sibling;null===n?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var r=null;null!==n;)null!==n.alternate&&(r=n),n=n.sibling;null===r?t||null===e.tail?e.tail=null:e.tail.sibling=null:r.sibling=null}}function fs(e){var t=null!==e.alternate&&e.alternate.child===e.child,n=0,r=0;if(t)for(var o=e.child;null!==o;)n|=o.lanes|o.childLanes,r|=65011712&o.subtreeFlags,r|=65011712&o.flags,o.return=e,o=o.sibling;else for(o=e.child;null!==o;)n|=o.lanes|o.childLanes,r|=o.subtreeFlags,r|=o.flags,o.return=e,o=o.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function ps(e,t,n){var r=t.pendingProps;switch(lo(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:case 1:return fs(t),null;case 3:return n=t.stateNode,r=null,null!==e&&(r=e.memoizedState.cache),t.memoizedState.cache!==r&&(t.flags|=2048),ko(Qo),Y(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),null!==e&&null!==e.child||(vo(t)?ls(t):null===e||e.memoizedState.isDehydrated&&!(256&t.flags)||(t.flags|=1024,wo())),fs(t),null;case 26:var o=t.type,i=t.memoizedState;return null===e?(ls(t),null!==i?(fs(t),cs(t,i)):(fs(t),ss(t,o,0,0,n))):i?i!==e.memoizedState?(ls(t),fs(t),cs(t,i)):(fs(t),t.flags&=-16777217):((e=e.memoizedProps)!==r&&ls(t),fs(t),ss(t,o,0,0,n)),null;case 27:if(J(t),n=W.current,o=t.type,null!==e&&null!=t.stateNode)e.memoizedProps!==r&&ls(t);else{if(!r){if(null===t.stateNode)throw Error(a(166));return fs(t),null}e=G.current,vo(t)?Ao(t):(e=Ld(o,r,n),t.stateNode=e,ls(t))}return fs(t),null;case 5:if(J(t),o=t.type,null!==e&&null!=t.stateNode)e.memoizedProps!==r&&ls(t);else{if(!r){if(null===t.stateNode)throw Error(a(166));return fs(t),null}if(i=G.current,vo(t))Ao(t);else{var l=md(W.current);switch(i){case 1:i=l.createElementNS("http://www.w3.org/2000/svg",o);break;case 2:i=l.createElementNS("http://www.w3.org/1998/Math/MathML",o);break;default:switch(o){case"svg":i=l.createElementNS("http://www.w3.org/2000/svg",o);break;case"math":i=l.createElementNS("http://www.w3.org/1998/Math/MathML",o);break;case"script":(i=l.createElement("div")).innerHTML="<script><\/script>",i=i.removeChild(i.firstChild);break;case"select":i="string"==typeof r.is?l.createElement("select",{is:r.is}):l.createElement("select"),r.multiple?i.multiple=!0:r.size&&(i.size=r.size);break;default:i="string"==typeof r.is?l.createElement(o,{is:r.is}):l.createElement(o)}}i[ze]=t,i[$e]=r;e:for(l=t.child;null!==l;){if(5===l.tag||6===l.tag)i.appendChild(l.stateNode);else if(4!==l.tag&&27!==l.tag&&null!==l.child){l.child.return=l,l=l.child;continue}if(l===t)break e;for(;null===l.sibling;){if(null===l.return||l.return===t)break e;l=l.return}l.sibling.return=l.return,l=l.sibling}t.stateNode=i;e:switch(fd(i,o,r),o){case"button":case"input":case"select":case"textarea":r=!!r.autoFocus;break e;case"img":r=!0;break e;default:r=!1}r&&ls(t)}}return fs(t),ss(t,t.type,null===e||e.memoizedProps,t.pendingProps,n),null;case 6:if(e&&null!=t.stateNode)e.memoizedProps!==r&&ls(t);else{if("string"!=typeof r&&null===t.stateNode)throw Error(a(166));if(e=W.current,vo(t)){if(e=t.stateNode,n=t.memoizedProps,r=null,null!==(o=co))switch(o.tag){case 27:case 5:r=o.memoizedProps}e[ze]=t,(e=!!(e.nodeValue===n||null!==r&&!0===r.suppressHydrationWarning||cd(e.nodeValue,n)))||mo(t,!0)}else(e=md(e).createTextNode(r))[ze]=t,t.stateNode=e}return fs(t),null;case 31:if(n=t.memoizedState,null===e||null!==e.memoizedState){if(r=vo(t),null!==n){if(null===e){if(!r)throw Error(a(318));if(!(e=null!==(e=t.memoizedState)?e.dehydrated:null))throw Error(a(557));e[ze]=t}else yo(),!(128&t.flags)&&(t.memoizedState=null),t.flags|=4;fs(t),e=!1}else n=wo(),null!==e&&null!==e.memoizedState&&(e.memoizedState.hydrationErrors=n),e=!0;if(!e)return 256&t.flags?(Qi(t),t):(Qi(t),null);if(128&t.flags)throw Error(a(558))}return fs(t),null;case 13:if(r=t.memoizedState,null===e||null!==e.memoizedState&&null!==e.memoizedState.dehydrated){if(o=vo(t),null!==r&&null!==r.dehydrated){if(null===e){if(!o)throw Error(a(318));if(!(o=null!==(o=t.memoizedState)?o.dehydrated:null))throw Error(a(317));o[ze]=t}else yo(),!(128&t.flags)&&(t.memoizedState=null),t.flags|=4;fs(t),o=!1}else o=wo(),null!==e&&null!==e.memoizedState&&(e.memoizedState.hydrationErrors=o),o=!0;if(!o)return 256&t.flags?(Qi(t),t):(Qi(t),null)}return Qi(t),128&t.flags?(t.lanes=n,t):(n=null!==r,e=null!==e&&null!==e.memoizedState,n&&(o=null,null!==(r=t.child).alternate&&null!==r.alternate.memoizedState&&null!==r.alternate.memoizedState.cachePool&&(o=r.alternate.memoizedState.cachePool.pool),i=null,null!==r.memoizedState&&null!==r.memoizedState.cachePool&&(i=r.memoizedState.cachePool.pool),i!==o&&(r.flags|=2048)),n!==e&&n&&(t.child.flags|=8192),us(t,t.updateQueue),fs(t),null);case 4:return Y(),null===e&&Zu(t.stateNode.containerInfo),fs(t),null;case 10:return ko(t.type),fs(t),null;case 19:if(j(ji),null===(r=t.memoizedState))return fs(t),null;if(o=!!(128&t.flags),null===(i=r.rendering))if(o)ds(r,!1);else{if(0!==Sc||null!==e&&128&e.flags)for(e=t.child;null!==e;){if(null!==(i=zi(e))){for(t.flags|=128,ds(r,!1),e=i.updateQueue,t.updateQueue=e,us(t,e),t.subtreeFlags=0,e=n,n=t.child;null!==n;)zr(n,e),n=n.sibling;return z(ji,1&ji.current|2),fo&&oo(t,r.treeForkCount),t.child}e=e.sibling}null!==r.tail&&se()>Oc&&(t.flags|=128,o=!0,ds(r,!1),t.lanes=4194304)}else{if(!o)if(null!==(e=zi(i))){if(t.flags|=128,o=!0,e=e.updateQueue,t.updateQueue=e,us(t,e),ds(r,!0),null===r.tail&&"hidden"===r.tailMode&&!i.alternate&&!fo)return fs(t),null}else 2*se()-r.renderingStartTime>Oc&&536870912!==n&&(t.flags|=128,o=!0,ds(r,!1),t.lanes=4194304);r.isBackwards?(i.sibling=t.child,t.child=i):(null!==(e=r.last)?e.sibling=i:t.child=i,r.last=i)}return null!==r.tail?(e=r.tail,r.rendering=e,r.tail=e.sibling,r.renderingStartTime=se(),e.sibling=null,n=ji.current,z(ji,o?1&n|2:1&n),fo&&oo(t,r.treeForkCount),e):(fs(t),null);case 22:case 23:return Qi(t),_i(),r=null!==t.memoizedState,null!==e?null!==e.memoizedState!==r&&(t.flags|=8192):r&&(t.flags|=8192),r?!!(536870912&n)&&!(128&t.flags)&&(fs(t),6&t.subtreeFlags&&(t.flags|=8192)):fs(t),null!==(n=t.updateQueue)&&us(t,n.retryQueue),n=null,null!==e&&null!==e.memoizedState&&null!==e.memoizedState.cachePool&&(n=e.memoizedState.cachePool.pool),r=null,null!==t.memoizedState&&null!==t.memoizedState.cachePool&&(r=t.memoizedState.cachePool.pool),r!==n&&(t.flags|=2048),null!==e&&j(qo),null;case 24:return n=null,null!==e&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),ko(Qo),fs(t),null;case 25:case 30:return null}throw Error(a(156,t.tag))}function hs(e,t){switch(lo(t),t.tag){case 1:return 65536&(e=t.flags)?(t.flags=-65537&e|128,t):null;case 3:return ko(Qo),Y(),65536&(e=t.flags)&&!(128&e)?(t.flags=-65537&e|128,t):null;case 26:case 27:case 5:return J(t),null;case 31:if(null!==t.memoizedState){if(Qi(t),null===t.alternate)throw Error(a(340));yo()}return 65536&(e=t.flags)?(t.flags=-65537&e|128,t):null;case 13:if(Qi(t),null!==(e=t.memoizedState)&&null!==e.dehydrated){if(null===t.alternate)throw Error(a(340));yo()}return 65536&(e=t.flags)?(t.flags=-65537&e|128,t):null;case 19:return j(ji),null;case 4:return Y(),null;case 10:return ko(t.type),null;case 22:case 23:return Qi(t),_i(),null!==e&&j(qo),65536&(e=t.flags)?(t.flags=-65537&e|128,t):null;case 24:return ko(Qo),null;default:return null}}function gs(e,t){switch(lo(t),t.tag){case 3:ko(Qo),Y();break;case 26:case 27:case 5:J(t);break;case 4:Y();break;case 31:null!==t.memoizedState&&Qi(t);break;case 13:Qi(t);break;case 19:j(ji);break;case 10:ko(t.type);break;case 22:case 23:Qi(t),_i(),null!==e&&j(qo);break;case 24:ko(Qo)}}function ms(e,t){try{var n=t.updateQueue,r=null!==n?n.lastEffect:null;if(null!==r){var o=r.next;n=o;do{if((n.tag&e)===e){r=void 0;var i=n.create,a=n.inst;r=i(),a.destroy=r}n=n.next}while(n!==o)}}catch(e){Su(t,t.return,e)}}function As(e,t,n){try{var r=t.updateQueue,o=null!==r?r.lastEffect:null;if(null!==o){var i=o.next;r=i;do{if((r.tag&e)===e){var a=r.inst,l=a.destroy;if(void 0!==l){a.destroy=void 0,o=t;var s=n,c=l;try{c()}catch(e){Su(o,s,e)}}}r=r.next}while(r!==i)}}catch(e){Su(t,t.return,e)}}function bs(e){var t=e.updateQueue;if(null!==t){var n=e.stateNode;try{ki(t,n)}catch(t){Su(e,e.return,t)}}}function vs(e,t,n){n.props=Sl(e.type,e.memoizedProps),n.state=e.memoizedState;try{n.componentWillUnmount()}catch(n){Su(e,t,n)}}function ys(e,t){try{var n=e.ref;if(null!==n){switch(e.tag){case 26:case 27:case 5:var r=e.stateNode;break;default:r=e.stateNode}"function"==typeof n?e.refCleanup=n(r):n.current=r}}catch(n){Su(e,t,n)}}function ws(e,t){var n=e.ref,r=e.refCleanup;if(null!==n)if("function"==typeof r)try{r()}catch(n){Su(e,t,n)}finally{e.refCleanup=null,null!=(e=e.alternate)&&(e.refCleanup=null)}else if("function"==typeof n)try{n(null)}catch(n){Su(e,t,n)}else n.current=null}function Cs(e){var t=e.type,n=e.memoizedProps,r=e.stateNode;try{e:switch(t){case"button":case"input":case"select":case"textarea":n.autoFocus&&r.focus();break e;case"img":n.src?r.src=n.src:n.srcSet&&(r.srcset=n.srcSet)}}catch(t){Su(e,e.return,t)}}function Ss(e,t,n){try{var r=e.stateNode;!function(e,t,n,r){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var o=null,i=null,l=null,s=null,c=null,u=null,d=null;for(h in n){var f=n[h];if(n.hasOwnProperty(h)&&null!=f)switch(h){case"checked":case"value":break;case"defaultValue":c=f;default:r.hasOwnProperty(h)||ud(e,t,h,null,r,f)}}for(var p in r){var h=r[p];if(f=n[p],r.hasOwnProperty(p)&&(null!=h||null!=f))switch(p){case"type":i=h;break;case"name":o=h;break;case"checked":u=h;break;case"defaultChecked":d=h;break;case"value":l=h;break;case"defaultValue":s=h;break;case"children":case"dangerouslySetInnerHTML":if(null!=h)throw Error(a(137,t));break;default:h!==f&&ud(e,t,p,h,r,f)}}return void bt(e,l,s,c,u,d,i,o);case"select":for(i in h=l=s=p=null,n)if(c=n[i],n.hasOwnProperty(i)&&null!=c)switch(i){case"value":break;case"multiple":h=c;default:r.hasOwnProperty(i)||ud(e,t,i,null,r,c)}for(o in r)if(i=r[o],c=n[o],r.hasOwnProperty(o)&&(null!=i||null!=c))switch(o){case"value":p=i;break;case"defaultValue":s=i;break;case"multiple":l=i;default:i!==c&&ud(e,t,o,i,r,c)}return t=s,n=l,r=h,void(null!=p?wt(e,!!n,p,!1):!!r!=!!n&&(null!=t?wt(e,!!n,t,!0):wt(e,!!n,n?[]:"",!1)));case"textarea":for(s in h=p=null,n)if(o=n[s],n.hasOwnProperty(s)&&null!=o&&!r.hasOwnProperty(s))switch(s){case"value":case"children":break;default:ud(e,t,s,null,r,o)}for(l in r)if(o=r[l],i=n[l],r.hasOwnProperty(l)&&(null!=o||null!=i))switch(l){case"value":p=o;break;case"defaultValue":h=o;break;case"children":break;case"dangerouslySetInnerHTML":if(null!=o)throw Error(a(91));break;default:o!==i&&ud(e,t,l,o,r,i)}return void Ct(e,p,h);case"option":for(var g in n)p=n[g],n.hasOwnProperty(g)&&null!=p&&!r.hasOwnProperty(g)&&("selected"===g?e.selected=!1:ud(e,t,g,null,r,p));for(c in r)p=r[c],h=n[c],!r.hasOwnProperty(c)||p===h||null==p&&null==h||("selected"===c?e.selected=p&&"function"!=typeof p&&"symbol"!=typeof p:ud(e,t,c,p,r,h));return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var m in n)p=n[m],n.hasOwnProperty(m)&&null!=p&&!r.hasOwnProperty(m)&&ud(e,t,m,null,r,p);for(u in r)if(p=r[u],h=n[u],r.hasOwnProperty(u)&&p!==h&&(null!=p||null!=h))switch(u){case"children":case"dangerouslySetInnerHTML":if(null!=p)throw Error(a(137,t));break;default:ud(e,t,u,p,r,h)}return;default:if(Rt(t)){for(var A in n)p=n[A],n.hasOwnProperty(A)&&void 0!==p&&!r.hasOwnProperty(A)&&dd(e,t,A,void 0,r,p);for(d in r)p=r[d],h=n[d],!r.hasOwnProperty(d)||p===h||void 0===p&&void 0===h||dd(e,t,d,p,r,h);return}}for(var b in n)p=n[b],n.hasOwnProperty(b)&&null!=p&&!r.hasOwnProperty(b)&&ud(e,t,b,null,r,p);for(f in r)p=r[f],h=n[f],!r.hasOwnProperty(f)||p===h||null==p&&null==h||ud(e,t,f,p,r,h)}(r,e.type,n,t),r[$e]=t}catch(t){Su(e,e.return,t)}}function xs(e){return 5===e.tag||3===e.tag||26===e.tag||27===e.tag&&Id(e.type)||4===e.tag}function Es(e){e:for(;;){for(;null===e.sibling;){if(null===e.return||xs(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;5!==e.tag&&6!==e.tag&&18!==e.tag;){if(27===e.tag&&Id(e.type))continue e;if(2&e.flags)continue e;if(null===e.child||4===e.tag)continue e;e.child.return=e,e=e.child}if(!(2&e.flags))return e.stateNode}}function Is(e,t,n){var r=e.tag;if(5===r||6===r)e=e.stateNode,t?(9===n.nodeType?n.body:"HTML"===n.nodeName?n.ownerDocument.body:n).insertBefore(e,t):((t=9===n.nodeType?n.body:"HTML"===n.nodeName?n.ownerDocument.body:n).appendChild(e),null!=(n=n._reactRootContainer)||null!==t.onclick||(t.onclick=_t));else if(4!==r&&(27===r&&Id(e.type)&&(n=e.stateNode,t=null),null!==(e=e.child)))for(Is(e,t,n),e=e.sibling;null!==e;)Is(e,t,n),e=e.sibling}function ks(e,t,n){var r=e.tag;if(5===r||6===r)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(4!==r&&(27===r&&Id(e.type)&&(n=e.stateNode),null!==(e=e.child)))for(ks(e,t,n),e=e.sibling;null!==e;)ks(e,t,n),e=e.sibling}function Rs(e){var t=e.stateNode,n=e.memoizedProps;try{for(var r=e.type,o=t.attributes;o.length;)t.removeAttributeNode(o[0]);fd(t,r,n),t[ze]=e,t[$e]=n}catch(t){Su(e,e.return,t)}}var Ms=!1,Ps=!1,Bs=!1,_s="function"==typeof WeakSet?WeakSet:Set,Ts=null;function Os(e,t,n){var r=n.flags;switch(n.tag){case 0:case 11:case 15:qs(e,n),4&r&&ms(5,n);break;case 1:if(qs(e,n),4&r)if(e=n.stateNode,null===t)try{e.componentDidMount()}catch(e){Su(n,n.return,e)}else{var o=Sl(n.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(o,t,e.__reactInternalSnapshotBeforeUpdate)}catch(e){Su(n,n.return,e)}}64&r&&bs(n),512&r&&ys(n,n.return);break;case 3:if(qs(e,n),64&r&&null!==(e=n.updateQueue)){if(t=null,null!==n.child)switch(n.child.tag){case 27:case 5:case 1:t=n.child.stateNode}try{ki(e,t)}catch(e){Su(n,n.return,e)}}break;case 27:null===t&&4&r&&Rs(n);case 26:case 5:qs(e,n),null===t&&4&r&&Cs(n),512&r&&ys(n,n.return);break;case 12:qs(e,n);break;case 31:qs(e,n),4&r&&js(e,n);break;case 13:qs(e,n),4&r&&zs(e,n),64&r&&null!==(e=n.memoizedState)&&null!==(e=e.dehydrated)&&function(e,t){var n=e.ownerDocument;if("$~"===e.data)e._reactRetry=t;else if("$?"!==e.data||"loading"!==n.readyState)t();else{var r=function(){t(),n.removeEventListener("DOMContentLoaded",r)};n.addEventListener("DOMContentLoaded",r),e._reactRetry=r}}(e,n=ku.bind(null,n));break;case 22:if(!(r=null!==n.memoizedState||Ms)){t=null!==t&&null!==t.memoizedState||Ps,o=Ms;var i=Ps;Ms=r,(Ps=t)&&!i?Ks(e,n,!!(8772&n.subtreeFlags)):qs(e,n),Ms=o,Ps=i}break;case 30:break;default:qs(e,n)}}function Ds(e){var t=e.alternate;null!==t&&(e.alternate=null,Ds(t)),e.child=null,e.deletions=null,e.sibling=null,5===e.tag&&null!==(t=e.stateNode)&&Ye(t),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var Ns=null,Ls=!1;function Fs(e,t,n){for(n=n.child;null!==n;)Qs(e,t,n),n=n.sibling}function Qs(e,t,n){if(be&&"function"==typeof be.onCommitFiberUnmount)try{be.onCommitFiberUnmount(Ae,n)}catch(e){}switch(n.tag){case 26:Ps||ws(n,t),Fs(e,t,n),n.memoizedState?n.memoizedState.count--:n.stateNode&&(n=n.stateNode).parentNode.removeChild(n);break;case 27:Ps||ws(n,t);var r=Ns,o=Ls;Id(n.type)&&(Ns=n.stateNode,Ls=!1),Fs(e,t,n),Fd(n.stateNode),Ns=r,Ls=o;break;case 5:Ps||ws(n,t);case 6:if(r=Ns,o=Ls,Ns=null,Fs(e,t,n),Ls=o,null!==(Ns=r))if(Ls)try{(9===Ns.nodeType?Ns.body:"HTML"===Ns.nodeName?Ns.ownerDocument.body:Ns).removeChild(n.stateNode)}catch(e){Su(n,t,e)}else try{Ns.removeChild(n.stateNode)}catch(e){Su(n,t,e)}break;case 18:null!==Ns&&(Ls?(kd(9===(e=Ns).nodeType?e.body:"HTML"===e.nodeName?e.ownerDocument.body:e,n.stateNode),Vf(e)):kd(Ns,n.stateNode));break;case 4:r=Ns,o=Ls,Ns=n.stateNode.containerInfo,Ls=!0,Fs(e,t,n),Ns=r,Ls=o;break;case 0:case 11:case 14:case 15:As(2,n,t),Ps||As(4,n,t),Fs(e,t,n);break;case 1:Ps||(ws(n,t),"function"==typeof(r=n.stateNode).componentWillUnmount&&vs(n,t,r)),Fs(e,t,n);break;case 21:Fs(e,t,n);break;case 22:Ps=(r=Ps)||null!==n.memoizedState,Fs(e,t,n),Ps=r;break;default:Fs(e,t,n)}}function js(e,t){if(null===t.memoizedState&&null!==(e=t.alternate)&&null!==(e=e.memoizedState)){e=e.dehydrated;try{Vf(e)}catch(e){Su(t,t.return,e)}}}function zs(e,t){if(null===t.memoizedState&&null!==(e=t.alternate)&&null!==(e=e.memoizedState)&&null!==(e=e.dehydrated))try{Vf(e)}catch(e){Su(t,t.return,e)}}function $s(e,t){var n=function(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return null===t&&(t=e.stateNode=new _s),t;case 22:return null===(t=(e=e.stateNode)._retryCache)&&(t=e._retryCache=new _s),t;default:throw Error(a(435,e.tag))}}(e);t.forEach(function(t){if(!n.has(t)){n.add(t);var r=Ru.bind(null,e,t);t.then(r,r)}})}function Hs(e,t){var n=t.deletions;if(null!==n)for(var r=0;r<n.length;r++){var o=n[r],i=e,l=t,s=l;e:for(;null!==s;){switch(s.tag){case 27:if(Id(s.type)){Ns=s.stateNode,Ls=!1;break e}break;case 5:Ns=s.stateNode,Ls=!1;break e;case 3:case 4:Ns=s.stateNode.containerInfo,Ls=!0;break e}s=s.return}if(null===Ns)throw Error(a(160));Qs(i,l,o),Ns=null,Ls=!1,null!==(i=o.alternate)&&(i.return=null),o.return=null}if(13886&t.subtreeFlags)for(t=t.child;null!==t;)Vs(t,e),t=t.sibling}var Gs=null;function Vs(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:Hs(t,e),Ws(e),4&r&&(As(3,e,e.return),ms(3,e),As(5,e,e.return));break;case 1:Hs(t,e),Ws(e),512&r&&(Ps||null===n||ws(n,n.return)),64&r&&Ms&&null!==(e=e.updateQueue)&&null!==(r=e.callbacks)&&(n=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=null===n?r:n.concat(r));break;case 26:var o=Gs;if(Hs(t,e),Ws(e),512&r&&(Ps||null===n||ws(n,n.return)),4&r){var i=null!==n?n.memoizedState:null;if(r=e.memoizedState,null===n)if(null===r)if(null===e.stateNode){e:{r=e.type,n=e.memoizedProps,o=o.ownerDocument||o;t:switch(r){case"title":(!(i=o.getElementsByTagName("title")[0])||i[qe]||i[ze]||"http://www.w3.org/2000/svg"===i.namespaceURI||i.hasAttribute("itemprop"))&&(i=o.createElement(r),o.head.insertBefore(i,o.querySelector("head > title"))),fd(i,r,n),i[ze]=e,et(i),r=i;break e;case"link":var l=nf("link","href",o).get(r+(n.href||""));if(l)for(var s=0;s<l.length;s++)if((i=l[s]).getAttribute("href")===(null==n.href||""===n.href?null:n.href)&&i.getAttribute("rel")===(null==n.rel?null:n.rel)&&i.getAttribute("title")===(null==n.title?null:n.title)&&i.getAttribute("crossorigin")===(null==n.crossOrigin?null:n.crossOrigin)){l.splice(s,1);break t}fd(i=o.createElement(r),r,n),o.head.appendChild(i);break;case"meta":if(l=nf("meta","content",o).get(r+(n.content||"")))for(s=0;s<l.length;s++)if((i=l[s]).getAttribute("content")===(null==n.content?null:""+n.content)&&i.getAttribute("name")===(null==n.name?null:n.name)&&i.getAttribute("property")===(null==n.property?null:n.property)&&i.getAttribute("http-equiv")===(null==n.httpEquiv?null:n.httpEquiv)&&i.getAttribute("charset")===(null==n.charSet?null:n.charSet)){l.splice(s,1);break t}fd(i=o.createElement(r),r,n),o.head.appendChild(i);break;default:throw Error(a(468,r))}i[ze]=e,et(i),r=i}e.stateNode=r}else rf(o,e.type,e.stateNode);else e.stateNode=Jd(o,r,e.memoizedProps);else i!==r?(null===i?null!==n.stateNode&&(n=n.stateNode).parentNode.removeChild(n):i.count--,null===r?rf(o,e.type,e.stateNode):Jd(o,r,e.memoizedProps)):null===r&&null!==e.stateNode&&Ss(e,e.memoizedProps,n.memoizedProps)}break;case 27:Hs(t,e),Ws(e),512&r&&(Ps||null===n||ws(n,n.return)),null!==n&&4&r&&Ss(e,e.memoizedProps,n.memoizedProps);break;case 5:if(Hs(t,e),Ws(e),512&r&&(Ps||null===n||ws(n,n.return)),32&e.flags){o=e.stateNode;try{xt(o,"")}catch(t){Su(e,e.return,t)}}4&r&&null!=e.stateNode&&Ss(e,o=e.memoizedProps,null!==n?n.memoizedProps:o),1024&r&&(Bs=!0);break;case 6:if(Hs(t,e),Ws(e),4&r){if(null===e.stateNode)throw Error(a(162));r=e.memoizedProps,n=e.stateNode;try{n.nodeValue=r}catch(t){Su(e,e.return,t)}}break;case 3:if(tf=null,o=Gs,Gs=zd(t.containerInfo),Hs(t,e),Gs=o,Ws(e),4&r&&null!==n&&n.memoizedState.isDehydrated)try{Vf(t.containerInfo)}catch(t){Su(e,e.return,t)}Bs&&(Bs=!1,Us(e));break;case 4:r=Gs,Gs=zd(e.stateNode.containerInfo),Hs(t,e),Ws(e),Gs=r;break;case 12:default:Hs(t,e),Ws(e);break;case 31:case 19:Hs(t,e),Ws(e),4&r&&null!==(r=e.updateQueue)&&(e.updateQueue=null,$s(e,r));break;case 13:Hs(t,e),Ws(e),8192&e.child.flags&&null!==e.memoizedState!=(null!==n&&null!==n.memoizedState)&&(_c=se()),4&r&&null!==(r=e.updateQueue)&&(e.updateQueue=null,$s(e,r));break;case 22:o=null!==e.memoizedState;var c=null!==n&&null!==n.memoizedState,u=Ms,d=Ps;if(Ms=u||o,Ps=d||c,Hs(t,e),Ps=d,Ms=u,Ws(e),8192&r)e:for(t=e.stateNode,t._visibility=o?-2&t._visibility:1|t._visibility,o&&(null===n||c||Ms||Ps||Ys(e)),n=null,t=e;;){if(5===t.tag||26===t.tag){if(null===n){c=n=t;try{if(i=c.stateNode,o)"function"==typeof(l=i.style).setProperty?l.setProperty("display","none","important"):l.display="none";else{s=c.stateNode;var f=c.memoizedProps.style,p=null!=f&&f.hasOwnProperty("display")?f.display:null;s.style.display=null==p||"boolean"==typeof p?"":(""+p).trim()}}catch(e){Su(c,c.return,e)}}}else if(6===t.tag){if(null===n){c=t;try{c.stateNode.nodeValue=o?"":c.memoizedProps}catch(e){Su(c,c.return,e)}}}else if(18===t.tag){if(null===n){c=t;try{var h=c.stateNode;o?Rd(h,!0):Rd(c.stateNode,!1)}catch(e){Su(c,c.return,e)}}}else if((22!==t.tag&&23!==t.tag||null===t.memoizedState||t===e)&&null!==t.child){t.child.return=t,t=t.child;continue}if(t===e)break e;for(;null===t.sibling;){if(null===t.return||t.return===e)break e;n===t&&(n=null),t=t.return}n===t&&(n=null),t.sibling.return=t.return,t=t.sibling}4&r&&null!==(r=e.updateQueue)&&null!==(n=r.retryQueue)&&(r.retryQueue=null,$s(e,n));case 30:case 21:}}function Ws(e){var t=e.flags;if(2&t){try{for(var n,r=e.return;null!==r;){if(xs(r)){n=r;break}r=r.return}if(null==n)throw Error(a(160));switch(n.tag){case 27:var o=n.stateNode;ks(e,Es(e),o);break;case 5:var i=n.stateNode;32&n.flags&&(xt(i,""),n.flags&=-33),ks(e,Es(e),i);break;case 3:case 4:var l=n.stateNode.containerInfo;Is(e,Es(e),l);break;default:throw Error(a(161))}}catch(t){Su(e,e.return,t)}e.flags&=-3}4096&t&&(e.flags&=-4097)}function Us(e){if(1024&e.subtreeFlags)for(e=e.child;null!==e;){var t=e;Us(t),5===t.tag&&1024&t.flags&&t.stateNode.reset(),e=e.sibling}}function qs(e,t){if(8772&t.subtreeFlags)for(t=t.child;null!==t;)Os(e,t.alternate,t),t=t.sibling}function Ys(e){for(e=e.child;null!==e;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:As(4,t,t.return),Ys(t);break;case 1:ws(t,t.return);var n=t.stateNode;"function"==typeof n.componentWillUnmount&&vs(t,t.return,n),Ys(t);break;case 27:Fd(t.stateNode);case 26:case 5:ws(t,t.return),Ys(t);break;case 22:null===t.memoizedState&&Ys(t);break;default:Ys(t)}e=e.sibling}}function Ks(e,t,n){for(n=n&&!!(8772&t.subtreeFlags),t=t.child;null!==t;){var r=t.alternate,o=e,i=t,a=i.flags;switch(i.tag){case 0:case 11:case 15:Ks(o,i,n),ms(4,i);break;case 1:if(Ks(o,i,n),"function"==typeof(o=(r=i).stateNode).componentDidMount)try{o.componentDidMount()}catch(e){Su(r,r.return,e)}if(null!==(o=(r=i).updateQueue)){var l=r.stateNode;try{var s=o.shared.hiddenCallbacks;if(null!==s)for(o.shared.hiddenCallbacks=null,o=0;o<s.length;o++)Ii(s[o],l)}catch(e){Su(r,r.return,e)}}n&&64&a&&bs(i),ys(i,i.return);break;case 27:Rs(i);case 26:case 5:Ks(o,i,n),n&&null===r&&4&a&&Cs(i),ys(i,i.return);break;case 12:Ks(o,i,n);break;case 31:Ks(o,i,n),n&&4&a&&js(o,i);break;case 13:Ks(o,i,n),n&&4&a&&zs(o,i);break;case 22:null===i.memoizedState&&Ks(o,i,n),ys(i,i.return);break;case 30:break;default:Ks(o,i,n)}t=t.sibling}}function Js(e,t){var n=null;null!==e&&null!==e.memoizedState&&null!==e.memoizedState.cachePool&&(n=e.memoizedState.cachePool.pool),e=null,null!==t.memoizedState&&null!==t.memoizedState.cachePool&&(e=t.memoizedState.cachePool.pool),e!==n&&(null!=e&&e.refCount++,null!=n&&zo(n))}function Xs(e,t){e=null,null!==t.alternate&&(e=t.alternate.memoizedState.cache),(t=t.memoizedState.cache)!==e&&(t.refCount++,null!=e&&zo(e))}function Zs(e,t,n,r){if(10256&t.subtreeFlags)for(t=t.child;null!==t;)ec(e,t,n,r),t=t.sibling}function ec(e,t,n,r){var o=t.flags;switch(t.tag){case 0:case 11:case 15:Zs(e,t,n,r),2048&o&&ms(9,t);break;case 1:case 31:case 13:default:Zs(e,t,n,r);break;case 3:Zs(e,t,n,r),2048&o&&(e=null,null!==t.alternate&&(e=t.alternate.memoizedState.cache),(t=t.memoizedState.cache)!==e&&(t.refCount++,null!=e&&zo(e)));break;case 12:if(2048&o){Zs(e,t,n,r),e=t.stateNode;try{var i=t.memoizedProps,a=i.id,l=i.onPostCommit;"function"==typeof l&&l(a,null===t.alternate?"mount":"update",e.passiveEffectDuration,-0)}catch(e){Su(t,t.return,e)}}else Zs(e,t,n,r);break;case 23:break;case 22:i=t.stateNode,a=t.alternate,null!==t.memoizedState?2&i._visibility?Zs(e,t,n,r):nc(e,t):2&i._visibility?Zs(e,t,n,r):(i._visibility|=2,tc(e,t,n,r,!!(10256&t.subtreeFlags)||!1)),2048&o&&Js(a,t);break;case 24:Zs(e,t,n,r),2048&o&&Xs(t.alternate,t)}}function tc(e,t,n,r,o){for(o=o&&(!!(10256&t.subtreeFlags)||!1),t=t.child;null!==t;){var i=e,a=t,l=n,s=r,c=a.flags;switch(a.tag){case 0:case 11:case 15:tc(i,a,l,s,o),ms(8,a);break;case 23:break;case 22:var u=a.stateNode;null!==a.memoizedState?2&u._visibility?tc(i,a,l,s,o):nc(i,a):(u._visibility|=2,tc(i,a,l,s,o)),o&&2048&c&&Js(a.alternate,a);break;case 24:tc(i,a,l,s,o),o&&2048&c&&Xs(a.alternate,a);break;default:tc(i,a,l,s,o)}t=t.sibling}}function nc(e,t){if(10256&t.subtreeFlags)for(t=t.child;null!==t;){var n=e,r=t,o=r.flags;switch(r.tag){case 22:nc(n,r),2048&o&&Js(r.alternate,r);break;case 24:nc(n,r),2048&o&&Xs(r.alternate,r);break;default:nc(n,r)}t=t.sibling}}var rc=8192;function oc(e,t,n){if(e.subtreeFlags&rc)for(e=e.child;null!==e;)ic(e,t,n),e=e.sibling}function ic(e,t,n){switch(e.tag){case 26:oc(e,t,n),e.flags&rc&&null!==e.memoizedState&&function(e,t,n,r){if(!("stylesheet"!==n.type||"string"==typeof r.media&&!1===matchMedia(r.media).matches||4&n.state.loading)){if(null===n.instance){var o=Wd(r.href),i=t.querySelector(Ud(o));if(i)return null!==(t=i._p)&&"object"==typeof t&&"function"==typeof t.then&&(e.count++,e=lf.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=i,void et(i);i=t.ownerDocument||t,r=qd(r),(o=Qd.get(o))&&Zd(r,o),et(i=i.createElement("link"));var a=i;a._p=new Promise(function(e,t){a.onload=e,a.onerror=t}),fd(i,"link",r),n.instance=i}null===e.stylesheets&&(e.stylesheets=new Map),e.stylesheets.set(n,t),(t=n.state.preload)&&!(3&n.state.loading)&&(e.count++,n=lf.bind(e),t.addEventListener("load",n),t.addEventListener("error",n))}}(n,Gs,e.memoizedState,e.memoizedProps);break;case 5:default:oc(e,t,n);break;case 3:case 4:var r=Gs;Gs=zd(e.stateNode.containerInfo),oc(e,t,n),Gs=r;break;case 22:null===e.memoizedState&&(null!==(r=e.alternate)&&null!==r.memoizedState?(r=rc,rc=16777216,oc(e,t,n),rc=r):oc(e,t,n))}}function ac(e){var t=e.alternate;if(null!==t&&null!==(e=t.child)){t.child=null;do{t=e.sibling,e.sibling=null,e=t}while(null!==e)}}function lc(e){var t=e.deletions;if(16&e.flags){if(null!==t)for(var n=0;n<t.length;n++){var r=t[n];Ts=r,uc(r,e)}ac(e)}if(10256&e.subtreeFlags)for(e=e.child;null!==e;)sc(e),e=e.sibling}function sc(e){switch(e.tag){case 0:case 11:case 15:lc(e),2048&e.flags&&As(9,e,e.return);break;case 3:case 12:default:lc(e);break;case 22:var t=e.stateNode;null!==e.memoizedState&&2&t._visibility&&(null===e.return||13!==e.return.tag)?(t._visibility&=-3,cc(e)):lc(e)}}function cc(e){var t=e.deletions;if(16&e.flags){if(null!==t)for(var n=0;n<t.length;n++){var r=t[n];Ts=r,uc(r,e)}ac(e)}for(e=e.child;null!==e;){switch((t=e).tag){case 0:case 11:case 15:As(8,t,t.return),cc(t);break;case 22:2&(n=t.stateNode)._visibility&&(n._visibility&=-3,cc(t));break;default:cc(t)}e=e.sibling}}function uc(e,t){for(;null!==Ts;){var n=Ts;switch(n.tag){case 0:case 11:case 15:As(8,n,t);break;case 23:case 22:if(null!==n.memoizedState&&null!==n.memoizedState.cachePool){var r=n.memoizedState.cachePool.pool;null!=r&&r.refCount++}break;case 24:zo(n.memoizedState.cache)}if(null!==(r=n.child))r.return=n,Ts=r;else e:for(n=e;null!==Ts;){var o=(r=Ts).sibling,i=r.return;if(Ds(r),r===n){Ts=null;break e}if(null!==o){o.return=i,Ts=o;break e}Ts=i}}}var dc={getCacheForType:function(e){var t=To(Qo),n=t.data.get(e);return void 0===n&&(n=e(),t.data.set(e,n)),n},cacheSignal:function(){return To(Qo).controller.signal}},fc="function"==typeof WeakMap?WeakMap:Map,pc=0,hc=null,gc=null,mc=0,Ac=0,bc=null,vc=!1,yc=!1,wc=!1,Cc=0,Sc=0,xc=0,Ec=0,Ic=0,kc=0,Rc=0,Mc=null,Pc=null,Bc=!1,_c=0,Tc=0,Oc=1/0,Dc=null,Nc=null,Lc=0,Fc=null,Qc=null,jc=0,zc=0,$c=null,Hc=null,Gc=0,Vc=null;function Wc(){return 2&pc&&0!==mc?mc&-mc:null!==O.T?$u():Fe()}function Uc(){if(0===kc)if(536870912&mc&&!fo)kc=536870912;else{var e=xe;!(3932160&(xe<<=1))&&(xe=262144),kc=e}return null!==(e=Ti.current)&&(e.flags|=32),kc}function qc(e,t,n){(e!==hc||2!==Ac&&9!==Ac)&&null===e.cancelPendingCommit||(tu(e,0),Xc(e,mc,kc,!1)),_e(e,n),2&pc&&e===hc||(e===hc&&(!(2&pc)&&(Ec|=n),4===Sc&&Xc(e,mc,kc,!1)),Du(e))}function Yc(e,t,n){if(6&pc)throw Error(a(327));for(var r=!n&&!(127&t)&&0===(t&e.expiredLanes)||Re(e,t),o=r?function(e,t){var n=pc;pc|=2;var r=ou(),o=iu();hc!==e||mc!==t?(Dc=null,Oc=se()+500,tu(e,t)):yc=Re(e,t);e:for(;;)try{if(0!==Ac&&null!==gc){t=gc;var i=bc;t:switch(Ac){case 1:Ac=0,bc=null,fu(e,t,i,1);break;case 2:case 9:if(ni(i)){Ac=0,bc=null,du(t);break}t=function(){2!==Ac&&9!==Ac||hc!==e||(Ac=7),Du(e)},i.then(t,t);break e;case 3:Ac=7;break e;case 4:Ac=5;break e;case 7:ni(i)?(Ac=0,bc=null,du(t)):(Ac=0,bc=null,fu(e,t,i,7));break;case 5:var l=null;switch(gc.tag){case 26:l=gc.memoizedState;case 5:case 27:var s=gc;if(l?of(l):s.stateNode.complete){Ac=0,bc=null;var c=s.sibling;if(null!==c)gc=c;else{var u=s.return;null!==u?(gc=u,pu(u)):gc=null}break t}}Ac=0,bc=null,fu(e,t,i,5);break;case 6:Ac=0,bc=null,fu(e,t,i,6);break;case 8:eu(),Sc=6;break e;default:throw Error(a(462))}}cu();break}catch(t){nu(e,t)}return Eo=xo=null,O.H=r,O.A=o,pc=n,null!==gc?0:(hc=null,mc=0,Pr(),Sc)}(e,t):lu(e,t,!0),i=r;;){if(0===o){yc&&!r&&Xc(e,t,0,!1);break}if(n=e.current.alternate,!i||Jc(n)){if(2===o){if(i=t,e.errorRecoveryDisabledLanes&i)var l=0;else l=0!=(l=-536870913&e.pendingLanes)?l:536870912&l?536870912:0;if(0!==l){t=l;e:{var s=e;o=Mc;var c=s.current.memoizedState.isDehydrated;if(c&&(tu(s,l).flags|=256),2!==(l=lu(s,l,!1))){if(wc&&!c){s.errorRecoveryDisabledLanes|=i,Ec|=i,o=4;break e}i=Pc,Pc=o,null!==i&&(null===Pc?Pc=i:Pc.push.apply(Pc,i))}o=l}if(i=!1,2!==o)continue}}if(1===o){tu(e,0),Xc(e,t,0,!0);break}e:{switch(r=e,i=o){case 0:case 1:throw Error(a(345));case 4:if((4194048&t)!==t)break;case 6:Xc(r,t,kc,!vc);break e;case 2:Pc=null;break;case 3:case 5:break;default:throw Error(a(329))}if((62914560&t)===t&&10<(o=_c+300-se())){if(Xc(r,t,kc,!vc),0!==ke(r,0,!0))break e;jc=t,r.timeoutHandle=wd(Kc.bind(null,r,n,Pc,Dc,Bc,t,kc,Ec,Rc,vc,i,"Throttled",-0,0),o)}else Kc(r,n,Pc,Dc,Bc,t,kc,Ec,Rc,vc,i,null,-0,0)}break}o=lu(e,t,!1),i=!1}Du(e)}function Kc(e,t,n,r,o,i,a,l,s,c,u,d,f,p){if(e.timeoutHandle=-1,8192&(d=t.subtreeFlags)||!(16785408&~d)){ic(t,i,d={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:_t});var h=(62914560&i)===i?_c-se():(4194048&i)===i?Tc-se():0;if(null!==(h=function(e,t){return e.stylesheets&&0===e.count&&cf(e,e.stylesheets),0<e.count||0<e.imgCount?function(n){var r=setTimeout(function(){if(e.stylesheets&&cf(e,e.stylesheets),e.unsuspend){var t=e.unsuspend;e.unsuspend=null,t()}},6e4+t);0<e.imgBytes&&0===af&&(af=62500*function(){if("function"==typeof performance.getEntriesByType){for(var e=0,t=0,n=performance.getEntriesByType("resource"),r=0;r<n.length;r++){var o=n[r],i=o.transferSize,a=o.initiatorType,l=o.duration;if(i&&l&&pd(a)){for(a=0,l=o.responseEnd,r+=1;r<n.length;r++){var s=n[r],c=s.startTime;if(c>l)break;var u=s.transferSize,d=s.initiatorType;u&&pd(d)&&(a+=u*((s=s.responseEnd)<l?1:(l-c)/(s-c)))}if(--r,t+=8*(i+a)/(o.duration/1e3),10<++e)break}}if(0<e)return t/e/1e6}return navigator.connection&&"number"==typeof(e=navigator.connection.downlink)?e:5}());var o=setTimeout(function(){if(e.waitingForImages=!1,0===e.count&&(e.stylesheets&&cf(e,e.stylesheets),e.unsuspend)){var t=e.unsuspend;e.unsuspend=null,t()}},(e.imgBytes>af?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r),clearTimeout(o)}}:null}(d,h)))return jc=i,e.cancelPendingCommit=h(gu.bind(null,e,t,i,n,r,o,a,l,s,u,d,null,f,p)),void Xc(e,i,a,!c)}gu(e,t,i,n,r,o,a,l,s)}function Jc(e){for(var t=e;;){var n=t.tag;if((0===n||11===n||15===n)&&16384&t.flags&&null!==(n=t.updateQueue)&&null!==(n=n.stores))for(var r=0;r<n.length;r++){var o=n[r],i=o.getSnapshot;o=o.value;try{if(!Xn(i(),o))return!1}catch(e){return!1}}if(n=t.child,16384&t.subtreeFlags&&null!==n)n.return=t,t=n;else{if(t===e)break;for(;null===t.sibling;){if(null===t.return||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function Xc(e,t,n,r){t&=~Ic,t&=~Ec,e.suspendedLanes|=t,e.pingedLanes&=~t,r&&(e.warmLanes|=t),r=e.expirationTimes;for(var o=t;0<o;){var i=31-ye(o),a=1<<i;r[i]=-1,o&=~a}0!==n&&Te(e,n,t)}function Zc(){return!!(6&pc)||(Nu(0,!1),!1)}function eu(){if(null!==gc){if(0===Ac)var e=gc.return;else Eo=xo=null,la(e=gc),si=null,ci=0,e=gc;for(;null!==e;)gs(e.alternate,e),e=e.return;gc=null}}function tu(e,t){var n=e.timeoutHandle;-1!==n&&(e.timeoutHandle=-1,Cd(n)),null!==(n=e.cancelPendingCommit)&&(e.cancelPendingCommit=null,n()),jc=0,eu(),hc=e,gc=n=jr(e.current,null),mc=t,Ac=0,bc=null,vc=!1,yc=Re(e,t),wc=!1,Rc=kc=Ic=Ec=xc=Sc=0,Pc=Mc=null,Bc=!1,8&t&&(t|=32&t);var r=e.entangledLanes;if(0!==r)for(e=e.entanglements,r&=t;0<r;){var o=31-ye(r),i=1<<o;t|=e[o],r&=~i}return Cc=t,Pr(),n}function nu(e,t){Hi=null,O.H=gl,t===Xo||t===ei?(t=ai(),Ac=3):t===Zo?(t=ai(),Ac=4):Ac=t===_l?8:null!==t&&"object"==typeof t&&"function"==typeof t.then?6:1,bc=t,null===gc&&(Sc=1,kl(e,qr(t,e.current)))}function ru(){var e=Ti.current;return null===e||((4194048&mc)===mc?null===Oi:!!((62914560&mc)===mc||536870912&mc)&&e===Oi)}function ou(){var e=O.H;return O.H=gl,null===e?gl:e}function iu(){var e=O.A;return O.A=dc,e}function au(){Sc=4,vc||(4194048&mc)!==mc&&null!==Ti.current||(yc=!0),!(134217727&xc)&&!(134217727&Ec)||null===hc||Xc(hc,mc,kc,!1)}function lu(e,t,n){var r=pc;pc|=2;var o=ou(),i=iu();hc===e&&mc===t||(Dc=null,tu(e,t)),t=!1;var a=Sc;e:for(;;)try{if(0!==Ac&&null!==gc){var l=gc,s=bc;switch(Ac){case 8:eu(),a=6;break e;case 3:case 2:case 9:case 6:null===Ti.current&&(t=!0);var c=Ac;if(Ac=0,bc=null,fu(e,l,s,c),n&&yc){a=0;break e}break;default:c=Ac,Ac=0,bc=null,fu(e,l,s,c)}}su(),a=Sc;break}catch(t){nu(e,t)}return t&&e.shellSuspendCounter++,Eo=xo=null,pc=r,O.H=o,O.A=i,null===gc&&(hc=null,mc=0,Pr()),a}function su(){for(;null!==gc;)uu(gc)}function cu(){for(;null!==gc&&!ae();)uu(gc)}function uu(e){var t=as(e.alternate,e,Cc);e.memoizedProps=e.pendingProps,null===t?pu(e):gc=t}function du(e){var t=e,n=t.alternate;switch(t.tag){case 15:case 0:t=Vl(n,t,t.pendingProps,t.type,void 0,mc);break;case 11:t=Vl(n,t,t.pendingProps,t.type.render,t.ref,mc);break;case 5:la(t);default:gs(n,t),t=as(n,t=gc=zr(t,Cc),Cc)}e.memoizedProps=e.pendingProps,null===t?pu(e):gc=t}function fu(e,t,n,r){Eo=xo=null,la(t),si=null,ci=0;var o=t.return;try{if(function(e,t,n,r,o){if(n.flags|=32768,null!==r&&"object"==typeof r&&"function"==typeof r.then){if(null!==(t=n.alternate)&&Po(t,n,o,!0),null!==(n=Ti.current)){switch(n.tag){case 31:case 13:return null===Oi?au():null===n.alternate&&0===Sc&&(Sc=3),n.flags&=-257,n.flags|=65536,n.lanes=o,r===ti?n.flags|=16384:(null===(t=n.updateQueue)?n.updateQueue=new Set([r]):t.add(r),xu(e,r,o)),!1;case 22:return n.flags|=65536,r===ti?n.flags|=16384:(null===(t=n.updateQueue)?(t={transitions:null,markerInstances:null,retryQueue:new Set([r])},n.updateQueue=t):null===(n=t.retryQueue)?t.retryQueue=new Set([r]):n.add(r),xu(e,r,o)),!1}throw Error(a(435,n.tag))}return xu(e,r,o),au(),!1}if(fo)return null!==(t=Ti.current)?(!(65536&t.flags)&&(t.flags|=256),t.flags|=65536,t.lanes=o,r!==go&&Co(qr(e=Error(a(422),{cause:r}),n))):(r!==go&&Co(qr(t=Error(a(423),{cause:r}),n)),(e=e.current.alternate).flags|=65536,o&=-o,e.lanes|=o,r=qr(r,n),Ci(e,o=Ml(e.stateNode,r,o)),4!==Sc&&(Sc=2)),!1;var i=Error(a(520),{cause:r});if(i=qr(i,n),null===Mc?Mc=[i]:Mc.push(i),4!==Sc&&(Sc=2),null===t)return!0;r=qr(r,n),n=t;do{switch(n.tag){case 3:return n.flags|=65536,e=o&-o,n.lanes|=e,Ci(n,e=Ml(n.stateNode,r,e)),!1;case 1:if(t=n.type,i=n.stateNode,!(128&n.flags||"function"!=typeof t.getDerivedStateFromError&&(null===i||"function"!=typeof i.componentDidCatch||null!==Nc&&Nc.has(i))))return n.flags|=65536,o&=-o,n.lanes|=o,Bl(o=Pl(o),e,n,r),Ci(n,o),!1}n=n.return}while(null!==n);return!1}(e,o,t,n,mc))return Sc=1,kl(e,qr(n,e.current)),void(gc=null)}catch(t){if(null!==o)throw gc=o,t;return Sc=1,kl(e,qr(n,e.current)),void(gc=null)}32768&t.flags?(fo||1===r?e=!0:yc||536870912&mc?e=!1:(vc=e=!0,(2===r||9===r||3===r||6===r)&&null!==(r=Ti.current)&&13===r.tag&&(r.flags|=16384)),hu(t,e)):pu(t)}function pu(e){var t=e;do{if(32768&t.flags)return void hu(t,vc);e=t.return;var n=ps(t.alternate,t,Cc);if(null!==n)return void(gc=n);if(null!==(t=t.sibling))return void(gc=t);gc=t=e}while(null!==t);0===Sc&&(Sc=5)}function hu(e,t){do{var n=hs(e.alternate,e);if(null!==n)return n.flags&=32767,void(gc=n);if(null!==(n=e.return)&&(n.flags|=32768,n.subtreeFlags=0,n.deletions=null),!t&&null!==(e=e.sibling))return void(gc=e);gc=e=n}while(null!==e);Sc=6,gc=null}function gu(e,t,n,r,o,i,l,s,c){e.cancelPendingCommit=null;do{yu()}while(0!==Lc);if(6&pc)throw Error(a(327));if(null!==t){if(t===e.current)throw Error(a(177));if(i=t.lanes|t.childLanes,function(e,t,n,r,o,i){var a=e.pendingLanes;e.pendingLanes=n,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=n,e.entangledLanes&=n,e.errorRecoveryDisabledLanes&=n,e.shellSuspendCounter=0;var l=e.entanglements,s=e.expirationTimes,c=e.hiddenUpdates;for(n=a&~n;0<n;){var u=31-ye(n),d=1<<u;l[u]=0,s[u]=-1;var f=c[u];if(null!==f)for(c[u]=null,u=0;u<f.length;u++){var p=f[u];null!==p&&(p.lane&=-536870913)}n&=~d}0!==r&&Te(e,r,0),0!==i&&0===o&&0!==e.tag&&(e.suspendedLanes|=i&~(a&~t))}(e,n,i|=Mr,l,s,c),e===hc&&(gc=hc=null,mc=0),Qc=t,Fc=e,jc=n,zc=i,$c=o,Hc=r,10256&t.subtreeFlags||10256&t.flags?(e.callbackNode=null,e.callbackPriority=0,oe(fe,function(){return wu(),null})):(e.callbackNode=null,e.callbackPriority=0),r=!!(13878&t.flags),13878&t.subtreeFlags||r){r=O.T,O.T=null,o=D.p,D.p=2,l=pc,pc|=4;try{!function(e,t){if(e=e.containerInfo,hd=yf,or(e=rr(e))){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{var r=(n=(n=e.ownerDocument)&&n.defaultView||window).getSelection&&n.getSelection();if(r&&0!==r.rangeCount){n=r.anchorNode;var o=r.anchorOffset,i=r.focusNode;r=r.focusOffset;try{n.nodeType,i.nodeType}catch(e){n=null;break e}var l=0,s=-1,c=-1,u=0,d=0,f=e,p=null;t:for(;;){for(var h;f!==n||0!==o&&3!==f.nodeType||(s=l+o),f!==i||0!==r&&3!==f.nodeType||(c=l+r),3===f.nodeType&&(l+=f.nodeValue.length),null!==(h=f.firstChild);)p=f,f=h;for(;;){if(f===e)break t;if(p===n&&++u===o&&(s=l),p===i&&++d===r&&(c=l),null!==(h=f.nextSibling))break;p=(f=p).parentNode}f=h}n=-1===s||-1===c?null:{start:s,end:c}}else n=null}n=n||{start:0,end:0}}else n=null;for(gd={focusedElem:e,selectionRange:n},yf=!1,Ts=t;null!==Ts;)if(e=(t=Ts).child,1028&t.subtreeFlags&&null!==e)e.return=t,Ts=e;else for(;null!==Ts;){switch(i=(t=Ts).alternate,e=t.flags,t.tag){case 0:if(4&e&&null!==(e=null!==(e=t.updateQueue)?e.events:null))for(n=0;n<e.length;n++)(o=e[n]).ref.impl=o.nextImpl;break;case 11:case 15:case 5:case 26:case 27:case 6:case 4:case 17:break;case 1:if(1024&e&&null!==i){e=void 0,n=t,o=i.memoizedProps,i=i.memoizedState,r=n.stateNode;try{var g=Sl(n.type,o);e=r.getSnapshotBeforeUpdate(g,i),r.__reactInternalSnapshotBeforeUpdate=e}catch(e){Su(n,n.return,e)}}break;case 3:if(1024&e)if(9===(n=(e=t.stateNode.containerInfo).nodeType))Md(e);else if(1===n)switch(e.nodeName){case"HEAD":case"HTML":case"BODY":Md(e);break;default:e.textContent=""}break;default:if(1024&e)throw Error(a(163))}if(null!==(e=t.sibling)){e.return=t.return,Ts=e;break}Ts=t.return}}(e,t)}finally{pc=l,D.p=o,O.T=r}}Lc=1,mu(),Au(),bu()}}function mu(){if(1===Lc){Lc=0;var e=Fc,t=Qc,n=!!(13878&t.flags);if(13878&t.subtreeFlags||n){n=O.T,O.T=null;var r=D.p;D.p=2;var o=pc;pc|=4;try{Vs(t,e);var i=gd,a=rr(e.containerInfo),l=i.focusedElem,s=i.selectionRange;if(a!==l&&l&&l.ownerDocument&&nr(l.ownerDocument.documentElement,l)){if(null!==s&&or(l)){var c=s.start,u=s.end;if(void 0===u&&(u=c),"selectionStart"in l)l.selectionStart=c,l.selectionEnd=Math.min(u,l.value.length);else{var d=l.ownerDocument||document,f=d&&d.defaultView||window;if(f.getSelection){var p=f.getSelection(),h=l.textContent.length,g=Math.min(s.start,h),m=void 0===s.end?g:Math.min(s.end,h);!p.extend&&g>m&&(a=m,m=g,g=a);var A=tr(l,g),b=tr(l,m);if(A&&b&&(1!==p.rangeCount||p.anchorNode!==A.node||p.anchorOffset!==A.offset||p.focusNode!==b.node||p.focusOffset!==b.offset)){var v=d.createRange();v.setStart(A.node,A.offset),p.removeAllRanges(),g>m?(p.addRange(v),p.extend(b.node,b.offset)):(v.setEnd(b.node,b.offset),p.addRange(v))}}}}for(d=[],p=l;p=p.parentNode;)1===p.nodeType&&d.push({element:p,left:p.scrollLeft,top:p.scrollTop});for("function"==typeof l.focus&&l.focus(),l=0;l<d.length;l++){var y=d[l];y.element.scrollLeft=y.left,y.element.scrollTop=y.top}}yf=!!hd,gd=hd=null}finally{pc=o,D.p=r,O.T=n}}e.current=t,Lc=2}}function Au(){if(2===Lc){Lc=0;var e=Fc,t=Qc,n=!!(8772&t.flags);if(8772&t.subtreeFlags||n){n=O.T,O.T=null;var r=D.p;D.p=2;var o=pc;pc|=4;try{Os(e,t.alternate,t)}finally{pc=o,D.p=r,O.T=n}}Lc=3}}function bu(){if(4===Lc||3===Lc){Lc=0,le();var e=Fc,t=Qc,n=jc,r=Hc;10256&t.subtreeFlags||10256&t.flags?Lc=5:(Lc=0,Qc=Fc=null,vu(e,e.pendingLanes));var o=e.pendingLanes;if(0===o&&(Nc=null),Le(n),t=t.stateNode,be&&"function"==typeof be.onCommitFiberRoot)try{be.onCommitFiberRoot(Ae,t,void 0,!(128&~t.current.flags))}catch(e){}if(null!==r){t=O.T,o=D.p,D.p=2,O.T=null;try{for(var i=e.onRecoverableError,a=0;a<r.length;a++){var l=r[a];i(l.value,{componentStack:l.stack})}}finally{O.T=t,D.p=o}}3&jc&&yu(),Du(e),o=e.pendingLanes,261930&n&&42&o?e===Vc?Gc++:(Gc=0,Vc=e):Gc=0,Nu(0,!1)}}function vu(e,t){0===(e.pooledCacheLanes&=t)&&null!=(t=e.pooledCache)&&(e.pooledCache=null,zo(t))}function yu(){return mu(),Au(),bu(),wu()}function wu(){if(5!==Lc)return!1;var e=Fc,t=zc;zc=0;var n=Le(jc),r=O.T,o=D.p;try{D.p=32>n?32:n,O.T=null,n=$c,$c=null;var i=Fc,l=jc;if(Lc=0,Qc=Fc=null,jc=0,6&pc)throw Error(a(331));var s=pc;if(pc|=4,sc(i.current),ec(i,i.current,l,n),pc=s,Nu(0,!1),be&&"function"==typeof be.onPostCommitFiberRoot)try{be.onPostCommitFiberRoot(Ae,i)}catch(e){}return!0}finally{D.p=o,O.T=r,vu(e,t)}}function Cu(e,t,n){t=qr(n,t),null!==(e=yi(e,t=Ml(e.stateNode,t,2),2))&&(_e(e,2),Du(e))}function Su(e,t,n){if(3===e.tag)Cu(e,e,n);else for(;null!==t;){if(3===t.tag){Cu(t,e,n);break}if(1===t.tag){var r=t.stateNode;if("function"==typeof t.type.getDerivedStateFromError||"function"==typeof r.componentDidCatch&&(null===Nc||!Nc.has(r))){e=qr(n,e),null!==(r=yi(t,n=Pl(2),2))&&(Bl(n,r,t,e),_e(r,2),Du(r));break}}t=t.return}}function xu(e,t,n){var r=e.pingCache;if(null===r){r=e.pingCache=new fc;var o=new Set;r.set(t,o)}else void 0===(o=r.get(t))&&(o=new Set,r.set(t,o));o.has(n)||(wc=!0,o.add(n),e=Eu.bind(null,e,t,n),t.then(e,e))}function Eu(e,t,n){var r=e.pingCache;null!==r&&r.delete(t),e.pingedLanes|=e.suspendedLanes&n,e.warmLanes&=~n,hc===e&&(mc&n)===n&&(4===Sc||3===Sc&&(62914560&mc)===mc&&300>se()-_c?!(2&pc)&&tu(e,0):Ic|=n,Rc===mc&&(Rc=0)),Du(e)}function Iu(e,t){0===t&&(t=Pe()),null!==(e=Tr(e,t))&&(_e(e,t),Du(e))}function ku(e){var t=e.memoizedState,n=0;null!==t&&(n=t.retryLane),Iu(e,n)}function Ru(e,t){var n=0;switch(e.tag){case 31:case 13:var r=e.stateNode,o=e.memoizedState;null!==o&&(n=o.retryLane);break;case 19:r=e.stateNode;break;case 22:r=e.stateNode._retryCache;break;default:throw Error(a(314))}null!==r&&r.delete(t),Iu(e,n)}var Mu=null,Pu=null,Bu=!1,_u=!1,Tu=!1,Ou=0;function Du(e){e!==Pu&&null===e.next&&(null===Pu?Mu=Pu=e:Pu=Pu.next=e),_u=!0,Bu||(Bu=!0,xd(function(){6&pc?oe(ue,Lu):Fu()}))}function Nu(e,t){if(!Tu&&_u){Tu=!0;do{for(var n=!1,r=Mu;null!==r;){if(!t)if(0!==e){var o=r.pendingLanes;if(0===o)var i=0;else{var a=r.suspendedLanes,l=r.pingedLanes;i=(1<<31-ye(42|e)+1)-1,i=201326741&(i&=o&~(a&~l))?201326741&i|1:i?2|i:0}0!==i&&(n=!0,zu(r,i))}else i=mc,!(3&(i=ke(r,r===hc?i:0,null!==r.cancelPendingCommit||-1!==r.timeoutHandle)))||Re(r,i)||(n=!0,zu(r,i));r=r.next}}while(n);Tu=!1}}function Lu(){Fu()}function Fu(){_u=Bu=!1;var e,t=0;0!==Ou&&((e=window.event)&&"popstate"===e.type?e!==yd&&(yd=e,1):(yd=null,0))&&(t=Ou);for(var n=se(),r=null,o=Mu;null!==o;){var i=o.next,a=Qu(o,n);0===a?(o.next=null,null===r?Mu=i:r.next=i,null===i&&(Pu=r)):(r=o,(0!==t||3&a)&&(_u=!0)),o=i}0!==Lc&&5!==Lc||Nu(t,!1),0!==Ou&&(Ou=0)}function Qu(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,o=e.expirationTimes,i=-62914561&e.pendingLanes;0<i;){var a=31-ye(i),l=1<<a,s=o[a];-1===s?0!==(l&n)&&0===(l&r)||(o[a]=Me(l,t)):s<=t&&(e.expiredLanes|=l),i&=~l}if(n=mc,n=ke(e,e===(t=hc)?n:0,null!==e.cancelPendingCommit||-1!==e.timeoutHandle),r=e.callbackNode,0===n||e===t&&(2===Ac||9===Ac)||null!==e.cancelPendingCommit)return null!==r&&null!==r&&ie(r),e.callbackNode=null,e.callbackPriority=0;if(!(3&n)||Re(e,n)){if((t=n&-n)===e.callbackPriority)return t;switch(null!==r&&ie(r),Le(n)){case 2:case 8:n=de;break;case 32:default:n=fe;break;case 268435456:n=he}return r=ju.bind(null,e),n=oe(n,r),e.callbackPriority=t,e.callbackNode=n,t}return null!==r&&null!==r&&ie(r),e.callbackPriority=2,e.callbackNode=null,2}function ju(e,t){if(0!==Lc&&5!==Lc)return e.callbackNode=null,e.callbackPriority=0,null;var n=e.callbackNode;if(yu()&&e.callbackNode!==n)return null;var r=mc;return 0===(r=ke(e,e===hc?r:0,null!==e.cancelPendingCommit||-1!==e.timeoutHandle))?null:(Yc(e,r,t),Qu(e,se()),null!=e.callbackNode&&e.callbackNode===n?ju.bind(null,e):null)}function zu(e,t){if(yu())return null;Yc(e,t,!0)}function $u(){if(0===Ou){var e=Go;0===e&&(e=Se,!(261888&(Se<<=1))&&(Se=256)),Ou=e}return Ou}function Hu(e){return null==e||"symbol"==typeof e||"boolean"==typeof e?null:"function"==typeof e?e:Bt(""+e)}function Gu(e,t){var n=t.ownerDocument.createElement("input");return n.name=t.name,n.value=t.value,e.id&&n.setAttribute("form",e.id),t.parentNode.insertBefore(n,t),e=new FormData(e),n.parentNode.removeChild(n),e}for(var Vu=0;Vu<xr.length;Vu++){var Wu=xr[Vu];Er(Wu.toLowerCase(),"on"+(Wu[0].toUpperCase()+Wu.slice(1)))}Er(mr,"onAnimationEnd"),Er(Ar,"onAnimationIteration"),Er(br,"onAnimationStart"),Er("dblclick","onDoubleClick"),Er("focusin","onFocus"),Er("focusout","onBlur"),Er(vr,"onTransitionRun"),Er(yr,"onTransitionStart"),Er(wr,"onTransitionCancel"),Er(Cr,"onTransitionEnd"),ot("onMouseEnter",["mouseout","mouseover"]),ot("onMouseLeave",["mouseout","mouseover"]),ot("onPointerEnter",["pointerout","pointerover"]),ot("onPointerLeave",["pointerout","pointerover"]),rt("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),rt("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),rt("onBeforeInput",["compositionend","keypress","textInput","paste"]),rt("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),rt("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),rt("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Uu="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),qu=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(Uu));function Yu(e,t){t=!!(4&t);for(var n=0;n<e.length;n++){var r=e[n],o=r.event;r=r.listeners;e:{var i=void 0;if(t)for(var a=r.length-1;0<=a;a--){var l=r[a],s=l.instance,c=l.currentTarget;if(l=l.listener,s!==i&&o.isPropagationStopped())break e;i=l,o.currentTarget=c;try{i(o)}catch(e){Ir(e)}o.currentTarget=null,i=s}else for(a=0;a<r.length;a++){if(s=(l=r[a]).instance,c=l.currentTarget,l=l.listener,s!==i&&o.isPropagationStopped())break e;i=l,o.currentTarget=c;try{i(o)}catch(e){Ir(e)}o.currentTarget=null,i=s}}}}function Ku(e,t){var n=t[Ge];void 0===n&&(n=t[Ge]=new Set);var r=e+"__bubble";n.has(r)||(ed(t,e,2,!1),n.add(r))}function Ju(e,t,n){var r=0;t&&(r|=4),ed(n,e,r,t)}var Xu="_reactListening"+Math.random().toString(36).slice(2);function Zu(e){if(!e[Xu]){e[Xu]=!0,tt.forEach(function(t){"selectionchange"!==t&&(qu.has(t)||Ju(t,!1,e),Ju(t,!0,e))});var t=9===e.nodeType?e:e.ownerDocument;null===t||t[Xu]||(t[Xu]=!0,Ju("selectionchange",!1,t))}}function ed(e,t,n,r){switch(kf(t)){case 2:var o=wf;break;case 8:o=Cf;break;default:o=Sf}n=o.bind(null,t,n,e),o=void 0,!$t||"touchstart"!==t&&"touchmove"!==t&&"wheel"!==t||(o=!0),r?void 0!==o?e.addEventListener(t,n,{capture:!0,passive:o}):e.addEventListener(t,n,!0):void 0!==o?e.addEventListener(t,n,{passive:o}):e.addEventListener(t,n,!1)}function td(e,t,n,r,o){var i=r;if(!(1&t||2&t||null===r))e:for(;;){if(null===r)return;var a=r.tag;if(3===a||4===a){var l=r.stateNode.containerInfo;if(l===o)break;if(4===a)for(a=r.return;null!==a;){var c=a.tag;if((3===c||4===c)&&a.stateNode.containerInfo===o)return;a=a.return}for(;null!==l;){if(null===(a=Ke(l)))return;if(5===(c=a.tag)||6===c||26===c||27===c){r=i=a;continue e}l=l.parentNode}}r=r.return}Qt(function(){var r=i,o=Ot(n),a=[];e:{var l=Sr.get(e);if(void 0!==l){var c=nn,u=e;switch(e){case"keypress":if(0===qt(n))break e;case"keydown":case"keyup":c=bn;break;case"focusin":u="focus",c=cn;break;case"focusout":u="blur",c=cn;break;case"beforeblur":case"afterblur":c=cn;break;case"click":if(2===n.button)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":c=ln;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":c=sn;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":c=yn;break;case mr:case Ar:case br:c=un;break;case Cr:c=wn;break;case"scroll":case"scrollend":c=on;break;case"wheel":c=Cn;break;case"copy":case"cut":case"paste":c=dn;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":c=vn;break;case"toggle":case"beforetoggle":c=Sn}var d=!!(4&t),f=!d&&("scroll"===e||"scrollend"===e),p=d?null!==l?l+"Capture":null:l;d=[];for(var h,g=r;null!==g;){var m=g;if(h=m.stateNode,5!==(m=m.tag)&&26!==m&&27!==m||null===h||null===p||null!=(m=jt(g,p))&&d.push(nd(g,m,h)),f)break;g=g.return}0<d.length&&(l=new c(l,u,null,n,o),a.push({event:l,listeners:d}))}}if(!(7&t)){if(c="mouseout"===e||"pointerout"===e,(!(l="mouseover"===e||"pointerover"===e)||n===Tt||!(u=n.relatedTarget||n.fromElement)||!Ke(u)&&!u[He])&&(c||l)&&(l=o.window===o?o:(l=o.ownerDocument)?l.defaultView||l.parentWindow:window,c?(c=r,null!==(u=(u=n.relatedTarget||n.toElement)?Ke(u):null)&&(f=s(u),d=u.tag,u!==f||5!==d&&27!==d&&6!==d)&&(u=null)):(c=null,u=r),c!==u)){if(d=ln,m="onMouseLeave",p="onMouseEnter",g="mouse","pointerout"!==e&&"pointerover"!==e||(d=vn,m="onPointerLeave",p="onPointerEnter",g="pointer"),f=null==c?l:Xe(c),h=null==u?l:Xe(u),(l=new d(m,g+"leave",c,n,o)).target=f,l.relatedTarget=h,m=null,Ke(o)===r&&((d=new d(p,g+"enter",u,n,o)).target=h,d.relatedTarget=f,m=d),f=m,c&&u)e:{for(d=od,g=u,h=0,m=p=c;m;m=d(m))h++;m=0;for(var A=g;A;A=d(A))m++;for(;0<h-m;)p=d(p),h--;for(;0<m-h;)g=d(g),m--;for(;h--;){if(p===g||null!==g&&p===g.alternate){d=p;break e}p=d(p),g=d(g)}d=null}else d=null;null!==c&&id(a,l,c,d,!1),null!==u&&null!==f&&id(a,f,u,d,!0)}if("select"===(c=(l=r?Xe(r):window).nodeName&&l.nodeName.toLowerCase())||"input"===c&&"file"===l.type)var b=zn;else if(Dn(l))if($n)b=Jn;else{b=Yn;var v=qn}else!(c=l.nodeName)||"input"!==c.toLowerCase()||"checkbox"!==l.type&&"radio"!==l.type?r&&Rt(r.elementType)&&(b=zn):b=Kn;switch(b&&(b=b(e,r))?Nn(a,b,n,o):(v&&v(e,l,r),"focusout"===e&&r&&"number"===l.type&&null!=r.memoizedProps.value&&yt(l,"number",l.value)),v=r?Xe(r):window,e){case"focusin":(Dn(v)||"true"===v.contentEditable)&&(ar=v,lr=r,sr=null);break;case"focusout":sr=lr=ar=null;break;case"mousedown":cr=!0;break;case"contextmenu":case"mouseup":case"dragend":cr=!1,ur(a,n,o);break;case"selectionchange":if(ir)break;case"keydown":case"keyup":ur(a,n,o)}var y;if(En)e:{switch(e){case"compositionstart":var w="onCompositionStart";break e;case"compositionend":w="onCompositionEnd";break e;case"compositionupdate":w="onCompositionUpdate";break e}w=void 0}else Tn?Bn(e,n)&&(w="onCompositionEnd"):"keydown"===e&&229===n.keyCode&&(w="onCompositionStart");w&&(Rn&&"ko"!==n.locale&&(Tn||"onCompositionStart"!==w?"onCompositionEnd"===w&&Tn&&(y=Ut()):(Vt="value"in(Gt=o)?Gt.value:Gt.textContent,Tn=!0)),0<(v=rd(r,w)).length&&(w=new fn(w,e,null,n,o),a.push({event:w,listeners:v}),(y||null!==(y=_n(n)))&&(w.data=y))),(y=kn?function(e,t){switch(e){case"compositionend":return _n(t);case"keypress":return 32!==t.which?null:(Pn=!0,Mn);case"textInput":return(e=t.data)===Mn&&Pn?null:e;default:return null}}(e,n):function(e,t){if(Tn)return"compositionend"===e||!En&&Bn(e,t)?(e=Ut(),Wt=Vt=Gt=null,Tn=!1,e):null;switch(e){case"paste":default:return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return Rn&&"ko"!==t.locale?null:t.data}}(e,n))&&0<(w=rd(r,"onBeforeInput")).length&&(v=new fn("onBeforeInput","beforeinput",null,n,o),a.push({event:v,listeners:w}),v.data=y),function(e,t,n,r,o){if("submit"===t&&n&&n.stateNode===o){var i=Hu((o[$e]||null).action),a=r.submitter;a&&null!==(t=(t=a[$e]||null)?Hu(t.formAction):a.getAttribute("formAction"))&&(i=t,a=null);var l=new nn("action","action",null,r,o);e.push({event:l,listeners:[{instance:null,listener:function(){if(r.defaultPrevented){if(0!==Ou){var e=a?Gu(o,a):new FormData(o);tl(n,{pending:!0,data:e,method:o.method,action:i},null,e)}}else"function"==typeof i&&(l.preventDefault(),e=a?Gu(o,a):new FormData(o),tl(n,{pending:!0,data:e,method:o.method,action:i},i,e))},currentTarget:o}]})}}(a,e,r,n,o)}Yu(a,t)})}function nd(e,t,n){return{instance:e,listener:t,currentTarget:n}}function rd(e,t){for(var n=t+"Capture",r=[];null!==e;){var o=e,i=o.stateNode;if(5!==(o=o.tag)&&26!==o&&27!==o||null===i||(null!=(o=jt(e,n))&&r.unshift(nd(e,o,i)),null!=(o=jt(e,t))&&r.push(nd(e,o,i))),3===e.tag)return r;e=e.return}return[]}function od(e){if(null===e)return null;do{e=e.return}while(e&&5!==e.tag&&27!==e.tag);return e||null}function id(e,t,n,r,o){for(var i=t._reactName,a=[];null!==n&&n!==r;){var l=n,s=l.alternate,c=l.stateNode;if(l=l.tag,null!==s&&s===r)break;5!==l&&26!==l&&27!==l||null===c||(s=c,o?null!=(c=jt(n,i))&&a.unshift(nd(n,c,s)):o||null!=(c=jt(n,i))&&a.push(nd(n,c,s))),n=n.return}0!==a.length&&e.push({event:t,listeners:a})}var ad=/\r\n?/g,ld=/\u0000|\uFFFD/g;function sd(e){return("string"==typeof e?e:""+e).replace(ad,"\n").replace(ld,"")}function cd(e,t){return t=sd(t),sd(e)===t}function ud(e,t,n,r,o,i){switch(n){case"children":"string"==typeof r?"body"===t||"textarea"===t&&""===r||xt(e,r):("number"==typeof r||"bigint"==typeof r)&&"body"!==t&&xt(e,""+r);break;case"className":ct(e,"class",r);break;case"tabIndex":ct(e,"tabindex",r);break;case"dir":case"role":case"viewBox":case"width":case"height":ct(e,n,r);break;case"style":kt(e,r,i);break;case"data":if("object"!==t){ct(e,"data",r);break}case"src":case"href":if(""===r&&("a"!==t||"href"!==n)){e.removeAttribute(n);break}if(null==r||"function"==typeof r||"symbol"==typeof r||"boolean"==typeof r){e.removeAttribute(n);break}r=Bt(""+r),e.setAttribute(n,r);break;case"action":case"formAction":if("function"==typeof r){e.setAttribute(n,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}if("function"==typeof i&&("formAction"===n?("input"!==t&&ud(e,t,"name",o.name,o,null),ud(e,t,"formEncType",o.formEncType,o,null),ud(e,t,"formMethod",o.formMethod,o,null),ud(e,t,"formTarget",o.formTarget,o,null)):(ud(e,t,"encType",o.encType,o,null),ud(e,t,"method",o.method,o,null),ud(e,t,"target",o.target,o,null))),null==r||"symbol"==typeof r||"boolean"==typeof r){e.removeAttribute(n);break}r=Bt(""+r),e.setAttribute(n,r);break;case"onClick":null!=r&&(e.onclick=_t);break;case"onScroll":null!=r&&Ku("scroll",e);break;case"onScrollEnd":null!=r&&Ku("scrollend",e);break;case"dangerouslySetInnerHTML":if(null!=r){if("object"!=typeof r||!("__html"in r))throw Error(a(61));if(null!=(n=r.__html)){if(null!=o.children)throw Error(a(60));e.innerHTML=n}}break;case"multiple":e.multiple=r&&"function"!=typeof r&&"symbol"!=typeof r;break;case"muted":e.muted=r&&"function"!=typeof r&&"symbol"!=typeof r;break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":case"autoFocus":break;case"xlinkHref":if(null==r||"function"==typeof r||"boolean"==typeof r||"symbol"==typeof r){e.removeAttribute("xlink:href");break}n=Bt(""+r),e.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",n);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":null!=r&&"function"!=typeof r&&"symbol"!=typeof r?e.setAttribute(n,""+r):e.removeAttribute(n);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":r&&"function"!=typeof r&&"symbol"!=typeof r?e.setAttribute(n,""):e.removeAttribute(n);break;case"capture":case"download":!0===r?e.setAttribute(n,""):!1!==r&&null!=r&&"function"!=typeof r&&"symbol"!=typeof r?e.setAttribute(n,r):e.removeAttribute(n);break;case"cols":case"rows":case"size":case"span":null!=r&&"function"!=typeof r&&"symbol"!=typeof r&&!isNaN(r)&&1<=r?e.setAttribute(n,r):e.removeAttribute(n);break;case"rowSpan":case"start":null==r||"function"==typeof r||"symbol"==typeof r||isNaN(r)?e.removeAttribute(n):e.setAttribute(n,r);break;case"popover":Ku("beforetoggle",e),Ku("toggle",e),st(e,"popover",r);break;case"xlinkActuate":ut(e,"http://www.w3.org/1999/xlink","xlink:actuate",r);break;case"xlinkArcrole":ut(e,"http://www.w3.org/1999/xlink","xlink:arcrole",r);break;case"xlinkRole":ut(e,"http://www.w3.org/1999/xlink","xlink:role",r);break;case"xlinkShow":ut(e,"http://www.w3.org/1999/xlink","xlink:show",r);break;case"xlinkTitle":ut(e,"http://www.w3.org/1999/xlink","xlink:title",r);break;case"xlinkType":ut(e,"http://www.w3.org/1999/xlink","xlink:type",r);break;case"xmlBase":ut(e,"http://www.w3.org/XML/1998/namespace","xml:base",r);break;case"xmlLang":ut(e,"http://www.w3.org/XML/1998/namespace","xml:lang",r);break;case"xmlSpace":ut(e,"http://www.w3.org/XML/1998/namespace","xml:space",r);break;case"is":st(e,"is",r);break;case"innerText":case"textContent":break;default:(!(2<n.length)||"o"!==n[0]&&"O"!==n[0]||"n"!==n[1]&&"N"!==n[1])&&st(e,n=Mt.get(n)||n,r)}}function dd(e,t,n,r,o,i){switch(n){case"style":kt(e,r,i);break;case"dangerouslySetInnerHTML":if(null!=r){if("object"!=typeof r||!("__html"in r))throw Error(a(61));if(null!=(n=r.__html)){if(null!=o.children)throw Error(a(60));e.innerHTML=n}}break;case"children":"string"==typeof r?xt(e,r):("number"==typeof r||"bigint"==typeof r)&&xt(e,""+r);break;case"onScroll":null!=r&&Ku("scroll",e);break;case"onScrollEnd":null!=r&&Ku("scrollend",e);break;case"onClick":null!=r&&(e.onclick=_t);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":case"innerText":case"textContent":break;default:nt.hasOwnProperty(n)||("o"!==n[0]||"n"!==n[1]||(o=n.endsWith("Capture"),t=n.slice(2,o?n.length-7:void 0),"function"==typeof(i=null!=(i=e[$e]||null)?i[n]:null)&&e.removeEventListener(t,i,o),"function"!=typeof r)?n in e?e[n]=r:!0===r?e.setAttribute(n,""):st(e,n,r):("function"!=typeof i&&null!==i&&(n in e?e[n]=null:e.hasAttribute(n)&&e.removeAttribute(n)),e.addEventListener(t,r,o)))}}function fd(e,t,n){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":Ku("error",e),Ku("load",e);var r,o=!1,i=!1;for(r in n)if(n.hasOwnProperty(r)){var l=n[r];if(null!=l)switch(r){case"src":o=!0;break;case"srcSet":i=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(a(137,t));default:ud(e,t,r,l,n,null)}}return i&&ud(e,t,"srcSet",n.srcSet,n,null),void(o&&ud(e,t,"src",n.src,n,null));case"input":Ku("invalid",e);var s=r=l=i=null,c=null,u=null;for(o in n)if(n.hasOwnProperty(o)){var d=n[o];if(null!=d)switch(o){case"name":i=d;break;case"type":l=d;break;case"checked":c=d;break;case"defaultChecked":u=d;break;case"value":r=d;break;case"defaultValue":s=d;break;case"children":case"dangerouslySetInnerHTML":if(null!=d)throw Error(a(137,t));break;default:ud(e,t,o,d,n,null)}}return void vt(e,r,s,c,u,l,i,!1);case"select":for(i in Ku("invalid",e),o=l=r=null,n)if(n.hasOwnProperty(i)&&null!=(s=n[i]))switch(i){case"value":r=s;break;case"defaultValue":l=s;break;case"multiple":o=s;default:ud(e,t,i,s,n,null)}return t=r,n=l,e.multiple=!!o,void(null!=t?wt(e,!!o,t,!1):null!=n&&wt(e,!!o,n,!0));case"textarea":for(l in Ku("invalid",e),r=i=o=null,n)if(n.hasOwnProperty(l)&&null!=(s=n[l]))switch(l){case"value":o=s;break;case"defaultValue":i=s;break;case"children":r=s;break;case"dangerouslySetInnerHTML":if(null!=s)throw Error(a(91));break;default:ud(e,t,l,s,n,null)}return void St(e,o,i,r);case"option":for(c in n)n.hasOwnProperty(c)&&null!=(o=n[c])&&("selected"===c?e.selected=o&&"function"!=typeof o&&"symbol"!=typeof o:ud(e,t,c,o,n,null));return;case"dialog":Ku("beforetoggle",e),Ku("toggle",e),Ku("cancel",e),Ku("close",e);break;case"iframe":case"object":Ku("load",e);break;case"video":case"audio":for(o=0;o<Uu.length;o++)Ku(Uu[o],e);break;case"image":Ku("error",e),Ku("load",e);break;case"details":Ku("toggle",e);break;case"embed":case"source":case"link":Ku("error",e),Ku("load",e);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(u in n)if(n.hasOwnProperty(u)&&null!=(o=n[u]))switch(u){case"children":case"dangerouslySetInnerHTML":throw Error(a(137,t));default:ud(e,t,u,o,n,null)}return;default:if(Rt(t)){for(d in n)n.hasOwnProperty(d)&&void 0!==(o=n[d])&&dd(e,t,d,o,n,void 0);return}}for(s in n)n.hasOwnProperty(s)&&null!=(o=n[s])&&ud(e,t,s,o,n,null)}function pd(e){switch(e){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}var hd=null,gd=null;function md(e){return 9===e.nodeType?e:e.ownerDocument}function Ad(e){switch(e){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function bd(e,t){if(0===e)switch(t){case"svg":return 1;case"math":return 2;default:return 0}return 1===e&&"foreignObject"===t?0:e}function vd(e,t){return"textarea"===e||"noscript"===e||"string"==typeof t.children||"number"==typeof t.children||"bigint"==typeof t.children||"object"==typeof t.dangerouslySetInnerHTML&&null!==t.dangerouslySetInnerHTML&&null!=t.dangerouslySetInnerHTML.__html}var yd=null,wd="function"==typeof setTimeout?setTimeout:void 0,Cd="function"==typeof clearTimeout?clearTimeout:void 0,Sd="function"==typeof Promise?Promise:void 0,xd="function"==typeof queueMicrotask?queueMicrotask:void 0!==Sd?function(e){return Sd.resolve(null).then(e).catch(Ed)}:wd;function Ed(e){setTimeout(function(){throw e})}function Id(e){return"head"===e}function kd(e,t){var n=t,r=0;do{var o=n.nextSibling;if(e.removeChild(n),o&&8===o.nodeType)if("/$"===(n=o.data)||"/&"===n){if(0===r)return e.removeChild(o),void Vf(t);r--}else if("$"===n||"$?"===n||"$~"===n||"$!"===n||"&"===n)r++;else if("html"===n)Fd(e.ownerDocument.documentElement);else if("head"===n){Fd(n=e.ownerDocument.head);for(var i=n.firstChild;i;){var a=i.nextSibling,l=i.nodeName;i[qe]||"SCRIPT"===l||"STYLE"===l||"LINK"===l&&"stylesheet"===i.rel.toLowerCase()||n.removeChild(i),i=a}}else"body"===n&&Fd(e.ownerDocument.body);n=o}while(n);Vf(t)}function Rd(e,t){var n=e;e=0;do{var r=n.nextSibling;if(1===n.nodeType?t?(n._stashedDisplay=n.style.display,n.style.display="none"):(n.style.display=n._stashedDisplay||"",""===n.getAttribute("style")&&n.removeAttribute("style")):3===n.nodeType&&(t?(n._stashedText=n.nodeValue,n.nodeValue=""):n.nodeValue=n._stashedText||""),r&&8===r.nodeType)if("/$"===(n=r.data)){if(0===e)break;e--}else"$"!==n&&"$?"!==n&&"$~"!==n&&"$!"!==n||e++;n=r}while(n)}function Md(e){var t=e.firstChild;for(t&&10===t.nodeType&&(t=t.nextSibling);t;){var n=t;switch(t=t.nextSibling,n.nodeName){case"HTML":case"HEAD":case"BODY":Md(n),Ye(n);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if("stylesheet"===n.rel.toLowerCase())continue}e.removeChild(n)}}function Pd(e,t){for(;8!==e.nodeType;){if((1!==e.nodeType||"INPUT"!==e.nodeName||"hidden"!==e.type)&&!t)return null;if(null===(e=Td(e.nextSibling)))return null}return e}function Bd(e){return"$?"===e.data||"$~"===e.data}function _d(e){return"$!"===e.data||"$?"===e.data&&"loading"!==e.ownerDocument.readyState}function Td(e){for(;null!=e;e=e.nextSibling){var t=e.nodeType;if(1===t||3===t)break;if(8===t){if("$"===(t=e.data)||"$!"===t||"$?"===t||"$~"===t||"&"===t||"F!"===t||"F"===t)break;if("/$"===t||"/&"===t)return null}}return e}var Od=null;function Dd(e){e=e.nextSibling;for(var t=0;e;){if(8===e.nodeType){var n=e.data;if("/$"===n||"/&"===n){if(0===t)return Td(e.nextSibling);t--}else"$"!==n&&"$!"!==n&&"$?"!==n&&"$~"!==n&&"&"!==n||t++}e=e.nextSibling}return null}function Nd(e){e=e.previousSibling;for(var t=0;e;){if(8===e.nodeType){var n=e.data;if("$"===n||"$!"===n||"$?"===n||"$~"===n||"&"===n){if(0===t)return e;t--}else"/$"!==n&&"/&"!==n||t++}e=e.previousSibling}return null}function Ld(e,t,n){switch(t=md(n),e){case"html":if(!(e=t.documentElement))throw Error(a(452));return e;case"head":if(!(e=t.head))throw Error(a(453));return e;case"body":if(!(e=t.body))throw Error(a(454));return e;default:throw Error(a(451))}}function Fd(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);Ye(e)}var Qd=new Map,jd=new Set;function zd(e){return"function"==typeof e.getRootNode?e.getRootNode():9===e.nodeType?e:e.ownerDocument}var $d=D.d;D.d={f:function(){var e=$d.f(),t=Zc();return e||t},r:function(e){var t=Je(e);null!==t&&5===t.tag&&"form"===t.type?rl(t):$d.r(e)},D:function(e){$d.D(e),Gd("dns-prefetch",e,null)},C:function(e,t){$d.C(e,t),Gd("preconnect",e,t)},L:function(e,t,n){$d.L(e,t,n);var r=Hd;if(r&&e&&t){var o='link[rel="preload"][as="'+At(t)+'"]';"image"===t&&n&&n.imageSrcSet?(o+='[imagesrcset="'+At(n.imageSrcSet)+'"]',"string"==typeof n.imageSizes&&(o+='[imagesizes="'+At(n.imageSizes)+'"]')):o+='[href="'+At(e)+'"]';var i=o;switch(t){case"style":i=Wd(e);break;case"script":i=Yd(e)}Qd.has(i)||(e=p({rel:"preload",href:"image"===t&&n&&n.imageSrcSet?void 0:e,as:t},n),Qd.set(i,e),null!==r.querySelector(o)||"style"===t&&r.querySelector(Ud(i))||"script"===t&&r.querySelector(Kd(i))||(fd(t=r.createElement("link"),"link",e),et(t),r.head.appendChild(t)))}},m:function(e,t){$d.m(e,t);var n=Hd;if(n&&e){var r=t&&"string"==typeof t.as?t.as:"script",o='link[rel="modulepreload"][as="'+At(r)+'"][href="'+At(e)+'"]',i=o;switch(r){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":i=Yd(e)}if(!Qd.has(i)&&(e=p({rel:"modulepreload",href:e},t),Qd.set(i,e),null===n.querySelector(o))){switch(r){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(n.querySelector(Kd(i)))return}fd(r=n.createElement("link"),"link",e),et(r),n.head.appendChild(r)}}},X:function(e,t){$d.X(e,t);var n=Hd;if(n&&e){var r=Ze(n).hoistableScripts,o=Yd(e),i=r.get(o);i||((i=n.querySelector(Kd(o)))||(e=p({src:e,async:!0},t),(t=Qd.get(o))&&ef(e,t),et(i=n.createElement("script")),fd(i,"link",e),n.head.appendChild(i)),i={type:"script",instance:i,count:1,state:null},r.set(o,i))}},S:function(e,t,n){$d.S(e,t,n);var r=Hd;if(r&&e){var o=Ze(r).hoistableStyles,i=Wd(e);t=t||"default";var a=o.get(i);if(!a){var l={loading:0,preload:null};if(a=r.querySelector(Ud(i)))l.loading=5;else{e=p({rel:"stylesheet",href:e,"data-precedence":t},n),(n=Qd.get(i))&&Zd(e,n);var s=a=r.createElement("link");et(s),fd(s,"link",e),s._p=new Promise(function(e,t){s.onload=e,s.onerror=t}),s.addEventListener("load",function(){l.loading|=1}),s.addEventListener("error",function(){l.loading|=2}),l.loading|=4,Xd(a,t,r)}a={type:"stylesheet",instance:a,count:1,state:l},o.set(i,a)}}},M:function(e,t){$d.M(e,t);var n=Hd;if(n&&e){var r=Ze(n).hoistableScripts,o=Yd(e),i=r.get(o);i||((i=n.querySelector(Kd(o)))||(e=p({src:e,async:!0,type:"module"},t),(t=Qd.get(o))&&ef(e,t),et(i=n.createElement("script")),fd(i,"link",e),n.head.appendChild(i)),i={type:"script",instance:i,count:1,state:null},r.set(o,i))}}};var Hd="undefined"==typeof document?null:document;function Gd(e,t,n){var r=Hd;if(r&&"string"==typeof t&&t){var o=At(t);o='link[rel="'+e+'"][href="'+o+'"]',"string"==typeof n&&(o+='[crossorigin="'+n+'"]'),jd.has(o)||(jd.add(o),e={rel:e,crossOrigin:n,href:t},null===r.querySelector(o)&&(fd(t=r.createElement("link"),"link",e),et(t),r.head.appendChild(t)))}}function Vd(e,t,n,r){var o,i,l,s,c=(c=W.current)?zd(c):null;if(!c)throw Error(a(446));switch(e){case"meta":case"title":return null;case"style":return"string"==typeof n.precedence&&"string"==typeof n.href?(t=Wd(n.href),(r=(n=Ze(c).hoistableStyles).get(t))||(r={type:"style",instance:null,count:0,state:null},n.set(t,r)),r):{type:"void",instance:null,count:0,state:null};case"link":if("stylesheet"===n.rel&&"string"==typeof n.href&&"string"==typeof n.precedence){e=Wd(n.href);var u=Ze(c).hoistableStyles,d=u.get(e);if(d||(c=c.ownerDocument||c,d={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},u.set(e,d),(u=c.querySelector(Ud(e)))&&!u._p&&(d.instance=u,d.state.loading=5),Qd.has(e)||(n={rel:"preload",as:"style",href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},Qd.set(e,n),u||(o=c,i=e,l=n,s=d.state,o.querySelector('link[rel="preload"][as="style"]['+i+"]")?s.loading=1:(i=o.createElement("link"),s.preload=i,i.addEventListener("load",function(){return s.loading|=1}),i.addEventListener("error",function(){return s.loading|=2}),fd(i,"link",l),et(i),o.head.appendChild(i))))),t&&null===r)throw Error(a(528,""));return d}if(t&&null!==r)throw Error(a(529,""));return null;case"script":return t=n.async,"string"==typeof(n=n.src)&&t&&"function"!=typeof t&&"symbol"!=typeof t?(t=Yd(n),(r=(n=Ze(c).hoistableScripts).get(t))||(r={type:"script",instance:null,count:0,state:null},n.set(t,r)),r):{type:"void",instance:null,count:0,state:null};default:throw Error(a(444,e))}}function Wd(e){return'href="'+At(e)+'"'}function Ud(e){return'link[rel="stylesheet"]['+e+"]"}function qd(e){return p({},e,{"data-precedence":e.precedence,precedence:null})}function Yd(e){return'[src="'+At(e)+'"]'}function Kd(e){return"script[async]"+e}function Jd(e,t,n){if(t.count++,null===t.instance)switch(t.type){case"style":var r=e.querySelector('style[data-href~="'+At(n.href)+'"]');if(r)return t.instance=r,et(r),r;var o=p({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return et(r=(e.ownerDocument||e).createElement("style")),fd(r,"style",o),Xd(r,n.precedence,e),t.instance=r;case"stylesheet":o=Wd(n.href);var i=e.querySelector(Ud(o));if(i)return t.state.loading|=4,t.instance=i,et(i),i;r=qd(n),(o=Qd.get(o))&&Zd(r,o),et(i=(e.ownerDocument||e).createElement("link"));var l=i;return l._p=new Promise(function(e,t){l.onload=e,l.onerror=t}),fd(i,"link",r),t.state.loading|=4,Xd(i,n.precedence,e),t.instance=i;case"script":return i=Yd(n.src),(o=e.querySelector(Kd(i)))?(t.instance=o,et(o),o):(r=n,(o=Qd.get(i))&&ef(r=p({},n),o),et(o=(e=e.ownerDocument||e).createElement("script")),fd(o,"link",r),e.head.appendChild(o),t.instance=o);case"void":return null;default:throw Error(a(443,t.type))}else"stylesheet"===t.type&&!(4&t.state.loading)&&(r=t.instance,t.state.loading|=4,Xd(r,n.precedence,e));return t.instance}function Xd(e,t,n){for(var r=n.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),o=r.length?r[r.length-1]:null,i=o,a=0;a<r.length;a++){var l=r[a];if(l.dataset.precedence===t)i=l;else if(i!==o)break}i?i.parentNode.insertBefore(e,i.nextSibling):(t=9===n.nodeType?n.head:n).insertBefore(e,t.firstChild)}function Zd(e,t){null==e.crossOrigin&&(e.crossOrigin=t.crossOrigin),null==e.referrerPolicy&&(e.referrerPolicy=t.referrerPolicy),null==e.title&&(e.title=t.title)}function ef(e,t){null==e.crossOrigin&&(e.crossOrigin=t.crossOrigin),null==e.referrerPolicy&&(e.referrerPolicy=t.referrerPolicy),null==e.integrity&&(e.integrity=t.integrity)}var tf=null;function nf(e,t,n){if(null===tf){var r=new Map,o=tf=new Map;o.set(n,r)}else(r=(o=tf).get(n))||(r=new Map,o.set(n,r));if(r.has(e))return r;for(r.set(e,null),n=n.getElementsByTagName(e),o=0;o<n.length;o++){var i=n[o];if(!(i[qe]||i[ze]||"link"===e&&"stylesheet"===i.getAttribute("rel"))&&"http://www.w3.org/2000/svg"!==i.namespaceURI){var a=i.getAttribute(t)||"";a=e+a;var l=r.get(a);l?l.push(i):r.set(a,[i])}}return r}function rf(e,t,n){(e=e.ownerDocument||e).head.insertBefore(n,"title"===t?e.querySelector("head > title"):null)}function of(e){return!!("stylesheet"!==e.type||3&e.state.loading)}var af=0;function lf(){if(this.count--,0===this.count&&(0===this.imgCount||!this.waitingForImages))if(this.stylesheets)cf(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}var sf=null;function cf(e,t){e.stylesheets=null,null!==e.unsuspend&&(e.count++,sf=new Map,t.forEach(uf,e),sf=null,lf.call(e))}function uf(e,t){if(!(4&t.state.loading)){var n=sf.get(e);if(n)var r=n.get(null);else{n=new Map,sf.set(e,n);for(var o=e.querySelectorAll("link[data-precedence],style[data-precedence]"),i=0;i<o.length;i++){var a=o[i];"LINK"!==a.nodeName&&"not all"===a.getAttribute("media")||(n.set(a.dataset.precedence,a),r=a)}r&&n.set(null,r)}a=(o=t.instance).getAttribute("data-precedence"),(i=n.get(a)||r)===r&&n.set(null,o),n.set(a,o),this.count++,r=lf.bind(this),o.addEventListener("load",r),o.addEventListener("error",r),i?i.parentNode.insertBefore(o,i.nextSibling):(e=9===e.nodeType?e.head:e).insertBefore(o,e.firstChild),t.state.loading|=4}}var df={$$typeof:w,Provider:null,Consumer:null,_currentValue:N,_currentValue2:N,_threadCount:0};function ff(e,t,n,r,o,i,a,l,s){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Be(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Be(0),this.hiddenUpdates=Be(null),this.identifierPrefix=r,this.onUncaughtError=o,this.onCaughtError=i,this.onRecoverableError=a,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=s,this.incompleteTransitions=new Map}function pf(e,t,n,r,o,i,a,l,s,c,u,d){return e=new ff(e,t,n,a,s,c,u,d,l),t=1,!0===i&&(t|=24),i=Fr(3,null,null,t),e.current=i,i.stateNode=e,(t=jo()).refCount++,e.pooledCache=t,t.refCount++,i.memoizedState={element:r,isDehydrated:n,cache:t},Ai(i),e}function hf(e){return e?e=Nr:Nr}function gf(e,t,n,r,o,i){o=hf(o),null===r.context?r.context=o:r.pendingContext=o,(r=vi(t)).payload={element:n},null!==(i=void 0===i?null:i)&&(r.callback=i),null!==(n=yi(e,r,t))&&(qc(n,0,t),wi(n,e,t))}function mf(e,t){if(null!==(e=e.memoizedState)&&null!==e.dehydrated){var n=e.retryLane;e.retryLane=0!==n&&n<t?n:t}}function Af(e,t){mf(e,t),(e=e.alternate)&&mf(e,t)}function bf(e){if(13===e.tag||31===e.tag){var t=Tr(e,67108864);null!==t&&qc(t,0,67108864),Af(e,67108864)}}function vf(e){if(13===e.tag||31===e.tag){var t=Wc(),n=Tr(e,t=Ne(t));null!==n&&qc(n,0,t),Af(e,t)}}var yf=!0;function wf(e,t,n,r){var o=O.T;O.T=null;var i=D.p;try{D.p=2,Sf(e,t,n,r)}finally{D.p=i,O.T=o}}function Cf(e,t,n,r){var o=O.T;O.T=null;var i=D.p;try{D.p=8,Sf(e,t,n,r)}finally{D.p=i,O.T=o}}function Sf(e,t,n,r){if(yf){var o=xf(r);if(null===o)td(e,t,r,Ef,n),Nf(e,r);else if(function(e,t,n,r,o){switch(t){case"focusin":return Mf=Lf(Mf,e,t,n,r,o),!0;case"dragenter":return Pf=Lf(Pf,e,t,n,r,o),!0;case"mouseover":return Bf=Lf(Bf,e,t,n,r,o),!0;case"pointerover":var i=o.pointerId;return _f.set(i,Lf(_f.get(i)||null,e,t,n,r,o)),!0;case"gotpointercapture":return i=o.pointerId,Tf.set(i,Lf(Tf.get(i)||null,e,t,n,r,o)),!0}return!1}(o,e,t,n,r))r.stopPropagation();else if(Nf(e,r),4&t&&-1<Df.indexOf(e)){for(;null!==o;){var i=Je(o);if(null!==i)switch(i.tag){case 3:if((i=i.stateNode).current.memoizedState.isDehydrated){var a=Ie(i.pendingLanes);if(0!==a){var l=i;for(l.pendingLanes|=2,l.entangledLanes|=2;a;){var s=1<<31-ye(a);l.entanglements[1]|=s,a&=~s}Du(i),!(6&pc)&&(Oc=se()+500,Nu(0,!1))}}break;case 31:case 13:null!==(l=Tr(i,2))&&qc(l,0,2),Zc(),Af(i,2)}if(null===(i=xf(r))&&td(e,t,r,Ef,n),i===o)break;o=i}null!==o&&r.stopPropagation()}else td(e,t,r,null,n)}}function xf(e){return If(e=Ot(e))}var Ef=null;function If(e){if(Ef=null,null!==(e=Ke(e))){var t=s(e);if(null===t)e=null;else{var n=t.tag;if(13===n){if(null!==(e=c(t)))return e;e=null}else if(31===n){if(null!==(e=u(t)))return e;e=null}else if(3===n){if(t.stateNode.current.memoizedState.isDehydrated)return 3===t.tag?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return Ef=e,null}function kf(e){switch(e){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(ce()){case ue:return 2;case de:return 8;case fe:case pe:return 32;case he:return 268435456;default:return 32}default:return 32}}var Rf=!1,Mf=null,Pf=null,Bf=null,_f=new Map,Tf=new Map,Of=[],Df="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");function Nf(e,t){switch(e){case"focusin":case"focusout":Mf=null;break;case"dragenter":case"dragleave":Pf=null;break;case"mouseover":case"mouseout":Bf=null;break;case"pointerover":case"pointerout":_f.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":Tf.delete(t.pointerId)}}function Lf(e,t,n,r,o,i){return null===e||e.nativeEvent!==i?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:i,targetContainers:[o]},null!==t&&null!==(t=Je(t))&&bf(t),e):(e.eventSystemFlags|=r,t=e.targetContainers,null!==o&&-1===t.indexOf(o)&&t.push(o),e)}function Ff(e){var t=Ke(e.target);if(null!==t){var n=s(t);if(null!==n)if(13===(t=n.tag)){if(null!==(t=c(n)))return e.blockedOn=t,void Qe(e.priority,function(){vf(n)})}else if(31===t){if(null!==(t=u(n)))return e.blockedOn=t,void Qe(e.priority,function(){vf(n)})}else if(3===t&&n.stateNode.current.memoizedState.isDehydrated)return void(e.blockedOn=3===n.tag?n.stateNode.containerInfo:null)}e.blockedOn=null}function Qf(e){if(null!==e.blockedOn)return!1;for(var t=e.targetContainers;0<t.length;){var n=xf(e.nativeEvent);if(null!==n)return null!==(t=Je(n))&&bf(t),e.blockedOn=n,!1;var r=new(n=e.nativeEvent).constructor(n.type,n);Tt=r,n.target.dispatchEvent(r),Tt=null,t.shift()}return!0}function jf(e,t,n){Qf(e)&&n.delete(t)}function zf(){Rf=!1,null!==Mf&&Qf(Mf)&&(Mf=null),null!==Pf&&Qf(Pf)&&(Pf=null),null!==Bf&&Qf(Bf)&&(Bf=null),_f.forEach(jf),Tf.forEach(jf)}function $f(e,t){e.blockedOn===t&&(e.blockedOn=null,Rf||(Rf=!0,r.unstable_scheduleCallback(r.unstable_NormalPriority,zf)))}var Hf=null;function Gf(e){Hf!==e&&(Hf=e,r.unstable_scheduleCallback(r.unstable_NormalPriority,function(){Hf===e&&(Hf=null);for(var t=0;t<e.length;t+=3){var n=e[t],r=e[t+1],o=e[t+2];if("function"!=typeof r){if(null===If(r||n))continue;break}var i=Je(n);null!==i&&(e.splice(t,3),t-=3,tl(i,{pending:!0,data:o,method:n.method,action:r},r,o))}}))}function Vf(e){function t(t){return $f(t,e)}null!==Mf&&$f(Mf,e),null!==Pf&&$f(Pf,e),null!==Bf&&$f(Bf,e),_f.forEach(t),Tf.forEach(t);for(var n=0;n<Of.length;n++){var r=Of[n];r.blockedOn===e&&(r.blockedOn=null)}for(;0<Of.length&&null===(n=Of[0]).blockedOn;)Ff(n),null===n.blockedOn&&Of.shift();if(null!=(n=(e.ownerDocument||e).$$reactFormReplay))for(r=0;r<n.length;r+=3){var o=n[r],i=n[r+1],a=o[$e]||null;if("function"==typeof i)a||Gf(n);else if(a){var l=null;if(i&&i.hasAttribute("formAction")){if(o=i,a=i[$e]||null)l=a.formAction;else if(null!==If(o))continue}else l=a.action;"function"==typeof l?n[r+1]=l:(n.splice(r,3),r-=3),Gf(n)}}}function Wf(){function e(e){e.canIntercept&&"react-transition"===e.info&&e.intercept({handler:function(){return new Promise(function(e){return o=e})},focusReset:"manual",scroll:"manual"})}function t(){null!==o&&(o(),o=null),r||setTimeout(n,20)}function n(){if(!r&&!navigation.transition){var e=navigation.currentEntry;e&&null!=e.url&&navigation.navigate(e.url,{state:e.getState(),info:"react-transition",history:"replace"})}}if("object"==typeof navigation){var r=!1,o=null;return navigation.addEventListener("navigate",e),navigation.addEventListener("navigatesuccess",t),navigation.addEventListener("navigateerror",t),setTimeout(n,100),function(){r=!0,navigation.removeEventListener("navigate",e),navigation.removeEventListener("navigatesuccess",t),navigation.removeEventListener("navigateerror",t),null!==o&&(o(),o=null)}}}function Uf(e){this._internalRoot=e}function qf(e){this._internalRoot=e}qf.prototype.render=Uf.prototype.render=function(e){var t=this._internalRoot;if(null===t)throw Error(a(409));gf(t.current,Wc(),e,t,null,null)},qf.prototype.unmount=Uf.prototype.unmount=function(){var e=this._internalRoot;if(null!==e){this._internalRoot=null;var t=e.containerInfo;gf(e.current,2,null,e,null,null),Zc(),t[He]=null}},qf.prototype.unstable_scheduleHydration=function(e){if(e){var t=Fe();e={blockedOn:null,target:e,priority:t};for(var n=0;n<Of.length&&0!==t&&t<Of[n].priority;n++);Of.splice(n,0,e),0===n&&Ff(e)}};var Yf=o.version;if("19.2.7"!==Yf)throw Error(a(527,Yf,"19.2.7"));D.findDOMNode=function(e){var t=e._reactInternals;if(void 0===t){if("function"==typeof e.render)throw Error(a(188));throw e=Object.keys(e).join(","),Error(a(268,e))}return e=function(e){var t=e.alternate;if(!t){if(null===(t=s(e)))throw Error(a(188));return t!==e?null:e}for(var n=e,r=t;;){var o=n.return;if(null===o)break;var i=o.alternate;if(null===i){if(null!==(r=o.return)){n=r;continue}break}if(o.child===i.child){for(i=o.child;i;){if(i===n)return d(o),e;if(i===r)return d(o),t;i=i.sibling}throw Error(a(188))}if(n.return!==r.return)n=o,r=i;else{for(var l=!1,c=o.child;c;){if(c===n){l=!0,n=o,r=i;break}if(c===r){l=!0,r=o,n=i;break}c=c.sibling}if(!l){for(c=i.child;c;){if(c===n){l=!0,n=i,r=o;break}if(c===r){l=!0,r=i,n=o;break}c=c.sibling}if(!l)throw Error(a(189))}}if(n.alternate!==r)throw Error(a(190))}if(3!==n.tag)throw Error(a(188));return n.stateNode.current===n?e:t}(t),null===(e=null!==e?f(e):null)?null:e.stateNode};var Kf={bundleType:0,version:"19.2.7",rendererPackageName:"react-dom",currentDispatcherRef:O,reconcilerVersion:"19.2.7"};if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__){var Jf=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Jf.isDisabled&&Jf.supportsFiber)try{Ae=Jf.inject(Kf),be=Jf}catch(e){}}t.createRoot=function(e,t){if(!l(e))throw Error(a(299));var n=!1,r="",o=xl,i=El,s=Il;return null!=t&&(!0===t.unstable_strictMode&&(n=!0),void 0!==t.identifierPrefix&&(r=t.identifierPrefix),void 0!==t.onUncaughtError&&(o=t.onUncaughtError),void 0!==t.onCaughtError&&(i=t.onCaughtError),void 0!==t.onRecoverableError&&(s=t.onRecoverableError)),t=pf(e,1,!1,null,0,n,r,null,o,i,s,Wf),e[He]=t.current,Zu(e),new Uf(t)},t.hydrateRoot=function(e,t,n){if(!l(e))throw Error(a(299));var r=!1,o="",i=xl,s=El,c=Il,u=null;return null!=n&&(!0===n.unstable_strictMode&&(r=!0),void 0!==n.identifierPrefix&&(o=n.identifierPrefix),void 0!==n.onUncaughtError&&(i=n.onUncaughtError),void 0!==n.onCaughtError&&(s=n.onCaughtError),void 0!==n.onRecoverableError&&(c=n.onRecoverableError),void 0!==n.formState&&(u=n.formState)),(t=pf(e,1,!0,t,0,r,o,u,i,s,c,Wf)).context=hf(null),n=t.current,(o=vi(r=Ne(r=Wc()))).callback=null,yi(n,o,r),n=r,t.current.lanes=n,_e(t,n),Du(t),e[He]=t.current,Zu(e),new qf(t)},t.version="19.2.7"},2826(e,t,n){"use strict";var r=n(405);function o(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n])}return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function i(){}var a={d:{f:i,r:function(){throw Error(o(522))},D:i,C:i,L:i,m:i,X:i,S:i,M:i},p:0,findDOMNode:null},l=Symbol.for("react.portal"),s=r.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function c(e,t){return"font"===e?"":"string"==typeof t?"use-credentials"===t?t:"":void 0}t.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=a,t.createPortal=function(e,t){var n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;if(!t||1!==t.nodeType&&9!==t.nodeType&&11!==t.nodeType)throw Error(o(299));return function(e,t,n){var r=3<arguments.length&&void 0!==arguments[3]?arguments[3]:null;return{$$typeof:l,key:null==r?null:""+r,children:e,containerInfo:t,implementation:n}}(e,t,null,n)},t.flushSync=function(e){var t=s.T,n=a.p;try{if(s.T=null,a.p=2,e)return e()}finally{s.T=t,a.p=n,a.d.f()}},t.preconnect=function(e,t){"string"==typeof e&&(t=t?"string"==typeof(t=t.crossOrigin)?"use-credentials"===t?t:"":void 0:null,a.d.C(e,t))},t.prefetchDNS=function(e){"string"==typeof e&&a.d.D(e)},t.preinit=function(e,t){if("string"==typeof e&&t&&"string"==typeof t.as){var n=t.as,r=c(n,t.crossOrigin),o="string"==typeof t.integrity?t.integrity:void 0,i="string"==typeof t.fetchPriority?t.fetchPriority:void 0;"style"===n?a.d.S(e,"string"==typeof t.precedence?t.precedence:void 0,{crossOrigin:r,integrity:o,fetchPriority:i}):"script"===n&&a.d.X(e,{crossOrigin:r,integrity:o,fetchPriority:i,nonce:"string"==typeof t.nonce?t.nonce:void 0})}},t.preinitModule=function(e,t){if("string"==typeof e)if("object"==typeof t&&null!==t){if(null==t.as||"script"===t.as){var n=c(t.as,t.crossOrigin);a.d.M(e,{crossOrigin:n,integrity:"string"==typeof t.integrity?t.integrity:void 0,nonce:"string"==typeof t.nonce?t.nonce:void 0})}}else null==t&&a.d.M(e)},t.preload=function(e,t){if("string"==typeof e&&"object"==typeof t&&null!==t&&"string"==typeof t.as){var n=t.as,r=c(n,t.crossOrigin);a.d.L(e,n,{crossOrigin:r,integrity:"string"==typeof t.integrity?t.integrity:void 0,nonce:"string"==typeof t.nonce?t.nonce:void 0,type:"string"==typeof t.type?t.type:void 0,fetchPriority:"string"==typeof t.fetchPriority?t.fetchPriority:void 0,referrerPolicy:"string"==typeof t.referrerPolicy?t.referrerPolicy:void 0,imageSrcSet:"string"==typeof t.imageSrcSet?t.imageSrcSet:void 0,imageSizes:"string"==typeof t.imageSizes?t.imageSizes:void 0,media:"string"==typeof t.media?t.media:void 0})}},t.preloadModule=function(e,t){if("string"==typeof e)if(t){var n=c(t.as,t.crossOrigin);a.d.m(e,{as:"string"==typeof t.as&&"script"!==t.as?t.as:void 0,crossOrigin:n,integrity:"string"==typeof t.integrity?t.integrity:void 0})}else a.d.m(e)},t.requestFormReset=function(e){a.d.r(e)},t.unstable_batchedUpdates=function(e,t){return e(t)},t.useFormState=function(e,t,n){return s.H.useFormState(e,t,n)},t.useFormStatus=function(){return s.H.useHostTransitionStatus()},t.version="19.2.7"},7541(e,t,n){"use strict";!function e(){if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(e){console.error(e)}}(),e.exports=n(4482)},7868(e,t,n){"use strict";!function e(){if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(e){console.error(e)}}(),e.exports=n(2826)},5360(e,t){"use strict";var n="function"==typeof Symbol&&Symbol.for,r=n?Symbol.for("react.element"):60103,o=n?Symbol.for("react.portal"):60106,i=n?Symbol.for("react.fragment"):60107,a=n?Symbol.for("react.strict_mode"):60108,l=n?Symbol.for("react.profiler"):60114,s=n?Symbol.for("react.provider"):60109,c=n?Symbol.for("react.context"):60110,u=n?Symbol.for("react.async_mode"):60111,d=n?Symbol.for("react.concurrent_mode"):60111,f=n?Symbol.for("react.forward_ref"):60112,p=n?Symbol.for("react.suspense"):60113,h=n?Symbol.for("react.suspense_list"):60120,g=n?Symbol.for("react.memo"):60115,m=n?Symbol.for("react.lazy"):60116,A=n?Symbol.for("react.block"):60121,b=n?Symbol.for("react.fundamental"):60117,v=n?Symbol.for("react.responder"):60118,y=n?Symbol.for("react.scope"):60119;function w(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case r:switch(e=e.type){case u:case d:case i:case l:case a:case p:return e;default:switch(e=e&&e.$$typeof){case c:case f:case m:case g:case s:return e;default:return t}}case o:return t}}}function C(e){return w(e)===d}t.AsyncMode=u,t.ConcurrentMode=d,t.ContextConsumer=c,t.ContextProvider=s,t.Element=r,t.ForwardRef=f,t.Fragment=i,t.Lazy=m,t.Memo=g,t.Portal=o,t.Profiler=l,t.StrictMode=a,t.Suspense=p,t.isAsyncMode=function(e){return C(e)||w(e)===u},t.isConcurrentMode=C,t.isContextConsumer=function(e){return w(e)===c},t.isContextProvider=function(e){return w(e)===s},t.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===r},t.isForwardRef=function(e){return w(e)===f},t.isFragment=function(e){return w(e)===i},t.isLazy=function(e){return w(e)===m},t.isMemo=function(e){return w(e)===g},t.isPortal=function(e){return w(e)===o},t.isProfiler=function(e){return w(e)===l},t.isStrictMode=function(e){return w(e)===a},t.isSuspense=function(e){return w(e)===p},t.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===i||e===d||e===l||e===a||e===p||e===h||"object"==typeof e&&null!==e&&(e.$$typeof===m||e.$$typeof===g||e.$$typeof===s||e.$$typeof===c||e.$$typeof===f||e.$$typeof===b||e.$$typeof===v||e.$$typeof===y||e.$$typeof===A)},t.typeOf=w},7020(e,t,n){"use strict";e.exports=n(5360)},85(e,t){"use strict";Symbol.for("react.transitional.element"),Symbol.for("react.portal");var n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),i=Symbol.for("react.consumer"),a=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),s=Symbol.for("react.suspense"),c=Symbol.for("react.suspense_list"),u=Symbol.for("react.memo"),d=Symbol.for("react.lazy"),f=(Symbol.for("react.view_transition"),Symbol.for("react.client.reference"));t.Hy=function(e){return"string"==typeof e||"function"==typeof e||e===n||e===o||e===r||e===s||e===c||"object"==typeof e&&null!==e&&(e.$$typeof===d||e.$$typeof===u||e.$$typeof===a||e.$$typeof===i||e.$$typeof===l||e.$$typeof===f||void 0!==e.getModuleId)}},8423(e,t,n){"use strict";n.d(t,{Ay:()=>g});var r=n(4722),o=n(2993),i=n(405),a=n(7868);var l=n(7619),s="unmounted",c="exited",u="entering",d="entered",f="exiting",p=function(e){function t(t,n){var r;r=e.call(this,t,n)||this;var o,i=n&&!n.isMounting?t.enter:t.appear;return r.appearStatus=null,t.in?i?(o=c,r.appearStatus=u):o=d:o=t.unmountOnExit||t.mountOnEnter?s:c,r.state={status:o},r.nextCallback=null,r}(0,o.A)(t,e),t.getDerivedStateFromProps=function(e,t){return e.in&&t.status===s?{status:c}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(e){var t=null;if(e!==this.props){var n=this.state.status;this.props.in?n!==u&&n!==d&&(t=u):n!==u&&n!==d||(t=f)}this.updateStatus(!1,t)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var e,t,n,r=this.props.timeout;return e=t=n=r,null!=r&&"number"!=typeof r&&(e=r.exit,t=r.enter,n=void 0!==r.appear?r.appear:t),{exit:e,enter:t,appear:n}},n.updateStatus=function(e,t){if(void 0===e&&(e=!1),null!==t)if(this.cancelNextCallback(),t===u){if(this.props.unmountOnExit||this.props.mountOnEnter){var n=this.props.nodeRef?this.props.nodeRef.current:a.findDOMNode(this);n&&function(e){e.scrollTop}(n)}this.performEnter(e)}else this.performExit();else this.props.unmountOnExit&&this.state.status===c&&this.setState({status:s})},n.performEnter=function(e){var t=this,n=this.props.enter,r=this.context?this.context.isMounting:e,o=this.props.nodeRef?[r]:[a.findDOMNode(this),r],i=o[0],l=o[1],s=this.getTimeouts(),c=r?s.appear:s.enter;e||n?(this.props.onEnter(i,l),this.safeSetState({status:u},function(){t.props.onEntering(i,l),t.onTransitionEnd(c,function(){t.safeSetState({status:d},function(){t.props.onEntered(i,l)})})})):this.safeSetState({status:d},function(){t.props.onEntered(i)})},n.performExit=function(){var e=this,t=this.props.exit,n=this.getTimeouts(),r=this.props.nodeRef?void 0:a.findDOMNode(this);t?(this.props.onExit(r),this.safeSetState({status:f},function(){e.props.onExiting(r),e.onTransitionEnd(n.exit,function(){e.safeSetState({status:c},function(){e.props.onExited(r)})})})):this.safeSetState({status:c},function(){e.props.onExited(r)})},n.cancelNextCallback=function(){null!==this.nextCallback&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(e,t){t=this.setNextCallback(t),this.setState(e,t)},n.setNextCallback=function(e){var t=this,n=!0;return this.nextCallback=function(r){n&&(n=!1,t.nextCallback=null,e(r))},this.nextCallback.cancel=function(){n=!1},this.nextCallback},n.onTransitionEnd=function(e,t){this.setNextCallback(t);var n=this.props.nodeRef?this.props.nodeRef.current:a.findDOMNode(this),r=null==e&&!this.props.addEndListener;if(n&&!r){if(this.props.addEndListener){var o=this.props.nodeRef?[this.nextCallback]:[n,this.nextCallback],i=o[0],l=o[1];this.props.addEndListener(i,l)}null!=e&&setTimeout(this.nextCallback,e)}else setTimeout(this.nextCallback,0)},n.render=function(){var e=this.state.status;if(e===s)return null;var t=this.props,n=t.children,o=(t.in,t.mountOnEnter,t.unmountOnExit,t.appear,t.enter,t.exit,t.timeout,t.addEndListener,t.onEnter,t.onEntering,t.onEntered,t.onExit,t.onExiting,t.onExited,t.nodeRef,(0,r.A)(t,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]));return i.createElement(l.A.Provider,{value:null},"function"==typeof n?n(e,o):i.cloneElement(i.Children.only(n),o))},t}(i.Component);function h(){}p.contextType=l.A,p.propTypes={},p.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:h,onEntering:h,onEntered:h,onExit:h,onExiting:h,onExited:h},p.UNMOUNTED=s,p.EXITED=c,p.ENTERING=u,p.ENTERED=d,p.EXITING=f;const g=p},7619(e,t,n){"use strict";n.d(t,{A:()=>r});const r=n(405).createContext(null)},8881(e,t){"use strict";var n=Symbol.for("react.transitional.element"),r=Symbol.for("react.fragment");function o(e,t,r){var o=null;if(void 0!==r&&(o=""+r),void 0!==t.key&&(o=""+t.key),"key"in t)for(var i in r={},t)"key"!==i&&(r[i]=t[i]);else r=t;return t=r.ref,{$$typeof:n,type:e,key:o,ref:void 0!==t?t:null,props:r}}t.Fragment=r,t.jsx=o,t.jsxs=o},7866(e,t){"use strict";var n=Symbol.for("react.transitional.element"),r=Symbol.for("react.portal"),o=Symbol.for("react.fragment"),i=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),l=Symbol.for("react.consumer"),s=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),d=Symbol.for("react.memo"),f=Symbol.for("react.lazy"),p=Symbol.for("react.activity"),h=Symbol.iterator,g={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},m=Object.assign,A={};function b(e,t,n){this.props=e,this.context=t,this.refs=A,this.updater=n||g}function v(){}function y(e,t,n){this.props=e,this.context=t,this.refs=A,this.updater=n||g}b.prototype.isReactComponent={},b.prototype.setState=function(e,t){if("object"!=typeof e&&"function"!=typeof e&&null!=e)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")},b.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},v.prototype=b.prototype;var w=y.prototype=new v;w.constructor=y,m(w,b.prototype),w.isPureReactComponent=!0;var C=Array.isArray;function S(){}var x={H:null,A:null,T:null,S:null},E=Object.prototype.hasOwnProperty;function I(e,t,r){var o=r.ref;return{$$typeof:n,type:e,key:t,ref:void 0!==o?o:null,props:r}}function k(e){return"object"==typeof e&&null!==e&&e.$$typeof===n}var R=/\/+/g;function M(e,t){return"object"==typeof e&&null!==e&&null!=e.key?(n=""+e.key,r={"=":"=0",":":"=2"},"$"+n.replace(/[=:]/g,function(e){return r[e]})):t.toString(36);var n,r}function P(e,t,o,i,a){var l=typeof e;"undefined"!==l&&"boolean"!==l||(e=null);var s,c,u=!1;if(null===e)u=!0;else switch(l){case"bigint":case"string":case"number":u=!0;break;case"object":switch(e.$$typeof){case n:case r:u=!0;break;case f:return P((u=e._init)(e._payload),t,o,i,a)}}if(u)return a=a(e),u=""===i?"."+M(e,0):i,C(a)?(o="",null!=u&&(o=u.replace(R,"$&/")+"/"),P(a,t,o,"",function(e){return e})):null!=a&&(k(a)&&(s=a,c=o+(null==a.key||e&&e.key===a.key?"":(""+a.key).replace(R,"$&/")+"/")+u,a=I(s.type,c,s.props)),t.push(a)),1;u=0;var d,p=""===i?".":i+":";if(C(e))for(var g=0;g<e.length;g++)u+=P(i=e[g],t,o,l=p+M(i,g),a);else if("function"==typeof(g=null===(d=e)||"object"!=typeof d?null:"function"==typeof(d=h&&d[h]||d["@@iterator"])?d:null))for(e=g.call(e),g=0;!(i=e.next()).done;)u+=P(i=i.value,t,o,l=p+M(i,g++),a);else if("object"===l){if("function"==typeof e.then)return P(function(e){switch(e.status){case"fulfilled":return e.value;case"rejected":throw e.reason;default:switch("string"==typeof e.status?e.then(S,S):(e.status="pending",e.then(function(t){"pending"===e.status&&(e.status="fulfilled",e.value=t)},function(t){"pending"===e.status&&(e.status="rejected",e.reason=t)})),e.status){case"fulfilled":return e.value;case"rejected":throw e.reason}}throw e}(e),t,o,i,a);throw t=String(e),Error("Objects are not valid as a React child (found: "+("[object Object]"===t?"object with keys {"+Object.keys(e).join(", ")+"}":t)+"). If you meant to render a collection of children, use an array instead.")}return u}function B(e,t,n){if(null==e)return e;var r=[],o=0;return P(e,r,"","",function(e){return t.call(n,e,o++)}),r}function _(e){if(-1===e._status){var t=e._result;(t=t()).then(function(t){0!==e._status&&-1!==e._status||(e._status=1,e._result=t)},function(t){0!==e._status&&-1!==e._status||(e._status=2,e._result=t)}),-1===e._status&&(e._status=0,e._result=t)}if(1===e._status)return e._result.default;throw e._result}var T="function"==typeof reportError?reportError:function(e){if("object"==typeof window&&"function"==typeof window.ErrorEvent){var t=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:"object"==typeof e&&null!==e&&"string"==typeof e.message?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if("object"==typeof process&&"function"==typeof process.emit)return void process.emit("uncaughtException",e);console.error(e)},O={map:B,forEach:function(e,t,n){B(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return B(e,function(){t++}),t},toArray:function(e){return B(e,function(e){return e})||[]},only:function(e){if(!k(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};t.Activity=p,t.Children=O,t.Component=b,t.Fragment=o,t.Profiler=a,t.PureComponent=y,t.StrictMode=i,t.Suspense=u,t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=x,t.__COMPILER_RUNTIME={__proto__:null,c:function(e){return x.H.useMemoCache(e)}},t.cache=function(e){return function(){return e.apply(null,arguments)}},t.cacheSignal=function(){return null},t.cloneElement=function(e,t,n){if(null==e)throw Error("The argument must be a React element, but you passed "+e+".");var r=m({},e.props),o=e.key;if(null!=t)for(i in void 0!==t.key&&(o=""+t.key),t)!E.call(t,i)||"key"===i||"__self"===i||"__source"===i||"ref"===i&&void 0===t.ref||(r[i]=t[i]);var i=arguments.length-2;if(1===i)r.children=n;else if(1<i){for(var a=Array(i),l=0;l<i;l++)a[l]=arguments[l+2];r.children=a}return I(e.type,o,r)},t.createContext=function(e){return(e={$$typeof:s,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null}).Provider=e,e.Consumer={$$typeof:l,_context:e},e},t.createElement=function(e,t,n){var r,o={},i=null;if(null!=t)for(r in void 0!==t.key&&(i=""+t.key),t)E.call(t,r)&&"key"!==r&&"__self"!==r&&"__source"!==r&&(o[r]=t[r]);var a=arguments.length-2;if(1===a)o.children=n;else if(1<a){for(var l=Array(a),s=0;s<a;s++)l[s]=arguments[s+2];o.children=l}if(e&&e.defaultProps)for(r in a=e.defaultProps)void 0===o[r]&&(o[r]=a[r]);return I(e,i,o)},t.createRef=function(){return{current:null}},t.forwardRef=function(e){return{$$typeof:c,render:e}},t.isValidElement=k,t.lazy=function(e){return{$$typeof:f,_payload:{_status:-1,_result:e},_init:_}},t.memo=function(e,t){return{$$typeof:d,type:e,compare:void 0===t?null:t}},t.startTransition=function(e){var t=x.T,n={};x.T=n;try{var r=e(),o=x.S;null!==o&&o(n,r),"object"==typeof r&&null!==r&&"function"==typeof r.then&&r.then(S,T)}catch(e){T(e)}finally{null!==t&&null!==n.types&&(t.types=n.types),x.T=t}},t.unstable_useCacheRefresh=function(){return x.H.useCacheRefresh()},t.use=function(e){return x.H.use(e)},t.useActionState=function(e,t,n){return x.H.useActionState(e,t,n)},t.useCallback=function(e,t){return x.H.useCallback(e,t)},t.useContext=function(e){return x.H.useContext(e)},t.useDebugValue=function(){},t.useDeferredValue=function(e,t){return x.H.useDeferredValue(e,t)},t.useEffect=function(e,t){return x.H.useEffect(e,t)},t.useEffectEvent=function(e){return x.H.useEffectEvent(e)},t.useId=function(){return x.H.useId()},t.useImperativeHandle=function(e,t,n){return x.H.useImperativeHandle(e,t,n)},t.useInsertionEffect=function(e,t){return x.H.useInsertionEffect(e,t)},t.useLayoutEffect=function(e,t){return x.H.useLayoutEffect(e,t)},t.useMemo=function(e,t){return x.H.useMemo(e,t)},t.useOptimistic=function(e,t){return x.H.useOptimistic(e,t)},t.useReducer=function(e,t,n){return x.H.useReducer(e,t,n)},t.useRef=function(e){return x.H.useRef(e)},t.useState=function(e){return x.H.useState(e)},t.useSyncExternalStore=function(e,t,n){return x.H.useSyncExternalStore(e,t,n)},t.useTransition=function(){return x.H.useTransition()},t.version="19.2.7"},405(e,t,n){"use strict";e.exports=n(7866)},9793(e,t,n){"use strict";e.exports=n(8881)},7146(e,t){"use strict";function n(e,t){var n=e.length;e.push(t);e:for(;0<n;){var r=n-1>>>1,o=e[r];if(!(0<i(o,t)))break e;e[r]=t,e[n]=o,n=r}}function r(e){return 0===e.length?null:e[0]}function o(e){if(0===e.length)return null;var t=e[0],n=e.pop();if(n!==t){e[0]=n;e:for(var r=0,o=e.length,a=o>>>1;r<a;){var l=2*(r+1)-1,s=e[l],c=l+1,u=e[c];if(0>i(s,n))c<o&&0>i(u,s)?(e[r]=u,e[c]=n,r=c):(e[r]=s,e[l]=n,r=l);else{if(!(c<o&&0>i(u,n)))break e;e[r]=u,e[c]=n,r=c}}}return t}function i(e,t){var n=e.sortIndex-t.sortIndex;return 0!==n?n:e.id-t.id}if(t.unstable_now=void 0,"object"==typeof performance&&"function"==typeof performance.now){var a=performance;t.unstable_now=function(){return a.now()}}else{var l=Date,s=l.now();t.unstable_now=function(){return l.now()-s}}var c=[],u=[],d=1,f=null,p=3,h=!1,g=!1,m=!1,A=!1,b="function"==typeof setTimeout?setTimeout:null,v="function"==typeof clearTimeout?clearTimeout:null,y="undefined"!=typeof setImmediate?setImmediate:null;function w(e){for(var t=r(u);null!==t;){if(null===t.callback)o(u);else{if(!(t.startTime<=e))break;o(u),t.sortIndex=t.expirationTime,n(c,t)}t=r(u)}}function C(e){if(m=!1,w(e),!g)if(null!==r(c))g=!0,x||(x=!0,S());else{var t=r(u);null!==t&&_(C,t.startTime-e)}}var S,x=!1,E=-1,I=5,k=-1;function R(){return!(!A&&t.unstable_now()-k<I)}function M(){if(A=!1,x){var e=t.unstable_now();k=e;var n=!0;try{e:{g=!1,m&&(m=!1,v(E),E=-1),h=!0;var i=p;try{t:{for(w(e),f=r(c);null!==f&&!(f.expirationTime>e&&R());){var a=f.callback;if("function"==typeof a){f.callback=null,p=f.priorityLevel;var l=a(f.expirationTime<=e);if(e=t.unstable_now(),"function"==typeof l){f.callback=l,w(e),n=!0;break t}f===r(c)&&o(c),w(e)}else o(c);f=r(c)}if(null!==f)n=!0;else{var s=r(u);null!==s&&_(C,s.startTime-e),n=!1}}break e}finally{f=null,p=i,h=!1}n=void 0}}finally{n?S():x=!1}}}if("function"==typeof y)S=function(){y(M)};else if("undefined"!=typeof MessageChannel){var P=new MessageChannel,B=P.port2;P.port1.onmessage=M,S=function(){B.postMessage(null)}}else S=function(){b(M,0)};function _(e,n){E=b(function(){e(t.unstable_now())},n)}t.unstable_IdlePriority=5,t.unstable_ImmediatePriority=1,t.unstable_LowPriority=4,t.unstable_NormalPriority=3,t.unstable_Profiling=null,t.unstable_UserBlockingPriority=2,t.unstable_cancelCallback=function(e){e.callback=null},t.unstable_forceFrameRate=function(e){0>e||125<e?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):I=0<e?Math.floor(1e3/e):5},t.unstable_getCurrentPriorityLevel=function(){return p},t.unstable_next=function(e){switch(p){case 1:case 2:case 3:var t=3;break;default:t=p}var n=p;p=t;try{return e()}finally{p=n}},t.unstable_requestPaint=function(){A=!0},t.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var n=p;p=e;try{return t()}finally{p=n}},t.unstable_scheduleCallback=function(e,o,i){var a=t.unstable_now();switch(i="object"==typeof i&&null!==i&&"number"==typeof(i=i.delay)&&0<i?a+i:a,e){case 1:var l=-1;break;case 2:l=250;break;case 5:l=1073741823;break;case 4:l=1e4;break;default:l=5e3}return e={id:d++,callback:o,priorityLevel:e,startTime:i,expirationTime:l=i+l,sortIndex:-1},i>a?(e.sortIndex=i,n(u,e),null===r(c)&&e===r(u)&&(m?(v(E),E=-1):m=!0,_(C,i-a))):(e.sortIndex=l,n(c,e),g||h||(g=!0,x||(x=!0,S()))),e},t.unstable_shouldYield=R,t.unstable_wrapCallback=function(e){var t=p;return function(){var n=p;p=t;try{return e.apply(this,arguments)}finally{p=n}}}},3480(e,t,n){"use strict";e.exports=n(7146)},4972(e,t,n){var r=n(2738),o=Object.prototype.hasOwnProperty,i="undefined"!=typeof Map;function a(){this._array=[],this._set=i?new Map:Object.create(null)}a.fromArray=function(e,t){for(var n=new a,r=0,o=e.length;r<o;r++)n.add(e[r],t);return n},a.prototype.size=function(){return i?this._set.size:Object.getOwnPropertyNames(this._set).length},a.prototype.add=function(e,t){var n=i?e:r.toSetString(e),a=i?this.has(e):o.call(this._set,n),l=this._array.length;a&&!t||this._array.push(e),a||(i?this._set.set(e,l):this._set[n]=l)},a.prototype.has=function(e){if(i)return this._set.has(e);var t=r.toSetString(e);return o.call(this._set,t)},a.prototype.indexOf=function(e){if(i){var t=this._set.get(e);if(t>=0)return t}else{var n=r.toSetString(e);if(o.call(this._set,n))return this._set[n]}throw new Error('"'+e+'" is not in the set.')},a.prototype.at=function(e){if(e>=0&&e<this._array.length)return this._array[e];throw new Error("No element indexed by "+e)},a.prototype.toArray=function(){return this._array.slice()},t.C=a},5781(e,t,n){var r=n(1549);t.encode=function(e){var t,n="",o=function(e){return e<0?1+(-e<<1):0+(e<<1)}(e);do{t=31&o,(o>>>=5)>0&&(t|=32),n+=r.encode(t)}while(o>0);return n},t.decode=function(e,t,n){var o,i,a,l,s=e.length,c=0,u=0;do{if(t>=s)throw new Error("Expected more digits in base 64 VLQ value.");if(-1===(i=r.decode(e.charCodeAt(t++))))throw new Error("Invalid base64 digit: "+e.charAt(t-1));o=!!(32&i),c+=(i&=31)<<u,u+=5}while(o);n.value=(l=(a=c)>>1,1&~a?l:-l),n.rest=t}},1549(e,t){var n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split("");t.encode=function(e){if(0<=e&&e<n.length)return n[e];throw new TypeError("Must be between 0 and 63: "+e)},t.decode=function(e){return 65<=e&&e<=90?e-65:97<=e&&e<=122?e-97+26:48<=e&&e<=57?e-48+52:43==e?62:47==e?63:-1}},3016(e,t){function n(e,r,o,i,a,l){var s=Math.floor((r-e)/2)+e,c=a(o,i[s],!0);return 0===c?s:c>0?r-s>1?n(s,r,o,i,a,l):l==t.LEAST_UPPER_BOUND?r<i.length?r:-1:s:s-e>1?n(e,s,o,i,a,l):l==t.LEAST_UPPER_BOUND?s:e<0?-1:e}t.GREATEST_LOWER_BOUND=1,t.LEAST_UPPER_BOUND=2,t.search=function(e,r,o,i){if(0===r.length)return-1;var a=n(-1,r.length,e,r,o,i||t.GREATEST_LOWER_BOUND);if(a<0)return-1;for(;a-1>=0&&0===o(r[a],r[a-1],!0);)--a;return a}},3383(e,t,n){var r=n(2738);function o(){this._array=[],this._sorted=!0,this._last={generatedLine:-1,generatedColumn:0}}o.prototype.unsortedForEach=function(e,t){this._array.forEach(e,t)},o.prototype.add=function(e){var t,n,o,i,a,l;n=e,o=(t=this._last).generatedLine,i=n.generatedLine,a=t.generatedColumn,l=n.generatedColumn,i>o||i==o&&l>=a||r.compareByGeneratedPositionsInflated(t,n)<=0?(this._last=e,this._array.push(e)):(this._sorted=!1,this._array.push(e))},o.prototype.toArray=function(){return this._sorted||(this._array.sort(r.compareByGeneratedPositionsInflated),this._sorted=!0),this._array},t.P=o},6360(e,t){function n(e){function t(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}return function e(n,r,o,i){if(o<i){var a=o-1;t(n,(u=o,d=i,Math.round(u+Math.random()*(d-u))),i);for(var l=n[i],s=o;s<i;s++)r(n[s],l,!1)<=0&&t(n,a+=1,s);t(n,a+1,s);var c=a+1;e(n,r,o,c-1),e(n,r,c+1,i)}var u,d}}let r=new WeakMap;t.g=function(e,t,o=0){let i=r.get(t);void 0===i&&(i=function(e){let t=n.toString();return new Function(`return ${t}`)()(e)}(t),r.set(t,i)),i(e,t,o,e.length-1)}},7881(e,t,n){var r=n(2738),o=n(3016),i=n(4972).C,a=n(5781),l=n(6360).g;function s(e,t){var n=e;return"string"==typeof e&&(n=r.parseSourceMapInput(e)),null!=n.sections?new p(n,t):new c(n,t)}function c(e,t){var n=e;"string"==typeof e&&(n=r.parseSourceMapInput(e));var o=r.getArg(n,"version"),a=r.getArg(n,"sources"),l=r.getArg(n,"names",[]),s=r.getArg(n,"sourceRoot",null),c=r.getArg(n,"sourcesContent",null),u=r.getArg(n,"mappings"),d=r.getArg(n,"file",null);if(o!=this._version)throw new Error("Unsupported version: "+o);s&&(s=r.normalize(s)),a=a.map(String).map(r.normalize).map(function(e){return s&&r.isAbsolute(s)&&r.isAbsolute(e)?r.relative(s,e):e}),this._names=i.fromArray(l.map(String),!0),this._sources=i.fromArray(a,!0),this._absoluteSources=this._sources.toArray().map(function(e){return r.computeSourceURL(s,e,t)}),this.sourceRoot=s,this.sourcesContent=c,this._mappings=u,this._sourceMapURL=t,this.file=d}function u(){this.generatedLine=0,this.generatedColumn=0,this.source=null,this.originalLine=null,this.originalColumn=null,this.name=null}s.fromSourceMap=function(e,t){return c.fromSourceMap(e,t)},s.prototype._version=3,s.prototype.__generatedMappings=null,Object.defineProperty(s.prototype,"_generatedMappings",{configurable:!0,enumerable:!0,get:function(){return this.__generatedMappings||this._parseMappings(this._mappings,this.sourceRoot),this.__generatedMappings}}),s.prototype.__originalMappings=null,Object.defineProperty(s.prototype,"_originalMappings",{configurable:!0,enumerable:!0,get:function(){return this.__originalMappings||this._parseMappings(this._mappings,this.sourceRoot),this.__originalMappings}}),s.prototype._charIsMappingSeparator=function(e,t){var n=e.charAt(t);return";"===n||","===n},s.prototype._parseMappings=function(e,t){throw new Error("Subclasses must implement _parseMappings")},s.GENERATED_ORDER=1,s.ORIGINAL_ORDER=2,s.GREATEST_LOWER_BOUND=1,s.LEAST_UPPER_BOUND=2,s.prototype.eachMapping=function(e,t,n){var o,i=t||null;switch(n||s.GENERATED_ORDER){case s.GENERATED_ORDER:o=this._generatedMappings;break;case s.ORIGINAL_ORDER:o=this._originalMappings;break;default:throw new Error("Unknown order of iteration.")}for(var a=this.sourceRoot,l=e.bind(i),c=this._names,u=this._sources,d=this._sourceMapURL,f=0,p=o.length;f<p;f++){var h=o[f],g=null===h.source?null:u.at(h.source);null!==g&&(g=r.computeSourceURL(a,g,d)),l({source:g,generatedLine:h.generatedLine,generatedColumn:h.generatedColumn,originalLine:h.originalLine,originalColumn:h.originalColumn,name:null===h.name?null:c.at(h.name)})}},s.prototype.allGeneratedPositionsFor=function(e){var t=r.getArg(e,"line"),n={source:r.getArg(e,"source"),originalLine:t,originalColumn:r.getArg(e,"column",0)};if(n.source=this._findSourceIndex(n.source),n.source<0)return[];var i=[],a=this._findMapping(n,this._originalMappings,"originalLine","originalColumn",r.compareByOriginalPositions,o.LEAST_UPPER_BOUND);if(a>=0){var l=this._originalMappings[a];if(void 0===e.column)for(var s=l.originalLine;l&&l.originalLine===s;)i.push({line:r.getArg(l,"generatedLine",null),column:r.getArg(l,"generatedColumn",null),lastColumn:r.getArg(l,"lastGeneratedColumn",null)}),l=this._originalMappings[++a];else for(var c=l.originalColumn;l&&l.originalLine===t&&l.originalColumn==c;)i.push({line:r.getArg(l,"generatedLine",null),column:r.getArg(l,"generatedColumn",null),lastColumn:r.getArg(l,"lastGeneratedColumn",null)}),l=this._originalMappings[++a]}return i},t.SourceMapConsumer=s,c.prototype=Object.create(s.prototype),c.prototype.consumer=s,c.prototype._findSourceIndex=function(e){var t,n=e;if(null!=this.sourceRoot&&(n=r.relative(this.sourceRoot,n)),this._sources.has(n))return this._sources.indexOf(n);for(t=0;t<this._absoluteSources.length;++t)if(this._absoluteSources[t]==e)return t;return-1},c.fromSourceMap=function(e,t){var n=Object.create(c.prototype),o=n._names=i.fromArray(e._names.toArray(),!0),a=n._sources=i.fromArray(e._sources.toArray(),!0);n.sourceRoot=e._sourceRoot,n.sourcesContent=e._generateSourcesContent(n._sources.toArray(),n.sourceRoot),n.file=e._file,n._sourceMapURL=t,n._absoluteSources=n._sources.toArray().map(function(e){return r.computeSourceURL(n.sourceRoot,e,t)});for(var s=e._mappings.toArray().slice(),d=n.__generatedMappings=[],f=n.__originalMappings=[],p=0,h=s.length;p<h;p++){var g=s[p],m=new u;m.generatedLine=g.generatedLine,m.generatedColumn=g.generatedColumn,g.source&&(m.source=a.indexOf(g.source),m.originalLine=g.originalLine,m.originalColumn=g.originalColumn,g.name&&(m.name=o.indexOf(g.name)),f.push(m)),d.push(m)}return l(n.__originalMappings,r.compareByOriginalPositions),n},c.prototype._version=3,Object.defineProperty(c.prototype,"sources",{get:function(){return this._absoluteSources.slice()}});const d=r.compareByGeneratedPositionsDeflatedNoLine;function f(e,t){let n=e.length,r=e.length-t;if(!(r<=1))if(2==r){let n=e[t],r=e[t+1];d(n,r)>0&&(e[t]=r,e[t+1]=n)}else if(r<20)for(let r=t;r<n;r++)for(let n=r;n>t;n--){let t=e[n-1],r=e[n];if(d(t,r)<=0)break;e[n-1]=r,e[n]=t}else l(e,d,t)}function p(e,t){var n=e;"string"==typeof e&&(n=r.parseSourceMapInput(e));var o=r.getArg(n,"version"),a=r.getArg(n,"sections");if(o!=this._version)throw new Error("Unsupported version: "+o);this._sources=new i,this._names=new i;var l={line:-1,column:0};this._sections=a.map(function(e){if(e.url)throw new Error("Support for url field in sections not implemented.");var n=r.getArg(e,"offset"),o=r.getArg(n,"line"),i=r.getArg(n,"column");if(o<l.line||o===l.line&&i<l.column)throw new Error("Section offsets must be ordered and non-overlapping.");return l=n,{generatedOffset:{generatedLine:o+1,generatedColumn:i+1},consumer:new s(r.getArg(e,"map"),t)}})}c.prototype._parseMappings=function(e,t){var n,o,i,s,c=1,d=0,p=0,h=0,g=0,m=0,A=e.length,b=0,v={},y=[],w=[];let C=0;for(;b<A;)if(";"===e.charAt(b))c++,b++,d=0,f(w,C),C=w.length;else if(","===e.charAt(b))b++;else{for((n=new u).generatedLine=c,i=b;i<A&&!this._charIsMappingSeparator(e,i);i++);for(e.slice(b,i),o=[];b<i;)a.decode(e,b,v),s=v.value,b=v.rest,o.push(s);if(2===o.length)throw new Error("Found a source, but no line and column");if(3===o.length)throw new Error("Found a source and line, but no column");if(n.generatedColumn=d+o[0],d=n.generatedColumn,o.length>1&&(n.source=g+o[1],g+=o[1],n.originalLine=p+o[2],p=n.originalLine,n.originalLine+=1,n.originalColumn=h+o[3],h=n.originalColumn,o.length>4&&(n.name=m+o[4],m+=o[4])),w.push(n),"number"==typeof n.originalLine){let e=n.source;for(;y.length<=e;)y.push(null);null===y[e]&&(y[e]=[]),y[e].push(n)}}f(w,C),this.__generatedMappings=w;for(var S=0;S<y.length;S++)null!=y[S]&&l(y[S],r.compareByOriginalPositionsNoSource);this.__originalMappings=[].concat(...y)},c.prototype._findMapping=function(e,t,n,r,i,a){if(e[n]<=0)throw new TypeError("Line must be greater than or equal to 1, got "+e[n]);if(e[r]<0)throw new TypeError("Column must be greater than or equal to 0, got "+e[r]);return o.search(e,t,i,a)},c.prototype.computeColumnSpans=function(){for(var e=0;e<this._generatedMappings.length;++e){var t=this._generatedMappings[e];if(e+1<this._generatedMappings.length){var n=this._generatedMappings[e+1];if(t.generatedLine===n.generatedLine){t.lastGeneratedColumn=n.generatedColumn-1;continue}}t.lastGeneratedColumn=1/0}},c.prototype.originalPositionFor=function(e){var t={generatedLine:r.getArg(e,"line"),generatedColumn:r.getArg(e,"column")},n=this._findMapping(t,this._generatedMappings,"generatedLine","generatedColumn",r.compareByGeneratedPositionsDeflated,r.getArg(e,"bias",s.GREATEST_LOWER_BOUND));if(n>=0){var o=this._generatedMappings[n];if(o.generatedLine===t.generatedLine){var i=r.getArg(o,"source",null);null!==i&&(i=this._sources.at(i),i=r.computeSourceURL(this.sourceRoot,i,this._sourceMapURL));var a=r.getArg(o,"name",null);return null!==a&&(a=this._names.at(a)),{source:i,line:r.getArg(o,"originalLine",null),column:r.getArg(o,"originalColumn",null),name:a}}}return{source:null,line:null,column:null,name:null}},c.prototype.hasContentsOfAllSources=function(){return!!this.sourcesContent&&this.sourcesContent.length>=this._sources.size()&&!this.sourcesContent.some(function(e){return null==e})},c.prototype.sourceContentFor=function(e,t){if(!this.sourcesContent)return null;var n=this._findSourceIndex(e);if(n>=0)return this.sourcesContent[n];var o,i=e;if(null!=this.sourceRoot&&(i=r.relative(this.sourceRoot,i)),null!=this.sourceRoot&&(o=r.urlParse(this.sourceRoot))){var a=i.replace(/^file:\/\//,"");if("file"==o.scheme&&this._sources.has(a))return this.sourcesContent[this._sources.indexOf(a)];if((!o.path||"/"==o.path)&&this._sources.has("/"+i))return this.sourcesContent[this._sources.indexOf("/"+i)]}if(t)return null;throw new Error('"'+i+'" is not in the SourceMap.')},c.prototype.generatedPositionFor=function(e){var t=r.getArg(e,"source");if((t=this._findSourceIndex(t))<0)return{line:null,column:null,lastColumn:null};var n={source:t,originalLine:r.getArg(e,"line"),originalColumn:r.getArg(e,"column")},o=this._findMapping(n,this._originalMappings,"originalLine","originalColumn",r.compareByOriginalPositions,r.getArg(e,"bias",s.GREATEST_LOWER_BOUND));if(o>=0){var i=this._originalMappings[o];if(i.source===n.source)return{line:r.getArg(i,"generatedLine",null),column:r.getArg(i,"generatedColumn",null),lastColumn:r.getArg(i,"lastGeneratedColumn",null)}}return{line:null,column:null,lastColumn:null}},p.prototype=Object.create(s.prototype),p.prototype.constructor=s,p.prototype._version=3,Object.defineProperty(p.prototype,"sources",{get:function(){for(var e=[],t=0;t<this._sections.length;t++)for(var n=0;n<this._sections[t].consumer.sources.length;n++)e.push(this._sections[t].consumer.sources[n]);return e}}),p.prototype.originalPositionFor=function(e){var t={generatedLine:r.getArg(e,"line"),generatedColumn:r.getArg(e,"column")},n=o.search(t,this._sections,function(e,t){return e.generatedLine-t.generatedOffset.generatedLine||e.generatedColumn-t.generatedOffset.generatedColumn}),i=this._sections[n];return i?i.consumer.originalPositionFor({line:t.generatedLine-(i.generatedOffset.generatedLine-1),column:t.generatedColumn-(i.generatedOffset.generatedLine===t.generatedLine?i.generatedOffset.generatedColumn-1:0),bias:e.bias}):{source:null,line:null,column:null,name:null}},p.prototype.hasContentsOfAllSources=function(){return this._sections.every(function(e){return e.consumer.hasContentsOfAllSources()})},p.prototype.sourceContentFor=function(e,t){for(var n=0;n<this._sections.length;n++){var r=this._sections[n].consumer.sourceContentFor(e,!0);if(r||""===r)return r}if(t)return null;throw new Error('"'+e+'" is not in the SourceMap.')},p.prototype.generatedPositionFor=function(e){for(var t=0;t<this._sections.length;t++){var n=this._sections[t];if(-1!==n.consumer._findSourceIndex(r.getArg(e,"source"))){var o=n.consumer.generatedPositionFor(e);if(o)return{line:o.line+(n.generatedOffset.generatedLine-1),column:o.column+(n.generatedOffset.generatedLine===o.line?n.generatedOffset.generatedColumn-1:0)}}}return{line:null,column:null}},p.prototype._parseMappings=function(e,t){this.__generatedMappings=[],this.__originalMappings=[];for(var n=0;n<this._sections.length;n++)for(var o=this._sections[n],i=o.consumer._generatedMappings,a=0;a<i.length;a++){var s=i[a],c=o.consumer._sources.at(s.source);null!==c&&(c=r.computeSourceURL(o.consumer.sourceRoot,c,this._sourceMapURL)),this._sources.add(c),c=this._sources.indexOf(c);var u=null;s.name&&(u=o.consumer._names.at(s.name),this._names.add(u),u=this._names.indexOf(u));var d={source:c,generatedLine:s.generatedLine+(o.generatedOffset.generatedLine-1),generatedColumn:s.generatedColumn+(o.generatedOffset.generatedLine===s.generatedLine?o.generatedOffset.generatedColumn-1:0),originalLine:s.originalLine,originalColumn:s.originalColumn,name:u};this.__generatedMappings.push(d),"number"==typeof d.originalLine&&this.__originalMappings.push(d)}l(this.__generatedMappings,r.compareByGeneratedPositionsDeflated),l(this.__originalMappings,r.compareByOriginalPositions)}},9592(e,t,n){var r=n(5781),o=n(2738),i=n(4972).C,a=n(3383).P;function l(e){e||(e={}),this._file=o.getArg(e,"file",null),this._sourceRoot=o.getArg(e,"sourceRoot",null),this._skipValidation=o.getArg(e,"skipValidation",!1),this._ignoreInvalidMapping=o.getArg(e,"ignoreInvalidMapping",!1),this._sources=new i,this._names=new i,this._mappings=new a,this._sourcesContents=null}l.prototype._version=3,l.fromSourceMap=function(e,t){var n=e.sourceRoot,r=new l(Object.assign(t||{},{file:e.file,sourceRoot:n}));return e.eachMapping(function(e){var t={generated:{line:e.generatedLine,column:e.generatedColumn}};null!=e.source&&(t.source=e.source,null!=n&&(t.source=o.relative(n,t.source)),t.original={line:e.originalLine,column:e.originalColumn},null!=e.name&&(t.name=e.name)),r.addMapping(t)}),e.sources.forEach(function(t){var i=t;null!==n&&(i=o.relative(n,t)),r._sources.has(i)||r._sources.add(i);var a=e.sourceContentFor(t);null!=a&&r.setSourceContent(t,a)}),r},l.prototype.addMapping=function(e){var t=o.getArg(e,"generated"),n=o.getArg(e,"original",null),r=o.getArg(e,"source",null),i=o.getArg(e,"name",null);(this._skipValidation||!1!==this._validateMapping(t,n,r,i))&&(null!=r&&(r=String(r),this._sources.has(r)||this._sources.add(r)),null!=i&&(i=String(i),this._names.has(i)||this._names.add(i)),this._mappings.add({generatedLine:t.line,generatedColumn:t.column,originalLine:null!=n&&n.line,originalColumn:null!=n&&n.column,source:r,name:i}))},l.prototype.setSourceContent=function(e,t){var n=e;null!=this._sourceRoot&&(n=o.relative(this._sourceRoot,n)),null!=t?(this._sourcesContents||(this._sourcesContents=Object.create(null)),this._sourcesContents[o.toSetString(n)]=t):this._sourcesContents&&(delete this._sourcesContents[o.toSetString(n)],0===Object.keys(this._sourcesContents).length&&(this._sourcesContents=null))},l.prototype.applySourceMap=function(e,t,n){var r=t;if(null==t){if(null==e.file)throw new Error('SourceMapGenerator.prototype.applySourceMap requires either an explicit source file, or the source map\'s "file" property. Both were omitted.');r=e.file}var a=this._sourceRoot;null!=a&&(r=o.relative(a,r));var l=new i,s=new i;this._mappings.unsortedForEach(function(t){if(t.source===r&&null!=t.originalLine){var i=e.originalPositionFor({line:t.originalLine,column:t.originalColumn});null!=i.source&&(t.source=i.source,null!=n&&(t.source=o.join(n,t.source)),null!=a&&(t.source=o.relative(a,t.source)),t.originalLine=i.line,t.originalColumn=i.column,null!=i.name&&(t.name=i.name))}var c=t.source;null==c||l.has(c)||l.add(c);var u=t.name;null==u||s.has(u)||s.add(u)},this),this._sources=l,this._names=s,e.sources.forEach(function(t){var r=e.sourceContentFor(t);null!=r&&(null!=n&&(t=o.join(n,t)),null!=a&&(t=o.relative(a,t)),this.setSourceContent(t,r))},this)},l.prototype._validateMapping=function(e,t,n,r){if(t&&"number"!=typeof t.line&&"number"!=typeof t.column){var o="original.line and original.column are not numbers -- you probably meant to omit the original mapping entirely and only map the generated position. If so, pass null for the original mapping instead of an object with empty or null values.";if(this._ignoreInvalidMapping)return"undefined"!=typeof console&&console.warn&&console.warn(o),!1;throw new Error(o)}if((!(e&&"line"in e&&"column"in e&&e.line>0&&e.column>=0)||t||n||r)&&!(e&&"line"in e&&"column"in e&&t&&"line"in t&&"column"in t&&e.line>0&&e.column>=0&&t.line>0&&t.column>=0&&n)){if(o="Invalid mapping: "+JSON.stringify({generated:e,source:n,original:t,name:r}),this._ignoreInvalidMapping)return"undefined"!=typeof console&&console.warn&&console.warn(o),!1;throw new Error(o)}},l.prototype._serializeMappings=function(){for(var e,t,n,i,a=0,l=1,s=0,c=0,u=0,d=0,f="",p=this._mappings.toArray(),h=0,g=p.length;h<g;h++){if(e="",(t=p[h]).generatedLine!==l)for(a=0;t.generatedLine!==l;)e+=";",l++;else if(h>0){if(!o.compareByGeneratedPositionsInflated(t,p[h-1]))continue;e+=","}e+=r.encode(t.generatedColumn-a),a=t.generatedColumn,null!=t.source&&(i=this._sources.indexOf(t.source),e+=r.encode(i-d),d=i,e+=r.encode(t.originalLine-1-c),c=t.originalLine-1,e+=r.encode(t.originalColumn-s),s=t.originalColumn,null!=t.name&&(n=this._names.indexOf(t.name),e+=r.encode(n-u),u=n)),f+=e}return f},l.prototype._generateSourcesContent=function(e,t){return e.map(function(e){if(!this._sourcesContents)return null;null!=t&&(e=o.relative(t,e));var n=o.toSetString(e);return Object.prototype.hasOwnProperty.call(this._sourcesContents,n)?this._sourcesContents[n]:null},this)},l.prototype.toJSON=function(){var e={version:this._version,sources:this._sources.toArray(),names:this._names.toArray(),mappings:this._serializeMappings()};return null!=this._file&&(e.file=this._file),null!=this._sourceRoot&&(e.sourceRoot=this._sourceRoot),this._sourcesContents&&(e.sourcesContent=this._generateSourcesContent(e.sources,e.sourceRoot)),e},l.prototype.toString=function(){return JSON.stringify(this.toJSON())},t.x=l},3548(e,t,n){var r=n(9592).x,o=n(2738),i=/(\r?\n)/,a="$$$isSourceNode$$$";function l(e,t,n,r,o){this.children=[],this.sourceContents={},this.line=e??null,this.column=t??null,this.source=n??null,this.name=o??null,this[a]=!0,null!=r&&this.add(r)}l.fromStringWithSourceMap=function(e,t,n){var r=new l,a=e.split(i),s=0,c=function(){return e()+(e()||"");function e(){return s<a.length?a[s++]:void 0}},u=1,d=0,f=null;return t.eachMapping(function(e){if(null!==f){if(!(u<e.generatedLine)){var t=(n=a[s]||"").substr(0,e.generatedColumn-d);return a[s]=n.substr(e.generatedColumn-d),d=e.generatedColumn,p(f,t),void(f=e)}p(f,c()),u++,d=0}for(;u<e.generatedLine;)r.add(c()),u++;if(d<e.generatedColumn){var n=a[s]||"";r.add(n.substr(0,e.generatedColumn)),a[s]=n.substr(e.generatedColumn),d=e.generatedColumn}f=e},this),s<a.length&&(f&&p(f,c()),r.add(a.splice(s).join(""))),t.sources.forEach(function(e){var i=t.sourceContentFor(e);null!=i&&(null!=n&&(e=o.join(n,e)),r.setSourceContent(e,i))}),r;function p(e,t){if(null===e||void 0===e.source)r.add(t);else{var i=n?o.join(n,e.source):e.source;r.add(new l(e.originalLine,e.originalColumn,i,t,e.name))}}},l.prototype.add=function(e){if(Array.isArray(e))e.forEach(function(e){this.add(e)},this);else{if(!e[a]&&"string"!=typeof e)throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+e);e&&this.children.push(e)}return this},l.prototype.prepend=function(e){if(Array.isArray(e))for(var t=e.length-1;t>=0;t--)this.prepend(e[t]);else{if(!e[a]&&"string"!=typeof e)throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+e);this.children.unshift(e)}return this},l.prototype.walk=function(e){for(var t,n=0,r=this.children.length;n<r;n++)(t=this.children[n])[a]?t.walk(e):""!==t&&e(t,{source:this.source,line:this.line,column:this.column,name:this.name})},l.prototype.join=function(e){var t,n,r=this.children.length;if(r>0){for(t=[],n=0;n<r-1;n++)t.push(this.children[n]),t.push(e);t.push(this.children[n]),this.children=t}return this},l.prototype.replaceRight=function(e,t){var n=this.children[this.children.length-1];return n[a]?n.replaceRight(e,t):"string"==typeof n?this.children[this.children.length-1]=n.replace(e,t):this.children.push("".replace(e,t)),this},l.prototype.setSourceContent=function(e,t){this.sourceContents[o.toSetString(e)]=t},l.prototype.walkSourceContents=function(e){for(var t=0,n=this.children.length;t<n;t++)this.children[t][a]&&this.children[t].walkSourceContents(e);var r=Object.keys(this.sourceContents);for(t=0,n=r.length;t<n;t++)e(o.fromSetString(r[t]),this.sourceContents[r[t]])},l.prototype.toString=function(){var e="";return this.walk(function(t){e+=t}),e},l.prototype.toStringWithSourceMap=function(e){var t={code:"",line:1,column:0},n=new r(e),o=!1,i=null,a=null,l=null,s=null;return this.walk(function(e,r){t.code+=e,null!==r.source&&null!==r.line&&null!==r.column?(i===r.source&&a===r.line&&l===r.column&&s===r.name||n.addMapping({source:r.source,original:{line:r.line,column:r.column},generated:{line:t.line,column:t.column},name:r.name}),i=r.source,a=r.line,l=r.column,s=r.name,o=!0):o&&(n.addMapping({generated:{line:t.line,column:t.column}}),i=null,o=!1);for(var c=0,u=e.length;c<u;c++)10===e.charCodeAt(c)?(t.line++,t.column=0,c+1===u?(i=null,o=!1):o&&n.addMapping({source:r.source,original:{line:r.line,column:r.column},generated:{line:t.line,column:t.column},name:r.name})):t.column++}),this.walkSourceContents(function(e,t){n.setSourceContent(e,t)}),{code:t.code,map:n}}},2738(e,t){t.getArg=function(e,t,n){if(t in e)return e[t];if(3===arguments.length)return n;throw new Error('"'+t+'" is a required argument.')};var n=/^(?:([\w+\-.]+):)?\/\/(?:(\w+:\w+)@)?([\w.-]*)(?::(\d+))?(.*)$/,r=/^data:.+\,.+$/;function o(e){var t=e.match(n);return t?{scheme:t[1],auth:t[2],host:t[3],port:t[4],path:t[5]}:null}function i(e){var t="";return e.scheme&&(t+=e.scheme+":"),t+="//",e.auth&&(t+=e.auth+"@"),e.host&&(t+=e.host),e.port&&(t+=":"+e.port),e.path&&(t+=e.path),t}t.urlParse=o,t.urlGenerate=i;var a,l,s=(a=function(e){var n=e,r=o(e);if(r){if(!r.path)return e;n=r.path}for(var a=t.isAbsolute(n),l=[],s=0,c=0;;){if(s=c,-1===(c=n.indexOf("/",s))){l.push(n.slice(s));break}for(l.push(n.slice(s,c));c<n.length&&"/"===n[c];)c++}var u,d=0;for(c=l.length-1;c>=0;c--)"."===(u=l[c])?l.splice(c,1):".."===u?d++:d>0&&(""===u?(l.splice(c+1,d),d=0):(l.splice(c,2),d--));return""===(n=l.join("/"))&&(n=a?"/":"."),r?(r.path=n,i(r)):n},l=[],function(e){for(var t=0;t<l.length;t++)if(l[t].input===e){var n=l[0];return l[0]=l[t],l[t]=n,l[0].result}var r=a(e);return l.unshift({input:e,result:r}),l.length>32&&l.pop(),r});function c(e,t){""===e&&(e="."),""===t&&(t=".");var n=o(t),a=o(e);if(a&&(e=a.path||"/"),n&&!n.scheme)return a&&(n.scheme=a.scheme),i(n);if(n||t.match(r))return t;if(a&&!a.host&&!a.path)return a.host=t,i(a);var l="/"===t.charAt(0)?t:s(e.replace(/\/+$/,"")+"/"+t);return a?(a.path=l,i(a)):l}t.normalize=s,t.join=c,t.isAbsolute=function(e){return"/"===e.charAt(0)||n.test(e)},t.relative=function(e,t){""===e&&(e="."),e=e.replace(/\/$/,"");for(var n=0;0!==t.indexOf(e+"/");){var r=e.lastIndexOf("/");if(r<0)return t;if((e=e.slice(0,r)).match(/^([^\/]+:\/)?\/*$/))return t;++n}return Array(n+1).join("../")+t.substr(e.length+1)};var u=!("__proto__"in Object.create(null));function d(e){return e}function f(e){if(!e)return!1;var t=e.length;if(t<9)return!1;if(95!==e.charCodeAt(t-1)||95!==e.charCodeAt(t-2)||111!==e.charCodeAt(t-3)||116!==e.charCodeAt(t-4)||111!==e.charCodeAt(t-5)||114!==e.charCodeAt(t-6)||112!==e.charCodeAt(t-7)||95!==e.charCodeAt(t-8)||95!==e.charCodeAt(t-9))return!1;for(var n=t-10;n>=0;n--)if(36!==e.charCodeAt(n))return!1;return!0}function p(e,t){return e===t?0:null===e?1:null===t?-1:e>t?1:-1}t.toSetString=u?d:function(e){return f(e)?"$"+e:e},t.fromSetString=u?d:function(e){return f(e)?e.slice(1):e},t.compareByOriginalPositions=function(e,t,n){var r=p(e.source,t.source);return 0!==r||0!==(r=e.originalLine-t.originalLine)||0!==(r=e.originalColumn-t.originalColumn)||n||0!==(r=e.generatedColumn-t.generatedColumn)||0!==(r=e.generatedLine-t.generatedLine)?r:p(e.name,t.name)},t.compareByOriginalPositionsNoSource=function(e,t,n){var r;return 0!==(r=e.originalLine-t.originalLine)||0!==(r=e.originalColumn-t.originalColumn)||n||0!==(r=e.generatedColumn-t.generatedColumn)||0!==(r=e.generatedLine-t.generatedLine)?r:p(e.name,t.name)},t.compareByGeneratedPositionsDeflated=function(e,t,n){var r=e.generatedLine-t.generatedLine;return 0!==r||0!==(r=e.generatedColumn-t.generatedColumn)||n||0!==(r=p(e.source,t.source))||0!==(r=e.originalLine-t.originalLine)||0!==(r=e.originalColumn-t.originalColumn)?r:p(e.name,t.name)},t.compareByGeneratedPositionsDeflatedNoLine=function(e,t,n){var r=e.generatedColumn-t.generatedColumn;return 0!==r||n||0!==(r=p(e.source,t.source))||0!==(r=e.originalLine-t.originalLine)||0!==(r=e.originalColumn-t.originalColumn)?r:p(e.name,t.name)},t.compareByGeneratedPositionsInflated=function(e,t){var n=e.generatedLine-t.generatedLine;return 0!==n||0!==(n=e.generatedColumn-t.generatedColumn)||0!==(n=p(e.source,t.source))||0!==(n=e.originalLine-t.originalLine)||0!==(n=e.originalColumn-t.originalColumn)?n:p(e.name,t.name)},t.parseSourceMapInput=function(e){return JSON.parse(e.replace(/^\)]}'[^\n]*\n/,""))},t.computeSourceURL=function(e,t,n){if(t=t||"",e&&("/"!==e[e.length-1]&&"/"!==t[0]&&(e+="/"),t=e+t),n){var r=o(n);if(!r)throw new Error("sourceMapURL could not be parsed");if(r.path){var a=r.path.lastIndexOf("/");a>=0&&(r.path=r.path.substring(0,a+1))}t=c(i(r),t)}return s(t)}},9736(e,t,n){n(9592).x,t.SourceMapConsumer=n(7881).SourceMapConsumer,n(3548)},9687(e){e.exports=function(){var e=document.getSelection();if(!e.rangeCount)return function(){};for(var t=document.activeElement,n=[],r=0;r<e.rangeCount;r++)n.push(e.getRangeAt(r));switch(t.tagName.toUpperCase()){case"INPUT":case"TEXTAREA":t.blur();break;default:t=null}return e.removeAllRanges(),function(){"Caret"===e.type&&e.removeAllRanges(),e.rangeCount||n.forEach(function(t){e.addRange(t)}),t&&t.focus()}}},8998(e,t,n){"use strict";n.d(t,{n9:()=>D});var r=n(5835),o=n(405);const i=Object.fromEntries?Object.fromEntries:e=>{if(!e||!e[Symbol.iterator])throw new Error("Object.fromEntries() requires a single iterable argument");const t={};return Object.keys(e).forEach(n=>{const[r,o]=e[n];t[r]=o}),t};function a(e){return Object.keys(e)}function l(e,t){if(!e)throw new Error(t)}function s(e,t){return t}const c=e=>{const t=e.length;let n=0,r="";for(;n<t;n++){const t=e[n];if(null==t)continue;let o;switch(typeof t){case"boolean":break;case"object":if(Array.isArray(t))o=c(t);else{l(!s(0,!1)),o="";for(const e in t)t[e]&&e&&(o&&(o+=" "),o+=e)}break;default:o=t}o&&(r&&(r+=" "),r+=o)}return r};var u=n(2855),d=n(966);const{createCssAndCx:f}={createCssAndCx:function(e){const{cache:t}=e,n=(...e)=>{const n=(0,u.J)(e,t.registered);(0,d.sk)(t,n,!1);const r=`${t.key}-${n.name}`;{const n=e[0];(function(e){return e instanceof Object&&!("styles"in e)&&!("length"in e)&&!("__emotion_styles"in e)})(n)&&h.saveClassNameCSSObjectMapping(t,r,n)}return r};return{css:n,cx:(...e)=>{const r=c(e),o=h.fixClassName(t,r,n);return function(e,t,n){const r=[],o=(0,d.Rk)(e,r,n);return r.length<2?n:o+t(r)}(t.registered,n,o)}}}};function p(e){const{useCache:t}=e;return{useCssAndCx:function(){const e=t(),{css:n,cx:r}=function(t,n){var r;const i=(0,o.useRef)();return(!i.current||n.length!==(null===(r=i.current.prevDeps)||void 0===r?void 0:r.length)||i.current.prevDeps.map((e,t)=>e===n[t]).indexOf(!1)>=0)&&(i.current={v:f({cache:e}),prevDeps:[...n]}),i.current.v}(0,[e]);return{css:n,cx:r}}}}const h=(()=>{const e=new WeakMap;return{saveClassNameCSSObjectMapping:(t,n,r)=>{let o=e.get(t);void 0===o&&(o=new Map,e.set(t,o)),o.set(n,r)},fixClassName:(t,n,r)=>{const o=e.get(t);return c(function(e){let t=!1;return e.map(([e,n])=>{if(void 0===n)return e;let r;if(t)r={"&&":n};else{r=e;for(const e in n)if(e.startsWith("@media")){t=!0;break}}return r})}(n.split(" ").map(e=>[e,null==o?void 0:o.get(e)])).map(e=>"string"==typeof e?e:r(e)))}}})();function g(e){if(!(e instanceof Object)||"function"==typeof e)return e;const t=[];for(const n in e){const r=e[n],o=typeof r;if("string"!==o&&("number"!==o||isNaN(r))&&"boolean"!==o&&null!=r)return e;t.push(`${n}:${o}_${r}`)}return"xSqLiJdLMd9s"+t.join("|")}function m(e,t,n){if(!(t instanceof Object))return e;const r={};return a(e).forEach(o=>r[o]=n(e[o],t[o])),a(t).forEach(n=>{if(n in e)return;const o=t[n];"string"==typeof o&&(r[n]=o)}),r}const A=({classes:e,theme:t,muiStyleOverridesParams:n,css:r,cx:i,name:a})=>{var l,s;if("makeStyle no name"!==a){if(void 0!==n&&void 0===a)throw new Error("To use muiStyleOverridesParams, you must specify a name using .withName('MyComponent')")}else a=void 0;let c;try{c=void 0===a?void 0:(null===(s=null===(l=t.components)||void 0===l?void 0:l[a])||void 0===s?void 0:s.styleOverrides)||void 0}catch(e){}const u=(0,o.useMemo)(()=>{if(void 0===c)return;const e={};for(const o in c){const i=c[o];i instanceof Object&&(e[o]=r("function"==typeof i?i({theme:t,ownerState:null==n?void 0:n.ownerState,...null==n?void 0:n.props}):i))}return e},[c,g(null==n?void 0:n.props),g(null==n?void 0:n.ownerState),r]);return{classes:e=(0,o.useMemo)(()=>m(e,u,i),[e,u,i])}},b=n(1733)._;let v=0;function y(e){const{useTheme:t,cache:n}=e,{useCache:r}=C({cacheProvidedAtInception:n}),{useCssAndCx:c}=p({useCache:r});return{makeStyles:function(e){const{name:n,uniqId:u=""+v++}=null!=e?e:{},d="object"!=typeof n?n:Object.keys(n)[0];return function(e){const n="function"==typeof e?e:()=>e;return function(e,f){const p=t();let{css:h,cx:b}=c();const v=r();let y=(0,o.useMemo)(()=>{const t={},r="undefined"!=typeof Proxy&&new Proxy({},{get:(e,n)=>("symbol"==typeof n&&l(!1),t[n]=`${v.key}-${u}${void 0!==d?`-${d}`:""}-${n}-ref`)}),o=n(p,e,r||{}),c=i(a(o).map(e=>{const n=o[e];return n.label||(n.label=`${void 0!==d?`${d}-`:""}${e}`),[e,`${h(n)}${s(0,e in t)?` ${t[e]}`:""}`]}));return a(t).forEach(e=>{e in c||(c[e]=t[e])}),c},[v,h,b,p,g(e)]);{const e=null==f?void 0:f.props.classes;y=(0,o.useMemo)(()=>m(y,e,b),[y,g(e),b])}{const e=A({classes:y,css:h,cx:b,name:null!=d?d:"makeStyle no name",idOfUseStyles:u,muiStyleOverridesParams:f,theme:p});void 0!==e.classes&&(y=e.classes),void 0!==e.css&&(h=e.css),void 0!==e.cx&&(b=e.cx)}return{classes:y,theme:p,css:h,cx:b}}}},useStyles:function(){const e=t(),{css:n,cx:r}=c();return{theme:e,css:n,cx:r}}}}const w=(0,o.createContext)(void 0),{createUseCache:C}={createUseCache:function(e){const{cacheProvidedAtInception:t}=e;return{useCache:function(){var e;const n=b(),r=(0,o.useContext)(w),i=null!==(e=null!=t?t:r)&&void 0!==e?e:n;if(null===i)throw new Error(["In order to get SSR working with tss-react you need to explicitly provide an Emotion cache.","MUI users be aware: This is not an error strictly related to tss-react, with or without tss-react,","MUI needs an Emotion cache to be provided for SSR to work.","Here is the MUI documentation related to SSR setup: https://mui.com/material-ui/guides/server-rendering/","TSS provides helper that makes the process of setting up SSR easier: https://docs.tss-react.dev/ssr"].join("\n"));return i}}}};function S(e){return e.charAt(0).toUpperCase()+e.slice(1)}const x=new WeakMap,E="getClasses should only be used in conjunction with withStyles";function I(e){const t=e.classes;if(void 0===t)throw new Error(E);const n=x.get(t);if(void 0===n)throw new Error(E);return n}function k(e){const t={},n={};return Object.keys(e).forEach(r=>(r.startsWith("@media")?n:t)[r]=e[r]),Object.keys(n).forEach(e=>{const r=n[e];Object.keys(r).forEach(n=>{var o;return t[n]={...null!==(o=t[n])&&void 0!==o?o:{},[e]:r[n]}})}),t}const R=(()=>{const e="object"==typeof document&&"function"==typeof(null===document||void 0===document?void 0:document.getElementById),t="undefined"!=typeof jest,n="undefined"!=typeof mocha,r="undefined"!=typeof __vitest_worker__;return!(e||t||n||r)})();function M(e){P=0,B.splice(0,B.length);const{useContext:t,usePlugin:n,cache:r}=e,{useCache:o}=C({cacheProvidedAtInception:r}),{useCssAndCx:i}=p({useCache:o});return{tss:_({useContext:t,useCache:o,useCssAndCx:i,usePlugin:null!=n?n:({classes:e,cx:t,css:n})=>({classes:e,cx:t,css:n}),name:void 0,doesUseNestedSelectors:!1})}}let P=0;const B=[];function _(e){const{useContext:t,useCache:n,useCssAndCx:r,usePlugin:o,name:c,doesUseNestedSelectors:u}=e;return{withParams:()=>_({...e}),withName:t=>_({...e,name:"object"!=typeof t?t:Object.keys(t)[0]}),withNestedSelectors:()=>_({...e,doesUseNestedSelectors:!0}),create:e=>{const d="x"+P++;if(void 0!==c)for(;;){const e=B.find(e=>e.name===c);if(void 0===e)break;B.splice(B.indexOf(e),1)}const f="function"==typeof e?e:()=>e;return function(p){var h,A,b;const{classesOverrides:v,...y}=null!=p?p:{},w=t(),{css:C,cx:S}=r(),x=n(),E=function(e){const{cache:t,cssObjectByRuleNameOrGetCssObjectByRuleName:n,classesOverridesRef:r,paramsAndPluginParamsRef:o,idOfUseStyles:i,context:s,getClasses:c}=e;e:{const e=T.get(t);if(void 0===e)break e;const l=e.get(n);if(void 0===l)break e;const c=l.get(r);if(void 0===c)break e;const u=c.get(o);if(void 0===u)break e;const d=u.find(({context:e})=>{if(e===s)return!0;if(a(e).length!==a(s).length)return!1;for(const t in e)if(g(e[t])!==g(s[t]))return!1;return!0});if(void 0!==d){if((null==d?void 0:d.idOfUseStyles)===i)return d.result;u.splice(u.indexOf(d),1)}}const u=c();{T.has(t)||T.set(t,new WeakMap);const e=T.get(t);l(void 0!==e),e.has(n)||e.set(n,new Map);const a=e.get(n);l(void 0!==a),a.has(r)||(a.size>200&&a.clear(),a.set(r,new Map));const c=a.get(r);if(l(void 0!==c),!c.has(o)){{const e="string"==typeof o?257:5;c.size<e||c.clear()}c.set(o,[])}let d=c.get(o);l(void 0!==d),d.length>5&&(d=[]),d.push({idOfUseStyles:i,context:s,result:u})}return u}({cache:x,cssObjectByRuleNameOrGetCssObjectByRuleName:e,classesOverridesRef:g(v),paramsAndPluginParamsRef:g(y),idOfUseStyles:d,context:w,getClasses:()=>{const e={},t=f({...p,...w,...u?{classes:"undefined"==typeof Proxy?{}:new Proxy({},{get:(t,n)=>{if("symbol"==typeof n&&l(!1),R&&void 0===c)throw new Error(["tss-react: In SSR setups, in order to use nested selectors, you must also give a unique name to the useStyle function.",'Solution: Use tss.withName("ComponentName").withNestedSelectors<...>()... to set a name.'].join("\n"));e:{if(void 0===c)break e;let e=B.find(e=>e.name===c&&e.idOfUseStyles===d);void 0===e&&(e={name:c,idOfUseStyles:d,nestedSelectorRuleNames:new Set},B.push(e)),e.nestedSelectorRuleNames.add(n)}if(void 0!==c&&void 0!==B.find(e=>e.name===c&&e.idOfUseStyles!==d&&e.nestedSelectorRuleNames.has(n)))throw new Error([`tss-react: There are in your codebase two different useStyles named "${c}" that`,`both use use the nested selector ${n}.\n`,"This may lead to CSS class name collisions, causing nested selectors to target elements outside of the intended scope.\n","Solution: Ensure each useStyles using nested selectors has a unique name.\n",'Use: tss.withName("UniqueName").withNestedSelectors<...>()...'].join(" "));return e[n]=`${x.key}-${void 0!==c?c:d}-${n}-ref`}})}:{}});let n=i(a(t).map(n=>{const r=t[n];return r.label||(r.label=`${void 0!==c?`${c}-`:""}${n}`),[n,`${C(r)}${s(0,n in e)?` ${e[n]}`:""}`]}));return a(e).forEach(t=>{t in n||(n[t]=e[t])}),n=m(n,v,S),n}}),I=o({classes:E,css:C,cx:S,idOfUseStyles:d,name:c,...w,...y});return{classes:null!==(h=I.classes)&&void 0!==h?h:E,css:null!==(A=I.css)&&void 0!==A?A:C,cx:null!==(b=I.cx)&&void 0!==b?b:S,...w}}}}}const T=new WeakMap,{tss:O}=M({useContext:()=>({})}),{makeStyles:D,withStyles:N}=(O.create({}),{...y(L={useTheme:r.A}),...function(e){const{useTheme:t,cache:n}=e,{makeStyles:r}=y({useTheme:t,cache:n});function i(e,t,n){const i="string"==typeof e?(()=>{const t=e,n=function({children:e,...n}){return(0,o.createElement)(t,n,e)};return Object.defineProperty(n,"name",{value:S(t)}),n})():e,a=(()=>{{const{name:e}=null!=n?n:{};if(void 0!==e)return"object"!=typeof e?e:Object.keys(e)[0]}let e;{const t=i.displayName;"string"==typeof t&&""!==t&&(e=t)}e:{if(void 0!==e)break e;const t=i.name;"string"==typeof t&&""!==t&&(e=t)}if(void 0!==e)return e=e.replace(/\$/g,"usd"),e=e.replace(/\(/g,"_").replace(/\)/g,"_"),e=e.replace(/[^a-zA-Z0-9-_]/g,"_"),e})(),l=r({...n,name:a})("function"==typeof t?(e,n,r)=>k(t(e,n,r)):k(t));function s(e){for(const t in e)if("root"!==t)return!0;return!1}const c=(0,o.forwardRef)(function(t,n){const{className:r,classes:a,...c}=t,{classes:u,cx:d}=l(t,{props:t}),f=d(u.root,r);return x.set(u,{...u,root:f}),o.createElement(i,{ref:n,className:s(u)?r:f,..."string"==typeof e?{}:{classes:u},...c})});return void 0!==a&&(c.displayName=`${S(a)}WithStyles`,Object.defineProperty(c,"name",{value:c.displayName})),c}return i.getClasses=I,{withStyles:i}}(L)});var L;const{tss:F}=M({useContext:function(){return{theme:(0,r.A)()}},usePlugin:A});F.create({})},3529(e,t,n){"use strict";var r=n(405),o="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},i=r.useState,a=r.useEffect,l=r.useLayoutEffect,s=r.useDebugValue;function c(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!o(e,n)}catch(e){return!0}}var u="undefined"==typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t){return t()}:function(e,t){var n=t(),r=i({inst:{value:n,getSnapshot:t}}),o=r[0].inst,u=r[1];return l(function(){o.value=n,o.getSnapshot=t,c(o)&&u({inst:o})},[e,n,t]),a(function(){return c(o)&&u({inst:o}),e(function(){c(o)&&u({inst:o})})},[e]),s(n),n};t.useSyncExternalStore=void 0!==r.useSyncExternalStore?r.useSyncExternalStore:u},1142(e,t,n){"use strict";var r=n(405),o=n(524),i="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},a=o.useSyncExternalStore,l=r.useRef,s=r.useEffect,c=r.useMemo,u=r.useDebugValue;t.useSyncExternalStoreWithSelector=function(e,t,n,r,o){var d=l(null);if(null===d.current){var f={hasValue:!1,value:null};d.current=f}else f=d.current;d=c(function(){function e(e){if(!s){if(s=!0,a=e,e=r(e),void 0!==o&&f.hasValue){var t=f.value;if(o(t,e))return l=t}return l=e}if(t=l,i(a,e))return t;var n=r(e);return void 0!==o&&o(t,n)?(a=e,t):(a=e,l=n)}var a,l,s=!1,c=void 0===n?null:n;return[function(){return e(t())},null===c?void 0:function(){return e(c())}]},[t,n,r,o]);var p=a(e,d[0],d[1]);return s(function(){f.hasValue=!0,f.value=p},[p]),u(p),p}},524(e,t,n){"use strict";e.exports=n(3529)},9966(e,t,n){"use strict";e.exports=n(1142)},4347(e,t,n){"use strict";function r(){return r=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},r.apply(null,arguments)}n.d(t,{A:()=>r})},2993(e,t,n){"use strict";function r(e,t){return r=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},r(e,t)}function o(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,r(e,t)}n.d(t,{A:()=>o})},4722(e,t,n){"use strict";function r(e,t){if(null==e)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(-1!==t.indexOf(r))continue;n[r]=e[r]}return n}n.d(t,{A:()=>r})},7434(e,t,n){"use strict";n.d(t,{A:()=>hv});var r=n(9793),o=n(405),i=n(4417),a=n(654),l=n(6081),s=n(4045);const c=(0,s.n)()(e=>({fieldValue:{wordBreak:"break-word",maxHeight:300,fontSize:12,padding:e.spacing(.5),overflow:"auto"}}));function u({value:e}){const{classes:t}=c(),n=/^https?:\/\//.exec(`${e}`);return(0,r.jsx)("div",{className:t.fieldValue,children:(0,o.isValidElement)(e)?e:n?(0,r.jsx)(i.A,{href:`${e}`,children:`${e}`}):(0,r.jsx)(a.A,{html:(0,l.Gvm)(e)?JSON.stringify(e):String(e)})})}var d=n(2351),f=n(7615);const p=(0,s.n)()(e=>({fieldDescription:{"&:hover":{background:"dark"===e.palette.mode?"#e65100":"yellow"}},fieldName:{wordBreak:"break-all",minWidth:90,borderBottom:"1px solid #0003",fontSize:12,background:e.palette.action.disabledBackground,marginRight:e.spacing(1),padding:e.spacing(.5)}}));function h({description:e,name:t,width:n,prefix:o=[]}){const{classes:i}=p(),a=[...o,t].join(".");return e?(0,r.jsx)(d.A,{title:e,placement:"left",children:(0,r.jsx)("div",{className:(0,f.cx)(i.fieldDescription,i.fieldName),children:a})}):(0,r.jsx)("div",{className:i.fieldName,style:{width:n},children:a})}const g=(0,s.n)()(e=>({field:{display:"flex",flexWrap:"wrap"},fieldSubvalue:{wordBreak:"break-word",maxHeight:300,padding:e.spacing(.5),border:`1px solid ${e.palette.action.selected}`,boxSizing:"border-box",overflow:"auto"}}));function m({name:e,value:t,description:n,formatter:i,prefix:a=[]}){const{classes:s}=g(),[c,d]=(0,o.useState)(!1),f=t.length>100,p=f&&!c?t.slice(0,100):t;return 1===t.length?(0,l.Gvm)(t[0])?(0,r.jsx)(hv,{formatter:i,attributes:t[0],prefix:[...a,e]}):(0,r.jsxs)("div",{className:s.field,children:[(0,r.jsx)(h,{prefix:a,description:n,name:e}),(0,r.jsx)(u,{value:i?i(t[0],e):t[0]})]}):t.every(e=>(0,l.Gvm)(e))?(0,r.jsx)(r.Fragment,{children:t.map((t,n)=>(0,r.jsx)(hv,{formatter:i,attributes:t,prefix:[...a,`${e}-${n}`]},`${JSON.stringify(t)}-${n}`))}):(0,r.jsxs)("div",{className:s.field,children:[(0,r.jsx)(h,{prefix:a,description:n,name:e}),p.map((t,n)=>(0,r.jsx)("div",{className:s.fieldSubvalue,children:(0,r.jsx)(u,{value:i?i(t,e):t})},`${JSON.stringify(t)}-${n}`)),f?(0,r.jsx)("button",{type:"button",onClick:()=>{d(e=>!e)},children:c?"Show less":`Showing 100 of ${t.length}. Show all...`}):null]})}var A=n(6807),b=n(548),v=n(4871),y=n(4347),w=n(5821);const C=parseInt(o.version,10),S=e=>{if(C>=19){const t=t=>e(t,t.ref??null);return t.displayName=e.displayName??e.name,t}return o.forwardRef(e)};var x=n(4722),E=n(851),I=n(4573),k=n(9225),R=n(941);const M=Object.is;function P(e,t){if(e===t)return!0;if(!(e instanceof Object&&t instanceof Object))return!1;let n=0,r=0;for(const r in e){if(n+=1,!M(e[r],t[r]))return!1;if(!(r in t))return!1}for(const e in t)r+=1;return n===r}function B(e){return o.memo(e,P)}var _=n(912),T=n(643),O=n(8783);function D(e){return(0,T.Ay)("MuiDataGrid",e)}const N={root:["autoHeight","autosizing","root--densityStandard","root--densityComfortable","root--densityCompact","root--disableUserSelection","root--noToolbar","withVerticalBorder"],children:["actionsCell","booleanCell","cell","cell--editable","cell--editing","cell--flex","cell--pinnedLeft","cell--pinnedRight","cell--rangeBottom","cell--rangeLeft","cell--rangeRight","cell--rangeTop","cell--selectionMode","cell--textCenter","cell--textLeft","cell--textRight","cell--withLeftBorder","cell--withRightBorder","cellCheckbox","cellEmpty","cellOffsetLeft","cellSkeleton","checkboxInput","columnHeader","columnHeader--alignCenter","columnHeader--alignLeft","columnHeader--alignRight","columnHeader--dragging","columnHeader--emptyGroup","columnHeader--filledGroup","columnHeader--filtered","columnHeader--last","columnHeader--moving","columnHeader--numeric","columnHeader--pinnedLeft","columnHeader--pinnedRight","columnHeader--siblingFocused","columnHeader--sortable","columnHeader--sorted","columnHeader--withLeftBorder","columnHeader--withRightBorder","columnHeaderCheckbox","columnHeaderDraggableContainer","columnHeaderTitleContainer","columnHeaderTitleContainerContent","columnSeparator","columnSeparator--resizable","columnSeparator--resizing","columnSeparator--sideLeft","columnSeparator--sideRight","container--bottom","container--top","detailPanelToggleCell","detailPanelToggleCell--expanded","editBooleanCell","filterIcon","filler--borderBottom","filler--pinnedLeft","filler--pinnedRight","groupingCriteriaCell","groupingCriteriaCellLoadingContainer","groupingCriteriaCellToggle","headerFilterRow","iconSeparator","menuIcon","menuIconButton","menuList","menuOpen","overlayWrapperInner","pinnedRows","pinnedRows--bottom","pinnedRows--top","row","row--borderBottom","row--detailPanelExpanded","row--dragging","row--dynamicHeight","row--editable","row--editing","row--firstVisible","row--lastVisible","rowReorderCell","rowReorderCell--draggable","rowReorderCellContainer","rowReorderCellPlaceholder","rowSkeleton","scrollbar","scrollbar--horizontal","scrollbar--vertical","scrollbarFiller","scrollbarFiller--pinnedRight","sortIcon","treeDataGroupingCell","treeDataGroupingCellLoadingContainer","treeDataGroupingCellToggle","withBorderColor","row--beingDragged"]},L=(0,O.A)("MuiDataGrid",[...N.root,...N.children,"aiAssistantPanel","aiAssistantPanelHeader","aiAssistantPanelTitleContainer","aiAssistantPanelTitle","aiAssistantPanelBody","aiAssistantPanelEmptyText","aiAssistantPanelFooter","aiAssistantPanelConversation","aiAssistantPanelConversationList","aiAssistantPanelConversationTitle","aiAssistantPanelSuggestions","aiAssistantPanelSuggestionsList","aiAssistantPanelSuggestionsItem","aiAssistantPanelSuggestionsLabel","aggregationColumnHeader","aggregationColumnHeader--alignLeft","aggregationColumnHeader--alignCenter","aggregationColumnHeader--alignRight","aggregationColumnHeaderLabel","aggregationRowOverlayWrapper","mainContent","withSidePanel","collapsible","collapsibleTrigger","collapsibleIcon","collapsiblePanel","columnHeader--filter","columnHeaderFilterInput","columnHeaderFilterOperatorLabel","columnHeaderTitle","columnHeaders","columnsManagement","columnsManagementRow","columnsManagementHeader","columnsManagementSearchInput","columnsManagementFooter","columnsManagementScrollArea","columnsManagementEmptyText","detailPanel","footerCell","panel","panelHeader","panelWrapper","panelContent","panelFooter","paper","editInputCell","longTextCell","longTextCellContent","longTextCellExpandButton","longTextCellCollapseButton","longTextCellPopup","longTextCellPopperContent","editLongTextCell","editLongTextCellValue","editLongTextCellPopup","editLongTextCellPopperContent","editLongTextCellTextarea","filler","filterForm","filterFormDeleteIcon","filterFormLogicOperatorInput","filterFormColumnInput","filterFormOperatorInput","filterFormValueInput","footerContainer","iconButtonContainer","main","main--hasPinnedRight","main--hiddenContent","menu","overlay","overlayWrapper","root","rowCount","rowReorderIcon","scrollArea--left","scrollArea--right","scrollArea--up","scrollArea--down","scrollArea","scrollShadow","scrollShadow--vertical","scrollShadow--horizontal","selectedRowCount","sortButton","shadowScrollArea","sidebar","sidebarHeader","toolbarContainer","toolbar","toolbarLabel","toolbarDivider","toolbarFilterList","toolbarQuickFilter","toolbarQuickFilterTrigger","toolbarQuickFilterControl","virtualScroller","virtualScroller--hasScrollX","virtualScrollerContent","virtualScrollerContent--overflowed","virtualScrollerRenderZone","pivotPanelAvailableFields","pivotPanelField","pivotPanelField--sorted","pivotPanelFieldActionContainer","pivotPanelFieldCheckbox","pivotPanelFieldDragIcon","pivotPanelFieldList","pivotPanelFieldName","pivotPanelHeader","pivotPanelPlaceholder","pivotPanelScrollArea","pivotPanelSearchContainer","pivotPanelSection","pivotPanelSectionTitle","pivotPanelSections","pivotPanelSwitch","pivotPanelSwitchLabel","prompt","promptContent","promptText","promptFeedback","promptChangeList","promptChangesToggle","promptChangesToggleIcon","promptIcon","promptIconContainer","promptError","promptAction","resizablePanelHandle","resizablePanelHandle--horizontal","resizablePanelHandle--vertical"]),F={values:{xs:0,sm:600,md:900,lg:1200,xl:1536},up:e=>{const t=F.values;return`@media (min-width:${"number"==typeof t[e]?t[e]:e}px)`}},Q={spacingUnit:"--DataGrid-t-spacing-unit",colors:{border:{base:"--DataGrid-t-color-border-base"},foreground:{base:"--DataGrid-t-color-foreground-base",muted:"--DataGrid-t-color-foreground-muted",accent:"--DataGrid-t-color-foreground-accent",disabled:"--DataGrid-t-color-foreground-disabled",error:"--DataGrid-t-color-foreground-error"},background:{base:"--DataGrid-t-color-background-base",overlay:"--DataGrid-t-color-background-overlay",backdrop:"--DataGrid-t-color-background-backdrop"},interactive:{hover:"--DataGrid-t-color-interactive-hover",hoverOpacity:"--DataGrid-t-color-interactive-hover-opacity",focus:"--DataGrid-t-color-interactive-focus",focusOpacity:"--DataGrid-t-color-interactive-focus-opacity",disabled:"--DataGrid-t-color-interactive-disabled",disabledOpacity:"--DataGrid-t-color-interactive-disabled-opacity",selected:"--DataGrid-t-color-interactive-selected",selectedOpacity:"--DataGrid-t-color-interactive-selected-opacity"}},header:{background:{base:"--DataGrid-t-header-background-base"}},cell:{background:{pinned:"--DataGrid-t-cell-background-pinned"}},radius:{base:"--DataGrid-t-radius-base"},typography:{font:{body:"--DataGrid-t-typography-font-body",small:"--DataGrid-t-typography-font-small",large:"--DataGrid-t-typography-font-large"},fontFamily:{base:"--DataGrid-t-typography-font-family-base"},fontWeight:{light:"--DataGrid-t-typography-font-weight-light",regular:"--DataGrid-t-typography-font-weight-regular",medium:"--DataGrid-t-typography-font-weight-medium",bold:"--DataGrid-t-typography-font-weight-bold"}},transitions:{easing:{easeIn:"--DataGrid-t-transition-easing-ease-in",easeOut:"--DataGrid-t-transition-easing-ease-out",easeInOut:"--DataGrid-t-transition-easing-ease-in-out"},duration:{short:"--DataGrid-t-transition-duration-short",base:"--DataGrid-t-transition-duration-base",long:"--DataGrid-t-transition-duration-long"}},shadows:{base:"--DataGrid-t-shadow-base",overlay:"--DataGrid-t-shadow-overlay"},zIndex:{panel:"--DataGrid-t-z-index-panel",menu:"--DataGrid-t-z-index-menu"}},j=function e(t){if("string"==typeof t)return`var(${t})`;const n={};for(const r in t)Object.hasOwn(t,r)&&(n[r]=e(t[r]));return n}(Q),z=(0,y.A)({breakpoints:F,spacing:function(e,t,n,r){return void 0===e?$(1):void 0===t?$(e):void 0===n?$(e)+" "+$(t):void 0===r?$(e)+" "+$(t)+" "+$(n):$(e)+" "+$(t)+" "+$(n)+" "+$(r)},transition:function(e,t){const{duration:n=z.transitions.duration.base,easing:r=z.transitions.easing.easeInOut,delay:o=0}=t??{};return e.map(e=>`${e} ${n} ${r} ${o}ms`).join(", ")},keys:Q},j);function $(e){return 0===e?"0":`calc(var(--DataGrid-t-spacing-unit) * ${e})`}new Set;var H=n(524),G=n(985);const V=Object.is,W=P,U=(e,t)=>e===t||e.length===t.length&&e.every((e,n)=>e===t[n]),q=()=>({state:null,equals:null,selector:null,args:void 0}),Y=[],K=()=>null;function J(e,t,n=void 0,r=V){e.current.state;const i=(0,G.A)(q),a=null!==i.current.selector,[l,s]=o.useState(a?null:t(e,n));i.current.state=l,i.current.equals=r,i.current.selector=t;const c=i.current.args;if(i.current.args=n,a&&!((e,t)=>{let n=Object.is;return t instanceof Array?n=U:t instanceof Object&&(n=W),n(e,t)})(c,n)){const t=i.current.selector(e,i.current.args);i.current.equals(i.current.state,t)||(i.current.state=t,s(t))}const u=o.useCallback(()=>(i.current.subscription||(i.current.subscription=e.current.store.subscribe(()=>{const t=i.current.selector(e,i.current.args);i.current.equals(i.current.state,t)||(i.current.state=t,s(t))})),null),Y),d=o.useCallback(()=>(i.current.subscription||u(),()=>{i.current.subscription&&(i.current.subscription(),i.current.subscription=void 0)}),Y);return(0,H.useSyncExternalStore)(d,u,K),l}const X=o.createContext(void 0);function Z(){const e=o.useContext(X);if(void 0===e)throw new Error(["MUI X: Could not find the Data Grid private context.","It looks like you rendered your component outside of a DataGrid, DataGridPro or DataGridPremium parent component.","This can also happen if you are bundling multiple versions of the Data Grid."].join("\n"));return e}const ee={width:3,rx:1.5,x:10.5},te=e=>e.current.state.dimensions.isReady?e.current.state.dimensions.hasScrollX&&(!e.current.state.dimensions.hasScrollY||0===e.current.state.dimensions.scrollbarSize):0===e.current.state.dimensions.scrollbarSize,ne=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"Root",overridesResolver:(e,t)=>{const n=[t.root];return N.root.forEach(e=>{n.push({[`&.${L[e]}`]:t[e]})}),N.children.forEach(e=>{n.push({[`& .${L[e]}`]:t[e]})}),n}})(()=>{const e=J(Z(),te),t=z.colors.background.base,n=z.header.background.base,r=z.cell.background.pinned,o=re(z.colors.interactive.hover,1),i=z.colors.interactive.hoverOpacity,a=z.colors.interactive.selected,l=z.colors.interactive.selectedOpacity,s=a,c=`calc(${l} + ${i})`,u={hover:z.colors.interactive.hover,selected:a,selectedHover:a},d=ae(t,o,i,u.hover),f=ae(t,a,l,u.selected),p=ae(t,s,c,u.selectedHover),h=ae(r,o,i,u.hover),g=ae(r,a,l,u.selected),m=ae(r,s,c,u.selectedHover),A=e=>({[`& .${L["cell--pinnedLeft"]}, & .${L["cell--pinnedRight"]}`]:{backgroundColor:e,"&.Mui-selected":{backgroundColor:ae(e,f,l,u.selected),"&:hover":{backgroundColor:ae(e,p,c,u.selectedHover)}}}}),b=A(h),v=A(g),y=A(m),w={backgroundColor:f,"&:hover":{backgroundColor:p,"@media (hover: none)":{backgroundColor:f}}};return{"--unstable_DataGrid-radius":z.radius.base,"--unstable_DataGrid-headWeight":z.typography.fontWeight.medium,"--DataGrid-rowBorderColor":z.colors.border.base,"--DataGrid-cellOffsetMultiplier":2,"--DataGrid-width":"0px","--DataGrid-hasScrollX":"0","--DataGrid-hasScrollY":"0","--DataGrid-scrollbarSize":"10px","--DataGrid-rowWidth":"0px","--DataGrid-columnsTotalWidth":"0px","--DataGrid-leftPinnedWidth":"0px","--DataGrid-rightPinnedWidth":"0px","--DataGrid-headerHeight":"0px","--DataGrid-headersTotalHeight":"0px","--DataGrid-topContainerHeight":"0px","--DataGrid-bottomContainerHeight":"0px",flex:1,boxSizing:"border-box",position:"relative",borderWidth:"1px",borderStyle:"solid",borderColor:z.colors.border.base,borderRadius:"var(--unstable_DataGrid-radius)",backgroundColor:z.colors.background.base,color:z.colors.foreground.base,font:z.typography.font.body,outline:"none",height:"100%",display:"flex",minWidth:0,minHeight:0,flexDirection:"column",overflow:"hidden",overflowAnchor:"none",transform:"translate(0, 0)",[`.${L.main} > *:first-child/* emotion-disable-server-rendering-unsafe-selector-warning-please-do-not-use-this-the-warning-exists-for-a-reason */`]:{borderTopLeftRadius:"var(--unstable_DataGrid-radius)",borderTopRightRadius:"var(--unstable_DataGrid-radius)"},[`&.${L.autoHeight}`]:{height:"auto"},[`&.${L.autosizing}`]:{[`& .${L.columnHeaderTitleContainerContent} > *`]:{overflow:"visible !important"},"@media (hover: hover)":{[`& .${L.menuIcon}`]:{width:"0 !important",visibility:"hidden !important"}},[`& .${L.cell}`]:{overflow:"visible !important",whiteSpace:"nowrap",minWidth:"max-content !important",maxWidth:"max-content !important"},[`& .${L.groupingCriteriaCell}`]:{width:"unset"},[`& .${L.treeDataGroupingCell}`]:{width:"unset"},[`& .${L["columnHeader--filter"]}`]:{flex:"none !important",width:"unset !important"}},[`&.${L.withSidePanel}`]:{flexDirection:"row"},[`& .${L.mainContent}`]:{display:"flex",flexDirection:"column",overflow:"hidden",flex:1},[`& .${L.columnHeader}, & .${L.cell}`]:{WebkitTapHighlightColor:"transparent",padding:"0 10px",boxSizing:"border-box"},[`& .${L.columnHeader}:focus-within, & .${L.cell}:focus-within`]:{outline:`solid ${re(z.colors.interactive.focus,.5)} 1px`,outlineOffset:-1},[`& .${L.columnHeader}:focus, & .${L.cell}:focus`]:{outline:`solid ${z.colors.interactive.focus} 1px`,outlineOffset:-1},[`& .${L.columnHeader}:focus,\n & .${L["columnHeader--withLeftBorder"]},\n & .${L["columnHeader--withRightBorder"]},\n & .${L["columnHeader--siblingFocused"]}\n `]:{[`& .${L.columnSeparator}`]:{opacity:0},"@media (hover: none)":{[`& .${L["columnSeparator--resizable"]}`]:{opacity:1}},[`& .${L["columnSeparator--resizable"]}:hover`]:{opacity:1}},[`&.${L["root--noToolbar"]} [aria-rowindex="1"] [aria-colindex="1"]`]:{borderTopLeftRadius:"calc(var(--unstable_DataGrid-radius) - 1px)"},[`&.${L["root--noToolbar"]} [aria-rowindex="1"] .${L["columnHeader--last"]}`]:{borderTopRightRadius:e?"calc(var(--unstable_DataGrid-radius) - 1px)":void 0},[`& .${L.columnHeaderCheckbox}, & .${L.cellCheckbox}`]:{padding:0,justifyContent:"center",alignItems:"center"},[`& .${L.columnHeader}`]:{position:"relative",display:"flex",alignItems:"center",backgroundColor:n},[`& .${L.columnHeader} .${L.sortButton}`]:{backgroundColor:z.header.background.base},[`& .${L["columnHeader--filter"]}`]:{paddingTop:8,paddingBottom:8,paddingRight:5,minHeight:"min-content",overflow:"hidden"},[`&.${L["root--densityCompact"]} .${L["columnHeader--filter"]}`]:{paddingTop:4,paddingBottom:4},[`& .${L["virtualScroller--hasScrollX"]} .${L["columnHeader--last"]}`]:{overflow:"hidden"},[`& .${L["pivotPanelField--sorted"]} .${L.iconButtonContainer},\n & .${L["columnHeader--sorted"]} .${L.iconButtonContainer},\n & .${L["columnHeader--filtered"]} .${L.iconButtonContainer}`]:{visibility:"visible",width:"auto"},[`& .${L.pivotPanelField}:not(.${L["pivotPanelField--sorted"]}) .${L.sortButton},\n & .${L.columnHeader}:not(.${L["columnHeader--sorted"]}) .${L.sortButton}`]:{opacity:0,transition:z.transition(["opacity"],{duration:z.transitions.duration.short})},[`& .${L.columnHeaderTitleContainer}`]:{display:"flex",alignItems:"center",gap:z.spacing(.25),minWidth:0,flex:1,whiteSpace:"nowrap",overflow:"hidden"},[`& .${L.columnHeaderTitleContainerContent}`]:{overflow:"hidden",display:"flex",alignItems:"center"},[`& .${L["columnHeader--filledGroup"]} .${L.columnHeaderTitleContainer}`]:{borderBottomWidth:"1px",borderBottomStyle:"solid",boxSizing:"border-box"},[`& .${L.sortIcon}, & .${L.filterIcon}`]:{fontSize:"inherit"},[`& .${L["columnHeader--sortable"]}`]:{cursor:"pointer"},[`& .${L["columnHeader--alignCenter"]} .${L.columnHeaderTitleContainer}`]:{justifyContent:"center"},[`& .${L["columnHeader--alignRight"]} .${L.columnHeaderDraggableContainer}, & .${L["columnHeader--alignRight"]} .${L.columnHeaderTitleContainer}`]:{flexDirection:"row-reverse"},[`& .${L["columnHeader--alignCenter"]} .${L.menuIcon}`]:{marginLeft:"auto"},[`& .${L["columnHeader--alignRight"]} .${L.menuIcon}`]:{marginRight:"auto",marginLeft:-5},[`& .${L["columnHeader--moving"]}`]:{backgroundColor:d},[`& .${L["columnHeader--pinnedLeft"]}, & .${L["columnHeader--pinnedRight"]}`]:{position:"sticky",zIndex:40,background:z.header.background.base},[`& .${L.columnSeparator}`]:{position:"absolute",overflow:"hidden",zIndex:30,display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",maxWidth:10,color:z.colors.border.base},[`& .${L.columnHeaders}`]:{width:"var(--DataGrid-rowWidth)",backgroundColor:n},"@media (hover: hover)":{[`& .${L.columnHeader}:hover`]:{[`& .${L.menuIcon}`]:{width:"auto",visibility:"visible"},[`& .${L.iconButtonContainer}`]:{visibility:"visible",width:"auto"}},[`& .${L.columnHeader}:not(.${L["columnHeader--sorted"]}):hover .${L.sortButton},\n & .${L.pivotPanelField}:not(.${L["pivotPanelField--sorted"]}):hover .${L.sortButton},\n & .${L.pivotPanelField}:not(.${L["pivotPanelField--sorted"]}) .${L.sortButton}:focus-visible`]:{opacity:1},[`& .${L.columnHeader}:not(.${L["columnHeader--sorted"]}):hover .${L.sortButton} > *,\n & .${L.pivotPanelField}:not(.${L["pivotPanelField--sorted"]}):hover .${L.sortButton} > *,\n & .${L.pivotPanelField}:not(.${L["pivotPanelField--sorted"]}) .${L.sortButton}:focus-visible > *`]:{opacity:.78},[`& .${L.pivotPanelFieldActionContainer} button:hover`]:{backgroundColor:z.colors.background.base}},"@media (hover: none)":{[`& .${L.columnHeader} .${L.menuIcon}`]:{width:"auto",visibility:"visible"},[`& .${L.columnHeader}:focus,\n & .${L["columnHeader--siblingFocused"]}`]:{[`.${L["columnSeparator--resizable"]}`]:{color:z.colors.foreground.accent}},[`& .${L.pivotPanelField}:not(.${L["pivotPanelField--sorted"]}) .${L.sortButton}`]:{opacity:.78}},[`& .${L["columnHeader--withLeftBorder"]} .${L["columnSeparator--sideLeft"]}:not(.${L["columnSeparator--resizable"]}), & .${L["columnHeader--withRightBorder"]} .${L["columnSeparator--sideRight"]}:not(.${L["columnSeparator--resizable"]})`]:{display:"none"},[`& .${L["columnSeparator--sideLeft"]}`]:{left:-5},[`& .${L["columnSeparator--sideRight"]}`]:{right:-5},[`& .${L["columnHeader--withRightBorder"]} .${L["columnSeparator--sideLeft"]}`]:{left:-5.5},[`& .${L["columnHeader--withRightBorder"]} .${L["columnSeparator--sideRight"]}`]:{right:-5.5},[`& .${L["columnSeparator--resizable"]}`]:{cursor:"col-resize",touchAction:"none",[`&.${L["columnSeparator--resizing"]}`]:{color:z.colors.foreground.accent},"@media (hover: none)":{[`& .${L.iconSeparator} rect`]:ee},"@media (hover: hover)":{"&:hover":{color:z.colors.foreground.accent,[`& .${L.iconSeparator} rect`]:ee}},"& svg":{pointerEvents:"none"}},[`& .${L.iconSeparator}`]:{color:"inherit",transition:z.transition(["color","width"],{duration:z.transitions.duration.short})},[`& .${L.menuIcon}`]:{width:0,visibility:"hidden",fontSize:20,marginRight:-5,display:"flex",alignItems:"center"},[`.${L.menuOpen}`]:{visibility:"visible",width:"auto"},[`& .${L.headerFilterRow}`]:{[`& .${L.columnHeader}, & .${L.scrollbarFiller}`]:{boxSizing:"border-box",borderBottom:"1px solid var(--DataGrid-rowBorderColor)"}},[`& .${L["row--borderBottom"]} .${L.columnHeader},\n & .${L["row--borderBottom"]} .${L.filler},\n & .${L["row--borderBottom"]} .${L.scrollbarFiller}`]:{borderBottom:"1px solid var(--DataGrid-rowBorderColor)"},[`& .${L["row--borderBottom"]} .${L.cell}`]:{borderBottom:"1px solid var(--rowBorderColor)"},[`.${L.row}`]:{display:"flex",width:"var(--DataGrid-rowWidth)",breakInside:"avoid","--rowBorderColor":"var(--DataGrid-rowBorderColor)",[`&.${L["row--firstVisible"]}`]:{"--rowBorderColor":"transparent"},"&:hover":{backgroundColor:d,"@media (hover: none)":{backgroundColor:"transparent"}},[`&.${L.rowSkeleton}:hover`]:{backgroundColor:"transparent"},"&.Mui-selected":w,position:"relative"},[`& .${L.cell}`]:{flex:"0 0 auto",height:"var(--height)",width:"var(--width)",lineHeight:"calc(var(--height) - 1px)",boxSizing:"border-box",borderTop:"1px solid var(--rowBorderColor)",overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis","&.Mui-selected":w},[`& .${L["virtualScrollerContent--overflowed"]} .${L["row--lastVisible"]} .${L.cell}`]:{borderTopColor:"transparent"},[`& .${L.pinnedRows} .${L.row}, .${L.aggregationRowOverlayWrapper} .${L.row}`]:{backgroundColor:r,"&:hover":{backgroundColor:h}},[`& .${L["pinnedRows--top"]} :first-of-type`]:{[`& .${L.cell}, .${L.scrollbarFiller}`]:{borderTop:"none"}},[`&.${L["root--disableUserSelection"]}`]:{userSelect:"none"},[`& .${L["row--dynamicHeight"]} > .${L.cell}`]:{whiteSpace:"initial",lineHeight:"inherit"},[`& .${L.cellEmpty}`]:{flex:1,padding:0,height:"unset"},[`& .${L.cell}.${L["cell--selectionMode"]}`]:{cursor:"default"},[`& .${L.cell}.${L["cell--editing"]}`]:{padding:1,display:"flex",boxShadow:z.shadows.base,backgroundColor:z.colors.background.overlay,"&:focus-within":{outline:`1px solid ${z.colors.interactive.focus}`,outlineOffset:-1}},[`& .${L["cell--editing"]}`]:{"& .MuiInputBase-root":{height:"100%"}},[`& .${L["row--editing"]}`]:{boxShadow:z.shadows.base},[`& .${L["row--editing"]} .${L.cell}`]:{boxShadow:"none",backgroundColor:z.colors.background.overlay},[`& .${L.editBooleanCell}`]:{display:"flex",height:"100%",width:"100%",alignItems:"center",justifyContent:"center"},[`& .${L.booleanCell}[data-value="true"]`]:{color:z.colors.foreground.muted},[`& .${L.booleanCell}[data-value="false"]`]:{color:z.colors.foreground.disabled},[`& .${L.actionsCell}`]:{display:"inline-flex",alignItems:"center",gridGap:z.spacing(1)},[`& .${L.rowReorderCell}`]:{display:"inline-flex",flex:1,alignItems:"center",justifyContent:"center",opacity:z.colors.interactive.disabledOpacity},[`& .${L["rowReorderCell--draggable"]}`]:{cursor:"grab",opacity:1},[`& .${L.rowReorderCellContainer}`]:{padding:0,display:"flex",alignItems:"stretch"},[`.${L.withBorderColor}`]:{borderColor:z.colors.border.base},[`& .${L["cell--withLeftBorder"]}, & .${L["columnHeader--withLeftBorder"]}`]:{borderLeftColor:"var(--DataGrid-rowBorderColor)",borderLeftWidth:"1px",borderLeftStyle:"solid"},[`& .${L["cell--withRightBorder"]}, & .${L["columnHeader--withRightBorder"]}`]:{borderRightColor:"var(--DataGrid-rowBorderColor)",borderRightWidth:"1px",borderRightStyle:"solid"},[`& .${L["cell--flex"]}`]:{display:"flex",alignItems:"center",lineHeight:"inherit"},[`& .${L["cell--textLeft"]}`]:{textAlign:"left",justifyContent:"flex-start"},[`& .${L["cell--textRight"]}`]:{textAlign:"right",justifyContent:"flex-end"},[`& .${L["cell--textCenter"]}`]:{textAlign:"center",justifyContent:"center"},[`& .${L["cell--pinnedLeft"]}, & .${L["cell--pinnedRight"]}`]:{position:"sticky",zIndex:30,background:z.cell.background.pinned,"&.Mui-selected":{backgroundColor:g}},[`& .${L.row}`]:{"&:hover":b,"&.Mui-selected":v,"&.Mui-selected:hover":y},[`& .${L.cellOffsetLeft}`]:{flex:"0 0 auto",display:"inline-block"},[`& .${L.cellSkeleton}`]:{flex:"0 0 auto",height:"100%",display:"inline-flex",alignItems:"center"},[`& .${L.columnHeaderDraggableContainer}`]:{display:"flex",width:"100%",height:"100%"},[`& .${L.rowReorderCellPlaceholder}`]:{display:"none"},[`& .${L["columnHeader--dragging"]}`]:{background:z.colors.background.overlay,padding:"0 12px",borderRadius:"var(--unstable_DataGrid-radius)",opacity:z.colors.interactive.disabledOpacity},[`& .${L["row--dragging"]}`]:{background:z.colors.background.overlay,padding:"0 12px",borderRadius:"var(--unstable_DataGrid-radius)",border:"1px solid var(--DataGrid-rowBorderColor)",color:z.colors.foreground.base,transform:"translateZ(0)",[`& .${L.rowReorderCellPlaceholder}`]:{padding:"0 6px",display:"flex"}},[`& .${L.treeDataGroupingCell}`]:{display:"flex",alignItems:"center",width:"100%"},[`& .${L.treeDataGroupingCellToggle}`]:{flex:"0 0 28px",alignSelf:"stretch",marginRight:z.spacing(2)},[`& .${L.treeDataGroupingCellLoadingContainer}, .${L.groupingCriteriaCellLoadingContainer}`]:{display:"flex",alignItems:"center",justifyContent:"center",height:"100%"},[`& .${L.groupingCriteriaCell}`]:{display:"flex",alignItems:"center",width:"100%"},[`& .${L.groupingCriteriaCellToggle}`]:{flex:"0 0 28px",alignSelf:"stretch",marginRight:z.spacing(2)},[`& .${L.columnHeaders} .${L.scrollbarFiller}`]:{backgroundColor:n},[`.${L.scrollbarFiller}`]:{minWidth:"calc(var(--DataGrid-hasScrollY) * var(--DataGrid-scrollbarSize))",alignSelf:"stretch",backgroundColor:n,[`&.${L["scrollbarFiller--pinnedRight"]}`]:{position:"sticky",zIndex:40,right:0}},[`& .${L.filler}`]:{flex:"1 0 auto"},[`& .${L["filler--borderBottom"]}`]:{borderBottom:"1px solid var(--DataGrid-rowBorderColor)"},[`& .${L.columnHeaders} .${L.filler}`]:{backgroundColor:n},[`& .${L["main--hiddenContent"]}`]:{[`& .${L.virtualScrollerContent}`]:{position:"fixed",visibility:"hidden"},[`& .${L.pinnedRows}`]:{display:"none"}},[`& .${L["row--beingDragged"]}`]:{color:z.colors.foreground.disabled,"&:hover":{backgroundColor:"transparent"}}}});function re(e,t){return`rgba(from ${e} r g b / ${t})`}const oe="undefined"!=typeof CSS&&"function"==typeof CSS.supports&&CSS.supports("color","color-mix(in srgb, red 50%, blue 50%)"),ie=(e,t)=>oe?e:t;function ae(e,t,n,r){return ie(`color-mix(in srgb,${e}, ${t} calc(${n} * 100%))`,r)}const le=o.createContext(void 0),se=()=>{const e=o.useContext(le);if(!e)throw new Error("MUI X: useGridRootProps should only be used inside the DataGrid, DataGridPro or DataGridPremium component.");return e},ce=o.createContext(void 0),ue=()=>{const e=o.useContext(ce);if(void 0===e)throw new Error(["MUI X: Could not find the Data Grid configuration context.","It looks like you rendered your component outside of a DataGrid, DataGridPro or DataGridPremium parent component.","This can also happen if you are bundling multiple versions of the Data Grid."].join("\n"));return e},de=o.createContext({className:"unset",tag:(0,r.jsx)("style",{href:"/unset"})});function fe(){return o.useContext(de).className}function pe(e){const t=ue(),n=se(),i=t.hooks.useCSSVariables(),a=o.useMemo(()=>{const e=`MuiDataGridVariables-${i.id}`,t=`.${e}{${function(e){let t="";for(const n in e)Object.hasOwn(e,n)&&void 0!==e[n]&&(t+=`${n}:${e[n]};`);return t}(i.variables)}}`;return{className:e,tag:(0,r.jsx)("style",{href:`/${e}`,nonce:n.nonce,children:t})}},[n.nonce,i]);return(0,r.jsx)(de.Provider,{value:a,children:e.children})}var he=Symbol("NOT_FOUND");var ge=e=>Array.isArray(e)?e:[e];var me=(e,t)=>e===t;function Ae(e,t){const n="object"==typeof t?t:{equalityCheck:t},{equalityCheck:r=me,maxSize:o=1,resultEqualityCheck:i}=n,a=function(e){return function(t,n){if(null===t||null===n||t.length!==n.length)return!1;const{length:r}=t;for(let o=0;o<r;o++)if(!e(t[o],n[o]))return!1;return!0}}(r);let l=0;const s=o<=1?function(e){let t;return{get:n=>t&&e(t.key,n)?t.value:he,put(e,n){t={key:e,value:n}},getEntries:()=>t?[t]:[],clear(){t=void 0}}}(a):function(e,t){let n=[];function r(e){const r=n.findIndex(n=>t(e,n.key));if(r>-1){const e=n[r];return r>0&&(n.splice(r,1),n.unshift(e)),e.value}return he}return{get:r,put:function(t,o){r(t)===he&&(n.unshift({key:t,value:o}),n.length>e&&n.pop())},getEntries:function(){return n},clear:function(){n=[]}}}(o,a);function c(){let t=s.get(arguments);if(t===he){if(t=e.apply(null,arguments),l++,i){const e=s.getEntries().find(e=>i(e.value,t));e&&(t=e.value,0!==l&&l--)}s.put(arguments,t)}return t}return c.clearCache=()=>{s.clear(),c.resetResultsCount()},c.resultsCount=()=>l,c.resetResultsCount=()=>{l=0},c}var be=class{constructor(e){this.value=e}deref(){return this.value}},ve=(()=>"undefined"==typeof WeakRef?be:WeakRef)();function ye(){return{s:0,v:void 0,o:null,p:null}}function we(e,t={}){let n={s:0,v:void 0,o:null,p:null};const{resultEqualityCheck:r}=t;let o,i=0;function a(){let t=n;const{length:a}=arguments;for(let e=0,n=a;e<n;e++){const n=arguments[e];if("function"==typeof n||"object"==typeof n&&null!==n){let e=t.o;null===e&&(t.o=e=new WeakMap);const r=e.get(n);void 0===r?(t=ye(),e.set(n,t)):t=r}else{let e=t.p;null===e&&(t.p=e=new Map);const r=e.get(n);void 0===r?(t=ye(),e.set(n,t)):t=r}}const l=t;let s;if(1===t.s)s=t.v;else if(s=e.apply(null,arguments),i++,r){const e=(c=o)instanceof ve?c.deref():c;null!=e&&r(e,s)&&(s=e,0!==i&&i--),o="object"==typeof s&&null!==s||"function"==typeof s?new ve(s):s}var c;return l.s=1,l.v=s,s}return a.clearCache=()=>{n={s:0,v:void 0,o:null,p:null},a.resetResultsCount()},a.resultsCount=()=>i,a.resetResultsCount=()=>{i=0},a}const Ce=function(e,...t){const n="function"==typeof e?{memoize:e,memoizeOptions:t}:e,r=(...e)=>{let t,r=0,o=0,i={},a=e.pop();"object"==typeof a&&(i=a,a=e.pop()),function(e,t="expected a function, instead received "+typeof e){if("function"!=typeof e)throw new TypeError(t)}(a,`createSelector expects an output function after the inputs, but received: [${typeof a}]`);const l={...n,...i},{memoize:s,memoizeOptions:c=[],argsMemoize:u=we,argsMemoizeOptions:d=[]}=l,f=ge(c),p=ge(d),h=function(e){const t=Array.isArray(e[0])?e[0]:e;return function(e,t="expected all items to be functions, instead received the following types: "){if(!e.every(e=>"function"==typeof e)){const n=e.map(e=>"function"==typeof e?`function ${e.name||"unnamed"}()`:typeof e).join(", ");throw new TypeError(`${t}[${n}]`)}}(t,"createSelector expects all input-selectors to be functions, but received the following types: "),t}(e),g=s(function(){return r++,a.apply(null,arguments)},...f),m=u(function(){o++;const e=function(e,t){const n=[],{length:r}=e;for(let o=0;o<r;o++)n.push(e[o].apply(null,t));return n}(h,arguments);return t=g.apply(null,e),t},...p);return Object.assign(m,{resultFunc:a,memoizedResultFunc:g,dependencies:h,dependencyRecomputations:()=>o,resetDependencyRecomputations:()=>{o=0},lastResult:()=>t,recomputations:()=>r,resetRecomputations:()=>{r=0},memoize:s,argsMemoize:u})};return Object.assign(r,{withTypes:()=>r}),r}({memoize:Ae,memoizeOptions:{maxSize:1,equalityCheck:Object.is}}),Se=(e,t,n,r,o,i,a,l,...s)=>{if(s.length>0)throw new Error("Unsupported number of selectors");let c;if(e&&t&&n&&r&&o&&i&&a&&l)c=(s,c,u,d)=>{const f=e(s,c,u,d),p=t(s,c,u,d),h=n(s,c,u,d),g=r(s,c,u,d),m=o(s,c,u,d),A=i(s,c,u,d),b=a(s,c,u,d);return l(f,p,h,g,m,A,b,c,u,d)};else if(e&&t&&n&&r&&o&&i&&a)c=(l,s,c,u)=>{const d=e(l,s,c,u),f=t(l,s,c,u),p=n(l,s,c,u),h=r(l,s,c,u),g=o(l,s,c,u),m=i(l,s,c,u);return a(d,f,p,h,g,m,s,c,u)};else if(e&&t&&n&&r&&o&&i)c=(a,l,s,c)=>{const u=e(a,l,s,c),d=t(a,l,s,c),f=n(a,l,s,c),p=r(a,l,s,c),h=o(a,l,s,c);return i(u,d,f,p,h,l,s,c)};else if(e&&t&&n&&r&&o)c=(i,a,l,s)=>{const c=e(i,a,l,s),u=t(i,a,l,s),d=n(i,a,l,s),f=r(i,a,l,s);return o(c,u,d,f,a,l,s)};else if(e&&t&&n&&r)c=(o,i,a,l)=>{const s=e(o,i,a,l),c=t(o,i,a,l),u=n(o,i,a,l);return r(s,c,u,i,a,l)};else if(e&&t&&n)c=(r,o,i,a)=>{const l=e(r,o,i,a),s=t(r,o,i,a);return n(l,s,o,i,a)};else if(e&&t)c=(n,r,o,i)=>{const a=e(n,r,o,i);return t(a,r,o,i)};else{if(!e)throw new Error("Missing arguments");c=e}return c},xe=(...e)=>{const t=new WeakMap;let n=1;const r=e[e.length-1],o=e.length-1||1,i=Math.max(r.length-o,0);if(i>3)throw new Error("Unsupported number of arguments");return(o,a,l,s)=>{let c=o.__cacheKey__;c||(c={id:n},o.__cacheKey__=c,n+=1);let u=t.get(c);if(!u){const n=1===e.length?[e=>e,r]:e;let o=e;const a=[void 0,void 0,void 0];switch(i){case 0:break;case 1:o=[...n.slice(0,-1),()=>a[0],r];break;case 2:o=[...n.slice(0,-1),()=>a[0],()=>a[1],r];break;case 3:o=[...n.slice(0,-1),()=>a[0],()=>a[1],()=>a[2],r];break;default:throw new Error("Unsupported number of arguments")}u=Ce(...o),u.selectorArgs=a,t.set(c,u)}switch(i){case 3:u.selectorArgs[2]=s;case 2:u.selectorArgs[1]=l;case 1:u.selectorArgs[0]=a}switch(i){case 0:return u(o);case 1:return u(o,a);case 2:return u(o,a,l);case 3:return u(o,a,l,s);default:throw new Error("unreachable")}}};const Ee=(...e)=>{const t=Se(...e);return(e,n,r,o)=>t(Re(e),n,r,o)},Ie=(...e)=>{const t=xe(...e);return(e,n,r,o)=>t(Re(e),n,r,o)},ke=e=>(t,n)=>e(Re(t),n);function Re(e){return"current"in e?e.current.state:e}const Me={compact:.7,comfortable:1.3,standard:1},Pe=ke(e=>e.density),Be=Ee(Pe,e=>Me[e]),_e=()=>()=>{},Te=()=>!1,Oe=()=>!0;let De=function(e){return e.LEFT="left",e.RIGHT="right",e}({});const Ne={left:[],right:[]},Le=ke(e=>e.props.listView??!1),Fe=ke(e=>e.listViewColumn),Qe=ke(e=>e.columns),je=Ee(Qe,e=>e.orderedFields),ze=Ee(Qe,e=>e.lookup),$e=Ie(je,ze,(e,t)=>e.map(e=>t[e])),He=Ee(Qe,e=>e.columnVisibilityModel),Ge=Ee(Qe,e=>e.initialColumnVisibilityModel),Ve=Ie($e,He,Le,Fe,(e,t,n,r)=>n&&r?[r]:e.filter(e=>!1!==t[e.field])),We=Ie(Ve,e=>e.map(e=>e.field)),Ue=ke(e=>e.pinnedColumns),qe=(Ie(Ue,je,(e,t)=>Ye(e,t)),Ie(Qe,Ue,We,Le,(e,t,n,r)=>{if(r)return Ne;const o=Ye(t,n);return{left:o.left.map(t=>e.lookup[t]),right:o.right.map(t=>e.lookup[t])}}));function Ye(e,t){if(!Array.isArray(e.left)&&!Array.isArray(e.right))return Ne;if(0===e.left?.length&&0===e.right?.length)return Ne;const n=(e,t)=>Array.isArray(e)?e.filter(e=>t.includes(e)):[],r=n(e.left,t),o=t.filter(e=>!r.includes(e)),i=n(e.right,o);return{left:r,right:i}}const Ke=Ie(Ve,e=>{const t=[];let n=0;for(let r=0;r<e.length;r+=1)t.push(n),n+=e[r].computedWidth;return t}),Je=Ie($e,e=>e.filter(e=>e.filterable)),Xe=Ie($e,e=>e.reduce((e,t)=>(t.filterable&&(e[t.field]=t),e),{})),Ze=Ie($e,e=>e.some(e=>void 0!==e.colSpan)),et=ke(e=>e.preferencePanel),tt=Ee(et,(e,t)=>!(!e.open||e.labelId!==t));var nt=function(e){return e.filters="filters",e.columns="columns",e.aiAssistant="aiAssistant",e}(nt||{});const rt=o.createContext(void 0);function ot(){const e=o.useContext(rt);if(void 0===e)throw new Error(["MUI X: Could not find the Data Grid context.","It looks like you rendered your component outside of a DataGrid, DataGridPro or DataGridPremium parent component.","This can also happen if you are bundling multiple versions of the Data Grid."].join("\n"));return e}const it=o.createContext(void 0);function at(){const e=o.useContext(it);if(void 0===e)throw new Error("MUI X: Missing context.");return e}function lt({children:e}){const t=o.useRef(null),n=o.useRef(null),i=o.useRef(null),a=o.useMemo(()=>({columnsPanelTriggerRef:t,filterPanelTriggerRef:n,aiAssistantPanelTriggerRef:i}),[]);return(0,r.jsx)(it.Provider,{value:a,children:e})}function st(){const e=ot(),t=J(e,$e),n=se(),o=J(e,et),{columnsPanelTriggerRef:i,filterPanelTriggerRef:a,aiAssistantPanelTriggerRef:l}=at(),s=e.current.unstable_applyPipeProcessors("preferencePanel",null,o.openedPanelValue??nt.filters);let c=null;switch(o.openedPanelValue){case nt.filters:c=a.current;break;case nt.columns:c=i.current;break;case nt.aiAssistant:c=l.current}return(0,r.jsx)(n.slots.panel,(0,y.A)({id:o.panelId,open:t.length>0&&o.open,"aria-labelledby":o.labelId,target:c,onClose:()=>e.current.hidePreferences()},n.slotProps?.panel,{children:s}))}function ct(){const e=se();return(0,r.jsxs)(o.Fragment,{children:[(0,r.jsx)(st,{}),e.showToolbar&&(0,r.jsx)(e.slots.toolbar,(0,y.A)({},e.slotProps?.toolbar))]})}const ut=ke(e=>e.dimensions),dt=Ee(ut,e=>e.columnsTotalWidth),ft=Ee(ut,e=>e.rowHeight),pt=(Ee(ut,e=>e.contentSize.height),Ee(ut,e=>e.hasScrollX)),ht=Ee(ut,e=>e.hasScrollY),gt=Ee(ut,e=>e.columnsTotalWidth<e.viewportOuterSize.width),mt=Ee(ut,e=>e.headerHeight),At=Ee(ut,e=>e.groupHeaderHeight),bt=(Ee(ut,e=>e.headerFilterHeight),Ee(ut,e=>e.hasScrollX?e.scrollbarSize:0)),vt=Ee(ut,e=>e.hasScrollY?e.scrollbarSize:0),yt=Ee(ut,bt,(e,t)=>{const n=e.viewportOuterSize.height-e.minimumSize.height>0;return!(0===t&&!n)}),wt=ke(e=>e.rows),Ct=Ee(wt,e=>e.totalRowCount),St=Ee(wt,e=>e.loading),xt=Ee(wt,e=>e.totalTopLevelRowCount),Et=Ee(wt,e=>e.dataRowIdToModelLookup),It=(Ee(Et,(e,t)=>e[t]),Ee(wt,e=>e.tree)),kt=Ee(It,(e,t)=>e[t]),Rt=Ee(wt,e=>e.groupsToFetch),Mt=Ee(wt,e=>e.groupingName),Pt=Ee(wt,e=>e.treeDepths),Bt=Ie(wt,e=>{const t=Object.entries(e.treeDepths);return 0===t.length?1:(t.filter(([,e])=>e>0).map(([e])=>Number(e)).sort((e,t)=>t-e)[0]??0)+1}),_t=Ee(wt,e=>e.dataRowIds),Tt=Ie(_t,Et,(e,t)=>e.reduce((e,n)=>t[n]?(e.push(t[n]),e):e,[])),Ot=Ie(Ee(wt,e=>e?.additionalRowGroups),e=>{const t=e?.pinnedRows;return{bottom:t?.bottom?.map(e=>({id:e.id,model:e.model??{}}))??[],top:t?.top?.map(e=>({id:e.id,model:e.model??{}}))??[]}}),Dt=Ee(Ot,e=>(e?.top?.length||0)+(e?.bottom?.length||0));var Nt=n(7341);class Lt{timeouts=(()=>new Map)();cleanupTimeout=1e3;constructor(e=1e3){this.cleanupTimeout=e}register(e,t,n){this.timeouts||(this.timeouts=new Map);const r=setTimeout(()=>{"function"==typeof t&&t(),this.timeouts.delete(n.cleanupToken)},this.cleanupTimeout);this.timeouts.set(n.cleanupToken,r)}unregister(e){const t=this.timeouts.get(e.cleanupToken);t&&(this.timeouts.delete(e.cleanupToken),clearTimeout(t))}reset(){this.timeouts&&(this.timeouts.forEach((e,t)=>{this.unregister({cleanupToken:t})}),this.timeouts=void 0)}}class Ft{registry=(()=>new FinalizationRegistry(e=>{"function"==typeof e&&e()}))();register(e,t,n){this.registry.register(e,t,n)}unregister(e){this.registry.unregister(e)}reset(){}}class Qt{static create(){return new Qt}}const jt={current:"undefined"!=typeof FinalizationRegistry?new Ft:new Lt};let zt=0;function $t(e,t,n,r){const i=o.useState(Qt.create)[0],a=o.useRef(null),l=o.useRef(null);l.current=n;const s=o.useRef(null);if(!a.current&&l.current){const n=(e,t,n)=>{t&&!t.defaultMuiPrevented&&l.current?.(e,t,n)};a.current=e.current.subscribeEvent(t,n,r),zt+=1,s.current={cleanupToken:zt},jt.current.register(i,()=>{a.current?.(),a.current=null,s.current=null},s.current)}else!l.current&&a.current&&(a.current(),a.current=null,s.current&&(jt.current.unregister(s.current),s.current=null));o.useEffect(()=>{if(!a.current&&l.current){const n=(e,t,n)=>{t&&!t.defaultMuiPrevented&&l.current?.(e,t,n)};a.current=e.current.subscribeEvent(t,n,r)}return s.current&&jt.current&&(jt.current.unregister(s.current),s.current=null),()=>{a.current?.(),a.current=null}},[e,t,r])}const Ht={isFirst:!0};function Gt(e,t,n){$t(e,t,n,Ht)}var Vt=n(4281),Wt=n(429),Ut=n(3395);function qt(e){throw new Error("Failed assertion: should not be rendered")}const Yt=["id","value","formattedValue","api","field","row","rowNode","colDef","cellMode","isEditable","tabIndex","hasFocus","isValidating","debounceMs","isProcessingProps","onValueChange","slotProps"],Kt=(0,_.Ay)(qt,{name:"MuiDataGrid",slot:"EditInputCell"})({font:z.typography.font.body,padding:"1px 0","& input":{padding:"0 16px",height:"100%"}}),Jt=S((e,t)=>{const n=se(),{id:i,value:a,field:l,colDef:s,hasFocus:c,debounceMs:u=200,isProcessingProps:d,onValueChange:f,slotProps:p}=e,h=(0,x.A)(e,Yt),g=ot(),m=o.useRef(null),[A,b]=o.useState(a),v=(e=>{const{classes:t}=e;return(0,R.A)({root:["editInputCell"]},D,t)})(n),w=o.useCallback(async e=>{const t=e.target.value,n=g.current.getColumn(l);let r=t;n.valueParser&&(r=n.valueParser(t,g.current.getRow(i),n,g)),b(r),g.current.setEditCellValue({id:i,field:l,value:r,debounceMs:u,unstable_skipValueParser:!0},e),f&&await f(e,t)},[g,u,l,i,f]),C=g.current.unstable_getEditCellMeta(i,l);return o.useEffect(()=>{"debouncedSetEditCellValue"!==C?.changeReason&&b(a)},[C,a]),(0,Ut.A)(()=>{c&&m.current.focus()},[c]),(0,r.jsx)(Kt,(0,y.A)({as:n.slots.baseInput,inputRef:m,className:v.root,ownerState:n,fullWidth:!0,type:"number"===s.type?s.type:"text",value:A??"",onChange:w,endAdornment:d?(0,r.jsx)(n.slots.loadIcon,{fontSize:"small",color:"action"}):void 0},h,p?.root,{ref:t}))}),Xt=(e,t)=>t&&e.length>1?[e[0]]:e,Zt=(e,t)=>n=>(0,y.A)({},n,{sorting:(0,y.A)({},n.sorting,{sortModel:Xt(e,t)})}),en=(e,t)=>{const n=e.indexOf(t);return t&&-1!==n&&n+1!==e.length?e[n+1]:e[0]},tn=(e,t)=>null==e&&null!=t?-1:null==t&&null!=e?1:null==e&&null==t?0:null,nn=new Intl.Collator,rn=(e,t)=>{const n=tn(e,t);return null!==n?n:Number(e)-Number(t)},on=(e,t)=>{const n=tn(e,t);return null!==n?n:e>t?1:e<t?-1:0};var an=n(2415);const ln=["item","applyValue","type","apiRef","focusElementRef","tabIndex","disabled","isFilterActive","slotProps","clearButton","headerFilterMenu"];function sn(e){const{item:t,applyValue:n,type:i,apiRef:a,focusElementRef:l,tabIndex:s,disabled:c,slotProps:u,clearButton:d,headerFilterMenu:f}=e,p=(0,x.A)(e,ln),h=u?.root,g=(0,Vt.A)(),[m,A]=o.useState(cn(t.value)),[b,v]=o.useState(!1),w=(0,an.A)(),C=se(),S=o.useCallback(e=>{const r=cn(e.target.value);A(r),v(!0),g.start(C.filterDebounceMs,()=>{const e=(0,y.A)({},t,{value:"number"!==i||Number.isNaN(Number(r))?r:Number(r),fromInput:w});n(e),v(!1)})},[g,C.filterDebounceMs,t,i,w,n]);return o.useEffect(()=>{t.fromInput===w&&null!=t.value||A(cn(t.value))},[w,t]),(0,r.jsxs)(o.Fragment,{children:[(0,r.jsx)(C.slots.baseTextField,(0,y.A)({id:w,label:a.current.getLocaleText("filterPanelInputLabel"),placeholder:a.current.getLocaleText("filterPanelInputPlaceholder"),value:m??"",onChange:S,type:i||"text",disabled:c,slotProps:(0,y.A)({},h?.slotProps,{input:(0,y.A)({endAdornment:b?(0,r.jsx)(C.slots.loadIcon,{fontSize:"small",color:"action"}):null},h?.slotProps?.input),htmlInput:(0,y.A)({tabIndex:s},h?.slotProps?.htmlInput)}),inputRef:l},C.slotProps?.baseTextField,p,h)),f,d]})}function cn(e){if(null!=e&&""!==e)return String(e)}function un(e){return"object"==typeof e&&null!==e}function dn(e){return e.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")}const fn=(e,t,n)=>Math.max(t,Math.min(n,e));function pn(e){return"function"==typeof structuredClone?structuredClone(e):JSON.parse(JSON.stringify(e))}const hn=(e,t)=>(...n)=>{e&&t(...n)},gn=["item","applyValue","type","apiRef","focusElementRef","slotProps"];function mn(e){const{item:t,applyValue:n,type:i,apiRef:a,focusElementRef:l,slotProps:s}=e,c=(0,x.A)(e,gn),u=(0,an.A)(),[d,f]=o.useState([]),[p,h]=o.useState(t.value||[]),g=se();o.useEffect(()=>{const e=t.value??[];h(e.map(String))},[t.value]);const m=o.useCallback((e,r)=>{h(r.map(String)),n((0,y.A)({},t,{value:[...r.map(e=>"number"===i?Number(e):e)]}))},[n,t,i]),A=o.useCallback((e,t)=>{f(""===t?[]:[t])},[f]),b=g.slots.baseAutocomplete;return(0,r.jsx)(b,(0,y.A)({multiple:!0,freeSolo:!0,options:d,id:u,value:p,onChange:m,onInputChange:A,label:a.current.getLocaleText("filterPanelInputLabel"),placeholder:a.current.getLocaleText("filterPanelInputPlaceholder"),slotProps:{textField:{type:i||"text",inputRef:l}}},c,s?.root))}var An=function(e){return e.And="and",e.Or="or",e}(An||{});const bn={filteredRowsLookup:{},filteredChildrenCountLookup:{},filteredDescendantCountLookup:{}},vn=()=>({items:[],logicOperator:An.And,quickFilterValues:[],quickFilterLogicOperator:An.And});function yn(e){return{current:e.current.getPublicApi()}}let wn;const Cn=(e,t)=>{const n=(0,y.A)({},e);if(null==n.id&&(n.id=Math.round(1e5*Math.random())),null==n.operator){const e=ze(t)[n.field];n.operator=e&&e.filterOperators[0].value}return n},Sn=(e,t,n)=>{const r=e.items.length>1;let o;o=r&&t?[e.items[0]]:e.items;const i=r&&o.some(e=>null==e.id);return o.some(e=>null==e.operator)||i?(0,y.A)({},e,{items:o.map(e=>Cn(e,n))}):e.items!==o?(0,y.A)({},e,{items:o}):e},xn=(e,t,n)=>r=>(0,y.A)({},r,{filterModel:Sn(e,t,n)}),En=e=>"string"==typeof e?e.normalize("NFD").replace(/[\u0300-\u036f]/g,""):e,In=(e,t,n)=>{if(!e.field||!e.operator)return null;const r=n.current.getColumn(e.field);if(!r)return null;let o;if(r.valueParser){const t=r.valueParser;o=Array.isArray(e.value)?e.value?.map(e=>t(e,void 0,r,n)):t(e.value,void 0,r,n)}else o=e.value;const{ignoreDiacritics:i}=n.current.rootProps;i&&(o=En(o));const a=(0,y.A)({},e,{value:o}),l=r.filterOperators;if(!l?.length)throw new Error(`MUI X: No filter operators found for column '${r.field}'.`);const s=l.find(e=>e.value===a.operator);if(!s)throw new Error(`MUI X: No filter operator found for column '${r.field}' and operator value '${a.operator}'.`);const c=yn(n),u=s.getApplyFilterFn(a,r);return"function"!=typeof u?null:{item:a,fn:e=>{let n=t(e,r);return i&&(n=En(n)),u(n,e,r,c)}}};let kn=1;const Rn=e=>e.quickFilterExcludeHiddenColumns??!0,Mn=(e,t,n,r)=>{const o=((e,t,n,r)=>{const{items:o}=e,i=o.map(e=>In(e,t,n)).filter(e=>!!e);if(0===i.length)return null;if(r||!function(){if(void 0!==wn)return wn;try{wn=new Function("return true")()}catch(e){wn=!1}return wn}())return(e,t)=>{const n={};for(let r=0;r<i.length;r+=1){const o=i[r];t&&!t(o.item.field)||(n[o.item.id]=o.fn(e))}return n};const a=new Function("appliers","row","shouldApplyFilter",`"use strict";\n${i.map((e,t)=>`const shouldApply${t} = !shouldApplyFilter || shouldApplyFilter(${JSON.stringify(e.item.field)});`).join("\n")}\n\nconst result$$ = {\n${i.map((e,t)=>` ${JSON.stringify(String(e.item.id))}: !shouldApply${t} ? false : appliers[${t}].fn(row),`).join("\n")}\n};\n\nreturn result$$;`.replaceAll("$$",String(kn)));return kn+=1,(e,t)=>a(i,e,t)})(e,t,n,r),i=((e,t,n)=>{const r=e.quickFilterValues?.filter(Boolean)??[];if(0===r.length)return null;const o=je(n),i=He(n);let a;a=Rn(e)?o.filter(e=>!1!==i[e]):o;const l=[],{ignoreDiacritics:s}=n.current.rootProps,c=yn(n);return a.forEach(e=>{const t=n.current.getColumn(e),o=t?.getApplyQuickFilterFn;o&&l.push({column:t,appliers:r.map(e=>{const n=s?En(e):e;return{fn:o(n,t,c)}})})}),function(e,n){const o={};e:for(let i=0;i<r.length;i+=1){const a=r[i];for(let r=0;r<l.length;r+=1){const{column:u,appliers:d}=l[r],{field:f}=u;if(n&&!n(f))continue;const p=d[i];let h=t(e,u);if(null!==p.fn&&(s&&(h=En(h)),p.fn(h,e,u,c))){o[a]=!0;continue e}}o[a]=!1}return o}})(e,t,n);return function(e,t,n){n.passingFilterItems=o?.(e,t)??null,n.passingQuickFilterValues=i?.(e,t)??null}},Pn=e=>null!=e,Bn=(e,t,n,r,o,i)=>{const a=((e,t,n,r)=>(e.cleanedFilterItems||(e.cleanedFilterItems=r.filter(e=>null!==In(e,t,n))),e.cleanedFilterItems))(i,r,o,n.items),l=e.filter(Pn),s=t.filter(Pn);if(l.length>0){const e=e=>l.some(t=>t[e.id]);if((n.logicOperator??vn().logicOperator)===An.And){if(!a.every(e))return!1}else if(!a.some(e))return!1}if(s.length>0&&null!=n.quickFilterValues){const e=e=>s.some(t=>t[e]);if((n.quickFilterLogicOperator??vn().quickFilterLogicOperator)===An.And){if(!n.quickFilterValues.every(e))return!1}else if(!n.quickFilterValues.some(e))return!1}return!0},_n=(e,t)=>n=>{if(!n.value)return null;const r=e?n.value:n.value.trim(),o=new RegExp(dn(r),"i");return e=>{if(null==e)return t;const n=o.test(String(e));return t?!n:n}},Tn=(e,t)=>n=>{if(!n.value)return null;const r=e?n.value:n.value.trim(),o=new Intl.Collator(void 0,{sensitivity:"base",usage:"search"});return e=>{if(null==e)return t;const n=0===o.compare(r,e.toString());return t?!n:n}},On=e=>()=>t=>{const n=""===t||null==t;return e?!n:n},Dn={width:100,minWidth:50,maxWidth:1/0,hideable:!0,sortable:!0,resizable:!0,filterable:!0,groupable:!0,pinnable:!0,aggregable:!0,chartable:!0,editable:!1,sortComparator:(e,t)=>{const n=tn(e,t);return null!==n?n:"string"==typeof e?nn.compare(e.toString(),t.toString()):e-t},type:"string",align:"left",filterOperators:((e=!1)=>[{value:"contains",getApplyFilterFn:_n(e,!1),InputComponent:sn},{value:"doesNotContain",getApplyFilterFn:_n(e,!0),InputComponent:sn},{value:"equals",getApplyFilterFn:Tn(e,!1),InputComponent:sn},{value:"doesNotEqual",getApplyFilterFn:Tn(e,!0),InputComponent:sn},{value:"startsWith",getApplyFilterFn:t=>{if(!t.value)return null;const n=e?t.value:t.value.trim(),r=new RegExp(`^${dn(n)}.*$`,"i");return e=>null!=e&&r.test(e.toString())},InputComponent:sn},{value:"endsWith",getApplyFilterFn:t=>{if(!t.value)return null;const n=e?t.value:t.value.trim(),r=new RegExp(`.*${dn(n)}$`,"i");return e=>null!=e&&r.test(e.toString())},InputComponent:sn},{value:"isEmpty",getApplyFilterFn:On(!1),requiresFilterValue:!1},{value:"isNotEmpty",getApplyFilterFn:On(!0),requiresFilterValue:!1},{value:"isAnyOf",getApplyFilterFn:t=>{if(!Array.isArray(t.value)||0===t.value.length)return null;const n=e?t.value:t.value.map(e=>e.trim()),r=new Intl.Collator(void 0,{sensitivity:"base",usage:"search"});return e=>null!=e&&n.some(t=>0===r.compare(t,e.toString()||""))},InputComponent:mn}])(),renderEditCell:e=>(0,r.jsx)(Jt,(0,y.A)({},e)),getApplyQuickFilterFn:e=>{if(!e)return null;const t=new RegExp(dn(e),"i");return(e,n,r,o)=>{let i=o.current.getRowFormattedValue(n,r);return o.current.ignoreDiacritics&&(i=En(i)),null!=i&&t.test(i.toString())}}},Nn=e=>null==e?null:Number(e),Ln=(0,y.A)({},Dn,{type:"number",align:"right",headerAlign:"right",sortComparator:rn,valueParser:e=>""===e?null:Number(e),valueFormatter:e=>function(e){return"number"==typeof e&&!Number.isNaN(e)}(e)?e.toLocaleString():e||"",filterOperators:[{value:"=",getApplyFilterFn:e=>null==e.value||Number.isNaN(e.value)?null:t=>Nn(t)===e.value,InputComponent:sn,InputComponentProps:{type:"number"}},{value:"!=",getApplyFilterFn:e=>null==e.value||Number.isNaN(e.value)?null:t=>Nn(t)!==e.value,InputComponent:sn,InputComponentProps:{type:"number"}},{value:">",getApplyFilterFn:e=>null==e.value||Number.isNaN(e.value)?null:t=>null!=t&&Nn(t)>e.value,InputComponent:sn,InputComponentProps:{type:"number"}},{value:">=",getApplyFilterFn:e=>null==e.value||Number.isNaN(e.value)?null:t=>null!=t&&Nn(t)>=e.value,InputComponent:sn,InputComponentProps:{type:"number"}},{value:"<",getApplyFilterFn:e=>null==e.value||Number.isNaN(e.value)?null:t=>null!=t&&Nn(t)<e.value,InputComponent:sn,InputComponentProps:{type:"number"}},{value:"<=",getApplyFilterFn:e=>null==e.value||Number.isNaN(e.value)?null:t=>null!=t&&Nn(t)<=e.value,InputComponent:sn,InputComponentProps:{type:"number"}},{value:"isEmpty",getApplyFilterFn:()=>e=>null==e,requiresFilterValue:!1},{value:"isNotEmpty",getApplyFilterFn:()=>e=>null!=e,requiresFilterValue:!1},{value:"isAnyOf",getApplyFilterFn:e=>Array.isArray(e.value)&&0!==e.value.length?t=>null!=t&&e.value.includes(Number(t)):null,InputComponent:mn,InputComponentProps:{type:"number"}}],getApplyQuickFilterFn:e=>null==e||Number.isNaN(e)||""===e?null:t=>Nn(t)===Nn(e)}),Fn=["item","applyValue","type","apiRef","focusElementRef","slotProps","isFilterActive","headerFilterMenu","clearButton","tabIndex","disabled"];function Qn(e,t){if(null==e)return"";const n=new Date(e);return Number.isNaN(n.getTime())?"":"date"===t?n.toISOString().substring(0,10):"datetime-local"===t?(n.setMinutes(n.getMinutes()-n.getTimezoneOffset()),n.toISOString().substring(0,19)):n.toISOString().substring(0,10)}function jn(e){const{item:t,applyValue:n,type:i,apiRef:a,focusElementRef:l,slotProps:s,headerFilterMenu:c,clearButton:u,tabIndex:d,disabled:f}=e,p=(0,x.A)(e,Fn),h=s?.root.slotProps,g=(0,Vt.A)(),[m,A]=o.useState(()=>Qn(t.value,i)),[b,v]=o.useState(!1),w=(0,an.A)(),C=se(),S=o.useCallback(e=>{g.clear();const r=e.target.value;A(r),v(!0),g.start(C.filterDebounceMs,()=>{const e=new Date(r);n((0,y.A)({},t,{value:Number.isNaN(e.getTime())?void 0:e})),v(!1)})},[n,t,C.filterDebounceMs,g]);return o.useEffect(()=>{const e=Qn(t.value,i);A(e)},[t.value,i]),(0,r.jsxs)(o.Fragment,{children:[(0,r.jsx)(C.slots.baseTextField,(0,y.A)({fullWidth:!0,id:w,label:a.current.getLocaleText("filterPanelInputLabel"),placeholder:a.current.getLocaleText("filterPanelInputPlaceholder"),value:m,onChange:S,type:i||"text",disabled:f,inputRef:l,slotProps:(0,y.A)({},h,{input:(0,y.A)({endAdornment:b?(0,r.jsx)(C.slots.loadIcon,{fontSize:"small",color:"action"}):null},h?.input),htmlInput:(0,y.A)({max:"datetime-local"===i?"9999-12-31T23:59":"9999-12-31",tabIndex:d},h?.htmlInput)})},C.slotProps?.baseTextField,p,s?.root)),c,u]})}function zn(e,t,n,r){if(!e.value)return null;const o=new Date(e.value);n?o.setSeconds(0,0):(o.setMinutes(o.getMinutes()+o.getTimezoneOffset()),o.setHours(0,0,0,0));const i=o.getTime();return e=>{if(!e)return!1;if(r)return t(e.getTime(),i);const o=new Date(e);return n?o.setSeconds(0,0):o.setHours(0,0,0,0),t(o.getTime(),i)}}const $n=e=>[{value:"is",getApplyFilterFn:t=>zn(t,(e,t)=>e===t,e),InputComponent:jn,InputComponentProps:{type:e?"datetime-local":"date"}},{value:"not",getApplyFilterFn:t=>zn(t,(e,t)=>e!==t,e),InputComponent:jn,InputComponentProps:{type:e?"datetime-local":"date"}},{value:"after",getApplyFilterFn:t=>zn(t,(e,t)=>e>t,e,e),InputComponent:jn,InputComponentProps:{type:e?"datetime-local":"date"}},{value:"onOrAfter",getApplyFilterFn:t=>zn(t,(e,t)=>e>=t,e,e),InputComponent:jn,InputComponentProps:{type:e?"datetime-local":"date"}},{value:"before",getApplyFilterFn:t=>zn(t,(e,t)=>e<t,e,!0),InputComponent:jn,InputComponentProps:{type:e?"datetime-local":"date"}},{value:"onOrBefore",getApplyFilterFn:t=>zn(t,(e,t)=>e<=t,e,e),InputComponent:jn,InputComponentProps:{type:e?"datetime-local":"date"}},{value:"isEmpty",getApplyFilterFn:()=>e=>null==e,requiresFilterValue:!1},{value:"isNotEmpty",getApplyFilterFn:()=>e=>null!=e,requiresFilterValue:!1}],Hn=["id","value","formattedValue","api","field","row","rowNode","colDef","cellMode","isEditable","tabIndex","hasFocus","inputProps","isValidating","isProcessingProps","onValueChange","slotProps"],Gn=(0,_.Ay)(qt,{slot:"internal"})({fontSize:"inherit"});function Vn(e){const{id:t,value:n,field:i,colDef:a,hasFocus:l,onValueChange:s,slotProps:c}=e,u=(0,x.A)(e,Hn),d="dateTime"===a.type,f=ot(),p=o.useRef(null),h=o.useMemo(()=>{let e,t;return e=null==n?null:n instanceof Date?n:new Date((n??"").toString()),t=null==e||Number.isNaN(e.getTime())?"":new Date(e.getTime()-60*e.getTimezoneOffset()*1e3).toISOString().substr(0,d?16:10),{parsed:e,formatted:t}},[n,d]),[g,m]=o.useState(h),A=se(),b=(e=>{const{classes:t}=e;return(0,R.A)({root:["editInputCell"]},D,t)})({classes:A.classes}),v=o.useCallback(e=>{if(""===e)return null;const[t,n]=e.split("T"),[r,o,i]=t.split("-"),a=new Date;if(a.setFullYear(Number(r),Number(o)-1,Number(i)),a.setHours(0,0,0,0),n){const[e,t]=n.split(":");a.setHours(Number(e),Number(t),0,0)}return a},[]),w=o.useCallback(async e=>{const n=e.target.value,r=v(n);s&&await s(e,r),m({parsed:r,formatted:n}),f.current.setEditCellValue({id:t,field:i,value:r},e)},[f,i,t,s,v]);return o.useEffect(()=>{m(e=>h.parsed!==e.parsed&&h.parsed?.getTime()!==e.parsed?.getTime()?h:e)},[h]),(0,Ut.A)(()=>{l&&p.current.focus()},[l]),(0,r.jsx)(Gn,(0,y.A)({as:A.slots.baseInput,inputRef:p,fullWidth:!0,className:b.root,type:d?"datetime-local":"date",value:g.formatted,onChange:w},u,c?.root,{slotProps:{htmlInput:(0,y.A)({max:d?"9999-12-31T23:59":"9999-12-31"},c?.root?.slotProps?.htmlInput)}}))}const Wn=e=>(0,r.jsx)(Vn,(0,y.A)({},e)),Un="auto-generated-group-node-root",qn=Symbol("mui.id_autogenerated"),Yn=(e,t,n)=>{const r=t?t(e):e.id;return function(e,t,n="A row was provided without id in the rows prop:"){if(null==e)throw new Error(["MUI X: The Data Grid component requires all rows to have a unique `id` property.","Alternatively, you can use the `getRowId` prop to specify a custom id for each row.",n,JSON.stringify(t)].join("\n"))}(r,e,n),r},Kn=(e,t,n)=>{const r=t.field;if(!t||!t.valueGetter)return e[r];const o=e[t.field];return t.valueGetter(o,e,t,n)},Jn=({rows:e,getRowId:t,loading:n,rowCount:r})=>{const o={type:"full",rows:[]},i={};for(let n=0;n<e.length;n+=1){const r=e[n],a=Yn(r,t);i[a]=r,o.rows.push(a)}return{rowsBeforePartialUpdates:e,loadingPropBeforePartialUpdates:n,rowCountPropBeforePartialUpdates:r,updates:o,dataRowIdToModelLookup:i}},Xn=({tree:e,rowCountProp:t=0})=>{const n=e[Un];return Math.max(t,n.children.length+(null==n.footerId?0:1))},Zn=({apiRef:e,rowCountProp:t=0,loadingProp:n,previousTree:r,previousTreeDepths:o,previousGroupsToFetch:i})=>{const a=e.current.caches.rows,{tree:l,treeDepths:s,dataRowIds:c,groupingName:u,groupsToFetch:d=[]}=e.current.applyStrategyProcessor("rowTreeCreation",{previousTree:r,previousTreeDepths:o,updates:a.updates,dataRowIdToModelLookup:a.dataRowIdToModelLookup,previousGroupsToFetch:i}),f=e.current.unstable_applyPipeProcessors("hydrateRows",{tree:l,treeDepths:s,dataRowIds:c,dataRowIdToModelLookup:a.dataRowIdToModelLookup});return e.current.caches.rows.updates={type:"partial",actions:{insert:[],modify:[],remove:[]},idToActionLookup:{}},(0,y.A)({},f,{totalRowCount:Math.max(t,f.dataRowIds.length),totalTopLevelRowCount:Xn({tree:f.tree,rowCountProp:t}),groupingName:u,loading:n,groupsToFetch:d})},er=e=>qn in e,tr=e=>"skeletonRow"===e.type||"footer"===e.type||"group"===e.type&&e.isAutoGenerated||"pinnedRow"===e.type&&e.isAutoGenerated,nr=(e,t,n,r)=>{const o=e[t];if("group"!==o.type)return[];const i=[];for(let t=0;t<o.children.length;t+=1){const a=o.children[t];if(n&&tr(e[a])||i.push(a),r)continue;const l=nr(e,a,n,r);for(let e=0;e<l.length;e+=1)i.push(l[e])}return n||null==o.footerId||i.push(o.footerId),i},rr=({previousCache:e,getRowId:t,updates:n,groupKeys:r})=>{if("full"===e.updates.type)throw new Error("MUI X: Unable to prepare a partial update if a full update is not applied yet.");const o=new Map;n.forEach(e=>{const n=Yn(e,t,"A row was provided without id when calling updateRows():");o.has(n)?o.set(n,(0,y.A)({},o.get(n),e)):o.set(n,e)});const i={type:"partial",actions:{insert:[...e.updates.actions.insert??[]],modify:[...e.updates.actions.modify??[]],remove:[...e.updates.actions.remove??[]]},idToActionLookup:(0,y.A)({},e.updates.idToActionLookup),groupKeys:r},a=(0,y.A)({},e.dataRowIdToModelLookup),l={insert:{},modify:{},remove:{}};o.forEach((e,t)=>{const n=i.idToActionLookup[t];if("delete"===e._action){if("remove"===n||!a[t])return;return null!=n&&(l[n][t]=!0),i.actions.remove.push(t),void delete a[t]}const r=a[t];if(r)return"remove"===n?(l.remove[t]=!0,i.actions.modify.push(t)):null==n&&i.actions.modify.push(t),void(a[t]=(0,y.A)({},r,e));"remove"===n?(l.remove[t]=!0,i.actions.insert.push(t)):null==n&&i.actions.insert.push(t),a[t]=e});const s=Object.keys(l);for(let e=0;e<s.length;e+=1){const t=s[e],n=l[t];Object.keys(n).length>0&&(i.actions[t]=i.actions[t].filter(e=>!n[e]))}return{dataRowIdToModelLookup:a,updates:i,rowsBeforePartialUpdates:e.rowsBeforePartialUpdates,loadingPropBeforePartialUpdates:e.loadingPropBeforePartialUpdates,rowCountPropBeforePartialUpdates:e.rowCountPropBeforePartialUpdates}},or="var(--DataGrid-overlayHeight, calc(var(--height) * 2))";function ir(e,t,n){const r=[];return t.forEach(t=>{const o=Yn(t,n,"A row was provided without id when calling updateRows():"),i=kt(e,o);if("pinnedRow"===i?.type){const n=e.current.caches.pinnedRows,r=n.idLookup[o];r&&(n.idLookup[o]=(0,y.A)({},r,t))}else r.push(t)}),r}const ar=(e,t,n)=>"number"==typeof e&&e>0?e:t,lr=(["MUI X: The `rowHeight` prop should be a number greater than 0.","The default value will be used instead."].join("\n"),["MUI X: The `getRowHeight` prop should return a number greater than 0 or 'auto'.","The default value will be used instead."].join("\n"),ke((e,t)=>qn in t?t[qn]:e.props.getRowId?e.props.getRowId(t):t.id)),sr=ke(e=>e.props.isRowSelectable);function cr({value:e,columnType:t,rowId:n,field:r}){if(!(e instanceof Date))throw new Error([`MUI X: \`${t}\` column type only accepts \`Date\` objects as values.`,"Use `valueGetter` to transform the value into a `Date` object.",`Row ID: ${n}, field: "${r}".`].join("\n"))}const ur=(0,y.A)({},Dn,{type:"date",sortComparator:on,valueFormatter:(e,t,n,r)=>{if(!e)return"";const o=lr(r,t);return!er(t)||e instanceof Date?(cr({value:e,columnType:"date",rowId:o,field:n.field}),e.toLocaleDateString()):e},filterOperators:$n(),renderEditCell:Wn,pastedValueParser:e=>new Date(e)}),dr=(0,y.A)({},Dn,{type:"dateTime",sortComparator:on,valueFormatter:(e,t,n,r)=>{if(!e)return"";const o=lr(r,t);return!er(t)||e instanceof Date?(cr({value:e,columnType:"dateTime",rowId:o,field:n.field}),e.toLocaleString()):e},filterOperators:$n(!0),renderEditCell:Wn,pastedValueParser:e=>new Date(e)}),fr="__row_group_by_columns_group__",pr="__detail_panel_toggle__";let hr=function(e){return e[e.NONE=0]="NONE",e[e.LEFT=1]="LEFT",e[e.RIGHT=2]="RIGHT",e[e.VIRTUAL=3]="VIRTUAL",e}({});const gr=["formattedValue","colDef","cellMode","row","api","id","value","rowNode","field","hasFocus","tabIndex","isEditable"],mr=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"FooterCell"})({fontWeight:z.typography.fontWeight.medium,color:z.colors.foreground.accent});function Ar(e){const{formattedValue:t}=e,n=(0,x.A)(e,gr),o={classes:se().classes},i=(e=>{const{classes:t}=e;return(0,R.A)({root:["footerCell"]},D,t)})(o);return(0,r.jsx)(mr,(0,y.A)({ownerState:o,className:i.root},n,{children:t}))}const br=o.memo(Ar),vr=["id","value","formattedValue","api","field","row","rowNode","colDef","cellMode","isEditable","hasFocus","tabIndex","hideDescendantCount"];function yr(e){const{value:t,rowNode:n}=e,i=(0,x.A)(e,vr),a=ot(),l=se(),s=(e=>{const{classes:t}=e;return(0,R.A)({root:["booleanCell"]},D,t)})({classes:l.classes}),c=J(a,Bt)>0&&"group"===n.type&&!1===l.treeData,u=o.useMemo(()=>t?l.slots.booleanCellTrueIcon:l.slots.booleanCellFalseIcon,[l.slots.booleanCellFalseIcon,l.slots.booleanCellTrueIcon,t]);return c&&void 0===t?null:(0,r.jsx)(u,(0,y.A)({fontSize:"small",className:s.root,titleAccess:a.current.getLocaleText(t?"booleanCellTrueLabel":"booleanCellFalseLabel"),"data-value":Boolean(t)},i))}const wr=o.memo(yr),Cr=["id","value","formattedValue","api","field","row","rowNode","colDef","cellMode","isEditable","tabIndex","className","hasFocus","isValidating","isProcessingProps","error","onValueChange"];function Sr(e){const{id:t,value:n,field:i,className:a,hasFocus:l,onValueChange:s}=e,c=(0,x.A)(e,Cr),u=ot(),d=o.useRef(null),f=(0,an.A)(),[p,h]=o.useState(n),g=se(),m=(e=>{const{classes:t}=e;return(0,R.A)({root:["editBooleanCell"]},D,t)})({classes:g.classes}),A=o.useCallback(async e=>{const n=e.target.checked;s&&await s(e,n),h(n),await u.current.setEditCellValue({id:t,field:i,value:n},e)},[u,i,t,s]);return o.useEffect(()=>{h(n)},[n]),(0,Ut.A)(()=>{l&&d.current.focus()},[l]),(0,r.jsx)("label",(0,y.A)({htmlFor:f,className:(0,E.A)(m.root,a)},c,{children:(0,r.jsx)(g.slots.baseCheckbox,(0,y.A)({id:f,inputRef:d,checked:Boolean(p),onChange:A,size:"small"},g.slotProps?.baseCheckbox))}))}const xr=["item","applyValue","apiRef","focusElementRef","isFilterActive","headerFilterMenu","clearButton","tabIndex","slotProps"];function Er(e){return"true"===String(e).toLowerCase()||"false"!==String(e).toLowerCase()&&void 0}const Ir=(0,y.A)({},Dn,{type:"boolean",display:"flex",align:"center",headerAlign:"center",renderCell:e=>{if(e.field!==fr&&tr(e.rowNode)){const t=e.aggregation;return t?"footer"===t.position?(0,r.jsx)(br,(0,y.A)({},e)):e.formattedValue:""}return(0,r.jsx)(wr,(0,y.A)({},e))},renderEditCell:e=>(0,r.jsx)(Sr,(0,y.A)({},e)),sortComparator:rn,valueFormatter:(e,t,n,r)=>e?r.current.getLocaleText("booleanCellTrueLabel"):r.current.getLocaleText("booleanCellFalseLabel"),filterOperators:[{value:"is",getApplyFilterFn:e=>{const t=Er(e.value);return void 0===t?null:e=>Boolean(e)===t},InputComponent:function(e){const{item:t,applyValue:n,apiRef:i,focusElementRef:a,headerFilterMenu:l,clearButton:s,tabIndex:c,slotProps:u}=e,d=(0,x.A)(e,xr),[f,p]=o.useState(Er(t.value)),h=se(),g=(0,an.A)(),m=(0,an.A)(),A=h.slotProps?.baseSelect||{},b=A.native??!1,v=h.slotProps?.baseSelectOption||{},w=o.useCallback(e=>{const r=Er(e.target.value);p(r),n((0,y.A)({},t,{value:r}))},[n,t]);o.useEffect(()=>{p(Er(t.value))},[t.value]);const C=u?.root.label??i.current.getLocaleText("filterPanelInputLabel"),S=u?.root.slotProps;return(0,r.jsxs)(o.Fragment,{children:[(0,r.jsxs)(h.slots.baseSelect,(0,y.A)({fullWidth:!0,labelId:g,id:m,label:C,value:void 0===f?"":String(f),onChange:w,native:b,slotProps:{htmlInput:(0,y.A)({ref:a,tabIndex:c},S?.htmlInput)}},A,d,u?.root,{children:[(0,r.jsx)(h.slots.baseSelectOption,(0,y.A)({},v,{native:b,value:"",children:i.current.getLocaleText("filterValueAny")})),(0,r.jsx)(h.slots.baseSelectOption,(0,y.A)({},v,{native:b,value:"true",children:i.current.getLocaleText("filterValueTrue")})),(0,r.jsx)(h.slots.baseSelectOption,(0,y.A)({},v,{native:b,value:"false",children:i.current.getLocaleText("filterValueFalse")}))]})),l,s]})}}],getApplyQuickFilterFn:()=>null,chartable:!1,pastedValueParser:e=>(e=>{switch(e.toLowerCase().trim()){case"true":case"yes":case"1":return!0;case"false":case"no":case"0":case"null":case"undefined":return!1;default:return}})(e)});var kr=function(e){return e.enterKeyDown="enterKeyDown",e.cellDoubleClick="cellDoubleClick",e.printableKeyDown="printableKeyDown",e.deleteKeyDown="deleteKeyDown",e.pasteKeyDown="pasteKeyDown",e}(kr||{}),Rr=function(e){return e.cellFocusOut="cellFocusOut",e.escapeKeyDown="escapeKeyDown",e.enterKeyDown="enterKeyDown",e.tabKeyDown="tabKeyDown",e.shiftTabKeyDown="shiftTabKeyDown",e}(Rr||{}),Mr=function(e){return e.Cell="cell",e.Row="row",e}(Mr||{}),Pr=function(e){return e.Edit="edit",e.View="view",e}(Pr||{}),Br=function(e){return e.Edit="edit",e.View="view",e}(Br||{});function _r(e){return"singleSelect"===e?.type}function Tr(e,t){if(e)return"function"==typeof e.valueOptions?e.valueOptions((0,y.A)({field:e.field},t)):e.valueOptions}function Or(e,t,n){if(void 0===t)return;const r=t.find(t=>{const r=n(t);return String(r)===String(e)});return n(r)}const Dr=["id","value","formattedValue","api","field","row","rowNode","colDef","cellMode","isEditable","tabIndex","className","hasFocus","isValidating","isProcessingProps","error","onValueChange","initialOpen","slotProps"];function Nr(e){const t=se(),{id:n,value:i,field:a,row:l,colDef:s,hasFocus:c,error:u,onValueChange:d,initialOpen:f=t.editMode===Mr.Cell,slotProps:p}=e,h=(0,x.A)(e,Dr),g=ot(),m=o.useRef(null),A=o.useRef(null),[b,v]=o.useState(f),w=(t.slotProps?.baseSelect||{}).native??!1;if((0,Ut.A)(()=>{c&&A.current?.focus()},[c]),!_r(s))return null;const C=Tr(s,{id:n,row:l});if(!C)return null;const S=s.getOptionValue,E=s.getOptionLabel;return C&&s?(0,r.jsx)(t.slots.baseSelect,(0,y.A)({ref:m,value:i,onChange:async e=>{if(!_r(s)||!C)return;v(!1);const t=Or(e.target.value,C,S);d&&await d(e,t),await g.current.setEditCellValue({id:n,field:a,value:t},e)},open:b,onOpen:e=>{(function(e){return"key"in e&&!!e.key})(e)&&"Enter"===e.key||v(!0)},onClose:(e,r)=>{if(t.editMode!==Mr.Row){if("backdropClick"===r||"Escape"===e.key){const t=g.current.getCellParams(n,a);g.current.publishEvent("cellEditStop",(0,y.A)({},t,{reason:"Escape"===e.key?Rr.escapeKeyDown:Rr.cellFocusOut}))}}else v(!1)},error:u,native:w,fullWidth:!0,slotProps:{htmlInput:{ref:A}}},h,p?.root,t.slotProps?.baseSelect,{children:C.map(e=>{const n=S(e);return(0,o.createElement)(t.slots.baseSelectOption,(0,y.A)({},t.slotProps?.baseSelectOption||{},{native:w,key:n,value:n}),E(e))})})):null}const Lr=["item","applyValue","type","apiRef","focusElementRef","tabIndex","isFilterActive","clearButton","headerFilterMenu","slotProps"],Fr=({column:e,OptionComponent:t,getOptionLabel:n,getOptionValue:r,isSelectNative:i,baseSelectOptionProps:a})=>["",...Tr(e)||[]].map(e=>{const l=r(e);let s=n(e);return""===s&&(s=" "),(0,o.createElement)(t,(0,y.A)({},a,{native:i,key:l,value:l}),s)});function Qr(e){const{item:t,applyValue:n,type:i,apiRef:a,focusElementRef:l,tabIndex:s,clearButton:c,headerFilterMenu:u,slotProps:d}=e,f=(0,x.A)(e,Lr),p=t.value??"",h=(0,an.A)(),g=(0,an.A)(),m=se(),A=m.slotProps?.baseSelect?.native??!1,b=a.current.getColumn(t.field),v=b.getOptionValue,w=b.getOptionLabel,C=o.useMemo(()=>Tr(b),[b]),S=o.useCallback(e=>{let r=e.target.value;r=Or(r,C,v),n((0,y.A)({},t,{value:r}))},[C,v,n,t]);if(!b||!_r(b))return null;const E=d?.root.label??a.current.getLocaleText("filterPanelInputLabel");return(0,r.jsxs)(o.Fragment,{children:[(0,r.jsx)(m.slots.baseSelect,(0,y.A)({fullWidth:!0,id:h,label:E,labelId:g,value:p,onChange:S,slotProps:{htmlInput:(0,y.A)({tabIndex:s,ref:l,type:i||"text",placeholder:d?.root.placeholder??a.current.getLocaleText("filterPanelInputPlaceholder")},d?.root.slotProps?.htmlInput)},native:A},m.slotProps?.baseSelect,f,d?.root,{children:Fr({column:b,OptionComponent:m.slots.baseSelectOption,getOptionLabel:w,getOptionValue:v,isSelectNative:A,baseSelectOptionProps:m.slotProps?.baseSelectOption})})),u,c]})}const jr=["item","applyValue","type","apiRef","focusElementRef","slotProps"];const zr=e=>null!=e&&un(e)?e.value:e,$r=(0,y.A)({},Dn,{type:"singleSelect",getOptionLabel:e=>un(e)?e.label:String(e),getOptionValue:e=>un(e)?e.value:e,valueFormatter(e,t,n,r){const o=lr(r,t);if(!_r(n))return"";const i=Tr(n,{id:o,row:t});if(null==e)return"";if(!i)return e;if(!(e=>"object"==typeof e[0])(i))return n.getOptionLabel(e);const a=i.find(t=>n.getOptionValue(t)===e);return a?n.getOptionLabel(a):""},renderEditCell:e=>(0,r.jsx)(Nr,(0,y.A)({},e)),filterOperators:[{value:"is",getApplyFilterFn:e=>null==e.value||""===e.value?null:t=>zr(t)===zr(e.value),InputComponent:Qr},{value:"not",getApplyFilterFn:e=>null==e.value||""===e.value?null:t=>zr(t)!==zr(e.value),InputComponent:Qr},{value:"isAnyOf",getApplyFilterFn:e=>{if(!Array.isArray(e.value)||0===e.value.length)return null;const t=e.value.map(zr);return e=>t.includes(zr(e))},InputComponent:function(e){const{item:t,applyValue:n,type:i,apiRef:a,focusElementRef:l,slotProps:s}=e,c=(0,x.A)(e,jr),u=(0,an.A)(),d=se(),f=a.current.getColumn(t.field),p=f.getOptionValue,h=f.getOptionLabel,g=o.useCallback((e,t)=>p(e)===p(t),[p]),m=o.useMemo(()=>Tr(f)||[],[f]),A=o.useMemo(()=>Array.isArray(t.value)?t.value.reduce((e,t)=>{const n=m.find(e=>p(e)===t);return null!=n&&e.push(n),e},[]):[],[p,t.value,m]),b=o.useCallback((e,r)=>{n((0,y.A)({},t,{value:r.map(p)}))},[n,t,p]);if(!f||!_r(f))return null;const v=d.slots.baseAutocomplete;return(0,r.jsx)(v,(0,y.A)({multiple:!0,options:m,isOptionEqualToValue:g,id:u,value:A,onChange:b,getOptionLabel:h,label:a.current.getLocaleText("filterPanelInputLabel"),placeholder:a.current.getLocaleText("filterPanelInputPlaceholder"),slotProps:{textField:{type:i||"text",inputRef:l}}},c,s?.root))}}],pastedValueParser:(e,t,n)=>{const r=n,o=Tr(r)||[],i=r.getOptionValue;if(o.find(t=>i(t)===e))return e}});var Hr=n(3776);function Gr(e){return 1===e.key.length&&!e.ctrlKey&&!e.metaKey}const Vr=e=>0===e.indexOf("Arrow")||0===e.indexOf("Page")||" "===e||"Home"===e||"End"===e,Wr=e=>"Tab"===e||"Escape"===e;function Ur(e){return(e.ctrlKey||e.metaKey)&&"V"===String.fromCharCode(e.keyCode)&&!e.shiftKey&&!e.altKey}const qr=["open","target","onClose","children","position","className","onExited"],Yr=(0,_.Ay)(qt,{name:"MuiDataGrid",slot:"Menu"})({zIndex:z.zIndex.menu,[`& .${L.menuList}`]:{outline:0}});function Kr(e){const{open:t,target:n,onClose:i,children:a,position:l,className:s,onExited:c}=e,u=(0,x.A)(e,qr),d=ot(),f=se(),p=(e=>{const{classes:t}=e;return(0,R.A)({root:["menu"]},D,t)})(f),h=fe(),g=o.useRef(null);return(0,Ut.A)(()=>{t?g.current=document.activeElement instanceof HTMLElement?document.activeElement:null:(g.current?.focus?.(),g.current=null)},[t]),o.useEffect(()=>{const e=t?"menuOpen":"menuClose";d.current.publishEvent(e,{target:n})},[d,t,n]),(0,r.jsx)(Yr,(0,y.A)({as:f.slots.basePopper,className:(0,E.A)(p.root,s,h),ownerState:f,open:t,target:n,transition:!0,placement:l,onClickAway:e=>{e.target&&(n===e.target||n?.contains(e.target))||i(e)},onExited:c,clickAwayMouseEvent:"onMouseDown",onKeyDown:e=>{Wr(e.key)&&i(e)}},u,f.slotProps?.basePopper,{children:a}))}const Jr=["label","icon","showInMenu","onClick"],Xr=["label","icon","showInMenu","onClick","closeMenuOnClick","closeMenu"],Zr=S((e,t)=>{const n=se();if(!e.showInMenu){const{label:i,icon:a,onClick:l}=e,s=(0,x.A)(e,Jr),c=e=>{l?.(e)};return(0,r.jsx)(n.slots.baseIconButton,(0,y.A)({size:"small",role:"menuitem","aria-label":i},s,{onClick:c},n.slotProps?.baseIconButton,{ref:t,children:o.cloneElement(a,{fontSize:"small"})}))}const{label:i,icon:a,onClick:l,closeMenuOnClick:s=!0,closeMenu:c}=e,u=(0,x.A)(e,Xr);return(0,r.jsx)(n.slots.baseMenuItem,(0,y.A)({ref:t},u,{onClick:e=>{l?.(e),s&&c?.()},iconStart:a,children:i}))}),eo=["api","colDef","id","hasFocus","isEditable","field","value","formattedValue","row","rowNode","cellMode","tabIndex","position","onMenuOpen","onMenuClose","children","suppressChildrenValidation"];function to(e){const{id:t,hasFocus:n,tabIndex:i,position:a="bottom-end",onMenuOpen:l,onMenuClose:s,children:c,suppressChildrenValidation:u}=e,d=(0,x.A)(e,eo),[f,p]=o.useState(-1),[h,g]=o.useState(!1),m=ot(),A=o.useRef(null),b=o.useRef(null),v=o.useRef(!1),w=o.useRef({}),C=(0,Hr.I)(),S=(0,an.A)(),E=(0,an.A)(),I=se(),k=m.current.getRowParams(t),R=[];o.Children.forEach(c,e=>{o.isValidElement(e)&&(e.type===o.Fragment?o.Children.forEach(e.props.children,e=>{o.isValidElement(e)&&R.push(e)}):e.type===Zr||u?R.push(e):"function"==typeof e.type?e.type.name:e.type)});const M=R.filter(e=>!e.props.showInMenu),P=R.filter(e=>e.props.showInMenu),B=M.length+(P.length?1:0);o.useLayoutEffect(()=>{n||Object.entries(w.current).forEach(([e,t])=>{t?.stop({},()=>{delete w.current[e]})})},[n]),o.useEffect(()=>{f<0||!A.current||f>=A.current.children.length||A.current.children[f].focus({preventScroll:!0})},[f]);const _=R.findIndex(e=>!e.props.disabled);o.useEffect(()=>{n&&-1===f&&p(_),n||(p(-1),v.current=!1)},[n,f,_]),o.useEffect(()=>{f>=B&&p(B-1)},[f,B]);const T=e=>{s&&!s(k,e)||g(!1)},O=e=>t=>{w.current[e]=t},D=(e,t)=>n=>{p(e),v.current=!0,t&&t(n)},N=B>0?{role:"menu",onKeyDown:e=>{if(B<=1)return;const t=(e,n)=>{if(e<0||e>R.length)return e;const r=("left"===n?-1:1)*(C?-1:1);return R[e+r]?.props.disabled?t(e+r,n):e+r};let n=f;"ArrowRight"===e.key?n=t(f,"right"):"ArrowLeft"===e.key&&(n=t(f,"left")),n<0||n>=B||n!==f&&(e.preventDefault(),e.stopPropagation(),p(n))}}:void 0;return(0,r.jsxs)("div",(0,y.A)({ref:A,tabIndex:-1,className:L.actionsCell},N,d,{children:[M.map((e,t)=>o.cloneElement(e,{key:t,touchRippleRef:O(t),onClick:D(t,e.props.onClick),tabIndex:f===t?i:-1})),P.length>0&&E&&(0,r.jsx)(I.slots.baseIconButton,(0,y.A)({ref:b,id:E,"aria-label":m.current.getLocaleText("actionsCellMore"),"aria-haspopup":"menu","aria-expanded":h,"aria-controls":h?S:void 0,role:"menuitem",size:"small",onClick:e=>{e.stopPropagation(),e.preventDefault(),h?T(e):(e=>{l&&!l(k,e)||(g(!0),p(B-1),v.current=!0)})(e)},touchRippleRef:O(E),tabIndex:f===M.length?i:-1},I.slotProps?.baseIconButton,{children:(0,r.jsx)(I.slots.moreActionsIcon,{fontSize:"small"})})),P.length>0&&(0,r.jsx)(Kr,{open:h,target:b.current,position:a,onClose:T,children:(0,r.jsx)(I.slots.baseMenuList,{id:S,className:L.menuList,"aria-labelledby":E,autoFocusItem:!0,children:P.map((e,t)=>o.cloneElement(e,{key:t,closeMenu:T}))})})]}))}function no(e){const{colDef:t,id:n}=e,o=ot();if(!(e=>"function"==typeof e.getActions)(t))throw new Error("MUI X: Missing the `getActions` property in the `GridColDef`.");const i=t.getActions(o.current.getRowParams(n));return(0,r.jsx)(to,(0,y.A)({suppressChildrenValidation:!0},e,{children:i}))}const ro="actions",oo=(0,y.A)({},Dn,{sortable:!1,filterable:!1,aggregable:!1,chartable:!1,width:100,display:"flex",align:"center",headerAlign:"center",headerName:"",disableColumnMenu:!0,disableExport:!0,renderCell:e=>(0,r.jsx)(no,(0,y.A)({},e)),getApplyQuickFilterFn:()=>null}),io=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"LongTextCell"})({display:"flex",alignItems:"center",width:"100%",height:"100%",position:"relative"}),ao=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"LongTextCellContent"})({overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",flex:1}),lo=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"LongTextCellPopperContent"})(({theme:e})=>(0,y.A)({},e.typography.body2,{letterSpacing:"normal",paddingBlock:15.5,paddingInline:9,maxHeight:156,overflow:"auto",whiteSpace:"pre-wrap",wordBreak:"break-word",width:"var(--_width)",border:`1px solid ${(e.vars||e).palette.divider}`,boxSizing:"border-box"})),so=(0,_.Ay)("button",{name:"MuiDataGrid",slot:"LongTextCellCornerButton"})(({theme:e})=>({lineHeight:0,position:"absolute",bottom:1,right:0,border:"1px solid",color:(e.vars||e).palette.text.secondary,borderColor:(e.vars||e).palette.divider,backgroundColor:(e.vars||e).palette.background.paper,borderRadius:0,fontSize:"0.875rem",padding:2,"&:focus-visible":{outline:"none"},"&:hover":{backgroundColor:(e.vars||e).palette.background.paper,color:(e.vars||e).palette.text.primary},[`&.${L.longTextCellExpandButton}`]:{right:-9,opacity:0,[`.${L.longTextCell}:hover &, .${L.longTextCell}.Mui-focused &`]:{opacity:1}},[`&.${L.longTextCellCollapseButton}`]:{bottom:2,right:2,border:"none"}})),co=(0,_.Ay)(qt,{name:"MuiDataGrid",slot:"LongTextCellPopper"})(({theme:e})=>({zIndex:z.zIndex.menu,background:(e.vars||e).palette.background.paper,"&[data-popper-reference-hidden]":{visibility:"hidden",pointerEvents:"none"}}));function uo(e){const{id:t,value:n="",colDef:i,hasFocus:a,slotProps:l,renderContent:s}=e,c=`${t}-${i.field}-longtext-popup`,u=se(),d=ot(),f=(e=>{const{classes:t}=e;return(0,R.A)({root:["longTextCell"],content:["longTextCellContent"],expandButton:["longTextCellExpandButton"],collapseButton:["longTextCellCollapseButton"],popup:["longTextCellPopup"],popperContent:["longTextCellPopperContent"]},D,t)})(u),p=J(d,ft),[h,g]=o.useState(!1),m=o.useRef(null),A=o.useRef(null);return o.useEffect(()=>{a&&!h&&A.current&&A.current!==document.activeElement&&A.current.focus(),a||g(!1)},[a,h]),(0,r.jsxs)(io,(0,y.A)({ref:m},l?.root,{className:(0,E.A)(f.root,l?.root?.className,a&&"Mui-focused"),children:[(0,r.jsx)(ao,(0,y.A)({},l?.content,{className:(0,E.A)(f.content,l?.content?.className),children:n})),(0,r.jsx)(so,(0,y.A)({ref:A,"aria-label":`${n}, ${d.current.getLocaleText("longTextCellExpandLabel")}`,"aria-haspopup":"dialog","aria-controls":h?c:void 0,"aria-expanded":h,"aria-keyshortcuts":"Space",tabIndex:0},l?.expandButton,{className:(0,E.A)(f.expandButton,l?.expandButton?.className),onClick:e=>{0!==e.detail&&(e.stopPropagation(),g(!0))},onKeyDown:e=>{" "!==e.key||e.shiftKey||(e.preventDefault(),e.stopPropagation(),g(e=>!e)),"Escape"===e.key&&h&&(e.stopPropagation(),g(!1))},children:(0,r.jsx)(u.slots.longTextCellExpandIcon,{fontSize:"inherit"})})),(0,r.jsx)(co,(0,y.A)({id:c,role:"dialog","aria-label":i.headerName||i.field,as:u.slots.basePopper,ownerState:u,open:h,target:m.current,placement:"bottom-start",onClickAway:()=>{g(!1)},clickAwayMouseEvent:"onMouseDown",flip:!0,material:{container:m.current?.closest('[role="row"]'),modifiers:[{name:"offset",options:{offset:[-10,-p]}}]}},l?.popper,{className:(0,E.A)(f.popup,l?.popper?.className),children:(0,r.jsxs)(lo,(0,y.A)({tabIndex:-1,onKeyDown:e=>{"Escape"===e.key&&(e.stopPropagation(),g(!1),d.current.getCellElement(t,i.field)?.focus())}},l?.popperContent,{className:(0,E.A)(f.popperContent,l?.popperContent?.className),style:(0,y.A)({"--_width":`${i.computedWidth}px`},l?.popperContent?.style),children:[s?s(n):n,(0,r.jsx)(so,(0,y.A)({"aria-label":d.current.getLocaleText("longTextCellCollapseLabel"),"aria-keyshortcuts":"Escape"},l?.collapseButton,{className:(0,E.A)(f.collapseButton,l?.collapseButton?.className),onClick:e=>{e.stopPropagation(),g(!1),d.current.getCellElement(t,i.field)?.focus()},children:(0,r.jsx)(u.slots.longTextCellCollapseIcon,{fontSize:"inherit"})}))]}))}))]}))}const fo=e=>{const{classes:t}=e;return(0,R.A)({root:["editLongTextCell"],value:["editLongTextCellValue"],popup:["editLongTextCellPopup"],popperContent:["editLongTextCellPopperContent"],textarea:["editLongTextCellTextarea"]},D,t)},po=(0,_.Ay)(qt,{name:"MuiDataGrid",slot:"EditLongTextCellTextarea"})(({theme:e})=>(0,y.A)({width:"100%",padding:0},e.typography.body2,{letterSpacing:"normal",outline:"none",background:"transparent",border:"none",resize:"vertical"})),ho=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"EditLongTextCell"})({display:"flex",alignItems:"center",width:"100%",height:"100%",position:"relative"}),go=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"EditLongTextCellValue"})({overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",width:"100%",paddingInline:10}),mo=(0,_.Ay)(qt,{name:"MuiDataGrid",slot:"EditLongTextCellPopper"})(({theme:e})=>({zIndex:z.zIndex.menu,background:(e.vars||e).palette.background.paper,"&[data-popper-reference-hidden]":{opacity:0}})),Ao=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"EditLongTextCellPopperContent"})(({theme:e})=>(0,y.A)({},e.typography.body2,{letterSpacing:"normal",paddingBlock:15.5,paddingInline:9,height:"max-content",overflow:"auto",whiteSpace:"pre-wrap",wordBreak:"break-word",width:"var(--_width)",border:`1px solid ${(e.vars||e).palette.divider}`,boxShadow:(e.vars||e).shadows[4],boxSizing:"border-box"}));function bo(e){const{id:t,value:n,field:i,colDef:a,hasFocus:l,cellMode:s,slotProps:c}=e,u=se(),d=ot(),f=fo(u),p=J(d,ft),[h,g]=o.useState(n),[m,A]=o.useState(null),b=d.current.unstable_getEditCellMeta(t,i),v=`${t}-${i}-longtext-edit-popup`,w=l&&Boolean(m);return o.useEffect(()=>{"debouncedSetEditCellValue"!==b?.changeReason&&g(n)},[b,n]),(0,r.jsxs)(ho,(0,y.A)({tabIndex:"edit"===s&&"row"===u.editMode?0:void 0,ref:A,"aria-controls":w?v:void 0,"aria-expanded":w},c?.root,{className:(0,E.A)(f.root,c?.root?.className),children:[(0,r.jsx)(go,(0,y.A)({},c?.value,{className:(0,E.A)(f.value,c?.value?.className),children:h})),(0,r.jsx)(mo,(0,y.A)({as:u.slots.basePopper,ownerState:u,id:v,role:"dialog","aria-label":a.headerName||i,open:w,target:m,placement:"bottom-start",flip:!0,material:{container:m?.closest('[role="row"]'),modifiers:[{name:"offset",options:{offset:[-1,-p]}}]}},c?.popper,{className:(0,E.A)(f.popup,c?.popper?.className),children:(0,r.jsx)(Ao,(0,y.A)({},c?.popperContent,{className:(0,E.A)(f.popperContent,c?.popperContent?.className),style:{"--_width":`${a.computedWidth}px`},children:(0,r.jsx)(vo,(0,y.A)({},e,{valueState:h,setValueState:g}))}))}))]}))}function vo(e){const{id:t,field:n,colDef:i,debounceMs:a=200,onValueChange:l,valueState:s,setValueState:c,hasFocus:u,slotProps:d}=e,f=o.useRef(null),p=ot(),h=se(),g=fo(h);(0,Ut.A)(()=>{if(u&&f.current){f.current.focus({preventScroll:!0});const e=f.current.value.length;f.current.setSelectionRange(e,e)}},[u]);const m=o.useCallback(async e=>{const r=e.target.value,o=p.current.getColumn(n);let i=r;o.valueParser&&(i=o.valueParser(r,p.current.getRow(t),o,p)),c(i),p.current.setEditCellValue({id:t,field:n,value:i,debounceMs:a,unstable_skipValueParser:!0},e),l&&await l(e,r)},[p,a,n,t,l,c]),A=o.useCallback(e=>{"Enter"===e.key&&e.shiftKey&&e.stopPropagation(),"cell"===h.editMode&&"Escape"===e.key&&p.current.stopCellEditMode({id:t,field:n,ignoreModifications:!0})},[p,n,t,h.editMode]);return(0,r.jsx)(po,(0,y.A)({ref:f,as:h.slots.baseTextarea,ownerState:h,"aria-label":i.headerName||n,value:s??"",onChange:m,onKeyDown:A},d?.textarea,{className:(0,E.A)(g.textarea,d?.textarea?.className)}))}const yo=(0,y.A)({},Dn,{type:"longText",display:"flex",renderCell:e=>(0,r.jsx)(uo,(0,y.A)({},e)),renderEditCell:e=>(0,r.jsx)(bo,(0,y.A)({},e))}),wo=ke(e=>e.headerFiltering),Co=Ee(wo,e=>e?.enabled??!1),So=Ee(wo,e=>e.editing),xo=Ee(wo,e=>e.menuOpen),Eo=ke(e=>e.columnGrouping),Io=Ie(Eo,e=>e?.unwrappedGroupingModel??{}),ko=Ie(Eo,e=>e?.lookup??{}),Ro=Ie(Eo,e=>e?.headerStructure??[]),Mo=Ee(Eo,e=>e?.maxDepth??0),Po=["maxWidth","minWidth","width","flex"],Bo={string:Dn,number:Ln,date:ur,dateTime:dr,boolean:Ir,singleSelect:$r,[ro]:oo,custom:Dn,longText:yo},_o=(e,t)=>{const n={};let r=0,o=0;const i=[];e.orderedFields.forEach(t=>{let a=e.lookup[t],l=0,s=!1;!1!==e.columnVisibilityModel[t]&&(a.flex&&a.flex>0?(r+=a.flex,s=!0):l=fn(a.width||Dn.width,a.minWidth||Dn.minWidth,a.maxWidth||Dn.maxWidth),o+=l),a.computedWidth!==l&&(a=(0,y.A)({},a,{computedWidth:l})),s&&i.push(a),n[t]=a});const a=void 0===t?0:t.viewportOuterSize.width-(t.hasScrollY?t.scrollbarSize:0),l=Math.max(a-o,0);if(r>0&&a>0){const e=function({initialFreeSpace:e,totalFlexUnits:t,flexColumns:n}){const r=new Set(n.map(e=>e.field)),o={all:{},frozenFields:[],freeze:e=>{const t=o.all[e];t&&!0!==t.frozen&&(o.all[e].frozen=!0,o.frozenFields.push(e))}};return function i(){if(o.frozenFields.length===r.size)return;const a={min:{},max:{}};let l=e,s=t,c=0;o.frozenFields.forEach(e=>{l-=o.all[e].computedWidth,s-=o.all[e].flex});for(let e=0;e<n.length;e+=1){const t=n[e];if(o.all[t.field]&&!0===o.all[t.field].frozen)continue;let r=l/s*t.flex;r<t.minWidth?(c+=t.minWidth-r,r=t.minWidth,a.min[t.field]=!0):r>t.maxWidth&&(c+=t.maxWidth-r,r=t.maxWidth,a.max[t.field]=!0),o.all[t.field]={frozen:!1,computedWidth:r,flex:t.flex}}c<0?Object.keys(a.max).forEach(e=>{o.freeze(e)}):c>0?Object.keys(a.min).forEach(e=>{o.freeze(e)}):n.forEach(({field:e})=>{o.freeze(e)}),i()}(),o.all}({initialFreeSpace:l,totalFlexUnits:r,flexColumns:i});Object.keys(e).forEach(t=>{n[t]=(0,y.A)({},n[t],{computedWidth:e[t].computedWidth})})}return(0,y.A)({},e,{lookup:n})};function To(e){let t=Bo.string;return e&&Bo[e]&&(t=Bo[e]),t}const Oo=({apiRef:e,columnsToUpsert:t,initialState:n,columnVisibilityModel:r=He(e),keepOnlyColumnsToUpsert:o=!1,updateInitialVisibilityModel:i=!1})=>{const a=!e.current.state.columns;let l;if(a)l={orderedFields:[],lookup:{},columnVisibilityModel:r,initialColumnVisibilityModel:r};else{const t=Qe(e);l={orderedFields:o?[]:[...t.orderedFields],lookup:o?{}:(0,y.A)({},t.lookup),columnVisibilityModel:r,initialColumnVisibilityModel:i?r:t.initialColumnVisibilityModel}}const s={};if(o&&!a)for(const e in l.lookup)Object.prototype.hasOwnProperty.call(l.lookup,e)&&(s[e]=!1);t.forEach(e=>{const{field:t}=e;s[t]=!0;let n=l.lookup[t];null==n?(n=(0,y.A)({},To(e.type),{field:t,hasBeenResized:!1}),l.orderedFields.push(t)):o&&l.orderedFields.push(t),n&&n.type!==e.type&&(n=(0,y.A)({},To(e.type),{field:t}));let r=n.hasBeenResized;Po.forEach(t=>{void 0!==e[t]&&(r=!0,-1===e[t]&&(e[t]=1/0))});const i=(0,y.A)({},To(e.type),{hasBeenResized:r,field:t});let a;for(a in e)void 0!==e[a]&&"field"!==a&&(i[a]=e[a]);l.lookup[t]=(0,Wt.A)(n,i)}),o&&!a&&Object.keys(l.lookup).forEach(e=>{s[e]||delete l.lookup[e]});const c=((e,t)=>{if(!t)return e;const{orderedFields:n=[],dimensions:r={}}=t,o=Object.keys(r);if(0===o.length&&0===n.length)return e;const i={},a=[];for(let t=0;t<n.length;t+=1){const r=n[t];e.lookup[r]&&(i[r]=!0,a.push(r))}const l=0===a.length?e.orderedFields:[...a,...e.orderedFields.filter(e=>!i[e])],s=(0,y.A)({},e.lookup);for(let e=0;e<o.length;e+=1){const t=o[e],n=(0,y.A)({},s[t],{hasBeenResized:!0});Object.entries(r[t]).forEach(([e,t])=>{n[e]=-1===t?1/0:t}),s[t]=n}return(0,y.A)({},e,{orderedFields:l,lookup:s})})(e.current.unstable_applyPipeProcessors("hydrateColumns",l),n);return _o(c,e.current.getRootDimensions?.()??void 0)};function Do(e,t){if(t.listView)return 0;const n=Be(e),r=Mo(e),o=Co(e);return Math.floor(t.columnHeaderHeight*n)+Math.floor((t.columnGroupHeaderHeight??t.columnHeaderHeight)*n)*r+(o?Math.floor((t.headerFilterHeight??t.columnHeaderHeight)*n):0)}const No=ke(e=>e.rowsMeta),Lo=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"ScrollArea",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.scrollArea,t[`scrollArea--${n.scrollDirection}`]]}})(()=>({position:"absolute",zIndex:101,[`&.${L["scrollArea--left"]}`]:{top:0,left:0,width:20,bottom:0},[`&.${L["scrollArea--right"]}`]:{top:0,right:0,width:20,bottom:0},[`&.${L["scrollArea--up"]}`]:{top:0,left:0,right:0,height:20},[`&.${L["scrollArea--down"]}`]:{bottom:0,left:0,right:0,height:20}})),Fo=Ee(ut,(e,t)=>"left"===t?e.leftPinnedWidth:"right"===t?e.rightPinnedWidth+(e.hasScrollX?e.scrollbarSize:0):0);function Qo(e){const{scrollDirection:t,scrollPosition:n}=e,i=o.useRef(null),a=ot(),l=(0,Vt.A)(),s=J(a,Be),c=J(a,dt),u=J(a,Fo,t),d=se(),f=Do(a,d),p=Math.floor(d.columnHeaderHeight*s),h=(0,y.A)({height:p,top:f-p},"left"===t?{left:u}:{},"right"===t?{right:u}:{}),g=(0,Nt.A)(e=>{let r;if(e.preventDefault(),"left"===t)r=e.clientX-i.current.getBoundingClientRect().right;else{if("right"!==t)throw new Error("MUI X: Wrong drag direction");r=Math.max(1,e.clientX-i.current.getBoundingClientRect().left)}r=1.5*(r-1)+1,l.start(0,()=>{a.current.scroll({left:n.current.left+r,top:n.current.top})})});return(0,r.jsx)(zo,(0,y.A)({},e,{ref:i,getCanScrollMore:()=>{const e=ut(a);if("left"===t)return n.current.left>0;if("right"===t){const t=c-e.viewportInnerSize.width;return n.current.left<t}return!1},style:h,handleDragOver:g}))}function jo(e){const{scrollDirection:t,scrollPosition:n}=e,i=o.useRef(null),a=ot(),l=(0,Vt.A)(),s=J(a,No),c=se(),u=Do(a,c),d={top:"up"===t?u:void 0,bottom:"down"===t?0:void 0},f=(0,Nt.A)(e=>{let r;if(e.preventDefault(),"up"===t)r=e.clientY-i.current.getBoundingClientRect().bottom;else{if("down"!==t)throw new Error("MUI X: Wrong drag direction");r=Math.max(1,e.clientY-i.current.getBoundingClientRect().top)}r=1.5*(r-1)+1,l.start(0,()=>{a.current.scroll({left:n.current.left,top:n.current.top+r})})});return(0,r.jsx)(zo,(0,y.A)({},e,{ref:i,getCanScrollMore:()=>{const e=ut(a);if("up"===t)return n.current.top>0;if("down"===t){const t=(s.currentPageTotalHeight||0)-e.viewportInnerSize.height-(e.hasScrollX?e.scrollbarSize:0);return n.current.top<t}return!1},style:d,handleDragOver:f}))}const zo=S(function(e,t){const{scrollDirection:n,getCanScrollMore:i,style:a,handleDragOver:l}=e,s=ot(),[c,u]=o.useState(i),d=se(),f=(0,y.A)({},d,{scrollDirection:n}),p=(e=>{const{scrollDirection:t,classes:n}=e,r={root:["scrollArea",`scrollArea--${t}`]};return(0,R.A)(r,D,n)})(f);return $t(s,"scrollPositionChange",()=>{u(i)}),c?(0,r.jsx)(Lo,{ref:t,className:p.root,ownerState:f,onDragOver:l,style:a}):null}),$o=B(function(e){const t=ot(),[n,i]=o.useState("none");return $t(t,"columnHeaderDragStart",()=>i("horizontal")),$t(t,"columnHeaderDragEnd",()=>i("none")),$t(t,"rowDragStart",()=>i("vertical")),$t(t,"rowDragEnd",()=>i("none")),"none"===n?null:"horizontal"===n?(0,r.jsx)(Qo,(0,y.A)({},e)):(0,r.jsx)(jo,(0,y.A)({},e))});function Ho(e){for(const t in e)return!1;return!0}const Go=ke(e=>e.sorting),Vo=Ee(Go,e=>e.sortedRows),Wo=Ie(Vo,Et,It,(e,t,n)=>e.reduce((e,r)=>{const o=t[r];if(o)e.push({id:r,model:o});else{const t=n[r];t&&tr(t)&&e.push({id:r,model:{[qn]:r}})}return e},[])),Uo=Ee(Go,e=>e.sortModel),qo=Ie(Uo,e=>e.reduce((t,n,r)=>(t[n.field]={sortDirection:n.sort,sortIndex:e.length>1?r+1:void 0},t),{})),Yo=(Ie(Vo,e=>e.reduce((e,t,n)=>(e[t]=n,e),Object.create(null))),ke(e=>e.filter)),Ko=Ee(Yo,e=>e.filterModel),Jo=Ee(Ko,e=>e.quickFilterValues),Xo=ke(e=>e.visibleRowsLookup),Zo=Ee(Yo,e=>e.filteredRowsLookup),ei=(Ee(Yo,e=>e.filteredChildrenCountLookup),Ee(Yo,e=>e.filteredDescendantCountLookup),Ie(Xo,Wo,(e,t)=>Ho(e)?t:t.filter(t=>!1!==e[t.id]))),ti=Ie(ei,e=>e.map(e=>e.id)),ni=Ie(Zo,Wo,(e,t)=>Ho(e)?t:t.filter(t=>!1!==e[t.id])),ri=Ie(ni,e=>e.map(e=>e.id)),oi=(Ie(ti,It,(e,t)=>{const n={};let r=0;return e.reduce((e,o)=>{const i=t[o];return n[i.depth]||(n[i.depth]=0),i.depth>r&&(n[i.depth]=0),r=i.depth,n[i.depth]+=1,e[o]=n[i.depth],e},{})}),Ee(Ie(ni,It,Bt,(e,t,n)=>n<2?[e]:e.reduce((e,n)=>{const r=t[n.id]?.depth;return void 0===r||(e[r]||(e[r]=[]),e[r].push(n)),e},[[]])),e=>e[0]??[])),ii=Ee(ei,e=>e.length),ai=Ee(oi,e=>e.length),li=Ee(ni,e=>e.length),si=(Ee(li,ai,(e,t)=>e-t),Ie(Ko,ze,(e,t)=>e.items?.filter(e=>{if(!e.field)return!1;const n=t[e.field];if(!n?.filterOperators||0===n?.filterOperators?.length)return!1;const r=n.filterOperators.find(t=>t.value===e.operator);if(!r)return!1;const o=Array.isArray(e.value)?e.value.length>0:null!=e.value&&""!==e.value?.toString();return!r.InputComponent||o}))),ci=Ie(si,e=>e.reduce((e,t)=>(e[t.field]?e[t.field].push(t):e[t.field]=[t],e),{})),ui=Ie(ti,e=>e.reduce((e,t,n)=>(e[t]=n,e),Object.create(null))),di=ke(e=>e.pivoting),fi=Ee(di,e=>e?.active),pi=new Map,hi=Ee(di,e=>e?.initialColumns||pi),gi=(e,t)=>{const n=J(e,Ct),r=J(e,ii),o=J(e,Dt),i=J(e,Ve),a=0===n&&0===o,l=J(e,St),s=J(e,fi),c=!l&&a,u=!l&&n>0&&0===r;let d=null,f=null;return c&&(d="noRowsOverlay"),!l&&0===i.length&&(d="noColumnsOverlay"),c&&s&&(d="emptyPivotOverlay"),u&&(d="noResultsOverlay"),l&&(d="loadingOverlay",f=t.slotProps?.loadingOverlay?.[a?"noRowsVariant":"variant"]??(a?"skeleton":"linear-progress")),{overlayType:d,loadingOverlayVariant:f}},mi=ke(e=>e.focus),Ai=Ee(mi,e=>e.cell),bi=Ee(mi,e=>e.columnHeader),vi=(Ee(mi,e=>e.columnHeaderFilter),Ee(mi,e=>e.columnGroupHeader)),yi=ke(e=>e.tabIndex),wi=Ee(yi,e=>e.cell),Ci=Ee(yi,e=>e.columnHeader),Si=(Ee(yi,e=>e.columnHeaderFilter),Ee(yi,e=>e.columnGroupHeader)),xi=ke(e=>e.columnMenu),Ei=B(function(){const e=Z(),t=se(),n=J(e,Ve),o=J(e,ci),i=J(e,qo),a=J(e,Ci),l=J(e,()=>null===wi(e)),s=J(e,Si),c=J(e,bi),u=J(e,vi),d=J(e,Mo),f=J(e,xi),p=J(e,He),h=J(e,Ro),g=!(null===s&&null===a&&l),m=e.current.columnHeadersContainerRef;return(0,r.jsx)(t.slots.columnHeaders,(0,y.A)({ref:m,visibleColumns:n,filterColumnLookup:o,sortColumnLookup:i,columnHeaderTabIndexState:a,columnGroupHeaderTabIndexState:s,columnHeaderFocus:c,columnGroupHeaderFocus:u,headerGroupingMaxDepth:d,columnMenuState:f,columnVisibility:p,columnGroupsHeaderStructure:h,hasOtherElementInTabSequence:g},t.slotProps?.columnHeaders))}),Ii=(0,_.Ay)("div",{slot:"internal",shouldForwardProp:void 0})({position:"absolute",top:"var(--DataGrid-headersTotalHeight)",left:0,width:"calc(100% - (var(--DataGrid-hasScrollY) * var(--DataGrid-scrollbarSize)))"}),ki=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"Main",overridesResolver:(e,t)=>{const{ownerState:n,loadingOverlayVariant:r,overlayType:o}=e,i="skeleton"===r||"noColumnsOverlay"===o;return[t.main,n.hasPinnedRight&&t["main--hasPinnedRight"],i&&t["main--hiddenContent"]]}})({flexGrow:1,position:"relative",overflow:"hidden",display:"flex",flexDirection:"column"}),Ri=S((e,t)=>{const{ownerState:n}=e,o=se(),i=ue().hooks.useGridAriaAttributes();return(0,r.jsxs)(ki,(0,y.A)({ownerState:n,className:e.className,tabIndex:-1},i,o.slotProps?.main,{ref:t,children:[(0,r.jsx)(Ii,{role:"presentation","data-id":"gridPanelAnchor"}),e.children]}))}),Mi=(0,_.Ay)("div",{slot:"internal",shouldForwardProp:void 0})({position:"sticky",zIndex:40,top:0});function Pi(e){const t=(0,R.A)({root:["topContainer"]},D,{});return(0,r.jsx)(Mi,(0,y.A)({},e,{className:(0,E.A)(t.root,L["container--top"]),role:"presentation"}))}var Bi=n(1539);const _i=(0,Bi.A)("div",{name:"MuiDataGrid",slot:"VirtualScrollerContent",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.virtualScrollerContent,n.overflowedContent&&t["virtualScrollerContent--overflowed"]]}})({}),Ti=S(function(e,t){const n=se(),o=!n.autoHeight&&"auto"===e.style?.minHeight,i=((e,t)=>{const{classes:n}=e,r={root:["virtualScrollerContent",t&&"virtualScrollerContent--overflowed"]};return(0,R.A)(r,D,n)})(n,o),a={classes:n.classes,overflowedContent:o};return(0,r.jsx)(_i,(0,y.A)({},e,{ownerState:a,className:(0,E.A)(i.root,e.className),ref:t}))}),Oi=(0,_.Ay)("div",{slot:"internal",shouldForwardProp:void 0})({display:"flex",flexDirection:"row",width:"var(--DataGrid-rowWidth)",boxSizing:"border-box"}),Di=(0,_.Ay)("div",{slot:"internal",shouldForwardProp:void 0})({position:"sticky",height:"100%",boxSizing:"border-box",borderTop:"1px solid var(--rowBorderColor)",backgroundColor:z.cell.background.pinned}),Ni=(0,_.Ay)(Di,{slot:"internal"})({left:0}),Li=(0,_.Ay)(Di,{slot:"internal"})({right:0}),Fi=(0,_.Ay)("div",{slot:"internal",shouldForwardProp:void 0})({flexGrow:1,borderTop:"1px solid var(--rowBorderColor)"}),Qi=B(function({rowsLength:e}){const t=ot(),{viewportOuterSize:n,minimumSize:o,hasScrollX:i,hasScrollY:a,scrollbarSize:l,leftPinnedWidth:s,rightPinnedWidth:c}=J(t,ut),u=i?l:0,d=n.height-o.height>0;return 0!==u||d?(0,r.jsxs)(Oi,{className:L.filler,role:"presentation",style:{height:u,"--rowBorderColor":0===e?"transparent":"var(--DataGrid-rowBorderColor)"},children:[s>0&&(0,r.jsx)(Ni,{className:L["filler--pinnedLeft"],style:{width:s}}),(0,r.jsx)(Fi,{}),c>0&&(0,r.jsx)(Li,{className:L["filler--pinnedRight"],style:{width:c+(a?l:0)}})]}):null}),ji=(0,Bi.A)("div",{name:"MuiDataGrid",slot:"VirtualScrollerRenderZone"})({position:"absolute",display:"flex",flexDirection:"column"}),zi=S(function(e,t){const n=se(),o=(e=>{const{classes:t}=e;return(0,R.A)({root:["virtualScrollerRenderZone"]},D,t)})(n);return(0,r.jsx)(ji,(0,y.A)({ownerState:n},e,{className:(0,E.A)(o.root,e.className),ref:t}))});var $i=n(7919);const Hi="calc(max(var(--DataGrid-scrollbarSize), 14px))",Gi=(0,_.Ay)("div",{slot:"internal",shouldForwardProp:void 0})({position:"absolute",display:"inline-block",zIndex:60,"&:hover":{zIndex:70},"--size":Hi}),Vi=(0,_.Ay)(Gi,{slot:"internal"})({width:"var(--size)",height:"calc(var(--DataGrid-hasScrollY) * (100% - var(--DataGrid-headersTotalHeight) - var(--DataGrid-hasScrollX) * var(--DataGrid-scrollbarSize)))",overflowY:"auto",overflowX:"hidden",outline:0,"& > div":{width:"var(--size)"},top:"var(--DataGrid-headersTotalHeight)",right:0}),Wi=(0,_.Ay)(Gi,{slot:"internal"})({width:"calc(var(--DataGrid-hasScrollX) * (100% - var(--DataGrid-hasScrollY) * var(--DataGrid-scrollbarSize)))",height:"var(--size)",overflowY:"hidden",overflowX:"auto",outline:0,"& > div":{height:"var(--size)"},bottom:0}),Ui=(0,_.Ay)(Gi,{slot:"internal"})({width:"var(--size)",height:"var(--size)",right:0,bottom:0,overflow:"scroll","@media print":{display:"none"}}),qi=S(function(e,t){const n=Z(),i=se(),a=o.useRef(!1),l=o.useRef(0),s=o.useRef(null),c=((e,t)=>{const{classes:n}=e,r={root:["scrollbar",`scrollbar--${t}`],content:["scrollbarContent"]};return(0,R.A)(r,D,n)})(i,e.position),u=J(n,ut),d="vertical"===e.position?"height":"width",f="vertical"===e.position?"scrollTop":"scrollLeft",p="vertical"===e.position?"top":"left",h="horizontal"===e.position?u.minimumSize.width:u.minimumSize.height-u.headersTotalHeight,g=(0,Nt.A)(()=>{const t=s.current,n=e.scrollPosition.current;t&&n[p]!==l.current&&(l.current=n[p],a.current?a.current=!1:(a.current=!0,t[f]=e.scrollPosition.current[p]))}),m=(0,Nt.A)(()=>{const e=n.current.virtualScrollerRef.current,t=s.current;t&&(a.current?a.current=!1:(a.current=!0,e[f]=t[f]))});(0,$i.A)(()=>{const e=n.current.virtualScrollerRef.current,t=s.current,r={passive:!0};return e.addEventListener("scroll",g,r),t.addEventListener("scroll",m,r),()=>{e.removeEventListener("scroll",g,r),t.removeEventListener("scroll",m,r)}});const A="vertical"===e.position?Vi:Wi,b=o.useMemo(()=>({[d]:`${h}px`}),[d,h]);return(0,r.jsx)(A,{ref:(0,I.A)(t,s),className:c.root,tabIndex:-1,"aria-hidden":"true",onFocus:e=>{e.target.blur()},children:(0,r.jsx)("div",{className:c.content,style:b})})}),Yi=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"ScrollShadow",overridesResolver:(e,t)=>[t.root,t[e.position]]})(({theme:e})=>({position:"absolute",inset:0,pointerEvents:"none",transition:z.transition(["box-shadow"],{duration:z.transitions.duration.short}),"--length":"dark"===e.palette.mode?"8px":"6px","--length-inverse":"calc(var(--length) * -1)","--opacity":"dark"===e.palette.mode?"0.7":"0.18","--blur":"var(--length)","--spread":"calc(var(--length) * -1)","--color":"0, 0, 0","--color-start":"rgba(var(--color), calc(var(--hasScrollStart) * var(--opacity)))","--color-end":"rgba(var(--color), calc(var(--hasScrollEnd) * var(--opacity)))",variants:[{props:{position:"vertical"},style:{top:"var(--DataGrid-topContainerHeight)",bottom:"calc(var(--DataGrid-bottomContainerHeight) + var(--DataGrid-hasScrollX) * var(--DataGrid-scrollbarSize))",boxShadow:"inset 0 var(--length) var(--blur) var(--spread) var(--color-start), inset 0 var(--length-inverse) var(--blur) var(--spread) var(--color-end)"}},{props:{position:"horizontal"},style:{left:"var(--DataGrid-leftPinnedWidth)",right:"calc(var(--DataGrid-rightPinnedWidth) + var(--DataGrid-hasScrollY) * var(--DataGrid-scrollbarSize))",boxShadow:"inset var(--length) 0 var(--blur) var(--spread) var(--color-start), inset var(--length-inverse) 0 var(--blur) var(--spread) var(--color-end)"}}]}));function Ki(e){const{position:t}=e,n={classes:se().classes,position:t},i=(e=>{const{classes:t,position:n}=e,r={root:["scrollShadow",`scrollShadow--${n}`]};return(0,R.A)(r,D,t)})(n),a=o.useRef(null),l=Z(),s=J(l,pt),c=J(l,ht),u=J(l,Ot),d=J(l,Ue),f="vertical"===t?c&&u?.bottom?.length>0:s&&void 0!==d?.right?.length&&d?.right?.length>0,p=(0,Hr.I)(),h=o.useCallback(e=>{if(!a.current)return;const n=Math.abs(Math.round(e)),r=ut(l),o=Math.round(r.contentSize["vertical"===t?"height":"width"]-r.viewportInnerSize["vertical"===t?"height":"width"]),i="vertical"===t?u?.top?.length>0:void 0!==d?.left?.length&&d?.left?.length>0,s="vertical"===t?u?.bottom?.length>0:void 0!==d?.right?.length&&d?.right?.length>0,c=p?n<o:n>0,f=p?n>0:n<o;a.current.style.setProperty("--hasScrollStart",i&&c?"1":"0"),a.current.style.setProperty("--hasScrollEnd",s&&f?"1":"0")},[u,d,p,t,l]);return $t(l,"scrollPositionChange",e=>{h(e["vertical"===t?"top":"left"])}),$t(l,"columnResizeStop",()=>{"horizontal"===t&&h(l.current.virtualScrollerRef?.current?.scrollLeft||0)}),o.useEffect(()=>{h(("horizontal"===t?l.current.virtualScrollerRef?.current?.scrollLeft:l.current.virtualScrollerRef?.current?.scrollTop)??0)},[h,l,t]),(0,r.jsx)(Yi,{className:i.root,ownerState:n,ref:a,style:{"--hasScrollStart":0,"--hasScrollEnd":f?"1":"0"}})}const Ji=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"OverlayWrapper",shouldForwardProp:e=>"overlayType"!==e&&"loadingOverlayVariant"!==e&&"right"!==e})(({overlayType:e,loadingOverlayVariant:t,right:n})=>"skeleton"!==t?{position:"sticky",top:"var(--DataGrid-headersTotalHeight)",left:0,right:`${n}px`,width:0,height:0,zIndex:"loadingOverlay"===e?5:4}:{}),Xi=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"OverlayWrapperInner",shouldForwardProp:e=>"overlayType"!==e&&"loadingOverlayVariant"!==e})({});function Zi(e){const t=ot(),n=se(),o=J(t,ut);let i=Math.max(o.viewportOuterSize.height-o.topContainerHeight-o.bottomContainerHeight-(o.hasScrollX?o.scrollbarSize:0),0);0===i&&(i=or);const a=(e=>{const{classes:t}=e;return(0,R.A)({root:["overlayWrapper"],inner:["overlayWrapperInner"]},D,t)})((0,y.A)({},e,{classes:n.classes}));return(0,r.jsx)(Ji,(0,y.A)({className:a.root},e,{right:o.columnsTotalWidth-o.viewportOuterSize.width,children:(0,r.jsx)(Xi,(0,y.A)({className:a.inner,style:{height:i,width:o.viewportOuterSize.width}},e))}))}function ea(e,t){return Math.round(e*10**t)/10**t}const ta=()=>{};function na(e,t,n){const r=(0,G.A)(ra,{store:e,selector:t}).current;r.effect=n,(0,$i.A)(r.onMount)}function ra(e){const{store:t,selector:n}=e;let r=n(t.state);const o={effect:ta,dispose:null,subscribe:()=>{o.dispose??=t.subscribe(e=>{const t=n(e);if(!Object.is(r,t)){const e=r;r=t,o.effect(e,t)}})},onMount:()=>(o.subscribe(),()=>{o.dispose?.(),o.dispose=null})};return o.subscribe(),o}const oa=("undefined"!=typeof navigator?navigator.userAgent.toLowerCase():"empty").includes("firefox"),ia="undefined"!=typeof window&&/jsdom|HappyDOM/.test(window.navigator.userAgent);var aa=n(55);function la(e,t){if(e===t)return!0;if(e&&t&&"object"==typeof e&&"object"==typeof t){if(e.constructor!==t.constructor)return!1;if(Array.isArray(e)){const n=e.length;if(n!==t.length)return!1;for(let r=0;r<n;r+=1)if(!la(e[r],t[r]))return!1;return!0}if(e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;const n=Array.from(e.entries());for(let e=0;e<n.length;e+=1)if(!t.has(n[e][0]))return!1;for(let e=0;e<n.length;e+=1){const r=n[e];if(!la(r[1],t.get(r[0])))return!1}return!0}if(e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;const n=Array.from(e.entries());for(let e=0;e<n.length;e+=1)if(!t.has(n[e][0]))return!1;return!0}if(ArrayBuffer.isView(e)&&ArrayBuffer.isView(t)){const n=e.length;if(n!==t.length)return!1;for(let r=0;r<n;r+=1)if(e[r]!==t[r])return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===t.toString();const n=Object.keys(e),r=n.length;if(r!==Object.keys(t).length)return!1;for(let e=0;e<r;e+=1)if(!Object.prototype.hasOwnProperty.call(t,n[e]))return!1;for(let o=0;o<r;o+=1){const r=n[o];if(!la(e[r],t[r]))return!1}return!0}return e!=e&&t!=t}var sa=n(9966);const ca=C>=19?function(e,t,n,r,i){const a=o.useCallback(()=>t(e.getSnapshot(),n,r,i),[e,t,n,r,i]);return(0,H.useSyncExternalStore)(e.subscribe,a,a)}:function(e,t,n,r,o){return(0,sa.useSyncExternalStoreWithSelector)(e.subscribe,e.getSnapshot,e.getSnapshot,e=>t(e,n,r,o))};function ua(e,t,n,r,o){return ca(e,t,n,r,o)}const da={EMPTY:{width:0,height:0},equals:(e,t)=>e.width===t.width&&e.height===t.height},fa={EMPTY:{top:[],bottom:[]}},pa={EMPTY:{left:[],right:[]}},ha={EMPTY:{top:0,left:0},equals:(e,t)=>e.top===t.top&&e.left===t.left};let ga=function(e){return e[e.NONE=0]="NONE",e[e.UP=1]="UP",e[e.DOWN=2]="DOWN",e[e.LEFT=3]="LEFT",e[e.RIGHT=4]="RIGHT",e}({});(ga||(ga={})).forDelta=function(e,t){return 0===e&&0===t?ga.NONE:Math.abs(t)>=Math.abs(e)?t>0?ga.DOWN:ga.UP:e>0?ga.RIGHT:ga.LEFT};const ma={isReady:!1,root:da.EMPTY,viewportOuterSize:da.EMPTY,viewportInnerSize:da.EMPTY,contentSize:da.EMPTY,minimumSize:da.EMPTY,hasScrollX:!1,hasScrollY:!1,scrollbarSize:0,rowWidth:0,rowHeight:0,columnsTotalWidth:0,leftPinnedWidth:0,rightPinnedWidth:0,topContainerHeight:0,bottomContainerHeight:0,autoHeight:!1,minimalContentHeight:void 0},Aa={rootSize:e=>e.rootSize,dimensions:e=>e.dimensions,rowHeight:e=>e.dimensions.rowHeight,columnsTotalWidth:e=>e.dimensions.columnsTotalWidth,contentHeight:e=>e.dimensions.contentSize.height,autoHeight:e=>e.dimensions.autoHeight,minimalContentHeight:e=>e.dimensions.minimalContentHeight,rowsMeta:e=>e.rowsMeta,rowPositions:e=>e.rowsMeta.positions,columnPositions:xe((e,t)=>{const n=[];let r=0;for(let e=0;e<t.length;e+=1)n.push(r),r+=t[e].computedWidth;return n}),needsHorizontalScrollbar:e=>e.dimensions.viewportOuterSize.width>0&&e.dimensions.columnsTotalWidth>e.dimensions.viewportOuterSize.width},ba={initialize:function(e){const t=(0,y.A)({},ma,e.dimensions,{autoHeight:e.dimensions.autoHeight,minimalContentHeight:e.dimensions.minimalContentHeight}),{rowCount:n}=e,{rowHeight:r}=t,o={currentPageTotalHeight:n*r,positions:Array.from({length:n},(e,t)=>t*r),pinnedTopRowsTotalHeight:0,pinnedBottomRowsTotalHeight:0},i=new Map;return{rootSize:da.EMPTY,dimensions:t,rowsMeta:o,rowHeights:i}},use:function(e,t,n){const r=o.useRef(!0),i=o.useRef({counter:0,heights:{content:0,pinnedTop:0,pinnedBottom:0},lastFlipTimestamp:0}),{layout:a,dimensions:{rowHeight:l,columnsTotalWidth:s,leftPinnedWidth:c,rightPinnedWidth:u,topPinnedHeight:d,bottomPinnedHeight:f},onResize:p}=t,h=o.useCallback(n=>{if(n&&(r.current=!1),r.current)return;const o=a.refs.container.current,h=Aa.rootSize(e.state),g=Aa.rowsMeta(e.state),m=function(e,t){if(void 0!==t)return t;if(null===e)return 0;const n=va.get(e);if(void 0!==n)return n;const r=(0,aa.A)(e).createElement("div");r.style.width="99px",r.style.height="99px",r.style.position="absolute",r.style.overflow="scroll",r.className="scrollDiv",e.appendChild(r);const o=r.offsetWidth-r.clientWidth;return e.removeChild(r),va.set(e,o),o}(o,t.dimensions.scrollbarSize),A=d+g.pinnedTopRowsTotalHeight,b=f+g.pinnedBottomRowsTotalHeight,v={width:s,height:ea(g.currentPageTotalHeight,1)},y=e.state.dimensions;let w,C,S=!1,x=!1;if(t.dimensions.autoHeight)x=!1,S=Math.round(s)>Math.round(h.width),w={width:h.width,height:A+b+v.height},C={width:Math.max(0,w.width-(x?m:0)),height:Math.max(0,w.height-(S?m:0))};else{w={width:h.width,height:h.height},C={width:Math.max(0,w.width),height:Math.max(0,w.height-A-b)};const e=v,t=C,n=e.width>t.width,r=e.height>t.height;(n||r)&&(x=r,S=e.width+(x?m:0)>t.width,S&&(x=e.height+m>t.height));{const e=i.current,t=g.currentPageTotalHeight!==e.heights.content||g.pinnedTopRowsTotalHeight!==e.heights.pinnedTop||g.pinnedBottomRowsTotalHeight!==e.heights.pinnedBottom;if(t&&(e.counter=0,e.heights={content:g.currentPageTotalHeight,pinnedTop:g.pinnedTopRowsTotalHeight,pinnedBottom:g.pinnedBottomRowsTotalHeight}),y.isReady&&x!==y.hasScrollY){const r=performance.now();r-e.lastFlipTimestamp>100&&(e.counter=0),e.lastFlipTimestamp=r,t||(e.counter+=1),e.counter>=2&&(x=!1,S=n)}}x&&(C.width-=m),S&&(C.height-=m)}t.disableHorizontalScroll&&(S=!1),t.disableVerticalScroll&&(x=!1);const E=Math.max(w.width,s+(x?m:0)),I={isReady:!0,root:h,viewportOuterSize:w,viewportInnerSize:C,contentSize:v,minimumSize:{width:s,height:A+v.height+b},hasScrollX:S,hasScrollY:x,scrollbarSize:m,rowWidth:E,rowHeight:l,columnsTotalWidth:s,leftPinnedWidth:c,rightPinnedWidth:u,topContainerHeight:A,bottomContainerHeight:b,autoHeight:t.dimensions.autoHeight,minimalContentHeight:t.dimensions.minimalContentHeight};la(y,I)||(e.update({dimensions:I}),p?.(I.root))},[e,a.refs.container,t.dimensions.scrollbarSize,t.dimensions.autoHeight,t.dimensions.minimalContentHeight,t.disableHorizontalScroll,t.disableVerticalScroll,p,l,s,c,u,d,f]),{resizeThrottleMs:g}=t,m=(0,Nt.A)(h),A=o.useMemo(()=>g>0?function(e,t=166){let n,r;const o=()=>{n=void 0,e(...r)};function i(...e){r=e,void 0===n&&(n=setTimeout(o,t))}return i.clear=()=>{clearTimeout(n),n=void 0},i}(m,g):void 0,[g,m]);o.useEffect(()=>A?.clear,[A]),(0,Ut.A)(h,[h]),(0,Ut.A)(()=>{e.update({dimensions:(0,y.A)({},e.state.dimensions,{autoHeight:t.dimensions.autoHeight,minimalContentHeight:t.dimensions.minimalContentHeight})})},[e,t.dimensions.autoHeight,t.dimensions.minimalContentHeight]);const b=function(e,t,n){const r=e.state.rowHeights,{rows:i,getRowHeight:a,getRowSpacing:l,getEstimatedRowHeight:s}=t,c=o.useRef(-1),u=o.useRef(!1),d=o.useRef(!1),f=t.pinnedRows,p=ua(e,Aa.rowHeight),h=(0,Nt.A)(t=>{let n=r.get(t);return void 0===n&&(n={content:e.state.dimensions.rowHeight,spacingTop:0,spacingBottom:0,detail:0,autoHeight:!1,needsFirstMeasurement:!0},r.set(t,n)),n}),{applyRowHeight:g}=t,m=o.useCallback(t=>{const n=Aa.dimensions(e.state),r=n.rowHeight,o=h(t.id);if(a){const e=a(t);if("auto"===e){if(o.needsFirstMeasurement){const e=s?s(t):r;o.content=e??r}u.current=!0,o.autoHeight=!0}else o.content=e??n.rowHeight,o.needsFirstMeasurement=!1,o.autoHeight=!1}else o.content=r,o.needsFirstMeasurement=!1;if(l){const e=l(t);o.spacingTop=e.top??0,o.spacingBottom=e.bottom??0}else o.spacingTop=0,o.spacingBottom=0;return g?.(o,t),o},[e,a,h,s,p,l,g]),A=o.useCallback(()=>{u.current=!1;const t=f?.top.reduce((e,t)=>{const n=m(t);return e+n.content+n.spacingTop+n.spacingBottom+n.detail},0)??0,r=f?.bottom.reduce((e,t)=>{const n=m(t);return e+n.content+n.spacingTop+n.spacingBottom+n.detail},0)??0,o=[],a=i.reduce((e,t)=>{o.push(e);const n=m(t);return e+(n.content+n.spacingTop+n.spacingBottom+n.detail)},0);u.current||(c.current=1/0);const l=t!==e.state.rowsMeta.pinnedTopRowsTotalHeight||r!==e.state.rowsMeta.pinnedBottomRowsTotalHeight||a!==e.state.rowsMeta.currentPageTotalHeight,s={currentPageTotalHeight:a,positions:o,pinnedTopRowsTotalHeight:t,pinnedBottomRowsTotalHeight:r};e.set("rowsMeta",s),l&&n(),d.current=!0},[e,f,i,m,n]),b=(0,Nt.A)(A),v=(e,t)=>{const n=h(e),r=n.content!==t;n.needsFirstMeasurement=!1,n.content=t,d.current&&=!r},y=(0,G.A)(()=>"undefined"==typeof ResizeObserver?void 0:new ResizeObserver(e=>{for(let n=0;n<e.length;n+=1){const r=e[n],o=r.borderBoxSize&&r.borderBoxSize.length>0?r.borderBoxSize[0].blockSize:r.contentRect.height,i=r.target.__mui_id,a=t.focusedVirtualCell?.()?.id;if(a===i&&0===o)return;v(i,o)}d.current||requestAnimationFrame(()=>{b()})})).current;return(0,Ut.A)(()=>{A()},[A]),{getRowHeight:t=>r.get(t)?.content??Aa.rowHeight(e.state),setLastMeasuredRowIndex:e=>{u.current&&e>c.current&&(c.current=e)},storeRowHeightMeasurement:v,hydrateRowsMeta:A,observeRowHeight:(e,t)=>(e.__mui_id=t,y?.observe(e),()=>y?.unobserve(e)),rowHasAutoHeight:e=>r.get(e)?.autoHeight??!1,getRowHeightEntry:h,getLastMeasuredRowIndex:()=>c.current,resetRowHeights:()=>{r.clear(),A()}}}(e,t,h);return{updateDimensions:h,debouncedUpdateDimensions:A,rowsMeta:b}},selectors:Aa},va=new WeakMap;var ya=n(7868);const wa=()=>{},Ca=(e,t,n)=>Math.max(t,Math.min(n,e)),Sa={top:0,left:0},xa=Object.freeze(new Map),Ea={firstRowIndex:0,lastRowIndex:0,firstColumnIndex:0,lastColumnIndex:0},Ia=(()=>{const e=Se(e=>e.virtualization.renderContext.firstRowIndex);return{store:Se(e=>e.virtualization),renderContext:Se(e=>e.virtualization.renderContext),enabledForRows:Se(e=>e.virtualization.enabledForRows),enabledForColumns:Se(e=>e.virtualization.enabledForColumns),offsetTop:Se(ba.selectors.rowPositions,e,(e,t)=>e[t]??0),context:Se(e=>e.virtualization.context),scrollPosition:Se(e=>e.virtualization.scrollPosition)}})(),ka={initialize:function(e){return{virtualization:(0,y.A)({enabled:!ia,enabledForRows:!ia,enabledForColumns:!ia,renderContext:Ea,props:e.layout.constructor.elements.reduce((e,t)=>(e[t],e),{}),context:{},scrollPosition:{current:ha.EMPTY}},e.initialState?.virtualization),getters:null}},use:function(e,t,n){const{layout:r,dimensions:{rowHeight:i,columnsTotalWidth:a=0},virtualization:{isRtl:l=!1,rowBufferPx:s=150,columnBufferPx:c=150},colspan:u,initialState:d,rows:f,range:p,columns:h,pinnedRows:g=fa.EMPTY,pinnedColumns:m=pa.EMPTY,onWheel:A,onTouchMove:b,onRenderContextChange:v,onScrollChange:w,scrollReset:C,renderRow:S,renderInfiniteLoadingTrigger:x}=t,E=g.bottom.length>0,[I,k]=o.useState(xa),R=o.useRef(!1),M=o.useRef(!1),P=ua(e,Ia.renderContext),B=ua(e,Ia.enabledForRows),_=ua(e,Ia.enabledForColumns),T=ua(e,ba.selectors.contentHeight),O=o.useRef(d?.scroll??Sa),D=o.useRef(!1),N=o.useRef(Sa),L=o.useRef(Ea),F=(0,Vt.A)(),Q=o.useRef(void 0),j=(0,G.A)(()=>function(e,t,n,r){return{direction:ga.NONE,buffer:Na(e,ga.NONE,t,n,r,300)}}(l,s,c,15*i)).current,z=o.useCallback(t=>{Oa(t,e.state.virtualization.renderContext)||e.set("virtualization",(0,y.A)({},e.state.virtualization,{renderContext:t,scrollPosition:{current:(0,y.A)({},O.current)}}));const n=ba.selectors.dimensions(e.state).isReady,r=t.firstRowIndex!==L.current.firstRowIndex||t.lastRowIndex!==L.current.lastRowIndex;n&&r&&(L.current=t,v?.(t)),N.current=O.current},[e,v]),$=(0,Nt.A)(()=>{const o=r.refs.scroller.current;if(!o)return;const a=ba.selectors.dimensions(e.state),u=Math.ceil(a.contentSize.height-a.viewportInnerSize.height),d=Math.ceil(a.contentSize.width-a.viewportInnerSize.width),f={top:Ca(o.scrollTop,0,u),left:l?Ca(o.scrollLeft,-Math.abs(d),0):Ca(o.scrollLeft,0,d)},p=f.left-O.current.left,h=f.top-O.current.top,g=0!==p||0!==h;O.current=f;const m=g?ga.forDelta(p,h):ga.NONE,A=Math.abs(O.current.top-N.current.top),b=Math.abs(O.current.left-N.current.left),v=A>=i||b>=50,w=j.direction!==m;if(!v&&!w)return e.set("virtualization",(0,y.A)({},e.state.virtualization,{scrollPosition:{current:(0,y.A)({},O.current)}})),P;if(w)switch(m){case ga.NONE:case ga.LEFT:case ga.RIGHT:Q.current=void 0;break;default:Q.current=P}j.direction=m,j.buffer=Na(l,m,s,c,15*i,300);const C=Pa(Ma(e,t,n,B,_),O.current,j);return Oa(C,P)?e.set("virtualization",(0,y.A)({},e.state.virtualization,{scrollPosition:{current:(0,y.A)({},O.current)}})):(ya.flushSync(()=>{z(C)}),F.start(1e3,$)),C}),H=()=>{if(!ba.selectors.dimensions(e.state).isReady&&(B||_))return;const r=Pa(Ma(e,t,n,B,_),O.current,j);Q.current=void 0,z(r)},V=(0,Nt.A)(H);na(e,ba.selectors.dimensions,(e,t)=>{t.isReady&&H()}),(0,Ut.A)(()=>{R.current&&(H(),R.current=!1)});const W=(0,Nt.A)(()=>{if(D.current)return void(D.current=!1);const e=$();e&&w?.(O.current,e)}),U=o.useRef(null);(0,Ut.A)(()=>{M.current&&V()},[_,B,V]),(0,Ut.A)(()=>{r.refs.scroller.current&&(r.refs.scroller.current.scrollLeft=0)},[r.refs.scroller,C]),(e=>{const t=o.useRef(!1);(0,Ut.A)(()=>t.current||!e?wa:(t.current=!0,(()=>{if(w?.(O.current,P),M.current=!0,d?.scroll&&r.refs.scroller.current){const e=r.refs.scroller.current,{top:t,left:n}=d.scroll,o={top:!(t>0),left:!(n>0)};!o.left&&a&&(e.scrollLeft=n,o.left=!0,D.current=!0),!o.top&&T&&(e.scrollTop=t,D.current=!0),o.top&&o.left||(U.current=(r,i)=>{!o.left&&r&&(e.scrollLeft=n,o.left=!0,D.current=!0),!o.top&&i&&(e.scrollTop=t,o.top=!0,D.current=!0),o.left&&o.top&&(U.current=null)})}})()),[t.current||e])})(P!==Ea),na(e,ba.selectors.dimensions,H),(0,Ut.A)(()=>{r.refs.scroller&&U.current?.(a,T)},[r.refs.scroller,a,T]);const q=o.useRef(!0),Y={containerRef:Ra(t=>{r.refs.container.current=t;const o=function(e,t,n){if(!e)return;const r=e.getBoundingClientRect(),o={width:ea(r.width,1),height:ea(r.height,1)};if(t.state.rootSize!==da.EMPTY&&da.equals(o,t.state.rootSize)||n(o),"undefined"==typeof ResizeObserver)return;const i=new ResizeObserver(([e])=>{if(!e)return;const r={width:ea(e.contentRect.width,1),height:ea(e.contentRect.height,1)};da.equals(r,t.state.rootSize)||n(r)});return i.observe(e),()=>{i.disconnect()}}(t,e,t=>{0===t.width&&0===t.height&&0!==e.state.rootSize.height&&0!==e.state.rootSize.width||(e.state.rootSize=t,q.current||!n.debouncedUpdateDimensions?(n.updateDimensions(q.current),q.current=!1):n.debouncedUpdateDimensions())});return()=>{o?.(),r.refs.container.current=null}}),scrollerRef:Ra(e=>{r.refs.scroller.current=e;const t={passive:!0};return e.addEventListener("scroll",W,t),e.addEventListener("wheel",A,t),e.addEventListener("touchmove",b,t),()=>{e.removeEventListener("scroll",W,t),e.removeEventListener("wheel",A,t),e.removeEventListener("touchmove",b,t),r.refs.scroller.current=null}})},K=r.use(e,t,n,Y),J=(0,y.A)({setPanels:k,getRows:(r={},o)=>{if(!r.rows&&!p)return[];let i=P;r.renderContext&&(i=r.renderContext,i.firstColumnIndex=P.firstColumnIndex,i.lastColumnIndex=P.lastColumnIndex);const l=!E&&void 0===r.position||E&&"bottom"===r.position,s=void 0!==r.position;let c;switch(r.position){case"top":c=0;break;case"bottom":c=g.top.length+f.length;break;default:c=g.top.length}const d=r.rows??f,A=i.firstRowIndex,b=Math.min(i.lastRowIndex,d.length),v=r.rows?La(0,r.rows.length):La(A,b);let y=-1;const w=t.focusedVirtualCell?.();!s&&w&&(w.rowIndex<A&&w.rowIndex>=0&&w.rowIndex<d.length&&(v.unshift(w.rowIndex),y=w.rowIndex),w.rowIndex>b&&w.rowIndex<d.length&&(v.push(w.rowIndex),y=w.rowIndex));const C=[],k=ba.selectors.columnPositions(e.state,h);return v.forEach(e=>{const{id:t,model:g}=d[e];if(o&&!o[t])return;const A=(p?.firstRowIndex||0)+c+e;if(u?.enabled){const e=m.left.length,r=h.length-m.right.length;n.calculateColSpan(t,e,r,h),m.left.length>0&&n.calculateColSpan(t,0,m.left.length,h),m.right.length>0&&n.calculateColSpan(t,h.length-m.right.length,h.length,h)}const b=n.rowsMeta.rowHasAutoHeight(t)?"auto":n.rowsMeta.getRowHeight(t);let v=!1;void 0===r.position&&(v=0===e);let E=!1;const R=e===d.length-1;l&&(s?E=R:e===f.length-1&&(E=!0));let M=i;Q.current&&e>=Q.current.firstRowIndex&&e<Q.current.lastRowIndex&&(M=Q.current);const P=e===y,B=w?.rowIndex===A,_=Da(k,M,m.left.length),T=R&&"top"===r.position,O=M.firstColumnIndex,D=M.lastColumnIndex;if(C.push(S({id:t,model:g,rowIndex:A,offsetLeft:_,columnsTotalWidth:a,baseRowHeight:b,firstColumnIndex:O,lastColumnIndex:D,focusedColumnIndex:B?w.columnIndex:void 0,isFirstVisible:v,isLastVisible:E,isVirtualFocusRow:P,showBottomBorder:T})),P)return;const N=I.get(t);N&&C.push(N),void 0===r.position&&R&&x&&C.push(x(t))}),C},rows:t.rows},K);return(0,y.A)({getters:J,setPanels:k,forceUpdateRenderContext:H,scheduleUpdateRenderContext:()=>{R.current=!0}},{getCellColSpanInfo:()=>{throw new Error("Unimplemented: colspan feature is required")},calculateColSpan:()=>{throw new Error("Unimplemented: colspan feature is required")},getHiddenCellsOrigin:()=>{throw new Error("Unimplemented: rowspan feature is required")}})},selectors:Ia};function Ra(e){const t=o.useRef(void 0);return(0,Nt.A)(n=>{if(n)return t.current=e(n),C>=19?t.current:void 0;t.current?.()})}function Ma(e,t,n,r,o){const i=ba.selectors.dimensions(e.state),a=t.rows,l=t.range,s=t.columns,c=n.getHiddenCellsOrigin(),u=t.rows.at(-1)?.id,d=s.at(-1);return{api:n,enabledForRows:r,enabledForColumns:o,autoHeight:i.autoHeight,rowBufferPx:t.virtualization.rowBufferPx,columnBufferPx:t.virtualization.columnBufferPx,leftPinnedWidth:i.leftPinnedWidth,columnsTotalWidth:i.columnsTotalWidth,viewportInnerWidth:i.viewportInnerSize.width,viewportInnerHeight:i.viewportInnerSize.height,lastRowHeight:void 0!==u?n.rowsMeta.getRowHeight(u):0,lastColumnWidth:d?.computedWidth??0,rowsMeta:ba.selectors.rowsMeta(e.state),columnPositions:ba.selectors.columnPositions(e.state,t.columns),rows:a,range:l,pinnedColumns:t.pinnedColumns,columns:s,hiddenCellsOriginMap:c,virtualizeColumnsWithAutoRowHeight:t.virtualizeColumnsWithAutoRowHeight}}function Pa(e,t,n){const r={firstRowIndex:0,lastRowIndex:e.rows.length,firstColumnIndex:0,lastColumnIndex:e.columns.length},{top:o,left:i}=t,a=Math.abs(i)+e.leftPinnedWidth;if(e.enabledForRows){let t=Math.min(Ba(e,o,{atStart:!0,lastPosition:e.rowsMeta.positions[e.rowsMeta.positions.length-1]+e.lastRowHeight}),e.rowsMeta.positions.length-1);const n=e.hiddenCellsOriginMap[t];if(n){const e=Math.min(...Object.values(n));t=Math.min(t,e)}const i=e.autoHeight?t+e.rows.length:Ba(e,o+e.viewportInnerHeight);r.firstRowIndex=t,r.lastRowIndex=i}if(e.enabledForColumns){let t=0,o=e.columnPositions.length,i=!1;const[l,s]=Ta({firstIndex:r.firstRowIndex,lastIndex:r.lastRowIndex,minFirstIndex:0,maxLastIndex:e.rows.length,bufferBefore:n.buffer.rowBefore,bufferAfter:n.buffer.rowAfter,positions:e.rowsMeta.positions,lastSize:e.lastRowHeight});if(!e.virtualizeColumnsWithAutoRowHeight)for(let t=l;t<s&&!i;t+=1){const n=e.rows[t];i=e.api.rowsMeta.rowHasAutoHeight(n.id)}i&&!e.virtualizeColumnsWithAutoRowHeight||(t=_a(a,e.columnPositions,{atStart:!0,lastPosition:e.columnsTotalWidth}),o=_a(a+e.viewportInnerWidth,e.columnPositions)),r.firstColumnIndex=t,r.lastColumnIndex=o}const l=function(e,t,n){const[r,o]=Ta({firstIndex:t.firstRowIndex,lastIndex:t.lastRowIndex,minFirstIndex:0,maxLastIndex:e.rows.length,bufferBefore:n.buffer.rowBefore,bufferAfter:n.buffer.rowAfter,positions:e.rowsMeta.positions,lastSize:e.lastRowHeight}),[i,a]=Ta({firstIndex:t.firstColumnIndex,lastIndex:t.lastColumnIndex,minFirstIndex:e.pinnedColumns?.left.length??0,maxLastIndex:e.columns.length-(e.pinnedColumns?.right.length??0),bufferBefore:n.buffer.columnBefore,bufferAfter:n.buffer.columnAfter,positions:e.columnPositions,lastSize:e.lastColumnWidth}),l=function({api:e,firstColumnToRender:t,firstRowToRender:n,lastRowToRender:r,visibleRows:o}){let i=t,a=!1;for(;!a&&i>=0;){a=!0;for(let t=n;t<r;t+=1)if(o[t]){const n=o[t].id,r=e.getCellColSpanInfo(n,i);if(r&&r.spannedByColSpan&&r.leftVisibleCellIndex<i){i=r.leftVisibleCellIndex,a=!1;break}}}return i}({api:e.api,firstColumnToRender:i,firstRowToRender:r,lastRowToRender:o,visibleRows:e.rows});return{firstRowIndex:r,lastRowIndex:o,firstColumnIndex:l,lastColumnIndex:a}}(e,r,n);return l}function Ba(e,t,n){const r=e.api.rowsMeta.getLastMeasuredRowIndex();let o=r===1/0;e.range?.lastRowIndex&&!o&&(o=r>=e.range.lastRowIndex);const i=Ca(r-(e.range?.firstRowIndex||0),0,e.rowsMeta.positions.length);return o||e.rowsMeta.positions[i]>=t?_a(t,e.rowsMeta.positions,n):function(e,t,n,r){let o=1;for(;n<t.length&&Math.abs(t[n])<e;)n+=o,o*=2;return _a(e,t,r,Math.floor(n/2),Math.min(n,t.length))}(t,e.rowsMeta.positions,i,n)}function _a(e,t,n=void 0,r=0,o=t.length){if(t.length<=0)return-1;if(r>=o)return r;const i=r+Math.floor((o-r)/2),a=t[i];let l;return l=n?.atStart?e-((i===t.length-1?n.lastPosition:t[i+1])-a)<a:e<=a,l?_a(e,t,n,r,i):_a(e,t,n,i+1,o)}function Ta({firstIndex:e,lastIndex:t,bufferBefore:n,bufferAfter:r,minFirstIndex:o,maxLastIndex:i,positions:a,lastSize:l}){const s=a[e]-n,c=a[t]+r,u=_a(s,a,{atStart:!0,lastPosition:a[a.length-1]+l}),d=_a(c,a);return[Ca(u,o,i),Ca(d,o,i)]}function Oa(e,t){return e===t||e.firstRowIndex===t.firstRowIndex&&e.lastRowIndex===t.lastRowIndex&&e.firstColumnIndex===t.firstColumnIndex&&e.lastColumnIndex===t.lastColumnIndex}function Da(e,t,n){const r=(e[t.firstColumnIndex]??0)-(e[n]??0);return Math.abs(r)}function Na(e,t,n,r,o,i){if(e)switch(t){case ga.LEFT:t=ga.RIGHT;break;case ga.RIGHT:t=ga.LEFT}switch(t){case ga.NONE:return{rowAfter:n,rowBefore:n,columnAfter:r,columnBefore:r};case ga.LEFT:return{rowAfter:0,rowBefore:0,columnAfter:0,columnBefore:i};case ga.RIGHT:return{rowAfter:0,rowBefore:0,columnAfter:i,columnBefore:0};case ga.UP:return{rowAfter:0,rowBefore:o,columnAfter:0,columnBefore:0};case ga.DOWN:return{rowAfter:o,rowBefore:0,columnAfter:0,columnBefore:0};default:throw new Error("unreachable")}}function La(e,t){return Array.from({length:t-e}).map((t,n)=>e+n)}class Fa{static elements=["scroller","container"];constructor(e){this.refs=e}refSetter(e){return t=>{t&&this.refs[e].current!==t&&(this.refs[e].current=t)}}}class Qa extends Fa{static elements=["scroller","container","content","positioner","scrollbarVertical","scrollbarHorizontal"];use(e,t,n,r){const{scrollerRef:o,containerRef:i}=r,a=(0,Nt.A)(this.refSetter("scrollbarVertical")),l=(0,Nt.A)(this.refSetter("scrollbarHorizontal"));e.state.virtualization.context={scrollerRef:o,containerRef:i,scrollbarVerticalRef:a,scrollbarHorizontalRef:l}}static selectors=(()=>({containerProps:xe(ka.selectors.context,e=>({ref:e.containerRef})),scrollerProps:xe(ka.selectors.context,ba.selectors.autoHeight,ba.selectors.needsHorizontalScrollbar,(e,t,n)=>({ref:e.scrollerRef,style:{overflowX:n?void 0:"hidden",overflowY:t?"hidden":void 0},role:"presentation",tabIndex:oa?-1:void 0})),contentProps:xe(ba.selectors.contentHeight,ba.selectors.minimalContentHeight,ba.selectors.columnsTotalWidth,ba.selectors.needsHorizontalScrollbar,(e,t,n,r)=>({style:{width:r?n:"auto",flexBasis:0===e?t:e,flexShrink:0},role:"presentation"})),positionerProps:xe(ka.selectors.offsetTop,e=>({style:{transform:`translate3d(0, ${e}px, 0)`}})),scrollbarHorizontalProps:xe(ka.selectors.context,ka.selectors.scrollPosition,(e,t)=>({ref:e.scrollbarHorizontalRef,scrollPosition:t})),scrollbarVerticalProps:xe(ka.selectors.context,ka.selectors.scrollPosition,(e,t)=>({ref:e.scrollbarVerticalRef,scrollPosition:t})),scrollAreaProps:xe(ka.selectors.scrollPosition,e=>({scrollPosition:e}))}))()}class ja extends Qa{use(e,t,n,r){super.use(e,t,n,r);const o=e.use(Qa.selectors.containerProps),i=e.use(Qa.selectors.scrollerProps),a=e.use(Qa.selectors.contentProps),l=e.use(Qa.selectors.positionerProps),s=e.use(Qa.selectors.scrollbarVerticalProps),c=e.use(Qa.selectors.scrollbarHorizontalProps),u=e.use(Qa.selectors.scrollAreaProps);return{getContainerProps:()=>o,getScrollerProps:()=>i,getContentProps:()=>a,getPositionerProps:()=>l,getScrollbarVerticalProps:()=>s,getScrollbarHorizontalProps:()=>c,getScrollAreaProps:()=>u}}}xe(ka.selectors.context,ba.selectors.autoHeight,ba.selectors.needsHorizontalScrollbar,(e,t,n)=>({ref:e.mergedRef,style:{overflowX:n?void 0:"hidden",overflowY:t?"hidden":void 0,position:"relative"},role:"presentation",tabIndex:oa?-1:void 0})),xe(ba.selectors.contentHeight,e=>({style:{position:"absolute",display:"inline-block",width:"100%",height:e,top:0,left:0,zIndex:-1},role:"presentation"})),xe(ka.selectors.offsetTop,e=>({style:{height:e}}));class za{static create(e){return new za(e)}constructor(e){this.state=e,this.listeners=new Set,this.updateTick=0}subscribe=e=>(this.listeners.add(e),()=>{this.listeners.delete(e)});getSnapshot=()=>this.state;setState(e){this.state=e,this.updateTick+=1;const t=this.updateTick,n=this.listeners.values();let r;for(;r=n.next(),!r.done;){if(t!==this.updateTick)return;(0,r.value)(e)}}update(e){for(const t in e)if(!Object.is(this.state[t],e[t]))return void this.setState((0,y.A)({},this.state,e))}set(e,t){Object.is(this.state[e],t)||this.setState((0,y.A)({},this.state,{[e]:t}))}use=(()=>(e,t,n,r)=>ua(this,e,t,n,r))()}function $a(e,t,n,r,o,i,a){const l=i.length,s=i[t],c=a(n,s,t);if(!c||1===c)return Ha(e,n,t,{spannedByColSpan:!1,cellProps:{colSpan:1,width:s.computedWidth}}),{colSpan:1};let u=s.computedWidth;for(let a=1;a<c;a+=1){const s=t+a;s>=r&&s<o&&(u+=i[s].computedWidth,Ha(e,n,t+a,{spannedByColSpan:!0,rightVisibleCellIndex:Math.min(t+c,l-1),leftVisibleCellIndex:t})),Ha(e,n,t,{spannedByColSpan:!1,cellProps:{colSpan:c,width:u}})}return{colSpan:c}}function Ha(e,t,n,r){let o=e.get(t);o||(o={},e.set(t,o)),o[n]=r}const Ga={initialize:function(e){return{}},use:function(e,t,n){return{getViewportPageSize:()=>{const n=ba.selectors.dimensions(e.state);if(!n.isReady)return 0;if(t.getRowHeight){const n=ka.selectors.renderContext(e.state),r=n.lastRowIndex-n.firstRowIndex;return Math.min(r-1,t.rows.length)}const r=Math.floor(n.viewportInnerSize.height/n.rowHeight);return Math.min(r,t.rows.length)}}},selectors:{}},Va={firstRowIndex:0,lastRowIndex:0},Wa={spannedCells:{},hiddenCells:{},hiddenCellOriginMap:{}},Ua={state:e=>e.rowSpanning,hiddenCells:e=>e.rowSpanning.caches.hiddenCells,spannedCells:e=>e.rowSpanning.caches.spannedCells,hiddenCellsOriginMap:e=>e.rowSpanning.caches.hiddenCellOriginMap},qa={initialize:function(e){return{rowSpanning:e.initialState?.rowSpanning??{caches:Wa,processedRange:Va}}},use:function(e,t,n){return{getHiddenCellsOrigin:()=>Ua.hiddenCellsOriginMap(e.state)}},selectors:Ua},Ya={resizeThrottleMs:100,columns:[{field:"DEFAULT_COLUMN"}],dimensions:{autoHeight:!1,columnsTotalWidth:0,leftPinnedWidth:0,rightPinnedWidth:0,topPinnedHeight:0,bottomPinnedHeight:0},virtualization:{isRtl:!1,rowBufferPx:150,columnBufferPx:150}},Ka=[ba,ka,{initialize:function(e){return{colspanMap:new Map}},use:function(e,t,n){const r=t.colspan?.getColspan,o=(0,Nt.A)(r?(t,n,o,i)=>{for(let a=n;a<o;a+=1){const l=$a(e.state.colspanMap,a,t,n,o,i,r);l.colSpan>1&&(a+=l.colSpan-1)}}:()=>{});return n.calculateColSpan=o,{resetColSpan:()=>{e.state.colspanMap=new Map},getCellColSpanInfo:(t,n)=>e.state.colspanMap.get(t)?.[n],calculateColSpan:o}},selectors:{}},qa,Ga],Ja=e=>{const t=Xa(e,Ya),n=(0,G.A)(()=>new za(Ka.map(e=>e.initialize(t)).reduce((e,t)=>Object.assign(e,t),{}))).current,r={};for(const e of Ka)Object.assign(r,e.use(n,t,r));return{store:n,api:r}};function Xa(e,t){const n=(0,y.A)({},e);for(const r in t)if(Object.hasOwn(t,r)){const o=t[r];null===o||"object"!=typeof o||Array.isArray(o)?n[r]=e[r]??o:n[r]=Xa(e[r]??{},o)}return n}function Za(e){const t=o.useRef(!0);t.current&&(t.current=!1,e())}let el=function(e){return e.DataGrid="DataGrid",e.DataGridPro="DataGridPro",e.DataGridPremium="DataGridPremium",e}({});const tl=(e,t,n)=>t>0&&e>0?Math.ceil(e/t):-1===e?n+2:0,nl=e=>({page:0,pageSize:e?0:100}),rl=(e,t)=>{if(t===el.DataGrid&&e>100)throw new Error(["MUI X: `pageSize` cannot exceed 100 in the MIT version of the DataGrid.","You need to upgrade to DataGridPro or DataGridPremium component to unlock this feature."].join("\n"))},ol=ke(e=>e.pagination),il=Ee(ol,e=>e.enabled&&"client"===e.paginationMode),al=Ee(ol,e=>e.paginationModel),ll=Ee(ol,e=>e.rowCount),sl=Ee(ol,e=>e.meta),cl=Ee(al,e=>e.page),ul=Ee(al,e=>e.pageSize),dl=Ee(al,ll,(e,t)=>tl(t,e.pageSize,e.page)),fl=Ie(il,al,It,Bt,ei,oi,(e,t,n,r,o,i)=>{if(!e)return null;if(!o||0===o.length)return null;const a=i.length,l=Math.min(t.pageSize*t.page,a-1),s=-1===t.pageSize?a-1:Math.min(l+t.pageSize-1,a-1);if(-1===l||-1===s)return null;if(r<2)return{firstRowIndex:l,lastRowIndex:s};const c=i[l],u=s-l+1,d=o.findIndex(e=>e.id===c.id);let f=d,p=0;for(;f<o.length&&p<=u;){const e=o[f],t=n[e.id]?.depth;void 0===t?f+=1:((p<u||t>0)&&(f+=1),0===t&&(p+=1))}return{firstRowIndex:d,lastRowIndex:f-1}}),pl=Ie(ei,fl,(e,t)=>t?e.slice(t.firstRowIndex,t.lastRowIndex+1):[]),hl=Ie(ti,fl,(e,t)=>t?e.slice(t.firstRowIndex,t.lastRowIndex+1):[]),gl=Ie(il,fl,pl,ei,(e,t,n,r)=>e?{rows:n,range:t,rowIdToIndexMap:n.reduce((e,t,n)=>(e.set(t.id,n),e),new Map)}:{rows:r,range:0===r.length?null:{firstRowIndex:0,lastRowIndex:r.length-1},rowIdToIndexMap:r.reduce((e,t,n)=>(e.set(t.id,n),e),new Map)}),ml=(e,t)=>gl(e),Al=(e,t)=>J(e,gl),bl=ke(e=>e.virtualization),vl=(Ee(bl,e=>e.enabled),Ee(bl,e=>e.enabledForColumns)),yl=(Ee(bl,e=>e.enabledForRows),Ee(bl,e=>e.renderContext)),wl=Ie(ke(e=>e.virtualization.renderContext.firstColumnIndex),ke(e=>e.virtualization.renderContext.lastColumnIndex),(e,t)=>({firstColumnIndex:e,lastColumnIndex:t})),Cl=Ie(Ee(Ai,yl,gl,Ve,(e,t,n,r)=>{if(!e)return!1;const o=n.rowIdToIndexMap.get(e.id),i=r.slice(t.firstColumnIndex,t.lastColumnIndex).findIndex(t=>t.field===e.field);return!(void 0!==o&&-1!==i&&o>=t.firstRowIndex&&o<=t.lastRowIndex)}),Ve,gl,Ai,(e,t,n,r)=>{if(!e)return null;const o=n.rowIdToIndexMap.get(r.id);if(void 0===o)return null;const i=t.findIndex(e=>e.field===r.field);return-1===i?null:(0,y.A)({},r,{rowIndex:o,columnIndex:i})});class Sl{constructor(e){this.data=e.ids}has(e){return this.data.has(e)}select(e){this.data.add(e)}unselect(e){this.data.delete(e)}}class xl{constructor(e){this.data=e.ids}has(e){return!this.data.has(e)}select(e){this.data.delete(e)}unselect(e){this.data.add(e)}}const El=e=>"include"===e.type?new Sl(e):new xl(e),Il=ke(e=>e.rowSelection),kl=Ie(Il,El),Rl=Ee(Il,li,(e,t)=>"include"===e.type?e.ids.size:t-e.ids.size),Ml=Ie(Il,Et,_t,(e,t,n)=>{const r=new Map;if("include"===e.type)for(const n of e.ids)r.set(n,t[n]);else for(let o=0;o<n.length;o+=1){const i=n[o];e.ids.has(i)||r.set(i,t[i])}return r}),Pl={autoHeight:!1,autoPageSize:!1,autosizeOnMount:!1,checkboxSelection:!1,checkboxSelectionVisibleOnly:!1,clipboardCopyCellDelimiter:"\t",columnBufferPx:150,columnFilterDebounceMs:150,columnHeaderHeight:56,disableAutosize:!1,disableColumnFilter:!1,disableColumnMenu:!1,disableColumnReorder:!1,disableColumnResize:!1,disableColumnSelector:!1,disableColumnSorting:!1,disableDensitySelector:!1,disableEval:!1,disableMultipleColumnsFiltering:!1,disableMultipleColumnsSorting:!1,disableMultipleRowSelection:!1,dataSourceRevalidateMs:0,disableRowSelectionOnClick:!1,disableRowSelectionExcludeModel:!1,disableVirtualization:!1,editMode:Mr.Cell,filterDebounceMs:150,filterMode:"client",hideFooter:!1,hideFooterPagination:!1,hideFooterRowCount:!1,hideFooterSelectedRowCount:!1,ignoreDiacritics:!1,ignoreValueFormatterDuringExport:!1,keepColumnPositionIfDraggedOutside:!1,keepNonExistentRowsSelected:!1,loading:!1,logger:console,logLevel:"error",pageSizeOptions:[25,50,100],pagination:!1,paginationMode:"client",resizeThrottleMs:60,rowBufferPx:150,rowHeight:52,rows:[],rowSelection:!0,rowSpacingType:"margin",rowSpanning:!1,showCellVerticalBorder:!1,showColumnVerticalBorder:!1,showToolbar:!1,sortingMode:"client",sortingOrder:["asc","desc",null],throttleRowsMs:0,virtualizeColumnsWithAutoRowHeight:!1,tabNavigation:"none"};function Bl(e,t,n){const r=o.useRef(!0);(0,Ut.A)(()=>{r.current=!1,e.current.register(n,t)},[e,n,t]),r.current&&e.current.register(n,t)}const _l=(e,t,n)=>{const r=o.useRef(null),i=o.useRef(`mui-${Math.round(1e9*Math.random())}`),a=o.useCallback(()=>{r.current=e.current.registerPipeApplier(t,i.current,n)},[e,n,t]);Za(()=>{a()});const l=o.useRef(!0);o.useEffect(()=>(l.current?l.current=!1:a(),()=>{r.current&&(r.current(),r.current=null)}),[a])},Tl=(e,t,n)=>{const r=ft(n),o=Ct(n),i=ol(n),a=Math.min(i.enabled?i.paginationModel.pageSize:o,o);return(0,y.A)({},e,{rowsMeta:{currentPageTotalHeight:a*r,positions:Array.from({length:a},(e,t)=>t*r),pinnedTopRowsTotalHeight:0,pinnedBottomRowsTotalHeight:0}})},Ol=Ee(Ve,Ke,(e,t)=>{const n=e.length;return 0===n?0:ea(t[n-1]+e[n-1].computedWidth,1)}),Dl=()=>Ae((e,t,n,r,o)=>(0,y.A)({},e,{headerHeight:t,groupHeaderHeight:n,headerFilterHeight:r,headersTotalHeight:o}),{maxSize:1});const Nl=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"VirtualScroller",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.virtualScroller,n.hasScrollX&&t["virtualScroller--hasScrollX"]]}})({position:"relative",height:"100%",flexGrow:1,overflow:"scroll",scrollbarWidth:"none",display:"flex",flexDirection:"column","&::-webkit-scrollbar":{display:"none"},"@media print":{overflow:"hidden"},zIndex:0}),Ll=e=>e.current.state.dimensions.rightPinnedWidth>0;function Fl(e){const t=Z(),n=se(),i=J(t,ht),a=J(t,pt),l=J(t,Ll),s=J(t,yt),{overlayType:c,loadingOverlayVariant:u}=gi(t,n),d=n.slots?.[c],f={classes:n.classes,hasScrollX:a,hasPinnedRight:l,overlayType:c,loadingOverlayVariant:u},p=(e=>{const{classes:t,hasScrollX:n,hasPinnedRight:r,loadingOverlayVariant:o,overlayType:i}=e,a={root:["main",r&&"main--hasPinnedRight",("skeleton"===o||"noColumnsOverlay"===i)&&"main--hiddenContent"],scroller:["virtualScroller",n&&"virtualScroller--hasScrollX"]};return(0,R.A)(a,D,t)})(f),h=function(){const e=(0,Hr.I)(),t=se(),n=Z(),{listView:i}=t,a=J(n,Ve),l=J(n,Ot),s=qe(n),c=J(n,kl),u=o.useCallback(e=>c.has(e)&&n.current.isRowSelectable(e),[c,n]),d=Al(n),f=J(n,Ze),p=J(n,vt),h=J(n,gt),{autoHeight:g}=t,m=i,A=J(n,Be),b=ar(t.rowHeight,Pl.rowHeight),v=Math.floor(b*A),w=Math.floor(t.columnHeaderHeight*A),C=Math.floor((t.columnGroupHeaderHeight??t.columnHeaderHeight)*A),S=Math.floor((t.headerFilterHeight??t.columnHeaderHeight)*A),x=J(n,Ol),E=Do(n,t),I=s.left.reduce((e,t)=>e+t.computedWidth,0),k=s.right.reduce((e,t)=>e+t.computedWidth,0),R=gi(n,t),M={rowHeight:v,headerHeight:w,columnsTotalWidth:x,leftPinnedWidth:I,rightPinnedWidth:k,topPinnedHeight:E,bottomPinnedHeight:0,autoHeight:g,minimalContentHeight:or,scrollbarSize:t.scrollbarSize},P=(0,G.A)(Dl).current,B=J(n,Ct),_=J(n,ol),T=Math.min(_.enabled?_.paginationModel.pageSize:B,B),{getRowHeight:O,getEstimatedRowHeight:D,getRowSpacing:N}=t,L=t.slots.row,F=t.slotProps?.row,Q=(J(n,Cl),(0,G.A)(()=>new ja({container:n.current.mainElementRef,scroller:n.current.virtualScrollerRef,scrollbarVertical:n.current.virtualScrollbarVerticalRef,scrollbarHorizontal:n.current.virtualScrollbarHorizontalRef})).current),j=Ja({layout:Q,dimensions:M,virtualization:{isRtl:e,rowBufferPx:t.rowBufferPx,columnBufferPx:t.columnBufferPx},colspan:{enabled:f,getColspan:o.useCallback((e,t)=>{if("function"==typeof t.colSpan){const r=n.current.getRow(e),o=n.current.getRowValue(r,t);return t.colSpan(o,r,t,n)??0}return t.colSpan??1},[n])},initialState:{scroll:t.initialState?.scroll,rowSpanning:n.current.state.rowSpanning,virtualization:n.current.state.virtualization},rows:d.rows,range:d.range,rowCount:T,columns:a,pinnedRows:l,pinnedColumns:s,disableHorizontalScroll:i,disableVerticalScroll:"noColumnsOverlay"===R.overlayType||"skeleton"===R.loadingOverlayVariant,getRowHeight:o.useMemo(()=>{if(O)return e=>O((0,y.A)({},e,{densityFactor:A}))},[O,A]),getEstimatedRowHeight:o.useMemo(()=>D?e=>D((0,y.A)({},e,{densityFactor:A})):void 0,[D,A]),getRowSpacing:o.useMemo(()=>N?e=>{const t=d.rowIdToIndexMap.get(e.id)??-1,r={isFirstVisible:0===t,isLastVisible:t===d.rows.length-1,indexRelativeToCurrentPage:t};return N((0,y.A)({},e,r,{indexRelativeToCurrentPage:n.current.getRowIndexRelativeToVisibleRows(e.id)}))}:void 0,[n,N,d.rows,d.rowIdToIndexMap]),applyRowHeight:(0,Nt.A)((e,t)=>n.current.unstable_applyPipeProcessors("rowHeight",e,t)),virtualizeColumnsWithAutoRowHeight:t.virtualizeColumnsWithAutoRowHeight,focusedVirtualCell:(0,Nt.A)(()=>Cl(n)),resizeThrottleMs:t.resizeThrottleMs,onResize:(0,Nt.A)(e=>n.current.publishEvent("resize",e)),onWheel:(0,Nt.A)(e=>{n.current.publishEvent("virtualScrollerWheel",{},e)}),onTouchMove:(0,Nt.A)(e=>{n.current.publishEvent("virtualScrollerTouchMove",{},e)}),onRenderContextChange:(0,Nt.A)(e=>{n.current.publishEvent("renderedRowsIntervalChange",e)}),onScrollChange:o.useCallback((e,t)=>{n.current.publishEvent("scrollPositionChange",{top:e.top,left:e.left,renderContext:t})},[n]),scrollReset:m,renderRow:o.useCallback(e=>(0,r.jsx)(L,(0,y.A)({row:e.model,rowId:e.id,index:e.rowIndex,selected:u(e.id),offsetLeft:e.offsetLeft,columnsTotalWidth:x,rowHeight:e.baseRowHeight,pinnedColumns:s,visibleColumns:a,firstColumnIndex:e.firstColumnIndex,lastColumnIndex:e.lastColumnIndex,focusedColumnIndex:e.focusedColumnIndex,isFirstVisible:e.isFirstVisible,isLastVisible:e.isLastVisible,isNotVisible:e.isVirtualFocusRow,showBottomBorder:e.showBottomBorder,scrollbarWidth:p,gridHasFiller:h},F),e.id),[x,h,u,s,L,F,p,a]),renderInfiniteLoadingTrigger:o.useCallback(e=>n.current.getInfiniteLoadingTriggerElement?.({lastRowId:e}),[n])});return Za(()=>{n.current.store.state.dimensions=P(j.store.state.dimensions,w,C,S,E),n.current.store.state.rowsMeta=j.store.state.rowsMeta,n.current.store.state.virtualization=j.store.state.virtualization}),na(j.store,ba.selectors.dimensions,(e,t)=>{t.isReady&&n.current.setState(e=>(0,y.A)({},e,{dimensions:P(t,w,C,S,E)}))}),na(j.store,ba.selectors.rowsMeta,(e,t)=>{t!==n.current.state.rowsMeta&&n.current.setState(e=>(0,y.A)({},e,{rowsMeta:t}))}),na(j.store,ka.selectors.store,(e,t)=>{t.renderContext!==Ea&&t!==n.current.state.virtualization&&n.current.setState(e=>(0,y.A)({},e,{virtualization:t}))}),n.current.register("private",{virtualizer:j}),(e=>{const t=e.current.virtualizer,{getRowHeight:n,setLastMeasuredRowIndex:r,storeRowHeightMeasurement:o,resetRowHeights:i,hydrateRowsMeta:a,observeRowHeight:l,rowHasAutoHeight:s,getRowHeightEntry:c,getLastMeasuredRowIndex:u}=t.api.rowsMeta;_l(e,"rowHeight",a);const d={hydrateRowsMeta:a,observeRowHeight:l,rowHasAutoHeight:s,getRowHeightEntry:c,getLastMeasuredRowIndex:u};Bl(e,{unstable_getRowHeight:n,unstable_setLastMeasuredRowIndex:r,unstable_storeRowHeightMeasurement:o,resetRowHeights:i},"public"),Bl(e,d,"private")})(n),j}().api.getters,{getContainerProps:g,getScrollerProps:m,getContentProps:A,getPositionerProps:b,getScrollbarVerticalProps:v,getScrollbarHorizontalProps:w,getRows:C,getScrollAreaProps:S}=h,x=C(void 0,It(t));return(0,r.jsxs)(Ri,(0,y.A)({className:p.root},g(),{ownerState:f,children:[(0,r.jsx)($o,(0,y.A)({scrollDirection:"left"},S())),(0,r.jsx)($o,(0,y.A)({scrollDirection:"right"},S())),(0,r.jsx)($o,(0,y.A)({scrollDirection:"up"},S())),(0,r.jsx)($o,(0,y.A)({scrollDirection:"down"},S())),(0,r.jsxs)(Nl,(0,y.A)({className:p.scroller},m(),{ownerState:f,children:[(0,r.jsxs)(Pi,{children:[!n.listView&&(0,r.jsx)(Ei,{}),(0,r.jsx)(n.slots.pinnedRows,{position:"top",virtualScroller:h})]}),c&&(0,r.jsx)(Zi,{overlayType:c,loadingOverlayVariant:u,children:(0,r.jsx)(d,(0,y.A)({},n.slotProps?.[c]))}),(0,r.jsx)(Ti,(0,y.A)({},A(),{children:(0,r.jsxs)(zi,(0,y.A)({role:"rowgroup"},b(),{children:[x,(0,r.jsx)(n.slots.detailPanels,{virtualScroller:h})]}))})),s&&(0,r.jsx)(Qi,{rowsLength:x.length}),(0,r.jsx)(n.slots.bottomContainer,{children:(0,r.jsx)(n.slots.pinnedRows,{position:"bottom",virtualScroller:h})})]})),a&&(0,r.jsxs)(o.Fragment,{children:[n.pinnedColumnsSectionSeparator?.endsWith("shadow")&&(0,r.jsx)(Ki,{position:"horizontal"}),(0,r.jsx)(qi,(0,y.A)({position:"horizontal"},w()))]}),i&&(0,r.jsxs)(o.Fragment,{children:[n.pinnedRowsSectionSeparator?.endsWith("shadow")&&(0,r.jsx)(Ki,{position:"vertical"}),(0,r.jsx)(qi,(0,y.A)({position:"vertical"},v()))]}),a&&i&&(0,r.jsx)(Ui,{"aria-hidden":"true"}),e.children]}))}function Ql(){const e=se();return e.hideFooter?null:(0,r.jsx)(e.slots.footer,(0,y.A)({},e.slotProps?.footer))}const jl=["className","children","sidePanel"],zl=S(function(e,t){const n=se(),{className:i,children:a,sidePanel:l}=e,s=(0,x.A)(e,jl),c=Z(),u=J(c,Pe),d=c.current.rootElementRef,f=o.useCallback(e=>{null!==e&&c.current.publishEvent("rootMount",e)},[c]),p=(0,I.A)(d,t,f),h=n,g=((e,t)=>{const{autoHeight:n,classes:r,showCellVerticalBorder:o}=e,i={root:["root",n&&"autoHeight",`root--density${(0,k.A)(t)}`,null===e.slots.toolbar&&"root--noToolbar","withBorderColor",o&&"withVerticalBorder"]};return(0,R.A)(i,D,r)})(h,u),m=o.useContext(de);return(0,H.useSyncExternalStore)(_e,Te,Oe)?null:(0,r.jsxs)(ne,(0,y.A)({className:(0,E.A)(g.root,i,m.className,l&&L.withSidePanel),ownerState:h},s,{ref:p,children:[(0,r.jsxs)("div",{className:L.mainContent,role:"presentation",children:[(0,r.jsx)(ct,{}),(0,r.jsx)(Fl,{children:a}),(0,r.jsx)(Ql,{})]}),l,m.tag]}))}),$l=B(zl);function Hl(e,t){const n=It(e),r=Vo(e),o=Zo(e),i=n[t];if(!i||"group"!==i.type)return[];const a=[];for(let l=r.findIndex(e=>e===t)+1;l<r.length&&n[r[l]]?.depth>i.depth;l+=1){const t=r[l];!1!==o[t]&&e.current.isRowSelectable(t)&&a.push(t)}return a}const Gl=Ee($e,It,Zo,kl,Et,sr,(e,t,n,r,o,i,{groupId:a,autoSelectParents:l})=>{const s=t[a],c={id:a,row:o[a],columns:e};let u=!0;if("function"==typeof i&&o[a]&&(u=i(c)),!s||"group"!==s.type||r.has(a))return{isIndeterminate:!1,isChecked:r.has(a),isSelectable:u};let d=!1,f=!1;const p=a=>{if(!1===n[a]||d&&f)return;const l=t[a];"group"===l?.type&&l.children.forEach(p);const s={id:a,row:o[a],columns:e};("function"!=typeof i||!o[a]||i(s))&&(r.has(a)?d=!0:f=!0)};return p(a),{isIndeterminate:d&&f,isChecked:!!l&&d&&!f,isSelectable:u}});function Vl(e){return e.signature===el.DataGrid?e.checkboxSelection&&!0!==e.disableMultipleRowSelection:!e.disableMultipleRowSelection}const Wl=(e,t,n,r,o,i,a=kl(e))=>{const l=Zo(e),s=new Set([]);if((r||o)&&!1!==l[n]){if(r){const r=t[n];"group"===r?.type&&Hl(e,n).forEach(e=>{i(e),s.add(e)})}if(o){const r=n=>{const o=t[n];return!!o&&("group"!==o.type?!e.current.isRowSelectable(n)||a.has(n)||s.has(n):!(!a.has(n)&&!s.has(n))||o.children.every(r))},o=n=>{const a=((e,t,n)=>{const r=e[n];if(!r)return[];const o=r.parent;return null==o?[]:e[o].children.filter(e=>e!==n&&!1!==t[e])})(t,l,n),c=a.every(t=>!e.current.isRowSelectable(t)||r(t));if(0===a.length||c){const r=t[n],a=r?.parent;null!=a&&a!==Un&&e.current.isRowSelectable(a)&&(i(a),s.add(a),o(a))}},c=t[n];if(!c||c.parent===Un)return;o(n)}}},Ul=(e,t,n,r,o,i)=>{const a=kl(e);if(o||r){if(o){const e=((e,t)=>{const n=[];let r=t;for(;null!=r&&r!==Un;){const t=e[r];if(!t)return n;n.push(r),r=t.parent}return n})(t,n);e.forEach(e=>{a.has(e)&&i(e)})}if(r){const r=t[n];"group"===r?.type&&Hl(e,n).forEach(e=>{i(e)})}}};function ql({privateApiRef:e,configuration:t,props:n,children:i}){const a=o.useRef(e.current.getPublicApi());return(0,r.jsx)(ce.Provider,{value:t,children:(0,r.jsx)(le.Provider,{value:n,children:(0,r.jsx)(X.Provider,{value:e,children:(0,r.jsx)(rt.Provider,{value:a,children:(0,r.jsx)(lt,{children:(0,r.jsx)(pe,{children:i})})})})})})}const Yl=function(){try{const e="__some_random_key_you_are_not_going_to_use__";return window.localStorage.setItem(e,e),window.localStorage.removeItem(e),!0}catch(e){return!1}}()&&null!=window.localStorage.getItem("DEBUG"),Kl=()=>{},Jl={debug:Kl,info:Kl,warn:Kl,error:Kl},Xl=["debug","info","warn","error"];function Zl(e,t,n=console){const r=Xl.indexOf(t);if(-1===r)throw new Error(`MUI X: Log level ${t} not recognized.`);return Xl.reduce((t,o,i)=>(t[o]=i>=r?(...t)=>{const[r,...i]=t;n[o](`MUI X: ${e} - ${r}`,...i)}:Kl,t),{})}function es(e){return es="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},es(e)}function ts(e){var t=function(e){if("object"!=es(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=es(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==es(t)?t:t+""}let ns=function(e){return e.DataSource="dataSource",e.RowTree="rowTree",e}({});const rs="none",os={dataSourceRowsUpdate:ns.DataSource,rowTreeCreation:ns.RowTree,filtering:ns.RowTree,sorting:ns.RowTree,visibleRowsLookupCreation:ns.RowTree},is=(e,t)=>(0,y.A)({},e,{props:{listView:t.listView,getRowId:t.getRowId,isCellEditable:t.isCellEditable,isRowSelectable:t.isRowSelectable,dataSource:t.dataSource}}),as=(e,t,n,r)=>{const i=o.useRef(r),a=o.useRef(!1);r!==i.current&&(a.current=!1,i.current=r),a.current||(t.current.state=e(t.current.state,n,t),a.current=!0)};function ls(e,t){const n=o.useRef(null);if(n.current)return n.current;const r=e.current.getLogger(t);return n.current=r,r}const ss=(e,t,n,r,o)=>{const i=ls(e,"useNativeEventListener");Gt(e,"rootMount",()=>{const e=t();if(e&&n)return i.debug(`Binding native ${n} event`),e.addEventListener(n,r,o),()=>{i.debug(`Clearing native ${n} event`),e.removeEventListener(n,r,o)}})},cs=["field","id","formattedValue","row","rowNode","colDef","isEditable","cellMode","hasFocus","tabIndex","api"],us=S(function(e,t){const{field:n,id:i,rowNode:a,tabIndex:l}=e,s=(0,x.A)(e,cs),c=ot(),u=se(),d=(e=>{const{classes:t}=e;return(0,R.A)({root:["checkboxInput"]},D,t)})({classes:u.classes}),{isIndeterminate:f,isChecked:p,isSelectable:h}=J(c,Gl,{groupId:i,autoSelectParents:u.rowSelectionPropagation?.parents??!1},W),g=!h;o.useLayoutEffect(()=>{if(0===l&&!g){const e=c.current.getCellElement(i,n);e&&(e.tabIndex=-1)}},[c,l,i,n,g]);const m=(0,Nt.A)(e=>{" "===e.key&&e.stopPropagation()}),A=(0,Nt.A)(e=>{g&&e.preventDefault()}),b=(0,Nt.A)(()=>{});if("footer"===a.type||"pinnedRow"===a.type)return null;const v=c.current.getLocaleText(p&&!f?"checkboxSelectionUnselectRow":"checkboxSelectionSelectRow");return(0,r.jsx)(u.slots.baseCheckbox,(0,y.A)({tabIndex:g?-1:l,checked:p&&!f,onChange:e=>{if(g)return;const t={value:e.target.checked,id:i};c.current.publishEvent("rowSelectionCheckboxChange",t,e)},onClick:A,onMouseDown:b,className:(0,E.A)(d.root,g&&"Mui-disabled"),disabled:g,material:{disableRipple:g},slotProps:{htmlInput:{"aria-disabled":g||void 0,"aria-label":v,name:"select_row"}},onKeyDown:m,indeterminate:f},u.slotProps?.baseCheckbox,s,{ref:t}))}),ds=us,fs=["field","colDef"],ps=S(function(e,t){const n=(0,x.A)(e,fs),[,i]=o.useState(!1),a=ot(),l=se(),s=(e=>{const{classes:t}=e;return(0,R.A)({root:["checkboxInput"]},D,t)})({classes:l.classes}),c=J(a,Ci),u=J(a,Il),d=J(a,ti),f=J(a,hl),p=o.useMemo(()=>{const e=l.isRowSelectable;if("function"!=typeof e)return u;if("exclude"===u.type)return u;const t={type:"include",ids:new Set};for(const n of u.ids)l.keepNonExistentRowsSelected&&t.ids.add(n),a.current.getRow(n)&&e(a.current.getRowParams(n))&&t.ids.add(n);return t},[a,l.isRowSelectable,l.keepNonExistentRowsSelected,u]),h=o.useMemo(()=>{const e=l.pagination&&l.checkboxSelectionVisibleOnly&&"server"!==l.paginationMode?f:d,t=new Set;for(let n=0;n<e.length;n+=1){const r=e[n];a.current.getRow(r)&&a.current.isRowSelectable(r)&&t.add(r)}return t},[a,l.pagination,l.paginationMode,l.checkboxSelectionVisibleOnly,f,d]),g=o.useMemo(()=>{const e=El(p);let t=0;for(const n of h)e.has(n)&&(t+=1);return t},[p,h]),m=o.useMemo(()=>{if(0===g)return!1;const e=El(p);for(const t of h)if(!e.has(t))return!0;return!1},[g,p,h]),A=g>0,b=Vl(l),v=null!==c&&c.field===e.field&&b?0:-1;(0,Ut.A)(()=>{const t=a.current.getColumnHeaderElement(e.field);0===v&&t&&b&&(t.tabIndex=-1)},[v,a,e.field,b]);const w=o.useCallback(e=>{" "===e.key&&a.current.publishEvent("headerSelectionCheckboxChange",{value:!A})},[a,A]),C=o.useCallback(()=>{i(e=>!e)},[]);o.useEffect(()=>a.current.subscribeEvent("rowSelectionChange",C),[a,C]);const S=a.current.getLocaleText(A&&!m?"checkboxSelectionUnselectAllRows":"checkboxSelectionSelectAllRows");return(0,r.jsx)(l.slots.baseCheckbox,(0,y.A)({indeterminate:m,checked:A&&!m,onChange:e=>{const t={value:e.target.checked};a.current.publishEvent("headerSelectionCheckboxChange",t)},className:s.root,slotProps:{htmlInput:{"aria-label":S,name:"select_all_rows"}},tabIndex:v,onKeyDown:w,disabled:!b},l.slotProps?.baseCheckbox,n,{ref:t}))}),hs="__check__",gs=(0,y.A)({},Ir,{type:"custom",field:hs,width:50,resizable:!1,sortable:!1,filterable:!1,aggregable:!1,chartable:!1,disableColumnMenu:!0,disableReorder:!0,disableExport:!0,getApplyQuickFilterFn:()=>null,display:"flex",valueGetter:(e,t,n,r)=>{const o=lr(r,t);return r.current.isRowSelected(o)},rowSpanValueGetter:(e,t,n,r)=>lr(r,t),renderHeader:e=>(0,r.jsx)(ps,(0,y.A)({},e)),renderCell:e=>(0,r.jsx)(ds,(0,y.A)({},e))});function ms(e,t){if(null==e)return"";const n="string"==typeof e?e:`${e}`;if(t.shouldAppendQuotes||t.escapeFormulas){const e=n.replace(/"/g,'""');return t.escapeFormulas&&["=","+","-","@","\t","\r"].includes(e[0])?`"'${e}"`:[t.delimiter,"\n","\r",'"'].some(e=>n.includes(e))?`"${e}"`:e}return n}const As=(e,t)=>{const{csvOptions:n,ignoreValueFormatter:r}=t;let o;if(r){const t=e.colDef.type;o="number"===t?String(e.value):"date"===t||"dateTime"===t?e.value?.toISOString():"function"==typeof e.value?.toString?e.value.toString():e.value}else o=e.formattedValue;return ms(o,n)};class bs{rowString="";isEmpty=!0;constructor(e){this.options=e}addValue(e){this.isEmpty||(this.rowString+=this.options.csvOptions.delimiter),"function"==typeof this.options.sanitizeCellValue?this.rowString+=this.options.sanitizeCellValue(e,this.options.csvOptions):this.rowString+=e,this.isEmpty=!1}getRowString(){return this.rowString}}function vs(e){const t=document.createElement("span");t.style.whiteSpace="pre",t.style.userSelect="all",t.style.opacity="0px",t.textContent=e,document.body.appendChild(t);const n=document.createRange();n.selectNode(t);const r=window.getSelection();r.removeAllRanges(),r.addRange(n);try{document.execCommand("copy")}finally{document.body.removeChild(t)}}const ys=e=>(0,y.A)({},e,{columnMenu:{open:!1}}),ws=(e,t,n,r=!0)=>{const i=o.useRef(null),a=o.useRef(`mui-${Math.round(1e9*Math.random())}`),l=o.useCallback(()=>{i.current=e.current.registerPipeProcessor(t,a.current,n)},[e,n,t]);Za(()=>{r&&l()});const s=o.useRef(!0);o.useEffect(()=>(s.current?s.current=!1:r&&l(),()=>{i.current&&(i.current(),i.current=null)}),[l,r])},Cs=(e,t,n)=>{n.current.caches.columns={lastColumnsProp:t.columns};const r=Oo({apiRef:n,columnsToUpsert:t.columns,initialState:t.initialState?.columns,columnVisibilityModel:t.columnVisibilityModel??t.initialState?.columns?.columnVisibilityModel??{},keepOnlyColumnsToUpsert:!0});return(0,y.A)({},e,{columns:r,pinnedColumns:e.pinnedColumns??Ne})};const Ss=(e,t)=>(0,y.A)({},e,{density:t.initialState?.density??t.density??"standard"}),xs=({apiRef:e,options:t})=>{const n=$e(e);return t.fields?t.fields.reduce((e,t)=>{const r=n.find(e=>e.field===t);return r&&e.push(r),e},[]):(t.allColumns?n:Ve(e)).filter(e=>!0!==e.disableExport)},Es=({apiRef:e})=>{const t=ri(e),n=It(e),r=Rl(e),o=t.filter(e=>"footer"!==n[e].type),i=Ot(e),a=i?.top?.map(e=>e.id)||[],l=i?.bottom?.map(e=>e.id)||[];if(o.unshift(...a),o.push(...l),r>0){const t=Ml(e);return o.filter(e=>t.has(e))}return o},Is=S(function(e,t){const{children:n,slotProps:i={}}=e,a=i.button||{},l=i.tooltip||{},s=ot(),c=se(),u=(0,an.A)(),d=(0,an.A)(),[f,p]=o.useState(!1),h=o.useRef(null),g=(0,I.A)(t,h),m=()=>p(!1);return null==n?null:(0,r.jsxs)(o.Fragment,{children:[(0,r.jsx)(c.slots.baseTooltip,(0,y.A)({title:s.current.getLocaleText("toolbarExportLabel"),enterDelay:1e3},c.slotProps?.baseTooltip,l,{children:(0,r.jsx)(c.slots.baseButton,(0,y.A)({size:"small",startIcon:(0,r.jsx)(c.slots.exportIcon,{}),"aria-expanded":f,"aria-label":s.current.getLocaleText("toolbarExportLabel"),"aria-haspopup":"menu","aria-controls":f?d:void 0,id:u},c.slotProps?.baseButton,a,{onClick:e=>{p(e=>!e),a.onClick?.(e)},ref:g,children:s.current.getLocaleText("toolbarExport")}))})),(0,r.jsx)(Kr,{open:f,target:h.current,onClose:m,position:"bottom-end",children:(0,r.jsx)(c.slots.baseMenuList,{id:d,className:L.menuList,"aria-labelledby":u,autoFocusItem:f,children:o.Children.map(n,e=>o.isValidElement(e)?o.cloneElement(e,{hideMenu:m}):e)})})]})}),ks=["hideMenu","options"],Rs=["hideMenu","options"],Ms=["csvOptions","printOptions","excelOptions"];function Ps(e){const t=ot(),n=se(),{hideMenu:o,options:i}=e,a=(0,x.A)(e,ks);return(0,r.jsx)(n.slots.baseMenuItem,(0,y.A)({onClick:()=>{t.current.exportDataAsCsv(i),o?.()}},a,{children:t.current.getLocaleText("toolbarExportCSV")}))}function Bs(e){const t=ot(),n=se(),{hideMenu:o,options:i}=e,a=(0,x.A)(e,Rs);return(0,r.jsx)(n.slots.baseMenuItem,(0,y.A)({onClick:()=>{t.current.exportDataAsPrint(i),o?.()}},a,{children:t.current.getLocaleText("toolbarExportPrint")}))}S(function(e,t){const n=e,{csvOptions:i={},printOptions:a={},excelOptions:l}=n,s=(0,x.A)(n,Ms),c=ot().current.unstable_applyPipeProcessors("exportMenu",[],{excelOptions:l,csvOptions:i,printOptions:a}).sort((e,t)=>e.componentName>t.componentName?1:-1);return 0===c.length?null:(0,r.jsx)(Is,(0,y.A)({},s,{ref:t,children:c.map((e,t)=>o.cloneElement(e.component,{key:t}))}))});const _s=(e,t)=>{const n=ls(e,"useGridCsvExport"),i=t.ignoreValueFormatterDuringExport,a=("object"==typeof i?i?.csvExport:i)||!1,l=o.useCallback((t={})=>(n.debug("Get data as CSV"),function(e){const{columns:t,rowIds:n,csvOptions:r,ignoreValueFormatter:o,apiRef:i}=e,a=n.reduce((e,n)=>`${e}${(({id:e,columns:t,getCellParams:n,csvOptions:r,ignoreValueFormatter:o})=>{const i=new bs({csvOptions:r});return t.forEach(t=>{const a=n(e,t.field);String(a.formattedValue),i.addValue(As(a,{ignoreValueFormatter:o,csvOptions:r}))}),i.getRowString()})({id:n,columns:t,getCellParams:i.current.getCellParams,ignoreValueFormatter:o,csvOptions:r})}\r\n`,"").trim();if(!r.includeHeaders)return a;const l=t.filter(e=>e.field!==gs.field),s=[];if(r.includeColumnGroupsHeaders){const e=i.current.getAllGroupDetails();let t=0;const n=l.reduce((e,n)=>{const r=i.current.getColumnGroupPath(n.field);return e[n.field]=r,t=Math.max(t,r.length),e},{});for(let o=0;o<t;o+=1){const t=new bs({csvOptions:r,sanitizeCellValue:ms});s.push(t),l.forEach(r=>{const i=(n[r.field]||[])[o],a=e[i];t.addValue(a?a.headerName||a.groupId:"")})}}const c=new bs({csvOptions:r,sanitizeCellValue:ms});return l.forEach(e=>{c.addValue(e.headerName||e.field)}),s.push(c),`${s.map(e=>e.getRowString()).join("\r\n")}\r\n${a}`.trim()}({columns:xs({apiRef:e,options:t}),rowIds:(t.getRowsToExport??Es)({apiRef:e}),csvOptions:{delimiter:t.delimiter||",",shouldAppendQuotes:t.shouldAppendQuotes??!0,includeHeaders:t.includeHeaders??!0,includeColumnGroupsHeaders:t.includeColumnGroupsHeaders??!0,escapeFormulas:t.escapeFormulas??!0},ignoreValueFormatter:a,apiRef:e})),[n,e,a]),s=o.useCallback(e=>{n.debug("Export data as CSV");const t=l(e);!function(e,t="csv",n=document.title||"untitled"){const r=`${n}.${t}`;if("download"in HTMLAnchorElement.prototype){const t=URL.createObjectURL(e),n=document.createElement("a");return n.href=t,n.download=r,n.click(),void setTimeout(()=>{URL.revokeObjectURL(t)})}throw new Error("MUI X: exportAs not supported.")}(new Blob([e?.utf8WithBom?new Uint8Array([239,187,191]):"",t],{type:"text/csv"}),"csv",e?.fileName)},[n,l]);Bl(e,{getDataAsCsv:l,exportDataAsCsv:s},"public");const c=o.useCallback((e,t)=>t.csvOptions?.disableToolbarButton?e:[...e,{component:(0,r.jsx)(Ps,{options:t.csvOptions}),componentName:"csvExport"}],[]);ws(e,"exportMenu",c)};var Ts=n(3075);const Os=(e,t,n)=>{let r=e.paginationModel;const o=e.rowCount,i=n?.pageSize??r.pageSize,a=n?.page??r.page,l=tl(o,i,a);!n||n?.page===r.page&&n?.pageSize===r.pageSize||(r=n);const s=-1===i?0:((e,t=0)=>0===t?e:Math.max(Math.min(e,t-1),0))(r.page,l);return s!==r.page&&(r=(0,y.A)({},r,{page:s})),rl(r.pageSize,t),r},Ds=(e,t,n,r)=>{const i=o.useCallback(()=>{e.current.registerStrategyProcessor(t,n,r)},[e,r,n,t]);Za(()=>{i()});const a=o.useRef(!0);o.useEffect(()=>{a.current?a.current=!1:i()},[i])},Ns=(e,t,n)=>{const r=t.filterModel??t.initialState?.filter?.filterModel??vn();return(0,y.A)({},e,{filter:(0,y.A)({filterModel:Sn(r,t.disableMultipleColumnsFiltering,n)},bn),visibleRowsLookup:{}})},Ls=e=>e.filteredRowsLookup;function Fs(e,t){return e.current.applyStrategyProcessor("visibleRowsLookupCreation",{tree:t.rows.tree,filteredRowsLookup:t.filter.filteredRowsLookup})}function Qs(){return Ae(Object.values)}let js;function zs(){return void 0===js&&document.createElement("div").focus({get preventScroll(){return js=!0,!1}}),js}const $s=e=>(0,y.A)({},e,{focus:{cell:null,columnHeader:null,columnHeaderFilter:null,columnGroupHeader:null},tabIndex:{cell:null,columnHeader:null,columnHeaderFilter:null,columnGroupHeader:null}});function Hs(e,t){return e.closest(`.${t}`)}function Gs(e){return e.replace(/["\\]/g,"\\$&")}function Vs(e){return`.${L.row}[data-id="${Gs(String(e))}"]`}function Ws(e){return 1===e.target.nodeType&&!e.currentTarget.contains(e.target)}function Us(e,t){return e.rootElementRef.current.querySelector(`.${L[t]}`)}const qs=({api:e,colIndex:t,position:n,filterFn:r})=>{if(null===t)return[];const o=[];return Ks(e).forEach(e=>{e.getAttribute("data-id")&&e.querySelectorAll(`.${L["left"===n?"cell--pinnedLeft":"cell--pinnedRight"]}`).forEach(e=>{const t=Js(e);null!==t&&r(t)&&o.push(e)})}),o},Ys=({api:e,colIndex:t,position:n,filterFn:r})=>{if(!e.columnHeadersContainerRef?.current)return[];if(null===t)return[];const o=[];return e.columnHeadersContainerRef.current.querySelectorAll(`.${L["left"===n?"columnHeader--pinnedLeft":"columnHeader--pinnedRight"]}`).forEach(e=>{const t=Js(e);null!==t&&r(t,e)&&o.push(e)}),o};function Ks(e){return e.virtualScrollerRef.current.querySelectorAll(`:scope > div > div > .${L.row}`)}function Js(e){const t=e.getAttribute("aria-colindex");return t?Number(t)-1:null}const Xs=({currentColIndex:e,firstColIndex:t,lastColIndex:n,isRtl:r})=>{if(r){if(e<n)return e+1}else if(!r&&e>t)return e-1;return null},Zs=({currentColIndex:e,firstColIndex:t,lastColIndex:n,isRtl:r})=>{if(r){if(e>t)return e-1}else if(!r&&e<n)return e+1;return null},ec=Ie(gl,Ot,(e,t)=>(t.top||[]).concat(e.rows,t.bottom||[])),tc=(e,t)=>{const n=(0,y.A)({},nl(t.autoPageSize),t.paginationModel??t.initialState?.pagination?.paginationModel);rl(n.pageSize,t.signature);const r=t.rowCount??t.initialState?.pagination?.rowCount??("client"===t.paginationMode?e.rows?.totalRowCount:void 0),o=t.paginationMeta??t.initialState?.pagination?.meta??{};return(0,y.A)({},e,{pagination:(0,y.A)({},e.pagination,{paginationModel:n,rowCount:r,meta:o,enabled:!0===t.pagination,paginationMode:t.paginationMode})})},nc=(e,t)=>(0,y.A)({},e,{preferencePanel:t.initialState?.preferencePanel??{open:!1}}),rc=ke(e=>e.editRows),oc=Ee(rc,(e,{rowId:t,editMode:n})=>n===Mr.Row&&Boolean(e[t])),ic=Ee(rc,(e,{rowId:t,field:n})=>e[t]?.[n]??null),ac=e=>{switch(e.type){case"boolean":return!1;case"date":case"dateTime":case"number":return;case"singleSelect":return null;default:return""}},lc=["id","field"],sc=["id","field"];var cc=function(e){return e.enterKeyDown="enterKeyDown",e.cellDoubleClick="cellDoubleClick",e.printableKeyDown="printableKeyDown",e.deleteKeyDown="deleteKeyDown",e}(cc||{}),uc=function(e){return e.rowFocusOut="rowFocusOut",e.escapeKeyDown="escapeKeyDown",e.enterKeyDown="enterKeyDown",e.tabKeyDown="tabKeyDown",e.shiftTabKeyDown="shiftTabKeyDown",e}(uc||{});const dc=["id"],fc=["id"],pc=e=>(0,y.A)({},e,{editRows:{}}),hc=(e,t,n)=>{const r=!!t.dataSource;return n.current.caches.rows=Jn({rows:r?[]:t.rows,getRowId:t.getRowId,loading:t.loading,rowCount:t.rowCount}),(0,y.A)({},e,{rows:Zn({apiRef:n,rowCountProp:t.rowCount,loadingProp:!!r||t.loading,previousTree:null,previousTreeDepths:null})})},gc=e=>"full"===e.updates.type?(e=>{const t={[Un]:(0,y.A)({},{type:"group",id:Un,depth:-1,groupingField:null,groupingKey:null,isAutoGenerated:!0,children:[],childrenFromPath:Object.create(null),childrenExpanded:!0,parent:null},{children:e})};for(let n=0;n<e.length;n+=1){const r=e[n];t[r]={id:r,depth:0,parent:Un,type:"leaf",groupingKey:null}}return{groupingName:rs,tree:t,treeDepths:{0:e.length},dataRowIds:e}})(e.updates.rows):(({previousTree:e,actions:t})=>{const n=(0,y.A)({},e),r={};for(let e=0;e<t.remove.length;e+=1){const o=t.remove[e];r[o]=!0,delete n[o]}for(let e=0;e<t.insert.length;e+=1){const r=t.insert[e];n[r]={id:r,depth:0,parent:Un,type:"leaf",groupingKey:null}}const o=n[Un];let i=[...o.children,...t.insert];return Object.values(r).length&&(i=i.filter(e=>!r[e])),n[Un]=(0,y.A)({},o,{children:i}),{groupingName:rs,tree:n,treeDepths:{0:i.length},dataRowIds:i}})({previousTree:e.previousTree,actions:e.updates.actions});class mc extends Error{}const Ac={type:"include",ids:new Set},bc=(e,t)=>(0,y.A)({},e,{rowSelection:t.rowSelection?t.rowSelectionModel??Ac:Ac}),vc=(e,t)=>{const n=t.sortModel??t.initialState?.sorting?.sortModel??[];return(0,y.A)({},e,{sorting:{sortModel:Xt(n,t.disableMultipleColumnsSorting),sortedRows:[]}})};function yc(e){const{containerSize:t,scrollPosition:n,elementSize:r,elementOffset:o}=e,i=o+r;return r>t?o:i-t>n?i-t:o<n?o:void 0}const wc={width:0,height:0},Cc={isReady:!1,root:wc,viewportOuterSize:wc,viewportInnerSize:wc,contentSize:wc,minimumSize:wc,hasScrollX:!1,hasScrollY:!1,scrollbarSize:0,headerHeight:0,groupHeaderHeight:0,headerFilterHeight:0,rowWidth:0,rowHeight:0,columnsTotalWidth:0,leftPinnedWidth:0,rightPinnedWidth:0,headersTotalHeight:0,topContainerHeight:0,bottomContainerHeight:0,autoHeight:!1,minimalContentHeight:void 0},Sc=(e,t,n)=>{const r=Cc,o=Be(n),i=(0,y.A)({},r,function(e,t,n,r){const o=ar(e.rowHeight,Pl.rowHeight);return{rowHeight:Math.floor(o*n),headerHeight:Math.floor(e.columnHeaderHeight*n),groupHeaderHeight:Math.floor((e.columnGroupHeaderHeight??e.columnHeaderHeight)*n),headerFilterHeight:Math.floor((e.headerFilterHeight??e.columnHeaderHeight)*n),columnsTotalWidth:xc(t),headersTotalHeight:Do(t,e),leftPinnedWidth:r.left.reduce((e,t)=>e+t.computedWidth,0),rightPinnedWidth:r.right.reduce((e,t)=>e+t.computedWidth,0)}}(t,n,o,qe(n)));return n.current.store.state.dimensions=i,(0,y.A)({},e,{dimensions:i})},xc=Ee(Ve,Ke,(e,t)=>{const n=e.length;return 0===n?0:ea(t[n-1]+e[n-1].computedWidth,1)});function Ec(e,t){const n=(t,n)=>e.style.setProperty(t,n);n("--DataGrid-hasScrollX",`${Number(t.hasScrollX)}`),n("--DataGrid-hasScrollY",`${Number(t.hasScrollY)}`),n("--DataGrid-scrollbarSize",`${t.scrollbarSize}px`),n("--DataGrid-rowWidth",`${t.rowWidth}px`),n("--DataGrid-columnsTotalWidth",`${t.columnsTotalWidth}px`),n("--DataGrid-leftPinnedWidth",`${t.leftPinnedWidth}px`),n("--DataGrid-rightPinnedWidth",`${t.rightPinnedWidth}px`),n("--DataGrid-headerHeight",`${t.headerHeight}px`),n("--DataGrid-headersTotalHeight",`${t.headersTotalHeight}px`),n("--DataGrid-topContainerHeight",`${t.topContainerHeight}px`),n("--DataGrid-bottomContainerHeight",`${t.bottomContainerHeight}px`),n("--height",`${t.rowHeight}px`)}function Ic(e){return void 0!==e.field}const kc=["groupId","children"],Rc=e=>{const t={};for(let n=0;n<e.length;n+=1){const r=e[n];if(Ic(r))continue;const{groupId:o,children:i}=r,a=(0,x.A)(r,kc);if(!o)throw new Error("MUI X: An element of the columnGroupingModel does not have either `field` or `groupId`.");const l=(0,y.A)({},a,{groupId:o}),s=Rc(i);if(void 0!==s[o]||void 0!==t[o])throw new Error(`MUI X: The groupId ${o} is used multiple times in the columnGroupingModel.`);Object.assign(t,s),t[o]=l}return t},Mc=(e,t,n)=>{if(Ic(e)){if(void 0!==n[e.field])throw new Error(["MUI X: columnGroupingModel contains duplicated field",`column field ${e.field} occurs two times in the grouping model:`,`- ${n[e.field].join(" > ")}`,`- ${t.join(" > ")}`].join("\n"));return void(n[e.field]=t)}const{groupId:r,children:o}=e;o.forEach(e=>{Mc(e,[...t,r],n)})},Pc=e=>{if(!e)return{};const t={};return e.forEach(e=>{Mc(e,[],t)}),t},Bc=(e,t,n)=>{const r=e=>t[e]??[],o=[],i=Math.max(0,...e.map(e=>r(e).length)),a=(e,t,n)=>{const o=r(e),i=r(t);for(let e=0;e<=n;e+=1)if(o[e]!==i[e])return!1;return!0},l=(e,t)=>{const r=n?.left,o=n?.right,i=!!r?.includes(e),a=!!r?.includes(t),l=!!o?.includes(e),s=!!o?.includes(t);return i!==a||l!==s};for(let t=0;t<i;t+=1){const n=[];for(let o=0;o<e.length;o+=1){const i=e[o],s=r(i)[t]??null;if(0===n.length){n.push({columnFields:[i],groupId:s});continue}const c=n[n.length-1],u=c.columnFields[c.columnFields.length-1];c.groupId!==s||!a(u,i,t)||l(u,i)?n.push({columnFields:[i],groupId:s}):c.columnFields.push(i)}o.push(n)}return o},_c=(e,t,n)=>{if(n.current.caches.columnGrouping={lastColumnGroupingModel:t.columnGroupingModel},!t.columnGroupingModel)return(0,y.A)({},e,{columnGrouping:void 0});const r=je(n),o=We(n),i=Rc(t.columnGroupingModel??[]),a=Pc(t.columnGroupingModel??[]),l=Bc(r,a,n.current.state.pinnedColumns??{}),s=0===o.length?0:Math.max(...o.map(e=>a[e]?.length??0));return(0,y.A)({},e,{columnGrouping:{lookup:i,unwrappedGroupingModel:a,headerStructure:l,maxDepth:s}})},Tc=!("undefined"!=typeof window&&/jsdom|HappyDOM/.test(window.navigator.userAgent)),Oc=(e,t)=>{const{disableVirtualization:n,autoHeight:r}=t,o={enabled:!n&&Tc,enabledForColumns:!n&&Tc,enabledForRows:!n&&!r&&Tc,renderContext:Ea};return(0,y.A)({},e,{virtualization:o})},Dc={includeHeaders:!0,includeHeaderFilters:!1,includeOutliers:!1,outliersFactor:1.5,expand:!1,disableColumnVirtualization:!0},Nc=Ee(ke(e=>e.columnResize),e=>e.resizingColumnField);function Lc(e,t){if(void 0!==t&&e.changedTouches){for(let n=0;n<e.changedTouches.length;n+=1){const r=e.changedTouches[n];if(r.identifier===t)return{x:r.clientX,y:r.clientY}}return!1}return{x:e.clientX,y:e.clientY}}function Fc(e,t,n,r){let o=e;return o+="Right"===r?t-n.left:n.right-t,Math.round(o)}function Qc(e,t){return t===De.LEFT?e?"--DataGrid-rightPinnedWidth":"--DataGrid-leftPinnedWidth":e?"--DataGrid-leftPinnedWidth":"--DataGrid-rightPinnedWidth"}function jc(e,t,n){return n===De.LEFT?t?e.rightPinnedWidth:e.leftPinnedWidth:t?e.leftPinnedWidth:e.rightPinnedWidth}function zc(e){e.preventDefault(),e.stopImmediatePropagation()}const $c=e=>(0,y.A)({},e,{columnResize:{resizingColumnField:""}});function Hc(){return{colDef:void 0,initialColWidth:0,initialTotalWidth:0,previousMouseClickEvent:void 0,columnHeaderElement:void 0,headerFilterElement:void 0,groupHeaderElements:[],cellElements:[],leftPinnedCellsAfter:[],rightPinnedCellsBefore:[],fillerLeft:void 0,fillerRight:void 0,leftPinnedHeadersAfter:[],rightPinnedHeadersBefore:[]}}const Gc=(e,t)=>{const n=(0,Hr.I)(),r=ls(e,"useGridColumnResize"),i=(0,G.A)(Hc).current,a=o.useRef(null),l=o.useRef(null),s=(0,Vt.A)(),c=o.useRef(void 0),u=t=>{r.debug(`Updating width to ${t} for col ${i.colDef.field}`);const o=i.columnHeaderElement.offsetWidth,a=t-o,l=t-i.initialColWidth;if(l>0){const t=i.initialTotalWidth+l;e.current.rootElementRef?.current?.style.setProperty("--DataGrid-rowWidth",`${t}px`)}i.colDef.computedWidth=t,i.colDef.width=t,i.colDef.flex=0,i.columnHeaderElement.style.width=`${t}px`;const s=i.headerFilterElement;s&&(s.style.width=`${t}px`),i.groupHeaderElements.forEach(e=>{const n=e;let r;r="1"===n.getAttribute("aria-colspan")?`${t}px`:`${n.offsetWidth+a}px`,n.style.width=r}),i.cellElements.forEach(e=>{const n=e;let r;r="1"===n.getAttribute("aria-colspan")?`${t}px`:`${n.offsetWidth+a}px`,n.style.setProperty("--width",r)});const c=ut(e),u=e.current.unstable_applyPipeProcessors("isColumnPinned",!1,i.colDef.field);u===De.LEFT&&(Vc(i.fillerLeft,"width",a),i.leftPinnedCellsAfter.forEach(e=>{Vc(e,"left",a)}),i.leftPinnedHeadersAfter.forEach(e=>{Vc(e,"left",a)}),e.current.rootElementRef?.current?.style.setProperty(Qc(n,u),`${jc(c,n,u)+l}px`)),u===De.RIGHT&&(Vc(i.fillerRight,"width",a),i.rightPinnedCellsBefore.forEach(e=>{Vc(e,"right",a)}),i.rightPinnedHeadersBefore.forEach(e=>{Vc(e,"right",a)}),e.current.rootElementRef?.current?.style.setProperty(Qc(n,u),`${jc(c,n,u)+l}px`))},d=t=>{if(v(),i.previousMouseClickEvent){const n=i.previousMouseClickEvent,r=n.timeStamp,o=n.clientX,a=n.clientY;if(t.timeStamp-r<300&&t.clientX===o&&t.clientY===a)return i.previousMouseClickEvent=void 0,void e.current.publishEvent("columnResizeStop",null,t)}if(i.colDef){e.current.setColumnWidth(i.colDef.field,i.colDef.width),r.debug(`Updating col ${i.colDef.field} with new width: ${i.colDef.width}`);const t=Qe(e);i.groupHeaderElements.forEach(e=>{const n=e,r=`${e.getAttribute("data-fields").slice(2,-2).split("-|-").reduce((e,n)=>!1!==t.columnVisibilityModel[n]?e+t.lookup[n].computedWidth:e,0)}px`;n.style.width=r})}s.start(0,()=>{e.current.publishEvent("columnResizeStop",null,t)})},f=()=>{i.columnHeaderElement&&(i.cellElements=function(e,t){if(!Hs(e,L.root))throw new Error("MUI X: The root element is not found.");const n=e.getAttribute("aria-colindex");if(!n)return[];const r=Number(n)-1,o=[];return t.virtualScrollerRef?.current?(Ks(t).forEach(e=>{const n=e.getAttribute("data-id");if(!n)return;let i=r;const a=t.unstable_getCellColSpanInfo(n,r);a&&a.spannedByColSpan&&(i=a.leftVisibleCellIndex);const l=e.querySelector(`[data-colindex="${i}"]`);l&&o.push(l)}),o):[]}(i.columnHeaderElement,e.current))},p=(t,r,o)=>{const s=e.current.rootElementRef.current;var c,u;i.initialColWidth=t.computedWidth,i.initialTotalWidth=e.current.getRootDimensions().rowWidth,i.colDef=t,i.columnHeaderElement=(c=e.current.columnHeadersContainerRef.current,u=t.field,c.querySelector(`[data-field="${Gs(u)}"]`));const d=s.querySelector(`.${L.headerFilterRow} [data-field="${Gs(t.field)}"]`);d&&(i.headerFilterElement=d),i.groupHeaderElements=function(e,t){return Array.from(e.querySelectorAll(`[data-fields*="|-${Gs(t)}-|"]`)??[])}(e.current.columnHeadersContainerRef?.current,t.field),f(),i.fillerLeft=Us(e.current,n?"filler--pinnedRight":"filler--pinnedLeft"),i.fillerRight=Us(e.current,n?"filler--pinnedLeft":"filler--pinnedRight");const p=e.current.unstable_applyPipeProcessors("isColumnPinned",!1,i.colDef.field);i.leftPinnedCellsAfter=p!==De.LEFT?[]:function(e,t,n){const r=Js(t);return qs({api:e,colIndex:r,position:n?"right":"left",filterFn:e=>n?e<r:e>r})}(e.current,i.columnHeaderElement,n),i.rightPinnedCellsBefore=p!==De.RIGHT?[]:function(e,t,n){const r=Js(t);return qs({api:e,colIndex:r,position:n?"left":"right",filterFn:e=>n?e>r:e<r})}(e.current,i.columnHeaderElement,n),i.leftPinnedHeadersAfter=p!==De.LEFT?[]:function(e,t,n){const r=Js(t);return Ys({api:e,position:n?"right":"left",colIndex:r,filterFn:e=>n?e<r:e>r})}(e.current,i.columnHeaderElement,n),i.rightPinnedHeadersBefore=p!==De.RIGHT?[]:function(e,t,n){const r=Js(t);return Ys({api:e,position:n?"left":"right",colIndex:r,filterFn:(e,t)=>!t.classList.contains(L["columnHeader--last"])&&(n?e>r:e<r)})}(e.current,i.columnHeaderElement,n),l.current=function(e,t){const n=e.classList.contains(L["columnSeparator--sideRight"])?"Right":"Left";return t?function(e){return"Right"===e?"Left":"Right"}(n):n}(r,n),a.current=function(e,t,n){return"Left"===n?e-t.left:t.right-e}(o,i.columnHeaderElement.getBoundingClientRect(),l.current)},h=(0,Nt.A)(d),g=(0,Nt.A)(t=>{if(0===t.buttons)return void h(t);let n=Fc(a.current,t.clientX,i.columnHeaderElement.getBoundingClientRect(),l.current);n=fn(n,i.colDef.minWidth,i.colDef.maxWidth),u(n);const r={element:i.columnHeaderElement,colDef:i.colDef,width:n};e.current.publishEvent("columnResize",r,t)}),m=(0,Nt.A)(e=>{Lc(e,c.current)&&d(e)}),A=(0,Nt.A)(t=>{const n=Lc(t,c.current);if(!n)return;if("mousemove"===t.type&&0===t.buttons)return void m(t);let r=Fc(a.current,n.x,i.columnHeaderElement.getBoundingClientRect(),l.current);r=fn(r,i.colDef.minWidth,i.colDef.maxWidth),u(r);const o={element:i.columnHeaderElement,colDef:i.colDef,width:r};e.current.publishEvent("columnResize",o,t)}),b=(0,Nt.A)(t=>{const n=Hs(t.target,L["columnSeparator--resizable"]);if(!n)return;const o=t.changedTouches[0];null!=o&&(c.current=o.identifier);const i=Hs(t.target,L.columnHeader).getAttribute("data-field"),a=e.current.getColumn(i);r.debug(`Start Resize on col ${a.field}`),e.current.publishEvent("columnResizeStart",{field:i},t),p(a,n,o.clientX);const l=(0,aa.A)(t.currentTarget);l.addEventListener("touchmove",A),l.addEventListener("touchend",m)}),v=o.useCallback(()=>{const t=(0,aa.A)(e.current.rootElementRef.current);t.body.style.removeProperty("cursor"),t.removeEventListener("mousemove",g),t.removeEventListener("mouseup",h),t.removeEventListener("touchmove",A),t.removeEventListener("touchend",m),setTimeout(()=>{t.removeEventListener("click",zc,!0)},100),i.columnHeaderElement&&(i.columnHeaderElement.style.pointerEvents="unset")},[e,i,g,h,A,m]),w=o.useCallback(({field:t})=>{e.current.setState(e=>(0,y.A)({},e,{columnResize:(0,y.A)({},e.columnResize,{resizingColumnField:t})}))},[e]),C=o.useCallback(()=>{e.current.setState(e=>(0,y.A)({},e,{columnResize:(0,y.A)({},e.columnResize,{resizingColumnField:""})}))},[e]),S=(0,Nt.A)(({colDef:t},n)=>{if(0!==n.button)return;if(!n.currentTarget.classList.contains(L["columnSeparator--resizable"]))return;n.preventDefault(),r.debug(`Start Resize on col ${t.field}`),e.current.publishEvent("columnResizeStart",{field:t.field},n),p(t,n.currentTarget,n.clientX);const o=(0,aa.A)(e.current.rootElementRef.current);o.body.style.cursor="col-resize",i.previousMouseClickEvent=n.nativeEvent,o.addEventListener("mousemove",g),o.addEventListener("mouseup",h),o.addEventListener("click",zc,!0)}),x=(0,Nt.A)((n,r)=>{if(t.disableAutosize)return;if(0!==r.button)return;const o=e.current.state.columns.lookup[n.field];!1!==o.resizable&&e.current.autosizeColumns((0,y.A)({},t.autosizeOptions,{disableColumnVirtualization:!1,columns:[o.field]}))}),E=function(e){const t=o.useRef(void 0),n=()=>vl(e),r=J(e,n);return o.useEffect(()=>{t.current&&!1===r&&(t.current.resolve(),t.current=void 0)}),()=>{if(!t.current){if(!1===n())return Promise.resolve();t.current=function(){let e,t;const n=new Promise((n,r)=>{e=n,t=r});return n.resolve=e,n.reject=t,n}()}return t.current}}(e),I=o.useRef(!1),k=o.useCallback(async n=>{const r=e.current.rootElementRef?.current;if(!r)return;if(I.current)return;I.current=!0;const o=Qe(e),i=(0,y.A)({},Dc,n,{columns:n?.columns??o.orderedFields});i.columns=i.columns.filter(e=>!1!==o.columnVisibilityModel[e]);const a=i.columns.map(t=>e.current.state.columns.lookup[t]);try{!t.disableVirtualization&&i.disableColumnVirtualization&&(e.current.unstable_setColumnVirtualization(!1),await E());const n=function(e,t,n){const r={},o=e.current.rootElementRef.current;o.classList.add(L.autosizing);const i=t.includeHeaderFilters&&Co(e);return n.forEach(n=>{const o=function(e,t){const n=e.virtualScrollerRef.current;return Array.from(n.querySelectorAll(`:scope > div > div > div > [data-field="${Gs(t)}"][role="gridcell"]`))}(e.current,n.field),a=o.map(e=>e.getBoundingClientRect().width??0),l=t.includeOutliers?a:function(e,t){if(e.length<4)return e;const n=e.slice();n.sort((e,t)=>e-t);const r=n[Math.floor(.25*n.length)],o=n[Math.floor(.75*n.length)-1],i=o-r,a=i<5?5:i*t;return n.filter(e=>e>r-a&&e<o+a)}(a,t.outliersFactor);if(t.includeHeaders){const t=(s=e.current,c=n.field,s.columnHeadersContainerRef.current.querySelector(`:scope > div > [data-field="${Gs(c)}"][role="columnheader"]`));if(t){const e=t.querySelector(`.${L.columnHeaderTitleContainer}`),n=Array.from(e.children),r=t.querySelector(`.${L.menuIcon}`),o=window.getComputedStyle(e,null),i=parseInt(o.gap,10)||0,a=window.getComputedStyle(t,null),s=parseInt(a.paddingLeft,10)+parseInt(a.paddingRight,10);let c=0,u=0;for(let e=0;e<n.length;e+=1){const t=n[e];t.clientWidth>0&&(c+=1,u+=t.scrollWidth)}u+=1;const d=u+i*(c-1)+s+(r?.clientWidth??0);l.push(d)}}var s,c;if(i){const t=function(e,t){return e.columnHeadersContainerRef.current.querySelector(`:scope > .${L.headerFilterRow} > [data-field="${Gs(t)}"]`)}(e.current,n.field);if(t){const e=window.getComputedStyle(t,null),n=parseInt(e.paddingLeft,10)+parseInt(e.paddingRight,10),r=t.scrollWidth+n;l.push(r)}}const u=n.minWidth!==-1/0&&void 0!==n.minWidth,d=n.maxWidth!==1/0&&void 0!==n.maxWidth,f=u?n.minWidth:0,p=d?n.maxWidth:1/0,h=0===l.length?0:Math.max(...l);r[n.field]=fn(h,f,p)}),o.classList.remove(L.autosizing),r}(e,i,a),r=a.map(e=>(0,y.A)({},e,{width:n[e.field],computedWidth:n[e.field],flex:0}));if(i.expand){const t=o.orderedFields.map(e=>o.lookup[e]).filter(e=>!1!==o.columnVisibilityModel[e.field]).reduce((e,t)=>e+(n[t.field]??t.computedWidth??t.width),0),i=e.current.getRootDimensions().viewportInnerSize.width-t;if(i>0){const e=i/(r.length||1);r.forEach(t=>{t.width+=e,t.computedWidth+=e})}}e.current.updateColumns(r),r.forEach((t,n)=>{if(t.width!==a[n].width){const n=t.width;e.current.publishEvent("columnWidthChange",{element:e.current.getColumnHeaderElement(t.field),colDef:t,width:n})}})}finally{t.disableVirtualization||e.current.unstable_setColumnVirtualization(!0),I.current=!1}},[e,E,t.disableVirtualization]);o.useEffect(()=>v,[v]),(0,$i.A)(()=>{t.autosizeOnMount&&Promise.resolve().then(()=>{e.current.autosizeColumns(t.autosizeOptions)})}),ss(e,()=>e.current.columnHeadersContainerRef?.current,"touchstart",b,{passive:!0}),Bl(e,{autosizeColumns:k},"public"),$t(e,"columnResizeStop",C),$t(e,"columnResizeStart",w),$t(e,"columnSeparatorMouseDown",S),$t(e,"columnSeparatorDoubleClick",x),$t(e,"rowsSet",()=>{""!==Nc(e)&&requestAnimationFrame(()=>{f()})}),Gt(e,"columnResize",t.onColumnResize),Gt(e,"columnWidthChange",t.onColumnWidthChange)};function Vc(e,t,n){e&&(e.style[t]=`${Math.round(parseFloat(e.style[t]))+n}px`)}function Wc(e){return 0!==e.firstRowIndex||0!==e.lastRowIndex}const Uc=(e,t,n)=>{if(!e)return null;const r=e[t.field];return t.rowSpanValueGetter?t.rowSpanValueGetter(r,e,t,n):Kn(e,t,n)},qc={caches:{spannedCells:{},hiddenCells:{},hiddenCellOriginMap:{}},processedRange:{firstRowIndex:0,lastRowIndex:0}},Yc=e=>(0,y.A)({},e,{rowSpanning:qc}),Kc=(e,t,n)=>(0,y.A)({},e,{listViewColumn:t.listViewColumn?(0,y.A)({},t.listViewColumn,{computedWidth:Jc(n)}):void 0});function Jc(e){return ut(e).viewportInnerSize.width}const Xc=Ee(Ko,Uo,al,(e,t,n)=>({groupKeys:[],paginationModel:n,sortModel:t,filterModel:e,start:n.page*n.pageSize,end:n.page*n.pageSize+n.pageSize-1}));let Zc=function(e){return e.Default="set-flat-rows",e.LazyLoading="replace-row-range",e.GroupedData="set-grouped-rows",e}({});class eu{constructor(e){this.chunkSize=e}getCacheKeys=e=>{if(this.chunkSize<1||"number"!=typeof e.start)return[e];const t=[];for(let n=e.start;n<=e.end;n+=this.chunkSize){const r=Math.min(n+this.chunkSize-1,e.end);t.push((0,y.A)({},e,{start:n,end:r}))}return t};splitResponse=(e,t)=>{const n=this.getCacheKeys(e);if(1===n.length)return new Map([[e,t]]);const r=new Map;return n.forEach(n=>{const o=n.end===e.end,i=(0,y.A)({},t,{pageInfo:(0,y.A)({},t.pageInfo,{hasNextPage:void 0!==t.pageInfo?.hasNextPage&&!o||t.pageInfo?.hasNextPage,nextCursor:void 0===t.pageInfo?.nextCursor||o?t.pageInfo?.nextCursor:t.rows[n.end+1].id}),rows:"number"!=typeof n.start||"number"!=typeof e.start?t.rows:t.rows.slice(n.start-e.start,n.end-e.start+1)});r.set(n,i)}),r};static mergeResponses=e=>1===e.length?e[0]:e.reduce((e,t)=>(0,y.A)({},t,{rows:[...e.rows,...t.rows]}),{rows:[],rowCount:0,pageInfo:{}})}function tu(e){return JSON.stringify([e.filterModel,e.sortModel,e.start,e.end])}class nu{constructor({ttl:e=3e5,getKey:t=tu}){this.cache={},this.ttl=e,this.getKey=t}set(e,t){const n=this.getKey(e),r=Date.now()+this.ttl;this.cache[n]={value:t,expiry:r}}get(e){const t=this.getKey(e),n=this.cache[t];if(n){if(!(Date.now()>n.expiry))return n.value;delete this.cache[t]}}clear(){this.cache={}}}class ru extends Error{constructor(e){super(e.message),this.name="GridGetRowsError",this.params=e.params,this.cause=e.cause}}class ou extends Error{constructor(e){super(e.message),this.name="GridUpdateRowError",this.params=e.params,this.cause=e.cause}}const iu=["skipCache","keepChildrenExpanded"],au={clear:()=>{},get:()=>{},set:()=>{}};function lu(e,t={}){return null===e?au:e??new nu(t)}const su=(e,t,n)=>{((e,t)=>{(e=>{const t=o.useRef(null),n=o.useRef(null),r=o.useRef(null),i=o.useRef(null),a=o.useRef(null),l=o.useRef(null);e.current.register("public",{rootElementRef:t}),e.current.register("private",{mainElementRef:n,virtualScrollerRef:r,virtualScrollbarVerticalRef:i,virtualScrollbarHorizontalRef:a,columnHeadersContainerRef:l})})(e),((e,t)=>{const n=o.useRef(!0);o.useEffect(()=>{n.current?n.current=!1:e.current.setState(e=>(0,y.A)({},e,{props:{listView:t.listView,getRowId:t.getRowId,isCellEditable:t.isCellEditable,isRowSelectable:t.isRowSelectable,dataSource:t.dataSource}}))},[e,t.listView,t.getRowId,t.isCellEditable,t.isRowSelectable,t.dataSource])})(e,t),(e=>{const t=(0,Hr.I)();void 0===e.current.state.isRtl&&(e.current.state.isRtl=t);const n=o.useRef(!0);o.useEffect(()=>{n.current?n.current=!1:e.current.setState(e=>(0,y.A)({},e,{isRtl:t}))},[e,t])})(e),((e,t)=>{Bl(e,{getLogger:o.useCallback(e=>Yl?Zl(e,"debug",t.logger):t.logLevel?Zl(e,t.logLevel.toString(),t.logger):Jl,[t.logLevel,t.logger])},"private")})(e,t),(e=>{const t=o.useRef({}),n=o.useCallback(e=>{t.current[e.stateId]=e},[]),r=o.useCallback((n,r)=>{let o;if(o="function"==typeof n?n(e.current.state):n,e.current.state===o)return!1;const i={current:{state:o}};let a=!1;const l=[];if(Object.keys(t.current).forEach(n=>{const r=t.current[n],o=r.stateSelector(e),s=r.stateSelector(i);s!==o&&(l.push({stateId:r.stateId,hasPropChanged:s!==r.propModel}),void 0!==r.propModel&&s!==r.propModel&&(a=!0))}),l.length>1)throw new Error(`You're not allowed to update several sub-state in one transaction. You already updated ${l[0].stateId}, therefore, you're not allowed to update ${l.map(e=>e.stateId).join(", ")} in the same transaction.`);if(a||(e.current.state=o,e.current.publishEvent("stateChange",o),e.current.store.update(o)),1===l.length){const{stateId:n,hasPropChanged:o}=l[0],s=t.current[n],c=s.stateSelector(i);s.propOnChange&&o&&s.propOnChange(c,{reason:r,api:e.current}),a||e.current.publishEvent(s.changeEvent,c,{reason:r})}return!a},[e]),i={updateControlState:o.useCallback((t,n,r)=>e.current.setState(e=>(0,y.A)({},e,{[t]:n(e[t])}),r),[e]),registerControlState:n};Bl(e,{setState:r},"public"),Bl(e,i,"private")})(e),(e=>{const t=o.useRef({}),n=o.useRef(!1),r=o.useCallback(e=>{!n.current&&e&&(n.current=!0,Object.values(e.appliers).forEach(e=>{e()}),n.current=!1)},[]),i=o.useCallback((e,n,r)=>{t.current[e]||(t.current[e]={processors:new Map,processorsAsArray:[],appliers:{},processorsUpdated:!1});const o=t.current[e];return o.processors.get(n)!==r&&(o.processors.set(n,r),o.processorsAsArray=Array.from(t.current[e].processors.values()).filter(e=>null!==e),o.processorsUpdated=!0),()=>{t.current[e].processors.set(n,null),t.current[e].processorsAsArray=Array.from(t.current[e].processors.values()).filter(e=>null!==e)}},[]),a=o.useCallback((e,n,r)=>(t.current[e]||(t.current[e]={processors:new Map,processorsAsArray:[],appliers:{},processorsUpdated:!1}),t.current[e].appliers[n]=r,()=>{const r=t.current[e].appliers,o=(0,x.A)(r,[n].map(ts));t.current[e].appliers=o}),[]),l=o.useCallback(e=>{r(t.current[e])},[r]),s=o.useCallback(()=>{for(const e in t.current){if(!Object.prototype.hasOwnProperty.call(t.current,e))continue;const n=t.current[e];n.processorsUpdated&&(n.processorsUpdated=!1,r(n))}},[r]),c={unstable_applyPipeProcessors:o.useCallback((...e)=>{const[n,r,o]=e;if(!t.current[n])return r;const i=t.current[n].processorsAsArray;let a=r;for(let e=0;e<i.length;e+=1)a=i[e](a,o);return a},[])};Bl(e,{registerPipeProcessor:i,registerPipeApplier:a,requestPipeProcessorsApplication:l,runAppliersForPendingProcessors:s},"private"),Bl(e,c,"public")})(e),(e=>{const t=o.useRef(new Map),n=o.useRef({}),r=o.useCallback((t,r,o)=>{const i=()=>{const e=n.current[r],o=(0,x.A)(e,[t].map(ts));n.current[r]=o};n.current[r]||(n.current[r]={});const a=n.current[r],l=a[t];return a[t]=o,l&&l!==o?(t===e.current.getActiveStrategy(os[r])&&e.current.publishEvent("activeStrategyProcessorChange",r),i):i},[e]),i=o.useCallback((t,r)=>{const o=e.current.getActiveStrategy(os[t]);if(null==o)throw new Error("Can't apply a strategy processor before defining an active strategy");const i=n.current[t];if(!i||!i[o])throw new Error(`No processor found for processor "${t}" on strategy "${o}"`);return(0,i[o])(r)},[e]),a=o.useCallback(e=>{const n=Array.from(t.current.entries()).find(([,t])=>t.group===e&&t.isAvailable());return n?.[0]??rs},[]),l=o.useCallback((n,r,o)=>{t.current.set(r,{group:n,isAvailable:o}),e.current.publishEvent("strategyAvailabilityChange")},[e]);Bl(e,{registerStrategyProcessor:r,applyStrategyProcessor:i,getActiveStrategy:a,setStrategyAvailability:l},"private")})(e),((e,t)=>{const n=o.useCallback(e=>{if(null==t.localeText[e])throw new Error(`Missing translation for key ${e}.`);return t.localeText[e]},[t.localeText]);e.current.register("public",{getLocaleText:n})})(e,t),e.current.register("private",{rootProps:t})})(e,t),((e,t)=>{const n=(e=>{const{classes:t}=e;return o.useMemo(()=>(0,R.A)({cellCheckbox:["cellCheckbox"],columnHeaderCheckbox:["columnHeaderCheckbox"]},D,t),[t])})({classes:t.classes}),r=o.useCallback(r=>{const o=(0,y.A)({},gs,{cellClassName:n.cellCheckbox,headerClassName:n.columnHeaderCheckbox,headerName:e.current.getLocaleText("checkboxSelectionHeaderName")}),i=t.checkboxSelection,a=null!=r.lookup[hs];return i&&!a?(r.lookup[hs]=o,r.orderedFields=[hs,...r.orderedFields]):!i&&a?(delete r.lookup[hs],r.orderedFields=r.orderedFields.filter(e=>e!==hs)):i&&a&&(r.lookup[hs]=(0,y.A)({},o,r.lookup[hs]),t.columns.some(e=>e.field===hs)||(r.orderedFields=[hs,...r.orderedFields.filter(e=>e!==hs)])),r},[e,n,t.columns,t.checkboxSelection]);ws(e,"hydrateColumns",r)})(e,t),(e=>{Ds(e,rs,"rowTreeCreation",gc)})(e),as(is,e,t),as(bc,e,t),as(Cs,e,t),as(hc,e,t),as(tc,e,t),as(pc,e,t),as($s,e,t),as(vc,e,t),as(nc,e,t),as(Ns,e,t),as(Yc,e,t),as(Ss,e,t),as($c,e,t),as(ys,e,t),as(_c,e,t),as(Oc,e,t),as(Sc,e,t),as(Tl,e,t),as(Kc,e,t),((e,t)=>{const n=ls(e,"useGridKeyboardNavigation"),r=(0,Hr.I)(),i=o.useCallback(()=>ec(e),[e]),a="DataGrid"!==t.signature&&t.headerFilters,l=o.useCallback((t,r,o="left",i="up")=>{const a=ei(e),l=e.current.unstable_getCellColSpanInfo(r,t);l&&l.spannedByColSpan&&("left"===o?t=l.leftVisibleCellIndex:"right"===o&&(t=l.rightVisibleCellIndex));const s=We(e)[t],c=function(e,t,n,r){const o=qa.selectors.hiddenCells(e.current.virtualizer.store.state);if(!o[t]?.[n])return t;const i=ri(e);let a=i.indexOf(t)+("down"===r?1:-1);for(;a>=0&&a<i.length;){const e=i[a];if(!o[e]?.[n])return e;a+="down"===r?1:-1}return t}(e,r,t,i),u=a.findIndex(e=>e.id===c);n.debug(`Navigating to cell row ${u}, col ${t}`),e.current.scrollToIndexes({colIndex:t,rowIndex:u}),e.current.setCellFocus(c,s)},[e,n]),s=o.useCallback((t,r)=>{n.debug(`Navigating to header col ${t}`),e.current.scrollToIndexes({colIndex:t});const o=e.current.getVisibleColumns()[t].field;e.current.setColumnHeaderFocus(o,r)},[e,n]),c=o.useCallback((t,r)=>{n.debug(`Navigating to header filter col ${t}`),e.current.scrollToIndexes({colIndex:t});const o=e.current.getVisibleColumns()[t].field;e.current.setColumnHeaderFilterFocus(o,r)},[e,n]),u=o.useCallback((t,r,o)=>{n.debug(`Navigating to header col ${t}`),e.current.scrollToIndexes({colIndex:t});const{field:i}=e.current.getVisibleColumns()[t];e.current.setColumnGroupHeaderFocus(i,r,o)},[e,n]),d=o.useCallback(e=>i()[e]?.id,[i]),f=o.useCallback((n,o)=>{const f=o.currentTarget.querySelector(`.${L.columnHeaderTitleContainerContent}`);if(f&&f.contains(o.target)&&n.field!==gs.field)return;if(!Vr(o.key)&&"Tab"!==o.key&&"Enter"!==o.key)return;if("Tab"===o.key&&("none"===t.tabNavigation||"content"===t.tabNavigation&&o.shiftKey))return;const p=i(),h=e.current.getViewportPageSize(),g=n.field?e.current.getColumnIndex(n.field):0,m=p.length>0?0:null,A=p.length>0?p.length-1:null,b=Math.max(0,Ve(e).length-1),v=Mo(e);let y=!0;if("Tab"!==o.key||"content"!==t.tabNavigation||o.shiftKey){switch(o.key){case"ArrowDown":a?c(g,o):null!==m&&l(g,d(m));break;case"ArrowRight":{const e=Zs({currentColIndex:g,firstColIndex:0,lastColIndex:b,isRtl:r});null!==e&&s(e,o);break}case"ArrowLeft":{const e=Xs({currentColIndex:g,firstColIndex:0,lastColIndex:b,isRtl:r});null!==e&&s(e,o);break}case"ArrowUp":v>0&&u(g,v-1,o);break;case"PageDown":null!==m&&null!==A&&l(g,d(Math.min(m+h,A)));break;case"Home":s(0,o);break;case"End":s(b,o);break;case"Enter":(o.ctrlKey||o.metaKey)&&e.current.toggleColumnMenu(n.field);break;case"Tab":o.shiftKey?0===g?v>0?u(b,v-1,o):y=!1:s(g-1,o):g===b?a?c(0,o):"all"===t.tabNavigation&&null!==m?l(0,d(m)):y=!1:s(g+1,o);break;case" ":break;default:y=!1}y&&o.preventDefault()}else null!==m&&(l(0,d(m)),o.preventDefault())},[e,t.tabNavigation,i,a,c,l,d,r,s,u]),p=o.useCallback((n,o)=>{const a=So(e)===n.field;if(xo(e)===n.field||a&&"Tab"!==o.key)return;if(!Vr(o.key)&&"Tab"!==o.key)return;if("Tab"===o.key&&("none"===t.tabNavigation||"content"===t.tabNavigation&&o.shiftKey))return;const u=i(),f=e.current.getViewportPageSize(),p=n.field?e.current.getColumnIndex(n.field):0,h=u.length>0?0:null,g=u.length>0?u.length-1:null,m=Math.max(0,Ve(e).length-1);let A=!0;if("Tab"!==o.key||"content"!==t.tabNavigation||o.shiftKey){switch(o.key){case"ArrowDown":null!==h&&l(p,d(h));break;case"ArrowRight":{const e=Zs({currentColIndex:p,firstColIndex:0,lastColIndex:m,isRtl:r});null!==e&&c(e,o);break}case"ArrowLeft":{const t=Xs({currentColIndex:p,firstColIndex:0,lastColIndex:m,isRtl:r});null!==t?c(t,o):e.current.setColumnHeaderFilterFocus(n.field,o);break}case"ArrowUp":s(p,o);break;case"PageDown":null!==h&&null!==g&&l(p,d(Math.min(h+f,g)));break;case"Home":c(0,o);break;case"End":c(m,o);break;case"Tab":o.shiftKey?0===p?s(m,o):c(p-1,o):p===m?"all"===t.tabNavigation&&null!==h?l(0,d(h)):A=!1:c(p+1,o);break;case" ":break;default:A=!1}A&&o.preventDefault()}else null!==h&&(l(0,d(h)),o.preventDefault())},[e,t.tabNavigation,i,c,r,s,l,d]),h=o.useCallback((n,r)=>{const o=vi(e);if(null===o)return;const{field:a,depth:c}=o,{fields:f,depth:p,maxDepth:h}=n;if(!Vr(r.key)&&"Tab"!==r.key)return;if("Tab"===r.key&&("none"===t.tabNavigation||"content"===t.tabNavigation&&r.shiftKey))return;const g=i(),m=e.current.getViewportPageSize(),A=e.current.getColumnIndex(a),b=a?e.current.getColumnIndex(a):0,v=g.length>0?0:null,y=g.length>0?g.length-1:null,w=Math.max(0,Ve(e).length-1);let C=!0;if("Tab"!==r.key||"content"!==t.tabNavigation||r.shiftKey){switch(r.key){case"ArrowDown":p===h-1?s(A,r):u(A,c+1,r);break;case"ArrowUp":p>0&&u(A,c-1,r);break;case"ArrowRight":{const e=f.length-f.indexOf(a)-1;A+e+1<=w&&u(A+e+1,c,r);break}case"ArrowLeft":{const e=f.indexOf(a);A-e-1>=0&&u(A-e-1,c,r);break}case"PageDown":null!==v&&null!==y&&l(b,d(Math.min(v+m,y)));break;case"Home":u(0,c,r);break;case"End":u(w,c,r);break;case"Tab":if(r.shiftKey){const e=A-f.indexOf(a)-1;e<0?0===p?C=!1:u(w,c-1,r):u(e,c,r)}else{const e=A+(f.length-f.indexOf(a)-1)+1;e>w&&p===h-1?s(0,r):e>w?u(0,c+1,r):u(e,c,r)}break;case" ":break;default:C=!1}C&&r.preventDefault()}else null!==v&&(l(0,d(v)),r.preventDefault())},[e,t.tabNavigation,i,s,u,l,d]),g=o.useCallback((n,o)=>{if(Ws(o))return;const u=e.current.getCellParams(n.id,n.field);if(u.cellMode===Pr.Edit||!Vr(o.key)&&"Tab"!==o.key)return;if("Tab"===o.key&&("none"===t.tabNavigation||"header"===t.tabNavigation&&!o.shiftKey))return;if(!e.current.unstable_applyPipeProcessors("canUpdateFocus",!0,{event:o,cell:u}))return;const f=i();if(0===f.length)return;const p=a?c:s,h=e.current.getViewportPageSize(),g=n.field?e.current.getColumnIndex(n.field):0,m=f.findIndex(e=>e.id===n.id),A=f.length-1,b=Math.max(0,Ve(e).length-1);let v=!0;if("Tab"===o.key&&"header"===t.tabNavigation&&o.shiftKey)return p(b,o),void o.preventDefault();switch(o.key){case"ArrowDown":m<A&&l(g,d(m+1),r?"right":"left","down");break;case"ArrowUp":m>0?l(g,d(m-1)):p(g,o);break;case"ArrowRight":{const e=Zs({currentColIndex:g,firstColIndex:0,lastColIndex:b,isRtl:r});null!==e&&l(e,d(m),r?"left":"right");break}case"ArrowLeft":{const e=Xs({currentColIndex:g,firstColIndex:0,lastColIndex:b,isRtl:r});null!==e&&l(e,d(m),r?"right":"left");break}case"Tab":o.shiftKey?0===g&&0===m?"all"===t.tabNavigation?p(b,o):v=!1:0===g?l(b,d(m-1)):l(g-1,d(m),"left"):g===b?m!==A?l(0,d(m+1)):v=!1:l(g+1,d(m),"right");break;case" ":{if(n.field===pr)break;const e=n.colDef;if(e&&("__tree_data_group__"===e.field||(y=e.field)===fr||null!==(e=>{const t=e.match(/^__row_group_by_columns_group_(.*)__$/);return t?t[1]:null})(y)))break;if(e&&"longText"===e.type)break;!o.shiftKey&&m<A&&l(g,d(Math.min(m+h,A)));break}case"PageDown":m<A&&l(g,d(Math.min(m+h,A)));break;case"PageUp":{const e=Math.max(m-h,0);e!==m&&e>=0?l(g,d(e)):s(g,o);break}case"Home":o.ctrlKey||o.metaKey||o.shiftKey?l(0,d(0)):l(0,d(m));break;case"End":o.ctrlKey||o.metaKey||o.shiftKey?l(b,d(A)):l(b,d(m));break;default:v=!1}var y;v&&o.preventDefault()},[e,t.tabNavigation,i,r,l,d,a,c,s]),m=o.useCallback((e,{event:t})=>" "!==t.key&&e,[]);ws(e,"canStartEditing",m),$t(e,"columnHeaderKeyDown",f),$t(e,"headerFilterKeyDown",p),$t(e,"columnGroupHeaderKeyDown",h),$t(e,"cellKeyDown",g)})(e,t),((e,t)=>{const n=ls(e,"useGridSelection"),r=J(e,Bt)>1,i=t.signature!==el.DataGrid&&(t.rowSelectionPropagation?.parents||t.rowSelectionPropagation?.descendants)&&r,a=o.useMemo(()=>t.rowSelectionModel,[t.rowSelectionModel]),l=o.useRef(null);e.current.registerControlState({stateId:"rowSelection",propModel:a,propOnChange:t.onRowSelectionModelChange,stateSelector:Il,changeEvent:"rowSelectionChange"});const{checkboxSelection:s,disableRowSelectionOnClick:c,isRowSelectable:u}=t,d=Vl(t),f=o.useCallback(t=>{let n=t;const r=l.current??t,o=e.current.isRowSelected(t);if(o){const t=ti(e),o=t.findIndex(e=>e===r),i=t.findIndex(e=>e===n);if(o===i)return;n=o>i?t[i+1]:t[i-1]}l.current=t,e.current.selectRowRange({startId:r,endId:n},!o)},[e]),p=(0,Nt.A)(()=>t.pagination&&t.checkboxSelectionVisibleOnly&&"client"===t.paginationMode?hl(e):ti(e)),h=o.useCallback((r,o)=>{if(t.signature===el.DataGrid&&!d&&("include"!==r.type||r.ids.size>1))throw new Error(["MUI X: `rowSelectionModel` can only contain 1 item in DataGrid.","You need to upgrade to DataGridPro or DataGridPremium component to unlock multiple selection."].join("\n"));if(Il(e)!==r){if(n.debug("Setting selection model"),null!==l.current){const e=r.ids.has(l.current);("include"===r.type&&!e||"exclude"===r.type&&e)&&(l.current=null)}e.current.setState(e=>(0,y.A)({},e,{rowSelection:t.rowSelection?r:Ac}),o)}},[e,n,t.rowSelection,t.signature,d]),g=o.useCallback(t=>kl(e).has(t),[e]),m=o.useCallback(n=>{if(!1===t.rowSelection)return!1;if(t.keepNonExistentRowsSelected&&!e.current.getRow(n))return!0;if(u&&!u(e.current.getRowParams(n)))return!1;const r=kt(e,n);return"footer"!==r?.type&&"pinnedRow"!==r?.type},[e,t.rowSelection,t.keepNonExistentRowsSelected,u]),A=o.useCallback(()=>Ml(e),[e]),b=o.useCallback((r,o=!0,a=!1)=>{if(!e.current.isRowSelectable(r))return;const s=It(e);if(l.current=o?r:null,a){n.debug(`Setting selection for row ${r}`);const a={type:"include",ids:new Set},l=e=>{a.ids.add(e)};o&&(l(r),i&&Wl(e,s,r,t.rowSelectionPropagation?.descendants??!1,t.rowSelectionPropagation?.parents??!1,l)),e.current.setRowSelectionModel(a,"singleRowSelection")}else{n.debug(`Toggling selection for row ${r}`);const a=Il(e),l={type:a.type,ids:new Set(a.ids)},c=El(l);c.unselect(r);const u=e=>{c.select(e)},f=e=>{c.unselect(e)};o?(u(r),i&&Wl(e,s,r,t.rowSelectionPropagation?.descendants??!1,t.rowSelectionPropagation?.parents??!1,u)):i&&Ul(e,s,r,t.rowSelectionPropagation?.descendants??!1,t.rowSelectionPropagation?.parents??!1,f),("include"===l.type&&l.ids.size<2||d)&&e.current.setRowSelectionModel(l,"singleRowSelection")}},[e,n,i,t.rowSelectionPropagation?.descendants,t.rowSelectionPropagation?.parents,d]),v=o.useCallback((r,o=!0,a=!1)=>{if(n.debug("Setting selection for several rows"),!1===t.rowSelection)return;const l=It(e),s=new Set;for(let t=0;t<r.length;t+=1){const n=r[t];e.current.isRowSelectable(n)&&s.add(n)}const c=Il(e);let u;if(a){if(u={type:"include",ids:s},o){const n=El(u);if(i){const r=e=>{n.select(e)};for(const n of s)Wl(e,l,n,t.rowSelectionPropagation?.descendants??!1,t.rowSelectionPropagation?.parents??!1,r)}}else u.ids=new Set;if(c.type===u.type&&u.ids.size===c.ids.size&&Array.from(u.ids).every(e=>c.ids.has(e)))return}else{u={type:c.type,ids:new Set(c.ids)};const n=El(u),r=e=>{n.select(e)},a=e=>{n.unselect(e)};for(const c of s)o?(n.select(c),i&&Wl(e,l,c,t.rowSelectionPropagation?.descendants??!1,t.rowSelectionPropagation?.parents??!1,r)):(a(c),i&&Ul(e,l,c,t.rowSelectionPropagation?.descendants??!1,t.rowSelectionPropagation?.parents??!1,a))}("include"===u.type&&u.ids.size<2||d)&&e.current.setRowSelectionModel(u,"multipleRowsSelection")},[n,i,d,e,t.rowSelectionPropagation?.descendants,t.rowSelectionPropagation?.parents,t.rowSelection]),w=o.useCallback(n=>{if(!r||!i||"exclude"===n.type||0===n.ids.size&&"include"===n.type)return n;const o={type:n.type,ids:new Set(n.ids)},a=It(e),l=El(o),s=e=>{l.select(e)};for(const r of n.ids)Wl(e,a,r,t.rowSelectionPropagation?.descendants??!1,t.rowSelectionPropagation?.parents??!1,s,l);return o},[e,t.rowSelectionPropagation?.descendants,t.rowSelectionPropagation?.parents,r,i]),C={selectRows:v,selectRowRange:o.useCallback(({startId:t,endId:r},o=!0,i=!1)=>{if(!e.current.getRow(t)||!e.current.getRow(r))return;n.debug(`Expanding selection from row ${t} to row ${r}`);const a=ti(e),l=a.indexOf(t),s=a.indexOf(r),[c,u]=l>s?[s,l]:[l,s],d=a.slice(c,u+1);e.current.selectRows(d,o,i)},[e,n]),getPropagatedRowSelectionModel:w};Bl(e,{selectRow:b,setRowSelectionModel:h,getSelectedRows:A,isRowSelected:g,isRowSelectable:m},"public"),Bl(e,C,t.signature===el.DataGrid?"private":"public");const S=o.useRef(!0),x=o.useCallback(()=>{if(S.current)return;const n=Il(e),o=Et(e),i=It(e),a=Zo(e),l=e=>"server"===t.filterMode?!o[e]:!i[e]||!1===a[e],s={type:n.type,ids:new Set(n.ids)},c=El(s),u=n=>{const r=i[n];return!!r&&("server"===t.filterMode||!1!==a[n])&&("group"!==r.type?Boolean(o[n])&&e.current.isRowSelectable(n):r.children.some(e=>u(e)))};let d=!1;for(const e of n.ids){if(l(e)){if(t.keepNonExistentRowsSelected)continue;c.unselect(e),d=!0;continue}if(!t.rowSelectionPropagation?.parents)continue;const n=i[e];if("group"===n?.type){if(n.isAutoGenerated){c.unselect(e),d=!0;continue}n.children.some(e=>!1!==a[e]&&u(e))&&(c.unselect(e),d=!0)}}const f=r&&t.rowSelectionPropagation?.parents&&(s.ids.size>0||"exclude"===s.type);if(d||f)if(f)if("exclude"===s.type){const n=p(),r=[];for(let e=0;e<n.length;e+=1){const o=n[e];!t.keepNonExistentRowsSelected&&l(o)||!c.has(o)||r.push(o)}e.current.selectRows(r,!0,!0)}else e.current.selectRows(Array.from(s.ids),!0,!0);else e.current.setRowSelectionModel(s,"multipleRowsSelection")},[e,r,t.rowSelectionPropagation?.parents,t.keepNonExistentRowsSelected,t.filterMode,p]),E=o.useCallback((t,n)=>{const r=n.metaKey||n.ctrlKey,o=!s&&!r&&!(e=>!!e.key)(n),i=!d||o,a=e.current.isRowSelected(t),l=Rl(e)>1&&i||!a;e.current.selectRow(t,l,i)},[e,d,s]),I=o.useCallback((t,n)=>{if(c)return;const r=n.target.closest(`.${L.cell}`)?.getAttribute("data-field");if(r!==gs.field&&r!==pr){if(r){const t=e.current.getColumn(r);if(t?.type===ro)return}"pinnedRow"!==kt(e,t.id).type&&(n.shiftKey&&d?f(t.id):E(t.id,n))}},[c,d,e,f,E]),k=o.useCallback((e,t)=>{d&&t.shiftKey&&window.getSelection()?.removeAllRanges()},[d]),R=o.useCallback((t,n)=>{d&&n.nativeEvent.shiftKey?f(t.id):e.current.selectRow(t.id,t.value,!d)},[e,f,d]),M=o.useCallback(n=>{const o=Ko(e),i=Jo(e),a=o.items.length>0||i?.some(e=>e.length);t.isRowSelectable||t.checkboxSelectionVisibleOnly||r&&!t.rowSelectionPropagation?.descendants||a||t.disableRowSelectionExcludeModel?e.current.selectRows(p(),n):e.current.setRowSelectionModel({type:n?"exclude":"include",ids:new Set},"multipleRowsSelection")},[e,p,t.checkboxSelectionVisibleOnly,t.isRowSelectable,t.rowSelectionPropagation?.descendants,t.disableRowSelectionExcludeModel,r]),P=o.useCallback(e=>{M(e.value)},[M]),B=o.useCallback((t,n)=>{if(e.current.getCellMode(t.id,t.field)!==Pr.Edit&&!Ws(n)){if(Vr(n.key)&&n.shiftKey){const r=Ai(e);if(r&&r.id!==t.id){n.preventDefault();const o=e.current.isRowSelected(r.id);if(!d)return void e.current.selectRow(r.id,!o,!0);const i=e.current.getRowIndexRelativeToVisibleRows(r.id),a=e.current.getRowIndexRelativeToVisibleRows(t.id);let l,s;i>a?o?(l=a,s=i-1):(l=a,s=i):o?(l=i+1,s=a):(l=i,s=a);const c=ml(e),u=[];for(let e=l;e<=s;e+=1)u.push(c.rows[e].id);return void e.current.selectRows(u,!o)}}if(" "===n.key&&n.shiftKey)return n.preventDefault(),void E(t.id,n);"A"===String.fromCharCode(n.keyCode)&&(n.ctrlKey||n.metaKey)&&(n.preventDefault(),d&&M(!0))}},[e,d,E,M]),_=(0,Nt.A)(()=>{if(!t.rowSelection)return void e.current.setRowSelectionModel(Ac);if(void 0===a)return;if(!i||!r||"include"===a.type&&0===a.ids.size)return void e.current.setRowSelectionModel(a);const n=e.current.getPropagatedRowSelectionModel(a);n.type===a.type&&n.ids.size===a.ids.size&&Array.from(a.ids).every(e=>n.ids.has(e))?e.current.setRowSelectionModel(a):e.current.setRowSelectionModel(n)});$t(e,"filteredRowsSet",hn(t.rowSelection,x)),$t(e,"rowClick",hn(t.rowSelection,I)),$t(e,"rowSelectionCheckboxChange",hn(t.rowSelection,R)),$t(e,"headerSelectionCheckboxChange",P),$t(e,"cellMouseDown",hn(t.rowSelection,k)),$t(e,"cellKeyDown",hn(t.rowSelection,B)),o.useEffect(()=>{_()},[e,a,t.rowSelection,_]);const T=null!=a;o.useEffect(()=>{if(T||!t.rowSelection||"function"!=typeof m)return;const n=Il(e);if("include"!==n.type)return;const r=new Set;for(const e of n.ids)m(e)&&r.add(e);r.size<n.ids.size&&e.current.setRowSelectionModel({type:n.type,ids:r})},[e,m,T,t.rowSelection]),o.useEffect(()=>{if(!t.rowSelection||T)return;const n=Il(e);!d&&("include"===n.type&&n.ids.size>1||"exclude"===n.type)&&e.current.setRowSelectionModel(Ac)},[e,d,s,T,t.rowSelection]),o.useEffect(()=>{hn(t.rowSelection,x)},[t.rowSelection,x]),o.useEffect(()=>{S.current&&(S.current=!1)},[])})(e,t),function(e,t){const n=ls(e,"useGridColumns");e.current.registerControlState({stateId:"visibleColumns",propModel:t.columnVisibilityModel,propOnChange:t.onColumnVisibilityModelChange,stateSelector:He,changeEvent:"columnVisibilityModelChange"});const i=o.useCallback(t=>{n.debug("Updating columns state."),e.current.setState(function(e){return t=>(0,y.A)({},t,{columns:e})}(t)),e.current.publishEvent("columnsChange",t.orderedFields)},[n,e]),a=o.useCallback(t=>ze(e)[t],[e]),l=o.useCallback(()=>$e(e),[e]),s=o.useCallback(()=>Ve(e),[e]),c=o.useCallback((t,n=!0)=>(n?Ve(e):$e(e)).findIndex(e=>e.field===t),[e]),u=o.useCallback(t=>{const n=c(t);return Ke(e)[n]},[e,c]),d=o.useCallback(t=>{He(e)!==t&&(e.current.setState(n=>(0,y.A)({},n,{columns:Oo({apiRef:e,columnsToUpsert:[],initialState:void 0,columnVisibilityModel:t,keepOnlyColumnsToUpsert:!1})})),e.current.updateRenderContext?.())},[e]),f=o.useCallback(t=>{let n=t;if(fi(e)){const r=[],o=[],i=hi(e);if(t.forEach(e=>{i.has(e.field)?r.push(e):o.push(e)}),r.length>0&&e.current.updateNonPivotColumns(r),0===o.length)return;n=o}const r=Oo({apiRef:e,columnsToUpsert:n,initialState:void 0,keepOnlyColumnsToUpsert:!1,updateInitialVisibilityModel:!0});i(r)},[e,i]),p=o.useCallback((t,n)=>{const r=He(e);if(n!==(r[t]??!0)){const o=(0,y.A)({},r,{[t]:n});e.current.setColumnVisibilityModel(o)}},[e]),h=o.useCallback(t=>je(e).findIndex(e=>e===t),[e]),g=o.useCallback((t,r)=>{const o=je(e),a=h(t);if(a===r)return;n.debug(`Moving column ${t} to index ${r}`);const l=[...o],s=l.splice(a,1)[0];l.splice(r,0,s),i((0,y.A)({},Qe(e),{orderedFields:l}));const c={column:e.current.getColumn(t),targetIndex:e.current.getColumnIndexRelativeToVisibleColumns(t),oldIndex:a};e.current.publishEvent("columnIndexChange",c)},[e,n,i,h]),m=o.useCallback((t,r)=>{n.debug(`Updating column ${t} width to ${r}`);const o=Qe(e),a=o.lookup[t],l=(0,y.A)({},a,{width:r,hasBeenResized:!0});i(_o((0,y.A)({},o,{lookup:(0,y.A)({},o.lookup,{[t]:l})}),e.current.getRootDimensions())),e.current.publishEvent("columnWidthChange",{element:e.current.getColumnHeaderElement(t),colDef:l,width:r})},[e,n,i]),A={setColumnIndex:g};Bl(e,{getColumn:a,getAllColumns:l,getColumnIndex:c,getColumnPosition:u,getVisibleColumns:s,getColumnIndexRelativeToVisibleColumns:h,updateColumns:f,setColumnVisibilityModel:d,setColumnVisibility:p,setColumnWidth:m},"public"),Bl(e,A,t.signature===el.DataGrid?"private":"public");const b=o.useCallback((n,r)=>{const o={},i=He(e);(!r.exportOnlyDirtyModels||null!=t.columnVisibilityModel||Object.keys(t.initialState?.columns?.columnVisibilityModel??{}).length>0||Object.keys(i).length>0)&&(o.columnVisibilityModel=i),o.orderedFields=je(e);const a=$e(e),l={};return a.forEach(e=>{if(e.hasBeenResized){const t={};Po.forEach(n=>{let r=e[n];r===1/0&&(r=-1),t[n]=r}),l[e.field]=t}}),Object.keys(l).length>0&&(o.dimensions=l),(0,y.A)({},n,{columns:o})},[e,t.columnVisibilityModel,t.initialState?.columns]),v=o.useCallback((t,n)=>{const r=n.stateToRestore.columns,o=r?.columnVisibilityModel;if(null==r)return t;const i=Oo({apiRef:e,columnsToUpsert:[],initialState:r,columnVisibilityModel:o,keepOnlyColumnsToUpsert:!1});return null!=r&&e.current.setState(e=>(0,y.A)({},e,{columns:(0,y.A)({},e.columns,{lookup:i.lookup,orderedFields:i.orderedFields,initialColumnVisibilityModel:i.initialColumnVisibilityModel})})),null!=o&&e.current.setState(e=>(0,y.A)({},e,{columns:(0,y.A)({},e.columns,{columnVisibilityModel:o})})),null!=r&&e.current.publishEvent("columnsChange",i.orderedFields),t},[e]),w=o.useCallback((e,n)=>{if(n===nt.columns){const e=t.slots.columnsPanel;return(0,r.jsx)(e,(0,y.A)({},t.slotProps?.columnsPanel))}return e},[t.slots.columnsPanel,t.slotProps?.columnsPanel]),C=o.useCallback(n=>{const r=fi(e);return t.disableColumnSelector||r?n:[...n,"columnMenuColumnsItem"]},[t.disableColumnSelector,e]);ws(e,"columnMenu",C),ws(e,"exportState",b),ws(e,"restoreState",v),ws(e,"preferencePanel",w);const S=o.useRef(null);$t(e,"viewportInnerSizeChange",t=>{if(S.current!==t.width){if(S.current=t.width,!Ve(e).some(e=>e.flex&&e.flex>0))return;i(_o(Qe(e),e.current.getRootDimensions()))}});const x=o.useCallback(()=>{n.info("Columns pipe processing have changed, regenerating the columns");const t=Oo({apiRef:e,columnsToUpsert:[],initialState:void 0,keepOnlyColumnsToUpsert:!1});i(t)},[e,n,i]);_l(e,"hydrateColumns",x),o.useEffect(()=>{if(e.current.caches.columns.lastColumnsProp===t.columns)return;e.current.caches.columns.lastColumnsProp=t.columns,n.info(`GridColumns have changed, new length ${t.columns.length}`);const r=Oo({apiRef:e,initialState:void 0,columnsToUpsert:t.columns,keepOnlyColumnsToUpsert:!0,updateInitialVisibilityModel:!0,columnVisibilityModel:t.columnVisibilityModel});i(r)},[n,e,i,t.columns,t.columnVisibilityModel]),o.useEffect(()=>{void 0!==t.columnVisibilityModel&&e.current.setColumnVisibilityModel(t.columnVisibilityModel)},[e,n,t.columnVisibilityModel])}(e,t),((e,t,n)=>{const r=ls(e,"useGridRows"),i=o.useRef(Date.now()),a=o.useRef(t.rowCount),l=(0,Vt.A)(),{setRowIndex:s,setRowPosition:c}=n.hooks.useGridRowsOverridableMethods(e,t),u=o.useCallback(t=>{const n=Et(e)[t];if(n)return n;const r=kt(e,t);return r&&tr(r)?{[qn]:t}:null},[e]),d=o.useCallback(t=>lr(e,t),[e]),f=o.useCallback(({cache:n,throttle:r})=>{const o=()=>{i.current=Date.now(),e.current.setState(n=>(0,y.A)({},n,{rows:Zn({apiRef:e,rowCountProp:t.rowCount,loadingProp:t.loading,previousTree:It(e),previousTreeDepths:Pt(e),previousGroupsToFetch:Rt(e)})})),e.current.publishEvent("rowsSet")};if(l.clear(),e.current.caches.rows=n,!r)return void o();const a=t.throttleRowsMs-(Date.now()-i.current);a>0?l.start(a,o):o()},[t.throttleRowsMs,t.rowCount,t.loading,e,l]),p=o.useCallback(n=>{if(r.debug(`Updating all rows, new length ${n.length}`),!t.dataSource&&fi(e))return void e.current.updateNonPivotRows(n,!1);const o=Jn({rows:n,getRowId:t.getRowId,loading:t.loading,rowCount:t.rowCount}),i=e.current.caches.rows;o.rowsBeforePartialUpdates=i.rowsBeforePartialUpdates,f({cache:o,throttle:!0})},[r,t.getRowId,t.dataSource,t.loading,t.rowCount,f,e]),h=o.useCallback(n=>{if(t.signature===el.DataGrid&&n.length>1)throw new Error(["MUI X: You cannot update several rows at once in `apiRef.current.updateRows` on the DataGrid.","You need to upgrade to DataGridPro or DataGridPremium component to unlock this feature."].join("\n"));if(!t.dataSource&&fi(e))return void e.current.updateNonPivotRows(n);const r=ir(e,n,t.getRowId),o=rr({updates:r,getRowId:t.getRowId,previousCache:e.current.caches.rows});f({cache:o,throttle:!0})},[t.signature,t.dataSource,t.getRowId,f,e]),g=o.useCallback((n,r)=>{const o=ir(e,n,t.getRowId),i=rr({updates:o,getRowId:t.getRowId,previousCache:e.current.caches.rows,groupKeys:r??[]});f({cache:i,throttle:!1})},[t.getRowId,f,e]),m=o.useCallback(t=>{r.debug(`Setting loading to ${t}`),e.current.setState(e=>(0,y.A)({},e,{rows:(0,y.A)({},e.rows,{loading:t})})),e.current.caches.rows.loadingPropBeforePartialUpdates=t},[e,r]),A=o.useCallback(()=>{const t=_t(e),n=Et(e);return new Map(t.map(e=>[e,n[e]??{}]))},[e]),b=o.useCallback(()=>Ct(e),[e]),v=o.useCallback(()=>_t(e),[e]),w=o.useCallback(t=>{const{rowIdToIndexMap:n}=ml(e);return n.get(t)},[e]),C=o.useCallback((t,n)=>{const r=kt(e,t);if(!r)throw new Error(`MUI X: No row with id #${t} found.`);if("group"!==r.type)throw new Error("MUI X: Only group nodes can be expanded or collapsed.");const o=(0,y.A)({},r,{childrenExpanded:n});e.current.setState(e=>(0,y.A)({},e,{rows:(0,y.A)({},e.rows,{tree:(0,y.A)({},e.rows.tree,{[t]:o})})})),e.current.publishEvent("rowExpansionChange",o)},[e]),S=o.useCallback(()=>{const t=(0,y.A)({},It(e)),n=e=>{const r=t[e];"group"===r?.type&&(t[e]=(0,y.A)({},r,{childrenExpanded:!0}),r.children.forEach(n))};n(Un),e.current.setState(e=>(0,y.A)({},e,{rows:(0,y.A)({},e.rows,{tree:t})})),e.current.publishEvent("rowExpansionChange",t[Un])},[e]),x=o.useCallback(()=>{const t=(0,y.A)({},It(e)),n=e=>{const r=t[e];"group"===r?.type&&(t[e]=(0,y.A)({},r,{childrenExpanded:!1}),r.children.forEach(n))};n(Un),e.current.setState(e=>(0,y.A)({},e,{rows:(0,y.A)({},e.rows,{tree:t})})),e.current.publishEvent("rowExpansionChange",t[Un])},[e]),E=o.useCallback(t=>kt(e,t)??null,[e]),I=o.useCallback(({skipAutoGeneratedRows:t=!0,groupId:n,applySorting:r,applyFiltering:o,directChildrenOnly:i=!1})=>{const a=It(e);let l;if(r){const r=a[n];if(!r)return[];const o=Vo(e);l=[];for(let e=o.findIndex(e=>e===n)+1;e<o.length&&(i?a[o[e]].depth===r.depth+1:a[o[e]].depth>r.depth);e+=1){const n=o[e];t&&tr(a[n])||l.push(n)}}else l=nr(a,n,t,i);if(o){const t=Zo(e);l=Ho(t)?l:l.filter(e=>!1!==t[e])}return l},[e]),k={getRow:u,setLoading:m,getRowId:d,getRowModels:A,getRowsCount:b,getAllRowIds:v,setRows:p,updateRows:h,getRowNode:E,getRowIndexRelativeToVisibleRows:w,unstable_replaceRows:o.useCallback((n,r)=>{if(t.signature===el.DataGrid&&r.length>1)throw new Error(["MUI X: You cannot replace rows using `apiRef.current.unstable_replaceRows` on the DataGrid.","You need to upgrade to DataGridPro or DataGridPremium component to unlock this feature."].join("\n"));if(0===r.length)return;if(Bt(e)>1)throw new Error("`apiRef.current.unstable_replaceRows` is not compatible with tree data and row grouping");const o=(0,y.A)({},It(e)),i=(0,y.A)({},Et(e)),a=o[Un],l=[...a.children],s=new Set;for(let e=0;e<r.length;e+=1){const a=r[e],c=Yn(a,t.getRowId,"A row was provided without id when calling replaceRows()."),[u]=l.splice(n+e,1,c);s.has(u)||(delete i[u],delete o[u]);const d={id:c,depth:0,parent:Un,type:"leaf",groupingKey:null};i[c]=a,o[c]=d,s.add(c)}o[Un]=(0,y.A)({},a,{children:l});const c=l.filter(e=>"leaf"===o[e]?.type);e.current.caches.rows.dataRowIdToModelLookup=i,e.current.setState(e=>(0,y.A)({},e,{rows:(0,y.A)({},e.rows,{loading:t.loading,totalRowCount:Math.max(t.rowCount||0,l.length),dataRowIdToModelLookup:i,dataRowIds:c,tree:o})})),e.current.publishEvent("rowsSet")},[e,t.signature,t.getRowId,t.loading,t.rowCount])},R={setRowIndex:s,setRowPosition:c,setRowChildrenExpansion:C,getRowGroupChildren:I,expandAllRows:S,collapseAllRows:x},M={updateNestedRows:g},P=o.useCallback(()=>{let n;r.info("Row grouping pre-processing have changed, regenerating the row tree"),n=e.current.caches.rows.rowsBeforePartialUpdates===t.rows?(0,y.A)({},e.current.caches.rows,{updates:{type:"full",rows:_t(e)}}):Jn({rows:t.rows,getRowId:t.getRowId,loading:t.loading,rowCount:t.rowCount}),f({cache:n,throttle:!1})},[r,e,t.rows,t.getRowId,t.loading,t.rowCount,f]),B=(0,G.A)(()=>t.dataSource),_=o.useCallback(e=>{t.dataSource&&t.dataSource!==B.current?B.current=t.dataSource:"rowTreeCreation"===e&&P()},[P,B,t.dataSource]),T=o.useCallback(()=>{e.current.getActiveStrategy(ns.RowTree)!==Mt(e)&&P()},[e,P]);$t(e,"activeStrategyProcessorChange",_),$t(e,"strategyAvailabilityChange",T);const O=o.useCallback(()=>{e.current.setState(n=>{const r=e.current.unstable_applyPipeProcessors("hydrateRows",{tree:It(e),treeDepths:Pt(e),dataRowIds:_t(e),dataRowIdToModelLookup:Et(e)});return(0,y.A)({},n,{rows:(0,y.A)({},n.rows,r,{totalTopLevelRowCount:Xn({tree:r.tree,rowCountProp:t.rowCount})})})}),e.current.publishEvent("rowsSet")},[e,t.rowCount]);_l(e,"hydrateRows",O),Bl(e,k,"public"),Bl(e,R,t.signature===el.DataGrid?"private":"public"),Bl(e,M,"private");const D=o.useRef(!0);o.useEffect(()=>{if(D.current)return void(D.current=!1);let n=!1;t.rowCount!==a.current&&(n=!0,a.current=t.rowCount);const o=t.dataSource?Tt(e):t.rows,i=e.current.caches.rows.rowsBeforePartialUpdates===o,l=e.current.caches.rows.loadingPropBeforePartialUpdates===t.loading,s=e.current.caches.rows.rowCountPropBeforePartialUpdates===t.rowCount;i&&(l||(e.current.setState(e=>(0,y.A)({},e,{rows:(0,y.A)({},e.rows,{loading:t.loading})})),e.current.caches.rows.loadingPropBeforePartialUpdates=t.loading),s||(e.current.setState(e=>(0,y.A)({},e,{rows:(0,y.A)({},e.rows,{totalRowCount:Math.max(t.rowCount||0,e.rows.totalRowCount),totalTopLevelRowCount:Math.max(t.rowCount||0,e.rows.totalTopLevelRowCount)})})),e.current.caches.rows.rowCountPropBeforePartialUpdates=t.rowCount),!n)||(r.debug(`Updating all rows, new length ${o?.length}`),f({cache:Jn({rows:o,getRowId:t.getRowId,loading:t.loading,rowCount:t.rowCount}),throttle:!1}))},[t.rows,t.rowCount,t.getRowId,t.loading,t.dataSource,r,f,e])})(e,t,n),((e,t)=>{const n=o.useCallback((t,n=!1)=>{const r=e.current.virtualizer.store,{range:o,rows:i}=ml(e);if(n&&r.set("rowSpanning",qc),null===o||!Wc(t))return;const a=n?qc:qa.selectors.state(r.state),l=(s={firstRowIndex:t.firstRowIndex,lastRowIndex:Math.min(t.lastRowIndex,o.lastRowIndex-o.firstRowIndex+1)},c=a.processedRange,s.firstRowIndex>=c.firstRowIndex&&s.lastRowIndex<=c.lastRowIndex?null:s.firstRowIndex>=c.firstRowIndex&&s.lastRowIndex>c.lastRowIndex?{firstRowIndex:c.lastRowIndex,lastRowIndex:s.lastRowIndex}:s.firstRowIndex<c.firstRowIndex&&s.lastRowIndex<=c.lastRowIndex?{firstRowIndex:s.firstRowIndex,lastRowIndex:c.firstRowIndex-1}:s);var s,c;if(null===l)return;const u=Ve(e),d=((e,t,n,r,o,i)=>{const a=e.current.virtualizer,l=i?qc:qa.selectors.state(a.store.state),s=(0,y.A)({},l.caches.spannedCells),c=(0,y.A)({},l.caches.hiddenCells),u=(0,y.A)({},l.caches.hiddenCellOriginMap),d={firstRowIndex:Math.min(l.processedRange.firstRowIndex,o.firstRowIndex),lastRowIndex:Math.max(l.processedRange.lastRowIndex,o.lastRowIndex)};return t.forEach((t,i)=>{for(let a=o.firstRowIndex;a<o.lastRowIndex;a+=1){const l=n[a];if(c[l.id]?.[i])continue;const d=Uc(l.model,t,e);if(null==d)continue;let f=l.id,p=a,h=0;const g=[];if(a===o.firstRowIndex){let o=a-1,l=n[o];for(;o>=r.firstRowIndex&&l&&Uc(l.model,t,e)===d;){const e=n[o+1];c[e.id]?c[e.id][i]=!0:c[e.id]={[i]:!0},g.push(a),h+=1,f=l.id,p=o,o-=1,l=n[o]}}g.forEach(e=>{u[e]?u[e][i]=p:u[e]={[i]:p}});let m=a+1;for(;m<=r.lastRowIndex&&n[m]&&Uc(n[m].model,t,e)===d;){const e=n[m];c[e.id]?c[e.id][i]=!0:c[e.id]={[i]:!0},u[m]?u[m][i]=p:u[m]={[i]:p},m+=1,h+=1}h>0&&(s[f]?s[f][i]=h+1:s[f]={[i]:h+1})}}),{caches:{spannedCells:s,hiddenCells:c,hiddenCellOriginMap:u},processedRange:d}})(e,u,i,o,l,n),f=Object.keys(d.caches.spannedCells).length,p=Object.keys(d.caches.hiddenCells).length,h=Object.keys(a.caches.spannedCells).length,g=Object.keys(a.caches.hiddenCells).length;(n||f!==h||p!==g)&&(0!==f||0!==h)&&r.set("rowSpanning",d)},[e]),{schedule:r,cancel:i}=function(e){const t=o.useRef(null),n=o.useCallback((...n)=>{t.current||queueMicrotask(()=>{t.current&&t.current()}),t.current=()=>{t.current=null,e(...n)}},[e]);return o.useLayoutEffect(()=>{t.current&&t.current()}),{schedule:n,cancel:()=>!!t.current&&(t.current=null,!0)}}(n),a=o.useCallback(()=>{const t=yl(e);Wc(t)&&r(t,!0)},[e,r]);$t(e,"renderedRowsIntervalChange",hn(t.rowSpanning,e=>{const t=i();n(e,t)})),$t(e,"sortedRowsSet",hn(t.rowSpanning,a)),$t(e,"paginationModelChange",hn(t.rowSpanning,a)),$t(e,"filteredRowsSet",hn(t.rowSpanning,a)),$t(e,"columnsChange",hn(t.rowSpanning,a)),$t(e,"rowExpansionChange",hn(t.rowSpanning,a)),o.useEffect(()=>{const r=e.current.virtualizer?.store;r&&(t.rowSpanning?r.state.rowSpanning===qc&&n(yl(e)):r.state.rowSpanning!==qc&&r.set("rowSpanning",qc))},[e,t.rowSpanning,n])})(e,t),function(e,t,n){const r=o.useCallback(t=>({field:t,colDef:e.current.getColumn(t)}),[e]),i=o.useCallback(t=>{const n=e.current.getRow(t);if(!n)throw new mc(`No row with id #${t} found`);return{id:t,columns:e.current.getAllColumns(),row:n}},[e]),a=o.useCallback((t,n,r,{cellMode:o,colDef:i,hasFocus:a,rowNode:l,tabIndex:s,value:c,formattedValue:u})=>{const d={id:t,field:n,row:r,rowNode:l,colDef:i,cellMode:o,hasFocus:a,tabIndex:s,value:void 0!==c?c:e.current.getRowValue(r,i),formattedValue:void 0!==u?u:e.current.getRowFormattedValue(r,i),isEditable:!1,api:e.current};return d.isEditable=i&&e.current.isCellEditable(d),d},[e]),l=o.useCallback((n,r)=>{const o=e.current.getRow(n),i=kt(e,n);if(!o||!i)throw new mc(`No row with id #${n} found`);const a=Ai(e),l=wi(e),s=e.current.getCellMode(n,r);return e.current.getCellParamsForRow(n,r,o,{colDef:t.listView&&t.listViewColumn?.field===r?Fe(e):e.current.getColumn(r),rowNode:i,hasFocus:null!==a&&a.field===r&&a.id===n,tabIndex:l&&l.field===r&&l.id===n?0:-1,cellMode:s})},[e,t.listView,t.listViewColumn?.field]),s=o.useCallback(t=>e.current.rootElementRef.current?function(e,t){return e.querySelector(`[role="columnheader"][data-field="${Gs(t)}"]`)}(e.current.rootElementRef.current,t):null,[e]),c=o.useCallback(t=>e.current.rootElementRef.current?function(e,t){return e.querySelector(Vs(t))}(e.current.rootElementRef.current,t):null,[e]),u=o.useCallback((t,n)=>e.current.rootElementRef.current?function(e,{id:t,field:n}){const r=`${Vs(t)} .${L.cell}[data-field="${Gs(n)}"]`;return e.querySelector(r)}(e.current.rootElementRef.current,{id:t,field:n}):null,[e]),d=n.hooks.useGridParamsOverridableMethods(e),f={getCellValue:d.getCellValue,getCellParams:l,getCellElement:u,getRowValue:d.getRowValue,getRowFormattedValue:d.getRowFormattedValue,getRowParams:i,getRowElement:c,getColumnHeaderParams:r,getColumnHeaderElement:s},p={getCellParamsForRow:a};Bl(e,f,"public"),Bl(e,p,"private")}(e,t,n),(e=>{const t=()=>e.current.virtualizer.api.resetColSpan(),n={unstable_getCellColSpanInfo:(...t)=>e.current.virtualizer.api.getCellColSpanInfo(...t)},r={resetColSpan:t,calculateColSpan:(...t)=>{e.current.virtualizer.api.calculateColSpan(...t)}};Bl(e,n,"public"),Bl(e,r,"private"),$t(e,"columnOrderChange",t)})(e),((e,t)=>{const n=o.useCallback(t=>Io(e)[t]??[],[e]),r=o.useCallback(()=>ko(e),[e]);Bl(e,{getColumnGroupPath:n,getAllGroupDetails:r},"public");const i=o.useCallback(()=>{const n=Pc(t.columnGroupingModel??[]);e.current.setState(e=>{const t=e.columns?.orderedFields??[],r=e.pinnedColumns??{},o=Bc(t,n,r);return(0,y.A)({},e,{columnGrouping:(0,y.A)({},e.columnGrouping,{headerStructure:o})})})},[e,t.columnGroupingModel]),a=o.useCallback(t=>{if(!t&&!e.current.caches.columnGrouping.lastColumnGroupingModel)return;e.current.caches.columnGrouping.lastColumnGroupingModel=t;const n=e.current.getPinnedColumns?.()??{},r=je(e),o=We(e),i=Rc(t??[]),a=Pc(t??[]),l=Bc(r,a,n),s=0===o.length?0:Math.max(...o.map(e=>a[e]?.length??0));e.current.setState(e=>(0,y.A)({},e,{columnGrouping:{lookup:i,unwrappedGroupingModel:a,headerStructure:l,maxDepth:s}}))},[e]);$t(e,"columnIndexChange",i),$t(e,"columnsChange",()=>{a(t.columnGroupingModel)}),$t(e,"columnVisibilityModelChange",()=>{a(t.columnGroupingModel)}),o.useEffect(()=>{t.columnGroupingModel!==e.current.caches.columnGrouping.lastColumnGroupingModel&&a(t.columnGroupingModel)},[e,a,t.columnGroupingModel])})(e,t),((e,t,n)=>{((e,t)=>{const[n,r]=o.useState({}),i=o.useRef(n),a=o.useRef({}),{processRowUpdate:l,onProcessRowUpdateError:s,cellModesModel:c,onCellModesModelChange:u}=t,d=e=>(...n)=>{t.editMode===Mr.Cell&&e(...n)},f=o.useCallback((t,n)=>{const r=e.current.getCellParams(t,n);if(!e.current.isCellEditable(r))throw new Error(`MUI X: The cell with id=${t} and field=${n} is not editable.`)},[e]),p=o.useCallback((t,n,r)=>{if(e.current.getCellMode(t,n)!==r)throw new Error(`MUI X: The cell with id=${t} and field=${n} is not in ${r} mode.`)},[e]),h=o.useCallback((t,n)=>{if(!t.isEditable)return;if(t.cellMode===Pr.Edit)return;const r=(0,y.A)({},t,{reason:kr.cellDoubleClick});e.current.publishEvent("cellEditStart",r,n)},[e]),g=o.useCallback((t,n)=>{if(t.cellMode===Pr.View)return;if(e.current.getCellMode(t.id,t.field)===Pr.View)return;const r=(0,y.A)({},t,{reason:Rr.cellFocusOut});e.current.publishEvent("cellEditStop",r,n)},[e]),m=o.useCallback((t,n)=>{if(t.cellMode===Pr.Edit){if(229===n.which)return;let r;if("Escape"===n.key?r=Rr.escapeKeyDown:"Enter"===n.key?r=Rr.enterKeyDown:"Tab"===n.key&&(r=n.shiftKey?Rr.shiftTabKeyDown:Rr.tabKeyDown,n.preventDefault()),r){const o=(0,y.A)({},t,{reason:r});e.current.publishEvent("cellEditStop",o,n)}}else if(t.isEditable){let r;if(!e.current.unstable_applyPipeProcessors("canStartEditing",!0,{event:n,cellParams:t,editMode:"cell"}))return;if(Gr(n)?r=kr.printableKeyDown:Ur(n)?r=kr.pasteKeyDown:"Enter"===n.key?(r=kr.enterKeyDown,n.preventDefault()):"Backspace"!==n.key&&"Delete"!==n.key||(r=kr.deleteKeyDown),r){const o=(0,y.A)({},t,{reason:r,key:n.key});e.current.publishEvent("cellEditStart",o,n)}}},[e]),A=o.useCallback(t=>{const{id:n,field:r,reason:o}=t,i={id:n,field:r};o!==kr.printableKeyDown&&o!==kr.deleteKeyDown&&o!==kr.pasteKeyDown||(i.deleteValue=!0),e.current.startCellEditMode(i)},[e]),b=o.useCallback(t=>{const{id:n,field:r,reason:o}=t;let i;e.current.runPendingEditCellValueMutation(n,r),o===Rr.enterKeyDown?i="below":o===Rr.tabKeyDown?i="right":o===Rr.shiftTabKeyDown&&(i="left");const a="escapeKeyDown"===o;e.current.stopCellEditMode({id:n,field:r,ignoreModifications:a,cellToFocusAfter:i})},[e]);var v;$t(e,"cellDoubleClick",d(h)),$t(e,"cellFocusOut",d(g)),$t(e,"cellKeyDown",d(m)),$t(e,"cellEditStart",d(A)),$t(e,"cellEditStop",d(b)),Gt(e,"cellEditStart",t.onCellEditStart),Gt(e,"cellEditStop",(v=t.onCellEditStop,async(...t)=>{if(v){const{id:n,field:r}=t[0],o=e.current.state.editRows,i=o[n][r]?.error;i||v(...t)}}));const w=o.useCallback((t,n)=>{const r=rc(e);return r[t]&&r[t][n]?Pr.Edit:Pr.View},[e]),C=(0,Nt.A)(n=>{const o=n!==t.cellModesModel;u&&o&&u(n,{api:e.current}),t.cellModesModel&&o||(r(n),i.current=n,e.current.publishEvent("cellModesModelChange",n))}),S=o.useCallback((e,t,n)=>{const r=(0,y.A)({},i.current);if(null!==n)r[e]=(0,y.A)({},r[e],{[t]:(0,y.A)({},n)});else{const n=r[e],o=(0,x.A)(n,[t].map(ts));r[e]=o,0===Object.keys(r[e]).length&&delete r[e]}C(r)},[C]),E=o.useCallback((t,n,r)=>{e.current.setState(e=>{const o=(0,y.A)({},e.editRows);return null!==r?o[t]=(0,y.A)({},o[t],{[n]:(0,y.A)({},r)}):(delete o[t][n],0===Object.keys(o[t]).length&&delete o[t]),(0,y.A)({},e,{editRows:o})})},[e]),I=o.useCallback(e=>{const{id:t,field:n}=e,r=(0,x.A)(e,lc);f(t,n),p(t,n,Pr.View),S(t,n,(0,y.A)({mode:Pr.Edit},r))},[f,p,S]),k=(0,Nt.A)(async t=>{const{id:n,field:r,deleteValue:o,initialValue:i}=t,a=e.current.getCellValue(n,r);let l=a;o?l=ac(e.current.getColumn(r)):i&&(l=i);const s=e.current.getColumn(r),c=!!s.preProcessEditCellProps&&o;let u={value:l,error:!1,isProcessingProps:c};if(E(n,r,u),e.current.setCellFocus(n,r),c&&(u=await Promise.resolve(s.preProcessEditCellProps({id:n,row:e.current.getRow(n),props:u,hasChanged:l!==a})),e.current.getCellMode(n,r)===Pr.Edit)){const t=rc(e);E(n,r,(0,y.A)({},u,{value:t[n][r].value,isProcessingProps:!1}))}}),R=o.useCallback(e=>{const{id:t,field:n}=e,r=(0,x.A)(e,sc);p(t,n,Pr.Edit),S(t,n,(0,y.A)({mode:Pr.View},r))},[p,S]),M=(0,Nt.A)(async n=>{const{id:r,field:o,ignoreModifications:i,cellToFocusAfter:c="none"}=n;p(r,o,Pr.Edit),e.current.runPendingEditCellValueMutation(r,o);const u=()=>{E(r,o,null),S(r,o,null),"none"!==c&&e.current.moveFocusToRelativeCell(r,o,c)};if(i)return void u();const d=rc(e),{error:f,isProcessingProps:h}=d[r][o],g=e.current.getRow(r);if(f||h)return a.current[r][o].mode=Pr.Edit,void S(r,o,{mode:Pr.Edit});const m=e.current.getRowWithUpdatedValuesFromCellEditing(r,o);if(t.dataSource?.updateRow){if(la(g,m))return void u();const t=()=>{a.current[r][o].mode=Pr.Edit,S(r,o,{mode:Pr.Edit})},n={rowId:r,updatedRow:m,previousRow:g};try{await e.current.dataSource.editRow(n),u()}catch{t()}}else if(l){const t=e=>{a.current[r][o].mode=Pr.Edit,S(r,o,{mode:Pr.Edit}),s&&s(e)};try{Promise.resolve(l(m,g,{rowId:r})).then(t=>{e.current.updateRows([t]),u()}).catch(t)}catch(e){t(e)}}else e.current.updateRows([m]),u()}),P={setCellEditingEditCellValue:o.useCallback(async t=>{const{id:n,field:r,value:o,debounceMs:i,unstable_skipValueParser:a}=t;f(n,r),p(n,r,Pr.Edit);const l=e.current.getColumn(r),s=e.current.getRow(n);let c=o;l.valueParser&&!a&&(c=l.valueParser(o,s,l,e));let u=rc(e),d=(0,y.A)({},u[n][r],{value:c,changeReason:i?"debouncedSetEditCellValue":"setEditCellValue"});if(l.preProcessEditCellProps){const e=o!==u[n][r].value;d=(0,y.A)({},d,{isProcessingProps:!0}),E(n,r,d),d=await Promise.resolve(l.preProcessEditCellProps({id:n,row:s,props:d,hasChanged:e}))}return e.current.getCellMode(n,r)!==Pr.View&&(u=rc(e),d=(0,y.A)({},d,{isProcessingProps:!1}),d.value=l.preProcessEditCellProps?u[n][r].value:c,E(n,r,d),u=rc(e),!u[n]?.[r]?.error)},[e,f,p,E]),getRowWithUpdatedValuesFromCellEditing:o.useCallback((t,n)=>{const r=e.current.getColumn(n),o=rc(e),i=e.current.getRow(t);if(!o[t]||!o[t][n])return e.current.getRow(t);const{value:a}=o[t][n];return r.valueSetter?r.valueSetter(a,i,r,e):(0,y.A)({},i,{[n]:a})},[e])};Bl(e,{getCellMode:w,startCellEditMode:I,stopCellEditMode:R},"public"),Bl(e,P,"private"),o.useEffect(()=>{c&&C(c)},[c,C]),(0,Ut.A)(()=>{const t=Et(e),r=a.current;a.current=pn(n),Object.entries(n).forEach(([n,o])=>{Object.entries(o).forEach(([o,i])=>{const a=r[n]?.[o]?.mode||Pr.View,l=t[n]?e.current.getRowId(t[n]):n;i.mode===Pr.Edit&&a===Pr.View?k((0,y.A)({id:l,field:o},i)):i.mode===Pr.View&&a===Pr.Edit&&M((0,y.A)({id:l,field:o},i))})})},[e,n,k,M])})(e,t),((e,t)=>{const[n,r]=o.useState({}),i=o.useRef(n),a=o.useRef({}),l=o.useRef({}),s=o.useRef(void 0),c=o.useRef(null),{processRowUpdate:u,onProcessRowUpdateError:d,rowModesModel:f,onRowModesModelChange:p}=t,h=e=>(...n)=>{t.editMode===Mr.Row&&e(...n)},g=o.useCallback((t,n)=>{const r=e.current.getCellParams(t,n);if(!e.current.isCellEditable(r))throw new Error(`MUI X: The cell with id=${t} and field=${n} is not editable.`)},[e]),m=o.useCallback((t,n)=>{if(e.current.getRowMode(t)!==n)throw new Error(`MUI X: The row with id=${t} is not in ${n} mode.`)},[e]),A=o.useCallback(t=>{const n=rc(e);return Object.values(n[t]).some(e=>e.error)},[e]),b=o.useCallback((t,n)=>{if(!t.isEditable)return;if(e.current.getRowMode(t.id)===Br.Edit)return;const r=e.current.getRowParams(t.id),o=(0,y.A)({},r,{field:t.field,reason:cc.cellDoubleClick});e.current.publishEvent("rowEditStart",o,n)},[e]),v=o.useCallback(e=>{c.current=e},[]),w=o.useCallback((t,n)=>{t.isEditable&&e.current.getRowMode(t.id)!==Br.View&&(c.current=null,s.current=setTimeout(()=>{if(c.current?.id!==t.id){if(!e.current.getRow(t.id))return;if(e.current.getRowMode(t.id)===Br.View)return;if(A(t.id))return;const r=e.current.getRowParams(t.id),o=(0,y.A)({},r,{field:t.field,reason:uc.rowFocusOut});e.current.publishEvent("rowEditStop",o,n)}}))},[e,A]);o.useEffect(()=>()=>{clearTimeout(s.current)},[]);const C=o.useCallback((t,n)=>{if(t.cellMode===Br.Edit){if(229===n.which)return;let r;if("Escape"===n.key)r=uc.escapeKeyDown;else if("Enter"===n.key)r=uc.enterKeyDown;else if("Tab"===n.key){const o=We(e).filter(n=>e.current.getColumn(n).type===ro||e.current.isCellEditable(e.current.getCellParams(t.id,n)));if(n.shiftKey?t.field===o[0]&&(r=uc.shiftTabKeyDown):t.field===o[o.length-1]&&(r=uc.tabKeyDown),n.preventDefault(),!r){const r=o.findIndex(e=>e===t.field),i=o[n.shiftKey?r-1:r+1];e.current.setCellFocus(t.id,i)}}if(r){if(r!==uc.escapeKeyDown&&A(t.id))return;const o=(0,y.A)({},e.current.getRowParams(t.id),{reason:r,field:t.field});e.current.publishEvent("rowEditStop",o,n)}}else if(t.isEditable){let r;if(!e.current.unstable_applyPipeProcessors("canStartEditing",!0,{event:n,cellParams:t,editMode:"row"}))return;if(Gr(n)||Ur(n)?r=cc.printableKeyDown:"Enter"===n.key?r=cc.enterKeyDown:"Backspace"!==n.key&&"Delete"!==n.key||(r=cc.deleteKeyDown),r){const o=e.current.getRowParams(t.id),i=(0,y.A)({},o,{field:t.field,reason:r,key:f&&Gr(n)?n.key:void 0});e.current.publishEvent("rowEditStart",i,n)}}},[e,A,f]),S=o.useCallback(t=>{const{id:n,field:r,reason:o}=t,i={id:n,fieldToFocus:r};o!==cc.printableKeyDown&&o!==cc.deleteKeyDown||(f&&o===cc.printableKeyDown&&t.key&&r?i.initialValue=t.key:i.deleteValue=!!r),e.current.startRowEditMode(i)},[e,f]),E=o.useCallback(t=>{const{id:n,reason:r,field:o}=t;let i;e.current.runPendingEditCellValueMutation(n),r===uc.enterKeyDown?i="below":r===uc.tabKeyDown?i="right":r===uc.shiftTabKeyDown&&(i="left");const a="escapeKeyDown"===r;e.current.stopRowEditMode({id:n,ignoreModifications:a,field:o,cellToFocusAfter:i})},[e]);$t(e,"cellDoubleClick",h(b)),$t(e,"cellFocusIn",h(v)),$t(e,"cellFocusOut",h(w)),$t(e,"cellKeyDown",h(C)),$t(e,"rowEditStart",h(S)),$t(e,"rowEditStop",h(E)),Gt(e,"rowEditStart",t.onRowEditStart),Gt(e,"rowEditStop",t.onRowEditStop);const I=o.useCallback(n=>oc(e,{rowId:n,editMode:t.editMode})?Br.Edit:Br.View,[e,t.editMode]),k=(0,Nt.A)(n=>{const o=n!==t.rowModesModel;p&&o&&p(n,{api:e.current}),t.rowModesModel&&o||(r(n),i.current=n,e.current.publishEvent("rowModesModelChange",n))}),R=o.useCallback((e,t)=>{const n=(0,y.A)({},i.current);null!==t?n[e]=(0,y.A)({},t):delete n[e],k(n)},[k]),M=o.useCallback((t,n)=>{e.current.setState(e=>{const r=(0,y.A)({},e.editRows);return null!==n?r[t]=n:delete r[t],(0,y.A)({},e,{editRows:r})})},[e]),P=o.useCallback((t,n,r)=>{e.current.setState(e=>{const o=(0,y.A)({},e.editRows);return null!==r?o[t]=(0,y.A)({},o[t],{[n]:(0,y.A)({},r)}):(delete o[t][n],0===Object.keys(o[t]).length&&delete o[t]),(0,y.A)({},e,{editRows:o})})},[e]),B=o.useCallback(e=>{const{id:t}=e,n=(0,x.A)(e,dc);m(t,Br.View),R(t,(0,y.A)({mode:Br.Edit},n))},[m,R]),_=(0,Nt.A)(t=>{const{id:n,fieldToFocus:r,deleteValue:o,initialValue:i}=t,a=e.current.getRow(n),s=$e(e),c=s.reduce((t,a)=>{const l=a.field;if(!e.current.getCellParams(n,l).isEditable)return t;const s=e.current.getColumn(l);let c=e.current.getCellValue(n,l);return r===l&&(o||i)&&(o?c=ac(s):i&&(c=i)),t[l]={value:c,error:!1,isProcessingProps:s.editable&&!!s.preProcessEditCellProps&&o},t},{});l.current[n]=a,M(n,c),r&&e.current.setCellFocus(n,r),s.filter(t=>e.current.getCellParams(n,t.field).isEditable&&t.editable&&!!t.preProcessEditCellProps&&o).forEach(t=>{const r=t.field,l=e.current.getCellValue(n,r),s=o?ac(t):i??l;Promise.resolve(t.preProcessEditCellProps({id:n,row:a,props:c[r],hasChanged:s!==l})).then(t=>{if(e.current.getRowMode(n)===Br.Edit){const o=rc(e);P(n,r,(0,y.A)({},t,{value:o[n][r].value,isProcessingProps:!1}))}})})}),T=o.useCallback(e=>{const{id:t}=e,n=(0,x.A)(e,fc);m(t,Br.Edit),R(t,(0,y.A)({mode:Br.View},n))},[m,R]),O=(0,Nt.A)(async n=>{const{id:r,ignoreModifications:o,field:i,cellToFocusAfter:s="none"}=n;e.current.runPendingEditCellValueMutation(r);const c=()=>{"none"!==s&&i&&e.current.moveFocusToRelativeCell(r,i,s),M(r,null),R(r,null),delete l.current[r]};if(o&&e.current.getRow(r))return void c();const f=rc(e);if(!f[r])return void c();const p=l.current[r];if(Object.values(f[r]).some(e=>e.isProcessingProps))return void(a.current[r].mode=Br.Edit);if(A(r))return a.current[r].mode=Br.Edit,void R(r,{mode:Br.Edit});const h=e.current.getRowWithUpdatedValuesFromRowEditing(r);if(t.dataSource?.updateRow){if(la(p,h))return void c();const t=()=>{a.current[r].mode=Br.Edit,R(r,{mode:Br.Edit})},n={rowId:r,updatedRow:h,previousRow:p};try{await e.current.dataSource.editRow(n),c()}catch{t()}}else if(u){const t=e=>{a.current[r]&&(a.current[r].mode=Br.Edit,R(r,{mode:Br.Edit})),d&&d(e)};try{Promise.resolve(u(h,p,{rowId:r})).then(t=>{e.current.getRow(r)&&e.current.updateRows([t]),c()}).catch(t)}catch(e){t(e)}}else e.current.getRow(r)&&e.current.updateRows([h]),c()}),D={setRowEditingEditCellValue:o.useCallback(t=>{const{id:n,field:r,value:o,debounceMs:i,unstable_skipValueParser:a}=t;g(n,r);const l=e.current.getColumn(r),s=e.current.getRow(n);let c=o;l.valueParser&&!a&&(c=l.valueParser(o,s,l,e));let u=rc(e),d=(0,y.A)({},u[n][r],{value:c,changeReason:i?"debouncedSetEditCellValue":"setEditCellValue"});return l.preProcessEditCellProps||P(n,r,d),new Promise(t=>{const o=[];if(l.preProcessEditCellProps){const i=d.value!==u[n][r].value;d=(0,y.A)({},d,{isProcessingProps:!0}),P(n,r,d);const a=u[n],f=(0,x.A)(a,[r].map(ts)),p=Promise.resolve(l.preProcessEditCellProps({id:n,row:s,props:d,hasChanged:i,otherFieldsProps:f})).then(o=>{e.current.getRowMode(n)!==Br.View?(u=rc(e),(o=(0,y.A)({},o,{isProcessingProps:!1})).value=l.preProcessEditCellProps?u[n][r].value:c,P(n,r,o)):t(!1)});o.push(p)}Object.entries(u[n]).forEach(([i,a])=>{if(i===r)return;const l=e.current.getColumn(i);if(!l.preProcessEditCellProps)return;a=(0,y.A)({},a,{isProcessingProps:!0}),P(n,i,a),u=rc(e);const c=u[n],d=(0,x.A)(c,[i].map(ts)),f=Promise.resolve(l.preProcessEditCellProps({id:n,row:s,props:a,hasChanged:!1,otherFieldsProps:d})).then(r=>{e.current.getRowMode(n)!==Br.View?(r=(0,y.A)({},r,{isProcessingProps:!1}),P(n,i,r)):t(!1)});o.push(f)}),Promise.all(o).then(()=>{e.current.getRowMode(n)===Br.Edit?(u=rc(e),t(!u[n][r].error)):t(!1)})})},[e,g,P]),getRowWithUpdatedValuesFromRowEditing:o.useCallback(t=>{const n=rc(e),r=e.current.getRow(t);if(!n[t])return e.current.getRow(t);let o=(0,y.A)({},l.current[t],r);return Object.entries(n[t]).forEach(([t,n])=>{const r=e.current.getColumn(t);r?.valueSetter?o=r.valueSetter(n.value,o,r,e):o[t]=n.value}),o},[e])};Bl(e,{getRowMode:I,startRowEditMode:B,stopRowEditMode:T},"public"),Bl(e,D,"private"),o.useEffect(()=>{f&&k(f)},[f,k]),(0,Ut.A)(()=>{const t=Et(e),r=a.current;a.current=pn(n);const o=new Set([...Object.keys(n),...Object.keys(r)]);Array.from(o).forEach(o=>{const i=n[o]??{mode:Br.View},a=r[o]?.mode||Br.View,l=t[o]?e.current.getRowId(t[o]):o;i.mode===Br.Edit&&a===Br.View?_((0,y.A)({id:l},i)):i.mode===Br.View&&a===Br.Edit&&O((0,y.A)({id:l},i))})},[e,n,M,_,O,R])})(e,t);const r=o.useRef({}),{isCellEditable:i}=t,a=n.hooks.useIsCellEditable(e,t),l=o.useCallback(e=>!!a(e)&&!!e.colDef.editable&&!!e.colDef.renderEditCell&&(!i||i(e)),[i,a]);o.useEffect(()=>{const e=r.current;return()=>{Object.entries(e).forEach(([t,n])=>{Object.keys(n).forEach(n=>{const[r]=e[t][n];clearTimeout(r),delete e[t][n]})})}},[]);const s=o.useCallback((e,t)=>{if(r.current[e])if(t){if(r.current[e][t]){const[,n]=r.current[e][t];n()}}else Object.keys(r.current[e]).forEach(t=>{const[,n]=r.current[e][t];n()})},[]),c=o.useCallback(n=>{const{id:o,field:i,debounceMs:a}=n;return new Promise(l=>{((e,t,n,o)=>{if(!n)return void o();if(r.current[e]||(r.current[e]={}),r.current[e][t]){const[n]=r.current[e][t];clearTimeout(n)}const i=setTimeout(()=>{o(),delete r.current[e][t]},n);r.current[e][t]=[i,()=>{const[n]=r.current[e][t];clearTimeout(n),o(),delete r.current[e][t]}]})(o,i,a,async()=>{const r=t.editMode===Mr.Row?e.current.setRowEditingEditCellValue:e.current.setCellEditingEditCellValue;if(e.current.getCellMode(o,i)===Pr.Edit){const e=await r(n);l(e)}})})},[e,t.editMode]),u=o.useCallback((n,r)=>t.editMode===Mr.Cell?e.current.getRowWithUpdatedValuesFromCellEditing(n,r):e.current.getRowWithUpdatedValuesFromRowEditing(n),[e,t.editMode]),d=o.useCallback((t,n)=>{const r=rc(e);return r[t]?.[n]??null},[e]),f={runPendingEditCellValueMutation:s};Bl(e,{isCellEditable:l,setEditCellValue:c,getRowWithUpdatedValues:u,unstable_getEditCellMeta:d},"public"),Bl(e,f,"private")})(e,t,n),((e,t)=>{const n=ls(e,"useGridFocus"),r=o.useRef(null),i=null!==e.current.rootElementRef.current,a=o.useCallback((t,n)=>{t&&e.current.getRow(t.id)&&e.current.publishEvent("cellFocusOut",e.current.getCellParams(t.id,t.field),n)},[e]),l=o.useCallback((t,r)=>{const o=Ai(e);if(o?.id===t&&o?.field===r){if("view"!==e.current.getCellMode(t,r))return;const n=e.current.getCellElement(t,r);if(!n)return;const o=e.current.rootElementRef.current,i=(0,aa.A)(o),a=i.activeElement;if(a&&a!==i.body&&a!==i.documentElement&&!o?.contains(a))return;if(n.contains(i.activeElement))return;if(zs())n.focus({preventScroll:!0});else{const t=e.current.getScrollPosition();n.focus(),e.current.scroll(t)}return}e.current.setState(e=>(n.debug(`Focusing on cell with id=${t} and field=${r}`),(0,y.A)({},e,{tabIndex:{cell:{id:t,field:r},columnHeader:null,columnHeaderFilter:null,columnGroupHeader:null},focus:{cell:{id:t,field:r},columnHeader:null,columnHeaderFilter:null,columnGroupHeader:null}}))),e.current.getRow(t)&&(o&&a(o,{}),e.current.publishEvent("cellFocusIn",e.current.getCellParams(t,r)))},[e,n,a]),s=o.useCallback((t,r={})=>{const o=Ai(e);a(o,r),e.current.setState(e=>(n.debug(`Focusing on column header with colIndex=${t}`),(0,y.A)({},e,{tabIndex:{columnHeader:{field:t},columnHeaderFilter:null,cell:null,columnGroupHeader:null},focus:{columnHeader:{field:t},columnHeaderFilter:null,cell:null,columnGroupHeader:null}})))},[e,n,a]),c=o.useCallback((t,r={})=>{const o=Ai(e);a(o,r),e.current.setState(e=>(n.debug(`Focusing on column header filter with colIndex=${t}`),(0,y.A)({},e,{tabIndex:{columnHeader:null,columnHeaderFilter:{field:t},cell:null,columnGroupHeader:null},focus:{columnHeader:null,columnHeaderFilter:{field:t},cell:null,columnGroupHeader:null}})))},[e,n,a]),u=o.useCallback((t,n,r={})=>{const o=Ai(e);o&&e.current.publishEvent("cellFocusOut",e.current.getCellParams(o.id,o.field),r),e.current.setState(e=>(0,y.A)({},e,{tabIndex:{columnGroupHeader:{field:t,depth:n},columnHeader:null,columnHeaderFilter:null,cell:null},focus:{columnGroupHeader:{field:t,depth:n},columnHeader:null,columnHeaderFilter:null,cell:null}}))},[e]),d=o.useCallback(()=>vi(e),[e]),f=o.useCallback((n,r,o)=>{let i=e.current.getColumnIndex(r);const a=Ve(e),l=ml(e,(t.pagination,t.paginationMode)),s=Ot(e),c=[].concat(s.top||[],l.rows,s.bottom||[]);let u=c.findIndex(e=>e.id===n);"right"===o?i+=1:"left"===o?i-=1:u+=1,i>=a.length?(u+=1,u<c.length&&(i=0)):i<0&&(u-=1,u>=0&&(i=a.length-1)),u=fn(u,0,c.length-1);const d=c[u];if(!d)return;const f=e.current.unstable_getCellColSpanInfo(d.id,i);f&&f.spannedByColSpan&&("left"===o||"below"===o?i=f.leftVisibleCellIndex:"right"===o&&(i=f.rightVisibleCellIndex)),i=fn(i,0,a.length-1);const p=a[i];e.current.setCellFocus(d.id,p.field)},[e,t.pagination,t.paginationMode]),p=o.useCallback(({id:t,field:n})=>{e.current.setCellFocus(t,n)},[e]),h=o.useCallback((t,n)=>{Ur(n)||"Enter"===n.key||"Tab"===n.key||"Shift"===n.key||Vr(n.key)||e.current.setCellFocus(t.id,t.field)},[e]),g=o.useCallback(({field:t},n)=>{n.target===n.currentTarget&&e.current.setColumnHeaderFocus(t,n)},[e]),m=o.useCallback(({fields:t,depth:n},r)=>{if(r.target!==r.currentTarget)return;const o=vi(e);null!==o&&o.depth===n&&t.includes(o.field)||e.current.setColumnGroupHeaderFocus(t[0],n,r)},[e]),A=o.useCallback((t,r)=>{r.relatedTarget?.getAttribute("class")?.includes(L.columnHeader)||(n.debug("Clearing focus"),e.current.setState(e=>(0,y.A)({},e,{focus:{cell:null,columnHeader:null,columnHeaderFilter:null,columnGroupHeader:null}})))},[n,e]),b=o.useCallback(e=>{r.current=e},[]),v=o.useCallback(t=>{const n=r.current;r.current=null;const o=Ai(e);if(!e.current.unstable_applyPipeProcessors("canUpdateFocus",!0,{event:t,cell:n}))return;if(!o)return void(n&&e.current.setCellFocus(n.id,n.field));if(n?.id===o.id&&n?.field===o.field)return;const i=e.current.getCellElement(o.id,o.field);i?.contains(t.target)||(n?e.current.setCellFocus(n.id,n.field):(e.current.setState(e=>(0,y.A)({},e,{focus:{cell:null,columnHeader:null,columnHeaderFilter:null,columnGroupHeader:null}})),a(o,t)))},[e,a]),w=o.useCallback(t=>{if("view"===t.cellMode)return;const n=Ai(e);n?.id===t.id&&n?.field===t.field||e.current.setCellFocus(t.id,t.field)},[e]),C=o.useCallback(()=>{const n=Ai(e);if(n&&!e.current.getRow(n.id)){const r=n.id;let o=null;if(void 0!==r){const n=e.current.getRowElement(r),i=n?.dataset.rowindex?Number(n?.dataset.rowindex):0,a=ml(e,(t.pagination,t.paginationMode)),l=a.rows[fn(i,0,a.rows.length-1)];o=l?.id??null}e.current.setState(e=>(0,y.A)({},e,{focus:{cell:null===o?null:{id:o,field:n.field},columnHeader:null,columnHeaderFilter:null,columnGroupHeader:null}}))}},[e,t.pagination,t.paginationMode]),S=o.useMemo(()=>(0,Ts.A)(C,0),[C]),x=(0,Nt.A)(()=>{const n=Ai(e);if(!n)return;const r=ml(e,(t.pagination,t.paginationMode));if(r.rows.find(e=>e.id===n.id)||0===r.rows.length)return;const o=Ve(e);e.current.setState(e=>(0,y.A)({},e,{tabIndex:{cell:{id:r.rows[0].id,field:o[0].field},columnGroupHeader:null,columnHeader:null,columnHeaderFilter:null}}))}),E={moveFocusToRelativeCell:f,setColumnGroupHeaderFocus:u,getColumnGroupHeaderFocus:d};Bl(e,{setCellFocus:l,setColumnHeaderFocus:s,setColumnHeaderFilterFocus:c},"public"),Bl(e,E,"private"),o.useEffect(()=>{const t=(0,aa.A)(e.current.rootElementRef.current);return t.addEventListener("mouseup",v),()=>{t.removeEventListener("mouseup",v)}},[e,i,v]),$t(e,"columnHeaderBlur",A),$t(e,"cellDoubleClick",p),$t(e,"cellMouseDown",b),$t(e,"cellKeyDown",h),$t(e,"cellModeChange",w),$t(e,"columnHeaderFocus",g),$t(e,"columnGroupHeaderFocus",m),$t(e,"rowsSet",S),$t(e,"paginationModelChange",x)})(e,t),((e,t)=>{const n=ls(e,"useGridPreferencesPanel"),r=o.useCallback(()=>{e.current.setState(t=>{if(!t.preferencePanel.open)return t;n.debug("Hiding Preferences Panel");const r=et(e);return e.current.publishEvent("preferencePanelClose",{openedPanelValue:r.openedPanelValue}),(0,y.A)({},t,{preferencePanel:{open:!1}})})},[e,n]),i=o.useCallback((t,r,o)=>{n.debug("Opening Preferences Panel"),e.current.setState(e=>(0,y.A)({},e,{preferencePanel:(0,y.A)({},e.preferencePanel,{open:!0,openedPanelValue:t,panelId:r,labelId:o})})),e.current.publishEvent("preferencePanelOpen",{openedPanelValue:t})},[n,e]);Bl(e,{showPreferences:i,hidePreferences:r},"public");const a=o.useCallback((n,r)=>{const o=et(e);return!r.exportOnlyDirtyModels||null!=t.initialState?.preferencePanel||o.open?(0,y.A)({},n,{preferencePanel:o}):n},[e,t.initialState?.preferencePanel]),l=o.useCallback((t,n)=>{const r=n.stateToRestore.preferencePanel;return null!=r&&e.current.setState(e=>(0,y.A)({},e,{preferencePanel:r})),t},[e]);ws(e,"exportState",a),ws(e,"restoreState",l)})(e,t),((e,t,n)=>{const i=ls(e,"useGridFilter");e.current.registerControlState({stateId:"filter",propModel:t.filterModel,propOnChange:t.onFilterModelChange,stateSelector:Ko,changeEvent:"filterModelChange"});const a=o.useCallback(()=>{e.current.setState(t=>{const n=Ko(e),r=e.current.getFilterState(n),o=(0,y.A)({},t,{filter:(0,y.A)({},t.filter,r)}),i=Fs(e,o);return(0,y.A)({},o,{visibleRowsLookup:i})}),e.current.publishEvent("filteredRowsSet")},[e]),l=o.useCallback((e,n)=>null==n||!1===n.filterable||t.disableColumnFilter?e:[...e,"columnMenuFilterItem"],[t.disableColumnFilter]),s=o.useCallback(t=>{const n=Ko(e),r=[...n.items],o=r.findIndex(e=>e.id===t.id);-1===o?r.push(t):r[o]=t,e.current.setFilterModel((0,y.A)({},n,{items:r}),"upsertFilterItem")},[e]),c=o.useCallback(t=>{const n=Ko(e),r=[...n.items];t.forEach(e=>{const t=r.findIndex(t=>t.id===e.id);-1===t?r.push(e):r[t]=e}),e.current.setFilterModel((0,y.A)({},n,{items:r}),"upsertFilterItems")},[e]),u=o.useCallback(t=>{const n=Ko(e),r=n.items.filter(e=>e.id!==t.id);r.length!==n.items.length&&e.current.setFilterModel((0,y.A)({},n,{items:r}),"deleteFilterItem")},[e]),d=o.useCallback((n,r,o)=>{if(i.debug("Displaying filter panel"),n){const r=Ko(e),o=r.items.filter(t=>{if(void 0!==t.value)return!Array.isArray(t.value)||0!==t.value.length;const n=e.current.getColumn(t.field),r=n.filterOperators?.find(e=>e.value===t.operator);return!(void 0===r?.requiresFilterValue||r?.requiresFilterValue)});let i;const a=o.find(e=>e.field===n),l=e.current.getColumn(n);i=a?o:t.disableMultipleColumnsFiltering?[Cn({field:n,operator:l.filterOperators[0].value},e)]:[...o,Cn({field:n,operator:l.filterOperators[0].value},e)],e.current.setFilterModel((0,y.A)({},r,{items:i}))}e.current.showPreferences(nt.filters,r,o)},[e,i,t.disableMultipleColumnsFiltering]),f=o.useCallback(()=>{i.debug("Hiding filter panel"),e.current.hidePreferences()},[e,i]),p=o.useCallback(t=>{const n=Ko(e);n.logicOperator!==t&&e.current.setFilterModel((0,y.A)({},n,{logicOperator:t}),"changeLogicOperator")},[e]),h=o.useCallback(t=>{const n=Ko(e);la(n.quickFilterValues,t)||e.current.setFilterModel((0,y.A)({},n,{quickFilterValues:[...t]}))},[e]),g=o.useCallback((n,r)=>{Ko(e)!==n&&(i.debug("Setting filter model"),e.current.updateControlState("filter",xn(n,t.disableMultipleColumnsFiltering,e),r),e.current.unstable_applyFilters())},[e,i,t.disableMultipleColumnsFiltering]),m=o.useCallback(r=>{const o=Sn(r,t.disableMultipleColumnsFiltering,e),i=n.hooks.useFilterValueGetter(e,t),a="client"===t.filterMode?Mn(o,i,e,t.disableEval):null,l=e.current.applyStrategyProcessor("filtering",{isRowMatchingFilters:a,filterModel:o??vn(),filterValueGetter:i});return(0,y.A)({},l,{filterModel:o})},[e,n.hooks,t]),A={setFilterLogicOperator:p,unstable_applyFilters:a,deleteFilterItem:u,upsertFilterItem:s,upsertFilterItems:c,setFilterModel:g,showFilterPanel:d,hideFilterPanel:f,setQuickFilterValues:h,ignoreDiacritics:t.ignoreDiacritics,getFilterState:m};Bl(e,A,"public");const b=o.useCallback((n,r)=>{const o=Ko(e);return o.items.forEach(e=>{delete e.fromInput}),r.exportOnlyDirtyModels&&null==t.filterModel&&null==t.initialState?.filter?.filterModel&&la(o,vn())?n:(0,y.A)({},n,{filter:{filterModel:o}})},[e,t.filterModel,t.initialState?.filter?.filterModel]),v=o.useCallback((n,r)=>{const o=r.stateToRestore.filter?.filterModel;return null==o?n:(e.current.updateControlState("filter",xn(o,t.disableMultipleColumnsFiltering,e),"restoreState"),(0,y.A)({},n,{callbacks:[...n.callbacks,e.current.unstable_applyFilters]}))},[e,t.disableMultipleColumnsFiltering]),w=o.useCallback((e,n)=>{if(n===nt.filters){const e=t.slots.filterPanel;return(0,r.jsx)(e,(0,y.A)({},t.slotProps?.filterPanel))}return e},[t.slots.filterPanel,t.slotProps?.filterPanel]),{getRowId:C}=t,S=(0,G.A)(Qs),x=o.useCallback(n=>{if("client"!==t.filterMode||!n.isRowMatchingFilters||!n.filterModel.items.length&&!n.filterModel.quickFilterValues?.length)return bn;const r=Et(e),o={},{isRowMatchingFilters:i}=n,a={},l={passingFilterItems:null,passingQuickFilterValues:null},s=S.current(e.current.state.rows.dataRowIdToModelLookup);for(let t=0;t<s.length;t+=1){const r=s[t],c=C?C(r):r.id;i(r,void 0,l);const u=Bn([l.passingFilterItems],[l.passingQuickFilterValues],n.filterModel,n.filterValueGetter,e,a);u||(o[c]=u)}const c="auto-generated-group-footer-root";return r[c]&&(o[c]=!0),{filteredRowsLookup:o,filteredChildrenCountLookup:{},filteredDescendantCountLookup:{}}},[e,t.filterMode,C,S]);ws(e,"columnMenu",l),ws(e,"exportState",b),ws(e,"restoreState",v),ws(e,"preferencePanel",w),Ds(e,rs,"filtering",x),Ds(e,rs,"visibleRowsLookupCreation",Ls);const E=o.useCallback(()=>{i.debug("onColUpdated - GridColumns changed, applying filters");const t=Ko(e),n=ze(e),r=t.items.filter(e=>e.field&&n[e.field]);r.length<t.items.length&&e.current.setFilterModel((0,y.A)({},t,{items:r}))},[e,i]),I=o.useCallback(t=>{"filtering"===t&&e.current.unstable_applyFilters()},[e]),k=o.useCallback(()=>{e.current.setState(t=>(0,y.A)({},t,{visibleRowsLookup:Fs(e,t)}))},[e]);$t(e,"rowsSet",a),$t(e,"columnsChange",E),$t(e,"activeStrategyProcessorChange",I),$t(e,"rowExpansionChange",k),$t(e,"columnVisibilityModelChange",()=>{const t=Ko(e);t.quickFilterValues?.length&&Rn(t)&&a()}),Za(()=>{"DataGrid"===t.signature&&a()}),(0,Ut.A)(()=>{void 0!==t.filterModel&&e.current.setFilterModel(t.filterModel)},[e,i,t.filterModel])})(e,t,n),((e,t)=>{const n=ls(e,"useGridSorting");e.current.registerControlState({stateId:"sortModel",propModel:t.sortModel,propOnChange:t.onSortModelChange,stateSelector:Uo,changeEvent:"sortModelChange"});const r=o.useCallback((t,n)=>{const r=Uo(e),o=r.findIndex(e=>e.field===t);let i=[...r];return o>-1?null==n?.sort?i.splice(o,1):i.splice(o,1,n):i=[...r,n],i},[e]),i=o.useCallback((n,r)=>{const o=Uo(e).find(e=>e.field===n.field);if(o){const e=void 0===r?en(n.sortingOrder??t.sortingOrder,o.sort):r;return void 0===e?void 0:(0,y.A)({},o,{sort:e})}return{field:n.field,sort:void 0===r?en(n.sortingOrder??t.sortingOrder):r}},[e,t.sortingOrder]),a=o.useCallback((e,n)=>null==n||!1===n.sortable||t.disableColumnSorting?e:(n.sortingOrder||t.sortingOrder).some(e=>!!e)?[...e,"columnMenuSortItem"]:e,[t.sortingOrder,t.disableColumnSorting]),l=o.useCallback(()=>{e.current.setState(r=>{if("server"===t.sortingMode)return n.debug("Skipping sorting rows as sortingMode = server"),(0,y.A)({},r,{sorting:(0,y.A)({},r.sorting,{sortedRows:nr(It(e),Un,!1)})});const o=((e,t)=>{const n=e.map(e=>((e,t)=>{const n=t.current.getColumn(e.field);if(!n||null===e.sort)return null;let r;return r=n.getSortComparator?n.getSortComparator(e.sort):"desc"===e.sort?(...e)=>-1*n.sortComparator(...e):n.sortComparator,r?{getSortCellParams:e=>({id:e,field:n.field,rowNode:kt(t,e),value:t.current.getCellValue(e,n.field),api:t.current}),comparator:r}:null})(e,t)).filter(e=>!!e);return 0===n.length?null:e=>e.map(e=>({node:e,params:n.map(t=>t.getSortCellParams(e.id))})).sort((e,t)=>{return r=e,o=t,n.reduce((e,t,n)=>{if(0!==e)return e;const i=r.params[n],a=o.params[n];return t.comparator(i.value,a.value,i,a)},0);var r,o}).map(e=>e.node.id)})(Uo(e),e),i=e.current.applyStrategyProcessor("sorting",{sortRowList:o});return(0,y.A)({},r,{sorting:(0,y.A)({},r.sorting,{sortedRows:i})})}),e.current.publishEvent("sortedRowsSet")},[e,n,t.sortingMode]),s=o.useCallback(r=>{Uo(e)!==r&&(n.debug("Setting sort model"),e.current.setState(Zt(r,t.disableMultipleColumnsSorting)),e.current.applySorting())},[e,n,t.disableMultipleColumnsSorting]),c=o.useCallback((n,o,a)=>{const l=e.current.getColumn(n),s=i(l,o);let c;c=!a||t.disableMultipleColumnsSorting?null==s?.sort?[]:[s]:r(l.field,s),e.current.setSortModel(c)},[e,r,i,t.disableMultipleColumnsSorting]),u=o.useCallback(()=>Uo(e),[e]),d=o.useCallback(()=>Wo(e).map(e=>e.model),[e]),f=o.useCallback(()=>Vo(e),[e]),p=o.useCallback(t=>e.current.getSortedRowIds()[t],[e]);Bl(e,{getSortModel:u,getSortedRows:d,getSortedRowIds:f,getRowIdFromRowIndex:p,setSortModel:s,sortColumn:c,applySorting:l},"public");const h=o.useCallback((n,r)=>{const o=Uo(e);return!r.exportOnlyDirtyModels||null!=t.sortModel||null!=t.initialState?.sorting?.sortModel||o.length>0?(0,y.A)({},n,{sorting:{sortModel:o}}):n},[e,t.sortModel,t.initialState?.sorting?.sortModel]),g=o.useCallback((n,r)=>{const o=r.stateToRestore.sorting?.sortModel;return null==o?n:(e.current.setState(Zt(o,t.disableMultipleColumnsSorting)),(0,y.A)({},n,{callbacks:[...n.callbacks,e.current.applySorting]}))},[e,t.disableMultipleColumnsSorting]),m=o.useCallback(t=>{const n=It(e),r=n[Un],o=t.sortRowList?t.sortRowList(r.children.map(e=>n[e])):[...r.children];return null!=r.footerId&&o.push(r.footerId),o},[e]);ws(e,"exportState",h),ws(e,"restoreState",g),Ds(e,rs,"sorting",m);const A=o.useCallback(({field:e,colDef:n},r)=>{if(!n.sortable||t.disableColumnSorting)return;const o="always"===t.multipleColumnsSortingMode||r.shiftKey||r.metaKey||r.ctrlKey;c(e,void 0,o)},[c,t.disableColumnSorting,t.multipleColumnsSortingMode]),b=o.useCallback(({field:e,colDef:n},r)=>{n.sortable&&!t.disableColumnSorting&&("Enter"!==r.key||r.ctrlKey||r.metaKey||c(e,void 0,"always"===t.multipleColumnsSortingMode||r.shiftKey))},[c,t.disableColumnSorting,t.multipleColumnsSortingMode]),v=o.useCallback(()=>{const t=Uo(e),n=ze(e);if(t.length>0){const r=t.filter(e=>n[e.field]);r.length<t.length&&e.current.setSortModel(r)}},[e]),w=o.useCallback(t=>{"sorting"===t&&e.current.applySorting()},[e]);ws(e,"columnMenu",a),$t(e,"columnHeaderClick",A),$t(e,"columnHeaderKeyDown",b),$t(e,"rowsSet",e.current.applySorting),$t(e,"columnsChange",v),$t(e,"activeStrategyProcessorChange",w),Za(()=>{"DataGrid"===t.signature&&e.current.applySorting()}),(0,Ut.A)(()=>{void 0!==t.sortModel&&e.current.setSortModel(t.sortModel)},[e,t.sortModel])})(e,t),((e,t)=>{const n=ls(e,"useDensity");e.current.registerControlState({stateId:"density",propModel:t.density,propOnChange:t.onDensityChange,stateSelector:Pe,changeEvent:"densityChange"});const r=(0,Nt.A)(t=>{Pe(e)!==t&&(n.debug(`Set grid density to ${t}`),e.current.setState(e=>(0,y.A)({},e,{density:t})))});Bl(e,{setDensity:r},"public");const i=o.useCallback((n,r)=>{const o=Pe(e);return r.exportOnlyDirtyModels&&null==t.density&&null==t.initialState?.density?n:(0,y.A)({},n,{density:o})},[e,t.density,t.initialState?.density]),a=o.useCallback((t,n)=>{const r=n.stateToRestore?.density?n.stateToRestore.density:Pe(e);return e.current.setState(e=>(0,y.A)({},e,{density:r})),t},[e]);ws(e,"exportState",i),ws(e,"restoreState",a),o.useEffect(()=>{t.density&&e.current.setDensity(t.density)},[e,t.density])})(e,t),Gc(e,t),((e,t)=>{((e,t)=>{const n=ls(e,"useGridPaginationMeta");e.current.registerControlState({stateId:"paginationMeta",propModel:t.paginationMeta,propOnChange:t.onPaginationMetaChange,stateSelector:sl,changeEvent:"paginationMetaChange"});const r=o.useCallback(t=>{sl(e)!==t&&(n.debug("Setting 'paginationMeta' to",t),e.current.setState(e=>(0,y.A)({},e,{pagination:(0,y.A)({},e.pagination,{meta:t})})))},[e,n]);Bl(e,{setPaginationMeta:r},"public");const i=o.useCallback((n,r)=>{const o=sl(e);return r.exportOnlyDirtyModels&&null==t.paginationMeta&&null==t.initialState?.pagination?.meta?n:(0,y.A)({},n,{pagination:(0,y.A)({},n.pagination,{meta:o})})},[e,t.paginationMeta,t.initialState?.pagination?.meta]),a=o.useCallback((t,n)=>{const r=n.stateToRestore.pagination?.meta?n.stateToRestore.pagination.meta:sl(e);return e.current.setState(e=>(0,y.A)({},e,{pagination:(0,y.A)({},e.pagination,{meta:r})})),t},[e]);ws(e,"exportState",i),ws(e,"restoreState",a),o.useEffect(()=>{t.paginationMeta&&e.current.setPaginationMeta(t.paginationMeta)},[e,t.paginationMeta])})(e,t),((e,t)=>{const n=ls(e,"useGridPaginationModel"),r=J(e,Be),i=o.useRef(Ko(e)),a=Math.floor(t.rowHeight*r);e.current.registerControlState({stateId:"paginationModel",propModel:t.paginationModel,propOnChange:t.onPaginationModelChange,stateSelector:al,changeEvent:"paginationModelChange"});const l=o.useCallback(t=>{const r=al(e);t!==r.page&&(n.debug(`Setting page to ${t}`),e.current.setPaginationModel({page:t,pageSize:r.pageSize}))},[e,n]),s=o.useMemo(()=>(0,Ts.A)(l,0),[l]),c=o.useCallback(t=>{const r=al(e);t!==r.pageSize&&(n.debug(`Setting page size to ${t}`),e.current.setPaginationModel({pageSize:t,page:r.page}))},[e,n]),u=o.useCallback(r=>{const o=al(e);r!==o&&(n.debug("Setting 'paginationModel' to",r),e.current.setState(e=>(0,y.A)({},e,{pagination:(0,y.A)({},e.pagination,{paginationModel:Os(e.pagination,t.signature,r)})}),"setPaginationModel"))},[e,n,t.signature]);Bl(e,{setPage:l,setPageSize:c,setPaginationModel:u},"public");const d=o.useCallback((n,r)=>{const o=al(e);return!r.exportOnlyDirtyModels||null!=t.paginationModel||null!=t.initialState?.pagination?.paginationModel||0!==o.page&&o.pageSize!==(t.autoPageSize?0:100)?(0,y.A)({},n,{pagination:(0,y.A)({},n.pagination,{paginationModel:o})}):n},[e,t.paginationModel,t.initialState?.pagination?.paginationModel,t.autoPageSize]),f=o.useCallback((n,r)=>{const o=r.stateToRestore.pagination?.paginationModel?(0,y.A)({},nl(t.autoPageSize),r.stateToRestore.pagination?.paginationModel):al(e);return e.current.setState(e=>(0,y.A)({},e,{pagination:(0,y.A)({},e.pagination,{paginationModel:Os(e.pagination,t.signature,o)})}),"stateRestorePreProcessing"),n},[e,t.autoPageSize,t.signature]);ws(e,"exportState",d),ws(e,"restoreState",f);const p=o.useCallback(()=>{if(!t.autoPageSize)return;const n=e.current.getRootDimensions(),r=Math.max(1,Math.floor(n.viewportInnerSize.height/a));e.current.setPageSize(r)},[e,t.autoPageSize,a]),h=o.useCallback(t=>{if(null==t)return;const n=al(e);if(0===n.page)return;const r=dl(e);n.page>r-1&&queueMicrotask(()=>{s(Math.max(0,r-1))})},[e,s]),g=o.useCallback(()=>{0!==al(e).page&&s(0),0!==e.current.getScrollPosition().top&&e.current.scroll({top:0})},[e,s]),m=o.useMemo(()=>(0,Ts.A)(g,0),[g]),A=o.useCallback(t=>{const n=(0,y.A)({},t,{items:si(e)});la(n,i.current)||(i.current=n,m())},[e,m]);$t(e,"viewportInnerSizeChange",p),$t(e,"paginationModelChange",()=>{const t=al(e);e.current.virtualScrollerRef?.current&&e.current.scrollToIndexes({rowIndex:t.page*t.pageSize})}),$t(e,"rowCountChange",h),$t(e,"sortModelChange",m),$t(e,"filterModelChange",A);const b=o.useRef(!0);o.useEffect(()=>{b.current?b.current=!1:t.pagination&&e.current.setState(e=>(0,y.A)({},e,{pagination:(0,y.A)({},e.pagination,{paginationModel:Os(e.pagination,t.signature,t.paginationModel)})}))},[e,t.paginationModel,t.signature,t.pagination]),o.useEffect(()=>{e.current.setState(e=>{const n=!0===t.pagination;return e.pagination.paginationMode===t.paginationMode&&e.pagination.enabled===n?e:(0,y.A)({},e,{pagination:(0,y.A)({},e.pagination,{paginationMode:t.paginationMode,enabled:n})})})},[e,t.paginationMode,t.pagination]),o.useEffect(p,[p])})(e,t),((e,t)=>{const n=ls(e,"useGridRowCount"),r=(0,G.A)(()=>al(e).pageSize);e.current.registerControlState({stateId:"paginationRowCount",propModel:t.rowCount,propOnChange:t.onRowCountChange,stateSelector:ll,changeEvent:"rowCountChange"});const i=o.useCallback(t=>{ll(e)!==t&&(n.debug("Setting 'rowCount' to",t),e.current.setState(e=>(0,y.A)({},e,{pagination:(0,y.A)({},e.pagination,{rowCount:t})})))},[e,n]);Bl(e,{setRowCount:i},"public");const a=o.useCallback((n,r)=>{const o=ll(e);return r.exportOnlyDirtyModels&&null==t.rowCount&&null==t.initialState?.pagination?.rowCount?n:(0,y.A)({},n,{pagination:(0,y.A)({},n.pagination,{rowCount:o})})},[e,t.rowCount,t.initialState?.pagination?.rowCount]),l=o.useCallback((t,n)=>{const r=n.stateToRestore.pagination?.rowCount?n.stateToRestore.pagination.rowCount:ll(e);return e.current.setState(e=>(0,y.A)({},e,{pagination:(0,y.A)({},e.pagination,{rowCount:r})})),t},[e]);ws(e,"exportState",a),ws(e,"restoreState",l);const s=o.useCallback(n=>{"client"!==t.paginationMode&&r.current&&n.pageSize!==r.current&&(r.current=n.pageSize,-1===ll(e)&&e.current.setPage(0))},[t.paginationMode,r,e]);$t(e,"paginationModelChange",s),o.useEffect(()=>{"server"===t.paginationMode&&null!=t.rowCount&&e.current.setRowCount(t.rowCount)},[e,t.paginationMode,t.rowCount]),na(e.current.store,()=>!(!1!==sl(e).hasNextPage)||("client"===t.paginationMode?ai(e):void 0),(t,n)=>{if(!0===n&&-1!==ll(e)){const t=ai(e),n=al(e);e.current.setRowCount(n.pageSize*n.page+t)}else"number"==typeof n&&e.current.setRowCount(n)}),o.useEffect(()=>{"client"===t.paginationMode&&e.current.setRowCount(ai(e))},[e,t.paginationMode])})(e,t)})(e,t),((e,t)=>{const n=(0,Hr.I)(),r=ls(e,"useGridScroll"),i=e.current.columnHeadersContainerRef,a=e.current.virtualScrollerRef,l=o.useCallback(n=>{const o=ut(e),i=Ct(e),l=Ve(e);if(null!=n.rowIndex&&0===i||0===l.length)return!1;r.debug(`Scrolling to cell at row ${n.rowIndex}, col: ${n.colIndex} `);let s={};if(void 0!==n.colIndex&&l[n.colIndex]){const t=Ke(e);let r;if(void 0!==n.rowIndex){const t=ei(e),o=t[n.rowIndex]?.id,i=e.current.unstable_getCellColSpanInfo(o,n.colIndex);i&&!i.spannedByColSpan&&(r=i.cellProps.width)}void 0===r&&(r=l[n.colIndex].computedWidth),s.left=yc({containerSize:o.viewportOuterSize.width,scrollPosition:Math.abs(a.current?.scrollLeft??0),elementSize:r,elementOffset:t[n.colIndex]})}if(void 0!==n.rowIndex){const r=No(e),i=cl(e),l=ul(e),c=t.pagination?n.rowIndex-i*l:n.rowIndex,u=r.positions[c+1]?r.positions[c+1]-r.positions[c]:r.currentPageTotalHeight-r.positions[c];s.top=yc({containerSize:o.viewportInnerSize.height,scrollPosition:a.current?.scrollTop??0,elementSize:u,elementOffset:r.positions[c]})}return s=e.current.unstable_applyPipeProcessors("scrollToIndexes",s,n),(void 0!==s.left||void 0!==s.top)&&(e.current.scroll(s),!0)},[r,e,a,t.pagination]),s=o.useCallback(e=>{if(a.current&&void 0!==e.left&&i.current){const t=n?-1:1;i.current.scrollLeft=e.left,a.current.scrollLeft=t*e.left,r.debug(`Scrolling left: ${e.left}`)}a.current&&void 0!==e.top&&(a.current.scrollTop=e.top,r.debug(`Scrolling top: ${e.top}`)),r.debug("Scrolling, updating container, and viewport")},[a,n,i,r]),c=o.useCallback(()=>a?.current?{top:a.current.scrollTop,left:a.current.scrollLeft}:{top:0,left:0},[a]);Bl(e,{scroll:s,scrollToIndexes:l,getScrollPosition:c},"public")})(e,t),(e=>{const t=ls(e,"useGridColumnMenu"),n=o.useRef({}),r=o.useCallback(()=>{n.current.wheel?.(),n.current.touchMove?.()},[]),i=o.useCallback(()=>{r(),n.current.wheel=e.current.subscribeEvent("virtualScrollerWheel",e.current.hideColumnMenu),n.current.touchMove=e.current.subscribeEvent("virtualScrollerTouchMove",e.current.hideColumnMenu)},[e,r]),a=o.useCallback(n=>{const r=xi(e),o=n;(!0!==r.open||o!==r.field)&&(e.current.setState(e=>e.columnMenu.open&&e.columnMenu.field===n?e:(t.debug("Opening Column Menu"),i(),(0,y.A)({},e,{columnMenu:{open:!0,field:n}}))),e.current.hidePreferences())},[e,t,i]),l=o.useCallback(()=>{const n=xi(e);if(n.field){const t=ze(e),r=He(e),o=je(e);let i=n.field;if(t[i]||(i=o[0]),!1===r[i]){const e=o.filter(e=>e===i||!1!==r[e]),t=e.indexOf(i);i=e[t+1]||e[t-1]}e.current.setColumnHeaderFocus(i)}const o={open:!1,field:void 0};(o.open!==n.open||o.field!==n.field)&&e.current.setState(e=>(t.debug("Hiding Column Menu"),r(),(0,y.A)({},e,{columnMenu:o})))},[e,t,r]),s=o.useCallback(n=>{t.debug("Toggle Column Menu");const r=xi(e);r.open&&r.field===n?l():a(n)},[e,t,a,l]);Bl(e,{showColumnMenu:a,hideColumnMenu:l,toggleColumnMenu:s},"public"),$t(e,"columnResizeStart",l)})(e),_s(e,t),((e,t)=>{const n=null!==e.current.rootElementRef.current,i=ls(e,"useGridPrintExport"),a=o.useRef(null),l=o.useRef(null),s=o.useRef({}),c=o.useRef([]),u=o.useRef(null);o.useEffect(()=>{a.current=(0,aa.A)(e.current.rootElementRef.current)},[e,n]);const d=o.useCallback((t,n,r)=>new Promise(o=>{const i=xs({apiRef:e,options:{fields:t,allColumns:n}}).map(e=>e.field),a=$e(e),l={};a.forEach(e=>{l[e.field]=i.includes(e.field)}),r&&(l[gs.field]=!0),e.current.setColumnVisibilityModel(l),o()}),[e]),f=o.useCallback(t=>{const n=t({apiRef:e}).reduce((t,n)=>{const r=e.current.getRow(n);return r[qn]||t.push(r),t},[]);e.current.setRows(n)},[e]),p=o.useCallback((t,n)=>{const r=(0,y.A)({copyStyles:!0,hideToolbar:!1,hideFooter:!1,includeCheckboxes:!1},n),o=t.contentDocument;if(!o)return;const i=e.current.rootElementRef.current,l=i.cloneNode(!0),s=l.querySelector(`.${L.virtualScrollerContent}`);if(l.querySelector(`.${L.main}`).style.overflow="visible",l.querySelector(`.${L.virtualScrollerRenderZone}`).style.position="static",s.style.flexBasis="auto",l.querySelector(`.${L["scrollbar--vertical"]}`)?.remove(),!(s.nextSibling instanceof HTMLElement&&s.nextSibling.classList.contains(L.filler))){const e=document.createElement("div");e.style.height=Hi,s.insertAdjacentElement("afterend",e)}const c=l.querySelector(`.${L.footerContainer}`);r.hideToolbar&&l.querySelector(`.${L.toolbar}`)?.remove(),r.hideFooter&&c&&c.remove(),l.style.height="auto",l.style.boxSizing="content-box",!r.hideFooter&&c&&(c.style.width="100%");const u=document.createElement("div");u.appendChild(l),o.body.style.marginTop="0px",o.body.innerHTML=u.innerHTML;const d="function"==typeof r.pageStyle?r.pageStyle():r.pageStyle;if("string"==typeof d){const e=o.createElement("style");e.appendChild(o.createTextNode(d)),o.head.appendChild(e)}r.bodyClassName&&o.body.classList.add(...r.bodyClassName.split(" "));let f=[];if(r.copyStyles){const e=i.getRootNode();f=function(e,t){const n=[],r=t.querySelectorAll("style, link[rel='stylesheet']");for(let t=0;t<r.length;t+=1){const o=r[t],i=e.createElement(o.tagName);if("STYLE"===o.tagName){const t=o.sheet;if(t){let n="";for(let e=0;e<t.cssRules.length;e+=1)"string"==typeof t.cssRules[e].cssText&&(n+=`${t.cssRules[e].cssText}\r\n`);i.appendChild(e.createTextNode(n))}}else if(o.getAttribute("href")){for(let e=0;e<o.attributes.length;e+=1){const t=o.attributes[e];t&&i.setAttribute(t.nodeName,t.nodeValue||"")}n.push(new Promise(e=>{i.addEventListener("load",()=>e())}))}e.head.appendChild(i)}return n}(o,"ShadowRoot"===e.constructor.name?e:a.current)}Promise.all(f).then(()=>{t.contentWindow.print()})},[e,a]),h=o.useCallback(t=>{a.current.body.removeChild(t),e.current.restoreState(l.current||{}),l.current?.columns?.columnVisibilityModel||e.current.setColumnVisibilityModel(s.current),e.current.setState(e=>(0,y.A)({},e,{virtualization:u.current})),e.current.setRows(c.current),l.current=null,s.current={},c.current=[]},[e]),g=o.useCallback(async n=>{if(i.debug("Export data as Print"),!e.current.rootElementRef.current)throw new Error("MUI X: No grid root element available.");if(l.current=e.current.exportState(),s.current=He(e),c.current=e.current.getSortedRows().filter(e=>!e[qn]),t.pagination){const t={page:0,pageSize:ii(e)};e.current.setState(e=>(0,y.A)({},e,{pagination:(0,y.A)({},e.pagination,{paginationModel:Os(e.pagination,"DataGridPro",t)})}))}u.current=e.current.state.virtualization,e.current.unstable_setVirtualization(!1),await d(n?.fields,n?.allColumns,n?.includeCheckboxes),f(n?.getRowsToExport??Es),await new Promise(e=>{requestAnimationFrame(()=>{e()})});const r=function(e){const t=document.createElement("iframe");return t.style.position="absolute",t.style.width="0px",t.style.height="0px",t.title=e||document.title,t}(n?.fileName);r.onload=()=>{p(r,n),r.contentWindow.matchMedia("print").addEventListener("change",e=>{!1===e.matches&&h(r)})},a.current.body.appendChild(r)},[t,i,e,p,h,d,f]);Bl(e,{exportDataAsPrint:g},"public");const m=o.useCallback((e,t)=>t.printOptions?.disableToolbarButton?e:[...e,{component:(0,r.jsx)(Bs,{options:t.printOptions}),componentName:"printExport"}],[]);ws(e,"exportMenu",m)})(e,t),((e,t)=>{const n=t.ignoreValueFormatterDuringExport,r=("object"==typeof n?n?.clipboardExport:n)||!1,i=t.clipboardCopyCellDelimiter,a=o.useCallback(t=>{if(!function(e){return(e.ctrlKey||e.metaKey)&&"C"===String.fromCharCode(e.keyCode)&&!e.shiftKey&&!e.altKey}(t))return;if(n=t.target,window.getSelection()?.toString()||n&&(n.selectionEnd||0)-(n.selectionStart||0)>0)return;var n;let o="";if(Rl(e)>0)o=e.current.getDataAsCsv({includeHeaders:!1,delimiter:i,shouldAppendQuotes:!1,escapeFormulas:!1});else{const t=Ai(e);if(t){const n=e.current.getCellParams(t.id,t.field);o=As(n,{csvOptions:{delimiter:i,shouldAppendQuotes:!1,escapeFormulas:!1},ignoreValueFormatter:r})}}var a;o=e.current.unstable_applyPipeProcessors("clipboardCopy",o),o&&(a=o,navigator.clipboard?navigator.clipboard.writeText(a).catch(()=>{vs(a)}):vs(a),e.current.publishEvent("clipboardCopy",o))},[e,r,i]);ss(e,()=>e.current.rootElementRef.current,"keydown",a),Gt(e,"clipboardCopy",t.onClipboardCopy)})(e,t),function(e,t){const n=o.useCallback(()=>ut(e),[e]),r={updateDimensions:()=>e.current.virtualizer.api.updateDimensions(),getViewportPageSize:()=>e.current.virtualizer.api.getViewportPageSize()};Bl(e,{getRootDimensions:n},"public"),Bl(e,r,"private"),Gt(e,"rootMount",t=>{Ec(t,ut(e))}),Gt(e,"debouncedResize",t.onResize),na(e.current.store,e=>e.dimensions,(t,n)=>{var r,o;n.isReady&&(e.current.rootElementRef.current&&Ec(e.current.rootElementRef.current,n),r=n.viewportInnerSize,o=t.viewportInnerSize,(r.width!==o.width||r.height!==o.height)&&e.current.publishEvent("viewportInnerSizeChange",n.viewportInnerSize),e.current.publishEvent("debouncedResize",n.root))})}(e,t),function(e,t){Gt(e,"columnHeaderClick",t.onColumnHeaderClick),Gt(e,"columnHeaderContextMenu",t.onColumnHeaderContextMenu),Gt(e,"columnHeaderDoubleClick",t.onColumnHeaderDoubleClick),Gt(e,"columnHeaderOver",t.onColumnHeaderOver),Gt(e,"columnHeaderOut",t.onColumnHeaderOut),Gt(e,"columnHeaderEnter",t.onColumnHeaderEnter),Gt(e,"columnHeaderLeave",t.onColumnHeaderLeave),Gt(e,"cellClick",t.onCellClick),Gt(e,"cellDoubleClick",t.onCellDoubleClick),Gt(e,"cellKeyDown",t.onCellKeyDown),Gt(e,"preferencePanelClose",t.onPreferencePanelClose),Gt(e,"preferencePanelOpen",t.onPreferencePanelOpen),Gt(e,"menuOpen",t.onMenuOpen),Gt(e,"menuClose",t.onMenuClose),Gt(e,"rowDoubleClick",t.onRowDoubleClick),Gt(e,"rowClick",t.onRowClick),Gt(e,"stateChange",t.onStateChange)}(e,t),(e=>{const t=o.useCallback((t={})=>e.current.unstable_applyPipeProcessors("exportState",{},t),[e]),n=o.useCallback(t=>{e.current.unstable_applyPipeProcessors("restoreState",{callbacks:[]},{stateToRestore:t}).callbacks.forEach(e=>{e()})},[e]);Bl(e,{exportState:t,restoreState:n},"public")})(e),function(e,t){const{autoHeight:n,disableVirtualization:r}=t,i=t=>{const{virtualizer:r}=e.current;t&&=Tc;const o=r.store.getSnapshot();o.virtualization.enabled===t&&o.virtualization.enabledForRows===t&&o.virtualization.enabledForColumns===t||r.store.set("virtualization",(0,y.A)({},r.store.state.virtualization,{enabled:t,enabledForColumns:t,enabledForRows:t&&!n}))};Bl(e,{unstable_setVirtualization:i,unstable_setColumnVirtualization:t=>{const{virtualizer:n}=e.current;t&&=Tc,n.store.getSnapshot().virtualization.enabledForColumns!==t&&n.store.set("virtualization",(0,y.A)({},n.store.state.virtualization,{enabledForColumns:t}))}},"public");const a=()=>{const{virtualizer:t}=e.current;t?.api.scheduleUpdateRenderContext()};e.current.register("private",{updateRenderContext:a}),Gt(e,"sortedRowsSet",a),Gt(e,"paginationModelChange",a),Gt(e,"columnsChange",a),o.useEffect(()=>{e.current.virtualizer&&i(!t.disableVirtualization)},[e,r,n])}(e,t),function(e,t){const n=()=>{e.current.setState(t=>t.listViewColumn?(0,y.A)({},t,{listViewColumn:(0,y.A)({},t.listViewColumn,{computedWidth:Jc(e)})}):t)},r=o.useRef(null);$t(e,"viewportInnerSizeChange",e=>{r.current!==e.width&&(r.current=e.width,n())}),$t(e,"columnVisibilityModelChange",n),(0,Ut.A)(()=>{const n=t.listViewColumn;n&&e.current.setState(t=>(0,y.A)({},t,{listViewColumn:(0,y.A)({},n,{computedWidth:Jc(e)})}))},[e,t.listViewColumn]),o.useEffect(()=>{t.listView&&t.listViewColumn},[t.listView,t.listViewColumn])}(e,t),((e,t)=>{const{api:n,strategyProcessor:r,events:i,setStrategyAvailability:a}=((e,t,n={})=>{const r=o.useCallback(()=>{e.current.setStrategyAvailability(ns.DataSource,Zc.Default,t.dataSource?()=>!0:()=>!1)},[e,t.dataSource]),[i,a]=o.useState(e.current.getActiveStrategy(ns.DataSource)),l=o.useMemo(()=>i===Zc.Default||i===Zc.GroupedData,[i]),s=J(e,al),c=o.useRef(0),u=o.useRef(null),d=t.onDataSourceError,f=t.dataSourceRevalidateMs,p=(0,G.A)(()=>{if(!t.pagination)return new eu(s.pageSize);const e=t.pageSizeOptions.map(e=>"number"==typeof e?e:e.value).sort((e,t)=>e-t),n=Math.min(s.pageSize,e[0]);return new eu(n)}).current,[h,g]=o.useState(()=>lu(t.dataSourceCache,n.cacheOptions)),m=o.useCallback(async(r,o)=>{const i=t.dataSource?.getRows;if(!i)return;if(r&&r!==Un&&"DataGrid"!==t.signature)return void n.fetchRowChildren?.([r]);n.clearDataSourceState?.();const a=o||{},{skipCache:s,keepChildrenExpanded:u}=a,f=(0,x.A)(a,iu),g=(0,y.A)({},Xc(e),e.current.unstable_applyPipeProcessors("getRowsParams",{}),f),m=p.getCacheKeys(g).map(e=>h.get(e));if(!s&&m.every(e=>void 0!==e))return void e.current.applyStrategyProcessor("dataSourceRowsUpdate",{response:eu.mergeResponses(m),fetchParams:g,options:{skipCache:s,keepChildrenExpanded:u}});(l||0===e.current.getRowsCount())&&e.current.setLoading(!0);const A=c.current+1;c.current=A;try{const t=await i(g);p.splitResponse(g,t).forEach((e,t)=>h.set(t,e)),c.current===A&&e.current.applyStrategyProcessor("dataSourceRowsUpdate",{response:t,fetchParams:g,options:{skipCache:s,keepChildrenExpanded:u}})}catch(t){c.current===A&&(e.current.applyStrategyProcessor("dataSourceRowsUpdate",{error:t,fetchParams:g,options:{skipCache:s,keepChildrenExpanded:u}}),"function"==typeof d&&d(new ru({message:t?.message,params:g,cause:t})))}finally{l&&c.current===A&&e.current.setLoading(!1)}},[p,h,e,l,t.dataSource?.getRows,d,n,t.signature]),A=o.useCallback(()=>{a(e.current.getActiveStrategy(ns.DataSource))},[e]),b=n.fetchRowChildren,v=(0,Nt.A)(async()=>{const n=t.dataSource?.getRows;if(!n||!l)return;const r=()=>{if(i!==Zc.GroupedData||!b)return;const t=It(e),n=gl(e).rows.reduce((e,n)=>{const r=t[n.id];return"group"===r.type&&r.id!==Un&&!0===r.childrenExpanded&&e.push(n.id),e},[]);n.length>0&&b(n,{showChildrenLoading:!1})},o=(0,y.A)({},Xc(e),e.current.unstable_applyPipeProcessors("getRowsParams",{}));if(p.getCacheKeys(o).map(e=>h.get(e)).every(e=>void 0!==e))r();else try{const t=await n(o);if(!la(o,(0,y.A)({},Xc(e),e.current.unstable_applyPipeProcessors("getRowsParams",{}))))return;p.splitResponse(o,t).forEach((e,t)=>h.set(t,e)),e.current.applyStrategyProcessor("dataSourceRowsUpdate",{response:t,fetchParams:o,options:{}}),r()}catch{}}),w=o.useCallback(()=>{null!==u.current&&(clearInterval(u.current),u.current=null)},[]),C=(0,Nt.A)(()=>{w(),f<=0||!l||(u.current=setInterval(v,f))}),S=o.useCallback(t=>{if("error"in t)return void e.current.setRows([]);const{response:n}=t;void 0!==n.rowCount&&e.current.setRowCount(n.rowCount),e.current.setRows(n.rows),e.current.unstable_applyPipeProcessors("processDataSourceRows",{params:t.fetchParams,response:n},!0),C()},[e,C]),E=t.dataSource?.updateRow,I=n.handleEditRow,k=o.useCallback(async t=>{if(E)try{const n=await E(t);return"function"==typeof I?(I(t,n),n):(n&&!la(n,t.previousRow)&&e.current.dataSource.cache.clear(),e.current.updateNestedRows([n],[]),n)}catch(e){throw"function"==typeof d&&d(new ou({message:e?.message,params:t,cause:e})),e}},[e,E,d,I]),R={dataSource:{fetchRows:m,cache:h,editRow:k}},M=o.useMemo(()=>(0,Ts.A)(m,0),[m]),P=o.useCallback(()=>{e.current.setRows([]),w(),M()},[w,M,e]),B=o.useRef(!0);return o.useEffect(()=>{if(B.current)return void(B.current=!1);if(void 0===t.dataSourceCache)return;const e=lu(t.dataSourceCache,n.cacheOptions);g(t=>t!==e?e:t)},[t.dataSourceCache,n.cacheOptions]),o.useEffect(()=>{l||w()},[l,w]),o.useEffect(()=>{f<=0&&w()},[f,w]),o.useEffect(()=>w,[w]),o.useEffect(()=>{if(i===Zc.Default||i===Zc.LazyLoading||i===Zc.GroupedData)return t.dataSource&&(w(),e.current.setRows([]),e.current.dataSource.cache.clear(),e.current.dataSource.fetchRows()),()=>{c.current+=1}},[e,t.dataSource,i,w]),{api:{public:R},debouncedFetchRows:M,strategyProcessor:{strategyName:Zc.Default,group:"dataSourceRowsUpdate",processor:S},setStrategyAvailability:r,startPolling:C,stopPolling:w,cacheChunkManager:p,cache:h,events:{strategyAvailabilityChange:A,sortModelChange:hn(l,P),filterModelChange:hn(l,P),paginationModelChange:hn(l,P)}}})(e,t);Bl(e,n.public,"public"),Ds(e,r.strategyName,r.group,r.processor),Object.entries(i).forEach(([t,n])=>{$t(e,t,n)}),o.useEffect(()=>{a()},[a])})(e,t),Za(()=>{e.current.runAppliersForPendingProcessors()}),o.useEffect(()=>{e.current.runAppliersForPendingProcessors()})};var cu=n(5835),uu=n(6096);const du={noRowsLabel:"No rows",noResultsOverlayLabel:"No results found.",noColumnsOverlayLabel:"No columns",noColumnsOverlayManageColumns:"Manage columns",emptyPivotOverlayLabel:"Add fields to rows, columns, and values to create a pivot table",toolbarDensity:"Density",toolbarDensityLabel:"Density",toolbarDensityCompact:"Compact",toolbarDensityStandard:"Standard",toolbarDensityComfortable:"Comfortable",toolbarUndo:"Undo",toolbarRedo:"Redo",toolbarColumns:"Columns",toolbarColumnsLabel:"Select columns",toolbarFilters:"Filters",toolbarFiltersLabel:"Show filters",toolbarFiltersTooltipHide:"Hide filters",toolbarFiltersTooltipShow:"Show filters",toolbarFiltersTooltipActive:e=>1!==e?`${e} active filters`:`${e} active filter`,toolbarQuickFilterPlaceholder:"Search…",toolbarQuickFilterLabel:"Search",toolbarQuickFilterDeleteIconLabel:"Clear",toolbarExport:"Export",toolbarExportLabel:"Export",toolbarExportCSV:"Download as CSV",toolbarExportPrint:"Print",toolbarExportExcel:"Download as Excel",toolbarPivot:"Pivot",toolbarCharts:"Charts",toolbarAssistant:"AI Assistant",columnsManagementSearchTitle:"Search",columnsManagementNoColumns:"No columns",columnsManagementShowHideAllText:"Show/Hide All",columnsManagementReset:"Reset",columnsManagementDeleteIconLabel:"Clear",filterPanelAddFilter:"Add filter",filterPanelRemoveAll:"Remove all",filterPanelDeleteIconLabel:"Delete",filterPanelLogicOperator:"Logic operator",filterPanelOperator:"Operator",filterPanelOperatorAnd:"And",filterPanelOperatorOr:"Or",filterPanelColumns:"Columns",filterPanelInputLabel:"Value",filterPanelInputPlaceholder:"Filter value",filterOperatorContains:"contains",filterOperatorDoesNotContain:"does not contain",filterOperatorEquals:"equals",filterOperatorDoesNotEqual:"does not equal",filterOperatorStartsWith:"starts with",filterOperatorEndsWith:"ends with",filterOperatorIs:"is",filterOperatorNot:"is not",filterOperatorAfter:"is after",filterOperatorOnOrAfter:"is on or after",filterOperatorBefore:"is before",filterOperatorOnOrBefore:"is on or before",filterOperatorIsEmpty:"is empty",filterOperatorIsNotEmpty:"is not empty",filterOperatorIsAnyOf:"is any of","filterOperator=":"=","filterOperator!=":"!=","filterOperator>":">","filterOperator>=":">=","filterOperator<":"<","filterOperator<=":"<=",headerFilterOperatorContains:"Contains",headerFilterOperatorDoesNotContain:"Does not contain",headerFilterOperatorEquals:"Equals",headerFilterOperatorDoesNotEqual:"Does not equal",headerFilterOperatorStartsWith:"Starts with",headerFilterOperatorEndsWith:"Ends with",headerFilterOperatorIs:"Is",headerFilterOperatorNot:"Is not",headerFilterOperatorAfter:"Is after",headerFilterOperatorOnOrAfter:"Is on or after",headerFilterOperatorBefore:"Is before",headerFilterOperatorOnOrBefore:"Is on or before",headerFilterOperatorIsEmpty:"Is empty",headerFilterOperatorIsNotEmpty:"Is not empty",headerFilterOperatorIsAnyOf:"Is any of","headerFilterOperator=":"Equals","headerFilterOperator!=":"Not equals","headerFilterOperator>":"Greater than","headerFilterOperator>=":"Greater than or equal to","headerFilterOperator<":"Less than","headerFilterOperator<=":"Less than or equal to",headerFilterClear:"Clear filter",filterValueAny:"any",filterValueTrue:"true",filterValueFalse:"false",columnMenuLabel:"Menu",columnMenuAriaLabel:e=>`${e} column menu`,columnMenuShowColumns:"Show columns",columnMenuManageColumns:"Manage columns",columnMenuFilter:"Filter",columnMenuHideColumn:"Hide column",columnMenuUnsort:"Unsort",columnMenuSortAsc:"Sort by ASC",columnMenuSortDesc:"Sort by DESC",columnMenuManagePivot:"Manage pivot",columnMenuManageCharts:"Manage charts",columnHeaderFiltersTooltipActive:e=>1!==e?`${e} active filters`:`${e} active filter`,columnHeaderFiltersLabel:"Show filters",columnHeaderSortIconLabel:"Sort",footerRowSelected:e=>1!==e?`${e.toLocaleString()} rows selected`:`${e.toLocaleString()} row selected`,footerTotalRows:"Total Rows:",footerTotalVisibleRows:(e,t)=>`${e.toLocaleString()} of ${t.toLocaleString()}`,checkboxSelectionHeaderName:"Checkbox selection",checkboxSelectionSelectAllRows:"Select all rows",checkboxSelectionUnselectAllRows:"Unselect all rows",checkboxSelectionSelectRow:"Select row",checkboxSelectionUnselectRow:"Unselect row",booleanCellTrueLabel:"yes",booleanCellFalseLabel:"no",longTextCellExpandLabel:"Expand",longTextCellCollapseLabel:"Collapse",actionsCellMore:"more",pinToLeft:"Pin to left",pinToRight:"Pin to right",unpin:"Unpin",treeDataGroupingHeaderName:"Group",treeDataExpand:"see children",treeDataCollapse:"hide children",groupingColumnHeaderName:"Group",groupColumn:e=>`Group by ${e}`,unGroupColumn:e=>`Stop grouping by ${e}`,detailPanelToggle:"Detail panel toggle",expandDetailPanel:"Expand",collapseDetailPanel:"Collapse",paginationRowsPerPage:"Rows per page:",paginationDisplayedRows:({from:e,to:t,count:n,estimated:r})=>r?`${e}–${t} of ${-1!==n?n:r&&r>t?`around ${r}`:`more than ${t}`}`:`${e}–${t} of ${-1!==n?n:`more than ${t}`}`,paginationItemAriaLabel:e=>"first"===e?"Go to first page":"last"===e?"Go to last page":"next"===e?"Go to next page":"Go to previous page",rowReorderingHeaderName:"Row reordering",aggregationMenuItemHeader:"Aggregation",aggregationFunctionLabelNone:"none",aggregationFunctionLabelSum:"sum",aggregationFunctionLabelAvg:"avg",aggregationFunctionLabelMin:"min",aggregationFunctionLabelMax:"max",aggregationFunctionLabelSize:"size",pivotToggleLabel:"Pivot",pivotRows:"Rows",pivotColumns:"Columns",pivotValues:"Values",pivotCloseButton:"Close pivot settings",pivotSearchButton:"Search fields",pivotSearchControlPlaceholder:"Search fields",pivotSearchControlLabel:"Search fields",pivotSearchControlClear:"Clear search",pivotNoFields:"No fields",pivotMenuMoveUp:"Move up",pivotMenuMoveDown:"Move down",pivotMenuMoveToTop:"Move to top",pivotMenuMoveToBottom:"Move to bottom",pivotMenuRows:"Rows",pivotMenuColumns:"Columns",pivotMenuValues:"Values",pivotMenuOptions:"Field options",pivotMenuAddToRows:"Add to Rows",pivotMenuAddToColumns:"Add to Columns",pivotMenuAddToValues:"Add to Values",pivotMenuRemove:"Remove",pivotDragToRows:"Drag here to create rows",pivotDragToColumns:"Drag here to create columns",pivotDragToValues:"Drag here to create values",pivotYearColumnHeaderName:"(Year)",pivotQuarterColumnHeaderName:"(Quarter)",chartsNoCharts:"There are no charts available",chartsChartNotSelected:"Select a chart type to configure its options",chartsTabChart:"Chart",chartsTabFields:"Fields",chartsTabCustomize:"Customize",chartsCloseButton:"Close charts configuration",chartsSyncButtonLabel:"Sync chart",chartsSearchPlaceholder:"Search fields",chartsSearchLabel:"Search fields",chartsSearchClear:"Clear search",chartsNoFields:"No fields",chartsFieldBlocked:"This field cannot be added to any section",chartsCategories:"Categories",chartsSeries:"Series",chartsMenuAddToDimensions:e=>`Add to ${e}`,chartsMenuAddToValues:e=>`Add to ${e}`,chartsMenuMoveUp:"Move up",chartsMenuMoveDown:"Move down",chartsMenuMoveToTop:"Move to top",chartsMenuMoveToBottom:"Move to bottom",chartsMenuOptions:"Field options",chartsMenuRemove:"Remove",chartsDragToDimensions:e=>`Drag here to use column as ${e}`,chartsDragToValues:e=>`Drag here to use column as ${e}`,aiAssistantPanelTitle:"AI Assistant",aiAssistantPanelClose:"Close AI Assistant",aiAssistantPanelNewConversation:"New conversation",aiAssistantPanelConversationHistory:"Conversation history",aiAssistantPanelEmptyConversation:"No prompt history",aiAssistantSuggestions:"Suggestions",promptFieldLabel:"Prompt",promptFieldPlaceholder:"Type a prompt…",promptFieldPlaceholderWithRecording:"Type or record a prompt…",promptFieldPlaceholderListening:"Listening for prompt…",promptFieldSpeechRecognitionNotSupported:"Speech recognition is not supported in this browser",promptFieldSend:"Send",promptFieldRecord:"Record",promptFieldStopRecording:"Stop recording",promptRerun:"Run again",promptProcessing:"Processing…",promptAppliedChanges:"Applied changes",promptChangeGroupDescription:e=>`Group by ${e}`,promptChangeAggregationLabel:(e,t)=>`${e} (${t})`,promptChangeAggregationDescription:(e,t)=>`Aggregate ${e} (${t})`,promptChangeFilterLabel:(e,t,n)=>"is any of"===t?`${e} is any of: ${n}`:`${e} ${t} ${n}`,promptChangeFilterDescription:(e,t,n)=>"is any of"===t?`Filter where ${e} is any of: ${n}`:`Filter where ${e} ${t} ${n}`,promptChangeSortDescription:(e,t)=>`Sort by ${e} (${t})`,promptChangePivotEnableLabel:"Pivot",promptChangePivotEnableDescription:"Enable pivot",promptChangePivotColumnsLabel:e=>`Columns (${e})`,promptChangePivotColumnsDescription:(e,t)=>`${e}${t?` (${t})`:""}`,promptChangePivotRowsLabel:e=>`Rows (${e})`,promptChangePivotValuesLabel:e=>`Values (${e})`,promptChangePivotValuesDescription:(e,t)=>`${e} (${t})`,promptChangeChartsLabel:(e,t)=>`Dimensions (${e}), Values (${t})`},fu=["field","type","align","width","height","empty","style","className"],pu="1.3em",hu=[40,80],gu={number:[40,60],string:[40,80],date:[40,60],dateTime:[60,80],singleSelect:[40,80]},mu=function(){const e=(t=12345,()=>{let e=t+=1831565813;return e=Math.imul(e^e>>>15,1|e),e^=e+Math.imul(e^e>>>7,61|e),((e^e>>>14)>>>0)/4294967296});var t;return(t,n)=>t+(n-t)*e()}(),Au=B(function(e){const{field:t,type:n,align:i,width:a,height:l,empty:s=!1,style:c,className:u}=e,d=(0,x.A)(e,fu),f=se(),p=(e=>{const{align:t,classes:n,empty:r}=e,o={root:["cell","cellSkeleton",`cell--text${t?(0,k.A)(t):"Left"}`,r&&"cellEmpty"]};return(0,R.A)(o,D,n)})({classes:f.classes,align:i,empty:s}),h=o.useMemo(()=>{if("boolean"===n||"actions"===n)return{variant:"circular",width:pu,height:pu};const[e,t]=n?gu[n]??hu:hu;return{variant:"text",width:`${Math.round(mu(e,t))}%`,height:"1.2em"}},[n]);return(0,r.jsx)("div",(0,y.A)({"data-field":t,className:(0,E.A)(p.root,u),style:(0,y.A)({height:l,maxWidth:a,minWidth:a},c)},d,{children:!s&&(0,r.jsx)(f.slots.baseSkeleton,(0,y.A)({},h))}))}),bu=["className"],vu=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"IconButtonContainer"})(()=>({display:"flex",visibility:"hidden",width:0})),yu=S(function(e,t){const{className:n}=e,o=(0,x.A)(e,bu),i=se(),a=(e=>{const{classes:t}=e;return(0,R.A)({root:["iconButtonContainer"]},D,t)})(i);return(0,r.jsx)(vu,(0,y.A)({className:(0,E.A)(a.root,n),ownerState:i},o,{ref:t}))});function wu(e){const{counter:t,field:n,onClick:i}=e,a=ot(),l=se(),s=(e=>{const{classes:t}=e;return(0,R.A)({icon:["filterIcon"]},D,t)})((0,y.A)({},e,{classes:l.classes})),c=(0,an.A)(),u=J(a,tt,c),d=(0,an.A)(),f=o.useCallback(e=>{e.preventDefault(),e.stopPropagation();const{open:t,openedPanelValue:r}=et(a);t&&r===nt.filters?a.current.hideFilterPanel():a.current.showFilterPanel(void 0,d,c),i&&i(a.current.getColumnHeaderParams(n),e)},[a,n,i,d,c]);if(!t)return null;const p=(0,r.jsx)(l.slots.baseIconButton,(0,y.A)({id:c,onClick:f,"aria-label":a.current.getLocaleText("columnHeaderFiltersLabel"),size:"small",tabIndex:-1,"aria-haspopup":"menu","aria-expanded":u,"aria-controls":u?d:void 0},l.slotProps?.baseIconButton,{children:(0,r.jsx)(l.slots.columnFilteredIcon,{className:s.icon,fontSize:"small"})}));return(0,r.jsx)(l.slots.baseTooltip,(0,y.A)({title:a.current.getLocaleText("columnHeaderFiltersTooltipActive")(t),enterDelay:1e3},l.slotProps?.baseTooltip,{children:(0,r.jsxs)(yu,{children:[t>1&&(0,r.jsx)(l.slots.baseBadge,{badgeContent:t,color:"default",children:p}),1===t&&p]})}))}const Cu=["direction","index","sortingOrder","disabled","className"],Su=(0,_.Ay)(qt,{name:"MuiDataGrid",slot:"SortButton"})({transition:z.transition(["opacity"],{duration:z.transitions.duration.short,easing:z.transitions.easing.easeInOut})});function xu(e){const{direction:t,index:n,sortingOrder:o,disabled:i,className:a}=e,l=(0,x.A)(e,Cu),s=ot(),c=se(),u=(0,y.A)({},e,{classes:c.classes}),d=(e=>{const{classes:t}=e;return(0,R.A)({root:["sortButton"],icon:["sortIcon"]},D,t)})(u),f=function(e,t,n,o){let i;const a={};return"asc"===t?i=e.columnSortedAscendingIcon:"desc"===t?i=e.columnSortedDescendingIcon:(i=e.columnUnsortedIcon,a.sortingOrder=o),i?(0,r.jsx)(i,(0,y.A)({fontSize:"small",className:n},a)):null}(c.slots,t,d.icon,o);if(!f)return null;const p=(0,r.jsx)(Su,(0,y.A)({as:c.slots.baseIconButton,ownerState:u,"aria-label":s.current.getLocaleText("columnHeaderSortIconLabel"),size:"small",disabled:i,className:(0,E.A)(d.root,a)},c.slotProps?.baseIconButton,l,{children:f}));return(0,r.jsx)(c.slots.baseTooltip,(0,y.A)({title:s.current.getLocaleText("columnHeaderSortIconLabel"),enterDelay:1e3},c.slotProps?.baseTooltip,{children:(0,r.jsxs)("span",{children:[null!=n&&(0,r.jsx)(c.slots.baseBadge,{badgeContent:n,color:"default",overlap:"circular",children:p}),null==n&&p]})}))}function Eu(e){return(0,r.jsx)(yu,{children:(0,r.jsx)(xu,(0,y.A)({},e,{tabIndex:-1}))})}const Iu=o.memo(Eu),ku=["className","selectedRowCount"],Ru=(0,Bi.A)("div",{name:"MuiDataGrid",slot:"SelectedRowCount"})({alignItems:"center",display:"flex",margin:z.spacing(0,2),visibility:"hidden",width:0,height:0,[z.breakpoints.up("sm")]:{visibility:"visible",width:"auto",height:"auto"}}),Mu=S(function(e,t){const{className:n,selectedRowCount:o}=e,i=(0,x.A)(e,ku),a=ot(),l=se(),s=(e=>{const{classes:t}=e;return(0,R.A)({root:["selectedRowCount"]},D,t)})(l),c=a.current.getLocaleText("footerRowSelected")(o);return(0,r.jsx)(Ru,(0,y.A)({className:(0,E.A)(s.root,n),ownerState:l},i,{ref:t,children:c}))}),Pu=["className"],Bu=(0,Bi.A)("div",{name:"MuiDataGrid",slot:"FooterContainer"})({display:"flex",justifyContent:"space-between",alignItems:"center",minHeight:52,borderTop:"1px solid"}),_u=S(function(e,t){const{className:n}=e,o=(0,x.A)(e,Pu),i=se(),a=(e=>{const{classes:t}=e;return(0,R.A)({root:["footerContainer","withBorderColor"]},D,t)})(i);return(0,r.jsx)(Bu,(0,y.A)({className:(0,E.A)(a.root,n),ownerState:i},o,{ref:t}))}),Tu=S(function(e,t){const n=ot(),o=se(),i=J(n,xt),a=J(n,Rl),l=J(n,ai),s=!o.hideFooterSelectedRowCount&&a>0?(0,r.jsx)(Mu,{selectedRowCount:a}):(0,r.jsx)("div",{}),c=o.hideFooterRowCount||o.pagination?null:(0,r.jsx)(o.slots.footerRowCount,(0,y.A)({},o.slotProps?.footerRowCount,{rowCount:i,visibleRowCount:l})),u=o.pagination&&!o.hideFooterPagination&&o.slots.pagination&&(0,r.jsx)(o.slots.pagination,(0,y.A)({},o.slotProps?.pagination));return(0,r.jsxs)(_u,(0,y.A)({},e,{ref:t,children:[s,c,u]}))}),Ou=["className","rowCount","visibleRowCount"],Du=(0,Bi.A)("div",{name:"MuiDataGrid",slot:"RowCount"})({alignItems:"center",display:"flex",margin:z.spacing(0,2)}),Nu=S(function(e,t){const{className:n,rowCount:o,visibleRowCount:i}=e,a=(0,x.A)(e,Ou),l=ot(),s=se(),c=(e=>{const{classes:t}=e;return(0,R.A)({root:["rowCount"]},D,t)})(s);if(0===o)return null;const u=i<o?l.current.getLocaleText("footerTotalVisibleRows")(i,o):o.toLocaleString();return(0,r.jsxs)(Du,(0,y.A)({className:(0,E.A)(c.root,n),ownerState:s},a,{ref:t,children:[l.current.getLocaleText("footerTotalRows")," ",u]}))}),Lu=["className"],Fu=(0,Bi.A)("div",{name:"MuiDataGrid",slot:"Overlay"})({width:"100%",height:"100%",display:"flex",gap:z.spacing(1),flexDirection:"column",alignSelf:"center",alignItems:"center",justifyContent:"center",textAlign:"center",textWrap:"balance",backgroundColor:z.colors.background.backdrop}),Qu=S(function(e,t){const{className:n}=e,o=(0,x.A)(e,Lu),i=se(),a=(e=>{const{classes:t}=e;return(0,R.A)({root:["overlay"]},D,t)})(i);return(0,r.jsx)(Fu,(0,y.A)({className:(0,E.A)(a.root,n),ownerState:i},o,{ref:t}))}),ju=(e,t,n,r,o,i)=>{let a;switch(e){case hr.LEFT:a=r[n];break;case hr.RIGHT:a=o-r[n]-t+i;break;default:a=void 0}return Number.isNaN(a)&&(a=void 0),a},zu=(e,t,n,r,o,i)=>{const a=t===n-1;return!(!i?.startsWith("border")||e!==hr.LEFT||!a)||!!r&&(e===hr.LEFT||(e===hr.RIGHT?!a:!a||o))},$u=(e,t,n,r)=>r?.startsWith("border")?e===hr.RIGHT&&0===t:n&&e===hr.RIGHT&&0===t,Hu=(e,t)=>{if(e)if(t){if(e===hr.LEFT)return"right";if(e===hr.RIGHT)return"left"}else{if(e===hr.LEFT)return"left";if(e===hr.RIGHT)return"right"}};function Gu(e,t,n,r){const o=Hu(n,t);return o&&void 0!==r?(e[o]=r,e):e}const Vu=["skeletonRowsCount","visibleColumns","showFirstRowBorder"],Wu=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"SkeletonLoadingOverlay"})({minWidth:"100%",width:"max-content",height:"100%",overflow:"clip"}),Uu=e=>parseInt(e.getAttribute("data-colindex"),10),qu=S(function(e,t){const n=se(),{slots:i}=n,a=(0,Hr.I)(),l=(e=>{const{classes:t}=e;return(0,R.A)({root:["skeletonLoadingOverlay"]},D,t)})({classes:n.classes}),s=o.useRef(null),c=(0,I.A)(s,t),u=ot(),d=J(u,ut),f=J(u,dt),p=J(u,Ke),h=o.useMemo(()=>p.filter(e=>e<=f).length,[f,p]),{skeletonRowsCount:g,visibleColumns:m,showFirstRowBorder:A}=e,b=(0,x.A)(e,Vu),v=J(u,Ve),w=o.useMemo(()=>v.slice(0,h),[v,h]),C=J(u,qe),S=o.useCallback(e=>-1!==C.left.findIndex(t=>t.field===e)?hr.LEFT:-1!==C.right.findIndex(t=>t.field===e)?hr.RIGHT:void 0,[C.left,C.right]),k=o.useMemo(()=>{const e=[];for(let t=0;t<g;t+=1){const o=[];for(let e=0;e<w.length;e+=1){const l=w[e],s=S(l.field),c=s===hr.LEFT,u=s===hr.RIGHT,f=Hu(s,a),h=f?C[f].length:w.length-C.left.length-C.right.length,g=f?C[f].findIndex(e=>e.field===l.field):e-C.left.length,A=d.hasScrollY?d.scrollbarSize:0,b=Gu({},a,s,ju(s,l.computedWidth,e,p,d.columnsTotalWidth,A)),v=d.columnsTotalWidth<d.viewportOuterSize.width,x=zu(s,g,h,n.showCellVerticalBorder,v,n.pinnedColumnsSectionSeparator),I=$u(s,g,n.showCellVerticalBorder,n.pinnedColumnsSectionSeparator),k=u&&0===g,R=k&&v,M=e===w.length-1&&!k&&v,P=d.viewportOuterSize.width-d.columnsTotalWidth,B=Math.max(0,P),_=(0,r.jsx)(i.skeletonCell,{width:B,empty:!0},`skeleton-filler-column-${t}`);R&&o.push(_),o.push((0,r.jsx)(i.skeletonCell,{field:l.field,type:l.type,align:l.align,width:"var(--width)",height:d.rowHeight,"data-colindex":e,empty:m&&!m.has(l.field),className:(0,E.A)(c&&L["cell--pinnedLeft"],u&&L["cell--pinnedRight"],x&&L["cell--withRightBorder"],I&&L["cell--withLeftBorder"]),style:(0,y.A)({"--width":`${l.computedWidth}px`},b)},`skeleton-column-${t}-${l.field}`)),M&&o.push(_)}e.push((0,r.jsx)("div",{className:(0,E.A)(L.row,L.rowSkeleton,0===t&&!A&&L["row--firstVisible"]),children:o},`skeleton-row-${t}`))}return e},[g,w,S,a,C,d.hasScrollY,d.scrollbarSize,d.columnsTotalWidth,d.viewportOuterSize.width,d.rowHeight,p,n.showCellVerticalBorder,n.pinnedColumnsSectionSeparator,i,m,A]);return $t(u,"columnResize",e=>{const{colDef:t,width:n}=e,r=s.current?.querySelectorAll(`[data-field="${Gs(t.field)}"]`);if(!r)throw new Error("MUI X: Expected skeleton cells to be defined with `data-field` attribute.");const o=w.findIndex(e=>e.field===t.field),i=S(t.field),a=i===hr.LEFT,l=i===hr.RIGHT,c=getComputedStyle(r[0]).getPropertyValue("--width"),u=parseInt(c,10)-n;if(r&&r.forEach(e=>{e.style.setProperty("--width",`${n}px`)}),a){const e=s.current?.querySelectorAll(`.${L["cell--pinnedLeft"]}`);e?.forEach(e=>{Uu(e)>o&&(e.style.left=parseInt(getComputedStyle(e).left,10)-u+"px")})}if(l){const e=s.current?.querySelectorAll(`.${L["cell--pinnedRight"]}`);e?.forEach(e=>{Uu(e)<o&&(e.style.right=`${parseInt(getComputedStyle(e).right,10)+u}px`)})}}),(0,r.jsx)(Wu,(0,y.A)({className:l.root},b,{ref:c,children:k}))}),Yu=S(function(e,t){const n=J(ot(),ut),o=n?.viewportInnerSize.height??0,i=Math.ceil(o/n.rowHeight);return(0,r.jsx)(qu,(0,y.A)({},e,{skeletonRowsCount:i,ref:t}))}),Ku=["variant","noRowsVariant","style"],Ju={"circular-progress":{component:e=>e.slots.baseCircularProgress,style:{}},"linear-progress":{component:e=>e.slots.baseLinearProgress,style:{display:"block"}},skeleton:{component:()=>Yu,style:{display:"block"}}},Xu=S(function(e,t){const{variant:n="linear-progress",noRowsVariant:o="skeleton",style:i}=e,a=(0,x.A)(e,Ku),l=ot(),s=se(),c=J(l,Ct),u=Ju[0===c?o:n],d=u.component(s);return(0,r.jsx)(Qu,(0,y.A)({style:(0,y.A)({},u.style,i)},a,{ref:t,children:(0,r.jsx)(d,{})}))}),Zu=S(function(e,t){const n=ot().current.getLocaleText("noRowsLabel");return(0,r.jsx)(Qu,(0,y.A)({},e,{ref:t,children:n}))}),ed=S(function(e,t){const n=se(),o=ot(),i=J(o,je),a=!n.disableColumnSelector&&i.length>0;return(0,r.jsxs)(Qu,(0,y.A)({},e,{ref:t,children:[o.current.getLocaleText("noColumnsOverlayLabel"),a&&(0,r.jsx)(n.slots.baseButton,(0,y.A)({size:"small"},n.slotProps?.baseButton,{onClick:()=>{o.current.showPreferences(nt.columns)},children:o.current.getLocaleText("noColumnsOverlayManageColumns")}))]}))}),td=(0,_.Ay)(qt,{slot:"internal"})({maxHeight:"calc(100% + 1px)",flexGrow:1}),nd=["className"],rd=(0,Bi.A)("div",{name:"MuiDataGrid",slot:"PanelContent"})({display:"flex",flexDirection:"column",overflow:"auto",flex:"1 1",maxHeight:400,padding:z.spacing(2.5,1.5,2,1),gap:z.spacing(2.5)});function od(e){const{className:t}=e,n=(0,x.A)(e,nd),o=se(),i=(e=>{const{classes:t}=e;return(0,R.A)({root:["panelContent"]},D,t)})(o);return(0,r.jsx)(rd,(0,y.A)({className:(0,E.A)(i.root,t),ownerState:o},n))}const id=["className"],ad=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"PanelFooter"})({padding:z.spacing(1),display:"flex",justifyContent:"space-between",borderTop:`1px solid ${z.colors.border.base}`});function ld(e){const{className:t}=e,n=(0,x.A)(e,id),o=se(),i=(e=>{const{classes:t}=e;return(0,R.A)({root:["panelFooter"]},D,t)})(o);return(0,r.jsx)(ad,(0,y.A)({className:(0,E.A)(i.root,t),ownerState:o},n))}const sd=["className"],cd=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"PanelWrapper"})({display:"flex",flexDirection:"column",flex:1,"&:focus":{outline:0}}),ud=S(function(e,t){const{className:n}=e,o=(0,x.A)(e,sd),i=se(),a=(e=>{const{classes:t}=e;return(0,R.A)({root:["panelWrapper"]},D,t)})(i);return(0,r.jsx)(cd,(0,y.A)({tabIndex:-1,className:(0,E.A)(a.root,n),ownerState:i},o,{ref:t}))}),dd=["item","hasMultipleFilters","deleteFilter","applyFilterChanges","showMultiFilterOperators","disableMultiFilterOperator","applyMultiFilterOperatorChanges","focusElementRef","logicOperators","columnsSort","filterColumns","deleteIconProps","logicOperatorInputProps","operatorInputProps","columnInputProps","valueInputProps","readOnly","children"],fd=["InputComponentProps"],pd=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"FilterForm"})({display:"flex",gap:z.spacing(1.5)}),hd=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"FilterFormDeleteIcon"})({flexShrink:0,display:"flex",justifyContent:"center",alignItems:"center"}),gd=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"FilterFormLogicOperatorInput"})({minWidth:75,justifyContent:"end"}),md=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"FilterFormColumnInput"})({width:150}),Ad=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"FilterFormOperatorInput"})({width:150}),bd=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"FilterFormValueInput"})({width:190}),vd=e=>e.headerName||e.field,yd=new Intl.Collator,wd=S(function(e,t){const{item:n,hasMultipleFilters:i,deleteFilter:a,applyFilterChanges:l,showMultiFilterOperators:s,disableMultiFilterOperator:c,applyMultiFilterOperatorChanges:u,focusElementRef:d,logicOperators:f=[An.And,An.Or],columnsSort:p,filterColumns:h,deleteIconProps:g={},logicOperatorInputProps:m={},operatorInputProps:A={},columnInputProps:b={},valueInputProps:v={},readOnly:w}=e,C=(0,x.A)(e,dd),S=ot(),I=J(S,ze),M=J(S,Je),P=J(S,Ko),B=(0,an.A)(),_=(0,an.A)(),T=(0,an.A)(),O=(0,an.A)(),N=se(),L=(e=>{const{classes:t}=e;return(0,R.A)({root:["filterForm"],deleteIcon:["filterFormDeleteIcon"],logicOperatorInput:["filterFormLogicOperatorInput"],columnInput:["filterFormColumnInput"],operatorInput:["filterFormOperatorInput"],valueInput:["filterFormValueInput"]},D,t)})(N),F=o.useRef(null),Q=o.useRef(null),j=P.logicOperator??An.And,z=i&&f.length>0,$=(N.slotProps?.baseSelect||{}).native??!1,H=N.slotProps?.baseSelectOption||{},{InputComponentProps:G}=v,V=(0,x.A)(v,fd),W=J(S,fi),U=J(S,hi),{filteredColumns:q,selectedField:Y}=o.useMemo(()=>{let e=n.field;const t=!1===I[n.field].filterable?I[n.field]:null;if(t)return{filteredColumns:[t],selectedField:e};if(W)return{filteredColumns:M.filter(e=>void 0!==U.get(e.field)),selectedField:e};if(void 0===h||"function"!=typeof h)return{filteredColumns:M,selectedField:e};const r=h({field:n.field,columns:M,currentFilters:P?.items||[]});return{filteredColumns:M.filter(t=>{const o=r.includes(t.field);return t.field!==n.field||o||(e=void 0),o}),selectedField:e}},[n.field,I,W,h,M,P?.items,U]),K=o.useMemo(()=>{switch(p){case"asc":return q.sort((e,t)=>yd.compare(vd(e),vd(t)));case"desc":return q.sort((e,t)=>-yd.compare(vd(e),vd(t)));default:return q}},[q,p]),X=n.field?S.current.getColumn(n.field):null,Z=o.useMemo(()=>n.operator&&X?X.filterOperators?.find(e=>e.value===n.operator):null,[n,X]),ee=o.useCallback(e=>{const t=e.target.value,r=S.current.getColumn(t);if(r.field===X.field)return;const o=r.filterOperators.find(e=>e.value===n.operator)||r.filterOperators[0];let i=o.InputComponent&&o.InputComponent===Z?.InputComponent&&r.type===X.type?n.value:void 0;if("singleSelect"===r.type&&void 0!==i){const e=r,t=Tr(e);Array.isArray(i)?i=i.filter(n=>void 0!==Or(n,t,e?.getOptionValue)):void 0===Or(n.value,t,e?.getOptionValue)&&(i=void 0)}l((0,y.A)({},n,{field:t,operator:o.value,value:i}))},[S,l,n,X,Z]),te=o.useCallback(e=>{const t=e.target.value,r=X?.filterOperators.find(e=>e.value===t),o=!r?.InputComponent||r?.InputComponent!==Z?.InputComponent;l((0,y.A)({},n,{operator:t,value:o?void 0:n.value}))},[l,n,X,Z]),ne=o.useCallback(e=>{const t=e.target.value===An.And.toString()?An.And:An.Or;u(t)},[u]);return o.useImperativeHandle(d,()=>({focus:()=>{Z?.InputComponent?F?.current?.focus():Q.current.focus()}}),[Z]),(0,r.jsxs)(pd,(0,y.A)({className:L.root,"data-id":n.id,ownerState:N},C,{ref:t,children:[(0,r.jsx)(hd,(0,y.A)({},g,{className:(0,E.A)(L.deleteIcon,g.className),ownerState:N,children:(0,r.jsx)(N.slots.baseIconButton,(0,y.A)({"aria-label":S.current.getLocaleText("filterPanelDeleteIconLabel"),title:S.current.getLocaleText("filterPanelDeleteIconLabel"),onClick:()=>{a(n)},size:"small",disabled:w},N.slotProps?.baseIconButton,{children:(0,r.jsx)(N.slots.filterPanelDeleteIcon,{fontSize:"small"})}))})),(0,r.jsx)(gd,(0,y.A)({as:N.slots.baseSelect,sx:[z?{display:"flex"}:{display:"none"},s?{visibility:"visible"}:{visibility:"hidden"},m.sx],className:(0,E.A)(L.logicOperatorInput,m.className),ownerState:N},m,{size:"small",slotProps:{htmlInput:{"aria-label":S.current.getLocaleText("filterPanelLogicOperator")}},value:j??"",onChange:ne,disabled:!!c||1===f.length,native:$},N.slotProps?.baseSelect,{children:f.map(e=>(0,o.createElement)(N.slots.baseSelectOption,(0,y.A)({},H,{native:$,key:e.toString(),value:e.toString()}),S.current.getLocaleText((e=>{switch(e){case An.And:return"filterPanelOperatorAnd";case An.Or:return"filterPanelOperatorOr";default:throw new Error("MUI X: Invalid `logicOperator` property in the `GridFilterPanel`.")}})(e))))})),(0,r.jsx)(md,(0,y.A)({as:N.slots.baseSelect},b,{className:(0,E.A)(L.columnInput,b.className),ownerState:N,size:"small",labelId:_,id:B,label:S.current.getLocaleText("filterPanelColumns"),value:Y??"",onChange:ee,native:$,disabled:w},N.slotProps?.baseSelect,{children:K.map(e=>(0,o.createElement)(N.slots.baseSelectOption,(0,y.A)({},H,{native:$,key:e.field,value:e.field}),vd(e)))})),(0,r.jsx)(Ad,(0,y.A)({as:N.slots.baseSelect,size:"small"},A,{className:(0,E.A)(L.operatorInput,A.className),ownerState:N,labelId:O,label:S.current.getLocaleText("filterPanelOperator"),id:T,value:n.operator,onChange:te,native:$,inputRef:Q,disabled:w},N.slotProps?.baseSelect,{children:X?.filterOperators?.map(e=>(0,o.createElement)(N.slots.baseSelectOption,(0,y.A)({},H,{native:$,key:e.value,value:e.value}),e.label||S.current.getLocaleText(`filterOperator${(0,k.A)(e.value)}`)))})),(0,r.jsx)(bd,(0,y.A)({},V,{className:(0,E.A)(L.valueInput,V.className),ownerState:N,children:Z?.InputComponent?(0,r.jsx)(Z.InputComponent,(0,y.A)({apiRef:S,item:n,applyValue:l,focusElementRef:F,disabled:w,slotProps:{root:{size:"small"}}},Z.InputComponentProps,G),n.field):null}))]}))}),Cd=["logicOperators","columnsSort","filterFormProps","getColumnForNewFilter","children","disableAddFilterButton","disableRemoveAllButton"],Sd=e=>({field:e.field,operator:e.filterOperators[0].value,id:Math.round(1e5*Math.random())}),xd=S(function(e,t){const n=ot(),i=se(),a=J(n,Ko),l=J(n,Je),s=J(n,Xe),c=o.useRef(null),u=o.useRef(null),{logicOperators:d=[An.And,An.Or],columnsSort:f,filterFormProps:p,getColumnForNewFilter:h,disableAddFilterButton:g=!1,disableRemoveAllButton:m=!1}=e,A=(0,x.A)(e,Cd),b=n.current.upsertFilterItem,v=o.useCallback(e=>{n.current.setFilterLogicOperator(e)},[n]),w=o.useCallback(()=>{let e;if(h&&"function"==typeof h){const t=h({currentFilters:a?.items||[],columns:l});if(null===t)return null;e=l.find(({field:e})=>e===t)}else e=l.find(e=>e.filterOperators?.length);return e?Sd(e):null},[a?.items,l,h]),C=o.useCallback(()=>{if(void 0===h||"function"!=typeof h)return w();const e=a.items.length?a.items:[w()].filter(Boolean),t=h({currentFilters:e,columns:l});if(null===t)return null;const n=l.find(({field:e})=>e===t);return n?Sd(n):null},[a.items,l,h,w]),S=o.useMemo(()=>a.items.length?a.items:(u.current||(u.current=w()),u.current?[u.current]:[]),[a.items,w]),E=S.length>1,{readOnlyFilters:I,validFilters:k}=o.useMemo(()=>S.reduce((e,t)=>(s[t.field]?e.validFilters.push(t):e.readOnlyFilters.push(t),e),{readOnlyFilters:[],validFilters:[]}),[S,s]),R=o.useCallback(()=>{const e=C();e&&n.current.upsertFilterItems([...S,e])},[n,C,S]),M=o.useCallback(e=>{const t=1===k.length;n.current.deleteFilterItem(e),t&&n.current.hideFilterPanel()},[n,k.length]),P=o.useCallback(()=>1===k.length&&void 0===k[0].value?(n.current.deleteFilterItem(k[0]),n.current.hideFilterPanel()):n.current.setFilterModel((0,y.A)({},a,{items:I}),"removeAllFilterItems"),[n,I,a,k]);return o.useEffect(()=>{d.length>0&&a.logicOperator&&!d.includes(a.logicOperator)&&v(d[0])},[d,v,a.logicOperator]),o.useEffect(()=>{k.length>0&&c.current.focus()},[k.length]),(0,r.jsxs)(ud,(0,y.A)({},A,{ref:t,children:[(0,r.jsxs)(od,{children:[I.map((e,t)=>(0,r.jsx)(wd,(0,y.A)({item:e,applyFilterChanges:b,deleteFilter:M,hasMultipleFilters:E,showMultiFilterOperators:t>0,disableMultiFilterOperator:1!==t,applyMultiFilterOperatorChanges:v,focusElementRef:null,readOnly:!0,logicOperators:d,columnsSort:f},p),null==e.id?t:e.id)),k.map((e,t)=>(0,r.jsx)(wd,(0,y.A)({item:e,applyFilterChanges:b,deleteFilter:M,hasMultipleFilters:E,showMultiFilterOperators:I.length+t>0,disableMultiFilterOperator:I.length+t!==1,applyMultiFilterOperatorChanges:v,focusElementRef:t===k.length-1?c:null,logicOperators:d,columnsSort:f},p),null==e.id?t+I.length:e.id))]}),i.disableMultipleColumnsFiltering||g&&m?null:(0,r.jsxs)(ld,{children:[g?(0,r.jsx)("span",{}):(0,r.jsx)(i.slots.baseButton,(0,y.A)({onClick:R,startIcon:(0,r.jsx)(i.slots.filterPanelAddIcon,{})},i.slotProps?.baseButton,{children:n.current.getLocaleText("filterPanelAddFilter")})),!m&&k.length>0?(0,r.jsx)(i.slots.baseButton,(0,y.A)({onClick:P,startIcon:(0,r.jsx)(i.slots.filterPanelRemoveAllIcon,{})},i.slotProps?.baseButton,{children:n.current.getLocaleText("filterPanelRemoveAll")})):null]})]}))});var Ed=n(8751);const Id=(e,t)=>(e.headerName||e.field).toLowerCase().indexOf(t)>-1;var kd=n(553);const Rd=["children"],Md=(0,kd.i7)({from:{opacity:0},to:{opacity:1}}),Pd=(0,kd.i7)({"from, to":{"--scrollable":'" "'}}),Bd=(0,Bi.A)("div",{name:"MuiDataGrid",slot:"ShadowScrollArea"})`
|
|
2
|
+
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.ReactMSAView=t():e.ReactMSAView=t()}(self,()=>(()=>{var e,t,n={8371(e,t,n){"use strict";function r(e){var t=Object.create(null);return function(n){return void 0===t[n]&&(t[n]=e(n)),t[n]}}n.d(t,{A:()=>r})},1733(e,t,n){"use strict";n.d(t,{E:()=>me,T:()=>de,_:()=>ce,c:()=>he,h:()=>fe,w:()=>ue});var r=n(405),o=function(){function e(e){var t=this;this._insertTag=function(e){var n;n=0===t.tags.length?t.insertionPoint?t.insertionPoint.nextSibling:t.prepend?t.container.firstChild:t.before:t.tags[t.tags.length-1].nextSibling,t.container.insertBefore(e,n),t.tags.push(e)},this.isSpeedy=void 0===e.speedy||e.speedy,this.tags=[],this.ctr=0,this.nonce=e.nonce,this.key=e.key,this.container=e.container,this.prepend=e.prepend,this.insertionPoint=e.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(e){e.forEach(this._insertTag)},t.insert=function(e){this.ctr%(this.isSpeedy?65e3:1)==0&&this._insertTag(function(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),void 0!==e.nonce&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}(this));var t=this.tags[this.tags.length-1];if(this.isSpeedy){var n=function(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}(t);try{n.insertRule(e,n.cssRules.length)}catch(e){}}else t.appendChild(document.createTextNode(e));this.ctr++},t.flush=function(){this.tags.forEach(function(e){var t;return null==(t=e.parentNode)?void 0:t.removeChild(e)}),this.tags=[],this.ctr=0},e}(),i=Math.abs,a=String.fromCharCode,l=Object.assign;function s(e){return e.trim()}function c(e,t,n){return e.replace(t,n)}function u(e,t){return e.indexOf(t)}function d(e,t){return 0|e.charCodeAt(t)}function f(e,t,n){return e.slice(t,n)}function p(e){return e.length}function h(e){return e.length}function g(e,t){return t.push(e),e}var m=1,A=1,b=0,v=0,y=0,w="";function C(e,t,n,r,o,i,a){return{value:e,root:t,parent:n,type:r,props:o,children:i,line:m,column:A,length:a,return:""}}function S(e,t){return l(C("",null,null,"",null,null,0),e,{length:-e.length},t)}function x(){return y=v>0?d(w,--v):0,A--,10===y&&(A=1,m--),y}function E(){return y=v<b?d(w,v++):0,A++,10===y&&(A=1,m++),y}function I(){return d(w,v)}function k(){return v}function R(e,t){return f(w,e,t)}function M(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function P(e){return m=A=1,b=p(w=e),v=0,[]}function B(e){return w="",e}function _(e){return s(R(v-1,D(91===e?e+2:40===e?e+1:e)))}function T(e){for(;(y=I())&&y<33;)E();return M(e)>2||M(y)>3?"":" "}function O(e,t){for(;--t&&E()&&!(y<48||y>102||y>57&&y<65||y>70&&y<97););return R(e,k()+(t<6&&32==I()&&32==E()))}function D(e){for(;E();)switch(y){case e:return v;case 34:case 39:34!==e&&39!==e&&D(y);break;case 40:41===e&&D(e);break;case 92:E()}return v}function N(e,t){for(;E()&&e+y!==57&&(e+y!==84||47!==I()););return"/*"+R(t,v-1)+"*"+a(47===e?e:E())}function L(e){for(;!M(I());)E();return R(e,v)}var F="-ms-",Q="-moz-",j="-webkit-",z="comm",$="rule",H="decl",G="@keyframes";function V(e,t){for(var n="",r=h(e),o=0;o<r;o++)n+=t(e[o],o,e,t)||"";return n}function W(e,t,n,r){switch(e.type){case"@layer":if(e.children.length)break;case"@import":case H:return e.return=e.return||e.value;case z:return"";case G:return e.return=e.value+"{"+V(e.children,r)+"}";case $:e.value=e.props.join(",")}return p(n=V(e.children,r))?e.return=e.value+"{"+n+"}":""}function U(e){return B(q("",null,null,null,[""],e=P(e),0,[0],e))}function q(e,t,n,r,o,i,l,s,f){for(var h=0,m=0,A=l,b=0,v=0,y=0,w=1,C=1,S=1,R=0,M="",P=o,B=i,D=r,F=M;C;)switch(y=R,R=E()){case 40:if(108!=y&&58==d(F,A-1)){-1!=u(F+=c(_(R),"&","&\f"),"&\f")&&(S=-1);break}case 34:case 39:case 91:F+=_(R);break;case 9:case 10:case 13:case 32:F+=T(y);break;case 92:F+=O(k()-1,7);continue;case 47:switch(I()){case 42:case 47:g(K(N(E(),k()),t,n),f);break;default:F+="/"}break;case 123*w:s[h++]=p(F)*S;case 125*w:case 59:case 0:switch(R){case 0:case 125:C=0;case 59+m:-1==S&&(F=c(F,/\f/g,"")),v>0&&p(F)-A&&g(v>32?J(F+";",r,n,A-1):J(c(F," ","")+";",r,n,A-2),f);break;case 59:F+=";";default:if(g(D=Y(F,t,n,h,m,o,s,M,P=[],B=[],A),i),123===R)if(0===m)q(F,t,D,D,P,i,A,s,B);else switch(99===b&&110===d(F,3)?100:b){case 100:case 108:case 109:case 115:q(e,D,D,r&&g(Y(e,D,D,0,0,o,s,M,o,P=[],A),B),o,B,A,s,r?P:B);break;default:q(F,D,D,D,[""],B,0,s,B)}}h=m=v=0,w=S=1,M=F="",A=l;break;case 58:A=1+p(F),v=y;default:if(w<1)if(123==R)--w;else if(125==R&&0==w++&&125==x())continue;switch(F+=a(R),R*w){case 38:S=m>0?1:(F+="\f",-1);break;case 44:s[h++]=(p(F)-1)*S,S=1;break;case 64:45===I()&&(F+=_(E())),b=I(),m=A=p(M=F+=L(k())),R++;break;case 45:45===y&&2==p(F)&&(w=0)}}return i}function Y(e,t,n,r,o,a,l,u,d,p,g){for(var m=o-1,A=0===o?a:[""],b=h(A),v=0,y=0,w=0;v<r;++v)for(var S=0,x=f(e,m+1,m=i(y=l[v])),E=e;S<b;++S)(E=s(y>0?A[S]+" "+x:c(x,/&\f/g,A[S])))&&(d[w++]=E);return C(e,t,n,0===o?$:u,d,p,g)}function K(e,t,n){return C(e,t,n,z,a(y),f(e,2,-2),0)}function J(e,t,n,r){return C(e,t,n,H,f(e,0,r),f(e,r+1,-1),r)}var X=function(e,t,n){for(var r=0,o=0;r=o,o=I(),38===r&&12===o&&(t[n]=1),!M(o);)E();return R(e,v)},Z=new WeakMap,ee=function(e){if("rule"===e.type&&e.parent&&!(e.length<1)){for(var t=e.value,n=e.parent,r=e.column===n.column&&e.line===n.line;"rule"!==n.type;)if(!(n=n.parent))return;if((1!==e.props.length||58===t.charCodeAt(0)||Z.get(n))&&!r){Z.set(e,!0);for(var o=[],i=function(e,t){return B(function(e,t){var n=-1,r=44;do{switch(M(r)){case 0:38===r&&12===I()&&(t[n]=1),e[n]+=X(v-1,t,n);break;case 2:e[n]+=_(r);break;case 4:if(44===r){e[++n]=58===I()?"&\f":"",t[n]=e[n].length;break}default:e[n]+=a(r)}}while(r=E());return e}(P(e),t))}(t,o),l=n.props,s=0,c=0;s<i.length;s++)for(var u=0;u<l.length;u++,c++)e.props[c]=o[s]?i[s].replace(/&\f/g,l[u]):l[u]+" "+i[s]}}},te=function(e){if("decl"===e.type){var t=e.value;108===t.charCodeAt(0)&&98===t.charCodeAt(2)&&(e.return="",e.value="")}};function ne(e,t){switch(function(e,t){return 45^d(e,0)?(((t<<2^d(e,0))<<2^d(e,1))<<2^d(e,2))<<2^d(e,3):0}(e,t)){case 5103:return j+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return j+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return j+e+Q+e+F+e+e;case 6828:case 4268:return j+e+F+e+e;case 6165:return j+e+F+"flex-"+e+e;case 5187:return j+e+c(e,/(\w+).+(:[^]+)/,j+"box-$1$2"+F+"flex-$1$2")+e;case 5443:return j+e+F+"flex-item-"+c(e,/flex-|-self/,"")+e;case 4675:return j+e+F+"flex-line-pack"+c(e,/align-content|flex-|-self/,"")+e;case 5548:return j+e+F+c(e,"shrink","negative")+e;case 5292:return j+e+F+c(e,"basis","preferred-size")+e;case 6060:return j+"box-"+c(e,"-grow","")+j+e+F+c(e,"grow","positive")+e;case 4554:return j+c(e,/([^-])(transform)/g,"$1"+j+"$2")+e;case 6187:return c(c(c(e,/(zoom-|grab)/,j+"$1"),/(image-set)/,j+"$1"),e,"")+e;case 5495:case 3959:return c(e,/(image-set\([^]*)/,j+"$1$`$1");case 4968:return c(c(e,/(.+:)(flex-)?(.*)/,j+"box-pack:$3"+F+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+j+e+e;case 4095:case 3583:case 4068:case 2532:return c(e,/(.+)-inline(.+)/,j+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(p(e)-1-t>6)switch(d(e,t+1)){case 109:if(45!==d(e,t+4))break;case 102:return c(e,/(.+:)(.+)-([^]+)/,"$1"+j+"$2-$3$1"+Q+(108==d(e,t+3)?"$3":"$2-$3"))+e;case 115:return~u(e,"stretch")?ne(c(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(115!==d(e,t+1))break;case 6444:switch(d(e,p(e)-3-(~u(e,"!important")&&10))){case 107:return c(e,":",":"+j)+e;case 101:return c(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+j+(45===d(e,14)?"inline-":"")+"box$3$1"+j+"$2$3$1"+F+"$2box$3")+e}break;case 5936:switch(d(e,t+11)){case 114:return j+e+F+c(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return j+e+F+c(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return j+e+F+c(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return j+e+F+e+e}return e}var re=[function(e,t,n,r){if(e.length>-1&&!e.return)switch(e.type){case H:e.return=ne(e.value,e.length);break;case G:return V([S(e,{value:c(e.value,"@","@"+j)})],r);case $:if(e.length)return function(e,t){return e.map(t).join("")}(e.props,function(t){switch(function(e){return(e=/(::plac\w+|:read-\w+)/.exec(e))?e[0]:e}(t)){case":read-only":case":read-write":return V([S(e,{props:[c(t,/:(read-\w+)/,":-moz-$1")]})],r);case"::placeholder":return V([S(e,{props:[c(t,/:(plac\w+)/,":"+j+"input-$1")]}),S(e,{props:[c(t,/:(plac\w+)/,":-moz-$1")]}),S(e,{props:[c(t,/:(plac\w+)/,F+"input-$1")]})],r)}return""})}}],oe=function(e){var t=e.key;if("css"===t){var n=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(n,function(e){-1!==e.getAttribute("data-emotion").indexOf(" ")&&(document.head.appendChild(e),e.setAttribute("data-s",""))})}var r,i,a=e.stylisPlugins||re,l={},s=[];r=e.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+t+' "]'),function(e){for(var t=e.getAttribute("data-emotion").split(" "),n=1;n<t.length;n++)l[t[n]]=!0;s.push(e)});var c,u,d,f,p=[W,(f=function(e){c.insert(e)},function(e){e.root||(e=e.return)&&f(e)})],g=(u=[ee,te].concat(a,p),d=h(u),function(e,t,n,r){for(var o="",i=0;i<d;i++)o+=u[i](e,t,n,r)||"";return o});i=function(e,t,n,r){c=n,V(U(e?e+"{"+t.styles+"}":t.styles),g),r&&(m.inserted[t.name]=!0)};var m={key:t,sheet:new o({key:t,container:r,nonce:e.nonce,speedy:e.speedy,prepend:e.prepend,insertionPoint:e.insertionPoint}),nonce:e.nonce,inserted:l,registered:{},insert:i};return m.sheet.hydrate(s),m},ie=n(966),ae=n(2855),le=n(6126),se=r.createContext("undefined"!=typeof HTMLElement?oe({key:"css"}):null),ce=(se.Provider,function(){return(0,r.useContext)(se)}),ue=function(e){return(0,r.forwardRef)(function(t,n){var o=(0,r.useContext)(se);return e(t,o,n)})},de=r.createContext({}),fe={}.hasOwnProperty,pe="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",he=function(e,t){var n={};for(var r in t)fe.call(t,r)&&(n[r]=t[r]);return n[pe]=e,n},ge=function(e){var t=e.cache,n=e.serialized,r=e.isStringTag;return(0,ie.SF)(t,n,r),(0,le.s)(function(){return(0,ie.sk)(t,n,r)}),null},me=ue(function(e,t,n){var o=e.css;"string"==typeof o&&void 0!==t.registered[o]&&(o=t.registered[o]);var i=e[pe],a=[o],l="";"string"==typeof e.className?l=(0,ie.Rk)(t.registered,a,e.className):null!=e.className&&(l=e.className+" ");var s=(0,ae.J)(a,void 0,r.useContext(de));l+=t.key+"-"+s.name;var c={};for(var u in e)fe.call(e,u)&&"css"!==u&&u!==pe&&(c[u]=e[u]);return c.className=l,n&&(c.ref=n),r.createElement(r.Fragment,null,r.createElement(ge,{cache:t,serialized:s,isStringTag:"string"==typeof i}),r.createElement(i,c))})},553(e,t,n){"use strict";n.d(t,{AH:()=>f,i7:()=>p,mL:()=>d});var r,o,i=n(1733),a=n(405),l=n(966),s=n(6126),c=n(2855),u=(n(4674),function(e,t){var n=arguments;if(null==t||!i.h.call(t,"css"))return a.createElement.apply(void 0,n);var r=n.length,o=new Array(r);o[0]=i.E,o[1]=(0,i.c)(e,t);for(var l=2;l<r;l++)o[l]=n[l];return a.createElement.apply(null,o)});r=u||(u={}),o||(o=r.JSX||(r.JSX={}));var d=(0,i.w)(function(e,t){var n=e.styles,r=(0,c.J)([n],void 0,a.useContext(i.T)),o=a.useRef();return(0,s.i)(function(){var e=t.key+"-global",n=new t.sheet.constructor({key:e,nonce:t.sheet.nonce,container:t.sheet.container,speedy:t.sheet.isSpeedy}),i=!1,a=document.querySelector('style[data-emotion="'+e+" "+r.name+'"]');return t.sheet.tags.length&&(n.before=t.sheet.tags[0]),null!==a&&(i=!0,a.setAttribute("data-emotion",e),n.hydrate([a])),o.current=[n,i],function(){n.flush()}},[t]),(0,s.i)(function(){var e=o.current,n=e[0];if(e[1])e[1]=!1;else{if(void 0!==r.next&&(0,l.sk)(t,r.next,!0),n.tags.length){var i=n.tags[n.tags.length-1].nextElementSibling;n.before=i,n.flush()}t.insert("",r,n,!1)}},[t,r.name]),null});function f(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return(0,c.J)(t)}function p(){var e=f.apply(void 0,arguments),t="animation-"+e.name;return{name:t,styles:"@keyframes "+t+"{"+e.styles+"}",anim:1,toString:function(){return"_EMO_"+this.name+"_"+this.styles+"_EMO_"}}}},2855(e,t,n){"use strict";n.d(t,{J:()=>h});var r={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},o=n(8371),i=/[A-Z]|^ms/g,a=/_EMO_([^_]+?)_([^]*?)_EMO_/g,l=function(e){return 45===e.charCodeAt(1)},s=function(e){return null!=e&&"boolean"!=typeof e},c=(0,o.A)(function(e){return l(e)?e:e.replace(i,"-$&").toLowerCase()}),u=function(e,t){switch(e){case"animation":case"animationName":if("string"==typeof t)return t.replace(a,function(e,t,n){return f={name:t,styles:n,next:f},t})}return 1===r[e]||l(e)||"number"!=typeof t||0===t?t:t+"px"};function d(e,t,n){if(null==n)return"";var r=n;if(void 0!==r.__emotion_styles)return r;switch(typeof n){case"boolean":return"";case"object":var o=n;if(1===o.anim)return f={name:o.name,styles:o.styles,next:f},o.name;var i=n;if(void 0!==i.styles){var a=i.next;if(void 0!==a)for(;void 0!==a;)f={name:a.name,styles:a.styles,next:f},a=a.next;return i.styles+";"}return function(e,t,n){var r="";if(Array.isArray(n))for(var o=0;o<n.length;o++)r+=d(e,t,n[o])+";";else for(var i in n){var a=n[i];if("object"!=typeof a){var l=a;null!=t&&void 0!==t[l]?r+=i+"{"+t[l]+"}":s(l)&&(r+=c(i)+":"+u(i,l)+";")}else if(!Array.isArray(a)||"string"!=typeof a[0]||null!=t&&void 0!==t[a[0]]){var f=d(e,t,a);switch(i){case"animation":case"animationName":r+=c(i)+":"+f+";";break;default:r+=i+"{"+f+"}"}}else for(var p=0;p<a.length;p++)s(a[p])&&(r+=c(i)+":"+u(i,a[p])+";")}return r}(e,t,n);case"function":if(void 0!==e){var l=f,p=n(e);return f=l,d(e,t,p)}}var h=n;if(null==t)return h;var g=t[h];return void 0!==g?g:h}var f,p=/label:\s*([^\s;{]+)\s*(;|$)/g;function h(e,t,n){if(1===e.length&&"object"==typeof e[0]&&null!==e[0]&&void 0!==e[0].styles)return e[0];var r=!0,o="";f=void 0;var i=e[0];null==i||void 0===i.raw?(r=!1,o+=d(n,t,i)):o+=i[0];for(var a=1;a<e.length;a++)o+=d(n,t,e[a]),r&&(o+=i[a]);p.lastIndex=0;for(var l,s="";null!==(l=p.exec(o));)s+="-"+l[1];var c=function(e){for(var t,n=0,r=0,o=e.length;o>=4;++r,o-=4)t=1540483477*(65535&(t=255&e.charCodeAt(r)|(255&e.charCodeAt(++r))<<8|(255&e.charCodeAt(++r))<<16|(255&e.charCodeAt(++r))<<24))+(59797*(t>>>16)<<16),n=1540483477*(65535&(t^=t>>>24))+(59797*(t>>>16)<<16)^1540483477*(65535&n)+(59797*(n>>>16)<<16);switch(o){case 3:n^=(255&e.charCodeAt(r+2))<<16;case 2:n^=(255&e.charCodeAt(r+1))<<8;case 1:n=1540483477*(65535&(n^=255&e.charCodeAt(r)))+(59797*(n>>>16)<<16)}return(((n=1540483477*(65535&(n^=n>>>13))+(59797*(n>>>16)<<16))^n>>>15)>>>0).toString(36)}(o)+s;return{name:c,styles:o,next:f}}},6126(e,t,n){"use strict";var r;n.d(t,{i:()=>l,s:()=>a});var o=n(405),i=!!(r||(r=n.t(o,2))).useInsertionEffect&&(r||(r=n.t(o,2))).useInsertionEffect,a=i||function(e){return e()},l=i||o.useLayoutEffect},966(e,t,n){"use strict";function r(e,t,n){var r="";return n.split(" ").forEach(function(n){void 0!==e[n]?t.push(e[n]+";"):n&&(r+=n+" ")}),r}n.d(t,{Rk:()=>r,SF:()=>o,sk:()=>i});var o=function(e,t,n){var r=e.key+"-"+t.name;!1===n&&void 0===e.registered[r]&&(e.registered[r]=t.styles)},i=function(e,t,n){o(e,t,n);var r=e.key+"-"+t.name;if(void 0===e.inserted[t.name]){var i=t;do{e.insert(t===i?"."+r:"",i,e.sheet,!0),i=i.next}while(void 0!==i)}}},7085(e,t,n){"use strict";function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function o(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function i(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?o(Object(n),!0).forEach(function(t){a(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):o(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function a(e,t,n){return(t=d(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e){return l="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},l(e)}function s(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function c(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,d(r.key),r)}}function u(e,t,n){return t&&c(e.prototype,t),n&&c(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function d(e){var t=function(e){if("object"!=l(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=l(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==l(t)?t:t+""}function f(e){return e?"string"==typeof e?e:e+"":e}function p(e,t){for(var n=0,r=Object.keys(t);n<r.length;n++){var o=r[n];e=e.replace(new RegExp("\\{"+o+"\\}","gi"),t[o])}return e}function h(e){if(!e)throw new Error("cannot create a random attribute name for an undefined object");var t="";do{t="";for(var n=0;n<12;n++)t+="ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz"[Math.floor(51*Math.random())]}while(e[t]);return t}function g(e){var t={alphabetic:"alphabetic",hanging:"hanging",top:"text-before-edge",bottom:"text-after-edge",middle:"central"};return t[e]||t.alphabetic}n.r(t),n.d(t,{Context:()=>y});var m=function(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:10,n={},r=e.split(","),o=0;o<r.length;o+=2){var i="&"+r[o+1]+";",a=parseInt(r[o],t);n[i]="&#"+a+";"}return n["\\xa0"]=" ",n}("50,nbsp,51,iexcl,52,cent,53,pound,54,curren,55,yen,56,brvbar,57,sect,58,uml,59,copy,5a,ordf,5b,laquo,5c,not,5d,shy,5e,reg,5f,macr,5g,deg,5h,plusmn,5i,sup2,5j,sup3,5k,acute,5l,micro,5m,para,5n,middot,5o,cedil,5p,sup1,5q,ordm,5r,raquo,5s,frac14,5t,frac12,5u,frac34,5v,iquest,60,Agrave,61,Aacute,62,Acirc,63,Atilde,64,Auml,65,Aring,66,AElig,67,Ccedil,68,Egrave,69,Eacute,6a,Ecirc,6b,Euml,6c,Igrave,6d,Iacute,6e,Icirc,6f,Iuml,6g,ETH,6h,Ntilde,6i,Ograve,6j,Oacute,6k,Ocirc,6l,Otilde,6m,Ouml,6n,times,6o,Oslash,6p,Ugrave,6q,Uacute,6r,Ucirc,6s,Uuml,6t,Yacute,6u,THORN,6v,szlig,70,agrave,71,aacute,72,acirc,73,atilde,74,auml,75,aring,76,aelig,77,ccedil,78,egrave,79,eacute,7a,ecirc,7b,euml,7c,igrave,7d,iacute,7e,icirc,7f,iuml,7g,eth,7h,ntilde,7i,ograve,7j,oacute,7k,ocirc,7l,otilde,7m,ouml,7n,divide,7o,oslash,7p,ugrave,7q,uacute,7r,ucirc,7s,uuml,7t,yacute,7u,thorn,7v,yuml,ci,fnof,sh,Alpha,si,Beta,sj,Gamma,sk,Delta,sl,Epsilon,sm,Zeta,sn,Eta,so,Theta,sp,Iota,sq,Kappa,sr,Lambda,ss,Mu,st,Nu,su,Xi,sv,Omicron,t0,Pi,t1,Rho,t3,Sigma,t4,Tau,t5,Upsilon,t6,Phi,t7,Chi,t8,Psi,t9,Omega,th,alpha,ti,beta,tj,gamma,tk,delta,tl,epsilon,tm,zeta,tn,eta,to,theta,tp,iota,tq,kappa,tr,lambda,ts,mu,tt,nu,tu,xi,tv,omicron,u0,pi,u1,rho,u2,sigmaf,u3,sigma,u4,tau,u5,upsilon,u6,phi,u7,chi,u8,psi,u9,omega,uh,thetasym,ui,upsih,um,piv,812,bull,816,hellip,81i,prime,81j,Prime,81u,oline,824,frasl,88o,weierp,88h,image,88s,real,892,trade,89l,alefsym,8cg,larr,8ch,uarr,8ci,rarr,8cj,darr,8ck,harr,8dl,crarr,8eg,lArr,8eh,uArr,8ei,rArr,8ej,dArr,8ek,hArr,8g0,forall,8g2,part,8g3,exist,8g5,empty,8g7,nabla,8g8,isin,8g9,notin,8gb,ni,8gf,prod,8gh,sum,8gi,minus,8gn,lowast,8gq,radic,8gt,prop,8gu,infin,8h0,ang,8h7,and,8h8,or,8h9,cap,8ha,cup,8hb,int,8hk,there4,8hs,sim,8i5,cong,8i8,asymp,8j0,ne,8j1,equiv,8j4,le,8j5,ge,8k2,sub,8k3,sup,8k4,nsub,8k6,sube,8k7,supe,8kl,oplus,8kn,otimes,8l5,perp,8m5,sdot,8o8,lceil,8o9,rceil,8oa,lfloor,8ob,rfloor,8p9,lang,8pa,rang,9ea,loz,9j0,spades,9j3,clubs,9j5,hearts,9j6,diams,ai,OElig,aj,oelig,b0,Scaron,b1,scaron,bo,Yuml,m6,circ,ms,tilde,802,ensp,803,emsp,809,thinsp,80c,zwnj,80d,zwj,80e,lrm,80f,rlm,80j,ndash,80k,mdash,80o,lsquo,80p,rsquo,80q,sbquo,80s,ldquo,80t,rdquo,80u,bdquo,810,dagger,811,Dagger,81g,permil,81p,lsaquo,81q,rsaquo,85c,euro",32),A={strokeStyle:{svgAttr:"stroke",canvas:"#000000",svg:"none",apply:"stroke"},fillStyle:{svgAttr:"fill",canvas:"#000000",svg:null,apply:"fill"},lineCap:{svgAttr:"stroke-linecap",canvas:"butt",svg:"butt",apply:"stroke"},lineJoin:{svgAttr:"stroke-linejoin",canvas:"miter",svg:"miter",apply:"stroke"},miterLimit:{svgAttr:"stroke-miterlimit",canvas:10,svg:4,apply:"stroke"},lineWidth:{svgAttr:"stroke-width",canvas:1,svg:1,apply:"stroke"},globalAlpha:{svgAttr:"opacity",canvas:1,svg:1,apply:"fill stroke"},font:{canvas:"10px sans-serif"},shadowColor:{canvas:"#000000"},shadowOffsetX:{canvas:0},shadowOffsetY:{canvas:0},shadowBlur:{canvas:0},textAlign:{canvas:"start"},textBaseline:{canvas:"alphabetic"},lineDash:{svgAttr:"stroke-dasharray",canvas:[],svg:null,apply:"stroke"}},b=function(){return u(function e(t,n){s(this,e),this.__root=t,this.__ctx=n},[{key:"addColorStop",value:function(e,t){var n=this.__ctx.__createElement("stop");if(n.setAttribute("offset",String(e)),f(t).includes("rgba")){var r=/rgba\(\s*(\d*\.?\d+)\s*,\s*(\d*\.?\d+)\s*,\s*(\d*\.?\d+)\s*,\s*(\d?\.?\d*)\s*\)/gi.exec(t);r&&(n.setAttribute("stop-color",p("rgb({r},{g},{b})",{r:r[1],g:r[2],b:r[3]})),n.setAttribute("stop-opacity",r[4]))}else n.setAttribute("stop-color",f(t));this.__root.appendChild(n)}}])}(),v=u(function e(t,n){s(this,e),this.__root=t,this.__ctx=n}),y=function(){return u(function e(t,n){s(this,e);var r,o={width:500,height:500,enableMirroring:!1};r="number"==typeof t&&void 0!==n?i(i({},o),{},{width:t,height:n}):t&&"object"===l(t)?t:o,this.width=r.width||o.width,this.height=r.height||o.height,this.enableMirroring=void 0!==r.enableMirroring?r.enableMirroring:o.enableMirroring,this.canvas=this,this.__document=r.document||document,r.ctx?this.__ctx=r.ctx:(this.__canvas=this.__document.createElement("canvas"),this.__ctx=this.__canvas.getContext("2d")),this.__setDefaultStyles(),this.__styleStack=[this.__getStyleState()],this.__groupStack=[],this.__root=this.__document.createElementNS("http://www.w3.org/2000/svg","svg"),this.__root.setAttribute("version","1.1"),this.__root.setAttribute("xmlns","http://www.w3.org/2000/svg"),this.__root.setAttributeNS("http://www.w3.org/2000/xmlns/","xmlns:xlink","http://www.w3.org/1999/xlink"),this.__root.setAttribute("width",String(this.width)),this.__root.setAttribute("height",String(this.height)),this.__ids={},this.__defs=this.__document.createElementNS("http://www.w3.org/2000/svg","defs"),this.__root.appendChild(this.__defs),this.__currentElement=this.__document.createElementNS("http://www.w3.org/2000/svg","g"),this.__root.appendChild(this.__currentElement),this.__currentDefaultPath="",this.__currentPosition={},this.__transformMatrix=new DOMMatrix,this.resetTransform(),this.__options=r,this.__id=Math.random().toString(16).substring(2,8)},[{key:"__createElement",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0,r=this.__document.createElementNS("http://www.w3.org/2000/svg",e);n&&(r.setAttribute("fill","none"),r.setAttribute("stroke","none"));for(var o=0,i=Object.keys(t);o<i.length;o++){var a=i[o];r.setAttribute(a,t[a])}return r}},{key:"__setDefaultStyles",value:function(){for(var e=0,t=Object.keys(A);e<t.length;e++){var n=t[e];this[n]=A[n].canvas}}},{key:"__applyStyleState",value:function(e){for(var t=0,n=Object.keys(e);t<n.length;t++){var r=n[t];this[r]=e[r]}}},{key:"__getStyleState",value:function(){for(var e={},t=0,n=Object.keys(A);t<n.length;t++){var r=n[t];e[r]=this[r]}return e}},{key:"__applyTransformation",value:function(e,t){var n=t||this.getTransform(),r=n.a,o=n.b,i=n.c,a=n.d,l=n.e,s=n.f;e.setAttribute("transform","matrix(".concat(r," ").concat(o," ").concat(i," ").concat(a," ").concat(l," ").concat(s,")"))}},{key:"__applyStyleToCurrentElement",value:function(e){var t=this.__currentElement,n=this.__currentElementsToStyle;if(n){t.setAttribute(e,""),t=n.element;var o,i=function(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return r(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var o=0,i=function(){};return{s:i,n:function(){return o>=e.length?{done:!0}:{done:!1,value:e[o++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,l=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return l=e.done,e},e:function(e){s=!0,a=e},f:function(){try{l||null==n.return||n.return()}finally{if(s)throw a}}}}(n.children);try{for(i.s();!(o=i.n()).done;)o.value.setAttribute(e,"")}catch(e){i.e(e)}finally{i.f()}}for(var a=0,l=Object.keys(A);a<l.length;a++){var s=l[a],c=A[s],u=this[s];if(c.apply)if(u instanceof v){if(u.__ctx)for(var d=0,f=Array.from(u.__ctx.__defs.childNodes);d<f.length;d++){var h=f[d],g=h.getAttribute("id");g&&(this.__ids[g]=g,this.__defs.appendChild(h))}t.setAttribute(c.apply,p("url(#{id})",{id:u.__root.getAttribute("id")}))}else if(u instanceof b)t.setAttribute(c.apply,p("url(#{id})",{id:u.__root.getAttribute("id")}));else if(c.apply.includes(e)&&c.svg!==u)if(("stroke"===c.svgAttr||"fill"===c.svgAttr)&&u&&u.includes("rgba")){var m=/rgba\(\s*(\d*\.?\d+)\s*,\s*(\d*\.?\d+)\s*,\s*(\d*\.?\d+)\s*,\s*(\d?\.?\d*)\s*\)/gi.exec(u);if(m){t.setAttribute(c.svgAttr,p("rgb({r},{g},{b})",{r:m[1],g:m[2],b:m[3]}));var y=Number(m[4]),w=this.globalAlpha;null!=w&&(y*=w),t.setAttribute(c.svgAttr+"-opacity",String(y))}}else{var C=c.svgAttr,S=u;if("globalAlpha"===s){if(C=e+"-"+c.svgAttr,t.getAttribute(C))continue}else if("lineWidth"===s){var x=this.__getTransformScale();S=u*Math.max(x.x,x.y)}t.setAttribute(C,S)}}}},{key:"__closestGroupOrSvg",value:function(e){return"g"===(e=e||this.__currentElement).nodeName||"svg"===e.nodeName?e:this.__closestGroupOrSvg(e.parentNode)}},{key:"getSerializedSvg",value:function(e){var t=(new XMLSerializer).serializeToString(this.__root);if(/xmlns="http:\/\/www\.w3\.org\/2000\/svg".+xmlns="http:\/\/www\.w3\.org\/2000\/svg/gi.test(t)&&(t=t.replace('xmlns="http://www.w3.org/2000/svg','xmlns:xlink="http://www.w3.org/1999/xlink')),e)for(var n=0,r=Object.keys(m);n<r.length;n++){var o=r[n],i=new RegExp(o,"gi");i.test(t)&&(t=t.replace(i,m[o]))}return t}},{key:"getSvg",value:function(){return this.__root}},{key:"save",value:function(){var e=this.__createElement("g"),t=this.__closestGroupOrSvg();this.__groupStack.push(t),t.appendChild(e),this.__currentElement=e;var n=this.__getStyleState();this.__styleStack.push(n),this.__transformMatrixStack||(this.__transformMatrixStack=[]),this.__transformMatrixStack.push(this.getTransform())}},{key:"restore",value:function(){this.__currentElement=this.__groupStack.pop(),this.__currentElementsToStyle=void 0,this.__currentElement||(this.__currentElement=this.__root.childNodes[1]);var e=this.__styleStack.pop();this.__applyStyleState(e),this.__transformMatrixStack&&this.__transformMatrixStack.length>0&&this.setTransform(this.__transformMatrixStack.pop())}},{key:"beginPath",value:function(){this.__currentDefaultPath="",this.__currentPosition={};var e=this.__createElement("path",{},!0);this.__closestGroupOrSvg().appendChild(e),this.__currentElement=e}},{key:"__applyCurrentDefaultPath",value:function(){var e=this.__currentElement;"path"===e.nodeName&&e.setAttribute("d",this.__currentDefaultPath)}},{key:"__addPathCommand",value:function(e){this.__currentDefaultPath+=" ",this.__currentDefaultPath+=e}},{key:"moveTo",value:function(e,t){"path"!==this.__currentElement.nodeName&&this.beginPath(),this.__currentPosition={x:e,y:t},this.__addPathCommand(p("M {x} {y}",{x:this.__matrixTransform(e,t).x,y:this.__matrixTransform(e,t).y}))}},{key:"closePath",value:function(){this.__currentDefaultPath&&this.__addPathCommand("Z")}},{key:"lineTo",value:function(e,t){this.__currentPosition={x:e,y:t},this.__currentDefaultPath.includes("M")?this.__addPathCommand(p("L {x} {y}",{x:this.__matrixTransform(e,t).x,y:this.__matrixTransform(e,t).y})):this.__addPathCommand(p("M {x} {y}",{x:this.__matrixTransform(e,t).x,y:this.__matrixTransform(e,t).y}))}},{key:"bezierCurveTo",value:function(e,t,n,r,o,i){this.__currentPosition={x:o,y:i},this.__addPathCommand(p("C {cp1x} {cp1y} {cp2x} {cp2y} {x} {y}",{cp1x:this.__matrixTransform(e,t).x,cp1y:this.__matrixTransform(e,t).y,cp2x:this.__matrixTransform(n,r).x,cp2y:this.__matrixTransform(n,r).y,x:this.__matrixTransform(o,i).x,y:this.__matrixTransform(o,i).y}))}},{key:"quadraticCurveTo",value:function(e,t,n,r){this.__currentPosition={x:n,y:r},this.__addPathCommand(p("Q {cpx} {cpy} {x} {y}",{cpx:this.__matrixTransform(e,t).x,cpy:this.__matrixTransform(e,t).y,x:this.__matrixTransform(n,r).x,y:this.__matrixTransform(n,r).y}))}},{key:"stroke",value:function(){"path"===this.__currentElement.nodeName&&this.__currentElement.setAttribute("paint-order","fill stroke markers"),this.__applyCurrentDefaultPath(),this.__applyStyleToCurrentElement("stroke")}},{key:"fill",value:function(){"path"===this.__currentElement.nodeName&&this.__currentElement.setAttribute("paint-order","stroke fill markers"),this.__applyCurrentDefaultPath(),this.__applyStyleToCurrentElement("fill")}},{key:"rect",value:function(e,t,n,r){"path"!==this.__currentElement.nodeName&&this.beginPath(),this.moveTo(e,t),this.lineTo(e+n,t),this.lineTo(e+n,t+r),this.lineTo(e,t+r),this.lineTo(e,t),this.closePath()}},{key:"__clearCanvas",value:function(){var e=this.__root.childNodes[1];this.__root.removeChild(e),this.__currentElement=this.__document.createElementNS("http://www.w3.org/2000/svg","g"),this.__root.appendChild(this.__currentElement),this.__groupStack=[]}},{key:"fillRect",value:function(e,t,n,r){var o=this.getTransform(),i=o.a,a=o.b,l=o.c,s=o.d,c=o.e,u=o.f;JSON.stringify([i,a,l,s,c,u])===JSON.stringify([1,0,0,1,0,0])&&0===e&&0===t&&n===this.width&&r===this.height&&this.__clearCanvas();var d=this.__createElement("rect",{x:e,y:t,width:n,height:r},!0);this.__closestGroupOrSvg().appendChild(d),this.__currentElement=d,this.__applyTransformation(d),this.__applyStyleToCurrentElement("fill")}},{key:"strokeRect",value:function(e,t,n,r){var o=this.__createElement("rect",{x:e,y:t,width:n,height:r},!0);this.__closestGroupOrSvg().appendChild(o),this.__currentElement=o,this.__applyTransformation(o),this.__applyStyleToCurrentElement("stroke")}},{key:"clearRect",value:function(e,t,n,r){var o=this.getTransform(),i=o.a,a=o.b,l=o.c,s=o.d,c=o.e,u=o.f;if(JSON.stringify([i,a,l,s,c,u])!==JSON.stringify([1,0,0,1,0,0])||0!==e||0!==t||n!==this.width||r!==this.height){var d=this.__createElement("rect",{x:e,y:t,width:n,height:r,fill:"#FFFFFF"},!0);this.__applyTransformation(d),this.__closestGroupOrSvg().appendChild(d)}else this.__clearCanvas()}},{key:"createLinearGradient",value:function(e,t,n,r){var o=this.__createElement("linearGradient",{id:h(this.__ids),x1:e+"px",x2:n+"px",y1:t+"px",y2:r+"px",gradientUnits:"userSpaceOnUse"});return this.__defs.appendChild(o),new b(o,this)}},{key:"createRadialGradient",value:function(e,t,n,r,o,i){var a=this.__createElement("radialGradient",{id:h(this.__ids),cx:r+"px",cy:o+"px",r:i+"px",fx:e+"px",fy:t+"px",gradientUnits:"userSpaceOnUse"});return this.__defs.appendChild(a),new b(a,this)}},{key:"__applyText",value:function(e,t,n,r){var o=document.createElement("span");o.setAttribute("style","font:"+this.font);var i,a,l=o.style,s=this.__closestGroupOrSvg(),c=this.__createElement("text",{"font-family":l.fontFamily,"font-size":l.fontSize,"font-style":l.fontStyle,"font-weight":l.fontWeight,"text-decoration":this.__fontUnderline,x:t,y:n,"text-anchor":(i=this.textAlign,a={left:"start",right:"end",center:"middle",start:"start",end:"end"},a[i]||a.start),"dominant-baseline":g(this.textBaseline)},!0);c.appendChild(this.__document.createTextNode(e)),this.__currentElement=c,this.__applyTransformation(c),this.__applyStyleToCurrentElement(r);var u=c;if(this.__fontHref){var d=this.__createElement("a");d.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",this.__fontHref),d.appendChild(c),u=d}s.appendChild(u)}},{key:"fillText",value:function(e,t,n){this.__applyText(e,t,n,"fill")}},{key:"strokeText",value:function(e,t,n){this.__applyText(e,t,n,"stroke")}},{key:"measureText",value:function(e){return this.__ctx.font=this.font,this.__ctx.measureText(e)}},{key:"arc",value:function(e,t,n,r,o,i){if(r!==o){(r%=2*Math.PI)==(o%=2*Math.PI)&&(o=(o+2*Math.PI-.001*(i?-1:1))%(2*Math.PI));var a,l=e+n*Math.cos(o),s=t+n*Math.sin(o),c=e+n*Math.cos(r),u=t+n*Math.sin(r),d=i?0:1,f=o-r;f<0&&(f+=2*Math.PI),a=i?f>Math.PI?0:1:f>Math.PI?1:0;var h=Math.hypot(this.__transformMatrix.a,this.__transformMatrix.b),g=Math.hypot(this.__transformMatrix.c,this.__transformMatrix.d);this.lineTo(c,u),this.__addPathCommand(p("A {rx} {ry} {xAxisRotation} {largeArcFlag} {sweepFlag} {endX} {endY}",{rx:n*h,ry:n*g,xAxisRotation:0,largeArcFlag:a,sweepFlag:d,endX:this.__matrixTransform(l,s).x,endY:this.__matrixTransform(l,s).y})),this.__currentPosition={x:l,y:s}}}},{key:"clip",value:function(){var e=this.__closestGroupOrSvg(),t=this.__createElement("clipPath"),n=h(this.__ids),r=this.__createElement("g");this.__applyCurrentDefaultPath(),e.removeChild(this.__currentElement),t.setAttribute("id",n),t.appendChild(this.__currentElement),this.__defs.appendChild(t),e.setAttribute("clip-path",p("url(#{id})",{id:n})),e.appendChild(r),this.__currentElement=r}},{key:"setLineDash",value:function(e){e&&e.length>0?this.lineDash=e.join(","):this.lineDash=null}},{key:"setTransform",value:function(e,t,n,r,o,i){e instanceof DOMMatrix?this.__transformMatrix=new DOMMatrix([e.a,e.b,e.c,e.d,e.e,e.f]):this.__transformMatrix=new DOMMatrix([e,t,n,r,o,i])}},{key:"getTransform",value:function(){var e=this.__transformMatrix,t=e.a,n=e.b,r=e.c,o=e.d,i=e.e,a=e.f;return new DOMMatrix([t,n,r,o,i,a])}},{key:"resetTransform",value:function(){this.setTransform(1,0,0,1,0,0)}},{key:"scale",value:function(e,t){if(void 0===t&&(t=e),!isNaN(e)&&!isNaN(t)&&isFinite(e)&&isFinite(t)){var n=this.getTransform().scale(e,t);this.setTransform(n)}}},{key:"rotate",value:function(e){var t=this.getTransform().multiply(new DOMMatrix([Math.cos(e),Math.sin(e),-Math.sin(e),Math.cos(e),0,0]));this.setTransform(t)}},{key:"translate",value:function(e,t){var n=this.getTransform().translate(e,t);this.setTransform(n)}},{key:"transform",value:function(e,t,n,r,o,i){var a=this.getTransform().multiply(new DOMMatrix([e,t,n,r,o,i]));this.setTransform(a)}},{key:"__matrixTransform",value:function(e,t){return new DOMPoint(e,t).matrixTransform(this.__transformMatrix)}},{key:"__getTransformScale",value:function(){return{x:Math.hypot(this.__transformMatrix.a,this.__transformMatrix.b),y:Math.hypot(this.__transformMatrix.c,this.__transformMatrix.d)}}},{key:"__getTransformRotation",value:function(){return Math.atan2(this.__transformMatrix.b,this.__transformMatrix.a)}},{key:"drawFocusRing",value:function(){}},{key:"createImageData",value:function(){}},{key:"putImageData",value:function(){}},{key:"globalCompositeOperation",value:function(){}},{key:"drawImage",value:function(){}},{key:"createPattern",value:function(){return null}}])}()},6439(e,t,n){"use strict";n.d(t,{A:()=>p});var r=n(7330),o=n(2765),i=n(3710),a=n(1683),l=n(5070),s=n(711),c=n(9168);function u(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,l=[],s=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw o}}return l}}(e,t)||function(e,t){if(e){if("string"==typeof e)return d(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?d(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function d(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}(0,l.X$)([s.A]);var f={none:{},clustal:{G:"orange",P:"orange",S:"orange",T:"orange",H:"red",K:"red",R:"red",F:"blue",W:"blue",Y:"blue",I:"green",L:"green",M:"green",V:"green"},lesk:{G:"orange",A:"orange",S:"orange",T:"orange",C:"green",V:"green",I:"green",L:"green",P:"green",F:"green",Y:"green",M:"green",W:"green",N:"magenta",Q:"magenta",H:"magenta",D:"red",E:"red",K:"blue",R:"blue"},maeditor:{A:"lightgreen",G:"lightgreen",C:"green",D:"darkgreen",E:"darkgreen",N:"darkgreen",Q:"darkgreen",I:"blue",L:"blue",M:"blue",V:"blue",F:"#c8a2c8",W:"#c8a2c8",Y:"#c8a2c8",H:"darkblue",K:"orange",R:"orange",P:"pink",S:"red",T:"red"},percent_identity_dynamic:{},flower:{A:"#b18a51",C:"#ff5701",D:"#01a578",E:"#2da0a1",F:"#fa559d",G:"#b1c23c",H:"#0194f9",I:"#f27663",K:"#7fc3d7",L:"#df6e75",M:"#fe9daf",N:"#0bcec6",P:"#4fa32a",Q:"#7295ae",R:"#83bff1",S:"#b4bd9b",T:"#d2b576",V:"#fd997b",W:"#ff2ded",Y:"#c96ecf"},rainbow_dna:{A:"#3737f5",C:"#37f537",G:"#f5f537",T:"#f53737",U:"#f53737"},clustalx_protein:{A:"#197fe5",C:"#e57f7f",D:"#cc4ccc",E:"#cc4ccc",F:"#197fe5",G:"#e5994c",H:"#19b2b2",I:"#197fe5",K:"#e53319",L:"#197fe5",M:"#197fe5",N:"#19cc19",P:"#cccc00",Q:"#19cc19",R:"#e53319",S:"#19cc19",T:"#19cc19",V:"#197fe5",W:"#197fe5",Y:"#19b2b2"},clustalx_protein_dynamic:{},clustalx_dna:{A:"#e53319",C:"#197fe5",G:"#e5994c",T:"#19cc19",U:"#19cc19"},jbrowse_dna:{A:i.A[500],C:o.A[500],G:a.A[500],T:r.A[500],U:r.A[500]},jalview_buried:{A:"#00a35c",R:"#00fc03",N:"#00eb14",D:"#00eb14",C:"#0000ff",Q:"#00f10e",E:"#00f10e",G:"#009d62",H:"#00d52a",I:"#0054ab",L:"#007b84",K:"#00ff00",M:"#009768",F:"#008778",P:"#00e01f",S:"#00d52a",T:"#00db24",W:"#00a857",Y:"#00e619",V:"#005fa0",B:"#00eb14",X:"#00b649",Z:"#00f10e"},jalview_hydrophobicity:{A:"#ad0052",R:"#0000ff",N:"#0c00f3",D:"#0c00f3",C:"#c2003d",Q:"#0c00f3",E:"#0c00f3",G:"#6a0095",H:"#1500ea",I:"#ff0000",L:"#ea0015",K:"#0000ff",M:"#b0004f",F:"#cb0034",P:"#4600b9",S:"#5e00a1",T:"#61009e",W:"#5b00a4",Y:"#4f00b0",V:"#f60009",B:"#0c00f3",X:"#680097",Z:"#0c00f3"},jalview_prophelix:{A:"#e718e7",R:"#6f906f",N:"#1be41b",D:"#778877",C:"#23dc23",Q:"#926d92",E:"#ff00ff",G:"#00ff00",H:"#758a75",I:"#8a758a",L:"#ae51ae",K:"#a05fa0",M:"#ef10ef",F:"#986798",P:"#00ff00",S:"#36c936",T:"#47b847",W:"#8a758a",Y:"#21de21",V:"#857a85",B:"#49b649",X:"#758a75",Z:"#c936c9"},jalview_propstrand:{A:"#5858a7",R:"#6b6b94",N:"#64649b",D:"#2121de",C:"#9d9d62",Q:"#8c8c73",E:"#0000ff",G:"#4949b6",H:"#60609f",I:"#ecec13",L:"#b2b24d",K:"#4747b8",M:"#82827d",F:"#c2c23d",P:"#2323dc",S:"#4949b6",T:"#9d9d62",W:"#c0c03f",Y:"#d3d32c",V:"#ffff00",B:"#4343bc",X:"#797986",Z:"#4747b8"},jalview_propturn:{A:"#2cd3d3",R:"#708f8f",N:"#ff0000",D:"#e81717",C:"#a85757",Q:"#3fc0c0",E:"#778888",G:"#ff0000",H:"#708f8f",I:"#00ffff",L:"#1ce3e3",K:"#7e8181",M:"#1ee1e1",F:"#1ee1e1",P:"#f60909",S:"#e11e1e",T:"#738c8c",W:"#738c8c",Y:"#9d6262",V:"#07f8f8",B:"#f30c0c",X:"#7c8383",Z:"#5ba4a4"},jalview_taylor:{A:"#ccff00",R:"#0000ff",N:"#cc00ff",D:"#ff0000",C:"#ffff00",Q:"#ff00cc",E:"#ff0066",G:"#ff9900",H:"#0066ff",I:"#66ff00",L:"#33ff00",K:"#6600ff",M:"#00ff00",F:"#00ff66",P:"#ffcc00",S:"#ff3300",T:"#ff6600",W:"#00ccff",Y:"#00ffcc",V:"#99ff00"},jalview_zappo:{A:"#ffafaf",R:"#6464ff",N:"#00ff00",D:"#ff0000",C:"#ffff00",Q:"#00ff00",E:"#ff0000",G:"#ff00ff",H:"#6464ff",I:"#ffafaf",L:"#ffafaf",K:"#6464ff",M:"#ffafaf",F:"#ffc800",P:"#ff00ff",S:"#00ff00",T:"#00ff00",W:"#ffc800",Y:"#ffc800",V:"#ffafaf"},cinema:{H:"blue",K:"blue",R:"blue",D:"red",E:"red",S:"green",T:"green",N:"green",Q:"green",A:"white",V:"white",L:"white",I:"white",M:"white",F:"magenta",W:"magenta",Y:"magenta",P:"brown",G:"brown",C:"yellow",B:"gray",Z:"gray",X:"gray","-":"gray",".":"gray"}};const p=(0,c.pd)(f,function(e){var t=u(e,2),n=t[0],r=t[1];return[n,(0,c.pd)(r,function(e){var t=u(e,2),n=t[0],r=t[1];return[n,(0,l.Mj)(r).toHex()]})]})},4760(e,t,n){"use strict";n.d(t,{A:()=>a});var r=n(405),o=n(6807),i=n(548);function a(e){var t=e.checked,n=e.label,a=e.disabled,l=e.onChange;return r.createElement("div",null,r.createElement(o.A,{control:r.createElement(i.A,{disabled:a,checked:t,onChange:l}),label:n}))}},9446(e,t,n){"use strict";n.d(t,{A:()=>f});var r=n(405),o=n(7346),i=n(2509),a=n(8998),l=n(4760),s=n(8053);function c(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,l=[],s=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw o}}return l}}(e,t)||function(e,t){if(e){if("string"==typeof e)return u(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?u(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function u(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var d=(0,a.n9)()({textAreaFont:{fontFamily:"Courier New",wordWrap:"break-word"},dialogContent:{background:"lightgrey",margin:4,minWidth:"80em"}});function f(e){var t=e.str,n=d().classes,a=c((0,r.useState)(!1),2),u=a[0],f=a[1],p=c((0,r.useState)(!1),2),h=p[0],g=p[1],m=c((0,r.useState)(!1),2),A=m[0],b=m[1],v=t.map(function(e){var t,n=c(e,2),r=n[0],o=n[1];return[r,h?o:(t=o,t.replaceAll("-","").replaceAll(".",""))]}).filter(function(e){var t=c(e,2)[1];return A||!!t}).map(function(e){var t=c(e,2),n=t[0],r=t[1];return">".concat(n,"\n").concat(r)}).join("\n");return r.createElement(r.Fragment,null,r.createElement(o.A,{color:"primary",variant:"contained",onClick:function(){(0,s.A)(v),f(!0),setTimeout(function(){f(!1)},500)}},u?"Copied!":"Copy to clipboard"),r.createElement(l.A,{label:"Show gaps",checked:h,onChange:function(){g(!h)}}),r.createElement(l.A,{label:"Show empty",checked:A,onChange:function(){b(!A)}}),r.createElement(i.A,{variant:"outlined",multiline:!0,className:n.dialogContent,minRows:5,maxRows:10,fullWidth:!0,value:v,slotProps:{input:{readOnly:!0,className:n.textAreaFont}}}))}},102(e,t,n){"use strict";n.r(t),n.d(t,{default:()=>s});var r=n(405),o=n(9936),i=n(8647),a=n(4871),l=n(4417);function s(e){var t=e.onClose;return r.createElement(o.A,{open:!0,title:"About",onClose:function(){t()}},r.createElement(i.A,null,r.createElement(a.A,null,"MSAView ","5.3.0"," (",r.createElement(l.A,{href:"https://github.com/gmod/react-msaview"},"Github"),")"),r.createElement("ul",null,r.createElement("li",null,r.createElement(a.A,null,"We use some color schemes from the"," ",r.createElement(l.A,{href:"https://github.com/biotite-dev/biotite"},"biotite")," ","project, and their license is reproduced"," ",r.createElement(l.A,{href:"https://github.com/biotite-dev/biotite/blob/master/LICENSE.rst"},"here"))),r.createElement("li",null,r.createElement(a.A,null,"See this page for some information on jalview colorings"," ",r.createElement(l.A,{href:"https://www.jalview.org/help/html/colourSchemes/"},"here"))),r.createElement("li",null,r.createElement(a.A,null,"See this page for some info on the clustal, cinema, maeditor, and lesk color schemes"," ",r.createElement(l.A,{href:"http://www.bioinformatics.nl/~berndb/aacolour.html"},"here"))),r.createElement("li",null,r.createElement(a.A,null,"See this paper about the flower color scheme"," ",r.createElement(l.A,{href:"https://www.ncbi.nlm.nih.gov/pmc/articles/PMC7245768/"},"here"))))))}},9304(e,t,n){"use strict";n.r(t),n.d(t,{default:()=>W});var r=n(405),o=n(9936),i=n(6677),a=n(5835),l=n(8647),s=n(4871),c=n(3186),u=n(6259),d=n(8450),f=n(6807),p=n(719),h=n(851),g=n(941),m=n(912),A=n(9861),b=n(8717),v=n(2369),y=n(8650),w=n(3724),C=n(6376),S=n(8783),x=n(643);function E(e){return(0,x.Ay)("MuiAlert",e)}const I=(0,S.A)("MuiAlert",["root","action","icon","message","filled","colorSuccess","colorInfo","colorWarning","colorError","filledSuccess","filledInfo","filledWarning","filledError","outlined","outlinedSuccess","outlinedInfo","outlinedWarning","outlinedError","standard","standardSuccess","standardInfo","standardWarning","standardError"]);var k=n(8199),R=n(6493),M=n(9793);const P=(0,R.A)((0,M.jsx)("path",{d:"M20,12A8,8 0 0,1 12,20A8,8 0 0,1 4,12A8,8 0 0,1 12,4C12.76,4 13.5,4.11 14.2, 4.31L15.77,2.74C14.61,2.26 13.34,2 12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0, 0 22,12M7.91,10.08L6.5,11.5L11,16L21,6L19.59,4.58L11,13.17L7.91,10.08Z"}),"SuccessOutlined"),B=(0,R.A)((0,M.jsx)("path",{d:"M12 5.99L19.53 19H4.47L12 5.99M12 2L1 21h22L12 2zm1 14h-2v2h2v-2zm0-6h-2v4h2v-4z"}),"ReportProblemOutlined"),_=(0,R.A)((0,M.jsx)("path",{d:"M11 15h2v2h-2zm0-8h2v6h-2zm.99-5C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"}),"ErrorOutline"),T=(0,R.A)((0,M.jsx)("path",{d:"M11,9H13V7H11M12,20C7.59,20 4,16.41 4,12C4,7.59 7.59,4 12,4C16.41,4 20,7.59 20, 12C20,16.41 16.41,20 12,20M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10, 10 0 0,0 12,2M11,17H13V11H11V17Z"}),"InfoOutlined");var O=n(3118);const D=(0,m.Ay)(C.A,{name:"MuiAlert",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[n.variant],t[`${n.variant}${(0,y.A)(n.color||n.severity)}`]]}})((0,A.A)(({theme:e})=>{const t="light"===e.palette.mode?e.darken:e.lighten,n="light"===e.palette.mode?e.lighten:e.darken;return{...e.typography.body2,backgroundColor:"transparent",display:"flex",padding:"6px 16px",variants:[...Object.entries(e.palette).filter((0,w.A)(["light"])).map(([r])=>({props:{colorSeverity:r,variant:"standard"},style:{color:e.vars?e.vars.palette.Alert[`${r}Color`]:t(e.palette[r].light,.6),backgroundColor:e.vars?e.vars.palette.Alert[`${r}StandardBg`]:n(e.palette[r].light,.9),[`& .${I.icon}`]:e.vars?{color:e.vars.palette.Alert[`${r}IconColor`]}:{color:e.palette[r].main}}})),...Object.entries(e.palette).filter((0,w.A)(["light"])).map(([n])=>({props:{colorSeverity:n,variant:"outlined"},style:{color:e.vars?e.vars.palette.Alert[`${n}Color`]:t(e.palette[n].light,.6),border:`1px solid ${(e.vars||e).palette[n].light}`,[`& .${I.icon}`]:e.vars?{color:e.vars.palette.Alert[`${n}IconColor`]}:{color:e.palette[n].main}}})),...Object.entries(e.palette).filter((0,w.A)(["dark"])).map(([t])=>({props:{colorSeverity:t,variant:"filled"},style:{fontWeight:e.typography.fontWeightMedium,...e.vars?{color:e.vars.palette.Alert[`${t}FilledColor`],backgroundColor:e.vars.palette.Alert[`${t}FilledBg`]}:{backgroundColor:"dark"===e.palette.mode?e.palette[t].dark:e.palette[t].main,color:e.palette.getContrastText(e.palette[t].main)}}}))]}})),N=(0,m.Ay)("div",{name:"MuiAlert",slot:"Icon"})({marginRight:12,padding:"7px 0",display:"flex",fontSize:22,opacity:.9}),L=(0,m.Ay)("div",{name:"MuiAlert",slot:"Message"})({padding:"8px 0",minWidth:0,overflow:"auto"}),F=(0,m.Ay)("div",{name:"MuiAlert",slot:"Action"})({display:"flex",alignItems:"flex-start",padding:"4px 0 0 16px",marginLeft:"auto",marginRight:-8}),Q={success:(0,M.jsx)(P,{fontSize:"inherit"}),warning:(0,M.jsx)(B,{fontSize:"inherit"}),error:(0,M.jsx)(_,{fontSize:"inherit"}),info:(0,M.jsx)(T,{fontSize:"inherit"})},j=r.forwardRef(function(e,t){const n=(0,b.b)({props:e,name:"MuiAlert"}),{action:r,children:o,className:i,closeText:a="Close",color:l,components:s={},componentsProps:c={},icon:u,iconMapping:d=Q,onClose:f,role:p="alert",severity:m="success",slotProps:A={},slots:w={},variant:C="standard",...S}=n,x={...n,color:l,severity:m,variant:C,colorSeverity:l||m},I=(e=>{const{variant:t,color:n,severity:r,classes:o}=e,i={root:["root",`color${(0,y.A)(n||r)}`,`${t}${(0,y.A)(n||r)}`,`${t}`],icon:["icon"],message:["message"],action:["action"]};return(0,g.A)(i,E,o)})(x),R={slots:{closeButton:s.CloseButton,closeIcon:s.CloseIcon,...w},slotProps:{...c,...A}},[P,B]=(0,v.A)("root",{ref:t,shouldForwardComponentProp:!0,className:(0,h.A)(I.root,i),elementType:D,externalForwardedProps:{...R,...S},ownerState:x,additionalProps:{role:p,elevation:0}}),[_,T]=(0,v.A)("icon",{className:I.icon,elementType:N,externalForwardedProps:R,ownerState:x}),[j,z]=(0,v.A)("message",{className:I.message,elementType:L,externalForwardedProps:R,ownerState:x}),[$,H]=(0,v.A)("action",{className:I.action,elementType:F,externalForwardedProps:R,ownerState:x}),[G,V]=(0,v.A)("closeButton",{elementType:k.A,externalForwardedProps:R,ownerState:x}),[W,U]=(0,v.A)("closeIcon",{elementType:O.A,externalForwardedProps:R,ownerState:x});return(0,M.jsxs)(P,{...B,children:[!1!==u?(0,M.jsx)(_,{...T,children:u||d[m]||Q[m]}):null,(0,M.jsx)(j,{...z,children:o}),null!=r?(0,M.jsx)($,{...H,children:r}):null,null==r&&f?(0,M.jsx)($,{...H,children:(0,M.jsx)(G,{size:"small","aria-label":a,title:a,color:"inherit",onClick:f,...V,children:(0,M.jsx)(W,{fontSize:"small",...U})})}):null]})});var z=n(7252),$=n(7346),H=n(4760);function G(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,l=[],s=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw o}}return l}}(e,t)||function(e,t){if(e){if("string"==typeof e)return V(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?V(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function V(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function W(e){var t=e.model,n=e.onClose,h=G((0,r.useState)(!0),2),g=h[0],m=h[1],A=G((0,r.useState)(!0),2),b=A[0],v=A[1],y=G((0,r.useState)("viewport"),2),w=y[0],C=y[1],S=G((0,r.useState)(),2),x=S[0],E=S[1],I=(0,a.A)(),k=t.totalWidth,R=t.totalHeight,M=t.treeAreaWidth,P=t.turnedOnTracks,B=t.totalTrackAreaHeight,_=P.length>0,T=k+M,O=R+(b?B:0),D="entire"===w&&(T>1e4||O>1e4);return r.createElement(o.A,{onClose:function(){n()},open:!0,title:"Export SVG"},r.createElement(l.A,null,x?r.createElement(i.A,{error:x}):null,r.createElement(s.A,null,"Settings:"),r.createElement(H.A,{label:"Include minimap?",disabled:"entire"===w,checked:g,onChange:function(){m(!g)}}),_?r.createElement(H.A,{label:"Include tracks?",checked:b,onChange:function(){v(!b)}}):null,r.createElement("div",null,r.createElement(c.A,null,r.createElement(u.A,null,"Export type"),r.createElement(d.A,{value:w,onChange:function(e){var t=e.target.value;"entire"!==t&&"viewport"!==t||C(t)}},r.createElement(f.A,{value:"entire",control:r.createElement(p.A,null),label:"Entire MSA"}),r.createElement(f.A,{value:"viewport",control:r.createElement(p.A,null),label:"Current viewport only"})))),D?r.createElement(j,{severity:"warning",style:{marginTop:8}},"The entire MSA is very large (",Math.round(T),"x",Math.round(O)," pixels). Export may be slow or fail."):null),r.createElement(z.A,null,r.createElement($.A,{variant:"contained",color:"primary",onClick:function(){t.exportSVG({theme:I,includeMinimap:"entire"!==w&&g,includeTracks:_&&b,exportType:w}).then(function(){n()}).catch(function(e){console.error(e),E(e)})}},"Submit"),r.createElement($.A,{variant:"contained",color:"secondary",onClick:function(){n()}},"Cancel")))}},2820(e,t,n){"use strict";n.r(t),n.d(t,{default:()=>h});var r=n(405),o=n(9936),i=n(7346),a=n(8647),l=n(2020),s=n(3431);function c(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=u(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,l=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){l=!0,i=e},f:function(){try{a||null==n.return||n.return()}finally{if(l)throw i}}}}function u(e,t){if(e){if("string"==typeof e)return d(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?d(e,t):void 0}}function d(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var f=(0,l.PA)(function(e){var t=e.model,n=t.featureFilters;return r.createElement("div",null,r.createElement(i.A,{onClick:function(){var e,r=c(n.keys());try{for(r.s();!(e=r.n()).done;){var o=e.value;t.setFilter(o,!0)}}catch(e){r.e(e)}finally{r.f()}}},"Toggle all on"),r.createElement(i.A,{onClick:function(){var e,r=c(n.keys());try{for(r.s();!(e=r.n()).done;){var o=e.value;t.setFilter(o,!1)}}catch(e){r.e(e)}finally{r.f()}}},"Toggle all off"))}),p=(0,l.PA)(function(e){var t,n=e.model,o=n.tidyInterProAnnotationTypes,i=n.featureFilters,a=function(e){if(Array.isArray(e))return d(e)}(t=o.values())||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(t)||u(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),l=(0,s.S)(a.length-1);return r.createElement(r.Fragment,null,r.createElement(f,{model:n}),r.createElement("table",null,r.createElement("thead",null,r.createElement("tr",null,r.createElement("td",null),r.createElement("td",null,"accession"),r.createElement("td",null,"name"),r.createElement("td",null,"description"))),r.createElement("tbody",null,a.map(function(e,t){var o,a=e.accession,s=e.name,c=e.description;return r.createElement("tr",{key:a},r.createElement("td",null,r.createElement("input",{type:"checkbox",checked:null!==(o=i.get(a))&&void 0!==o&&o,onChange:function(){n.setFilter(a,!n.featureFilters.get(a))}})),r.createElement("td",null,a),r.createElement("td",null,s),r.createElement("td",null,c),r.createElement("td",null,r.createElement("div",{style:{width:20,height:20,background:l[t]||"black"}})))}))))});const h=(0,l.PA)(function(e){var t=e.onClose,n=e.model;return r.createElement(o.A,{onClose:function(){t()},open:!0,title:"Feature filters",maxWidth:"xl"},r.createElement(a.A,null,r.createElement(p,{model:n})))})},6574(e,t,n){"use strict";n.r(t),n.d(t,{default:()=>N});var r=n(405),o=n(9936),i=n(6081),a=n(8647),l=n(4871),s=n(7346),c=n(7252),u=n(2020),d=n(4567);function f(){var e,t,n="function"==typeof Symbol?Symbol:{},r=n.iterator||"@@iterator",o=n.toStringTag||"@@toStringTag";function i(n,r,o,i){var s=r&&r.prototype instanceof l?r:l,c=Object.create(s.prototype);return p(c,"_invoke",function(n,r,o){var i,l,s,c=0,u=o||[],d=!1,f={p:0,n:0,v:e,a:p,f:p.bind(e,4),d:function(t,n){return i=t,l=0,s=e,f.n=n,a}};function p(n,r){for(l=n,s=r,t=0;!d&&c&&!o&&t<u.length;t++){var o,i=u[t],p=f.p,h=i[2];n>3?(o=h===r)&&(s=i[(l=i[4])?5:(l=3,3)],i[4]=i[5]=e):i[0]<=p&&((o=n<2&&p<i[1])?(l=0,f.v=r,f.n=i[1]):p<h&&(o=n<3||i[0]>r||r>h)&&(i[4]=n,i[5]=r,f.n=h,l=0))}if(o||n>1)return a;throw d=!0,r}return function(o,u,h){if(c>1)throw TypeError("Generator is already running");for(d&&1===u&&p(u,h),l=u,s=h;(t=l<2?e:s)||!d;){i||(l?l<3?(l>1&&(f.n=-1),p(l,s)):f.n=s:f.v=s);try{if(c=2,i){if(l||(o="next"),t=i[o]){if(!(t=t.call(i,s)))throw TypeError("iterator result is not an object");if(!t.done)return t;s=t.value,l<2&&(l=0)}else 1===l&&(t=i.return)&&t.call(i),l<2&&(s=TypeError("The iterator does not provide a '"+o+"' method"),l=1);i=e}else if((t=(d=f.n<0)?s:n.call(r,f))!==a)break}catch(t){i=e,l=1,s=t}finally{c=1}}return{value:t,done:d}}}(n,o,i),!0),c}var a={};function l(){}function s(){}function c(){}t=Object.getPrototypeOf;var u=[][r]?t(t([][r]())):(p(t={},r,function(){return this}),t),d=c.prototype=l.prototype=Object.create(u);function h(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,c):(e.__proto__=c,p(e,o,"GeneratorFunction")),e.prototype=Object.create(d),e}return s.prototype=c,p(d,"constructor",c),p(c,"constructor",s),s.displayName="GeneratorFunction",p(c,o,"GeneratorFunction"),p(d),p(d,o,"Generator"),p(d,r,function(){return this}),p(d,"toString",function(){return"[object Generator]"}),(f=function(){return{w:i,m:h}})()}function p(e,t,n,r){var o=Object.defineProperty;try{o({},"",{})}catch(e){o=0}p=function(e,t,n,r){function i(t,n){p(e,t,function(e){return this._invoke(t,n,e)})}t?o?o(e,t,{value:n,enumerable:!r,configurable:!r,writable:!r}):e[t]=n:(i("next",0),i("throw",1),i("return",2))},p(e,t,n,r)}function h(e,t,n,r,o,i,a){try{var l=e[i](a),s=l.value}catch(e){return void n(e)}l.done?t(s):Promise.resolve(s).then(r,o)}function g(e){return function(){var t=this,n=arguments;return new Promise(function(r,o){var i=e.apply(t,n);function a(e){h(i,r,o,a,l,"next",e)}function l(e){h(i,r,o,a,l,"throw",e)}a(void 0)})}}var m="https://www.ebi.ac.uk/Tools/services/rest";function A(e){return b.apply(this,arguments)}function b(){return(b=g(f().m(function e(t){var n,r,o,i,a,l,s;return f().w(function(e){for(;;)switch(e.n){case 0:return n=t.seq,r=t.onProgress,o=t.onJobId,i=t.programs,a=t.model,l=t.signal,e.n=1,(0,d.y1)("".concat(m,"/iprscan5/run"),{method:"POST",body:new URLSearchParams({email:"colin.diesh@gmail.com",sequence:n,programs:i.join(",")}),signal:l});case 1:return s=e.v,null==o||o(s),e.n=2,y({jobId:s,onProgress:r,signal:l});case 2:return e.n=3,x({jobId:s,model:a,onProgress:r,signal:l});case 3:return e.a(2)}},e)}))).apply(this,arguments)}function v(e,t){return(0,d.jT)("".concat(m,"/iprscan5/result/").concat(e,"/json"),{signal:t})}function y(e){return w.apply(this,arguments)}function w(){return(w=g(f().m(function e(t){var n,r,o,i,a,l,s,c,u;return f().w(function(e){for(;;)switch(e.p=e.n){case 0:n=t.onProgress,r=t.jobId,o=t.signal,i="".concat(m,"/iprscan5/status/").concat(r),a=360,e.p=1,l=!1,s=0;case 2:if(!(s<a)||l){e.n=10;break}c=0;case 3:if(!(c<10)){e.n=6;break}return e.n=4,(0,d.wR)(1e3,o);case 4:n({msg:"Checking status ".concat(10-c),url:i});case 5:c++,e.n=3;break;case 6:return e.n=7,(0,d.y1)(i,{signal:o});case 7:if("FINISHED"!==(u=e.v.trim())){e.n=8;break}l=!0,e.n=9;break;case 8:if("FAILURE"!==u&&"ERROR"!==u&&"NOT_FOUND"!==u){e.n=9;break}throw new Error("InterProScan job ".concat(r," ended with status: ").concat(u));case 9:s++,e.n=2;break;case 10:if(l){e.n=11;break}throw new Error("InterProScan job ".concat(r," did not finish after ").concat(a," status checks"));case 11:return e.p=11,n(),e.f(11);case 12:return e.a(2)}},e,null,[[1,,11,12]])}))).apply(this,arguments)}function C(e){return S.apply(this,arguments)}function S(){return(S=g(f().m(function e(t){var n,r,o,a,l,s,c,u;return f().w(function(e){for(;;)switch(e.p=e.n){case 0:if(n=t.algorithm,r=t.seq,o=t.programs,a=t.onJobId,l=t.onProgress,s=t.model,c=t.signal,e.p=1,l({msg:"Launching ".concat(n," MSA")}),"interproscan"!==n){e.n=3;break}return e.n=2,A({seq:r,onJobId:a,onProgress:l,programs:o,model:s,signal:c});case 2:e.n=4;break;case 3:throw new Error("unknown algorithm");case 4:e.n=7;break;case 5:if(e.p=5,u=e.v,!(0,d.zf)(u)){e.n=6;break}(0,i.HtM)(s).notify("Cancelled InterProScan query","info"),e.n=7;break;case 6:throw u;case 7:return e.p=7,l(),e.f(7);case 8:return e.a(2)}},e,null,[[1,5,7,8]])}))).apply(this,arguments)}function x(e){return E.apply(this,arguments)}function E(){return(E=g(f().m(function e(t){var n,r,o,a,l,s;return f().w(function(e){for(;;)switch(e.p=e.n){case 0:return n=t.jobId,r=t.model,o=t.onProgress,a=t.signal,e.p=1,o({msg:"Downloading results of ".concat(n," (for larger sequences this can be slow, click status to download and upload in the manual tab)"),url:"https://www.ebi.ac.uk/Tools/services/rest/iprscan5/result/".concat(n,"/json")}),e.n=2,v(n,a);case 2:l=e.v,r.setDomains(Object.fromEntries(l.results.map(function(e){var t;return[null===(t=e.xref[0])||void 0===t?void 0:t.id,e]}).filter(function(e){return void 0!==e[0]}))),(0,i.HtM)(r).notify("Loaded interproscan ".concat(n," results"),"success"),e.n=4;break;case 3:e.p=3,s=e.v,(0,d.zf)(s)?(0,i.HtM)(r).notify("Cancelled InterProScan query","info"):(console.error(s),(0,i.HtM)(r).notifyError("".concat(s),s));case 4:return e.p=4,o(),e.f(4);case 5:return e.a(2)}},e,null,[[1,3,4,5]])}))).apply(this,arguments)}function I(e){return I="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},I(e)}function k(){var e,t,n="function"==typeof Symbol?Symbol:{},r=n.iterator||"@@iterator",o=n.toStringTag||"@@toStringTag";function i(n,r,o,i){var s=r&&r.prototype instanceof l?r:l,c=Object.create(s.prototype);return R(c,"_invoke",function(n,r,o){var i,l,s,c=0,u=o||[],d=!1,f={p:0,n:0,v:e,a:p,f:p.bind(e,4),d:function(t,n){return i=t,l=0,s=e,f.n=n,a}};function p(n,r){for(l=n,s=r,t=0;!d&&c&&!o&&t<u.length;t++){var o,i=u[t],p=f.p,h=i[2];n>3?(o=h===r)&&(s=i[(l=i[4])?5:(l=3,3)],i[4]=i[5]=e):i[0]<=p&&((o=n<2&&p<i[1])?(l=0,f.v=r,f.n=i[1]):p<h&&(o=n<3||i[0]>r||r>h)&&(i[4]=n,i[5]=r,f.n=h,l=0))}if(o||n>1)return a;throw d=!0,r}return function(o,u,h){if(c>1)throw TypeError("Generator is already running");for(d&&1===u&&p(u,h),l=u,s=h;(t=l<2?e:s)||!d;){i||(l?l<3?(l>1&&(f.n=-1),p(l,s)):f.n=s:f.v=s);try{if(c=2,i){if(l||(o="next"),t=i[o]){if(!(t=t.call(i,s)))throw TypeError("iterator result is not an object");if(!t.done)return t;s=t.value,l<2&&(l=0)}else 1===l&&(t=i.return)&&t.call(i),l<2&&(s=TypeError("The iterator does not provide a '"+o+"' method"),l=1);i=e}else if((t=(d=f.n<0)?s:n.call(r,f))!==a)break}catch(t){i=e,l=1,s=t}finally{c=1}}return{value:t,done:d}}}(n,o,i),!0),c}var a={};function l(){}function s(){}function c(){}t=Object.getPrototypeOf;var u=[][r]?t(t([][r]())):(R(t={},r,function(){return this}),t),d=c.prototype=l.prototype=Object.create(u);function f(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,c):(e.__proto__=c,R(e,o,"GeneratorFunction")),e.prototype=Object.create(d),e}return s.prototype=c,R(d,"constructor",c),R(c,"constructor",s),s.displayName="GeneratorFunction",R(c,o,"GeneratorFunction"),R(d),R(d,o,"Generator"),R(d,r,function(){return this}),R(d,"toString",function(){return"[object Generator]"}),(k=function(){return{w:i,m:f}})()}function R(e,t,n,r){var o=Object.defineProperty;try{o({},"",{})}catch(e){o=0}R=function(e,t,n,r){function i(t,n){R(e,t,function(e){return this._invoke(t,n,e)})}t?o?o(e,t,{value:n,enumerable:!r,configurable:!r,writable:!r}):e[t]=n:(i("next",0),i("throw",1),i("return",2))},R(e,t,n,r)}function M(e,t,n,r,o,i,a){try{var l=e[i](a),s=l.value}catch(e){return void n(e)}l.done?t(s):Promise.resolve(s).then(r,o)}function P(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function B(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?P(Object(n),!0).forEach(function(t){_(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):P(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function _(e,t,n){return(t=function(e){var t=function(e){if("object"!=I(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=I(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==I(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function T(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,l=[],s=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw o}}return l}}(e,t)||function(e,t){if(e){if("string"==typeof e)return O(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?O(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function O(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var D=(0,u.PA)(function(e){var t=e.handleClose,n=e.model,u=T((0,r.useState)([{name:"NCBIfam",description:"NCBI RefSeq FAMs including TIGRFAMs",category:"Families, domains, sites & repeats",checked:!0},{name:"SFLD",description:"Structure function linkage database",category:"Families, domains, sites & repeats",checked:!0},{name:"Phobius",checked:!0,description:"A combined transmembrane topology and signal peptide predictor",category:"Other sequence features"},{name:"SignalP",checked:!0,category:"Other sequence features"},{name:"SignalP_EUK",category:"Other category",checked:!0},{name:"SignalP_GRAM_POSITIVE",category:"Other category",checked:!0},{name:"SignalP_GRAM_NEGATIVE",checked:!0,category:"Other category"},{name:"SuperFamily",category:"Structural domains",checked:!0},{name:"Panther",category:"Families, domains, sites & repeats",checked:!0},{name:"Gene3d",category:"Structural domains",checked:!0},{name:"HAMAP",category:"Families, domains, sites & repeats",checked:!0},{name:"PrositeProfiles",category:"Families, domains, sites & repeats",checked:!0},{name:"PrositePatterns",category:"Families, domains, sites & repeats",checked:!0},{name:"Coils",category:"Other sequence features",checked:!0},{name:"SMART",category:"Families, domains, sites & repeats",checked:!0},{name:"CDD",description:"Conserved Domains Database",category:"Families, domains, sites & repeats",checked:!0},{name:"PRINTS",category:"Families, domains, sites & repeats",checked:!0},{name:"PfamA",category:"Families, domains, sites & repeats",checked:!0},{name:"MobiDBLite",checked:!0,category:"Other sequence features"},{name:"PIRSF",checked:!0,category:"Other category"},{name:"TMHMM",checked:!0,category:"Other sequence features"},{name:"AntiFam",checked:!0,category:"Other category"},{name:"FunFam",checked:!0,category:"Other category"},{name:"PIRSR",checked:!0,category:"Families, domains, sites & repeats"}]),2),d=u[0],f=u[1],p=d.filter(function(e){return e.checked}).map(function(e){return e.name}),h=T((0,r.useState)(!1),2),g=h[0],m=h[1];return r.createElement(o.A,{maxWidth:"xl",title:"Query InterProScan API for domains",onClose:function(){t()},open:!0},r.createElement(a.A,null,r.createElement(l.A,null,"This will run InterProScan via the InterProScan API on all rows of the current MSA"),r.createElement(s.A,{onClick:function(){m(!g)}},g?"Hide":"Show"," advanced options"),g?r.createElement("div",null,r.createElement(l.A,null,"Select algorithms for InterProScan to run"),r.createElement("div",null,r.createElement(s.A,{variant:"contained",color:"secondary",onClick:function(){f(d.map(function(e){return B(B({},e),{},{checked:!1})}))}},"Select none"),r.createElement(s.A,{variant:"contained",color:"primary",onClick:function(){f(d.map(function(e){return B(B({},e),{},{checked:!0})}))}},"Select all")),r.createElement("table",null,r.createElement("tbody",null,d.toSorted(function(e,t){return e.category.localeCompare(t.category)}).map(function(e){var t=e.name,n=e.checked,o=e.category;return r.createElement("tr",{key:t},r.createElement("td",null,r.createElement("input",{type:"checkbox",key:t,checked:n,onChange:function(){f(d.map(function(e){return e.name===t?B(B({},e),{},{checked:!e.checked}):e}))}})),r.createElement("td",null,t),r.createElement("td",null,o))})))):null),r.createElement(c.A,null,r.createElement(s.A,{variant:"contained",color:"secondary",onClick:function(){t()}},"Cancel"),r.createElement(s.A,{variant:"contained",color:"primary",onClick:function(){var e,r=new AbortController;(e=k().m(function e(){var t,o;return k().w(function(e){for(;;)switch(e.p=e.n){case 0:if(e.p=0,!((t=n.rows).length>140)){e.n=1;break}throw new Error("Too many sequences, please run InterProScan offline");case 1:return e.n=2,C({algorithm:"interproscan",programs:p,seq:t.map(function(e){return[e[0],e[1].replaceAll("-","")]}).filter(function(e){return!!e[1]}).map(function(e){return">".concat(e[0],"\n").concat(e[1])}).join("\n"),onProgress:function(e){n.setStatus(e?B(B({},e),{},{onCancel:function(){r.abort()}}):void 0)},model:n,signal:r.signal});case 2:e.n=4;break;case 3:e.p=3,o=e.v,console.error(o),(0,i.HtM)(n).notifyError("".concat(o),o);case 4:return e.p=4,n.setStatus(),e.f(4);case 5:return e.a(2)}},e,null,[[0,3,4,5]])}),function(){var t=this,n=arguments;return new Promise(function(r,o){var i=e.apply(t,n);function a(e){M(i,r,o,a,l,"next",e)}function l(e){M(i,r,o,a,l,"throw",e)}a(void 0)})})(),t()}},"Send sequences to InterProScan")))});const N=D},390(e,t,n){"use strict";n.r(t),n.d(t,{default:()=>u});var r=n(405),o=n(7434),i=n(6584),a=n(9936),l=n(8647),s=n(2020),c=n(9446);const u=(0,s.PA)(function(e){var t=e.model,n=e.onClose,s=t.header;return r.createElement(a.A,{onClose:function(){n()},open:!0,title:"Metadata",maxWidth:"xl"},r.createElement(l.A,null,r.createElement(o.A,{attributes:s}),r.createElement(i.A,{title:"sequence"},r.createElement(c.A,{str:t.rows}))))})},4262(e,t,n){"use strict";n.r(t),n.d(t,{default:()=>w});var r=n(405),o=n(9936),i=n(4871),a=n(937),l=n(2509),s=n(9406),c=n(8647),u=n(7252),d=n(7346),f=n(2020),p=n(8998),h=n(6439),g=n(4760),m=(0,p.n9)()(function(e){return{field:{margin:e.spacing(4)},flex:{display:"flex"},minw:{width:"80em"}}}),A=function(){return+(arguments.length>0&&void 0!==arguments[0]?arguments[0]:0).toFixed(1)},b=(0,f.PA)(function(e){var t=e.model;return r.createElement(r.Fragment,null,r.createElement(v,{model:t}),r.createElement(y,{model:t}))}),v=(0,f.PA)(function(e){var t=e.model,n=t.drawTree,o=t.drawLabels,i=t.drawNodeBubbles,a=t.labelsAlignRight,l=t.showBranchLen;return r.createElement("div",null,r.createElement("h1",null,"Tree options"),r.createElement(g.A,{checked:l,label:"Show branch length?",onChange:function(){t.setShowBranchLen(!l)}}),r.createElement(g.A,{checked:i,label:"Draw clickable bubbles on tree branches?",onChange:function(){t.setDrawNodeBubbles(!i)}}),r.createElement(g.A,{checked:n,label:"Show tree?",onChange:function(){t.setDrawTree(!n)}}),r.createElement(g.A,{checked:a,label:"Tree labels align right?",onChange:function(){t.setLabelsAlignRight(!a)}}),r.createElement(g.A,{checked:o,label:"Draw labels",onChange:function(){t.setDrawLabels(!o)}}))}),y=(0,f.PA)(function(e){var t=e.model,n=m().classes,o=t.bgColor,c=t.colWidth,u=t.allowedGappyness,d=t.drawMsaLetters,f=t.colorSchemeName,p=t.hideGaps,b=t.rowHeight;return r.createElement("div",null,r.createElement("h1",null,"MSA options"),r.createElement(g.A,{checked:d,label:"Draw letters",onChange:function(){t.setDrawMsaLetters(!d)}}),r.createElement(g.A,{checked:o,label:"Color letters instead of background of tiles",onChange:function(){t.setBgColor(!o)}}),r.createElement(g.A,{checked:p,label:"Enable hiding gappy columns?",onChange:function(){t.setHideGaps(!p)}}),p?r.createElement("div",{className:n.flex},r.createElement(i.A,null,"Hide columns w/ >",u,"% gaps"),r.createElement(a.Ay,{className:n.field,min:1,max:100,value:u,onChange:function(e,n){t.setAllowedGappyness(n)}})):null,r.createElement("div",{className:n.flex},r.createElement(i.A,null,"Column width (",A(c),"px)"),r.createElement(a.Ay,{className:n.field,min:1,max:50,value:c,onChange:function(e,n){t.setColWidth(n)}})),r.createElement("div",{className:n.flex},r.createElement(i.A,null,"Row height (",A(b),"px)"),r.createElement(a.Ay,{className:n.field,min:1,max:50,value:b,onChange:function(e,n){t.setRowHeight(n)}})),r.createElement(l.A,{select:!0,label:"Color scheme",value:f,onChange:function(e){t.setColorSchemeName(e.target.value)}},Object.keys(h.A).map(function(e){return r.createElement(s.A,{key:e,value:e},e)})))});const w=(0,f.PA)(function(e){var t=e.model,n=e.onClose,i=m().classes;return r.createElement(o.A,{open:!0,title:"Settings",maxWidth:"xl",onClose:function(){n()}},r.createElement(c.A,{className:i.minw},r.createElement(b,{model:t}),r.createElement(u.A,null,r.createElement(d.A,{variant:"contained",color:"primary",onClick:function(){n()}},"Submit"))))})},4916(e,t,n){"use strict";n.r(t),n.d(t,{default:()=>p});var r=n(405),o=n(9936),i=n(8647),a=n(7346),l=n(7252),s=n(2020),c=n(8998),u=n(8053);function d(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var f=(0,c.n9)()(function(e){return{textArea:{padding:e.spacing(2),overflow:"auto",background:"#ddd",wordBreak:"break-word"}}});const p=(0,s.PA)(function(e){var t,n,s=e.model,c=e.onClose,p=(t=(0,r.useState)("Copy to clipboard"),n=2,function(e){if(Array.isArray(e))return e}(t)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,l=[],s=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw o}}return l}}(t,n)||function(e,t){if(e){if("string"==typeof e)return d(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?d(e,t):void 0}}(t,n)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),h=p[0],g=p[1],m=f().classes;return r.createElement(o.A,{open:!0,onClose:c,fullWidth:!0,maxWidth:"lg",title:"Track info - ".concat(s.name)},r.createElement(i.A,null,r.createElement(a.A,{variant:"contained",color:"primary",onClick:function(){(0,u.A)(s.data),g("Copied!"),setTimeout(function(){g("Copy to clipboard")},300)}},h),r.createElement("pre",{className:m.textArea},s.data)),r.createElement(l.A,null,r.createElement(a.A,{variant:"contained",onClick:c,color:"secondary"},"Close")))})},2802(e,t,n){"use strict";n.r(t),n.d(t,{default:()=>S});var r=n(405),o=n(9936),i=n(6081),a=n(8647),l=n(4871),s=n(3186),c=n(8450),u=n(6807),d=n(719),f=n(2509),p=n(7346),h=n(7252),g=n(2020),m=n(4567);function A(){var e,t,n="function"==typeof Symbol?Symbol:{},r=n.iterator||"@@iterator",o=n.toStringTag||"@@toStringTag";function i(n,r,o,i){var s=r&&r.prototype instanceof l?r:l,c=Object.create(s.prototype);return b(c,"_invoke",function(n,r,o){var i,l,s,c=0,u=o||[],d=!1,f={p:0,n:0,v:e,a:p,f:p.bind(e,4),d:function(t,n){return i=t,l=0,s=e,f.n=n,a}};function p(n,r){for(l=n,s=r,t=0;!d&&c&&!o&&t<u.length;t++){var o,i=u[t],p=f.p,h=i[2];n>3?(o=h===r)&&(s=i[(l=i[4])?5:(l=3,3)],i[4]=i[5]=e):i[0]<=p&&((o=n<2&&p<i[1])?(l=0,f.v=r,f.n=i[1]):p<h&&(o=n<3||i[0]>r||r>h)&&(i[4]=n,i[5]=r,f.n=h,l=0))}if(o||n>1)return a;throw d=!0,r}return function(o,u,h){if(c>1)throw TypeError("Generator is already running");for(d&&1===u&&p(u,h),l=u,s=h;(t=l<2?e:s)||!d;){i||(l?l<3?(l>1&&(f.n=-1),p(l,s)):f.n=s:f.v=s);try{if(c=2,i){if(l||(o="next"),t=i[o]){if(!(t=t.call(i,s)))throw TypeError("iterator result is not an object");if(!t.done)return t;s=t.value,l<2&&(l=0)}else 1===l&&(t=i.return)&&t.call(i),l<2&&(s=TypeError("The iterator does not provide a '"+o+"' method"),l=1);i=e}else if((t=(d=f.n<0)?s:n.call(r,f))!==a)break}catch(t){i=e,l=1,s=t}finally{c=1}}return{value:t,done:d}}}(n,o,i),!0),c}var a={};function l(){}function s(){}function c(){}t=Object.getPrototypeOf;var u=[][r]?t(t([][r]())):(b(t={},r,function(){return this}),t),d=c.prototype=l.prototype=Object.create(u);function f(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,c):(e.__proto__=c,b(e,o,"GeneratorFunction")),e.prototype=Object.create(d),e}return s.prototype=c,b(d,"constructor",c),b(c,"constructor",s),s.displayName="GeneratorFunction",b(c,o,"GeneratorFunction"),b(d),b(d,o,"Generator"),b(d,r,function(){return this}),b(d,"toString",function(){return"[object Generator]"}),(A=function(){return{w:i,m:f}})()}function b(e,t,n,r){var o=Object.defineProperty;try{o({},"",{})}catch(e){o=0}b=function(e,t,n,r){function i(t,n){b(e,t,function(e){return this._invoke(t,n,e)})}t?o?o(e,t,{value:n,enumerable:!r,configurable:!r,writable:!r}):e[t]=n:(i("next",0),i("throw",1),i("return",2))},b(e,t,n,r)}function v(e,t,n,r,o,i,a){try{var l=e[i](a),s=l.value}catch(e){return void n(e)}l.done?t(s):Promise.resolve(s).then(r,o)}function y(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,l=[],s=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw o}}return l}}(e,t)||function(e,t){if(e){if("string"==typeof e)return w(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?w(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function w(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var C=(0,g.PA)(function(e){var t=e.handleClose,n=e.model,g=y((0,r.useState)(),2),b=g[0],w=g[1],C=y((0,r.useState)("file"),2),S=C[0],x=C[1],E=y((0,r.useState)(""),2),I=E[0],k=E[1];return r.createElement(o.A,{maxWidth:"xl",title:"Open protein domains from file",onClose:function(){t()},open:!0},r.createElement(a.A,null,r.createElement("div",null,r.createElement(l.A,null,"Open a JSON file of InterProScan results that you run remotely on EBI servers or locally"),r.createElement("div",{style:{display:"flex",margin:30}},r.createElement(s.A,{component:"fieldset"},r.createElement(c.A,{value:S,onChange:function(e){x(e.target.value)}},r.createElement(u.A,{value:"url",control:r.createElement(d.A,null),label:"URL"}),r.createElement(u.A,{value:"file",control:r.createElement(d.A,null),label:"File"}))),"url"===S?r.createElement("div",null,r.createElement(l.A,null,"Open a InterProScan JSON file remote URL"),r.createElement(f.A,{label:"URL",value:I,onChange:function(e){k(e.target.value)}})):null,"file"===S?r.createElement("div",{style:{paddingTop:20}},r.createElement(l.A,null,"Open a InterProScan JSON file file from your local drive"),r.createElement(p.A,{variant:"outlined",component:"label"},"Choose File",r.createElement("input",{type:"file",hidden:!0,onChange:function(e){var t,n=null===(t=e.target.files)||void 0===t?void 0:t[0];n&&w(n)}}))):null))),r.createElement(h.A,null,r.createElement(p.A,{variant:"contained",color:"primary",onClick:function(){var e;(e=A().m(function e(){var t,r,o,a;return A().w(function(e){for(;;)switch(e.p=e.n){case 0:if(e.p=0,!b){e.n=2;break}return o=JSON,e.n=1,b.text();case 1:r=o.parse.call(o,e.v),e.n=4;break;case 2:return e.n=3,(0,m.jT)(I);case 3:r=e.v;case 4:t=r,n.setDomains(Object.fromEntries(t.results.map(function(e){return[e.xref[0].id,e]}))),(0,i.HtM)(n).notify("Loaded interproscan results","success"),e.n=6;break;case 5:e.p=5,a=e.v,console.error(a),(0,i.HtM)(n).notifyError("".concat(a),a);case 6:return e.p=6,n.setStatus(),e.f(6);case 7:return e.a(2)}},e,null,[[0,5,6,7]])}),function(){var t=this,n=arguments;return new Promise(function(r,o){var i=e.apply(t,n);function a(e){v(i,r,o,a,l,"next",e)}function l(e){v(i,r,o,a,l,"throw",e)}a(void 0)})})(),t()}},"Open results")))});const S=C},2700(e,t,n){"use strict";n.d(t,{S:()=>r,a:()=>o});var r=12;function o(e){var t=e.scrollX,n=e.msaAreaWidth,o=e.minimapHeight,i=e.colWidth,a=n/e.numColumns/i,l=-t,s=l*a,c=(l+n)*a,u=Math.max(c-s,20),d=o-r;return{unit:a,s,w:u,polygonHeight:d,polygonPoints:"".concat(s+u,",0 ").concat(s,",0 0,").concat(d," ").concat(n,",").concat(d)}}},1755(e,t,n){"use strict";function r(e){var t=e.model,n=e.offsetY,r=e.blockSizeY,o=t.leaves,i=t.rowHeight,a=Math.max(0,Math.floor((n-i)/i)),l=Math.max(0,Math.ceil((n+r+i)/i));return o.slice(a,l)}n.d(t,{t:()=>r})},1739(e,t,n){"use strict";n.d(t,{X:()=>o});var r=n(1755);function o(e){var t=e.model,n=e.offsetX,o=e.offsetY,i=e.ctx,a=e.highResScaleFactorOverride,l=e.blockSizeYOverride,s=t.blockSize,c=t.rowHeight,u=t.highResScaleFactor;if(t.showDomains){var d=null!=a?a:u,f=null!=l?l:s;i.resetTransform(),i.scale(d,d),i.translate(-n,c/2-o),function(e){for(var t=e.model,n=e.ctx,r=e.visibleLeaves,o=t.subFeatureRows,i=t.colWidth,a=t.rowHeight,l=t.fillPalette,s=t.strokePalette,c=t.tidyFilteredGatheredInterProAnnotations,u=0,d=r.length;u<d;u++){var f=r[u],p=f.x,h=f.data.name,g=p,m=c[h];if(m)for(var A=0,b=m.length;A<b;A++){var v=m[A],y=v.start,w=v.end,C=v.accession,S=t.seqPosToVisibleCol(h,y-1),x=t.seqPosToVisibleCol(h,w);if(void 0!==S&&void 0!==x){var E=S*i;n.fillStyle=l[C],n.strokeStyle=s[C];var I=o?4:a,k=g-a+(o?A*I:0),R=i*(x-S);n.fillRect(E,k,R,I),n.strokeRect(E,k,R,I)}}}}({model:t,ctx:i,visibleLeaves:(0,r.t)({model:t,offsetY:o,blockSizeY:f})})}}},5374(e,t,n){"use strict";n.d(t,{H:()=>c});var r=n(1755),o=n(988),i=n(9444),a=n(9168);function l(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return s(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?s(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,l=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){l=!0,i=e},f:function(){try{a||null==n.return||n.return()}finally{if(l)throw i}}}}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function c(e){var t,n=e.model,l=e.offsetX,s=e.offsetY,c=e.contrastScheme,d=e.ctx,f=e.theme,p=e.highResScaleFactorOverride,h=e.blockSizeXOverride,g=e.blockSizeYOverride,m=n.colWidth,A=n.blockSize,b=n.rowHeight,v=n.fontSize,y=n.highResScaleFactor,w=n.actuallyShowDomains,C=n.bgColor,S=null!=p?p:y,x=null!=h?h:A,E=null!=g?g:A;d.resetTransform(),d.scale(S,S),d.translate(-l,b/2-s),d.textAlign="center",(0,i.X)(d,v,!C);var I=(0,o.U)({offsetX:l,blockWidth:x,colWidth:m}),k=I.xStart,R=I.xEnd,M=(0,r.t)({model:n,offsetY:s,blockSizeY:E}),P=n.relativeTo,B=n.columns,_=P?null===(t=B.get(P))||void 0===t?void 0:t.slice(k,R):null;w?function(e){var t=e.model,n=e.offsetX,r=e.ctx,o=e.visibleLeaves,i=e.xStart,a=e.xEnd,l=e.referenceSeq,s=t.showMsaLetters,c=t.columns,u=t.colWidth,d=t.rowHeight,f=t.relativeTo;if(s){var p=n-n%u,h=u/2,g=d/4;r.fillStyle="black";for(var m=0,A=o.length;m<A;m++){var b,v=o[m],y=v.data.name,w=v.x-g,C=null===(b=c.get(y))||void 0===b?void 0:b.slice(i,a);if(C)for(var S=0,x=C.length;S<x;S++){var E=C[S],I=l&&y!==f&&E===l[S];r.fillText(I?".":E,S*u+p+h,w)}}}}({model:n,ctx:d,offsetX:l,xStart:k,xEnd:R,visibleLeaves:M,referenceSeq:_}):function(e){var t=e.model,n=e.offsetX,r=e.ctx,o=e.theme,i=e.contrastScheme,l=e.visibleLeaves,s=e.xStart,c=e.xEnd,u=e.referenceSeq,d=t.bgColor,f=t.colorSchemeName,p=t.colorScheme,h=t.columns,g=t.colWidth,m=t.rowHeight,A=t.relativeTo,b=t.showMsaLetters,v=t.colClustalX,y=t.colConsensus,w="clustalx_protein_dynamic"===f,C="percent_identity_dynamic"===f,S=d||w||C;if(S||b)for(var x=n-n%g,E=g/2,I=m/4,k=0,R=l.length;k<R;k++){var M,P=l[k],B=P.data.name,_=P.x,T=null===(M=h.get(B))||void 0===M?void 0:M.slice(s,c);if(T)for(var O=_-m,D=_-I,N=0,L=T.length;N<L;N++){var F,Q=T[N],j=N*g+x,z=u&&B!==A&&Q===u[N],$=void 0;if(w)$=v[s+N][Q];else if(C){var H=y[s+N];$=Q===H.letter?H.color:void 0}else $=p[Q];S&&(r.fillStyle=z?o.palette.action.hover:$||o.palette.background.default,r.fillRect(j,O,g,m)),b&&(r.fillStyle=d?null!==(F=i[Q])&&void 0!==F?F:"black":$?(0,a.uL)($,o.palette.background.default):o.palette.text.primary,r.fillText(z?".":Q,j+E,D))}}}({model:n,ctx:d,theme:f,contrastScheme:c,offsetX:l,xStart:k,xEnd:R,visibleLeaves:M,referenceSeq:_}),function(e){var t=e.model,n=e.ctx,r=e.visibleLeaves,o=e.xStart,i=e.xEnd,a=t.bgColor;t.hideGapsEffective&&(n.lineWidth=1,n.strokeStyle="#f0f",u({visibleLeaves:r,xStart:o,ctx:n,model:t,xEnd:i,offset:0}),n.strokeStyle=a?"#fff":"#000",u({visibleLeaves:r,xStart:o,ctx:n,model:t,xEnd:i,offset:-1}))}({model:n,ctx:d,xStart:k,xEnd:R,visibleLeaves:M}),d.resetTransform()}function u(e){var t,n=e.model,r=e.ctx,o=e.visibleLeaves,i=e.xStart,a=e.xEnd,s=e.offset,c=n.colWidth,u=n.rowHeight,d=n.insertionPositions,f=l(o);try{for(f.s();!(t=f.n()).done;){var p=t.value,h=p.data.name,g=d.get(h);if(g){var m,A=p.x,b=l(g);try{for(b.s();!(m=b.n()).done;){var v=m.value.pos;if(v>=i&&v<a){var y=v*c,w=A-u,C=A;r.beginPath(),r.moveTo(y+s,w+s);for(var S=w,x=!0;S<C;){var E=Math.min(S+2,C),I=x?y+1:y-1;r.lineTo(I+s,E+s),S=E,x=!x}r.stroke()}}}catch(e){b.e(e)}finally{b.f()}}}}catch(e){f.e(e)}finally{f.f()}}},988(e,t,n){"use strict";function r(e){var t=e.offsetX,n=e.blockWidth,r=e.colWidth;return{xStart:Math.max(0,Math.floor(t/r)),xEnd:Math.max(0,Math.ceil((t+n)/r))}}n.d(t,{U:()=>r})},2012(e,t,n){"use strict";n.d(t,{ay:()=>u,kt:()=>a,qM:()=>l});var r=n(9444),o=n(988);function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function a(e){var t=e.ctx,n=e.conservation,r=e.colWidth,i=e.trackHeight,a=e.offsetX,l=e.blockSize,s=(0,o.U)({offsetX:a,blockWidth:l,colWidth:r}),c=s.xStart,u=s.xEnd;t.fillStyle="gray";for(var d=c;d<u&&d<n.length;d++){var f=n[d]*i,p=d*r;t.fillRect(p,i-f,r,f)}}function l(e){for(var t=e.ctx,n=e.data,r=e.colorScheme,i=e.contrastScheme,a=e.bgColor,l=e.colWidth,s=e.rowHeight,c=e.offsetX,u=e.blockSize,d=(0,o.U)({offsetX:c,blockWidth:u,colWidth:l}),f=d.xStart,p=d.xEnd,h=null==n?void 0:n.slice(f,p),g=0;h&&g<h.length;g++){var m=h[g],A=r[m.toUpperCase()];if(a){var b=g*l+c-c%l;t.fillStyle=A||"white",t.fillRect(b,0,l,s),s>=10&&l>=s/2&&(t.fillStyle=i[m.toUpperCase()]||"black",t.fillText(m,b+l/2,s/2+1))}}}function s(e){var t=e.model,n=e.ctx,r=e.offsetX,o=e.offsetY,i=e.trackHeight,l=e.blockSizeXOverride,s=e.highResScaleFactorOverride,c=t.blockSize,u=t.colWidth,d=t.highResScaleFactor,f=t.conservation,p=null!=l?l:c,h=null!=s?s:d;n.resetTransform(),n.scale(h,h),n.translate(-r,o),a({ctx:n,conservation:f,colWidth:u,trackHeight:i,offsetX:r,blockSize:p}),n.resetTransform()}function c(e){var t=e.model,n=e.ctx,o=e.track,i=e.offsetX,a=e.offsetY,s=e.contrastScheme,c=e.blockSizeXOverride,u=e.highResScaleFactorOverride,d=t.blockSize,f=t.bgColor,p=t.colorScheme,h=t.colWidth,g=t.fontSize,m=t.rowHeight,A=t.highResScaleFactor,b=o.model,v=b.customColorScheme,y=b.data,w=null!=v?v:p,C=null!=c?c:d,S=null!=u?u:A;n.resetTransform(),n.scale(S,S),n.translate(-i,a),n.textAlign="center",(0,r.X)(n,g),l({ctx:n,data:y,colorScheme:w,contrastScheme:s,bgColor:f,colWidth:h,rowHeight:m,offsetX:i,blockSize:C}),n.resetTransform()}function u(e){var t,n=e.model,r=e.ctx,o=e.offsetX,a=e.contrastScheme,l=e.blockSizeXOverride,u=e.highResScaleFactorOverride,d=0,f=function(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return i(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?i(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,l=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return l=e.done,e},e:function(e){s=!0,a=e},f:function(){try{l||null==n.return||n.return()}finally{if(s)throw a}}}}(n.turnedOnTracks);try{for(f.s();!(t=f.n()).done;){var p=t.value,h=p.model.height;"conservation"===p.model.id?s({model:n,ctx:r,offsetX:o,offsetY:d,trackHeight:h,blockSizeXOverride:l,highResScaleFactorOverride:u}):c({model:n,ctx:r,track:p,offsetX:o,offsetY:d,contrastScheme:a,blockSizeXOverride:l,highResScaleFactorOverride:u}),d+=h}}catch(e){f.e(e)}finally{f.f()}}},7058(e,t,n){"use strict";n.r(t),n.d(t,{default:()=>h});var r=n(405),o=n(7434),i=n(6584),a=n(9936),l=n(8647),s=n(2020),c=n(9446);function u(e){return u="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},u(e)}function d(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function f(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?d(Object(n),!0).forEach(function(t){p(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):d(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function p(e,t,n){return(t=function(e){var t=function(e){if("object"!=u(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=u(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==u(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const h=(0,s.PA)(function(e){var t=e.info,n=e.model,s=e.nodeName,u=e.onClose,d=n.treeMetadata,p=n.rows,h=d[s],g=p.find(function(e){return e[0]===s});return r.createElement(a.A,{onClose:function(){u()},open:!0,title:"Tree node info",maxWidth:"xl"},r.createElement(l.A,null,r.createElement(i.A,{title:"Attributes"},r.createElement(o.A,{attributes:f({nodeName:s},t)})),r.createElement(i.A,{title:"Sequence"},g?r.createElement(c.A,{str:[g]}):r.createElement("div",null,"Sequence not found")),h?r.createElement(i.A,{title:"Extra metadata"},r.createElement(o.A,{attributes:h})):null))})},1856(e,t,n){"use strict";n.d(t,{Ms:()=>a,t0:()=>c});var r=n(7335),o=n(9444);function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var a=600,l=2.5;function s(e,t,n,o){return t?e.len:(o-(0,r.wt)(e))/o*n}function c(e){var t=e.model,n=e.clickMap,a=e.ctx,c=e.offsetY,u=e.theme,d=e.highResScaleFactorOverride,f=e.blockSizeYOverride;null==n||n.clear();var p=t.noTree,h=t.drawTree,g=t.drawNodeBubbles,m=t.highResScaleFactor,A=t.fontSize,b=t.showTreeText,v=t.marginLeft;t.rowHeight,a.resetTransform();var y=null!=d?d:m;a.scale(y,y),a.translate(v,-c),(0,o.X)(a,A);var w=t.maxBranchLength,C=t.maxDepthToLeaf;!p&&h&&(function(e){var t=e.offsetY,n=e.ctx,o=e.model,i=e.theme,a=e.maxBranchLen,l=e.maxDepthToLeaf,c=e.blockSizeYOverride,u=o.hierarchy,d=o.showBranchLenEffective,f=o.blockSize,p=null!=c?c:f;n.strokeStyle=i.palette.text.primary,(0,r.rX)(u,function(e,r){var o=e.x,i=r.x,c=s(r,d,a,l),u=s(e,d,a,l);if(void 0!==c&&void 0!==u){var f=Math.min(o,i),h=Math.max(o,i);t+p>=f&&h>=t&&(n.beginPath(),n.moveTo(u,o),n.lineTo(u,i),n.lineTo(c,i),n.stroke())}})}({ctx:a,offsetY:c,model:t,theme:u,maxBranchLen:w,maxDepthToLeaf:C,blockSizeYOverride:f}),g&&function(e){var t=e.ctx,n=e.clickMap,o=e.offsetY,i=e.model,a=e.maxBranchLen,c=e.maxDepthToLeaf,u=e.blockSizeYOverride,d=i.hierarchy,f=i.showBranchLenEffective,p=i.collapsed,h=i.blockSize,g=i.marginLeft,m=null!=u?u:h;(0,r.ul)(d,function(e){var r=s(e,f,a,c);if(void 0!==r){var i=e.data,u=e.x,d=i.id,h=i.name;e.height>=1&&u>o-5&&u<o+m+5&&(t.strokeStyle="black",t.fillStyle=p.includes(d)?"black":"white",t.beginPath(),t.arc(r,u,l,0,2*Math.PI),t.fill(),t.stroke(),null==n||n.insert({minX:r-l+g,maxX:r-l+5+g,minY:u-l,maxY:u-l+5,branch:!0,id:d,name:h}))}})}({ctx:a,offsetY:c,clickMap:n,model:t,maxBranchLen:w,maxDepthToLeaf:C,blockSizeYOverride:f})),b&&function(e){var t=e.theme,n=e.model,r=e.offsetY,o=e.ctx,a=e.clickMap,c=e.maxBranchLen,u=e.maxDepthToLeaf,d=e.blockSizeYOverride,f=n.fontSize,p=n.showBranchLenEffective,h=n.treeMetadata,g=n.blockSize,m=n.labelsAlignRight,A=n.drawTree,b=n.treeAreaWidth,v=n.treeAreaWidthMinusMargin,y=n.marginLeft,w=n.leaves,C=n.noTree,S=n.labelWidthMap,x=null!=d?d:g,E=o.measureText("M").width;m?(o.textAlign="right",o.setLineDash([1,3])):o.textAlign="start";var I,k=function(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return i(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?i(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,l=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return l=e.done,e},e:function(e){s=!0,a=e},f:function(){try{l||null==n.return||n.return()}finally{if(s)throw a}}}}(w);try{for(k.s();!(I=k.n()).done;){var R,M=I.value,P=M.data,B=P.name,_=P.id,T=M.x,O=(null===(R=h[B])||void 0===R?void 0:R.genome)||B;if(T>r-5&&T<r+x+5){var D,N,L=T+f/4,F=0;C||(F=null!==(N=s(M,p,c,u))&&void 0!==N?N:0);var Q=null!==(D=S.get(B))&&void 0!==D?D:o.measureText(O).width;if(o.fillStyle=t.palette.text.primary,m){var j=v-2;A&&!C&&(o.moveTo(F+l+2,T),o.lineTo(j-2-Q,T),o.stroke()),o.fillText(O,j,L),null==a||a.insert({minX:b-Q,maxX:b,minY:L-E,maxY:L,name:B,id:_})}else{var z=C?2:F+5;o.fillText(O,z,L),null==a||a.insert({minX:z+y,maxX:z+Q+y,minY:L-E,maxY:L,name:B,id:_})}}}}catch(e){k.e(e)}finally{k.f()}o.setLineDash([])}({ctx:a,offsetY:c,model:t,clickMap:n,theme:u,maxBranchLen:w,maxDepthToLeaf:C,blockSizeYOverride:f}),null==n||n.finish()}},4567(e,t,n){"use strict";function r(){var e,t,n="function"==typeof Symbol?Symbol:{},i=n.iterator||"@@iterator",a=n.toStringTag||"@@toStringTag";function l(n,r,i,a){var l=r&&r.prototype instanceof c?r:c,u=Object.create(l.prototype);return o(u,"_invoke",function(n,r,o){var i,a,l,c=0,u=o||[],d=!1,f={p:0,n:0,v:e,a:p,f:p.bind(e,4),d:function(t,n){return i=t,a=0,l=e,f.n=n,s}};function p(n,r){for(a=n,l=r,t=0;!d&&c&&!o&&t<u.length;t++){var o,i=u[t],p=f.p,h=i[2];n>3?(o=h===r)&&(l=i[(a=i[4])?5:(a=3,3)],i[4]=i[5]=e):i[0]<=p&&((o=n<2&&p<i[1])?(a=0,f.v=r,f.n=i[1]):p<h&&(o=n<3||i[0]>r||r>h)&&(i[4]=n,i[5]=r,f.n=h,a=0))}if(o||n>1)return s;throw d=!0,r}return function(o,u,h){if(c>1)throw TypeError("Generator is already running");for(d&&1===u&&p(u,h),a=u,l=h;(t=a<2?e:l)||!d;){i||(a?a<3?(a>1&&(f.n=-1),p(a,l)):f.n=l:f.v=l);try{if(c=2,i){if(a||(o="next"),t=i[o]){if(!(t=t.call(i,l)))throw TypeError("iterator result is not an object");if(!t.done)return t;l=t.value,a<2&&(a=0)}else 1===a&&(t=i.return)&&t.call(i),a<2&&(l=TypeError("The iterator does not provide a '"+o+"' method"),a=1);i=e}else if((t=(d=f.n<0)?l:n.call(r,f))!==s)break}catch(t){i=e,a=1,l=t}finally{c=1}}return{value:t,done:d}}}(n,i,a),!0),u}var s={};function c(){}function u(){}function d(){}t=Object.getPrototypeOf;var f=[][i]?t(t([][i]())):(o(t={},i,function(){return this}),t),p=d.prototype=c.prototype=Object.create(f);function h(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,d):(e.__proto__=d,o(e,a,"GeneratorFunction")),e.prototype=Object.create(p),e}return u.prototype=d,o(p,"constructor",d),o(d,"constructor",u),u.displayName="GeneratorFunction",o(d,a,"GeneratorFunction"),o(p),o(p,a,"Generator"),o(p,i,function(){return this}),o(p,"toString",function(){return"[object Generator]"}),(r=function(){return{w:l,m:h}})()}function o(e,t,n,r){var i=Object.defineProperty;try{i({},"",{})}catch(e){i=0}o=function(e,t,n,r){function a(t,n){o(e,t,function(e){return this._invoke(t,n,e)})}t?i?i(e,t,{value:n,enumerable:!r,configurable:!r,writable:!r}):e[t]=n:(a("next",0),a("throw",1),a("return",2))},o(e,t,n,r)}function i(e,t,n,r,o,i,a){try{var l=e[i](a),s=l.value}catch(e){return void n(e)}l.done?t(s):Promise.resolve(s).then(r,o)}function a(e){return function(){var t=this,n=arguments;return new Promise(function(r,o){var a=e.apply(t,n);function l(e){i(a,r,o,l,s,"next",e)}function s(e){i(a,r,o,l,s,"throw",e)}l(void 0)})}}function l(e,t){return s.apply(this,arguments)}function s(){return(s=a(r().m(function e(t,n){var o,i,a,l;return r().w(function(e){for(;;)switch(e.n){case 0:return e.n=1,fetch(t,n);case 1:if((o=e.v).ok){e.n=3;break}return i=Error,a="HTTP ".concat(o.status," fetching ").concat(t," "),e.n=2,o.text();case 2:throw l=a.concat.call(a,e.v),new i(l);case 3:return e.a(2,o)}},e)}))).apply(this,arguments)}function c(e,t){return u.apply(this,arguments)}function u(){return(u=a(r().m(function e(t,n){var o;return r().w(function(e){for(;;)switch(e.n){case 0:return e.n=1,l(t,n);case 1:return o=e.v,e.a(2,o.text())}},e)}))).apply(this,arguments)}function d(e,t){return f.apply(this,arguments)}function f(){return(f=a(r().m(function e(t,n){var o;return r().w(function(e){for(;;)switch(e.n){case 0:return e.n=1,l(t,n);case 1:return o=e.v,e.a(2,o.json())}},e)}))).apply(this,arguments)}function p(e,t){return new Promise(function(n,r){if(null!=t&&t.aborted)r(new DOMException("Aborted","AbortError"));else{var o=setTimeout(n,e);null==t||t.addEventListener("abort",function(){clearTimeout(o),r(new DOMException("Aborted","AbortError"))})}})}function h(e){return e instanceof DOMException&&"AbortError"===e.name}n.d(t,{jT:()=>d,wR:()=>p,y1:()=>c,zf:()=>h})},3431(e,t,n){"use strict";n.d(t,{A:()=>i,S:()=>o});var r=[["#F8766D"],["#F8766D","#00BFC4"],["#F8766D","#00BA38","#619CFF"],["#F8766D","#7CAE00","#00BFC4","#C77CFF"],["#F8766D","#A3A500","#00BF7D","#00B0F6","#E76BF3"],["#F8766D","#B79F00","#00BA38","#00BFC4","#619CFF","#F564E3"],["#F8766D","#C49A00","#53B400","#00C094","#00B6EB","#A58AFF","#FB61D7"],["#F8766D","#CD9600","#7CAE00","#00BE67","#00BFC4","#00A9FF","#C77CFF","#FF61CC"]];function o(e){return r[Math.min(e,r.length-1)]}const i=r},7335(e,t,n){"use strict";function r(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return o(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?o(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,l=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return l=e.done,e},e:function(e){s=!0,a=e},f:function(){try{l||null==n.return||n.return()}finally{if(s)throw a}}}}function o(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function i(e){for(var t=[],n=[e];n.length>0;){var r=n.pop();if(t.push(r),r.children)for(var o=r.children.length-1;o>=0;o--)n.push(r.children[o])}return t}function a(e,t){for(var n={data:e,children:null,parent:null,depth:0,height:0},o=[n],a=function(){var e=o.pop(),n=t(e.data);if(null!=n&&n.length){e.children=n.map(function(t){return{data:t,children:null,parent:e,depth:e.depth+1,height:0}});var i,a=r(e.children);try{for(a.s();!(i=a.n()).done;){var l=i.value;o.push(l)}}catch(e){a.e(e)}finally{a.f()}}};o.length>0;)a();return function(e){for(var t=i(e),n=t.length-1;n>=0;n--){var o=t[n],a=0;if(o.children){var l,s=r(o.children);try{for(s.s();!(l=s.n()).done;){var c=l.value;c.height+1>a&&(a=c.height+1)}}catch(e){s.e(e)}finally{s.f()}}o.height=a}}(n),n}function l(e,t){for(var n=i(e),o=n.length-1;o>=0;o--){var a=n[o],l=t(a.data);if(a.children){var s,c=r(a.children);try{for(c.s();!(s=c.n()).done;)l+=s.value.value}catch(e){c.e(e)}finally{c.f()}}a.value=l}return e}function s(e,t){for(var n=[e];n.length>0;){var o=n.pop();if(o.children){o.children.sort(t);var i,a=r(o.children);try{for(a.s();!(i=a.n()).done;){var l=i.value;n.push(l)}}catch(e){a.e(e)}finally{a.f()}}}return e}function c(e,t){for(var n,r=[e];r.length>0&&void 0===n;){var o=r.pop();if(t(o))n=o;else if(o.children)for(var i=o.children.length-1;i>=0;i--)r.push(o.children[i])}return n}function u(e){for(var t=[],n=[e];n.length>0;){var r=n.pop();if(r.children)for(var o=r.children.length-1;o>=0;o--)n.push(r.children[o]);else t.push(r)}return t}function d(e){var t=[];return f(e,function(e,n){t.push({source:e,target:n})}),t}function f(e,t){for(var n=[e];n.length>0;){var r=n.pop();if(r.children)for(var o=r.children.length-1;o>=0;o--){var i=r.children[o];t(r,i),n.push(i)}}}function p(e,t){var n,o=r(i(e));try{for(o.s();!(n=o.n()).done;)t(n.value)}catch(e){o.e(e)}finally{o.f()}}function h(e,t,n){for(var o=u(e),a=o.length,l=t/a,s=0;s<a;s++)o[s].x=(s+.5)*l;for(var c=i(e),d=c.length-1;d>=0;d--){var f=c[d];if(f.children){var p,h=0,g=r(f.children);try{for(g.s();!(p=g.n()).done;)h+=p.value.x}catch(e){g.e(e)}finally{g.f()}f.x=h/f.children.length}}for(var m=e.height,A=[{node:e,depth:0}];A.length>0;){var b=A.pop(),v=b.node,y=b.depth;if(v.y=0===m?n:y/m*n,v.children){var w,C=r(v.children);try{for(C.s();!(w=C.n()).done;){var S=w.value;A.push({node:S,depth:y+1})}}catch(e){C.e(e)}finally{C.f()}}}}function g(e){e.children&&(e._children=e.children,e.children=null)}function m(e){for(var t=i(e),n=t.length-1;n>=0;n--){var o=t[n];if(void 0===o.depthToLeaf){var a=0;if(o.children){var l,s=r(o.children);try{for(s.s();!(l=s.n()).done;){var c=l.value;a=Math.max(a,1+c.depthToLeaf)}}catch(e){s.e(e)}finally{s.f()}}o.depthToLeaf=a}}return e.depthToLeaf}function A(e){var t,n=0,o=r(i(e));try{for(o.s();!(t=o.n()).done;){var a=t.value;n=Math.max(n,a.len||0)}}catch(e){o.e(e)}finally{o.f()}return n}function b(e){for(var t=i(e),n=new Map,o=t.length-1;o>=0;o--){var a=t[o],l=0;if(a.children){var s,c=r(a.children);try{for(c.s();!(s=c.n()).done;){var u=s.value;l=Math.max(l,n.get(u))}}catch(e){c.e(e)}finally{c.f()}}n.set(a,(a.data.length||0)+l)}return n.get(e)}function v(e,t,n){for(var o=[{node:e,y0:t}];o.length>0;){var i=o.pop(),a=i.node,l=i.y0+Math.max(a.data.length||0,0);if(a.len=l*n,a.children){var s,c=r(a.children);try{for(c.s();!(s=c.n()).done;){var u=s.value;o.push({node:u,y0:l})}}catch(e){c.e(e)}finally{c.f()}}}}n.d(t,{FQ:()=>u,Fj:()=>h,I6:()=>c,Ru:()=>b,Sk:()=>a,ap:()=>g,cz:()=>l,di:()=>s,jm:()=>A,rX:()=>f,ul:()=>p,wt:()=>m,yJ:()=>d,zu:()=>v})},3714(e,t,n){"use strict";n.r(t),n.d(t,{renderToSvg:()=>b});var r=n(405),o=n(6081),i=n(5597),a=n(2020),l=n(2700);const s=(0,a.PA)(function(e){var t=e.model,n=t.msaAreaWidth,o=(0,l.a)(t),i=o.s,a=o.w,s=o.polygonPoints,c="rgb(66, 119, 127)";return r.createElement(r.Fragment,null,r.createElement("rect",{x:0,y:0,width:n,height:l.S,stroke:"#555",fill:"none"}),r.createElement("rect",{x:Math.max(0,i),y:0,width:a,height:l.S,fill:c,fillOpacity:.3,stroke:"#555"}),r.createElement("g",{transform:"translate(0 ".concat(l.S,")")},r.createElement("polygon",{fill:c,fillOpacity:.3,points:s})))});var c=n(1739),u=n(5374),d=n(2012),f=n(1856),p=n(9168);function h(){var e,t,n="function"==typeof Symbol?Symbol:{},r=n.iterator||"@@iterator",o=n.toStringTag||"@@toStringTag";function i(n,r,o,i){var s=r&&r.prototype instanceof l?r:l,c=Object.create(s.prototype);return g(c,"_invoke",function(n,r,o){var i,l,s,c=0,u=o||[],d=!1,f={p:0,n:0,v:e,a:p,f:p.bind(e,4),d:function(t,n){return i=t,l=0,s=e,f.n=n,a}};function p(n,r){for(l=n,s=r,t=0;!d&&c&&!o&&t<u.length;t++){var o,i=u[t],p=f.p,h=i[2];n>3?(o=h===r)&&(s=i[(l=i[4])?5:(l=3,3)],i[4]=i[5]=e):i[0]<=p&&((o=n<2&&p<i[1])?(l=0,f.v=r,f.n=i[1]):p<h&&(o=n<3||i[0]>r||r>h)&&(i[4]=n,i[5]=r,f.n=h,l=0))}if(o||n>1)return a;throw d=!0,r}return function(o,u,h){if(c>1)throw TypeError("Generator is already running");for(d&&1===u&&p(u,h),l=u,s=h;(t=l<2?e:s)||!d;){i||(l?l<3?(l>1&&(f.n=-1),p(l,s)):f.n=s:f.v=s);try{if(c=2,i){if(l||(o="next"),t=i[o]){if(!(t=t.call(i,s)))throw TypeError("iterator result is not an object");if(!t.done)return t;s=t.value,l<2&&(l=0)}else 1===l&&(t=i.return)&&t.call(i),l<2&&(s=TypeError("The iterator does not provide a '"+o+"' method"),l=1);i=e}else if((t=(d=f.n<0)?s:n.call(r,f))!==a)break}catch(t){i=e,l=1,s=t}finally{c=1}}return{value:t,done:d}}}(n,o,i),!0),c}var a={};function l(){}function s(){}function c(){}t=Object.getPrototypeOf;var u=[][r]?t(t([][r]())):(g(t={},r,function(){return this}),t),d=c.prototype=l.prototype=Object.create(u);function f(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,c):(e.__proto__=c,g(e,o,"GeneratorFunction")),e.prototype=Object.create(d),e}return s.prototype=c,g(d,"constructor",c),g(c,"constructor",s),s.displayName="GeneratorFunction",g(c,o,"GeneratorFunction"),g(d),g(d,o,"Generator"),g(d,r,function(){return this}),g(d,"toString",function(){return"[object Generator]"}),(h=function(){return{w:i,m:f}})()}function g(e,t,n,r){var o=Object.defineProperty;try{o({},"",{})}catch(e){o=0}g=function(e,t,n,r){function i(t,n){g(e,t,function(e){return this._invoke(t,n,e)})}t?o?o(e,t,{value:n,enumerable:!r,configurable:!r,writable:!r}):e[t]=n:(i("next",0),i("throw",1),i("return",2))},g(e,t,n,r)}function m(e,t,n,r,o,i,a){try{var l=e[i](a),s=l.value}catch(e){return void n(e)}l.done?t(s):Promise.resolve(s).then(r,o)}function A(e){return function(){var t=this,n=arguments;return new Promise(function(r,o){var i=e.apply(t,n);function a(e){m(i,r,o,a,l,"next",e)}function l(e){m(i,r,o,a,l,"throw",e)}a(void 0)})}}function b(e,t){return v.apply(this,arguments)}function v(){return(v=A(h().m(function e(t,n){var r,o,a,l,s,c,u,d,f,p,g;return h().w(function(e){for(;;)switch(e.n){case 0:return e.n=1,(0,i.z7)(function(){return t.dataInitialized});case 1:if(r=t.width,o=t.height,a=t.scrollX,l=t.scrollY,s=t.totalTrackAreaHeight,c=t.minimapHeight,u=n.exportType,d=n.theme,f=n.includeTracks,p=f?s:0,g="viewport"===u&&!!n.includeMinimap,"entire"!==u){e.n=2;break}return e.a(2,y({width:t.totalWidth+t.treeAreaWidth,height:t.totalHeight+p,contentHeight:t.totalHeight,trackHeight:p,theme:d,model:t,offsetY:0,offsetX:0,includeMinimap:g,includeTracks:f}));case 2:return e.a(2,y({width:r,height:o+(g?c:0)+p,contentHeight:o,trackHeight:p,theme:d,model:t,offsetY:-l,offsetX:-a,includeMinimap:g,includeTracks:f}))}},e)}))).apply(this,arguments)}function y(e){return w.apply(this,arguments)}function w(){return(w=A(h().m(function e(t){var i,a,l,c,u,d,f,p,g,m,A,b,v,y,w;return h().w(function(e){for(;;)switch(e.n){case 0:return i=t.width,a=t.height,l=t.contentHeight,c=t.trackHeight,u=t.offsetX,d=t.offsetY,f=t.theme,p=t.model,g=t.includeMinimap,m=t.includeTracks,e.n=1,Promise.resolve().then(n.bind(n,7085));case 1:return A=e.v,b=A.Context,v=p.treeAreaWidth,y=p.minimapHeight,w=r.createElement(r.Fragment,null,m&&c>0?r.createElement(x,{Context:b,model:p,theme:f,offsetX:u,msaAreaWidth:i-v,trackHeight:c}):null,r.createElement("g",{transform:c>0?"translate(0 ".concat(c,")"):void 0},r.createElement(C,{Context:b,model:p,theme:f,offsetX:u,offsetY:d,msaAreaWidth:i-v,contentHeight:l}))),e.a(2,(0,o.qVg)(r.createElement(E,{width:i,height:a},g?r.createElement(r.Fragment,null,r.createElement("g",{transform:"translate(".concat(v," 0)")},r.createElement(s,{model:p})),r.createElement("g",{transform:"translate(0 ".concat(y,")")},w)):w)))}},e)}))).apply(this,arguments)}function C(e){var t=e.model,n=e.theme,o=e.msaAreaWidth,i=e.contentHeight,a=e.offsetX,l=e.offsetY,s=e.Context,d=t.treeAreaWidth,h=t.colorScheme,g=t.id,m="tree-".concat(g),A="msa-".concat(g),b=(0,p.Sl)(h,n),v=new s(d,i),y=new s(o,i);return(0,c.X)({ctx:y,offsetX:a,offsetY:l,model:t,blockSizeYOverride:i,highResScaleFactorOverride:1}),(0,f.t0)({model:t,offsetY:l,ctx:v,theme:n,blockSizeYOverride:i,highResScaleFactorOverride:1}),(0,u.H)({model:t,theme:n,offsetY:l,offsetX:a,contrastScheme:b,ctx:y,blockSizeXOverride:o,blockSizeYOverride:i,highResScaleFactorOverride:1}),r.createElement(r.Fragment,null,r.createElement("defs",null,r.createElement("clipPath",{id:m},r.createElement("rect",{x:0,y:0,width:d,height:i})),r.createElement("clipPath",{id:A},r.createElement("rect",{x:0,y:0,width:o,height:i}))),r.createElement(S,{clipId:m,html:v.getSvg().innerHTML}),r.createElement(S,{clipId:A,transform:"translate(".concat(d," 0)"),html:y.getSvg().innerHTML}))}function S(e){var t=e.clipId,n=e.html,o=e.transform;return r.createElement("g",{clipPath:"url(#".concat(t,")"),transform:o,dangerouslySetInnerHTML:{__html:n}})}function x(e){var t=e.model,n=e.theme,o=e.msaAreaWidth,i=e.trackHeight,a=e.offsetX,l=e.Context,s=t.treeAreaWidth,c=t.colorScheme,u=t.id,f="tracks-".concat(u),h=(0,p.Sl)(c,n),g=new l(o,i);return(0,d.ay)({model:t,ctx:g,offsetX:a,contrastScheme:h,blockSizeXOverride:o,highResScaleFactorOverride:1}),r.createElement("g",{transform:"translate(".concat(s," 0)")},r.createElement("defs",null,r.createElement("clipPath",{id:f},r.createElement("rect",{x:0,y:0,width:o,height:i}))),r.createElement(S,{clipId:f,html:g.getSvg().innerHTML}))}function E(e){var t=e.width,n=e.height,o=e.children;return r.createElement("svg",{width:t,height:n,xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",viewBox:"0 0 ".concat(t," ").concat(n)},r.createElement("rect",{width:"100%",height:"100%",fill:"white"}),o)}},9444(e,t,n){"use strict";function r(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];e.font=e.font.replace(/(?:bold )?[\d.]+px/,"".concat(n?"bold ":"").concat(t,"px"))}n.d(t,{X:()=>r})},9168(e,t,n){"use strict";n.d(t,{uL:()=>u,Sl:()=>f,i8:()=>h,z3:()=>m,Il:()=>g,pw:()=>p,pd:()=>d});var r=n(5070),o=function(e){var t=e/255;return t<.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)},i=function(e){return.2126*o(e.r)+.7152*o(e.g)+.0722*o(e.b)},a=n(711);function l(e,t){if(e){if("string"==typeof e)return s(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?s(e,t):void 0}}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}(0,r.X$)([a.A,function(e){e.prototype.luminance=function(){return e=i(this.rgba),void 0===(t=2)&&(t=0),void 0===n&&(n=Math.pow(10,t)),Math.round(n*e)/n+0;var e,t,n},e.prototype.contrast=function(t){void 0===t&&(t="#FFF");var n,r,o,a,l,s,c,u=t instanceof e?t:new e(t);return a=this.rgba,l=u.toRgb(),n=(s=i(a))>(c=i(l))?(s+.05)/(c+.05):(c+.05)/(s+.05),void 0===(r=2)&&(r=0),void 0===o&&(o=Math.pow(10,r)),Math.floor(o*n)/o+0},e.prototype.isReadable=function(e,t){return void 0===e&&(e="#FFF"),void 0===t&&(t={}),this.contrast(e)>=(a=void 0===(i=(n=t).size)?"normal":i,"AAA"===(o=void 0===(r=n.level)?"AA":r)&&"normal"===a?7:"AA"===o&&"large"===a?3:4.5);var n,r,o,i,a}}]);var c=new Map;function u(e,t){var n="".concat(e,"|").concat(t),o=c.get(n);if(void 0!==o)return o;var i=(0,r.Mj)(e);if(!i.isReadable(t))for(var a=(0,r.Mj)(t).luminance()<.5,l=0;l<40&&!i.isReadable(t);l++)i=a?i.lighten(.05):i.darken(.05);var s=i.toHex();return c.set(n,s),s}function d(e,t){return Object.fromEntries(Object.entries(e).map(t))}function f(e,t){return d(e,function(e){var n,o,i=(o=2,function(e){if(Array.isArray(e))return e}(n=e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,l=[],s=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){c=!0,o=e}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw o}}return l}}(n,o)||l(n,o)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),a=i[0],s=i[1];return[a,t.palette.getContrastText((0,r.Mj)(s).toHex())]})}function p(e,t){if(0===e.length)return t;var n,r=[],o=0,i=function(e){var t="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!t){if(Array.isArray(e)||(t=l(e))){t&&(e=t);var n=0,r=function(){};return{s:r,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:r}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,i=!0,a=!1;return{s:function(){t=t.call(e)},n:function(){var e=t.next();return i=e.done,e},e:function(e){a=!0,o=e},f:function(){try{i||null==t.return||t.return()}finally{if(a)throw o}}}}(e);try{for(i.s();!(n=i.n()).done;){var a=n.value;a>o&&r.push(t.slice(o,a)),o=a+1}}catch(e){i.e(e)}finally{i.f()}return o<t.length&&r.push(t.slice(o)),r.join("")}function h(e,t){for(var n=[],r=e.length,o=0,i=0,a=-1,l=[],s=0;s<t.length;s++)i<r&&e[i]===s?(t.charCodeAt(s)-45>>>0<=1||(a===o?l.push(t[s]):(l.length>0&&n.push({pos:a,letters:l.join("")}),a=o,l=[t[s]])),i++):o++;return l.length>0&&n.push({pos:a,letters:l.join("")}),n}function g(e){return e.end-e.start}function m(e){return"-"===e||"."===e}},8053(e,t,n){"use strict";function r(e){var t=navigator.clipboard;if(null!=t&&t.writeText)t.writeText(e).catch(function(e){console.error("Failed to copy to clipboard:",e)});else{var n=document.createElement("textarea");n.value=e,n.style.position="fixed",n.style.opacity="0",document.body.append(n),n.select(),document.execCommand("copy"),n.remove()}}n.d(t,{A:()=>r})},9585(e,t,n){"use strict";var r=n(9687),o={"text/plain":"Text","text/html":"Url",default:"Text"};e.exports=function(e,t){var n,i,a,l,s,c,u=!1;t||(t={}),n=t.debug||!1;try{if(a=r(),l=document.createRange(),s=document.getSelection(),(c=document.createElement("span")).textContent=e,c.ariaHidden="true",c.style.all="unset",c.style.position="fixed",c.style.top=0,c.style.clip="rect(0, 0, 0, 0)",c.style.whiteSpace="pre",c.style.webkitUserSelect="text",c.style.MozUserSelect="text",c.style.msUserSelect="text",c.style.userSelect="text",c.addEventListener("copy",function(r){if(r.stopPropagation(),t.format)if(r.preventDefault(),void 0===r.clipboardData){n&&console.warn("unable to use e.clipboardData"),n&&console.warn("trying IE specific stuff"),window.clipboardData.clearData();var i=o[t.format]||o.default;window.clipboardData.setData(i,e)}else r.clipboardData.clearData(),r.clipboardData.setData(t.format,e);t.onCopy&&(r.preventDefault(),t.onCopy(r.clipboardData))}),document.body.appendChild(c),l.selectNodeContents(c),s.addRange(l),!document.execCommand("copy"))throw new Error("copy command was unsuccessful");u=!0}catch(r){n&&console.error("unable to copy using execCommand: ",r),n&&console.warn("trying IE specific stuff");try{window.clipboardData.setData(t.format||"text",e),t.onCopy&&t.onCopy(window.clipboardData),u=!0}catch(r){n&&console.error("unable to copy using clipboardData: ",r),n&&console.error("falling back to prompt"),i=function(e){var t=(/mac os x/i.test(navigator.userAgent)?"⌘":"Ctrl")+"+C";return e.replace(/#{\s*key\s*}/g,t)}("message"in t?t.message:"Copy to clipboard: #{key}, Enter"),window.prompt(i,e)}}finally{s&&("function"==typeof s.removeRange?s.removeRange(l):s.removeAllRanges()),c&&document.body.removeChild(c),a()}return u}},8361(e){e.exports=!1},8018(e){"use strict";var t=/["'&<>]/;e.exports=function(e){var n,r=""+e,o=t.exec(r);if(!o)return r;var i="",a=0,l=0;for(a=o.index;a<r.length;a++){switch(r.charCodeAt(a)){case 34:n=""";break;case 38:n="&";break;case 39:n="'";break;case 60:n="<";break;case 62:n=">";break;default:continue}l!==a&&(i+=r.substring(l,a)),l=a+1,i+=n}return l!==a?i+r.substring(l,a):i}},4674(e,t,n){"use strict";var r=n(7020),o={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},i={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},a={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},l={};function s(e){return r.isMemo(e)?a:l[e.$$typeof]||o}l[r.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},l[r.Memo]=a;var c=Object.defineProperty,u=Object.getOwnPropertyNames,d=Object.getOwnPropertySymbols,f=Object.getOwnPropertyDescriptor,p=Object.getPrototypeOf,h=Object.prototype;e.exports=function e(t,n,r){if("string"!=typeof n){if(h){var o=p(n);o&&o!==h&&e(t,o,r)}var a=u(n);d&&(a=a.concat(d(n)));for(var l=s(t),g=s(n),m=0;m<a.length;++m){var A=a[m];if(!(i[A]||r&&r[A]||g&&g[A]||l&&l[A])){var b=f(n,A);try{c(t,A,b)}catch(e){}}}}return t}},2020(e,t,n){"use strict";n.d(t,{PA:()=>T});var r=n(5597),o=n(405);if(!o.useState)throw new Error("mobx-react-lite requires React with Hooks support");if(!r.Gn)throw new Error("mobx-react-lite@3 requires mobx at least version 6 to be available");var i=n(7868);function a(e){return(0,r.yl)(e)}var l,s,c=function(){function e(e){var t=this;Object.defineProperty(this,"finalize",{enumerable:!0,configurable:!0,writable:!0,value:e}),Object.defineProperty(this,"registrations",{enumerable:!0,configurable:!0,writable:!0,value:new Map}),Object.defineProperty(this,"sweepTimeout",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"sweep",{enumerable:!0,configurable:!0,writable:!0,value:function(e){void 0===e&&(e=1e4),clearTimeout(t.sweepTimeout),t.sweepTimeout=void 0;var n=Date.now();t.registrations.forEach(function(r,o){n-r.registeredAt>=e&&(t.finalize(r.value),t.registrations.delete(o))}),t.registrations.size>0&&t.scheduleSweep()}}),Object.defineProperty(this,"finalizeAllImmediately",{enumerable:!0,configurable:!0,writable:!0,value:function(){t.sweep(0)}})}return Object.defineProperty(e.prototype,"register",{enumerable:!1,configurable:!0,writable:!0,value:function(e,t,n){this.registrations.set(n,{value:t,registeredAt:Date.now()}),this.scheduleSweep()}}),Object.defineProperty(e.prototype,"unregister",{enumerable:!1,configurable:!0,writable:!0,value:function(e){this.registrations.delete(e)}}),Object.defineProperty(e.prototype,"scheduleSweep",{enumerable:!1,configurable:!0,writable:!0,value:function(){void 0===this.sweepTimeout&&(this.sweepTimeout=setTimeout(this.sweep,1e4))}}),e}(),u=new("undefined"!=typeof FinalizationRegistry?FinalizationRegistry:c)(function(e){var t;null===(t=e.reaction)||void 0===t||t.dispose(),e.reaction=null}),d=n(524);function f(e){e.reaction=new r.qT("observer".concat(e.name),function(){var t;e.stateVersion=Symbol(),null===(t=e.onStoreChange)||void 0===t||t.call(e)})}var p="function"==typeof Symbol&&Symbol.for,h=null!==(s=null===(l=Object.getOwnPropertyDescriptor(function(){},"name"))||void 0===l?void 0:l.configurable)&&void 0!==s&&s,g=p?Symbol.for("react.forward_ref"):"function"==typeof o.forwardRef&&(0,o.forwardRef)(function(e){return null}).$$typeof,m=p?Symbol.for("react.memo"):"function"==typeof o.memo&&(0,o.memo)(function(e){return null}).$$typeof;function A(e,t){var n;if(m&&e.$$typeof===m)throw new Error("[mobx-react-lite] You are trying to use `observer` on a function component wrapped in either another `observer` or `React.memo`. The observer already applies 'React.memo' for you.");var r=null!==(n=null==t?void 0:t.forwardRef)&&void 0!==n&&n,i=e,l=e.displayName||e.name;if(g&&e.$$typeof===g&&(r=!0,"function"!=typeof(i=e.render)))throw new Error("[mobx-react-lite] `render` property of ForwardRef was not a function");var s,c,p=function(e,t){return function(e,t){void 0===t&&(t="observed");var n=o.useRef(null);if(!n.current){var r={reaction:null,onStoreChange:null,stateVersion:Symbol(),name:t,subscribe:function(e){return u.unregister(r),r.onStoreChange=e,r.reaction||(f(r),r.stateVersion=Symbol()),function(){var e;r.onStoreChange=null,null===(e=r.reaction)||void 0===e||e.dispose(),r.reaction=null}},getSnapshot:function(){return r.stateVersion}};n.current=r}var i,l,s=n.current;if(s.reaction||(f(s),u.register(n,s,s)),o.useDebugValue(s.reaction,a),(0,d.useSyncExternalStore)(s.subscribe,s.getSnapshot,s.getSnapshot),s.reaction.track(function(){try{i=e()}catch(e){l=e}}),l)throw l;return i}(function(){return i(e,t)},l)};return p.displayName=e.displayName,h&&Object.defineProperty(p,"name",{value:e.name,writable:!0,configurable:!0}),e.contextTypes&&(p.contextTypes=e.contextTypes),r&&(p=(0,o.forwardRef)(p)),p=(0,o.memo)(p),s=e,c=p,Object.keys(s).forEach(function(e){v[e]||Object.defineProperty(c,e,Object.getOwnPropertyDescriptor(s,e))}),p}var b,v={$$typeof:!0,render:!0,compare:!0,type:!0,displayName:!0};function y(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}(b=i.unstable_batchedUpdates)||(b=function(e){e()}),(0,r.jK)({reactionScheduler:b}),u.finalizeAllImmediately;var w=Symbol("patchMixins"),C=Symbol("patchedDefinition");function S(e,t){for(var n=this,r=arguments.length,o=new Array(r>2?r-2:0),i=2;i<r;i++)o[i-2]=arguments[i];t.locks++;try{var a;return null!=e&&(a=e.apply(this,o)),a}finally{t.locks--,0===t.locks&&t.methods.forEach(function(e){e.apply(n,o)})}}function x(e,t){return function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];S.call.apply(S,[this,e,t].concat(r))}}function E(e,t,n){var r=function(e,t){var n=e[w]=e[w]||{},r=n[t]=n[t]||{};return r.locks=r.locks||0,r.methods=r.methods||[],r}(e,t);r.methods.indexOf(n)<0&&r.methods.push(n);var o=Object.getOwnPropertyDescriptor(e,t);if(!o||!o[C]){var i=e[t],a=I(e,t,o?o.enumerable:void 0,r,i);Object.defineProperty(e,t,a)}}function I(e,t,n,r,o){var i,a=x(o,r);return(i={})[C]=!0,i.get=function(){return a},i.set=function(o){if(this===e)a=x(o,r);else{var i=I(this,t,n,r,o);Object.defineProperty(this,t,i)}},i.configurable=!0,i.enumerable=n,i}var k=Symbol("ObserverAdministration"),R=Symbol("isMobXReactObserver");function M(e){var t;return null!=(t=e[k])?t:e[k]={reaction:null,mounted:!1,reactionInvalidatedBeforeMount:!1,forceUpdate:null,name:P(e.constructor),state:void 0,props:void 0,context:void 0}}function P(e){return e.displayName||e.name||"<component>"}function B(e){var t=e.bind(this),n=M(this);return function(){n.reaction||(n.reaction=function(e){return new r.qT(e.name+".render()",function(){if(e.mounted)try{null==e.forceUpdate||e.forceUpdate()}catch(n){var t;null==(t=e.reaction)||t.dispose(),e.reaction=null}else e.reactionInvalidatedBeforeMount=!0})}(n),n.mounted||u.register(this,n,this));var e=void 0,o=void 0;if(n.reaction.track(function(){try{o=(0,r.vx)(!1,t)}catch(t){e=t}}),e)throw e;return o}}function _(e,t){return this.state!==t||!function(e,t){if(y(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(var o=0;o<n.length;o++)if(!Object.hasOwnProperty.call(t,n[o])||!y(e[n[o]],t[n[o]]))return!1;return!0}(this.props,e)}function T(e,t){if(t&&"class"!==t.kind)throw new Error("The @observer decorator can be used on classes only");return!0===e.isMobxInjector&&console.warn("Mobx observer: You are trying to use `observer` on a component that already has `inject`. Please apply `observer` before applying `inject`"),Object.prototype.isPrototypeOf.call(o.Component,e)||Object.prototype.isPrototypeOf.call(o.PureComponent,e)?function(e){var t=e.prototype;if(e[R]){var n=P(e);throw new Error("The provided component class ("+n+") has already been declared as an observer component.")}if(e[R]=!0,t.componentWillReact)throw new Error("The componentWillReact life-cycle event is no longer supported");if(e.__proto__!==o.PureComponent)if(t.shouldComponentUpdate){if(t.shouldComponentUpdate!==_)throw new Error("It is not allowed to use shouldComponentUpdate in observer based components.")}else t.shouldComponentUpdate=_;var r=t.render;if("function"!=typeof r){var i=P(e);throw new Error("[mobx-react] class component ("+i+") is missing `render` method.\n`observer` requires `render` being a function defined on prototype.\n`render = () => {}` or `render = function() {}` is not supported.")}t.render=function(){return Object.defineProperty(this,"render",{configurable:!1,writable:!1,value:B.call(this,r)}),this.render()};var a=t.componentDidMount;return t.componentDidMount=function(){var e=this,t=M(this);return t.mounted=!0,u.unregister(this),t.forceUpdate=function(){return e.forceUpdate()},t.reaction&&!t.reactionInvalidatedBeforeMount||t.forceUpdate(),null==a?void 0:a.apply(this,arguments)},E(t,"componentWillUnmount",function(){var e,t=M(this);null==(e=t.reaction)||e.dispose(),t.reaction=null,t.forceUpdate=null,t.mounted=!1,t.reactionInvalidatedBeforeMount=!1}),e}(e):A(e)}if(o.version,!o.Component)throw new Error("mobx-react requires React to be available");if(!r.sH)throw new Error("mobx-react requires mobx to be available")},5597(e,t,n){"use strict";function r(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];throw new Error("number"==typeof e?"[MobX] minified error nr: "+e+(n.length?" "+n.map(String).join(","):"")+". Find the full error at: https://github.com/mobxjs/mobx/blob/main/packages/mobx/src/errors.ts":"[MobX] "+e)}n.d(t,{EW:()=>$e,Es:()=>Gn,Fq:()=>jn,Gn:()=>Rn,MN:()=>Z,Mr:()=>Ar,OB:()=>rr,Rn:()=>An,XI:()=>Qt,Zc:()=>cn,_t:()=>zt,fm:()=>Ht,go:()=>mr,hZ:()=>hn,jK:()=>Jt,jO:()=>pn,lB:()=>mn,mJ:()=>Wt,n8:()=>gn,pA:()=>sn,qT:()=>kt,sG:()=>vt,sH:()=>Fe,vx:()=>Ye,yl:()=>Xt,z7:()=>bn,zu:()=>fn});var o={};function i(){return"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==n.g?n.g:"undefined"!=typeof self?self:o}var a=Object.assign,l=Object.getOwnPropertyDescriptor,s=Object.defineProperty,c=Object.prototype,u=[];Object.freeze(u);var d={};Object.freeze(d);var f="undefined"!=typeof Proxy,p=Object.toString();function h(){f||r("Proxy not available")}function g(e){var t=!1;return function(){if(!t)return t=!0,e.apply(this,arguments)}}var m=function(){};function A(e){return"function"==typeof e}function b(e){switch(typeof e){case"string":case"symbol":case"number":return!0}return!1}function v(e){return null!==e&&"object"==typeof e}function y(e){if(!v(e))return!1;var t=Object.getPrototypeOf(e);if(null==t)return!0;var n=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n.toString()===p}function w(e){var t=null==e?void 0:e.constructor;return!!t&&("GeneratorFunction"===t.name||"GeneratorFunction"===t.displayName)}function C(e,t,n){s(e,t,{enumerable:!1,writable:!0,configurable:!0,value:n})}function S(e,t,n){s(e,t,{enumerable:!1,writable:!1,configurable:!0,value:n})}function x(e,t){var n="isMobX"+e;return t.prototype[n]=!0,function(e){return v(e)&&!0===e[n]}}function E(e){return null!=e&&"[object Map]"===Object.prototype.toString.call(e)}function I(e){return null!=e&&"[object Set]"===Object.prototype.toString.call(e)}var k=void 0!==Object.getOwnPropertySymbols,R="undefined"!=typeof Reflect&&Reflect.ownKeys?Reflect.ownKeys:k?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:Object.getOwnPropertyNames;function M(e){return null===e?null:"object"==typeof e?""+e:e}function P(e,t){return c.hasOwnProperty.call(e,t)}var B=Object.getOwnPropertyDescriptors||function(e){var t={};return R(e).forEach(function(n){t[n]=l(e,n)}),t};function _(e,t){return!!(e&t)}function T(e,t,n){return n?e|=t:e&=~t,e}function O(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function D(e,t,n){if($())return Reflect.construct.apply(null,arguments);var r=[null];r.push.apply(r,t);var o=new(e.bind.apply(e,r));return n&&H(o,n.prototype),o}function N(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,G(r.key),r)}}function L(e,t,n){return t&&N(e.prototype,t),n&&N(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function F(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(n)return(n=n.call(e)).next.bind(n);if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return O(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?O(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function Q(){return Q=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Q.apply(null,arguments)}function j(e){return j=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},j(e)}function z(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,H(e,t)}function $(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return($=function(){return!!e})()}function H(e,t){return H=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},H(e,t)}function G(e){var t=function(e){if("object"!=typeof e||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=typeof n)return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:t+""}function V(e){var t="function"==typeof Map?new Map:void 0;return V=function(e){if(null===e||!function(e){try{return-1!==Function.toString.call(e).indexOf("[native code]")}catch(t){return"function"==typeof e}}(e))return e;if("function"!=typeof e)throw new TypeError("Super expression must either be null or a function");if(void 0!==t){if(t.has(e))return t.get(e);t.set(e,n)}function n(){return D(e,arguments,j(this).constructor)}return n.prototype=Object.create(e.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),H(n,e)},V(e)}var W=Symbol("mobx-stored-annotations");function U(e){return Object.assign(function(t,n){if(Y(n))return e.decorate_20223_(t,n);q(t,n,e)},e)}function q(e,t,n){P(e,W)||C(e,W,Q({},e[W])),function(e){return e.annotationType_===re}(n)||(e[W][t]=n)}function Y(e){return"object"==typeof e&&"string"==typeof e.kind}var K=Symbol("mobx administration"),J=function(){function e(e){void 0===e&&(e="Atom"),this.name_=void 0,this.flags_=0,this.observers_=new Set,this.lastAccessedBy_=0,this.lowestObserverState_=tt.NOT_TRACKING_,this.onBOL=void 0,this.onBUOL=void 0,this.name_=e}var t=e.prototype;return t.onBO=function(){this.onBOL&&this.onBOL.forEach(function(e){return e()})},t.onBUO=function(){this.onBUOL&&this.onBUOL.forEach(function(e){return e()})},t.reportObserved=function(){return Et(this)},t.reportChanged=function(){St(),It(this),xt()},t.toString=function(){return this.name_},L(e,[{key:"isBeingObserved",get:function(){return _(this.flags_,e.isBeingObservedMask_)},set:function(t){this.flags_=T(this.flags_,e.isBeingObservedMask_,t)}},{key:"isPendingUnobservation",get:function(){return _(this.flags_,e.isPendingUnobservationMask_)},set:function(t){this.flags_=T(this.flags_,e.isPendingUnobservationMask_,t)}},{key:"diffValue",get:function(){return _(this.flags_,e.diffValueMask_)?1:0},set:function(t){this.flags_=T(this.flags_,e.diffValueMask_,1===t)}}])}();J.isBeingObservedMask_=1,J.isPendingUnobservationMask_=2,J.diffValueMask_=4;var X=x("Atom",J);function Z(e,t,n){void 0===t&&(t=m),void 0===n&&(n=m);var r=new J(e);return t!==m&&Yt(Ut,r,t,void 0),n!==m&&qt(r,n),r}var ee={identity:function(e,t){return e===t},structural:function(e,t){return Cr(e,t)},default:function(e,t){return Object.is?Object.is(e,t):e===t?0!==e||1/e==1/t:e!=e&&t!=t},shallow:function(e,t){return Cr(e,t,1)}};function te(e,t,n){return un(e)?e:Array.isArray(e)?Fe.array(e,{name:n}):y(e)?Fe.object(e,void 0,{name:n}):E(e)?Fe.map(e,{name:n}):I(e)?Fe.set(e,{name:n}):"function"!=typeof e||$t(e)||ln(e)?e:w(e)?on(e):jt(n,e)}function ne(e){return e}var re="override";function oe(e,t){return{annotationType_:e,options_:t,make_:ie,extend_:ae,decorate_20223_:le}}function ie(e,t,n,r){var o;if(null!=(o=this.options_)&&o.bound)return null===this.extend_(e,t,n,!1)?0:1;if(r===e.target_)return null===this.extend_(e,t,n,!1)?0:2;if($t(n.value))return 1;var i=se(e,this,t,n,!1);return s(r,t,i),2}function ae(e,t,n,r){var o=se(e,this,t,n);return e.defineProperty_(t,o,r)}function le(e,t){var n,o=t.kind,i=t.name,a=t.addInitializer,l=this,s=function(e){var t,n,r,o;return Ue(null!=(t=null==(n=l.options_)?void 0:n.name)?t:i.toString(),e,null!=(r=null==(o=l.options_)?void 0:o.autoAction)&&r)};return"field"==o?function(e){var t,n=e;return $t(n)||(n=s(n)),null!=(t=l.options_)&&t.bound&&((n=n.bind(this)).isMobxAction=!0),n}:"method"==o?($t(e)||(e=s(e)),null!=(n=this.options_)&&n.bound&&a(function(){var e=this,t=e[i].bind(e);t.isMobxAction=!0,e[i]=t}),e):void r("Cannot apply '"+l.annotationType_+"' to '"+String(i)+"' (kind: "+o+"):\n'"+l.annotationType_+"' can only be used on properties with a function value.")}function se(e,t,n,r,o){var i,a,l,s,c,u,d,f;void 0===o&&(o=bt.safeDescriptors),f=r,t.annotationType_,f.value;var p,h=r.value;return null!=(i=t.options_)&&i.bound&&(h=h.bind(null!=(p=e.proxy_)?p:e.target_)),{value:Ue(null!=(a=null==(l=t.options_)?void 0:l.name)?a:n.toString(),h,null!=(s=null==(c=t.options_)?void 0:c.autoAction)&&s,null!=(u=t.options_)&&u.bound?null!=(d=e.proxy_)?d:e.target_:void 0),configurable:!o||e.isPlainObject_,enumerable:!1,writable:!o}}function ce(e,t){return{annotationType_:e,options_:t,make_:ue,extend_:de,decorate_20223_:fe}}function ue(e,t,n,r){var o;if(r===e.target_)return null===this.extend_(e,t,n,!1)?0:2;if(null!=(o=this.options_)&&o.bound&&(!P(e.target_,t)||!ln(e.target_[t]))&&null===this.extend_(e,t,n,!1))return 0;if(ln(n.value))return 1;var i=pe(e,this,0,n,!1,!1);return s(r,t,i),2}function de(e,t,n,r){var o,i=pe(e,this,0,n,null==(o=this.options_)?void 0:o.bound);return e.defineProperty_(t,i,r)}function fe(e,t){var n,r=t.name,o=t.addInitializer;return ln(e)||(e=on(e)),null!=(n=this.options_)&&n.bound&&o(function(){var e=this,t=e[r].bind(e);t.isMobXFlow=!0,e[r]=t}),e}function pe(e,t,n,r,o,i){var a;void 0===i&&(i=bt.safeDescriptors),a=r,t.annotationType_,a.value;var l,s=r.value;return ln(s)||(s=on(s)),o&&((s=s.bind(null!=(l=e.proxy_)?l:e.target_)).isMobXFlow=!0),{value:s,configurable:!i||e.isPlainObject_,enumerable:!1,writable:!i}}function he(e,t){return{annotationType_:e,options_:t,make_:ge,extend_:me,decorate_20223_:Ae}}function ge(e,t,n){return null===this.extend_(e,t,n,!1)?0:1}function me(e,t,n,r){return o=n,this.annotationType_,o.get,e.defineComputedProperty_(t,Q({},this.options_,{get:n.get,set:n.set}),r);var o}function Ae(e,t){var n,r=this,o=t.name;function i(t,n){var i=Q({},r.options_,{get:e,context:t});return i.name||(i.name="ObservableObject."+o.toString()),new et(i)}return(0,t.addInitializer)(function(){var t,n=er(this)[K],r=this,a=n.values_.get(o);a instanceof et&&a.derivation!==e&&n.values_.delete(o),(null!=(t=n.lazyComputedKeys_)?t:n.lazyComputedKeys_=new Map).set(o,function(){return i(r)})}),function(){var t=this[K],r=t.values_.get(o);if(r instanceof et&&r.derivation!==e){var a,l,s=null==(a=n)?void 0:a.get(this);return s||(s=i(this),(null!=(l=n)?l:n=new WeakMap).set(this,s)),s.get()}return t.getObservablePropValue_(o)}}function be(e,t){return{annotationType_:e,options_:t,make_:ve,extend_:ye,decorate_20223_:we}}function ve(e,t,n){return null===this.extend_(e,t,n,!1)?0:1}function ye(e,t,n,r){var o,i;return this.annotationType_,e.defineObservableProperty_(t,n.value,null!=(o=null==(i=this.options_)?void 0:i.enhancer)?o:te,r)}function we(e,t){var n=this,r=t.kind,o=t.name;if("accessor"===r)return{get:function(){var t;return(null!=(t=this[K])?t:i(this,e.get.call(this))).getObservablePropValue_(o)},set:function(e){var t;return(null!=(t=this[K])?t:i(this,e)).setObservablePropValue_(o,e)},init:function(e){return i(this,e),e}};function i(e,t){var r,i=er(e)[K];return(null!=(r=i.lazyObservableKeys_)?r:i.lazyObservableKeys_=new Map).set(o,function(){var e,r;return new Xe(t,null!=(e=null==(r=n.options_)?void 0:r.enhancer)?e:te,"ObservableObject."+o.toString(),!1)}),i}}var Ce=Se();function Se(e){return{annotationType_:"true",options_:e,make_:xe,extend_:Ee,decorate_20223_:Ie}}function xe(e,t,n,r){var o,i,a,l;if(n.get)return $e.make_(e,t,n,r);if(n.set){var c=$t(n.set)?n.set:Ue(t.toString(),n.set);return r===e.target_?null===e.defineProperty_(t,{configurable:!bt.safeDescriptors||e.isPlainObject_,set:c})?0:2:(s(r,t,{configurable:!0,set:c}),2)}if(r!==e.target_&&"function"==typeof n.value)return w(n.value)?(null!=(l=this.options_)&&l.autoBind?on.bound:on).make_(e,t,n,r):(null!=(a=this.options_)&&a.autoBind?jt.bound:jt).make_(e,t,n,r);var u,d=!1===(null==(o=this.options_)?void 0:o.deep)?Fe.ref:Fe;return"function"==typeof n.value&&null!=(i=this.options_)&&i.autoBind&&(n.value=n.value.bind(null!=(u=e.proxy_)?u:e.target_)),d.make_(e,t,n,r)}function Ee(e,t,n,r){var o,i,a;return n.get?$e.extend_(e,t,n,r):n.set?e.defineProperty_(t,{configurable:!bt.safeDescriptors||e.isPlainObject_,set:Ue(t.toString(),n.set)},r):("function"==typeof n.value&&null!=(o=this.options_)&&o.autoBind&&(n.value=n.value.bind(null!=(a=e.proxy_)?a:e.target_)),(!1===(null==(i=this.options_)?void 0:i.deep)?Fe.ref:Fe).extend_(e,t,n,r))}function Ie(e,t){r("'"+this.annotationType_+"' cannot be used as a decorator")}var ke={deep:!0,name:void 0,defaultDecorator:void 0,proxy:!0};function Re(e){return e||ke}Object.freeze(ke);var Me=be("observable"),Pe=be("observable.ref",{enhancer:ne}),Be=be("observable.shallow",{enhancer:function(e,t,n){return null==e||rr(e)||jn(e)||Vn(e)||Yn(e)?e:Array.isArray(e)?Fe.array(e,{name:n,deep:!1}):y(e)?Fe.object(e,void 0,{name:n,deep:!1}):E(e)?Fe.map(e,{name:n,deep:!1}):I(e)?Fe.set(e,{name:n,deep:!1}):void 0}}),_e=be("observable.struct",{enhancer:function(e,t){return Cr(e,t)?t:e}}),Te=U(Me);function Oe(e){return!0===e.deep?te:!1===e.deep?ne:(t=e.defaultDecorator)&&null!=(n=null==(r=t.options_)?void 0:r.enhancer)?n:te;var t,n,r}function De(e,t,n){return Y(t)?Me.decorate_20223_(e,t):b(t)?void q(e,t,Me):un(e)?e:y(e)?Fe.object(e,t,n):Array.isArray(e)?Fe.array(e,t):E(e)?Fe.map(e,t):I(e)?Fe.set(e,t):"object"==typeof e&&null!==e?e:Fe.box(e,t)}a(De,Te);var Ne,Le,Fe=a(De,{box:function(e,t){var n=Re(t);return new Xe(e,Oe(n),n.name,!0,n.equals)},array:function(e,t){var n=Re(t);return(!1===bt.useProxies||!1===n.proxy?gr:Tn)(e,Oe(n),n.name)},map:function(e,t){var n=Re(t);return new Gn(e,Oe(n),n.name)},set:function(e,t){var n=Re(t);return new qn(e,Oe(n),n.name)},object:function(e,t,n){return vr(function(){return function(e,t,n,r){var o=B(t);return vr(function(){var t=er(e,r)[K];R(o).forEach(function(e){t.extend_(e,o[e],!n||!(e in n)||n[e])})}),e}(!1===bt.useProxies||!1===(null==n?void 0:n.proxy)?er({},n):function(e,t){var n,r;return h(),null!=(r=(n=(e=er(e,t))[K]).proxy_)?r:n.proxy_=new Proxy(e,wn)}({},n),e,t)})},ref:U(Pe),shallow:U(Be),deep:Te,struct:U(_e)}),Qe="computed",je=he(Qe),ze=he("computed.struct",{equals:ee.structural}),$e=function(e,t){if(Y(t))return je.decorate_20223_(e,t);if(b(t))return q(e,t,je);if(y(e))return U(he(Qe,e));var n=y(t)?t:{};return n.get=e,n.name||(n.name=e.name||""),new et(n)};Object.assign($e,je),$e.struct=U(ze);var He=0,Ge=1,Ve=null!=(Ne=null==(Le=l(function(){},"name"))?void 0:Le.configurable)&&Ne,We={value:"action",configurable:!0,writable:!1,enumerable:!1};function Ue(e,t,n,r){function o(){return qe(0,n,t,r||this,arguments)}return void 0===n&&(n=!1),o.isMobxAction=!0,o.toString=function(){return t.toString()},Ve&&(We.value=e,s(o,"name",We)),o}function qe(e,t,n,o,i){var a=function(e,t){var n=bt.trackingDerivation,r=!t||!n;St();var o=bt.allowStateChanges;r&&(ut(),o=Ke(!0));var i={runAsAction_:r,prevDerivation_:n,prevAllowStateChanges_:o,prevAllowStateReads_:ft(!0),notifySpy_:!1,startTime_:0,actionId_:Ge++,parentActionId_:He};return He=i.actionId_,i}(0,t);try{return n.apply(o,i)}catch(e){throw a.error_=e,e}finally{!function(e){He!==e.actionId_&&r(30),He=e.parentActionId_,void 0!==e.error_&&(bt.suppressReactionErrors=!0),Je(e.prevAllowStateChanges_),pt(e.prevAllowStateReads_),xt(),e.runAsAction_&&dt(e.prevDerivation_),bt.suppressReactionErrors=!1}(a)}}function Ye(e,t){var n=Ke(e);try{return t()}finally{Je(n)}}function Ke(e){var t=bt.allowStateChanges;return bt.allowStateChanges=e,t}function Je(e){bt.allowStateChanges=e}var Xe=function(e){function t(t,n,r,o,i){var a;return void 0===r&&(r="ObservableValue"),void 0===o&&(o=!0),void 0===i&&(i=ee.default),(a=e.call(this,r)||this).enhancer=void 0,a.name_=void 0,a.equals=void 0,a.hasUnreportedChange_=!1,a.interceptors_=void 0,a.changeListeners_=void 0,a.value_=void 0,a.dehancer=void 0,a.enhancer=n,a.name_=r,a.equals=i,a.value_=n(t,void 0,r),a}z(t,e);var n=t.prototype;return n.dehanceValue=function(e){return void 0!==this.dehancer?this.dehancer(e):e},n.set=function(e){this.value_,(e=this.prepareNewValue_(e))!==bt.UNCHANGED&&this.setNewValue_(e)},n.prepareNewValue_=function(e){if(Cn(this)){var t=xn(this,{object:this,type:Pn,newValue:e});if(!t)return bt.UNCHANGED;e=t.newValue}return e=this.enhancer(e,this.value_,this.name_),this.equals(this.value_,e)?bt.UNCHANGED:e},n.setNewValue_=function(e){var t=this.value_;this.value_=e,this.reportChanged(),En(this)&&kn(this,{type:Pn,object:this,newValue:e,oldValue:t})},n.get=function(){return this.reportObserved(),this.dehanceValue(this.value_)},n.intercept_=function(e){return Sn(this,e)},n.observe_=function(e,t){return t&&e({observableKind:"value",debugObjectName:this.name_,object:this,type:Pn,newValue:this.value_,oldValue:void 0}),In(this,e)},n.raw=function(){return this.value_},n.toJSON=function(){return this.get()},n.toString=function(){return this.name_+"["+this.value_+"]"},n.valueOf=function(){return M(this.get())},n[Symbol.toPrimitive]=function(){return this.valueOf()},t}(J),Ze=x("ObservableValue",Xe),et=function(){function e(e){this.dependenciesState_=tt.NOT_TRACKING_,this.observing_=[],this.newObserving_=null,this.observers_=new Set,this.runId_=0,this.lastAccessedBy_=0,this.lowestObserverState_=tt.UP_TO_DATE_,this.unboundDepsCount_=0,this.value_=new ot(null),this.name_=void 0,this.triggeredBy_=void 0,this.flags_=0,this.derivation=void 0,this.setter_=void 0,this.isTracing_=nt.NONE,this.scope_=void 0,this.equals_=void 0,this.requiresReaction_=void 0,this.keepAlive_=void 0,this.onBOL=void 0,this.onBUOL=void 0,e.get||r(31),this.derivation=e.get,this.name_=e.name||"ComputedValue",e.set&&(this.setter_=Ue("ComputedValue-setter",e.set)),this.equals_=e.equals||(e.compareStructural||e.struct?ee.structural:ee.default),this.scope_=e.context,this.requiresReaction_=e.requiresReaction,this.keepAlive_=!!e.keepAlive}var t=e.prototype;return t.onBecomeStale_=function(){!function(e){e.lowestObserverState_===tt.UP_TO_DATE_&&(e.lowestObserverState_=tt.POSSIBLY_STALE_,e.observers_.forEach(function(e){e.dependenciesState_===tt.UP_TO_DATE_&&(e.dependenciesState_=tt.POSSIBLY_STALE_,e.onBecomeStale_())}))}(this)},t.onBO=function(){this.onBOL&&this.onBOL.forEach(function(e){return e()})},t.onBUO=function(){this.onBUOL&&this.onBUOL.forEach(function(e){return e()})},t.get=function(){if(this.isComputing&&r(32,this.name_,this.derivation),0!==bt.inBatch||0!==this.observers_.size||this.keepAlive_){if(Et(this),at(this)){var e=bt.trackingContext;this.keepAlive_&&!e&&(bt.trackingContext=this),this.trackAndCompute()&&function(e){e.lowestObserverState_!==tt.STALE_&&(e.lowestObserverState_=tt.STALE_,e.observers_.forEach(function(t){t.dependenciesState_===tt.POSSIBLY_STALE_?t.dependenciesState_=tt.STALE_:t.dependenciesState_===tt.UP_TO_DATE_&&(e.lowestObserverState_=tt.UP_TO_DATE_)}))}(this),bt.trackingContext=e}}else at(this)&&(this.warnAboutUntrackedRead_(),St(),this.value_=this.computeValue_(!1),xt());var t=this.value_;if(it(t))throw t.cause;return t},t.set=function(e){if(this.setter_){this.isRunningSetter&&r(33,this.name_),this.isRunningSetter=!0;try{this.setter_.call(this.scope_,e)}finally{this.isRunningSetter=!1}}else r(34,this.name_)},t.trackAndCompute=function(){var e=this.value_,t=this.dependenciesState_===tt.NOT_TRACKING_,n=this.computeValue_(!0),r=t||it(e)||it(n)||!this.equals_(e,n);return r&&(this.value_=n),r},t.computeValue_=function(e){this.isComputing=!0;var t,n=Ke(!1);if(e)t=lt(this,this.derivation,this.scope_);else if(!0===bt.disableErrorBoundaries)t=this.derivation.call(this.scope_);else try{t=this.derivation.call(this.scope_)}catch(e){t=new ot(e)}return Je(n),this.isComputing=!1,t},t.suspend_=function(){this.keepAlive_||(st(this),this.value_=void 0)},t.observe_=function(e,t){var n=this,r=!0,o=void 0;return Ht(function(){var i=n.get();if(!r||t){var a=ut();e({observableKind:"computed",debugObjectName:n.name_,type:Pn,object:n,newValue:i,oldValue:o}),dt(a)}r=!1,o=i})},t.warnAboutUntrackedRead_=function(){},t.toString=function(){return this.name_+"["+this.derivation.toString()+"]"},t.valueOf=function(){return M(this.get())},t[Symbol.toPrimitive]=function(){return this.valueOf()},L(e,[{key:"isComputing",get:function(){return _(this.flags_,e.isComputingMask_)},set:function(t){this.flags_=T(this.flags_,e.isComputingMask_,t)}},{key:"isRunningSetter",get:function(){return _(this.flags_,e.isRunningSetterMask_)},set:function(t){this.flags_=T(this.flags_,e.isRunningSetterMask_,t)}},{key:"isBeingObserved",get:function(){return _(this.flags_,e.isBeingObservedMask_)},set:function(t){this.flags_=T(this.flags_,e.isBeingObservedMask_,t)}},{key:"isPendingUnobservation",get:function(){return _(this.flags_,e.isPendingUnobservationMask_)},set:function(t){this.flags_=T(this.flags_,e.isPendingUnobservationMask_,t)}},{key:"diffValue",get:function(){return _(this.flags_,e.diffValueMask_)?1:0},set:function(t){this.flags_=T(this.flags_,e.diffValueMask_,1===t)}}])}();et.isComputingMask_=1,et.isRunningSetterMask_=2,et.isBeingObservedMask_=4,et.isPendingUnobservationMask_=8,et.diffValueMask_=16;var tt,nt,rt=x("ComputedValue",et);!function(e){e[e.NOT_TRACKING_=-1]="NOT_TRACKING_",e[e.UP_TO_DATE_=0]="UP_TO_DATE_",e[e.POSSIBLY_STALE_=1]="POSSIBLY_STALE_",e[e.STALE_=2]="STALE_"}(tt||(tt={})),function(e){e[e.NONE=0]="NONE",e[e.LOG=1]="LOG",e[e.BREAK=2]="BREAK"}(nt||(nt={}));var ot=function(e){this.cause=void 0,this.cause=e};function it(e){return e instanceof ot}function at(e){switch(e.dependenciesState_){case tt.UP_TO_DATE_:return!1;case tt.NOT_TRACKING_:case tt.STALE_:return!0;case tt.POSSIBLY_STALE_:for(var t=ft(!0),n=ut(),r=e.observing_,o=r.length,i=0;i<o;i++){var a=r[i];if(rt(a)){if(bt.disableErrorBoundaries)a.get();else try{a.get()}catch(e){return dt(n),pt(t),!0}if(e.dependenciesState_===tt.STALE_)return dt(n),pt(t),!0}}return ht(e),dt(n),pt(t),!1}}function lt(e,t,n){var r=ft(!0);ht(e),e.newObserving_=new Array(0===e.runId_?100:e.observing_.length),e.unboundDepsCount_=0,e.runId_=++bt.runId;var o,i=bt.trackingDerivation;if(bt.trackingDerivation=e,bt.inBatch++,!0===bt.disableErrorBoundaries)o=t.call(n);else try{o=t.call(n)}catch(e){o=new ot(e)}return bt.inBatch--,bt.trackingDerivation=i,function(e){for(var t=e.observing_,n=e.observing_=e.newObserving_,r=tt.UP_TO_DATE_,o=0,i=e.unboundDepsCount_,a=0;a<i;a++){var l=n[a];0===l.diffValue&&(l.diffValue=1,o!==a&&(n[o]=l),o++),l.dependenciesState_>r&&(r=l.dependenciesState_)}for(n.length=o,e.newObserving_=null,i=t.length;i--;){var s=t[i];0===s.diffValue&&wt(s,e),s.diffValue=0}for(;o--;){var c=n[o];1===c.diffValue&&(c.diffValue=0,yt(c,e))}r!==tt.UP_TO_DATE_&&(e.dependenciesState_=r,e.onBecomeStale_())}(e),pt(r),o}function st(e){var t=e.observing_;e.observing_=[];for(var n=t.length;n--;)wt(t[n],e);e.dependenciesState_=tt.NOT_TRACKING_}function ct(e){var t=ut();try{return e()}finally{dt(t)}}function ut(){var e=bt.trackingDerivation;return bt.trackingDerivation=null,e}function dt(e){bt.trackingDerivation=e}function ft(e){var t=bt.allowStateReads;return bt.allowStateReads=e,t}function pt(e){bt.allowStateReads=e}function ht(e){if(e.dependenciesState_!==tt.UP_TO_DATE_){e.dependenciesState_=tt.UP_TO_DATE_;for(var t=e.observing_,n=t.length;n--;)t[n].lowestObserverState_=tt.UP_TO_DATE_}}var gt=function(){this.version=6,this.UNCHANGED={},this.trackingDerivation=null,this.trackingContext=null,this.runId=0,this.mobxGuid=0,this.inBatch=0,this.pendingUnobservations=[],this.pendingReactions=[],this.isRunningReactions=!1,this.allowStateChanges=!1,this.allowStateReads=!0,this.enforceActions=!0,this.spyListeners=[],this.globalReactionErrorHandlers=[],this.computedRequiresReaction=!1,this.reactionRequiresObservable=!1,this.observableRequiresReaction=!1,this.disableErrorBoundaries=!1,this.suppressReactionErrors=!1,this.useProxies=!0,this.verifyProxies=!1,this.safeDescriptors=!0},mt=!0,At=!1,bt=function(){var e=i();return e.__mobxInstanceCount>0&&!e.__mobxGlobals&&(mt=!1),e.__mobxGlobals&&e.__mobxGlobals.version!==(new gt).version&&(mt=!1),mt?e.__mobxGlobals?(e.__mobxInstanceCount+=1,e.__mobxGlobals.UNCHANGED||(e.__mobxGlobals.UNCHANGED={}),e.__mobxGlobals):(e.__mobxInstanceCount=1,e.__mobxGlobals=new gt):(setTimeout(function(){At||r(35)},1),new gt)}();function vt(){return bt}function yt(e,t){e.observers_.add(t),e.lowestObserverState_>t.dependenciesState_&&(e.lowestObserverState_=t.dependenciesState_)}function wt(e,t){e.observers_.delete(t),0===e.observers_.size&&Ct(e)}function Ct(e){!1===e.isPendingUnobservation&&(e.isPendingUnobservation=!0,bt.pendingUnobservations.push(e))}function St(){bt.inBatch++}function xt(){if(0===--bt.inBatch){Mt();for(var e=bt.pendingUnobservations,t=0;t<e.length;t++){var n=e[t];n.isPendingUnobservation=!1,0===n.observers_.size&&(n.isBeingObserved&&(n.isBeingObserved=!1,n.onBUO()),n instanceof et&&n.suspend_())}bt.pendingUnobservations=[]}}function Et(e){var t=bt.trackingDerivation;return null!==t?(t.runId_!==e.lastAccessedBy_&&(e.lastAccessedBy_=t.runId_,t.newObserving_[t.unboundDepsCount_++]=e,!e.isBeingObserved&&bt.trackingContext&&(e.isBeingObserved=!0,e.onBO())),e.isBeingObserved):(0===e.observers_.size&&bt.inBatch>0&&Ct(e),!1)}function It(e){e.lowestObserverState_!==tt.STALE_&&(e.lowestObserverState_=tt.STALE_,e.observers_.forEach(function(e){e.dependenciesState_===tt.UP_TO_DATE_&&e.onBecomeStale_(),e.dependenciesState_=tt.STALE_}))}var kt=function(){function e(e,t,n,r){void 0===e&&(e="Reaction"),this.name_=void 0,this.onInvalidate_=void 0,this.errorHandler_=void 0,this.requiresObservable_=void 0,this.observing_=[],this.newObserving_=[],this.dependenciesState_=tt.NOT_TRACKING_,this.runId_=0,this.unboundDepsCount_=0,this.flags_=0,this.isTracing_=nt.NONE,this.name_=e,this.onInvalidate_=t,this.errorHandler_=n,this.requiresObservable_=r}var t=e.prototype;return t.onBecomeStale_=function(){this.schedule_()},t.schedule_=function(){this.isScheduled||(this.isScheduled=!0,bt.pendingReactions.push(this),Mt())},t.runReaction_=function(){if(!this.isDisposed){St(),this.isScheduled=!1;var e=bt.trackingContext;if(bt.trackingContext=this,at(this)){this.isTrackPending=!0;try{this.onInvalidate_()}catch(e){this.reportExceptionInDerivation_(e)}}bt.trackingContext=e,xt()}},t.track=function(e){if(!this.isDisposed){St(),this.isRunning=!0;var t=bt.trackingContext;bt.trackingContext=this;var n=lt(this,e,void 0);bt.trackingContext=t,this.isRunning=!1,this.isTrackPending=!1,this.isDisposed&&st(this),it(n)&&this.reportExceptionInDerivation_(n.cause),xt()}},t.reportExceptionInDerivation_=function(e){var t=this;if(this.errorHandler_)this.errorHandler_(e,this);else{if(bt.disableErrorBoundaries)throw e;var n="[mobx] uncaught error in '"+this+"'";bt.suppressReactionErrors||console.error(n,e),bt.globalReactionErrorHandlers.forEach(function(n){return n(e,t)})}},t.dispose=function(){this.isDisposed||(this.isDisposed=!0,this.isRunning||(St(),st(this),xt()))},t.getDisposer_=function(e){var t=this,n=function n(){t.dispose(),null==e||null==e.removeEventListener||e.removeEventListener("abort",n)};return null==e||null==e.addEventListener||e.addEventListener("abort",n),n[K]=this,"dispose"in Symbol&&"symbol"==typeof Symbol.dispose&&(n[Symbol.dispose]=n),n},t.toString=function(){return"Reaction["+this.name_+"]"},t.trace=function(e){void 0===e&&(e=!1)},L(e,[{key:"isDisposed",get:function(){return _(this.flags_,e.isDisposedMask_)},set:function(t){this.flags_=T(this.flags_,e.isDisposedMask_,t)}},{key:"isScheduled",get:function(){return _(this.flags_,e.isScheduledMask_)},set:function(t){this.flags_=T(this.flags_,e.isScheduledMask_,t)}},{key:"isTrackPending",get:function(){return _(this.flags_,e.isTrackPendingMask_)},set:function(t){this.flags_=T(this.flags_,e.isTrackPendingMask_,t)}},{key:"isRunning",get:function(){return _(this.flags_,e.isRunningMask_)},set:function(t){this.flags_=T(this.flags_,e.isRunningMask_,t)}},{key:"diffValue",get:function(){return _(this.flags_,e.diffValueMask_)?1:0},set:function(t){this.flags_=T(this.flags_,e.diffValueMask_,1===t)}}])}();kt.isDisposedMask_=1,kt.isScheduledMask_=2,kt.isTrackPendingMask_=4,kt.isRunningMask_=8,kt.diffValueMask_=16;var Rt=function(e){return e()};function Mt(){bt.inBatch>0||bt.isRunningReactions||Rt(Pt)}function Pt(){bt.isRunningReactions=!0;for(var e=bt.pendingReactions,t=0;e.length>0;){100===++t&&(console.error("[mobx] cycle in reaction: "+e[0]),e.splice(0));for(var n=e.splice(0),r=0,o=n.length;r<o;r++)n[r].runReaction_()}bt.isRunningReactions=!1}var Bt=x("Reaction",kt),_t="action",Tt="autoAction",Ot=oe(_t),Dt=oe("action.bound",{bound:!0}),Nt=oe(Tt,{autoAction:!0}),Lt=oe("autoAction.bound",{autoAction:!0,bound:!0});function Ft(e){return function(t,n){return A(t)?Ue(t.name||"<unnamed action>",t,e):A(n)?Ue(t,n,e):Y(n)?(e?Nt:Ot).decorate_20223_(t,n):b(n)?q(t,n,e?Nt:Ot):b(t)?U(oe(e?Tt:_t,{name:t,autoAction:e})):void 0}}var Qt=Ft(!1);Object.assign(Qt,Ot);var jt=Ft(!0);function zt(e){return qe(e.name,!1,e,this,void 0)}function $t(e){return A(e)&&!0===e.isMobxAction}function Ht(e,t){var n,r,o,i;void 0===t&&(t=d);var a,l=null!=(n=null==(r=t)?void 0:r.name)?n:"Autorun";if(t.scheduler||t.delay){var s=Vt(t),c=!1;a=new kt(l,function(){c||(c=!0,s(function(){c=!1,a.isDisposed||a.track(u)}))},t.onError,t.requiresObservable)}else a=new kt(l,function(){this.track(u)},t.onError,t.requiresObservable);function u(){e(a)}return null!=(o=t)&&null!=(o=o.signal)&&o.aborted||a.schedule_(),a.getDisposer_(null==(i=t)?void 0:i.signal)}Object.assign(jt,Nt),Qt.bound=U(Dt),jt.bound=U(Lt);var Gt=function(e){return e()};function Vt(e){return e.scheduler?e.scheduler:e.delay?function(t){return setTimeout(t,e.delay)}:Gt}function Wt(e,t,n){var r,o,i;void 0===n&&(n=d);var a,l,s,c=null!=(r=n.name)?r:"Reaction",u=Qt(c,n.onError?(a=n.onError,l=t,function(){try{return l.apply(this,arguments)}catch(e){a.call(this,e)}}):t),f=!n.scheduler&&!n.delay,p=Vt(n),h=!0,g=!1,m=n.compareStructural?ee.structural:n.equals||ee.default,A=new kt(c,function(){h||f?b():g||(g=!0,p(b))},n.onError,n.requiresObservable);function b(){if(g=!1,!A.isDisposed){var t=!1,r=s;A.track(function(){var n=Ye(!1,function(){return e(A)});t=h||!m(s,n),s=n}),(h&&n.fireImmediately||!h&&t)&&u(s,r,A),h=!1}}return null!=(o=n)&&null!=(o=o.signal)&&o.aborted||A.schedule_(),A.getDisposer_(null==(i=n)?void 0:i.signal)}var Ut="onBO";function qt(e,t,n){return Yt("onBUO",e,t,n)}function Yt(e,t,n,r){var o="function"==typeof r?mr(t,n):mr(t),i=A(r)?r:n,a=e+"L";return o[a]?o[a].add(i):o[a]=new Set([i]),function(){var e=o[a];e&&(e.delete(i),0===e.size&&delete o[a])}}var Kt="always";function Jt(e){!0===e.isolateGlobalState&&function(){if((bt.pendingReactions.length||bt.inBatch||bt.isRunningReactions)&&r(36),At=!0,mt){var e=i();0===--e.__mobxInstanceCount&&(e.__mobxGlobals=void 0),bt=new gt}}();var t,n,o=e.useProxies,a=e.enforceActions;if(void 0!==o&&(bt.useProxies=o===Kt||"never"!==o&&"undefined"!=typeof Proxy),"ifavailable"===o&&(bt.verifyProxies=!0),void 0!==a){var l=a===Kt?Kt:"observed"===a;bt.enforceActions=l,bt.allowStateChanges=!0!==l&&l!==Kt}["computedRequiresReaction","reactionRequiresObservable","observableRequiresReaction","disableErrorBoundaries","safeDescriptors"].forEach(function(t){t in e&&(bt[t]=!!e[t])}),bt.allowStateReads=!bt.observableRequiresReaction,e.reactionScheduler&&(t=e.reactionScheduler,n=Rt,Rt=function(e){return t(function(){return n(e)})})}function Xt(e,t){return Zt(mr(e,t))}function Zt(e){var t,n={name:e.name_};return e.observing_&&e.observing_.length>0&&(n.dependencies=(t=e.observing_,Array.from(new Set(t))).map(Zt)),n}var en=0,tn=function(e){function t(){var n;return n=e.call(this,"FLOW_CANCELLED")||this,Object.setPrototypeOf(n,(this instanceof t?this.constructor:void 0).prototype),n.name="FlowCancellationError",n}return z(t,e),t.prototype.toString=function(){return"Error: "+this.message},t}(V(Error)),nn=ce("flow"),rn=ce("flow.bound",{bound:!0}),on=Object.assign(function(e,t){if(Y(t))return nn.decorate_20223_(e,t);if(b(t))return q(e,t,nn);var n=e,r=n.name||"<unnamed flow>",o=function(){var e,t=arguments,o=++en,i=Qt(r+" - runid: "+o+" - init",n).apply(this,t),a=void 0,l=new Promise(function(t,n){var l=0;function s(e){var t;a=void 0;try{t=Qt(r+" - runid: "+o+" - yield "+l++,i.next).call(i,e)}catch(e){return n(e)}u(t)}function c(e){var t;a=void 0;try{t=Qt(r+" - runid: "+o+" - yield "+l++,i.throw).call(i,e)}catch(e){return n(e)}u(t)}function u(e){if(!A(null==e?void 0:e.then))return e.done?t(e.value):(a=Promise.resolve(e.value)).then(s,c);e.then(u,n)}e=n,s(void 0)});return l.cancel=Qt(r+" - runid: "+o+" - cancel",function(){try{a&&an(a);var t=i.return(void 0),n=Promise.resolve(t.value);n.then(m,m),an(n),e(new tn)}catch(t){e(t)}}),l};return o.isMobXFlow=!0,o},nn);function an(e){A(e.cancel)&&e.cancel()}function ln(e){return!0===(null==e?void 0:e.isMobXFlow)}function sn(e,t,n){var r;return Vn(e)||jn(e)||Ze(e)?r=Ar(e):rr(e)&&(r=Ar(e,t)),r.dehancer="function"==typeof t?t:n,function(){r.dehancer=void 0}}function cn(e,t,n){return A(n)?function(e,t,n){return Ar(e,t).intercept_(n)}(e,t,n):function(e,t){return Ar(e).intercept_(t)}(e,t)}function un(e){return function(e,t){if(!e)return!1;if(void 0!==t){if(rr(e)){var n,r,o=e[K];return o.values_.has(t)||!(null==(n=o.lazyComputedKeys_)||!n.has(t))||!(null==(r=o.lazyObservableKeys_)||!r.has(t))}return!1}return rr(e)||!!e[K]||X(e)||Bt(e)||rt(e)}(e)}function dn(e){return rr(e)?e[K].keys_():Vn(e)||Yn(e)?Array.from(e.keys()):jn(e)?e.map(function(e,t){return t}):void r(5)}function fn(e){return rr(e)?dn(e).map(function(t){return e[t]}):Vn(e)?dn(e).map(function(t){return e.get(t)}):Yn(e)?Array.from(e.values()):jn(e)?e.slice():void r(6)}function pn(e){return rr(e)?dn(e).map(function(t){return[t,e[t]]}):Vn(e)?dn(e).map(function(t){return[t,e.get(t)]}):Yn(e)?Array.from(e.entries()):jn(e)?e.map(function(e,t){return[t,e]}):void r(7)}function hn(e,t,n){if(2!==arguments.length||Yn(e))rr(e)?e[K].set_(t,n):Vn(e)?e.set(t,n):Yn(e)?e.add(t):jn(e)?("number"!=typeof t&&(t=parseInt(t,10)),t<0&&r("Invalid index: '"+t+"'"),St(),t>=e.length&&(e.length=t+1),e[t]=n,xt()):r(8);else{St();var o=t;try{for(var i in o)hn(e,i,o[i])}finally{xt()}}}function gn(e,t,n){if(rr(e))return e[K].defineProperty_(t,n);r(39)}function mn(e,t,n,r){return A(n)?function(e,t,n,r){return Ar(e,t).observe_(n,r)}(e,t,n,r):function(e,t,n){return Ar(e).observe_(t,n)}(e,t,n)}function An(e,t){void 0===t&&(t=void 0),St();try{return e.apply(t)}finally{xt()}}function bn(e,t,n){return 1===arguments.length||t&&"object"==typeof t?function(e,t){var n,r,o;if(null!=t&&null!=(n=t.signal)&&n.aborted)return Object.assign(Promise.reject(new Error("WHEN_ABORTED")),{cancel:function(){return null}});var i=new Promise(function(n,i){var a,l=vn(e,n,Q({},t,{onError:i}));r=function(){l(),i(new Error("WHEN_CANCELLED"))},o=function(){l(),i(new Error("WHEN_ABORTED"))},null==t||null==(a=t.signal)||null==a.addEventListener||a.addEventListener("abort",o)}).finally(function(){var e;return null==t||null==(e=t.signal)||null==e.removeEventListener?void 0:e.removeEventListener("abort",o)});return i.cancel=r,i}(e,t):vn(e,t,n||{})}function vn(e,t,n){var r;if("number"==typeof n.timeout){var o=new Error("WHEN_TIMEOUT");r=setTimeout(function(){if(!a[K].isDisposed){if(a(),!n.onError)throw o;n.onError(o)}},n.timeout)}n.name="When";var i=Ue("When-effect",t),a=Ht(function(t){Ye(!1,e)&&(t.dispose(),r&&clearTimeout(r),i())},n);return a}function yn(e){return e[K]}on.bound=U(rn);var wn={has:function(e,t){return yn(e).has_(t)},get:function(e,t){return yn(e).get_(t)},set:function(e,t,n){var r;return!!b(t)&&(null==(r=yn(e).set_(t,n,!0))||r)},deleteProperty:function(e,t){var n;return!!b(t)&&(null==(n=yn(e).delete_(t,!0))||n)},defineProperty:function(e,t,n){var r;return null==(r=yn(e).defineProperty_(t,n))||r},ownKeys:function(e){return yn(e).ownKeys_()},preventExtensions:function(e){r(13)}};function Cn(e){return void 0!==e.interceptors_&&e.interceptors_.length>0}function Sn(e,t){var n=e.interceptors_||(e.interceptors_=[]);return n.push(t),g(function(){var e=n.indexOf(t);-1!==e&&n.splice(e,1)})}function xn(e,t){var n=ut();try{for(var o=[].concat(e.interceptors_||[]),i=0,a=o.length;i<a&&((t=o[i](t))&&!t.type&&r(14),t);i++);return t}finally{dt(n)}}function En(e){return void 0!==e.changeListeners_&&e.changeListeners_.length>0}function In(e,t){var n=e.changeListeners_||(e.changeListeners_=[]);return n.push(t),g(function(){var e=n.indexOf(t);-1!==e&&n.splice(e,1)})}function kn(e,t){var n=ut(),r=e.changeListeners_;if(r){for(var o=0,i=(r=r.slice()).length;o<i;o++)r[o](t);dt(n)}}function Rn(e,t,n){return vr(function(){var r=er(e,n)[K];null!=t||(t=function(e){return P(e,W)||C(e,W,Q({},e[W])),e[W]}(e)),R(t).forEach(function(e){return r.make_(e,t[e])})}),e}var Mn="splice",Pn="update",Bn={get:function(e,t){var n=e[K];return t===K?n:"length"===t?n.getArrayLength_():"string"!=typeof t||isNaN(t)?P(On,t)?On[t]:e[t]:n.get_(parseInt(t))},set:function(e,t,n){var r=e[K];return"length"===t&&r.setArrayLength_(n),"symbol"==typeof t||isNaN(t)?e[t]=n:r.set_(parseInt(t),n),!0},preventExtensions:function(){r(15)}},_n=function(){function e(e,t,n,r){void 0===e&&(e="ObservableArray"),this.owned_=void 0,this.legacyMode_=void 0,this.atom_=void 0,this.values_=[],this.interceptors_=void 0,this.changeListeners_=void 0,this.enhancer_=void 0,this.dehancer=void 0,this.proxy_=void 0,this.lastKnownLength_=0,this.owned_=n,this.legacyMode_=r,this.atom_=new J(e),this.enhancer_=function(e,n){return t(e,n,"ObservableArray[..]")}}var t=e.prototype;return t.dehanceValue_=function(e){return void 0!==this.dehancer?this.dehancer(e):e},t.dehanceValues_=function(e){return void 0!==this.dehancer&&e.length>0?e.map(this.dehancer):e},t.intercept_=function(e){return Sn(this,e)},t.observe_=function(e,t){return void 0===t&&(t=!1),t&&e({observableKind:"array",object:this.proxy_,debugObjectName:this.atom_.name_,type:"splice",index:0,added:this.values_.slice(),addedCount:this.values_.length,removed:[],removedCount:0}),In(this,e)},t.getArrayLength_=function(){return this.atom_.reportObserved(),this.values_.length},t.setArrayLength_=function(e){("number"!=typeof e||isNaN(e)||e<0)&&r("Out of range: "+e);var t=this.values_.length;if(e!==t)if(e>t){for(var n=new Array(e-t),o=0;o<e-t;o++)n[o]=void 0;this.spliceWithArray_(t,0,n)}else this.spliceWithArray_(e,t-e)},t.updateArrayLength_=function(e,t){e!==this.lastKnownLength_&&r(16),this.lastKnownLength_+=t,this.legacyMode_&&t>0&&hr(e+t+1)},t.spliceWithArray_=function(e,t,n){var r=this;this.atom_;var o=this.values_.length;if(void 0===e?e=0:e>o?e=o:e<0&&(e=Math.max(0,o+e)),t=1===arguments.length?o-e:null==t?0:Math.max(0,Math.min(t,o-e)),void 0===n&&(n=u),Cn(this)){var i=xn(this,{object:this.proxy_,type:Mn,index:e,removedCount:t,added:n});if(!i)return u;t=i.removedCount,n=i.added}if(n=0===n.length?n:n.map(function(e){return r.enhancer_(e,void 0)}),this.legacyMode_){var a=n.length-t;this.updateArrayLength_(o,a)}var l=this.spliceItemsIntoValues_(e,t,n);return 0===t&&0===n.length||this.notifyArraySplice_(e,n,l),this.dehanceValues_(l)},t.spliceItemsIntoValues_=function(e,t,n){var r;if(n.length<1e4)return(r=this.values_).splice.apply(r,[e,t].concat(n));var o=this.values_.slice(e,e+t),i=this.values_.slice(e+t);this.values_.length+=n.length-t;for(var a=0;a<n.length;a++)this.values_[e+a]=n[a];for(var l=0;l<i.length;l++)this.values_[e+n.length+l]=i[l];return o},t.notifyArrayChildUpdate_=function(e,t,n){var r=!this.owned_&&!1,o=En(this),i=o||r?{observableKind:"array",object:this.proxy_,type:Pn,debugObjectName:this.atom_.name_,index:e,newValue:t,oldValue:n}:null;this.atom_.reportChanged(),o&&kn(this,i)},t.notifyArraySplice_=function(e,t,n){var r=!this.owned_&&!1,o=En(this),i=o||r?{observableKind:"array",object:this.proxy_,debugObjectName:this.atom_.name_,type:Mn,index:e,removed:n,added:t,removedCount:n.length,addedCount:t.length}:null;this.atom_.reportChanged(),o&&kn(this,i)},t.get_=function(e){if(!(this.legacyMode_&&e>=this.values_.length))return this.atom_.reportObserved(),this.dehanceValue_(this.values_[e]);console.warn("[mobx] Out of bounds read: "+e)},t.set_=function(e,t){var n=this.values_;if(this.legacyMode_&&e>n.length&&r(17,e,n.length),e<n.length){this.atom_;var o=n[e];if(Cn(this)){var i=xn(this,{type:Pn,object:this.proxy_,index:e,newValue:t});if(!i)return;t=i.newValue}(t=this.enhancer_(t,o))!==o&&(n[e]=t,this.notifyArrayChildUpdate_(e,t,o))}else{for(var a=new Array(e+1-n.length),l=0;l<a.length-1;l++)a[l]=void 0;a[a.length-1]=t,this.spliceWithArray_(n.length,0,a)}},e}();function Tn(e,t,n,r){return void 0===n&&(n="ObservableArray"),void 0===r&&(r=!1),h(),vr(function(){var o=new _n(n,t,r,!1);S(o.values_,K,o);var i=new Proxy(o.values_,Bn);return o.proxy_=i,e&&e.length&&o.spliceWithArray_(0,0,e),i})}var On={clear:function(){return this.splice(0)},replace:function(e){var t=this[K];return t.spliceWithArray_(0,t.values_.length,e)},toJSON:function(){return this.slice()},splice:function(e,t){for(var n=arguments.length,r=new Array(n>2?n-2:0),o=2;o<n;o++)r[o-2]=arguments[o];var i=this[K];switch(arguments.length){case 0:return[];case 1:return i.spliceWithArray_(e);case 2:return i.spliceWithArray_(e,t)}return i.spliceWithArray_(e,t,r)},spliceWithArray:function(e,t,n){return this[K].spliceWithArray_(e,t,n)},push:function(){for(var e=this[K],t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return e.spliceWithArray_(e.values_.length,0,n),e.values_.length},pop:function(){return this.splice(Math.max(this[K].values_.length-1,0),1)[0]},shift:function(){return this.splice(0,1)[0]},unshift:function(){for(var e=this[K],t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return e.spliceWithArray_(0,0,n),e.values_.length},reverse:function(){return bt.trackingDerivation&&r(37,"reverse"),this.replace(this.slice().reverse()),this},sort:function(){bt.trackingDerivation&&r(37,"sort");var e=this.slice();return e.sort.apply(e,arguments),this.replace(e),this},remove:function(e){var t=this[K],n=t.dehanceValues_(t.values_).indexOf(e);return n>-1&&(this.splice(n,1),!0)}};function Dn(e,t){"function"==typeof Array.prototype[e]&&(On[e]=t(e))}function Nn(e){return function(){var t=this[K];t.atom_.reportObserved();var n=t.dehanceValues_(t.values_);return n[e].apply(n,arguments)}}function Ln(e){return function(t,n){var r=this,o=this[K];return o.atom_.reportObserved(),o.dehanceValues_(o.values_)[e](function(e,o){return t.call(n,e,o,r)})}}function Fn(e){return function(){var t=this,n=this[K];n.atom_.reportObserved();var r=n.dehanceValues_(n.values_),o=arguments[0];return arguments[0]=function(e,n,r){return o(e,n,r,t)},r[e].apply(r,arguments)}}Dn("at",Nn),Dn("concat",Nn),Dn("flat",Nn),Dn("includes",Nn),Dn("indexOf",Nn),Dn("join",Nn),Dn("lastIndexOf",Nn),Dn("slice",Nn),Dn("toString",Nn),Dn("toLocaleString",Nn),Dn("toSorted",Nn),Dn("toSpliced",Nn),Dn("with",Nn),Dn("every",Ln),Dn("filter",Ln),Dn("find",Ln),Dn("findIndex",Ln),Dn("findLast",Ln),Dn("findLastIndex",Ln),Dn("flatMap",Ln),Dn("forEach",Ln),Dn("map",Ln),Dn("some",Ln),Dn("toReversed",Ln),Dn("reduce",Fn),Dn("reduceRight",Fn);var Qn=x("ObservableArrayAdministration",_n);function jn(e){return v(e)&&Qn(e[K])}var zn={},$n="add",Hn="delete",Gn=function(){function e(e,t,n){var o=this;void 0===t&&(t=te),void 0===n&&(n="ObservableMap"),this.enhancer_=void 0,this.name_=void 0,this[K]=zn,this.data_=void 0,this.hasMap_=void 0,this.keysAtom_=void 0,this.interceptors_=void 0,this.changeListeners_=void 0,this.dehancer=void 0,this.enhancer_=t,this.name_=n,A(Map)||r(18),vr(function(){o.keysAtom_=Z("ObservableMap.keys()"),o.data_=new Map,o.hasMap_=new Map,e&&o.merge(e)})}var t=e.prototype;return t.has_=function(e){return this.data_.has(e)},t.has=function(e){var t=this;if(!bt.trackingDerivation)return this.has_(e);var n=this.hasMap_.get(e);if(!n){var r=n=new Xe(this.has_(e),ne,"ObservableMap.key?",!1);this.hasMap_.set(e,r),qt(r,function(){return t.hasMap_.delete(e)})}return n.get()},t.set=function(e,t){var n=this.has_(e);if(Cn(this)){var r=xn(this,{type:n?Pn:$n,object:this,newValue:t,name:e});if(!r)return this;t=r.newValue}return n?this.updateValue_(e,t):this.addValue_(e,t),this},t.delete=function(e){var t=this;if(this.keysAtom_,Cn(this)&&!xn(this,{type:Hn,object:this,name:e}))return!1;if(this.has_(e)){var n=En(this),r=n?{observableKind:"map",debugObjectName:this.name_,type:Hn,object:this,oldValue:this.data_.get(e).value_,name:e}:null;return An(function(){var n;t.keysAtom_.reportChanged(),null==(n=t.hasMap_.get(e))||n.setNewValue_(!1),t.data_.get(e).setNewValue_(void 0),t.data_.delete(e)}),n&&kn(this,r),!0}return!1},t.updateValue_=function(e,t){var n=this.data_.get(e);if((t=n.prepareNewValue_(t))!==bt.UNCHANGED){var r=En(this),o=r?{observableKind:"map",debugObjectName:this.name_,type:Pn,object:this,oldValue:n.value_,name:e,newValue:t}:null;n.setNewValue_(t),r&&kn(this,o)}},t.addValue_=function(e,t){var n=this;this.keysAtom_,An(function(){var r,o=new Xe(t,n.enhancer_,"ObservableMap.key",!1);n.data_.set(e,o),t=o.value_,null==(r=n.hasMap_.get(e))||r.setNewValue_(!0),n.keysAtom_.reportChanged()});var r=En(this),o=r?{observableKind:"map",debugObjectName:this.name_,type:$n,object:this,name:e,newValue:t}:null;r&&kn(this,o)},t.get=function(e){return this.has(e)?this.dehanceValue_(this.data_.get(e).get()):this.dehanceValue_(void 0)},t.getOrInsert=function(e,t){return this.has(e)||this.set(e,t),this.get(e)},t.getOrInsertComputed=function(e,t){return this.has(e)||this.set(e,t(e)),this.get(e)},t.dehanceValue_=function(e){return void 0!==this.dehancer?this.dehancer(e):e},t.keys=function(){return this.keysAtom_.reportObserved(),this.data_.keys()},t.values=function(){var e=this,t=this.keys();return Wn({next:function(){var n=t.next(),r=n.done,o=n.value;return{done:r,value:r?void 0:e.get(o)}}})},t.entries=function(){var e=this,t=this.keys();return Wn({next:function(){var n=t.next(),r=n.done,o=n.value;return{done:r,value:r?void 0:[o,e.get(o)]}}})},t[Symbol.iterator]=function(){return this.entries()},t.forEach=function(e,t){for(var n,r=F(this);!(n=r()).done;){var o=n.value,i=o[0],a=o[1];e.call(t,a,i,this)}},t.merge=function(e){var t=this;return Vn(e)&&(e=new Map(e)),An(function(){var n,o,i;y(e)?function(e){var t=Object.keys(e);if(!k)return t;var n=Object.getOwnPropertySymbols(e);return n.length?[].concat(t,n.filter(function(t){return c.propertyIsEnumerable.call(e,t)})):t}(e).forEach(function(n){return t.set(n,e[n])}):Array.isArray(e)?e.forEach(function(e){var n=e[0],r=e[1];return t.set(n,r)}):E(e)?(n=e,o=Object.getPrototypeOf(n),i=Object.getPrototypeOf(o),null!==Object.getPrototypeOf(i)&&r(19,e),e.forEach(function(e,n){return t.set(n,e)})):null!=e&&r(20,e)}),this},t.clear=function(){var e=this;An(function(){ct(function(){for(var t,n=F(e.keys());!(t=n()).done;){var r=t.value;e.delete(r)}})})},t.replace=function(e){var t=this;return An(function(){for(var n,o=function(e){if(E(e)||Vn(e))return e;if(Array.isArray(e))return new Map(e);if(y(e)){var t=new Map;for(var n in e)t.set(n,e[n]);return t}return r(21,e)}(e),i=new Map,a=!1,l=F(t.data_.keys());!(n=l()).done;){var s=n.value;if(!o.has(s))if(t.delete(s))a=!0;else{var c=t.data_.get(s);i.set(s,c)}}for(var u,d=F(o.entries());!(u=d()).done;){var f=u.value,p=f[0],h=f[1],g=t.data_.has(p);if(t.set(p,h),t.data_.has(p)){var m=t.data_.get(p);i.set(p,m),g||(a=!0)}}if(!a)if(t.data_.size!==i.size)t.keysAtom_.reportChanged();else for(var A=t.data_.keys(),b=i.keys(),v=A.next(),w=b.next();!v.done;){if(v.value!==w.value){t.keysAtom_.reportChanged();break}v=A.next(),w=b.next()}t.data_=i}),this},t.toString=function(){return"[object ObservableMap]"},t.toJSON=function(){return Array.from(this)},t.observe_=function(e,t){return In(this,e)},t.intercept_=function(e){return Sn(this,e)},L(e,[{key:"size",get:function(){return this.keysAtom_.reportObserved(),this.data_.size}},{key:Symbol.toStringTag,get:function(){return"Map"}}])}(),Vn=x("ObservableMap",Gn);function Wn(e){return e[Symbol.toStringTag]="MapIterator",Ir(e)}var Un={},qn=function(){function e(e,t,n){var o=this;void 0===t&&(t=te),void 0===n&&(n="ObservableSet"),this.name_=void 0,this[K]=Un,this.data_=new Set,this.atom_=void 0,this.changeListeners_=void 0,this.interceptors_=void 0,this.dehancer=void 0,this.enhancer_=void 0,this.name_=n,A(Set)||r(22),this.enhancer_=function(e,r){return t(e,r,n)},vr(function(){o.atom_=Z(o.name_),e&&o.replace(e)})}var t=e.prototype;return t.dehanceValue_=function(e){return void 0!==this.dehancer?this.dehancer(e):e},t.clear=function(){var e=this;An(function(){ct(function(){for(var t,n=F(e.data_.values());!(t=n()).done;){var r=t.value;e.delete(r)}})})},t.forEach=function(e,t){for(var n,r=F(this);!(n=r()).done;){var o=n.value;e.call(t,o,o,this)}},t.add=function(e){var t=this;if(this.atom_,Cn(this)){var n=xn(this,{type:$n,object:this,newValue:e});if(!n)return this;e=n.newValue}if(!this.has(e)){An(function(){t.data_.add(t.enhancer_(e,void 0)),t.atom_.reportChanged()});var r=En(this),o=r?{observableKind:"set",debugObjectName:this.name_,type:$n,object:this,newValue:e}:null;r&&kn(this,o)}return this},t.delete=function(e){var t=this;if(Cn(this)&&!xn(this,{type:Hn,object:this,oldValue:e}))return!1;if(this.has(e)){var n=En(this),r=n?{observableKind:"set",debugObjectName:this.name_,type:Hn,object:this,oldValue:e}:null;return An(function(){t.atom_.reportChanged(),t.data_.delete(e)}),n&&kn(this,r),!0}return!1},t.has=function(e){return this.atom_.reportObserved(),this.data_.has(this.dehanceValue_(e))},t.entries=function(){var e=this.values();return Kn({next:function(){var t=e.next(),n=t.value,r=t.done;return r?{value:void 0,done:r}:{value:[n,n],done:r}}})},t.keys=function(){return this.values()},t.values=function(){this.atom_.reportObserved();var e=this,t=this.data_.values();return Kn({next:function(){var n=t.next(),r=n.value,o=n.done;return o?{value:void 0,done:o}:{value:e.dehanceValue_(r),done:o}}})},t.intersection=function(e){return I(e)&&!Yn(e)?e.intersection(this):new Set(this).intersection(e)},t.union=function(e){return I(e)&&!Yn(e)?e.union(this):new Set(this).union(e)},t.difference=function(e){return new Set(this).difference(e)},t.symmetricDifference=function(e){return I(e)&&!Yn(e)?e.symmetricDifference(this):new Set(this).symmetricDifference(e)},t.isSubsetOf=function(e){return new Set(this).isSubsetOf(e)},t.isSupersetOf=function(e){return new Set(this).isSupersetOf(e)},t.isDisjointFrom=function(e){return I(e)&&!Yn(e)?e.isDisjointFrom(this):new Set(this).isDisjointFrom(e)},t.replace=function(e){var t=this;return Yn(e)&&(e=new Set(e)),An(function(){Array.isArray(e)||I(e)?(t.clear(),e.forEach(function(e){return t.add(e)})):null!=e&&r("Cannot initialize set from "+e)}),this},t.observe_=function(e,t){return In(this,e)},t.intercept_=function(e){return Sn(this,e)},t.toJSON=function(){return Array.from(this)},t.toString=function(){return"[object ObservableSet]"},t[Symbol.iterator]=function(){return this.values()},L(e,[{key:"size",get:function(){return this.atom_.reportObserved(),this.data_.size}},{key:Symbol.toStringTag,get:function(){return"Set"}}])}(),Yn=x("ObservableSet",qn);function Kn(e){return e[Symbol.toStringTag]="SetIterator",Ir(e)}var Jn=Object.create(null),Xn="remove",Zn=function(){function e(e,t,n,r){void 0===t&&(t=new Map),void 0===r&&(r=Ce),this.target_=void 0,this.values_=void 0,this.name_=void 0,this.defaultAnnotation_=void 0,this.keysAtom_=void 0,this.changeListeners_=void 0,this.interceptors_=void 0,this.proxy_=void 0,this.isPlainObject_=void 0,this.appliedAnnotations_=void 0,this.pendingKeys_=void 0,this.lazyComputedKeys_=void 0,this.lazyObservableKeys_=void 0,this.target_=e,this.values_=t,this.name_=n,this.defaultAnnotation_=r,this.keysAtom_=new J("ObservableObject.keys"),this.isPlainObject_=y(this.target_)}var t=e.prototype;return t.getObservablePropValue_=function(e){var t,n;return(null!=(t=null!=(n=this.values_.get(e))?n:this.materializeLazyComputed_(e))?t:this.materializeLazyObservable_(e)).get()},t.materializeLazyComputed_=function(e){var t,n=null==(t=this.lazyComputedKeys_)?void 0:t.get(e);if(n){this.lazyComputedKeys_.delete(e),0===this.lazyComputedKeys_.size&&(this.lazyComputedKeys_=void 0);var r=n();return this.values_.set(e,r),r}},t.materializeLazyObservable_=function(e){var t,n=null==(t=this.lazyObservableKeys_)?void 0:t.get(e);if(n){this.lazyObservableKeys_.delete(e),0===this.lazyObservableKeys_.size&&(this.lazyObservableKeys_=void 0);var r=n();return this.values_.set(e,r),r}},t.setObservablePropValue_=function(e,t){var n,r,o=null!=(n=null!=(r=this.values_.get(e))?r:this.materializeLazyComputed_(e))?n:this.materializeLazyObservable_(e);if(o instanceof et)return o.set(t),!0;if(Cn(this)){var i=xn(this,{type:Pn,object:this.proxy_||this.target_,name:e,newValue:t});if(!i)return null;t=i.newValue}if((t=o.prepareNewValue_(t))!==bt.UNCHANGED){var a=En(this),l=a?{type:Pn,observableKind:"object",debugObjectName:this.name_,object:this.proxy_||this.target_,oldValue:o.value_,name:e,newValue:t}:null;o.setNewValue_(t),a&&kn(this,l)}return!0},t.get_=function(e){return bt.trackingDerivation&&!P(this.target_,e)&&this.has_(e),this.target_[e]},t.set_=function(e,t,n){return void 0===n&&(n=!1),P(this.target_,e)?this.values_.has(e)?this.setObservablePropValue_(e,t):n?Reflect.set(this.target_,e,t):(this.target_[e]=t,!0):this.extend_(e,{value:t,enumerable:!0,writable:!0,configurable:!0},this.defaultAnnotation_,n)},t.has_=function(e){if(!bt.trackingDerivation)return e in this.target_;this.pendingKeys_||(this.pendingKeys_=new Map);var t=this.pendingKeys_.get(e);return t||(t=new Xe(e in this.target_,ne,"ObservableObject.key?",!1),this.pendingKeys_.set(e,t)),t.get()},t.make_=function(e,t){if(!0===t&&(t=this.defaultAnnotation_),!1!==t){if(!(e in this.target_)){var n;if(null!=(n=this.target_[W])&&n[e])return;r(1,t.annotationType_,this.name_+"."+e.toString())}for(var o=this.target_;o&&o!==c;){var i=l(o,e);if(i){var a=t.make_(this,e,i,o);if(0===a)return;if(1===a)break}o=Object.getPrototypeOf(o)}or(this,0,e)}},t.extend_=function(e,t,n,r){if(void 0===r&&(r=!1),!0===n&&(n=this.defaultAnnotation_),!1===n)return this.defineProperty_(e,t,r);var o=n.extend_(this,e,t,r);return o&&or(this,0,e),o},t.defineProperty_=function(e,t,n){void 0===n&&(n=!1),this.keysAtom_;try{St();var r=this.delete_(e);if(!r)return r;if(Cn(this)){var o=xn(this,{object:this.proxy_||this.target_,name:e,type:$n,newValue:t.value});if(!o)return null;var i=o.newValue;t.value!==i&&(t=Q({},t,{value:i}))}if(n){if(!Reflect.defineProperty(this.target_,e,t))return!1}else s(this.target_,e,t);this.notifyPropertyAddition_(e,t.value)}finally{xt()}return!0},t.defineObservableProperty_=function(e,t,n,r){void 0===r&&(r=!1),this.keysAtom_;try{St();var o=this.delete_(e);if(!o)return o;if(Cn(this)){var i=xn(this,{object:this.proxy_||this.target_,name:e,type:$n,newValue:t});if(!i)return null;t=i.newValue}var a=nr(e),l={configurable:!bt.safeDescriptors||this.isPlainObject_,enumerable:!0,get:a.get,set:a.set};if(r){if(!Reflect.defineProperty(this.target_,e,l))return!1}else s(this.target_,e,l);var c=new Xe(t,n,"ObservableObject.key",!1);this.values_.set(e,c),this.notifyPropertyAddition_(e,c.value_)}finally{xt()}return!0},t.defineComputedProperty_=function(e,t,n){void 0===n&&(n=!1),this.keysAtom_;try{St();var r=this.delete_(e);if(!r)return r;if(Cn(this)&&!xn(this,{object:this.proxy_||this.target_,name:e,type:$n,newValue:void 0}))return null;t.name||(t.name="ObservableObject.key"),t.context=this.proxy_||this.target_;var o=nr(e),i={configurable:!bt.safeDescriptors||this.isPlainObject_,enumerable:!1,get:o.get,set:o.set};if(n){if(!Reflect.defineProperty(this.target_,e,i))return!1}else s(this.target_,e,i);this.values_.set(e,new et(t)),this.notifyPropertyAddition_(e,void 0)}finally{xt()}return!0},t.delete_=function(e,t){if(void 0===t&&(t=!1),this.keysAtom_,!P(this.target_,e))return!0;if(Cn(this)&&!xn(this,{object:this.proxy_||this.target_,name:e,type:Xn}))return null;try{var n;St();var r,o=En(this),i=this.values_.get(e),a=void 0;if(!i&&o&&(a=null==(r=l(this.target_,e))?void 0:r.value),t){if(!Reflect.deleteProperty(this.target_,e))return!1}else delete this.target_[e];if(i&&(this.values_.delete(e),i instanceof Xe&&(a=i.value_),It(i)),this.keysAtom_.reportChanged(),null==(n=this.pendingKeys_)||null==(n=n.get(e))||n.set(e in this.target_),o){var s={type:Xn,observableKind:"object",object:this.proxy_||this.target_,debugObjectName:this.name_,oldValue:a,name:e};o&&kn(this,s)}}finally{xt()}return!0},t.observe_=function(e,t){return In(this,e)},t.intercept_=function(e){return Sn(this,e)},t.notifyPropertyAddition_=function(e,t){var n,r=En(this);if(r){var o=r?{type:$n,observableKind:"object",debugObjectName:this.name_,object:this.proxy_||this.target_,name:e,newValue:t}:null;r&&kn(this,o)}null==(n=this.pendingKeys_)||null==(n=n.get(e))||n.set(!0),this.keysAtom_.reportChanged()},t.ownKeys_=function(){return this.keysAtom_.reportObserved(),R(this.target_)},t.keys_=function(){return this.keysAtom_.reportObserved(),Object.keys(this.target_)},e}();function er(e,t){var n;if(P(e,K))return e;var r=null!=(n=null==t?void 0:t.name)?n:"ObservableObject",o=new Zn(e,new Map,String(r),function(e){var t;return e?null!=(t=e.defaultDecorator)?t:Se(e):void 0}(t));return C(e,K,o),e}var tr=x("ObservableObjectAdministration",Zn);function nr(e){return Jn[e]||(Jn[e]={get:function(){return this[K].getObservablePropValue_(e)},set:function(t){return this[K].setObservablePropValue_(e,t)}})}function rr(e){return!!v(e)&&tr(e[K])}function or(e,t,n){var r;null==(r=e.target_[W])||delete r[n]}var ir,ar,lr=fr(0),sr=function(){var e=!1,t={};return Object.defineProperty(t,"0",{set:function(){e=!0}}),Object.create(t)[0]=1,!1===e}(),cr=0,ur=function(){};ir=ur,ar=Array.prototype,Object.setPrototypeOf?Object.setPrototypeOf(ir.prototype,ar):void 0!==ir.prototype.__proto__?ir.prototype.__proto__=ar:ir.prototype=ar;var dr=function(e){function t(t,n,r,o){var i;return void 0===r&&(r="ObservableArray"),void 0===o&&(o=!1),i=e.call(this)||this,vr(function(){var e=new _n(r,n,o,!0);e.proxy_=i,S(i,K,e),t&&t.length&&i.spliceWithArray(0,0,t),sr&&Object.defineProperty(i,"0",lr)}),i}z(t,e);var n=t.prototype;return n.concat=function(){this[K].atom_.reportObserved();for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return Array.prototype.concat.apply(this.slice(),t.map(function(e){return jn(e)?e.slice():e}))},n[Symbol.iterator]=function(){var e=this,t=0;return Ir({next:function(){return t<e.length?{value:e[t++],done:!1}:{done:!0,value:void 0}}})},L(t,[{key:"length",get:function(){return this[K].getArrayLength_()},set:function(e){this[K].setArrayLength_(e)}},{key:Symbol.toStringTag,get:function(){return"Array"}}])}(ur);function fr(e){return{enumerable:!1,configurable:!0,get:function(){return this[K].get_(e)},set:function(t){this[K].set_(e,t)}}}function pr(e){s(dr.prototype,""+e,fr(e))}function hr(e){if(e>cr){for(var t=cr;t<e+100;t++)pr(t);cr=e}}function gr(e,t,n){return new dr(e,t,n)}function mr(e,t){if("object"==typeof e&&null!==e){if(jn(e))return void 0!==t&&r(23),e[K].atom_;if(Yn(e))return e.atom_;if(Vn(e)){if(void 0===t)return e.keysAtom_;var n=e.data_.get(t)||e.hasMap_.get(t);return n||r(25,t,br(e)),n}if(rr(e)){var o,i;if(!t)return r(26);var a=e[K],l=null!=(o=null!=(i=a.values_.get(t))?i:a.materializeLazyComputed_(t))?o:a.materializeLazyObservable_(t);return l||r(27,t,br(e)),l}if(X(e)||rt(e)||Bt(e))return e}else if(A(e)&&Bt(e[K]))return e[K];r(28)}function Ar(e,t){return e||r(29),void 0!==t?Ar(mr(e,t)):X(e)||rt(e)||Bt(e)||Vn(e)||Yn(e)?e:e[K]?e[K]:void r(24,e)}function br(e,t){var n;if(void 0!==t)n=mr(e,t);else{if($t(e))return e.name;n=rr(e)||Vn(e)||Yn(e)?Ar(e):mr(e)}return n.name_}function vr(e){var t=ut(),n=Ke(!0);St();try{return e()}finally{xt(),Je(n),dt(t)}}Object.entries(On).forEach(function(e){var t=e[0],n=e[1];"concat"!==t&&C(dr.prototype,t,n)}),hr(1e3);var yr,wr=c.toString;function Cr(e,t,n){return void 0===n&&(n=-1),Sr(e,t,n)}function Sr(e,t,n,r,o){if(e===t)return 0!==e||1/e==1/t;if(null==e||null==t)return!1;if(e!=e)return t!=t;var i=typeof e;if("function"!==i&&"object"!==i&&"object"!=typeof t)return!1;var a=wr.call(e);if(a!==wr.call(t))return!1;switch(a){case"[object RegExp]":case"[object String]":return""+e==""+t;case"[object Number]":return+e!=+e?+t!=+t:0===+e?1/+e==1/t:+e===+t;case"[object Date]":case"[object Boolean]":return+e===+t;case"[object Symbol]":return"undefined"!=typeof Symbol&&Symbol.valueOf.call(e)===Symbol.valueOf.call(t);case"[object Map]":case"[object Set]":n>=0&&n++}e=xr(e),t=xr(t);var l="[object Array]"===a;if(!l){if("object"!=typeof e||"object"!=typeof t)return!1;var s=e.constructor,c=t.constructor;if(s!==c&&!(A(s)&&s instanceof s&&A(c)&&c instanceof c)&&"constructor"in e&&"constructor"in t)return!1}if(0===n)return!1;n<0&&(n=-1),o=o||[];for(var u=(r=r||[]).length;u--;)if(r[u]===e)return o[u]===t;if(r.push(e),o.push(t),l){if((u=e.length)!==t.length)return!1;for(;u--;)if(!Sr(e[u],t[u],n-1,r,o))return!1}else{var d=Object.keys(e),f=d.length;if(Object.keys(t).length!==f)return!1;for(var p=0;p<f;p++){var h=d[p];if(!P(t,h)||!Sr(e[h],t[h],n-1,r,o))return!1}}return r.pop(),o.pop(),!0}function xr(e){return jn(e)?e.slice():E(e)||Vn(e)||I(e)||Yn(e)?Array.from(e.entries()):e}var Er=(null==(yr=i().Iterator)?void 0:yr.prototype)||{};function Ir(e){return e[Symbol.iterator]=kr,Object.assign(Object.create(Er),e)}function kr(){return this}["Symbol","Map","Set"].forEach(function(e){void 0===i()[e]&&r("MobX requires global '"+e+"' to be available or polyfilled")}),"object"==typeof __MOBX_DEVTOOLS_GLOBAL_HOOK__&&__MOBX_DEVTOOLS_GLOBAL_HOOK__.injectMobx({spy:function(e){return console.warn("[mobx.spy] Is a no-op in production builds"),function(){}},extras:{getDebugName:br},$mobx:K})},7265(e,t,n){"use strict";var r=n(3034);function o(){}function i(){}i.resetWarningCache=o,e.exports=function(){function e(e,t,n,o,i,a){if(a!==r){var l=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw l.name="Invariant Violation",l}}function t(){return e}e.isRequired=e;var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:i,resetWarningCache:o};return n.PropTypes=n,n}},5821(e,t,n){e.exports=n(7265)()},3034(e){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},4482(e,t,n){"use strict";var r=n(3480),o=n(405),i=n(7868);function a(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n])}return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function l(e){return!(!e||1!==e.nodeType&&9!==e.nodeType&&11!==e.nodeType)}function s(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do{!!(4098&(t=e).flags)&&(n=t.return),e=t.return}while(e)}return 3===t.tag?n:null}function c(e){if(13===e.tag){var t=e.memoizedState;if(null===t&&null!==(e=e.alternate)&&(t=e.memoizedState),null!==t)return t.dehydrated}return null}function u(e){if(31===e.tag){var t=e.memoizedState;if(null===t&&null!==(e=e.alternate)&&(t=e.memoizedState),null!==t)return t.dehydrated}return null}function d(e){if(s(e)!==e)throw Error(a(188))}function f(e){var t=e.tag;if(5===t||26===t||27===t||6===t)return e;for(e=e.child;null!==e;){if(null!==(t=f(e)))return t;e=e.sibling}return null}var p=Object.assign,h=Symbol.for("react.element"),g=Symbol.for("react.transitional.element"),m=Symbol.for("react.portal"),A=Symbol.for("react.fragment"),b=Symbol.for("react.strict_mode"),v=Symbol.for("react.profiler"),y=Symbol.for("react.consumer"),w=Symbol.for("react.context"),C=Symbol.for("react.forward_ref"),S=Symbol.for("react.suspense"),x=Symbol.for("react.suspense_list"),E=Symbol.for("react.memo"),I=Symbol.for("react.lazy");Symbol.for("react.scope");var k=Symbol.for("react.activity");Symbol.for("react.legacy_hidden"),Symbol.for("react.tracing_marker");var R=Symbol.for("react.memo_cache_sentinel");Symbol.for("react.view_transition");var M=Symbol.iterator;function P(e){return null===e||"object"!=typeof e?null:"function"==typeof(e=M&&e[M]||e["@@iterator"])?e:null}var B=Symbol.for("react.client.reference");function _(e){if(null==e)return null;if("function"==typeof e)return e.$$typeof===B?null:e.displayName||e.name||null;if("string"==typeof e)return e;switch(e){case A:return"Fragment";case v:return"Profiler";case b:return"StrictMode";case S:return"Suspense";case x:return"SuspenseList";case k:return"Activity"}if("object"==typeof e)switch(e.$$typeof){case m:return"Portal";case w:return e.displayName||"Context";case y:return(e._context.displayName||"Context")+".Consumer";case C:var t=e.render;return(e=e.displayName)||(e=""!==(e=t.displayName||t.name||"")?"ForwardRef("+e+")":"ForwardRef"),e;case E:return null!==(t=e.displayName||null)?t:_(e.type)||"Memo";case I:t=e._payload,e=e._init;try{return _(e(t))}catch(e){}}return null}var T=Array.isArray,O=o.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,D=i.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,N={pending:!1,data:null,method:null,action:null},L=[],F=-1;function Q(e){return{current:e}}function j(e){0>F||(e.current=L[F],L[F]=null,F--)}function z(e,t){F++,L[F]=e.current,e.current=t}var $,H,G=Q(null),V=Q(null),W=Q(null),U=Q(null);function q(e,t){switch(z(W,t),z(V,e),z(G,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?Ad(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)e=bd(t=Ad(t),e);else switch(e){case"svg":e=1;break;case"math":e=2;break;default:e=0}}j(G),z(G,e)}function Y(){j(G),j(V),j(W)}function K(e){null!==e.memoizedState&&z(U,e);var t=G.current,n=bd(t,e.type);t!==n&&(z(V,e),z(G,n))}function J(e){V.current===e&&(j(G),j(V)),U.current===e&&(j(U),df._currentValue=N)}function X(e){if(void 0===$)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);$=t&&t[1]||"",H=-1<e.stack.indexOf("\n at")?" (<anonymous>)":-1<e.stack.indexOf("@")?"@unknown:0:0":""}return"\n"+$+e+H}var Z=!1;function ee(e,t){if(!e||Z)return"";Z=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var r={DetermineComponentFrameRoot:function(){try{if(t){var n=function(){throw Error()};if(Object.defineProperty(n.prototype,"props",{set:function(){throw Error()}}),"object"==typeof Reflect&&Reflect.construct){try{Reflect.construct(n,[])}catch(e){var r=e}Reflect.construct(e,[],n)}else{try{n.call()}catch(e){r=e}e.call(n.prototype)}}else{try{throw Error()}catch(e){r=e}(n=e())&&"function"==typeof n.catch&&n.catch(function(){})}}catch(e){if(e&&r&&"string"==typeof e.stack)return[e.stack,r.stack]}return[null,null]}};r.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var o=Object.getOwnPropertyDescriptor(r.DetermineComponentFrameRoot,"name");o&&o.configurable&&Object.defineProperty(r.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var i=r.DetermineComponentFrameRoot(),a=i[0],l=i[1];if(a&&l){var s=a.split("\n"),c=l.split("\n");for(o=r=0;r<s.length&&!s[r].includes("DetermineComponentFrameRoot");)r++;for(;o<c.length&&!c[o].includes("DetermineComponentFrameRoot");)o++;if(r===s.length||o===c.length)for(r=s.length-1,o=c.length-1;1<=r&&0<=o&&s[r]!==c[o];)o--;for(;1<=r&&0<=o;r--,o--)if(s[r]!==c[o]){if(1!==r||1!==o)do{if(r--,0>--o||s[r]!==c[o]){var u="\n"+s[r].replace(" at new "," at ");return e.displayName&&u.includes("<anonymous>")&&(u=u.replace("<anonymous>",e.displayName)),u}}while(1<=r&&0<=o);break}}}finally{Z=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:"")?X(n):""}function te(e,t){switch(e.tag){case 26:case 27:case 5:return X(e.type);case 16:return X("Lazy");case 13:return e.child!==t&&null!==t?X("Suspense Fallback"):X("Suspense");case 19:return X("SuspenseList");case 0:case 15:return ee(e.type,!1);case 11:return ee(e.type.render,!1);case 1:return ee(e.type,!0);case 31:return X("Activity");default:return""}}function ne(e){try{var t="",n=null;do{t+=te(e,n),n=e,e=e.return}while(e);return t}catch(e){return"\nError generating stack: "+e.message+"\n"+e.stack}}var re=Object.prototype.hasOwnProperty,oe=r.unstable_scheduleCallback,ie=r.unstable_cancelCallback,ae=r.unstable_shouldYield,le=r.unstable_requestPaint,se=r.unstable_now,ce=r.unstable_getCurrentPriorityLevel,ue=r.unstable_ImmediatePriority,de=r.unstable_UserBlockingPriority,fe=r.unstable_NormalPriority,pe=r.unstable_LowPriority,he=r.unstable_IdlePriority,ge=r.log,me=r.unstable_setDisableYieldValue,Ae=null,be=null;function ve(e){if("function"==typeof ge&&me(e),be&&"function"==typeof be.setStrictMode)try{be.setStrictMode(Ae,e)}catch(e){}}var ye=Math.clz32?Math.clz32:function(e){return 0==(e>>>=0)?32:31-(we(e)/Ce|0)|0},we=Math.log,Ce=Math.LN2,Se=256,xe=262144,Ee=4194304;function Ie(e){var t=42&e;if(0!==t)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return 261888&e;case 262144:case 524288:case 1048576:case 2097152:return 3932160&e;case 4194304:case 8388608:case 16777216:case 33554432:return 62914560&e;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function ke(e,t,n){var r=e.pendingLanes;if(0===r)return 0;var o=0,i=e.suspendedLanes,a=e.pingedLanes;e=e.warmLanes;var l=134217727&r;return 0!==l?0!==(r=l&~i)?o=Ie(r):0!==(a&=l)?o=Ie(a):n||0!==(n=l&~e)&&(o=Ie(n)):0!==(l=r&~i)?o=Ie(l):0!==a?o=Ie(a):n||0!==(n=r&~e)&&(o=Ie(n)),0===o?0:0!==t&&t!==o&&0===(t&i)&&((i=o&-o)>=(n=t&-t)||32===i&&4194048&n)?t:o}function Re(e,t){return 0===(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)}function Me(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;default:return-1}}function Pe(){var e=Ee;return!(62914560&(Ee<<=1))&&(Ee=4194304),e}function Be(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function _e(e,t){e.pendingLanes|=t,268435456!==t&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function Te(e,t,n){e.pendingLanes|=t,e.suspendedLanes&=~t;var r=31-ye(t);e.entangledLanes|=t,e.entanglements[r]=1073741824|e.entanglements[r]|261930&n}function Oe(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-ye(n),o=1<<r;o&t|e[r]&t&&(e[r]|=t),n&=~o}}function De(e,t){var n=t&-t;return 0!==((n=42&n?1:Ne(n))&(e.suspendedLanes|t))?0:n}function Ne(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function Le(e){return 2<(e&=-e)?8<e?134217727&e?32:268435456:8:2}function Fe(){var e=D.p;return 0!==e?e:void 0===(e=window.event)?32:kf(e.type)}function Qe(e,t){var n=D.p;try{return D.p=e,t()}finally{D.p=n}}var je=Math.random().toString(36).slice(2),ze="__reactFiber$"+je,$e="__reactProps$"+je,He="__reactContainer$"+je,Ge="__reactEvents$"+je,Ve="__reactListeners$"+je,We="__reactHandles$"+je,Ue="__reactResources$"+je,qe="__reactMarker$"+je;function Ye(e){delete e[ze],delete e[$e],delete e[Ge],delete e[Ve],delete e[We]}function Ke(e){var t=e[ze];if(t)return t;for(var n=e.parentNode;n;){if(t=n[He]||n[ze]){if(n=t.alternate,null!==t.child||null!==n&&null!==n.child)for(e=Nd(e);null!==e;){if(n=e[ze])return n;e=Nd(e)}return t}n=(e=n).parentNode}return null}function Je(e){if(e=e[ze]||e[He]){var t=e.tag;if(5===t||6===t||13===t||31===t||26===t||27===t||3===t)return e}return null}function Xe(e){var t=e.tag;if(5===t||26===t||27===t||6===t)return e.stateNode;throw Error(a(33))}function Ze(e){var t=e[Ue];return t||(t=e[Ue]={hoistableStyles:new Map,hoistableScripts:new Map}),t}function et(e){e[qe]=!0}var tt=new Set,nt={};function rt(e,t){ot(e,t),ot(e+"Capture",t)}function ot(e,t){for(nt[e]=t,e=0;e<t.length;e++)tt.add(t[e])}var it=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),at={},lt={};function st(e,t,n){if(o=t,re.call(lt,o)||!re.call(at,o)&&(it.test(o)?lt[o]=!0:(at[o]=!0,0)))if(null===n)e.removeAttribute(t);else{switch(typeof n){case"undefined":case"function":case"symbol":return void e.removeAttribute(t);case"boolean":var r=t.toLowerCase().slice(0,5);if("data-"!==r&&"aria-"!==r)return void e.removeAttribute(t)}e.setAttribute(t,""+n)}var o}function ct(e,t,n){if(null===n)e.removeAttribute(t);else{switch(typeof n){case"undefined":case"function":case"symbol":case"boolean":return void e.removeAttribute(t)}e.setAttribute(t,""+n)}}function ut(e,t,n,r){if(null===r)e.removeAttribute(n);else{switch(typeof r){case"undefined":case"function":case"symbol":case"boolean":return void e.removeAttribute(n)}e.setAttributeNS(t,n,""+r)}}function dt(e){switch(typeof e){case"bigint":case"boolean":case"number":case"string":case"undefined":case"object":return e;default:return""}}function ft(e){var t=e.type;return(e=e.nodeName)&&"input"===e.toLowerCase()&&("checkbox"===t||"radio"===t)}function pt(e){if(!e._valueTracker){var t=ft(e)?"checked":"value";e._valueTracker=function(e,t,n){var r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t);if(!e.hasOwnProperty(t)&&void 0!==r&&"function"==typeof r.get&&"function"==typeof r.set){var o=r.get,i=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return o.call(this)},set:function(e){n=""+e,i.call(this,e)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(e){n=""+e},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}(e,t,""+e[t])}}function ht(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=ft(e)?e.checked?"true":"false":e.value),(e=r)!==n&&(t.setValue(e),!0)}function gt(e){if(void 0===(e=e||("undefined"!=typeof document?document:void 0)))return null;try{return e.activeElement||e.body}catch(t){return e.body}}var mt=/[\n"\\]/g;function At(e){return e.replace(mt,function(e){return"\\"+e.charCodeAt(0).toString(16)+" "})}function bt(e,t,n,r,o,i,a,l){e.name="",null!=a&&"function"!=typeof a&&"symbol"!=typeof a&&"boolean"!=typeof a?e.type=a:e.removeAttribute("type"),null!=t?"number"===a?(0===t&&""===e.value||e.value!=t)&&(e.value=""+dt(t)):e.value!==""+dt(t)&&(e.value=""+dt(t)):"submit"!==a&&"reset"!==a||e.removeAttribute("value"),null!=t?yt(e,a,dt(t)):null!=n?yt(e,a,dt(n)):null!=r&&e.removeAttribute("value"),null==o&&null!=i&&(e.defaultChecked=!!i),null!=o&&(e.checked=o&&"function"!=typeof o&&"symbol"!=typeof o),null!=l&&"function"!=typeof l&&"symbol"!=typeof l&&"boolean"!=typeof l?e.name=""+dt(l):e.removeAttribute("name")}function vt(e,t,n,r,o,i,a,l){if(null!=i&&"function"!=typeof i&&"symbol"!=typeof i&&"boolean"!=typeof i&&(e.type=i),null!=t||null!=n){if(("submit"===i||"reset"===i)&&null==t)return void pt(e);n=null!=n?""+dt(n):"",t=null!=t?""+dt(t):n,l||t===e.value||(e.value=t),e.defaultValue=t}r="function"!=typeof(r=null!=r?r:o)&&"symbol"!=typeof r&&!!r,e.checked=l?e.checked:!!r,e.defaultChecked=!!r,null!=a&&"function"!=typeof a&&"symbol"!=typeof a&&"boolean"!=typeof a&&(e.name=a),pt(e)}function yt(e,t,n){"number"===t&>(e.ownerDocument)===e||e.defaultValue===""+n||(e.defaultValue=""+n)}function wt(e,t,n,r){if(e=e.options,t){t={};for(var o=0;o<n.length;o++)t["$"+n[o]]=!0;for(n=0;n<e.length;n++)o=t.hasOwnProperty("$"+e[n].value),e[n].selected!==o&&(e[n].selected=o),o&&r&&(e[n].defaultSelected=!0)}else{for(n=""+dt(n),t=null,o=0;o<e.length;o++){if(e[o].value===n)return e[o].selected=!0,void(r&&(e[o].defaultSelected=!0));null!==t||e[o].disabled||(t=e[o])}null!==t&&(t.selected=!0)}}function Ct(e,t,n){null==t||((t=""+dt(t))!==e.value&&(e.value=t),null!=n)?e.defaultValue=null!=n?""+dt(n):"":e.defaultValue!==t&&(e.defaultValue=t)}function St(e,t,n,r){if(null==t){if(null!=r){if(null!=n)throw Error(a(92));if(T(r)){if(1<r.length)throw Error(a(93));r=r[0]}n=r}null==n&&(n=""),t=n}n=dt(t),e.defaultValue=n,(r=e.textContent)===n&&""!==r&&null!==r&&(e.value=r),pt(e)}function xt(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&3===n.nodeType)return void(n.nodeValue=t)}e.textContent=t}var Et=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function It(e,t,n){var r=0===t.indexOf("--");null==n||"boolean"==typeof n||""===n?r?e.setProperty(t,""):"float"===t?e.cssFloat="":e[t]="":r?e.setProperty(t,n):"number"!=typeof n||0===n||Et.has(t)?"float"===t?e.cssFloat=n:e[t]=(""+n).trim():e[t]=n+"px"}function kt(e,t,n){if(null!=t&&"object"!=typeof t)throw Error(a(62));if(e=e.style,null!=n){for(var r in n)!n.hasOwnProperty(r)||null!=t&&t.hasOwnProperty(r)||(0===r.indexOf("--")?e.setProperty(r,""):"float"===r?e.cssFloat="":e[r]="");for(var o in t)r=t[o],t.hasOwnProperty(o)&&n[o]!==r&&It(e,o,r)}else for(var i in t)t.hasOwnProperty(i)&&It(e,i,t[i])}function Rt(e){if(-1===e.indexOf("-"))return!1;switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Mt=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),Pt=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function Bt(e){return Pt.test(""+e)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":e}function _t(){}var Tt=null;function Ot(e){return(e=e.target||e.srcElement||window).correspondingUseElement&&(e=e.correspondingUseElement),3===e.nodeType?e.parentNode:e}var Dt=null,Nt=null;function Lt(e){var t=Je(e);if(t&&(e=t.stateNode)){var n=e[$e]||null;e:switch(e=t.stateNode,t.type){case"input":if(bt(e,n.value,n.defaultValue,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name),t=n.name,"radio"===n.type&&null!=t){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll('input[name="'+At(""+t)+'"][type="radio"]'),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var o=r[$e]||null;if(!o)throw Error(a(90));bt(r,o.value,o.defaultValue,o.defaultValue,o.checked,o.defaultChecked,o.type,o.name)}}for(t=0;t<n.length;t++)(r=n[t]).form===e.form&&ht(r)}break e;case"textarea":Ct(e,n.value,n.defaultValue);break e;case"select":null!=(t=n.value)&&wt(e,!!n.multiple,t,!1)}}}var Ft=!1;function Qt(e,t,n){if(Ft)return e(t,n);Ft=!0;try{return e(t)}finally{if(Ft=!1,(null!==Dt||null!==Nt)&&(Zc(),Dt&&(t=Dt,e=Nt,Nt=Dt=null,Lt(t),e)))for(t=0;t<e.length;t++)Lt(e[t])}}function jt(e,t){var n=e.stateNode;if(null===n)return null;var r=n[$e]||null;if(null===r)return null;n=r[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(r=!r.disabled)||(r=!("button"===(e=e.type)||"input"===e||"select"===e||"textarea"===e)),e=!r;break e;default:e=!1}if(e)return null;if(n&&"function"!=typeof n)throw Error(a(231,t,typeof n));return n}var zt=!("undefined"==typeof window||void 0===window.document||void 0===window.document.createElement),$t=!1;if(zt)try{var Ht={};Object.defineProperty(Ht,"passive",{get:function(){$t=!0}}),window.addEventListener("test",Ht,Ht),window.removeEventListener("test",Ht,Ht)}catch(e){$t=!1}var Gt=null,Vt=null,Wt=null;function Ut(){if(Wt)return Wt;var e,t,n=Vt,r=n.length,o="value"in Gt?Gt.value:Gt.textContent,i=o.length;for(e=0;e<r&&n[e]===o[e];e++);var a=r-e;for(t=1;t<=a&&n[r-t]===o[i-t];t++);return Wt=o.slice(e,1<t?1-t:void 0)}function qt(e){var t=e.keyCode;return"charCode"in e?0===(e=e.charCode)&&13===t&&(e=13):e=t,10===e&&(e=13),32<=e||13===e?e:0}function Yt(){return!0}function Kt(){return!1}function Jt(e){function t(t,n,r,o,i){for(var a in this._reactName=t,this._targetInst=r,this.type=n,this.nativeEvent=o,this.target=i,this.currentTarget=null,e)e.hasOwnProperty(a)&&(t=e[a],this[a]=t?t(o):o[a]);return this.isDefaultPrevented=(null!=o.defaultPrevented?o.defaultPrevented:!1===o.returnValue)?Yt:Kt,this.isPropagationStopped=Kt,this}return p(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():"unknown"!=typeof e.returnValue&&(e.returnValue=!1),this.isDefaultPrevented=Yt)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():"unknown"!=typeof e.cancelBubble&&(e.cancelBubble=!0),this.isPropagationStopped=Yt)},persist:function(){},isPersistent:Yt}),t}var Xt,Zt,en,tn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},nn=Jt(tn),rn=p({},tn,{view:0,detail:0}),on=Jt(rn),an=p({},rn,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:An,button:0,buttons:0,relatedTarget:function(e){return void 0===e.relatedTarget?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==en&&(en&&"mousemove"===e.type?(Xt=e.screenX-en.screenX,Zt=e.screenY-en.screenY):Zt=Xt=0,en=e),Xt)},movementY:function(e){return"movementY"in e?e.movementY:Zt}}),ln=Jt(an),sn=Jt(p({},an,{dataTransfer:0})),cn=Jt(p({},rn,{relatedTarget:0})),un=Jt(p({},tn,{animationName:0,elapsedTime:0,pseudoElement:0})),dn=Jt(p({},tn,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}})),fn=Jt(p({},tn,{data:0})),pn={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},hn={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},gn={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function mn(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):!!(e=gn[e])&&!!t[e]}function An(){return mn}var bn=Jt(p({},rn,{key:function(e){if(e.key){var t=pn[e.key]||e.key;if("Unidentified"!==t)return t}return"keypress"===e.type?13===(e=qt(e))?"Enter":String.fromCharCode(e):"keydown"===e.type||"keyup"===e.type?hn[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:An,charCode:function(e){return"keypress"===e.type?qt(e):0},keyCode:function(e){return"keydown"===e.type||"keyup"===e.type?e.keyCode:0},which:function(e){return"keypress"===e.type?qt(e):"keydown"===e.type||"keyup"===e.type?e.keyCode:0}})),vn=Jt(p({},an,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0})),yn=Jt(p({},rn,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:An})),wn=Jt(p({},tn,{propertyName:0,elapsedTime:0,pseudoElement:0})),Cn=Jt(p({},an,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0})),Sn=Jt(p({},tn,{newState:0,oldState:0})),xn=[9,13,27,32],En=zt&&"CompositionEvent"in window,In=null;zt&&"documentMode"in document&&(In=document.documentMode);var kn=zt&&"TextEvent"in window&&!In,Rn=zt&&(!En||In&&8<In&&11>=In),Mn=String.fromCharCode(32),Pn=!1;function Bn(e,t){switch(e){case"keyup":return-1!==xn.indexOf(t.keyCode);case"keydown":return 229!==t.keyCode;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function _n(e){return"object"==typeof(e=e.detail)&&"data"in e?e.data:null}var Tn=!1,On={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function Dn(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return"input"===t?!!On[e.type]:"textarea"===t}function Nn(e,t,n,r){Dt?Nt?Nt.push(r):Nt=[r]:Dt=r,0<(t=rd(t,"onChange")).length&&(n=new nn("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var Ln=null,Fn=null;function Qn(e){Yu(e,0)}function jn(e){if(ht(Xe(e)))return e}function zn(e,t){if("change"===e)return t}var $n=!1;if(zt){var Hn;if(zt){var Gn="oninput"in document;if(!Gn){var Vn=document.createElement("div");Vn.setAttribute("oninput","return;"),Gn="function"==typeof Vn.oninput}Hn=Gn}else Hn=!1;$n=Hn&&(!document.documentMode||9<document.documentMode)}function Wn(){Ln&&(Ln.detachEvent("onpropertychange",Un),Fn=Ln=null)}function Un(e){if("value"===e.propertyName&&jn(Fn)){var t=[];Nn(t,Fn,e,Ot(e)),Qt(Qn,t)}}function qn(e,t,n){"focusin"===e?(Wn(),Fn=n,(Ln=t).attachEvent("onpropertychange",Un)):"focusout"===e&&Wn()}function Yn(e){if("selectionchange"===e||"keyup"===e||"keydown"===e)return jn(Fn)}function Kn(e,t){if("click"===e)return jn(t)}function Jn(e,t){if("input"===e||"change"===e)return jn(t)}var Xn="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t};function Zn(e,t){if(Xn(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var o=n[r];if(!re.call(t,o)||!Xn(e[o],t[o]))return!1}return!0}function er(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function tr(e,t){var n,r=er(e);for(e=0;r;){if(3===r.nodeType){if(n=e+r.textContent.length,e<=t&&n>=t)return{node:r,offset:t-e};e=n}e:{for(;r;){if(r.nextSibling){r=r.nextSibling;break e}r=r.parentNode}r=void 0}r=er(r)}}function nr(e,t){return!(!e||!t)&&(e===t||(!e||3!==e.nodeType)&&(t&&3===t.nodeType?nr(e,t.parentNode):"contains"in e?e.contains(t):!!e.compareDocumentPosition&&!!(16&e.compareDocumentPosition(t))))}function rr(e){for(var t=gt((e=null!=e&&null!=e.ownerDocument&&null!=e.ownerDocument.defaultView?e.ownerDocument.defaultView:window).document);t instanceof e.HTMLIFrameElement;){try{var n="string"==typeof t.contentWindow.location.href}catch(e){n=!1}if(!n)break;t=gt((e=t.contentWindow).document)}return t}function or(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&("input"===t&&("text"===e.type||"search"===e.type||"tel"===e.type||"url"===e.type||"password"===e.type)||"textarea"===t||"true"===e.contentEditable)}var ir=zt&&"documentMode"in document&&11>=document.documentMode,ar=null,lr=null,sr=null,cr=!1;function ur(e,t,n){var r=n.window===n?n.document:9===n.nodeType?n:n.ownerDocument;cr||null==ar||ar!==gt(r)||(r="selectionStart"in(r=ar)&&or(r)?{start:r.selectionStart,end:r.selectionEnd}:{anchorNode:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection()).anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset},sr&&Zn(sr,r)||(sr=r,0<(r=rd(lr,"onSelect")).length&&(t=new nn("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=ar)))}function dr(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var fr={animationend:dr("Animation","AnimationEnd"),animationiteration:dr("Animation","AnimationIteration"),animationstart:dr("Animation","AnimationStart"),transitionrun:dr("Transition","TransitionRun"),transitionstart:dr("Transition","TransitionStart"),transitioncancel:dr("Transition","TransitionCancel"),transitionend:dr("Transition","TransitionEnd")},pr={},hr={};function gr(e){if(pr[e])return pr[e];if(!fr[e])return e;var t,n=fr[e];for(t in n)if(n.hasOwnProperty(t)&&t in hr)return pr[e]=n[t];return e}zt&&(hr=document.createElement("div").style,"AnimationEvent"in window||(delete fr.animationend.animation,delete fr.animationiteration.animation,delete fr.animationstart.animation),"TransitionEvent"in window||delete fr.transitionend.transition);var mr=gr("animationend"),Ar=gr("animationiteration"),br=gr("animationstart"),vr=gr("transitionrun"),yr=gr("transitionstart"),wr=gr("transitioncancel"),Cr=gr("transitionend"),Sr=new Map,xr="abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function Er(e,t){Sr.set(e,t),rt(t,[e])}xr.push("scrollEnd");var Ir="function"==typeof reportError?reportError:function(e){if("object"==typeof window&&"function"==typeof window.ErrorEvent){var t=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:"object"==typeof e&&null!==e&&"string"==typeof e.message?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if("object"==typeof process&&"function"==typeof process.emit)return void process.emit("uncaughtException",e);console.error(e)},kr=[],Rr=0,Mr=0;function Pr(){for(var e=Rr,t=Mr=Rr=0;t<e;){var n=kr[t];kr[t++]=null;var r=kr[t];kr[t++]=null;var o=kr[t];kr[t++]=null;var i=kr[t];if(kr[t++]=null,null!==r&&null!==o){var a=r.pending;null===a?o.next=o:(o.next=a.next,a.next=o),r.pending=o}0!==i&&Or(n,o,i)}}function Br(e,t,n,r){kr[Rr++]=e,kr[Rr++]=t,kr[Rr++]=n,kr[Rr++]=r,Mr|=r,e.lanes|=r,null!==(e=e.alternate)&&(e.lanes|=r)}function _r(e,t,n,r){return Br(e,t,n,r),Dr(e)}function Tr(e,t){return Br(e,null,null,t),Dr(e)}function Or(e,t,n){e.lanes|=n;var r=e.alternate;null!==r&&(r.lanes|=n);for(var o=!1,i=e.return;null!==i;)i.childLanes|=n,null!==(r=i.alternate)&&(r.childLanes|=n),22===i.tag&&(null===(e=i.stateNode)||1&e._visibility||(o=!0)),e=i,i=i.return;return 3===e.tag?(i=e.stateNode,o&&null!==t&&(o=31-ye(n),null===(r=(e=i.hiddenUpdates)[o])?e[o]=[t]:r.push(t),t.lane=536870912|n),i):null}function Dr(e){if(50<Gc)throw Gc=0,Vc=null,Error(a(185));for(var t=e.return;null!==t;)t=(e=t).return;return 3===e.tag?e.stateNode:null}var Nr={};function Lr(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Fr(e,t,n,r){return new Lr(e,t,n,r)}function Qr(e){return!(!(e=e.prototype)||!e.isReactComponent)}function jr(e,t){var n=e.alternate;return null===n?((n=Fr(e.tag,t,e.key,e.mode)).elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=65011712&e.flags,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=null===t?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n.refCleanup=e.refCleanup,n}function zr(e,t){e.flags&=65011714;var n=e.alternate;return null===n?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=n.childLanes,e.lanes=n.lanes,e.child=n.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=n.memoizedProps,e.memoizedState=n.memoizedState,e.updateQueue=n.updateQueue,e.type=n.type,t=n.dependencies,e.dependencies=null===t?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function $r(e,t,n,r,o,i){var l=0;if(r=e,"function"==typeof e)Qr(e)&&(l=1);else if("string"==typeof e)l=function(e,t,n){if(1===n||null!=t.itemProp)return!1;switch(e){case"meta":case"title":return!0;case"style":if("string"!=typeof t.precedence||"string"!=typeof t.href||""===t.href)break;return!0;case"link":if("string"!=typeof t.rel||"string"!=typeof t.href||""===t.href||t.onLoad||t.onError)break;return"stylesheet"!==t.rel||(e=t.disabled,"string"==typeof t.precedence&&null==e);case"script":if(t.async&&"function"!=typeof t.async&&"symbol"!=typeof t.async&&!t.onLoad&&!t.onError&&t.src&&"string"==typeof t.src)return!0}return!1}(e,n,G.current)?26:"html"===e||"head"===e||"body"===e?27:5;else e:switch(e){case k:return(e=Fr(31,n,t,o)).elementType=k,e.lanes=i,e;case A:return Hr(n.children,o,i,t);case b:l=8,o|=24;break;case v:return(e=Fr(12,n,t,2|o)).elementType=v,e.lanes=i,e;case S:return(e=Fr(13,n,t,o)).elementType=S,e.lanes=i,e;case x:return(e=Fr(19,n,t,o)).elementType=x,e.lanes=i,e;default:if("object"==typeof e&&null!==e)switch(e.$$typeof){case w:l=10;break e;case y:l=9;break e;case C:l=11;break e;case E:l=14;break e;case I:l=16,r=null;break e}l=29,n=Error(a(130,null===e?"null":typeof e,"")),r=null}return(t=Fr(l,n,t,o)).elementType=e,t.type=r,t.lanes=i,t}function Hr(e,t,n,r){return(e=Fr(7,e,r,t)).lanes=n,e}function Gr(e,t,n){return(e=Fr(6,e,null,t)).lanes=n,e}function Vr(e){var t=Fr(18,null,null,0);return t.stateNode=e,t}function Wr(e,t,n){return(t=Fr(4,null!==e.children?e.children:[],e.key,t)).lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var Ur=new WeakMap;function qr(e,t){if("object"==typeof e&&null!==e){var n=Ur.get(e);return void 0!==n?n:(t={value:e,source:t,stack:ne(t)},Ur.set(e,t),t)}return{value:e,source:t,stack:ne(t)}}var Yr=[],Kr=0,Jr=null,Xr=0,Zr=[],eo=0,to=null,no=1,ro="";function oo(e,t){Yr[Kr++]=Xr,Yr[Kr++]=Jr,Jr=e,Xr=t}function io(e,t,n){Zr[eo++]=no,Zr[eo++]=ro,Zr[eo++]=to,to=e;var r=no;e=ro;var o=32-ye(r)-1;r&=~(1<<o),n+=1;var i=32-ye(t)+o;if(30<i){var a=o-o%5;i=(r&(1<<a)-1).toString(32),r>>=a,o-=a,no=1<<32-ye(t)+o|n<<o|r,ro=i+e}else no=1<<i|n<<o|r,ro=e}function ao(e){null!==e.return&&(oo(e,1),io(e,1,0))}function lo(e){for(;e===Jr;)Jr=Yr[--Kr],Yr[Kr]=null,Xr=Yr[--Kr],Yr[Kr]=null;for(;e===to;)to=Zr[--eo],Zr[eo]=null,ro=Zr[--eo],Zr[eo]=null,no=Zr[--eo],Zr[eo]=null}function so(e,t){Zr[eo++]=no,Zr[eo++]=ro,Zr[eo++]=to,no=t.id,ro=t.overflow,to=e}var co=null,uo=null,fo=!1,po=null,ho=!1,go=Error(a(519));function mo(e){throw Co(qr(Error(a(418,1<arguments.length&&void 0!==arguments[1]&&arguments[1]?"text":"HTML","")),e)),go}function Ao(e){var t=e.stateNode,n=e.type,r=e.memoizedProps;switch(t[ze]=e,t[$e]=r,n){case"dialog":Ku("cancel",t),Ku("close",t);break;case"iframe":case"object":case"embed":Ku("load",t);break;case"video":case"audio":for(n=0;n<Uu.length;n++)Ku(Uu[n],t);break;case"source":Ku("error",t);break;case"img":case"image":case"link":Ku("error",t),Ku("load",t);break;case"details":Ku("toggle",t);break;case"input":Ku("invalid",t),vt(t,r.value,r.defaultValue,r.checked,r.defaultChecked,r.type,r.name,!0);break;case"select":Ku("invalid",t);break;case"textarea":Ku("invalid",t),St(t,r.value,r.defaultValue,r.children)}"string"!=typeof(n=r.children)&&"number"!=typeof n&&"bigint"!=typeof n||t.textContent===""+n||!0===r.suppressHydrationWarning||cd(t.textContent,n)?(null!=r.popover&&(Ku("beforetoggle",t),Ku("toggle",t)),null!=r.onScroll&&Ku("scroll",t),null!=r.onScrollEnd&&Ku("scrollend",t),null!=r.onClick&&(t.onclick=_t),t=!0):t=!1,t||mo(e,!0)}function bo(e){for(co=e.return;co;)switch(co.tag){case 5:case 31:case 13:return void(ho=!1);case 27:case 3:return void(ho=!0);default:co=co.return}}function vo(e){if(e!==co)return!1;if(!fo)return bo(e),fo=!0,!1;var t,n=e.tag;if((t=3!==n&&27!==n)&&((t=5===n)&&(t=!("form"!==(t=e.type)&&"button"!==t)||vd(e.type,e.memoizedProps)),t=!t),t&&uo&&mo(e),bo(e),13===n){if(!(e=null!==(e=e.memoizedState)?e.dehydrated:null))throw Error(a(317));uo=Dd(e)}else if(31===n){if(!(e=null!==(e=e.memoizedState)?e.dehydrated:null))throw Error(a(317));uo=Dd(e)}else 27===n?(n=uo,Id(e.type)?(e=Od,Od=null,uo=e):uo=n):uo=co?Td(e.stateNode.nextSibling):null;return!0}function yo(){uo=co=null,fo=!1}function wo(){var e=po;return null!==e&&(null===Pc?Pc=e:Pc.push.apply(Pc,e),po=null),e}function Co(e){null===po?po=[e]:po.push(e)}var So=Q(null),xo=null,Eo=null;function Io(e,t,n){z(So,t._currentValue),t._currentValue=n}function ko(e){e._currentValue=So.current,j(So)}function Ro(e,t,n){for(;null!==e;){var r=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,null!==r&&(r.childLanes|=t)):null!==r&&(r.childLanes&t)!==t&&(r.childLanes|=t),e===n)break;e=e.return}}function Mo(e,t,n,r){var o=e.child;for(null!==o&&(o.return=e);null!==o;){var i=o.dependencies;if(null!==i){var l=o.child;i=i.firstContext;e:for(;null!==i;){var s=i;i=o;for(var c=0;c<t.length;c++)if(s.context===t[c]){i.lanes|=n,null!==(s=i.alternate)&&(s.lanes|=n),Ro(i.return,n,e),r||(l=null);break e}i=s.next}}else if(18===o.tag){if(null===(l=o.return))throw Error(a(341));l.lanes|=n,null!==(i=l.alternate)&&(i.lanes|=n),Ro(l,n,e),l=null}else l=o.child;if(null!==l)l.return=o;else for(l=o;null!==l;){if(l===e){l=null;break}if(null!==(o=l.sibling)){o.return=l.return,l=o;break}l=l.return}o=l}}function Po(e,t,n,r){e=null;for(var o=t,i=!1;null!==o;){if(!i)if(524288&o.flags)i=!0;else if(262144&o.flags)break;if(10===o.tag){var l=o.alternate;if(null===l)throw Error(a(387));if(null!==(l=l.memoizedProps)){var s=o.type;Xn(o.pendingProps.value,l.value)||(null!==e?e.push(s):e=[s])}}else if(o===U.current){if(null===(l=o.alternate))throw Error(a(387));l.memoizedState.memoizedState!==o.memoizedState.memoizedState&&(null!==e?e.push(df):e=[df])}o=o.return}null!==e&&Mo(t,e,n,r),t.flags|=262144}function Bo(e){for(e=e.firstContext;null!==e;){if(!Xn(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function _o(e){xo=e,Eo=null,null!==(e=e.dependencies)&&(e.firstContext=null)}function To(e){return Do(xo,e)}function Oo(e,t){return null===xo&&_o(e),Do(e,t)}function Do(e,t){var n=t._currentValue;if(t={context:t,memoizedValue:n,next:null},null===Eo){if(null===e)throw Error(a(308));Eo=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else Eo=Eo.next=t;return n}var No="undefined"!=typeof AbortController?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(t,n){e.push(n)}};this.abort=function(){t.aborted=!0,e.forEach(function(e){return e()})}},Lo=r.unstable_scheduleCallback,Fo=r.unstable_NormalPriority,Qo={$$typeof:w,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function jo(){return{controller:new No,data:new Map,refCount:0}}function zo(e){e.refCount--,0===e.refCount&&Lo(Fo,function(){e.controller.abort()})}var $o=null,Ho=0,Go=0,Vo=null;function Wo(){if(0===--Ho&&null!==$o){null!==Vo&&(Vo.status="fulfilled");var e=$o;$o=null,Go=0,Vo=null;for(var t=0;t<e.length;t++)(0,e[t])()}}var Uo=O.S;O.S=function(e,t){Tc=se(),"object"==typeof t&&null!==t&&"function"==typeof t.then&&function(e,t){if(null===$o){var n=$o=[];Ho=0,Go=$u(),Vo={status:"pending",value:void 0,then:function(e){n.push(e)}}}Ho++,t.then(Wo,Wo)}(0,t),null!==Uo&&Uo(e,t)};var qo=Q(null);function Yo(){var e=qo.current;return null!==e?e:hc.pooledCache}function Ko(e,t){z(qo,null===t?qo.current:t.pool)}function Jo(){var e=Yo();return null===e?null:{parent:Qo._currentValue,pool:e}}var Xo=Error(a(460)),Zo=Error(a(474)),ei=Error(a(542)),ti={then:function(){}};function ni(e){return"fulfilled"===(e=e.status)||"rejected"===e}function ri(e,t,n){switch(void 0===(n=e[n])?e.push(t):n!==t&&(t.then(_t,_t),t=n),t.status){case"fulfilled":return t.value;case"rejected":throw li(e=t.reason),e;default:if("string"==typeof t.status)t.then(_t,_t);else{if(null!==(e=hc)&&100<e.shellSuspendCounter)throw Error(a(482));(e=t).status="pending",e.then(function(e){if("pending"===t.status){var n=t;n.status="fulfilled",n.value=e}},function(e){if("pending"===t.status){var n=t;n.status="rejected",n.reason=e}})}switch(t.status){case"fulfilled":return t.value;case"rejected":throw li(e=t.reason),e}throw ii=t,Xo}}function oi(e){try{return(0,e._init)(e._payload)}catch(e){if(null!==e&&"object"==typeof e&&"function"==typeof e.then)throw ii=e,Xo;throw e}}var ii=null;function ai(){if(null===ii)throw Error(a(459));var e=ii;return ii=null,e}function li(e){if(e===Xo||e===ei)throw Error(a(483))}var si=null,ci=0;function ui(e){var t=ci;return ci+=1,null===si&&(si=[]),ri(si,e,t)}function di(e,t){t=t.props.ref,e.ref=void 0!==t?t:null}function fi(e,t){if(t.$$typeof===h)throw Error(a(525));throw e=Object.prototype.toString.call(t),Error(a(31,"[object Object]"===e?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function pi(e){function t(t,n){if(e){var r=t.deletions;null===r?(t.deletions=[n],t.flags|=16):r.push(n)}}function n(n,r){if(!e)return null;for(;null!==r;)t(n,r),r=r.sibling;return null}function r(e){for(var t=new Map;null!==e;)null!==e.key?t.set(e.key,e):t.set(e.index,e),e=e.sibling;return t}function o(e,t){return(e=jr(e,t)).index=0,e.sibling=null,e}function i(t,n,r){return t.index=r,e?null!==(r=t.alternate)?(r=r.index)<n?(t.flags|=67108866,n):r:(t.flags|=67108866,n):(t.flags|=1048576,n)}function l(t){return e&&null===t.alternate&&(t.flags|=67108866),t}function s(e,t,n,r){return null===t||6!==t.tag?((t=Gr(n,e.mode,r)).return=e,t):((t=o(t,n)).return=e,t)}function c(e,t,n,r){var i=n.type;return i===A?d(e,t,n.props.children,r,n.key):null!==t&&(t.elementType===i||"object"==typeof i&&null!==i&&i.$$typeof===I&&oi(i)===t.type)?(di(t=o(t,n.props),n),t.return=e,t):(di(t=$r(n.type,n.key,n.props,null,e.mode,r),n),t.return=e,t)}function u(e,t,n,r){return null===t||4!==t.tag||t.stateNode.containerInfo!==n.containerInfo||t.stateNode.implementation!==n.implementation?((t=Wr(n,e.mode,r)).return=e,t):((t=o(t,n.children||[])).return=e,t)}function d(e,t,n,r,i){return null===t||7!==t.tag?((t=Hr(n,e.mode,r,i)).return=e,t):((t=o(t,n)).return=e,t)}function f(e,t,n){if("string"==typeof t&&""!==t||"number"==typeof t||"bigint"==typeof t)return(t=Gr(""+t,e.mode,n)).return=e,t;if("object"==typeof t&&null!==t){switch(t.$$typeof){case g:return di(n=$r(t.type,t.key,t.props,null,e.mode,n),t),n.return=e,n;case m:return(t=Wr(t,e.mode,n)).return=e,t;case I:return f(e,t=oi(t),n)}if(T(t)||P(t))return(t=Hr(t,e.mode,n,null)).return=e,t;if("function"==typeof t.then)return f(e,ui(t),n);if(t.$$typeof===w)return f(e,Oo(e,t),n);fi(e,t)}return null}function p(e,t,n,r){var o=null!==t?t.key:null;if("string"==typeof n&&""!==n||"number"==typeof n||"bigint"==typeof n)return null!==o?null:s(e,t,""+n,r);if("object"==typeof n&&null!==n){switch(n.$$typeof){case g:return n.key===o?c(e,t,n,r):null;case m:return n.key===o?u(e,t,n,r):null;case I:return p(e,t,n=oi(n),r)}if(T(n)||P(n))return null!==o?null:d(e,t,n,r,null);if("function"==typeof n.then)return p(e,t,ui(n),r);if(n.$$typeof===w)return p(e,t,Oo(e,n),r);fi(e,n)}return null}function h(e,t,n,r,o){if("string"==typeof r&&""!==r||"number"==typeof r||"bigint"==typeof r)return s(t,e=e.get(n)||null,""+r,o);if("object"==typeof r&&null!==r){switch(r.$$typeof){case g:return c(t,e=e.get(null===r.key?n:r.key)||null,r,o);case m:return u(t,e=e.get(null===r.key?n:r.key)||null,r,o);case I:return h(e,t,n,r=oi(r),o)}if(T(r)||P(r))return d(t,e=e.get(n)||null,r,o,null);if("function"==typeof r.then)return h(e,t,n,ui(r),o);if(r.$$typeof===w)return h(e,t,n,Oo(t,r),o);fi(t,r)}return null}function b(s,c,u,d){if("object"==typeof u&&null!==u&&u.type===A&&null===u.key&&(u=u.props.children),"object"==typeof u&&null!==u){switch(u.$$typeof){case g:e:{for(var v=u.key;null!==c;){if(c.key===v){if((v=u.type)===A){if(7===c.tag){n(s,c.sibling),(d=o(c,u.props.children)).return=s,s=d;break e}}else if(c.elementType===v||"object"==typeof v&&null!==v&&v.$$typeof===I&&oi(v)===c.type){n(s,c.sibling),di(d=o(c,u.props),u),d.return=s,s=d;break e}n(s,c);break}t(s,c),c=c.sibling}u.type===A?((d=Hr(u.props.children,s.mode,d,u.key)).return=s,s=d):(di(d=$r(u.type,u.key,u.props,null,s.mode,d),u),d.return=s,s=d)}return l(s);case m:e:{for(v=u.key;null!==c;){if(c.key===v){if(4===c.tag&&c.stateNode.containerInfo===u.containerInfo&&c.stateNode.implementation===u.implementation){n(s,c.sibling),(d=o(c,u.children||[])).return=s,s=d;break e}n(s,c);break}t(s,c),c=c.sibling}(d=Wr(u,s.mode,d)).return=s,s=d}return l(s);case I:return b(s,c,u=oi(u),d)}if(T(u))return function(o,a,l,s){for(var c=null,u=null,d=a,g=a=0,m=null;null!==d&&g<l.length;g++){d.index>g?(m=d,d=null):m=d.sibling;var A=p(o,d,l[g],s);if(null===A){null===d&&(d=m);break}e&&d&&null===A.alternate&&t(o,d),a=i(A,a,g),null===u?c=A:u.sibling=A,u=A,d=m}if(g===l.length)return n(o,d),fo&&oo(o,g),c;if(null===d){for(;g<l.length;g++)null!==(d=f(o,l[g],s))&&(a=i(d,a,g),null===u?c=d:u.sibling=d,u=d);return fo&&oo(o,g),c}for(d=r(d);g<l.length;g++)null!==(m=h(d,o,g,l[g],s))&&(e&&null!==m.alternate&&d.delete(null===m.key?g:m.key),a=i(m,a,g),null===u?c=m:u.sibling=m,u=m);return e&&d.forEach(function(e){return t(o,e)}),fo&&oo(o,g),c}(s,c,u,d);if(P(u)){if("function"!=typeof(v=P(u)))throw Error(a(150));return function(o,l,s,c){if(null==s)throw Error(a(151));for(var u=null,d=null,g=l,m=l=0,A=null,b=s.next();null!==g&&!b.done;m++,b=s.next()){g.index>m?(A=g,g=null):A=g.sibling;var v=p(o,g,b.value,c);if(null===v){null===g&&(g=A);break}e&&g&&null===v.alternate&&t(o,g),l=i(v,l,m),null===d?u=v:d.sibling=v,d=v,g=A}if(b.done)return n(o,g),fo&&oo(o,m),u;if(null===g){for(;!b.done;m++,b=s.next())null!==(b=f(o,b.value,c))&&(l=i(b,l,m),null===d?u=b:d.sibling=b,d=b);return fo&&oo(o,m),u}for(g=r(g);!b.done;m++,b=s.next())null!==(b=h(g,o,m,b.value,c))&&(e&&null!==b.alternate&&g.delete(null===b.key?m:b.key),l=i(b,l,m),null===d?u=b:d.sibling=b,d=b);return e&&g.forEach(function(e){return t(o,e)}),fo&&oo(o,m),u}(s,c,u=v.call(u),d)}if("function"==typeof u.then)return b(s,c,ui(u),d);if(u.$$typeof===w)return b(s,c,Oo(s,u),d);fi(s,u)}return"string"==typeof u&&""!==u||"number"==typeof u||"bigint"==typeof u?(u=""+u,null!==c&&6===c.tag?(n(s,c.sibling),(d=o(c,u)).return=s,s=d):(n(s,c),(d=Gr(u,s.mode,d)).return=s,s=d),l(s)):n(s,c)}return function(e,t,n,r){try{ci=0;var o=b(e,t,n,r);return si=null,o}catch(t){if(t===Xo||t===ei)throw t;var i=Fr(29,t,null,e.mode);return i.lanes=r,i.return=e,i}}}var hi=pi(!0),gi=pi(!1),mi=!1;function Ai(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function bi(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function vi(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function yi(e,t,n){var r=e.updateQueue;if(null===r)return null;if(r=r.shared,2&pc){var o=r.pending;return null===o?t.next=t:(t.next=o.next,o.next=t),r.pending=t,t=Dr(e),Or(e,null,n),t}return Br(e,r,t,n),Dr(e)}function wi(e,t,n){if(null!==(t=t.updateQueue)&&(t=t.shared,4194048&n)){var r=t.lanes;n|=r&=e.pendingLanes,t.lanes=n,Oe(e,n)}}function Ci(e,t){var n=e.updateQueue,r=e.alternate;if(null!==r&&n===(r=r.updateQueue)){var o=null,i=null;if(null!==(n=n.firstBaseUpdate)){do{var a={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};null===i?o=i=a:i=i.next=a,n=n.next}while(null!==n);null===i?o=i=t:i=i.next=t}else o=i=t;return n={baseState:r.baseState,firstBaseUpdate:o,lastBaseUpdate:i,shared:r.shared,callbacks:r.callbacks},void(e.updateQueue=n)}null===(e=n.lastBaseUpdate)?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}var Si=!1;function xi(){if(Si&&null!==Vo)throw Vo}function Ei(e,t,n,r){Si=!1;var o=e.updateQueue;mi=!1;var i=o.firstBaseUpdate,a=o.lastBaseUpdate,l=o.shared.pending;if(null!==l){o.shared.pending=null;var s=l,c=s.next;s.next=null,null===a?i=c:a.next=c,a=s;var u=e.alternate;null!==u&&(l=(u=u.updateQueue).lastBaseUpdate)!==a&&(null===l?u.firstBaseUpdate=c:l.next=c,u.lastBaseUpdate=s)}if(null!==i){var d=o.baseState;for(a=0,u=c=s=null,l=i;;){var f=-536870913&l.lane,h=f!==l.lane;if(h?(mc&f)===f:(r&f)===f){0!==f&&f===Go&&(Si=!0),null!==u&&(u=u.next={lane:0,tag:l.tag,payload:l.payload,callback:null,next:null});e:{var g=e,m=l;f=t;var A=n;switch(m.tag){case 1:if("function"==typeof(g=m.payload)){d=g.call(A,d,f);break e}d=g;break e;case 3:g.flags=-65537&g.flags|128;case 0:if(null==(f="function"==typeof(g=m.payload)?g.call(A,d,f):g))break e;d=p({},d,f);break e;case 2:mi=!0}}null!==(f=l.callback)&&(e.flags|=64,h&&(e.flags|=8192),null===(h=o.callbacks)?o.callbacks=[f]:h.push(f))}else h={lane:f,tag:l.tag,payload:l.payload,callback:l.callback,next:null},null===u?(c=u=h,s=d):u=u.next=h,a|=f;if(null===(l=l.next)){if(null===(l=o.shared.pending))break;l=(h=l).next,h.next=null,o.lastBaseUpdate=h,o.shared.pending=null}}null===u&&(s=d),o.baseState=s,o.firstBaseUpdate=c,o.lastBaseUpdate=u,null===i&&(o.shared.lanes=0),xc|=a,e.lanes=a,e.memoizedState=d}}function Ii(e,t){if("function"!=typeof e)throw Error(a(191,e));e.call(t)}function ki(e,t){var n=e.callbacks;if(null!==n)for(e.callbacks=null,e=0;e<n.length;e++)Ii(n[e],t)}var Ri=Q(null),Mi=Q(0);function Pi(e,t){z(Mi,e=Cc),z(Ri,t),Cc=e|t.baseLanes}function Bi(){z(Mi,Cc),z(Ri,Ri.current)}function _i(){Cc=Mi.current,j(Ri),j(Mi)}var Ti=Q(null),Oi=null;function Di(e){var t=e.alternate;z(ji,1&ji.current),z(Ti,e),null===Oi&&(null===t||null!==Ri.current||null!==t.memoizedState)&&(Oi=e)}function Ni(e){z(ji,ji.current),z(Ti,e),null===Oi&&(Oi=e)}function Li(e){22===e.tag?(z(ji,ji.current),z(Ti,e),null===Oi&&(Oi=e)):Fi()}function Fi(){z(ji,ji.current),z(Ti,Ti.current)}function Qi(e){j(Ti),Oi===e&&(Oi=null),j(ji)}var ji=Q(0);function zi(e){for(var t=e;null!==t;){if(13===t.tag){var n=t.memoizedState;if(null!==n&&(null===(n=n.dehydrated)||Bd(n)||_d(n)))return t}else if(19!==t.tag||"forwards"!==t.memoizedProps.revealOrder&&"backwards"!==t.memoizedProps.revealOrder&&"unstable_legacy-backwards"!==t.memoizedProps.revealOrder&&"together"!==t.memoizedProps.revealOrder){if(null!==t.child){t.child.return=t,t=t.child;continue}}else if(128&t.flags)return t;if(t===e)break;for(;null===t.sibling;){if(null===t.return||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var $i=0,Hi=null,Gi=null,Vi=null,Wi=!1,Ui=!1,qi=!1,Yi=0,Ki=0,Ji=null,Xi=0;function Zi(){throw Error(a(321))}function ea(e,t){if(null===t)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!Xn(e[n],t[n]))return!1;return!0}function ta(e,t,n,r,o,i){return $i=i,Hi=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,O.H=null===e||null===e.memoizedState?ml:Al,qi=!1,i=n(r,o),qi=!1,Ui&&(i=ra(t,n,r,o)),na(e),i}function na(e){O.H=gl;var t=null!==Gi&&null!==Gi.next;if($i=0,Vi=Gi=Hi=null,Wi=!1,Ki=0,Ji=null,t)throw Error(a(300));null===e||Tl||null!==(e=e.dependencies)&&Bo(e)&&(Tl=!0)}function ra(e,t,n,r){Hi=e;var o=0;do{if(Ui&&(Ji=null),Ki=0,Ui=!1,25<=o)throw Error(a(301));if(o+=1,Vi=Gi=null,null!=e.updateQueue){var i=e.updateQueue;i.lastEffect=null,i.events=null,i.stores=null,null!=i.memoCache&&(i.memoCache.index=0)}O.H=bl,i=t(n,r)}while(Ui);return i}function oa(){var e=O.H,t=e.useState()[0];return t="function"==typeof t.then?ua(t):t,e=e.useState()[0],(null!==Gi?Gi.memoizedState:null)!==e&&(Hi.flags|=1024),t}function ia(){var e=0!==Yi;return Yi=0,e}function aa(e,t,n){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~n}function la(e){if(Wi){for(e=e.memoizedState;null!==e;){var t=e.queue;null!==t&&(t.pending=null),e=e.next}Wi=!1}$i=0,Vi=Gi=Hi=null,Ui=!1,Ki=Yi=0,Ji=null}function sa(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return null===Vi?Hi.memoizedState=Vi=e:Vi=Vi.next=e,Vi}function ca(){if(null===Gi){var e=Hi.alternate;e=null!==e?e.memoizedState:null}else e=Gi.next;var t=null===Vi?Hi.memoizedState:Vi.next;if(null!==t)Vi=t,Gi=e;else{if(null===e){if(null===Hi.alternate)throw Error(a(467));throw Error(a(310))}e={memoizedState:(Gi=e).memoizedState,baseState:Gi.baseState,baseQueue:Gi.baseQueue,queue:Gi.queue,next:null},null===Vi?Hi.memoizedState=Vi=e:Vi=Vi.next=e}return Vi}function ua(e){var t=Ki;return Ki+=1,null===Ji&&(Ji=[]),e=ri(Ji,e,t),t=Hi,null===(null===Vi?t.memoizedState:Vi.next)&&(t=t.alternate,O.H=null===t||null===t.memoizedState?ml:Al),e}function da(e){if(null!==e&&"object"==typeof e){if("function"==typeof e.then)return ua(e);if(e.$$typeof===w)return To(e)}throw Error(a(438,String(e)))}function fa(e){var t=null,n=Hi.updateQueue;if(null!==n&&(t=n.memoCache),null==t){var r=Hi.alternate;null!==r&&null!==(r=r.updateQueue)&&null!=(r=r.memoCache)&&(t={data:r.data.map(function(e){return e.slice()}),index:0})}if(null==t&&(t={data:[],index:0}),null===n&&(n={lastEffect:null,events:null,stores:null,memoCache:null},Hi.updateQueue=n),n.memoCache=t,void 0===(n=t.data[t.index]))for(n=t.data[t.index]=Array(e),r=0;r<e;r++)n[r]=R;return t.index++,n}function pa(e,t){return"function"==typeof t?t(e):t}function ha(e){return ga(ca(),Gi,e)}function ga(e,t,n){var r=e.queue;if(null===r)throw Error(a(311));r.lastRenderedReducer=n;var o=e.baseQueue,i=r.pending;if(null!==i){if(null!==o){var l=o.next;o.next=i.next,i.next=l}t.baseQueue=o=i,r.pending=null}if(i=e.baseState,null===o)e.memoizedState=i;else{var s=l=null,c=null,u=t=o.next,d=!1;do{var f=-536870913&u.lane;if(f!==u.lane?(mc&f)===f:($i&f)===f){var p=u.revertLane;if(0===p)null!==c&&(c=c.next={lane:0,revertLane:0,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),f===Go&&(d=!0);else{if(($i&p)===p){u=u.next,p===Go&&(d=!0);continue}f={lane:0,revertLane:u.revertLane,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},null===c?(s=c=f,l=i):c=c.next=f,Hi.lanes|=p,xc|=p}f=u.action,qi&&n(i,f),i=u.hasEagerState?u.eagerState:n(i,f)}else p={lane:f,revertLane:u.revertLane,gesture:u.gesture,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},null===c?(s=c=p,l=i):c=c.next=p,Hi.lanes|=f,xc|=f;u=u.next}while(null!==u&&u!==t);if(null===c?l=i:c.next=s,!Xn(i,e.memoizedState)&&(Tl=!0,d&&null!==(n=Vo)))throw n;e.memoizedState=i,e.baseState=l,e.baseQueue=c,r.lastRenderedState=i}return null===o&&(r.lanes=0),[e.memoizedState,r.dispatch]}function ma(e){var t=ca(),n=t.queue;if(null===n)throw Error(a(311));n.lastRenderedReducer=e;var r=n.dispatch,o=n.pending,i=t.memoizedState;if(null!==o){n.pending=null;var l=o=o.next;do{i=e(i,l.action),l=l.next}while(l!==o);Xn(i,t.memoizedState)||(Tl=!0),t.memoizedState=i,null===t.baseQueue&&(t.baseState=i),n.lastRenderedState=i}return[i,r]}function Aa(e,t,n){var r=Hi,o=ca(),i=fo;if(i){if(void 0===n)throw Error(a(407));n=n()}else n=t();var l=!Xn((Gi||o).memoizedState,n);if(l&&(o.memoizedState=n,Tl=!0),o=o.queue,$a(ya.bind(null,r,o,e),[e]),o.getSnapshot!==t||l||null!==Vi&&1&Vi.memoizedState.tag){if(r.flags|=2048,La(9,{destroy:void 0},va.bind(null,r,o,n,t),null),null===hc)throw Error(a(349));i||127&$i||ba(r,t,n)}return n}function ba(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},null===(t=Hi.updateQueue)?(t={lastEffect:null,events:null,stores:null,memoCache:null},Hi.updateQueue=t,t.stores=[e]):null===(n=t.stores)?t.stores=[e]:n.push(e)}function va(e,t,n,r){t.value=n,t.getSnapshot=r,wa(t)&&Ca(e)}function ya(e,t,n){return n(function(){wa(t)&&Ca(e)})}function wa(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!Xn(e,n)}catch(e){return!0}}function Ca(e){var t=Tr(e,2);null!==t&&qc(t,0,2)}function Sa(e){var t=sa();if("function"==typeof e){var n=e;if(e=n(),qi){ve(!0);try{n()}finally{ve(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:pa,lastRenderedState:e},t}function xa(e,t,n,r){return e.baseState=n,ga(e,Gi,"function"==typeof r?r:pa)}function Ea(e,t,n,r,o){if(fl(e))throw Error(a(485));if(null!==(e=t.action)){var i={payload:o,action:e,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(e){i.listeners.push(e)}};null!==O.T?n(!0):i.isTransition=!1,r(i),null===(n=t.pending)?(i.next=t.pending=i,Ia(t,i)):(i.next=n.next,t.pending=n.next=i)}}function Ia(e,t){var n=t.action,r=t.payload,o=e.state;if(t.isTransition){var i=O.T,a={};O.T=a;try{var l=n(o,r),s=O.S;null!==s&&s(a,l),ka(e,t,l)}catch(n){Ma(e,t,n)}finally{null!==i&&null!==a.types&&(i.types=a.types),O.T=i}}else try{ka(e,t,i=n(o,r))}catch(n){Ma(e,t,n)}}function ka(e,t,n){null!==n&&"object"==typeof n&&"function"==typeof n.then?n.then(function(n){Ra(e,t,n)},function(n){return Ma(e,t,n)}):Ra(e,t,n)}function Ra(e,t,n){t.status="fulfilled",t.value=n,Pa(t),e.state=n,null!==(t=e.pending)&&((n=t.next)===t?e.pending=null:(n=n.next,t.next=n,Ia(e,n)))}function Ma(e,t,n){var r=e.pending;if(e.pending=null,null!==r){r=r.next;do{t.status="rejected",t.reason=n,Pa(t),t=t.next}while(t!==r)}e.action=null}function Pa(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function Ba(e,t){return t}function _a(e,t){if(fo){var n=hc.formState;if(null!==n){e:{var r=Hi;if(fo){if(uo){t:{for(var o=uo,i=ho;8!==o.nodeType;){if(!i){o=null;break t}if(null===(o=Td(o.nextSibling))){o=null;break t}}o="F!"===(i=o.data)||"F"===i?o:null}if(o){uo=Td(o.nextSibling),r="F!"===o.data;break e}}mo(r)}r=!1}r&&(t=n[0])}}return(n=sa()).memoizedState=n.baseState=t,r={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ba,lastRenderedState:t},n.queue=r,n=cl.bind(null,Hi,r),r.dispatch=n,r=Sa(!1),i=dl.bind(null,Hi,!1,r.queue),o={state:t,dispatch:null,action:e,pending:null},(r=sa()).queue=o,n=Ea.bind(null,Hi,o,i,n),o.dispatch=n,r.memoizedState=e,[t,n,!1]}function Ta(e){return Oa(ca(),Gi,e)}function Oa(e,t,n){if(t=ga(e,t,Ba)[0],e=ha(pa)[0],"object"==typeof t&&null!==t&&"function"==typeof t.then)try{var r=ua(t)}catch(e){if(e===Xo)throw ei;throw e}else r=t;var o=(t=ca()).queue,i=o.dispatch;return n!==t.memoizedState&&(Hi.flags|=2048,La(9,{destroy:void 0},Da.bind(null,o,n),null)),[r,i,e]}function Da(e,t){e.action=t}function Na(e){var t=ca(),n=Gi;if(null!==n)return Oa(t,n,e);ca(),t=t.memoizedState;var r=(n=ca()).queue.dispatch;return n.memoizedState=e,[t,r,!1]}function La(e,t,n,r){return e={tag:e,create:n,deps:r,inst:t,next:null},null===(t=Hi.updateQueue)&&(t={lastEffect:null,events:null,stores:null,memoCache:null},Hi.updateQueue=t),null===(n=t.lastEffect)?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e),e}function Fa(){return ca().memoizedState}function Qa(e,t,n,r){var o=sa();Hi.flags|=e,o.memoizedState=La(1|t,{destroy:void 0},n,void 0===r?null:r)}function ja(e,t,n,r){var o=ca();r=void 0===r?null:r;var i=o.memoizedState.inst;null!==Gi&&null!==r&&ea(r,Gi.memoizedState.deps)?o.memoizedState=La(t,i,n,r):(Hi.flags|=e,o.memoizedState=La(1|t,i,n,r))}function za(e,t){Qa(8390656,8,e,t)}function $a(e,t){ja(2048,8,e,t)}function Ha(e){var t=ca().memoizedState;return function(e){Hi.flags|=4;var t=Hi.updateQueue;if(null===t)t={lastEffect:null,events:null,stores:null,memoCache:null},Hi.updateQueue=t,t.events=[e];else{var n=t.events;null===n?t.events=[e]:n.push(e)}}({ref:t,nextImpl:e}),function(){if(2&pc)throw Error(a(440));return t.impl.apply(void 0,arguments)}}function Ga(e,t){return ja(4,2,e,t)}function Va(e,t){return ja(4,4,e,t)}function Wa(e,t){if("function"==typeof t){e=e();var n=t(e);return function(){"function"==typeof n?n():t(null)}}if(null!=t)return e=e(),t.current=e,function(){t.current=null}}function Ua(e,t,n){n=null!=n?n.concat([e]):null,ja(4,4,Wa.bind(null,t,e),n)}function qa(){}function Ya(e,t){var n=ca();t=void 0===t?null:t;var r=n.memoizedState;return null!==t&&ea(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function Ka(e,t){var n=ca();t=void 0===t?null:t;var r=n.memoizedState;if(null!==t&&ea(t,r[1]))return r[0];if(r=e(),qi){ve(!0);try{e()}finally{ve(!1)}}return n.memoizedState=[r,t],r}function Ja(e,t,n){return void 0===n||1073741824&$i&&!(261930&mc)?e.memoizedState=t:(e.memoizedState=n,e=Uc(),Hi.lanes|=e,xc|=e,n)}function Xa(e,t,n,r){return Xn(n,t)?n:null!==Ri.current?(e=Ja(e,n,r),Xn(e,t)||(Tl=!0),e):42&$i&&(!(1073741824&$i)||261930&mc)?(e=Uc(),Hi.lanes|=e,xc|=e,t):(Tl=!0,e.memoizedState=n)}function Za(e,t,n,r,o){var i=D.p;D.p=0!==i&&8>i?i:8;var a,l,s,c=O.T,u={};O.T=u,dl(e,!1,t,n);try{var d=o(),f=O.S;null!==f&&f(u,d),null!==d&&"object"==typeof d&&"function"==typeof d.then?ul(e,t,(a=r,l=[],s={status:"pending",value:null,reason:null,then:function(e){l.push(e)}},d.then(function(){s.status="fulfilled",s.value=a;for(var e=0;e<l.length;e++)(0,l[e])(a)},function(e){for(s.status="rejected",s.reason=e,e=0;e<l.length;e++)(0,l[e])(void 0)}),s),Wc()):ul(e,t,r,Wc())}catch(n){ul(e,t,{then:function(){},status:"rejected",reason:n},Wc())}finally{D.p=i,null!==c&&null!==u.types&&(c.types=u.types),O.T=c}}function el(){}function tl(e,t,n,r){if(5!==e.tag)throw Error(a(476));var o=nl(e).queue;Za(e,o,t,N,null===n?el:function(){return rl(e),n(r)})}function nl(e){var t=e.memoizedState;if(null!==t)return t;var n={};return(t={memoizedState:N,baseState:N,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:pa,lastRenderedState:N},next:null}).next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:pa,lastRenderedState:n},next:null},e.memoizedState=t,null!==(e=e.alternate)&&(e.memoizedState=t),t}function rl(e){var t=nl(e);null===t.next&&(t=e.alternate.memoizedState),ul(e,t.next.queue,{},Wc())}function ol(){return To(df)}function il(){return ca().memoizedState}function al(){return ca().memoizedState}function ll(e){for(var t=e.return;null!==t;){switch(t.tag){case 24:case 3:var n=Wc(),r=yi(t,e=vi(n),n);return null!==r&&(qc(r,0,n),wi(r,t,n)),t={cache:jo()},void(e.payload=t)}t=t.return}}function sl(e,t,n){var r=Wc();n={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},fl(e)?pl(t,n):null!==(n=_r(e,t,n,r))&&(qc(n,0,r),hl(n,t,r))}function cl(e,t,n){ul(e,t,n,Wc())}function ul(e,t,n,r){var o={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(fl(e))pl(t,o);else{var i=e.alternate;if(0===e.lanes&&(null===i||0===i.lanes)&&null!==(i=t.lastRenderedReducer))try{var a=t.lastRenderedState,l=i(a,n);if(o.hasEagerState=!0,o.eagerState=l,Xn(l,a))return Br(e,t,o,0),null===hc&&Pr(),!1}catch(e){}if(null!==(n=_r(e,t,o,r)))return qc(n,0,r),hl(n,t,r),!0}return!1}function dl(e,t,n,r){if(r={lane:2,revertLane:$u(),gesture:null,action:r,hasEagerState:!1,eagerState:null,next:null},fl(e)){if(t)throw Error(a(479))}else null!==(t=_r(e,n,r,2))&&qc(t,0,2)}function fl(e){var t=e.alternate;return e===Hi||null!==t&&t===Hi}function pl(e,t){Ui=Wi=!0;var n=e.pending;null===n?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function hl(e,t,n){if(4194048&n){var r=t.lanes;n|=r&=e.pendingLanes,t.lanes=n,Oe(e,n)}}var gl={readContext:To,use:da,useCallback:Zi,useContext:Zi,useEffect:Zi,useImperativeHandle:Zi,useLayoutEffect:Zi,useInsertionEffect:Zi,useMemo:Zi,useReducer:Zi,useRef:Zi,useState:Zi,useDebugValue:Zi,useDeferredValue:Zi,useTransition:Zi,useSyncExternalStore:Zi,useId:Zi,useHostTransitionStatus:Zi,useFormState:Zi,useActionState:Zi,useOptimistic:Zi,useMemoCache:Zi,useCacheRefresh:Zi};gl.useEffectEvent=Zi;var ml={readContext:To,use:da,useCallback:function(e,t){return sa().memoizedState=[e,void 0===t?null:t],e},useContext:To,useEffect:za,useImperativeHandle:function(e,t,n){n=null!=n?n.concat([e]):null,Qa(4194308,4,Wa.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Qa(4194308,4,e,t)},useInsertionEffect:function(e,t){Qa(4,2,e,t)},useMemo:function(e,t){var n=sa();t=void 0===t?null:t;var r=e();if(qi){ve(!0);try{e()}finally{ve(!1)}}return n.memoizedState=[r,t],r},useReducer:function(e,t,n){var r=sa();if(void 0!==n){var o=n(t);if(qi){ve(!0);try{n(t)}finally{ve(!1)}}}else o=t;return r.memoizedState=r.baseState=o,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:o},r.queue=e,e=e.dispatch=sl.bind(null,Hi,e),[r.memoizedState,e]},useRef:function(e){return e={current:e},sa().memoizedState=e},useState:function(e){var t=(e=Sa(e)).queue,n=cl.bind(null,Hi,t);return t.dispatch=n,[e.memoizedState,n]},useDebugValue:qa,useDeferredValue:function(e,t){return Ja(sa(),e,t)},useTransition:function(){var e=Sa(!1);return e=Za.bind(null,Hi,e.queue,!0,!1),sa().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,n){var r=Hi,o=sa();if(fo){if(void 0===n)throw Error(a(407));n=n()}else{if(n=t(),null===hc)throw Error(a(349));127&mc||ba(r,t,n)}o.memoizedState=n;var i={value:n,getSnapshot:t};return o.queue=i,za(ya.bind(null,r,i,e),[e]),r.flags|=2048,La(9,{destroy:void 0},va.bind(null,r,i,n,t),null),n},useId:function(){var e=sa(),t=hc.identifierPrefix;if(fo){var n=ro;t="_"+t+"R_"+(n=(no&~(1<<32-ye(no)-1)).toString(32)+n),0<(n=Yi++)&&(t+="H"+n.toString(32)),t+="_"}else t="_"+t+"r_"+(n=Xi++).toString(32)+"_";return e.memoizedState=t},useHostTransitionStatus:ol,useFormState:_a,useActionState:_a,useOptimistic:function(e){var t=sa();t.memoizedState=t.baseState=e;var n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=n,t=dl.bind(null,Hi,!0,n),n.dispatch=t,[e,t]},useMemoCache:fa,useCacheRefresh:function(){return sa().memoizedState=ll.bind(null,Hi)},useEffectEvent:function(e){var t=sa(),n={impl:e};return t.memoizedState=n,function(){if(2&pc)throw Error(a(440));return n.impl.apply(void 0,arguments)}}},Al={readContext:To,use:da,useCallback:Ya,useContext:To,useEffect:$a,useImperativeHandle:Ua,useInsertionEffect:Ga,useLayoutEffect:Va,useMemo:Ka,useReducer:ha,useRef:Fa,useState:function(){return ha(pa)},useDebugValue:qa,useDeferredValue:function(e,t){return Xa(ca(),Gi.memoizedState,e,t)},useTransition:function(){var e=ha(pa)[0],t=ca().memoizedState;return["boolean"==typeof e?e:ua(e),t]},useSyncExternalStore:Aa,useId:il,useHostTransitionStatus:ol,useFormState:Ta,useActionState:Ta,useOptimistic:function(e,t){return xa(ca(),0,e,t)},useMemoCache:fa,useCacheRefresh:al};Al.useEffectEvent=Ha;var bl={readContext:To,use:da,useCallback:Ya,useContext:To,useEffect:$a,useImperativeHandle:Ua,useInsertionEffect:Ga,useLayoutEffect:Va,useMemo:Ka,useReducer:ma,useRef:Fa,useState:function(){return ma(pa)},useDebugValue:qa,useDeferredValue:function(e,t){var n=ca();return null===Gi?Ja(n,e,t):Xa(n,Gi.memoizedState,e,t)},useTransition:function(){var e=ma(pa)[0],t=ca().memoizedState;return["boolean"==typeof e?e:ua(e),t]},useSyncExternalStore:Aa,useId:il,useHostTransitionStatus:ol,useFormState:Na,useActionState:Na,useOptimistic:function(e,t){var n=ca();return null!==Gi?xa(n,0,e,t):(n.baseState=e,[e,n.queue.dispatch])},useMemoCache:fa,useCacheRefresh:al};function vl(e,t,n,r){n=null==(n=n(r,t=e.memoizedState))?t:p({},t,n),e.memoizedState=n,0===e.lanes&&(e.updateQueue.baseState=n)}bl.useEffectEvent=Ha;var yl={enqueueSetState:function(e,t,n){e=e._reactInternals;var r=Wc(),o=vi(r);o.payload=t,null!=n&&(o.callback=n),null!==(t=yi(e,o,r))&&(qc(t,0,r),wi(t,e,r))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=Wc(),o=vi(r);o.tag=1,o.payload=t,null!=n&&(o.callback=n),null!==(t=yi(e,o,r))&&(qc(t,0,r),wi(t,e,r))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=Wc(),r=vi(n);r.tag=2,null!=t&&(r.callback=t),null!==(t=yi(e,r,n))&&(qc(t,0,n),wi(t,e,n))}};function wl(e,t,n,r,o,i,a){return"function"==typeof(e=e.stateNode).shouldComponentUpdate?e.shouldComponentUpdate(r,i,a):!(t.prototype&&t.prototype.isPureReactComponent&&Zn(n,r)&&Zn(o,i))}function Cl(e,t,n,r){e=t.state,"function"==typeof t.componentWillReceiveProps&&t.componentWillReceiveProps(n,r),"function"==typeof t.UNSAFE_componentWillReceiveProps&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&yl.enqueueReplaceState(t,t.state,null)}function Sl(e,t){var n=t;if("ref"in t)for(var r in n={},t)"ref"!==r&&(n[r]=t[r]);if(e=e.defaultProps)for(var o in n===t&&(n=p({},n)),e)void 0===n[o]&&(n[o]=e[o]);return n}function xl(e){Ir(e)}function El(e){console.error(e)}function Il(e){Ir(e)}function kl(e,t){try{(0,e.onUncaughtError)(t.value,{componentStack:t.stack})}catch(e){setTimeout(function(){throw e})}}function Rl(e,t,n){try{(0,e.onCaughtError)(n.value,{componentStack:n.stack,errorBoundary:1===t.tag?t.stateNode:null})}catch(e){setTimeout(function(){throw e})}}function Ml(e,t,n){return(n=vi(n)).tag=3,n.payload={element:null},n.callback=function(){kl(e,t)},n}function Pl(e){return(e=vi(e)).tag=3,e}function Bl(e,t,n,r){var o=n.type.getDerivedStateFromError;if("function"==typeof o){var i=r.value;e.payload=function(){return o(i)},e.callback=function(){Rl(t,n,r)}}var a=n.stateNode;null!==a&&"function"==typeof a.componentDidCatch&&(e.callback=function(){Rl(t,n,r),"function"!=typeof o&&(null===Nc?Nc=new Set([this]):Nc.add(this));var e=r.stack;this.componentDidCatch(r.value,{componentStack:null!==e?e:""})})}var _l=Error(a(461)),Tl=!1;function Ol(e,t,n,r){t.child=null===e?gi(t,null,n,r):hi(t,e.child,n,r)}function Dl(e,t,n,r,o){n=n.render;var i=t.ref;if("ref"in r){var a={};for(var l in r)"ref"!==l&&(a[l]=r[l])}else a=r;return _o(t),r=ta(e,t,n,a,i,o),l=ia(),null===e||Tl?(fo&&l&&ao(t),t.flags|=1,Ol(e,t,r,o),t.child):(aa(e,t,o),os(e,t,o))}function Nl(e,t,n,r,o){if(null===e){var i=n.type;return"function"!=typeof i||Qr(i)||void 0!==i.defaultProps||null!==n.compare?((e=$r(n.type,null,r,t,t.mode,o)).ref=t.ref,e.return=t,t.child=e):(t.tag=15,t.type=i,Ll(e,t,i,r,o))}if(i=e.child,!is(e,o)){var a=i.memoizedProps;if((n=null!==(n=n.compare)?n:Zn)(a,r)&&e.ref===t.ref)return os(e,t,o)}return t.flags|=1,(e=jr(i,r)).ref=t.ref,e.return=t,t.child=e}function Ll(e,t,n,r,o){if(null!==e){var i=e.memoizedProps;if(Zn(i,r)&&e.ref===t.ref){if(Tl=!1,t.pendingProps=r=i,!is(e,o))return t.lanes=e.lanes,os(e,t,o);131072&e.flags&&(Tl=!0)}}return Gl(e,t,n,r,o)}function Fl(e,t,n,r){var o=r.children,i=null!==e?e.memoizedState:null;if(null===e&&null===t.stateNode&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),"hidden"===r.mode){if(128&t.flags){if(i=null!==i?i.baseLanes|n:n,null!==e){for(r=t.child=e.child,o=0;null!==r;)o=o|r.lanes|r.childLanes,r=r.sibling;r=o&~i}else r=0,t.child=null;return jl(e,t,i,n,r)}if(!(536870912&n))return r=t.lanes=536870912,jl(e,t,null!==i?i.baseLanes|n:n,n,r);t.memoizedState={baseLanes:0,cachePool:null},null!==e&&Ko(0,null!==i?i.cachePool:null),null!==i?Pi(t,i):Bi(),Li(t)}else null!==i?(Ko(0,i.cachePool),Pi(t,i),Fi(),t.memoizedState=null):(null!==e&&Ko(0,null),Bi(),Fi());return Ol(e,t,o,n),t.child}function Ql(e,t){return null!==e&&22===e.tag||null!==t.stateNode||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function jl(e,t,n,r,o){var i=Yo();return i=null===i?null:{parent:Qo._currentValue,pool:i},t.memoizedState={baseLanes:n,cachePool:i},null!==e&&Ko(0,null),Bi(),Li(t),null!==e&&Po(e,t,r,!0),t.childLanes=o,null}function zl(e,t){return(t=Zl({mode:t.mode,children:t.children},e.mode)).ref=e.ref,e.child=t,t.return=e,t}function $l(e,t,n){return hi(t,e.child,null,n),(e=zl(t,t.pendingProps)).flags|=2,Qi(t),t.memoizedState=null,e}function Hl(e,t){var n=t.ref;if(null===n)null!==e&&null!==e.ref&&(t.flags|=4194816);else{if("function"!=typeof n&&"object"!=typeof n)throw Error(a(284));null!==e&&e.ref===n||(t.flags|=4194816)}}function Gl(e,t,n,r,o){return _o(t),n=ta(e,t,n,r,void 0,o),r=ia(),null===e||Tl?(fo&&r&&ao(t),t.flags|=1,Ol(e,t,n,o),t.child):(aa(e,t,o),os(e,t,o))}function Vl(e,t,n,r,o,i){return _o(t),t.updateQueue=null,n=ra(t,r,n,o),na(e),r=ia(),null===e||Tl?(fo&&r&&ao(t),t.flags|=1,Ol(e,t,n,i),t.child):(aa(e,t,i),os(e,t,i))}function Wl(e,t,n,r,o){if(_o(t),null===t.stateNode){var i=Nr,a=n.contextType;"object"==typeof a&&null!==a&&(i=To(a)),i=new n(r,i),t.memoizedState=null!==i.state&&void 0!==i.state?i.state:null,i.updater=yl,t.stateNode=i,i._reactInternals=t,(i=t.stateNode).props=r,i.state=t.memoizedState,i.refs={},Ai(t),a=n.contextType,i.context="object"==typeof a&&null!==a?To(a):Nr,i.state=t.memoizedState,"function"==typeof(a=n.getDerivedStateFromProps)&&(vl(t,n,a,r),i.state=t.memoizedState),"function"==typeof n.getDerivedStateFromProps||"function"==typeof i.getSnapshotBeforeUpdate||"function"!=typeof i.UNSAFE_componentWillMount&&"function"!=typeof i.componentWillMount||(a=i.state,"function"==typeof i.componentWillMount&&i.componentWillMount(),"function"==typeof i.UNSAFE_componentWillMount&&i.UNSAFE_componentWillMount(),a!==i.state&&yl.enqueueReplaceState(i,i.state,null),Ei(t,r,i,o),xi(),i.state=t.memoizedState),"function"==typeof i.componentDidMount&&(t.flags|=4194308),r=!0}else if(null===e){i=t.stateNode;var l=t.memoizedProps,s=Sl(n,l);i.props=s;var c=i.context,u=n.contextType;a=Nr,"object"==typeof u&&null!==u&&(a=To(u));var d=n.getDerivedStateFromProps;u="function"==typeof d||"function"==typeof i.getSnapshotBeforeUpdate,l=t.pendingProps!==l,u||"function"!=typeof i.UNSAFE_componentWillReceiveProps&&"function"!=typeof i.componentWillReceiveProps||(l||c!==a)&&Cl(t,i,r,a),mi=!1;var f=t.memoizedState;i.state=f,Ei(t,r,i,o),xi(),c=t.memoizedState,l||f!==c||mi?("function"==typeof d&&(vl(t,n,d,r),c=t.memoizedState),(s=mi||wl(t,n,s,r,f,c,a))?(u||"function"!=typeof i.UNSAFE_componentWillMount&&"function"!=typeof i.componentWillMount||("function"==typeof i.componentWillMount&&i.componentWillMount(),"function"==typeof i.UNSAFE_componentWillMount&&i.UNSAFE_componentWillMount()),"function"==typeof i.componentDidMount&&(t.flags|=4194308)):("function"==typeof i.componentDidMount&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=c),i.props=r,i.state=c,i.context=a,r=s):("function"==typeof i.componentDidMount&&(t.flags|=4194308),r=!1)}else{i=t.stateNode,bi(e,t),u=Sl(n,a=t.memoizedProps),i.props=u,d=t.pendingProps,f=i.context,c=n.contextType,s=Nr,"object"==typeof c&&null!==c&&(s=To(c)),(c="function"==typeof(l=n.getDerivedStateFromProps)||"function"==typeof i.getSnapshotBeforeUpdate)||"function"!=typeof i.UNSAFE_componentWillReceiveProps&&"function"!=typeof i.componentWillReceiveProps||(a!==d||f!==s)&&Cl(t,i,r,s),mi=!1,f=t.memoizedState,i.state=f,Ei(t,r,i,o),xi();var p=t.memoizedState;a!==d||f!==p||mi||null!==e&&null!==e.dependencies&&Bo(e.dependencies)?("function"==typeof l&&(vl(t,n,l,r),p=t.memoizedState),(u=mi||wl(t,n,u,r,f,p,s)||null!==e&&null!==e.dependencies&&Bo(e.dependencies))?(c||"function"!=typeof i.UNSAFE_componentWillUpdate&&"function"!=typeof i.componentWillUpdate||("function"==typeof i.componentWillUpdate&&i.componentWillUpdate(r,p,s),"function"==typeof i.UNSAFE_componentWillUpdate&&i.UNSAFE_componentWillUpdate(r,p,s)),"function"==typeof i.componentDidUpdate&&(t.flags|=4),"function"==typeof i.getSnapshotBeforeUpdate&&(t.flags|=1024)):("function"!=typeof i.componentDidUpdate||a===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),"function"!=typeof i.getSnapshotBeforeUpdate||a===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=p),i.props=r,i.state=p,i.context=s,r=u):("function"!=typeof i.componentDidUpdate||a===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),"function"!=typeof i.getSnapshotBeforeUpdate||a===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),r=!1)}return i=r,Hl(e,t),r=!!(128&t.flags),i||r?(i=t.stateNode,n=r&&"function"!=typeof n.getDerivedStateFromError?null:i.render(),t.flags|=1,null!==e&&r?(t.child=hi(t,e.child,null,o),t.child=hi(t,null,n,o)):Ol(e,t,n,o),t.memoizedState=i.state,e=t.child):e=os(e,t,o),e}function Ul(e,t,n,r){return yo(),t.flags|=256,Ol(e,t,n,r),t.child}var ql={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function Yl(e){return{baseLanes:e,cachePool:Jo()}}function Kl(e,t,n){return e=null!==e?e.childLanes&~n:0,t&&(e|=kc),e}function Jl(e,t,n){var r,o=t.pendingProps,i=!1,l=!!(128&t.flags);if((r=l)||(r=(null===e||null!==e.memoizedState)&&!!(2&ji.current)),r&&(i=!0,t.flags&=-129),r=!!(32&t.flags),t.flags&=-33,null===e){if(fo){if(i?Di(t):Fi(),(e=uo)?null!==(e=null!==(e=Pd(e,ho))&&"&"!==e.data?e:null)&&(t.memoizedState={dehydrated:e,treeContext:null!==to?{id:no,overflow:ro}:null,retryLane:536870912,hydrationErrors:null},(n=Vr(e)).return=t,t.child=n,co=t,uo=null):e=null,null===e)throw mo(t);return _d(e)?t.lanes=32:t.lanes=536870912,null}var s=o.children;return o=o.fallback,i?(Fi(),s=Zl({mode:"hidden",children:s},i=t.mode),o=Hr(o,i,n,null),s.return=t,o.return=t,s.sibling=o,t.child=s,(o=t.child).memoizedState=Yl(n),o.childLanes=Kl(e,r,n),t.memoizedState=ql,Ql(null,o)):(Di(t),Xl(t,s))}var c=e.memoizedState;if(null!==c&&null!==(s=c.dehydrated)){if(l)256&t.flags?(Di(t),t.flags&=-257,t=es(e,t,n)):null!==t.memoizedState?(Fi(),t.child=e.child,t.flags|=128,t=null):(Fi(),s=o.fallback,i=t.mode,o=Zl({mode:"visible",children:o.children},i),(s=Hr(s,i,n,null)).flags|=2,o.return=t,s.return=t,o.sibling=s,t.child=o,hi(t,e.child,null,n),(o=t.child).memoizedState=Yl(n),o.childLanes=Kl(e,r,n),t.memoizedState=ql,t=Ql(null,o));else if(Di(t),_d(s)){if(r=s.nextSibling&&s.nextSibling.dataset)var u=r.dgst;r=u,(o=Error(a(419))).stack="",o.digest=r,Co({value:o,source:null,stack:null}),t=es(e,t,n)}else if(Tl||Po(e,t,n,!1),r=0!==(n&e.childLanes),Tl||r){if(null!==(r=hc)&&0!==(o=De(r,n))&&o!==c.retryLane)throw c.retryLane=o,Tr(e,o),qc(r,0,o),_l;Bd(s)||au(),t=es(e,t,n)}else Bd(s)?(t.flags|=192,t.child=e.child,t=null):(e=c.treeContext,uo=Td(s.nextSibling),co=t,fo=!0,po=null,ho=!1,null!==e&&so(t,e),(t=Xl(t,o.children)).flags|=4096);return t}return i?(Fi(),s=o.fallback,i=t.mode,u=(c=e.child).sibling,(o=jr(c,{mode:"hidden",children:o.children})).subtreeFlags=65011712&c.subtreeFlags,null!==u?s=jr(u,s):(s=Hr(s,i,n,null)).flags|=2,s.return=t,o.return=t,o.sibling=s,t.child=o,Ql(null,o),o=t.child,null===(s=e.child.memoizedState)?s=Yl(n):(null!==(i=s.cachePool)?(c=Qo._currentValue,i=i.parent!==c?{parent:c,pool:c}:i):i=Jo(),s={baseLanes:s.baseLanes|n,cachePool:i}),o.memoizedState=s,o.childLanes=Kl(e,r,n),t.memoizedState=ql,Ql(e.child,o)):(Di(t),e=(n=e.child).sibling,(n=jr(n,{mode:"visible",children:o.children})).return=t,n.sibling=null,null!==e&&(null===(r=t.deletions)?(t.deletions=[e],t.flags|=16):r.push(e)),t.child=n,t.memoizedState=null,n)}function Xl(e,t){return(t=Zl({mode:"visible",children:t},e.mode)).return=e,e.child=t}function Zl(e,t){return(e=Fr(22,e,null,t)).lanes=0,e}function es(e,t,n){return hi(t,e.child,null,n),(e=Xl(t,t.pendingProps.children)).flags|=2,t.memoizedState=null,e}function ts(e,t,n){e.lanes|=t;var r=e.alternate;null!==r&&(r.lanes|=t),Ro(e.return,t,n)}function ns(e,t,n,r,o,i){var a=e.memoizedState;null===a?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:o,treeForkCount:i}:(a.isBackwards=t,a.rendering=null,a.renderingStartTime=0,a.last=r,a.tail=n,a.tailMode=o,a.treeForkCount=i)}function rs(e,t,n){var r=t.pendingProps,o=r.revealOrder,i=r.tail;r=r.children;var a=ji.current,l=!!(2&a);if(l?(a=1&a|2,t.flags|=128):a&=1,z(ji,a),Ol(e,t,r,n),r=fo?Xr:0,!l&&null!==e&&128&e.flags)e:for(e=t.child;null!==e;){if(13===e.tag)null!==e.memoizedState&&ts(e,n,t);else if(19===e.tag)ts(e,n,t);else if(null!==e.child){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;null===e.sibling;){if(null===e.return||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(o){case"forwards":for(n=t.child,o=null;null!==n;)null!==(e=n.alternate)&&null===zi(e)&&(o=n),n=n.sibling;null===(n=o)?(o=t.child,t.child=null):(o=n.sibling,n.sibling=null),ns(t,!1,o,n,i,r);break;case"backwards":case"unstable_legacy-backwards":for(n=null,o=t.child,t.child=null;null!==o;){if(null!==(e=o.alternate)&&null===zi(e)){t.child=o;break}e=o.sibling,o.sibling=n,n=o,o=e}ns(t,!0,n,null,i,r);break;case"together":ns(t,!1,null,null,void 0,r);break;default:t.memoizedState=null}return t.child}function os(e,t,n){if(null!==e&&(t.dependencies=e.dependencies),xc|=t.lanes,0===(n&t.childLanes)){if(null===e)return null;if(Po(e,t,n,!1),0===(n&t.childLanes))return null}if(null!==e&&t.child!==e.child)throw Error(a(153));if(null!==t.child){for(n=jr(e=t.child,e.pendingProps),t.child=n,n.return=t;null!==e.sibling;)e=e.sibling,(n=n.sibling=jr(e,e.pendingProps)).return=t;n.sibling=null}return t.child}function is(e,t){return 0!==(e.lanes&t)||!(null===(e=e.dependencies)||!Bo(e))}function as(e,t,n){if(null!==e)if(e.memoizedProps!==t.pendingProps)Tl=!0;else{if(!(is(e,n)||128&t.flags))return Tl=!1,function(e,t,n){switch(t.tag){case 3:q(t,t.stateNode.containerInfo),Io(0,Qo,e.memoizedState.cache),yo();break;case 27:case 5:K(t);break;case 4:q(t,t.stateNode.containerInfo);break;case 10:Io(0,t.type,t.memoizedProps.value);break;case 31:if(null!==t.memoizedState)return t.flags|=128,Ni(t),null;break;case 13:var r=t.memoizedState;if(null!==r)return null!==r.dehydrated?(Di(t),t.flags|=128,null):0!==(n&t.child.childLanes)?Jl(e,t,n):(Di(t),null!==(e=os(e,t,n))?e.sibling:null);Di(t);break;case 19:var o=!!(128&e.flags);if((r=0!==(n&t.childLanes))||(Po(e,t,n,!1),r=0!==(n&t.childLanes)),o){if(r)return rs(e,t,n);t.flags|=128}if(null!==(o=t.memoizedState)&&(o.rendering=null,o.tail=null,o.lastEffect=null),z(ji,ji.current),r)break;return null;case 22:return t.lanes=0,Fl(e,t,n,t.pendingProps);case 24:Io(0,Qo,e.memoizedState.cache)}return os(e,t,n)}(e,t,n);Tl=!!(131072&e.flags)}else Tl=!1,fo&&1048576&t.flags&&io(t,Xr,t.index);switch(t.lanes=0,t.tag){case 16:e:{var r=t.pendingProps;if(e=oi(t.elementType),t.type=e,"function"!=typeof e){if(null!=e){var o=e.$$typeof;if(o===C){t.tag=11,t=Dl(null,t,e,r,n);break e}if(o===E){t.tag=14,t=Nl(null,t,e,r,n);break e}}throw t=_(e)||e,Error(a(306,t,""))}Qr(e)?(r=Sl(e,r),t.tag=1,t=Wl(null,t,e,r,n)):(t.tag=0,t=Gl(null,t,e,r,n))}return t;case 0:return Gl(e,t,t.type,t.pendingProps,n);case 1:return Wl(e,t,r=t.type,o=Sl(r,t.pendingProps),n);case 3:e:{if(q(t,t.stateNode.containerInfo),null===e)throw Error(a(387));r=t.pendingProps;var i=t.memoizedState;o=i.element,bi(e,t),Ei(t,r,null,n);var l=t.memoizedState;if(r=l.cache,Io(0,Qo,r),r!==i.cache&&Mo(t,[Qo],n,!0),xi(),r=l.element,i.isDehydrated){if(i={element:r,isDehydrated:!1,cache:l.cache},t.updateQueue.baseState=i,t.memoizedState=i,256&t.flags){t=Ul(e,t,r,n);break e}if(r!==o){Co(o=qr(Error(a(424)),t)),t=Ul(e,t,r,n);break e}for(e=9===(e=t.stateNode.containerInfo).nodeType?e.body:"HTML"===e.nodeName?e.ownerDocument.body:e,uo=Td(e.firstChild),co=t,fo=!0,po=null,ho=!0,n=gi(t,null,r,n),t.child=n;n;)n.flags=-3&n.flags|4096,n=n.sibling}else{if(yo(),r===o){t=os(e,t,n);break e}Ol(e,t,r,n)}t=t.child}return t;case 26:return Hl(e,t),null===e?(n=Vd(t.type,null,t.pendingProps,null))?t.memoizedState=n:fo||(n=t.type,e=t.pendingProps,(r=md(W.current).createElement(n))[ze]=t,r[$e]=e,fd(r,n,e),et(r),t.stateNode=r):t.memoizedState=Vd(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return K(t),null===e&&fo&&(r=t.stateNode=Ld(t.type,t.pendingProps,W.current),co=t,ho=!0,o=uo,Id(t.type)?(Od=o,uo=Td(r.firstChild)):uo=o),Ol(e,t,t.pendingProps.children,n),Hl(e,t),null===e&&(t.flags|=4194304),t.child;case 5:return null===e&&fo&&((o=r=uo)&&(null!==(r=function(e,t,n,r){for(;1===e.nodeType;){var o=n;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!r&&("INPUT"!==e.nodeName||"hidden"!==e.type))break}else if(r){if(!e[qe])switch(t){case"meta":if(!e.hasAttribute("itemprop"))break;return e;case"link":if("stylesheet"===(i=e.getAttribute("rel"))&&e.hasAttribute("data-precedence"))break;if(i!==o.rel||e.getAttribute("href")!==(null==o.href||""===o.href?null:o.href)||e.getAttribute("crossorigin")!==(null==o.crossOrigin?null:o.crossOrigin)||e.getAttribute("title")!==(null==o.title?null:o.title))break;return e;case"style":if(e.hasAttribute("data-precedence"))break;return e;case"script":if(((i=e.getAttribute("src"))!==(null==o.src?null:o.src)||e.getAttribute("type")!==(null==o.type?null:o.type)||e.getAttribute("crossorigin")!==(null==o.crossOrigin?null:o.crossOrigin))&&i&&e.hasAttribute("async")&&!e.hasAttribute("itemprop"))break;return e;default:return e}}else{if("input"!==t||"hidden"!==e.type)return e;var i=null==o.name?null:""+o.name;if("hidden"===o.type&&e.getAttribute("name")===i)return e}if(null===(e=Td(e.nextSibling)))break}return null}(r,t.type,t.pendingProps,ho))?(t.stateNode=r,co=t,uo=Td(r.firstChild),ho=!1,o=!0):o=!1),o||mo(t)),K(t),o=t.type,i=t.pendingProps,l=null!==e?e.memoizedProps:null,r=i.children,vd(o,i)?r=null:null!==l&&vd(o,l)&&(t.flags|=32),null!==t.memoizedState&&(o=ta(e,t,oa,null,null,n),df._currentValue=o),Hl(e,t),Ol(e,t,r,n),t.child;case 6:return null===e&&fo&&((e=n=uo)&&(null!==(n=function(e,t,n){if(""===t)return null;for(;3!==e.nodeType;){if((1!==e.nodeType||"INPUT"!==e.nodeName||"hidden"!==e.type)&&!n)return null;if(null===(e=Td(e.nextSibling)))return null}return e}(n,t.pendingProps,ho))?(t.stateNode=n,co=t,uo=null,e=!0):e=!1),e||mo(t)),null;case 13:return Jl(e,t,n);case 4:return q(t,t.stateNode.containerInfo),r=t.pendingProps,null===e?t.child=hi(t,null,r,n):Ol(e,t,r,n),t.child;case 11:return Dl(e,t,t.type,t.pendingProps,n);case 7:return Ol(e,t,t.pendingProps,n),t.child;case 8:case 12:return Ol(e,t,t.pendingProps.children,n),t.child;case 10:return r=t.pendingProps,Io(0,t.type,r.value),Ol(e,t,r.children,n),t.child;case 9:return o=t.type._context,r=t.pendingProps.children,_o(t),r=r(o=To(o)),t.flags|=1,Ol(e,t,r,n),t.child;case 14:return Nl(e,t,t.type,t.pendingProps,n);case 15:return Ll(e,t,t.type,t.pendingProps,n);case 19:return rs(e,t,n);case 31:return function(e,t,n){var r=t.pendingProps,o=!!(128&t.flags);if(t.flags&=-129,null===e){if(fo){if("hidden"===r.mode)return e=zl(t,r),t.lanes=536870912,Ql(null,e);if(Ni(t),(e=uo)?null!==(e=null!==(e=Pd(e,ho))&&"&"===e.data?e:null)&&(t.memoizedState={dehydrated:e,treeContext:null!==to?{id:no,overflow:ro}:null,retryLane:536870912,hydrationErrors:null},(n=Vr(e)).return=t,t.child=n,co=t,uo=null):e=null,null===e)throw mo(t);return t.lanes=536870912,null}return zl(t,r)}var i=e.memoizedState;if(null!==i){var l=i.dehydrated;if(Ni(t),o)if(256&t.flags)t.flags&=-257,t=$l(e,t,n);else{if(null===t.memoizedState)throw Error(a(558));t.child=e.child,t.flags|=128,t=null}else if(Tl||Po(e,t,n,!1),o=0!==(n&e.childLanes),Tl||o){if(null!==(r=hc)&&0!==(l=De(r,n))&&l!==i.retryLane)throw i.retryLane=l,Tr(e,l),qc(r,0,l),_l;au(),t=$l(e,t,n)}else e=i.treeContext,uo=Td(l.nextSibling),co=t,fo=!0,po=null,ho=!1,null!==e&&so(t,e),(t=zl(t,r)).flags|=4096;return t}return(e=jr(e.child,{mode:r.mode,children:r.children})).ref=t.ref,t.child=e,e.return=t,e}(e,t,n);case 22:return Fl(e,t,n,t.pendingProps);case 24:return _o(t),r=To(Qo),null===e?(null===(o=Yo())&&(o=hc,i=jo(),o.pooledCache=i,i.refCount++,null!==i&&(o.pooledCacheLanes|=n),o=i),t.memoizedState={parent:r,cache:o},Ai(t),Io(0,Qo,o)):(0!==(e.lanes&n)&&(bi(e,t),Ei(t,null,null,n),xi()),o=e.memoizedState,i=t.memoizedState,o.parent!==r?(o={parent:r,cache:r},t.memoizedState=o,0===t.lanes&&(t.memoizedState=t.updateQueue.baseState=o),Io(0,Qo,r)):(r=i.cache,Io(0,Qo,r),r!==o.cache&&Mo(t,[Qo],n,!0))),Ol(e,t,t.pendingProps.children,n),t.child;case 29:throw t.pendingProps}throw Error(a(156,t.tag))}function ls(e){e.flags|=4}function ss(e,t,n,r,o){if((t=!!(32&e.mode))&&(t=!1),t){if(e.flags|=16777216,(335544128&o)===o)if(e.stateNode.complete)e.flags|=8192;else{if(!ru())throw ii=ti,Zo;e.flags|=8192}}else e.flags&=-16777217}function cs(e,t){if("stylesheet"!==t.type||4&t.state.loading)e.flags&=-16777217;else if(e.flags|=16777216,!of(t)){if(!ru())throw ii=ti,Zo;e.flags|=8192}}function us(e,t){null!==t&&(e.flags|=4),16384&e.flags&&(t=22!==e.tag?Pe():536870912,e.lanes|=t,Rc|=t)}function ds(e,t){if(!fo)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;null!==t;)null!==t.alternate&&(n=t),t=t.sibling;null===n?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var r=null;null!==n;)null!==n.alternate&&(r=n),n=n.sibling;null===r?t||null===e.tail?e.tail=null:e.tail.sibling=null:r.sibling=null}}function fs(e){var t=null!==e.alternate&&e.alternate.child===e.child,n=0,r=0;if(t)for(var o=e.child;null!==o;)n|=o.lanes|o.childLanes,r|=65011712&o.subtreeFlags,r|=65011712&o.flags,o.return=e,o=o.sibling;else for(o=e.child;null!==o;)n|=o.lanes|o.childLanes,r|=o.subtreeFlags,r|=o.flags,o.return=e,o=o.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function ps(e,t,n){var r=t.pendingProps;switch(lo(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:case 1:return fs(t),null;case 3:return n=t.stateNode,r=null,null!==e&&(r=e.memoizedState.cache),t.memoizedState.cache!==r&&(t.flags|=2048),ko(Qo),Y(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),null!==e&&null!==e.child||(vo(t)?ls(t):null===e||e.memoizedState.isDehydrated&&!(256&t.flags)||(t.flags|=1024,wo())),fs(t),null;case 26:var o=t.type,i=t.memoizedState;return null===e?(ls(t),null!==i?(fs(t),cs(t,i)):(fs(t),ss(t,o,0,0,n))):i?i!==e.memoizedState?(ls(t),fs(t),cs(t,i)):(fs(t),t.flags&=-16777217):((e=e.memoizedProps)!==r&&ls(t),fs(t),ss(t,o,0,0,n)),null;case 27:if(J(t),n=W.current,o=t.type,null!==e&&null!=t.stateNode)e.memoizedProps!==r&&ls(t);else{if(!r){if(null===t.stateNode)throw Error(a(166));return fs(t),null}e=G.current,vo(t)?Ao(t):(e=Ld(o,r,n),t.stateNode=e,ls(t))}return fs(t),null;case 5:if(J(t),o=t.type,null!==e&&null!=t.stateNode)e.memoizedProps!==r&&ls(t);else{if(!r){if(null===t.stateNode)throw Error(a(166));return fs(t),null}if(i=G.current,vo(t))Ao(t);else{var l=md(W.current);switch(i){case 1:i=l.createElementNS("http://www.w3.org/2000/svg",o);break;case 2:i=l.createElementNS("http://www.w3.org/1998/Math/MathML",o);break;default:switch(o){case"svg":i=l.createElementNS("http://www.w3.org/2000/svg",o);break;case"math":i=l.createElementNS("http://www.w3.org/1998/Math/MathML",o);break;case"script":(i=l.createElement("div")).innerHTML="<script><\/script>",i=i.removeChild(i.firstChild);break;case"select":i="string"==typeof r.is?l.createElement("select",{is:r.is}):l.createElement("select"),r.multiple?i.multiple=!0:r.size&&(i.size=r.size);break;default:i="string"==typeof r.is?l.createElement(o,{is:r.is}):l.createElement(o)}}i[ze]=t,i[$e]=r;e:for(l=t.child;null!==l;){if(5===l.tag||6===l.tag)i.appendChild(l.stateNode);else if(4!==l.tag&&27!==l.tag&&null!==l.child){l.child.return=l,l=l.child;continue}if(l===t)break e;for(;null===l.sibling;){if(null===l.return||l.return===t)break e;l=l.return}l.sibling.return=l.return,l=l.sibling}t.stateNode=i;e:switch(fd(i,o,r),o){case"button":case"input":case"select":case"textarea":r=!!r.autoFocus;break e;case"img":r=!0;break e;default:r=!1}r&&ls(t)}}return fs(t),ss(t,t.type,null===e||e.memoizedProps,t.pendingProps,n),null;case 6:if(e&&null!=t.stateNode)e.memoizedProps!==r&&ls(t);else{if("string"!=typeof r&&null===t.stateNode)throw Error(a(166));if(e=W.current,vo(t)){if(e=t.stateNode,n=t.memoizedProps,r=null,null!==(o=co))switch(o.tag){case 27:case 5:r=o.memoizedProps}e[ze]=t,(e=!!(e.nodeValue===n||null!==r&&!0===r.suppressHydrationWarning||cd(e.nodeValue,n)))||mo(t,!0)}else(e=md(e).createTextNode(r))[ze]=t,t.stateNode=e}return fs(t),null;case 31:if(n=t.memoizedState,null===e||null!==e.memoizedState){if(r=vo(t),null!==n){if(null===e){if(!r)throw Error(a(318));if(!(e=null!==(e=t.memoizedState)?e.dehydrated:null))throw Error(a(557));e[ze]=t}else yo(),!(128&t.flags)&&(t.memoizedState=null),t.flags|=4;fs(t),e=!1}else n=wo(),null!==e&&null!==e.memoizedState&&(e.memoizedState.hydrationErrors=n),e=!0;if(!e)return 256&t.flags?(Qi(t),t):(Qi(t),null);if(128&t.flags)throw Error(a(558))}return fs(t),null;case 13:if(r=t.memoizedState,null===e||null!==e.memoizedState&&null!==e.memoizedState.dehydrated){if(o=vo(t),null!==r&&null!==r.dehydrated){if(null===e){if(!o)throw Error(a(318));if(!(o=null!==(o=t.memoizedState)?o.dehydrated:null))throw Error(a(317));o[ze]=t}else yo(),!(128&t.flags)&&(t.memoizedState=null),t.flags|=4;fs(t),o=!1}else o=wo(),null!==e&&null!==e.memoizedState&&(e.memoizedState.hydrationErrors=o),o=!0;if(!o)return 256&t.flags?(Qi(t),t):(Qi(t),null)}return Qi(t),128&t.flags?(t.lanes=n,t):(n=null!==r,e=null!==e&&null!==e.memoizedState,n&&(o=null,null!==(r=t.child).alternate&&null!==r.alternate.memoizedState&&null!==r.alternate.memoizedState.cachePool&&(o=r.alternate.memoizedState.cachePool.pool),i=null,null!==r.memoizedState&&null!==r.memoizedState.cachePool&&(i=r.memoizedState.cachePool.pool),i!==o&&(r.flags|=2048)),n!==e&&n&&(t.child.flags|=8192),us(t,t.updateQueue),fs(t),null);case 4:return Y(),null===e&&Zu(t.stateNode.containerInfo),fs(t),null;case 10:return ko(t.type),fs(t),null;case 19:if(j(ji),null===(r=t.memoizedState))return fs(t),null;if(o=!!(128&t.flags),null===(i=r.rendering))if(o)ds(r,!1);else{if(0!==Sc||null!==e&&128&e.flags)for(e=t.child;null!==e;){if(null!==(i=zi(e))){for(t.flags|=128,ds(r,!1),e=i.updateQueue,t.updateQueue=e,us(t,e),t.subtreeFlags=0,e=n,n=t.child;null!==n;)zr(n,e),n=n.sibling;return z(ji,1&ji.current|2),fo&&oo(t,r.treeForkCount),t.child}e=e.sibling}null!==r.tail&&se()>Oc&&(t.flags|=128,o=!0,ds(r,!1),t.lanes=4194304)}else{if(!o)if(null!==(e=zi(i))){if(t.flags|=128,o=!0,e=e.updateQueue,t.updateQueue=e,us(t,e),ds(r,!0),null===r.tail&&"hidden"===r.tailMode&&!i.alternate&&!fo)return fs(t),null}else 2*se()-r.renderingStartTime>Oc&&536870912!==n&&(t.flags|=128,o=!0,ds(r,!1),t.lanes=4194304);r.isBackwards?(i.sibling=t.child,t.child=i):(null!==(e=r.last)?e.sibling=i:t.child=i,r.last=i)}return null!==r.tail?(e=r.tail,r.rendering=e,r.tail=e.sibling,r.renderingStartTime=se(),e.sibling=null,n=ji.current,z(ji,o?1&n|2:1&n),fo&&oo(t,r.treeForkCount),e):(fs(t),null);case 22:case 23:return Qi(t),_i(),r=null!==t.memoizedState,null!==e?null!==e.memoizedState!==r&&(t.flags|=8192):r&&(t.flags|=8192),r?!!(536870912&n)&&!(128&t.flags)&&(fs(t),6&t.subtreeFlags&&(t.flags|=8192)):fs(t),null!==(n=t.updateQueue)&&us(t,n.retryQueue),n=null,null!==e&&null!==e.memoizedState&&null!==e.memoizedState.cachePool&&(n=e.memoizedState.cachePool.pool),r=null,null!==t.memoizedState&&null!==t.memoizedState.cachePool&&(r=t.memoizedState.cachePool.pool),r!==n&&(t.flags|=2048),null!==e&&j(qo),null;case 24:return n=null,null!==e&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),ko(Qo),fs(t),null;case 25:case 30:return null}throw Error(a(156,t.tag))}function hs(e,t){switch(lo(t),t.tag){case 1:return 65536&(e=t.flags)?(t.flags=-65537&e|128,t):null;case 3:return ko(Qo),Y(),65536&(e=t.flags)&&!(128&e)?(t.flags=-65537&e|128,t):null;case 26:case 27:case 5:return J(t),null;case 31:if(null!==t.memoizedState){if(Qi(t),null===t.alternate)throw Error(a(340));yo()}return 65536&(e=t.flags)?(t.flags=-65537&e|128,t):null;case 13:if(Qi(t),null!==(e=t.memoizedState)&&null!==e.dehydrated){if(null===t.alternate)throw Error(a(340));yo()}return 65536&(e=t.flags)?(t.flags=-65537&e|128,t):null;case 19:return j(ji),null;case 4:return Y(),null;case 10:return ko(t.type),null;case 22:case 23:return Qi(t),_i(),null!==e&&j(qo),65536&(e=t.flags)?(t.flags=-65537&e|128,t):null;case 24:return ko(Qo),null;default:return null}}function gs(e,t){switch(lo(t),t.tag){case 3:ko(Qo),Y();break;case 26:case 27:case 5:J(t);break;case 4:Y();break;case 31:null!==t.memoizedState&&Qi(t);break;case 13:Qi(t);break;case 19:j(ji);break;case 10:ko(t.type);break;case 22:case 23:Qi(t),_i(),null!==e&&j(qo);break;case 24:ko(Qo)}}function ms(e,t){try{var n=t.updateQueue,r=null!==n?n.lastEffect:null;if(null!==r){var o=r.next;n=o;do{if((n.tag&e)===e){r=void 0;var i=n.create,a=n.inst;r=i(),a.destroy=r}n=n.next}while(n!==o)}}catch(e){Su(t,t.return,e)}}function As(e,t,n){try{var r=t.updateQueue,o=null!==r?r.lastEffect:null;if(null!==o){var i=o.next;r=i;do{if((r.tag&e)===e){var a=r.inst,l=a.destroy;if(void 0!==l){a.destroy=void 0,o=t;var s=n,c=l;try{c()}catch(e){Su(o,s,e)}}}r=r.next}while(r!==i)}}catch(e){Su(t,t.return,e)}}function bs(e){var t=e.updateQueue;if(null!==t){var n=e.stateNode;try{ki(t,n)}catch(t){Su(e,e.return,t)}}}function vs(e,t,n){n.props=Sl(e.type,e.memoizedProps),n.state=e.memoizedState;try{n.componentWillUnmount()}catch(n){Su(e,t,n)}}function ys(e,t){try{var n=e.ref;if(null!==n){switch(e.tag){case 26:case 27:case 5:var r=e.stateNode;break;default:r=e.stateNode}"function"==typeof n?e.refCleanup=n(r):n.current=r}}catch(n){Su(e,t,n)}}function ws(e,t){var n=e.ref,r=e.refCleanup;if(null!==n)if("function"==typeof r)try{r()}catch(n){Su(e,t,n)}finally{e.refCleanup=null,null!=(e=e.alternate)&&(e.refCleanup=null)}else if("function"==typeof n)try{n(null)}catch(n){Su(e,t,n)}else n.current=null}function Cs(e){var t=e.type,n=e.memoizedProps,r=e.stateNode;try{e:switch(t){case"button":case"input":case"select":case"textarea":n.autoFocus&&r.focus();break e;case"img":n.src?r.src=n.src:n.srcSet&&(r.srcset=n.srcSet)}}catch(t){Su(e,e.return,t)}}function Ss(e,t,n){try{var r=e.stateNode;!function(e,t,n,r){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var o=null,i=null,l=null,s=null,c=null,u=null,d=null;for(h in n){var f=n[h];if(n.hasOwnProperty(h)&&null!=f)switch(h){case"checked":case"value":break;case"defaultValue":c=f;default:r.hasOwnProperty(h)||ud(e,t,h,null,r,f)}}for(var p in r){var h=r[p];if(f=n[p],r.hasOwnProperty(p)&&(null!=h||null!=f))switch(p){case"type":i=h;break;case"name":o=h;break;case"checked":u=h;break;case"defaultChecked":d=h;break;case"value":l=h;break;case"defaultValue":s=h;break;case"children":case"dangerouslySetInnerHTML":if(null!=h)throw Error(a(137,t));break;default:h!==f&&ud(e,t,p,h,r,f)}}return void bt(e,l,s,c,u,d,i,o);case"select":for(i in h=l=s=p=null,n)if(c=n[i],n.hasOwnProperty(i)&&null!=c)switch(i){case"value":break;case"multiple":h=c;default:r.hasOwnProperty(i)||ud(e,t,i,null,r,c)}for(o in r)if(i=r[o],c=n[o],r.hasOwnProperty(o)&&(null!=i||null!=c))switch(o){case"value":p=i;break;case"defaultValue":s=i;break;case"multiple":l=i;default:i!==c&&ud(e,t,o,i,r,c)}return t=s,n=l,r=h,void(null!=p?wt(e,!!n,p,!1):!!r!=!!n&&(null!=t?wt(e,!!n,t,!0):wt(e,!!n,n?[]:"",!1)));case"textarea":for(s in h=p=null,n)if(o=n[s],n.hasOwnProperty(s)&&null!=o&&!r.hasOwnProperty(s))switch(s){case"value":case"children":break;default:ud(e,t,s,null,r,o)}for(l in r)if(o=r[l],i=n[l],r.hasOwnProperty(l)&&(null!=o||null!=i))switch(l){case"value":p=o;break;case"defaultValue":h=o;break;case"children":break;case"dangerouslySetInnerHTML":if(null!=o)throw Error(a(91));break;default:o!==i&&ud(e,t,l,o,r,i)}return void Ct(e,p,h);case"option":for(var g in n)p=n[g],n.hasOwnProperty(g)&&null!=p&&!r.hasOwnProperty(g)&&("selected"===g?e.selected=!1:ud(e,t,g,null,r,p));for(c in r)p=r[c],h=n[c],!r.hasOwnProperty(c)||p===h||null==p&&null==h||("selected"===c?e.selected=p&&"function"!=typeof p&&"symbol"!=typeof p:ud(e,t,c,p,r,h));return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var m in n)p=n[m],n.hasOwnProperty(m)&&null!=p&&!r.hasOwnProperty(m)&&ud(e,t,m,null,r,p);for(u in r)if(p=r[u],h=n[u],r.hasOwnProperty(u)&&p!==h&&(null!=p||null!=h))switch(u){case"children":case"dangerouslySetInnerHTML":if(null!=p)throw Error(a(137,t));break;default:ud(e,t,u,p,r,h)}return;default:if(Rt(t)){for(var A in n)p=n[A],n.hasOwnProperty(A)&&void 0!==p&&!r.hasOwnProperty(A)&&dd(e,t,A,void 0,r,p);for(d in r)p=r[d],h=n[d],!r.hasOwnProperty(d)||p===h||void 0===p&&void 0===h||dd(e,t,d,p,r,h);return}}for(var b in n)p=n[b],n.hasOwnProperty(b)&&null!=p&&!r.hasOwnProperty(b)&&ud(e,t,b,null,r,p);for(f in r)p=r[f],h=n[f],!r.hasOwnProperty(f)||p===h||null==p&&null==h||ud(e,t,f,p,r,h)}(r,e.type,n,t),r[$e]=t}catch(t){Su(e,e.return,t)}}function xs(e){return 5===e.tag||3===e.tag||26===e.tag||27===e.tag&&Id(e.type)||4===e.tag}function Es(e){e:for(;;){for(;null===e.sibling;){if(null===e.return||xs(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;5!==e.tag&&6!==e.tag&&18!==e.tag;){if(27===e.tag&&Id(e.type))continue e;if(2&e.flags)continue e;if(null===e.child||4===e.tag)continue e;e.child.return=e,e=e.child}if(!(2&e.flags))return e.stateNode}}function Is(e,t,n){var r=e.tag;if(5===r||6===r)e=e.stateNode,t?(9===n.nodeType?n.body:"HTML"===n.nodeName?n.ownerDocument.body:n).insertBefore(e,t):((t=9===n.nodeType?n.body:"HTML"===n.nodeName?n.ownerDocument.body:n).appendChild(e),null!=(n=n._reactRootContainer)||null!==t.onclick||(t.onclick=_t));else if(4!==r&&(27===r&&Id(e.type)&&(n=e.stateNode,t=null),null!==(e=e.child)))for(Is(e,t,n),e=e.sibling;null!==e;)Is(e,t,n),e=e.sibling}function ks(e,t,n){var r=e.tag;if(5===r||6===r)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(4!==r&&(27===r&&Id(e.type)&&(n=e.stateNode),null!==(e=e.child)))for(ks(e,t,n),e=e.sibling;null!==e;)ks(e,t,n),e=e.sibling}function Rs(e){var t=e.stateNode,n=e.memoizedProps;try{for(var r=e.type,o=t.attributes;o.length;)t.removeAttributeNode(o[0]);fd(t,r,n),t[ze]=e,t[$e]=n}catch(t){Su(e,e.return,t)}}var Ms=!1,Ps=!1,Bs=!1,_s="function"==typeof WeakSet?WeakSet:Set,Ts=null;function Os(e,t,n){var r=n.flags;switch(n.tag){case 0:case 11:case 15:qs(e,n),4&r&&ms(5,n);break;case 1:if(qs(e,n),4&r)if(e=n.stateNode,null===t)try{e.componentDidMount()}catch(e){Su(n,n.return,e)}else{var o=Sl(n.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(o,t,e.__reactInternalSnapshotBeforeUpdate)}catch(e){Su(n,n.return,e)}}64&r&&bs(n),512&r&&ys(n,n.return);break;case 3:if(qs(e,n),64&r&&null!==(e=n.updateQueue)){if(t=null,null!==n.child)switch(n.child.tag){case 27:case 5:case 1:t=n.child.stateNode}try{ki(e,t)}catch(e){Su(n,n.return,e)}}break;case 27:null===t&&4&r&&Rs(n);case 26:case 5:qs(e,n),null===t&&4&r&&Cs(n),512&r&&ys(n,n.return);break;case 12:qs(e,n);break;case 31:qs(e,n),4&r&&js(e,n);break;case 13:qs(e,n),4&r&&zs(e,n),64&r&&null!==(e=n.memoizedState)&&null!==(e=e.dehydrated)&&function(e,t){var n=e.ownerDocument;if("$~"===e.data)e._reactRetry=t;else if("$?"!==e.data||"loading"!==n.readyState)t();else{var r=function(){t(),n.removeEventListener("DOMContentLoaded",r)};n.addEventListener("DOMContentLoaded",r),e._reactRetry=r}}(e,n=ku.bind(null,n));break;case 22:if(!(r=null!==n.memoizedState||Ms)){t=null!==t&&null!==t.memoizedState||Ps,o=Ms;var i=Ps;Ms=r,(Ps=t)&&!i?Ks(e,n,!!(8772&n.subtreeFlags)):qs(e,n),Ms=o,Ps=i}break;case 30:break;default:qs(e,n)}}function Ds(e){var t=e.alternate;null!==t&&(e.alternate=null,Ds(t)),e.child=null,e.deletions=null,e.sibling=null,5===e.tag&&null!==(t=e.stateNode)&&Ye(t),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var Ns=null,Ls=!1;function Fs(e,t,n){for(n=n.child;null!==n;)Qs(e,t,n),n=n.sibling}function Qs(e,t,n){if(be&&"function"==typeof be.onCommitFiberUnmount)try{be.onCommitFiberUnmount(Ae,n)}catch(e){}switch(n.tag){case 26:Ps||ws(n,t),Fs(e,t,n),n.memoizedState?n.memoizedState.count--:n.stateNode&&(n=n.stateNode).parentNode.removeChild(n);break;case 27:Ps||ws(n,t);var r=Ns,o=Ls;Id(n.type)&&(Ns=n.stateNode,Ls=!1),Fs(e,t,n),Fd(n.stateNode),Ns=r,Ls=o;break;case 5:Ps||ws(n,t);case 6:if(r=Ns,o=Ls,Ns=null,Fs(e,t,n),Ls=o,null!==(Ns=r))if(Ls)try{(9===Ns.nodeType?Ns.body:"HTML"===Ns.nodeName?Ns.ownerDocument.body:Ns).removeChild(n.stateNode)}catch(e){Su(n,t,e)}else try{Ns.removeChild(n.stateNode)}catch(e){Su(n,t,e)}break;case 18:null!==Ns&&(Ls?(kd(9===(e=Ns).nodeType?e.body:"HTML"===e.nodeName?e.ownerDocument.body:e,n.stateNode),Vf(e)):kd(Ns,n.stateNode));break;case 4:r=Ns,o=Ls,Ns=n.stateNode.containerInfo,Ls=!0,Fs(e,t,n),Ns=r,Ls=o;break;case 0:case 11:case 14:case 15:As(2,n,t),Ps||As(4,n,t),Fs(e,t,n);break;case 1:Ps||(ws(n,t),"function"==typeof(r=n.stateNode).componentWillUnmount&&vs(n,t,r)),Fs(e,t,n);break;case 21:Fs(e,t,n);break;case 22:Ps=(r=Ps)||null!==n.memoizedState,Fs(e,t,n),Ps=r;break;default:Fs(e,t,n)}}function js(e,t){if(null===t.memoizedState&&null!==(e=t.alternate)&&null!==(e=e.memoizedState)){e=e.dehydrated;try{Vf(e)}catch(e){Su(t,t.return,e)}}}function zs(e,t){if(null===t.memoizedState&&null!==(e=t.alternate)&&null!==(e=e.memoizedState)&&null!==(e=e.dehydrated))try{Vf(e)}catch(e){Su(t,t.return,e)}}function $s(e,t){var n=function(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return null===t&&(t=e.stateNode=new _s),t;case 22:return null===(t=(e=e.stateNode)._retryCache)&&(t=e._retryCache=new _s),t;default:throw Error(a(435,e.tag))}}(e);t.forEach(function(t){if(!n.has(t)){n.add(t);var r=Ru.bind(null,e,t);t.then(r,r)}})}function Hs(e,t){var n=t.deletions;if(null!==n)for(var r=0;r<n.length;r++){var o=n[r],i=e,l=t,s=l;e:for(;null!==s;){switch(s.tag){case 27:if(Id(s.type)){Ns=s.stateNode,Ls=!1;break e}break;case 5:Ns=s.stateNode,Ls=!1;break e;case 3:case 4:Ns=s.stateNode.containerInfo,Ls=!0;break e}s=s.return}if(null===Ns)throw Error(a(160));Qs(i,l,o),Ns=null,Ls=!1,null!==(i=o.alternate)&&(i.return=null),o.return=null}if(13886&t.subtreeFlags)for(t=t.child;null!==t;)Vs(t,e),t=t.sibling}var Gs=null;function Vs(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:Hs(t,e),Ws(e),4&r&&(As(3,e,e.return),ms(3,e),As(5,e,e.return));break;case 1:Hs(t,e),Ws(e),512&r&&(Ps||null===n||ws(n,n.return)),64&r&&Ms&&null!==(e=e.updateQueue)&&null!==(r=e.callbacks)&&(n=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=null===n?r:n.concat(r));break;case 26:var o=Gs;if(Hs(t,e),Ws(e),512&r&&(Ps||null===n||ws(n,n.return)),4&r){var i=null!==n?n.memoizedState:null;if(r=e.memoizedState,null===n)if(null===r)if(null===e.stateNode){e:{r=e.type,n=e.memoizedProps,o=o.ownerDocument||o;t:switch(r){case"title":(!(i=o.getElementsByTagName("title")[0])||i[qe]||i[ze]||"http://www.w3.org/2000/svg"===i.namespaceURI||i.hasAttribute("itemprop"))&&(i=o.createElement(r),o.head.insertBefore(i,o.querySelector("head > title"))),fd(i,r,n),i[ze]=e,et(i),r=i;break e;case"link":var l=nf("link","href",o).get(r+(n.href||""));if(l)for(var s=0;s<l.length;s++)if((i=l[s]).getAttribute("href")===(null==n.href||""===n.href?null:n.href)&&i.getAttribute("rel")===(null==n.rel?null:n.rel)&&i.getAttribute("title")===(null==n.title?null:n.title)&&i.getAttribute("crossorigin")===(null==n.crossOrigin?null:n.crossOrigin)){l.splice(s,1);break t}fd(i=o.createElement(r),r,n),o.head.appendChild(i);break;case"meta":if(l=nf("meta","content",o).get(r+(n.content||"")))for(s=0;s<l.length;s++)if((i=l[s]).getAttribute("content")===(null==n.content?null:""+n.content)&&i.getAttribute("name")===(null==n.name?null:n.name)&&i.getAttribute("property")===(null==n.property?null:n.property)&&i.getAttribute("http-equiv")===(null==n.httpEquiv?null:n.httpEquiv)&&i.getAttribute("charset")===(null==n.charSet?null:n.charSet)){l.splice(s,1);break t}fd(i=o.createElement(r),r,n),o.head.appendChild(i);break;default:throw Error(a(468,r))}i[ze]=e,et(i),r=i}e.stateNode=r}else rf(o,e.type,e.stateNode);else e.stateNode=Jd(o,r,e.memoizedProps);else i!==r?(null===i?null!==n.stateNode&&(n=n.stateNode).parentNode.removeChild(n):i.count--,null===r?rf(o,e.type,e.stateNode):Jd(o,r,e.memoizedProps)):null===r&&null!==e.stateNode&&Ss(e,e.memoizedProps,n.memoizedProps)}break;case 27:Hs(t,e),Ws(e),512&r&&(Ps||null===n||ws(n,n.return)),null!==n&&4&r&&Ss(e,e.memoizedProps,n.memoizedProps);break;case 5:if(Hs(t,e),Ws(e),512&r&&(Ps||null===n||ws(n,n.return)),32&e.flags){o=e.stateNode;try{xt(o,"")}catch(t){Su(e,e.return,t)}}4&r&&null!=e.stateNode&&Ss(e,o=e.memoizedProps,null!==n?n.memoizedProps:o),1024&r&&(Bs=!0);break;case 6:if(Hs(t,e),Ws(e),4&r){if(null===e.stateNode)throw Error(a(162));r=e.memoizedProps,n=e.stateNode;try{n.nodeValue=r}catch(t){Su(e,e.return,t)}}break;case 3:if(tf=null,o=Gs,Gs=zd(t.containerInfo),Hs(t,e),Gs=o,Ws(e),4&r&&null!==n&&n.memoizedState.isDehydrated)try{Vf(t.containerInfo)}catch(t){Su(e,e.return,t)}Bs&&(Bs=!1,Us(e));break;case 4:r=Gs,Gs=zd(e.stateNode.containerInfo),Hs(t,e),Ws(e),Gs=r;break;case 12:default:Hs(t,e),Ws(e);break;case 31:case 19:Hs(t,e),Ws(e),4&r&&null!==(r=e.updateQueue)&&(e.updateQueue=null,$s(e,r));break;case 13:Hs(t,e),Ws(e),8192&e.child.flags&&null!==e.memoizedState!=(null!==n&&null!==n.memoizedState)&&(_c=se()),4&r&&null!==(r=e.updateQueue)&&(e.updateQueue=null,$s(e,r));break;case 22:o=null!==e.memoizedState;var c=null!==n&&null!==n.memoizedState,u=Ms,d=Ps;if(Ms=u||o,Ps=d||c,Hs(t,e),Ps=d,Ms=u,Ws(e),8192&r)e:for(t=e.stateNode,t._visibility=o?-2&t._visibility:1|t._visibility,o&&(null===n||c||Ms||Ps||Ys(e)),n=null,t=e;;){if(5===t.tag||26===t.tag){if(null===n){c=n=t;try{if(i=c.stateNode,o)"function"==typeof(l=i.style).setProperty?l.setProperty("display","none","important"):l.display="none";else{s=c.stateNode;var f=c.memoizedProps.style,p=null!=f&&f.hasOwnProperty("display")?f.display:null;s.style.display=null==p||"boolean"==typeof p?"":(""+p).trim()}}catch(e){Su(c,c.return,e)}}}else if(6===t.tag){if(null===n){c=t;try{c.stateNode.nodeValue=o?"":c.memoizedProps}catch(e){Su(c,c.return,e)}}}else if(18===t.tag){if(null===n){c=t;try{var h=c.stateNode;o?Rd(h,!0):Rd(c.stateNode,!1)}catch(e){Su(c,c.return,e)}}}else if((22!==t.tag&&23!==t.tag||null===t.memoizedState||t===e)&&null!==t.child){t.child.return=t,t=t.child;continue}if(t===e)break e;for(;null===t.sibling;){if(null===t.return||t.return===e)break e;n===t&&(n=null),t=t.return}n===t&&(n=null),t.sibling.return=t.return,t=t.sibling}4&r&&null!==(r=e.updateQueue)&&null!==(n=r.retryQueue)&&(r.retryQueue=null,$s(e,n));case 30:case 21:}}function Ws(e){var t=e.flags;if(2&t){try{for(var n,r=e.return;null!==r;){if(xs(r)){n=r;break}r=r.return}if(null==n)throw Error(a(160));switch(n.tag){case 27:var o=n.stateNode;ks(e,Es(e),o);break;case 5:var i=n.stateNode;32&n.flags&&(xt(i,""),n.flags&=-33),ks(e,Es(e),i);break;case 3:case 4:var l=n.stateNode.containerInfo;Is(e,Es(e),l);break;default:throw Error(a(161))}}catch(t){Su(e,e.return,t)}e.flags&=-3}4096&t&&(e.flags&=-4097)}function Us(e){if(1024&e.subtreeFlags)for(e=e.child;null!==e;){var t=e;Us(t),5===t.tag&&1024&t.flags&&t.stateNode.reset(),e=e.sibling}}function qs(e,t){if(8772&t.subtreeFlags)for(t=t.child;null!==t;)Os(e,t.alternate,t),t=t.sibling}function Ys(e){for(e=e.child;null!==e;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:As(4,t,t.return),Ys(t);break;case 1:ws(t,t.return);var n=t.stateNode;"function"==typeof n.componentWillUnmount&&vs(t,t.return,n),Ys(t);break;case 27:Fd(t.stateNode);case 26:case 5:ws(t,t.return),Ys(t);break;case 22:null===t.memoizedState&&Ys(t);break;default:Ys(t)}e=e.sibling}}function Ks(e,t,n){for(n=n&&!!(8772&t.subtreeFlags),t=t.child;null!==t;){var r=t.alternate,o=e,i=t,a=i.flags;switch(i.tag){case 0:case 11:case 15:Ks(o,i,n),ms(4,i);break;case 1:if(Ks(o,i,n),"function"==typeof(o=(r=i).stateNode).componentDidMount)try{o.componentDidMount()}catch(e){Su(r,r.return,e)}if(null!==(o=(r=i).updateQueue)){var l=r.stateNode;try{var s=o.shared.hiddenCallbacks;if(null!==s)for(o.shared.hiddenCallbacks=null,o=0;o<s.length;o++)Ii(s[o],l)}catch(e){Su(r,r.return,e)}}n&&64&a&&bs(i),ys(i,i.return);break;case 27:Rs(i);case 26:case 5:Ks(o,i,n),n&&null===r&&4&a&&Cs(i),ys(i,i.return);break;case 12:Ks(o,i,n);break;case 31:Ks(o,i,n),n&&4&a&&js(o,i);break;case 13:Ks(o,i,n),n&&4&a&&zs(o,i);break;case 22:null===i.memoizedState&&Ks(o,i,n),ys(i,i.return);break;case 30:break;default:Ks(o,i,n)}t=t.sibling}}function Js(e,t){var n=null;null!==e&&null!==e.memoizedState&&null!==e.memoizedState.cachePool&&(n=e.memoizedState.cachePool.pool),e=null,null!==t.memoizedState&&null!==t.memoizedState.cachePool&&(e=t.memoizedState.cachePool.pool),e!==n&&(null!=e&&e.refCount++,null!=n&&zo(n))}function Xs(e,t){e=null,null!==t.alternate&&(e=t.alternate.memoizedState.cache),(t=t.memoizedState.cache)!==e&&(t.refCount++,null!=e&&zo(e))}function Zs(e,t,n,r){if(10256&t.subtreeFlags)for(t=t.child;null!==t;)ec(e,t,n,r),t=t.sibling}function ec(e,t,n,r){var o=t.flags;switch(t.tag){case 0:case 11:case 15:Zs(e,t,n,r),2048&o&&ms(9,t);break;case 1:case 31:case 13:default:Zs(e,t,n,r);break;case 3:Zs(e,t,n,r),2048&o&&(e=null,null!==t.alternate&&(e=t.alternate.memoizedState.cache),(t=t.memoizedState.cache)!==e&&(t.refCount++,null!=e&&zo(e)));break;case 12:if(2048&o){Zs(e,t,n,r),e=t.stateNode;try{var i=t.memoizedProps,a=i.id,l=i.onPostCommit;"function"==typeof l&&l(a,null===t.alternate?"mount":"update",e.passiveEffectDuration,-0)}catch(e){Su(t,t.return,e)}}else Zs(e,t,n,r);break;case 23:break;case 22:i=t.stateNode,a=t.alternate,null!==t.memoizedState?2&i._visibility?Zs(e,t,n,r):nc(e,t):2&i._visibility?Zs(e,t,n,r):(i._visibility|=2,tc(e,t,n,r,!!(10256&t.subtreeFlags)||!1)),2048&o&&Js(a,t);break;case 24:Zs(e,t,n,r),2048&o&&Xs(t.alternate,t)}}function tc(e,t,n,r,o){for(o=o&&(!!(10256&t.subtreeFlags)||!1),t=t.child;null!==t;){var i=e,a=t,l=n,s=r,c=a.flags;switch(a.tag){case 0:case 11:case 15:tc(i,a,l,s,o),ms(8,a);break;case 23:break;case 22:var u=a.stateNode;null!==a.memoizedState?2&u._visibility?tc(i,a,l,s,o):nc(i,a):(u._visibility|=2,tc(i,a,l,s,o)),o&&2048&c&&Js(a.alternate,a);break;case 24:tc(i,a,l,s,o),o&&2048&c&&Xs(a.alternate,a);break;default:tc(i,a,l,s,o)}t=t.sibling}}function nc(e,t){if(10256&t.subtreeFlags)for(t=t.child;null!==t;){var n=e,r=t,o=r.flags;switch(r.tag){case 22:nc(n,r),2048&o&&Js(r.alternate,r);break;case 24:nc(n,r),2048&o&&Xs(r.alternate,r);break;default:nc(n,r)}t=t.sibling}}var rc=8192;function oc(e,t,n){if(e.subtreeFlags&rc)for(e=e.child;null!==e;)ic(e,t,n),e=e.sibling}function ic(e,t,n){switch(e.tag){case 26:oc(e,t,n),e.flags&rc&&null!==e.memoizedState&&function(e,t,n,r){if(!("stylesheet"!==n.type||"string"==typeof r.media&&!1===matchMedia(r.media).matches||4&n.state.loading)){if(null===n.instance){var o=Wd(r.href),i=t.querySelector(Ud(o));if(i)return null!==(t=i._p)&&"object"==typeof t&&"function"==typeof t.then&&(e.count++,e=lf.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=i,void et(i);i=t.ownerDocument||t,r=qd(r),(o=Qd.get(o))&&Zd(r,o),et(i=i.createElement("link"));var a=i;a._p=new Promise(function(e,t){a.onload=e,a.onerror=t}),fd(i,"link",r),n.instance=i}null===e.stylesheets&&(e.stylesheets=new Map),e.stylesheets.set(n,t),(t=n.state.preload)&&!(3&n.state.loading)&&(e.count++,n=lf.bind(e),t.addEventListener("load",n),t.addEventListener("error",n))}}(n,Gs,e.memoizedState,e.memoizedProps);break;case 5:default:oc(e,t,n);break;case 3:case 4:var r=Gs;Gs=zd(e.stateNode.containerInfo),oc(e,t,n),Gs=r;break;case 22:null===e.memoizedState&&(null!==(r=e.alternate)&&null!==r.memoizedState?(r=rc,rc=16777216,oc(e,t,n),rc=r):oc(e,t,n))}}function ac(e){var t=e.alternate;if(null!==t&&null!==(e=t.child)){t.child=null;do{t=e.sibling,e.sibling=null,e=t}while(null!==e)}}function lc(e){var t=e.deletions;if(16&e.flags){if(null!==t)for(var n=0;n<t.length;n++){var r=t[n];Ts=r,uc(r,e)}ac(e)}if(10256&e.subtreeFlags)for(e=e.child;null!==e;)sc(e),e=e.sibling}function sc(e){switch(e.tag){case 0:case 11:case 15:lc(e),2048&e.flags&&As(9,e,e.return);break;case 3:case 12:default:lc(e);break;case 22:var t=e.stateNode;null!==e.memoizedState&&2&t._visibility&&(null===e.return||13!==e.return.tag)?(t._visibility&=-3,cc(e)):lc(e)}}function cc(e){var t=e.deletions;if(16&e.flags){if(null!==t)for(var n=0;n<t.length;n++){var r=t[n];Ts=r,uc(r,e)}ac(e)}for(e=e.child;null!==e;){switch((t=e).tag){case 0:case 11:case 15:As(8,t,t.return),cc(t);break;case 22:2&(n=t.stateNode)._visibility&&(n._visibility&=-3,cc(t));break;default:cc(t)}e=e.sibling}}function uc(e,t){for(;null!==Ts;){var n=Ts;switch(n.tag){case 0:case 11:case 15:As(8,n,t);break;case 23:case 22:if(null!==n.memoizedState&&null!==n.memoizedState.cachePool){var r=n.memoizedState.cachePool.pool;null!=r&&r.refCount++}break;case 24:zo(n.memoizedState.cache)}if(null!==(r=n.child))r.return=n,Ts=r;else e:for(n=e;null!==Ts;){var o=(r=Ts).sibling,i=r.return;if(Ds(r),r===n){Ts=null;break e}if(null!==o){o.return=i,Ts=o;break e}Ts=i}}}var dc={getCacheForType:function(e){var t=To(Qo),n=t.data.get(e);return void 0===n&&(n=e(),t.data.set(e,n)),n},cacheSignal:function(){return To(Qo).controller.signal}},fc="function"==typeof WeakMap?WeakMap:Map,pc=0,hc=null,gc=null,mc=0,Ac=0,bc=null,vc=!1,yc=!1,wc=!1,Cc=0,Sc=0,xc=0,Ec=0,Ic=0,kc=0,Rc=0,Mc=null,Pc=null,Bc=!1,_c=0,Tc=0,Oc=1/0,Dc=null,Nc=null,Lc=0,Fc=null,Qc=null,jc=0,zc=0,$c=null,Hc=null,Gc=0,Vc=null;function Wc(){return 2&pc&&0!==mc?mc&-mc:null!==O.T?$u():Fe()}function Uc(){if(0===kc)if(536870912&mc&&!fo)kc=536870912;else{var e=xe;!(3932160&(xe<<=1))&&(xe=262144),kc=e}return null!==(e=Ti.current)&&(e.flags|=32),kc}function qc(e,t,n){(e!==hc||2!==Ac&&9!==Ac)&&null===e.cancelPendingCommit||(tu(e,0),Xc(e,mc,kc,!1)),_e(e,n),2&pc&&e===hc||(e===hc&&(!(2&pc)&&(Ec|=n),4===Sc&&Xc(e,mc,kc,!1)),Du(e))}function Yc(e,t,n){if(6&pc)throw Error(a(327));for(var r=!n&&!(127&t)&&0===(t&e.expiredLanes)||Re(e,t),o=r?function(e,t){var n=pc;pc|=2;var r=ou(),o=iu();hc!==e||mc!==t?(Dc=null,Oc=se()+500,tu(e,t)):yc=Re(e,t);e:for(;;)try{if(0!==Ac&&null!==gc){t=gc;var i=bc;t:switch(Ac){case 1:Ac=0,bc=null,fu(e,t,i,1);break;case 2:case 9:if(ni(i)){Ac=0,bc=null,du(t);break}t=function(){2!==Ac&&9!==Ac||hc!==e||(Ac=7),Du(e)},i.then(t,t);break e;case 3:Ac=7;break e;case 4:Ac=5;break e;case 7:ni(i)?(Ac=0,bc=null,du(t)):(Ac=0,bc=null,fu(e,t,i,7));break;case 5:var l=null;switch(gc.tag){case 26:l=gc.memoizedState;case 5:case 27:var s=gc;if(l?of(l):s.stateNode.complete){Ac=0,bc=null;var c=s.sibling;if(null!==c)gc=c;else{var u=s.return;null!==u?(gc=u,pu(u)):gc=null}break t}}Ac=0,bc=null,fu(e,t,i,5);break;case 6:Ac=0,bc=null,fu(e,t,i,6);break;case 8:eu(),Sc=6;break e;default:throw Error(a(462))}}cu();break}catch(t){nu(e,t)}return Eo=xo=null,O.H=r,O.A=o,pc=n,null!==gc?0:(hc=null,mc=0,Pr(),Sc)}(e,t):lu(e,t,!0),i=r;;){if(0===o){yc&&!r&&Xc(e,t,0,!1);break}if(n=e.current.alternate,!i||Jc(n)){if(2===o){if(i=t,e.errorRecoveryDisabledLanes&i)var l=0;else l=0!=(l=-536870913&e.pendingLanes)?l:536870912&l?536870912:0;if(0!==l){t=l;e:{var s=e;o=Mc;var c=s.current.memoizedState.isDehydrated;if(c&&(tu(s,l).flags|=256),2!==(l=lu(s,l,!1))){if(wc&&!c){s.errorRecoveryDisabledLanes|=i,Ec|=i,o=4;break e}i=Pc,Pc=o,null!==i&&(null===Pc?Pc=i:Pc.push.apply(Pc,i))}o=l}if(i=!1,2!==o)continue}}if(1===o){tu(e,0),Xc(e,t,0,!0);break}e:{switch(r=e,i=o){case 0:case 1:throw Error(a(345));case 4:if((4194048&t)!==t)break;case 6:Xc(r,t,kc,!vc);break e;case 2:Pc=null;break;case 3:case 5:break;default:throw Error(a(329))}if((62914560&t)===t&&10<(o=_c+300-se())){if(Xc(r,t,kc,!vc),0!==ke(r,0,!0))break e;jc=t,r.timeoutHandle=wd(Kc.bind(null,r,n,Pc,Dc,Bc,t,kc,Ec,Rc,vc,i,"Throttled",-0,0),o)}else Kc(r,n,Pc,Dc,Bc,t,kc,Ec,Rc,vc,i,null,-0,0)}break}o=lu(e,t,!1),i=!1}Du(e)}function Kc(e,t,n,r,o,i,a,l,s,c,u,d,f,p){if(e.timeoutHandle=-1,8192&(d=t.subtreeFlags)||!(16785408&~d)){ic(t,i,d={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:_t});var h=(62914560&i)===i?_c-se():(4194048&i)===i?Tc-se():0;if(null!==(h=function(e,t){return e.stylesheets&&0===e.count&&cf(e,e.stylesheets),0<e.count||0<e.imgCount?function(n){var r=setTimeout(function(){if(e.stylesheets&&cf(e,e.stylesheets),e.unsuspend){var t=e.unsuspend;e.unsuspend=null,t()}},6e4+t);0<e.imgBytes&&0===af&&(af=62500*function(){if("function"==typeof performance.getEntriesByType){for(var e=0,t=0,n=performance.getEntriesByType("resource"),r=0;r<n.length;r++){var o=n[r],i=o.transferSize,a=o.initiatorType,l=o.duration;if(i&&l&&pd(a)){for(a=0,l=o.responseEnd,r+=1;r<n.length;r++){var s=n[r],c=s.startTime;if(c>l)break;var u=s.transferSize,d=s.initiatorType;u&&pd(d)&&(a+=u*((s=s.responseEnd)<l?1:(l-c)/(s-c)))}if(--r,t+=8*(i+a)/(o.duration/1e3),10<++e)break}}if(0<e)return t/e/1e6}return navigator.connection&&"number"==typeof(e=navigator.connection.downlink)?e:5}());var o=setTimeout(function(){if(e.waitingForImages=!1,0===e.count&&(e.stylesheets&&cf(e,e.stylesheets),e.unsuspend)){var t=e.unsuspend;e.unsuspend=null,t()}},(e.imgBytes>af?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r),clearTimeout(o)}}:null}(d,h)))return jc=i,e.cancelPendingCommit=h(gu.bind(null,e,t,i,n,r,o,a,l,s,u,d,null,f,p)),void Xc(e,i,a,!c)}gu(e,t,i,n,r,o,a,l,s)}function Jc(e){for(var t=e;;){var n=t.tag;if((0===n||11===n||15===n)&&16384&t.flags&&null!==(n=t.updateQueue)&&null!==(n=n.stores))for(var r=0;r<n.length;r++){var o=n[r],i=o.getSnapshot;o=o.value;try{if(!Xn(i(),o))return!1}catch(e){return!1}}if(n=t.child,16384&t.subtreeFlags&&null!==n)n.return=t,t=n;else{if(t===e)break;for(;null===t.sibling;){if(null===t.return||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function Xc(e,t,n,r){t&=~Ic,t&=~Ec,e.suspendedLanes|=t,e.pingedLanes&=~t,r&&(e.warmLanes|=t),r=e.expirationTimes;for(var o=t;0<o;){var i=31-ye(o),a=1<<i;r[i]=-1,o&=~a}0!==n&&Te(e,n,t)}function Zc(){return!!(6&pc)||(Nu(0,!1),!1)}function eu(){if(null!==gc){if(0===Ac)var e=gc.return;else Eo=xo=null,la(e=gc),si=null,ci=0,e=gc;for(;null!==e;)gs(e.alternate,e),e=e.return;gc=null}}function tu(e,t){var n=e.timeoutHandle;-1!==n&&(e.timeoutHandle=-1,Cd(n)),null!==(n=e.cancelPendingCommit)&&(e.cancelPendingCommit=null,n()),jc=0,eu(),hc=e,gc=n=jr(e.current,null),mc=t,Ac=0,bc=null,vc=!1,yc=Re(e,t),wc=!1,Rc=kc=Ic=Ec=xc=Sc=0,Pc=Mc=null,Bc=!1,8&t&&(t|=32&t);var r=e.entangledLanes;if(0!==r)for(e=e.entanglements,r&=t;0<r;){var o=31-ye(r),i=1<<o;t|=e[o],r&=~i}return Cc=t,Pr(),n}function nu(e,t){Hi=null,O.H=gl,t===Xo||t===ei?(t=ai(),Ac=3):t===Zo?(t=ai(),Ac=4):Ac=t===_l?8:null!==t&&"object"==typeof t&&"function"==typeof t.then?6:1,bc=t,null===gc&&(Sc=1,kl(e,qr(t,e.current)))}function ru(){var e=Ti.current;return null===e||((4194048&mc)===mc?null===Oi:!!((62914560&mc)===mc||536870912&mc)&&e===Oi)}function ou(){var e=O.H;return O.H=gl,null===e?gl:e}function iu(){var e=O.A;return O.A=dc,e}function au(){Sc=4,vc||(4194048&mc)!==mc&&null!==Ti.current||(yc=!0),!(134217727&xc)&&!(134217727&Ec)||null===hc||Xc(hc,mc,kc,!1)}function lu(e,t,n){var r=pc;pc|=2;var o=ou(),i=iu();hc===e&&mc===t||(Dc=null,tu(e,t)),t=!1;var a=Sc;e:for(;;)try{if(0!==Ac&&null!==gc){var l=gc,s=bc;switch(Ac){case 8:eu(),a=6;break e;case 3:case 2:case 9:case 6:null===Ti.current&&(t=!0);var c=Ac;if(Ac=0,bc=null,fu(e,l,s,c),n&&yc){a=0;break e}break;default:c=Ac,Ac=0,bc=null,fu(e,l,s,c)}}su(),a=Sc;break}catch(t){nu(e,t)}return t&&e.shellSuspendCounter++,Eo=xo=null,pc=r,O.H=o,O.A=i,null===gc&&(hc=null,mc=0,Pr()),a}function su(){for(;null!==gc;)uu(gc)}function cu(){for(;null!==gc&&!ae();)uu(gc)}function uu(e){var t=as(e.alternate,e,Cc);e.memoizedProps=e.pendingProps,null===t?pu(e):gc=t}function du(e){var t=e,n=t.alternate;switch(t.tag){case 15:case 0:t=Vl(n,t,t.pendingProps,t.type,void 0,mc);break;case 11:t=Vl(n,t,t.pendingProps,t.type.render,t.ref,mc);break;case 5:la(t);default:gs(n,t),t=as(n,t=gc=zr(t,Cc),Cc)}e.memoizedProps=e.pendingProps,null===t?pu(e):gc=t}function fu(e,t,n,r){Eo=xo=null,la(t),si=null,ci=0;var o=t.return;try{if(function(e,t,n,r,o){if(n.flags|=32768,null!==r&&"object"==typeof r&&"function"==typeof r.then){if(null!==(t=n.alternate)&&Po(t,n,o,!0),null!==(n=Ti.current)){switch(n.tag){case 31:case 13:return null===Oi?au():null===n.alternate&&0===Sc&&(Sc=3),n.flags&=-257,n.flags|=65536,n.lanes=o,r===ti?n.flags|=16384:(null===(t=n.updateQueue)?n.updateQueue=new Set([r]):t.add(r),xu(e,r,o)),!1;case 22:return n.flags|=65536,r===ti?n.flags|=16384:(null===(t=n.updateQueue)?(t={transitions:null,markerInstances:null,retryQueue:new Set([r])},n.updateQueue=t):null===(n=t.retryQueue)?t.retryQueue=new Set([r]):n.add(r),xu(e,r,o)),!1}throw Error(a(435,n.tag))}return xu(e,r,o),au(),!1}if(fo)return null!==(t=Ti.current)?(!(65536&t.flags)&&(t.flags|=256),t.flags|=65536,t.lanes=o,r!==go&&Co(qr(e=Error(a(422),{cause:r}),n))):(r!==go&&Co(qr(t=Error(a(423),{cause:r}),n)),(e=e.current.alternate).flags|=65536,o&=-o,e.lanes|=o,r=qr(r,n),Ci(e,o=Ml(e.stateNode,r,o)),4!==Sc&&(Sc=2)),!1;var i=Error(a(520),{cause:r});if(i=qr(i,n),null===Mc?Mc=[i]:Mc.push(i),4!==Sc&&(Sc=2),null===t)return!0;r=qr(r,n),n=t;do{switch(n.tag){case 3:return n.flags|=65536,e=o&-o,n.lanes|=e,Ci(n,e=Ml(n.stateNode,r,e)),!1;case 1:if(t=n.type,i=n.stateNode,!(128&n.flags||"function"!=typeof t.getDerivedStateFromError&&(null===i||"function"!=typeof i.componentDidCatch||null!==Nc&&Nc.has(i))))return n.flags|=65536,o&=-o,n.lanes|=o,Bl(o=Pl(o),e,n,r),Ci(n,o),!1}n=n.return}while(null!==n);return!1}(e,o,t,n,mc))return Sc=1,kl(e,qr(n,e.current)),void(gc=null)}catch(t){if(null!==o)throw gc=o,t;return Sc=1,kl(e,qr(n,e.current)),void(gc=null)}32768&t.flags?(fo||1===r?e=!0:yc||536870912&mc?e=!1:(vc=e=!0,(2===r||9===r||3===r||6===r)&&null!==(r=Ti.current)&&13===r.tag&&(r.flags|=16384)),hu(t,e)):pu(t)}function pu(e){var t=e;do{if(32768&t.flags)return void hu(t,vc);e=t.return;var n=ps(t.alternate,t,Cc);if(null!==n)return void(gc=n);if(null!==(t=t.sibling))return void(gc=t);gc=t=e}while(null!==t);0===Sc&&(Sc=5)}function hu(e,t){do{var n=hs(e.alternate,e);if(null!==n)return n.flags&=32767,void(gc=n);if(null!==(n=e.return)&&(n.flags|=32768,n.subtreeFlags=0,n.deletions=null),!t&&null!==(e=e.sibling))return void(gc=e);gc=e=n}while(null!==e);Sc=6,gc=null}function gu(e,t,n,r,o,i,l,s,c){e.cancelPendingCommit=null;do{yu()}while(0!==Lc);if(6&pc)throw Error(a(327));if(null!==t){if(t===e.current)throw Error(a(177));if(i=t.lanes|t.childLanes,function(e,t,n,r,o,i){var a=e.pendingLanes;e.pendingLanes=n,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=n,e.entangledLanes&=n,e.errorRecoveryDisabledLanes&=n,e.shellSuspendCounter=0;var l=e.entanglements,s=e.expirationTimes,c=e.hiddenUpdates;for(n=a&~n;0<n;){var u=31-ye(n),d=1<<u;l[u]=0,s[u]=-1;var f=c[u];if(null!==f)for(c[u]=null,u=0;u<f.length;u++){var p=f[u];null!==p&&(p.lane&=-536870913)}n&=~d}0!==r&&Te(e,r,0),0!==i&&0===o&&0!==e.tag&&(e.suspendedLanes|=i&~(a&~t))}(e,n,i|=Mr,l,s,c),e===hc&&(gc=hc=null,mc=0),Qc=t,Fc=e,jc=n,zc=i,$c=o,Hc=r,10256&t.subtreeFlags||10256&t.flags?(e.callbackNode=null,e.callbackPriority=0,oe(fe,function(){return wu(),null})):(e.callbackNode=null,e.callbackPriority=0),r=!!(13878&t.flags),13878&t.subtreeFlags||r){r=O.T,O.T=null,o=D.p,D.p=2,l=pc,pc|=4;try{!function(e,t){if(e=e.containerInfo,hd=yf,or(e=rr(e))){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{var r=(n=(n=e.ownerDocument)&&n.defaultView||window).getSelection&&n.getSelection();if(r&&0!==r.rangeCount){n=r.anchorNode;var o=r.anchorOffset,i=r.focusNode;r=r.focusOffset;try{n.nodeType,i.nodeType}catch(e){n=null;break e}var l=0,s=-1,c=-1,u=0,d=0,f=e,p=null;t:for(;;){for(var h;f!==n||0!==o&&3!==f.nodeType||(s=l+o),f!==i||0!==r&&3!==f.nodeType||(c=l+r),3===f.nodeType&&(l+=f.nodeValue.length),null!==(h=f.firstChild);)p=f,f=h;for(;;){if(f===e)break t;if(p===n&&++u===o&&(s=l),p===i&&++d===r&&(c=l),null!==(h=f.nextSibling))break;p=(f=p).parentNode}f=h}n=-1===s||-1===c?null:{start:s,end:c}}else n=null}n=n||{start:0,end:0}}else n=null;for(gd={focusedElem:e,selectionRange:n},yf=!1,Ts=t;null!==Ts;)if(e=(t=Ts).child,1028&t.subtreeFlags&&null!==e)e.return=t,Ts=e;else for(;null!==Ts;){switch(i=(t=Ts).alternate,e=t.flags,t.tag){case 0:if(4&e&&null!==(e=null!==(e=t.updateQueue)?e.events:null))for(n=0;n<e.length;n++)(o=e[n]).ref.impl=o.nextImpl;break;case 11:case 15:case 5:case 26:case 27:case 6:case 4:case 17:break;case 1:if(1024&e&&null!==i){e=void 0,n=t,o=i.memoizedProps,i=i.memoizedState,r=n.stateNode;try{var g=Sl(n.type,o);e=r.getSnapshotBeforeUpdate(g,i),r.__reactInternalSnapshotBeforeUpdate=e}catch(e){Su(n,n.return,e)}}break;case 3:if(1024&e)if(9===(n=(e=t.stateNode.containerInfo).nodeType))Md(e);else if(1===n)switch(e.nodeName){case"HEAD":case"HTML":case"BODY":Md(e);break;default:e.textContent=""}break;default:if(1024&e)throw Error(a(163))}if(null!==(e=t.sibling)){e.return=t.return,Ts=e;break}Ts=t.return}}(e,t)}finally{pc=l,D.p=o,O.T=r}}Lc=1,mu(),Au(),bu()}}function mu(){if(1===Lc){Lc=0;var e=Fc,t=Qc,n=!!(13878&t.flags);if(13878&t.subtreeFlags||n){n=O.T,O.T=null;var r=D.p;D.p=2;var o=pc;pc|=4;try{Vs(t,e);var i=gd,a=rr(e.containerInfo),l=i.focusedElem,s=i.selectionRange;if(a!==l&&l&&l.ownerDocument&&nr(l.ownerDocument.documentElement,l)){if(null!==s&&or(l)){var c=s.start,u=s.end;if(void 0===u&&(u=c),"selectionStart"in l)l.selectionStart=c,l.selectionEnd=Math.min(u,l.value.length);else{var d=l.ownerDocument||document,f=d&&d.defaultView||window;if(f.getSelection){var p=f.getSelection(),h=l.textContent.length,g=Math.min(s.start,h),m=void 0===s.end?g:Math.min(s.end,h);!p.extend&&g>m&&(a=m,m=g,g=a);var A=tr(l,g),b=tr(l,m);if(A&&b&&(1!==p.rangeCount||p.anchorNode!==A.node||p.anchorOffset!==A.offset||p.focusNode!==b.node||p.focusOffset!==b.offset)){var v=d.createRange();v.setStart(A.node,A.offset),p.removeAllRanges(),g>m?(p.addRange(v),p.extend(b.node,b.offset)):(v.setEnd(b.node,b.offset),p.addRange(v))}}}}for(d=[],p=l;p=p.parentNode;)1===p.nodeType&&d.push({element:p,left:p.scrollLeft,top:p.scrollTop});for("function"==typeof l.focus&&l.focus(),l=0;l<d.length;l++){var y=d[l];y.element.scrollLeft=y.left,y.element.scrollTop=y.top}}yf=!!hd,gd=hd=null}finally{pc=o,D.p=r,O.T=n}}e.current=t,Lc=2}}function Au(){if(2===Lc){Lc=0;var e=Fc,t=Qc,n=!!(8772&t.flags);if(8772&t.subtreeFlags||n){n=O.T,O.T=null;var r=D.p;D.p=2;var o=pc;pc|=4;try{Os(e,t.alternate,t)}finally{pc=o,D.p=r,O.T=n}}Lc=3}}function bu(){if(4===Lc||3===Lc){Lc=0,le();var e=Fc,t=Qc,n=jc,r=Hc;10256&t.subtreeFlags||10256&t.flags?Lc=5:(Lc=0,Qc=Fc=null,vu(e,e.pendingLanes));var o=e.pendingLanes;if(0===o&&(Nc=null),Le(n),t=t.stateNode,be&&"function"==typeof be.onCommitFiberRoot)try{be.onCommitFiberRoot(Ae,t,void 0,!(128&~t.current.flags))}catch(e){}if(null!==r){t=O.T,o=D.p,D.p=2,O.T=null;try{for(var i=e.onRecoverableError,a=0;a<r.length;a++){var l=r[a];i(l.value,{componentStack:l.stack})}}finally{O.T=t,D.p=o}}3&jc&&yu(),Du(e),o=e.pendingLanes,261930&n&&42&o?e===Vc?Gc++:(Gc=0,Vc=e):Gc=0,Nu(0,!1)}}function vu(e,t){0===(e.pooledCacheLanes&=t)&&null!=(t=e.pooledCache)&&(e.pooledCache=null,zo(t))}function yu(){return mu(),Au(),bu(),wu()}function wu(){if(5!==Lc)return!1;var e=Fc,t=zc;zc=0;var n=Le(jc),r=O.T,o=D.p;try{D.p=32>n?32:n,O.T=null,n=$c,$c=null;var i=Fc,l=jc;if(Lc=0,Qc=Fc=null,jc=0,6&pc)throw Error(a(331));var s=pc;if(pc|=4,sc(i.current),ec(i,i.current,l,n),pc=s,Nu(0,!1),be&&"function"==typeof be.onPostCommitFiberRoot)try{be.onPostCommitFiberRoot(Ae,i)}catch(e){}return!0}finally{D.p=o,O.T=r,vu(e,t)}}function Cu(e,t,n){t=qr(n,t),null!==(e=yi(e,t=Ml(e.stateNode,t,2),2))&&(_e(e,2),Du(e))}function Su(e,t,n){if(3===e.tag)Cu(e,e,n);else for(;null!==t;){if(3===t.tag){Cu(t,e,n);break}if(1===t.tag){var r=t.stateNode;if("function"==typeof t.type.getDerivedStateFromError||"function"==typeof r.componentDidCatch&&(null===Nc||!Nc.has(r))){e=qr(n,e),null!==(r=yi(t,n=Pl(2),2))&&(Bl(n,r,t,e),_e(r,2),Du(r));break}}t=t.return}}function xu(e,t,n){var r=e.pingCache;if(null===r){r=e.pingCache=new fc;var o=new Set;r.set(t,o)}else void 0===(o=r.get(t))&&(o=new Set,r.set(t,o));o.has(n)||(wc=!0,o.add(n),e=Eu.bind(null,e,t,n),t.then(e,e))}function Eu(e,t,n){var r=e.pingCache;null!==r&&r.delete(t),e.pingedLanes|=e.suspendedLanes&n,e.warmLanes&=~n,hc===e&&(mc&n)===n&&(4===Sc||3===Sc&&(62914560&mc)===mc&&300>se()-_c?!(2&pc)&&tu(e,0):Ic|=n,Rc===mc&&(Rc=0)),Du(e)}function Iu(e,t){0===t&&(t=Pe()),null!==(e=Tr(e,t))&&(_e(e,t),Du(e))}function ku(e){var t=e.memoizedState,n=0;null!==t&&(n=t.retryLane),Iu(e,n)}function Ru(e,t){var n=0;switch(e.tag){case 31:case 13:var r=e.stateNode,o=e.memoizedState;null!==o&&(n=o.retryLane);break;case 19:r=e.stateNode;break;case 22:r=e.stateNode._retryCache;break;default:throw Error(a(314))}null!==r&&r.delete(t),Iu(e,n)}var Mu=null,Pu=null,Bu=!1,_u=!1,Tu=!1,Ou=0;function Du(e){e!==Pu&&null===e.next&&(null===Pu?Mu=Pu=e:Pu=Pu.next=e),_u=!0,Bu||(Bu=!0,xd(function(){6&pc?oe(ue,Lu):Fu()}))}function Nu(e,t){if(!Tu&&_u){Tu=!0;do{for(var n=!1,r=Mu;null!==r;){if(!t)if(0!==e){var o=r.pendingLanes;if(0===o)var i=0;else{var a=r.suspendedLanes,l=r.pingedLanes;i=(1<<31-ye(42|e)+1)-1,i=201326741&(i&=o&~(a&~l))?201326741&i|1:i?2|i:0}0!==i&&(n=!0,zu(r,i))}else i=mc,!(3&(i=ke(r,r===hc?i:0,null!==r.cancelPendingCommit||-1!==r.timeoutHandle)))||Re(r,i)||(n=!0,zu(r,i));r=r.next}}while(n);Tu=!1}}function Lu(){Fu()}function Fu(){_u=Bu=!1;var e,t=0;0!==Ou&&((e=window.event)&&"popstate"===e.type?e!==yd&&(yd=e,1):(yd=null,0))&&(t=Ou);for(var n=se(),r=null,o=Mu;null!==o;){var i=o.next,a=Qu(o,n);0===a?(o.next=null,null===r?Mu=i:r.next=i,null===i&&(Pu=r)):(r=o,(0!==t||3&a)&&(_u=!0)),o=i}0!==Lc&&5!==Lc||Nu(t,!1),0!==Ou&&(Ou=0)}function Qu(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,o=e.expirationTimes,i=-62914561&e.pendingLanes;0<i;){var a=31-ye(i),l=1<<a,s=o[a];-1===s?0!==(l&n)&&0===(l&r)||(o[a]=Me(l,t)):s<=t&&(e.expiredLanes|=l),i&=~l}if(n=mc,n=ke(e,e===(t=hc)?n:0,null!==e.cancelPendingCommit||-1!==e.timeoutHandle),r=e.callbackNode,0===n||e===t&&(2===Ac||9===Ac)||null!==e.cancelPendingCommit)return null!==r&&null!==r&&ie(r),e.callbackNode=null,e.callbackPriority=0;if(!(3&n)||Re(e,n)){if((t=n&-n)===e.callbackPriority)return t;switch(null!==r&&ie(r),Le(n)){case 2:case 8:n=de;break;case 32:default:n=fe;break;case 268435456:n=he}return r=ju.bind(null,e),n=oe(n,r),e.callbackPriority=t,e.callbackNode=n,t}return null!==r&&null!==r&&ie(r),e.callbackPriority=2,e.callbackNode=null,2}function ju(e,t){if(0!==Lc&&5!==Lc)return e.callbackNode=null,e.callbackPriority=0,null;var n=e.callbackNode;if(yu()&&e.callbackNode!==n)return null;var r=mc;return 0===(r=ke(e,e===hc?r:0,null!==e.cancelPendingCommit||-1!==e.timeoutHandle))?null:(Yc(e,r,t),Qu(e,se()),null!=e.callbackNode&&e.callbackNode===n?ju.bind(null,e):null)}function zu(e,t){if(yu())return null;Yc(e,t,!0)}function $u(){if(0===Ou){var e=Go;0===e&&(e=Se,!(261888&(Se<<=1))&&(Se=256)),Ou=e}return Ou}function Hu(e){return null==e||"symbol"==typeof e||"boolean"==typeof e?null:"function"==typeof e?e:Bt(""+e)}function Gu(e,t){var n=t.ownerDocument.createElement("input");return n.name=t.name,n.value=t.value,e.id&&n.setAttribute("form",e.id),t.parentNode.insertBefore(n,t),e=new FormData(e),n.parentNode.removeChild(n),e}for(var Vu=0;Vu<xr.length;Vu++){var Wu=xr[Vu];Er(Wu.toLowerCase(),"on"+(Wu[0].toUpperCase()+Wu.slice(1)))}Er(mr,"onAnimationEnd"),Er(Ar,"onAnimationIteration"),Er(br,"onAnimationStart"),Er("dblclick","onDoubleClick"),Er("focusin","onFocus"),Er("focusout","onBlur"),Er(vr,"onTransitionRun"),Er(yr,"onTransitionStart"),Er(wr,"onTransitionCancel"),Er(Cr,"onTransitionEnd"),ot("onMouseEnter",["mouseout","mouseover"]),ot("onMouseLeave",["mouseout","mouseover"]),ot("onPointerEnter",["pointerout","pointerover"]),ot("onPointerLeave",["pointerout","pointerover"]),rt("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),rt("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),rt("onBeforeInput",["compositionend","keypress","textInput","paste"]),rt("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),rt("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),rt("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Uu="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),qu=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(Uu));function Yu(e,t){t=!!(4&t);for(var n=0;n<e.length;n++){var r=e[n],o=r.event;r=r.listeners;e:{var i=void 0;if(t)for(var a=r.length-1;0<=a;a--){var l=r[a],s=l.instance,c=l.currentTarget;if(l=l.listener,s!==i&&o.isPropagationStopped())break e;i=l,o.currentTarget=c;try{i(o)}catch(e){Ir(e)}o.currentTarget=null,i=s}else for(a=0;a<r.length;a++){if(s=(l=r[a]).instance,c=l.currentTarget,l=l.listener,s!==i&&o.isPropagationStopped())break e;i=l,o.currentTarget=c;try{i(o)}catch(e){Ir(e)}o.currentTarget=null,i=s}}}}function Ku(e,t){var n=t[Ge];void 0===n&&(n=t[Ge]=new Set);var r=e+"__bubble";n.has(r)||(ed(t,e,2,!1),n.add(r))}function Ju(e,t,n){var r=0;t&&(r|=4),ed(n,e,r,t)}var Xu="_reactListening"+Math.random().toString(36).slice(2);function Zu(e){if(!e[Xu]){e[Xu]=!0,tt.forEach(function(t){"selectionchange"!==t&&(qu.has(t)||Ju(t,!1,e),Ju(t,!0,e))});var t=9===e.nodeType?e:e.ownerDocument;null===t||t[Xu]||(t[Xu]=!0,Ju("selectionchange",!1,t))}}function ed(e,t,n,r){switch(kf(t)){case 2:var o=wf;break;case 8:o=Cf;break;default:o=Sf}n=o.bind(null,t,n,e),o=void 0,!$t||"touchstart"!==t&&"touchmove"!==t&&"wheel"!==t||(o=!0),r?void 0!==o?e.addEventListener(t,n,{capture:!0,passive:o}):e.addEventListener(t,n,!0):void 0!==o?e.addEventListener(t,n,{passive:o}):e.addEventListener(t,n,!1)}function td(e,t,n,r,o){var i=r;if(!(1&t||2&t||null===r))e:for(;;){if(null===r)return;var a=r.tag;if(3===a||4===a){var l=r.stateNode.containerInfo;if(l===o)break;if(4===a)for(a=r.return;null!==a;){var c=a.tag;if((3===c||4===c)&&a.stateNode.containerInfo===o)return;a=a.return}for(;null!==l;){if(null===(a=Ke(l)))return;if(5===(c=a.tag)||6===c||26===c||27===c){r=i=a;continue e}l=l.parentNode}}r=r.return}Qt(function(){var r=i,o=Ot(n),a=[];e:{var l=Sr.get(e);if(void 0!==l){var c=nn,u=e;switch(e){case"keypress":if(0===qt(n))break e;case"keydown":case"keyup":c=bn;break;case"focusin":u="focus",c=cn;break;case"focusout":u="blur",c=cn;break;case"beforeblur":case"afterblur":c=cn;break;case"click":if(2===n.button)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":c=ln;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":c=sn;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":c=yn;break;case mr:case Ar:case br:c=un;break;case Cr:c=wn;break;case"scroll":case"scrollend":c=on;break;case"wheel":c=Cn;break;case"copy":case"cut":case"paste":c=dn;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":c=vn;break;case"toggle":case"beforetoggle":c=Sn}var d=!!(4&t),f=!d&&("scroll"===e||"scrollend"===e),p=d?null!==l?l+"Capture":null:l;d=[];for(var h,g=r;null!==g;){var m=g;if(h=m.stateNode,5!==(m=m.tag)&&26!==m&&27!==m||null===h||null===p||null!=(m=jt(g,p))&&d.push(nd(g,m,h)),f)break;g=g.return}0<d.length&&(l=new c(l,u,null,n,o),a.push({event:l,listeners:d}))}}if(!(7&t)){if(c="mouseout"===e||"pointerout"===e,(!(l="mouseover"===e||"pointerover"===e)||n===Tt||!(u=n.relatedTarget||n.fromElement)||!Ke(u)&&!u[He])&&(c||l)&&(l=o.window===o?o:(l=o.ownerDocument)?l.defaultView||l.parentWindow:window,c?(c=r,null!==(u=(u=n.relatedTarget||n.toElement)?Ke(u):null)&&(f=s(u),d=u.tag,u!==f||5!==d&&27!==d&&6!==d)&&(u=null)):(c=null,u=r),c!==u)){if(d=ln,m="onMouseLeave",p="onMouseEnter",g="mouse","pointerout"!==e&&"pointerover"!==e||(d=vn,m="onPointerLeave",p="onPointerEnter",g="pointer"),f=null==c?l:Xe(c),h=null==u?l:Xe(u),(l=new d(m,g+"leave",c,n,o)).target=f,l.relatedTarget=h,m=null,Ke(o)===r&&((d=new d(p,g+"enter",u,n,o)).target=h,d.relatedTarget=f,m=d),f=m,c&&u)e:{for(d=od,g=u,h=0,m=p=c;m;m=d(m))h++;m=0;for(var A=g;A;A=d(A))m++;for(;0<h-m;)p=d(p),h--;for(;0<m-h;)g=d(g),m--;for(;h--;){if(p===g||null!==g&&p===g.alternate){d=p;break e}p=d(p),g=d(g)}d=null}else d=null;null!==c&&id(a,l,c,d,!1),null!==u&&null!==f&&id(a,f,u,d,!0)}if("select"===(c=(l=r?Xe(r):window).nodeName&&l.nodeName.toLowerCase())||"input"===c&&"file"===l.type)var b=zn;else if(Dn(l))if($n)b=Jn;else{b=Yn;var v=qn}else!(c=l.nodeName)||"input"!==c.toLowerCase()||"checkbox"!==l.type&&"radio"!==l.type?r&&Rt(r.elementType)&&(b=zn):b=Kn;switch(b&&(b=b(e,r))?Nn(a,b,n,o):(v&&v(e,l,r),"focusout"===e&&r&&"number"===l.type&&null!=r.memoizedProps.value&&yt(l,"number",l.value)),v=r?Xe(r):window,e){case"focusin":(Dn(v)||"true"===v.contentEditable)&&(ar=v,lr=r,sr=null);break;case"focusout":sr=lr=ar=null;break;case"mousedown":cr=!0;break;case"contextmenu":case"mouseup":case"dragend":cr=!1,ur(a,n,o);break;case"selectionchange":if(ir)break;case"keydown":case"keyup":ur(a,n,o)}var y;if(En)e:{switch(e){case"compositionstart":var w="onCompositionStart";break e;case"compositionend":w="onCompositionEnd";break e;case"compositionupdate":w="onCompositionUpdate";break e}w=void 0}else Tn?Bn(e,n)&&(w="onCompositionEnd"):"keydown"===e&&229===n.keyCode&&(w="onCompositionStart");w&&(Rn&&"ko"!==n.locale&&(Tn||"onCompositionStart"!==w?"onCompositionEnd"===w&&Tn&&(y=Ut()):(Vt="value"in(Gt=o)?Gt.value:Gt.textContent,Tn=!0)),0<(v=rd(r,w)).length&&(w=new fn(w,e,null,n,o),a.push({event:w,listeners:v}),(y||null!==(y=_n(n)))&&(w.data=y))),(y=kn?function(e,t){switch(e){case"compositionend":return _n(t);case"keypress":return 32!==t.which?null:(Pn=!0,Mn);case"textInput":return(e=t.data)===Mn&&Pn?null:e;default:return null}}(e,n):function(e,t){if(Tn)return"compositionend"===e||!En&&Bn(e,t)?(e=Ut(),Wt=Vt=Gt=null,Tn=!1,e):null;switch(e){case"paste":default:return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return Rn&&"ko"!==t.locale?null:t.data}}(e,n))&&0<(w=rd(r,"onBeforeInput")).length&&(v=new fn("onBeforeInput","beforeinput",null,n,o),a.push({event:v,listeners:w}),v.data=y),function(e,t,n,r,o){if("submit"===t&&n&&n.stateNode===o){var i=Hu((o[$e]||null).action),a=r.submitter;a&&null!==(t=(t=a[$e]||null)?Hu(t.formAction):a.getAttribute("formAction"))&&(i=t,a=null);var l=new nn("action","action",null,r,o);e.push({event:l,listeners:[{instance:null,listener:function(){if(r.defaultPrevented){if(0!==Ou){var e=a?Gu(o,a):new FormData(o);tl(n,{pending:!0,data:e,method:o.method,action:i},null,e)}}else"function"==typeof i&&(l.preventDefault(),e=a?Gu(o,a):new FormData(o),tl(n,{pending:!0,data:e,method:o.method,action:i},i,e))},currentTarget:o}]})}}(a,e,r,n,o)}Yu(a,t)})}function nd(e,t,n){return{instance:e,listener:t,currentTarget:n}}function rd(e,t){for(var n=t+"Capture",r=[];null!==e;){var o=e,i=o.stateNode;if(5!==(o=o.tag)&&26!==o&&27!==o||null===i||(null!=(o=jt(e,n))&&r.unshift(nd(e,o,i)),null!=(o=jt(e,t))&&r.push(nd(e,o,i))),3===e.tag)return r;e=e.return}return[]}function od(e){if(null===e)return null;do{e=e.return}while(e&&5!==e.tag&&27!==e.tag);return e||null}function id(e,t,n,r,o){for(var i=t._reactName,a=[];null!==n&&n!==r;){var l=n,s=l.alternate,c=l.stateNode;if(l=l.tag,null!==s&&s===r)break;5!==l&&26!==l&&27!==l||null===c||(s=c,o?null!=(c=jt(n,i))&&a.unshift(nd(n,c,s)):o||null!=(c=jt(n,i))&&a.push(nd(n,c,s))),n=n.return}0!==a.length&&e.push({event:t,listeners:a})}var ad=/\r\n?/g,ld=/\u0000|\uFFFD/g;function sd(e){return("string"==typeof e?e:""+e).replace(ad,"\n").replace(ld,"")}function cd(e,t){return t=sd(t),sd(e)===t}function ud(e,t,n,r,o,i){switch(n){case"children":"string"==typeof r?"body"===t||"textarea"===t&&""===r||xt(e,r):("number"==typeof r||"bigint"==typeof r)&&"body"!==t&&xt(e,""+r);break;case"className":ct(e,"class",r);break;case"tabIndex":ct(e,"tabindex",r);break;case"dir":case"role":case"viewBox":case"width":case"height":ct(e,n,r);break;case"style":kt(e,r,i);break;case"data":if("object"!==t){ct(e,"data",r);break}case"src":case"href":if(""===r&&("a"!==t||"href"!==n)){e.removeAttribute(n);break}if(null==r||"function"==typeof r||"symbol"==typeof r||"boolean"==typeof r){e.removeAttribute(n);break}r=Bt(""+r),e.setAttribute(n,r);break;case"action":case"formAction":if("function"==typeof r){e.setAttribute(n,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}if("function"==typeof i&&("formAction"===n?("input"!==t&&ud(e,t,"name",o.name,o,null),ud(e,t,"formEncType",o.formEncType,o,null),ud(e,t,"formMethod",o.formMethod,o,null),ud(e,t,"formTarget",o.formTarget,o,null)):(ud(e,t,"encType",o.encType,o,null),ud(e,t,"method",o.method,o,null),ud(e,t,"target",o.target,o,null))),null==r||"symbol"==typeof r||"boolean"==typeof r){e.removeAttribute(n);break}r=Bt(""+r),e.setAttribute(n,r);break;case"onClick":null!=r&&(e.onclick=_t);break;case"onScroll":null!=r&&Ku("scroll",e);break;case"onScrollEnd":null!=r&&Ku("scrollend",e);break;case"dangerouslySetInnerHTML":if(null!=r){if("object"!=typeof r||!("__html"in r))throw Error(a(61));if(null!=(n=r.__html)){if(null!=o.children)throw Error(a(60));e.innerHTML=n}}break;case"multiple":e.multiple=r&&"function"!=typeof r&&"symbol"!=typeof r;break;case"muted":e.muted=r&&"function"!=typeof r&&"symbol"!=typeof r;break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":case"autoFocus":break;case"xlinkHref":if(null==r||"function"==typeof r||"boolean"==typeof r||"symbol"==typeof r){e.removeAttribute("xlink:href");break}n=Bt(""+r),e.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",n);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":null!=r&&"function"!=typeof r&&"symbol"!=typeof r?e.setAttribute(n,""+r):e.removeAttribute(n);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":r&&"function"!=typeof r&&"symbol"!=typeof r?e.setAttribute(n,""):e.removeAttribute(n);break;case"capture":case"download":!0===r?e.setAttribute(n,""):!1!==r&&null!=r&&"function"!=typeof r&&"symbol"!=typeof r?e.setAttribute(n,r):e.removeAttribute(n);break;case"cols":case"rows":case"size":case"span":null!=r&&"function"!=typeof r&&"symbol"!=typeof r&&!isNaN(r)&&1<=r?e.setAttribute(n,r):e.removeAttribute(n);break;case"rowSpan":case"start":null==r||"function"==typeof r||"symbol"==typeof r||isNaN(r)?e.removeAttribute(n):e.setAttribute(n,r);break;case"popover":Ku("beforetoggle",e),Ku("toggle",e),st(e,"popover",r);break;case"xlinkActuate":ut(e,"http://www.w3.org/1999/xlink","xlink:actuate",r);break;case"xlinkArcrole":ut(e,"http://www.w3.org/1999/xlink","xlink:arcrole",r);break;case"xlinkRole":ut(e,"http://www.w3.org/1999/xlink","xlink:role",r);break;case"xlinkShow":ut(e,"http://www.w3.org/1999/xlink","xlink:show",r);break;case"xlinkTitle":ut(e,"http://www.w3.org/1999/xlink","xlink:title",r);break;case"xlinkType":ut(e,"http://www.w3.org/1999/xlink","xlink:type",r);break;case"xmlBase":ut(e,"http://www.w3.org/XML/1998/namespace","xml:base",r);break;case"xmlLang":ut(e,"http://www.w3.org/XML/1998/namespace","xml:lang",r);break;case"xmlSpace":ut(e,"http://www.w3.org/XML/1998/namespace","xml:space",r);break;case"is":st(e,"is",r);break;case"innerText":case"textContent":break;default:(!(2<n.length)||"o"!==n[0]&&"O"!==n[0]||"n"!==n[1]&&"N"!==n[1])&&st(e,n=Mt.get(n)||n,r)}}function dd(e,t,n,r,o,i){switch(n){case"style":kt(e,r,i);break;case"dangerouslySetInnerHTML":if(null!=r){if("object"!=typeof r||!("__html"in r))throw Error(a(61));if(null!=(n=r.__html)){if(null!=o.children)throw Error(a(60));e.innerHTML=n}}break;case"children":"string"==typeof r?xt(e,r):("number"==typeof r||"bigint"==typeof r)&&xt(e,""+r);break;case"onScroll":null!=r&&Ku("scroll",e);break;case"onScrollEnd":null!=r&&Ku("scrollend",e);break;case"onClick":null!=r&&(e.onclick=_t);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":case"innerText":case"textContent":break;default:nt.hasOwnProperty(n)||("o"!==n[0]||"n"!==n[1]||(o=n.endsWith("Capture"),t=n.slice(2,o?n.length-7:void 0),"function"==typeof(i=null!=(i=e[$e]||null)?i[n]:null)&&e.removeEventListener(t,i,o),"function"!=typeof r)?n in e?e[n]=r:!0===r?e.setAttribute(n,""):st(e,n,r):("function"!=typeof i&&null!==i&&(n in e?e[n]=null:e.hasAttribute(n)&&e.removeAttribute(n)),e.addEventListener(t,r,o)))}}function fd(e,t,n){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":Ku("error",e),Ku("load",e);var r,o=!1,i=!1;for(r in n)if(n.hasOwnProperty(r)){var l=n[r];if(null!=l)switch(r){case"src":o=!0;break;case"srcSet":i=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(a(137,t));default:ud(e,t,r,l,n,null)}}return i&&ud(e,t,"srcSet",n.srcSet,n,null),void(o&&ud(e,t,"src",n.src,n,null));case"input":Ku("invalid",e);var s=r=l=i=null,c=null,u=null;for(o in n)if(n.hasOwnProperty(o)){var d=n[o];if(null!=d)switch(o){case"name":i=d;break;case"type":l=d;break;case"checked":c=d;break;case"defaultChecked":u=d;break;case"value":r=d;break;case"defaultValue":s=d;break;case"children":case"dangerouslySetInnerHTML":if(null!=d)throw Error(a(137,t));break;default:ud(e,t,o,d,n,null)}}return void vt(e,r,s,c,u,l,i,!1);case"select":for(i in Ku("invalid",e),o=l=r=null,n)if(n.hasOwnProperty(i)&&null!=(s=n[i]))switch(i){case"value":r=s;break;case"defaultValue":l=s;break;case"multiple":o=s;default:ud(e,t,i,s,n,null)}return t=r,n=l,e.multiple=!!o,void(null!=t?wt(e,!!o,t,!1):null!=n&&wt(e,!!o,n,!0));case"textarea":for(l in Ku("invalid",e),r=i=o=null,n)if(n.hasOwnProperty(l)&&null!=(s=n[l]))switch(l){case"value":o=s;break;case"defaultValue":i=s;break;case"children":r=s;break;case"dangerouslySetInnerHTML":if(null!=s)throw Error(a(91));break;default:ud(e,t,l,s,n,null)}return void St(e,o,i,r);case"option":for(c in n)n.hasOwnProperty(c)&&null!=(o=n[c])&&("selected"===c?e.selected=o&&"function"!=typeof o&&"symbol"!=typeof o:ud(e,t,c,o,n,null));return;case"dialog":Ku("beforetoggle",e),Ku("toggle",e),Ku("cancel",e),Ku("close",e);break;case"iframe":case"object":Ku("load",e);break;case"video":case"audio":for(o=0;o<Uu.length;o++)Ku(Uu[o],e);break;case"image":Ku("error",e),Ku("load",e);break;case"details":Ku("toggle",e);break;case"embed":case"source":case"link":Ku("error",e),Ku("load",e);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(u in n)if(n.hasOwnProperty(u)&&null!=(o=n[u]))switch(u){case"children":case"dangerouslySetInnerHTML":throw Error(a(137,t));default:ud(e,t,u,o,n,null)}return;default:if(Rt(t)){for(d in n)n.hasOwnProperty(d)&&void 0!==(o=n[d])&&dd(e,t,d,o,n,void 0);return}}for(s in n)n.hasOwnProperty(s)&&null!=(o=n[s])&&ud(e,t,s,o,n,null)}function pd(e){switch(e){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}var hd=null,gd=null;function md(e){return 9===e.nodeType?e:e.ownerDocument}function Ad(e){switch(e){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function bd(e,t){if(0===e)switch(t){case"svg":return 1;case"math":return 2;default:return 0}return 1===e&&"foreignObject"===t?0:e}function vd(e,t){return"textarea"===e||"noscript"===e||"string"==typeof t.children||"number"==typeof t.children||"bigint"==typeof t.children||"object"==typeof t.dangerouslySetInnerHTML&&null!==t.dangerouslySetInnerHTML&&null!=t.dangerouslySetInnerHTML.__html}var yd=null,wd="function"==typeof setTimeout?setTimeout:void 0,Cd="function"==typeof clearTimeout?clearTimeout:void 0,Sd="function"==typeof Promise?Promise:void 0,xd="function"==typeof queueMicrotask?queueMicrotask:void 0!==Sd?function(e){return Sd.resolve(null).then(e).catch(Ed)}:wd;function Ed(e){setTimeout(function(){throw e})}function Id(e){return"head"===e}function kd(e,t){var n=t,r=0;do{var o=n.nextSibling;if(e.removeChild(n),o&&8===o.nodeType)if("/$"===(n=o.data)||"/&"===n){if(0===r)return e.removeChild(o),void Vf(t);r--}else if("$"===n||"$?"===n||"$~"===n||"$!"===n||"&"===n)r++;else if("html"===n)Fd(e.ownerDocument.documentElement);else if("head"===n){Fd(n=e.ownerDocument.head);for(var i=n.firstChild;i;){var a=i.nextSibling,l=i.nodeName;i[qe]||"SCRIPT"===l||"STYLE"===l||"LINK"===l&&"stylesheet"===i.rel.toLowerCase()||n.removeChild(i),i=a}}else"body"===n&&Fd(e.ownerDocument.body);n=o}while(n);Vf(t)}function Rd(e,t){var n=e;e=0;do{var r=n.nextSibling;if(1===n.nodeType?t?(n._stashedDisplay=n.style.display,n.style.display="none"):(n.style.display=n._stashedDisplay||"",""===n.getAttribute("style")&&n.removeAttribute("style")):3===n.nodeType&&(t?(n._stashedText=n.nodeValue,n.nodeValue=""):n.nodeValue=n._stashedText||""),r&&8===r.nodeType)if("/$"===(n=r.data)){if(0===e)break;e--}else"$"!==n&&"$?"!==n&&"$~"!==n&&"$!"!==n||e++;n=r}while(n)}function Md(e){var t=e.firstChild;for(t&&10===t.nodeType&&(t=t.nextSibling);t;){var n=t;switch(t=t.nextSibling,n.nodeName){case"HTML":case"HEAD":case"BODY":Md(n),Ye(n);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if("stylesheet"===n.rel.toLowerCase())continue}e.removeChild(n)}}function Pd(e,t){for(;8!==e.nodeType;){if((1!==e.nodeType||"INPUT"!==e.nodeName||"hidden"!==e.type)&&!t)return null;if(null===(e=Td(e.nextSibling)))return null}return e}function Bd(e){return"$?"===e.data||"$~"===e.data}function _d(e){return"$!"===e.data||"$?"===e.data&&"loading"!==e.ownerDocument.readyState}function Td(e){for(;null!=e;e=e.nextSibling){var t=e.nodeType;if(1===t||3===t)break;if(8===t){if("$"===(t=e.data)||"$!"===t||"$?"===t||"$~"===t||"&"===t||"F!"===t||"F"===t)break;if("/$"===t||"/&"===t)return null}}return e}var Od=null;function Dd(e){e=e.nextSibling;for(var t=0;e;){if(8===e.nodeType){var n=e.data;if("/$"===n||"/&"===n){if(0===t)return Td(e.nextSibling);t--}else"$"!==n&&"$!"!==n&&"$?"!==n&&"$~"!==n&&"&"!==n||t++}e=e.nextSibling}return null}function Nd(e){e=e.previousSibling;for(var t=0;e;){if(8===e.nodeType){var n=e.data;if("$"===n||"$!"===n||"$?"===n||"$~"===n||"&"===n){if(0===t)return e;t--}else"/$"!==n&&"/&"!==n||t++}e=e.previousSibling}return null}function Ld(e,t,n){switch(t=md(n),e){case"html":if(!(e=t.documentElement))throw Error(a(452));return e;case"head":if(!(e=t.head))throw Error(a(453));return e;case"body":if(!(e=t.body))throw Error(a(454));return e;default:throw Error(a(451))}}function Fd(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);Ye(e)}var Qd=new Map,jd=new Set;function zd(e){return"function"==typeof e.getRootNode?e.getRootNode():9===e.nodeType?e:e.ownerDocument}var $d=D.d;D.d={f:function(){var e=$d.f(),t=Zc();return e||t},r:function(e){var t=Je(e);null!==t&&5===t.tag&&"form"===t.type?rl(t):$d.r(e)},D:function(e){$d.D(e),Gd("dns-prefetch",e,null)},C:function(e,t){$d.C(e,t),Gd("preconnect",e,t)},L:function(e,t,n){$d.L(e,t,n);var r=Hd;if(r&&e&&t){var o='link[rel="preload"][as="'+At(t)+'"]';"image"===t&&n&&n.imageSrcSet?(o+='[imagesrcset="'+At(n.imageSrcSet)+'"]',"string"==typeof n.imageSizes&&(o+='[imagesizes="'+At(n.imageSizes)+'"]')):o+='[href="'+At(e)+'"]';var i=o;switch(t){case"style":i=Wd(e);break;case"script":i=Yd(e)}Qd.has(i)||(e=p({rel:"preload",href:"image"===t&&n&&n.imageSrcSet?void 0:e,as:t},n),Qd.set(i,e),null!==r.querySelector(o)||"style"===t&&r.querySelector(Ud(i))||"script"===t&&r.querySelector(Kd(i))||(fd(t=r.createElement("link"),"link",e),et(t),r.head.appendChild(t)))}},m:function(e,t){$d.m(e,t);var n=Hd;if(n&&e){var r=t&&"string"==typeof t.as?t.as:"script",o='link[rel="modulepreload"][as="'+At(r)+'"][href="'+At(e)+'"]',i=o;switch(r){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":i=Yd(e)}if(!Qd.has(i)&&(e=p({rel:"modulepreload",href:e},t),Qd.set(i,e),null===n.querySelector(o))){switch(r){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(n.querySelector(Kd(i)))return}fd(r=n.createElement("link"),"link",e),et(r),n.head.appendChild(r)}}},X:function(e,t){$d.X(e,t);var n=Hd;if(n&&e){var r=Ze(n).hoistableScripts,o=Yd(e),i=r.get(o);i||((i=n.querySelector(Kd(o)))||(e=p({src:e,async:!0},t),(t=Qd.get(o))&&ef(e,t),et(i=n.createElement("script")),fd(i,"link",e),n.head.appendChild(i)),i={type:"script",instance:i,count:1,state:null},r.set(o,i))}},S:function(e,t,n){$d.S(e,t,n);var r=Hd;if(r&&e){var o=Ze(r).hoistableStyles,i=Wd(e);t=t||"default";var a=o.get(i);if(!a){var l={loading:0,preload:null};if(a=r.querySelector(Ud(i)))l.loading=5;else{e=p({rel:"stylesheet",href:e,"data-precedence":t},n),(n=Qd.get(i))&&Zd(e,n);var s=a=r.createElement("link");et(s),fd(s,"link",e),s._p=new Promise(function(e,t){s.onload=e,s.onerror=t}),s.addEventListener("load",function(){l.loading|=1}),s.addEventListener("error",function(){l.loading|=2}),l.loading|=4,Xd(a,t,r)}a={type:"stylesheet",instance:a,count:1,state:l},o.set(i,a)}}},M:function(e,t){$d.M(e,t);var n=Hd;if(n&&e){var r=Ze(n).hoistableScripts,o=Yd(e),i=r.get(o);i||((i=n.querySelector(Kd(o)))||(e=p({src:e,async:!0,type:"module"},t),(t=Qd.get(o))&&ef(e,t),et(i=n.createElement("script")),fd(i,"link",e),n.head.appendChild(i)),i={type:"script",instance:i,count:1,state:null},r.set(o,i))}}};var Hd="undefined"==typeof document?null:document;function Gd(e,t,n){var r=Hd;if(r&&"string"==typeof t&&t){var o=At(t);o='link[rel="'+e+'"][href="'+o+'"]',"string"==typeof n&&(o+='[crossorigin="'+n+'"]'),jd.has(o)||(jd.add(o),e={rel:e,crossOrigin:n,href:t},null===r.querySelector(o)&&(fd(t=r.createElement("link"),"link",e),et(t),r.head.appendChild(t)))}}function Vd(e,t,n,r){var o,i,l,s,c=(c=W.current)?zd(c):null;if(!c)throw Error(a(446));switch(e){case"meta":case"title":return null;case"style":return"string"==typeof n.precedence&&"string"==typeof n.href?(t=Wd(n.href),(r=(n=Ze(c).hoistableStyles).get(t))||(r={type:"style",instance:null,count:0,state:null},n.set(t,r)),r):{type:"void",instance:null,count:0,state:null};case"link":if("stylesheet"===n.rel&&"string"==typeof n.href&&"string"==typeof n.precedence){e=Wd(n.href);var u=Ze(c).hoistableStyles,d=u.get(e);if(d||(c=c.ownerDocument||c,d={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},u.set(e,d),(u=c.querySelector(Ud(e)))&&!u._p&&(d.instance=u,d.state.loading=5),Qd.has(e)||(n={rel:"preload",as:"style",href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},Qd.set(e,n),u||(o=c,i=e,l=n,s=d.state,o.querySelector('link[rel="preload"][as="style"]['+i+"]")?s.loading=1:(i=o.createElement("link"),s.preload=i,i.addEventListener("load",function(){return s.loading|=1}),i.addEventListener("error",function(){return s.loading|=2}),fd(i,"link",l),et(i),o.head.appendChild(i))))),t&&null===r)throw Error(a(528,""));return d}if(t&&null!==r)throw Error(a(529,""));return null;case"script":return t=n.async,"string"==typeof(n=n.src)&&t&&"function"!=typeof t&&"symbol"!=typeof t?(t=Yd(n),(r=(n=Ze(c).hoistableScripts).get(t))||(r={type:"script",instance:null,count:0,state:null},n.set(t,r)),r):{type:"void",instance:null,count:0,state:null};default:throw Error(a(444,e))}}function Wd(e){return'href="'+At(e)+'"'}function Ud(e){return'link[rel="stylesheet"]['+e+"]"}function qd(e){return p({},e,{"data-precedence":e.precedence,precedence:null})}function Yd(e){return'[src="'+At(e)+'"]'}function Kd(e){return"script[async]"+e}function Jd(e,t,n){if(t.count++,null===t.instance)switch(t.type){case"style":var r=e.querySelector('style[data-href~="'+At(n.href)+'"]');if(r)return t.instance=r,et(r),r;var o=p({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return et(r=(e.ownerDocument||e).createElement("style")),fd(r,"style",o),Xd(r,n.precedence,e),t.instance=r;case"stylesheet":o=Wd(n.href);var i=e.querySelector(Ud(o));if(i)return t.state.loading|=4,t.instance=i,et(i),i;r=qd(n),(o=Qd.get(o))&&Zd(r,o),et(i=(e.ownerDocument||e).createElement("link"));var l=i;return l._p=new Promise(function(e,t){l.onload=e,l.onerror=t}),fd(i,"link",r),t.state.loading|=4,Xd(i,n.precedence,e),t.instance=i;case"script":return i=Yd(n.src),(o=e.querySelector(Kd(i)))?(t.instance=o,et(o),o):(r=n,(o=Qd.get(i))&&ef(r=p({},n),o),et(o=(e=e.ownerDocument||e).createElement("script")),fd(o,"link",r),e.head.appendChild(o),t.instance=o);case"void":return null;default:throw Error(a(443,t.type))}else"stylesheet"===t.type&&!(4&t.state.loading)&&(r=t.instance,t.state.loading|=4,Xd(r,n.precedence,e));return t.instance}function Xd(e,t,n){for(var r=n.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),o=r.length?r[r.length-1]:null,i=o,a=0;a<r.length;a++){var l=r[a];if(l.dataset.precedence===t)i=l;else if(i!==o)break}i?i.parentNode.insertBefore(e,i.nextSibling):(t=9===n.nodeType?n.head:n).insertBefore(e,t.firstChild)}function Zd(e,t){null==e.crossOrigin&&(e.crossOrigin=t.crossOrigin),null==e.referrerPolicy&&(e.referrerPolicy=t.referrerPolicy),null==e.title&&(e.title=t.title)}function ef(e,t){null==e.crossOrigin&&(e.crossOrigin=t.crossOrigin),null==e.referrerPolicy&&(e.referrerPolicy=t.referrerPolicy),null==e.integrity&&(e.integrity=t.integrity)}var tf=null;function nf(e,t,n){if(null===tf){var r=new Map,o=tf=new Map;o.set(n,r)}else(r=(o=tf).get(n))||(r=new Map,o.set(n,r));if(r.has(e))return r;for(r.set(e,null),n=n.getElementsByTagName(e),o=0;o<n.length;o++){var i=n[o];if(!(i[qe]||i[ze]||"link"===e&&"stylesheet"===i.getAttribute("rel"))&&"http://www.w3.org/2000/svg"!==i.namespaceURI){var a=i.getAttribute(t)||"";a=e+a;var l=r.get(a);l?l.push(i):r.set(a,[i])}}return r}function rf(e,t,n){(e=e.ownerDocument||e).head.insertBefore(n,"title"===t?e.querySelector("head > title"):null)}function of(e){return!!("stylesheet"!==e.type||3&e.state.loading)}var af=0;function lf(){if(this.count--,0===this.count&&(0===this.imgCount||!this.waitingForImages))if(this.stylesheets)cf(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}var sf=null;function cf(e,t){e.stylesheets=null,null!==e.unsuspend&&(e.count++,sf=new Map,t.forEach(uf,e),sf=null,lf.call(e))}function uf(e,t){if(!(4&t.state.loading)){var n=sf.get(e);if(n)var r=n.get(null);else{n=new Map,sf.set(e,n);for(var o=e.querySelectorAll("link[data-precedence],style[data-precedence]"),i=0;i<o.length;i++){var a=o[i];"LINK"!==a.nodeName&&"not all"===a.getAttribute("media")||(n.set(a.dataset.precedence,a),r=a)}r&&n.set(null,r)}a=(o=t.instance).getAttribute("data-precedence"),(i=n.get(a)||r)===r&&n.set(null,o),n.set(a,o),this.count++,r=lf.bind(this),o.addEventListener("load",r),o.addEventListener("error",r),i?i.parentNode.insertBefore(o,i.nextSibling):(e=9===e.nodeType?e.head:e).insertBefore(o,e.firstChild),t.state.loading|=4}}var df={$$typeof:w,Provider:null,Consumer:null,_currentValue:N,_currentValue2:N,_threadCount:0};function ff(e,t,n,r,o,i,a,l,s){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Be(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Be(0),this.hiddenUpdates=Be(null),this.identifierPrefix=r,this.onUncaughtError=o,this.onCaughtError=i,this.onRecoverableError=a,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=s,this.incompleteTransitions=new Map}function pf(e,t,n,r,o,i,a,l,s,c,u,d){return e=new ff(e,t,n,a,s,c,u,d,l),t=1,!0===i&&(t|=24),i=Fr(3,null,null,t),e.current=i,i.stateNode=e,(t=jo()).refCount++,e.pooledCache=t,t.refCount++,i.memoizedState={element:r,isDehydrated:n,cache:t},Ai(i),e}function hf(e){return e?e=Nr:Nr}function gf(e,t,n,r,o,i){o=hf(o),null===r.context?r.context=o:r.pendingContext=o,(r=vi(t)).payload={element:n},null!==(i=void 0===i?null:i)&&(r.callback=i),null!==(n=yi(e,r,t))&&(qc(n,0,t),wi(n,e,t))}function mf(e,t){if(null!==(e=e.memoizedState)&&null!==e.dehydrated){var n=e.retryLane;e.retryLane=0!==n&&n<t?n:t}}function Af(e,t){mf(e,t),(e=e.alternate)&&mf(e,t)}function bf(e){if(13===e.tag||31===e.tag){var t=Tr(e,67108864);null!==t&&qc(t,0,67108864),Af(e,67108864)}}function vf(e){if(13===e.tag||31===e.tag){var t=Wc(),n=Tr(e,t=Ne(t));null!==n&&qc(n,0,t),Af(e,t)}}var yf=!0;function wf(e,t,n,r){var o=O.T;O.T=null;var i=D.p;try{D.p=2,Sf(e,t,n,r)}finally{D.p=i,O.T=o}}function Cf(e,t,n,r){var o=O.T;O.T=null;var i=D.p;try{D.p=8,Sf(e,t,n,r)}finally{D.p=i,O.T=o}}function Sf(e,t,n,r){if(yf){var o=xf(r);if(null===o)td(e,t,r,Ef,n),Nf(e,r);else if(function(e,t,n,r,o){switch(t){case"focusin":return Mf=Lf(Mf,e,t,n,r,o),!0;case"dragenter":return Pf=Lf(Pf,e,t,n,r,o),!0;case"mouseover":return Bf=Lf(Bf,e,t,n,r,o),!0;case"pointerover":var i=o.pointerId;return _f.set(i,Lf(_f.get(i)||null,e,t,n,r,o)),!0;case"gotpointercapture":return i=o.pointerId,Tf.set(i,Lf(Tf.get(i)||null,e,t,n,r,o)),!0}return!1}(o,e,t,n,r))r.stopPropagation();else if(Nf(e,r),4&t&&-1<Df.indexOf(e)){for(;null!==o;){var i=Je(o);if(null!==i)switch(i.tag){case 3:if((i=i.stateNode).current.memoizedState.isDehydrated){var a=Ie(i.pendingLanes);if(0!==a){var l=i;for(l.pendingLanes|=2,l.entangledLanes|=2;a;){var s=1<<31-ye(a);l.entanglements[1]|=s,a&=~s}Du(i),!(6&pc)&&(Oc=se()+500,Nu(0,!1))}}break;case 31:case 13:null!==(l=Tr(i,2))&&qc(l,0,2),Zc(),Af(i,2)}if(null===(i=xf(r))&&td(e,t,r,Ef,n),i===o)break;o=i}null!==o&&r.stopPropagation()}else td(e,t,r,null,n)}}function xf(e){return If(e=Ot(e))}var Ef=null;function If(e){if(Ef=null,null!==(e=Ke(e))){var t=s(e);if(null===t)e=null;else{var n=t.tag;if(13===n){if(null!==(e=c(t)))return e;e=null}else if(31===n){if(null!==(e=u(t)))return e;e=null}else if(3===n){if(t.stateNode.current.memoizedState.isDehydrated)return 3===t.tag?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return Ef=e,null}function kf(e){switch(e){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(ce()){case ue:return 2;case de:return 8;case fe:case pe:return 32;case he:return 268435456;default:return 32}default:return 32}}var Rf=!1,Mf=null,Pf=null,Bf=null,_f=new Map,Tf=new Map,Of=[],Df="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");function Nf(e,t){switch(e){case"focusin":case"focusout":Mf=null;break;case"dragenter":case"dragleave":Pf=null;break;case"mouseover":case"mouseout":Bf=null;break;case"pointerover":case"pointerout":_f.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":Tf.delete(t.pointerId)}}function Lf(e,t,n,r,o,i){return null===e||e.nativeEvent!==i?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:i,targetContainers:[o]},null!==t&&null!==(t=Je(t))&&bf(t),e):(e.eventSystemFlags|=r,t=e.targetContainers,null!==o&&-1===t.indexOf(o)&&t.push(o),e)}function Ff(e){var t=Ke(e.target);if(null!==t){var n=s(t);if(null!==n)if(13===(t=n.tag)){if(null!==(t=c(n)))return e.blockedOn=t,void Qe(e.priority,function(){vf(n)})}else if(31===t){if(null!==(t=u(n)))return e.blockedOn=t,void Qe(e.priority,function(){vf(n)})}else if(3===t&&n.stateNode.current.memoizedState.isDehydrated)return void(e.blockedOn=3===n.tag?n.stateNode.containerInfo:null)}e.blockedOn=null}function Qf(e){if(null!==e.blockedOn)return!1;for(var t=e.targetContainers;0<t.length;){var n=xf(e.nativeEvent);if(null!==n)return null!==(t=Je(n))&&bf(t),e.blockedOn=n,!1;var r=new(n=e.nativeEvent).constructor(n.type,n);Tt=r,n.target.dispatchEvent(r),Tt=null,t.shift()}return!0}function jf(e,t,n){Qf(e)&&n.delete(t)}function zf(){Rf=!1,null!==Mf&&Qf(Mf)&&(Mf=null),null!==Pf&&Qf(Pf)&&(Pf=null),null!==Bf&&Qf(Bf)&&(Bf=null),_f.forEach(jf),Tf.forEach(jf)}function $f(e,t){e.blockedOn===t&&(e.blockedOn=null,Rf||(Rf=!0,r.unstable_scheduleCallback(r.unstable_NormalPriority,zf)))}var Hf=null;function Gf(e){Hf!==e&&(Hf=e,r.unstable_scheduleCallback(r.unstable_NormalPriority,function(){Hf===e&&(Hf=null);for(var t=0;t<e.length;t+=3){var n=e[t],r=e[t+1],o=e[t+2];if("function"!=typeof r){if(null===If(r||n))continue;break}var i=Je(n);null!==i&&(e.splice(t,3),t-=3,tl(i,{pending:!0,data:o,method:n.method,action:r},r,o))}}))}function Vf(e){function t(t){return $f(t,e)}null!==Mf&&$f(Mf,e),null!==Pf&&$f(Pf,e),null!==Bf&&$f(Bf,e),_f.forEach(t),Tf.forEach(t);for(var n=0;n<Of.length;n++){var r=Of[n];r.blockedOn===e&&(r.blockedOn=null)}for(;0<Of.length&&null===(n=Of[0]).blockedOn;)Ff(n),null===n.blockedOn&&Of.shift();if(null!=(n=(e.ownerDocument||e).$$reactFormReplay))for(r=0;r<n.length;r+=3){var o=n[r],i=n[r+1],a=o[$e]||null;if("function"==typeof i)a||Gf(n);else if(a){var l=null;if(i&&i.hasAttribute("formAction")){if(o=i,a=i[$e]||null)l=a.formAction;else if(null!==If(o))continue}else l=a.action;"function"==typeof l?n[r+1]=l:(n.splice(r,3),r-=3),Gf(n)}}}function Wf(){function e(e){e.canIntercept&&"react-transition"===e.info&&e.intercept({handler:function(){return new Promise(function(e){return o=e})},focusReset:"manual",scroll:"manual"})}function t(){null!==o&&(o(),o=null),r||setTimeout(n,20)}function n(){if(!r&&!navigation.transition){var e=navigation.currentEntry;e&&null!=e.url&&navigation.navigate(e.url,{state:e.getState(),info:"react-transition",history:"replace"})}}if("object"==typeof navigation){var r=!1,o=null;return navigation.addEventListener("navigate",e),navigation.addEventListener("navigatesuccess",t),navigation.addEventListener("navigateerror",t),setTimeout(n,100),function(){r=!0,navigation.removeEventListener("navigate",e),navigation.removeEventListener("navigatesuccess",t),navigation.removeEventListener("navigateerror",t),null!==o&&(o(),o=null)}}}function Uf(e){this._internalRoot=e}function qf(e){this._internalRoot=e}qf.prototype.render=Uf.prototype.render=function(e){var t=this._internalRoot;if(null===t)throw Error(a(409));gf(t.current,Wc(),e,t,null,null)},qf.prototype.unmount=Uf.prototype.unmount=function(){var e=this._internalRoot;if(null!==e){this._internalRoot=null;var t=e.containerInfo;gf(e.current,2,null,e,null,null),Zc(),t[He]=null}},qf.prototype.unstable_scheduleHydration=function(e){if(e){var t=Fe();e={blockedOn:null,target:e,priority:t};for(var n=0;n<Of.length&&0!==t&&t<Of[n].priority;n++);Of.splice(n,0,e),0===n&&Ff(e)}};var Yf=o.version;if("19.2.7"!==Yf)throw Error(a(527,Yf,"19.2.7"));D.findDOMNode=function(e){var t=e._reactInternals;if(void 0===t){if("function"==typeof e.render)throw Error(a(188));throw e=Object.keys(e).join(","),Error(a(268,e))}return e=function(e){var t=e.alternate;if(!t){if(null===(t=s(e)))throw Error(a(188));return t!==e?null:e}for(var n=e,r=t;;){var o=n.return;if(null===o)break;var i=o.alternate;if(null===i){if(null!==(r=o.return)){n=r;continue}break}if(o.child===i.child){for(i=o.child;i;){if(i===n)return d(o),e;if(i===r)return d(o),t;i=i.sibling}throw Error(a(188))}if(n.return!==r.return)n=o,r=i;else{for(var l=!1,c=o.child;c;){if(c===n){l=!0,n=o,r=i;break}if(c===r){l=!0,r=o,n=i;break}c=c.sibling}if(!l){for(c=i.child;c;){if(c===n){l=!0,n=i,r=o;break}if(c===r){l=!0,r=i,n=o;break}c=c.sibling}if(!l)throw Error(a(189))}}if(n.alternate!==r)throw Error(a(190))}if(3!==n.tag)throw Error(a(188));return n.stateNode.current===n?e:t}(t),null===(e=null!==e?f(e):null)?null:e.stateNode};var Kf={bundleType:0,version:"19.2.7",rendererPackageName:"react-dom",currentDispatcherRef:O,reconcilerVersion:"19.2.7"};if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__){var Jf=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Jf.isDisabled&&Jf.supportsFiber)try{Ae=Jf.inject(Kf),be=Jf}catch(e){}}t.createRoot=function(e,t){if(!l(e))throw Error(a(299));var n=!1,r="",o=xl,i=El,s=Il;return null!=t&&(!0===t.unstable_strictMode&&(n=!0),void 0!==t.identifierPrefix&&(r=t.identifierPrefix),void 0!==t.onUncaughtError&&(o=t.onUncaughtError),void 0!==t.onCaughtError&&(i=t.onCaughtError),void 0!==t.onRecoverableError&&(s=t.onRecoverableError)),t=pf(e,1,!1,null,0,n,r,null,o,i,s,Wf),e[He]=t.current,Zu(e),new Uf(t)},t.hydrateRoot=function(e,t,n){if(!l(e))throw Error(a(299));var r=!1,o="",i=xl,s=El,c=Il,u=null;return null!=n&&(!0===n.unstable_strictMode&&(r=!0),void 0!==n.identifierPrefix&&(o=n.identifierPrefix),void 0!==n.onUncaughtError&&(i=n.onUncaughtError),void 0!==n.onCaughtError&&(s=n.onCaughtError),void 0!==n.onRecoverableError&&(c=n.onRecoverableError),void 0!==n.formState&&(u=n.formState)),(t=pf(e,1,!0,t,0,r,o,u,i,s,c,Wf)).context=hf(null),n=t.current,(o=vi(r=Ne(r=Wc()))).callback=null,yi(n,o,r),n=r,t.current.lanes=n,_e(t,n),Du(t),e[He]=t.current,Zu(e),new qf(t)},t.version="19.2.7"},2826(e,t,n){"use strict";var r=n(405);function o(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n])}return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function i(){}var a={d:{f:i,r:function(){throw Error(o(522))},D:i,C:i,L:i,m:i,X:i,S:i,M:i},p:0,findDOMNode:null},l=Symbol.for("react.portal"),s=r.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function c(e,t){return"font"===e?"":"string"==typeof t?"use-credentials"===t?t:"":void 0}t.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=a,t.createPortal=function(e,t){var n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;if(!t||1!==t.nodeType&&9!==t.nodeType&&11!==t.nodeType)throw Error(o(299));return function(e,t,n){var r=3<arguments.length&&void 0!==arguments[3]?arguments[3]:null;return{$$typeof:l,key:null==r?null:""+r,children:e,containerInfo:t,implementation:n}}(e,t,null,n)},t.flushSync=function(e){var t=s.T,n=a.p;try{if(s.T=null,a.p=2,e)return e()}finally{s.T=t,a.p=n,a.d.f()}},t.preconnect=function(e,t){"string"==typeof e&&(t=t?"string"==typeof(t=t.crossOrigin)?"use-credentials"===t?t:"":void 0:null,a.d.C(e,t))},t.prefetchDNS=function(e){"string"==typeof e&&a.d.D(e)},t.preinit=function(e,t){if("string"==typeof e&&t&&"string"==typeof t.as){var n=t.as,r=c(n,t.crossOrigin),o="string"==typeof t.integrity?t.integrity:void 0,i="string"==typeof t.fetchPriority?t.fetchPriority:void 0;"style"===n?a.d.S(e,"string"==typeof t.precedence?t.precedence:void 0,{crossOrigin:r,integrity:o,fetchPriority:i}):"script"===n&&a.d.X(e,{crossOrigin:r,integrity:o,fetchPriority:i,nonce:"string"==typeof t.nonce?t.nonce:void 0})}},t.preinitModule=function(e,t){if("string"==typeof e)if("object"==typeof t&&null!==t){if(null==t.as||"script"===t.as){var n=c(t.as,t.crossOrigin);a.d.M(e,{crossOrigin:n,integrity:"string"==typeof t.integrity?t.integrity:void 0,nonce:"string"==typeof t.nonce?t.nonce:void 0})}}else null==t&&a.d.M(e)},t.preload=function(e,t){if("string"==typeof e&&"object"==typeof t&&null!==t&&"string"==typeof t.as){var n=t.as,r=c(n,t.crossOrigin);a.d.L(e,n,{crossOrigin:r,integrity:"string"==typeof t.integrity?t.integrity:void 0,nonce:"string"==typeof t.nonce?t.nonce:void 0,type:"string"==typeof t.type?t.type:void 0,fetchPriority:"string"==typeof t.fetchPriority?t.fetchPriority:void 0,referrerPolicy:"string"==typeof t.referrerPolicy?t.referrerPolicy:void 0,imageSrcSet:"string"==typeof t.imageSrcSet?t.imageSrcSet:void 0,imageSizes:"string"==typeof t.imageSizes?t.imageSizes:void 0,media:"string"==typeof t.media?t.media:void 0})}},t.preloadModule=function(e,t){if("string"==typeof e)if(t){var n=c(t.as,t.crossOrigin);a.d.m(e,{as:"string"==typeof t.as&&"script"!==t.as?t.as:void 0,crossOrigin:n,integrity:"string"==typeof t.integrity?t.integrity:void 0})}else a.d.m(e)},t.requestFormReset=function(e){a.d.r(e)},t.unstable_batchedUpdates=function(e,t){return e(t)},t.useFormState=function(e,t,n){return s.H.useFormState(e,t,n)},t.useFormStatus=function(){return s.H.useHostTransitionStatus()},t.version="19.2.7"},7541(e,t,n){"use strict";!function e(){if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(e){console.error(e)}}(),e.exports=n(4482)},7868(e,t,n){"use strict";!function e(){if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(e){console.error(e)}}(),e.exports=n(2826)},5360(e,t){"use strict";var n="function"==typeof Symbol&&Symbol.for,r=n?Symbol.for("react.element"):60103,o=n?Symbol.for("react.portal"):60106,i=n?Symbol.for("react.fragment"):60107,a=n?Symbol.for("react.strict_mode"):60108,l=n?Symbol.for("react.profiler"):60114,s=n?Symbol.for("react.provider"):60109,c=n?Symbol.for("react.context"):60110,u=n?Symbol.for("react.async_mode"):60111,d=n?Symbol.for("react.concurrent_mode"):60111,f=n?Symbol.for("react.forward_ref"):60112,p=n?Symbol.for("react.suspense"):60113,h=n?Symbol.for("react.suspense_list"):60120,g=n?Symbol.for("react.memo"):60115,m=n?Symbol.for("react.lazy"):60116,A=n?Symbol.for("react.block"):60121,b=n?Symbol.for("react.fundamental"):60117,v=n?Symbol.for("react.responder"):60118,y=n?Symbol.for("react.scope"):60119;function w(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case r:switch(e=e.type){case u:case d:case i:case l:case a:case p:return e;default:switch(e=e&&e.$$typeof){case c:case f:case m:case g:case s:return e;default:return t}}case o:return t}}}function C(e){return w(e)===d}t.AsyncMode=u,t.ConcurrentMode=d,t.ContextConsumer=c,t.ContextProvider=s,t.Element=r,t.ForwardRef=f,t.Fragment=i,t.Lazy=m,t.Memo=g,t.Portal=o,t.Profiler=l,t.StrictMode=a,t.Suspense=p,t.isAsyncMode=function(e){return C(e)||w(e)===u},t.isConcurrentMode=C,t.isContextConsumer=function(e){return w(e)===c},t.isContextProvider=function(e){return w(e)===s},t.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===r},t.isForwardRef=function(e){return w(e)===f},t.isFragment=function(e){return w(e)===i},t.isLazy=function(e){return w(e)===m},t.isMemo=function(e){return w(e)===g},t.isPortal=function(e){return w(e)===o},t.isProfiler=function(e){return w(e)===l},t.isStrictMode=function(e){return w(e)===a},t.isSuspense=function(e){return w(e)===p},t.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===i||e===d||e===l||e===a||e===p||e===h||"object"==typeof e&&null!==e&&(e.$$typeof===m||e.$$typeof===g||e.$$typeof===s||e.$$typeof===c||e.$$typeof===f||e.$$typeof===b||e.$$typeof===v||e.$$typeof===y||e.$$typeof===A)},t.typeOf=w},7020(e,t,n){"use strict";e.exports=n(5360)},85(e,t){"use strict";Symbol.for("react.transitional.element"),Symbol.for("react.portal");var n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),i=Symbol.for("react.consumer"),a=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),s=Symbol.for("react.suspense"),c=Symbol.for("react.suspense_list"),u=Symbol.for("react.memo"),d=Symbol.for("react.lazy"),f=(Symbol.for("react.view_transition"),Symbol.for("react.client.reference"));t.Hy=function(e){return"string"==typeof e||"function"==typeof e||e===n||e===o||e===r||e===s||e===c||"object"==typeof e&&null!==e&&(e.$$typeof===d||e.$$typeof===u||e.$$typeof===a||e.$$typeof===i||e.$$typeof===l||e.$$typeof===f||void 0!==e.getModuleId)}},8423(e,t,n){"use strict";n.d(t,{Ay:()=>g});var r=n(4722),o=n(2993),i=n(405),a=n(7868);var l=n(7619),s="unmounted",c="exited",u="entering",d="entered",f="exiting",p=function(e){function t(t,n){var r;r=e.call(this,t,n)||this;var o,i=n&&!n.isMounting?t.enter:t.appear;return r.appearStatus=null,t.in?i?(o=c,r.appearStatus=u):o=d:o=t.unmountOnExit||t.mountOnEnter?s:c,r.state={status:o},r.nextCallback=null,r}(0,o.A)(t,e),t.getDerivedStateFromProps=function(e,t){return e.in&&t.status===s?{status:c}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(e){var t=null;if(e!==this.props){var n=this.state.status;this.props.in?n!==u&&n!==d&&(t=u):n!==u&&n!==d||(t=f)}this.updateStatus(!1,t)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var e,t,n,r=this.props.timeout;return e=t=n=r,null!=r&&"number"!=typeof r&&(e=r.exit,t=r.enter,n=void 0!==r.appear?r.appear:t),{exit:e,enter:t,appear:n}},n.updateStatus=function(e,t){if(void 0===e&&(e=!1),null!==t)if(this.cancelNextCallback(),t===u){if(this.props.unmountOnExit||this.props.mountOnEnter){var n=this.props.nodeRef?this.props.nodeRef.current:a.findDOMNode(this);n&&function(e){e.scrollTop}(n)}this.performEnter(e)}else this.performExit();else this.props.unmountOnExit&&this.state.status===c&&this.setState({status:s})},n.performEnter=function(e){var t=this,n=this.props.enter,r=this.context?this.context.isMounting:e,o=this.props.nodeRef?[r]:[a.findDOMNode(this),r],i=o[0],l=o[1],s=this.getTimeouts(),c=r?s.appear:s.enter;e||n?(this.props.onEnter(i,l),this.safeSetState({status:u},function(){t.props.onEntering(i,l),t.onTransitionEnd(c,function(){t.safeSetState({status:d},function(){t.props.onEntered(i,l)})})})):this.safeSetState({status:d},function(){t.props.onEntered(i)})},n.performExit=function(){var e=this,t=this.props.exit,n=this.getTimeouts(),r=this.props.nodeRef?void 0:a.findDOMNode(this);t?(this.props.onExit(r),this.safeSetState({status:f},function(){e.props.onExiting(r),e.onTransitionEnd(n.exit,function(){e.safeSetState({status:c},function(){e.props.onExited(r)})})})):this.safeSetState({status:c},function(){e.props.onExited(r)})},n.cancelNextCallback=function(){null!==this.nextCallback&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(e,t){t=this.setNextCallback(t),this.setState(e,t)},n.setNextCallback=function(e){var t=this,n=!0;return this.nextCallback=function(r){n&&(n=!1,t.nextCallback=null,e(r))},this.nextCallback.cancel=function(){n=!1},this.nextCallback},n.onTransitionEnd=function(e,t){this.setNextCallback(t);var n=this.props.nodeRef?this.props.nodeRef.current:a.findDOMNode(this),r=null==e&&!this.props.addEndListener;if(n&&!r){if(this.props.addEndListener){var o=this.props.nodeRef?[this.nextCallback]:[n,this.nextCallback],i=o[0],l=o[1];this.props.addEndListener(i,l)}null!=e&&setTimeout(this.nextCallback,e)}else setTimeout(this.nextCallback,0)},n.render=function(){var e=this.state.status;if(e===s)return null;var t=this.props,n=t.children,o=(t.in,t.mountOnEnter,t.unmountOnExit,t.appear,t.enter,t.exit,t.timeout,t.addEndListener,t.onEnter,t.onEntering,t.onEntered,t.onExit,t.onExiting,t.onExited,t.nodeRef,(0,r.A)(t,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]));return i.createElement(l.A.Provider,{value:null},"function"==typeof n?n(e,o):i.cloneElement(i.Children.only(n),o))},t}(i.Component);function h(){}p.contextType=l.A,p.propTypes={},p.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:h,onEntering:h,onEntered:h,onExit:h,onExiting:h,onExited:h},p.UNMOUNTED=s,p.EXITED=c,p.ENTERING=u,p.ENTERED=d,p.EXITING=f;const g=p},7619(e,t,n){"use strict";n.d(t,{A:()=>r});const r=n(405).createContext(null)},8881(e,t){"use strict";var n=Symbol.for("react.transitional.element"),r=Symbol.for("react.fragment");function o(e,t,r){var o=null;if(void 0!==r&&(o=""+r),void 0!==t.key&&(o=""+t.key),"key"in t)for(var i in r={},t)"key"!==i&&(r[i]=t[i]);else r=t;return t=r.ref,{$$typeof:n,type:e,key:o,ref:void 0!==t?t:null,props:r}}t.Fragment=r,t.jsx=o,t.jsxs=o},7866(e,t){"use strict";var n=Symbol.for("react.transitional.element"),r=Symbol.for("react.portal"),o=Symbol.for("react.fragment"),i=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),l=Symbol.for("react.consumer"),s=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),d=Symbol.for("react.memo"),f=Symbol.for("react.lazy"),p=Symbol.for("react.activity"),h=Symbol.iterator,g={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},m=Object.assign,A={};function b(e,t,n){this.props=e,this.context=t,this.refs=A,this.updater=n||g}function v(){}function y(e,t,n){this.props=e,this.context=t,this.refs=A,this.updater=n||g}b.prototype.isReactComponent={},b.prototype.setState=function(e,t){if("object"!=typeof e&&"function"!=typeof e&&null!=e)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")},b.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},v.prototype=b.prototype;var w=y.prototype=new v;w.constructor=y,m(w,b.prototype),w.isPureReactComponent=!0;var C=Array.isArray;function S(){}var x={H:null,A:null,T:null,S:null},E=Object.prototype.hasOwnProperty;function I(e,t,r){var o=r.ref;return{$$typeof:n,type:e,key:t,ref:void 0!==o?o:null,props:r}}function k(e){return"object"==typeof e&&null!==e&&e.$$typeof===n}var R=/\/+/g;function M(e,t){return"object"==typeof e&&null!==e&&null!=e.key?(n=""+e.key,r={"=":"=0",":":"=2"},"$"+n.replace(/[=:]/g,function(e){return r[e]})):t.toString(36);var n,r}function P(e,t,o,i,a){var l=typeof e;"undefined"!==l&&"boolean"!==l||(e=null);var s,c,u=!1;if(null===e)u=!0;else switch(l){case"bigint":case"string":case"number":u=!0;break;case"object":switch(e.$$typeof){case n:case r:u=!0;break;case f:return P((u=e._init)(e._payload),t,o,i,a)}}if(u)return a=a(e),u=""===i?"."+M(e,0):i,C(a)?(o="",null!=u&&(o=u.replace(R,"$&/")+"/"),P(a,t,o,"",function(e){return e})):null!=a&&(k(a)&&(s=a,c=o+(null==a.key||e&&e.key===a.key?"":(""+a.key).replace(R,"$&/")+"/")+u,a=I(s.type,c,s.props)),t.push(a)),1;u=0;var d,p=""===i?".":i+":";if(C(e))for(var g=0;g<e.length;g++)u+=P(i=e[g],t,o,l=p+M(i,g),a);else if("function"==typeof(g=null===(d=e)||"object"!=typeof d?null:"function"==typeof(d=h&&d[h]||d["@@iterator"])?d:null))for(e=g.call(e),g=0;!(i=e.next()).done;)u+=P(i=i.value,t,o,l=p+M(i,g++),a);else if("object"===l){if("function"==typeof e.then)return P(function(e){switch(e.status){case"fulfilled":return e.value;case"rejected":throw e.reason;default:switch("string"==typeof e.status?e.then(S,S):(e.status="pending",e.then(function(t){"pending"===e.status&&(e.status="fulfilled",e.value=t)},function(t){"pending"===e.status&&(e.status="rejected",e.reason=t)})),e.status){case"fulfilled":return e.value;case"rejected":throw e.reason}}throw e}(e),t,o,i,a);throw t=String(e),Error("Objects are not valid as a React child (found: "+("[object Object]"===t?"object with keys {"+Object.keys(e).join(", ")+"}":t)+"). If you meant to render a collection of children, use an array instead.")}return u}function B(e,t,n){if(null==e)return e;var r=[],o=0;return P(e,r,"","",function(e){return t.call(n,e,o++)}),r}function _(e){if(-1===e._status){var t=e._result;(t=t()).then(function(t){0!==e._status&&-1!==e._status||(e._status=1,e._result=t)},function(t){0!==e._status&&-1!==e._status||(e._status=2,e._result=t)}),-1===e._status&&(e._status=0,e._result=t)}if(1===e._status)return e._result.default;throw e._result}var T="function"==typeof reportError?reportError:function(e){if("object"==typeof window&&"function"==typeof window.ErrorEvent){var t=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:"object"==typeof e&&null!==e&&"string"==typeof e.message?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if("object"==typeof process&&"function"==typeof process.emit)return void process.emit("uncaughtException",e);console.error(e)},O={map:B,forEach:function(e,t,n){B(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return B(e,function(){t++}),t},toArray:function(e){return B(e,function(e){return e})||[]},only:function(e){if(!k(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};t.Activity=p,t.Children=O,t.Component=b,t.Fragment=o,t.Profiler=a,t.PureComponent=y,t.StrictMode=i,t.Suspense=u,t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=x,t.__COMPILER_RUNTIME={__proto__:null,c:function(e){return x.H.useMemoCache(e)}},t.cache=function(e){return function(){return e.apply(null,arguments)}},t.cacheSignal=function(){return null},t.cloneElement=function(e,t,n){if(null==e)throw Error("The argument must be a React element, but you passed "+e+".");var r=m({},e.props),o=e.key;if(null!=t)for(i in void 0!==t.key&&(o=""+t.key),t)!E.call(t,i)||"key"===i||"__self"===i||"__source"===i||"ref"===i&&void 0===t.ref||(r[i]=t[i]);var i=arguments.length-2;if(1===i)r.children=n;else if(1<i){for(var a=Array(i),l=0;l<i;l++)a[l]=arguments[l+2];r.children=a}return I(e.type,o,r)},t.createContext=function(e){return(e={$$typeof:s,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null}).Provider=e,e.Consumer={$$typeof:l,_context:e},e},t.createElement=function(e,t,n){var r,o={},i=null;if(null!=t)for(r in void 0!==t.key&&(i=""+t.key),t)E.call(t,r)&&"key"!==r&&"__self"!==r&&"__source"!==r&&(o[r]=t[r]);var a=arguments.length-2;if(1===a)o.children=n;else if(1<a){for(var l=Array(a),s=0;s<a;s++)l[s]=arguments[s+2];o.children=l}if(e&&e.defaultProps)for(r in a=e.defaultProps)void 0===o[r]&&(o[r]=a[r]);return I(e,i,o)},t.createRef=function(){return{current:null}},t.forwardRef=function(e){return{$$typeof:c,render:e}},t.isValidElement=k,t.lazy=function(e){return{$$typeof:f,_payload:{_status:-1,_result:e},_init:_}},t.memo=function(e,t){return{$$typeof:d,type:e,compare:void 0===t?null:t}},t.startTransition=function(e){var t=x.T,n={};x.T=n;try{var r=e(),o=x.S;null!==o&&o(n,r),"object"==typeof r&&null!==r&&"function"==typeof r.then&&r.then(S,T)}catch(e){T(e)}finally{null!==t&&null!==n.types&&(t.types=n.types),x.T=t}},t.unstable_useCacheRefresh=function(){return x.H.useCacheRefresh()},t.use=function(e){return x.H.use(e)},t.useActionState=function(e,t,n){return x.H.useActionState(e,t,n)},t.useCallback=function(e,t){return x.H.useCallback(e,t)},t.useContext=function(e){return x.H.useContext(e)},t.useDebugValue=function(){},t.useDeferredValue=function(e,t){return x.H.useDeferredValue(e,t)},t.useEffect=function(e,t){return x.H.useEffect(e,t)},t.useEffectEvent=function(e){return x.H.useEffectEvent(e)},t.useId=function(){return x.H.useId()},t.useImperativeHandle=function(e,t,n){return x.H.useImperativeHandle(e,t,n)},t.useInsertionEffect=function(e,t){return x.H.useInsertionEffect(e,t)},t.useLayoutEffect=function(e,t){return x.H.useLayoutEffect(e,t)},t.useMemo=function(e,t){return x.H.useMemo(e,t)},t.useOptimistic=function(e,t){return x.H.useOptimistic(e,t)},t.useReducer=function(e,t,n){return x.H.useReducer(e,t,n)},t.useRef=function(e){return x.H.useRef(e)},t.useState=function(e){return x.H.useState(e)},t.useSyncExternalStore=function(e,t,n){return x.H.useSyncExternalStore(e,t,n)},t.useTransition=function(){return x.H.useTransition()},t.version="19.2.7"},405(e,t,n){"use strict";e.exports=n(7866)},9793(e,t,n){"use strict";e.exports=n(8881)},7146(e,t){"use strict";function n(e,t){var n=e.length;e.push(t);e:for(;0<n;){var r=n-1>>>1,o=e[r];if(!(0<i(o,t)))break e;e[r]=t,e[n]=o,n=r}}function r(e){return 0===e.length?null:e[0]}function o(e){if(0===e.length)return null;var t=e[0],n=e.pop();if(n!==t){e[0]=n;e:for(var r=0,o=e.length,a=o>>>1;r<a;){var l=2*(r+1)-1,s=e[l],c=l+1,u=e[c];if(0>i(s,n))c<o&&0>i(u,s)?(e[r]=u,e[c]=n,r=c):(e[r]=s,e[l]=n,r=l);else{if(!(c<o&&0>i(u,n)))break e;e[r]=u,e[c]=n,r=c}}}return t}function i(e,t){var n=e.sortIndex-t.sortIndex;return 0!==n?n:e.id-t.id}if(t.unstable_now=void 0,"object"==typeof performance&&"function"==typeof performance.now){var a=performance;t.unstable_now=function(){return a.now()}}else{var l=Date,s=l.now();t.unstable_now=function(){return l.now()-s}}var c=[],u=[],d=1,f=null,p=3,h=!1,g=!1,m=!1,A=!1,b="function"==typeof setTimeout?setTimeout:null,v="function"==typeof clearTimeout?clearTimeout:null,y="undefined"!=typeof setImmediate?setImmediate:null;function w(e){for(var t=r(u);null!==t;){if(null===t.callback)o(u);else{if(!(t.startTime<=e))break;o(u),t.sortIndex=t.expirationTime,n(c,t)}t=r(u)}}function C(e){if(m=!1,w(e),!g)if(null!==r(c))g=!0,x||(x=!0,S());else{var t=r(u);null!==t&&_(C,t.startTime-e)}}var S,x=!1,E=-1,I=5,k=-1;function R(){return!(!A&&t.unstable_now()-k<I)}function M(){if(A=!1,x){var e=t.unstable_now();k=e;var n=!0;try{e:{g=!1,m&&(m=!1,v(E),E=-1),h=!0;var i=p;try{t:{for(w(e),f=r(c);null!==f&&!(f.expirationTime>e&&R());){var a=f.callback;if("function"==typeof a){f.callback=null,p=f.priorityLevel;var l=a(f.expirationTime<=e);if(e=t.unstable_now(),"function"==typeof l){f.callback=l,w(e),n=!0;break t}f===r(c)&&o(c),w(e)}else o(c);f=r(c)}if(null!==f)n=!0;else{var s=r(u);null!==s&&_(C,s.startTime-e),n=!1}}break e}finally{f=null,p=i,h=!1}n=void 0}}finally{n?S():x=!1}}}if("function"==typeof y)S=function(){y(M)};else if("undefined"!=typeof MessageChannel){var P=new MessageChannel,B=P.port2;P.port1.onmessage=M,S=function(){B.postMessage(null)}}else S=function(){b(M,0)};function _(e,n){E=b(function(){e(t.unstable_now())},n)}t.unstable_IdlePriority=5,t.unstable_ImmediatePriority=1,t.unstable_LowPriority=4,t.unstable_NormalPriority=3,t.unstable_Profiling=null,t.unstable_UserBlockingPriority=2,t.unstable_cancelCallback=function(e){e.callback=null},t.unstable_forceFrameRate=function(e){0>e||125<e?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):I=0<e?Math.floor(1e3/e):5},t.unstable_getCurrentPriorityLevel=function(){return p},t.unstable_next=function(e){switch(p){case 1:case 2:case 3:var t=3;break;default:t=p}var n=p;p=t;try{return e()}finally{p=n}},t.unstable_requestPaint=function(){A=!0},t.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var n=p;p=e;try{return t()}finally{p=n}},t.unstable_scheduleCallback=function(e,o,i){var a=t.unstable_now();switch(i="object"==typeof i&&null!==i&&"number"==typeof(i=i.delay)&&0<i?a+i:a,e){case 1:var l=-1;break;case 2:l=250;break;case 5:l=1073741823;break;case 4:l=1e4;break;default:l=5e3}return e={id:d++,callback:o,priorityLevel:e,startTime:i,expirationTime:l=i+l,sortIndex:-1},i>a?(e.sortIndex=i,n(u,e),null===r(c)&&e===r(u)&&(m?(v(E),E=-1):m=!0,_(C,i-a))):(e.sortIndex=l,n(c,e),g||h||(g=!0,x||(x=!0,S()))),e},t.unstable_shouldYield=R,t.unstable_wrapCallback=function(e){var t=p;return function(){var n=p;p=t;try{return e.apply(this,arguments)}finally{p=n}}}},3480(e,t,n){"use strict";e.exports=n(7146)},4972(e,t,n){var r=n(2738),o=Object.prototype.hasOwnProperty,i="undefined"!=typeof Map;function a(){this._array=[],this._set=i?new Map:Object.create(null)}a.fromArray=function(e,t){for(var n=new a,r=0,o=e.length;r<o;r++)n.add(e[r],t);return n},a.prototype.size=function(){return i?this._set.size:Object.getOwnPropertyNames(this._set).length},a.prototype.add=function(e,t){var n=i?e:r.toSetString(e),a=i?this.has(e):o.call(this._set,n),l=this._array.length;a&&!t||this._array.push(e),a||(i?this._set.set(e,l):this._set[n]=l)},a.prototype.has=function(e){if(i)return this._set.has(e);var t=r.toSetString(e);return o.call(this._set,t)},a.prototype.indexOf=function(e){if(i){var t=this._set.get(e);if(t>=0)return t}else{var n=r.toSetString(e);if(o.call(this._set,n))return this._set[n]}throw new Error('"'+e+'" is not in the set.')},a.prototype.at=function(e){if(e>=0&&e<this._array.length)return this._array[e];throw new Error("No element indexed by "+e)},a.prototype.toArray=function(){return this._array.slice()},t.C=a},5781(e,t,n){var r=n(1549);t.encode=function(e){var t,n="",o=function(e){return e<0?1+(-e<<1):0+(e<<1)}(e);do{t=31&o,(o>>>=5)>0&&(t|=32),n+=r.encode(t)}while(o>0);return n},t.decode=function(e,t,n){var o,i,a,l,s=e.length,c=0,u=0;do{if(t>=s)throw new Error("Expected more digits in base 64 VLQ value.");if(-1===(i=r.decode(e.charCodeAt(t++))))throw new Error("Invalid base64 digit: "+e.charAt(t-1));o=!!(32&i),c+=(i&=31)<<u,u+=5}while(o);n.value=(l=(a=c)>>1,1&~a?l:-l),n.rest=t}},1549(e,t){var n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split("");t.encode=function(e){if(0<=e&&e<n.length)return n[e];throw new TypeError("Must be between 0 and 63: "+e)},t.decode=function(e){return 65<=e&&e<=90?e-65:97<=e&&e<=122?e-97+26:48<=e&&e<=57?e-48+52:43==e?62:47==e?63:-1}},3016(e,t){function n(e,r,o,i,a,l){var s=Math.floor((r-e)/2)+e,c=a(o,i[s],!0);return 0===c?s:c>0?r-s>1?n(s,r,o,i,a,l):l==t.LEAST_UPPER_BOUND?r<i.length?r:-1:s:s-e>1?n(e,s,o,i,a,l):l==t.LEAST_UPPER_BOUND?s:e<0?-1:e}t.GREATEST_LOWER_BOUND=1,t.LEAST_UPPER_BOUND=2,t.search=function(e,r,o,i){if(0===r.length)return-1;var a=n(-1,r.length,e,r,o,i||t.GREATEST_LOWER_BOUND);if(a<0)return-1;for(;a-1>=0&&0===o(r[a],r[a-1],!0);)--a;return a}},3383(e,t,n){var r=n(2738);function o(){this._array=[],this._sorted=!0,this._last={generatedLine:-1,generatedColumn:0}}o.prototype.unsortedForEach=function(e,t){this._array.forEach(e,t)},o.prototype.add=function(e){var t,n,o,i,a,l;n=e,o=(t=this._last).generatedLine,i=n.generatedLine,a=t.generatedColumn,l=n.generatedColumn,i>o||i==o&&l>=a||r.compareByGeneratedPositionsInflated(t,n)<=0?(this._last=e,this._array.push(e)):(this._sorted=!1,this._array.push(e))},o.prototype.toArray=function(){return this._sorted||(this._array.sort(r.compareByGeneratedPositionsInflated),this._sorted=!0),this._array},t.P=o},6360(e,t){function n(e){function t(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}return function e(n,r,o,i){if(o<i){var a=o-1;t(n,(u=o,d=i,Math.round(u+Math.random()*(d-u))),i);for(var l=n[i],s=o;s<i;s++)r(n[s],l,!1)<=0&&t(n,a+=1,s);t(n,a+1,s);var c=a+1;e(n,r,o,c-1),e(n,r,c+1,i)}var u,d}}let r=new WeakMap;t.g=function(e,t,o=0){let i=r.get(t);void 0===i&&(i=function(e){let t=n.toString();return new Function(`return ${t}`)()(e)}(t),r.set(t,i)),i(e,t,o,e.length-1)}},7881(e,t,n){var r=n(2738),o=n(3016),i=n(4972).C,a=n(5781),l=n(6360).g;function s(e,t){var n=e;return"string"==typeof e&&(n=r.parseSourceMapInput(e)),null!=n.sections?new p(n,t):new c(n,t)}function c(e,t){var n=e;"string"==typeof e&&(n=r.parseSourceMapInput(e));var o=r.getArg(n,"version"),a=r.getArg(n,"sources"),l=r.getArg(n,"names",[]),s=r.getArg(n,"sourceRoot",null),c=r.getArg(n,"sourcesContent",null),u=r.getArg(n,"mappings"),d=r.getArg(n,"file",null);if(o!=this._version)throw new Error("Unsupported version: "+o);s&&(s=r.normalize(s)),a=a.map(String).map(r.normalize).map(function(e){return s&&r.isAbsolute(s)&&r.isAbsolute(e)?r.relative(s,e):e}),this._names=i.fromArray(l.map(String),!0),this._sources=i.fromArray(a,!0),this._absoluteSources=this._sources.toArray().map(function(e){return r.computeSourceURL(s,e,t)}),this.sourceRoot=s,this.sourcesContent=c,this._mappings=u,this._sourceMapURL=t,this.file=d}function u(){this.generatedLine=0,this.generatedColumn=0,this.source=null,this.originalLine=null,this.originalColumn=null,this.name=null}s.fromSourceMap=function(e,t){return c.fromSourceMap(e,t)},s.prototype._version=3,s.prototype.__generatedMappings=null,Object.defineProperty(s.prototype,"_generatedMappings",{configurable:!0,enumerable:!0,get:function(){return this.__generatedMappings||this._parseMappings(this._mappings,this.sourceRoot),this.__generatedMappings}}),s.prototype.__originalMappings=null,Object.defineProperty(s.prototype,"_originalMappings",{configurable:!0,enumerable:!0,get:function(){return this.__originalMappings||this._parseMappings(this._mappings,this.sourceRoot),this.__originalMappings}}),s.prototype._charIsMappingSeparator=function(e,t){var n=e.charAt(t);return";"===n||","===n},s.prototype._parseMappings=function(e,t){throw new Error("Subclasses must implement _parseMappings")},s.GENERATED_ORDER=1,s.ORIGINAL_ORDER=2,s.GREATEST_LOWER_BOUND=1,s.LEAST_UPPER_BOUND=2,s.prototype.eachMapping=function(e,t,n){var o,i=t||null;switch(n||s.GENERATED_ORDER){case s.GENERATED_ORDER:o=this._generatedMappings;break;case s.ORIGINAL_ORDER:o=this._originalMappings;break;default:throw new Error("Unknown order of iteration.")}for(var a=this.sourceRoot,l=e.bind(i),c=this._names,u=this._sources,d=this._sourceMapURL,f=0,p=o.length;f<p;f++){var h=o[f],g=null===h.source?null:u.at(h.source);null!==g&&(g=r.computeSourceURL(a,g,d)),l({source:g,generatedLine:h.generatedLine,generatedColumn:h.generatedColumn,originalLine:h.originalLine,originalColumn:h.originalColumn,name:null===h.name?null:c.at(h.name)})}},s.prototype.allGeneratedPositionsFor=function(e){var t=r.getArg(e,"line"),n={source:r.getArg(e,"source"),originalLine:t,originalColumn:r.getArg(e,"column",0)};if(n.source=this._findSourceIndex(n.source),n.source<0)return[];var i=[],a=this._findMapping(n,this._originalMappings,"originalLine","originalColumn",r.compareByOriginalPositions,o.LEAST_UPPER_BOUND);if(a>=0){var l=this._originalMappings[a];if(void 0===e.column)for(var s=l.originalLine;l&&l.originalLine===s;)i.push({line:r.getArg(l,"generatedLine",null),column:r.getArg(l,"generatedColumn",null),lastColumn:r.getArg(l,"lastGeneratedColumn",null)}),l=this._originalMappings[++a];else for(var c=l.originalColumn;l&&l.originalLine===t&&l.originalColumn==c;)i.push({line:r.getArg(l,"generatedLine",null),column:r.getArg(l,"generatedColumn",null),lastColumn:r.getArg(l,"lastGeneratedColumn",null)}),l=this._originalMappings[++a]}return i},t.SourceMapConsumer=s,c.prototype=Object.create(s.prototype),c.prototype.consumer=s,c.prototype._findSourceIndex=function(e){var t,n=e;if(null!=this.sourceRoot&&(n=r.relative(this.sourceRoot,n)),this._sources.has(n))return this._sources.indexOf(n);for(t=0;t<this._absoluteSources.length;++t)if(this._absoluteSources[t]==e)return t;return-1},c.fromSourceMap=function(e,t){var n=Object.create(c.prototype),o=n._names=i.fromArray(e._names.toArray(),!0),a=n._sources=i.fromArray(e._sources.toArray(),!0);n.sourceRoot=e._sourceRoot,n.sourcesContent=e._generateSourcesContent(n._sources.toArray(),n.sourceRoot),n.file=e._file,n._sourceMapURL=t,n._absoluteSources=n._sources.toArray().map(function(e){return r.computeSourceURL(n.sourceRoot,e,t)});for(var s=e._mappings.toArray().slice(),d=n.__generatedMappings=[],f=n.__originalMappings=[],p=0,h=s.length;p<h;p++){var g=s[p],m=new u;m.generatedLine=g.generatedLine,m.generatedColumn=g.generatedColumn,g.source&&(m.source=a.indexOf(g.source),m.originalLine=g.originalLine,m.originalColumn=g.originalColumn,g.name&&(m.name=o.indexOf(g.name)),f.push(m)),d.push(m)}return l(n.__originalMappings,r.compareByOriginalPositions),n},c.prototype._version=3,Object.defineProperty(c.prototype,"sources",{get:function(){return this._absoluteSources.slice()}});const d=r.compareByGeneratedPositionsDeflatedNoLine;function f(e,t){let n=e.length,r=e.length-t;if(!(r<=1))if(2==r){let n=e[t],r=e[t+1];d(n,r)>0&&(e[t]=r,e[t+1]=n)}else if(r<20)for(let r=t;r<n;r++)for(let n=r;n>t;n--){let t=e[n-1],r=e[n];if(d(t,r)<=0)break;e[n-1]=r,e[n]=t}else l(e,d,t)}function p(e,t){var n=e;"string"==typeof e&&(n=r.parseSourceMapInput(e));var o=r.getArg(n,"version"),a=r.getArg(n,"sections");if(o!=this._version)throw new Error("Unsupported version: "+o);this._sources=new i,this._names=new i;var l={line:-1,column:0};this._sections=a.map(function(e){if(e.url)throw new Error("Support for url field in sections not implemented.");var n=r.getArg(e,"offset"),o=r.getArg(n,"line"),i=r.getArg(n,"column");if(o<l.line||o===l.line&&i<l.column)throw new Error("Section offsets must be ordered and non-overlapping.");return l=n,{generatedOffset:{generatedLine:o+1,generatedColumn:i+1},consumer:new s(r.getArg(e,"map"),t)}})}c.prototype._parseMappings=function(e,t){var n,o,i,s,c=1,d=0,p=0,h=0,g=0,m=0,A=e.length,b=0,v={},y=[],w=[];let C=0;for(;b<A;)if(";"===e.charAt(b))c++,b++,d=0,f(w,C),C=w.length;else if(","===e.charAt(b))b++;else{for((n=new u).generatedLine=c,i=b;i<A&&!this._charIsMappingSeparator(e,i);i++);for(e.slice(b,i),o=[];b<i;)a.decode(e,b,v),s=v.value,b=v.rest,o.push(s);if(2===o.length)throw new Error("Found a source, but no line and column");if(3===o.length)throw new Error("Found a source and line, but no column");if(n.generatedColumn=d+o[0],d=n.generatedColumn,o.length>1&&(n.source=g+o[1],g+=o[1],n.originalLine=p+o[2],p=n.originalLine,n.originalLine+=1,n.originalColumn=h+o[3],h=n.originalColumn,o.length>4&&(n.name=m+o[4],m+=o[4])),w.push(n),"number"==typeof n.originalLine){let e=n.source;for(;y.length<=e;)y.push(null);null===y[e]&&(y[e]=[]),y[e].push(n)}}f(w,C),this.__generatedMappings=w;for(var S=0;S<y.length;S++)null!=y[S]&&l(y[S],r.compareByOriginalPositionsNoSource);this.__originalMappings=[].concat(...y)},c.prototype._findMapping=function(e,t,n,r,i,a){if(e[n]<=0)throw new TypeError("Line must be greater than or equal to 1, got "+e[n]);if(e[r]<0)throw new TypeError("Column must be greater than or equal to 0, got "+e[r]);return o.search(e,t,i,a)},c.prototype.computeColumnSpans=function(){for(var e=0;e<this._generatedMappings.length;++e){var t=this._generatedMappings[e];if(e+1<this._generatedMappings.length){var n=this._generatedMappings[e+1];if(t.generatedLine===n.generatedLine){t.lastGeneratedColumn=n.generatedColumn-1;continue}}t.lastGeneratedColumn=1/0}},c.prototype.originalPositionFor=function(e){var t={generatedLine:r.getArg(e,"line"),generatedColumn:r.getArg(e,"column")},n=this._findMapping(t,this._generatedMappings,"generatedLine","generatedColumn",r.compareByGeneratedPositionsDeflated,r.getArg(e,"bias",s.GREATEST_LOWER_BOUND));if(n>=0){var o=this._generatedMappings[n];if(o.generatedLine===t.generatedLine){var i=r.getArg(o,"source",null);null!==i&&(i=this._sources.at(i),i=r.computeSourceURL(this.sourceRoot,i,this._sourceMapURL));var a=r.getArg(o,"name",null);return null!==a&&(a=this._names.at(a)),{source:i,line:r.getArg(o,"originalLine",null),column:r.getArg(o,"originalColumn",null),name:a}}}return{source:null,line:null,column:null,name:null}},c.prototype.hasContentsOfAllSources=function(){return!!this.sourcesContent&&this.sourcesContent.length>=this._sources.size()&&!this.sourcesContent.some(function(e){return null==e})},c.prototype.sourceContentFor=function(e,t){if(!this.sourcesContent)return null;var n=this._findSourceIndex(e);if(n>=0)return this.sourcesContent[n];var o,i=e;if(null!=this.sourceRoot&&(i=r.relative(this.sourceRoot,i)),null!=this.sourceRoot&&(o=r.urlParse(this.sourceRoot))){var a=i.replace(/^file:\/\//,"");if("file"==o.scheme&&this._sources.has(a))return this.sourcesContent[this._sources.indexOf(a)];if((!o.path||"/"==o.path)&&this._sources.has("/"+i))return this.sourcesContent[this._sources.indexOf("/"+i)]}if(t)return null;throw new Error('"'+i+'" is not in the SourceMap.')},c.prototype.generatedPositionFor=function(e){var t=r.getArg(e,"source");if((t=this._findSourceIndex(t))<0)return{line:null,column:null,lastColumn:null};var n={source:t,originalLine:r.getArg(e,"line"),originalColumn:r.getArg(e,"column")},o=this._findMapping(n,this._originalMappings,"originalLine","originalColumn",r.compareByOriginalPositions,r.getArg(e,"bias",s.GREATEST_LOWER_BOUND));if(o>=0){var i=this._originalMappings[o];if(i.source===n.source)return{line:r.getArg(i,"generatedLine",null),column:r.getArg(i,"generatedColumn",null),lastColumn:r.getArg(i,"lastGeneratedColumn",null)}}return{line:null,column:null,lastColumn:null}},p.prototype=Object.create(s.prototype),p.prototype.constructor=s,p.prototype._version=3,Object.defineProperty(p.prototype,"sources",{get:function(){for(var e=[],t=0;t<this._sections.length;t++)for(var n=0;n<this._sections[t].consumer.sources.length;n++)e.push(this._sections[t].consumer.sources[n]);return e}}),p.prototype.originalPositionFor=function(e){var t={generatedLine:r.getArg(e,"line"),generatedColumn:r.getArg(e,"column")},n=o.search(t,this._sections,function(e,t){return e.generatedLine-t.generatedOffset.generatedLine||e.generatedColumn-t.generatedOffset.generatedColumn}),i=this._sections[n];return i?i.consumer.originalPositionFor({line:t.generatedLine-(i.generatedOffset.generatedLine-1),column:t.generatedColumn-(i.generatedOffset.generatedLine===t.generatedLine?i.generatedOffset.generatedColumn-1:0),bias:e.bias}):{source:null,line:null,column:null,name:null}},p.prototype.hasContentsOfAllSources=function(){return this._sections.every(function(e){return e.consumer.hasContentsOfAllSources()})},p.prototype.sourceContentFor=function(e,t){for(var n=0;n<this._sections.length;n++){var r=this._sections[n].consumer.sourceContentFor(e,!0);if(r||""===r)return r}if(t)return null;throw new Error('"'+e+'" is not in the SourceMap.')},p.prototype.generatedPositionFor=function(e){for(var t=0;t<this._sections.length;t++){var n=this._sections[t];if(-1!==n.consumer._findSourceIndex(r.getArg(e,"source"))){var o=n.consumer.generatedPositionFor(e);if(o)return{line:o.line+(n.generatedOffset.generatedLine-1),column:o.column+(n.generatedOffset.generatedLine===o.line?n.generatedOffset.generatedColumn-1:0)}}}return{line:null,column:null}},p.prototype._parseMappings=function(e,t){this.__generatedMappings=[],this.__originalMappings=[];for(var n=0;n<this._sections.length;n++)for(var o=this._sections[n],i=o.consumer._generatedMappings,a=0;a<i.length;a++){var s=i[a],c=o.consumer._sources.at(s.source);null!==c&&(c=r.computeSourceURL(o.consumer.sourceRoot,c,this._sourceMapURL)),this._sources.add(c),c=this._sources.indexOf(c);var u=null;s.name&&(u=o.consumer._names.at(s.name),this._names.add(u),u=this._names.indexOf(u));var d={source:c,generatedLine:s.generatedLine+(o.generatedOffset.generatedLine-1),generatedColumn:s.generatedColumn+(o.generatedOffset.generatedLine===s.generatedLine?o.generatedOffset.generatedColumn-1:0),originalLine:s.originalLine,originalColumn:s.originalColumn,name:u};this.__generatedMappings.push(d),"number"==typeof d.originalLine&&this.__originalMappings.push(d)}l(this.__generatedMappings,r.compareByGeneratedPositionsDeflated),l(this.__originalMappings,r.compareByOriginalPositions)}},9592(e,t,n){var r=n(5781),o=n(2738),i=n(4972).C,a=n(3383).P;function l(e){e||(e={}),this._file=o.getArg(e,"file",null),this._sourceRoot=o.getArg(e,"sourceRoot",null),this._skipValidation=o.getArg(e,"skipValidation",!1),this._ignoreInvalidMapping=o.getArg(e,"ignoreInvalidMapping",!1),this._sources=new i,this._names=new i,this._mappings=new a,this._sourcesContents=null}l.prototype._version=3,l.fromSourceMap=function(e,t){var n=e.sourceRoot,r=new l(Object.assign(t||{},{file:e.file,sourceRoot:n}));return e.eachMapping(function(e){var t={generated:{line:e.generatedLine,column:e.generatedColumn}};null!=e.source&&(t.source=e.source,null!=n&&(t.source=o.relative(n,t.source)),t.original={line:e.originalLine,column:e.originalColumn},null!=e.name&&(t.name=e.name)),r.addMapping(t)}),e.sources.forEach(function(t){var i=t;null!==n&&(i=o.relative(n,t)),r._sources.has(i)||r._sources.add(i);var a=e.sourceContentFor(t);null!=a&&r.setSourceContent(t,a)}),r},l.prototype.addMapping=function(e){var t=o.getArg(e,"generated"),n=o.getArg(e,"original",null),r=o.getArg(e,"source",null),i=o.getArg(e,"name",null);(this._skipValidation||!1!==this._validateMapping(t,n,r,i))&&(null!=r&&(r=String(r),this._sources.has(r)||this._sources.add(r)),null!=i&&(i=String(i),this._names.has(i)||this._names.add(i)),this._mappings.add({generatedLine:t.line,generatedColumn:t.column,originalLine:null!=n&&n.line,originalColumn:null!=n&&n.column,source:r,name:i}))},l.prototype.setSourceContent=function(e,t){var n=e;null!=this._sourceRoot&&(n=o.relative(this._sourceRoot,n)),null!=t?(this._sourcesContents||(this._sourcesContents=Object.create(null)),this._sourcesContents[o.toSetString(n)]=t):this._sourcesContents&&(delete this._sourcesContents[o.toSetString(n)],0===Object.keys(this._sourcesContents).length&&(this._sourcesContents=null))},l.prototype.applySourceMap=function(e,t,n){var r=t;if(null==t){if(null==e.file)throw new Error('SourceMapGenerator.prototype.applySourceMap requires either an explicit source file, or the source map\'s "file" property. Both were omitted.');r=e.file}var a=this._sourceRoot;null!=a&&(r=o.relative(a,r));var l=new i,s=new i;this._mappings.unsortedForEach(function(t){if(t.source===r&&null!=t.originalLine){var i=e.originalPositionFor({line:t.originalLine,column:t.originalColumn});null!=i.source&&(t.source=i.source,null!=n&&(t.source=o.join(n,t.source)),null!=a&&(t.source=o.relative(a,t.source)),t.originalLine=i.line,t.originalColumn=i.column,null!=i.name&&(t.name=i.name))}var c=t.source;null==c||l.has(c)||l.add(c);var u=t.name;null==u||s.has(u)||s.add(u)},this),this._sources=l,this._names=s,e.sources.forEach(function(t){var r=e.sourceContentFor(t);null!=r&&(null!=n&&(t=o.join(n,t)),null!=a&&(t=o.relative(a,t)),this.setSourceContent(t,r))},this)},l.prototype._validateMapping=function(e,t,n,r){if(t&&"number"!=typeof t.line&&"number"!=typeof t.column){var o="original.line and original.column are not numbers -- you probably meant to omit the original mapping entirely and only map the generated position. If so, pass null for the original mapping instead of an object with empty or null values.";if(this._ignoreInvalidMapping)return"undefined"!=typeof console&&console.warn&&console.warn(o),!1;throw new Error(o)}if((!(e&&"line"in e&&"column"in e&&e.line>0&&e.column>=0)||t||n||r)&&!(e&&"line"in e&&"column"in e&&t&&"line"in t&&"column"in t&&e.line>0&&e.column>=0&&t.line>0&&t.column>=0&&n)){if(o="Invalid mapping: "+JSON.stringify({generated:e,source:n,original:t,name:r}),this._ignoreInvalidMapping)return"undefined"!=typeof console&&console.warn&&console.warn(o),!1;throw new Error(o)}},l.prototype._serializeMappings=function(){for(var e,t,n,i,a=0,l=1,s=0,c=0,u=0,d=0,f="",p=this._mappings.toArray(),h=0,g=p.length;h<g;h++){if(e="",(t=p[h]).generatedLine!==l)for(a=0;t.generatedLine!==l;)e+=";",l++;else if(h>0){if(!o.compareByGeneratedPositionsInflated(t,p[h-1]))continue;e+=","}e+=r.encode(t.generatedColumn-a),a=t.generatedColumn,null!=t.source&&(i=this._sources.indexOf(t.source),e+=r.encode(i-d),d=i,e+=r.encode(t.originalLine-1-c),c=t.originalLine-1,e+=r.encode(t.originalColumn-s),s=t.originalColumn,null!=t.name&&(n=this._names.indexOf(t.name),e+=r.encode(n-u),u=n)),f+=e}return f},l.prototype._generateSourcesContent=function(e,t){return e.map(function(e){if(!this._sourcesContents)return null;null!=t&&(e=o.relative(t,e));var n=o.toSetString(e);return Object.prototype.hasOwnProperty.call(this._sourcesContents,n)?this._sourcesContents[n]:null},this)},l.prototype.toJSON=function(){var e={version:this._version,sources:this._sources.toArray(),names:this._names.toArray(),mappings:this._serializeMappings()};return null!=this._file&&(e.file=this._file),null!=this._sourceRoot&&(e.sourceRoot=this._sourceRoot),this._sourcesContents&&(e.sourcesContent=this._generateSourcesContent(e.sources,e.sourceRoot)),e},l.prototype.toString=function(){return JSON.stringify(this.toJSON())},t.x=l},3548(e,t,n){var r=n(9592).x,o=n(2738),i=/(\r?\n)/,a="$$$isSourceNode$$$";function l(e,t,n,r,o){this.children=[],this.sourceContents={},this.line=e??null,this.column=t??null,this.source=n??null,this.name=o??null,this[a]=!0,null!=r&&this.add(r)}l.fromStringWithSourceMap=function(e,t,n){var r=new l,a=e.split(i),s=0,c=function(){return e()+(e()||"");function e(){return s<a.length?a[s++]:void 0}},u=1,d=0,f=null;return t.eachMapping(function(e){if(null!==f){if(!(u<e.generatedLine)){var t=(n=a[s]||"").substr(0,e.generatedColumn-d);return a[s]=n.substr(e.generatedColumn-d),d=e.generatedColumn,p(f,t),void(f=e)}p(f,c()),u++,d=0}for(;u<e.generatedLine;)r.add(c()),u++;if(d<e.generatedColumn){var n=a[s]||"";r.add(n.substr(0,e.generatedColumn)),a[s]=n.substr(e.generatedColumn),d=e.generatedColumn}f=e},this),s<a.length&&(f&&p(f,c()),r.add(a.splice(s).join(""))),t.sources.forEach(function(e){var i=t.sourceContentFor(e);null!=i&&(null!=n&&(e=o.join(n,e)),r.setSourceContent(e,i))}),r;function p(e,t){if(null===e||void 0===e.source)r.add(t);else{var i=n?o.join(n,e.source):e.source;r.add(new l(e.originalLine,e.originalColumn,i,t,e.name))}}},l.prototype.add=function(e){if(Array.isArray(e))e.forEach(function(e){this.add(e)},this);else{if(!e[a]&&"string"!=typeof e)throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+e);e&&this.children.push(e)}return this},l.prototype.prepend=function(e){if(Array.isArray(e))for(var t=e.length-1;t>=0;t--)this.prepend(e[t]);else{if(!e[a]&&"string"!=typeof e)throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+e);this.children.unshift(e)}return this},l.prototype.walk=function(e){for(var t,n=0,r=this.children.length;n<r;n++)(t=this.children[n])[a]?t.walk(e):""!==t&&e(t,{source:this.source,line:this.line,column:this.column,name:this.name})},l.prototype.join=function(e){var t,n,r=this.children.length;if(r>0){for(t=[],n=0;n<r-1;n++)t.push(this.children[n]),t.push(e);t.push(this.children[n]),this.children=t}return this},l.prototype.replaceRight=function(e,t){var n=this.children[this.children.length-1];return n[a]?n.replaceRight(e,t):"string"==typeof n?this.children[this.children.length-1]=n.replace(e,t):this.children.push("".replace(e,t)),this},l.prototype.setSourceContent=function(e,t){this.sourceContents[o.toSetString(e)]=t},l.prototype.walkSourceContents=function(e){for(var t=0,n=this.children.length;t<n;t++)this.children[t][a]&&this.children[t].walkSourceContents(e);var r=Object.keys(this.sourceContents);for(t=0,n=r.length;t<n;t++)e(o.fromSetString(r[t]),this.sourceContents[r[t]])},l.prototype.toString=function(){var e="";return this.walk(function(t){e+=t}),e},l.prototype.toStringWithSourceMap=function(e){var t={code:"",line:1,column:0},n=new r(e),o=!1,i=null,a=null,l=null,s=null;return this.walk(function(e,r){t.code+=e,null!==r.source&&null!==r.line&&null!==r.column?(i===r.source&&a===r.line&&l===r.column&&s===r.name||n.addMapping({source:r.source,original:{line:r.line,column:r.column},generated:{line:t.line,column:t.column},name:r.name}),i=r.source,a=r.line,l=r.column,s=r.name,o=!0):o&&(n.addMapping({generated:{line:t.line,column:t.column}}),i=null,o=!1);for(var c=0,u=e.length;c<u;c++)10===e.charCodeAt(c)?(t.line++,t.column=0,c+1===u?(i=null,o=!1):o&&n.addMapping({source:r.source,original:{line:r.line,column:r.column},generated:{line:t.line,column:t.column},name:r.name})):t.column++}),this.walkSourceContents(function(e,t){n.setSourceContent(e,t)}),{code:t.code,map:n}}},2738(e,t){t.getArg=function(e,t,n){if(t in e)return e[t];if(3===arguments.length)return n;throw new Error('"'+t+'" is a required argument.')};var n=/^(?:([\w+\-.]+):)?\/\/(?:(\w+:\w+)@)?([\w.-]*)(?::(\d+))?(.*)$/,r=/^data:.+\,.+$/;function o(e){var t=e.match(n);return t?{scheme:t[1],auth:t[2],host:t[3],port:t[4],path:t[5]}:null}function i(e){var t="";return e.scheme&&(t+=e.scheme+":"),t+="//",e.auth&&(t+=e.auth+"@"),e.host&&(t+=e.host),e.port&&(t+=":"+e.port),e.path&&(t+=e.path),t}t.urlParse=o,t.urlGenerate=i;var a,l,s=(a=function(e){var n=e,r=o(e);if(r){if(!r.path)return e;n=r.path}for(var a=t.isAbsolute(n),l=[],s=0,c=0;;){if(s=c,-1===(c=n.indexOf("/",s))){l.push(n.slice(s));break}for(l.push(n.slice(s,c));c<n.length&&"/"===n[c];)c++}var u,d=0;for(c=l.length-1;c>=0;c--)"."===(u=l[c])?l.splice(c,1):".."===u?d++:d>0&&(""===u?(l.splice(c+1,d),d=0):(l.splice(c,2),d--));return""===(n=l.join("/"))&&(n=a?"/":"."),r?(r.path=n,i(r)):n},l=[],function(e){for(var t=0;t<l.length;t++)if(l[t].input===e){var n=l[0];return l[0]=l[t],l[t]=n,l[0].result}var r=a(e);return l.unshift({input:e,result:r}),l.length>32&&l.pop(),r});function c(e,t){""===e&&(e="."),""===t&&(t=".");var n=o(t),a=o(e);if(a&&(e=a.path||"/"),n&&!n.scheme)return a&&(n.scheme=a.scheme),i(n);if(n||t.match(r))return t;if(a&&!a.host&&!a.path)return a.host=t,i(a);var l="/"===t.charAt(0)?t:s(e.replace(/\/+$/,"")+"/"+t);return a?(a.path=l,i(a)):l}t.normalize=s,t.join=c,t.isAbsolute=function(e){return"/"===e.charAt(0)||n.test(e)},t.relative=function(e,t){""===e&&(e="."),e=e.replace(/\/$/,"");for(var n=0;0!==t.indexOf(e+"/");){var r=e.lastIndexOf("/");if(r<0)return t;if((e=e.slice(0,r)).match(/^([^\/]+:\/)?\/*$/))return t;++n}return Array(n+1).join("../")+t.substr(e.length+1)};var u=!("__proto__"in Object.create(null));function d(e){return e}function f(e){if(!e)return!1;var t=e.length;if(t<9)return!1;if(95!==e.charCodeAt(t-1)||95!==e.charCodeAt(t-2)||111!==e.charCodeAt(t-3)||116!==e.charCodeAt(t-4)||111!==e.charCodeAt(t-5)||114!==e.charCodeAt(t-6)||112!==e.charCodeAt(t-7)||95!==e.charCodeAt(t-8)||95!==e.charCodeAt(t-9))return!1;for(var n=t-10;n>=0;n--)if(36!==e.charCodeAt(n))return!1;return!0}function p(e,t){return e===t?0:null===e?1:null===t?-1:e>t?1:-1}t.toSetString=u?d:function(e){return f(e)?"$"+e:e},t.fromSetString=u?d:function(e){return f(e)?e.slice(1):e},t.compareByOriginalPositions=function(e,t,n){var r=p(e.source,t.source);return 0!==r||0!==(r=e.originalLine-t.originalLine)||0!==(r=e.originalColumn-t.originalColumn)||n||0!==(r=e.generatedColumn-t.generatedColumn)||0!==(r=e.generatedLine-t.generatedLine)?r:p(e.name,t.name)},t.compareByOriginalPositionsNoSource=function(e,t,n){var r;return 0!==(r=e.originalLine-t.originalLine)||0!==(r=e.originalColumn-t.originalColumn)||n||0!==(r=e.generatedColumn-t.generatedColumn)||0!==(r=e.generatedLine-t.generatedLine)?r:p(e.name,t.name)},t.compareByGeneratedPositionsDeflated=function(e,t,n){var r=e.generatedLine-t.generatedLine;return 0!==r||0!==(r=e.generatedColumn-t.generatedColumn)||n||0!==(r=p(e.source,t.source))||0!==(r=e.originalLine-t.originalLine)||0!==(r=e.originalColumn-t.originalColumn)?r:p(e.name,t.name)},t.compareByGeneratedPositionsDeflatedNoLine=function(e,t,n){var r=e.generatedColumn-t.generatedColumn;return 0!==r||n||0!==(r=p(e.source,t.source))||0!==(r=e.originalLine-t.originalLine)||0!==(r=e.originalColumn-t.originalColumn)?r:p(e.name,t.name)},t.compareByGeneratedPositionsInflated=function(e,t){var n=e.generatedLine-t.generatedLine;return 0!==n||0!==(n=e.generatedColumn-t.generatedColumn)||0!==(n=p(e.source,t.source))||0!==(n=e.originalLine-t.originalLine)||0!==(n=e.originalColumn-t.originalColumn)?n:p(e.name,t.name)},t.parseSourceMapInput=function(e){return JSON.parse(e.replace(/^\)]}'[^\n]*\n/,""))},t.computeSourceURL=function(e,t,n){if(t=t||"",e&&("/"!==e[e.length-1]&&"/"!==t[0]&&(e+="/"),t=e+t),n){var r=o(n);if(!r)throw new Error("sourceMapURL could not be parsed");if(r.path){var a=r.path.lastIndexOf("/");a>=0&&(r.path=r.path.substring(0,a+1))}t=c(i(r),t)}return s(t)}},9736(e,t,n){n(9592).x,t.SourceMapConsumer=n(7881).SourceMapConsumer,n(3548)},9687(e){e.exports=function(){var e=document.getSelection();if(!e.rangeCount)return function(){};for(var t=document.activeElement,n=[],r=0;r<e.rangeCount;r++)n.push(e.getRangeAt(r));switch(t.tagName.toUpperCase()){case"INPUT":case"TEXTAREA":t.blur();break;default:t=null}return e.removeAllRanges(),function(){"Caret"===e.type&&e.removeAllRanges(),e.rangeCount||n.forEach(function(t){e.addRange(t)}),t&&t.focus()}}},8998(e,t,n){"use strict";n.d(t,{n9:()=>D});var r=n(5835),o=n(405);const i=Object.fromEntries?Object.fromEntries:e=>{if(!e||!e[Symbol.iterator])throw new Error("Object.fromEntries() requires a single iterable argument");const t={};return Object.keys(e).forEach(n=>{const[r,o]=e[n];t[r]=o}),t};function a(e){return Object.keys(e)}function l(e,t){if(!e)throw new Error(t)}function s(e,t){return t}const c=e=>{const t=e.length;let n=0,r="";for(;n<t;n++){const t=e[n];if(null==t)continue;let o;switch(typeof t){case"boolean":break;case"object":if(Array.isArray(t))o=c(t);else{l(!s(0,!1)),o="";for(const e in t)t[e]&&e&&(o&&(o+=" "),o+=e)}break;default:o=t}o&&(r&&(r+=" "),r+=o)}return r};var u=n(2855),d=n(966);const{createCssAndCx:f}={createCssAndCx:function(e){const{cache:t}=e,n=(...e)=>{const n=(0,u.J)(e,t.registered);(0,d.sk)(t,n,!1);const r=`${t.key}-${n.name}`;{const n=e[0];(function(e){return e instanceof Object&&!("styles"in e)&&!("length"in e)&&!("__emotion_styles"in e)})(n)&&h.saveClassNameCSSObjectMapping(t,r,n)}return r};return{css:n,cx:(...e)=>{const r=c(e),o=h.fixClassName(t,r,n);return function(e,t,n){const r=[],o=(0,d.Rk)(e,r,n);return r.length<2?n:o+t(r)}(t.registered,n,o)}}}};function p(e){const{useCache:t}=e;return{useCssAndCx:function(){const e=t(),{css:n,cx:r}=function(t,n){var r;const i=(0,o.useRef)();return(!i.current||n.length!==(null===(r=i.current.prevDeps)||void 0===r?void 0:r.length)||i.current.prevDeps.map((e,t)=>e===n[t]).indexOf(!1)>=0)&&(i.current={v:f({cache:e}),prevDeps:[...n]}),i.current.v}(0,[e]);return{css:n,cx:r}}}}const h=(()=>{const e=new WeakMap;return{saveClassNameCSSObjectMapping:(t,n,r)=>{let o=e.get(t);void 0===o&&(o=new Map,e.set(t,o)),o.set(n,r)},fixClassName:(t,n,r)=>{const o=e.get(t);return c(function(e){let t=!1;return e.map(([e,n])=>{if(void 0===n)return e;let r;if(t)r={"&&":n};else{r=e;for(const e in n)if(e.startsWith("@media")){t=!0;break}}return r})}(n.split(" ").map(e=>[e,null==o?void 0:o.get(e)])).map(e=>"string"==typeof e?e:r(e)))}}})();function g(e){if(!(e instanceof Object)||"function"==typeof e)return e;const t=[];for(const n in e){const r=e[n],o=typeof r;if("string"!==o&&("number"!==o||isNaN(r))&&"boolean"!==o&&null!=r)return e;t.push(`${n}:${o}_${r}`)}return"xSqLiJdLMd9s"+t.join("|")}function m(e,t,n){if(!(t instanceof Object))return e;const r={};return a(e).forEach(o=>r[o]=n(e[o],t[o])),a(t).forEach(n=>{if(n in e)return;const o=t[n];"string"==typeof o&&(r[n]=o)}),r}const A=({classes:e,theme:t,muiStyleOverridesParams:n,css:r,cx:i,name:a})=>{var l,s;if("makeStyle no name"!==a){if(void 0!==n&&void 0===a)throw new Error("To use muiStyleOverridesParams, you must specify a name using .withName('MyComponent')")}else a=void 0;let c;try{c=void 0===a?void 0:(null===(s=null===(l=t.components)||void 0===l?void 0:l[a])||void 0===s?void 0:s.styleOverrides)||void 0}catch(e){}const u=(0,o.useMemo)(()=>{if(void 0===c)return;const e={};for(const o in c){const i=c[o];i instanceof Object&&(e[o]=r("function"==typeof i?i({theme:t,ownerState:null==n?void 0:n.ownerState,...null==n?void 0:n.props}):i))}return e},[c,g(null==n?void 0:n.props),g(null==n?void 0:n.ownerState),r]);return{classes:e=(0,o.useMemo)(()=>m(e,u,i),[e,u,i])}},b=n(1733)._;let v=0;function y(e){const{useTheme:t,cache:n}=e,{useCache:r}=C({cacheProvidedAtInception:n}),{useCssAndCx:c}=p({useCache:r});return{makeStyles:function(e){const{name:n,uniqId:u=""+v++}=null!=e?e:{},d="object"!=typeof n?n:Object.keys(n)[0];return function(e){const n="function"==typeof e?e:()=>e;return function(e,f){const p=t();let{css:h,cx:b}=c();const v=r();let y=(0,o.useMemo)(()=>{const t={},r="undefined"!=typeof Proxy&&new Proxy({},{get:(e,n)=>("symbol"==typeof n&&l(!1),t[n]=`${v.key}-${u}${void 0!==d?`-${d}`:""}-${n}-ref`)}),o=n(p,e,r||{}),c=i(a(o).map(e=>{const n=o[e];return n.label||(n.label=`${void 0!==d?`${d}-`:""}${e}`),[e,`${h(n)}${s(0,e in t)?` ${t[e]}`:""}`]}));return a(t).forEach(e=>{e in c||(c[e]=t[e])}),c},[v,h,b,p,g(e)]);{const e=null==f?void 0:f.props.classes;y=(0,o.useMemo)(()=>m(y,e,b),[y,g(e),b])}{const e=A({classes:y,css:h,cx:b,name:null!=d?d:"makeStyle no name",idOfUseStyles:u,muiStyleOverridesParams:f,theme:p});void 0!==e.classes&&(y=e.classes),void 0!==e.css&&(h=e.css),void 0!==e.cx&&(b=e.cx)}return{classes:y,theme:p,css:h,cx:b}}}},useStyles:function(){const e=t(),{css:n,cx:r}=c();return{theme:e,css:n,cx:r}}}}const w=(0,o.createContext)(void 0),{createUseCache:C}={createUseCache:function(e){const{cacheProvidedAtInception:t}=e;return{useCache:function(){var e;const n=b(),r=(0,o.useContext)(w),i=null!==(e=null!=t?t:r)&&void 0!==e?e:n;if(null===i)throw new Error(["In order to get SSR working with tss-react you need to explicitly provide an Emotion cache.","MUI users be aware: This is not an error strictly related to tss-react, with or without tss-react,","MUI needs an Emotion cache to be provided for SSR to work.","Here is the MUI documentation related to SSR setup: https://mui.com/material-ui/guides/server-rendering/","TSS provides helper that makes the process of setting up SSR easier: https://docs.tss-react.dev/ssr"].join("\n"));return i}}}};function S(e){return e.charAt(0).toUpperCase()+e.slice(1)}const x=new WeakMap,E="getClasses should only be used in conjunction with withStyles";function I(e){const t=e.classes;if(void 0===t)throw new Error(E);const n=x.get(t);if(void 0===n)throw new Error(E);return n}function k(e){const t={},n={};return Object.keys(e).forEach(r=>(r.startsWith("@media")?n:t)[r]=e[r]),Object.keys(n).forEach(e=>{const r=n[e];Object.keys(r).forEach(n=>{var o;return t[n]={...null!==(o=t[n])&&void 0!==o?o:{},[e]:r[n]}})}),t}const R=(()=>{const e="object"==typeof document&&"function"==typeof(null===document||void 0===document?void 0:document.getElementById),t="undefined"!=typeof jest,n="undefined"!=typeof mocha,r="undefined"!=typeof __vitest_worker__;return!(e||t||n||r)})();function M(e){P=0,B.splice(0,B.length);const{useContext:t,usePlugin:n,cache:r}=e,{useCache:o}=C({cacheProvidedAtInception:r}),{useCssAndCx:i}=p({useCache:o});return{tss:_({useContext:t,useCache:o,useCssAndCx:i,usePlugin:null!=n?n:({classes:e,cx:t,css:n})=>({classes:e,cx:t,css:n}),name:void 0,doesUseNestedSelectors:!1})}}let P=0;const B=[];function _(e){const{useContext:t,useCache:n,useCssAndCx:r,usePlugin:o,name:c,doesUseNestedSelectors:u}=e;return{withParams:()=>_({...e}),withName:t=>_({...e,name:"object"!=typeof t?t:Object.keys(t)[0]}),withNestedSelectors:()=>_({...e,doesUseNestedSelectors:!0}),create:e=>{const d="x"+P++;if(void 0!==c)for(;;){const e=B.find(e=>e.name===c);if(void 0===e)break;B.splice(B.indexOf(e),1)}const f="function"==typeof e?e:()=>e;return function(p){var h,A,b;const{classesOverrides:v,...y}=null!=p?p:{},w=t(),{css:C,cx:S}=r(),x=n(),E=function(e){const{cache:t,cssObjectByRuleNameOrGetCssObjectByRuleName:n,classesOverridesRef:r,paramsAndPluginParamsRef:o,idOfUseStyles:i,context:s,getClasses:c}=e;e:{const e=T.get(t);if(void 0===e)break e;const l=e.get(n);if(void 0===l)break e;const c=l.get(r);if(void 0===c)break e;const u=c.get(o);if(void 0===u)break e;const d=u.find(({context:e})=>{if(e===s)return!0;if(a(e).length!==a(s).length)return!1;for(const t in e)if(g(e[t])!==g(s[t]))return!1;return!0});if(void 0!==d){if((null==d?void 0:d.idOfUseStyles)===i)return d.result;u.splice(u.indexOf(d),1)}}const u=c();{T.has(t)||T.set(t,new WeakMap);const e=T.get(t);l(void 0!==e),e.has(n)||e.set(n,new Map);const a=e.get(n);l(void 0!==a),a.has(r)||(a.size>200&&a.clear(),a.set(r,new Map));const c=a.get(r);if(l(void 0!==c),!c.has(o)){{const e="string"==typeof o?257:5;c.size<e||c.clear()}c.set(o,[])}let d=c.get(o);l(void 0!==d),d.length>5&&(d=[]),d.push({idOfUseStyles:i,context:s,result:u})}return u}({cache:x,cssObjectByRuleNameOrGetCssObjectByRuleName:e,classesOverridesRef:g(v),paramsAndPluginParamsRef:g(y),idOfUseStyles:d,context:w,getClasses:()=>{const e={},t=f({...p,...w,...u?{classes:"undefined"==typeof Proxy?{}:new Proxy({},{get:(t,n)=>{if("symbol"==typeof n&&l(!1),R&&void 0===c)throw new Error(["tss-react: In SSR setups, in order to use nested selectors, you must also give a unique name to the useStyle function.",'Solution: Use tss.withName("ComponentName").withNestedSelectors<...>()... to set a name.'].join("\n"));e:{if(void 0===c)break e;let e=B.find(e=>e.name===c&&e.idOfUseStyles===d);void 0===e&&(e={name:c,idOfUseStyles:d,nestedSelectorRuleNames:new Set},B.push(e)),e.nestedSelectorRuleNames.add(n)}if(void 0!==c&&void 0!==B.find(e=>e.name===c&&e.idOfUseStyles!==d&&e.nestedSelectorRuleNames.has(n)))throw new Error([`tss-react: There are in your codebase two different useStyles named "${c}" that`,`both use use the nested selector ${n}.\n`,"This may lead to CSS class name collisions, causing nested selectors to target elements outside of the intended scope.\n","Solution: Ensure each useStyles using nested selectors has a unique name.\n",'Use: tss.withName("UniqueName").withNestedSelectors<...>()...'].join(" "));return e[n]=`${x.key}-${void 0!==c?c:d}-${n}-ref`}})}:{}});let n=i(a(t).map(n=>{const r=t[n];return r.label||(r.label=`${void 0!==c?`${c}-`:""}${n}`),[n,`${C(r)}${s(0,n in e)?` ${e[n]}`:""}`]}));return a(e).forEach(t=>{t in n||(n[t]=e[t])}),n=m(n,v,S),n}}),I=o({classes:E,css:C,cx:S,idOfUseStyles:d,name:c,...w,...y});return{classes:null!==(h=I.classes)&&void 0!==h?h:E,css:null!==(A=I.css)&&void 0!==A?A:C,cx:null!==(b=I.cx)&&void 0!==b?b:S,...w}}}}}const T=new WeakMap,{tss:O}=M({useContext:()=>({})}),{makeStyles:D,withStyles:N}=(O.create({}),{...y(L={useTheme:r.A}),...function(e){const{useTheme:t,cache:n}=e,{makeStyles:r}=y({useTheme:t,cache:n});function i(e,t,n){const i="string"==typeof e?(()=>{const t=e,n=function({children:e,...n}){return(0,o.createElement)(t,n,e)};return Object.defineProperty(n,"name",{value:S(t)}),n})():e,a=(()=>{{const{name:e}=null!=n?n:{};if(void 0!==e)return"object"!=typeof e?e:Object.keys(e)[0]}let e;{const t=i.displayName;"string"==typeof t&&""!==t&&(e=t)}e:{if(void 0!==e)break e;const t=i.name;"string"==typeof t&&""!==t&&(e=t)}if(void 0!==e)return e=e.replace(/\$/g,"usd"),e=e.replace(/\(/g,"_").replace(/\)/g,"_"),e=e.replace(/[^a-zA-Z0-9-_]/g,"_"),e})(),l=r({...n,name:a})("function"==typeof t?(e,n,r)=>k(t(e,n,r)):k(t));function s(e){for(const t in e)if("root"!==t)return!0;return!1}const c=(0,o.forwardRef)(function(t,n){const{className:r,classes:a,...c}=t,{classes:u,cx:d}=l(t,{props:t}),f=d(u.root,r);return x.set(u,{...u,root:f}),o.createElement(i,{ref:n,className:s(u)?r:f,..."string"==typeof e?{}:{classes:u},...c})});return void 0!==a&&(c.displayName=`${S(a)}WithStyles`,Object.defineProperty(c,"name",{value:c.displayName})),c}return i.getClasses=I,{withStyles:i}}(L)});var L;const{tss:F}=M({useContext:function(){return{theme:(0,r.A)()}},usePlugin:A});F.create({})},3529(e,t,n){"use strict";var r=n(405),o="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},i=r.useState,a=r.useEffect,l=r.useLayoutEffect,s=r.useDebugValue;function c(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!o(e,n)}catch(e){return!0}}var u="undefined"==typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t){return t()}:function(e,t){var n=t(),r=i({inst:{value:n,getSnapshot:t}}),o=r[0].inst,u=r[1];return l(function(){o.value=n,o.getSnapshot=t,c(o)&&u({inst:o})},[e,n,t]),a(function(){return c(o)&&u({inst:o}),e(function(){c(o)&&u({inst:o})})},[e]),s(n),n};t.useSyncExternalStore=void 0!==r.useSyncExternalStore?r.useSyncExternalStore:u},1142(e,t,n){"use strict";var r=n(405),o=n(524),i="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},a=o.useSyncExternalStore,l=r.useRef,s=r.useEffect,c=r.useMemo,u=r.useDebugValue;t.useSyncExternalStoreWithSelector=function(e,t,n,r,o){var d=l(null);if(null===d.current){var f={hasValue:!1,value:null};d.current=f}else f=d.current;d=c(function(){function e(e){if(!s){if(s=!0,a=e,e=r(e),void 0!==o&&f.hasValue){var t=f.value;if(o(t,e))return l=t}return l=e}if(t=l,i(a,e))return t;var n=r(e);return void 0!==o&&o(t,n)?(a=e,t):(a=e,l=n)}var a,l,s=!1,c=void 0===n?null:n;return[function(){return e(t())},null===c?void 0:function(){return e(c())}]},[t,n,r,o]);var p=a(e,d[0],d[1]);return s(function(){f.hasValue=!0,f.value=p},[p]),u(p),p}},524(e,t,n){"use strict";e.exports=n(3529)},9966(e,t,n){"use strict";e.exports=n(1142)},4347(e,t,n){"use strict";function r(){return r=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},r.apply(null,arguments)}n.d(t,{A:()=>r})},2993(e,t,n){"use strict";function r(e,t){return r=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},r(e,t)}function o(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,r(e,t)}n.d(t,{A:()=>o})},4722(e,t,n){"use strict";function r(e,t){if(null==e)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(-1!==t.indexOf(r))continue;n[r]=e[r]}return n}n.d(t,{A:()=>r})},7434(e,t,n){"use strict";n.d(t,{A:()=>hv});var r=n(9793),o=n(405),i=n(4417),a=n(654),l=n(6081),s=n(4045);const c=(0,s.n)()(e=>({fieldValue:{wordBreak:"break-word",maxHeight:300,fontSize:12,padding:e.spacing(.5),overflow:"auto"}}));function u({value:e}){const{classes:t}=c(),n=/^https?:\/\//.exec(`${e}`);return(0,r.jsx)("div",{className:t.fieldValue,children:(0,o.isValidElement)(e)?e:n?(0,r.jsx)(i.A,{href:`${e}`,children:`${e}`}):(0,r.jsx)(a.A,{html:(0,l.Gvm)(e)?JSON.stringify(e):String(e)})})}var d=n(2351),f=n(7615);const p=(0,s.n)()(e=>({fieldDescription:{"&:hover":{background:"dark"===e.palette.mode?"#e65100":"yellow"}},fieldName:{wordBreak:"break-all",minWidth:90,borderBottom:"1px solid #0003",fontSize:12,background:e.palette.action.disabledBackground,marginRight:e.spacing(1),padding:e.spacing(.5)}}));function h({description:e,name:t,width:n,prefix:o=[]}){const{classes:i}=p(),a=[...o,t].join(".");return e?(0,r.jsx)(d.A,{title:e,placement:"left",children:(0,r.jsx)("div",{className:(0,f.cx)(i.fieldDescription,i.fieldName),children:a})}):(0,r.jsx)("div",{className:i.fieldName,style:{width:n},children:a})}const g=(0,s.n)()(e=>({field:{display:"flex",flexWrap:"wrap"},fieldSubvalue:{wordBreak:"break-word",maxHeight:300,padding:e.spacing(.5),border:`1px solid ${e.palette.action.selected}`,boxSizing:"border-box",overflow:"auto"}}));function m({name:e,value:t,description:n,formatter:i,prefix:a=[]}){const{classes:s}=g(),[c,d]=(0,o.useState)(!1),f=t.length>100,p=f&&!c?t.slice(0,100):t;return 1===t.length?(0,l.Gvm)(t[0])?(0,r.jsx)(hv,{formatter:i,attributes:t[0],prefix:[...a,e]}):(0,r.jsxs)("div",{className:s.field,children:[(0,r.jsx)(h,{prefix:a,description:n,name:e}),(0,r.jsx)(u,{value:i?i(t[0],e):t[0]})]}):t.every(e=>(0,l.Gvm)(e))?(0,r.jsx)(r.Fragment,{children:t.map((t,n)=>(0,r.jsx)(hv,{formatter:i,attributes:t,prefix:[...a,`${e}-${n}`]},`${JSON.stringify(t)}-${n}`))}):(0,r.jsxs)("div",{className:s.field,children:[(0,r.jsx)(h,{prefix:a,description:n,name:e}),p.map((t,n)=>(0,r.jsx)("div",{className:s.fieldSubvalue,children:(0,r.jsx)(u,{value:i?i(t,e):t})},`${JSON.stringify(t)}-${n}`)),f?(0,r.jsx)("button",{type:"button",onClick:()=>{d(e=>!e)},children:c?"Show less":`Showing 100 of ${t.length}. Show all...`}):null]})}var A=n(6807),b=n(548),v=n(4871),y=n(4347),w=n(5821);const C=parseInt(o.version,10),S=e=>{if(C>=19){const t=t=>e(t,t.ref??null);return t.displayName=e.displayName??e.name,t}return o.forwardRef(e)};var x=n(4722),E=n(851),I=n(4573),k=n(9225),R=n(941);const M=Object.is;function P(e,t){if(e===t)return!0;if(!(e instanceof Object&&t instanceof Object))return!1;let n=0,r=0;for(const r in e){if(n+=1,!M(e[r],t[r]))return!1;if(!(r in t))return!1}for(const e in t)r+=1;return n===r}function B(e){return o.memo(e,P)}var _=n(912),T=n(643),O=n(8783);function D(e){return(0,T.Ay)("MuiDataGrid",e)}const N={root:["autoHeight","autosizing","root--densityStandard","root--densityComfortable","root--densityCompact","root--disableUserSelection","root--noToolbar","withVerticalBorder"],children:["actionsCell","booleanCell","cell","cell--editable","cell--editing","cell--flex","cell--pinnedLeft","cell--pinnedRight","cell--rangeBottom","cell--rangeLeft","cell--rangeRight","cell--rangeTop","cell--selectionMode","cell--textCenter","cell--textLeft","cell--textRight","cell--withLeftBorder","cell--withRightBorder","cellCheckbox","cellEmpty","cellOffsetLeft","cellSkeleton","checkboxInput","columnHeader","columnHeader--alignCenter","columnHeader--alignLeft","columnHeader--alignRight","columnHeader--dragging","columnHeader--emptyGroup","columnHeader--filledGroup","columnHeader--filtered","columnHeader--last","columnHeader--moving","columnHeader--numeric","columnHeader--pinnedLeft","columnHeader--pinnedRight","columnHeader--siblingFocused","columnHeader--sortable","columnHeader--sorted","columnHeader--withLeftBorder","columnHeader--withRightBorder","columnHeaderCheckbox","columnHeaderDraggableContainer","columnHeaderTitleContainer","columnHeaderTitleContainerContent","columnSeparator","columnSeparator--resizable","columnSeparator--resizing","columnSeparator--sideLeft","columnSeparator--sideRight","container--bottom","container--top","detailPanelToggleCell","detailPanelToggleCell--expanded","editBooleanCell","filterIcon","filler--borderBottom","filler--pinnedLeft","filler--pinnedRight","groupingCriteriaCell","groupingCriteriaCellLoadingContainer","groupingCriteriaCellToggle","headerFilterRow","iconSeparator","menuIcon","menuIconButton","menuList","menuOpen","overlayWrapperInner","pinnedRows","pinnedRows--bottom","pinnedRows--top","row","row--borderBottom","row--detailPanelExpanded","row--dragging","row--dynamicHeight","row--editable","row--editing","row--firstVisible","row--lastVisible","rowReorderCell","rowReorderCell--draggable","rowReorderCellContainer","rowReorderCellPlaceholder","rowSkeleton","scrollbar","scrollbar--horizontal","scrollbar--vertical","scrollbarFiller","scrollbarFiller--pinnedRight","sortIcon","treeDataGroupingCell","treeDataGroupingCellLoadingContainer","treeDataGroupingCellToggle","withBorderColor","row--beingDragged"]},L=(0,O.A)("MuiDataGrid",[...N.root,...N.children,"aiAssistantPanel","aiAssistantPanelHeader","aiAssistantPanelTitleContainer","aiAssistantPanelTitle","aiAssistantPanelBody","aiAssistantPanelEmptyText","aiAssistantPanelFooter","aiAssistantPanelConversation","aiAssistantPanelConversationList","aiAssistantPanelConversationTitle","aiAssistantPanelSuggestions","aiAssistantPanelSuggestionsList","aiAssistantPanelSuggestionsItem","aiAssistantPanelSuggestionsLabel","aggregationColumnHeader","aggregationColumnHeader--alignLeft","aggregationColumnHeader--alignCenter","aggregationColumnHeader--alignRight","aggregationColumnHeaderLabel","aggregationRowOverlayWrapper","mainContent","withSidePanel","collapsible","collapsibleTrigger","collapsibleIcon","collapsiblePanel","columnHeader--filter","columnHeaderFilterInput","columnHeaderFilterOperatorLabel","columnHeaderTitle","columnHeaders","columnsManagement","columnsManagementRow","columnsManagementHeader","columnsManagementSearchInput","columnsManagementFooter","columnsManagementScrollArea","columnsManagementEmptyText","detailPanel","footerCell","panel","panelHeader","panelWrapper","panelContent","panelFooter","paper","editInputCell","longTextCell","longTextCellContent","longTextCellExpandButton","longTextCellCollapseButton","longTextCellPopup","longTextCellPopperContent","editLongTextCell","editLongTextCellValue","editLongTextCellPopup","editLongTextCellPopperContent","editLongTextCellTextarea","filler","filterForm","filterFormDeleteIcon","filterFormLogicOperatorInput","filterFormColumnInput","filterFormOperatorInput","filterFormValueInput","footerContainer","iconButtonContainer","main","main--hasPinnedRight","main--hiddenContent","menu","overlay","overlayWrapper","root","rowCount","rowReorderIcon","scrollArea--left","scrollArea--right","scrollArea--up","scrollArea--down","scrollArea","scrollShadow","scrollShadow--vertical","scrollShadow--horizontal","selectedRowCount","sortButton","shadowScrollArea","sidebar","sidebarHeader","toolbarContainer","toolbar","toolbarLabel","toolbarDivider","toolbarFilterList","toolbarQuickFilter","toolbarQuickFilterTrigger","toolbarQuickFilterControl","virtualScroller","virtualScroller--hasScrollX","virtualScrollerContent","virtualScrollerContent--overflowed","virtualScrollerRenderZone","pivotPanelAvailableFields","pivotPanelField","pivotPanelField--sorted","pivotPanelFieldActionContainer","pivotPanelFieldCheckbox","pivotPanelFieldDragIcon","pivotPanelFieldList","pivotPanelFieldName","pivotPanelHeader","pivotPanelPlaceholder","pivotPanelScrollArea","pivotPanelSearchContainer","pivotPanelSection","pivotPanelSectionTitle","pivotPanelSections","pivotPanelSwitch","pivotPanelSwitchLabel","prompt","promptContent","promptText","promptFeedback","promptChangeList","promptChangesToggle","promptChangesToggleIcon","promptIcon","promptIconContainer","promptError","promptAction","resizablePanelHandle","resizablePanelHandle--horizontal","resizablePanelHandle--vertical"]),F={values:{xs:0,sm:600,md:900,lg:1200,xl:1536},up:e=>{const t=F.values;return`@media (min-width:${"number"==typeof t[e]?t[e]:e}px)`}},Q={spacingUnit:"--DataGrid-t-spacing-unit",colors:{border:{base:"--DataGrid-t-color-border-base"},foreground:{base:"--DataGrid-t-color-foreground-base",muted:"--DataGrid-t-color-foreground-muted",accent:"--DataGrid-t-color-foreground-accent",disabled:"--DataGrid-t-color-foreground-disabled",error:"--DataGrid-t-color-foreground-error"},background:{base:"--DataGrid-t-color-background-base",overlay:"--DataGrid-t-color-background-overlay",backdrop:"--DataGrid-t-color-background-backdrop"},interactive:{hover:"--DataGrid-t-color-interactive-hover",hoverOpacity:"--DataGrid-t-color-interactive-hover-opacity",focus:"--DataGrid-t-color-interactive-focus",focusOpacity:"--DataGrid-t-color-interactive-focus-opacity",disabled:"--DataGrid-t-color-interactive-disabled",disabledOpacity:"--DataGrid-t-color-interactive-disabled-opacity",selected:"--DataGrid-t-color-interactive-selected",selectedOpacity:"--DataGrid-t-color-interactive-selected-opacity"}},header:{background:{base:"--DataGrid-t-header-background-base"}},cell:{background:{pinned:"--DataGrid-t-cell-background-pinned"}},radius:{base:"--DataGrid-t-radius-base"},typography:{font:{body:"--DataGrid-t-typography-font-body",small:"--DataGrid-t-typography-font-small",large:"--DataGrid-t-typography-font-large"},fontFamily:{base:"--DataGrid-t-typography-font-family-base"},fontWeight:{light:"--DataGrid-t-typography-font-weight-light",regular:"--DataGrid-t-typography-font-weight-regular",medium:"--DataGrid-t-typography-font-weight-medium",bold:"--DataGrid-t-typography-font-weight-bold"}},transitions:{easing:{easeIn:"--DataGrid-t-transition-easing-ease-in",easeOut:"--DataGrid-t-transition-easing-ease-out",easeInOut:"--DataGrid-t-transition-easing-ease-in-out"},duration:{short:"--DataGrid-t-transition-duration-short",base:"--DataGrid-t-transition-duration-base",long:"--DataGrid-t-transition-duration-long"}},shadows:{base:"--DataGrid-t-shadow-base",overlay:"--DataGrid-t-shadow-overlay"},zIndex:{panel:"--DataGrid-t-z-index-panel",menu:"--DataGrid-t-z-index-menu"}},j=function e(t){if("string"==typeof t)return`var(${t})`;const n={};for(const r in t)Object.hasOwn(t,r)&&(n[r]=e(t[r]));return n}(Q),z=(0,y.A)({breakpoints:F,spacing:function(e,t,n,r){return void 0===e?$(1):void 0===t?$(e):void 0===n?$(e)+" "+$(t):void 0===r?$(e)+" "+$(t)+" "+$(n):$(e)+" "+$(t)+" "+$(n)+" "+$(r)},transition:function(e,t){const{duration:n=z.transitions.duration.base,easing:r=z.transitions.easing.easeInOut,delay:o=0}=t??{};return e.map(e=>`${e} ${n} ${r} ${o}ms`).join(", ")},keys:Q},j);function $(e){return 0===e?"0":`calc(var(--DataGrid-t-spacing-unit) * ${e})`}new Set;var H=n(524),G=n(985);const V=Object.is,W=P,U=(e,t)=>e===t||e.length===t.length&&e.every((e,n)=>e===t[n]),q=()=>({state:null,equals:null,selector:null,args:void 0}),Y=[],K=()=>null;function J(e,t,n=void 0,r=V){e.current.state;const i=(0,G.A)(q),a=null!==i.current.selector,[l,s]=o.useState(a?null:t(e,n));i.current.state=l,i.current.equals=r,i.current.selector=t;const c=i.current.args;if(i.current.args=n,a&&!((e,t)=>{let n=Object.is;return t instanceof Array?n=U:t instanceof Object&&(n=W),n(e,t)})(c,n)){const t=i.current.selector(e,i.current.args);i.current.equals(i.current.state,t)||(i.current.state=t,s(t))}const u=o.useCallback(()=>(i.current.subscription||(i.current.subscription=e.current.store.subscribe(()=>{const t=i.current.selector(e,i.current.args);i.current.equals(i.current.state,t)||(i.current.state=t,s(t))})),null),Y),d=o.useCallback(()=>(i.current.subscription||u(),()=>{i.current.subscription&&(i.current.subscription(),i.current.subscription=void 0)}),Y);return(0,H.useSyncExternalStore)(d,u,K),l}const X=o.createContext(void 0);function Z(){const e=o.useContext(X);if(void 0===e)throw new Error(["MUI X: Could not find the Data Grid private context.","It looks like you rendered your component outside of a DataGrid, DataGridPro or DataGridPremium parent component.","This can also happen if you are bundling multiple versions of the Data Grid."].join("\n"));return e}const ee={width:3,rx:1.5,x:10.5},te=e=>e.current.state.dimensions.isReady?e.current.state.dimensions.hasScrollX&&(!e.current.state.dimensions.hasScrollY||0===e.current.state.dimensions.scrollbarSize):0===e.current.state.dimensions.scrollbarSize,ne=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"Root",overridesResolver:(e,t)=>{const n=[t.root];return N.root.forEach(e=>{n.push({[`&.${L[e]}`]:t[e]})}),N.children.forEach(e=>{n.push({[`& .${L[e]}`]:t[e]})}),n}})(()=>{const e=J(Z(),te),t=z.colors.background.base,n=z.header.background.base,r=z.cell.background.pinned,o=re(z.colors.interactive.hover,1),i=z.colors.interactive.hoverOpacity,a=z.colors.interactive.selected,l=z.colors.interactive.selectedOpacity,s=a,c=`calc(${l} + ${i})`,u={hover:z.colors.interactive.hover,selected:a,selectedHover:a},d=ae(t,o,i,u.hover),f=ae(t,a,l,u.selected),p=ae(t,s,c,u.selectedHover),h=ae(r,o,i,u.hover),g=ae(r,a,l,u.selected),m=ae(r,s,c,u.selectedHover),A=e=>({[`& .${L["cell--pinnedLeft"]}, & .${L["cell--pinnedRight"]}`]:{backgroundColor:e,"&.Mui-selected":{backgroundColor:ae(e,f,l,u.selected),"&:hover":{backgroundColor:ae(e,p,c,u.selectedHover)}}}}),b=A(h),v=A(g),y=A(m),w={backgroundColor:f,"&:hover":{backgroundColor:p,"@media (hover: none)":{backgroundColor:f}}};return{"--unstable_DataGrid-radius":z.radius.base,"--unstable_DataGrid-headWeight":z.typography.fontWeight.medium,"--DataGrid-rowBorderColor":z.colors.border.base,"--DataGrid-cellOffsetMultiplier":2,"--DataGrid-width":"0px","--DataGrid-hasScrollX":"0","--DataGrid-hasScrollY":"0","--DataGrid-scrollbarSize":"10px","--DataGrid-rowWidth":"0px","--DataGrid-columnsTotalWidth":"0px","--DataGrid-leftPinnedWidth":"0px","--DataGrid-rightPinnedWidth":"0px","--DataGrid-headerHeight":"0px","--DataGrid-headersTotalHeight":"0px","--DataGrid-topContainerHeight":"0px","--DataGrid-bottomContainerHeight":"0px",flex:1,boxSizing:"border-box",position:"relative",borderWidth:"1px",borderStyle:"solid",borderColor:z.colors.border.base,borderRadius:"var(--unstable_DataGrid-radius)",backgroundColor:z.colors.background.base,color:z.colors.foreground.base,font:z.typography.font.body,outline:"none",height:"100%",display:"flex",minWidth:0,minHeight:0,flexDirection:"column",overflow:"hidden",overflowAnchor:"none",transform:"translate(0, 0)",[`.${L.main} > *:first-child/* emotion-disable-server-rendering-unsafe-selector-warning-please-do-not-use-this-the-warning-exists-for-a-reason */`]:{borderTopLeftRadius:"var(--unstable_DataGrid-radius)",borderTopRightRadius:"var(--unstable_DataGrid-radius)"},[`&.${L.autoHeight}`]:{height:"auto"},[`&.${L.autosizing}`]:{[`& .${L.columnHeaderTitleContainerContent} > *`]:{overflow:"visible !important"},"@media (hover: hover)":{[`& .${L.menuIcon}`]:{width:"0 !important",visibility:"hidden !important"}},[`& .${L.cell}`]:{overflow:"visible !important",whiteSpace:"nowrap",minWidth:"max-content !important",maxWidth:"max-content !important"},[`& .${L.groupingCriteriaCell}`]:{width:"unset"},[`& .${L.treeDataGroupingCell}`]:{width:"unset"},[`& .${L["columnHeader--filter"]}`]:{flex:"none !important",width:"unset !important"}},[`&.${L.withSidePanel}`]:{flexDirection:"row"},[`& .${L.mainContent}`]:{display:"flex",flexDirection:"column",overflow:"hidden",flex:1},[`& .${L.columnHeader}, & .${L.cell}`]:{WebkitTapHighlightColor:"transparent",padding:"0 10px",boxSizing:"border-box"},[`& .${L.columnHeader}:focus-within, & .${L.cell}:focus-within`]:{outline:`solid ${re(z.colors.interactive.focus,.5)} 1px`,outlineOffset:-1},[`& .${L.columnHeader}:focus, & .${L.cell}:focus`]:{outline:`solid ${z.colors.interactive.focus} 1px`,outlineOffset:-1},[`& .${L.columnHeader}:focus,\n & .${L["columnHeader--withLeftBorder"]},\n & .${L["columnHeader--withRightBorder"]},\n & .${L["columnHeader--siblingFocused"]}\n `]:{[`& .${L.columnSeparator}`]:{opacity:0},"@media (hover: none)":{[`& .${L["columnSeparator--resizable"]}`]:{opacity:1}},[`& .${L["columnSeparator--resizable"]}:hover`]:{opacity:1}},[`&.${L["root--noToolbar"]} [aria-rowindex="1"] [aria-colindex="1"]`]:{borderTopLeftRadius:"calc(var(--unstable_DataGrid-radius) - 1px)"},[`&.${L["root--noToolbar"]} [aria-rowindex="1"] .${L["columnHeader--last"]}`]:{borderTopRightRadius:e?"calc(var(--unstable_DataGrid-radius) - 1px)":void 0},[`& .${L.columnHeaderCheckbox}, & .${L.cellCheckbox}`]:{padding:0,justifyContent:"center",alignItems:"center"},[`& .${L.columnHeader}`]:{position:"relative",display:"flex",alignItems:"center",backgroundColor:n},[`& .${L.columnHeader} .${L.sortButton}`]:{backgroundColor:z.header.background.base},[`& .${L["columnHeader--filter"]}`]:{paddingTop:8,paddingBottom:8,paddingRight:5,minHeight:"min-content",overflow:"hidden"},[`&.${L["root--densityCompact"]} .${L["columnHeader--filter"]}`]:{paddingTop:4,paddingBottom:4},[`& .${L["virtualScroller--hasScrollX"]} .${L["columnHeader--last"]}`]:{overflow:"hidden"},[`& .${L["pivotPanelField--sorted"]} .${L.iconButtonContainer},\n & .${L["columnHeader--sorted"]} .${L.iconButtonContainer},\n & .${L["columnHeader--filtered"]} .${L.iconButtonContainer}`]:{visibility:"visible",width:"auto"},[`& .${L.pivotPanelField}:not(.${L["pivotPanelField--sorted"]}) .${L.sortButton},\n & .${L.columnHeader}:not(.${L["columnHeader--sorted"]}) .${L.sortButton}`]:{opacity:0,transition:z.transition(["opacity"],{duration:z.transitions.duration.short})},[`& .${L.columnHeaderTitleContainer}`]:{display:"flex",alignItems:"center",gap:z.spacing(.25),minWidth:0,flex:1,whiteSpace:"nowrap",overflow:"hidden"},[`& .${L.columnHeaderTitleContainerContent}`]:{overflow:"hidden",display:"flex",alignItems:"center"},[`& .${L["columnHeader--filledGroup"]} .${L.columnHeaderTitleContainer}`]:{borderBottomWidth:"1px",borderBottomStyle:"solid",boxSizing:"border-box"},[`& .${L.sortIcon}, & .${L.filterIcon}`]:{fontSize:"inherit"},[`& .${L["columnHeader--sortable"]}`]:{cursor:"pointer"},[`& .${L["columnHeader--alignCenter"]} .${L.columnHeaderTitleContainer}`]:{justifyContent:"center"},[`& .${L["columnHeader--alignRight"]} .${L.columnHeaderDraggableContainer}, & .${L["columnHeader--alignRight"]} .${L.columnHeaderTitleContainer}`]:{flexDirection:"row-reverse"},[`& .${L["columnHeader--alignCenter"]} .${L.menuIcon}`]:{marginLeft:"auto"},[`& .${L["columnHeader--alignRight"]} .${L.menuIcon}`]:{marginRight:"auto",marginLeft:-5},[`& .${L["columnHeader--moving"]}`]:{backgroundColor:d},[`& .${L["columnHeader--pinnedLeft"]}, & .${L["columnHeader--pinnedRight"]}`]:{position:"sticky",zIndex:40,background:z.header.background.base},[`& .${L.columnSeparator}`]:{position:"absolute",overflow:"hidden",zIndex:30,display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",maxWidth:10,color:z.colors.border.base},[`& .${L.columnHeaders}`]:{width:"var(--DataGrid-rowWidth)",backgroundColor:n},"@media (hover: hover)":{[`& .${L.columnHeader}:hover`]:{[`& .${L.menuIcon}`]:{width:"auto",visibility:"visible"},[`& .${L.iconButtonContainer}`]:{visibility:"visible",width:"auto"}},[`& .${L.columnHeader}:not(.${L["columnHeader--sorted"]}):hover .${L.sortButton},\n & .${L.pivotPanelField}:not(.${L["pivotPanelField--sorted"]}):hover .${L.sortButton},\n & .${L.pivotPanelField}:not(.${L["pivotPanelField--sorted"]}) .${L.sortButton}:focus-visible`]:{opacity:1},[`& .${L.columnHeader}:not(.${L["columnHeader--sorted"]}):hover .${L.sortButton} > *,\n & .${L.pivotPanelField}:not(.${L["pivotPanelField--sorted"]}):hover .${L.sortButton} > *,\n & .${L.pivotPanelField}:not(.${L["pivotPanelField--sorted"]}) .${L.sortButton}:focus-visible > *`]:{opacity:.78},[`& .${L.pivotPanelFieldActionContainer} button:hover`]:{backgroundColor:z.colors.background.base}},"@media (hover: none)":{[`& .${L.columnHeader} .${L.menuIcon}`]:{width:"auto",visibility:"visible"},[`& .${L.columnHeader}:focus,\n & .${L["columnHeader--siblingFocused"]}`]:{[`.${L["columnSeparator--resizable"]}`]:{color:z.colors.foreground.accent}},[`& .${L.pivotPanelField}:not(.${L["pivotPanelField--sorted"]}) .${L.sortButton}`]:{opacity:.78}},[`& .${L["columnHeader--withLeftBorder"]} .${L["columnSeparator--sideLeft"]}:not(.${L["columnSeparator--resizable"]}), & .${L["columnHeader--withRightBorder"]} .${L["columnSeparator--sideRight"]}:not(.${L["columnSeparator--resizable"]})`]:{display:"none"},[`& .${L["columnSeparator--sideLeft"]}`]:{left:-5},[`& .${L["columnSeparator--sideRight"]}`]:{right:-5},[`& .${L["columnHeader--withRightBorder"]} .${L["columnSeparator--sideLeft"]}`]:{left:-5.5},[`& .${L["columnHeader--withRightBorder"]} .${L["columnSeparator--sideRight"]}`]:{right:-5.5},[`& .${L["columnSeparator--resizable"]}`]:{cursor:"col-resize",touchAction:"none",[`&.${L["columnSeparator--resizing"]}`]:{color:z.colors.foreground.accent},"@media (hover: none)":{[`& .${L.iconSeparator} rect`]:ee},"@media (hover: hover)":{"&:hover":{color:z.colors.foreground.accent,[`& .${L.iconSeparator} rect`]:ee}},"& svg":{pointerEvents:"none"}},[`& .${L.iconSeparator}`]:{color:"inherit",transition:z.transition(["color","width"],{duration:z.transitions.duration.short})},[`& .${L.menuIcon}`]:{width:0,visibility:"hidden",fontSize:20,marginRight:-5,display:"flex",alignItems:"center"},[`.${L.menuOpen}`]:{visibility:"visible",width:"auto"},[`& .${L.headerFilterRow}`]:{[`& .${L.columnHeader}, & .${L.scrollbarFiller}`]:{boxSizing:"border-box",borderBottom:"1px solid var(--DataGrid-rowBorderColor)"}},[`& .${L["row--borderBottom"]} .${L.columnHeader},\n & .${L["row--borderBottom"]} .${L.filler},\n & .${L["row--borderBottom"]} .${L.scrollbarFiller}`]:{borderBottom:"1px solid var(--DataGrid-rowBorderColor)"},[`& .${L["row--borderBottom"]} .${L.cell}`]:{borderBottom:"1px solid var(--rowBorderColor)"},[`.${L.row}`]:{display:"flex",width:"var(--DataGrid-rowWidth)",breakInside:"avoid","--rowBorderColor":"var(--DataGrid-rowBorderColor)",[`&.${L["row--firstVisible"]}`]:{"--rowBorderColor":"transparent"},"&:hover":{backgroundColor:d,"@media (hover: none)":{backgroundColor:"transparent"}},[`&.${L.rowSkeleton}:hover`]:{backgroundColor:"transparent"},"&.Mui-selected":w,position:"relative"},[`& .${L.cell}`]:{flex:"0 0 auto",height:"var(--height)",width:"var(--width)",lineHeight:"calc(var(--height) - 1px)",boxSizing:"border-box",borderTop:"1px solid var(--rowBorderColor)",overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis","&.Mui-selected":w},[`& .${L["virtualScrollerContent--overflowed"]} .${L["row--lastVisible"]} .${L.cell}`]:{borderTopColor:"transparent"},[`& .${L.pinnedRows} .${L.row}, .${L.aggregationRowOverlayWrapper} .${L.row}`]:{backgroundColor:r,"&:hover":{backgroundColor:h}},[`& .${L["pinnedRows--top"]} :first-of-type`]:{[`& .${L.cell}, .${L.scrollbarFiller}`]:{borderTop:"none"}},[`&.${L["root--disableUserSelection"]}`]:{userSelect:"none"},[`& .${L["row--dynamicHeight"]} > .${L.cell}`]:{whiteSpace:"initial",lineHeight:"inherit"},[`& .${L.cellEmpty}`]:{flex:1,padding:0,height:"unset"},[`& .${L.cell}.${L["cell--selectionMode"]}`]:{cursor:"default"},[`& .${L.cell}.${L["cell--editing"]}`]:{padding:1,display:"flex",boxShadow:z.shadows.base,backgroundColor:z.colors.background.overlay,"&:focus-within":{outline:`1px solid ${z.colors.interactive.focus}`,outlineOffset:-1}},[`& .${L["cell--editing"]}`]:{"& .MuiInputBase-root":{height:"100%"}},[`& .${L["row--editing"]}`]:{boxShadow:z.shadows.base},[`& .${L["row--editing"]} .${L.cell}`]:{boxShadow:"none",backgroundColor:z.colors.background.overlay},[`& .${L.editBooleanCell}`]:{display:"flex",height:"100%",width:"100%",alignItems:"center",justifyContent:"center"},[`& .${L.booleanCell}[data-value="true"]`]:{color:z.colors.foreground.muted},[`& .${L.booleanCell}[data-value="false"]`]:{color:z.colors.foreground.disabled},[`& .${L.actionsCell}`]:{display:"inline-flex",alignItems:"center",gridGap:z.spacing(1)},[`& .${L.rowReorderCell}`]:{display:"inline-flex",flex:1,alignItems:"center",justifyContent:"center",opacity:z.colors.interactive.disabledOpacity},[`& .${L["rowReorderCell--draggable"]}`]:{cursor:"grab",opacity:1},[`& .${L.rowReorderCellContainer}`]:{padding:0,display:"flex",alignItems:"stretch"},[`.${L.withBorderColor}`]:{borderColor:z.colors.border.base},[`& .${L["cell--withLeftBorder"]}, & .${L["columnHeader--withLeftBorder"]}`]:{borderLeftColor:"var(--DataGrid-rowBorderColor)",borderLeftWidth:"1px",borderLeftStyle:"solid"},[`& .${L["cell--withRightBorder"]}, & .${L["columnHeader--withRightBorder"]}`]:{borderRightColor:"var(--DataGrid-rowBorderColor)",borderRightWidth:"1px",borderRightStyle:"solid"},[`& .${L["cell--flex"]}`]:{display:"flex",alignItems:"center",lineHeight:"inherit"},[`& .${L["cell--textLeft"]}`]:{textAlign:"left",justifyContent:"flex-start"},[`& .${L["cell--textRight"]}`]:{textAlign:"right",justifyContent:"flex-end"},[`& .${L["cell--textCenter"]}`]:{textAlign:"center",justifyContent:"center"},[`& .${L["cell--pinnedLeft"]}, & .${L["cell--pinnedRight"]}`]:{position:"sticky",zIndex:30,background:z.cell.background.pinned,"&.Mui-selected":{backgroundColor:g}},[`& .${L.row}`]:{"&:hover":b,"&.Mui-selected":v,"&.Mui-selected:hover":y},[`& .${L.cellOffsetLeft}`]:{flex:"0 0 auto",display:"inline-block"},[`& .${L.cellSkeleton}`]:{flex:"0 0 auto",height:"100%",display:"inline-flex",alignItems:"center"},[`& .${L.columnHeaderDraggableContainer}`]:{display:"flex",width:"100%",height:"100%"},[`& .${L.rowReorderCellPlaceholder}`]:{display:"none"},[`& .${L["columnHeader--dragging"]}`]:{background:z.colors.background.overlay,padding:"0 12px",borderRadius:"var(--unstable_DataGrid-radius)",opacity:z.colors.interactive.disabledOpacity},[`& .${L["row--dragging"]}`]:{background:z.colors.background.overlay,padding:"0 12px",borderRadius:"var(--unstable_DataGrid-radius)",border:"1px solid var(--DataGrid-rowBorderColor)",color:z.colors.foreground.base,transform:"translateZ(0)",[`& .${L.rowReorderCellPlaceholder}`]:{padding:"0 6px",display:"flex"}},[`& .${L.treeDataGroupingCell}`]:{display:"flex",alignItems:"center",width:"100%"},[`& .${L.treeDataGroupingCellToggle}`]:{flex:"0 0 28px",alignSelf:"stretch",marginRight:z.spacing(2)},[`& .${L.treeDataGroupingCellLoadingContainer}, .${L.groupingCriteriaCellLoadingContainer}`]:{display:"flex",alignItems:"center",justifyContent:"center",height:"100%"},[`& .${L.groupingCriteriaCell}`]:{display:"flex",alignItems:"center",width:"100%"},[`& .${L.groupingCriteriaCellToggle}`]:{flex:"0 0 28px",alignSelf:"stretch",marginRight:z.spacing(2)},[`& .${L.columnHeaders} .${L.scrollbarFiller}`]:{backgroundColor:n},[`.${L.scrollbarFiller}`]:{minWidth:"calc(var(--DataGrid-hasScrollY) * var(--DataGrid-scrollbarSize))",alignSelf:"stretch",backgroundColor:n,[`&.${L["scrollbarFiller--pinnedRight"]}`]:{position:"sticky",zIndex:40,right:0}},[`& .${L.filler}`]:{flex:"1 0 auto"},[`& .${L["filler--borderBottom"]}`]:{borderBottom:"1px solid var(--DataGrid-rowBorderColor)"},[`& .${L.columnHeaders} .${L.filler}`]:{backgroundColor:n},[`& .${L["main--hiddenContent"]}`]:{[`& .${L.virtualScrollerContent}`]:{position:"fixed",visibility:"hidden"},[`& .${L.pinnedRows}`]:{display:"none"}},[`& .${L["row--beingDragged"]}`]:{color:z.colors.foreground.disabled,"&:hover":{backgroundColor:"transparent"}}}});function re(e,t){return`rgba(from ${e} r g b / ${t})`}const oe="undefined"!=typeof CSS&&"function"==typeof CSS.supports&&CSS.supports("color","color-mix(in srgb, red 50%, blue 50%)"),ie=(e,t)=>oe?e:t;function ae(e,t,n,r){return ie(`color-mix(in srgb,${e}, ${t} calc(${n} * 100%))`,r)}const le=o.createContext(void 0),se=()=>{const e=o.useContext(le);if(!e)throw new Error("MUI X: useGridRootProps should only be used inside the DataGrid, DataGridPro or DataGridPremium component.");return e},ce=o.createContext(void 0),ue=()=>{const e=o.useContext(ce);if(void 0===e)throw new Error(["MUI X: Could not find the Data Grid configuration context.","It looks like you rendered your component outside of a DataGrid, DataGridPro or DataGridPremium parent component.","This can also happen if you are bundling multiple versions of the Data Grid."].join("\n"));return e},de=o.createContext({className:"unset",tag:(0,r.jsx)("style",{href:"/unset"})});function fe(){return o.useContext(de).className}function pe(e){const t=ue(),n=se(),i=t.hooks.useCSSVariables(),a=o.useMemo(()=>{const e=`MuiDataGridVariables-${i.id}`,t=`.${e}{${function(e){let t="";for(const n in e)Object.hasOwn(e,n)&&void 0!==e[n]&&(t+=`${n}:${e[n]};`);return t}(i.variables)}}`;return{className:e,tag:(0,r.jsx)("style",{href:`/${e}`,nonce:n.nonce,children:t})}},[n.nonce,i]);return(0,r.jsx)(de.Provider,{value:a,children:e.children})}var he=Symbol("NOT_FOUND");var ge=e=>Array.isArray(e)?e:[e];var me=(e,t)=>e===t;function Ae(e,t){const n="object"==typeof t?t:{equalityCheck:t},{equalityCheck:r=me,maxSize:o=1,resultEqualityCheck:i}=n,a=function(e){return function(t,n){if(null===t||null===n||t.length!==n.length)return!1;const{length:r}=t;for(let o=0;o<r;o++)if(!e(t[o],n[o]))return!1;return!0}}(r);let l=0;const s=o<=1?function(e){let t;return{get:n=>t&&e(t.key,n)?t.value:he,put(e,n){t={key:e,value:n}},getEntries:()=>t?[t]:[],clear(){t=void 0}}}(a):function(e,t){let n=[];function r(e){const r=n.findIndex(n=>t(e,n.key));if(r>-1){const e=n[r];return r>0&&(n.splice(r,1),n.unshift(e)),e.value}return he}return{get:r,put:function(t,o){r(t)===he&&(n.unshift({key:t,value:o}),n.length>e&&n.pop())},getEntries:function(){return n},clear:function(){n=[]}}}(o,a);function c(){let t=s.get(arguments);if(t===he){if(t=e.apply(null,arguments),l++,i){const e=s.getEntries().find(e=>i(e.value,t));e&&(t=e.value,0!==l&&l--)}s.put(arguments,t)}return t}return c.clearCache=()=>{s.clear(),c.resetResultsCount()},c.resultsCount=()=>l,c.resetResultsCount=()=>{l=0},c}var be=class{constructor(e){this.value=e}deref(){return this.value}},ve=(()=>"undefined"==typeof WeakRef?be:WeakRef)();function ye(){return{s:0,v:void 0,o:null,p:null}}function we(e,t={}){let n={s:0,v:void 0,o:null,p:null};const{resultEqualityCheck:r}=t;let o,i=0;function a(){let t=n;const{length:a}=arguments;for(let e=0,n=a;e<n;e++){const n=arguments[e];if("function"==typeof n||"object"==typeof n&&null!==n){let e=t.o;null===e&&(t.o=e=new WeakMap);const r=e.get(n);void 0===r?(t=ye(),e.set(n,t)):t=r}else{let e=t.p;null===e&&(t.p=e=new Map);const r=e.get(n);void 0===r?(t=ye(),e.set(n,t)):t=r}}const l=t;let s;if(1===t.s)s=t.v;else if(s=e.apply(null,arguments),i++,r){const e=(c=o)instanceof ve?c.deref():c;null!=e&&r(e,s)&&(s=e,0!==i&&i--),o="object"==typeof s&&null!==s||"function"==typeof s?new ve(s):s}var c;return l.s=1,l.v=s,s}return a.clearCache=()=>{n={s:0,v:void 0,o:null,p:null},a.resetResultsCount()},a.resultsCount=()=>i,a.resetResultsCount=()=>{i=0},a}const Ce=function(e,...t){const n="function"==typeof e?{memoize:e,memoizeOptions:t}:e,r=(...e)=>{let t,r=0,o=0,i={},a=e.pop();"object"==typeof a&&(i=a,a=e.pop()),function(e,t="expected a function, instead received "+typeof e){if("function"!=typeof e)throw new TypeError(t)}(a,`createSelector expects an output function after the inputs, but received: [${typeof a}]`);const l={...n,...i},{memoize:s,memoizeOptions:c=[],argsMemoize:u=we,argsMemoizeOptions:d=[]}=l,f=ge(c),p=ge(d),h=function(e){const t=Array.isArray(e[0])?e[0]:e;return function(e,t="expected all items to be functions, instead received the following types: "){if(!e.every(e=>"function"==typeof e)){const n=e.map(e=>"function"==typeof e?`function ${e.name||"unnamed"}()`:typeof e).join(", ");throw new TypeError(`${t}[${n}]`)}}(t,"createSelector expects all input-selectors to be functions, but received the following types: "),t}(e),g=s(function(){return r++,a.apply(null,arguments)},...f),m=u(function(){o++;const e=function(e,t){const n=[],{length:r}=e;for(let o=0;o<r;o++)n.push(e[o].apply(null,t));return n}(h,arguments);return t=g.apply(null,e),t},...p);return Object.assign(m,{resultFunc:a,memoizedResultFunc:g,dependencies:h,dependencyRecomputations:()=>o,resetDependencyRecomputations:()=>{o=0},lastResult:()=>t,recomputations:()=>r,resetRecomputations:()=>{r=0},memoize:s,argsMemoize:u})};return Object.assign(r,{withTypes:()=>r}),r}({memoize:Ae,memoizeOptions:{maxSize:1,equalityCheck:Object.is}}),Se=(e,t,n,r,o,i,a,l,...s)=>{if(s.length>0)throw new Error("Unsupported number of selectors");let c;if(e&&t&&n&&r&&o&&i&&a&&l)c=(s,c,u,d)=>{const f=e(s,c,u,d),p=t(s,c,u,d),h=n(s,c,u,d),g=r(s,c,u,d),m=o(s,c,u,d),A=i(s,c,u,d),b=a(s,c,u,d);return l(f,p,h,g,m,A,b,c,u,d)};else if(e&&t&&n&&r&&o&&i&&a)c=(l,s,c,u)=>{const d=e(l,s,c,u),f=t(l,s,c,u),p=n(l,s,c,u),h=r(l,s,c,u),g=o(l,s,c,u),m=i(l,s,c,u);return a(d,f,p,h,g,m,s,c,u)};else if(e&&t&&n&&r&&o&&i)c=(a,l,s,c)=>{const u=e(a,l,s,c),d=t(a,l,s,c),f=n(a,l,s,c),p=r(a,l,s,c),h=o(a,l,s,c);return i(u,d,f,p,h,l,s,c)};else if(e&&t&&n&&r&&o)c=(i,a,l,s)=>{const c=e(i,a,l,s),u=t(i,a,l,s),d=n(i,a,l,s),f=r(i,a,l,s);return o(c,u,d,f,a,l,s)};else if(e&&t&&n&&r)c=(o,i,a,l)=>{const s=e(o,i,a,l),c=t(o,i,a,l),u=n(o,i,a,l);return r(s,c,u,i,a,l)};else if(e&&t&&n)c=(r,o,i,a)=>{const l=e(r,o,i,a),s=t(r,o,i,a);return n(l,s,o,i,a)};else if(e&&t)c=(n,r,o,i)=>{const a=e(n,r,o,i);return t(a,r,o,i)};else{if(!e)throw new Error("Missing arguments");c=e}return c},xe=(...e)=>{const t=new WeakMap;let n=1;const r=e[e.length-1],o=e.length-1||1,i=Math.max(r.length-o,0);if(i>3)throw new Error("Unsupported number of arguments");return(o,a,l,s)=>{let c=o.__cacheKey__;c||(c={id:n},o.__cacheKey__=c,n+=1);let u=t.get(c);if(!u){const n=1===e.length?[e=>e,r]:e;let o=e;const a=[void 0,void 0,void 0];switch(i){case 0:break;case 1:o=[...n.slice(0,-1),()=>a[0],r];break;case 2:o=[...n.slice(0,-1),()=>a[0],()=>a[1],r];break;case 3:o=[...n.slice(0,-1),()=>a[0],()=>a[1],()=>a[2],r];break;default:throw new Error("Unsupported number of arguments")}u=Ce(...o),u.selectorArgs=a,t.set(c,u)}switch(i){case 3:u.selectorArgs[2]=s;case 2:u.selectorArgs[1]=l;case 1:u.selectorArgs[0]=a}switch(i){case 0:return u(o);case 1:return u(o,a);case 2:return u(o,a,l);case 3:return u(o,a,l,s);default:throw new Error("unreachable")}}};const Ee=(...e)=>{const t=Se(...e);return(e,n,r,o)=>t(Re(e),n,r,o)},Ie=(...e)=>{const t=xe(...e);return(e,n,r,o)=>t(Re(e),n,r,o)},ke=e=>(t,n)=>e(Re(t),n);function Re(e){return"current"in e?e.current.state:e}const Me={compact:.7,comfortable:1.3,standard:1},Pe=ke(e=>e.density),Be=Ee(Pe,e=>Me[e]),_e=()=>()=>{},Te=()=>!1,Oe=()=>!0;let De=function(e){return e.LEFT="left",e.RIGHT="right",e}({});const Ne={left:[],right:[]},Le=ke(e=>e.props.listView??!1),Fe=ke(e=>e.listViewColumn),Qe=ke(e=>e.columns),je=Ee(Qe,e=>e.orderedFields),ze=Ee(Qe,e=>e.lookup),$e=Ie(je,ze,(e,t)=>e.map(e=>t[e])),He=Ee(Qe,e=>e.columnVisibilityModel),Ge=Ee(Qe,e=>e.initialColumnVisibilityModel),Ve=Ie($e,He,Le,Fe,(e,t,n,r)=>n&&r?[r]:e.filter(e=>!1!==t[e.field])),We=Ie(Ve,e=>e.map(e=>e.field)),Ue=ke(e=>e.pinnedColumns),qe=(Ie(Ue,je,(e,t)=>Ye(e,t)),Ie(Qe,Ue,We,Le,(e,t,n,r)=>{if(r)return Ne;const o=Ye(t,n);return{left:o.left.map(t=>e.lookup[t]),right:o.right.map(t=>e.lookup[t])}}));function Ye(e,t){if(!Array.isArray(e.left)&&!Array.isArray(e.right))return Ne;if(0===e.left?.length&&0===e.right?.length)return Ne;const n=(e,t)=>Array.isArray(e)?e.filter(e=>t.includes(e)):[],r=n(e.left,t),o=t.filter(e=>!r.includes(e)),i=n(e.right,o);return{left:r,right:i}}const Ke=Ie(Ve,e=>{const t=[];let n=0;for(let r=0;r<e.length;r+=1)t.push(n),n+=e[r].computedWidth;return t}),Je=Ie($e,e=>e.filter(e=>e.filterable)),Xe=Ie($e,e=>e.reduce((e,t)=>(t.filterable&&(e[t.field]=t),e),{})),Ze=Ie($e,e=>e.some(e=>void 0!==e.colSpan)),et=ke(e=>e.preferencePanel),tt=Ee(et,(e,t)=>!(!e.open||e.labelId!==t));var nt=function(e){return e.filters="filters",e.columns="columns",e.aiAssistant="aiAssistant",e}(nt||{});const rt=o.createContext(void 0);function ot(){const e=o.useContext(rt);if(void 0===e)throw new Error(["MUI X: Could not find the Data Grid context.","It looks like you rendered your component outside of a DataGrid, DataGridPro or DataGridPremium parent component.","This can also happen if you are bundling multiple versions of the Data Grid."].join("\n"));return e}const it=o.createContext(void 0);function at(){const e=o.useContext(it);if(void 0===e)throw new Error("MUI X: Missing context.");return e}function lt({children:e}){const t=o.useRef(null),n=o.useRef(null),i=o.useRef(null),a=o.useMemo(()=>({columnsPanelTriggerRef:t,filterPanelTriggerRef:n,aiAssistantPanelTriggerRef:i}),[]);return(0,r.jsx)(it.Provider,{value:a,children:e})}function st(){const e=ot(),t=J(e,$e),n=se(),o=J(e,et),{columnsPanelTriggerRef:i,filterPanelTriggerRef:a,aiAssistantPanelTriggerRef:l}=at(),s=e.current.unstable_applyPipeProcessors("preferencePanel",null,o.openedPanelValue??nt.filters);let c=null;switch(o.openedPanelValue){case nt.filters:c=a.current;break;case nt.columns:c=i.current;break;case nt.aiAssistant:c=l.current}return(0,r.jsx)(n.slots.panel,(0,y.A)({id:o.panelId,open:t.length>0&&o.open,"aria-labelledby":o.labelId,target:c,onClose:()=>e.current.hidePreferences()},n.slotProps?.panel,{children:s}))}function ct(){const e=se();return(0,r.jsxs)(o.Fragment,{children:[(0,r.jsx)(st,{}),e.showToolbar&&(0,r.jsx)(e.slots.toolbar,(0,y.A)({},e.slotProps?.toolbar))]})}const ut=ke(e=>e.dimensions),dt=Ee(ut,e=>e.columnsTotalWidth),ft=Ee(ut,e=>e.rowHeight),pt=(Ee(ut,e=>e.contentSize.height),Ee(ut,e=>e.hasScrollX)),ht=Ee(ut,e=>e.hasScrollY),gt=Ee(ut,e=>e.columnsTotalWidth<e.viewportOuterSize.width),mt=Ee(ut,e=>e.headerHeight),At=Ee(ut,e=>e.groupHeaderHeight),bt=(Ee(ut,e=>e.headerFilterHeight),Ee(ut,e=>e.hasScrollX?e.scrollbarSize:0)),vt=Ee(ut,e=>e.hasScrollY?e.scrollbarSize:0),yt=Ee(ut,bt,(e,t)=>{const n=e.viewportOuterSize.height-e.minimumSize.height>0;return!(0===t&&!n)}),wt=ke(e=>e.rows),Ct=Ee(wt,e=>e.totalRowCount),St=Ee(wt,e=>e.loading),xt=Ee(wt,e=>e.totalTopLevelRowCount),Et=Ee(wt,e=>e.dataRowIdToModelLookup),It=(Ee(Et,(e,t)=>e[t]),Ee(wt,e=>e.tree)),kt=Ee(It,(e,t)=>e[t]),Rt=Ee(wt,e=>e.groupsToFetch),Mt=Ee(wt,e=>e.groupingName),Pt=Ee(wt,e=>e.treeDepths),Bt=Ie(wt,e=>{const t=Object.entries(e.treeDepths);return 0===t.length?1:(t.filter(([,e])=>e>0).map(([e])=>Number(e)).sort((e,t)=>t-e)[0]??0)+1}),_t=Ee(wt,e=>e.dataRowIds),Tt=Ie(_t,Et,(e,t)=>e.reduce((e,n)=>t[n]?(e.push(t[n]),e):e,[])),Ot=Ie(Ee(wt,e=>e?.additionalRowGroups),e=>{const t=e?.pinnedRows;return{bottom:t?.bottom?.map(e=>({id:e.id,model:e.model??{}}))??[],top:t?.top?.map(e=>({id:e.id,model:e.model??{}}))??[]}}),Dt=Ee(Ot,e=>(e?.top?.length||0)+(e?.bottom?.length||0));var Nt=n(7341);class Lt{timeouts=(()=>new Map)();cleanupTimeout=1e3;constructor(e=1e3){this.cleanupTimeout=e}register(e,t,n){this.timeouts||(this.timeouts=new Map);const r=setTimeout(()=>{"function"==typeof t&&t(),this.timeouts.delete(n.cleanupToken)},this.cleanupTimeout);this.timeouts.set(n.cleanupToken,r)}unregister(e){const t=this.timeouts.get(e.cleanupToken);t&&(this.timeouts.delete(e.cleanupToken),clearTimeout(t))}reset(){this.timeouts&&(this.timeouts.forEach((e,t)=>{this.unregister({cleanupToken:t})}),this.timeouts=void 0)}}class Ft{registry=(()=>new FinalizationRegistry(e=>{"function"==typeof e&&e()}))();register(e,t,n){this.registry.register(e,t,n)}unregister(e){this.registry.unregister(e)}reset(){}}class Qt{static create(){return new Qt}}const jt={current:"undefined"!=typeof FinalizationRegistry?new Ft:new Lt};let zt=0;function $t(e,t,n,r){const i=o.useState(Qt.create)[0],a=o.useRef(null),l=o.useRef(null);l.current=n;const s=o.useRef(null);if(!a.current&&l.current){const n=(e,t,n)=>{t&&!t.defaultMuiPrevented&&l.current?.(e,t,n)};a.current=e.current.subscribeEvent(t,n,r),zt+=1,s.current={cleanupToken:zt},jt.current.register(i,()=>{a.current?.(),a.current=null,s.current=null},s.current)}else!l.current&&a.current&&(a.current(),a.current=null,s.current&&(jt.current.unregister(s.current),s.current=null));o.useEffect(()=>{if(!a.current&&l.current){const n=(e,t,n)=>{t&&!t.defaultMuiPrevented&&l.current?.(e,t,n)};a.current=e.current.subscribeEvent(t,n,r)}return s.current&&jt.current&&(jt.current.unregister(s.current),s.current=null),()=>{a.current?.(),a.current=null}},[e,t,r])}const Ht={isFirst:!0};function Gt(e,t,n){$t(e,t,n,Ht)}var Vt=n(4281),Wt=n(429),Ut=n(3395);function qt(e){throw new Error("Failed assertion: should not be rendered")}const Yt=["id","value","formattedValue","api","field","row","rowNode","colDef","cellMode","isEditable","tabIndex","hasFocus","isValidating","debounceMs","isProcessingProps","onValueChange","slotProps"],Kt=(0,_.Ay)(qt,{name:"MuiDataGrid",slot:"EditInputCell"})({font:z.typography.font.body,padding:"1px 0","& input":{padding:"0 16px",height:"100%"}}),Jt=S((e,t)=>{const n=se(),{id:i,value:a,field:l,colDef:s,hasFocus:c,debounceMs:u=200,isProcessingProps:d,onValueChange:f,slotProps:p}=e,h=(0,x.A)(e,Yt),g=ot(),m=o.useRef(null),[A,b]=o.useState(a),v=(e=>{const{classes:t}=e;return(0,R.A)({root:["editInputCell"]},D,t)})(n),w=o.useCallback(async e=>{const t=e.target.value,n=g.current.getColumn(l);let r=t;n.valueParser&&(r=n.valueParser(t,g.current.getRow(i),n,g)),b(r),g.current.setEditCellValue({id:i,field:l,value:r,debounceMs:u,unstable_skipValueParser:!0},e),f&&await f(e,t)},[g,u,l,i,f]),C=g.current.unstable_getEditCellMeta(i,l);return o.useEffect(()=>{"debouncedSetEditCellValue"!==C?.changeReason&&b(a)},[C,a]),(0,Ut.A)(()=>{c&&m.current.focus()},[c]),(0,r.jsx)(Kt,(0,y.A)({as:n.slots.baseInput,inputRef:m,className:v.root,ownerState:n,fullWidth:!0,type:"number"===s.type?s.type:"text",value:A??"",onChange:w,endAdornment:d?(0,r.jsx)(n.slots.loadIcon,{fontSize:"small",color:"action"}):void 0},h,p?.root,{ref:t}))}),Xt=(e,t)=>t&&e.length>1?[e[0]]:e,Zt=(e,t)=>n=>(0,y.A)({},n,{sorting:(0,y.A)({},n.sorting,{sortModel:Xt(e,t)})}),en=(e,t)=>{const n=e.indexOf(t);return t&&-1!==n&&n+1!==e.length?e[n+1]:e[0]},tn=(e,t)=>null==e&&null!=t?-1:null==t&&null!=e?1:null==e&&null==t?0:null,nn=new Intl.Collator,rn=(e,t)=>{const n=tn(e,t);return null!==n?n:Number(e)-Number(t)},on=(e,t)=>{const n=tn(e,t);return null!==n?n:e>t?1:e<t?-1:0};var an=n(2415);const ln=["item","applyValue","type","apiRef","focusElementRef","tabIndex","disabled","isFilterActive","slotProps","clearButton","headerFilterMenu"];function sn(e){const{item:t,applyValue:n,type:i,apiRef:a,focusElementRef:l,tabIndex:s,disabled:c,slotProps:u,clearButton:d,headerFilterMenu:f}=e,p=(0,x.A)(e,ln),h=u?.root,g=(0,Vt.A)(),[m,A]=o.useState(cn(t.value)),[b,v]=o.useState(!1),w=(0,an.A)(),C=se(),S=o.useCallback(e=>{const r=cn(e.target.value);A(r),v(!0),g.start(C.filterDebounceMs,()=>{const e=(0,y.A)({},t,{value:"number"!==i||Number.isNaN(Number(r))?r:Number(r),fromInput:w});n(e),v(!1)})},[g,C.filterDebounceMs,t,i,w,n]);return o.useEffect(()=>{t.fromInput===w&&null!=t.value||A(cn(t.value))},[w,t]),(0,r.jsxs)(o.Fragment,{children:[(0,r.jsx)(C.slots.baseTextField,(0,y.A)({id:w,label:a.current.getLocaleText("filterPanelInputLabel"),placeholder:a.current.getLocaleText("filterPanelInputPlaceholder"),value:m??"",onChange:S,type:i||"text",disabled:c,slotProps:(0,y.A)({},h?.slotProps,{input:(0,y.A)({endAdornment:b?(0,r.jsx)(C.slots.loadIcon,{fontSize:"small",color:"action"}):null},h?.slotProps?.input),htmlInput:(0,y.A)({tabIndex:s},h?.slotProps?.htmlInput)}),inputRef:l},C.slotProps?.baseTextField,p,h)),f,d]})}function cn(e){if(null!=e&&""!==e)return String(e)}function un(e){return"object"==typeof e&&null!==e}function dn(e){return e.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")}const fn=(e,t,n)=>Math.max(t,Math.min(n,e));function pn(e){return"function"==typeof structuredClone?structuredClone(e):JSON.parse(JSON.stringify(e))}const hn=(e,t)=>(...n)=>{e&&t(...n)},gn=["item","applyValue","type","apiRef","focusElementRef","slotProps"];function mn(e){const{item:t,applyValue:n,type:i,apiRef:a,focusElementRef:l,slotProps:s}=e,c=(0,x.A)(e,gn),u=(0,an.A)(),[d,f]=o.useState([]),[p,h]=o.useState(t.value||[]),g=se();o.useEffect(()=>{const e=t.value??[];h(e.map(String))},[t.value]);const m=o.useCallback((e,r)=>{h(r.map(String)),n((0,y.A)({},t,{value:[...r.map(e=>"number"===i?Number(e):e)]}))},[n,t,i]),A=o.useCallback((e,t)=>{f(""===t?[]:[t])},[f]),b=g.slots.baseAutocomplete;return(0,r.jsx)(b,(0,y.A)({multiple:!0,freeSolo:!0,options:d,id:u,value:p,onChange:m,onInputChange:A,label:a.current.getLocaleText("filterPanelInputLabel"),placeholder:a.current.getLocaleText("filterPanelInputPlaceholder"),slotProps:{textField:{type:i||"text",inputRef:l}}},c,s?.root))}var An=function(e){return e.And="and",e.Or="or",e}(An||{});const bn={filteredRowsLookup:{},filteredChildrenCountLookup:{},filteredDescendantCountLookup:{}},vn=()=>({items:[],logicOperator:An.And,quickFilterValues:[],quickFilterLogicOperator:An.And});function yn(e){return{current:e.current.getPublicApi()}}let wn;const Cn=(e,t)=>{const n=(0,y.A)({},e);if(null==n.id&&(n.id=Math.round(1e5*Math.random())),null==n.operator){const e=ze(t)[n.field];n.operator=e&&e.filterOperators[0].value}return n},Sn=(e,t,n)=>{const r=e.items.length>1;let o;o=r&&t?[e.items[0]]:e.items;const i=r&&o.some(e=>null==e.id);return o.some(e=>null==e.operator)||i?(0,y.A)({},e,{items:o.map(e=>Cn(e,n))}):e.items!==o?(0,y.A)({},e,{items:o}):e},xn=(e,t,n)=>r=>(0,y.A)({},r,{filterModel:Sn(e,t,n)}),En=e=>"string"==typeof e?e.normalize("NFD").replace(/[\u0300-\u036f]/g,""):e,In=(e,t,n)=>{if(!e.field||!e.operator)return null;const r=n.current.getColumn(e.field);if(!r)return null;let o;if(r.valueParser){const t=r.valueParser;o=Array.isArray(e.value)?e.value?.map(e=>t(e,void 0,r,n)):t(e.value,void 0,r,n)}else o=e.value;const{ignoreDiacritics:i}=n.current.rootProps;i&&(o=En(o));const a=(0,y.A)({},e,{value:o}),l=r.filterOperators;if(!l?.length)throw new Error(`MUI X: No filter operators found for column '${r.field}'.`);const s=l.find(e=>e.value===a.operator);if(!s)throw new Error(`MUI X: No filter operator found for column '${r.field}' and operator value '${a.operator}'.`);const c=yn(n),u=s.getApplyFilterFn(a,r);return"function"!=typeof u?null:{item:a,fn:e=>{let n=t(e,r);return i&&(n=En(n)),u(n,e,r,c)}}};let kn=1;const Rn=e=>e.quickFilterExcludeHiddenColumns??!0,Mn=(e,t,n,r)=>{const o=((e,t,n,r)=>{const{items:o}=e,i=o.map(e=>In(e,t,n)).filter(e=>!!e);if(0===i.length)return null;if(r||!function(){if(void 0!==wn)return wn;try{wn=new Function("return true")()}catch(e){wn=!1}return wn}())return(e,t)=>{const n={};for(let r=0;r<i.length;r+=1){const o=i[r];t&&!t(o.item.field)||(n[o.item.id]=o.fn(e))}return n};const a=new Function("appliers","row","shouldApplyFilter",`"use strict";\n${i.map((e,t)=>`const shouldApply${t} = !shouldApplyFilter || shouldApplyFilter(${JSON.stringify(e.item.field)});`).join("\n")}\n\nconst result$$ = {\n${i.map((e,t)=>` ${JSON.stringify(String(e.item.id))}: !shouldApply${t} ? false : appliers[${t}].fn(row),`).join("\n")}\n};\n\nreturn result$$;`.replaceAll("$$",String(kn)));return kn+=1,(e,t)=>a(i,e,t)})(e,t,n,r),i=((e,t,n)=>{const r=e.quickFilterValues?.filter(Boolean)??[];if(0===r.length)return null;const o=je(n),i=He(n);let a;a=Rn(e)?o.filter(e=>!1!==i[e]):o;const l=[],{ignoreDiacritics:s}=n.current.rootProps,c=yn(n);return a.forEach(e=>{const t=n.current.getColumn(e),o=t?.getApplyQuickFilterFn;o&&l.push({column:t,appliers:r.map(e=>{const n=s?En(e):e;return{fn:o(n,t,c)}})})}),function(e,n){const o={};e:for(let i=0;i<r.length;i+=1){const a=r[i];for(let r=0;r<l.length;r+=1){const{column:u,appliers:d}=l[r],{field:f}=u;if(n&&!n(f))continue;const p=d[i];let h=t(e,u);if(null!==p.fn&&(s&&(h=En(h)),p.fn(h,e,u,c))){o[a]=!0;continue e}}o[a]=!1}return o}})(e,t,n);return function(e,t,n){n.passingFilterItems=o?.(e,t)??null,n.passingQuickFilterValues=i?.(e,t)??null}},Pn=e=>null!=e,Bn=(e,t,n,r,o,i)=>{const a=((e,t,n,r)=>(e.cleanedFilterItems||(e.cleanedFilterItems=r.filter(e=>null!==In(e,t,n))),e.cleanedFilterItems))(i,r,o,n.items),l=e.filter(Pn),s=t.filter(Pn);if(l.length>0){const e=e=>l.some(t=>t[e.id]);if((n.logicOperator??vn().logicOperator)===An.And){if(!a.every(e))return!1}else if(!a.some(e))return!1}if(s.length>0&&null!=n.quickFilterValues){const e=e=>s.some(t=>t[e]);if((n.quickFilterLogicOperator??vn().quickFilterLogicOperator)===An.And){if(!n.quickFilterValues.every(e))return!1}else if(!n.quickFilterValues.some(e))return!1}return!0},_n=(e,t)=>n=>{if(!n.value)return null;const r=e?n.value:n.value.trim(),o=new RegExp(dn(r),"i");return e=>{if(null==e)return t;const n=o.test(String(e));return t?!n:n}},Tn=(e,t)=>n=>{if(!n.value)return null;const r=e?n.value:n.value.trim(),o=new Intl.Collator(void 0,{sensitivity:"base",usage:"search"});return e=>{if(null==e)return t;const n=0===o.compare(r,e.toString());return t?!n:n}},On=e=>()=>t=>{const n=""===t||null==t;return e?!n:n},Dn={width:100,minWidth:50,maxWidth:1/0,hideable:!0,sortable:!0,resizable:!0,filterable:!0,groupable:!0,pinnable:!0,aggregable:!0,chartable:!0,editable:!1,sortComparator:(e,t)=>{const n=tn(e,t);return null!==n?n:"string"==typeof e?nn.compare(e.toString(),t.toString()):e-t},type:"string",align:"left",filterOperators:((e=!1)=>[{value:"contains",getApplyFilterFn:_n(e,!1),InputComponent:sn},{value:"doesNotContain",getApplyFilterFn:_n(e,!0),InputComponent:sn},{value:"equals",getApplyFilterFn:Tn(e,!1),InputComponent:sn},{value:"doesNotEqual",getApplyFilterFn:Tn(e,!0),InputComponent:sn},{value:"startsWith",getApplyFilterFn:t=>{if(!t.value)return null;const n=e?t.value:t.value.trim(),r=new RegExp(`^${dn(n)}.*$`,"i");return e=>null!=e&&r.test(e.toString())},InputComponent:sn},{value:"endsWith",getApplyFilterFn:t=>{if(!t.value)return null;const n=e?t.value:t.value.trim(),r=new RegExp(`.*${dn(n)}$`,"i");return e=>null!=e&&r.test(e.toString())},InputComponent:sn},{value:"isEmpty",getApplyFilterFn:On(!1),requiresFilterValue:!1},{value:"isNotEmpty",getApplyFilterFn:On(!0),requiresFilterValue:!1},{value:"isAnyOf",getApplyFilterFn:t=>{if(!Array.isArray(t.value)||0===t.value.length)return null;const n=e?t.value:t.value.map(e=>e.trim()),r=new Intl.Collator(void 0,{sensitivity:"base",usage:"search"});return e=>null!=e&&n.some(t=>0===r.compare(t,e.toString()||""))},InputComponent:mn}])(),renderEditCell:e=>(0,r.jsx)(Jt,(0,y.A)({},e)),getApplyQuickFilterFn:e=>{if(!e)return null;const t=new RegExp(dn(e),"i");return(e,n,r,o)=>{let i=o.current.getRowFormattedValue(n,r);return o.current.ignoreDiacritics&&(i=En(i)),null!=i&&t.test(i.toString())}}},Nn=e=>null==e?null:Number(e),Ln=(0,y.A)({},Dn,{type:"number",align:"right",headerAlign:"right",sortComparator:rn,valueParser:e=>""===e?null:Number(e),valueFormatter:e=>function(e){return"number"==typeof e&&!Number.isNaN(e)}(e)?e.toLocaleString():e||"",filterOperators:[{value:"=",getApplyFilterFn:e=>null==e.value||Number.isNaN(e.value)?null:t=>Nn(t)===e.value,InputComponent:sn,InputComponentProps:{type:"number"}},{value:"!=",getApplyFilterFn:e=>null==e.value||Number.isNaN(e.value)?null:t=>Nn(t)!==e.value,InputComponent:sn,InputComponentProps:{type:"number"}},{value:">",getApplyFilterFn:e=>null==e.value||Number.isNaN(e.value)?null:t=>null!=t&&Nn(t)>e.value,InputComponent:sn,InputComponentProps:{type:"number"}},{value:">=",getApplyFilterFn:e=>null==e.value||Number.isNaN(e.value)?null:t=>null!=t&&Nn(t)>=e.value,InputComponent:sn,InputComponentProps:{type:"number"}},{value:"<",getApplyFilterFn:e=>null==e.value||Number.isNaN(e.value)?null:t=>null!=t&&Nn(t)<e.value,InputComponent:sn,InputComponentProps:{type:"number"}},{value:"<=",getApplyFilterFn:e=>null==e.value||Number.isNaN(e.value)?null:t=>null!=t&&Nn(t)<=e.value,InputComponent:sn,InputComponentProps:{type:"number"}},{value:"isEmpty",getApplyFilterFn:()=>e=>null==e,requiresFilterValue:!1},{value:"isNotEmpty",getApplyFilterFn:()=>e=>null!=e,requiresFilterValue:!1},{value:"isAnyOf",getApplyFilterFn:e=>Array.isArray(e.value)&&0!==e.value.length?t=>null!=t&&e.value.includes(Number(t)):null,InputComponent:mn,InputComponentProps:{type:"number"}}],getApplyQuickFilterFn:e=>null==e||Number.isNaN(e)||""===e?null:t=>Nn(t)===Nn(e)}),Fn=["item","applyValue","type","apiRef","focusElementRef","slotProps","isFilterActive","headerFilterMenu","clearButton","tabIndex","disabled"];function Qn(e,t){if(null==e)return"";const n=new Date(e);return Number.isNaN(n.getTime())?"":"date"===t?n.toISOString().substring(0,10):"datetime-local"===t?(n.setMinutes(n.getMinutes()-n.getTimezoneOffset()),n.toISOString().substring(0,19)):n.toISOString().substring(0,10)}function jn(e){const{item:t,applyValue:n,type:i,apiRef:a,focusElementRef:l,slotProps:s,headerFilterMenu:c,clearButton:u,tabIndex:d,disabled:f}=e,p=(0,x.A)(e,Fn),h=s?.root.slotProps,g=(0,Vt.A)(),[m,A]=o.useState(()=>Qn(t.value,i)),[b,v]=o.useState(!1),w=(0,an.A)(),C=se(),S=o.useCallback(e=>{g.clear();const r=e.target.value;A(r),v(!0),g.start(C.filterDebounceMs,()=>{const e=new Date(r);n((0,y.A)({},t,{value:Number.isNaN(e.getTime())?void 0:e})),v(!1)})},[n,t,C.filterDebounceMs,g]);return o.useEffect(()=>{const e=Qn(t.value,i);A(e)},[t.value,i]),(0,r.jsxs)(o.Fragment,{children:[(0,r.jsx)(C.slots.baseTextField,(0,y.A)({fullWidth:!0,id:w,label:a.current.getLocaleText("filterPanelInputLabel"),placeholder:a.current.getLocaleText("filterPanelInputPlaceholder"),value:m,onChange:S,type:i||"text",disabled:f,inputRef:l,slotProps:(0,y.A)({},h,{input:(0,y.A)({endAdornment:b?(0,r.jsx)(C.slots.loadIcon,{fontSize:"small",color:"action"}):null},h?.input),htmlInput:(0,y.A)({max:"datetime-local"===i?"9999-12-31T23:59":"9999-12-31",tabIndex:d},h?.htmlInput)})},C.slotProps?.baseTextField,p,s?.root)),c,u]})}function zn(e,t,n,r){if(!e.value)return null;const o=new Date(e.value);n?o.setSeconds(0,0):(o.setMinutes(o.getMinutes()+o.getTimezoneOffset()),o.setHours(0,0,0,0));const i=o.getTime();return e=>{if(!e)return!1;if(r)return t(e.getTime(),i);const o=new Date(e);return n?o.setSeconds(0,0):o.setHours(0,0,0,0),t(o.getTime(),i)}}const $n=e=>[{value:"is",getApplyFilterFn:t=>zn(t,(e,t)=>e===t,e),InputComponent:jn,InputComponentProps:{type:e?"datetime-local":"date"}},{value:"not",getApplyFilterFn:t=>zn(t,(e,t)=>e!==t,e),InputComponent:jn,InputComponentProps:{type:e?"datetime-local":"date"}},{value:"after",getApplyFilterFn:t=>zn(t,(e,t)=>e>t,e,e),InputComponent:jn,InputComponentProps:{type:e?"datetime-local":"date"}},{value:"onOrAfter",getApplyFilterFn:t=>zn(t,(e,t)=>e>=t,e,e),InputComponent:jn,InputComponentProps:{type:e?"datetime-local":"date"}},{value:"before",getApplyFilterFn:t=>zn(t,(e,t)=>e<t,e,!0),InputComponent:jn,InputComponentProps:{type:e?"datetime-local":"date"}},{value:"onOrBefore",getApplyFilterFn:t=>zn(t,(e,t)=>e<=t,e,e),InputComponent:jn,InputComponentProps:{type:e?"datetime-local":"date"}},{value:"isEmpty",getApplyFilterFn:()=>e=>null==e,requiresFilterValue:!1},{value:"isNotEmpty",getApplyFilterFn:()=>e=>null!=e,requiresFilterValue:!1}],Hn=["id","value","formattedValue","api","field","row","rowNode","colDef","cellMode","isEditable","tabIndex","hasFocus","inputProps","isValidating","isProcessingProps","onValueChange","slotProps"],Gn=(0,_.Ay)(qt,{slot:"internal"})({fontSize:"inherit"});function Vn(e){const{id:t,value:n,field:i,colDef:a,hasFocus:l,onValueChange:s,slotProps:c}=e,u=(0,x.A)(e,Hn),d="dateTime"===a.type,f=ot(),p=o.useRef(null),h=o.useMemo(()=>{let e,t;return e=null==n?null:n instanceof Date?n:new Date((n??"").toString()),t=null==e||Number.isNaN(e.getTime())?"":new Date(e.getTime()-60*e.getTimezoneOffset()*1e3).toISOString().substr(0,d?16:10),{parsed:e,formatted:t}},[n,d]),[g,m]=o.useState(h),A=se(),b=(e=>{const{classes:t}=e;return(0,R.A)({root:["editInputCell"]},D,t)})({classes:A.classes}),v=o.useCallback(e=>{if(""===e)return null;const[t,n]=e.split("T"),[r,o,i]=t.split("-"),a=new Date;if(a.setFullYear(Number(r),Number(o)-1,Number(i)),a.setHours(0,0,0,0),n){const[e,t]=n.split(":");a.setHours(Number(e),Number(t),0,0)}return a},[]),w=o.useCallback(async e=>{const n=e.target.value,r=v(n);s&&await s(e,r),m({parsed:r,formatted:n}),f.current.setEditCellValue({id:t,field:i,value:r},e)},[f,i,t,s,v]);return o.useEffect(()=>{m(e=>h.parsed!==e.parsed&&h.parsed?.getTime()!==e.parsed?.getTime()?h:e)},[h]),(0,Ut.A)(()=>{l&&p.current.focus()},[l]),(0,r.jsx)(Gn,(0,y.A)({as:A.slots.baseInput,inputRef:p,fullWidth:!0,className:b.root,type:d?"datetime-local":"date",value:g.formatted,onChange:w},u,c?.root,{slotProps:{htmlInput:(0,y.A)({max:d?"9999-12-31T23:59":"9999-12-31"},c?.root?.slotProps?.htmlInput)}}))}const Wn=e=>(0,r.jsx)(Vn,(0,y.A)({},e)),Un="auto-generated-group-node-root",qn=Symbol("mui.id_autogenerated"),Yn=(e,t,n)=>{const r=t?t(e):e.id;return function(e,t,n="A row was provided without id in the rows prop:"){if(null==e)throw new Error(["MUI X: The Data Grid component requires all rows to have a unique `id` property.","Alternatively, you can use the `getRowId` prop to specify a custom id for each row.",n,JSON.stringify(t)].join("\n"))}(r,e,n),r},Kn=(e,t,n)=>{const r=t.field;if(!t||!t.valueGetter)return e[r];const o=e[t.field];return t.valueGetter(o,e,t,n)},Jn=({rows:e,getRowId:t,loading:n,rowCount:r})=>{const o={type:"full",rows:[]},i={};for(let n=0;n<e.length;n+=1){const r=e[n],a=Yn(r,t);i[a]=r,o.rows.push(a)}return{rowsBeforePartialUpdates:e,loadingPropBeforePartialUpdates:n,rowCountPropBeforePartialUpdates:r,updates:o,dataRowIdToModelLookup:i}},Xn=({tree:e,rowCountProp:t=0})=>{const n=e[Un];return Math.max(t,n.children.length+(null==n.footerId?0:1))},Zn=({apiRef:e,rowCountProp:t=0,loadingProp:n,previousTree:r,previousTreeDepths:o,previousGroupsToFetch:i})=>{const a=e.current.caches.rows,{tree:l,treeDepths:s,dataRowIds:c,groupingName:u,groupsToFetch:d=[]}=e.current.applyStrategyProcessor("rowTreeCreation",{previousTree:r,previousTreeDepths:o,updates:a.updates,dataRowIdToModelLookup:a.dataRowIdToModelLookup,previousGroupsToFetch:i}),f=e.current.unstable_applyPipeProcessors("hydrateRows",{tree:l,treeDepths:s,dataRowIds:c,dataRowIdToModelLookup:a.dataRowIdToModelLookup});return e.current.caches.rows.updates={type:"partial",actions:{insert:[],modify:[],remove:[]},idToActionLookup:{}},(0,y.A)({},f,{totalRowCount:Math.max(t,f.dataRowIds.length),totalTopLevelRowCount:Xn({tree:f.tree,rowCountProp:t}),groupingName:u,loading:n,groupsToFetch:d})},er=e=>qn in e,tr=e=>"skeletonRow"===e.type||"footer"===e.type||"group"===e.type&&e.isAutoGenerated||"pinnedRow"===e.type&&e.isAutoGenerated,nr=(e,t,n,r)=>{const o=e[t];if("group"!==o.type)return[];const i=[];for(let t=0;t<o.children.length;t+=1){const a=o.children[t];if(n&&tr(e[a])||i.push(a),r)continue;const l=nr(e,a,n,r);for(let e=0;e<l.length;e+=1)i.push(l[e])}return n||null==o.footerId||i.push(o.footerId),i},rr=({previousCache:e,getRowId:t,updates:n,groupKeys:r})=>{if("full"===e.updates.type)throw new Error("MUI X: Unable to prepare a partial update if a full update is not applied yet.");const o=new Map;n.forEach(e=>{const n=Yn(e,t,"A row was provided without id when calling updateRows():");o.has(n)?o.set(n,(0,y.A)({},o.get(n),e)):o.set(n,e)});const i={type:"partial",actions:{insert:[...e.updates.actions.insert??[]],modify:[...e.updates.actions.modify??[]],remove:[...e.updates.actions.remove??[]]},idToActionLookup:(0,y.A)({},e.updates.idToActionLookup),groupKeys:r},a=(0,y.A)({},e.dataRowIdToModelLookup),l={insert:{},modify:{},remove:{}};o.forEach((e,t)=>{const n=i.idToActionLookup[t];if("delete"===e._action){if("remove"===n||!a[t])return;return null!=n&&(l[n][t]=!0),i.actions.remove.push(t),void delete a[t]}const r=a[t];if(r)return"remove"===n?(l.remove[t]=!0,i.actions.modify.push(t)):null==n&&i.actions.modify.push(t),void(a[t]=(0,y.A)({},r,e));"remove"===n?(l.remove[t]=!0,i.actions.insert.push(t)):null==n&&i.actions.insert.push(t),a[t]=e});const s=Object.keys(l);for(let e=0;e<s.length;e+=1){const t=s[e],n=l[t];Object.keys(n).length>0&&(i.actions[t]=i.actions[t].filter(e=>!n[e]))}return{dataRowIdToModelLookup:a,updates:i,rowsBeforePartialUpdates:e.rowsBeforePartialUpdates,loadingPropBeforePartialUpdates:e.loadingPropBeforePartialUpdates,rowCountPropBeforePartialUpdates:e.rowCountPropBeforePartialUpdates}},or="var(--DataGrid-overlayHeight, calc(var(--height) * 2))";function ir(e,t,n){const r=[];return t.forEach(t=>{const o=Yn(t,n,"A row was provided without id when calling updateRows():"),i=kt(e,o);if("pinnedRow"===i?.type){const n=e.current.caches.pinnedRows,r=n.idLookup[o];r&&(n.idLookup[o]=(0,y.A)({},r,t))}else r.push(t)}),r}const ar=(e,t,n)=>"number"==typeof e&&e>0?e:t,lr=(["MUI X: The `rowHeight` prop should be a number greater than 0.","The default value will be used instead."].join("\n"),["MUI X: The `getRowHeight` prop should return a number greater than 0 or 'auto'.","The default value will be used instead."].join("\n"),ke((e,t)=>qn in t?t[qn]:e.props.getRowId?e.props.getRowId(t):t.id)),sr=ke(e=>e.props.isRowSelectable);function cr({value:e,columnType:t,rowId:n,field:r}){if(!(e instanceof Date))throw new Error([`MUI X: \`${t}\` column type only accepts \`Date\` objects as values.`,"Use `valueGetter` to transform the value into a `Date` object.",`Row ID: ${n}, field: "${r}".`].join("\n"))}const ur=(0,y.A)({},Dn,{type:"date",sortComparator:on,valueFormatter:(e,t,n,r)=>{if(!e)return"";const o=lr(r,t);return!er(t)||e instanceof Date?(cr({value:e,columnType:"date",rowId:o,field:n.field}),e.toLocaleDateString()):e},filterOperators:$n(),renderEditCell:Wn,pastedValueParser:e=>new Date(e)}),dr=(0,y.A)({},Dn,{type:"dateTime",sortComparator:on,valueFormatter:(e,t,n,r)=>{if(!e)return"";const o=lr(r,t);return!er(t)||e instanceof Date?(cr({value:e,columnType:"dateTime",rowId:o,field:n.field}),e.toLocaleString()):e},filterOperators:$n(!0),renderEditCell:Wn,pastedValueParser:e=>new Date(e)}),fr="__row_group_by_columns_group__",pr="__detail_panel_toggle__";let hr=function(e){return e[e.NONE=0]="NONE",e[e.LEFT=1]="LEFT",e[e.RIGHT=2]="RIGHT",e[e.VIRTUAL=3]="VIRTUAL",e}({});const gr=["formattedValue","colDef","cellMode","row","api","id","value","rowNode","field","hasFocus","tabIndex","isEditable"],mr=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"FooterCell"})({fontWeight:z.typography.fontWeight.medium,color:z.colors.foreground.accent});function Ar(e){const{formattedValue:t}=e,n=(0,x.A)(e,gr),o={classes:se().classes},i=(e=>{const{classes:t}=e;return(0,R.A)({root:["footerCell"]},D,t)})(o);return(0,r.jsx)(mr,(0,y.A)({ownerState:o,className:i.root},n,{children:t}))}const br=o.memo(Ar),vr=["id","value","formattedValue","api","field","row","rowNode","colDef","cellMode","isEditable","hasFocus","tabIndex","hideDescendantCount"];function yr(e){const{value:t,rowNode:n}=e,i=(0,x.A)(e,vr),a=ot(),l=se(),s=(e=>{const{classes:t}=e;return(0,R.A)({root:["booleanCell"]},D,t)})({classes:l.classes}),c=J(a,Bt)>0&&"group"===n.type&&!1===l.treeData,u=o.useMemo(()=>t?l.slots.booleanCellTrueIcon:l.slots.booleanCellFalseIcon,[l.slots.booleanCellFalseIcon,l.slots.booleanCellTrueIcon,t]);return c&&void 0===t?null:(0,r.jsx)(u,(0,y.A)({fontSize:"small",className:s.root,titleAccess:a.current.getLocaleText(t?"booleanCellTrueLabel":"booleanCellFalseLabel"),"data-value":Boolean(t)},i))}const wr=o.memo(yr),Cr=["id","value","formattedValue","api","field","row","rowNode","colDef","cellMode","isEditable","tabIndex","className","hasFocus","isValidating","isProcessingProps","error","onValueChange"];function Sr(e){const{id:t,value:n,field:i,className:a,hasFocus:l,onValueChange:s}=e,c=(0,x.A)(e,Cr),u=ot(),d=o.useRef(null),f=(0,an.A)(),[p,h]=o.useState(n),g=se(),m=(e=>{const{classes:t}=e;return(0,R.A)({root:["editBooleanCell"]},D,t)})({classes:g.classes}),A=o.useCallback(async e=>{const n=e.target.checked;s&&await s(e,n),h(n),await u.current.setEditCellValue({id:t,field:i,value:n},e)},[u,i,t,s]);return o.useEffect(()=>{h(n)},[n]),(0,Ut.A)(()=>{l&&d.current.focus()},[l]),(0,r.jsx)("label",(0,y.A)({htmlFor:f,className:(0,E.A)(m.root,a)},c,{children:(0,r.jsx)(g.slots.baseCheckbox,(0,y.A)({id:f,inputRef:d,checked:Boolean(p),onChange:A,size:"small"},g.slotProps?.baseCheckbox))}))}const xr=["item","applyValue","apiRef","focusElementRef","isFilterActive","headerFilterMenu","clearButton","tabIndex","slotProps"];function Er(e){return"true"===String(e).toLowerCase()||"false"!==String(e).toLowerCase()&&void 0}const Ir=(0,y.A)({},Dn,{type:"boolean",display:"flex",align:"center",headerAlign:"center",renderCell:e=>{if(e.field!==fr&&tr(e.rowNode)){const t=e.aggregation;return t?"footer"===t.position?(0,r.jsx)(br,(0,y.A)({},e)):e.formattedValue:""}return(0,r.jsx)(wr,(0,y.A)({},e))},renderEditCell:e=>(0,r.jsx)(Sr,(0,y.A)({},e)),sortComparator:rn,valueFormatter:(e,t,n,r)=>e?r.current.getLocaleText("booleanCellTrueLabel"):r.current.getLocaleText("booleanCellFalseLabel"),filterOperators:[{value:"is",getApplyFilterFn:e=>{const t=Er(e.value);return void 0===t?null:e=>Boolean(e)===t},InputComponent:function(e){const{item:t,applyValue:n,apiRef:i,focusElementRef:a,headerFilterMenu:l,clearButton:s,tabIndex:c,slotProps:u}=e,d=(0,x.A)(e,xr),[f,p]=o.useState(Er(t.value)),h=se(),g=(0,an.A)(),m=(0,an.A)(),A=h.slotProps?.baseSelect||{},b=A.native??!1,v=h.slotProps?.baseSelectOption||{},w=o.useCallback(e=>{const r=Er(e.target.value);p(r),n((0,y.A)({},t,{value:r}))},[n,t]);o.useEffect(()=>{p(Er(t.value))},[t.value]);const C=u?.root.label??i.current.getLocaleText("filterPanelInputLabel"),S=u?.root.slotProps;return(0,r.jsxs)(o.Fragment,{children:[(0,r.jsxs)(h.slots.baseSelect,(0,y.A)({fullWidth:!0,labelId:g,id:m,label:C,value:void 0===f?"":String(f),onChange:w,native:b,slotProps:{htmlInput:(0,y.A)({ref:a,tabIndex:c},S?.htmlInput)}},A,d,u?.root,{children:[(0,r.jsx)(h.slots.baseSelectOption,(0,y.A)({},v,{native:b,value:"",children:i.current.getLocaleText("filterValueAny")})),(0,r.jsx)(h.slots.baseSelectOption,(0,y.A)({},v,{native:b,value:"true",children:i.current.getLocaleText("filterValueTrue")})),(0,r.jsx)(h.slots.baseSelectOption,(0,y.A)({},v,{native:b,value:"false",children:i.current.getLocaleText("filterValueFalse")}))]})),l,s]})}}],getApplyQuickFilterFn:()=>null,chartable:!1,pastedValueParser:e=>(e=>{switch(e.toLowerCase().trim()){case"true":case"yes":case"1":return!0;case"false":case"no":case"0":case"null":case"undefined":return!1;default:return}})(e)});var kr=function(e){return e.enterKeyDown="enterKeyDown",e.cellDoubleClick="cellDoubleClick",e.printableKeyDown="printableKeyDown",e.deleteKeyDown="deleteKeyDown",e.pasteKeyDown="pasteKeyDown",e}(kr||{}),Rr=function(e){return e.cellFocusOut="cellFocusOut",e.escapeKeyDown="escapeKeyDown",e.enterKeyDown="enterKeyDown",e.tabKeyDown="tabKeyDown",e.shiftTabKeyDown="shiftTabKeyDown",e}(Rr||{}),Mr=function(e){return e.Cell="cell",e.Row="row",e}(Mr||{}),Pr=function(e){return e.Edit="edit",e.View="view",e}(Pr||{}),Br=function(e){return e.Edit="edit",e.View="view",e}(Br||{});function _r(e){return"singleSelect"===e?.type}function Tr(e,t){if(e)return"function"==typeof e.valueOptions?e.valueOptions((0,y.A)({field:e.field},t)):e.valueOptions}function Or(e,t,n){if(void 0===t)return;const r=t.find(t=>{const r=n(t);return String(r)===String(e)});return n(r)}const Dr=["id","value","formattedValue","api","field","row","rowNode","colDef","cellMode","isEditable","tabIndex","className","hasFocus","isValidating","isProcessingProps","error","onValueChange","initialOpen","slotProps"];function Nr(e){const t=se(),{id:n,value:i,field:a,row:l,colDef:s,hasFocus:c,error:u,onValueChange:d,initialOpen:f=t.editMode===Mr.Cell,slotProps:p}=e,h=(0,x.A)(e,Dr),g=ot(),m=o.useRef(null),A=o.useRef(null),[b,v]=o.useState(f),w=(t.slotProps?.baseSelect||{}).native??!1;if((0,Ut.A)(()=>{c&&A.current?.focus()},[c]),!_r(s))return null;const C=Tr(s,{id:n,row:l});if(!C)return null;const S=s.getOptionValue,E=s.getOptionLabel;return C&&s?(0,r.jsx)(t.slots.baseSelect,(0,y.A)({ref:m,value:i,onChange:async e=>{if(!_r(s)||!C)return;v(!1);const t=Or(e.target.value,C,S);d&&await d(e,t),await g.current.setEditCellValue({id:n,field:a,value:t},e)},open:b,onOpen:e=>{(function(e){return"key"in e&&!!e.key})(e)&&"Enter"===e.key||v(!0)},onClose:(e,r)=>{if(t.editMode!==Mr.Row){if("backdropClick"===r||"Escape"===e.key){const t=g.current.getCellParams(n,a);g.current.publishEvent("cellEditStop",(0,y.A)({},t,{reason:"Escape"===e.key?Rr.escapeKeyDown:Rr.cellFocusOut}))}}else v(!1)},error:u,native:w,fullWidth:!0,slotProps:{htmlInput:{ref:A}}},h,p?.root,t.slotProps?.baseSelect,{children:C.map(e=>{const n=S(e);return(0,o.createElement)(t.slots.baseSelectOption,(0,y.A)({},t.slotProps?.baseSelectOption||{},{native:w,key:n,value:n}),E(e))})})):null}const Lr=["item","applyValue","type","apiRef","focusElementRef","tabIndex","isFilterActive","clearButton","headerFilterMenu","slotProps"],Fr=({column:e,OptionComponent:t,getOptionLabel:n,getOptionValue:r,isSelectNative:i,baseSelectOptionProps:a})=>["",...Tr(e)||[]].map(e=>{const l=r(e);let s=n(e);return""===s&&(s=" "),(0,o.createElement)(t,(0,y.A)({},a,{native:i,key:l,value:l}),s)});function Qr(e){const{item:t,applyValue:n,type:i,apiRef:a,focusElementRef:l,tabIndex:s,clearButton:c,headerFilterMenu:u,slotProps:d}=e,f=(0,x.A)(e,Lr),p=t.value??"",h=(0,an.A)(),g=(0,an.A)(),m=se(),A=m.slotProps?.baseSelect?.native??!1,b=a.current.getColumn(t.field),v=b.getOptionValue,w=b.getOptionLabel,C=o.useMemo(()=>Tr(b),[b]),S=o.useCallback(e=>{let r=e.target.value;r=Or(r,C,v),n((0,y.A)({},t,{value:r}))},[C,v,n,t]);if(!b||!_r(b))return null;const E=d?.root.label??a.current.getLocaleText("filterPanelInputLabel");return(0,r.jsxs)(o.Fragment,{children:[(0,r.jsx)(m.slots.baseSelect,(0,y.A)({fullWidth:!0,id:h,label:E,labelId:g,value:p,onChange:S,slotProps:{htmlInput:(0,y.A)({tabIndex:s,ref:l,type:i||"text",placeholder:d?.root.placeholder??a.current.getLocaleText("filterPanelInputPlaceholder")},d?.root.slotProps?.htmlInput)},native:A},m.slotProps?.baseSelect,f,d?.root,{children:Fr({column:b,OptionComponent:m.slots.baseSelectOption,getOptionLabel:w,getOptionValue:v,isSelectNative:A,baseSelectOptionProps:m.slotProps?.baseSelectOption})})),u,c]})}const jr=["item","applyValue","type","apiRef","focusElementRef","slotProps"];const zr=e=>null!=e&&un(e)?e.value:e,$r=(0,y.A)({},Dn,{type:"singleSelect",getOptionLabel:e=>un(e)?e.label:String(e),getOptionValue:e=>un(e)?e.value:e,valueFormatter(e,t,n,r){const o=lr(r,t);if(!_r(n))return"";const i=Tr(n,{id:o,row:t});if(null==e)return"";if(!i)return e;if(!(e=>"object"==typeof e[0])(i))return n.getOptionLabel(e);const a=i.find(t=>n.getOptionValue(t)===e);return a?n.getOptionLabel(a):""},renderEditCell:e=>(0,r.jsx)(Nr,(0,y.A)({},e)),filterOperators:[{value:"is",getApplyFilterFn:e=>null==e.value||""===e.value?null:t=>zr(t)===zr(e.value),InputComponent:Qr},{value:"not",getApplyFilterFn:e=>null==e.value||""===e.value?null:t=>zr(t)!==zr(e.value),InputComponent:Qr},{value:"isAnyOf",getApplyFilterFn:e=>{if(!Array.isArray(e.value)||0===e.value.length)return null;const t=e.value.map(zr);return e=>t.includes(zr(e))},InputComponent:function(e){const{item:t,applyValue:n,type:i,apiRef:a,focusElementRef:l,slotProps:s}=e,c=(0,x.A)(e,jr),u=(0,an.A)(),d=se(),f=a.current.getColumn(t.field),p=f.getOptionValue,h=f.getOptionLabel,g=o.useCallback((e,t)=>p(e)===p(t),[p]),m=o.useMemo(()=>Tr(f)||[],[f]),A=o.useMemo(()=>Array.isArray(t.value)?t.value.reduce((e,t)=>{const n=m.find(e=>p(e)===t);return null!=n&&e.push(n),e},[]):[],[p,t.value,m]),b=o.useCallback((e,r)=>{n((0,y.A)({},t,{value:r.map(p)}))},[n,t,p]);if(!f||!_r(f))return null;const v=d.slots.baseAutocomplete;return(0,r.jsx)(v,(0,y.A)({multiple:!0,options:m,isOptionEqualToValue:g,id:u,value:A,onChange:b,getOptionLabel:h,label:a.current.getLocaleText("filterPanelInputLabel"),placeholder:a.current.getLocaleText("filterPanelInputPlaceholder"),slotProps:{textField:{type:i||"text",inputRef:l}}},c,s?.root))}}],pastedValueParser:(e,t,n)=>{const r=n,o=Tr(r)||[],i=r.getOptionValue;if(o.find(t=>i(t)===e))return e}});var Hr=n(3776);function Gr(e){return 1===e.key.length&&!e.ctrlKey&&!e.metaKey}const Vr=e=>0===e.indexOf("Arrow")||0===e.indexOf("Page")||" "===e||"Home"===e||"End"===e,Wr=e=>"Tab"===e||"Escape"===e;function Ur(e){return(e.ctrlKey||e.metaKey)&&"V"===String.fromCharCode(e.keyCode)&&!e.shiftKey&&!e.altKey}const qr=["open","target","onClose","children","position","className","onExited"],Yr=(0,_.Ay)(qt,{name:"MuiDataGrid",slot:"Menu"})({zIndex:z.zIndex.menu,[`& .${L.menuList}`]:{outline:0}});function Kr(e){const{open:t,target:n,onClose:i,children:a,position:l,className:s,onExited:c}=e,u=(0,x.A)(e,qr),d=ot(),f=se(),p=(e=>{const{classes:t}=e;return(0,R.A)({root:["menu"]},D,t)})(f),h=fe(),g=o.useRef(null);return(0,Ut.A)(()=>{t?g.current=document.activeElement instanceof HTMLElement?document.activeElement:null:(g.current?.focus?.(),g.current=null)},[t]),o.useEffect(()=>{const e=t?"menuOpen":"menuClose";d.current.publishEvent(e,{target:n})},[d,t,n]),(0,r.jsx)(Yr,(0,y.A)({as:f.slots.basePopper,className:(0,E.A)(p.root,s,h),ownerState:f,open:t,target:n,transition:!0,placement:l,onClickAway:e=>{e.target&&(n===e.target||n?.contains(e.target))||i(e)},onExited:c,clickAwayMouseEvent:"onMouseDown",onKeyDown:e=>{Wr(e.key)&&i(e)}},u,f.slotProps?.basePopper,{children:a}))}const Jr=["label","icon","showInMenu","onClick"],Xr=["label","icon","showInMenu","onClick","closeMenuOnClick","closeMenu"],Zr=S((e,t)=>{const n=se();if(!e.showInMenu){const{label:i,icon:a,onClick:l}=e,s=(0,x.A)(e,Jr),c=e=>{l?.(e)};return(0,r.jsx)(n.slots.baseIconButton,(0,y.A)({size:"small",role:"menuitem","aria-label":i},s,{onClick:c},n.slotProps?.baseIconButton,{ref:t,children:o.cloneElement(a,{fontSize:"small"})}))}const{label:i,icon:a,onClick:l,closeMenuOnClick:s=!0,closeMenu:c}=e,u=(0,x.A)(e,Xr);return(0,r.jsx)(n.slots.baseMenuItem,(0,y.A)({ref:t},u,{onClick:e=>{l?.(e),s&&c?.()},iconStart:a,children:i}))}),eo=["api","colDef","id","hasFocus","isEditable","field","value","formattedValue","row","rowNode","cellMode","tabIndex","position","onMenuOpen","onMenuClose","children","suppressChildrenValidation"];function to(e){const{id:t,hasFocus:n,tabIndex:i,position:a="bottom-end",onMenuOpen:l,onMenuClose:s,children:c,suppressChildrenValidation:u}=e,d=(0,x.A)(e,eo),[f,p]=o.useState(-1),[h,g]=o.useState(!1),m=ot(),A=o.useRef(null),b=o.useRef(null),v=o.useRef(!1),w=o.useRef({}),C=(0,Hr.I)(),S=(0,an.A)(),E=(0,an.A)(),I=se(),k=m.current.getRowParams(t),R=[];o.Children.forEach(c,e=>{o.isValidElement(e)&&(e.type===o.Fragment?o.Children.forEach(e.props.children,e=>{o.isValidElement(e)&&R.push(e)}):e.type===Zr||u?R.push(e):"function"==typeof e.type?e.type.name:e.type)});const M=R.filter(e=>!e.props.showInMenu),P=R.filter(e=>e.props.showInMenu),B=M.length+(P.length?1:0);o.useLayoutEffect(()=>{n||Object.entries(w.current).forEach(([e,t])=>{t?.stop({},()=>{delete w.current[e]})})},[n]),o.useEffect(()=>{f<0||!A.current||f>=A.current.children.length||A.current.children[f].focus({preventScroll:!0})},[f]);const _=R.findIndex(e=>!e.props.disabled);o.useEffect(()=>{n&&-1===f&&p(_),n||(p(-1),v.current=!1)},[n,f,_]),o.useEffect(()=>{f>=B&&p(B-1)},[f,B]);const T=e=>{s&&!s(k,e)||g(!1)},O=e=>t=>{w.current[e]=t},D=(e,t)=>n=>{p(e),v.current=!0,t&&t(n)},N=B>0?{role:"menu",onKeyDown:e=>{if(B<=1)return;const t=(e,n)=>{if(e<0||e>R.length)return e;const r=("left"===n?-1:1)*(C?-1:1);return R[e+r]?.props.disabled?t(e+r,n):e+r};let n=f;"ArrowRight"===e.key?n=t(f,"right"):"ArrowLeft"===e.key&&(n=t(f,"left")),n<0||n>=B||n!==f&&(e.preventDefault(),e.stopPropagation(),p(n))}}:void 0;return(0,r.jsxs)("div",(0,y.A)({ref:A,tabIndex:-1,className:L.actionsCell},N,d,{children:[M.map((e,t)=>o.cloneElement(e,{key:t,touchRippleRef:O(t),onClick:D(t,e.props.onClick),tabIndex:f===t?i:-1})),P.length>0&&E&&(0,r.jsx)(I.slots.baseIconButton,(0,y.A)({ref:b,id:E,"aria-label":m.current.getLocaleText("actionsCellMore"),"aria-haspopup":"menu","aria-expanded":h,"aria-controls":h?S:void 0,role:"menuitem",size:"small",onClick:e=>{e.stopPropagation(),e.preventDefault(),h?T(e):(e=>{l&&!l(k,e)||(g(!0),p(B-1),v.current=!0)})(e)},touchRippleRef:O(E),tabIndex:f===M.length?i:-1},I.slotProps?.baseIconButton,{children:(0,r.jsx)(I.slots.moreActionsIcon,{fontSize:"small"})})),P.length>0&&(0,r.jsx)(Kr,{open:h,target:b.current,position:a,onClose:T,children:(0,r.jsx)(I.slots.baseMenuList,{id:S,className:L.menuList,"aria-labelledby":E,autoFocusItem:!0,children:P.map((e,t)=>o.cloneElement(e,{key:t,closeMenu:T}))})})]}))}function no(e){const{colDef:t,id:n}=e,o=ot();if(!(e=>"function"==typeof e.getActions)(t))throw new Error("MUI X: Missing the `getActions` property in the `GridColDef`.");const i=t.getActions(o.current.getRowParams(n));return(0,r.jsx)(to,(0,y.A)({suppressChildrenValidation:!0},e,{children:i}))}const ro="actions",oo=(0,y.A)({},Dn,{sortable:!1,filterable:!1,aggregable:!1,chartable:!1,width:100,display:"flex",align:"center",headerAlign:"center",headerName:"",disableColumnMenu:!0,disableExport:!0,renderCell:e=>(0,r.jsx)(no,(0,y.A)({},e)),getApplyQuickFilterFn:()=>null}),io=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"LongTextCell"})({display:"flex",alignItems:"center",width:"100%",height:"100%",position:"relative"}),ao=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"LongTextCellContent"})({overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",flex:1}),lo=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"LongTextCellPopperContent"})(({theme:e})=>(0,y.A)({},e.typography.body2,{letterSpacing:"normal",paddingBlock:15.5,paddingInline:9,maxHeight:156,overflow:"auto",whiteSpace:"pre-wrap",wordBreak:"break-word",width:"var(--_width)",border:`1px solid ${(e.vars||e).palette.divider}`,boxSizing:"border-box"})),so=(0,_.Ay)("button",{name:"MuiDataGrid",slot:"LongTextCellCornerButton"})(({theme:e})=>({lineHeight:0,position:"absolute",bottom:1,right:0,border:"1px solid",color:(e.vars||e).palette.text.secondary,borderColor:(e.vars||e).palette.divider,backgroundColor:(e.vars||e).palette.background.paper,borderRadius:0,fontSize:"0.875rem",padding:2,"&:focus-visible":{outline:"none"},"&:hover":{backgroundColor:(e.vars||e).palette.background.paper,color:(e.vars||e).palette.text.primary},[`&.${L.longTextCellExpandButton}`]:{right:-9,opacity:0,[`.${L.longTextCell}:hover &, .${L.longTextCell}.Mui-focused &`]:{opacity:1}},[`&.${L.longTextCellCollapseButton}`]:{bottom:2,right:2,border:"none"}})),co=(0,_.Ay)(qt,{name:"MuiDataGrid",slot:"LongTextCellPopper"})(({theme:e})=>({zIndex:z.zIndex.menu,background:(e.vars||e).palette.background.paper,"&[data-popper-reference-hidden]":{visibility:"hidden",pointerEvents:"none"}}));function uo(e){const{id:t,value:n="",colDef:i,hasFocus:a,slotProps:l,renderContent:s}=e,c=`${t}-${i.field}-longtext-popup`,u=se(),d=ot(),f=(e=>{const{classes:t}=e;return(0,R.A)({root:["longTextCell"],content:["longTextCellContent"],expandButton:["longTextCellExpandButton"],collapseButton:["longTextCellCollapseButton"],popup:["longTextCellPopup"],popperContent:["longTextCellPopperContent"]},D,t)})(u),p=J(d,ft),[h,g]=o.useState(!1),m=o.useRef(null),A=o.useRef(null);return o.useEffect(()=>{a&&!h&&A.current&&A.current!==document.activeElement&&A.current.focus(),a||g(!1)},[a,h]),(0,r.jsxs)(io,(0,y.A)({ref:m},l?.root,{className:(0,E.A)(f.root,l?.root?.className,a&&"Mui-focused"),children:[(0,r.jsx)(ao,(0,y.A)({},l?.content,{className:(0,E.A)(f.content,l?.content?.className),children:n})),(0,r.jsx)(so,(0,y.A)({ref:A,"aria-label":`${n}, ${d.current.getLocaleText("longTextCellExpandLabel")}`,"aria-haspopup":"dialog","aria-controls":h?c:void 0,"aria-expanded":h,"aria-keyshortcuts":"Space",tabIndex:0},l?.expandButton,{className:(0,E.A)(f.expandButton,l?.expandButton?.className),onClick:e=>{0!==e.detail&&(e.stopPropagation(),g(!0))},onKeyDown:e=>{" "!==e.key||e.shiftKey||(e.preventDefault(),e.stopPropagation(),g(e=>!e)),"Escape"===e.key&&h&&(e.stopPropagation(),g(!1))},children:(0,r.jsx)(u.slots.longTextCellExpandIcon,{fontSize:"inherit"})})),(0,r.jsx)(co,(0,y.A)({id:c,role:"dialog","aria-label":i.headerName||i.field,as:u.slots.basePopper,ownerState:u,open:h,target:m.current,placement:"bottom-start",onClickAway:()=>{g(!1)},clickAwayMouseEvent:"onMouseDown",flip:!0,material:{container:m.current?.closest('[role="row"]'),modifiers:[{name:"offset",options:{offset:[-10,-p]}}]}},l?.popper,{className:(0,E.A)(f.popup,l?.popper?.className),children:(0,r.jsxs)(lo,(0,y.A)({tabIndex:-1,onKeyDown:e=>{"Escape"===e.key&&(e.stopPropagation(),g(!1),d.current.getCellElement(t,i.field)?.focus())}},l?.popperContent,{className:(0,E.A)(f.popperContent,l?.popperContent?.className),style:(0,y.A)({"--_width":`${i.computedWidth}px`},l?.popperContent?.style),children:[s?s(n):n,(0,r.jsx)(so,(0,y.A)({"aria-label":d.current.getLocaleText("longTextCellCollapseLabel"),"aria-keyshortcuts":"Escape"},l?.collapseButton,{className:(0,E.A)(f.collapseButton,l?.collapseButton?.className),onClick:e=>{e.stopPropagation(),g(!1),d.current.getCellElement(t,i.field)?.focus()},children:(0,r.jsx)(u.slots.longTextCellCollapseIcon,{fontSize:"inherit"})}))]}))}))]}))}const fo=e=>{const{classes:t}=e;return(0,R.A)({root:["editLongTextCell"],value:["editLongTextCellValue"],popup:["editLongTextCellPopup"],popperContent:["editLongTextCellPopperContent"],textarea:["editLongTextCellTextarea"]},D,t)},po=(0,_.Ay)(qt,{name:"MuiDataGrid",slot:"EditLongTextCellTextarea"})(({theme:e})=>(0,y.A)({width:"100%",padding:0},e.typography.body2,{letterSpacing:"normal",outline:"none",background:"transparent",border:"none",resize:"vertical"})),ho=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"EditLongTextCell"})({display:"flex",alignItems:"center",width:"100%",height:"100%",position:"relative"}),go=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"EditLongTextCellValue"})({overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",width:"100%",paddingInline:10}),mo=(0,_.Ay)(qt,{name:"MuiDataGrid",slot:"EditLongTextCellPopper"})(({theme:e})=>({zIndex:z.zIndex.menu,background:(e.vars||e).palette.background.paper,"&[data-popper-reference-hidden]":{opacity:0}})),Ao=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"EditLongTextCellPopperContent"})(({theme:e})=>(0,y.A)({},e.typography.body2,{letterSpacing:"normal",paddingBlock:15.5,paddingInline:9,height:"max-content",overflow:"auto",whiteSpace:"pre-wrap",wordBreak:"break-word",width:"var(--_width)",border:`1px solid ${(e.vars||e).palette.divider}`,boxShadow:(e.vars||e).shadows[4],boxSizing:"border-box"}));function bo(e){const{id:t,value:n,field:i,colDef:a,hasFocus:l,cellMode:s,slotProps:c}=e,u=se(),d=ot(),f=fo(u),p=J(d,ft),[h,g]=o.useState(n),[m,A]=o.useState(null),b=d.current.unstable_getEditCellMeta(t,i),v=`${t}-${i}-longtext-edit-popup`,w=l&&Boolean(m);return o.useEffect(()=>{"debouncedSetEditCellValue"!==b?.changeReason&&g(n)},[b,n]),(0,r.jsxs)(ho,(0,y.A)({tabIndex:"edit"===s&&"row"===u.editMode?0:void 0,ref:A,"aria-controls":w?v:void 0,"aria-expanded":w},c?.root,{className:(0,E.A)(f.root,c?.root?.className),children:[(0,r.jsx)(go,(0,y.A)({},c?.value,{className:(0,E.A)(f.value,c?.value?.className),children:h})),(0,r.jsx)(mo,(0,y.A)({as:u.slots.basePopper,ownerState:u,id:v,role:"dialog","aria-label":a.headerName||i,open:w,target:m,placement:"bottom-start",flip:!0,material:{container:m?.closest('[role="row"]'),modifiers:[{name:"offset",options:{offset:[-1,-p]}}]}},c?.popper,{className:(0,E.A)(f.popup,c?.popper?.className),children:(0,r.jsx)(Ao,(0,y.A)({},c?.popperContent,{className:(0,E.A)(f.popperContent,c?.popperContent?.className),style:{"--_width":`${a.computedWidth}px`},children:(0,r.jsx)(vo,(0,y.A)({},e,{valueState:h,setValueState:g}))}))}))]}))}function vo(e){const{id:t,field:n,colDef:i,debounceMs:a=200,onValueChange:l,valueState:s,setValueState:c,hasFocus:u,slotProps:d}=e,f=o.useRef(null),p=ot(),h=se(),g=fo(h);(0,Ut.A)(()=>{if(u&&f.current){f.current.focus({preventScroll:!0});const e=f.current.value.length;f.current.setSelectionRange(e,e)}},[u]);const m=o.useCallback(async e=>{const r=e.target.value,o=p.current.getColumn(n);let i=r;o.valueParser&&(i=o.valueParser(r,p.current.getRow(t),o,p)),c(i),p.current.setEditCellValue({id:t,field:n,value:i,debounceMs:a,unstable_skipValueParser:!0},e),l&&await l(e,r)},[p,a,n,t,l,c]),A=o.useCallback(e=>{"Enter"===e.key&&e.shiftKey&&e.stopPropagation(),"cell"===h.editMode&&"Escape"===e.key&&p.current.stopCellEditMode({id:t,field:n,ignoreModifications:!0})},[p,n,t,h.editMode]);return(0,r.jsx)(po,(0,y.A)({ref:f,as:h.slots.baseTextarea,ownerState:h,"aria-label":i.headerName||n,value:s??"",onChange:m,onKeyDown:A},d?.textarea,{className:(0,E.A)(g.textarea,d?.textarea?.className)}))}const yo=(0,y.A)({},Dn,{type:"longText",display:"flex",renderCell:e=>(0,r.jsx)(uo,(0,y.A)({},e)),renderEditCell:e=>(0,r.jsx)(bo,(0,y.A)({},e))}),wo=ke(e=>e.headerFiltering),Co=Ee(wo,e=>e?.enabled??!1),So=Ee(wo,e=>e.editing),xo=Ee(wo,e=>e.menuOpen),Eo=ke(e=>e.columnGrouping),Io=Ie(Eo,e=>e?.unwrappedGroupingModel??{}),ko=Ie(Eo,e=>e?.lookup??{}),Ro=Ie(Eo,e=>e?.headerStructure??[]),Mo=Ee(Eo,e=>e?.maxDepth??0),Po=["maxWidth","minWidth","width","flex"],Bo={string:Dn,number:Ln,date:ur,dateTime:dr,boolean:Ir,singleSelect:$r,[ro]:oo,custom:Dn,longText:yo},_o=(e,t)=>{const n={};let r=0,o=0;const i=[];e.orderedFields.forEach(t=>{let a=e.lookup[t],l=0,s=!1;!1!==e.columnVisibilityModel[t]&&(a.flex&&a.flex>0?(r+=a.flex,s=!0):l=fn(a.width||Dn.width,a.minWidth||Dn.minWidth,a.maxWidth||Dn.maxWidth),o+=l),a.computedWidth!==l&&(a=(0,y.A)({},a,{computedWidth:l})),s&&i.push(a),n[t]=a});const a=void 0===t?0:t.viewportOuterSize.width-(t.hasScrollY?t.scrollbarSize:0),l=Math.max(a-o,0);if(r>0&&a>0){const e=function({initialFreeSpace:e,totalFlexUnits:t,flexColumns:n}){const r=new Set(n.map(e=>e.field)),o={all:{},frozenFields:[],freeze:e=>{const t=o.all[e];t&&!0!==t.frozen&&(o.all[e].frozen=!0,o.frozenFields.push(e))}};return function i(){if(o.frozenFields.length===r.size)return;const a={min:{},max:{}};let l=e,s=t,c=0;o.frozenFields.forEach(e=>{l-=o.all[e].computedWidth,s-=o.all[e].flex});for(let e=0;e<n.length;e+=1){const t=n[e];if(o.all[t.field]&&!0===o.all[t.field].frozen)continue;let r=l/s*t.flex;r<t.minWidth?(c+=t.minWidth-r,r=t.minWidth,a.min[t.field]=!0):r>t.maxWidth&&(c+=t.maxWidth-r,r=t.maxWidth,a.max[t.field]=!0),o.all[t.field]={frozen:!1,computedWidth:r,flex:t.flex}}c<0?Object.keys(a.max).forEach(e=>{o.freeze(e)}):c>0?Object.keys(a.min).forEach(e=>{o.freeze(e)}):n.forEach(({field:e})=>{o.freeze(e)}),i()}(),o.all}({initialFreeSpace:l,totalFlexUnits:r,flexColumns:i});Object.keys(e).forEach(t=>{n[t]=(0,y.A)({},n[t],{computedWidth:e[t].computedWidth})})}return(0,y.A)({},e,{lookup:n})};function To(e){let t=Bo.string;return e&&Bo[e]&&(t=Bo[e]),t}const Oo=({apiRef:e,columnsToUpsert:t,initialState:n,columnVisibilityModel:r=He(e),keepOnlyColumnsToUpsert:o=!1,updateInitialVisibilityModel:i=!1})=>{const a=!e.current.state.columns;let l;if(a)l={orderedFields:[],lookup:{},columnVisibilityModel:r,initialColumnVisibilityModel:r};else{const t=Qe(e);l={orderedFields:o?[]:[...t.orderedFields],lookup:o?{}:(0,y.A)({},t.lookup),columnVisibilityModel:r,initialColumnVisibilityModel:i?r:t.initialColumnVisibilityModel}}const s={};if(o&&!a)for(const e in l.lookup)Object.prototype.hasOwnProperty.call(l.lookup,e)&&(s[e]=!1);t.forEach(e=>{const{field:t}=e;s[t]=!0;let n=l.lookup[t];null==n?(n=(0,y.A)({},To(e.type),{field:t,hasBeenResized:!1}),l.orderedFields.push(t)):o&&l.orderedFields.push(t),n&&n.type!==e.type&&(n=(0,y.A)({},To(e.type),{field:t}));let r=n.hasBeenResized;Po.forEach(t=>{void 0!==e[t]&&(r=!0,-1===e[t]&&(e[t]=1/0))});const i=(0,y.A)({},To(e.type),{hasBeenResized:r,field:t});let a;for(a in e)void 0!==e[a]&&"field"!==a&&(i[a]=e[a]);l.lookup[t]=(0,Wt.A)(n,i)}),o&&!a&&Object.keys(l.lookup).forEach(e=>{s[e]||delete l.lookup[e]});const c=((e,t)=>{if(!t)return e;const{orderedFields:n=[],dimensions:r={}}=t,o=Object.keys(r);if(0===o.length&&0===n.length)return e;const i={},a=[];for(let t=0;t<n.length;t+=1){const r=n[t];e.lookup[r]&&(i[r]=!0,a.push(r))}const l=0===a.length?e.orderedFields:[...a,...e.orderedFields.filter(e=>!i[e])],s=(0,y.A)({},e.lookup);for(let e=0;e<o.length;e+=1){const t=o[e],n=(0,y.A)({},s[t],{hasBeenResized:!0});Object.entries(r[t]).forEach(([e,t])=>{n[e]=-1===t?1/0:t}),s[t]=n}return(0,y.A)({},e,{orderedFields:l,lookup:s})})(e.current.unstable_applyPipeProcessors("hydrateColumns",l),n);return _o(c,e.current.getRootDimensions?.()??void 0)};function Do(e,t){if(t.listView)return 0;const n=Be(e),r=Mo(e),o=Co(e);return Math.floor(t.columnHeaderHeight*n)+Math.floor((t.columnGroupHeaderHeight??t.columnHeaderHeight)*n)*r+(o?Math.floor((t.headerFilterHeight??t.columnHeaderHeight)*n):0)}const No=ke(e=>e.rowsMeta),Lo=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"ScrollArea",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.scrollArea,t[`scrollArea--${n.scrollDirection}`]]}})(()=>({position:"absolute",zIndex:101,[`&.${L["scrollArea--left"]}`]:{top:0,left:0,width:20,bottom:0},[`&.${L["scrollArea--right"]}`]:{top:0,right:0,width:20,bottom:0},[`&.${L["scrollArea--up"]}`]:{top:0,left:0,right:0,height:20},[`&.${L["scrollArea--down"]}`]:{bottom:0,left:0,right:0,height:20}})),Fo=Ee(ut,(e,t)=>"left"===t?e.leftPinnedWidth:"right"===t?e.rightPinnedWidth+(e.hasScrollX?e.scrollbarSize:0):0);function Qo(e){const{scrollDirection:t,scrollPosition:n}=e,i=o.useRef(null),a=ot(),l=(0,Vt.A)(),s=J(a,Be),c=J(a,dt),u=J(a,Fo,t),d=se(),f=Do(a,d),p=Math.floor(d.columnHeaderHeight*s),h=(0,y.A)({height:p,top:f-p},"left"===t?{left:u}:{},"right"===t?{right:u}:{}),g=(0,Nt.A)(e=>{let r;if(e.preventDefault(),"left"===t)r=e.clientX-i.current.getBoundingClientRect().right;else{if("right"!==t)throw new Error("MUI X: Wrong drag direction");r=Math.max(1,e.clientX-i.current.getBoundingClientRect().left)}r=1.5*(r-1)+1,l.start(0,()=>{a.current.scroll({left:n.current.left+r,top:n.current.top})})});return(0,r.jsx)(zo,(0,y.A)({},e,{ref:i,getCanScrollMore:()=>{const e=ut(a);if("left"===t)return n.current.left>0;if("right"===t){const t=c-e.viewportInnerSize.width;return n.current.left<t}return!1},style:h,handleDragOver:g}))}function jo(e){const{scrollDirection:t,scrollPosition:n}=e,i=o.useRef(null),a=ot(),l=(0,Vt.A)(),s=J(a,No),c=se(),u=Do(a,c),d={top:"up"===t?u:void 0,bottom:"down"===t?0:void 0},f=(0,Nt.A)(e=>{let r;if(e.preventDefault(),"up"===t)r=e.clientY-i.current.getBoundingClientRect().bottom;else{if("down"!==t)throw new Error("MUI X: Wrong drag direction");r=Math.max(1,e.clientY-i.current.getBoundingClientRect().top)}r=1.5*(r-1)+1,l.start(0,()=>{a.current.scroll({left:n.current.left,top:n.current.top+r})})});return(0,r.jsx)(zo,(0,y.A)({},e,{ref:i,getCanScrollMore:()=>{const e=ut(a);if("up"===t)return n.current.top>0;if("down"===t){const t=(s.currentPageTotalHeight||0)-e.viewportInnerSize.height-(e.hasScrollX?e.scrollbarSize:0);return n.current.top<t}return!1},style:d,handleDragOver:f}))}const zo=S(function(e,t){const{scrollDirection:n,getCanScrollMore:i,style:a,handleDragOver:l}=e,s=ot(),[c,u]=o.useState(i),d=se(),f=(0,y.A)({},d,{scrollDirection:n}),p=(e=>{const{scrollDirection:t,classes:n}=e,r={root:["scrollArea",`scrollArea--${t}`]};return(0,R.A)(r,D,n)})(f);return $t(s,"scrollPositionChange",()=>{u(i)}),c?(0,r.jsx)(Lo,{ref:t,className:p.root,ownerState:f,onDragOver:l,style:a}):null}),$o=B(function(e){const t=ot(),[n,i]=o.useState("none");return $t(t,"columnHeaderDragStart",()=>i("horizontal")),$t(t,"columnHeaderDragEnd",()=>i("none")),$t(t,"rowDragStart",()=>i("vertical")),$t(t,"rowDragEnd",()=>i("none")),"none"===n?null:"horizontal"===n?(0,r.jsx)(Qo,(0,y.A)({},e)):(0,r.jsx)(jo,(0,y.A)({},e))});function Ho(e){for(const t in e)return!1;return!0}const Go=ke(e=>e.sorting),Vo=Ee(Go,e=>e.sortedRows),Wo=Ie(Vo,Et,It,(e,t,n)=>e.reduce((e,r)=>{const o=t[r];if(o)e.push({id:r,model:o});else{const t=n[r];t&&tr(t)&&e.push({id:r,model:{[qn]:r}})}return e},[])),Uo=Ee(Go,e=>e.sortModel),qo=Ie(Uo,e=>e.reduce((t,n,r)=>(t[n.field]={sortDirection:n.sort,sortIndex:e.length>1?r+1:void 0},t),{})),Yo=(Ie(Vo,e=>e.reduce((e,t,n)=>(e[t]=n,e),Object.create(null))),ke(e=>e.filter)),Ko=Ee(Yo,e=>e.filterModel),Jo=Ee(Ko,e=>e.quickFilterValues),Xo=ke(e=>e.visibleRowsLookup),Zo=Ee(Yo,e=>e.filteredRowsLookup),ei=(Ee(Yo,e=>e.filteredChildrenCountLookup),Ee(Yo,e=>e.filteredDescendantCountLookup),Ie(Xo,Wo,(e,t)=>Ho(e)?t:t.filter(t=>!1!==e[t.id]))),ti=Ie(ei,e=>e.map(e=>e.id)),ni=Ie(Zo,Wo,(e,t)=>Ho(e)?t:t.filter(t=>!1!==e[t.id])),ri=Ie(ni,e=>e.map(e=>e.id)),oi=(Ie(ti,It,(e,t)=>{const n={};let r=0;return e.reduce((e,o)=>{const i=t[o];return n[i.depth]||(n[i.depth]=0),i.depth>r&&(n[i.depth]=0),r=i.depth,n[i.depth]+=1,e[o]=n[i.depth],e},{})}),Ee(Ie(ni,It,Bt,(e,t,n)=>n<2?[e]:e.reduce((e,n)=>{const r=t[n.id]?.depth;return void 0===r||(e[r]||(e[r]=[]),e[r].push(n)),e},[[]])),e=>e[0]??[])),ii=Ee(ei,e=>e.length),ai=Ee(oi,e=>e.length),li=Ee(ni,e=>e.length),si=(Ee(li,ai,(e,t)=>e-t),Ie(Ko,ze,(e,t)=>e.items?.filter(e=>{if(!e.field)return!1;const n=t[e.field];if(!n?.filterOperators||0===n?.filterOperators?.length)return!1;const r=n.filterOperators.find(t=>t.value===e.operator);if(!r)return!1;const o=Array.isArray(e.value)?e.value.length>0:null!=e.value&&""!==e.value?.toString();return!r.InputComponent||o}))),ci=Ie(si,e=>e.reduce((e,t)=>(e[t.field]?e[t.field].push(t):e[t.field]=[t],e),{})),ui=Ie(ti,e=>e.reduce((e,t,n)=>(e[t]=n,e),Object.create(null))),di=ke(e=>e.pivoting),fi=Ee(di,e=>e?.active),pi=new Map,hi=Ee(di,e=>e?.initialColumns||pi),gi=(e,t)=>{const n=J(e,Ct),r=J(e,ii),o=J(e,Dt),i=J(e,Ve),a=0===n&&0===o,l=J(e,St),s=J(e,fi),c=!l&&a,u=!l&&n>0&&0===r;let d=null,f=null;return c&&(d="noRowsOverlay"),!l&&0===i.length&&(d="noColumnsOverlay"),c&&s&&(d="emptyPivotOverlay"),u&&(d="noResultsOverlay"),l&&(d="loadingOverlay",f=t.slotProps?.loadingOverlay?.[a?"noRowsVariant":"variant"]??(a?"skeleton":"linear-progress")),{overlayType:d,loadingOverlayVariant:f}},mi=ke(e=>e.focus),Ai=Ee(mi,e=>e.cell),bi=Ee(mi,e=>e.columnHeader),vi=(Ee(mi,e=>e.columnHeaderFilter),Ee(mi,e=>e.columnGroupHeader)),yi=ke(e=>e.tabIndex),wi=Ee(yi,e=>e.cell),Ci=Ee(yi,e=>e.columnHeader),Si=(Ee(yi,e=>e.columnHeaderFilter),Ee(yi,e=>e.columnGroupHeader)),xi=ke(e=>e.columnMenu),Ei=B(function(){const e=Z(),t=se(),n=J(e,Ve),o=J(e,ci),i=J(e,qo),a=J(e,Ci),l=J(e,()=>null===wi(e)),s=J(e,Si),c=J(e,bi),u=J(e,vi),d=J(e,Mo),f=J(e,xi),p=J(e,He),h=J(e,Ro),g=!(null===s&&null===a&&l),m=e.current.columnHeadersContainerRef;return(0,r.jsx)(t.slots.columnHeaders,(0,y.A)({ref:m,visibleColumns:n,filterColumnLookup:o,sortColumnLookup:i,columnHeaderTabIndexState:a,columnGroupHeaderTabIndexState:s,columnHeaderFocus:c,columnGroupHeaderFocus:u,headerGroupingMaxDepth:d,columnMenuState:f,columnVisibility:p,columnGroupsHeaderStructure:h,hasOtherElementInTabSequence:g},t.slotProps?.columnHeaders))}),Ii=(0,_.Ay)("div",{slot:"internal",shouldForwardProp:void 0})({position:"absolute",top:"var(--DataGrid-headersTotalHeight)",left:0,width:"calc(100% - (var(--DataGrid-hasScrollY) * var(--DataGrid-scrollbarSize)))"}),ki=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"Main",overridesResolver:(e,t)=>{const{ownerState:n,loadingOverlayVariant:r,overlayType:o}=e,i="skeleton"===r||"noColumnsOverlay"===o;return[t.main,n.hasPinnedRight&&t["main--hasPinnedRight"],i&&t["main--hiddenContent"]]}})({flexGrow:1,position:"relative",overflow:"hidden",display:"flex",flexDirection:"column"}),Ri=S((e,t)=>{const{ownerState:n}=e,o=se(),i=ue().hooks.useGridAriaAttributes();return(0,r.jsxs)(ki,(0,y.A)({ownerState:n,className:e.className,tabIndex:-1},i,o.slotProps?.main,{ref:t,children:[(0,r.jsx)(Ii,{role:"presentation","data-id":"gridPanelAnchor"}),e.children]}))}),Mi=(0,_.Ay)("div",{slot:"internal",shouldForwardProp:void 0})({position:"sticky",zIndex:40,top:0});function Pi(e){const t=(0,R.A)({root:["topContainer"]},D,{});return(0,r.jsx)(Mi,(0,y.A)({},e,{className:(0,E.A)(t.root,L["container--top"]),role:"presentation"}))}var Bi=n(1539);const _i=(0,Bi.A)("div",{name:"MuiDataGrid",slot:"VirtualScrollerContent",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.virtualScrollerContent,n.overflowedContent&&t["virtualScrollerContent--overflowed"]]}})({}),Ti=S(function(e,t){const n=se(),o=!n.autoHeight&&"auto"===e.style?.minHeight,i=((e,t)=>{const{classes:n}=e,r={root:["virtualScrollerContent",t&&"virtualScrollerContent--overflowed"]};return(0,R.A)(r,D,n)})(n,o),a={classes:n.classes,overflowedContent:o};return(0,r.jsx)(_i,(0,y.A)({},e,{ownerState:a,className:(0,E.A)(i.root,e.className),ref:t}))}),Oi=(0,_.Ay)("div",{slot:"internal",shouldForwardProp:void 0})({display:"flex",flexDirection:"row",width:"var(--DataGrid-rowWidth)",boxSizing:"border-box"}),Di=(0,_.Ay)("div",{slot:"internal",shouldForwardProp:void 0})({position:"sticky",height:"100%",boxSizing:"border-box",borderTop:"1px solid var(--rowBorderColor)",backgroundColor:z.cell.background.pinned}),Ni=(0,_.Ay)(Di,{slot:"internal"})({left:0}),Li=(0,_.Ay)(Di,{slot:"internal"})({right:0}),Fi=(0,_.Ay)("div",{slot:"internal",shouldForwardProp:void 0})({flexGrow:1,borderTop:"1px solid var(--rowBorderColor)"}),Qi=B(function({rowsLength:e}){const t=ot(),{viewportOuterSize:n,minimumSize:o,hasScrollX:i,hasScrollY:a,scrollbarSize:l,leftPinnedWidth:s,rightPinnedWidth:c}=J(t,ut),u=i?l:0,d=n.height-o.height>0;return 0!==u||d?(0,r.jsxs)(Oi,{className:L.filler,role:"presentation",style:{height:u,"--rowBorderColor":0===e?"transparent":"var(--DataGrid-rowBorderColor)"},children:[s>0&&(0,r.jsx)(Ni,{className:L["filler--pinnedLeft"],style:{width:s}}),(0,r.jsx)(Fi,{}),c>0&&(0,r.jsx)(Li,{className:L["filler--pinnedRight"],style:{width:c+(a?l:0)}})]}):null}),ji=(0,Bi.A)("div",{name:"MuiDataGrid",slot:"VirtualScrollerRenderZone"})({position:"absolute",display:"flex",flexDirection:"column"}),zi=S(function(e,t){const n=se(),o=(e=>{const{classes:t}=e;return(0,R.A)({root:["virtualScrollerRenderZone"]},D,t)})(n);return(0,r.jsx)(ji,(0,y.A)({ownerState:n},e,{className:(0,E.A)(o.root,e.className),ref:t}))});var $i=n(7919);const Hi="calc(max(var(--DataGrid-scrollbarSize), 14px))",Gi=(0,_.Ay)("div",{slot:"internal",shouldForwardProp:void 0})({position:"absolute",display:"inline-block",zIndex:60,"&:hover":{zIndex:70},"--size":Hi}),Vi=(0,_.Ay)(Gi,{slot:"internal"})({width:"var(--size)",height:"calc(var(--DataGrid-hasScrollY) * (100% - var(--DataGrid-headersTotalHeight) - var(--DataGrid-hasScrollX) * var(--DataGrid-scrollbarSize)))",overflowY:"auto",overflowX:"hidden",outline:0,"& > div":{width:"var(--size)"},top:"var(--DataGrid-headersTotalHeight)",right:0}),Wi=(0,_.Ay)(Gi,{slot:"internal"})({width:"calc(var(--DataGrid-hasScrollX) * (100% - var(--DataGrid-hasScrollY) * var(--DataGrid-scrollbarSize)))",height:"var(--size)",overflowY:"hidden",overflowX:"auto",outline:0,"& > div":{height:"var(--size)"},bottom:0}),Ui=(0,_.Ay)(Gi,{slot:"internal"})({width:"var(--size)",height:"var(--size)",right:0,bottom:0,overflow:"scroll","@media print":{display:"none"}}),qi=S(function(e,t){const n=Z(),i=se(),a=o.useRef(!1),l=o.useRef(0),s=o.useRef(null),c=((e,t)=>{const{classes:n}=e,r={root:["scrollbar",`scrollbar--${t}`],content:["scrollbarContent"]};return(0,R.A)(r,D,n)})(i,e.position),u=J(n,ut),d="vertical"===e.position?"height":"width",f="vertical"===e.position?"scrollTop":"scrollLeft",p="vertical"===e.position?"top":"left",h="horizontal"===e.position?u.minimumSize.width:u.minimumSize.height-u.headersTotalHeight,g=(0,Nt.A)(()=>{const t=s.current,n=e.scrollPosition.current;t&&n[p]!==l.current&&(l.current=n[p],a.current?a.current=!1:(a.current=!0,t[f]=e.scrollPosition.current[p]))}),m=(0,Nt.A)(()=>{const e=n.current.virtualScrollerRef.current,t=s.current;t&&(a.current?a.current=!1:(a.current=!0,e[f]=t[f]))});(0,$i.A)(()=>{const e=n.current.virtualScrollerRef.current,t=s.current,r={passive:!0};return e.addEventListener("scroll",g,r),t.addEventListener("scroll",m,r),()=>{e.removeEventListener("scroll",g,r),t.removeEventListener("scroll",m,r)}});const A="vertical"===e.position?Vi:Wi,b=o.useMemo(()=>({[d]:`${h}px`}),[d,h]);return(0,r.jsx)(A,{ref:(0,I.A)(t,s),className:c.root,tabIndex:-1,"aria-hidden":"true",onFocus:e=>{e.target.blur()},children:(0,r.jsx)("div",{className:c.content,style:b})})}),Yi=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"ScrollShadow",overridesResolver:(e,t)=>[t.root,t[e.position]]})(({theme:e})=>({position:"absolute",inset:0,pointerEvents:"none",transition:z.transition(["box-shadow"],{duration:z.transitions.duration.short}),"--length":"dark"===e.palette.mode?"8px":"6px","--length-inverse":"calc(var(--length) * -1)","--opacity":"dark"===e.palette.mode?"0.7":"0.18","--blur":"var(--length)","--spread":"calc(var(--length) * -1)","--color":"0, 0, 0","--color-start":"rgba(var(--color), calc(var(--hasScrollStart) * var(--opacity)))","--color-end":"rgba(var(--color), calc(var(--hasScrollEnd) * var(--opacity)))",variants:[{props:{position:"vertical"},style:{top:"var(--DataGrid-topContainerHeight)",bottom:"calc(var(--DataGrid-bottomContainerHeight) + var(--DataGrid-hasScrollX) * var(--DataGrid-scrollbarSize))",boxShadow:"inset 0 var(--length) var(--blur) var(--spread) var(--color-start), inset 0 var(--length-inverse) var(--blur) var(--spread) var(--color-end)"}},{props:{position:"horizontal"},style:{left:"var(--DataGrid-leftPinnedWidth)",right:"calc(var(--DataGrid-rightPinnedWidth) + var(--DataGrid-hasScrollY) * var(--DataGrid-scrollbarSize))",boxShadow:"inset var(--length) 0 var(--blur) var(--spread) var(--color-start), inset var(--length-inverse) 0 var(--blur) var(--spread) var(--color-end)"}}]}));function Ki(e){const{position:t}=e,n={classes:se().classes,position:t},i=(e=>{const{classes:t,position:n}=e,r={root:["scrollShadow",`scrollShadow--${n}`]};return(0,R.A)(r,D,t)})(n),a=o.useRef(null),l=Z(),s=J(l,pt),c=J(l,ht),u=J(l,Ot),d=J(l,Ue),f="vertical"===t?c&&u?.bottom?.length>0:s&&void 0!==d?.right?.length&&d?.right?.length>0,p=(0,Hr.I)(),h=o.useCallback(e=>{if(!a.current)return;const n=Math.abs(Math.round(e)),r=ut(l),o=Math.round(r.contentSize["vertical"===t?"height":"width"]-r.viewportInnerSize["vertical"===t?"height":"width"]),i="vertical"===t?u?.top?.length>0:void 0!==d?.left?.length&&d?.left?.length>0,s="vertical"===t?u?.bottom?.length>0:void 0!==d?.right?.length&&d?.right?.length>0,c=p?n<o:n>0,f=p?n>0:n<o;a.current.style.setProperty("--hasScrollStart",i&&c?"1":"0"),a.current.style.setProperty("--hasScrollEnd",s&&f?"1":"0")},[u,d,p,t,l]);return $t(l,"scrollPositionChange",e=>{h(e["vertical"===t?"top":"left"])}),$t(l,"columnResizeStop",()=>{"horizontal"===t&&h(l.current.virtualScrollerRef?.current?.scrollLeft||0)}),o.useEffect(()=>{h(("horizontal"===t?l.current.virtualScrollerRef?.current?.scrollLeft:l.current.virtualScrollerRef?.current?.scrollTop)??0)},[h,l,t]),(0,r.jsx)(Yi,{className:i.root,ownerState:n,ref:a,style:{"--hasScrollStart":0,"--hasScrollEnd":f?"1":"0"}})}const Ji=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"OverlayWrapper",shouldForwardProp:e=>"overlayType"!==e&&"loadingOverlayVariant"!==e&&"right"!==e})(({overlayType:e,loadingOverlayVariant:t,right:n})=>"skeleton"!==t?{position:"sticky",top:"var(--DataGrid-headersTotalHeight)",left:0,right:`${n}px`,width:0,height:0,zIndex:"loadingOverlay"===e?5:4}:{}),Xi=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"OverlayWrapperInner",shouldForwardProp:e=>"overlayType"!==e&&"loadingOverlayVariant"!==e})({});function Zi(e){const t=ot(),n=se(),o=J(t,ut);let i=Math.max(o.viewportOuterSize.height-o.topContainerHeight-o.bottomContainerHeight-(o.hasScrollX?o.scrollbarSize:0),0);0===i&&(i=or);const a=(e=>{const{classes:t}=e;return(0,R.A)({root:["overlayWrapper"],inner:["overlayWrapperInner"]},D,t)})((0,y.A)({},e,{classes:n.classes}));return(0,r.jsx)(Ji,(0,y.A)({className:a.root},e,{right:o.columnsTotalWidth-o.viewportOuterSize.width,children:(0,r.jsx)(Xi,(0,y.A)({className:a.inner,style:{height:i,width:o.viewportOuterSize.width}},e))}))}function ea(e,t){return Math.round(e*10**t)/10**t}const ta=()=>{};function na(e,t,n){const r=(0,G.A)(ra,{store:e,selector:t}).current;r.effect=n,(0,$i.A)(r.onMount)}function ra(e){const{store:t,selector:n}=e;let r=n(t.state);const o={effect:ta,dispose:null,subscribe:()=>{o.dispose??=t.subscribe(e=>{const t=n(e);if(!Object.is(r,t)){const e=r;r=t,o.effect(e,t)}})},onMount:()=>(o.subscribe(),()=>{o.dispose?.(),o.dispose=null})};return o.subscribe(),o}const oa=("undefined"!=typeof navigator?navigator.userAgent.toLowerCase():"empty").includes("firefox"),ia="undefined"!=typeof window&&/jsdom|HappyDOM/.test(window.navigator.userAgent);var aa=n(55);function la(e,t){if(e===t)return!0;if(e&&t&&"object"==typeof e&&"object"==typeof t){if(e.constructor!==t.constructor)return!1;if(Array.isArray(e)){const n=e.length;if(n!==t.length)return!1;for(let r=0;r<n;r+=1)if(!la(e[r],t[r]))return!1;return!0}if(e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;const n=Array.from(e.entries());for(let e=0;e<n.length;e+=1)if(!t.has(n[e][0]))return!1;for(let e=0;e<n.length;e+=1){const r=n[e];if(!la(r[1],t.get(r[0])))return!1}return!0}if(e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;const n=Array.from(e.entries());for(let e=0;e<n.length;e+=1)if(!t.has(n[e][0]))return!1;return!0}if(ArrayBuffer.isView(e)&&ArrayBuffer.isView(t)){const n=e.length;if(n!==t.length)return!1;for(let r=0;r<n;r+=1)if(e[r]!==t[r])return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===t.toString();const n=Object.keys(e),r=n.length;if(r!==Object.keys(t).length)return!1;for(let e=0;e<r;e+=1)if(!Object.prototype.hasOwnProperty.call(t,n[e]))return!1;for(let o=0;o<r;o+=1){const r=n[o];if(!la(e[r],t[r]))return!1}return!0}return e!=e&&t!=t}var sa=n(9966);const ca=C>=19?function(e,t,n,r,i){const a=o.useCallback(()=>t(e.getSnapshot(),n,r,i),[e,t,n,r,i]);return(0,H.useSyncExternalStore)(e.subscribe,a,a)}:function(e,t,n,r,o){return(0,sa.useSyncExternalStoreWithSelector)(e.subscribe,e.getSnapshot,e.getSnapshot,e=>t(e,n,r,o))};function ua(e,t,n,r,o){return ca(e,t,n,r,o)}const da={EMPTY:{width:0,height:0},equals:(e,t)=>e.width===t.width&&e.height===t.height},fa={EMPTY:{top:[],bottom:[]}},pa={EMPTY:{left:[],right:[]}},ha={EMPTY:{top:0,left:0},equals:(e,t)=>e.top===t.top&&e.left===t.left};let ga=function(e){return e[e.NONE=0]="NONE",e[e.UP=1]="UP",e[e.DOWN=2]="DOWN",e[e.LEFT=3]="LEFT",e[e.RIGHT=4]="RIGHT",e}({});(ga||(ga={})).forDelta=function(e,t){return 0===e&&0===t?ga.NONE:Math.abs(t)>=Math.abs(e)?t>0?ga.DOWN:ga.UP:e>0?ga.RIGHT:ga.LEFT};const ma={isReady:!1,root:da.EMPTY,viewportOuterSize:da.EMPTY,viewportInnerSize:da.EMPTY,contentSize:da.EMPTY,minimumSize:da.EMPTY,hasScrollX:!1,hasScrollY:!1,scrollbarSize:0,rowWidth:0,rowHeight:0,columnsTotalWidth:0,leftPinnedWidth:0,rightPinnedWidth:0,topContainerHeight:0,bottomContainerHeight:0,autoHeight:!1,minimalContentHeight:void 0},Aa={rootSize:e=>e.rootSize,dimensions:e=>e.dimensions,rowHeight:e=>e.dimensions.rowHeight,columnsTotalWidth:e=>e.dimensions.columnsTotalWidth,contentHeight:e=>e.dimensions.contentSize.height,autoHeight:e=>e.dimensions.autoHeight,minimalContentHeight:e=>e.dimensions.minimalContentHeight,rowsMeta:e=>e.rowsMeta,rowPositions:e=>e.rowsMeta.positions,columnPositions:xe((e,t)=>{const n=[];let r=0;for(let e=0;e<t.length;e+=1)n.push(r),r+=t[e].computedWidth;return n}),needsHorizontalScrollbar:e=>e.dimensions.viewportOuterSize.width>0&&e.dimensions.columnsTotalWidth>e.dimensions.viewportOuterSize.width},ba={initialize:function(e){const t=(0,y.A)({},ma,e.dimensions,{autoHeight:e.dimensions.autoHeight,minimalContentHeight:e.dimensions.minimalContentHeight}),{rowCount:n}=e,{rowHeight:r}=t,o={currentPageTotalHeight:n*r,positions:Array.from({length:n},(e,t)=>t*r),pinnedTopRowsTotalHeight:0,pinnedBottomRowsTotalHeight:0},i=new Map;return{rootSize:da.EMPTY,dimensions:t,rowsMeta:o,rowHeights:i}},use:function(e,t,n){const r=o.useRef(!0),i=o.useRef({counter:0,heights:{content:0,pinnedTop:0,pinnedBottom:0},lastFlipTimestamp:0}),{layout:a,dimensions:{rowHeight:l,columnsTotalWidth:s,leftPinnedWidth:c,rightPinnedWidth:u,topPinnedHeight:d,bottomPinnedHeight:f},onResize:p}=t,h=o.useCallback(n=>{if(n&&(r.current=!1),r.current)return;const o=a.refs.container.current,h=Aa.rootSize(e.state),g=Aa.rowsMeta(e.state),m=function(e,t){if(void 0!==t)return t;if(null===e)return 0;const n=va.get(e);if(void 0!==n)return n;const r=(0,aa.A)(e).createElement("div");r.style.width="99px",r.style.height="99px",r.style.position="absolute",r.style.overflow="scroll",r.className="scrollDiv",e.appendChild(r);const o=r.offsetWidth-r.clientWidth;return e.removeChild(r),va.set(e,o),o}(o,t.dimensions.scrollbarSize),A=d+g.pinnedTopRowsTotalHeight,b=f+g.pinnedBottomRowsTotalHeight,v={width:s,height:ea(g.currentPageTotalHeight,1)},y=e.state.dimensions;let w,C,S=!1,x=!1;if(t.dimensions.autoHeight)x=!1,S=Math.round(s)>Math.round(h.width),w={width:h.width,height:A+b+v.height},C={width:Math.max(0,w.width-(x?m:0)),height:Math.max(0,w.height-(S?m:0))};else{w={width:h.width,height:h.height},C={width:Math.max(0,w.width),height:Math.max(0,w.height-A-b)};const e=v,t=C,n=e.width>t.width,r=e.height>t.height;(n||r)&&(x=r,S=e.width+(x?m:0)>t.width,S&&(x=e.height+m>t.height));{const e=i.current,t=g.currentPageTotalHeight!==e.heights.content||g.pinnedTopRowsTotalHeight!==e.heights.pinnedTop||g.pinnedBottomRowsTotalHeight!==e.heights.pinnedBottom;if(t&&(e.counter=0,e.heights={content:g.currentPageTotalHeight,pinnedTop:g.pinnedTopRowsTotalHeight,pinnedBottom:g.pinnedBottomRowsTotalHeight}),y.isReady&&x!==y.hasScrollY){const r=performance.now();r-e.lastFlipTimestamp>100&&(e.counter=0),e.lastFlipTimestamp=r,t||(e.counter+=1),e.counter>=2&&(x=!1,S=n)}}x&&(C.width-=m),S&&(C.height-=m)}t.disableHorizontalScroll&&(S=!1),t.disableVerticalScroll&&(x=!1);const E=Math.max(w.width,s+(x?m:0)),I={isReady:!0,root:h,viewportOuterSize:w,viewportInnerSize:C,contentSize:v,minimumSize:{width:s,height:A+v.height+b},hasScrollX:S,hasScrollY:x,scrollbarSize:m,rowWidth:E,rowHeight:l,columnsTotalWidth:s,leftPinnedWidth:c,rightPinnedWidth:u,topContainerHeight:A,bottomContainerHeight:b,autoHeight:t.dimensions.autoHeight,minimalContentHeight:t.dimensions.minimalContentHeight};la(y,I)||(e.update({dimensions:I}),p?.(I.root))},[e,a.refs.container,t.dimensions.scrollbarSize,t.dimensions.autoHeight,t.dimensions.minimalContentHeight,t.disableHorizontalScroll,t.disableVerticalScroll,p,l,s,c,u,d,f]),{resizeThrottleMs:g}=t,m=(0,Nt.A)(h),A=o.useMemo(()=>g>0?function(e,t=166){let n,r;const o=()=>{n=void 0,e(...r)};function i(...e){r=e,void 0===n&&(n=setTimeout(o,t))}return i.clear=()=>{clearTimeout(n),n=void 0},i}(m,g):void 0,[g,m]);o.useEffect(()=>A?.clear,[A]),(0,Ut.A)(h,[h]),(0,Ut.A)(()=>{e.update({dimensions:(0,y.A)({},e.state.dimensions,{autoHeight:t.dimensions.autoHeight,minimalContentHeight:t.dimensions.minimalContentHeight})})},[e,t.dimensions.autoHeight,t.dimensions.minimalContentHeight]);const b=function(e,t,n){const r=e.state.rowHeights,{rows:i,getRowHeight:a,getRowSpacing:l,getEstimatedRowHeight:s}=t,c=o.useRef(-1),u=o.useRef(!1),d=o.useRef(!1),f=t.pinnedRows,p=ua(e,Aa.rowHeight),h=(0,Nt.A)(t=>{let n=r.get(t);return void 0===n&&(n={content:e.state.dimensions.rowHeight,spacingTop:0,spacingBottom:0,detail:0,autoHeight:!1,needsFirstMeasurement:!0},r.set(t,n)),n}),{applyRowHeight:g}=t,m=o.useCallback(t=>{const n=Aa.dimensions(e.state),r=n.rowHeight,o=h(t.id);if(a){const e=a(t);if("auto"===e){if(o.needsFirstMeasurement){const e=s?s(t):r;o.content=e??r}u.current=!0,o.autoHeight=!0}else o.content=e??n.rowHeight,o.needsFirstMeasurement=!1,o.autoHeight=!1}else o.content=r,o.needsFirstMeasurement=!1;if(l){const e=l(t);o.spacingTop=e.top??0,o.spacingBottom=e.bottom??0}else o.spacingTop=0,o.spacingBottom=0;return g?.(o,t),o},[e,a,h,s,p,l,g]),A=o.useCallback(()=>{u.current=!1;const t=f?.top.reduce((e,t)=>{const n=m(t);return e+n.content+n.spacingTop+n.spacingBottom+n.detail},0)??0,r=f?.bottom.reduce((e,t)=>{const n=m(t);return e+n.content+n.spacingTop+n.spacingBottom+n.detail},0)??0,o=[],a=i.reduce((e,t)=>{o.push(e);const n=m(t);return e+(n.content+n.spacingTop+n.spacingBottom+n.detail)},0);u.current||(c.current=1/0);const l=t!==e.state.rowsMeta.pinnedTopRowsTotalHeight||r!==e.state.rowsMeta.pinnedBottomRowsTotalHeight||a!==e.state.rowsMeta.currentPageTotalHeight,s={currentPageTotalHeight:a,positions:o,pinnedTopRowsTotalHeight:t,pinnedBottomRowsTotalHeight:r};e.set("rowsMeta",s),l&&n(),d.current=!0},[e,f,i,m,n]),b=(0,Nt.A)(A),v=(e,t)=>{const n=h(e),r=n.content!==t;n.needsFirstMeasurement=!1,n.content=t,d.current&&=!r},y=(0,G.A)(()=>"undefined"==typeof ResizeObserver?void 0:new ResizeObserver(e=>{for(let n=0;n<e.length;n+=1){const r=e[n],o=r.borderBoxSize&&r.borderBoxSize.length>0?r.borderBoxSize[0].blockSize:r.contentRect.height,i=r.target.__mui_id,a=t.focusedVirtualCell?.()?.id;if(a===i&&0===o)return;v(i,o)}d.current||requestAnimationFrame(()=>{b()})})).current;return(0,Ut.A)(()=>{A()},[A]),{getRowHeight:t=>r.get(t)?.content??Aa.rowHeight(e.state),setLastMeasuredRowIndex:e=>{u.current&&e>c.current&&(c.current=e)},storeRowHeightMeasurement:v,hydrateRowsMeta:A,observeRowHeight:(e,t)=>(e.__mui_id=t,y?.observe(e),()=>y?.unobserve(e)),rowHasAutoHeight:e=>r.get(e)?.autoHeight??!1,getRowHeightEntry:h,getLastMeasuredRowIndex:()=>c.current,resetRowHeights:()=>{r.clear(),A()}}}(e,t,h);return{updateDimensions:h,debouncedUpdateDimensions:A,rowsMeta:b}},selectors:Aa},va=new WeakMap;var ya=n(7868);const wa=()=>{},Ca=(e,t,n)=>Math.max(t,Math.min(n,e)),Sa={top:0,left:0},xa=Object.freeze(new Map),Ea={firstRowIndex:0,lastRowIndex:0,firstColumnIndex:0,lastColumnIndex:0},Ia=(()=>{const e=Se(e=>e.virtualization.renderContext.firstRowIndex);return{store:Se(e=>e.virtualization),renderContext:Se(e=>e.virtualization.renderContext),enabledForRows:Se(e=>e.virtualization.enabledForRows),enabledForColumns:Se(e=>e.virtualization.enabledForColumns),offsetTop:Se(ba.selectors.rowPositions,e,(e,t)=>e[t]??0),context:Se(e=>e.virtualization.context),scrollPosition:Se(e=>e.virtualization.scrollPosition)}})(),ka={initialize:function(e){return{virtualization:(0,y.A)({enabled:!ia,enabledForRows:!ia,enabledForColumns:!ia,renderContext:Ea,props:e.layout.constructor.elements.reduce((e,t)=>(e[t],e),{}),context:{},scrollPosition:{current:ha.EMPTY}},e.initialState?.virtualization),getters:null}},use:function(e,t,n){const{layout:r,dimensions:{rowHeight:i,columnsTotalWidth:a=0},virtualization:{isRtl:l=!1,rowBufferPx:s=150,columnBufferPx:c=150},colspan:u,initialState:d,rows:f,range:p,columns:h,pinnedRows:g=fa.EMPTY,pinnedColumns:m=pa.EMPTY,onWheel:A,onTouchMove:b,onRenderContextChange:v,onScrollChange:w,scrollReset:C,renderRow:S,renderInfiniteLoadingTrigger:x}=t,E=g.bottom.length>0,[I,k]=o.useState(xa),R=o.useRef(!1),M=o.useRef(!1),P=ua(e,Ia.renderContext),B=ua(e,Ia.enabledForRows),_=ua(e,Ia.enabledForColumns),T=ua(e,ba.selectors.contentHeight),O=o.useRef(d?.scroll??Sa),D=o.useRef(!1),N=o.useRef(Sa),L=o.useRef(Ea),F=(0,Vt.A)(),Q=o.useRef(void 0),j=(0,G.A)(()=>function(e,t,n,r){return{direction:ga.NONE,buffer:Na(e,ga.NONE,t,n,r,300)}}(l,s,c,15*i)).current,z=o.useCallback(t=>{Oa(t,e.state.virtualization.renderContext)||e.set("virtualization",(0,y.A)({},e.state.virtualization,{renderContext:t,scrollPosition:{current:(0,y.A)({},O.current)}}));const n=ba.selectors.dimensions(e.state).isReady,r=t.firstRowIndex!==L.current.firstRowIndex||t.lastRowIndex!==L.current.lastRowIndex;n&&r&&(L.current=t,v?.(t)),N.current=O.current},[e,v]),$=(0,Nt.A)(()=>{const o=r.refs.scroller.current;if(!o)return;const a=ba.selectors.dimensions(e.state),u=Math.ceil(a.contentSize.height-a.viewportInnerSize.height),d=Math.ceil(a.contentSize.width-a.viewportInnerSize.width),f={top:Ca(o.scrollTop,0,u),left:l?Ca(o.scrollLeft,-Math.abs(d),0):Ca(o.scrollLeft,0,d)},p=f.left-O.current.left,h=f.top-O.current.top,g=0!==p||0!==h;O.current=f;const m=g?ga.forDelta(p,h):ga.NONE,A=Math.abs(O.current.top-N.current.top),b=Math.abs(O.current.left-N.current.left),v=A>=i||b>=50,w=j.direction!==m;if(!v&&!w)return e.set("virtualization",(0,y.A)({},e.state.virtualization,{scrollPosition:{current:(0,y.A)({},O.current)}})),P;if(w)switch(m){case ga.NONE:case ga.LEFT:case ga.RIGHT:Q.current=void 0;break;default:Q.current=P}j.direction=m,j.buffer=Na(l,m,s,c,15*i,300);const C=Pa(Ma(e,t,n,B,_),O.current,j);return Oa(C,P)?e.set("virtualization",(0,y.A)({},e.state.virtualization,{scrollPosition:{current:(0,y.A)({},O.current)}})):(ya.flushSync(()=>{z(C)}),F.start(1e3,$)),C}),H=()=>{if(!ba.selectors.dimensions(e.state).isReady&&(B||_))return;const r=Pa(Ma(e,t,n,B,_),O.current,j);Q.current=void 0,z(r)},V=(0,Nt.A)(H);na(e,ba.selectors.dimensions,(e,t)=>{t.isReady&&H()}),(0,Ut.A)(()=>{R.current&&(H(),R.current=!1)});const W=(0,Nt.A)(()=>{if(D.current)return void(D.current=!1);const e=$();e&&w?.(O.current,e)}),U=o.useRef(null);(0,Ut.A)(()=>{M.current&&V()},[_,B,V]),(0,Ut.A)(()=>{r.refs.scroller.current&&(r.refs.scroller.current.scrollLeft=0)},[r.refs.scroller,C]),(e=>{const t=o.useRef(!1);(0,Ut.A)(()=>t.current||!e?wa:(t.current=!0,(()=>{if(w?.(O.current,P),M.current=!0,d?.scroll&&r.refs.scroller.current){const e=r.refs.scroller.current,{top:t,left:n}=d.scroll,o={top:!(t>0),left:!(n>0)};!o.left&&a&&(e.scrollLeft=n,o.left=!0,D.current=!0),!o.top&&T&&(e.scrollTop=t,D.current=!0),o.top&&o.left||(U.current=(r,i)=>{!o.left&&r&&(e.scrollLeft=n,o.left=!0,D.current=!0),!o.top&&i&&(e.scrollTop=t,o.top=!0,D.current=!0),o.left&&o.top&&(U.current=null)})}})()),[t.current||e])})(P!==Ea),na(e,ba.selectors.dimensions,H),(0,Ut.A)(()=>{r.refs.scroller&&U.current?.(a,T)},[r.refs.scroller,a,T]);const q=o.useRef(!0),Y={containerRef:Ra(t=>{r.refs.container.current=t;const o=function(e,t,n){if(!e)return;const r=e.getBoundingClientRect(),o={width:ea(r.width,1),height:ea(r.height,1)};if(t.state.rootSize!==da.EMPTY&&da.equals(o,t.state.rootSize)||n(o),"undefined"==typeof ResizeObserver)return;const i=new ResizeObserver(([e])=>{if(!e)return;const r={width:ea(e.contentRect.width,1),height:ea(e.contentRect.height,1)};da.equals(r,t.state.rootSize)||n(r)});return i.observe(e),()=>{i.disconnect()}}(t,e,t=>{0===t.width&&0===t.height&&0!==e.state.rootSize.height&&0!==e.state.rootSize.width||(e.state.rootSize=t,q.current||!n.debouncedUpdateDimensions?(n.updateDimensions(q.current),q.current=!1):n.debouncedUpdateDimensions())});return()=>{o?.(),r.refs.container.current=null}}),scrollerRef:Ra(e=>{r.refs.scroller.current=e;const t={passive:!0};return e.addEventListener("scroll",W,t),e.addEventListener("wheel",A,t),e.addEventListener("touchmove",b,t),()=>{e.removeEventListener("scroll",W,t),e.removeEventListener("wheel",A,t),e.removeEventListener("touchmove",b,t),r.refs.scroller.current=null}})},K=r.use(e,t,n,Y),J=(0,y.A)({setPanels:k,getRows:(r={},o)=>{if(!r.rows&&!p)return[];let i=P;r.renderContext&&(i=r.renderContext,i.firstColumnIndex=P.firstColumnIndex,i.lastColumnIndex=P.lastColumnIndex);const l=!E&&void 0===r.position||E&&"bottom"===r.position,s=void 0!==r.position;let c;switch(r.position){case"top":c=0;break;case"bottom":c=g.top.length+f.length;break;default:c=g.top.length}const d=r.rows??f,A=i.firstRowIndex,b=Math.min(i.lastRowIndex,d.length),v=r.rows?La(0,r.rows.length):La(A,b);let y=-1;const w=t.focusedVirtualCell?.();!s&&w&&(w.rowIndex<A&&w.rowIndex>=0&&w.rowIndex<d.length&&(v.unshift(w.rowIndex),y=w.rowIndex),w.rowIndex>b&&w.rowIndex<d.length&&(v.push(w.rowIndex),y=w.rowIndex));const C=[],k=ba.selectors.columnPositions(e.state,h);return v.forEach(e=>{const{id:t,model:g}=d[e];if(o&&!o[t])return;const A=(p?.firstRowIndex||0)+c+e;if(u?.enabled){const e=m.left.length,r=h.length-m.right.length;n.calculateColSpan(t,e,r,h),m.left.length>0&&n.calculateColSpan(t,0,m.left.length,h),m.right.length>0&&n.calculateColSpan(t,h.length-m.right.length,h.length,h)}const b=n.rowsMeta.rowHasAutoHeight(t)?"auto":n.rowsMeta.getRowHeight(t);let v=!1;void 0===r.position&&(v=0===e);let E=!1;const R=e===d.length-1;l&&(s?E=R:e===f.length-1&&(E=!0));let M=i;Q.current&&e>=Q.current.firstRowIndex&&e<Q.current.lastRowIndex&&(M=Q.current);const P=e===y,B=w?.rowIndex===A,_=Da(k,M,m.left.length),T=R&&"top"===r.position,O=M.firstColumnIndex,D=M.lastColumnIndex;if(C.push(S({id:t,model:g,rowIndex:A,offsetLeft:_,columnsTotalWidth:a,baseRowHeight:b,firstColumnIndex:O,lastColumnIndex:D,focusedColumnIndex:B?w.columnIndex:void 0,isFirstVisible:v,isLastVisible:E,isVirtualFocusRow:P,showBottomBorder:T})),P)return;const N=I.get(t);N&&C.push(N),void 0===r.position&&R&&x&&C.push(x(t))}),C},rows:t.rows},K);return(0,y.A)({getters:J,setPanels:k,forceUpdateRenderContext:H,scheduleUpdateRenderContext:()=>{R.current=!0}},{getCellColSpanInfo:()=>{throw new Error("Unimplemented: colspan feature is required")},calculateColSpan:()=>{throw new Error("Unimplemented: colspan feature is required")},getHiddenCellsOrigin:()=>{throw new Error("Unimplemented: rowspan feature is required")}})},selectors:Ia};function Ra(e){const t=o.useRef(void 0);return(0,Nt.A)(n=>{if(n)return t.current=e(n),C>=19?t.current:void 0;t.current?.()})}function Ma(e,t,n,r,o){const i=ba.selectors.dimensions(e.state),a=t.rows,l=t.range,s=t.columns,c=n.getHiddenCellsOrigin(),u=t.rows.at(-1)?.id,d=s.at(-1);return{api:n,enabledForRows:r,enabledForColumns:o,autoHeight:i.autoHeight,rowBufferPx:t.virtualization.rowBufferPx,columnBufferPx:t.virtualization.columnBufferPx,leftPinnedWidth:i.leftPinnedWidth,columnsTotalWidth:i.columnsTotalWidth,viewportInnerWidth:i.viewportInnerSize.width,viewportInnerHeight:i.viewportInnerSize.height,lastRowHeight:void 0!==u?n.rowsMeta.getRowHeight(u):0,lastColumnWidth:d?.computedWidth??0,rowsMeta:ba.selectors.rowsMeta(e.state),columnPositions:ba.selectors.columnPositions(e.state,t.columns),rows:a,range:l,pinnedColumns:t.pinnedColumns,columns:s,hiddenCellsOriginMap:c,virtualizeColumnsWithAutoRowHeight:t.virtualizeColumnsWithAutoRowHeight}}function Pa(e,t,n){const r={firstRowIndex:0,lastRowIndex:e.rows.length,firstColumnIndex:0,lastColumnIndex:e.columns.length},{top:o,left:i}=t,a=Math.abs(i)+e.leftPinnedWidth;if(e.enabledForRows){let t=Math.min(Ba(e,o,{atStart:!0,lastPosition:e.rowsMeta.positions[e.rowsMeta.positions.length-1]+e.lastRowHeight}),e.rowsMeta.positions.length-1);const n=e.hiddenCellsOriginMap[t];if(n){const e=Math.min(...Object.values(n));t=Math.min(t,e)}const i=e.autoHeight?t+e.rows.length:Ba(e,o+e.viewportInnerHeight);r.firstRowIndex=t,r.lastRowIndex=i}if(e.enabledForColumns){let t=0,o=e.columnPositions.length,i=!1;const[l,s]=Ta({firstIndex:r.firstRowIndex,lastIndex:r.lastRowIndex,minFirstIndex:0,maxLastIndex:e.rows.length,bufferBefore:n.buffer.rowBefore,bufferAfter:n.buffer.rowAfter,positions:e.rowsMeta.positions,lastSize:e.lastRowHeight});if(!e.virtualizeColumnsWithAutoRowHeight)for(let t=l;t<s&&!i;t+=1){const n=e.rows[t];i=e.api.rowsMeta.rowHasAutoHeight(n.id)}i&&!e.virtualizeColumnsWithAutoRowHeight||(t=_a(a,e.columnPositions,{atStart:!0,lastPosition:e.columnsTotalWidth}),o=_a(a+e.viewportInnerWidth,e.columnPositions)),r.firstColumnIndex=t,r.lastColumnIndex=o}const l=function(e,t,n){const[r,o]=Ta({firstIndex:t.firstRowIndex,lastIndex:t.lastRowIndex,minFirstIndex:0,maxLastIndex:e.rows.length,bufferBefore:n.buffer.rowBefore,bufferAfter:n.buffer.rowAfter,positions:e.rowsMeta.positions,lastSize:e.lastRowHeight}),[i,a]=Ta({firstIndex:t.firstColumnIndex,lastIndex:t.lastColumnIndex,minFirstIndex:e.pinnedColumns?.left.length??0,maxLastIndex:e.columns.length-(e.pinnedColumns?.right.length??0),bufferBefore:n.buffer.columnBefore,bufferAfter:n.buffer.columnAfter,positions:e.columnPositions,lastSize:e.lastColumnWidth}),l=function({api:e,firstColumnToRender:t,firstRowToRender:n,lastRowToRender:r,visibleRows:o}){let i=t,a=!1;for(;!a&&i>=0;){a=!0;for(let t=n;t<r;t+=1)if(o[t]){const n=o[t].id,r=e.getCellColSpanInfo(n,i);if(r&&r.spannedByColSpan&&r.leftVisibleCellIndex<i){i=r.leftVisibleCellIndex,a=!1;break}}}return i}({api:e.api,firstColumnToRender:i,firstRowToRender:r,lastRowToRender:o,visibleRows:e.rows});return{firstRowIndex:r,lastRowIndex:o,firstColumnIndex:l,lastColumnIndex:a}}(e,r,n);return l}function Ba(e,t,n){const r=e.api.rowsMeta.getLastMeasuredRowIndex();let o=r===1/0;e.range?.lastRowIndex&&!o&&(o=r>=e.range.lastRowIndex);const i=Ca(r-(e.range?.firstRowIndex||0),0,e.rowsMeta.positions.length);return o||e.rowsMeta.positions[i]>=t?_a(t,e.rowsMeta.positions,n):function(e,t,n,r){let o=1;for(;n<t.length&&Math.abs(t[n])<e;)n+=o,o*=2;return _a(e,t,r,Math.floor(n/2),Math.min(n,t.length))}(t,e.rowsMeta.positions,i,n)}function _a(e,t,n=void 0,r=0,o=t.length){if(t.length<=0)return-1;if(r>=o)return r;const i=r+Math.floor((o-r)/2),a=t[i];let l;return l=n?.atStart?e-((i===t.length-1?n.lastPosition:t[i+1])-a)<a:e<=a,l?_a(e,t,n,r,i):_a(e,t,n,i+1,o)}function Ta({firstIndex:e,lastIndex:t,bufferBefore:n,bufferAfter:r,minFirstIndex:o,maxLastIndex:i,positions:a,lastSize:l}){const s=a[e]-n,c=a[t]+r,u=_a(s,a,{atStart:!0,lastPosition:a[a.length-1]+l}),d=_a(c,a);return[Ca(u,o,i),Ca(d,o,i)]}function Oa(e,t){return e===t||e.firstRowIndex===t.firstRowIndex&&e.lastRowIndex===t.lastRowIndex&&e.firstColumnIndex===t.firstColumnIndex&&e.lastColumnIndex===t.lastColumnIndex}function Da(e,t,n){const r=(e[t.firstColumnIndex]??0)-(e[n]??0);return Math.abs(r)}function Na(e,t,n,r,o,i){if(e)switch(t){case ga.LEFT:t=ga.RIGHT;break;case ga.RIGHT:t=ga.LEFT}switch(t){case ga.NONE:return{rowAfter:n,rowBefore:n,columnAfter:r,columnBefore:r};case ga.LEFT:return{rowAfter:0,rowBefore:0,columnAfter:0,columnBefore:i};case ga.RIGHT:return{rowAfter:0,rowBefore:0,columnAfter:i,columnBefore:0};case ga.UP:return{rowAfter:0,rowBefore:o,columnAfter:0,columnBefore:0};case ga.DOWN:return{rowAfter:o,rowBefore:0,columnAfter:0,columnBefore:0};default:throw new Error("unreachable")}}function La(e,t){return Array.from({length:t-e}).map((t,n)=>e+n)}class Fa{static elements=["scroller","container"];constructor(e){this.refs=e}refSetter(e){return t=>{t&&this.refs[e].current!==t&&(this.refs[e].current=t)}}}class Qa extends Fa{static elements=["scroller","container","content","positioner","scrollbarVertical","scrollbarHorizontal"];use(e,t,n,r){const{scrollerRef:o,containerRef:i}=r,a=(0,Nt.A)(this.refSetter("scrollbarVertical")),l=(0,Nt.A)(this.refSetter("scrollbarHorizontal"));e.state.virtualization.context={scrollerRef:o,containerRef:i,scrollbarVerticalRef:a,scrollbarHorizontalRef:l}}static selectors=(()=>({containerProps:xe(ka.selectors.context,e=>({ref:e.containerRef})),scrollerProps:xe(ka.selectors.context,ba.selectors.autoHeight,ba.selectors.needsHorizontalScrollbar,(e,t,n)=>({ref:e.scrollerRef,style:{overflowX:n?void 0:"hidden",overflowY:t?"hidden":void 0},role:"presentation",tabIndex:oa?-1:void 0})),contentProps:xe(ba.selectors.contentHeight,ba.selectors.minimalContentHeight,ba.selectors.columnsTotalWidth,ba.selectors.needsHorizontalScrollbar,(e,t,n,r)=>({style:{width:r?n:"auto",flexBasis:0===e?t:e,flexShrink:0},role:"presentation"})),positionerProps:xe(ka.selectors.offsetTop,e=>({style:{transform:`translate3d(0, ${e}px, 0)`}})),scrollbarHorizontalProps:xe(ka.selectors.context,ka.selectors.scrollPosition,(e,t)=>({ref:e.scrollbarHorizontalRef,scrollPosition:t})),scrollbarVerticalProps:xe(ka.selectors.context,ka.selectors.scrollPosition,(e,t)=>({ref:e.scrollbarVerticalRef,scrollPosition:t})),scrollAreaProps:xe(ka.selectors.scrollPosition,e=>({scrollPosition:e}))}))()}class ja extends Qa{use(e,t,n,r){super.use(e,t,n,r);const o=e.use(Qa.selectors.containerProps),i=e.use(Qa.selectors.scrollerProps),a=e.use(Qa.selectors.contentProps),l=e.use(Qa.selectors.positionerProps),s=e.use(Qa.selectors.scrollbarVerticalProps),c=e.use(Qa.selectors.scrollbarHorizontalProps),u=e.use(Qa.selectors.scrollAreaProps);return{getContainerProps:()=>o,getScrollerProps:()=>i,getContentProps:()=>a,getPositionerProps:()=>l,getScrollbarVerticalProps:()=>s,getScrollbarHorizontalProps:()=>c,getScrollAreaProps:()=>u}}}xe(ka.selectors.context,ba.selectors.autoHeight,ba.selectors.needsHorizontalScrollbar,(e,t,n)=>({ref:e.mergedRef,style:{overflowX:n?void 0:"hidden",overflowY:t?"hidden":void 0,position:"relative"},role:"presentation",tabIndex:oa?-1:void 0})),xe(ba.selectors.contentHeight,e=>({style:{position:"absolute",display:"inline-block",width:"100%",height:e,top:0,left:0,zIndex:-1},role:"presentation"})),xe(ka.selectors.offsetTop,e=>({style:{height:e}}));class za{static create(e){return new za(e)}constructor(e){this.state=e,this.listeners=new Set,this.updateTick=0}subscribe=e=>(this.listeners.add(e),()=>{this.listeners.delete(e)});getSnapshot=()=>this.state;setState(e){this.state=e,this.updateTick+=1;const t=this.updateTick,n=this.listeners.values();let r;for(;r=n.next(),!r.done;){if(t!==this.updateTick)return;(0,r.value)(e)}}update(e){for(const t in e)if(!Object.is(this.state[t],e[t]))return void this.setState((0,y.A)({},this.state,e))}set(e,t){Object.is(this.state[e],t)||this.setState((0,y.A)({},this.state,{[e]:t}))}use=(()=>(e,t,n,r)=>ua(this,e,t,n,r))()}function $a(e,t,n,r,o,i,a){const l=i.length,s=i[t],c=a(n,s,t);if(!c||1===c)return Ha(e,n,t,{spannedByColSpan:!1,cellProps:{colSpan:1,width:s.computedWidth}}),{colSpan:1};let u=s.computedWidth;for(let a=1;a<c;a+=1){const s=t+a;s>=r&&s<o&&(u+=i[s].computedWidth,Ha(e,n,t+a,{spannedByColSpan:!0,rightVisibleCellIndex:Math.min(t+c,l-1),leftVisibleCellIndex:t})),Ha(e,n,t,{spannedByColSpan:!1,cellProps:{colSpan:c,width:u}})}return{colSpan:c}}function Ha(e,t,n,r){let o=e.get(t);o||(o={},e.set(t,o)),o[n]=r}const Ga={initialize:function(e){return{}},use:function(e,t,n){return{getViewportPageSize:()=>{const n=ba.selectors.dimensions(e.state);if(!n.isReady)return 0;if(t.getRowHeight){const n=ka.selectors.renderContext(e.state),r=n.lastRowIndex-n.firstRowIndex;return Math.min(r-1,t.rows.length)}const r=Math.floor(n.viewportInnerSize.height/n.rowHeight);return Math.min(r,t.rows.length)}}},selectors:{}},Va={firstRowIndex:0,lastRowIndex:0},Wa={spannedCells:{},hiddenCells:{},hiddenCellOriginMap:{}},Ua={state:e=>e.rowSpanning,hiddenCells:e=>e.rowSpanning.caches.hiddenCells,spannedCells:e=>e.rowSpanning.caches.spannedCells,hiddenCellsOriginMap:e=>e.rowSpanning.caches.hiddenCellOriginMap},qa={initialize:function(e){return{rowSpanning:e.initialState?.rowSpanning??{caches:Wa,processedRange:Va}}},use:function(e,t,n){return{getHiddenCellsOrigin:()=>Ua.hiddenCellsOriginMap(e.state)}},selectors:Ua},Ya={resizeThrottleMs:100,columns:[{field:"DEFAULT_COLUMN"}],dimensions:{autoHeight:!1,columnsTotalWidth:0,leftPinnedWidth:0,rightPinnedWidth:0,topPinnedHeight:0,bottomPinnedHeight:0},virtualization:{isRtl:!1,rowBufferPx:150,columnBufferPx:150}},Ka=[ba,ka,{initialize:function(e){return{colspanMap:new Map}},use:function(e,t,n){const r=t.colspan?.getColspan,o=(0,Nt.A)(r?(t,n,o,i)=>{for(let a=n;a<o;a+=1){const l=$a(e.state.colspanMap,a,t,n,o,i,r);l.colSpan>1&&(a+=l.colSpan-1)}}:()=>{});return n.calculateColSpan=o,{resetColSpan:()=>{e.state.colspanMap=new Map},getCellColSpanInfo:(t,n)=>e.state.colspanMap.get(t)?.[n],calculateColSpan:o}},selectors:{}},qa,Ga],Ja=e=>{const t=Xa(e,Ya),n=(0,G.A)(()=>new za(Ka.map(e=>e.initialize(t)).reduce((e,t)=>Object.assign(e,t),{}))).current,r={};for(const e of Ka)Object.assign(r,e.use(n,t,r));return{store:n,api:r}};function Xa(e,t){const n=(0,y.A)({},e);for(const r in t)if(Object.hasOwn(t,r)){const o=t[r];null===o||"object"!=typeof o||Array.isArray(o)?n[r]=e[r]??o:n[r]=Xa(e[r]??{},o)}return n}function Za(e){const t=o.useRef(!0);t.current&&(t.current=!1,e())}let el=function(e){return e.DataGrid="DataGrid",e.DataGridPro="DataGridPro",e.DataGridPremium="DataGridPremium",e}({});const tl=(e,t,n)=>t>0&&e>0?Math.ceil(e/t):-1===e?n+2:0,nl=e=>({page:0,pageSize:e?0:100}),rl=(e,t)=>{if(t===el.DataGrid&&e>100)throw new Error(["MUI X: `pageSize` cannot exceed 100 in the MIT version of the DataGrid.","You need to upgrade to DataGridPro or DataGridPremium component to unlock this feature."].join("\n"))},ol=ke(e=>e.pagination),il=Ee(ol,e=>e.enabled&&"client"===e.paginationMode),al=Ee(ol,e=>e.paginationModel),ll=Ee(ol,e=>e.rowCount),sl=Ee(ol,e=>e.meta),cl=Ee(al,e=>e.page),ul=Ee(al,e=>e.pageSize),dl=Ee(al,ll,(e,t)=>tl(t,e.pageSize,e.page)),fl=Ie(il,al,It,Bt,ei,oi,(e,t,n,r,o,i)=>{if(!e)return null;if(!o||0===o.length)return null;const a=i.length,l=Math.min(t.pageSize*t.page,a-1),s=-1===t.pageSize?a-1:Math.min(l+t.pageSize-1,a-1);if(-1===l||-1===s)return null;if(r<2)return{firstRowIndex:l,lastRowIndex:s};const c=i[l],u=s-l+1,d=o.findIndex(e=>e.id===c.id);let f=d,p=0;for(;f<o.length&&p<=u;){const e=o[f],t=n[e.id]?.depth;void 0===t?f+=1:((p<u||t>0)&&(f+=1),0===t&&(p+=1))}return{firstRowIndex:d,lastRowIndex:f-1}}),pl=Ie(ei,fl,(e,t)=>t?e.slice(t.firstRowIndex,t.lastRowIndex+1):[]),hl=Ie(ti,fl,(e,t)=>t?e.slice(t.firstRowIndex,t.lastRowIndex+1):[]),gl=Ie(il,fl,pl,ei,(e,t,n,r)=>e?{rows:n,range:t,rowIdToIndexMap:n.reduce((e,t,n)=>(e.set(t.id,n),e),new Map)}:{rows:r,range:0===r.length?null:{firstRowIndex:0,lastRowIndex:r.length-1},rowIdToIndexMap:r.reduce((e,t,n)=>(e.set(t.id,n),e),new Map)}),ml=(e,t)=>gl(e),Al=(e,t)=>J(e,gl),bl=ke(e=>e.virtualization),vl=(Ee(bl,e=>e.enabled),Ee(bl,e=>e.enabledForColumns)),yl=(Ee(bl,e=>e.enabledForRows),Ee(bl,e=>e.renderContext)),wl=Ie(ke(e=>e.virtualization.renderContext.firstColumnIndex),ke(e=>e.virtualization.renderContext.lastColumnIndex),(e,t)=>({firstColumnIndex:e,lastColumnIndex:t})),Cl=Ie(Ee(Ai,yl,gl,Ve,(e,t,n,r)=>{if(!e)return!1;const o=n.rowIdToIndexMap.get(e.id),i=r.slice(t.firstColumnIndex,t.lastColumnIndex).findIndex(t=>t.field===e.field);return!(void 0!==o&&-1!==i&&o>=t.firstRowIndex&&o<=t.lastRowIndex)}),Ve,gl,Ai,(e,t,n,r)=>{if(!e)return null;const o=n.rowIdToIndexMap.get(r.id);if(void 0===o)return null;const i=t.findIndex(e=>e.field===r.field);return-1===i?null:(0,y.A)({},r,{rowIndex:o,columnIndex:i})});class Sl{constructor(e){this.data=e.ids}has(e){return this.data.has(e)}select(e){this.data.add(e)}unselect(e){this.data.delete(e)}}class xl{constructor(e){this.data=e.ids}has(e){return!this.data.has(e)}select(e){this.data.delete(e)}unselect(e){this.data.add(e)}}const El=e=>"include"===e.type?new Sl(e):new xl(e),Il=ke(e=>e.rowSelection),kl=Ie(Il,El),Rl=Ee(Il,li,(e,t)=>"include"===e.type?e.ids.size:t-e.ids.size),Ml=Ie(Il,Et,_t,(e,t,n)=>{const r=new Map;if("include"===e.type)for(const n of e.ids)r.set(n,t[n]);else for(let o=0;o<n.length;o+=1){const i=n[o];e.ids.has(i)||r.set(i,t[i])}return r}),Pl={autoHeight:!1,autoPageSize:!1,autosizeOnMount:!1,checkboxSelection:!1,checkboxSelectionVisibleOnly:!1,clipboardCopyCellDelimiter:"\t",columnBufferPx:150,columnFilterDebounceMs:150,columnHeaderHeight:56,disableAutosize:!1,disableColumnFilter:!1,disableColumnMenu:!1,disableColumnReorder:!1,disableColumnResize:!1,disableColumnSelector:!1,disableColumnSorting:!1,disableDensitySelector:!1,disableEval:!1,disableMultipleColumnsFiltering:!1,disableMultipleColumnsSorting:!1,disableMultipleRowSelection:!1,dataSourceRevalidateMs:0,disableRowSelectionOnClick:!1,disableRowSelectionExcludeModel:!1,disableVirtualization:!1,editMode:Mr.Cell,filterDebounceMs:150,filterMode:"client",hideFooter:!1,hideFooterPagination:!1,hideFooterRowCount:!1,hideFooterSelectedRowCount:!1,ignoreDiacritics:!1,ignoreValueFormatterDuringExport:!1,keepColumnPositionIfDraggedOutside:!1,keepNonExistentRowsSelected:!1,loading:!1,logger:console,logLevel:"error",pageSizeOptions:[25,50,100],pagination:!1,paginationMode:"client",resizeThrottleMs:60,rowBufferPx:150,rowHeight:52,rows:[],rowSelection:!0,rowSpacingType:"margin",rowSpanning:!1,showCellVerticalBorder:!1,showColumnVerticalBorder:!1,showToolbar:!1,sortingMode:"client",sortingOrder:["asc","desc",null],throttleRowsMs:0,virtualizeColumnsWithAutoRowHeight:!1,tabNavigation:"none"};function Bl(e,t,n){const r=o.useRef(!0);(0,Ut.A)(()=>{r.current=!1,e.current.register(n,t)},[e,n,t]),r.current&&e.current.register(n,t)}const _l=(e,t,n)=>{const r=o.useRef(null),i=o.useRef(`mui-${Math.round(1e9*Math.random())}`),a=o.useCallback(()=>{r.current=e.current.registerPipeApplier(t,i.current,n)},[e,n,t]);Za(()=>{a()});const l=o.useRef(!0);o.useEffect(()=>(l.current?l.current=!1:a(),()=>{r.current&&(r.current(),r.current=null)}),[a])},Tl=(e,t,n)=>{const r=ft(n),o=Ct(n),i=ol(n),a=Math.min(i.enabled?i.paginationModel.pageSize:o,o);return(0,y.A)({},e,{rowsMeta:{currentPageTotalHeight:a*r,positions:Array.from({length:a},(e,t)=>t*r),pinnedTopRowsTotalHeight:0,pinnedBottomRowsTotalHeight:0}})},Ol=Ee(Ve,Ke,(e,t)=>{const n=e.length;return 0===n?0:ea(t[n-1]+e[n-1].computedWidth,1)}),Dl=()=>Ae((e,t,n,r,o)=>(0,y.A)({},e,{headerHeight:t,groupHeaderHeight:n,headerFilterHeight:r,headersTotalHeight:o}),{maxSize:1});const Nl=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"VirtualScroller",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.virtualScroller,n.hasScrollX&&t["virtualScroller--hasScrollX"]]}})({position:"relative",height:"100%",flexGrow:1,overflow:"scroll",scrollbarWidth:"none",display:"flex",flexDirection:"column","&::-webkit-scrollbar":{display:"none"},"@media print":{overflow:"hidden"},zIndex:0}),Ll=e=>e.current.state.dimensions.rightPinnedWidth>0;function Fl(e){const t=Z(),n=se(),i=J(t,ht),a=J(t,pt),l=J(t,Ll),s=J(t,yt),{overlayType:c,loadingOverlayVariant:u}=gi(t,n),d=n.slots?.[c],f={classes:n.classes,hasScrollX:a,hasPinnedRight:l,overlayType:c,loadingOverlayVariant:u},p=(e=>{const{classes:t,hasScrollX:n,hasPinnedRight:r,loadingOverlayVariant:o,overlayType:i}=e,a={root:["main",r&&"main--hasPinnedRight",("skeleton"===o||"noColumnsOverlay"===i)&&"main--hiddenContent"],scroller:["virtualScroller",n&&"virtualScroller--hasScrollX"]};return(0,R.A)(a,D,t)})(f),h=function(){const e=(0,Hr.I)(),t=se(),n=Z(),{listView:i}=t,a=J(n,Ve),l=J(n,Ot),s=qe(n),c=J(n,kl),u=o.useCallback(e=>c.has(e)&&n.current.isRowSelectable(e),[c,n]),d=Al(n),f=J(n,Ze),p=J(n,vt),h=J(n,gt),{autoHeight:g}=t,m=i,A=J(n,Be),b=ar(t.rowHeight,Pl.rowHeight),v=Math.floor(b*A),w=Math.floor(t.columnHeaderHeight*A),C=Math.floor((t.columnGroupHeaderHeight??t.columnHeaderHeight)*A),S=Math.floor((t.headerFilterHeight??t.columnHeaderHeight)*A),x=J(n,Ol),E=Do(n,t),I=s.left.reduce((e,t)=>e+t.computedWidth,0),k=s.right.reduce((e,t)=>e+t.computedWidth,0),R=gi(n,t),M={rowHeight:v,headerHeight:w,columnsTotalWidth:x,leftPinnedWidth:I,rightPinnedWidth:k,topPinnedHeight:E,bottomPinnedHeight:0,autoHeight:g,minimalContentHeight:or,scrollbarSize:t.scrollbarSize},P=(0,G.A)(Dl).current,B=J(n,Ct),_=J(n,ol),T=Math.min(_.enabled?_.paginationModel.pageSize:B,B),{getRowHeight:O,getEstimatedRowHeight:D,getRowSpacing:N}=t,L=t.slots.row,F=t.slotProps?.row,Q=(J(n,Cl),(0,G.A)(()=>new ja({container:n.current.mainElementRef,scroller:n.current.virtualScrollerRef,scrollbarVertical:n.current.virtualScrollbarVerticalRef,scrollbarHorizontal:n.current.virtualScrollbarHorizontalRef})).current),j=Ja({layout:Q,dimensions:M,virtualization:{isRtl:e,rowBufferPx:t.rowBufferPx,columnBufferPx:t.columnBufferPx},colspan:{enabled:f,getColspan:o.useCallback((e,t)=>{if("function"==typeof t.colSpan){const r=n.current.getRow(e),o=n.current.getRowValue(r,t);return t.colSpan(o,r,t,n)??0}return t.colSpan??1},[n])},initialState:{scroll:t.initialState?.scroll,rowSpanning:n.current.state.rowSpanning,virtualization:n.current.state.virtualization},rows:d.rows,range:d.range,rowCount:T,columns:a,pinnedRows:l,pinnedColumns:s,disableHorizontalScroll:i,disableVerticalScroll:"noColumnsOverlay"===R.overlayType||"skeleton"===R.loadingOverlayVariant,getRowHeight:o.useMemo(()=>{if(O)return e=>O((0,y.A)({},e,{densityFactor:A}))},[O,A]),getEstimatedRowHeight:o.useMemo(()=>D?e=>D((0,y.A)({},e,{densityFactor:A})):void 0,[D,A]),getRowSpacing:o.useMemo(()=>N?e=>{const t=d.rowIdToIndexMap.get(e.id)??-1,r={isFirstVisible:0===t,isLastVisible:t===d.rows.length-1,indexRelativeToCurrentPage:t};return N((0,y.A)({},e,r,{indexRelativeToCurrentPage:n.current.getRowIndexRelativeToVisibleRows(e.id)}))}:void 0,[n,N,d.rows,d.rowIdToIndexMap]),applyRowHeight:(0,Nt.A)((e,t)=>n.current.unstable_applyPipeProcessors("rowHeight",e,t)),virtualizeColumnsWithAutoRowHeight:t.virtualizeColumnsWithAutoRowHeight,focusedVirtualCell:(0,Nt.A)(()=>Cl(n)),resizeThrottleMs:t.resizeThrottleMs,onResize:(0,Nt.A)(e=>n.current.publishEvent("resize",e)),onWheel:(0,Nt.A)(e=>{n.current.publishEvent("virtualScrollerWheel",{},e)}),onTouchMove:(0,Nt.A)(e=>{n.current.publishEvent("virtualScrollerTouchMove",{},e)}),onRenderContextChange:(0,Nt.A)(e=>{n.current.publishEvent("renderedRowsIntervalChange",e)}),onScrollChange:o.useCallback((e,t)=>{n.current.publishEvent("scrollPositionChange",{top:e.top,left:e.left,renderContext:t})},[n]),scrollReset:m,renderRow:o.useCallback(e=>(0,r.jsx)(L,(0,y.A)({row:e.model,rowId:e.id,index:e.rowIndex,selected:u(e.id),offsetLeft:e.offsetLeft,columnsTotalWidth:x,rowHeight:e.baseRowHeight,pinnedColumns:s,visibleColumns:a,firstColumnIndex:e.firstColumnIndex,lastColumnIndex:e.lastColumnIndex,focusedColumnIndex:e.focusedColumnIndex,isFirstVisible:e.isFirstVisible,isLastVisible:e.isLastVisible,isNotVisible:e.isVirtualFocusRow,showBottomBorder:e.showBottomBorder,scrollbarWidth:p,gridHasFiller:h},F),e.id),[x,h,u,s,L,F,p,a]),renderInfiniteLoadingTrigger:o.useCallback(e=>n.current.getInfiniteLoadingTriggerElement?.({lastRowId:e}),[n])});return Za(()=>{n.current.store.state.dimensions=P(j.store.state.dimensions,w,C,S,E),n.current.store.state.rowsMeta=j.store.state.rowsMeta,n.current.store.state.virtualization=j.store.state.virtualization}),na(j.store,ba.selectors.dimensions,(e,t)=>{t.isReady&&n.current.setState(e=>(0,y.A)({},e,{dimensions:P(t,w,C,S,E)}))}),na(j.store,ba.selectors.rowsMeta,(e,t)=>{t!==n.current.state.rowsMeta&&n.current.setState(e=>(0,y.A)({},e,{rowsMeta:t}))}),na(j.store,ka.selectors.store,(e,t)=>{t.renderContext!==Ea&&t!==n.current.state.virtualization&&n.current.setState(e=>(0,y.A)({},e,{virtualization:t}))}),n.current.register("private",{virtualizer:j}),(e=>{const t=e.current.virtualizer,{getRowHeight:n,setLastMeasuredRowIndex:r,storeRowHeightMeasurement:o,resetRowHeights:i,hydrateRowsMeta:a,observeRowHeight:l,rowHasAutoHeight:s,getRowHeightEntry:c,getLastMeasuredRowIndex:u}=t.api.rowsMeta;_l(e,"rowHeight",a);const d={hydrateRowsMeta:a,observeRowHeight:l,rowHasAutoHeight:s,getRowHeightEntry:c,getLastMeasuredRowIndex:u};Bl(e,{unstable_getRowHeight:n,unstable_setLastMeasuredRowIndex:r,unstable_storeRowHeightMeasurement:o,resetRowHeights:i},"public"),Bl(e,d,"private")})(n),j}().api.getters,{getContainerProps:g,getScrollerProps:m,getContentProps:A,getPositionerProps:b,getScrollbarVerticalProps:v,getScrollbarHorizontalProps:w,getRows:C,getScrollAreaProps:S}=h,x=C(void 0,It(t));return(0,r.jsxs)(Ri,(0,y.A)({className:p.root},g(),{ownerState:f,children:[(0,r.jsx)($o,(0,y.A)({scrollDirection:"left"},S())),(0,r.jsx)($o,(0,y.A)({scrollDirection:"right"},S())),(0,r.jsx)($o,(0,y.A)({scrollDirection:"up"},S())),(0,r.jsx)($o,(0,y.A)({scrollDirection:"down"},S())),(0,r.jsxs)(Nl,(0,y.A)({className:p.scroller},m(),{ownerState:f,children:[(0,r.jsxs)(Pi,{children:[!n.listView&&(0,r.jsx)(Ei,{}),(0,r.jsx)(n.slots.pinnedRows,{position:"top",virtualScroller:h})]}),c&&(0,r.jsx)(Zi,{overlayType:c,loadingOverlayVariant:u,children:(0,r.jsx)(d,(0,y.A)({},n.slotProps?.[c]))}),(0,r.jsx)(Ti,(0,y.A)({},A(),{children:(0,r.jsxs)(zi,(0,y.A)({role:"rowgroup"},b(),{children:[x,(0,r.jsx)(n.slots.detailPanels,{virtualScroller:h})]}))})),s&&(0,r.jsx)(Qi,{rowsLength:x.length}),(0,r.jsx)(n.slots.bottomContainer,{children:(0,r.jsx)(n.slots.pinnedRows,{position:"bottom",virtualScroller:h})})]})),a&&(0,r.jsxs)(o.Fragment,{children:[n.pinnedColumnsSectionSeparator?.endsWith("shadow")&&(0,r.jsx)(Ki,{position:"horizontal"}),(0,r.jsx)(qi,(0,y.A)({position:"horizontal"},w()))]}),i&&(0,r.jsxs)(o.Fragment,{children:[n.pinnedRowsSectionSeparator?.endsWith("shadow")&&(0,r.jsx)(Ki,{position:"vertical"}),(0,r.jsx)(qi,(0,y.A)({position:"vertical"},v()))]}),a&&i&&(0,r.jsx)(Ui,{"aria-hidden":"true"}),e.children]}))}function Ql(){const e=se();return e.hideFooter?null:(0,r.jsx)(e.slots.footer,(0,y.A)({},e.slotProps?.footer))}const jl=["className","children","sidePanel"],zl=S(function(e,t){const n=se(),{className:i,children:a,sidePanel:l}=e,s=(0,x.A)(e,jl),c=Z(),u=J(c,Pe),d=c.current.rootElementRef,f=o.useCallback(e=>{null!==e&&c.current.publishEvent("rootMount",e)},[c]),p=(0,I.A)(d,t,f),h=n,g=((e,t)=>{const{autoHeight:n,classes:r,showCellVerticalBorder:o}=e,i={root:["root",n&&"autoHeight",`root--density${(0,k.A)(t)}`,null===e.slots.toolbar&&"root--noToolbar","withBorderColor",o&&"withVerticalBorder"]};return(0,R.A)(i,D,r)})(h,u),m=o.useContext(de);return(0,H.useSyncExternalStore)(_e,Te,Oe)?null:(0,r.jsxs)(ne,(0,y.A)({className:(0,E.A)(g.root,i,m.className,l&&L.withSidePanel),ownerState:h},s,{ref:p,children:[(0,r.jsxs)("div",{className:L.mainContent,role:"presentation",children:[(0,r.jsx)(ct,{}),(0,r.jsx)(Fl,{children:a}),(0,r.jsx)(Ql,{})]}),l,m.tag]}))}),$l=B(zl);function Hl(e,t){const n=It(e),r=Vo(e),o=Zo(e),i=n[t];if(!i||"group"!==i.type)return[];const a=[];for(let l=r.findIndex(e=>e===t)+1;l<r.length&&n[r[l]]?.depth>i.depth;l+=1){const t=r[l];!1!==o[t]&&e.current.isRowSelectable(t)&&a.push(t)}return a}const Gl=Ee($e,It,Zo,kl,Et,sr,(e,t,n,r,o,i,{groupId:a,autoSelectParents:l})=>{const s=t[a],c={id:a,row:o[a],columns:e};let u=!0;if("function"==typeof i&&o[a]&&(u=i(c)),!s||"group"!==s.type||r.has(a))return{isIndeterminate:!1,isChecked:r.has(a),isSelectable:u};let d=!1,f=!1;const p=a=>{if(!1===n[a]||d&&f)return;const l=t[a];"group"===l?.type&&l.children.forEach(p);const s={id:a,row:o[a],columns:e};("function"!=typeof i||!o[a]||i(s))&&(r.has(a)?d=!0:f=!0)};return p(a),{isIndeterminate:d&&f,isChecked:!!l&&d&&!f,isSelectable:u}});function Vl(e){return e.signature===el.DataGrid?e.checkboxSelection&&!0!==e.disableMultipleRowSelection:!e.disableMultipleRowSelection}const Wl=(e,t,n,r,o,i,a=kl(e))=>{const l=Zo(e),s=new Set([]);if((r||o)&&!1!==l[n]){if(r){const r=t[n];"group"===r?.type&&Hl(e,n).forEach(e=>{i(e),s.add(e)})}if(o){const r=n=>{const o=t[n];return!!o&&("group"!==o.type?!e.current.isRowSelectable(n)||a.has(n)||s.has(n):!(!a.has(n)&&!s.has(n))||o.children.every(r))},o=n=>{const a=((e,t,n)=>{const r=e[n];if(!r)return[];const o=r.parent;return null==o?[]:e[o].children.filter(e=>e!==n&&!1!==t[e])})(t,l,n),c=a.every(t=>!e.current.isRowSelectable(t)||r(t));if(0===a.length||c){const r=t[n],a=r?.parent;null!=a&&a!==Un&&e.current.isRowSelectable(a)&&(i(a),s.add(a),o(a))}},c=t[n];if(!c||c.parent===Un)return;o(n)}}},Ul=(e,t,n,r,o,i)=>{const a=kl(e);if(o||r){if(o){const e=((e,t)=>{const n=[];let r=t;for(;null!=r&&r!==Un;){const t=e[r];if(!t)return n;n.push(r),r=t.parent}return n})(t,n);e.forEach(e=>{a.has(e)&&i(e)})}if(r){const r=t[n];"group"===r?.type&&Hl(e,n).forEach(e=>{i(e)})}}};function ql({privateApiRef:e,configuration:t,props:n,children:i}){const a=o.useRef(e.current.getPublicApi());return(0,r.jsx)(ce.Provider,{value:t,children:(0,r.jsx)(le.Provider,{value:n,children:(0,r.jsx)(X.Provider,{value:e,children:(0,r.jsx)(rt.Provider,{value:a,children:(0,r.jsx)(lt,{children:(0,r.jsx)(pe,{children:i})})})})})})}const Yl=function(){try{const e="__some_random_key_you_are_not_going_to_use__";return window.localStorage.setItem(e,e),window.localStorage.removeItem(e),!0}catch(e){return!1}}()&&null!=window.localStorage.getItem("DEBUG"),Kl=()=>{},Jl={debug:Kl,info:Kl,warn:Kl,error:Kl},Xl=["debug","info","warn","error"];function Zl(e,t,n=console){const r=Xl.indexOf(t);if(-1===r)throw new Error(`MUI X: Log level ${t} not recognized.`);return Xl.reduce((t,o,i)=>(t[o]=i>=r?(...t)=>{const[r,...i]=t;n[o](`MUI X: ${e} - ${r}`,...i)}:Kl,t),{})}function es(e){return es="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},es(e)}function ts(e){var t=function(e){if("object"!=es(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var n=t.call(e,"string");if("object"!=es(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==es(t)?t:t+""}let ns=function(e){return e.DataSource="dataSource",e.RowTree="rowTree",e}({});const rs="none",os={dataSourceRowsUpdate:ns.DataSource,rowTreeCreation:ns.RowTree,filtering:ns.RowTree,sorting:ns.RowTree,visibleRowsLookupCreation:ns.RowTree},is=(e,t)=>(0,y.A)({},e,{props:{listView:t.listView,getRowId:t.getRowId,isCellEditable:t.isCellEditable,isRowSelectable:t.isRowSelectable,dataSource:t.dataSource}}),as=(e,t,n,r)=>{const i=o.useRef(r),a=o.useRef(!1);r!==i.current&&(a.current=!1,i.current=r),a.current||(t.current.state=e(t.current.state,n,t),a.current=!0)};function ls(e,t){const n=o.useRef(null);if(n.current)return n.current;const r=e.current.getLogger(t);return n.current=r,r}const ss=(e,t,n,r,o)=>{const i=ls(e,"useNativeEventListener");Gt(e,"rootMount",()=>{const e=t();if(e&&n)return i.debug(`Binding native ${n} event`),e.addEventListener(n,r,o),()=>{i.debug(`Clearing native ${n} event`),e.removeEventListener(n,r,o)}})},cs=["field","id","formattedValue","row","rowNode","colDef","isEditable","cellMode","hasFocus","tabIndex","api"],us=S(function(e,t){const{field:n,id:i,rowNode:a,tabIndex:l}=e,s=(0,x.A)(e,cs),c=ot(),u=se(),d=(e=>{const{classes:t}=e;return(0,R.A)({root:["checkboxInput"]},D,t)})({classes:u.classes}),{isIndeterminate:f,isChecked:p,isSelectable:h}=J(c,Gl,{groupId:i,autoSelectParents:u.rowSelectionPropagation?.parents??!1},W),g=!h;o.useLayoutEffect(()=>{if(0===l&&!g){const e=c.current.getCellElement(i,n);e&&(e.tabIndex=-1)}},[c,l,i,n,g]);const m=(0,Nt.A)(e=>{" "===e.key&&e.stopPropagation()}),A=(0,Nt.A)(e=>{g&&e.preventDefault()}),b=(0,Nt.A)(()=>{});if("footer"===a.type||"pinnedRow"===a.type)return null;const v=c.current.getLocaleText(p&&!f?"checkboxSelectionUnselectRow":"checkboxSelectionSelectRow");return(0,r.jsx)(u.slots.baseCheckbox,(0,y.A)({tabIndex:g?-1:l,checked:p&&!f,onChange:e=>{if(g)return;const t={value:e.target.checked,id:i};c.current.publishEvent("rowSelectionCheckboxChange",t,e)},onClick:A,onMouseDown:b,className:(0,E.A)(d.root,g&&"Mui-disabled"),disabled:g,material:{disableRipple:g},slotProps:{htmlInput:{"aria-disabled":g||void 0,"aria-label":v,name:"select_row"}},onKeyDown:m,indeterminate:f},u.slotProps?.baseCheckbox,s,{ref:t}))}),ds=us,fs=["field","colDef"],ps=S(function(e,t){const n=(0,x.A)(e,fs),[,i]=o.useState(!1),a=ot(),l=se(),s=(e=>{const{classes:t}=e;return(0,R.A)({root:["checkboxInput"]},D,t)})({classes:l.classes}),c=J(a,Ci),u=J(a,Il),d=J(a,ti),f=J(a,hl),p=o.useMemo(()=>{const e=l.isRowSelectable;if("function"!=typeof e)return u;if("exclude"===u.type)return u;const t={type:"include",ids:new Set};for(const n of u.ids)l.keepNonExistentRowsSelected&&t.ids.add(n),a.current.getRow(n)&&e(a.current.getRowParams(n))&&t.ids.add(n);return t},[a,l.isRowSelectable,l.keepNonExistentRowsSelected,u]),h=o.useMemo(()=>{const e=l.pagination&&l.checkboxSelectionVisibleOnly&&"server"!==l.paginationMode?f:d,t=new Set;for(let n=0;n<e.length;n+=1){const r=e[n];a.current.getRow(r)&&a.current.isRowSelectable(r)&&t.add(r)}return t},[a,l.pagination,l.paginationMode,l.checkboxSelectionVisibleOnly,f,d]),g=o.useMemo(()=>{const e=El(p);let t=0;for(const n of h)e.has(n)&&(t+=1);return t},[p,h]),m=o.useMemo(()=>{if(0===g)return!1;const e=El(p);for(const t of h)if(!e.has(t))return!0;return!1},[g,p,h]),A=g>0,b=Vl(l),v=null!==c&&c.field===e.field&&b?0:-1;(0,Ut.A)(()=>{const t=a.current.getColumnHeaderElement(e.field);0===v&&t&&b&&(t.tabIndex=-1)},[v,a,e.field,b]);const w=o.useCallback(e=>{" "===e.key&&a.current.publishEvent("headerSelectionCheckboxChange",{value:!A})},[a,A]),C=o.useCallback(()=>{i(e=>!e)},[]);o.useEffect(()=>a.current.subscribeEvent("rowSelectionChange",C),[a,C]);const S=a.current.getLocaleText(A&&!m?"checkboxSelectionUnselectAllRows":"checkboxSelectionSelectAllRows");return(0,r.jsx)(l.slots.baseCheckbox,(0,y.A)({indeterminate:m,checked:A&&!m,onChange:e=>{const t={value:e.target.checked};a.current.publishEvent("headerSelectionCheckboxChange",t)},className:s.root,slotProps:{htmlInput:{"aria-label":S,name:"select_all_rows"}},tabIndex:v,onKeyDown:w,disabled:!b},l.slotProps?.baseCheckbox,n,{ref:t}))}),hs="__check__",gs=(0,y.A)({},Ir,{type:"custom",field:hs,width:50,resizable:!1,sortable:!1,filterable:!1,aggregable:!1,chartable:!1,disableColumnMenu:!0,disableReorder:!0,disableExport:!0,getApplyQuickFilterFn:()=>null,display:"flex",valueGetter:(e,t,n,r)=>{const o=lr(r,t);return r.current.isRowSelected(o)},rowSpanValueGetter:(e,t,n,r)=>lr(r,t),renderHeader:e=>(0,r.jsx)(ps,(0,y.A)({},e)),renderCell:e=>(0,r.jsx)(ds,(0,y.A)({},e))});function ms(e,t){if(null==e)return"";const n="string"==typeof e?e:`${e}`;if(t.shouldAppendQuotes||t.escapeFormulas){const e=n.replace(/"/g,'""');return t.escapeFormulas&&["=","+","-","@","\t","\r"].includes(e[0])?`"'${e}"`:[t.delimiter,"\n","\r",'"'].some(e=>n.includes(e))?`"${e}"`:e}return n}const As=(e,t)=>{const{csvOptions:n,ignoreValueFormatter:r}=t;let o;if(r){const t=e.colDef.type;o="number"===t?String(e.value):"date"===t||"dateTime"===t?e.value?.toISOString():"function"==typeof e.value?.toString?e.value.toString():e.value}else o=e.formattedValue;return ms(o,n)};class bs{rowString="";isEmpty=!0;constructor(e){this.options=e}addValue(e){this.isEmpty||(this.rowString+=this.options.csvOptions.delimiter),"function"==typeof this.options.sanitizeCellValue?this.rowString+=this.options.sanitizeCellValue(e,this.options.csvOptions):this.rowString+=e,this.isEmpty=!1}getRowString(){return this.rowString}}function vs(e){const t=document.createElement("span");t.style.whiteSpace="pre",t.style.userSelect="all",t.style.opacity="0px",t.textContent=e,document.body.appendChild(t);const n=document.createRange();n.selectNode(t);const r=window.getSelection();r.removeAllRanges(),r.addRange(n);try{document.execCommand("copy")}finally{document.body.removeChild(t)}}const ys=e=>(0,y.A)({},e,{columnMenu:{open:!1}}),ws=(e,t,n,r=!0)=>{const i=o.useRef(null),a=o.useRef(`mui-${Math.round(1e9*Math.random())}`),l=o.useCallback(()=>{i.current=e.current.registerPipeProcessor(t,a.current,n)},[e,n,t]);Za(()=>{r&&l()});const s=o.useRef(!0);o.useEffect(()=>(s.current?s.current=!1:r&&l(),()=>{i.current&&(i.current(),i.current=null)}),[l,r])},Cs=(e,t,n)=>{n.current.caches.columns={lastColumnsProp:t.columns};const r=Oo({apiRef:n,columnsToUpsert:t.columns,initialState:t.initialState?.columns,columnVisibilityModel:t.columnVisibilityModel??t.initialState?.columns?.columnVisibilityModel??{},keepOnlyColumnsToUpsert:!0});return(0,y.A)({},e,{columns:r,pinnedColumns:e.pinnedColumns??Ne})};const Ss=(e,t)=>(0,y.A)({},e,{density:t.initialState?.density??t.density??"standard"}),xs=({apiRef:e,options:t})=>{const n=$e(e);return t.fields?t.fields.reduce((e,t)=>{const r=n.find(e=>e.field===t);return r&&e.push(r),e},[]):(t.allColumns?n:Ve(e)).filter(e=>!0!==e.disableExport)},Es=({apiRef:e})=>{const t=ri(e),n=It(e),r=Rl(e),o=t.filter(e=>"footer"!==n[e].type),i=Ot(e),a=i?.top?.map(e=>e.id)||[],l=i?.bottom?.map(e=>e.id)||[];if(o.unshift(...a),o.push(...l),r>0){const t=Ml(e);return o.filter(e=>t.has(e))}return o},Is=S(function(e,t){const{children:n,slotProps:i={}}=e,a=i.button||{},l=i.tooltip||{},s=ot(),c=se(),u=(0,an.A)(),d=(0,an.A)(),[f,p]=o.useState(!1),h=o.useRef(null),g=(0,I.A)(t,h),m=()=>p(!1);return null==n?null:(0,r.jsxs)(o.Fragment,{children:[(0,r.jsx)(c.slots.baseTooltip,(0,y.A)({title:s.current.getLocaleText("toolbarExportLabel"),enterDelay:1e3},c.slotProps?.baseTooltip,l,{children:(0,r.jsx)(c.slots.baseButton,(0,y.A)({size:"small",startIcon:(0,r.jsx)(c.slots.exportIcon,{}),"aria-expanded":f,"aria-label":s.current.getLocaleText("toolbarExportLabel"),"aria-haspopup":"menu","aria-controls":f?d:void 0,id:u},c.slotProps?.baseButton,a,{onClick:e=>{p(e=>!e),a.onClick?.(e)},ref:g,children:s.current.getLocaleText("toolbarExport")}))})),(0,r.jsx)(Kr,{open:f,target:h.current,onClose:m,position:"bottom-end",children:(0,r.jsx)(c.slots.baseMenuList,{id:d,className:L.menuList,"aria-labelledby":u,autoFocusItem:f,children:o.Children.map(n,e=>o.isValidElement(e)?o.cloneElement(e,{hideMenu:m}):e)})})]})}),ks=["hideMenu","options"],Rs=["hideMenu","options"],Ms=["csvOptions","printOptions","excelOptions"];function Ps(e){const t=ot(),n=se(),{hideMenu:o,options:i}=e,a=(0,x.A)(e,ks);return(0,r.jsx)(n.slots.baseMenuItem,(0,y.A)({onClick:()=>{t.current.exportDataAsCsv(i),o?.()}},a,{children:t.current.getLocaleText("toolbarExportCSV")}))}function Bs(e){const t=ot(),n=se(),{hideMenu:o,options:i}=e,a=(0,x.A)(e,Rs);return(0,r.jsx)(n.slots.baseMenuItem,(0,y.A)({onClick:()=>{t.current.exportDataAsPrint(i),o?.()}},a,{children:t.current.getLocaleText("toolbarExportPrint")}))}S(function(e,t){const n=e,{csvOptions:i={},printOptions:a={},excelOptions:l}=n,s=(0,x.A)(n,Ms),c=ot().current.unstable_applyPipeProcessors("exportMenu",[],{excelOptions:l,csvOptions:i,printOptions:a}).sort((e,t)=>e.componentName>t.componentName?1:-1);return 0===c.length?null:(0,r.jsx)(Is,(0,y.A)({},s,{ref:t,children:c.map((e,t)=>o.cloneElement(e.component,{key:t}))}))});const _s=(e,t)=>{const n=ls(e,"useGridCsvExport"),i=t.ignoreValueFormatterDuringExport,a=("object"==typeof i?i?.csvExport:i)||!1,l=o.useCallback((t={})=>(n.debug("Get data as CSV"),function(e){const{columns:t,rowIds:n,csvOptions:r,ignoreValueFormatter:o,apiRef:i}=e,a=n.reduce((e,n)=>`${e}${(({id:e,columns:t,getCellParams:n,csvOptions:r,ignoreValueFormatter:o})=>{const i=new bs({csvOptions:r});return t.forEach(t=>{const a=n(e,t.field);String(a.formattedValue),i.addValue(As(a,{ignoreValueFormatter:o,csvOptions:r}))}),i.getRowString()})({id:n,columns:t,getCellParams:i.current.getCellParams,ignoreValueFormatter:o,csvOptions:r})}\r\n`,"").trim();if(!r.includeHeaders)return a;const l=t.filter(e=>e.field!==gs.field),s=[];if(r.includeColumnGroupsHeaders){const e=i.current.getAllGroupDetails();let t=0;const n=l.reduce((e,n)=>{const r=i.current.getColumnGroupPath(n.field);return e[n.field]=r,t=Math.max(t,r.length),e},{});for(let o=0;o<t;o+=1){const t=new bs({csvOptions:r,sanitizeCellValue:ms});s.push(t),l.forEach(r=>{const i=(n[r.field]||[])[o],a=e[i];t.addValue(a?a.headerName||a.groupId:"")})}}const c=new bs({csvOptions:r,sanitizeCellValue:ms});return l.forEach(e=>{c.addValue(e.headerName||e.field)}),s.push(c),`${s.map(e=>e.getRowString()).join("\r\n")}\r\n${a}`.trim()}({columns:xs({apiRef:e,options:t}),rowIds:(t.getRowsToExport??Es)({apiRef:e}),csvOptions:{delimiter:t.delimiter||",",shouldAppendQuotes:t.shouldAppendQuotes??!0,includeHeaders:t.includeHeaders??!0,includeColumnGroupsHeaders:t.includeColumnGroupsHeaders??!0,escapeFormulas:t.escapeFormulas??!0},ignoreValueFormatter:a,apiRef:e})),[n,e,a]),s=o.useCallback(e=>{n.debug("Export data as CSV");const t=l(e);!function(e,t="csv",n=document.title||"untitled"){const r=`${n}.${t}`;if("download"in HTMLAnchorElement.prototype){const t=URL.createObjectURL(e),n=document.createElement("a");return n.href=t,n.download=r,n.click(),void setTimeout(()=>{URL.revokeObjectURL(t)})}throw new Error("MUI X: exportAs not supported.")}(new Blob([e?.utf8WithBom?new Uint8Array([239,187,191]):"",t],{type:"text/csv"}),"csv",e?.fileName)},[n,l]);Bl(e,{getDataAsCsv:l,exportDataAsCsv:s},"public");const c=o.useCallback((e,t)=>t.csvOptions?.disableToolbarButton?e:[...e,{component:(0,r.jsx)(Ps,{options:t.csvOptions}),componentName:"csvExport"}],[]);ws(e,"exportMenu",c)};var Ts=n(3075);const Os=(e,t,n)=>{let r=e.paginationModel;const o=e.rowCount,i=n?.pageSize??r.pageSize,a=n?.page??r.page,l=tl(o,i,a);!n||n?.page===r.page&&n?.pageSize===r.pageSize||(r=n);const s=-1===i?0:((e,t=0)=>0===t?e:Math.max(Math.min(e,t-1),0))(r.page,l);return s!==r.page&&(r=(0,y.A)({},r,{page:s})),rl(r.pageSize,t),r},Ds=(e,t,n,r)=>{const i=o.useCallback(()=>{e.current.registerStrategyProcessor(t,n,r)},[e,r,n,t]);Za(()=>{i()});const a=o.useRef(!0);o.useEffect(()=>{a.current?a.current=!1:i()},[i])},Ns=(e,t,n)=>{const r=t.filterModel??t.initialState?.filter?.filterModel??vn();return(0,y.A)({},e,{filter:(0,y.A)({filterModel:Sn(r,t.disableMultipleColumnsFiltering,n)},bn),visibleRowsLookup:{}})},Ls=e=>e.filteredRowsLookup;function Fs(e,t){return e.current.applyStrategyProcessor("visibleRowsLookupCreation",{tree:t.rows.tree,filteredRowsLookup:t.filter.filteredRowsLookup})}function Qs(){return Ae(Object.values)}let js;function zs(){return void 0===js&&document.createElement("div").focus({get preventScroll(){return js=!0,!1}}),js}const $s=e=>(0,y.A)({},e,{focus:{cell:null,columnHeader:null,columnHeaderFilter:null,columnGroupHeader:null},tabIndex:{cell:null,columnHeader:null,columnHeaderFilter:null,columnGroupHeader:null}});function Hs(e,t){return e.closest(`.${t}`)}function Gs(e){return e.replace(/["\\]/g,"\\$&")}function Vs(e){return`.${L.row}[data-id="${Gs(String(e))}"]`}function Ws(e){return 1===e.target.nodeType&&!e.currentTarget.contains(e.target)}function Us(e,t){return e.rootElementRef.current.querySelector(`.${L[t]}`)}const qs=({api:e,colIndex:t,position:n,filterFn:r})=>{if(null===t)return[];const o=[];return Ks(e).forEach(e=>{e.getAttribute("data-id")&&e.querySelectorAll(`.${L["left"===n?"cell--pinnedLeft":"cell--pinnedRight"]}`).forEach(e=>{const t=Js(e);null!==t&&r(t)&&o.push(e)})}),o},Ys=({api:e,colIndex:t,position:n,filterFn:r})=>{if(!e.columnHeadersContainerRef?.current)return[];if(null===t)return[];const o=[];return e.columnHeadersContainerRef.current.querySelectorAll(`.${L["left"===n?"columnHeader--pinnedLeft":"columnHeader--pinnedRight"]}`).forEach(e=>{const t=Js(e);null!==t&&r(t,e)&&o.push(e)}),o};function Ks(e){return e.virtualScrollerRef.current.querySelectorAll(`:scope > div > div > .${L.row}`)}function Js(e){const t=e.getAttribute("aria-colindex");return t?Number(t)-1:null}const Xs=({currentColIndex:e,firstColIndex:t,lastColIndex:n,isRtl:r})=>{if(r){if(e<n)return e+1}else if(!r&&e>t)return e-1;return null},Zs=({currentColIndex:e,firstColIndex:t,lastColIndex:n,isRtl:r})=>{if(r){if(e>t)return e-1}else if(!r&&e<n)return e+1;return null},ec=Ie(gl,Ot,(e,t)=>(t.top||[]).concat(e.rows,t.bottom||[])),tc=(e,t)=>{const n=(0,y.A)({},nl(t.autoPageSize),t.paginationModel??t.initialState?.pagination?.paginationModel);rl(n.pageSize,t.signature);const r=t.rowCount??t.initialState?.pagination?.rowCount??("client"===t.paginationMode?e.rows?.totalRowCount:void 0),o=t.paginationMeta??t.initialState?.pagination?.meta??{};return(0,y.A)({},e,{pagination:(0,y.A)({},e.pagination,{paginationModel:n,rowCount:r,meta:o,enabled:!0===t.pagination,paginationMode:t.paginationMode})})},nc=(e,t)=>(0,y.A)({},e,{preferencePanel:t.initialState?.preferencePanel??{open:!1}}),rc=ke(e=>e.editRows),oc=Ee(rc,(e,{rowId:t,editMode:n})=>n===Mr.Row&&Boolean(e[t])),ic=Ee(rc,(e,{rowId:t,field:n})=>e[t]?.[n]??null),ac=e=>{switch(e.type){case"boolean":return!1;case"date":case"dateTime":case"number":return;case"singleSelect":return null;default:return""}},lc=["id","field"],sc=["id","field"];var cc=function(e){return e.enterKeyDown="enterKeyDown",e.cellDoubleClick="cellDoubleClick",e.printableKeyDown="printableKeyDown",e.deleteKeyDown="deleteKeyDown",e}(cc||{}),uc=function(e){return e.rowFocusOut="rowFocusOut",e.escapeKeyDown="escapeKeyDown",e.enterKeyDown="enterKeyDown",e.tabKeyDown="tabKeyDown",e.shiftTabKeyDown="shiftTabKeyDown",e}(uc||{});const dc=["id"],fc=["id"],pc=e=>(0,y.A)({},e,{editRows:{}}),hc=(e,t,n)=>{const r=!!t.dataSource;return n.current.caches.rows=Jn({rows:r?[]:t.rows,getRowId:t.getRowId,loading:t.loading,rowCount:t.rowCount}),(0,y.A)({},e,{rows:Zn({apiRef:n,rowCountProp:t.rowCount,loadingProp:!!r||t.loading,previousTree:null,previousTreeDepths:null})})},gc=e=>"full"===e.updates.type?(e=>{const t={[Un]:(0,y.A)({},{type:"group",id:Un,depth:-1,groupingField:null,groupingKey:null,isAutoGenerated:!0,children:[],childrenFromPath:Object.create(null),childrenExpanded:!0,parent:null},{children:e})};for(let n=0;n<e.length;n+=1){const r=e[n];t[r]={id:r,depth:0,parent:Un,type:"leaf",groupingKey:null}}return{groupingName:rs,tree:t,treeDepths:{0:e.length},dataRowIds:e}})(e.updates.rows):(({previousTree:e,actions:t})=>{const n=(0,y.A)({},e),r={};for(let e=0;e<t.remove.length;e+=1){const o=t.remove[e];r[o]=!0,delete n[o]}for(let e=0;e<t.insert.length;e+=1){const r=t.insert[e];n[r]={id:r,depth:0,parent:Un,type:"leaf",groupingKey:null}}const o=n[Un];let i=[...o.children,...t.insert];return Object.values(r).length&&(i=i.filter(e=>!r[e])),n[Un]=(0,y.A)({},o,{children:i}),{groupingName:rs,tree:n,treeDepths:{0:i.length},dataRowIds:i}})({previousTree:e.previousTree,actions:e.updates.actions});class mc extends Error{}const Ac={type:"include",ids:new Set},bc=(e,t)=>(0,y.A)({},e,{rowSelection:t.rowSelection?t.rowSelectionModel??Ac:Ac}),vc=(e,t)=>{const n=t.sortModel??t.initialState?.sorting?.sortModel??[];return(0,y.A)({},e,{sorting:{sortModel:Xt(n,t.disableMultipleColumnsSorting),sortedRows:[]}})};function yc(e){const{containerSize:t,scrollPosition:n,elementSize:r,elementOffset:o}=e,i=o+r;return r>t?o:i-t>n?i-t:o<n?o:void 0}const wc={width:0,height:0},Cc={isReady:!1,root:wc,viewportOuterSize:wc,viewportInnerSize:wc,contentSize:wc,minimumSize:wc,hasScrollX:!1,hasScrollY:!1,scrollbarSize:0,headerHeight:0,groupHeaderHeight:0,headerFilterHeight:0,rowWidth:0,rowHeight:0,columnsTotalWidth:0,leftPinnedWidth:0,rightPinnedWidth:0,headersTotalHeight:0,topContainerHeight:0,bottomContainerHeight:0,autoHeight:!1,minimalContentHeight:void 0},Sc=(e,t,n)=>{const r=Cc,o=Be(n),i=(0,y.A)({},r,function(e,t,n,r){const o=ar(e.rowHeight,Pl.rowHeight);return{rowHeight:Math.floor(o*n),headerHeight:Math.floor(e.columnHeaderHeight*n),groupHeaderHeight:Math.floor((e.columnGroupHeaderHeight??e.columnHeaderHeight)*n),headerFilterHeight:Math.floor((e.headerFilterHeight??e.columnHeaderHeight)*n),columnsTotalWidth:xc(t),headersTotalHeight:Do(t,e),leftPinnedWidth:r.left.reduce((e,t)=>e+t.computedWidth,0),rightPinnedWidth:r.right.reduce((e,t)=>e+t.computedWidth,0)}}(t,n,o,qe(n)));return n.current.store.state.dimensions=i,(0,y.A)({},e,{dimensions:i})},xc=Ee(Ve,Ke,(e,t)=>{const n=e.length;return 0===n?0:ea(t[n-1]+e[n-1].computedWidth,1)});function Ec(e,t){const n=(t,n)=>e.style.setProperty(t,n);n("--DataGrid-hasScrollX",`${Number(t.hasScrollX)}`),n("--DataGrid-hasScrollY",`${Number(t.hasScrollY)}`),n("--DataGrid-scrollbarSize",`${t.scrollbarSize}px`),n("--DataGrid-rowWidth",`${t.rowWidth}px`),n("--DataGrid-columnsTotalWidth",`${t.columnsTotalWidth}px`),n("--DataGrid-leftPinnedWidth",`${t.leftPinnedWidth}px`),n("--DataGrid-rightPinnedWidth",`${t.rightPinnedWidth}px`),n("--DataGrid-headerHeight",`${t.headerHeight}px`),n("--DataGrid-headersTotalHeight",`${t.headersTotalHeight}px`),n("--DataGrid-topContainerHeight",`${t.topContainerHeight}px`),n("--DataGrid-bottomContainerHeight",`${t.bottomContainerHeight}px`),n("--height",`${t.rowHeight}px`)}function Ic(e){return void 0!==e.field}const kc=["groupId","children"],Rc=e=>{const t={};for(let n=0;n<e.length;n+=1){const r=e[n];if(Ic(r))continue;const{groupId:o,children:i}=r,a=(0,x.A)(r,kc);if(!o)throw new Error("MUI X: An element of the columnGroupingModel does not have either `field` or `groupId`.");const l=(0,y.A)({},a,{groupId:o}),s=Rc(i);if(void 0!==s[o]||void 0!==t[o])throw new Error(`MUI X: The groupId ${o} is used multiple times in the columnGroupingModel.`);Object.assign(t,s),t[o]=l}return t},Mc=(e,t,n)=>{if(Ic(e)){if(void 0!==n[e.field])throw new Error(["MUI X: columnGroupingModel contains duplicated field",`column field ${e.field} occurs two times in the grouping model:`,`- ${n[e.field].join(" > ")}`,`- ${t.join(" > ")}`].join("\n"));return void(n[e.field]=t)}const{groupId:r,children:o}=e;o.forEach(e=>{Mc(e,[...t,r],n)})},Pc=e=>{if(!e)return{};const t={};return e.forEach(e=>{Mc(e,[],t)}),t},Bc=(e,t,n)=>{const r=e=>t[e]??[],o=[],i=Math.max(0,...e.map(e=>r(e).length)),a=(e,t,n)=>{const o=r(e),i=r(t);for(let e=0;e<=n;e+=1)if(o[e]!==i[e])return!1;return!0},l=(e,t)=>{const r=n?.left,o=n?.right,i=!!r?.includes(e),a=!!r?.includes(t),l=!!o?.includes(e),s=!!o?.includes(t);return i!==a||l!==s};for(let t=0;t<i;t+=1){const n=[];for(let o=0;o<e.length;o+=1){const i=e[o],s=r(i)[t]??null;if(0===n.length){n.push({columnFields:[i],groupId:s});continue}const c=n[n.length-1],u=c.columnFields[c.columnFields.length-1];c.groupId!==s||!a(u,i,t)||l(u,i)?n.push({columnFields:[i],groupId:s}):c.columnFields.push(i)}o.push(n)}return o},_c=(e,t,n)=>{if(n.current.caches.columnGrouping={lastColumnGroupingModel:t.columnGroupingModel},!t.columnGroupingModel)return(0,y.A)({},e,{columnGrouping:void 0});const r=je(n),o=We(n),i=Rc(t.columnGroupingModel??[]),a=Pc(t.columnGroupingModel??[]),l=Bc(r,a,n.current.state.pinnedColumns??{}),s=0===o.length?0:Math.max(...o.map(e=>a[e]?.length??0));return(0,y.A)({},e,{columnGrouping:{lookup:i,unwrappedGroupingModel:a,headerStructure:l,maxDepth:s}})},Tc=!("undefined"!=typeof window&&/jsdom|HappyDOM/.test(window.navigator.userAgent)),Oc=(e,t)=>{const{disableVirtualization:n,autoHeight:r}=t,o={enabled:!n&&Tc,enabledForColumns:!n&&Tc,enabledForRows:!n&&!r&&Tc,renderContext:Ea};return(0,y.A)({},e,{virtualization:o})},Dc={includeHeaders:!0,includeHeaderFilters:!1,includeOutliers:!1,outliersFactor:1.5,expand:!1,disableColumnVirtualization:!0},Nc=Ee(ke(e=>e.columnResize),e=>e.resizingColumnField);function Lc(e,t){if(void 0!==t&&e.changedTouches){for(let n=0;n<e.changedTouches.length;n+=1){const r=e.changedTouches[n];if(r.identifier===t)return{x:r.clientX,y:r.clientY}}return!1}return{x:e.clientX,y:e.clientY}}function Fc(e,t,n,r){let o=e;return o+="Right"===r?t-n.left:n.right-t,Math.round(o)}function Qc(e,t){return t===De.LEFT?e?"--DataGrid-rightPinnedWidth":"--DataGrid-leftPinnedWidth":e?"--DataGrid-leftPinnedWidth":"--DataGrid-rightPinnedWidth"}function jc(e,t,n){return n===De.LEFT?t?e.rightPinnedWidth:e.leftPinnedWidth:t?e.leftPinnedWidth:e.rightPinnedWidth}function zc(e){e.preventDefault(),e.stopImmediatePropagation()}const $c=e=>(0,y.A)({},e,{columnResize:{resizingColumnField:""}});function Hc(){return{colDef:void 0,initialColWidth:0,initialTotalWidth:0,previousMouseClickEvent:void 0,columnHeaderElement:void 0,headerFilterElement:void 0,groupHeaderElements:[],cellElements:[],leftPinnedCellsAfter:[],rightPinnedCellsBefore:[],fillerLeft:void 0,fillerRight:void 0,leftPinnedHeadersAfter:[],rightPinnedHeadersBefore:[]}}const Gc=(e,t)=>{const n=(0,Hr.I)(),r=ls(e,"useGridColumnResize"),i=(0,G.A)(Hc).current,a=o.useRef(null),l=o.useRef(null),s=(0,Vt.A)(),c=o.useRef(void 0),u=t=>{r.debug(`Updating width to ${t} for col ${i.colDef.field}`);const o=i.columnHeaderElement.offsetWidth,a=t-o,l=t-i.initialColWidth;if(l>0){const t=i.initialTotalWidth+l;e.current.rootElementRef?.current?.style.setProperty("--DataGrid-rowWidth",`${t}px`)}i.colDef.computedWidth=t,i.colDef.width=t,i.colDef.flex=0,i.columnHeaderElement.style.width=`${t}px`;const s=i.headerFilterElement;s&&(s.style.width=`${t}px`),i.groupHeaderElements.forEach(e=>{const n=e;let r;r="1"===n.getAttribute("aria-colspan")?`${t}px`:`${n.offsetWidth+a}px`,n.style.width=r}),i.cellElements.forEach(e=>{const n=e;let r;r="1"===n.getAttribute("aria-colspan")?`${t}px`:`${n.offsetWidth+a}px`,n.style.setProperty("--width",r)});const c=ut(e),u=e.current.unstable_applyPipeProcessors("isColumnPinned",!1,i.colDef.field);u===De.LEFT&&(Vc(i.fillerLeft,"width",a),i.leftPinnedCellsAfter.forEach(e=>{Vc(e,"left",a)}),i.leftPinnedHeadersAfter.forEach(e=>{Vc(e,"left",a)}),e.current.rootElementRef?.current?.style.setProperty(Qc(n,u),`${jc(c,n,u)+l}px`)),u===De.RIGHT&&(Vc(i.fillerRight,"width",a),i.rightPinnedCellsBefore.forEach(e=>{Vc(e,"right",a)}),i.rightPinnedHeadersBefore.forEach(e=>{Vc(e,"right",a)}),e.current.rootElementRef?.current?.style.setProperty(Qc(n,u),`${jc(c,n,u)+l}px`))},d=t=>{if(v(),i.previousMouseClickEvent){const n=i.previousMouseClickEvent,r=n.timeStamp,o=n.clientX,a=n.clientY;if(t.timeStamp-r<300&&t.clientX===o&&t.clientY===a)return i.previousMouseClickEvent=void 0,void e.current.publishEvent("columnResizeStop",null,t)}if(i.colDef){e.current.setColumnWidth(i.colDef.field,i.colDef.width),r.debug(`Updating col ${i.colDef.field} with new width: ${i.colDef.width}`);const t=Qe(e);i.groupHeaderElements.forEach(e=>{const n=e,r=`${e.getAttribute("data-fields").slice(2,-2).split("-|-").reduce((e,n)=>!1!==t.columnVisibilityModel[n]?e+t.lookup[n].computedWidth:e,0)}px`;n.style.width=r})}s.start(0,()=>{e.current.publishEvent("columnResizeStop",null,t)})},f=()=>{i.columnHeaderElement&&(i.cellElements=function(e,t){if(!Hs(e,L.root))throw new Error("MUI X: The root element is not found.");const n=e.getAttribute("aria-colindex");if(!n)return[];const r=Number(n)-1,o=[];return t.virtualScrollerRef?.current?(Ks(t).forEach(e=>{const n=e.getAttribute("data-id");if(!n)return;let i=r;const a=t.unstable_getCellColSpanInfo(n,r);a&&a.spannedByColSpan&&(i=a.leftVisibleCellIndex);const l=e.querySelector(`[data-colindex="${i}"]`);l&&o.push(l)}),o):[]}(i.columnHeaderElement,e.current))},p=(t,r,o)=>{const s=e.current.rootElementRef.current;var c,u;i.initialColWidth=t.computedWidth,i.initialTotalWidth=e.current.getRootDimensions().rowWidth,i.colDef=t,i.columnHeaderElement=(c=e.current.columnHeadersContainerRef.current,u=t.field,c.querySelector(`[data-field="${Gs(u)}"]`));const d=s.querySelector(`.${L.headerFilterRow} [data-field="${Gs(t.field)}"]`);d&&(i.headerFilterElement=d),i.groupHeaderElements=function(e,t){return Array.from(e.querySelectorAll(`[data-fields*="|-${Gs(t)}-|"]`)??[])}(e.current.columnHeadersContainerRef?.current,t.field),f(),i.fillerLeft=Us(e.current,n?"filler--pinnedRight":"filler--pinnedLeft"),i.fillerRight=Us(e.current,n?"filler--pinnedLeft":"filler--pinnedRight");const p=e.current.unstable_applyPipeProcessors("isColumnPinned",!1,i.colDef.field);i.leftPinnedCellsAfter=p!==De.LEFT?[]:function(e,t,n){const r=Js(t);return qs({api:e,colIndex:r,position:n?"right":"left",filterFn:e=>n?e<r:e>r})}(e.current,i.columnHeaderElement,n),i.rightPinnedCellsBefore=p!==De.RIGHT?[]:function(e,t,n){const r=Js(t);return qs({api:e,colIndex:r,position:n?"left":"right",filterFn:e=>n?e>r:e<r})}(e.current,i.columnHeaderElement,n),i.leftPinnedHeadersAfter=p!==De.LEFT?[]:function(e,t,n){const r=Js(t);return Ys({api:e,position:n?"right":"left",colIndex:r,filterFn:e=>n?e<r:e>r})}(e.current,i.columnHeaderElement,n),i.rightPinnedHeadersBefore=p!==De.RIGHT?[]:function(e,t,n){const r=Js(t);return Ys({api:e,position:n?"left":"right",colIndex:r,filterFn:(e,t)=>!t.classList.contains(L["columnHeader--last"])&&(n?e>r:e<r)})}(e.current,i.columnHeaderElement,n),l.current=function(e,t){const n=e.classList.contains(L["columnSeparator--sideRight"])?"Right":"Left";return t?function(e){return"Right"===e?"Left":"Right"}(n):n}(r,n),a.current=function(e,t,n){return"Left"===n?e-t.left:t.right-e}(o,i.columnHeaderElement.getBoundingClientRect(),l.current)},h=(0,Nt.A)(d),g=(0,Nt.A)(t=>{if(0===t.buttons)return void h(t);let n=Fc(a.current,t.clientX,i.columnHeaderElement.getBoundingClientRect(),l.current);n=fn(n,i.colDef.minWidth,i.colDef.maxWidth),u(n);const r={element:i.columnHeaderElement,colDef:i.colDef,width:n};e.current.publishEvent("columnResize",r,t)}),m=(0,Nt.A)(e=>{Lc(e,c.current)&&d(e)}),A=(0,Nt.A)(t=>{const n=Lc(t,c.current);if(!n)return;if("mousemove"===t.type&&0===t.buttons)return void m(t);let r=Fc(a.current,n.x,i.columnHeaderElement.getBoundingClientRect(),l.current);r=fn(r,i.colDef.minWidth,i.colDef.maxWidth),u(r);const o={element:i.columnHeaderElement,colDef:i.colDef,width:r};e.current.publishEvent("columnResize",o,t)}),b=(0,Nt.A)(t=>{const n=Hs(t.target,L["columnSeparator--resizable"]);if(!n)return;const o=t.changedTouches[0];null!=o&&(c.current=o.identifier);const i=Hs(t.target,L.columnHeader).getAttribute("data-field"),a=e.current.getColumn(i);r.debug(`Start Resize on col ${a.field}`),e.current.publishEvent("columnResizeStart",{field:i},t),p(a,n,o.clientX);const l=(0,aa.A)(t.currentTarget);l.addEventListener("touchmove",A),l.addEventListener("touchend",m)}),v=o.useCallback(()=>{const t=(0,aa.A)(e.current.rootElementRef.current);t.body.style.removeProperty("cursor"),t.removeEventListener("mousemove",g),t.removeEventListener("mouseup",h),t.removeEventListener("touchmove",A),t.removeEventListener("touchend",m),setTimeout(()=>{t.removeEventListener("click",zc,!0)},100),i.columnHeaderElement&&(i.columnHeaderElement.style.pointerEvents="unset")},[e,i,g,h,A,m]),w=o.useCallback(({field:t})=>{e.current.setState(e=>(0,y.A)({},e,{columnResize:(0,y.A)({},e.columnResize,{resizingColumnField:t})}))},[e]),C=o.useCallback(()=>{e.current.setState(e=>(0,y.A)({},e,{columnResize:(0,y.A)({},e.columnResize,{resizingColumnField:""})}))},[e]),S=(0,Nt.A)(({colDef:t},n)=>{if(0!==n.button)return;if(!n.currentTarget.classList.contains(L["columnSeparator--resizable"]))return;n.preventDefault(),r.debug(`Start Resize on col ${t.field}`),e.current.publishEvent("columnResizeStart",{field:t.field},n),p(t,n.currentTarget,n.clientX);const o=(0,aa.A)(e.current.rootElementRef.current);o.body.style.cursor="col-resize",i.previousMouseClickEvent=n.nativeEvent,o.addEventListener("mousemove",g),o.addEventListener("mouseup",h),o.addEventListener("click",zc,!0)}),x=(0,Nt.A)((n,r)=>{if(t.disableAutosize)return;if(0!==r.button)return;const o=e.current.state.columns.lookup[n.field];!1!==o.resizable&&e.current.autosizeColumns((0,y.A)({},t.autosizeOptions,{disableColumnVirtualization:!1,columns:[o.field]}))}),E=function(e){const t=o.useRef(void 0),n=()=>vl(e),r=J(e,n);return o.useEffect(()=>{t.current&&!1===r&&(t.current.resolve(),t.current=void 0)}),()=>{if(!t.current){if(!1===n())return Promise.resolve();t.current=function(){let e,t;const n=new Promise((n,r)=>{e=n,t=r});return n.resolve=e,n.reject=t,n}()}return t.current}}(e),I=o.useRef(!1),k=o.useCallback(async n=>{const r=e.current.rootElementRef?.current;if(!r)return;if(I.current)return;I.current=!0;const o=Qe(e),i=(0,y.A)({},Dc,n,{columns:n?.columns??o.orderedFields});i.columns=i.columns.filter(e=>!1!==o.columnVisibilityModel[e]);const a=i.columns.map(t=>e.current.state.columns.lookup[t]);try{!t.disableVirtualization&&i.disableColumnVirtualization&&(e.current.unstable_setColumnVirtualization(!1),await E());const n=function(e,t,n){const r={},o=e.current.rootElementRef.current;o.classList.add(L.autosizing);const i=t.includeHeaderFilters&&Co(e);return n.forEach(n=>{const o=function(e,t){const n=e.virtualScrollerRef.current;return Array.from(n.querySelectorAll(`:scope > div > div > div > [data-field="${Gs(t)}"][role="gridcell"]`))}(e.current,n.field),a=o.map(e=>e.getBoundingClientRect().width??0),l=t.includeOutliers?a:function(e,t){if(e.length<4)return e;const n=e.slice();n.sort((e,t)=>e-t);const r=n[Math.floor(.25*n.length)],o=n[Math.floor(.75*n.length)-1],i=o-r,a=i<5?5:i*t;return n.filter(e=>e>r-a&&e<o+a)}(a,t.outliersFactor);if(t.includeHeaders){const t=(s=e.current,c=n.field,s.columnHeadersContainerRef.current.querySelector(`:scope > div > [data-field="${Gs(c)}"][role="columnheader"]`));if(t){const e=t.querySelector(`.${L.columnHeaderTitleContainer}`),n=Array.from(e.children),r=t.querySelector(`.${L.menuIcon}`),o=window.getComputedStyle(e,null),i=parseInt(o.gap,10)||0,a=window.getComputedStyle(t,null),s=parseInt(a.paddingLeft,10)+parseInt(a.paddingRight,10);let c=0,u=0;for(let e=0;e<n.length;e+=1){const t=n[e];t.clientWidth>0&&(c+=1,u+=t.scrollWidth)}u+=1;const d=u+i*(c-1)+s+(r?.clientWidth??0);l.push(d)}}var s,c;if(i){const t=function(e,t){return e.columnHeadersContainerRef.current.querySelector(`:scope > .${L.headerFilterRow} > [data-field="${Gs(t)}"]`)}(e.current,n.field);if(t){const e=window.getComputedStyle(t,null),n=parseInt(e.paddingLeft,10)+parseInt(e.paddingRight,10),r=t.scrollWidth+n;l.push(r)}}const u=n.minWidth!==-1/0&&void 0!==n.minWidth,d=n.maxWidth!==1/0&&void 0!==n.maxWidth,f=u?n.minWidth:0,p=d?n.maxWidth:1/0,h=0===l.length?0:Math.max(...l);r[n.field]=fn(h,f,p)}),o.classList.remove(L.autosizing),r}(e,i,a),r=a.map(e=>(0,y.A)({},e,{width:n[e.field],computedWidth:n[e.field],flex:0}));if(i.expand){const t=o.orderedFields.map(e=>o.lookup[e]).filter(e=>!1!==o.columnVisibilityModel[e.field]).reduce((e,t)=>e+(n[t.field]??t.computedWidth??t.width),0),i=e.current.getRootDimensions().viewportInnerSize.width-t;if(i>0){const e=i/(r.length||1);r.forEach(t=>{t.width+=e,t.computedWidth+=e})}}e.current.updateColumns(r),r.forEach((t,n)=>{if(t.width!==a[n].width){const n=t.width;e.current.publishEvent("columnWidthChange",{element:e.current.getColumnHeaderElement(t.field),colDef:t,width:n})}})}finally{t.disableVirtualization||e.current.unstable_setColumnVirtualization(!0),I.current=!1}},[e,E,t.disableVirtualization]);o.useEffect(()=>v,[v]),(0,$i.A)(()=>{t.autosizeOnMount&&Promise.resolve().then(()=>{e.current.autosizeColumns(t.autosizeOptions)})}),ss(e,()=>e.current.columnHeadersContainerRef?.current,"touchstart",b,{passive:!0}),Bl(e,{autosizeColumns:k},"public"),$t(e,"columnResizeStop",C),$t(e,"columnResizeStart",w),$t(e,"columnSeparatorMouseDown",S),$t(e,"columnSeparatorDoubleClick",x),$t(e,"rowsSet",()=>{""!==Nc(e)&&requestAnimationFrame(()=>{f()})}),Gt(e,"columnResize",t.onColumnResize),Gt(e,"columnWidthChange",t.onColumnWidthChange)};function Vc(e,t,n){e&&(e.style[t]=`${Math.round(parseFloat(e.style[t]))+n}px`)}function Wc(e){return 0!==e.firstRowIndex||0!==e.lastRowIndex}const Uc=(e,t,n)=>{if(!e)return null;const r=e[t.field];return t.rowSpanValueGetter?t.rowSpanValueGetter(r,e,t,n):Kn(e,t,n)},qc={caches:{spannedCells:{},hiddenCells:{},hiddenCellOriginMap:{}},processedRange:{firstRowIndex:0,lastRowIndex:0}},Yc=e=>(0,y.A)({},e,{rowSpanning:qc}),Kc=(e,t,n)=>(0,y.A)({},e,{listViewColumn:t.listViewColumn?(0,y.A)({},t.listViewColumn,{computedWidth:Jc(n)}):void 0});function Jc(e){return ut(e).viewportInnerSize.width}const Xc=Ee(Ko,Uo,al,(e,t,n)=>({groupKeys:[],paginationModel:n,sortModel:t,filterModel:e,start:n.page*n.pageSize,end:n.page*n.pageSize+n.pageSize-1}));let Zc=function(e){return e.Default="set-flat-rows",e.LazyLoading="replace-row-range",e.GroupedData="set-grouped-rows",e}({});class eu{constructor(e){this.chunkSize=e}getCacheKeys=e=>{if(this.chunkSize<1||"number"!=typeof e.start)return[e];const t=[];for(let n=e.start;n<=e.end;n+=this.chunkSize){const r=Math.min(n+this.chunkSize-1,e.end);t.push((0,y.A)({},e,{start:n,end:r}))}return t};splitResponse=(e,t)=>{const n=this.getCacheKeys(e);if(1===n.length)return new Map([[e,t]]);const r=new Map;return n.forEach(n=>{const o=n.end===e.end,i=(0,y.A)({},t,{pageInfo:(0,y.A)({},t.pageInfo,{hasNextPage:void 0!==t.pageInfo?.hasNextPage&&!o||t.pageInfo?.hasNextPage,nextCursor:void 0===t.pageInfo?.nextCursor||o?t.pageInfo?.nextCursor:t.rows[n.end+1].id}),rows:"number"!=typeof n.start||"number"!=typeof e.start?t.rows:t.rows.slice(n.start-e.start,n.end-e.start+1)});r.set(n,i)}),r};static mergeResponses=e=>1===e.length?e[0]:e.reduce((e,t)=>(0,y.A)({},t,{rows:[...e.rows,...t.rows]}),{rows:[],rowCount:0,pageInfo:{}})}function tu(e){return JSON.stringify([e.filterModel,e.sortModel,e.start,e.end])}class nu{constructor({ttl:e=3e5,getKey:t=tu}){this.cache={},this.ttl=e,this.getKey=t}set(e,t){const n=this.getKey(e),r=Date.now()+this.ttl;this.cache[n]={value:t,expiry:r}}get(e){const t=this.getKey(e),n=this.cache[t];if(n){if(!(Date.now()>n.expiry))return n.value;delete this.cache[t]}}clear(){this.cache={}}}class ru extends Error{constructor(e){super(e.message),this.name="GridGetRowsError",this.params=e.params,this.cause=e.cause}}class ou extends Error{constructor(e){super(e.message),this.name="GridUpdateRowError",this.params=e.params,this.cause=e.cause}}const iu=["skipCache","keepChildrenExpanded"],au={clear:()=>{},get:()=>{},set:()=>{}};function lu(e,t={}){return null===e?au:e??new nu(t)}const su=(e,t,n)=>{((e,t)=>{(e=>{const t=o.useRef(null),n=o.useRef(null),r=o.useRef(null),i=o.useRef(null),a=o.useRef(null),l=o.useRef(null);e.current.register("public",{rootElementRef:t}),e.current.register("private",{mainElementRef:n,virtualScrollerRef:r,virtualScrollbarVerticalRef:i,virtualScrollbarHorizontalRef:a,columnHeadersContainerRef:l})})(e),((e,t)=>{const n=o.useRef(!0);o.useEffect(()=>{n.current?n.current=!1:e.current.setState(e=>(0,y.A)({},e,{props:{listView:t.listView,getRowId:t.getRowId,isCellEditable:t.isCellEditable,isRowSelectable:t.isRowSelectable,dataSource:t.dataSource}}))},[e,t.listView,t.getRowId,t.isCellEditable,t.isRowSelectable,t.dataSource])})(e,t),(e=>{const t=(0,Hr.I)();void 0===e.current.state.isRtl&&(e.current.state.isRtl=t);const n=o.useRef(!0);o.useEffect(()=>{n.current?n.current=!1:e.current.setState(e=>(0,y.A)({},e,{isRtl:t}))},[e,t])})(e),((e,t)=>{Bl(e,{getLogger:o.useCallback(e=>Yl?Zl(e,"debug",t.logger):t.logLevel?Zl(e,t.logLevel.toString(),t.logger):Jl,[t.logLevel,t.logger])},"private")})(e,t),(e=>{const t=o.useRef({}),n=o.useCallback(e=>{t.current[e.stateId]=e},[]),r=o.useCallback((n,r)=>{let o;if(o="function"==typeof n?n(e.current.state):n,e.current.state===o)return!1;const i={current:{state:o}};let a=!1;const l=[];if(Object.keys(t.current).forEach(n=>{const r=t.current[n],o=r.stateSelector(e),s=r.stateSelector(i);s!==o&&(l.push({stateId:r.stateId,hasPropChanged:s!==r.propModel}),void 0!==r.propModel&&s!==r.propModel&&(a=!0))}),l.length>1)throw new Error(`You're not allowed to update several sub-state in one transaction. You already updated ${l[0].stateId}, therefore, you're not allowed to update ${l.map(e=>e.stateId).join(", ")} in the same transaction.`);if(a||(e.current.state=o,e.current.publishEvent("stateChange",o),e.current.store.update(o)),1===l.length){const{stateId:n,hasPropChanged:o}=l[0],s=t.current[n],c=s.stateSelector(i);s.propOnChange&&o&&s.propOnChange(c,{reason:r,api:e.current}),a||e.current.publishEvent(s.changeEvent,c,{reason:r})}return!a},[e]),i={updateControlState:o.useCallback((t,n,r)=>e.current.setState(e=>(0,y.A)({},e,{[t]:n(e[t])}),r),[e]),registerControlState:n};Bl(e,{setState:r},"public"),Bl(e,i,"private")})(e),(e=>{const t=o.useRef({}),n=o.useRef(!1),r=o.useCallback(e=>{!n.current&&e&&(n.current=!0,Object.values(e.appliers).forEach(e=>{e()}),n.current=!1)},[]),i=o.useCallback((e,n,r)=>{t.current[e]||(t.current[e]={processors:new Map,processorsAsArray:[],appliers:{},processorsUpdated:!1});const o=t.current[e];return o.processors.get(n)!==r&&(o.processors.set(n,r),o.processorsAsArray=Array.from(t.current[e].processors.values()).filter(e=>null!==e),o.processorsUpdated=!0),()=>{t.current[e].processors.set(n,null),t.current[e].processorsAsArray=Array.from(t.current[e].processors.values()).filter(e=>null!==e)}},[]),a=o.useCallback((e,n,r)=>(t.current[e]||(t.current[e]={processors:new Map,processorsAsArray:[],appliers:{},processorsUpdated:!1}),t.current[e].appliers[n]=r,()=>{const r=t.current[e].appliers,o=(0,x.A)(r,[n].map(ts));t.current[e].appliers=o}),[]),l=o.useCallback(e=>{r(t.current[e])},[r]),s=o.useCallback(()=>{for(const e in t.current){if(!Object.prototype.hasOwnProperty.call(t.current,e))continue;const n=t.current[e];n.processorsUpdated&&(n.processorsUpdated=!1,r(n))}},[r]),c={unstable_applyPipeProcessors:o.useCallback((...e)=>{const[n,r,o]=e;if(!t.current[n])return r;const i=t.current[n].processorsAsArray;let a=r;for(let e=0;e<i.length;e+=1)a=i[e](a,o);return a},[])};Bl(e,{registerPipeProcessor:i,registerPipeApplier:a,requestPipeProcessorsApplication:l,runAppliersForPendingProcessors:s},"private"),Bl(e,c,"public")})(e),(e=>{const t=o.useRef(new Map),n=o.useRef({}),r=o.useCallback((t,r,o)=>{const i=()=>{const e=n.current[r],o=(0,x.A)(e,[t].map(ts));n.current[r]=o};n.current[r]||(n.current[r]={});const a=n.current[r],l=a[t];return a[t]=o,l&&l!==o?(t===e.current.getActiveStrategy(os[r])&&e.current.publishEvent("activeStrategyProcessorChange",r),i):i},[e]),i=o.useCallback((t,r)=>{const o=e.current.getActiveStrategy(os[t]);if(null==o)throw new Error("Can't apply a strategy processor before defining an active strategy");const i=n.current[t];if(!i||!i[o])throw new Error(`No processor found for processor "${t}" on strategy "${o}"`);return(0,i[o])(r)},[e]),a=o.useCallback(e=>{const n=Array.from(t.current.entries()).find(([,t])=>t.group===e&&t.isAvailable());return n?.[0]??rs},[]),l=o.useCallback((n,r,o)=>{t.current.set(r,{group:n,isAvailable:o}),e.current.publishEvent("strategyAvailabilityChange")},[e]);Bl(e,{registerStrategyProcessor:r,applyStrategyProcessor:i,getActiveStrategy:a,setStrategyAvailability:l},"private")})(e),((e,t)=>{const n=o.useCallback(e=>{if(null==t.localeText[e])throw new Error(`Missing translation for key ${e}.`);return t.localeText[e]},[t.localeText]);e.current.register("public",{getLocaleText:n})})(e,t),e.current.register("private",{rootProps:t})})(e,t),((e,t)=>{const n=(e=>{const{classes:t}=e;return o.useMemo(()=>(0,R.A)({cellCheckbox:["cellCheckbox"],columnHeaderCheckbox:["columnHeaderCheckbox"]},D,t),[t])})({classes:t.classes}),r=o.useCallback(r=>{const o=(0,y.A)({},gs,{cellClassName:n.cellCheckbox,headerClassName:n.columnHeaderCheckbox,headerName:e.current.getLocaleText("checkboxSelectionHeaderName")}),i=t.checkboxSelection,a=null!=r.lookup[hs];return i&&!a?(r.lookup[hs]=o,r.orderedFields=[hs,...r.orderedFields]):!i&&a?(delete r.lookup[hs],r.orderedFields=r.orderedFields.filter(e=>e!==hs)):i&&a&&(r.lookup[hs]=(0,y.A)({},o,r.lookup[hs]),t.columns.some(e=>e.field===hs)||(r.orderedFields=[hs,...r.orderedFields.filter(e=>e!==hs)])),r},[e,n,t.columns,t.checkboxSelection]);ws(e,"hydrateColumns",r)})(e,t),(e=>{Ds(e,rs,"rowTreeCreation",gc)})(e),as(is,e,t),as(bc,e,t),as(Cs,e,t),as(hc,e,t),as(tc,e,t),as(pc,e,t),as($s,e,t),as(vc,e,t),as(nc,e,t),as(Ns,e,t),as(Yc,e,t),as(Ss,e,t),as($c,e,t),as(ys,e,t),as(_c,e,t),as(Oc,e,t),as(Sc,e,t),as(Tl,e,t),as(Kc,e,t),((e,t)=>{const n=ls(e,"useGridKeyboardNavigation"),r=(0,Hr.I)(),i=o.useCallback(()=>ec(e),[e]),a="DataGrid"!==t.signature&&t.headerFilters,l=o.useCallback((t,r,o="left",i="up")=>{const a=ei(e),l=e.current.unstable_getCellColSpanInfo(r,t);l&&l.spannedByColSpan&&("left"===o?t=l.leftVisibleCellIndex:"right"===o&&(t=l.rightVisibleCellIndex));const s=We(e)[t],c=function(e,t,n,r){const o=qa.selectors.hiddenCells(e.current.virtualizer.store.state);if(!o[t]?.[n])return t;const i=ri(e);let a=i.indexOf(t)+("down"===r?1:-1);for(;a>=0&&a<i.length;){const e=i[a];if(!o[e]?.[n])return e;a+="down"===r?1:-1}return t}(e,r,t,i),u=a.findIndex(e=>e.id===c);n.debug(`Navigating to cell row ${u}, col ${t}`),e.current.scrollToIndexes({colIndex:t,rowIndex:u}),e.current.setCellFocus(c,s)},[e,n]),s=o.useCallback((t,r)=>{n.debug(`Navigating to header col ${t}`),e.current.scrollToIndexes({colIndex:t});const o=e.current.getVisibleColumns()[t].field;e.current.setColumnHeaderFocus(o,r)},[e,n]),c=o.useCallback((t,r)=>{n.debug(`Navigating to header filter col ${t}`),e.current.scrollToIndexes({colIndex:t});const o=e.current.getVisibleColumns()[t].field;e.current.setColumnHeaderFilterFocus(o,r)},[e,n]),u=o.useCallback((t,r,o)=>{n.debug(`Navigating to header col ${t}`),e.current.scrollToIndexes({colIndex:t});const{field:i}=e.current.getVisibleColumns()[t];e.current.setColumnGroupHeaderFocus(i,r,o)},[e,n]),d=o.useCallback(e=>i()[e]?.id,[i]),f=o.useCallback((n,o)=>{const f=o.currentTarget.querySelector(`.${L.columnHeaderTitleContainerContent}`);if(f&&f.contains(o.target)&&n.field!==gs.field)return;if(!Vr(o.key)&&"Tab"!==o.key&&"Enter"!==o.key)return;if("Tab"===o.key&&("none"===t.tabNavigation||"content"===t.tabNavigation&&o.shiftKey))return;const p=i(),h=e.current.getViewportPageSize(),g=n.field?e.current.getColumnIndex(n.field):0,m=p.length>0?0:null,A=p.length>0?p.length-1:null,b=Math.max(0,Ve(e).length-1),v=Mo(e);let y=!0;if("Tab"!==o.key||"content"!==t.tabNavigation||o.shiftKey){switch(o.key){case"ArrowDown":a?c(g,o):null!==m&&l(g,d(m));break;case"ArrowRight":{const e=Zs({currentColIndex:g,firstColIndex:0,lastColIndex:b,isRtl:r});null!==e&&s(e,o);break}case"ArrowLeft":{const e=Xs({currentColIndex:g,firstColIndex:0,lastColIndex:b,isRtl:r});null!==e&&s(e,o);break}case"ArrowUp":v>0&&u(g,v-1,o);break;case"PageDown":null!==m&&null!==A&&l(g,d(Math.min(m+h,A)));break;case"Home":s(0,o);break;case"End":s(b,o);break;case"Enter":(o.ctrlKey||o.metaKey)&&e.current.toggleColumnMenu(n.field);break;case"Tab":o.shiftKey?0===g?v>0?u(b,v-1,o):y=!1:s(g-1,o):g===b?a?c(0,o):"all"===t.tabNavigation&&null!==m?l(0,d(m)):y=!1:s(g+1,o);break;case" ":break;default:y=!1}y&&o.preventDefault()}else null!==m&&(l(0,d(m)),o.preventDefault())},[e,t.tabNavigation,i,a,c,l,d,r,s,u]),p=o.useCallback((n,o)=>{const a=So(e)===n.field;if(xo(e)===n.field||a&&"Tab"!==o.key)return;if(!Vr(o.key)&&"Tab"!==o.key)return;if("Tab"===o.key&&("none"===t.tabNavigation||"content"===t.tabNavigation&&o.shiftKey))return;const u=i(),f=e.current.getViewportPageSize(),p=n.field?e.current.getColumnIndex(n.field):0,h=u.length>0?0:null,g=u.length>0?u.length-1:null,m=Math.max(0,Ve(e).length-1);let A=!0;if("Tab"!==o.key||"content"!==t.tabNavigation||o.shiftKey){switch(o.key){case"ArrowDown":null!==h&&l(p,d(h));break;case"ArrowRight":{const e=Zs({currentColIndex:p,firstColIndex:0,lastColIndex:m,isRtl:r});null!==e&&c(e,o);break}case"ArrowLeft":{const t=Xs({currentColIndex:p,firstColIndex:0,lastColIndex:m,isRtl:r});null!==t?c(t,o):e.current.setColumnHeaderFilterFocus(n.field,o);break}case"ArrowUp":s(p,o);break;case"PageDown":null!==h&&null!==g&&l(p,d(Math.min(h+f,g)));break;case"Home":c(0,o);break;case"End":c(m,o);break;case"Tab":o.shiftKey?0===p?s(m,o):c(p-1,o):p===m?"all"===t.tabNavigation&&null!==h?l(0,d(h)):A=!1:c(p+1,o);break;case" ":break;default:A=!1}A&&o.preventDefault()}else null!==h&&(l(0,d(h)),o.preventDefault())},[e,t.tabNavigation,i,c,r,s,l,d]),h=o.useCallback((n,r)=>{const o=vi(e);if(null===o)return;const{field:a,depth:c}=o,{fields:f,depth:p,maxDepth:h}=n;if(!Vr(r.key)&&"Tab"!==r.key)return;if("Tab"===r.key&&("none"===t.tabNavigation||"content"===t.tabNavigation&&r.shiftKey))return;const g=i(),m=e.current.getViewportPageSize(),A=e.current.getColumnIndex(a),b=a?e.current.getColumnIndex(a):0,v=g.length>0?0:null,y=g.length>0?g.length-1:null,w=Math.max(0,Ve(e).length-1);let C=!0;if("Tab"!==r.key||"content"!==t.tabNavigation||r.shiftKey){switch(r.key){case"ArrowDown":p===h-1?s(A,r):u(A,c+1,r);break;case"ArrowUp":p>0&&u(A,c-1,r);break;case"ArrowRight":{const e=f.length-f.indexOf(a)-1;A+e+1<=w&&u(A+e+1,c,r);break}case"ArrowLeft":{const e=f.indexOf(a);A-e-1>=0&&u(A-e-1,c,r);break}case"PageDown":null!==v&&null!==y&&l(b,d(Math.min(v+m,y)));break;case"Home":u(0,c,r);break;case"End":u(w,c,r);break;case"Tab":if(r.shiftKey){const e=A-f.indexOf(a)-1;e<0?0===p?C=!1:u(w,c-1,r):u(e,c,r)}else{const e=A+(f.length-f.indexOf(a)-1)+1;e>w&&p===h-1?s(0,r):e>w?u(0,c+1,r):u(e,c,r)}break;case" ":break;default:C=!1}C&&r.preventDefault()}else null!==v&&(l(0,d(v)),r.preventDefault())},[e,t.tabNavigation,i,s,u,l,d]),g=o.useCallback((n,o)=>{if(Ws(o))return;const u=e.current.getCellParams(n.id,n.field);if(u.cellMode===Pr.Edit||!Vr(o.key)&&"Tab"!==o.key)return;if("Tab"===o.key&&("none"===t.tabNavigation||"header"===t.tabNavigation&&!o.shiftKey))return;if(!e.current.unstable_applyPipeProcessors("canUpdateFocus",!0,{event:o,cell:u}))return;const f=i();if(0===f.length)return;const p=a?c:s,h=e.current.getViewportPageSize(),g=n.field?e.current.getColumnIndex(n.field):0,m=f.findIndex(e=>e.id===n.id),A=f.length-1,b=Math.max(0,Ve(e).length-1);let v=!0;if("Tab"===o.key&&"header"===t.tabNavigation&&o.shiftKey)return p(b,o),void o.preventDefault();switch(o.key){case"ArrowDown":m<A&&l(g,d(m+1),r?"right":"left","down");break;case"ArrowUp":m>0?l(g,d(m-1)):p(g,o);break;case"ArrowRight":{const e=Zs({currentColIndex:g,firstColIndex:0,lastColIndex:b,isRtl:r});null!==e&&l(e,d(m),r?"left":"right");break}case"ArrowLeft":{const e=Xs({currentColIndex:g,firstColIndex:0,lastColIndex:b,isRtl:r});null!==e&&l(e,d(m),r?"right":"left");break}case"Tab":o.shiftKey?0===g&&0===m?"all"===t.tabNavigation?p(b,o):v=!1:0===g?l(b,d(m-1)):l(g-1,d(m),"left"):g===b?m!==A?l(0,d(m+1)):v=!1:l(g+1,d(m),"right");break;case" ":{if(n.field===pr)break;const e=n.colDef;if(e&&("__tree_data_group__"===e.field||(y=e.field)===fr||null!==(e=>{const t=e.match(/^__row_group_by_columns_group_(.*)__$/);return t?t[1]:null})(y)))break;if(e&&"longText"===e.type)break;!o.shiftKey&&m<A&&l(g,d(Math.min(m+h,A)));break}case"PageDown":m<A&&l(g,d(Math.min(m+h,A)));break;case"PageUp":{const e=Math.max(m-h,0);e!==m&&e>=0?l(g,d(e)):s(g,o);break}case"Home":o.ctrlKey||o.metaKey||o.shiftKey?l(0,d(0)):l(0,d(m));break;case"End":o.ctrlKey||o.metaKey||o.shiftKey?l(b,d(A)):l(b,d(m));break;default:v=!1}var y;v&&o.preventDefault()},[e,t.tabNavigation,i,r,l,d,a,c,s]),m=o.useCallback((e,{event:t})=>" "!==t.key&&e,[]);ws(e,"canStartEditing",m),$t(e,"columnHeaderKeyDown",f),$t(e,"headerFilterKeyDown",p),$t(e,"columnGroupHeaderKeyDown",h),$t(e,"cellKeyDown",g)})(e,t),((e,t)=>{const n=ls(e,"useGridSelection"),r=J(e,Bt)>1,i=t.signature!==el.DataGrid&&(t.rowSelectionPropagation?.parents||t.rowSelectionPropagation?.descendants)&&r,a=o.useMemo(()=>t.rowSelectionModel,[t.rowSelectionModel]),l=o.useRef(null);e.current.registerControlState({stateId:"rowSelection",propModel:a,propOnChange:t.onRowSelectionModelChange,stateSelector:Il,changeEvent:"rowSelectionChange"});const{checkboxSelection:s,disableRowSelectionOnClick:c,isRowSelectable:u}=t,d=Vl(t),f=o.useCallback(t=>{let n=t;const r=l.current??t,o=e.current.isRowSelected(t);if(o){const t=ti(e),o=t.findIndex(e=>e===r),i=t.findIndex(e=>e===n);if(o===i)return;n=o>i?t[i+1]:t[i-1]}l.current=t,e.current.selectRowRange({startId:r,endId:n},!o)},[e]),p=(0,Nt.A)(()=>t.pagination&&t.checkboxSelectionVisibleOnly&&"client"===t.paginationMode?hl(e):ti(e)),h=o.useCallback((r,o)=>{if(t.signature===el.DataGrid&&!d&&("include"!==r.type||r.ids.size>1))throw new Error(["MUI X: `rowSelectionModel` can only contain 1 item in DataGrid.","You need to upgrade to DataGridPro or DataGridPremium component to unlock multiple selection."].join("\n"));if(Il(e)!==r){if(n.debug("Setting selection model"),null!==l.current){const e=r.ids.has(l.current);("include"===r.type&&!e||"exclude"===r.type&&e)&&(l.current=null)}e.current.setState(e=>(0,y.A)({},e,{rowSelection:t.rowSelection?r:Ac}),o)}},[e,n,t.rowSelection,t.signature,d]),g=o.useCallback(t=>kl(e).has(t),[e]),m=o.useCallback(n=>{if(!1===t.rowSelection)return!1;if(t.keepNonExistentRowsSelected&&!e.current.getRow(n))return!0;if(u&&!u(e.current.getRowParams(n)))return!1;const r=kt(e,n);return"footer"!==r?.type&&"pinnedRow"!==r?.type},[e,t.rowSelection,t.keepNonExistentRowsSelected,u]),A=o.useCallback(()=>Ml(e),[e]),b=o.useCallback((r,o=!0,a=!1)=>{if(!e.current.isRowSelectable(r))return;const s=It(e);if(l.current=o?r:null,a){n.debug(`Setting selection for row ${r}`);const a={type:"include",ids:new Set},l=e=>{a.ids.add(e)};o&&(l(r),i&&Wl(e,s,r,t.rowSelectionPropagation?.descendants??!1,t.rowSelectionPropagation?.parents??!1,l)),e.current.setRowSelectionModel(a,"singleRowSelection")}else{n.debug(`Toggling selection for row ${r}`);const a=Il(e),l={type:a.type,ids:new Set(a.ids)},c=El(l);c.unselect(r);const u=e=>{c.select(e)},f=e=>{c.unselect(e)};o?(u(r),i&&Wl(e,s,r,t.rowSelectionPropagation?.descendants??!1,t.rowSelectionPropagation?.parents??!1,u)):i&&Ul(e,s,r,t.rowSelectionPropagation?.descendants??!1,t.rowSelectionPropagation?.parents??!1,f),("include"===l.type&&l.ids.size<2||d)&&e.current.setRowSelectionModel(l,"singleRowSelection")}},[e,n,i,t.rowSelectionPropagation?.descendants,t.rowSelectionPropagation?.parents,d]),v=o.useCallback((r,o=!0,a=!1)=>{if(n.debug("Setting selection for several rows"),!1===t.rowSelection)return;const l=It(e),s=new Set;for(let t=0;t<r.length;t+=1){const n=r[t];e.current.isRowSelectable(n)&&s.add(n)}const c=Il(e);let u;if(a){if(u={type:"include",ids:s},o){const n=El(u);if(i){const r=e=>{n.select(e)};for(const n of s)Wl(e,l,n,t.rowSelectionPropagation?.descendants??!1,t.rowSelectionPropagation?.parents??!1,r)}}else u.ids=new Set;if(c.type===u.type&&u.ids.size===c.ids.size&&Array.from(u.ids).every(e=>c.ids.has(e)))return}else{u={type:c.type,ids:new Set(c.ids)};const n=El(u),r=e=>{n.select(e)},a=e=>{n.unselect(e)};for(const c of s)o?(n.select(c),i&&Wl(e,l,c,t.rowSelectionPropagation?.descendants??!1,t.rowSelectionPropagation?.parents??!1,r)):(a(c),i&&Ul(e,l,c,t.rowSelectionPropagation?.descendants??!1,t.rowSelectionPropagation?.parents??!1,a))}("include"===u.type&&u.ids.size<2||d)&&e.current.setRowSelectionModel(u,"multipleRowsSelection")},[n,i,d,e,t.rowSelectionPropagation?.descendants,t.rowSelectionPropagation?.parents,t.rowSelection]),w=o.useCallback(n=>{if(!r||!i||"exclude"===n.type||0===n.ids.size&&"include"===n.type)return n;const o={type:n.type,ids:new Set(n.ids)},a=It(e),l=El(o),s=e=>{l.select(e)};for(const r of n.ids)Wl(e,a,r,t.rowSelectionPropagation?.descendants??!1,t.rowSelectionPropagation?.parents??!1,s,l);return o},[e,t.rowSelectionPropagation?.descendants,t.rowSelectionPropagation?.parents,r,i]),C={selectRows:v,selectRowRange:o.useCallback(({startId:t,endId:r},o=!0,i=!1)=>{if(!e.current.getRow(t)||!e.current.getRow(r))return;n.debug(`Expanding selection from row ${t} to row ${r}`);const a=ti(e),l=a.indexOf(t),s=a.indexOf(r),[c,u]=l>s?[s,l]:[l,s],d=a.slice(c,u+1);e.current.selectRows(d,o,i)},[e,n]),getPropagatedRowSelectionModel:w};Bl(e,{selectRow:b,setRowSelectionModel:h,getSelectedRows:A,isRowSelected:g,isRowSelectable:m},"public"),Bl(e,C,t.signature===el.DataGrid?"private":"public");const S=o.useRef(!0),x=o.useCallback(()=>{if(S.current)return;const n=Il(e),o=Et(e),i=It(e),a=Zo(e),l=e=>"server"===t.filterMode?!o[e]:!i[e]||!1===a[e],s={type:n.type,ids:new Set(n.ids)},c=El(s),u=n=>{const r=i[n];return!!r&&("server"===t.filterMode||!1!==a[n])&&("group"!==r.type?Boolean(o[n])&&e.current.isRowSelectable(n):r.children.some(e=>u(e)))};let d=!1;for(const e of n.ids){if(l(e)){if(t.keepNonExistentRowsSelected)continue;c.unselect(e),d=!0;continue}if(!t.rowSelectionPropagation?.parents)continue;const n=i[e];if("group"===n?.type){if(n.isAutoGenerated){c.unselect(e),d=!0;continue}n.children.some(e=>!1!==a[e]&&u(e))&&(c.unselect(e),d=!0)}}const f=r&&t.rowSelectionPropagation?.parents&&(s.ids.size>0||"exclude"===s.type);if(d||f)if(f)if("exclude"===s.type){const n=p(),r=[];for(let e=0;e<n.length;e+=1){const o=n[e];!t.keepNonExistentRowsSelected&&l(o)||!c.has(o)||r.push(o)}e.current.selectRows(r,!0,!0)}else e.current.selectRows(Array.from(s.ids),!0,!0);else e.current.setRowSelectionModel(s,"multipleRowsSelection")},[e,r,t.rowSelectionPropagation?.parents,t.keepNonExistentRowsSelected,t.filterMode,p]),E=o.useCallback((t,n)=>{const r=n.metaKey||n.ctrlKey,o=!s&&!r&&!(e=>!!e.key)(n),i=!d||o,a=e.current.isRowSelected(t),l=Rl(e)>1&&i||!a;e.current.selectRow(t,l,i)},[e,d,s]),I=o.useCallback((t,n)=>{if(c)return;const r=n.target.closest(`.${L.cell}`)?.getAttribute("data-field");if(r!==gs.field&&r!==pr){if(r){const t=e.current.getColumn(r);if(t?.type===ro)return}"pinnedRow"!==kt(e,t.id).type&&(n.shiftKey&&d?f(t.id):E(t.id,n))}},[c,d,e,f,E]),k=o.useCallback((e,t)=>{d&&t.shiftKey&&window.getSelection()?.removeAllRanges()},[d]),R=o.useCallback((t,n)=>{d&&n.nativeEvent.shiftKey?f(t.id):e.current.selectRow(t.id,t.value,!d)},[e,f,d]),M=o.useCallback(n=>{const o=Ko(e),i=Jo(e),a=o.items.length>0||i?.some(e=>e.length);t.isRowSelectable||t.checkboxSelectionVisibleOnly||r&&!t.rowSelectionPropagation?.descendants||a||t.disableRowSelectionExcludeModel?e.current.selectRows(p(),n):e.current.setRowSelectionModel({type:n?"exclude":"include",ids:new Set},"multipleRowsSelection")},[e,p,t.checkboxSelectionVisibleOnly,t.isRowSelectable,t.rowSelectionPropagation?.descendants,t.disableRowSelectionExcludeModel,r]),P=o.useCallback(e=>{M(e.value)},[M]),B=o.useCallback((t,n)=>{if(e.current.getCellMode(t.id,t.field)!==Pr.Edit&&!Ws(n)){if(Vr(n.key)&&n.shiftKey){const r=Ai(e);if(r&&r.id!==t.id){n.preventDefault();const o=e.current.isRowSelected(r.id);if(!d)return void e.current.selectRow(r.id,!o,!0);const i=e.current.getRowIndexRelativeToVisibleRows(r.id),a=e.current.getRowIndexRelativeToVisibleRows(t.id);let l,s;i>a?o?(l=a,s=i-1):(l=a,s=i):o?(l=i+1,s=a):(l=i,s=a);const c=ml(e),u=[];for(let e=l;e<=s;e+=1)u.push(c.rows[e].id);return void e.current.selectRows(u,!o)}}if(" "===n.key&&n.shiftKey)return n.preventDefault(),void E(t.id,n);"A"===String.fromCharCode(n.keyCode)&&(n.ctrlKey||n.metaKey)&&(n.preventDefault(),d&&M(!0))}},[e,d,E,M]),_=(0,Nt.A)(()=>{if(!t.rowSelection)return void e.current.setRowSelectionModel(Ac);if(void 0===a)return;if(!i||!r||"include"===a.type&&0===a.ids.size)return void e.current.setRowSelectionModel(a);const n=e.current.getPropagatedRowSelectionModel(a);n.type===a.type&&n.ids.size===a.ids.size&&Array.from(a.ids).every(e=>n.ids.has(e))?e.current.setRowSelectionModel(a):e.current.setRowSelectionModel(n)});$t(e,"filteredRowsSet",hn(t.rowSelection,x)),$t(e,"rowClick",hn(t.rowSelection,I)),$t(e,"rowSelectionCheckboxChange",hn(t.rowSelection,R)),$t(e,"headerSelectionCheckboxChange",P),$t(e,"cellMouseDown",hn(t.rowSelection,k)),$t(e,"cellKeyDown",hn(t.rowSelection,B)),o.useEffect(()=>{_()},[e,a,t.rowSelection,_]);const T=null!=a;o.useEffect(()=>{if(T||!t.rowSelection||"function"!=typeof m)return;const n=Il(e);if("include"!==n.type)return;const r=new Set;for(const e of n.ids)m(e)&&r.add(e);r.size<n.ids.size&&e.current.setRowSelectionModel({type:n.type,ids:r})},[e,m,T,t.rowSelection]),o.useEffect(()=>{if(!t.rowSelection||T)return;const n=Il(e);!d&&("include"===n.type&&n.ids.size>1||"exclude"===n.type)&&e.current.setRowSelectionModel(Ac)},[e,d,s,T,t.rowSelection]),o.useEffect(()=>{hn(t.rowSelection,x)},[t.rowSelection,x]),o.useEffect(()=>{S.current&&(S.current=!1)},[])})(e,t),function(e,t){const n=ls(e,"useGridColumns");e.current.registerControlState({stateId:"visibleColumns",propModel:t.columnVisibilityModel,propOnChange:t.onColumnVisibilityModelChange,stateSelector:He,changeEvent:"columnVisibilityModelChange"});const i=o.useCallback(t=>{n.debug("Updating columns state."),e.current.setState(function(e){return t=>(0,y.A)({},t,{columns:e})}(t)),e.current.publishEvent("columnsChange",t.orderedFields)},[n,e]),a=o.useCallback(t=>ze(e)[t],[e]),l=o.useCallback(()=>$e(e),[e]),s=o.useCallback(()=>Ve(e),[e]),c=o.useCallback((t,n=!0)=>(n?Ve(e):$e(e)).findIndex(e=>e.field===t),[e]),u=o.useCallback(t=>{const n=c(t);return Ke(e)[n]},[e,c]),d=o.useCallback(t=>{He(e)!==t&&(e.current.setState(n=>(0,y.A)({},n,{columns:Oo({apiRef:e,columnsToUpsert:[],initialState:void 0,columnVisibilityModel:t,keepOnlyColumnsToUpsert:!1})})),e.current.updateRenderContext?.())},[e]),f=o.useCallback(t=>{let n=t;if(fi(e)){const r=[],o=[],i=hi(e);if(t.forEach(e=>{i.has(e.field)?r.push(e):o.push(e)}),r.length>0&&e.current.updateNonPivotColumns(r),0===o.length)return;n=o}const r=Oo({apiRef:e,columnsToUpsert:n,initialState:void 0,keepOnlyColumnsToUpsert:!1,updateInitialVisibilityModel:!0});i(r)},[e,i]),p=o.useCallback((t,n)=>{const r=He(e);if(n!==(r[t]??!0)){const o=(0,y.A)({},r,{[t]:n});e.current.setColumnVisibilityModel(o)}},[e]),h=o.useCallback(t=>je(e).findIndex(e=>e===t),[e]),g=o.useCallback((t,r)=>{const o=je(e),a=h(t);if(a===r)return;n.debug(`Moving column ${t} to index ${r}`);const l=[...o],s=l.splice(a,1)[0];l.splice(r,0,s),i((0,y.A)({},Qe(e),{orderedFields:l}));const c={column:e.current.getColumn(t),targetIndex:e.current.getColumnIndexRelativeToVisibleColumns(t),oldIndex:a};e.current.publishEvent("columnIndexChange",c)},[e,n,i,h]),m=o.useCallback((t,r)=>{n.debug(`Updating column ${t} width to ${r}`);const o=Qe(e),a=o.lookup[t],l=(0,y.A)({},a,{width:r,hasBeenResized:!0});i(_o((0,y.A)({},o,{lookup:(0,y.A)({},o.lookup,{[t]:l})}),e.current.getRootDimensions())),e.current.publishEvent("columnWidthChange",{element:e.current.getColumnHeaderElement(t),colDef:l,width:r})},[e,n,i]),A={setColumnIndex:g};Bl(e,{getColumn:a,getAllColumns:l,getColumnIndex:c,getColumnPosition:u,getVisibleColumns:s,getColumnIndexRelativeToVisibleColumns:h,updateColumns:f,setColumnVisibilityModel:d,setColumnVisibility:p,setColumnWidth:m},"public"),Bl(e,A,t.signature===el.DataGrid?"private":"public");const b=o.useCallback((n,r)=>{const o={},i=He(e);(!r.exportOnlyDirtyModels||null!=t.columnVisibilityModel||Object.keys(t.initialState?.columns?.columnVisibilityModel??{}).length>0||Object.keys(i).length>0)&&(o.columnVisibilityModel=i),o.orderedFields=je(e);const a=$e(e),l={};return a.forEach(e=>{if(e.hasBeenResized){const t={};Po.forEach(n=>{let r=e[n];r===1/0&&(r=-1),t[n]=r}),l[e.field]=t}}),Object.keys(l).length>0&&(o.dimensions=l),(0,y.A)({},n,{columns:o})},[e,t.columnVisibilityModel,t.initialState?.columns]),v=o.useCallback((t,n)=>{const r=n.stateToRestore.columns,o=r?.columnVisibilityModel;if(null==r)return t;const i=Oo({apiRef:e,columnsToUpsert:[],initialState:r,columnVisibilityModel:o,keepOnlyColumnsToUpsert:!1});return null!=r&&e.current.setState(e=>(0,y.A)({},e,{columns:(0,y.A)({},e.columns,{lookup:i.lookup,orderedFields:i.orderedFields,initialColumnVisibilityModel:i.initialColumnVisibilityModel})})),null!=o&&e.current.setState(e=>(0,y.A)({},e,{columns:(0,y.A)({},e.columns,{columnVisibilityModel:o})})),null!=r&&e.current.publishEvent("columnsChange",i.orderedFields),t},[e]),w=o.useCallback((e,n)=>{if(n===nt.columns){const e=t.slots.columnsPanel;return(0,r.jsx)(e,(0,y.A)({},t.slotProps?.columnsPanel))}return e},[t.slots.columnsPanel,t.slotProps?.columnsPanel]),C=o.useCallback(n=>{const r=fi(e);return t.disableColumnSelector||r?n:[...n,"columnMenuColumnsItem"]},[t.disableColumnSelector,e]);ws(e,"columnMenu",C),ws(e,"exportState",b),ws(e,"restoreState",v),ws(e,"preferencePanel",w);const S=o.useRef(null);$t(e,"viewportInnerSizeChange",t=>{if(S.current!==t.width){if(S.current=t.width,!Ve(e).some(e=>e.flex&&e.flex>0))return;i(_o(Qe(e),e.current.getRootDimensions()))}});const x=o.useCallback(()=>{n.info("Columns pipe processing have changed, regenerating the columns");const t=Oo({apiRef:e,columnsToUpsert:[],initialState:void 0,keepOnlyColumnsToUpsert:!1});i(t)},[e,n,i]);_l(e,"hydrateColumns",x),o.useEffect(()=>{if(e.current.caches.columns.lastColumnsProp===t.columns)return;e.current.caches.columns.lastColumnsProp=t.columns,n.info(`GridColumns have changed, new length ${t.columns.length}`);const r=Oo({apiRef:e,initialState:void 0,columnsToUpsert:t.columns,keepOnlyColumnsToUpsert:!0,updateInitialVisibilityModel:!0,columnVisibilityModel:t.columnVisibilityModel});i(r)},[n,e,i,t.columns,t.columnVisibilityModel]),o.useEffect(()=>{void 0!==t.columnVisibilityModel&&e.current.setColumnVisibilityModel(t.columnVisibilityModel)},[e,n,t.columnVisibilityModel])}(e,t),((e,t,n)=>{const r=ls(e,"useGridRows"),i=o.useRef(Date.now()),a=o.useRef(t.rowCount),l=(0,Vt.A)(),{setRowIndex:s,setRowPosition:c}=n.hooks.useGridRowsOverridableMethods(e,t),u=o.useCallback(t=>{const n=Et(e)[t];if(n)return n;const r=kt(e,t);return r&&tr(r)?{[qn]:t}:null},[e]),d=o.useCallback(t=>lr(e,t),[e]),f=o.useCallback(({cache:n,throttle:r})=>{const o=()=>{i.current=Date.now(),e.current.setState(n=>(0,y.A)({},n,{rows:Zn({apiRef:e,rowCountProp:t.rowCount,loadingProp:t.loading,previousTree:It(e),previousTreeDepths:Pt(e),previousGroupsToFetch:Rt(e)})})),e.current.publishEvent("rowsSet")};if(l.clear(),e.current.caches.rows=n,!r)return void o();const a=t.throttleRowsMs-(Date.now()-i.current);a>0?l.start(a,o):o()},[t.throttleRowsMs,t.rowCount,t.loading,e,l]),p=o.useCallback(n=>{if(r.debug(`Updating all rows, new length ${n.length}`),!t.dataSource&&fi(e))return void e.current.updateNonPivotRows(n,!1);const o=Jn({rows:n,getRowId:t.getRowId,loading:t.loading,rowCount:t.rowCount}),i=e.current.caches.rows;o.rowsBeforePartialUpdates=i.rowsBeforePartialUpdates,f({cache:o,throttle:!0})},[r,t.getRowId,t.dataSource,t.loading,t.rowCount,f,e]),h=o.useCallback(n=>{if(t.signature===el.DataGrid&&n.length>1)throw new Error(["MUI X: You cannot update several rows at once in `apiRef.current.updateRows` on the DataGrid.","You need to upgrade to DataGridPro or DataGridPremium component to unlock this feature."].join("\n"));if(!t.dataSource&&fi(e))return void e.current.updateNonPivotRows(n);const r=ir(e,n,t.getRowId),o=rr({updates:r,getRowId:t.getRowId,previousCache:e.current.caches.rows});f({cache:o,throttle:!0})},[t.signature,t.dataSource,t.getRowId,f,e]),g=o.useCallback((n,r)=>{const o=ir(e,n,t.getRowId),i=rr({updates:o,getRowId:t.getRowId,previousCache:e.current.caches.rows,groupKeys:r??[]});f({cache:i,throttle:!1})},[t.getRowId,f,e]),m=o.useCallback(t=>{r.debug(`Setting loading to ${t}`),e.current.setState(e=>(0,y.A)({},e,{rows:(0,y.A)({},e.rows,{loading:t})})),e.current.caches.rows.loadingPropBeforePartialUpdates=t},[e,r]),A=o.useCallback(()=>{const t=_t(e),n=Et(e);return new Map(t.map(e=>[e,n[e]??{}]))},[e]),b=o.useCallback(()=>Ct(e),[e]),v=o.useCallback(()=>_t(e),[e]),w=o.useCallback(t=>{const{rowIdToIndexMap:n}=ml(e);return n.get(t)},[e]),C=o.useCallback((t,n)=>{const r=kt(e,t);if(!r)throw new Error(`MUI X: No row with id #${t} found.`);if("group"!==r.type)throw new Error("MUI X: Only group nodes can be expanded or collapsed.");const o=(0,y.A)({},r,{childrenExpanded:n});e.current.setState(e=>(0,y.A)({},e,{rows:(0,y.A)({},e.rows,{tree:(0,y.A)({},e.rows.tree,{[t]:o})})})),e.current.publishEvent("rowExpansionChange",o)},[e]),S=o.useCallback(()=>{const t=(0,y.A)({},It(e)),n=e=>{const r=t[e];"group"===r?.type&&(t[e]=(0,y.A)({},r,{childrenExpanded:!0}),r.children.forEach(n))};n(Un),e.current.setState(e=>(0,y.A)({},e,{rows:(0,y.A)({},e.rows,{tree:t})})),e.current.publishEvent("rowExpansionChange",t[Un])},[e]),x=o.useCallback(()=>{const t=(0,y.A)({},It(e)),n=e=>{const r=t[e];"group"===r?.type&&(t[e]=(0,y.A)({},r,{childrenExpanded:!1}),r.children.forEach(n))};n(Un),e.current.setState(e=>(0,y.A)({},e,{rows:(0,y.A)({},e.rows,{tree:t})})),e.current.publishEvent("rowExpansionChange",t[Un])},[e]),E=o.useCallback(t=>kt(e,t)??null,[e]),I=o.useCallback(({skipAutoGeneratedRows:t=!0,groupId:n,applySorting:r,applyFiltering:o,directChildrenOnly:i=!1})=>{const a=It(e);let l;if(r){const r=a[n];if(!r)return[];const o=Vo(e);l=[];for(let e=o.findIndex(e=>e===n)+1;e<o.length&&(i?a[o[e]].depth===r.depth+1:a[o[e]].depth>r.depth);e+=1){const n=o[e];t&&tr(a[n])||l.push(n)}}else l=nr(a,n,t,i);if(o){const t=Zo(e);l=Ho(t)?l:l.filter(e=>!1!==t[e])}return l},[e]),k={getRow:u,setLoading:m,getRowId:d,getRowModels:A,getRowsCount:b,getAllRowIds:v,setRows:p,updateRows:h,getRowNode:E,getRowIndexRelativeToVisibleRows:w,unstable_replaceRows:o.useCallback((n,r)=>{if(t.signature===el.DataGrid&&r.length>1)throw new Error(["MUI X: You cannot replace rows using `apiRef.current.unstable_replaceRows` on the DataGrid.","You need to upgrade to DataGridPro or DataGridPremium component to unlock this feature."].join("\n"));if(0===r.length)return;if(Bt(e)>1)throw new Error("`apiRef.current.unstable_replaceRows` is not compatible with tree data and row grouping");const o=(0,y.A)({},It(e)),i=(0,y.A)({},Et(e)),a=o[Un],l=[...a.children],s=new Set;for(let e=0;e<r.length;e+=1){const a=r[e],c=Yn(a,t.getRowId,"A row was provided without id when calling replaceRows()."),[u]=l.splice(n+e,1,c);s.has(u)||(delete i[u],delete o[u]);const d={id:c,depth:0,parent:Un,type:"leaf",groupingKey:null};i[c]=a,o[c]=d,s.add(c)}o[Un]=(0,y.A)({},a,{children:l});const c=l.filter(e=>"leaf"===o[e]?.type);e.current.caches.rows.dataRowIdToModelLookup=i,e.current.setState(e=>(0,y.A)({},e,{rows:(0,y.A)({},e.rows,{loading:t.loading,totalRowCount:Math.max(t.rowCount||0,l.length),dataRowIdToModelLookup:i,dataRowIds:c,tree:o})})),e.current.publishEvent("rowsSet")},[e,t.signature,t.getRowId,t.loading,t.rowCount])},R={setRowIndex:s,setRowPosition:c,setRowChildrenExpansion:C,getRowGroupChildren:I,expandAllRows:S,collapseAllRows:x},M={updateNestedRows:g},P=o.useCallback(()=>{let n;r.info("Row grouping pre-processing have changed, regenerating the row tree"),n=e.current.caches.rows.rowsBeforePartialUpdates===t.rows?(0,y.A)({},e.current.caches.rows,{updates:{type:"full",rows:_t(e)}}):Jn({rows:t.rows,getRowId:t.getRowId,loading:t.loading,rowCount:t.rowCount}),f({cache:n,throttle:!1})},[r,e,t.rows,t.getRowId,t.loading,t.rowCount,f]),B=(0,G.A)(()=>t.dataSource),_=o.useCallback(e=>{t.dataSource&&t.dataSource!==B.current?B.current=t.dataSource:"rowTreeCreation"===e&&P()},[P,B,t.dataSource]),T=o.useCallback(()=>{e.current.getActiveStrategy(ns.RowTree)!==Mt(e)&&P()},[e,P]);$t(e,"activeStrategyProcessorChange",_),$t(e,"strategyAvailabilityChange",T);const O=o.useCallback(()=>{e.current.setState(n=>{const r=e.current.unstable_applyPipeProcessors("hydrateRows",{tree:It(e),treeDepths:Pt(e),dataRowIds:_t(e),dataRowIdToModelLookup:Et(e)});return(0,y.A)({},n,{rows:(0,y.A)({},n.rows,r,{totalTopLevelRowCount:Xn({tree:r.tree,rowCountProp:t.rowCount})})})}),e.current.publishEvent("rowsSet")},[e,t.rowCount]);_l(e,"hydrateRows",O),Bl(e,k,"public"),Bl(e,R,t.signature===el.DataGrid?"private":"public"),Bl(e,M,"private");const D=o.useRef(!0);o.useEffect(()=>{if(D.current)return void(D.current=!1);let n=!1;t.rowCount!==a.current&&(n=!0,a.current=t.rowCount);const o=t.dataSource?Tt(e):t.rows,i=e.current.caches.rows.rowsBeforePartialUpdates===o,l=e.current.caches.rows.loadingPropBeforePartialUpdates===t.loading,s=e.current.caches.rows.rowCountPropBeforePartialUpdates===t.rowCount;i&&(l||(e.current.setState(e=>(0,y.A)({},e,{rows:(0,y.A)({},e.rows,{loading:t.loading})})),e.current.caches.rows.loadingPropBeforePartialUpdates=t.loading),s||(e.current.setState(e=>(0,y.A)({},e,{rows:(0,y.A)({},e.rows,{totalRowCount:Math.max(t.rowCount||0,e.rows.totalRowCount),totalTopLevelRowCount:Math.max(t.rowCount||0,e.rows.totalTopLevelRowCount)})})),e.current.caches.rows.rowCountPropBeforePartialUpdates=t.rowCount),!n)||(r.debug(`Updating all rows, new length ${o?.length}`),f({cache:Jn({rows:o,getRowId:t.getRowId,loading:t.loading,rowCount:t.rowCount}),throttle:!1}))},[t.rows,t.rowCount,t.getRowId,t.loading,t.dataSource,r,f,e])})(e,t,n),((e,t)=>{const n=o.useCallback((t,n=!1)=>{const r=e.current.virtualizer.store,{range:o,rows:i}=ml(e);if(n&&r.set("rowSpanning",qc),null===o||!Wc(t))return;const a=n?qc:qa.selectors.state(r.state),l=(s={firstRowIndex:t.firstRowIndex,lastRowIndex:Math.min(t.lastRowIndex,o.lastRowIndex-o.firstRowIndex+1)},c=a.processedRange,s.firstRowIndex>=c.firstRowIndex&&s.lastRowIndex<=c.lastRowIndex?null:s.firstRowIndex>=c.firstRowIndex&&s.lastRowIndex>c.lastRowIndex?{firstRowIndex:c.lastRowIndex,lastRowIndex:s.lastRowIndex}:s.firstRowIndex<c.firstRowIndex&&s.lastRowIndex<=c.lastRowIndex?{firstRowIndex:s.firstRowIndex,lastRowIndex:c.firstRowIndex-1}:s);var s,c;if(null===l)return;const u=Ve(e),d=((e,t,n,r,o,i)=>{const a=e.current.virtualizer,l=i?qc:qa.selectors.state(a.store.state),s=(0,y.A)({},l.caches.spannedCells),c=(0,y.A)({},l.caches.hiddenCells),u=(0,y.A)({},l.caches.hiddenCellOriginMap),d={firstRowIndex:Math.min(l.processedRange.firstRowIndex,o.firstRowIndex),lastRowIndex:Math.max(l.processedRange.lastRowIndex,o.lastRowIndex)};return t.forEach((t,i)=>{for(let a=o.firstRowIndex;a<o.lastRowIndex;a+=1){const l=n[a];if(c[l.id]?.[i])continue;const d=Uc(l.model,t,e);if(null==d)continue;let f=l.id,p=a,h=0;const g=[];if(a===o.firstRowIndex){let o=a-1,l=n[o];for(;o>=r.firstRowIndex&&l&&Uc(l.model,t,e)===d;){const e=n[o+1];c[e.id]?c[e.id][i]=!0:c[e.id]={[i]:!0},g.push(a),h+=1,f=l.id,p=o,o-=1,l=n[o]}}g.forEach(e=>{u[e]?u[e][i]=p:u[e]={[i]:p}});let m=a+1;for(;m<=r.lastRowIndex&&n[m]&&Uc(n[m].model,t,e)===d;){const e=n[m];c[e.id]?c[e.id][i]=!0:c[e.id]={[i]:!0},u[m]?u[m][i]=p:u[m]={[i]:p},m+=1,h+=1}h>0&&(s[f]?s[f][i]=h+1:s[f]={[i]:h+1})}}),{caches:{spannedCells:s,hiddenCells:c,hiddenCellOriginMap:u},processedRange:d}})(e,u,i,o,l,n),f=Object.keys(d.caches.spannedCells).length,p=Object.keys(d.caches.hiddenCells).length,h=Object.keys(a.caches.spannedCells).length,g=Object.keys(a.caches.hiddenCells).length;(n||f!==h||p!==g)&&(0!==f||0!==h)&&r.set("rowSpanning",d)},[e]),{schedule:r,cancel:i}=function(e){const t=o.useRef(null),n=o.useCallback((...n)=>{t.current||queueMicrotask(()=>{t.current&&t.current()}),t.current=()=>{t.current=null,e(...n)}},[e]);return o.useLayoutEffect(()=>{t.current&&t.current()}),{schedule:n,cancel:()=>!!t.current&&(t.current=null,!0)}}(n),a=o.useCallback(()=>{const t=yl(e);Wc(t)&&r(t,!0)},[e,r]);$t(e,"renderedRowsIntervalChange",hn(t.rowSpanning,e=>{const t=i();n(e,t)})),$t(e,"sortedRowsSet",hn(t.rowSpanning,a)),$t(e,"paginationModelChange",hn(t.rowSpanning,a)),$t(e,"filteredRowsSet",hn(t.rowSpanning,a)),$t(e,"columnsChange",hn(t.rowSpanning,a)),$t(e,"rowExpansionChange",hn(t.rowSpanning,a)),o.useEffect(()=>{const r=e.current.virtualizer?.store;r&&(t.rowSpanning?r.state.rowSpanning===qc&&n(yl(e)):r.state.rowSpanning!==qc&&r.set("rowSpanning",qc))},[e,t.rowSpanning,n])})(e,t),function(e,t,n){const r=o.useCallback(t=>({field:t,colDef:e.current.getColumn(t)}),[e]),i=o.useCallback(t=>{const n=e.current.getRow(t);if(!n)throw new mc(`No row with id #${t} found`);return{id:t,columns:e.current.getAllColumns(),row:n}},[e]),a=o.useCallback((t,n,r,{cellMode:o,colDef:i,hasFocus:a,rowNode:l,tabIndex:s,value:c,formattedValue:u})=>{const d={id:t,field:n,row:r,rowNode:l,colDef:i,cellMode:o,hasFocus:a,tabIndex:s,value:void 0!==c?c:e.current.getRowValue(r,i),formattedValue:void 0!==u?u:e.current.getRowFormattedValue(r,i),isEditable:!1,api:e.current};return d.isEditable=i&&e.current.isCellEditable(d),d},[e]),l=o.useCallback((n,r)=>{const o=e.current.getRow(n),i=kt(e,n);if(!o||!i)throw new mc(`No row with id #${n} found`);const a=Ai(e),l=wi(e),s=e.current.getCellMode(n,r);return e.current.getCellParamsForRow(n,r,o,{colDef:t.listView&&t.listViewColumn?.field===r?Fe(e):e.current.getColumn(r),rowNode:i,hasFocus:null!==a&&a.field===r&&a.id===n,tabIndex:l&&l.field===r&&l.id===n?0:-1,cellMode:s})},[e,t.listView,t.listViewColumn?.field]),s=o.useCallback(t=>e.current.rootElementRef.current?function(e,t){return e.querySelector(`[role="columnheader"][data-field="${Gs(t)}"]`)}(e.current.rootElementRef.current,t):null,[e]),c=o.useCallback(t=>e.current.rootElementRef.current?function(e,t){return e.querySelector(Vs(t))}(e.current.rootElementRef.current,t):null,[e]),u=o.useCallback((t,n)=>e.current.rootElementRef.current?function(e,{id:t,field:n}){const r=`${Vs(t)} .${L.cell}[data-field="${Gs(n)}"]`;return e.querySelector(r)}(e.current.rootElementRef.current,{id:t,field:n}):null,[e]),d=n.hooks.useGridParamsOverridableMethods(e),f={getCellValue:d.getCellValue,getCellParams:l,getCellElement:u,getRowValue:d.getRowValue,getRowFormattedValue:d.getRowFormattedValue,getRowParams:i,getRowElement:c,getColumnHeaderParams:r,getColumnHeaderElement:s},p={getCellParamsForRow:a};Bl(e,f,"public"),Bl(e,p,"private")}(e,t,n),(e=>{const t=()=>e.current.virtualizer.api.resetColSpan(),n={unstable_getCellColSpanInfo:(...t)=>e.current.virtualizer.api.getCellColSpanInfo(...t)},r={resetColSpan:t,calculateColSpan:(...t)=>{e.current.virtualizer.api.calculateColSpan(...t)}};Bl(e,n,"public"),Bl(e,r,"private"),$t(e,"columnOrderChange",t)})(e),((e,t)=>{const n=o.useCallback(t=>Io(e)[t]??[],[e]),r=o.useCallback(()=>ko(e),[e]);Bl(e,{getColumnGroupPath:n,getAllGroupDetails:r},"public");const i=o.useCallback(()=>{const n=Pc(t.columnGroupingModel??[]);e.current.setState(e=>{const t=e.columns?.orderedFields??[],r=e.pinnedColumns??{},o=Bc(t,n,r);return(0,y.A)({},e,{columnGrouping:(0,y.A)({},e.columnGrouping,{headerStructure:o})})})},[e,t.columnGroupingModel]),a=o.useCallback(t=>{if(!t&&!e.current.caches.columnGrouping.lastColumnGroupingModel)return;e.current.caches.columnGrouping.lastColumnGroupingModel=t;const n=e.current.getPinnedColumns?.()??{},r=je(e),o=We(e),i=Rc(t??[]),a=Pc(t??[]),l=Bc(r,a,n),s=0===o.length?0:Math.max(...o.map(e=>a[e]?.length??0));e.current.setState(e=>(0,y.A)({},e,{columnGrouping:{lookup:i,unwrappedGroupingModel:a,headerStructure:l,maxDepth:s}}))},[e]);$t(e,"columnIndexChange",i),$t(e,"columnsChange",()=>{a(t.columnGroupingModel)}),$t(e,"columnVisibilityModelChange",()=>{a(t.columnGroupingModel)}),o.useEffect(()=>{t.columnGroupingModel!==e.current.caches.columnGrouping.lastColumnGroupingModel&&a(t.columnGroupingModel)},[e,a,t.columnGroupingModel])})(e,t),((e,t,n)=>{((e,t)=>{const[n,r]=o.useState({}),i=o.useRef(n),a=o.useRef({}),{processRowUpdate:l,onProcessRowUpdateError:s,cellModesModel:c,onCellModesModelChange:u}=t,d=e=>(...n)=>{t.editMode===Mr.Cell&&e(...n)},f=o.useCallback((t,n)=>{const r=e.current.getCellParams(t,n);if(!e.current.isCellEditable(r))throw new Error(`MUI X: The cell with id=${t} and field=${n} is not editable.`)},[e]),p=o.useCallback((t,n,r)=>{if(e.current.getCellMode(t,n)!==r)throw new Error(`MUI X: The cell with id=${t} and field=${n} is not in ${r} mode.`)},[e]),h=o.useCallback((t,n)=>{if(!t.isEditable)return;if(t.cellMode===Pr.Edit)return;const r=(0,y.A)({},t,{reason:kr.cellDoubleClick});e.current.publishEvent("cellEditStart",r,n)},[e]),g=o.useCallback((t,n)=>{if(t.cellMode===Pr.View)return;if(e.current.getCellMode(t.id,t.field)===Pr.View)return;const r=(0,y.A)({},t,{reason:Rr.cellFocusOut});e.current.publishEvent("cellEditStop",r,n)},[e]),m=o.useCallback((t,n)=>{if(t.cellMode===Pr.Edit){if(229===n.which)return;let r;if("Escape"===n.key?r=Rr.escapeKeyDown:"Enter"===n.key?r=Rr.enterKeyDown:"Tab"===n.key&&(r=n.shiftKey?Rr.shiftTabKeyDown:Rr.tabKeyDown,n.preventDefault()),r){const o=(0,y.A)({},t,{reason:r});e.current.publishEvent("cellEditStop",o,n)}}else if(t.isEditable){let r;if(!e.current.unstable_applyPipeProcessors("canStartEditing",!0,{event:n,cellParams:t,editMode:"cell"}))return;if(Gr(n)?r=kr.printableKeyDown:Ur(n)?r=kr.pasteKeyDown:"Enter"===n.key?(r=kr.enterKeyDown,n.preventDefault()):"Backspace"!==n.key&&"Delete"!==n.key||(r=kr.deleteKeyDown),r){const o=(0,y.A)({},t,{reason:r,key:n.key});e.current.publishEvent("cellEditStart",o,n)}}},[e]),A=o.useCallback(t=>{const{id:n,field:r,reason:o}=t,i={id:n,field:r};o!==kr.printableKeyDown&&o!==kr.deleteKeyDown&&o!==kr.pasteKeyDown||(i.deleteValue=!0),e.current.startCellEditMode(i)},[e]),b=o.useCallback(t=>{const{id:n,field:r,reason:o}=t;let i;e.current.runPendingEditCellValueMutation(n,r),o===Rr.enterKeyDown?i="below":o===Rr.tabKeyDown?i="right":o===Rr.shiftTabKeyDown&&(i="left");const a="escapeKeyDown"===o;e.current.stopCellEditMode({id:n,field:r,ignoreModifications:a,cellToFocusAfter:i})},[e]);var v;$t(e,"cellDoubleClick",d(h)),$t(e,"cellFocusOut",d(g)),$t(e,"cellKeyDown",d(m)),$t(e,"cellEditStart",d(A)),$t(e,"cellEditStop",d(b)),Gt(e,"cellEditStart",t.onCellEditStart),Gt(e,"cellEditStop",(v=t.onCellEditStop,async(...t)=>{if(v){const{id:n,field:r}=t[0],o=e.current.state.editRows,i=o[n][r]?.error;i||v(...t)}}));const w=o.useCallback((t,n)=>{const r=rc(e);return r[t]&&r[t][n]?Pr.Edit:Pr.View},[e]),C=(0,Nt.A)(n=>{const o=n!==t.cellModesModel;u&&o&&u(n,{api:e.current}),t.cellModesModel&&o||(r(n),i.current=n,e.current.publishEvent("cellModesModelChange",n))}),S=o.useCallback((e,t,n)=>{const r=(0,y.A)({},i.current);if(null!==n)r[e]=(0,y.A)({},r[e],{[t]:(0,y.A)({},n)});else{const n=r[e],o=(0,x.A)(n,[t].map(ts));r[e]=o,0===Object.keys(r[e]).length&&delete r[e]}C(r)},[C]),E=o.useCallback((t,n,r)=>{e.current.setState(e=>{const o=(0,y.A)({},e.editRows);return null!==r?o[t]=(0,y.A)({},o[t],{[n]:(0,y.A)({},r)}):(delete o[t][n],0===Object.keys(o[t]).length&&delete o[t]),(0,y.A)({},e,{editRows:o})})},[e]),I=o.useCallback(e=>{const{id:t,field:n}=e,r=(0,x.A)(e,lc);f(t,n),p(t,n,Pr.View),S(t,n,(0,y.A)({mode:Pr.Edit},r))},[f,p,S]),k=(0,Nt.A)(async t=>{const{id:n,field:r,deleteValue:o,initialValue:i}=t,a=e.current.getCellValue(n,r);let l=a;o?l=ac(e.current.getColumn(r)):i&&(l=i);const s=e.current.getColumn(r),c=!!s.preProcessEditCellProps&&o;let u={value:l,error:!1,isProcessingProps:c};if(E(n,r,u),e.current.setCellFocus(n,r),c&&(u=await Promise.resolve(s.preProcessEditCellProps({id:n,row:e.current.getRow(n),props:u,hasChanged:l!==a})),e.current.getCellMode(n,r)===Pr.Edit)){const t=rc(e);E(n,r,(0,y.A)({},u,{value:t[n][r].value,isProcessingProps:!1}))}}),R=o.useCallback(e=>{const{id:t,field:n}=e,r=(0,x.A)(e,sc);p(t,n,Pr.Edit),S(t,n,(0,y.A)({mode:Pr.View},r))},[p,S]),M=(0,Nt.A)(async n=>{const{id:r,field:o,ignoreModifications:i,cellToFocusAfter:c="none"}=n;p(r,o,Pr.Edit),e.current.runPendingEditCellValueMutation(r,o);const u=()=>{E(r,o,null),S(r,o,null),"none"!==c&&e.current.moveFocusToRelativeCell(r,o,c)};if(i)return void u();const d=rc(e),{error:f,isProcessingProps:h}=d[r][o],g=e.current.getRow(r);if(f||h)return a.current[r][o].mode=Pr.Edit,void S(r,o,{mode:Pr.Edit});const m=e.current.getRowWithUpdatedValuesFromCellEditing(r,o);if(t.dataSource?.updateRow){if(la(g,m))return void u();const t=()=>{a.current[r][o].mode=Pr.Edit,S(r,o,{mode:Pr.Edit})},n={rowId:r,updatedRow:m,previousRow:g};try{await e.current.dataSource.editRow(n),u()}catch{t()}}else if(l){const t=e=>{a.current[r][o].mode=Pr.Edit,S(r,o,{mode:Pr.Edit}),s&&s(e)};try{Promise.resolve(l(m,g,{rowId:r})).then(t=>{e.current.updateRows([t]),u()}).catch(t)}catch(e){t(e)}}else e.current.updateRows([m]),u()}),P={setCellEditingEditCellValue:o.useCallback(async t=>{const{id:n,field:r,value:o,debounceMs:i,unstable_skipValueParser:a}=t;f(n,r),p(n,r,Pr.Edit);const l=e.current.getColumn(r),s=e.current.getRow(n);let c=o;l.valueParser&&!a&&(c=l.valueParser(o,s,l,e));let u=rc(e),d=(0,y.A)({},u[n][r],{value:c,changeReason:i?"debouncedSetEditCellValue":"setEditCellValue"});if(l.preProcessEditCellProps){const e=o!==u[n][r].value;d=(0,y.A)({},d,{isProcessingProps:!0}),E(n,r,d),d=await Promise.resolve(l.preProcessEditCellProps({id:n,row:s,props:d,hasChanged:e}))}return e.current.getCellMode(n,r)!==Pr.View&&(u=rc(e),d=(0,y.A)({},d,{isProcessingProps:!1}),d.value=l.preProcessEditCellProps?u[n][r].value:c,E(n,r,d),u=rc(e),!u[n]?.[r]?.error)},[e,f,p,E]),getRowWithUpdatedValuesFromCellEditing:o.useCallback((t,n)=>{const r=e.current.getColumn(n),o=rc(e),i=e.current.getRow(t);if(!o[t]||!o[t][n])return e.current.getRow(t);const{value:a}=o[t][n];return r.valueSetter?r.valueSetter(a,i,r,e):(0,y.A)({},i,{[n]:a})},[e])};Bl(e,{getCellMode:w,startCellEditMode:I,stopCellEditMode:R},"public"),Bl(e,P,"private"),o.useEffect(()=>{c&&C(c)},[c,C]),(0,Ut.A)(()=>{const t=Et(e),r=a.current;a.current=pn(n),Object.entries(n).forEach(([n,o])=>{Object.entries(o).forEach(([o,i])=>{const a=r[n]?.[o]?.mode||Pr.View,l=t[n]?e.current.getRowId(t[n]):n;i.mode===Pr.Edit&&a===Pr.View?k((0,y.A)({id:l,field:o},i)):i.mode===Pr.View&&a===Pr.Edit&&M((0,y.A)({id:l,field:o},i))})})},[e,n,k,M])})(e,t),((e,t)=>{const[n,r]=o.useState({}),i=o.useRef(n),a=o.useRef({}),l=o.useRef({}),s=o.useRef(void 0),c=o.useRef(null),{processRowUpdate:u,onProcessRowUpdateError:d,rowModesModel:f,onRowModesModelChange:p}=t,h=e=>(...n)=>{t.editMode===Mr.Row&&e(...n)},g=o.useCallback((t,n)=>{const r=e.current.getCellParams(t,n);if(!e.current.isCellEditable(r))throw new Error(`MUI X: The cell with id=${t} and field=${n} is not editable.`)},[e]),m=o.useCallback((t,n)=>{if(e.current.getRowMode(t)!==n)throw new Error(`MUI X: The row with id=${t} is not in ${n} mode.`)},[e]),A=o.useCallback(t=>{const n=rc(e);return Object.values(n[t]).some(e=>e.error)},[e]),b=o.useCallback((t,n)=>{if(!t.isEditable)return;if(e.current.getRowMode(t.id)===Br.Edit)return;const r=e.current.getRowParams(t.id),o=(0,y.A)({},r,{field:t.field,reason:cc.cellDoubleClick});e.current.publishEvent("rowEditStart",o,n)},[e]),v=o.useCallback(e=>{c.current=e},[]),w=o.useCallback((t,n)=>{t.isEditable&&e.current.getRowMode(t.id)!==Br.View&&(c.current=null,s.current=setTimeout(()=>{if(c.current?.id!==t.id){if(!e.current.getRow(t.id))return;if(e.current.getRowMode(t.id)===Br.View)return;if(A(t.id))return;const r=e.current.getRowParams(t.id),o=(0,y.A)({},r,{field:t.field,reason:uc.rowFocusOut});e.current.publishEvent("rowEditStop",o,n)}}))},[e,A]);o.useEffect(()=>()=>{clearTimeout(s.current)},[]);const C=o.useCallback((t,n)=>{if(t.cellMode===Br.Edit){if(229===n.which)return;let r;if("Escape"===n.key)r=uc.escapeKeyDown;else if("Enter"===n.key)r=uc.enterKeyDown;else if("Tab"===n.key){const o=We(e).filter(n=>e.current.getColumn(n).type===ro||e.current.isCellEditable(e.current.getCellParams(t.id,n)));if(n.shiftKey?t.field===o[0]&&(r=uc.shiftTabKeyDown):t.field===o[o.length-1]&&(r=uc.tabKeyDown),n.preventDefault(),!r){const r=o.findIndex(e=>e===t.field),i=o[n.shiftKey?r-1:r+1];e.current.setCellFocus(t.id,i)}}if(r){if(r!==uc.escapeKeyDown&&A(t.id))return;const o=(0,y.A)({},e.current.getRowParams(t.id),{reason:r,field:t.field});e.current.publishEvent("rowEditStop",o,n)}}else if(t.isEditable){let r;if(!e.current.unstable_applyPipeProcessors("canStartEditing",!0,{event:n,cellParams:t,editMode:"row"}))return;if(Gr(n)||Ur(n)?r=cc.printableKeyDown:"Enter"===n.key?r=cc.enterKeyDown:"Backspace"!==n.key&&"Delete"!==n.key||(r=cc.deleteKeyDown),r){const o=e.current.getRowParams(t.id),i=(0,y.A)({},o,{field:t.field,reason:r,key:f&&Gr(n)?n.key:void 0});e.current.publishEvent("rowEditStart",i,n)}}},[e,A,f]),S=o.useCallback(t=>{const{id:n,field:r,reason:o}=t,i={id:n,fieldToFocus:r};o!==cc.printableKeyDown&&o!==cc.deleteKeyDown||(f&&o===cc.printableKeyDown&&t.key&&r?i.initialValue=t.key:i.deleteValue=!!r),e.current.startRowEditMode(i)},[e,f]),E=o.useCallback(t=>{const{id:n,reason:r,field:o}=t;let i;e.current.runPendingEditCellValueMutation(n),r===uc.enterKeyDown?i="below":r===uc.tabKeyDown?i="right":r===uc.shiftTabKeyDown&&(i="left");const a="escapeKeyDown"===r;e.current.stopRowEditMode({id:n,ignoreModifications:a,field:o,cellToFocusAfter:i})},[e]);$t(e,"cellDoubleClick",h(b)),$t(e,"cellFocusIn",h(v)),$t(e,"cellFocusOut",h(w)),$t(e,"cellKeyDown",h(C)),$t(e,"rowEditStart",h(S)),$t(e,"rowEditStop",h(E)),Gt(e,"rowEditStart",t.onRowEditStart),Gt(e,"rowEditStop",t.onRowEditStop);const I=o.useCallback(n=>oc(e,{rowId:n,editMode:t.editMode})?Br.Edit:Br.View,[e,t.editMode]),k=(0,Nt.A)(n=>{const o=n!==t.rowModesModel;p&&o&&p(n,{api:e.current}),t.rowModesModel&&o||(r(n),i.current=n,e.current.publishEvent("rowModesModelChange",n))}),R=o.useCallback((e,t)=>{const n=(0,y.A)({},i.current);null!==t?n[e]=(0,y.A)({},t):delete n[e],k(n)},[k]),M=o.useCallback((t,n)=>{e.current.setState(e=>{const r=(0,y.A)({},e.editRows);return null!==n?r[t]=n:delete r[t],(0,y.A)({},e,{editRows:r})})},[e]),P=o.useCallback((t,n,r)=>{e.current.setState(e=>{const o=(0,y.A)({},e.editRows);return null!==r?o[t]=(0,y.A)({},o[t],{[n]:(0,y.A)({},r)}):(delete o[t][n],0===Object.keys(o[t]).length&&delete o[t]),(0,y.A)({},e,{editRows:o})})},[e]),B=o.useCallback(e=>{const{id:t}=e,n=(0,x.A)(e,dc);m(t,Br.View),R(t,(0,y.A)({mode:Br.Edit},n))},[m,R]),_=(0,Nt.A)(t=>{const{id:n,fieldToFocus:r,deleteValue:o,initialValue:i}=t,a=e.current.getRow(n),s=$e(e),c=s.reduce((t,a)=>{const l=a.field;if(!e.current.getCellParams(n,l).isEditable)return t;const s=e.current.getColumn(l);let c=e.current.getCellValue(n,l);return r===l&&(o||i)&&(o?c=ac(s):i&&(c=i)),t[l]={value:c,error:!1,isProcessingProps:s.editable&&!!s.preProcessEditCellProps&&o},t},{});l.current[n]=a,M(n,c),r&&e.current.setCellFocus(n,r),s.filter(t=>e.current.getCellParams(n,t.field).isEditable&&t.editable&&!!t.preProcessEditCellProps&&o).forEach(t=>{const r=t.field,l=e.current.getCellValue(n,r),s=o?ac(t):i??l;Promise.resolve(t.preProcessEditCellProps({id:n,row:a,props:c[r],hasChanged:s!==l})).then(t=>{if(e.current.getRowMode(n)===Br.Edit){const o=rc(e);P(n,r,(0,y.A)({},t,{value:o[n][r].value,isProcessingProps:!1}))}})})}),T=o.useCallback(e=>{const{id:t}=e,n=(0,x.A)(e,fc);m(t,Br.Edit),R(t,(0,y.A)({mode:Br.View},n))},[m,R]),O=(0,Nt.A)(async n=>{const{id:r,ignoreModifications:o,field:i,cellToFocusAfter:s="none"}=n;e.current.runPendingEditCellValueMutation(r);const c=()=>{"none"!==s&&i&&e.current.moveFocusToRelativeCell(r,i,s),M(r,null),R(r,null),delete l.current[r]};if(o&&e.current.getRow(r))return void c();const f=rc(e);if(!f[r])return void c();const p=l.current[r];if(Object.values(f[r]).some(e=>e.isProcessingProps))return void(a.current[r].mode=Br.Edit);if(A(r))return a.current[r].mode=Br.Edit,void R(r,{mode:Br.Edit});const h=e.current.getRowWithUpdatedValuesFromRowEditing(r);if(t.dataSource?.updateRow){if(la(p,h))return void c();const t=()=>{a.current[r].mode=Br.Edit,R(r,{mode:Br.Edit})},n={rowId:r,updatedRow:h,previousRow:p};try{await e.current.dataSource.editRow(n),c()}catch{t()}}else if(u){const t=e=>{a.current[r]&&(a.current[r].mode=Br.Edit,R(r,{mode:Br.Edit})),d&&d(e)};try{Promise.resolve(u(h,p,{rowId:r})).then(t=>{e.current.getRow(r)&&e.current.updateRows([t]),c()}).catch(t)}catch(e){t(e)}}else e.current.getRow(r)&&e.current.updateRows([h]),c()}),D={setRowEditingEditCellValue:o.useCallback(t=>{const{id:n,field:r,value:o,debounceMs:i,unstable_skipValueParser:a}=t;g(n,r);const l=e.current.getColumn(r),s=e.current.getRow(n);let c=o;l.valueParser&&!a&&(c=l.valueParser(o,s,l,e));let u=rc(e),d=(0,y.A)({},u[n][r],{value:c,changeReason:i?"debouncedSetEditCellValue":"setEditCellValue"});return l.preProcessEditCellProps||P(n,r,d),new Promise(t=>{const o=[];if(l.preProcessEditCellProps){const i=d.value!==u[n][r].value;d=(0,y.A)({},d,{isProcessingProps:!0}),P(n,r,d);const a=u[n],f=(0,x.A)(a,[r].map(ts)),p=Promise.resolve(l.preProcessEditCellProps({id:n,row:s,props:d,hasChanged:i,otherFieldsProps:f})).then(o=>{e.current.getRowMode(n)!==Br.View?(u=rc(e),(o=(0,y.A)({},o,{isProcessingProps:!1})).value=l.preProcessEditCellProps?u[n][r].value:c,P(n,r,o)):t(!1)});o.push(p)}Object.entries(u[n]).forEach(([i,a])=>{if(i===r)return;const l=e.current.getColumn(i);if(!l.preProcessEditCellProps)return;a=(0,y.A)({},a,{isProcessingProps:!0}),P(n,i,a),u=rc(e);const c=u[n],d=(0,x.A)(c,[i].map(ts)),f=Promise.resolve(l.preProcessEditCellProps({id:n,row:s,props:a,hasChanged:!1,otherFieldsProps:d})).then(r=>{e.current.getRowMode(n)!==Br.View?(r=(0,y.A)({},r,{isProcessingProps:!1}),P(n,i,r)):t(!1)});o.push(f)}),Promise.all(o).then(()=>{e.current.getRowMode(n)===Br.Edit?(u=rc(e),t(!u[n][r].error)):t(!1)})})},[e,g,P]),getRowWithUpdatedValuesFromRowEditing:o.useCallback(t=>{const n=rc(e),r=e.current.getRow(t);if(!n[t])return e.current.getRow(t);let o=(0,y.A)({},l.current[t],r);return Object.entries(n[t]).forEach(([t,n])=>{const r=e.current.getColumn(t);r?.valueSetter?o=r.valueSetter(n.value,o,r,e):o[t]=n.value}),o},[e])};Bl(e,{getRowMode:I,startRowEditMode:B,stopRowEditMode:T},"public"),Bl(e,D,"private"),o.useEffect(()=>{f&&k(f)},[f,k]),(0,Ut.A)(()=>{const t=Et(e),r=a.current;a.current=pn(n);const o=new Set([...Object.keys(n),...Object.keys(r)]);Array.from(o).forEach(o=>{const i=n[o]??{mode:Br.View},a=r[o]?.mode||Br.View,l=t[o]?e.current.getRowId(t[o]):o;i.mode===Br.Edit&&a===Br.View?_((0,y.A)({id:l},i)):i.mode===Br.View&&a===Br.Edit&&O((0,y.A)({id:l},i))})},[e,n,M,_,O,R])})(e,t);const r=o.useRef({}),{isCellEditable:i}=t,a=n.hooks.useIsCellEditable(e,t),l=o.useCallback(e=>!!a(e)&&!!e.colDef.editable&&!!e.colDef.renderEditCell&&(!i||i(e)),[i,a]);o.useEffect(()=>{const e=r.current;return()=>{Object.entries(e).forEach(([t,n])=>{Object.keys(n).forEach(n=>{const[r]=e[t][n];clearTimeout(r),delete e[t][n]})})}},[]);const s=o.useCallback((e,t)=>{if(r.current[e])if(t){if(r.current[e][t]){const[,n]=r.current[e][t];n()}}else Object.keys(r.current[e]).forEach(t=>{const[,n]=r.current[e][t];n()})},[]),c=o.useCallback(n=>{const{id:o,field:i,debounceMs:a}=n;return new Promise(l=>{((e,t,n,o)=>{if(!n)return void o();if(r.current[e]||(r.current[e]={}),r.current[e][t]){const[n]=r.current[e][t];clearTimeout(n)}const i=setTimeout(()=>{o(),delete r.current[e][t]},n);r.current[e][t]=[i,()=>{const[n]=r.current[e][t];clearTimeout(n),o(),delete r.current[e][t]}]})(o,i,a,async()=>{const r=t.editMode===Mr.Row?e.current.setRowEditingEditCellValue:e.current.setCellEditingEditCellValue;if(e.current.getCellMode(o,i)===Pr.Edit){const e=await r(n);l(e)}})})},[e,t.editMode]),u=o.useCallback((n,r)=>t.editMode===Mr.Cell?e.current.getRowWithUpdatedValuesFromCellEditing(n,r):e.current.getRowWithUpdatedValuesFromRowEditing(n),[e,t.editMode]),d=o.useCallback((t,n)=>{const r=rc(e);return r[t]?.[n]??null},[e]),f={runPendingEditCellValueMutation:s};Bl(e,{isCellEditable:l,setEditCellValue:c,getRowWithUpdatedValues:u,unstable_getEditCellMeta:d},"public"),Bl(e,f,"private")})(e,t,n),((e,t)=>{const n=ls(e,"useGridFocus"),r=o.useRef(null),i=null!==e.current.rootElementRef.current,a=o.useCallback((t,n)=>{t&&e.current.getRow(t.id)&&e.current.publishEvent("cellFocusOut",e.current.getCellParams(t.id,t.field),n)},[e]),l=o.useCallback((t,r)=>{const o=Ai(e);if(o?.id===t&&o?.field===r){if("view"!==e.current.getCellMode(t,r))return;const n=e.current.getCellElement(t,r);if(!n)return;const o=e.current.rootElementRef.current,i=(0,aa.A)(o),a=i.activeElement;if(a&&a!==i.body&&a!==i.documentElement&&!o?.contains(a))return;if(n.contains(i.activeElement))return;if(zs())n.focus({preventScroll:!0});else{const t=e.current.getScrollPosition();n.focus(),e.current.scroll(t)}return}e.current.setState(e=>(n.debug(`Focusing on cell with id=${t} and field=${r}`),(0,y.A)({},e,{tabIndex:{cell:{id:t,field:r},columnHeader:null,columnHeaderFilter:null,columnGroupHeader:null},focus:{cell:{id:t,field:r},columnHeader:null,columnHeaderFilter:null,columnGroupHeader:null}}))),e.current.getRow(t)&&(o&&a(o,{}),e.current.publishEvent("cellFocusIn",e.current.getCellParams(t,r)))},[e,n,a]),s=o.useCallback((t,r={})=>{const o=Ai(e);a(o,r),e.current.setState(e=>(n.debug(`Focusing on column header with colIndex=${t}`),(0,y.A)({},e,{tabIndex:{columnHeader:{field:t},columnHeaderFilter:null,cell:null,columnGroupHeader:null},focus:{columnHeader:{field:t},columnHeaderFilter:null,cell:null,columnGroupHeader:null}})))},[e,n,a]),c=o.useCallback((t,r={})=>{const o=Ai(e);a(o,r),e.current.setState(e=>(n.debug(`Focusing on column header filter with colIndex=${t}`),(0,y.A)({},e,{tabIndex:{columnHeader:null,columnHeaderFilter:{field:t},cell:null,columnGroupHeader:null},focus:{columnHeader:null,columnHeaderFilter:{field:t},cell:null,columnGroupHeader:null}})))},[e,n,a]),u=o.useCallback((t,n,r={})=>{const o=Ai(e);o&&e.current.publishEvent("cellFocusOut",e.current.getCellParams(o.id,o.field),r),e.current.setState(e=>(0,y.A)({},e,{tabIndex:{columnGroupHeader:{field:t,depth:n},columnHeader:null,columnHeaderFilter:null,cell:null},focus:{columnGroupHeader:{field:t,depth:n},columnHeader:null,columnHeaderFilter:null,cell:null}}))},[e]),d=o.useCallback(()=>vi(e),[e]),f=o.useCallback((n,r,o)=>{let i=e.current.getColumnIndex(r);const a=Ve(e),l=ml(e,(t.pagination,t.paginationMode)),s=Ot(e),c=[].concat(s.top||[],l.rows,s.bottom||[]);let u=c.findIndex(e=>e.id===n);"right"===o?i+=1:"left"===o?i-=1:u+=1,i>=a.length?(u+=1,u<c.length&&(i=0)):i<0&&(u-=1,u>=0&&(i=a.length-1)),u=fn(u,0,c.length-1);const d=c[u];if(!d)return;const f=e.current.unstable_getCellColSpanInfo(d.id,i);f&&f.spannedByColSpan&&("left"===o||"below"===o?i=f.leftVisibleCellIndex:"right"===o&&(i=f.rightVisibleCellIndex)),i=fn(i,0,a.length-1);const p=a[i];e.current.setCellFocus(d.id,p.field)},[e,t.pagination,t.paginationMode]),p=o.useCallback(({id:t,field:n})=>{e.current.setCellFocus(t,n)},[e]),h=o.useCallback((t,n)=>{Ur(n)||"Enter"===n.key||"Tab"===n.key||"Shift"===n.key||Vr(n.key)||e.current.setCellFocus(t.id,t.field)},[e]),g=o.useCallback(({field:t},n)=>{n.target===n.currentTarget&&e.current.setColumnHeaderFocus(t,n)},[e]),m=o.useCallback(({fields:t,depth:n},r)=>{if(r.target!==r.currentTarget)return;const o=vi(e);null!==o&&o.depth===n&&t.includes(o.field)||e.current.setColumnGroupHeaderFocus(t[0],n,r)},[e]),A=o.useCallback((t,r)=>{r.relatedTarget?.getAttribute("class")?.includes(L.columnHeader)||(n.debug("Clearing focus"),e.current.setState(e=>(0,y.A)({},e,{focus:{cell:null,columnHeader:null,columnHeaderFilter:null,columnGroupHeader:null}})))},[n,e]),b=o.useCallback(e=>{r.current=e},[]),v=o.useCallback(t=>{const n=r.current;r.current=null;const o=Ai(e);if(!e.current.unstable_applyPipeProcessors("canUpdateFocus",!0,{event:t,cell:n}))return;if(!o)return void(n&&e.current.setCellFocus(n.id,n.field));if(n?.id===o.id&&n?.field===o.field)return;const i=e.current.getCellElement(o.id,o.field);i?.contains(t.target)||(n?e.current.setCellFocus(n.id,n.field):(e.current.setState(e=>(0,y.A)({},e,{focus:{cell:null,columnHeader:null,columnHeaderFilter:null,columnGroupHeader:null}})),a(o,t)))},[e,a]),w=o.useCallback(t=>{if("view"===t.cellMode)return;const n=Ai(e);n?.id===t.id&&n?.field===t.field||e.current.setCellFocus(t.id,t.field)},[e]),C=o.useCallback(()=>{const n=Ai(e);if(n&&!e.current.getRow(n.id)){const r=n.id;let o=null;if(void 0!==r){const n=e.current.getRowElement(r),i=n?.dataset.rowindex?Number(n?.dataset.rowindex):0,a=ml(e,(t.pagination,t.paginationMode)),l=a.rows[fn(i,0,a.rows.length-1)];o=l?.id??null}e.current.setState(e=>(0,y.A)({},e,{focus:{cell:null===o?null:{id:o,field:n.field},columnHeader:null,columnHeaderFilter:null,columnGroupHeader:null}}))}},[e,t.pagination,t.paginationMode]),S=o.useMemo(()=>(0,Ts.A)(C,0),[C]),x=(0,Nt.A)(()=>{const n=Ai(e);if(!n)return;const r=ml(e,(t.pagination,t.paginationMode));if(r.rows.find(e=>e.id===n.id)||0===r.rows.length)return;const o=Ve(e);e.current.setState(e=>(0,y.A)({},e,{tabIndex:{cell:{id:r.rows[0].id,field:o[0].field},columnGroupHeader:null,columnHeader:null,columnHeaderFilter:null}}))}),E={moveFocusToRelativeCell:f,setColumnGroupHeaderFocus:u,getColumnGroupHeaderFocus:d};Bl(e,{setCellFocus:l,setColumnHeaderFocus:s,setColumnHeaderFilterFocus:c},"public"),Bl(e,E,"private"),o.useEffect(()=>{const t=(0,aa.A)(e.current.rootElementRef.current);return t.addEventListener("mouseup",v),()=>{t.removeEventListener("mouseup",v)}},[e,i,v]),$t(e,"columnHeaderBlur",A),$t(e,"cellDoubleClick",p),$t(e,"cellMouseDown",b),$t(e,"cellKeyDown",h),$t(e,"cellModeChange",w),$t(e,"columnHeaderFocus",g),$t(e,"columnGroupHeaderFocus",m),$t(e,"rowsSet",S),$t(e,"paginationModelChange",x)})(e,t),((e,t)=>{const n=ls(e,"useGridPreferencesPanel"),r=o.useCallback(()=>{e.current.setState(t=>{if(!t.preferencePanel.open)return t;n.debug("Hiding Preferences Panel");const r=et(e);return e.current.publishEvent("preferencePanelClose",{openedPanelValue:r.openedPanelValue}),(0,y.A)({},t,{preferencePanel:{open:!1}})})},[e,n]),i=o.useCallback((t,r,o)=>{n.debug("Opening Preferences Panel"),e.current.setState(e=>(0,y.A)({},e,{preferencePanel:(0,y.A)({},e.preferencePanel,{open:!0,openedPanelValue:t,panelId:r,labelId:o})})),e.current.publishEvent("preferencePanelOpen",{openedPanelValue:t})},[n,e]);Bl(e,{showPreferences:i,hidePreferences:r},"public");const a=o.useCallback((n,r)=>{const o=et(e);return!r.exportOnlyDirtyModels||null!=t.initialState?.preferencePanel||o.open?(0,y.A)({},n,{preferencePanel:o}):n},[e,t.initialState?.preferencePanel]),l=o.useCallback((t,n)=>{const r=n.stateToRestore.preferencePanel;return null!=r&&e.current.setState(e=>(0,y.A)({},e,{preferencePanel:r})),t},[e]);ws(e,"exportState",a),ws(e,"restoreState",l)})(e,t),((e,t,n)=>{const i=ls(e,"useGridFilter");e.current.registerControlState({stateId:"filter",propModel:t.filterModel,propOnChange:t.onFilterModelChange,stateSelector:Ko,changeEvent:"filterModelChange"});const a=o.useCallback(()=>{e.current.setState(t=>{const n=Ko(e),r=e.current.getFilterState(n),o=(0,y.A)({},t,{filter:(0,y.A)({},t.filter,r)}),i=Fs(e,o);return(0,y.A)({},o,{visibleRowsLookup:i})}),e.current.publishEvent("filteredRowsSet")},[e]),l=o.useCallback((e,n)=>null==n||!1===n.filterable||t.disableColumnFilter?e:[...e,"columnMenuFilterItem"],[t.disableColumnFilter]),s=o.useCallback(t=>{const n=Ko(e),r=[...n.items],o=r.findIndex(e=>e.id===t.id);-1===o?r.push(t):r[o]=t,e.current.setFilterModel((0,y.A)({},n,{items:r}),"upsertFilterItem")},[e]),c=o.useCallback(t=>{const n=Ko(e),r=[...n.items];t.forEach(e=>{const t=r.findIndex(t=>t.id===e.id);-1===t?r.push(e):r[t]=e}),e.current.setFilterModel((0,y.A)({},n,{items:r}),"upsertFilterItems")},[e]),u=o.useCallback(t=>{const n=Ko(e),r=n.items.filter(e=>e.id!==t.id);r.length!==n.items.length&&e.current.setFilterModel((0,y.A)({},n,{items:r}),"deleteFilterItem")},[e]),d=o.useCallback((n,r,o)=>{if(i.debug("Displaying filter panel"),n){const r=Ko(e),o=r.items.filter(t=>{if(void 0!==t.value)return!Array.isArray(t.value)||0!==t.value.length;const n=e.current.getColumn(t.field),r=n.filterOperators?.find(e=>e.value===t.operator);return!(void 0===r?.requiresFilterValue||r?.requiresFilterValue)});let i;const a=o.find(e=>e.field===n),l=e.current.getColumn(n);i=a?o:t.disableMultipleColumnsFiltering?[Cn({field:n,operator:l.filterOperators[0].value},e)]:[...o,Cn({field:n,operator:l.filterOperators[0].value},e)],e.current.setFilterModel((0,y.A)({},r,{items:i}))}e.current.showPreferences(nt.filters,r,o)},[e,i,t.disableMultipleColumnsFiltering]),f=o.useCallback(()=>{i.debug("Hiding filter panel"),e.current.hidePreferences()},[e,i]),p=o.useCallback(t=>{const n=Ko(e);n.logicOperator!==t&&e.current.setFilterModel((0,y.A)({},n,{logicOperator:t}),"changeLogicOperator")},[e]),h=o.useCallback(t=>{const n=Ko(e);la(n.quickFilterValues,t)||e.current.setFilterModel((0,y.A)({},n,{quickFilterValues:[...t]}))},[e]),g=o.useCallback((n,r)=>{Ko(e)!==n&&(i.debug("Setting filter model"),e.current.updateControlState("filter",xn(n,t.disableMultipleColumnsFiltering,e),r),e.current.unstable_applyFilters())},[e,i,t.disableMultipleColumnsFiltering]),m=o.useCallback(r=>{const o=Sn(r,t.disableMultipleColumnsFiltering,e),i=n.hooks.useFilterValueGetter(e,t),a="client"===t.filterMode?Mn(o,i,e,t.disableEval):null,l=e.current.applyStrategyProcessor("filtering",{isRowMatchingFilters:a,filterModel:o??vn(),filterValueGetter:i});return(0,y.A)({},l,{filterModel:o})},[e,n.hooks,t]),A={setFilterLogicOperator:p,unstable_applyFilters:a,deleteFilterItem:u,upsertFilterItem:s,upsertFilterItems:c,setFilterModel:g,showFilterPanel:d,hideFilterPanel:f,setQuickFilterValues:h,ignoreDiacritics:t.ignoreDiacritics,getFilterState:m};Bl(e,A,"public");const b=o.useCallback((n,r)=>{const o=Ko(e);return o.items.forEach(e=>{delete e.fromInput}),r.exportOnlyDirtyModels&&null==t.filterModel&&null==t.initialState?.filter?.filterModel&&la(o,vn())?n:(0,y.A)({},n,{filter:{filterModel:o}})},[e,t.filterModel,t.initialState?.filter?.filterModel]),v=o.useCallback((n,r)=>{const o=r.stateToRestore.filter?.filterModel;return null==o?n:(e.current.updateControlState("filter",xn(o,t.disableMultipleColumnsFiltering,e),"restoreState"),(0,y.A)({},n,{callbacks:[...n.callbacks,e.current.unstable_applyFilters]}))},[e,t.disableMultipleColumnsFiltering]),w=o.useCallback((e,n)=>{if(n===nt.filters){const e=t.slots.filterPanel;return(0,r.jsx)(e,(0,y.A)({},t.slotProps?.filterPanel))}return e},[t.slots.filterPanel,t.slotProps?.filterPanel]),{getRowId:C}=t,S=(0,G.A)(Qs),x=o.useCallback(n=>{if("client"!==t.filterMode||!n.isRowMatchingFilters||!n.filterModel.items.length&&!n.filterModel.quickFilterValues?.length)return bn;const r=Et(e),o={},{isRowMatchingFilters:i}=n,a={},l={passingFilterItems:null,passingQuickFilterValues:null},s=S.current(e.current.state.rows.dataRowIdToModelLookup);for(let t=0;t<s.length;t+=1){const r=s[t],c=C?C(r):r.id;i(r,void 0,l);const u=Bn([l.passingFilterItems],[l.passingQuickFilterValues],n.filterModel,n.filterValueGetter,e,a);u||(o[c]=u)}const c="auto-generated-group-footer-root";return r[c]&&(o[c]=!0),{filteredRowsLookup:o,filteredChildrenCountLookup:{},filteredDescendantCountLookup:{}}},[e,t.filterMode,C,S]);ws(e,"columnMenu",l),ws(e,"exportState",b),ws(e,"restoreState",v),ws(e,"preferencePanel",w),Ds(e,rs,"filtering",x),Ds(e,rs,"visibleRowsLookupCreation",Ls);const E=o.useCallback(()=>{i.debug("onColUpdated - GridColumns changed, applying filters");const t=Ko(e),n=ze(e),r=t.items.filter(e=>e.field&&n[e.field]);r.length<t.items.length&&e.current.setFilterModel((0,y.A)({},t,{items:r}))},[e,i]),I=o.useCallback(t=>{"filtering"===t&&e.current.unstable_applyFilters()},[e]),k=o.useCallback(()=>{e.current.setState(t=>(0,y.A)({},t,{visibleRowsLookup:Fs(e,t)}))},[e]);$t(e,"rowsSet",a),$t(e,"columnsChange",E),$t(e,"activeStrategyProcessorChange",I),$t(e,"rowExpansionChange",k),$t(e,"columnVisibilityModelChange",()=>{const t=Ko(e);t.quickFilterValues?.length&&Rn(t)&&a()}),Za(()=>{"DataGrid"===t.signature&&a()}),(0,Ut.A)(()=>{void 0!==t.filterModel&&e.current.setFilterModel(t.filterModel)},[e,i,t.filterModel])})(e,t,n),((e,t)=>{const n=ls(e,"useGridSorting");e.current.registerControlState({stateId:"sortModel",propModel:t.sortModel,propOnChange:t.onSortModelChange,stateSelector:Uo,changeEvent:"sortModelChange"});const r=o.useCallback((t,n)=>{const r=Uo(e),o=r.findIndex(e=>e.field===t);let i=[...r];return o>-1?null==n?.sort?i.splice(o,1):i.splice(o,1,n):i=[...r,n],i},[e]),i=o.useCallback((n,r)=>{const o=Uo(e).find(e=>e.field===n.field);if(o){const e=void 0===r?en(n.sortingOrder??t.sortingOrder,o.sort):r;return void 0===e?void 0:(0,y.A)({},o,{sort:e})}return{field:n.field,sort:void 0===r?en(n.sortingOrder??t.sortingOrder):r}},[e,t.sortingOrder]),a=o.useCallback((e,n)=>null==n||!1===n.sortable||t.disableColumnSorting?e:(n.sortingOrder||t.sortingOrder).some(e=>!!e)?[...e,"columnMenuSortItem"]:e,[t.sortingOrder,t.disableColumnSorting]),l=o.useCallback(()=>{e.current.setState(r=>{if("server"===t.sortingMode)return n.debug("Skipping sorting rows as sortingMode = server"),(0,y.A)({},r,{sorting:(0,y.A)({},r.sorting,{sortedRows:nr(It(e),Un,!1)})});const o=((e,t)=>{const n=e.map(e=>((e,t)=>{const n=t.current.getColumn(e.field);if(!n||null===e.sort)return null;let r;return r=n.getSortComparator?n.getSortComparator(e.sort):"desc"===e.sort?(...e)=>-1*n.sortComparator(...e):n.sortComparator,r?{getSortCellParams:e=>({id:e,field:n.field,rowNode:kt(t,e),value:t.current.getCellValue(e,n.field),api:t.current}),comparator:r}:null})(e,t)).filter(e=>!!e);return 0===n.length?null:e=>e.map(e=>({node:e,params:n.map(t=>t.getSortCellParams(e.id))})).sort((e,t)=>{return r=e,o=t,n.reduce((e,t,n)=>{if(0!==e)return e;const i=r.params[n],a=o.params[n];return t.comparator(i.value,a.value,i,a)},0);var r,o}).map(e=>e.node.id)})(Uo(e),e),i=e.current.applyStrategyProcessor("sorting",{sortRowList:o});return(0,y.A)({},r,{sorting:(0,y.A)({},r.sorting,{sortedRows:i})})}),e.current.publishEvent("sortedRowsSet")},[e,n,t.sortingMode]),s=o.useCallback(r=>{Uo(e)!==r&&(n.debug("Setting sort model"),e.current.setState(Zt(r,t.disableMultipleColumnsSorting)),e.current.applySorting())},[e,n,t.disableMultipleColumnsSorting]),c=o.useCallback((n,o,a)=>{const l=e.current.getColumn(n),s=i(l,o);let c;c=!a||t.disableMultipleColumnsSorting?null==s?.sort?[]:[s]:r(l.field,s),e.current.setSortModel(c)},[e,r,i,t.disableMultipleColumnsSorting]),u=o.useCallback(()=>Uo(e),[e]),d=o.useCallback(()=>Wo(e).map(e=>e.model),[e]),f=o.useCallback(()=>Vo(e),[e]),p=o.useCallback(t=>e.current.getSortedRowIds()[t],[e]);Bl(e,{getSortModel:u,getSortedRows:d,getSortedRowIds:f,getRowIdFromRowIndex:p,setSortModel:s,sortColumn:c,applySorting:l},"public");const h=o.useCallback((n,r)=>{const o=Uo(e);return!r.exportOnlyDirtyModels||null!=t.sortModel||null!=t.initialState?.sorting?.sortModel||o.length>0?(0,y.A)({},n,{sorting:{sortModel:o}}):n},[e,t.sortModel,t.initialState?.sorting?.sortModel]),g=o.useCallback((n,r)=>{const o=r.stateToRestore.sorting?.sortModel;return null==o?n:(e.current.setState(Zt(o,t.disableMultipleColumnsSorting)),(0,y.A)({},n,{callbacks:[...n.callbacks,e.current.applySorting]}))},[e,t.disableMultipleColumnsSorting]),m=o.useCallback(t=>{const n=It(e),r=n[Un],o=t.sortRowList?t.sortRowList(r.children.map(e=>n[e])):[...r.children];return null!=r.footerId&&o.push(r.footerId),o},[e]);ws(e,"exportState",h),ws(e,"restoreState",g),Ds(e,rs,"sorting",m);const A=o.useCallback(({field:e,colDef:n},r)=>{if(!n.sortable||t.disableColumnSorting)return;const o="always"===t.multipleColumnsSortingMode||r.shiftKey||r.metaKey||r.ctrlKey;c(e,void 0,o)},[c,t.disableColumnSorting,t.multipleColumnsSortingMode]),b=o.useCallback(({field:e,colDef:n},r)=>{n.sortable&&!t.disableColumnSorting&&("Enter"!==r.key||r.ctrlKey||r.metaKey||c(e,void 0,"always"===t.multipleColumnsSortingMode||r.shiftKey))},[c,t.disableColumnSorting,t.multipleColumnsSortingMode]),v=o.useCallback(()=>{const t=Uo(e),n=ze(e);if(t.length>0){const r=t.filter(e=>n[e.field]);r.length<t.length&&e.current.setSortModel(r)}},[e]),w=o.useCallback(t=>{"sorting"===t&&e.current.applySorting()},[e]);ws(e,"columnMenu",a),$t(e,"columnHeaderClick",A),$t(e,"columnHeaderKeyDown",b),$t(e,"rowsSet",e.current.applySorting),$t(e,"columnsChange",v),$t(e,"activeStrategyProcessorChange",w),Za(()=>{"DataGrid"===t.signature&&e.current.applySorting()}),(0,Ut.A)(()=>{void 0!==t.sortModel&&e.current.setSortModel(t.sortModel)},[e,t.sortModel])})(e,t),((e,t)=>{const n=ls(e,"useDensity");e.current.registerControlState({stateId:"density",propModel:t.density,propOnChange:t.onDensityChange,stateSelector:Pe,changeEvent:"densityChange"});const r=(0,Nt.A)(t=>{Pe(e)!==t&&(n.debug(`Set grid density to ${t}`),e.current.setState(e=>(0,y.A)({},e,{density:t})))});Bl(e,{setDensity:r},"public");const i=o.useCallback((n,r)=>{const o=Pe(e);return r.exportOnlyDirtyModels&&null==t.density&&null==t.initialState?.density?n:(0,y.A)({},n,{density:o})},[e,t.density,t.initialState?.density]),a=o.useCallback((t,n)=>{const r=n.stateToRestore?.density?n.stateToRestore.density:Pe(e);return e.current.setState(e=>(0,y.A)({},e,{density:r})),t},[e]);ws(e,"exportState",i),ws(e,"restoreState",a),o.useEffect(()=>{t.density&&e.current.setDensity(t.density)},[e,t.density])})(e,t),Gc(e,t),((e,t)=>{((e,t)=>{const n=ls(e,"useGridPaginationMeta");e.current.registerControlState({stateId:"paginationMeta",propModel:t.paginationMeta,propOnChange:t.onPaginationMetaChange,stateSelector:sl,changeEvent:"paginationMetaChange"});const r=o.useCallback(t=>{sl(e)!==t&&(n.debug("Setting 'paginationMeta' to",t),e.current.setState(e=>(0,y.A)({},e,{pagination:(0,y.A)({},e.pagination,{meta:t})})))},[e,n]);Bl(e,{setPaginationMeta:r},"public");const i=o.useCallback((n,r)=>{const o=sl(e);return r.exportOnlyDirtyModels&&null==t.paginationMeta&&null==t.initialState?.pagination?.meta?n:(0,y.A)({},n,{pagination:(0,y.A)({},n.pagination,{meta:o})})},[e,t.paginationMeta,t.initialState?.pagination?.meta]),a=o.useCallback((t,n)=>{const r=n.stateToRestore.pagination?.meta?n.stateToRestore.pagination.meta:sl(e);return e.current.setState(e=>(0,y.A)({},e,{pagination:(0,y.A)({},e.pagination,{meta:r})})),t},[e]);ws(e,"exportState",i),ws(e,"restoreState",a),o.useEffect(()=>{t.paginationMeta&&e.current.setPaginationMeta(t.paginationMeta)},[e,t.paginationMeta])})(e,t),((e,t)=>{const n=ls(e,"useGridPaginationModel"),r=J(e,Be),i=o.useRef(Ko(e)),a=Math.floor(t.rowHeight*r);e.current.registerControlState({stateId:"paginationModel",propModel:t.paginationModel,propOnChange:t.onPaginationModelChange,stateSelector:al,changeEvent:"paginationModelChange"});const l=o.useCallback(t=>{const r=al(e);t!==r.page&&(n.debug(`Setting page to ${t}`),e.current.setPaginationModel({page:t,pageSize:r.pageSize}))},[e,n]),s=o.useMemo(()=>(0,Ts.A)(l,0),[l]),c=o.useCallback(t=>{const r=al(e);t!==r.pageSize&&(n.debug(`Setting page size to ${t}`),e.current.setPaginationModel({pageSize:t,page:r.page}))},[e,n]),u=o.useCallback(r=>{const o=al(e);r!==o&&(n.debug("Setting 'paginationModel' to",r),e.current.setState(e=>(0,y.A)({},e,{pagination:(0,y.A)({},e.pagination,{paginationModel:Os(e.pagination,t.signature,r)})}),"setPaginationModel"))},[e,n,t.signature]);Bl(e,{setPage:l,setPageSize:c,setPaginationModel:u},"public");const d=o.useCallback((n,r)=>{const o=al(e);return!r.exportOnlyDirtyModels||null!=t.paginationModel||null!=t.initialState?.pagination?.paginationModel||0!==o.page&&o.pageSize!==(t.autoPageSize?0:100)?(0,y.A)({},n,{pagination:(0,y.A)({},n.pagination,{paginationModel:o})}):n},[e,t.paginationModel,t.initialState?.pagination?.paginationModel,t.autoPageSize]),f=o.useCallback((n,r)=>{const o=r.stateToRestore.pagination?.paginationModel?(0,y.A)({},nl(t.autoPageSize),r.stateToRestore.pagination?.paginationModel):al(e);return e.current.setState(e=>(0,y.A)({},e,{pagination:(0,y.A)({},e.pagination,{paginationModel:Os(e.pagination,t.signature,o)})}),"stateRestorePreProcessing"),n},[e,t.autoPageSize,t.signature]);ws(e,"exportState",d),ws(e,"restoreState",f);const p=o.useCallback(()=>{if(!t.autoPageSize)return;const n=e.current.getRootDimensions(),r=Math.max(1,Math.floor(n.viewportInnerSize.height/a));e.current.setPageSize(r)},[e,t.autoPageSize,a]),h=o.useCallback(t=>{if(null==t)return;const n=al(e);if(0===n.page)return;const r=dl(e);n.page>r-1&&queueMicrotask(()=>{s(Math.max(0,r-1))})},[e,s]),g=o.useCallback(()=>{0!==al(e).page&&s(0),0!==e.current.getScrollPosition().top&&e.current.scroll({top:0})},[e,s]),m=o.useMemo(()=>(0,Ts.A)(g,0),[g]),A=o.useCallback(t=>{const n=(0,y.A)({},t,{items:si(e)});la(n,i.current)||(i.current=n,m())},[e,m]);$t(e,"viewportInnerSizeChange",p),$t(e,"paginationModelChange",()=>{const t=al(e);e.current.virtualScrollerRef?.current&&e.current.scrollToIndexes({rowIndex:t.page*t.pageSize})}),$t(e,"rowCountChange",h),$t(e,"sortModelChange",m),$t(e,"filterModelChange",A);const b=o.useRef(!0);o.useEffect(()=>{b.current?b.current=!1:t.pagination&&e.current.setState(e=>(0,y.A)({},e,{pagination:(0,y.A)({},e.pagination,{paginationModel:Os(e.pagination,t.signature,t.paginationModel)})}))},[e,t.paginationModel,t.signature,t.pagination]),o.useEffect(()=>{e.current.setState(e=>{const n=!0===t.pagination;return e.pagination.paginationMode===t.paginationMode&&e.pagination.enabled===n?e:(0,y.A)({},e,{pagination:(0,y.A)({},e.pagination,{paginationMode:t.paginationMode,enabled:n})})})},[e,t.paginationMode,t.pagination]),o.useEffect(p,[p])})(e,t),((e,t)=>{const n=ls(e,"useGridRowCount"),r=(0,G.A)(()=>al(e).pageSize);e.current.registerControlState({stateId:"paginationRowCount",propModel:t.rowCount,propOnChange:t.onRowCountChange,stateSelector:ll,changeEvent:"rowCountChange"});const i=o.useCallback(t=>{ll(e)!==t&&(n.debug("Setting 'rowCount' to",t),e.current.setState(e=>(0,y.A)({},e,{pagination:(0,y.A)({},e.pagination,{rowCount:t})})))},[e,n]);Bl(e,{setRowCount:i},"public");const a=o.useCallback((n,r)=>{const o=ll(e);return r.exportOnlyDirtyModels&&null==t.rowCount&&null==t.initialState?.pagination?.rowCount?n:(0,y.A)({},n,{pagination:(0,y.A)({},n.pagination,{rowCount:o})})},[e,t.rowCount,t.initialState?.pagination?.rowCount]),l=o.useCallback((t,n)=>{const r=n.stateToRestore.pagination?.rowCount?n.stateToRestore.pagination.rowCount:ll(e);return e.current.setState(e=>(0,y.A)({},e,{pagination:(0,y.A)({},e.pagination,{rowCount:r})})),t},[e]);ws(e,"exportState",a),ws(e,"restoreState",l);const s=o.useCallback(n=>{"client"!==t.paginationMode&&r.current&&n.pageSize!==r.current&&(r.current=n.pageSize,-1===ll(e)&&e.current.setPage(0))},[t.paginationMode,r,e]);$t(e,"paginationModelChange",s),o.useEffect(()=>{"server"===t.paginationMode&&null!=t.rowCount&&e.current.setRowCount(t.rowCount)},[e,t.paginationMode,t.rowCount]),na(e.current.store,()=>!(!1!==sl(e).hasNextPage)||("client"===t.paginationMode?ai(e):void 0),(t,n)=>{if(!0===n&&-1!==ll(e)){const t=ai(e),n=al(e);e.current.setRowCount(n.pageSize*n.page+t)}else"number"==typeof n&&e.current.setRowCount(n)}),o.useEffect(()=>{"client"===t.paginationMode&&e.current.setRowCount(ai(e))},[e,t.paginationMode])})(e,t)})(e,t),((e,t)=>{const n=(0,Hr.I)(),r=ls(e,"useGridScroll"),i=e.current.columnHeadersContainerRef,a=e.current.virtualScrollerRef,l=o.useCallback(n=>{const o=ut(e),i=Ct(e),l=Ve(e);if(null!=n.rowIndex&&0===i||0===l.length)return!1;r.debug(`Scrolling to cell at row ${n.rowIndex}, col: ${n.colIndex} `);let s={};if(void 0!==n.colIndex&&l[n.colIndex]){const t=Ke(e);let r;if(void 0!==n.rowIndex){const t=ei(e),o=t[n.rowIndex]?.id,i=e.current.unstable_getCellColSpanInfo(o,n.colIndex);i&&!i.spannedByColSpan&&(r=i.cellProps.width)}void 0===r&&(r=l[n.colIndex].computedWidth),s.left=yc({containerSize:o.viewportOuterSize.width,scrollPosition:Math.abs(a.current?.scrollLeft??0),elementSize:r,elementOffset:t[n.colIndex]})}if(void 0!==n.rowIndex){const r=No(e),i=cl(e),l=ul(e),c=t.pagination?n.rowIndex-i*l:n.rowIndex,u=r.positions[c+1]?r.positions[c+1]-r.positions[c]:r.currentPageTotalHeight-r.positions[c];s.top=yc({containerSize:o.viewportInnerSize.height,scrollPosition:a.current?.scrollTop??0,elementSize:u,elementOffset:r.positions[c]})}return s=e.current.unstable_applyPipeProcessors("scrollToIndexes",s,n),(void 0!==s.left||void 0!==s.top)&&(e.current.scroll(s),!0)},[r,e,a,t.pagination]),s=o.useCallback(e=>{if(a.current&&void 0!==e.left&&i.current){const t=n?-1:1;i.current.scrollLeft=e.left,a.current.scrollLeft=t*e.left,r.debug(`Scrolling left: ${e.left}`)}a.current&&void 0!==e.top&&(a.current.scrollTop=e.top,r.debug(`Scrolling top: ${e.top}`)),r.debug("Scrolling, updating container, and viewport")},[a,n,i,r]),c=o.useCallback(()=>a?.current?{top:a.current.scrollTop,left:a.current.scrollLeft}:{top:0,left:0},[a]);Bl(e,{scroll:s,scrollToIndexes:l,getScrollPosition:c},"public")})(e,t),(e=>{const t=ls(e,"useGridColumnMenu"),n=o.useRef({}),r=o.useCallback(()=>{n.current.wheel?.(),n.current.touchMove?.()},[]),i=o.useCallback(()=>{r(),n.current.wheel=e.current.subscribeEvent("virtualScrollerWheel",e.current.hideColumnMenu),n.current.touchMove=e.current.subscribeEvent("virtualScrollerTouchMove",e.current.hideColumnMenu)},[e,r]),a=o.useCallback(n=>{const r=xi(e),o=n;(!0!==r.open||o!==r.field)&&(e.current.setState(e=>e.columnMenu.open&&e.columnMenu.field===n?e:(t.debug("Opening Column Menu"),i(),(0,y.A)({},e,{columnMenu:{open:!0,field:n}}))),e.current.hidePreferences())},[e,t,i]),l=o.useCallback(()=>{const n=xi(e);if(n.field){const t=ze(e),r=He(e),o=je(e);let i=n.field;if(t[i]||(i=o[0]),!1===r[i]){const e=o.filter(e=>e===i||!1!==r[e]),t=e.indexOf(i);i=e[t+1]||e[t-1]}e.current.setColumnHeaderFocus(i)}const o={open:!1,field:void 0};(o.open!==n.open||o.field!==n.field)&&e.current.setState(e=>(t.debug("Hiding Column Menu"),r(),(0,y.A)({},e,{columnMenu:o})))},[e,t,r]),s=o.useCallback(n=>{t.debug("Toggle Column Menu");const r=xi(e);r.open&&r.field===n?l():a(n)},[e,t,a,l]);Bl(e,{showColumnMenu:a,hideColumnMenu:l,toggleColumnMenu:s},"public"),$t(e,"columnResizeStart",l)})(e),_s(e,t),((e,t)=>{const n=null!==e.current.rootElementRef.current,i=ls(e,"useGridPrintExport"),a=o.useRef(null),l=o.useRef(null),s=o.useRef({}),c=o.useRef([]),u=o.useRef(null);o.useEffect(()=>{a.current=(0,aa.A)(e.current.rootElementRef.current)},[e,n]);const d=o.useCallback((t,n,r)=>new Promise(o=>{const i=xs({apiRef:e,options:{fields:t,allColumns:n}}).map(e=>e.field),a=$e(e),l={};a.forEach(e=>{l[e.field]=i.includes(e.field)}),r&&(l[gs.field]=!0),e.current.setColumnVisibilityModel(l),o()}),[e]),f=o.useCallback(t=>{const n=t({apiRef:e}).reduce((t,n)=>{const r=e.current.getRow(n);return r[qn]||t.push(r),t},[]);e.current.setRows(n)},[e]),p=o.useCallback((t,n)=>{const r=(0,y.A)({copyStyles:!0,hideToolbar:!1,hideFooter:!1,includeCheckboxes:!1},n),o=t.contentDocument;if(!o)return;const i=e.current.rootElementRef.current,l=i.cloneNode(!0),s=l.querySelector(`.${L.virtualScrollerContent}`);if(l.querySelector(`.${L.main}`).style.overflow="visible",l.querySelector(`.${L.virtualScrollerRenderZone}`).style.position="static",s.style.flexBasis="auto",l.querySelector(`.${L["scrollbar--vertical"]}`)?.remove(),!(s.nextSibling instanceof HTMLElement&&s.nextSibling.classList.contains(L.filler))){const e=document.createElement("div");e.style.height=Hi,s.insertAdjacentElement("afterend",e)}const c=l.querySelector(`.${L.footerContainer}`);r.hideToolbar&&l.querySelector(`.${L.toolbar}`)?.remove(),r.hideFooter&&c&&c.remove(),l.style.height="auto",l.style.boxSizing="content-box",!r.hideFooter&&c&&(c.style.width="100%");const u=document.createElement("div");u.appendChild(l),o.body.style.marginTop="0px",o.body.innerHTML=u.innerHTML;const d="function"==typeof r.pageStyle?r.pageStyle():r.pageStyle;if("string"==typeof d){const e=o.createElement("style");e.appendChild(o.createTextNode(d)),o.head.appendChild(e)}r.bodyClassName&&o.body.classList.add(...r.bodyClassName.split(" "));let f=[];if(r.copyStyles){const e=i.getRootNode();f=function(e,t){const n=[],r=t.querySelectorAll("style, link[rel='stylesheet']");for(let t=0;t<r.length;t+=1){const o=r[t],i=e.createElement(o.tagName);if("STYLE"===o.tagName){const t=o.sheet;if(t){let n="";for(let e=0;e<t.cssRules.length;e+=1)"string"==typeof t.cssRules[e].cssText&&(n+=`${t.cssRules[e].cssText}\r\n`);i.appendChild(e.createTextNode(n))}}else if(o.getAttribute("href")){for(let e=0;e<o.attributes.length;e+=1){const t=o.attributes[e];t&&i.setAttribute(t.nodeName,t.nodeValue||"")}n.push(new Promise(e=>{i.addEventListener("load",()=>e())}))}e.head.appendChild(i)}return n}(o,"ShadowRoot"===e.constructor.name?e:a.current)}Promise.all(f).then(()=>{t.contentWindow.print()})},[e,a]),h=o.useCallback(t=>{a.current.body.removeChild(t),e.current.restoreState(l.current||{}),l.current?.columns?.columnVisibilityModel||e.current.setColumnVisibilityModel(s.current),e.current.setState(e=>(0,y.A)({},e,{virtualization:u.current})),e.current.setRows(c.current),l.current=null,s.current={},c.current=[]},[e]),g=o.useCallback(async n=>{if(i.debug("Export data as Print"),!e.current.rootElementRef.current)throw new Error("MUI X: No grid root element available.");if(l.current=e.current.exportState(),s.current=He(e),c.current=e.current.getSortedRows().filter(e=>!e[qn]),t.pagination){const t={page:0,pageSize:ii(e)};e.current.setState(e=>(0,y.A)({},e,{pagination:(0,y.A)({},e.pagination,{paginationModel:Os(e.pagination,"DataGridPro",t)})}))}u.current=e.current.state.virtualization,e.current.unstable_setVirtualization(!1),await d(n?.fields,n?.allColumns,n?.includeCheckboxes),f(n?.getRowsToExport??Es),await new Promise(e=>{requestAnimationFrame(()=>{e()})});const r=function(e){const t=document.createElement("iframe");return t.style.position="absolute",t.style.width="0px",t.style.height="0px",t.title=e||document.title,t}(n?.fileName);r.onload=()=>{p(r,n),r.contentWindow.matchMedia("print").addEventListener("change",e=>{!1===e.matches&&h(r)})},a.current.body.appendChild(r)},[t,i,e,p,h,d,f]);Bl(e,{exportDataAsPrint:g},"public");const m=o.useCallback((e,t)=>t.printOptions?.disableToolbarButton?e:[...e,{component:(0,r.jsx)(Bs,{options:t.printOptions}),componentName:"printExport"}],[]);ws(e,"exportMenu",m)})(e,t),((e,t)=>{const n=t.ignoreValueFormatterDuringExport,r=("object"==typeof n?n?.clipboardExport:n)||!1,i=t.clipboardCopyCellDelimiter,a=o.useCallback(t=>{if(!function(e){return(e.ctrlKey||e.metaKey)&&"C"===String.fromCharCode(e.keyCode)&&!e.shiftKey&&!e.altKey}(t))return;if(n=t.target,window.getSelection()?.toString()||n&&(n.selectionEnd||0)-(n.selectionStart||0)>0)return;var n;let o="";if(Rl(e)>0)o=e.current.getDataAsCsv({includeHeaders:!1,delimiter:i,shouldAppendQuotes:!1,escapeFormulas:!1});else{const t=Ai(e);if(t){const n=e.current.getCellParams(t.id,t.field);o=As(n,{csvOptions:{delimiter:i,shouldAppendQuotes:!1,escapeFormulas:!1},ignoreValueFormatter:r})}}var a;o=e.current.unstable_applyPipeProcessors("clipboardCopy",o),o&&(a=o,navigator.clipboard?navigator.clipboard.writeText(a).catch(()=>{vs(a)}):vs(a),e.current.publishEvent("clipboardCopy",o))},[e,r,i]);ss(e,()=>e.current.rootElementRef.current,"keydown",a),Gt(e,"clipboardCopy",t.onClipboardCopy)})(e,t),function(e,t){const n=o.useCallback(()=>ut(e),[e]),r={updateDimensions:()=>e.current.virtualizer.api.updateDimensions(),getViewportPageSize:()=>e.current.virtualizer.api.getViewportPageSize()};Bl(e,{getRootDimensions:n},"public"),Bl(e,r,"private"),Gt(e,"rootMount",t=>{Ec(t,ut(e))}),Gt(e,"debouncedResize",t.onResize),na(e.current.store,e=>e.dimensions,(t,n)=>{var r,o;n.isReady&&(e.current.rootElementRef.current&&Ec(e.current.rootElementRef.current,n),r=n.viewportInnerSize,o=t.viewportInnerSize,(r.width!==o.width||r.height!==o.height)&&e.current.publishEvent("viewportInnerSizeChange",n.viewportInnerSize),e.current.publishEvent("debouncedResize",n.root))})}(e,t),function(e,t){Gt(e,"columnHeaderClick",t.onColumnHeaderClick),Gt(e,"columnHeaderContextMenu",t.onColumnHeaderContextMenu),Gt(e,"columnHeaderDoubleClick",t.onColumnHeaderDoubleClick),Gt(e,"columnHeaderOver",t.onColumnHeaderOver),Gt(e,"columnHeaderOut",t.onColumnHeaderOut),Gt(e,"columnHeaderEnter",t.onColumnHeaderEnter),Gt(e,"columnHeaderLeave",t.onColumnHeaderLeave),Gt(e,"cellClick",t.onCellClick),Gt(e,"cellDoubleClick",t.onCellDoubleClick),Gt(e,"cellKeyDown",t.onCellKeyDown),Gt(e,"preferencePanelClose",t.onPreferencePanelClose),Gt(e,"preferencePanelOpen",t.onPreferencePanelOpen),Gt(e,"menuOpen",t.onMenuOpen),Gt(e,"menuClose",t.onMenuClose),Gt(e,"rowDoubleClick",t.onRowDoubleClick),Gt(e,"rowClick",t.onRowClick),Gt(e,"stateChange",t.onStateChange)}(e,t),(e=>{const t=o.useCallback((t={})=>e.current.unstable_applyPipeProcessors("exportState",{},t),[e]),n=o.useCallback(t=>{e.current.unstable_applyPipeProcessors("restoreState",{callbacks:[]},{stateToRestore:t}).callbacks.forEach(e=>{e()})},[e]);Bl(e,{exportState:t,restoreState:n},"public")})(e),function(e,t){const{autoHeight:n,disableVirtualization:r}=t,i=t=>{const{virtualizer:r}=e.current;t&&=Tc;const o=r.store.getSnapshot();o.virtualization.enabled===t&&o.virtualization.enabledForRows===t&&o.virtualization.enabledForColumns===t||r.store.set("virtualization",(0,y.A)({},r.store.state.virtualization,{enabled:t,enabledForColumns:t,enabledForRows:t&&!n}))};Bl(e,{unstable_setVirtualization:i,unstable_setColumnVirtualization:t=>{const{virtualizer:n}=e.current;t&&=Tc,n.store.getSnapshot().virtualization.enabledForColumns!==t&&n.store.set("virtualization",(0,y.A)({},n.store.state.virtualization,{enabledForColumns:t}))}},"public");const a=()=>{const{virtualizer:t}=e.current;t?.api.scheduleUpdateRenderContext()};e.current.register("private",{updateRenderContext:a}),Gt(e,"sortedRowsSet",a),Gt(e,"paginationModelChange",a),Gt(e,"columnsChange",a),o.useEffect(()=>{e.current.virtualizer&&i(!t.disableVirtualization)},[e,r,n])}(e,t),function(e,t){const n=()=>{e.current.setState(t=>t.listViewColumn?(0,y.A)({},t,{listViewColumn:(0,y.A)({},t.listViewColumn,{computedWidth:Jc(e)})}):t)},r=o.useRef(null);$t(e,"viewportInnerSizeChange",e=>{r.current!==e.width&&(r.current=e.width,n())}),$t(e,"columnVisibilityModelChange",n),(0,Ut.A)(()=>{const n=t.listViewColumn;n&&e.current.setState(t=>(0,y.A)({},t,{listViewColumn:(0,y.A)({},n,{computedWidth:Jc(e)})}))},[e,t.listViewColumn]),o.useEffect(()=>{t.listView&&t.listViewColumn},[t.listView,t.listViewColumn])}(e,t),((e,t)=>{const{api:n,strategyProcessor:r,events:i,setStrategyAvailability:a}=((e,t,n={})=>{const r=o.useCallback(()=>{e.current.setStrategyAvailability(ns.DataSource,Zc.Default,t.dataSource?()=>!0:()=>!1)},[e,t.dataSource]),[i,a]=o.useState(e.current.getActiveStrategy(ns.DataSource)),l=o.useMemo(()=>i===Zc.Default||i===Zc.GroupedData,[i]),s=J(e,al),c=o.useRef(0),u=o.useRef(null),d=t.onDataSourceError,f=t.dataSourceRevalidateMs,p=(0,G.A)(()=>{if(!t.pagination)return new eu(s.pageSize);const e=t.pageSizeOptions.map(e=>"number"==typeof e?e:e.value).sort((e,t)=>e-t),n=Math.min(s.pageSize,e[0]);return new eu(n)}).current,[h,g]=o.useState(()=>lu(t.dataSourceCache,n.cacheOptions)),m=o.useCallback(async(r,o)=>{const i=t.dataSource?.getRows;if(!i)return;if(r&&r!==Un&&"DataGrid"!==t.signature)return void n.fetchRowChildren?.([r]);n.clearDataSourceState?.();const a=o||{},{skipCache:s,keepChildrenExpanded:u}=a,f=(0,x.A)(a,iu),g=(0,y.A)({},Xc(e),e.current.unstable_applyPipeProcessors("getRowsParams",{}),f),m=p.getCacheKeys(g).map(e=>h.get(e));if(!s&&m.every(e=>void 0!==e))return void e.current.applyStrategyProcessor("dataSourceRowsUpdate",{response:eu.mergeResponses(m),fetchParams:g,options:{skipCache:s,keepChildrenExpanded:u}});(l||0===e.current.getRowsCount())&&e.current.setLoading(!0);const A=c.current+1;c.current=A;try{const t=await i(g);p.splitResponse(g,t).forEach((e,t)=>h.set(t,e)),c.current===A&&e.current.applyStrategyProcessor("dataSourceRowsUpdate",{response:t,fetchParams:g,options:{skipCache:s,keepChildrenExpanded:u}})}catch(t){c.current===A&&(e.current.applyStrategyProcessor("dataSourceRowsUpdate",{error:t,fetchParams:g,options:{skipCache:s,keepChildrenExpanded:u}}),"function"==typeof d&&d(new ru({message:t?.message,params:g,cause:t})))}finally{l&&c.current===A&&e.current.setLoading(!1)}},[p,h,e,l,t.dataSource?.getRows,d,n,t.signature]),A=o.useCallback(()=>{a(e.current.getActiveStrategy(ns.DataSource))},[e]),b=n.fetchRowChildren,v=(0,Nt.A)(async()=>{const n=t.dataSource?.getRows;if(!n||!l)return;const r=()=>{if(i!==Zc.GroupedData||!b)return;const t=It(e),n=gl(e).rows.reduce((e,n)=>{const r=t[n.id];return"group"===r.type&&r.id!==Un&&!0===r.childrenExpanded&&e.push(n.id),e},[]);n.length>0&&b(n,{showChildrenLoading:!1})},o=(0,y.A)({},Xc(e),e.current.unstable_applyPipeProcessors("getRowsParams",{}));if(p.getCacheKeys(o).map(e=>h.get(e)).every(e=>void 0!==e))r();else try{const t=await n(o);if(!la(o,(0,y.A)({},Xc(e),e.current.unstable_applyPipeProcessors("getRowsParams",{}))))return;p.splitResponse(o,t).forEach((e,t)=>h.set(t,e)),e.current.applyStrategyProcessor("dataSourceRowsUpdate",{response:t,fetchParams:o,options:{}}),r()}catch{}}),w=o.useCallback(()=>{null!==u.current&&(clearInterval(u.current),u.current=null)},[]),C=(0,Nt.A)(()=>{w(),f<=0||!l||(u.current=setInterval(v,f))}),S=o.useCallback(t=>{if("error"in t)return void e.current.setRows([]);const{response:n}=t;void 0!==n.rowCount&&e.current.setRowCount(n.rowCount),e.current.setRows(n.rows),e.current.unstable_applyPipeProcessors("processDataSourceRows",{params:t.fetchParams,response:n},!0),C()},[e,C]),E=t.dataSource?.updateRow,I=n.handleEditRow,k=o.useCallback(async t=>{if(E)try{const n=await E(t);return"function"==typeof I?(I(t,n),n):(n&&!la(n,t.previousRow)&&e.current.dataSource.cache.clear(),e.current.updateNestedRows([n],[]),n)}catch(e){throw"function"==typeof d&&d(new ou({message:e?.message,params:t,cause:e})),e}},[e,E,d,I]),R={dataSource:{fetchRows:m,cache:h,editRow:k}},M=o.useMemo(()=>(0,Ts.A)(m,0),[m]),P=o.useCallback(()=>{e.current.setRows([]),w(),M()},[w,M,e]),B=o.useRef(!0);return o.useEffect(()=>{if(B.current)return void(B.current=!1);if(void 0===t.dataSourceCache)return;const e=lu(t.dataSourceCache,n.cacheOptions);g(t=>t!==e?e:t)},[t.dataSourceCache,n.cacheOptions]),o.useEffect(()=>{l||w()},[l,w]),o.useEffect(()=>{f<=0&&w()},[f,w]),o.useEffect(()=>w,[w]),o.useEffect(()=>{if(i===Zc.Default||i===Zc.LazyLoading||i===Zc.GroupedData)return t.dataSource&&(w(),e.current.setRows([]),e.current.dataSource.cache.clear(),e.current.dataSource.fetchRows()),()=>{c.current+=1}},[e,t.dataSource,i,w]),{api:{public:R},debouncedFetchRows:M,strategyProcessor:{strategyName:Zc.Default,group:"dataSourceRowsUpdate",processor:S},setStrategyAvailability:r,startPolling:C,stopPolling:w,cacheChunkManager:p,cache:h,events:{strategyAvailabilityChange:A,sortModelChange:hn(l,P),filterModelChange:hn(l,P),paginationModelChange:hn(l,P)}}})(e,t);Bl(e,n.public,"public"),Ds(e,r.strategyName,r.group,r.processor),Object.entries(i).forEach(([t,n])=>{$t(e,t,n)}),o.useEffect(()=>{a()},[a])})(e,t),Za(()=>{e.current.runAppliersForPendingProcessors()}),o.useEffect(()=>{e.current.runAppliersForPendingProcessors()})};var cu=n(5835),uu=n(6096);const du={noRowsLabel:"No rows",noResultsOverlayLabel:"No results found.",noColumnsOverlayLabel:"No columns",noColumnsOverlayManageColumns:"Manage columns",emptyPivotOverlayLabel:"Add fields to rows, columns, and values to create a pivot table",toolbarDensity:"Density",toolbarDensityLabel:"Density",toolbarDensityCompact:"Compact",toolbarDensityStandard:"Standard",toolbarDensityComfortable:"Comfortable",toolbarUndo:"Undo",toolbarRedo:"Redo",toolbarColumns:"Columns",toolbarColumnsLabel:"Select columns",toolbarFilters:"Filters",toolbarFiltersLabel:"Show filters",toolbarFiltersTooltipHide:"Hide filters",toolbarFiltersTooltipShow:"Show filters",toolbarFiltersTooltipActive:e=>1!==e?`${e} active filters`:`${e} active filter`,toolbarQuickFilterPlaceholder:"Search…",toolbarQuickFilterLabel:"Search",toolbarQuickFilterDeleteIconLabel:"Clear",toolbarExport:"Export",toolbarExportLabel:"Export",toolbarExportCSV:"Download as CSV",toolbarExportPrint:"Print",toolbarExportExcel:"Download as Excel",toolbarPivot:"Pivot",toolbarCharts:"Charts",toolbarAssistant:"AI Assistant",columnsManagementSearchTitle:"Search",columnsManagementNoColumns:"No columns",columnsManagementShowHideAllText:"Show/Hide All",columnsManagementReset:"Reset",columnsManagementDeleteIconLabel:"Clear",filterPanelAddFilter:"Add filter",filterPanelRemoveAll:"Remove all",filterPanelDeleteIconLabel:"Delete",filterPanelLogicOperator:"Logic operator",filterPanelOperator:"Operator",filterPanelOperatorAnd:"And",filterPanelOperatorOr:"Or",filterPanelColumns:"Columns",filterPanelInputLabel:"Value",filterPanelInputPlaceholder:"Filter value",filterOperatorContains:"contains",filterOperatorDoesNotContain:"does not contain",filterOperatorEquals:"equals",filterOperatorDoesNotEqual:"does not equal",filterOperatorStartsWith:"starts with",filterOperatorEndsWith:"ends with",filterOperatorIs:"is",filterOperatorNot:"is not",filterOperatorAfter:"is after",filterOperatorOnOrAfter:"is on or after",filterOperatorBefore:"is before",filterOperatorOnOrBefore:"is on or before",filterOperatorIsEmpty:"is empty",filterOperatorIsNotEmpty:"is not empty",filterOperatorIsAnyOf:"is any of","filterOperator=":"=","filterOperator!=":"!=","filterOperator>":">","filterOperator>=":">=","filterOperator<":"<","filterOperator<=":"<=",headerFilterOperatorContains:"Contains",headerFilterOperatorDoesNotContain:"Does not contain",headerFilterOperatorEquals:"Equals",headerFilterOperatorDoesNotEqual:"Does not equal",headerFilterOperatorStartsWith:"Starts with",headerFilterOperatorEndsWith:"Ends with",headerFilterOperatorIs:"Is",headerFilterOperatorNot:"Is not",headerFilterOperatorAfter:"Is after",headerFilterOperatorOnOrAfter:"Is on or after",headerFilterOperatorBefore:"Is before",headerFilterOperatorOnOrBefore:"Is on or before",headerFilterOperatorIsEmpty:"Is empty",headerFilterOperatorIsNotEmpty:"Is not empty",headerFilterOperatorIsAnyOf:"Is any of","headerFilterOperator=":"Equals","headerFilterOperator!=":"Not equals","headerFilterOperator>":"Greater than","headerFilterOperator>=":"Greater than or equal to","headerFilterOperator<":"Less than","headerFilterOperator<=":"Less than or equal to",headerFilterClear:"Clear filter",filterValueAny:"any",filterValueTrue:"true",filterValueFalse:"false",columnMenuLabel:"Menu",columnMenuAriaLabel:e=>`${e} column menu`,columnMenuShowColumns:"Show columns",columnMenuManageColumns:"Manage columns",columnMenuFilter:"Filter",columnMenuHideColumn:"Hide column",columnMenuUnsort:"Unsort",columnMenuSortAsc:"Sort by ASC",columnMenuSortDesc:"Sort by DESC",columnMenuManagePivot:"Manage pivot",columnMenuManageCharts:"Manage charts",columnHeaderFiltersTooltipActive:e=>1!==e?`${e} active filters`:`${e} active filter`,columnHeaderFiltersLabel:"Show filters",columnHeaderSortIconLabel:"Sort",footerRowSelected:e=>1!==e?`${e.toLocaleString()} rows selected`:`${e.toLocaleString()} row selected`,footerTotalRows:"Total Rows:",footerTotalVisibleRows:(e,t)=>`${e.toLocaleString()} of ${t.toLocaleString()}`,checkboxSelectionHeaderName:"Checkbox selection",checkboxSelectionSelectAllRows:"Select all rows",checkboxSelectionUnselectAllRows:"Unselect all rows",checkboxSelectionSelectRow:"Select row",checkboxSelectionUnselectRow:"Unselect row",booleanCellTrueLabel:"yes",booleanCellFalseLabel:"no",longTextCellExpandLabel:"Expand",longTextCellCollapseLabel:"Collapse",actionsCellMore:"more",pinToLeft:"Pin to left",pinToRight:"Pin to right",unpin:"Unpin",treeDataGroupingHeaderName:"Group",treeDataExpand:"see children",treeDataCollapse:"hide children",groupingColumnHeaderName:"Group",groupColumn:e=>`Group by ${e}`,unGroupColumn:e=>`Stop grouping by ${e}`,detailPanelToggle:"Detail panel toggle",expandDetailPanel:"Expand",collapseDetailPanel:"Collapse",paginationRowsPerPage:"Rows per page:",paginationDisplayedRows:({from:e,to:t,count:n,estimated:r})=>r?`${e}–${t} of ${-1!==n?n:r&&r>t?`around ${r}`:`more than ${t}`}`:`${e}–${t} of ${-1!==n?n:`more than ${t}`}`,paginationItemAriaLabel:e=>"first"===e?"Go to first page":"last"===e?"Go to last page":"next"===e?"Go to next page":"Go to previous page",rowReorderingHeaderName:"Row reordering",aggregationMenuItemHeader:"Aggregation",aggregationFunctionLabelNone:"none",aggregationFunctionLabelSum:"sum",aggregationFunctionLabelAvg:"avg",aggregationFunctionLabelMin:"min",aggregationFunctionLabelMax:"max",aggregationFunctionLabelSize:"size",pivotToggleLabel:"Pivot",pivotRows:"Rows",pivotColumns:"Columns",pivotValues:"Values",pivotCloseButton:"Close pivot settings",pivotSearchButton:"Search fields",pivotSearchControlPlaceholder:"Search fields",pivotSearchControlLabel:"Search fields",pivotSearchControlClear:"Clear search",pivotNoFields:"No fields",pivotMenuMoveUp:"Move up",pivotMenuMoveDown:"Move down",pivotMenuMoveToTop:"Move to top",pivotMenuMoveToBottom:"Move to bottom",pivotMenuRows:"Rows",pivotMenuColumns:"Columns",pivotMenuValues:"Values",pivotMenuOptions:"Field options",pivotMenuAddToRows:"Add to Rows",pivotMenuAddToColumns:"Add to Columns",pivotMenuAddToValues:"Add to Values",pivotMenuRemove:"Remove",pivotDragToRows:"Drag here to create rows",pivotDragToColumns:"Drag here to create columns",pivotDragToValues:"Drag here to create values",pivotYearColumnHeaderName:"(Year)",pivotQuarterColumnHeaderName:"(Quarter)",chartsNoCharts:"There are no charts available",chartsChartNotSelected:"Select a chart type to configure its options",chartsTabChart:"Chart",chartsTabFields:"Fields",chartsTabCustomize:"Customize",chartsCloseButton:"Close charts configuration",chartsSyncButtonLabel:"Sync chart",chartsSearchPlaceholder:"Search fields",chartsSearchLabel:"Search fields",chartsSearchClear:"Clear search",chartsNoFields:"No fields",chartsFieldBlocked:"This field cannot be added to any section",chartsCategories:"Categories",chartsSeries:"Series",chartsMenuAddToDimensions:e=>`Add to ${e}`,chartsMenuAddToValues:e=>`Add to ${e}`,chartsMenuMoveUp:"Move up",chartsMenuMoveDown:"Move down",chartsMenuMoveToTop:"Move to top",chartsMenuMoveToBottom:"Move to bottom",chartsMenuOptions:"Field options",chartsMenuRemove:"Remove",chartsDragToDimensions:e=>`Drag here to use column as ${e}`,chartsDragToValues:e=>`Drag here to use column as ${e}`,aiAssistantPanelTitle:"AI Assistant",aiAssistantPanelClose:"Close AI Assistant",aiAssistantPanelNewConversation:"New conversation",aiAssistantPanelConversationHistory:"Conversation history",aiAssistantPanelEmptyConversation:"No prompt history",aiAssistantSuggestions:"Suggestions",promptFieldLabel:"Prompt",promptFieldPlaceholder:"Type a prompt…",promptFieldPlaceholderWithRecording:"Type or record a prompt…",promptFieldPlaceholderListening:"Listening for prompt…",promptFieldSpeechRecognitionNotSupported:"Speech recognition is not supported in this browser",promptFieldSend:"Send",promptFieldRecord:"Record",promptFieldStopRecording:"Stop recording",promptRerun:"Run again",promptProcessing:"Processing…",promptAppliedChanges:"Applied changes",promptChangeGroupDescription:e=>`Group by ${e}`,promptChangeAggregationLabel:(e,t)=>`${e} (${t})`,promptChangeAggregationDescription:(e,t)=>`Aggregate ${e} (${t})`,promptChangeFilterLabel:(e,t,n)=>"is any of"===t?`${e} is any of: ${n}`:`${e} ${t} ${n}`,promptChangeFilterDescription:(e,t,n)=>"is any of"===t?`Filter where ${e} is any of: ${n}`:`Filter where ${e} ${t} ${n}`,promptChangeSortDescription:(e,t)=>`Sort by ${e} (${t})`,promptChangePivotEnableLabel:"Pivot",promptChangePivotEnableDescription:"Enable pivot",promptChangePivotColumnsLabel:e=>`Columns (${e})`,promptChangePivotColumnsDescription:(e,t)=>`${e}${t?` (${t})`:""}`,promptChangePivotRowsLabel:e=>`Rows (${e})`,promptChangePivotValuesLabel:e=>`Values (${e})`,promptChangePivotValuesDescription:(e,t)=>`${e} (${t})`,promptChangeChartsLabel:(e,t)=>`Dimensions (${e}), Values (${t})`},fu=["field","type","align","width","height","empty","style","className"],pu="1.3em",hu=[40,80],gu={number:[40,60],string:[40,80],date:[40,60],dateTime:[60,80],singleSelect:[40,80]},mu=function(){const e=(t=12345,()=>{let e=t+=1831565813;return e=Math.imul(e^e>>>15,1|e),e^=e+Math.imul(e^e>>>7,61|e),((e^e>>>14)>>>0)/4294967296});var t;return(t,n)=>t+(n-t)*e()}(),Au=B(function(e){const{field:t,type:n,align:i,width:a,height:l,empty:s=!1,style:c,className:u}=e,d=(0,x.A)(e,fu),f=se(),p=(e=>{const{align:t,classes:n,empty:r}=e,o={root:["cell","cellSkeleton",`cell--text${t?(0,k.A)(t):"Left"}`,r&&"cellEmpty"]};return(0,R.A)(o,D,n)})({classes:f.classes,align:i,empty:s}),h=o.useMemo(()=>{if("boolean"===n||"actions"===n)return{variant:"circular",width:pu,height:pu};const[e,t]=n?gu[n]??hu:hu;return{variant:"text",width:`${Math.round(mu(e,t))}%`,height:"1.2em"}},[n]);return(0,r.jsx)("div",(0,y.A)({"data-field":t,className:(0,E.A)(p.root,u),style:(0,y.A)({height:l,maxWidth:a,minWidth:a},c)},d,{children:!s&&(0,r.jsx)(f.slots.baseSkeleton,(0,y.A)({},h))}))}),bu=["className"],vu=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"IconButtonContainer"})(()=>({display:"flex",visibility:"hidden",width:0})),yu=S(function(e,t){const{className:n}=e,o=(0,x.A)(e,bu),i=se(),a=(e=>{const{classes:t}=e;return(0,R.A)({root:["iconButtonContainer"]},D,t)})(i);return(0,r.jsx)(vu,(0,y.A)({className:(0,E.A)(a.root,n),ownerState:i},o,{ref:t}))});function wu(e){const{counter:t,field:n,onClick:i}=e,a=ot(),l=se(),s=(e=>{const{classes:t}=e;return(0,R.A)({icon:["filterIcon"]},D,t)})((0,y.A)({},e,{classes:l.classes})),c=(0,an.A)(),u=J(a,tt,c),d=(0,an.A)(),f=o.useCallback(e=>{e.preventDefault(),e.stopPropagation();const{open:t,openedPanelValue:r}=et(a);t&&r===nt.filters?a.current.hideFilterPanel():a.current.showFilterPanel(void 0,d,c),i&&i(a.current.getColumnHeaderParams(n),e)},[a,n,i,d,c]);if(!t)return null;const p=(0,r.jsx)(l.slots.baseIconButton,(0,y.A)({id:c,onClick:f,"aria-label":a.current.getLocaleText("columnHeaderFiltersLabel"),size:"small",tabIndex:-1,"aria-haspopup":"menu","aria-expanded":u,"aria-controls":u?d:void 0},l.slotProps?.baseIconButton,{children:(0,r.jsx)(l.slots.columnFilteredIcon,{className:s.icon,fontSize:"small"})}));return(0,r.jsx)(l.slots.baseTooltip,(0,y.A)({title:a.current.getLocaleText("columnHeaderFiltersTooltipActive")(t),enterDelay:1e3},l.slotProps?.baseTooltip,{children:(0,r.jsxs)(yu,{children:[t>1&&(0,r.jsx)(l.slots.baseBadge,{badgeContent:t,color:"default",children:p}),1===t&&p]})}))}const Cu=["direction","index","sortingOrder","disabled","className"],Su=(0,_.Ay)(qt,{name:"MuiDataGrid",slot:"SortButton"})({transition:z.transition(["opacity"],{duration:z.transitions.duration.short,easing:z.transitions.easing.easeInOut})});function xu(e){const{direction:t,index:n,sortingOrder:o,disabled:i,className:a}=e,l=(0,x.A)(e,Cu),s=ot(),c=se(),u=(0,y.A)({},e,{classes:c.classes}),d=(e=>{const{classes:t}=e;return(0,R.A)({root:["sortButton"],icon:["sortIcon"]},D,t)})(u),f=function(e,t,n,o){let i;const a={};return"asc"===t?i=e.columnSortedAscendingIcon:"desc"===t?i=e.columnSortedDescendingIcon:(i=e.columnUnsortedIcon,a.sortingOrder=o),i?(0,r.jsx)(i,(0,y.A)({fontSize:"small",className:n},a)):null}(c.slots,t,d.icon,o);if(!f)return null;const p=(0,r.jsx)(Su,(0,y.A)({as:c.slots.baseIconButton,ownerState:u,"aria-label":s.current.getLocaleText("columnHeaderSortIconLabel"),size:"small",disabled:i,className:(0,E.A)(d.root,a)},c.slotProps?.baseIconButton,l,{children:f}));return(0,r.jsx)(c.slots.baseTooltip,(0,y.A)({title:s.current.getLocaleText("columnHeaderSortIconLabel"),enterDelay:1e3},c.slotProps?.baseTooltip,{children:(0,r.jsxs)("span",{children:[null!=n&&(0,r.jsx)(c.slots.baseBadge,{badgeContent:n,color:"default",overlap:"circular",children:p}),null==n&&p]})}))}function Eu(e){return(0,r.jsx)(yu,{children:(0,r.jsx)(xu,(0,y.A)({},e,{tabIndex:-1}))})}const Iu=o.memo(Eu),ku=["className","selectedRowCount"],Ru=(0,Bi.A)("div",{name:"MuiDataGrid",slot:"SelectedRowCount"})({alignItems:"center",display:"flex",margin:z.spacing(0,2),visibility:"hidden",width:0,height:0,[z.breakpoints.up("sm")]:{visibility:"visible",width:"auto",height:"auto"}}),Mu=S(function(e,t){const{className:n,selectedRowCount:o}=e,i=(0,x.A)(e,ku),a=ot(),l=se(),s=(e=>{const{classes:t}=e;return(0,R.A)({root:["selectedRowCount"]},D,t)})(l),c=a.current.getLocaleText("footerRowSelected")(o);return(0,r.jsx)(Ru,(0,y.A)({className:(0,E.A)(s.root,n),ownerState:l},i,{ref:t,children:c}))}),Pu=["className"],Bu=(0,Bi.A)("div",{name:"MuiDataGrid",slot:"FooterContainer"})({display:"flex",justifyContent:"space-between",alignItems:"center",minHeight:52,borderTop:"1px solid"}),_u=S(function(e,t){const{className:n}=e,o=(0,x.A)(e,Pu),i=se(),a=(e=>{const{classes:t}=e;return(0,R.A)({root:["footerContainer","withBorderColor"]},D,t)})(i);return(0,r.jsx)(Bu,(0,y.A)({className:(0,E.A)(a.root,n),ownerState:i},o,{ref:t}))}),Tu=S(function(e,t){const n=ot(),o=se(),i=J(n,xt),a=J(n,Rl),l=J(n,ai),s=!o.hideFooterSelectedRowCount&&a>0?(0,r.jsx)(Mu,{selectedRowCount:a}):(0,r.jsx)("div",{}),c=o.hideFooterRowCount||o.pagination?null:(0,r.jsx)(o.slots.footerRowCount,(0,y.A)({},o.slotProps?.footerRowCount,{rowCount:i,visibleRowCount:l})),u=o.pagination&&!o.hideFooterPagination&&o.slots.pagination&&(0,r.jsx)(o.slots.pagination,(0,y.A)({},o.slotProps?.pagination));return(0,r.jsxs)(_u,(0,y.A)({},e,{ref:t,children:[s,c,u]}))}),Ou=["className","rowCount","visibleRowCount"],Du=(0,Bi.A)("div",{name:"MuiDataGrid",slot:"RowCount"})({alignItems:"center",display:"flex",margin:z.spacing(0,2)}),Nu=S(function(e,t){const{className:n,rowCount:o,visibleRowCount:i}=e,a=(0,x.A)(e,Ou),l=ot(),s=se(),c=(e=>{const{classes:t}=e;return(0,R.A)({root:["rowCount"]},D,t)})(s);if(0===o)return null;const u=i<o?l.current.getLocaleText("footerTotalVisibleRows")(i,o):o.toLocaleString();return(0,r.jsxs)(Du,(0,y.A)({className:(0,E.A)(c.root,n),ownerState:s},a,{ref:t,children:[l.current.getLocaleText("footerTotalRows")," ",u]}))}),Lu=["className"],Fu=(0,Bi.A)("div",{name:"MuiDataGrid",slot:"Overlay"})({width:"100%",height:"100%",display:"flex",gap:z.spacing(1),flexDirection:"column",alignSelf:"center",alignItems:"center",justifyContent:"center",textAlign:"center",textWrap:"balance",backgroundColor:z.colors.background.backdrop}),Qu=S(function(e,t){const{className:n}=e,o=(0,x.A)(e,Lu),i=se(),a=(e=>{const{classes:t}=e;return(0,R.A)({root:["overlay"]},D,t)})(i);return(0,r.jsx)(Fu,(0,y.A)({className:(0,E.A)(a.root,n),ownerState:i},o,{ref:t}))}),ju=(e,t,n,r,o,i)=>{let a;switch(e){case hr.LEFT:a=r[n];break;case hr.RIGHT:a=o-r[n]-t+i;break;default:a=void 0}return Number.isNaN(a)&&(a=void 0),a},zu=(e,t,n,r,o,i)=>{const a=t===n-1;return!(!i?.startsWith("border")||e!==hr.LEFT||!a)||!!r&&(e===hr.LEFT||(e===hr.RIGHT?!a:!a||o))},$u=(e,t,n,r)=>r?.startsWith("border")?e===hr.RIGHT&&0===t:n&&e===hr.RIGHT&&0===t,Hu=(e,t)=>{if(e)if(t){if(e===hr.LEFT)return"right";if(e===hr.RIGHT)return"left"}else{if(e===hr.LEFT)return"left";if(e===hr.RIGHT)return"right"}};function Gu(e,t,n,r){const o=Hu(n,t);return o&&void 0!==r?(e[o]=r,e):e}const Vu=["skeletonRowsCount","visibleColumns","showFirstRowBorder"],Wu=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"SkeletonLoadingOverlay"})({minWidth:"100%",width:"max-content",height:"100%",overflow:"clip"}),Uu=e=>parseInt(e.getAttribute("data-colindex"),10),qu=S(function(e,t){const n=se(),{slots:i}=n,a=(0,Hr.I)(),l=(e=>{const{classes:t}=e;return(0,R.A)({root:["skeletonLoadingOverlay"]},D,t)})({classes:n.classes}),s=o.useRef(null),c=(0,I.A)(s,t),u=ot(),d=J(u,ut),f=J(u,dt),p=J(u,Ke),h=o.useMemo(()=>p.filter(e=>e<=f).length,[f,p]),{skeletonRowsCount:g,visibleColumns:m,showFirstRowBorder:A}=e,b=(0,x.A)(e,Vu),v=J(u,Ve),w=o.useMemo(()=>v.slice(0,h),[v,h]),C=J(u,qe),S=o.useCallback(e=>-1!==C.left.findIndex(t=>t.field===e)?hr.LEFT:-1!==C.right.findIndex(t=>t.field===e)?hr.RIGHT:void 0,[C.left,C.right]),k=o.useMemo(()=>{const e=[];for(let t=0;t<g;t+=1){const o=[];for(let e=0;e<w.length;e+=1){const l=w[e],s=S(l.field),c=s===hr.LEFT,u=s===hr.RIGHT,f=Hu(s,a),h=f?C[f].length:w.length-C.left.length-C.right.length,g=f?C[f].findIndex(e=>e.field===l.field):e-C.left.length,A=d.hasScrollY?d.scrollbarSize:0,b=Gu({},a,s,ju(s,l.computedWidth,e,p,d.columnsTotalWidth,A)),v=d.columnsTotalWidth<d.viewportOuterSize.width,x=zu(s,g,h,n.showCellVerticalBorder,v,n.pinnedColumnsSectionSeparator),I=$u(s,g,n.showCellVerticalBorder,n.pinnedColumnsSectionSeparator),k=u&&0===g,R=k&&v,M=e===w.length-1&&!k&&v,P=d.viewportOuterSize.width-d.columnsTotalWidth,B=Math.max(0,P),_=(0,r.jsx)(i.skeletonCell,{width:B,empty:!0},`skeleton-filler-column-${t}`);R&&o.push(_),o.push((0,r.jsx)(i.skeletonCell,{field:l.field,type:l.type,align:l.align,width:"var(--width)",height:d.rowHeight,"data-colindex":e,empty:m&&!m.has(l.field),className:(0,E.A)(c&&L["cell--pinnedLeft"],u&&L["cell--pinnedRight"],x&&L["cell--withRightBorder"],I&&L["cell--withLeftBorder"]),style:(0,y.A)({"--width":`${l.computedWidth}px`},b)},`skeleton-column-${t}-${l.field}`)),M&&o.push(_)}e.push((0,r.jsx)("div",{className:(0,E.A)(L.row,L.rowSkeleton,0===t&&!A&&L["row--firstVisible"]),children:o},`skeleton-row-${t}`))}return e},[g,w,S,a,C,d.hasScrollY,d.scrollbarSize,d.columnsTotalWidth,d.viewportOuterSize.width,d.rowHeight,p,n.showCellVerticalBorder,n.pinnedColumnsSectionSeparator,i,m,A]);return $t(u,"columnResize",e=>{const{colDef:t,width:n}=e,r=s.current?.querySelectorAll(`[data-field="${Gs(t.field)}"]`);if(!r)throw new Error("MUI X: Expected skeleton cells to be defined with `data-field` attribute.");const o=w.findIndex(e=>e.field===t.field),i=S(t.field),a=i===hr.LEFT,l=i===hr.RIGHT,c=getComputedStyle(r[0]).getPropertyValue("--width"),u=parseInt(c,10)-n;if(r&&r.forEach(e=>{e.style.setProperty("--width",`${n}px`)}),a){const e=s.current?.querySelectorAll(`.${L["cell--pinnedLeft"]}`);e?.forEach(e=>{Uu(e)>o&&(e.style.left=parseInt(getComputedStyle(e).left,10)-u+"px")})}if(l){const e=s.current?.querySelectorAll(`.${L["cell--pinnedRight"]}`);e?.forEach(e=>{Uu(e)<o&&(e.style.right=`${parseInt(getComputedStyle(e).right,10)+u}px`)})}}),(0,r.jsx)(Wu,(0,y.A)({className:l.root},b,{ref:c,children:k}))}),Yu=S(function(e,t){const n=J(ot(),ut),o=n?.viewportInnerSize.height??0,i=Math.ceil(o/n.rowHeight);return(0,r.jsx)(qu,(0,y.A)({},e,{skeletonRowsCount:i,ref:t}))}),Ku=["variant","noRowsVariant","style"],Ju={"circular-progress":{component:e=>e.slots.baseCircularProgress,style:{}},"linear-progress":{component:e=>e.slots.baseLinearProgress,style:{display:"block"}},skeleton:{component:()=>Yu,style:{display:"block"}}},Xu=S(function(e,t){const{variant:n="linear-progress",noRowsVariant:o="skeleton",style:i}=e,a=(0,x.A)(e,Ku),l=ot(),s=se(),c=J(l,Ct),u=Ju[0===c?o:n],d=u.component(s);return(0,r.jsx)(Qu,(0,y.A)({style:(0,y.A)({},u.style,i)},a,{ref:t,children:(0,r.jsx)(d,{})}))}),Zu=S(function(e,t){const n=ot().current.getLocaleText("noRowsLabel");return(0,r.jsx)(Qu,(0,y.A)({},e,{ref:t,children:n}))}),ed=S(function(e,t){const n=se(),o=ot(),i=J(o,je),a=!n.disableColumnSelector&&i.length>0;return(0,r.jsxs)(Qu,(0,y.A)({},e,{ref:t,children:[o.current.getLocaleText("noColumnsOverlayLabel"),a&&(0,r.jsx)(n.slots.baseButton,(0,y.A)({size:"small"},n.slotProps?.baseButton,{onClick:()=>{o.current.showPreferences(nt.columns)},children:o.current.getLocaleText("noColumnsOverlayManageColumns")}))]}))}),td=(0,_.Ay)(qt,{slot:"internal"})({maxHeight:"calc(100% + 1px)",flexGrow:1}),nd=["className"],rd=(0,Bi.A)("div",{name:"MuiDataGrid",slot:"PanelContent"})({display:"flex",flexDirection:"column",overflow:"auto",flex:"1 1",maxHeight:400,padding:z.spacing(2.5,1.5,2,1),gap:z.spacing(2.5)});function od(e){const{className:t}=e,n=(0,x.A)(e,nd),o=se(),i=(e=>{const{classes:t}=e;return(0,R.A)({root:["panelContent"]},D,t)})(o);return(0,r.jsx)(rd,(0,y.A)({className:(0,E.A)(i.root,t),ownerState:o},n))}const id=["className"],ad=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"PanelFooter"})({padding:z.spacing(1),display:"flex",justifyContent:"space-between",borderTop:`1px solid ${z.colors.border.base}`});function ld(e){const{className:t}=e,n=(0,x.A)(e,id),o=se(),i=(e=>{const{classes:t}=e;return(0,R.A)({root:["panelFooter"]},D,t)})(o);return(0,r.jsx)(ad,(0,y.A)({className:(0,E.A)(i.root,t),ownerState:o},n))}const sd=["className"],cd=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"PanelWrapper"})({display:"flex",flexDirection:"column",flex:1,"&:focus":{outline:0}}),ud=S(function(e,t){const{className:n}=e,o=(0,x.A)(e,sd),i=se(),a=(e=>{const{classes:t}=e;return(0,R.A)({root:["panelWrapper"]},D,t)})(i);return(0,r.jsx)(cd,(0,y.A)({tabIndex:-1,className:(0,E.A)(a.root,n),ownerState:i},o,{ref:t}))}),dd=["item","hasMultipleFilters","deleteFilter","applyFilterChanges","showMultiFilterOperators","disableMultiFilterOperator","applyMultiFilterOperatorChanges","focusElementRef","logicOperators","columnsSort","filterColumns","deleteIconProps","logicOperatorInputProps","operatorInputProps","columnInputProps","valueInputProps","readOnly","children"],fd=["InputComponentProps"],pd=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"FilterForm"})({display:"flex",gap:z.spacing(1.5)}),hd=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"FilterFormDeleteIcon"})({flexShrink:0,display:"flex",justifyContent:"center",alignItems:"center"}),gd=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"FilterFormLogicOperatorInput"})({minWidth:75,justifyContent:"end"}),md=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"FilterFormColumnInput"})({width:150}),Ad=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"FilterFormOperatorInput"})({width:150}),bd=(0,_.Ay)("div",{name:"MuiDataGrid",slot:"FilterFormValueInput"})({width:190}),vd=e=>e.headerName||e.field,yd=new Intl.Collator,wd=S(function(e,t){const{item:n,hasMultipleFilters:i,deleteFilter:a,applyFilterChanges:l,showMultiFilterOperators:s,disableMultiFilterOperator:c,applyMultiFilterOperatorChanges:u,focusElementRef:d,logicOperators:f=[An.And,An.Or],columnsSort:p,filterColumns:h,deleteIconProps:g={},logicOperatorInputProps:m={},operatorInputProps:A={},columnInputProps:b={},valueInputProps:v={},readOnly:w}=e,C=(0,x.A)(e,dd),S=ot(),I=J(S,ze),M=J(S,Je),P=J(S,Ko),B=(0,an.A)(),_=(0,an.A)(),T=(0,an.A)(),O=(0,an.A)(),N=se(),L=(e=>{const{classes:t}=e;return(0,R.A)({root:["filterForm"],deleteIcon:["filterFormDeleteIcon"],logicOperatorInput:["filterFormLogicOperatorInput"],columnInput:["filterFormColumnInput"],operatorInput:["filterFormOperatorInput"],valueInput:["filterFormValueInput"]},D,t)})(N),F=o.useRef(null),Q=o.useRef(null),j=P.logicOperator??An.And,z=i&&f.length>0,$=(N.slotProps?.baseSelect||{}).native??!1,H=N.slotProps?.baseSelectOption||{},{InputComponentProps:G}=v,V=(0,x.A)(v,fd),W=J(S,fi),U=J(S,hi),{filteredColumns:q,selectedField:Y}=o.useMemo(()=>{let e=n.field;const t=!1===I[n.field].filterable?I[n.field]:null;if(t)return{filteredColumns:[t],selectedField:e};if(W)return{filteredColumns:M.filter(e=>void 0!==U.get(e.field)),selectedField:e};if(void 0===h||"function"!=typeof h)return{filteredColumns:M,selectedField:e};const r=h({field:n.field,columns:M,currentFilters:P?.items||[]});return{filteredColumns:M.filter(t=>{const o=r.includes(t.field);return t.field!==n.field||o||(e=void 0),o}),selectedField:e}},[n.field,I,W,h,M,P?.items,U]),K=o.useMemo(()=>{switch(p){case"asc":return q.sort((e,t)=>yd.compare(vd(e),vd(t)));case"desc":return q.sort((e,t)=>-yd.compare(vd(e),vd(t)));default:return q}},[q,p]),X=n.field?S.current.getColumn(n.field):null,Z=o.useMemo(()=>n.operator&&X?X.filterOperators?.find(e=>e.value===n.operator):null,[n,X]),ee=o.useCallback(e=>{const t=e.target.value,r=S.current.getColumn(t);if(r.field===X.field)return;const o=r.filterOperators.find(e=>e.value===n.operator)||r.filterOperators[0];let i=o.InputComponent&&o.InputComponent===Z?.InputComponent&&r.type===X.type?n.value:void 0;if("singleSelect"===r.type&&void 0!==i){const e=r,t=Tr(e);Array.isArray(i)?i=i.filter(n=>void 0!==Or(n,t,e?.getOptionValue)):void 0===Or(n.value,t,e?.getOptionValue)&&(i=void 0)}l((0,y.A)({},n,{field:t,operator:o.value,value:i}))},[S,l,n,X,Z]),te=o.useCallback(e=>{const t=e.target.value,r=X?.filterOperators.find(e=>e.value===t),o=!r?.InputComponent||r?.InputComponent!==Z?.InputComponent;l((0,y.A)({},n,{operator:t,value:o?void 0:n.value}))},[l,n,X,Z]),ne=o.useCallback(e=>{const t=e.target.value===An.And.toString()?An.And:An.Or;u(t)},[u]);return o.useImperativeHandle(d,()=>({focus:()=>{Z?.InputComponent?F?.current?.focus():Q.current.focus()}}),[Z]),(0,r.jsxs)(pd,(0,y.A)({className:L.root,"data-id":n.id,ownerState:N},C,{ref:t,children:[(0,r.jsx)(hd,(0,y.A)({},g,{className:(0,E.A)(L.deleteIcon,g.className),ownerState:N,children:(0,r.jsx)(N.slots.baseIconButton,(0,y.A)({"aria-label":S.current.getLocaleText("filterPanelDeleteIconLabel"),title:S.current.getLocaleText("filterPanelDeleteIconLabel"),onClick:()=>{a(n)},size:"small",disabled:w},N.slotProps?.baseIconButton,{children:(0,r.jsx)(N.slots.filterPanelDeleteIcon,{fontSize:"small"})}))})),(0,r.jsx)(gd,(0,y.A)({as:N.slots.baseSelect,sx:[z?{display:"flex"}:{display:"none"},s?{visibility:"visible"}:{visibility:"hidden"},m.sx],className:(0,E.A)(L.logicOperatorInput,m.className),ownerState:N},m,{size:"small",slotProps:{htmlInput:{"aria-label":S.current.getLocaleText("filterPanelLogicOperator")}},value:j??"",onChange:ne,disabled:!!c||1===f.length,native:$},N.slotProps?.baseSelect,{children:f.map(e=>(0,o.createElement)(N.slots.baseSelectOption,(0,y.A)({},H,{native:$,key:e.toString(),value:e.toString()}),S.current.getLocaleText((e=>{switch(e){case An.And:return"filterPanelOperatorAnd";case An.Or:return"filterPanelOperatorOr";default:throw new Error("MUI X: Invalid `logicOperator` property in the `GridFilterPanel`.")}})(e))))})),(0,r.jsx)(md,(0,y.A)({as:N.slots.baseSelect},b,{className:(0,E.A)(L.columnInput,b.className),ownerState:N,size:"small",labelId:_,id:B,label:S.current.getLocaleText("filterPanelColumns"),value:Y??"",onChange:ee,native:$,disabled:w},N.slotProps?.baseSelect,{children:K.map(e=>(0,o.createElement)(N.slots.baseSelectOption,(0,y.A)({},H,{native:$,key:e.field,value:e.field}),vd(e)))})),(0,r.jsx)(Ad,(0,y.A)({as:N.slots.baseSelect,size:"small"},A,{className:(0,E.A)(L.operatorInput,A.className),ownerState:N,labelId:O,label:S.current.getLocaleText("filterPanelOperator"),id:T,value:n.operator,onChange:te,native:$,inputRef:Q,disabled:w},N.slotProps?.baseSelect,{children:X?.filterOperators?.map(e=>(0,o.createElement)(N.slots.baseSelectOption,(0,y.A)({},H,{native:$,key:e.value,value:e.value}),e.label||S.current.getLocaleText(`filterOperator${(0,k.A)(e.value)}`)))})),(0,r.jsx)(bd,(0,y.A)({},V,{className:(0,E.A)(L.valueInput,V.className),ownerState:N,children:Z?.InputComponent?(0,r.jsx)(Z.InputComponent,(0,y.A)({apiRef:S,item:n,applyValue:l,focusElementRef:F,disabled:w,slotProps:{root:{size:"small"}}},Z.InputComponentProps,G),n.field):null}))]}))}),Cd=["logicOperators","columnsSort","filterFormProps","getColumnForNewFilter","children","disableAddFilterButton","disableRemoveAllButton"],Sd=e=>({field:e.field,operator:e.filterOperators[0].value,id:Math.round(1e5*Math.random())}),xd=S(function(e,t){const n=ot(),i=se(),a=J(n,Ko),l=J(n,Je),s=J(n,Xe),c=o.useRef(null),u=o.useRef(null),{logicOperators:d=[An.And,An.Or],columnsSort:f,filterFormProps:p,getColumnForNewFilter:h,disableAddFilterButton:g=!1,disableRemoveAllButton:m=!1}=e,A=(0,x.A)(e,Cd),b=n.current.upsertFilterItem,v=o.useCallback(e=>{n.current.setFilterLogicOperator(e)},[n]),w=o.useCallback(()=>{let e;if(h&&"function"==typeof h){const t=h({currentFilters:a?.items||[],columns:l});if(null===t)return null;e=l.find(({field:e})=>e===t)}else e=l.find(e=>e.filterOperators?.length);return e?Sd(e):null},[a?.items,l,h]),C=o.useCallback(()=>{if(void 0===h||"function"!=typeof h)return w();const e=a.items.length?a.items:[w()].filter(Boolean),t=h({currentFilters:e,columns:l});if(null===t)return null;const n=l.find(({field:e})=>e===t);return n?Sd(n):null},[a.items,l,h,w]),S=o.useMemo(()=>a.items.length?a.items:(u.current||(u.current=w()),u.current?[u.current]:[]),[a.items,w]),E=S.length>1,{readOnlyFilters:I,validFilters:k}=o.useMemo(()=>S.reduce((e,t)=>(s[t.field]?e.validFilters.push(t):e.readOnlyFilters.push(t),e),{readOnlyFilters:[],validFilters:[]}),[S,s]),R=o.useCallback(()=>{const e=C();e&&n.current.upsertFilterItems([...S,e])},[n,C,S]),M=o.useCallback(e=>{const t=1===k.length;n.current.deleteFilterItem(e),t&&n.current.hideFilterPanel()},[n,k.length]),P=o.useCallback(()=>1===k.length&&void 0===k[0].value?(n.current.deleteFilterItem(k[0]),n.current.hideFilterPanel()):n.current.setFilterModel((0,y.A)({},a,{items:I}),"removeAllFilterItems"),[n,I,a,k]);return o.useEffect(()=>{d.length>0&&a.logicOperator&&!d.includes(a.logicOperator)&&v(d[0])},[d,v,a.logicOperator]),o.useEffect(()=>{k.length>0&&c.current.focus()},[k.length]),(0,r.jsxs)(ud,(0,y.A)({},A,{ref:t,children:[(0,r.jsxs)(od,{children:[I.map((e,t)=>(0,r.jsx)(wd,(0,y.A)({item:e,applyFilterChanges:b,deleteFilter:M,hasMultipleFilters:E,showMultiFilterOperators:t>0,disableMultiFilterOperator:1!==t,applyMultiFilterOperatorChanges:v,focusElementRef:null,readOnly:!0,logicOperators:d,columnsSort:f},p),null==e.id?t:e.id)),k.map((e,t)=>(0,r.jsx)(wd,(0,y.A)({item:e,applyFilterChanges:b,deleteFilter:M,hasMultipleFilters:E,showMultiFilterOperators:I.length+t>0,disableMultiFilterOperator:I.length+t!==1,applyMultiFilterOperatorChanges:v,focusElementRef:t===k.length-1?c:null,logicOperators:d,columnsSort:f},p),null==e.id?t+I.length:e.id))]}),i.disableMultipleColumnsFiltering||g&&m?null:(0,r.jsxs)(ld,{children:[g?(0,r.jsx)("span",{}):(0,r.jsx)(i.slots.baseButton,(0,y.A)({onClick:R,startIcon:(0,r.jsx)(i.slots.filterPanelAddIcon,{})},i.slotProps?.baseButton,{children:n.current.getLocaleText("filterPanelAddFilter")})),!m&&k.length>0?(0,r.jsx)(i.slots.baseButton,(0,y.A)({onClick:P,startIcon:(0,r.jsx)(i.slots.filterPanelRemoveAllIcon,{})},i.slotProps?.baseButton,{children:n.current.getLocaleText("filterPanelRemoveAll")})):null]})]}))});var Ed=n(8751);const Id=(e,t)=>(e.headerName||e.field).toLowerCase().indexOf(t)>-1;var kd=n(553);const Rd=["children"],Md=(0,kd.i7)({from:{opacity:0},to:{opacity:1}}),Pd=(0,kd.i7)({"from, to":{"--scrollable":'" "'}}),Bd=(0,Bi.A)("div",{name:"MuiDataGrid",slot:"ShadowScrollArea"})`
|
|
3
3
|
flex: 1;
|
|
4
4
|
display: flex;
|
|
5
5
|
flex-direction: column;
|