@bygd/nc-report-ui 0.1.23 → 0.1.24
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.
|
@@ -210,7 +210,7 @@ var _BYGD_NC_REPORT_UI=function(){"use strict";function e(e,t){return t.forEach(
|
|
|
210
210
|
&::after {
|
|
211
211
|
animation: ${wk} 2s linear 0.5s infinite;
|
|
212
212
|
}
|
|
213
|
-
`:null,Ck=pg("span",{name:"MuiSkeleton",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[n.variant],!1!==n.animation&&t[n.animation],n.hasChildren&&t.withChildren,n.hasChildren&&!n.width&&t.fitContent,n.hasChildren&&!n.height&&t.heightAuto]}})(vg(({theme:e})=>{const t=(n=e.shape.borderRadius,String(n).match(/[\d.\-+]*\s*(.*)/)[1]||""||"px");var n;const r=function(e){return parseFloat(e)}(e.shape.borderRadius);return{display:"block",backgroundColor:e.vars?e.vars.palette.Skeleton.bg:e.alpha(e.palette.text.primary,"light"===e.palette.mode?.11:.13),height:"1.2em",variants:[{props:{variant:"text"},style:{marginTop:0,marginBottom:0,height:"auto",transformOrigin:"0 55%",transform:"scale(1, 0.60)",borderRadius:`${r}${t}/${Math.round(r/.6*10)/10}${t}`,"&:empty:before":{content:'"\\00a0"'}}},{props:{variant:"circular"},style:{borderRadius:"50%"}},{props:{variant:"rounded"},style:{borderRadius:(e.vars||e).shape.borderRadius}},{props:({ownerState:e})=>e.hasChildren,style:{"& > *":{visibility:"hidden"}}},{props:({ownerState:e})=>e.hasChildren&&!e.width,style:{maxWidth:"fit-content"}},{props:({ownerState:e})=>e.hasChildren&&!e.height,style:{height:"auto"}},{props:{animation:"pulse"},style:xk||{animation:`${yk} 2s ease-in-out 0.5s infinite`}},{props:{animation:"wave"},style:{position:"relative",overflow:"hidden",WebkitMaskImage:"-webkit-radial-gradient(white, black)","&::after":{background:`linear-gradient(\n 90deg,\n transparent,\n ${(e.vars||e).palette.action.hover},\n transparent\n )`,content:'""',position:"absolute",transform:"translateX(-100%)",bottom:0,left:0,right:0,top:0}}},{props:{animation:"wave"},style:Sk||{"&::after":{animation:`${wk} 2s linear 0.5s infinite`}}}]}})),kk=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiSkeleton"}),{animation:r="pulse",className:o,component:i="span",height:a,style:l,variant:s="text",width:c,...u}=n,d={...n,animation:r,component:i,variant:s,hasChildren:Boolean(u.children)},p=(e=>{const{classes:t,variant:n,animation:r,hasChildren:o,width:i,height:a}=e;return wm({root:["root",n,r,o&&"withChildren",o&&!i&&"fitContent",o&&!a&&"heightAuto"]},bk,t)})(d);return Xp.jsx(Ck,{as:i,ref:t,className:mg(p.root,o),ownerState:d,...u,style:{width:c,height:a,...l}})});function Ek(e){return Ph("MuiSnackbarContent",e)}Mh("MuiSnackbarContent",["root","message","action"]);const Rk=pg(qg,{name:"MuiSnackbarContent",slot:"Root"})(vg(({theme:e})=>{const t="light"===e.palette.mode?.8:.98;return{...e.typography.body2,color:e.vars?e.vars.palette.SnackbarContent.color:e.palette.getContrastText(lm(e.palette.background.default,t)),backgroundColor:e.vars?e.vars.palette.SnackbarContent.bg:lm(e.palette.background.default,t),display:"flex",alignItems:"center",flexWrap:"wrap",padding:"6px 16px",flexGrow:1,[e.breakpoints.up("sm")]:{flexGrow:"initial",minWidth:288}}})),Pk=pg("div",{name:"MuiSnackbarContent",slot:"Message"})({padding:"8px 0"}),Mk=pg("div",{name:"MuiSnackbarContent",slot:"Action"})({display:"flex",alignItems:"center",marginLeft:"auto",paddingLeft:16,marginRight:-8}),Tk=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiSnackbarContent"}),{action:r,className:o,message:i,role:a="alert",...l}=n,s=n,c=(e=>{const{classes:t}=e;return wm({root:["root"],action:["action"],message:["message"]},Ek,t)})(s);return Xp.jsxs(Rk,{role:a,elevation:6,className:mg(c.root,o),ownerState:s,ref:t,...l,children:[Xp.jsx(Pk,{className:c.message,ownerState:s,children:i}),r?Xp.jsx(Mk,{className:c.action,ownerState:s,children:r}):null]})});function Ik(e){return Ph("MuiSnackbar",e)}Mh("MuiSnackbar",["root","anchorOriginTopCenter","anchorOriginBottomCenter","anchorOriginTopRight","anchorOriginBottomRight","anchorOriginTopLeft","anchorOriginBottomLeft"]);const Ok=pg("div",{name:"MuiSnackbar",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[`anchorOrigin${xf(n.anchorOrigin.vertical)}${xf(n.anchorOrigin.horizontal)}`]]}})(vg(({theme:e})=>({zIndex:(e.vars||e).zIndex.snackbar,position:"fixed",display:"flex",left:8,right:8,justifyContent:"center",alignItems:"center",variants:[{props:({ownerState:e})=>"top"===e.anchorOrigin.vertical,style:{top:8,[e.breakpoints.up("sm")]:{top:24}}},{props:({ownerState:e})=>"top"!==e.anchorOrigin.vertical,style:{bottom:8,[e.breakpoints.up("sm")]:{bottom:24}}},{props:({ownerState:e})=>"left"===e.anchorOrigin.horizontal,style:{justifyContent:"flex-start",[e.breakpoints.up("sm")]:{left:24,right:"auto"}}},{props:({ownerState:e})=>"right"===e.anchorOrigin.horizontal,style:{justifyContent:"flex-end",[e.breakpoints.up("sm")]:{right:24,left:"auto"}}},{props:({ownerState:e})=>"center"===e.anchorOrigin.horizontal,style:{[e.breakpoints.up("sm")]:{left:"50%",right:"auto",transform:"translateX(-50%)"}}}]}))),Dk=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiSnackbar"}),r=sg(),o={enter:r.transitions.duration.enteringScreen,exit:r.transitions.duration.leavingScreen},{action:i,anchorOrigin:{vertical:a,horizontal:l}={vertical:"bottom",horizontal:"left"},autoHideDuration:c=null,children:u,className:d,ClickAwayListenerProps:p,ContentProps:f,disableWindowBlurListener:h=!1,message:m,onBlur:g,onClose:v,onFocus:b,onMouseEnter:y,onMouseLeave:w,open:x,resumeHideDuration:S,slots:C={},slotProps:k={},TransitionComponent:E,transitionDuration:R=o,TransitionProps:{onEnter:P,onExited:M,...T}={},...I}=n,O={...n,anchorOrigin:{vertical:a,horizontal:l},autoHideDuration:c,disableWindowBlurListener:h,TransitionComponent:E,transitionDuration:R},D=(e=>{const{classes:t,anchorOrigin:n}=e;return wm({root:["root",`anchorOrigin${xf(n.vertical)}${xf(n.horizontal)}`]},Ik,t)})(O),{getRootProps:F,onClickAway:L}=function(e={}){const{autoHideDuration:t=null,disableWindowBlurListener:n=!1,onClose:r,open:o,resumeHideDuration:i}=e,a=Ng();s.useEffect(()=>{if(o)return document.addEventListener("keydown",e),()=>{document.removeEventListener("keydown",e)};function e(e){e.defaultPrevented||"Escape"===e.key&&r?.(e,"escapeKeyDown")}},[o,r]);const l=Mg((e,t)=>{r?.(e,t)}),c=Mg(e=>{r&&null!=e&&a.start(e,()=>{l(null,"timeout")})});s.useEffect(()=>(o&&c(t),a.clear),[o,t,c,a]);const u=a.clear,d=s.useCallback(()=>{null!=t&&c(null!=i?i:.5*t)},[t,i,c]),p=e=>t=>{const n=e.onFocus;n?.(t),u()},f=e=>t=>{const n=e.onMouseEnter;n?.(t),u()},h=e=>t=>{const n=e.onMouseLeave;n?.(t),d()};return s.useEffect(()=>{if(!n&&o)return window.addEventListener("focus",d),window.addEventListener("blur",u),()=>{window.removeEventListener("focus",d),window.removeEventListener("blur",u)}},[n,o,d,u]),{getRootProps:(t={})=>{const n={...Hg(e),...Hg(t)};return{role:"presentation",...t,...n,onBlur:(r=n,e=>{const t=r.onBlur;t?.(e),d()}),onFocus:p(n),onMouseEnter:f(n),onMouseLeave:h(n)};var r},onClickAway:e=>{r?.(e,"clickaway")}}}(O),[A,N]=s.useState(!0),$={slots:{transition:E,...C},slotProps:{content:f,clickAwayListener:p,transition:T,...k}},[z,j]=Ug("root",{ref:t,className:[D.root,d],elementType:Ok,getSlotProps:F,externalForwardedProps:{...$,...I},ownerState:O}),[B,{ownerState:_,...H}]=Ug("clickAwayListener",{elementType:px,externalForwardedProps:$,getSlotProps:e=>({onClickAway:(...t)=>{const n=t[0];e.onClickAway?.(...t),n?.defaultMuiPrevented||L(...t)}}),ownerState:O}),[V,W]=Ug("content",{elementType:Tk,shouldForwardComponentProp:!0,externalForwardedProps:$,additionalProps:{message:m,action:i},ownerState:O}),[U,G]=Ug("transition",{elementType:PS,externalForwardedProps:$,getSlotProps:e=>({onEnter:(...t)=>{e.onEnter?.(...t),((e,t)=>{N(!1),P&&P(e,t)})(...t)},onExited:(...t)=>{e.onExited?.(...t),(e=>{N(!0),M&&M(e)})(...t)}}),additionalProps:{appear:!0,in:x,timeout:R,direction:"top"===a?"down":"up"},ownerState:O});return!x&&A?null:Xp.jsx(B,{...H,...C.clickAwayListener&&{ownerState:_},children:Xp.jsx(z,{...j,children:Xp.jsx(U,{...G,children:u||Xp.jsx(V,{...W})})})})});function Fk(e){return Ph("MuiTooltip",e)}const Lk=Mh("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]);const Ak=pg(My,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.popper,!n.disableInteractive&&t.popperInteractive,n.arrow&&t.popperArrow,!n.open&&t.popperClose]}})(vg(({theme:e})=>({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none",variants:[{props:({ownerState:e})=>!e.disableInteractive,style:{pointerEvents:"auto"}},{props:({open:e})=>!e,style:{pointerEvents:"none"}},{props:({ownerState:e})=>e.arrow,style:{[`&[data-popper-placement*="bottom"] .${Lk.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${Lk.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${Lk.arrow}`]:{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}},[`&[data-popper-placement*="left"] .${Lk.arrow}`]:{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}}}},{props:({ownerState:e})=>e.arrow&&!e.isRtl,style:{[`&[data-popper-placement*="right"] .${Lk.arrow}`]:{left:0,marginLeft:"-0.71em"}}},{props:({ownerState:e})=>e.arrow&&!!e.isRtl,style:{[`&[data-popper-placement*="right"] .${Lk.arrow}`]:{right:0,marginRight:"-0.71em"}}},{props:({ownerState:e})=>e.arrow&&!e.isRtl,style:{[`&[data-popper-placement*="left"] .${Lk.arrow}`]:{right:0,marginRight:"-0.71em"}}},{props:({ownerState:e})=>e.arrow&&!!e.isRtl,style:{[`&[data-popper-placement*="left"] .${Lk.arrow}`]:{left:0,marginLeft:"-0.71em"}}}]}))),Nk=pg("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.tooltip,n.touch&&t.touch,n.arrow&&t.tooltipArrow,t[`tooltipPlacement${xf(n.placement.split("-")[0])}`]]}})(vg(({theme:e})=>{return{backgroundColor:e.vars?e.vars.palette.Tooltip.bg:e.alpha(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium,[`.${Lk.popper}[data-popper-placement*="left"] &`]:{transformOrigin:"right center"},[`.${Lk.popper}[data-popper-placement*="right"] &`]:{transformOrigin:"left center"},[`.${Lk.popper}[data-popper-placement*="top"] &`]:{transformOrigin:"center bottom",marginBottom:"14px"},[`.${Lk.popper}[data-popper-placement*="bottom"] &`]:{transformOrigin:"center top",marginTop:"14px"},variants:[{props:({ownerState:e})=>e.arrow,style:{position:"relative",margin:0}},{props:({ownerState:e})=>e.touch,style:{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:(t=16/14,Math.round(1e5*t)/1e5)+"em",fontWeight:e.typography.fontWeightRegular}},{props:({ownerState:e})=>!e.isRtl,style:{[`.${Lk.popper}[data-popper-placement*="left"] &`]:{marginRight:"14px"},[`.${Lk.popper}[data-popper-placement*="right"] &`]:{marginLeft:"14px"}}},{props:({ownerState:e})=>!e.isRtl&&e.touch,style:{[`.${Lk.popper}[data-popper-placement*="left"] &`]:{marginRight:"24px"},[`.${Lk.popper}[data-popper-placement*="right"] &`]:{marginLeft:"24px"}}},{props:({ownerState:e})=>!!e.isRtl,style:{[`.${Lk.popper}[data-popper-placement*="left"] &`]:{marginLeft:"14px"},[`.${Lk.popper}[data-popper-placement*="right"] &`]:{marginRight:"14px"}}},{props:({ownerState:e})=>!!e.isRtl&&e.touch,style:{[`.${Lk.popper}[data-popper-placement*="left"] &`]:{marginLeft:"24px"},[`.${Lk.popper}[data-popper-placement*="right"] &`]:{marginRight:"24px"}}},{props:({ownerState:e})=>e.touch,style:{[`.${Lk.popper}[data-popper-placement*="top"] &`]:{marginBottom:"24px"}}},{props:({ownerState:e})=>e.touch,style:{[`.${Lk.popper}[data-popper-placement*="bottom"] &`]:{marginTop:"24px"}}}]};var t})),$k=pg("span",{name:"MuiTooltip",slot:"Arrow"})(vg(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:e.alpha(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}})));let zk=!1;const jk=new Ag;let Bk={x:0,y:0};function _k(e,t){return(n,...r)=>{t&&t(n,...r),e(n,...r)}}const Hk=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiTooltip"}),{arrow:r=!1,children:o,classes:i,components:a={},componentsProps:l={},describeChild:c=!1,disableFocusListener:u=!1,disableHoverListener:d=!1,disableInteractive:p=!1,disableTouchListener:f=!1,enterDelay:h=100,enterNextDelay:m=0,enterTouchDelay:g=700,followCursor:v=!1,id:b,leaveDelay:y=0,leaveTouchDelay:w=1500,onClose:x,onOpen:S,open:C,placement:k="bottom",PopperComponent:E,PopperProps:R={},slotProps:P={},slots:M={},title:T,TransitionComponent:I,TransitionProps:O,...D}=n,F=s.isValidElement(o)?o:Xp.jsx("span",{children:o}),L=sg(),A=um(),[N,$]=s.useState(),[z,j]=s.useState(null),B=s.useRef(!1),_=p||v,H=Ng(),V=Ng(),W=Ng(),U=Ng(),[G,K]=Pg({controlled:C,default:!1,name:"Tooltip",state:"open"});let q=G;const Y=mm(b),X=s.useRef(),Q=Mg(()=>{void 0!==X.current&&(document.body.style.WebkitUserSelect=X.current,X.current=void 0),U.clear()});s.useEffect(()=>Q,[Q]);const Z=e=>{jk.clear(),zk=!0,K(!0),S&&!q&&S(e)},J=Mg(e=>{jk.start(800+y,()=>{zk=!1}),K(!1),x&&q&&x(e),H.start(L.transitions.duration.shortest,()=>{B.current=!1})}),ee=e=>{B.current&&"touchstart"!==e.type||(N&&N.removeAttribute("title"),V.clear(),W.clear(),h||zk&&m?V.start(zk?m:h,()=>{Z(e)}):Z(e))},te=e=>{V.clear(),W.start(y,()=>{J(e)})},[,ne]=s.useState(!1),re=e=>{Xg(e.target)||(ne(!1),te(e))},oe=e=>{N||$(e.currentTarget),Xg(e.target)&&(ne(!0),ee(e))},ie=e=>{B.current=!0;const t=F.props;t.onTouchStart&&t.onTouchStart(e)},ae=e=>{ie(e),W.clear(),H.clear(),Q(),X.current=document.body.style.WebkitUserSelect,document.body.style.WebkitUserSelect="none",U.start(g,()=>{document.body.style.WebkitUserSelect=X.current,ee(e)})},le=e=>{F.props.onTouchEnd&&F.props.onTouchEnd(e),Q(),W.start(w,()=>{J(e)})};s.useEffect(()=>{if(q)return document.addEventListener("keydown",e),()=>{document.removeEventListener("keydown",e)};function e(e){"Escape"===e.key&&J(e)}},[J,q]);const se=Tg(wy(F),$,t);T||0===T||(q=!1);const ce=s.useRef(),ue={},de="string"==typeof T;c?(ue.title=q||!de||d?null:T,ue["aria-describedby"]=q?Y:null):(ue["aria-label"]=de?T:null,ue["aria-labelledby"]=q&&!de?Y:null);const pe={...ue,...D,...F.props,className:mg(D.className,F.props.className),onTouchStart:ie,ref:se,...v?{onMouseMove:e=>{const t=F.props;t.onMouseMove&&t.onMouseMove(e),Bk={x:e.clientX,y:e.clientY},ce.current&&ce.current.update()}}:{}},fe={};f||(pe.onTouchStart=ae,pe.onTouchEnd=le),d||(pe.onMouseOver=_k(ee,pe.onMouseOver),pe.onMouseLeave=_k(te,pe.onMouseLeave),_||(fe.onMouseOver=ee,fe.onMouseLeave=te)),u||(pe.onFocus=_k(oe,pe.onFocus),pe.onBlur=_k(re,pe.onBlur),_||(fe.onFocus=oe,fe.onBlur=re));const he={...n,isRtl:A,arrow:r,disableInteractive:_,placement:k,PopperComponentProp:E,touch:B.current},me="function"==typeof P.popper?P.popper(he):P.popper,ge=s.useMemo(()=>{let e=[{name:"arrow",enabled:Boolean(z),options:{element:z,padding:4}}];return R.popperOptions?.modifiers&&(e=e.concat(R.popperOptions.modifiers)),me?.popperOptions?.modifiers&&(e=e.concat(me.popperOptions.modifiers)),{...R.popperOptions,...me?.popperOptions,modifiers:e}},[z,R.popperOptions,me?.popperOptions]),ve=(e=>{const{classes:t,disableInteractive:n,arrow:r,touch:o,placement:i}=e;return wm({popper:["popper",!n&&"popperInteractive",r&&"popperArrow"],tooltip:["tooltip",r&&"tooltipArrow",o&&"touch",`tooltipPlacement${xf(i.split("-")[0])}`],arrow:["arrow"]},Fk,t)})(he),be="function"==typeof P.transition?P.transition(he):P.transition,ye={slots:{popper:a.Popper,transition:a.Transition??I,tooltip:a.Tooltip,arrow:a.Arrow,...M},slotProps:{arrow:P.arrow??l.arrow,popper:{...R,...me??l.popper},tooltip:P.tooltip??l.tooltip,transition:{...O,...be??l.transition}}},[we,xe]=Ug("popper",{elementType:Ak,externalForwardedProps:ye,ownerState:he,className:mg(ve.popper,R?.className)}),[Se,Ce]=Ug("transition",{elementType:PS,externalForwardedProps:ye,ownerState:he}),[ke,Ee]=Ug("tooltip",{elementType:Nk,className:ve.tooltip,externalForwardedProps:ye,ownerState:he}),[Re,Pe]=Ug("arrow",{elementType:$k,className:ve.arrow,externalForwardedProps:ye,ownerState:he,ref:j});return Xp.jsxs(s.Fragment,{children:[s.cloneElement(F,pe),Xp.jsx(we,{as:E??My,placement:k,anchorEl:v?{getBoundingClientRect:()=>({top:Bk.y,left:Bk.x,right:Bk.x,bottom:Bk.y,width:0,height:0})}:N,popperRef:ce,open:!!N&&q,id:Y,transition:!0,...fe,...xe,popperOptions:ge,children:({TransitionProps:e})=>Xp.jsx(Se,{timeout:L.transitions.duration.shorter,...e,...Ce,children:Xp.jsxs(ke,{...Ee,children:[T,r?Xp.jsx(Re,{...Pe}):null]})})})]})});function Vk(e){return Ph("MuiSwitch",e)}const Wk=Mh("MuiSwitch",["root","edgeStart","edgeEnd","switchBase","colorPrimary","colorSecondary","sizeSmall","sizeMedium","checked","disabled","input","thumb","track"]),Uk=pg("span",{name:"MuiSwitch",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.edge&&t[`edge${xf(n.edge)}`],t[`size${xf(n.size)}`]]}})({display:"inline-flex",width:58,height:38,overflow:"hidden",padding:12,boxSizing:"border-box",position:"relative",flexShrink:0,zIndex:0,verticalAlign:"middle","@media print":{colorAdjust:"exact"},variants:[{props:{edge:"start"},style:{marginLeft:-8}},{props:{edge:"end"},style:{marginRight:-8}},{props:{size:"small"},style:{width:40,height:24,padding:7,[`& .${Wk.thumb}`]:{width:16,height:16},[`& .${Wk.switchBase}`]:{padding:4,[`&.${Wk.checked}`]:{transform:"translateX(16px)"}}}}]}),Gk=pg(ex,{name:"MuiSwitch",slot:"SwitchBase",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.switchBase,{[`& .${Wk.input}`]:t.input},"default"!==n.color&&t[`color${xf(n.color)}`]]}})(vg(({theme:e})=>({position:"absolute",top:0,left:0,zIndex:1,color:e.vars?e.vars.palette.Switch.defaultColor:`${"light"===e.palette.mode?e.palette.common.white:e.palette.grey[300]}`,transition:e.transitions.create(["left","transform"],{duration:e.transitions.duration.shortest}),[`&.${Wk.checked}`]:{transform:"translateX(20px)"},[`&.${Wk.disabled}`]:{color:e.vars?e.vars.palette.Switch.defaultDisabledColor:`${"light"===e.palette.mode?e.palette.grey[100]:e.palette.grey[600]}`},[`&.${Wk.checked} + .${Wk.track}`]:{opacity:.5},[`&.${Wk.disabled} + .${Wk.track}`]:{opacity:e.vars?e.vars.opacity.switchTrackDisabled:""+("light"===e.palette.mode?.12:.2)},[`& .${Wk.input}`]:{left:"-100%",width:"300%"}})),vg(({theme:e})=>({"&:hover":{backgroundColor:e.alpha((e.vars||e).palette.action.active,(e.vars||e).palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}},variants:[...Object.entries(e.palette).filter(uv(["light"])).map(([t])=>({props:{color:t},style:{[`&.${Wk.checked}`]:{color:(e.vars||e).palette[t].main,"&:hover":{backgroundColor:e.alpha((e.vars||e).palette[t].main,(e.vars||e).palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}},[`&.${Wk.disabled}`]:{color:e.vars?e.vars.palette.Switch[`${t}DisabledColor`]:`${"light"===e.palette.mode?e.lighten(e.palette[t].main,.62):e.darken(e.palette[t].main,.55)}`}},[`&.${Wk.checked} + .${Wk.track}`]:{backgroundColor:(e.vars||e).palette[t].main}}}))]}))),Kk=pg("span",{name:"MuiSwitch",slot:"Track"})(vg(({theme:e})=>({height:"100%",width:"100%",borderRadius:7,zIndex:-1,transition:e.transitions.create(["opacity","background-color"],{duration:e.transitions.duration.shortest}),backgroundColor:e.vars?e.vars.palette.common.onBackground:`${"light"===e.palette.mode?e.palette.common.black:e.palette.common.white}`,opacity:e.vars?e.vars.opacity.switchTrack:""+("light"===e.palette.mode?.38:.3)}))),qk=pg("span",{name:"MuiSwitch",slot:"Thumb"})(vg(({theme:e})=>({boxShadow:(e.vars||e).shadows[1],backgroundColor:"currentColor",width:20,height:20,borderRadius:"50%"}))),Yk=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiSwitch"}),{className:r,color:o="primary",edge:i=!1,size:a="medium",sx:l,slots:s={},slotProps:c={},...u}=n,d={...n,color:o,edge:i,size:a},p=(e=>{const{classes:t,edge:n,size:r,color:o,checked:i,disabled:a}=e,l=wm({root:["root",n&&`edge${xf(n)}`,`size${xf(r)}`],switchBase:["switchBase",`color${xf(o)}`,i&&"checked",a&&"disabled"],thumb:["thumb"],track:["track"],input:["input"]},Vk,t);return{...t,...l}})(d),f={slots:s,slotProps:c},[h,m]=Ug("root",{className:mg(p.root,r),elementType:Uk,externalForwardedProps:f,ownerState:d,additionalProps:{sx:l}}),[g,v]=Ug("thumb",{className:p.thumb,elementType:qk,externalForwardedProps:f,ownerState:d}),b=Xp.jsx(g,{...v}),[y,w]=Ug("track",{className:p.track,elementType:Kk,externalForwardedProps:f,ownerState:d});return Xp.jsxs(h,{...m,children:[Xp.jsx(Gk,{type:"checkbox",icon:b,checkedIcon:b,ref:t,ownerState:d,...u,classes:{...p,root:p.switchBase},slots:{...s.switchBase&&{root:s.switchBase},...s.input&&{input:s.input}},slotProps:{...c.switchBase&&{root:"function"==typeof c.switchBase?c.switchBase(d):c.switchBase},input:{role:"switch"},...c.input&&{input:"function"==typeof c.input?c.input(d):c.input}}}),Xp.jsx(y,{...w})]})});function Xk(e){return Ph("MuiTab",e)}const Qk=Mh("MuiTab",["root","labelIcon","textColorInherit","textColorPrimary","textColorSecondary","selected","disabled","fullWidth","wrapped","iconWrapper","icon"]),Zk=pg(sv,{name:"MuiTab",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.label&&n.icon&&t.labelIcon,t[`textColor${xf(n.textColor)}`],n.fullWidth&&t.fullWidth,n.wrapped&&t.wrapped,{[`& .${Qk.iconWrapper}`]:t.iconWrapper},{[`& .${Qk.icon}`]:t.icon}]}})(vg(({theme:e})=>({...e.typography.button,maxWidth:360,minWidth:90,position:"relative",minHeight:48,flexShrink:0,padding:"12px 16px",overflow:"hidden",whiteSpace:"normal",textAlign:"center",lineHeight:1.25,variants:[{props:({ownerState:e})=>e.label&&("top"===e.iconPosition||"bottom"===e.iconPosition),style:{flexDirection:"column"}},{props:({ownerState:e})=>e.label&&"top"!==e.iconPosition&&"bottom"!==e.iconPosition,style:{flexDirection:"row"}},{props:({ownerState:e})=>e.icon&&e.label,style:{minHeight:72,paddingTop:9,paddingBottom:9}},{props:({ownerState:e,iconPosition:t})=>e.icon&&e.label&&"top"===t,style:{[`& > .${Qk.icon}`]:{marginBottom:6}}},{props:({ownerState:e,iconPosition:t})=>e.icon&&e.label&&"bottom"===t,style:{[`& > .${Qk.icon}`]:{marginTop:6}}},{props:({ownerState:e,iconPosition:t})=>e.icon&&e.label&&"start"===t,style:{[`& > .${Qk.icon}`]:{marginRight:e.spacing(1)}}},{props:({ownerState:e,iconPosition:t})=>e.icon&&e.label&&"end"===t,style:{[`& > .${Qk.icon}`]:{marginLeft:e.spacing(1)}}},{props:{textColor:"inherit"},style:{color:"inherit",opacity:.6,[`&.${Qk.selected}`]:{opacity:1},[`&.${Qk.disabled}`]:{opacity:(e.vars||e).palette.action.disabledOpacity}}},{props:{textColor:"primary"},style:{color:(e.vars||e).palette.text.secondary,[`&.${Qk.selected}`]:{color:(e.vars||e).palette.primary.main},[`&.${Qk.disabled}`]:{color:(e.vars||e).palette.text.disabled}}},{props:{textColor:"secondary"},style:{color:(e.vars||e).palette.text.secondary,[`&.${Qk.selected}`]:{color:(e.vars||e).palette.secondary.main},[`&.${Qk.disabled}`]:{color:(e.vars||e).palette.text.disabled}}},{props:({ownerState:e})=>e.fullWidth,style:{flexShrink:1,flexGrow:1,flexBasis:0,maxWidth:"none"}},{props:({ownerState:e})=>e.wrapped,style:{fontSize:e.typography.pxToRem(12)}}]}))),Jk=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiTab"}),{className:r,disabled:o=!1,disableFocusRipple:i=!1,fullWidth:a,icon:l,iconPosition:c="top",indicator:u,label:d,onChange:p,onClick:f,onFocus:h,selected:m,selectionFollowsFocus:g,textColor:v="inherit",value:b,wrapped:y=!1,...w}=n,x={...n,disabled:o,disableFocusRipple:i,selected:m,icon:!!l,iconPosition:c,label:!!d,fullWidth:a,textColor:v,wrapped:y},S=(e=>{const{classes:t,textColor:n,fullWidth:r,wrapped:o,icon:i,label:a,selected:l,disabled:s}=e;return wm({root:["root",i&&a&&"labelIcon",`textColor${xf(n)}`,r&&"fullWidth",o&&"wrapped",l&&"selected",s&&"disabled"],icon:["iconWrapper","icon"]},Xk,t)})(x),C=l&&d&&s.isValidElement(l)?s.cloneElement(l,{className:mg(S.icon,l.props.className)}):l;return Xp.jsxs(Zk,{focusRipple:!i,className:mg(S.root,r),ref:t,role:"tab","aria-selected":m,disabled:o,onClick:e=>{!m&&p&&p(e,b),f&&f(e)},onFocus:e=>{g&&!m&&p&&p(e,b),h&&h(e)},ownerState:x,tabIndex:m?0:-1,...w,children:["top"===c||"start"===c?Xp.jsxs(s.Fragment,{children:[C,d]}):Xp.jsxs(s.Fragment,{children:[d,C]}),u]})}),eE=s.createContext(),tE=s.createContext();function nE(e){return Ph("MuiTableCell",e)}const rE=Mh("MuiTableCell",["root","head","body","footer","sizeSmall","sizeMedium","paddingCheckbox","paddingNone","alignLeft","alignCenter","alignRight","alignJustify","stickyHeader"]),oE=pg("td",{name:"MuiTableCell",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[n.variant],t[`size${xf(n.size)}`],"normal"!==n.padding&&t[`padding${xf(n.padding)}`],"inherit"!==n.align&&t[`align${xf(n.align)}`],n.stickyHeader&&t.stickyHeader]}})(vg(({theme:e})=>({...e.typography.body2,display:"table-cell",verticalAlign:"inherit",borderBottom:e.vars?`1px solid ${e.vars.palette.TableCell.border}`:`1px solid\n ${"light"===e.palette.mode?e.lighten(e.alpha(e.palette.divider,1),.88):e.darken(e.alpha(e.palette.divider,1),.68)}`,textAlign:"left",padding:16,variants:[{props:{variant:"head"},style:{color:(e.vars||e).palette.text.primary,lineHeight:e.typography.pxToRem(24),fontWeight:e.typography.fontWeightMedium}},{props:{variant:"body"},style:{color:(e.vars||e).palette.text.primary}},{props:{variant:"footer"},style:{color:(e.vars||e).palette.text.secondary,lineHeight:e.typography.pxToRem(21),fontSize:e.typography.pxToRem(12)}},{props:{size:"small"},style:{padding:"6px 16px",[`&.${rE.paddingCheckbox}`]:{width:24,padding:"0 12px 0 16px","& > *":{padding:0}}}},{props:{padding:"checkbox"},style:{width:48,padding:"0 0 0 4px"}},{props:{padding:"none"},style:{padding:0}},{props:{align:"left"},style:{textAlign:"left"}},{props:{align:"center"},style:{textAlign:"center"}},{props:{align:"right"},style:{textAlign:"right",flexDirection:"row-reverse"}},{props:{align:"justify"},style:{textAlign:"justify"}},{props:({ownerState:e})=>e.stickyHeader,style:{position:"sticky",top:0,zIndex:2,backgroundColor:(e.vars||e).palette.background.default}}]}))),iE=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiTableCell"}),{align:r="inherit",className:o,component:i,padding:a,scope:l,size:c,sortDirection:u,variant:d,...p}=n,f=s.useContext(eE),h=s.useContext(tE),m=h&&"head"===h.variant;let g;g=i||(m?"th":"td");let v=l;"td"===g?v=void 0:!v&&m&&(v="col");const b=d||h&&h.variant,y={...n,align:r,component:g,padding:a||(f&&f.padding?f.padding:"normal"),size:c||(f&&f.size?f.size:"medium"),sortDirection:u,stickyHeader:"head"===b&&f&&f.stickyHeader,variant:b},w=(e=>{const{classes:t,variant:n,align:r,padding:o,size:i,stickyHeader:a}=e;return wm({root:["root",n,a&&"stickyHeader","inherit"!==r&&`align${xf(r)}`,"normal"!==o&&`padding${xf(o)}`,`size${xf(i)}`]},nE,t)})(y);let x=null;return u&&(x="asc"===u?"ascending":"descending"),Xp.jsx(oE,{as:g,ref:t,className:mg(w.root,o),"aria-sort":x,scope:v,ownerState:y,...p})});function aE(e){return Ph("MuiToolbar",e)}Mh("MuiToolbar",["root","gutters","regular","dense"]);const lE=pg("div",{name:"MuiToolbar",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,!n.disableGutters&&t.gutters,t[n.variant]]}})(vg(({theme:e})=>({position:"relative",display:"flex",alignItems:"center",variants:[{props:({ownerState:e})=>!e.disableGutters,style:{paddingLeft:e.spacing(2),paddingRight:e.spacing(2),[e.breakpoints.up("sm")]:{paddingLeft:e.spacing(3),paddingRight:e.spacing(3)}}},{props:{variant:"dense"},style:{minHeight:48}},{props:{variant:"regular"},style:e.mixins.toolbar}]}))),sE=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiToolbar"}),{className:r,component:o="div",disableGutters:i=!1,variant:a="regular",...l}=n,s={...n,component:o,disableGutters:i,variant:a},c=(e=>{const{classes:t,disableGutters:n,variant:r}=e;return wm({root:["root",!n&&"gutters",r]},aE,t)})(s);return Xp.jsx(lE,{as:o,className:mg(c.root,r),ref:t,ownerState:s,...l})});var cE=Sg(Xp.jsx("path",{d:"M15.41 16.09l-4.58-4.59 4.58-4.59L14 5.5l-6 6 6 6z"})),uE=Sg(Xp.jsx("path",{d:"M8.59 16.34l4.58-4.59-4.58-4.59L10 5.75l6 6-6 6z"}));function dE(e){return Ph("MuiTablePaginationActions",e)}Mh("MuiTablePaginationActions",["root"]);const pE=pg("div",{name:"MuiTablePaginationActions",slot:"Root"})({}),fE=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiTablePaginationActions"}),{backIconButtonProps:r,className:o,count:i,disabled:a=!1,getItemAriaLabel:l,nextIconButtonProps:s,onPageChange:c,page:u,rowsPerPage:d,showFirstButton:p,showLastButton:f,slots:h={},slotProps:m={},...g}=n,v=um(),b=(e=>{const{classes:t}=e;return wm({root:["root"]},dE,t)})(n),y=h.firstButton??Mv,w=h.lastButton??Mv,x=h.nextButton??Mv,S=h.previousButton??Mv,C=h.firstButtonIcon??nk,k=h.lastButtonIcon??rk,E=h.nextButtonIcon??uE,R=h.previousButtonIcon??cE,P=v?w:y,M=v?x:S,T=v?S:x,I=v?y:w,O=v?m.lastButton:m.firstButton,D=v?m.nextButton:m.previousButton,F=v?m.previousButton:m.nextButton,L=v?m.firstButton:m.lastButton;return Xp.jsxs(pE,{ref:t,className:mg(b.root,o),...g,children:[p&&Xp.jsx(P,{onClick:e=>{c(e,0)},disabled:a||0===u,"aria-label":l("first",u),title:l("first",u),...O,children:v?Xp.jsx(k,{...m.lastButtonIcon}):Xp.jsx(C,{...m.firstButtonIcon})}),Xp.jsx(M,{onClick:e=>{c(e,u-1)},disabled:a||0===u,color:"inherit","aria-label":l("previous",u),title:l("previous",u),...D??r,children:v?Xp.jsx(E,{...m.nextButtonIcon}):Xp.jsx(R,{...m.previousButtonIcon})}),Xp.jsx(T,{onClick:e=>{c(e,u+1)},disabled:a||-1!==i&&u>=Math.ceil(i/d)-1,color:"inherit","aria-label":l("next",u),title:l("next",u),...F??s,children:v?Xp.jsx(R,{...m.previousButtonIcon}):Xp.jsx(E,{...m.nextButtonIcon})}),f&&Xp.jsx(I,{onClick:e=>{c(e,Math.max(0,Math.ceil(i/d)-1))},disabled:a||u>=Math.ceil(i/d)-1,"aria-label":l("last",u),title:l("last",u),...L,children:v?Xp.jsx(C,{...m.firstButtonIcon}):Xp.jsx(k,{...m.lastButtonIcon})})]})});function hE(e){return Ph("MuiTablePagination",e)}const mE=Mh("MuiTablePagination",["root","toolbar","spacer","selectLabel","selectRoot","select","selectIcon","input","menuItem","displayedRows","actions"]);var gE;const vE=pg(iE,{name:"MuiTablePagination",slot:"Root"})(vg(({theme:e})=>({overflow:"auto",color:(e.vars||e).palette.text.primary,fontSize:e.typography.pxToRem(14),"&:last-child":{padding:0}}))),bE=pg(sE,{name:"MuiTablePagination",slot:"Toolbar",overridesResolver:(e,t)=>({[`& .${mE.actions}`]:t.actions,...t.toolbar})})(vg(({theme:e})=>({minHeight:52,paddingRight:2,[`${e.breakpoints.up("xs")} and (orientation: landscape)`]:{minHeight:52},[e.breakpoints.up("sm")]:{minHeight:52,paddingRight:2},[`& .${mE.actions}`]:{flexShrink:0,marginLeft:20}}))),yE=pg("div",{name:"MuiTablePagination",slot:"Spacer"})({flex:"1 1 100%"}),wE=pg("p",{name:"MuiTablePagination",slot:"SelectLabel"})(vg(({theme:e})=>({...e.typography.body2,flexShrink:0}))),xE=pg(vk,{name:"MuiTablePagination",slot:"Select",overridesResolver:(e,t)=>({[`& .${mE.selectIcon}`]:t.selectIcon,[`& .${mE.select}`]:t.select,...t.input,...t.selectRoot})})({color:"inherit",fontSize:"inherit",flexShrink:0,marginRight:32,marginLeft:8,[`& .${mE.select}`]:{paddingLeft:8,paddingRight:24,textAlign:"right",textAlignLast:"right"}}),SE=pg(_C,{name:"MuiTablePagination",slot:"MenuItem"})({}),CE=pg("p",{name:"MuiTablePagination",slot:"DisplayedRows"})(vg(({theme:e})=>({...e.typography.body2,flexShrink:0})));function kE({from:e,to:t,count:n}){return`${e}–${t} of ${-1!==n?n:`more than ${t}`}`}function EE(e){return`Go to ${e} page`}const RE=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiTablePagination"}),{ActionsComponent:r=fE,backIconButtonProps:o,colSpan:i,component:a=iE,count:l,disabled:c=!1,getItemAriaLabel:u=EE,labelDisplayedRows:d=kE,labelRowsPerPage:p="Rows per page:",nextIconButtonProps:f,onPageChange:h,onRowsPerPageChange:m,page:g,rowsPerPage:v,rowsPerPageOptions:b=[10,25,50,100],SelectProps:y={},showFirstButton:w=!1,showLastButton:x=!1,slotProps:S={},slots:C={},...k}=n,E=n,R=(e=>{const{classes:t}=e;return wm({root:["root"],toolbar:["toolbar"],spacer:["spacer"],selectLabel:["selectLabel"],select:["select"],input:["input"],selectIcon:["selectIcon"],menuItem:["menuItem"],displayedRows:["displayedRows"],actions:["actions"]},hE,t)})(E),P=S?.select??y,M=P.native?"option":SE;let T;a!==iE&&"td"!==a||(T=i||1e3);const I=mm(P.id),O=mm(P.labelId),D={slots:C,slotProps:S},[F,L]=Ug("root",{ref:t,className:R.root,elementType:vE,externalForwardedProps:{...D,component:a,...k},ownerState:E,additionalProps:{colSpan:T}}),[A,N]=Ug("toolbar",{className:R.toolbar,elementType:bE,externalForwardedProps:D,ownerState:E}),[$,z]=Ug("spacer",{className:R.spacer,elementType:yE,externalForwardedProps:D,ownerState:E}),[j,B]=Ug("selectLabel",{className:R.selectLabel,elementType:wE,externalForwardedProps:D,ownerState:E,additionalProps:{id:O}}),[_,H]=Ug("select",{className:R.select,elementType:xE,externalForwardedProps:D,ownerState:E}),[V,W]=Ug("menuItem",{className:R.menuItem,elementType:M,externalForwardedProps:D,ownerState:E}),[U,G]=Ug("displayedRows",{className:R.displayedRows,elementType:CE,externalForwardedProps:D,ownerState:E});return Xp.jsx(F,{...L,children:Xp.jsxs(A,{...N,children:[Xp.jsx($,{...z}),b.length>1&&Xp.jsx(j,{...B,children:p}),b.length>1&&Xp.jsx(_,{variant:"standard",...!P.variant&&{input:gE||(gE=Xp.jsx(nw,{}))},value:v,onChange:m,id:I,labelId:O,...P,classes:{...P.classes,root:mg(R.input,R.selectRoot,(P.classes||{}).root),select:mg(R.select,(P.classes||{}).select),icon:mg(R.selectIcon,(P.classes||{}).icon)},disabled:c,...H,children:b.map(e=>s.createElement(V,{...W,key:e.label?e.label:e,value:e.value?e.value:e},e.label?e.label:e))}),Xp.jsx(U,{...G,children:d({from:0===l?0:g*v+1,to:-1===l?(g+1)*v:-1===v?l:Math.min(l,(g+1)*v),count:-1===l?-1:l,page:g})}),Xp.jsx(r,{className:R.actions,backIconButtonProps:o,count:l,nextIconButtonProps:f,onPageChange:h,page:g,rowsPerPage:v,showFirstButton:w,showLastButton:x,slotProps:S.actions,slots:C.actions,getItemAriaLabel:u,disabled:c})]})})});function PE(e){return(1+Math.sin(Math.PI*e-Math.PI/2))/2}const ME={width:99,height:99,position:"absolute",top:-9999,overflow:"scroll"};function TE(e){return Ph("MuiTabScrollButton",e)}const IE=Mh("MuiTabScrollButton",["root","vertical","horizontal","disabled"]),OE=pg(sv,{name:"MuiTabScrollButton",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.orientation&&t[n.orientation]]}})({width:40,flexShrink:0,opacity:.8,[`&.${IE.disabled}`]:{opacity:0},variants:[{props:{orientation:"vertical"},style:{width:"100%",height:40,"& svg":{transform:"var(--TabScrollButton-svgRotate)"}}}]}),DE=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiTabScrollButton"}),{className:r,slots:o={},slotProps:i={},direction:a,orientation:l,disabled:s,...c}=n,u=um(),d={isRtl:u,...n},p=(e=>{const{classes:t,orientation:n,disabled:r}=e;return wm({root:["root",n,r&&"disabled"]},TE,t)})(d),f=o.StartScrollButtonIcon??cE,h=o.EndScrollButtonIcon??uE,m=yy({elementType:f,externalSlotProps:i.startScrollButtonIcon,additionalProps:{fontSize:"small"},ownerState:d}),g=yy({elementType:h,externalSlotProps:i.endScrollButtonIcon,additionalProps:{fontSize:"small"},ownerState:d});return Xp.jsx(OE,{component:"div",className:mg(p.root,r),ref:t,role:null,ownerState:d,tabIndex:null,...c,style:{...c.style,..."vertical"===l&&{"--TabScrollButton-svgRotate":`rotate(${u?-90:90}deg)`}},children:"left"===a?Xp.jsx(f,{...m}):Xp.jsx(h,{...g})})});function FE(e){return Ph("MuiTabs",e)}const LE=Mh("MuiTabs",["root","vertical","list","flexContainer","flexContainerVertical","centered","scroller","fixed","scrollableX","scrollableY","hideScrollbar","scrollButtons","scrollButtonsHideMobile","indicator"]),AE=(e,t)=>e===t?e.firstChild:t&&t.nextElementSibling?t.nextElementSibling:e.firstChild,NE=(e,t)=>e===t?e.lastChild:t&&t.previousElementSibling?t.previousElementSibling:e.lastChild,$E=(e,t,n)=>{let r=!1,o=n(e,t);for(;o;){if(o===e.firstChild){if(r)return;r=!0}const t=o.disabled||"true"===o.getAttribute("aria-disabled");if(o.hasAttribute("tabindex")&&!t)return void o.focus();o=n(e,o)}},zE=pg("div",{name:"MuiTabs",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[{[`& .${LE.scrollButtons}`]:t.scrollButtons},{[`& .${LE.scrollButtons}`]:n.scrollButtonsHideMobile&&t.scrollButtonsHideMobile},t.root,n.vertical&&t.vertical]}})(vg(({theme:e})=>({overflow:"hidden",minHeight:48,WebkitOverflowScrolling:"touch",display:"flex",variants:[{props:({ownerState:e})=>e.vertical,style:{flexDirection:"column"}},{props:({ownerState:e})=>e.scrollButtonsHideMobile,style:{[`& .${LE.scrollButtons}`]:{[e.breakpoints.down("sm")]:{display:"none"}}}}]}))),jE=pg("div",{name:"MuiTabs",slot:"Scroller",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.scroller,n.fixed&&t.fixed,n.hideScrollbar&&t.hideScrollbar,n.scrollableX&&t.scrollableX,n.scrollableY&&t.scrollableY]}})({position:"relative",display:"inline-block",flex:"1 1 auto",whiteSpace:"nowrap",variants:[{props:({ownerState:e})=>e.fixed,style:{overflowX:"hidden",width:"100%"}},{props:({ownerState:e})=>e.hideScrollbar,style:{scrollbarWidth:"none","&::-webkit-scrollbar":{display:"none"}}},{props:({ownerState:e})=>e.scrollableX,style:{overflowX:"auto",overflowY:"hidden"}},{props:({ownerState:e})=>e.scrollableY,style:{overflowY:"auto",overflowX:"hidden"}}]}),BE=pg("div",{name:"MuiTabs",slot:"List",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.list,t.flexContainer,n.vertical&&t.flexContainerVertical,n.centered&&t.centered]}})({display:"flex",variants:[{props:({ownerState:e})=>e.vertical,style:{flexDirection:"column"}},{props:({ownerState:e})=>e.centered,style:{justifyContent:"center"}}]}),_E=pg("span",{name:"MuiTabs",slot:"Indicator"})(vg(({theme:e})=>({position:"absolute",height:2,bottom:0,width:"100%",transition:e.transitions.create(),variants:[{props:{indicatorColor:"primary"},style:{backgroundColor:(e.vars||e).palette.primary.main}},{props:{indicatorColor:"secondary"},style:{backgroundColor:(e.vars||e).palette.secondary.main}},{props:({ownerState:e})=>e.vertical,style:{height:"100%",width:2,right:0}}]}))),HE=pg(function(e){const{onChange:t,...n}=e,r=s.useRef(),o=s.useRef(null),i=()=>{r.current=o.current.offsetHeight-o.current.clientHeight};return Wh(()=>{const e=Cg(()=>{const e=r.current;i(),e!==r.current&&t(r.current)}),n=Eg(o.current);return n.addEventListener("resize",e),()=>{e.clear(),n.removeEventListener("resize",e)}},[t]),s.useEffect(()=>{i(),t(r.current)},[t]),Xp.jsx("div",{style:ME,...n,ref:o})})({overflowX:"auto",overflowY:"hidden",scrollbarWidth:"none","&::-webkit-scrollbar":{display:"none"}}),VE={},WE=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiTabs"}),r=sg(),o=um(),{"aria-label":i,"aria-labelledby":a,action:l,centered:c=!1,children:u,className:d,component:p="div",allowScrollButtonsMobile:f=!1,indicatorColor:h="primary",onChange:m,orientation:g="horizontal",ScrollButtonComponent:v,scrollButtons:b="auto",selectionFollowsFocus:y,slots:w={},slotProps:x={},TabIndicatorProps:S={},TabScrollButtonProps:C={},textColor:k="primary",value:E,variant:R="standard",visibleScrollbar:P=!1,...M}=n,T="scrollable"===R,I="vertical"===g,O=I?"scrollTop":"scrollLeft",D=I?"top":"left",F=I?"bottom":"right",L=I?"clientHeight":"clientWidth",A=I?"height":"width",N={...n,component:p,allowScrollButtonsMobile:f,indicatorColor:h,orientation:g,vertical:I,scrollButtons:b,textColor:k,variant:R,visibleScrollbar:P,fixed:!T,hideScrollbar:T&&!P,scrollableX:T&&!I,scrollableY:T&&I,centered:c&&!T,scrollButtonsHideMobile:!f},$=(e=>{const{vertical:t,fixed:n,hideScrollbar:r,scrollableX:o,scrollableY:i,centered:a,scrollButtonsHideMobile:l,classes:s}=e;return wm({root:["root",t&&"vertical"],scroller:["scroller",n&&"fixed",r&&"hideScrollbar",o&&"scrollableX",i&&"scrollableY"],list:["list","flexContainer",t&&"flexContainerVertical",t&&"vertical",a&&"centered"],indicator:["indicator"],scrollButtons:["scrollButtons",l&&"scrollButtonsHideMobile"],scrollableX:[o&&"scrollableX"],hideScrollbar:[r&&"hideScrollbar"]},FE,s)})(N),z=yy({elementType:w.StartScrollButtonIcon,externalSlotProps:x.startScrollButtonIcon,ownerState:N}),j=yy({elementType:w.EndScrollButtonIcon,externalSlotProps:x.endScrollButtonIcon,ownerState:N}),[B,_]=s.useState(!1),[H,V]=s.useState(VE),[W,U]=s.useState(!1),[G,K]=s.useState(!1),[q,Y]=s.useState(!1),[X,Q]=s.useState({overflow:"hidden",scrollbarWidth:0}),Z=new Map,J=s.useRef(null),ee=s.useRef(null),te={slots:w,slotProps:{indicator:S,scrollButton:C,...x}},ne=()=>{const e=J.current;let t,n;if(e){const n=e.getBoundingClientRect();t={clientWidth:e.clientWidth,scrollLeft:e.scrollLeft,scrollTop:e.scrollTop,scrollWidth:e.scrollWidth,top:n.top,bottom:n.bottom,left:n.left,right:n.right}}if(e&&!1!==E){const e=ee.current.children;if(e.length>0){const t=e[Z.get(E)];n=t?t.getBoundingClientRect():null}}return{tabsMeta:t,tabMeta:n}},re=Mg(()=>{const{tabsMeta:e,tabMeta:t}=ne();let n,r=0;I?(n="top",t&&e&&(r=t.top-e.top+e.scrollTop)):(n=o?"right":"left",t&&e&&(r=(o?-1:1)*(t[n]-e[n]+e.scrollLeft)));const i={[n]:r,[A]:t?t[A]:0};if("number"!=typeof H[n]||"number"!=typeof H[A])V(i);else{const e=Math.abs(H[n]-i[n]),t=Math.abs(H[A]-i[A]);(e>=1||t>=1)&&V(i)}}),oe=(e,{animation:t=!0}={})=>{t?function(e,t,n,r={},o=()=>{}){const{ease:i=PE,duration:a=300}=r;let l=null;const s=t[e];let c=!1;const u=()=>{c=!0},d=r=>{if(c)return void o(new Error("Animation cancelled"));null===l&&(l=r);const u=Math.min(1,(r-l)/a);t[e]=i(u)*(n-s)+s,u>=1?requestAnimationFrame(()=>{o(null)}):requestAnimationFrame(d)};s===n?o(new Error("Element already at target position")):requestAnimationFrame(d)}(O,J.current,e,{duration:r.transitions.duration.standard}):J.current[O]=e},ie=e=>{let t=J.current[O];t+=I?e:e*(o?-1:1),oe(t)},ae=()=>{const e=J.current[L];let t=0;const n=Array.from(ee.current.children);for(let r=0;r<n.length;r+=1){const o=n[r];if(t+o[L]>e){0===r&&(t=e);break}t+=o[L]}return t},le=()=>{ie(-1*ae())},se=()=>{ie(ae())},[ce,{onChange:ue,...de}]=Ug("scrollbar",{className:mg($.scrollableX,$.hideScrollbar),elementType:HE,shouldForwardComponentProp:!0,externalForwardedProps:te,ownerState:N}),pe=s.useCallback(e=>{ue?.(e),Q({overflow:null,scrollbarWidth:e})},[ue]),[fe,he]=Ug("scrollButtons",{className:mg($.scrollButtons,C.className),elementType:DE,externalForwardedProps:te,ownerState:N,additionalProps:{orientation:g,slots:{StartScrollButtonIcon:w.startScrollButtonIcon||w.StartScrollButtonIcon,EndScrollButtonIcon:w.endScrollButtonIcon||w.EndScrollButtonIcon},slotProps:{startScrollButtonIcon:z,endScrollButtonIcon:j}}}),me=Mg(e=>{const{tabsMeta:t,tabMeta:n}=ne();if(n&&t)if(n[D]<t[D]){const r=t[O]+(n[D]-t[D]);oe(r,{animation:e})}else if(n[F]>t[F]){const r=t[O]+(n[F]-t[F]);oe(r,{animation:e})}}),ge=Mg(()=>{T&&!1!==b&&Y(!q)});s.useEffect(()=>{const e=Cg(()=>{J.current&&re()});let t;const n=n=>{n.forEach(e=>{e.removedNodes.forEach(e=>{t?.unobserve(e)}),e.addedNodes.forEach(e=>{t?.observe(e)})}),e(),ge()},r=Eg(J.current);let o;return r.addEventListener("resize",e),"undefined"!=typeof ResizeObserver&&(t=new ResizeObserver(e),Array.from(ee.current.children).forEach(e=>{t.observe(e)})),"undefined"!=typeof MutationObserver&&(o=new MutationObserver(n),o.observe(ee.current,{childList:!0})),()=>{e.clear(),r.removeEventListener("resize",e),o?.disconnect(),t?.disconnect()}},[re,ge]),s.useEffect(()=>{const e=Array.from(ee.current.children),t=e.length;if("undefined"!=typeof IntersectionObserver&&t>0&&T&&!1!==b){const n=e[0],r=e[t-1],o={root:J.current,threshold:.99},i=new IntersectionObserver(e=>{U(!e[0].isIntersecting)},o);i.observe(n);const a=new IntersectionObserver(e=>{K(!e[0].isIntersecting)},o);return a.observe(r),()=>{i.disconnect(),a.disconnect()}}},[T,b,q,u?.length]),s.useEffect(()=>{_(!0)},[]),s.useEffect(()=>{re()}),s.useEffect(()=>{me(VE!==H)},[me,H]),s.useImperativeHandle(l,()=>({updateIndicator:re,updateScrollButtons:ge}),[re,ge]);const[ve,be]=Ug("indicator",{className:mg($.indicator,S.className),elementType:_E,externalForwardedProps:te,ownerState:N,additionalProps:{style:H}}),ye=Xp.jsx(ve,{...be});let we=0;const xe=s.Children.map(u,e=>{if(!s.isValidElement(e))return null;const t=void 0===e.props.value?we:e.props.value;Z.set(t,we);const n=t===E;return we+=1,s.cloneElement(e,{fullWidth:"fullWidth"===R,indicator:n&&!B&&ye,selected:n,selectionFollowsFocus:y,onChange:m,textColor:k,value:t,...1!==we||!1!==E||e.props.tabIndex?{}:{tabIndex:0}})}),Se=(()=>{const e={};e.scrollbarSizeListener=T?Xp.jsx(ce,{...de,onChange:pe}):null;const t=T&&("auto"===b&&(W||G)||!0===b);return e.scrollButtonStart=t?Xp.jsx(fe,{direction:o?"right":"left",onClick:le,disabled:!W,...he}):null,e.scrollButtonEnd=t?Xp.jsx(fe,{direction:o?"left":"right",onClick:se,disabled:!G,...he}):null,e})(),[Ce,ke]=Ug("root",{ref:t,className:mg($.root,d),elementType:zE,externalForwardedProps:{...te,...M,component:p},ownerState:N}),[Ee,Re]=Ug("scroller",{ref:J,className:$.scroller,elementType:jE,externalForwardedProps:te,ownerState:N,additionalProps:{style:{overflow:X.overflow,[I?"margin"+(o?"Left":"Right"):"marginBottom"]:P?void 0:-X.scrollbarWidth}}}),[Pe,Me]=Ug("list",{ref:ee,className:mg($.list,$.flexContainer),elementType:BE,externalForwardedProps:te,ownerState:N,getSlotProps:e=>({...e,onKeyDown:t=>{(e=>{if(e.altKey||e.shiftKey||e.ctrlKey||e.metaKey)return;const t=ee.current,n=yx(kg(t)),r=n?.getAttribute("role");if("tab"!==r)return;let i="horizontal"===g?"ArrowLeft":"ArrowUp",a="horizontal"===g?"ArrowRight":"ArrowDown";switch("horizontal"===g&&o&&(i="ArrowRight",a="ArrowLeft"),e.key){case i:e.preventDefault(),$E(t,n,NE);break;case a:e.preventDefault(),$E(t,n,AE);break;case"Home":e.preventDefault(),$E(t,null,AE);break;case"End":e.preventDefault(),$E(t,null,NE)}})(t),e.onKeyDown?.(t)}})});return Xp.jsxs(Ce,{...ke,children:[Se.scrollButtonStart,Se.scrollbarSizeListener,Xp.jsxs(Ee,{...Re,children:[Xp.jsx(Pe,{"aria-label":i,"aria-labelledby":a,"aria-orientation":"vertical"===g?"vertical":null,role:"tablist",...Me,children:xe}),B&&ye]}),Se.scrollButtonEnd]})});function UE(e){return Ph("MuiTextField",e)}Mh("MuiTextField",["root"]);const GE={standard:IS,filled:iS,outlined:tk},KE=pg(sS,{name:"MuiTextField",slot:"Root"})({}),qE=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiTextField"}),{autoComplete:r,autoFocus:o=!1,children:i,className:a,color:l="primary",defaultValue:s,disabled:c=!1,error:u=!1,FormHelperTextProps:d,fullWidth:p=!1,helperText:f,id:h,InputLabelProps:m,inputProps:g,InputProps:v,inputRef:b,label:y,maxRows:w,minRows:x,multiline:S=!1,name:C,onBlur:k,onChange:E,onFocus:R,placeholder:P,required:M=!1,rows:T,select:I=!1,SelectProps:O,slots:D={},slotProps:F={},type:L,value:A,variant:N="outlined",...$}=n,z={...n,autoFocus:o,color:l,disabled:c,error:u,fullWidth:p,multiline:S,required:M,select:I,variant:N},j=(e=>{const{classes:t}=e;return wm({root:["root"]},UE,t)})(z),B=mm(h),_=f&&B?`${B}-helper-text`:void 0,H=y&&B?`${B}-label`:void 0,V=GE[N],W={slots:D,slotProps:{input:v,inputLabel:m,htmlInput:g,formHelperText:d,select:O,...F}},U={},G=W.slotProps.inputLabel;"outlined"===N&&(G&&void 0!==G.shrink&&(U.notched=G.shrink),U.label=y),I&&(O&&O.native||(U.id=void 0),U["aria-describedby"]=void 0);const[K,q]=Ug("root",{elementType:KE,shouldForwardComponentProp:!0,externalForwardedProps:{...W,...$},ownerState:z,className:mg(j.root,a),ref:t,additionalProps:{disabled:c,error:u,fullWidth:p,required:M,color:l,variant:N}}),[Y,X]=Ug("input",{elementType:V,externalForwardedProps:W,additionalProps:U,ownerState:z}),[Q,Z]=Ug("inputLabel",{elementType:zS,externalForwardedProps:W,ownerState:z}),[J,ee]=Ug("htmlInput",{elementType:"input",externalForwardedProps:W,ownerState:z}),[te,ne]=Ug("formHelperText",{elementType:bS,externalForwardedProps:W,ownerState:z}),[re,oe]=Ug("select",{elementType:vk,externalForwardedProps:W,ownerState:z}),ie=Xp.jsx(Y,{"aria-describedby":_,autoComplete:r,autoFocus:o,defaultValue:s,fullWidth:p,multiline:S,name:C,rows:T,maxRows:w,minRows:x,type:L,value:A,id:B,inputRef:b,onBlur:k,onChange:E,onFocus:R,placeholder:P,inputProps:ee,slots:{input:D.htmlInput?J:void 0},...X});return Xp.jsxs(K,{...q,children:[null!=y&&""!==y&&Xp.jsx(Q,{htmlFor:B,id:H,...Z,children:y}),I?Xp.jsx(re,{"aria-describedby":_,id:B,labelId:H,value:A,input:ie,...oe,children:i}):ie,f&&Xp.jsx(te,{id:_,...ne,children:f})]})});function YE(e){return Ph("MuiToggleButton",e)}const XE=Mh("MuiToggleButton",["root","disabled","selected","standard","primary","secondary","sizeSmall","sizeMedium","sizeLarge","fullWidth"]),QE=s.createContext({}),ZE=s.createContext(void 0);function JE(e,t){return void 0!==t&&void 0!==e&&(Array.isArray(t)?t.includes(e):e===t)}const eR=pg(sv,{name:"MuiToggleButton",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[`size${xf(n.size)}`]]}})(vg(({theme:e})=>({...e.typography.button,borderRadius:(e.vars||e).shape.borderRadius,padding:11,border:`1px solid ${(e.vars||e).palette.divider}`,color:(e.vars||e).palette.action.active,[`&.${XE.disabled}`]:{color:(e.vars||e).palette.action.disabled,border:`1px solid ${(e.vars||e).palette.action.disabledBackground}`},"&:hover":{textDecoration:"none",backgroundColor:e.alpha((e.vars||e).palette.text.primary,(e.vars||e).palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}},variants:[{props:{color:"standard"},style:{[`&.${XE.selected}`]:{color:(e.vars||e).palette.text.primary,backgroundColor:e.alpha((e.vars||e).palette.text.primary,(e.vars||e).palette.action.selectedOpacity),"&:hover":{backgroundColor:e.alpha((e.vars||e).palette.text.primary,`${(e.vars||e).palette.action.selectedOpacity} + ${(e.vars||e).palette.action.hoverOpacity}`),"@media (hover: none)":{backgroundColor:e.alpha((e.vars||e).palette.text.primary,(e.vars||e).palette.action.selectedOpacity)}}}}},...Object.entries(e.palette).filter(uv()).map(([t])=>({props:{color:t},style:{[`&.${XE.selected}`]:{color:(e.vars||e).palette[t].main,backgroundColor:e.alpha((e.vars||e).palette[t].main,(e.vars||e).palette.action.selectedOpacity),"&:hover":{backgroundColor:e.alpha((e.vars||e).palette[t].main,`${(e.vars||e).palette.action.selectedOpacity} + ${(e.vars||e).palette.action.hoverOpacity}`),"@media (hover: none)":{backgroundColor:e.alpha((e.vars||e).palette[t].main,(e.vars||e).palette.action.selectedOpacity)}}}}})),{props:{fullWidth:!0},style:{width:"100%"}},{props:{size:"small"},style:{padding:7,fontSize:e.typography.pxToRem(13)}},{props:{size:"large"},style:{padding:15,fontSize:e.typography.pxToRem(15)}}]}))),tR=s.forwardRef(function(e,t){const{value:n,...r}=s.useContext(QE),o=s.useContext(ZE),i=bg({props:Hh({...r,selected:JE(e.value,n)},e),name:"MuiToggleButton"}),{children:a,className:l,color:c="standard",disabled:u=!1,disableFocusRipple:d=!1,fullWidth:p=!1,onChange:f,onClick:h,selected:m,size:g="medium",value:v,...b}=i,y={...i,color:c,disabled:u,disableFocusRipple:d,fullWidth:p,size:g},w=(e=>{const{classes:t,fullWidth:n,selected:r,disabled:o,size:i,color:a}=e;return wm({root:["root",r&&"selected",o&&"disabled",n&&"fullWidth",`size${xf(i)}`,a]},YE,t)})(y),x=o||"";return Xp.jsx(eR,{className:mg(r.className,w.root,l,x),disabled:u,focusRipple:!d,ref:t,onClick:e=>{h&&(h(e,v),e.defaultPrevented)||f&&f(e,v)},onChange:f,value:v,ownerState:y,"aria-pressed":m,...b,children:a})}),nR=qh({themeId:od}),rR=Number("7");var oR=Sg(Xp.jsx("path",{d:"M19 5v14H5V5zm0-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2"})),iR=Sg(Xp.jsx("path",{d:"M19 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.11 0 2-.9 2-2V5c0-1.1-.89-2-2-2m-9 14-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8z"}));const aR=s.createElement(oR,{fontSize:"small"}),lR=s.createElement(iR,{fontSize:"small"});function sR({items:e,selectedKeys:t,defaultSelectedKeys:n,onChange:r,inputValue:o,defaultInputValue:i,onInputChange:a,debounceMs:l=300,label:c,placeholder:u,loading:d,disabled:p,size:f="small",error:h,helperText:m,limitTags:g=3,disableClearable:v,id:b,textFieldProps:y}){const w=s.useMemo(()=>Array.isArray(e)?e:[],[e]),x=Array.isArray(t),[S,C]=s.useState(Array.isArray(n)?n:[]),k=x?t:S,E=s.useMemo(()=>{const e=new Map;for(const t of w)e.set(t&&t.key,t);return e},[w]),R=s.useMemo(()=>(Array.isArray(k)?k:[]).map(e=>E.get(e)).filter(Boolean),[k,E]),P="string"==typeof o,[M,T]=s.useState("string"==typeof i?i:""),I=P?o:M,O=function(e,t=300){const n=s.useRef(e),r=s.useRef(null);return n.current=e,s.useEffect(()=>()=>{r.current&&window.clearTimeout(r.current)},[]),s.useCallback((...e)=>{n.current&&(r.current&&window.clearTimeout(r.current),r.current=window.setTimeout(()=>{n.current&&n.current(...e)},t))},[t])}(e=>{a&&a(e)},l),D=R;return s.createElement(sS,{fullWidth:!0,error:h,disabled:p},s.createElement(Ew,{openOnFocus:!0,forcePopupIcon:!0,id:b,multiple:!0,disableCloseOnSelect:!0,options:w,value:D,inputValue:I,getOptionLabel:e=>e&&"object"==typeof e?e.value??"":"",isOptionEqualToValue:(e,t)=>e&&t&&e.key===t.key,loading:d,limitTags:g,disableClearable:v,onChange:(e,t)=>{const n=Array.isArray(t)?t.map(e=>e&&e.key):[];x||C(n),r&&r(n,Array.isArray(t)?t:[])},onInputChange:(e,t,n)=>{P||T(t??""),"input"===n?O(t??""):"clear"===n&&O("")},renderOption:(e,t,{selected:n})=>s.createElement("li",Xr({},e,{key:t&&t.key||Math.random().toString(36)}),s.createElement(ux,{icon:aR,checkedIcon:lR,style:{marginRight:8},checked:!!n}),t&&t.value),renderTags:(e,t)=>(Array.isArray(e)?e:[]).map((e,n)=>s.createElement(zy,Xr({},t({index:n}),{key:e&&e.key||n,label:e&&e.value||""}))),renderInput:e=>s.createElement(qE,Xr({},e,{label:c,placeholder:u,InputProps:{...e.InputProps,endAdornment:s.createElement(s.Fragment,null,d?s.createElement(Cv,{size:18}):null,e.InputProps.endAdornment)},size:f},y))}),m?s.createElement(bS,null,m):null)}const cR=({filter:e,channel:t,query:n})=>{const[r,o]=s.useState([]),[i,a]=s.useState([]),[l,u]=s.useState(!1),[d,p]=s.useState("");return s.useEffect(()=>{a(n?.filter?.[e?.filter]||[])},[n]),s.useEffect(()=>{(async()=>{u(!0);const t=await async function(e,t){return t?.source?(await jc.runReport({id:t.source})).map(e=>({key:e[t.field],value:e[t.field]})):[]}(0,e);o(t),u(!1)})()},[d]),c.createElement("div",{style:{display:"flex"}},c.createElement("div",{style:{maxWidth:640,minWidth:200}},c.createElement(sR,{id:e?.title,label:e?.title,placeholder:"Type to search…",items:r,selectedKeys:i,onChange:(n,r)=>{a(n),t.emit("filterChanged",e,{[e.filter]:n})},onInputChange:e=>{p(e)},loading:l,debounceMs:300,helperText:i.length?`${i.length} selected`:""})))};function uR({items:e,value:t,label:n,onChange:r,sx:o={width:"100%"},disabled:i=!1}){const a=e.some(e=>e.key===t)?t:"";return c.createElement(jw,{sx:o},c.createElement(sS,{fullWidth:!0},c.createElement(zS,{id:"demo-simple-select-label"},n),c.createElement(vk,{labelId:"demo-simple-select-label",id:"demo-simple-select",value:a,label:n,onChange:r,disabled:i,MenuProps:{style:{maxHeight:"300px"}},size:"small"},e.map(e=>{const{key:t,value:n,disabled:r}=e;return c.createElement(_C,{key:t,value:t,disabled:r},n)}))))}const dR=({filter:e,channel:t,query:n})=>{const[r,o]=s.useState([]),[i,a]=s.useState("");return s.useEffect(()=>{a(n?.date_range?.name)},[n]),s.useEffect(()=>{(async()=>{const t=(await jc.getDateRanges()).filter(t=>!(e.allowedOptions.length>0)||e.allowedOptions.some(e=>e===t.name)).map(e=>({key:e.name,value:e.title}));o(t)})()},[]),c.createElement("div",{style:{minWidth:"200px",maxWidth:"640px"}},c.createElement(uR,{items:r,value:i,label:e?.title,onChange:(n,r)=>{const o=n.target.value;a(o),t.emit("filterChanged",e,{date_range:{name:o}})}}))},pR=({filters:e=[],channel:t,query:n})=>c.createElement("div",{style:{display:"flex",flexWrap:"wrap",gap:"8px"}},e.map(e=>"multi-select"===e.type?c.createElement(cR,{key:e.title,channel:t,filter:e,query:n}):"date-range"===e.type?c.createElement(dR,{key:e.title,channel:t,filter:e,query:n}):null));var fR,hR={exports:{}};var mR=(fR||(fR=1,function(e){var t=Object.prototype.hasOwnProperty,n="~";function r(){}function o(e,t,n){this.fn=e,this.context=t,this.once=n||!1}function i(e,t,r,i,a){if("function"!=typeof r)throw new TypeError("The listener must be a function");var l=new o(r,i||e,a),s=n?n+t:t;return e._events[s]?e._events[s].fn?e._events[s]=[e._events[s],l]:e._events[s].push(l):(e._events[s]=l,e._eventsCount++),e}function a(e,t){0===--e._eventsCount?e._events=new r:delete e._events[t]}function l(){this._events=new r,this._eventsCount=0}Object.create&&(r.prototype=Object.create(null),(new r).__proto__||(n=!1)),l.prototype.eventNames=function(){var e,r,o=[];if(0===this._eventsCount)return o;for(r in e=this._events)t.call(e,r)&&o.push(n?r.slice(1):r);return Object.getOwnPropertySymbols?o.concat(Object.getOwnPropertySymbols(e)):o},l.prototype.listeners=function(e){var t=n?n+e:e,r=this._events[t];if(!r)return[];if(r.fn)return[r.fn];for(var o=0,i=r.length,a=new Array(i);o<i;o++)a[o]=r[o].fn;return a},l.prototype.listenerCount=function(e){var t=n?n+e:e,r=this._events[t];return r?r.fn?1:r.length:0},l.prototype.emit=function(e,t,r,o,i,a){var l=n?n+e:e;if(!this._events[l])return!1;var s,c,u=this._events[l],d=arguments.length;if(u.fn){switch(u.once&&this.removeListener(e,u.fn,void 0,!0),d){case 1:return u.fn.call(u.context),!0;case 2:return u.fn.call(u.context,t),!0;case 3:return u.fn.call(u.context,t,r),!0;case 4:return u.fn.call(u.context,t,r,o),!0;case 5:return u.fn.call(u.context,t,r,o,i),!0;case 6:return u.fn.call(u.context,t,r,o,i,a),!0}for(c=1,s=new Array(d-1);c<d;c++)s[c-1]=arguments[c];u.fn.apply(u.context,s)}else{var p,f=u.length;for(c=0;c<f;c++)switch(u[c].once&&this.removeListener(e,u[c].fn,void 0,!0),d){case 1:u[c].fn.call(u[c].context);break;case 2:u[c].fn.call(u[c].context,t);break;case 3:u[c].fn.call(u[c].context,t,r);break;case 4:u[c].fn.call(u[c].context,t,r,o);break;default:if(!s)for(p=1,s=new Array(d-1);p<d;p++)s[p-1]=arguments[p];u[c].fn.apply(u[c].context,s)}}return!0},l.prototype.on=function(e,t,n){return i(this,e,t,n,!1)},l.prototype.once=function(e,t,n){return i(this,e,t,n,!0)},l.prototype.removeListener=function(e,t,r,o){var i=n?n+e:e;if(!this._events[i])return this;if(!t)return a(this,i),this;var l=this._events[i];if(l.fn)l.fn!==t||o&&!l.once||r&&l.context!==r||a(this,i);else{for(var s=0,c=[],u=l.length;s<u;s++)(l[s].fn!==t||o&&!l[s].once||r&&l[s].context!==r)&&c.push(l[s]);c.length?this._events[i]=1===c.length?c[0]:c:a(this,i)}return this},l.prototype.removeAllListeners=function(e){var t;return e?(t=n?n+e:e,this._events[t]&&a(this,t)):(this._events=new r,this._eventsCount=0),this},l.prototype.off=l.prototype.removeListener,l.prototype.addListener=l.prototype.on,l.prefixed=n,l.EventEmitter=l,e.exports=l}(hR)),hR.exports),gR=t(mR),vR=e=>c.useRef(e||new gR).current,bR=e=>{const t=c.useState({}),n=c.useCallback((n,r)=>{let o={...t.current,...r};for(var i in t.current=o,o)"date_range"===i||o[i].length||delete o[i];e?.emit("mergedFilterChanged",{value:o})},[e]);c.useEffect(()=>(e?.on("filterChanged",n),()=>{e?.off("filterChanged",n)}),[e])},yR=({id:e,cache:t,dashboard:n,channel:r,...o})=>{const[i,a]=c.useState(),[l,u]=c.useState(),[d,p]=c.useState(),[f,h]=c.useState(),[m,g]=c.useState(vu()),[v,b]=c.useState(),[y,w]=c.useState(0),[x,S]=c.useState(!1),[C,k]=c.useState(),[E,R]=c.useState(!1),P=c.useRef({value:o?.filter}),[M,T]=c.useState({}),{ref:I,inView:O}=function({threshold:e,delay:t,trackVisibility:n,rootMargin:r,root:o,triggerOnce:i,skip:a,initialInView:l,fallbackInView:c,onChange:u}={}){var d;const[p,f]=s.useState(null),h=s.useRef(u),m=s.useRef(l),[g,v]=s.useState({inView:!!l,entry:void 0});h.current=u,s.useEffect(()=>{if(void 0===m.current&&(m.current=l),a||!p)return;let s;return s=Su(p,(e,t)=>{const n=m.current;m.current=e,(void 0!==n||e)&&(v({inView:e,entry:t}),h.current&&h.current(e,t),t.isIntersecting&&i&&s&&(s(),s=void 0))},{root:o,rootMargin:r,threshold:e,trackVisibility:n,delay:t},c),()=>{s&&s()}},[Array.isArray(e)?e.toString():e,p,o,r,i,a,n,c,t]);const b=null==(d=g.entry)?void 0:d.target,y=s.useRef(void 0);p||!b||i||a||y.current===b||(y.current=b,v({inView:!!l,entry:void 0}),m.current=l);const w=[f,g.inView,g.entry];return w.ref=w[0],w.inView=w[1],w.entry=w[2],w}({threshold:.1,delay:1e3}),D=vR(r);bR(D);const F=c.useCallback(e=>{const t=e.target.value;w(t),b(i.doc.view[t])},[i]);c.useEffect(()=>{e&&(async()=>{const n=e,r=t?.[n]||await jc.getChart({id:n}),i=r.doc.source?.id,l=i?t?.[i]||await jc.getReport({id:i}):void 0,s=t?.[`schema_${i}`]||o?.schema||await jc.getReportSchema({id:i}),c=r.doc?.view?.[0];w(0),u(l),a(r),b(c),p(s),R(!0)})().catch(e=>{console.error(e.message)})},[e]),c.useEffect(()=>{i&&f&&(!i?.doc?.source?.id||l)&&d&&(async()=>{g(vu(i.doc.chart?.component,{view:v,source:f,chart:i,report:l,schema:d,dashboard:n,query:M}))})().catch(e=>{console.error(e.message)})},[i,f,v,l,d]);const L=e=>{const t={...l?.doc.query.filter||{},...o?.filter,...e?.value},n=t.date_range||l?.doc.query.date_range;if(delete t.date_range,R(!1),k(),S(!0),"context"===i?.doc?.source?.type)return h({filter:t}),void S(!1);const r={filter:t,date_range:n,parameters:o?.params};T(r),jc.runReport({id:l.id,query:r}).then(e=>{h(i.doc.source.reverse?e.reverse():e)}).catch(e=>{h([])}).finally(()=>{S(!1)})},A=e=>{P.current=e,O?L(e):(k(e),R(!0))};return c.useEffect(()=>(D?.on("mergedFilterChanged",A),()=>{D?.off("mergedFilterChanged",A)}),[D,l,i,O]),c.useEffect(()=>{O&&E&&L(C)},[O,E]),c.useEffect(()=>{R(!0)},[o.params]),c.createElement(Yr,{ref:I,elevation:0,style:{borderRadius:12,padding:20,border:"1px solid #e5e5e5",background:"#fff",display:"flex",flexDirection:"column",gap:"12px",height:"100%"}},i&&c.createElement("div",{style:{display:"flex",alignItems:"center",lineHeight:0}},c.createElement(si,{variant:"subtitle2",style:{fontWeight:600,color:"#252525"}},o?.title||i.doc.name," ")),x?c.createElement(Wa,{style:{display:"flex",justifyContent:"center",alignItems:"center",height:"100%",width:"100%"}}):c.createElement(c.Fragment,null,c.createElement("div",{style:{display:"flex"}},c.createElement("div",{style:{flexGrow:1}}),c.createElement("div",null,i?.doc?.view?.length>1&&c.createElement(Vi,null,c.createElement(Ha,{labelId:"date-range-select-label",id:"date-range-select",value:y,onChange:F,style:{fontSize:"12px"},disableUnderline:!0},i.doc.view.map((e,t)=>c.createElement(Ea,{key:t,value:t},e.title)))))),c.createElement("div",{style:{position:"relative",flexGrow:n?void 0:1,display:"flex",flexDirection:"column"}},c.createElement(pR,{filters:i?.doc?.filters,channel:D,query:M}),m)))};const wR=s.createContext(void 0),xR=({defaultParameters:e={},defaultApi:t={},children:n})=>{const[r,o]=s.useState(e),[i,a]=s.useState(t),l={parameters:r,setParameters:o,api:i,setApi:a,setReportingContext:({parameters:e,api:t})=>{void 0!==e&&o(e),void 0!==t&&a(t)}};return c.createElement(wR.Provider,{value:l},n)},SR=()=>s.useContext(wR);const CR=s.createContext(),kR=({children:e})=>{const[t,n]=s.useState({open:!1,message:"",severity:"info",duration:6e3}),r=(e,t="info",r=6e3)=>{n({open:!0,message:e,severity:t,duration:r})},o=(e,t)=>{"clickaway"!==t&&n(e=>({...e,open:!1}))},i={success:(e,t)=>r(e,"success",t),error:(e,t)=>r(e,"error",t),warning:(e,t)=>r(e,"warning",t),info:(e,t)=>r(e,"info",t)};return c.createElement(CR.Provider,{value:i},e,c.createElement(Dk,{open:t.open,autoHideDuration:t.duration,onClose:o,anchorOrigin:{vertical:"top",horizontal:"right"}},c.createElement(jv,{onClose:o,severity:t.severity,variant:"filled",sx:{width:"100%"}},t.message)))},ER=()=>{const e=s.useContext(CR);if(!e)throw new Error("useNotify must be used within a NotifyProvider");return e};function RR(e){var t,n,r="";if("string"==typeof e||"number"==typeof e)r+=e;else if("object"==typeof e)if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(n=RR(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function PR(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=RR(e))&&(r&&(r+=" "),r+=t);return r}var MR=parseInt(s.version,10);const TR=e=>{if(MR>=19){const t=t=>e(t,t.ref??null);return t.displayName=e.displayName??e.name,t}return s.forwardRef(e)},IR=Sg,OR=IR(Xp.jsx("path",{d:"M4 12l1.41 1.41L11 7.83V20h2V7.83l5.58 5.59L20 12l-8-8-8 8z"})),DR=IR(Xp.jsx("path",{d:"M20 12l-1.41-1.41L13 16.17V4h-2v12.17l-5.58-5.59L4 12l8 8 8-8z"})),FR=IR(Xp.jsx("path",{d:"M8.59 16.59 13.17 12 8.59 7.41 10 6l6 6-6 6-1.41-1.41z"})),LR=IR(Xp.jsx("path",{d:"M16.59 8.59 12 13.17 7.41 8.59 6 10l6 6 6-6z"})),AR=IR(Xp.jsx("path",{d:"M10 18h4v-2h-4v2zM3 6v2h18V6H3zm3 7h12v-2H6v2z"})),NR=IR(Xp.jsx("path",{d:"M4.25 5.61C6.27 8.2 10 13 10 13v6c0 .55.45 1 1 1h2c.55 0 1-.45 1-1v-6s3.72-4.8 5.74-7.39c.51-.66.04-1.61-.79-1.61H5.04c-.83 0-1.3.95-.79 1.61z"})),$R=IR(Xp.jsx("path",{d:"M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z"}));IR(Xp.jsx("path",{d:"M3 18h18v-2H3v2zm0-5h18v-2H3v2zm0-7v2h18V6H3z"})),IR(Xp.jsx("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-2 15l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z"}));const zR=IR(Xp.jsx("path",{d:"M14.67 5v14H9.33V5zm1 14H21V5h-5.33zm-7.34 0V5H3v14z"})),jR=IR(Xp.jsx("rect",{width:"1",height:"24",x:"11.5",rx:"0.5"})),BR=IR(Xp.jsx("path",{d:"M4 15h16v-2H4v2zm0 4h16v-2H4v2zm0-8h16V9H4v2zm0-6v2h16V5H4z"})),_R=IR(Xp.jsx("path",{d:"M21,8H3V4h18V8z M21,10H3v4h18V10z M21,16H3v4h18V16z"})),HR=IR(Xp.jsx("path",{d:"M4 18h17v-6H4v6zM4 5v6h17V5H4z"})),VR=IR(Xp.jsx("path",{d:"M12 8c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm0 2c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0 6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"})),WR=IR(Xp.jsx("path",{d:"M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"})),UR=IR(Xp.jsx("path",{d:"M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6v2z"})),GR=IR(Xp.jsx("path",{d:"M19 13H5v-2h14v2z"})),KR=IR(Xp.jsx("path",{d:"M12 4V1L8 5l4 4V6c3.31 0 6 2.69 6 6 0 1.01-.25 1.97-.7 2.8l1.46 1.46C19.54 15.03 20 13.57 20 12c0-4.42-3.58-8-8-8zm0 14c-3.31 0-6-2.69-6-6 0-1.01.25-1.97.7-2.8L5.24 7.74C4.46 8.97 4 10.43 4 12c0 4.42 3.58 8 8 8v3l4-4-4-4v3z"})),qR=IR(Xp.jsx("path",{d:"M11 18c0 1.1-.9 2-2 2s-2-.9-2-2 .9-2 2-2 2 .9 2 2zm-2-8c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0-6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm6 4c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm0 2c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0 6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"})),YR=IR(Xp.jsx("path",{d:"M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"})),XR=IR(Xp.jsx("path",{d:"M12 8c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm0 2c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0 6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"})),QR=IR(Xp.jsx("path",{d:"M12 7c2.76 0 5 2.24 5 5 0 .65-.13 1.26-.36 1.83l2.92 2.92c1.51-1.26 2.7-2.89 3.43-4.75-1.73-4.39-6-7.5-11-7.5-1.4 0-2.74.25-3.98.7l2.16 2.16C10.74 7.13 11.35 7 12 7zM2 4.27l2.28 2.28.46.46C3.08 8.3 1.78 10.02 1 12c1.73 4.39 6 7.5 11 7.5 1.55 0 3.03-.3 4.38-.84l.42.42L19.73 22 21 20.73 3.27 3 2 4.27zM7.53 9.8l1.55 1.55c-.05.21-.08.43-.08.65 0 1.66 1.34 3 3 3 .22 0 .44-.03.65-.08l1.55 1.55c-.67.33-1.41.53-2.2.53-2.76 0-5-2.24-5-5 0-.79.2-1.53.53-2.2zm4.31-.78l3.15 3.15.02-.16c0-1.66-1.34-3-3-3l-.17.01z"})),ZR=IR(Xp.jsx("g",{children:Xp.jsx("path",{d:"M14.67,5v14H9.33V5H14.67z M15.67,19H21V5h-5.33V19z M8.33,19V5H3v14H8.33z"})})),JR=IR(Xp.jsx("path",{d:"M12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2m5 13.59L15.59 17 12 13.41 8.41 17 7 15.59 10.59 12 7 8.41 8.41 7 12 10.59 15.59 7 17 8.41 13.41 12z"}));IR(Xp.jsx("path",{d:"M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6v12zM19 4h-3.5l-1-1h-5l-1 1H5v2h14V4z"}));const eP=IR(Xp.jsx("path",{d:"M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6v12zm2.46-7.12l1.41-1.41L12 12.59l2.12-2.12 1.41 1.41L13.41 14l2.12 2.12-1.41 1.41L12 15.41l-2.12 2.12-1.41-1.41L10.59 14l-2.13-2.12zM15.5 4l-1-1h-5l-1 1H5v2h14V4z"})),tP=IR(Xp.jsx("path",{d:"M5 20h14v-2H5zM19 9h-4V3H9v6H5l7 7z"})),nP=s.createContext(void 0),rP=()=>{const e=s.useContext(nP);if(!e)throw new Error("MUI X: useGridRootProps should only be used inside the DataGrid, DataGridPro or DataGridPremium component.");return e},oP=["sortingOrder"],iP=s.memo(function(e){const{sortingOrder:t}=e,n=d(e,oP),r=rP(),[o]=t,i="asc"===o?r.slots.columnSortedAscendingIcon:r.slots.columnSortedDescendingIcon;return i?Xp.jsx(i,f({},n)):null}),aP=s.createContext(void 0);function lP(){const e=s.useContext(aP);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 sP=new TextEncoder;let cP=2048,uP=new ArrayBuffer(cP),dP=new Uint8Array(uP),pP=new Int32Array(uP);const fP=function(e){const t=2*e.length;t>cP&&(cP=t+(4-t%4),uP=new ArrayBuffer(cP),dP=new Uint8Array(uP),pP=new Int32Array(uP));const n=sP.encodeInto(e,dP).written,r=0|n;let o=0,i=374761393+(0+r|0)|0;if(r<16)for(;(o+3|0)<r;o=o+4|0)i=Math.imul(0|hP(i+Math.imul(0|pP[o],3266489917)|0,17),668265263);else{let e=606290984,t=-2048144777,n=0,a=1640531535;for(;(o+15|0)<r;o=o+16|0)e=Math.imul(0|hP(e+Math.imul(0|pP[o+0|0],2246822519)|0,13),2654435761),t=Math.imul(0|hP(t+Math.imul(0|pP[o+4|0],2246822519)|0,13),2654435761),n=Math.imul(0|hP(n+Math.imul(0|pP[o+8|0],2246822519)|0,13),2654435761),a=Math.imul(0|hP(a+Math.imul(0|pP[o+12|0],2246822519)|0,13),2654435761);for(i=(((hP(e,1)|0+hP(t,7)|0)+hP(n,12)|0)+hP(a,18)|0)+r|0;(o+3|0)<r;o=o+4|0)i=Math.imul(0|hP(i+Math.imul(0|pP[o],3266489917)|0,17),668265263)}for(;o<r;o=o+1|0)i=Math.imul(0|hP(i+Math.imul(0|dP[o],374761393)|0,11),2654435761);return i=Math.imul(i^i>>>15,2246822519),i=Math.imul(i^i>>>13,3266489917),((i^i>>>16)>>>0).toString()};function hP(e,t){return e<<t|e>>>32-t}const mP={values:{xs:0,sm:600,md:900,lg:1200,xl:1536},up:e=>{const t=mP.values;return`@media (min-width:${"number"==typeof t[e]?t[e]:e}px)`}},gP={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"}},vP=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}(gP),bP=f({breakpoints:mP,spacing:function(e,t,n,r){if(void 0===e)return yP(1);if(void 0===t)return yP(e);if(void 0===n)return yP(e)+" "+yP(t);if(void 0===r)return yP(e)+" "+yP(t)+" "+yP(n);return yP(e)+" "+yP(t)+" "+yP(n)+" "+yP(r)},transition:function(e,t){const{duration:n=bP.transitions.duration.base,easing:r=bP.transitions.easing.easeInOut,delay:o=0}=t??{};return e.map(e=>`${e} ${n} ${r} ${o}ms`).join(", ")},keys:gP},vP);function yP(e){return 0===e?"0":`calc(var(--DataGrid-t-spacing-unit) * ${e})`}function wP(e){return function(e,t){return`rgba(from ${e} r g b / ${t})`}(e,1)}function xP(e){if(!e)return;const t="number"==typeof e.fontSize?`${e.fontSize}px`:e.fontSize;return`${e.fontWeight} ${t} / ${e.lineHeight} ${e.fontFamily}`}const SP=["id","label","labelId","material","disabled","slotProps","onChange","onKeyDown","onOpen","onClose","size","style","fullWidth"],CP=["onRowsPerPageChange","material","disabled"],kP=["material"],EP=["autoFocus","label","fullWidth","slotProps","className","material"],RP=["material"],PP=["material"],MP=["material"],TP=["material"],IP=["material"],OP=["material"],DP=["material"],FP=["material"],LP=["material"],AP=["material","label","className"],NP=["material"],$P=["inert","iconStart","iconEnd","children","material"],zP=["slotProps","material"],jP=["id","multiple","freeSolo","options","getOptionLabel","isOptionEqualToValue","value","onChange","label","placeholder","slotProps","material"],BP=["key"],_P=["inputProps","InputProps","InputLabelProps"],HP=["slotProps","material"],VP=["ref","open","children","className","clickAwayTouchEvent","clickAwayMouseEvent","flip","focusTrap","onExited","onClickAway","onDidShow","onDidHide","id","target","transition","placement","material"],WP=["native"],UP=["children","value","active"],GP=["items","value","material"],KP=pg(AS)(({theme:e})=>({[`&.${DS.positionEnd} .${Ev.sizeSmall}`]:{marginRight:e.spacing(-.75)}})),qP=pg(fS,{shouldForwardProp:e=>"fullWidth"!==e})(({theme:e})=>({gap:e.spacing(.5),margin:0,overflow:"hidden",[`& .${uS.label}`]:{fontSize:e.typography.pxToRem(14),overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},variants:[{props:{fullWidth:!0},style:{width:"100%"}}]})),YP=pg(ux,{shouldForwardProp:e=>"density"!==e})(({theme:e})=>({variants:[{props:{density:"compact"},style:{padding:e.spacing(.5)}}]})),XP=pg(vC)({[`& .${mC.primary}`]:{overflowX:"clip",textOverflow:"ellipsis",maxWidth:"300px"}}),QP=TR(function(e,t){const{id:n,label:r,labelId:o,material:i,disabled:a,slotProps:l,onChange:s,onKeyDown:c,onOpen:u,onClose:p,size:h,style:m,fullWidth:g}=e,v=d(e,SP),b={PaperProps:{onKeyDown:c}};return p&&(b.onClose=p),Xp.jsxs(sS,{size:h,fullWidth:g,style:m,disabled:a,ref:t,children:[Xp.jsx(zS,{id:o,htmlFor:n,shrink:!0,variant:"outlined",children:r}),Xp.jsx(vk,f({id:n,labelId:o,label:r,displayEmpty:!0,onChange:s,variant:"outlined"},v,{notched:!0,inputProps:l?.htmlInput,onOpen:u,MenuProps:b,size:h},i))]})}),ZP=pg(RE)(({theme:e})=>({[`& .${mE.selectLabel}`]:{display:"none",[e.breakpoints.up("sm")]:{display:"block"}},[`& .${mE.input}`]:{display:"none",[e.breakpoints.up("sm")]:{display:"inline-flex"}}})),JP=TR(function(e,t){const{onRowsPerPageChange:n,material:r,disabled:o}=e,i=d(e,CP),a=s.useMemo(()=>{if(o)return{backIconButtonProps:{disabled:!0},nextIconButtonProps:{disabled:!0}}},[o]),l=lP(),c=rP(),{estimatedRowCount:u}=c;return Xp.jsx(ZP,f({component:"div",onRowsPerPageChange:Mg(e=>{n?.(Number(e.target.value))}),labelRowsPerPage:l.current.getLocaleText("paginationRowsPerPage"),labelDisplayedRows:e=>l.current.getLocaleText("paginationDisplayedRows")(f({},e,{estimated:u})),getItemAriaLabel:l.current.getLocaleText("paginationItemAriaLabel")},a,i,r,{ref:t}))}),eM=TR(function(e,t){const{material:n}=e,r=d(e,kP);return Xp.jsx(Nw,f({},r,n,{ref:t}))}),tM=TR(function(e,t){const{autoFocus:n,label:r,fullWidth:o,slotProps:i,className:a,material:l}=e,c=d(e,EP),u=s.useRef(null),p=Tg(u,t),h=s.useRef(null);return s.useEffect(()=>{if(n){const e=u.current?.querySelector("input");e?.focus({preventScroll:!0})}else!1===n&&h.current&&h.current.stop({})},[n]),r?Xp.jsx(qP,{className:a,control:Xp.jsx(YP,f({},c,l,{inputProps:i?.htmlInput,ref:p,touchRippleRef:h})),label:r,fullWidth:o}):Xp.jsx(YP,f({},c,l,{className:PR(a,l?.className),inputProps:i?.htmlInput,ref:p,touchRippleRef:h}))}),nM=TR(function(e,t){const{material:n}=e,r=d(e,RP);return Xp.jsx(Cv,f({},r,n,{ref:t}))}),rM=TR(function(e,t){const{material:n}=e,r=d(e,PP);return Xp.jsx(nS,f({},r,n,{ref:t}))}),oM=TR(function(e,t){const{material:n}=e,r=d(e,MP);return Xp.jsx(QS,f({},r,n,{ref:t}))}),iM=TR(function(e,t){const{material:n}=e,r=d(e,TP);return Xp.jsx(Xw,f({},r,n,{ref:t}))}),aM=pg(tR)(({theme:e})=>({gap:e.spacing(1),border:0})),lM=TR(function(e,t){const{material:n}=e,r=d(e,IP);return Xp.jsx(aM,f({size:"small",color:"primary"},r,n,{ref:t}))}),sM=TR(function(e,t){const{material:n}=e,r=d(e,OP);return Xp.jsx(zy,f({},r,n,{ref:t}))}),cM=TR(function(e,t){const{material:n}=e,r=d(e,DP);return Xp.jsx(Mv,f({},r,n,{ref:t}))}),uM=TR(function(e,t){const{material:n}=e,r=d(e,FP);return Xp.jsx(Hk,f({},r,n,{ref:t}))}),dM=TR(function(e,t){const{material:n}=e,r=d(e,LP);return Xp.jsx(kk,f({},r,n,{ref:t}))}),pM=TR(function(e,t){const{material:n,label:r,className:o}=e,i=d(e,AP);return r?Xp.jsx(qP,{className:o,control:Xp.jsx(Yk,f({},i,n,{ref:t})),label:r}):Xp.jsx(Yk,f({},i,n,{className:o,ref:t}))}),fM=TR(function(e,t){const{material:n}=e,r=d(e,NP);return Xp.jsx(SC,f({},r,n,{ref:t}))});function hM(e,t=!0){if(!e)return;const{slotProps:n,material:r}=e,o=d(e,HP);t&&(o.startAdornment&&(o.startAdornment=Xp.jsx(KP,{position:"start",children:o.startAdornment})),o.endAdornment&&(o.endAdornment=Xp.jsx(KP,{position:"end",children:o.endAdornment})));for(const e in r)Object.hasOwn(r,e)&&(o[e]=r[e]);return n?.htmlInput&&(o.inputProps?o.inputProps=f({},o.inputProps,n?.htmlInput):o.inputProps=n?.htmlInput),o}const mM={"bottom-start":"top left","bottom-end":"top right"};function gM(e,t){return function(e,t){if(void 0===e.focusTrap)return t;return Xp.jsx(Cx,{open:!0,disableEnforceFocus:!0,disableAutoFocus:!0,children:Xp.jsx("div",{tabIndex:-1,children:t})})}(e,function(e,t){if(void 0===e.onClickAway)return t;return Xp.jsx(px,{onClickAway:e.onClickAway,touchEvent:e.clickAwayTouchEvent,mouseEvent:e.clickAwayMouseEvent,children:t})}(e,t))}const vM=pg(WE,{name:"MuiDataGrid",slot:"Tabs"})(({theme:e})=>({borderBottom:`1px solid ${e.palette.divider}`})),bM=pg(Jk,{name:"MuiDataGrid",slot:"Tab"})({flex:1,minWidth:"fit-content"}),yM=pg("div",{name:"MuiDataGrid",slot:"TabPanel"})({flex:1,display:"flex",flexDirection:"column",overflow:"hidden"});function wM(e){const{children:t,active:n}=e,r=d(e,UP);return Xp.jsx(yM,f({role:"tabpanel",style:{display:n?"flex":"none"}},r,{children:t}))}const xM={baseAutocomplete:function(e){const t=rP(),{id:n,multiple:r,freeSolo:o,options:i,getOptionLabel:a,isOptionEqualToValue:l,value:s,onChange:c,label:u,placeholder:p,slotProps:h,material:m}=e,g=d(e,jP);return Xp.jsx(Ew,f({id:n,multiple:r,freeSolo:o,options:i,getOptionLabel:a,isOptionEqualToValue:l,value:s,onChange:c,renderTags:(e,t)=>e.map((e,n)=>{const r=t({index:n}),{key:o}=r,i=d(r,BP);return Xp.jsx(zy,f({variant:"outlined",size:"small",label:"string"==typeof e?e:a?.(e)},i),o)}),renderInput:e=>{const{inputProps:n,InputProps:r,InputLabelProps:o}=e,i=d(e,_P);return Xp.jsx(qE,f({},i,{label:u,placeholder:p,inputProps:n,InputProps:hM(r,!1),InputLabelProps:f({shrink:!0},o)},h?.textField,t.slotProps?.baseTextField))}},g,m))},baseBadge:eM,baseCheckbox:tM,baseChip:sM,baseCircularProgress:nM,baseDivider:rM,baseInput:function(e){return Xp.jsx(nw,f({},hM(e)))},baseLinearProgress:oM,baseMenuList:fM,baseMenuItem:function(e){const{inert:t,iconStart:n,iconEnd:r,children:o,material:i}=e,a=d(e,$P);return t&&(a.disableRipple=!0),s.createElement(_C,f({},a,i),[n&&Xp.jsx(fC,{children:n},"1"),Xp.jsx(XP,{children:o},"2"),r&&Xp.jsx(fC,{children:r},"3")])},baseTextField:function(e){const{slotProps:t,material:n}=e,r=d(e,zP);return Xp.jsx(qE,f({variant:"outlined"},r,n,{inputProps:t?.htmlInput,InputProps:hM(t?.input),InputLabelProps:f({shrink:!0},t?.inputLabel)}))},baseButton:iM,baseIconButton:cM,baseToggleButton:lM,baseTooltip:uM,baseTabs:function(e){let{items:t,value:n,material:r}=e,o=d(e,GP);const i=mm(),a=`${i}-tab-${n}`,l=`${i}-tabpanel-${n}`;return Xp.jsxs(s.Fragment,{children:[Xp.jsx(vM,f({},o,{value:n,variant:"scrollable",scrollButtons:"auto"},r,{children:t.map(e=>Xp.jsx(bM,{value:e.value,label:e.label,id:a,"aria-controls":l},e.value))})),t.map(e=>Xp.jsx(wM,{value:e.value,active:n===e.value,id:l,"aria-labelledby":a,children:e.children},e.value))]})},basePagination:JP,basePopper:function(e){const{open:t,children:n,className:r,flip:o,onExited:i,onDidShow:a,onDidHide:l,id:c,target:u,transition:p,placement:h,material:m}=e,g=d(e,VP),v=s.useMemo(()=>{const e=[{name:"preventOverflow",options:{padding:8}}];return o&&e.push({name:"flip",enabled:!0}),(a||l)&&e.push({name:"isPlaced",enabled:!0,phase:"main",fn:()=>{a?.()},effect:()=>()=>{l?.()}}),e},[o,a,l]);let b;if(p){const t=e=>t=>{e&&e(),i&&i(t)};b=r=>gM(e,Xp.jsx(PS,f({},r.TransitionProps,{style:{transformOrigin:mM[r.placement]},onExited:t(r.TransitionProps?.onExited),children:Xp.jsx(qg,{children:n})})))}else b=gM(e,n);return Xp.jsx(My,f({id:c,className:r,open:t,anchorEl:u,transition:p,placement:h,modifiers:v},g,m,{children:b}))},baseSelect:QP,baseSelectOption:function(e){let{native:t}=e,n=d(e,WP);return t?Xp.jsx("option",f({},n)):Xp.jsx(_C,f({},n))},baseSkeleton:dM,baseSwitch:pM},SM=f({},xM,{booleanCellTrueIcon:YR,booleanCellFalseIcon:WR,columnMenuIcon:VR,openFilterButtonIcon:AR,filterPanelDeleteIcon:WR,columnFilteredIcon:NR,columnSelectorIcon:zR,columnUnsortedIcon:iP,columnSortedAscendingIcon:OR,columnSortedDescendingIcon:DR,columnResizeIcon:jR,densityCompactIcon:BR,densityStandardIcon:_R,densityComfortableIcon:HR,exportIcon:tP,moreActionsIcon:XR,treeDataCollapseIcon:LR,treeDataExpandIcon:FR,groupingCriteriaCollapseIcon:LR,groupingCriteriaExpandIcon:FR,detailPanelExpandIcon:UR,detailPanelCollapseIcon:GR,rowReorderIcon:qR,quickFilterIcon:$R,quickFilterClearIcon:JR,columnMenuHideIcon:QR,columnMenuSortAscendingIcon:OR,columnMenuSortDescendingIcon:DR,columnMenuUnsortIcon:null,columnMenuFilterIcon:NR,columnMenuManageColumnsIcon:ZR,columnMenuClearIcon:JR,loadIcon:KR,filterPanelAddIcon:UR,filterPanelRemoveAllIcon:eP,columnReorderIcon:qR,menuItemCheckIcon:YR});var CM=Symbol("NOT_FOUND");var kM=e=>Array.isArray(e)?e:[e];function EM(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}var RM=(e,t)=>e===t;function PM(e,t){const n="object"==typeof t?t:{equalityCheck:t},{equalityCheck:r=RM,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:CM,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 CM}return{get:r,put:function(t,o){r(t)===CM&&(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===CM){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 MM="undefined"!=typeof WeakRef?WeakRef:class{constructor(e){this.value=e}deref(){return this.value}};function TM(){return{s:0,v:void 0,o:null,p:null}}function IM(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=TM(),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=TM(),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=o?.deref?.()??o;null!=e&&r(e,s)&&(s=e,0!==i&&i--);o="object"==typeof s&&null!==s||"function"==typeof s?new MM(s):s}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}function OM(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=IM,argsMemoizeOptions:d=[]}=l,p=kM(c),f=kM(d),h=EM(e),m=s(function(){return r++,a.apply(null,arguments)},...p),g=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=m.apply(null,e),t},...f);return Object.assign(g,{resultFunc:a,memoizedResultFunc:m,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}var DM=OM(IM),FM=Object.assign((e,t=DM)=>{!function(e,t="expected an object, instead received "+typeof e){if("object"!=typeof e)throw new TypeError(t)}(e,"createStructuredSelector expects first argument to be an object where each property is a selector, instead received a "+typeof e);const n=Object.keys(e),r=n.map(t=>e[t]),o=t(r,(...e)=>e.reduce((e,t,r)=>(e[n[r]]=t,e),{}));return o},{withTypes:()=>FM});const LM=OM({memoize:PM,memoizeOptions:{maxSize:1,equalityCheck:Object.is}}),AM=(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 p=e(s,c,u,d),f=t(s,c,u,d),h=n(s,c,u,d),m=r(s,c,u,d),g=o(s,c,u,d),v=i(s,c,u,d),b=a(s,c,u,d);return l(p,f,h,m,g,v,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),p=t(l,s,c,u),f=n(l,s,c,u),h=r(l,s,c,u),m=o(l,s,c,u),g=i(l,s,c,u);return a(d,p,f,h,m,g,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),p=n(a,l,s,c),f=r(a,l,s,c),h=o(a,l,s,c);return i(u,d,p,f,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),p=r(i,a,l,s);return o(c,u,d,p,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},NM=(...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=LM(...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")}}};var $M,zM,jM={exports:{}},BM={};function _M(){return zM||(zM=1,jM.exports=function(){if($M)return BM;$M=1;var e=l(),t="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},n=e.useState,r=e.useEffect,o=e.useLayoutEffect,i=e.useDebugValue;function a(e){var n=e.getSnapshot;e=e.value;try{var r=n();return!t(e,r)}catch(e){return!0}}var s="undefined"==typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t){return t()}:function(e,t){var l=t(),s=n({inst:{value:l,getSnapshot:t}}),c=s[0].inst,u=s[1];return o(function(){c.value=l,c.getSnapshot=t,a(c)&&u({inst:c})},[e,l,t]),r(function(){return a(c)&&u({inst:c}),e(function(){a(c)&&u({inst:c})})},[e]),i(l),l};return BM.useSyncExternalStore=void 0!==e.useSyncExternalStore?e.useSyncExternalStore:s,BM}()),jM.exports}var HM,VM,WM=_M(),UM={exports:{}},GM={};var KM=(VM||(VM=1,UM.exports=function(){if(HM)return GM;HM=1;var e=l(),t=_M(),n="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},r=t.useSyncExternalStore,o=e.useRef,i=e.useEffect,a=e.useMemo,s=e.useDebugValue;return GM.useSyncExternalStoreWithSelector=function(e,t,l,c,u){var d=o(null);if(null===d.current){var p={hasValue:!1,value:null};d.current=p}else p=d.current;d=a(function(){function e(e){if(!i){if(i=!0,r=e,e=c(e),void 0!==u&&p.hasValue){var t=p.value;if(u(t,e))return o=t}return o=e}if(t=o,n(r,e))return t;var a=c(e);return void 0!==u&&u(t,a)?(r=e,t):(r=e,o=a)}var r,o,i=!1,a=void 0===l?null:l;return[function(){return e(t())},null===a?void 0:function(){return e(a())}]},[t,l,c,u]);var f=r(e,d[0],d[1]);return i(function(){p.hasValue=!0,p.value=f},[f]),s(f),f},GM}()),UM.exports);const qM=MR>=19?function(e,t,n,r,o){const i=s.useCallback(()=>t(e.getSnapshot(),n,r,o),[e,t,n,r,o]);return WM.useSyncExternalStore(e.subscribe,i,i)}:function(e,t,n,r,o){return KM.useSyncExternalStoreWithSelector(e.subscribe,e.getSnapshot,e.getSnapshot,e=>t(e,n,r,o))};function YM(e,t,n,r,o){return qM(e,t,n,r,o)}const XM=()=>{};function QM(e,t,n){const r=Dg(ZM,{store:e,selector:t}).current;r.effect=n,Lg(r.onMount)}function ZM(e){const{store:t,selector:n}=e;let r=n(t.state);const o={effect:XM,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}class JM{static create(e){return new JM(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(f({},this.state,e))}set(e,t){Object.is(this.state[e],t)||this.setState(f({},this.state,{[e]:t}))}use=(()=>(e,t,n,r)=>YM(this,e,t,n,r))()}const eT=(...e)=>{const t=AM(...e);return(e,n,r,o)=>t(rT(e),n,r,o)},tT=(...e)=>{const t=NM(...e);return(e,n,r,o)=>t(rT(e),n,r,o)},nT=e=>(t,n)=>e(rT(t),n);function rT(e){return"current"in e?e.current.state:e}const oT=nT(e=>e.dimensions),iT=eT(oT,e=>e.columnsTotalWidth),aT=eT(oT,e=>e.rowHeight);eT(oT,e=>e.contentSize.height);const lT=eT(oT,e=>e.hasScrollX),sT=eT(oT,e=>e.hasScrollY),cT=eT(oT,e=>e.columnsTotalWidth<e.viewportOuterSize.width),uT=eT(oT,e=>e.headerHeight),dT=eT(oT,e=>e.groupHeaderHeight);eT(oT,e=>e.headerFilterHeight);const pT=eT(oT,e=>e.hasScrollX?e.scrollbarSize:0),fT=eT(oT,e=>e.hasScrollY?e.scrollbarSize:0),hT=eT(oT,pT,(e,t)=>{const n=e.viewportOuterSize.height-e.minimumSize.height>0;return!(0===t&&!n)}),mT=nT(e=>e.rowsMeta),gT=nT(e=>e.rows),vT=eT(gT,e=>e.totalRowCount),bT=eT(gT,e=>e.loading),yT=eT(gT,e=>e.totalTopLevelRowCount),wT=eT(gT,e=>e.dataRowIdToModelLookup);eT(wT,(e,t)=>e[t]);const xT=eT(gT,e=>e.tree),ST=eT(xT,(e,t)=>e[t]),CT=eT(gT,e=>e.groupsToFetch),kT=eT(gT,e=>e.groupingName),ET=eT(gT,e=>e.treeDepths),RT=tT(gT,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}),PT=eT(gT,e=>e.dataRowIds),MT=tT(PT,wT,(e,t)=>e.reduce((e,n)=>t[n]?(e.push(t[n]),e):e,[])),TT=tT(eT(gT,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??{}}))??[]}}),IT=eT(TT,e=>(e?.top?.length||0)+(e?.bottom?.length||0)),OT="auto-generated-group-node-root",DT=Symbol("mui.id_autogenerated");const FT=(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},LT=(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)},AT=({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=FT(r,t);i[a]=r,o.rows.push(a)}return{rowsBeforePartialUpdates:e,loadingPropBeforePartialUpdates:n,rowCountPropBeforePartialUpdates:r,updates:o,dataRowIdToModelLookup:i}},NT=({tree:e,rowCountProp:t=0})=>{const n=e[OT];return Math.max(t,n.children.length+(null==n.footerId?0:1))},$T=({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}),p=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:{}},f({},p,{totalRowCount:Math.max(t,p.dataRowIds.length),totalTopLevelRowCount:NT({tree:p.tree,rowCountProp:t}),groupingName:u,loading:n,groupsToFetch:d})},zT=e=>DT in e,jT=e=>"skeletonRow"===e.type||"footer"===e.type||"group"===e.type&&e.isAutoGenerated||"pinnedRow"===e.type&&e.isAutoGenerated,BT=(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&&jT(e[a])||i.push(a),r)continue;const l=BT(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},_T=({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=FT(e,t,"A row was provided without id when calling updateRows():");o.has(n)?o.set(n,f({},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:f({},e.updates.idToActionLookup),groupKeys:r},a=f({},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]=f({},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}},HT="var(--DataGrid-overlayHeight, calc(var(--height) * 2))";function VT(e,t,n){const r=[];return t.forEach(t=>{const o=FT(t,n,"A row was provided without id when calling updateRows():"),i=ST(e,o);if("pinnedRow"===i?.type){const n=e.current.caches.pinnedRows,r=n.idLookup[o];r&&(n.idLookup[o]=f({},r,t))}else r.push(t)}),r}const WT=(e,t,n)=>"number"==typeof e&&e>0?e:t,UT=Object.is;function GT(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,!UT(e[r],t[r]))return!1;if(!(r in t))return!1}for(const e in t)r+=1;return n===r}function KT(e){return s.memo(e,GT)}const qT={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",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",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})=>{if(!r)return`${e}–${t} of ${-1!==n?n:`more than ${t}`}`;return`${e}–${t} of ${-1!==n?n:r&&r>t?`around ${r}`:`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})`};function YT(e){return Ph("MuiDataGrid",e)}const XT=Mh("MuiDataGrid",["aiAssistantPanel","aiAssistantPanelHeader","aiAssistantPanelTitleContainer","aiAssistantPanelTitle","aiAssistantPanelBody","aiAssistantPanelEmptyText","aiAssistantPanelFooter","aiAssistantPanelConversation","aiAssistantPanelConversationList","aiAssistantPanelConversationTitle","aiAssistantPanelSuggestions","aiAssistantPanelSuggestionsList","aiAssistantPanelSuggestionsItem","aiAssistantPanelSuggestionsLabel","actionsCell","aggregationColumnHeader","aggregationColumnHeader--alignLeft","aggregationColumnHeader--alignCenter","aggregationColumnHeader--alignRight","aggregationColumnHeaderLabel","aggregationRowOverlayWrapper","autoHeight","autosizing","mainContent","withSidePanel","booleanCell","cell--editable","cell--editing","cell--flex","cell--textCenter","cell--textLeft","cell--textRight","cell--rangeTop","cell--rangeBottom","cell--rangeLeft","cell--rangeRight","cell--pinnedLeft","cell--pinnedRight","cell--selectionMode","cell","cellCheckbox","cellEmpty","cellSkeleton","cellOffsetLeft","checkboxInput","collapsible","collapsibleTrigger","collapsibleIcon","collapsiblePanel","columnHeader","columnHeader--alignCenter","columnHeader--alignLeft","columnHeader--alignRight","columnHeader--dragging","columnHeader--moving","columnHeader--numeric","columnHeader--sortable","columnHeader--sorted","columnHeader--filtered","columnHeader--pinnedLeft","columnHeader--pinnedRight","columnHeader--last","columnHeader--siblingFocused","columnHeader--filter","columnHeaderFilterInput","columnHeaderFilterOperatorLabel","columnHeaderCheckbox","columnHeaderDraggableContainer","columnHeaderTitle","columnHeaderTitleContainer","columnHeaderTitleContainerContent","columnHeader--filledGroup","columnHeader--emptyGroup","columnHeaders","columnSeparator--resizable","columnSeparator--resizing","columnSeparator--sideLeft","columnSeparator--sideRight","columnSeparator","columnsManagement","columnsManagementRow","columnsManagementHeader","columnsManagementSearchInput","columnsManagementFooter","columnsManagementScrollArea","columnsManagementEmptyText","container--top","container--bottom","detailPanel","detailPanelToggleCell","detailPanelToggleCell--expanded","footerCell","panel","panelHeader","panelWrapper","panelContent","panelFooter","paper","editBooleanCell","editInputCell","filler","filler--borderBottom","filler--pinnedLeft","filler--pinnedRight","filterForm","filterFormDeleteIcon","filterFormLogicOperatorInput","filterFormColumnInput","filterFormOperatorInput","filterFormValueInput","filterIcon","footerContainer","headerFilterRow","iconButtonContainer","iconSeparator","main","main--hasPinnedRight","main--hiddenContent","menu","menuIcon","menuIconButton","menuOpen","menuList","overlay","overlayWrapper","overlayWrapperInner","root","root--densityStandard","root--densityComfortable","root--densityCompact","root--disableUserSelection","root--noToolbar","row","row--editable","row--editing","row--firstVisible","row--lastVisible","row--dragging","row--beingDragged","row--dynamicHeight","row--detailPanelExpanded","row--borderBottom","rowReorderCellPlaceholder","rowCount","rowReorderCellContainer","rowReorderCell","rowReorderCell--draggable","rowReorderIcon","rowSkeleton","scrollArea--left","scrollArea--right","scrollArea--up","scrollArea--down","scrollArea","scrollbar","scrollbar--vertical","scrollbar--horizontal","scrollbarFiller","scrollbarFiller--pinnedRight","scrollShadow","scrollShadow--vertical","scrollShadow--horizontal","selectedRowCount","sortButton","sortIcon","shadowScrollArea","sidebar","sidebarHeader","toolbarContainer","toolbar","toolbarLabel","toolbarDivider","toolbarFilterList","toolbarQuickFilter","toolbarQuickFilterTrigger","toolbarQuickFilterControl","virtualScroller","virtualScroller--hasScrollX","virtualScrollerContent","virtualScrollerContent--overflowed","virtualScrollerRenderZone","withVerticalBorder","withBorderColor","cell--withRightBorder","cell--withLeftBorder","columnHeader--withRightBorder","columnHeader--withLeftBorder","treeDataGroupingCell","treeDataGroupingCellToggle","treeDataGroupingCellLoadingContainer","groupingCriteriaCell","groupingCriteriaCellToggle","groupingCriteriaCellLoadingContainer","pinnedRows","pinnedRows--top","pinnedRows--bottom","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"]);let QT=function(e){return e.DataGrid="DataGrid",e.DataGridPro="DataGridPro",e.DataGridPremium="DataGridPremium",e}({});class ZT{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 JT{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 eI{static create(){return new eI}}const tI={current:"undefined"!=typeof FinalizationRegistry?new JT:new ZT};let nI=0;function rI(e,t,n,r){const o=s.useState(eI.create)[0],i=s.useRef(null),a=s.useRef(null);a.current=n;const l=s.useRef(null);if(!i.current&&a.current){const n=(e,t,n)=>{t&&!t.defaultMuiPrevented&&a.current?.(e,t,n)};i.current=e.current.subscribeEvent(t,n,r),nI+=1,l.current={cleanupToken:nI},tI.current.register(o,()=>{i.current?.(),i.current=null,l.current=null},l.current)}else!a.current&&i.current&&(i.current(),i.current=null,l.current&&(tI.current.unregister(l.current),l.current=null));s.useEffect(()=>{if(!i.current&&a.current){const n=(e,t,n)=>{t&&!t.defaultMuiPrevented&&a.current?.(e,t,n)};i.current=e.current.subscribeEvent(t,n,r)}return l.current&&tI.current&&(tI.current.unregister(l.current),l.current=null),()=>{i.current?.(),i.current=null}},[e,t,r])}const oI={isFirst:!0};function iI(e,t,n){rI(e,t,n,oI)}const aI=Object.is,lI=GT,sI=(e,t)=>e===t||e.length===t.length&&e.every((e,n)=>e===t[n]),cI=()=>({state:null,equals:null,selector:null,args:void 0}),uI=[],dI=()=>null;function pI(e,t,n=void 0,r=aI){e.current.state;const o=Dg(cI),i=null!==o.current.selector,[a,l]=s.useState(i?null:t(e,n));o.current.state=a,o.current.equals=r,o.current.selector=t;const c=o.current.args;if(o.current.args=n,i&&!((e,t)=>{let n=Object.is;return t instanceof Array?n=sI:t instanceof Object&&(n=lI),n(e,t)})(c,n)){const t=o.current.selector(e,o.current.args);o.current.equals(o.current.state,t)||(o.current.state=t,l(t))}const u=s.useCallback(()=>(o.current.subscription||(o.current.subscription=e.current.store.subscribe(()=>{const t=o.current.selector(e,o.current.args);o.current.equals(o.current.state,t)||(o.current.state=t,l(t))})),null),uI),d=s.useCallback(()=>(o.current.subscription||u(),()=>{o.current.subscription&&(o.current.subscription(),o.current.subscription=void 0)}),uI);return WM.useSyncExternalStore(d,u,dI),a}const fI={compact:.7,comfortable:1.3,standard:1},hI=nT(e=>e.density),mI=eT(hI,e=>fI[e]);function gI(e){throw new Error("Failed assertion: should not be rendered")}const vI=["id","value","formattedValue","api","field","row","rowNode","colDef","cellMode","isEditable","tabIndex","hasFocus","isValidating","debounceMs","isProcessingProps","onValueChange","slotProps"],bI=pg(gI,{name:"MuiDataGrid",slot:"EditInputCell"})({font:bP.typography.font.body,padding:"1px 0","& input":{padding:"0 16px",height:"100%"}}),yI=TR((e,t)=>{const n=rP(),{id:r,value:o,field:i,colDef:a,hasFocus:l,debounceMs:c=200,isProcessingProps:u,onValueChange:p,slotProps:h}=e,m=d(e,vI),g=lP(),v=s.useRef(null),[b,y]=s.useState(o),w=(e=>{const{classes:t}=e;return wm({root:["editInputCell"]},YT,t)})(n),x=s.useCallback(async e=>{const t=e.target.value,n=g.current.getColumn(i);let o=t;n.valueParser&&(o=n.valueParser(t,g.current.getRow(r),n,g)),y(o),g.current.setEditCellValue({id:r,field:i,value:o,debounceMs:c,unstable_skipValueParser:!0},e),p&&await p(e,t)},[g,c,i,r,p]),S=g.current.unstable_getEditCellMeta(r,i);return s.useEffect(()=>{"debouncedSetEditCellValue"!==S?.changeReason&&y(o)},[S,o]),Wh(()=>{l&&v.current.focus()},[l]),Xp.jsx(bI,f({as:n.slots.baseInput,inputRef:v,className:w.root,ownerState:n,fullWidth:!0,type:"number"===a.type?a.type:"text",value:b??"",onChange:x,endAdornment:u?Xp.jsx(n.slots.loadIcon,{fontSize:"small",color:"action"}):void 0},m,h?.root,{ref:t}))}),wI=(e,t)=>t&&e.length>1?[e[0]]:e,xI=(e,t)=>n=>f({},n,{sorting:f({},n.sorting,{sortModel:wI(e,t)})}),SI=(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:ST(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)},CI=(e,t)=>{const n=e.indexOf(t);return t&&-1!==n&&n+1!==e.length?e[n+1]:e[0]},kI=(e,t)=>null==e&&null!=t?-1:null==t&&null!=e?1:null==e&&null==t?0:null,EI=new Intl.Collator,RI=(e,t)=>{const n=kI(e,t);return null!==n?n:Number(e)-Number(t)},PI=(e,t)=>{const n=kI(e,t);return null!==n?n:e>t?1:e<t?-1:0},MI=["item","applyValue","type","apiRef","focusElementRef","tabIndex","disabled","isFilterActive","slotProps","clearButton","headerFilterMenu"];function TI(e){const{item:t,applyValue:n,type:r,apiRef:o,focusElementRef:i,tabIndex:a,disabled:l,slotProps:c,clearButton:u,headerFilterMenu:p}=e,h=d(e,MI),m=c?.root,g=Ng(),[v,b]=s.useState(II(t.value)),[y,w]=s.useState(!1),x=mm(),S=rP(),C=s.useCallback(e=>{const o=II(e.target.value);b(o),w(!0),g.start(S.filterDebounceMs,()=>{const e=f({},t,{value:"number"!==r||Number.isNaN(Number(o))?o:Number(o),fromInput:x});n(e),w(!1)})},[g,S.filterDebounceMs,t,r,x,n]);return s.useEffect(()=>{t.fromInput===x&&null!=t.value||b(II(t.value))},[x,t]),Xp.jsxs(s.Fragment,{children:[Xp.jsx(S.slots.baseTextField,f({id:x,label:o.current.getLocaleText("filterPanelInputLabel"),placeholder:o.current.getLocaleText("filterPanelInputPlaceholder"),value:v??"",onChange:C,type:r||"text",disabled:l,slotProps:f({},m?.slotProps,{input:f({endAdornment:y?Xp.jsx(S.slots.loadIcon,{fontSize:"small",color:"action"}):null},m?.slotProps?.input),htmlInput:f({tabIndex:a},m?.slotProps?.htmlInput)}),inputRef:i},S.slotProps?.baseTextField,h,m)),p,u]})}function II(e){if(null!=e&&""!==e)return String(e)}function OI(e){return"object"==typeof e&&null!==e}function DI(e){return e.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")}const FI=(e,t,n)=>Math.max(t,Math.min(n,e));function LI(e){return"function"==typeof structuredClone?structuredClone(e):JSON.parse(JSON.stringify(e))}const AI=(e,t)=>n=>{e&&t(n)};function NI(e){const{item:t,applyValue:n,type:r,apiRef:o,focusElementRef:i,slotProps:a}=e,l=mm(),[c,u]=s.useState([]),[d,p]=s.useState(t.value||[]),h=rP();s.useEffect(()=>{const e=t.value??[];p(e.map(String))},[t.value]);const m=s.useCallback((e,o)=>{p(o.map(String)),n(f({},t,{value:[...o.map(e=>"number"===r?Number(e):e)]}))},[n,t,r]),g=s.useCallback((e,t)=>{u(""===t?[]:[t])},[u]),v=h.slots.baseAutocomplete;return Xp.jsx(v,f({multiple:!0,freeSolo:!0,options:c,id:l,value:d,onChange:m,onInputChange:g,label:o.current.getLocaleText("filterPanelInputLabel"),placeholder:o.current.getLocaleText("filterPanelInputPlaceholder"),slotProps:{textField:{type:r||"text",inputRef:i}}},a?.root))}var $I=function(e){return e.Cell="cell",e.Row="row",e}($I||{}),zI=function(e){return e.Edit="edit",e.View="view",e}(zI||{}),jI=function(e){return e.Edit="edit",e.View="view",e}(jI||{}),BI=function(e){return e.And="and",e.Or="or",e}(BI||{});class _I{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 HI{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 VI=e=>"include"===e.type?new _I(e):new HI(e);var WI=function(e){return e.enterKeyDown="enterKeyDown",e.cellDoubleClick="cellDoubleClick",e.printableKeyDown="printableKeyDown",e.deleteKeyDown="deleteKeyDown",e.pasteKeyDown="pasteKeyDown",e}(WI||{}),UI=function(e){return e.cellFocusOut="cellFocusOut",e.escapeKeyDown="escapeKeyDown",e.enterKeyDown="enterKeyDown",e.tabKeyDown="tabKeyDown",e.shiftTabKeyDown="shiftTabKeyDown",e}(UI||{}),GI=function(e){return e.enterKeyDown="enterKeyDown",e.cellDoubleClick="cellDoubleClick",e.printableKeyDown="printableKeyDown",e.deleteKeyDown="deleteKeyDown",e}(GI||{}),KI=function(e){return e.rowFocusOut="rowFocusOut",e.escapeKeyDown="escapeKeyDown",e.enterKeyDown="enterKeyDown",e.tabKeyDown="tabKeyDown",e.shiftTabKeyDown="shiftTabKeyDown",e}(KI||{});function qI(e){return void 0!==e.field}const YI={filteredRowsLookup:{},filteredChildrenCountLookup:{},filteredDescendantCountLookup:{}},XI=()=>({items:[],logicOperator:BI.And,quickFilterValues:[],quickFilterLogicOperator:BI.And});function QI(e){return{current:e.current.getPublicApi()}}let ZI=function(e){return e.LEFT="left",e.RIGHT="right",e}({});const JI={left:[],right:[]},eO=nT(e=>e.isRtl),tO=nT(e=>e.props.listView??!1),nO=nT(e=>e.listViewColumn),rO=nT(e=>e.columns),oO=eT(rO,e=>e.orderedFields),iO=eT(rO,e=>e.lookup),aO=tT(oO,iO,(e,t)=>e.map(e=>t[e])),lO=eT(rO,e=>e.columnVisibilityModel),sO=eT(rO,e=>e.initialColumnVisibilityModel),cO=tT(aO,lO,tO,nO,(e,t,n,r)=>n&&r?[r]:e.filter(e=>!1!==t[e.field])),uO=tT(cO,e=>e.map(e=>e.field)),dO=nT(e=>e.pinnedColumns);tT(dO,oO,eO,(e,t,n)=>fO(e,t,n));const pO=tT(rO,dO,uO,eO,tO,(e,t,n,r,o)=>{if(o)return JI;const i=fO(t,n,r);return{left:i.left.map(t=>e.lookup[t]),right:i.right.map(t=>e.lookup[t])}});function fO(e,t,n){if(!Array.isArray(e.left)&&!Array.isArray(e.right))return JI;if(0===e.left?.length&&0===e.right?.length)return JI;const r=(e,t)=>Array.isArray(e)?e.filter(e=>t.includes(e)):[],o=r(e.left,t),i=t.filter(e=>!o.includes(e)),a=r(e.right,i);return n?{left:a,right:o}:{left:o,right:a}}const hO=tT(cO,e=>{const t=[];let n=0;for(let r=0;r<e.length;r+=1)t.push(n),n+=e[r].computedWidth;return t}),mO=tT(aO,e=>e.filter(e=>e.filterable)),gO=tT(aO,e=>e.reduce((e,t)=>(t.filterable&&(e[t.field]=t),e),{})),vO=tT(aO,e=>e.some(e=>void 0!==e.colSpan));let bO;const yO=(e,t)=>{const n=f({},e);if(null==n.id&&(n.id=Math.round(1e5*Math.random())),null==n.operator){const e=iO(t)[n.field];n.operator=e&&e.filterOperators[0].value}return n},wO=(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?f({},e,{items:o.map(e=>yO(e,n))}):e.items!==o?f({},e,{items:o}):e},xO=(e,t,n)=>r=>f({},r,{filterModel:wO(e,t,n)}),SO=e=>"string"==typeof e?e.normalize("NFD").replace(/[\u0300-\u036f]/g,""):e,CO=(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=SO(o));const a=f({},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=QI(n),u=s.getApplyFilterFn(a,r);return"function"!=typeof u?null:{item:a,fn:e=>{let n=t(e,r);return i&&(n=SO(n)),u(n,e,r,c)}}};let kO=1;const EO=(e,t,n,r)=>{const{items:o}=e,i=o.map(e=>CO(e,t,n)).filter(e=>!!e);if(0===i.length)return null;if(r||!function(){if(void 0!==bO)return bO;try{bO=new Function("return true")()}catch(e){bO=!1}return bO}())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(kO)));kO+=1;return(e,t)=>a(i,e,t)},RO=e=>e.quickFilterExcludeHiddenColumns??!0,PO=(e,t,n,r)=>{const o=EO(e,t,n,r),i=((e,t,n)=>{const r=e.quickFilterValues?.filter(Boolean)??[];if(0===r.length)return null;const o=oO(n),i=lO(n);let a;a=RO(e)?o.filter(e=>!1!==i[e]):o;const l=[],{ignoreDiacritics:s}=n.current.rootProps,c=QI(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?SO(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:p}=u;if(n&&!n(p))continue;const f=d[i];let h=t(e,u);if(null!==f.fn&&(s&&(h=SO(h)),f.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}},MO=e=>null!=e,TO=(e,t,n,r,o,i)=>{const a=((e,t,n,r)=>(e.cleanedFilterItems||(e.cleanedFilterItems=r.filter(e=>null!==CO(e,t,n))),e.cleanedFilterItems))(i,r,o,n.items),l=e.filter(MO),s=t.filter(MO);if(l.length>0){const e=e=>l.some(t=>t[e.id]);if((n.logicOperator??XI().logicOperator)===BI.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??XI().quickFilterLogicOperator)===BI.And){if(!n.quickFilterValues.every(e))return!1}else{if(!n.quickFilterValues.some(e))return!1}}return!0},IO=(e,t)=>n=>{if(!n.value)return null;const r=e?n.value:n.value.trim(),o=new RegExp(DI(r),"i");return e=>{if(null==e)return t;const n=o.test(String(e));return t?!n:n}},OO=(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}},DO=e=>()=>t=>{const n=""===t||null==t;return e?!n:n},FO={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=kI(e,t);return null!==n?n:"string"==typeof e?EI.compare(e.toString(),t.toString()):e-t},type:"string",align:"left",filterOperators:((e=!1)=>[{value:"contains",getApplyFilterFn:IO(e,!1),InputComponent:TI},{value:"doesNotContain",getApplyFilterFn:IO(e,!0),InputComponent:TI},{value:"equals",getApplyFilterFn:OO(e,!1),InputComponent:TI},{value:"doesNotEqual",getApplyFilterFn:OO(e,!0),InputComponent:TI},{value:"startsWith",getApplyFilterFn:t=>{if(!t.value)return null;const n=e?t.value:t.value.trim(),r=new RegExp(`^${DI(n)}.*$`,"i");return e=>null!=e&&r.test(e.toString())},InputComponent:TI},{value:"endsWith",getApplyFilterFn:t=>{if(!t.value)return null;const n=e?t.value:t.value.trim(),r=new RegExp(`.*${DI(n)}$`,"i");return e=>null!=e&&r.test(e.toString())},InputComponent:TI},{value:"isEmpty",getApplyFilterFn:DO(!1),requiresFilterValue:!1},{value:"isNotEmpty",getApplyFilterFn:DO(!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:NI}])(),renderEditCell:e=>Xp.jsx(yI,f({},e)),getApplyQuickFilterFn:e=>{if(!e)return null;const t=new RegExp(DI(e),"i");return(e,n,r,o)=>{let i=o.current.getRowFormattedValue(n,r);return o.current.ignoreDiacritics&&(i=SO(i)),null!=i&&t.test(i.toString())}}};function LO(e){return 1===e.key.length&&!e.ctrlKey&&!e.metaKey}const AO=e=>0===e.indexOf("Arrow")||0===e.indexOf("Page")||" "===e||"Home"===e||"End"===e,NO=e=>"Tab"===e||"Escape"===e;function $O(e){return(e.ctrlKey||e.metaKey)&&"V"===String.fromCharCode(e.keyCode)&&!e.shiftKey&&!e.altKey}const zO=s.createContext(void 0),jO=()=>{const e=s.useContext(zO);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},BO=s.createContext({className:"unset",tag:Xp.jsx("style",{href:"/unset"})});function _O(){return s.useContext(BO).className}function HO(e){const t=jO(),n=rP(),r=t.hooks.useCSSVariables(),o=s.useMemo(()=>{const e=`MuiDataGridVariables-${r.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}(r.variables)}}`;return{className:e,tag:Xp.jsx("style",{href:`/${e}`,nonce:n.nonce,children:t})}},[n.nonce,r]);return Xp.jsx(BO.Provider,{value:o,children:e.children})}const VO=["open","target","onClose","children","position","className","onExited"],WO=pg(gI,{name:"MuiDataGrid",slot:"Menu"})({zIndex:bP.zIndex.menu,[`& .${XT.menuList}`]:{outline:0}});function UO(e){const{open:t,target:n,onClose:r,children:o,position:i,className:a,onExited:l}=e,c=d(e,VO),u=lP(),p=rP(),h=(e=>{const{classes:t}=e;return wm({root:["menu"]},YT,t)})(p),m=_O(),g=s.useRef(null);Wh(()=>{t?g.current=document.activeElement instanceof HTMLElement?document.activeElement:null:(g.current?.focus?.(),g.current=null)},[t]),s.useEffect(()=>{const e=t?"menuOpen":"menuClose";u.current.publishEvent(e,{target:n})},[u,t,n]);return Xp.jsx(WO,f({as:p.slots.basePopper,className:PR(h.root,a,m),ownerState:p,open:t,target:n,transition:!0,placement:i,onClickAway:e=>{e.target&&(n===e.target||n?.contains(e.target))||r(e)},onExited:l,clickAwayMouseEvent:"onMouseDown",onKeyDown:e=>{NO(e.key)&&r(e)}},c,p.slotProps?.basePopper,{children:o}))}const GO=["label","icon","showInMenu","onClick"],KO=["label","icon","showInMenu","onClick","closeMenuOnClick","closeMenu"],qO=TR((e,t)=>{const n=rP();if(!e.showInMenu){const{label:r,icon:o,onClick:i}=e,a=d(e,GO),l=e=>{i?.(e)};return Xp.jsx(n.slots.baseIconButton,f({size:"small",role:"menuitem","aria-label":r},a,{onClick:l},n.slotProps?.baseIconButton,{ref:t,children:s.cloneElement(o,{fontSize:"small"})}))}const{label:r,icon:o,onClick:i,closeMenuOnClick:a=!0,closeMenu:l}=e,c=d(e,KO);return Xp.jsx(n.slots.baseMenuItem,f({ref:t},c,{onClick:e=>{i?.(e),a&&l?.()},iconStart:o,children:r}))}),YO=["api","colDef","id","hasFocus","isEditable","field","value","formattedValue","row","rowNode","cellMode","tabIndex","position","children","suppressChildrenValidation"];function XO(e){const{hasFocus:t,tabIndex:n,position:r="bottom-end",children:o,suppressChildrenValidation:i}=e,a=d(e,YO),[l,c]=s.useState(-1),[u,p]=s.useState(!1),h=lP(),m=s.useRef(null),g=s.useRef(null),v=s.useRef(!1),b=s.useRef({}),y=um(),w=mm(),x=mm(),S=rP(),C=[];s.Children.forEach(o,e=>{s.isValidElement(e)&&(e.type===s.Fragment?s.Children.forEach(e.props.children,e=>{s.isValidElement(e)&&C.push(e)}):e.type===qO||i?C.push(e):"function"==typeof e.type?e.type.name:e.type)});const k=C.filter(e=>!e.props.showInMenu),E=C.filter(e=>e.props.showInMenu),R=k.length+(E.length?1:0);s.useLayoutEffect(()=>{t||Object.entries(b.current).forEach(([e,t])=>{t?.stop({},()=>{delete b.current[e]})})},[t]),s.useEffect(()=>{if(l<0||!m.current)return;if(l>=m.current.children.length)return;m.current.children[l].focus({preventScroll:!0})},[l]);const P=C.findIndex(e=>!e.props.disabled);s.useEffect(()=>{t&&-1===l&&c(P),t||(c(-1),v.current=!1)},[t,l,P]),s.useEffect(()=>{l>=R&&c(R-1)},[l,R]);const M=()=>{p(!1)},T=e=>t=>{b.current[e]=t},I=(e,t)=>n=>{c(e),v.current=!0,t&&t(n)},O=R>0?{role:"menu",onKeyDown:e=>{if(R<=1)return;const t=(e,n)=>{if(e<0||e>C.length)return e;const r=("left"===n?-1:1)*(y?-1:1);return C[e+r]?.props.disabled?t(e+r,n):e+r};let n=l;"ArrowRight"===e.key?n=t(l,"right"):"ArrowLeft"===e.key&&(n=t(l,"left")),n<0||n>=R||n!==l&&(e.preventDefault(),e.stopPropagation(),c(n))}}:void 0;return Xp.jsxs("div",f({ref:m,tabIndex:-1,className:XT.actionsCell},O,a,{children:[k.map((e,t)=>s.cloneElement(e,{key:t,touchRippleRef:T(t),onClick:I(t,e.props.onClick),tabIndex:l===t?n:-1})),E.length>0&&x&&Xp.jsx(S.slots.baseIconButton,f({ref:g,id:x,"aria-label":h.current.getLocaleText("actionsCellMore"),"aria-haspopup":"menu","aria-expanded":u,"aria-controls":u?w:void 0,role:"menuitem",size:"small",onClick:e=>{e.stopPropagation(),e.preventDefault(),u?M():(p(!0),c(R-1),v.current=!0)},touchRippleRef:T(x),tabIndex:l===k.length?n:-1},S.slotProps?.baseIconButton,{children:Xp.jsx(S.slots.moreActionsIcon,{fontSize:"small"})})),E.length>0&&Xp.jsx(UO,{open:u,target:g.current,position:r,onClose:M,children:Xp.jsx(S.slots.baseMenuList,{id:w,className:XT.menuList,"aria-labelledby":x,autoFocusItem:!0,children:E.map((e,t)=>s.cloneElement(e,{key:t,closeMenu:M}))})})]}))}function QO(e){const{colDef:t,id:n}=e,r=lP();if(!(e=>"function"==typeof e.getActions)(t))throw new Error("MUI X: Missing the `getActions` property in the `GridColDef`.");const o=t.getActions(r.current.getRowParams(n));return Xp.jsx(XO,f({suppressChildrenValidation:!0},e,{children:o}))}const ZO="actions",JO=f({},FO,{sortable:!1,filterable:!1,aggregable:!1,chartable:!1,width:100,display:"flex",align:"center",headerAlign:"center",headerName:"",disableColumnMenu:!0,disableExport:!0,renderCell:e=>Xp.jsx(QO,f({},e)),getApplyQuickFilterFn:()=>null}),eD="__row_group_by_columns_group__",tD="__detail_panel_toggle__";let nD=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 rD=["id","value","formattedValue","api","field","row","rowNode","colDef","cellMode","isEditable","hasFocus","tabIndex","hideDescendantCount"];function oD(e){const{value:t,rowNode:n}=e,r=d(e,rD),o=lP(),i=rP(),a=(e=>{const{classes:t}=e;return wm({root:["booleanCell"]},YT,t)})({classes:i.classes}),l=pI(o,RT)>0&&"group"===n.type&&!1===i.treeData,c=s.useMemo(()=>t?i.slots.booleanCellTrueIcon:i.slots.booleanCellFalseIcon,[i.slots.booleanCellFalseIcon,i.slots.booleanCellTrueIcon,t]);return l&&void 0===t?null:Xp.jsx(c,f({fontSize:"small",className:a.root,titleAccess:o.current.getLocaleText(t?"booleanCellTrueLabel":"booleanCellFalseLabel"),"data-value":Boolean(t)},r))}const iD=s.memo(oD),aD=["id","value","formattedValue","api","field","row","rowNode","colDef","cellMode","isEditable","tabIndex","className","hasFocus","isValidating","isProcessingProps","error","onValueChange"];function lD(e){const{id:t,value:n,field:r,className:o,hasFocus:i,onValueChange:a}=e,l=d(e,aD),c=lP(),u=s.useRef(null),p=mm(),[h,m]=s.useState(n),g=rP(),v=(e=>{const{classes:t}=e;return wm({root:["editBooleanCell"]},YT,t)})({classes:g.classes}),b=s.useCallback(async e=>{const n=e.target.checked;a&&await a(e,n),m(n),await c.current.setEditCellValue({id:t,field:r,value:n},e)},[c,r,t,a]);return s.useEffect(()=>{m(n)},[n]),Wh(()=>{i&&u.current.focus()},[i]),Xp.jsx("label",f({htmlFor:p,className:PR(v.root,o)},l,{children:Xp.jsx(g.slots.baseCheckbox,f({id:p,inputRef:u,checked:Boolean(h),onChange:b,size:"small"},g.slotProps?.baseCheckbox))}))}const sD=["item","applyValue","apiRef","focusElementRef","isFilterActive","headerFilterMenu","clearButton","tabIndex","slotProps"];function cD(e){const{item:t,applyValue:n,apiRef:r,focusElementRef:o,headerFilterMenu:i,clearButton:a,tabIndex:l,slotProps:c}=e,u=d(e,sD),[p,h]=s.useState(uD(t.value)),m=rP(),g=mm(),v=mm(),b=m.slotProps?.baseSelect||{},y=b.native??!1,w=m.slotProps?.baseSelectOption||{},x=s.useCallback(e=>{const r=uD(e.target.value);h(r),n(f({},t,{value:r}))},[n,t]);s.useEffect(()=>{h(uD(t.value))},[t.value]);const S=c?.root.label??r.current.getLocaleText("filterPanelInputLabel"),C=c?.root.slotProps;return Xp.jsxs(s.Fragment,{children:[Xp.jsxs(m.slots.baseSelect,f({fullWidth:!0,labelId:g,id:v,label:S,value:void 0===p?"":String(p),onChange:x,native:y,slotProps:{htmlInput:f({ref:o,tabIndex:l},C?.htmlInput)}},b,u,c?.root,{children:[Xp.jsx(m.slots.baseSelectOption,f({},w,{native:y,value:"",children:r.current.getLocaleText("filterValueAny")})),Xp.jsx(m.slots.baseSelectOption,f({},w,{native:y,value:"true",children:r.current.getLocaleText("filterValueTrue")})),Xp.jsx(m.slots.baseSelectOption,f({},w,{native:y,value:"false",children:r.current.getLocaleText("filterValueFalse")}))]})),i,a]})}function uD(e){return"true"===String(e).toLowerCase()||"false"!==String(e).toLowerCase()&&void 0}const dD=f({},FO,{type:"boolean",display:"flex",align:"center",headerAlign:"center",renderCell:e=>e.field!==eD&&jT(e.rowNode)?"":Xp.jsx(iD,f({},e)),renderEditCell:e=>Xp.jsx(lD,f({},e)),sortComparator:RI,valueFormatter:(e,t,n,r)=>e?r.current.getLocaleText("booleanCellTrueLabel"):r.current.getLocaleText("booleanCellFalseLabel"),filterOperators:[{value:"is",getApplyFilterFn:e=>{const t=uD(e.value);return void 0===t?null:e=>Boolean(e)===t},InputComponent:cD}],getApplyQuickFilterFn:()=>null,aggregable:!1,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)});function pD(e){for(const t in e)return!1;return!0}const fD=nT(e=>e.sorting),hD=eT(fD,e=>e.sortedRows),mD=tT(hD,wT,xT,(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&&jT(t)&&e.push({id:r,model:{[DT]:r}})}return e},[])),gD=eT(fD,e=>e.sortModel),vD=tT(gD,e=>{const t=e.reduce((t,n,r)=>(t[n.field]={sortDirection:n.sort,sortIndex:e.length>1?r+1:void 0},t),{});return t});tT(hD,e=>e.reduce((e,t,n)=>(e[t]=n,e),Object.create(null)));const bD=nT(e=>e.filter),yD=eT(bD,e=>e.filterModel),wD=eT(yD,e=>e.quickFilterValues),xD=nT(e=>e.visibleRowsLookup),SD=eT(bD,e=>e.filteredRowsLookup);eT(bD,e=>e.filteredChildrenCountLookup),eT(bD,e=>e.filteredDescendantCountLookup);const CD=tT(xD,mD,(e,t)=>pD(e)?t:t.filter(t=>!1!==e[t.id])),kD=tT(CD,e=>e.map(e=>e.id)),ED=tT(SD,mD,(e,t)=>pD(e)?t:t.filter(t=>!1!==e[t.id])),RD=tT(ED,e=>e.map(e=>e.id));tT(kD,xT,(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},{})});const PD=eT(tT(ED,xT,RT,(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]??[]),MD=eT(CD,e=>e.length),TD=eT(PD,e=>e.length),ID=eT(ED,e=>e.length);eT(ID,TD,(e,t)=>e-t);const OD=tT(yD,iO,(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);return!!r&&(!r.InputComponent||null!=e.value&&""!==e.value?.toString())})),DD=tT(OD,e=>{const t=e.reduce((e,t)=>(e[t.field]?e[t.field].push(t):e[t.field]=[t],e),{});return t}),FD=tT(kD,e=>e.reduce((e,t,n)=>(e[t]=n,e),Object.create(null))),LD=nT(e=>e.rowSelection),AD=tT(LD,VI),ND=eT(LD,ID,(e,t)=>"include"===e.type?e.ids.size:t-e.ids.size),$D=tT(LD,wT,PT,(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}),zD=nT((e,t)=>DT in t?t[DT]:e.props.getRowId?e.props.getRowId(t):t.id),jD=nT(e=>e.props.isRowSelectable);function BD(e,t){const n=xT(e),r=hD(e),o=SD(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 _D=eT(aO,xT,SD,AD,wT,jD,(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&&(u=i(c)),!s||"group"!==s.type||r.has(a))return{isIndeterminate:!1,isChecked:r.has(a),isSelectable:u};let d=!1,p=!1;const f=e=>{if(!1===n[e]||d&&p)return;const o=t[e];"group"===o?.type&&o.children.forEach(f),r.has(e)?d=!0:p=!0};return f(a),{isIndeterminate:d&&p,isChecked:!!l&&(d&&!p),isSelectable:u}});function HD(e){return e.signature===QT.DataGrid?e.checkboxSelection&&!0!==e.disableMultipleRowSelection:!e.disableMultipleRowSelection}const VD=(e,t,n,r,o,i,a=AD(e))=>{const l=SD(e),s=new Set([]);if((r||o)&&!1!==l[n]){if(r){const r=t[n];if("group"===r?.type){BD(e,n).forEach(e=>{i(e),s.add(e)})}}if(o){const r=e=>{if(!a.has(e)&&!s.has(e))return!1;const n=t[e];return!!n&&("group"!==n.type||n.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);if(0===a.length||a.every(r)){const r=t[n],a=r?.parent;null!=a&&a!==OT&&e.current.isRowSelectable(a)&&(i(a),s.add(a),o(a))}},c=t[n];if(!c||c.parent===OT)return;o(n)}}},WD=(e,t,n,r,o,i)=>{const a=AD(e);if(o||r){if(o){const e=((e,t)=>{const n=[];let r=t;for(;null!=r&&r!==OT;){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];if("group"===r?.type){BD(e,n).forEach(e=>{i(e)})}}}},UD=["field","id","formattedValue","row","rowNode","colDef","isEditable","cellMode","hasFocus","tabIndex","api"],GD=TR(function(e,t){const{field:n,id:r,rowNode:o,tabIndex:i}=e,a=d(e,UD),l=lP(),c=rP(),u=(e=>{const{classes:t}=e;return wm({root:["checkboxInput"]},YT,t)})({classes:c.classes}),{isIndeterminate:p,isChecked:h,isSelectable:m}=pI(l,_D,{groupId:r,autoSelectParents:c.rowSelectionPropagation?.parents??!1}),g=!m;s.useLayoutEffect(()=>{if(0===i){const e=l.current.getCellElement(r,n);e&&(e.tabIndex=-1)}},[l,i,r,n]);const v=Mg(e=>{" "===e.key&&e.stopPropagation()}),b=Mg(e=>{g&&e.preventDefault()}),y=Mg(()=>{});if("footer"===o.type||"pinnedRow"===o.type)return null;const w=l.current.getLocaleText(h&&!p?"checkboxSelectionUnselectRow":"checkboxSelectionSelectRow");return Xp.jsx(c.slots.baseCheckbox,f({tabIndex:i,checked:h&&!p,onChange:e=>{if(g)return;const t={value:e.target.checked,id:r};l.current.publishEvent("rowSelectionCheckboxChange",t,e)},onClick:b,onMouseDown:y,className:PR(u.root,g&&"Mui-disabled"),material:{disableRipple:g},slotProps:{htmlInput:{"aria-disabled":g||void 0,"aria-label":w,name:"select_row"}},onKeyDown:v,indeterminate:p},c.slotProps?.baseCheckbox,a,{ref:t}))}),KD=GD,qD=nT(e=>e.focus),YD=eT(qD,e=>e.cell),XD=eT(qD,e=>e.columnHeader);eT(qD,e=>e.columnHeaderFilter);const QD=eT(qD,e=>e.columnGroupHeader),ZD=nT(e=>e.tabIndex),JD=eT(ZD,e=>e.cell),eF=eT(ZD,e=>e.columnHeader);eT(ZD,e=>e.columnHeaderFilter);const tF=eT(ZD,e=>e.columnGroupHeader),nF=(e,t,n)=>t>0&&e>0?Math.ceil(e/t):-1===e?n+2:0,rF=e=>({page:0,pageSize:e?0:100}),oF=(e,t)=>{if(t===QT.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"))},iF=nT(e=>e.pagination),aF=eT(iF,e=>e.enabled&&"client"===e.paginationMode),lF=eT(iF,e=>e.paginationModel),sF=eT(iF,e=>e.rowCount),cF=eT(iF,e=>e.meta),uF=eT(lF,e=>e.page),dF=eT(lF,e=>e.pageSize),pF=eT(lF,sF,(e,t)=>nF(t,e.pageSize,e.page)),fF=tT(aF,lF,xT,RT,CD,PD,(e,t,n,r,o,i)=>{if(!e)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 p=d,f=0;for(;p<o.length&&f<=u;){const e=o[p],t=n[e.id]?.depth;void 0===t?p+=1:((f<u||t>0)&&(p+=1),0===t&&(f+=1))}return{firstRowIndex:d,lastRowIndex:p-1}}),hF=tT(CD,fF,(e,t)=>t?e.slice(t.firstRowIndex,t.lastRowIndex+1):[]),mF=tT(kD,fF,(e,t)=>t?e.slice(t.firstRowIndex,t.lastRowIndex+1):[]),gF=tT(aF,fF,hF,CD,(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)}),vF=["field","colDef"],bF=TR(function(e,t){const n=d(e,vF),[,r]=s.useState(!1),o=lP(),i=rP(),a=(e=>{const{classes:t}=e;return wm({root:["checkboxInput"]},YT,t)})({classes:i.classes}),l=pI(o,eF),c=pI(o,LD),u=pI(o,kD),p=pI(o,mF),h=s.useMemo(()=>{const e=i.isRowSelectable;if("function"!=typeof e)return c;if("exclude"===c.type)return c;const t={type:"include",ids:new Set};for(const n of c.ids)i.keepNonExistentRowsSelected&&t.ids.add(n),o.current.getRow(n)&&e(o.current.getRowParams(n))&&t.ids.add(n);return t},[o,i.isRowSelectable,i.keepNonExistentRowsSelected,c]),m=s.useMemo(()=>{const e=i.pagination&&i.checkboxSelectionVisibleOnly&&"server"!==i.paginationMode?p:u,t=new Set;for(let n=0;n<e.length;n+=1){const r=e[n];o.current.getRow(r)&&(o.current.isRowSelectable(r)&&t.add(r))}return t},[o,i.pagination,i.paginationMode,i.checkboxSelectionVisibleOnly,p,u]),g=s.useMemo(()=>{const e=VI(h);let t=0;for(const n of m)e.has(n)&&(t+=1);return t},[h,m]),v=s.useMemo(()=>{if(0===g)return!1;const e=VI(h);for(const t of m)if(!e.has(t))return!0;return!1},[g,h,m]),b=g>0,y=null!==l&&l.field===e.field?0:-1;s.useLayoutEffect(()=>{const t=o.current.getColumnHeaderElement(e.field);0===y&&t&&(t.tabIndex=-1)},[y,o,e.field]);const w=s.useCallback(e=>{" "===e.key&&o.current.publishEvent("headerSelectionCheckboxChange",{value:!b})},[o,b]),x=s.useCallback(()=>{r(e=>!e)},[]);s.useEffect(()=>o.current.subscribeEvent("rowSelectionChange",x),[o,x]);const S=o.current.getLocaleText(b&&!v?"checkboxSelectionUnselectAllRows":"checkboxSelectionSelectAllRows");return Xp.jsx(i.slots.baseCheckbox,f({indeterminate:v,checked:b&&!v,onChange:e=>{const t={value:e.target.checked};o.current.publishEvent("headerSelectionCheckboxChange",t)},className:a.root,slotProps:{htmlInput:{"aria-label":S,name:"select_all_rows"}},tabIndex:y,onKeyDown:w,disabled:!HD(i)},i.slotProps?.baseCheckbox,n,{ref:t}))}),yF="__check__",wF=f({},dD,{type:"custom",field:yF,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=zD(r,t);return r.current.isRowSelected(o)},rowSpanValueGetter:(e,t,n,r)=>zD(r,t),renderHeader:e=>Xp.jsx(bF,f({},e)),renderCell:e=>Xp.jsx(KD,f({},e))}),xF=["item","applyValue","type","apiRef","focusElementRef","slotProps","isFilterActive","headerFilterMenu","clearButton","tabIndex","disabled"];function SF(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 CF(e){const{item:t,applyValue:n,type:r,apiRef:o,focusElementRef:i,slotProps:a,headerFilterMenu:l,clearButton:c,tabIndex:u,disabled:p}=e,h=d(e,xF),m=a?.root.slotProps,g=Ng(),[v,b]=s.useState(()=>SF(t.value,r)),[y,w]=s.useState(!1),x=mm(),S=rP(),C=s.useCallback(e=>{g.clear();const r=e.target.value;b(r),w(!0),g.start(S.filterDebounceMs,()=>{const e=new Date(r);n(f({},t,{value:Number.isNaN(e.getTime())?void 0:e})),w(!1)})},[n,t,S.filterDebounceMs,g]);return s.useEffect(()=>{const e=SF(t.value,r);b(e)},[t.value,r]),Xp.jsxs(s.Fragment,{children:[Xp.jsx(S.slots.baseTextField,f({fullWidth:!0,id:x,label:o.current.getLocaleText("filterPanelInputLabel"),placeholder:o.current.getLocaleText("filterPanelInputPlaceholder"),value:v,onChange:C,type:r||"text",disabled:p,inputRef:i,slotProps:f({},m,{input:f({endAdornment:y?Xp.jsx(S.slots.loadIcon,{fontSize:"small",color:"action"}):null},m?.input),htmlInput:f({max:"datetime-local"===r?"9999-12-31T23:59":"9999-12-31",tabIndex:u},m?.htmlInput)})},S.slotProps?.baseTextField,h,a?.root)),l,c]})}function kF(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 EF=e=>[{value:"is",getApplyFilterFn:t=>kF(t,(e,t)=>e===t,e),InputComponent:CF,InputComponentProps:{type:e?"datetime-local":"date"}},{value:"not",getApplyFilterFn:t=>kF(t,(e,t)=>e!==t,e),InputComponent:CF,InputComponentProps:{type:e?"datetime-local":"date"}},{value:"after",getApplyFilterFn:t=>kF(t,(e,t)=>e>t,e),InputComponent:CF,InputComponentProps:{type:e?"datetime-local":"date"}},{value:"onOrAfter",getApplyFilterFn:t=>kF(t,(e,t)=>e>=t,e),InputComponent:CF,InputComponentProps:{type:e?"datetime-local":"date"}},{value:"before",getApplyFilterFn:t=>kF(t,(e,t)=>e<t,e,!e),InputComponent:CF,InputComponentProps:{type:e?"datetime-local":"date"}},{value:"onOrBefore",getApplyFilterFn:t=>kF(t,(e,t)=>e<=t,e),InputComponent:CF,InputComponentProps:{type:e?"datetime-local":"date"}},{value:"isEmpty",getApplyFilterFn:()=>e=>null==e,requiresFilterValue:!1},{value:"isNotEmpty",getApplyFilterFn:()=>e=>null!=e,requiresFilterValue:!1}],RF=["id","value","formattedValue","api","field","row","rowNode","colDef","cellMode","isEditable","tabIndex","hasFocus","inputProps","isValidating","isProcessingProps","onValueChange","slotProps"],PF=pg(gI)({fontSize:"inherit"});function MF(e){const{id:t,value:n,field:r,colDef:o,hasFocus:i,onValueChange:a,slotProps:l}=e,c=d(e,RF),u="dateTime"===o.type,p=lP(),h=s.useRef(null),m=s.useMemo(()=>{let e,t;if(e=null==n?null:n instanceof Date?n:new Date((n??"").toString()),null==e||Number.isNaN(e.getTime()))t="";else{t=new Date(e.getTime()-60*e.getTimezoneOffset()*1e3).toISOString().substr(0,u?16:10)}return{parsed:e,formatted:t}},[n,u]),[g,v]=s.useState(m),b=rP(),y=(e=>{const{classes:t}=e;return wm({root:["editInputCell"]},YT,t)})({classes:b.classes}),w=s.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},[]),x=s.useCallback(async e=>{const n=e.target.value,o=w(n);a&&await a(e,o),v({parsed:o,formatted:n}),p.current.setEditCellValue({id:t,field:r,value:o},e)},[p,r,t,a,w]);return s.useEffect(()=>{v(e=>m.parsed!==e.parsed&&m.parsed?.getTime()!==e.parsed?.getTime()?m:e)},[m]),Wh(()=>{i&&h.current.focus()},[i]),Xp.jsx(PF,f({as:b.slots.baseInput,inputRef:h,fullWidth:!0,className:y.root,type:u?"datetime-local":"date",value:g.formatted,onChange:x},c,l?.root,{slotProps:{htmlInput:f({max:u?"9999-12-31T23:59":"9999-12-31"},l?.root?.slotProps?.htmlInput)}}))}const TF=e=>Xp.jsx(MF,f({},e));function IF({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 OF=f({},FO,{type:"date",sortComparator:PI,valueFormatter:(e,t,n,r)=>{if(!e)return"";const o=zD(r,t);return!zT(t)||e instanceof Date?(IF({value:e,columnType:"date",rowId:o,field:n.field}),e.toLocaleDateString()):e},filterOperators:EF(),renderEditCell:TF,pastedValueParser:e=>new Date(e)}),DF=f({},FO,{type:"dateTime",sortComparator:PI,valueFormatter:(e,t,n,r)=>{if(!e)return"";const o=zD(r,t);return!zT(t)||e instanceof Date?(IF({value:e,columnType:"dateTime",rowId:o,field:n.field}),e.toLocaleString()):e},filterOperators:EF(!0),renderEditCell:TF,pastedValueParser:e=>new Date(e)}),FF=e=>null==e?null:Number(e),LF=f({},FO,{type:"number",align:"right",headerAlign:"right",sortComparator:RI,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=>FF(t)===e.value,InputComponent:TI,InputComponentProps:{type:"number"}},{value:"!=",getApplyFilterFn:e=>null==e.value||Number.isNaN(e.value)?null:t=>FF(t)!==e.value,InputComponent:TI,InputComponentProps:{type:"number"}},{value:">",getApplyFilterFn:e=>null==e.value||Number.isNaN(e.value)?null:t=>null!=t&&FF(t)>e.value,InputComponent:TI,InputComponentProps:{type:"number"}},{value:">=",getApplyFilterFn:e=>null==e.value||Number.isNaN(e.value)?null:t=>null!=t&&FF(t)>=e.value,InputComponent:TI,InputComponentProps:{type:"number"}},{value:"<",getApplyFilterFn:e=>null==e.value||Number.isNaN(e.value)?null:t=>null!=t&&FF(t)<e.value,InputComponent:TI,InputComponentProps:{type:"number"}},{value:"<=",getApplyFilterFn:e=>null==e.value||Number.isNaN(e.value)?null:t=>null!=t&&FF(t)<=e.value,InputComponent:TI,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:NI,InputComponentProps:{type:"number"}}],getApplyQuickFilterFn:e=>null==e||Number.isNaN(e)||""===e?null:t=>FF(t)===FF(e)});function AF(e){return"singleSelect"===e?.type}function NF(e,t){if(e)return"function"==typeof e.valueOptions?e.valueOptions(f({field:e.field},t)):e.valueOptions}function $F(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 zF=["id","value","formattedValue","api","field","row","rowNode","colDef","cellMode","isEditable","tabIndex","className","hasFocus","isValidating","isProcessingProps","error","onValueChange","initialOpen","slotProps"];function jF(e){const t=rP(),{id:n,value:r,field:o,row:i,colDef:a,hasFocus:l,error:c,onValueChange:u,initialOpen:p=t.editMode===$I.Cell,slotProps:h}=e,m=d(e,zF),g=lP(),v=s.useRef(null),b=s.useRef(null),[y,w]=s.useState(p),x=(t.slotProps?.baseSelect||{}).native??!1;if(Wh(()=>{l&&b.current?.focus()},[l]),!AF(a))return null;const S=NF(a,{id:n,row:i});if(!S)return null;const C=a.getOptionValue,k=a.getOptionLabel;return S&&a?Xp.jsx(t.slots.baseSelect,f({ref:v,value:r,onChange:async e=>{if(!AF(a)||!S)return;w(!1);const t=$F(e.target.value,S,C);u&&await u(e,t),await g.current.setEditCellValue({id:n,field:o,value:t},e)},open:y,onOpen:e=>{(function(e){return"key"in e&&!!e.key})(e)&&"Enter"===e.key||w(!0)},onClose:(e,r)=>{if(t.editMode!==$I.Row){if("backdropClick"===r||"Escape"===e.key){const t=g.current.getCellParams(n,o);g.current.publishEvent("cellEditStop",f({},t,{reason:"Escape"===e.key?UI.escapeKeyDown:UI.cellFocusOut}))}}else w(!1)},error:c,native:x,fullWidth:!0,slotProps:{htmlInput:{ref:b}}},m,h?.root,t.slotProps?.baseSelect,{children:S.map(e=>{const n=C(e);return s.createElement(t.slots.baseSelectOption,f({},t.slotProps?.baseSelectOption||{},{native:x,key:n,value:n}),k(e))})})):null}const BF=["item","applyValue","type","apiRef","focusElementRef","tabIndex","isFilterActive","clearButton","headerFilterMenu","slotProps"],_F=({column:e,OptionComponent:t,getOptionLabel:n,getOptionValue:r,isSelectNative:o,baseSelectOptionProps:i})=>["",...NF(e)||[]].map(e=>{const a=r(e);let l=n(e);return""===l&&(l=" "),s.createElement(t,f({},i,{native:o,key:a,value:a}),l)});function HF(e){const{item:t,applyValue:n,type:r,apiRef:o,focusElementRef:i,tabIndex:a,clearButton:l,headerFilterMenu:c,slotProps:u}=e,p=d(e,BF),h=t.value??"",m=mm(),g=mm(),v=rP(),b=v.slotProps?.baseSelect?.native??!1,y=o.current.getColumn(t.field),w=y.getOptionValue,x=y.getOptionLabel,S=s.useMemo(()=>NF(y),[y]),C=s.useCallback(e=>{let r=e.target.value;r=$F(r,S,w),n(f({},t,{value:r}))},[S,w,n,t]);if(!y||!AF(y))return null;const k=u?.root.label??o.current.getLocaleText("filterPanelInputLabel");return Xp.jsxs(s.Fragment,{children:[Xp.jsx(v.slots.baseSelect,f({fullWidth:!0,id:m,label:k,labelId:g,value:h,onChange:C,slotProps:{htmlInput:f({tabIndex:a,ref:i,type:r||"text",placeholder:u?.root.placeholder??o.current.getLocaleText("filterPanelInputPlaceholder")},u?.root.slotProps?.htmlInput)},native:b},v.slotProps?.baseSelect,p,u?.root,{children:_F({column:y,OptionComponent:v.slots.baseSelectOption,getOptionLabel:x,getOptionValue:w,isSelectNative:b,baseSelectOptionProps:v.slotProps?.baseSelectOption})})),c,l]})}const VF=["item","applyValue","type","apiRef","focusElementRef","slotProps"];function WF(e){const{item:t,applyValue:n,type:r,apiRef:o,focusElementRef:i,slotProps:a}=e,l=d(e,VF),c=mm(),u=rP(),p=o.current.getColumn(t.field),h=p.getOptionValue,m=p.getOptionLabel,g=s.useCallback((e,t)=>h(e)===h(t),[h]),v=s.useMemo(()=>NF(p)||[],[p]),b=s.useMemo(()=>Array.isArray(t.value)?t.value.reduce((e,t)=>{const n=v.find(e=>h(e)===t);return null!=n&&e.push(n),e},[]):[],[h,t.value,v]),y=s.useCallback((e,r)=>{n(f({},t,{value:r.map(h)}))},[n,t,h]);if(!p||!AF(p))return null;const w=u.slots.baseAutocomplete;return Xp.jsx(w,f({multiple:!0,options:v,isOptionEqualToValue:g,id:c,value:b,onChange:y,getOptionLabel:m,label:o.current.getLocaleText("filterPanelInputLabel"),placeholder:o.current.getLocaleText("filterPanelInputPlaceholder"),slotProps:{textField:{type:r||"text",inputRef:i}}},l,a?.root))}const UF=e=>null!=e&&OI(e)?e.value:e,GF=f({},FO,{type:"singleSelect",getOptionLabel:e=>OI(e)?e.label:String(e),getOptionValue:e=>OI(e)?e.value:e,valueFormatter(e,t,n,r){const o=zD(r,t);if(!AF(n))return"";const i=NF(n,{id:o,row:t});if(null==e)return"";if(!i)return e;if("object"!=typeof i[0])return n.getOptionLabel(e);const a=i.find(t=>n.getOptionValue(t)===e);return a?n.getOptionLabel(a):""},renderEditCell:e=>Xp.jsx(jF,f({},e)),filterOperators:[{value:"is",getApplyFilterFn:e=>null==e.value||""===e.value?null:t=>UF(t)===UF(e.value),InputComponent:HF},{value:"not",getApplyFilterFn:e=>null==e.value||""===e.value?null:t=>UF(t)!==UF(e.value),InputComponent:HF},{value:"isAnyOf",getApplyFilterFn:e=>{if(!Array.isArray(e.value)||0===e.value.length)return null;const t=e.value.map(UF);return e=>t.includes(UF(e))},InputComponent:WF}],pastedValueParser:(e,t,n)=>{const r=n,o=NF(r)||[],i=r.getOptionValue;if(o.find(t=>i(t)===e))return e}}),KF=nT(e=>e.headerFiltering),qF=eT(KF,e=>e?.enabled??!1),YF=eT(KF,e=>e.editing),XF=eT(KF,e=>e.menuOpen),QF=nT(e=>e.columnGrouping),ZF=tT(QF,e=>e?.unwrappedGroupingModel??{}),JF=tT(QF,e=>e?.lookup??{}),eL=tT(QF,e=>e?.headerStructure??[]),tL=eT(QF,e=>e?.maxDepth??0),nL=["maxWidth","minWidth","width","flex"],rL={string:FO,number:LF,date:OF,dateTime:DF,boolean:dD,singleSelect:GF,[ZO]:JO,custom:FO};const oL=(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=FI(a.width||FO.width,a.minWidth||FO.minWidth,a.maxWidth||FO.maxWidth),o+=l),a.computedWidth!==l&&(a=f({},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]=f({},n[t],{computedWidth:e[t].computedWidth})})}return f({},e,{lookup:n})};function iL(e){let t=rL.string;return e&&rL[e]&&(t=rL[e]),t}const aL=({apiRef:e,columnsToUpsert:t,initialState:n,columnVisibilityModel:r=lO(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=rO(e);l={orderedFields:o?[]:[...t.orderedFields],lookup:f({},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=f({},iL(e.type),{field:t,hasBeenResized:!1}),l.orderedFields.push(t)):o&&l.orderedFields.push(t),n&&n.type!==e.type&&(n=f({},iL(e.type),{field:t}));let r=n.hasBeenResized;nL.forEach(t=>{void 0!==e[t]&&(r=!0,-1===e[t]&&(e[t]=1/0))}),l.lookup[t]=Hh(n,f({},iL(e.type),e,{hasBeenResized:r}))}),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=f({},e.lookup);for(let e=0;e<o.length;e+=1){const t=o[e],n=f({},s[t],{hasBeenResized:!0});Object.entries(r[t]).forEach(([e,t])=>{n[e]=-1===t?1/0:t}),s[t]=n}return f({},e,{orderedFields:l,lookup:s})})(e.current.unstable_applyPipeProcessors("hydrateColumns",l),n);return oL(c,e.current.getRootDimensions?.()??void 0)};function lL(e,t){if(t.listView)return 0;const n=mI(e),r=tL(e),o=qF(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 sL=jh("div",{name:"MuiDataGrid",slot:"ScrollArea",overridesResolver:(e,t)=>[{[`&.${XT["scrollArea--left"]}`]:t["scrollArea--left"]},{[`&.${XT["scrollArea--right"]}`]:t["scrollArea--right"]},{[`&.${XT["scrollArea--up"]}`]:t["scrollArea--up"]},{[`&.${XT["scrollArea--down"]}`]:t["scrollArea--down"]},t.scrollArea]})(()=>({position:"absolute",zIndex:101,[`&.${XT["scrollArea--left"]}`]:{top:0,left:0,width:20,bottom:0},[`&.${XT["scrollArea--right"]}`]:{top:0,right:0,width:20,bottom:0},[`&.${XT["scrollArea--up"]}`]:{top:0,left:0,right:0,height:20},[`&.${XT["scrollArea--down"]}`]:{bottom:0,left:0,right:0,height:20}})),cL=eT(oT,(e,t)=>"left"===t?e.leftPinnedWidth:"right"===t?e.rightPinnedWidth+(e.hasScrollX?e.scrollbarSize:0):0);function uL(e){const{scrollDirection:t,scrollPosition:n}=e,r=s.useRef(null),o=lP(),i=Ng(),a=pI(o,mI),l=pI(o,iT),c=pI(o,cL,t),u=rP(),d=lL(o,u),p=Math.floor(u.columnHeaderHeight*a),h=f({height:p,top:d-p},"left"===t?{left:c}:{},"right"===t?{right:c}:{}),m=Mg(e=>{let a;if(e.preventDefault(),"left"===t)a=e.clientX-r.current.getBoundingClientRect().right;else{if("right"!==t)throw new Error("MUI X: Wrong drag direction");a=Math.max(1,e.clientX-r.current.getBoundingClientRect().left)}a=1.5*(a-1)+1,i.start(0,()=>{o.current.scroll({left:n.current.left+a,top:n.current.top})})});return Xp.jsx(pL,f({},e,{ref:r,getCanScrollMore:()=>{const e=oT(o);if("left"===t)return n.current.left>0;if("right"===t){const t=l-e.viewportInnerSize.width;return n.current.left<t}return!1},style:h,handleDragOver:m}))}function dL(e){const{scrollDirection:t,scrollPosition:n}=e,r=s.useRef(null),o=lP(),i=Ng(),a=pI(o,mT),l=rP(),c=lL(o,l),u={top:"up"===t?c:void 0,bottom:"down"===t?0:void 0},d=Mg(e=>{let a;if(e.preventDefault(),"up"===t)a=e.clientY-r.current.getBoundingClientRect().bottom;else{if("down"!==t)throw new Error("MUI X: Wrong drag direction");a=Math.max(1,e.clientY-r.current.getBoundingClientRect().top)}a=1.5*(a-1)+1,i.start(0,()=>{o.current.scroll({left:n.current.left,top:n.current.top+a})})});return Xp.jsx(pL,f({},e,{ref:r,getCanScrollMore:()=>{const e=oT(o);if("up"===t)return n.current.top>0;if("down"===t){const t=(a.currentPageTotalHeight||0)-e.viewportInnerSize.height-(e.hasScrollX?e.scrollbarSize:0);return n.current.top<t}return!1},style:u,handleDragOver:d}))}const pL=TR(function(e,t){const{scrollDirection:n,getCanScrollMore:r,style:o,handleDragOver:i}=e,a=lP(),[l,c]=s.useState(r),u=f({},rP(),{scrollDirection:n}),d=(e=>{const{scrollDirection:t,classes:n}=e;return wm({root:["scrollArea",`scrollArea--${t}`]},YT,n)})(u);return rI(a,"scrollPositionChange",()=>{c(r)}),l?Xp.jsx(sL,{ref:t,className:d.root,ownerState:u,onDragOver:i,style:o}):null}),fL=KT(function(e){const t=lP(),[n,r]=s.useState("none");return rI(t,"columnHeaderDragStart",()=>r("horizontal")),rI(t,"columnHeaderDragEnd",()=>r("none")),rI(t,"rowDragStart",()=>r("vertical")),rI(t,"rowDragEnd",()=>r("none")),"none"===n?null:"horizontal"===n?Xp.jsx(uL,f({},e)):Xp.jsx(dL,f({},e))}),hL=s.createContext(void 0);function mL(){const e=s.useContext(hL);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 gL=()=>{};function vL(e,t,n){const r=s.useRef(!0);Wh(()=>{r.current=!1,e.current.register(n,t)},[e,n,t]),r.current&&e.current.register(n,t)}function bL(e,t){const n=s.useRef(null);if(n.current)return n.current;const r=e.current.getLogger(t);return n.current=r,r}const yL=(e,t,n,r,o)=>{const i=bL(e,"useNativeEventListener");iI(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)}})};function wL(e){const t=s.useRef(!0);t.current&&(t.current=!1,e())}const xL=nT(e=>e.pivoting),SL=eT(xL,e=>e?.active),CL=new Map,kL=eT(xL,e=>e?.initialColumns||CL),EL=(e,t)=>{const n=pI(e,vT),r=pI(e,MD),o=pI(e,IT),i=pI(e,cO),a=0===n&&0===o,l=pI(e,bT),s=pI(e,SL),c=!l&&a,u=!l&&n>0&&0===r;let d=null,p=null;return c&&(d="noRowsOverlay"),!l&&0===i.length&&(d="noColumnsOverlay"),c&&s&&(d="emptyPivotOverlay"),u&&(d="noResultsOverlay"),l&&(d="loadingOverlay",p=t.slotProps?.loadingOverlay?.[a?"noRowsVariant":"variant"]??(a?"skeleton":"linear-progress")),{overlayType:d,loadingOverlayVariant:p}},RL=nT(e=>e.columnMenu);const PL=KT(function(){const e=mL(),t=rP(),n=pI(e,cO),r=pI(e,DD),o=pI(e,vD),i=pI(e,eF),a=pI(e,()=>null===JD(e)),l=pI(e,tF),s=pI(e,XD),c=pI(e,QD),u=pI(e,tL),d=pI(e,RL),p=pI(e,lO),h=pI(e,eL),m=!(null===l&&null===i&&a),g=e.current.columnHeadersContainerRef;return Xp.jsx(t.slots.columnHeaders,f({ref:g,visibleColumns:n,filterColumnLookup:r,sortColumnLookup:o,columnHeaderTabIndexState:i,columnGroupHeaderTabIndexState:l,columnHeaderFocus:s,columnGroupHeaderFocus:c,headerGroupingMaxDepth:u,columnMenuState:d,columnVisibility:p,columnGroupsHeaderStructure:h,hasOtherElementInTabSequence:m},t.slotProps?.columnHeaders))}),ML=jh("div")({position:"absolute",top:"var(--DataGrid-headersTotalHeight)",left:0,width:"calc(100% - (var(--DataGrid-hasScrollY) * var(--DataGrid-scrollbarSize)))"}),TL=jh("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"}),IL=TR((e,t)=>{const{ownerState:n}=e,r=rP(),o=jO().hooks.useGridAriaAttributes();return Xp.jsxs(TL,f({ownerState:n,className:e.className,tabIndex:-1},o,r.slotProps?.main,{ref:t,children:[Xp.jsx(ML,{role:"presentation","data-id":"gridPanelAnchor"}),e.children]}))}),OL=jh("div")({position:"sticky",zIndex:40,top:0});function DL(e){const t=wm({root:["topContainer"]},YT,{});return Xp.jsx(OL,f({},e,{className:PR(t.root,XT["container--top"]),role:"presentation"}))}const FL=jh("div",{name:"MuiDataGrid",slot:"VirtualScrollerContent",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.virtualScrollerContent,n.overflowedContent&&t["virtualScrollerContent--overflowed"]]}})({}),LL=TR(function(e,t){const n=rP(),r=!n.autoHeight&&"auto"===e.style?.minHeight,o=((e,t)=>{const{classes:n}=e;return wm({root:["virtualScrollerContent",t&&"virtualScrollerContent--overflowed"]},YT,n)})(n,r),i={classes:n.classes,overflowedContent:r};return Xp.jsx(FL,f({},e,{ownerState:i,className:PR(o.root,e.className),ref:t}))}),AL=jh("div")({display:"flex",flexDirection:"row",width:"var(--DataGrid-rowWidth)",boxSizing:"border-box"}),NL=jh("div")({position:"sticky",height:"100%",boxSizing:"border-box",borderTop:"1px solid var(--rowBorderColor)",backgroundColor:bP.cell.background.pinned}),$L=jh(NL)({left:0}),zL=jh(NL)({right:0}),jL=jh("div")({flexGrow:1,borderTop:"1px solid var(--rowBorderColor)"});const BL=KT(function({rowsLength:e}){const t=lP(),{viewportOuterSize:n,minimumSize:r,hasScrollX:o,hasScrollY:i,scrollbarSize:a,leftPinnedWidth:l,rightPinnedWidth:s}=pI(t,oT),c=o?a:0,u=n.height-r.height>0;return 0!==c||u?Xp.jsxs(AL,{className:XT.filler,role:"presentation",style:{height:c,"--rowBorderColor":0===e?"transparent":"var(--DataGrid-rowBorderColor)"},children:[l>0&&Xp.jsx($L,{className:XT["filler--pinnedLeft"],style:{width:l}}),Xp.jsx(jL,{}),s>0&&Xp.jsx(zL,{className:XT["filler--pinnedRight"],style:{width:s+(i?a:0)}})]}):null}),_L=jh("div",{name:"MuiDataGrid",slot:"VirtualScrollerRenderZone"})({position:"absolute",display:"flex",flexDirection:"column"}),HL=TR(function(e,t){const n=rP(),r=(e=>{const{classes:t}=e;return wm({root:["virtualScrollerRenderZone"]},YT,t)})(n);return Xp.jsx(_L,f({ownerState:n},e,{className:PR(r.root,e.className),ref:t}))}),VL={includeHeaders:!0,includeOutliers:!1,outliersFactor:1.5,expand:!1,disableColumnVirtualization:!0},WL=nT(e=>e.editRows),UL=eT(WL,(e,{rowId:t,editMode:n})=>n===$I.Row&&Boolean(e[t])),GL=eT(WL,(e,{rowId:t,field:n})=>e[t]?.[n]??null),KL=nT(e=>e.preferencePanel),qL=eT(KL,(e,t)=>!(!e.open||e.labelId!==t));var YL=function(e){return e.filters="filters",e.columns="columns",e.aiAssistant="aiAssistant",e}(YL||{});const XL={initialize:function(e){return{colspanMap:new Map}},use:function(e,t,n){const r=t.colspan?.getColspan,o=Mg(r?(t,n,o,i)=>{for(let a=n;a<o;a+=1){const l=QL(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:{}};function QL(e,t,n,r,o,i,a){const l=i.length,s=i[t],c=a(n,s,t);if(!c||1===c)return ZL(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;if(s>=r&&s<o){u+=i[s].computedWidth,ZL(e,n,t+a,{spannedByColSpan:!0,rightVisibleCellIndex:Math.min(t+c,l-1),leftVisibleCellIndex:t})}ZL(e,n,t,{spannedByColSpan:!1,cellProps:{colSpan:c,width:u}})}return{colSpan:c}}function ZL(e,t,n,r){let o=e.get(t);o||(o={},e.set(t,o)),o[n]=r}function JL(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(!JL(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(!JL(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(!JL(e[r],t[r]))return!1}return!0}return e!=e&&t!=t}function eA(e,t){return Math.round(e*10**t)/10**t}const tA={EMPTY:{width:0,height:0},equals:(e,t)=>e.width===t.width&&e.height===t.height},nA={EMPTY:{top:[],bottom:[]}},rA={EMPTY:{left:[],right:[]}},oA={EMPTY:{top:0,left:0}};let iA=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}({});(iA||(iA={})).forDelta=function(e,t){return 0===e&&0===t?iA.NONE:Math.abs(t)>=Math.abs(e)?t>0?iA.DOWN:iA.UP:e>0?iA.RIGHT:iA.LEFT};const aA={isReady:!1,root:tA.EMPTY,viewportOuterSize:tA.EMPTY,viewportInnerSize:tA.EMPTY,contentSize:tA.EMPTY,minimumSize:tA.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},lA={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:NM((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},sA={initialize:function(e){const t=f({},aA,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:tA.EMPTY,dimensions:t,rowsMeta:o,rowHeights:i}},use:function(e,t,n){const r=s.useRef(!0),{layout:o,dimensions:{rowHeight:i,columnsTotalWidth:a,leftPinnedWidth:l,rightPinnedWidth:c,topPinnedHeight:u,bottomPinnedHeight:d},onResize:p}=t,h=s.useCallback(n=>{if(n&&(r.current=!1),r.current)return;const s=o.refs.container.current,f=lA.rootSize(e.state),h=lA.rowsMeta(e.state),m=function(e,t){if(void 0!==t)return t;if(null===e)return 0;const n=cA.get(e);if(void 0!==n)return n;const r=kg(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),cA.set(e,o),o}(s,t.dimensions.scrollbarSize),g=u+h.pinnedTopRowsTotalHeight,v=d+h.pinnedBottomRowsTotalHeight,b={width:a,height:eA(h.currentPageTotalHeight,1)};let y,w,x=!1,S=!1;if(t.dimensions.autoHeight)S=!1,x=Math.round(a)>Math.round(f.width),y={width:f.width,height:g+v+b.height},w={width:Math.max(0,y.width-(S?m:0)),height:Math.max(0,y.height-(x?m:0))};else{y={width:f.width,height:f.height},w={width:Math.max(0,y.width),height:Math.max(0,y.height-g-v)};const e=b,t=w,n=e.width>t.width,r=e.height>t.height;(n||r)&&(S=r,x=e.width+(S?m:0)>t.width,x&&(S=e.height+m>t.height)),S&&(w.width-=m),x&&(w.height-=m)}t.disableHorizontalScroll&&(x=!1),t.disableVerticalScroll&&(S=!1);const C=Math.max(y.width,a+(S?m:0)),k={isReady:!0,root:f,viewportOuterSize:y,viewportInnerSize:w,contentSize:b,minimumSize:{width:a,height:g+b.height+v},hasScrollX:x,hasScrollY:S,scrollbarSize:m,rowWidth:C,rowHeight:i,columnsTotalWidth:a,leftPinnedWidth:l,rightPinnedWidth:c,topContainerHeight:g,bottomContainerHeight:v,autoHeight:t.dimensions.autoHeight,minimalContentHeight:t.dimensions.minimalContentHeight};JL(e.state.dimensions,k)||(e.update({dimensions:k}),p?.(k.root))},[e,o.refs.container,t.dimensions.scrollbarSize,t.dimensions.autoHeight,t.dimensions.minimalContentHeight,t.disableHorizontalScroll,t.disableVerticalScroll,p,i,a,l,c,u,d]),{resizeThrottleMs:m}=t,g=Mg(h),v=s.useMemo(()=>m>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}(g,m):void 0,[m,g]);s.useEffect(()=>v?.clear,[v]),Wh(h,[h]),Wh(()=>{e.update({dimensions:f({},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:o,getRowHeight:i,getRowSpacing:a,getEstimatedRowHeight:l}=t,c=s.useRef(-1),u=s.useRef(!1),d=s.useRef(!1),p=t.pinnedRows,f=YM(e,lA.rowHeight),h=Mg(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:m}=t,g=s.useCallback(t=>{const n=lA.dimensions(e.state),r=n.rowHeight,o=h(t.id);if(i){const e=i(t);if("auto"===e){if(o.needsFirstMeasurement){const e=l?l(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(a){const e=a(t);o.spacingTop=e.top??0,o.spacingBottom=e.bottom??0}else o.spacingTop=0,o.spacingBottom=0;return m?.(o,t),o},[e,i,h,l,f,a,m]),v=s.useCallback(()=>{u.current=!1;const t=p?.top.reduce((e,t)=>{const n=g(t);return e+n.content+n.spacingTop+n.spacingBottom+n.detail},0)??0,r=p?.bottom.reduce((e,t)=>{const n=g(t);return e+n.content+n.spacingTop+n.spacingBottom+n.detail},0)??0,i=[],a=o.reduce((e,t)=>{i.push(e);const n=g(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:i,pinnedTopRowsTotalHeight:t,pinnedBottomRowsTotalHeight:r};e.set("rowsMeta",s),l&&n(),d.current=!0},[e,p,o,g,n]),b=Mg(v),y=t=>r.get(t)?.content??lA.rowHeight(e.state),w=(e,t)=>{const n=h(e),r=n.content!==t;n.needsFirstMeasurement=!1,n.content=t,d.current&&=!r},x=e=>r.get(e)?.autoHeight??!1,S=()=>c.current,C=e=>{u.current&&e>c.current&&(c.current=e)},k=()=>{r.clear(),v()},E=Dg(()=>"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;w(i,o)}d.current||requestAnimationFrame(()=>{b()})})).current,R=(e,t)=>(e.__mui_id=t,E?.observe(e),()=>E?.unobserve(e));return Wh(()=>{v()},[v]),{getRowHeight:y,setLastMeasuredRowIndex:C,storeRowHeightMeasurement:w,hydrateRowsMeta:v,observeRowHeight:R,rowHasAutoHeight:x,getRowHeightEntry:h,getLastMeasuredRowIndex:S,resetRowHeights:k}}(e,t,h);return{updateDimensions:h,debouncedUpdateDimensions:v,rowsMeta:b}},selectors:lA};const cA=new WeakMap;const uA=("undefined"!=typeof navigator?navigator.userAgent.toLowerCase():"empty").includes("firefox"),dA="undefined"!=typeof window&&/jsdom|HappyDOM/.test(window.navigator.userAgent),pA=(e,t,n)=>Math.max(t,Math.min(n,e)),fA={top:0,left:0},hA=Object.freeze(new Map),mA={firstRowIndex:0,lastRowIndex:0,firstColumnIndex:0,lastColumnIndex:0},gA=(()=>{const e=AM(e=>e.virtualization.renderContext.firstRowIndex);return{store:AM(e=>e.virtualization),renderContext:AM(e=>e.virtualization.renderContext),enabledForRows:AM(e=>e.virtualization.enabledForRows),enabledForColumns:AM(e=>e.virtualization.enabledForColumns),offsetTop:AM(sA.selectors.rowPositions,e,(e,t)=>e[t]??0),context:AM(e=>e.virtualization.context),scrollPosition:AM(e=>e.virtualization.scrollPosition)}})(),vA={initialize:function(e){const t={virtualization:f({enabled:!dA,enabledForRows:!dA,enabledForColumns:!dA,renderContext:mA,props:e.layout.constructor.elements.reduce((e,t)=>(e[t],e),{}),context:{},scrollPosition:{current:oA.EMPTY}},e.initialState?.virtualization),getters:null};return t},use:function(e,t,n){const{layout:r,dimensions:{rowHeight:o,columnsTotalWidth:i=0},virtualization:{isRtl:a=!1,rowBufferPx:l=150,columnBufferPx:c=150},colspan:u,initialState:d,rows:p,range:h,columns:m,pinnedRows:g=nA.EMPTY,pinnedColumns:v=rA.EMPTY,onWheel:b,onTouchMove:y,onRenderContextChange:w,onScrollChange:x,scrollReset:S,renderRow:C,renderInfiniteLoadingTrigger:k}=t,E=g.bottom.length>0,[R,P]=s.useState(hA),M=s.useRef(!1),T=s.useRef(!1),I=YM(e,gA.renderContext),O=YM(e,gA.enabledForRows),D=YM(e,gA.enabledForColumns),F=YM(e,sA.selectors.contentHeight),L=s.useRef(d?.scroll??fA),A=s.useRef(!1),N=s.useRef(fA),$=s.useRef(mA),z=Ng(),j=s.useRef(void 0),B=Dg(()=>function(e,t,n,r,o){return{direction:iA.NONE,buffer:RA(e,iA.NONE,t,n,r,o)}}(a,l,c,15*o,300)).current,_=s.useCallback(t=>{kA(t,e.state.virtualization.renderContext)||e.set("virtualization",f({},e.state.virtualization,{renderContext:t,scrollPosition:{current:f({},L.current)}}));const n=sA.selectors.dimensions(e.state).isReady,r=t.firstRowIndex!==$.current.firstRowIndex||t.lastRowIndex!==$.current.lastRowIndex;n&&r&&($.current=t,w?.(t)),N.current=L.current},[e,w]),H=Mg(()=>{const i=r.refs.scroller.current;if(!i)return;const s=sA.selectors.dimensions(e.state),u=Math.ceil(s.contentSize.height-s.viewportInnerSize.height),d=Math.ceil(s.contentSize.width-s.viewportInnerSize.width),p={top:pA(i.scrollTop,0,u),left:a?pA(i.scrollLeft,-Math.abs(d),0):pA(i.scrollLeft,0,d)},h=p.left-L.current.left,m=p.top-L.current.top,g=0!==h||0!==m;L.current=p;const v=g?iA.forDelta(h,m):iA.NONE,b=Math.abs(L.current.top-N.current.top),y=Math.abs(L.current.left-N.current.left),w=b>=o||y>=50,x=B.direction!==v;if(!(w||x))return e.set("virtualization",f({},e.state.virtualization,{scrollPosition:{current:f({},L.current)}})),I;if(x)switch(v){case iA.NONE:case iA.LEFT:case iA.RIGHT:j.current=void 0;break;default:j.current=I}B.direction=v,B.buffer=RA(a,v,l,c,15*o,300);const S=wA(yA(e,t,n,O,D),L.current,B);return kA(S,I)||(So.flushSync(()=>{_(S)}),z.start(1e3,H)),S}),V=()=>{if(!sA.selectors.dimensions(e.state).isReady&&(O||D))return;const r=wA(yA(e,t,n,O,D),L.current,B);j.current=void 0,_(r)},W=Mg(V);QM(e,sA.selectors.dimensions,(e,t)=>{t.isReady&&V()}),Wh(()=>{M.current&&(V(),M.current=!1)});const U=Mg(()=>{if(A.current)return void(A.current=!1);const e=H();e&&x?.(L.current,e)}),G=s.useRef(null);Wh(()=>{T.current&&W()},[D,O,W]),Wh(()=>{r.refs.scroller.current&&(r.refs.scroller.current.scrollLeft=0)},[r.refs.scroller,S]),((e,t)=>{const n=s.useRef(!1);Wh(()=>n.current||!e?gL:(n.current=!0,t()),[n.current||e])})(I!==mA,()=>{if(x?.(L.current,I),T.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&&i&&(e.scrollLeft=n,o.left=!0,A.current=!0),!o.top&&F&&(e.scrollTop=t,A.current=!0),o.top&&o.left||(G.current=(r,i)=>{!o.left&&r&&(e.scrollLeft=n,o.left=!0,A.current=!0),!o.top&&i&&(e.scrollTop=t,o.top=!0,A.current=!0),o.left&&o.top&&(G.current=null)})}}),QM(e,sA.selectors.dimensions,V),Wh(()=>{r.refs.scroller&&G.current?.(i,F)},[r.refs.scroller,i,F]);const K=s.useRef(!0),q=bA(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!==tA.EMPTY&&tA.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)};tA.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,K.current||!n.debouncedUpdateDimensions?(n.updateDimensions(K.current),K.current=!1):n.debouncedUpdateDimensions())});return()=>{o?.(),r.refs.container.current=null}}),Y=bA(e=>{r.refs.scroller.current=e;const t={passive:!0};return e.addEventListener("scroll",U,t),e.addEventListener("wheel",b,t),e.addEventListener("touchmove",y,t),()=>{e.removeEventListener("scroll",U,t),e.removeEventListener("wheel",b,t),e.removeEventListener("touchmove",y,t),r.refs.scroller.current=null}}),X={containerRef:q,scrollerRef:Y},Q=r.use(e,t,n,X),Z=f({setPanels:P,getRows:(r={},o)=>{if(!r.rows&&!h)return[];let a=I;r.renderContext&&(a=r.renderContext,a.firstColumnIndex=I.firstColumnIndex,a.lastColumnIndex=I.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+p.length;break;default:c=g.top.length}const d=r.rows??p,f=a.firstRowIndex,b=Math.min(a.lastRowIndex,d.length),y=r.rows?PA(0,r.rows.length):PA(f,b);let w=-1;const x=t.focusedVirtualCell?.();!s&&x&&(x.rowIndex<f&&(y.unshift(x.rowIndex),w=x.rowIndex),x.rowIndex>b&&(y.push(x.rowIndex),w=x.rowIndex));const S=[],P=sA.selectors.columnPositions(e.state,m);return y.forEach(e=>{const{id:t,model:f}=d[e];if(o&&!o[t])return;const g=(h?.firstRowIndex||0)+c+e;if(u?.enabled){const e=v.left.length,r=m.length-v.right.length;n.calculateColSpan(t,e,r,m),v.left.length>0&&n.calculateColSpan(t,0,v.left.length,m),v.right.length>0&&n.calculateColSpan(t,m.length-v.right.length,m.length,m)}const b=n.rowsMeta.rowHasAutoHeight(t)?"auto":n.rowsMeta.getRowHeight(t);let y=!1;void 0===r.position&&(y=0===e);let E=!1;const M=e===d.length-1;l&&(s?E=M:e===p.length-1&&(E=!0));let T=a;j.current&&e>=j.current.firstRowIndex&&e<j.current.lastRowIndex&&(T=j.current);const I=e===w,O=x?.rowIndex===g,D=EA(P,T,v.left.length),F=M&&"top"===r.position,L=T.firstColumnIndex,A=T.lastColumnIndex;if(S.push(C({id:t,model:f,rowIndex:g,offsetLeft:D,columnsTotalWidth:i,baseRowHeight:b,firstColumnIndex:L,lastColumnIndex:A,focusedColumnIndex:O?x.columnIndex:void 0,isFirstVisible:y,isLastVisible:E,isVirtualFocusRow:I,showBottomBorder:F})),I)return;const N=R.get(t);N&&S.push(N),void 0===r.position&&M&&k&&S.push(k(t))}),S},rows:t.rows},Q);return f({getters:Z,setPanels:P,forceUpdateRenderContext:V,scheduleUpdateRenderContext:()=>{M.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:gA};function bA(e){const t=s.useRef(void 0),n=Mg(n=>{if(n)return t.current=e(n),MR>=19?t.current:void 0;t.current?.()});return n}function yA(e,t,n,r,o){const i=sA.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:sA.selectors.rowsMeta(e.state),columnPositions:sA.selectors.columnPositions(e.state,t.columns),rows:a,range:l,pinnedColumns:t.pinnedColumns,columns:s,hiddenCellsOriginMap:c,virtualizeColumnsWithAutoRowHeight:t.virtualizeColumnsWithAutoRowHeight}}function wA(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(xA(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:xA(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]=CA({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=SA(a,e.columnPositions,{atStart:!0,lastPosition:e.columnsTotalWidth}),o=SA(a+e.viewportInnerWidth,e.columnPositions)),r.firstColumnIndex=t,r.lastColumnIndex=o}const l=function(e,t,n){const[r,o]=CA({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]=CA({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 xA(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=pA(r-(e.range?.firstRowIndex||0),0,e.rowsMeta.positions.length);return o||e.rowsMeta.positions[i]>=t?SA(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 SA(e,t,r,Math.floor(n/2),Math.min(n,t.length))}(t,e.rowsMeta.positions,i,n)}function SA(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;if(n?.atStart){l=e-((i===t.length-1?n.lastPosition:t[i+1])-a)<a}else l=e<=a;return l?SA(e,t,n,r,i):SA(e,t,n,i+1,o)}function CA({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=SA(s,a,{atStart:!0,lastPosition:a[a.length-1]+l}),d=SA(c,a);return[pA(u,o,i),pA(d,o,i)]}function kA(e,t){return e===t||e.firstRowIndex===t.firstRowIndex&&e.lastRowIndex===t.lastRowIndex&&e.firstColumnIndex===t.firstColumnIndex&&e.lastColumnIndex===t.lastColumnIndex}function EA(e,t,n){const r=(e[t.firstColumnIndex]??0)-(e[n]??0);return Math.abs(r)}function RA(e,t,n,r,o,i){if(e)switch(t){case iA.LEFT:t=iA.RIGHT;break;case iA.RIGHT:t=iA.LEFT}switch(t){case iA.NONE:return{rowAfter:n,rowBefore:n,columnAfter:r,columnBefore:r};case iA.LEFT:return{rowAfter:0,rowBefore:0,columnAfter:0,columnBefore:i};case iA.RIGHT:return{rowAfter:0,rowBefore:0,columnAfter:i,columnBefore:0};case iA.UP:return{rowAfter:0,rowBefore:o,columnAfter:0,columnBefore:0};case iA.DOWN:return{rowAfter:o,rowBefore:0,columnAfter:0,columnBefore:0};default:throw new Error("unreachable")}}function PA(e,t){return Array.from({length:t-e}).map((t,n)=>e+n)}class MA{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 TA extends MA{static elements=["scroller","container","content","positioner","scrollbarVertical","scrollbarHorizontal"];use(e,t,n,r){const{scrollerRef:o,containerRef:i}=r,a=Mg(this.refSetter("scrollbarVertical")),l=Mg(this.refSetter("scrollbarHorizontal"));e.state.virtualization.context={scrollerRef:o,containerRef:i,scrollbarVerticalRef:a,scrollbarHorizontalRef:l}}static selectors=(()=>({containerProps:NM(vA.selectors.context,e=>({ref:e.containerRef})),scrollerProps:NM(vA.selectors.context,sA.selectors.autoHeight,sA.selectors.needsHorizontalScrollbar,(e,t,n)=>({ref:e.scrollerRef,style:{overflowX:n?void 0:"hidden",overflowY:t?"hidden":void 0},role:"presentation",tabIndex:uA?-1:void 0})),contentProps:NM(sA.selectors.contentHeight,sA.selectors.minimalContentHeight,sA.selectors.columnsTotalWidth,sA.selectors.needsHorizontalScrollbar,(e,t,n,r)=>({style:{width:r?n:"auto",flexBasis:0===e?t:e,flexShrink:0},role:"presentation"})),positionerProps:NM(vA.selectors.offsetTop,e=>({style:{transform:`translate3d(0, ${e}px, 0)`}})),scrollbarHorizontalProps:NM(vA.selectors.context,vA.selectors.scrollPosition,(e,t)=>({ref:e.scrollbarHorizontalRef,scrollPosition:t})),scrollbarVerticalProps:NM(vA.selectors.context,vA.selectors.scrollPosition,(e,t)=>({ref:e.scrollbarVerticalRef,scrollPosition:t})),scrollAreaProps:NM(vA.selectors.scrollPosition,e=>({scrollPosition:e}))}))()}class IA extends TA{use(e,t,n,r){super.use(e,t,n,r);const o=e.use(TA.selectors.containerProps),i=e.use(TA.selectors.scrollerProps),a=e.use(TA.selectors.contentProps),l=e.use(TA.selectors.positionerProps),s=e.use(TA.selectors.scrollbarVerticalProps),c=e.use(TA.selectors.scrollbarHorizontalProps),u=e.use(TA.selectors.scrollAreaProps);return{getContainerProps:()=>o,getScrollerProps:()=>i,getContentProps:()=>a,getPositionerProps:()=>l,getScrollbarVerticalProps:()=>s,getScrollbarHorizontalProps:()=>c,getScrollAreaProps:()=>u}}}NM(vA.selectors.context,sA.selectors.autoHeight,sA.selectors.needsHorizontalScrollbar,(e,t,n)=>({ref:e.mergedRef,style:{overflowX:n?void 0:"hidden",overflowY:t?"hidden":void 0,position:"relative"},role:"presentation",tabIndex:uA?-1:void 0})),NM(sA.selectors.contentHeight,e=>({style:{position:"absolute",display:"inline-block",width:"100%",height:e,top:0,left:0,zIndex:-1},role:"presentation"})),NM(vA.selectors.offsetTop,e=>({style:{height:e}}));const OA={initialize:function(e){return{}},use:function(e,t,n){return{getViewportPageSize:()=>{const n=sA.selectors.dimensions(e.state);if(!n.isReady)return 0;if(t.getRowHeight){const n=vA.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:{}};const DA={firstRowIndex:0,lastRowIndex:0},FA={spannedCells:{},hiddenCells:{},hiddenCellOriginMap:{}},LA={state:e=>e.rowSpanning,hiddenCells:e=>e.rowSpanning.caches.hiddenCells,spannedCells:e=>e.rowSpanning.caches.spannedCells,hiddenCellsOriginMap:e=>e.rowSpanning.caches.hiddenCellOriginMap},AA={initialize:function(e){return{rowSpanning:e.initialState?.rowSpanning??{caches:FA,processedRange:DA}}},use:function(e,t,n){return{getHiddenCellsOrigin:()=>LA.hiddenCellsOriginMap(e.state)}},selectors:LA};const NA={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}},$A=[sA,vA,XL,AA,OA],zA=e=>{const t=jA(e,NA),n=Dg(()=>new JM($A.map(e=>e.initialize(t)).reduce((e,t)=>Object.assign(e,t),{}))).current,r={};for(const e of $A)Object.assign(r,e.use(n,t,r));return{store:n,api:r}};function jA(e,t){const n=f({},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]=jA(e[r]??{},o)}return n}const BA=!("undefined"!=typeof window&&/jsdom|HappyDOM/.test(window.navigator.userAgent)),_A=(e,t)=>{const{disableVirtualization:n,autoHeight:r}=t;return f({},e,{virtualization:{enabled:!n&&BA,enabledForColumns:!n&&BA,enabledForRows:!n&&!r&&BA,renderContext:mA}})};const HA=nT(e=>e.virtualization);eT(HA,e=>e.enabled);const VA=eT(HA,e=>e.enabledForColumns);eT(HA,e=>e.enabledForRows);const WA=eT(HA,e=>e.renderContext),UA=tT(nT(e=>e.virtualization.renderContext.firstColumnIndex),nT(e=>e.virtualization.renderContext.lastColumnIndex),(e,t)=>({firstColumnIndex:e,lastColumnIndex:t}));function GA(e){return JSON.stringify([e.filterModel,e.sortModel,e.start,e.end])}class KA{constructor({ttl:e=3e5,getKey:t=GA}){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 qA extends Error{constructor(e){super(e.message),this.name="GridGetRowsError",this.params=e.params,this.cause=e.cause}}class YA extends Error{constructor(e){super(e.message),this.name="GridUpdateRowError",this.params=e.params,this.cause=e.cause}}const XA="calc(max(var(--DataGrid-scrollbarSize), 14px))",QA=jh("div")({position:"absolute",display:"inline-block",zIndex:60,"&:hover":{zIndex:70},"--size":XA}),ZA=jh(QA)({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}),JA=jh(QA)({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}),eN=jh(QA)({width:"var(--size)",height:"var(--size)",right:0,bottom:0,overflow:"scroll","@media print":{display:"none"}}),tN=TR(function(e,t){const n=mL(),r=rP(),o=s.useRef(!1),i=s.useRef(0),a=s.useRef(null),l=((e,t)=>{const{classes:n}=e;return wm({root:["scrollbar",`scrollbar--${t}`],content:["scrollbarContent"]},YT,n)})(r,e.position),c=pI(n,oT),u="vertical"===e.position?"height":"width",d="vertical"===e.position?"scrollTop":"scrollLeft",p="vertical"===e.position?"top":"left",f="horizontal"===e.position?c.minimumSize.width:c.minimumSize.height-c.headersTotalHeight,h=Mg(()=>{const t=a.current,n=e.scrollPosition.current;t&&n[p]!==i.current&&(i.current=n[p],o.current?o.current=!1:(o.current=!0,t[d]=e.scrollPosition.current[p]))}),m=Mg(()=>{const e=n.current.virtualScrollerRef.current,t=a.current;t&&(o.current?o.current=!1:(o.current=!0,e[d]=t[d]))});Lg(()=>{const e=n.current.virtualScrollerRef.current,t=a.current,r={passive:!0};return e.addEventListener("scroll",h,r),t.addEventListener("scroll",m,r),()=>{e.removeEventListener("scroll",h,r),t.removeEventListener("scroll",m,r)}});const g="vertical"===e.position?ZA:JA,v=s.useMemo(()=>({[u]:`${f}px`}),[u,f]);return Xp.jsx(g,{ref:Tg(t,a),className:l.root,tabIndex:-1,"aria-hidden":"true",onFocus:e=>{e.target.blur()},children:Xp.jsx("div",{className:l.content,style:v})})}),nN=jh("div",{name:"MuiDataGrid",slot:"ScrollShadow",overridesResolver:(e,t)=>[t.root,t[e.position]]})(({theme:e})=>({position:"absolute",inset:0,pointerEvents:"none",transition:bP.transition(["box-shadow"],{duration:bP.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 rN(e){const{position:t}=e,n={classes:rP().classes,position:t},r=(e=>{const{classes:t,position:n}=e;return wm({root:["scrollShadow",`scrollShadow--${n}`]},YT,t)})(n),o=s.useRef(null),i=mL(),a=pI(i,lT),l=pI(i,sT),c=pI(i,TT),u=pI(i,dO),d="vertical"===t?l&&c?.bottom?.length>0:a&&void 0!==u?.right?.length&&u?.right?.length>0,p=um(),f=s.useCallback(e=>{if(!o.current)return;const n=Math.abs(Math.round(e)),r=oT(i),a=Math.round(r.contentSize["vertical"===t?"height":"width"]-r.viewportInnerSize["vertical"===t?"height":"width"]),l="vertical"===t?c?.top?.length>0:void 0!==u?.left?.length&&u?.left?.length>0,s="vertical"===t?c?.bottom?.length>0:void 0!==u?.right?.length&&u?.right?.length>0,d=p?n<a:n>0,f=p?n>0:n<a;o.current.style.setProperty("--hasScrollStart",l&&d?"1":"0"),o.current.style.setProperty("--hasScrollEnd",s&&f?"1":"0")},[c,u,p,t,i]);return rI(i,"scrollPositionChange",e=>{f(e["vertical"===t?"top":"left"])}),rI(i,"columnResizeStop",()=>{"horizontal"===t&&f(i.current.virtualScrollerRef?.current?.scrollLeft||0)}),s.useEffect(()=>{f(("horizontal"===t?i.current.virtualScrollerRef?.current?.scrollLeft:i.current.virtualScrollerRef?.current?.scrollTop)??0)},[f,i,t]),Xp.jsx(nN,{className:r.root,ownerState:n,ref:o,style:{"--hasScrollStart":0,"--hasScrollEnd":d?"1":"0"}})}const oN=jh("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}:{}),iN=jh("div",{name:"MuiDataGrid",slot:"OverlayWrapperInner",shouldForwardProp:e=>"overlayType"!==e&&"loadingOverlayVariant"!==e})({});function aN(e){const t=lP(),n=rP(),r=pI(t,oT);let o=Math.max(r.viewportOuterSize.height-r.topContainerHeight-r.bottomContainerHeight-(r.hasScrollX?r.scrollbarSize:0),0);0===o&&(o=HT);const i=(e=>{const{classes:t}=e;return wm({root:["overlayWrapper"],inner:["overlayWrapperInner"]},YT,t)})(f({},e,{classes:n.classes}));return Xp.jsx(oN,f({className:i.root},e,{right:r.columnsTotalWidth-r.viewportOuterSize.width,children:Xp.jsx(iN,f({className:i.inner,style:{height:o,width:r.viewportOuterSize.width}},e))}))}const lN=(e,t)=>gF(e),sN=(e,t)=>pI(e,gF),cN=eT(YD,WA,gF,cO,(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)}),uN=tT(cN,cO,gF,YD,(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:f({},r,{rowIndex:o,columnIndex:i})}),dN={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,disableRowSelectionOnClick:!1,disableRowSelectionExcludeModel:!1,disableVirtualization:!1,editMode:$I.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"},pN=(e,t,n,r=!0)=>{const o=s.useRef(null),i=s.useRef(`mui-${Math.round(1e9*Math.random())}`),a=s.useCallback(()=>{o.current=e.current.registerPipeProcessor(t,i.current,n)},[e,n,t]);wL(()=>{r&&a()});const l=s.useRef(!0);s.useEffect(()=>(l.current?l.current=!1:r&&a(),()=>{o.current&&(o.current(),o.current=null)}),[a,r])},fN=(e,t,n)=>{const r=s.useRef(null),o=s.useRef(`mui-${Math.round(1e9*Math.random())}`),i=s.useCallback(()=>{r.current=e.current.registerPipeApplier(t,o.current,n)},[e,n,t]);wL(()=>{i()});const a=s.useRef(!0);s.useEffect(()=>(a.current?a.current=!1:i(),()=>{r.current&&(r.current(),r.current=null)}),[i])},hN=(e,t,n)=>{const r=aT(n),o=vT(n),i=iF(n),a=Math.min(i.enabled?i.paginationModel.pageSize:o,o);return f({},e,{rowsMeta:{currentPageTotalHeight:a*r,positions:Array.from({length:a},(e,t)=>t*r),pinnedTopRowsTotalHeight:0,pinnedBottomRowsTotalHeight:0}})},mN=eT(cO,hO,(e,t)=>{const n=e.length;return 0===n?0:eA(t[n-1]+e[n-1].computedWidth,1)}),gN=()=>PM((e,t,n,r,o)=>f({},e,{headerHeight:t,groupHeaderHeight:n,headerFilterHeight:r,headersTotalHeight:o}),{maxSize:1});function vN(){const e=um(),t=rP(),n=mL(),{listView:r}=t,o=pI(n,cO),i=pI(n,TT),a=pO(n),l=pI(n,AD),c=s.useCallback(e=>l.has(e)&&n.current.isRowSelectable(e),[l,n]),u=sN(n),d=pI(n,vO),p=pI(n,fT),h=pI(n,cT),{autoHeight:m}=t,g=r,v=pI(n,mI),b=WT(t.rowHeight,dN.rowHeight),y=Math.floor(b*v),w=Math.floor(t.columnHeaderHeight*v),x=Math.floor((t.columnGroupHeaderHeight??t.columnHeaderHeight)*v),S=Math.floor((t.headerFilterHeight??t.columnHeaderHeight)*v),C=pI(n,mN),k=lL(n,t),E=a.left.reduce((e,t)=>e+t.computedWidth,0),R=a.right.reduce((e,t)=>e+t.computedWidth,0),P=EL(n,t),M={rowHeight:y,headerHeight:w,columnsTotalWidth:C,leftPinnedWidth:E,rightPinnedWidth:R,topPinnedHeight:k,bottomPinnedHeight:0,autoHeight:m,minimalContentHeight:HT,scrollbarSize:t.scrollbarSize},T=Dg(gN).current,I=pI(n,vT),O=pI(n,iF),D=Math.min(O.enabled?O.paginationModel.pageSize:I,I),{getRowHeight:F,getEstimatedRowHeight:L,getRowSpacing:A}=t,N=t.slots.row,$=t.slotProps?.row;pI(n,uN);const z=Dg(()=>new IA({container:n.current.mainElementRef,scroller:n.current.virtualScrollerRef,scrollbarVertical:n.current.virtualScrollbarVerticalRef,scrollbarHorizontal:n.current.virtualScrollbarHorizontalRef})).current,j=zA({layout:z,dimensions:M,virtualization:{isRtl:e,rowBufferPx:t.rowBufferPx,columnBufferPx:t.columnBufferPx},colspan:{enabled:d,getColspan:s.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:u.rows,range:u.range,rowCount:D,columns:o,pinnedRows:i,pinnedColumns:a,disableHorizontalScroll:r,disableVerticalScroll:"noColumnsOverlay"===P.overlayType||"skeleton"===P.loadingOverlayVariant,getRowHeight:s.useMemo(()=>{if(F)return e=>F(f({},e,{densityFactor:v}))},[F,v]),getEstimatedRowHeight:s.useMemo(()=>L?e=>L(f({},e,{densityFactor:v})):void 0,[L,v]),getRowSpacing:s.useMemo(()=>A?e=>{const t=u.rowIdToIndexMap.get(e.id)??-1,r={isFirstVisible:0===t,isLastVisible:t===u.rows.length-1,indexRelativeToCurrentPage:t};return A(f({},e,r,{indexRelativeToCurrentPage:n.current.getRowIndexRelativeToVisibleRows(e.id)}))}:void 0,[n,A,u.rows,u.rowIdToIndexMap]),applyRowHeight:Mg((e,t)=>n.current.unstable_applyPipeProcessors("rowHeight",e,t)),virtualizeColumnsWithAutoRowHeight:t.virtualizeColumnsWithAutoRowHeight,focusedVirtualCell:Mg(()=>uN(n)),resizeThrottleMs:t.resizeThrottleMs,onResize:Mg(e=>n.current.publishEvent("resize",e)),onWheel:Mg(e=>{n.current.publishEvent("virtualScrollerWheel",{},e)}),onTouchMove:Mg(e=>{n.current.publishEvent("virtualScrollerTouchMove",{},e)}),onRenderContextChange:Mg(e=>{n.current.publishEvent("renderedRowsIntervalChange",e)}),onScrollChange:s.useCallback((e,t)=>{n.current.publishEvent("scrollPositionChange",{top:e.top,left:e.left,renderContext:t})},[n]),scrollReset:g,renderRow:s.useCallback(e=>Xp.jsx(N,f({row:e.model,rowId:e.id,index:e.rowIndex,selected:c(e.id),offsetLeft:e.offsetLeft,columnsTotalWidth:C,rowHeight:e.baseRowHeight,pinnedColumns:a,visibleColumns:o,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},$),e.id),[C,h,c,a,N,$,p,o]),renderInfiniteLoadingTrigger:s.useCallback(e=>n.current.getInfiniteLoadingTriggerElement?.({lastRowId:e}),[n])});return wL(()=>{n.current.store.state.dimensions=T(j.store.state.dimensions,w,x,S,k),n.current.store.state.rowsMeta=j.store.state.rowsMeta,n.current.store.state.virtualization=j.store.state.virtualization}),QM(j.store,sA.selectors.dimensions,(e,t)=>{t.isReady&&n.current.setState(e=>f({},e,{dimensions:T(t,w,x,S,k)}))}),QM(j.store,sA.selectors.rowsMeta,(e,t)=>{t!==n.current.state.rowsMeta&&n.current.setState(e=>f({},e,{rowsMeta:t}))}),QM(j.store,vA.selectors.store,(e,t)=>{t.renderContext!==mA&&t!==n.current.state.virtualization&&n.current.setState(e=>f({},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;fN(e,"rowHeight",a);const d={hydrateRowsMeta:a,observeRowHeight:l,rowHasAutoHeight:s,getRowHeightEntry:c,getLastMeasuredRowIndex:u};vL(e,{unstable_getRowHeight:n,unstable_setLastMeasuredRowIndex:r,unstable_storeRowHeightMeasurement:o,resetRowHeights:i},"public"),vL(e,d,"private")})(n),j}const bN=jh("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}),yN=e=>e.current.state.dimensions.rightPinnedWidth>0;function wN(e){const t=mL(),n=rP(),r=pI(t,sT),o=pI(t,lT),i=pI(t,yN),a=pI(t,hT),{overlayType:l,loadingOverlayVariant:c}=EL(t,n),u=n.slots?.[l],d={classes:n.classes,hasScrollX:o,hasPinnedRight:i,overlayType:l,loadingOverlayVariant:c},p=(e=>{const{classes:t,hasScrollX:n,hasPinnedRight:r,loadingOverlayVariant:o,overlayType:i}=e;return wm({root:["main",r&&"main--hasPinnedRight",("skeleton"===o||"noColumnsOverlay"===i)&&"main--hiddenContent"],scroller:["virtualScroller",n&&"virtualScroller--hasScrollX"]},YT,t)})(d),h=vN().api.getters,{getContainerProps:m,getScrollerProps:g,getContentProps:v,getPositionerProps:b,getScrollbarVerticalProps:y,getScrollbarHorizontalProps:w,getRows:x,getScrollAreaProps:S}=h,C=x(void 0,xT(t));return Xp.jsxs(IL,f({className:p.root},m(),{ownerState:d,children:[Xp.jsx(fL,f({scrollDirection:"left"},S())),Xp.jsx(fL,f({scrollDirection:"right"},S())),Xp.jsx(fL,f({scrollDirection:"up"},S())),Xp.jsx(fL,f({scrollDirection:"down"},S())),Xp.jsxs(bN,f({className:p.scroller},g(),{ownerState:d,children:[Xp.jsxs(DL,{children:[!n.listView&&Xp.jsx(PL,{}),Xp.jsx(n.slots.pinnedRows,{position:"top",virtualScroller:h})]}),l&&Xp.jsx(aN,{overlayType:l,loadingOverlayVariant:c,children:Xp.jsx(u,f({},n.slotProps?.[l]))}),Xp.jsx(LL,f({},v(),{children:Xp.jsxs(HL,f({role:"rowgroup"},b(),{children:[C,Xp.jsx(n.slots.detailPanels,{virtualScroller:h})]}))})),a&&Xp.jsx(BL,{rowsLength:C.length}),Xp.jsx(n.slots.bottomContainer,{children:Xp.jsx(n.slots.pinnedRows,{position:"bottom",virtualScroller:h})})]})),o&&Xp.jsxs(s.Fragment,{children:[n.pinnedColumnsSectionSeparator?.endsWith("shadow")&&Xp.jsx(rN,{position:"horizontal"}),Xp.jsx(tN,f({position:"horizontal"},w()))]}),r&&Xp.jsxs(s.Fragment,{children:[n.pinnedRowsSectionSeparator?.endsWith("shadow")&&Xp.jsx(rN,{position:"vertical"}),Xp.jsx(tN,f({position:"vertical"},y()))]}),o&&r&&Xp.jsx(eN,{"aria-hidden":"true"}),e.children]}))}function xN(){const e=rP();return e.hideFooter?null:Xp.jsx(e.slots.footer,f({},e.slotProps?.footer))}let SN;function CN(){return void 0===SN&&document.createElement("div").focus({get preventScroll(){return SN=!0,!1}}),SN}const kN=(e,t)=>{if(e)if(t){if(e===nD.LEFT)return"right";if(e===nD.RIGHT)return"left"}else{if(e===nD.LEFT)return"left";if(e===nD.RIGHT)return"right"}};function EN(e,t,n,r){const o=kN(n,t);return o&&void 0!==r?(e[o]=r,e):e}const RN=["column","row","rowId","rowNode","align","children","colIndex","width","className","style","colSpan","disableDragEvents","isNotVisible","pinnedOffset","pinnedPosition","showRightBorder","showLeftBorder","onClick","onDoubleClick","onMouseDown","onMouseUp","onMouseOver","onKeyDown","onKeyUp","onDragEnter","onDragOver"],PN=["changeReason","unstable_updateValueOnRender"];nD.LEFT,ZI.LEFT,nD.RIGHT,ZI.RIGHT,nD.NONE,nD.VIRTUAL;const MN=TR(function(e,t){const{column:n,row:r,rowId:o,rowNode:i,align:a,colIndex:l,width:c,className:u,style:p,colSpan:h,disableDragEvents:m,isNotVisible:g,pinnedOffset:v,pinnedPosition:b,showRightBorder:y,showLeftBorder:w,onClick:x,onDoubleClick:S,onMouseDown:C,onMouseUp:k,onMouseOver:E,onKeyDown:R,onKeyUp:P,onDragEnter:M,onDragOver:T}=e,I=d(e,RN),O=mL(),D=rP(),F=um(),L=n.field,A=pI(O,GL,{rowId:o,field:L}),N=jO().hooks.useCellAggregationResult(o,L),$=A?zI.Edit:zI.View,{value:z,formattedValue:j}=N||{},B=O.current.getCellParamsForRow(o,L,r,{colDef:n,cellMode:$,rowNode:i,tabIndex:pI(O,()=>{const e=JD(O);return e&&e.field===L&&e.id===o?0:-1}),hasFocus:pI(O,()=>{const e=YD(O);return e?.id===o&&e.field===L}),value:z,formattedValue:j});B.api=O.current,pI(O,()=>O.current.isCellEditable(B));const _=pI(O,()=>O.current.unstable_applyPipeProcessors("isCellSelected",!1,{id:o,field:L})),H=O.current.virtualizer.store,V=YM(H,AA.selectors.hiddenCells),W=YM(H,AA.selectors.spannedCells),{hasFocus:U,isEditable:G=!1,value:K}=B,q="view"!==$&&G||"actions"===n.type?-1:B.tabIndex,{classes:Y,getCellClassName:X}=D,Q=[pI(O,()=>O.current.unstable_applyPipeProcessors("cellClassName",[],{id:o,field:L}).filter(Boolean).join(" "))];n.cellClassName&&Q.push("function"==typeof n.cellClassName?n.cellClassName(B):n.cellClassName),"flex"===n.display&&Q.push(XT["cell--flex"]),X&&Q.push(X(B));const Z=B.formattedValue??K,J=s.useRef(null),ee=Tg(t,J),te=D.cellSelection??!1,ne=(e=>{const{align:t,showLeftBorder:n,showRightBorder:r,pinnedPosition:o,isEditable:i,isSelected:a,isSelectionMode:l,classes:s}=e;return wm({root:["cell",`cell--text${xf(t)}`,a&&"selected",i&&"cell--editable",n&&"cell--withLeftBorder",r&&"cell--withRightBorder",o===nD.LEFT&&"cell--pinnedLeft",o===nD.RIGHT&&"cell--pinnedRight",l&&!i&&"cell--selectionMode"]},YT,s)})({align:a,showLeftBorder:w,showRightBorder:y,isEditable:G,classes:D.classes,pinnedPosition:b,isSelected:_,isSelectionMode:te}),re=s.useCallback(e=>t=>{const n=O.current.getCellParams(o,L||"");O.current.publishEvent(e,n,t),k&&k(t)},[O,L,k,o]),oe=s.useCallback(e=>t=>{const n=O.current.getCellParams(o,L||"");O.current.publishEvent(e,n,t),C&&C(t)},[O,L,C,o]),ie=s.useCallback((e,t)=>n=>{if(!O.current.getRow(o))return;const r=O.current.getCellParams(o,L||"");O.current.publishEvent(e,r,n),t&&t(n)},[O,L,o]),ae=V[o]?.[l]??!1,le=W[o]?.[l]??1,se=s.useMemo(()=>{if(g)return{padding:0,opacity:0,width:0,height:0,border:0};const e=EN(f({"--width":`${c}px`},p),F,b,v),t=b===nD.LEFT,n=b===nD.RIGHT;return le>1&&(e.height=`calc(var(--height) * ${le})`,e.zIndex=10,(t||n)&&(e.zIndex=40)),e},[c,g,p,v,b,F,le]);if(Wh(()=>{if(!U||$===zI.Edit)return;const e=kg(O.current.rootElementRef.current);if(J.current&&!J.current.contains(e.activeElement)){const e=J.current.querySelector('[tabindex="0"]')||J.current;if(CN())e.focus({preventScroll:!0});else{const t=O.current.getScrollPosition();e.focus(),O.current.scroll(t)}}},[U,$,O]),ae)return Xp.jsx("div",{"data-colindex":l,role:"presentation",style:f({width:"var(--width)"},se)});let ce,ue,de=I.onFocus;if(null===A&&n.renderCell&&(ce=n.renderCell(B)),null!==A&&n.renderEditCell){const e=O.current.getRowWithUpdatedValues(o,n.field),t=d(A,PN),r=n.valueFormatter?n.valueFormatter(A.value,e,n,O):B.formattedValue,i=f({},B,{row:e,formattedValue:r},t);ce=n.renderEditCell(i),Q.push(XT["cell--editing"]),Q.push(Y?.["cell--editing"])}if(void 0===ce){const e=Z?.toString();ce=e,ue=e}const pe=m?null:{onDragEnter:ie("cellDragEnter",M),onDragOver:ie("cellDragOver",T)};return Xp.jsx("div",f({className:PR(ne.root,Q,u),role:"gridcell","data-field":L,"data-colindex":l,"aria-colindex":l+1,"aria-colspan":h,"aria-rowspan":le,style:se,title:ue,tabIndex:q,onClick:ie("cellClick",x),onDoubleClick:ie("cellDoubleClick",S),onMouseOver:ie("cellMouseOver",E),onMouseDown:oe("cellMouseDown"),onMouseUp:re("cellMouseUp"),onKeyDown:ie("cellKeyDown",R),onKeyUp:ie("cellKeyUp",P)},pe,I,{onFocus:de,ref:ee,children:ce}))}),TN=KT(MN),IN=["field","type","align","width","height","empty","style","className"],ON="1.3em",DN=[40,80],FN={number:[40,60],string:[40,80],date:[40,60],dateTime:[60,80],singleSelect:[40,80]},LN=function(e){const t=(n=e,()=>{let e=n+=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 n;return(e,n)=>e+(n-e)*t()}(12345);const AN=KT(function(e){const{field:t,type:n,align:r,width:o,height:i,empty:a=!1,style:l,className:c}=e,u=d(e,IN),p=rP(),h=(e=>{const{align:t,classes:n,empty:r}=e;return wm({root:["cell","cellSkeleton",`cell--text${t?xf(t):"Left"}`,r&&"cellEmpty"]},YT,n)})({classes:p.classes,align:r,empty:a}),m=s.useMemo(()=>{if("boolean"===n||"actions"===n)return{variant:"circular",width:ON,height:ON};const[e,t]=n?FN[n]??DN:DN;return{variant:"text",width:`${Math.round(LN(e,t))}%`,height:"1.2em"}},[n]);return Xp.jsx("div",f({"data-field":t,className:PR(h.root,c),style:f({height:i,maxWidth:o,minWidth:o},l)},u,{children:!a&&Xp.jsx(p.slots.baseSkeleton,f({},m))}))}),NN={width:3,rx:1.5,x:10.5},$N=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,zN=pg("div",{name:"MuiDataGrid",slot:"Root",overridesResolver:(e,t)=>[t.root,{[`&.${XT.autoHeight}`]:t.autoHeight},{[`&.${XT.autosizing}`]:t.autosizing},{[`&.${XT["root--densityStandard"]}`]:t["root--densityStandard"]},{[`&.${XT["root--densityComfortable"]}`]:t["root--densityComfortable"]},{[`&.${XT["root--densityCompact"]}`]:t["root--densityCompact"]},{[`&.${XT["root--disableUserSelection"]}`]:t["root--disableUserSelection"]},{[`&.${XT["root--noToolbar"]}`]:t["root--noToolbar"]},{[`&.${XT.withVerticalBorder}`]:t.withVerticalBorder},{[`& .${XT.actionsCell}`]:t.actionsCell},{[`& .${XT.booleanCell}`]:t.booleanCell},{[`& .${XT.cell}`]:t.cell},{[`& .${XT["cell--editable"]}`]:t["cell--editable"]},{[`& .${XT["cell--editing"]}`]:t["cell--editing"]},{[`& .${XT["cell--flex"]}`]:t["cell--flex"]},{[`& .${XT["cell--pinnedLeft"]}`]:t["cell--pinnedLeft"]},{[`& .${XT["cell--pinnedRight"]}`]:t["cell--pinnedRight"]},{[`& .${XT["cell--rangeBottom"]}`]:t["cell--rangeBottom"]},{[`& .${XT["cell--rangeLeft"]}`]:t["cell--rangeLeft"]},{[`& .${XT["cell--rangeRight"]}`]:t["cell--rangeRight"]},{[`& .${XT["cell--rangeTop"]}`]:t["cell--rangeTop"]},{[`& .${XT["cell--selectionMode"]}`]:t["cell--selectionMode"]},{[`& .${XT["cell--textCenter"]}`]:t["cell--textCenter"]},{[`& .${XT["cell--textLeft"]}`]:t["cell--textLeft"]},{[`& .${XT["cell--textRight"]}`]:t["cell--textRight"]},{[`& .${XT["cell--withLeftBorder"]}`]:t["cell--withLeftBorder"]},{[`& .${XT["cell--withRightBorder"]}`]:t["cell--withRightBorder"]},{[`& .${XT.cellCheckbox}`]:t.cellCheckbox},{[`& .${XT.cellEmpty}`]:t.cellEmpty},{[`& .${XT.cellOffsetLeft}`]:t.cellOffsetLeft},{[`& .${XT.cellSkeleton}`]:t.cellSkeleton},{[`& .${XT.checkboxInput}`]:t.checkboxInput},{[`& .${XT.columnHeader}`]:t.columnHeader},{[`& .${XT["columnHeader--alignCenter"]}`]:t["columnHeader--alignCenter"]},{[`& .${XT["columnHeader--alignLeft"]}`]:t["columnHeader--alignLeft"]},{[`& .${XT["columnHeader--alignRight"]}`]:t["columnHeader--alignRight"]},{[`& .${XT["columnHeader--dragging"]}`]:t["columnHeader--dragging"]},{[`& .${XT["columnHeader--emptyGroup"]}`]:t["columnHeader--emptyGroup"]},{[`& .${XT["columnHeader--filledGroup"]}`]:t["columnHeader--filledGroup"]},{[`& .${XT["columnHeader--filtered"]}`]:t["columnHeader--filtered"]},{[`& .${XT["columnHeader--last"]}`]:t["columnHeader--last"]},{[`& .${XT["columnHeader--moving"]}`]:t["columnHeader--moving"]},{[`& .${XT["columnHeader--numeric"]}`]:t["columnHeader--numeric"]},{[`& .${XT["columnHeader--pinnedLeft"]}`]:t["columnHeader--pinnedLeft"]},{[`& .${XT["columnHeader--pinnedRight"]}`]:t["columnHeader--pinnedRight"]},{[`& .${XT["columnHeader--siblingFocused"]}`]:t["columnHeader--siblingFocused"]},{[`& .${XT["columnHeader--sortable"]}`]:t["columnHeader--sortable"]},{[`& .${XT["columnHeader--sorted"]}`]:t["columnHeader--sorted"]},{[`& .${XT["columnHeader--withLeftBorder"]}`]:t["columnHeader--withLeftBorder"]},{[`& .${XT["columnHeader--withRightBorder"]}`]:t["columnHeader--withRightBorder"]},{[`& .${XT.columnHeaderCheckbox}`]:t.columnHeaderCheckbox},{[`& .${XT.columnHeaderDraggableContainer}`]:t.columnHeaderDraggableContainer},{[`& .${XT.columnHeaderTitleContainer}`]:t.columnHeaderTitleContainer},{[`& .${XT.columnHeaderTitleContainerContent}`]:t.columnHeaderTitleContainerContent},{[`& .${XT.columnSeparator}`]:t.columnSeparator},{[`& .${XT["columnSeparator--resizable"]}`]:t["columnSeparator--resizable"]},{[`& .${XT["columnSeparator--resizing"]}`]:t["columnSeparator--resizing"]},{[`& .${XT["columnSeparator--sideLeft"]}`]:t["columnSeparator--sideLeft"]},{[`& .${XT["columnSeparator--sideRight"]}`]:t["columnSeparator--sideRight"]},{[`& .${XT["container--bottom"]}`]:t["container--bottom"]},{[`& .${XT["container--top"]}`]:t["container--top"]},{[`& .${XT.detailPanelToggleCell}`]:t.detailPanelToggleCell},{[`& .${XT["detailPanelToggleCell--expanded"]}`]:t["detailPanelToggleCell--expanded"]},{[`& .${XT.editBooleanCell}`]:t.editBooleanCell},{[`& .${XT.filterIcon}`]:t.filterIcon},{[`& .${XT["filler--borderBottom"]}`]:t["filler--borderBottom"]},{[`& .${XT["filler--pinnedLeft"]}`]:t["filler--pinnedLeft"]},{[`& .${XT["filler--pinnedRight"]}`]:t["filler--pinnedRight"]},{[`& .${XT.groupingCriteriaCell}`]:t.groupingCriteriaCell},{[`& .${XT.groupingCriteriaCellLoadingContainer}`]:t.groupingCriteriaCellLoadingContainer},{[`& .${XT.groupingCriteriaCellToggle}`]:t.groupingCriteriaCellToggle},{[`& .${XT.headerFilterRow}`]:t.headerFilterRow},{[`& .${XT.iconSeparator}`]:t.iconSeparator},{[`& .${XT.menuIcon}`]:t.menuIcon},{[`& .${XT.menuIconButton}`]:t.menuIconButton},{[`& .${XT.menuList}`]:t.menuList},{[`& .${XT.menuOpen}`]:t.menuOpen},{[`& .${XT.overlayWrapperInner}`]:t.overlayWrapperInner},{[`& .${XT.pinnedRows}`]:t.pinnedRows},{[`& .${XT["pinnedRows--bottom"]}`]:t["pinnedRows--bottom"]},{[`& .${XT["pinnedRows--top"]}`]:t["pinnedRows--top"]},{[`& .${XT.row}`]:t.row},{[`& .${XT["row--borderBottom"]}`]:t["row--borderBottom"]},{[`& .${XT["row--detailPanelExpanded"]}`]:t["row--detailPanelExpanded"]},{[`& .${XT["row--dragging"]}`]:t["row--dragging"]},{[`& .${XT["row--dynamicHeight"]}`]:t["row--dynamicHeight"]},{[`& .${XT["row--editable"]}`]:t["row--editable"]},{[`& .${XT["row--editing"]}`]:t["row--editing"]},{[`& .${XT["row--firstVisible"]}`]:t["row--firstVisible"]},{[`& .${XT["row--lastVisible"]}`]:t["row--lastVisible"]},{[`& .${XT.rowReorderCell}`]:t.rowReorderCell},{[`& .${XT["rowReorderCell--draggable"]}`]:t["rowReorderCell--draggable"]},{[`& .${XT.rowReorderCellContainer}`]:t.rowReorderCellContainer},{[`& .${XT.rowReorderCellPlaceholder}`]:t.rowReorderCellPlaceholder},{[`& .${XT.rowSkeleton}`]:t.rowSkeleton},{[`& .${XT.scrollbar}`]:t.scrollbar},{[`& .${XT["scrollbar--horizontal"]}`]:t["scrollbar--horizontal"]},{[`& .${XT["scrollbar--vertical"]}`]:t["scrollbar--vertical"]},{[`& .${XT.scrollbarFiller}`]:t.scrollbarFiller},{[`& .${XT["scrollbarFiller--pinnedRight"]}`]:t["scrollbarFiller--pinnedRight"]},{[`& .${XT.sortIcon}`]:t.sortIcon},{[`& .${XT.treeDataGroupingCell}`]:t.treeDataGroupingCell},{[`& .${XT.treeDataGroupingCellLoadingContainer}`]:t.treeDataGroupingCellLoadingContainer},{[`& .${XT.treeDataGroupingCellToggle}`]:t.treeDataGroupingCellToggle},{[`& .${XT.withBorderColor}`]:t.withBorderColor},{[`& .${XT["row--beingDragged"]}`]:t["row--beingDragged"]}]})(()=>{const e=pI(mL(),$N),t=bP.colors.background.base,n=bP.header.background.base,r=bP.cell.background.pinned,o=function(e){return jN(e,1)}(bP.colors.interactive.hover),i=bP.colors.interactive.hoverOpacity,a=bP.colors.interactive.selected,l=bP.colors.interactive.selectedOpacity,s=a,c=`calc(${l} + ${i})`,u=BN(t,o,i),d=BN(t,a,l),p=BN(t,s,c),f=BN(r,o,i),h=BN(r,a,l),m=BN(r,s,c),g=e=>({[`& .${XT["cell--pinnedLeft"]}, & .${XT["cell--pinnedRight"]}`]:{backgroundColor:e,"&.Mui-selected":{backgroundColor:BN(e,d,l),"&:hover":{backgroundColor:BN(e,p,c)}}}}),v=g(f),b=g(h),y=g(m),w={backgroundColor:d,"&:hover":{backgroundColor:p,"@media (hover: none)":{backgroundColor:d}}};return{"--unstable_DataGrid-radius":bP.radius.base,"--unstable_DataGrid-headWeight":bP.typography.fontWeight.medium,"--DataGrid-rowBorderColor":bP.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:bP.colors.border.base,borderRadius:"var(--unstable_DataGrid-radius)",backgroundColor:bP.colors.background.base,color:bP.colors.foreground.base,font:bP.typography.font.body,outline:"none",height:"100%",display:"flex",minWidth:0,minHeight:0,flexDirection:"column",overflow:"hidden",overflowAnchor:"none",transform:"translate(0, 0)",[`.${XT.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)"},[`&.${XT.autoHeight}`]:{height:"auto"},[`&.${XT.autosizing}`]:{[`& .${XT.columnHeaderTitleContainerContent} > *`]:{overflow:"visible !important"},"@media (hover: hover)":{[`& .${XT.menuIcon}`]:{width:"0 !important",visibility:"hidden !important"}},[`& .${XT.cell}`]:{overflow:"visible !important",whiteSpace:"nowrap",minWidth:"max-content !important",maxWidth:"max-content !important"},[`& .${XT.groupingCriteriaCell}`]:{width:"unset"},[`& .${XT.treeDataGroupingCell}`]:{width:"unset"}},[`&.${XT.withSidePanel}`]:{flexDirection:"row"},[`& .${XT.mainContent}`]:{display:"flex",flexDirection:"column",overflow:"hidden",flex:1},[`& .${XT.columnHeader}, & .${XT.cell}`]:{WebkitTapHighlightColor:"transparent",padding:"0 10px",boxSizing:"border-box"},[`& .${XT.columnHeader}:focus-within, & .${XT.cell}:focus-within`]:{outline:`solid ${jN(bP.colors.interactive.focus,.5)} 1px`,outlineOffset:-1},[`& .${XT.columnHeader}:focus, & .${XT.cell}:focus`]:{outline:`solid ${bP.colors.interactive.focus} 1px`,outlineOffset:-1},[`& .${XT.columnHeader}:focus,\n & .${XT["columnHeader--withLeftBorder"]},\n & .${XT["columnHeader--withRightBorder"]},\n & .${XT["columnHeader--siblingFocused"]}\n `]:{[`& .${XT.columnSeparator}`]:{opacity:0},"@media (hover: none)":{[`& .${XT["columnSeparator--resizable"]}`]:{opacity:1}},[`& .${XT["columnSeparator--resizable"]}:hover`]:{opacity:1}},[`&.${XT["root--noToolbar"]} [aria-rowindex="1"] [aria-colindex="1"]`]:{borderTopLeftRadius:"calc(var(--unstable_DataGrid-radius) - 1px)"},[`&.${XT["root--noToolbar"]} [aria-rowindex="1"] .${XT["columnHeader--last"]}`]:{borderTopRightRadius:e?"calc(var(--unstable_DataGrid-radius) - 1px)":void 0},[`& .${XT.columnHeaderCheckbox}, & .${XT.cellCheckbox}`]:{padding:0,justifyContent:"center",alignItems:"center"},[`& .${XT.columnHeader}`]:{position:"relative",display:"flex",alignItems:"center",backgroundColor:n},[`& .${XT.columnHeader} .${XT.sortButton}`]:{backgroundColor:bP.header.background.base},[`& .${XT["columnHeader--filter"]}`]:{paddingTop:8,paddingBottom:8,paddingRight:5,minHeight:"min-content",overflow:"hidden"},[`& .${XT["virtualScroller--hasScrollX"]} .${XT["columnHeader--last"]}`]:{overflow:"hidden"},[`& .${XT["pivotPanelField--sorted"]} .${XT.iconButtonContainer},\n & .${XT["columnHeader--sorted"]} .${XT.iconButtonContainer},\n & .${XT["columnHeader--filtered"]} .${XT.iconButtonContainer}`]:{visibility:"visible",width:"auto"},[`& .${XT.pivotPanelField}:not(.${XT["pivotPanelField--sorted"]}) .${XT.sortButton},\n & .${XT.columnHeader}:not(.${XT["columnHeader--sorted"]}) .${XT.sortButton}`]:{opacity:0,transition:bP.transition(["opacity"],{duration:bP.transitions.duration.short})},[`& .${XT.columnHeaderTitleContainer}`]:{display:"flex",alignItems:"center",gap:bP.spacing(.25),minWidth:0,flex:1,whiteSpace:"nowrap",overflow:"hidden"},[`& .${XT.columnHeaderTitleContainerContent}`]:{overflow:"hidden",display:"flex",alignItems:"center"},[`& .${XT["columnHeader--filledGroup"]} .${XT.columnHeaderTitleContainer}`]:{borderBottomWidth:"1px",borderBottomStyle:"solid",boxSizing:"border-box"},[`& .${XT.sortIcon}, & .${XT.filterIcon}`]:{fontSize:"inherit"},[`& .${XT["columnHeader--sortable"]}`]:{cursor:"pointer"},[`& .${XT["columnHeader--alignCenter"]} .${XT.columnHeaderTitleContainer}`]:{justifyContent:"center"},[`& .${XT["columnHeader--alignRight"]} .${XT.columnHeaderDraggableContainer}, & .${XT["columnHeader--alignRight"]} .${XT.columnHeaderTitleContainer}`]:{flexDirection:"row-reverse"},[`& .${XT["columnHeader--alignCenter"]} .${XT.menuIcon}`]:{marginLeft:"auto"},[`& .${XT["columnHeader--alignRight"]} .${XT.menuIcon}`]:{marginRight:"auto",marginLeft:-5},[`& .${XT["columnHeader--moving"]}`]:{backgroundColor:u},[`& .${XT["columnHeader--pinnedLeft"]}, & .${XT["columnHeader--pinnedRight"]}`]:{position:"sticky",zIndex:40,background:bP.header.background.base},[`& .${XT.columnSeparator}`]:{position:"absolute",overflow:"hidden",zIndex:30,display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",maxWidth:10,color:bP.colors.border.base},[`& .${XT.columnHeaders}`]:{width:"var(--DataGrid-rowWidth)",backgroundColor:n},"@media (hover: hover)":{[`& .${XT.columnHeader}:hover`]:{[`& .${XT.menuIcon}`]:{width:"auto",visibility:"visible"},[`& .${XT.iconButtonContainer}`]:{visibility:"visible",width:"auto"}},[`& .${XT.columnHeader}:not(.${XT["columnHeader--sorted"]}):hover .${XT.sortButton},\n & .${XT.pivotPanelField}:not(.${XT["pivotPanelField--sorted"]}):hover .${XT.sortButton},\n & .${XT.pivotPanelField}:not(.${XT["pivotPanelField--sorted"]}) .${XT.sortButton}:focus-visible`]:{opacity:1},[`& .${XT.columnHeader}:not(.${XT["columnHeader--sorted"]}):hover .${XT.sortButton} > *,\n & .${XT.pivotPanelField}:not(.${XT["pivotPanelField--sorted"]}):hover .${XT.sortButton} > *,\n & .${XT.pivotPanelField}:not(.${XT["pivotPanelField--sorted"]}) .${XT.sortButton}:focus-visible > *`]:{opacity:.78},[`& .${XT.pivotPanelFieldActionContainer} button:hover`]:{backgroundColor:bP.colors.background.base}},"@media (hover: none)":{[`& .${XT.columnHeader} .${XT.menuIcon}`]:{width:"auto",visibility:"visible"},[`& .${XT.columnHeader}:focus,\n & .${XT["columnHeader--siblingFocused"]}`]:{[`.${XT["columnSeparator--resizable"]}`]:{color:bP.colors.foreground.accent}},[`& .${XT.pivotPanelField}:not(.${XT["pivotPanelField--sorted"]}) .${XT.sortButton}`]:{opacity:.78}},[`& .${XT["columnHeader--withLeftBorder"]} .${XT["columnSeparator--sideLeft"]}:not(.${XT["columnSeparator--resizable"]}), & .${XT["columnHeader--withRightBorder"]} .${XT["columnSeparator--sideRight"]}:not(.${XT["columnSeparator--resizable"]})`]:{display:"none"},[`& .${XT["columnSeparator--sideLeft"]}`]:{left:-5},[`& .${XT["columnSeparator--sideRight"]}`]:{right:-5},[`& .${XT["columnHeader--withRightBorder"]} .${XT["columnSeparator--sideLeft"]}`]:{left:-5.5},[`& .${XT["columnHeader--withRightBorder"]} .${XT["columnSeparator--sideRight"]}`]:{right:-5.5},[`& .${XT["columnSeparator--resizable"]}`]:{cursor:"col-resize",touchAction:"none",[`&.${XT["columnSeparator--resizing"]}`]:{color:bP.colors.foreground.accent},"@media (hover: none)":{[`& .${XT.iconSeparator} rect`]:NN},"@media (hover: hover)":{"&:hover":{color:bP.colors.foreground.accent,[`& .${XT.iconSeparator} rect`]:NN}},"& svg":{pointerEvents:"none"}},[`& .${XT.iconSeparator}`]:{color:"inherit",transition:bP.transition(["color","width"],{duration:bP.transitions.duration.short})},[`& .${XT.menuIcon}`]:{width:0,visibility:"hidden",fontSize:20,marginRight:-5,display:"flex",alignItems:"center"},[`.${XT.menuOpen}`]:{visibility:"visible",width:"auto"},[`& .${XT.headerFilterRow}`]:{[`& .${XT.columnHeader}, & .${XT.scrollbarFiller}`]:{boxSizing:"border-box",borderBottom:"1px solid var(--DataGrid-rowBorderColor)"}},[`& .${XT["row--borderBottom"]} .${XT.columnHeader},\n & .${XT["row--borderBottom"]} .${XT.filler},\n & .${XT["row--borderBottom"]} .${XT.scrollbarFiller}`]:{borderBottom:"1px solid var(--DataGrid-rowBorderColor)"},[`& .${XT["row--borderBottom"]} .${XT.cell}`]:{borderBottom:"1px solid var(--rowBorderColor)"},[`.${XT.row}`]:{display:"flex",width:"var(--DataGrid-rowWidth)",breakInside:"avoid","--rowBorderColor":"var(--DataGrid-rowBorderColor)",[`&.${XT["row--firstVisible"]}`]:{"--rowBorderColor":"transparent"},"&:hover":{backgroundColor:u,"@media (hover: none)":{backgroundColor:"transparent"}},[`&.${XT.rowSkeleton}:hover`]:{backgroundColor:"transparent"},"&.Mui-selected":w,position:"relative"},[`& .${XT.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},[`& .${XT["virtualScrollerContent--overflowed"]} .${XT["row--lastVisible"]} .${XT.cell}`]:{borderTopColor:"transparent"},[`& .${XT.pinnedRows} .${XT.row}, .${XT.aggregationRowOverlayWrapper} .${XT.row}`]:{backgroundColor:r,"&:hover":{backgroundColor:f}},[`& .${XT["pinnedRows--top"]} :first-of-type`]:{[`& .${XT.cell}, .${XT.scrollbarFiller}`]:{borderTop:"none"}},[`&.${XT["root--disableUserSelection"]}`]:{userSelect:"none"},[`& .${XT["row--dynamicHeight"]} > .${XT.cell}`]:{whiteSpace:"initial",lineHeight:"inherit"},[`& .${XT.cellEmpty}`]:{flex:1,padding:0,height:"unset"},[`& .${XT.cell}.${XT["cell--selectionMode"]}`]:{cursor:"default"},[`& .${XT.cell}.${XT["cell--editing"]}`]:{padding:1,display:"flex",boxShadow:bP.shadows.base,backgroundColor:bP.colors.background.overlay,"&:focus-within":{outline:`1px solid ${bP.colors.interactive.focus}`,outlineOffset:-1}},[`& .${XT["cell--editing"]}`]:{"& .MuiInputBase-root":{height:"100%"}},[`& .${XT["row--editing"]}`]:{boxShadow:bP.shadows.base},[`& .${XT["row--editing"]} .${XT.cell}`]:{boxShadow:"none",backgroundColor:bP.colors.background.overlay},[`& .${XT.editBooleanCell}`]:{display:"flex",height:"100%",width:"100%",alignItems:"center",justifyContent:"center"},[`& .${XT.booleanCell}[data-value="true"]`]:{color:bP.colors.foreground.muted},[`& .${XT.booleanCell}[data-value="false"]`]:{color:bP.colors.foreground.disabled},[`& .${XT.actionsCell}`]:{display:"inline-flex",alignItems:"center",gridGap:bP.spacing(1)},[`& .${XT.rowReorderCell}`]:{display:"inline-flex",flex:1,alignItems:"center",justifyContent:"center",opacity:bP.colors.interactive.disabledOpacity},[`& .${XT["rowReorderCell--draggable"]}`]:{cursor:"grab",opacity:1},[`& .${XT.rowReorderCellContainer}`]:{padding:0,display:"flex",alignItems:"stretch"},[`.${XT.withBorderColor}`]:{borderColor:bP.colors.border.base},[`& .${XT["cell--withLeftBorder"]}, & .${XT["columnHeader--withLeftBorder"]}`]:{borderLeftColor:"var(--DataGrid-rowBorderColor)",borderLeftWidth:"1px",borderLeftStyle:"solid"},[`& .${XT["cell--withRightBorder"]}, & .${XT["columnHeader--withRightBorder"]}`]:{borderRightColor:"var(--DataGrid-rowBorderColor)",borderRightWidth:"1px",borderRightStyle:"solid"},[`& .${XT["cell--flex"]}`]:{display:"flex",alignItems:"center",lineHeight:"inherit"},[`& .${XT["cell--textLeft"]}`]:{textAlign:"left",justifyContent:"flex-start"},[`& .${XT["cell--textRight"]}`]:{textAlign:"right",justifyContent:"flex-end"},[`& .${XT["cell--textCenter"]}`]:{textAlign:"center",justifyContent:"center"},[`& .${XT["cell--pinnedLeft"]}, & .${XT["cell--pinnedRight"]}`]:{position:"sticky",zIndex:30,background:bP.cell.background.pinned,"&.Mui-selected":{backgroundColor:h}},[`& .${XT.row}`]:{"&:hover":v,"&.Mui-selected":b,"&.Mui-selected:hover":y},[`& .${XT.cellOffsetLeft}`]:{flex:"0 0 auto",display:"inline-block"},[`& .${XT.cellSkeleton}`]:{flex:"0 0 auto",height:"100%",display:"inline-flex",alignItems:"center"},[`& .${XT.columnHeaderDraggableContainer}`]:{display:"flex",width:"100%",height:"100%"},[`& .${XT.rowReorderCellPlaceholder}`]:{display:"none"},[`& .${XT["columnHeader--dragging"]}`]:{background:bP.colors.background.overlay,padding:"0 12px",borderRadius:"var(--unstable_DataGrid-radius)",opacity:bP.colors.interactive.disabledOpacity},[`& .${XT["row--dragging"]}`]:{background:bP.colors.background.overlay,padding:"0 12px",borderRadius:"var(--unstable_DataGrid-radius)",border:"1px solid var(--DataGrid-rowBorderColor)",color:bP.colors.foreground.base,transform:"translateZ(0)",[`& .${XT.rowReorderCellPlaceholder}`]:{padding:"0 6px",display:"flex"}},[`& .${XT.treeDataGroupingCell}`]:{display:"flex",alignItems:"center",width:"100%"},[`& .${XT.treeDataGroupingCellToggle}`]:{flex:"0 0 28px",alignSelf:"stretch",marginRight:bP.spacing(2)},[`& .${XT.treeDataGroupingCellLoadingContainer}, .${XT.groupingCriteriaCellLoadingContainer}`]:{display:"flex",alignItems:"center",justifyContent:"center",height:"100%"},[`& .${XT.groupingCriteriaCell}`]:{display:"flex",alignItems:"center",width:"100%"},[`& .${XT.groupingCriteriaCellToggle}`]:{flex:"0 0 28px",alignSelf:"stretch",marginRight:bP.spacing(2)},[`& .${XT.columnHeaders} .${XT.scrollbarFiller}`]:{backgroundColor:n},[`.${XT.scrollbarFiller}`]:{minWidth:"calc(var(--DataGrid-hasScrollY) * var(--DataGrid-scrollbarSize))",alignSelf:"stretch",backgroundColor:n,[`&.${XT["scrollbarFiller--pinnedRight"]}`]:{position:"sticky",zIndex:40,right:0}},[`& .${XT.filler}`]:{flex:"1 0 auto"},[`& .${XT["filler--borderBottom"]}`]:{borderBottom:"1px solid var(--DataGrid-rowBorderColor)"},[`& .${XT.columnHeaders} .${XT.filler}`]:{backgroundColor:n},[`& .${XT["main--hiddenContent"]}`]:{[`& .${XT.virtualScrollerContent}`]:{position:"fixed",visibility:"hidden"},[`& .${XT.pinnedRows}`]:{display:"none"}},[`& .${XT["row--beingDragged"]}`]:{color:bP.colors.foreground.disabled,"&:hover":{backgroundColor:"transparent"}}}});function jN(e,t){return`rgba(from ${e} r g b / ${t})`}function BN(e,t,n){return`color-mix(in srgb,${e}, ${t} calc(${n} * 100%))`}const _N=()=>()=>{},HN=()=>!1,VN=()=>!0,WN=s.createContext(void 0);function UN(){const e=s.useContext(WN);if(void 0===e)throw new Error("MUI X: Missing context.");return e}function GN({children:e}){const t=s.useRef(null),n=s.useRef(null),r=s.useRef(null),o=s.useMemo(()=>({columnsPanelTriggerRef:t,filterPanelTriggerRef:n,aiAssistantPanelTriggerRef:r}),[]);return Xp.jsx(WN.Provider,{value:o,children:e})}function KN(){const e=lP(),t=pI(e,aO),n=rP(),r=pI(e,KL),{columnsPanelTriggerRef:o,filterPanelTriggerRef:i,aiAssistantPanelTriggerRef:a}=UN(),l=e.current.unstable_applyPipeProcessors("preferencePanel",null,r.openedPanelValue??YL.filters);let s=null;switch(r.openedPanelValue){case YL.filters:s=i.current;break;case YL.columns:s=o.current;break;case YL.aiAssistant:s=a.current}return Xp.jsx(n.slots.panel,f({id:r.panelId,open:t.length>0&&r.open,"aria-labelledby":r.labelId,target:s,onClose:()=>e.current.hidePreferences()},n.slotProps?.panel,{children:l}))}function qN(){const e=rP();return Xp.jsxs(s.Fragment,{children:[Xp.jsx(KN,{}),e.showToolbar&&Xp.jsx(e.slots.toolbar,f({},e.slotProps?.toolbar))]})}const YN=["className","children","sidePanel"],XN=TR(function(e,t){const n=rP(),{className:r,children:o,sidePanel:i}=e,a=d(e,YN),l=mL(),c=pI(l,hI),u=l.current.rootElementRef,p=s.useCallback(e=>{null!==e&&l.current.publishEvent("rootMount",e)},[l]),h=Tg(u,t,p),m=n,g=((e,t)=>{const{autoHeight:n,classes:r,showCellVerticalBorder:o}=e;return wm({root:["root",n&&"autoHeight",`root--density${xf(t)}`,null===e.slots.toolbar&&"root--noToolbar","withBorderColor",o&&"withVerticalBorder"]},YT,r)})(m,c),v=s.useContext(BO);return WM.useSyncExternalStore(_N,HN,VN)?null:Xp.jsxs(zN,f({className:PR(g.root,r,v.className,i&&XT.withSidePanel),ownerState:m},a,{ref:h,children:[Xp.jsxs("div",{className:XT.mainContent,role:"presentation",children:[Xp.jsx(qN,{}),Xp.jsx(wN,{children:o}),Xp.jsx(xN,{})]}),i,v.tag]}))}),QN=KT(XN),ZN=["className"],JN=jh("div",{name:"MuiDataGrid",slot:"FooterContainer"})({display:"flex",justifyContent:"space-between",alignItems:"center",minHeight:52,borderTop:"1px solid"}),e$=TR(function(e,t){const{className:n}=e,r=d(e,ZN),o=rP(),i=(e=>{const{classes:t}=e;return wm({root:["footerContainer","withBorderColor"]},YT,t)})(o);return Xp.jsx(JN,f({className:PR(i.root,n),ownerState:o},r,{ref:t}))}),t$=["className"],n$=jh("div",{name:"MuiDataGrid",slot:"Overlay"})({width:"100%",height:"100%",display:"flex",gap:bP.spacing(1),flexDirection:"column",alignSelf:"center",alignItems:"center",justifyContent:"center",textAlign:"center",textWrap:"balance",backgroundColor:bP.colors.background.backdrop}),r$=TR(function(e,t){const{className:n}=e,r=d(e,t$),o=rP(),i=(e=>{const{classes:t}=e;return wm({root:["overlay"]},YT,t)})(o);return Xp.jsx(n$,f({className:PR(i.root,n),ownerState:o},r,{ref:t}))});function o$(e,t,n,r={}){return"function"==typeof t?t(n,r):t?(t.props.className&&(n.className=function(e,t){if(!e||!t)return e||t;return`${e} ${t}`}(t.props.className,n.className)),(t.props.style||n.style)&&(n.style=f({},n.style,t.props.style)),s.cloneElement(t,n)):s.createElement(e,n)}const i$=s.createContext(void 0);function a$(e,t){if(!e.ref.current||!t.ref.current)return 0;const n=e.ref.current.compareDocumentPosition(t.ref.current);return n?n&Node.DOCUMENT_POSITION_FOLLOWING||n&Node.DOCUMENT_POSITION_CONTAINED_BY?-1:n&Node.DOCUMENT_POSITION_PRECEDING||n&Node.DOCUMENT_POSITION_CONTAINS?1:0:0}const l$=["render","className"],s$=jh("div",{name:"MuiDataGrid",slot:"Toolbar"})({flex:"0 1 1px",display:"flex",alignItems:"center",justifyContent:"end",gap:bP.spacing(.25),padding:bP.spacing(.75),minHeight:52,boxSizing:"border-box",borderBottom:`1px solid ${bP.colors.border.base}`}),c$=TR(function(e,t){const{render:n,className:r}=e,o=d(e,l$),i=rP(),a=(e=>{const{classes:t}=e;return wm({root:["toolbar"]},YT,t)})(i),[l,c]=s.useState(null),[u,p]=s.useState([]),h=s.useCallback(()=>u.sort(a$),[u]),m=s.useCallback((e,t,n=!0)=>{let r=e;const o=h(),i=o.length;for(let e=0;e<i;e+=1){if(r+=t,r>=i){if(!n)return-1;r=0}else if(r<0){if(!n)return-1;r=i-1}if(!o[r].ref.current?.disabled&&"true"!==o[r].ref.current?.ariaDisabled)return r}return-1},[h]),g=s.useCallback((e,t)=>{p(n=>[...n,{id:e,ref:t}])},[]),v=s.useCallback(e=>{p(t=>t.filter(t=>t.id!==e))},[]),b=s.useCallback(e=>{if(!l)return;const t=h(),n=t.findIndex(e=>e.id===l);let r=-1;if("ArrowRight"===e.key?(e.preventDefault(),r=m(n,1)):"ArrowLeft"===e.key?(e.preventDefault(),r=m(n,-1)):"Home"===e.key?(e.preventDefault(),r=m(-1,1,!1)):"End"===e.key&&(e.preventDefault(),r=m(t.length,-1,!1)),r>=0&&r<t.length){const e=t[r];c(e.id),e.ref.current?.focus()}},[h,l,m]),y=s.useCallback(e=>{l!==e&&c(e)},[l,c]),w=s.useCallback(e=>{const t=h(),n=t.findIndex(t=>t.id===e),r=m(n,1);if(r>=0&&r<t.length){const e=t[r];c(e.id),e.ref.current?.focus()}},[h,m]);s.useEffect(()=>{const e=h();if(e.length>0){if(!l)return void c(e[0].id);const t=e.findIndex(e=>e.id===l);if(e[t]){if(-1===t){const n=e[t];n&&(c(n.id),n.ref.current?.focus())}}else{const t=e[e.length-1];t&&(c(t.id),t.ref.current?.focus())}}},[h,m]);const x=s.useMemo(()=>({focusableItemId:l,registerItem:g,unregisterItem:v,onItemKeyDown:b,onItemFocus:y,onItemDisabled:w}),[l,g,v,b,y,w]),S=o$(s$,n,f({role:"toolbar","aria-orientation":"horizontal","aria-label":i.label||void 0,className:PR(a.root,r)},o,{ref:t}));return Xp.jsx(i$.Provider,{value:x,children:S})}),u$=["render","onKeyDown","onFocus","disabled","aria-disabled"],d$=TR(function(e,t){const{render:n,onKeyDown:r,onFocus:o,disabled:i,"aria-disabled":a}=e,l=d(e,u$),c=mm(),u=rP(),p=s.useRef(null),h=Tg(p,t),{focusableItemId:m,registerItem:g,unregisterItem:v,onItemKeyDown:b,onItemFocus:y,onItemDisabled:w}=function(){const e=s.useContext(i$);if(void 0===e)throw new Error("MUI X: Missing context. Toolbar subcomponents must be placed within a <Toolbar /> component.");return e}();s.useEffect(()=>(g(c,p),()=>v(c)),[]);const x=s.useRef(i);s.useEffect(()=>{x.current!==i&&!0===i&&w(c,i),x.current=i},[i,c,w]);const S=s.useRef(a);s.useEffect(()=>{S.current!==a&&!0===a&&w(c,!0),S.current=a},[a,c,w]);const C=o$(u.slots.baseIconButton,n,f({},u.slotProps?.baseIconButton,{tabIndex:m===c?0:-1},l,{disabled:i,"aria-disabled":a,onKeyDown:e=>{b(e),r?.(e)},onFocus:e=>{y(c),o?.(e)},ref:h}));return Xp.jsx(s.Fragment,{children:C})}),p$=s.memo(e=>{const{colDef:t,open:n,columnMenuId:r,columnMenuButtonId:o,iconButtonRef:i}=e,a=lP(),l=rP(),c=(e=>{const{classes:t,open:n}=e;return wm({root:["menuIcon",n&&"menuOpen"],button:["menuIconButton"]},YT,t)})(f({},e,{classes:l.classes})),u=s.useCallback(e=>{e.preventDefault(),e.stopPropagation(),a.current.toggleColumnMenu(t.field)},[a,t.field]),d=t.headerName??t.field;return Xp.jsx("div",{className:c.root,children:Xp.jsx(l.slots.baseTooltip,f({title:a.current.getLocaleText("columnMenuLabel"),enterDelay:1e3},l.slotProps?.baseTooltip,{children:Xp.jsx(l.slots.baseIconButton,f({ref:i,tabIndex:-1,className:c.button,"aria-label":a.current.getLocaleText("columnMenuAriaLabel")(d),size:"small",onClick:u,"aria-haspopup":"menu","aria-expanded":n,"aria-controls":n?r:void 0,id:o},l.slotProps?.baseIconButton,{children:Xp.jsx(l.slots.columnMenuIcon,{fontSize:"inherit"})}))}))})});function f$({columnMenuId:e,columnMenuButtonId:t,ContentComponent:n,contentComponentProps:r,field:o,open:i,target:a,onExited:l}){const s=lP(),c=s.current.getColumn(o),u=Mg(e=>{e&&(e.stopPropagation(),a?.contains(e.target))||s.current.hideColumnMenu()});return a&&c?Xp.jsx(UO,{position:"bottom-"+("right"===c.align?"start":"end"),open:i,target:a,onClose:u,onExited:l,children:Xp.jsx(n,f({colDef:c,hideMenu:u,open:i,id:e,labelledby:t},r))}):null}function h$(e,t){return e.closest(`.${t}`)}function m$(e){return e.replace(/["\\]/g,"\\$&")}function g$(e){return`.${XT.row}[data-id="${m$(String(e))}"]`}function v$(e){return 1===e.target.nodeType&&!e.currentTarget.contains(e.target)}function b$(e,t){return e.rootElementRef.current.querySelector(`.${XT[t]}`)}const y$=({api:e,colIndex:t,position:n,filterFn:r})=>{if(null===t)return[];const o=[];return x$(e).forEach(e=>{e.getAttribute("data-id")&&e.querySelectorAll(`.${XT["left"===n?"cell--pinnedLeft":"cell--pinnedRight"]}`).forEach(e=>{const t=S$(e);null!==t&&r(t)&&o.push(e)})}),o};const w$=({api:e,colIndex:t,position:n,filterFn:r})=>{if(!e.columnHeadersContainerRef?.current)return[];if(null===t)return[];const o=[];return e.columnHeadersContainerRef.current.querySelectorAll(`.${XT["left"===n?"columnHeader--pinnedLeft":"columnHeader--pinnedRight"]}`).forEach(e=>{const t=S$(e);null!==t&&r(t,e)&&o.push(e)}),o};function x$(e){return e.virtualScrollerRef.current.querySelectorAll(`:scope > div > div > .${XT.row}`)}function S$(e){const t=e.getAttribute("aria-colindex");return t?Number(t)-1:null}const C$=["className","aria-label"],k$=jh("div",{name:"MuiDataGrid",slot:"ColumnHeaderTitle"})({textOverflow:"ellipsis",overflow:"hidden",whiteSpace:"nowrap",fontWeight:"var(--unstable_DataGrid-headWeight)",lineHeight:"normal"}),E$=TR(function(e,t){const{className:n}=e,r=d(e,C$),o=rP(),i=(e=>{const{classes:t}=e;return wm({root:["columnHeaderTitle"]},YT,t)})(o);return Xp.jsx(k$,f({className:PR(i.root,n),ownerState:o},r,{ref:t}))});function R$(e){const{label:t,description:n}=e,r=rP(),o=s.useRef(null),[i,a]=s.useState(""),l=s.useCallback(()=>{if(!n&&o?.current){const n=(e=o.current).scrollHeight>e.clientHeight||e.scrollWidth>e.clientWidth;a(n?t:"")}var e},[n,t]);return Xp.jsx(r.slots.baseTooltip,f({title:n||i},r.slotProps?.baseTooltip,{children:Xp.jsx(E$,{onMouseOver:l,ref:o,children:t})}))}const P$=["resizable","resizing","height","side"];var M$=function(e){return e.Left="left",e.Right="right",e}(M$||{});function T$(e){const{height:t,side:n=M$.Right}=e,r=d(e,P$),o=rP(),i=(e=>{const{resizable:t,resizing:n,classes:r,side:o}=e;return wm({root:["columnSeparator",t&&"columnSeparator--resizable",n&&"columnSeparator--resizing",o&&`columnSeparator--side${xf(o)}`],icon:["iconSeparator"]},YT,r)})(f({},e,{side:n,classes:o.classes})),a=s.useCallback(e=>{e.preventDefault(),e.stopPropagation()},[]);return Xp.jsx("div",f({className:i.root,style:{minHeight:t}},r,{onClick:a,children:Xp.jsx(o.slots.columnResizeIcon,{className:i.icon})}))}const I$=s.memo(T$),O$=["classes","columnMenuOpen","colIndex","height","isResizing","sortDirection","hasFocus","tabIndex","separatorSide","isDraggable","headerComponent","description","elementId","width","columnMenuIconButton","columnMenu","columnTitleIconButtons","headerClassName","label","resizable","draggableContainerProps","columnHeaderSeparatorProps","style"],D$=TR(function(e,t){const{classes:n,colIndex:r,height:o,isResizing:i,sortDirection:a,tabIndex:l,separatorSide:c,isDraggable:u,headerComponent:p,description:h,width:m,columnMenuIconButton:g=null,columnMenu:v=null,columnTitleIconButtons:b=null,headerClassName:y,label:w,resizable:x,draggableContainerProps:S,columnHeaderSeparatorProps:C,style:k}=e,E=d(e,O$),R=rP(),P=Tg(s.useRef(null),t);let M="none";return null!=a&&(M="asc"===a?"ascending":"descending"),Xp.jsxs("div",f({className:PR(n.root,y),style:f({},k,{width:m}),role:"columnheader",tabIndex:l,"aria-colindex":r+1,"aria-sort":M},E,{ref:P,children:[Xp.jsxs("div",f({className:n.draggableContainer,draggable:u,role:"presentation"},S,{children:[Xp.jsxs("div",{className:n.titleContainer,role:"presentation",children:[Xp.jsx("div",{className:n.titleContainerContent,children:void 0!==p?p:Xp.jsx(R$,{label:w,description:h,columnWidth:m})}),b]}),g]})),Xp.jsx(I$,f({resizable:!R.disableColumnResize&&!!x,resizing:i,height:o,side:c},C)),v]}))});const F$=KT(function(e){const{colDef:t,columnMenuOpen:n,colIndex:r,headerHeight:o,isResizing:i,isLast:a,sortDirection:l,sortIndex:c,filterItemsCounter:u,hasFocus:d,tabIndex:p,disableReorder:h,separatorSide:m,showLeftBorder:g,showRightBorder:v,pinnedPosition:b,pinnedOffset:y}=e,w=mL(),x=rP(),S=um(),C=s.useRef(null),k=mm(),E=mm(),R=s.useRef(null),[P,M]=s.useState(n),T=!x.disableColumnReorder&&!h&&!t.disableReorder;let I;t.renderHeader&&(I=t.renderHeader(w.current.getColumnHeaderParams(t.field)));const O=(e=>{const{disableColumnSorting:t}=rP(),{colDef:n,classes:r,isDragging:o,sortDirection:i,showRightBorder:a,showLeftBorder:l,filterItemsCounter:s,pinnedPosition:c,isSiblingFocused:u}=e,d=n.sortable&&!t,p=null!=i,f=null!=s&&s>0,h="number"===n.type;return wm({root:["columnHeader","left"===n.headerAlign&&"columnHeader--alignLeft","center"===n.headerAlign&&"columnHeader--alignCenter","right"===n.headerAlign&&"columnHeader--alignRight",d&&"columnHeader--sortable",o&&"columnHeader--moving",p&&"columnHeader--sorted",f&&"columnHeader--filtered",h&&"columnHeader--numeric","withBorderColor",a&&"columnHeader--withRightBorder",l&&"columnHeader--withLeftBorder",c===nD.LEFT&&"columnHeader--pinnedLeft",c===nD.RIGHT&&"columnHeader--pinnedRight",u&&"columnHeader--siblingFocused"],draggableContainer:["columnHeaderDraggableContainer"],titleContainer:["columnHeaderTitleContainer"],titleContainerContent:["columnHeaderTitleContainerContent"]},YT,r)})(f({},e,{classes:x.classes,showRightBorder:v,showLeftBorder:g})),D=s.useCallback(e=>n=>{v$(n)||w.current.publishEvent(e,w.current.getColumnHeaderParams(t.field),n)},[w,t.field]),F=s.useMemo(()=>({onClick:D("columnHeaderClick"),onContextMenu:D("columnHeaderContextMenu"),onDoubleClick:D("columnHeaderDoubleClick"),onMouseOver:D("columnHeaderOver"),onMouseOut:D("columnHeaderOut"),onMouseEnter:D("columnHeaderEnter"),onMouseLeave:D("columnHeaderLeave"),onKeyDown:D("columnHeaderKeyDown"),onFocus:D("columnHeaderFocus"),onBlur:D("columnHeaderBlur")}),[D]),L=s.useMemo(()=>T?{onDragStart:D("columnHeaderDragStart"),onDragEnter:D("columnHeaderDragEnter"),onDragOver:D("columnHeaderDragOver"),onDragEndCapture:D("columnHeaderDragEnd")}:{},[T,D]),A=s.useMemo(()=>({onMouseDown:D("columnSeparatorMouseDown"),onDoubleClick:D("columnSeparatorDoubleClick")}),[D]);s.useEffect(()=>{!P&&n&&M(n)},[P,n]);const N=s.useCallback(()=>{M(!1)},[]),$=!x.disableColumnMenu&&!t.disableColumnMenu&&Xp.jsx(p$,{colDef:t,columnMenuId:k,columnMenuButtonId:E,open:P,iconButtonRef:R}),z=Xp.jsx(f$,{columnMenuId:k,columnMenuButtonId:E,field:t.field,open:n,target:R.current,ContentComponent:x.slots.columnMenu,contentComponentProps:x.slotProps?.columnMenu,onExited:N}),j=t.sortingOrder??x.sortingOrder,B=(t.sortable||null!=l)&&!t.hideSortIcons&&!x.disableColumnSorting,_=Xp.jsxs(s.Fragment,{children:[!x.disableColumnFilter&&Xp.jsx(x.slots.columnHeaderFilterIconButton,f({field:t.field,counter:u},x.slotProps?.columnHeaderFilterIconButton)),B&&Xp.jsx(x.slots.columnHeaderSortIcon,f({field:t.field,direction:l,index:c,sortingOrder:j,disabled:!t.sortable},x.slotProps?.columnHeaderSortIcon))]});s.useLayoutEffect(()=>{const e=w.current.state.columnMenu;if(d&&!e.open){const e=C.current.querySelector('[tabindex="0"]')||C.current;if(!e)return;if(CN())e.focus({preventScroll:!0});else{const t=w.current.getScrollPosition();e.focus(),w.current.scroll(t)}}},[w,d]);const H="function"==typeof t.headerClassName?t.headerClassName({field:t.field,colDef:t}):t.headerClassName,V=t.headerName??t.field,W=s.useMemo(()=>EN(f({},e.style),S,b,y),[b,y,e.style,S]);return Xp.jsx(D$,f({ref:C,classes:O,columnMenuOpen:n,colIndex:r,height:o,isResizing:i,sortDirection:l,hasFocus:d,tabIndex:p,separatorSide:m,isDraggable:T,headerComponent:I,description:t.description,elementId:t.field,width:t.computedWidth,columnMenuIconButton:$,columnTitleIconButtons:_,headerClassName:PR(H,a&&XT["columnHeader--last"]),label:V,resizable:!x.disableColumnResize&&!!t.resizable,"data-field":t.field,columnMenu:z,draggableContainerProps:L,columnHeaderSeparatorProps:A,style:W},F))}),L$=["className"],A$=jh("div",{name:"MuiDataGrid",slot:"IconButtonContainer"})(()=>({display:"flex",visibility:"hidden",width:0})),N$=TR(function(e,t){const{className:n}=e,r=d(e,L$),o=rP(),i=(e=>{const{classes:t}=e;return wm({root:["iconButtonContainer"]},YT,t)})(o);return Xp.jsx(A$,f({className:PR(i.root,n),ownerState:o},r,{ref:t}))}),$$=["direction","index","sortingOrder","disabled","className"],z$=jh(gI,{name:"MuiDataGrid",slot:"SortButton"})({transition:bP.transition(["opacity"],{duration:bP.transitions.duration.short,easing:bP.transitions.easing.easeInOut})});function j$(e){const{direction:t,index:n,sortingOrder:r,disabled:o,className:i}=e,a=d(e,$$),l=lP(),c=rP(),u=f({},e,{classes:c.classes}),p=(e=>{const{classes:t}=e;return wm({root:["sortButton"],icon:["sortIcon"]},YT,t)})(u),h=function(e,t,n,r){let o;const i={};return"asc"===t?o=e.columnSortedAscendingIcon:"desc"===t?o=e.columnSortedDescendingIcon:(o=e.columnUnsortedIcon,i.sortingOrder=r),o?Xp.jsx(o,f({fontSize:"small",className:n},i)):null}(c.slots,t,p.icon,r);if(!h)return null;const m=Xp.jsx(z$,f({as:c.slots.baseIconButton,ownerState:u,"aria-label":l.current.getLocaleText("columnHeaderSortIconLabel"),title:l.current.getLocaleText("columnHeaderSortIconLabel"),size:"small",disabled:o,className:PR(p.root,i)},c.slotProps?.baseIconButton,a,{children:h}));return Xp.jsxs(s.Fragment,{children:[null!=n&&Xp.jsx(c.slots.baseBadge,{badgeContent:n,color:"default",overlap:"circular",children:m}),null==n&&m]})}function B$(e){return Xp.jsx(N$,{children:Xp.jsx(j$,f({},e,{tabIndex:-1}))})}const _$=s.memo(B$);function H$(e){const{counter:t,field:n,onClick:r}=e,o=lP(),i=rP(),a=(e=>{const{classes:t}=e;return wm({icon:["filterIcon"]},YT,t)})(f({},e,{classes:i.classes})),l=mm(),c=pI(o,qL,l),u=mm(),d=s.useCallback(e=>{e.preventDefault(),e.stopPropagation();const{open:t,openedPanelValue:i}=KL(o);t&&i===YL.filters?o.current.hideFilterPanel():o.current.showFilterPanel(void 0,u,l),r&&r(o.current.getColumnHeaderParams(n),e)},[o,n,r,u,l]);if(!t)return null;const p=Xp.jsx(i.slots.baseIconButton,f({id:l,onClick:d,"aria-label":o.current.getLocaleText("columnHeaderFiltersLabel"),size:"small",tabIndex:-1,"aria-haspopup":"menu","aria-expanded":c,"aria-controls":c?u:void 0},i.slotProps?.baseIconButton,{children:Xp.jsx(i.slots.columnFilteredIcon,{className:a.icon,fontSize:"small"})}));return Xp.jsx(i.slots.baseTooltip,f({title:o.current.getLocaleText("columnHeaderFiltersTooltipActive")(t),enterDelay:1e3},i.slotProps?.baseTooltip,{children:Xp.jsxs(N$,{children:[t>1&&Xp.jsx(i.slots.baseBadge,{badgeContent:t,color:"default",children:p}),1===t&&p]})}))}const V$=["hideMenu","colDef","id","labelledby","className","children","open"],W$=pg(gI)(()=>({minWidth:248}));function U$(e){e.currentTarget.contains(e.target)&&e.stopPropagation()}const G$=TR(function(e,t){const{hideMenu:n,id:r,labelledby:o,className:i,children:a,open:l}=e,c=d(e,V$),u=rP(),p=s.useCallback(e=>{"Tab"===e.key&&e.preventDefault(),NO(e.key)&&n(e)},[n]);return Xp.jsx(W$,f({as:u.slots.baseMenuList,id:r,className:PR(XT.menuList,i),"aria-labelledby":o,onKeyDown:p,onWheel:U$,onTouchMove:U$,autoFocus:l},c,{ref:t,children:a}))}),K$=["displayOrder"];function q$(e){const{colDef:t,onClick:n}=e,r=lP(),o=rP(),i=1===cO(r).filter(e=>!0!==e.disableColumnMenu).length,a=s.useCallback(e=>{i||(r.current.setColumnVisibility(t.field,!1),n(e))},[r,t.field,n,i]);return o.disableColumnSelector||!1===t.hideable?null:Xp.jsx(o.slots.baseMenuItem,{onClick:a,disabled:i,iconStart:Xp.jsx(o.slots.columnMenuHideIcon,{fontSize:"small"}),children:r.current.getLocaleText("columnMenuHideColumn")})}function Y$(e){const{onClick:t}=e,n=lP(),r=rP(),o=s.useCallback(e=>{t(e),n.current.showPreferences(YL.columns)},[n,t]);return r.disableColumnSelector?null:Xp.jsx(r.slots.baseMenuItem,{onClick:o,iconStart:Xp.jsx(r.slots.columnMenuManageColumnsIcon,{fontSize:"small"}),children:n.current.getLocaleText("columnMenuManageColumns")})}const X$=["defaultSlots","defaultSlotProps","slots","slotProps"],Q$={columnMenuSortItem:function(e){const{colDef:t,onClick:n}=e,r=lP(),o=pI(r,gD),i=rP(),a=s.useMemo(()=>{if(!t)return null;const e=o.find(e=>e.field===t.field);return e?.sort},[t,o]),l=t.sortingOrder??i.sortingOrder,c=s.useCallback(e=>{n(e);const o=e.currentTarget.getAttribute("data-value")||null,l="always"===i.multipleColumnsSortingMode;r.current.sortColumn(t.field,o===a?null:o,l)},[r,t,n,a,i.multipleColumnsSortingMode]);if(i.disableColumnSorting||!t||!t.sortable||!l.some(e=>!!e))return null;const u=e=>{const n=r.current.getLocaleText(e);return"function"==typeof n?n(t):n};return Xp.jsxs(s.Fragment,{children:[l.includes("asc")&&"asc"!==a?Xp.jsx(i.slots.baseMenuItem,{onClick:c,"data-value":"asc",iconStart:Xp.jsx(i.slots.columnMenuSortAscendingIcon,{fontSize:"small"}),children:u("columnMenuSortAsc")}):null,l.includes("desc")&&"desc"!==a?Xp.jsx(i.slots.baseMenuItem,{onClick:c,"data-value":"desc",iconStart:Xp.jsx(i.slots.columnMenuSortDescendingIcon,{fontSize:"small"}),children:u("columnMenuSortDesc")}):null,l.includes(null)&&null!=a?Xp.jsx(i.slots.baseMenuItem,{onClick:c,iconStart:i.slots.columnMenuUnsortIcon?Xp.jsx(i.slots.columnMenuUnsortIcon,{fontSize:"small"}):Xp.jsx("span",{}),children:r.current.getLocaleText("columnMenuUnsort")}):null]})},columnMenuFilterItem:function(e){const{colDef:t,onClick:n}=e,r=lP(),o=rP(),i=s.useCallback(e=>{n(e),r.current.showFilterPanel(t.field)},[r,t.field,n]);return o.disableColumnFilter||!t.filterable?null:Xp.jsx(o.slots.baseMenuItem,{onClick:i,iconStart:Xp.jsx(o.slots.columnMenuFilterIcon,{fontSize:"small"}),children:r.current.getLocaleText("columnMenuFilter")})},columnMenuColumnsItem:function(e){return Xp.jsxs(s.Fragment,{children:[Xp.jsx(q$,f({},e)),Xp.jsx(Y$,f({},e))]})}},Z$={columnMenuSortItem:{displayOrder:10},columnMenuFilterItem:{displayOrder:20},columnMenuColumnsItem:{displayOrder:30}},J$=TR(function(e,t){const{defaultSlots:n,defaultSlotProps:r,slots:o,slotProps:i}=e,a=d(e,X$),l=(e=>{const t=mL(),n=rP(),{defaultSlots:r,defaultSlotProps:o,slots:i={},slotProps:a={},hideMenu:l,colDef:c,addDividers:u=!0}=e,p=s.useMemo(()=>f({},r,i),[r,i]),h=s.useMemo(()=>{if(!a||0===Object.keys(a).length)return o;const e=f({},a);return Object.entries(o).forEach(([t,n])=>{e[t]=f({},n,a[t]||{})}),e},[o,a]),m=t.current.unstable_applyPipeProcessors("columnMenu",[],e.colDef),g=s.useMemo(()=>{const e=Object.keys(r);return Object.keys(i).filter(t=>!e.includes(t))},[i,r]);return s.useMemo(()=>{const e=Array.from(new Set([...m,...g])).filter(e=>null!=p[e]),t=e.sort((e,t)=>{const n=h[e],r=h[t];return(Number.isFinite(n?.displayOrder)?n.displayOrder:100)-(Number.isFinite(r?.displayOrder)?r.displayOrder:100)});return t.reduce((e,r,o)=>{let i={colDef:c,onClick:l};const a=h[r];return a&&(i=f({},i,d(a,K$))),u&&o!==t.length-1?[...e,[p[r],i],[n.slots.baseDivider,{}]]:[...e,[p[r],i]]},[])},[u,c,m,l,p,h,g,n.slots.baseDivider])})(f({},a,{defaultSlots:n,defaultSlotProps:r,slots:o,slotProps:i}));return Xp.jsx(G$,f({},a,{ref:t,children:l.map(([e,t],n)=>Xp.jsx(e,f({},t),n))}))}),ez=TR(function(e,t){return Xp.jsx(J$,f({},e,{ref:t,defaultSlots:Q$,defaultSlotProps:Z$}))}),tz=["className"],nz=pg("div",{name:"MuiDataGrid",slot:"PanelWrapper"})({display:"flex",flexDirection:"column",flex:1,"&:focus":{outline:0}}),rz=TR(function(e,t){const{className:n}=e,r=d(e,tz),o=rP(),i=(e=>{const{classes:t}=e;return wm({root:["panelWrapper"]},YT,t)})(o);return Xp.jsx(nz,f({tabIndex:-1,className:PR(i.root,n),ownerState:o},r,{ref:t}))});const oz=["children","className","classes","onClose"],iz=Mh("MuiDataGrid",["panel","paper"]),az=pg(gI,{name:"MuiDataGrid",slot:"panel"})({zIndex:bP.zIndex.panel}),lz=pg("div",{name:"MuiDataGrid",slot:"panelContent"})({backgroundColor:bP.colors.background.overlay,borderRadius:bP.radius.base,boxShadow:bP.shadows.overlay,display:"flex",maxWidth:`calc(100vw - ${bP.spacing(2)})`,overflow:"auto"}),sz=TR((e,t)=>{const{children:n,className:r,onClose:o}=e,i=d(e,oz),a=lP(),l=rP(),c=iz,[u,p]=s.useState(!1),h=_O(),m=Mg(()=>p(!0)),g=Mg(()=>p(!1)),v=Mg(()=>{o?.()}),b=Mg(e=>{"Escape"===e.key&&o?.()}),[y,w]=s.useState(null);return s.useEffect(()=>{const e=a.current.rootElementRef?.current?.querySelector('[data-id="gridPanelAnchor"]');e&&w(e)},[a]),y?Xp.jsx(az,f({as:l.slots.basePopper,ownerState:l,placement:"bottom-end",className:PR(c.panel,r,h),flip:!0,onDidShow:m,onDidHide:g,onClickAway:v,clickAwayMouseEvent:"onPointerUp",clickAwayTouchEvent:!1,focusTrap:!0},i,l.slotProps?.basePopper,{target:e.target??y,ref:t,children:Xp.jsx(lz,{className:c.paper,ownerState:l,onKeyDown:b,children:u&&n})})):null}),cz=["className"],uz=jh("div",{name:"MuiDataGrid",slot:"PanelContent"})({display:"flex",flexDirection:"column",overflow:"auto",flex:"1 1",maxHeight:400,padding:bP.spacing(2.5,1.5,2,1),gap:bP.spacing(2.5)});function dz(e){const{className:t}=e,n=d(e,cz),r=rP(),o=(e=>{const{classes:t}=e;return wm({root:["panelContent"]},YT,t)})(r);return Xp.jsx(uz,f({className:PR(o.root,t),ownerState:r},n))}const pz=["className"],fz=pg("div",{name:"MuiDataGrid",slot:"PanelFooter"})({padding:bP.spacing(1),display:"flex",justifyContent:"space-between",borderTop:`1px solid ${bP.colors.border.base}`});function hz(e){const{className:t}=e,n=d(e,pz),r=rP(),o=(e=>{const{classes:t}=e;return wm({root:["panelFooter"]},YT,t)})(r);return Xp.jsx(fz,f({className:PR(o.root,t),ownerState:r},n))}const mz=["item","hasMultipleFilters","deleteFilter","applyFilterChanges","showMultiFilterOperators","disableMultiFilterOperator","applyMultiFilterOperatorChanges","focusElementRef","logicOperators","columnsSort","filterColumns","deleteIconProps","logicOperatorInputProps","operatorInputProps","columnInputProps","valueInputProps","readOnly","children"],gz=["InputComponentProps"],vz=pg("div",{name:"MuiDataGrid",slot:"FilterForm"})({display:"flex",gap:bP.spacing(1.5)}),bz=pg("div",{name:"MuiDataGrid",slot:"FilterFormDeleteIcon"})({flexShrink:0,display:"flex",justifyContent:"center",alignItems:"center"}),yz=pg("div",{name:"MuiDataGrid",slot:"FilterFormLogicOperatorInput"})({minWidth:75,justifyContent:"end"}),wz=pg("div",{name:"MuiDataGrid",slot:"FilterFormColumnInput"})({width:150}),xz=pg("div",{name:"MuiDataGrid",slot:"FilterFormOperatorInput"})({width:150}),Sz=pg("div",{name:"MuiDataGrid",slot:"FilterFormValueInput"})({width:190}),Cz=e=>e.headerName||e.field,kz=new Intl.Collator,Ez=TR(function(e,t){const{item:n,hasMultipleFilters:r,deleteFilter:o,applyFilterChanges:i,showMultiFilterOperators:a,disableMultiFilterOperator:l,applyMultiFilterOperatorChanges:c,focusElementRef:u,logicOperators:p=[BI.And,BI.Or],columnsSort:h,filterColumns:m,deleteIconProps:g={},logicOperatorInputProps:v={},operatorInputProps:b={},columnInputProps:y={},valueInputProps:w={},readOnly:x}=e,S=d(e,mz),C=lP(),k=pI(C,iO),E=pI(C,mO),R=pI(C,yD),P=mm(),M=mm(),T=mm(),I=mm(),O=rP(),D=(e=>{const{classes:t}=e;return wm({root:["filterForm"],deleteIcon:["filterFormDeleteIcon"],logicOperatorInput:["filterFormLogicOperatorInput"],columnInput:["filterFormColumnInput"],operatorInput:["filterFormOperatorInput"],valueInput:["filterFormValueInput"]},YT,t)})(O),F=s.useRef(null),L=s.useRef(null),A=R.logicOperator??BI.And,N=r&&p.length>0,$=(O.slotProps?.baseSelect||{}).native??!1,z=O.slotProps?.baseSelectOption||{},{InputComponentProps:j}=w,B=d(w,gz),_=pI(C,SL),H=pI(C,kL),{filteredColumns:V,selectedField:W}=s.useMemo(()=>{let e=n.field;const t=!1===k[n.field].filterable?k[n.field]:null;if(t)return{filteredColumns:[t],selectedField:e};if(_)return{filteredColumns:E.filter(e=>void 0!==H.get(e.field)),selectedField:e};if(void 0===m||"function"!=typeof m)return{filteredColumns:E,selectedField:e};const r=m({field:n.field,columns:E,currentFilters:R?.items||[]});return{filteredColumns:E.filter(t=>{const o=r.includes(t.field);return t.field!==n.field||o||(e=void 0),o}),selectedField:e}},[n.field,k,_,m,E,R?.items,H]),U=s.useMemo(()=>{switch(h){case"asc":return V.sort((e,t)=>kz.compare(Cz(e),Cz(t)));case"desc":return V.sort((e,t)=>-kz.compare(Cz(e),Cz(t)));default:return V}},[V,h]),G=n.field?C.current.getColumn(n.field):null,K=s.useMemo(()=>n.operator&&G?G.filterOperators?.find(e=>e.value===n.operator):null,[n,G]),q=s.useCallback(e=>{const t=e.target.value,r=C.current.getColumn(t);if(r.field===G.field)return;const o=r.filterOperators.find(e=>e.value===n.operator)||r.filterOperators[0];let a=!o.InputComponent||o.InputComponent!==K?.InputComponent||r.type!==G.type?void 0:n.value;if("singleSelect"===r.type&&void 0!==a){const e=r,t=NF(e);Array.isArray(a)?a=a.filter(n=>void 0!==$F(n,t,e?.getOptionValue)):void 0===$F(n.value,t,e?.getOptionValue)&&(a=void 0)}i(f({},n,{field:t,operator:o.value,value:a}))},[C,i,n,G,K]),Y=s.useCallback(e=>{const t=e.target.value,r=G?.filterOperators.find(e=>e.value===t);i(f({},n,{operator:t,value:!r?.InputComponent||r?.InputComponent!==K?.InputComponent?void 0:n.value}))},[i,n,G,K]),X=s.useCallback(e=>{const t=e.target.value===BI.And.toString()?BI.And:BI.Or;c(t)},[c]);return s.useImperativeHandle(u,()=>({focus:()=>{K?.InputComponent?F?.current?.focus():L.current.focus()}}),[K]),Xp.jsxs(vz,f({className:D.root,"data-id":n.id,ownerState:O},S,{ref:t,children:[Xp.jsx(bz,f({},g,{className:PR(D.deleteIcon,g.className),ownerState:O,children:Xp.jsx(O.slots.baseIconButton,f({"aria-label":C.current.getLocaleText("filterPanelDeleteIconLabel"),title:C.current.getLocaleText("filterPanelDeleteIconLabel"),onClick:()=>{o(n)},size:"small",disabled:x},O.slotProps?.baseIconButton,{children:Xp.jsx(O.slots.filterPanelDeleteIcon,{fontSize:"small"})}))})),Xp.jsx(yz,f({as:O.slots.baseSelect,sx:[N?{display:"flex"}:{display:"none"},a?{visibility:"visible"}:{visibility:"hidden"},v.sx],className:PR(D.logicOperatorInput,v.className),ownerState:O},v,{size:"small",slotProps:{htmlInput:{"aria-label":C.current.getLocaleText("filterPanelLogicOperator")}},value:A??"",onChange:X,disabled:!!l||1===p.length,native:$},O.slotProps?.baseSelect,{children:p.map(e=>s.createElement(O.slots.baseSelectOption,f({},z,{native:$,key:e.toString(),value:e.toString()}),C.current.getLocaleText((e=>{switch(e){case BI.And:return"filterPanelOperatorAnd";case BI.Or:return"filterPanelOperatorOr";default:throw new Error("MUI X: Invalid `logicOperator` property in the `GridFilterPanel`.")}})(e))))})),Xp.jsx(wz,f({as:O.slots.baseSelect},y,{className:PR(D.columnInput,y.className),ownerState:O,size:"small",labelId:M,id:P,label:C.current.getLocaleText("filterPanelColumns"),value:W??"",onChange:q,native:$,disabled:x},O.slotProps?.baseSelect,{children:U.map(e=>s.createElement(O.slots.baseSelectOption,f({},z,{native:$,key:e.field,value:e.field}),Cz(e)))})),Xp.jsx(xz,f({as:O.slots.baseSelect,size:"small"},b,{className:PR(D.operatorInput,b.className),ownerState:O,labelId:I,label:C.current.getLocaleText("filterPanelOperator"),id:T,value:n.operator,onChange:Y,native:$,inputRef:L,disabled:x},O.slotProps?.baseSelect,{children:G?.filterOperators?.map(e=>s.createElement(O.slots.baseSelectOption,f({},z,{native:$,key:e.value,value:e.value}),e.label||C.current.getLocaleText(`filterOperator${xf(e.value)}`)))})),Xp.jsx(Sz,f({},B,{className:PR(D.valueInput,B.className),ownerState:O,children:K?.InputComponent?Xp.jsx(K.InputComponent,f({apiRef:C,item:n,applyValue:i,focusElementRef:F,disabled:x,slotProps:{root:{size:"small"}}},K.InputComponentProps,j),n.field):null}))]}))}),Rz=["logicOperators","columnsSort","filterFormProps","getColumnForNewFilter","children","disableAddFilterButton","disableRemoveAllButton"],Pz=e=>({field:e.field,operator:e.filterOperators[0].value,id:Math.round(1e5*Math.random())}),Mz=TR(function(e,t){const n=lP(),r=rP(),o=pI(n,yD),i=pI(n,mO),a=pI(n,gO),l=s.useRef(null),c=s.useRef(null),{logicOperators:u=[BI.And,BI.Or],columnsSort:p,filterFormProps:h,getColumnForNewFilter:m,disableAddFilterButton:g=!1,disableRemoveAllButton:v=!1}=e,b=d(e,Rz),y=n.current.upsertFilterItem,w=s.useCallback(e=>{n.current.setFilterLogicOperator(e)},[n]),x=s.useCallback(()=>{let e;if(m&&"function"==typeof m){const t=m({currentFilters:o?.items||[],columns:i});if(null===t)return null;e=i.find(({field:e})=>e===t)}else e=i.find(e=>e.filterOperators?.length);return e?Pz(e):null},[o?.items,i,m]),S=s.useCallback(()=>{if(void 0===m||"function"!=typeof m)return x();const e=o.items.length?o.items:[x()].filter(Boolean),t=m({currentFilters:e,columns:i});if(null===t)return null;const n=i.find(({field:e})=>e===t);return n?Pz(n):null},[o.items,i,m,x]),C=s.useMemo(()=>o.items.length?o.items:(c.current||(c.current=x()),c.current?[c.current]:[]),[o.items,x]),k=C.length>1,{readOnlyFilters:E,validFilters:R}=s.useMemo(()=>C.reduce((e,t)=>(a[t.field]?e.validFilters.push(t):e.readOnlyFilters.push(t),e),{readOnlyFilters:[],validFilters:[]}),[C,a]),P=s.useCallback(()=>{const e=S();e&&n.current.upsertFilterItems([...C,e])},[n,S,C]),M=s.useCallback(e=>{const t=1===R.length;n.current.deleteFilterItem(e),t&&n.current.hideFilterPanel()},[n,R.length]),T=s.useCallback(()=>1===R.length&&void 0===R[0].value?(n.current.deleteFilterItem(R[0]),n.current.hideFilterPanel()):n.current.setFilterModel(f({},o,{items:E}),"removeAllFilterItems"),[n,E,o,R]);return s.useEffect(()=>{u.length>0&&o.logicOperator&&!u.includes(o.logicOperator)&&w(u[0])},[u,w,o.logicOperator]),s.useEffect(()=>{R.length>0&&l.current.focus()},[R.length]),Xp.jsxs(rz,f({},b,{ref:t,children:[Xp.jsxs(dz,{children:[E.map((e,t)=>Xp.jsx(Ez,f({item:e,applyFilterChanges:y,deleteFilter:M,hasMultipleFilters:k,showMultiFilterOperators:t>0,disableMultiFilterOperator:1!==t,applyMultiFilterOperatorChanges:w,focusElementRef:null,readOnly:!0,logicOperators:u,columnsSort:p},h),null==e.id?t:e.id)),R.map((e,t)=>Xp.jsx(Ez,f({item:e,applyFilterChanges:y,deleteFilter:M,hasMultipleFilters:k,showMultiFilterOperators:E.length+t>0,disableMultiFilterOperator:E.length+t!==1,applyMultiFilterOperatorChanges:w,focusElementRef:t===R.length-1?l:null,logicOperators:u,columnsSort:p},h),null==e.id?t+E.length:e.id))]}),r.disableMultipleColumnsFiltering||g&&v?null:Xp.jsxs(hz,{children:[g?Xp.jsx("span",{}):Xp.jsx(r.slots.baseButton,f({onClick:P,startIcon:Xp.jsx(r.slots.filterPanelAddIcon,{})},r.slotProps?.baseButton,{children:n.current.getLocaleText("filterPanelAddFilter")})),!v&&R.length>0?Xp.jsx(r.slots.baseButton,f({onClick:T,startIcon:Xp.jsx(r.slots.filterPanelRemoveAllIcon,{})},r.slotProps?.baseButton,{children:n.current.getLocaleText("filterPanelRemoveAll")})):null]})]}))}),Tz=(e,t)=>(e.headerName||e.field).toLowerCase().indexOf(t)>-1,Iz=["children"],Oz=zp({from:{opacity:0},to:{opacity:1}}),Dz=zp({"from, to":{"--scrollable":'" "'}}),Fz=jh("div",{name:"MuiDataGrid",slot:"ShadowScrollArea"})`
|
|
213
|
+
`:null,Ck=pg("span",{name:"MuiSkeleton",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[n.variant],!1!==n.animation&&t[n.animation],n.hasChildren&&t.withChildren,n.hasChildren&&!n.width&&t.fitContent,n.hasChildren&&!n.height&&t.heightAuto]}})(vg(({theme:e})=>{const t=(n=e.shape.borderRadius,String(n).match(/[\d.\-+]*\s*(.*)/)[1]||""||"px");var n;const r=function(e){return parseFloat(e)}(e.shape.borderRadius);return{display:"block",backgroundColor:e.vars?e.vars.palette.Skeleton.bg:e.alpha(e.palette.text.primary,"light"===e.palette.mode?.11:.13),height:"1.2em",variants:[{props:{variant:"text"},style:{marginTop:0,marginBottom:0,height:"auto",transformOrigin:"0 55%",transform:"scale(1, 0.60)",borderRadius:`${r}${t}/${Math.round(r/.6*10)/10}${t}`,"&:empty:before":{content:'"\\00a0"'}}},{props:{variant:"circular"},style:{borderRadius:"50%"}},{props:{variant:"rounded"},style:{borderRadius:(e.vars||e).shape.borderRadius}},{props:({ownerState:e})=>e.hasChildren,style:{"& > *":{visibility:"hidden"}}},{props:({ownerState:e})=>e.hasChildren&&!e.width,style:{maxWidth:"fit-content"}},{props:({ownerState:e})=>e.hasChildren&&!e.height,style:{height:"auto"}},{props:{animation:"pulse"},style:xk||{animation:`${yk} 2s ease-in-out 0.5s infinite`}},{props:{animation:"wave"},style:{position:"relative",overflow:"hidden",WebkitMaskImage:"-webkit-radial-gradient(white, black)","&::after":{background:`linear-gradient(\n 90deg,\n transparent,\n ${(e.vars||e).palette.action.hover},\n transparent\n )`,content:'""',position:"absolute",transform:"translateX(-100%)",bottom:0,left:0,right:0,top:0}}},{props:{animation:"wave"},style:Sk||{"&::after":{animation:`${wk} 2s linear 0.5s infinite`}}}]}})),kk=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiSkeleton"}),{animation:r="pulse",className:o,component:i="span",height:a,style:l,variant:s="text",width:c,...u}=n,d={...n,animation:r,component:i,variant:s,hasChildren:Boolean(u.children)},p=(e=>{const{classes:t,variant:n,animation:r,hasChildren:o,width:i,height:a}=e;return wm({root:["root",n,r,o&&"withChildren",o&&!i&&"fitContent",o&&!a&&"heightAuto"]},bk,t)})(d);return Xp.jsx(Ck,{as:i,ref:t,className:mg(p.root,o),ownerState:d,...u,style:{width:c,height:a,...l}})});function Ek(e){return Ph("MuiSnackbarContent",e)}Mh("MuiSnackbarContent",["root","message","action"]);const Rk=pg(qg,{name:"MuiSnackbarContent",slot:"Root"})(vg(({theme:e})=>{const t="light"===e.palette.mode?.8:.98;return{...e.typography.body2,color:e.vars?e.vars.palette.SnackbarContent.color:e.palette.getContrastText(lm(e.palette.background.default,t)),backgroundColor:e.vars?e.vars.palette.SnackbarContent.bg:lm(e.palette.background.default,t),display:"flex",alignItems:"center",flexWrap:"wrap",padding:"6px 16px",flexGrow:1,[e.breakpoints.up("sm")]:{flexGrow:"initial",minWidth:288}}})),Pk=pg("div",{name:"MuiSnackbarContent",slot:"Message"})({padding:"8px 0"}),Mk=pg("div",{name:"MuiSnackbarContent",slot:"Action"})({display:"flex",alignItems:"center",marginLeft:"auto",paddingLeft:16,marginRight:-8}),Tk=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiSnackbarContent"}),{action:r,className:o,message:i,role:a="alert",...l}=n,s=n,c=(e=>{const{classes:t}=e;return wm({root:["root"],action:["action"],message:["message"]},Ek,t)})(s);return Xp.jsxs(Rk,{role:a,elevation:6,className:mg(c.root,o),ownerState:s,ref:t,...l,children:[Xp.jsx(Pk,{className:c.message,ownerState:s,children:i}),r?Xp.jsx(Mk,{className:c.action,ownerState:s,children:r}):null]})});function Ik(e){return Ph("MuiSnackbar",e)}Mh("MuiSnackbar",["root","anchorOriginTopCenter","anchorOriginBottomCenter","anchorOriginTopRight","anchorOriginBottomRight","anchorOriginTopLeft","anchorOriginBottomLeft"]);const Ok=pg("div",{name:"MuiSnackbar",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[`anchorOrigin${xf(n.anchorOrigin.vertical)}${xf(n.anchorOrigin.horizontal)}`]]}})(vg(({theme:e})=>({zIndex:(e.vars||e).zIndex.snackbar,position:"fixed",display:"flex",left:8,right:8,justifyContent:"center",alignItems:"center",variants:[{props:({ownerState:e})=>"top"===e.anchorOrigin.vertical,style:{top:8,[e.breakpoints.up("sm")]:{top:24}}},{props:({ownerState:e})=>"top"!==e.anchorOrigin.vertical,style:{bottom:8,[e.breakpoints.up("sm")]:{bottom:24}}},{props:({ownerState:e})=>"left"===e.anchorOrigin.horizontal,style:{justifyContent:"flex-start",[e.breakpoints.up("sm")]:{left:24,right:"auto"}}},{props:({ownerState:e})=>"right"===e.anchorOrigin.horizontal,style:{justifyContent:"flex-end",[e.breakpoints.up("sm")]:{right:24,left:"auto"}}},{props:({ownerState:e})=>"center"===e.anchorOrigin.horizontal,style:{[e.breakpoints.up("sm")]:{left:"50%",right:"auto",transform:"translateX(-50%)"}}}]}))),Dk=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiSnackbar"}),r=sg(),o={enter:r.transitions.duration.enteringScreen,exit:r.transitions.duration.leavingScreen},{action:i,anchorOrigin:{vertical:a,horizontal:l}={vertical:"bottom",horizontal:"left"},autoHideDuration:c=null,children:u,className:d,ClickAwayListenerProps:p,ContentProps:f,disableWindowBlurListener:h=!1,message:m,onBlur:g,onClose:v,onFocus:b,onMouseEnter:y,onMouseLeave:w,open:x,resumeHideDuration:S,slots:C={},slotProps:k={},TransitionComponent:E,transitionDuration:R=o,TransitionProps:{onEnter:P,onExited:M,...T}={},...I}=n,O={...n,anchorOrigin:{vertical:a,horizontal:l},autoHideDuration:c,disableWindowBlurListener:h,TransitionComponent:E,transitionDuration:R},D=(e=>{const{classes:t,anchorOrigin:n}=e;return wm({root:["root",`anchorOrigin${xf(n.vertical)}${xf(n.horizontal)}`]},Ik,t)})(O),{getRootProps:F,onClickAway:L}=function(e={}){const{autoHideDuration:t=null,disableWindowBlurListener:n=!1,onClose:r,open:o,resumeHideDuration:i}=e,a=Ng();s.useEffect(()=>{if(o)return document.addEventListener("keydown",e),()=>{document.removeEventListener("keydown",e)};function e(e){e.defaultPrevented||"Escape"===e.key&&r?.(e,"escapeKeyDown")}},[o,r]);const l=Mg((e,t)=>{r?.(e,t)}),c=Mg(e=>{r&&null!=e&&a.start(e,()=>{l(null,"timeout")})});s.useEffect(()=>(o&&c(t),a.clear),[o,t,c,a]);const u=a.clear,d=s.useCallback(()=>{null!=t&&c(null!=i?i:.5*t)},[t,i,c]),p=e=>t=>{const n=e.onFocus;n?.(t),u()},f=e=>t=>{const n=e.onMouseEnter;n?.(t),u()},h=e=>t=>{const n=e.onMouseLeave;n?.(t),d()};return s.useEffect(()=>{if(!n&&o)return window.addEventListener("focus",d),window.addEventListener("blur",u),()=>{window.removeEventListener("focus",d),window.removeEventListener("blur",u)}},[n,o,d,u]),{getRootProps:(t={})=>{const n={...Hg(e),...Hg(t)};return{role:"presentation",...t,...n,onBlur:(r=n,e=>{const t=r.onBlur;t?.(e),d()}),onFocus:p(n),onMouseEnter:f(n),onMouseLeave:h(n)};var r},onClickAway:e=>{r?.(e,"clickaway")}}}(O),[A,N]=s.useState(!0),$={slots:{transition:E,...C},slotProps:{content:f,clickAwayListener:p,transition:T,...k}},[z,j]=Ug("root",{ref:t,className:[D.root,d],elementType:Ok,getSlotProps:F,externalForwardedProps:{...$,...I},ownerState:O}),[B,{ownerState:_,...H}]=Ug("clickAwayListener",{elementType:px,externalForwardedProps:$,getSlotProps:e=>({onClickAway:(...t)=>{const n=t[0];e.onClickAway?.(...t),n?.defaultMuiPrevented||L(...t)}}),ownerState:O}),[V,W]=Ug("content",{elementType:Tk,shouldForwardComponentProp:!0,externalForwardedProps:$,additionalProps:{message:m,action:i},ownerState:O}),[U,G]=Ug("transition",{elementType:PS,externalForwardedProps:$,getSlotProps:e=>({onEnter:(...t)=>{e.onEnter?.(...t),((e,t)=>{N(!1),P&&P(e,t)})(...t)},onExited:(...t)=>{e.onExited?.(...t),(e=>{N(!0),M&&M(e)})(...t)}}),additionalProps:{appear:!0,in:x,timeout:R,direction:"top"===a?"down":"up"},ownerState:O});return!x&&A?null:Xp.jsx(B,{...H,...C.clickAwayListener&&{ownerState:_},children:Xp.jsx(z,{...j,children:Xp.jsx(U,{...G,children:u||Xp.jsx(V,{...W})})})})});function Fk(e){return Ph("MuiTooltip",e)}const Lk=Mh("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]);const Ak=pg(My,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.popper,!n.disableInteractive&&t.popperInteractive,n.arrow&&t.popperArrow,!n.open&&t.popperClose]}})(vg(({theme:e})=>({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none",variants:[{props:({ownerState:e})=>!e.disableInteractive,style:{pointerEvents:"auto"}},{props:({open:e})=>!e,style:{pointerEvents:"none"}},{props:({ownerState:e})=>e.arrow,style:{[`&[data-popper-placement*="bottom"] .${Lk.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${Lk.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${Lk.arrow}`]:{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}},[`&[data-popper-placement*="left"] .${Lk.arrow}`]:{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}}}},{props:({ownerState:e})=>e.arrow&&!e.isRtl,style:{[`&[data-popper-placement*="right"] .${Lk.arrow}`]:{left:0,marginLeft:"-0.71em"}}},{props:({ownerState:e})=>e.arrow&&!!e.isRtl,style:{[`&[data-popper-placement*="right"] .${Lk.arrow}`]:{right:0,marginRight:"-0.71em"}}},{props:({ownerState:e})=>e.arrow&&!e.isRtl,style:{[`&[data-popper-placement*="left"] .${Lk.arrow}`]:{right:0,marginRight:"-0.71em"}}},{props:({ownerState:e})=>e.arrow&&!!e.isRtl,style:{[`&[data-popper-placement*="left"] .${Lk.arrow}`]:{left:0,marginLeft:"-0.71em"}}}]}))),Nk=pg("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.tooltip,n.touch&&t.touch,n.arrow&&t.tooltipArrow,t[`tooltipPlacement${xf(n.placement.split("-")[0])}`]]}})(vg(({theme:e})=>{return{backgroundColor:e.vars?e.vars.palette.Tooltip.bg:e.alpha(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium,[`.${Lk.popper}[data-popper-placement*="left"] &`]:{transformOrigin:"right center"},[`.${Lk.popper}[data-popper-placement*="right"] &`]:{transformOrigin:"left center"},[`.${Lk.popper}[data-popper-placement*="top"] &`]:{transformOrigin:"center bottom",marginBottom:"14px"},[`.${Lk.popper}[data-popper-placement*="bottom"] &`]:{transformOrigin:"center top",marginTop:"14px"},variants:[{props:({ownerState:e})=>e.arrow,style:{position:"relative",margin:0}},{props:({ownerState:e})=>e.touch,style:{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:(t=16/14,Math.round(1e5*t)/1e5)+"em",fontWeight:e.typography.fontWeightRegular}},{props:({ownerState:e})=>!e.isRtl,style:{[`.${Lk.popper}[data-popper-placement*="left"] &`]:{marginRight:"14px"},[`.${Lk.popper}[data-popper-placement*="right"] &`]:{marginLeft:"14px"}}},{props:({ownerState:e})=>!e.isRtl&&e.touch,style:{[`.${Lk.popper}[data-popper-placement*="left"] &`]:{marginRight:"24px"},[`.${Lk.popper}[data-popper-placement*="right"] &`]:{marginLeft:"24px"}}},{props:({ownerState:e})=>!!e.isRtl,style:{[`.${Lk.popper}[data-popper-placement*="left"] &`]:{marginLeft:"14px"},[`.${Lk.popper}[data-popper-placement*="right"] &`]:{marginRight:"14px"}}},{props:({ownerState:e})=>!!e.isRtl&&e.touch,style:{[`.${Lk.popper}[data-popper-placement*="left"] &`]:{marginLeft:"24px"},[`.${Lk.popper}[data-popper-placement*="right"] &`]:{marginRight:"24px"}}},{props:({ownerState:e})=>e.touch,style:{[`.${Lk.popper}[data-popper-placement*="top"] &`]:{marginBottom:"24px"}}},{props:({ownerState:e})=>e.touch,style:{[`.${Lk.popper}[data-popper-placement*="bottom"] &`]:{marginTop:"24px"}}}]};var t})),$k=pg("span",{name:"MuiTooltip",slot:"Arrow"})(vg(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:e.alpha(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}})));let zk=!1;const jk=new Ag;let Bk={x:0,y:0};function _k(e,t){return(n,...r)=>{t&&t(n,...r),e(n,...r)}}const Hk=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiTooltip"}),{arrow:r=!1,children:o,classes:i,components:a={},componentsProps:l={},describeChild:c=!1,disableFocusListener:u=!1,disableHoverListener:d=!1,disableInteractive:p=!1,disableTouchListener:f=!1,enterDelay:h=100,enterNextDelay:m=0,enterTouchDelay:g=700,followCursor:v=!1,id:b,leaveDelay:y=0,leaveTouchDelay:w=1500,onClose:x,onOpen:S,open:C,placement:k="bottom",PopperComponent:E,PopperProps:R={},slotProps:P={},slots:M={},title:T,TransitionComponent:I,TransitionProps:O,...D}=n,F=s.isValidElement(o)?o:Xp.jsx("span",{children:o}),L=sg(),A=um(),[N,$]=s.useState(),[z,j]=s.useState(null),B=s.useRef(!1),_=p||v,H=Ng(),V=Ng(),W=Ng(),U=Ng(),[G,K]=Pg({controlled:C,default:!1,name:"Tooltip",state:"open"});let q=G;const Y=mm(b),X=s.useRef(),Q=Mg(()=>{void 0!==X.current&&(document.body.style.WebkitUserSelect=X.current,X.current=void 0),U.clear()});s.useEffect(()=>Q,[Q]);const Z=e=>{jk.clear(),zk=!0,K(!0),S&&!q&&S(e)},J=Mg(e=>{jk.start(800+y,()=>{zk=!1}),K(!1),x&&q&&x(e),H.start(L.transitions.duration.shortest,()=>{B.current=!1})}),ee=e=>{B.current&&"touchstart"!==e.type||(N&&N.removeAttribute("title"),V.clear(),W.clear(),h||zk&&m?V.start(zk?m:h,()=>{Z(e)}):Z(e))},te=e=>{V.clear(),W.start(y,()=>{J(e)})},[,ne]=s.useState(!1),re=e=>{Xg(e.target)||(ne(!1),te(e))},oe=e=>{N||$(e.currentTarget),Xg(e.target)&&(ne(!0),ee(e))},ie=e=>{B.current=!0;const t=F.props;t.onTouchStart&&t.onTouchStart(e)},ae=e=>{ie(e),W.clear(),H.clear(),Q(),X.current=document.body.style.WebkitUserSelect,document.body.style.WebkitUserSelect="none",U.start(g,()=>{document.body.style.WebkitUserSelect=X.current,ee(e)})},le=e=>{F.props.onTouchEnd&&F.props.onTouchEnd(e),Q(),W.start(w,()=>{J(e)})};s.useEffect(()=>{if(q)return document.addEventListener("keydown",e),()=>{document.removeEventListener("keydown",e)};function e(e){"Escape"===e.key&&J(e)}},[J,q]);const se=Tg(wy(F),$,t);T||0===T||(q=!1);const ce=s.useRef(),ue={},de="string"==typeof T;c?(ue.title=q||!de||d?null:T,ue["aria-describedby"]=q?Y:null):(ue["aria-label"]=de?T:null,ue["aria-labelledby"]=q&&!de?Y:null);const pe={...ue,...D,...F.props,className:mg(D.className,F.props.className),onTouchStart:ie,ref:se,...v?{onMouseMove:e=>{const t=F.props;t.onMouseMove&&t.onMouseMove(e),Bk={x:e.clientX,y:e.clientY},ce.current&&ce.current.update()}}:{}},fe={};f||(pe.onTouchStart=ae,pe.onTouchEnd=le),d||(pe.onMouseOver=_k(ee,pe.onMouseOver),pe.onMouseLeave=_k(te,pe.onMouseLeave),_||(fe.onMouseOver=ee,fe.onMouseLeave=te)),u||(pe.onFocus=_k(oe,pe.onFocus),pe.onBlur=_k(re,pe.onBlur),_||(fe.onFocus=oe,fe.onBlur=re));const he={...n,isRtl:A,arrow:r,disableInteractive:_,placement:k,PopperComponentProp:E,touch:B.current},me="function"==typeof P.popper?P.popper(he):P.popper,ge=s.useMemo(()=>{let e=[{name:"arrow",enabled:Boolean(z),options:{element:z,padding:4}}];return R.popperOptions?.modifiers&&(e=e.concat(R.popperOptions.modifiers)),me?.popperOptions?.modifiers&&(e=e.concat(me.popperOptions.modifiers)),{...R.popperOptions,...me?.popperOptions,modifiers:e}},[z,R.popperOptions,me?.popperOptions]),ve=(e=>{const{classes:t,disableInteractive:n,arrow:r,touch:o,placement:i}=e;return wm({popper:["popper",!n&&"popperInteractive",r&&"popperArrow"],tooltip:["tooltip",r&&"tooltipArrow",o&&"touch",`tooltipPlacement${xf(i.split("-")[0])}`],arrow:["arrow"]},Fk,t)})(he),be="function"==typeof P.transition?P.transition(he):P.transition,ye={slots:{popper:a.Popper,transition:a.Transition??I,tooltip:a.Tooltip,arrow:a.Arrow,...M},slotProps:{arrow:P.arrow??l.arrow,popper:{...R,...me??l.popper},tooltip:P.tooltip??l.tooltip,transition:{...O,...be??l.transition}}},[we,xe]=Ug("popper",{elementType:Ak,externalForwardedProps:ye,ownerState:he,className:mg(ve.popper,R?.className)}),[Se,Ce]=Ug("transition",{elementType:PS,externalForwardedProps:ye,ownerState:he}),[ke,Ee]=Ug("tooltip",{elementType:Nk,className:ve.tooltip,externalForwardedProps:ye,ownerState:he}),[Re,Pe]=Ug("arrow",{elementType:$k,className:ve.arrow,externalForwardedProps:ye,ownerState:he,ref:j});return Xp.jsxs(s.Fragment,{children:[s.cloneElement(F,pe),Xp.jsx(we,{as:E??My,placement:k,anchorEl:v?{getBoundingClientRect:()=>({top:Bk.y,left:Bk.x,right:Bk.x,bottom:Bk.y,width:0,height:0})}:N,popperRef:ce,open:!!N&&q,id:Y,transition:!0,...fe,...xe,popperOptions:ge,children:({TransitionProps:e})=>Xp.jsx(Se,{timeout:L.transitions.duration.shorter,...e,...Ce,children:Xp.jsxs(ke,{...Ee,children:[T,r?Xp.jsx(Re,{...Pe}):null]})})})]})});function Vk(e){return Ph("MuiSwitch",e)}const Wk=Mh("MuiSwitch",["root","edgeStart","edgeEnd","switchBase","colorPrimary","colorSecondary","sizeSmall","sizeMedium","checked","disabled","input","thumb","track"]),Uk=pg("span",{name:"MuiSwitch",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.edge&&t[`edge${xf(n.edge)}`],t[`size${xf(n.size)}`]]}})({display:"inline-flex",width:58,height:38,overflow:"hidden",padding:12,boxSizing:"border-box",position:"relative",flexShrink:0,zIndex:0,verticalAlign:"middle","@media print":{colorAdjust:"exact"},variants:[{props:{edge:"start"},style:{marginLeft:-8}},{props:{edge:"end"},style:{marginRight:-8}},{props:{size:"small"},style:{width:40,height:24,padding:7,[`& .${Wk.thumb}`]:{width:16,height:16},[`& .${Wk.switchBase}`]:{padding:4,[`&.${Wk.checked}`]:{transform:"translateX(16px)"}}}}]}),Gk=pg(ex,{name:"MuiSwitch",slot:"SwitchBase",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.switchBase,{[`& .${Wk.input}`]:t.input},"default"!==n.color&&t[`color${xf(n.color)}`]]}})(vg(({theme:e})=>({position:"absolute",top:0,left:0,zIndex:1,color:e.vars?e.vars.palette.Switch.defaultColor:`${"light"===e.palette.mode?e.palette.common.white:e.palette.grey[300]}`,transition:e.transitions.create(["left","transform"],{duration:e.transitions.duration.shortest}),[`&.${Wk.checked}`]:{transform:"translateX(20px)"},[`&.${Wk.disabled}`]:{color:e.vars?e.vars.palette.Switch.defaultDisabledColor:`${"light"===e.palette.mode?e.palette.grey[100]:e.palette.grey[600]}`},[`&.${Wk.checked} + .${Wk.track}`]:{opacity:.5},[`&.${Wk.disabled} + .${Wk.track}`]:{opacity:e.vars?e.vars.opacity.switchTrackDisabled:""+("light"===e.palette.mode?.12:.2)},[`& .${Wk.input}`]:{left:"-100%",width:"300%"}})),vg(({theme:e})=>({"&:hover":{backgroundColor:e.alpha((e.vars||e).palette.action.active,(e.vars||e).palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}},variants:[...Object.entries(e.palette).filter(uv(["light"])).map(([t])=>({props:{color:t},style:{[`&.${Wk.checked}`]:{color:(e.vars||e).palette[t].main,"&:hover":{backgroundColor:e.alpha((e.vars||e).palette[t].main,(e.vars||e).palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}},[`&.${Wk.disabled}`]:{color:e.vars?e.vars.palette.Switch[`${t}DisabledColor`]:`${"light"===e.palette.mode?e.lighten(e.palette[t].main,.62):e.darken(e.palette[t].main,.55)}`}},[`&.${Wk.checked} + .${Wk.track}`]:{backgroundColor:(e.vars||e).palette[t].main}}}))]}))),Kk=pg("span",{name:"MuiSwitch",slot:"Track"})(vg(({theme:e})=>({height:"100%",width:"100%",borderRadius:7,zIndex:-1,transition:e.transitions.create(["opacity","background-color"],{duration:e.transitions.duration.shortest}),backgroundColor:e.vars?e.vars.palette.common.onBackground:`${"light"===e.palette.mode?e.palette.common.black:e.palette.common.white}`,opacity:e.vars?e.vars.opacity.switchTrack:""+("light"===e.palette.mode?.38:.3)}))),qk=pg("span",{name:"MuiSwitch",slot:"Thumb"})(vg(({theme:e})=>({boxShadow:(e.vars||e).shadows[1],backgroundColor:"currentColor",width:20,height:20,borderRadius:"50%"}))),Yk=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiSwitch"}),{className:r,color:o="primary",edge:i=!1,size:a="medium",sx:l,slots:s={},slotProps:c={},...u}=n,d={...n,color:o,edge:i,size:a},p=(e=>{const{classes:t,edge:n,size:r,color:o,checked:i,disabled:a}=e,l=wm({root:["root",n&&`edge${xf(n)}`,`size${xf(r)}`],switchBase:["switchBase",`color${xf(o)}`,i&&"checked",a&&"disabled"],thumb:["thumb"],track:["track"],input:["input"]},Vk,t);return{...t,...l}})(d),f={slots:s,slotProps:c},[h,m]=Ug("root",{className:mg(p.root,r),elementType:Uk,externalForwardedProps:f,ownerState:d,additionalProps:{sx:l}}),[g,v]=Ug("thumb",{className:p.thumb,elementType:qk,externalForwardedProps:f,ownerState:d}),b=Xp.jsx(g,{...v}),[y,w]=Ug("track",{className:p.track,elementType:Kk,externalForwardedProps:f,ownerState:d});return Xp.jsxs(h,{...m,children:[Xp.jsx(Gk,{type:"checkbox",icon:b,checkedIcon:b,ref:t,ownerState:d,...u,classes:{...p,root:p.switchBase},slots:{...s.switchBase&&{root:s.switchBase},...s.input&&{input:s.input}},slotProps:{...c.switchBase&&{root:"function"==typeof c.switchBase?c.switchBase(d):c.switchBase},input:{role:"switch"},...c.input&&{input:"function"==typeof c.input?c.input(d):c.input}}}),Xp.jsx(y,{...w})]})});function Xk(e){return Ph("MuiTab",e)}const Qk=Mh("MuiTab",["root","labelIcon","textColorInherit","textColorPrimary","textColorSecondary","selected","disabled","fullWidth","wrapped","iconWrapper","icon"]),Zk=pg(sv,{name:"MuiTab",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.label&&n.icon&&t.labelIcon,t[`textColor${xf(n.textColor)}`],n.fullWidth&&t.fullWidth,n.wrapped&&t.wrapped,{[`& .${Qk.iconWrapper}`]:t.iconWrapper},{[`& .${Qk.icon}`]:t.icon}]}})(vg(({theme:e})=>({...e.typography.button,maxWidth:360,minWidth:90,position:"relative",minHeight:48,flexShrink:0,padding:"12px 16px",overflow:"hidden",whiteSpace:"normal",textAlign:"center",lineHeight:1.25,variants:[{props:({ownerState:e})=>e.label&&("top"===e.iconPosition||"bottom"===e.iconPosition),style:{flexDirection:"column"}},{props:({ownerState:e})=>e.label&&"top"!==e.iconPosition&&"bottom"!==e.iconPosition,style:{flexDirection:"row"}},{props:({ownerState:e})=>e.icon&&e.label,style:{minHeight:72,paddingTop:9,paddingBottom:9}},{props:({ownerState:e,iconPosition:t})=>e.icon&&e.label&&"top"===t,style:{[`& > .${Qk.icon}`]:{marginBottom:6}}},{props:({ownerState:e,iconPosition:t})=>e.icon&&e.label&&"bottom"===t,style:{[`& > .${Qk.icon}`]:{marginTop:6}}},{props:({ownerState:e,iconPosition:t})=>e.icon&&e.label&&"start"===t,style:{[`& > .${Qk.icon}`]:{marginRight:e.spacing(1)}}},{props:({ownerState:e,iconPosition:t})=>e.icon&&e.label&&"end"===t,style:{[`& > .${Qk.icon}`]:{marginLeft:e.spacing(1)}}},{props:{textColor:"inherit"},style:{color:"inherit",opacity:.6,[`&.${Qk.selected}`]:{opacity:1},[`&.${Qk.disabled}`]:{opacity:(e.vars||e).palette.action.disabledOpacity}}},{props:{textColor:"primary"},style:{color:(e.vars||e).palette.text.secondary,[`&.${Qk.selected}`]:{color:(e.vars||e).palette.primary.main},[`&.${Qk.disabled}`]:{color:(e.vars||e).palette.text.disabled}}},{props:{textColor:"secondary"},style:{color:(e.vars||e).palette.text.secondary,[`&.${Qk.selected}`]:{color:(e.vars||e).palette.secondary.main},[`&.${Qk.disabled}`]:{color:(e.vars||e).palette.text.disabled}}},{props:({ownerState:e})=>e.fullWidth,style:{flexShrink:1,flexGrow:1,flexBasis:0,maxWidth:"none"}},{props:({ownerState:e})=>e.wrapped,style:{fontSize:e.typography.pxToRem(12)}}]}))),Jk=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiTab"}),{className:r,disabled:o=!1,disableFocusRipple:i=!1,fullWidth:a,icon:l,iconPosition:c="top",indicator:u,label:d,onChange:p,onClick:f,onFocus:h,selected:m,selectionFollowsFocus:g,textColor:v="inherit",value:b,wrapped:y=!1,...w}=n,x={...n,disabled:o,disableFocusRipple:i,selected:m,icon:!!l,iconPosition:c,label:!!d,fullWidth:a,textColor:v,wrapped:y},S=(e=>{const{classes:t,textColor:n,fullWidth:r,wrapped:o,icon:i,label:a,selected:l,disabled:s}=e;return wm({root:["root",i&&a&&"labelIcon",`textColor${xf(n)}`,r&&"fullWidth",o&&"wrapped",l&&"selected",s&&"disabled"],icon:["iconWrapper","icon"]},Xk,t)})(x),C=l&&d&&s.isValidElement(l)?s.cloneElement(l,{className:mg(S.icon,l.props.className)}):l;return Xp.jsxs(Zk,{focusRipple:!i,className:mg(S.root,r),ref:t,role:"tab","aria-selected":m,disabled:o,onClick:e=>{!m&&p&&p(e,b),f&&f(e)},onFocus:e=>{g&&!m&&p&&p(e,b),h&&h(e)},ownerState:x,tabIndex:m?0:-1,...w,children:["top"===c||"start"===c?Xp.jsxs(s.Fragment,{children:[C,d]}):Xp.jsxs(s.Fragment,{children:[d,C]}),u]})}),eE=s.createContext(),tE=s.createContext();function nE(e){return Ph("MuiTableCell",e)}const rE=Mh("MuiTableCell",["root","head","body","footer","sizeSmall","sizeMedium","paddingCheckbox","paddingNone","alignLeft","alignCenter","alignRight","alignJustify","stickyHeader"]),oE=pg("td",{name:"MuiTableCell",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[n.variant],t[`size${xf(n.size)}`],"normal"!==n.padding&&t[`padding${xf(n.padding)}`],"inherit"!==n.align&&t[`align${xf(n.align)}`],n.stickyHeader&&t.stickyHeader]}})(vg(({theme:e})=>({...e.typography.body2,display:"table-cell",verticalAlign:"inherit",borderBottom:e.vars?`1px solid ${e.vars.palette.TableCell.border}`:`1px solid\n ${"light"===e.palette.mode?e.lighten(e.alpha(e.palette.divider,1),.88):e.darken(e.alpha(e.palette.divider,1),.68)}`,textAlign:"left",padding:16,variants:[{props:{variant:"head"},style:{color:(e.vars||e).palette.text.primary,lineHeight:e.typography.pxToRem(24),fontWeight:e.typography.fontWeightMedium}},{props:{variant:"body"},style:{color:(e.vars||e).palette.text.primary}},{props:{variant:"footer"},style:{color:(e.vars||e).palette.text.secondary,lineHeight:e.typography.pxToRem(21),fontSize:e.typography.pxToRem(12)}},{props:{size:"small"},style:{padding:"6px 16px",[`&.${rE.paddingCheckbox}`]:{width:24,padding:"0 12px 0 16px","& > *":{padding:0}}}},{props:{padding:"checkbox"},style:{width:48,padding:"0 0 0 4px"}},{props:{padding:"none"},style:{padding:0}},{props:{align:"left"},style:{textAlign:"left"}},{props:{align:"center"},style:{textAlign:"center"}},{props:{align:"right"},style:{textAlign:"right",flexDirection:"row-reverse"}},{props:{align:"justify"},style:{textAlign:"justify"}},{props:({ownerState:e})=>e.stickyHeader,style:{position:"sticky",top:0,zIndex:2,backgroundColor:(e.vars||e).palette.background.default}}]}))),iE=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiTableCell"}),{align:r="inherit",className:o,component:i,padding:a,scope:l,size:c,sortDirection:u,variant:d,...p}=n,f=s.useContext(eE),h=s.useContext(tE),m=h&&"head"===h.variant;let g;g=i||(m?"th":"td");let v=l;"td"===g?v=void 0:!v&&m&&(v="col");const b=d||h&&h.variant,y={...n,align:r,component:g,padding:a||(f&&f.padding?f.padding:"normal"),size:c||(f&&f.size?f.size:"medium"),sortDirection:u,stickyHeader:"head"===b&&f&&f.stickyHeader,variant:b},w=(e=>{const{classes:t,variant:n,align:r,padding:o,size:i,stickyHeader:a}=e;return wm({root:["root",n,a&&"stickyHeader","inherit"!==r&&`align${xf(r)}`,"normal"!==o&&`padding${xf(o)}`,`size${xf(i)}`]},nE,t)})(y);let x=null;return u&&(x="asc"===u?"ascending":"descending"),Xp.jsx(oE,{as:g,ref:t,className:mg(w.root,o),"aria-sort":x,scope:v,ownerState:y,...p})});function aE(e){return Ph("MuiToolbar",e)}Mh("MuiToolbar",["root","gutters","regular","dense"]);const lE=pg("div",{name:"MuiToolbar",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,!n.disableGutters&&t.gutters,t[n.variant]]}})(vg(({theme:e})=>({position:"relative",display:"flex",alignItems:"center",variants:[{props:({ownerState:e})=>!e.disableGutters,style:{paddingLeft:e.spacing(2),paddingRight:e.spacing(2),[e.breakpoints.up("sm")]:{paddingLeft:e.spacing(3),paddingRight:e.spacing(3)}}},{props:{variant:"dense"},style:{minHeight:48}},{props:{variant:"regular"},style:e.mixins.toolbar}]}))),sE=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiToolbar"}),{className:r,component:o="div",disableGutters:i=!1,variant:a="regular",...l}=n,s={...n,component:o,disableGutters:i,variant:a},c=(e=>{const{classes:t,disableGutters:n,variant:r}=e;return wm({root:["root",!n&&"gutters",r]},aE,t)})(s);return Xp.jsx(lE,{as:o,className:mg(c.root,r),ref:t,ownerState:s,...l})});var cE=Sg(Xp.jsx("path",{d:"M15.41 16.09l-4.58-4.59 4.58-4.59L14 5.5l-6 6 6 6z"})),uE=Sg(Xp.jsx("path",{d:"M8.59 16.34l4.58-4.59-4.58-4.59L10 5.75l6 6-6 6z"}));function dE(e){return Ph("MuiTablePaginationActions",e)}Mh("MuiTablePaginationActions",["root"]);const pE=pg("div",{name:"MuiTablePaginationActions",slot:"Root"})({}),fE=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiTablePaginationActions"}),{backIconButtonProps:r,className:o,count:i,disabled:a=!1,getItemAriaLabel:l,nextIconButtonProps:s,onPageChange:c,page:u,rowsPerPage:d,showFirstButton:p,showLastButton:f,slots:h={},slotProps:m={},...g}=n,v=um(),b=(e=>{const{classes:t}=e;return wm({root:["root"]},dE,t)})(n),y=h.firstButton??Mv,w=h.lastButton??Mv,x=h.nextButton??Mv,S=h.previousButton??Mv,C=h.firstButtonIcon??nk,k=h.lastButtonIcon??rk,E=h.nextButtonIcon??uE,R=h.previousButtonIcon??cE,P=v?w:y,M=v?x:S,T=v?S:x,I=v?y:w,O=v?m.lastButton:m.firstButton,D=v?m.nextButton:m.previousButton,F=v?m.previousButton:m.nextButton,L=v?m.firstButton:m.lastButton;return Xp.jsxs(pE,{ref:t,className:mg(b.root,o),...g,children:[p&&Xp.jsx(P,{onClick:e=>{c(e,0)},disabled:a||0===u,"aria-label":l("first",u),title:l("first",u),...O,children:v?Xp.jsx(k,{...m.lastButtonIcon}):Xp.jsx(C,{...m.firstButtonIcon})}),Xp.jsx(M,{onClick:e=>{c(e,u-1)},disabled:a||0===u,color:"inherit","aria-label":l("previous",u),title:l("previous",u),...D??r,children:v?Xp.jsx(E,{...m.nextButtonIcon}):Xp.jsx(R,{...m.previousButtonIcon})}),Xp.jsx(T,{onClick:e=>{c(e,u+1)},disabled:a||-1!==i&&u>=Math.ceil(i/d)-1,color:"inherit","aria-label":l("next",u),title:l("next",u),...F??s,children:v?Xp.jsx(R,{...m.previousButtonIcon}):Xp.jsx(E,{...m.nextButtonIcon})}),f&&Xp.jsx(I,{onClick:e=>{c(e,Math.max(0,Math.ceil(i/d)-1))},disabled:a||u>=Math.ceil(i/d)-1,"aria-label":l("last",u),title:l("last",u),...L,children:v?Xp.jsx(C,{...m.firstButtonIcon}):Xp.jsx(k,{...m.lastButtonIcon})})]})});function hE(e){return Ph("MuiTablePagination",e)}const mE=Mh("MuiTablePagination",["root","toolbar","spacer","selectLabel","selectRoot","select","selectIcon","input","menuItem","displayedRows","actions"]);var gE;const vE=pg(iE,{name:"MuiTablePagination",slot:"Root"})(vg(({theme:e})=>({overflow:"auto",color:(e.vars||e).palette.text.primary,fontSize:e.typography.pxToRem(14),"&:last-child":{padding:0}}))),bE=pg(sE,{name:"MuiTablePagination",slot:"Toolbar",overridesResolver:(e,t)=>({[`& .${mE.actions}`]:t.actions,...t.toolbar})})(vg(({theme:e})=>({minHeight:52,paddingRight:2,[`${e.breakpoints.up("xs")} and (orientation: landscape)`]:{minHeight:52},[e.breakpoints.up("sm")]:{minHeight:52,paddingRight:2},[`& .${mE.actions}`]:{flexShrink:0,marginLeft:20}}))),yE=pg("div",{name:"MuiTablePagination",slot:"Spacer"})({flex:"1 1 100%"}),wE=pg("p",{name:"MuiTablePagination",slot:"SelectLabel"})(vg(({theme:e})=>({...e.typography.body2,flexShrink:0}))),xE=pg(vk,{name:"MuiTablePagination",slot:"Select",overridesResolver:(e,t)=>({[`& .${mE.selectIcon}`]:t.selectIcon,[`& .${mE.select}`]:t.select,...t.input,...t.selectRoot})})({color:"inherit",fontSize:"inherit",flexShrink:0,marginRight:32,marginLeft:8,[`& .${mE.select}`]:{paddingLeft:8,paddingRight:24,textAlign:"right",textAlignLast:"right"}}),SE=pg(_C,{name:"MuiTablePagination",slot:"MenuItem"})({}),CE=pg("p",{name:"MuiTablePagination",slot:"DisplayedRows"})(vg(({theme:e})=>({...e.typography.body2,flexShrink:0})));function kE({from:e,to:t,count:n}){return`${e}–${t} of ${-1!==n?n:`more than ${t}`}`}function EE(e){return`Go to ${e} page`}const RE=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiTablePagination"}),{ActionsComponent:r=fE,backIconButtonProps:o,colSpan:i,component:a=iE,count:l,disabled:c=!1,getItemAriaLabel:u=EE,labelDisplayedRows:d=kE,labelRowsPerPage:p="Rows per page:",nextIconButtonProps:f,onPageChange:h,onRowsPerPageChange:m,page:g,rowsPerPage:v,rowsPerPageOptions:b=[10,25,50,100],SelectProps:y={},showFirstButton:w=!1,showLastButton:x=!1,slotProps:S={},slots:C={},...k}=n,E=n,R=(e=>{const{classes:t}=e;return wm({root:["root"],toolbar:["toolbar"],spacer:["spacer"],selectLabel:["selectLabel"],select:["select"],input:["input"],selectIcon:["selectIcon"],menuItem:["menuItem"],displayedRows:["displayedRows"],actions:["actions"]},hE,t)})(E),P=S?.select??y,M=P.native?"option":SE;let T;a!==iE&&"td"!==a||(T=i||1e3);const I=mm(P.id),O=mm(P.labelId),D={slots:C,slotProps:S},[F,L]=Ug("root",{ref:t,className:R.root,elementType:vE,externalForwardedProps:{...D,component:a,...k},ownerState:E,additionalProps:{colSpan:T}}),[A,N]=Ug("toolbar",{className:R.toolbar,elementType:bE,externalForwardedProps:D,ownerState:E}),[$,z]=Ug("spacer",{className:R.spacer,elementType:yE,externalForwardedProps:D,ownerState:E}),[j,B]=Ug("selectLabel",{className:R.selectLabel,elementType:wE,externalForwardedProps:D,ownerState:E,additionalProps:{id:O}}),[_,H]=Ug("select",{className:R.select,elementType:xE,externalForwardedProps:D,ownerState:E}),[V,W]=Ug("menuItem",{className:R.menuItem,elementType:M,externalForwardedProps:D,ownerState:E}),[U,G]=Ug("displayedRows",{className:R.displayedRows,elementType:CE,externalForwardedProps:D,ownerState:E});return Xp.jsx(F,{...L,children:Xp.jsxs(A,{...N,children:[Xp.jsx($,{...z}),b.length>1&&Xp.jsx(j,{...B,children:p}),b.length>1&&Xp.jsx(_,{variant:"standard",...!P.variant&&{input:gE||(gE=Xp.jsx(nw,{}))},value:v,onChange:m,id:I,labelId:O,...P,classes:{...P.classes,root:mg(R.input,R.selectRoot,(P.classes||{}).root),select:mg(R.select,(P.classes||{}).select),icon:mg(R.selectIcon,(P.classes||{}).icon)},disabled:c,...H,children:b.map(e=>s.createElement(V,{...W,key:e.label?e.label:e,value:e.value?e.value:e},e.label?e.label:e))}),Xp.jsx(U,{...G,children:d({from:0===l?0:g*v+1,to:-1===l?(g+1)*v:-1===v?l:Math.min(l,(g+1)*v),count:-1===l?-1:l,page:g})}),Xp.jsx(r,{className:R.actions,backIconButtonProps:o,count:l,nextIconButtonProps:f,onPageChange:h,page:g,rowsPerPage:v,showFirstButton:w,showLastButton:x,slotProps:S.actions,slots:C.actions,getItemAriaLabel:u,disabled:c})]})})});function PE(e){return(1+Math.sin(Math.PI*e-Math.PI/2))/2}const ME={width:99,height:99,position:"absolute",top:-9999,overflow:"scroll"};function TE(e){return Ph("MuiTabScrollButton",e)}const IE=Mh("MuiTabScrollButton",["root","vertical","horizontal","disabled"]),OE=pg(sv,{name:"MuiTabScrollButton",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.orientation&&t[n.orientation]]}})({width:40,flexShrink:0,opacity:.8,[`&.${IE.disabled}`]:{opacity:0},variants:[{props:{orientation:"vertical"},style:{width:"100%",height:40,"& svg":{transform:"var(--TabScrollButton-svgRotate)"}}}]}),DE=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiTabScrollButton"}),{className:r,slots:o={},slotProps:i={},direction:a,orientation:l,disabled:s,...c}=n,u=um(),d={isRtl:u,...n},p=(e=>{const{classes:t,orientation:n,disabled:r}=e;return wm({root:["root",n,r&&"disabled"]},TE,t)})(d),f=o.StartScrollButtonIcon??cE,h=o.EndScrollButtonIcon??uE,m=yy({elementType:f,externalSlotProps:i.startScrollButtonIcon,additionalProps:{fontSize:"small"},ownerState:d}),g=yy({elementType:h,externalSlotProps:i.endScrollButtonIcon,additionalProps:{fontSize:"small"},ownerState:d});return Xp.jsx(OE,{component:"div",className:mg(p.root,r),ref:t,role:null,ownerState:d,tabIndex:null,...c,style:{...c.style,..."vertical"===l&&{"--TabScrollButton-svgRotate":`rotate(${u?-90:90}deg)`}},children:"left"===a?Xp.jsx(f,{...m}):Xp.jsx(h,{...g})})});function FE(e){return Ph("MuiTabs",e)}const LE=Mh("MuiTabs",["root","vertical","list","flexContainer","flexContainerVertical","centered","scroller","fixed","scrollableX","scrollableY","hideScrollbar","scrollButtons","scrollButtonsHideMobile","indicator"]),AE=(e,t)=>e===t?e.firstChild:t&&t.nextElementSibling?t.nextElementSibling:e.firstChild,NE=(e,t)=>e===t?e.lastChild:t&&t.previousElementSibling?t.previousElementSibling:e.lastChild,$E=(e,t,n)=>{let r=!1,o=n(e,t);for(;o;){if(o===e.firstChild){if(r)return;r=!0}const t=o.disabled||"true"===o.getAttribute("aria-disabled");if(o.hasAttribute("tabindex")&&!t)return void o.focus();o=n(e,o)}},zE=pg("div",{name:"MuiTabs",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[{[`& .${LE.scrollButtons}`]:t.scrollButtons},{[`& .${LE.scrollButtons}`]:n.scrollButtonsHideMobile&&t.scrollButtonsHideMobile},t.root,n.vertical&&t.vertical]}})(vg(({theme:e})=>({overflow:"hidden",minHeight:48,WebkitOverflowScrolling:"touch",display:"flex",variants:[{props:({ownerState:e})=>e.vertical,style:{flexDirection:"column"}},{props:({ownerState:e})=>e.scrollButtonsHideMobile,style:{[`& .${LE.scrollButtons}`]:{[e.breakpoints.down("sm")]:{display:"none"}}}}]}))),jE=pg("div",{name:"MuiTabs",slot:"Scroller",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.scroller,n.fixed&&t.fixed,n.hideScrollbar&&t.hideScrollbar,n.scrollableX&&t.scrollableX,n.scrollableY&&t.scrollableY]}})({position:"relative",display:"inline-block",flex:"1 1 auto",whiteSpace:"nowrap",variants:[{props:({ownerState:e})=>e.fixed,style:{overflowX:"hidden",width:"100%"}},{props:({ownerState:e})=>e.hideScrollbar,style:{scrollbarWidth:"none","&::-webkit-scrollbar":{display:"none"}}},{props:({ownerState:e})=>e.scrollableX,style:{overflowX:"auto",overflowY:"hidden"}},{props:({ownerState:e})=>e.scrollableY,style:{overflowY:"auto",overflowX:"hidden"}}]}),BE=pg("div",{name:"MuiTabs",slot:"List",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.list,t.flexContainer,n.vertical&&t.flexContainerVertical,n.centered&&t.centered]}})({display:"flex",variants:[{props:({ownerState:e})=>e.vertical,style:{flexDirection:"column"}},{props:({ownerState:e})=>e.centered,style:{justifyContent:"center"}}]}),_E=pg("span",{name:"MuiTabs",slot:"Indicator"})(vg(({theme:e})=>({position:"absolute",height:2,bottom:0,width:"100%",transition:e.transitions.create(),variants:[{props:{indicatorColor:"primary"},style:{backgroundColor:(e.vars||e).palette.primary.main}},{props:{indicatorColor:"secondary"},style:{backgroundColor:(e.vars||e).palette.secondary.main}},{props:({ownerState:e})=>e.vertical,style:{height:"100%",width:2,right:0}}]}))),HE=pg(function(e){const{onChange:t,...n}=e,r=s.useRef(),o=s.useRef(null),i=()=>{r.current=o.current.offsetHeight-o.current.clientHeight};return Wh(()=>{const e=Cg(()=>{const e=r.current;i(),e!==r.current&&t(r.current)}),n=Eg(o.current);return n.addEventListener("resize",e),()=>{e.clear(),n.removeEventListener("resize",e)}},[t]),s.useEffect(()=>{i(),t(r.current)},[t]),Xp.jsx("div",{style:ME,...n,ref:o})})({overflowX:"auto",overflowY:"hidden",scrollbarWidth:"none","&::-webkit-scrollbar":{display:"none"}}),VE={},WE=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiTabs"}),r=sg(),o=um(),{"aria-label":i,"aria-labelledby":a,action:l,centered:c=!1,children:u,className:d,component:p="div",allowScrollButtonsMobile:f=!1,indicatorColor:h="primary",onChange:m,orientation:g="horizontal",ScrollButtonComponent:v,scrollButtons:b="auto",selectionFollowsFocus:y,slots:w={},slotProps:x={},TabIndicatorProps:S={},TabScrollButtonProps:C={},textColor:k="primary",value:E,variant:R="standard",visibleScrollbar:P=!1,...M}=n,T="scrollable"===R,I="vertical"===g,O=I?"scrollTop":"scrollLeft",D=I?"top":"left",F=I?"bottom":"right",L=I?"clientHeight":"clientWidth",A=I?"height":"width",N={...n,component:p,allowScrollButtonsMobile:f,indicatorColor:h,orientation:g,vertical:I,scrollButtons:b,textColor:k,variant:R,visibleScrollbar:P,fixed:!T,hideScrollbar:T&&!P,scrollableX:T&&!I,scrollableY:T&&I,centered:c&&!T,scrollButtonsHideMobile:!f},$=(e=>{const{vertical:t,fixed:n,hideScrollbar:r,scrollableX:o,scrollableY:i,centered:a,scrollButtonsHideMobile:l,classes:s}=e;return wm({root:["root",t&&"vertical"],scroller:["scroller",n&&"fixed",r&&"hideScrollbar",o&&"scrollableX",i&&"scrollableY"],list:["list","flexContainer",t&&"flexContainerVertical",t&&"vertical",a&&"centered"],indicator:["indicator"],scrollButtons:["scrollButtons",l&&"scrollButtonsHideMobile"],scrollableX:[o&&"scrollableX"],hideScrollbar:[r&&"hideScrollbar"]},FE,s)})(N),z=yy({elementType:w.StartScrollButtonIcon,externalSlotProps:x.startScrollButtonIcon,ownerState:N}),j=yy({elementType:w.EndScrollButtonIcon,externalSlotProps:x.endScrollButtonIcon,ownerState:N}),[B,_]=s.useState(!1),[H,V]=s.useState(VE),[W,U]=s.useState(!1),[G,K]=s.useState(!1),[q,Y]=s.useState(!1),[X,Q]=s.useState({overflow:"hidden",scrollbarWidth:0}),Z=new Map,J=s.useRef(null),ee=s.useRef(null),te={slots:w,slotProps:{indicator:S,scrollButton:C,...x}},ne=()=>{const e=J.current;let t,n;if(e){const n=e.getBoundingClientRect();t={clientWidth:e.clientWidth,scrollLeft:e.scrollLeft,scrollTop:e.scrollTop,scrollWidth:e.scrollWidth,top:n.top,bottom:n.bottom,left:n.left,right:n.right}}if(e&&!1!==E){const e=ee.current.children;if(e.length>0){const t=e[Z.get(E)];n=t?t.getBoundingClientRect():null}}return{tabsMeta:t,tabMeta:n}},re=Mg(()=>{const{tabsMeta:e,tabMeta:t}=ne();let n,r=0;I?(n="top",t&&e&&(r=t.top-e.top+e.scrollTop)):(n=o?"right":"left",t&&e&&(r=(o?-1:1)*(t[n]-e[n]+e.scrollLeft)));const i={[n]:r,[A]:t?t[A]:0};if("number"!=typeof H[n]||"number"!=typeof H[A])V(i);else{const e=Math.abs(H[n]-i[n]),t=Math.abs(H[A]-i[A]);(e>=1||t>=1)&&V(i)}}),oe=(e,{animation:t=!0}={})=>{t?function(e,t,n,r={},o=()=>{}){const{ease:i=PE,duration:a=300}=r;let l=null;const s=t[e];let c=!1;const u=()=>{c=!0},d=r=>{if(c)return void o(new Error("Animation cancelled"));null===l&&(l=r);const u=Math.min(1,(r-l)/a);t[e]=i(u)*(n-s)+s,u>=1?requestAnimationFrame(()=>{o(null)}):requestAnimationFrame(d)};s===n?o(new Error("Element already at target position")):requestAnimationFrame(d)}(O,J.current,e,{duration:r.transitions.duration.standard}):J.current[O]=e},ie=e=>{let t=J.current[O];t+=I?e:e*(o?-1:1),oe(t)},ae=()=>{const e=J.current[L];let t=0;const n=Array.from(ee.current.children);for(let r=0;r<n.length;r+=1){const o=n[r];if(t+o[L]>e){0===r&&(t=e);break}t+=o[L]}return t},le=()=>{ie(-1*ae())},se=()=>{ie(ae())},[ce,{onChange:ue,...de}]=Ug("scrollbar",{className:mg($.scrollableX,$.hideScrollbar),elementType:HE,shouldForwardComponentProp:!0,externalForwardedProps:te,ownerState:N}),pe=s.useCallback(e=>{ue?.(e),Q({overflow:null,scrollbarWidth:e})},[ue]),[fe,he]=Ug("scrollButtons",{className:mg($.scrollButtons,C.className),elementType:DE,externalForwardedProps:te,ownerState:N,additionalProps:{orientation:g,slots:{StartScrollButtonIcon:w.startScrollButtonIcon||w.StartScrollButtonIcon,EndScrollButtonIcon:w.endScrollButtonIcon||w.EndScrollButtonIcon},slotProps:{startScrollButtonIcon:z,endScrollButtonIcon:j}}}),me=Mg(e=>{const{tabsMeta:t,tabMeta:n}=ne();if(n&&t)if(n[D]<t[D]){const r=t[O]+(n[D]-t[D]);oe(r,{animation:e})}else if(n[F]>t[F]){const r=t[O]+(n[F]-t[F]);oe(r,{animation:e})}}),ge=Mg(()=>{T&&!1!==b&&Y(!q)});s.useEffect(()=>{const e=Cg(()=>{J.current&&re()});let t;const n=n=>{n.forEach(e=>{e.removedNodes.forEach(e=>{t?.unobserve(e)}),e.addedNodes.forEach(e=>{t?.observe(e)})}),e(),ge()},r=Eg(J.current);let o;return r.addEventListener("resize",e),"undefined"!=typeof ResizeObserver&&(t=new ResizeObserver(e),Array.from(ee.current.children).forEach(e=>{t.observe(e)})),"undefined"!=typeof MutationObserver&&(o=new MutationObserver(n),o.observe(ee.current,{childList:!0})),()=>{e.clear(),r.removeEventListener("resize",e),o?.disconnect(),t?.disconnect()}},[re,ge]),s.useEffect(()=>{const e=Array.from(ee.current.children),t=e.length;if("undefined"!=typeof IntersectionObserver&&t>0&&T&&!1!==b){const n=e[0],r=e[t-1],o={root:J.current,threshold:.99},i=new IntersectionObserver(e=>{U(!e[0].isIntersecting)},o);i.observe(n);const a=new IntersectionObserver(e=>{K(!e[0].isIntersecting)},o);return a.observe(r),()=>{i.disconnect(),a.disconnect()}}},[T,b,q,u?.length]),s.useEffect(()=>{_(!0)},[]),s.useEffect(()=>{re()}),s.useEffect(()=>{me(VE!==H)},[me,H]),s.useImperativeHandle(l,()=>({updateIndicator:re,updateScrollButtons:ge}),[re,ge]);const[ve,be]=Ug("indicator",{className:mg($.indicator,S.className),elementType:_E,externalForwardedProps:te,ownerState:N,additionalProps:{style:H}}),ye=Xp.jsx(ve,{...be});let we=0;const xe=s.Children.map(u,e=>{if(!s.isValidElement(e))return null;const t=void 0===e.props.value?we:e.props.value;Z.set(t,we);const n=t===E;return we+=1,s.cloneElement(e,{fullWidth:"fullWidth"===R,indicator:n&&!B&&ye,selected:n,selectionFollowsFocus:y,onChange:m,textColor:k,value:t,...1!==we||!1!==E||e.props.tabIndex?{}:{tabIndex:0}})}),Se=(()=>{const e={};e.scrollbarSizeListener=T?Xp.jsx(ce,{...de,onChange:pe}):null;const t=T&&("auto"===b&&(W||G)||!0===b);return e.scrollButtonStart=t?Xp.jsx(fe,{direction:o?"right":"left",onClick:le,disabled:!W,...he}):null,e.scrollButtonEnd=t?Xp.jsx(fe,{direction:o?"left":"right",onClick:se,disabled:!G,...he}):null,e})(),[Ce,ke]=Ug("root",{ref:t,className:mg($.root,d),elementType:zE,externalForwardedProps:{...te,...M,component:p},ownerState:N}),[Ee,Re]=Ug("scroller",{ref:J,className:$.scroller,elementType:jE,externalForwardedProps:te,ownerState:N,additionalProps:{style:{overflow:X.overflow,[I?"margin"+(o?"Left":"Right"):"marginBottom"]:P?void 0:-X.scrollbarWidth}}}),[Pe,Me]=Ug("list",{ref:ee,className:mg($.list,$.flexContainer),elementType:BE,externalForwardedProps:te,ownerState:N,getSlotProps:e=>({...e,onKeyDown:t=>{(e=>{if(e.altKey||e.shiftKey||e.ctrlKey||e.metaKey)return;const t=ee.current,n=yx(kg(t)),r=n?.getAttribute("role");if("tab"!==r)return;let i="horizontal"===g?"ArrowLeft":"ArrowUp",a="horizontal"===g?"ArrowRight":"ArrowDown";switch("horizontal"===g&&o&&(i="ArrowRight",a="ArrowLeft"),e.key){case i:e.preventDefault(),$E(t,n,NE);break;case a:e.preventDefault(),$E(t,n,AE);break;case"Home":e.preventDefault(),$E(t,null,AE);break;case"End":e.preventDefault(),$E(t,null,NE)}})(t),e.onKeyDown?.(t)}})});return Xp.jsxs(Ce,{...ke,children:[Se.scrollButtonStart,Se.scrollbarSizeListener,Xp.jsxs(Ee,{...Re,children:[Xp.jsx(Pe,{"aria-label":i,"aria-labelledby":a,"aria-orientation":"vertical"===g?"vertical":null,role:"tablist",...Me,children:xe}),B&&ye]}),Se.scrollButtonEnd]})});function UE(e){return Ph("MuiTextField",e)}Mh("MuiTextField",["root"]);const GE={standard:IS,filled:iS,outlined:tk},KE=pg(sS,{name:"MuiTextField",slot:"Root"})({}),qE=s.forwardRef(function(e,t){const n=bg({props:e,name:"MuiTextField"}),{autoComplete:r,autoFocus:o=!1,children:i,className:a,color:l="primary",defaultValue:s,disabled:c=!1,error:u=!1,FormHelperTextProps:d,fullWidth:p=!1,helperText:f,id:h,InputLabelProps:m,inputProps:g,InputProps:v,inputRef:b,label:y,maxRows:w,minRows:x,multiline:S=!1,name:C,onBlur:k,onChange:E,onFocus:R,placeholder:P,required:M=!1,rows:T,select:I=!1,SelectProps:O,slots:D={},slotProps:F={},type:L,value:A,variant:N="outlined",...$}=n,z={...n,autoFocus:o,color:l,disabled:c,error:u,fullWidth:p,multiline:S,required:M,select:I,variant:N},j=(e=>{const{classes:t}=e;return wm({root:["root"]},UE,t)})(z),B=mm(h),_=f&&B?`${B}-helper-text`:void 0,H=y&&B?`${B}-label`:void 0,V=GE[N],W={slots:D,slotProps:{input:v,inputLabel:m,htmlInput:g,formHelperText:d,select:O,...F}},U={},G=W.slotProps.inputLabel;"outlined"===N&&(G&&void 0!==G.shrink&&(U.notched=G.shrink),U.label=y),I&&(O&&O.native||(U.id=void 0),U["aria-describedby"]=void 0);const[K,q]=Ug("root",{elementType:KE,shouldForwardComponentProp:!0,externalForwardedProps:{...W,...$},ownerState:z,className:mg(j.root,a),ref:t,additionalProps:{disabled:c,error:u,fullWidth:p,required:M,color:l,variant:N}}),[Y,X]=Ug("input",{elementType:V,externalForwardedProps:W,additionalProps:U,ownerState:z}),[Q,Z]=Ug("inputLabel",{elementType:zS,externalForwardedProps:W,ownerState:z}),[J,ee]=Ug("htmlInput",{elementType:"input",externalForwardedProps:W,ownerState:z}),[te,ne]=Ug("formHelperText",{elementType:bS,externalForwardedProps:W,ownerState:z}),[re,oe]=Ug("select",{elementType:vk,externalForwardedProps:W,ownerState:z}),ie=Xp.jsx(Y,{"aria-describedby":_,autoComplete:r,autoFocus:o,defaultValue:s,fullWidth:p,multiline:S,name:C,rows:T,maxRows:w,minRows:x,type:L,value:A,id:B,inputRef:b,onBlur:k,onChange:E,onFocus:R,placeholder:P,inputProps:ee,slots:{input:D.htmlInput?J:void 0},...X});return Xp.jsxs(K,{...q,children:[null!=y&&""!==y&&Xp.jsx(Q,{htmlFor:B,id:H,...Z,children:y}),I?Xp.jsx(re,{"aria-describedby":_,id:B,labelId:H,value:A,input:ie,...oe,children:i}):ie,f&&Xp.jsx(te,{id:_,...ne,children:f})]})});function YE(e){return Ph("MuiToggleButton",e)}const XE=Mh("MuiToggleButton",["root","disabled","selected","standard","primary","secondary","sizeSmall","sizeMedium","sizeLarge","fullWidth"]),QE=s.createContext({}),ZE=s.createContext(void 0);function JE(e,t){return void 0!==t&&void 0!==e&&(Array.isArray(t)?t.includes(e):e===t)}const eR=pg(sv,{name:"MuiToggleButton",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[`size${xf(n.size)}`]]}})(vg(({theme:e})=>({...e.typography.button,borderRadius:(e.vars||e).shape.borderRadius,padding:11,border:`1px solid ${(e.vars||e).palette.divider}`,color:(e.vars||e).palette.action.active,[`&.${XE.disabled}`]:{color:(e.vars||e).palette.action.disabled,border:`1px solid ${(e.vars||e).palette.action.disabledBackground}`},"&:hover":{textDecoration:"none",backgroundColor:e.alpha((e.vars||e).palette.text.primary,(e.vars||e).palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}},variants:[{props:{color:"standard"},style:{[`&.${XE.selected}`]:{color:(e.vars||e).palette.text.primary,backgroundColor:e.alpha((e.vars||e).palette.text.primary,(e.vars||e).palette.action.selectedOpacity),"&:hover":{backgroundColor:e.alpha((e.vars||e).palette.text.primary,`${(e.vars||e).palette.action.selectedOpacity} + ${(e.vars||e).palette.action.hoverOpacity}`),"@media (hover: none)":{backgroundColor:e.alpha((e.vars||e).palette.text.primary,(e.vars||e).palette.action.selectedOpacity)}}}}},...Object.entries(e.palette).filter(uv()).map(([t])=>({props:{color:t},style:{[`&.${XE.selected}`]:{color:(e.vars||e).palette[t].main,backgroundColor:e.alpha((e.vars||e).palette[t].main,(e.vars||e).palette.action.selectedOpacity),"&:hover":{backgroundColor:e.alpha((e.vars||e).palette[t].main,`${(e.vars||e).palette.action.selectedOpacity} + ${(e.vars||e).palette.action.hoverOpacity}`),"@media (hover: none)":{backgroundColor:e.alpha((e.vars||e).palette[t].main,(e.vars||e).palette.action.selectedOpacity)}}}}})),{props:{fullWidth:!0},style:{width:"100%"}},{props:{size:"small"},style:{padding:7,fontSize:e.typography.pxToRem(13)}},{props:{size:"large"},style:{padding:15,fontSize:e.typography.pxToRem(15)}}]}))),tR=s.forwardRef(function(e,t){const{value:n,...r}=s.useContext(QE),o=s.useContext(ZE),i=bg({props:Hh({...r,selected:JE(e.value,n)},e),name:"MuiToggleButton"}),{children:a,className:l,color:c="standard",disabled:u=!1,disableFocusRipple:d=!1,fullWidth:p=!1,onChange:f,onClick:h,selected:m,size:g="medium",value:v,...b}=i,y={...i,color:c,disabled:u,disableFocusRipple:d,fullWidth:p,size:g},w=(e=>{const{classes:t,fullWidth:n,selected:r,disabled:o,size:i,color:a}=e;return wm({root:["root",r&&"selected",o&&"disabled",n&&"fullWidth",`size${xf(i)}`,a]},YE,t)})(y),x=o||"";return Xp.jsx(eR,{className:mg(r.className,w.root,l,x),disabled:u,focusRipple:!d,ref:t,onClick:e=>{h&&(h(e,v),e.defaultPrevented)||f&&f(e,v)},onChange:f,value:v,ownerState:y,"aria-pressed":m,...b,children:a})}),nR=qh({themeId:od}),rR=Number("7");var oR=Sg(Xp.jsx("path",{d:"M19 5v14H5V5zm0-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2"})),iR=Sg(Xp.jsx("path",{d:"M19 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.11 0 2-.9 2-2V5c0-1.1-.89-2-2-2m-9 14-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8z"}));const aR=s.createElement(oR,{fontSize:"small"}),lR=s.createElement(iR,{fontSize:"small"});function sR({items:e,selectedKeys:t,defaultSelectedKeys:n,onChange:r,inputValue:o,defaultInputValue:i,onInputChange:a,debounceMs:l=300,label:c,placeholder:u,loading:d,disabled:p,size:f="small",error:h,helperText:m,limitTags:g=3,disableClearable:v,id:b,textFieldProps:y}){const w=s.useMemo(()=>Array.isArray(e)?e:[],[e]),x=Array.isArray(t),[S,C]=s.useState(Array.isArray(n)?n:[]),k=x?t:S,E=s.useMemo(()=>{const e=new Map;for(const t of w)e.set(t&&t.key,t);return e},[w]),R=s.useMemo(()=>(Array.isArray(k)?k:[]).map(e=>E.get(e)).filter(Boolean),[k,E]),P="string"==typeof o,[M,T]=s.useState("string"==typeof i?i:""),I=P?o:M,O=function(e,t=300){const n=s.useRef(e),r=s.useRef(null);return n.current=e,s.useEffect(()=>()=>{r.current&&window.clearTimeout(r.current)},[]),s.useCallback((...e)=>{n.current&&(r.current&&window.clearTimeout(r.current),r.current=window.setTimeout(()=>{n.current&&n.current(...e)},t))},[t])}(e=>{a&&a(e)},l),D=R;return s.createElement(sS,{fullWidth:!0,error:h,disabled:p},s.createElement(Ew,{openOnFocus:!0,forcePopupIcon:!0,id:b,multiple:!0,disableCloseOnSelect:!0,options:w,value:D,inputValue:I,getOptionLabel:e=>e&&"object"==typeof e?e.value??"":"",isOptionEqualToValue:(e,t)=>e&&t&&e.key===t.key,loading:d,limitTags:g,disableClearable:v,onChange:(e,t)=>{const n=Array.isArray(t)?t.map(e=>e&&e.key):[];x||C(n),r&&r(n,Array.isArray(t)?t:[])},onInputChange:(e,t,n)=>{P||T(t??""),"input"===n?O(t??""):"clear"===n&&O("")},renderOption:(e,t,{selected:n})=>s.createElement("li",Xr({},e,{key:t&&t.key||Math.random().toString(36)}),s.createElement(ux,{icon:aR,checkedIcon:lR,style:{marginRight:8},checked:!!n}),t&&t.value),renderTags:(e,t)=>(Array.isArray(e)?e:[]).map((e,n)=>s.createElement(zy,Xr({},t({index:n}),{key:e&&e.key||n,label:e&&e.value||""}))),renderInput:e=>s.createElement(qE,Xr({},e,{label:c,placeholder:u,InputProps:{...e.InputProps,endAdornment:s.createElement(s.Fragment,null,d?s.createElement(Cv,{size:18}):null,e.InputProps.endAdornment)},size:f},y))}),m?s.createElement(bS,null,m):null)}const cR=({filter:e,channel:t,query:n})=>{const[r,o]=s.useState([]),[i,a]=s.useState([]),[l,u]=s.useState(!1),[d,p]=s.useState("");return s.useEffect(()=>{a(n?.filter?.[e?.filter]||[])},[n]),s.useEffect(()=>{(async()=>{u(!0);const t=await async function(e,t){return t?.source?(await jc.runReport({id:t.source})).map(e=>({key:e[t.field],value:e[t.field]})):[]}(0,e);o(t),u(!1)})()},[d]),c.createElement("div",{style:{display:"flex"}},c.createElement("div",{style:{maxWidth:640,minWidth:200}},c.createElement(sR,{id:e?.title,label:e?.title,placeholder:"Type to search…",items:r,selectedKeys:i,onChange:(n,r)=>{a(n),t.emit("filterChanged",e,{[e.filter]:n})},onInputChange:e=>{p(e)},loading:l,debounceMs:300,helperText:i.length?`${i.length} selected`:""})))};function uR({items:e,value:t,label:n,onChange:r,sx:o={width:"100%"},disabled:i=!1}){const a=e.some(e=>e.key===t)?t:"";return c.createElement(jw,{sx:o},c.createElement(sS,{fullWidth:!0},c.createElement(zS,{id:"demo-simple-select-label"},n),c.createElement(vk,{labelId:"demo-simple-select-label",id:"demo-simple-select",value:a,label:n,onChange:r,disabled:i,MenuProps:{style:{maxHeight:"300px"}},size:"small"},e.map(e=>{const{key:t,value:n,disabled:r}=e;return c.createElement(_C,{key:t,value:t,disabled:r},n)}))))}const dR=({filter:e,channel:t,query:n})=>{const[r,o]=s.useState([]),[i,a]=s.useState("");return s.useEffect(()=>{a(n?.date_range?.name)},[n]),s.useEffect(()=>{(async()=>{const t=(await jc.getDateRanges()).filter(t=>!(e.allowedOptions.length>0)||e.allowedOptions.some(e=>e===t.name)).map(e=>({key:e.name,value:e.title}));o(t)})()},[]),c.createElement("div",{style:{minWidth:"200px",maxWidth:"640px"}},c.createElement(uR,{items:r,value:i,label:e?.title,onChange:(n,r)=>{const o=n.target.value;a(o),t.emit("filterChanged",e,{date_range:{name:o}})}}))},pR=({filters:e=[],channel:t,query:n})=>c.createElement("div",{style:{display:"flex",flexWrap:"wrap",gap:"8px"}},e.map(e=>"multi-select"===e.type?c.createElement(cR,{key:e.title,channel:t,filter:e,query:n}):"date-range"===e.type?c.createElement(dR,{key:e.title,channel:t,filter:e,query:n}):null));var fR,hR={exports:{}};var mR=(fR||(fR=1,function(e){var t=Object.prototype.hasOwnProperty,n="~";function r(){}function o(e,t,n){this.fn=e,this.context=t,this.once=n||!1}function i(e,t,r,i,a){if("function"!=typeof r)throw new TypeError("The listener must be a function");var l=new o(r,i||e,a),s=n?n+t:t;return e._events[s]?e._events[s].fn?e._events[s]=[e._events[s],l]:e._events[s].push(l):(e._events[s]=l,e._eventsCount++),e}function a(e,t){0===--e._eventsCount?e._events=new r:delete e._events[t]}function l(){this._events=new r,this._eventsCount=0}Object.create&&(r.prototype=Object.create(null),(new r).__proto__||(n=!1)),l.prototype.eventNames=function(){var e,r,o=[];if(0===this._eventsCount)return o;for(r in e=this._events)t.call(e,r)&&o.push(n?r.slice(1):r);return Object.getOwnPropertySymbols?o.concat(Object.getOwnPropertySymbols(e)):o},l.prototype.listeners=function(e){var t=n?n+e:e,r=this._events[t];if(!r)return[];if(r.fn)return[r.fn];for(var o=0,i=r.length,a=new Array(i);o<i;o++)a[o]=r[o].fn;return a},l.prototype.listenerCount=function(e){var t=n?n+e:e,r=this._events[t];return r?r.fn?1:r.length:0},l.prototype.emit=function(e,t,r,o,i,a){var l=n?n+e:e;if(!this._events[l])return!1;var s,c,u=this._events[l],d=arguments.length;if(u.fn){switch(u.once&&this.removeListener(e,u.fn,void 0,!0),d){case 1:return u.fn.call(u.context),!0;case 2:return u.fn.call(u.context,t),!0;case 3:return u.fn.call(u.context,t,r),!0;case 4:return u.fn.call(u.context,t,r,o),!0;case 5:return u.fn.call(u.context,t,r,o,i),!0;case 6:return u.fn.call(u.context,t,r,o,i,a),!0}for(c=1,s=new Array(d-1);c<d;c++)s[c-1]=arguments[c];u.fn.apply(u.context,s)}else{var p,f=u.length;for(c=0;c<f;c++)switch(u[c].once&&this.removeListener(e,u[c].fn,void 0,!0),d){case 1:u[c].fn.call(u[c].context);break;case 2:u[c].fn.call(u[c].context,t);break;case 3:u[c].fn.call(u[c].context,t,r);break;case 4:u[c].fn.call(u[c].context,t,r,o);break;default:if(!s)for(p=1,s=new Array(d-1);p<d;p++)s[p-1]=arguments[p];u[c].fn.apply(u[c].context,s)}}return!0},l.prototype.on=function(e,t,n){return i(this,e,t,n,!1)},l.prototype.once=function(e,t,n){return i(this,e,t,n,!0)},l.prototype.removeListener=function(e,t,r,o){var i=n?n+e:e;if(!this._events[i])return this;if(!t)return a(this,i),this;var l=this._events[i];if(l.fn)l.fn!==t||o&&!l.once||r&&l.context!==r||a(this,i);else{for(var s=0,c=[],u=l.length;s<u;s++)(l[s].fn!==t||o&&!l[s].once||r&&l[s].context!==r)&&c.push(l[s]);c.length?this._events[i]=1===c.length?c[0]:c:a(this,i)}return this},l.prototype.removeAllListeners=function(e){var t;return e?(t=n?n+e:e,this._events[t]&&a(this,t)):(this._events=new r,this._eventsCount=0),this},l.prototype.off=l.prototype.removeListener,l.prototype.addListener=l.prototype.on,l.prefixed=n,l.EventEmitter=l,e.exports=l}(hR)),hR.exports),gR=t(mR),vR=e=>c.useRef(e||new gR).current,bR=e=>{const t=c.useState({}),n=c.useCallback((n,r)=>{let o={...t.current,...r};for(var i in t.current=o,o)"date_range"===i||o[i].length||delete o[i];e?.emit("mergedFilterChanged",{value:o})},[e]);c.useEffect(()=>(e?.on("filterChanged",n),()=>{e?.off("filterChanged",n)}),[e])},yR=({id:e,cache:t,dashboard:n,channel:r,...o})=>{const[i,a]=c.useState(),[l,u]=c.useState(),[d,p]=c.useState(),[f,h]=c.useState(),[m,g]=c.useState(vu()),[v,b]=c.useState(),[y,w]=c.useState(0),[x,S]=c.useState(!1),[C,k]=c.useState(),[E,R]=c.useState(!1),P=c.useRef({value:o?.filter}),[M,T]=c.useState({}),{ref:I,inView:O}=function({threshold:e,delay:t,trackVisibility:n,rootMargin:r,root:o,triggerOnce:i,skip:a,initialInView:l,fallbackInView:c,onChange:u}={}){var d;const[p,f]=s.useState(null),h=s.useRef(u),m=s.useRef(l),[g,v]=s.useState({inView:!!l,entry:void 0});h.current=u,s.useEffect(()=>{if(void 0===m.current&&(m.current=l),a||!p)return;let s;return s=Su(p,(e,t)=>{const n=m.current;m.current=e,(void 0!==n||e)&&(v({inView:e,entry:t}),h.current&&h.current(e,t),t.isIntersecting&&i&&s&&(s(),s=void 0))},{root:o,rootMargin:r,threshold:e,trackVisibility:n,delay:t},c),()=>{s&&s()}},[Array.isArray(e)?e.toString():e,p,o,r,i,a,n,c,t]);const b=null==(d=g.entry)?void 0:d.target,y=s.useRef(void 0);p||!b||i||a||y.current===b||(y.current=b,v({inView:!!l,entry:void 0}),m.current=l);const w=[f,g.inView,g.entry];return w.ref=w[0],w.inView=w[1],w.entry=w[2],w}({threshold:.1,delay:1e3}),D=vR(r);bR(D);const F=c.useCallback(e=>{const t=e.target.value;w(t),b(i.doc.view[t])},[i]);c.useEffect(()=>{e&&(async()=>{const n=e,r=t?.[n]||await jc.getChart({id:n}),i=r.doc.source?.id,l=i?t?.[i]||await jc.getReport({id:i}):void 0,s=t?.[`schema_${i}`]||o?.schema||await jc.getReportSchema({id:i}),c=r.doc?.view?.[0];w(0),u(l),a(r),b(c),p(s),R(!0)})().catch(e=>{console.error(e.message)})},[e]),c.useEffect(()=>{i&&f&&(!i?.doc?.source?.id||l)&&d&&(async()=>{g(vu(i.doc.chart?.component,{view:v,source:f,chart:i,report:l,schema:d,dashboard:n,query:M}))})().catch(e=>{console.error(e.message)})},[i,f,v,l,d]);const L=e=>{const t={...l?.doc.query.filter||{},...o?.filter,...e?.value},n=t.date_range||l?.doc.query.date_range;if(delete t.date_range,R(!1),k(),S(!0),"context"===i?.doc?.source?.type)return h({filter:t}),void S(!1);const r={filter:t,date_range:n,parameters:o?.params};T(r),jc.runReport({id:l.id,query:r}).then(e=>{h(i.doc.source.reverse?e.reverse():e)}).catch(e=>{h([])}).finally(()=>{S(!1)})},A=e=>{P.current=e,O?L(e):(k(e),R(!0))};return c.useEffect(()=>(D?.on("mergedFilterChanged",A),()=>{D?.off("mergedFilterChanged",A)}),[D,l,i,O]),c.useEffect(()=>{O&&E&&L(C)},[O,E]),c.useEffect(()=>{R(!0)},[o.params]),c.createElement(Yr,{ref:I,elevation:0,style:{borderRadius:12,padding:20,border:"1px solid #e5e5e5",background:"#fff",display:"flex",flexDirection:"column",gap:"12px",height:"100%"}},i&&c.createElement("div",{style:{display:"flex",alignItems:"center",lineHeight:0}},c.createElement(si,{variant:"subtitle2",style:{fontWeight:600,color:"#252525"}},o?.title||i.doc.name," ")),x?c.createElement(Wa,{style:{display:"flex",justifyContent:"center",alignItems:"center",height:"100%",width:"100%"}}):c.createElement(c.Fragment,null,c.createElement("div",{style:{display:"flex"}},c.createElement("div",{style:{flexGrow:1}}),c.createElement("div",null,i?.doc?.view?.length>1&&c.createElement(Vi,null,c.createElement(Ha,{labelId:"date-range-select-label",id:"date-range-select",value:y,onChange:F,style:{fontSize:"12px"},disableUnderline:!0},i.doc.view.map((e,t)=>c.createElement(Ea,{key:t,value:t},e.title)))))),c.createElement("div",{style:{position:"relative",flexGrow:n?void 0:1,display:"flex",flexDirection:"column"}},c.createElement(pR,{filters:i?.doc?.filters,channel:D,query:M}),m)))};const wR=s.createContext(void 0),xR=({defaultParameters:e={},defaultApi:t={},children:n})=>{const r={base_currency:"EUR",...e},[o,i]=s.useState(r),[a,l]=s.useState(t),u={parameters:o,setParameters:e=>{const t={base_currency:"EUR",...e};i(t)},api:a,setApi:l,setReportingContext:({parameters:e,api:t})=>{if(void 0!==e){const t={base_currency:"EUR",...e};i(t)}void 0!==t&&l(t)}};return c.createElement(wR.Provider,{value:u},n)},SR=()=>s.useContext(wR);const CR=s.createContext(),kR=({children:e})=>{const[t,n]=s.useState({open:!1,message:"",severity:"info",duration:6e3}),r=(e,t="info",r=6e3)=>{n({open:!0,message:e,severity:t,duration:r})},o=(e,t)=>{"clickaway"!==t&&n(e=>({...e,open:!1}))},i={success:(e,t)=>r(e,"success",t),error:(e,t)=>r(e,"error",t),warning:(e,t)=>r(e,"warning",t),info:(e,t)=>r(e,"info",t)};return c.createElement(CR.Provider,{value:i},e,c.createElement(Dk,{open:t.open,autoHideDuration:t.duration,onClose:o,anchorOrigin:{vertical:"top",horizontal:"right"}},c.createElement(jv,{onClose:o,severity:t.severity,variant:"filled",sx:{width:"100%"}},t.message)))},ER=()=>{const e=s.useContext(CR);if(!e)throw new Error("useNotify must be used within a NotifyProvider");return e};function RR(e){var t,n,r="";if("string"==typeof e||"number"==typeof e)r+=e;else if("object"==typeof e)if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(n=RR(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function PR(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=RR(e))&&(r&&(r+=" "),r+=t);return r}var MR=parseInt(s.version,10);const TR=e=>{if(MR>=19){const t=t=>e(t,t.ref??null);return t.displayName=e.displayName??e.name,t}return s.forwardRef(e)},IR=Sg,OR=IR(Xp.jsx("path",{d:"M4 12l1.41 1.41L11 7.83V20h2V7.83l5.58 5.59L20 12l-8-8-8 8z"})),DR=IR(Xp.jsx("path",{d:"M20 12l-1.41-1.41L13 16.17V4h-2v12.17l-5.58-5.59L4 12l8 8 8-8z"})),FR=IR(Xp.jsx("path",{d:"M8.59 16.59 13.17 12 8.59 7.41 10 6l6 6-6 6-1.41-1.41z"})),LR=IR(Xp.jsx("path",{d:"M16.59 8.59 12 13.17 7.41 8.59 6 10l6 6 6-6z"})),AR=IR(Xp.jsx("path",{d:"M10 18h4v-2h-4v2zM3 6v2h18V6H3zm3 7h12v-2H6v2z"})),NR=IR(Xp.jsx("path",{d:"M4.25 5.61C6.27 8.2 10 13 10 13v6c0 .55.45 1 1 1h2c.55 0 1-.45 1-1v-6s3.72-4.8 5.74-7.39c.51-.66.04-1.61-.79-1.61H5.04c-.83 0-1.3.95-.79 1.61z"})),$R=IR(Xp.jsx("path",{d:"M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z"}));IR(Xp.jsx("path",{d:"M3 18h18v-2H3v2zm0-5h18v-2H3v2zm0-7v2h18V6H3z"})),IR(Xp.jsx("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-2 15l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z"}));const zR=IR(Xp.jsx("path",{d:"M14.67 5v14H9.33V5zm1 14H21V5h-5.33zm-7.34 0V5H3v14z"})),jR=IR(Xp.jsx("rect",{width:"1",height:"24",x:"11.5",rx:"0.5"})),BR=IR(Xp.jsx("path",{d:"M4 15h16v-2H4v2zm0 4h16v-2H4v2zm0-8h16V9H4v2zm0-6v2h16V5H4z"})),_R=IR(Xp.jsx("path",{d:"M21,8H3V4h18V8z M21,10H3v4h18V10z M21,16H3v4h18V16z"})),HR=IR(Xp.jsx("path",{d:"M4 18h17v-6H4v6zM4 5v6h17V5H4z"})),VR=IR(Xp.jsx("path",{d:"M12 8c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm0 2c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0 6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"})),WR=IR(Xp.jsx("path",{d:"M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"})),UR=IR(Xp.jsx("path",{d:"M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6v2z"})),GR=IR(Xp.jsx("path",{d:"M19 13H5v-2h14v2z"})),KR=IR(Xp.jsx("path",{d:"M12 4V1L8 5l4 4V6c3.31 0 6 2.69 6 6 0 1.01-.25 1.97-.7 2.8l1.46 1.46C19.54 15.03 20 13.57 20 12c0-4.42-3.58-8-8-8zm0 14c-3.31 0-6-2.69-6-6 0-1.01.25-1.97.7-2.8L5.24 7.74C4.46 8.97 4 10.43 4 12c0 4.42 3.58 8 8 8v3l4-4-4-4v3z"})),qR=IR(Xp.jsx("path",{d:"M11 18c0 1.1-.9 2-2 2s-2-.9-2-2 .9-2 2-2 2 .9 2 2zm-2-8c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0-6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm6 4c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm0 2c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0 6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"})),YR=IR(Xp.jsx("path",{d:"M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"})),XR=IR(Xp.jsx("path",{d:"M12 8c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm0 2c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0 6c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"})),QR=IR(Xp.jsx("path",{d:"M12 7c2.76 0 5 2.24 5 5 0 .65-.13 1.26-.36 1.83l2.92 2.92c1.51-1.26 2.7-2.89 3.43-4.75-1.73-4.39-6-7.5-11-7.5-1.4 0-2.74.25-3.98.7l2.16 2.16C10.74 7.13 11.35 7 12 7zM2 4.27l2.28 2.28.46.46C3.08 8.3 1.78 10.02 1 12c1.73 4.39 6 7.5 11 7.5 1.55 0 3.03-.3 4.38-.84l.42.42L19.73 22 21 20.73 3.27 3 2 4.27zM7.53 9.8l1.55 1.55c-.05.21-.08.43-.08.65 0 1.66 1.34 3 3 3 .22 0 .44-.03.65-.08l1.55 1.55c-.67.33-1.41.53-2.2.53-2.76 0-5-2.24-5-5 0-.79.2-1.53.53-2.2zm4.31-.78l3.15 3.15.02-.16c0-1.66-1.34-3-3-3l-.17.01z"})),ZR=IR(Xp.jsx("g",{children:Xp.jsx("path",{d:"M14.67,5v14H9.33V5H14.67z M15.67,19H21V5h-5.33V19z M8.33,19V5H3v14H8.33z"})})),JR=IR(Xp.jsx("path",{d:"M12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2m5 13.59L15.59 17 12 13.41 8.41 17 7 15.59 10.59 12 7 8.41 8.41 7 12 10.59 15.59 7 17 8.41 13.41 12z"}));IR(Xp.jsx("path",{d:"M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6v12zM19 4h-3.5l-1-1h-5l-1 1H5v2h14V4z"}));const eP=IR(Xp.jsx("path",{d:"M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6v12zm2.46-7.12l1.41-1.41L12 12.59l2.12-2.12 1.41 1.41L13.41 14l2.12 2.12-1.41 1.41L12 15.41l-2.12 2.12-1.41-1.41L10.59 14l-2.13-2.12zM15.5 4l-1-1h-5l-1 1H5v2h14V4z"})),tP=IR(Xp.jsx("path",{d:"M5 20h14v-2H5zM19 9h-4V3H9v6H5l7 7z"})),nP=s.createContext(void 0),rP=()=>{const e=s.useContext(nP);if(!e)throw new Error("MUI X: useGridRootProps should only be used inside the DataGrid, DataGridPro or DataGridPremium component.");return e},oP=["sortingOrder"],iP=s.memo(function(e){const{sortingOrder:t}=e,n=d(e,oP),r=rP(),[o]=t,i="asc"===o?r.slots.columnSortedAscendingIcon:r.slots.columnSortedDescendingIcon;return i?Xp.jsx(i,f({},n)):null}),aP=s.createContext(void 0);function lP(){const e=s.useContext(aP);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 sP=new TextEncoder;let cP=2048,uP=new ArrayBuffer(cP),dP=new Uint8Array(uP),pP=new Int32Array(uP);const fP=function(e){const t=2*e.length;t>cP&&(cP=t+(4-t%4),uP=new ArrayBuffer(cP),dP=new Uint8Array(uP),pP=new Int32Array(uP));const n=sP.encodeInto(e,dP).written,r=0|n;let o=0,i=374761393+(0+r|0)|0;if(r<16)for(;(o+3|0)<r;o=o+4|0)i=Math.imul(0|hP(i+Math.imul(0|pP[o],3266489917)|0,17),668265263);else{let e=606290984,t=-2048144777,n=0,a=1640531535;for(;(o+15|0)<r;o=o+16|0)e=Math.imul(0|hP(e+Math.imul(0|pP[o+0|0],2246822519)|0,13),2654435761),t=Math.imul(0|hP(t+Math.imul(0|pP[o+4|0],2246822519)|0,13),2654435761),n=Math.imul(0|hP(n+Math.imul(0|pP[o+8|0],2246822519)|0,13),2654435761),a=Math.imul(0|hP(a+Math.imul(0|pP[o+12|0],2246822519)|0,13),2654435761);for(i=(((hP(e,1)|0+hP(t,7)|0)+hP(n,12)|0)+hP(a,18)|0)+r|0;(o+3|0)<r;o=o+4|0)i=Math.imul(0|hP(i+Math.imul(0|pP[o],3266489917)|0,17),668265263)}for(;o<r;o=o+1|0)i=Math.imul(0|hP(i+Math.imul(0|dP[o],374761393)|0,11),2654435761);return i=Math.imul(i^i>>>15,2246822519),i=Math.imul(i^i>>>13,3266489917),((i^i>>>16)>>>0).toString()};function hP(e,t){return e<<t|e>>>32-t}const mP={values:{xs:0,sm:600,md:900,lg:1200,xl:1536},up:e=>{const t=mP.values;return`@media (min-width:${"number"==typeof t[e]?t[e]:e}px)`}},gP={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"}},vP=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}(gP),bP=f({breakpoints:mP,spacing:function(e,t,n,r){if(void 0===e)return yP(1);if(void 0===t)return yP(e);if(void 0===n)return yP(e)+" "+yP(t);if(void 0===r)return yP(e)+" "+yP(t)+" "+yP(n);return yP(e)+" "+yP(t)+" "+yP(n)+" "+yP(r)},transition:function(e,t){const{duration:n=bP.transitions.duration.base,easing:r=bP.transitions.easing.easeInOut,delay:o=0}=t??{};return e.map(e=>`${e} ${n} ${r} ${o}ms`).join(", ")},keys:gP},vP);function yP(e){return 0===e?"0":`calc(var(--DataGrid-t-spacing-unit) * ${e})`}function wP(e){return function(e,t){return`rgba(from ${e} r g b / ${t})`}(e,1)}function xP(e){if(!e)return;const t="number"==typeof e.fontSize?`${e.fontSize}px`:e.fontSize;return`${e.fontWeight} ${t} / ${e.lineHeight} ${e.fontFamily}`}const SP=["id","label","labelId","material","disabled","slotProps","onChange","onKeyDown","onOpen","onClose","size","style","fullWidth"],CP=["onRowsPerPageChange","material","disabled"],kP=["material"],EP=["autoFocus","label","fullWidth","slotProps","className","material"],RP=["material"],PP=["material"],MP=["material"],TP=["material"],IP=["material"],OP=["material"],DP=["material"],FP=["material"],LP=["material"],AP=["material","label","className"],NP=["material"],$P=["inert","iconStart","iconEnd","children","material"],zP=["slotProps","material"],jP=["id","multiple","freeSolo","options","getOptionLabel","isOptionEqualToValue","value","onChange","label","placeholder","slotProps","material"],BP=["key"],_P=["inputProps","InputProps","InputLabelProps"],HP=["slotProps","material"],VP=["ref","open","children","className","clickAwayTouchEvent","clickAwayMouseEvent","flip","focusTrap","onExited","onClickAway","onDidShow","onDidHide","id","target","transition","placement","material"],WP=["native"],UP=["children","value","active"],GP=["items","value","material"],KP=pg(AS)(({theme:e})=>({[`&.${DS.positionEnd} .${Ev.sizeSmall}`]:{marginRight:e.spacing(-.75)}})),qP=pg(fS,{shouldForwardProp:e=>"fullWidth"!==e})(({theme:e})=>({gap:e.spacing(.5),margin:0,overflow:"hidden",[`& .${uS.label}`]:{fontSize:e.typography.pxToRem(14),overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},variants:[{props:{fullWidth:!0},style:{width:"100%"}}]})),YP=pg(ux,{shouldForwardProp:e=>"density"!==e})(({theme:e})=>({variants:[{props:{density:"compact"},style:{padding:e.spacing(.5)}}]})),XP=pg(vC)({[`& .${mC.primary}`]:{overflowX:"clip",textOverflow:"ellipsis",maxWidth:"300px"}}),QP=TR(function(e,t){const{id:n,label:r,labelId:o,material:i,disabled:a,slotProps:l,onChange:s,onKeyDown:c,onOpen:u,onClose:p,size:h,style:m,fullWidth:g}=e,v=d(e,SP),b={PaperProps:{onKeyDown:c}};return p&&(b.onClose=p),Xp.jsxs(sS,{size:h,fullWidth:g,style:m,disabled:a,ref:t,children:[Xp.jsx(zS,{id:o,htmlFor:n,shrink:!0,variant:"outlined",children:r}),Xp.jsx(vk,f({id:n,labelId:o,label:r,displayEmpty:!0,onChange:s,variant:"outlined"},v,{notched:!0,inputProps:l?.htmlInput,onOpen:u,MenuProps:b,size:h},i))]})}),ZP=pg(RE)(({theme:e})=>({[`& .${mE.selectLabel}`]:{display:"none",[e.breakpoints.up("sm")]:{display:"block"}},[`& .${mE.input}`]:{display:"none",[e.breakpoints.up("sm")]:{display:"inline-flex"}}})),JP=TR(function(e,t){const{onRowsPerPageChange:n,material:r,disabled:o}=e,i=d(e,CP),a=s.useMemo(()=>{if(o)return{backIconButtonProps:{disabled:!0},nextIconButtonProps:{disabled:!0}}},[o]),l=lP(),c=rP(),{estimatedRowCount:u}=c;return Xp.jsx(ZP,f({component:"div",onRowsPerPageChange:Mg(e=>{n?.(Number(e.target.value))}),labelRowsPerPage:l.current.getLocaleText("paginationRowsPerPage"),labelDisplayedRows:e=>l.current.getLocaleText("paginationDisplayedRows")(f({},e,{estimated:u})),getItemAriaLabel:l.current.getLocaleText("paginationItemAriaLabel")},a,i,r,{ref:t}))}),eM=TR(function(e,t){const{material:n}=e,r=d(e,kP);return Xp.jsx(Nw,f({},r,n,{ref:t}))}),tM=TR(function(e,t){const{autoFocus:n,label:r,fullWidth:o,slotProps:i,className:a,material:l}=e,c=d(e,EP),u=s.useRef(null),p=Tg(u,t),h=s.useRef(null);return s.useEffect(()=>{if(n){const e=u.current?.querySelector("input");e?.focus({preventScroll:!0})}else!1===n&&h.current&&h.current.stop({})},[n]),r?Xp.jsx(qP,{className:a,control:Xp.jsx(YP,f({},c,l,{inputProps:i?.htmlInput,ref:p,touchRippleRef:h})),label:r,fullWidth:o}):Xp.jsx(YP,f({},c,l,{className:PR(a,l?.className),inputProps:i?.htmlInput,ref:p,touchRippleRef:h}))}),nM=TR(function(e,t){const{material:n}=e,r=d(e,RP);return Xp.jsx(Cv,f({},r,n,{ref:t}))}),rM=TR(function(e,t){const{material:n}=e,r=d(e,PP);return Xp.jsx(nS,f({},r,n,{ref:t}))}),oM=TR(function(e,t){const{material:n}=e,r=d(e,MP);return Xp.jsx(QS,f({},r,n,{ref:t}))}),iM=TR(function(e,t){const{material:n}=e,r=d(e,TP);return Xp.jsx(Xw,f({},r,n,{ref:t}))}),aM=pg(tR)(({theme:e})=>({gap:e.spacing(1),border:0})),lM=TR(function(e,t){const{material:n}=e,r=d(e,IP);return Xp.jsx(aM,f({size:"small",color:"primary"},r,n,{ref:t}))}),sM=TR(function(e,t){const{material:n}=e,r=d(e,OP);return Xp.jsx(zy,f({},r,n,{ref:t}))}),cM=TR(function(e,t){const{material:n}=e,r=d(e,DP);return Xp.jsx(Mv,f({},r,n,{ref:t}))}),uM=TR(function(e,t){const{material:n}=e,r=d(e,FP);return Xp.jsx(Hk,f({},r,n,{ref:t}))}),dM=TR(function(e,t){const{material:n}=e,r=d(e,LP);return Xp.jsx(kk,f({},r,n,{ref:t}))}),pM=TR(function(e,t){const{material:n,label:r,className:o}=e,i=d(e,AP);return r?Xp.jsx(qP,{className:o,control:Xp.jsx(Yk,f({},i,n,{ref:t})),label:r}):Xp.jsx(Yk,f({},i,n,{className:o,ref:t}))}),fM=TR(function(e,t){const{material:n}=e,r=d(e,NP);return Xp.jsx(SC,f({},r,n,{ref:t}))});function hM(e,t=!0){if(!e)return;const{slotProps:n,material:r}=e,o=d(e,HP);t&&(o.startAdornment&&(o.startAdornment=Xp.jsx(KP,{position:"start",children:o.startAdornment})),o.endAdornment&&(o.endAdornment=Xp.jsx(KP,{position:"end",children:o.endAdornment})));for(const e in r)Object.hasOwn(r,e)&&(o[e]=r[e]);return n?.htmlInput&&(o.inputProps?o.inputProps=f({},o.inputProps,n?.htmlInput):o.inputProps=n?.htmlInput),o}const mM={"bottom-start":"top left","bottom-end":"top right"};function gM(e,t){return function(e,t){if(void 0===e.focusTrap)return t;return Xp.jsx(Cx,{open:!0,disableEnforceFocus:!0,disableAutoFocus:!0,children:Xp.jsx("div",{tabIndex:-1,children:t})})}(e,function(e,t){if(void 0===e.onClickAway)return t;return Xp.jsx(px,{onClickAway:e.onClickAway,touchEvent:e.clickAwayTouchEvent,mouseEvent:e.clickAwayMouseEvent,children:t})}(e,t))}const vM=pg(WE,{name:"MuiDataGrid",slot:"Tabs"})(({theme:e})=>({borderBottom:`1px solid ${e.palette.divider}`})),bM=pg(Jk,{name:"MuiDataGrid",slot:"Tab"})({flex:1,minWidth:"fit-content"}),yM=pg("div",{name:"MuiDataGrid",slot:"TabPanel"})({flex:1,display:"flex",flexDirection:"column",overflow:"hidden"});function wM(e){const{children:t,active:n}=e,r=d(e,UP);return Xp.jsx(yM,f({role:"tabpanel",style:{display:n?"flex":"none"}},r,{children:t}))}const xM={baseAutocomplete:function(e){const t=rP(),{id:n,multiple:r,freeSolo:o,options:i,getOptionLabel:a,isOptionEqualToValue:l,value:s,onChange:c,label:u,placeholder:p,slotProps:h,material:m}=e,g=d(e,jP);return Xp.jsx(Ew,f({id:n,multiple:r,freeSolo:o,options:i,getOptionLabel:a,isOptionEqualToValue:l,value:s,onChange:c,renderTags:(e,t)=>e.map((e,n)=>{const r=t({index:n}),{key:o}=r,i=d(r,BP);return Xp.jsx(zy,f({variant:"outlined",size:"small",label:"string"==typeof e?e:a?.(e)},i),o)}),renderInput:e=>{const{inputProps:n,InputProps:r,InputLabelProps:o}=e,i=d(e,_P);return Xp.jsx(qE,f({},i,{label:u,placeholder:p,inputProps:n,InputProps:hM(r,!1),InputLabelProps:f({shrink:!0},o)},h?.textField,t.slotProps?.baseTextField))}},g,m))},baseBadge:eM,baseCheckbox:tM,baseChip:sM,baseCircularProgress:nM,baseDivider:rM,baseInput:function(e){return Xp.jsx(nw,f({},hM(e)))},baseLinearProgress:oM,baseMenuList:fM,baseMenuItem:function(e){const{inert:t,iconStart:n,iconEnd:r,children:o,material:i}=e,a=d(e,$P);return t&&(a.disableRipple=!0),s.createElement(_C,f({},a,i),[n&&Xp.jsx(fC,{children:n},"1"),Xp.jsx(XP,{children:o},"2"),r&&Xp.jsx(fC,{children:r},"3")])},baseTextField:function(e){const{slotProps:t,material:n}=e,r=d(e,zP);return Xp.jsx(qE,f({variant:"outlined"},r,n,{inputProps:t?.htmlInput,InputProps:hM(t?.input),InputLabelProps:f({shrink:!0},t?.inputLabel)}))},baseButton:iM,baseIconButton:cM,baseToggleButton:lM,baseTooltip:uM,baseTabs:function(e){let{items:t,value:n,material:r}=e,o=d(e,GP);const i=mm(),a=`${i}-tab-${n}`,l=`${i}-tabpanel-${n}`;return Xp.jsxs(s.Fragment,{children:[Xp.jsx(vM,f({},o,{value:n,variant:"scrollable",scrollButtons:"auto"},r,{children:t.map(e=>Xp.jsx(bM,{value:e.value,label:e.label,id:a,"aria-controls":l},e.value))})),t.map(e=>Xp.jsx(wM,{value:e.value,active:n===e.value,id:l,"aria-labelledby":a,children:e.children},e.value))]})},basePagination:JP,basePopper:function(e){const{open:t,children:n,className:r,flip:o,onExited:i,onDidShow:a,onDidHide:l,id:c,target:u,transition:p,placement:h,material:m}=e,g=d(e,VP),v=s.useMemo(()=>{const e=[{name:"preventOverflow",options:{padding:8}}];return o&&e.push({name:"flip",enabled:!0}),(a||l)&&e.push({name:"isPlaced",enabled:!0,phase:"main",fn:()=>{a?.()},effect:()=>()=>{l?.()}}),e},[o,a,l]);let b;if(p){const t=e=>t=>{e&&e(),i&&i(t)};b=r=>gM(e,Xp.jsx(PS,f({},r.TransitionProps,{style:{transformOrigin:mM[r.placement]},onExited:t(r.TransitionProps?.onExited),children:Xp.jsx(qg,{children:n})})))}else b=gM(e,n);return Xp.jsx(My,f({id:c,className:r,open:t,anchorEl:u,transition:p,placement:h,modifiers:v},g,m,{children:b}))},baseSelect:QP,baseSelectOption:function(e){let{native:t}=e,n=d(e,WP);return t?Xp.jsx("option",f({},n)):Xp.jsx(_C,f({},n))},baseSkeleton:dM,baseSwitch:pM},SM=f({},xM,{booleanCellTrueIcon:YR,booleanCellFalseIcon:WR,columnMenuIcon:VR,openFilterButtonIcon:AR,filterPanelDeleteIcon:WR,columnFilteredIcon:NR,columnSelectorIcon:zR,columnUnsortedIcon:iP,columnSortedAscendingIcon:OR,columnSortedDescendingIcon:DR,columnResizeIcon:jR,densityCompactIcon:BR,densityStandardIcon:_R,densityComfortableIcon:HR,exportIcon:tP,moreActionsIcon:XR,treeDataCollapseIcon:LR,treeDataExpandIcon:FR,groupingCriteriaCollapseIcon:LR,groupingCriteriaExpandIcon:FR,detailPanelExpandIcon:UR,detailPanelCollapseIcon:GR,rowReorderIcon:qR,quickFilterIcon:$R,quickFilterClearIcon:JR,columnMenuHideIcon:QR,columnMenuSortAscendingIcon:OR,columnMenuSortDescendingIcon:DR,columnMenuUnsortIcon:null,columnMenuFilterIcon:NR,columnMenuManageColumnsIcon:ZR,columnMenuClearIcon:JR,loadIcon:KR,filterPanelAddIcon:UR,filterPanelRemoveAllIcon:eP,columnReorderIcon:qR,menuItemCheckIcon:YR});var CM=Symbol("NOT_FOUND");var kM=e=>Array.isArray(e)?e:[e];function EM(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}var RM=(e,t)=>e===t;function PM(e,t){const n="object"==typeof t?t:{equalityCheck:t},{equalityCheck:r=RM,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:CM,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 CM}return{get:r,put:function(t,o){r(t)===CM&&(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===CM){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 MM="undefined"!=typeof WeakRef?WeakRef:class{constructor(e){this.value=e}deref(){return this.value}};function TM(){return{s:0,v:void 0,o:null,p:null}}function IM(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=TM(),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=TM(),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=o?.deref?.()??o;null!=e&&r(e,s)&&(s=e,0!==i&&i--);o="object"==typeof s&&null!==s||"function"==typeof s?new MM(s):s}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}function OM(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=IM,argsMemoizeOptions:d=[]}=l,p=kM(c),f=kM(d),h=EM(e),m=s(function(){return r++,a.apply(null,arguments)},...p),g=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=m.apply(null,e),t},...f);return Object.assign(g,{resultFunc:a,memoizedResultFunc:m,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}var DM=OM(IM),FM=Object.assign((e,t=DM)=>{!function(e,t="expected an object, instead received "+typeof e){if("object"!=typeof e)throw new TypeError(t)}(e,"createStructuredSelector expects first argument to be an object where each property is a selector, instead received a "+typeof e);const n=Object.keys(e),r=n.map(t=>e[t]),o=t(r,(...e)=>e.reduce((e,t,r)=>(e[n[r]]=t,e),{}));return o},{withTypes:()=>FM});const LM=OM({memoize:PM,memoizeOptions:{maxSize:1,equalityCheck:Object.is}}),AM=(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 p=e(s,c,u,d),f=t(s,c,u,d),h=n(s,c,u,d),m=r(s,c,u,d),g=o(s,c,u,d),v=i(s,c,u,d),b=a(s,c,u,d);return l(p,f,h,m,g,v,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),p=t(l,s,c,u),f=n(l,s,c,u),h=r(l,s,c,u),m=o(l,s,c,u),g=i(l,s,c,u);return a(d,p,f,h,m,g,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),p=n(a,l,s,c),f=r(a,l,s,c),h=o(a,l,s,c);return i(u,d,p,f,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),p=r(i,a,l,s);return o(c,u,d,p,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},NM=(...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=LM(...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")}}};var $M,zM,jM={exports:{}},BM={};function _M(){return zM||(zM=1,jM.exports=function(){if($M)return BM;$M=1;var e=l(),t="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},n=e.useState,r=e.useEffect,o=e.useLayoutEffect,i=e.useDebugValue;function a(e){var n=e.getSnapshot;e=e.value;try{var r=n();return!t(e,r)}catch(e){return!0}}var s="undefined"==typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t){return t()}:function(e,t){var l=t(),s=n({inst:{value:l,getSnapshot:t}}),c=s[0].inst,u=s[1];return o(function(){c.value=l,c.getSnapshot=t,a(c)&&u({inst:c})},[e,l,t]),r(function(){return a(c)&&u({inst:c}),e(function(){a(c)&&u({inst:c})})},[e]),i(l),l};return BM.useSyncExternalStore=void 0!==e.useSyncExternalStore?e.useSyncExternalStore:s,BM}()),jM.exports}var HM,VM,WM=_M(),UM={exports:{}},GM={};var KM=(VM||(VM=1,UM.exports=function(){if(HM)return GM;HM=1;var e=l(),t=_M(),n="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},r=t.useSyncExternalStore,o=e.useRef,i=e.useEffect,a=e.useMemo,s=e.useDebugValue;return GM.useSyncExternalStoreWithSelector=function(e,t,l,c,u){var d=o(null);if(null===d.current){var p={hasValue:!1,value:null};d.current=p}else p=d.current;d=a(function(){function e(e){if(!i){if(i=!0,r=e,e=c(e),void 0!==u&&p.hasValue){var t=p.value;if(u(t,e))return o=t}return o=e}if(t=o,n(r,e))return t;var a=c(e);return void 0!==u&&u(t,a)?(r=e,t):(r=e,o=a)}var r,o,i=!1,a=void 0===l?null:l;return[function(){return e(t())},null===a?void 0:function(){return e(a())}]},[t,l,c,u]);var f=r(e,d[0],d[1]);return i(function(){p.hasValue=!0,p.value=f},[f]),s(f),f},GM}()),UM.exports);const qM=MR>=19?function(e,t,n,r,o){const i=s.useCallback(()=>t(e.getSnapshot(),n,r,o),[e,t,n,r,o]);return WM.useSyncExternalStore(e.subscribe,i,i)}:function(e,t,n,r,o){return KM.useSyncExternalStoreWithSelector(e.subscribe,e.getSnapshot,e.getSnapshot,e=>t(e,n,r,o))};function YM(e,t,n,r,o){return qM(e,t,n,r,o)}const XM=()=>{};function QM(e,t,n){const r=Dg(ZM,{store:e,selector:t}).current;r.effect=n,Lg(r.onMount)}function ZM(e){const{store:t,selector:n}=e;let r=n(t.state);const o={effect:XM,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}class JM{static create(e){return new JM(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(f({},this.state,e))}set(e,t){Object.is(this.state[e],t)||this.setState(f({},this.state,{[e]:t}))}use=(()=>(e,t,n,r)=>YM(this,e,t,n,r))()}const eT=(...e)=>{const t=AM(...e);return(e,n,r,o)=>t(rT(e),n,r,o)},tT=(...e)=>{const t=NM(...e);return(e,n,r,o)=>t(rT(e),n,r,o)},nT=e=>(t,n)=>e(rT(t),n);function rT(e){return"current"in e?e.current.state:e}const oT=nT(e=>e.dimensions),iT=eT(oT,e=>e.columnsTotalWidth),aT=eT(oT,e=>e.rowHeight);eT(oT,e=>e.contentSize.height);const lT=eT(oT,e=>e.hasScrollX),sT=eT(oT,e=>e.hasScrollY),cT=eT(oT,e=>e.columnsTotalWidth<e.viewportOuterSize.width),uT=eT(oT,e=>e.headerHeight),dT=eT(oT,e=>e.groupHeaderHeight);eT(oT,e=>e.headerFilterHeight);const pT=eT(oT,e=>e.hasScrollX?e.scrollbarSize:0),fT=eT(oT,e=>e.hasScrollY?e.scrollbarSize:0),hT=eT(oT,pT,(e,t)=>{const n=e.viewportOuterSize.height-e.minimumSize.height>0;return!(0===t&&!n)}),mT=nT(e=>e.rowsMeta),gT=nT(e=>e.rows),vT=eT(gT,e=>e.totalRowCount),bT=eT(gT,e=>e.loading),yT=eT(gT,e=>e.totalTopLevelRowCount),wT=eT(gT,e=>e.dataRowIdToModelLookup);eT(wT,(e,t)=>e[t]);const xT=eT(gT,e=>e.tree),ST=eT(xT,(e,t)=>e[t]),CT=eT(gT,e=>e.groupsToFetch),kT=eT(gT,e=>e.groupingName),ET=eT(gT,e=>e.treeDepths),RT=tT(gT,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}),PT=eT(gT,e=>e.dataRowIds),MT=tT(PT,wT,(e,t)=>e.reduce((e,n)=>t[n]?(e.push(t[n]),e):e,[])),TT=tT(eT(gT,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??{}}))??[]}}),IT=eT(TT,e=>(e?.top?.length||0)+(e?.bottom?.length||0)),OT="auto-generated-group-node-root",DT=Symbol("mui.id_autogenerated");const FT=(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},LT=(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)},AT=({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=FT(r,t);i[a]=r,o.rows.push(a)}return{rowsBeforePartialUpdates:e,loadingPropBeforePartialUpdates:n,rowCountPropBeforePartialUpdates:r,updates:o,dataRowIdToModelLookup:i}},NT=({tree:e,rowCountProp:t=0})=>{const n=e[OT];return Math.max(t,n.children.length+(null==n.footerId?0:1))},$T=({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}),p=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:{}},f({},p,{totalRowCount:Math.max(t,p.dataRowIds.length),totalTopLevelRowCount:NT({tree:p.tree,rowCountProp:t}),groupingName:u,loading:n,groupsToFetch:d})},zT=e=>DT in e,jT=e=>"skeletonRow"===e.type||"footer"===e.type||"group"===e.type&&e.isAutoGenerated||"pinnedRow"===e.type&&e.isAutoGenerated,BT=(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&&jT(e[a])||i.push(a),r)continue;const l=BT(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},_T=({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=FT(e,t,"A row was provided without id when calling updateRows():");o.has(n)?o.set(n,f({},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:f({},e.updates.idToActionLookup),groupKeys:r},a=f({},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]=f({},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}},HT="var(--DataGrid-overlayHeight, calc(var(--height) * 2))";function VT(e,t,n){const r=[];return t.forEach(t=>{const o=FT(t,n,"A row was provided without id when calling updateRows():"),i=ST(e,o);if("pinnedRow"===i?.type){const n=e.current.caches.pinnedRows,r=n.idLookup[o];r&&(n.idLookup[o]=f({},r,t))}else r.push(t)}),r}const WT=(e,t,n)=>"number"==typeof e&&e>0?e:t,UT=Object.is;function GT(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,!UT(e[r],t[r]))return!1;if(!(r in t))return!1}for(const e in t)r+=1;return n===r}function KT(e){return s.memo(e,GT)}const qT={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",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",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})=>{if(!r)return`${e}–${t} of ${-1!==n?n:`more than ${t}`}`;return`${e}–${t} of ${-1!==n?n:r&&r>t?`around ${r}`:`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})`};function YT(e){return Ph("MuiDataGrid",e)}const XT=Mh("MuiDataGrid",["aiAssistantPanel","aiAssistantPanelHeader","aiAssistantPanelTitleContainer","aiAssistantPanelTitle","aiAssistantPanelBody","aiAssistantPanelEmptyText","aiAssistantPanelFooter","aiAssistantPanelConversation","aiAssistantPanelConversationList","aiAssistantPanelConversationTitle","aiAssistantPanelSuggestions","aiAssistantPanelSuggestionsList","aiAssistantPanelSuggestionsItem","aiAssistantPanelSuggestionsLabel","actionsCell","aggregationColumnHeader","aggregationColumnHeader--alignLeft","aggregationColumnHeader--alignCenter","aggregationColumnHeader--alignRight","aggregationColumnHeaderLabel","aggregationRowOverlayWrapper","autoHeight","autosizing","mainContent","withSidePanel","booleanCell","cell--editable","cell--editing","cell--flex","cell--textCenter","cell--textLeft","cell--textRight","cell--rangeTop","cell--rangeBottom","cell--rangeLeft","cell--rangeRight","cell--pinnedLeft","cell--pinnedRight","cell--selectionMode","cell","cellCheckbox","cellEmpty","cellSkeleton","cellOffsetLeft","checkboxInput","collapsible","collapsibleTrigger","collapsibleIcon","collapsiblePanel","columnHeader","columnHeader--alignCenter","columnHeader--alignLeft","columnHeader--alignRight","columnHeader--dragging","columnHeader--moving","columnHeader--numeric","columnHeader--sortable","columnHeader--sorted","columnHeader--filtered","columnHeader--pinnedLeft","columnHeader--pinnedRight","columnHeader--last","columnHeader--siblingFocused","columnHeader--filter","columnHeaderFilterInput","columnHeaderFilterOperatorLabel","columnHeaderCheckbox","columnHeaderDraggableContainer","columnHeaderTitle","columnHeaderTitleContainer","columnHeaderTitleContainerContent","columnHeader--filledGroup","columnHeader--emptyGroup","columnHeaders","columnSeparator--resizable","columnSeparator--resizing","columnSeparator--sideLeft","columnSeparator--sideRight","columnSeparator","columnsManagement","columnsManagementRow","columnsManagementHeader","columnsManagementSearchInput","columnsManagementFooter","columnsManagementScrollArea","columnsManagementEmptyText","container--top","container--bottom","detailPanel","detailPanelToggleCell","detailPanelToggleCell--expanded","footerCell","panel","panelHeader","panelWrapper","panelContent","panelFooter","paper","editBooleanCell","editInputCell","filler","filler--borderBottom","filler--pinnedLeft","filler--pinnedRight","filterForm","filterFormDeleteIcon","filterFormLogicOperatorInput","filterFormColumnInput","filterFormOperatorInput","filterFormValueInput","filterIcon","footerContainer","headerFilterRow","iconButtonContainer","iconSeparator","main","main--hasPinnedRight","main--hiddenContent","menu","menuIcon","menuIconButton","menuOpen","menuList","overlay","overlayWrapper","overlayWrapperInner","root","root--densityStandard","root--densityComfortable","root--densityCompact","root--disableUserSelection","root--noToolbar","row","row--editable","row--editing","row--firstVisible","row--lastVisible","row--dragging","row--beingDragged","row--dynamicHeight","row--detailPanelExpanded","row--borderBottom","rowReorderCellPlaceholder","rowCount","rowReorderCellContainer","rowReorderCell","rowReorderCell--draggable","rowReorderIcon","rowSkeleton","scrollArea--left","scrollArea--right","scrollArea--up","scrollArea--down","scrollArea","scrollbar","scrollbar--vertical","scrollbar--horizontal","scrollbarFiller","scrollbarFiller--pinnedRight","scrollShadow","scrollShadow--vertical","scrollShadow--horizontal","selectedRowCount","sortButton","sortIcon","shadowScrollArea","sidebar","sidebarHeader","toolbarContainer","toolbar","toolbarLabel","toolbarDivider","toolbarFilterList","toolbarQuickFilter","toolbarQuickFilterTrigger","toolbarQuickFilterControl","virtualScroller","virtualScroller--hasScrollX","virtualScrollerContent","virtualScrollerContent--overflowed","virtualScrollerRenderZone","withVerticalBorder","withBorderColor","cell--withRightBorder","cell--withLeftBorder","columnHeader--withRightBorder","columnHeader--withLeftBorder","treeDataGroupingCell","treeDataGroupingCellToggle","treeDataGroupingCellLoadingContainer","groupingCriteriaCell","groupingCriteriaCellToggle","groupingCriteriaCellLoadingContainer","pinnedRows","pinnedRows--top","pinnedRows--bottom","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"]);let QT=function(e){return e.DataGrid="DataGrid",e.DataGridPro="DataGridPro",e.DataGridPremium="DataGridPremium",e}({});class ZT{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 JT{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 eI{static create(){return new eI}}const tI={current:"undefined"!=typeof FinalizationRegistry?new JT:new ZT};let nI=0;function rI(e,t,n,r){const o=s.useState(eI.create)[0],i=s.useRef(null),a=s.useRef(null);a.current=n;const l=s.useRef(null);if(!i.current&&a.current){const n=(e,t,n)=>{t&&!t.defaultMuiPrevented&&a.current?.(e,t,n)};i.current=e.current.subscribeEvent(t,n,r),nI+=1,l.current={cleanupToken:nI},tI.current.register(o,()=>{i.current?.(),i.current=null,l.current=null},l.current)}else!a.current&&i.current&&(i.current(),i.current=null,l.current&&(tI.current.unregister(l.current),l.current=null));s.useEffect(()=>{if(!i.current&&a.current){const n=(e,t,n)=>{t&&!t.defaultMuiPrevented&&a.current?.(e,t,n)};i.current=e.current.subscribeEvent(t,n,r)}return l.current&&tI.current&&(tI.current.unregister(l.current),l.current=null),()=>{i.current?.(),i.current=null}},[e,t,r])}const oI={isFirst:!0};function iI(e,t,n){rI(e,t,n,oI)}const aI=Object.is,lI=GT,sI=(e,t)=>e===t||e.length===t.length&&e.every((e,n)=>e===t[n]),cI=()=>({state:null,equals:null,selector:null,args:void 0}),uI=[],dI=()=>null;function pI(e,t,n=void 0,r=aI){e.current.state;const o=Dg(cI),i=null!==o.current.selector,[a,l]=s.useState(i?null:t(e,n));o.current.state=a,o.current.equals=r,o.current.selector=t;const c=o.current.args;if(o.current.args=n,i&&!((e,t)=>{let n=Object.is;return t instanceof Array?n=sI:t instanceof Object&&(n=lI),n(e,t)})(c,n)){const t=o.current.selector(e,o.current.args);o.current.equals(o.current.state,t)||(o.current.state=t,l(t))}const u=s.useCallback(()=>(o.current.subscription||(o.current.subscription=e.current.store.subscribe(()=>{const t=o.current.selector(e,o.current.args);o.current.equals(o.current.state,t)||(o.current.state=t,l(t))})),null),uI),d=s.useCallback(()=>(o.current.subscription||u(),()=>{o.current.subscription&&(o.current.subscription(),o.current.subscription=void 0)}),uI);return WM.useSyncExternalStore(d,u,dI),a}const fI={compact:.7,comfortable:1.3,standard:1},hI=nT(e=>e.density),mI=eT(hI,e=>fI[e]);function gI(e){throw new Error("Failed assertion: should not be rendered")}const vI=["id","value","formattedValue","api","field","row","rowNode","colDef","cellMode","isEditable","tabIndex","hasFocus","isValidating","debounceMs","isProcessingProps","onValueChange","slotProps"],bI=pg(gI,{name:"MuiDataGrid",slot:"EditInputCell"})({font:bP.typography.font.body,padding:"1px 0","& input":{padding:"0 16px",height:"100%"}}),yI=TR((e,t)=>{const n=rP(),{id:r,value:o,field:i,colDef:a,hasFocus:l,debounceMs:c=200,isProcessingProps:u,onValueChange:p,slotProps:h}=e,m=d(e,vI),g=lP(),v=s.useRef(null),[b,y]=s.useState(o),w=(e=>{const{classes:t}=e;return wm({root:["editInputCell"]},YT,t)})(n),x=s.useCallback(async e=>{const t=e.target.value,n=g.current.getColumn(i);let o=t;n.valueParser&&(o=n.valueParser(t,g.current.getRow(r),n,g)),y(o),g.current.setEditCellValue({id:r,field:i,value:o,debounceMs:c,unstable_skipValueParser:!0},e),p&&await p(e,t)},[g,c,i,r,p]),S=g.current.unstable_getEditCellMeta(r,i);return s.useEffect(()=>{"debouncedSetEditCellValue"!==S?.changeReason&&y(o)},[S,o]),Wh(()=>{l&&v.current.focus()},[l]),Xp.jsx(bI,f({as:n.slots.baseInput,inputRef:v,className:w.root,ownerState:n,fullWidth:!0,type:"number"===a.type?a.type:"text",value:b??"",onChange:x,endAdornment:u?Xp.jsx(n.slots.loadIcon,{fontSize:"small",color:"action"}):void 0},m,h?.root,{ref:t}))}),wI=(e,t)=>t&&e.length>1?[e[0]]:e,xI=(e,t)=>n=>f({},n,{sorting:f({},n.sorting,{sortModel:wI(e,t)})}),SI=(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:ST(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)},CI=(e,t)=>{const n=e.indexOf(t);return t&&-1!==n&&n+1!==e.length?e[n+1]:e[0]},kI=(e,t)=>null==e&&null!=t?-1:null==t&&null!=e?1:null==e&&null==t?0:null,EI=new Intl.Collator,RI=(e,t)=>{const n=kI(e,t);return null!==n?n:Number(e)-Number(t)},PI=(e,t)=>{const n=kI(e,t);return null!==n?n:e>t?1:e<t?-1:0},MI=["item","applyValue","type","apiRef","focusElementRef","tabIndex","disabled","isFilterActive","slotProps","clearButton","headerFilterMenu"];function TI(e){const{item:t,applyValue:n,type:r,apiRef:o,focusElementRef:i,tabIndex:a,disabled:l,slotProps:c,clearButton:u,headerFilterMenu:p}=e,h=d(e,MI),m=c?.root,g=Ng(),[v,b]=s.useState(II(t.value)),[y,w]=s.useState(!1),x=mm(),S=rP(),C=s.useCallback(e=>{const o=II(e.target.value);b(o),w(!0),g.start(S.filterDebounceMs,()=>{const e=f({},t,{value:"number"!==r||Number.isNaN(Number(o))?o:Number(o),fromInput:x});n(e),w(!1)})},[g,S.filterDebounceMs,t,r,x,n]);return s.useEffect(()=>{t.fromInput===x&&null!=t.value||b(II(t.value))},[x,t]),Xp.jsxs(s.Fragment,{children:[Xp.jsx(S.slots.baseTextField,f({id:x,label:o.current.getLocaleText("filterPanelInputLabel"),placeholder:o.current.getLocaleText("filterPanelInputPlaceholder"),value:v??"",onChange:C,type:r||"text",disabled:l,slotProps:f({},m?.slotProps,{input:f({endAdornment:y?Xp.jsx(S.slots.loadIcon,{fontSize:"small",color:"action"}):null},m?.slotProps?.input),htmlInput:f({tabIndex:a},m?.slotProps?.htmlInput)}),inputRef:i},S.slotProps?.baseTextField,h,m)),p,u]})}function II(e){if(null!=e&&""!==e)return String(e)}function OI(e){return"object"==typeof e&&null!==e}function DI(e){return e.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")}const FI=(e,t,n)=>Math.max(t,Math.min(n,e));function LI(e){return"function"==typeof structuredClone?structuredClone(e):JSON.parse(JSON.stringify(e))}const AI=(e,t)=>n=>{e&&t(n)};function NI(e){const{item:t,applyValue:n,type:r,apiRef:o,focusElementRef:i,slotProps:a}=e,l=mm(),[c,u]=s.useState([]),[d,p]=s.useState(t.value||[]),h=rP();s.useEffect(()=>{const e=t.value??[];p(e.map(String))},[t.value]);const m=s.useCallback((e,o)=>{p(o.map(String)),n(f({},t,{value:[...o.map(e=>"number"===r?Number(e):e)]}))},[n,t,r]),g=s.useCallback((e,t)=>{u(""===t?[]:[t])},[u]),v=h.slots.baseAutocomplete;return Xp.jsx(v,f({multiple:!0,freeSolo:!0,options:c,id:l,value:d,onChange:m,onInputChange:g,label:o.current.getLocaleText("filterPanelInputLabel"),placeholder:o.current.getLocaleText("filterPanelInputPlaceholder"),slotProps:{textField:{type:r||"text",inputRef:i}}},a?.root))}var $I=function(e){return e.Cell="cell",e.Row="row",e}($I||{}),zI=function(e){return e.Edit="edit",e.View="view",e}(zI||{}),jI=function(e){return e.Edit="edit",e.View="view",e}(jI||{}),BI=function(e){return e.And="and",e.Or="or",e}(BI||{});class _I{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 HI{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 VI=e=>"include"===e.type?new _I(e):new HI(e);var WI=function(e){return e.enterKeyDown="enterKeyDown",e.cellDoubleClick="cellDoubleClick",e.printableKeyDown="printableKeyDown",e.deleteKeyDown="deleteKeyDown",e.pasteKeyDown="pasteKeyDown",e}(WI||{}),UI=function(e){return e.cellFocusOut="cellFocusOut",e.escapeKeyDown="escapeKeyDown",e.enterKeyDown="enterKeyDown",e.tabKeyDown="tabKeyDown",e.shiftTabKeyDown="shiftTabKeyDown",e}(UI||{}),GI=function(e){return e.enterKeyDown="enterKeyDown",e.cellDoubleClick="cellDoubleClick",e.printableKeyDown="printableKeyDown",e.deleteKeyDown="deleteKeyDown",e}(GI||{}),KI=function(e){return e.rowFocusOut="rowFocusOut",e.escapeKeyDown="escapeKeyDown",e.enterKeyDown="enterKeyDown",e.tabKeyDown="tabKeyDown",e.shiftTabKeyDown="shiftTabKeyDown",e}(KI||{});function qI(e){return void 0!==e.field}const YI={filteredRowsLookup:{},filteredChildrenCountLookup:{},filteredDescendantCountLookup:{}},XI=()=>({items:[],logicOperator:BI.And,quickFilterValues:[],quickFilterLogicOperator:BI.And});function QI(e){return{current:e.current.getPublicApi()}}let ZI=function(e){return e.LEFT="left",e.RIGHT="right",e}({});const JI={left:[],right:[]},eO=nT(e=>e.isRtl),tO=nT(e=>e.props.listView??!1),nO=nT(e=>e.listViewColumn),rO=nT(e=>e.columns),oO=eT(rO,e=>e.orderedFields),iO=eT(rO,e=>e.lookup),aO=tT(oO,iO,(e,t)=>e.map(e=>t[e])),lO=eT(rO,e=>e.columnVisibilityModel),sO=eT(rO,e=>e.initialColumnVisibilityModel),cO=tT(aO,lO,tO,nO,(e,t,n,r)=>n&&r?[r]:e.filter(e=>!1!==t[e.field])),uO=tT(cO,e=>e.map(e=>e.field)),dO=nT(e=>e.pinnedColumns);tT(dO,oO,eO,(e,t,n)=>fO(e,t,n));const pO=tT(rO,dO,uO,eO,tO,(e,t,n,r,o)=>{if(o)return JI;const i=fO(t,n,r);return{left:i.left.map(t=>e.lookup[t]),right:i.right.map(t=>e.lookup[t])}});function fO(e,t,n){if(!Array.isArray(e.left)&&!Array.isArray(e.right))return JI;if(0===e.left?.length&&0===e.right?.length)return JI;const r=(e,t)=>Array.isArray(e)?e.filter(e=>t.includes(e)):[],o=r(e.left,t),i=t.filter(e=>!o.includes(e)),a=r(e.right,i);return n?{left:a,right:o}:{left:o,right:a}}const hO=tT(cO,e=>{const t=[];let n=0;for(let r=0;r<e.length;r+=1)t.push(n),n+=e[r].computedWidth;return t}),mO=tT(aO,e=>e.filter(e=>e.filterable)),gO=tT(aO,e=>e.reduce((e,t)=>(t.filterable&&(e[t.field]=t),e),{})),vO=tT(aO,e=>e.some(e=>void 0!==e.colSpan));let bO;const yO=(e,t)=>{const n=f({},e);if(null==n.id&&(n.id=Math.round(1e5*Math.random())),null==n.operator){const e=iO(t)[n.field];n.operator=e&&e.filterOperators[0].value}return n},wO=(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?f({},e,{items:o.map(e=>yO(e,n))}):e.items!==o?f({},e,{items:o}):e},xO=(e,t,n)=>r=>f({},r,{filterModel:wO(e,t,n)}),SO=e=>"string"==typeof e?e.normalize("NFD").replace(/[\u0300-\u036f]/g,""):e,CO=(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=SO(o));const a=f({},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=QI(n),u=s.getApplyFilterFn(a,r);return"function"!=typeof u?null:{item:a,fn:e=>{let n=t(e,r);return i&&(n=SO(n)),u(n,e,r,c)}}};let kO=1;const EO=(e,t,n,r)=>{const{items:o}=e,i=o.map(e=>CO(e,t,n)).filter(e=>!!e);if(0===i.length)return null;if(r||!function(){if(void 0!==bO)return bO;try{bO=new Function("return true")()}catch(e){bO=!1}return bO}())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(kO)));kO+=1;return(e,t)=>a(i,e,t)},RO=e=>e.quickFilterExcludeHiddenColumns??!0,PO=(e,t,n,r)=>{const o=EO(e,t,n,r),i=((e,t,n)=>{const r=e.quickFilterValues?.filter(Boolean)??[];if(0===r.length)return null;const o=oO(n),i=lO(n);let a;a=RO(e)?o.filter(e=>!1!==i[e]):o;const l=[],{ignoreDiacritics:s}=n.current.rootProps,c=QI(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?SO(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:p}=u;if(n&&!n(p))continue;const f=d[i];let h=t(e,u);if(null!==f.fn&&(s&&(h=SO(h)),f.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}},MO=e=>null!=e,TO=(e,t,n,r,o,i)=>{const a=((e,t,n,r)=>(e.cleanedFilterItems||(e.cleanedFilterItems=r.filter(e=>null!==CO(e,t,n))),e.cleanedFilterItems))(i,r,o,n.items),l=e.filter(MO),s=t.filter(MO);if(l.length>0){const e=e=>l.some(t=>t[e.id]);if((n.logicOperator??XI().logicOperator)===BI.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??XI().quickFilterLogicOperator)===BI.And){if(!n.quickFilterValues.every(e))return!1}else{if(!n.quickFilterValues.some(e))return!1}}return!0},IO=(e,t)=>n=>{if(!n.value)return null;const r=e?n.value:n.value.trim(),o=new RegExp(DI(r),"i");return e=>{if(null==e)return t;const n=o.test(String(e));return t?!n:n}},OO=(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}},DO=e=>()=>t=>{const n=""===t||null==t;return e?!n:n},FO={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=kI(e,t);return null!==n?n:"string"==typeof e?EI.compare(e.toString(),t.toString()):e-t},type:"string",align:"left",filterOperators:((e=!1)=>[{value:"contains",getApplyFilterFn:IO(e,!1),InputComponent:TI},{value:"doesNotContain",getApplyFilterFn:IO(e,!0),InputComponent:TI},{value:"equals",getApplyFilterFn:OO(e,!1),InputComponent:TI},{value:"doesNotEqual",getApplyFilterFn:OO(e,!0),InputComponent:TI},{value:"startsWith",getApplyFilterFn:t=>{if(!t.value)return null;const n=e?t.value:t.value.trim(),r=new RegExp(`^${DI(n)}.*$`,"i");return e=>null!=e&&r.test(e.toString())},InputComponent:TI},{value:"endsWith",getApplyFilterFn:t=>{if(!t.value)return null;const n=e?t.value:t.value.trim(),r=new RegExp(`.*${DI(n)}$`,"i");return e=>null!=e&&r.test(e.toString())},InputComponent:TI},{value:"isEmpty",getApplyFilterFn:DO(!1),requiresFilterValue:!1},{value:"isNotEmpty",getApplyFilterFn:DO(!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:NI}])(),renderEditCell:e=>Xp.jsx(yI,f({},e)),getApplyQuickFilterFn:e=>{if(!e)return null;const t=new RegExp(DI(e),"i");return(e,n,r,o)=>{let i=o.current.getRowFormattedValue(n,r);return o.current.ignoreDiacritics&&(i=SO(i)),null!=i&&t.test(i.toString())}}};function LO(e){return 1===e.key.length&&!e.ctrlKey&&!e.metaKey}const AO=e=>0===e.indexOf("Arrow")||0===e.indexOf("Page")||" "===e||"Home"===e||"End"===e,NO=e=>"Tab"===e||"Escape"===e;function $O(e){return(e.ctrlKey||e.metaKey)&&"V"===String.fromCharCode(e.keyCode)&&!e.shiftKey&&!e.altKey}const zO=s.createContext(void 0),jO=()=>{const e=s.useContext(zO);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},BO=s.createContext({className:"unset",tag:Xp.jsx("style",{href:"/unset"})});function _O(){return s.useContext(BO).className}function HO(e){const t=jO(),n=rP(),r=t.hooks.useCSSVariables(),o=s.useMemo(()=>{const e=`MuiDataGridVariables-${r.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}(r.variables)}}`;return{className:e,tag:Xp.jsx("style",{href:`/${e}`,nonce:n.nonce,children:t})}},[n.nonce,r]);return Xp.jsx(BO.Provider,{value:o,children:e.children})}const VO=["open","target","onClose","children","position","className","onExited"],WO=pg(gI,{name:"MuiDataGrid",slot:"Menu"})({zIndex:bP.zIndex.menu,[`& .${XT.menuList}`]:{outline:0}});function UO(e){const{open:t,target:n,onClose:r,children:o,position:i,className:a,onExited:l}=e,c=d(e,VO),u=lP(),p=rP(),h=(e=>{const{classes:t}=e;return wm({root:["menu"]},YT,t)})(p),m=_O(),g=s.useRef(null);Wh(()=>{t?g.current=document.activeElement instanceof HTMLElement?document.activeElement:null:(g.current?.focus?.(),g.current=null)},[t]),s.useEffect(()=>{const e=t?"menuOpen":"menuClose";u.current.publishEvent(e,{target:n})},[u,t,n]);return Xp.jsx(WO,f({as:p.slots.basePopper,className:PR(h.root,a,m),ownerState:p,open:t,target:n,transition:!0,placement:i,onClickAway:e=>{e.target&&(n===e.target||n?.contains(e.target))||r(e)},onExited:l,clickAwayMouseEvent:"onMouseDown",onKeyDown:e=>{NO(e.key)&&r(e)}},c,p.slotProps?.basePopper,{children:o}))}const GO=["label","icon","showInMenu","onClick"],KO=["label","icon","showInMenu","onClick","closeMenuOnClick","closeMenu"],qO=TR((e,t)=>{const n=rP();if(!e.showInMenu){const{label:r,icon:o,onClick:i}=e,a=d(e,GO),l=e=>{i?.(e)};return Xp.jsx(n.slots.baseIconButton,f({size:"small",role:"menuitem","aria-label":r},a,{onClick:l},n.slotProps?.baseIconButton,{ref:t,children:s.cloneElement(o,{fontSize:"small"})}))}const{label:r,icon:o,onClick:i,closeMenuOnClick:a=!0,closeMenu:l}=e,c=d(e,KO);return Xp.jsx(n.slots.baseMenuItem,f({ref:t},c,{onClick:e=>{i?.(e),a&&l?.()},iconStart:o,children:r}))}),YO=["api","colDef","id","hasFocus","isEditable","field","value","formattedValue","row","rowNode","cellMode","tabIndex","position","children","suppressChildrenValidation"];function XO(e){const{hasFocus:t,tabIndex:n,position:r="bottom-end",children:o,suppressChildrenValidation:i}=e,a=d(e,YO),[l,c]=s.useState(-1),[u,p]=s.useState(!1),h=lP(),m=s.useRef(null),g=s.useRef(null),v=s.useRef(!1),b=s.useRef({}),y=um(),w=mm(),x=mm(),S=rP(),C=[];s.Children.forEach(o,e=>{s.isValidElement(e)&&(e.type===s.Fragment?s.Children.forEach(e.props.children,e=>{s.isValidElement(e)&&C.push(e)}):e.type===qO||i?C.push(e):"function"==typeof e.type?e.type.name:e.type)});const k=C.filter(e=>!e.props.showInMenu),E=C.filter(e=>e.props.showInMenu),R=k.length+(E.length?1:0);s.useLayoutEffect(()=>{t||Object.entries(b.current).forEach(([e,t])=>{t?.stop({},()=>{delete b.current[e]})})},[t]),s.useEffect(()=>{if(l<0||!m.current)return;if(l>=m.current.children.length)return;m.current.children[l].focus({preventScroll:!0})},[l]);const P=C.findIndex(e=>!e.props.disabled);s.useEffect(()=>{t&&-1===l&&c(P),t||(c(-1),v.current=!1)},[t,l,P]),s.useEffect(()=>{l>=R&&c(R-1)},[l,R]);const M=()=>{p(!1)},T=e=>t=>{b.current[e]=t},I=(e,t)=>n=>{c(e),v.current=!0,t&&t(n)},O=R>0?{role:"menu",onKeyDown:e=>{if(R<=1)return;const t=(e,n)=>{if(e<0||e>C.length)return e;const r=("left"===n?-1:1)*(y?-1:1);return C[e+r]?.props.disabled?t(e+r,n):e+r};let n=l;"ArrowRight"===e.key?n=t(l,"right"):"ArrowLeft"===e.key&&(n=t(l,"left")),n<0||n>=R||n!==l&&(e.preventDefault(),e.stopPropagation(),c(n))}}:void 0;return Xp.jsxs("div",f({ref:m,tabIndex:-1,className:XT.actionsCell},O,a,{children:[k.map((e,t)=>s.cloneElement(e,{key:t,touchRippleRef:T(t),onClick:I(t,e.props.onClick),tabIndex:l===t?n:-1})),E.length>0&&x&&Xp.jsx(S.slots.baseIconButton,f({ref:g,id:x,"aria-label":h.current.getLocaleText("actionsCellMore"),"aria-haspopup":"menu","aria-expanded":u,"aria-controls":u?w:void 0,role:"menuitem",size:"small",onClick:e=>{e.stopPropagation(),e.preventDefault(),u?M():(p(!0),c(R-1),v.current=!0)},touchRippleRef:T(x),tabIndex:l===k.length?n:-1},S.slotProps?.baseIconButton,{children:Xp.jsx(S.slots.moreActionsIcon,{fontSize:"small"})})),E.length>0&&Xp.jsx(UO,{open:u,target:g.current,position:r,onClose:M,children:Xp.jsx(S.slots.baseMenuList,{id:w,className:XT.menuList,"aria-labelledby":x,autoFocusItem:!0,children:E.map((e,t)=>s.cloneElement(e,{key:t,closeMenu:M}))})})]}))}function QO(e){const{colDef:t,id:n}=e,r=lP();if(!(e=>"function"==typeof e.getActions)(t))throw new Error("MUI X: Missing the `getActions` property in the `GridColDef`.");const o=t.getActions(r.current.getRowParams(n));return Xp.jsx(XO,f({suppressChildrenValidation:!0},e,{children:o}))}const ZO="actions",JO=f({},FO,{sortable:!1,filterable:!1,aggregable:!1,chartable:!1,width:100,display:"flex",align:"center",headerAlign:"center",headerName:"",disableColumnMenu:!0,disableExport:!0,renderCell:e=>Xp.jsx(QO,f({},e)),getApplyQuickFilterFn:()=>null}),eD="__row_group_by_columns_group__",tD="__detail_panel_toggle__";let nD=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 rD=["id","value","formattedValue","api","field","row","rowNode","colDef","cellMode","isEditable","hasFocus","tabIndex","hideDescendantCount"];function oD(e){const{value:t,rowNode:n}=e,r=d(e,rD),o=lP(),i=rP(),a=(e=>{const{classes:t}=e;return wm({root:["booleanCell"]},YT,t)})({classes:i.classes}),l=pI(o,RT)>0&&"group"===n.type&&!1===i.treeData,c=s.useMemo(()=>t?i.slots.booleanCellTrueIcon:i.slots.booleanCellFalseIcon,[i.slots.booleanCellFalseIcon,i.slots.booleanCellTrueIcon,t]);return l&&void 0===t?null:Xp.jsx(c,f({fontSize:"small",className:a.root,titleAccess:o.current.getLocaleText(t?"booleanCellTrueLabel":"booleanCellFalseLabel"),"data-value":Boolean(t)},r))}const iD=s.memo(oD),aD=["id","value","formattedValue","api","field","row","rowNode","colDef","cellMode","isEditable","tabIndex","className","hasFocus","isValidating","isProcessingProps","error","onValueChange"];function lD(e){const{id:t,value:n,field:r,className:o,hasFocus:i,onValueChange:a}=e,l=d(e,aD),c=lP(),u=s.useRef(null),p=mm(),[h,m]=s.useState(n),g=rP(),v=(e=>{const{classes:t}=e;return wm({root:["editBooleanCell"]},YT,t)})({classes:g.classes}),b=s.useCallback(async e=>{const n=e.target.checked;a&&await a(e,n),m(n),await c.current.setEditCellValue({id:t,field:r,value:n},e)},[c,r,t,a]);return s.useEffect(()=>{m(n)},[n]),Wh(()=>{i&&u.current.focus()},[i]),Xp.jsx("label",f({htmlFor:p,className:PR(v.root,o)},l,{children:Xp.jsx(g.slots.baseCheckbox,f({id:p,inputRef:u,checked:Boolean(h),onChange:b,size:"small"},g.slotProps?.baseCheckbox))}))}const sD=["item","applyValue","apiRef","focusElementRef","isFilterActive","headerFilterMenu","clearButton","tabIndex","slotProps"];function cD(e){const{item:t,applyValue:n,apiRef:r,focusElementRef:o,headerFilterMenu:i,clearButton:a,tabIndex:l,slotProps:c}=e,u=d(e,sD),[p,h]=s.useState(uD(t.value)),m=rP(),g=mm(),v=mm(),b=m.slotProps?.baseSelect||{},y=b.native??!1,w=m.slotProps?.baseSelectOption||{},x=s.useCallback(e=>{const r=uD(e.target.value);h(r),n(f({},t,{value:r}))},[n,t]);s.useEffect(()=>{h(uD(t.value))},[t.value]);const S=c?.root.label??r.current.getLocaleText("filterPanelInputLabel"),C=c?.root.slotProps;return Xp.jsxs(s.Fragment,{children:[Xp.jsxs(m.slots.baseSelect,f({fullWidth:!0,labelId:g,id:v,label:S,value:void 0===p?"":String(p),onChange:x,native:y,slotProps:{htmlInput:f({ref:o,tabIndex:l},C?.htmlInput)}},b,u,c?.root,{children:[Xp.jsx(m.slots.baseSelectOption,f({},w,{native:y,value:"",children:r.current.getLocaleText("filterValueAny")})),Xp.jsx(m.slots.baseSelectOption,f({},w,{native:y,value:"true",children:r.current.getLocaleText("filterValueTrue")})),Xp.jsx(m.slots.baseSelectOption,f({},w,{native:y,value:"false",children:r.current.getLocaleText("filterValueFalse")}))]})),i,a]})}function uD(e){return"true"===String(e).toLowerCase()||"false"!==String(e).toLowerCase()&&void 0}const dD=f({},FO,{type:"boolean",display:"flex",align:"center",headerAlign:"center",renderCell:e=>e.field!==eD&&jT(e.rowNode)?"":Xp.jsx(iD,f({},e)),renderEditCell:e=>Xp.jsx(lD,f({},e)),sortComparator:RI,valueFormatter:(e,t,n,r)=>e?r.current.getLocaleText("booleanCellTrueLabel"):r.current.getLocaleText("booleanCellFalseLabel"),filterOperators:[{value:"is",getApplyFilterFn:e=>{const t=uD(e.value);return void 0===t?null:e=>Boolean(e)===t},InputComponent:cD}],getApplyQuickFilterFn:()=>null,aggregable:!1,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)});function pD(e){for(const t in e)return!1;return!0}const fD=nT(e=>e.sorting),hD=eT(fD,e=>e.sortedRows),mD=tT(hD,wT,xT,(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&&jT(t)&&e.push({id:r,model:{[DT]:r}})}return e},[])),gD=eT(fD,e=>e.sortModel),vD=tT(gD,e=>{const t=e.reduce((t,n,r)=>(t[n.field]={sortDirection:n.sort,sortIndex:e.length>1?r+1:void 0},t),{});return t});tT(hD,e=>e.reduce((e,t,n)=>(e[t]=n,e),Object.create(null)));const bD=nT(e=>e.filter),yD=eT(bD,e=>e.filterModel),wD=eT(yD,e=>e.quickFilterValues),xD=nT(e=>e.visibleRowsLookup),SD=eT(bD,e=>e.filteredRowsLookup);eT(bD,e=>e.filteredChildrenCountLookup),eT(bD,e=>e.filteredDescendantCountLookup);const CD=tT(xD,mD,(e,t)=>pD(e)?t:t.filter(t=>!1!==e[t.id])),kD=tT(CD,e=>e.map(e=>e.id)),ED=tT(SD,mD,(e,t)=>pD(e)?t:t.filter(t=>!1!==e[t.id])),RD=tT(ED,e=>e.map(e=>e.id));tT(kD,xT,(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},{})});const PD=eT(tT(ED,xT,RT,(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]??[]),MD=eT(CD,e=>e.length),TD=eT(PD,e=>e.length),ID=eT(ED,e=>e.length);eT(ID,TD,(e,t)=>e-t);const OD=tT(yD,iO,(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);return!!r&&(!r.InputComponent||null!=e.value&&""!==e.value?.toString())})),DD=tT(OD,e=>{const t=e.reduce((e,t)=>(e[t.field]?e[t.field].push(t):e[t.field]=[t],e),{});return t}),FD=tT(kD,e=>e.reduce((e,t,n)=>(e[t]=n,e),Object.create(null))),LD=nT(e=>e.rowSelection),AD=tT(LD,VI),ND=eT(LD,ID,(e,t)=>"include"===e.type?e.ids.size:t-e.ids.size),$D=tT(LD,wT,PT,(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}),zD=nT((e,t)=>DT in t?t[DT]:e.props.getRowId?e.props.getRowId(t):t.id),jD=nT(e=>e.props.isRowSelectable);function BD(e,t){const n=xT(e),r=hD(e),o=SD(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 _D=eT(aO,xT,SD,AD,wT,jD,(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&&(u=i(c)),!s||"group"!==s.type||r.has(a))return{isIndeterminate:!1,isChecked:r.has(a),isSelectable:u};let d=!1,p=!1;const f=e=>{if(!1===n[e]||d&&p)return;const o=t[e];"group"===o?.type&&o.children.forEach(f),r.has(e)?d=!0:p=!0};return f(a),{isIndeterminate:d&&p,isChecked:!!l&&(d&&!p),isSelectable:u}});function HD(e){return e.signature===QT.DataGrid?e.checkboxSelection&&!0!==e.disableMultipleRowSelection:!e.disableMultipleRowSelection}const VD=(e,t,n,r,o,i,a=AD(e))=>{const l=SD(e),s=new Set([]);if((r||o)&&!1!==l[n]){if(r){const r=t[n];if("group"===r?.type){BD(e,n).forEach(e=>{i(e),s.add(e)})}}if(o){const r=e=>{if(!a.has(e)&&!s.has(e))return!1;const n=t[e];return!!n&&("group"!==n.type||n.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);if(0===a.length||a.every(r)){const r=t[n],a=r?.parent;null!=a&&a!==OT&&e.current.isRowSelectable(a)&&(i(a),s.add(a),o(a))}},c=t[n];if(!c||c.parent===OT)return;o(n)}}},WD=(e,t,n,r,o,i)=>{const a=AD(e);if(o||r){if(o){const e=((e,t)=>{const n=[];let r=t;for(;null!=r&&r!==OT;){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];if("group"===r?.type){BD(e,n).forEach(e=>{i(e)})}}}},UD=["field","id","formattedValue","row","rowNode","colDef","isEditable","cellMode","hasFocus","tabIndex","api"],GD=TR(function(e,t){const{field:n,id:r,rowNode:o,tabIndex:i}=e,a=d(e,UD),l=lP(),c=rP(),u=(e=>{const{classes:t}=e;return wm({root:["checkboxInput"]},YT,t)})({classes:c.classes}),{isIndeterminate:p,isChecked:h,isSelectable:m}=pI(l,_D,{groupId:r,autoSelectParents:c.rowSelectionPropagation?.parents??!1}),g=!m;s.useLayoutEffect(()=>{if(0===i){const e=l.current.getCellElement(r,n);e&&(e.tabIndex=-1)}},[l,i,r,n]);const v=Mg(e=>{" "===e.key&&e.stopPropagation()}),b=Mg(e=>{g&&e.preventDefault()}),y=Mg(()=>{});if("footer"===o.type||"pinnedRow"===o.type)return null;const w=l.current.getLocaleText(h&&!p?"checkboxSelectionUnselectRow":"checkboxSelectionSelectRow");return Xp.jsx(c.slots.baseCheckbox,f({tabIndex:i,checked:h&&!p,onChange:e=>{if(g)return;const t={value:e.target.checked,id:r};l.current.publishEvent("rowSelectionCheckboxChange",t,e)},onClick:b,onMouseDown:y,className:PR(u.root,g&&"Mui-disabled"),material:{disableRipple:g},slotProps:{htmlInput:{"aria-disabled":g||void 0,"aria-label":w,name:"select_row"}},onKeyDown:v,indeterminate:p},c.slotProps?.baseCheckbox,a,{ref:t}))}),KD=GD,qD=nT(e=>e.focus),YD=eT(qD,e=>e.cell),XD=eT(qD,e=>e.columnHeader);eT(qD,e=>e.columnHeaderFilter);const QD=eT(qD,e=>e.columnGroupHeader),ZD=nT(e=>e.tabIndex),JD=eT(ZD,e=>e.cell),eF=eT(ZD,e=>e.columnHeader);eT(ZD,e=>e.columnHeaderFilter);const tF=eT(ZD,e=>e.columnGroupHeader),nF=(e,t,n)=>t>0&&e>0?Math.ceil(e/t):-1===e?n+2:0,rF=e=>({page:0,pageSize:e?0:100}),oF=(e,t)=>{if(t===QT.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"))},iF=nT(e=>e.pagination),aF=eT(iF,e=>e.enabled&&"client"===e.paginationMode),lF=eT(iF,e=>e.paginationModel),sF=eT(iF,e=>e.rowCount),cF=eT(iF,e=>e.meta),uF=eT(lF,e=>e.page),dF=eT(lF,e=>e.pageSize),pF=eT(lF,sF,(e,t)=>nF(t,e.pageSize,e.page)),fF=tT(aF,lF,xT,RT,CD,PD,(e,t,n,r,o,i)=>{if(!e)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 p=d,f=0;for(;p<o.length&&f<=u;){const e=o[p],t=n[e.id]?.depth;void 0===t?p+=1:((f<u||t>0)&&(p+=1),0===t&&(f+=1))}return{firstRowIndex:d,lastRowIndex:p-1}}),hF=tT(CD,fF,(e,t)=>t?e.slice(t.firstRowIndex,t.lastRowIndex+1):[]),mF=tT(kD,fF,(e,t)=>t?e.slice(t.firstRowIndex,t.lastRowIndex+1):[]),gF=tT(aF,fF,hF,CD,(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)}),vF=["field","colDef"],bF=TR(function(e,t){const n=d(e,vF),[,r]=s.useState(!1),o=lP(),i=rP(),a=(e=>{const{classes:t}=e;return wm({root:["checkboxInput"]},YT,t)})({classes:i.classes}),l=pI(o,eF),c=pI(o,LD),u=pI(o,kD),p=pI(o,mF),h=s.useMemo(()=>{const e=i.isRowSelectable;if("function"!=typeof e)return c;if("exclude"===c.type)return c;const t={type:"include",ids:new Set};for(const n of c.ids)i.keepNonExistentRowsSelected&&t.ids.add(n),o.current.getRow(n)&&e(o.current.getRowParams(n))&&t.ids.add(n);return t},[o,i.isRowSelectable,i.keepNonExistentRowsSelected,c]),m=s.useMemo(()=>{const e=i.pagination&&i.checkboxSelectionVisibleOnly&&"server"!==i.paginationMode?p:u,t=new Set;for(let n=0;n<e.length;n+=1){const r=e[n];o.current.getRow(r)&&(o.current.isRowSelectable(r)&&t.add(r))}return t},[o,i.pagination,i.paginationMode,i.checkboxSelectionVisibleOnly,p,u]),g=s.useMemo(()=>{const e=VI(h);let t=0;for(const n of m)e.has(n)&&(t+=1);return t},[h,m]),v=s.useMemo(()=>{if(0===g)return!1;const e=VI(h);for(const t of m)if(!e.has(t))return!0;return!1},[g,h,m]),b=g>0,y=null!==l&&l.field===e.field?0:-1;s.useLayoutEffect(()=>{const t=o.current.getColumnHeaderElement(e.field);0===y&&t&&(t.tabIndex=-1)},[y,o,e.field]);const w=s.useCallback(e=>{" "===e.key&&o.current.publishEvent("headerSelectionCheckboxChange",{value:!b})},[o,b]),x=s.useCallback(()=>{r(e=>!e)},[]);s.useEffect(()=>o.current.subscribeEvent("rowSelectionChange",x),[o,x]);const S=o.current.getLocaleText(b&&!v?"checkboxSelectionUnselectAllRows":"checkboxSelectionSelectAllRows");return Xp.jsx(i.slots.baseCheckbox,f({indeterminate:v,checked:b&&!v,onChange:e=>{const t={value:e.target.checked};o.current.publishEvent("headerSelectionCheckboxChange",t)},className:a.root,slotProps:{htmlInput:{"aria-label":S,name:"select_all_rows"}},tabIndex:y,onKeyDown:w,disabled:!HD(i)},i.slotProps?.baseCheckbox,n,{ref:t}))}),yF="__check__",wF=f({},dD,{type:"custom",field:yF,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=zD(r,t);return r.current.isRowSelected(o)},rowSpanValueGetter:(e,t,n,r)=>zD(r,t),renderHeader:e=>Xp.jsx(bF,f({},e)),renderCell:e=>Xp.jsx(KD,f({},e))}),xF=["item","applyValue","type","apiRef","focusElementRef","slotProps","isFilterActive","headerFilterMenu","clearButton","tabIndex","disabled"];function SF(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 CF(e){const{item:t,applyValue:n,type:r,apiRef:o,focusElementRef:i,slotProps:a,headerFilterMenu:l,clearButton:c,tabIndex:u,disabled:p}=e,h=d(e,xF),m=a?.root.slotProps,g=Ng(),[v,b]=s.useState(()=>SF(t.value,r)),[y,w]=s.useState(!1),x=mm(),S=rP(),C=s.useCallback(e=>{g.clear();const r=e.target.value;b(r),w(!0),g.start(S.filterDebounceMs,()=>{const e=new Date(r);n(f({},t,{value:Number.isNaN(e.getTime())?void 0:e})),w(!1)})},[n,t,S.filterDebounceMs,g]);return s.useEffect(()=>{const e=SF(t.value,r);b(e)},[t.value,r]),Xp.jsxs(s.Fragment,{children:[Xp.jsx(S.slots.baseTextField,f({fullWidth:!0,id:x,label:o.current.getLocaleText("filterPanelInputLabel"),placeholder:o.current.getLocaleText("filterPanelInputPlaceholder"),value:v,onChange:C,type:r||"text",disabled:p,inputRef:i,slotProps:f({},m,{input:f({endAdornment:y?Xp.jsx(S.slots.loadIcon,{fontSize:"small",color:"action"}):null},m?.input),htmlInput:f({max:"datetime-local"===r?"9999-12-31T23:59":"9999-12-31",tabIndex:u},m?.htmlInput)})},S.slotProps?.baseTextField,h,a?.root)),l,c]})}function kF(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 EF=e=>[{value:"is",getApplyFilterFn:t=>kF(t,(e,t)=>e===t,e),InputComponent:CF,InputComponentProps:{type:e?"datetime-local":"date"}},{value:"not",getApplyFilterFn:t=>kF(t,(e,t)=>e!==t,e),InputComponent:CF,InputComponentProps:{type:e?"datetime-local":"date"}},{value:"after",getApplyFilterFn:t=>kF(t,(e,t)=>e>t,e),InputComponent:CF,InputComponentProps:{type:e?"datetime-local":"date"}},{value:"onOrAfter",getApplyFilterFn:t=>kF(t,(e,t)=>e>=t,e),InputComponent:CF,InputComponentProps:{type:e?"datetime-local":"date"}},{value:"before",getApplyFilterFn:t=>kF(t,(e,t)=>e<t,e,!e),InputComponent:CF,InputComponentProps:{type:e?"datetime-local":"date"}},{value:"onOrBefore",getApplyFilterFn:t=>kF(t,(e,t)=>e<=t,e),InputComponent:CF,InputComponentProps:{type:e?"datetime-local":"date"}},{value:"isEmpty",getApplyFilterFn:()=>e=>null==e,requiresFilterValue:!1},{value:"isNotEmpty",getApplyFilterFn:()=>e=>null!=e,requiresFilterValue:!1}],RF=["id","value","formattedValue","api","field","row","rowNode","colDef","cellMode","isEditable","tabIndex","hasFocus","inputProps","isValidating","isProcessingProps","onValueChange","slotProps"],PF=pg(gI)({fontSize:"inherit"});function MF(e){const{id:t,value:n,field:r,colDef:o,hasFocus:i,onValueChange:a,slotProps:l}=e,c=d(e,RF),u="dateTime"===o.type,p=lP(),h=s.useRef(null),m=s.useMemo(()=>{let e,t;if(e=null==n?null:n instanceof Date?n:new Date((n??"").toString()),null==e||Number.isNaN(e.getTime()))t="";else{t=new Date(e.getTime()-60*e.getTimezoneOffset()*1e3).toISOString().substr(0,u?16:10)}return{parsed:e,formatted:t}},[n,u]),[g,v]=s.useState(m),b=rP(),y=(e=>{const{classes:t}=e;return wm({root:["editInputCell"]},YT,t)})({classes:b.classes}),w=s.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},[]),x=s.useCallback(async e=>{const n=e.target.value,o=w(n);a&&await a(e,o),v({parsed:o,formatted:n}),p.current.setEditCellValue({id:t,field:r,value:o},e)},[p,r,t,a,w]);return s.useEffect(()=>{v(e=>m.parsed!==e.parsed&&m.parsed?.getTime()!==e.parsed?.getTime()?m:e)},[m]),Wh(()=>{i&&h.current.focus()},[i]),Xp.jsx(PF,f({as:b.slots.baseInput,inputRef:h,fullWidth:!0,className:y.root,type:u?"datetime-local":"date",value:g.formatted,onChange:x},c,l?.root,{slotProps:{htmlInput:f({max:u?"9999-12-31T23:59":"9999-12-31"},l?.root?.slotProps?.htmlInput)}}))}const TF=e=>Xp.jsx(MF,f({},e));function IF({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 OF=f({},FO,{type:"date",sortComparator:PI,valueFormatter:(e,t,n,r)=>{if(!e)return"";const o=zD(r,t);return!zT(t)||e instanceof Date?(IF({value:e,columnType:"date",rowId:o,field:n.field}),e.toLocaleDateString()):e},filterOperators:EF(),renderEditCell:TF,pastedValueParser:e=>new Date(e)}),DF=f({},FO,{type:"dateTime",sortComparator:PI,valueFormatter:(e,t,n,r)=>{if(!e)return"";const o=zD(r,t);return!zT(t)||e instanceof Date?(IF({value:e,columnType:"dateTime",rowId:o,field:n.field}),e.toLocaleString()):e},filterOperators:EF(!0),renderEditCell:TF,pastedValueParser:e=>new Date(e)}),FF=e=>null==e?null:Number(e),LF=f({},FO,{type:"number",align:"right",headerAlign:"right",sortComparator:RI,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=>FF(t)===e.value,InputComponent:TI,InputComponentProps:{type:"number"}},{value:"!=",getApplyFilterFn:e=>null==e.value||Number.isNaN(e.value)?null:t=>FF(t)!==e.value,InputComponent:TI,InputComponentProps:{type:"number"}},{value:">",getApplyFilterFn:e=>null==e.value||Number.isNaN(e.value)?null:t=>null!=t&&FF(t)>e.value,InputComponent:TI,InputComponentProps:{type:"number"}},{value:">=",getApplyFilterFn:e=>null==e.value||Number.isNaN(e.value)?null:t=>null!=t&&FF(t)>=e.value,InputComponent:TI,InputComponentProps:{type:"number"}},{value:"<",getApplyFilterFn:e=>null==e.value||Number.isNaN(e.value)?null:t=>null!=t&&FF(t)<e.value,InputComponent:TI,InputComponentProps:{type:"number"}},{value:"<=",getApplyFilterFn:e=>null==e.value||Number.isNaN(e.value)?null:t=>null!=t&&FF(t)<=e.value,InputComponent:TI,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:NI,InputComponentProps:{type:"number"}}],getApplyQuickFilterFn:e=>null==e||Number.isNaN(e)||""===e?null:t=>FF(t)===FF(e)});function AF(e){return"singleSelect"===e?.type}function NF(e,t){if(e)return"function"==typeof e.valueOptions?e.valueOptions(f({field:e.field},t)):e.valueOptions}function $F(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 zF=["id","value","formattedValue","api","field","row","rowNode","colDef","cellMode","isEditable","tabIndex","className","hasFocus","isValidating","isProcessingProps","error","onValueChange","initialOpen","slotProps"];function jF(e){const t=rP(),{id:n,value:r,field:o,row:i,colDef:a,hasFocus:l,error:c,onValueChange:u,initialOpen:p=t.editMode===$I.Cell,slotProps:h}=e,m=d(e,zF),g=lP(),v=s.useRef(null),b=s.useRef(null),[y,w]=s.useState(p),x=(t.slotProps?.baseSelect||{}).native??!1;if(Wh(()=>{l&&b.current?.focus()},[l]),!AF(a))return null;const S=NF(a,{id:n,row:i});if(!S)return null;const C=a.getOptionValue,k=a.getOptionLabel;return S&&a?Xp.jsx(t.slots.baseSelect,f({ref:v,value:r,onChange:async e=>{if(!AF(a)||!S)return;w(!1);const t=$F(e.target.value,S,C);u&&await u(e,t),await g.current.setEditCellValue({id:n,field:o,value:t},e)},open:y,onOpen:e=>{(function(e){return"key"in e&&!!e.key})(e)&&"Enter"===e.key||w(!0)},onClose:(e,r)=>{if(t.editMode!==$I.Row){if("backdropClick"===r||"Escape"===e.key){const t=g.current.getCellParams(n,o);g.current.publishEvent("cellEditStop",f({},t,{reason:"Escape"===e.key?UI.escapeKeyDown:UI.cellFocusOut}))}}else w(!1)},error:c,native:x,fullWidth:!0,slotProps:{htmlInput:{ref:b}}},m,h?.root,t.slotProps?.baseSelect,{children:S.map(e=>{const n=C(e);return s.createElement(t.slots.baseSelectOption,f({},t.slotProps?.baseSelectOption||{},{native:x,key:n,value:n}),k(e))})})):null}const BF=["item","applyValue","type","apiRef","focusElementRef","tabIndex","isFilterActive","clearButton","headerFilterMenu","slotProps"],_F=({column:e,OptionComponent:t,getOptionLabel:n,getOptionValue:r,isSelectNative:o,baseSelectOptionProps:i})=>["",...NF(e)||[]].map(e=>{const a=r(e);let l=n(e);return""===l&&(l=" "),s.createElement(t,f({},i,{native:o,key:a,value:a}),l)});function HF(e){const{item:t,applyValue:n,type:r,apiRef:o,focusElementRef:i,tabIndex:a,clearButton:l,headerFilterMenu:c,slotProps:u}=e,p=d(e,BF),h=t.value??"",m=mm(),g=mm(),v=rP(),b=v.slotProps?.baseSelect?.native??!1,y=o.current.getColumn(t.field),w=y.getOptionValue,x=y.getOptionLabel,S=s.useMemo(()=>NF(y),[y]),C=s.useCallback(e=>{let r=e.target.value;r=$F(r,S,w),n(f({},t,{value:r}))},[S,w,n,t]);if(!y||!AF(y))return null;const k=u?.root.label??o.current.getLocaleText("filterPanelInputLabel");return Xp.jsxs(s.Fragment,{children:[Xp.jsx(v.slots.baseSelect,f({fullWidth:!0,id:m,label:k,labelId:g,value:h,onChange:C,slotProps:{htmlInput:f({tabIndex:a,ref:i,type:r||"text",placeholder:u?.root.placeholder??o.current.getLocaleText("filterPanelInputPlaceholder")},u?.root.slotProps?.htmlInput)},native:b},v.slotProps?.baseSelect,p,u?.root,{children:_F({column:y,OptionComponent:v.slots.baseSelectOption,getOptionLabel:x,getOptionValue:w,isSelectNative:b,baseSelectOptionProps:v.slotProps?.baseSelectOption})})),c,l]})}const VF=["item","applyValue","type","apiRef","focusElementRef","slotProps"];function WF(e){const{item:t,applyValue:n,type:r,apiRef:o,focusElementRef:i,slotProps:a}=e,l=d(e,VF),c=mm(),u=rP(),p=o.current.getColumn(t.field),h=p.getOptionValue,m=p.getOptionLabel,g=s.useCallback((e,t)=>h(e)===h(t),[h]),v=s.useMemo(()=>NF(p)||[],[p]),b=s.useMemo(()=>Array.isArray(t.value)?t.value.reduce((e,t)=>{const n=v.find(e=>h(e)===t);return null!=n&&e.push(n),e},[]):[],[h,t.value,v]),y=s.useCallback((e,r)=>{n(f({},t,{value:r.map(h)}))},[n,t,h]);if(!p||!AF(p))return null;const w=u.slots.baseAutocomplete;return Xp.jsx(w,f({multiple:!0,options:v,isOptionEqualToValue:g,id:c,value:b,onChange:y,getOptionLabel:m,label:o.current.getLocaleText("filterPanelInputLabel"),placeholder:o.current.getLocaleText("filterPanelInputPlaceholder"),slotProps:{textField:{type:r||"text",inputRef:i}}},l,a?.root))}const UF=e=>null!=e&&OI(e)?e.value:e,GF=f({},FO,{type:"singleSelect",getOptionLabel:e=>OI(e)?e.label:String(e),getOptionValue:e=>OI(e)?e.value:e,valueFormatter(e,t,n,r){const o=zD(r,t);if(!AF(n))return"";const i=NF(n,{id:o,row:t});if(null==e)return"";if(!i)return e;if("object"!=typeof i[0])return n.getOptionLabel(e);const a=i.find(t=>n.getOptionValue(t)===e);return a?n.getOptionLabel(a):""},renderEditCell:e=>Xp.jsx(jF,f({},e)),filterOperators:[{value:"is",getApplyFilterFn:e=>null==e.value||""===e.value?null:t=>UF(t)===UF(e.value),InputComponent:HF},{value:"not",getApplyFilterFn:e=>null==e.value||""===e.value?null:t=>UF(t)!==UF(e.value),InputComponent:HF},{value:"isAnyOf",getApplyFilterFn:e=>{if(!Array.isArray(e.value)||0===e.value.length)return null;const t=e.value.map(UF);return e=>t.includes(UF(e))},InputComponent:WF}],pastedValueParser:(e,t,n)=>{const r=n,o=NF(r)||[],i=r.getOptionValue;if(o.find(t=>i(t)===e))return e}}),KF=nT(e=>e.headerFiltering),qF=eT(KF,e=>e?.enabled??!1),YF=eT(KF,e=>e.editing),XF=eT(KF,e=>e.menuOpen),QF=nT(e=>e.columnGrouping),ZF=tT(QF,e=>e?.unwrappedGroupingModel??{}),JF=tT(QF,e=>e?.lookup??{}),eL=tT(QF,e=>e?.headerStructure??[]),tL=eT(QF,e=>e?.maxDepth??0),nL=["maxWidth","minWidth","width","flex"],rL={string:FO,number:LF,date:OF,dateTime:DF,boolean:dD,singleSelect:GF,[ZO]:JO,custom:FO};const oL=(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=FI(a.width||FO.width,a.minWidth||FO.minWidth,a.maxWidth||FO.maxWidth),o+=l),a.computedWidth!==l&&(a=f({},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]=f({},n[t],{computedWidth:e[t].computedWidth})})}return f({},e,{lookup:n})};function iL(e){let t=rL.string;return e&&rL[e]&&(t=rL[e]),t}const aL=({apiRef:e,columnsToUpsert:t,initialState:n,columnVisibilityModel:r=lO(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=rO(e);l={orderedFields:o?[]:[...t.orderedFields],lookup:f({},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=f({},iL(e.type),{field:t,hasBeenResized:!1}),l.orderedFields.push(t)):o&&l.orderedFields.push(t),n&&n.type!==e.type&&(n=f({},iL(e.type),{field:t}));let r=n.hasBeenResized;nL.forEach(t=>{void 0!==e[t]&&(r=!0,-1===e[t]&&(e[t]=1/0))}),l.lookup[t]=Hh(n,f({},iL(e.type),e,{hasBeenResized:r}))}),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=f({},e.lookup);for(let e=0;e<o.length;e+=1){const t=o[e],n=f({},s[t],{hasBeenResized:!0});Object.entries(r[t]).forEach(([e,t])=>{n[e]=-1===t?1/0:t}),s[t]=n}return f({},e,{orderedFields:l,lookup:s})})(e.current.unstable_applyPipeProcessors("hydrateColumns",l),n);return oL(c,e.current.getRootDimensions?.()??void 0)};function lL(e,t){if(t.listView)return 0;const n=mI(e),r=tL(e),o=qF(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 sL=jh("div",{name:"MuiDataGrid",slot:"ScrollArea",overridesResolver:(e,t)=>[{[`&.${XT["scrollArea--left"]}`]:t["scrollArea--left"]},{[`&.${XT["scrollArea--right"]}`]:t["scrollArea--right"]},{[`&.${XT["scrollArea--up"]}`]:t["scrollArea--up"]},{[`&.${XT["scrollArea--down"]}`]:t["scrollArea--down"]},t.scrollArea]})(()=>({position:"absolute",zIndex:101,[`&.${XT["scrollArea--left"]}`]:{top:0,left:0,width:20,bottom:0},[`&.${XT["scrollArea--right"]}`]:{top:0,right:0,width:20,bottom:0},[`&.${XT["scrollArea--up"]}`]:{top:0,left:0,right:0,height:20},[`&.${XT["scrollArea--down"]}`]:{bottom:0,left:0,right:0,height:20}})),cL=eT(oT,(e,t)=>"left"===t?e.leftPinnedWidth:"right"===t?e.rightPinnedWidth+(e.hasScrollX?e.scrollbarSize:0):0);function uL(e){const{scrollDirection:t,scrollPosition:n}=e,r=s.useRef(null),o=lP(),i=Ng(),a=pI(o,mI),l=pI(o,iT),c=pI(o,cL,t),u=rP(),d=lL(o,u),p=Math.floor(u.columnHeaderHeight*a),h=f({height:p,top:d-p},"left"===t?{left:c}:{},"right"===t?{right:c}:{}),m=Mg(e=>{let a;if(e.preventDefault(),"left"===t)a=e.clientX-r.current.getBoundingClientRect().right;else{if("right"!==t)throw new Error("MUI X: Wrong drag direction");a=Math.max(1,e.clientX-r.current.getBoundingClientRect().left)}a=1.5*(a-1)+1,i.start(0,()=>{o.current.scroll({left:n.current.left+a,top:n.current.top})})});return Xp.jsx(pL,f({},e,{ref:r,getCanScrollMore:()=>{const e=oT(o);if("left"===t)return n.current.left>0;if("right"===t){const t=l-e.viewportInnerSize.width;return n.current.left<t}return!1},style:h,handleDragOver:m}))}function dL(e){const{scrollDirection:t,scrollPosition:n}=e,r=s.useRef(null),o=lP(),i=Ng(),a=pI(o,mT),l=rP(),c=lL(o,l),u={top:"up"===t?c:void 0,bottom:"down"===t?0:void 0},d=Mg(e=>{let a;if(e.preventDefault(),"up"===t)a=e.clientY-r.current.getBoundingClientRect().bottom;else{if("down"!==t)throw new Error("MUI X: Wrong drag direction");a=Math.max(1,e.clientY-r.current.getBoundingClientRect().top)}a=1.5*(a-1)+1,i.start(0,()=>{o.current.scroll({left:n.current.left,top:n.current.top+a})})});return Xp.jsx(pL,f({},e,{ref:r,getCanScrollMore:()=>{const e=oT(o);if("up"===t)return n.current.top>0;if("down"===t){const t=(a.currentPageTotalHeight||0)-e.viewportInnerSize.height-(e.hasScrollX?e.scrollbarSize:0);return n.current.top<t}return!1},style:u,handleDragOver:d}))}const pL=TR(function(e,t){const{scrollDirection:n,getCanScrollMore:r,style:o,handleDragOver:i}=e,a=lP(),[l,c]=s.useState(r),u=f({},rP(),{scrollDirection:n}),d=(e=>{const{scrollDirection:t,classes:n}=e;return wm({root:["scrollArea",`scrollArea--${t}`]},YT,n)})(u);return rI(a,"scrollPositionChange",()=>{c(r)}),l?Xp.jsx(sL,{ref:t,className:d.root,ownerState:u,onDragOver:i,style:o}):null}),fL=KT(function(e){const t=lP(),[n,r]=s.useState("none");return rI(t,"columnHeaderDragStart",()=>r("horizontal")),rI(t,"columnHeaderDragEnd",()=>r("none")),rI(t,"rowDragStart",()=>r("vertical")),rI(t,"rowDragEnd",()=>r("none")),"none"===n?null:"horizontal"===n?Xp.jsx(uL,f({},e)):Xp.jsx(dL,f({},e))}),hL=s.createContext(void 0);function mL(){const e=s.useContext(hL);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 gL=()=>{};function vL(e,t,n){const r=s.useRef(!0);Wh(()=>{r.current=!1,e.current.register(n,t)},[e,n,t]),r.current&&e.current.register(n,t)}function bL(e,t){const n=s.useRef(null);if(n.current)return n.current;const r=e.current.getLogger(t);return n.current=r,r}const yL=(e,t,n,r,o)=>{const i=bL(e,"useNativeEventListener");iI(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)}})};function wL(e){const t=s.useRef(!0);t.current&&(t.current=!1,e())}const xL=nT(e=>e.pivoting),SL=eT(xL,e=>e?.active),CL=new Map,kL=eT(xL,e=>e?.initialColumns||CL),EL=(e,t)=>{const n=pI(e,vT),r=pI(e,MD),o=pI(e,IT),i=pI(e,cO),a=0===n&&0===o,l=pI(e,bT),s=pI(e,SL),c=!l&&a,u=!l&&n>0&&0===r;let d=null,p=null;return c&&(d="noRowsOverlay"),!l&&0===i.length&&(d="noColumnsOverlay"),c&&s&&(d="emptyPivotOverlay"),u&&(d="noResultsOverlay"),l&&(d="loadingOverlay",p=t.slotProps?.loadingOverlay?.[a?"noRowsVariant":"variant"]??(a?"skeleton":"linear-progress")),{overlayType:d,loadingOverlayVariant:p}},RL=nT(e=>e.columnMenu);const PL=KT(function(){const e=mL(),t=rP(),n=pI(e,cO),r=pI(e,DD),o=pI(e,vD),i=pI(e,eF),a=pI(e,()=>null===JD(e)),l=pI(e,tF),s=pI(e,XD),c=pI(e,QD),u=pI(e,tL),d=pI(e,RL),p=pI(e,lO),h=pI(e,eL),m=!(null===l&&null===i&&a),g=e.current.columnHeadersContainerRef;return Xp.jsx(t.slots.columnHeaders,f({ref:g,visibleColumns:n,filterColumnLookup:r,sortColumnLookup:o,columnHeaderTabIndexState:i,columnGroupHeaderTabIndexState:l,columnHeaderFocus:s,columnGroupHeaderFocus:c,headerGroupingMaxDepth:u,columnMenuState:d,columnVisibility:p,columnGroupsHeaderStructure:h,hasOtherElementInTabSequence:m},t.slotProps?.columnHeaders))}),ML=jh("div")({position:"absolute",top:"var(--DataGrid-headersTotalHeight)",left:0,width:"calc(100% - (var(--DataGrid-hasScrollY) * var(--DataGrid-scrollbarSize)))"}),TL=jh("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"}),IL=TR((e,t)=>{const{ownerState:n}=e,r=rP(),o=jO().hooks.useGridAriaAttributes();return Xp.jsxs(TL,f({ownerState:n,className:e.className,tabIndex:-1},o,r.slotProps?.main,{ref:t,children:[Xp.jsx(ML,{role:"presentation","data-id":"gridPanelAnchor"}),e.children]}))}),OL=jh("div")({position:"sticky",zIndex:40,top:0});function DL(e){const t=wm({root:["topContainer"]},YT,{});return Xp.jsx(OL,f({},e,{className:PR(t.root,XT["container--top"]),role:"presentation"}))}const FL=jh("div",{name:"MuiDataGrid",slot:"VirtualScrollerContent",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.virtualScrollerContent,n.overflowedContent&&t["virtualScrollerContent--overflowed"]]}})({}),LL=TR(function(e,t){const n=rP(),r=!n.autoHeight&&"auto"===e.style?.minHeight,o=((e,t)=>{const{classes:n}=e;return wm({root:["virtualScrollerContent",t&&"virtualScrollerContent--overflowed"]},YT,n)})(n,r),i={classes:n.classes,overflowedContent:r};return Xp.jsx(FL,f({},e,{ownerState:i,className:PR(o.root,e.className),ref:t}))}),AL=jh("div")({display:"flex",flexDirection:"row",width:"var(--DataGrid-rowWidth)",boxSizing:"border-box"}),NL=jh("div")({position:"sticky",height:"100%",boxSizing:"border-box",borderTop:"1px solid var(--rowBorderColor)",backgroundColor:bP.cell.background.pinned}),$L=jh(NL)({left:0}),zL=jh(NL)({right:0}),jL=jh("div")({flexGrow:1,borderTop:"1px solid var(--rowBorderColor)"});const BL=KT(function({rowsLength:e}){const t=lP(),{viewportOuterSize:n,minimumSize:r,hasScrollX:o,hasScrollY:i,scrollbarSize:a,leftPinnedWidth:l,rightPinnedWidth:s}=pI(t,oT),c=o?a:0,u=n.height-r.height>0;return 0!==c||u?Xp.jsxs(AL,{className:XT.filler,role:"presentation",style:{height:c,"--rowBorderColor":0===e?"transparent":"var(--DataGrid-rowBorderColor)"},children:[l>0&&Xp.jsx($L,{className:XT["filler--pinnedLeft"],style:{width:l}}),Xp.jsx(jL,{}),s>0&&Xp.jsx(zL,{className:XT["filler--pinnedRight"],style:{width:s+(i?a:0)}})]}):null}),_L=jh("div",{name:"MuiDataGrid",slot:"VirtualScrollerRenderZone"})({position:"absolute",display:"flex",flexDirection:"column"}),HL=TR(function(e,t){const n=rP(),r=(e=>{const{classes:t}=e;return wm({root:["virtualScrollerRenderZone"]},YT,t)})(n);return Xp.jsx(_L,f({ownerState:n},e,{className:PR(r.root,e.className),ref:t}))}),VL={includeHeaders:!0,includeOutliers:!1,outliersFactor:1.5,expand:!1,disableColumnVirtualization:!0},WL=nT(e=>e.editRows),UL=eT(WL,(e,{rowId:t,editMode:n})=>n===$I.Row&&Boolean(e[t])),GL=eT(WL,(e,{rowId:t,field:n})=>e[t]?.[n]??null),KL=nT(e=>e.preferencePanel),qL=eT(KL,(e,t)=>!(!e.open||e.labelId!==t));var YL=function(e){return e.filters="filters",e.columns="columns",e.aiAssistant="aiAssistant",e}(YL||{});const XL={initialize:function(e){return{colspanMap:new Map}},use:function(e,t,n){const r=t.colspan?.getColspan,o=Mg(r?(t,n,o,i)=>{for(let a=n;a<o;a+=1){const l=QL(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:{}};function QL(e,t,n,r,o,i,a){const l=i.length,s=i[t],c=a(n,s,t);if(!c||1===c)return ZL(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;if(s>=r&&s<o){u+=i[s].computedWidth,ZL(e,n,t+a,{spannedByColSpan:!0,rightVisibleCellIndex:Math.min(t+c,l-1),leftVisibleCellIndex:t})}ZL(e,n,t,{spannedByColSpan:!1,cellProps:{colSpan:c,width:u}})}return{colSpan:c}}function ZL(e,t,n,r){let o=e.get(t);o||(o={},e.set(t,o)),o[n]=r}function JL(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(!JL(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(!JL(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(!JL(e[r],t[r]))return!1}return!0}return e!=e&&t!=t}function eA(e,t){return Math.round(e*10**t)/10**t}const tA={EMPTY:{width:0,height:0},equals:(e,t)=>e.width===t.width&&e.height===t.height},nA={EMPTY:{top:[],bottom:[]}},rA={EMPTY:{left:[],right:[]}},oA={EMPTY:{top:0,left:0}};let iA=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}({});(iA||(iA={})).forDelta=function(e,t){return 0===e&&0===t?iA.NONE:Math.abs(t)>=Math.abs(e)?t>0?iA.DOWN:iA.UP:e>0?iA.RIGHT:iA.LEFT};const aA={isReady:!1,root:tA.EMPTY,viewportOuterSize:tA.EMPTY,viewportInnerSize:tA.EMPTY,contentSize:tA.EMPTY,minimumSize:tA.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},lA={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:NM((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},sA={initialize:function(e){const t=f({},aA,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:tA.EMPTY,dimensions:t,rowsMeta:o,rowHeights:i}},use:function(e,t,n){const r=s.useRef(!0),{layout:o,dimensions:{rowHeight:i,columnsTotalWidth:a,leftPinnedWidth:l,rightPinnedWidth:c,topPinnedHeight:u,bottomPinnedHeight:d},onResize:p}=t,h=s.useCallback(n=>{if(n&&(r.current=!1),r.current)return;const s=o.refs.container.current,f=lA.rootSize(e.state),h=lA.rowsMeta(e.state),m=function(e,t){if(void 0!==t)return t;if(null===e)return 0;const n=cA.get(e);if(void 0!==n)return n;const r=kg(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),cA.set(e,o),o}(s,t.dimensions.scrollbarSize),g=u+h.pinnedTopRowsTotalHeight,v=d+h.pinnedBottomRowsTotalHeight,b={width:a,height:eA(h.currentPageTotalHeight,1)};let y,w,x=!1,S=!1;if(t.dimensions.autoHeight)S=!1,x=Math.round(a)>Math.round(f.width),y={width:f.width,height:g+v+b.height},w={width:Math.max(0,y.width-(S?m:0)),height:Math.max(0,y.height-(x?m:0))};else{y={width:f.width,height:f.height},w={width:Math.max(0,y.width),height:Math.max(0,y.height-g-v)};const e=b,t=w,n=e.width>t.width,r=e.height>t.height;(n||r)&&(S=r,x=e.width+(S?m:0)>t.width,x&&(S=e.height+m>t.height)),S&&(w.width-=m),x&&(w.height-=m)}t.disableHorizontalScroll&&(x=!1),t.disableVerticalScroll&&(S=!1);const C=Math.max(y.width,a+(S?m:0)),k={isReady:!0,root:f,viewportOuterSize:y,viewportInnerSize:w,contentSize:b,minimumSize:{width:a,height:g+b.height+v},hasScrollX:x,hasScrollY:S,scrollbarSize:m,rowWidth:C,rowHeight:i,columnsTotalWidth:a,leftPinnedWidth:l,rightPinnedWidth:c,topContainerHeight:g,bottomContainerHeight:v,autoHeight:t.dimensions.autoHeight,minimalContentHeight:t.dimensions.minimalContentHeight};JL(e.state.dimensions,k)||(e.update({dimensions:k}),p?.(k.root))},[e,o.refs.container,t.dimensions.scrollbarSize,t.dimensions.autoHeight,t.dimensions.minimalContentHeight,t.disableHorizontalScroll,t.disableVerticalScroll,p,i,a,l,c,u,d]),{resizeThrottleMs:m}=t,g=Mg(h),v=s.useMemo(()=>m>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}(g,m):void 0,[m,g]);s.useEffect(()=>v?.clear,[v]),Wh(h,[h]),Wh(()=>{e.update({dimensions:f({},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:o,getRowHeight:i,getRowSpacing:a,getEstimatedRowHeight:l}=t,c=s.useRef(-1),u=s.useRef(!1),d=s.useRef(!1),p=t.pinnedRows,f=YM(e,lA.rowHeight),h=Mg(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:m}=t,g=s.useCallback(t=>{const n=lA.dimensions(e.state),r=n.rowHeight,o=h(t.id);if(i){const e=i(t);if("auto"===e){if(o.needsFirstMeasurement){const e=l?l(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(a){const e=a(t);o.spacingTop=e.top??0,o.spacingBottom=e.bottom??0}else o.spacingTop=0,o.spacingBottom=0;return m?.(o,t),o},[e,i,h,l,f,a,m]),v=s.useCallback(()=>{u.current=!1;const t=p?.top.reduce((e,t)=>{const n=g(t);return e+n.content+n.spacingTop+n.spacingBottom+n.detail},0)??0,r=p?.bottom.reduce((e,t)=>{const n=g(t);return e+n.content+n.spacingTop+n.spacingBottom+n.detail},0)??0,i=[],a=o.reduce((e,t)=>{i.push(e);const n=g(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:i,pinnedTopRowsTotalHeight:t,pinnedBottomRowsTotalHeight:r};e.set("rowsMeta",s),l&&n(),d.current=!0},[e,p,o,g,n]),b=Mg(v),y=t=>r.get(t)?.content??lA.rowHeight(e.state),w=(e,t)=>{const n=h(e),r=n.content!==t;n.needsFirstMeasurement=!1,n.content=t,d.current&&=!r},x=e=>r.get(e)?.autoHeight??!1,S=()=>c.current,C=e=>{u.current&&e>c.current&&(c.current=e)},k=()=>{r.clear(),v()},E=Dg(()=>"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;w(i,o)}d.current||requestAnimationFrame(()=>{b()})})).current,R=(e,t)=>(e.__mui_id=t,E?.observe(e),()=>E?.unobserve(e));return Wh(()=>{v()},[v]),{getRowHeight:y,setLastMeasuredRowIndex:C,storeRowHeightMeasurement:w,hydrateRowsMeta:v,observeRowHeight:R,rowHasAutoHeight:x,getRowHeightEntry:h,getLastMeasuredRowIndex:S,resetRowHeights:k}}(e,t,h);return{updateDimensions:h,debouncedUpdateDimensions:v,rowsMeta:b}},selectors:lA};const cA=new WeakMap;const uA=("undefined"!=typeof navigator?navigator.userAgent.toLowerCase():"empty").includes("firefox"),dA="undefined"!=typeof window&&/jsdom|HappyDOM/.test(window.navigator.userAgent),pA=(e,t,n)=>Math.max(t,Math.min(n,e)),fA={top:0,left:0},hA=Object.freeze(new Map),mA={firstRowIndex:0,lastRowIndex:0,firstColumnIndex:0,lastColumnIndex:0},gA=(()=>{const e=AM(e=>e.virtualization.renderContext.firstRowIndex);return{store:AM(e=>e.virtualization),renderContext:AM(e=>e.virtualization.renderContext),enabledForRows:AM(e=>e.virtualization.enabledForRows),enabledForColumns:AM(e=>e.virtualization.enabledForColumns),offsetTop:AM(sA.selectors.rowPositions,e,(e,t)=>e[t]??0),context:AM(e=>e.virtualization.context),scrollPosition:AM(e=>e.virtualization.scrollPosition)}})(),vA={initialize:function(e){const t={virtualization:f({enabled:!dA,enabledForRows:!dA,enabledForColumns:!dA,renderContext:mA,props:e.layout.constructor.elements.reduce((e,t)=>(e[t],e),{}),context:{},scrollPosition:{current:oA.EMPTY}},e.initialState?.virtualization),getters:null};return t},use:function(e,t,n){const{layout:r,dimensions:{rowHeight:o,columnsTotalWidth:i=0},virtualization:{isRtl:a=!1,rowBufferPx:l=150,columnBufferPx:c=150},colspan:u,initialState:d,rows:p,range:h,columns:m,pinnedRows:g=nA.EMPTY,pinnedColumns:v=rA.EMPTY,onWheel:b,onTouchMove:y,onRenderContextChange:w,onScrollChange:x,scrollReset:S,renderRow:C,renderInfiniteLoadingTrigger:k}=t,E=g.bottom.length>0,[R,P]=s.useState(hA),M=s.useRef(!1),T=s.useRef(!1),I=YM(e,gA.renderContext),O=YM(e,gA.enabledForRows),D=YM(e,gA.enabledForColumns),F=YM(e,sA.selectors.contentHeight),L=s.useRef(d?.scroll??fA),A=s.useRef(!1),N=s.useRef(fA),$=s.useRef(mA),z=Ng(),j=s.useRef(void 0),B=Dg(()=>function(e,t,n,r,o){return{direction:iA.NONE,buffer:RA(e,iA.NONE,t,n,r,o)}}(a,l,c,15*o,300)).current,_=s.useCallback(t=>{kA(t,e.state.virtualization.renderContext)||e.set("virtualization",f({},e.state.virtualization,{renderContext:t,scrollPosition:{current:f({},L.current)}}));const n=sA.selectors.dimensions(e.state).isReady,r=t.firstRowIndex!==$.current.firstRowIndex||t.lastRowIndex!==$.current.lastRowIndex;n&&r&&($.current=t,w?.(t)),N.current=L.current},[e,w]),H=Mg(()=>{const i=r.refs.scroller.current;if(!i)return;const s=sA.selectors.dimensions(e.state),u=Math.ceil(s.contentSize.height-s.viewportInnerSize.height),d=Math.ceil(s.contentSize.width-s.viewportInnerSize.width),p={top:pA(i.scrollTop,0,u),left:a?pA(i.scrollLeft,-Math.abs(d),0):pA(i.scrollLeft,0,d)},h=p.left-L.current.left,m=p.top-L.current.top,g=0!==h||0!==m;L.current=p;const v=g?iA.forDelta(h,m):iA.NONE,b=Math.abs(L.current.top-N.current.top),y=Math.abs(L.current.left-N.current.left),w=b>=o||y>=50,x=B.direction!==v;if(!(w||x))return e.set("virtualization",f({},e.state.virtualization,{scrollPosition:{current:f({},L.current)}})),I;if(x)switch(v){case iA.NONE:case iA.LEFT:case iA.RIGHT:j.current=void 0;break;default:j.current=I}B.direction=v,B.buffer=RA(a,v,l,c,15*o,300);const S=wA(yA(e,t,n,O,D),L.current,B);return kA(S,I)||(So.flushSync(()=>{_(S)}),z.start(1e3,H)),S}),V=()=>{if(!sA.selectors.dimensions(e.state).isReady&&(O||D))return;const r=wA(yA(e,t,n,O,D),L.current,B);j.current=void 0,_(r)},W=Mg(V);QM(e,sA.selectors.dimensions,(e,t)=>{t.isReady&&V()}),Wh(()=>{M.current&&(V(),M.current=!1)});const U=Mg(()=>{if(A.current)return void(A.current=!1);const e=H();e&&x?.(L.current,e)}),G=s.useRef(null);Wh(()=>{T.current&&W()},[D,O,W]),Wh(()=>{r.refs.scroller.current&&(r.refs.scroller.current.scrollLeft=0)},[r.refs.scroller,S]),((e,t)=>{const n=s.useRef(!1);Wh(()=>n.current||!e?gL:(n.current=!0,t()),[n.current||e])})(I!==mA,()=>{if(x?.(L.current,I),T.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&&i&&(e.scrollLeft=n,o.left=!0,A.current=!0),!o.top&&F&&(e.scrollTop=t,A.current=!0),o.top&&o.left||(G.current=(r,i)=>{!o.left&&r&&(e.scrollLeft=n,o.left=!0,A.current=!0),!o.top&&i&&(e.scrollTop=t,o.top=!0,A.current=!0),o.left&&o.top&&(G.current=null)})}}),QM(e,sA.selectors.dimensions,V),Wh(()=>{r.refs.scroller&&G.current?.(i,F)},[r.refs.scroller,i,F]);const K=s.useRef(!0),q=bA(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!==tA.EMPTY&&tA.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)};tA.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,K.current||!n.debouncedUpdateDimensions?(n.updateDimensions(K.current),K.current=!1):n.debouncedUpdateDimensions())});return()=>{o?.(),r.refs.container.current=null}}),Y=bA(e=>{r.refs.scroller.current=e;const t={passive:!0};return e.addEventListener("scroll",U,t),e.addEventListener("wheel",b,t),e.addEventListener("touchmove",y,t),()=>{e.removeEventListener("scroll",U,t),e.removeEventListener("wheel",b,t),e.removeEventListener("touchmove",y,t),r.refs.scroller.current=null}}),X={containerRef:q,scrollerRef:Y},Q=r.use(e,t,n,X),Z=f({setPanels:P,getRows:(r={},o)=>{if(!r.rows&&!h)return[];let a=I;r.renderContext&&(a=r.renderContext,a.firstColumnIndex=I.firstColumnIndex,a.lastColumnIndex=I.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+p.length;break;default:c=g.top.length}const d=r.rows??p,f=a.firstRowIndex,b=Math.min(a.lastRowIndex,d.length),y=r.rows?PA(0,r.rows.length):PA(f,b);let w=-1;const x=t.focusedVirtualCell?.();!s&&x&&(x.rowIndex<f&&(y.unshift(x.rowIndex),w=x.rowIndex),x.rowIndex>b&&(y.push(x.rowIndex),w=x.rowIndex));const S=[],P=sA.selectors.columnPositions(e.state,m);return y.forEach(e=>{const{id:t,model:f}=d[e];if(o&&!o[t])return;const g=(h?.firstRowIndex||0)+c+e;if(u?.enabled){const e=v.left.length,r=m.length-v.right.length;n.calculateColSpan(t,e,r,m),v.left.length>0&&n.calculateColSpan(t,0,v.left.length,m),v.right.length>0&&n.calculateColSpan(t,m.length-v.right.length,m.length,m)}const b=n.rowsMeta.rowHasAutoHeight(t)?"auto":n.rowsMeta.getRowHeight(t);let y=!1;void 0===r.position&&(y=0===e);let E=!1;const M=e===d.length-1;l&&(s?E=M:e===p.length-1&&(E=!0));let T=a;j.current&&e>=j.current.firstRowIndex&&e<j.current.lastRowIndex&&(T=j.current);const I=e===w,O=x?.rowIndex===g,D=EA(P,T,v.left.length),F=M&&"top"===r.position,L=T.firstColumnIndex,A=T.lastColumnIndex;if(S.push(C({id:t,model:f,rowIndex:g,offsetLeft:D,columnsTotalWidth:i,baseRowHeight:b,firstColumnIndex:L,lastColumnIndex:A,focusedColumnIndex:O?x.columnIndex:void 0,isFirstVisible:y,isLastVisible:E,isVirtualFocusRow:I,showBottomBorder:F})),I)return;const N=R.get(t);N&&S.push(N),void 0===r.position&&M&&k&&S.push(k(t))}),S},rows:t.rows},Q);return f({getters:Z,setPanels:P,forceUpdateRenderContext:V,scheduleUpdateRenderContext:()=>{M.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:gA};function bA(e){const t=s.useRef(void 0),n=Mg(n=>{if(n)return t.current=e(n),MR>=19?t.current:void 0;t.current?.()});return n}function yA(e,t,n,r,o){const i=sA.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:sA.selectors.rowsMeta(e.state),columnPositions:sA.selectors.columnPositions(e.state,t.columns),rows:a,range:l,pinnedColumns:t.pinnedColumns,columns:s,hiddenCellsOriginMap:c,virtualizeColumnsWithAutoRowHeight:t.virtualizeColumnsWithAutoRowHeight}}function wA(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(xA(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:xA(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]=CA({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=SA(a,e.columnPositions,{atStart:!0,lastPosition:e.columnsTotalWidth}),o=SA(a+e.viewportInnerWidth,e.columnPositions)),r.firstColumnIndex=t,r.lastColumnIndex=o}const l=function(e,t,n){const[r,o]=CA({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]=CA({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 xA(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=pA(r-(e.range?.firstRowIndex||0),0,e.rowsMeta.positions.length);return o||e.rowsMeta.positions[i]>=t?SA(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 SA(e,t,r,Math.floor(n/2),Math.min(n,t.length))}(t,e.rowsMeta.positions,i,n)}function SA(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;if(n?.atStart){l=e-((i===t.length-1?n.lastPosition:t[i+1])-a)<a}else l=e<=a;return l?SA(e,t,n,r,i):SA(e,t,n,i+1,o)}function CA({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=SA(s,a,{atStart:!0,lastPosition:a[a.length-1]+l}),d=SA(c,a);return[pA(u,o,i),pA(d,o,i)]}function kA(e,t){return e===t||e.firstRowIndex===t.firstRowIndex&&e.lastRowIndex===t.lastRowIndex&&e.firstColumnIndex===t.firstColumnIndex&&e.lastColumnIndex===t.lastColumnIndex}function EA(e,t,n){const r=(e[t.firstColumnIndex]??0)-(e[n]??0);return Math.abs(r)}function RA(e,t,n,r,o,i){if(e)switch(t){case iA.LEFT:t=iA.RIGHT;break;case iA.RIGHT:t=iA.LEFT}switch(t){case iA.NONE:return{rowAfter:n,rowBefore:n,columnAfter:r,columnBefore:r};case iA.LEFT:return{rowAfter:0,rowBefore:0,columnAfter:0,columnBefore:i};case iA.RIGHT:return{rowAfter:0,rowBefore:0,columnAfter:i,columnBefore:0};case iA.UP:return{rowAfter:0,rowBefore:o,columnAfter:0,columnBefore:0};case iA.DOWN:return{rowAfter:o,rowBefore:0,columnAfter:0,columnBefore:0};default:throw new Error("unreachable")}}function PA(e,t){return Array.from({length:t-e}).map((t,n)=>e+n)}class MA{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 TA extends MA{static elements=["scroller","container","content","positioner","scrollbarVertical","scrollbarHorizontal"];use(e,t,n,r){const{scrollerRef:o,containerRef:i}=r,a=Mg(this.refSetter("scrollbarVertical")),l=Mg(this.refSetter("scrollbarHorizontal"));e.state.virtualization.context={scrollerRef:o,containerRef:i,scrollbarVerticalRef:a,scrollbarHorizontalRef:l}}static selectors=(()=>({containerProps:NM(vA.selectors.context,e=>({ref:e.containerRef})),scrollerProps:NM(vA.selectors.context,sA.selectors.autoHeight,sA.selectors.needsHorizontalScrollbar,(e,t,n)=>({ref:e.scrollerRef,style:{overflowX:n?void 0:"hidden",overflowY:t?"hidden":void 0},role:"presentation",tabIndex:uA?-1:void 0})),contentProps:NM(sA.selectors.contentHeight,sA.selectors.minimalContentHeight,sA.selectors.columnsTotalWidth,sA.selectors.needsHorizontalScrollbar,(e,t,n,r)=>({style:{width:r?n:"auto",flexBasis:0===e?t:e,flexShrink:0},role:"presentation"})),positionerProps:NM(vA.selectors.offsetTop,e=>({style:{transform:`translate3d(0, ${e}px, 0)`}})),scrollbarHorizontalProps:NM(vA.selectors.context,vA.selectors.scrollPosition,(e,t)=>({ref:e.scrollbarHorizontalRef,scrollPosition:t})),scrollbarVerticalProps:NM(vA.selectors.context,vA.selectors.scrollPosition,(e,t)=>({ref:e.scrollbarVerticalRef,scrollPosition:t})),scrollAreaProps:NM(vA.selectors.scrollPosition,e=>({scrollPosition:e}))}))()}class IA extends TA{use(e,t,n,r){super.use(e,t,n,r);const o=e.use(TA.selectors.containerProps),i=e.use(TA.selectors.scrollerProps),a=e.use(TA.selectors.contentProps),l=e.use(TA.selectors.positionerProps),s=e.use(TA.selectors.scrollbarVerticalProps),c=e.use(TA.selectors.scrollbarHorizontalProps),u=e.use(TA.selectors.scrollAreaProps);return{getContainerProps:()=>o,getScrollerProps:()=>i,getContentProps:()=>a,getPositionerProps:()=>l,getScrollbarVerticalProps:()=>s,getScrollbarHorizontalProps:()=>c,getScrollAreaProps:()=>u}}}NM(vA.selectors.context,sA.selectors.autoHeight,sA.selectors.needsHorizontalScrollbar,(e,t,n)=>({ref:e.mergedRef,style:{overflowX:n?void 0:"hidden",overflowY:t?"hidden":void 0,position:"relative"},role:"presentation",tabIndex:uA?-1:void 0})),NM(sA.selectors.contentHeight,e=>({style:{position:"absolute",display:"inline-block",width:"100%",height:e,top:0,left:0,zIndex:-1},role:"presentation"})),NM(vA.selectors.offsetTop,e=>({style:{height:e}}));const OA={initialize:function(e){return{}},use:function(e,t,n){return{getViewportPageSize:()=>{const n=sA.selectors.dimensions(e.state);if(!n.isReady)return 0;if(t.getRowHeight){const n=vA.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:{}};const DA={firstRowIndex:0,lastRowIndex:0},FA={spannedCells:{},hiddenCells:{},hiddenCellOriginMap:{}},LA={state:e=>e.rowSpanning,hiddenCells:e=>e.rowSpanning.caches.hiddenCells,spannedCells:e=>e.rowSpanning.caches.spannedCells,hiddenCellsOriginMap:e=>e.rowSpanning.caches.hiddenCellOriginMap},AA={initialize:function(e){return{rowSpanning:e.initialState?.rowSpanning??{caches:FA,processedRange:DA}}},use:function(e,t,n){return{getHiddenCellsOrigin:()=>LA.hiddenCellsOriginMap(e.state)}},selectors:LA};const NA={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}},$A=[sA,vA,XL,AA,OA],zA=e=>{const t=jA(e,NA),n=Dg(()=>new JM($A.map(e=>e.initialize(t)).reduce((e,t)=>Object.assign(e,t),{}))).current,r={};for(const e of $A)Object.assign(r,e.use(n,t,r));return{store:n,api:r}};function jA(e,t){const n=f({},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]=jA(e[r]??{},o)}return n}const BA=!("undefined"!=typeof window&&/jsdom|HappyDOM/.test(window.navigator.userAgent)),_A=(e,t)=>{const{disableVirtualization:n,autoHeight:r}=t;return f({},e,{virtualization:{enabled:!n&&BA,enabledForColumns:!n&&BA,enabledForRows:!n&&!r&&BA,renderContext:mA}})};const HA=nT(e=>e.virtualization);eT(HA,e=>e.enabled);const VA=eT(HA,e=>e.enabledForColumns);eT(HA,e=>e.enabledForRows);const WA=eT(HA,e=>e.renderContext),UA=tT(nT(e=>e.virtualization.renderContext.firstColumnIndex),nT(e=>e.virtualization.renderContext.lastColumnIndex),(e,t)=>({firstColumnIndex:e,lastColumnIndex:t}));function GA(e){return JSON.stringify([e.filterModel,e.sortModel,e.start,e.end])}class KA{constructor({ttl:e=3e5,getKey:t=GA}){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 qA extends Error{constructor(e){super(e.message),this.name="GridGetRowsError",this.params=e.params,this.cause=e.cause}}class YA extends Error{constructor(e){super(e.message),this.name="GridUpdateRowError",this.params=e.params,this.cause=e.cause}}const XA="calc(max(var(--DataGrid-scrollbarSize), 14px))",QA=jh("div")({position:"absolute",display:"inline-block",zIndex:60,"&:hover":{zIndex:70},"--size":XA}),ZA=jh(QA)({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}),JA=jh(QA)({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}),eN=jh(QA)({width:"var(--size)",height:"var(--size)",right:0,bottom:0,overflow:"scroll","@media print":{display:"none"}}),tN=TR(function(e,t){const n=mL(),r=rP(),o=s.useRef(!1),i=s.useRef(0),a=s.useRef(null),l=((e,t)=>{const{classes:n}=e;return wm({root:["scrollbar",`scrollbar--${t}`],content:["scrollbarContent"]},YT,n)})(r,e.position),c=pI(n,oT),u="vertical"===e.position?"height":"width",d="vertical"===e.position?"scrollTop":"scrollLeft",p="vertical"===e.position?"top":"left",f="horizontal"===e.position?c.minimumSize.width:c.minimumSize.height-c.headersTotalHeight,h=Mg(()=>{const t=a.current,n=e.scrollPosition.current;t&&n[p]!==i.current&&(i.current=n[p],o.current?o.current=!1:(o.current=!0,t[d]=e.scrollPosition.current[p]))}),m=Mg(()=>{const e=n.current.virtualScrollerRef.current,t=a.current;t&&(o.current?o.current=!1:(o.current=!0,e[d]=t[d]))});Lg(()=>{const e=n.current.virtualScrollerRef.current,t=a.current,r={passive:!0};return e.addEventListener("scroll",h,r),t.addEventListener("scroll",m,r),()=>{e.removeEventListener("scroll",h,r),t.removeEventListener("scroll",m,r)}});const g="vertical"===e.position?ZA:JA,v=s.useMemo(()=>({[u]:`${f}px`}),[u,f]);return Xp.jsx(g,{ref:Tg(t,a),className:l.root,tabIndex:-1,"aria-hidden":"true",onFocus:e=>{e.target.blur()},children:Xp.jsx("div",{className:l.content,style:v})})}),nN=jh("div",{name:"MuiDataGrid",slot:"ScrollShadow",overridesResolver:(e,t)=>[t.root,t[e.position]]})(({theme:e})=>({position:"absolute",inset:0,pointerEvents:"none",transition:bP.transition(["box-shadow"],{duration:bP.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 rN(e){const{position:t}=e,n={classes:rP().classes,position:t},r=(e=>{const{classes:t,position:n}=e;return wm({root:["scrollShadow",`scrollShadow--${n}`]},YT,t)})(n),o=s.useRef(null),i=mL(),a=pI(i,lT),l=pI(i,sT),c=pI(i,TT),u=pI(i,dO),d="vertical"===t?l&&c?.bottom?.length>0:a&&void 0!==u?.right?.length&&u?.right?.length>0,p=um(),f=s.useCallback(e=>{if(!o.current)return;const n=Math.abs(Math.round(e)),r=oT(i),a=Math.round(r.contentSize["vertical"===t?"height":"width"]-r.viewportInnerSize["vertical"===t?"height":"width"]),l="vertical"===t?c?.top?.length>0:void 0!==u?.left?.length&&u?.left?.length>0,s="vertical"===t?c?.bottom?.length>0:void 0!==u?.right?.length&&u?.right?.length>0,d=p?n<a:n>0,f=p?n>0:n<a;o.current.style.setProperty("--hasScrollStart",l&&d?"1":"0"),o.current.style.setProperty("--hasScrollEnd",s&&f?"1":"0")},[c,u,p,t,i]);return rI(i,"scrollPositionChange",e=>{f(e["vertical"===t?"top":"left"])}),rI(i,"columnResizeStop",()=>{"horizontal"===t&&f(i.current.virtualScrollerRef?.current?.scrollLeft||0)}),s.useEffect(()=>{f(("horizontal"===t?i.current.virtualScrollerRef?.current?.scrollLeft:i.current.virtualScrollerRef?.current?.scrollTop)??0)},[f,i,t]),Xp.jsx(nN,{className:r.root,ownerState:n,ref:o,style:{"--hasScrollStart":0,"--hasScrollEnd":d?"1":"0"}})}const oN=jh("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}:{}),iN=jh("div",{name:"MuiDataGrid",slot:"OverlayWrapperInner",shouldForwardProp:e=>"overlayType"!==e&&"loadingOverlayVariant"!==e})({});function aN(e){const t=lP(),n=rP(),r=pI(t,oT);let o=Math.max(r.viewportOuterSize.height-r.topContainerHeight-r.bottomContainerHeight-(r.hasScrollX?r.scrollbarSize:0),0);0===o&&(o=HT);const i=(e=>{const{classes:t}=e;return wm({root:["overlayWrapper"],inner:["overlayWrapperInner"]},YT,t)})(f({},e,{classes:n.classes}));return Xp.jsx(oN,f({className:i.root},e,{right:r.columnsTotalWidth-r.viewportOuterSize.width,children:Xp.jsx(iN,f({className:i.inner,style:{height:o,width:r.viewportOuterSize.width}},e))}))}const lN=(e,t)=>gF(e),sN=(e,t)=>pI(e,gF),cN=eT(YD,WA,gF,cO,(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)}),uN=tT(cN,cO,gF,YD,(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:f({},r,{rowIndex:o,columnIndex:i})}),dN={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,disableRowSelectionOnClick:!1,disableRowSelectionExcludeModel:!1,disableVirtualization:!1,editMode:$I.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"},pN=(e,t,n,r=!0)=>{const o=s.useRef(null),i=s.useRef(`mui-${Math.round(1e9*Math.random())}`),a=s.useCallback(()=>{o.current=e.current.registerPipeProcessor(t,i.current,n)},[e,n,t]);wL(()=>{r&&a()});const l=s.useRef(!0);s.useEffect(()=>(l.current?l.current=!1:r&&a(),()=>{o.current&&(o.current(),o.current=null)}),[a,r])},fN=(e,t,n)=>{const r=s.useRef(null),o=s.useRef(`mui-${Math.round(1e9*Math.random())}`),i=s.useCallback(()=>{r.current=e.current.registerPipeApplier(t,o.current,n)},[e,n,t]);wL(()=>{i()});const a=s.useRef(!0);s.useEffect(()=>(a.current?a.current=!1:i(),()=>{r.current&&(r.current(),r.current=null)}),[i])},hN=(e,t,n)=>{const r=aT(n),o=vT(n),i=iF(n),a=Math.min(i.enabled?i.paginationModel.pageSize:o,o);return f({},e,{rowsMeta:{currentPageTotalHeight:a*r,positions:Array.from({length:a},(e,t)=>t*r),pinnedTopRowsTotalHeight:0,pinnedBottomRowsTotalHeight:0}})},mN=eT(cO,hO,(e,t)=>{const n=e.length;return 0===n?0:eA(t[n-1]+e[n-1].computedWidth,1)}),gN=()=>PM((e,t,n,r,o)=>f({},e,{headerHeight:t,groupHeaderHeight:n,headerFilterHeight:r,headersTotalHeight:o}),{maxSize:1});function vN(){const e=um(),t=rP(),n=mL(),{listView:r}=t,o=pI(n,cO),i=pI(n,TT),a=pO(n),l=pI(n,AD),c=s.useCallback(e=>l.has(e)&&n.current.isRowSelectable(e),[l,n]),u=sN(n),d=pI(n,vO),p=pI(n,fT),h=pI(n,cT),{autoHeight:m}=t,g=r,v=pI(n,mI),b=WT(t.rowHeight,dN.rowHeight),y=Math.floor(b*v),w=Math.floor(t.columnHeaderHeight*v),x=Math.floor((t.columnGroupHeaderHeight??t.columnHeaderHeight)*v),S=Math.floor((t.headerFilterHeight??t.columnHeaderHeight)*v),C=pI(n,mN),k=lL(n,t),E=a.left.reduce((e,t)=>e+t.computedWidth,0),R=a.right.reduce((e,t)=>e+t.computedWidth,0),P=EL(n,t),M={rowHeight:y,headerHeight:w,columnsTotalWidth:C,leftPinnedWidth:E,rightPinnedWidth:R,topPinnedHeight:k,bottomPinnedHeight:0,autoHeight:m,minimalContentHeight:HT,scrollbarSize:t.scrollbarSize},T=Dg(gN).current,I=pI(n,vT),O=pI(n,iF),D=Math.min(O.enabled?O.paginationModel.pageSize:I,I),{getRowHeight:F,getEstimatedRowHeight:L,getRowSpacing:A}=t,N=t.slots.row,$=t.slotProps?.row;pI(n,uN);const z=Dg(()=>new IA({container:n.current.mainElementRef,scroller:n.current.virtualScrollerRef,scrollbarVertical:n.current.virtualScrollbarVerticalRef,scrollbarHorizontal:n.current.virtualScrollbarHorizontalRef})).current,j=zA({layout:z,dimensions:M,virtualization:{isRtl:e,rowBufferPx:t.rowBufferPx,columnBufferPx:t.columnBufferPx},colspan:{enabled:d,getColspan:s.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:u.rows,range:u.range,rowCount:D,columns:o,pinnedRows:i,pinnedColumns:a,disableHorizontalScroll:r,disableVerticalScroll:"noColumnsOverlay"===P.overlayType||"skeleton"===P.loadingOverlayVariant,getRowHeight:s.useMemo(()=>{if(F)return e=>F(f({},e,{densityFactor:v}))},[F,v]),getEstimatedRowHeight:s.useMemo(()=>L?e=>L(f({},e,{densityFactor:v})):void 0,[L,v]),getRowSpacing:s.useMemo(()=>A?e=>{const t=u.rowIdToIndexMap.get(e.id)??-1,r={isFirstVisible:0===t,isLastVisible:t===u.rows.length-1,indexRelativeToCurrentPage:t};return A(f({},e,r,{indexRelativeToCurrentPage:n.current.getRowIndexRelativeToVisibleRows(e.id)}))}:void 0,[n,A,u.rows,u.rowIdToIndexMap]),applyRowHeight:Mg((e,t)=>n.current.unstable_applyPipeProcessors("rowHeight",e,t)),virtualizeColumnsWithAutoRowHeight:t.virtualizeColumnsWithAutoRowHeight,focusedVirtualCell:Mg(()=>uN(n)),resizeThrottleMs:t.resizeThrottleMs,onResize:Mg(e=>n.current.publishEvent("resize",e)),onWheel:Mg(e=>{n.current.publishEvent("virtualScrollerWheel",{},e)}),onTouchMove:Mg(e=>{n.current.publishEvent("virtualScrollerTouchMove",{},e)}),onRenderContextChange:Mg(e=>{n.current.publishEvent("renderedRowsIntervalChange",e)}),onScrollChange:s.useCallback((e,t)=>{n.current.publishEvent("scrollPositionChange",{top:e.top,left:e.left,renderContext:t})},[n]),scrollReset:g,renderRow:s.useCallback(e=>Xp.jsx(N,f({row:e.model,rowId:e.id,index:e.rowIndex,selected:c(e.id),offsetLeft:e.offsetLeft,columnsTotalWidth:C,rowHeight:e.baseRowHeight,pinnedColumns:a,visibleColumns:o,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},$),e.id),[C,h,c,a,N,$,p,o]),renderInfiniteLoadingTrigger:s.useCallback(e=>n.current.getInfiniteLoadingTriggerElement?.({lastRowId:e}),[n])});return wL(()=>{n.current.store.state.dimensions=T(j.store.state.dimensions,w,x,S,k),n.current.store.state.rowsMeta=j.store.state.rowsMeta,n.current.store.state.virtualization=j.store.state.virtualization}),QM(j.store,sA.selectors.dimensions,(e,t)=>{t.isReady&&n.current.setState(e=>f({},e,{dimensions:T(t,w,x,S,k)}))}),QM(j.store,sA.selectors.rowsMeta,(e,t)=>{t!==n.current.state.rowsMeta&&n.current.setState(e=>f({},e,{rowsMeta:t}))}),QM(j.store,vA.selectors.store,(e,t)=>{t.renderContext!==mA&&t!==n.current.state.virtualization&&n.current.setState(e=>f({},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;fN(e,"rowHeight",a);const d={hydrateRowsMeta:a,observeRowHeight:l,rowHasAutoHeight:s,getRowHeightEntry:c,getLastMeasuredRowIndex:u};vL(e,{unstable_getRowHeight:n,unstable_setLastMeasuredRowIndex:r,unstable_storeRowHeightMeasurement:o,resetRowHeights:i},"public"),vL(e,d,"private")})(n),j}const bN=jh("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}),yN=e=>e.current.state.dimensions.rightPinnedWidth>0;function wN(e){const t=mL(),n=rP(),r=pI(t,sT),o=pI(t,lT),i=pI(t,yN),a=pI(t,hT),{overlayType:l,loadingOverlayVariant:c}=EL(t,n),u=n.slots?.[l],d={classes:n.classes,hasScrollX:o,hasPinnedRight:i,overlayType:l,loadingOverlayVariant:c},p=(e=>{const{classes:t,hasScrollX:n,hasPinnedRight:r,loadingOverlayVariant:o,overlayType:i}=e;return wm({root:["main",r&&"main--hasPinnedRight",("skeleton"===o||"noColumnsOverlay"===i)&&"main--hiddenContent"],scroller:["virtualScroller",n&&"virtualScroller--hasScrollX"]},YT,t)})(d),h=vN().api.getters,{getContainerProps:m,getScrollerProps:g,getContentProps:v,getPositionerProps:b,getScrollbarVerticalProps:y,getScrollbarHorizontalProps:w,getRows:x,getScrollAreaProps:S}=h,C=x(void 0,xT(t));return Xp.jsxs(IL,f({className:p.root},m(),{ownerState:d,children:[Xp.jsx(fL,f({scrollDirection:"left"},S())),Xp.jsx(fL,f({scrollDirection:"right"},S())),Xp.jsx(fL,f({scrollDirection:"up"},S())),Xp.jsx(fL,f({scrollDirection:"down"},S())),Xp.jsxs(bN,f({className:p.scroller},g(),{ownerState:d,children:[Xp.jsxs(DL,{children:[!n.listView&&Xp.jsx(PL,{}),Xp.jsx(n.slots.pinnedRows,{position:"top",virtualScroller:h})]}),l&&Xp.jsx(aN,{overlayType:l,loadingOverlayVariant:c,children:Xp.jsx(u,f({},n.slotProps?.[l]))}),Xp.jsx(LL,f({},v(),{children:Xp.jsxs(HL,f({role:"rowgroup"},b(),{children:[C,Xp.jsx(n.slots.detailPanels,{virtualScroller:h})]}))})),a&&Xp.jsx(BL,{rowsLength:C.length}),Xp.jsx(n.slots.bottomContainer,{children:Xp.jsx(n.slots.pinnedRows,{position:"bottom",virtualScroller:h})})]})),o&&Xp.jsxs(s.Fragment,{children:[n.pinnedColumnsSectionSeparator?.endsWith("shadow")&&Xp.jsx(rN,{position:"horizontal"}),Xp.jsx(tN,f({position:"horizontal"},w()))]}),r&&Xp.jsxs(s.Fragment,{children:[n.pinnedRowsSectionSeparator?.endsWith("shadow")&&Xp.jsx(rN,{position:"vertical"}),Xp.jsx(tN,f({position:"vertical"},y()))]}),o&&r&&Xp.jsx(eN,{"aria-hidden":"true"}),e.children]}))}function xN(){const e=rP();return e.hideFooter?null:Xp.jsx(e.slots.footer,f({},e.slotProps?.footer))}let SN;function CN(){return void 0===SN&&document.createElement("div").focus({get preventScroll(){return SN=!0,!1}}),SN}const kN=(e,t)=>{if(e)if(t){if(e===nD.LEFT)return"right";if(e===nD.RIGHT)return"left"}else{if(e===nD.LEFT)return"left";if(e===nD.RIGHT)return"right"}};function EN(e,t,n,r){const o=kN(n,t);return o&&void 0!==r?(e[o]=r,e):e}const RN=["column","row","rowId","rowNode","align","children","colIndex","width","className","style","colSpan","disableDragEvents","isNotVisible","pinnedOffset","pinnedPosition","showRightBorder","showLeftBorder","onClick","onDoubleClick","onMouseDown","onMouseUp","onMouseOver","onKeyDown","onKeyUp","onDragEnter","onDragOver"],PN=["changeReason","unstable_updateValueOnRender"];nD.LEFT,ZI.LEFT,nD.RIGHT,ZI.RIGHT,nD.NONE,nD.VIRTUAL;const MN=TR(function(e,t){const{column:n,row:r,rowId:o,rowNode:i,align:a,colIndex:l,width:c,className:u,style:p,colSpan:h,disableDragEvents:m,isNotVisible:g,pinnedOffset:v,pinnedPosition:b,showRightBorder:y,showLeftBorder:w,onClick:x,onDoubleClick:S,onMouseDown:C,onMouseUp:k,onMouseOver:E,onKeyDown:R,onKeyUp:P,onDragEnter:M,onDragOver:T}=e,I=d(e,RN),O=mL(),D=rP(),F=um(),L=n.field,A=pI(O,GL,{rowId:o,field:L}),N=jO().hooks.useCellAggregationResult(o,L),$=A?zI.Edit:zI.View,{value:z,formattedValue:j}=N||{},B=O.current.getCellParamsForRow(o,L,r,{colDef:n,cellMode:$,rowNode:i,tabIndex:pI(O,()=>{const e=JD(O);return e&&e.field===L&&e.id===o?0:-1}),hasFocus:pI(O,()=>{const e=YD(O);return e?.id===o&&e.field===L}),value:z,formattedValue:j});B.api=O.current,pI(O,()=>O.current.isCellEditable(B));const _=pI(O,()=>O.current.unstable_applyPipeProcessors("isCellSelected",!1,{id:o,field:L})),H=O.current.virtualizer.store,V=YM(H,AA.selectors.hiddenCells),W=YM(H,AA.selectors.spannedCells),{hasFocus:U,isEditable:G=!1,value:K}=B,q="view"!==$&&G||"actions"===n.type?-1:B.tabIndex,{classes:Y,getCellClassName:X}=D,Q=[pI(O,()=>O.current.unstable_applyPipeProcessors("cellClassName",[],{id:o,field:L}).filter(Boolean).join(" "))];n.cellClassName&&Q.push("function"==typeof n.cellClassName?n.cellClassName(B):n.cellClassName),"flex"===n.display&&Q.push(XT["cell--flex"]),X&&Q.push(X(B));const Z=B.formattedValue??K,J=s.useRef(null),ee=Tg(t,J),te=D.cellSelection??!1,ne=(e=>{const{align:t,showLeftBorder:n,showRightBorder:r,pinnedPosition:o,isEditable:i,isSelected:a,isSelectionMode:l,classes:s}=e;return wm({root:["cell",`cell--text${xf(t)}`,a&&"selected",i&&"cell--editable",n&&"cell--withLeftBorder",r&&"cell--withRightBorder",o===nD.LEFT&&"cell--pinnedLeft",o===nD.RIGHT&&"cell--pinnedRight",l&&!i&&"cell--selectionMode"]},YT,s)})({align:a,showLeftBorder:w,showRightBorder:y,isEditable:G,classes:D.classes,pinnedPosition:b,isSelected:_,isSelectionMode:te}),re=s.useCallback(e=>t=>{const n=O.current.getCellParams(o,L||"");O.current.publishEvent(e,n,t),k&&k(t)},[O,L,k,o]),oe=s.useCallback(e=>t=>{const n=O.current.getCellParams(o,L||"");O.current.publishEvent(e,n,t),C&&C(t)},[O,L,C,o]),ie=s.useCallback((e,t)=>n=>{if(!O.current.getRow(o))return;const r=O.current.getCellParams(o,L||"");O.current.publishEvent(e,r,n),t&&t(n)},[O,L,o]),ae=V[o]?.[l]??!1,le=W[o]?.[l]??1,se=s.useMemo(()=>{if(g)return{padding:0,opacity:0,width:0,height:0,border:0};const e=EN(f({"--width":`${c}px`},p),F,b,v),t=b===nD.LEFT,n=b===nD.RIGHT;return le>1&&(e.height=`calc(var(--height) * ${le})`,e.zIndex=10,(t||n)&&(e.zIndex=40)),e},[c,g,p,v,b,F,le]);if(Wh(()=>{if(!U||$===zI.Edit)return;const e=kg(O.current.rootElementRef.current);if(J.current&&!J.current.contains(e.activeElement)){const e=J.current.querySelector('[tabindex="0"]')||J.current;if(CN())e.focus({preventScroll:!0});else{const t=O.current.getScrollPosition();e.focus(),O.current.scroll(t)}}},[U,$,O]),ae)return Xp.jsx("div",{"data-colindex":l,role:"presentation",style:f({width:"var(--width)"},se)});let ce,ue,de=I.onFocus;if(null===A&&n.renderCell&&(ce=n.renderCell(B)),null!==A&&n.renderEditCell){const e=O.current.getRowWithUpdatedValues(o,n.field),t=d(A,PN),r=n.valueFormatter?n.valueFormatter(A.value,e,n,O):B.formattedValue,i=f({},B,{row:e,formattedValue:r},t);ce=n.renderEditCell(i),Q.push(XT["cell--editing"]),Q.push(Y?.["cell--editing"])}if(void 0===ce){const e=Z?.toString();ce=e,ue=e}const pe=m?null:{onDragEnter:ie("cellDragEnter",M),onDragOver:ie("cellDragOver",T)};return Xp.jsx("div",f({className:PR(ne.root,Q,u),role:"gridcell","data-field":L,"data-colindex":l,"aria-colindex":l+1,"aria-colspan":h,"aria-rowspan":le,style:se,title:ue,tabIndex:q,onClick:ie("cellClick",x),onDoubleClick:ie("cellDoubleClick",S),onMouseOver:ie("cellMouseOver",E),onMouseDown:oe("cellMouseDown"),onMouseUp:re("cellMouseUp"),onKeyDown:ie("cellKeyDown",R),onKeyUp:ie("cellKeyUp",P)},pe,I,{onFocus:de,ref:ee,children:ce}))}),TN=KT(MN),IN=["field","type","align","width","height","empty","style","className"],ON="1.3em",DN=[40,80],FN={number:[40,60],string:[40,80],date:[40,60],dateTime:[60,80],singleSelect:[40,80]},LN=function(e){const t=(n=e,()=>{let e=n+=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 n;return(e,n)=>e+(n-e)*t()}(12345);const AN=KT(function(e){const{field:t,type:n,align:r,width:o,height:i,empty:a=!1,style:l,className:c}=e,u=d(e,IN),p=rP(),h=(e=>{const{align:t,classes:n,empty:r}=e;return wm({root:["cell","cellSkeleton",`cell--text${t?xf(t):"Left"}`,r&&"cellEmpty"]},YT,n)})({classes:p.classes,align:r,empty:a}),m=s.useMemo(()=>{if("boolean"===n||"actions"===n)return{variant:"circular",width:ON,height:ON};const[e,t]=n?FN[n]??DN:DN;return{variant:"text",width:`${Math.round(LN(e,t))}%`,height:"1.2em"}},[n]);return Xp.jsx("div",f({"data-field":t,className:PR(h.root,c),style:f({height:i,maxWidth:o,minWidth:o},l)},u,{children:!a&&Xp.jsx(p.slots.baseSkeleton,f({},m))}))}),NN={width:3,rx:1.5,x:10.5},$N=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,zN=pg("div",{name:"MuiDataGrid",slot:"Root",overridesResolver:(e,t)=>[t.root,{[`&.${XT.autoHeight}`]:t.autoHeight},{[`&.${XT.autosizing}`]:t.autosizing},{[`&.${XT["root--densityStandard"]}`]:t["root--densityStandard"]},{[`&.${XT["root--densityComfortable"]}`]:t["root--densityComfortable"]},{[`&.${XT["root--densityCompact"]}`]:t["root--densityCompact"]},{[`&.${XT["root--disableUserSelection"]}`]:t["root--disableUserSelection"]},{[`&.${XT["root--noToolbar"]}`]:t["root--noToolbar"]},{[`&.${XT.withVerticalBorder}`]:t.withVerticalBorder},{[`& .${XT.actionsCell}`]:t.actionsCell},{[`& .${XT.booleanCell}`]:t.booleanCell},{[`& .${XT.cell}`]:t.cell},{[`& .${XT["cell--editable"]}`]:t["cell--editable"]},{[`& .${XT["cell--editing"]}`]:t["cell--editing"]},{[`& .${XT["cell--flex"]}`]:t["cell--flex"]},{[`& .${XT["cell--pinnedLeft"]}`]:t["cell--pinnedLeft"]},{[`& .${XT["cell--pinnedRight"]}`]:t["cell--pinnedRight"]},{[`& .${XT["cell--rangeBottom"]}`]:t["cell--rangeBottom"]},{[`& .${XT["cell--rangeLeft"]}`]:t["cell--rangeLeft"]},{[`& .${XT["cell--rangeRight"]}`]:t["cell--rangeRight"]},{[`& .${XT["cell--rangeTop"]}`]:t["cell--rangeTop"]},{[`& .${XT["cell--selectionMode"]}`]:t["cell--selectionMode"]},{[`& .${XT["cell--textCenter"]}`]:t["cell--textCenter"]},{[`& .${XT["cell--textLeft"]}`]:t["cell--textLeft"]},{[`& .${XT["cell--textRight"]}`]:t["cell--textRight"]},{[`& .${XT["cell--withLeftBorder"]}`]:t["cell--withLeftBorder"]},{[`& .${XT["cell--withRightBorder"]}`]:t["cell--withRightBorder"]},{[`& .${XT.cellCheckbox}`]:t.cellCheckbox},{[`& .${XT.cellEmpty}`]:t.cellEmpty},{[`& .${XT.cellOffsetLeft}`]:t.cellOffsetLeft},{[`& .${XT.cellSkeleton}`]:t.cellSkeleton},{[`& .${XT.checkboxInput}`]:t.checkboxInput},{[`& .${XT.columnHeader}`]:t.columnHeader},{[`& .${XT["columnHeader--alignCenter"]}`]:t["columnHeader--alignCenter"]},{[`& .${XT["columnHeader--alignLeft"]}`]:t["columnHeader--alignLeft"]},{[`& .${XT["columnHeader--alignRight"]}`]:t["columnHeader--alignRight"]},{[`& .${XT["columnHeader--dragging"]}`]:t["columnHeader--dragging"]},{[`& .${XT["columnHeader--emptyGroup"]}`]:t["columnHeader--emptyGroup"]},{[`& .${XT["columnHeader--filledGroup"]}`]:t["columnHeader--filledGroup"]},{[`& .${XT["columnHeader--filtered"]}`]:t["columnHeader--filtered"]},{[`& .${XT["columnHeader--last"]}`]:t["columnHeader--last"]},{[`& .${XT["columnHeader--moving"]}`]:t["columnHeader--moving"]},{[`& .${XT["columnHeader--numeric"]}`]:t["columnHeader--numeric"]},{[`& .${XT["columnHeader--pinnedLeft"]}`]:t["columnHeader--pinnedLeft"]},{[`& .${XT["columnHeader--pinnedRight"]}`]:t["columnHeader--pinnedRight"]},{[`& .${XT["columnHeader--siblingFocused"]}`]:t["columnHeader--siblingFocused"]},{[`& .${XT["columnHeader--sortable"]}`]:t["columnHeader--sortable"]},{[`& .${XT["columnHeader--sorted"]}`]:t["columnHeader--sorted"]},{[`& .${XT["columnHeader--withLeftBorder"]}`]:t["columnHeader--withLeftBorder"]},{[`& .${XT["columnHeader--withRightBorder"]}`]:t["columnHeader--withRightBorder"]},{[`& .${XT.columnHeaderCheckbox}`]:t.columnHeaderCheckbox},{[`& .${XT.columnHeaderDraggableContainer}`]:t.columnHeaderDraggableContainer},{[`& .${XT.columnHeaderTitleContainer}`]:t.columnHeaderTitleContainer},{[`& .${XT.columnHeaderTitleContainerContent}`]:t.columnHeaderTitleContainerContent},{[`& .${XT.columnSeparator}`]:t.columnSeparator},{[`& .${XT["columnSeparator--resizable"]}`]:t["columnSeparator--resizable"]},{[`& .${XT["columnSeparator--resizing"]}`]:t["columnSeparator--resizing"]},{[`& .${XT["columnSeparator--sideLeft"]}`]:t["columnSeparator--sideLeft"]},{[`& .${XT["columnSeparator--sideRight"]}`]:t["columnSeparator--sideRight"]},{[`& .${XT["container--bottom"]}`]:t["container--bottom"]},{[`& .${XT["container--top"]}`]:t["container--top"]},{[`& .${XT.detailPanelToggleCell}`]:t.detailPanelToggleCell},{[`& .${XT["detailPanelToggleCell--expanded"]}`]:t["detailPanelToggleCell--expanded"]},{[`& .${XT.editBooleanCell}`]:t.editBooleanCell},{[`& .${XT.filterIcon}`]:t.filterIcon},{[`& .${XT["filler--borderBottom"]}`]:t["filler--borderBottom"]},{[`& .${XT["filler--pinnedLeft"]}`]:t["filler--pinnedLeft"]},{[`& .${XT["filler--pinnedRight"]}`]:t["filler--pinnedRight"]},{[`& .${XT.groupingCriteriaCell}`]:t.groupingCriteriaCell},{[`& .${XT.groupingCriteriaCellLoadingContainer}`]:t.groupingCriteriaCellLoadingContainer},{[`& .${XT.groupingCriteriaCellToggle}`]:t.groupingCriteriaCellToggle},{[`& .${XT.headerFilterRow}`]:t.headerFilterRow},{[`& .${XT.iconSeparator}`]:t.iconSeparator},{[`& .${XT.menuIcon}`]:t.menuIcon},{[`& .${XT.menuIconButton}`]:t.menuIconButton},{[`& .${XT.menuList}`]:t.menuList},{[`& .${XT.menuOpen}`]:t.menuOpen},{[`& .${XT.overlayWrapperInner}`]:t.overlayWrapperInner},{[`& .${XT.pinnedRows}`]:t.pinnedRows},{[`& .${XT["pinnedRows--bottom"]}`]:t["pinnedRows--bottom"]},{[`& .${XT["pinnedRows--top"]}`]:t["pinnedRows--top"]},{[`& .${XT.row}`]:t.row},{[`& .${XT["row--borderBottom"]}`]:t["row--borderBottom"]},{[`& .${XT["row--detailPanelExpanded"]}`]:t["row--detailPanelExpanded"]},{[`& .${XT["row--dragging"]}`]:t["row--dragging"]},{[`& .${XT["row--dynamicHeight"]}`]:t["row--dynamicHeight"]},{[`& .${XT["row--editable"]}`]:t["row--editable"]},{[`& .${XT["row--editing"]}`]:t["row--editing"]},{[`& .${XT["row--firstVisible"]}`]:t["row--firstVisible"]},{[`& .${XT["row--lastVisible"]}`]:t["row--lastVisible"]},{[`& .${XT.rowReorderCell}`]:t.rowReorderCell},{[`& .${XT["rowReorderCell--draggable"]}`]:t["rowReorderCell--draggable"]},{[`& .${XT.rowReorderCellContainer}`]:t.rowReorderCellContainer},{[`& .${XT.rowReorderCellPlaceholder}`]:t.rowReorderCellPlaceholder},{[`& .${XT.rowSkeleton}`]:t.rowSkeleton},{[`& .${XT.scrollbar}`]:t.scrollbar},{[`& .${XT["scrollbar--horizontal"]}`]:t["scrollbar--horizontal"]},{[`& .${XT["scrollbar--vertical"]}`]:t["scrollbar--vertical"]},{[`& .${XT.scrollbarFiller}`]:t.scrollbarFiller},{[`& .${XT["scrollbarFiller--pinnedRight"]}`]:t["scrollbarFiller--pinnedRight"]},{[`& .${XT.sortIcon}`]:t.sortIcon},{[`& .${XT.treeDataGroupingCell}`]:t.treeDataGroupingCell},{[`& .${XT.treeDataGroupingCellLoadingContainer}`]:t.treeDataGroupingCellLoadingContainer},{[`& .${XT.treeDataGroupingCellToggle}`]:t.treeDataGroupingCellToggle},{[`& .${XT.withBorderColor}`]:t.withBorderColor},{[`& .${XT["row--beingDragged"]}`]:t["row--beingDragged"]}]})(()=>{const e=pI(mL(),$N),t=bP.colors.background.base,n=bP.header.background.base,r=bP.cell.background.pinned,o=function(e){return jN(e,1)}(bP.colors.interactive.hover),i=bP.colors.interactive.hoverOpacity,a=bP.colors.interactive.selected,l=bP.colors.interactive.selectedOpacity,s=a,c=`calc(${l} + ${i})`,u=BN(t,o,i),d=BN(t,a,l),p=BN(t,s,c),f=BN(r,o,i),h=BN(r,a,l),m=BN(r,s,c),g=e=>({[`& .${XT["cell--pinnedLeft"]}, & .${XT["cell--pinnedRight"]}`]:{backgroundColor:e,"&.Mui-selected":{backgroundColor:BN(e,d,l),"&:hover":{backgroundColor:BN(e,p,c)}}}}),v=g(f),b=g(h),y=g(m),w={backgroundColor:d,"&:hover":{backgroundColor:p,"@media (hover: none)":{backgroundColor:d}}};return{"--unstable_DataGrid-radius":bP.radius.base,"--unstable_DataGrid-headWeight":bP.typography.fontWeight.medium,"--DataGrid-rowBorderColor":bP.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:bP.colors.border.base,borderRadius:"var(--unstable_DataGrid-radius)",backgroundColor:bP.colors.background.base,color:bP.colors.foreground.base,font:bP.typography.font.body,outline:"none",height:"100%",display:"flex",minWidth:0,minHeight:0,flexDirection:"column",overflow:"hidden",overflowAnchor:"none",transform:"translate(0, 0)",[`.${XT.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)"},[`&.${XT.autoHeight}`]:{height:"auto"},[`&.${XT.autosizing}`]:{[`& .${XT.columnHeaderTitleContainerContent} > *`]:{overflow:"visible !important"},"@media (hover: hover)":{[`& .${XT.menuIcon}`]:{width:"0 !important",visibility:"hidden !important"}},[`& .${XT.cell}`]:{overflow:"visible !important",whiteSpace:"nowrap",minWidth:"max-content !important",maxWidth:"max-content !important"},[`& .${XT.groupingCriteriaCell}`]:{width:"unset"},[`& .${XT.treeDataGroupingCell}`]:{width:"unset"}},[`&.${XT.withSidePanel}`]:{flexDirection:"row"},[`& .${XT.mainContent}`]:{display:"flex",flexDirection:"column",overflow:"hidden",flex:1},[`& .${XT.columnHeader}, & .${XT.cell}`]:{WebkitTapHighlightColor:"transparent",padding:"0 10px",boxSizing:"border-box"},[`& .${XT.columnHeader}:focus-within, & .${XT.cell}:focus-within`]:{outline:`solid ${jN(bP.colors.interactive.focus,.5)} 1px`,outlineOffset:-1},[`& .${XT.columnHeader}:focus, & .${XT.cell}:focus`]:{outline:`solid ${bP.colors.interactive.focus} 1px`,outlineOffset:-1},[`& .${XT.columnHeader}:focus,\n & .${XT["columnHeader--withLeftBorder"]},\n & .${XT["columnHeader--withRightBorder"]},\n & .${XT["columnHeader--siblingFocused"]}\n `]:{[`& .${XT.columnSeparator}`]:{opacity:0},"@media (hover: none)":{[`& .${XT["columnSeparator--resizable"]}`]:{opacity:1}},[`& .${XT["columnSeparator--resizable"]}:hover`]:{opacity:1}},[`&.${XT["root--noToolbar"]} [aria-rowindex="1"] [aria-colindex="1"]`]:{borderTopLeftRadius:"calc(var(--unstable_DataGrid-radius) - 1px)"},[`&.${XT["root--noToolbar"]} [aria-rowindex="1"] .${XT["columnHeader--last"]}`]:{borderTopRightRadius:e?"calc(var(--unstable_DataGrid-radius) - 1px)":void 0},[`& .${XT.columnHeaderCheckbox}, & .${XT.cellCheckbox}`]:{padding:0,justifyContent:"center",alignItems:"center"},[`& .${XT.columnHeader}`]:{position:"relative",display:"flex",alignItems:"center",backgroundColor:n},[`& .${XT.columnHeader} .${XT.sortButton}`]:{backgroundColor:bP.header.background.base},[`& .${XT["columnHeader--filter"]}`]:{paddingTop:8,paddingBottom:8,paddingRight:5,minHeight:"min-content",overflow:"hidden"},[`& .${XT["virtualScroller--hasScrollX"]} .${XT["columnHeader--last"]}`]:{overflow:"hidden"},[`& .${XT["pivotPanelField--sorted"]} .${XT.iconButtonContainer},\n & .${XT["columnHeader--sorted"]} .${XT.iconButtonContainer},\n & .${XT["columnHeader--filtered"]} .${XT.iconButtonContainer}`]:{visibility:"visible",width:"auto"},[`& .${XT.pivotPanelField}:not(.${XT["pivotPanelField--sorted"]}) .${XT.sortButton},\n & .${XT.columnHeader}:not(.${XT["columnHeader--sorted"]}) .${XT.sortButton}`]:{opacity:0,transition:bP.transition(["opacity"],{duration:bP.transitions.duration.short})},[`& .${XT.columnHeaderTitleContainer}`]:{display:"flex",alignItems:"center",gap:bP.spacing(.25),minWidth:0,flex:1,whiteSpace:"nowrap",overflow:"hidden"},[`& .${XT.columnHeaderTitleContainerContent}`]:{overflow:"hidden",display:"flex",alignItems:"center"},[`& .${XT["columnHeader--filledGroup"]} .${XT.columnHeaderTitleContainer}`]:{borderBottomWidth:"1px",borderBottomStyle:"solid",boxSizing:"border-box"},[`& .${XT.sortIcon}, & .${XT.filterIcon}`]:{fontSize:"inherit"},[`& .${XT["columnHeader--sortable"]}`]:{cursor:"pointer"},[`& .${XT["columnHeader--alignCenter"]} .${XT.columnHeaderTitleContainer}`]:{justifyContent:"center"},[`& .${XT["columnHeader--alignRight"]} .${XT.columnHeaderDraggableContainer}, & .${XT["columnHeader--alignRight"]} .${XT.columnHeaderTitleContainer}`]:{flexDirection:"row-reverse"},[`& .${XT["columnHeader--alignCenter"]} .${XT.menuIcon}`]:{marginLeft:"auto"},[`& .${XT["columnHeader--alignRight"]} .${XT.menuIcon}`]:{marginRight:"auto",marginLeft:-5},[`& .${XT["columnHeader--moving"]}`]:{backgroundColor:u},[`& .${XT["columnHeader--pinnedLeft"]}, & .${XT["columnHeader--pinnedRight"]}`]:{position:"sticky",zIndex:40,background:bP.header.background.base},[`& .${XT.columnSeparator}`]:{position:"absolute",overflow:"hidden",zIndex:30,display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",maxWidth:10,color:bP.colors.border.base},[`& .${XT.columnHeaders}`]:{width:"var(--DataGrid-rowWidth)",backgroundColor:n},"@media (hover: hover)":{[`& .${XT.columnHeader}:hover`]:{[`& .${XT.menuIcon}`]:{width:"auto",visibility:"visible"},[`& .${XT.iconButtonContainer}`]:{visibility:"visible",width:"auto"}},[`& .${XT.columnHeader}:not(.${XT["columnHeader--sorted"]}):hover .${XT.sortButton},\n & .${XT.pivotPanelField}:not(.${XT["pivotPanelField--sorted"]}):hover .${XT.sortButton},\n & .${XT.pivotPanelField}:not(.${XT["pivotPanelField--sorted"]}) .${XT.sortButton}:focus-visible`]:{opacity:1},[`& .${XT.columnHeader}:not(.${XT["columnHeader--sorted"]}):hover .${XT.sortButton} > *,\n & .${XT.pivotPanelField}:not(.${XT["pivotPanelField--sorted"]}):hover .${XT.sortButton} > *,\n & .${XT.pivotPanelField}:not(.${XT["pivotPanelField--sorted"]}) .${XT.sortButton}:focus-visible > *`]:{opacity:.78},[`& .${XT.pivotPanelFieldActionContainer} button:hover`]:{backgroundColor:bP.colors.background.base}},"@media (hover: none)":{[`& .${XT.columnHeader} .${XT.menuIcon}`]:{width:"auto",visibility:"visible"},[`& .${XT.columnHeader}:focus,\n & .${XT["columnHeader--siblingFocused"]}`]:{[`.${XT["columnSeparator--resizable"]}`]:{color:bP.colors.foreground.accent}},[`& .${XT.pivotPanelField}:not(.${XT["pivotPanelField--sorted"]}) .${XT.sortButton}`]:{opacity:.78}},[`& .${XT["columnHeader--withLeftBorder"]} .${XT["columnSeparator--sideLeft"]}:not(.${XT["columnSeparator--resizable"]}), & .${XT["columnHeader--withRightBorder"]} .${XT["columnSeparator--sideRight"]}:not(.${XT["columnSeparator--resizable"]})`]:{display:"none"},[`& .${XT["columnSeparator--sideLeft"]}`]:{left:-5},[`& .${XT["columnSeparator--sideRight"]}`]:{right:-5},[`& .${XT["columnHeader--withRightBorder"]} .${XT["columnSeparator--sideLeft"]}`]:{left:-5.5},[`& .${XT["columnHeader--withRightBorder"]} .${XT["columnSeparator--sideRight"]}`]:{right:-5.5},[`& .${XT["columnSeparator--resizable"]}`]:{cursor:"col-resize",touchAction:"none",[`&.${XT["columnSeparator--resizing"]}`]:{color:bP.colors.foreground.accent},"@media (hover: none)":{[`& .${XT.iconSeparator} rect`]:NN},"@media (hover: hover)":{"&:hover":{color:bP.colors.foreground.accent,[`& .${XT.iconSeparator} rect`]:NN}},"& svg":{pointerEvents:"none"}},[`& .${XT.iconSeparator}`]:{color:"inherit",transition:bP.transition(["color","width"],{duration:bP.transitions.duration.short})},[`& .${XT.menuIcon}`]:{width:0,visibility:"hidden",fontSize:20,marginRight:-5,display:"flex",alignItems:"center"},[`.${XT.menuOpen}`]:{visibility:"visible",width:"auto"},[`& .${XT.headerFilterRow}`]:{[`& .${XT.columnHeader}, & .${XT.scrollbarFiller}`]:{boxSizing:"border-box",borderBottom:"1px solid var(--DataGrid-rowBorderColor)"}},[`& .${XT["row--borderBottom"]} .${XT.columnHeader},\n & .${XT["row--borderBottom"]} .${XT.filler},\n & .${XT["row--borderBottom"]} .${XT.scrollbarFiller}`]:{borderBottom:"1px solid var(--DataGrid-rowBorderColor)"},[`& .${XT["row--borderBottom"]} .${XT.cell}`]:{borderBottom:"1px solid var(--rowBorderColor)"},[`.${XT.row}`]:{display:"flex",width:"var(--DataGrid-rowWidth)",breakInside:"avoid","--rowBorderColor":"var(--DataGrid-rowBorderColor)",[`&.${XT["row--firstVisible"]}`]:{"--rowBorderColor":"transparent"},"&:hover":{backgroundColor:u,"@media (hover: none)":{backgroundColor:"transparent"}},[`&.${XT.rowSkeleton}:hover`]:{backgroundColor:"transparent"},"&.Mui-selected":w,position:"relative"},[`& .${XT.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},[`& .${XT["virtualScrollerContent--overflowed"]} .${XT["row--lastVisible"]} .${XT.cell}`]:{borderTopColor:"transparent"},[`& .${XT.pinnedRows} .${XT.row}, .${XT.aggregationRowOverlayWrapper} .${XT.row}`]:{backgroundColor:r,"&:hover":{backgroundColor:f}},[`& .${XT["pinnedRows--top"]} :first-of-type`]:{[`& .${XT.cell}, .${XT.scrollbarFiller}`]:{borderTop:"none"}},[`&.${XT["root--disableUserSelection"]}`]:{userSelect:"none"},[`& .${XT["row--dynamicHeight"]} > .${XT.cell}`]:{whiteSpace:"initial",lineHeight:"inherit"},[`& .${XT.cellEmpty}`]:{flex:1,padding:0,height:"unset"},[`& .${XT.cell}.${XT["cell--selectionMode"]}`]:{cursor:"default"},[`& .${XT.cell}.${XT["cell--editing"]}`]:{padding:1,display:"flex",boxShadow:bP.shadows.base,backgroundColor:bP.colors.background.overlay,"&:focus-within":{outline:`1px solid ${bP.colors.interactive.focus}`,outlineOffset:-1}},[`& .${XT["cell--editing"]}`]:{"& .MuiInputBase-root":{height:"100%"}},[`& .${XT["row--editing"]}`]:{boxShadow:bP.shadows.base},[`& .${XT["row--editing"]} .${XT.cell}`]:{boxShadow:"none",backgroundColor:bP.colors.background.overlay},[`& .${XT.editBooleanCell}`]:{display:"flex",height:"100%",width:"100%",alignItems:"center",justifyContent:"center"},[`& .${XT.booleanCell}[data-value="true"]`]:{color:bP.colors.foreground.muted},[`& .${XT.booleanCell}[data-value="false"]`]:{color:bP.colors.foreground.disabled},[`& .${XT.actionsCell}`]:{display:"inline-flex",alignItems:"center",gridGap:bP.spacing(1)},[`& .${XT.rowReorderCell}`]:{display:"inline-flex",flex:1,alignItems:"center",justifyContent:"center",opacity:bP.colors.interactive.disabledOpacity},[`& .${XT["rowReorderCell--draggable"]}`]:{cursor:"grab",opacity:1},[`& .${XT.rowReorderCellContainer}`]:{padding:0,display:"flex",alignItems:"stretch"},[`.${XT.withBorderColor}`]:{borderColor:bP.colors.border.base},[`& .${XT["cell--withLeftBorder"]}, & .${XT["columnHeader--withLeftBorder"]}`]:{borderLeftColor:"var(--DataGrid-rowBorderColor)",borderLeftWidth:"1px",borderLeftStyle:"solid"},[`& .${XT["cell--withRightBorder"]}, & .${XT["columnHeader--withRightBorder"]}`]:{borderRightColor:"var(--DataGrid-rowBorderColor)",borderRightWidth:"1px",borderRightStyle:"solid"},[`& .${XT["cell--flex"]}`]:{display:"flex",alignItems:"center",lineHeight:"inherit"},[`& .${XT["cell--textLeft"]}`]:{textAlign:"left",justifyContent:"flex-start"},[`& .${XT["cell--textRight"]}`]:{textAlign:"right",justifyContent:"flex-end"},[`& .${XT["cell--textCenter"]}`]:{textAlign:"center",justifyContent:"center"},[`& .${XT["cell--pinnedLeft"]}, & .${XT["cell--pinnedRight"]}`]:{position:"sticky",zIndex:30,background:bP.cell.background.pinned,"&.Mui-selected":{backgroundColor:h}},[`& .${XT.row}`]:{"&:hover":v,"&.Mui-selected":b,"&.Mui-selected:hover":y},[`& .${XT.cellOffsetLeft}`]:{flex:"0 0 auto",display:"inline-block"},[`& .${XT.cellSkeleton}`]:{flex:"0 0 auto",height:"100%",display:"inline-flex",alignItems:"center"},[`& .${XT.columnHeaderDraggableContainer}`]:{display:"flex",width:"100%",height:"100%"},[`& .${XT.rowReorderCellPlaceholder}`]:{display:"none"},[`& .${XT["columnHeader--dragging"]}`]:{background:bP.colors.background.overlay,padding:"0 12px",borderRadius:"var(--unstable_DataGrid-radius)",opacity:bP.colors.interactive.disabledOpacity},[`& .${XT["row--dragging"]}`]:{background:bP.colors.background.overlay,padding:"0 12px",borderRadius:"var(--unstable_DataGrid-radius)",border:"1px solid var(--DataGrid-rowBorderColor)",color:bP.colors.foreground.base,transform:"translateZ(0)",[`& .${XT.rowReorderCellPlaceholder}`]:{padding:"0 6px",display:"flex"}},[`& .${XT.treeDataGroupingCell}`]:{display:"flex",alignItems:"center",width:"100%"},[`& .${XT.treeDataGroupingCellToggle}`]:{flex:"0 0 28px",alignSelf:"stretch",marginRight:bP.spacing(2)},[`& .${XT.treeDataGroupingCellLoadingContainer}, .${XT.groupingCriteriaCellLoadingContainer}`]:{display:"flex",alignItems:"center",justifyContent:"center",height:"100%"},[`& .${XT.groupingCriteriaCell}`]:{display:"flex",alignItems:"center",width:"100%"},[`& .${XT.groupingCriteriaCellToggle}`]:{flex:"0 0 28px",alignSelf:"stretch",marginRight:bP.spacing(2)},[`& .${XT.columnHeaders} .${XT.scrollbarFiller}`]:{backgroundColor:n},[`.${XT.scrollbarFiller}`]:{minWidth:"calc(var(--DataGrid-hasScrollY) * var(--DataGrid-scrollbarSize))",alignSelf:"stretch",backgroundColor:n,[`&.${XT["scrollbarFiller--pinnedRight"]}`]:{position:"sticky",zIndex:40,right:0}},[`& .${XT.filler}`]:{flex:"1 0 auto"},[`& .${XT["filler--borderBottom"]}`]:{borderBottom:"1px solid var(--DataGrid-rowBorderColor)"},[`& .${XT.columnHeaders} .${XT.filler}`]:{backgroundColor:n},[`& .${XT["main--hiddenContent"]}`]:{[`& .${XT.virtualScrollerContent}`]:{position:"fixed",visibility:"hidden"},[`& .${XT.pinnedRows}`]:{display:"none"}},[`& .${XT["row--beingDragged"]}`]:{color:bP.colors.foreground.disabled,"&:hover":{backgroundColor:"transparent"}}}});function jN(e,t){return`rgba(from ${e} r g b / ${t})`}function BN(e,t,n){return`color-mix(in srgb,${e}, ${t} calc(${n} * 100%))`}const _N=()=>()=>{},HN=()=>!1,VN=()=>!0,WN=s.createContext(void 0);function UN(){const e=s.useContext(WN);if(void 0===e)throw new Error("MUI X: Missing context.");return e}function GN({children:e}){const t=s.useRef(null),n=s.useRef(null),r=s.useRef(null),o=s.useMemo(()=>({columnsPanelTriggerRef:t,filterPanelTriggerRef:n,aiAssistantPanelTriggerRef:r}),[]);return Xp.jsx(WN.Provider,{value:o,children:e})}function KN(){const e=lP(),t=pI(e,aO),n=rP(),r=pI(e,KL),{columnsPanelTriggerRef:o,filterPanelTriggerRef:i,aiAssistantPanelTriggerRef:a}=UN(),l=e.current.unstable_applyPipeProcessors("preferencePanel",null,r.openedPanelValue??YL.filters);let s=null;switch(r.openedPanelValue){case YL.filters:s=i.current;break;case YL.columns:s=o.current;break;case YL.aiAssistant:s=a.current}return Xp.jsx(n.slots.panel,f({id:r.panelId,open:t.length>0&&r.open,"aria-labelledby":r.labelId,target:s,onClose:()=>e.current.hidePreferences()},n.slotProps?.panel,{children:l}))}function qN(){const e=rP();return Xp.jsxs(s.Fragment,{children:[Xp.jsx(KN,{}),e.showToolbar&&Xp.jsx(e.slots.toolbar,f({},e.slotProps?.toolbar))]})}const YN=["className","children","sidePanel"],XN=TR(function(e,t){const n=rP(),{className:r,children:o,sidePanel:i}=e,a=d(e,YN),l=mL(),c=pI(l,hI),u=l.current.rootElementRef,p=s.useCallback(e=>{null!==e&&l.current.publishEvent("rootMount",e)},[l]),h=Tg(u,t,p),m=n,g=((e,t)=>{const{autoHeight:n,classes:r,showCellVerticalBorder:o}=e;return wm({root:["root",n&&"autoHeight",`root--density${xf(t)}`,null===e.slots.toolbar&&"root--noToolbar","withBorderColor",o&&"withVerticalBorder"]},YT,r)})(m,c),v=s.useContext(BO);return WM.useSyncExternalStore(_N,HN,VN)?null:Xp.jsxs(zN,f({className:PR(g.root,r,v.className,i&&XT.withSidePanel),ownerState:m},a,{ref:h,children:[Xp.jsxs("div",{className:XT.mainContent,role:"presentation",children:[Xp.jsx(qN,{}),Xp.jsx(wN,{children:o}),Xp.jsx(xN,{})]}),i,v.tag]}))}),QN=KT(XN),ZN=["className"],JN=jh("div",{name:"MuiDataGrid",slot:"FooterContainer"})({display:"flex",justifyContent:"space-between",alignItems:"center",minHeight:52,borderTop:"1px solid"}),e$=TR(function(e,t){const{className:n}=e,r=d(e,ZN),o=rP(),i=(e=>{const{classes:t}=e;return wm({root:["footerContainer","withBorderColor"]},YT,t)})(o);return Xp.jsx(JN,f({className:PR(i.root,n),ownerState:o},r,{ref:t}))}),t$=["className"],n$=jh("div",{name:"MuiDataGrid",slot:"Overlay"})({width:"100%",height:"100%",display:"flex",gap:bP.spacing(1),flexDirection:"column",alignSelf:"center",alignItems:"center",justifyContent:"center",textAlign:"center",textWrap:"balance",backgroundColor:bP.colors.background.backdrop}),r$=TR(function(e,t){const{className:n}=e,r=d(e,t$),o=rP(),i=(e=>{const{classes:t}=e;return wm({root:["overlay"]},YT,t)})(o);return Xp.jsx(n$,f({className:PR(i.root,n),ownerState:o},r,{ref:t}))});function o$(e,t,n,r={}){return"function"==typeof t?t(n,r):t?(t.props.className&&(n.className=function(e,t){if(!e||!t)return e||t;return`${e} ${t}`}(t.props.className,n.className)),(t.props.style||n.style)&&(n.style=f({},n.style,t.props.style)),s.cloneElement(t,n)):s.createElement(e,n)}const i$=s.createContext(void 0);function a$(e,t){if(!e.ref.current||!t.ref.current)return 0;const n=e.ref.current.compareDocumentPosition(t.ref.current);return n?n&Node.DOCUMENT_POSITION_FOLLOWING||n&Node.DOCUMENT_POSITION_CONTAINED_BY?-1:n&Node.DOCUMENT_POSITION_PRECEDING||n&Node.DOCUMENT_POSITION_CONTAINS?1:0:0}const l$=["render","className"],s$=jh("div",{name:"MuiDataGrid",slot:"Toolbar"})({flex:"0 1 1px",display:"flex",alignItems:"center",justifyContent:"end",gap:bP.spacing(.25),padding:bP.spacing(.75),minHeight:52,boxSizing:"border-box",borderBottom:`1px solid ${bP.colors.border.base}`}),c$=TR(function(e,t){const{render:n,className:r}=e,o=d(e,l$),i=rP(),a=(e=>{const{classes:t}=e;return wm({root:["toolbar"]},YT,t)})(i),[l,c]=s.useState(null),[u,p]=s.useState([]),h=s.useCallback(()=>u.sort(a$),[u]),m=s.useCallback((e,t,n=!0)=>{let r=e;const o=h(),i=o.length;for(let e=0;e<i;e+=1){if(r+=t,r>=i){if(!n)return-1;r=0}else if(r<0){if(!n)return-1;r=i-1}if(!o[r].ref.current?.disabled&&"true"!==o[r].ref.current?.ariaDisabled)return r}return-1},[h]),g=s.useCallback((e,t)=>{p(n=>[...n,{id:e,ref:t}])},[]),v=s.useCallback(e=>{p(t=>t.filter(t=>t.id!==e))},[]),b=s.useCallback(e=>{if(!l)return;const t=h(),n=t.findIndex(e=>e.id===l);let r=-1;if("ArrowRight"===e.key?(e.preventDefault(),r=m(n,1)):"ArrowLeft"===e.key?(e.preventDefault(),r=m(n,-1)):"Home"===e.key?(e.preventDefault(),r=m(-1,1,!1)):"End"===e.key&&(e.preventDefault(),r=m(t.length,-1,!1)),r>=0&&r<t.length){const e=t[r];c(e.id),e.ref.current?.focus()}},[h,l,m]),y=s.useCallback(e=>{l!==e&&c(e)},[l,c]),w=s.useCallback(e=>{const t=h(),n=t.findIndex(t=>t.id===e),r=m(n,1);if(r>=0&&r<t.length){const e=t[r];c(e.id),e.ref.current?.focus()}},[h,m]);s.useEffect(()=>{const e=h();if(e.length>0){if(!l)return void c(e[0].id);const t=e.findIndex(e=>e.id===l);if(e[t]){if(-1===t){const n=e[t];n&&(c(n.id),n.ref.current?.focus())}}else{const t=e[e.length-1];t&&(c(t.id),t.ref.current?.focus())}}},[h,m]);const x=s.useMemo(()=>({focusableItemId:l,registerItem:g,unregisterItem:v,onItemKeyDown:b,onItemFocus:y,onItemDisabled:w}),[l,g,v,b,y,w]),S=o$(s$,n,f({role:"toolbar","aria-orientation":"horizontal","aria-label":i.label||void 0,className:PR(a.root,r)},o,{ref:t}));return Xp.jsx(i$.Provider,{value:x,children:S})}),u$=["render","onKeyDown","onFocus","disabled","aria-disabled"],d$=TR(function(e,t){const{render:n,onKeyDown:r,onFocus:o,disabled:i,"aria-disabled":a}=e,l=d(e,u$),c=mm(),u=rP(),p=s.useRef(null),h=Tg(p,t),{focusableItemId:m,registerItem:g,unregisterItem:v,onItemKeyDown:b,onItemFocus:y,onItemDisabled:w}=function(){const e=s.useContext(i$);if(void 0===e)throw new Error("MUI X: Missing context. Toolbar subcomponents must be placed within a <Toolbar /> component.");return e}();s.useEffect(()=>(g(c,p),()=>v(c)),[]);const x=s.useRef(i);s.useEffect(()=>{x.current!==i&&!0===i&&w(c,i),x.current=i},[i,c,w]);const S=s.useRef(a);s.useEffect(()=>{S.current!==a&&!0===a&&w(c,!0),S.current=a},[a,c,w]);const C=o$(u.slots.baseIconButton,n,f({},u.slotProps?.baseIconButton,{tabIndex:m===c?0:-1},l,{disabled:i,"aria-disabled":a,onKeyDown:e=>{b(e),r?.(e)},onFocus:e=>{y(c),o?.(e)},ref:h}));return Xp.jsx(s.Fragment,{children:C})}),p$=s.memo(e=>{const{colDef:t,open:n,columnMenuId:r,columnMenuButtonId:o,iconButtonRef:i}=e,a=lP(),l=rP(),c=(e=>{const{classes:t,open:n}=e;return wm({root:["menuIcon",n&&"menuOpen"],button:["menuIconButton"]},YT,t)})(f({},e,{classes:l.classes})),u=s.useCallback(e=>{e.preventDefault(),e.stopPropagation(),a.current.toggleColumnMenu(t.field)},[a,t.field]),d=t.headerName??t.field;return Xp.jsx("div",{className:c.root,children:Xp.jsx(l.slots.baseTooltip,f({title:a.current.getLocaleText("columnMenuLabel"),enterDelay:1e3},l.slotProps?.baseTooltip,{children:Xp.jsx(l.slots.baseIconButton,f({ref:i,tabIndex:-1,className:c.button,"aria-label":a.current.getLocaleText("columnMenuAriaLabel")(d),size:"small",onClick:u,"aria-haspopup":"menu","aria-expanded":n,"aria-controls":n?r:void 0,id:o},l.slotProps?.baseIconButton,{children:Xp.jsx(l.slots.columnMenuIcon,{fontSize:"inherit"})}))}))})});function f$({columnMenuId:e,columnMenuButtonId:t,ContentComponent:n,contentComponentProps:r,field:o,open:i,target:a,onExited:l}){const s=lP(),c=s.current.getColumn(o),u=Mg(e=>{e&&(e.stopPropagation(),a?.contains(e.target))||s.current.hideColumnMenu()});return a&&c?Xp.jsx(UO,{position:"bottom-"+("right"===c.align?"start":"end"),open:i,target:a,onClose:u,onExited:l,children:Xp.jsx(n,f({colDef:c,hideMenu:u,open:i,id:e,labelledby:t},r))}):null}function h$(e,t){return e.closest(`.${t}`)}function m$(e){return e.replace(/["\\]/g,"\\$&")}function g$(e){return`.${XT.row}[data-id="${m$(String(e))}"]`}function v$(e){return 1===e.target.nodeType&&!e.currentTarget.contains(e.target)}function b$(e,t){return e.rootElementRef.current.querySelector(`.${XT[t]}`)}const y$=({api:e,colIndex:t,position:n,filterFn:r})=>{if(null===t)return[];const o=[];return x$(e).forEach(e=>{e.getAttribute("data-id")&&e.querySelectorAll(`.${XT["left"===n?"cell--pinnedLeft":"cell--pinnedRight"]}`).forEach(e=>{const t=S$(e);null!==t&&r(t)&&o.push(e)})}),o};const w$=({api:e,colIndex:t,position:n,filterFn:r})=>{if(!e.columnHeadersContainerRef?.current)return[];if(null===t)return[];const o=[];return e.columnHeadersContainerRef.current.querySelectorAll(`.${XT["left"===n?"columnHeader--pinnedLeft":"columnHeader--pinnedRight"]}`).forEach(e=>{const t=S$(e);null!==t&&r(t,e)&&o.push(e)}),o};function x$(e){return e.virtualScrollerRef.current.querySelectorAll(`:scope > div > div > .${XT.row}`)}function S$(e){const t=e.getAttribute("aria-colindex");return t?Number(t)-1:null}const C$=["className","aria-label"],k$=jh("div",{name:"MuiDataGrid",slot:"ColumnHeaderTitle"})({textOverflow:"ellipsis",overflow:"hidden",whiteSpace:"nowrap",fontWeight:"var(--unstable_DataGrid-headWeight)",lineHeight:"normal"}),E$=TR(function(e,t){const{className:n}=e,r=d(e,C$),o=rP(),i=(e=>{const{classes:t}=e;return wm({root:["columnHeaderTitle"]},YT,t)})(o);return Xp.jsx(k$,f({className:PR(i.root,n),ownerState:o},r,{ref:t}))});function R$(e){const{label:t,description:n}=e,r=rP(),o=s.useRef(null),[i,a]=s.useState(""),l=s.useCallback(()=>{if(!n&&o?.current){const n=(e=o.current).scrollHeight>e.clientHeight||e.scrollWidth>e.clientWidth;a(n?t:"")}var e},[n,t]);return Xp.jsx(r.slots.baseTooltip,f({title:n||i},r.slotProps?.baseTooltip,{children:Xp.jsx(E$,{onMouseOver:l,ref:o,children:t})}))}const P$=["resizable","resizing","height","side"];var M$=function(e){return e.Left="left",e.Right="right",e}(M$||{});function T$(e){const{height:t,side:n=M$.Right}=e,r=d(e,P$),o=rP(),i=(e=>{const{resizable:t,resizing:n,classes:r,side:o}=e;return wm({root:["columnSeparator",t&&"columnSeparator--resizable",n&&"columnSeparator--resizing",o&&`columnSeparator--side${xf(o)}`],icon:["iconSeparator"]},YT,r)})(f({},e,{side:n,classes:o.classes})),a=s.useCallback(e=>{e.preventDefault(),e.stopPropagation()},[]);return Xp.jsx("div",f({className:i.root,style:{minHeight:t}},r,{onClick:a,children:Xp.jsx(o.slots.columnResizeIcon,{className:i.icon})}))}const I$=s.memo(T$),O$=["classes","columnMenuOpen","colIndex","height","isResizing","sortDirection","hasFocus","tabIndex","separatorSide","isDraggable","headerComponent","description","elementId","width","columnMenuIconButton","columnMenu","columnTitleIconButtons","headerClassName","label","resizable","draggableContainerProps","columnHeaderSeparatorProps","style"],D$=TR(function(e,t){const{classes:n,colIndex:r,height:o,isResizing:i,sortDirection:a,tabIndex:l,separatorSide:c,isDraggable:u,headerComponent:p,description:h,width:m,columnMenuIconButton:g=null,columnMenu:v=null,columnTitleIconButtons:b=null,headerClassName:y,label:w,resizable:x,draggableContainerProps:S,columnHeaderSeparatorProps:C,style:k}=e,E=d(e,O$),R=rP(),P=Tg(s.useRef(null),t);let M="none";return null!=a&&(M="asc"===a?"ascending":"descending"),Xp.jsxs("div",f({className:PR(n.root,y),style:f({},k,{width:m}),role:"columnheader",tabIndex:l,"aria-colindex":r+1,"aria-sort":M},E,{ref:P,children:[Xp.jsxs("div",f({className:n.draggableContainer,draggable:u,role:"presentation"},S,{children:[Xp.jsxs("div",{className:n.titleContainer,role:"presentation",children:[Xp.jsx("div",{className:n.titleContainerContent,children:void 0!==p?p:Xp.jsx(R$,{label:w,description:h,columnWidth:m})}),b]}),g]})),Xp.jsx(I$,f({resizable:!R.disableColumnResize&&!!x,resizing:i,height:o,side:c},C)),v]}))});const F$=KT(function(e){const{colDef:t,columnMenuOpen:n,colIndex:r,headerHeight:o,isResizing:i,isLast:a,sortDirection:l,sortIndex:c,filterItemsCounter:u,hasFocus:d,tabIndex:p,disableReorder:h,separatorSide:m,showLeftBorder:g,showRightBorder:v,pinnedPosition:b,pinnedOffset:y}=e,w=mL(),x=rP(),S=um(),C=s.useRef(null),k=mm(),E=mm(),R=s.useRef(null),[P,M]=s.useState(n),T=!x.disableColumnReorder&&!h&&!t.disableReorder;let I;t.renderHeader&&(I=t.renderHeader(w.current.getColumnHeaderParams(t.field)));const O=(e=>{const{disableColumnSorting:t}=rP(),{colDef:n,classes:r,isDragging:o,sortDirection:i,showRightBorder:a,showLeftBorder:l,filterItemsCounter:s,pinnedPosition:c,isSiblingFocused:u}=e,d=n.sortable&&!t,p=null!=i,f=null!=s&&s>0,h="number"===n.type;return wm({root:["columnHeader","left"===n.headerAlign&&"columnHeader--alignLeft","center"===n.headerAlign&&"columnHeader--alignCenter","right"===n.headerAlign&&"columnHeader--alignRight",d&&"columnHeader--sortable",o&&"columnHeader--moving",p&&"columnHeader--sorted",f&&"columnHeader--filtered",h&&"columnHeader--numeric","withBorderColor",a&&"columnHeader--withRightBorder",l&&"columnHeader--withLeftBorder",c===nD.LEFT&&"columnHeader--pinnedLeft",c===nD.RIGHT&&"columnHeader--pinnedRight",u&&"columnHeader--siblingFocused"],draggableContainer:["columnHeaderDraggableContainer"],titleContainer:["columnHeaderTitleContainer"],titleContainerContent:["columnHeaderTitleContainerContent"]},YT,r)})(f({},e,{classes:x.classes,showRightBorder:v,showLeftBorder:g})),D=s.useCallback(e=>n=>{v$(n)||w.current.publishEvent(e,w.current.getColumnHeaderParams(t.field),n)},[w,t.field]),F=s.useMemo(()=>({onClick:D("columnHeaderClick"),onContextMenu:D("columnHeaderContextMenu"),onDoubleClick:D("columnHeaderDoubleClick"),onMouseOver:D("columnHeaderOver"),onMouseOut:D("columnHeaderOut"),onMouseEnter:D("columnHeaderEnter"),onMouseLeave:D("columnHeaderLeave"),onKeyDown:D("columnHeaderKeyDown"),onFocus:D("columnHeaderFocus"),onBlur:D("columnHeaderBlur")}),[D]),L=s.useMemo(()=>T?{onDragStart:D("columnHeaderDragStart"),onDragEnter:D("columnHeaderDragEnter"),onDragOver:D("columnHeaderDragOver"),onDragEndCapture:D("columnHeaderDragEnd")}:{},[T,D]),A=s.useMemo(()=>({onMouseDown:D("columnSeparatorMouseDown"),onDoubleClick:D("columnSeparatorDoubleClick")}),[D]);s.useEffect(()=>{!P&&n&&M(n)},[P,n]);const N=s.useCallback(()=>{M(!1)},[]),$=!x.disableColumnMenu&&!t.disableColumnMenu&&Xp.jsx(p$,{colDef:t,columnMenuId:k,columnMenuButtonId:E,open:P,iconButtonRef:R}),z=Xp.jsx(f$,{columnMenuId:k,columnMenuButtonId:E,field:t.field,open:n,target:R.current,ContentComponent:x.slots.columnMenu,contentComponentProps:x.slotProps?.columnMenu,onExited:N}),j=t.sortingOrder??x.sortingOrder,B=(t.sortable||null!=l)&&!t.hideSortIcons&&!x.disableColumnSorting,_=Xp.jsxs(s.Fragment,{children:[!x.disableColumnFilter&&Xp.jsx(x.slots.columnHeaderFilterIconButton,f({field:t.field,counter:u},x.slotProps?.columnHeaderFilterIconButton)),B&&Xp.jsx(x.slots.columnHeaderSortIcon,f({field:t.field,direction:l,index:c,sortingOrder:j,disabled:!t.sortable},x.slotProps?.columnHeaderSortIcon))]});s.useLayoutEffect(()=>{const e=w.current.state.columnMenu;if(d&&!e.open){const e=C.current.querySelector('[tabindex="0"]')||C.current;if(!e)return;if(CN())e.focus({preventScroll:!0});else{const t=w.current.getScrollPosition();e.focus(),w.current.scroll(t)}}},[w,d]);const H="function"==typeof t.headerClassName?t.headerClassName({field:t.field,colDef:t}):t.headerClassName,V=t.headerName??t.field,W=s.useMemo(()=>EN(f({},e.style),S,b,y),[b,y,e.style,S]);return Xp.jsx(D$,f({ref:C,classes:O,columnMenuOpen:n,colIndex:r,height:o,isResizing:i,sortDirection:l,hasFocus:d,tabIndex:p,separatorSide:m,isDraggable:T,headerComponent:I,description:t.description,elementId:t.field,width:t.computedWidth,columnMenuIconButton:$,columnTitleIconButtons:_,headerClassName:PR(H,a&&XT["columnHeader--last"]),label:V,resizable:!x.disableColumnResize&&!!t.resizable,"data-field":t.field,columnMenu:z,draggableContainerProps:L,columnHeaderSeparatorProps:A,style:W},F))}),L$=["className"],A$=jh("div",{name:"MuiDataGrid",slot:"IconButtonContainer"})(()=>({display:"flex",visibility:"hidden",width:0})),N$=TR(function(e,t){const{className:n}=e,r=d(e,L$),o=rP(),i=(e=>{const{classes:t}=e;return wm({root:["iconButtonContainer"]},YT,t)})(o);return Xp.jsx(A$,f({className:PR(i.root,n),ownerState:o},r,{ref:t}))}),$$=["direction","index","sortingOrder","disabled","className"],z$=jh(gI,{name:"MuiDataGrid",slot:"SortButton"})({transition:bP.transition(["opacity"],{duration:bP.transitions.duration.short,easing:bP.transitions.easing.easeInOut})});function j$(e){const{direction:t,index:n,sortingOrder:r,disabled:o,className:i}=e,a=d(e,$$),l=lP(),c=rP(),u=f({},e,{classes:c.classes}),p=(e=>{const{classes:t}=e;return wm({root:["sortButton"],icon:["sortIcon"]},YT,t)})(u),h=function(e,t,n,r){let o;const i={};return"asc"===t?o=e.columnSortedAscendingIcon:"desc"===t?o=e.columnSortedDescendingIcon:(o=e.columnUnsortedIcon,i.sortingOrder=r),o?Xp.jsx(o,f({fontSize:"small",className:n},i)):null}(c.slots,t,p.icon,r);if(!h)return null;const m=Xp.jsx(z$,f({as:c.slots.baseIconButton,ownerState:u,"aria-label":l.current.getLocaleText("columnHeaderSortIconLabel"),title:l.current.getLocaleText("columnHeaderSortIconLabel"),size:"small",disabled:o,className:PR(p.root,i)},c.slotProps?.baseIconButton,a,{children:h}));return Xp.jsxs(s.Fragment,{children:[null!=n&&Xp.jsx(c.slots.baseBadge,{badgeContent:n,color:"default",overlap:"circular",children:m}),null==n&&m]})}function B$(e){return Xp.jsx(N$,{children:Xp.jsx(j$,f({},e,{tabIndex:-1}))})}const _$=s.memo(B$);function H$(e){const{counter:t,field:n,onClick:r}=e,o=lP(),i=rP(),a=(e=>{const{classes:t}=e;return wm({icon:["filterIcon"]},YT,t)})(f({},e,{classes:i.classes})),l=mm(),c=pI(o,qL,l),u=mm(),d=s.useCallback(e=>{e.preventDefault(),e.stopPropagation();const{open:t,openedPanelValue:i}=KL(o);t&&i===YL.filters?o.current.hideFilterPanel():o.current.showFilterPanel(void 0,u,l),r&&r(o.current.getColumnHeaderParams(n),e)},[o,n,r,u,l]);if(!t)return null;const p=Xp.jsx(i.slots.baseIconButton,f({id:l,onClick:d,"aria-label":o.current.getLocaleText("columnHeaderFiltersLabel"),size:"small",tabIndex:-1,"aria-haspopup":"menu","aria-expanded":c,"aria-controls":c?u:void 0},i.slotProps?.baseIconButton,{children:Xp.jsx(i.slots.columnFilteredIcon,{className:a.icon,fontSize:"small"})}));return Xp.jsx(i.slots.baseTooltip,f({title:o.current.getLocaleText("columnHeaderFiltersTooltipActive")(t),enterDelay:1e3},i.slotProps?.baseTooltip,{children:Xp.jsxs(N$,{children:[t>1&&Xp.jsx(i.slots.baseBadge,{badgeContent:t,color:"default",children:p}),1===t&&p]})}))}const V$=["hideMenu","colDef","id","labelledby","className","children","open"],W$=pg(gI)(()=>({minWidth:248}));function U$(e){e.currentTarget.contains(e.target)&&e.stopPropagation()}const G$=TR(function(e,t){const{hideMenu:n,id:r,labelledby:o,className:i,children:a,open:l}=e,c=d(e,V$),u=rP(),p=s.useCallback(e=>{"Tab"===e.key&&e.preventDefault(),NO(e.key)&&n(e)},[n]);return Xp.jsx(W$,f({as:u.slots.baseMenuList,id:r,className:PR(XT.menuList,i),"aria-labelledby":o,onKeyDown:p,onWheel:U$,onTouchMove:U$,autoFocus:l},c,{ref:t,children:a}))}),K$=["displayOrder"];function q$(e){const{colDef:t,onClick:n}=e,r=lP(),o=rP(),i=1===cO(r).filter(e=>!0!==e.disableColumnMenu).length,a=s.useCallback(e=>{i||(r.current.setColumnVisibility(t.field,!1),n(e))},[r,t.field,n,i]);return o.disableColumnSelector||!1===t.hideable?null:Xp.jsx(o.slots.baseMenuItem,{onClick:a,disabled:i,iconStart:Xp.jsx(o.slots.columnMenuHideIcon,{fontSize:"small"}),children:r.current.getLocaleText("columnMenuHideColumn")})}function Y$(e){const{onClick:t}=e,n=lP(),r=rP(),o=s.useCallback(e=>{t(e),n.current.showPreferences(YL.columns)},[n,t]);return r.disableColumnSelector?null:Xp.jsx(r.slots.baseMenuItem,{onClick:o,iconStart:Xp.jsx(r.slots.columnMenuManageColumnsIcon,{fontSize:"small"}),children:n.current.getLocaleText("columnMenuManageColumns")})}const X$=["defaultSlots","defaultSlotProps","slots","slotProps"],Q$={columnMenuSortItem:function(e){const{colDef:t,onClick:n}=e,r=lP(),o=pI(r,gD),i=rP(),a=s.useMemo(()=>{if(!t)return null;const e=o.find(e=>e.field===t.field);return e?.sort},[t,o]),l=t.sortingOrder??i.sortingOrder,c=s.useCallback(e=>{n(e);const o=e.currentTarget.getAttribute("data-value")||null,l="always"===i.multipleColumnsSortingMode;r.current.sortColumn(t.field,o===a?null:o,l)},[r,t,n,a,i.multipleColumnsSortingMode]);if(i.disableColumnSorting||!t||!t.sortable||!l.some(e=>!!e))return null;const u=e=>{const n=r.current.getLocaleText(e);return"function"==typeof n?n(t):n};return Xp.jsxs(s.Fragment,{children:[l.includes("asc")&&"asc"!==a?Xp.jsx(i.slots.baseMenuItem,{onClick:c,"data-value":"asc",iconStart:Xp.jsx(i.slots.columnMenuSortAscendingIcon,{fontSize:"small"}),children:u("columnMenuSortAsc")}):null,l.includes("desc")&&"desc"!==a?Xp.jsx(i.slots.baseMenuItem,{onClick:c,"data-value":"desc",iconStart:Xp.jsx(i.slots.columnMenuSortDescendingIcon,{fontSize:"small"}),children:u("columnMenuSortDesc")}):null,l.includes(null)&&null!=a?Xp.jsx(i.slots.baseMenuItem,{onClick:c,iconStart:i.slots.columnMenuUnsortIcon?Xp.jsx(i.slots.columnMenuUnsortIcon,{fontSize:"small"}):Xp.jsx("span",{}),children:r.current.getLocaleText("columnMenuUnsort")}):null]})},columnMenuFilterItem:function(e){const{colDef:t,onClick:n}=e,r=lP(),o=rP(),i=s.useCallback(e=>{n(e),r.current.showFilterPanel(t.field)},[r,t.field,n]);return o.disableColumnFilter||!t.filterable?null:Xp.jsx(o.slots.baseMenuItem,{onClick:i,iconStart:Xp.jsx(o.slots.columnMenuFilterIcon,{fontSize:"small"}),children:r.current.getLocaleText("columnMenuFilter")})},columnMenuColumnsItem:function(e){return Xp.jsxs(s.Fragment,{children:[Xp.jsx(q$,f({},e)),Xp.jsx(Y$,f({},e))]})}},Z$={columnMenuSortItem:{displayOrder:10},columnMenuFilterItem:{displayOrder:20},columnMenuColumnsItem:{displayOrder:30}},J$=TR(function(e,t){const{defaultSlots:n,defaultSlotProps:r,slots:o,slotProps:i}=e,a=d(e,X$),l=(e=>{const t=mL(),n=rP(),{defaultSlots:r,defaultSlotProps:o,slots:i={},slotProps:a={},hideMenu:l,colDef:c,addDividers:u=!0}=e,p=s.useMemo(()=>f({},r,i),[r,i]),h=s.useMemo(()=>{if(!a||0===Object.keys(a).length)return o;const e=f({},a);return Object.entries(o).forEach(([t,n])=>{e[t]=f({},n,a[t]||{})}),e},[o,a]),m=t.current.unstable_applyPipeProcessors("columnMenu",[],e.colDef),g=s.useMemo(()=>{const e=Object.keys(r);return Object.keys(i).filter(t=>!e.includes(t))},[i,r]);return s.useMemo(()=>{const e=Array.from(new Set([...m,...g])).filter(e=>null!=p[e]),t=e.sort((e,t)=>{const n=h[e],r=h[t];return(Number.isFinite(n?.displayOrder)?n.displayOrder:100)-(Number.isFinite(r?.displayOrder)?r.displayOrder:100)});return t.reduce((e,r,o)=>{let i={colDef:c,onClick:l};const a=h[r];return a&&(i=f({},i,d(a,K$))),u&&o!==t.length-1?[...e,[p[r],i],[n.slots.baseDivider,{}]]:[...e,[p[r],i]]},[])},[u,c,m,l,p,h,g,n.slots.baseDivider])})(f({},a,{defaultSlots:n,defaultSlotProps:r,slots:o,slotProps:i}));return Xp.jsx(G$,f({},a,{ref:t,children:l.map(([e,t],n)=>Xp.jsx(e,f({},t),n))}))}),ez=TR(function(e,t){return Xp.jsx(J$,f({},e,{ref:t,defaultSlots:Q$,defaultSlotProps:Z$}))}),tz=["className"],nz=pg("div",{name:"MuiDataGrid",slot:"PanelWrapper"})({display:"flex",flexDirection:"column",flex:1,"&:focus":{outline:0}}),rz=TR(function(e,t){const{className:n}=e,r=d(e,tz),o=rP(),i=(e=>{const{classes:t}=e;return wm({root:["panelWrapper"]},YT,t)})(o);return Xp.jsx(nz,f({tabIndex:-1,className:PR(i.root,n),ownerState:o},r,{ref:t}))});const oz=["children","className","classes","onClose"],iz=Mh("MuiDataGrid",["panel","paper"]),az=pg(gI,{name:"MuiDataGrid",slot:"panel"})({zIndex:bP.zIndex.panel}),lz=pg("div",{name:"MuiDataGrid",slot:"panelContent"})({backgroundColor:bP.colors.background.overlay,borderRadius:bP.radius.base,boxShadow:bP.shadows.overlay,display:"flex",maxWidth:`calc(100vw - ${bP.spacing(2)})`,overflow:"auto"}),sz=TR((e,t)=>{const{children:n,className:r,onClose:o}=e,i=d(e,oz),a=lP(),l=rP(),c=iz,[u,p]=s.useState(!1),h=_O(),m=Mg(()=>p(!0)),g=Mg(()=>p(!1)),v=Mg(()=>{o?.()}),b=Mg(e=>{"Escape"===e.key&&o?.()}),[y,w]=s.useState(null);return s.useEffect(()=>{const e=a.current.rootElementRef?.current?.querySelector('[data-id="gridPanelAnchor"]');e&&w(e)},[a]),y?Xp.jsx(az,f({as:l.slots.basePopper,ownerState:l,placement:"bottom-end",className:PR(c.panel,r,h),flip:!0,onDidShow:m,onDidHide:g,onClickAway:v,clickAwayMouseEvent:"onPointerUp",clickAwayTouchEvent:!1,focusTrap:!0},i,l.slotProps?.basePopper,{target:e.target??y,ref:t,children:Xp.jsx(lz,{className:c.paper,ownerState:l,onKeyDown:b,children:u&&n})})):null}),cz=["className"],uz=jh("div",{name:"MuiDataGrid",slot:"PanelContent"})({display:"flex",flexDirection:"column",overflow:"auto",flex:"1 1",maxHeight:400,padding:bP.spacing(2.5,1.5,2,1),gap:bP.spacing(2.5)});function dz(e){const{className:t}=e,n=d(e,cz),r=rP(),o=(e=>{const{classes:t}=e;return wm({root:["panelContent"]},YT,t)})(r);return Xp.jsx(uz,f({className:PR(o.root,t),ownerState:r},n))}const pz=["className"],fz=pg("div",{name:"MuiDataGrid",slot:"PanelFooter"})({padding:bP.spacing(1),display:"flex",justifyContent:"space-between",borderTop:`1px solid ${bP.colors.border.base}`});function hz(e){const{className:t}=e,n=d(e,pz),r=rP(),o=(e=>{const{classes:t}=e;return wm({root:["panelFooter"]},YT,t)})(r);return Xp.jsx(fz,f({className:PR(o.root,t),ownerState:r},n))}const mz=["item","hasMultipleFilters","deleteFilter","applyFilterChanges","showMultiFilterOperators","disableMultiFilterOperator","applyMultiFilterOperatorChanges","focusElementRef","logicOperators","columnsSort","filterColumns","deleteIconProps","logicOperatorInputProps","operatorInputProps","columnInputProps","valueInputProps","readOnly","children"],gz=["InputComponentProps"],vz=pg("div",{name:"MuiDataGrid",slot:"FilterForm"})({display:"flex",gap:bP.spacing(1.5)}),bz=pg("div",{name:"MuiDataGrid",slot:"FilterFormDeleteIcon"})({flexShrink:0,display:"flex",justifyContent:"center",alignItems:"center"}),yz=pg("div",{name:"MuiDataGrid",slot:"FilterFormLogicOperatorInput"})({minWidth:75,justifyContent:"end"}),wz=pg("div",{name:"MuiDataGrid",slot:"FilterFormColumnInput"})({width:150}),xz=pg("div",{name:"MuiDataGrid",slot:"FilterFormOperatorInput"})({width:150}),Sz=pg("div",{name:"MuiDataGrid",slot:"FilterFormValueInput"})({width:190}),Cz=e=>e.headerName||e.field,kz=new Intl.Collator,Ez=TR(function(e,t){const{item:n,hasMultipleFilters:r,deleteFilter:o,applyFilterChanges:i,showMultiFilterOperators:a,disableMultiFilterOperator:l,applyMultiFilterOperatorChanges:c,focusElementRef:u,logicOperators:p=[BI.And,BI.Or],columnsSort:h,filterColumns:m,deleteIconProps:g={},logicOperatorInputProps:v={},operatorInputProps:b={},columnInputProps:y={},valueInputProps:w={},readOnly:x}=e,S=d(e,mz),C=lP(),k=pI(C,iO),E=pI(C,mO),R=pI(C,yD),P=mm(),M=mm(),T=mm(),I=mm(),O=rP(),D=(e=>{const{classes:t}=e;return wm({root:["filterForm"],deleteIcon:["filterFormDeleteIcon"],logicOperatorInput:["filterFormLogicOperatorInput"],columnInput:["filterFormColumnInput"],operatorInput:["filterFormOperatorInput"],valueInput:["filterFormValueInput"]},YT,t)})(O),F=s.useRef(null),L=s.useRef(null),A=R.logicOperator??BI.And,N=r&&p.length>0,$=(O.slotProps?.baseSelect||{}).native??!1,z=O.slotProps?.baseSelectOption||{},{InputComponentProps:j}=w,B=d(w,gz),_=pI(C,SL),H=pI(C,kL),{filteredColumns:V,selectedField:W}=s.useMemo(()=>{let e=n.field;const t=!1===k[n.field].filterable?k[n.field]:null;if(t)return{filteredColumns:[t],selectedField:e};if(_)return{filteredColumns:E.filter(e=>void 0!==H.get(e.field)),selectedField:e};if(void 0===m||"function"!=typeof m)return{filteredColumns:E,selectedField:e};const r=m({field:n.field,columns:E,currentFilters:R?.items||[]});return{filteredColumns:E.filter(t=>{const o=r.includes(t.field);return t.field!==n.field||o||(e=void 0),o}),selectedField:e}},[n.field,k,_,m,E,R?.items,H]),U=s.useMemo(()=>{switch(h){case"asc":return V.sort((e,t)=>kz.compare(Cz(e),Cz(t)));case"desc":return V.sort((e,t)=>-kz.compare(Cz(e),Cz(t)));default:return V}},[V,h]),G=n.field?C.current.getColumn(n.field):null,K=s.useMemo(()=>n.operator&&G?G.filterOperators?.find(e=>e.value===n.operator):null,[n,G]),q=s.useCallback(e=>{const t=e.target.value,r=C.current.getColumn(t);if(r.field===G.field)return;const o=r.filterOperators.find(e=>e.value===n.operator)||r.filterOperators[0];let a=!o.InputComponent||o.InputComponent!==K?.InputComponent||r.type!==G.type?void 0:n.value;if("singleSelect"===r.type&&void 0!==a){const e=r,t=NF(e);Array.isArray(a)?a=a.filter(n=>void 0!==$F(n,t,e?.getOptionValue)):void 0===$F(n.value,t,e?.getOptionValue)&&(a=void 0)}i(f({},n,{field:t,operator:o.value,value:a}))},[C,i,n,G,K]),Y=s.useCallback(e=>{const t=e.target.value,r=G?.filterOperators.find(e=>e.value===t);i(f({},n,{operator:t,value:!r?.InputComponent||r?.InputComponent!==K?.InputComponent?void 0:n.value}))},[i,n,G,K]),X=s.useCallback(e=>{const t=e.target.value===BI.And.toString()?BI.And:BI.Or;c(t)},[c]);return s.useImperativeHandle(u,()=>({focus:()=>{K?.InputComponent?F?.current?.focus():L.current.focus()}}),[K]),Xp.jsxs(vz,f({className:D.root,"data-id":n.id,ownerState:O},S,{ref:t,children:[Xp.jsx(bz,f({},g,{className:PR(D.deleteIcon,g.className),ownerState:O,children:Xp.jsx(O.slots.baseIconButton,f({"aria-label":C.current.getLocaleText("filterPanelDeleteIconLabel"),title:C.current.getLocaleText("filterPanelDeleteIconLabel"),onClick:()=>{o(n)},size:"small",disabled:x},O.slotProps?.baseIconButton,{children:Xp.jsx(O.slots.filterPanelDeleteIcon,{fontSize:"small"})}))})),Xp.jsx(yz,f({as:O.slots.baseSelect,sx:[N?{display:"flex"}:{display:"none"},a?{visibility:"visible"}:{visibility:"hidden"},v.sx],className:PR(D.logicOperatorInput,v.className),ownerState:O},v,{size:"small",slotProps:{htmlInput:{"aria-label":C.current.getLocaleText("filterPanelLogicOperator")}},value:A??"",onChange:X,disabled:!!l||1===p.length,native:$},O.slotProps?.baseSelect,{children:p.map(e=>s.createElement(O.slots.baseSelectOption,f({},z,{native:$,key:e.toString(),value:e.toString()}),C.current.getLocaleText((e=>{switch(e){case BI.And:return"filterPanelOperatorAnd";case BI.Or:return"filterPanelOperatorOr";default:throw new Error("MUI X: Invalid `logicOperator` property in the `GridFilterPanel`.")}})(e))))})),Xp.jsx(wz,f({as:O.slots.baseSelect},y,{className:PR(D.columnInput,y.className),ownerState:O,size:"small",labelId:M,id:P,label:C.current.getLocaleText("filterPanelColumns"),value:W??"",onChange:q,native:$,disabled:x},O.slotProps?.baseSelect,{children:U.map(e=>s.createElement(O.slots.baseSelectOption,f({},z,{native:$,key:e.field,value:e.field}),Cz(e)))})),Xp.jsx(xz,f({as:O.slots.baseSelect,size:"small"},b,{className:PR(D.operatorInput,b.className),ownerState:O,labelId:I,label:C.current.getLocaleText("filterPanelOperator"),id:T,value:n.operator,onChange:Y,native:$,inputRef:L,disabled:x},O.slotProps?.baseSelect,{children:G?.filterOperators?.map(e=>s.createElement(O.slots.baseSelectOption,f({},z,{native:$,key:e.value,value:e.value}),e.label||C.current.getLocaleText(`filterOperator${xf(e.value)}`)))})),Xp.jsx(Sz,f({},B,{className:PR(D.valueInput,B.className),ownerState:O,children:K?.InputComponent?Xp.jsx(K.InputComponent,f({apiRef:C,item:n,applyValue:i,focusElementRef:F,disabled:x,slotProps:{root:{size:"small"}}},K.InputComponentProps,j),n.field):null}))]}))}),Rz=["logicOperators","columnsSort","filterFormProps","getColumnForNewFilter","children","disableAddFilterButton","disableRemoveAllButton"],Pz=e=>({field:e.field,operator:e.filterOperators[0].value,id:Math.round(1e5*Math.random())}),Mz=TR(function(e,t){const n=lP(),r=rP(),o=pI(n,yD),i=pI(n,mO),a=pI(n,gO),l=s.useRef(null),c=s.useRef(null),{logicOperators:u=[BI.And,BI.Or],columnsSort:p,filterFormProps:h,getColumnForNewFilter:m,disableAddFilterButton:g=!1,disableRemoveAllButton:v=!1}=e,b=d(e,Rz),y=n.current.upsertFilterItem,w=s.useCallback(e=>{n.current.setFilterLogicOperator(e)},[n]),x=s.useCallback(()=>{let e;if(m&&"function"==typeof m){const t=m({currentFilters:o?.items||[],columns:i});if(null===t)return null;e=i.find(({field:e})=>e===t)}else e=i.find(e=>e.filterOperators?.length);return e?Pz(e):null},[o?.items,i,m]),S=s.useCallback(()=>{if(void 0===m||"function"!=typeof m)return x();const e=o.items.length?o.items:[x()].filter(Boolean),t=m({currentFilters:e,columns:i});if(null===t)return null;const n=i.find(({field:e})=>e===t);return n?Pz(n):null},[o.items,i,m,x]),C=s.useMemo(()=>o.items.length?o.items:(c.current||(c.current=x()),c.current?[c.current]:[]),[o.items,x]),k=C.length>1,{readOnlyFilters:E,validFilters:R}=s.useMemo(()=>C.reduce((e,t)=>(a[t.field]?e.validFilters.push(t):e.readOnlyFilters.push(t),e),{readOnlyFilters:[],validFilters:[]}),[C,a]),P=s.useCallback(()=>{const e=S();e&&n.current.upsertFilterItems([...C,e])},[n,S,C]),M=s.useCallback(e=>{const t=1===R.length;n.current.deleteFilterItem(e),t&&n.current.hideFilterPanel()},[n,R.length]),T=s.useCallback(()=>1===R.length&&void 0===R[0].value?(n.current.deleteFilterItem(R[0]),n.current.hideFilterPanel()):n.current.setFilterModel(f({},o,{items:E}),"removeAllFilterItems"),[n,E,o,R]);return s.useEffect(()=>{u.length>0&&o.logicOperator&&!u.includes(o.logicOperator)&&w(u[0])},[u,w,o.logicOperator]),s.useEffect(()=>{R.length>0&&l.current.focus()},[R.length]),Xp.jsxs(rz,f({},b,{ref:t,children:[Xp.jsxs(dz,{children:[E.map((e,t)=>Xp.jsx(Ez,f({item:e,applyFilterChanges:y,deleteFilter:M,hasMultipleFilters:k,showMultiFilterOperators:t>0,disableMultiFilterOperator:1!==t,applyMultiFilterOperatorChanges:w,focusElementRef:null,readOnly:!0,logicOperators:u,columnsSort:p},h),null==e.id?t:e.id)),R.map((e,t)=>Xp.jsx(Ez,f({item:e,applyFilterChanges:y,deleteFilter:M,hasMultipleFilters:k,showMultiFilterOperators:E.length+t>0,disableMultiFilterOperator:E.length+t!==1,applyMultiFilterOperatorChanges:w,focusElementRef:t===R.length-1?l:null,logicOperators:u,columnsSort:p},h),null==e.id?t+E.length:e.id))]}),r.disableMultipleColumnsFiltering||g&&v?null:Xp.jsxs(hz,{children:[g?Xp.jsx("span",{}):Xp.jsx(r.slots.baseButton,f({onClick:P,startIcon:Xp.jsx(r.slots.filterPanelAddIcon,{})},r.slotProps?.baseButton,{children:n.current.getLocaleText("filterPanelAddFilter")})),!v&&R.length>0?Xp.jsx(r.slots.baseButton,f({onClick:T,startIcon:Xp.jsx(r.slots.filterPanelRemoveAllIcon,{})},r.slotProps?.baseButton,{children:n.current.getLocaleText("filterPanelRemoveAll")})):null]})]}))}),Tz=(e,t)=>(e.headerName||e.field).toLowerCase().indexOf(t)>-1,Iz=["children"],Oz=zp({from:{opacity:0},to:{opacity:1}}),Dz=zp({"from, to":{"--scrollable":'" "'}}),Fz=jh("div",{name:"MuiDataGrid",slot:"ShadowScrollArea"})`
|
|
214
214
|
flex: 1;
|
|
215
215
|
display: flex;
|
|
216
216
|
flex-direction: column;
|