@sheetxl/utils-mui 0.7.14 → 0.7.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/browser/cjs/{DlwQQFN_mRiIrttG.cjs → C44XRP-zhbpgMlg3.cjs} +2 -2
- package/browser/cjs/{DTu7X4NVQR5Imqxw.cjs → Ctt_H1syChJ1jaik.cjs} +2 -2
- package/browser/cjs/index.cjs +2 -2
- package/browser/esm/{BEjEVDP4wDSgmkji.mjs → BBaINx5mfXntn3rN.mjs} +2 -2
- package/browser/esm/{BQAx8mHWow5_y9KO.mjs → CkiwRvu0Y9rgxCr6.mjs} +2 -2
- package/browser/esm/index.mjs +2 -2
- package/node/esm/{mzf6ST9951mHAaux.mjs → DZBZtLhOBpcHChEQ.mjs} +1 -1
- package/node/esm/index.mjs +2 -2
- package/package.json +3 -3
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";/**
|
|
2
|
-
* @license @sheetxl/utils-mui - Utilities MUI - Utilities for MUI Components needed for all SheetXL components. - v0.7.
|
|
2
|
+
* @license @sheetxl/utils-mui - Utilities MUI - Utilities for MUI Components needed for all SheetXL components. - v0.7.16
|
|
3
3
|
*
|
|
4
4
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
@@ -8,4 +8,4 @@
|
|
|
8
8
|
`);await navigator.clipboard.writeText(m),s("Copied!"),setTimeout(()=>s(null),2e3)}catch(l){s("Can't copy!"),console.warn("Failed to copy stack trace:",l)}},sx:{color:"inherit",opacity:.7,"&:hover":{opacity:1}},title:"Copy stack trace",children:f.jsx(N.DynamicIcon,{iconKey:"ContentCopy",style:{fontSize:"0.875rem"}})}),f.jsx(L.IconButton,{size:"small",onClick:()=>{s("Logged!"),setTimeout(()=>s(null),2e3),console.log(e)},sx:{color:"inherit",opacity:.7,"&:hover":{opacity:1}},title:"Log error to console",children:f.jsx(N.DynamicIcon,{iconKey:"BugReport",style:{fontSize:"0.875rem"}})})]}),f.jsxs(L.Box,{sx:{mt:1,backgroundColor:"rgba(0, 0, 0, 0.2)",borderRadius:1,p:1,maxHeight:"300px",overflow:"auto",fontFamily:"monospace",fontSize:"0.75rem",lineHeight:1.4},children:[c.map((l,m)=>l.isBoundary?f.jsx(L.Box,{sx:{py:1,mt:m>0?1:0,mb:.5,borderTop:m>0?"1px solid rgba(255, 255, 255, 0.1)":"none"},children:f.jsx(L.Typography,{variant:"caption",component:"div",sx:{fontSize:"0.75rem",fontWeight:"bold",color:k=>l.isBoundary?k.palette.text.primary:k.palette.text.secondary,display:"block"},children:l.line})},`error-${m}`):f.jsxs(L.Box,{sx:{display:"flex",alignItems:"flex-start",gap:1,py:.25,pl:1,"&:hover":{backgroundColor:"rgba(255, 255, 255, 0.05)"}},children:[!n&&f.jsx(L.Typography,{variant:"caption",component:"div",sx:{fontSize:"0.625rem",opacity:.5,minWidth:"20px",textAlign:"right",userSelect:"none"},children:m+1}),f.jsxs(L.Box,{sx:{flex:1,overflow:"hidden"},children:[f.jsx(L.Typography,{variant:"caption",component:"div",sx:{fontSize:"0.75rem",whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",color:"inherit"},children:l.line}),l.location&&l.line!==l.location&&f.jsx(L.Typography,{variant:"caption",component:"div",sx:{fontSize:"0.625rem",opacity:.6,fontStyle:"italic"},children:l.location})]})]},`stack-${m}`)),i&&f.jsxs(L.Typography,{variant:"caption",component:"div",sx:{fontSize:"0.625rem",opacity:.6,fontStyle:"italic",textAlign:"center",display:"block",mt:1},children:["... and ",r.length-o," more frames"]})]})]})});tn.displayName="StackTrace";const Eo=(e,o=!1,n=!1)=>{if(p.isValidElement(e))return e;if(e instanceof Error)return f.jsxs(L.Box,{sx:{display:"flex",flexDirection:"column",maxWidth:"500px",width:"100%"},children:[f.jsx(L.Typography,{variant:"caption",component:"div",sx:{fontSize:"0.875rem",lineHeight:1.43,mb:1},children:e.message}),e.cause?f.jsxs(L.Typography,{variant:"caption",component:"div",sx:{fontSize:"0.875rem",lineHeight:1.43,letterSpacing:"0.01071em",mb:1,opacity:.8},children:["Caused by: ",e.cause instanceof Error?e.cause.message:String(e.cause)]}):null,!o&&f.jsx(tn,{error:e,hideLineNumbers:!0})]});const t=e==="string"?e:`Unknown Error: ${String(e)}`;return f.jsx(L.Typography,{variant:"caption",component:"div",sx:{fontSize:"0.875rem",lineHeight:1.43,letterSpacing:"0.01071em"},children:t})},Mo=p.memo(p.forwardRef((e,o)=>{const{sx:n,icon:t=f.jsx(N.DynamicIcon,{iconKey:"Error",style:{fontSize:48}}),error:s,hideStackTrace:a=!1,stackTraceExpanded:r=!1,...c}=e,i=p.useMemo(()=>Eo(s,a,r),[s,a,r]);return p.useMemo(()=>f.jsx(L.Box,{ref:o,sx:{boxSizing:"border-box",alignItems:"center",justifyContent:"center",display:"flex",flexDirection:"row",overflow:"hidden",width:"100%",height:"100%",...n},...c,children:f.jsxs(L.Box,{sx:{display:"flex",flex:"1 1 100%",height:"100%",alignItems:"center",justifyContent:"center",boxSizing:"border-box",position:"relative"},children:[f.jsx(L.Box,{className:"backdrop",sx:{backdropFilter:"blur(4px)",borderRadius:l=>`${l.shape.borderRadius}px`,zIndex:-1,position:"absolute",width:"100%",height:"100%",boxSizing:"border-box"}}),f.jsx(L.Paper,{elevation:0,sx:{display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",rowGap:"8px",alignSelf:"center",marginBottom:"5%",backgroundColor:l=>l.palette.error.light,color:l=>l.palette.error.contrastText,paddingLeft:l=>l.spacing(2),paddingRight:l=>l.spacing(2),paddingTop:l=>l.spacing(2),paddingBottom:l=>l.spacing(2),borderRadius:l=>`${l.shape.borderRadius}px`,boxShadow:l=>l.shadows[2],"& .primary":{background:l=>`${l.palette.error.contrastText} !important`,border:"solid transparent"},zIndex:1},children:f.jsx(L.Box,{sx:{display:"flex",flexDirection:"column",alignItems:"center",gap:l=>l.spacing(2),width:"100%",maxWidth:"600px"},children:f.jsxs(L.Box,{sx:{display:"flex",flexDirection:"row",alignItems:"flex-start",gap:l=>l.spacing(2)},children:[t,i]})})})]})}),[n])}));Mo.displayName="ErrorPanel";const nn=p.memo(p.forwardRef((e,o)=>{const{chips:n,sx:t,...s}=e,a=p.useMemo(()=>{if(!n)return null;let r=null;r=Array.isArray(n)?n:[n];const c=[],i=r.length;for(let l=0;l<i;l++){const m=r[l];let k=null;typeof m=="string"?k=f.jsx(L.Chip,{label:m,color:"primary",size:"small",sx:{scale:"0.8"}},"chip-"+l):p.cloneElement(m,{key:"chip-"+l}),c.push(k)}return c},[n]);return f.jsx(L.Box,{ref:o,sx:{display:"flex",flexDirection:"row",marginLeft:"4px",gap:"2px",...t},...s,children:a})}));var zt="top",vt="bottom",Wt="right",To="left",Mr=[zt,vt,Wt,To],jo="viewport",tt="popper";function ze(e){return e?(e.nodeName||"").toLowerCase():null}function Pe(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var o=e.ownerDocument;return o&&o.defaultView||window}return e}function Xe(e){return e instanceof Pe(e).Element||e instanceof Element}function Qe(e){return e instanceof Pe(e).HTMLElement||e instanceof HTMLElement}function on(e){return typeof ShadowRoot<"u"&&(e instanceof Pe(e).ShadowRoot||e instanceof ShadowRoot)}var lt=Math.max,Sn=Math.min,Cn=Math.round;function Ut(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(o){return o.brand+"/"+o.version}).join(" "):navigator.userAgent}function Po(){return!/^((?!chrome|android).)*safari/i.test(Ut())}function rn(e,o,n){o===void 0&&(o=!1),n===void 0&&(n=!1);var t=e.getBoundingClientRect(),s=1,a=1;o&&Qe(e)&&(s=e.offsetWidth>0&&Cn(t.width)/e.offsetWidth||1,a=e.offsetHeight>0&&Cn(t.height)/e.offsetHeight||1);var r=(Xe(e)?Pe(e):window).visualViewport,c=!Po()&&n,i=(t.left+(c&&r?r.offsetLeft:0))/s,l=(t.top+(c&&r?r.offsetTop:0))/a,m=t.width/s,k=t.height/a;return{width:m,height:k,top:l,right:i+m,bottom:l+k,left:i,x:i,y:l}}function Le(e){return Pe(e).getComputedStyle(e)}function Tr(e){return["table","td","th"].indexOf(ze(e))>=0}function Ge(e){return((Xe(e)?e.ownerDocument:e.document)||window.document).documentElement}function Mt(e){return ze(e)==="html"?e:e.assignedSlot||e.parentNode||(on(e)?e.host:null)||Ge(e)}function Dn(e){return Qe(e)&&Le(e).position!=="fixed"?e.offsetParent:null}function jr(e){for(var o=Pe(e),n=Dn(e);n&&Tr(n)&&Le(n).position==="static";)n=Dn(n);return n&&(ze(n)==="html"||ze(n)==="body"&&Le(n).position==="static")?o:n||(function(t){var s=/firefox/i.test(Ut());if(/Trident/i.test(Ut())&&Qe(t)&&Le(t).position==="fixed")return null;var a=Mt(t);for(on(a)&&(a=a.host);Qe(a)&&["html","body"].indexOf(ze(a))<0;){var r=Le(a);if(r.transform!=="none"||r.perspective!=="none"||r.contain==="paint"||["transform","perspective"].indexOf(r.willChange)!==-1||s&&r.willChange==="filter"||s&&r.filter&&r.filter!=="none")return a;a=a.parentNode}return null})(e)||o}function Ro(e){var o=Pe(e);return{scrollLeft:o.pageXOffset,scrollTop:o.pageYOffset}}function On(e){return rn(Ge(e)).left+Ro(e).scrollLeft}function Fo(e){var o=Le(e),n=o.overflow,t=o.overflowX,s=o.overflowY;return/auto|scroll|overlay|hidden/.test(n+s+t)}function No(e){return["html","body","#document"].indexOf(ze(e))>=0?e.ownerDocument.body:Qe(e)&&Fo(e)?e:No(Mt(e))}function Bo(e,o){var n;o===void 0&&(o=[]);var t=No(e),s=t===((n=e.ownerDocument)==null?void 0:n.body),a=Pe(t),r=s?[a].concat(a.visualViewport||[],Fo(t)?t:[]):t,c=o.concat(r);return s?c:c.concat(Bo(Mt(r)))}function Ht(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function En(e,o,n){return o===jo?Ht((function(t,s){var a=Pe(t),r=Ge(t),c=a.visualViewport,i=r.clientWidth,l=r.clientHeight,m=0,k=0;if(c){i=c.width,l=c.height;var g=Po();(g||!g&&s==="fixed")&&(m=c.offsetLeft,k=c.offsetTop)}return{width:i,height:l,x:m+On(t),y:k}})(e,n)):Xe(o)?(function(t,s){var a=rn(t,!1,s==="fixed");return a.top=a.top+t.clientTop,a.left=a.left+t.clientLeft,a.bottom=a.top+t.clientHeight,a.right=a.left+t.clientWidth,a.width=t.clientWidth,a.height=t.clientHeight,a.x=a.left,a.y=a.top,a})(o,n):Ht((function(t){var s,a=Ge(t),r=Ro(t),c=(s=t.ownerDocument)==null?void 0:s.body,i=lt(a.scrollWidth,a.clientWidth,c?c.scrollWidth:0,c?c.clientWidth:0),l=lt(a.scrollHeight,a.clientHeight,c?c.scrollHeight:0,c?c.clientHeight:0),m=-r.scrollLeft+On(t),k=-r.scrollTop;return Le(c||a).direction==="rtl"&&(m+=lt(a.clientWidth,c?c.clientWidth:0)-i),{width:i,height:l,x:m,y:k}})(Ge(e)))}function Pr(e){var o=Bo(Mt(e)),n=["absolute","fixed"].indexOf(Le(e).position)>=0&&Qe(e)?jr(e):e;return Xe(n)?o.filter(function(t){return Xe(t)&&(function(s,a){var r=a.getRootNode&&a.getRootNode();if(s.contains(a))return!0;if(r&&on(r)){var c=a;do{if(c&&s.isSameNode(c))return!0;c=c.parentNode||c.host}while(c)}return!1})(t,n)&&ze(t)!=="body"}):[]}function Rr(e,o){o===void 0&&(o={});var n,t=o,s=t.placement,a=s===void 0?e.placement:s,r=t.strategy,c=r===void 0?e.strategy:r,i=t.boundary,l=i===void 0?"clippingParents":i,m=t.rootBoundary,k=m===void 0?jo:m,g=t.elementContext,x=g===void 0?tt:g,w=t.altBoundary,y=w!==void 0&&w,h=t.padding,v=h===void 0?0:h,u=(function(_){return Object.assign({},{top:0,right:0,bottom:0,left:0},_)})(typeof v!="number"?v:(n=v,Mr.reduce(function(_,V){return _[V]=n,_},{}))),S=x===tt?"reference":tt,M=e.rects.popper,j=e.elements[y?S:x],$=(function(_,V,z,H){var Z=V==="clippingParents"?Pr(_):[].concat(V),X=[].concat(Z,[z]),J=X[0],ne=X.reduce(function(oe,ee){var re=En(_,ee,H);return oe.top=lt(re.top,oe.top),oe.right=Sn(re.right,oe.right),oe.bottom=Sn(re.bottom,oe.bottom),oe.left=lt(re.left,oe.left),oe},En(_,J,H));return ne.width=ne.right-ne.left,ne.height=ne.bottom-ne.top,ne.x=ne.left,ne.y=ne.top,ne})(Xe(j)?j:j.contextElement||Ge(e.elements.popper),l,k,c),O=rn(e.elements.reference),P=(function(_){var V,z=_.reference,H=_.element,Z=_.placement,X=Z?(function(ie){return ie.split("-")[0]})(Z):null,J=Z?(function(ie){return ie.split("-")[1]})(Z):null,ne=z.x+z.width/2-H.width/2,oe=z.y+z.height/2-H.height/2;switch(X){case zt:V={x:ne,y:z.y-H.height};break;case vt:V={x:ne,y:z.y+z.height};break;case Wt:V={x:z.x+z.width,y:oe};break;case To:V={x:z.x-H.width,y:oe};break;default:V={x:z.x,y:z.y}}var ee=X?(function(ie){return["top","bottom"].indexOf(ie)>=0?"x":"y"})(X):null;if(ee!=null){var re=ee==="y"?"height":"width";switch(J){case"start":V[ee]=V[ee]-(z[re]/2-H[re]/2);break;case"end":V[ee]=V[ee]+(z[re]/2-H[re]/2)}}return V})({reference:O,element:M,placement:a}),C=Ht(Object.assign({},M,P)),D=x===tt?C:O,I={top:$.top-D.top+u.top,bottom:D.bottom-$.bottom+u.bottom,left:$.left-D.left+u.left,right:D.right-$.right+u.right},T=e.modifiersData.offset;if(x===tt&&T){var B=T[a];Object.keys(I).forEach(function(_){var V=[Wt,vt].indexOf(_)>=0?1:-1,z=[zt,vt].indexOf(_)>=0?"y":"x";I[_]+=B[z]*V})}return I}const Fr={name:"maxSize",enabled:!0,phase:"main",requiresIfExists:["offset","preventOverflow","flip"],fn:function(e){var o=e.state,n=e.name,t=Rr(o,e.options),s=o.modifiersData.preventOverflow||{x:0,y:0},a=s.x,r=s.y;let c=o.rects.popper,i=c.width,l=c.height,m=o.placement.split("-")[0],k=m==="left"?"left":"right",g=m==="top"?"top":"bottom";o.modifiersData[n]={width:i-t[k]-a,height:l-t[g]-r}}},Nr=[0,2],an=p.memo(p.forwardRef((e,o)=>{const{sx:n,open:t,children:s,label:a,offsets:r=Nr,anchorEl:c,anchorPosition:i,onMount:l,onOpening:m,onOpen:k,onClosing:g,onClose:x,resizeOnOverflow:w=!0,...y}=e;if(Array.isArray(s))throw new Error("children can not be an array");const h=We.useTheme(),v={name:"applyMaxSize",enabled:!0,phase:"beforeWrite",requires:["maxSize"],fn({state:X}){const{height:J}=X.modifiersData.maxSize;X.styles.popper.maxHeight=J-10+"px"}},u=p.useMemo(()=>{const X=[{name:"offset",options:{offset:r}},{name:"flip",enabled:!0,options:{rootBoundary:"document"}}];return w&&X.unshift(Fr,v),X},[w,r]),[S,M]=p.useState(!1),j=p.useRef(null),$=N.useCallbackRef(()=>{l?.(B.current,j.current)},[m]),O=N.useCallbackRef(m,[m]),P=N.useCallbackRef(k,[k]),C=N.useCallbackRef(g,[g]),D=N.useCallbackRef(()=>{M(!1),x?.()},[x]),[I,T]=p.useState(!1),B=p.useRef(null),_=p.useRef(!0),V=p.useMemo(()=>({onFirstUpdate:()=>{_.current&&(T(!0),$?.(),_.current=!1)}}),[t,S]);p.useEffect(()=>{t&&I?O?.():!t&&S&&C?.(),t&&M(t)},[t,I]);const z=p.useMemo(()=>({getBoundingClientRect:()=>i?new DOMRect(i?.left||0,i?.top||0,0,0):c.getBoundingClientRect()}),[i,c]);p.useImperativeHandle(o,()=>({instance:()=>j.current,element:()=>B.current}),[]);const{getPortalContainer:H}=N.useFullscreenPortal(),Z=p.useMemo(()=>({zIndex:t?"1300":"1299",display:"flex",pointerEvents:S&&t?void 0:"none",maxWidth:"100%",maxHeight:"100%",...n}),[n,t,S]);return f.jsx(L.Popper,{ref:B,popperRef:j,container:H,anchorEl:z,open:S,role:void 0,popperOptions:V,transition:!0,sx:Z,placement:"bottom-start",modifiers:u,...y,children:({TransitionProps:X,placement:J,...ne})=>{const{in:oe,onEnter:ee,onExited:re,...ie}=X??{};return f.jsx(L.Grow,{...ie,in:t,onEnter:()=>{ee?.(),P()},onExited:()=>{re?.(),D()},timeout:{enter:h.transitions.duration.shorter,exit:0},style:{transformOrigin:J==="bottom-start"?"left top":"center bottom"},children:typeof s=="function"?s({TransitionProps:X,placement:J,...ne}):s||ve.CommonUtils.EmptyArray})}})}));an.displayName="ExhibitPopper";const Kt=e=>f.jsx(N.DynamicIcon,{...e,iconKey:"ArrowDownOutline"}),Io=e=>f.jsx(N.DynamicIcon,{...e,iconKey:"ArrowRightOutline"}),Br=p.memo(p.forwardRef((e,o)=>{const{sx:n,size:t="small",activeColor:s,children:a,className:r,...c}=e;let i="1rem",l="1rem";return t==="medium"?(i="1.25rem",l="1.25rem"):t==="large"&&(i="1.5rem",l="1.5rem"),f.jsx(L.Box,{ref:o,className:ye("icon",r),sx:{width:i,height:l,...n},...c,children:a})})),Ir=We.styled(Br)(({theme:e})=>({fill:"currentColor","& .activeColor":{fill:e.palette.primary.main},"& .styled.high_contrast":{fill:e.palette.primary.main},"& .styled.background":{fill:e.palette.background.paper},"& .styled.current_color":{fill:"currentColor"},"& .styled.secondary":{fill:e.palette.secondary.main},"& .styled.secondary_dark":{fill:e.palette.secondary.dark},"& .styled.secondary_light":{fill:e.palette.secondary.light},"& .styled.info":{fill:e.palette.info.main},"& .styled.info.stroked":{stroke:e.palette.info.main},"& .styled.info_dark":{fill:e.palette.info.dark},"& .styled.info_light":{fill:e.palette.info.light},"& .styled.warning":{fill:e.palette.warning.main},"& .styled.warning.stroked":{stroke:e.palette.warning.main},"& .styled.warning_dark":{fill:e.palette.warning.dark},"& .styled.warning_light":{fill:e.palette.warning.light},"& .styled.error.info":{fill:e.palette.error.main},"& .styled.error.stroked":{stroke:e.palette.error.main},"& .styled.error_dark":{fill:e.palette.error.dark},"& .styled.error_light":{fill:e.palette.error.light},"& .styled.success":{fill:e.palette.success.main},"& .styled.success_dark":{fill:e.palette.success.dark},"& .styled.success_light":{fill:e.palette.success.light},"& .styled.grey":{fill:e.palette.text.icon??e.palette.action.active}})),_r=/^#?([a-f\d])([a-f\d])([a-f\d])$/i,Ar=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i,_o=function(e,o=null){if(!e)return e;e=e.replace(_r,function(t,s,a,r){return s+s+a+a+r+r});let n=Ar.exec(e);return n?o===null?`rgb(${parseInt(n[1],16)}, ${parseInt(n[2],16)}, ${parseInt(n[3],16)})`:`rgb(${parseInt(n[1],16)} ${parseInt(n[2],16)} ${parseInt(n[3],16)} / ${100*o}%)`:e},Yt=function(e,o=.2,n="light"){if(!e)return e;let t=n!=="dark";return o<0&&(t=!t,o*=-1),e=_o(e),t?se.darken(e,Math.max(0,Math.min(1,1*o))):se.lighten(e,Math.max(0,Math.min(1,1.5*o)))};function Ao(e,o){return o=bo.deepmerge({track:Yt(e.palette.background.paper,.05,e?.palette.mode),thumb:Yt(e.palette.background.paper,.3,e?.palette.mode),active:e.palette.primary.main,corner:e.palette.background.paper,outline:!1},o||{}),{"--scrollbar-track-color":se.alpha(o.track,.2),"--scrollbar-thumb-color":o.thumb,"--scrollbar-button-color":o.button||o.thumb,"--scrollbar-active-color":o.active,"--scrollbar-corner-color":o.corner||o.thumb,"--scrollbar-border-color":o.track,"--scrollbar-width":"13px","--scrollbar-height":"13px","--scrollbar-border-radius":"9999px","--scrollbar-border-width":"2px","--scrollbar-min-thumb-size":"24px"}}function sn(e,o){const n=Ao(e,o),t={...n,"& .scrollbar, & .vsb-track, & .vsb-thumb":{...n},"&::-webkit-scrollbar, & *::-webkit-scrollbar":{backgroundColor:"var(--scrollbar-track-color)",width:"var(--scrollbar-width)",height:"var(--scrollbar-height)"},"&::-webkit-scrollbar-button":{display:"none"},"& .scrollbar-button":{fill:"var(--scrollbar-thumb-color)",backgroundColor:"transparent",transition:"fill opacity 260ms ease",width:"var(--scrollbar-width)",height:"var(--scrollbar-height)"},"& .scrollbar-button:hover:not([disabled])":{fill:"var(--scrollbar-active-color)"},"& .scrollbar-button:disabled":{opacity:.8},"&::-webkit-scrollbar-track, & *::-webkit-scrollbar-track":{},"&::-webkit-scrollbar-track-piece, & *::-webkit-scrollbar-track-piece":{},"&::-webkit-scrollbar-thumb, & *::-webkit-scrollbar-thumb":{borderRadius:"var(--scrollbar-border-radius)",backgroundColor:"var(--scrollbar-thumb-color)",minHeight:"var(--scrollbar-min-thumb-size)",minWidth:"var(--scrollbar-min-thumb-size)",border:"var(--scrollbar-border-width) solid var(--scrollbar-border-color)"},"&::-webkit-scrollbar-thumb:focus, & *::-webkit-scrollbar-thumb:focus":{backgroundColor:"var(--scrollbar-active-color)",border:o?.outline?o.outline:void 0},"&::-webkit-scrollbar-thumb:active, & *::-webkit-scrollbar-thumb:active":{backgroundColor:"var(--scrollbar-active-color)",border:o?.outline?o.outline:void 0},"&::-webkit-scrollbar-thumb:hover, & *::-webkit-scrollbar-thumb:hover":{backgroundColor:"var(--scrollbar-active-color)",border:o?.outline?o.outline:void 0},"&::-webkit-scrollbar-corner, & *::-webkit-scrollbar-corner":{backgroundColor:"var(--scrollbar-corner-color)"}};return ve.CommonUtils.getOS()===ve.CommonUtils.OSType.Firefox&&(t["* .pseudo-scrollbar"]={scrollbarColor:"var(--scrollbar-thumb-color) transparent"},t["* .pseudo-scrollbar:hover:not([disabled])"]={scrollbarColor:"var(--scrollbar-active-color) transparent"}),t}function Mn(){if(typeof document>"u")return null;const e=[...Array.from(document.body.classList),...document.documentElement?Array.from(document.documentElement.classList):[]];return e.includes("dark")?"dark":e.includes("light")?"light":null}function Tn(){return typeof window>"u"?"light":window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"}const Lo={Toolbar:"toolbar",Menuitem:"menuitem"},Tt=e=>{const{closeFloat:o,closeFloatAll:n,floatReference:t,popupContainer:s,children:a,className:r,sx:c,...i}=e;return f.jsx(L.Box,{className:ye("menu",r),sx:{display:"flex",flexDirection:"column",...c},...i,children:a})},qt=(e,o,n)=>{let t;return n&&(t=(t?t+" ":"")+"rotate(180deg)"),f.jsx(Kt,{style:{marginLeft:e?void 0:o?"-0.25rem":"-3px",marginRight:e?void 0:o?"-0.25rem":"-6px",transform:t},color:"inherit"})},ln=p.memo(p.forwardRef((e,o)=>{const{open:n,anchorEl:t,anchorPosition:s,label:a,floatReference:r,createPopupPanel:c=Tt,popperProps:i,onMount:l,onClosing:m,onClose:k,onOpening:g,onOpen:x,children:w,sx:y,...h}=e,v=N.useCallbackRef(m,[m]),u=N.useCallbackRef(k,[k]),S=N.useCallbackRef(g,[g]),M=N.useCallbackRef(x,[x]),[j,$]=p.useState(),O=p.useRef(null),P=N.useCallbackRef((D,I)=>{$(D),l?.(O.current,I)},[l]),C=p.useMemo(()=>{const D={popupContainer:j,floatReference:r,children:w,...h},I=c(D);return f.jsx(L.Paper,{elevation:8,ref:O,sx:{display:"flex",overflow:"auto",outline:"none","&.MuiPaper-root":T=>sn(T)},tabIndex:0,children:I})},[c,w,j,r]);return f.jsx(an,{ref:o,anchorEl:t,anchorPosition:s,label:a,open:n,onMount:P,onOpening:S,onOpen:M,onClosing:v,onClose:u,...i,children:C})}));ln.displayName="ExhibitFloatPanel";const Be=new Map;let _t=null;const Ie=new Map;let je=null;const At=(e=null,o,n,t)=>(je&&(je.fn.clear(),je=null),e===0?o:(e===null&&(e=120),je={fn:ve.CommonUtils.debounce(()=>o(),e),setReferences:n,isClose:t},je.fn)),Vo=(e,o)=>{if(o===null)return;e.add(o);const n=Be.get(o.key);if(!n)return;const t=Ie.get(n);t&&Vo(e,t)},jn=e=>{const o=new Set;return Vo(o,e),o},ft=e=>{const{anchor:o,label:n=null,parentFloat:t=null,onOpen:s,onClose:a,popperProps:r,createPopupPanel:c=Tt}=e??{},i=N.useCallbackRef(s,[s]),l=N.useCallbackRef(a,[a]),[m,k]=p.useState(null),[g,x]=p.useState(!1),[w,y]=p.useState(!1),h=p.useMemo(()=>t===null?(_t===null&&(_t={key:{label:"root"},isRoot:!0,parent:null,open:()=>null,close:b=>null,closeChild:b=>null,onChildVisible:()=>{},onChildHidden:()=>{},closeAll:()=>z(0),floatElement:()=>null,anchorElement:()=>null}),_t):t,[]),v=p.useMemo(()=>({label:n}),[]),u=p.useRef(null),S=p.useRef(o);p.useEffect(()=>{S.current=o},[o]);const M=b=>{const E=Be.get(b);let F=null;return E&&(F=Ie.get(E)?.close(0)),F},j=()=>M(X.key),[$,O]=p.useState(),P=()=>{if(!m)return void T();const b=new Promise((E,F)=>{O(A=>({resolve:E,reject:F}))});return j(),Be.delete(h.key),k(!1),b};p.useEffect(()=>{$&&($.resolve(),O(null))},[g,w,$]);const C=p.useCallback(()=>{let b=h;for(;b.parent;)b=b.parent;return M(b.key)},[]),D=()=>{if(m)return void T();h&&Ie.get(h.key)?.open(0);const b=Be.get(h.key);b&&b!==v&&Ie.get(b)?.close(0),requestAnimationFrame(()=>{Be.set(h.key,X.key),k(!0)})},[I,T]=p.useReducer(b=>b+1,0),B=p.useCallback(b=>c===null?null:c({closeFloat:z,closeFloatAll:Z,...b}),[c]),_=c===null,V=N.useCallbackRef((b=120)=>At(b,D,new Set([X]),!1)(),[D]),z=N.useCallbackRef((b=60)=>At(b,P,jn(X),!0)(),[P]),H=N.useCallbackRef((b=360)=>At(b,j,jn((E=>{const F=Be.get(E.key);return F&&Ie.get(F)||null})(X)),!0)(),[j]),Z=N.useCallbackRef(C,[C]),X=p.useMemo(()=>({key:v,isRoot:!1,label:n,parent:h,onChildVisible:()=>{y(!0)},onChildHidden:()=>{y(!1)},open:V,close:z,closeChild:H,closeAll:Z,floatElement:()=>u.current,anchorElement:()=>S.current}),[]);p.useEffect(()=>{Ie.set(v,X)},[X]),p.useEffect(()=>()=>{Ie.delete(v),z(0)},[]),p.useEffect(()=>{m&&!_&&(x(!0),h.onChildVisible())},[m,_]);const J=p.useCallback(b=>{b.which===N.KeyCodes.Escape&&(b.preventDefault(),b.stopPropagation(),z(0))},[]),ne=p.useRef(null),oe=p.useCallback(()=>{const b=ne.current,E=u.current;b&&E&&(requestAnimationFrame(()=>{(E.contains(document.activeElement)||document.activeElement===document.body)&&b.focus()}),ne.current=null),l?.()},[]),ee=p.useCallback(b=>{u.current=b,b.addEventListener("focus",F=>{ne.current=F.relatedTarget},{once:!0,passive:!0});const E=document.activeElement;requestAnimationFrame(()=>{E===document.activeElement&&b.focus()})},[]),[re,ie]=p.useState();p.useEffect(()=>{_&&(m?i?.():m===!1&&l?.()),ie(g?f.jsx(ln,{floatReference:X,open:m,label:n,anchorEl:o,onOpening:()=>{i?.(),h.onChildVisible()},onClosing:oe,onClose:()=>{x(!1),h.onChildHidden()},onMount:ee,popperProps:{onKeyDown:J,onMouseEnter:b=>{m&&je?.isClose&&je.setReferences.has(X)&&(je.fn.clear(),je=null,X.closeChild())},...r},createPopupPanel:B}):null)},[g,m,n,_,r,B,I]);const d=N.useCallbackRef(b=>{if(Be.size===0)return;let E=!1;Be.forEach(F=>{const A=Ie.get(F);if(E||!A)return;A.floatElement()?.contains?.(b.target)&&(E=!0),A.anchorElement()?.contains?.(b.target)&&(E=!0)}),E||C()},[C]);return p.useEffect(()=>{if(!m||!h.isRoot)return;const b=E=>{d(E)};return document.addEventListener("mousedown",b),document.addEventListener("touchstart",b),document.addEventListener("focus",b),()=>{document.removeEventListener("mousedown",b),document.removeEventListener("touchstart",b),document.removeEventListener("focus",b)}},[m,h]),{component:re,reference:X}},$o=p.memo(p.forwardRef((e,o)=>{const{nestedChildren:n,variant:t,disabled:s=!1,createPopupPanel:a,...r}=e,c={disabled:s,createPopupPanel:N.useCallbackRef(i=>{if(!n||n.length===0)return null;const{popupContainer:l,floatReference:m,ref:k,...g}=i,x=[];for(let w=0;w<n.length;w++){const y=n[w];y&&x.push(f.jsx($o,{parentFloat:m,...g,...y},w))}return f.jsxs(L.Box,{ref:o,sx:{display:"flex",flexDirection:"column",paddingTop:"4px",paddingBottom:"4px"},children:["Children here",x,f.jsx(Je,{parentFloat:m,children:"Close other children"})]})},[n]),...r};return t===Lo.Toolbar?f.jsx(jt,{...c}):f.jsx(un,{...c})})),Lr={placement:"right-start"},Vr=p.memo(p.forwardRef((e,o)=>{const{children:n,sx:t,parentFloat:s,createPopupPanel:a,popperProps:r=Lr,label:c,...i}=e;(function(h){if(!h)throw new Error("Invariant failed")})(p.isValidElement(n));const l=n,m=p.useMemo(()=>({...l?.props,...i,onContextMenu:h=>{l?.props?.onContextMenu?.(h),h.isDefaultPrevented()||(i?.onContextMenu?.(h),h.isDefaultPrevented()||(x(h),h.preventDefault()))}}),[i,l?.props]),k=N.useCallbackRef(a,[a]),[g,x]=p.useState(null),{reference:w,component:y}=ft({label:c??"contextMenu",popperProps:r,parentFloat:s,anchor:{getBoundingClientRect:()=>new DOMRect(g?.clientX||0,g?.clientY||0)},onClose:()=>x(null),createPopupPanel:k});return p.useEffect(()=>{g?w.open(0):w.close(0)},[g]),f.jsxs(f.Fragment,{children:[p.cloneElement(n,m),y]})})),He=p.forwardRef((e,o)=>{const{slotProps:n,...t}=e,{getPortalContainer:s}=N.useFullscreenPortal();return f.jsx(L.Tooltip,{ref:o,slotProps:{...n,popper:{container:s,...n?.popper||{}}},...t})});He.displayName="SimpleTooltip";const nt=p.memo(e=>{const{modifier:o,sx:n,...t}=e;return f.jsx(L.Box,{sx:{marginLeft:"1px",marginRight:"1px",borderRadius:"4px",borderStyle:"solid",borderTopWidth:"1px",borderLeftWidth:"1px",borderRightWidth:"1px",borderBottomWidth:"2px",borderTopColor:s=>se.alpha(s.palette.background.paper,s.palette.action.disabledOpacity),borderLeftColor:s=>se.alpha(s.palette.background.paper,s.palette.action.disabledOpacity),borderRightColor:s=>se.alpha(s.palette.background.paper,s.palette.action.disabledOpacity),borderBottomColor:s=>se.alpha(s.palette.background.paper,1-s.palette.action.disabledOpacity),backgroundColor:s=>se.alpha(s.palette.action.hover,s.palette.action.disabledOpacity),paddingLeft:"4px",paddingRight:"4px",minHeight:"1.6em",display:"flex",justifyContent:"center",alignItems:"center",boxSizing:"content-box",overflow:"hidden",...n},...t,children:f.jsx(L.Box,{sx:{display:"flex",alignItems:"center",justifyContent:"center",textAlign:"center","& *":{fontWeight:"500"}},children:o})})}),$r=ve.CommonUtils.getOS()===ve.CommonUtils.OSType.MacOS||ve.CommonUtils.getOS()===ve.CommonUtils.OSType.IOS?"Cmd":"Ctrl",cn=(e,o=!1,n=null)=>{if(Array.isArray(e)){let a=[],r=e;for(let c=0;c<r.length;c++)a.push(cn(r[c],o,n??""+c));return f.jsx(L.Box,{sx:{display:"flex",alignItems:"center",flexDirection:"column"},children:a},n)}if(!e?.key)return null;const t={};for(let a=0;e.modifiers&&a<e.modifiers.length;a++)t[e.modifiers[a]]=!0;const s=[];return t?.[N.KeyModifiers.Ctrl]&&(s.push(f.jsx(nt,{modifier:o?"^":f.jsx("div",{style:{paddingRight:"1px"},children:$r})},"ctrl")),s.push("+")),t?.[N.KeyModifiers.Alt]&&(s.push(f.jsx(nt,{modifier:o?"⌥":"Alt"},"alt")),s.push("+")),t?.[N.KeyModifiers.Shift]&&(s.push(f.jsx(nt,{modifier:o?"⇧":f.jsx("div",{style:{paddingRight:"1px"},children:"Shift"})},"shift")),s.push("+")),t?.[N.KeyModifiers.Meta]&&(s.push(f.jsx(nt,{modifier:o?f.jsx("div",{style:{paddingTop:"1px"},children:"⌘"}):"Meta"},"meta")),s.push("+")),s.push(f.jsx(nt,{modifier:N.ReactUtils.toPrettyKeyCode(e.key)},"character")),f.jsx(L.Box,{sx:{display:"flex",alignItems:"center"},children:s},n)},Ke=p.memo(p.forwardRef((e,o)=>{const{disabled:n=!1,label:t,shortcut:s,chips:a,description:r,maxWidth:c=280,useModifierSymbols:i=!1,children:l,simple:m,componentDisabled:k=!1,sx:g,...x}=e;let w=null;s&&(w=cn(s,i));const[y,h]=p.useState(null);p.useEffect(()=>{Promise.resolve(t).then(u=>{h(u)})},[t]);const v=f.jsxs(L.Box,{sx:{maxWidth:`${c}px`},ref:o,children:[f.jsxs(L.Box,{sx:{display:"flex",flexDirection:"row",marginBottom:r?"4px":"0px"},children:[f.jsx(L.Typography,{variant:"subtitle1",component:"div",flex:"1 1 100%",children:y}),a?f.jsx(nn,{chips:a}):null,w?f.jsx(L.Box,{sx:{marginLeft:"8px"}},"leadingSpace"):f.jsx(f.Fragment,{}),w]}),r?f.jsx(L.Typography,{variant:"caption",sx:{whiteSpace:"pre-line",lineHeight:"1.4"},children:r}):f.jsx(f.Fragment,{})]});return f.jsx(He,{slotProps:{popper:{sx:{"& .MuiTooltip-tooltip":{marginTop:"0px !important"},...g},modifiers:[{name:"offset",options:{offset:[0,14]}}]}},className:"tooltip-wrapper",tabIndex:-1,title:!n&&y?v:"",enterDelay:260,enterNextDelay:130,leaveDelay:230,disableInteractive:!0,...x,children:f.jsx("div",{style:{display:"flex",alignItems:"stretch",justifyContent:"stretch"},children:l})})})),zr=f.jsx(N.DynamicIcon,{}),Wr=f.jsx(N.DynamicIcon,{iconKey:"Check"}),mt=p.memo(p.forwardRef((e,o)=>{const{dense:n=!0,outlined:t=!1,disableHover:s=!1,parentFloat:a,selected:r,icon:c,tooltipProps:i,children:l,primary:m,sx:k,disabled:g,className:x,onFocus:w,onBlur:y,...h}=e,[v,u]=p.useState(!1),S={marginRight:"0px",padding:n?"2px":"7px",borderRadius:P=>`${P.shape.borderRadius}px`,color:P=>m?void 0:P.palette.text.icon??P.palette.action.active,border:P=>`solid ${t?P.palette.divider:"transparent"} 1px`,"& .MuiTouchRipple-child":{borderRadius:P=>`${P.shape.borderRadius}px !important`},"&.Mui-selected":{backgroundColor:P=>se.alpha(P.palette.text.primary,P.palette.action.selectedOpacity),border:P=>`solid ${t?P.palette.text?.primary:P.palette.divider} 1px`},"&.Mui-disabled":{border:P=>`solid ${t?P.palette.divider:"transparent"} 1px`},"&.Mui-disabled > .icon path":{filter:"grayscale(65%)",opacity:".8"},"&.Mui-focusVisible":{outline:"solid transparent 1px",border:"1px solid transparent"},...k},M={"&:hover:not(.Mui-disabled, [disabled])":{color:P=>P.palette.text.primary,border:P=>`solid ${t?P.palette.text?.primary:P.palette.divider} 1px`,"&.Mui-selected":{backgroundColor:P=>se.alpha(P.palette.text.primary,P.palette.action.selectedOpacity+P.palette.action.hoverOpacity)},"> .outline-hover":{outline:P=>`solid ${t?P.palette.text?.primary:P.palette.divider} 1px`},backgroundColor:null},"&.Mui-focusVisible":{outline:P=>`solid ${P.palette.primary.main} 1px`,border:P=>`1px solid ${P.palette?.primary?.main}`,zIndex:1}};let j=S;s||(j=ve.CommonUtils.mergeContentful(S,M));const $=p.useMemo(()=>{let P=typeof c=="function"?c():c;return P===null?P:P||(r===void 0?zr:Wr)},[c,r]);let O=f.jsxs(L.IconButton,{component:"div",ref:o,className:ye({"Mui-focusVisible":v,"Mui-selected":r,"Mui-disabled":g},x),onFocus:P=>{u(!0),w?.(P)},onBlur:P=>{u(!1),y?.(P)},size:"small",TouchRippleProps:{center:!1},sx:j,edge:"end",...h,disabled:g||!1,children:[$,l]});if(i)if(i.simple&&i.label&&!i.disabled){const{label:P,description:C,maxWidth:D,shortcut:I,useModifierSymbols:T,componentDisabled:B,simple:_,chips:V,ref:z,...H}=i;O=f.jsx(He,{disableInteractive:!0,title:P??"",...H,children:f.jsx(L.Box,{sx:{display:"flex"},children:O})})}else O=f.jsx(Ke,{children:O,...i});return O})),Ur=f.jsx(N.DynamicIcon,{}),Hr=e=>e.icon,Je=p.memo(p.forwardRef((e,o)=>{const{icon:n=Ur,renderIcon:t=Hr,parentFloat:s,className:a,onFocus:r,selected:c,onBlur:i,onMouseOver:l,onMouseOut:m,onMouseEnter:k,disabled:g,children:x,sx:w,tooltipProps:y,chips:h,primary:v,...u}=e,[S,M]=p.useState(!1),[j,$]=p.useState(!1),O=p.useMemo(()=>{const C=t?.({icon:n,disabled:g,selected:c});return C?f.jsx(L.ListItemIcon,{className:ye({"Mui-focusVisible":S,"Mui-hovered":j}),sx:{"& .MuiSvgIcon-root":{color:D=>v?void 0:D.palette.text.icon??D.palette.action.active},"&.Mui-hovered:not(.Mui-disabled, [disabled])":{"& .MuiSvgIcon-root":{color:D=>D.palette.text.primary}}},children:C}):null},[t,g,n,S,j,v,c]);let P=f.jsxs(L.MenuItem,{ref:o,disabled:g,onMouseOver:C=>{l?.(C),C.isDefaultPrevented()||$(!0)},onMouseOut:C=>{m?.(C),C.isDefaultPrevented()||$(!1)},onMouseEnter:C=>{k?.(C),C.isDefaultPrevented()||s?.closeChild()},TouchRippleProps:{center:!1},className:ye({"Mui-focusVisible":S,"Mui-hovered":j},a),onFocus:C=>{r?.(C),M(!0)},onBlur:C=>{i?.(C),M(!1)},sx:{flex:"1 1 100%","&.Mui-disabled > .icon path":{filter:"grayscale(65%)"},"&.Mui-selected":{color:C=>C.palette.text.primary},color:C=>C.palette.text.secondary,"&.Mui-hovered:not(.Mui-disabled, [disabled])":{color:C=>C.palette.text.primary},...w},...u,children:[O,x,h?f.jsx(nn,{chips:h}):null]});return y&&(P=f.jsx(Ke,{children:P,placement:"right-start",...y})),P})),Kr=p.memo(p.forwardRef((e,o)=>{const{children:n,sx:t,primary:s=!1,variant:a="subtitle1",...r}=e;return f.jsx(f.Fragment,{children:f.jsx(L.Typography,{ref:o,variant:a,component:"div",sx:{userSelect:"none",fontWeight:"500",paddingLeft:"8px",paddingTop:a==="subtitle1"?"2px":void 0,paddingBottom:a==="subtitle1"?"2px":void 0,color:c=>s?void 0:c.palette.text.secondary,...t},...r,children:n})})})),jt=p.memo(p.forwardRef((e,o)=>{const{dense:n=!0,outlined:t=!1,label:s,selected:a=!1,onQuickClick:r,parentFloat:c,createPopupPanel:i,popupProps:l,onPopupOpen:m,onPopupClose:k,quickButtonProps:g,createQuickButton:x,tooltip:w="",createTooltip:y,icon:h,disabled:v,buttonProps:u=ve.CommonUtils.EmptyObject,disableHover:S,touchRippleRef:M,primary:j,children:$,sx:O,className:P,...C}=e,D=We.useTheme(),I=p.useMemo(()=>{const Q=(te,ae,ue,Oe=ue)=>{const be=typeof t=="boolean"?null:t[te];return typeof be=="function"?be(ae):be||(t?ue:Oe)};return{outline:{color:te=>Q("color",te,te.palette.divider,"transparent"),hoverColor:te=>Q("hoverColor",te,te.palette.text?.primary,te.palette.divider),focusColor:te=>Q("focusColor",te,te.palette?.primary?.main)},active:D.palette.mode==="dark"?D.palette.text.secondary:D.palette.text.primary,text:D.palette.text.icon??D.palette.action.active}},[t,D]),[T,B]=p.useState(!1),[_,V]=p.useState(!1),[z,H]=p.useState(!1),Z=p.useRef(null),X=p.useRef(null),J=ft({anchor:Z.current,label:s,createPopupPanel:i,parentFloat:c,popperProps:l?.popperProps,onClose:()=>{B(!1),k?.()},onOpen:()=>{B(!0),m?.()}}),ne=N.useCallbackRef(Q=>{r?.(Q),J.reference.close(0)},[r,J]),oe=N.useCallbackRef(()=>{T?J.reference.close(0):J.reference.open(0)},[T,J,c,s]),ee=p.useMemo(()=>{const Q={"&.bordered":{borderWidth:"1px",borderRadius:"0px",borderTopStyle:"solid",borderBottomStyle:"solid",borderColor:G=>I.outline.color(G),"&.Mui-focusVisible":{border:G=>`1px solid ${I.outline.focusColor(G)} !important`},"&:hover:not(.Mui-disabled, [disabled])":{borderColor:()=>S?"transparent":void 0,backgroundColor:()=>S?"transparent":void 0},"&.Mui-hovered:not(.Mui-disabled, [disabled])":{borderColor:G=>I.outline.hoverColor(G)},"&.Mui-selected:not(.Mui-disabled, [disabled])":{borderColor:G=>I.outline.hoverColor(G)},"&.left":{borderTopLeftRadius:G=>`${G.shape.borderRadius}px`,borderBottomLeftRadius:G=>`${G.shape.borderRadius}px`,borderLeftStyle:"solid"},"&.hard-right":{borderRightStyle:"solid",borderRightWidth:"1px",borderRightColor:G=>I.outline.color(G)},"&.right":{borderTopRightRadius:G=>`${G.shape.borderRadius}px`,borderBottomRightRadius:G=>`${G.shape.borderRadius}px`,borderRightStyle:"solid"},"&.divider":{borderLeftWidth:"0px !important"}},"& .MuiTouchRipple-child":{borderRadius:G=>`${G.shape.borderRadius}px !important`}},te={"&.Mui-selected":{backgroundColor:G=>se.alpha(G.palette.primary.main,G.palette.action.selectedOpacity),"&:hover:not(.Mui-disabled)":{backgroundColor:G=>se.alpha(G.palette.primary.main,G.palette.action.selectedOpacity+G.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:G=>se.alpha(G.palette.primary.main,G.palette.action.selectedOpacity)}}}},ae={maxHeight:"100%","&.Mui-selected":{backgroundColor:G=>se.alpha(G.palette.text.icon??G.palette.action.active,G.palette.action.selectedOpacity),"&:hover:not(.Mui-disabled)":{backgroundColor:G=>se.alpha(G.palette.text.icon??G.palette.action.active,G.palette.action.selectedOpacity+G.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:G=>se.alpha(G.palette.text.icon??G.palette.action.active,G.palette.action.selectedOpacity)}}},"&:hover:not(.Mui-disabled, [disabled])":{color:G=>G.palette.text.primary},backgroundColor:()=>S?"transparent":void 0,color:G=>G.palette.text.icon,"&.Mui-disabled > .icon path":{filter:"grayscale(65%)",opacity:".8"},padding:()=>n?"2px 3px":"7px",marginRight:"0"},ue=ve.CommonUtils.mergeContentful(ae,Q),Oe=ve.CommonUtils.mergeContentful(ue,te),be=ve.CommonUtils.mergeContentful(ae,Q);return{quickButtonStyling:ue,openQuickButtonStyling:Oe,compoundStyling:be,openCompoundStyling:ve.CommonUtils.mergeContentful(be,te)}},[I,S]),re=N.useCallbackRef(Q=>{const{children:te,ref:ae,...ue}=Q;return f.jsx(He,{ref:ae,...ue,disableInteractive:!0,children:te})},[]),ie=r||x,d=ie&&(g?.tooltip||g?.createTooltip),b=Q=>{const{tooltip:te,createTooltip:ae,sx:ue,...Oe}=Q;let be=f.jsx(L.IconButton,{sx:{...ue},component:"div",...Oe});return d&&(be=(ae??re)({title:T?"":te??w,children:f.jsx("div",{children:be})},T)),be},E={onKeyDown:Q=>{Q.keyCode===N.KeyCodes.Space?oe():Q.keyCode===N.KeyCodes.F4||Q.keyCode===N.KeyCodes.Down?J.reference.open(0):Q.keyCode===N.KeyCodes.Up&&J.reference.close(0)}};let F=f.jsx(f.Fragment,{});const A=p.useMemo(()=>typeof h=="function"?h():h,[h]);if(ie){let Q=T?ee.openQuickButtonStyling:ee.quickButtonStyling;const te=(x||b)({tabIndex:-1,disabled:v,size:"small",edge:"end",onMouseEnter:()=>{J.reference.parent.closeChild()},onMouseDown:ue=>{ue.button===0&&(ue.preventDefault(),ne(ue))},touchRippleRef:M,children:A,...g,className:ye({"Mui-focusVisible":_||T,"Mui-selected":a,"Mui-hovered":z||T,"Mui-disabled":v,bordered:!0,left:!0,"hard-right":!0},g?.className),sx:{...ee.quickButtonStyling,height:"100%",...g?.sx}});let ae=qt(!0,n,T);d&&(ae=(y??re)({title:T?"":w,children:ae},T)),F=f.jsxs(f.Fragment,{children:[te,f.jsx(L.IconButton,{ref:X,component:"div",className:ye({"Mui-selected":T,"Mui-hovered":z||T,"Mui-disabled":v,"Mui-focusVisible":_||T,bordered:!0,right:!0,divider:!0}),sx:{paddingLeft:(n?0:2)+"px",paddingRight:(n?0:2)+"px",width:()=>"calc(var(--icon-size, 1.25em) * 0.8)",...ee.quickButtonStyling,...Q},TouchRippleProps:{center:!1},tabIndex:-1,disabled:v,size:"small",edge:"end",onMouseDown:ue=>{ue.button===0&&(ue.preventDefault(),oe())},children:ae})]})}else{let Q=T?ee.openCompoundStyling:ee.compoundStyling;F=f.jsx(mt,{ref:X,tabIndex:-1,disabled:v,size:"small",icon:A,className:ye({"Mui-selected":T||a,"Mui-hovered":z,"Mui-disabled":v,"Mui-focusVisible":_||T,bordered:!0,left:!0,right:!0}),sx:{...ee.quickButtonStyling,...Q},onMouseDown:te=>{te.button===0&&(te.preventDefault(),oe())},children:qt(!1,n,T)})}const{className:R,sx:W,...Y}=u;let q=f.jsx(L.Box,{onFocus:()=>V(!0),onBlur:()=>V(!1),onMouseOver:()=>H(!0),onMouseOut:()=>H(!1),...E,"aria-label":"split button",ref:Z,tabIndex:v?void 0:0,className:ye(R,"split-button-root",{"Mui-focusVisible":_||T,"Mui-selected":T||a,"Mui-hovered":z,"Mui-disabled":v}),sx:{display:"flex",flex:"1 1 100%",alignItems:"stretch",width:"fit-content","&:not(.Mui-disabled)":{cursor:"pointer"},marginLeft:t?"1px":"0px",marginRight:t?"1px":"0px",borderRadius:Q=>`${Q.shape.borderRadius}px`,"&.Mui-focusVisible":{outline:Q=>`solid ${Q.palette.primary.main} 1px`,zIndex:2},...W},...Y,children:F});return d||(q=(y??re)({title:T?"":w,children:q},T)),f.jsxs(L.Box,{className:ye(P,"popupIconButton"),ref:o,...C,sx:{zIndex:_||T?2:void 0,display:"flex",alignItems:"center",...O},children:[q,J.component]})}));jt.displayName="ExhibitPopupIconButton";const Yr={},un=p.memo(p.forwardRef((e,o)=>{const{selected:n=!1,label:t,onQuickClick:s,parentFloat:a,createPopupPanel:r,popupProps:c=Yr,onPopupOpen:i,onPopupClose:l,quickButtonProps:m,createQuickButton:k,tooltip:g="",createTooltip:x,icon:w,disabled:y,touchRippleRef:h,primary:v,children:u,sx:S,...M}=e,[j,$]=p.useState(!1),[O,P]=p.useState(!1),[C,D]=p.useState(!1),[I,T]=p.useState(!1),B=p.useRef(null),_=p.useRef(null),V=p.useMemo(()=>{if(!c)return;const{popperProps:d}=c;return{placement:"right-start",offsets:[-4,-2],...d}},[c]),z=ft({anchor:B.current,label:t,createPopupPanel:r,parentFloat:a,popperProps:V,onClose:()=>{$(!1),l?.()},onOpen:()=>{$(!0),i?.()}}),H=N.useCallbackRef(d=>{d.button===0&&(s?.(d),z.reference.close(0))},[s]),Z=f.jsx(Io,{}),X={"&.Mui-selected":{color:d=>d.palette.text.primary,"& svg * ":{color:d=>d.palette.text.primary}}},J=p.useCallback(d=>{const{children:b,ref:E,...F}=d;return f.jsx(He,{ref:E,...F,disableInteractive:!0,children:b})},[]),ne=s||k,oe=d=>{const{tooltip:b,createTooltip:E,...F}=d;return f.jsx(Je,{icon:w,className:ye({"Mui-hovered":C}),sx:{flex:"1 1 100%",...X},...F,children:t})},ee={onFocus:()=>{P(!0)},onBlur:()=>P(!1),onMouseOver:()=>{D(!0)},onMouseLeave:()=>{D(!1)},onMouseEnter:()=>{z.reference.open()},onMouseDown:d=>{d.button===0&&d.preventDefault()}};let re=f.jsx(f.Fragment,{});if(ne){const d=(k||oe)({tabIndex:-1,disabled:y,onMouseEnter:()=>{z.reference.parent.closeChild()},onMouseDown:b=>{b.button===0&&(b.preventDefault(),H(b))},className:ye("quick-left",{},m?.className),...m});re=f.jsxs(f.Fragment,{children:[d,f.jsx(L.Divider,{sx:{ml:"0px",mr:"0px"},orientation:"vertical",variant:"middle",flexItem:!0}),f.jsx(L.MenuItem,{ref:_,className:ye({"Mui-selected":j,"Mui-hovered":C}),sx:{borderTopLeftRadius:"0px",borderBottomLeftRadius:"0px",paddingLeft:"0px",paddingRight:"0px",marginLeft:"0px",color:b=>v?void 0:b.palette.text.secondary,"&.Mui-hovered:not(.Mui-disabled, [disabled])":{color:b=>b.palette.text.primary},...X},tabIndex:-1,disabled:y,...ee,children:f.jsx(L.Box,{className:"expand-icon",sx:{flex:"none",display:"flex",border:"1px solid transparent",paddingTop:"1px",paddingBottom:"1px",color:b=>v?void 0:b.palette.text.icon??b.palette.action.active},onMouseOver:b=>{b.preventDefault(),T(!0)},onMouseLeave:()=>{T(!1)},onClick:b=>{b.preventDefault(),j?z.reference.close():z.reference.open()},children:Z})})]})}else re=f.jsxs(Je,{ref:_,tabIndex:-1,disabled:y,icon:w,className:ye({"Mui-selected":j||n,"Mui-hovered":C}),sx:{flex:"1 1 100%",paddingRight:"0px",...X},onClick:d=>{d.preventDefault(),j?z.reference.close():z.reference.open()},...ee,children:[f.jsx("div",{style:{flex:"1 1 100%"},children:t}),f.jsx(L.Box,{className:"expand-icon",sx:{flex:"none",display:"flex",color:d=>v?void 0:d.palette.text.icon??d.palette.action.active},children:Z})]});let ie=f.jsx(L.Box,{"aria-label":"split button",ref:B,tabIndex:y?void 0:0,className:ye({"Mui-disabled":y,"Mui-selected":j,"Mui-focusVisible":O||j,"Mui-hovered":C}),sx:{display:"flex",flex:"1 1 100%",alignItems:"center",width:"fit-content","& .quick-left":{borderTopRightRadius:"0px",borderBottomRightRadius:"0px",marginRight:"-1px"},"&.Mui-disabled > .icon path":{filter:"grayscale(65%)"},...S},...M,children:re});return ne&&!I&&(m?.tooltip||m?.createTooltip)&&(ie=(m?.createTooltip??J)({title:j?"":ie??m?.tooltip,children:ie},j)),f.jsxs(L.Box,{ref:o,sx:{zIndex:O||j?2:void 0,display:"flex"," .tooltip-wrapper":{display:"flex",flex:"1 1 100%"}},children:[ie,z.component]})})),qr=p.memo(p.forwardRef((e,o)=>{const{onSelectToggle:n,selected:t=!1,label:s,shortcut:a,tabIndex:r=0,preventFocus:c=!1,...i}=e;return f.jsx(Ke,{label:s,shortcut:a,children:f.jsx(mt,{ref:o,outlined:!1,tabIndex:r,selected:t,onMouseDown:l=>{c&&l.preventDefault()},onClick:()=>{n?.(!t)},...i})})})),Gr=f.jsx(N.DynamicIcon,{}),Xr=f.jsx(N.DynamicIcon,{iconKey:"Check"}),zo=p.memo(p.forwardRef((e,o)=>{const{children:n,selected:t=!0,outlined:s=!0,sx:a,...r}=e,c={display:"flex",border:l=>t?`solid ${s?l.palette.divider:"transparent"} 1px`:"solid transparent 1px",borderRadius:l=>`${l.shape.borderRadius}px`,backgroundColor:l=>{if(t)return se.alpha(l.palette.text.icon??l.palette.action.active,l.palette.action.selectedOpacity)}};let i=n;return i===null&&(i=Gr),i||(i=Xr),f.jsx(L.Box,{ref:o,sx:{...c,...a},...r,children:i})}));function xe(){return xe=Object.assign?Object.assign.bind():function(e){for(var o=1;o<arguments.length;o++){var n=arguments[o];for(var t in n)({}).hasOwnProperty.call(n,t)&&(e[t]=n[t])}return e},xe.apply(null,arguments)}function Wo(e,o){if(e==null)return{};var n={};for(var t in e)if({}.hasOwnProperty.call(e,t)){if(o.indexOf(t)!==-1)continue;n[t]=e[t]}return n}var Ce,Qr={state:{},updateModal:function(){},hideModal:function(){},destroyModal:function(){},destroyModalsByRootId:function(){},showModal:function(){return{id:"id",hide:function(){},destroy:function(){},update:function(){}}}},Uo=p.createContext(void 0);(function(e){e.SHOW="SHOW",e.HIDE="HIDE",e.UPDATE="UPDATE",e.DESTROY="DESTROY",e.DESTROY_BY_ROOT_ID="DESTROY_BY_ROOT_ID",e.UNKNOWN="UNKNOWN"})(Ce||(Ce={}));var Jr={};function Zr(e,o){switch(o.type){case Ce.SHOW:var n,t=o.payload,s=t.id,a=t.component,r=t.props,c=t.options;return xe({},e,((n={})[s]={component:a,props:xe({},r,{open:!0}),options:c},n));case Ce.HIDE:var i,l=o.payload.id;return e[l]?xe({},e,((i={})[l]=xe({},e[l],{props:xe({},e[l].props,{open:!1})}),i)):e;case Ce.UPDATE:var m,k=o.payload,g=k.id,x=k.props;return e[g]?xe({},e,((m={})[g]=xe({},e[g],{props:xe({},e[g].props,x)}),m)):e;case Ce.DESTROY:var w=o.payload.id,y=xe({},e);return delete y[w],y;case Ce.DESTROY_BY_ROOT_ID:var h=o.payload.rootId;return Object.keys(e).filter(function(v){return v.split(".")[0]!==h}).reduce(function(v,u){var S;return xe({},v,((S={})[u]=e[u],S))},{});default:throw new Error("Unexpected action")}}var Lt="[ERROR]: Modal ID is missing",Ho=function(e){e===void 0&&(e=8);for(var o=[],n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",t=0;t<e;t++)o[t]=n.charAt(Math.floor(62*Math.random()));return o.join("")},ei=["open"],Ko={enforceProvider:!1};function Yo(){return Ko}var ti=["showModal","destroyModalsByRootId"],Pn={disableAutoDestroy:!1};function ht(e){e===void 0&&(e=Pn);var o=xe({},Pn,e).disableAutoDestroy,n=(function(){var c=p.useContext(Uo);if(Yo().enforceProvider&&c===void 0)throw new Error("useModalContext must be used within a ModalProvider");return c||Qr})(),t=n.showModal,s=n.destroyModalsByRootId,a=Wo(n,ti),r=p.useRef(Ho(6));return p.useEffect(function(){return function(){!o&&s&&s(r.current)}},[o,s]),xe({showModal:p.useCallback(function(c,i,l){return t(c,i,xe({rootId:r.current,hideOnClose:!0},l))},[t]),destroyModalsByRootId:s},a)}var Rn,Fn,Nn,Bn,In,_n={exports:{}};function ni(){return Fn?Rn:(Fn=1,Rn="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}function oi(){if(Bn)return Nn;Bn=1;var e=ni();function o(){}function n(){}return n.resetWarningCache=o,Nn=function(){function t(r,c,i,l,m,k){if(k!==e){var g=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw g.name="Invariant Violation",g}}function s(){return t}t.isRequired=t;var a={array:t,bigint:t,bool:t,func:t,number:t,object:t,string:t,symbol:t,any:t,arrayOf:s,element:t,elementType:t,instanceOf:s,node:t,objectOf:s,oneOf:s,oneOfType:s,shape:s,exact:s,checkPropTypes:n,resetWarningCache:o};return a.PropTypes=a,a}}function dn(){return In||(In=1,_n.exports=oi()()),_n.exports}var qo=["input:not([inert])","select:not([inert])","textarea:not([inert])","a[href]:not([inert])","button:not([inert])","[tabindex]:not(slot):not([inert])","audio[controls]:not([inert])","video[controls]:not([inert])",'[contenteditable]:not([contenteditable="false"]):not([inert])',"details>summary:first-of-type:not([inert])","details:not([inert])"],St=qo.join(","),Go=typeof Element>"u",Ue=Go?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,xt=!Go&&Element.prototype.getRootNode?function(e){var o;return e==null||(o=e.getRootNode)===null||o===void 0?void 0:o.call(e)}:function(e){return e?.ownerDocument},Ct=function e(o,n){var t;n===void 0&&(n=!0);var s=o==null||(t=o.getAttribute)===null||t===void 0?void 0:t.call(o,"inert");return s===""||s==="true"||n&&o&&e(o.parentNode)},Xo=function(e,o,n){if(Ct(e))return[];var t=Array.prototype.slice.apply(e.querySelectorAll(St));return o&&Ue.call(e,St)&&t.unshift(e),t=t.filter(n)},Qo=function e(o,n,t){for(var s=[],a=Array.from(o);a.length;){var r=a.shift();if(!Ct(r,!1))if(r.tagName==="SLOT"){var c=r.assignedElements(),i=e(c.length?c:r.children,!0,t);t.flatten?s.push.apply(s,i):s.push({scopeParent:r,candidates:i})}else{Ue.call(r,St)&&t.filter(r)&&(n||!o.includes(r))&&s.push(r);var l=r.shadowRoot||typeof t.getShadowRoot=="function"&&t.getShadowRoot(r),m=!Ct(l,!1)&&(!t.shadowRootFilter||t.shadowRootFilter(r));if(l&&m){var k=e(l===!0?r.children:l.children,!0,t);t.flatten?s.push.apply(s,k):s.push({scopeParent:r,candidates:k})}else a.unshift.apply(a,r.children)}}return s},Jo=function(e){return!isNaN(parseInt(e.getAttribute("tabindex"),10))},_e=function(e){if(!e)throw new Error("No node provided");return e.tabIndex<0&&(/^(AUDIO|VIDEO|DETAILS)$/.test(e.tagName)||(function(o){var n,t=o==null||(n=o.getAttribute)===null||n===void 0?void 0:n.call(o,"contenteditable");return t===""||t==="true"})(e))&&!Jo(e)?0:e.tabIndex},ri=function(e,o){return e.tabIndex===o.tabIndex?e.documentOrder-o.documentOrder:e.tabIndex-o.tabIndex},Zo=function(e){return e.tagName==="INPUT"},ii=function(e){return(function(o){return Zo(o)&&o.type==="radio"})(e)&&!(function(o){if(!o.name)return!0;var n,t=o.form||xt(o),s=function(r){return t.querySelectorAll('input[type="radio"][name="'+r+'"]')};if(typeof window<"u"&&window.CSS!==void 0&&typeof window.CSS.escape=="function")n=s(window.CSS.escape(o.name));else try{n=s(o.name)}catch(r){return console.error("Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s",r.message),!1}var a=(function(r,c){for(var i=0;i<r.length;i++)if(r[i].checked&&r[i].form===c)return r[i]})(n,o.form);return!a||a===o})(e)},An=function(e){var o=e.getBoundingClientRect(),n=o.width,t=o.height;return n===0&&t===0},ai=function(e,o){var n=o.displayCheck,t=o.getShadowRoot;if(getComputedStyle(e).visibility==="hidden")return!0;var s=Ue.call(e,"details>summary:first-of-type")?e.parentElement:e;if(Ue.call(s,"details:not([open]) *"))return!0;if(n&&n!=="full"&&n!=="legacy-full"){if(n==="non-zero-area")return An(e)}else{if(typeof t=="function"){for(var a=e;e;){var r=e.parentElement,c=xt(e);if(r&&!r.shadowRoot&&t(r)===!0)return An(e);e=e.assignedSlot?e.assignedSlot:r||c===e.ownerDocument?r:c.host}e=a}if((function(i){var l,m,k,g,x=i&&xt(i),w=(l=x)===null||l===void 0?void 0:l.host,y=!1;if(x&&x!==i)for(y=!!((m=w)!==null&&m!==void 0&&(k=m.ownerDocument)!==null&&k!==void 0&&k.contains(w)||i!=null&&(g=i.ownerDocument)!==null&&g!==void 0&&g.contains(i));!y&&w;){var h,v,u;y=!((v=w=(h=x=xt(w))===null||h===void 0?void 0:h.host)===null||v===void 0||(u=v.ownerDocument)===null||u===void 0||!u.contains(w))}return y})(e))return!e.getClientRects().length;if(n!=="legacy-full")return!0}return!1},Dt=function(e,o){return!(o.disabled||Ct(o)||(function(n){return Zo(n)&&n.type==="hidden"})(o)||ai(o,e)||(function(n){return n.tagName==="DETAILS"&&Array.prototype.slice.apply(n.children).some(function(t){return t.tagName==="SUMMARY"})})(o)||(function(n){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(n.tagName))for(var t=n.parentElement;t;){if(t.tagName==="FIELDSET"&&t.disabled){for(var s=0;s<t.children.length;s++){var a=t.children.item(s);if(a.tagName==="LEGEND")return!!Ue.call(t,"fieldset[disabled] *")||!a.contains(n)}return!0}t=t.parentElement}return!1})(o))},Gt=function(e,o){return!(ii(o)||_e(o)<0||!Dt(e,o))},si=function(e){var o=parseInt(e.getAttribute("tabindex"),10);return!!(isNaN(o)||o>=0)},li=function e(o){var n=[],t=[];return o.forEach(function(s,a){var r=!!s.scopeParent,c=r?s.scopeParent:s,i=(function(m,k){var g=_e(m);return g<0&&k&&!Jo(m)?0:g})(c,r),l=r?e(s.candidates):c;i===0?r?n.push.apply(n,l):n.push(c):t.push({documentOrder:a,tabIndex:i,item:s,isScope:r,content:l})}),t.sort(ri).reduce(function(s,a){return a.isScope?s.push.apply(s,a.content):s.push(a.content),s},[]).concat(n)},er=function(e,o){var n;return n=(o=o||{}).getShadowRoot?Qo([e],o.includeContainer,{filter:Gt.bind(null,o),flatten:!1,getShadowRoot:o.getShadowRoot,shadowRootFilter:si}):Xo(e,o.includeContainer,Gt.bind(null,o)),li(n)},tr=function(e,o){return(o=o||{}).getShadowRoot?Qo([e],o.includeContainer,{filter:Dt.bind(null,o),flatten:!0,getShadowRoot:o.getShadowRoot}):Xo(e,o.includeContainer,Dt.bind(null,o))},Ve=function(e,o){if(o=o||{},!e)throw new Error("No node provided");return Ue.call(e,St)!==!1&&Gt(o,e)},ci=qo.concat("iframe").join(","),wt=function(e,o){if(o=o||{},!e)throw new Error("No node provided");return Ue.call(e,ci)!==!1&&Dt(o,e)};const ui=Object.freeze(Object.defineProperty({__proto__:null,focusable:tr,getTabIndex:_e,isFocusable:wt,isTabbable:Ve,tabbable:er},Symbol.toStringTag,{value:"Module"}));function Vt(e,o){(o==null||o>e.length)&&(o=e.length);for(var n=0,t=Array(o);n<o;n++)t[n]=e[n];return t}function di(e,o,n){return(o=(function(t){var s=(function(a,r){if(typeof a!="object"||!a)return a;var c=a[Symbol.toPrimitive];if(c!==void 0){var i=c.call(a,r);if(typeof i!="object")return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return(r==="string"?String:Number)(a)})(t,"string");return typeof s=="symbol"?s:s+""})(o))in e?Object.defineProperty(e,o,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[o]=n,e}function Ln(e,o){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);o&&(t=t.filter(function(s){return Object.getOwnPropertyDescriptor(e,s).enumerable})),n.push.apply(n,t)}return n}function Vn(e){for(var o=1;o<arguments.length;o++){var n=arguments[o]!=null?arguments[o]:{};o%2?Ln(Object(n),!0).forEach(function(t){di(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ln(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function pi(e){return(function(o){if(Array.isArray(o))return Vt(o)})(e)||(function(o){if(typeof Symbol<"u"&&o[Symbol.iterator]!=null||o["@@iterator"]!=null)return Array.from(o)})(e)||(function(o,n){if(o){if(typeof o=="string")return Vt(o,n);var t={}.toString.call(o).slice(8,-1);return t==="Object"&&o.constructor&&(t=o.constructor.name),t==="Map"||t==="Set"?Array.from(o):t==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?Vt(o,n):void 0}})(e)||(function(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
9
9
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}var fi=function(e,o){if(e.length>0){var n=e[e.length-1];n!==o&&n._setPausedState(!0)}var t=e.indexOf(o);t===-1||e.splice(t,1),e.push(o)},mi=function(e,o){var n=e.indexOf(o);n!==-1&&e.splice(n,1),e.length>0&&!e[e.length-1]._isManuallyPaused()&&e[e.length-1]._setPausedState(!1)},ct=function(e){return e?.key==="Tab"||e?.keyCode===9},hi=function(e){return ct(e)&&!e.shiftKey},yi=function(e){return ct(e)&&e.shiftKey},$n=function(e){return setTimeout(e,0)},ot=function(e){for(var o=arguments.length,n=new Array(o>1?o-1:0),t=1;t<o;t++)n[t-1]=arguments[t];return typeof e=="function"?e.apply(void 0,n):e},yt=function(e){return e.target.shadowRoot&&typeof e.composedPath=="function"?e.composedPath()[0]:e.target},gi=[];const bi=Object.freeze(Object.defineProperty({__proto__:null,createFocusTrap:function(e,o){var n,t=o?.document||document,s=o?.trapStack||gi,a=Vn({returnFocusOnDeactivate:!0,escapeDeactivates:!0,delayInitialFocus:!0,isKeyForward:hi,isKeyBackward:yi},o),r={containers:[],containerGroups:[],tabbableGroups:[],nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1,manuallyPaused:!1,delayInitialFocusTimer:void 0,recentNavEvent:void 0},c=function(C,D,I){return C&&C[D]!==void 0?C[D]:a[I||D]},i=function(C,D){var I=typeof D?.composedPath=="function"?D.composedPath():void 0;return r.containerGroups.findIndex(function(T){var B=T.container,_=T.tabbableNodes;return B.contains(C)||I?.includes(B)||_.find(function(V){return V===C})})},l=function(C){var D=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},I=D.hasFallback,T=I!==void 0&&I,B=D.params,_=B===void 0?[]:B,V=a[C];if(typeof V=="function"&&(V=V.apply(void 0,pi(_))),V===!0&&(V=void 0),!V){if(V===void 0||V===!1)return V;throw new Error("`".concat(C,"` was specified but was not a node, or did not return a node"))}var z=V;if(typeof V=="string"){try{z=t.querySelector(V)}catch(H){throw new Error("`".concat(C,'` appears to be an invalid selector; error="').concat(H.message,'"'))}if(!z&&!T)throw new Error("`".concat(C,"` as selector refers to no known node"))}return z},m=function(){var C=l("initialFocus",{hasFallback:!0});if(C===!1)return!1;if(C===void 0||C&&!wt(C,a.tabbableOptions))if(i(t.activeElement)>=0)C=t.activeElement;else{var D=r.tabbableGroups[0];C=D&&D.firstTabbableNode||l("fallbackFocus")}else C===null&&(C=l("fallbackFocus"));if(!C)throw new Error("Your focus-trap needs to have at least one focusable element");return C},k=function(){if(r.containerGroups=r.containers.map(function(C){var D=er(C,a.tabbableOptions),I=tr(C,a.tabbableOptions),T=D.length>0?D[0]:void 0,B=D.length>0?D[D.length-1]:void 0,_=I.find(function(H){return Ve(H)}),V=I.slice().reverse().find(function(H){return Ve(H)}),z=!!D.find(function(H){return _e(H)>0});return{container:C,tabbableNodes:D,focusableNodes:I,posTabIndexesFound:z,firstTabbableNode:T,lastTabbableNode:B,firstDomTabbableNode:_,lastDomTabbableNode:V,nextTabbableNode:function(H){var Z=!(arguments.length>1&&arguments[1]!==void 0)||arguments[1],X=D.indexOf(H);return X<0?Z?I.slice(I.indexOf(H)+1).find(function(J){return Ve(J)}):I.slice(0,I.indexOf(H)).reverse().find(function(J){return Ve(J)}):D[X+(Z?1:-1)]}}}),r.tabbableGroups=r.containerGroups.filter(function(C){return C.tabbableNodes.length>0}),r.tabbableGroups.length<=0&&!l("fallbackFocus"))throw new Error("Your focus-trap must have at least one container with at least one tabbable node in it at all times");if(r.containerGroups.find(function(C){return C.posTabIndexesFound})&&r.containerGroups.length>1)throw new Error("At least one node with a positive tabindex was found in one of your focus-trap's multiple containers. Positive tabindexes are only supported in single-container focus-traps.")},g=function(C){var D=C.activeElement;if(D)return D.shadowRoot&&D.shadowRoot.activeElement!==null?g(D.shadowRoot):D},x=function(C){C!==!1&&C!==g(document)&&(C&&C.focus?(C.focus({preventScroll:!!a.preventScroll}),r.mostRecentlyFocusedNode=C,(function(D){return D.tagName&&D.tagName.toLowerCase()==="input"&&typeof D.select=="function"})(C)&&C.select()):x(m()))},w=function(C){var D=l("setReturnFocus",{params:[C]});return D||D!==!1&&C},y=function(C){var D=C.target,I=C.event,T=C.isBackward,B=T!==void 0&&T;D=D||yt(I),k();var _=null;if(r.tabbableGroups.length>0){var V=i(D,I),z=V>=0?r.containerGroups[V]:void 0;if(V<0)_=B?r.tabbableGroups[r.tabbableGroups.length-1].lastTabbableNode:r.tabbableGroups[0].firstTabbableNode;else if(B){var H=r.tabbableGroups.findIndex(function(ee){var re=ee.firstTabbableNode;return D===re});if(H<0&&(z.container===D||wt(D,a.tabbableOptions)&&!Ve(D,a.tabbableOptions)&&!z.nextTabbableNode(D,!1))&&(H=V),H>=0){var Z=H===0?r.tabbableGroups.length-1:H-1,X=r.tabbableGroups[Z];_=_e(D)>=0?X.lastTabbableNode:X.lastDomTabbableNode}else ct(I)||(_=z.nextTabbableNode(D,!1))}else{var J=r.tabbableGroups.findIndex(function(ee){var re=ee.lastTabbableNode;return D===re});if(J<0&&(z.container===D||wt(D,a.tabbableOptions)&&!Ve(D,a.tabbableOptions)&&!z.nextTabbableNode(D))&&(J=V),J>=0){var ne=J===r.tabbableGroups.length-1?0:J+1,oe=r.tabbableGroups[ne];_=_e(D)>=0?oe.firstTabbableNode:oe.firstDomTabbableNode}else ct(I)||(_=z.nextTabbableNode(D))}}else _=l("fallbackFocus");return _},h=function(C){var D=yt(C);i(D,C)>=0||(ot(a.clickOutsideDeactivates,C)?n.deactivate({returnFocus:a.returnFocusOnDeactivate}):ot(a.allowOutsideClick,C)||C.preventDefault())},v=function(C){var D=yt(C),I=i(D,C)>=0;if(I||D instanceof Document)I&&(r.mostRecentlyFocusedNode=D);else{var T;C.stopImmediatePropagation();var B=!0;if(r.mostRecentlyFocusedNode)if(_e(r.mostRecentlyFocusedNode)>0){var _=i(r.mostRecentlyFocusedNode),V=r.containerGroups[_].tabbableNodes;if(V.length>0){var z=V.findIndex(function(H){return H===r.mostRecentlyFocusedNode});z>=0&&(a.isKeyForward(r.recentNavEvent)?z+1<V.length&&(T=V[z+1],B=!1):z-1>=0&&(T=V[z-1],B=!1))}}else r.containerGroups.some(function(H){return H.tabbableNodes.some(function(Z){return _e(Z)>0})})||(B=!1);else B=!1;B&&(T=y({target:r.mostRecentlyFocusedNode,isBackward:a.isKeyBackward(r.recentNavEvent)})),x(T||r.mostRecentlyFocusedNode||m())}r.recentNavEvent=void 0},u=function(C){(a.isKeyForward(C)||a.isKeyBackward(C))&&(function(D){var I=arguments.length>1&&arguments[1]!==void 0&&arguments[1];r.recentNavEvent=D;var T=y({event:D,isBackward:I});T&&(ct(D)&&D.preventDefault(),x(T))})(C,a.isKeyBackward(C))},S=function(C){var D;((D=C)==null?void 0:D.key)!=="Escape"&&D?.key!=="Esc"&&D?.keyCode!==27||ot(a.escapeDeactivates,C)===!1||(C.preventDefault(),n.deactivate())},M=function(C){var D=yt(C);i(D,C)>=0||ot(a.clickOutsideDeactivates,C)||ot(a.allowOutsideClick,C)||(C.preventDefault(),C.stopImmediatePropagation())},j=function(){if(r.active)return fi(s,n),r.delayInitialFocusTimer=a.delayInitialFocus?$n(function(){x(m())}):x(m()),t.addEventListener("focusin",v,!0),t.addEventListener("mousedown",h,{capture:!0,passive:!1}),t.addEventListener("touchstart",h,{capture:!0,passive:!1}),t.addEventListener("click",M,{capture:!0,passive:!1}),t.addEventListener("keydown",u,{capture:!0,passive:!1}),t.addEventListener("keydown",S),n},$=function(){if(r.active)return t.removeEventListener("focusin",v,!0),t.removeEventListener("mousedown",h,!0),t.removeEventListener("touchstart",h,!0),t.removeEventListener("click",M,!0),t.removeEventListener("keydown",u,!0),t.removeEventListener("keydown",S),n},O=typeof window<"u"&&"MutationObserver"in window?new MutationObserver(function(C){C.some(function(D){return Array.from(D.removedNodes).some(function(I){return I===r.mostRecentlyFocusedNode})})&&x(m())}):void 0,P=function(){O&&(O.disconnect(),r.active&&!r.paused&&r.containers.map(function(C){O.observe(C,{subtree:!0,childList:!0})}))};return n={get active(){return r.active},get paused(){return r.paused},activate:function(C){if(r.active)return this;var D=c(C,"onActivate"),I=c(C,"onPostActivate"),T=c(C,"checkCanFocusTrap");T||k(),r.active=!0,r.paused=!1,r.nodeFocusedBeforeActivation=g(t),D?.();var B=function(){T&&k(),j(),P(),I?.()};return T?(T(r.containers.concat()).then(B,B),this):(B(),this)},deactivate:function(C){if(!r.active)return this;var D=Vn({onDeactivate:a.onDeactivate,onPostDeactivate:a.onPostDeactivate,checkCanReturnFocus:a.checkCanReturnFocus},C);clearTimeout(r.delayInitialFocusTimer),r.delayInitialFocusTimer=void 0,$(),r.active=!1,r.paused=!1,P(),mi(s,n);var I=c(D,"onDeactivate"),T=c(D,"onPostDeactivate"),B=c(D,"checkCanReturnFocus"),_=c(D,"returnFocus","returnFocusOnDeactivate");I?.();var V=function(){$n(function(){_&&x(w(r.nodeFocusedBeforeActivation)),T?.()})};return _&&B?(B(w(r.nodeFocusedBeforeActivation)).then(V,V),this):(V(),this)},pause:function(C){return r.active?(r.manuallyPaused=!0,this._setPausedState(!0,C)):this},unpause:function(C){return r.active?(r.manuallyPaused=!1,s[s.length-1]!==this?this:this._setPausedState(!1,C)):this},updateContainerElements:function(C){var D=[].concat(C).filter(Boolean);return r.containers=D.map(function(I){return typeof I=="string"?t.querySelector(I):I}),r.active&&k(),P(),this}},Object.defineProperties(n,{_isManuallyPaused:{value:function(){return r.manuallyPaused}},_setPausedState:{value:function(C,D){if(r.paused===C)return this;if(r.paused=C,C){var I=c(D,"onPause"),T=c(D,"onPostPause");I?.(),$(),P(),T?.()}else{var B=c(D,"onUnpause"),_=c(D,"onPostUnpause");B?.(),k(),j(),P(),_?.()}return this}}}),n.updateContainerElements(e),n}},Symbol.toStringTag,{value:"Module"})),vi=So(bi),xi=So(ui);var zn,Wn,wi=(function(){if(Wn)return zn;function e(x){return e=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(w){return typeof w}:function(w){return w&&typeof Symbol=="function"&&w.constructor===Symbol&&w!==Symbol.prototype?"symbol":typeof w},e(x)}function o(x,w,y){return w&&(function(h,v){for(var u=0;u<v.length;u++){var S=v[u];S.enumerable=S.enumerable||!1,S.configurable=!0,"value"in S&&(S.writable=!0),Object.defineProperty(h,r(S.key),S)}})(x.prototype,w),Object.defineProperty(x,"prototype",{writable:!1}),x}function n(x,w,y){return w=s(w),(function(h,v){if(v&&(e(v)=="object"||typeof v=="function"))return v;if(v!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return(function(u){if(u===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return u})(h)})(x,t()?Reflect.construct(w,y||[],s(x).constructor):w.apply(x,y))}function t(){try{var x=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(t=function(){return!!x})()}function s(x){return s=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(w){return w.__proto__||Object.getPrototypeOf(w)},s(x)}function a(x,w){return a=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(y,h){return y.__proto__=h,y},a(x,w)}function r(x){var w=(function(y,h){if(e(y)!="object"||!y)return y;var v=y[Symbol.toPrimitive];if(v!==void 0){var u=v.call(y,h);if(e(u)!="object")return u;throw new TypeError("@@toPrimitive must return a primitive value.")}return(h==="string"?String:Number)(y)})(x,"string");return e(w)=="symbol"?w:w+""}Wn=1;var c=p,i=dn(),l=vi.createFocusTrap,m=xi.isFocusable,k=(function(x){function w(y){var h;(function(S,M){if(!(S instanceof M))throw new TypeError("Cannot call a class as a function")})(this,w),(function(S,M,j){(M=r(M))in S?Object.defineProperty(S,M,{value:j,enumerable:!0,configurable:!0,writable:!0}):S[M]=j})(h=n(this,w,[y]),"getNodeForOption",function(S){var M,j=(M=this.internalOptions[S])!==null&&M!==void 0?M:this.originalOptions[S];if(typeof j=="function"){for(var $=arguments.length,O=new Array($>1?$-1:0),P=1;P<$;P++)O[P-1]=arguments[P];j=j.apply(void 0,O)}if(j===!0&&(j=void 0),!j){if(j===void 0||j===!1)return j;throw new Error("`".concat(S,"` was specified but was not a node, or did not return a node"))}var C,D=j;if(typeof j=="string"&&!(D=(C=this.getDocument())===null||C===void 0?void 0:C.querySelector(j)))throw new Error("`".concat(S,"` as selector refers to no known node"));return D}),h.handleDeactivate=h.handleDeactivate.bind(h),h.handlePostDeactivate=h.handlePostDeactivate.bind(h),h.handleClickOutsideDeactivates=h.handleClickOutsideDeactivates.bind(h),h.internalOptions={returnFocusOnDeactivate:!1,checkCanReturnFocus:null,onDeactivate:h.handleDeactivate,onPostDeactivate:h.handlePostDeactivate,clickOutsideDeactivates:h.handleClickOutsideDeactivates},h.originalOptions={returnFocusOnDeactivate:!0,onDeactivate:null,onPostDeactivate:null,checkCanReturnFocus:null,clickOutsideDeactivates:!1};var v=y.focusTrapOptions;for(var u in v)Object.prototype.hasOwnProperty.call(v,u)&&(u!=="returnFocusOnDeactivate"&&u!=="onDeactivate"&&u!=="onPostDeactivate"&&u!=="checkCanReturnFocus"&&u!=="clickOutsideDeactivates"?h.internalOptions[u]=v[u]:h.originalOptions[u]=v[u]);return h.outsideClick=null,h.focusTrapElements=y.containerElements||[],h.updatePreviousElement(),h}return(function(y,h){if(typeof h!="function"&&h!==null)throw new TypeError("Super expression must either be null or a function");y.prototype=Object.create(h&&h.prototype,{constructor:{value:y,writable:!0,configurable:!0}}),Object.defineProperty(y,"prototype",{writable:!1}),h&&a(y,h)})(w,x),o(w,[{key:"getDocument",value:function(){return this.props.focusTrapOptions.document||(typeof document<"u"?document:void 0)}},{key:"getReturnFocusNode",value:function(){var y=this.getNodeForOption("setReturnFocus",this.previouslyFocusedElement);return y||y!==!1&&this.previouslyFocusedElement}},{key:"updatePreviousElement",value:function(){var y=this.getDocument();y&&(this.previouslyFocusedElement=y.activeElement)}},{key:"deactivateTrap",value:function(){this.focusTrap&&this.focusTrap.active&&this.focusTrap.deactivate({returnFocus:!1,checkCanReturnFocus:null,onDeactivate:this.originalOptions.onDeactivate})}},{key:"handleClickOutsideDeactivates",value:function(y){var h=typeof this.originalOptions.clickOutsideDeactivates=="function"?this.originalOptions.clickOutsideDeactivates.call(null,y):this.originalOptions.clickOutsideDeactivates;return h&&(this.outsideClick={target:y.target,allowDeactivation:h}),h}},{key:"handleDeactivate",value:function(){this.originalOptions.onDeactivate&&this.originalOptions.onDeactivate.call(null),this.deactivateTrap()}},{key:"handlePostDeactivate",value:function(){var y=this,h=function(){var v=y.getReturnFocusNode(),u=!(!y.originalOptions.returnFocusOnDeactivate||v==null||!v.focus||y.outsideClick&&(!y.outsideClick.allowDeactivation||m(y.outsideClick.target,y.internalOptions.tabbableOptions))),S=y.internalOptions.preventScroll,M=S!==void 0&&S;u&&v.focus({preventScroll:M}),y.originalOptions.onPostDeactivate&&y.originalOptions.onPostDeactivate.call(null),y.outsideClick=null};this.originalOptions.checkCanReturnFocus?this.originalOptions.checkCanReturnFocus.call(null,this.getReturnFocusNode()).then(h,h):h()}},{key:"setupFocusTrap",value:function(){this.focusTrap?this.props.active&&!this.focusTrap.active&&(this.focusTrap.activate(),this.props.paused&&this.focusTrap.pause()):this.focusTrapElements.some(Boolean)&&(this.focusTrap=this.props._createFocusTrap(this.focusTrapElements,this.internalOptions),this.props.active&&this.focusTrap.activate(),this.props.paused&&this.focusTrap.pause())}},{key:"componentDidMount",value:function(){this.props.active&&this.setupFocusTrap()}},{key:"componentDidUpdate",value:function(y){if(this.focusTrap){y.containerElements!==this.props.containerElements&&this.focusTrap.updateContainerElements(this.props.containerElements);var h=!y.active&&this.props.active,v=y.active&&!this.props.active,u=!y.paused&&this.props.paused,S=y.paused&&!this.props.paused;if(h&&(this.updatePreviousElement(),this.focusTrap.activate()),v)return void this.deactivateTrap();u&&this.focusTrap.pause(),S&&this.focusTrap.unpause()}else y.containerElements!==this.props.containerElements&&(this.focusTrapElements=this.props.containerElements),this.props.active&&(this.updatePreviousElement(),this.setupFocusTrap())}},{key:"componentWillUnmount",value:function(){this.deactivateTrap()}},{key:"render",value:function(){var y=this,h=this.props.children?c.Children.only(this.props.children):void 0;if(h){if(h.type&&h.type===c.Fragment)throw new Error("A focus-trap cannot use a Fragment as its child container. Try replacing it with a <div> element.");return c.cloneElement(h,{ref:function(v){var u=y.props.containerElements;h&&(typeof h.ref=="function"?h.ref(v):h.ref&&(h.ref.current=v)),y.focusTrapElements=u||[v]}})}return null}}])})(c.Component),g=typeof Element>"u"?Function:Element;return k.propTypes={active:i.bool,paused:i.bool,focusTrapOptions:i.shape({document:i.object,onActivate:i.func,onPostActivate:i.func,checkCanFocusTrap:i.func,onPause:i.func,onPostPause:i.func,onUnpause:i.func,onPostUnpause:i.func,onDeactivate:i.func,onPostDeactivate:i.func,checkCanReturnFocus:i.func,initialFocus:i.oneOfType([i.instanceOf(g),i.string,i.bool,i.func]),fallbackFocus:i.oneOfType([i.instanceOf(g),i.string,i.func]),escapeDeactivates:i.oneOfType([i.bool,i.func]),clickOutsideDeactivates:i.oneOfType([i.bool,i.func]),returnFocusOnDeactivate:i.bool,setReturnFocus:i.oneOfType([i.instanceOf(g),i.string,i.bool,i.func]),allowOutsideClick:i.oneOfType([i.bool,i.func]),preventScroll:i.bool,tabbableOptions:i.shape({displayCheck:i.oneOf(["full","legacy-full","non-zero-area","none"]),getShadowRoot:i.oneOfType([i.bool,i.func])}),trapStack:i.array,isKeyForward:i.func,isKeyBackward:i.func}),containerElements:i.arrayOf(i.instanceOf(g)),children:i.oneOfType([i.element,i.instanceOf(g)])},k.defaultProps={active:!0,paused:!1,focusTrapOptions:{},_createFocusTrap:l},zn=k})();const ki=ko(wi);var Un,rt={exports:{}},Hn={},gt={exports:{}},Kn,de={},Fe={};function Pt(){return Kn||(Kn=1,Object.defineProperty(Fe,"__esModule",{value:!0}),Fe.dontSetMe=function(e,o,n){if(e[o])return new Error(`Invalid prop ${o} passed to ${n} - do not set this, set it on the child.`)},Fe.findInArray=function(e,o){for(let n=0,t=e.length;n<t;n++)if(o.apply(o,[e[n],n,e]))return e[n]},Fe.int=function(e){return parseInt(e,10)},Fe.isFunction=function(e){return typeof e=="function"||Object.prototype.toString.call(e)==="[object Function]"},Fe.isNum=function(e){return typeof e=="number"&&!isNaN(e)}),Fe}var Yn,qn,Ne={};function pn(){if(qn)return de;qn=1,Object.defineProperty(de,"__esModule",{value:!0}),de.addClassName=r,de.addEvent=function(i,l,m,k){if(!i)return;const g={capture:!0,...k};i.addEventListener?i.addEventListener(l,m,g):i.attachEvent?i.attachEvent("on"+l,m):i["on"+l]=m},de.addUserSelectStyles=function(i){if(!i)return;let l=i.getElementById("react-draggable-style-el");l||(l=i.createElement("style"),l.type="text/css",l.id="react-draggable-style-el",l.innerHTML=`.react-draggable-transparent-selection *::-moz-selection {all: inherit;}
|
|
10
10
|
`,l.innerHTML+=`.react-draggable-transparent-selection *::selection {all: inherit;}
|
|
11
|
-
`,i.getElementsByTagName("head")[0].appendChild(l)),i.body&&r(i.body,"react-draggable-transparent-selection")},de.createCSSTransform=function(i,l){const m=s(i,l,"px");return{[(0,o.browserPrefixToKey)("transform",o.default)]:m}},de.createSVGTransform=function(i,l){return s(i,l,"")},de.getTouch=function(i,l){return i.targetTouches&&(0,e.findInArray)(i.targetTouches,m=>l===m.identifier)||i.changedTouches&&(0,e.findInArray)(i.changedTouches,m=>l===m.identifier)},de.getTouchIdentifier=function(i){if(i.targetTouches&&i.targetTouches[0])return i.targetTouches[0].identifier;if(i.changedTouches&&i.changedTouches[0])return i.changedTouches[0].identifier},de.getTranslation=s,de.innerHeight=function(i){let l=i.clientHeight;const m=i.ownerDocument.defaultView.getComputedStyle(i);return l-=(0,e.int)(m.paddingTop),l-=(0,e.int)(m.paddingBottom),l},de.innerWidth=function(i){let l=i.clientWidth;const m=i.ownerDocument.defaultView.getComputedStyle(i);return l-=(0,e.int)(m.paddingLeft),l-=(0,e.int)(m.paddingRight),l},de.matchesSelector=t,de.matchesSelectorAndParentsTo=function(i,l,m){let k=i;do{if(t(k,l))return!0;if(k===m)return!1;k=k.parentNode}while(k);return!1},de.offsetXYFromParent=function(i,l,m){const k=l===l.ownerDocument.body?{left:0,top:0}:l.getBoundingClientRect(),g=(i.clientX+l.scrollLeft-k.left)/m,x=(i.clientY+l.scrollTop-k.top)/m;return{x:g,y:x}},de.outerHeight=function(i){let l=i.clientHeight;const m=i.ownerDocument.defaultView.getComputedStyle(i);return l+=(0,e.int)(m.borderTopWidth),l+=(0,e.int)(m.borderBottomWidth),l},de.outerWidth=function(i){let l=i.clientWidth;const m=i.ownerDocument.defaultView.getComputedStyle(i);return l+=(0,e.int)(m.borderLeftWidth),l+=(0,e.int)(m.borderRightWidth),l},de.removeClassName=c,de.removeEvent=function(i,l,m,k){if(!i)return;const g={capture:!0,...k};i.removeEventListener?i.removeEventListener(l,m,g):i.detachEvent?i.detachEvent("on"+l,m):i["on"+l]=null},de.scheduleRemoveUserSelectStyles=function(i){window.requestAnimationFrame?window.requestAnimationFrame(()=>{a(i)}):a(i)};var e=Pt(),o=(function(i,l){if(typeof WeakMap=="function")var m=new WeakMap,k=new WeakMap;return(function(g,x){if(!x&&g&&g.__esModule)return g;var w,y,h={__proto__:null,default:g};if(g===null||typeof g!="object"&&typeof g!="function")return h;if(w=x?k:m){if(w.has(g))return w.get(g);w.set(g,h)}for(const v in g)v!=="default"&&{}.hasOwnProperty.call(g,v)&&((y=(w=Object.defineProperty)&&Object.getOwnPropertyDescriptor(g,v))&&(y.get||y.set)?w(h,v,y):h[v]=g[v]);return h})(i,l)})((function(){if(Yn)return Ne;Yn=1,Object.defineProperty(Ne,"__esModule",{value:!0}),Ne.browserPrefixToKey=m,Ne.browserPrefixToStyle=function(k,g){return g?`-${g.toLowerCase()}-${k}`:k},Ne.default=void 0,Ne.getPrefix=l;const i=["Moz","Webkit","O","ms"];function l(){let k=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"transform";if(typeof window>"u")return"";const g=window.document?.documentElement?.style;if(!g||k in g)return"";for(let x=0;x<i.length;x++)if(m(k,i[x])in g)return i[x];return""}function m(k,g){return g?`${g}${(function(x){let w="",y=!0;for(let h=0;h<x.length;h++)y?(w+=x[h].toUpperCase(),y=!1):x[h]==="-"?y=!0:w+=x[h];return w})(k)}`:k}return Ne.default=l(),Ne})());let n="";function t(i,l){return n||(n=(0,e.findInArray)(["matches","webkitMatchesSelector","mozMatchesSelector","msMatchesSelector","oMatchesSelector"],function(m){return(0,e.isFunction)(i[m])})),!!(0,e.isFunction)(i[n])&&i[n](l)}function s(i,l,m){let{x:k,y:g}=i,x=`translate(${k}${m},${g}${m})`;return l&&(x=`translate(${`${typeof l.x=="string"?l.x:l.x+m}`}, ${`${typeof l.y=="string"?l.y:l.y+m}`})`+x),x}function a(i){if(i)try{if(i.body&&c(i.body,"react-draggable-transparent-selection"),i.selection)i.selection.empty();else{const l=(i.defaultView||window).getSelection();l&&l.type!=="Caret"&&l.removeAllRanges()}}catch{}}function r(i,l){i.classList?i.classList.add(l):i.className.match(new RegExp(`(?:^|\\s)${l}(?!\\S)`))||(i.className+=` ${l}`)}function c(i,l){i.classList?i.classList.remove(l):i.className=i.className.replace(new RegExp(`(?:^|\\s)${l}(?!\\S)`,"g"),"")}return de}var Gn,Me={};function nr(){if(Gn)return Me;Gn=1,Object.defineProperty(Me,"__esModule",{value:!0}),Me.canDragX=function(t){return t.props.axis==="both"||t.props.axis==="x"},Me.canDragY=function(t){return t.props.axis==="both"||t.props.axis==="y"},Me.createCoreData=function(t,s,a){const r=!(0,e.isNum)(t.lastX),c=n(t);return r?{node:c,deltaX:0,deltaY:0,lastX:s,lastY:a,x:s,y:a}:{node:c,deltaX:s-t.lastX,deltaY:a-t.lastY,lastX:t.lastX,lastY:t.lastY,x:s,y:a}},Me.createDraggableData=function(t,s){const a=t.props.scale;return{node:s.node,x:t.state.x+s.deltaX/a,y:t.state.y+s.deltaY/a,deltaX:s.deltaX/a,deltaY:s.deltaY/a,lastX:t.state.x,lastY:t.state.y}},Me.getBoundPosition=function(t,s,a){if(!t.props.bounds)return[s,a];let{bounds:r}=t.props;r=typeof r=="string"?r:(function(i){return{left:i.left,top:i.top,right:i.right,bottom:i.bottom}})(r);const c=n(t);if(typeof r=="string"){const{ownerDocument:i}=c,l=i.defaultView;let m;if(r==="parent"?m=c.parentNode:m=c.getRootNode().querySelector(r),!(m instanceof l.HTMLElement))throw new Error('Bounds selector "'+r+'" could not find an element.');const k=m,g=l.getComputedStyle(c),x=l.getComputedStyle(k);r={left:-c.offsetLeft+(0,e.int)(x.paddingLeft)+(0,e.int)(g.marginLeft),top:-c.offsetTop+(0,e.int)(x.paddingTop)+(0,e.int)(g.marginTop),right:(0,o.innerWidth)(k)-(0,o.outerWidth)(c)-c.offsetLeft+(0,e.int)(x.paddingRight)-(0,e.int)(g.marginRight),bottom:(0,o.innerHeight)(k)-(0,o.outerHeight)(c)-c.offsetTop+(0,e.int)(x.paddingBottom)-(0,e.int)(g.marginBottom)}}return(0,e.isNum)(r.right)&&(s=Math.min(s,r.right)),(0,e.isNum)(r.bottom)&&(a=Math.min(a,r.bottom)),(0,e.isNum)(r.left)&&(s=Math.max(s,r.left)),(0,e.isNum)(r.top)&&(a=Math.max(a,r.top)),[s,a]},Me.getControlPosition=function(t,s,a){const r=typeof s=="number"?(0,o.getTouch)(t,s):null;if(typeof s=="number"&&!r)return null;const c=n(a),i=a.props.offsetParent||c.offsetParent||c.ownerDocument.body;return(0,o.offsetXYFromParent)(r||t,i,a.props.scale)},Me.snapToGrid=function(t,s,a){const r=Math.round(s/t[0])*t[0],c=Math.round(a/t[1])*t[1];return[r,c]};var e=Pt(),o=pn();function n(t){const s=t.findDOMNode();if(!s)throw new Error("<DraggableCore>: Unmounted during event!");return s}return Me}var Xn,Qn,Jn,Zn,it={},bt={};function or(){return Xn||(Xn=1,Object.defineProperty(bt,"__esModule",{value:!0}),bt.default=function(){}),bt}function Si(){if(Qn)return it;Qn=1,Object.defineProperty(it,"__esModule",{value:!0}),it.default=void 0;var e=(function(x,w){if(typeof WeakMap=="function")var y=new WeakMap,h=new WeakMap;return(function(v,u){if(!u&&v&&v.__esModule)return v;var S,M,j={__proto__:null,default:v};if(v===null||typeof v!="object"&&typeof v!="function")return j;if(S=u?h:y){if(S.has(v))return S.get(v);S.set(v,j)}for(const $ in v)$!=="default"&&{}.hasOwnProperty.call(v,$)&&((M=(S=Object.defineProperty)&&Object.getOwnPropertyDescriptor(v,$))&&(M.get||M.set)?S(j,$,M):j[$]=v[$]);return j})(x,w)})(p),o=c(dn()),n=c(en),t=pn(),s=nr(),a=Pt(),r=c(or());function c(x){return x&&x.__esModule?x:{default:x}}function i(x,w,y){return(w=(function(h){var v=(function(u,S){if(typeof u!="object"||!u)return u;var M=u[Symbol.toPrimitive];if(M!==void 0){var j=M.call(u,S);if(typeof j!="object")return j;throw new TypeError("@@toPrimitive must return a primitive value.")}return(S==="string"?String:Number)(u)})(h,"string");return typeof v=="symbol"?v:v+""})(w))in x?Object.defineProperty(x,w,{value:y,enumerable:!0,configurable:!0,writable:!0}):x[w]=y,x}const l={start:"touchstart",move:"touchmove",stop:"touchend"},m={start:"mousedown",move:"mousemove",stop:"mouseup"};let k=m,g=class extends e.Component{constructor(){super(...arguments),i(this,"dragging",!1),i(this,"lastX",NaN),i(this,"lastY",NaN),i(this,"touchIdentifier",null),i(this,"mounted",!1),i(this,"handleDragStart",x=>{if(this.props.onMouseDown(x),!this.props.allowAnyClick&&typeof x.button=="number"&&x.button!==0)return!1;const w=this.findDOMNode();if(!w||!w.ownerDocument||!w.ownerDocument.body)throw new Error("<DraggableCore> not mounted on DragStart!");const{ownerDocument:y}=w;if(this.props.disabled||!(x.target instanceof y.defaultView.Node)||this.props.handle&&!(0,t.matchesSelectorAndParentsTo)(x.target,this.props.handle,w)||this.props.cancel&&(0,t.matchesSelectorAndParentsTo)(x.target,this.props.cancel,w))return;x.type!=="touchstart"||this.props.allowMobileScroll||x.preventDefault();const h=(0,t.getTouchIdentifier)(x);this.touchIdentifier=h;const v=(0,s.getControlPosition)(x,h,this);if(v==null)return;const{x:u,y:S}=v,M=(0,s.createCoreData)(this,u,S);(0,r.default)("DraggableCore: handleDragStart: %j",M),(0,r.default)("calling",this.props.onStart),this.props.onStart(x,M)!==!1&&this.mounted!==!1&&(this.props.enableUserSelectHack&&(0,t.addUserSelectStyles)(y),this.dragging=!0,this.lastX=u,this.lastY=S,(0,t.addEvent)(y,k.move,this.handleDrag),(0,t.addEvent)(y,k.stop,this.handleDragStop))}),i(this,"handleDrag",x=>{const w=(0,s.getControlPosition)(x,this.touchIdentifier,this);if(w==null)return;let{x:y,y:h}=w;if(Array.isArray(this.props.grid)){let u=y-this.lastX,S=h-this.lastY;if([u,S]=(0,s.snapToGrid)(this.props.grid,u,S),!u&&!S)return;y=this.lastX+u,h=this.lastY+S}const v=(0,s.createCoreData)(this,y,h);if((0,r.default)("DraggableCore: handleDrag: %j",v),this.props.onDrag(x,v)!==!1&&this.mounted!==!1)this.lastX=y,this.lastY=h;else try{this.handleDragStop(new MouseEvent("mouseup"))}catch{const S=document.createEvent("MouseEvents");S.initMouseEvent("mouseup",!0,!0,window,0,0,0,0,0,!1,!1,!1,!1,0,null),this.handleDragStop(S)}}),i(this,"handleDragStop",x=>{if(!this.dragging)return;const w=(0,s.getControlPosition)(x,this.touchIdentifier,this);if(w==null)return;let{x:y,y:h}=w;if(Array.isArray(this.props.grid)){let S=y-this.lastX||0,M=h-this.lastY||0;[S,M]=(0,s.snapToGrid)(this.props.grid,S,M),y=this.lastX+S,h=this.lastY+M}const v=(0,s.createCoreData)(this,y,h);if(this.props.onStop(x,v)===!1||this.mounted===!1)return!1;const u=this.findDOMNode();u&&this.props.enableUserSelectHack&&(0,t.scheduleRemoveUserSelectStyles)(u.ownerDocument),(0,r.default)("DraggableCore: handleDragStop: %j",v),this.dragging=!1,this.lastX=NaN,this.lastY=NaN,u&&((0,r.default)("DraggableCore: Removing handlers"),(0,t.removeEvent)(u.ownerDocument,k.move,this.handleDrag),(0,t.removeEvent)(u.ownerDocument,k.stop,this.handleDragStop))}),i(this,"onMouseDown",x=>(k=m,this.handleDragStart(x))),i(this,"onMouseUp",x=>(k=m,this.handleDragStop(x))),i(this,"onTouchStart",x=>(k=l,this.handleDragStart(x))),i(this,"onTouchEnd",x=>(k=l,this.handleDragStop(x)))}componentDidMount(){this.mounted=!0;const x=this.findDOMNode();x&&(0,t.addEvent)(x,l.start,this.onTouchStart,{passive:!1})}componentWillUnmount(){this.mounted=!1;const x=this.findDOMNode();if(x){const{ownerDocument:w}=x;(0,t.removeEvent)(w,m.move,this.handleDrag),(0,t.removeEvent)(w,l.move,this.handleDrag),(0,t.removeEvent)(w,m.stop,this.handleDragStop),(0,t.removeEvent)(w,l.stop,this.handleDragStop),(0,t.removeEvent)(x,l.start,this.onTouchStart,{passive:!1}),this.props.enableUserSelectHack&&(0,t.scheduleRemoveUserSelectStyles)(w)}}findDOMNode(){return this.props?.nodeRef?this.props?.nodeRef?.current:n.default.findDOMNode(this)}render(){return e.cloneElement(e.Children.only(this.props.children),{onMouseDown:this.onMouseDown,onMouseUp:this.onMouseUp,onTouchEnd:this.onTouchEnd})}};return it.default=g,i(g,"displayName","DraggableCore"),i(g,"propTypes",{allowAnyClick:o.default.bool,allowMobileScroll:o.default.bool,children:o.default.node.isRequired,disabled:o.default.bool,enableUserSelectHack:o.default.bool,offsetParent:function(x,w){if(x[w]&&x[w].nodeType!==1)throw new Error("Draggable's offsetParent must be a DOM Node.")},grid:o.default.arrayOf(o.default.number),handle:o.default.string,cancel:o.default.string,nodeRef:o.default.object,onStart:o.default.func,onDrag:o.default.func,onStop:o.default.func,onMouseDown:o.default.func,scale:o.default.number,className:a.dontSetMe,style:a.dontSetMe,transform:a.dontSetMe}),i(g,"defaultProps",{allowAnyClick:!1,allowMobileScroll:!1,disabled:!1,enableUserSelectHack:!0,onStart:function(){},onDrag:function(){},onStop:function(){},onMouseDown:function(){},scale:1}),it}function Ci(){return Jn||(Jn=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"DraggableCore",{enumerable:!0,get:function(){return i.default}}),e.default=void 0;var o=(function(w,y){if(typeof WeakMap=="function")var h=new WeakMap,v=new WeakMap;return(function(u,S){if(!S&&u&&u.__esModule)return u;var M,j,$={__proto__:null,default:u};if(u===null||typeof u!="object"&&typeof u!="function")return $;if(M=S?v:h){if(M.has(u))return M.get(u);M.set(u,$)}for(const O in u)O!=="default"&&{}.hasOwnProperty.call(u,O)&&((j=(M=Object.defineProperty)&&Object.getOwnPropertyDescriptor(u,O))&&(j.get||j.set)?M($,O,j):$[O]=u[O]);return $})(w,y)})(p),n=m(dn()),t=m(en),s=(function(){if(Un)return gt.exports;function w(h){var v,u,S="";if(typeof h=="string"||typeof h=="number")S+=h;else if(typeof h=="object")if(Array.isArray(h)){var M=h.length;for(v=0;v<M;v++)h[v]&&(u=w(h[v]))&&(S&&(S+=" "),S+=u)}else for(u in h)h[u]&&(S&&(S+=" "),S+=u);return S}function y(){for(var h,v,u=0,S="",M=arguments.length;u<M;u++)(h=arguments[u])&&(v=w(h))&&(S&&(S+=" "),S+=v);return S}return Un=1,gt.exports=y,gt.exports.clsx=y,gt.exports})(),a=pn(),r=nr(),c=Pt(),i=m(Si()),l=m(or());function m(w){return w&&w.__esModule?w:{default:w}}function k(){return k=Object.assign?Object.assign.bind():function(w){for(var y=1;y<arguments.length;y++){var h=arguments[y];for(var v in h)({}).hasOwnProperty.call(h,v)&&(w[v]=h[v])}return w},k.apply(null,arguments)}function g(w,y,h){return(y=(function(v){var u=(function(S,M){if(typeof S!="object"||!S)return S;var j=S[Symbol.toPrimitive];if(j!==void 0){var $=j.call(S,M);if(typeof $!="object")return $;throw new TypeError("@@toPrimitive must return a primitive value.")}return(M==="string"?String:Number)(S)})(v,"string");return typeof u=="symbol"?u:u+""})(y))in w?Object.defineProperty(w,y,{value:h,enumerable:!0,configurable:!0,writable:!0}):w[y]=h,w}class x extends o.Component{static getDerivedStateFromProps(y,h){let{position:v}=y,{prevPropsPosition:u}=h;return!v||u&&v.x===u.x&&v.y===u.y?null:((0,l.default)("Draggable: getDerivedStateFromProps %j",{position:v,prevPropsPosition:u}),{x:v.x,y:v.y,prevPropsPosition:{...v}})}constructor(y){super(y),g(this,"onDragStart",(h,v)=>{if((0,l.default)("Draggable: onDragStart: %j",v),this.props.onStart(h,(0,r.createDraggableData)(this,v))===!1)return!1;this.setState({dragging:!0,dragged:!0})}),g(this,"onDrag",(h,v)=>{if(!this.state.dragging)return!1;(0,l.default)("Draggable: onDrag: %j",v);const u=(0,r.createDraggableData)(this,v),S={x:u.x,y:u.y,slackX:0,slackY:0};if(this.props.bounds){const{x:M,y:j}=S;S.x+=this.state.slackX,S.y+=this.state.slackY;const[$,O]=(0,r.getBoundPosition)(this,S.x,S.y);S.x=$,S.y=O,S.slackX=this.state.slackX+(M-S.x),S.slackY=this.state.slackY+(j-S.y),u.x=S.x,u.y=S.y,u.deltaX=S.x-this.state.x,u.deltaY=S.y-this.state.y}if(this.props.onDrag(h,u)===!1)return!1;this.setState(S)}),g(this,"onDragStop",(h,v)=>{if(!this.state.dragging||this.props.onStop(h,(0,r.createDraggableData)(this,v))===!1)return!1;(0,l.default)("Draggable: onDragStop: %j",v);const u={dragging:!1,slackX:0,slackY:0};if(this.props.position){const{x:S,y:M}=this.props.position;u.x=S,u.y=M}this.setState(u)}),this.state={dragging:!1,dragged:!1,x:y.position?y.position.x:y.defaultPosition.x,y:y.position?y.position.y:y.defaultPosition.y,prevPropsPosition:{...y.position},slackX:0,slackY:0,isElementSVG:!1},!y.position||y.onDrag||y.onStop||console.warn("A `position` was applied to this <Draggable>, without drag handlers. This will make this component effectively undraggable. Please attach `onDrag` or `onStop` handlers so you can adjust the `position` of this element.")}componentDidMount(){window.SVGElement!==void 0&&this.findDOMNode()instanceof window.SVGElement&&this.setState({isElementSVG:!0})}componentWillUnmount(){this.state.dragging&&this.setState({dragging:!1})}findDOMNode(){return this.props?.nodeRef?.current??t.default.findDOMNode(this)}render(){const{axis:y,bounds:h,children:v,defaultPosition:u,defaultClassName:S,defaultClassNameDragging:M,defaultClassNameDragged:j,position:$,positionOffset:O,scale:P,...C}=this.props;let D={},I=null;const T=!$||this.state.dragging,B=$||u,_={x:(0,r.canDragX)(this)&&T?this.state.x:B.x,y:(0,r.canDragY)(this)&&T?this.state.y:B.y};this.state.isElementSVG?I=(0,a.createSVGTransform)(_,O):D=(0,a.createCSSTransform)(_,O);const V=(0,s.clsx)(v.props.className||"",S,{[M]:this.state.dragging,[j]:this.state.dragged});return o.createElement(i.default,k({},C,{onStart:this.onDragStart,onDrag:this.onDrag,onStop:this.onDragStop}),o.cloneElement(o.Children.only(v),{className:V,style:{...v.props.style,...D},transform:I}))}}e.default=x,g(x,"displayName","Draggable"),g(x,"propTypes",{...i.default.propTypes,axis:n.default.oneOf(["both","x","y","none"]),bounds:n.default.oneOfType([n.default.shape({left:n.default.number,right:n.default.number,top:n.default.number,bottom:n.default.number}),n.default.string,n.default.oneOf([!1])]),defaultClassName:n.default.string,defaultClassNameDragging:n.default.string,defaultClassNameDragged:n.default.string,defaultPosition:n.default.shape({x:n.default.number,y:n.default.number}),positionOffset:n.default.shape({x:n.default.oneOfType([n.default.number,n.default.string]),y:n.default.oneOfType([n.default.number,n.default.string])}),position:n.default.shape({x:n.default.number,y:n.default.number}),className:c.dontSetMe,style:c.dontSetMe,transform:c.dontSetMe}),g(x,"defaultProps",{...i.default.defaultProps,axis:"both",bounds:!1,defaultClassName:"react-draggable",defaultClassNameDragging:"react-draggable-dragging",defaultClassNameDragged:"react-draggable-dragged",defaultPosition:{x:0,y:0},scale:1})})(Hn)),Hn}var Di=(function(){if(Zn)return rt.exports;Zn=1;const{default:e,DraggableCore:o}=Ci();return rt.exports=e,rt.exports.default=e,rt.exports.DraggableCore=o,rt.exports})();const Oi=ko(Di),eo={x:0,y:0},Ei=p.memo(p.forwardRef((e,o)=>{const{defaultPosition:n=eo,PaperComponent:t=L.Paper,onDragStop:s,rootSel:a=".MuiModal-root",handleSel:r=".draggable-title",titleSize:c,rootSize:i,...l}=e,m=p.useRef(null),k=p.useMemo(()=>c&&i?{left:0,top:0,right:i.width-c.width,bottom:i.height-c.height}:null,[c,i]),[g,x]=p.useState(null),[w,y]=p.useState(null),[h,v]=p.useState(null);return p.useLayoutEffect(()=>{!g&&n&&x(n??eo)},[n]),p.useEffect(()=>{k&&g&&y({x:Math.max(0,Math.min(g.x,k.right)),y:Math.max(0,Math.min(g.y,k.bottom))})},[g,k]),f.jsx(Oi,{nodeRef:m,handle:r,cancel:'[class*="MuiDialogContent-root"]',position:w,bounds:k??".MuiModal-root",onStop:s,onStart:(u,S)=>{const M=u;v({x:(M.clientX??M.touches?.[0]?.clientX)-S.x,y:(M.clientY??M.touches?.[0]?.clientY)-S.y})},onDrag:(u,S)=>{const M=u,j=M.clientX??M.touches?.[0]?.clientX,$=M.clientY??M.touches?.[0]?.clientY;x({x:j-h.x,y:$-h.y})},children:f.jsx(t,{ref:kt([m,o]),...l})})})),Mi={x:"50",y:"50"},rr=p.memo(p.forwardRef((e,o)=>{const n=We.useThemeProps({props:e,name:"MuiDialog"}),t=We.useTheme(),s={enter:.66*t.transitions.duration.enteringScreen,exit:.66*t.transitions.duration.leavingScreen},{title:a="SheetXL",key:r="draggable-window",onCancel:c,onDone:i,onShow:l,onShown:m,onHide:k,onClose:g,open:x,autoFocusSel:w,children:y,transitionDuration:h=s,TransitionProps:v,slots:u=ve.CommonUtils.EmptyArray,slotProps:S=ve.CommonUtils.EmptyArray,sx:M,className:j,onMouseDown:$,initialPosition:O=Mi,isModal:P=!1,...C}=n;let D=u.transition??L.Fade;const I=u.backdrop??L.Backdrop,T=u.paper??L.Paper;let B=S.transition;v&&(B={...v,...B});const _=S.backdrop,V=S.paper,z=p.useRef(null),[H,Z]=p.useState(null),[X,J]=p.useState(!1),[ne,oe]=p.useState(!1),ee=p.useRef(null),[re,ie]=wn(),d=p.useRef(null),[b,E]=wn(),F=p.useRef(null);p.useEffect(()=>{H&&J(x)},[x,H]);const A=N.useCallbackRef(()=>{c?.(),J(!1)},[c]);p.useEffect(()=>{if(ie.width===0&&ie.height===0||H)return;const U=F.current?.getBoundingClientRect(),he=ie.height-U.height,et=ie.width-U.width;let Re=.5*et,Nt=.5*he;typeof O?.x=="number"?Re=O.x:typeof O?.x=="string"&&(Re=et*(parseFloat(O.x)/100)),typeof O?.y=="number"?Nt=O.y:typeof O?.y=="string"&&(Nt=he*(parseFloat(O.y)/100)),Z({x:Re,y:Nt})},[ie,E]);const[R,W]=p.useState(!1),[Y,q]=p.useState(null),[Q,te]=p.useState(null),ae=N.useCallbackRef(U=>{if(Y)return Y.focus(U),!0;if(w){const he=d.current?.querySelectorAll?.(w);if(he&&he.length>0)return he[0]?.focus?.(U),!0}return d.current?.focus?.(U),!1},[Y,w]),ue=N.useImperativeElement(o,()=>({focus:U=>{ae(U)}}),[]),Oe={...B,onExited:U=>{i?.(null),B?.onExited?.(U)},onExit:U=>{const he=Q;he&&requestAnimationFrame(()=>{ue.current?.contains(document.activeElement)&&he.focus()}),k?.(),oe(!1),B?.onExit?.(U)},onEntered:(U,he)=>{l?.(),B?.onEntered?.(U,he)},onEntering:(U,he)=>{oe(!0),m?.(ue.current)}};p.useEffect(()=>{ne&&ae()},[ne]);let be=f.jsx(ki,{focusTrapOptions:{escapeDeactivates:!1,allowOutsideClick:!0,initialFocus:!1},ref:z,active:ne,children:f.jsx(D,{in:X,timeout:h,role:"presentation",...Oe,children:f.jsx(L.Box,{className:"MuiDialog-container",ref:d,tabIndex:0,sx:{outline:"none",position:"relative"},onKeyDown:U=>{U.which===N.KeyCodes.Escape&&(A(),ee.current?.start(U,{center:!1}),setTimeout(()=>ee.current?.stop(U),180)),U.stopPropagation()},children:f.jsxs(Ei,{ref:kt([F,o]),className:ye({"Mui-focusVisible":R},j,"draggable"),sx:{"& *":U=>sn(U),pointerEvents:"auto",userSelect:"none","&:hover:not([disabled]):not(.Mui-focusVisible)":{outline:U=>`solid ${se.alpha(U.palette.text?.primary,.2)} 1px`},"&.Mui-focusVisible":{outline:U=>`solid ${se.alpha(U.palette.text?.primary,.2)} 1px`},position:"absolute",maxWidth:"100%",...M},defaultPosition:H,titleSize:E,rootSize:ie,PaperComponent:T,...C,...V,children:[a?f.jsx(L.DialogTitle,{className:ye({"Mui-selected":R},"draggable-title"),sx:{cursor:"move",display:"flex",color:U=>U.palette.text.secondary,boxSizing:"border-box",padding:"0 0",transitionProperty:"opacity",transitionDuration:U=>`${U.transitions.duration.shortest}ms`,opacity:.7,"&.Mui-selected":{opacity:1,transitionDuration:U=>U.transitions.duration.shortest/2+"ms"},backgroundColor:U=>se.alpha(U.palette.action.hover,.03)},ref:b,children:f.jsxs(L.Box,{sx:{display:"flex",flex:"1 1 10%",flexDirection:"row",alignItems:"center",marginTop:U=>U.spacing(1),marginLeft:U=>U.spacing(1),marginRight:U=>U.spacing(1)},children:[f.jsx(L.Box,{sx:{flex:"1 1 100%",paddingLeft:U=>U.spacing(1)},children:a}),f.jsx(Ke,{label:"Close",children:f.jsx(L.IconButton,{"aria-label":"close",sx:{color:U=>U.palette.text.icon??U.palette.action.active},touchRippleRef:ee,onPointerDown:U=>{ee.current?.start(U,{center:!1}),U.stopPropagation(),U.preventDefault()},onPointerUp:A,children:f.jsx(N.DynamicIcon,{iconKey:"Close"})})})]})}):null,y]})})})}),G=null;P&&(G=f.jsx(I,{..._,open:X,onMouseDown:U=>{A(),_?.onMouseDown?.(U)},onClick:U=>{g?.(U,"backdropClick"),_?.onClick?.(U)},sx:{pointerEvents:"auto",..._?.sx}}));const{getPortalContainer:le}=N.useFullscreenPortal();return en.createPortal(f.jsxs(L.Box,{className:"MuiModal-root",sx:{position:"fixed",zIndex:"1300",right:"0",bottom:"0",top:"0",left:"0",outline:"0",display:"block",pointerEvents:"none"},ref:kt([ue,re]),onPointerDown:U=>{R&&(U.target===d.current||U.target.tabIndex<0)&&d.current?.contains(document.activeElement)},onContextMenu:U=>{U.isPropagationStopped()||U.preventDefault()},onFocus:U=>{!R&&(U.target===d.current||U.target.tabIndex<0)&&setTimeout(()=>{ae()},100),z.current?.focusTrap?.unpause(),W(!0),d.current?.contains(U.target)&&U.target!==d.current&&q(U.target),U.relatedTarget&&!Q&&te(U.relatedTarget)},onBlur:U=>{ue?.current?.contains(U.relatedTarget)||(te(null),z.current?.focusTrap?.pause(),W(!1))},children:[G,be]}),le(),r+"")}));var De=typeof window<"u"?window:{screen:{},navigator:{}},Ze=(De.matchMedia||function(){return{matches:!1}}).bind(De),Ti={get passive(){return!0}},to=function(){};De.addEventListener&&De.addEventListener("p",to,Ti),De.removeEventListener&&De.removeEventListener("p",to,!1);var fn="ontouchstart"in De,ji=fn||"TouchEvent"in De&&Ze("(any-pointer: coarse)").matches,no=(De.navigator.maxTouchPoints||0)>0||ji,ir=De.navigator.userAgent||"",Pi=Ze("(pointer: coarse)").matches&&/iPad|Macintosh/.test(ir)&&Math.min(De.screen.width||0,De.screen.height||0)>=768,ar=(Ze("(pointer: coarse)").matches||!Ze("(pointer: fine)").matches&&fn)&&!/Windows.*Firefox/.test(ir),Ri=Ze("(any-pointer: fine)").matches||Ze("(any-hover: hover)").matches||Pi||!fn,oo=!no||!Ri&&ar?no?"touchOnly":"mouseOnly":"hybrid",Fi=oo==="mouseOnly"?"mouse":oo==="touchOnly"||ar?"touch":"mouse",ut=e=>e.type==="checkbox",$e=e=>e instanceof Date,we=e=>e==null;const sr=e=>typeof e=="object";var me=e=>!we(e)&&!Array.isArray(e)&&sr(e)&&!$e(e),mn=typeof window<"u"&&window.HTMLElement!==void 0&&typeof document<"u";function ge(e){let o;const n=Array.isArray(e),t=typeof FileList<"u"&&e instanceof FileList;if(e instanceof Date)o=new Date(e);else{if(mn&&(e instanceof Blob||t)||!n&&!me(e))return e;if(o=n?[]:Object.create(Object.getPrototypeOf(e)),n||(s=>{const a=s.constructor&&s.constructor.prototype;return me(a)&&a.hasOwnProperty("isPrototypeOf")})(e))for(const s in e)e.hasOwnProperty(s)&&(o[s]=ge(e[s]));else o=e}return o}var Rt=e=>/^\w*$/.test(e),fe=e=>e===void 0,Xt=e=>Array.isArray(e)?e.filter(Boolean):[],hn=e=>Xt(e.replace(/["|']|\]/g,"").split(/\.|\[/)),K=(e,o,n)=>{if(!o||!me(e))return n;const t=(Rt(o)?[o]:hn(o)).reduce((s,a)=>we(s)?s:s[a],e);return fe(t)||t===e?fe(e[o])?n:e[o]:t},Te=e=>typeof e=="boolean",ce=(e,o,n)=>{let t=-1;const s=Rt(o)?[o]:hn(o),a=s.length,r=a-1;for(;++t<a;){const c=s[t];let i=n;if(t!==r){const l=e[c];i=me(l)||Array.isArray(l)?l:isNaN(+s[t+1])?{}:[]}if(c==="__proto__"||c==="constructor"||c==="prototype")return;e[c]=i,e=e[c]}};const Ni="blur",Bi="focusout",Ii="onBlur",lr="onChange",cr="onSubmit",_i="onTouched",pt="all",Ai="max",Li="min",Vi="maxLength",$i="minLength",ro="pattern",io="required",zi="validate",ur=p.createContext(null);ur.displayName="HookFormContext";const Wi=e=>{const{children:o,...n}=e;return p.createElement(ur.Provider,{value:n},o)},Ui=typeof window<"u"?p.useLayoutEffect:p.useEffect;var Se=e=>typeof e=="string",Qt=e=>we(e)||!sr(e);function Ae(e,o,n=new WeakSet){if(Qt(e)||Qt(o))return e===o;if($e(e)&&$e(o))return e.getTime()===o.getTime();const t=Object.keys(e),s=Object.keys(o);if(t.length!==s.length)return!1;if(n.has(e)||n.has(o))return!0;n.add(e),n.add(o);for(const a of t){const r=e[a];if(!s.includes(a))return!1;if(a!=="ref"){const c=o[a];if($e(r)&&$e(c)||me(r)&&me(c)||Array.isArray(r)&&Array.isArray(c)?!Ae(r,c,n):r!==c)return!1}}return!0}var Hi=(e,o,n,t,s)=>o?{...n[e],types:{...n[e]&&n[e].types?n[e].types:{},[t]:s||!0}}:{},st=e=>Array.isArray(e)?e:[e],ao=()=>{let e=[];return{get observers(){return e},next:o=>{for(const n of e)n.next&&n.next(o)},subscribe:o=>(e.push(o),{unsubscribe:()=>{e=e.filter(n=>n!==o)}}),unsubscribe:()=>{e=[]}}};function dr(e,o){const n={};for(const t in e)if(e.hasOwnProperty(t)){const s=e[t],a=o[t];if(s&&me(s)&&a){const r=dr(s,a);me(r)&&(n[t]=r)}else e[t]&&(n[t]=a)}return n}var ke=e=>me(e)&&!Object.keys(e).length,yn=e=>e.type==="file",Ee=e=>typeof e=="function",Ot=e=>{if(!mn)return!1;const o=e?e.ownerDocument:0;return e instanceof(o&&o.defaultView?o.defaultView.HTMLElement:HTMLElement)},pr=e=>e.type==="select-multiple",gn=e=>e.type==="radio",$t=e=>Ot(e)&&e.isConnected;function pe(e,o){const n=Array.isArray(o)?o:Rt(o)?[o]:hn(o),t=n.length===1?e:(function(r,c){const i=c.slice(0,-1).length;let l=0;for(;l<i;)r=fe(r)?l++:r[c[l++]];return r})(e,n),s=n.length-1,a=n[s];return t&&delete t[a],s!==0&&(me(t)&&ke(t)||Array.isArray(t)&&(function(r){for(const c in r)if(r.hasOwnProperty(c)&&!fe(r[c]))return!1;return!0})(t))&&pe(e,n.slice(0,-1)),e}function fr(e){return Array.isArray(e)||me(e)&&!(o=>{for(const n in o)if(Ee(o[n]))return!0;return!1})(e)}function Jt(e,o={}){for(const n in e)fr(e[n])?(o[n]=Array.isArray(e[n])?[]:{},Jt(e[n],o[n])):we(e[n])||(o[n]=!0);return o}function qe(e,o,n){n||(n=Jt(o));for(const t in e)fr(e[t])?fe(o)||Qt(n[t])?n[t]=Jt(e[t],Array.isArray(e[t])?[]:{}):qe(e[t],we(o)?{}:o[t],n[t]):n[t]=!Ae(e[t],o[t]);return n}const so={value:!1,isValid:!1},lo={value:!0,isValid:!0};var mr=e=>{if(Array.isArray(e)){if(e.length>1){const o=e.filter(n=>n&&n.checked&&!n.disabled).map(n=>n.value);return{value:o,isValid:!!o.length}}return e[0].checked&&!e[0].disabled?e[0].attributes&&!fe(e[0].attributes.value)?fe(e[0].value)||e[0].value===""?lo:{value:e[0].value,isValid:!0}:lo:so}return so},hr=(e,{valueAsNumber:o,valueAsDate:n,setValueAs:t})=>fe(e)?e:o?e===""?NaN:e&&+e:n&&Se(e)?new Date(e):t?t(e):e;const co={isValid:!1,value:null};var yr=e=>Array.isArray(e)?e.reduce((o,n)=>n&&n.checked&&!n.disabled?{isValid:!0,value:n.value}:o,co):co;function uo(e){const o=e.ref;return yn(o)?o.files:gn(o)?yr(e.refs).value:pr(o)?[...o.selectedOptions].map(({value:n})=>n):ut(o)?mr(e.refs).value:hr(fe(o.value)?e.ref.value:o.value,e)}var Et=e=>e instanceof RegExp,at=e=>fe(e)?e:Et(e)?e.source:me(e)?Et(e.value)?e.value.source:e.value:e,po=e=>({isOnSubmit:!e||e===cr,isOnBlur:e===Ii,isOnChange:e===lr,isOnAll:e===pt,isOnTouch:e===_i});const fo="AsyncFunction";var Ki=e=>!!e&&!!e.validate&&!!(Ee(e.validate)&&e.validate.constructor.name===fo||me(e.validate)&&Object.values(e.validate).find(o=>o.constructor.name===fo)),mo=(e,o,n)=>!n&&(o.watchAll||o.watch.has(e)||[...o.watch].some(t=>e.startsWith(t)&&/^\.\w+/.test(e.slice(t.length))));const dt=(e,o,n,t)=>{for(const s of n||Object.keys(e)){const a=K(e,s);if(a){const{_f:r,...c}=a;if(r){if(r.refs&&r.refs[0]&&o(r.refs[0],s)&&!t||r.ref&&o(r.ref,r.name)&&!t)return!0;if(dt(c,o))break}else if(me(c)&&dt(c,o))break}}};function ho(e,o,n){const t=K(e,n);if(t||Rt(n))return{error:t,name:n};const s=n.split(".");for(;s.length;){const a=s.join("."),r=K(o,a),c=K(e,a);if(r&&!Array.isArray(r)&&n!==a)return{name:n};if(c&&c.type)return{name:a,error:c};if(c&&c.root&&c.root.type)return{name:`${a}.root`,error:c.root};s.pop()}return{name:n}}var Yi=(e,o,n)=>{const t=st(K(e,n));return ce(t,"root",o[n]),ce(e,n,t),e};function yo(e,o,n="validate"){if(Se(e)||Array.isArray(e)&&e.every(Se)||Te(e)&&!e)return{type:n,message:Se(e)?e:"",ref:o}}var Ye=e=>me(e)&&!Et(e)?e:{value:e,message:""},go=async(e,o,n,t,s,a)=>{const{ref:r,refs:c,required:i,maxLength:l,minLength:m,min:k,max:g,pattern:x,validate:w,name:y,valueAsNumber:h,mount:v}=e._f,u=K(n,y);if(!v||o.has(y))return{};const S=c?c[0]:r,M=T=>{s&&S.reportValidity&&(S.setCustomValidity(Te(T)?"":T||""),S.reportValidity())},j={},$=gn(r),O=ut(r),P=$||O,C=(h||yn(r))&&fe(r.value)&&fe(u)||Ot(r)&&r.value===""||u===""||Array.isArray(u)&&!u.length,D=Hi.bind(null,y,t,j),I=(T,B,_,V=Vi,z=$i)=>{const H=T?B:_;j[y]={type:T?V:z,message:H,ref:r,...D(T?V:z,H)}};if(a?!Array.isArray(u)||!u.length:i&&(!P&&(C||we(u))||Te(u)&&!u||O&&!mr(c).isValid||$&&!yr(c).isValid)){const{value:T,message:B}=Se(i)?{value:!!i,message:i}:Ye(i);if(T&&(j[y]={type:io,message:B,ref:S,...D(io,B)},!t))return M(B),j}if(!(C||we(k)&&we(g))){let T,B;const _=Ye(g),V=Ye(k);if(we(u)||isNaN(u)){const z=r.valueAsDate||new Date(u),H=J=>new Date(new Date().toDateString()+" "+J),Z=r.type=="time",X=r.type=="week";Se(_.value)&&u&&(T=Z?H(u)>H(_.value):X?u>_.value:z>new Date(_.value)),Se(V.value)&&u&&(B=Z?H(u)<H(V.value):X?u<V.value:z<new Date(V.value))}else{const z=r.valueAsNumber||u&&+u;we(_.value)||(T=z>_.value),we(V.value)||(B=z<V.value)}if((T||B)&&(I(!!T,_.message,V.message,Ai,Li),!t))return M(j[y].message),j}if((l||m)&&!C&&(Se(u)||a&&Array.isArray(u))){const T=Ye(l),B=Ye(m),_=!we(T.value)&&u.length>+T.value,V=!we(B.value)&&u.length<+B.value;if((_||V)&&(I(_,T.message,B.message),!t))return M(j[y].message),j}if(x&&!C&&Se(u)){const{value:T,message:B}=Ye(x);if(Et(T)&&!u.match(T)&&(j[y]={type:ro,message:B,ref:r,...D(ro,B)},!t))return M(B),j}if(w){if(Ee(w)){const T=yo(await w(u,n),S);if(T&&(j[y]={...T,...D(zi,T.message)},!t))return M(T.message),j}else if(me(w)){let T={};for(const B in w){if(!ke(T)&&!t)break;const _=yo(await w[B](u,n),S,B);_&&(T={..._,...D(B,_.message)},M(_.message),t&&(j[y]=T))}if(!ke(T)&&(j[y]={ref:S,...T},!t))return j}}return M(!0),j};const qi={mode:cr,reValidateMode:lr,shouldFocusError:!0};function Gi(e={}){let o,n={...qi,...e},t={submitCount:0,isDirty:!1,isReady:!1,isLoading:Ee(n.defaultValues),isValidating:!1,isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,touchedFields:{},dirtyFields:{},validatingFields:{},errors:n.errors||{},disabled:n.disabled||!1},s={},a=(me(n.defaultValues)||me(n.values))&&ge(n.defaultValues||n.values)||{},r=n.shouldUnregister?{}:ge(a),c={action:!1,mount:!1,watch:!1},i={mount:new Set,disabled:new Set,unMount:new Set,array:new Set,watch:new Set},l=0;const m={isDirty:!1,dirtyFields:!1,validatingFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1};let k={...m};const g={array:ao(),state:ao()},x=n.criteriaMode===pt,w=async d=>{if(!n.disabled&&(m.isValid||k.isValid||d)){const b=n.resolver?ke((await S()).errors):await M(s,!0);b!==t.isValid&&g.state.next({isValid:b})}},y=(d,b)=>{!n.disabled&&(m.isValidating||m.validatingFields||k.isValidating||k.validatingFields)&&((d||Array.from(i.mount)).forEach(E=>{E&&(b?ce(t.validatingFields,E,b):pe(t.validatingFields,E))}),g.state.next({validatingFields:t.validatingFields,isValidating:!ke(t.validatingFields)}))},h=(d,b,E,F)=>{const A=K(s,d);if(A){const R=K(r,d,fe(E)?K(a,d):E);fe(R)||F&&F.defaultChecked||b?ce(r,d,b?R:uo(A._f)):O(d,R),c.mount&&w()}},v=(d,b,E,F,A)=>{let R=!1,W=!1;const Y={name:d};if(!n.disabled){if(!E||F){(m.isDirty||k.isDirty)&&(W=t.isDirty,t.isDirty=Y.isDirty=j(),R=W!==Y.isDirty);const q=Ae(K(a,d),b);W=!!K(t.dirtyFields,d),q?pe(t.dirtyFields,d):ce(t.dirtyFields,d,!0),Y.dirtyFields=t.dirtyFields,R=R||(m.dirtyFields||k.dirtyFields)&&W!==!q}if(E){const q=K(t.touchedFields,d);q||(ce(t.touchedFields,d,E),Y.touchedFields=t.touchedFields,R=R||(m.touchedFields||k.touchedFields)&&q!==E)}R&&A&&g.state.next(Y)}return R?Y:{}},u=(d,b,E,F)=>{const A=K(t.errors,d),R=(m.isValid||k.isValid)&&Te(b)&&t.isValid!==b;var W;if(n.delayError&&E?(W=()=>((Y,q)=>{ce(t.errors,Y,q),g.state.next({errors:t.errors})})(d,E),o=Y=>{clearTimeout(l),l=setTimeout(W,Y)},o(n.delayError)):(clearTimeout(l),o=null,E?ce(t.errors,d,E):pe(t.errors,d)),(E?!Ae(A,E):A)||!ke(F)||R){const Y={...F,...R&&Te(b)?{isValid:b}:{},errors:t.errors,name:d};t={...t,...Y},g.state.next(Y)}},S=async d=>{y(d,!0);const b=await n.resolver(r,n.context,((E,F,A,R)=>{const W={};for(const Y of E){const q=K(F,Y);q&&ce(W,Y,q._f)}return{criteriaMode:A,names:[...E],fields:W,shouldUseNativeValidation:R}})(d||i.mount,s,n.criteriaMode,n.shouldUseNativeValidation));return y(d),b},M=async(d,b,E={valid:!0})=>{for(const F in d){const A=d[F];if(A){const{_f:R,...W}=A;if(R){const Y=i.array.has(R.name),q=A._f&&Ki(A._f);q&&m.validatingFields&&y([R.name],!0);const Q=await go(A,i.disabled,r,x,n.shouldUseNativeValidation&&!b,Y);if(q&&m.validatingFields&&y([R.name]),Q[R.name]&&(E.valid=!1,b))break;!b&&(K(Q,R.name)?Y?Yi(t.errors,Q,R.name):ce(t.errors,R.name,Q[R.name]):pe(t.errors,R.name))}!ke(W)&&await M(W,b,E)}}return E.valid},j=(d,b)=>!n.disabled&&(d&&b&&ce(r,d,b),!Ae(B(),a)),$=(d,b,E)=>((F,A,R,W,Y)=>Se(F)?(W&&A.watch.add(F),K(R,F,Y)):Array.isArray(F)?F.map(q=>(W&&A.watch.add(q),K(R,q))):(W&&(A.watchAll=!0),R))(d,i,{...c.mount?r:fe(b)?a:Se(d)?{[d]:b}:b},E,b),O=(d,b,E={})=>{const F=K(s,d);let A=b;if(F){const R=F._f;R&&(!R.disabled&&ce(r,d,hr(b,R)),A=Ot(R.ref)&&we(b)?"":b,pr(R.ref)?[...R.ref.options].forEach(W=>W.selected=A.includes(W.value)):R.refs?ut(R.ref)?R.refs.forEach(W=>{W.defaultChecked&&W.disabled||(Array.isArray(A)?W.checked=!!A.find(Y=>Y===W.value):W.checked=A===W.value||!!A)}):R.refs.forEach(W=>W.checked=W.value===A):yn(R.ref)?R.ref.value="":(R.ref.value=A,R.ref.type||g.state.next({name:d,values:ge(r)})))}(E.shouldDirty||E.shouldTouch)&&v(d,A,E.shouldTouch,E.shouldDirty,!0),E.shouldValidate&&T(d)},P=(d,b,E)=>{for(const F in b){if(!b.hasOwnProperty(F))return;const A=b[F],R=d+"."+F,W=K(s,R);(i.array.has(d)||me(A)||W&&!W._f)&&!$e(A)?P(R,A,E):O(R,A,E)}},C=(d,b,E={})=>{const F=K(s,d),A=i.array.has(d),R=ge(b);ce(r,d,R),A?(g.array.next({name:d,values:ge(r)}),(m.isDirty||m.dirtyFields||k.isDirty||k.dirtyFields)&&E.shouldDirty&&g.state.next({name:d,dirtyFields:qe(a,r),isDirty:j(d,R)})):!F||F._f||we(R)?O(d,R,E):P(d,R,E),mo(d,i)&&g.state.next({...t,name:d}),g.state.next({name:c.mount?d:void 0,values:ge(r)})},D=async d=>{c.mount=!0;const b=d.target;let E=b.name,F=!0;const A=K(s,E),R=q=>{F=Number.isNaN(q)||$e(q)&&isNaN(q.getTime())||Ae(q,K(r,E,q))},W=po(n.mode),Y=po(n.reValidateMode);if(A){let q,Q;const te=b.type?uo(A._f):(le=>me(le)&&le.target?ut(le.target)?le.target.checked:le.target.value:le)(d),ae=d.type===Ni||d.type===Bi,ue=!(le=>le.mount&&(le.required||le.min||le.max||le.maxLength||le.minLength||le.pattern||le.validate))(A._f)&&!n.resolver&&!K(t.errors,E)&&!A._f.deps||((le,U,he,et,Re)=>!Re.isOnAll&&(!he&&Re.isOnTouch?!(U||le):(he?et.isOnBlur:Re.isOnBlur)?!le:!(he?et.isOnChange:Re.isOnChange)||le))(ae,K(t.touchedFields,E),t.isSubmitted,Y,W),Oe=mo(E,i,ae);ce(r,E,te),ae?b&&b.readOnly||(A._f.onBlur&&A._f.onBlur(d),o&&o(0)):A._f.onChange&&A._f.onChange(d);const be=v(E,te,ae),G=!ke(be)||Oe;if(!ae&&g.state.next({name:E,type:d.type,values:ge(r)}),ue)return(m.isValid||k.isValid)&&(n.mode==="onBlur"?ae&&w():ae||w()),G&&g.state.next({name:E,...Oe?{}:be});if(!ae&&Oe&&g.state.next({...t}),n.resolver){const{errors:le}=await S([E]);if(R(te),F){const U=ho(t.errors,s,E),he=ho(le,s,U.name||E);q=he.error,E=he.name,Q=ke(le)}}else y([E],!0),q=(await go(A,i.disabled,r,x,n.shouldUseNativeValidation))[E],y([E]),R(te),F&&(q?Q=!1:(m.isValid||k.isValid)&&(Q=await M(s,!0)));F&&(A._f.deps&&(!Array.isArray(A._f.deps)||A._f.deps.length>0)&&T(A._f.deps),u(E,Q,q,be))}},I=(d,b)=>{if(K(t.errors,b)&&d.focus)return d.focus(),1},T=async(d,b={})=>{let E,F;const A=st(d);if(n.resolver){const R=await(async W=>{const{errors:Y}=await S(W);if(W)for(const q of W){const Q=K(Y,q);Q?ce(t.errors,q,Q):pe(t.errors,q)}else t.errors=Y;return Y})(fe(d)?d:A);E=ke(R),F=d?!A.some(W=>K(R,W)):E}else d?(F=(await Promise.all(A.map(async R=>{const W=K(s,R);return await M(W&&W._f?{[R]:W}:W)}))).every(Boolean),(F||t.isValid)&&w()):F=E=await M(s);return g.state.next({...!Se(d)||(m.isValid||k.isValid)&&E!==t.isValid?{}:{name:d},...n.resolver||!d?{isValid:E}:{},errors:t.errors}),b.shouldFocus&&!F&&dt(s,I,d?A:i.mount),F},B=(d,b)=>{let E={...c.mount?r:a};return b&&(E=dr(b.dirtyFields?t.dirtyFields:t.touchedFields,E)),fe(d)?E:Se(d)?K(E,d):d.map(F=>K(E,F))},_=(d,b)=>({invalid:!!K((b||t).errors,d),isDirty:!!K((b||t).dirtyFields,d),error:K((b||t).errors,d),isValidating:!!K(t.validatingFields,d),isTouched:!!K((b||t).touchedFields,d)}),V=(d,b,E)=>{const F=(K(s,d,{_f:{}})._f||{}).ref,A=K(t.errors,d)||{},{ref:R,message:W,type:Y,...q}=A;ce(t.errors,d,{...q,...b,ref:F}),g.state.next({name:d,errors:t.errors,isValid:!1}),E&&E.shouldFocus&&F&&F.focus&&F.focus()},z=d=>g.state.subscribe({next:b=>{var E,F,A;E=d.name,F=b.name,A=d.exact,E&&F&&E!==F&&!st(E).some(R=>R&&(A?R===F:R.startsWith(F)||F.startsWith(R)))||!((R,W,Y,q)=>{Y(R);const{name:Q,...te}=R;return ke(te)||Object.keys(te).length>=Object.keys(W).length||Object.keys(te).find(ae=>W[ae]===(!q||pt))})(b,d.formState||m,re,d.reRenderRoot)||d.callback({values:{...r},...t,...b,defaultValues:a})}}).unsubscribe,H=(d,b={})=>{for(const E of d?st(d):i.mount)i.mount.delete(E),i.array.delete(E),b.keepValue||(pe(s,E),pe(r,E)),!b.keepError&&pe(t.errors,E),!b.keepDirty&&pe(t.dirtyFields,E),!b.keepTouched&&pe(t.touchedFields,E),!b.keepIsValidating&&pe(t.validatingFields,E),!n.shouldUnregister&&!b.keepDefaultValue&&pe(a,E);g.state.next({values:ge(r)}),g.state.next({...t,...b.keepDirty?{isDirty:j()}:{}}),!b.keepIsValid&&w()},Z=({disabled:d,name:b})=>{(Te(d)&&c.mount||d||i.disabled.has(b))&&(d?i.disabled.add(b):i.disabled.delete(b))},X=(d,b={})=>{let E=K(s,d);const F=Te(b.disabled)||Te(n.disabled);return ce(s,d,{...E||{},_f:{...E&&E._f?E._f:{ref:{name:d}},name:d,mount:!0,...b}}),i.mount.add(d),E?Z({disabled:Te(b.disabled)?b.disabled:n.disabled,name:d}):h(d,!0,b.value),{...F?{disabled:b.disabled||n.disabled}:{},...n.progressive?{required:!!b.required,min:at(b.min),max:at(b.max),minLength:at(b.minLength),maxLength:at(b.maxLength),pattern:at(b.pattern)}:{},name:d,onChange:D,onBlur:D,ref:A=>{if(A){X(d,b),E=K(s,d);const R=fe(A.value)&&A.querySelectorAll&&A.querySelectorAll("input,select,textarea")[0]||A,W=(q=>gn(q)||ut(q))(R),Y=E._f.refs||[];if(W?Y.find(q=>q===R):R===E._f.ref)return;ce(s,d,{_f:{...E._f,...W?{refs:[...Y.filter($t),R,...Array.isArray(K(a,d))?[{}]:[]],ref:{type:R.type,name:d}}:{ref:R}}}),h(d,!1,void 0,R)}else E=K(s,d,{}),E._f&&(E._f.mount=!1),(n.shouldUnregister||b.shouldUnregister)&&(!((R,W)=>R.has((Y=>Y.substring(0,Y.search(/\.\d+(\.|$)/))||Y)(W)))(i.array,d)||!c.action)&&i.unMount.add(d)}}},J=()=>n.shouldFocusError&&dt(s,I,i.mount),ne=(d,b)=>async E=>{let F;E&&(E.preventDefault&&E.preventDefault(),E.persist&&E.persist());let A=ge(r);if(g.state.next({isSubmitting:!0}),n.resolver){const{errors:R,values:W}=await S();t.errors=R,A=ge(W)}else await M(s);if(i.disabled.size)for(const R of i.disabled)pe(A,R);if(pe(t.errors,"root"),ke(t.errors)){g.state.next({errors:{}});try{await d(A,E)}catch(R){F=R}}else b&&await b({...t.errors},E),J(),setTimeout(J);if(g.state.next({isSubmitted:!0,isSubmitting:!1,isSubmitSuccessful:ke(t.errors)&&!F,submitCount:t.submitCount+1,errors:t.errors}),F)throw F},oe=(d,b={})=>{const E=d?ge(d):a,F=ge(E),A=ke(d),R=A?a:F;if(b.keepDefaultValues||(a=E),!b.keepValues){if(b.keepDirtyValues){const W=new Set([...i.mount,...Object.keys(qe(a,r))]);for(const Y of Array.from(W))K(t.dirtyFields,Y)?ce(R,Y,K(r,Y)):C(Y,K(R,Y))}else{if(mn&&fe(d))for(const W of i.mount){const Y=K(s,W);if(Y&&Y._f){const q=Array.isArray(Y._f.refs)?Y._f.refs[0]:Y._f.ref;if(Ot(q)){const Q=q.closest("form");if(Q){Q.reset();break}}}}if(b.keepFieldsRef)for(const W of i.mount)C(W,K(R,W));else s={}}r=n.shouldUnregister?b.keepDefaultValues?ge(a):{}:ge(R),g.array.next({values:{...R}}),g.state.next({values:{...R}})}i={mount:b.keepDirtyValues?i.mount:new Set,unMount:new Set,array:new Set,disabled:new Set,watch:new Set,watchAll:!1,focus:""},c.mount=!m.isValid||!!b.keepIsValid||!!b.keepDirtyValues,c.watch=!!n.shouldUnregister,g.state.next({submitCount:b.keepSubmitCount?t.submitCount:0,isDirty:!A&&(b.keepDirty?t.isDirty:!(!b.keepDefaultValues||Ae(d,a))),isSubmitted:!!b.keepIsSubmitted&&t.isSubmitted,dirtyFields:A?{}:b.keepDirtyValues?b.keepDefaultValues&&r?qe(a,r):t.dirtyFields:b.keepDefaultValues&&d?qe(a,d):b.keepDirty?t.dirtyFields:{},touchedFields:b.keepTouched?t.touchedFields:{},errors:b.keepErrors?t.errors:{},isSubmitSuccessful:!!b.keepIsSubmitSuccessful&&t.isSubmitSuccessful,isSubmitting:!1,defaultValues:a})},ee=(d,b)=>oe(Ee(d)?d(r):d,b),re=d=>{t={...t,...d}},ie={control:{register:X,unregister:H,getFieldState:_,handleSubmit:ne,setError:V,_subscribe:z,_runSchema:S,_focusError:J,_getWatch:$,_getDirty:j,_setValid:w,_setFieldArray:(d,b=[],E,F,A=!0,R=!0)=>{if(F&&E&&!n.disabled){if(c.action=!0,R&&Array.isArray(K(s,d))){const W=E(K(s,d),F.argA,F.argB);A&&ce(s,d,W)}if(R&&Array.isArray(K(t.errors,d))){const W=E(K(t.errors,d),F.argA,F.argB);A&&ce(t.errors,d,W),((Y,q)=>{!Xt(K(Y,q)).length&&pe(Y,q)})(t.errors,d)}if((m.touchedFields||k.touchedFields)&&R&&Array.isArray(K(t.touchedFields,d))){const W=E(K(t.touchedFields,d),F.argA,F.argB);A&&ce(t.touchedFields,d,W)}(m.dirtyFields||k.dirtyFields)&&(t.dirtyFields=qe(a,r)),g.state.next({name:d,isDirty:j(d,b),dirtyFields:t.dirtyFields,errors:t.errors,isValid:t.isValid})}else ce(r,d,b)},_setDisabledField:Z,_setErrors:d=>{t.errors=d,g.state.next({errors:t.errors,isValid:!1})},_getFieldArray:d=>Xt(K(c.mount?r:a,d,n.shouldUnregister?K(a,d,[]):[])),_reset:oe,_resetDefaultValues:()=>Ee(n.defaultValues)&&n.defaultValues().then(d=>{ee(d,n.resetOptions),g.state.next({isLoading:!1})}),_removeUnmounted:()=>{for(const d of i.unMount){const b=K(s,d);b&&(b._f.refs?b._f.refs.every(E=>!$t(E)):!$t(b._f.ref))&&H(d)}i.unMount=new Set},_disableForm:d=>{Te(d)&&(g.state.next({disabled:d}),dt(s,(b,E)=>{const F=K(s,E);F&&(b.disabled=F._f.disabled||d,Array.isArray(F._f.refs)&&F._f.refs.forEach(A=>{A.disabled=F._f.disabled||d}))},0,!1))},_subjects:g,_proxyFormState:m,get _fields(){return s},get _formValues(){return r},get _state(){return c},set _state(d){c=d},get _defaultValues(){return a},get _names(){return i},set _names(d){i=d},get _formState(){return t},get _options(){return n},set _options(d){n={...n,...d}}},subscribe:d=>(c.mount=!0,k={...k,...d.formState},z({...d,formState:k})),trigger:T,register:X,handleSubmit:ne,watch:(d,b)=>Ee(d)?g.state.subscribe({next:E=>"values"in E&&d($(void 0,b),E)}):$(d,b,!0),setValue:C,getValues:B,reset:ee,resetField:(d,b={})=>{K(s,d)&&(fe(b.defaultValue)?C(d,ge(K(a,d))):(C(d,b.defaultValue),ce(a,d,ge(b.defaultValue))),b.keepTouched||pe(t.touchedFields,d),b.keepDirty||(pe(t.dirtyFields,d),t.isDirty=b.defaultValue?j(d,ge(K(a,d))):j()),b.keepError||(pe(t.errors,d),m.isValid&&w()),g.state.next({...t}))},clearErrors:d=>{d&&st(d).forEach(b=>pe(t.errors,b)),g.state.next({errors:d?t.errors:{}})},unregister:H,setError:V,setFocus:(d,b={})=>{const E=K(s,d),F=E&&E._f;if(F){const A=F.refs?F.refs[0]:F.ref;A.focus&&(A.focus(),b.shouldSelect&&Ee(A.select)&&A.select())}},getFieldState:_};return{...ie,formControl:ie}}function Xi(e={}){const o=p.useRef(void 0),n=p.useRef(void 0),[t,s]=p.useState({isDirty:!1,isValidating:!1,isLoading:Ee(e.defaultValues),isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,submitCount:0,dirtyFields:{},touchedFields:{},validatingFields:{},errors:e.errors||{},disabled:e.disabled||!1,isReady:!1,defaultValues:Ee(e.defaultValues)?void 0:e.defaultValues});if(!o.current)if(e.formControl)o.current={...e.formControl,formState:t},e.defaultValues&&!Ee(e.defaultValues)&&e.formControl.reset(e.defaultValues,e.resetOptions);else{const{formControl:r,...c}=Gi(e);o.current={...c,formState:t}}const a=o.current.control;return a._options=e,Ui(()=>{const r=a._subscribe({formState:a._proxyFormState,callback:()=>s({...a._formState}),reRenderRoot:!0});return s(c=>({...c,isReady:!0})),a._formState.isReady=!0,r},[a]),p.useEffect(()=>a._disableForm(e.disabled),[a,e.disabled]),p.useEffect(()=>{e.mode&&(a._options.mode=e.mode),e.reValidateMode&&(a._options.reValidateMode=e.reValidateMode)},[a,e.mode,e.reValidateMode]),p.useEffect(()=>{e.errors&&(a._setErrors(e.errors),a._focusError())},[a,e.errors]),p.useEffect(()=>{e.shouldUnregister&&a._subjects.state.next({values:a._getWatch()})},[a,e.shouldUnregister]),p.useEffect(()=>{if(a._proxyFormState.isDirty){const r=a._getDirty();r!==t.isDirty&&a._subjects.state.next({isDirty:r})}},[a,t.isDirty]),p.useEffect(()=>{e.values&&!Ae(e.values,n.current)?(a._reset(e.values,{keepFieldsRef:!0,...a._options.resetOptions}),n.current=e.values,s(r=>({...r}))):a._resetDefaultValues()},[a,e.values]),p.useEffect(()=>{a._state.mount||(a._setValid(),a._state.mount=!0),a._state.watch&&(a._state.watch=!1,a._subjects.state.next({...a._formState})),a._removeUnmounted()}),o.current.formState=((r,c,i,l=!0)=>{const m={defaultValues:c._defaultValues};for(const k in r)Object.defineProperty(m,k,{get:()=>{const g=k;return c._proxyFormState[g]!==pt&&(c._proxyFormState[g]=!l||pt),r[g]}});return m})(t,a),o.current}const Qi=["Ok","Cancel"],Zt=p.memo(p.forwardRef((e,o)=>{const{description:n,icon:t,onCancel:s,onOption:a,onDone:r,onValidateOption:c,createOptionsButton:i,options:l=Qi,autoFocusSel:m=".defaultOption",defaultOption:k=l[0],cancelOption:g="Cancel",autoFocus:x,children:w,...y}=e,h=Xi({shouldUseNativeValidation:!1}),{handleSubmit:v,formState:u}=h,S=p.useRef(null),M=p.useRef(null),j=p.useRef(null),$=N.useCallbackRef(async T=>{let B;try{if(B=await Promise.resolve(c?.(T))??!0,B!==!0)return;await Promise.resolve(a?.(T,T===g,T===k)),r?.(T)}catch{}},[a,r,c,g,k]),O=N.useCallbackRef((T,B)=>{setTimeout(()=>{$(k)},180)},[$]),P=N.useCallbackRef(()=>{a?.(g,!0,!1),s?.(),r?.(null)},[a,g,s,r]),C=u&&(Object.keys(u.errors).length>0||u.disabled||u.isSubmitted),D=N.useCallbackRef((T,B)=>{const _=T===g,V={className:B?"defaultOption":"action",type:B?"submit":"button",style:{minWidth:"75px"},onClick:()=>{_?P():B||$(T)}};if(i)return i(T,V,B);const z={className:B?"defaultOption":"action",variant:B?"contained":"outlined",size:"small",disabled:!_&&C,color:"primary",...V};if(B||_){const H=B?S:M;z.touchRippleRef=H,z.onPointerDown=Z=>{H.current?.start(Z,{center:!1}),Z.stopPropagation(),Z.preventDefault()}}return f.jsx(L.Button,{...z,children:f.jsx("div",{style:{paddingTop:"3px"},children:T})},`action:${T}`)},[l,k,g,i,u]),I=p.useMemo(()=>{const T=[];for(let B=0;B<l.length;B++){const _=l[B],V=k?_===k:B===0;T.push(D(_,V))}return T},[l,k,u]);return f.jsx(rr,{onCancel:P,initialPosition:{y:Fi==="touch"?"15":"35"},onDone:r,autoFocusSel:m,isModal:!0,ref:o,...y,children:f.jsx(Wi,{...h,children:f.jsxs("form",{ref:j,onSubmit:v(O),children:[f.jsx(L.DialogContent,{dividers:!0,onKeyDown:T=>{if(T.isDefaultPrevented())return;T.stopPropagation();let B=null,_=null;const V=T.which===N.KeyCodes.Escape&&g;if(V)B=g,_=M;else{if(C)return;T.which===N.KeyCodes.Enter&&(B=k??l[0],_=S)}B&&(_.current?.start(T,{center:!1}),setTimeout(()=>{_.current?.stop(T),V&&$(B)},180))},children:f.jsxs(L.Box,{sx:{display:"flex",flexDirection:"column",whiteSpace:"pre-wrap",rowGap:T=>T.spacing(t||n?1.5:0)},children:[f.jsxs(L.Box,{sx:{display:"flex",flexDirection:"column"},children:[t,f.jsx(L.Typography,{children:n})]}),w]})}),f.jsx(L.DialogActions,{sx:{paddingTop:T=>T.spacing(1),paddingBottom:T=>T.spacing(1),paddingLeft:T=>T.spacing(1),paddingRight:T=>T.spacing(1),backgroundColor:T=>se.alpha(T.palette.action.hover,.03)},children:I})]})})})})),Ji=Object.freeze(Object.defineProperty({__proto__:null,OptionsDialog:Zt,default:Zt},Symbol.toStringTag,{value:"Module"})),Zi=p.lazy(()=>Promise.resolve().then(()=>Ji)),ea=p.lazy(()=>Promise.resolve().then(()=>require("./DTu7X4NVQR5Imqxw.cjs"))),Ft=p.memo(p.forwardRef((e,o)=>{const{command:n,disabled:t=!1,shortcut:s,children:a,...r}=e;return N.useCommand(n),f.jsx(Ke,{ref:o,label:t!==void 0?n?.label():"",shortcut:s!==void 0?s:Array.isArray(n?.shortcut())?n?.shortcut()[0]:n?.shortcut(),description:n?.description(),disabled:t,chips:n?.tags(),componentDisabled:n?.disabled(),...r,children:f.jsx("div",{style:{display:"flex",flex:"1 1 0%"},children:a})})})),ta=f.jsx(N.DynamicIcon,{}),bn=p.memo(p.forwardRef((e,o)=>{const{command:n,commandHook:t,scope:s,context:a,icon:r,label:c,disabled:i=!1,variant:l=N.CommandButtonType.Toolbar,shortcut:m,commandState:k,tooltipProps:g,...x}=e,w=p.useRef(null),y=p.useRef(!1),h=p.useMemo(()=>{const P={onExecute(C,D){t?.onExecute?.(C,D),y.current||(w.current?.start({center:!1}),setTimeout(()=>w.current?.stop({}),180)),y.current=!1},onError(C,D,I){t?.onError(C,D,I)}};return t?.beforeExecute&&(P.beforeExecute=t.beforeExecute),P},[t]),v=N.useCommand(n,h),u=p.useCallback(P=>{P.button===0&&P.preventDefault()},[]),S=p.useCallback(P=>{P.button===0&&n?.execute(k,t)},[v,t,k]),M=p.useCallback(P=>{P.keyCode!==N.KeyCodes.Enter&&P.keyCode!==N.KeyCodes.Space||n?.execute(k,t)},[v,t,k]),j=p.useMemo(()=>{if(r)return typeof r=="function"?r(n):r;let P=n?.icon(a);return P?(typeof P=="string"&&(P=f.jsx(N.DynamicIcon,{iconKey:P})),P):l===N.CommandButtonType.Toolbar||n?.state()?void 0:ta},[v,r]),$=p.useMemo(()=>({tabIndex:0,ref:o,selected:n?.state(),icon:l===N.CommandButtonType.Toolbar?j:f.jsx(zo,{selected:n?.state()??!1,children:j}),touchRippleRef:w,disabled:i||!n||n.disabled(),onMouseDown:u,onMouseUp:S,onKeyDown:M}),[v,t,i,j]);let O;return O=l===N.CommandButtonType.Menuitem?f.jsx(Je,{...x,chips:n?.tags(),...$,children:c??n?.label(s,a)}):f.jsx(mt,{...x,...$}),(c||n?.label())&&((n.disabled()||i)&&(O=f.jsx("div",{children:O})),O=f.jsx(Ft,{command:n,placement:l===N.CommandButtonType.Toolbar?"bottom-start":"right-start",shortcut:m,...g,children:O})),O}));bn.displayName="CommandButton";const na=f.jsx(N.DynamicIcon,{}),oa=p.memo(p.forwardRef((e,o)=>{const{command:n,scope:t,icon:s=na,label:a,variant:r=N.CommandButtonType.Toolbar,disabled:c=!1,commandHook:i,...l}=e,m=p.useRef(null),k=p.useRef(!1),g=p.useMemo(()=>{const O={onExecute(P,C){i?.onExecute?.(P,C),k.current||(m.current?.start({center:!1}),setTimeout(()=>m.current?.stop({}),180)),k.current=!1},onError(P,C,D){i?.onError(P,C,D)}};return i?.beforeExecute&&(O.beforeExecute=i.beforeExecute),O},[i]),x=N.useCommand(n,g),w=()=>n?.state()?.toString()||"0",[y,h]=p.useState(w),v=N.useCallbackRef(()=>{const O=parseFloat(y);isNaN(O)?h(w()):parseFloat(w())!==O&&n.execute(O,i)},[w,n,y,i]);p.useEffect(()=>{h(w())},[n?.state()]);const u=p.useMemo(()=>{let O=typeof s=="function"?s(n):s;return O&&(O=n?.icon()),typeof O=="string"&&(O=f.jsx(N.DynamicIcon,{iconKey:O})),O},[x,s,n?.icon]),S=p.useMemo(()=>a===void 0?n?.label(t):typeof a=="function"?a():a,[x]),M=p.useMemo(()=>f.jsx(L.IconButton,{...l,sx:{paddingTop:"0px",paddingBottom:"0px"},component:"div",disableRipple:!0,onClick:O=>O.stopPropagation(),onMouseDown:O=>{O.button===0&&O.stopPropagation()},onMouseUp:O=>{O.button===0&&O.stopPropagation()},children:f.jsx(L.Input,{inputMode:"numeric",disabled:c||!n||n.disabled(),inputProps:{tabIndex:0,name:`input-${n.key()}`,autoComplete:"off",type:"number",maxLength:4},sx:{paddingTop:"0px",paddingBottom:"0px",paddingLeft:"0px",paddingRight:"0px",fontSize:O=>`${Math.round(O.typography.fontSize)}px`,width:O=>"3.2em",input:{padding:"0 0",textAlign:"center",MozAppearance:"textfield"},"input::-webkit-inner-spin-button":{WebkitAppearance:"none",margin:"0"},minHeight:"24px"},value:y,onFocus:O=>{O.target?.select()},onKeyDown:O=>{if(O.which===N.KeyCodes.Enter)w()!==y&&(O.stopPropagation(),O.preventDefault(),v());else if(O.which===N.KeyCodes.Escape)w()!==y&&(h(w()),setTimeout(()=>{O.target?.select()},0),O.stopPropagation(),O.preventDefault());else{if(O.key.match("[-]")||O.key.match("[0-9.]")&&(y+O.key).length>4)return O.stopPropagation(),void O.preventDefault();if(O.which===N.KeyCodes.Space)return void O.preventDefault()}},onBlur:()=>{v()},onChange:O=>{if(O.target.value.length>4)return O.stopPropagation(),void O.preventDefault();h(O.target.value)}})}),[y,c,n]),j={tabIndex:0,ref:o,icon:u,touchRippleRef:m,disabled:c||!n||n.disabled(),onMouseDown:O=>{O.button===0&&O.preventDefault()},onMouseUp:O=>{O.button!==0||O.isPropagationStopped()||O.isDefaultPrevented()||O.isDefaultPrevented()||(O.preventDefault(),n?.execute(!n?.state?.(),g))},onKeyDown:O=>{O.keyCode!==N.KeyCodes.Enter&&O.keyCode!==N.KeyCodes.Space||n?.execute(!n?.state?.(),g)}};let $;return $=r===N.CommandButtonType.Menuitem?f.jsxs(Je,{...l,chips:n?.tags(),...j,children:[S,M]}):f.jsx(mt,{...l,...j}),n?.label()&&((n.disabled()||c)&&($=f.jsx("div",{children:$})),$=f.jsx(Ft,{command:n,placement:r===N.CommandButtonType.Toolbar?"bottom-start":"right-start",children:$})),$})),vn=p.memo(p.forwardRef((e,o)=>{const{variant:n=N.CommandButtonType.Toolbar,quickCommand:t,onQuickClick:s,commands:a,commandState:r,commandHook:c,disabled:i,label:l,icon:m,createPopupPanel:k,tooltip:g,selected:x,scope:w,...y}=e,h=p.useRef(null),v=p.useRef(!1),u=p.useMemo(()=>{const D={onExecute(I,T){c?.onExecute?.(I,T),v.current||(h.current?.start({center:!1}),setTimeout(()=>h.current?.stop({}),180)),v.current=!1},onError(I,T,B){c?.onError(I,T,B)}};return c?.beforeExecute&&(D.beforeExecute=c.beforeExecute),D},[c]),S=N.useCommands(a,[t],null,[t]),M=S[0],{label:j,icon:$}=p.useMemo(()=>{let D=null;l&&(D=typeof l=="function"?l(M):l),D||(D=M?.label?.(w));let I=m;return I||(I=M?.icon?.()),typeof I=="string"?I=f.jsx(N.DynamicIcon,{iconKey:I}):typeof I=="function"&&(I=I(M)),{label:D,icon:I}},[S,l,m]),O={disabled:i,scope:w,touchRippleRef:h,onQuickClick:s,tooltip:g,label:j,icon:$};(j||g)&&(O.createTooltip=({children:D},I)=>f.jsx(Ke,{label:j,description:g,disabled:I,children:D}));const P=N.useCallbackRef(D=>k?.(D,a),[k,S]),C=N.useCallbackRef(D=>M?.execute(r,u),[M]);return M?(O.quickButtonProps={},O.quickButtonProps.createTooltip=({children:D,placement:I},T)=>f.jsx(Ft,{command:M,placement:I??n===N.CommandButtonType.Toolbar?"bottom-start":"right-start",disabled:T,children:D}),O.disabled=O.disabled??M?.disabled(),s||(O.onQuickClick=C)):t&&(O.onQuickClick=()=>{}),O.selected=x??M?.state(),O.createPopupPanel=P,n===N.CommandButtonType.Toolbar?f.jsx(jt,{...y,...O,ref:o}):f.jsx(un,{...y,...O,ref:o})}));vn.displayName="CommandPopupButton";const ra=f.jsx(N.DynamicIcon,{iconKey:"Check"}),gr=p.memo(p.forwardRef((e,o)=>{const{sx:n,commands:t,commandButtonProps:s,parentFloat:a,createToolbarPalette:r,children:c,...i}=e,l=N.useImperativeElement(o,()=>({}),[]),[m,k]=p.useState(null),{reference:g}=ft({label:"toolbar",anchor:l.current,parentFloat:a,createPopupPanel:null}),x=p.useCallback(()=>{const O=m;O&&requestAnimationFrame(()=>{l.current?.contains(document.activeElement)&&O.focus()})},[]),w=p.useMemo(()=>({dense:!0,outlined:!1}),[]),y=p.useMemo(()=>{const{commandHook:O,...P}=s||{};return{commandHook:{beforeExecute:(C,D)=>O?.beforeExecute?.(C,D)!==!1&&g.closeAll(),onExecute(C,D){O?.onExecute?.(C,D),x()},onError(C,D,I){O?.onError?.(C,D,I)}},...P}},[g,s]),h=p.useMemo(()=>({...w,...y}),[w,y]),[v,u]=p.useReducer(O=>O+1,0);N.useCommands(t,[],{onChange:()=>{u()}});const S=p.useMemo(()=>({commands:t,parentFloat:g,...y}),[v,h,g,s]);let M=0;w.dense||(M+=2),w.outlined&&M++;let j=2;w.dense||(j=4);const $=p.useMemo(()=>r({commands:t,commandButtonProps:h,commandPopupProps:{commands:t,...S,...s}}),[v,h,S,r]);return f.jsx(L.Toolbar,{variant:"dense",sx:{minHeight:"unset",height:"unset",paddingTop:`${j}px`,paddingBottom:`${j}px`,paddingLeft:"6px !important",paddingRight:"6px !important",flex:"1 1 0%",alignItems:"center",userSelect:"none",flexGrow:1,display:"flex",overflow:"hidden",...n},ref:l,onFocus:O=>{O.relatedTarget&&!m&&k(O.relatedTarget)},onBlur:O=>{m&&!l?.current?.contains(O.relatedTarget)&&k(null)},onKeyDown:O=>{m&&O.which===N.KeyCodes.Escape&&m.focus()},...i,children:f.jsx("div",{ref:l,style:{flex:"1 1 100%",display:"flex",flexWrap:"wrap",rowGap:`${j}px`,columnGap:`${M}px`,alignItems:"center",maxWidth:"100%"},children:$})})}));gr.displayName="CommandToolbar";const ia=e=>{const{key:o,...n}=e;return f.jsx(bn,{...n},o)},aa=p.memo(p.forwardRef((e,o)=>{const{popupCommandKeys:n,renderCommandButton:t=ia,scope:s,commands:a,quickCommand:r,popupScope:c=r,commandState:i,commandHook:l,disabled:m=!1,...k}=e,g=N.useCommands(a,n?[r,...n]:[r]),{allDisabled:x}=p.useMemo(()=>{let y=0;const h=g.length;for(let v=0;v<h;v++){const u=g[v];u&&!u.disabled()&&y++}return{allDisabled:y===0}},[g]),w=p.useCallback((y,h)=>{const v={variant:N.CommandButtonType.Menuitem,commandHook:l,commandState:i,scope:c??s,disabled:m},u=[],S=n?n.length:0;for(let M=0;M<S;M++){const j=n[M];if(j===null||j==="-"){u.push(f.jsx(xo,{orientation:"horizontal"},`element-${u.length}`));continue}const $=h.getCommand(j),O={key:`${j}-${u.length}`,command:$,...v},P=t(O);P&&u.push(P)}return Tt({...y,children:u})},[m,l,i,c,n,t]);return n?f.jsx(vn,{ref:o,commands:a,disabled:m||x,commandHook:l,commandState:i,scope:s,quickCommand:r,createPopupPanel:w,...k}):t({ref:o,disabled:m,commandHook:l,commandState:i,scope:s,command:g[0],...k})}));exports.AnimatedBouncingEllipsisIcon=kr,exports.AnimatedCircleIcon=Do,exports.AnimatedClockIcon=xr,exports.AnimatedFadingEllipsisIcon=wr,exports.AnimatedOrbitIcon=Sr,exports.AnimatedTraversingEllipsisIcon=Cr,exports.ArrowDownIcon=Kt,exports.ArrowRightIcon=Io,exports.ChipStrip=nn,exports.ClosingReason={ByPopup:"popupDone",Cancel:"popupCancel",ClickAway:"clickAway"},exports.CommandButton=bn,exports.CommandPopupButton=vn,exports.CommandToolbar=gr,exports.CommandTooltip=Ft,exports.ContextMenu=Vr,exports.ErrorPanel=Mo,exports.ExhibitDivider=xo,exports.ExhibitFloatPanel=ln,exports.ExhibitIconButton=mt,exports.ExhibitMenuHeader=Kr,exports.ExhibitMenuItem=Je,exports.ExhibitOptionButton=qr,exports.ExhibitPopper=an,exports.ExhibitPopupIconButton=jt,exports.ExhibitPopupMenuItem=un,exports.ExhibitTooltip=Ke,exports.InputCommandButton=oa,exports.InternalWindow=rr,exports.LabelIcon=e=>{const{command:o,label:n,scope:t,icon:s=ra,sx:a,...r}=e;return f.jsxs(L.Box,{sx:{display:"flex",flexDirection:"row",textTransform:"none",alignItems:"center",fontSize:c=>c.typography.subtitle2.fontSize,...a},...r,children:[s,f.jsx(L.Typography,{component:"div",sx:{whiteSpace:"nowrap",lineHeight:"1",paddingLeft:c=>c.spacing(.25),paddingRight:c=>c.spacing(.25),fontSize:"inherit"},children:o?.label(t)||n})]})},exports.LoadingPanel=Oo,exports.ModalProvider=function(e){var o=e.children,n=e.legacy,t=n!==void 0&&n,s=e.suspense,a=s===void 0||s,r=e.fallback,c=r===void 0?null:r,i=p.useReducer(Zr,Jr),l=i[0],m=i[1],k=p.useCallback(function(v,u){var S=Wo(u,ei);v?m({type:Ce.UPDATE,payload:{id:v,props:S}}):console.error(Lt)},[m]),g=p.useCallback(function(v){v?m({type:Ce.HIDE,payload:{id:v}}):console.error(Lt)},[m]),x=p.useCallback(function(v){v?m({type:Ce.DESTROY,payload:{id:v}}):console.error(Lt)},[m]),w=p.useCallback(function(v){v?m({type:Ce.DESTROY_BY_ROOT_ID,payload:{rootId:v}}):console.error("[ERROR]: Modal root ID is missing")},[m]),y=p.useCallback(function(v,u,S){var M=Ho(8);return S&&S.rootId&&(M=S.rootId+"."+M),m({type:Ce.SHOW,payload:{id:M,component:v,props:u,options:S}}),{id:M,hide:function(){return g(M)},destroy:function(){return x(M)},update:function(j){return k(M,j)}}},[m,g,x,k]),h=a?p.Suspense:p.Fragment;return p.createElement(Uo.Provider,{value:{state:l,updateModal:k,hideModal:g,destroyModal:x,showModal:y,destroyModalsByRootId:w}},o,p.createElement(h,Object.assign({},a&&{fallback:c}),Object.keys(l).map(function(v){var u=l[v],S=u.component,M=u.props,j=u.options,$=function(){var P,C;M!=null&&M.onExited&&M.onExited.apply(M,arguments),M!=null&&(P=M.TransitionProps)!=null&&P.onExited&&(C=M.TransitionProps).onExited.apply(C,arguments),x(v)},O={};return O=t?{onExited:$}:{TransitionProps:xe({},M?.TransitionProps,{onExited:$})},p.createElement(S,Object.assign({},M,{key:v,onClose:function(){j&&j.hideOnClose&&g(v),j&&j.destroyOnClose&&j.hideOnClose&&x(v),M&&M.onClose&&M.onClose.apply(M,arguments)}},j&&!j.destroyOnClose&&O))})))},exports.NestingPopupButton=$o,exports.OptionsDialog=Zt,exports.PopupAutoFocus={Popup:"popup",Anchor:"anchor"},exports.PopupButtonType=Lo,exports.SelectedIcon=zo,exports.SimpleCommandPopupButton=aa,exports.SimpleTooltip=He,exports.StackTrace=tn,exports.ThemeMode={Light:"light",Dark:"dark"},exports.ThemedIcon=Ir,exports.clsx=ye,exports.createDownArrow=qt,exports.createExhibitTheme=(e,o)=>{let n=We.createTheme({palette:{mode:e?"dark":"light"}});const t={"--icon-primary":n.palette.primary.main,"--icon-secondary":n.palette.secondary.main,"--icon-secondary-light":n.palette.secondary.light,"--icon-success":n.palette.success.main,"--icon-success-light":n.palette.success.light,"--icon-info":n.palette.info.main,"--icon-warn":n.palette.warning.main,"--icon-error":n.palette.error.main,"--icon-error-light":n.palette.error.light,"--icon-grey":n.palette.text.icon??n.palette.action.active,"--icon-shadow":e?n.palette.text.primary:n.palette.divider,"--icon-size":"1.25rem","@media (pointer: coarse)":{"--icon-size":"1.75rem"}};let s={typography:{},palette:{mode:e?"dark":"light",text:{secondary:e?n.palette.text.secondary:se.alpha(n.palette.text.secondary,.75),icon:e?se.alpha(n.palette.text.secondary,.7):se.alpha(n.palette.text.primary,.75)}},components:{MuiDialogTitle:{styleOverrides:{root:{fontWeight:"normal"}}},MuiSelect:{defaultProps:{IconComponent:Kt,MenuProps:{container:()=>document.fullscreenElement??void 0}},styleOverrides:{iconOutlined:{top:"unset"}}},MuiListItemIcon:{styleOverrides:{root:{minWidth:"0px !important",overflow:"hidden",marginLeft:"0px",marginRight:"6px",padding:"1px 1px",border:"solid transparent 1px",color:"unset"}}},MuiMenuItem:{styleOverrides:{root:{paddingTop:"2px",paddingBottom:"2px",marginLeft:"4px",marginRight:"4px",paddingLeft:"6px",paddingRight:"18px",borderRadius:"4px",fontSize:"0.875em","@media (pointer: coarse)":{fontSize:"1em"},"&.Mui-selected":{}}}},MuiMenu:{defaultProps:{container:()=>document.fullscreenElement??void 0},styleOverrides:{root:{paddingTop:"2px",paddingBottom:"2px",marginLeft:"4px",marginRight:"4px",paddingLeft:"6px",paddingRight:"18px",borderRadius:"4px",fontSize:"0.875em","@media (pointer: coarse)":{fontSize:"1em"},"&.Mui-selected":{}}}},MuiToolbar:{styleOverrides:{root:{paddingTop:"4px",paddingBottom:"4px","@media (min-width: 600px)":{paddingTop:"4px",paddingBottom:"4px"}}}},MuiDivider:{styleOverrides:{root:{marginTop:"4px !important",marginBottom:"4px !important",marginLeft:"0px",marginRight:"0px"}}},MuiInputBase:{styleOverrides:{root:{}}},MuiPaper:{styleOverrides:{root:{...t}}},MuiPopper:{styleOverrides:{root:{"& .menu":{marginTop:"4px",marginBottom:"4px",borderRadius:"4px"}}}},SmartInputField:{styleOverrides:{automatic:{transition:"opacity 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms",color:function(){return n.palette.text.secondary}},dirty:{fontStyle:"italic",color:function(){return n.palette.text.secondary}}}}}},a=s;return o&&(a=bo.deepmerge(s,o)),We.createTheme(a)},exports.createScrollButton=Bt,exports.createScrollEdgeButton=e=>{const o={style:{cursor:"pointer"},...e};return N.defaultCreateScrollEdgeButton(o)},exports.createScrollEndButton=e=>Bt(e,N.ScrollbarOrientation.Horizontal?f.jsx(N.DynamicIcon,{iconKey:"ArrowRight",size:"small"}):f.jsx(N.DynamicIcon,{iconKey:"ArrowDownward",size:"small"}),"Scroll "+(e.orientation===N.ScrollbarOrientation.Horizontal?"Right":"Down"),`Scroll ${e.orientation===N.ScrollbarOrientation.Horizontal?"right":"down"}, 'Ctrl+Click' to scroll to the end`),exports.createScrollStartButton=e=>Bt(e,N.ScrollbarOrientation.Horizontal?f.jsx(N.DynamicIcon,{iconKey:"ArrowLeft",size:"small"}):f.jsx(N.DynamicIcon,{iconKey:"ArrowUpward",size:"small"}),"Scroll "+(e.orientation===N.ScrollbarOrientation.Horizontal?"Left":"Up"),`Scroll ${e.orientation===N.ScrollbarOrientation.Horizontal?"left":"up"}, 'Ctrl+Click' to scroll to the beginning`),exports.createStrokeShadowFilter=(e=1)=>o=>{if(o.palette.mode!=="dark")return;const n=o.palette.mode==="dark"?o.palette.text.primary:o.palette.divider;return`drop-shadow(0px 0px ${e}px ${n})`},exports.defaultCreatePopupPanel=Tt,exports.elevateColor=Yt,exports.getModalConfig=Yo,exports.getScrollbarCssVariables=Ao,exports.hexToRGB=_o,exports.overlayAlpha=function(e){let o=0;return o=e<1?5.11916*e**2:4.5*Math.log(e+1)+2,(o/100).toFixed(2)},exports.scrollbarTheming=sn,exports.setModalConfig=function(e){Object.assign(Ko,e)},exports.strokeShadowFilter=e=>{if(e.palette.mode==="dark")return`drop-shadow(0px 0px 1px ${e.palette.mode==="dark"?e.palette.text.primary:e.palette.divider})`},exports.toShortcutElements=cn,exports.useFloatStack=ft,exports.useInputDialog=e=>{const{showModal:o}=ht();return n=>{const{defaultOption:t=n.options?.[0],cancelOption:s="Cancel",...a}=n;return new Promise(r=>{const c=o(ea,{...e,defaultOption:t,cancelOption:s,...a,onOption(i){a?.onOption?.(i,i===s,i===t),r({input:"",option:i})},onInput(i,l){a?.onInput?.(i,l),r({input:i,option:l})},onDone:()=>{a?.onDone?.(),c.hide()}})})}},exports.useLazyWindow=function(e){const[o,n]=p.useState(()=>new Map),{showModal:t,updateModal:s,destroyModal:a,hideModal:r}=ht({disableAutoDestroy:!0});return(c,i,l,m)=>new Promise((k,g)=>{let x=!1;l?.disableAutoDestroy!==void 0&&(x=l.disableAutoDestroy,delete(l={...l}).disableAutoDestroy);const w={...e,...l,...m,onHide:()=>{const u=o.get(c);m?.onHide?.(),n(S=>(S.delete(c),S)),r(u.id)},onDone:u=>{const S=o.get(c);n(M=>(M.delete(c),M)),m?.onDone?.(u),S&&S.id&&!x&&a(S.id)},onShown:u=>{n(S=>{const M=S.get(c);return S.set(c,{...M,element:u}),S}),k(u)},open:!0},y=o.get(c);if(y)return s(y.id,w),k(y.element),void(w.autoFocus&&y.element?.focus());if(!i)return void g(`Invalid function for window '${c}'`);const h=p.lazy(i),v=t(h,w,{destroyOnClose:!x});n(u=>(u.set(c,{id:v.id,element:null}),u))})},exports.useModal=ht,exports.useOptionsDialog=e=>{const{showModal:o}=ht();return n=>new Promise(t=>{const s=o(Zi,{...e,...n,onOption(a){n?.onOption?.(a,a===n.cancelOption,a===n.defaultOption),t(a)},onDone:()=>{n?.onDone?.(),s.hide()}})})},exports.useResolvedThemeMode=function(e){const{mode:o}=e||{},[n,t]=p.useState(()=>{if(o==="light"||o==="dark")return{themeMode:o,source:"prop"};if(typeof document<"u"){const s=Mn();if(s)return{themeMode:s,source:"class"}}return{themeMode:Tn(),source:"media"}});return p.useEffect(()=>{const s=()=>{if(o)return void(o===n.themeMode&&n.source==="prop"||t(l=>({...l,themeMode:o,source:"prop"})));const i=Mn();if(i)t({themeMode:i,source:"class"});else{const l=Tn();t({themeMode:l,source:"media"})}},a=new MutationObserver(s),r=[document.documentElement,document.body].filter(Boolean);for(const i of r)a.observe(i,{attributes:!0,attributeFilter:["class"]});const c=window.matchMedia("(prefers-color-scheme: dark)");return c.addEventListener("change",s),s(),()=>{a.disconnect(),c.removeEventListener("change",s)}},[o]),n},exports.wrapErrorAsComponent=Eo;
|
|
11
|
+
`,i.getElementsByTagName("head")[0].appendChild(l)),i.body&&r(i.body,"react-draggable-transparent-selection")},de.createCSSTransform=function(i,l){const m=s(i,l,"px");return{[(0,o.browserPrefixToKey)("transform",o.default)]:m}},de.createSVGTransform=function(i,l){return s(i,l,"")},de.getTouch=function(i,l){return i.targetTouches&&(0,e.findInArray)(i.targetTouches,m=>l===m.identifier)||i.changedTouches&&(0,e.findInArray)(i.changedTouches,m=>l===m.identifier)},de.getTouchIdentifier=function(i){if(i.targetTouches&&i.targetTouches[0])return i.targetTouches[0].identifier;if(i.changedTouches&&i.changedTouches[0])return i.changedTouches[0].identifier},de.getTranslation=s,de.innerHeight=function(i){let l=i.clientHeight;const m=i.ownerDocument.defaultView.getComputedStyle(i);return l-=(0,e.int)(m.paddingTop),l-=(0,e.int)(m.paddingBottom),l},de.innerWidth=function(i){let l=i.clientWidth;const m=i.ownerDocument.defaultView.getComputedStyle(i);return l-=(0,e.int)(m.paddingLeft),l-=(0,e.int)(m.paddingRight),l},de.matchesSelector=t,de.matchesSelectorAndParentsTo=function(i,l,m){let k=i;do{if(t(k,l))return!0;if(k===m)return!1;k=k.parentNode}while(k);return!1},de.offsetXYFromParent=function(i,l,m){const k=l===l.ownerDocument.body?{left:0,top:0}:l.getBoundingClientRect(),g=(i.clientX+l.scrollLeft-k.left)/m,x=(i.clientY+l.scrollTop-k.top)/m;return{x:g,y:x}},de.outerHeight=function(i){let l=i.clientHeight;const m=i.ownerDocument.defaultView.getComputedStyle(i);return l+=(0,e.int)(m.borderTopWidth),l+=(0,e.int)(m.borderBottomWidth),l},de.outerWidth=function(i){let l=i.clientWidth;const m=i.ownerDocument.defaultView.getComputedStyle(i);return l+=(0,e.int)(m.borderLeftWidth),l+=(0,e.int)(m.borderRightWidth),l},de.removeClassName=c,de.removeEvent=function(i,l,m,k){if(!i)return;const g={capture:!0,...k};i.removeEventListener?i.removeEventListener(l,m,g):i.detachEvent?i.detachEvent("on"+l,m):i["on"+l]=null},de.scheduleRemoveUserSelectStyles=function(i){window.requestAnimationFrame?window.requestAnimationFrame(()=>{a(i)}):a(i)};var e=Pt(),o=(function(i,l){if(typeof WeakMap=="function")var m=new WeakMap,k=new WeakMap;return(function(g,x){if(!x&&g&&g.__esModule)return g;var w,y,h={__proto__:null,default:g};if(g===null||typeof g!="object"&&typeof g!="function")return h;if(w=x?k:m){if(w.has(g))return w.get(g);w.set(g,h)}for(const v in g)v!=="default"&&{}.hasOwnProperty.call(g,v)&&((y=(w=Object.defineProperty)&&Object.getOwnPropertyDescriptor(g,v))&&(y.get||y.set)?w(h,v,y):h[v]=g[v]);return h})(i,l)})((function(){if(Yn)return Ne;Yn=1,Object.defineProperty(Ne,"__esModule",{value:!0}),Ne.browserPrefixToKey=m,Ne.browserPrefixToStyle=function(k,g){return g?`-${g.toLowerCase()}-${k}`:k},Ne.default=void 0,Ne.getPrefix=l;const i=["Moz","Webkit","O","ms"];function l(){let k=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"transform";if(typeof window>"u")return"";const g=window.document?.documentElement?.style;if(!g||k in g)return"";for(let x=0;x<i.length;x++)if(m(k,i[x])in g)return i[x];return""}function m(k,g){return g?`${g}${(function(x){let w="",y=!0;for(let h=0;h<x.length;h++)y?(w+=x[h].toUpperCase(),y=!1):x[h]==="-"?y=!0:w+=x[h];return w})(k)}`:k}return Ne.default=l(),Ne})());let n="";function t(i,l){return n||(n=(0,e.findInArray)(["matches","webkitMatchesSelector","mozMatchesSelector","msMatchesSelector","oMatchesSelector"],function(m){return(0,e.isFunction)(i[m])})),!!(0,e.isFunction)(i[n])&&i[n](l)}function s(i,l,m){let{x:k,y:g}=i,x=`translate(${k}${m},${g}${m})`;return l&&(x=`translate(${`${typeof l.x=="string"?l.x:l.x+m}`}, ${`${typeof l.y=="string"?l.y:l.y+m}`})`+x),x}function a(i){if(i)try{if(i.body&&c(i.body,"react-draggable-transparent-selection"),i.selection)i.selection.empty();else{const l=(i.defaultView||window).getSelection();l&&l.type!=="Caret"&&l.removeAllRanges()}}catch{}}function r(i,l){i.classList?i.classList.add(l):i.className.match(new RegExp(`(?:^|\\s)${l}(?!\\S)`))||(i.className+=` ${l}`)}function c(i,l){i.classList?i.classList.remove(l):i.className=i.className.replace(new RegExp(`(?:^|\\s)${l}(?!\\S)`,"g"),"")}return de}var Gn,Me={};function nr(){if(Gn)return Me;Gn=1,Object.defineProperty(Me,"__esModule",{value:!0}),Me.canDragX=function(t){return t.props.axis==="both"||t.props.axis==="x"},Me.canDragY=function(t){return t.props.axis==="both"||t.props.axis==="y"},Me.createCoreData=function(t,s,a){const r=!(0,e.isNum)(t.lastX),c=n(t);return r?{node:c,deltaX:0,deltaY:0,lastX:s,lastY:a,x:s,y:a}:{node:c,deltaX:s-t.lastX,deltaY:a-t.lastY,lastX:t.lastX,lastY:t.lastY,x:s,y:a}},Me.createDraggableData=function(t,s){const a=t.props.scale;return{node:s.node,x:t.state.x+s.deltaX/a,y:t.state.y+s.deltaY/a,deltaX:s.deltaX/a,deltaY:s.deltaY/a,lastX:t.state.x,lastY:t.state.y}},Me.getBoundPosition=function(t,s,a){if(!t.props.bounds)return[s,a];let{bounds:r}=t.props;r=typeof r=="string"?r:(function(i){return{left:i.left,top:i.top,right:i.right,bottom:i.bottom}})(r);const c=n(t);if(typeof r=="string"){const{ownerDocument:i}=c,l=i.defaultView;let m;if(r==="parent"?m=c.parentNode:m=c.getRootNode().querySelector(r),!(m instanceof l.HTMLElement))throw new Error('Bounds selector "'+r+'" could not find an element.');const k=m,g=l.getComputedStyle(c),x=l.getComputedStyle(k);r={left:-c.offsetLeft+(0,e.int)(x.paddingLeft)+(0,e.int)(g.marginLeft),top:-c.offsetTop+(0,e.int)(x.paddingTop)+(0,e.int)(g.marginTop),right:(0,o.innerWidth)(k)-(0,o.outerWidth)(c)-c.offsetLeft+(0,e.int)(x.paddingRight)-(0,e.int)(g.marginRight),bottom:(0,o.innerHeight)(k)-(0,o.outerHeight)(c)-c.offsetTop+(0,e.int)(x.paddingBottom)-(0,e.int)(g.marginBottom)}}return(0,e.isNum)(r.right)&&(s=Math.min(s,r.right)),(0,e.isNum)(r.bottom)&&(a=Math.min(a,r.bottom)),(0,e.isNum)(r.left)&&(s=Math.max(s,r.left)),(0,e.isNum)(r.top)&&(a=Math.max(a,r.top)),[s,a]},Me.getControlPosition=function(t,s,a){const r=typeof s=="number"?(0,o.getTouch)(t,s):null;if(typeof s=="number"&&!r)return null;const c=n(a),i=a.props.offsetParent||c.offsetParent||c.ownerDocument.body;return(0,o.offsetXYFromParent)(r||t,i,a.props.scale)},Me.snapToGrid=function(t,s,a){const r=Math.round(s/t[0])*t[0],c=Math.round(a/t[1])*t[1];return[r,c]};var e=Pt(),o=pn();function n(t){const s=t.findDOMNode();if(!s)throw new Error("<DraggableCore>: Unmounted during event!");return s}return Me}var Xn,Qn,Jn,Zn,it={},bt={};function or(){return Xn||(Xn=1,Object.defineProperty(bt,"__esModule",{value:!0}),bt.default=function(){}),bt}function Si(){if(Qn)return it;Qn=1,Object.defineProperty(it,"__esModule",{value:!0}),it.default=void 0;var e=(function(x,w){if(typeof WeakMap=="function")var y=new WeakMap,h=new WeakMap;return(function(v,u){if(!u&&v&&v.__esModule)return v;var S,M,j={__proto__:null,default:v};if(v===null||typeof v!="object"&&typeof v!="function")return j;if(S=u?h:y){if(S.has(v))return S.get(v);S.set(v,j)}for(const $ in v)$!=="default"&&{}.hasOwnProperty.call(v,$)&&((M=(S=Object.defineProperty)&&Object.getOwnPropertyDescriptor(v,$))&&(M.get||M.set)?S(j,$,M):j[$]=v[$]);return j})(x,w)})(p),o=c(dn()),n=c(en),t=pn(),s=nr(),a=Pt(),r=c(or());function c(x){return x&&x.__esModule?x:{default:x}}function i(x,w,y){return(w=(function(h){var v=(function(u,S){if(typeof u!="object"||!u)return u;var M=u[Symbol.toPrimitive];if(M!==void 0){var j=M.call(u,S);if(typeof j!="object")return j;throw new TypeError("@@toPrimitive must return a primitive value.")}return(S==="string"?String:Number)(u)})(h,"string");return typeof v=="symbol"?v:v+""})(w))in x?Object.defineProperty(x,w,{value:y,enumerable:!0,configurable:!0,writable:!0}):x[w]=y,x}const l={start:"touchstart",move:"touchmove",stop:"touchend"},m={start:"mousedown",move:"mousemove",stop:"mouseup"};let k=m,g=class extends e.Component{constructor(){super(...arguments),i(this,"dragging",!1),i(this,"lastX",NaN),i(this,"lastY",NaN),i(this,"touchIdentifier",null),i(this,"mounted",!1),i(this,"handleDragStart",x=>{if(this.props.onMouseDown(x),!this.props.allowAnyClick&&typeof x.button=="number"&&x.button!==0)return!1;const w=this.findDOMNode();if(!w||!w.ownerDocument||!w.ownerDocument.body)throw new Error("<DraggableCore> not mounted on DragStart!");const{ownerDocument:y}=w;if(this.props.disabled||!(x.target instanceof y.defaultView.Node)||this.props.handle&&!(0,t.matchesSelectorAndParentsTo)(x.target,this.props.handle,w)||this.props.cancel&&(0,t.matchesSelectorAndParentsTo)(x.target,this.props.cancel,w))return;x.type!=="touchstart"||this.props.allowMobileScroll||x.preventDefault();const h=(0,t.getTouchIdentifier)(x);this.touchIdentifier=h;const v=(0,s.getControlPosition)(x,h,this);if(v==null)return;const{x:u,y:S}=v,M=(0,s.createCoreData)(this,u,S);(0,r.default)("DraggableCore: handleDragStart: %j",M),(0,r.default)("calling",this.props.onStart),this.props.onStart(x,M)!==!1&&this.mounted!==!1&&(this.props.enableUserSelectHack&&(0,t.addUserSelectStyles)(y),this.dragging=!0,this.lastX=u,this.lastY=S,(0,t.addEvent)(y,k.move,this.handleDrag),(0,t.addEvent)(y,k.stop,this.handleDragStop))}),i(this,"handleDrag",x=>{const w=(0,s.getControlPosition)(x,this.touchIdentifier,this);if(w==null)return;let{x:y,y:h}=w;if(Array.isArray(this.props.grid)){let u=y-this.lastX,S=h-this.lastY;if([u,S]=(0,s.snapToGrid)(this.props.grid,u,S),!u&&!S)return;y=this.lastX+u,h=this.lastY+S}const v=(0,s.createCoreData)(this,y,h);if((0,r.default)("DraggableCore: handleDrag: %j",v),this.props.onDrag(x,v)!==!1&&this.mounted!==!1)this.lastX=y,this.lastY=h;else try{this.handleDragStop(new MouseEvent("mouseup"))}catch{const S=document.createEvent("MouseEvents");S.initMouseEvent("mouseup",!0,!0,window,0,0,0,0,0,!1,!1,!1,!1,0,null),this.handleDragStop(S)}}),i(this,"handleDragStop",x=>{if(!this.dragging)return;const w=(0,s.getControlPosition)(x,this.touchIdentifier,this);if(w==null)return;let{x:y,y:h}=w;if(Array.isArray(this.props.grid)){let S=y-this.lastX||0,M=h-this.lastY||0;[S,M]=(0,s.snapToGrid)(this.props.grid,S,M),y=this.lastX+S,h=this.lastY+M}const v=(0,s.createCoreData)(this,y,h);if(this.props.onStop(x,v)===!1||this.mounted===!1)return!1;const u=this.findDOMNode();u&&this.props.enableUserSelectHack&&(0,t.scheduleRemoveUserSelectStyles)(u.ownerDocument),(0,r.default)("DraggableCore: handleDragStop: %j",v),this.dragging=!1,this.lastX=NaN,this.lastY=NaN,u&&((0,r.default)("DraggableCore: Removing handlers"),(0,t.removeEvent)(u.ownerDocument,k.move,this.handleDrag),(0,t.removeEvent)(u.ownerDocument,k.stop,this.handleDragStop))}),i(this,"onMouseDown",x=>(k=m,this.handleDragStart(x))),i(this,"onMouseUp",x=>(k=m,this.handleDragStop(x))),i(this,"onTouchStart",x=>(k=l,this.handleDragStart(x))),i(this,"onTouchEnd",x=>(k=l,this.handleDragStop(x)))}componentDidMount(){this.mounted=!0;const x=this.findDOMNode();x&&(0,t.addEvent)(x,l.start,this.onTouchStart,{passive:!1})}componentWillUnmount(){this.mounted=!1;const x=this.findDOMNode();if(x){const{ownerDocument:w}=x;(0,t.removeEvent)(w,m.move,this.handleDrag),(0,t.removeEvent)(w,l.move,this.handleDrag),(0,t.removeEvent)(w,m.stop,this.handleDragStop),(0,t.removeEvent)(w,l.stop,this.handleDragStop),(0,t.removeEvent)(x,l.start,this.onTouchStart,{passive:!1}),this.props.enableUserSelectHack&&(0,t.scheduleRemoveUserSelectStyles)(w)}}findDOMNode(){return this.props?.nodeRef?this.props?.nodeRef?.current:n.default.findDOMNode(this)}render(){return e.cloneElement(e.Children.only(this.props.children),{onMouseDown:this.onMouseDown,onMouseUp:this.onMouseUp,onTouchEnd:this.onTouchEnd})}};return it.default=g,i(g,"displayName","DraggableCore"),i(g,"propTypes",{allowAnyClick:o.default.bool,allowMobileScroll:o.default.bool,children:o.default.node.isRequired,disabled:o.default.bool,enableUserSelectHack:o.default.bool,offsetParent:function(x,w){if(x[w]&&x[w].nodeType!==1)throw new Error("Draggable's offsetParent must be a DOM Node.")},grid:o.default.arrayOf(o.default.number),handle:o.default.string,cancel:o.default.string,nodeRef:o.default.object,onStart:o.default.func,onDrag:o.default.func,onStop:o.default.func,onMouseDown:o.default.func,scale:o.default.number,className:a.dontSetMe,style:a.dontSetMe,transform:a.dontSetMe}),i(g,"defaultProps",{allowAnyClick:!1,allowMobileScroll:!1,disabled:!1,enableUserSelectHack:!0,onStart:function(){},onDrag:function(){},onStop:function(){},onMouseDown:function(){},scale:1}),it}function Ci(){return Jn||(Jn=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"DraggableCore",{enumerable:!0,get:function(){return i.default}}),e.default=void 0;var o=(function(w,y){if(typeof WeakMap=="function")var h=new WeakMap,v=new WeakMap;return(function(u,S){if(!S&&u&&u.__esModule)return u;var M,j,$={__proto__:null,default:u};if(u===null||typeof u!="object"&&typeof u!="function")return $;if(M=S?v:h){if(M.has(u))return M.get(u);M.set(u,$)}for(const O in u)O!=="default"&&{}.hasOwnProperty.call(u,O)&&((j=(M=Object.defineProperty)&&Object.getOwnPropertyDescriptor(u,O))&&(j.get||j.set)?M($,O,j):$[O]=u[O]);return $})(w,y)})(p),n=m(dn()),t=m(en),s=(function(){if(Un)return gt.exports;function w(h){var v,u,S="";if(typeof h=="string"||typeof h=="number")S+=h;else if(typeof h=="object")if(Array.isArray(h)){var M=h.length;for(v=0;v<M;v++)h[v]&&(u=w(h[v]))&&(S&&(S+=" "),S+=u)}else for(u in h)h[u]&&(S&&(S+=" "),S+=u);return S}function y(){for(var h,v,u=0,S="",M=arguments.length;u<M;u++)(h=arguments[u])&&(v=w(h))&&(S&&(S+=" "),S+=v);return S}return Un=1,gt.exports=y,gt.exports.clsx=y,gt.exports})(),a=pn(),r=nr(),c=Pt(),i=m(Si()),l=m(or());function m(w){return w&&w.__esModule?w:{default:w}}function k(){return k=Object.assign?Object.assign.bind():function(w){for(var y=1;y<arguments.length;y++){var h=arguments[y];for(var v in h)({}).hasOwnProperty.call(h,v)&&(w[v]=h[v])}return w},k.apply(null,arguments)}function g(w,y,h){return(y=(function(v){var u=(function(S,M){if(typeof S!="object"||!S)return S;var j=S[Symbol.toPrimitive];if(j!==void 0){var $=j.call(S,M);if(typeof $!="object")return $;throw new TypeError("@@toPrimitive must return a primitive value.")}return(M==="string"?String:Number)(S)})(v,"string");return typeof u=="symbol"?u:u+""})(y))in w?Object.defineProperty(w,y,{value:h,enumerable:!0,configurable:!0,writable:!0}):w[y]=h,w}class x extends o.Component{static getDerivedStateFromProps(y,h){let{position:v}=y,{prevPropsPosition:u}=h;return!v||u&&v.x===u.x&&v.y===u.y?null:((0,l.default)("Draggable: getDerivedStateFromProps %j",{position:v,prevPropsPosition:u}),{x:v.x,y:v.y,prevPropsPosition:{...v}})}constructor(y){super(y),g(this,"onDragStart",(h,v)=>{if((0,l.default)("Draggable: onDragStart: %j",v),this.props.onStart(h,(0,r.createDraggableData)(this,v))===!1)return!1;this.setState({dragging:!0,dragged:!0})}),g(this,"onDrag",(h,v)=>{if(!this.state.dragging)return!1;(0,l.default)("Draggable: onDrag: %j",v);const u=(0,r.createDraggableData)(this,v),S={x:u.x,y:u.y,slackX:0,slackY:0};if(this.props.bounds){const{x:M,y:j}=S;S.x+=this.state.slackX,S.y+=this.state.slackY;const[$,O]=(0,r.getBoundPosition)(this,S.x,S.y);S.x=$,S.y=O,S.slackX=this.state.slackX+(M-S.x),S.slackY=this.state.slackY+(j-S.y),u.x=S.x,u.y=S.y,u.deltaX=S.x-this.state.x,u.deltaY=S.y-this.state.y}if(this.props.onDrag(h,u)===!1)return!1;this.setState(S)}),g(this,"onDragStop",(h,v)=>{if(!this.state.dragging||this.props.onStop(h,(0,r.createDraggableData)(this,v))===!1)return!1;(0,l.default)("Draggable: onDragStop: %j",v);const u={dragging:!1,slackX:0,slackY:0};if(this.props.position){const{x:S,y:M}=this.props.position;u.x=S,u.y=M}this.setState(u)}),this.state={dragging:!1,dragged:!1,x:y.position?y.position.x:y.defaultPosition.x,y:y.position?y.position.y:y.defaultPosition.y,prevPropsPosition:{...y.position},slackX:0,slackY:0,isElementSVG:!1},!y.position||y.onDrag||y.onStop||console.warn("A `position` was applied to this <Draggable>, without drag handlers. This will make this component effectively undraggable. Please attach `onDrag` or `onStop` handlers so you can adjust the `position` of this element.")}componentDidMount(){window.SVGElement!==void 0&&this.findDOMNode()instanceof window.SVGElement&&this.setState({isElementSVG:!0})}componentWillUnmount(){this.state.dragging&&this.setState({dragging:!1})}findDOMNode(){return this.props?.nodeRef?.current??t.default.findDOMNode(this)}render(){const{axis:y,bounds:h,children:v,defaultPosition:u,defaultClassName:S,defaultClassNameDragging:M,defaultClassNameDragged:j,position:$,positionOffset:O,scale:P,...C}=this.props;let D={},I=null;const T=!$||this.state.dragging,B=$||u,_={x:(0,r.canDragX)(this)&&T?this.state.x:B.x,y:(0,r.canDragY)(this)&&T?this.state.y:B.y};this.state.isElementSVG?I=(0,a.createSVGTransform)(_,O):D=(0,a.createCSSTransform)(_,O);const V=(0,s.clsx)(v.props.className||"",S,{[M]:this.state.dragging,[j]:this.state.dragged});return o.createElement(i.default,k({},C,{onStart:this.onDragStart,onDrag:this.onDrag,onStop:this.onDragStop}),o.cloneElement(o.Children.only(v),{className:V,style:{...v.props.style,...D},transform:I}))}}e.default=x,g(x,"displayName","Draggable"),g(x,"propTypes",{...i.default.propTypes,axis:n.default.oneOf(["both","x","y","none"]),bounds:n.default.oneOfType([n.default.shape({left:n.default.number,right:n.default.number,top:n.default.number,bottom:n.default.number}),n.default.string,n.default.oneOf([!1])]),defaultClassName:n.default.string,defaultClassNameDragging:n.default.string,defaultClassNameDragged:n.default.string,defaultPosition:n.default.shape({x:n.default.number,y:n.default.number}),positionOffset:n.default.shape({x:n.default.oneOfType([n.default.number,n.default.string]),y:n.default.oneOfType([n.default.number,n.default.string])}),position:n.default.shape({x:n.default.number,y:n.default.number}),className:c.dontSetMe,style:c.dontSetMe,transform:c.dontSetMe}),g(x,"defaultProps",{...i.default.defaultProps,axis:"both",bounds:!1,defaultClassName:"react-draggable",defaultClassNameDragging:"react-draggable-dragging",defaultClassNameDragged:"react-draggable-dragged",defaultPosition:{x:0,y:0},scale:1})})(Hn)),Hn}var Di=(function(){if(Zn)return rt.exports;Zn=1;const{default:e,DraggableCore:o}=Ci();return rt.exports=e,rt.exports.default=e,rt.exports.DraggableCore=o,rt.exports})();const Oi=ko(Di),eo={x:0,y:0},Ei=p.memo(p.forwardRef((e,o)=>{const{defaultPosition:n=eo,PaperComponent:t=L.Paper,onDragStop:s,rootSel:a=".MuiModal-root",handleSel:r=".draggable-title",titleSize:c,rootSize:i,...l}=e,m=p.useRef(null),k=p.useMemo(()=>c&&i?{left:0,top:0,right:i.width-c.width,bottom:i.height-c.height}:null,[c,i]),[g,x]=p.useState(null),[w,y]=p.useState(null),[h,v]=p.useState(null);return p.useLayoutEffect(()=>{!g&&n&&x(n??eo)},[n]),p.useEffect(()=>{k&&g&&y({x:Math.max(0,Math.min(g.x,k.right)),y:Math.max(0,Math.min(g.y,k.bottom))})},[g,k]),f.jsx(Oi,{nodeRef:m,handle:r,cancel:'[class*="MuiDialogContent-root"]',position:w,bounds:k??".MuiModal-root",onStop:s,onStart:(u,S)=>{const M=u;v({x:(M.clientX??M.touches?.[0]?.clientX)-S.x,y:(M.clientY??M.touches?.[0]?.clientY)-S.y})},onDrag:(u,S)=>{const M=u,j=M.clientX??M.touches?.[0]?.clientX,$=M.clientY??M.touches?.[0]?.clientY;x({x:j-h.x,y:$-h.y})},children:f.jsx(t,{ref:kt([m,o]),...l})})})),Mi={x:"50",y:"50"},rr=p.memo(p.forwardRef((e,o)=>{const n=We.useThemeProps({props:e,name:"MuiDialog"}),t=We.useTheme(),s={enter:.66*t.transitions.duration.enteringScreen,exit:.66*t.transitions.duration.leavingScreen},{title:a="SheetXL",key:r="draggable-window",onCancel:c,onDone:i,onShow:l,onShown:m,onHide:k,onClose:g,open:x,autoFocusSel:w,children:y,transitionDuration:h=s,TransitionProps:v,slots:u=ve.CommonUtils.EmptyArray,slotProps:S=ve.CommonUtils.EmptyArray,sx:M,className:j,onMouseDown:$,initialPosition:O=Mi,isModal:P=!1,...C}=n;let D=u.transition??L.Fade;const I=u.backdrop??L.Backdrop,T=u.paper??L.Paper;let B=S.transition;v&&(B={...v,...B});const _=S.backdrop,V=S.paper,z=p.useRef(null),[H,Z]=p.useState(null),[X,J]=p.useState(!1),[ne,oe]=p.useState(!1),ee=p.useRef(null),[re,ie]=wn(),d=p.useRef(null),[b,E]=wn(),F=p.useRef(null);p.useEffect(()=>{H&&J(x)},[x,H]);const A=N.useCallbackRef(()=>{c?.(),J(!1)},[c]);p.useEffect(()=>{if(ie.width===0&&ie.height===0||H)return;const U=F.current?.getBoundingClientRect(),he=ie.height-U.height,et=ie.width-U.width;let Re=.5*et,Nt=.5*he;typeof O?.x=="number"?Re=O.x:typeof O?.x=="string"&&(Re=et*(parseFloat(O.x)/100)),typeof O?.y=="number"?Nt=O.y:typeof O?.y=="string"&&(Nt=he*(parseFloat(O.y)/100)),Z({x:Re,y:Nt})},[ie,E]);const[R,W]=p.useState(!1),[Y,q]=p.useState(null),[Q,te]=p.useState(null),ae=N.useCallbackRef(U=>{if(Y)return Y.focus(U),!0;if(w){const he=d.current?.querySelectorAll?.(w);if(he&&he.length>0)return he[0]?.focus?.(U),!0}return d.current?.focus?.(U),!1},[Y,w]),ue=N.useImperativeElement(o,()=>({focus:U=>{ae(U)}}),[]),Oe={...B,onExited:U=>{i?.(null),B?.onExited?.(U)},onExit:U=>{const he=Q;he&&requestAnimationFrame(()=>{ue.current?.contains(document.activeElement)&&he.focus()}),k?.(),oe(!1),B?.onExit?.(U)},onEntered:(U,he)=>{l?.(),B?.onEntered?.(U,he)},onEntering:(U,he)=>{oe(!0),m?.(ue.current)}};p.useEffect(()=>{ne&&ae()},[ne]);let be=f.jsx(ki,{focusTrapOptions:{escapeDeactivates:!1,allowOutsideClick:!0,initialFocus:!1},ref:z,active:ne,children:f.jsx(D,{in:X,timeout:h,role:"presentation",...Oe,children:f.jsx(L.Box,{className:"MuiDialog-container",ref:d,tabIndex:0,sx:{outline:"none",position:"relative"},onKeyDown:U=>{U.which===N.KeyCodes.Escape&&(A(),ee.current?.start(U,{center:!1}),setTimeout(()=>ee.current?.stop(U),180)),U.stopPropagation()},children:f.jsxs(Ei,{ref:kt([F,o]),className:ye({"Mui-focusVisible":R},j,"draggable"),sx:{"& *":U=>sn(U),pointerEvents:"auto",userSelect:"none","&:hover:not([disabled]):not(.Mui-focusVisible)":{outline:U=>`solid ${se.alpha(U.palette.text?.primary,.2)} 1px`},"&.Mui-focusVisible":{outline:U=>`solid ${se.alpha(U.palette.text?.primary,.2)} 1px`},position:"absolute",maxWidth:"100%",...M},defaultPosition:H,titleSize:E,rootSize:ie,PaperComponent:T,...C,...V,children:[a?f.jsx(L.DialogTitle,{className:ye({"Mui-selected":R},"draggable-title"),sx:{cursor:"move",display:"flex",color:U=>U.palette.text.secondary,boxSizing:"border-box",padding:"0 0",transitionProperty:"opacity",transitionDuration:U=>`${U.transitions.duration.shortest}ms`,opacity:.7,"&.Mui-selected":{opacity:1,transitionDuration:U=>U.transitions.duration.shortest/2+"ms"},backgroundColor:U=>se.alpha(U.palette.action.hover,.03)},ref:b,children:f.jsxs(L.Box,{sx:{display:"flex",flex:"1 1 10%",flexDirection:"row",alignItems:"center",marginTop:U=>U.spacing(1),marginLeft:U=>U.spacing(1),marginRight:U=>U.spacing(1)},children:[f.jsx(L.Box,{sx:{flex:"1 1 100%",paddingLeft:U=>U.spacing(1)},children:a}),f.jsx(Ke,{label:"Close",children:f.jsx(L.IconButton,{"aria-label":"close",sx:{color:U=>U.palette.text.icon??U.palette.action.active},touchRippleRef:ee,onPointerDown:U=>{ee.current?.start(U,{center:!1}),U.stopPropagation(),U.preventDefault()},onPointerUp:A,children:f.jsx(N.DynamicIcon,{iconKey:"Close"})})})]})}):null,y]})})})}),G=null;P&&(G=f.jsx(I,{..._,open:X,onMouseDown:U=>{A(),_?.onMouseDown?.(U)},onClick:U=>{g?.(U,"backdropClick"),_?.onClick?.(U)},sx:{pointerEvents:"auto",..._?.sx}}));const{getPortalContainer:le}=N.useFullscreenPortal();return en.createPortal(f.jsxs(L.Box,{className:"MuiModal-root",sx:{position:"fixed",zIndex:"1300",right:"0",bottom:"0",top:"0",left:"0",outline:"0",display:"block",pointerEvents:"none"},ref:kt([ue,re]),onPointerDown:U=>{R&&(U.target===d.current||U.target.tabIndex<0)&&d.current?.contains(document.activeElement)},onContextMenu:U=>{U.isPropagationStopped()||U.preventDefault()},onFocus:U=>{!R&&(U.target===d.current||U.target.tabIndex<0)&&setTimeout(()=>{ae()},100),z.current?.focusTrap?.unpause(),W(!0),d.current?.contains(U.target)&&U.target!==d.current&&q(U.target),U.relatedTarget&&!Q&&te(U.relatedTarget)},onBlur:U=>{ue?.current?.contains(U.relatedTarget)||(te(null),z.current?.focusTrap?.pause(),W(!1))},children:[G,be]}),le(),r+"")}));var De=typeof window<"u"?window:{screen:{},navigator:{}},Ze=(De.matchMedia||function(){return{matches:!1}}).bind(De),Ti={get passive(){return!0}},to=function(){};De.addEventListener&&De.addEventListener("p",to,Ti),De.removeEventListener&&De.removeEventListener("p",to,!1);var fn="ontouchstart"in De,ji=fn||"TouchEvent"in De&&Ze("(any-pointer: coarse)").matches,no=(De.navigator.maxTouchPoints||0)>0||ji,ir=De.navigator.userAgent||"",Pi=Ze("(pointer: coarse)").matches&&/iPad|Macintosh/.test(ir)&&Math.min(De.screen.width||0,De.screen.height||0)>=768,ar=(Ze("(pointer: coarse)").matches||!Ze("(pointer: fine)").matches&&fn)&&!/Windows.*Firefox/.test(ir),Ri=Ze("(any-pointer: fine)").matches||Ze("(any-hover: hover)").matches||Pi||!fn,oo=!no||!Ri&&ar?no?"touchOnly":"mouseOnly":"hybrid",Fi=oo==="mouseOnly"?"mouse":oo==="touchOnly"||ar?"touch":"mouse",ut=e=>e.type==="checkbox",$e=e=>e instanceof Date,we=e=>e==null;const sr=e=>typeof e=="object";var me=e=>!we(e)&&!Array.isArray(e)&&sr(e)&&!$e(e),mn=typeof window<"u"&&window.HTMLElement!==void 0&&typeof document<"u";function ge(e){let o;const n=Array.isArray(e),t=typeof FileList<"u"&&e instanceof FileList;if(e instanceof Date)o=new Date(e);else{if(mn&&(e instanceof Blob||t)||!n&&!me(e))return e;if(o=n?[]:Object.create(Object.getPrototypeOf(e)),n||(s=>{const a=s.constructor&&s.constructor.prototype;return me(a)&&a.hasOwnProperty("isPrototypeOf")})(e))for(const s in e)e.hasOwnProperty(s)&&(o[s]=ge(e[s]));else o=e}return o}var Rt=e=>/^\w*$/.test(e),fe=e=>e===void 0,Xt=e=>Array.isArray(e)?e.filter(Boolean):[],hn=e=>Xt(e.replace(/["|']|\]/g,"").split(/\.|\[/)),K=(e,o,n)=>{if(!o||!me(e))return n;const t=(Rt(o)?[o]:hn(o)).reduce((s,a)=>we(s)?s:s[a],e);return fe(t)||t===e?fe(e[o])?n:e[o]:t},Te=e=>typeof e=="boolean",ce=(e,o,n)=>{let t=-1;const s=Rt(o)?[o]:hn(o),a=s.length,r=a-1;for(;++t<a;){const c=s[t];let i=n;if(t!==r){const l=e[c];i=me(l)||Array.isArray(l)?l:isNaN(+s[t+1])?{}:[]}if(c==="__proto__"||c==="constructor"||c==="prototype")return;e[c]=i,e=e[c]}};const Ni="blur",Bi="focusout",Ii="onBlur",lr="onChange",cr="onSubmit",_i="onTouched",pt="all",Ai="max",Li="min",Vi="maxLength",$i="minLength",ro="pattern",io="required",zi="validate",ur=p.createContext(null);ur.displayName="HookFormContext";const Wi=e=>{const{children:o,...n}=e;return p.createElement(ur.Provider,{value:n},o)},Ui=typeof window<"u"?p.useLayoutEffect:p.useEffect;var Se=e=>typeof e=="string",Qt=e=>we(e)||!sr(e);function Ae(e,o,n=new WeakSet){if(Qt(e)||Qt(o))return e===o;if($e(e)&&$e(o))return e.getTime()===o.getTime();const t=Object.keys(e),s=Object.keys(o);if(t.length!==s.length)return!1;if(n.has(e)||n.has(o))return!0;n.add(e),n.add(o);for(const a of t){const r=e[a];if(!s.includes(a))return!1;if(a!=="ref"){const c=o[a];if($e(r)&&$e(c)||me(r)&&me(c)||Array.isArray(r)&&Array.isArray(c)?!Ae(r,c,n):r!==c)return!1}}return!0}var Hi=(e,o,n,t,s)=>o?{...n[e],types:{...n[e]&&n[e].types?n[e].types:{},[t]:s||!0}}:{},st=e=>Array.isArray(e)?e:[e],ao=()=>{let e=[];return{get observers(){return e},next:o=>{for(const n of e)n.next&&n.next(o)},subscribe:o=>(e.push(o),{unsubscribe:()=>{e=e.filter(n=>n!==o)}}),unsubscribe:()=>{e=[]}}};function dr(e,o){const n={};for(const t in e)if(e.hasOwnProperty(t)){const s=e[t],a=o[t];if(s&&me(s)&&a){const r=dr(s,a);me(r)&&(n[t]=r)}else e[t]&&(n[t]=a)}return n}var ke=e=>me(e)&&!Object.keys(e).length,yn=e=>e.type==="file",Ee=e=>typeof e=="function",Ot=e=>{if(!mn)return!1;const o=e?e.ownerDocument:0;return e instanceof(o&&o.defaultView?o.defaultView.HTMLElement:HTMLElement)},pr=e=>e.type==="select-multiple",gn=e=>e.type==="radio",$t=e=>Ot(e)&&e.isConnected;function pe(e,o){const n=Array.isArray(o)?o:Rt(o)?[o]:hn(o),t=n.length===1?e:(function(r,c){const i=c.slice(0,-1).length;let l=0;for(;l<i;)r=fe(r)?l++:r[c[l++]];return r})(e,n),s=n.length-1,a=n[s];return t&&delete t[a],s!==0&&(me(t)&&ke(t)||Array.isArray(t)&&(function(r){for(const c in r)if(r.hasOwnProperty(c)&&!fe(r[c]))return!1;return!0})(t))&&pe(e,n.slice(0,-1)),e}function fr(e){return Array.isArray(e)||me(e)&&!(o=>{for(const n in o)if(Ee(o[n]))return!0;return!1})(e)}function Jt(e,o={}){for(const n in e)fr(e[n])?(o[n]=Array.isArray(e[n])?[]:{},Jt(e[n],o[n])):we(e[n])||(o[n]=!0);return o}function qe(e,o,n){n||(n=Jt(o));for(const t in e)fr(e[t])?fe(o)||Qt(n[t])?n[t]=Jt(e[t],Array.isArray(e[t])?[]:{}):qe(e[t],we(o)?{}:o[t],n[t]):n[t]=!Ae(e[t],o[t]);return n}const so={value:!1,isValid:!1},lo={value:!0,isValid:!0};var mr=e=>{if(Array.isArray(e)){if(e.length>1){const o=e.filter(n=>n&&n.checked&&!n.disabled).map(n=>n.value);return{value:o,isValid:!!o.length}}return e[0].checked&&!e[0].disabled?e[0].attributes&&!fe(e[0].attributes.value)?fe(e[0].value)||e[0].value===""?lo:{value:e[0].value,isValid:!0}:lo:so}return so},hr=(e,{valueAsNumber:o,valueAsDate:n,setValueAs:t})=>fe(e)?e:o?e===""?NaN:e&&+e:n&&Se(e)?new Date(e):t?t(e):e;const co={isValid:!1,value:null};var yr=e=>Array.isArray(e)?e.reduce((o,n)=>n&&n.checked&&!n.disabled?{isValid:!0,value:n.value}:o,co):co;function uo(e){const o=e.ref;return yn(o)?o.files:gn(o)?yr(e.refs).value:pr(o)?[...o.selectedOptions].map(({value:n})=>n):ut(o)?mr(e.refs).value:hr(fe(o.value)?e.ref.value:o.value,e)}var Et=e=>e instanceof RegExp,at=e=>fe(e)?e:Et(e)?e.source:me(e)?Et(e.value)?e.value.source:e.value:e,po=e=>({isOnSubmit:!e||e===cr,isOnBlur:e===Ii,isOnChange:e===lr,isOnAll:e===pt,isOnTouch:e===_i});const fo="AsyncFunction";var Ki=e=>!!e&&!!e.validate&&!!(Ee(e.validate)&&e.validate.constructor.name===fo||me(e.validate)&&Object.values(e.validate).find(o=>o.constructor.name===fo)),mo=(e,o,n)=>!n&&(o.watchAll||o.watch.has(e)||[...o.watch].some(t=>e.startsWith(t)&&/^\.\w+/.test(e.slice(t.length))));const dt=(e,o,n,t)=>{for(const s of n||Object.keys(e)){const a=K(e,s);if(a){const{_f:r,...c}=a;if(r){if(r.refs&&r.refs[0]&&o(r.refs[0],s)&&!t||r.ref&&o(r.ref,r.name)&&!t)return!0;if(dt(c,o))break}else if(me(c)&&dt(c,o))break}}};function ho(e,o,n){const t=K(e,n);if(t||Rt(n))return{error:t,name:n};const s=n.split(".");for(;s.length;){const a=s.join("."),r=K(o,a),c=K(e,a);if(r&&!Array.isArray(r)&&n!==a)return{name:n};if(c&&c.type)return{name:a,error:c};if(c&&c.root&&c.root.type)return{name:`${a}.root`,error:c.root};s.pop()}return{name:n}}var Yi=(e,o,n)=>{const t=st(K(e,n));return ce(t,"root",o[n]),ce(e,n,t),e};function yo(e,o,n="validate"){if(Se(e)||Array.isArray(e)&&e.every(Se)||Te(e)&&!e)return{type:n,message:Se(e)?e:"",ref:o}}var Ye=e=>me(e)&&!Et(e)?e:{value:e,message:""},go=async(e,o,n,t,s,a)=>{const{ref:r,refs:c,required:i,maxLength:l,minLength:m,min:k,max:g,pattern:x,validate:w,name:y,valueAsNumber:h,mount:v}=e._f,u=K(n,y);if(!v||o.has(y))return{};const S=c?c[0]:r,M=T=>{s&&S.reportValidity&&(S.setCustomValidity(Te(T)?"":T||""),S.reportValidity())},j={},$=gn(r),O=ut(r),P=$||O,C=(h||yn(r))&&fe(r.value)&&fe(u)||Ot(r)&&r.value===""||u===""||Array.isArray(u)&&!u.length,D=Hi.bind(null,y,t,j),I=(T,B,_,V=Vi,z=$i)=>{const H=T?B:_;j[y]={type:T?V:z,message:H,ref:r,...D(T?V:z,H)}};if(a?!Array.isArray(u)||!u.length:i&&(!P&&(C||we(u))||Te(u)&&!u||O&&!mr(c).isValid||$&&!yr(c).isValid)){const{value:T,message:B}=Se(i)?{value:!!i,message:i}:Ye(i);if(T&&(j[y]={type:io,message:B,ref:S,...D(io,B)},!t))return M(B),j}if(!(C||we(k)&&we(g))){let T,B;const _=Ye(g),V=Ye(k);if(we(u)||isNaN(u)){const z=r.valueAsDate||new Date(u),H=J=>new Date(new Date().toDateString()+" "+J),Z=r.type=="time",X=r.type=="week";Se(_.value)&&u&&(T=Z?H(u)>H(_.value):X?u>_.value:z>new Date(_.value)),Se(V.value)&&u&&(B=Z?H(u)<H(V.value):X?u<V.value:z<new Date(V.value))}else{const z=r.valueAsNumber||u&&+u;we(_.value)||(T=z>_.value),we(V.value)||(B=z<V.value)}if((T||B)&&(I(!!T,_.message,V.message,Ai,Li),!t))return M(j[y].message),j}if((l||m)&&!C&&(Se(u)||a&&Array.isArray(u))){const T=Ye(l),B=Ye(m),_=!we(T.value)&&u.length>+T.value,V=!we(B.value)&&u.length<+B.value;if((_||V)&&(I(_,T.message,B.message),!t))return M(j[y].message),j}if(x&&!C&&Se(u)){const{value:T,message:B}=Ye(x);if(Et(T)&&!u.match(T)&&(j[y]={type:ro,message:B,ref:r,...D(ro,B)},!t))return M(B),j}if(w){if(Ee(w)){const T=yo(await w(u,n),S);if(T&&(j[y]={...T,...D(zi,T.message)},!t))return M(T.message),j}else if(me(w)){let T={};for(const B in w){if(!ke(T)&&!t)break;const _=yo(await w[B](u,n),S,B);_&&(T={..._,...D(B,_.message)},M(_.message),t&&(j[y]=T))}if(!ke(T)&&(j[y]={ref:S,...T},!t))return j}}return M(!0),j};const qi={mode:cr,reValidateMode:lr,shouldFocusError:!0};function Gi(e={}){let o,n={...qi,...e},t={submitCount:0,isDirty:!1,isReady:!1,isLoading:Ee(n.defaultValues),isValidating:!1,isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,touchedFields:{},dirtyFields:{},validatingFields:{},errors:n.errors||{},disabled:n.disabled||!1},s={},a=(me(n.defaultValues)||me(n.values))&&ge(n.defaultValues||n.values)||{},r=n.shouldUnregister?{}:ge(a),c={action:!1,mount:!1,watch:!1},i={mount:new Set,disabled:new Set,unMount:new Set,array:new Set,watch:new Set},l=0;const m={isDirty:!1,dirtyFields:!1,validatingFields:!1,touchedFields:!1,isValidating:!1,isValid:!1,errors:!1};let k={...m};const g={array:ao(),state:ao()},x=n.criteriaMode===pt,w=async d=>{if(!n.disabled&&(m.isValid||k.isValid||d)){const b=n.resolver?ke((await S()).errors):await M(s,!0);b!==t.isValid&&g.state.next({isValid:b})}},y=(d,b)=>{!n.disabled&&(m.isValidating||m.validatingFields||k.isValidating||k.validatingFields)&&((d||Array.from(i.mount)).forEach(E=>{E&&(b?ce(t.validatingFields,E,b):pe(t.validatingFields,E))}),g.state.next({validatingFields:t.validatingFields,isValidating:!ke(t.validatingFields)}))},h=(d,b,E,F)=>{const A=K(s,d);if(A){const R=K(r,d,fe(E)?K(a,d):E);fe(R)||F&&F.defaultChecked||b?ce(r,d,b?R:uo(A._f)):O(d,R),c.mount&&w()}},v=(d,b,E,F,A)=>{let R=!1,W=!1;const Y={name:d};if(!n.disabled){if(!E||F){(m.isDirty||k.isDirty)&&(W=t.isDirty,t.isDirty=Y.isDirty=j(),R=W!==Y.isDirty);const q=Ae(K(a,d),b);W=!!K(t.dirtyFields,d),q?pe(t.dirtyFields,d):ce(t.dirtyFields,d,!0),Y.dirtyFields=t.dirtyFields,R=R||(m.dirtyFields||k.dirtyFields)&&W!==!q}if(E){const q=K(t.touchedFields,d);q||(ce(t.touchedFields,d,E),Y.touchedFields=t.touchedFields,R=R||(m.touchedFields||k.touchedFields)&&q!==E)}R&&A&&g.state.next(Y)}return R?Y:{}},u=(d,b,E,F)=>{const A=K(t.errors,d),R=(m.isValid||k.isValid)&&Te(b)&&t.isValid!==b;var W;if(n.delayError&&E?(W=()=>((Y,q)=>{ce(t.errors,Y,q),g.state.next({errors:t.errors})})(d,E),o=Y=>{clearTimeout(l),l=setTimeout(W,Y)},o(n.delayError)):(clearTimeout(l),o=null,E?ce(t.errors,d,E):pe(t.errors,d)),(E?!Ae(A,E):A)||!ke(F)||R){const Y={...F,...R&&Te(b)?{isValid:b}:{},errors:t.errors,name:d};t={...t,...Y},g.state.next(Y)}},S=async d=>{y(d,!0);const b=await n.resolver(r,n.context,((E,F,A,R)=>{const W={};for(const Y of E){const q=K(F,Y);q&&ce(W,Y,q._f)}return{criteriaMode:A,names:[...E],fields:W,shouldUseNativeValidation:R}})(d||i.mount,s,n.criteriaMode,n.shouldUseNativeValidation));return y(d),b},M=async(d,b,E={valid:!0})=>{for(const F in d){const A=d[F];if(A){const{_f:R,...W}=A;if(R){const Y=i.array.has(R.name),q=A._f&&Ki(A._f);q&&m.validatingFields&&y([R.name],!0);const Q=await go(A,i.disabled,r,x,n.shouldUseNativeValidation&&!b,Y);if(q&&m.validatingFields&&y([R.name]),Q[R.name]&&(E.valid=!1,b))break;!b&&(K(Q,R.name)?Y?Yi(t.errors,Q,R.name):ce(t.errors,R.name,Q[R.name]):pe(t.errors,R.name))}!ke(W)&&await M(W,b,E)}}return E.valid},j=(d,b)=>!n.disabled&&(d&&b&&ce(r,d,b),!Ae(B(),a)),$=(d,b,E)=>((F,A,R,W,Y)=>Se(F)?(W&&A.watch.add(F),K(R,F,Y)):Array.isArray(F)?F.map(q=>(W&&A.watch.add(q),K(R,q))):(W&&(A.watchAll=!0),R))(d,i,{...c.mount?r:fe(b)?a:Se(d)?{[d]:b}:b},E,b),O=(d,b,E={})=>{const F=K(s,d);let A=b;if(F){const R=F._f;R&&(!R.disabled&&ce(r,d,hr(b,R)),A=Ot(R.ref)&&we(b)?"":b,pr(R.ref)?[...R.ref.options].forEach(W=>W.selected=A.includes(W.value)):R.refs?ut(R.ref)?R.refs.forEach(W=>{W.defaultChecked&&W.disabled||(Array.isArray(A)?W.checked=!!A.find(Y=>Y===W.value):W.checked=A===W.value||!!A)}):R.refs.forEach(W=>W.checked=W.value===A):yn(R.ref)?R.ref.value="":(R.ref.value=A,R.ref.type||g.state.next({name:d,values:ge(r)})))}(E.shouldDirty||E.shouldTouch)&&v(d,A,E.shouldTouch,E.shouldDirty,!0),E.shouldValidate&&T(d)},P=(d,b,E)=>{for(const F in b){if(!b.hasOwnProperty(F))return;const A=b[F],R=d+"."+F,W=K(s,R);(i.array.has(d)||me(A)||W&&!W._f)&&!$e(A)?P(R,A,E):O(R,A,E)}},C=(d,b,E={})=>{const F=K(s,d),A=i.array.has(d),R=ge(b);ce(r,d,R),A?(g.array.next({name:d,values:ge(r)}),(m.isDirty||m.dirtyFields||k.isDirty||k.dirtyFields)&&E.shouldDirty&&g.state.next({name:d,dirtyFields:qe(a,r),isDirty:j(d,R)})):!F||F._f||we(R)?O(d,R,E):P(d,R,E),mo(d,i)&&g.state.next({...t,name:d}),g.state.next({name:c.mount?d:void 0,values:ge(r)})},D=async d=>{c.mount=!0;const b=d.target;let E=b.name,F=!0;const A=K(s,E),R=q=>{F=Number.isNaN(q)||$e(q)&&isNaN(q.getTime())||Ae(q,K(r,E,q))},W=po(n.mode),Y=po(n.reValidateMode);if(A){let q,Q;const te=b.type?uo(A._f):(le=>me(le)&&le.target?ut(le.target)?le.target.checked:le.target.value:le)(d),ae=d.type===Ni||d.type===Bi,ue=!(le=>le.mount&&(le.required||le.min||le.max||le.maxLength||le.minLength||le.pattern||le.validate))(A._f)&&!n.resolver&&!K(t.errors,E)&&!A._f.deps||((le,U,he,et,Re)=>!Re.isOnAll&&(!he&&Re.isOnTouch?!(U||le):(he?et.isOnBlur:Re.isOnBlur)?!le:!(he?et.isOnChange:Re.isOnChange)||le))(ae,K(t.touchedFields,E),t.isSubmitted,Y,W),Oe=mo(E,i,ae);ce(r,E,te),ae?b&&b.readOnly||(A._f.onBlur&&A._f.onBlur(d),o&&o(0)):A._f.onChange&&A._f.onChange(d);const be=v(E,te,ae),G=!ke(be)||Oe;if(!ae&&g.state.next({name:E,type:d.type,values:ge(r)}),ue)return(m.isValid||k.isValid)&&(n.mode==="onBlur"?ae&&w():ae||w()),G&&g.state.next({name:E,...Oe?{}:be});if(!ae&&Oe&&g.state.next({...t}),n.resolver){const{errors:le}=await S([E]);if(R(te),F){const U=ho(t.errors,s,E),he=ho(le,s,U.name||E);q=he.error,E=he.name,Q=ke(le)}}else y([E],!0),q=(await go(A,i.disabled,r,x,n.shouldUseNativeValidation))[E],y([E]),R(te),F&&(q?Q=!1:(m.isValid||k.isValid)&&(Q=await M(s,!0)));F&&(A._f.deps&&(!Array.isArray(A._f.deps)||A._f.deps.length>0)&&T(A._f.deps),u(E,Q,q,be))}},I=(d,b)=>{if(K(t.errors,b)&&d.focus)return d.focus(),1},T=async(d,b={})=>{let E,F;const A=st(d);if(n.resolver){const R=await(async W=>{const{errors:Y}=await S(W);if(W)for(const q of W){const Q=K(Y,q);Q?ce(t.errors,q,Q):pe(t.errors,q)}else t.errors=Y;return Y})(fe(d)?d:A);E=ke(R),F=d?!A.some(W=>K(R,W)):E}else d?(F=(await Promise.all(A.map(async R=>{const W=K(s,R);return await M(W&&W._f?{[R]:W}:W)}))).every(Boolean),(F||t.isValid)&&w()):F=E=await M(s);return g.state.next({...!Se(d)||(m.isValid||k.isValid)&&E!==t.isValid?{}:{name:d},...n.resolver||!d?{isValid:E}:{},errors:t.errors}),b.shouldFocus&&!F&&dt(s,I,d?A:i.mount),F},B=(d,b)=>{let E={...c.mount?r:a};return b&&(E=dr(b.dirtyFields?t.dirtyFields:t.touchedFields,E)),fe(d)?E:Se(d)?K(E,d):d.map(F=>K(E,F))},_=(d,b)=>({invalid:!!K((b||t).errors,d),isDirty:!!K((b||t).dirtyFields,d),error:K((b||t).errors,d),isValidating:!!K(t.validatingFields,d),isTouched:!!K((b||t).touchedFields,d)}),V=(d,b,E)=>{const F=(K(s,d,{_f:{}})._f||{}).ref,A=K(t.errors,d)||{},{ref:R,message:W,type:Y,...q}=A;ce(t.errors,d,{...q,...b,ref:F}),g.state.next({name:d,errors:t.errors,isValid:!1}),E&&E.shouldFocus&&F&&F.focus&&F.focus()},z=d=>g.state.subscribe({next:b=>{var E,F,A;E=d.name,F=b.name,A=d.exact,E&&F&&E!==F&&!st(E).some(R=>R&&(A?R===F:R.startsWith(F)||F.startsWith(R)))||!((R,W,Y,q)=>{Y(R);const{name:Q,...te}=R;return ke(te)||Object.keys(te).length>=Object.keys(W).length||Object.keys(te).find(ae=>W[ae]===(!q||pt))})(b,d.formState||m,re,d.reRenderRoot)||d.callback({values:{...r},...t,...b,defaultValues:a})}}).unsubscribe,H=(d,b={})=>{for(const E of d?st(d):i.mount)i.mount.delete(E),i.array.delete(E),b.keepValue||(pe(s,E),pe(r,E)),!b.keepError&&pe(t.errors,E),!b.keepDirty&&pe(t.dirtyFields,E),!b.keepTouched&&pe(t.touchedFields,E),!b.keepIsValidating&&pe(t.validatingFields,E),!n.shouldUnregister&&!b.keepDefaultValue&&pe(a,E);g.state.next({values:ge(r)}),g.state.next({...t,...b.keepDirty?{isDirty:j()}:{}}),!b.keepIsValid&&w()},Z=({disabled:d,name:b})=>{(Te(d)&&c.mount||d||i.disabled.has(b))&&(d?i.disabled.add(b):i.disabled.delete(b))},X=(d,b={})=>{let E=K(s,d);const F=Te(b.disabled)||Te(n.disabled);return ce(s,d,{...E||{},_f:{...E&&E._f?E._f:{ref:{name:d}},name:d,mount:!0,...b}}),i.mount.add(d),E?Z({disabled:Te(b.disabled)?b.disabled:n.disabled,name:d}):h(d,!0,b.value),{...F?{disabled:b.disabled||n.disabled}:{},...n.progressive?{required:!!b.required,min:at(b.min),max:at(b.max),minLength:at(b.minLength),maxLength:at(b.maxLength),pattern:at(b.pattern)}:{},name:d,onChange:D,onBlur:D,ref:A=>{if(A){X(d,b),E=K(s,d);const R=fe(A.value)&&A.querySelectorAll&&A.querySelectorAll("input,select,textarea")[0]||A,W=(q=>gn(q)||ut(q))(R),Y=E._f.refs||[];if(W?Y.find(q=>q===R):R===E._f.ref)return;ce(s,d,{_f:{...E._f,...W?{refs:[...Y.filter($t),R,...Array.isArray(K(a,d))?[{}]:[]],ref:{type:R.type,name:d}}:{ref:R}}}),h(d,!1,void 0,R)}else E=K(s,d,{}),E._f&&(E._f.mount=!1),(n.shouldUnregister||b.shouldUnregister)&&(!((R,W)=>R.has((Y=>Y.substring(0,Y.search(/\.\d+(\.|$)/))||Y)(W)))(i.array,d)||!c.action)&&i.unMount.add(d)}}},J=()=>n.shouldFocusError&&dt(s,I,i.mount),ne=(d,b)=>async E=>{let F;E&&(E.preventDefault&&E.preventDefault(),E.persist&&E.persist());let A=ge(r);if(g.state.next({isSubmitting:!0}),n.resolver){const{errors:R,values:W}=await S();t.errors=R,A=ge(W)}else await M(s);if(i.disabled.size)for(const R of i.disabled)pe(A,R);if(pe(t.errors,"root"),ke(t.errors)){g.state.next({errors:{}});try{await d(A,E)}catch(R){F=R}}else b&&await b({...t.errors},E),J(),setTimeout(J);if(g.state.next({isSubmitted:!0,isSubmitting:!1,isSubmitSuccessful:ke(t.errors)&&!F,submitCount:t.submitCount+1,errors:t.errors}),F)throw F},oe=(d,b={})=>{const E=d?ge(d):a,F=ge(E),A=ke(d),R=A?a:F;if(b.keepDefaultValues||(a=E),!b.keepValues){if(b.keepDirtyValues){const W=new Set([...i.mount,...Object.keys(qe(a,r))]);for(const Y of Array.from(W))K(t.dirtyFields,Y)?ce(R,Y,K(r,Y)):C(Y,K(R,Y))}else{if(mn&&fe(d))for(const W of i.mount){const Y=K(s,W);if(Y&&Y._f){const q=Array.isArray(Y._f.refs)?Y._f.refs[0]:Y._f.ref;if(Ot(q)){const Q=q.closest("form");if(Q){Q.reset();break}}}}if(b.keepFieldsRef)for(const W of i.mount)C(W,K(R,W));else s={}}r=n.shouldUnregister?b.keepDefaultValues?ge(a):{}:ge(R),g.array.next({values:{...R}}),g.state.next({values:{...R}})}i={mount:b.keepDirtyValues?i.mount:new Set,unMount:new Set,array:new Set,disabled:new Set,watch:new Set,watchAll:!1,focus:""},c.mount=!m.isValid||!!b.keepIsValid||!!b.keepDirtyValues,c.watch=!!n.shouldUnregister,g.state.next({submitCount:b.keepSubmitCount?t.submitCount:0,isDirty:!A&&(b.keepDirty?t.isDirty:!(!b.keepDefaultValues||Ae(d,a))),isSubmitted:!!b.keepIsSubmitted&&t.isSubmitted,dirtyFields:A?{}:b.keepDirtyValues?b.keepDefaultValues&&r?qe(a,r):t.dirtyFields:b.keepDefaultValues&&d?qe(a,d):b.keepDirty?t.dirtyFields:{},touchedFields:b.keepTouched?t.touchedFields:{},errors:b.keepErrors?t.errors:{},isSubmitSuccessful:!!b.keepIsSubmitSuccessful&&t.isSubmitSuccessful,isSubmitting:!1,defaultValues:a})},ee=(d,b)=>oe(Ee(d)?d(r):d,b),re=d=>{t={...t,...d}},ie={control:{register:X,unregister:H,getFieldState:_,handleSubmit:ne,setError:V,_subscribe:z,_runSchema:S,_focusError:J,_getWatch:$,_getDirty:j,_setValid:w,_setFieldArray:(d,b=[],E,F,A=!0,R=!0)=>{if(F&&E&&!n.disabled){if(c.action=!0,R&&Array.isArray(K(s,d))){const W=E(K(s,d),F.argA,F.argB);A&&ce(s,d,W)}if(R&&Array.isArray(K(t.errors,d))){const W=E(K(t.errors,d),F.argA,F.argB);A&&ce(t.errors,d,W),((Y,q)=>{!Xt(K(Y,q)).length&&pe(Y,q)})(t.errors,d)}if((m.touchedFields||k.touchedFields)&&R&&Array.isArray(K(t.touchedFields,d))){const W=E(K(t.touchedFields,d),F.argA,F.argB);A&&ce(t.touchedFields,d,W)}(m.dirtyFields||k.dirtyFields)&&(t.dirtyFields=qe(a,r)),g.state.next({name:d,isDirty:j(d,b),dirtyFields:t.dirtyFields,errors:t.errors,isValid:t.isValid})}else ce(r,d,b)},_setDisabledField:Z,_setErrors:d=>{t.errors=d,g.state.next({errors:t.errors,isValid:!1})},_getFieldArray:d=>Xt(K(c.mount?r:a,d,n.shouldUnregister?K(a,d,[]):[])),_reset:oe,_resetDefaultValues:()=>Ee(n.defaultValues)&&n.defaultValues().then(d=>{ee(d,n.resetOptions),g.state.next({isLoading:!1})}),_removeUnmounted:()=>{for(const d of i.unMount){const b=K(s,d);b&&(b._f.refs?b._f.refs.every(E=>!$t(E)):!$t(b._f.ref))&&H(d)}i.unMount=new Set},_disableForm:d=>{Te(d)&&(g.state.next({disabled:d}),dt(s,(b,E)=>{const F=K(s,E);F&&(b.disabled=F._f.disabled||d,Array.isArray(F._f.refs)&&F._f.refs.forEach(A=>{A.disabled=F._f.disabled||d}))},0,!1))},_subjects:g,_proxyFormState:m,get _fields(){return s},get _formValues(){return r},get _state(){return c},set _state(d){c=d},get _defaultValues(){return a},get _names(){return i},set _names(d){i=d},get _formState(){return t},get _options(){return n},set _options(d){n={...n,...d}}},subscribe:d=>(c.mount=!0,k={...k,...d.formState},z({...d,formState:k})),trigger:T,register:X,handleSubmit:ne,watch:(d,b)=>Ee(d)?g.state.subscribe({next:E=>"values"in E&&d($(void 0,b),E)}):$(d,b,!0),setValue:C,getValues:B,reset:ee,resetField:(d,b={})=>{K(s,d)&&(fe(b.defaultValue)?C(d,ge(K(a,d))):(C(d,b.defaultValue),ce(a,d,ge(b.defaultValue))),b.keepTouched||pe(t.touchedFields,d),b.keepDirty||(pe(t.dirtyFields,d),t.isDirty=b.defaultValue?j(d,ge(K(a,d))):j()),b.keepError||(pe(t.errors,d),m.isValid&&w()),g.state.next({...t}))},clearErrors:d=>{d&&st(d).forEach(b=>pe(t.errors,b)),g.state.next({errors:d?t.errors:{}})},unregister:H,setError:V,setFocus:(d,b={})=>{const E=K(s,d),F=E&&E._f;if(F){const A=F.refs?F.refs[0]:F.ref;A.focus&&(A.focus(),b.shouldSelect&&Ee(A.select)&&A.select())}},getFieldState:_};return{...ie,formControl:ie}}function Xi(e={}){const o=p.useRef(void 0),n=p.useRef(void 0),[t,s]=p.useState({isDirty:!1,isValidating:!1,isLoading:Ee(e.defaultValues),isSubmitted:!1,isSubmitting:!1,isSubmitSuccessful:!1,isValid:!1,submitCount:0,dirtyFields:{},touchedFields:{},validatingFields:{},errors:e.errors||{},disabled:e.disabled||!1,isReady:!1,defaultValues:Ee(e.defaultValues)?void 0:e.defaultValues});if(!o.current)if(e.formControl)o.current={...e.formControl,formState:t},e.defaultValues&&!Ee(e.defaultValues)&&e.formControl.reset(e.defaultValues,e.resetOptions);else{const{formControl:r,...c}=Gi(e);o.current={...c,formState:t}}const a=o.current.control;return a._options=e,Ui(()=>{const r=a._subscribe({formState:a._proxyFormState,callback:()=>s({...a._formState}),reRenderRoot:!0});return s(c=>({...c,isReady:!0})),a._formState.isReady=!0,r},[a]),p.useEffect(()=>a._disableForm(e.disabled),[a,e.disabled]),p.useEffect(()=>{e.mode&&(a._options.mode=e.mode),e.reValidateMode&&(a._options.reValidateMode=e.reValidateMode)},[a,e.mode,e.reValidateMode]),p.useEffect(()=>{e.errors&&(a._setErrors(e.errors),a._focusError())},[a,e.errors]),p.useEffect(()=>{e.shouldUnregister&&a._subjects.state.next({values:a._getWatch()})},[a,e.shouldUnregister]),p.useEffect(()=>{if(a._proxyFormState.isDirty){const r=a._getDirty();r!==t.isDirty&&a._subjects.state.next({isDirty:r})}},[a,t.isDirty]),p.useEffect(()=>{e.values&&!Ae(e.values,n.current)?(a._reset(e.values,{keepFieldsRef:!0,...a._options.resetOptions}),n.current=e.values,s(r=>({...r}))):a._resetDefaultValues()},[a,e.values]),p.useEffect(()=>{a._state.mount||(a._setValid(),a._state.mount=!0),a._state.watch&&(a._state.watch=!1,a._subjects.state.next({...a._formState})),a._removeUnmounted()}),o.current.formState=((r,c,i,l=!0)=>{const m={defaultValues:c._defaultValues};for(const k in r)Object.defineProperty(m,k,{get:()=>{const g=k;return c._proxyFormState[g]!==pt&&(c._proxyFormState[g]=!l||pt),r[g]}});return m})(t,a),o.current}const Qi=["Ok","Cancel"],Zt=p.memo(p.forwardRef((e,o)=>{const{description:n,icon:t,onCancel:s,onOption:a,onDone:r,onValidateOption:c,createOptionsButton:i,options:l=Qi,autoFocusSel:m=".defaultOption",defaultOption:k=l[0],cancelOption:g="Cancel",autoFocus:x,children:w,...y}=e,h=Xi({shouldUseNativeValidation:!1}),{handleSubmit:v,formState:u}=h,S=p.useRef(null),M=p.useRef(null),j=p.useRef(null),$=N.useCallbackRef(async T=>{let B;try{if(B=await Promise.resolve(c?.(T))??!0,B!==!0)return;await Promise.resolve(a?.(T,T===g,T===k)),r?.(T)}catch{}},[a,r,c,g,k]),O=N.useCallbackRef((T,B)=>{setTimeout(()=>{$(k)},180)},[$]),P=N.useCallbackRef(()=>{a?.(g,!0,!1),s?.(),r?.(null)},[a,g,s,r]),C=u&&(Object.keys(u.errors).length>0||u.disabled||u.isSubmitted),D=N.useCallbackRef((T,B)=>{const _=T===g,V={className:B?"defaultOption":"action",type:B?"submit":"button",style:{minWidth:"75px"},onClick:()=>{_?P():B||$(T)}};if(i)return i(T,V,B);const z={className:B?"defaultOption":"action",variant:B?"contained":"outlined",size:"small",disabled:!_&&C,color:"primary",...V};if(B||_){const H=B?S:M;z.touchRippleRef=H,z.onPointerDown=Z=>{H.current?.start(Z,{center:!1}),Z.stopPropagation(),Z.preventDefault()}}return f.jsx(L.Button,{...z,children:f.jsx("div",{style:{paddingTop:"3px"},children:T})},`action:${T}`)},[l,k,g,i,u]),I=p.useMemo(()=>{const T=[];for(let B=0;B<l.length;B++){const _=l[B],V=k?_===k:B===0;T.push(D(_,V))}return T},[l,k,u]);return f.jsx(rr,{onCancel:P,initialPosition:{y:Fi==="touch"?"15":"35"},onDone:r,autoFocusSel:m,isModal:!0,ref:o,...y,children:f.jsx(Wi,{...h,children:f.jsxs("form",{ref:j,onSubmit:v(O),children:[f.jsx(L.DialogContent,{dividers:!0,onKeyDown:T=>{if(T.isDefaultPrevented())return;T.stopPropagation();let B=null,_=null;const V=T.which===N.KeyCodes.Escape&&g;if(V)B=g,_=M;else{if(C)return;T.which===N.KeyCodes.Enter&&(B=k??l[0],_=S)}B&&(_.current?.start(T,{center:!1}),setTimeout(()=>{_.current?.stop(T),V&&$(B)},180))},children:f.jsxs(L.Box,{sx:{display:"flex",flexDirection:"column",whiteSpace:"pre-wrap",rowGap:T=>T.spacing(t||n?1.5:0)},children:[f.jsxs(L.Box,{sx:{display:"flex",flexDirection:"column"},children:[t,f.jsx(L.Typography,{children:n})]}),w]})}),f.jsx(L.DialogActions,{sx:{paddingTop:T=>T.spacing(1),paddingBottom:T=>T.spacing(1),paddingLeft:T=>T.spacing(1),paddingRight:T=>T.spacing(1),backgroundColor:T=>se.alpha(T.palette.action.hover,.03)},children:I})]})})})})),Ji=Object.freeze(Object.defineProperty({__proto__:null,OptionsDialog:Zt,default:Zt},Symbol.toStringTag,{value:"Module"})),Zi=p.lazy(()=>Promise.resolve().then(()=>Ji)),ea=p.lazy(()=>Promise.resolve().then(()=>require("./Ctt_H1syChJ1jaik.cjs"))),Ft=p.memo(p.forwardRef((e,o)=>{const{command:n,disabled:t=!1,shortcut:s,children:a,...r}=e;return N.useCommand(n),f.jsx(Ke,{ref:o,label:t!==void 0?n?.label():"",shortcut:s!==void 0?s:Array.isArray(n?.shortcut())?n?.shortcut()[0]:n?.shortcut(),description:n?.description(),disabled:t,chips:n?.tags(),componentDisabled:n?.disabled(),...r,children:f.jsx("div",{style:{display:"flex",flex:"1 1 0%"},children:a})})})),ta=f.jsx(N.DynamicIcon,{}),bn=p.memo(p.forwardRef((e,o)=>{const{command:n,commandHook:t,scope:s,context:a,icon:r,label:c,disabled:i=!1,variant:l=N.CommandButtonType.Toolbar,shortcut:m,commandState:k,tooltipProps:g,...x}=e,w=p.useRef(null),y=p.useRef(!1),h=p.useMemo(()=>{const P={onExecute(C,D){t?.onExecute?.(C,D),y.current||(w.current?.start({center:!1}),setTimeout(()=>w.current?.stop({}),180)),y.current=!1},onError(C,D,I){t?.onError(C,D,I)}};return t?.beforeExecute&&(P.beforeExecute=t.beforeExecute),P},[t]),v=N.useCommand(n,h),u=p.useCallback(P=>{P.button===0&&P.preventDefault()},[]),S=p.useCallback(P=>{P.button===0&&n?.execute(k,t)},[v,t,k]),M=p.useCallback(P=>{P.keyCode!==N.KeyCodes.Enter&&P.keyCode!==N.KeyCodes.Space||n?.execute(k,t)},[v,t,k]),j=p.useMemo(()=>{if(r)return typeof r=="function"?r(n):r;let P=n?.icon(a);return P?(typeof P=="string"&&(P=f.jsx(N.DynamicIcon,{iconKey:P})),P):l===N.CommandButtonType.Toolbar||n?.state()?void 0:ta},[v,r]),$=p.useMemo(()=>({tabIndex:0,ref:o,selected:n?.state(),icon:l===N.CommandButtonType.Toolbar?j:f.jsx(zo,{selected:n?.state()??!1,children:j}),touchRippleRef:w,disabled:i||!n||n.disabled(),onMouseDown:u,onMouseUp:S,onKeyDown:M}),[v,t,i,j]);let O;return O=l===N.CommandButtonType.Menuitem?f.jsx(Je,{...x,chips:n?.tags(),...$,children:c??n?.label(s,a)}):f.jsx(mt,{...x,...$}),(c||n?.label())&&((n.disabled()||i)&&(O=f.jsx("div",{children:O})),O=f.jsx(Ft,{command:n,placement:l===N.CommandButtonType.Toolbar?"bottom-start":"right-start",shortcut:m,...g,children:O})),O}));bn.displayName="CommandButton";const na=f.jsx(N.DynamicIcon,{}),oa=p.memo(p.forwardRef((e,o)=>{const{command:n,scope:t,icon:s=na,label:a,variant:r=N.CommandButtonType.Toolbar,disabled:c=!1,commandHook:i,...l}=e,m=p.useRef(null),k=p.useRef(!1),g=p.useMemo(()=>{const O={onExecute(P,C){i?.onExecute?.(P,C),k.current||(m.current?.start({center:!1}),setTimeout(()=>m.current?.stop({}),180)),k.current=!1},onError(P,C,D){i?.onError(P,C,D)}};return i?.beforeExecute&&(O.beforeExecute=i.beforeExecute),O},[i]),x=N.useCommand(n,g),w=()=>n?.state()?.toString()||"0",[y,h]=p.useState(w),v=N.useCallbackRef(()=>{const O=parseFloat(y);isNaN(O)?h(w()):parseFloat(w())!==O&&n.execute(O,i)},[w,n,y,i]);p.useEffect(()=>{h(w())},[n?.state()]);const u=p.useMemo(()=>{let O=typeof s=="function"?s(n):s;return O&&(O=n?.icon()),typeof O=="string"&&(O=f.jsx(N.DynamicIcon,{iconKey:O})),O},[x,s,n?.icon]),S=p.useMemo(()=>a===void 0?n?.label(t):typeof a=="function"?a():a,[x]),M=p.useMemo(()=>f.jsx(L.IconButton,{...l,sx:{paddingTop:"0px",paddingBottom:"0px"},component:"div",disableRipple:!0,onClick:O=>O.stopPropagation(),onMouseDown:O=>{O.button===0&&O.stopPropagation()},onMouseUp:O=>{O.button===0&&O.stopPropagation()},children:f.jsx(L.Input,{inputMode:"numeric",disabled:c||!n||n.disabled(),inputProps:{tabIndex:0,name:`input-${n.key()}`,autoComplete:"off",type:"number",maxLength:4},sx:{paddingTop:"0px",paddingBottom:"0px",paddingLeft:"0px",paddingRight:"0px",fontSize:O=>`${Math.round(O.typography.fontSize)}px`,width:O=>"3.2em",input:{padding:"0 0",textAlign:"center",MozAppearance:"textfield"},"input::-webkit-inner-spin-button":{WebkitAppearance:"none",margin:"0"},minHeight:"24px"},value:y,onFocus:O=>{O.target?.select()},onKeyDown:O=>{if(O.which===N.KeyCodes.Enter)w()!==y&&(O.stopPropagation(),O.preventDefault(),v());else if(O.which===N.KeyCodes.Escape)w()!==y&&(h(w()),setTimeout(()=>{O.target?.select()},0),O.stopPropagation(),O.preventDefault());else{if(O.key.match("[-]")||O.key.match("[0-9.]")&&(y+O.key).length>4)return O.stopPropagation(),void O.preventDefault();if(O.which===N.KeyCodes.Space)return void O.preventDefault()}},onBlur:()=>{v()},onChange:O=>{if(O.target.value.length>4)return O.stopPropagation(),void O.preventDefault();h(O.target.value)}})}),[y,c,n]),j={tabIndex:0,ref:o,icon:u,touchRippleRef:m,disabled:c||!n||n.disabled(),onMouseDown:O=>{O.button===0&&O.preventDefault()},onMouseUp:O=>{O.button!==0||O.isPropagationStopped()||O.isDefaultPrevented()||O.isDefaultPrevented()||(O.preventDefault(),n?.execute(!n?.state?.(),g))},onKeyDown:O=>{O.keyCode!==N.KeyCodes.Enter&&O.keyCode!==N.KeyCodes.Space||n?.execute(!n?.state?.(),g)}};let $;return $=r===N.CommandButtonType.Menuitem?f.jsxs(Je,{...l,chips:n?.tags(),...j,children:[S,M]}):f.jsx(mt,{...l,...j}),n?.label()&&((n.disabled()||c)&&($=f.jsx("div",{children:$})),$=f.jsx(Ft,{command:n,placement:r===N.CommandButtonType.Toolbar?"bottom-start":"right-start",children:$})),$})),vn=p.memo(p.forwardRef((e,o)=>{const{variant:n=N.CommandButtonType.Toolbar,quickCommand:t,onQuickClick:s,commands:a,commandState:r,commandHook:c,disabled:i,label:l,icon:m,createPopupPanel:k,tooltip:g,selected:x,scope:w,...y}=e,h=p.useRef(null),v=p.useRef(!1),u=p.useMemo(()=>{const D={onExecute(I,T){c?.onExecute?.(I,T),v.current||(h.current?.start({center:!1}),setTimeout(()=>h.current?.stop({}),180)),v.current=!1},onError(I,T,B){c?.onError(I,T,B)}};return c?.beforeExecute&&(D.beforeExecute=c.beforeExecute),D},[c]),S=N.useCommands(a,[t],null,[t]),M=S[0],{label:j,icon:$}=p.useMemo(()=>{let D=null;l&&(D=typeof l=="function"?l(M):l),D||(D=M?.label?.(w));let I=m;return I||(I=M?.icon?.()),typeof I=="string"?I=f.jsx(N.DynamicIcon,{iconKey:I}):typeof I=="function"&&(I=I(M)),{label:D,icon:I}},[S,l,m]),O={disabled:i,scope:w,touchRippleRef:h,onQuickClick:s,tooltip:g,label:j,icon:$};(j||g)&&(O.createTooltip=({children:D},I)=>f.jsx(Ke,{label:j,description:g,disabled:I,children:D}));const P=N.useCallbackRef(D=>k?.(D,a),[k,S]),C=N.useCallbackRef(D=>M?.execute(r,u),[M]);return M?(O.quickButtonProps={},O.quickButtonProps.createTooltip=({children:D,placement:I},T)=>f.jsx(Ft,{command:M,placement:I??n===N.CommandButtonType.Toolbar?"bottom-start":"right-start",disabled:T,children:D}),O.disabled=O.disabled??M?.disabled(),s||(O.onQuickClick=C)):t&&(O.onQuickClick=()=>{}),O.selected=x??M?.state(),O.createPopupPanel=P,n===N.CommandButtonType.Toolbar?f.jsx(jt,{...y,...O,ref:o}):f.jsx(un,{...y,...O,ref:o})}));vn.displayName="CommandPopupButton";const ra=f.jsx(N.DynamicIcon,{iconKey:"Check"}),gr=p.memo(p.forwardRef((e,o)=>{const{sx:n,commands:t,commandButtonProps:s,parentFloat:a,createToolbarPalette:r,children:c,...i}=e,l=N.useImperativeElement(o,()=>({}),[]),[m,k]=p.useState(null),{reference:g}=ft({label:"toolbar",anchor:l.current,parentFloat:a,createPopupPanel:null}),x=p.useCallback(()=>{const O=m;O&&requestAnimationFrame(()=>{l.current?.contains(document.activeElement)&&O.focus()})},[]),w=p.useMemo(()=>({dense:!0,outlined:!1}),[]),y=p.useMemo(()=>{const{commandHook:O,...P}=s||{};return{commandHook:{beforeExecute:(C,D)=>O?.beforeExecute?.(C,D)!==!1&&g.closeAll(),onExecute(C,D){O?.onExecute?.(C,D),x()},onError(C,D,I){O?.onError?.(C,D,I)}},...P}},[g,s]),h=p.useMemo(()=>({...w,...y}),[w,y]),[v,u]=p.useReducer(O=>O+1,0);N.useCommands(t,[],{onChange:()=>{u()}});const S=p.useMemo(()=>({commands:t,parentFloat:g,...y}),[v,h,g,s]);let M=0;w.dense||(M+=2),w.outlined&&M++;let j=2;w.dense||(j=4);const $=p.useMemo(()=>r({commands:t,commandButtonProps:h,commandPopupProps:{commands:t,...S,...s}}),[v,h,S,r]);return f.jsx(L.Toolbar,{variant:"dense",sx:{minHeight:"unset",height:"unset",paddingTop:`${j}px`,paddingBottom:`${j}px`,paddingLeft:"6px !important",paddingRight:"6px !important",flex:"1 1 0%",alignItems:"center",userSelect:"none",flexGrow:1,display:"flex",overflow:"hidden",...n},ref:l,onFocus:O=>{O.relatedTarget&&!m&&k(O.relatedTarget)},onBlur:O=>{m&&!l?.current?.contains(O.relatedTarget)&&k(null)},onKeyDown:O=>{m&&O.which===N.KeyCodes.Escape&&m.focus()},...i,children:f.jsx("div",{ref:l,style:{flex:"1 1 100%",display:"flex",flexWrap:"wrap",rowGap:`${j}px`,columnGap:`${M}px`,alignItems:"center",maxWidth:"100%"},children:$})})}));gr.displayName="CommandToolbar";const ia=e=>{const{key:o,...n}=e;return f.jsx(bn,{...n},o)},aa=p.memo(p.forwardRef((e,o)=>{const{popupCommandKeys:n,renderCommandButton:t=ia,scope:s,commands:a,quickCommand:r,popupScope:c=r,commandState:i,commandHook:l,disabled:m=!1,...k}=e,g=N.useCommands(a,n?[r,...n]:[r]),{allDisabled:x}=p.useMemo(()=>{let y=0;const h=g.length;for(let v=0;v<h;v++){const u=g[v];u&&!u.disabled()&&y++}return{allDisabled:y===0}},[g]),w=p.useCallback((y,h)=>{const v={variant:N.CommandButtonType.Menuitem,commandHook:l,commandState:i,scope:c??s,disabled:m},u=[],S=n?n.length:0;for(let M=0;M<S;M++){const j=n[M];if(j===null||j==="-"){u.push(f.jsx(xo,{orientation:"horizontal"},`element-${u.length}`));continue}const $=h.getCommand(j),O={key:`${j}-${u.length}`,command:$,...v},P=t(O);P&&u.push(P)}return Tt({...y,children:u})},[m,l,i,c,n,t]);return n?f.jsx(vn,{ref:o,commands:a,disabled:m||x,commandHook:l,commandState:i,scope:s,quickCommand:r,createPopupPanel:w,...k}):t({ref:o,disabled:m,commandHook:l,commandState:i,scope:s,command:g[0],...k})}));exports.AnimatedBouncingEllipsisIcon=kr,exports.AnimatedCircleIcon=Do,exports.AnimatedClockIcon=xr,exports.AnimatedFadingEllipsisIcon=wr,exports.AnimatedOrbitIcon=Sr,exports.AnimatedTraversingEllipsisIcon=Cr,exports.ArrowDownIcon=Kt,exports.ArrowRightIcon=Io,exports.ChipStrip=nn,exports.ClosingReason={ByPopup:"popupDone",Cancel:"popupCancel",ClickAway:"clickAway"},exports.CommandButton=bn,exports.CommandPopupButton=vn,exports.CommandToolbar=gr,exports.CommandTooltip=Ft,exports.ContextMenu=Vr,exports.ErrorPanel=Mo,exports.ExhibitDivider=xo,exports.ExhibitFloatPanel=ln,exports.ExhibitIconButton=mt,exports.ExhibitMenuHeader=Kr,exports.ExhibitMenuItem=Je,exports.ExhibitOptionButton=qr,exports.ExhibitPopper=an,exports.ExhibitPopupIconButton=jt,exports.ExhibitPopupMenuItem=un,exports.ExhibitTooltip=Ke,exports.InputCommandButton=oa,exports.InternalWindow=rr,exports.LabelIcon=e=>{const{command:o,label:n,scope:t,icon:s=ra,sx:a,...r}=e;return f.jsxs(L.Box,{sx:{display:"flex",flexDirection:"row",textTransform:"none",alignItems:"center",fontSize:c=>c.typography.subtitle2.fontSize,...a},...r,children:[s,f.jsx(L.Typography,{component:"div",sx:{whiteSpace:"nowrap",lineHeight:"1",paddingLeft:c=>c.spacing(.25),paddingRight:c=>c.spacing(.25),fontSize:"inherit"},children:o?.label(t)||n})]})},exports.LoadingPanel=Oo,exports.ModalProvider=function(e){var o=e.children,n=e.legacy,t=n!==void 0&&n,s=e.suspense,a=s===void 0||s,r=e.fallback,c=r===void 0?null:r,i=p.useReducer(Zr,Jr),l=i[0],m=i[1],k=p.useCallback(function(v,u){var S=Wo(u,ei);v?m({type:Ce.UPDATE,payload:{id:v,props:S}}):console.error(Lt)},[m]),g=p.useCallback(function(v){v?m({type:Ce.HIDE,payload:{id:v}}):console.error(Lt)},[m]),x=p.useCallback(function(v){v?m({type:Ce.DESTROY,payload:{id:v}}):console.error(Lt)},[m]),w=p.useCallback(function(v){v?m({type:Ce.DESTROY_BY_ROOT_ID,payload:{rootId:v}}):console.error("[ERROR]: Modal root ID is missing")},[m]),y=p.useCallback(function(v,u,S){var M=Ho(8);return S&&S.rootId&&(M=S.rootId+"."+M),m({type:Ce.SHOW,payload:{id:M,component:v,props:u,options:S}}),{id:M,hide:function(){return g(M)},destroy:function(){return x(M)},update:function(j){return k(M,j)}}},[m,g,x,k]),h=a?p.Suspense:p.Fragment;return p.createElement(Uo.Provider,{value:{state:l,updateModal:k,hideModal:g,destroyModal:x,showModal:y,destroyModalsByRootId:w}},o,p.createElement(h,Object.assign({},a&&{fallback:c}),Object.keys(l).map(function(v){var u=l[v],S=u.component,M=u.props,j=u.options,$=function(){var P,C;M!=null&&M.onExited&&M.onExited.apply(M,arguments),M!=null&&(P=M.TransitionProps)!=null&&P.onExited&&(C=M.TransitionProps).onExited.apply(C,arguments),x(v)},O={};return O=t?{onExited:$}:{TransitionProps:xe({},M?.TransitionProps,{onExited:$})},p.createElement(S,Object.assign({},M,{key:v,onClose:function(){j&&j.hideOnClose&&g(v),j&&j.destroyOnClose&&j.hideOnClose&&x(v),M&&M.onClose&&M.onClose.apply(M,arguments)}},j&&!j.destroyOnClose&&O))})))},exports.NestingPopupButton=$o,exports.OptionsDialog=Zt,exports.PopupAutoFocus={Popup:"popup",Anchor:"anchor"},exports.PopupButtonType=Lo,exports.SelectedIcon=zo,exports.SimpleCommandPopupButton=aa,exports.SimpleTooltip=He,exports.StackTrace=tn,exports.ThemeMode={Light:"light",Dark:"dark"},exports.ThemedIcon=Ir,exports.clsx=ye,exports.createDownArrow=qt,exports.createExhibitTheme=(e,o)=>{let n=We.createTheme({palette:{mode:e?"dark":"light"}});const t={"--icon-primary":n.palette.primary.main,"--icon-secondary":n.palette.secondary.main,"--icon-secondary-light":n.palette.secondary.light,"--icon-success":n.palette.success.main,"--icon-success-light":n.palette.success.light,"--icon-info":n.palette.info.main,"--icon-warn":n.palette.warning.main,"--icon-error":n.palette.error.main,"--icon-error-light":n.palette.error.light,"--icon-grey":n.palette.text.icon??n.palette.action.active,"--icon-shadow":e?n.palette.text.primary:n.palette.divider,"--icon-size":"1.25rem","@media (pointer: coarse)":{"--icon-size":"1.75rem"}};let s={typography:{},palette:{mode:e?"dark":"light",text:{secondary:e?n.palette.text.secondary:se.alpha(n.palette.text.secondary,.75),icon:e?se.alpha(n.palette.text.secondary,.7):se.alpha(n.palette.text.primary,.75)}},components:{MuiDialogTitle:{styleOverrides:{root:{fontWeight:"normal"}}},MuiSelect:{defaultProps:{IconComponent:Kt,MenuProps:{container:()=>document.fullscreenElement??void 0}},styleOverrides:{iconOutlined:{top:"unset"}}},MuiListItemIcon:{styleOverrides:{root:{minWidth:"0px !important",overflow:"hidden",marginLeft:"0px",marginRight:"6px",padding:"1px 1px",border:"solid transparent 1px",color:"unset"}}},MuiMenuItem:{styleOverrides:{root:{paddingTop:"2px",paddingBottom:"2px",marginLeft:"4px",marginRight:"4px",paddingLeft:"6px",paddingRight:"18px",borderRadius:"4px",fontSize:"0.875em","@media (pointer: coarse)":{fontSize:"1em"},"&.Mui-selected":{}}}},MuiMenu:{defaultProps:{container:()=>document.fullscreenElement??void 0},styleOverrides:{root:{paddingTop:"2px",paddingBottom:"2px",marginLeft:"4px",marginRight:"4px",paddingLeft:"6px",paddingRight:"18px",borderRadius:"4px",fontSize:"0.875em","@media (pointer: coarse)":{fontSize:"1em"},"&.Mui-selected":{}}}},MuiToolbar:{styleOverrides:{root:{paddingTop:"4px",paddingBottom:"4px","@media (min-width: 600px)":{paddingTop:"4px",paddingBottom:"4px"}}}},MuiDivider:{styleOverrides:{root:{marginTop:"4px !important",marginBottom:"4px !important",marginLeft:"0px",marginRight:"0px"}}},MuiInputBase:{styleOverrides:{root:{}}},MuiPaper:{styleOverrides:{root:{...t}}},MuiPopper:{styleOverrides:{root:{"& .menu":{marginTop:"4px",marginBottom:"4px",borderRadius:"4px"}}}},SmartInputField:{styleOverrides:{automatic:{transition:"opacity 200ms cubic-bezier(0.4, 0, 0.2, 1) 0ms",color:function(){return n.palette.text.secondary}},dirty:{fontStyle:"italic",color:function(){return n.palette.text.secondary}}}}}},a=s;return o&&(a=bo.deepmerge(s,o)),We.createTheme(a)},exports.createScrollButton=Bt,exports.createScrollEdgeButton=e=>{const o={style:{cursor:"pointer"},...e};return N.defaultCreateScrollEdgeButton(o)},exports.createScrollEndButton=e=>Bt(e,N.ScrollbarOrientation.Horizontal?f.jsx(N.DynamicIcon,{iconKey:"ArrowRight",size:"small"}):f.jsx(N.DynamicIcon,{iconKey:"ArrowDownward",size:"small"}),"Scroll "+(e.orientation===N.ScrollbarOrientation.Horizontal?"Right":"Down"),`Scroll ${e.orientation===N.ScrollbarOrientation.Horizontal?"right":"down"}, 'Ctrl+Click' to scroll to the end`),exports.createScrollStartButton=e=>Bt(e,N.ScrollbarOrientation.Horizontal?f.jsx(N.DynamicIcon,{iconKey:"ArrowLeft",size:"small"}):f.jsx(N.DynamicIcon,{iconKey:"ArrowUpward",size:"small"}),"Scroll "+(e.orientation===N.ScrollbarOrientation.Horizontal?"Left":"Up"),`Scroll ${e.orientation===N.ScrollbarOrientation.Horizontal?"left":"up"}, 'Ctrl+Click' to scroll to the beginning`),exports.createStrokeShadowFilter=(e=1)=>o=>{if(o.palette.mode!=="dark")return;const n=o.palette.mode==="dark"?o.palette.text.primary:o.palette.divider;return`drop-shadow(0px 0px ${e}px ${n})`},exports.defaultCreatePopupPanel=Tt,exports.elevateColor=Yt,exports.getModalConfig=Yo,exports.getScrollbarCssVariables=Ao,exports.hexToRGB=_o,exports.overlayAlpha=function(e){let o=0;return o=e<1?5.11916*e**2:4.5*Math.log(e+1)+2,(o/100).toFixed(2)},exports.scrollbarTheming=sn,exports.setModalConfig=function(e){Object.assign(Ko,e)},exports.strokeShadowFilter=e=>{if(e.palette.mode==="dark")return`drop-shadow(0px 0px 1px ${e.palette.mode==="dark"?e.palette.text.primary:e.palette.divider})`},exports.toShortcutElements=cn,exports.useFloatStack=ft,exports.useInputDialog=e=>{const{showModal:o}=ht();return n=>{const{defaultOption:t=n.options?.[0],cancelOption:s="Cancel",...a}=n;return new Promise(r=>{const c=o(ea,{...e,defaultOption:t,cancelOption:s,...a,onOption(i){a?.onOption?.(i,i===s,i===t),r({input:"",option:i})},onInput(i,l){a?.onInput?.(i,l),r({input:i,option:l})},onDone:()=>{a?.onDone?.(),c.hide()}})})}},exports.useLazyWindow=function(e){const[o,n]=p.useState(()=>new Map),{showModal:t,updateModal:s,destroyModal:a,hideModal:r}=ht({disableAutoDestroy:!0});return(c,i,l,m)=>new Promise((k,g)=>{let x=!1;l?.disableAutoDestroy!==void 0&&(x=l.disableAutoDestroy,delete(l={...l}).disableAutoDestroy);const w={...e,...l,...m,onHide:()=>{const u=o.get(c);m?.onHide?.(),n(S=>(S.delete(c),S)),r(u.id)},onDone:u=>{const S=o.get(c);n(M=>(M.delete(c),M)),m?.onDone?.(u),S&&S.id&&!x&&a(S.id)},onShown:u=>{n(S=>{const M=S.get(c);return S.set(c,{...M,element:u}),S}),k(u)},open:!0},y=o.get(c);if(y)return s(y.id,w),k(y.element),void(w.autoFocus&&y.element?.focus());if(!i)return void g(`Invalid function for window '${c}'`);const h=p.lazy(i),v=t(h,w,{destroyOnClose:!x});n(u=>(u.set(c,{id:v.id,element:null}),u))})},exports.useModal=ht,exports.useOptionsDialog=e=>{const{showModal:o}=ht();return n=>new Promise(t=>{const s=o(Zi,{...e,...n,onOption(a){n?.onOption?.(a,a===n.cancelOption,a===n.defaultOption),t(a)},onDone:()=>{n?.onDone?.(),s.hide()}})})},exports.useResolvedThemeMode=function(e){const{mode:o}=e||{},[n,t]=p.useState(()=>{if(o==="light"||o==="dark")return{themeMode:o,source:"prop"};if(typeof document<"u"){const s=Mn();if(s)return{themeMode:s,source:"class"}}return{themeMode:Tn(),source:"media"}});return p.useEffect(()=>{const s=()=>{if(o)return void(o===n.themeMode&&n.source==="prop"||t(l=>({...l,themeMode:o,source:"prop"})));const i=Mn();if(i)t({themeMode:i,source:"class"});else{const l=Tn();t({themeMode:l,source:"media"})}},a=new MutationObserver(s),r=[document.documentElement,document.body].filter(Boolean);for(const i of r)a.observe(i,{attributes:!0,attributeFilter:["class"]});const c=window.matchMedia("(prefers-color-scheme: dark)");return c.addEventListener("change",s),s(),()=>{a.disconnect(),c.removeEventListener("change",s)}},[o]),n},exports.wrapErrorAsComponent=Eo;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";/**
|
|
2
|
-
* @license @sheetxl/utils-mui - Utilities MUI - Utilities for MUI Components needed for all SheetXL components. - v0.7.
|
|
2
|
+
* @license @sheetxl/utils-mui - Utilities MUI - Utilities for MUI Components needed for all SheetXL components. - v0.7.16
|
|
3
3
|
*
|
|
4
4
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
6
|
-
*/Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("react/jsx-runtime"),o=require("react"),O=require("./
|
|
6
|
+
*/Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("react/jsx-runtime"),o=require("react"),O=require("./C44XRP-zhbpgMlg3.cjs"),s=require("@mui/material/styles"),p=require("@mui/material"),n=require("@sheetxl/utils-react"),L=["Input"],N=o.memo(o.forwardRef((b,k)=>{const{initialValue:T="",onOption:v,onValidateOption:c,onInput:d,onValidateInput:r,onDone:g,inputProps:f,inputLabel:w,inputType:F,inputPlaceHolder:S,options:h=L,autoFocusSel:q=".autoFocus",cancelOption:m,defaultOption:x=h?.[0],...R}=b,[j,I]=o.useState(!1),[a,P]=o.useState(T),[D,V]=o.useState(""),[B,M]=o.useState(!0),l=n.useCallbackRef(async(e,t)=>{if(!r)return!0;const u=await r?.(e,t);V(u?.message??"");const C=u?.valid??!0;return M(C),C},[r]),y=n.useCallbackRef(async e=>{d?.(a,e)},[a,d,g,v,m,x]),A=n.useCallbackRef(async e=>{e.keyCode===n.KeyCodes.Enter&&await l?.(a,null)},[a,y]),H=n.useCallbackRef(e=>{P(e.target.value),l?.(e.target.value,null)},[c]),K=n.useCallbackRef(async e=>{let t=await l(a,e);try{t!==!1&&(t=await l(a,e))}catch{}return t??!0},[a,c]);return i.jsx(O.OptionsDialog,{options:h,onDone:g,onOption:(e,t)=>{t||y(e)},onValidateOption:K,cancelOption:m,defaultOption:x,autoFocusSel:q,ref:k,...R,children:i.jsx(p.Box,{sx:{paddingTop:e=>e.spacing(1),paddingBottom:e=>e.spacing(0)},children:i.jsx(p.FormControl,{sx:{paddingTop:e=>e.spacing(1.5),minWidth:135,width:"100%"},size:"small",children:i.jsx(p.TextField,{onFocus:e=>{j||e.target?.select(),I(!0)},type:F,label:w,helperText:D||" ",sx:{width:"100%","& .MuiFormHelperText-root":{marginTop:e=>e.spacing(.5),color:B?void 0:"error.main"}},slotProps:{inputLabel:{shrink:!0},htmlInput:{placeholder:S,spellCheck:!1,autoComplete:"off",...f,className:O.clsx("autoFocus",f?.className),sx:{paddingTop:e=>e.spacing(1.25),paddingBottom:e=>e.spacing(.75),backgroundImage:`linear-gradient(${s.alpha("#fff",s.getOverlayAlpha(5))}, ${s.alpha("#fff",s.getOverlayAlpha(5))})`}}},value:a,onChange:H,onKeyDown:A,onContextMenu:e=>{e.stopPropagation()}})})})})}));exports.default=N;
|
package/browser/cjs/index.cjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
(function(){"use strict";try{if(typeof document<"u"){var e=document.createElement("style");e.appendChild(document.createTextNode("._traverse-ellipsis_14l1h_1{display:inline-block;position:relative}._traverse-ellipsis_14l1h_1 div{position:absolute;border-radius:50%}._traverse-ellipsis_14l1h_1 div:nth-child(1){left:0;animation:_traverse-ellipsis1_14l1h_1 .6s infinite}._traverse-ellipsis_14l1h_1 div:nth-child(2){left:0;animation:_traverse-ellipsis2_14l1h_1 .6s infinite}._traverse-ellipsis_14l1h_1 div:nth-child(3){left:24px;animation:_traverse-ellipsis2_14l1h_1 .6s infinite}._traverse-ellipsis_14l1h_1 div:nth-child(4){left:48px;animation:_traverse-ellipsis3_14l1h_1 .6s infinite}@keyframes _traverse-ellipsis1_14l1h_1{0%{transform:scale(0)}to{transform:scale(1)}}@keyframes _traverse-ellipsis3_14l1h_1{0%{transform:scale(1)}to{transform:scale(0)}}@keyframes _traverse-ellipsis2_14l1h_1{0%{transform:translate(0)}to{transform:translate(24px)}}")),document.head.appendChild(e)}}catch(i){console.error("vite-plugin-css-injected-by-js",i)}})();
|
|
2
2
|
"use strict";/**
|
|
3
|
-
* @license @sheetxl/utils-mui - Utilities MUI - Utilities for MUI Components needed for all SheetXL components. - v0.7.
|
|
3
|
+
* @license @sheetxl/utils-mui - Utilities MUI - Utilities for MUI Components needed for all SheetXL components. - v0.7.16
|
|
4
4
|
*
|
|
5
5
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
6
6
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
7
|
-
*/Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("./
|
|
7
|
+
*/Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("./C44XRP-zhbpgMlg3.cjs");exports.AnimatedBouncingEllipsisIcon=o.AnimatedBouncingEllipsisIcon,exports.AnimatedCircleIcon=o.AnimatedCircleIcon,exports.AnimatedClockIcon=o.AnimatedClockIcon,exports.AnimatedFadingEllipsisIcon=o.AnimatedFadingEllipsisIcon,exports.AnimatedOrbitIcon=o.AnimatedOrbitIcon,exports.AnimatedTraversingEllipsisIcon=o.AnimatedTraversingEllipsisIcon,exports.ArrowDownIcon=o.ArrowDownIcon,exports.ArrowRightIcon=o.ArrowRightIcon,exports.ChipStrip=o.ChipStrip,exports.ClosingReason=o.ClosingReason,exports.CommandButton=o.CommandButton,exports.CommandPopupButton=o.CommandPopupButton,exports.CommandToolbar=o.CommandToolbar,exports.CommandTooltip=o.CommandTooltip,exports.ContextMenu=o.ContextMenu,exports.ErrorPanel=o.ErrorPanel,exports.ExhibitDivider=o.ExhibitDivider,exports.ExhibitFloatPanel=o.ExhibitFloatPanel,exports.ExhibitIconButton=o.ExhibitIconButton,exports.ExhibitMenuHeader=o.ExhibitMenuHeader,exports.ExhibitMenuItem=o.ExhibitMenuItem,exports.ExhibitOptionButton=o.ExhibitOptionButton,exports.ExhibitPopper=o.ExhibitPopper,exports.ExhibitPopupIconButton=o.ExhibitPopupIconButton,exports.ExhibitPopupMenuItem=o.ExhibitPopupMenuItem,exports.ExhibitTooltip=o.ExhibitTooltip,exports.InputCommandButton=o.InputCommandButton,exports.InternalWindow=o.InternalWindow,exports.LabelIcon=o.LabelIcon,exports.LoadingPanel=o.LoadingPanel,exports.ModalProvider=o.ModalProvider,exports.NestingPopupButton=o.NestingPopupButton,exports.OptionsDialog=o.OptionsDialog,exports.PopupAutoFocus=o.PopupAutoFocus,exports.PopupButtonType=o.PopupButtonType,exports.SelectedIcon=o.SelectedIcon,exports.SimpleCommandPopupButton=o.SimpleCommandPopupButton,exports.SimpleTooltip=o.SimpleTooltip,exports.StackTrace=o.StackTrace,exports.ThemeMode=o.ThemeMode,exports.ThemedIcon=o.ThemedIcon,exports.createDownArrow=o.createDownArrow,exports.createExhibitTheme=o.createExhibitTheme,exports.createScrollButton=o.createScrollButton,exports.createScrollEdgeButton=o.createScrollEdgeButton,exports.createScrollEndButton=o.createScrollEndButton,exports.createScrollStartButton=o.createScrollStartButton,exports.createStrokeShadowFilter=o.createStrokeShadowFilter,exports.defaultCreatePopupPanel=o.defaultCreatePopupPanel,exports.elevateColor=o.elevateColor,exports.getModalConfig=o.getModalConfig,exports.getScrollbarCssVariables=o.getScrollbarCssVariables,exports.hexToRGB=o.hexToRGB,exports.overlayAlpha=o.overlayAlpha,exports.scrollbarTheming=o.scrollbarTheming,exports.setModalConfig=o.setModalConfig,exports.strokeShadowFilter=o.strokeShadowFilter,exports.toShortcutElements=o.toShortcutElements,exports.useFloatStack=o.useFloatStack,exports.useInputDialog=o.useInputDialog,exports.useLazyWindow=o.useLazyWindow,exports.useModal=o.useModal,exports.useOptionsDialog=o.useOptionsDialog,exports.useResolvedThemeMode=o.useResolvedThemeMode,exports.wrapErrorAsComponent=o.wrapErrorAsComponent;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { jsx as i } from "react/jsx-runtime";
|
|
2
2
|
import { memo as j, forwardRef as z, useState as s } from "react";
|
|
3
|
-
import { O as E, c as R } from "./
|
|
3
|
+
import { O as E, c as R } from "./CkiwRvu0Y9rgxCr6.mjs";
|
|
4
4
|
import { alpha as y, getOverlayAlpha as O } from "@mui/material/styles";
|
|
5
5
|
import { Box as A, FormControl as W, TextField as q } from "@mui/material";
|
|
6
6
|
import { useCallbackRef as n, KeyCodes as G } from "@sheetxl/utils-react";
|
|
7
7
|
/**
|
|
8
|
-
* @license @sheetxl/utils-mui - Utilities MUI - Utilities for MUI Components needed for all SheetXL components. - v0.7.
|
|
8
|
+
* @license @sheetxl/utils-mui - Utilities MUI - Utilities for MUI Components needed for all SheetXL components. - v0.7.16
|
|
9
9
|
*
|
|
10
10
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
11
11
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
@@ -8,7 +8,7 @@ import { useTheme as dn, styled as ei, createTheme as On, useThemeProps as ti }
|
|
|
8
8
|
import { deepmerge as Pr } from "@mui/utils";
|
|
9
9
|
import Rr, { createPortal as ni } from "react-dom";
|
|
10
10
|
/**
|
|
11
|
-
* @license @sheetxl/utils-mui - Utilities MUI - Utilities for MUI Components needed for all SheetXL components. - v0.7.
|
|
11
|
+
* @license @sheetxl/utils-mui - Utilities MUI - Utilities for MUI Components needed for all SheetXL components. - v0.7.16
|
|
12
12
|
*
|
|
13
13
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
14
14
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
@@ -2653,7 +2653,7 @@ const Ba = ["Ok", "Cancel"], Or = ie(de((e, r) => {
|
|
|
2653
2653
|
n?.onDone?.(), s.hide();
|
|
2654
2654
|
} });
|
|
2655
2655
|
});
|
|
2656
|
-
}, za = q.lazy(() => import("./
|
|
2656
|
+
}, za = q.lazy(() => import("./BBaINx5mfXntn3rN.mjs")), Es = (e) => {
|
|
2657
2657
|
const { showModal: r } = gn();
|
|
2658
2658
|
return (n) => {
|
|
2659
2659
|
const { defaultOption: t = n.options?.[0], cancelOption: s = "Cancel", ...a } = n;
|
package/browser/esm/index.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
(function(){"use strict";try{if(typeof document<"u"){var e=document.createElement("style");e.appendChild(document.createTextNode("._traverse-ellipsis_14l1h_1{display:inline-block;position:relative}._traverse-ellipsis_14l1h_1 div{position:absolute;border-radius:50%}._traverse-ellipsis_14l1h_1 div:nth-child(1){left:0;animation:_traverse-ellipsis1_14l1h_1 .6s infinite}._traverse-ellipsis_14l1h_1 div:nth-child(2){left:0;animation:_traverse-ellipsis2_14l1h_1 .6s infinite}._traverse-ellipsis_14l1h_1 div:nth-child(3){left:24px;animation:_traverse-ellipsis2_14l1h_1 .6s infinite}._traverse-ellipsis_14l1h_1 div:nth-child(4){left:48px;animation:_traverse-ellipsis3_14l1h_1 .6s infinite}@keyframes _traverse-ellipsis1_14l1h_1{0%{transform:scale(0)}to{transform:scale(1)}}@keyframes _traverse-ellipsis3_14l1h_1{0%{transform:scale(1)}to{transform:scale(0)}}@keyframes _traverse-ellipsis2_14l1h_1{0%{transform:translate(0)}to{transform:translate(24px)}}")),document.head.appendChild(e)}}catch(i){console.error("vite-plugin-css-injected-by-js",i)}})();
|
|
2
|
-
import { C as s, z as t, y as e, B as n, D as i, F as l, A as r, n as p, J as u, $ as c, a5 as d, a7 as m, aa as h, a8 as E, K as b, H as I, x as C, a4 as g, E as S, b as B, a as x, f as P, Z as T, d as A, e as w, g as M, a6 as v, R as D, a9 as F, L as k, P as f, N as O, O as R, _ as y, a0 as L, S as W, ab as z, M as G, I as H, p as N, T as V, a2 as j, k as q, r as J, q as K, w as Q, v as U, m as X, a1 as Y, j as Z, W as _, h as $, i as aa, o as oa, s as sa, X as ta, l as ea, t as na, a3 as ia, V as la, Q as ra, Y as pa, U as ua, u as ca, G as da } from "./
|
|
2
|
+
import { C as s, z as t, y as e, B as n, D as i, F as l, A as r, n as p, J as u, $ as c, a5 as d, a7 as m, aa as h, a8 as E, K as b, H as I, x as C, a4 as g, E as S, b as B, a as x, f as P, Z as T, d as A, e as w, g as M, a6 as v, R as D, a9 as F, L as k, P as f, N as O, O as R, _ as y, a0 as L, S as W, ab as z, M as G, I as H, p as N, T as V, a2 as j, k as q, r as J, q as K, w as Q, v as U, m as X, a1 as Y, j as Z, W as _, h as $, i as aa, o as oa, s as sa, X as ta, l as ea, t as na, a3 as ia, V as la, Q as ra, Y as pa, U as ua, u as ca, G as da } from "./CkiwRvu0Y9rgxCr6.mjs";
|
|
3
3
|
/**
|
|
4
|
-
* @license @sheetxl/utils-mui - Utilities MUI - Utilities for MUI Components needed for all SheetXL components. - v0.7.
|
|
4
|
+
* @license @sheetxl/utils-mui - Utilities MUI - Utilities for MUI Components needed for all SheetXL components. - v0.7.16
|
|
5
5
|
*
|
|
6
6
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
7
7
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license @sheetxl/utils-mui - Utilities MUI - Utilities for MUI Components needed for all SheetXL components. - v0.7.
|
|
2
|
+
* @license @sheetxl/utils-mui - Utilities MUI - Utilities for MUI Components needed for all SheetXL components. - v0.7.16
|
|
3
3
|
*
|
|
4
4
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
package/node/esm/index.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license @sheetxl/utils-mui - Utilities MUI - Utilities for MUI Components needed for all SheetXL components. - v0.7.
|
|
2
|
+
* @license @sheetxl/utils-mui - Utilities MUI - Utilities for MUI Components needed for all SheetXL components. - v0.7.16
|
|
3
3
|
*
|
|
4
4
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
@@ -760,7 +760,7 @@ const Ft = { x: 0, y: 0 }, At = n(i((t2, o2) => {
|
|
|
760
760
|
o2?.onDone?.(), n2.hide();
|
|
761
761
|
} });
|
|
762
762
|
});
|
|
763
|
-
}, Ut = r.lazy(() => import("./
|
|
763
|
+
}, Ut = r.lazy(() => import("./DZBZtLhOBpcHChEQ.mjs")), Qt = (e2) => {
|
|
764
764
|
const { showModal: t2 } = ae();
|
|
765
765
|
return (o2) => {
|
|
766
766
|
const { defaultOption: r2 = o2.options?.[0], cancelOption: n2 = "Cancel", ...i2 } = o2;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sheetxl/utils-mui",
|
|
3
3
|
"description": "Utilities MUI - Utilities for MUI Components needed for all SheetXL components.",
|
|
4
|
-
"version": "0.7.
|
|
4
|
+
"version": "0.7.16",
|
|
5
5
|
"license": "SEE LICENSE IN <LICENSE>",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"exports": {
|
|
@@ -45,8 +45,8 @@
|
|
|
45
45
|
],
|
|
46
46
|
"dependencies": {
|
|
47
47
|
"@popperjs/core": "^2.11.8",
|
|
48
|
-
"@sheetxl/utils": "^0.7.
|
|
49
|
-
"@sheetxl/utils-react": "^0.7.
|
|
48
|
+
"@sheetxl/utils": "^0.7.16",
|
|
49
|
+
"@sheetxl/utils-react": "^0.7.16",
|
|
50
50
|
"clsx": "^2.1.1",
|
|
51
51
|
"detect-it": "^4.0.1",
|
|
52
52
|
"focus-trap-react": "^10.1.4",
|