@simoncomputing/mui-bueno-v2 0.18.2 → 0.18.4
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/CHANGELOG.md +19 -1
- package/dist/@types/index.d.ts +2 -0
- package/dist/components/Form/Inputs/CitationField/CitationField.d.ts +1 -1
- package/dist/components/Form/Inputs/CitationField/CitationManager/BaseCitationManager.d.ts +1 -1
- package/dist/components/Form/Inputs/CitationField/CitationManager/CitationTable.d.ts +8 -0
- package/dist/index.cjs.js +41 -41
- package/dist/index.es.js +2446 -2438
- package/dist/index.umd.js +39 -39
- package/package.json +1 -1
package/dist/index.umd.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
(function(Pe,F){typeof exports=="object"&&typeof module<"u"?F(exports,require("@mui/material"),require("react/jsx-runtime"),require("react"),require("formik"),require("react-router-dom"),require("@emotion/styled"),require("@emotion/react"),require("react-dom")):typeof define=="function"&&define.amd?define(["exports","@mui/material","react/jsx-runtime","react","formik","react-router-dom","@emotion/styled","@emotion/react","react-dom"],F):(Pe=typeof globalThis<"u"?globalThis:Pe||self,F(Pe["mui-bueno-v2"]={},Pe.MaterialUI,Pe["react/jsx-runtime"],Pe.React,Pe.Formik,Pe.ReactRouterDom,Pe.EmotionStyled,Pe.EmotionReact,Pe.ReactDom))})(this,function(Pe,F,v,J,jt,eo,AF,to,ls){"use strict";var xue=Object.defineProperty;var Sue=(Pe,F,v)=>F in Pe?xue(Pe,F,{enumerable:!0,configurable:!0,writable:!0,value:v}):Pe[F]=v;var wu=(Pe,F,v)=>Sue(Pe,typeof F!="symbol"?F+"":F,v);var DP,PP,NP,LP,FP,$P,BP,RP,zP,VP,HP,jP,WP,qP,UP,KP,YP,GP,JP,ZP,XP,QP,eN,tN;var Vx=document.createElement("style");Vx.textContent=`.sort-icon-asc{-moz-transform:scale(1,-1);-o-transform:scale(1,-1);-webkit-transform:scale(1,-1);transform:scaleY(-1)}.loading-page{width:100%;height:80%;display:flex;flex-direction:column;align-items:center;justify-content:center}.loading-page .text-content{display:flex;flex-direction:column}.citation-link,.selected-citation-link{vertical-align:super;font-size:smaller;padding:0 4px}.selected-citation-link{background-color:#e6e6e6}.citation-link:hover,.selected-citation-link:hover{cursor:pointer}.MuiTiptap-ControlledBubbleMenu-root{z-index:1300!important}.citation-tooltip .MuiTypography-subtitle2{font-size:.9rem}.citation-tooltip .citation-tooltip-divider{margin:6px 0;background-color:#adadad}
|
|
2
|
-
/*$vite$:1*/`,document.head.appendChild(Vx);function Hx(t){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const n in t)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(e,n,r.get?r:{enumerable:!0,get:()=>t[n]})}}return e.default=t,Object.freeze(e)}const I=Hx(J),IF=Hx(ls),le={breakpoints_xs:"0px",breakpoints_sm:"600px",breakpoints_md:"960px",breakpoints_lg:"1100px",breakpoints_xl:"1536px",light_palette_primary_light:"#4c98d7",light_palette_primary_main:"#005ea2",light_palette_primary_dark:"#1a4480",light_palette_secondary_light:"#9bb672",light_palette_secondary_main:"#607f35",light_palette_secondary_dark:"#3c4a29",light_palette_text_primary:"rgba(0, 0, 0, 0.8705882353)",light_palette_text_secondary:"rgba(0, 0, 0, 0.6)",light_palette_text_disabled:"rgba(0, 0, 0, 0.3803921569)",light_palette_error_light:"#dc5b52",light_palette_error_main:"#d83933",light_palette_error_dark:"#b50909",light_palette_warning_light:"#ffbe2e",light_palette_warning_main:"#e5a000",light_palette_warning_dark:"#c2850c",light_palette_info_light:"#4c98d7",light_palette_info_main:"#005ea2",light_palette_info_dark:"#1a4480",light_palette_success_light:"#9bb672",light_palette_success_main:"#607f35",light_palette_success_dark:"#3c4a29",light_palette_background_default:"#f9f9f9",light_palette_background_paper:"#fff",light_palette_background_appBar:"#252f3e",light_palette_divider_default:"#c9c9c9",dark_palette_primary_light:"#98cbfb",dark_palette_primary_main:"#4c98d7",dark_palette_primary_dark:"#005ea2",dark_palette_secondary_light:"#b8d293",dark_palette_secondary_main:"#9bb672",dark_palette_secondary_dark:"#607f35",dark_palette_text_primary:"#fff",dark_palette_text_secondary:"rgba(255, 255, 255, 0.7019607843)",dark_palette_text_disabled:"rgba(255, 255, 255, 0.5019607843)",dark_palette_error_light:"#f1928b",dark_palette_error_main:"#dc5b52",dark_palette_error_dark:"#d83933",dark_palette_warning_light:"#ffe396",dark_palette_warning_main:"#ffbe2e",dark_palette_warning_dark:"#e5a000",dark_palette_info_light:"#98cbfb",dark_palette_info_main:"#4c98d7",dark_palette_info_dark:"#005ea2",dark_palette_success_light:"#b8d293",dark_palette_success_main:"#9bb672",dark_palette_success_dark:"#607f35",dark_palette_background_default:"#121212",dark_palette_background_paper:"#1b1b1b",dark_palette_background_appBar:"#252f3e",dark_palette_divider_default:"#2e2e2e",common_palette_grey_50:"#f0f0f0",common_palette_grey_100:"#e6e6e6",common_palette_grey_200:"#c9c9c9",common_palette_grey_300:"#adadad",common_palette_grey_400:"#919191",common_palette_grey_500:"#757575",common_palette_grey_600:"#5c5c5c",common_palette_grey_700:"#454545",common_palette_grey_800:"#2e2e2e",common_palette_grey_900:"#1b1b1b",common_palette_grey_A100:"#e6e6e6",common_palette_grey_A200:"#c9c9c9",common_palette_grey_A400:"#919191",common_palette_grey_A700:"#454545",common_palette_common_white:"#fff",common_palette_common_black:"#000",shadows_0:"none",shadows_1:"2px 2px 5px 0px rgba(0, 0, 0, 0.05)",shadows_2:"2px 2px 7px 0px rgba(0, 0, 0, 0.075)",shadows_3:"2px 3px 7px 0px rgba(0, 0, 0, 0.075), 0px 1px 10px 0px rgba(0, 0, 0, 0.05)",shadows_4:"2px 4px 8px 0px rgba(0, 0, 0, 0.075), 0px 1px 12px 0px rgba(0, 0, 0, 0.075)",shadows_5:"2px 5px 8px 0px rgba(0, 0, 0, 0.075), 0px 2px 14px 0px rgba(0, 0, 0, 0.1)",shadows_6:"2px 6px 10px 0px rgba(0, 0, 0, 0.1), 0px 2px 18px 0px rgba(0, 0, 0, 0.1)",shadows_7:"2px 7px 10px 1px rgba(0, 0, 0, 0.1), 0px 2px 16px 1px rgba(0, 0, 0, 0.12)",shadows_8:"2px 8px 10px 1px rgba(0, 0, 0, 0.1), 0px 3px 14px 2px rgba(0, 0, 0, 0.12)",shadows_9:"2px 9px 12px 1px rgba(0, 0, 0, 0.1), 0px 3px 16px 2px rgba(0, 0, 0, 0.12)",shadows_10:"2px 10px 14px 1px rgba(0, 0, 0, 0.12), 0px 4px 18px 3px rgba(0, 0, 0, 0.12)",shadows_11:"2px 11px 15px 1px rgba(0, 0, 0, 0.12), 0px 4px 20px 3px rgba(0, 0, 0, 0.12)",shadows_12:"2px 12px 17px 2px rgba(0, 0, 0, 0.12), 0px 5px 22px 4px rgba(0, 0, 0, 0.12)",shadows_13:"2px 13px 19px 2px rgba(0, 0, 0, 0.12), 0px 5px 24px 4px rgba(0, 0, 0, 0.12)",shadows_14:"2px 14px 21px 2px rgba(0, 0, 0, 0.12), 0px 5px 26px 4px rgba(0, 0, 0, 0.12)",shadows_15:"2px 15px 22px 2px rgba(0, 0, 0, 0.12), 0px 6px 28px 5px rgba(0, 0, 0, 0.12)",shadows_16:"2px 16px 24px 2px rgba(0, 0, 0, 0.12), 0px 6px 30px 5px rgba(0, 0, 0, 0.12)",shadows_17:"2px 17px 26px 2px rgba(0, 0, 0, 0.14), 0px 6px 32px 5px rgba(0, 0, 0, 0.12)",shadows_18:"2px 18px 28px 2px rgba(0, 0, 0, 0.14), 0px 7px 34px 6px rgba(0, 0, 0, 0.12)",shadows_19:"2px 19px 29px 2px rgba(0, 0, 0, 0.14), 0px 7px 36px 6px rgba(0, 0, 0, 0.12)",shadows_20:"2px 20px 31px 3px rgba(0, 0, 0, 0.14), 0px 8px 38px 7px rgba(0, 0, 0, 0.12)",shadows_21:"2px 21px 33px 3px rgba(0, 0, 0, 0.14), 0px 8px 40px 7px rgba(0, 0, 0, 0.12)",shadows_22:"2px 22px 35px 3px rgba(0, 0, 0, 0.14), 0px 8px 42px 7px rgba(0, 0, 0, 0.12)",shadows_23:"2px 23px 36px 3px rgba(0, 0, 0, 0.14), 0px 9px 44px 8px rgba(0, 0, 0, 0.12)",shadows_24:"2px 24px 38px 3px rgba(0, 0, 0, 0.14), 0px 9px 46px 8px rgba(0, 0, 0, 0.12)",shape_borderRadius:"3px",shape_borderStyle:'"solid"',shape_borderWidth:"1px",shape_buttonBorderWidth:"2px",typography_fontFamily_default:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_h1_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_h1_fontWeight:"700",typography_h1_fontSize:"2rem",typography_h1_lineHeight:"normal",typography_h1_letterSpacing:"normal",typography_h2_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_h2_fontWeight:"700",typography_h2_fontSize:"1.75rem",typography_h2_lineHeight:"normal",typography_h2_letterSpacing:"normal",typography_h3_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_h3_fontWeight:"700",typography_h3_fontSize:"1.5rem",typography_h3_lineHeight:"normal",typography_h3_letterSpacing:"normal",typography_h4_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_h4_fontWeight:"700",typography_h4_fontSize:"1.35rem",typography_h4_lineHeight:"normal",typography_h4_letterSpacing:"normal",typography_h5_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_h5_fontWeight:"700",typography_h5_fontSize:"1.25rem",typography_h5_lineHeight:"normal",typography_h5_letterSpacing:"normal",typography_h6_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_h6_fontWeight:"700",typography_h6_fontSize:"1.1rem",typography_h6_lineHeight:"normal",typography_h6_letterSpacing:"normal",typography_subtitle1_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_subtitle1_fontWeight:"600",typography_subtitle1_fontSize:"1.25rem",typography_subtitle1_lineHeight:"normal",typography_subtitle1_letterSpacing:"normal",typography_subtitle2_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_subtitle2_fontWeight:"600",typography_subtitle2_fontSize:"1.125rem",typography_subtitle2_lineHeight:"normal",typography_subtitle2_letterSpacing:"normal",typography_body1_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_body1_fontWeight:"400",typography_body1_fontSize:"1.125rem",typography_body1_lineHeight:"normal",typography_body1_letterSpacing:"normal",typography_body2_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_body2_fontWeight:"400",typography_body2_fontSize:"1rem",typography_body2_lineHeight:"normal",typography_body2_letterSpacing:"normal",typography_button_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_button_fontWeight:"600",typography_button_fontSize:"1rem",typography_button_lineHeight:"normal",typography_button_letterSpacing:"normal",typography_caption_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_caption_fontWeight:"400",typography_caption_fontSize:"0.75rem",typography_caption_lineHeight:"normal",typography_caption_letterSpacing:"normal",typography_overline_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_overline_fontWeight:"400",typography_overline_fontSize:"0.75rem",typography_overline_lineHeight:"normal",typography_overline_letterSpacing:"normal"},vn={breakpoints:{values:{xs:parseInt(le.breakpoints_xs),sm:parseInt(le.breakpoints_sm),md:parseInt(le.breakpoints_md),lg:parseInt(le.breakpoints_lg),xl:parseInt(le.breakpoints_xl)}},shadows:["none",le.shadows_1,le.shadows_2,le.shadows_3,le.shadows_4,le.shadows_5,le.shadows_6,le.shadows_7,le.shadows_8,le.shadows_9,le.shadows_10,le.shadows_11,le.shadows_12,le.shadows_13,le.shadows_14,le.shadows_15,le.shadows_16,le.shadows_17,le.shadows_18,le.shadows_19,le.shadows_20,le.shadows_21,le.shadows_22,le.shadows_23,le.shadows_24],shape:{borderRadius:parseInt(le.shape_borderRadius)},typography:{fontFamily:le.typography_fontFamily_default,h1:{fontFamily:le.typography_h1_fontFamily,fontWeight:parseInt(le.typography_h1_fontWeight),fontSize:le.typography_h1_fontSize,lineHeight:le.typography_h1_lineHeight,letterSpacing:le.typography_h1_letterSpacing},h2:{fontFamily:le.typography_h2_fontFamily,fontWeight:parseInt(le.typography_h2_fontWeight),fontSize:le.typography_h2_fontSize,lineHeight:le.typography_h2_lineHeight,letterSpacing:le.typography_h2_letterSpacing},h3:{fontFamily:le.typography_h3_fontFamily,fontWeight:parseInt(le.typography_h3_fontWeight),fontSize:le.typography_h3_fontSize,lineHeight:le.typography_h3_lineHeight,letterSpacing:le.typography_h3_letterSpacing},h4:{fontFamily:le.typography_h4_fontFamily,fontWeight:parseInt(le.typography_h4_fontWeight),fontSize:le.typography_h4_fontSize,lineHeight:le.typography_h4_lineHeight,letterSpacing:le.typography_h4_letterSpacing},h5:{fontFamily:le.typography_h5_fontFamily,fontWeight:parseInt(le.typography_h5_fontWeight),fontSize:le.typography_h5_fontSize,lineHeight:le.typography_h5_lineHeight,letterSpacing:le.typography_h5_letterSpacing},h6:{fontFamily:le.typography_h6_fontFamily,fontWeight:parseInt(le.typography_h6_fontWeight),fontSize:le.typography_h6_fontSize,lineHeight:le.typography_h6_lineHeight,letterSpacing:le.typography_h6_letterSpacing},subtitle1:{fontFamily:le.typography_subtitle1_fontFamily,fontWeight:parseInt(le.typography_subtitle1_fontWeight),fontSize:le.typography_subtitle1_fontSize,lineHeight:le.typography_subtitle1_lineHeight,letterSpacing:le.typography_subtitle1_letterSpacing},subtitle2:{fontFamily:le.typography_subtitle2_fontFamily,fontWeight:parseInt(le.typography_subtitle2_fontWeight),fontSize:le.typography_subtitle2_fontSize,lineHeight:le.typography_subtitle2_lineHeight,letterSpacing:le.typography_subtitle2_letterSpacing},body1:{fontFamily:le.typography_body1_fontFamily,fontWeight:parseInt(le.typography_body1_fontWeight),fontSize:le.typography_body1_fontSize,lineHeight:le.typography_body1_lineHeight,letterSpacing:le.typography_body1_letterSpacing},body2:{fontFamily:le.typography_body2_fontFamily,fontWeight:parseInt(le.typography_body2_fontWeight),fontSize:le.typography_body2_fontSize,lineHeight:le.typography_body2_lineHeight,letterSpacing:le.typography_body2_letterSpacing},button:{fontFamily:le.typography_button_fontFamily,fontWeight:parseInt(le.typography_button_fontWeight),fontSize:le.typography_button_fontSize,lineHeight:le.typography_button_lineHeight,letterSpacing:le.typography_button_letterSpacing,textTransform:"none"},caption:{fontFamily:le.typography_caption_fontFamily,fontWeight:parseInt(le.typography_caption_fontWeight),fontSize:le.typography_caption_fontSize,lineHeight:le.typography_caption_lineHeight,letterSpacing:le.typography_caption_letterSpacing},overline:{fontFamily:le.typography_overline_fontFamily,fontWeight:parseInt(le.typography_overline_fontWeight),fontSize:le.typography_overline_fontSize,lineHeight:le.typography_overline_lineHeight,letterSpacing:le.typography_overline_letterSpacing}},palette:{grey:{50:le.common_palette_grey_50,100:le.common_palette_grey_100,200:le.common_palette_grey_200,300:le.common_palette_grey_300,400:le.common_palette_grey_400,500:le.common_palette_grey_500,600:le.common_palette_grey_600,700:le.common_palette_grey_700,800:le.common_palette_grey_800,900:le.common_palette_grey_900,A100:le.common_palette_grey_A100,A200:le.common_palette_grey_A200,A400:le.common_palette_grey_A400,A700:le.common_palette_grey_A700},common:{black:le.common_palette_common_black,white:le.common_palette_common_white},white:le.common_palette_common_white},components:{MuiCard:{defaultProps:{elevation:0},styleOverrides:{root:{borderStyle:"solid",borderWidth:le.shape_borderWidth}}},MuiAppBar:{styleOverrides:{root:{backgroundImage:"none"}}},MuiButton:{styleOverrides:{outlined:{borderWidth:le.shape_buttonBorderWidth,":hover":{borderWidth:le.shape_buttonBorderWidth}}}},MuiTable:{styleOverrides:{root:({ownerState:t})=>({...t.size==="x-small"&&{"& .MuiTableCell-root":{padding:"0px 16px"}}})}}}},DF=F.createTheme({...vn,palette:{...vn.palette,mode:"light",primary:{light:le.light_palette_primary_light,main:le.light_palette_primary_main,dark:le.light_palette_primary_dark},secondary:{light:le.light_palette_secondary_light,main:le.light_palette_secondary_main,dark:le.light_palette_secondary_dark},text:{primary:le.light_palette_text_primary,secondary:le.light_palette_text_secondary,disabled:le.light_palette_text_disabled},background:{default:le.light_palette_background_default,paper:le.light_palette_background_paper},error:{light:le.light_palette_error_light,main:le.light_palette_error_main,dark:le.light_palette_error_dark},success:{light:le.light_palette_success_light,main:le.light_palette_success_main,dark:le.light_palette_success_dark},info:{light:le.light_palette_info_light,main:le.light_palette_info_main,dark:le.light_palette_info_dark},warning:{light:le.light_palette_warning_light,main:le.light_palette_warning_main,dark:le.light_palette_warning_dark}},components:{...vn.components,MuiAppBar:{...(DP=vn.components)==null?void 0:DP.MuiAppBar,styleOverrides:{...(NP=(PP=vn.components)==null?void 0:PP.MuiAppBar)==null?void 0:NP.styleOverrides,root:{...($P=(FP=(LP=vn.components)==null?void 0:LP.MuiAppBar)==null?void 0:FP.styleOverrides)==null?void 0:$P.root,backgroundColor:le.light_palette_background_appBar}}},MuiCard:{...(BP=vn.components)==null?void 0:BP.MuiCard,styleOverrides:{...(zP=(RP=vn.components)==null?void 0:RP.MuiCard)==null?void 0:zP.styleOverrides,root:{...(jP=(HP=(VP=vn.components)==null?void 0:VP.MuiCard)==null?void 0:HP.styleOverrides)==null?void 0:jP.root,borderColor:le.light_palette_divider_default}}}}}),PF=F.createTheme({...vn,palette:{...vn.palette,mode:"dark",primary:{light:le.dark_palette_primary_light,main:le.dark_palette_primary_main,dark:le.dark_palette_primary_dark},secondary:{light:le.dark_palette_secondary_light,main:le.dark_palette_secondary_main,dark:le.dark_palette_secondary_dark},text:{primary:le.dark_palette_text_primary,secondary:le.dark_palette_text_secondary,disabled:le.dark_palette_text_disabled},background:{default:le.dark_palette_background_default,paper:le.dark_palette_background_paper},error:{light:le.dark_palette_error_light,main:le.dark_palette_error_main,dark:le.dark_palette_error_dark},success:{light:le.dark_palette_success_light,main:le.dark_palette_success_main,dark:le.dark_palette_success_dark},info:{light:le.dark_palette_info_light,main:le.dark_palette_info_main,dark:le.dark_palette_info_dark},warning:{light:le.dark_palette_warning_light,main:le.dark_palette_warning_main,dark:le.dark_palette_warning_dark}},components:{...vn.components,MuiAppBar:{...(WP=vn.components)==null?void 0:WP.MuiAppBar,styleOverrides:{...(UP=(qP=vn.components)==null?void 0:qP.MuiAppBar)==null?void 0:UP.styleOverrides,root:{...(GP=(YP=(KP=vn.components)==null?void 0:KP.MuiAppBar)==null?void 0:YP.styleOverrides)==null?void 0:GP.root,backgroundColor:le.dark_palette_background_appBar,backgroundImage:"none"}}},MuiCard:{...(JP=vn.components)==null?void 0:JP.MuiCard,styleOverrides:{...(XP=(ZP=vn.components)==null?void 0:ZP.MuiCard)==null?void 0:XP.styleOverrides,root:{...(tN=(eN=(QP=vn.components)==null?void 0:QP.MuiCard)==null?void 0:eN.styleOverrides)==null?void 0:tN.root,borderColor:le.dark_palette_divider_default}}}}}),NF=["w","xs","sm","md","lg","xl","alignment","justify","noMP","noGrid","gridClassName","gridStyle"],jx=t=>t>47&&t<58,Wx=t=>t>64&&t<123&&(t<91||t>96),LF=(t,e,n,r)=>{let o="",i=0,s=0,a=0,l=0;const u=r.selectionStart;let f=!1;if(t.length<=e.length){for(let _=0;_<t.length&&_<e.length;_++){for(;i<e.length&&e[i]!=="X"&&e[i]!=="9";)a++,s++,i++;(jx(t.charCodeAt(_))&&e[i]==="9"||Wx(t.charCodeAt(_))&&e[i]==="X")&&(a>0&&(l=a,a=0),o+=t[_],i++)}const p=jx(t.charCodeAt(u-1))?"number":Wx(t.charCodeAt(u-1))?"letter":"something else",g=p!=="number"&&e[u-1]==="9",m=p!=="letter"&&e[u-1]==="X";(g||m||p==="something else")&&(f=!0);let b="",S=0;Math.abs(n.length-t.length)<=1&&(s=0);let C=u+s;for(let _=0;_<o.length;_++){for(;S<e.length&&e[S]!=="X"&&e[S]!=="9";)b+=e[S],S++;b+=o[_],S++}t.length<n.length?window.requestAnimationFrame(()=>{r.selectionStart=C,r.selectionEnd=C}):e[C-1]!=="X"&&e[C-1]!=="9"?window.requestAnimationFrame(()=>{r.selectionStart=C+l,r.selectionEnd=C+l}):(f&&(C-=1),window.requestAnimationFrame(()=>{r.selectionStart=C,r.selectionEnd=C}));const T=e.slice(S);return T.indexOf("X")===-1&&T.indexOf("9")===-1&&(b+=T),b}return window.requestAnimationFrame(()=>{r.selectionStart=u-1,r.selectionEnd=u-1}),n};function Jn(t,e){const r=Object.keys(t).filter(i=>e.includes(i)),o={...t};for(const i of NF)delete o[i];for(const i of r)delete o[i];return o}const _n=t=>t.split(/(?=[A-Z])|[.\-_\s]+/).map(n=>n.charAt(0).toUpperCase()+n.slice(1).toLowerCase()).filter(Boolean).join(" ");function FF(t,e,n=!1,r=""){let o="";if(e==null||e.length==0)return r;if(n){let i="";const s=e.toString().split(",");let a=0;t.forEach(l=>{s.includes(String(l.value).toString())&&(i+=l.label,a<s.length-1&&(i+=", "),a++)}),o=i}else{const i=t.find(s=>e==s.value);i!=null&&(o=i.label)}return o}function vl(t,e,n){return t.onClick?{onClick:()=>{t.onClick(),t.path&&e(t.path),t.externalLink&&window.open(t.externalLink,"_blank","noopener"),n&&n()}}:t.path?{component:eo.Link,to:t.path}:t.externalLink?{href:t.externalLink}:{}}function zo(t,e){return process.env.NODE_ENV==="production"?()=>null:function(...r){return t(...r)||e(...r)}}var yi=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Zn(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var _u={exports:{}},At={};/**
|
|
2
|
+
/*$vite$:1*/`,document.head.appendChild(Vx);function Hx(t){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const n in t)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(e,n,r.get?r:{enumerable:!0,get:()=>t[n]})}}return e.default=t,Object.freeze(e)}const I=Hx(J),IF=Hx(ls),ae={breakpoints_xs:"0px",breakpoints_sm:"600px",breakpoints_md:"960px",breakpoints_lg:"1100px",breakpoints_xl:"1536px",light_palette_primary_light:"#4c98d7",light_palette_primary_main:"#005ea2",light_palette_primary_dark:"#1a4480",light_palette_secondary_light:"#9bb672",light_palette_secondary_main:"#607f35",light_palette_secondary_dark:"#3c4a29",light_palette_text_primary:"rgba(0, 0, 0, 0.8705882353)",light_palette_text_secondary:"rgba(0, 0, 0, 0.6)",light_palette_text_disabled:"rgba(0, 0, 0, 0.3803921569)",light_palette_error_light:"#dc5b52",light_palette_error_main:"#d83933",light_palette_error_dark:"#b50909",light_palette_warning_light:"#ffbe2e",light_palette_warning_main:"#e5a000",light_palette_warning_dark:"#c2850c",light_palette_info_light:"#4c98d7",light_palette_info_main:"#005ea2",light_palette_info_dark:"#1a4480",light_palette_success_light:"#9bb672",light_palette_success_main:"#607f35",light_palette_success_dark:"#3c4a29",light_palette_background_default:"#f9f9f9",light_palette_background_paper:"#fff",light_palette_background_appBar:"#252f3e",light_palette_divider_default:"#c9c9c9",dark_palette_primary_light:"#98cbfb",dark_palette_primary_main:"#4c98d7",dark_palette_primary_dark:"#005ea2",dark_palette_secondary_light:"#b8d293",dark_palette_secondary_main:"#9bb672",dark_palette_secondary_dark:"#607f35",dark_palette_text_primary:"#fff",dark_palette_text_secondary:"rgba(255, 255, 255, 0.7019607843)",dark_palette_text_disabled:"rgba(255, 255, 255, 0.5019607843)",dark_palette_error_light:"#f1928b",dark_palette_error_main:"#dc5b52",dark_palette_error_dark:"#d83933",dark_palette_warning_light:"#ffe396",dark_palette_warning_main:"#ffbe2e",dark_palette_warning_dark:"#e5a000",dark_palette_info_light:"#98cbfb",dark_palette_info_main:"#4c98d7",dark_palette_info_dark:"#005ea2",dark_palette_success_light:"#b8d293",dark_palette_success_main:"#9bb672",dark_palette_success_dark:"#607f35",dark_palette_background_default:"#121212",dark_palette_background_paper:"#1b1b1b",dark_palette_background_appBar:"#252f3e",dark_palette_divider_default:"#2e2e2e",common_palette_grey_50:"#f0f0f0",common_palette_grey_100:"#e6e6e6",common_palette_grey_200:"#c9c9c9",common_palette_grey_300:"#adadad",common_palette_grey_400:"#919191",common_palette_grey_500:"#757575",common_palette_grey_600:"#5c5c5c",common_palette_grey_700:"#454545",common_palette_grey_800:"#2e2e2e",common_palette_grey_900:"#1b1b1b",common_palette_grey_A100:"#e6e6e6",common_palette_grey_A200:"#c9c9c9",common_palette_grey_A400:"#919191",common_palette_grey_A700:"#454545",common_palette_common_white:"#fff",common_palette_common_black:"#000",shadows_0:"none",shadows_1:"2px 2px 5px 0px rgba(0, 0, 0, 0.05)",shadows_2:"2px 2px 7px 0px rgba(0, 0, 0, 0.075)",shadows_3:"2px 3px 7px 0px rgba(0, 0, 0, 0.075), 0px 1px 10px 0px rgba(0, 0, 0, 0.05)",shadows_4:"2px 4px 8px 0px rgba(0, 0, 0, 0.075), 0px 1px 12px 0px rgba(0, 0, 0, 0.075)",shadows_5:"2px 5px 8px 0px rgba(0, 0, 0, 0.075), 0px 2px 14px 0px rgba(0, 0, 0, 0.1)",shadows_6:"2px 6px 10px 0px rgba(0, 0, 0, 0.1), 0px 2px 18px 0px rgba(0, 0, 0, 0.1)",shadows_7:"2px 7px 10px 1px rgba(0, 0, 0, 0.1), 0px 2px 16px 1px rgba(0, 0, 0, 0.12)",shadows_8:"2px 8px 10px 1px rgba(0, 0, 0, 0.1), 0px 3px 14px 2px rgba(0, 0, 0, 0.12)",shadows_9:"2px 9px 12px 1px rgba(0, 0, 0, 0.1), 0px 3px 16px 2px rgba(0, 0, 0, 0.12)",shadows_10:"2px 10px 14px 1px rgba(0, 0, 0, 0.12), 0px 4px 18px 3px rgba(0, 0, 0, 0.12)",shadows_11:"2px 11px 15px 1px rgba(0, 0, 0, 0.12), 0px 4px 20px 3px rgba(0, 0, 0, 0.12)",shadows_12:"2px 12px 17px 2px rgba(0, 0, 0, 0.12), 0px 5px 22px 4px rgba(0, 0, 0, 0.12)",shadows_13:"2px 13px 19px 2px rgba(0, 0, 0, 0.12), 0px 5px 24px 4px rgba(0, 0, 0, 0.12)",shadows_14:"2px 14px 21px 2px rgba(0, 0, 0, 0.12), 0px 5px 26px 4px rgba(0, 0, 0, 0.12)",shadows_15:"2px 15px 22px 2px rgba(0, 0, 0, 0.12), 0px 6px 28px 5px rgba(0, 0, 0, 0.12)",shadows_16:"2px 16px 24px 2px rgba(0, 0, 0, 0.12), 0px 6px 30px 5px rgba(0, 0, 0, 0.12)",shadows_17:"2px 17px 26px 2px rgba(0, 0, 0, 0.14), 0px 6px 32px 5px rgba(0, 0, 0, 0.12)",shadows_18:"2px 18px 28px 2px rgba(0, 0, 0, 0.14), 0px 7px 34px 6px rgba(0, 0, 0, 0.12)",shadows_19:"2px 19px 29px 2px rgba(0, 0, 0, 0.14), 0px 7px 36px 6px rgba(0, 0, 0, 0.12)",shadows_20:"2px 20px 31px 3px rgba(0, 0, 0, 0.14), 0px 8px 38px 7px rgba(0, 0, 0, 0.12)",shadows_21:"2px 21px 33px 3px rgba(0, 0, 0, 0.14), 0px 8px 40px 7px rgba(0, 0, 0, 0.12)",shadows_22:"2px 22px 35px 3px rgba(0, 0, 0, 0.14), 0px 8px 42px 7px rgba(0, 0, 0, 0.12)",shadows_23:"2px 23px 36px 3px rgba(0, 0, 0, 0.14), 0px 9px 44px 8px rgba(0, 0, 0, 0.12)",shadows_24:"2px 24px 38px 3px rgba(0, 0, 0, 0.14), 0px 9px 46px 8px rgba(0, 0, 0, 0.12)",shape_borderRadius:"3px",shape_borderStyle:'"solid"',shape_borderWidth:"1px",shape_buttonBorderWidth:"2px",typography_fontFamily_default:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_h1_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_h1_fontWeight:"700",typography_h1_fontSize:"2rem",typography_h1_lineHeight:"normal",typography_h1_letterSpacing:"normal",typography_h2_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_h2_fontWeight:"700",typography_h2_fontSize:"1.75rem",typography_h2_lineHeight:"normal",typography_h2_letterSpacing:"normal",typography_h3_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_h3_fontWeight:"700",typography_h3_fontSize:"1.5rem",typography_h3_lineHeight:"normal",typography_h3_letterSpacing:"normal",typography_h4_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_h4_fontWeight:"700",typography_h4_fontSize:"1.35rem",typography_h4_lineHeight:"normal",typography_h4_letterSpacing:"normal",typography_h5_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_h5_fontWeight:"700",typography_h5_fontSize:"1.25rem",typography_h5_lineHeight:"normal",typography_h5_letterSpacing:"normal",typography_h6_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_h6_fontWeight:"700",typography_h6_fontSize:"1.1rem",typography_h6_lineHeight:"normal",typography_h6_letterSpacing:"normal",typography_subtitle1_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_subtitle1_fontWeight:"600",typography_subtitle1_fontSize:"1.25rem",typography_subtitle1_lineHeight:"normal",typography_subtitle1_letterSpacing:"normal",typography_subtitle2_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_subtitle2_fontWeight:"600",typography_subtitle2_fontSize:"1.125rem",typography_subtitle2_lineHeight:"normal",typography_subtitle2_letterSpacing:"normal",typography_body1_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_body1_fontWeight:"400",typography_body1_fontSize:"1.125rem",typography_body1_lineHeight:"normal",typography_body1_letterSpacing:"normal",typography_body2_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_body2_fontWeight:"400",typography_body2_fontSize:"1rem",typography_body2_lineHeight:"normal",typography_body2_letterSpacing:"normal",typography_button_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_button_fontWeight:"600",typography_button_fontSize:"1rem",typography_button_lineHeight:"normal",typography_button_letterSpacing:"normal",typography_caption_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_caption_fontWeight:"400",typography_caption_fontSize:"0.75rem",typography_caption_lineHeight:"normal",typography_caption_letterSpacing:"normal",typography_overline_fontFamily:'"source-sans-pro", "helvetica", "arial", sans-serif',typography_overline_fontWeight:"400",typography_overline_fontSize:"0.75rem",typography_overline_lineHeight:"normal",typography_overline_letterSpacing:"normal"},vn={breakpoints:{values:{xs:parseInt(ae.breakpoints_xs),sm:parseInt(ae.breakpoints_sm),md:parseInt(ae.breakpoints_md),lg:parseInt(ae.breakpoints_lg),xl:parseInt(ae.breakpoints_xl)}},shadows:["none",ae.shadows_1,ae.shadows_2,ae.shadows_3,ae.shadows_4,ae.shadows_5,ae.shadows_6,ae.shadows_7,ae.shadows_8,ae.shadows_9,ae.shadows_10,ae.shadows_11,ae.shadows_12,ae.shadows_13,ae.shadows_14,ae.shadows_15,ae.shadows_16,ae.shadows_17,ae.shadows_18,ae.shadows_19,ae.shadows_20,ae.shadows_21,ae.shadows_22,ae.shadows_23,ae.shadows_24],shape:{borderRadius:parseInt(ae.shape_borderRadius)},typography:{fontFamily:ae.typography_fontFamily_default,h1:{fontFamily:ae.typography_h1_fontFamily,fontWeight:parseInt(ae.typography_h1_fontWeight),fontSize:ae.typography_h1_fontSize,lineHeight:ae.typography_h1_lineHeight,letterSpacing:ae.typography_h1_letterSpacing},h2:{fontFamily:ae.typography_h2_fontFamily,fontWeight:parseInt(ae.typography_h2_fontWeight),fontSize:ae.typography_h2_fontSize,lineHeight:ae.typography_h2_lineHeight,letterSpacing:ae.typography_h2_letterSpacing},h3:{fontFamily:ae.typography_h3_fontFamily,fontWeight:parseInt(ae.typography_h3_fontWeight),fontSize:ae.typography_h3_fontSize,lineHeight:ae.typography_h3_lineHeight,letterSpacing:ae.typography_h3_letterSpacing},h4:{fontFamily:ae.typography_h4_fontFamily,fontWeight:parseInt(ae.typography_h4_fontWeight),fontSize:ae.typography_h4_fontSize,lineHeight:ae.typography_h4_lineHeight,letterSpacing:ae.typography_h4_letterSpacing},h5:{fontFamily:ae.typography_h5_fontFamily,fontWeight:parseInt(ae.typography_h5_fontWeight),fontSize:ae.typography_h5_fontSize,lineHeight:ae.typography_h5_lineHeight,letterSpacing:ae.typography_h5_letterSpacing},h6:{fontFamily:ae.typography_h6_fontFamily,fontWeight:parseInt(ae.typography_h6_fontWeight),fontSize:ae.typography_h6_fontSize,lineHeight:ae.typography_h6_lineHeight,letterSpacing:ae.typography_h6_letterSpacing},subtitle1:{fontFamily:ae.typography_subtitle1_fontFamily,fontWeight:parseInt(ae.typography_subtitle1_fontWeight),fontSize:ae.typography_subtitle1_fontSize,lineHeight:ae.typography_subtitle1_lineHeight,letterSpacing:ae.typography_subtitle1_letterSpacing},subtitle2:{fontFamily:ae.typography_subtitle2_fontFamily,fontWeight:parseInt(ae.typography_subtitle2_fontWeight),fontSize:ae.typography_subtitle2_fontSize,lineHeight:ae.typography_subtitle2_lineHeight,letterSpacing:ae.typography_subtitle2_letterSpacing},body1:{fontFamily:ae.typography_body1_fontFamily,fontWeight:parseInt(ae.typography_body1_fontWeight),fontSize:ae.typography_body1_fontSize,lineHeight:ae.typography_body1_lineHeight,letterSpacing:ae.typography_body1_letterSpacing},body2:{fontFamily:ae.typography_body2_fontFamily,fontWeight:parseInt(ae.typography_body2_fontWeight),fontSize:ae.typography_body2_fontSize,lineHeight:ae.typography_body2_lineHeight,letterSpacing:ae.typography_body2_letterSpacing},button:{fontFamily:ae.typography_button_fontFamily,fontWeight:parseInt(ae.typography_button_fontWeight),fontSize:ae.typography_button_fontSize,lineHeight:ae.typography_button_lineHeight,letterSpacing:ae.typography_button_letterSpacing,textTransform:"none"},caption:{fontFamily:ae.typography_caption_fontFamily,fontWeight:parseInt(ae.typography_caption_fontWeight),fontSize:ae.typography_caption_fontSize,lineHeight:ae.typography_caption_lineHeight,letterSpacing:ae.typography_caption_letterSpacing},overline:{fontFamily:ae.typography_overline_fontFamily,fontWeight:parseInt(ae.typography_overline_fontWeight),fontSize:ae.typography_overline_fontSize,lineHeight:ae.typography_overline_lineHeight,letterSpacing:ae.typography_overline_letterSpacing}},palette:{grey:{50:ae.common_palette_grey_50,100:ae.common_palette_grey_100,200:ae.common_palette_grey_200,300:ae.common_palette_grey_300,400:ae.common_palette_grey_400,500:ae.common_palette_grey_500,600:ae.common_palette_grey_600,700:ae.common_palette_grey_700,800:ae.common_palette_grey_800,900:ae.common_palette_grey_900,A100:ae.common_palette_grey_A100,A200:ae.common_palette_grey_A200,A400:ae.common_palette_grey_A400,A700:ae.common_palette_grey_A700},common:{black:ae.common_palette_common_black,white:ae.common_palette_common_white},white:ae.common_palette_common_white},components:{MuiCard:{defaultProps:{elevation:0},styleOverrides:{root:{borderStyle:"solid",borderWidth:ae.shape_borderWidth}}},MuiAppBar:{styleOverrides:{root:{backgroundImage:"none"}}},MuiButton:{styleOverrides:{outlined:{borderWidth:ae.shape_buttonBorderWidth,":hover":{borderWidth:ae.shape_buttonBorderWidth}}}},MuiTable:{styleOverrides:{root:({ownerState:t})=>({...t.size==="x-small"&&{"& .MuiTableCell-root":{padding:"0px 16px"}}})}}}},DF=F.createTheme({...vn,palette:{...vn.palette,mode:"light",primary:{light:ae.light_palette_primary_light,main:ae.light_palette_primary_main,dark:ae.light_palette_primary_dark},secondary:{light:ae.light_palette_secondary_light,main:ae.light_palette_secondary_main,dark:ae.light_palette_secondary_dark},text:{primary:ae.light_palette_text_primary,secondary:ae.light_palette_text_secondary,disabled:ae.light_palette_text_disabled},background:{default:ae.light_palette_background_default,paper:ae.light_palette_background_paper},error:{light:ae.light_palette_error_light,main:ae.light_palette_error_main,dark:ae.light_palette_error_dark},success:{light:ae.light_palette_success_light,main:ae.light_palette_success_main,dark:ae.light_palette_success_dark},info:{light:ae.light_palette_info_light,main:ae.light_palette_info_main,dark:ae.light_palette_info_dark},warning:{light:ae.light_palette_warning_light,main:ae.light_palette_warning_main,dark:ae.light_palette_warning_dark}},components:{...vn.components,MuiAppBar:{...(DP=vn.components)==null?void 0:DP.MuiAppBar,styleOverrides:{...(NP=(PP=vn.components)==null?void 0:PP.MuiAppBar)==null?void 0:NP.styleOverrides,root:{...($P=(FP=(LP=vn.components)==null?void 0:LP.MuiAppBar)==null?void 0:FP.styleOverrides)==null?void 0:$P.root,backgroundColor:ae.light_palette_background_appBar}}},MuiCard:{...(BP=vn.components)==null?void 0:BP.MuiCard,styleOverrides:{...(zP=(RP=vn.components)==null?void 0:RP.MuiCard)==null?void 0:zP.styleOverrides,root:{...(jP=(HP=(VP=vn.components)==null?void 0:VP.MuiCard)==null?void 0:HP.styleOverrides)==null?void 0:jP.root,borderColor:ae.light_palette_divider_default}}}}}),PF=F.createTheme({...vn,palette:{...vn.palette,mode:"dark",primary:{light:ae.dark_palette_primary_light,main:ae.dark_palette_primary_main,dark:ae.dark_palette_primary_dark},secondary:{light:ae.dark_palette_secondary_light,main:ae.dark_palette_secondary_main,dark:ae.dark_palette_secondary_dark},text:{primary:ae.dark_palette_text_primary,secondary:ae.dark_palette_text_secondary,disabled:ae.dark_palette_text_disabled},background:{default:ae.dark_palette_background_default,paper:ae.dark_palette_background_paper},error:{light:ae.dark_palette_error_light,main:ae.dark_palette_error_main,dark:ae.dark_palette_error_dark},success:{light:ae.dark_palette_success_light,main:ae.dark_palette_success_main,dark:ae.dark_palette_success_dark},info:{light:ae.dark_palette_info_light,main:ae.dark_palette_info_main,dark:ae.dark_palette_info_dark},warning:{light:ae.dark_palette_warning_light,main:ae.dark_palette_warning_main,dark:ae.dark_palette_warning_dark}},components:{...vn.components,MuiAppBar:{...(WP=vn.components)==null?void 0:WP.MuiAppBar,styleOverrides:{...(UP=(qP=vn.components)==null?void 0:qP.MuiAppBar)==null?void 0:UP.styleOverrides,root:{...(GP=(YP=(KP=vn.components)==null?void 0:KP.MuiAppBar)==null?void 0:YP.styleOverrides)==null?void 0:GP.root,backgroundColor:ae.dark_palette_background_appBar,backgroundImage:"none"}}},MuiCard:{...(JP=vn.components)==null?void 0:JP.MuiCard,styleOverrides:{...(XP=(ZP=vn.components)==null?void 0:ZP.MuiCard)==null?void 0:XP.styleOverrides,root:{...(tN=(eN=(QP=vn.components)==null?void 0:QP.MuiCard)==null?void 0:eN.styleOverrides)==null?void 0:tN.root,borderColor:ae.dark_palette_divider_default}}}}}),NF=["w","xs","sm","md","lg","xl","alignment","justify","noMP","noGrid","gridClassName","gridStyle"],jx=t=>t>47&&t<58,Wx=t=>t>64&&t<123&&(t<91||t>96),LF=(t,e,n,r)=>{let o="",i=0,s=0,a=0,l=0;const u=r.selectionStart;let f=!1;if(t.length<=e.length){for(let _=0;_<t.length&&_<e.length;_++){for(;i<e.length&&e[i]!=="X"&&e[i]!=="9";)a++,s++,i++;(jx(t.charCodeAt(_))&&e[i]==="9"||Wx(t.charCodeAt(_))&&e[i]==="X")&&(a>0&&(l=a,a=0),o+=t[_],i++)}const p=jx(t.charCodeAt(u-1))?"number":Wx(t.charCodeAt(u-1))?"letter":"something else",g=p!=="number"&&e[u-1]==="9",m=p!=="letter"&&e[u-1]==="X";(g||m||p==="something else")&&(f=!0);let b="",S=0;Math.abs(n.length-t.length)<=1&&(s=0);let C=u+s;for(let _=0;_<o.length;_++){for(;S<e.length&&e[S]!=="X"&&e[S]!=="9";)b+=e[S],S++;b+=o[_],S++}t.length<n.length?window.requestAnimationFrame(()=>{r.selectionStart=C,r.selectionEnd=C}):e[C-1]!=="X"&&e[C-1]!=="9"?window.requestAnimationFrame(()=>{r.selectionStart=C+l,r.selectionEnd=C+l}):(f&&(C-=1),window.requestAnimationFrame(()=>{r.selectionStart=C,r.selectionEnd=C}));const T=e.slice(S);return T.indexOf("X")===-1&&T.indexOf("9")===-1&&(b+=T),b}return window.requestAnimationFrame(()=>{r.selectionStart=u-1,r.selectionEnd=u-1}),n};function Jn(t,e){const r=Object.keys(t).filter(i=>e.includes(i)),o={...t};for(const i of NF)delete o[i];for(const i of r)delete o[i];return o}const _n=t=>t.split(/(?=[A-Z])|[.\-_\s]+/).map(n=>n.charAt(0).toUpperCase()+n.slice(1).toLowerCase()).filter(Boolean).join(" ");function FF(t,e,n=!1,r=""){let o="";if(e==null||e.length==0)return r;if(n){let i="";const s=e.toString().split(",");let a=0;t.forEach(l=>{s.includes(String(l.value).toString())&&(i+=l.label,a<s.length-1&&(i+=", "),a++)}),o=i}else{const i=t.find(s=>e==s.value);i!=null&&(o=i.label)}return o}function vl(t,e,n){return t.onClick?{onClick:()=>{t.onClick(),t.path&&e(t.path),t.externalLink&&window.open(t.externalLink,"_blank","noopener"),n&&n()}}:t.path?{component:eo.Link,to:t.path}:t.externalLink?{href:t.externalLink}:{}}function zo(t,e){return process.env.NODE_ENV==="production"?()=>null:function(...r){return t(...r)||e(...r)}}var yi=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Zn(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var _u={exports:{}},At={};/**
|
|
3
3
|
* @license React
|
|
4
4
|
* react-is.production.js
|
|
5
5
|
*
|
|
@@ -29,12 +29,12 @@
|
|
|
29
29
|
*
|
|
30
30
|
* This source code is licensed under the MIT license found in the
|
|
31
31
|
* LICENSE file in the root directory of this source tree.
|
|
32
|
-
*/var Jx;function VF(){return Jx||(Jx=1,process.env.NODE_ENV!=="production"&&function(){var t=typeof Symbol=="function"&&Symbol.for,e=t?Symbol.for("react.element"):60103,n=t?Symbol.for("react.portal"):60106,r=t?Symbol.for("react.fragment"):60107,o=t?Symbol.for("react.strict_mode"):60108,i=t?Symbol.for("react.profiler"):60114,s=t?Symbol.for("react.provider"):60109,a=t?Symbol.for("react.context"):60110,l=t?Symbol.for("react.async_mode"):60111,u=t?Symbol.for("react.concurrent_mode"):60111,f=t?Symbol.for("react.forward_ref"):60112,p=t?Symbol.for("react.suspense"):60113,g=t?Symbol.for("react.suspense_list"):60120,m=t?Symbol.for("react.memo"):60115,y=t?Symbol.for("react.lazy"):60116,b=t?Symbol.for("react.block"):60121,S=t?Symbol.for("react.fundamental"):60117,C=t?Symbol.for("react.responder"):60118,T=t?Symbol.for("react.scope"):60119;function _(
|
|
32
|
+
*/var Jx;function VF(){return Jx||(Jx=1,process.env.NODE_ENV!=="production"&&function(){var t=typeof Symbol=="function"&&Symbol.for,e=t?Symbol.for("react.element"):60103,n=t?Symbol.for("react.portal"):60106,r=t?Symbol.for("react.fragment"):60107,o=t?Symbol.for("react.strict_mode"):60108,i=t?Symbol.for("react.profiler"):60114,s=t?Symbol.for("react.provider"):60109,a=t?Symbol.for("react.context"):60110,l=t?Symbol.for("react.async_mode"):60111,u=t?Symbol.for("react.concurrent_mode"):60111,f=t?Symbol.for("react.forward_ref"):60112,p=t?Symbol.for("react.suspense"):60113,g=t?Symbol.for("react.suspense_list"):60120,m=t?Symbol.for("react.memo"):60115,y=t?Symbol.for("react.lazy"):60116,b=t?Symbol.for("react.block"):60121,S=t?Symbol.for("react.fundamental"):60117,C=t?Symbol.for("react.responder"):60118,T=t?Symbol.for("react.scope"):60119;function _(te){return typeof te=="string"||typeof te=="function"||te===r||te===u||te===i||te===o||te===p||te===g||typeof te=="object"&&te!==null&&(te.$$typeof===y||te.$$typeof===m||te.$$typeof===s||te.$$typeof===a||te.$$typeof===f||te.$$typeof===S||te.$$typeof===C||te.$$typeof===T||te.$$typeof===b)}function w(te){if(typeof te=="object"&&te!==null){var se=te.$$typeof;switch(se){case e:var ue=te.type;switch(ue){case l:case u:case r:case i:case o:case p:return ue;default:var ye=ue&&ue.$$typeof;switch(ye){case a:case f:case y:case m:case s:return ye;default:return se}}case n:return se}}}var E=l,O=u,L=a,P=s,$=e,M=f,A=r,N=y,z=m,V=n,B=i,R=o,q=p,U=!1;function G(te){return U||(U=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),Y(te)||w(te)===l}function Y(te){return w(te)===u}function Z(te){return w(te)===a}function fe(te){return w(te)===s}function pe(te){return typeof te=="object"&&te!==null&&te.$$typeof===e}function me(te){return w(te)===f}function re(te){return w(te)===r}function he(te){return w(te)===y}function le(te){return w(te)===m}function X(te){return w(te)===n}function W(te){return w(te)===i}function ee(te){return w(te)===o}function ce(te){return w(te)===p}kt.AsyncMode=E,kt.ConcurrentMode=O,kt.ContextConsumer=L,kt.ContextProvider=P,kt.Element=$,kt.ForwardRef=M,kt.Fragment=A,kt.Lazy=N,kt.Memo=z,kt.Portal=V,kt.Profiler=B,kt.StrictMode=R,kt.Suspense=q,kt.isAsyncMode=G,kt.isConcurrentMode=Y,kt.isContextConsumer=Z,kt.isContextProvider=fe,kt.isElement=pe,kt.isForwardRef=me,kt.isFragment=re,kt.isLazy=he,kt.isMemo=le,kt.isPortal=X,kt.isProfiler=W,kt.isStrictMode=ee,kt.isSuspense=ce,kt.isValidElementType=_,kt.typeOf=w}()),kt}var Zx;function Xx(){return Zx||(Zx=1,process.env.NODE_ENV==="production"?ku.exports=zF():ku.exports=VF()),ku.exports}/*
|
|
33
33
|
object-assign
|
|
34
34
|
(c) Sindre Sorhus
|
|
35
35
|
@license MIT
|
|
36
|
-
*/var wh,Qx;function HF(){if(Qx)return wh;Qx=1;var t=Object.getOwnPropertySymbols,e=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function r(i){if(i==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(i)}function o(){try{if(!Object.assign)return!1;var i=new String("abc");if(i[5]="de",Object.getOwnPropertyNames(i)[0]==="5")return!1;for(var s={},a=0;a<10;a++)s["_"+String.fromCharCode(a)]=a;var l=Object.getOwnPropertyNames(s).map(function(f){return s[f]});if(l.join("")!=="0123456789")return!1;var u={};return"abcdefghijklmnopqrst".split("").forEach(function(f){u[f]=f}),Object.keys(Object.assign({},u)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return wh=o()?Object.assign:function(i,s){for(var a,l=r(i),u,f=1;f<arguments.length;f++){a=Object(arguments[f]);for(var p in a)e.call(a,p)&&(l[p]=a[p]);if(t){u=t(a);for(var g=0;g<u.length;g++)n.call(a,u[g])&&(l[u[g]]=a[u[g]])}}return l},wh}var _h,eS;function Th(){if(eS)return _h;eS=1;var t="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return _h=t,_h}var kh,tS;function nS(){return tS||(tS=1,kh=Function.call.bind(Object.prototype.hasOwnProperty)),kh}var Eh,rS;function jF(){if(rS)return Eh;rS=1;var t=function(){};if(process.env.NODE_ENV!=="production"){var e=Th(),n={},r=nS();t=function(i){var s="Warning: "+i;typeof console<"u"&&console.error(s);try{throw new Error(s)}catch{}}}function o(i,s,a,l,u){if(process.env.NODE_ENV!=="production"){for(var f in i)if(r(i,f)){var p;try{if(typeof i[f]!="function"){var g=Error((l||"React class")+": "+a+" type `"+f+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof i[f]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw g.name="Invariant Violation",g}p=i[f](s,f,l,a,null,e)}catch(y){p=y}if(p&&!(p instanceof Error)&&t((l||"React class")+": type specification of "+a+" `"+f+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof p+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),p instanceof Error&&!(p.message in n)){n[p.message]=!0;var m=u?u():"";t("Failed "+a+" type: "+p.message+(m??""))}}}}return o.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(n={})},Eh=o,Eh}var Mh,oS;function WF(){if(oS)return Mh;oS=1;var t=Xx(),e=HF(),n=Th(),r=nS(),o=jF(),i=function(){};process.env.NODE_ENV!=="production"&&(i=function(a){var l="Warning: "+a;typeof console<"u"&&console.error(l);try{throw new Error(l)}catch{}});function s(){return null}return Mh=function(a,l){var u=typeof Symbol=="function"&&Symbol.iterator,f="@@iterator";function p(Y){var Z=Y&&(u&&Y[u]||Y[f]);if(typeof Z=="function")return Z}var g="<<anonymous>>",m={array:C("array"),bigint:C("bigint"),bool:C("boolean"),func:C("function"),number:C("number"),object:C("object"),string:C("string"),symbol:C("symbol"),any:T(),arrayOf:_,element:w(),elementType:E(),instanceOf:O,node:M(),objectOf:P,oneOf:L,oneOfType:$,shape:N,exact:
|
|
37
|
-
Valid keys: `+JSON.stringify(Object.keys(Y),null," "));var
|
|
36
|
+
*/var wh,Qx;function HF(){if(Qx)return wh;Qx=1;var t=Object.getOwnPropertySymbols,e=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function r(i){if(i==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(i)}function o(){try{if(!Object.assign)return!1;var i=new String("abc");if(i[5]="de",Object.getOwnPropertyNames(i)[0]==="5")return!1;for(var s={},a=0;a<10;a++)s["_"+String.fromCharCode(a)]=a;var l=Object.getOwnPropertyNames(s).map(function(f){return s[f]});if(l.join("")!=="0123456789")return!1;var u={};return"abcdefghijklmnopqrst".split("").forEach(function(f){u[f]=f}),Object.keys(Object.assign({},u)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return wh=o()?Object.assign:function(i,s){for(var a,l=r(i),u,f=1;f<arguments.length;f++){a=Object(arguments[f]);for(var p in a)e.call(a,p)&&(l[p]=a[p]);if(t){u=t(a);for(var g=0;g<u.length;g++)n.call(a,u[g])&&(l[u[g]]=a[u[g]])}}return l},wh}var _h,eS;function Th(){if(eS)return _h;eS=1;var t="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return _h=t,_h}var kh,tS;function nS(){return tS||(tS=1,kh=Function.call.bind(Object.prototype.hasOwnProperty)),kh}var Eh,rS;function jF(){if(rS)return Eh;rS=1;var t=function(){};if(process.env.NODE_ENV!=="production"){var e=Th(),n={},r=nS();t=function(i){var s="Warning: "+i;typeof console<"u"&&console.error(s);try{throw new Error(s)}catch{}}}function o(i,s,a,l,u){if(process.env.NODE_ENV!=="production"){for(var f in i)if(r(i,f)){var p;try{if(typeof i[f]!="function"){var g=Error((l||"React class")+": "+a+" type `"+f+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof i[f]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw g.name="Invariant Violation",g}p=i[f](s,f,l,a,null,e)}catch(y){p=y}if(p&&!(p instanceof Error)&&t((l||"React class")+": type specification of "+a+" `"+f+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof p+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),p instanceof Error&&!(p.message in n)){n[p.message]=!0;var m=u?u():"";t("Failed "+a+" type: "+p.message+(m??""))}}}}return o.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(n={})},Eh=o,Eh}var Mh,oS;function WF(){if(oS)return Mh;oS=1;var t=Xx(),e=HF(),n=Th(),r=nS(),o=jF(),i=function(){};process.env.NODE_ENV!=="production"&&(i=function(a){var l="Warning: "+a;typeof console<"u"&&console.error(l);try{throw new Error(l)}catch{}});function s(){return null}return Mh=function(a,l){var u=typeof Symbol=="function"&&Symbol.iterator,f="@@iterator";function p(Y){var Z=Y&&(u&&Y[u]||Y[f]);if(typeof Z=="function")return Z}var g="<<anonymous>>",m={array:C("array"),bigint:C("bigint"),bool:C("boolean"),func:C("function"),number:C("number"),object:C("object"),string:C("string"),symbol:C("symbol"),any:T(),arrayOf:_,element:w(),elementType:E(),instanceOf:O,node:M(),objectOf:P,oneOf:L,oneOfType:$,shape:N,exact:z};function y(Y,Z){return Y===Z?Y!==0||1/Y===1/Z:Y!==Y&&Z!==Z}function b(Y,Z){this.message=Y,this.data=Z&&typeof Z=="object"?Z:{},this.stack=""}b.prototype=Error.prototype;function S(Y){if(process.env.NODE_ENV!=="production")var Z={},fe=0;function pe(re,he,le,X,W,ee,ce){if(X=X||g,ee=ee||le,ce!==n){if(l){var te=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 te.name="Invariant Violation",te}else if(process.env.NODE_ENV!=="production"&&typeof console<"u"){var se=X+":"+le;!Z[se]&&fe<3&&(i("You are manually calling a React.PropTypes validation function for the `"+ee+"` prop on `"+X+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),Z[se]=!0,fe++)}}return he[le]==null?re?he[le]===null?new b("The "+W+" `"+ee+"` is marked as required "+("in `"+X+"`, but its value is `null`.")):new b("The "+W+" `"+ee+"` is marked as required in "+("`"+X+"`, but its value is `undefined`.")):null:Y(he,le,X,W,ee)}var me=pe.bind(null,!1);return me.isRequired=pe.bind(null,!0),me}function C(Y){function Z(fe,pe,me,re,he,le){var X=fe[pe],W=R(X);if(W!==Y){var ee=q(X);return new b("Invalid "+re+" `"+he+"` of type "+("`"+ee+"` supplied to `"+me+"`, expected ")+("`"+Y+"`."),{expectedType:Y})}return null}return S(Z)}function T(){return S(s)}function _(Y){function Z(fe,pe,me,re,he){if(typeof Y!="function")return new b("Property `"+he+"` of component `"+me+"` has invalid PropType notation inside arrayOf.");var le=fe[pe];if(!Array.isArray(le)){var X=R(le);return new b("Invalid "+re+" `"+he+"` of type "+("`"+X+"` supplied to `"+me+"`, expected an array."))}for(var W=0;W<le.length;W++){var ee=Y(le,W,me,re,he+"["+W+"]",n);if(ee instanceof Error)return ee}return null}return S(Z)}function w(){function Y(Z,fe,pe,me,re){var he=Z[fe];if(!a(he)){var le=R(he);return new b("Invalid "+me+" `"+re+"` of type "+("`"+le+"` supplied to `"+pe+"`, expected a single ReactElement."))}return null}return S(Y)}function E(){function Y(Z,fe,pe,me,re){var he=Z[fe];if(!t.isValidElementType(he)){var le=R(he);return new b("Invalid "+me+" `"+re+"` of type "+("`"+le+"` supplied to `"+pe+"`, expected a single ReactElement type."))}return null}return S(Y)}function O(Y){function Z(fe,pe,me,re,he){if(!(fe[pe]instanceof Y)){var le=Y.name||g,X=G(fe[pe]);return new b("Invalid "+re+" `"+he+"` of type "+("`"+X+"` supplied to `"+me+"`, expected ")+("instance of `"+le+"`."))}return null}return S(Z)}function L(Y){if(!Array.isArray(Y))return process.env.NODE_ENV!=="production"&&(arguments.length>1?i("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):i("Invalid argument supplied to oneOf, expected an array.")),s;function Z(fe,pe,me,re,he){for(var le=fe[pe],X=0;X<Y.length;X++)if(y(le,Y[X]))return null;var W=JSON.stringify(Y,function(ce,te){var se=q(te);return se==="symbol"?String(te):te});return new b("Invalid "+re+" `"+he+"` of value `"+String(le)+"` "+("supplied to `"+me+"`, expected one of "+W+"."))}return S(Z)}function P(Y){function Z(fe,pe,me,re,he){if(typeof Y!="function")return new b("Property `"+he+"` of component `"+me+"` has invalid PropType notation inside objectOf.");var le=fe[pe],X=R(le);if(X!=="object")return new b("Invalid "+re+" `"+he+"` of type "+("`"+X+"` supplied to `"+me+"`, expected an object."));for(var W in le)if(r(le,W)){var ee=Y(le,W,me,re,he+"."+W,n);if(ee instanceof Error)return ee}return null}return S(Z)}function $(Y){if(!Array.isArray(Y))return process.env.NODE_ENV!=="production"&&i("Invalid argument supplied to oneOfType, expected an instance of array."),s;for(var Z=0;Z<Y.length;Z++){var fe=Y[Z];if(typeof fe!="function")return i("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+U(fe)+" at index "+Z+"."),s}function pe(me,re,he,le,X){for(var W=[],ee=0;ee<Y.length;ee++){var ce=Y[ee],te=ce(me,re,he,le,X,n);if(te==null)return null;te.data&&r(te.data,"expectedType")&&W.push(te.data.expectedType)}var se=W.length>0?", expected one of type ["+W.join(", ")+"]":"";return new b("Invalid "+le+" `"+X+"` supplied to "+("`"+he+"`"+se+"."))}return S(pe)}function M(){function Y(Z,fe,pe,me,re){return V(Z[fe])?null:new b("Invalid "+me+" `"+re+"` supplied to "+("`"+pe+"`, expected a ReactNode."))}return S(Y)}function A(Y,Z,fe,pe,me){return new b((Y||"React class")+": "+Z+" type `"+fe+"."+pe+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+me+"`.")}function N(Y){function Z(fe,pe,me,re,he){var le=fe[pe],X=R(le);if(X!=="object")return new b("Invalid "+re+" `"+he+"` of type `"+X+"` "+("supplied to `"+me+"`, expected `object`."));for(var W in Y){var ee=Y[W];if(typeof ee!="function")return A(me,re,he,W,q(ee));var ce=ee(le,W,me,re,he+"."+W,n);if(ce)return ce}return null}return S(Z)}function z(Y){function Z(fe,pe,me,re,he){var le=fe[pe],X=R(le);if(X!=="object")return new b("Invalid "+re+" `"+he+"` of type `"+X+"` "+("supplied to `"+me+"`, expected `object`."));var W=e({},fe[pe],Y);for(var ee in W){var ce=Y[ee];if(r(Y,ee)&&typeof ce!="function")return A(me,re,he,ee,q(ce));if(!ce)return new b("Invalid "+re+" `"+he+"` key `"+ee+"` supplied to `"+me+"`.\nBad object: "+JSON.stringify(fe[pe],null," ")+`
|
|
37
|
+
Valid keys: `+JSON.stringify(Object.keys(Y),null," "));var te=ce(le,ee,me,re,he+"."+ee,n);if(te)return te}return null}return S(Z)}function V(Y){switch(typeof Y){case"number":case"string":case"undefined":return!0;case"boolean":return!Y;case"object":if(Array.isArray(Y))return Y.every(V);if(Y===null||a(Y))return!0;var Z=p(Y);if(Z){var fe=Z.call(Y),pe;if(Z!==Y.entries){for(;!(pe=fe.next()).done;)if(!V(pe.value))return!1}else for(;!(pe=fe.next()).done;){var me=pe.value;if(me&&!V(me[1]))return!1}}else return!1;return!0;default:return!1}}function B(Y,Z){return Y==="symbol"?!0:Z?Z["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&Z instanceof Symbol:!1}function R(Y){var Z=typeof Y;return Array.isArray(Y)?"array":Y instanceof RegExp?"object":B(Z,Y)?"symbol":Z}function q(Y){if(typeof Y>"u"||Y===null)return""+Y;var Z=R(Y);if(Z==="object"){if(Y instanceof Date)return"date";if(Y instanceof RegExp)return"regexp"}return Z}function U(Y){var Z=q(Y);switch(Z){case"array":case"object":return"an "+Z;case"boolean":case"date":case"regexp":return"a "+Z;default:return Z}}function G(Y){return!Y.constructor||!Y.constructor.name?g:Y.constructor.name}return m.checkPropTypes=o,m.resetWarningCache=o.resetWarningCache,m.PropTypes=m,m},Mh}var Oh,iS;function qF(){if(iS)return Oh;iS=1;var t=Th();function e(){}function n(){}return n.resetWarningCache=e,Oh=function(){function r(s,a,l,u,f,p){if(p!==t){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}}r.isRequired=r;function o(){return r}var i={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:e};return i.PropTypes=i,i},Oh}var sS;function UF(){if(sS)return Tu.exports;if(sS=1,process.env.NODE_ENV!=="production"){var t=Xx(),e=!0;Tu.exports=WF()(t.isElement,e)}else Tu.exports=qF()();return Tu.exports}var KF=UF();const c=Zn(KF);function YF(t){const{prototype:e={}}=t;return!!e.isReactComponent}function aS(t,e,n,r,o){const i=t[e],s=o||e;if(i==null||typeof window>"u")return null;let a;const l=i.type;return typeof l=="function"&&!YF(l)&&(a="Did you accidentally use a plain function component for an element instead?"),a!==void 0?new Error(`Invalid ${r} \`${s}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${a} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const xl=zo(c.element,aS);xl.isRequired=zo(c.element.isRequired,aS);function GF(t){const{prototype:e={}}=t;return!!e.isReactComponent}function JF(t,e,n,r,o){const i=t[e],s=o||e;if(i==null||typeof window>"u")return null;let a;return typeof i=="function"&&!GF(i)&&(a="Did you accidentally provide a plain function component instead?"),a!==void 0?new Error(`Invalid ${r} \`${s}\` supplied to \`${n}\`. Expected an element type that can hold a ref. ${a} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const Eu=zo(c.elementType,JF),ZF="exact-prop: ";function lS(t){return process.env.NODE_ENV==="production"?t:{...t,[ZF]:e=>{const n=Object.keys(e).filter(r=>!t.hasOwnProperty(r));return n.length>0?new Error(`The following props are not supported: ${n.map(r=>`\`${r}\``).join(", ")}. Please remove them.`):null}}}function bo(t,...e){const n=new URL(`https://mui.com/production-error/?code=${t}`);return e.forEach(r=>n.searchParams.append("args[]",r)),`Minified MUI error #${t}; visit ${n} for the full message.`}function cS(t,e=""){return t.displayName||t.name||e}function uS(t,e,n){const r=cS(e);return t.displayName||(r!==""?`${n}(${r})`:n)}function XF(t){if(t!=null){if(typeof t=="string")return t;if(typeof t=="function")return cS(t,"Component");if(typeof t=="object")switch(t.$$typeof){case cs.ForwardRef:return uS(t,t.render,"ForwardRef");case cs.Memo:return uS(t,t.type,"memo");default:return}}}function Vo(t,e,n,r,o){if(process.env.NODE_ENV==="production")return null;const i=t[e],s=o||e;return i==null?null:i&&i.nodeType!==1?new Error(`Invalid ${r} \`${s}\` supplied to \`${n}\`. Expected an HTMLElement.`):null}const mn=c.oneOfType([c.func,c.object]);function Ae(t){if(typeof t!="string")throw new Error(process.env.NODE_ENV!=="production"?"MUI: `capitalize(string)` expects a string argument.":bo(7));return t.charAt(0).toUpperCase()+t.slice(1)}function dS(...t){return t.reduce((e,n)=>n==null?e:function(...o){e.apply(this,o),n.apply(this,o)},()=>{})}function fS(t,e=166){let n;function r(...o){const i=()=>{t.apply(this,o)};clearTimeout(n),n=setTimeout(i,e)}return r.clear=()=>{clearTimeout(n)},r}function Sl(t,e){var n,r,o;return I.isValidElement(t)&&e.indexOf(t.type.muiName??((o=(r=(n=t.type)==null?void 0:n._payload)==null?void 0:r.value)==null?void 0:o.muiName))!==-1}function Vn(t){return t&&t.ownerDocument||document}function Ho(t){return Vn(t).defaultView||window}function Ah(t,e){typeof t=="function"?t(e):t&&(t.current=e)}const Tn=typeof window<"u"?I.useLayoutEffect:I.useEffect;let pS=0;function QF(t){const[e,n]=I.useState(t),r=t||e;return I.useEffect(()=>{e==null&&(pS+=1,n(`mui-${pS}`))},[e]),r}const hS={...I}.useId;function vo(t){if(hS!==void 0){const e=hS();return t??e}return QF(t)}function e$(t,e,n,r,o){if(process.env.NODE_ENV==="production")return null;const i=o||e;return typeof t[e]<"u"?new Error(`The prop \`${i}\` is not supported. Please remove it.`):null}function jo({controlled:t,default:e,name:n,state:r="value"}){const{current:o}=I.useRef(t!==void 0),[i,s]=I.useState(e),a=o?t:i;if(process.env.NODE_ENV!=="production"){I.useEffect(()=>{o!==(t!==void 0)&&console.error([`MUI: A component is changing the ${o?"":"un"}controlled ${r} state of ${n} to be ${o?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(`
|
|
38
38
|
`))},[r,n,t]);const{current:u}=I.useRef(e);I.useEffect(()=>{!o&&!Object.is(u,e)&&console.error([`MUI: A component is changing the default ${r} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join(`
|
|
39
39
|
`))},[JSON.stringify(e)])}const l=I.useCallback(u=>{o||s(u)},[]);return[a,l]}function Be(t){const e=I.useRef(t);return Tn(()=>{e.current=t}),I.useRef((...n)=>(0,e.current)(...n)).current}function Et(...t){return I.useMemo(()=>t.every(e=>e==null)?null:e=>{t.forEach(n=>{Ah(n,e)})},t)}const gS={};function mS(t,e){const n=I.useRef(gS);return n.current===gS&&(n.current=t(e)),n}const t$=[];function n$(t){I.useEffect(t,t$)}class Ih{constructor(){wu(this,"currentId",null);wu(this,"clear",()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)});wu(this,"disposeEffect",()=>this.clear)}static create(){return new Ih}start(e,n){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,n()},e)}}function yS(){const t=mS(Ih.create).current;return n$(t.disposeEffect),t}function bS(t){try{return t.matches(":focus-visible")}catch{process.env.NODE_ENV!=="production"&&!/jsdom/.test(window.navigator.userAgent)&&console.warn(["MUI: The `:focus-visible` pseudo class is not supported in this browser.","Some components rely on this feature to work properly."].join(`
|
|
40
40
|
`))}return!1}function vS(t=window){const e=t.document.documentElement.clientWidth;return t.innerWidth-e}const r$={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"absolute",whiteSpace:"nowrap",width:"1px"};function o$(t){const e=typeof t;switch(e){case"number":return Number.isNaN(t)?"NaN":Number.isFinite(t)?t!==Math.floor(t)?"float":"number":"Infinity";case"object":return t===null?"null":t.constructor.name;default:return e}}function xS(t,e,n,r){const o=t[e];if(o==null||!Number.isInteger(o)){const i=o$(o);return new RangeError(`Invalid ${r} \`${e}\` of type \`${i}\` supplied to \`${n}\`, expected \`integer\`.`)}return null}function SS(t,e,...n){return t[e]===void 0?null:xS(t,e,...n)}function Dh(){return null}SS.isRequired=xS,Dh.isRequired=Dh;const CS=process.env.NODE_ENV==="production"?Dh:SS;function Cl(t,e){const n={...e};for(const r in t)if(Object.prototype.hasOwnProperty.call(t,r)){const o=r;if(o==="components"||o==="slots")n[o]={...t[o],...n[o]};else if(o==="componentsProps"||o==="slotProps"){const i=t[o],s=e[o];if(!s)n[o]=i||{};else if(!i)n[o]=s;else{n[o]={...s};for(const a in i)if(Object.prototype.hasOwnProperty.call(i,a)){const l=a;n[o][l]=Cl(i[l],s[l])}}}else n[o]===void 0&&(n[o]=t[o])}return n}function Ue(t,e,n=void 0){const r={};for(const o in t){const i=t[o];let s="",a=!0;for(let l=0;l<i.length;l+=1){const u=i[l];u&&(s+=(a===!0?"":" ")+e(u),a=!1,n&&n[u]&&(s+=" "+n[u]))}r[o]=s}return r}const wS=t=>t,i$=(()=>{let t=wS;return{configure(e){t=e},generate(e){return t(e)},reset(){t=wS}}})(),s$={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function Ke(t,e,n="Mui"){const r=s$[e];return r?`${n}-${r}`:`${i$.generate(t)}-${e}`}function qe(t,e,n="Mui"){const r={};return e.forEach(o=>{r[o]=Ke(t,o,n)}),r}function a$(t,e=Number.MIN_SAFE_INTEGER,n=Number.MAX_SAFE_INTEGER){return Math.max(e,Math.min(t,n))}function l$(t){return typeof t=="string"}function _S(t,e,n){return t===void 0||l$(t)?e:{...e,ownerState:{...e.ownerState,...n}}}function TS(t){var e,n,r="";if(typeof t=="string"||typeof t=="number")r+=t;else if(typeof t=="object")if(Array.isArray(t)){var o=t.length;for(e=0;e<o;e++)t[e]&&(n=TS(t[e]))&&(r&&(r+=" "),r+=n)}else for(n in t)t[n]&&(r&&(r+=" "),r+=n);return r}function Le(){for(var t,e,n=0,r="",o=arguments.length;n<o;n++)(t=arguments[n])&&(e=TS(t))&&(r&&(r+=" "),r+=e);return r}function kS(t,e=[]){if(t===void 0)return{};const n={};return Object.keys(t).filter(r=>r.match(/^on[A-Z]/)&&typeof t[r]=="function"&&!e.includes(r)).forEach(r=>{n[r]=t[r]}),n}function ES(t){if(t===void 0)return{};const e={};return Object.keys(t).filter(n=>!(n.match(/^on[A-Z]/)&&typeof t[n]=="function")).forEach(n=>{e[n]=t[n]}),e}function MS(t){const{getSlotProps:e,additionalProps:n,externalSlotProps:r,externalForwardedProps:o,className:i}=t;if(!e){const m=Le(n==null?void 0:n.className,i,o==null?void 0:o.className,r==null?void 0:r.className),y={...n==null?void 0:n.style,...o==null?void 0:o.style,...r==null?void 0:r.style},b={...n,...o,...r};return m.length>0&&(b.className=m),Object.keys(y).length>0&&(b.style=y),{props:b,internalRef:void 0}}const s=kS({...o,...r}),a=ES(r),l=ES(o),u=e(s),f=Le(u==null?void 0:u.className,n==null?void 0:n.className,i,o==null?void 0:o.className,r==null?void 0:r.className),p={...u==null?void 0:u.style,...n==null?void 0:n.style,...o==null?void 0:o.style,...r==null?void 0:r.style},g={...u,...n,...l,...a};return f.length>0&&(g.className=f),Object.keys(p).length>0&&(g.style=p),{props:g,internalRef:u.ref}}function Mu(t,e,n){return typeof t=="function"?t(e,n):t}function wt(t){var p;const{elementType:e,externalSlotProps:n,ownerState:r,skipResolvingSlotProps:o=!1,...i}=t,s=o?{}:Mu(n,r),{props:a,internalRef:l}=MS({...i,externalSlotProps:s}),u=Et(l,s==null?void 0:s.ref,(p=t.additionalProps)==null?void 0:p.ref);return _S(e,{...a,ref:u},r)}function wl(t){var e;return parseInt(I.version,10)>=19?((e=t==null?void 0:t.props)==null?void 0:e.ref)||null:(t==null?void 0:t.ref)||null}function _l(t,e){return e?zn(t,e,{clone:!1}):t}const bi=process.env.NODE_ENV!=="production"?c.oneOfType([c.number,c.string,c.object,c.array]):{};function c$(t,e){if(!t.containerQueries)return e;const n=Object.keys(e).filter(r=>r.startsWith("@container")).sort((r,o)=>{var s,a;const i=/min-width:\s*([0-9.]+)/;return+(((s=r.match(i))==null?void 0:s[1])||0)-+(((a=o.match(i))==null?void 0:a[1])||0)});return n.length?n.reduce((r,o)=>{const i=e[o];return delete r[o],r[o]=i,r},{...e}):e}function u$(t,e){return e==="@"||e.startsWith("@")&&(t.some(n=>e.startsWith(`@${n}`))||!!e.match(/^@\d/))}function d$(t,e){const n=e.match(/^@([^/]+)?\/?(.+)?$/);if(!n){if(process.env.NODE_ENV!=="production")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The provided shorthand ${`(${e})`} is invalid. The format should be \`@<breakpoint | number>\` or \`@<breakpoint | number>/<container>\`.
|
|
@@ -48,10 +48,10 @@ For example, \`@sm\` or \`@600\` or \`@40rem/sidebar\`.`:bo(18,`(${e})`));return
|
|
|
48
48
|
* This source code is licensed under the MIT license found in the
|
|
49
49
|
* LICENSE file in the root directory of this source tree.
|
|
50
50
|
*/function d5(t,e){const n=AF(t,e);return process.env.NODE_ENV!=="production"?(...r)=>{const o=typeof t=="string"?`"${t}"`:"component";return r.length===0?console.error([`MUI: Seems like you called \`styled(${o})()\` without a \`style\` argument.`,'You must provide a `styles` argument: `styled("div")(styleYouForgotToPass)`.'].join(`
|
|
51
|
-
`)):r.some(i=>i===void 0)&&console.error(`MUI: the styled(${o})(...args) API requires all its args to be defined.`),n(...r)}:n}function f5(t,e){Array.isArray(t.__emotion_styles)&&(t.__emotion_styles=e(t.__emotion_styles))}const BS=[];function RS(t){return BS[0]=t,FS(BS)}const p5=t=>{const e=Object.keys(t).map(n=>({key:n,val:t[n]}))||[];return e.sort((n,r)=>n.val-r.val),e.reduce((n,r)=>({...n,[r.key]:r.val}),{})};function h5(t){const{values:e={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:n="px",step:r=5,...o}=t,i=p5(e),s=Object.keys(i);function a(g){return`@media (min-width:${typeof e[g]=="number"?e[g]:g}${n})`}function l(g){return`@media (max-width:${(typeof e[g]=="number"?e[g]:g)-r/100}${n})`}function u(g,m){const y=s.indexOf(m);return`@media (min-width:${typeof e[g]=="number"?e[g]:g}${n}) and (max-width:${(y!==-1&&typeof e[s[y]]=="number"?e[s[y]]:m)-r/100}${n})`}function f(g){return s.indexOf(g)+1<s.length?u(g,s[s.indexOf(g)+1]):a(g)}function p(g){const m=s.indexOf(g);return m===0?a(s[1]):m===s.length-1?l(s[m]):u(g,s[s.indexOf(g)+1]).replace("@media","@media not all and")}return{keys:s,values:i,up:a,down:l,between:u,only:f,not:p,unit:n,...o}}const g5={borderRadius:4};function zS(t=8,e=Ph({spacing:t})){if(t.mui)return t;const n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(i=>{const s=e(i);return typeof s=="number"?`${s}px`:s}).join(" "));return n.mui=!0,n}function m5(t,e){var r;const n=this;if(n.vars){if(!((r=n.colorSchemes)!=null&&r[t])||typeof n.getColorSchemeSelector!="function")return{};let o=n.getColorSchemeSelector(t);return o==="&"?e:((o.includes("data-")||o.includes("."))&&(o=`*:where(${o.replace(/\s*&$/,"")}) &`),{[o]:e})}return n.palette.mode===t?e:{}}function Fh(t={},...e){const{breakpoints:n={},palette:r={},spacing:o,shape:i={},...s}=t,a=h5(n),l=zS(o);let u=zn({breakpoints:a,direction:"ltr",components:{},palette:{mode:"light",...r},spacing:l,shape:{...g5,...i}},s);return u=f$(u),u.applyStyles=m5,u=e.reduce((f,p)=>zn(f,p),u),u.unstable_sxConfig={...El,...s==null?void 0:s.unstable_sxConfig},u.unstable_sx=function(p){return oa({sx:p,theme:this})},u}function y5(t){return Object.keys(t).length===0}function VS(t=null){const e=I.useContext(to.ThemeContext);return!e||y5(e)?t:e}const b5=Fh();function $h(t=b5){return VS(t)}function HS({styles:t,themeId:e,defaultTheme:n={}}){const r=$h(n),o=typeof t=="function"?t(e&&r[e]||r):t;return v.jsx($S,{styles:o})}process.env.NODE_ENV!=="production"&&(HS.propTypes={defaultTheme:c.object,styles:c.oneOfType([c.array,c.func,c.number,c.object,c.string,c.bool]),themeId:c.string});function jS(t){const{variants:e,...n}=t,r={variants:e,style:RS(n),isProcessed:!0};return r.style===n||e&&e.forEach(o=>{typeof o.style!="function"&&(o.style=RS(o.style))}),r}const v5=Fh();function zu(t){return t!=="ownerState"&&t!=="theme"&&t!=="sx"&&t!=="as"}function x5(t){return t?(e,n)=>n[t]:null}function S5(t,e,n){t.theme=T5(t.theme)?n:t.theme[e]||t.theme}function Vu(t,e){const n=typeof e=="function"?e(t):e;if(Array.isArray(n))return n.flatMap(r=>Vu(t,r));if(Array.isArray(n==null?void 0:n.variants)){let r;if(n.isProcessed)r=n.style;else{const{variants:o,...i}=n;r=i}return WS(t,n.variants,[r])}return n!=null&&n.isProcessed?n.style:n}function WS(t,e,n=[]){var o;let r;e:for(let i=0;i<e.length;i+=1){const s=e[i];if(typeof s.props=="function"){if(r??(r={...t,...t.ownerState,ownerState:t.ownerState}),!s.props(r))continue}else for(const a in s.props)if(t[a]!==s.props[a]&&((o=t.ownerState)==null?void 0:o[a])!==s.props[a])continue e;typeof s.style=="function"?(r??(r={...t,...t.ownerState,ownerState:t.ownerState}),n.push(s.style(r))):n.push(s.style)}return n}function C5(t={}){const{themeId:e,defaultTheme:n=v5,rootShouldForwardProp:r=zu,slotShouldForwardProp:o=zu}=t;function i(a){S5(a,e,n)}return(a,l={})=>{f5(a,E=>E.filter(O=>O!==oa));const{name:u,slot:f,skipVariantsResolver:p,skipSx:g,overridesResolver:m=x5(qS(f)),...y}=l,b=p!==void 0?p:f&&f!=="Root"&&f!=="root"||!1,S=g||!1;let C=zu;f==="Root"||f==="root"?C=r:f?C=o:k5(a)&&(C=void 0);const T=d5(a,{shouldForwardProp:C,label:_5(u,f),...y}),_=E=>{if(typeof E=="function"&&E.__emotion_real!==E)return function(L){return Vu(L,E)};if(yo(E)){const O=jS(E);return O.variants?function(P){return Vu(P,O)}:O.style}return E},w=(...E)=>{const O=[],L=E.map(_),P=[];if(O.push(i),u&&m&&P.push(function(N){var
|
|
51
|
+
`)):r.some(i=>i===void 0)&&console.error(`MUI: the styled(${o})(...args) API requires all its args to be defined.`),n(...r)}:n}function f5(t,e){Array.isArray(t.__emotion_styles)&&(t.__emotion_styles=e(t.__emotion_styles))}const BS=[];function RS(t){return BS[0]=t,FS(BS)}const p5=t=>{const e=Object.keys(t).map(n=>({key:n,val:t[n]}))||[];return e.sort((n,r)=>n.val-r.val),e.reduce((n,r)=>({...n,[r.key]:r.val}),{})};function h5(t){const{values:e={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:n="px",step:r=5,...o}=t,i=p5(e),s=Object.keys(i);function a(g){return`@media (min-width:${typeof e[g]=="number"?e[g]:g}${n})`}function l(g){return`@media (max-width:${(typeof e[g]=="number"?e[g]:g)-r/100}${n})`}function u(g,m){const y=s.indexOf(m);return`@media (min-width:${typeof e[g]=="number"?e[g]:g}${n}) and (max-width:${(y!==-1&&typeof e[s[y]]=="number"?e[s[y]]:m)-r/100}${n})`}function f(g){return s.indexOf(g)+1<s.length?u(g,s[s.indexOf(g)+1]):a(g)}function p(g){const m=s.indexOf(g);return m===0?a(s[1]):m===s.length-1?l(s[m]):u(g,s[s.indexOf(g)+1]).replace("@media","@media not all and")}return{keys:s,values:i,up:a,down:l,between:u,only:f,not:p,unit:n,...o}}const g5={borderRadius:4};function zS(t=8,e=Ph({spacing:t})){if(t.mui)return t;const n=(...r)=>(process.env.NODE_ENV!=="production"&&(r.length<=4||console.error(`MUI: Too many arguments provided, expected between 0 and 4, got ${r.length}`)),(r.length===0?[1]:r).map(i=>{const s=e(i);return typeof s=="number"?`${s}px`:s}).join(" "));return n.mui=!0,n}function m5(t,e){var r;const n=this;if(n.vars){if(!((r=n.colorSchemes)!=null&&r[t])||typeof n.getColorSchemeSelector!="function")return{};let o=n.getColorSchemeSelector(t);return o==="&"?e:((o.includes("data-")||o.includes("."))&&(o=`*:where(${o.replace(/\s*&$/,"")}) &`),{[o]:e})}return n.palette.mode===t?e:{}}function Fh(t={},...e){const{breakpoints:n={},palette:r={},spacing:o,shape:i={},...s}=t,a=h5(n),l=zS(o);let u=zn({breakpoints:a,direction:"ltr",components:{},palette:{mode:"light",...r},spacing:l,shape:{...g5,...i}},s);return u=f$(u),u.applyStyles=m5,u=e.reduce((f,p)=>zn(f,p),u),u.unstable_sxConfig={...El,...s==null?void 0:s.unstable_sxConfig},u.unstable_sx=function(p){return oa({sx:p,theme:this})},u}function y5(t){return Object.keys(t).length===0}function VS(t=null){const e=I.useContext(to.ThemeContext);return!e||y5(e)?t:e}const b5=Fh();function $h(t=b5){return VS(t)}function HS({styles:t,themeId:e,defaultTheme:n={}}){const r=$h(n),o=typeof t=="function"?t(e&&r[e]||r):t;return v.jsx($S,{styles:o})}process.env.NODE_ENV!=="production"&&(HS.propTypes={defaultTheme:c.object,styles:c.oneOfType([c.array,c.func,c.number,c.object,c.string,c.bool]),themeId:c.string});function jS(t){const{variants:e,...n}=t,r={variants:e,style:RS(n),isProcessed:!0};return r.style===n||e&&e.forEach(o=>{typeof o.style!="function"&&(o.style=RS(o.style))}),r}const v5=Fh();function zu(t){return t!=="ownerState"&&t!=="theme"&&t!=="sx"&&t!=="as"}function x5(t){return t?(e,n)=>n[t]:null}function S5(t,e,n){t.theme=T5(t.theme)?n:t.theme[e]||t.theme}function Vu(t,e){const n=typeof e=="function"?e(t):e;if(Array.isArray(n))return n.flatMap(r=>Vu(t,r));if(Array.isArray(n==null?void 0:n.variants)){let r;if(n.isProcessed)r=n.style;else{const{variants:o,...i}=n;r=i}return WS(t,n.variants,[r])}return n!=null&&n.isProcessed?n.style:n}function WS(t,e,n=[]){var o;let r;e:for(let i=0;i<e.length;i+=1){const s=e[i];if(typeof s.props=="function"){if(r??(r={...t,...t.ownerState,ownerState:t.ownerState}),!s.props(r))continue}else for(const a in s.props)if(t[a]!==s.props[a]&&((o=t.ownerState)==null?void 0:o[a])!==s.props[a])continue e;typeof s.style=="function"?(r??(r={...t,...t.ownerState,ownerState:t.ownerState}),n.push(s.style(r))):n.push(s.style)}return n}function C5(t={}){const{themeId:e,defaultTheme:n=v5,rootShouldForwardProp:r=zu,slotShouldForwardProp:o=zu}=t;function i(a){S5(a,e,n)}return(a,l={})=>{f5(a,E=>E.filter(O=>O!==oa));const{name:u,slot:f,skipVariantsResolver:p,skipSx:g,overridesResolver:m=x5(qS(f)),...y}=l,b=p!==void 0?p:f&&f!=="Root"&&f!=="root"||!1,S=g||!1;let C=zu;f==="Root"||f==="root"?C=r:f?C=o:k5(a)&&(C=void 0);const T=d5(a,{shouldForwardProp:C,label:_5(u,f),...y}),_=E=>{if(typeof E=="function"&&E.__emotion_real!==E)return function(L){return Vu(L,E)};if(yo(E)){const O=jS(E);return O.variants?function(P){return Vu(P,O)}:O.style}return E},w=(...E)=>{const O=[],L=E.map(_),P=[];if(O.push(i),u&&m&&P.push(function(N){var R,q;const V=(q=(R=N.theme.components)==null?void 0:R[u])==null?void 0:q.styleOverrides;if(!V)return null;const B={};for(const U in V)B[U]=Vu(N,V[U]);return m(N,B)}),u&&!b&&P.push(function(N){var B,R;const z=N.theme,V=(R=(B=z==null?void 0:z.components)==null?void 0:B[u])==null?void 0:R.variants;return V?WS(N,V):null}),S||P.push(oa),Array.isArray(L[0])){const A=L.shift(),N=new Array(O.length).fill(""),z=new Array(P.length).fill("");let V;V=[...N,...A,...z],V.raw=[...N,...A.raw,...z],O.unshift(V)}const $=[...O,...L,...P],M=T(...$);return a.muiName&&(M.muiName=a.muiName),process.env.NODE_ENV!=="production"&&(M.displayName=w5(u,f,a)),M};return T.withConfig&&(w.withConfig=T.withConfig),w}}function w5(t,e,n){return t?`${t}${Ae(e||"")}`:`Styled(${XF(n)})`}function _5(t,e){let n;return process.env.NODE_ENV!=="production"&&t&&(n=`${t}-${qS(e||"Root")}`),n}function T5(t){for(const e in t)return!1;return!0}function k5(t){return typeof t=="string"&&t.charCodeAt(0)>96}function qS(t){return t&&t.charAt(0).toLowerCase()+t.slice(1)}function US(t){const{theme:e,name:n,props:r}=t;return!e||!e.components||!e.components[n]||!e.components[n].defaultProps?r:Cl(e.components[n].defaultProps,r)}function E5({props:t,name:e,defaultTheme:n,themeId:r}){let o=$h(n);return r&&(o=o[r]||o),US({theme:o,name:e,props:t})}function M5(t,e,n,r,o){const[i,s]=I.useState(()=>o&&n?n(t).matches:r?r(t).matches:e);return Tn(()=>{if(!n)return;const a=n(t),l=()=>{s(a.matches)};return l(),a.addEventListener("change",l),()=>{a.removeEventListener("change",l)}},[t,n]),i}const KS={...I}.useSyncExternalStore;function O5(t,e,n,r,o){const i=I.useCallback(()=>e,[e]),s=I.useMemo(()=>{if(o&&n)return()=>n(t).matches;if(r!==null){const{matches:f}=r(t);return()=>f}return i},[i,t,r,o,n]),[a,l]=I.useMemo(()=>{if(n===null)return[i,()=>()=>{}];const f=n(t);return[()=>f.matches,p=>(f.addEventListener("change",p),()=>{f.removeEventListener("change",p)})]},[i,n,t]);return KS(l,a,s)}function A5(t={}){const{themeId:e}=t;return function(r,o={}){let i=VS();i&&e&&(i=i[e]||i);const s=typeof window<"u"&&typeof window.matchMedia<"u",{defaultMatches:a=!1,matchMedia:l=s?window.matchMedia:null,ssrMatchMedia:u=null,noSsr:f=!1}=US({name:"MuiUseMediaQuery",props:o,theme:i});process.env.NODE_ENV!=="production"&&typeof r=="function"&&i===null&&console.error(["MUI: The `query` argument provided is invalid.","You are providing a function without a theme in the context.","One of the parent elements needs to use a ThemeProvider."].join(`
|
|
52
52
|
`));let p=typeof r=="function"?r(i):r;p=p.replace(/^@media( ?)/m,"");const m=(KS!==void 0?O5:M5)(p,a,l,u,f);return process.env.NODE_ENV!=="production"&&I.useDebugValue({query:p,match:m}),m}}function Bh(t,e=0,n=1){return process.env.NODE_ENV!=="production"&&(t<e||t>n)&&console.error(`MUI: The value provided ${t} is out of range [${e}, ${n}].`),a$(t,e,n)}function I5(t){t=t.slice(1);const e=new RegExp(`.{1,${t.length>=6?2:1}}`,"g");let n=t.match(e);return n&&n[0].length===1&&(n=n.map(r=>r+r)),process.env.NODE_ENV!=="production"&&t.length!==t.trim().length&&console.error(`MUI: The color: "${t}" is invalid. Make sure the color input doesn't contain leading/trailing space.`),n?`rgb${n.length===4?"a":""}(${n.map((r,o)=>o<3?parseInt(r,16):Math.round(parseInt(r,16)/255*1e3)/1e3).join(", ")})`:""}function xi(t){if(t.type)return t;if(t.charAt(0)==="#")return xi(I5(t));const e=t.indexOf("("),n=t.substring(0,e);if(!["rgb","rgba","hsl","hsla","color"].includes(n))throw new Error(process.env.NODE_ENV!=="production"?`MUI: Unsupported \`${t}\` color.
|
|
53
53
|
The following formats are supported: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().`:bo(9,t));let r=t.substring(e+1,t.length-1),o;if(n==="color"){if(r=r.split(" "),o=r.shift(),r.length===4&&r[3].charAt(0)==="/"&&(r[3]=r[3].slice(1)),!["srgb","display-p3","a98-rgb","prophoto-rgb","rec-2020"].includes(o))throw new Error(process.env.NODE_ENV!=="production"?`MUI: unsupported \`${o}\` color space.
|
|
54
|
-
The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:bo(10,o))}else r=r.split(",");return r=r.map(i=>parseFloat(i)),{type:n,values:r,colorSpace:o}}const D5=t=>{const e=xi(t);return e.values.slice(0,3).map((n,r)=>e.type.includes("hsl")&&r!==0?`${n}%`:n).join(" ")},Ml=(t,e)=>{try{return D5(t)}catch{return e&&process.env.NODE_ENV!=="production"&&console.warn(e),t}};function Hu(t){const{type:e,colorSpace:n}=t;let{values:r}=t;return e.includes("rgb")?r=r.map((o,i)=>i<3?parseInt(o,10):o):e.includes("hsl")&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),e.includes("color")?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${e}(${r})`}function YS(t){t=xi(t);const{values:e}=t,n=e[0],r=e[1]/100,o=e[2]/100,i=r*Math.min(o,1-o),s=(u,f=(u+n/30)%12)=>o-i*Math.max(Math.min(f-3,9-f,1),-1);let a="rgb";const l=[Math.round(s(0)*255),Math.round(s(8)*255),Math.round(s(4)*255)];return t.type==="hsla"&&(a+="a",l.push(e[3])),Hu({type:a,values:l})}function Rh(t){t=xi(t);let e=t.type==="hsl"||t.type==="hsla"?xi(YS(t)).values:t.values;return e=e.map(n=>(t.type!=="color"&&(n/=255),n<=.03928?n/12.92:((n+.055)/1.055)**2.4)),Number((.2126*e[0]+.7152*e[1]+.0722*e[2]).toFixed(3))}function GS(t,e){const n=Rh(t),r=Rh(e);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function Rt(t,e){return t=xi(t),e=Bh(e),(t.type==="rgb"||t.type==="hsl")&&(t.type+="a"),t.type==="color"?t.values[3]=`/${e}`:t.values[3]=e,Hu(t)}function ju(t,e,n){try{return Rt(t,e)}catch{return t}}function ia(t,e){if(t=xi(t),e=Bh(e),t.type.includes("hsl"))t.values[2]*=1-e;else if(t.type.includes("rgb")||t.type.includes("color"))for(let n=0;n<3;n+=1)t.values[n]*=1-e;return Hu(t)}function Nt(t,e,n){try{return ia(t,e)}catch{return t}}function Ol(t,e){if(t=xi(t),e=Bh(e),t.type.includes("hsl"))t.values[2]+=(100-t.values[2])*e;else if(t.type.includes("rgb"))for(let n=0;n<3;n+=1)t.values[n]+=(255-t.values[n])*e;else if(t.type.includes("color"))for(let n=0;n<3;n+=1)t.values[n]+=(1-t.values[n])*e;return Hu(t)}function Lt(t,e,n){try{return Ol(t,e)}catch{return t}}function P5(t,e=.15){return Rh(t)>.5?ia(t,e):Ol(t,e)}function Wu(t,e,n){try{return P5(t,e)}catch{return t}}const N5=I.createContext();process.env.NODE_ENV!=="production"&&(c.node,c.bool);const no=()=>I.useContext(N5)??!1,L5=I.createContext(void 0);process.env.NODE_ENV!=="production"&&(c.node,c.object);function F5(t){const{theme:e,name:n,props:r}=t;if(!e||!e.components||!e.components[n])return r;const o=e.components[n];return o.defaultProps?Cl(o.defaultProps,r):!o.styleOverrides&&!o.variants?Cl(o,r):r}function $5({props:t,name:e}){const n=I.useContext(L5);return F5({props:t,name:e,theme:{components:n}})}const JS={theme:void 0};function B5(t){let e,n;return function(o){let i=e;return(i===void 0||o.theme!==n)&&(JS.theme=o.theme,i=jS(t(JS)),e=i,n=o.theme),i}}function R5(t=""){function e(...r){if(!r.length)return"";const o=r[0];return typeof o=="string"&&!o.match(/(#|\(|\)|(-?(\d*\.)?\d+)(px|em|%|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc))|^(-?(\d*\.)?\d+)$|(\d+ \d+ \d+)/)?`, var(--${t?`${t}-`:""}${o}${e(...r.slice(1))})`:`, ${o}`}return(r,...o)=>`var(--${t?`${t}-`:""}${r}${e(...o)})`}const ZS=(t,e,n,r=[])=>{let o=t;e.forEach((i,s)=>{s===e.length-1?Array.isArray(o)?o[Number(i)]=n:o&&typeof o=="object"&&(o[i]=n):o&&typeof o=="object"&&(o[i]||(o[i]=r.includes(i)?[]:{}),o=o[i])})},z5=(t,e,n)=>{function r(o,i=[],s=[]){Object.entries(o).forEach(([a,l])=>{(!n||!n([...i,a]))&&l!=null&&(typeof l=="object"&&Object.keys(l).length>0?r(l,[...i,a],Array.isArray(l)?[...s,a]:s):e([...i,a],l,s))})}r(t)},V5=(t,e)=>typeof e=="number"?["lineHeight","fontWeight","opacity","zIndex"].some(r=>t.includes(r))||t[t.length-1].toLowerCase().includes("opacity")?e:`${e}px`:e;function zh(t,e){const{prefix:n,shouldSkipGeneratingVar:r}=e||{},o={},i={},s={};return z5(t,(a,l,u)=>{if((typeof l=="string"||typeof l=="number")&&(!r||!r(a,l))){const f=`--${n?`${n}-`:""}${a.join("-")}`,p=V5(a,l);Object.assign(o,{[f]:p}),ZS(i,a,`var(${f})`,u),ZS(s,a,`var(${f}, ${p})`,u)}},a=>a[0]==="vars"),{css:o,vars:i,varsWithDefaults:s}}function H5(t,e={}){const{getSelector:n=S,disableCssColorScheme:r,colorSchemeSelector:o}=e,{colorSchemes:i={},components:s,defaultColorScheme:a="light",...l}=t,{vars:u,css:f,varsWithDefaults:p}=zh(l,e);let g=p;const m={},{[a]:y,...b}=i;if(Object.entries(b||{}).forEach(([_,w])=>{const{vars:E,css:O,varsWithDefaults:L}=zh(w,e);g=zn(g,L),m[_]={css:O,vars:E}}),y){const{css:_,vars:w,varsWithDefaults:E}=zh(y,e);g=zn(g,E),m[a]={css:_,vars:w}}function S(_,w){var O,L;let E=o;if(o==="class"&&(E=".%s"),o==="data"&&(E="[data-%s]"),o!=null&&o.startsWith("data-")&&!o.includes("%s")&&(E=`[${o}="%s"]`),_){if(E==="media")return t.defaultColorScheme===_?":root":{[`@media (prefers-color-scheme: ${((L=(O=i[_])==null?void 0:O.palette)==null?void 0:L.mode)||_})`]:{":root":w}};if(E)return t.defaultColorScheme===_?`:root, ${E.replace("%s",String(_))}`:E.replace("%s",String(_))}return":root"}return{vars:g,generateThemeVars:()=>{let _={...u};return Object.entries(m).forEach(([,{vars:w}])=>{_=zn(_,w)}),_},generateStyleSheets:()=>{var P,$;const _=[],w=t.defaultColorScheme||"light";function E(M,A){Object.keys(A).length&&_.push(typeof M=="string"?{[M]:{...A}}:M)}E(n(void 0,{...f}),f);const{[w]:O,...L}=m;if(O){const{css:M}=O,A=($=(P=i[w])==null?void 0:P.palette)==null?void 0:$.mode,N=!r&&A?{colorScheme:A,...M}:{...M};E(n(w,{...N}),N)}return Object.entries(L).forEach(([M,{css:A}])=>{var
|
|
54
|
+
The following color spaces are supported: srgb, display-p3, a98-rgb, prophoto-rgb, rec-2020.`:bo(10,o))}else r=r.split(",");return r=r.map(i=>parseFloat(i)),{type:n,values:r,colorSpace:o}}const D5=t=>{const e=xi(t);return e.values.slice(0,3).map((n,r)=>e.type.includes("hsl")&&r!==0?`${n}%`:n).join(" ")},Ml=(t,e)=>{try{return D5(t)}catch{return e&&process.env.NODE_ENV!=="production"&&console.warn(e),t}};function Hu(t){const{type:e,colorSpace:n}=t;let{values:r}=t;return e.includes("rgb")?r=r.map((o,i)=>i<3?parseInt(o,10):o):e.includes("hsl")&&(r[1]=`${r[1]}%`,r[2]=`${r[2]}%`),e.includes("color")?r=`${n} ${r.join(" ")}`:r=`${r.join(", ")}`,`${e}(${r})`}function YS(t){t=xi(t);const{values:e}=t,n=e[0],r=e[1]/100,o=e[2]/100,i=r*Math.min(o,1-o),s=(u,f=(u+n/30)%12)=>o-i*Math.max(Math.min(f-3,9-f,1),-1);let a="rgb";const l=[Math.round(s(0)*255),Math.round(s(8)*255),Math.round(s(4)*255)];return t.type==="hsla"&&(a+="a",l.push(e[3])),Hu({type:a,values:l})}function Rh(t){t=xi(t);let e=t.type==="hsl"||t.type==="hsla"?xi(YS(t)).values:t.values;return e=e.map(n=>(t.type!=="color"&&(n/=255),n<=.03928?n/12.92:((n+.055)/1.055)**2.4)),Number((.2126*e[0]+.7152*e[1]+.0722*e[2]).toFixed(3))}function GS(t,e){const n=Rh(t),r=Rh(e);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)}function Rt(t,e){return t=xi(t),e=Bh(e),(t.type==="rgb"||t.type==="hsl")&&(t.type+="a"),t.type==="color"?t.values[3]=`/${e}`:t.values[3]=e,Hu(t)}function ju(t,e,n){try{return Rt(t,e)}catch{return t}}function ia(t,e){if(t=xi(t),e=Bh(e),t.type.includes("hsl"))t.values[2]*=1-e;else if(t.type.includes("rgb")||t.type.includes("color"))for(let n=0;n<3;n+=1)t.values[n]*=1-e;return Hu(t)}function Nt(t,e,n){try{return ia(t,e)}catch{return t}}function Ol(t,e){if(t=xi(t),e=Bh(e),t.type.includes("hsl"))t.values[2]+=(100-t.values[2])*e;else if(t.type.includes("rgb"))for(let n=0;n<3;n+=1)t.values[n]+=(255-t.values[n])*e;else if(t.type.includes("color"))for(let n=0;n<3;n+=1)t.values[n]+=(1-t.values[n])*e;return Hu(t)}function Lt(t,e,n){try{return Ol(t,e)}catch{return t}}function P5(t,e=.15){return Rh(t)>.5?ia(t,e):Ol(t,e)}function Wu(t,e,n){try{return P5(t,e)}catch{return t}}const N5=I.createContext();process.env.NODE_ENV!=="production"&&(c.node,c.bool);const no=()=>I.useContext(N5)??!1,L5=I.createContext(void 0);process.env.NODE_ENV!=="production"&&(c.node,c.object);function F5(t){const{theme:e,name:n,props:r}=t;if(!e||!e.components||!e.components[n])return r;const o=e.components[n];return o.defaultProps?Cl(o.defaultProps,r):!o.styleOverrides&&!o.variants?Cl(o,r):r}function $5({props:t,name:e}){const n=I.useContext(L5);return F5({props:t,name:e,theme:{components:n}})}const JS={theme:void 0};function B5(t){let e,n;return function(o){let i=e;return(i===void 0||o.theme!==n)&&(JS.theme=o.theme,i=jS(t(JS)),e=i,n=o.theme),i}}function R5(t=""){function e(...r){if(!r.length)return"";const o=r[0];return typeof o=="string"&&!o.match(/(#|\(|\)|(-?(\d*\.)?\d+)(px|em|%|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc))|^(-?(\d*\.)?\d+)$|(\d+ \d+ \d+)/)?`, var(--${t?`${t}-`:""}${o}${e(...r.slice(1))})`:`, ${o}`}return(r,...o)=>`var(--${t?`${t}-`:""}${r}${e(...o)})`}const ZS=(t,e,n,r=[])=>{let o=t;e.forEach((i,s)=>{s===e.length-1?Array.isArray(o)?o[Number(i)]=n:o&&typeof o=="object"&&(o[i]=n):o&&typeof o=="object"&&(o[i]||(o[i]=r.includes(i)?[]:{}),o=o[i])})},z5=(t,e,n)=>{function r(o,i=[],s=[]){Object.entries(o).forEach(([a,l])=>{(!n||!n([...i,a]))&&l!=null&&(typeof l=="object"&&Object.keys(l).length>0?r(l,[...i,a],Array.isArray(l)?[...s,a]:s):e([...i,a],l,s))})}r(t)},V5=(t,e)=>typeof e=="number"?["lineHeight","fontWeight","opacity","zIndex"].some(r=>t.includes(r))||t[t.length-1].toLowerCase().includes("opacity")?e:`${e}px`:e;function zh(t,e){const{prefix:n,shouldSkipGeneratingVar:r}=e||{},o={},i={},s={};return z5(t,(a,l,u)=>{if((typeof l=="string"||typeof l=="number")&&(!r||!r(a,l))){const f=`--${n?`${n}-`:""}${a.join("-")}`,p=V5(a,l);Object.assign(o,{[f]:p}),ZS(i,a,`var(${f})`,u),ZS(s,a,`var(${f}, ${p})`,u)}},a=>a[0]==="vars"),{css:o,vars:i,varsWithDefaults:s}}function H5(t,e={}){const{getSelector:n=S,disableCssColorScheme:r,colorSchemeSelector:o}=e,{colorSchemes:i={},components:s,defaultColorScheme:a="light",...l}=t,{vars:u,css:f,varsWithDefaults:p}=zh(l,e);let g=p;const m={},{[a]:y,...b}=i;if(Object.entries(b||{}).forEach(([_,w])=>{const{vars:E,css:O,varsWithDefaults:L}=zh(w,e);g=zn(g,L),m[_]={css:O,vars:E}}),y){const{css:_,vars:w,varsWithDefaults:E}=zh(y,e);g=zn(g,E),m[a]={css:_,vars:w}}function S(_,w){var O,L;let E=o;if(o==="class"&&(E=".%s"),o==="data"&&(E="[data-%s]"),o!=null&&o.startsWith("data-")&&!o.includes("%s")&&(E=`[${o}="%s"]`),_){if(E==="media")return t.defaultColorScheme===_?":root":{[`@media (prefers-color-scheme: ${((L=(O=i[_])==null?void 0:O.palette)==null?void 0:L.mode)||_})`]:{":root":w}};if(E)return t.defaultColorScheme===_?`:root, ${E.replace("%s",String(_))}`:E.replace("%s",String(_))}return":root"}return{vars:g,generateThemeVars:()=>{let _={...u};return Object.entries(m).forEach(([,{vars:w}])=>{_=zn(_,w)}),_},generateStyleSheets:()=>{var P,$;const _=[],w=t.defaultColorScheme||"light";function E(M,A){Object.keys(A).length&&_.push(typeof M=="string"?{[M]:{...A}}:M)}E(n(void 0,{...f}),f);const{[w]:O,...L}=m;if(O){const{css:M}=O,A=($=(P=i[w])==null?void 0:P.palette)==null?void 0:$.mode,N=!r&&A?{colorScheme:A,...M}:{...M};E(n(w,{...N}),N)}return Object.entries(L).forEach(([M,{css:A}])=>{var V,B;const N=(B=(V=i[M])==null?void 0:V.palette)==null?void 0:B.mode,z=!r&&N?{colorScheme:N,...A}:{...A};E(n(M,{...z}),z)}),_}}}function j5(t){return function(n){return t==="media"?(process.env.NODE_ENV!=="production"&&n!=="light"&&n!=="dark"&&console.error(`MUI: @media (prefers-color-scheme) supports only 'light' or 'dark', but receive '${n}'.`),`@media (prefers-color-scheme: ${n})`):t?t.startsWith("data-")&&!t.includes("%s")?`[${t}="${n}"] &`:t==="class"?`.${n} &`:t==="data"?`[data-${n}] &`:`${t.replace("%s",n)} &`:"&"}}const Al={black:"#000",white:"#fff"},W5={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},sa={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",A100:"#ea80fc",A200:"#e040fb",A400:"#d500f9",A700:"#aa00ff"},aa={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",A100:"#ff8a80",A200:"#ff5252",A400:"#ff1744",A700:"#d50000"},Il={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"},la={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",A100:"#82b1ff",A200:"#448aff",A400:"#2979ff",A700:"#2962ff"},ca={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",A100:"#80d8ff",A200:"#40c4ff",A400:"#00b0ff",A700:"#0091ea"},ua={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",A100:"#b9f6ca",A200:"#69f0ae",A400:"#00e676",A700:"#00c853"};function XS(){return{text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:Al.white,default:Al.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}}}const q5=XS();function QS(){return{text:{primary:Al.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:Al.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}}}const eC=QS();function tC(t,e,n,r){const o=r.light||r,i=r.dark||r*1.5;t[e]||(t.hasOwnProperty(n)?t[e]=t[n]:e==="light"?t.light=Ol(t.main,o):e==="dark"&&(t.dark=ia(t.main,i)))}function U5(t="light"){return t==="dark"?{main:la[200],light:la[50],dark:la[400]}:{main:la[700],light:la[400],dark:la[800]}}function K5(t="light"){return t==="dark"?{main:sa[200],light:sa[50],dark:sa[400]}:{main:sa[500],light:sa[300],dark:sa[700]}}function Y5(t="light"){return t==="dark"?{main:aa[500],light:aa[300],dark:aa[700]}:{main:aa[700],light:aa[400],dark:aa[800]}}function G5(t="light"){return t==="dark"?{main:ca[400],light:ca[300],dark:ca[700]}:{main:ca[700],light:ca[500],dark:ca[900]}}function J5(t="light"){return t==="dark"?{main:ua[400],light:ua[300],dark:ua[700]}:{main:ua[800],light:ua[500],dark:ua[900]}}function Z5(t="light"){return t==="dark"?{main:Il[400],light:Il[300],dark:Il[700]}:{main:"#ed6c02",light:Il[500],dark:Il[900]}}function Vh(t){const{mode:e="light",contrastThreshold:n=3,tonalOffset:r=.2,...o}=t,i=t.primary||U5(e),s=t.secondary||K5(e),a=t.error||Y5(e),l=t.info||G5(e),u=t.success||J5(e),f=t.warning||Z5(e);function p(b){const S=GS(b,eC.text.primary)>=n?eC.text.primary:q5.text.primary;if(process.env.NODE_ENV!=="production"){const C=GS(b,S);C<3&&console.error([`MUI: The contrast ratio of ${C}:1 for ${S} on ${b}`,"falls below the WCAG recommended absolute minimum contrast ratio of 3:1.","https://www.w3.org/TR/2008/REC-WCAG20-20081211/#visual-audio-contrast-contrast"].join(`
|
|
55
55
|
`))}return S}const g=({color:b,name:S,mainShade:C=500,lightShade:T=300,darkShade:_=700})=>{if(b={...b},!b.main&&b[C]&&(b.main=b[C]),!b.hasOwnProperty("main"))throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${S?` (${S})`:""} provided to augmentColor(color) is invalid.
|
|
56
56
|
The color object needs to have a \`main\` property or a \`${C}\` property.`:bo(11,S?` (${S})`:"",C));if(typeof b.main!="string")throw new Error(process.env.NODE_ENV!=="production"?`MUI: The color${S?` (${S})`:""} provided to augmentColor(color) is invalid.
|
|
57
57
|
\`color.main\` should be a string, but \`${JSON.stringify(b.main)}\` was provided instead.
|
|
@@ -76,17 +76,17 @@ theme.transitions = createTransitions(theme.transitions || {});
|
|
|
76
76
|
|
|
77
77
|
export default theme;`}function Hh(t={},...e){const{breakpoints:n,mixins:r={},spacing:o,palette:i={},transitions:s={},typography:a={},shape:l,...u}=t;if(t.vars&&t.generateThemeVars===void 0)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name or follow the [docs](https://mui.com/material-ui/customization/css-theme-variables/usage/) to enable the feature.":bo(20));const f=Vh(i),p=Fh(t);let g=zn(p,{mixins:Q5(p.breakpoints,r),palette:f,shadows:iB.slice(),typography:tB(f,a),transitions:cB(s),zIndex:{...uB}});if(g=zn(g,u),g=e.reduce((m,y)=>zn(m,y),g),process.env.NODE_ENV!=="production"){const m=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],y=(b,S)=>{let C;for(C in b){const T=b[C];if(m.includes(C)&&Object.keys(T).length>0){if(process.env.NODE_ENV!=="production"){const _=Ke("",C);console.error([`MUI: The \`${S}\` component increases the CSS specificity of the \`${C}\` internal state.`,"You can not override it like this: ",JSON.stringify(b,null,2),"",`Instead, you need to use the '&.${_}' syntax:`,JSON.stringify({root:{[`&.${_}`]:T}},null,2),"","https://mui.com/r/state-classes-guide"].join(`
|
|
78
78
|
`))}b[C]={}}}};Object.keys(g.components).forEach(b=>{const S=g.components[b].styleOverrides;S&&b.startsWith("Mui")&&y(S,b)})}return g.unstable_sxConfig={...El,...u==null?void 0:u.unstable_sxConfig},g.unstable_sx=function(y){return oa({sx:y,theme:this})},g.toRuntimeSource=iC,g}function jh(t){let e;return t<1?e=5.11916*t**2:e=4.5*Math.log(t+1)+2,Math.round(e*10)/1e3}const fB=[...Array(25)].map((t,e)=>{if(e===0)return"none";const n=jh(e);return`linear-gradient(rgba(255 255 255 / ${n}), rgba(255 255 255 / ${n}))`});function sC(t){return{inputPlaceholder:t==="dark"?.5:.42,inputUnderline:t==="dark"?.7:.42,switchTrackDisabled:t==="dark"?.2:.12,switchTrack:t==="dark"?.3:.38}}function aC(t){return t==="dark"?fB:[]}function pB(t){const{palette:e={mode:"light"},opacity:n,overlays:r,...o}=t,i=Vh(e);return{palette:i,opacity:{...sC(i.mode),...n},overlays:r||aC(i.mode),...o}}function hB(t){var e;return!!t[0].match(/(cssVarPrefix|colorSchemeSelector|rootSelector|typography|mixins|breakpoints|direction|transitions)/)||!!t[0].match(/sxConfig$/)||t[0]==="palette"&&!!((e=t[1])!=null&&e.match(/(mode|contrastThreshold|tonalOffset)/))}const gB=t=>[...[...Array(25)].map((e,n)=>`--${t?`${t}-`:""}overlays-${n}`),`--${t?`${t}-`:""}palette-AppBar-darkBg`,`--${t?`${t}-`:""}palette-AppBar-darkColor`],mB=t=>(e,n)=>{const r=t.rootSelector||":root",o=t.colorSchemeSelector;let i=o;if(o==="class"&&(i=".%s"),o==="data"&&(i="[data-%s]"),o!=null&&o.startsWith("data-")&&!o.includes("%s")&&(i=`[${o}="%s"]`),t.defaultColorScheme===e){if(e==="dark"){const s={};return gB(t.cssVarPrefix).forEach(a=>{s[a]=n[a],delete n[a]}),i==="media"?{[r]:n,"@media (prefers-color-scheme: dark)":{[r]:s}}:i?{[i.replace("%s",e)]:s,[`${r}, ${i.replace("%s",e)}`]:n}:{[r]:{...n,...s}}}if(i&&i!=="media")return`${r}, ${i.replace("%s",String(e))}`}else if(e){if(i==="media")return{[`@media (prefers-color-scheme: ${String(e)})`]:{[r]:n}};if(i)return i.replace("%s",String(e))}return r};function yB(t,e){e.forEach(n=>{t[n]||(t[n]={})})}function ve(t,e,n){!t[e]&&n&&(t[e]=n)}function Dl(t){return typeof t!="string"||!t.startsWith("hsl")?t:YS(t)}function qo(t,e){`${e}Channel`in t||(t[`${e}Channel`]=Ml(Dl(t[e]),`MUI: Can't create \`palette.${e}Channel\` because \`palette.${e}\` is not one of these formats: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().
|
|
79
|
-
To suppress this warning, you need to explicitly provide the \`palette.${e}Channel\` as a string (in rgb format, for example "12 12 12") or undefined if you want to remove the channel token.`))}function bB(t){return typeof t=="number"?`${t}px`:typeof t=="string"||typeof t=="function"||Array.isArray(t)?t:"8px"}const xo=t=>{try{return t()}catch{}},vB=(t="mui")=>R5(t);function Wh(t,e,n,r){if(!e)return;e=e===!0?{}:e;const o=r==="dark"?"dark":"light";if(!n){t[r]=pB({...e,palette:{mode:o,...e==null?void 0:e.palette}});return}const{palette:i,...s}=Hh({...n,palette:{mode:o,...e==null?void 0:e.palette}});return t[r]={...e,palette:i,opacity:{...sC(o),...e==null?void 0:e.opacity},overlays:(e==null?void 0:e.overlays)||aC(o)},s}function xB(t={},...e){const{colorSchemes:n={light:!0},defaultColorScheme:r,disableCssColorScheme:o=!1,cssVarPrefix:i="mui",shouldSkipGeneratingVar:s=hB,colorSchemeSelector:a=n.light&&n.dark?"media":void 0,rootSelector:l=":root",...u}=t,f=Object.keys(n)[0],p=r||(n.light&&f!=="light"?"light":f),g=vB(i),{[p]:m,light:y,dark:b,...S}=n,C={...S};let T=m;if((p==="dark"&&!("dark"in n)||p==="light"&&!("light"in n))&&(T=!0),!T)throw new Error(process.env.NODE_ENV!=="production"?`MUI: The \`colorSchemes.${p}\` option is either missing or invalid.`:bo(21,p));const _=Wh(C,T,u,p);y&&!C.light&&Wh(C,y,void 0,"light"),b&&!C.dark&&Wh(C,b,void 0,"dark");let w={defaultColorScheme:p,..._,cssVarPrefix:i,colorSchemeSelector:a,rootSelector:l,getCssVar:g,colorSchemes:C,font:{...X5(_.typography),..._.font},spacing:bB(u.spacing)};Object.keys(w.colorSchemes).forEach($=>{const M=w.colorSchemes[$].palette,A=N=>{const V=N.split("-"),R=V[1],B=V[2];return g(N,M[R][B])};if(M.mode==="light"&&(ve(M.common,"background","#fff"),ve(M.common,"onBackground","#000")),M.mode==="dark"&&(ve(M.common,"background","#000"),ve(M.common,"onBackground","#fff")),yB(M,["Alert","AppBar","Avatar","Button","Chip","FilledInput","LinearProgress","Skeleton","Slider","SnackbarContent","SpeedDialAction","StepConnector","StepContent","Switch","TableCell","Tooltip"]),M.mode==="light"){ve(M.Alert,"errorColor",Nt(M.error.light,.6)),ve(M.Alert,"infoColor",Nt(M.info.light,.6)),ve(M.Alert,"successColor",Nt(M.success.light,.6)),ve(M.Alert,"warningColor",Nt(M.warning.light,.6)),ve(M.Alert,"errorFilledBg",A("palette-error-main")),ve(M.Alert,"infoFilledBg",A("palette-info-main")),ve(M.Alert,"successFilledBg",A("palette-success-main")),ve(M.Alert,"warningFilledBg",A("palette-warning-main")),ve(M.Alert,"errorFilledColor",xo(()=>M.getContrastText(M.error.main))),ve(M.Alert,"infoFilledColor",xo(()=>M.getContrastText(M.info.main))),ve(M.Alert,"successFilledColor",xo(()=>M.getContrastText(M.success.main))),ve(M.Alert,"warningFilledColor",xo(()=>M.getContrastText(M.warning.main))),ve(M.Alert,"errorStandardBg",Lt(M.error.light,.9)),ve(M.Alert,"infoStandardBg",Lt(M.info.light,.9)),ve(M.Alert,"successStandardBg",Lt(M.success.light,.9)),ve(M.Alert,"warningStandardBg",Lt(M.warning.light,.9)),ve(M.Alert,"errorIconColor",A("palette-error-main")),ve(M.Alert,"infoIconColor",A("palette-info-main")),ve(M.Alert,"successIconColor",A("palette-success-main")),ve(M.Alert,"warningIconColor",A("palette-warning-main")),ve(M.AppBar,"defaultBg",A("palette-grey-100")),ve(M.Avatar,"defaultBg",A("palette-grey-400")),ve(M.Button,"inheritContainedBg",A("palette-grey-300")),ve(M.Button,"inheritContainedHoverBg",A("palette-grey-A100")),ve(M.Chip,"defaultBorder",A("palette-grey-400")),ve(M.Chip,"defaultAvatarColor",A("palette-grey-700")),ve(M.Chip,"defaultIconColor",A("palette-grey-700")),ve(M.FilledInput,"bg","rgba(0, 0, 0, 0.06)"),ve(M.FilledInput,"hoverBg","rgba(0, 0, 0, 0.09)"),ve(M.FilledInput,"disabledBg","rgba(0, 0, 0, 0.12)"),ve(M.LinearProgress,"primaryBg",Lt(M.primary.main,.62)),ve(M.LinearProgress,"secondaryBg",Lt(M.secondary.main,.62)),ve(M.LinearProgress,"errorBg",Lt(M.error.main,.62)),ve(M.LinearProgress,"infoBg",Lt(M.info.main,.62)),ve(M.LinearProgress,"successBg",Lt(M.success.main,.62)),ve(M.LinearProgress,"warningBg",Lt(M.warning.main,.62)),ve(M.Skeleton,"bg",`rgba(${A("palette-text-primaryChannel")} / 0.11)`),ve(M.Slider,"primaryTrack",Lt(M.primary.main,.62)),ve(M.Slider,"secondaryTrack",Lt(M.secondary.main,.62)),ve(M.Slider,"errorTrack",Lt(M.error.main,.62)),ve(M.Slider,"infoTrack",Lt(M.info.main,.62)),ve(M.Slider,"successTrack",Lt(M.success.main,.62)),ve(M.Slider,"warningTrack",Lt(M.warning.main,.62));const N=Wu(M.background.default,.8);ve(M.SnackbarContent,"bg",N),ve(M.SnackbarContent,"color",xo(()=>M.getContrastText(N))),ve(M.SpeedDialAction,"fabHoverBg",Wu(M.background.paper,.15)),ve(M.StepConnector,"border",A("palette-grey-400")),ve(M.StepContent,"border",A("palette-grey-400")),ve(M.Switch,"defaultColor",A("palette-common-white")),ve(M.Switch,"defaultDisabledColor",A("palette-grey-100")),ve(M.Switch,"primaryDisabledColor",Lt(M.primary.main,.62)),ve(M.Switch,"secondaryDisabledColor",Lt(M.secondary.main,.62)),ve(M.Switch,"errorDisabledColor",Lt(M.error.main,.62)),ve(M.Switch,"infoDisabledColor",Lt(M.info.main,.62)),ve(M.Switch,"successDisabledColor",Lt(M.success.main,.62)),ve(M.Switch,"warningDisabledColor",Lt(M.warning.main,.62)),ve(M.TableCell,"border",Lt(ju(M.divider,1),.88)),ve(M.Tooltip,"bg",ju(M.grey[700],.92))}if(M.mode==="dark"){ve(M.Alert,"errorColor",Lt(M.error.light,.6)),ve(M.Alert,"infoColor",Lt(M.info.light,.6)),ve(M.Alert,"successColor",Lt(M.success.light,.6)),ve(M.Alert,"warningColor",Lt(M.warning.light,.6)),ve(M.Alert,"errorFilledBg",A("palette-error-dark")),ve(M.Alert,"infoFilledBg",A("palette-info-dark")),ve(M.Alert,"successFilledBg",A("palette-success-dark")),ve(M.Alert,"warningFilledBg",A("palette-warning-dark")),ve(M.Alert,"errorFilledColor",xo(()=>M.getContrastText(M.error.dark))),ve(M.Alert,"infoFilledColor",xo(()=>M.getContrastText(M.info.dark))),ve(M.Alert,"successFilledColor",xo(()=>M.getContrastText(M.success.dark))),ve(M.Alert,"warningFilledColor",xo(()=>M.getContrastText(M.warning.dark))),ve(M.Alert,"errorStandardBg",Nt(M.error.light,.9)),ve(M.Alert,"infoStandardBg",Nt(M.info.light,.9)),ve(M.Alert,"successStandardBg",Nt(M.success.light,.9)),ve(M.Alert,"warningStandardBg",Nt(M.warning.light,.9)),ve(M.Alert,"errorIconColor",A("palette-error-main")),ve(M.Alert,"infoIconColor",A("palette-info-main")),ve(M.Alert,"successIconColor",A("palette-success-main")),ve(M.Alert,"warningIconColor",A("palette-warning-main")),ve(M.AppBar,"defaultBg",A("palette-grey-900")),ve(M.AppBar,"darkBg",A("palette-background-paper")),ve(M.AppBar,"darkColor",A("palette-text-primary")),ve(M.Avatar,"defaultBg",A("palette-grey-600")),ve(M.Button,"inheritContainedBg",A("palette-grey-800")),ve(M.Button,"inheritContainedHoverBg",A("palette-grey-700")),ve(M.Chip,"defaultBorder",A("palette-grey-700")),ve(M.Chip,"defaultAvatarColor",A("palette-grey-300")),ve(M.Chip,"defaultIconColor",A("palette-grey-300")),ve(M.FilledInput,"bg","rgba(255, 255, 255, 0.09)"),ve(M.FilledInput,"hoverBg","rgba(255, 255, 255, 0.13)"),ve(M.FilledInput,"disabledBg","rgba(255, 255, 255, 0.12)"),ve(M.LinearProgress,"primaryBg",Nt(M.primary.main,.5)),ve(M.LinearProgress,"secondaryBg",Nt(M.secondary.main,.5)),ve(M.LinearProgress,"errorBg",Nt(M.error.main,.5)),ve(M.LinearProgress,"infoBg",Nt(M.info.main,.5)),ve(M.LinearProgress,"successBg",Nt(M.success.main,.5)),ve(M.LinearProgress,"warningBg",Nt(M.warning.main,.5)),ve(M.Skeleton,"bg",`rgba(${A("palette-text-primaryChannel")} / 0.13)`),ve(M.Slider,"primaryTrack",Nt(M.primary.main,.5)),ve(M.Slider,"secondaryTrack",Nt(M.secondary.main,.5)),ve(M.Slider,"errorTrack",Nt(M.error.main,.5)),ve(M.Slider,"infoTrack",Nt(M.info.main,.5)),ve(M.Slider,"successTrack",Nt(M.success.main,.5)),ve(M.Slider,"warningTrack",Nt(M.warning.main,.5));const N=Wu(M.background.default,.98);ve(M.SnackbarContent,"bg",N),ve(M.SnackbarContent,"color",xo(()=>M.getContrastText(N))),ve(M.SpeedDialAction,"fabHoverBg",Wu(M.background.paper,.15)),ve(M.StepConnector,"border",A("palette-grey-600")),ve(M.StepContent,"border",A("palette-grey-600")),ve(M.Switch,"defaultColor",A("palette-grey-300")),ve(M.Switch,"defaultDisabledColor",A("palette-grey-600")),ve(M.Switch,"primaryDisabledColor",Nt(M.primary.main,.55)),ve(M.Switch,"secondaryDisabledColor",Nt(M.secondary.main,.55)),ve(M.Switch,"errorDisabledColor",Nt(M.error.main,.55)),ve(M.Switch,"infoDisabledColor",Nt(M.info.main,.55)),ve(M.Switch,"successDisabledColor",Nt(M.success.main,.55)),ve(M.Switch,"warningDisabledColor",Nt(M.warning.main,.55)),ve(M.TableCell,"border",Nt(ju(M.divider,1),.68)),ve(M.Tooltip,"bg",ju(M.grey[700],.92))}qo(M.background,"default"),qo(M.background,"paper"),qo(M.common,"background"),qo(M.common,"onBackground"),qo(M,"divider"),Object.keys(M).forEach(N=>{const V=M[N];N!=="tonalOffset"&&V&&typeof V=="object"&&(V.main&&ve(M[N],"mainChannel",Ml(Dl(V.main))),V.light&&ve(M[N],"lightChannel",Ml(Dl(V.light))),V.dark&&ve(M[N],"darkChannel",Ml(Dl(V.dark))),V.contrastText&&ve(M[N],"contrastTextChannel",Ml(Dl(V.contrastText))),N==="text"&&(qo(M[N],"primary"),qo(M[N],"secondary")),N==="action"&&(V.active&&qo(M[N],"active"),V.selected&&qo(M[N],"selected")))})}),w=e.reduce(($,M)=>zn($,M),w);const E={prefix:i,disableCssColorScheme:o,shouldSkipGeneratingVar:s,getSelector:mB(w)},{vars:O,generateThemeVars:L,generateStyleSheets:P}=H5(w,E);return w.vars=O,Object.entries(w.colorSchemes[w.defaultColorScheme]).forEach(([$,M])=>{w[$]=M}),w.generateThemeVars=L,w.generateStyleSheets=P,w.generateSpacing=function(){return zS(u.spacing,Ph(this))},w.getColorSchemeSelector=j5(a),w.spacing=w.generateSpacing(),w.shouldSkipGeneratingVar=s,w.unstable_sxConfig={...El,...u==null?void 0:u.unstable_sxConfig},w.unstable_sx=function(M){return oa({sx:M,theme:this})},w.toRuntimeSource=iC,w}function lC(t,e,n){t.colorSchemes&&n&&(t.colorSchemes[e]={...n!==!0&&n,palette:Vh({...n===!0?{}:n.palette,mode:e})})}function SB(t={},...e){const{palette:n,cssVariables:r=!1,colorSchemes:o=n?void 0:{light:!0},defaultColorScheme:i=n==null?void 0:n.mode,...s}=t,a=i||"light",l=o==null?void 0:o[a],u={...o,...n?{[a]:{...typeof l!="boolean"&&l,palette:n}}:void 0};if(r===!1){if(!("colorSchemes"in t))return Hh(t,...e);let f=n;"palette"in t||u[a]&&(u[a]!==!0?f=u[a].palette:a==="dark"&&(f={mode:"dark"}));const p=Hh({...t,palette:f},...e);return p.defaultColorScheme=a,p.colorSchemes=u,p.palette.mode==="light"&&(p.colorSchemes.light={...u.light!==!0&&u.light,palette:p.palette},lC(p,"dark",u.dark)),p.palette.mode==="dark"&&(p.colorSchemes.dark={...u.dark!==!0&&u.dark,palette:p.palette},lC(p,"light",u.light)),p}return!n&&!("light"in u)&&a==="light"&&(u.light=!0),xB({...s,colorSchemes:u,defaultColorScheme:a,...typeof r!="boolean"&&r},...e)}const qu=SB(),Pl="$$material";function Si(){const t=$h(qu);return process.env.NODE_ENV!=="production"&&I.useDebugValue(t),t[Pl]||t}function cC(t){return v.jsx(HS,{...t,defaultTheme:qu,themeId:Pl})}process.env.NODE_ENV!=="production"&&(cC.propTypes={styles:c.oneOfType([c.array,c.func,c.number,c.object,c.string,c.bool])});function uC(t){return t!=="ownerState"&&t!=="theme"&&t!=="sx"&&t!=="as"}const ro=t=>uC(t)&&t!=="classes",be=C5({themeId:Pl,defaultTheme:qu,rootShouldForwardProp:ro});function CB(t){return function(n){return v.jsx(cC,{styles:typeof t=="function"?r=>t({theme:r,...n}):t})}}function wB(){return r5}const Dt=B5;process.env.NODE_ENV!=="production"&&(c.node,c.object.isRequired);function St(t){return $5(t)}function _B(t){return Ke("MuiSvgIcon",t)}qe("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const TB=t=>{const{color:e,fontSize:n,classes:r}=t,o={root:["root",e!=="inherit"&&`color${Ae(e)}`,`fontSize${Ae(n)}`]};return Ue(o,_B,r)},kB=be("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,n.color!=="inherit"&&e[`color${Ae(n.color)}`],e[`fontSize${Ae(n.fontSize)}`]]}})(Dt(({theme:t})=>{var e,n,r,o,i,s,a,l,u,f,p,g,m,y;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",flexShrink:0,transition:(o=(e=t.transitions)==null?void 0:e.create)==null?void 0:o.call(e,"fill",{duration:(r=(n=(t.vars??t).transitions)==null?void 0:n.duration)==null?void 0:r.shorter}),variants:[{props:b=>!b.hasSvgAsChild,style:{fill:"currentColor"}},{props:{fontSize:"inherit"},style:{fontSize:"inherit"}},{props:{fontSize:"small"},style:{fontSize:((s=(i=t.typography)==null?void 0:i.pxToRem)==null?void 0:s.call(i,20))||"1.25rem"}},{props:{fontSize:"medium"},style:{fontSize:((l=(a=t.typography)==null?void 0:a.pxToRem)==null?void 0:l.call(a,24))||"1.5rem"}},{props:{fontSize:"large"},style:{fontSize:((f=(u=t.typography)==null?void 0:u.pxToRem)==null?void 0:f.call(u,35))||"2.1875rem"}},...Object.entries((t.vars??t).palette).filter(([,b])=>b&&b.main).map(([b])=>{var S,C;return{props:{color:b},style:{color:(C=(S=(t.vars??t).palette)==null?void 0:S[b])==null?void 0:C.main}}}),{props:{color:"action"},style:{color:(g=(p=(t.vars??t).palette)==null?void 0:p.action)==null?void 0:g.active}},{props:{color:"disabled"},style:{color:(y=(m=(t.vars??t).palette)==null?void 0:m.action)==null?void 0:y.disabled}},{props:{color:"inherit"},style:{color:void 0}}]}})),Uu=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiSvgIcon"}),{children:o,className:i,color:s="inherit",component:a="svg",fontSize:l="medium",htmlColor:u,inheritViewBox:f=!1,titleAccess:p,viewBox:g="0 0 24 24",...m}=r,y=I.isValidElement(o)&&o.type==="svg",b={...r,color:s,component:a,fontSize:l,instanceFontSize:e.fontSize,inheritViewBox:f,viewBox:g,hasSvgAsChild:y},S={};f||(S.viewBox=g);const C=TB(b);return v.jsxs(kB,{as:a,className:Le(C.root,i),focusable:"false",color:u,"aria-hidden":p?void 0:!0,role:p?"img":void 0,ref:n,...S,...m,...y&&o.props,ownerState:b,children:[y?o.props.children:o,p?v.jsx("title",{children:p}):null]})});process.env.NODE_ENV!=="production"&&(Uu.propTypes={children:c.node,classes:c.object,className:c.string,color:c.oneOfType([c.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),c.string]),component:c.elementType,fontSize:c.oneOfType([c.oneOf(["inherit","large","medium","small"]),c.string]),htmlColor:c.string,inheritViewBox:c.bool,shapeRendering:c.string,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),titleAccess:c.string,viewBox:c.string}),Uu.muiName="SvgIcon";function ze(t,e){function n(r,o){return v.jsx(Uu,{"data-testid":`${e}Icon`,ref:o,...r,children:t})}return process.env.NODE_ENV!=="production"&&(n.displayName=`${e}Icon`),n.muiName=Uu.muiName,I.memo(I.forwardRef(n))}function EB(t,e){if(!t)return e;if(typeof t=="function"||typeof e=="function")return o=>{const i=typeof e=="function"?e(o):e,s=typeof t=="function"?t({...o,...i}):t,a=Le(o==null?void 0:o.className,i==null?void 0:i.className,s==null?void 0:s.className);return{...i,...s,...!!a&&{className:a},...(i==null?void 0:i.style)&&(s==null?void 0:s.style)&&{style:{...i.style,...s.style}},...(i==null?void 0:i.sx)&&(s==null?void 0:s.sx)&&{sx:[...Array.isArray(i.sx)?i.sx:[i.sx],...Array.isArray(s.sx)?s.sx:[s.sx]]}}};const n=e,r=Le(n==null?void 0:n.className,t==null?void 0:t.className);return{...e,...t,...!!r&&{className:r},...(n==null?void 0:n.style)&&(t==null?void 0:t.style)&&{style:{...n.style,...t.style}},...(n==null?void 0:n.sx)&&(t==null?void 0:t.sx)&&{sx:[...Array.isArray(n.sx)?n.sx:[n.sx],...Array.isArray(t.sx)?t.sx:[t.sx]]}}}const dC=ze(v.jsx("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m1 15h-2v-2h2zm0-4h-2V7h2z"}),"Error"),Xn=t=>{const{name:e,id:n,className:r}=t,[o,i,s]=jt.useField(e),{error:a}=i;return v.jsxs(F.Typography,{id:n,variant:"caption",display:"block",color:"error",style:{visibility:a?"visible":"hidden"},className:r,fontSize:".9rem",children:[v.jsx(F.Box,{component:"span",sx:{display:"inline-flex",alignItems:"center",position:"relative",top:"3px",mr:.5},children:v.jsx(dC,{fontSize:"inherit"})}),a]})},fC=t=>{const{name:e,label:n=_n(e),options:r=[],filterSelectedOptions:o=!0,variant:i="outlined",staticLabel:s=!1,staticLabelProps:a={fontSize:".9em",color:"#808080"},readOnly:l,margin:u="dense",fullWidth:f=!0,required:p,onChange:g,clearOnSelect:m=!1,onInputChange:y,getOptionLabel:b=N=>typeof N=="string"?N:String(N),isOptionEqualToValue:S=(N,V)=>JSON.stringify(N)===JSON.stringify(V),useFieldAsValue:C,...T}=t,[_,w,E]=jt.useField(e),{setValue:O}=E,{error:L}=w,[P,$]=I.useState(""),M={...Jn(T,["useFieldAsValue"]),getOptionLabel:b,options:r,filterSelectedOptions:o,isOptionEqualToValue:S,renderInput:N=>v.jsx(F.TextField,{...N,variant:i,label:s?void 0:n,error:!!L,required:p}),onChange:(N,V,R,B)=>{m?($(""),O(null)):O(C?V?V[C]:null:V),g&&g(N,V,R,B)},onInputChange:(N,V,R)=>{$(V),y&&y(N,V,R)},fullWidth:!0,inputValue:P,value:C?r.find(N=>N[C]===_.value)||null:_.value,slotProps:{paper:{elevation:8,sx:{borderRadius:2}}}},A=()=>{if(!_.value)return"";if(C){const N=r.find(V=>V[C]===_.value);return N?b(N):""}return b(_.value)};return v.jsxs(F.FormControl,{margin:u,fullWidth:f,required:p,children:[(s||l)&&v.jsx(F.Typography,{...a,children:n}),l?v.jsx(F.Typography,{children:A()}):v.jsxs(F.Box,{children:[v.jsx(F.Autocomplete,{...M}),v.jsx(Xn,{name:e,id:`${e}-err`})]})]})};var Nl={exports:{}};/**
|
|
79
|
+
To suppress this warning, you need to explicitly provide the \`palette.${e}Channel\` as a string (in rgb format, for example "12 12 12") or undefined if you want to remove the channel token.`))}function bB(t){return typeof t=="number"?`${t}px`:typeof t=="string"||typeof t=="function"||Array.isArray(t)?t:"8px"}const xo=t=>{try{return t()}catch{}},vB=(t="mui")=>R5(t);function Wh(t,e,n,r){if(!e)return;e=e===!0?{}:e;const o=r==="dark"?"dark":"light";if(!n){t[r]=pB({...e,palette:{mode:o,...e==null?void 0:e.palette}});return}const{palette:i,...s}=Hh({...n,palette:{mode:o,...e==null?void 0:e.palette}});return t[r]={...e,palette:i,opacity:{...sC(o),...e==null?void 0:e.opacity},overlays:(e==null?void 0:e.overlays)||aC(o)},s}function xB(t={},...e){const{colorSchemes:n={light:!0},defaultColorScheme:r,disableCssColorScheme:o=!1,cssVarPrefix:i="mui",shouldSkipGeneratingVar:s=hB,colorSchemeSelector:a=n.light&&n.dark?"media":void 0,rootSelector:l=":root",...u}=t,f=Object.keys(n)[0],p=r||(n.light&&f!=="light"?"light":f),g=vB(i),{[p]:m,light:y,dark:b,...S}=n,C={...S};let T=m;if((p==="dark"&&!("dark"in n)||p==="light"&&!("light"in n))&&(T=!0),!T)throw new Error(process.env.NODE_ENV!=="production"?`MUI: The \`colorSchemes.${p}\` option is either missing or invalid.`:bo(21,p));const _=Wh(C,T,u,p);y&&!C.light&&Wh(C,y,void 0,"light"),b&&!C.dark&&Wh(C,b,void 0,"dark");let w={defaultColorScheme:p,..._,cssVarPrefix:i,colorSchemeSelector:a,rootSelector:l,getCssVar:g,colorSchemes:C,font:{...X5(_.typography),..._.font},spacing:bB(u.spacing)};Object.keys(w.colorSchemes).forEach($=>{const M=w.colorSchemes[$].palette,A=N=>{const z=N.split("-"),V=z[1],B=z[2];return g(N,M[V][B])};if(M.mode==="light"&&(ve(M.common,"background","#fff"),ve(M.common,"onBackground","#000")),M.mode==="dark"&&(ve(M.common,"background","#000"),ve(M.common,"onBackground","#fff")),yB(M,["Alert","AppBar","Avatar","Button","Chip","FilledInput","LinearProgress","Skeleton","Slider","SnackbarContent","SpeedDialAction","StepConnector","StepContent","Switch","TableCell","Tooltip"]),M.mode==="light"){ve(M.Alert,"errorColor",Nt(M.error.light,.6)),ve(M.Alert,"infoColor",Nt(M.info.light,.6)),ve(M.Alert,"successColor",Nt(M.success.light,.6)),ve(M.Alert,"warningColor",Nt(M.warning.light,.6)),ve(M.Alert,"errorFilledBg",A("palette-error-main")),ve(M.Alert,"infoFilledBg",A("palette-info-main")),ve(M.Alert,"successFilledBg",A("palette-success-main")),ve(M.Alert,"warningFilledBg",A("palette-warning-main")),ve(M.Alert,"errorFilledColor",xo(()=>M.getContrastText(M.error.main))),ve(M.Alert,"infoFilledColor",xo(()=>M.getContrastText(M.info.main))),ve(M.Alert,"successFilledColor",xo(()=>M.getContrastText(M.success.main))),ve(M.Alert,"warningFilledColor",xo(()=>M.getContrastText(M.warning.main))),ve(M.Alert,"errorStandardBg",Lt(M.error.light,.9)),ve(M.Alert,"infoStandardBg",Lt(M.info.light,.9)),ve(M.Alert,"successStandardBg",Lt(M.success.light,.9)),ve(M.Alert,"warningStandardBg",Lt(M.warning.light,.9)),ve(M.Alert,"errorIconColor",A("palette-error-main")),ve(M.Alert,"infoIconColor",A("palette-info-main")),ve(M.Alert,"successIconColor",A("palette-success-main")),ve(M.Alert,"warningIconColor",A("palette-warning-main")),ve(M.AppBar,"defaultBg",A("palette-grey-100")),ve(M.Avatar,"defaultBg",A("palette-grey-400")),ve(M.Button,"inheritContainedBg",A("palette-grey-300")),ve(M.Button,"inheritContainedHoverBg",A("palette-grey-A100")),ve(M.Chip,"defaultBorder",A("palette-grey-400")),ve(M.Chip,"defaultAvatarColor",A("palette-grey-700")),ve(M.Chip,"defaultIconColor",A("palette-grey-700")),ve(M.FilledInput,"bg","rgba(0, 0, 0, 0.06)"),ve(M.FilledInput,"hoverBg","rgba(0, 0, 0, 0.09)"),ve(M.FilledInput,"disabledBg","rgba(0, 0, 0, 0.12)"),ve(M.LinearProgress,"primaryBg",Lt(M.primary.main,.62)),ve(M.LinearProgress,"secondaryBg",Lt(M.secondary.main,.62)),ve(M.LinearProgress,"errorBg",Lt(M.error.main,.62)),ve(M.LinearProgress,"infoBg",Lt(M.info.main,.62)),ve(M.LinearProgress,"successBg",Lt(M.success.main,.62)),ve(M.LinearProgress,"warningBg",Lt(M.warning.main,.62)),ve(M.Skeleton,"bg",`rgba(${A("palette-text-primaryChannel")} / 0.11)`),ve(M.Slider,"primaryTrack",Lt(M.primary.main,.62)),ve(M.Slider,"secondaryTrack",Lt(M.secondary.main,.62)),ve(M.Slider,"errorTrack",Lt(M.error.main,.62)),ve(M.Slider,"infoTrack",Lt(M.info.main,.62)),ve(M.Slider,"successTrack",Lt(M.success.main,.62)),ve(M.Slider,"warningTrack",Lt(M.warning.main,.62));const N=Wu(M.background.default,.8);ve(M.SnackbarContent,"bg",N),ve(M.SnackbarContent,"color",xo(()=>M.getContrastText(N))),ve(M.SpeedDialAction,"fabHoverBg",Wu(M.background.paper,.15)),ve(M.StepConnector,"border",A("palette-grey-400")),ve(M.StepContent,"border",A("palette-grey-400")),ve(M.Switch,"defaultColor",A("palette-common-white")),ve(M.Switch,"defaultDisabledColor",A("palette-grey-100")),ve(M.Switch,"primaryDisabledColor",Lt(M.primary.main,.62)),ve(M.Switch,"secondaryDisabledColor",Lt(M.secondary.main,.62)),ve(M.Switch,"errorDisabledColor",Lt(M.error.main,.62)),ve(M.Switch,"infoDisabledColor",Lt(M.info.main,.62)),ve(M.Switch,"successDisabledColor",Lt(M.success.main,.62)),ve(M.Switch,"warningDisabledColor",Lt(M.warning.main,.62)),ve(M.TableCell,"border",Lt(ju(M.divider,1),.88)),ve(M.Tooltip,"bg",ju(M.grey[700],.92))}if(M.mode==="dark"){ve(M.Alert,"errorColor",Lt(M.error.light,.6)),ve(M.Alert,"infoColor",Lt(M.info.light,.6)),ve(M.Alert,"successColor",Lt(M.success.light,.6)),ve(M.Alert,"warningColor",Lt(M.warning.light,.6)),ve(M.Alert,"errorFilledBg",A("palette-error-dark")),ve(M.Alert,"infoFilledBg",A("palette-info-dark")),ve(M.Alert,"successFilledBg",A("palette-success-dark")),ve(M.Alert,"warningFilledBg",A("palette-warning-dark")),ve(M.Alert,"errorFilledColor",xo(()=>M.getContrastText(M.error.dark))),ve(M.Alert,"infoFilledColor",xo(()=>M.getContrastText(M.info.dark))),ve(M.Alert,"successFilledColor",xo(()=>M.getContrastText(M.success.dark))),ve(M.Alert,"warningFilledColor",xo(()=>M.getContrastText(M.warning.dark))),ve(M.Alert,"errorStandardBg",Nt(M.error.light,.9)),ve(M.Alert,"infoStandardBg",Nt(M.info.light,.9)),ve(M.Alert,"successStandardBg",Nt(M.success.light,.9)),ve(M.Alert,"warningStandardBg",Nt(M.warning.light,.9)),ve(M.Alert,"errorIconColor",A("palette-error-main")),ve(M.Alert,"infoIconColor",A("palette-info-main")),ve(M.Alert,"successIconColor",A("palette-success-main")),ve(M.Alert,"warningIconColor",A("palette-warning-main")),ve(M.AppBar,"defaultBg",A("palette-grey-900")),ve(M.AppBar,"darkBg",A("palette-background-paper")),ve(M.AppBar,"darkColor",A("palette-text-primary")),ve(M.Avatar,"defaultBg",A("palette-grey-600")),ve(M.Button,"inheritContainedBg",A("palette-grey-800")),ve(M.Button,"inheritContainedHoverBg",A("palette-grey-700")),ve(M.Chip,"defaultBorder",A("palette-grey-700")),ve(M.Chip,"defaultAvatarColor",A("palette-grey-300")),ve(M.Chip,"defaultIconColor",A("palette-grey-300")),ve(M.FilledInput,"bg","rgba(255, 255, 255, 0.09)"),ve(M.FilledInput,"hoverBg","rgba(255, 255, 255, 0.13)"),ve(M.FilledInput,"disabledBg","rgba(255, 255, 255, 0.12)"),ve(M.LinearProgress,"primaryBg",Nt(M.primary.main,.5)),ve(M.LinearProgress,"secondaryBg",Nt(M.secondary.main,.5)),ve(M.LinearProgress,"errorBg",Nt(M.error.main,.5)),ve(M.LinearProgress,"infoBg",Nt(M.info.main,.5)),ve(M.LinearProgress,"successBg",Nt(M.success.main,.5)),ve(M.LinearProgress,"warningBg",Nt(M.warning.main,.5)),ve(M.Skeleton,"bg",`rgba(${A("palette-text-primaryChannel")} / 0.13)`),ve(M.Slider,"primaryTrack",Nt(M.primary.main,.5)),ve(M.Slider,"secondaryTrack",Nt(M.secondary.main,.5)),ve(M.Slider,"errorTrack",Nt(M.error.main,.5)),ve(M.Slider,"infoTrack",Nt(M.info.main,.5)),ve(M.Slider,"successTrack",Nt(M.success.main,.5)),ve(M.Slider,"warningTrack",Nt(M.warning.main,.5));const N=Wu(M.background.default,.98);ve(M.SnackbarContent,"bg",N),ve(M.SnackbarContent,"color",xo(()=>M.getContrastText(N))),ve(M.SpeedDialAction,"fabHoverBg",Wu(M.background.paper,.15)),ve(M.StepConnector,"border",A("palette-grey-600")),ve(M.StepContent,"border",A("palette-grey-600")),ve(M.Switch,"defaultColor",A("palette-grey-300")),ve(M.Switch,"defaultDisabledColor",A("palette-grey-600")),ve(M.Switch,"primaryDisabledColor",Nt(M.primary.main,.55)),ve(M.Switch,"secondaryDisabledColor",Nt(M.secondary.main,.55)),ve(M.Switch,"errorDisabledColor",Nt(M.error.main,.55)),ve(M.Switch,"infoDisabledColor",Nt(M.info.main,.55)),ve(M.Switch,"successDisabledColor",Nt(M.success.main,.55)),ve(M.Switch,"warningDisabledColor",Nt(M.warning.main,.55)),ve(M.TableCell,"border",Nt(ju(M.divider,1),.68)),ve(M.Tooltip,"bg",ju(M.grey[700],.92))}qo(M.background,"default"),qo(M.background,"paper"),qo(M.common,"background"),qo(M.common,"onBackground"),qo(M,"divider"),Object.keys(M).forEach(N=>{const z=M[N];N!=="tonalOffset"&&z&&typeof z=="object"&&(z.main&&ve(M[N],"mainChannel",Ml(Dl(z.main))),z.light&&ve(M[N],"lightChannel",Ml(Dl(z.light))),z.dark&&ve(M[N],"darkChannel",Ml(Dl(z.dark))),z.contrastText&&ve(M[N],"contrastTextChannel",Ml(Dl(z.contrastText))),N==="text"&&(qo(M[N],"primary"),qo(M[N],"secondary")),N==="action"&&(z.active&&qo(M[N],"active"),z.selected&&qo(M[N],"selected")))})}),w=e.reduce(($,M)=>zn($,M),w);const E={prefix:i,disableCssColorScheme:o,shouldSkipGeneratingVar:s,getSelector:mB(w)},{vars:O,generateThemeVars:L,generateStyleSheets:P}=H5(w,E);return w.vars=O,Object.entries(w.colorSchemes[w.defaultColorScheme]).forEach(([$,M])=>{w[$]=M}),w.generateThemeVars=L,w.generateStyleSheets=P,w.generateSpacing=function(){return zS(u.spacing,Ph(this))},w.getColorSchemeSelector=j5(a),w.spacing=w.generateSpacing(),w.shouldSkipGeneratingVar=s,w.unstable_sxConfig={...El,...u==null?void 0:u.unstable_sxConfig},w.unstable_sx=function(M){return oa({sx:M,theme:this})},w.toRuntimeSource=iC,w}function lC(t,e,n){t.colorSchemes&&n&&(t.colorSchemes[e]={...n!==!0&&n,palette:Vh({...n===!0?{}:n.palette,mode:e})})}function SB(t={},...e){const{palette:n,cssVariables:r=!1,colorSchemes:o=n?void 0:{light:!0},defaultColorScheme:i=n==null?void 0:n.mode,...s}=t,a=i||"light",l=o==null?void 0:o[a],u={...o,...n?{[a]:{...typeof l!="boolean"&&l,palette:n}}:void 0};if(r===!1){if(!("colorSchemes"in t))return Hh(t,...e);let f=n;"palette"in t||u[a]&&(u[a]!==!0?f=u[a].palette:a==="dark"&&(f={mode:"dark"}));const p=Hh({...t,palette:f},...e);return p.defaultColorScheme=a,p.colorSchemes=u,p.palette.mode==="light"&&(p.colorSchemes.light={...u.light!==!0&&u.light,palette:p.palette},lC(p,"dark",u.dark)),p.palette.mode==="dark"&&(p.colorSchemes.dark={...u.dark!==!0&&u.dark,palette:p.palette},lC(p,"light",u.light)),p}return!n&&!("light"in u)&&a==="light"&&(u.light=!0),xB({...s,colorSchemes:u,defaultColorScheme:a,...typeof r!="boolean"&&r},...e)}const qu=SB(),Pl="$$material";function Si(){const t=$h(qu);return process.env.NODE_ENV!=="production"&&I.useDebugValue(t),t[Pl]||t}function cC(t){return v.jsx(HS,{...t,defaultTheme:qu,themeId:Pl})}process.env.NODE_ENV!=="production"&&(cC.propTypes={styles:c.oneOfType([c.array,c.func,c.number,c.object,c.string,c.bool])});function uC(t){return t!=="ownerState"&&t!=="theme"&&t!=="sx"&&t!=="as"}const ro=t=>uC(t)&&t!=="classes",be=C5({themeId:Pl,defaultTheme:qu,rootShouldForwardProp:ro});function CB(t){return function(n){return v.jsx(cC,{styles:typeof t=="function"?r=>t({theme:r,...n}):t})}}function wB(){return r5}const Dt=B5;process.env.NODE_ENV!=="production"&&(c.node,c.object.isRequired);function St(t){return $5(t)}function _B(t){return Ke("MuiSvgIcon",t)}qe("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const TB=t=>{const{color:e,fontSize:n,classes:r}=t,o={root:["root",e!=="inherit"&&`color${Ae(e)}`,`fontSize${Ae(n)}`]};return Ue(o,_B,r)},kB=be("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,n.color!=="inherit"&&e[`color${Ae(n.color)}`],e[`fontSize${Ae(n.fontSize)}`]]}})(Dt(({theme:t})=>{var e,n,r,o,i,s,a,l,u,f,p,g,m,y;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",flexShrink:0,transition:(o=(e=t.transitions)==null?void 0:e.create)==null?void 0:o.call(e,"fill",{duration:(r=(n=(t.vars??t).transitions)==null?void 0:n.duration)==null?void 0:r.shorter}),variants:[{props:b=>!b.hasSvgAsChild,style:{fill:"currentColor"}},{props:{fontSize:"inherit"},style:{fontSize:"inherit"}},{props:{fontSize:"small"},style:{fontSize:((s=(i=t.typography)==null?void 0:i.pxToRem)==null?void 0:s.call(i,20))||"1.25rem"}},{props:{fontSize:"medium"},style:{fontSize:((l=(a=t.typography)==null?void 0:a.pxToRem)==null?void 0:l.call(a,24))||"1.5rem"}},{props:{fontSize:"large"},style:{fontSize:((f=(u=t.typography)==null?void 0:u.pxToRem)==null?void 0:f.call(u,35))||"2.1875rem"}},...Object.entries((t.vars??t).palette).filter(([,b])=>b&&b.main).map(([b])=>{var S,C;return{props:{color:b},style:{color:(C=(S=(t.vars??t).palette)==null?void 0:S[b])==null?void 0:C.main}}}),{props:{color:"action"},style:{color:(g=(p=(t.vars??t).palette)==null?void 0:p.action)==null?void 0:g.active}},{props:{color:"disabled"},style:{color:(y=(m=(t.vars??t).palette)==null?void 0:m.action)==null?void 0:y.disabled}},{props:{color:"inherit"},style:{color:void 0}}]}})),Uu=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiSvgIcon"}),{children:o,className:i,color:s="inherit",component:a="svg",fontSize:l="medium",htmlColor:u,inheritViewBox:f=!1,titleAccess:p,viewBox:g="0 0 24 24",...m}=r,y=I.isValidElement(o)&&o.type==="svg",b={...r,color:s,component:a,fontSize:l,instanceFontSize:e.fontSize,inheritViewBox:f,viewBox:g,hasSvgAsChild:y},S={};f||(S.viewBox=g);const C=TB(b);return v.jsxs(kB,{as:a,className:Le(C.root,i),focusable:"false",color:u,"aria-hidden":p?void 0:!0,role:p?"img":void 0,ref:n,...S,...m,...y&&o.props,ownerState:b,children:[y?o.props.children:o,p?v.jsx("title",{children:p}):null]})});process.env.NODE_ENV!=="production"&&(Uu.propTypes={children:c.node,classes:c.object,className:c.string,color:c.oneOfType([c.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),c.string]),component:c.elementType,fontSize:c.oneOfType([c.oneOf(["inherit","large","medium","small"]),c.string]),htmlColor:c.string,inheritViewBox:c.bool,shapeRendering:c.string,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),titleAccess:c.string,viewBox:c.string}),Uu.muiName="SvgIcon";function ze(t,e){function n(r,o){return v.jsx(Uu,{"data-testid":`${e}Icon`,ref:o,...r,children:t})}return process.env.NODE_ENV!=="production"&&(n.displayName=`${e}Icon`),n.muiName=Uu.muiName,I.memo(I.forwardRef(n))}function EB(t,e){if(!t)return e;if(typeof t=="function"||typeof e=="function")return o=>{const i=typeof e=="function"?e(o):e,s=typeof t=="function"?t({...o,...i}):t,a=Le(o==null?void 0:o.className,i==null?void 0:i.className,s==null?void 0:s.className);return{...i,...s,...!!a&&{className:a},...(i==null?void 0:i.style)&&(s==null?void 0:s.style)&&{style:{...i.style,...s.style}},...(i==null?void 0:i.sx)&&(s==null?void 0:s.sx)&&{sx:[...Array.isArray(i.sx)?i.sx:[i.sx],...Array.isArray(s.sx)?s.sx:[s.sx]]}}};const n=e,r=Le(n==null?void 0:n.className,t==null?void 0:t.className);return{...e,...t,...!!r&&{className:r},...(n==null?void 0:n.style)&&(t==null?void 0:t.style)&&{style:{...n.style,...t.style}},...(n==null?void 0:n.sx)&&(t==null?void 0:t.sx)&&{sx:[...Array.isArray(n.sx)?n.sx:[n.sx],...Array.isArray(t.sx)?t.sx:[t.sx]]}}}const dC=ze(v.jsx("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m1 15h-2v-2h2zm0-4h-2V7h2z"}),"Error"),Xn=t=>{const{name:e,id:n,className:r}=t,[o,i,s]=jt.useField(e),{error:a}=i;return v.jsxs(F.Typography,{id:n,variant:"caption",display:"block",color:"error",style:{visibility:a?"visible":"hidden"},className:r,fontSize:".9rem",children:[v.jsx(F.Box,{component:"span",sx:{display:"inline-flex",alignItems:"center",position:"relative",top:"3px",mr:.5},children:v.jsx(dC,{fontSize:"inherit"})}),a]})},fC=t=>{const{name:e,label:n=_n(e),options:r=[],filterSelectedOptions:o=!0,variant:i="outlined",staticLabel:s=!1,staticLabelProps:a={fontSize:".9em",color:"#808080"},readOnly:l,margin:u="dense",fullWidth:f=!0,required:p,onChange:g,clearOnSelect:m=!1,onInputChange:y,getOptionLabel:b=N=>typeof N=="string"?N:String(N),isOptionEqualToValue:S=(N,z)=>JSON.stringify(N)===JSON.stringify(z),useFieldAsValue:C,...T}=t,[_,w,E]=jt.useField(e),{setValue:O}=E,{error:L}=w,[P,$]=I.useState(""),M={...Jn(T,["useFieldAsValue"]),getOptionLabel:b,options:r,filterSelectedOptions:o,isOptionEqualToValue:S,renderInput:N=>v.jsx(F.TextField,{...N,variant:i,label:s?void 0:n,error:!!L,required:p}),onChange:(N,z,V,B)=>{m?($(""),O(null)):O(C?z?z[C]:null:z),g&&g(N,z,V,B)},onInputChange:(N,z,V)=>{$(z),y&&y(N,z,V)},fullWidth:!0,inputValue:P,value:C?r.find(N=>N[C]===_.value)||null:_.value,slotProps:{paper:{elevation:8,sx:{borderRadius:2}}}},A=()=>{if(!_.value)return"";if(C){const N=r.find(z=>z[C]===_.value);return N?b(N):""}return b(_.value)};return v.jsxs(F.FormControl,{margin:u,fullWidth:f,required:p,children:[(s||l)&&v.jsx(F.Typography,{...a,children:n}),l?v.jsx(F.Typography,{children:A()}):v.jsxs(F.Box,{children:[v.jsx(F.Autocomplete,{...M}),v.jsx(Xn,{name:e,id:`${e}-err`})]})]})};var Nl={exports:{}};/**
|
|
80
80
|
* @license
|
|
81
81
|
* Lodash <https://lodash.com/>
|
|
82
82
|
* Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
|
|
83
83
|
* Released under MIT license <https://lodash.com/license>
|
|
84
84
|
* Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
|
|
85
85
|
* Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
|
|
86
|
-
*/var MB=Nl.exports,pC;function OB(){return pC||(pC=1,function(t,e){(function(){var n,r="4.17.21",o=200,i="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",s="Expected a function",a="Invalid `variable` option passed into `_.template`",l="__lodash_hash_undefined__",u=500,f="__lodash_placeholder__",p=1,g=2,m=4,y=1,b=2,S=1,C=2,T=4,_=8,w=16,E=32,O=64,L=128,P=256,$=512,M=30,A="...",N=800,V=16,R=1,B=2,z=3,q=1/0,K=9007199254740991,G=17976931348623157e292,Y=NaN,Z=4294967295,me=Z-1,he=Z>>>1,oe=[["ary",L],["bind",S],["bindKey",C],["curry",_],["curryRight",w],["flip",$],["partial",E],["partialRight",O],["rearg",P]],Q="[object Arguments]",fe="[object Array]",ce="[object AsyncFunction]",ae="[object Boolean]",W="[object Date]",te="[object DOMException]",ue="[object Error]",ee="[object Function]",se="[object GeneratorFunction]",de="[object Map]",ye="[object Number]",_e="[object Null]",Se="[object Object]",Me="[object Promise]",Fe="[object Proxy]",je="[object RegExp]",Je="[object Set]",De="[object String]",ct="[object Symbol]",Ct="[object Undefined]",Xt="[object WeakMap]",Sn="[object WeakSet]",un="[object ArrayBuffer]",$t="[object DataView]",In="[object Float32Array]",Kn="[object Float64Array]",ft="[object Int8Array]",$n="[object Int16Array]",Yt="[object Int32Array]",ge="[object Uint8Array]",$e="[object Uint8ClampedArray]",ke="[object Uint16Array]",Re="[object Uint32Array]",Ge=/\b__p \+= '';/g,nt=/\b(__p \+=) '' \+/g,Pt=/(__e\(.*?\)|\b__t\)) \+\n'';/g,rr=/&(?:amp|lt|gt|quot|#39);/g,hr=/[&<>"']/g,si=RegExp(rr.source),su=RegExp(hr.source),rl=/<%-([\s\S]+?)%>/g,Zi=/<%([\s\S]+?)%>/g,Pp=/<%=([\s\S]+?)%>/g,au=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,ol=/^\w*$/,Jne=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,E1=/[\\^$.*+?()[\]{}|]/g,Zne=RegExp(E1.source),M1=/^\s+/,Xne=/\s/,Qne=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,ere=/\{\n\/\* \[wrapped with (.+)\] \*/,tre=/,? & /,nre=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,rre=/[()=,{}\[\]\/\s]/,ore=/\\(\\)?/g,ire=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,nN=/\w*$/,sre=/^[-+]0x[0-9a-f]+$/i,are=/^0b[01]+$/i,lre=/^\[object .+?Constructor\]$/,cre=/^0o[0-7]+$/i,ure=/^(?:0|[1-9]\d*)$/,dre=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Np=/($^)/,fre=/['\n\r\u2028\u2029\\]/g,Lp="\\ud800-\\udfff",pre="\\u0300-\\u036f",hre="\\ufe20-\\ufe2f",gre="\\u20d0-\\u20ff",rN=pre+hre+gre,oN="\\u2700-\\u27bf",iN="a-z\\xdf-\\xf6\\xf8-\\xff",mre="\\xac\\xb1\\xd7\\xf7",yre="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",bre="\\u2000-\\u206f",vre=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",sN="A-Z\\xc0-\\xd6\\xd8-\\xde",aN="\\ufe0e\\ufe0f",lN=mre+yre+bre+vre,O1="['’]",xre="["+Lp+"]",cN="["+lN+"]",Fp="["+rN+"]",uN="\\d+",Sre="["+oN+"]",dN="["+iN+"]",fN="[^"+Lp+lN+uN+oN+iN+sN+"]",A1="\\ud83c[\\udffb-\\udfff]",Cre="(?:"+Fp+"|"+A1+")",pN="[^"+Lp+"]",I1="(?:\\ud83c[\\udde6-\\uddff]){2}",D1="[\\ud800-\\udbff][\\udc00-\\udfff]",il="["+sN+"]",hN="\\u200d",gN="(?:"+dN+"|"+fN+")",wre="(?:"+il+"|"+fN+")",mN="(?:"+O1+"(?:d|ll|m|re|s|t|ve))?",yN="(?:"+O1+"(?:D|LL|M|RE|S|T|VE))?",bN=Cre+"?",vN="["+aN+"]?",_re="(?:"+hN+"(?:"+[pN,I1,D1].join("|")+")"+vN+bN+")*",Tre="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",kre="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",xN=vN+bN+_re,Ere="(?:"+[Sre,I1,D1].join("|")+")"+xN,Mre="(?:"+[pN+Fp+"?",Fp,I1,D1,xre].join("|")+")",Ore=RegExp(O1,"g"),Are=RegExp(Fp,"g"),P1=RegExp(A1+"(?="+A1+")|"+Mre+xN,"g"),Ire=RegExp([il+"?"+dN+"+"+mN+"(?="+[cN,il,"$"].join("|")+")",wre+"+"+yN+"(?="+[cN,il+gN,"$"].join("|")+")",il+"?"+gN+"+"+mN,il+"+"+yN,kre,Tre,uN,Ere].join("|"),"g"),Dre=RegExp("["+hN+Lp+rN+aN+"]"),Pre=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Nre=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],Lre=-1,Gt={};Gt[In]=Gt[Kn]=Gt[ft]=Gt[$n]=Gt[Yt]=Gt[ge]=Gt[$e]=Gt[ke]=Gt[Re]=!0,Gt[Q]=Gt[fe]=Gt[un]=Gt[ae]=Gt[$t]=Gt[W]=Gt[ue]=Gt[ee]=Gt[de]=Gt[ye]=Gt[Se]=Gt[je]=Gt[Je]=Gt[De]=Gt[Xt]=!1;var Ht={};Ht[Q]=Ht[fe]=Ht[un]=Ht[$t]=Ht[ae]=Ht[W]=Ht[In]=Ht[Kn]=Ht[ft]=Ht[$n]=Ht[Yt]=Ht[de]=Ht[ye]=Ht[Se]=Ht[je]=Ht[Je]=Ht[De]=Ht[ct]=Ht[ge]=Ht[$e]=Ht[ke]=Ht[Re]=!0,Ht[ue]=Ht[ee]=Ht[Xt]=!1;var Fre={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},$re={"&":"&","<":"<",">":">",'"':""","'":"'"},Bre={"&":"&","<":"<",">":">",""":'"',"'":"'"},Rre={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},zre=parseFloat,Vre=parseInt,SN=typeof yi=="object"&&yi&&yi.Object===Object&&yi,Hre=typeof self=="object"&&self&&self.Object===Object&&self,Bn=SN||Hre||Function("return this")(),N1=e&&!e.nodeType&&e,Ys=N1&&!0&&t&&!t.nodeType&&t,CN=Ys&&Ys.exports===N1,L1=CN&&SN.process,Ur=function(){try{var re=Ys&&Ys.require&&Ys.require("util").types;return re||L1&&L1.binding&&L1.binding("util")}catch{}}(),wN=Ur&&Ur.isArrayBuffer,_N=Ur&&Ur.isDate,TN=Ur&&Ur.isMap,kN=Ur&&Ur.isRegExp,EN=Ur&&Ur.isSet,MN=Ur&&Ur.isTypedArray;function Tr(re,xe,pe){switch(pe.length){case 0:return re.call(xe);case 1:return re.call(xe,pe[0]);case 2:return re.call(xe,pe[0],pe[1]);case 3:return re.call(xe,pe[0],pe[1],pe[2])}return re.apply(xe,pe)}function jre(re,xe,pe,Ve){for(var ot=-1,_t=re==null?0:re.length;++ot<_t;){var Cn=re[ot];xe(Ve,Cn,pe(Cn),re)}return Ve}function Kr(re,xe){for(var pe=-1,Ve=re==null?0:re.length;++pe<Ve&&xe(re[pe],pe,re)!==!1;);return re}function Wre(re,xe){for(var pe=re==null?0:re.length;pe--&&xe(re[pe],pe,re)!==!1;);return re}function ON(re,xe){for(var pe=-1,Ve=re==null?0:re.length;++pe<Ve;)if(!xe(re[pe],pe,re))return!1;return!0}function Xi(re,xe){for(var pe=-1,Ve=re==null?0:re.length,ot=0,_t=[];++pe<Ve;){var Cn=re[pe];xe(Cn,pe,re)&&(_t[ot++]=Cn)}return _t}function $p(re,xe){var pe=re==null?0:re.length;return!!pe&&sl(re,xe,0)>-1}function F1(re,xe,pe){for(var Ve=-1,ot=re==null?0:re.length;++Ve<ot;)if(pe(xe,re[Ve]))return!0;return!1}function Qt(re,xe){for(var pe=-1,Ve=re==null?0:re.length,ot=Array(Ve);++pe<Ve;)ot[pe]=xe(re[pe],pe,re);return ot}function Qi(re,xe){for(var pe=-1,Ve=xe.length,ot=re.length;++pe<Ve;)re[ot+pe]=xe[pe];return re}function $1(re,xe,pe,Ve){var ot=-1,_t=re==null?0:re.length;for(Ve&&_t&&(pe=re[++ot]);++ot<_t;)pe=xe(pe,re[ot],ot,re);return pe}function qre(re,xe,pe,Ve){var ot=re==null?0:re.length;for(Ve&&ot&&(pe=re[--ot]);ot--;)pe=xe(pe,re[ot],ot,re);return pe}function B1(re,xe){for(var pe=-1,Ve=re==null?0:re.length;++pe<Ve;)if(xe(re[pe],pe,re))return!0;return!1}var Ure=R1("length");function Kre(re){return re.split("")}function Yre(re){return re.match(nre)||[]}function AN(re,xe,pe){var Ve;return pe(re,function(ot,_t,Cn){if(xe(ot,_t,Cn))return Ve=_t,!1}),Ve}function Bp(re,xe,pe,Ve){for(var ot=re.length,_t=pe+(Ve?1:-1);Ve?_t--:++_t<ot;)if(xe(re[_t],_t,re))return _t;return-1}function sl(re,xe,pe){return xe===xe?soe(re,xe,pe):Bp(re,IN,pe)}function Gre(re,xe,pe,Ve){for(var ot=pe-1,_t=re.length;++ot<_t;)if(Ve(re[ot],xe))return ot;return-1}function IN(re){return re!==re}function DN(re,xe){var pe=re==null?0:re.length;return pe?V1(re,xe)/pe:Y}function R1(re){return function(xe){return xe==null?n:xe[re]}}function z1(re){return function(xe){return re==null?n:re[xe]}}function PN(re,xe,pe,Ve,ot){return ot(re,function(_t,Cn,Bt){pe=Ve?(Ve=!1,_t):xe(pe,_t,Cn,Bt)}),pe}function Jre(re,xe){var pe=re.length;for(re.sort(xe);pe--;)re[pe]=re[pe].value;return re}function V1(re,xe){for(var pe,Ve=-1,ot=re.length;++Ve<ot;){var _t=xe(re[Ve]);_t!==n&&(pe=pe===n?_t:pe+_t)}return pe}function H1(re,xe){for(var pe=-1,Ve=Array(re);++pe<re;)Ve[pe]=xe(pe);return Ve}function Zre(re,xe){return Qt(xe,function(pe){return[pe,re[pe]]})}function NN(re){return re&&re.slice(0,BN(re)+1).replace(M1,"")}function kr(re){return function(xe){return re(xe)}}function j1(re,xe){return Qt(xe,function(pe){return re[pe]})}function lu(re,xe){return re.has(xe)}function LN(re,xe){for(var pe=-1,Ve=re.length;++pe<Ve&&sl(xe,re[pe],0)>-1;);return pe}function FN(re,xe){for(var pe=re.length;pe--&&sl(xe,re[pe],0)>-1;);return pe}function Xre(re,xe){for(var pe=re.length,Ve=0;pe--;)re[pe]===xe&&++Ve;return Ve}var Qre=z1(Fre),eoe=z1($re);function toe(re){return"\\"+Rre[re]}function noe(re,xe){return re==null?n:re[xe]}function al(re){return Dre.test(re)}function roe(re){return Pre.test(re)}function ooe(re){for(var xe,pe=[];!(xe=re.next()).done;)pe.push(xe.value);return pe}function W1(re){var xe=-1,pe=Array(re.size);return re.forEach(function(Ve,ot){pe[++xe]=[ot,Ve]}),pe}function $N(re,xe){return function(pe){return re(xe(pe))}}function es(re,xe){for(var pe=-1,Ve=re.length,ot=0,_t=[];++pe<Ve;){var Cn=re[pe];(Cn===xe||Cn===f)&&(re[pe]=f,_t[ot++]=pe)}return _t}function Rp(re){var xe=-1,pe=Array(re.size);return re.forEach(function(Ve){pe[++xe]=Ve}),pe}function ioe(re){var xe=-1,pe=Array(re.size);return re.forEach(function(Ve){pe[++xe]=[Ve,Ve]}),pe}function soe(re,xe,pe){for(var Ve=pe-1,ot=re.length;++Ve<ot;)if(re[Ve]===xe)return Ve;return-1}function aoe(re,xe,pe){for(var Ve=pe+1;Ve--;)if(re[Ve]===xe)return Ve;return Ve}function ll(re){return al(re)?coe(re):Ure(re)}function po(re){return al(re)?uoe(re):Kre(re)}function BN(re){for(var xe=re.length;xe--&&Xne.test(re.charAt(xe)););return xe}var loe=z1(Bre);function coe(re){for(var xe=P1.lastIndex=0;P1.test(re);)++xe;return xe}function uoe(re){return re.match(P1)||[]}function doe(re){return re.match(Ire)||[]}var foe=function re(xe){xe=xe==null?Bn:cl.defaults(Bn.Object(),xe,cl.pick(Bn,Nre));var pe=xe.Array,Ve=xe.Date,ot=xe.Error,_t=xe.Function,Cn=xe.Math,Bt=xe.Object,q1=xe.RegExp,poe=xe.String,Yr=xe.TypeError,zp=pe.prototype,hoe=_t.prototype,ul=Bt.prototype,Vp=xe["__core-js_shared__"],Hp=hoe.toString,Ot=ul.hasOwnProperty,goe=0,RN=function(){var d=/[^.]+$/.exec(Vp&&Vp.keys&&Vp.keys.IE_PROTO||"");return d?"Symbol(src)_1."+d:""}(),jp=ul.toString,moe=Hp.call(Bt),yoe=Bn._,boe=q1("^"+Hp.call(Ot).replace(E1,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Wp=CN?xe.Buffer:n,ts=xe.Symbol,qp=xe.Uint8Array,zN=Wp?Wp.allocUnsafe:n,Up=$N(Bt.getPrototypeOf,Bt),VN=Bt.create,HN=ul.propertyIsEnumerable,Kp=zp.splice,jN=ts?ts.isConcatSpreadable:n,cu=ts?ts.iterator:n,Gs=ts?ts.toStringTag:n,Yp=function(){try{var d=ea(Bt,"defineProperty");return d({},"",{}),d}catch{}}(),voe=xe.clearTimeout!==Bn.clearTimeout&&xe.clearTimeout,xoe=Ve&&Ve.now!==Bn.Date.now&&Ve.now,Soe=xe.setTimeout!==Bn.setTimeout&&xe.setTimeout,Gp=Cn.ceil,Jp=Cn.floor,U1=Bt.getOwnPropertySymbols,Coe=Wp?Wp.isBuffer:n,WN=xe.isFinite,woe=zp.join,_oe=$N(Bt.keys,Bt),wn=Cn.max,Yn=Cn.min,Toe=Ve.now,koe=xe.parseInt,qN=Cn.random,Eoe=zp.reverse,K1=ea(xe,"DataView"),uu=ea(xe,"Map"),Y1=ea(xe,"Promise"),dl=ea(xe,"Set"),du=ea(xe,"WeakMap"),fu=ea(Bt,"create"),Zp=du&&new du,fl={},Moe=ta(K1),Ooe=ta(uu),Aoe=ta(Y1),Ioe=ta(dl),Doe=ta(du),Xp=ts?ts.prototype:n,pu=Xp?Xp.valueOf:n,UN=Xp?Xp.toString:n;function H(d){if(dn(d)&&!it(d)&&!(d instanceof mt)){if(d instanceof Gr)return d;if(Ot.call(d,"__wrapped__"))return KL(d)}return new Gr(d)}var pl=function(){function d(){}return function(h){if(!nn(h))return{};if(VN)return VN(h);d.prototype=h;var x=new d;return d.prototype=n,x}}();function Qp(){}function Gr(d,h){this.__wrapped__=d,this.__actions__=[],this.__chain__=!!h,this.__index__=0,this.__values__=n}H.templateSettings={escape:rl,evaluate:Zi,interpolate:Pp,variable:"",imports:{_:H}},H.prototype=Qp.prototype,H.prototype.constructor=H,Gr.prototype=pl(Qp.prototype),Gr.prototype.constructor=Gr;function mt(d){this.__wrapped__=d,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=Z,this.__views__=[]}function Poe(){var d=new mt(this.__wrapped__);return d.__actions__=gr(this.__actions__),d.__dir__=this.__dir__,d.__filtered__=this.__filtered__,d.__iteratees__=gr(this.__iteratees__),d.__takeCount__=this.__takeCount__,d.__views__=gr(this.__views__),d}function Noe(){if(this.__filtered__){var d=new mt(this);d.__dir__=-1,d.__filtered__=!0}else d=this.clone(),d.__dir__*=-1;return d}function Loe(){var d=this.__wrapped__.value(),h=this.__dir__,x=it(d),k=h<0,D=x?d.length:0,j=Kie(0,D,this.__views__),U=j.start,X=j.end,ie=X-U,Ce=k?X:U-1,we=this.__iteratees__,Ee=we.length,Ne=0,We=Yn(ie,this.__takeCount__);if(!x||!k&&D==ie&&We==ie)return mL(d,this.__actions__);var et=[];e:for(;ie--&&Ne<We;){Ce+=h;for(var ut=-1,tt=d[Ce];++ut<Ee;){var ht=we[ut],xt=ht.iteratee,Or=ht.type,sr=xt(tt);if(Or==B)tt=sr;else if(!sr){if(Or==R)continue e;break e}}et[Ne++]=tt}return et}mt.prototype=pl(Qp.prototype),mt.prototype.constructor=mt;function Js(d){var h=-1,x=d==null?0:d.length;for(this.clear();++h<x;){var k=d[h];this.set(k[0],k[1])}}function Foe(){this.__data__=fu?fu(null):{},this.size=0}function $oe(d){var h=this.has(d)&&delete this.__data__[d];return this.size-=h?1:0,h}function Boe(d){var h=this.__data__;if(fu){var x=h[d];return x===l?n:x}return Ot.call(h,d)?h[d]:n}function Roe(d){var h=this.__data__;return fu?h[d]!==n:Ot.call(h,d)}function zoe(d,h){var x=this.__data__;return this.size+=this.has(d)?0:1,x[d]=fu&&h===n?l:h,this}Js.prototype.clear=Foe,Js.prototype.delete=$oe,Js.prototype.get=Boe,Js.prototype.has=Roe,Js.prototype.set=zoe;function ai(d){var h=-1,x=d==null?0:d.length;for(this.clear();++h<x;){var k=d[h];this.set(k[0],k[1])}}function Voe(){this.__data__=[],this.size=0}function Hoe(d){var h=this.__data__,x=eh(h,d);if(x<0)return!1;var k=h.length-1;return x==k?h.pop():Kp.call(h,x,1),--this.size,!0}function joe(d){var h=this.__data__,x=eh(h,d);return x<0?n:h[x][1]}function Woe(d){return eh(this.__data__,d)>-1}function qoe(d,h){var x=this.__data__,k=eh(x,d);return k<0?(++this.size,x.push([d,h])):x[k][1]=h,this}ai.prototype.clear=Voe,ai.prototype.delete=Hoe,ai.prototype.get=joe,ai.prototype.has=Woe,ai.prototype.set=qoe;function li(d){var h=-1,x=d==null?0:d.length;for(this.clear();++h<x;){var k=d[h];this.set(k[0],k[1])}}function Uoe(){this.size=0,this.__data__={hash:new Js,map:new(uu||ai),string:new Js}}function Koe(d){var h=fh(this,d).delete(d);return this.size-=h?1:0,h}function Yoe(d){return fh(this,d).get(d)}function Goe(d){return fh(this,d).has(d)}function Joe(d,h){var x=fh(this,d),k=x.size;return x.set(d,h),this.size+=x.size==k?0:1,this}li.prototype.clear=Uoe,li.prototype.delete=Koe,li.prototype.get=Yoe,li.prototype.has=Goe,li.prototype.set=Joe;function Zs(d){var h=-1,x=d==null?0:d.length;for(this.__data__=new li;++h<x;)this.add(d[h])}function Zoe(d){return this.__data__.set(d,l),this}function Xoe(d){return this.__data__.has(d)}Zs.prototype.add=Zs.prototype.push=Zoe,Zs.prototype.has=Xoe;function ho(d){var h=this.__data__=new ai(d);this.size=h.size}function Qoe(){this.__data__=new ai,this.size=0}function eie(d){var h=this.__data__,x=h.delete(d);return this.size=h.size,x}function tie(d){return this.__data__.get(d)}function nie(d){return this.__data__.has(d)}function rie(d,h){var x=this.__data__;if(x instanceof ai){var k=x.__data__;if(!uu||k.length<o-1)return k.push([d,h]),this.size=++x.size,this;x=this.__data__=new li(k)}return x.set(d,h),this.size=x.size,this}ho.prototype.clear=Qoe,ho.prototype.delete=eie,ho.prototype.get=tie,ho.prototype.has=nie,ho.prototype.set=rie;function KN(d,h){var x=it(d),k=!x&&na(d),D=!x&&!k&&as(d),j=!x&&!k&&!D&&yl(d),U=x||k||D||j,X=U?H1(d.length,poe):[],ie=X.length;for(var Ce in d)(h||Ot.call(d,Ce))&&!(U&&(Ce=="length"||D&&(Ce=="offset"||Ce=="parent")||j&&(Ce=="buffer"||Ce=="byteLength"||Ce=="byteOffset")||fi(Ce,ie)))&&X.push(Ce);return X}function YN(d){var h=d.length;return h?d[ix(0,h-1)]:n}function oie(d,h){return ph(gr(d),Xs(h,0,d.length))}function iie(d){return ph(gr(d))}function G1(d,h,x){(x!==n&&!go(d[h],x)||x===n&&!(h in d))&&ci(d,h,x)}function hu(d,h,x){var k=d[h];(!(Ot.call(d,h)&&go(k,x))||x===n&&!(h in d))&&ci(d,h,x)}function eh(d,h){for(var x=d.length;x--;)if(go(d[x][0],h))return x;return-1}function sie(d,h,x,k){return ns(d,function(D,j,U){h(k,D,x(D),U)}),k}function GN(d,h){return d&&Bo(h,Dn(h),d)}function aie(d,h){return d&&Bo(h,yr(h),d)}function ci(d,h,x){h=="__proto__"&&Yp?Yp(d,h,{configurable:!0,enumerable:!0,value:x,writable:!0}):d[h]=x}function J1(d,h){for(var x=-1,k=h.length,D=pe(k),j=d==null;++x<k;)D[x]=j?n:Ax(d,h[x]);return D}function Xs(d,h,x){return d===d&&(x!==n&&(d=d<=x?d:x),h!==n&&(d=d>=h?d:h)),d}function Jr(d,h,x,k,D,j){var U,X=h&p,ie=h&g,Ce=h&m;if(x&&(U=D?x(d,k,D,j):x(d)),U!==n)return U;if(!nn(d))return d;var we=it(d);if(we){if(U=Gie(d),!X)return gr(d,U)}else{var Ee=Gn(d),Ne=Ee==ee||Ee==se;if(as(d))return vL(d,X);if(Ee==Se||Ee==Q||Ne&&!D){if(U=ie||Ne?{}:BL(d),!X)return ie?Bie(d,aie(U,d)):$ie(d,GN(U,d))}else{if(!Ht[Ee])return D?d:{};U=Jie(d,Ee,X)}}j||(j=new ho);var We=j.get(d);if(We)return We;j.set(d,U),pF(d)?d.forEach(function(tt){U.add(Jr(tt,h,x,tt,d,j))}):dF(d)&&d.forEach(function(tt,ht){U.set(ht,Jr(tt,h,x,ht,d,j))});var et=Ce?ie?mx:gx:ie?yr:Dn,ut=we?n:et(d);return Kr(ut||d,function(tt,ht){ut&&(ht=tt,tt=d[ht]),hu(U,ht,Jr(tt,h,x,ht,d,j))}),U}function lie(d){var h=Dn(d);return function(x){return JN(x,d,h)}}function JN(d,h,x){var k=x.length;if(d==null)return!k;for(d=Bt(d);k--;){var D=x[k],j=h[D],U=d[D];if(U===n&&!(D in d)||!j(U))return!1}return!0}function ZN(d,h,x){if(typeof d!="function")throw new Yr(s);return Su(function(){d.apply(n,x)},h)}function gu(d,h,x,k){var D=-1,j=$p,U=!0,X=d.length,ie=[],Ce=h.length;if(!X)return ie;x&&(h=Qt(h,kr(x))),k?(j=F1,U=!1):h.length>=o&&(j=lu,U=!1,h=new Zs(h));e:for(;++D<X;){var we=d[D],Ee=x==null?we:x(we);if(we=k||we!==0?we:0,U&&Ee===Ee){for(var Ne=Ce;Ne--;)if(h[Ne]===Ee)continue e;ie.push(we)}else j(h,Ee,k)||ie.push(we)}return ie}var ns=_L($o),XN=_L(X1,!0);function cie(d,h){var x=!0;return ns(d,function(k,D,j){return x=!!h(k,D,j),x}),x}function th(d,h,x){for(var k=-1,D=d.length;++k<D;){var j=d[k],U=h(j);if(U!=null&&(X===n?U===U&&!Mr(U):x(U,X)))var X=U,ie=j}return ie}function uie(d,h,x,k){var D=d.length;for(x=st(x),x<0&&(x=-x>D?0:D+x),k=k===n||k>D?D:st(k),k<0&&(k+=D),k=x>k?0:gF(k);x<k;)d[x++]=h;return d}function QN(d,h){var x=[];return ns(d,function(k,D,j){h(k,D,j)&&x.push(k)}),x}function Rn(d,h,x,k,D){var j=-1,U=d.length;for(x||(x=Xie),D||(D=[]);++j<U;){var X=d[j];h>0&&x(X)?h>1?Rn(X,h-1,x,k,D):Qi(D,X):k||(D[D.length]=X)}return D}var Z1=TL(),eL=TL(!0);function $o(d,h){return d&&Z1(d,h,Dn)}function X1(d,h){return d&&eL(d,h,Dn)}function nh(d,h){return Xi(h,function(x){return pi(d[x])})}function Qs(d,h){h=is(h,d);for(var x=0,k=h.length;d!=null&&x<k;)d=d[Ro(h[x++])];return x&&x==k?d:n}function tL(d,h,x){var k=h(d);return it(d)?k:Qi(k,x(d))}function or(d){return d==null?d===n?Ct:_e:Gs&&Gs in Bt(d)?Uie(d):ise(d)}function Q1(d,h){return d>h}function die(d,h){return d!=null&&Ot.call(d,h)}function fie(d,h){return d!=null&&h in Bt(d)}function pie(d,h,x){return d>=Yn(h,x)&&d<wn(h,x)}function ex(d,h,x){for(var k=x?F1:$p,D=d[0].length,j=d.length,U=j,X=pe(j),ie=1/0,Ce=[];U--;){var we=d[U];U&&h&&(we=Qt(we,kr(h))),ie=Yn(we.length,ie),X[U]=!x&&(h||D>=120&&we.length>=120)?new Zs(U&&we):n}we=d[0];var Ee=-1,Ne=X[0];e:for(;++Ee<D&&Ce.length<ie;){var We=we[Ee],et=h?h(We):We;if(We=x||We!==0?We:0,!(Ne?lu(Ne,et):k(Ce,et,x))){for(U=j;--U;){var ut=X[U];if(!(ut?lu(ut,et):k(d[U],et,x)))continue e}Ne&&Ne.push(et),Ce.push(We)}}return Ce}function hie(d,h,x,k){return $o(d,function(D,j,U){h(k,x(D),j,U)}),k}function mu(d,h,x){h=is(h,d),d=HL(d,h);var k=d==null?d:d[Ro(Xr(h))];return k==null?n:Tr(k,d,x)}function nL(d){return dn(d)&&or(d)==Q}function gie(d){return dn(d)&&or(d)==un}function mie(d){return dn(d)&&or(d)==W}function yu(d,h,x,k,D){return d===h?!0:d==null||h==null||!dn(d)&&!dn(h)?d!==d&&h!==h:yie(d,h,x,k,yu,D)}function yie(d,h,x,k,D,j){var U=it(d),X=it(h),ie=U?fe:Gn(d),Ce=X?fe:Gn(h);ie=ie==Q?Se:ie,Ce=Ce==Q?Se:Ce;var we=ie==Se,Ee=Ce==Se,Ne=ie==Ce;if(Ne&&as(d)){if(!as(h))return!1;U=!0,we=!1}if(Ne&&!we)return j||(j=new ho),U||yl(d)?LL(d,h,x,k,D,j):Wie(d,h,ie,x,k,D,j);if(!(x&y)){var We=we&&Ot.call(d,"__wrapped__"),et=Ee&&Ot.call(h,"__wrapped__");if(We||et){var ut=We?d.value():d,tt=et?h.value():h;return j||(j=new ho),D(ut,tt,x,k,j)}}return Ne?(j||(j=new ho),qie(d,h,x,k,D,j)):!1}function bie(d){return dn(d)&&Gn(d)==de}function tx(d,h,x,k){var D=x.length,j=D,U=!k;if(d==null)return!j;for(d=Bt(d);D--;){var X=x[D];if(U&&X[2]?X[1]!==d[X[0]]:!(X[0]in d))return!1}for(;++D<j;){X=x[D];var ie=X[0],Ce=d[ie],we=X[1];if(U&&X[2]){if(Ce===n&&!(ie in d))return!1}else{var Ee=new ho;if(k)var Ne=k(Ce,we,ie,d,h,Ee);if(!(Ne===n?yu(we,Ce,y|b,k,Ee):Ne))return!1}}return!0}function rL(d){if(!nn(d)||ese(d))return!1;var h=pi(d)?boe:lre;return h.test(ta(d))}function vie(d){return dn(d)&&or(d)==je}function xie(d){return dn(d)&&Gn(d)==Je}function Sie(d){return dn(d)&&vh(d.length)&&!!Gt[or(d)]}function oL(d){return typeof d=="function"?d:d==null?br:typeof d=="object"?it(d)?aL(d[0],d[1]):sL(d):kF(d)}function nx(d){if(!xu(d))return _oe(d);var h=[];for(var x in Bt(d))Ot.call(d,x)&&x!="constructor"&&h.push(x);return h}function Cie(d){if(!nn(d))return ose(d);var h=xu(d),x=[];for(var k in d)k=="constructor"&&(h||!Ot.call(d,k))||x.push(k);return x}function rx(d,h){return d<h}function iL(d,h){var x=-1,k=mr(d)?pe(d.length):[];return ns(d,function(D,j,U){k[++x]=h(D,j,U)}),k}function sL(d){var h=bx(d);return h.length==1&&h[0][2]?zL(h[0][0],h[0][1]):function(x){return x===d||tx(x,d,h)}}function aL(d,h){return xx(d)&&RL(h)?zL(Ro(d),h):function(x){var k=Ax(x,d);return k===n&&k===h?Ix(x,d):yu(h,k,y|b)}}function rh(d,h,x,k,D){d!==h&&Z1(h,function(j,U){if(D||(D=new ho),nn(j))wie(d,h,U,x,rh,k,D);else{var X=k?k(Cx(d,U),j,U+"",d,h,D):n;X===n&&(X=j),G1(d,U,X)}},yr)}function wie(d,h,x,k,D,j,U){var X=Cx(d,x),ie=Cx(h,x),Ce=U.get(ie);if(Ce){G1(d,x,Ce);return}var we=j?j(X,ie,x+"",d,h,U):n,Ee=we===n;if(Ee){var Ne=it(ie),We=!Ne&&as(ie),et=!Ne&&!We&&yl(ie);we=ie,Ne||We||et?it(X)?we=X:hn(X)?we=gr(X):We?(Ee=!1,we=vL(ie,!0)):et?(Ee=!1,we=xL(ie,!0)):we=[]:Cu(ie)||na(ie)?(we=X,na(X)?we=mF(X):(!nn(X)||pi(X))&&(we=BL(ie))):Ee=!1}Ee&&(U.set(ie,we),D(we,ie,k,j,U),U.delete(ie)),G1(d,x,we)}function lL(d,h){var x=d.length;if(x)return h+=h<0?x:0,fi(h,x)?d[h]:n}function cL(d,h,x){h.length?h=Qt(h,function(j){return it(j)?function(U){return Qs(U,j.length===1?j[0]:j)}:j}):h=[br];var k=-1;h=Qt(h,kr(Xe()));var D=iL(d,function(j,U,X){var ie=Qt(h,function(Ce){return Ce(j)});return{criteria:ie,index:++k,value:j}});return Jre(D,function(j,U){return Fie(j,U,x)})}function _ie(d,h){return uL(d,h,function(x,k){return Ix(d,k)})}function uL(d,h,x){for(var k=-1,D=h.length,j={};++k<D;){var U=h[k],X=Qs(d,U);x(X,U)&&bu(j,is(U,d),X)}return j}function Tie(d){return function(h){return Qs(h,d)}}function ox(d,h,x,k){var D=k?Gre:sl,j=-1,U=h.length,X=d;for(d===h&&(h=gr(h)),x&&(X=Qt(d,kr(x)));++j<U;)for(var ie=0,Ce=h[j],we=x?x(Ce):Ce;(ie=D(X,we,ie,k))>-1;)X!==d&&Kp.call(X,ie,1),Kp.call(d,ie,1);return d}function dL(d,h){for(var x=d?h.length:0,k=x-1;x--;){var D=h[x];if(x==k||D!==j){var j=D;fi(D)?Kp.call(d,D,1):lx(d,D)}}return d}function ix(d,h){return d+Jp(qN()*(h-d+1))}function kie(d,h,x,k){for(var D=-1,j=wn(Gp((h-d)/(x||1)),0),U=pe(j);j--;)U[k?j:++D]=d,d+=x;return U}function sx(d,h){var x="";if(!d||h<1||h>K)return x;do h%2&&(x+=d),h=Jp(h/2),h&&(d+=d);while(h);return x}function dt(d,h){return wx(VL(d,h,br),d+"")}function Eie(d){return YN(bl(d))}function Mie(d,h){var x=bl(d);return ph(x,Xs(h,0,x.length))}function bu(d,h,x,k){if(!nn(d))return d;h=is(h,d);for(var D=-1,j=h.length,U=j-1,X=d;X!=null&&++D<j;){var ie=Ro(h[D]),Ce=x;if(ie==="__proto__"||ie==="constructor"||ie==="prototype")return d;if(D!=U){var we=X[ie];Ce=k?k(we,ie,X):n,Ce===n&&(Ce=nn(we)?we:fi(h[D+1])?[]:{})}hu(X,ie,Ce),X=X[ie]}return d}var fL=Zp?function(d,h){return Zp.set(d,h),d}:br,Oie=Yp?function(d,h){return Yp(d,"toString",{configurable:!0,enumerable:!1,value:Px(h),writable:!0})}:br;function Aie(d){return ph(bl(d))}function Zr(d,h,x){var k=-1,D=d.length;h<0&&(h=-h>D?0:D+h),x=x>D?D:x,x<0&&(x+=D),D=h>x?0:x-h>>>0,h>>>=0;for(var j=pe(D);++k<D;)j[k]=d[k+h];return j}function Iie(d,h){var x;return ns(d,function(k,D,j){return x=h(k,D,j),!x}),!!x}function oh(d,h,x){var k=0,D=d==null?k:d.length;if(typeof h=="number"&&h===h&&D<=he){for(;k<D;){var j=k+D>>>1,U=d[j];U!==null&&!Mr(U)&&(x?U<=h:U<h)?k=j+1:D=j}return D}return ax(d,h,br,x)}function ax(d,h,x,k){var D=0,j=d==null?0:d.length;if(j===0)return 0;h=x(h);for(var U=h!==h,X=h===null,ie=Mr(h),Ce=h===n;D<j;){var we=Jp((D+j)/2),Ee=x(d[we]),Ne=Ee!==n,We=Ee===null,et=Ee===Ee,ut=Mr(Ee);if(U)var tt=k||et;else Ce?tt=et&&(k||Ne):X?tt=et&&Ne&&(k||!We):ie?tt=et&&Ne&&!We&&(k||!ut):We||ut?tt=!1:tt=k?Ee<=h:Ee<h;tt?D=we+1:j=we}return Yn(j,me)}function pL(d,h){for(var x=-1,k=d.length,D=0,j=[];++x<k;){var U=d[x],X=h?h(U):U;if(!x||!go(X,ie)){var ie=X;j[D++]=U===0?0:U}}return j}function hL(d){return typeof d=="number"?d:Mr(d)?Y:+d}function Er(d){if(typeof d=="string")return d;if(it(d))return Qt(d,Er)+"";if(Mr(d))return UN?UN.call(d):"";var h=d+"";return h=="0"&&1/d==-q?"-0":h}function rs(d,h,x){var k=-1,D=$p,j=d.length,U=!0,X=[],ie=X;if(x)U=!1,D=F1;else if(j>=o){var Ce=h?null:Hie(d);if(Ce)return Rp(Ce);U=!1,D=lu,ie=new Zs}else ie=h?[]:X;e:for(;++k<j;){var we=d[k],Ee=h?h(we):we;if(we=x||we!==0?we:0,U&&Ee===Ee){for(var Ne=ie.length;Ne--;)if(ie[Ne]===Ee)continue e;h&&ie.push(Ee),X.push(we)}else D(ie,Ee,x)||(ie!==X&&ie.push(Ee),X.push(we))}return X}function lx(d,h){return h=is(h,d),d=HL(d,h),d==null||delete d[Ro(Xr(h))]}function gL(d,h,x,k){return bu(d,h,x(Qs(d,h)),k)}function ih(d,h,x,k){for(var D=d.length,j=k?D:-1;(k?j--:++j<D)&&h(d[j],j,d););return x?Zr(d,k?0:j,k?j+1:D):Zr(d,k?j+1:0,k?D:j)}function mL(d,h){var x=d;return x instanceof mt&&(x=x.value()),$1(h,function(k,D){return D.func.apply(D.thisArg,Qi([k],D.args))},x)}function cx(d,h,x){var k=d.length;if(k<2)return k?rs(d[0]):[];for(var D=-1,j=pe(k);++D<k;)for(var U=d[D],X=-1;++X<k;)X!=D&&(j[D]=gu(j[D]||U,d[X],h,x));return rs(Rn(j,1),h,x)}function yL(d,h,x){for(var k=-1,D=d.length,j=h.length,U={};++k<D;){var X=k<j?h[k]:n;x(U,d[k],X)}return U}function ux(d){return hn(d)?d:[]}function dx(d){return typeof d=="function"?d:br}function is(d,h){return it(d)?d:xx(d,h)?[d]:UL(Mt(d))}var Die=dt;function ss(d,h,x){var k=d.length;return x=x===n?k:x,!h&&x>=k?d:Zr(d,h,x)}var bL=voe||function(d){return Bn.clearTimeout(d)};function vL(d,h){if(h)return d.slice();var x=d.length,k=zN?zN(x):new d.constructor(x);return d.copy(k),k}function fx(d){var h=new d.constructor(d.byteLength);return new qp(h).set(new qp(d)),h}function Pie(d,h){var x=h?fx(d.buffer):d.buffer;return new d.constructor(x,d.byteOffset,d.byteLength)}function Nie(d){var h=new d.constructor(d.source,nN.exec(d));return h.lastIndex=d.lastIndex,h}function Lie(d){return pu?Bt(pu.call(d)):{}}function xL(d,h){var x=h?fx(d.buffer):d.buffer;return new d.constructor(x,d.byteOffset,d.length)}function SL(d,h){if(d!==h){var x=d!==n,k=d===null,D=d===d,j=Mr(d),U=h!==n,X=h===null,ie=h===h,Ce=Mr(h);if(!X&&!Ce&&!j&&d>h||j&&U&&ie&&!X&&!Ce||k&&U&&ie||!x&&ie||!D)return 1;if(!k&&!j&&!Ce&&d<h||Ce&&x&&D&&!k&&!j||X&&x&&D||!U&&D||!ie)return-1}return 0}function Fie(d,h,x){for(var k=-1,D=d.criteria,j=h.criteria,U=D.length,X=x.length;++k<U;){var ie=SL(D[k],j[k]);if(ie){if(k>=X)return ie;var Ce=x[k];return ie*(Ce=="desc"?-1:1)}}return d.index-h.index}function CL(d,h,x,k){for(var D=-1,j=d.length,U=x.length,X=-1,ie=h.length,Ce=wn(j-U,0),we=pe(ie+Ce),Ee=!k;++X<ie;)we[X]=h[X];for(;++D<U;)(Ee||D<j)&&(we[x[D]]=d[D]);for(;Ce--;)we[X++]=d[D++];return we}function wL(d,h,x,k){for(var D=-1,j=d.length,U=-1,X=x.length,ie=-1,Ce=h.length,we=wn(j-X,0),Ee=pe(we+Ce),Ne=!k;++D<we;)Ee[D]=d[D];for(var We=D;++ie<Ce;)Ee[We+ie]=h[ie];for(;++U<X;)(Ne||D<j)&&(Ee[We+x[U]]=d[D++]);return Ee}function gr(d,h){var x=-1,k=d.length;for(h||(h=pe(k));++x<k;)h[x]=d[x];return h}function Bo(d,h,x,k){var D=!x;x||(x={});for(var j=-1,U=h.length;++j<U;){var X=h[j],ie=k?k(x[X],d[X],X,x,d):n;ie===n&&(ie=d[X]),D?ci(x,X,ie):hu(x,X,ie)}return x}function $ie(d,h){return Bo(d,vx(d),h)}function Bie(d,h){return Bo(d,FL(d),h)}function sh(d,h){return function(x,k){var D=it(x)?jre:sie,j=h?h():{};return D(x,d,Xe(k,2),j)}}function hl(d){return dt(function(h,x){var k=-1,D=x.length,j=D>1?x[D-1]:n,U=D>2?x[2]:n;for(j=d.length>3&&typeof j=="function"?(D--,j):n,U&&ir(x[0],x[1],U)&&(j=D<3?n:j,D=1),h=Bt(h);++k<D;){var X=x[k];X&&d(h,X,k,j)}return h})}function _L(d,h){return function(x,k){if(x==null)return x;if(!mr(x))return d(x,k);for(var D=x.length,j=h?D:-1,U=Bt(x);(h?j--:++j<D)&&k(U[j],j,U)!==!1;);return x}}function TL(d){return function(h,x,k){for(var D=-1,j=Bt(h),U=k(h),X=U.length;X--;){var ie=U[d?X:++D];if(x(j[ie],ie,j)===!1)break}return h}}function Rie(d,h,x){var k=h&S,D=vu(d);function j(){var U=this&&this!==Bn&&this instanceof j?D:d;return U.apply(k?x:this,arguments)}return j}function kL(d){return function(h){h=Mt(h);var x=al(h)?po(h):n,k=x?x[0]:h.charAt(0),D=x?ss(x,1).join(""):h.slice(1);return k[d]()+D}}function gl(d){return function(h){return $1(_F(wF(h).replace(Ore,"")),d,"")}}function vu(d){return function(){var h=arguments;switch(h.length){case 0:return new d;case 1:return new d(h[0]);case 2:return new d(h[0],h[1]);case 3:return new d(h[0],h[1],h[2]);case 4:return new d(h[0],h[1],h[2],h[3]);case 5:return new d(h[0],h[1],h[2],h[3],h[4]);case 6:return new d(h[0],h[1],h[2],h[3],h[4],h[5]);case 7:return new d(h[0],h[1],h[2],h[3],h[4],h[5],h[6])}var x=pl(d.prototype),k=d.apply(x,h);return nn(k)?k:x}}function zie(d,h,x){var k=vu(d);function D(){for(var j=arguments.length,U=pe(j),X=j,ie=ml(D);X--;)U[X]=arguments[X];var Ce=j<3&&U[0]!==ie&&U[j-1]!==ie?[]:es(U,ie);if(j-=Ce.length,j<x)return IL(d,h,ah,D.placeholder,n,U,Ce,n,n,x-j);var we=this&&this!==Bn&&this instanceof D?k:d;return Tr(we,this,U)}return D}function EL(d){return function(h,x,k){var D=Bt(h);if(!mr(h)){var j=Xe(x,3);h=Dn(h),x=function(X){return j(D[X],X,D)}}var U=d(h,x,k);return U>-1?D[j?h[U]:U]:n}}function ML(d){return di(function(h){var x=h.length,k=x,D=Gr.prototype.thru;for(d&&h.reverse();k--;){var j=h[k];if(typeof j!="function")throw new Yr(s);if(D&&!U&&dh(j)=="wrapper")var U=new Gr([],!0)}for(k=U?k:x;++k<x;){j=h[k];var X=dh(j),ie=X=="wrapper"?yx(j):n;ie&&Sx(ie[0])&&ie[1]==(L|_|E|P)&&!ie[4].length&&ie[9]==1?U=U[dh(ie[0])].apply(U,ie[3]):U=j.length==1&&Sx(j)?U[X]():U.thru(j)}return function(){var Ce=arguments,we=Ce[0];if(U&&Ce.length==1&&it(we))return U.plant(we).value();for(var Ee=0,Ne=x?h[Ee].apply(this,Ce):we;++Ee<x;)Ne=h[Ee].call(this,Ne);return Ne}})}function ah(d,h,x,k,D,j,U,X,ie,Ce){var we=h&L,Ee=h&S,Ne=h&C,We=h&(_|w),et=h&$,ut=Ne?n:vu(d);function tt(){for(var ht=arguments.length,xt=pe(ht),Or=ht;Or--;)xt[Or]=arguments[Or];if(We)var sr=ml(tt),Ar=Xre(xt,sr);if(k&&(xt=CL(xt,k,D,We)),j&&(xt=wL(xt,j,U,We)),ht-=Ar,We&&ht<Ce){var gn=es(xt,sr);return IL(d,h,ah,tt.placeholder,x,xt,gn,X,ie,Ce-ht)}var mo=Ee?x:this,gi=Ne?mo[d]:d;return ht=xt.length,X?xt=sse(xt,X):et&&ht>1&&xt.reverse(),we&&ie<ht&&(xt.length=ie),this&&this!==Bn&&this instanceof tt&&(gi=ut||vu(gi)),gi.apply(mo,xt)}return tt}function OL(d,h){return function(x,k){return hie(x,d,h(k),{})}}function lh(d,h){return function(x,k){var D;if(x===n&&k===n)return h;if(x!==n&&(D=x),k!==n){if(D===n)return k;typeof x=="string"||typeof k=="string"?(x=Er(x),k=Er(k)):(x=hL(x),k=hL(k)),D=d(x,k)}return D}}function px(d){return di(function(h){return h=Qt(h,kr(Xe())),dt(function(x){var k=this;return d(h,function(D){return Tr(D,k,x)})})})}function ch(d,h){h=h===n?" ":Er(h);var x=h.length;if(x<2)return x?sx(h,d):h;var k=sx(h,Gp(d/ll(h)));return al(h)?ss(po(k),0,d).join(""):k.slice(0,d)}function Vie(d,h,x,k){var D=h&S,j=vu(d);function U(){for(var X=-1,ie=arguments.length,Ce=-1,we=k.length,Ee=pe(we+ie),Ne=this&&this!==Bn&&this instanceof U?j:d;++Ce<we;)Ee[Ce]=k[Ce];for(;ie--;)Ee[Ce++]=arguments[++X];return Tr(Ne,D?x:this,Ee)}return U}function AL(d){return function(h,x,k){return k&&typeof k!="number"&&ir(h,x,k)&&(x=k=n),h=hi(h),x===n?(x=h,h=0):x=hi(x),k=k===n?h<x?1:-1:hi(k),kie(h,x,k,d)}}function uh(d){return function(h,x){return typeof h=="string"&&typeof x=="string"||(h=Qr(h),x=Qr(x)),d(h,x)}}function IL(d,h,x,k,D,j,U,X,ie,Ce){var we=h&_,Ee=we?U:n,Ne=we?n:U,We=we?j:n,et=we?n:j;h|=we?E:O,h&=~(we?O:E),h&T||(h&=~(S|C));var ut=[d,h,D,We,Ee,et,Ne,X,ie,Ce],tt=x.apply(n,ut);return Sx(d)&&jL(tt,ut),tt.placeholder=k,WL(tt,d,h)}function hx(d){var h=Cn[d];return function(x,k){if(x=Qr(x),k=k==null?0:Yn(st(k),292),k&&WN(x)){var D=(Mt(x)+"e").split("e"),j=h(D[0]+"e"+(+D[1]+k));return D=(Mt(j)+"e").split("e"),+(D[0]+"e"+(+D[1]-k))}return h(x)}}var Hie=dl&&1/Rp(new dl([,-0]))[1]==q?function(d){return new dl(d)}:Fx;function DL(d){return function(h){var x=Gn(h);return x==de?W1(h):x==Je?ioe(h):Zre(h,d(h))}}function ui(d,h,x,k,D,j,U,X){var ie=h&C;if(!ie&&typeof d!="function")throw new Yr(s);var Ce=k?k.length:0;if(Ce||(h&=~(E|O),k=D=n),U=U===n?U:wn(st(U),0),X=X===n?X:st(X),Ce-=D?D.length:0,h&O){var we=k,Ee=D;k=D=n}var Ne=ie?n:yx(d),We=[d,h,x,k,D,we,Ee,j,U,X];if(Ne&&rse(We,Ne),d=We[0],h=We[1],x=We[2],k=We[3],D=We[4],X=We[9]=We[9]===n?ie?0:d.length:wn(We[9]-Ce,0),!X&&h&(_|w)&&(h&=~(_|w)),!h||h==S)var et=Rie(d,h,x);else h==_||h==w?et=zie(d,h,X):(h==E||h==(S|E))&&!D.length?et=Vie(d,h,x,k):et=ah.apply(n,We);var ut=Ne?fL:jL;return WL(ut(et,We),d,h)}function PL(d,h,x,k){return d===n||go(d,ul[x])&&!Ot.call(k,x)?h:d}function NL(d,h,x,k,D,j){return nn(d)&&nn(h)&&(j.set(h,d),rh(d,h,n,NL,j),j.delete(h)),d}function jie(d){return Cu(d)?n:d}function LL(d,h,x,k,D,j){var U=x&y,X=d.length,ie=h.length;if(X!=ie&&!(U&&ie>X))return!1;var Ce=j.get(d),we=j.get(h);if(Ce&&we)return Ce==h&&we==d;var Ee=-1,Ne=!0,We=x&b?new Zs:n;for(j.set(d,h),j.set(h,d);++Ee<X;){var et=d[Ee],ut=h[Ee];if(k)var tt=U?k(ut,et,Ee,h,d,j):k(et,ut,Ee,d,h,j);if(tt!==n){if(tt)continue;Ne=!1;break}if(We){if(!B1(h,function(ht,xt){if(!lu(We,xt)&&(et===ht||D(et,ht,x,k,j)))return We.push(xt)})){Ne=!1;break}}else if(!(et===ut||D(et,ut,x,k,j))){Ne=!1;break}}return j.delete(d),j.delete(h),Ne}function Wie(d,h,x,k,D,j,U){switch(x){case $t:if(d.byteLength!=h.byteLength||d.byteOffset!=h.byteOffset)return!1;d=d.buffer,h=h.buffer;case un:return!(d.byteLength!=h.byteLength||!j(new qp(d),new qp(h)));case ae:case W:case ye:return go(+d,+h);case ue:return d.name==h.name&&d.message==h.message;case je:case De:return d==h+"";case de:var X=W1;case Je:var ie=k&y;if(X||(X=Rp),d.size!=h.size&&!ie)return!1;var Ce=U.get(d);if(Ce)return Ce==h;k|=b,U.set(d,h);var we=LL(X(d),X(h),k,D,j,U);return U.delete(d),we;case ct:if(pu)return pu.call(d)==pu.call(h)}return!1}function qie(d,h,x,k,D,j){var U=x&y,X=gx(d),ie=X.length,Ce=gx(h),we=Ce.length;if(ie!=we&&!U)return!1;for(var Ee=ie;Ee--;){var Ne=X[Ee];if(!(U?Ne in h:Ot.call(h,Ne)))return!1}var We=j.get(d),et=j.get(h);if(We&&et)return We==h&&et==d;var ut=!0;j.set(d,h),j.set(h,d);for(var tt=U;++Ee<ie;){Ne=X[Ee];var ht=d[Ne],xt=h[Ne];if(k)var Or=U?k(xt,ht,Ne,h,d,j):k(ht,xt,Ne,d,h,j);if(!(Or===n?ht===xt||D(ht,xt,x,k,j):Or)){ut=!1;break}tt||(tt=Ne=="constructor")}if(ut&&!tt){var sr=d.constructor,Ar=h.constructor;sr!=Ar&&"constructor"in d&&"constructor"in h&&!(typeof sr=="function"&&sr instanceof sr&&typeof Ar=="function"&&Ar instanceof Ar)&&(ut=!1)}return j.delete(d),j.delete(h),ut}function di(d){return wx(VL(d,n,JL),d+"")}function gx(d){return tL(d,Dn,vx)}function mx(d){return tL(d,yr,FL)}var yx=Zp?function(d){return Zp.get(d)}:Fx;function dh(d){for(var h=d.name+"",x=fl[h],k=Ot.call(fl,h)?x.length:0;k--;){var D=x[k],j=D.func;if(j==null||j==d)return D.name}return h}function ml(d){var h=Ot.call(H,"placeholder")?H:d;return h.placeholder}function Xe(){var d=H.iteratee||Nx;return d=d===Nx?oL:d,arguments.length?d(arguments[0],arguments[1]):d}function fh(d,h){var x=d.__data__;return Qie(h)?x[typeof h=="string"?"string":"hash"]:x.map}function bx(d){for(var h=Dn(d),x=h.length;x--;){var k=h[x],D=d[k];h[x]=[k,D,RL(D)]}return h}function ea(d,h){var x=noe(d,h);return rL(x)?x:n}function Uie(d){var h=Ot.call(d,Gs),x=d[Gs];try{d[Gs]=n;var k=!0}catch{}var D=jp.call(d);return k&&(h?d[Gs]=x:delete d[Gs]),D}var vx=U1?function(d){return d==null?[]:(d=Bt(d),Xi(U1(d),function(h){return HN.call(d,h)}))}:$x,FL=U1?function(d){for(var h=[];d;)Qi(h,vx(d)),d=Up(d);return h}:$x,Gn=or;(K1&&Gn(new K1(new ArrayBuffer(1)))!=$t||uu&&Gn(new uu)!=de||Y1&&Gn(Y1.resolve())!=Me||dl&&Gn(new dl)!=Je||du&&Gn(new du)!=Xt)&&(Gn=function(d){var h=or(d),x=h==Se?d.constructor:n,k=x?ta(x):"";if(k)switch(k){case Moe:return $t;case Ooe:return de;case Aoe:return Me;case Ioe:return Je;case Doe:return Xt}return h});function Kie(d,h,x){for(var k=-1,D=x.length;++k<D;){var j=x[k],U=j.size;switch(j.type){case"drop":d+=U;break;case"dropRight":h-=U;break;case"take":h=Yn(h,d+U);break;case"takeRight":d=wn(d,h-U);break}}return{start:d,end:h}}function Yie(d){var h=d.match(ere);return h?h[1].split(tre):[]}function $L(d,h,x){h=is(h,d);for(var k=-1,D=h.length,j=!1;++k<D;){var U=Ro(h[k]);if(!(j=d!=null&&x(d,U)))break;d=d[U]}return j||++k!=D?j:(D=d==null?0:d.length,!!D&&vh(D)&&fi(U,D)&&(it(d)||na(d)))}function Gie(d){var h=d.length,x=new d.constructor(h);return h&&typeof d[0]=="string"&&Ot.call(d,"index")&&(x.index=d.index,x.input=d.input),x}function BL(d){return typeof d.constructor=="function"&&!xu(d)?pl(Up(d)):{}}function Jie(d,h,x){var k=d.constructor;switch(h){case un:return fx(d);case ae:case W:return new k(+d);case $t:return Pie(d,x);case In:case Kn:case ft:case $n:case Yt:case ge:case $e:case ke:case Re:return xL(d,x);case de:return new k;case ye:case De:return new k(d);case je:return Nie(d);case Je:return new k;case ct:return Lie(d)}}function Zie(d,h){var x=h.length;if(!x)return d;var k=x-1;return h[k]=(x>1?"& ":"")+h[k],h=h.join(x>2?", ":" "),d.replace(Qne,`{
|
|
86
|
+
*/var MB=Nl.exports,pC;function OB(){return pC||(pC=1,function(t,e){(function(){var n,r="4.17.21",o=200,i="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",s="Expected a function",a="Invalid `variable` option passed into `_.template`",l="__lodash_hash_undefined__",u=500,f="__lodash_placeholder__",p=1,g=2,m=4,y=1,b=2,S=1,C=2,T=4,_=8,w=16,E=32,O=64,L=128,P=256,$=512,M=30,A="...",N=800,z=16,V=1,B=2,R=3,q=1/0,U=9007199254740991,G=17976931348623157e292,Y=NaN,Z=4294967295,fe=Z-1,pe=Z>>>1,me=[["ary",L],["bind",S],["bindKey",C],["curry",_],["curryRight",w],["flip",$],["partial",E],["partialRight",O],["rearg",P]],re="[object Arguments]",he="[object Array]",le="[object AsyncFunction]",X="[object Boolean]",W="[object Date]",ee="[object DOMException]",ce="[object Error]",te="[object Function]",se="[object GeneratorFunction]",ue="[object Map]",ye="[object Number]",_e="[object Null]",Se="[object Object]",Me="[object Promise]",Fe="[object Proxy]",je="[object RegExp]",Je="[object Set]",De="[object String]",ct="[object Symbol]",Ct="[object Undefined]",Xt="[object WeakMap]",Sn="[object WeakSet]",un="[object ArrayBuffer]",$t="[object DataView]",In="[object Float32Array]",Kn="[object Float64Array]",ft="[object Int8Array]",$n="[object Int16Array]",Yt="[object Int32Array]",ge="[object Uint8Array]",$e="[object Uint8ClampedArray]",ke="[object Uint16Array]",Re="[object Uint32Array]",Ge=/\b__p \+= '';/g,nt=/\b(__p \+=) '' \+/g,Pt=/(__e\(.*?\)|\b__t\)) \+\n'';/g,rr=/&(?:amp|lt|gt|quot|#39);/g,hr=/[&<>"']/g,si=RegExp(rr.source),su=RegExp(hr.source),rl=/<%-([\s\S]+?)%>/g,Zi=/<%([\s\S]+?)%>/g,Pp=/<%=([\s\S]+?)%>/g,au=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,ol=/^\w*$/,Jne=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,E1=/[\\^$.*+?()[\]{}|]/g,Zne=RegExp(E1.source),M1=/^\s+/,Xne=/\s/,Qne=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,ere=/\{\n\/\* \[wrapped with (.+)\] \*/,tre=/,? & /,nre=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,rre=/[()=,{}\[\]\/\s]/,ore=/\\(\\)?/g,ire=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,nN=/\w*$/,sre=/^[-+]0x[0-9a-f]+$/i,are=/^0b[01]+$/i,lre=/^\[object .+?Constructor\]$/,cre=/^0o[0-7]+$/i,ure=/^(?:0|[1-9]\d*)$/,dre=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Np=/($^)/,fre=/['\n\r\u2028\u2029\\]/g,Lp="\\ud800-\\udfff",pre="\\u0300-\\u036f",hre="\\ufe20-\\ufe2f",gre="\\u20d0-\\u20ff",rN=pre+hre+gre,oN="\\u2700-\\u27bf",iN="a-z\\xdf-\\xf6\\xf8-\\xff",mre="\\xac\\xb1\\xd7\\xf7",yre="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",bre="\\u2000-\\u206f",vre=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",sN="A-Z\\xc0-\\xd6\\xd8-\\xde",aN="\\ufe0e\\ufe0f",lN=mre+yre+bre+vre,O1="['’]",xre="["+Lp+"]",cN="["+lN+"]",Fp="["+rN+"]",uN="\\d+",Sre="["+oN+"]",dN="["+iN+"]",fN="[^"+Lp+lN+uN+oN+iN+sN+"]",A1="\\ud83c[\\udffb-\\udfff]",Cre="(?:"+Fp+"|"+A1+")",pN="[^"+Lp+"]",I1="(?:\\ud83c[\\udde6-\\uddff]){2}",D1="[\\ud800-\\udbff][\\udc00-\\udfff]",il="["+sN+"]",hN="\\u200d",gN="(?:"+dN+"|"+fN+")",wre="(?:"+il+"|"+fN+")",mN="(?:"+O1+"(?:d|ll|m|re|s|t|ve))?",yN="(?:"+O1+"(?:D|LL|M|RE|S|T|VE))?",bN=Cre+"?",vN="["+aN+"]?",_re="(?:"+hN+"(?:"+[pN,I1,D1].join("|")+")"+vN+bN+")*",Tre="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",kre="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",xN=vN+bN+_re,Ere="(?:"+[Sre,I1,D1].join("|")+")"+xN,Mre="(?:"+[pN+Fp+"?",Fp,I1,D1,xre].join("|")+")",Ore=RegExp(O1,"g"),Are=RegExp(Fp,"g"),P1=RegExp(A1+"(?="+A1+")|"+Mre+xN,"g"),Ire=RegExp([il+"?"+dN+"+"+mN+"(?="+[cN,il,"$"].join("|")+")",wre+"+"+yN+"(?="+[cN,il+gN,"$"].join("|")+")",il+"?"+gN+"+"+mN,il+"+"+yN,kre,Tre,uN,Ere].join("|"),"g"),Dre=RegExp("["+hN+Lp+rN+aN+"]"),Pre=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Nre=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],Lre=-1,Gt={};Gt[In]=Gt[Kn]=Gt[ft]=Gt[$n]=Gt[Yt]=Gt[ge]=Gt[$e]=Gt[ke]=Gt[Re]=!0,Gt[re]=Gt[he]=Gt[un]=Gt[X]=Gt[$t]=Gt[W]=Gt[ce]=Gt[te]=Gt[ue]=Gt[ye]=Gt[Se]=Gt[je]=Gt[Je]=Gt[De]=Gt[Xt]=!1;var Ht={};Ht[re]=Ht[he]=Ht[un]=Ht[$t]=Ht[X]=Ht[W]=Ht[In]=Ht[Kn]=Ht[ft]=Ht[$n]=Ht[Yt]=Ht[ue]=Ht[ye]=Ht[Se]=Ht[je]=Ht[Je]=Ht[De]=Ht[ct]=Ht[ge]=Ht[$e]=Ht[ke]=Ht[Re]=!0,Ht[ce]=Ht[te]=Ht[Xt]=!1;var Fre={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},$re={"&":"&","<":"<",">":">",'"':""","'":"'"},Bre={"&":"&","<":"<",">":">",""":'"',"'":"'"},Rre={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},zre=parseFloat,Vre=parseInt,SN=typeof yi=="object"&&yi&&yi.Object===Object&&yi,Hre=typeof self=="object"&&self&&self.Object===Object&&self,Bn=SN||Hre||Function("return this")(),N1=e&&!e.nodeType&&e,Ys=N1&&!0&&t&&!t.nodeType&&t,CN=Ys&&Ys.exports===N1,L1=CN&&SN.process,Ur=function(){try{var oe=Ys&&Ys.require&&Ys.require("util").types;return oe||L1&&L1.binding&&L1.binding("util")}catch{}}(),wN=Ur&&Ur.isArrayBuffer,_N=Ur&&Ur.isDate,TN=Ur&&Ur.isMap,kN=Ur&&Ur.isRegExp,EN=Ur&&Ur.isSet,MN=Ur&&Ur.isTypedArray;function Tr(oe,xe,de){switch(de.length){case 0:return oe.call(xe);case 1:return oe.call(xe,de[0]);case 2:return oe.call(xe,de[0],de[1]);case 3:return oe.call(xe,de[0],de[1],de[2])}return oe.apply(xe,de)}function jre(oe,xe,de,Ve){for(var ot=-1,_t=oe==null?0:oe.length;++ot<_t;){var Cn=oe[ot];xe(Ve,Cn,de(Cn),oe)}return Ve}function Kr(oe,xe){for(var de=-1,Ve=oe==null?0:oe.length;++de<Ve&&xe(oe[de],de,oe)!==!1;);return oe}function Wre(oe,xe){for(var de=oe==null?0:oe.length;de--&&xe(oe[de],de,oe)!==!1;);return oe}function ON(oe,xe){for(var de=-1,Ve=oe==null?0:oe.length;++de<Ve;)if(!xe(oe[de],de,oe))return!1;return!0}function Xi(oe,xe){for(var de=-1,Ve=oe==null?0:oe.length,ot=0,_t=[];++de<Ve;){var Cn=oe[de];xe(Cn,de,oe)&&(_t[ot++]=Cn)}return _t}function $p(oe,xe){var de=oe==null?0:oe.length;return!!de&&sl(oe,xe,0)>-1}function F1(oe,xe,de){for(var Ve=-1,ot=oe==null?0:oe.length;++Ve<ot;)if(de(xe,oe[Ve]))return!0;return!1}function Qt(oe,xe){for(var de=-1,Ve=oe==null?0:oe.length,ot=Array(Ve);++de<Ve;)ot[de]=xe(oe[de],de,oe);return ot}function Qi(oe,xe){for(var de=-1,Ve=xe.length,ot=oe.length;++de<Ve;)oe[ot+de]=xe[de];return oe}function $1(oe,xe,de,Ve){var ot=-1,_t=oe==null?0:oe.length;for(Ve&&_t&&(de=oe[++ot]);++ot<_t;)de=xe(de,oe[ot],ot,oe);return de}function qre(oe,xe,de,Ve){var ot=oe==null?0:oe.length;for(Ve&&ot&&(de=oe[--ot]);ot--;)de=xe(de,oe[ot],ot,oe);return de}function B1(oe,xe){for(var de=-1,Ve=oe==null?0:oe.length;++de<Ve;)if(xe(oe[de],de,oe))return!0;return!1}var Ure=R1("length");function Kre(oe){return oe.split("")}function Yre(oe){return oe.match(nre)||[]}function AN(oe,xe,de){var Ve;return de(oe,function(ot,_t,Cn){if(xe(ot,_t,Cn))return Ve=_t,!1}),Ve}function Bp(oe,xe,de,Ve){for(var ot=oe.length,_t=de+(Ve?1:-1);Ve?_t--:++_t<ot;)if(xe(oe[_t],_t,oe))return _t;return-1}function sl(oe,xe,de){return xe===xe?soe(oe,xe,de):Bp(oe,IN,de)}function Gre(oe,xe,de,Ve){for(var ot=de-1,_t=oe.length;++ot<_t;)if(Ve(oe[ot],xe))return ot;return-1}function IN(oe){return oe!==oe}function DN(oe,xe){var de=oe==null?0:oe.length;return de?V1(oe,xe)/de:Y}function R1(oe){return function(xe){return xe==null?n:xe[oe]}}function z1(oe){return function(xe){return oe==null?n:oe[xe]}}function PN(oe,xe,de,Ve,ot){return ot(oe,function(_t,Cn,Bt){de=Ve?(Ve=!1,_t):xe(de,_t,Cn,Bt)}),de}function Jre(oe,xe){var de=oe.length;for(oe.sort(xe);de--;)oe[de]=oe[de].value;return oe}function V1(oe,xe){for(var de,Ve=-1,ot=oe.length;++Ve<ot;){var _t=xe(oe[Ve]);_t!==n&&(de=de===n?_t:de+_t)}return de}function H1(oe,xe){for(var de=-1,Ve=Array(oe);++de<oe;)Ve[de]=xe(de);return Ve}function Zre(oe,xe){return Qt(xe,function(de){return[de,oe[de]]})}function NN(oe){return oe&&oe.slice(0,BN(oe)+1).replace(M1,"")}function kr(oe){return function(xe){return oe(xe)}}function j1(oe,xe){return Qt(xe,function(de){return oe[de]})}function lu(oe,xe){return oe.has(xe)}function LN(oe,xe){for(var de=-1,Ve=oe.length;++de<Ve&&sl(xe,oe[de],0)>-1;);return de}function FN(oe,xe){for(var de=oe.length;de--&&sl(xe,oe[de],0)>-1;);return de}function Xre(oe,xe){for(var de=oe.length,Ve=0;de--;)oe[de]===xe&&++Ve;return Ve}var Qre=z1(Fre),eoe=z1($re);function toe(oe){return"\\"+Rre[oe]}function noe(oe,xe){return oe==null?n:oe[xe]}function al(oe){return Dre.test(oe)}function roe(oe){return Pre.test(oe)}function ooe(oe){for(var xe,de=[];!(xe=oe.next()).done;)de.push(xe.value);return de}function W1(oe){var xe=-1,de=Array(oe.size);return oe.forEach(function(Ve,ot){de[++xe]=[ot,Ve]}),de}function $N(oe,xe){return function(de){return oe(xe(de))}}function es(oe,xe){for(var de=-1,Ve=oe.length,ot=0,_t=[];++de<Ve;){var Cn=oe[de];(Cn===xe||Cn===f)&&(oe[de]=f,_t[ot++]=de)}return _t}function Rp(oe){var xe=-1,de=Array(oe.size);return oe.forEach(function(Ve){de[++xe]=Ve}),de}function ioe(oe){var xe=-1,de=Array(oe.size);return oe.forEach(function(Ve){de[++xe]=[Ve,Ve]}),de}function soe(oe,xe,de){for(var Ve=de-1,ot=oe.length;++Ve<ot;)if(oe[Ve]===xe)return Ve;return-1}function aoe(oe,xe,de){for(var Ve=de+1;Ve--;)if(oe[Ve]===xe)return Ve;return Ve}function ll(oe){return al(oe)?coe(oe):Ure(oe)}function po(oe){return al(oe)?uoe(oe):Kre(oe)}function BN(oe){for(var xe=oe.length;xe--&&Xne.test(oe.charAt(xe)););return xe}var loe=z1(Bre);function coe(oe){for(var xe=P1.lastIndex=0;P1.test(oe);)++xe;return xe}function uoe(oe){return oe.match(P1)||[]}function doe(oe){return oe.match(Ire)||[]}var foe=function oe(xe){xe=xe==null?Bn:cl.defaults(Bn.Object(),xe,cl.pick(Bn,Nre));var de=xe.Array,Ve=xe.Date,ot=xe.Error,_t=xe.Function,Cn=xe.Math,Bt=xe.Object,q1=xe.RegExp,poe=xe.String,Yr=xe.TypeError,zp=de.prototype,hoe=_t.prototype,ul=Bt.prototype,Vp=xe["__core-js_shared__"],Hp=hoe.toString,Ot=ul.hasOwnProperty,goe=0,RN=function(){var d=/[^.]+$/.exec(Vp&&Vp.keys&&Vp.keys.IE_PROTO||"");return d?"Symbol(src)_1."+d:""}(),jp=ul.toString,moe=Hp.call(Bt),yoe=Bn._,boe=q1("^"+Hp.call(Ot).replace(E1,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Wp=CN?xe.Buffer:n,ts=xe.Symbol,qp=xe.Uint8Array,zN=Wp?Wp.allocUnsafe:n,Up=$N(Bt.getPrototypeOf,Bt),VN=Bt.create,HN=ul.propertyIsEnumerable,Kp=zp.splice,jN=ts?ts.isConcatSpreadable:n,cu=ts?ts.iterator:n,Gs=ts?ts.toStringTag:n,Yp=function(){try{var d=ea(Bt,"defineProperty");return d({},"",{}),d}catch{}}(),voe=xe.clearTimeout!==Bn.clearTimeout&&xe.clearTimeout,xoe=Ve&&Ve.now!==Bn.Date.now&&Ve.now,Soe=xe.setTimeout!==Bn.setTimeout&&xe.setTimeout,Gp=Cn.ceil,Jp=Cn.floor,U1=Bt.getOwnPropertySymbols,Coe=Wp?Wp.isBuffer:n,WN=xe.isFinite,woe=zp.join,_oe=$N(Bt.keys,Bt),wn=Cn.max,Yn=Cn.min,Toe=Ve.now,koe=xe.parseInt,qN=Cn.random,Eoe=zp.reverse,K1=ea(xe,"DataView"),uu=ea(xe,"Map"),Y1=ea(xe,"Promise"),dl=ea(xe,"Set"),du=ea(xe,"WeakMap"),fu=ea(Bt,"create"),Zp=du&&new du,fl={},Moe=ta(K1),Ooe=ta(uu),Aoe=ta(Y1),Ioe=ta(dl),Doe=ta(du),Xp=ts?ts.prototype:n,pu=Xp?Xp.valueOf:n,UN=Xp?Xp.toString:n;function H(d){if(dn(d)&&!it(d)&&!(d instanceof mt)){if(d instanceof Gr)return d;if(Ot.call(d,"__wrapped__"))return KL(d)}return new Gr(d)}var pl=function(){function d(){}return function(h){if(!nn(h))return{};if(VN)return VN(h);d.prototype=h;var x=new d;return d.prototype=n,x}}();function Qp(){}function Gr(d,h){this.__wrapped__=d,this.__actions__=[],this.__chain__=!!h,this.__index__=0,this.__values__=n}H.templateSettings={escape:rl,evaluate:Zi,interpolate:Pp,variable:"",imports:{_:H}},H.prototype=Qp.prototype,H.prototype.constructor=H,Gr.prototype=pl(Qp.prototype),Gr.prototype.constructor=Gr;function mt(d){this.__wrapped__=d,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=Z,this.__views__=[]}function Poe(){var d=new mt(this.__wrapped__);return d.__actions__=gr(this.__actions__),d.__dir__=this.__dir__,d.__filtered__=this.__filtered__,d.__iteratees__=gr(this.__iteratees__),d.__takeCount__=this.__takeCount__,d.__views__=gr(this.__views__),d}function Noe(){if(this.__filtered__){var d=new mt(this);d.__dir__=-1,d.__filtered__=!0}else d=this.clone(),d.__dir__*=-1;return d}function Loe(){var d=this.__wrapped__.value(),h=this.__dir__,x=it(d),k=h<0,D=x?d.length:0,j=Kie(0,D,this.__views__),K=j.start,Q=j.end,ie=Q-K,Ce=k?Q:K-1,we=this.__iteratees__,Ee=we.length,Ne=0,We=Yn(ie,this.__takeCount__);if(!x||!k&&D==ie&&We==ie)return mL(d,this.__actions__);var et=[];e:for(;ie--&&Ne<We;){Ce+=h;for(var ut=-1,tt=d[Ce];++ut<Ee;){var ht=we[ut],xt=ht.iteratee,Or=ht.type,sr=xt(tt);if(Or==B)tt=sr;else if(!sr){if(Or==V)continue e;break e}}et[Ne++]=tt}return et}mt.prototype=pl(Qp.prototype),mt.prototype.constructor=mt;function Js(d){var h=-1,x=d==null?0:d.length;for(this.clear();++h<x;){var k=d[h];this.set(k[0],k[1])}}function Foe(){this.__data__=fu?fu(null):{},this.size=0}function $oe(d){var h=this.has(d)&&delete this.__data__[d];return this.size-=h?1:0,h}function Boe(d){var h=this.__data__;if(fu){var x=h[d];return x===l?n:x}return Ot.call(h,d)?h[d]:n}function Roe(d){var h=this.__data__;return fu?h[d]!==n:Ot.call(h,d)}function zoe(d,h){var x=this.__data__;return this.size+=this.has(d)?0:1,x[d]=fu&&h===n?l:h,this}Js.prototype.clear=Foe,Js.prototype.delete=$oe,Js.prototype.get=Boe,Js.prototype.has=Roe,Js.prototype.set=zoe;function ai(d){var h=-1,x=d==null?0:d.length;for(this.clear();++h<x;){var k=d[h];this.set(k[0],k[1])}}function Voe(){this.__data__=[],this.size=0}function Hoe(d){var h=this.__data__,x=eh(h,d);if(x<0)return!1;var k=h.length-1;return x==k?h.pop():Kp.call(h,x,1),--this.size,!0}function joe(d){var h=this.__data__,x=eh(h,d);return x<0?n:h[x][1]}function Woe(d){return eh(this.__data__,d)>-1}function qoe(d,h){var x=this.__data__,k=eh(x,d);return k<0?(++this.size,x.push([d,h])):x[k][1]=h,this}ai.prototype.clear=Voe,ai.prototype.delete=Hoe,ai.prototype.get=joe,ai.prototype.has=Woe,ai.prototype.set=qoe;function li(d){var h=-1,x=d==null?0:d.length;for(this.clear();++h<x;){var k=d[h];this.set(k[0],k[1])}}function Uoe(){this.size=0,this.__data__={hash:new Js,map:new(uu||ai),string:new Js}}function Koe(d){var h=fh(this,d).delete(d);return this.size-=h?1:0,h}function Yoe(d){return fh(this,d).get(d)}function Goe(d){return fh(this,d).has(d)}function Joe(d,h){var x=fh(this,d),k=x.size;return x.set(d,h),this.size+=x.size==k?0:1,this}li.prototype.clear=Uoe,li.prototype.delete=Koe,li.prototype.get=Yoe,li.prototype.has=Goe,li.prototype.set=Joe;function Zs(d){var h=-1,x=d==null?0:d.length;for(this.__data__=new li;++h<x;)this.add(d[h])}function Zoe(d){return this.__data__.set(d,l),this}function Xoe(d){return this.__data__.has(d)}Zs.prototype.add=Zs.prototype.push=Zoe,Zs.prototype.has=Xoe;function ho(d){var h=this.__data__=new ai(d);this.size=h.size}function Qoe(){this.__data__=new ai,this.size=0}function eie(d){var h=this.__data__,x=h.delete(d);return this.size=h.size,x}function tie(d){return this.__data__.get(d)}function nie(d){return this.__data__.has(d)}function rie(d,h){var x=this.__data__;if(x instanceof ai){var k=x.__data__;if(!uu||k.length<o-1)return k.push([d,h]),this.size=++x.size,this;x=this.__data__=new li(k)}return x.set(d,h),this.size=x.size,this}ho.prototype.clear=Qoe,ho.prototype.delete=eie,ho.prototype.get=tie,ho.prototype.has=nie,ho.prototype.set=rie;function KN(d,h){var x=it(d),k=!x&&na(d),D=!x&&!k&&as(d),j=!x&&!k&&!D&&yl(d),K=x||k||D||j,Q=K?H1(d.length,poe):[],ie=Q.length;for(var Ce in d)(h||Ot.call(d,Ce))&&!(K&&(Ce=="length"||D&&(Ce=="offset"||Ce=="parent")||j&&(Ce=="buffer"||Ce=="byteLength"||Ce=="byteOffset")||fi(Ce,ie)))&&Q.push(Ce);return Q}function YN(d){var h=d.length;return h?d[ix(0,h-1)]:n}function oie(d,h){return ph(gr(d),Xs(h,0,d.length))}function iie(d){return ph(gr(d))}function G1(d,h,x){(x!==n&&!go(d[h],x)||x===n&&!(h in d))&&ci(d,h,x)}function hu(d,h,x){var k=d[h];(!(Ot.call(d,h)&&go(k,x))||x===n&&!(h in d))&&ci(d,h,x)}function eh(d,h){for(var x=d.length;x--;)if(go(d[x][0],h))return x;return-1}function sie(d,h,x,k){return ns(d,function(D,j,K){h(k,D,x(D),K)}),k}function GN(d,h){return d&&Bo(h,Dn(h),d)}function aie(d,h){return d&&Bo(h,yr(h),d)}function ci(d,h,x){h=="__proto__"&&Yp?Yp(d,h,{configurable:!0,enumerable:!0,value:x,writable:!0}):d[h]=x}function J1(d,h){for(var x=-1,k=h.length,D=de(k),j=d==null;++x<k;)D[x]=j?n:Ax(d,h[x]);return D}function Xs(d,h,x){return d===d&&(x!==n&&(d=d<=x?d:x),h!==n&&(d=d>=h?d:h)),d}function Jr(d,h,x,k,D,j){var K,Q=h&p,ie=h&g,Ce=h&m;if(x&&(K=D?x(d,k,D,j):x(d)),K!==n)return K;if(!nn(d))return d;var we=it(d);if(we){if(K=Gie(d),!Q)return gr(d,K)}else{var Ee=Gn(d),Ne=Ee==te||Ee==se;if(as(d))return vL(d,Q);if(Ee==Se||Ee==re||Ne&&!D){if(K=ie||Ne?{}:BL(d),!Q)return ie?Bie(d,aie(K,d)):$ie(d,GN(K,d))}else{if(!Ht[Ee])return D?d:{};K=Jie(d,Ee,Q)}}j||(j=new ho);var We=j.get(d);if(We)return We;j.set(d,K),pF(d)?d.forEach(function(tt){K.add(Jr(tt,h,x,tt,d,j))}):dF(d)&&d.forEach(function(tt,ht){K.set(ht,Jr(tt,h,x,ht,d,j))});var et=Ce?ie?mx:gx:ie?yr:Dn,ut=we?n:et(d);return Kr(ut||d,function(tt,ht){ut&&(ht=tt,tt=d[ht]),hu(K,ht,Jr(tt,h,x,ht,d,j))}),K}function lie(d){var h=Dn(d);return function(x){return JN(x,d,h)}}function JN(d,h,x){var k=x.length;if(d==null)return!k;for(d=Bt(d);k--;){var D=x[k],j=h[D],K=d[D];if(K===n&&!(D in d)||!j(K))return!1}return!0}function ZN(d,h,x){if(typeof d!="function")throw new Yr(s);return Su(function(){d.apply(n,x)},h)}function gu(d,h,x,k){var D=-1,j=$p,K=!0,Q=d.length,ie=[],Ce=h.length;if(!Q)return ie;x&&(h=Qt(h,kr(x))),k?(j=F1,K=!1):h.length>=o&&(j=lu,K=!1,h=new Zs(h));e:for(;++D<Q;){var we=d[D],Ee=x==null?we:x(we);if(we=k||we!==0?we:0,K&&Ee===Ee){for(var Ne=Ce;Ne--;)if(h[Ne]===Ee)continue e;ie.push(we)}else j(h,Ee,k)||ie.push(we)}return ie}var ns=_L($o),XN=_L(X1,!0);function cie(d,h){var x=!0;return ns(d,function(k,D,j){return x=!!h(k,D,j),x}),x}function th(d,h,x){for(var k=-1,D=d.length;++k<D;){var j=d[k],K=h(j);if(K!=null&&(Q===n?K===K&&!Mr(K):x(K,Q)))var Q=K,ie=j}return ie}function uie(d,h,x,k){var D=d.length;for(x=st(x),x<0&&(x=-x>D?0:D+x),k=k===n||k>D?D:st(k),k<0&&(k+=D),k=x>k?0:gF(k);x<k;)d[x++]=h;return d}function QN(d,h){var x=[];return ns(d,function(k,D,j){h(k,D,j)&&x.push(k)}),x}function Rn(d,h,x,k,D){var j=-1,K=d.length;for(x||(x=Xie),D||(D=[]);++j<K;){var Q=d[j];h>0&&x(Q)?h>1?Rn(Q,h-1,x,k,D):Qi(D,Q):k||(D[D.length]=Q)}return D}var Z1=TL(),eL=TL(!0);function $o(d,h){return d&&Z1(d,h,Dn)}function X1(d,h){return d&&eL(d,h,Dn)}function nh(d,h){return Xi(h,function(x){return pi(d[x])})}function Qs(d,h){h=is(h,d);for(var x=0,k=h.length;d!=null&&x<k;)d=d[Ro(h[x++])];return x&&x==k?d:n}function tL(d,h,x){var k=h(d);return it(d)?k:Qi(k,x(d))}function or(d){return d==null?d===n?Ct:_e:Gs&&Gs in Bt(d)?Uie(d):ise(d)}function Q1(d,h){return d>h}function die(d,h){return d!=null&&Ot.call(d,h)}function fie(d,h){return d!=null&&h in Bt(d)}function pie(d,h,x){return d>=Yn(h,x)&&d<wn(h,x)}function ex(d,h,x){for(var k=x?F1:$p,D=d[0].length,j=d.length,K=j,Q=de(j),ie=1/0,Ce=[];K--;){var we=d[K];K&&h&&(we=Qt(we,kr(h))),ie=Yn(we.length,ie),Q[K]=!x&&(h||D>=120&&we.length>=120)?new Zs(K&&we):n}we=d[0];var Ee=-1,Ne=Q[0];e:for(;++Ee<D&&Ce.length<ie;){var We=we[Ee],et=h?h(We):We;if(We=x||We!==0?We:0,!(Ne?lu(Ne,et):k(Ce,et,x))){for(K=j;--K;){var ut=Q[K];if(!(ut?lu(ut,et):k(d[K],et,x)))continue e}Ne&&Ne.push(et),Ce.push(We)}}return Ce}function hie(d,h,x,k){return $o(d,function(D,j,K){h(k,x(D),j,K)}),k}function mu(d,h,x){h=is(h,d),d=HL(d,h);var k=d==null?d:d[Ro(Xr(h))];return k==null?n:Tr(k,d,x)}function nL(d){return dn(d)&&or(d)==re}function gie(d){return dn(d)&&or(d)==un}function mie(d){return dn(d)&&or(d)==W}function yu(d,h,x,k,D){return d===h?!0:d==null||h==null||!dn(d)&&!dn(h)?d!==d&&h!==h:yie(d,h,x,k,yu,D)}function yie(d,h,x,k,D,j){var K=it(d),Q=it(h),ie=K?he:Gn(d),Ce=Q?he:Gn(h);ie=ie==re?Se:ie,Ce=Ce==re?Se:Ce;var we=ie==Se,Ee=Ce==Se,Ne=ie==Ce;if(Ne&&as(d)){if(!as(h))return!1;K=!0,we=!1}if(Ne&&!we)return j||(j=new ho),K||yl(d)?LL(d,h,x,k,D,j):Wie(d,h,ie,x,k,D,j);if(!(x&y)){var We=we&&Ot.call(d,"__wrapped__"),et=Ee&&Ot.call(h,"__wrapped__");if(We||et){var ut=We?d.value():d,tt=et?h.value():h;return j||(j=new ho),D(ut,tt,x,k,j)}}return Ne?(j||(j=new ho),qie(d,h,x,k,D,j)):!1}function bie(d){return dn(d)&&Gn(d)==ue}function tx(d,h,x,k){var D=x.length,j=D,K=!k;if(d==null)return!j;for(d=Bt(d);D--;){var Q=x[D];if(K&&Q[2]?Q[1]!==d[Q[0]]:!(Q[0]in d))return!1}for(;++D<j;){Q=x[D];var ie=Q[0],Ce=d[ie],we=Q[1];if(K&&Q[2]){if(Ce===n&&!(ie in d))return!1}else{var Ee=new ho;if(k)var Ne=k(Ce,we,ie,d,h,Ee);if(!(Ne===n?yu(we,Ce,y|b,k,Ee):Ne))return!1}}return!0}function rL(d){if(!nn(d)||ese(d))return!1;var h=pi(d)?boe:lre;return h.test(ta(d))}function vie(d){return dn(d)&&or(d)==je}function xie(d){return dn(d)&&Gn(d)==Je}function Sie(d){return dn(d)&&vh(d.length)&&!!Gt[or(d)]}function oL(d){return typeof d=="function"?d:d==null?br:typeof d=="object"?it(d)?aL(d[0],d[1]):sL(d):kF(d)}function nx(d){if(!xu(d))return _oe(d);var h=[];for(var x in Bt(d))Ot.call(d,x)&&x!="constructor"&&h.push(x);return h}function Cie(d){if(!nn(d))return ose(d);var h=xu(d),x=[];for(var k in d)k=="constructor"&&(h||!Ot.call(d,k))||x.push(k);return x}function rx(d,h){return d<h}function iL(d,h){var x=-1,k=mr(d)?de(d.length):[];return ns(d,function(D,j,K){k[++x]=h(D,j,K)}),k}function sL(d){var h=bx(d);return h.length==1&&h[0][2]?zL(h[0][0],h[0][1]):function(x){return x===d||tx(x,d,h)}}function aL(d,h){return xx(d)&&RL(h)?zL(Ro(d),h):function(x){var k=Ax(x,d);return k===n&&k===h?Ix(x,d):yu(h,k,y|b)}}function rh(d,h,x,k,D){d!==h&&Z1(h,function(j,K){if(D||(D=new ho),nn(j))wie(d,h,K,x,rh,k,D);else{var Q=k?k(Cx(d,K),j,K+"",d,h,D):n;Q===n&&(Q=j),G1(d,K,Q)}},yr)}function wie(d,h,x,k,D,j,K){var Q=Cx(d,x),ie=Cx(h,x),Ce=K.get(ie);if(Ce){G1(d,x,Ce);return}var we=j?j(Q,ie,x+"",d,h,K):n,Ee=we===n;if(Ee){var Ne=it(ie),We=!Ne&&as(ie),et=!Ne&&!We&&yl(ie);we=ie,Ne||We||et?it(Q)?we=Q:hn(Q)?we=gr(Q):We?(Ee=!1,we=vL(ie,!0)):et?(Ee=!1,we=xL(ie,!0)):we=[]:Cu(ie)||na(ie)?(we=Q,na(Q)?we=mF(Q):(!nn(Q)||pi(Q))&&(we=BL(ie))):Ee=!1}Ee&&(K.set(ie,we),D(we,ie,k,j,K),K.delete(ie)),G1(d,x,we)}function lL(d,h){var x=d.length;if(x)return h+=h<0?x:0,fi(h,x)?d[h]:n}function cL(d,h,x){h.length?h=Qt(h,function(j){return it(j)?function(K){return Qs(K,j.length===1?j[0]:j)}:j}):h=[br];var k=-1;h=Qt(h,kr(Xe()));var D=iL(d,function(j,K,Q){var ie=Qt(h,function(Ce){return Ce(j)});return{criteria:ie,index:++k,value:j}});return Jre(D,function(j,K){return Fie(j,K,x)})}function _ie(d,h){return uL(d,h,function(x,k){return Ix(d,k)})}function uL(d,h,x){for(var k=-1,D=h.length,j={};++k<D;){var K=h[k],Q=Qs(d,K);x(Q,K)&&bu(j,is(K,d),Q)}return j}function Tie(d){return function(h){return Qs(h,d)}}function ox(d,h,x,k){var D=k?Gre:sl,j=-1,K=h.length,Q=d;for(d===h&&(h=gr(h)),x&&(Q=Qt(d,kr(x)));++j<K;)for(var ie=0,Ce=h[j],we=x?x(Ce):Ce;(ie=D(Q,we,ie,k))>-1;)Q!==d&&Kp.call(Q,ie,1),Kp.call(d,ie,1);return d}function dL(d,h){for(var x=d?h.length:0,k=x-1;x--;){var D=h[x];if(x==k||D!==j){var j=D;fi(D)?Kp.call(d,D,1):lx(d,D)}}return d}function ix(d,h){return d+Jp(qN()*(h-d+1))}function kie(d,h,x,k){for(var D=-1,j=wn(Gp((h-d)/(x||1)),0),K=de(j);j--;)K[k?j:++D]=d,d+=x;return K}function sx(d,h){var x="";if(!d||h<1||h>U)return x;do h%2&&(x+=d),h=Jp(h/2),h&&(d+=d);while(h);return x}function dt(d,h){return wx(VL(d,h,br),d+"")}function Eie(d){return YN(bl(d))}function Mie(d,h){var x=bl(d);return ph(x,Xs(h,0,x.length))}function bu(d,h,x,k){if(!nn(d))return d;h=is(h,d);for(var D=-1,j=h.length,K=j-1,Q=d;Q!=null&&++D<j;){var ie=Ro(h[D]),Ce=x;if(ie==="__proto__"||ie==="constructor"||ie==="prototype")return d;if(D!=K){var we=Q[ie];Ce=k?k(we,ie,Q):n,Ce===n&&(Ce=nn(we)?we:fi(h[D+1])?[]:{})}hu(Q,ie,Ce),Q=Q[ie]}return d}var fL=Zp?function(d,h){return Zp.set(d,h),d}:br,Oie=Yp?function(d,h){return Yp(d,"toString",{configurable:!0,enumerable:!1,value:Px(h),writable:!0})}:br;function Aie(d){return ph(bl(d))}function Zr(d,h,x){var k=-1,D=d.length;h<0&&(h=-h>D?0:D+h),x=x>D?D:x,x<0&&(x+=D),D=h>x?0:x-h>>>0,h>>>=0;for(var j=de(D);++k<D;)j[k]=d[k+h];return j}function Iie(d,h){var x;return ns(d,function(k,D,j){return x=h(k,D,j),!x}),!!x}function oh(d,h,x){var k=0,D=d==null?k:d.length;if(typeof h=="number"&&h===h&&D<=pe){for(;k<D;){var j=k+D>>>1,K=d[j];K!==null&&!Mr(K)&&(x?K<=h:K<h)?k=j+1:D=j}return D}return ax(d,h,br,x)}function ax(d,h,x,k){var D=0,j=d==null?0:d.length;if(j===0)return 0;h=x(h);for(var K=h!==h,Q=h===null,ie=Mr(h),Ce=h===n;D<j;){var we=Jp((D+j)/2),Ee=x(d[we]),Ne=Ee!==n,We=Ee===null,et=Ee===Ee,ut=Mr(Ee);if(K)var tt=k||et;else Ce?tt=et&&(k||Ne):Q?tt=et&&Ne&&(k||!We):ie?tt=et&&Ne&&!We&&(k||!ut):We||ut?tt=!1:tt=k?Ee<=h:Ee<h;tt?D=we+1:j=we}return Yn(j,fe)}function pL(d,h){for(var x=-1,k=d.length,D=0,j=[];++x<k;){var K=d[x],Q=h?h(K):K;if(!x||!go(Q,ie)){var ie=Q;j[D++]=K===0?0:K}}return j}function hL(d){return typeof d=="number"?d:Mr(d)?Y:+d}function Er(d){if(typeof d=="string")return d;if(it(d))return Qt(d,Er)+"";if(Mr(d))return UN?UN.call(d):"";var h=d+"";return h=="0"&&1/d==-q?"-0":h}function rs(d,h,x){var k=-1,D=$p,j=d.length,K=!0,Q=[],ie=Q;if(x)K=!1,D=F1;else if(j>=o){var Ce=h?null:Hie(d);if(Ce)return Rp(Ce);K=!1,D=lu,ie=new Zs}else ie=h?[]:Q;e:for(;++k<j;){var we=d[k],Ee=h?h(we):we;if(we=x||we!==0?we:0,K&&Ee===Ee){for(var Ne=ie.length;Ne--;)if(ie[Ne]===Ee)continue e;h&&ie.push(Ee),Q.push(we)}else D(ie,Ee,x)||(ie!==Q&&ie.push(Ee),Q.push(we))}return Q}function lx(d,h){return h=is(h,d),d=HL(d,h),d==null||delete d[Ro(Xr(h))]}function gL(d,h,x,k){return bu(d,h,x(Qs(d,h)),k)}function ih(d,h,x,k){for(var D=d.length,j=k?D:-1;(k?j--:++j<D)&&h(d[j],j,d););return x?Zr(d,k?0:j,k?j+1:D):Zr(d,k?j+1:0,k?D:j)}function mL(d,h){var x=d;return x instanceof mt&&(x=x.value()),$1(h,function(k,D){return D.func.apply(D.thisArg,Qi([k],D.args))},x)}function cx(d,h,x){var k=d.length;if(k<2)return k?rs(d[0]):[];for(var D=-1,j=de(k);++D<k;)for(var K=d[D],Q=-1;++Q<k;)Q!=D&&(j[D]=gu(j[D]||K,d[Q],h,x));return rs(Rn(j,1),h,x)}function yL(d,h,x){for(var k=-1,D=d.length,j=h.length,K={};++k<D;){var Q=k<j?h[k]:n;x(K,d[k],Q)}return K}function ux(d){return hn(d)?d:[]}function dx(d){return typeof d=="function"?d:br}function is(d,h){return it(d)?d:xx(d,h)?[d]:UL(Mt(d))}var Die=dt;function ss(d,h,x){var k=d.length;return x=x===n?k:x,!h&&x>=k?d:Zr(d,h,x)}var bL=voe||function(d){return Bn.clearTimeout(d)};function vL(d,h){if(h)return d.slice();var x=d.length,k=zN?zN(x):new d.constructor(x);return d.copy(k),k}function fx(d){var h=new d.constructor(d.byteLength);return new qp(h).set(new qp(d)),h}function Pie(d,h){var x=h?fx(d.buffer):d.buffer;return new d.constructor(x,d.byteOffset,d.byteLength)}function Nie(d){var h=new d.constructor(d.source,nN.exec(d));return h.lastIndex=d.lastIndex,h}function Lie(d){return pu?Bt(pu.call(d)):{}}function xL(d,h){var x=h?fx(d.buffer):d.buffer;return new d.constructor(x,d.byteOffset,d.length)}function SL(d,h){if(d!==h){var x=d!==n,k=d===null,D=d===d,j=Mr(d),K=h!==n,Q=h===null,ie=h===h,Ce=Mr(h);if(!Q&&!Ce&&!j&&d>h||j&&K&&ie&&!Q&&!Ce||k&&K&&ie||!x&&ie||!D)return 1;if(!k&&!j&&!Ce&&d<h||Ce&&x&&D&&!k&&!j||Q&&x&&D||!K&&D||!ie)return-1}return 0}function Fie(d,h,x){for(var k=-1,D=d.criteria,j=h.criteria,K=D.length,Q=x.length;++k<K;){var ie=SL(D[k],j[k]);if(ie){if(k>=Q)return ie;var Ce=x[k];return ie*(Ce=="desc"?-1:1)}}return d.index-h.index}function CL(d,h,x,k){for(var D=-1,j=d.length,K=x.length,Q=-1,ie=h.length,Ce=wn(j-K,0),we=de(ie+Ce),Ee=!k;++Q<ie;)we[Q]=h[Q];for(;++D<K;)(Ee||D<j)&&(we[x[D]]=d[D]);for(;Ce--;)we[Q++]=d[D++];return we}function wL(d,h,x,k){for(var D=-1,j=d.length,K=-1,Q=x.length,ie=-1,Ce=h.length,we=wn(j-Q,0),Ee=de(we+Ce),Ne=!k;++D<we;)Ee[D]=d[D];for(var We=D;++ie<Ce;)Ee[We+ie]=h[ie];for(;++K<Q;)(Ne||D<j)&&(Ee[We+x[K]]=d[D++]);return Ee}function gr(d,h){var x=-1,k=d.length;for(h||(h=de(k));++x<k;)h[x]=d[x];return h}function Bo(d,h,x,k){var D=!x;x||(x={});for(var j=-1,K=h.length;++j<K;){var Q=h[j],ie=k?k(x[Q],d[Q],Q,x,d):n;ie===n&&(ie=d[Q]),D?ci(x,Q,ie):hu(x,Q,ie)}return x}function $ie(d,h){return Bo(d,vx(d),h)}function Bie(d,h){return Bo(d,FL(d),h)}function sh(d,h){return function(x,k){var D=it(x)?jre:sie,j=h?h():{};return D(x,d,Xe(k,2),j)}}function hl(d){return dt(function(h,x){var k=-1,D=x.length,j=D>1?x[D-1]:n,K=D>2?x[2]:n;for(j=d.length>3&&typeof j=="function"?(D--,j):n,K&&ir(x[0],x[1],K)&&(j=D<3?n:j,D=1),h=Bt(h);++k<D;){var Q=x[k];Q&&d(h,Q,k,j)}return h})}function _L(d,h){return function(x,k){if(x==null)return x;if(!mr(x))return d(x,k);for(var D=x.length,j=h?D:-1,K=Bt(x);(h?j--:++j<D)&&k(K[j],j,K)!==!1;);return x}}function TL(d){return function(h,x,k){for(var D=-1,j=Bt(h),K=k(h),Q=K.length;Q--;){var ie=K[d?Q:++D];if(x(j[ie],ie,j)===!1)break}return h}}function Rie(d,h,x){var k=h&S,D=vu(d);function j(){var K=this&&this!==Bn&&this instanceof j?D:d;return K.apply(k?x:this,arguments)}return j}function kL(d){return function(h){h=Mt(h);var x=al(h)?po(h):n,k=x?x[0]:h.charAt(0),D=x?ss(x,1).join(""):h.slice(1);return k[d]()+D}}function gl(d){return function(h){return $1(_F(wF(h).replace(Ore,"")),d,"")}}function vu(d){return function(){var h=arguments;switch(h.length){case 0:return new d;case 1:return new d(h[0]);case 2:return new d(h[0],h[1]);case 3:return new d(h[0],h[1],h[2]);case 4:return new d(h[0],h[1],h[2],h[3]);case 5:return new d(h[0],h[1],h[2],h[3],h[4]);case 6:return new d(h[0],h[1],h[2],h[3],h[4],h[5]);case 7:return new d(h[0],h[1],h[2],h[3],h[4],h[5],h[6])}var x=pl(d.prototype),k=d.apply(x,h);return nn(k)?k:x}}function zie(d,h,x){var k=vu(d);function D(){for(var j=arguments.length,K=de(j),Q=j,ie=ml(D);Q--;)K[Q]=arguments[Q];var Ce=j<3&&K[0]!==ie&&K[j-1]!==ie?[]:es(K,ie);if(j-=Ce.length,j<x)return IL(d,h,ah,D.placeholder,n,K,Ce,n,n,x-j);var we=this&&this!==Bn&&this instanceof D?k:d;return Tr(we,this,K)}return D}function EL(d){return function(h,x,k){var D=Bt(h);if(!mr(h)){var j=Xe(x,3);h=Dn(h),x=function(Q){return j(D[Q],Q,D)}}var K=d(h,x,k);return K>-1?D[j?h[K]:K]:n}}function ML(d){return di(function(h){var x=h.length,k=x,D=Gr.prototype.thru;for(d&&h.reverse();k--;){var j=h[k];if(typeof j!="function")throw new Yr(s);if(D&&!K&&dh(j)=="wrapper")var K=new Gr([],!0)}for(k=K?k:x;++k<x;){j=h[k];var Q=dh(j),ie=Q=="wrapper"?yx(j):n;ie&&Sx(ie[0])&&ie[1]==(L|_|E|P)&&!ie[4].length&&ie[9]==1?K=K[dh(ie[0])].apply(K,ie[3]):K=j.length==1&&Sx(j)?K[Q]():K.thru(j)}return function(){var Ce=arguments,we=Ce[0];if(K&&Ce.length==1&&it(we))return K.plant(we).value();for(var Ee=0,Ne=x?h[Ee].apply(this,Ce):we;++Ee<x;)Ne=h[Ee].call(this,Ne);return Ne}})}function ah(d,h,x,k,D,j,K,Q,ie,Ce){var we=h&L,Ee=h&S,Ne=h&C,We=h&(_|w),et=h&$,ut=Ne?n:vu(d);function tt(){for(var ht=arguments.length,xt=de(ht),Or=ht;Or--;)xt[Or]=arguments[Or];if(We)var sr=ml(tt),Ar=Xre(xt,sr);if(k&&(xt=CL(xt,k,D,We)),j&&(xt=wL(xt,j,K,We)),ht-=Ar,We&&ht<Ce){var gn=es(xt,sr);return IL(d,h,ah,tt.placeholder,x,xt,gn,Q,ie,Ce-ht)}var mo=Ee?x:this,gi=Ne?mo[d]:d;return ht=xt.length,Q?xt=sse(xt,Q):et&&ht>1&&xt.reverse(),we&&ie<ht&&(xt.length=ie),this&&this!==Bn&&this instanceof tt&&(gi=ut||vu(gi)),gi.apply(mo,xt)}return tt}function OL(d,h){return function(x,k){return hie(x,d,h(k),{})}}function lh(d,h){return function(x,k){var D;if(x===n&&k===n)return h;if(x!==n&&(D=x),k!==n){if(D===n)return k;typeof x=="string"||typeof k=="string"?(x=Er(x),k=Er(k)):(x=hL(x),k=hL(k)),D=d(x,k)}return D}}function px(d){return di(function(h){return h=Qt(h,kr(Xe())),dt(function(x){var k=this;return d(h,function(D){return Tr(D,k,x)})})})}function ch(d,h){h=h===n?" ":Er(h);var x=h.length;if(x<2)return x?sx(h,d):h;var k=sx(h,Gp(d/ll(h)));return al(h)?ss(po(k),0,d).join(""):k.slice(0,d)}function Vie(d,h,x,k){var D=h&S,j=vu(d);function K(){for(var Q=-1,ie=arguments.length,Ce=-1,we=k.length,Ee=de(we+ie),Ne=this&&this!==Bn&&this instanceof K?j:d;++Ce<we;)Ee[Ce]=k[Ce];for(;ie--;)Ee[Ce++]=arguments[++Q];return Tr(Ne,D?x:this,Ee)}return K}function AL(d){return function(h,x,k){return k&&typeof k!="number"&&ir(h,x,k)&&(x=k=n),h=hi(h),x===n?(x=h,h=0):x=hi(x),k=k===n?h<x?1:-1:hi(k),kie(h,x,k,d)}}function uh(d){return function(h,x){return typeof h=="string"&&typeof x=="string"||(h=Qr(h),x=Qr(x)),d(h,x)}}function IL(d,h,x,k,D,j,K,Q,ie,Ce){var we=h&_,Ee=we?K:n,Ne=we?n:K,We=we?j:n,et=we?n:j;h|=we?E:O,h&=~(we?O:E),h&T||(h&=~(S|C));var ut=[d,h,D,We,Ee,et,Ne,Q,ie,Ce],tt=x.apply(n,ut);return Sx(d)&&jL(tt,ut),tt.placeholder=k,WL(tt,d,h)}function hx(d){var h=Cn[d];return function(x,k){if(x=Qr(x),k=k==null?0:Yn(st(k),292),k&&WN(x)){var D=(Mt(x)+"e").split("e"),j=h(D[0]+"e"+(+D[1]+k));return D=(Mt(j)+"e").split("e"),+(D[0]+"e"+(+D[1]-k))}return h(x)}}var Hie=dl&&1/Rp(new dl([,-0]))[1]==q?function(d){return new dl(d)}:Fx;function DL(d){return function(h){var x=Gn(h);return x==ue?W1(h):x==Je?ioe(h):Zre(h,d(h))}}function ui(d,h,x,k,D,j,K,Q){var ie=h&C;if(!ie&&typeof d!="function")throw new Yr(s);var Ce=k?k.length:0;if(Ce||(h&=~(E|O),k=D=n),K=K===n?K:wn(st(K),0),Q=Q===n?Q:st(Q),Ce-=D?D.length:0,h&O){var we=k,Ee=D;k=D=n}var Ne=ie?n:yx(d),We=[d,h,x,k,D,we,Ee,j,K,Q];if(Ne&&rse(We,Ne),d=We[0],h=We[1],x=We[2],k=We[3],D=We[4],Q=We[9]=We[9]===n?ie?0:d.length:wn(We[9]-Ce,0),!Q&&h&(_|w)&&(h&=~(_|w)),!h||h==S)var et=Rie(d,h,x);else h==_||h==w?et=zie(d,h,Q):(h==E||h==(S|E))&&!D.length?et=Vie(d,h,x,k):et=ah.apply(n,We);var ut=Ne?fL:jL;return WL(ut(et,We),d,h)}function PL(d,h,x,k){return d===n||go(d,ul[x])&&!Ot.call(k,x)?h:d}function NL(d,h,x,k,D,j){return nn(d)&&nn(h)&&(j.set(h,d),rh(d,h,n,NL,j),j.delete(h)),d}function jie(d){return Cu(d)?n:d}function LL(d,h,x,k,D,j){var K=x&y,Q=d.length,ie=h.length;if(Q!=ie&&!(K&&ie>Q))return!1;var Ce=j.get(d),we=j.get(h);if(Ce&&we)return Ce==h&&we==d;var Ee=-1,Ne=!0,We=x&b?new Zs:n;for(j.set(d,h),j.set(h,d);++Ee<Q;){var et=d[Ee],ut=h[Ee];if(k)var tt=K?k(ut,et,Ee,h,d,j):k(et,ut,Ee,d,h,j);if(tt!==n){if(tt)continue;Ne=!1;break}if(We){if(!B1(h,function(ht,xt){if(!lu(We,xt)&&(et===ht||D(et,ht,x,k,j)))return We.push(xt)})){Ne=!1;break}}else if(!(et===ut||D(et,ut,x,k,j))){Ne=!1;break}}return j.delete(d),j.delete(h),Ne}function Wie(d,h,x,k,D,j,K){switch(x){case $t:if(d.byteLength!=h.byteLength||d.byteOffset!=h.byteOffset)return!1;d=d.buffer,h=h.buffer;case un:return!(d.byteLength!=h.byteLength||!j(new qp(d),new qp(h)));case X:case W:case ye:return go(+d,+h);case ce:return d.name==h.name&&d.message==h.message;case je:case De:return d==h+"";case ue:var Q=W1;case Je:var ie=k&y;if(Q||(Q=Rp),d.size!=h.size&&!ie)return!1;var Ce=K.get(d);if(Ce)return Ce==h;k|=b,K.set(d,h);var we=LL(Q(d),Q(h),k,D,j,K);return K.delete(d),we;case ct:if(pu)return pu.call(d)==pu.call(h)}return!1}function qie(d,h,x,k,D,j){var K=x&y,Q=gx(d),ie=Q.length,Ce=gx(h),we=Ce.length;if(ie!=we&&!K)return!1;for(var Ee=ie;Ee--;){var Ne=Q[Ee];if(!(K?Ne in h:Ot.call(h,Ne)))return!1}var We=j.get(d),et=j.get(h);if(We&&et)return We==h&&et==d;var ut=!0;j.set(d,h),j.set(h,d);for(var tt=K;++Ee<ie;){Ne=Q[Ee];var ht=d[Ne],xt=h[Ne];if(k)var Or=K?k(xt,ht,Ne,h,d,j):k(ht,xt,Ne,d,h,j);if(!(Or===n?ht===xt||D(ht,xt,x,k,j):Or)){ut=!1;break}tt||(tt=Ne=="constructor")}if(ut&&!tt){var sr=d.constructor,Ar=h.constructor;sr!=Ar&&"constructor"in d&&"constructor"in h&&!(typeof sr=="function"&&sr instanceof sr&&typeof Ar=="function"&&Ar instanceof Ar)&&(ut=!1)}return j.delete(d),j.delete(h),ut}function di(d){return wx(VL(d,n,JL),d+"")}function gx(d){return tL(d,Dn,vx)}function mx(d){return tL(d,yr,FL)}var yx=Zp?function(d){return Zp.get(d)}:Fx;function dh(d){for(var h=d.name+"",x=fl[h],k=Ot.call(fl,h)?x.length:0;k--;){var D=x[k],j=D.func;if(j==null||j==d)return D.name}return h}function ml(d){var h=Ot.call(H,"placeholder")?H:d;return h.placeholder}function Xe(){var d=H.iteratee||Nx;return d=d===Nx?oL:d,arguments.length?d(arguments[0],arguments[1]):d}function fh(d,h){var x=d.__data__;return Qie(h)?x[typeof h=="string"?"string":"hash"]:x.map}function bx(d){for(var h=Dn(d),x=h.length;x--;){var k=h[x],D=d[k];h[x]=[k,D,RL(D)]}return h}function ea(d,h){var x=noe(d,h);return rL(x)?x:n}function Uie(d){var h=Ot.call(d,Gs),x=d[Gs];try{d[Gs]=n;var k=!0}catch{}var D=jp.call(d);return k&&(h?d[Gs]=x:delete d[Gs]),D}var vx=U1?function(d){return d==null?[]:(d=Bt(d),Xi(U1(d),function(h){return HN.call(d,h)}))}:$x,FL=U1?function(d){for(var h=[];d;)Qi(h,vx(d)),d=Up(d);return h}:$x,Gn=or;(K1&&Gn(new K1(new ArrayBuffer(1)))!=$t||uu&&Gn(new uu)!=ue||Y1&&Gn(Y1.resolve())!=Me||dl&&Gn(new dl)!=Je||du&&Gn(new du)!=Xt)&&(Gn=function(d){var h=or(d),x=h==Se?d.constructor:n,k=x?ta(x):"";if(k)switch(k){case Moe:return $t;case Ooe:return ue;case Aoe:return Me;case Ioe:return Je;case Doe:return Xt}return h});function Kie(d,h,x){for(var k=-1,D=x.length;++k<D;){var j=x[k],K=j.size;switch(j.type){case"drop":d+=K;break;case"dropRight":h-=K;break;case"take":h=Yn(h,d+K);break;case"takeRight":d=wn(d,h-K);break}}return{start:d,end:h}}function Yie(d){var h=d.match(ere);return h?h[1].split(tre):[]}function $L(d,h,x){h=is(h,d);for(var k=-1,D=h.length,j=!1;++k<D;){var K=Ro(h[k]);if(!(j=d!=null&&x(d,K)))break;d=d[K]}return j||++k!=D?j:(D=d==null?0:d.length,!!D&&vh(D)&&fi(K,D)&&(it(d)||na(d)))}function Gie(d){var h=d.length,x=new d.constructor(h);return h&&typeof d[0]=="string"&&Ot.call(d,"index")&&(x.index=d.index,x.input=d.input),x}function BL(d){return typeof d.constructor=="function"&&!xu(d)?pl(Up(d)):{}}function Jie(d,h,x){var k=d.constructor;switch(h){case un:return fx(d);case X:case W:return new k(+d);case $t:return Pie(d,x);case In:case Kn:case ft:case $n:case Yt:case ge:case $e:case ke:case Re:return xL(d,x);case ue:return new k;case ye:case De:return new k(d);case je:return Nie(d);case Je:return new k;case ct:return Lie(d)}}function Zie(d,h){var x=h.length;if(!x)return d;var k=x-1;return h[k]=(x>1?"& ":"")+h[k],h=h.join(x>2?", ":" "),d.replace(Qne,`{
|
|
87
87
|
/* [wrapped with `+h+`] */
|
|
88
|
-
`)}function Xie(d){return it(d)||na(d)||!!(jN&&d&&d[jN])}function fi(d,h){var x=typeof d;return h=h??K,!!h&&(x=="number"||x!="symbol"&&ure.test(d))&&d>-1&&d%1==0&&d<h}function ir(d,h,x){if(!nn(x))return!1;var k=typeof h;return(k=="number"?mr(x)&&fi(h,x.length):k=="string"&&h in x)?go(x[h],d):!1}function xx(d,h){if(it(d))return!1;var x=typeof d;return x=="number"||x=="symbol"||x=="boolean"||d==null||Mr(d)?!0:ol.test(d)||!au.test(d)||h!=null&&d in Bt(h)}function Qie(d){var h=typeof d;return h=="string"||h=="number"||h=="symbol"||h=="boolean"?d!=="__proto__":d===null}function Sx(d){var h=dh(d),x=H[h];if(typeof x!="function"||!(h in mt.prototype))return!1;if(d===x)return!0;var k=yx(x);return!!k&&d===k[0]}function ese(d){return!!RN&&RN in d}var tse=Vp?pi:Bx;function xu(d){var h=d&&d.constructor,x=typeof h=="function"&&h.prototype||ul;return d===x}function RL(d){return d===d&&!nn(d)}function zL(d,h){return function(x){return x==null?!1:x[d]===h&&(h!==n||d in Bt(x))}}function nse(d){var h=yh(d,function(k){return x.size===u&&x.clear(),k}),x=h.cache;return h}function rse(d,h){var x=d[1],k=h[1],D=x|k,j=D<(S|C|L),U=k==L&&x==_||k==L&&x==P&&d[7].length<=h[8]||k==(L|P)&&h[7].length<=h[8]&&x==_;if(!(j||U))return d;k&S&&(d[2]=h[2],D|=x&S?0:T);var X=h[3];if(X){var ie=d[3];d[3]=ie?CL(ie,X,h[4]):X,d[4]=ie?es(d[3],f):h[4]}return X=h[5],X&&(ie=d[5],d[5]=ie?wL(ie,X,h[6]):X,d[6]=ie?es(d[5],f):h[6]),X=h[7],X&&(d[7]=X),k&L&&(d[8]=d[8]==null?h[8]:Yn(d[8],h[8])),d[9]==null&&(d[9]=h[9]),d[0]=h[0],d[1]=D,d}function ose(d){var h=[];if(d!=null)for(var x in Bt(d))h.push(x);return h}function ise(d){return jp.call(d)}function VL(d,h,x){return h=wn(h===n?d.length-1:h,0),function(){for(var k=arguments,D=-1,j=wn(k.length-h,0),U=pe(j);++D<j;)U[D]=k[h+D];D=-1;for(var X=pe(h+1);++D<h;)X[D]=k[D];return X[h]=x(U),Tr(d,this,X)}}function HL(d,h){return h.length<2?d:Qs(d,Zr(h,0,-1))}function sse(d,h){for(var x=d.length,k=Yn(h.length,x),D=gr(d);k--;){var j=h[k];d[k]=fi(j,x)?D[j]:n}return d}function Cx(d,h){if(!(h==="constructor"&&typeof d[h]=="function")&&h!="__proto__")return d[h]}var jL=qL(fL),Su=Soe||function(d,h){return Bn.setTimeout(d,h)},wx=qL(Oie);function WL(d,h,x){var k=h+"";return wx(d,Zie(k,ase(Yie(k),x)))}function qL(d){var h=0,x=0;return function(){var k=Toe(),D=V-(k-x);if(x=k,D>0){if(++h>=N)return arguments[0]}else h=0;return d.apply(n,arguments)}}function ph(d,h){var x=-1,k=d.length,D=k-1;for(h=h===n?k:h;++x<h;){var j=ix(x,D),U=d[j];d[j]=d[x],d[x]=U}return d.length=h,d}var UL=nse(function(d){var h=[];return d.charCodeAt(0)===46&&h.push(""),d.replace(Jne,function(x,k,D,j){h.push(D?j.replace(ore,"$1"):k||x)}),h});function Ro(d){if(typeof d=="string"||Mr(d))return d;var h=d+"";return h=="0"&&1/d==-q?"-0":h}function ta(d){if(d!=null){try{return Hp.call(d)}catch{}try{return d+""}catch{}}return""}function ase(d,h){return Kr(oe,function(x){var k="_."+x[0];h&x[1]&&!$p(d,k)&&d.push(k)}),d.sort()}function KL(d){if(d instanceof mt)return d.clone();var h=new Gr(d.__wrapped__,d.__chain__);return h.__actions__=gr(d.__actions__),h.__index__=d.__index__,h.__values__=d.__values__,h}function lse(d,h,x){(x?ir(d,h,x):h===n)?h=1:h=wn(st(h),0);var k=d==null?0:d.length;if(!k||h<1)return[];for(var D=0,j=0,U=pe(Gp(k/h));D<k;)U[j++]=Zr(d,D,D+=h);return U}function cse(d){for(var h=-1,x=d==null?0:d.length,k=0,D=[];++h<x;){var j=d[h];j&&(D[k++]=j)}return D}function use(){var d=arguments.length;if(!d)return[];for(var h=pe(d-1),x=arguments[0],k=d;k--;)h[k-1]=arguments[k];return Qi(it(x)?gr(x):[x],Rn(h,1))}var dse=dt(function(d,h){return hn(d)?gu(d,Rn(h,1,hn,!0)):[]}),fse=dt(function(d,h){var x=Xr(h);return hn(x)&&(x=n),hn(d)?gu(d,Rn(h,1,hn,!0),Xe(x,2)):[]}),pse=dt(function(d,h){var x=Xr(h);return hn(x)&&(x=n),hn(d)?gu(d,Rn(h,1,hn,!0),n,x):[]});function hse(d,h,x){var k=d==null?0:d.length;return k?(h=x||h===n?1:st(h),Zr(d,h<0?0:h,k)):[]}function gse(d,h,x){var k=d==null?0:d.length;return k?(h=x||h===n?1:st(h),h=k-h,Zr(d,0,h<0?0:h)):[]}function mse(d,h){return d&&d.length?ih(d,Xe(h,3),!0,!0):[]}function yse(d,h){return d&&d.length?ih(d,Xe(h,3),!0):[]}function bse(d,h,x,k){var D=d==null?0:d.length;return D?(x&&typeof x!="number"&&ir(d,h,x)&&(x=0,k=D),uie(d,h,x,k)):[]}function YL(d,h,x){var k=d==null?0:d.length;if(!k)return-1;var D=x==null?0:st(x);return D<0&&(D=wn(k+D,0)),Bp(d,Xe(h,3),D)}function GL(d,h,x){var k=d==null?0:d.length;if(!k)return-1;var D=k-1;return x!==n&&(D=st(x),D=x<0?wn(k+D,0):Yn(D,k-1)),Bp(d,Xe(h,3),D,!0)}function JL(d){var h=d==null?0:d.length;return h?Rn(d,1):[]}function vse(d){var h=d==null?0:d.length;return h?Rn(d,q):[]}function xse(d,h){var x=d==null?0:d.length;return x?(h=h===n?1:st(h),Rn(d,h)):[]}function Sse(d){for(var h=-1,x=d==null?0:d.length,k={};++h<x;){var D=d[h];k[D[0]]=D[1]}return k}function ZL(d){return d&&d.length?d[0]:n}function Cse(d,h,x){var k=d==null?0:d.length;if(!k)return-1;var D=x==null?0:st(x);return D<0&&(D=wn(k+D,0)),sl(d,h,D)}function wse(d){var h=d==null?0:d.length;return h?Zr(d,0,-1):[]}var _se=dt(function(d){var h=Qt(d,ux);return h.length&&h[0]===d[0]?ex(h):[]}),Tse=dt(function(d){var h=Xr(d),x=Qt(d,ux);return h===Xr(x)?h=n:x.pop(),x.length&&x[0]===d[0]?ex(x,Xe(h,2)):[]}),kse=dt(function(d){var h=Xr(d),x=Qt(d,ux);return h=typeof h=="function"?h:n,h&&x.pop(),x.length&&x[0]===d[0]?ex(x,n,h):[]});function Ese(d,h){return d==null?"":woe.call(d,h)}function Xr(d){var h=d==null?0:d.length;return h?d[h-1]:n}function Mse(d,h,x){var k=d==null?0:d.length;if(!k)return-1;var D=k;return x!==n&&(D=st(x),D=D<0?wn(k+D,0):Yn(D,k-1)),h===h?aoe(d,h,D):Bp(d,IN,D,!0)}function Ose(d,h){return d&&d.length?lL(d,st(h)):n}var Ase=dt(XL);function XL(d,h){return d&&d.length&&h&&h.length?ox(d,h):d}function Ise(d,h,x){return d&&d.length&&h&&h.length?ox(d,h,Xe(x,2)):d}function Dse(d,h,x){return d&&d.length&&h&&h.length?ox(d,h,n,x):d}var Pse=di(function(d,h){var x=d==null?0:d.length,k=J1(d,h);return dL(d,Qt(h,function(D){return fi(D,x)?+D:D}).sort(SL)),k});function Nse(d,h){var x=[];if(!(d&&d.length))return x;var k=-1,D=[],j=d.length;for(h=Xe(h,3);++k<j;){var U=d[k];h(U,k,d)&&(x.push(U),D.push(k))}return dL(d,D),x}function _x(d){return d==null?d:Eoe.call(d)}function Lse(d,h,x){var k=d==null?0:d.length;return k?(x&&typeof x!="number"&&ir(d,h,x)?(h=0,x=k):(h=h==null?0:st(h),x=x===n?k:st(x)),Zr(d,h,x)):[]}function Fse(d,h){return oh(d,h)}function $se(d,h,x){return ax(d,h,Xe(x,2))}function Bse(d,h){var x=d==null?0:d.length;if(x){var k=oh(d,h);if(k<x&&go(d[k],h))return k}return-1}function Rse(d,h){return oh(d,h,!0)}function zse(d,h,x){return ax(d,h,Xe(x,2),!0)}function Vse(d,h){var x=d==null?0:d.length;if(x){var k=oh(d,h,!0)-1;if(go(d[k],h))return k}return-1}function Hse(d){return d&&d.length?pL(d):[]}function jse(d,h){return d&&d.length?pL(d,Xe(h,2)):[]}function Wse(d){var h=d==null?0:d.length;return h?Zr(d,1,h):[]}function qse(d,h,x){return d&&d.length?(h=x||h===n?1:st(h),Zr(d,0,h<0?0:h)):[]}function Use(d,h,x){var k=d==null?0:d.length;return k?(h=x||h===n?1:st(h),h=k-h,Zr(d,h<0?0:h,k)):[]}function Kse(d,h){return d&&d.length?ih(d,Xe(h,3),!1,!0):[]}function Yse(d,h){return d&&d.length?ih(d,Xe(h,3)):[]}var Gse=dt(function(d){return rs(Rn(d,1,hn,!0))}),Jse=dt(function(d){var h=Xr(d);return hn(h)&&(h=n),rs(Rn(d,1,hn,!0),Xe(h,2))}),Zse=dt(function(d){var h=Xr(d);return h=typeof h=="function"?h:n,rs(Rn(d,1,hn,!0),n,h)});function Xse(d){return d&&d.length?rs(d):[]}function Qse(d,h){return d&&d.length?rs(d,Xe(h,2)):[]}function eae(d,h){return h=typeof h=="function"?h:n,d&&d.length?rs(d,n,h):[]}function Tx(d){if(!(d&&d.length))return[];var h=0;return d=Xi(d,function(x){if(hn(x))return h=wn(x.length,h),!0}),H1(h,function(x){return Qt(d,R1(x))})}function QL(d,h){if(!(d&&d.length))return[];var x=Tx(d);return h==null?x:Qt(x,function(k){return Tr(h,n,k)})}var tae=dt(function(d,h){return hn(d)?gu(d,h):[]}),nae=dt(function(d){return cx(Xi(d,hn))}),rae=dt(function(d){var h=Xr(d);return hn(h)&&(h=n),cx(Xi(d,hn),Xe(h,2))}),oae=dt(function(d){var h=Xr(d);return h=typeof h=="function"?h:n,cx(Xi(d,hn),n,h)}),iae=dt(Tx);function sae(d,h){return yL(d||[],h||[],hu)}function aae(d,h){return yL(d||[],h||[],bu)}var lae=dt(function(d){var h=d.length,x=h>1?d[h-1]:n;return x=typeof x=="function"?(d.pop(),x):n,QL(d,x)});function eF(d){var h=H(d);return h.__chain__=!0,h}function cae(d,h){return h(d),d}function hh(d,h){return h(d)}var uae=di(function(d){var h=d.length,x=h?d[0]:0,k=this.__wrapped__,D=function(j){return J1(j,d)};return h>1||this.__actions__.length||!(k instanceof mt)||!fi(x)?this.thru(D):(k=k.slice(x,+x+(h?1:0)),k.__actions__.push({func:hh,args:[D],thisArg:n}),new Gr(k,this.__chain__).thru(function(j){return h&&!j.length&&j.push(n),j}))});function dae(){return eF(this)}function fae(){return new Gr(this.value(),this.__chain__)}function pae(){this.__values__===n&&(this.__values__=hF(this.value()));var d=this.__index__>=this.__values__.length,h=d?n:this.__values__[this.__index__++];return{done:d,value:h}}function hae(){return this}function gae(d){for(var h,x=this;x instanceof Qp;){var k=KL(x);k.__index__=0,k.__values__=n,h?D.__wrapped__=k:h=k;var D=k;x=x.__wrapped__}return D.__wrapped__=d,h}function mae(){var d=this.__wrapped__;if(d instanceof mt){var h=d;return this.__actions__.length&&(h=new mt(this)),h=h.reverse(),h.__actions__.push({func:hh,args:[_x],thisArg:n}),new Gr(h,this.__chain__)}return this.thru(_x)}function yae(){return mL(this.__wrapped__,this.__actions__)}var bae=sh(function(d,h,x){Ot.call(d,x)?++d[x]:ci(d,x,1)});function vae(d,h,x){var k=it(d)?ON:cie;return x&&ir(d,h,x)&&(h=n),k(d,Xe(h,3))}function xae(d,h){var x=it(d)?Xi:QN;return x(d,Xe(h,3))}var Sae=EL(YL),Cae=EL(GL);function wae(d,h){return Rn(gh(d,h),1)}function _ae(d,h){return Rn(gh(d,h),q)}function Tae(d,h,x){return x=x===n?1:st(x),Rn(gh(d,h),x)}function tF(d,h){var x=it(d)?Kr:ns;return x(d,Xe(h,3))}function nF(d,h){var x=it(d)?Wre:XN;return x(d,Xe(h,3))}var kae=sh(function(d,h,x){Ot.call(d,x)?d[x].push(h):ci(d,x,[h])});function Eae(d,h,x,k){d=mr(d)?d:bl(d),x=x&&!k?st(x):0;var D=d.length;return x<0&&(x=wn(D+x,0)),xh(d)?x<=D&&d.indexOf(h,x)>-1:!!D&&sl(d,h,x)>-1}var Mae=dt(function(d,h,x){var k=-1,D=typeof h=="function",j=mr(d)?pe(d.length):[];return ns(d,function(U){j[++k]=D?Tr(h,U,x):mu(U,h,x)}),j}),Oae=sh(function(d,h,x){ci(d,x,h)});function gh(d,h){var x=it(d)?Qt:iL;return x(d,Xe(h,3))}function Aae(d,h,x,k){return d==null?[]:(it(h)||(h=h==null?[]:[h]),x=k?n:x,it(x)||(x=x==null?[]:[x]),cL(d,h,x))}var Iae=sh(function(d,h,x){d[x?0:1].push(h)},function(){return[[],[]]});function Dae(d,h,x){var k=it(d)?$1:PN,D=arguments.length<3;return k(d,Xe(h,4),x,D,ns)}function Pae(d,h,x){var k=it(d)?qre:PN,D=arguments.length<3;return k(d,Xe(h,4),x,D,XN)}function Nae(d,h){var x=it(d)?Xi:QN;return x(d,bh(Xe(h,3)))}function Lae(d){var h=it(d)?YN:Eie;return h(d)}function Fae(d,h,x){(x?ir(d,h,x):h===n)?h=1:h=st(h);var k=it(d)?oie:Mie;return k(d,h)}function $ae(d){var h=it(d)?iie:Aie;return h(d)}function Bae(d){if(d==null)return 0;if(mr(d))return xh(d)?ll(d):d.length;var h=Gn(d);return h==de||h==Je?d.size:nx(d).length}function Rae(d,h,x){var k=it(d)?B1:Iie;return x&&ir(d,h,x)&&(h=n),k(d,Xe(h,3))}var zae=dt(function(d,h){if(d==null)return[];var x=h.length;return x>1&&ir(d,h[0],h[1])?h=[]:x>2&&ir(h[0],h[1],h[2])&&(h=[h[0]]),cL(d,Rn(h,1),[])}),mh=xoe||function(){return Bn.Date.now()};function Vae(d,h){if(typeof h!="function")throw new Yr(s);return d=st(d),function(){if(--d<1)return h.apply(this,arguments)}}function rF(d,h,x){return h=x?n:h,h=d&&h==null?d.length:h,ui(d,L,n,n,n,n,h)}function oF(d,h){var x;if(typeof h!="function")throw new Yr(s);return d=st(d),function(){return--d>0&&(x=h.apply(this,arguments)),d<=1&&(h=n),x}}var kx=dt(function(d,h,x){var k=S;if(x.length){var D=es(x,ml(kx));k|=E}return ui(d,k,h,x,D)}),iF=dt(function(d,h,x){var k=S|C;if(x.length){var D=es(x,ml(iF));k|=E}return ui(h,k,d,x,D)});function sF(d,h,x){h=x?n:h;var k=ui(d,_,n,n,n,n,n,h);return k.placeholder=sF.placeholder,k}function aF(d,h,x){h=x?n:h;var k=ui(d,w,n,n,n,n,n,h);return k.placeholder=aF.placeholder,k}function lF(d,h,x){var k,D,j,U,X,ie,Ce=0,we=!1,Ee=!1,Ne=!0;if(typeof d!="function")throw new Yr(s);h=Qr(h)||0,nn(x)&&(we=!!x.leading,Ee="maxWait"in x,j=Ee?wn(Qr(x.maxWait)||0,h):j,Ne="trailing"in x?!!x.trailing:Ne);function We(gn){var mo=k,gi=D;return k=D=n,Ce=gn,U=d.apply(gi,mo),U}function et(gn){return Ce=gn,X=Su(ht,h),we?We(gn):U}function ut(gn){var mo=gn-ie,gi=gn-Ce,EF=h-mo;return Ee?Yn(EF,j-gi):EF}function tt(gn){var mo=gn-ie,gi=gn-Ce;return ie===n||mo>=h||mo<0||Ee&&gi>=j}function ht(){var gn=mh();if(tt(gn))return xt(gn);X=Su(ht,ut(gn))}function xt(gn){return X=n,Ne&&k?We(gn):(k=D=n,U)}function Or(){X!==n&&bL(X),Ce=0,k=ie=D=X=n}function sr(){return X===n?U:xt(mh())}function Ar(){var gn=mh(),mo=tt(gn);if(k=arguments,D=this,ie=gn,mo){if(X===n)return et(ie);if(Ee)return bL(X),X=Su(ht,h),We(ie)}return X===n&&(X=Su(ht,h)),U}return Ar.cancel=Or,Ar.flush=sr,Ar}var Hae=dt(function(d,h){return ZN(d,1,h)}),jae=dt(function(d,h,x){return ZN(d,Qr(h)||0,x)});function Wae(d){return ui(d,$)}function yh(d,h){if(typeof d!="function"||h!=null&&typeof h!="function")throw new Yr(s);var x=function(){var k=arguments,D=h?h.apply(this,k):k[0],j=x.cache;if(j.has(D))return j.get(D);var U=d.apply(this,k);return x.cache=j.set(D,U)||j,U};return x.cache=new(yh.Cache||li),x}yh.Cache=li;function bh(d){if(typeof d!="function")throw new Yr(s);return function(){var h=arguments;switch(h.length){case 0:return!d.call(this);case 1:return!d.call(this,h[0]);case 2:return!d.call(this,h[0],h[1]);case 3:return!d.call(this,h[0],h[1],h[2])}return!d.apply(this,h)}}function qae(d){return oF(2,d)}var Uae=Die(function(d,h){h=h.length==1&&it(h[0])?Qt(h[0],kr(Xe())):Qt(Rn(h,1),kr(Xe()));var x=h.length;return dt(function(k){for(var D=-1,j=Yn(k.length,x);++D<j;)k[D]=h[D].call(this,k[D]);return Tr(d,this,k)})}),Ex=dt(function(d,h){var x=es(h,ml(Ex));return ui(d,E,n,h,x)}),cF=dt(function(d,h){var x=es(h,ml(cF));return ui(d,O,n,h,x)}),Kae=di(function(d,h){return ui(d,P,n,n,n,h)});function Yae(d,h){if(typeof d!="function")throw new Yr(s);return h=h===n?h:st(h),dt(d,h)}function Gae(d,h){if(typeof d!="function")throw new Yr(s);return h=h==null?0:wn(st(h),0),dt(function(x){var k=x[h],D=ss(x,0,h);return k&&Qi(D,k),Tr(d,this,D)})}function Jae(d,h,x){var k=!0,D=!0;if(typeof d!="function")throw new Yr(s);return nn(x)&&(k="leading"in x?!!x.leading:k,D="trailing"in x?!!x.trailing:D),lF(d,h,{leading:k,maxWait:h,trailing:D})}function Zae(d){return rF(d,1)}function Xae(d,h){return Ex(dx(h),d)}function Qae(){if(!arguments.length)return[];var d=arguments[0];return it(d)?d:[d]}function ele(d){return Jr(d,m)}function tle(d,h){return h=typeof h=="function"?h:n,Jr(d,m,h)}function nle(d){return Jr(d,p|m)}function rle(d,h){return h=typeof h=="function"?h:n,Jr(d,p|m,h)}function ole(d,h){return h==null||JN(d,h,Dn(h))}function go(d,h){return d===h||d!==d&&h!==h}var ile=uh(Q1),sle=uh(function(d,h){return d>=h}),na=nL(function(){return arguments}())?nL:function(d){return dn(d)&&Ot.call(d,"callee")&&!HN.call(d,"callee")},it=pe.isArray,ale=wN?kr(wN):gie;function mr(d){return d!=null&&vh(d.length)&&!pi(d)}function hn(d){return dn(d)&&mr(d)}function lle(d){return d===!0||d===!1||dn(d)&&or(d)==ae}var as=Coe||Bx,cle=_N?kr(_N):mie;function ule(d){return dn(d)&&d.nodeType===1&&!Cu(d)}function dle(d){if(d==null)return!0;if(mr(d)&&(it(d)||typeof d=="string"||typeof d.splice=="function"||as(d)||yl(d)||na(d)))return!d.length;var h=Gn(d);if(h==de||h==Je)return!d.size;if(xu(d))return!nx(d).length;for(var x in d)if(Ot.call(d,x))return!1;return!0}function fle(d,h){return yu(d,h)}function ple(d,h,x){x=typeof x=="function"?x:n;var k=x?x(d,h):n;return k===n?yu(d,h,n,x):!!k}function Mx(d){if(!dn(d))return!1;var h=or(d);return h==ue||h==te||typeof d.message=="string"&&typeof d.name=="string"&&!Cu(d)}function hle(d){return typeof d=="number"&&WN(d)}function pi(d){if(!nn(d))return!1;var h=or(d);return h==ee||h==se||h==ce||h==Fe}function uF(d){return typeof d=="number"&&d==st(d)}function vh(d){return typeof d=="number"&&d>-1&&d%1==0&&d<=K}function nn(d){var h=typeof d;return d!=null&&(h=="object"||h=="function")}function dn(d){return d!=null&&typeof d=="object"}var dF=TN?kr(TN):bie;function gle(d,h){return d===h||tx(d,h,bx(h))}function mle(d,h,x){return x=typeof x=="function"?x:n,tx(d,h,bx(h),x)}function yle(d){return fF(d)&&d!=+d}function ble(d){if(tse(d))throw new ot(i);return rL(d)}function vle(d){return d===null}function xle(d){return d==null}function fF(d){return typeof d=="number"||dn(d)&&or(d)==ye}function Cu(d){if(!dn(d)||or(d)!=Se)return!1;var h=Up(d);if(h===null)return!0;var x=Ot.call(h,"constructor")&&h.constructor;return typeof x=="function"&&x instanceof x&&Hp.call(x)==moe}var Ox=kN?kr(kN):vie;function Sle(d){return uF(d)&&d>=-K&&d<=K}var pF=EN?kr(EN):xie;function xh(d){return typeof d=="string"||!it(d)&&dn(d)&&or(d)==De}function Mr(d){return typeof d=="symbol"||dn(d)&&or(d)==ct}var yl=MN?kr(MN):Sie;function Cle(d){return d===n}function wle(d){return dn(d)&&Gn(d)==Xt}function _le(d){return dn(d)&&or(d)==Sn}var Tle=uh(rx),kle=uh(function(d,h){return d<=h});function hF(d){if(!d)return[];if(mr(d))return xh(d)?po(d):gr(d);if(cu&&d[cu])return ooe(d[cu]());var h=Gn(d),x=h==de?W1:h==Je?Rp:bl;return x(d)}function hi(d){if(!d)return d===0?d:0;if(d=Qr(d),d===q||d===-q){var h=d<0?-1:1;return h*G}return d===d?d:0}function st(d){var h=hi(d),x=h%1;return h===h?x?h-x:h:0}function gF(d){return d?Xs(st(d),0,Z):0}function Qr(d){if(typeof d=="number")return d;if(Mr(d))return Y;if(nn(d)){var h=typeof d.valueOf=="function"?d.valueOf():d;d=nn(h)?h+"":h}if(typeof d!="string")return d===0?d:+d;d=NN(d);var x=are.test(d);return x||cre.test(d)?Vre(d.slice(2),x?2:8):sre.test(d)?Y:+d}function mF(d){return Bo(d,yr(d))}function Ele(d){return d?Xs(st(d),-K,K):d===0?d:0}function Mt(d){return d==null?"":Er(d)}var Mle=hl(function(d,h){if(xu(h)||mr(h)){Bo(h,Dn(h),d);return}for(var x in h)Ot.call(h,x)&&hu(d,x,h[x])}),yF=hl(function(d,h){Bo(h,yr(h),d)}),Sh=hl(function(d,h,x,k){Bo(h,yr(h),d,k)}),Ole=hl(function(d,h,x,k){Bo(h,Dn(h),d,k)}),Ale=di(J1);function Ile(d,h){var x=pl(d);return h==null?x:GN(x,h)}var Dle=dt(function(d,h){d=Bt(d);var x=-1,k=h.length,D=k>2?h[2]:n;for(D&&ir(h[0],h[1],D)&&(k=1);++x<k;)for(var j=h[x],U=yr(j),X=-1,ie=U.length;++X<ie;){var Ce=U[X],we=d[Ce];(we===n||go(we,ul[Ce])&&!Ot.call(d,Ce))&&(d[Ce]=j[Ce])}return d}),Ple=dt(function(d){return d.push(n,NL),Tr(bF,n,d)});function Nle(d,h){return AN(d,Xe(h,3),$o)}function Lle(d,h){return AN(d,Xe(h,3),X1)}function Fle(d,h){return d==null?d:Z1(d,Xe(h,3),yr)}function $le(d,h){return d==null?d:eL(d,Xe(h,3),yr)}function Ble(d,h){return d&&$o(d,Xe(h,3))}function Rle(d,h){return d&&X1(d,Xe(h,3))}function zle(d){return d==null?[]:nh(d,Dn(d))}function Vle(d){return d==null?[]:nh(d,yr(d))}function Ax(d,h,x){var k=d==null?n:Qs(d,h);return k===n?x:k}function Hle(d,h){return d!=null&&$L(d,h,die)}function Ix(d,h){return d!=null&&$L(d,h,fie)}var jle=OL(function(d,h,x){h!=null&&typeof h.toString!="function"&&(h=jp.call(h)),d[h]=x},Px(br)),Wle=OL(function(d,h,x){h!=null&&typeof h.toString!="function"&&(h=jp.call(h)),Ot.call(d,h)?d[h].push(x):d[h]=[x]},Xe),qle=dt(mu);function Dn(d){return mr(d)?KN(d):nx(d)}function yr(d){return mr(d)?KN(d,!0):Cie(d)}function Ule(d,h){var x={};return h=Xe(h,3),$o(d,function(k,D,j){ci(x,h(k,D,j),k)}),x}function Kle(d,h){var x={};return h=Xe(h,3),$o(d,function(k,D,j){ci(x,D,h(k,D,j))}),x}var Yle=hl(function(d,h,x){rh(d,h,x)}),bF=hl(function(d,h,x,k){rh(d,h,x,k)}),Gle=di(function(d,h){var x={};if(d==null)return x;var k=!1;h=Qt(h,function(j){return j=is(j,d),k||(k=j.length>1),j}),Bo(d,mx(d),x),k&&(x=Jr(x,p|g|m,jie));for(var D=h.length;D--;)lx(x,h[D]);return x});function Jle(d,h){return vF(d,bh(Xe(h)))}var Zle=di(function(d,h){return d==null?{}:_ie(d,h)});function vF(d,h){if(d==null)return{};var x=Qt(mx(d),function(k){return[k]});return h=Xe(h),uL(d,x,function(k,D){return h(k,D[0])})}function Xle(d,h,x){h=is(h,d);var k=-1,D=h.length;for(D||(D=1,d=n);++k<D;){var j=d==null?n:d[Ro(h[k])];j===n&&(k=D,j=x),d=pi(j)?j.call(d):j}return d}function Qle(d,h,x){return d==null?d:bu(d,h,x)}function ece(d,h,x,k){return k=typeof k=="function"?k:n,d==null?d:bu(d,h,x,k)}var xF=DL(Dn),SF=DL(yr);function tce(d,h,x){var k=it(d),D=k||as(d)||yl(d);if(h=Xe(h,4),x==null){var j=d&&d.constructor;D?x=k?new j:[]:nn(d)?x=pi(j)?pl(Up(d)):{}:x={}}return(D?Kr:$o)(d,function(U,X,ie){return h(x,U,X,ie)}),x}function nce(d,h){return d==null?!0:lx(d,h)}function rce(d,h,x){return d==null?d:gL(d,h,dx(x))}function oce(d,h,x,k){return k=typeof k=="function"?k:n,d==null?d:gL(d,h,dx(x),k)}function bl(d){return d==null?[]:j1(d,Dn(d))}function ice(d){return d==null?[]:j1(d,yr(d))}function sce(d,h,x){return x===n&&(x=h,h=n),x!==n&&(x=Qr(x),x=x===x?x:0),h!==n&&(h=Qr(h),h=h===h?h:0),Xs(Qr(d),h,x)}function ace(d,h,x){return h=hi(h),x===n?(x=h,h=0):x=hi(x),d=Qr(d),pie(d,h,x)}function lce(d,h,x){if(x&&typeof x!="boolean"&&ir(d,h,x)&&(h=x=n),x===n&&(typeof h=="boolean"?(x=h,h=n):typeof d=="boolean"&&(x=d,d=n)),d===n&&h===n?(d=0,h=1):(d=hi(d),h===n?(h=d,d=0):h=hi(h)),d>h){var k=d;d=h,h=k}if(x||d%1||h%1){var D=qN();return Yn(d+D*(h-d+zre("1e-"+((D+"").length-1))),h)}return ix(d,h)}var cce=gl(function(d,h,x){return h=h.toLowerCase(),d+(x?CF(h):h)});function CF(d){return Dx(Mt(d).toLowerCase())}function wF(d){return d=Mt(d),d&&d.replace(dre,Qre).replace(Are,"")}function uce(d,h,x){d=Mt(d),h=Er(h);var k=d.length;x=x===n?k:Xs(st(x),0,k);var D=x;return x-=h.length,x>=0&&d.slice(x,D)==h}function dce(d){return d=Mt(d),d&&su.test(d)?d.replace(hr,eoe):d}function fce(d){return d=Mt(d),d&&Zne.test(d)?d.replace(E1,"\\$&"):d}var pce=gl(function(d,h,x){return d+(x?"-":"")+h.toLowerCase()}),hce=gl(function(d,h,x){return d+(x?" ":"")+h.toLowerCase()}),gce=kL("toLowerCase");function mce(d,h,x){d=Mt(d),h=st(h);var k=h?ll(d):0;if(!h||k>=h)return d;var D=(h-k)/2;return ch(Jp(D),x)+d+ch(Gp(D),x)}function yce(d,h,x){d=Mt(d),h=st(h);var k=h?ll(d):0;return h&&k<h?d+ch(h-k,x):d}function bce(d,h,x){d=Mt(d),h=st(h);var k=h?ll(d):0;return h&&k<h?ch(h-k,x)+d:d}function vce(d,h,x){return x||h==null?h=0:h&&(h=+h),koe(Mt(d).replace(M1,""),h||0)}function xce(d,h,x){return(x?ir(d,h,x):h===n)?h=1:h=st(h),sx(Mt(d),h)}function Sce(){var d=arguments,h=Mt(d[0]);return d.length<3?h:h.replace(d[1],d[2])}var Cce=gl(function(d,h,x){return d+(x?"_":"")+h.toLowerCase()});function wce(d,h,x){return x&&typeof x!="number"&&ir(d,h,x)&&(h=x=n),x=x===n?Z:x>>>0,x?(d=Mt(d),d&&(typeof h=="string"||h!=null&&!Ox(h))&&(h=Er(h),!h&&al(d))?ss(po(d),0,x):d.split(h,x)):[]}var _ce=gl(function(d,h,x){return d+(x?" ":"")+Dx(h)});function Tce(d,h,x){return d=Mt(d),x=x==null?0:Xs(st(x),0,d.length),h=Er(h),d.slice(x,x+h.length)==h}function kce(d,h,x){var k=H.templateSettings;x&&ir(d,h,x)&&(h=n),d=Mt(d),h=Sh({},h,k,PL);var D=Sh({},h.imports,k.imports,PL),j=Dn(D),U=j1(D,j),X,ie,Ce=0,we=h.interpolate||Np,Ee="__p += '",Ne=q1((h.escape||Np).source+"|"+we.source+"|"+(we===Pp?ire:Np).source+"|"+(h.evaluate||Np).source+"|$","g"),We="//# sourceURL="+(Ot.call(h,"sourceURL")?(h.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++Lre+"]")+`
|
|
89
|
-
`;d.replace(Ne,function(tt,ht,xt,Or,sr,Ar){return xt||(xt=Or),Ee+=d.slice(Ce,Ar).replace(fre,toe),ht&&(
|
|
88
|
+
`)}function Xie(d){return it(d)||na(d)||!!(jN&&d&&d[jN])}function fi(d,h){var x=typeof d;return h=h??U,!!h&&(x=="number"||x!="symbol"&&ure.test(d))&&d>-1&&d%1==0&&d<h}function ir(d,h,x){if(!nn(x))return!1;var k=typeof h;return(k=="number"?mr(x)&&fi(h,x.length):k=="string"&&h in x)?go(x[h],d):!1}function xx(d,h){if(it(d))return!1;var x=typeof d;return x=="number"||x=="symbol"||x=="boolean"||d==null||Mr(d)?!0:ol.test(d)||!au.test(d)||h!=null&&d in Bt(h)}function Qie(d){var h=typeof d;return h=="string"||h=="number"||h=="symbol"||h=="boolean"?d!=="__proto__":d===null}function Sx(d){var h=dh(d),x=H[h];if(typeof x!="function"||!(h in mt.prototype))return!1;if(d===x)return!0;var k=yx(x);return!!k&&d===k[0]}function ese(d){return!!RN&&RN in d}var tse=Vp?pi:Bx;function xu(d){var h=d&&d.constructor,x=typeof h=="function"&&h.prototype||ul;return d===x}function RL(d){return d===d&&!nn(d)}function zL(d,h){return function(x){return x==null?!1:x[d]===h&&(h!==n||d in Bt(x))}}function nse(d){var h=yh(d,function(k){return x.size===u&&x.clear(),k}),x=h.cache;return h}function rse(d,h){var x=d[1],k=h[1],D=x|k,j=D<(S|C|L),K=k==L&&x==_||k==L&&x==P&&d[7].length<=h[8]||k==(L|P)&&h[7].length<=h[8]&&x==_;if(!(j||K))return d;k&S&&(d[2]=h[2],D|=x&S?0:T);var Q=h[3];if(Q){var ie=d[3];d[3]=ie?CL(ie,Q,h[4]):Q,d[4]=ie?es(d[3],f):h[4]}return Q=h[5],Q&&(ie=d[5],d[5]=ie?wL(ie,Q,h[6]):Q,d[6]=ie?es(d[5],f):h[6]),Q=h[7],Q&&(d[7]=Q),k&L&&(d[8]=d[8]==null?h[8]:Yn(d[8],h[8])),d[9]==null&&(d[9]=h[9]),d[0]=h[0],d[1]=D,d}function ose(d){var h=[];if(d!=null)for(var x in Bt(d))h.push(x);return h}function ise(d){return jp.call(d)}function VL(d,h,x){return h=wn(h===n?d.length-1:h,0),function(){for(var k=arguments,D=-1,j=wn(k.length-h,0),K=de(j);++D<j;)K[D]=k[h+D];D=-1;for(var Q=de(h+1);++D<h;)Q[D]=k[D];return Q[h]=x(K),Tr(d,this,Q)}}function HL(d,h){return h.length<2?d:Qs(d,Zr(h,0,-1))}function sse(d,h){for(var x=d.length,k=Yn(h.length,x),D=gr(d);k--;){var j=h[k];d[k]=fi(j,x)?D[j]:n}return d}function Cx(d,h){if(!(h==="constructor"&&typeof d[h]=="function")&&h!="__proto__")return d[h]}var jL=qL(fL),Su=Soe||function(d,h){return Bn.setTimeout(d,h)},wx=qL(Oie);function WL(d,h,x){var k=h+"";return wx(d,Zie(k,ase(Yie(k),x)))}function qL(d){var h=0,x=0;return function(){var k=Toe(),D=z-(k-x);if(x=k,D>0){if(++h>=N)return arguments[0]}else h=0;return d.apply(n,arguments)}}function ph(d,h){var x=-1,k=d.length,D=k-1;for(h=h===n?k:h;++x<h;){var j=ix(x,D),K=d[j];d[j]=d[x],d[x]=K}return d.length=h,d}var UL=nse(function(d){var h=[];return d.charCodeAt(0)===46&&h.push(""),d.replace(Jne,function(x,k,D,j){h.push(D?j.replace(ore,"$1"):k||x)}),h});function Ro(d){if(typeof d=="string"||Mr(d))return d;var h=d+"";return h=="0"&&1/d==-q?"-0":h}function ta(d){if(d!=null){try{return Hp.call(d)}catch{}try{return d+""}catch{}}return""}function ase(d,h){return Kr(me,function(x){var k="_."+x[0];h&x[1]&&!$p(d,k)&&d.push(k)}),d.sort()}function KL(d){if(d instanceof mt)return d.clone();var h=new Gr(d.__wrapped__,d.__chain__);return h.__actions__=gr(d.__actions__),h.__index__=d.__index__,h.__values__=d.__values__,h}function lse(d,h,x){(x?ir(d,h,x):h===n)?h=1:h=wn(st(h),0);var k=d==null?0:d.length;if(!k||h<1)return[];for(var D=0,j=0,K=de(Gp(k/h));D<k;)K[j++]=Zr(d,D,D+=h);return K}function cse(d){for(var h=-1,x=d==null?0:d.length,k=0,D=[];++h<x;){var j=d[h];j&&(D[k++]=j)}return D}function use(){var d=arguments.length;if(!d)return[];for(var h=de(d-1),x=arguments[0],k=d;k--;)h[k-1]=arguments[k];return Qi(it(x)?gr(x):[x],Rn(h,1))}var dse=dt(function(d,h){return hn(d)?gu(d,Rn(h,1,hn,!0)):[]}),fse=dt(function(d,h){var x=Xr(h);return hn(x)&&(x=n),hn(d)?gu(d,Rn(h,1,hn,!0),Xe(x,2)):[]}),pse=dt(function(d,h){var x=Xr(h);return hn(x)&&(x=n),hn(d)?gu(d,Rn(h,1,hn,!0),n,x):[]});function hse(d,h,x){var k=d==null?0:d.length;return k?(h=x||h===n?1:st(h),Zr(d,h<0?0:h,k)):[]}function gse(d,h,x){var k=d==null?0:d.length;return k?(h=x||h===n?1:st(h),h=k-h,Zr(d,0,h<0?0:h)):[]}function mse(d,h){return d&&d.length?ih(d,Xe(h,3),!0,!0):[]}function yse(d,h){return d&&d.length?ih(d,Xe(h,3),!0):[]}function bse(d,h,x,k){var D=d==null?0:d.length;return D?(x&&typeof x!="number"&&ir(d,h,x)&&(x=0,k=D),uie(d,h,x,k)):[]}function YL(d,h,x){var k=d==null?0:d.length;if(!k)return-1;var D=x==null?0:st(x);return D<0&&(D=wn(k+D,0)),Bp(d,Xe(h,3),D)}function GL(d,h,x){var k=d==null?0:d.length;if(!k)return-1;var D=k-1;return x!==n&&(D=st(x),D=x<0?wn(k+D,0):Yn(D,k-1)),Bp(d,Xe(h,3),D,!0)}function JL(d){var h=d==null?0:d.length;return h?Rn(d,1):[]}function vse(d){var h=d==null?0:d.length;return h?Rn(d,q):[]}function xse(d,h){var x=d==null?0:d.length;return x?(h=h===n?1:st(h),Rn(d,h)):[]}function Sse(d){for(var h=-1,x=d==null?0:d.length,k={};++h<x;){var D=d[h];k[D[0]]=D[1]}return k}function ZL(d){return d&&d.length?d[0]:n}function Cse(d,h,x){var k=d==null?0:d.length;if(!k)return-1;var D=x==null?0:st(x);return D<0&&(D=wn(k+D,0)),sl(d,h,D)}function wse(d){var h=d==null?0:d.length;return h?Zr(d,0,-1):[]}var _se=dt(function(d){var h=Qt(d,ux);return h.length&&h[0]===d[0]?ex(h):[]}),Tse=dt(function(d){var h=Xr(d),x=Qt(d,ux);return h===Xr(x)?h=n:x.pop(),x.length&&x[0]===d[0]?ex(x,Xe(h,2)):[]}),kse=dt(function(d){var h=Xr(d),x=Qt(d,ux);return h=typeof h=="function"?h:n,h&&x.pop(),x.length&&x[0]===d[0]?ex(x,n,h):[]});function Ese(d,h){return d==null?"":woe.call(d,h)}function Xr(d){var h=d==null?0:d.length;return h?d[h-1]:n}function Mse(d,h,x){var k=d==null?0:d.length;if(!k)return-1;var D=k;return x!==n&&(D=st(x),D=D<0?wn(k+D,0):Yn(D,k-1)),h===h?aoe(d,h,D):Bp(d,IN,D,!0)}function Ose(d,h){return d&&d.length?lL(d,st(h)):n}var Ase=dt(XL);function XL(d,h){return d&&d.length&&h&&h.length?ox(d,h):d}function Ise(d,h,x){return d&&d.length&&h&&h.length?ox(d,h,Xe(x,2)):d}function Dse(d,h,x){return d&&d.length&&h&&h.length?ox(d,h,n,x):d}var Pse=di(function(d,h){var x=d==null?0:d.length,k=J1(d,h);return dL(d,Qt(h,function(D){return fi(D,x)?+D:D}).sort(SL)),k});function Nse(d,h){var x=[];if(!(d&&d.length))return x;var k=-1,D=[],j=d.length;for(h=Xe(h,3);++k<j;){var K=d[k];h(K,k,d)&&(x.push(K),D.push(k))}return dL(d,D),x}function _x(d){return d==null?d:Eoe.call(d)}function Lse(d,h,x){var k=d==null?0:d.length;return k?(x&&typeof x!="number"&&ir(d,h,x)?(h=0,x=k):(h=h==null?0:st(h),x=x===n?k:st(x)),Zr(d,h,x)):[]}function Fse(d,h){return oh(d,h)}function $se(d,h,x){return ax(d,h,Xe(x,2))}function Bse(d,h){var x=d==null?0:d.length;if(x){var k=oh(d,h);if(k<x&&go(d[k],h))return k}return-1}function Rse(d,h){return oh(d,h,!0)}function zse(d,h,x){return ax(d,h,Xe(x,2),!0)}function Vse(d,h){var x=d==null?0:d.length;if(x){var k=oh(d,h,!0)-1;if(go(d[k],h))return k}return-1}function Hse(d){return d&&d.length?pL(d):[]}function jse(d,h){return d&&d.length?pL(d,Xe(h,2)):[]}function Wse(d){var h=d==null?0:d.length;return h?Zr(d,1,h):[]}function qse(d,h,x){return d&&d.length?(h=x||h===n?1:st(h),Zr(d,0,h<0?0:h)):[]}function Use(d,h,x){var k=d==null?0:d.length;return k?(h=x||h===n?1:st(h),h=k-h,Zr(d,h<0?0:h,k)):[]}function Kse(d,h){return d&&d.length?ih(d,Xe(h,3),!1,!0):[]}function Yse(d,h){return d&&d.length?ih(d,Xe(h,3)):[]}var Gse=dt(function(d){return rs(Rn(d,1,hn,!0))}),Jse=dt(function(d){var h=Xr(d);return hn(h)&&(h=n),rs(Rn(d,1,hn,!0),Xe(h,2))}),Zse=dt(function(d){var h=Xr(d);return h=typeof h=="function"?h:n,rs(Rn(d,1,hn,!0),n,h)});function Xse(d){return d&&d.length?rs(d):[]}function Qse(d,h){return d&&d.length?rs(d,Xe(h,2)):[]}function eae(d,h){return h=typeof h=="function"?h:n,d&&d.length?rs(d,n,h):[]}function Tx(d){if(!(d&&d.length))return[];var h=0;return d=Xi(d,function(x){if(hn(x))return h=wn(x.length,h),!0}),H1(h,function(x){return Qt(d,R1(x))})}function QL(d,h){if(!(d&&d.length))return[];var x=Tx(d);return h==null?x:Qt(x,function(k){return Tr(h,n,k)})}var tae=dt(function(d,h){return hn(d)?gu(d,h):[]}),nae=dt(function(d){return cx(Xi(d,hn))}),rae=dt(function(d){var h=Xr(d);return hn(h)&&(h=n),cx(Xi(d,hn),Xe(h,2))}),oae=dt(function(d){var h=Xr(d);return h=typeof h=="function"?h:n,cx(Xi(d,hn),n,h)}),iae=dt(Tx);function sae(d,h){return yL(d||[],h||[],hu)}function aae(d,h){return yL(d||[],h||[],bu)}var lae=dt(function(d){var h=d.length,x=h>1?d[h-1]:n;return x=typeof x=="function"?(d.pop(),x):n,QL(d,x)});function eF(d){var h=H(d);return h.__chain__=!0,h}function cae(d,h){return h(d),d}function hh(d,h){return h(d)}var uae=di(function(d){var h=d.length,x=h?d[0]:0,k=this.__wrapped__,D=function(j){return J1(j,d)};return h>1||this.__actions__.length||!(k instanceof mt)||!fi(x)?this.thru(D):(k=k.slice(x,+x+(h?1:0)),k.__actions__.push({func:hh,args:[D],thisArg:n}),new Gr(k,this.__chain__).thru(function(j){return h&&!j.length&&j.push(n),j}))});function dae(){return eF(this)}function fae(){return new Gr(this.value(),this.__chain__)}function pae(){this.__values__===n&&(this.__values__=hF(this.value()));var d=this.__index__>=this.__values__.length,h=d?n:this.__values__[this.__index__++];return{done:d,value:h}}function hae(){return this}function gae(d){for(var h,x=this;x instanceof Qp;){var k=KL(x);k.__index__=0,k.__values__=n,h?D.__wrapped__=k:h=k;var D=k;x=x.__wrapped__}return D.__wrapped__=d,h}function mae(){var d=this.__wrapped__;if(d instanceof mt){var h=d;return this.__actions__.length&&(h=new mt(this)),h=h.reverse(),h.__actions__.push({func:hh,args:[_x],thisArg:n}),new Gr(h,this.__chain__)}return this.thru(_x)}function yae(){return mL(this.__wrapped__,this.__actions__)}var bae=sh(function(d,h,x){Ot.call(d,x)?++d[x]:ci(d,x,1)});function vae(d,h,x){var k=it(d)?ON:cie;return x&&ir(d,h,x)&&(h=n),k(d,Xe(h,3))}function xae(d,h){var x=it(d)?Xi:QN;return x(d,Xe(h,3))}var Sae=EL(YL),Cae=EL(GL);function wae(d,h){return Rn(gh(d,h),1)}function _ae(d,h){return Rn(gh(d,h),q)}function Tae(d,h,x){return x=x===n?1:st(x),Rn(gh(d,h),x)}function tF(d,h){var x=it(d)?Kr:ns;return x(d,Xe(h,3))}function nF(d,h){var x=it(d)?Wre:XN;return x(d,Xe(h,3))}var kae=sh(function(d,h,x){Ot.call(d,x)?d[x].push(h):ci(d,x,[h])});function Eae(d,h,x,k){d=mr(d)?d:bl(d),x=x&&!k?st(x):0;var D=d.length;return x<0&&(x=wn(D+x,0)),xh(d)?x<=D&&d.indexOf(h,x)>-1:!!D&&sl(d,h,x)>-1}var Mae=dt(function(d,h,x){var k=-1,D=typeof h=="function",j=mr(d)?de(d.length):[];return ns(d,function(K){j[++k]=D?Tr(h,K,x):mu(K,h,x)}),j}),Oae=sh(function(d,h,x){ci(d,x,h)});function gh(d,h){var x=it(d)?Qt:iL;return x(d,Xe(h,3))}function Aae(d,h,x,k){return d==null?[]:(it(h)||(h=h==null?[]:[h]),x=k?n:x,it(x)||(x=x==null?[]:[x]),cL(d,h,x))}var Iae=sh(function(d,h,x){d[x?0:1].push(h)},function(){return[[],[]]});function Dae(d,h,x){var k=it(d)?$1:PN,D=arguments.length<3;return k(d,Xe(h,4),x,D,ns)}function Pae(d,h,x){var k=it(d)?qre:PN,D=arguments.length<3;return k(d,Xe(h,4),x,D,XN)}function Nae(d,h){var x=it(d)?Xi:QN;return x(d,bh(Xe(h,3)))}function Lae(d){var h=it(d)?YN:Eie;return h(d)}function Fae(d,h,x){(x?ir(d,h,x):h===n)?h=1:h=st(h);var k=it(d)?oie:Mie;return k(d,h)}function $ae(d){var h=it(d)?iie:Aie;return h(d)}function Bae(d){if(d==null)return 0;if(mr(d))return xh(d)?ll(d):d.length;var h=Gn(d);return h==ue||h==Je?d.size:nx(d).length}function Rae(d,h,x){var k=it(d)?B1:Iie;return x&&ir(d,h,x)&&(h=n),k(d,Xe(h,3))}var zae=dt(function(d,h){if(d==null)return[];var x=h.length;return x>1&&ir(d,h[0],h[1])?h=[]:x>2&&ir(h[0],h[1],h[2])&&(h=[h[0]]),cL(d,Rn(h,1),[])}),mh=xoe||function(){return Bn.Date.now()};function Vae(d,h){if(typeof h!="function")throw new Yr(s);return d=st(d),function(){if(--d<1)return h.apply(this,arguments)}}function rF(d,h,x){return h=x?n:h,h=d&&h==null?d.length:h,ui(d,L,n,n,n,n,h)}function oF(d,h){var x;if(typeof h!="function")throw new Yr(s);return d=st(d),function(){return--d>0&&(x=h.apply(this,arguments)),d<=1&&(h=n),x}}var kx=dt(function(d,h,x){var k=S;if(x.length){var D=es(x,ml(kx));k|=E}return ui(d,k,h,x,D)}),iF=dt(function(d,h,x){var k=S|C;if(x.length){var D=es(x,ml(iF));k|=E}return ui(h,k,d,x,D)});function sF(d,h,x){h=x?n:h;var k=ui(d,_,n,n,n,n,n,h);return k.placeholder=sF.placeholder,k}function aF(d,h,x){h=x?n:h;var k=ui(d,w,n,n,n,n,n,h);return k.placeholder=aF.placeholder,k}function lF(d,h,x){var k,D,j,K,Q,ie,Ce=0,we=!1,Ee=!1,Ne=!0;if(typeof d!="function")throw new Yr(s);h=Qr(h)||0,nn(x)&&(we=!!x.leading,Ee="maxWait"in x,j=Ee?wn(Qr(x.maxWait)||0,h):j,Ne="trailing"in x?!!x.trailing:Ne);function We(gn){var mo=k,gi=D;return k=D=n,Ce=gn,K=d.apply(gi,mo),K}function et(gn){return Ce=gn,Q=Su(ht,h),we?We(gn):K}function ut(gn){var mo=gn-ie,gi=gn-Ce,EF=h-mo;return Ee?Yn(EF,j-gi):EF}function tt(gn){var mo=gn-ie,gi=gn-Ce;return ie===n||mo>=h||mo<0||Ee&&gi>=j}function ht(){var gn=mh();if(tt(gn))return xt(gn);Q=Su(ht,ut(gn))}function xt(gn){return Q=n,Ne&&k?We(gn):(k=D=n,K)}function Or(){Q!==n&&bL(Q),Ce=0,k=ie=D=Q=n}function sr(){return Q===n?K:xt(mh())}function Ar(){var gn=mh(),mo=tt(gn);if(k=arguments,D=this,ie=gn,mo){if(Q===n)return et(ie);if(Ee)return bL(Q),Q=Su(ht,h),We(ie)}return Q===n&&(Q=Su(ht,h)),K}return Ar.cancel=Or,Ar.flush=sr,Ar}var Hae=dt(function(d,h){return ZN(d,1,h)}),jae=dt(function(d,h,x){return ZN(d,Qr(h)||0,x)});function Wae(d){return ui(d,$)}function yh(d,h){if(typeof d!="function"||h!=null&&typeof h!="function")throw new Yr(s);var x=function(){var k=arguments,D=h?h.apply(this,k):k[0],j=x.cache;if(j.has(D))return j.get(D);var K=d.apply(this,k);return x.cache=j.set(D,K)||j,K};return x.cache=new(yh.Cache||li),x}yh.Cache=li;function bh(d){if(typeof d!="function")throw new Yr(s);return function(){var h=arguments;switch(h.length){case 0:return!d.call(this);case 1:return!d.call(this,h[0]);case 2:return!d.call(this,h[0],h[1]);case 3:return!d.call(this,h[0],h[1],h[2])}return!d.apply(this,h)}}function qae(d){return oF(2,d)}var Uae=Die(function(d,h){h=h.length==1&&it(h[0])?Qt(h[0],kr(Xe())):Qt(Rn(h,1),kr(Xe()));var x=h.length;return dt(function(k){for(var D=-1,j=Yn(k.length,x);++D<j;)k[D]=h[D].call(this,k[D]);return Tr(d,this,k)})}),Ex=dt(function(d,h){var x=es(h,ml(Ex));return ui(d,E,n,h,x)}),cF=dt(function(d,h){var x=es(h,ml(cF));return ui(d,O,n,h,x)}),Kae=di(function(d,h){return ui(d,P,n,n,n,h)});function Yae(d,h){if(typeof d!="function")throw new Yr(s);return h=h===n?h:st(h),dt(d,h)}function Gae(d,h){if(typeof d!="function")throw new Yr(s);return h=h==null?0:wn(st(h),0),dt(function(x){var k=x[h],D=ss(x,0,h);return k&&Qi(D,k),Tr(d,this,D)})}function Jae(d,h,x){var k=!0,D=!0;if(typeof d!="function")throw new Yr(s);return nn(x)&&(k="leading"in x?!!x.leading:k,D="trailing"in x?!!x.trailing:D),lF(d,h,{leading:k,maxWait:h,trailing:D})}function Zae(d){return rF(d,1)}function Xae(d,h){return Ex(dx(h),d)}function Qae(){if(!arguments.length)return[];var d=arguments[0];return it(d)?d:[d]}function ele(d){return Jr(d,m)}function tle(d,h){return h=typeof h=="function"?h:n,Jr(d,m,h)}function nle(d){return Jr(d,p|m)}function rle(d,h){return h=typeof h=="function"?h:n,Jr(d,p|m,h)}function ole(d,h){return h==null||JN(d,h,Dn(h))}function go(d,h){return d===h||d!==d&&h!==h}var ile=uh(Q1),sle=uh(function(d,h){return d>=h}),na=nL(function(){return arguments}())?nL:function(d){return dn(d)&&Ot.call(d,"callee")&&!HN.call(d,"callee")},it=de.isArray,ale=wN?kr(wN):gie;function mr(d){return d!=null&&vh(d.length)&&!pi(d)}function hn(d){return dn(d)&&mr(d)}function lle(d){return d===!0||d===!1||dn(d)&&or(d)==X}var as=Coe||Bx,cle=_N?kr(_N):mie;function ule(d){return dn(d)&&d.nodeType===1&&!Cu(d)}function dle(d){if(d==null)return!0;if(mr(d)&&(it(d)||typeof d=="string"||typeof d.splice=="function"||as(d)||yl(d)||na(d)))return!d.length;var h=Gn(d);if(h==ue||h==Je)return!d.size;if(xu(d))return!nx(d).length;for(var x in d)if(Ot.call(d,x))return!1;return!0}function fle(d,h){return yu(d,h)}function ple(d,h,x){x=typeof x=="function"?x:n;var k=x?x(d,h):n;return k===n?yu(d,h,n,x):!!k}function Mx(d){if(!dn(d))return!1;var h=or(d);return h==ce||h==ee||typeof d.message=="string"&&typeof d.name=="string"&&!Cu(d)}function hle(d){return typeof d=="number"&&WN(d)}function pi(d){if(!nn(d))return!1;var h=or(d);return h==te||h==se||h==le||h==Fe}function uF(d){return typeof d=="number"&&d==st(d)}function vh(d){return typeof d=="number"&&d>-1&&d%1==0&&d<=U}function nn(d){var h=typeof d;return d!=null&&(h=="object"||h=="function")}function dn(d){return d!=null&&typeof d=="object"}var dF=TN?kr(TN):bie;function gle(d,h){return d===h||tx(d,h,bx(h))}function mle(d,h,x){return x=typeof x=="function"?x:n,tx(d,h,bx(h),x)}function yle(d){return fF(d)&&d!=+d}function ble(d){if(tse(d))throw new ot(i);return rL(d)}function vle(d){return d===null}function xle(d){return d==null}function fF(d){return typeof d=="number"||dn(d)&&or(d)==ye}function Cu(d){if(!dn(d)||or(d)!=Se)return!1;var h=Up(d);if(h===null)return!0;var x=Ot.call(h,"constructor")&&h.constructor;return typeof x=="function"&&x instanceof x&&Hp.call(x)==moe}var Ox=kN?kr(kN):vie;function Sle(d){return uF(d)&&d>=-U&&d<=U}var pF=EN?kr(EN):xie;function xh(d){return typeof d=="string"||!it(d)&&dn(d)&&or(d)==De}function Mr(d){return typeof d=="symbol"||dn(d)&&or(d)==ct}var yl=MN?kr(MN):Sie;function Cle(d){return d===n}function wle(d){return dn(d)&&Gn(d)==Xt}function _le(d){return dn(d)&&or(d)==Sn}var Tle=uh(rx),kle=uh(function(d,h){return d<=h});function hF(d){if(!d)return[];if(mr(d))return xh(d)?po(d):gr(d);if(cu&&d[cu])return ooe(d[cu]());var h=Gn(d),x=h==ue?W1:h==Je?Rp:bl;return x(d)}function hi(d){if(!d)return d===0?d:0;if(d=Qr(d),d===q||d===-q){var h=d<0?-1:1;return h*G}return d===d?d:0}function st(d){var h=hi(d),x=h%1;return h===h?x?h-x:h:0}function gF(d){return d?Xs(st(d),0,Z):0}function Qr(d){if(typeof d=="number")return d;if(Mr(d))return Y;if(nn(d)){var h=typeof d.valueOf=="function"?d.valueOf():d;d=nn(h)?h+"":h}if(typeof d!="string")return d===0?d:+d;d=NN(d);var x=are.test(d);return x||cre.test(d)?Vre(d.slice(2),x?2:8):sre.test(d)?Y:+d}function mF(d){return Bo(d,yr(d))}function Ele(d){return d?Xs(st(d),-U,U):d===0?d:0}function Mt(d){return d==null?"":Er(d)}var Mle=hl(function(d,h){if(xu(h)||mr(h)){Bo(h,Dn(h),d);return}for(var x in h)Ot.call(h,x)&&hu(d,x,h[x])}),yF=hl(function(d,h){Bo(h,yr(h),d)}),Sh=hl(function(d,h,x,k){Bo(h,yr(h),d,k)}),Ole=hl(function(d,h,x,k){Bo(h,Dn(h),d,k)}),Ale=di(J1);function Ile(d,h){var x=pl(d);return h==null?x:GN(x,h)}var Dle=dt(function(d,h){d=Bt(d);var x=-1,k=h.length,D=k>2?h[2]:n;for(D&&ir(h[0],h[1],D)&&(k=1);++x<k;)for(var j=h[x],K=yr(j),Q=-1,ie=K.length;++Q<ie;){var Ce=K[Q],we=d[Ce];(we===n||go(we,ul[Ce])&&!Ot.call(d,Ce))&&(d[Ce]=j[Ce])}return d}),Ple=dt(function(d){return d.push(n,NL),Tr(bF,n,d)});function Nle(d,h){return AN(d,Xe(h,3),$o)}function Lle(d,h){return AN(d,Xe(h,3),X1)}function Fle(d,h){return d==null?d:Z1(d,Xe(h,3),yr)}function $le(d,h){return d==null?d:eL(d,Xe(h,3),yr)}function Ble(d,h){return d&&$o(d,Xe(h,3))}function Rle(d,h){return d&&X1(d,Xe(h,3))}function zle(d){return d==null?[]:nh(d,Dn(d))}function Vle(d){return d==null?[]:nh(d,yr(d))}function Ax(d,h,x){var k=d==null?n:Qs(d,h);return k===n?x:k}function Hle(d,h){return d!=null&&$L(d,h,die)}function Ix(d,h){return d!=null&&$L(d,h,fie)}var jle=OL(function(d,h,x){h!=null&&typeof h.toString!="function"&&(h=jp.call(h)),d[h]=x},Px(br)),Wle=OL(function(d,h,x){h!=null&&typeof h.toString!="function"&&(h=jp.call(h)),Ot.call(d,h)?d[h].push(x):d[h]=[x]},Xe),qle=dt(mu);function Dn(d){return mr(d)?KN(d):nx(d)}function yr(d){return mr(d)?KN(d,!0):Cie(d)}function Ule(d,h){var x={};return h=Xe(h,3),$o(d,function(k,D,j){ci(x,h(k,D,j),k)}),x}function Kle(d,h){var x={};return h=Xe(h,3),$o(d,function(k,D,j){ci(x,D,h(k,D,j))}),x}var Yle=hl(function(d,h,x){rh(d,h,x)}),bF=hl(function(d,h,x,k){rh(d,h,x,k)}),Gle=di(function(d,h){var x={};if(d==null)return x;var k=!1;h=Qt(h,function(j){return j=is(j,d),k||(k=j.length>1),j}),Bo(d,mx(d),x),k&&(x=Jr(x,p|g|m,jie));for(var D=h.length;D--;)lx(x,h[D]);return x});function Jle(d,h){return vF(d,bh(Xe(h)))}var Zle=di(function(d,h){return d==null?{}:_ie(d,h)});function vF(d,h){if(d==null)return{};var x=Qt(mx(d),function(k){return[k]});return h=Xe(h),uL(d,x,function(k,D){return h(k,D[0])})}function Xle(d,h,x){h=is(h,d);var k=-1,D=h.length;for(D||(D=1,d=n);++k<D;){var j=d==null?n:d[Ro(h[k])];j===n&&(k=D,j=x),d=pi(j)?j.call(d):j}return d}function Qle(d,h,x){return d==null?d:bu(d,h,x)}function ece(d,h,x,k){return k=typeof k=="function"?k:n,d==null?d:bu(d,h,x,k)}var xF=DL(Dn),SF=DL(yr);function tce(d,h,x){var k=it(d),D=k||as(d)||yl(d);if(h=Xe(h,4),x==null){var j=d&&d.constructor;D?x=k?new j:[]:nn(d)?x=pi(j)?pl(Up(d)):{}:x={}}return(D?Kr:$o)(d,function(K,Q,ie){return h(x,K,Q,ie)}),x}function nce(d,h){return d==null?!0:lx(d,h)}function rce(d,h,x){return d==null?d:gL(d,h,dx(x))}function oce(d,h,x,k){return k=typeof k=="function"?k:n,d==null?d:gL(d,h,dx(x),k)}function bl(d){return d==null?[]:j1(d,Dn(d))}function ice(d){return d==null?[]:j1(d,yr(d))}function sce(d,h,x){return x===n&&(x=h,h=n),x!==n&&(x=Qr(x),x=x===x?x:0),h!==n&&(h=Qr(h),h=h===h?h:0),Xs(Qr(d),h,x)}function ace(d,h,x){return h=hi(h),x===n?(x=h,h=0):x=hi(x),d=Qr(d),pie(d,h,x)}function lce(d,h,x){if(x&&typeof x!="boolean"&&ir(d,h,x)&&(h=x=n),x===n&&(typeof h=="boolean"?(x=h,h=n):typeof d=="boolean"&&(x=d,d=n)),d===n&&h===n?(d=0,h=1):(d=hi(d),h===n?(h=d,d=0):h=hi(h)),d>h){var k=d;d=h,h=k}if(x||d%1||h%1){var D=qN();return Yn(d+D*(h-d+zre("1e-"+((D+"").length-1))),h)}return ix(d,h)}var cce=gl(function(d,h,x){return h=h.toLowerCase(),d+(x?CF(h):h)});function CF(d){return Dx(Mt(d).toLowerCase())}function wF(d){return d=Mt(d),d&&d.replace(dre,Qre).replace(Are,"")}function uce(d,h,x){d=Mt(d),h=Er(h);var k=d.length;x=x===n?k:Xs(st(x),0,k);var D=x;return x-=h.length,x>=0&&d.slice(x,D)==h}function dce(d){return d=Mt(d),d&&su.test(d)?d.replace(hr,eoe):d}function fce(d){return d=Mt(d),d&&Zne.test(d)?d.replace(E1,"\\$&"):d}var pce=gl(function(d,h,x){return d+(x?"-":"")+h.toLowerCase()}),hce=gl(function(d,h,x){return d+(x?" ":"")+h.toLowerCase()}),gce=kL("toLowerCase");function mce(d,h,x){d=Mt(d),h=st(h);var k=h?ll(d):0;if(!h||k>=h)return d;var D=(h-k)/2;return ch(Jp(D),x)+d+ch(Gp(D),x)}function yce(d,h,x){d=Mt(d),h=st(h);var k=h?ll(d):0;return h&&k<h?d+ch(h-k,x):d}function bce(d,h,x){d=Mt(d),h=st(h);var k=h?ll(d):0;return h&&k<h?ch(h-k,x)+d:d}function vce(d,h,x){return x||h==null?h=0:h&&(h=+h),koe(Mt(d).replace(M1,""),h||0)}function xce(d,h,x){return(x?ir(d,h,x):h===n)?h=1:h=st(h),sx(Mt(d),h)}function Sce(){var d=arguments,h=Mt(d[0]);return d.length<3?h:h.replace(d[1],d[2])}var Cce=gl(function(d,h,x){return d+(x?"_":"")+h.toLowerCase()});function wce(d,h,x){return x&&typeof x!="number"&&ir(d,h,x)&&(h=x=n),x=x===n?Z:x>>>0,x?(d=Mt(d),d&&(typeof h=="string"||h!=null&&!Ox(h))&&(h=Er(h),!h&&al(d))?ss(po(d),0,x):d.split(h,x)):[]}var _ce=gl(function(d,h,x){return d+(x?" ":"")+Dx(h)});function Tce(d,h,x){return d=Mt(d),x=x==null?0:Xs(st(x),0,d.length),h=Er(h),d.slice(x,x+h.length)==h}function kce(d,h,x){var k=H.templateSettings;x&&ir(d,h,x)&&(h=n),d=Mt(d),h=Sh({},h,k,PL);var D=Sh({},h.imports,k.imports,PL),j=Dn(D),K=j1(D,j),Q,ie,Ce=0,we=h.interpolate||Np,Ee="__p += '",Ne=q1((h.escape||Np).source+"|"+we.source+"|"+(we===Pp?ire:Np).source+"|"+(h.evaluate||Np).source+"|$","g"),We="//# sourceURL="+(Ot.call(h,"sourceURL")?(h.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++Lre+"]")+`
|
|
89
|
+
`;d.replace(Ne,function(tt,ht,xt,Or,sr,Ar){return xt||(xt=Or),Ee+=d.slice(Ce,Ar).replace(fre,toe),ht&&(Q=!0,Ee+=`' +
|
|
90
90
|
__e(`+ht+`) +
|
|
91
91
|
'`),sr&&(ie=!0,Ee+=`';
|
|
92
92
|
`+sr+`;
|
|
@@ -98,34 +98,34 @@ __p += '`),xt&&(Ee+=`' +
|
|
|
98
98
|
}
|
|
99
99
|
`;else if(rre.test(et))throw new ot(a);Ee=(ie?Ee.replace(Ge,""):Ee).replace(nt,"$1").replace(Pt,"$1;"),Ee="function("+(et||"obj")+`) {
|
|
100
100
|
`+(et?"":`obj || (obj = {});
|
|
101
|
-
`)+"var __t, __p = ''"+(
|
|
101
|
+
`)+"var __t, __p = ''"+(Q?", __e = _.escape":"")+(ie?`, __j = Array.prototype.join;
|
|
102
102
|
function print() { __p += __j.call(arguments, '') }
|
|
103
103
|
`:`;
|
|
104
104
|
`)+Ee+`return __p
|
|
105
|
-
}`;var ut=TF(function(){return _t(j,We+"return "+Ee).apply(n,U)});if(ut.source=Ee,Mx(ut))throw ut;return ut}function Ece(d){return Mt(d).toLowerCase()}function Mce(d){return Mt(d).toUpperCase()}function Oce(d,h,x){if(d=Mt(d),d&&(x||h===n))return NN(d);if(!d||!(h=Er(h)))return d;var k=po(d),D=po(h),j=LN(k,D),U=FN(k,D)+1;return ss(k,j,U).join("")}function Ace(d,h,x){if(d=Mt(d),d&&(x||h===n))return d.slice(0,BN(d)+1);if(!d||!(h=Er(h)))return d;var k=po(d),D=FN(k,po(h))+1;return ss(k,0,D).join("")}function Ice(d,h,x){if(d=Mt(d),d&&(x||h===n))return d.replace(M1,"");if(!d||!(h=Er(h)))return d;var k=po(d),D=LN(k,po(h));return ss(k,D).join("")}function Dce(d,h){var x=M,k=A;if(nn(h)){var D="separator"in h?h.separator:D;x="length"in h?st(h.length):x,k="omission"in h?Er(h.omission):k}d=Mt(d);var j=d.length;if(al(d)){var U=po(d);j=U.length}if(x>=j)return d;var X=x-ll(k);if(X<1)return k;var ie=U?ss(U,0,X).join(""):d.slice(0,X);if(D===n)return ie+k;if(U&&(X+=ie.length-X),Ox(D)){if(d.slice(X).search(D)){var Ce,we=ie;for(D.global||(D=q1(D.source,Mt(nN.exec(D))+"g")),D.lastIndex=0;Ce=D.exec(we);)var Ee=Ce.index;ie=ie.slice(0,Ee===n?X:Ee)}}else if(d.indexOf(Er(D),X)!=X){var Ne=ie.lastIndexOf(D);Ne>-1&&(ie=ie.slice(0,Ne))}return ie+k}function Pce(d){return d=Mt(d),d&&si.test(d)?d.replace(rr,loe):d}var Nce=gl(function(d,h,x){return d+(x?" ":"")+h.toUpperCase()}),Dx=kL("toUpperCase");function _F(d,h,x){return d=Mt(d),h=x?n:h,h===n?roe(d)?doe(d):Yre(d):d.match(h)||[]}var TF=dt(function(d,h){try{return Tr(d,n,h)}catch(x){return Mx(x)?x:new ot(x)}}),Lce=di(function(d,h){return Kr(h,function(x){x=Ro(x),ci(d,x,kx(d[x],d))}),d});function Fce(d){var h=d==null?0:d.length,x=Xe();return d=h?Qt(d,function(k){if(typeof k[1]!="function")throw new Yr(s);return[x(k[0]),k[1]]}):[],dt(function(k){for(var D=-1;++D<h;){var j=d[D];if(Tr(j[0],this,k))return Tr(j[1],this,k)}})}function $ce(d){return lie(Jr(d,p))}function Px(d){return function(){return d}}function Bce(d,h){return d==null||d!==d?h:d}var Rce=ML(),zce=ML(!0);function br(d){return d}function Nx(d){return oL(typeof d=="function"?d:Jr(d,p))}function Vce(d){return sL(Jr(d,p))}function Hce(d,h){return aL(d,Jr(h,p))}var jce=dt(function(d,h){return function(x){return mu(x,d,h)}}),Wce=dt(function(d,h){return function(x){return mu(d,x,h)}});function Lx(d,h,x){var k=Dn(h),D=nh(h,k);x==null&&!(nn(h)&&(D.length||!k.length))&&(x=h,h=d,d=this,D=nh(h,Dn(h)));var j=!(nn(x)&&"chain"in x)||!!x.chain,U=pi(d);return Kr(D,function(X){var ie=h[X];d[X]=ie,U&&(d.prototype[X]=function(){var Ce=this.__chain__;if(j||Ce){var we=d(this.__wrapped__),Ee=we.__actions__=gr(this.__actions__);return Ee.push({func:ie,args:arguments,thisArg:d}),we.__chain__=Ce,we}return ie.apply(d,Qi([this.value()],arguments))})}),d}function qce(){return Bn._===this&&(Bn._=yoe),this}function Fx(){}function Uce(d){return d=st(d),dt(function(h){return lL(h,d)})}var Kce=px(Qt),Yce=px(ON),Gce=px(B1);function kF(d){return xx(d)?R1(Ro(d)):Tie(d)}function Jce(d){return function(h){return d==null?n:Qs(d,h)}}var Zce=AL(),Xce=AL(!0);function $x(){return[]}function Bx(){return!1}function Qce(){return{}}function eue(){return""}function tue(){return!0}function nue(d,h){if(d=st(d),d<1||d>K)return[];var x=Z,k=Yn(d,Z);h=Xe(h),d-=Z;for(var D=H1(k,h);++x<d;)h(x);return D}function rue(d){return it(d)?Qt(d,Ro):Mr(d)?[d]:gr(UL(Mt(d)))}function oue(d){var h=++goe;return Mt(d)+h}var iue=lh(function(d,h){return d+h},0),sue=hx("ceil"),aue=lh(function(d,h){return d/h},1),lue=hx("floor");function cue(d){return d&&d.length?th(d,br,Q1):n}function uue(d,h){return d&&d.length?th(d,Xe(h,2),Q1):n}function due(d){return DN(d,br)}function fue(d,h){return DN(d,Xe(h,2))}function pue(d){return d&&d.length?th(d,br,rx):n}function hue(d,h){return d&&d.length?th(d,Xe(h,2),rx):n}var gue=lh(function(d,h){return d*h},1),mue=hx("round"),yue=lh(function(d,h){return d-h},0);function bue(d){return d&&d.length?V1(d,br):0}function vue(d,h){return d&&d.length?V1(d,Xe(h,2)):0}return H.after=Vae,H.ary=rF,H.assign=Mle,H.assignIn=yF,H.assignInWith=Sh,H.assignWith=Ole,H.at=Ale,H.before=oF,H.bind=kx,H.bindAll=Lce,H.bindKey=iF,H.castArray=Qae,H.chain=eF,H.chunk=lse,H.compact=cse,H.concat=use,H.cond=Fce,H.conforms=$ce,H.constant=Px,H.countBy=bae,H.create=Ile,H.curry=sF,H.curryRight=aF,H.debounce=lF,H.defaults=Dle,H.defaultsDeep=Ple,H.defer=Hae,H.delay=jae,H.difference=dse,H.differenceBy=fse,H.differenceWith=pse,H.drop=hse,H.dropRight=gse,H.dropRightWhile=mse,H.dropWhile=yse,H.fill=bse,H.filter=xae,H.flatMap=wae,H.flatMapDeep=_ae,H.flatMapDepth=Tae,H.flatten=JL,H.flattenDeep=vse,H.flattenDepth=xse,H.flip=Wae,H.flow=Rce,H.flowRight=zce,H.fromPairs=Sse,H.functions=zle,H.functionsIn=Vle,H.groupBy=kae,H.initial=wse,H.intersection=_se,H.intersectionBy=Tse,H.intersectionWith=kse,H.invert=jle,H.invertBy=Wle,H.invokeMap=Mae,H.iteratee=Nx,H.keyBy=Oae,H.keys=Dn,H.keysIn=yr,H.map=gh,H.mapKeys=Ule,H.mapValues=Kle,H.matches=Vce,H.matchesProperty=Hce,H.memoize=yh,H.merge=Yle,H.mergeWith=bF,H.method=jce,H.methodOf=Wce,H.mixin=Lx,H.negate=bh,H.nthArg=Uce,H.omit=Gle,H.omitBy=Jle,H.once=qae,H.orderBy=Aae,H.over=Kce,H.overArgs=Uae,H.overEvery=Yce,H.overSome=Gce,H.partial=Ex,H.partialRight=cF,H.partition=Iae,H.pick=Zle,H.pickBy=vF,H.property=kF,H.propertyOf=Jce,H.pull=Ase,H.pullAll=XL,H.pullAllBy=Ise,H.pullAllWith=Dse,H.pullAt=Pse,H.range=Zce,H.rangeRight=Xce,H.rearg=Kae,H.reject=Nae,H.remove=Nse,H.rest=Yae,H.reverse=_x,H.sampleSize=Fae,H.set=Qle,H.setWith=ece,H.shuffle=$ae,H.slice=Lse,H.sortBy=zae,H.sortedUniq=Hse,H.sortedUniqBy=jse,H.split=wce,H.spread=Gae,H.tail=Wse,H.take=qse,H.takeRight=Use,H.takeRightWhile=Kse,H.takeWhile=Yse,H.tap=cae,H.throttle=Jae,H.thru=hh,H.toArray=hF,H.toPairs=xF,H.toPairsIn=SF,H.toPath=rue,H.toPlainObject=mF,H.transform=tce,H.unary=Zae,H.union=Gse,H.unionBy=Jse,H.unionWith=Zse,H.uniq=Xse,H.uniqBy=Qse,H.uniqWith=eae,H.unset=nce,H.unzip=Tx,H.unzipWith=QL,H.update=rce,H.updateWith=oce,H.values=bl,H.valuesIn=ice,H.without=tae,H.words=_F,H.wrap=Xae,H.xor=nae,H.xorBy=rae,H.xorWith=oae,H.zip=iae,H.zipObject=sae,H.zipObjectDeep=aae,H.zipWith=lae,H.entries=xF,H.entriesIn=SF,H.extend=yF,H.extendWith=Sh,Lx(H,H),H.add=iue,H.attempt=TF,H.camelCase=cce,H.capitalize=CF,H.ceil=sue,H.clamp=sce,H.clone=ele,H.cloneDeep=nle,H.cloneDeepWith=rle,H.cloneWith=tle,H.conformsTo=ole,H.deburr=wF,H.defaultTo=Bce,H.divide=aue,H.endsWith=uce,H.eq=go,H.escape=dce,H.escapeRegExp=fce,H.every=vae,H.find=Sae,H.findIndex=YL,H.findKey=Nle,H.findLast=Cae,H.findLastIndex=GL,H.findLastKey=Lle,H.floor=lue,H.forEach=tF,H.forEachRight=nF,H.forIn=Fle,H.forInRight=$le,H.forOwn=Ble,H.forOwnRight=Rle,H.get=Ax,H.gt=ile,H.gte=sle,H.has=Hle,H.hasIn=Ix,H.head=ZL,H.identity=br,H.includes=Eae,H.indexOf=Cse,H.inRange=ace,H.invoke=qle,H.isArguments=na,H.isArray=it,H.isArrayBuffer=ale,H.isArrayLike=mr,H.isArrayLikeObject=hn,H.isBoolean=lle,H.isBuffer=as,H.isDate=cle,H.isElement=ule,H.isEmpty=dle,H.isEqual=fle,H.isEqualWith=ple,H.isError=Mx,H.isFinite=hle,H.isFunction=pi,H.isInteger=uF,H.isLength=vh,H.isMap=dF,H.isMatch=gle,H.isMatchWith=mle,H.isNaN=yle,H.isNative=ble,H.isNil=xle,H.isNull=vle,H.isNumber=fF,H.isObject=nn,H.isObjectLike=dn,H.isPlainObject=Cu,H.isRegExp=Ox,H.isSafeInteger=Sle,H.isSet=pF,H.isString=xh,H.isSymbol=Mr,H.isTypedArray=yl,H.isUndefined=Cle,H.isWeakMap=wle,H.isWeakSet=_le,H.join=Ese,H.kebabCase=pce,H.last=Xr,H.lastIndexOf=Mse,H.lowerCase=hce,H.lowerFirst=gce,H.lt=Tle,H.lte=kle,H.max=cue,H.maxBy=uue,H.mean=due,H.meanBy=fue,H.min=pue,H.minBy=hue,H.stubArray=$x,H.stubFalse=Bx,H.stubObject=Qce,H.stubString=eue,H.stubTrue=tue,H.multiply=gue,H.nth=Ose,H.noConflict=qce,H.noop=Fx,H.now=mh,H.pad=mce,H.padEnd=yce,H.padStart=bce,H.parseInt=vce,H.random=lce,H.reduce=Dae,H.reduceRight=Pae,H.repeat=xce,H.replace=Sce,H.result=Xle,H.round=mue,H.runInContext=re,H.sample=Lae,H.size=Bae,H.snakeCase=Cce,H.some=Rae,H.sortedIndex=Fse,H.sortedIndexBy=$se,H.sortedIndexOf=Bse,H.sortedLastIndex=Rse,H.sortedLastIndexBy=zse,H.sortedLastIndexOf=Vse,H.startCase=_ce,H.startsWith=Tce,H.subtract=yue,H.sum=bue,H.sumBy=vue,H.template=kce,H.times=nue,H.toFinite=hi,H.toInteger=st,H.toLength=gF,H.toLower=Ece,H.toNumber=Qr,H.toSafeInteger=Ele,H.toString=Mt,H.toUpper=Mce,H.trim=Oce,H.trimEnd=Ace,H.trimStart=Ice,H.truncate=Dce,H.unescape=Pce,H.uniqueId=oue,H.upperCase=Nce,H.upperFirst=Dx,H.each=tF,H.eachRight=nF,H.first=ZL,Lx(H,function(){var d={};return $o(H,function(h,x){Ot.call(H.prototype,x)||(d[x]=h)}),d}(),{chain:!1}),H.VERSION=r,Kr(["bind","bindKey","curry","curryRight","partial","partialRight"],function(d){H[d].placeholder=H}),Kr(["drop","take"],function(d,h){mt.prototype[d]=function(x){x=x===n?1:wn(st(x),0);var k=this.__filtered__&&!h?new mt(this):this.clone();return k.__filtered__?k.__takeCount__=Yn(x,k.__takeCount__):k.__views__.push({size:Yn(x,Z),type:d+(k.__dir__<0?"Right":"")}),k},mt.prototype[d+"Right"]=function(x){return this.reverse()[d](x).reverse()}}),Kr(["filter","map","takeWhile"],function(d,h){var x=h+1,k=x==R||x==z;mt.prototype[d]=function(D){var j=this.clone();return j.__iteratees__.push({iteratee:Xe(D,3),type:x}),j.__filtered__=j.__filtered__||k,j}}),Kr(["head","last"],function(d,h){var x="take"+(h?"Right":"");mt.prototype[d]=function(){return this[x](1).value()[0]}}),Kr(["initial","tail"],function(d,h){var x="drop"+(h?"":"Right");mt.prototype[d]=function(){return this.__filtered__?new mt(this):this[x](1)}}),mt.prototype.compact=function(){return this.filter(br)},mt.prototype.find=function(d){return this.filter(d).head()},mt.prototype.findLast=function(d){return this.reverse().find(d)},mt.prototype.invokeMap=dt(function(d,h){return typeof d=="function"?new mt(this):this.map(function(x){return mu(x,d,h)})}),mt.prototype.reject=function(d){return this.filter(bh(Xe(d)))},mt.prototype.slice=function(d,h){d=st(d);var x=this;return x.__filtered__&&(d>0||h<0)?new mt(x):(d<0?x=x.takeRight(-d):d&&(x=x.drop(d)),h!==n&&(h=st(h),x=h<0?x.dropRight(-h):x.take(h-d)),x)},mt.prototype.takeRightWhile=function(d){return this.reverse().takeWhile(d).reverse()},mt.prototype.toArray=function(){return this.take(Z)},$o(mt.prototype,function(d,h){var x=/^(?:filter|find|map|reject)|While$/.test(h),k=/^(?:head|last)$/.test(h),D=H[k?"take"+(h=="last"?"Right":""):h],j=k||/^find/.test(h);D&&(H.prototype[h]=function(){var U=this.__wrapped__,X=k?[1]:arguments,ie=U instanceof mt,Ce=X[0],we=ie||it(U),Ee=function(ht){var xt=D.apply(H,Qi([ht],X));return k&&Ne?xt[0]:xt};we&&x&&typeof Ce=="function"&&Ce.length!=1&&(ie=we=!1);var Ne=this.__chain__,We=!!this.__actions__.length,et=j&&!Ne,ut=ie&&!We;if(!j&&we){U=ut?U:new mt(this);var tt=d.apply(U,X);return tt.__actions__.push({func:hh,args:[Ee],thisArg:n}),new Gr(tt,Ne)}return et&&ut?d.apply(this,X):(tt=this.thru(Ee),et?k?tt.value()[0]:tt.value():tt)})}),Kr(["pop","push","shift","sort","splice","unshift"],function(d){var h=zp[d],x=/^(?:push|sort|unshift)$/.test(d)?"tap":"thru",k=/^(?:pop|shift)$/.test(d);H.prototype[d]=function(){var D=arguments;if(k&&!this.__chain__){var j=this.value();return h.apply(it(j)?j:[],D)}return this[x](function(U){return h.apply(it(U)?U:[],D)})}}),$o(mt.prototype,function(d,h){var x=H[h];if(x){var k=x.name+"";Ot.call(fl,k)||(fl[k]=[]),fl[k].push({name:h,func:x})}}),fl[ah(n,C).name]=[{name:"wrapper",func:n}],mt.prototype.clone=Poe,mt.prototype.reverse=Noe,mt.prototype.value=Loe,H.prototype.at=uae,H.prototype.chain=dae,H.prototype.commit=fae,H.prototype.next=pae,H.prototype.plant=gae,H.prototype.reverse=mae,H.prototype.toJSON=H.prototype.valueOf=H.prototype.value=yae,H.prototype.first=H.prototype.head,cu&&(H.prototype[cu]=hae),H},cl=foe();Ys?((Ys.exports=cl)._=cl,N1._=cl):Bn._=cl}).call(MB)}(Nl,Nl.exports)),Nl.exports}var Ku=OB();const AB=t=>{const{name:e,onInputChange:n,onChange:r,onFilter:o,onFilterError:i,fetchOnCount:s=1,preFilterMessage:a=s?"Start typing to see options...":t.noOptionsText,noOptionsText:l,filterOptions:u=P=>P,includeInputInList:f=!0,autoComplete:p=!0,...g}=t,[m,y,b]=jt.useField(e),{setValue:S}=b,[C,T]=J.useState(""),[_,w]=J.useState([]),[E,O]=J.useState(!1),L=Ku.debounce(async(P,$)=>{try{O(!0);const M=await o(P.input);$(M)}catch(M){throw M}finally{O(!1)}},400);return J.useEffect(()=>{if(C===""){w(m.value?[m.value]:[]);return}C.length>=s&&L({input:C},P=>{let $=[];P?($=P,m.value&&($=[m.value,...P.filter(M=>JSON.stringify(M)!==JSON.stringify(m.value))])):m.value&&($=[m.value]),w($)})},[m.value,C]),v.jsx(fC,{name:e,loading:E,filterOptions:u,noOptionsText:C.length<s?a:l,options:_,autoComplete:p,includeInputInList:f,onChange:(P,$,M,A)=>{w($?[$,..._]:_),S($),r&&r(P,$,M,A)},onInputChange:(P,$,M)=>{T($),n&&n(P,$,M)},...g})},IB=t=>{const{name:e,label:n=_n(e),options:r=[],filterSelectedOptions:o=!0,variant:i="outlined",staticLabel:s=!1,staticLabelProps:a={fontSize:".9em",color:"#808080"},readOnly:l,margin:u="dense",fullWidth:f=!0,required:p,onChange:g,getOptionLabel:m=P=>typeof P=="string"?P:String(P),isOptionEqualToValue:y=(P,$)=>JSON.stringify(P)===JSON.stringify($),useFieldAsValue:b,...S}=t,[C,T,_]=jt.useField(e),{setValue:w}=_,{error:E}=T,O={...Jn(S,["useFieldAsValue"]),getOptionLabel:m,options:r,filterSelectedOptions:o,isOptionEqualToValue:y,renderInput:P=>v.jsx(F.TextField,{...P,variant:i,label:s?void 0:n,error:!!E,required:p}),onChange:(P,$,M,A)=>{w(b?$.map(N=>N[b]):$),g&&g(P,$,M,A)},fullWidth:!0,value:b?r.filter(P=>C.value.includes(P[b]))||[]:C.value,slotProps:{paper:{elevation:8,sx:{borderRadius:2}}}},L=()=>C.value.length===0?"":(b?r.filter($=>C.value.includes($[b]))||[]:C.value).map($=>m($)).join(", ");return v.jsxs(F.FormControl,{margin:u,fullWidth:f,required:p,children:[(s||l)&&v.jsx(F.Typography,{...a,children:n}),l?v.jsx(F.Typography,{children:L()}):v.jsxs(F.Box,{children:[v.jsx(F.Autocomplete,{...O,multiple:!0}),v.jsx(Xn,{name:e,id:`${e}-err`})]})]})},DB=t=>{const{name:e,label:n=_n(e),sublabel:r,required:o=!1,labelPlacement:i="end",labelAlignment:s=i==="end"||i==="start"?"top":"center",readOnly:a=!1,staticLabelProps:l={fontSize:".9em",color:"#808080"},onChange:u,...f}=t;s==="top"&&(i==="bottom"||i==="top")&&console.error(`Checkbox: Ignoring labelAlignment='top'. labelAlignment cannot be 'top' when labelPlacement=${i}`);const p=jt.useField({name:e}),g=p[0],m=p[2],y=r?v.jsxs("div",{children:[v.jsx("p",{style:{margin:0},children:n}),v.jsx(F.Typography,{variant:"caption",style:{fontSize:"0.85rem"},children:r})]}):n,b=s==="top"&&(i==="start"||i==="end");return a?g.value&&v.jsx(F.Typography,{...l,children:y}):v.jsxs(F.Box,{children:[v.jsx(F.FormControlLabel,{sx:{alignItems:b?"flex-start":"center"},label:v.jsx("span",{"data-testid":n,style:{display:"inline-block",marginTop:b?"10px":0},children:y}),required:o,labelPlacement:i,control:v.jsx(F.Checkbox,{"data-testid":"checkbox",...f,...g,onChange:(S,C)=>{m.setValue(S.target.checked),u&&u(S,C)},checked:g.value})}),v.jsx(Xn,{name:e,id:`${e}-err`})]})},da=t=>{const{name:e,label:n=_n(e),format:r="",autoFormat:o=r,placeholder:i=n,staticLabel:s=!1,staticLabelProps:a={fontSize:".9em",color:"#808080"},readOnly:l=!1,startIcon:u,endIcon:f,margin:p="dense",noTrimOnBlur:g=!1}=t,[m,y,b]=jt.useField({name:e}),{setValue:S}=b,{value:C}=m,{error:T}=y;C===void 0&&console.error(`Please set an initial value for ${e}`),!r&&o&&console.error("Can't auto format when there is no format");const _=E=>{if(o){const O=LF(E.target.value,r,C,E.target);S(O)}else S(E.target.value);t.onChange&&t.onChange(E)},w=["autoFormat","format","staticLabel","staticLabelProps","endIcon","startIcon"];return v.jsxs(F.FormControl,{margin:p,fullWidth:!0,children:[(s||l)&&v.jsx(F.Typography,{...a,children:n}),l?v.jsx(F.Typography,{children:C}):v.jsxs(F.Box,{children:[v.jsx(F.TextField,{variant:"outlined",fullWidth:!0,...m,id:`${e}-tf`,error:!!T,placeholder:i,...Jn({...t},w),onChange:_,label:s?void 0:n,slotProps:{input:{endAdornment:f,startAdornment:u}},onBlur:E=>{g||S(E.target.value.trim()),t.onBlur&&t.onBlur(E)}}),v.jsx(Xn,{name:e,id:`${e}-err`})]})]})},PB=t=>{const{name:e,checkboxes:n=[],label:r=_n(e),labelPlacement:o="end",labelAlignment:i=o==="end"||o==="start"?"top":"center",required:s=!1,disabled:a=!1,readOnly:l=!1,min:u=0,max:f=n.length,minMaxSubtitle:p="Please select between {min} and {max} options",maxSubtitle:g="Up to {max} max",minSubtitle:m="Please select {min} or more",margin:y="dense",staticLabelProps:b={fontSize:".9em",color:"#808080"}}=t,[S,C,T]=jt.useField({name:e}),{setValue:_}=T,{value:w}=S,{error:E}=C,{setFieldValue:O}=jt.useFormikContext();(u<0||u>=n.length)&&console.error(`CheckboxGroup: "min" cannot be ${u}. It must be a value between 0 and ${n.length-1}.`),(f<=1||f>n.length)&&console.error(`CheckboxGroup: "max" must be a value between 2 and ${n.length}.`),i==="top"&&(o==="bottom"||o==="top")&&console.error(`CheckboxGroup: Ignoring labelAlignment='top'. labelAlignment cannot be 'top' when labelPlacement=${o}`);const L=()=>t.labelPlacement=="start"?"right":t.labelPlacement=="top"||t.labelPlacement=="bottom"?"center":"left",P=N=>typeof N=="string"?N:!N.textField&&!N.sublabel?N.label:v.jsxs(F.Box,{display:"flex",flexDirection:"row",justifyContent:"center",gap:"0.5rem",alignItems:"baseline",children:[v.jsxs(F.Box,{display:"flex",flexDirection:"column",justifyContent:"center",children:[v.jsx("p",{style:{margin:0},children:N.label}),N.sublabel&&v.jsx(F.Typography,{variant:"caption",style:{fontSize:"0.85rem"},children:N.sublabel})]}),N.textField&&v.jsx(da,{label:"",size:"small",margin:"none",sx:{"& .MuiInputBase-input":{height:14}},...N.textField})]}),$=n.map(N=>{const V=typeof N=="string"?N:N.label,R=i==="top"&&(o==="start"||o==="end");return v.jsx(F.FormControlLabel,{sx:{alignItems:R?"flex-start":"center"},value:V,control:v.jsx(F.Checkbox,{}),label:v.jsx("div",{"data-testid":typeof N=="string"?N:N.label,style:{marginTop:R?"10px":0},children:P(N)}),labelPlacement:o,checked:w.includes(V),disabled:a||!w.includes(V)&&w.length===f,style:{textAlign:L()}},`checkbox-group-${V}`)}),M=()=>{if(f<n.length&&u>0)return v.jsx(F.Typography,{variant:"subtitle2",children:p.replace("{min}",`${u}`).replace("{max}",`${f}`)});if(f<n.length)return v.jsx(F.Typography,{variant:"subtitle2",children:g.replace("{max}",`${f}`)});if(u>0)return v.jsx(F.Typography,{variant:"subtitle2",children:m.replace("{min}",`${u}`)})};return l?v.jsxs(F.Box,{children:[v.jsx(F.Typography,{...b,children:r}),w.join(", ")]}):v.jsxs(F.FormControl,{onChange:N=>{const V=N.target.value,R=N.target.checked,B=n.find(z=>typeof z=="string"?z===V:z.label===V);R?_([...w,V]):(B&&typeof B=="object"&&B.textField&&B.textField.name&&O(B.textField.name,""),_(w.filter(z=>z!=V)))},fullWidth:!0,margin:y,error:!!E,children:[v.jsx(F.FormLabel,{focused:t.focused,htmlFor:e,required:s,disabled:t.disableLabel,children:r}),M(),$,v.jsx(Xn,{name:e,id:`${e}-err`})]})},hC=ze(v.jsx("path",{d:"M19.35 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.6 5.64 5.35 8.04 2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96M14 13v4h-4v-4H7l5-5 5 5z"}),"CloudUpload"),gC=t=>{const{name:e,multiple:n=!1,readOnly:r=!1,variant:o=n?"drag-and-drop":"button",duplicateFilesCallback:i,incorrectFileTypesCallback:s,staticLabelProps:a={fontSize:".9em",color:"#808080"}}=t,[l,u,f]=jt.useField({name:e}),{setValue:p}=f,g=l.value,m=t.fileType?Array.isArray(t.fileType)?t.fileType:[t.fileType]:[],y=t.subtitle??(m.length>0?`Allowed file extensions: ${m.join(", ")}`:""),b=L=>{C(Array.from(L.target.files??[]))},S=L=>{L.preventDefault(),C(Array.from(L.dataTransfer.files))},C=L=>{if(L&&L.length>0){const P=g?Array.isArray(g)?g:[g]:[],$=Ku.partition(L,M=>P.find(A=>_(M,A)));if(L=$[1],i&&$[0].length>0&&i($[0]),m.length>0){const M=Ku.partition(L,A=>m.find(N=>A.name.endsWith(N)));L=M[0],s&&M[1].length>0&&s(M[1])}n?p([...T(),...L]):!Array.isArray(g)&&L.length>0&&p(L[0])}},T=()=>g?Array.isArray(g)?g:[g]:[],_=(L,P)=>L.lastModified===P.lastModified&&L.name===P.name&&L.type===P.type&&L.size===P.size,w=()=>T().map(L=>L.name).join(", ");return r?v.jsx(F.Typography,{"data-testid":"fileupload-readonly",...a,children:w()}):o==="drag-and-drop"?v.jsxs("div",{style:{border:`4px dashed ${u.error?"red":"lightgray"}`,padding:"30px 10px",display:"flex",alignItems:"center",flexDirection:"column"},onDrop:S,onDragOver:L=>L.preventDefault(),"data-testid":"dropzone",children:[v.jsx(hC,{color:"primary",sx:{fontSize:"40px"}}),v.jsxs("div",{style:{display:"flex",flexDirection:"row",alignItems:"baseline"},children:[v.jsx(F.Typography,{children:"Drag and drop or"}),v.jsxs(F.Button,{component:"label",role:void 0,variant:"text",tabIndex:-1,sx:{textTransform:"none",fontSize:"16px",textDecoration:"underline"},children:["browse",v.jsx("input",{"data-testid":"file-input",id:e,hidden:!0,type:"file",onChange:b,multiple:!0,accept:m==null?void 0:m.toString()})]})]}),y&&v.jsx(F.Typography,{variant:"caption",children:y}),v.jsx(Xn,{name:e,id:`${e}-err`})]}):v.jsxs("div",{style:{display:"flex",flexDirection:"column"},children:[v.jsx("div",{style:{display:"flex",alignItems:"center",marginBottom:"4px"},children:v.jsxs(F.Button,{component:"label",role:void 0,variant:"contained",tabIndex:-1,startIcon:v.jsx(hC,{}),children:["Upload a file",v.jsx("input",{"data-testid":"file-input",id:e,hidden:!0,type:"file",onChange:b,accept:m==null?void 0:m.toString()})]})}),v.jsx(Xn,{name:e,id:`${e}-err`})]})},NB=ze(v.jsx("path",{d:"M15 2H6c-1.1 0-2 .9-2 2v16c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V7zM6 20V4h8v4h4v12zm10-10v5c0 2.21-1.79 4-4 4s-4-1.79-4-4V8.5c0-1.47 1.26-2.64 2.76-2.49 1.3.13 2.24 1.32 2.24 2.63V15h-2V8.5c0-.28-.22-.5-.5-.5s-.5.22-.5.5V15c0 1.1.9 2 2 2s2-.9 2-2v-5z"}),"FilePresent"),qh=ze(v.jsx("path",{d:"M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6zM19 4h-3.5l-1-1h-5l-1 1H5v2h14z"}),"Delete"),LB=t=>{const{name:e}=t,[n,,r]=jt.useField({name:e}),{setValue:o}=r,i=n.value;return v.jsx("div",{style:{width:"100%"},children:i.map(s=>v.jsx(F.Card,{sx:{margin:"10px 0px"},children:v.jsxs(F.CardContent,{style:{display:"flex",alignItems:"center",padding:"8px 12px"},children:[v.jsx(NB,{sx:{color:"gray",fontSize:"20px"}}),v.jsx(F.Typography,{sx:{padding:"8px",overflowWrap:"anywhere"},children:s.name}),v.jsx(F.IconButton,{"aria-label":"remove file",onClick:()=>o(i.filter(a=>a!==s)),edge:"end",style:{marginLeft:"auto",order:"2"},children:v.jsx(qh,{})})]})},`${s.name}-${s.type}-${s.size}-${s.lastModified}`))})};var Uh,mC;function Uo(){if(mC)return Uh;mC=1;function t(e){var n=typeof e;return e!=null&&(n=="object"||n=="function")}return Uh=t,Uh}var Kh,yC;function bC(){if(yC)return Kh;yC=1;var t=typeof yi=="object"&&yi&&yi.Object===Object&&yi;return Kh=t,Kh}var Yh,vC;function oo(){if(vC)return Yh;vC=1;var t=bC(),e=typeof self=="object"&&self&&self.Object===Object&&self,n=t||e||Function("return this")();return Yh=n,Yh}var Gh,xC;function FB(){if(xC)return Gh;xC=1;var t=oo(),e=function(){return t.Date.now()};return Gh=e,Gh}var Jh,SC;function $B(){if(SC)return Jh;SC=1;var t=/\s/;function e(n){for(var r=n.length;r--&&t.test(n.charAt(r)););return r}return Jh=e,Jh}var Zh,CC;function BB(){if(CC)return Zh;CC=1;var t=$B(),e=/^\s+/;function n(r){return r&&r.slice(0,t(r)+1).replace(e,"")}return Zh=n,Zh}var Xh,wC;function Ll(){if(wC)return Xh;wC=1;var t=oo(),e=t.Symbol;return Xh=e,Xh}var Qh,_C;function RB(){if(_C)return Qh;_C=1;var t=Ll(),e=Object.prototype,n=e.hasOwnProperty,r=e.toString,o=t?t.toStringTag:void 0;function i(s){var a=n.call(s,o),l=s[o];try{s[o]=void 0;var u=!0}catch{}var f=r.call(s);return u&&(a?s[o]=l:delete s[o]),f}return Qh=i,Qh}var eg,TC;function zB(){if(TC)return eg;TC=1;var t=Object.prototype,e=t.toString;function n(r){return e.call(r)}return eg=n,eg}var tg,kC;function us(){if(kC)return tg;kC=1;var t=Ll(),e=RB(),n=zB(),r="[object Null]",o="[object Undefined]",i=t?t.toStringTag:void 0;function s(a){return a==null?a===void 0?o:r:i&&i in Object(a)?e(a):n(a)}return tg=s,tg}var ng,EC;function Ci(){if(EC)return ng;EC=1;function t(e){return e!=null&&typeof e=="object"}return ng=t,ng}var rg,MC;function Yu(){if(MC)return rg;MC=1;var t=us(),e=Ci(),n="[object Symbol]";function r(o){return typeof o=="symbol"||e(o)&&t(o)==n}return rg=r,rg}var og,OC;function AC(){if(OC)return og;OC=1;var t=BB(),e=Uo(),n=Yu(),r=NaN,o=/^[-+]0x[0-9a-f]+$/i,i=/^0b[01]+$/i,s=/^0o[0-7]+$/i,a=parseInt;function l(u){if(typeof u=="number")return u;if(n(u))return r;if(e(u)){var f=typeof u.valueOf=="function"?u.valueOf():u;u=e(f)?f+"":f}if(typeof u!="string")return u===0?u:+u;u=t(u);var p=i.test(u);return p||s.test(u)?a(u.slice(2),p?2:8):o.test(u)?r:+u}return og=l,og}var ig,IC;function DC(){if(IC)return ig;IC=1;var t=Uo(),e=FB(),n=AC(),r="Expected a function",o=Math.max,i=Math.min;function s(a,l,u){var f,p,g,m,y,b,S=0,C=!1,T=!1,_=!0;if(typeof a!="function")throw new TypeError(r);l=n(l)||0,t(u)&&(C=!!u.leading,T="maxWait"in u,g=T?o(n(u.maxWait)||0,l):g,_="trailing"in u?!!u.trailing:_);function w(V){var R=f,B=p;return f=p=void 0,S=V,m=a.apply(B,R),m}function E(V){return S=V,y=setTimeout(P,l),C?w(V):m}function O(V){var R=V-b,B=V-S,z=l-R;return T?i(z,g-B):z}function L(V){var R=V-b,B=V-S;return b===void 0||R>=l||R<0||T&&B>=g}function P(){var V=e();if(L(V))return $(V);y=setTimeout(P,O(V))}function $(V){return y=void 0,_&&f?w(V):(f=p=void 0,m)}function M(){y!==void 0&&clearTimeout(y),S=0,f=b=p=y=void 0}function A(){return y===void 0?m:$(e())}function N(){var V=e(),R=L(V);if(f=arguments,p=this,b=V,R){if(y===void 0)return E(b);if(T)return clearTimeout(y),y=setTimeout(P,l),w(b)}return y===void 0&&(y=setTimeout(P,l)),m}return N.cancel=M,N.flush=A,N}return ig=s,ig}var sg,PC;function VB(){if(PC)return sg;PC=1;var t=DC(),e=Uo(),n="Expected a function";function r(o,i,s){var a=!0,l=!0;if(typeof o!="function")throw new TypeError(n);return e(s)&&(a="leading"in s?!!s.leading:a,l="trailing"in s?!!s.trailing:l),t(o,i,{leading:a,maxWait:i,trailing:l})}return sg=r,sg}var HB=VB();const NC=Zn(HB),jB=ze(v.jsx("path",{d:"M12 2C8.13 2 5 5.13 5 9c0 5.25 7 13 7 13s7-7.75 7-13c0-3.87-3.13-7-7-7m0 9.5c-1.38 0-2.5-1.12-2.5-2.5s1.12-2.5 2.5-2.5 2.5 1.12 2.5 2.5-1.12 2.5-2.5 2.5"}),"LocationOn");var Gu={exports:{}},WB=Gu.exports,LC;function qB(){return LC||(LC=1,function(t,e){(function(n,r){t.exports=r()})(WB,()=>{return n={705:o=>{o.exports=function(i,s){const a=[];return s.length===0?a.push({text:i,highlight:!1}):s[0][0]>0&&a.push({text:i.slice(0,s[0][0]),highlight:!1}),s.forEach((l,u)=>{const f=l[0],p=l[1];a.push({text:i.slice(f,p),highlight:!0}),u===s.length-1?p<i.length&&a.push({text:i.slice(p,i.length),highlight:!1}):p<s[u+1][0]&&a.push({text:i.slice(p,s[u+1][0]),highlight:!1})}),a}}},r={},function o(i){var s=r[i];if(s!==void 0)return s.exports;var a=r[i]={exports:{}};return n[i](a,a.exports,o),a.exports}(705);var n,r})}(Gu)),Gu.exports}var UB=qB();const KB=Zn(UB),YB=t=>{const{listItemProps:e,option:n,resultIcon:r,highlightMatches:o}=t,{main_text:i,secondary_text:s,main_text_matched_substrings:a}=n.structured_formatting,l=KB(i,a.map(u=>[u.offset,u.offset+u.length]));return v.jsx("li",{...Jn({...e},["key"]),"data-testid":`loc-${n.place_id}`,children:v.jsxs(F.Box,{display:"flex",flexDirection:"row",alignItems:"center",children:[r?I.cloneElement(r):null,v.jsxs(F.Box,{children:[l.map(u=>{const f=o&&u.highlight?700:400;return v.jsx("span",{style:{fontWeight:f},children:u.text},`${n.place_id}_${u.text}`)}),v.jsx(F.Typography,{variant:"body2",color:"textSecondary",children:s})]})]})})};function GB(t,e,n){if(!e)return;const r=document.createElement("script");r.setAttribute("async",""),r.setAttribute("id",n),r.src=t,r.onerror=()=>console.error(`Failed to load script: ${t}`),e.appendChild(r)}const Fl={current:null},JB=t=>{const{name:e,label:n=_n(e),resultIcon:r=v.jsx(jB,{}),apiKey:o,highlightMatches:i=!0,types:s,variant:a="outlined",staticLabel:l=!1,staticLabelProps:u={fontSize:".9em",color:"#808080"},readOnly:f=!1,margin:p="dense"}=t,[g,m]=I.useState(null),[y,b]=I.useState(""),[S,C]=I.useState([]),T=I.useRef(!1),[,_,w]=jt.useField(e),{setValue:E}=w,{error:O}=_;typeof window<"u"&&!T.current&&(document.querySelector("#google-maps")||GB(`https://maps.googleapis.com/maps/api/js?key=${o}&libraries=places`,document.querySelector("head"),"google-maps"),T.current=!0);const L=I.useMemo(()=>NC((B,z)=>{Fl.current&&Fl.current.getPlacePredictions(B,z)},200),[]);I.useEffect(()=>{let B=!0;if(!Fl.current&&window.google&&(Fl.current=new window.google.maps.places.AutocompleteService),!Fl.current)return;if(y===""){C(g?[g]:[]);return}return L({input:y,types:s?[s]:[]},K=>{if(B){let G=[];g&&(G=[g]),K&&(G=[...G,...K]);const Y=G.filter((Z,me,he)=>me===he.findIndex(oe=>oe.place_id===Z.place_id));C(Y)}}),()=>{B=!1}},[g,y,L,s]);const P=I.useCallback(B=>{const q=(B?[B,...S]:S).filter((K,G,Y)=>G===Y.findIndex(Z=>Z.place_id===K.place_id));C(q),m(B),E(B?B.description:"")},[S,C,m,E]),$=B=>{b(B)},M=["name","apiKey","resultIcon","highlightMatches","variant","staticLabel","staticLabelProps","margin"],A=B=>v.jsx(F.TextField,{margin:p,variant:a,...B,...Jn({...t},M),label:l?void 0:n,hiddenLabel:l,error:!!O}),N=B=>typeof B=="string"?B:B.description,V=(B,z)=>v.jsx(YB,{listItemProps:B,option:z,resultIcon:r,highlightMatches:i},z.place_id);I.useEffect(()=>{const B=z=>{z.key==="Enter"&&S.length>0&&P(S[0])};return window.addEventListener("keydown",B),()=>{window.removeEventListener("keydown",B)}},[S,P]);const R=v.jsx(F.Autocomplete,{id:`${e}-loc`,"data-testid":"location-autocomplete",getOptionLabel:N,filterOptions:B=>B,options:S,autoComplete:!0,includeInputInList:!0,filterSelectedOptions:!0,value:g,onChange:(B,z)=>P(z),onInputChange:(B,z)=>$(z),disabled:t.disabled,renderOption:V,renderInput:A});return v.jsxs(F.FormControl,{margin:p,fullWidth:!0,children:[(l||f)&&v.jsx(F.Typography,{...u,children:n}),f?v.jsx(F.Typography,{children:g==null?void 0:g.description}):v.jsxs(F.Box,{children:[R,v.jsx(Xn,{name:e,id:`${e}-err`})]})]})},FC=t=>{const{name:e,radios:n=[],label:r=_n(e),labelPlacement:o="end",labelAlignment:i=o==="end"||o==="start"?"top":"center",required:s=!1,disabled:a=!1,readOnly:l=!1,margin:u="dense",onChange:f,staticLabelProps:p={fontSize:".9em",color:"#808080"}}=t;i==="top"&&(o==="bottom"||o==="top")&&console.error(`RadioGroup: Ignoring labelAlignment='top'. labelAlignment cannot be 'top' when labelPlacement=${o}`);const[g,m,y]=jt.useField({name:e}),{setValue:b}=y,{value:S}=g,{error:C}=m,T=["radioProps","labelPlacement"],_=["disableRedLabelOnError","disableLabel","sameButtonColor","labelPlacement","focused","margin","fullWidth","labelAlignment"],w=()=>t.labelPlacement=="start"?"right":t.labelPlacement=="top"||t.labelPlacement=="bottom"?"center":"left",E=n.map(($,M)=>{const A=i==="top"&&(o==="start"||o==="end"),N=$.sublabel?v.jsxs("div",{children:[v.jsx("p",{style:{margin:0},children:$.label}),v.jsx(F.Typography,{variant:"caption",style:{fontSize:"0.85rem"},children:$.sublabel})]}):$.label;return v.jsx(F.FormControlLabel,{sx:{alignItems:A?"flex-start":"center"},value:M.toString(),control:v.jsx(F.Radio,{id:`${$.value}-rb`,color:t.sameButtonColor?t.sameButtonColor:$.color??"default",...Jn({...$},T)}),label:v.jsx("div",{style:{marginTop:A?"10px":0},children:N}),labelPlacement:o,disabled:$.disabled||a,style:{textAlign:w()}},`rb-${M}-${r}`)}),O=()=>{const $=n.find(M=>M.value===g.value);return v.jsxs(F.Box,{children:[v.jsx(F.Typography,{...p,children:r}),L($)]})},L=$=>v.jsxs(F.Box,{children:[v.jsx(F.Typography,{children:$==null?void 0:$.label}),($==null?void 0:$.sublabel)&&v.jsx(F.Typography,{variant:"caption",style:{fontSize:"0.85rem"},children:$.sublabel})]}),P=$=>{b($.target.value),f&&f($.target.value)};return l?O():v.jsxs(F.FormControl,{focused:t.focused,margin:u,fullWidth:t.fullWidth,error:!!C,children:[v.jsx(F.FormLabel,{htmlFor:e,required:s,disabled:t.disableLabel,children:r}),v.jsx(F.RadioGroup,{id:e,value:S??"",...Jn({...t},_),onChange:P,children:E}),v.jsx(Xn,{name:e,id:`${e}-err`})]})},ZB=t=>{const{name:e,label:n=_n(e),min:r=0,max:o=100,step:i=1,readOnly:s,staticLabelProps:a={fontSize:".9em",color:"#808080"}}=t,l=jt.useField(e),{value:u}=l[0],{setValue:f}=l[2],p=["label"];return s?(()=>{let m;return Array.isArray(u)?m=s==="percent"?`${100*(u[0]??0)/o}% - ${100*(u[1]??0)/o}%`:`${u[0]??0} - ${u[1]??0}`:m=s==="percent"?`${100*(u??0)/o}%`:`${u??0}`,v.jsxs(F.Box,{children:[v.jsx(F.Typography,{...a,children:n}),v.jsx(F.Typography,{children:m})]})})():v.jsxs(F.FormControl,{fullWidth:!0,children:[v.jsx(F.Typography,{gutterBottom:!0,color:"textSecondary",children:n}),v.jsx(F.Slider,{...Jn({...t},p),id:t.name,value:u??0,onChange:(m,y)=>{f(y)},min:r,max:o,step:i})]})},XB=t=>{const{name:e,options:n=[],label:r=_n(e),selectedOptionIcon:o=void 0,staticLabel:i=!1,staticLabelProps:s={fontSize:".9em",color:"#808080"},variant:a="outlined",readOnly:l=!1,margin:u="dense",required:f}=t,[p,g,m]=jt.useField({name:e}),{setValue:y}=m,{value:b}=p,{error:S}=g,C=I.useCallback(()=>{let A="";for(let N=0;N<n.length;N++)JSON.stringify(n[N].value)===JSON.stringify(b)&&(A=N.toString());return A},[n,b]),T=I.useCallback(()=>{const A=[],N=b.toString().split(",");for(const V of N)for(let R=0;R<n.length;R++)n[R].value===V&&A.push(R);return A},[n,b]);I.useEffect(()=>{E(t.multiple?T():C())},[n,t.multiple,b,T,C]);const _=(A,N)=>t.multiple?!!b.toString().split(",").find(V=>V===JSON.stringify(A.value)):N===n.findIndex(V=>b===V.value),[w,E]=I.useState(t.multiple?T:C),O=n.map((A,N)=>{const V=o&&_(A,N)?o:void 0;return v.jsxs(F.MenuItem,{id:`select-${e}-option-${A.value}`,value:N,disabled:A.disabled,children:[o&&v.jsx(F.ListItemIcon,{children:V}),A.label]},N.toString())}),L=A=>{if(t.multiple){const N=[];A.target.value.forEach(V=>{n[V].value&&N.push(n[V].value)}),y(N.join(","))}else y(n[A.target.value].value);E(A.target.value)},P=["name","options",i?"label":"","required","selectedOptionIcon","variant","staticLabel","staticLabelProps"],$=()=>FF(n,b,t.multiple),M=t.renderValue??$;return v.jsxs(F.FormControl,{fullWidth:!0,variant:a,error:!!S,margin:u,required:f,children:[i||l?v.jsx(F.Typography,{...s,children:r}):v.jsx(F.InputLabel,{id:`${e}-select-label`,children:r}),l?v.jsx(F.Typography,{children:$()}):v.jsxs(F.Box,{children:[v.jsx(F.Select,{id:`${e}-sel`,labelId:`${e}-select-label`,label:i?void 0:r,...Jn({...t},P),name:e,value:w,fullWidth:!0,onChange:A=>L(A),displayEmpty:i,renderValue:M,children:O}),v.jsx(Xn,{name:e,id:`${e}-err`})]})]})},QB=t=>{const{name:e,label:n=_n(e),labelPlacement:r="end",readOnly:o,staticLabelProps:i={fontSize:".9em",color:"#808080"},onChange:s,color:a="primary",chipColor:l,activeValue:u=!0,inactiveValue:f=!1}=t,[p,,g]=jt.useField({name:e}),{setValue:m}=g,{value:y}=p;y===void 0&&console.error(`Please set an initial value for ${e}`);const b=["labelPlacement","chipColor","activeValue","inactiveValue"],S=C=>{if(typeof C!="boolean")return String(C);switch(o){case"YES_NO":return C===u?"Yes":"No";case"ON_OFF":return C===u?"On":"Off";default:return C===u?"True":"False"}};return o?v.jsxs(F.Box,{children:[v.jsx(F.Typography,{...i,children:n}),v.jsx(F.Typography,{children:S(y)})]}):v.jsxs(F.Box,{bgcolor:l??"inherit",sx:l?{display:"inline-flex",justifyContent:"center",alignItems:"center",borderRadius:"32px",padding:"2px 0px 2px 12px"}:{},children:[v.jsx(F.FormControlLabel,{label:n,sx:{"& .MuiFormControlLabel-label":{color:a}},labelPlacement:r,control:v.jsx(F.Switch,{...Jn({...t},b),id:e,...p,onChange:C=>{if(typeof u=="string"&&typeof f=="string"){const T=C.target.checked?u:f;m(T),s&&s(T)}else m(C.target.checked),s&&s(C.target.checked)},checked:y===u})}),v.jsx(Xn,{name:e,id:`${e}-err`})]})},eR=ze([v.jsx("path",{d:"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2M12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8"},"0"),v.jsx("path",{d:"M12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z"},"1")],"AccessTime"),tR=ze(v.jsx("path",{d:"M13 7h-2v4H7v2h4v4h2v-4h4v-2h-4zm-1-5C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8"}),"AddCircleOutline"),nR=ze(v.jsx("path",{d:"M19 7v2.99s-1.99.01-2 0V7h-3s.01-1.99 0-2h3V2h2v3h3v2zm-3 4V8h-3V5H5c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2v-8zM5 19l3-4 2 3 3-4 4 5z"}),"AddPhotoAlternate"),rR=ze(v.jsx("path",{d:"m19 18 2 1V3c0-1.1-.9-2-2-2H8.99C7.89 1 7 1.9 7 3h10c1.1 0 2 .9 2 2zM15 5H5c-1.1 0-2 .9-2 2v16l7-3 7 3V7c0-1.1-.9-2-2-2"}),"Bookmarks"),oR=ze(v.jsx("path",{d:"M9 16.17 4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"}),"Check"),iR=ze(v.jsx("path",{d:"M22 7h-9v2h9zm0 8h-9v2h9zM5.54 11 2 7.46l1.41-1.41 2.12 2.12 4.24-4.24 1.41 1.41zm0 8L2 15.46l1.41-1.41 2.12 2.12 4.24-4.24 1.41 1.41z"}),"Checklist"),sR=ze(v.jsx("path",{d:"M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}),"Close"),aR=ze(v.jsx("path",{d:"M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}),"CloseOutlined"),lR=ze(v.jsx("path",{d:"M9.4 16.6 4.8 12l4.6-4.6L8 6l-6 6 6 6zm5.2 0 4.6-4.6-4.6-4.6L16 6l6 6-6 6z"}),"Code"),$C=ze(v.jsx("path",{d:"M12 3c-4.97 0-9 4.03-9 9s4.03 9 9 9 9-4.03 9-9c0-.46-.04-.92-.1-1.36-.98 1.37-2.58 2.26-4.4 2.26-2.98 0-5.4-2.42-5.4-5.4 0-1.81.89-3.42 2.26-4.4-.44-.06-.9-.1-1.36-.1"}),"DarkMode"),BC=ze(v.jsx("path",{d:"M14 2H6c-1.1 0-1.99.9-1.99 2L4 20c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8zm2 16H8v-2h8zm0-4H8v-2h8zm-3-5V3.5L18.5 9z"}),"Description"),cR=ze(v.jsx("path",{d:"M5 20h14v-2H5zM19 9h-4V3H9v6H5l7 7z"}),"Download"),uR=ze(v.jsx("path",{d:"M3 17.25V21h3.75L17.81 9.94l-3.75-3.75zM20.71 7.04c.39-.39.39-1.02 0-1.41l-2.34-2.34a.996.996 0 0 0-1.41 0l-1.83 1.83 3.75 3.75z"}),"Edit"),dR=ze(v.jsx("path",{d:"M7 15v2h10v-2zm-4 6h18v-2H3zm0-8h18v-2H3zm4-6v2h10V7zM3 3v2h18V3z"}),"FormatAlignCenter"),fR=ze(v.jsx("path",{d:"M3 21h18v-2H3zm0-4h18v-2H3zm0-4h18v-2H3zm0-4h18V7H3zm0-6v2h18V3z"}),"FormatAlignJustify"),pR=ze(v.jsx("path",{d:"M15 15H3v2h12zm0-8H3v2h12zM3 13h18v-2H3zm0 8h18v-2H3zM3 3v2h18V3z"}),"FormatAlignLeft"),hR=ze(v.jsx("path",{d:"M3 21h18v-2H3zm6-4h12v-2H9zm-6-4h18v-2H3zm6-4h12V7H9zM3 3v2h18V3z"}),"FormatAlignRight"),gR=ze(v.jsx("path",{d:"M15.6 10.79c.97-.67 1.65-1.77 1.65-2.79 0-2.26-1.75-4-4-4H7v14h7.04c2.09 0 3.71-1.7 3.71-3.79 0-1.52-.86-2.82-2.15-3.42M10 6.5h3c.83 0 1.5.67 1.5 1.5s-.67 1.5-1.5 1.5h-3zm3.5 9H10v-3h3.5c.83 0 1.5.67 1.5 1.5s-.67 1.5-1.5 1.5"}),"FormatBold"),mR=ze(v.jsx("path",{d:"M3.27 5 2 6.27l6.97 6.97L6.5 19h3l1.57-3.66L16.73 21 18 19.73 3.55 5.27zM6 5v.18L8.82 8h2.4l-.72 1.68 2.1 2.1L14.21 8H20V5z"}),"FormatClear"),yR=ze(v.jsx("path",{d:"M16.56 8.94 7.62 0 6.21 1.41l2.38 2.38-5.15 5.15c-.59.59-.59 1.54 0 2.12l5.5 5.5c.29.29.68.44 1.06.44s.77-.15 1.06-.44l5.5-5.5c.59-.58.59-1.53 0-2.12M5.21 10 10 5.21 14.79 10zM19 11.5s-2 2.17-2 3.5c0 1.1.9 2 2 2s2-.9 2-2c0-1.33-2-3.5-2-3.5M2 20h20v4H2z"}),"FormatColorFill"),bR=ze(v.jsx("path",{d:"M11 17h10v-2H11zm-8-5 4 4V8zm0 9h18v-2H3zM3 3v2h18V3zm8 6h10V7H11zm0 4h10v-2H11z"}),"FormatIndentDecrease"),vR=ze(v.jsx("path",{d:"M3 21h18v-2H3zM3 8v8l4-4zm8 9h10v-2H11zM3 3v2h18V3zm8 6h10V7H11zm0 4h10v-2H11z"}),"FormatIndentIncrease"),xR=ze(v.jsx("path",{d:"M10 4v3h2.21l-3.42 8H6v3h8v-3h-2.21l3.42-8H18V4z"}),"FormatItalic"),SR=ze(v.jsx("path",{d:"M4 10.5c-.83 0-1.5.67-1.5 1.5s.67 1.5 1.5 1.5 1.5-.67 1.5-1.5-.67-1.5-1.5-1.5m0-6c-.83 0-1.5.67-1.5 1.5S3.17 7.5 4 7.5 5.5 6.83 5.5 6 4.83 4.5 4 4.5m0 12c-.83 0-1.5.68-1.5 1.5s.68 1.5 1.5 1.5 1.5-.68 1.5-1.5-.67-1.5-1.5-1.5M7 19h14v-2H7zm0-6h14v-2H7zm0-8v2h14V5z"}),"FormatListBulleted"),CR=ze(v.jsx("path",{d:"M2 17h2v.5H3v1h1v.5H2v1h3v-4H2zm1-9h1V4H2v1h1zm-1 3h1.8L2 13.1v.9h3v-1H3.2L5 10.9V10H2zm5-6v2h14V5zm0 14h14v-2H7zm0-6h14v-2H7z"}),"FormatListNumbered"),wR=ze(v.jsx("path",{d:"M6 17h3l2-4V7H5v6h3zm8 0h3l2-4V7h-6v6h3z"}),"FormatQuote"),_R=ze(v.jsx("path",{d:"M9 4v3h5v12h3V7h5V4zm-6 8h3v7h3v-7h3V9H3z"}),"FormatSize"),TR=ze(v.jsx("path",{d:"M12 17c3.31 0 6-2.69 6-6V3h-2.5v8c0 1.93-1.57 3.5-3.5 3.5S8.5 12.93 8.5 11V3H6v8c0 3.31 2.69 6 6 6m-7 2v2h14v-2z"}),"FormatUnderlined"),kR=ze(v.jsx("path",{d:"M8 4v1.45l2 2V4h4v4h-3.45l2 2H14v1.45l2 2V10h4v4h-3.45l2 2H20v1.45l2 2V4c0-1.1-.9-2-2-2H4.55l2 2zm8 0h4v4h-4zM1.27 1.27 0 2.55l2 2V20c0 1.1.9 2 2 2h15.46l2 2 1.27-1.27zM10 12.55 11.45 14H10zm-6-6L5.45 8H4zM8 20H4v-4h4zm0-6H4v-4h3.45l.55.55zm6 6h-4v-4h3.45l.55.54zm2 0v-1.46L17.46 20z"}),"GridOff"),ER=ze(v.jsx("path",{fillRule:"evenodd",d:"M4 11h16v2H4z"}),"HorizontalRule"),MR=ze(v.jsx("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m1 15h-2v-6h2zm0-8h-2V7h2z"}),"Info"),OR=ze(v.jsx("path",{d:"M7.41 8.59 12 13.17l4.59-4.58L18 10l-6 6-6-6z"}),"KeyboardArrowDown"),RC=ze(v.jsx("path",{d:"M7.41 15.41 12 10.83l4.59 4.58L18 14l-6-6-6 6z"}),"KeyboardArrowUp"),zC=ze(v.jsx("path",{d:"M12 7c-2.76 0-5 2.24-5 5s2.24 5 5 5 5-2.24 5-5-2.24-5-5-5M2 13h2c.55 0 1-.45 1-1s-.45-1-1-1H2c-.55 0-1 .45-1 1s.45 1 1 1m18 0h2c.55 0 1-.45 1-1s-.45-1-1-1h-2c-.55 0-1 .45-1 1s.45 1 1 1M11 2v2c0 .55.45 1 1 1s1-.45 1-1V2c0-.55-.45-1-1-1s-1 .45-1 1m0 18v2c0 .55.45 1 1 1s1-.45 1-1v-2c0-.55-.45-1-1-1s-1 .45-1 1M5.99 4.58c-.39-.39-1.03-.39-1.41 0-.39.39-.39 1.03 0 1.41l1.06 1.06c.39.39 1.03.39 1.41 0s.39-1.03 0-1.41zm12.37 12.37c-.39-.39-1.03-.39-1.41 0-.39.39-.39 1.03 0 1.41l1.06 1.06c.39.39 1.03.39 1.41 0 .39-.39.39-1.03 0-1.41zm1.06-10.96c.39-.39.39-1.03 0-1.41-.39-.39-1.03-.39-1.41 0l-1.06 1.06c-.39.39-.39 1.03 0 1.41s1.03.39 1.41 0zM7.05 18.36c.39-.39.39-1.03 0-1.41-.39-.39-1.03-.39-1.41 0l-1.06 1.06c-.39.39-.39 1.03 0 1.41s1.03.39 1.41 0z"}),"LightMode"),Ju=ze(v.jsx("path",{d:"M3.9 12c0-1.71 1.39-3.1 3.1-3.1h4V7H7c-2.76 0-5 2.24-5 5s2.24 5 5 5h4v-1.9H7c-1.71 0-3.1-1.39-3.1-3.1M8 13h8v-2H8zm9-6h-4v1.9h4c1.71 0 3.1 1.39 3.1 3.1s-1.39 3.1-3.1 3.1h-4V17h4c2.76 0 5-2.24 5-5s-2.24-5-5-5"}),"Link"),AR=ze(v.jsx("path",{d:"m17 7-1.41 1.41L18.17 11H8v2h10.17l-2.58 2.58L17 17l5-5zM4 5h8V3H4c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h8v-2H4z"}),"Logout"),IR=ze(v.jsx("path",{d:"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z"}),"Menu"),DR=ze(v.jsx("path",{d:"M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"}),"NavigateNext"),PR=ze(v.jsx("path",{d:"M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4m0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4"}),"Person"),NR=ze(v.jsx("path",{d:"M18.4 10.6C16.55 8.99 14.15 8 11.5 8c-4.65 0-8.58 3.03-9.96 7.22L3.9 16c1.05-3.19 4.05-5.5 7.6-5.5 1.95 0 3.73.72 5.12 1.88L13 16h9V7z"}),"Redo"),LR=ze(v.jsx("path",{d:"M19 13H5v-2h14z"}),"Remove"),FR=ze(v.jsx("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m5 11H7v-2h10z"}),"RemoveCircle"),$R=ze(v.jsx("path",{d:"M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14"}),"SearchOutlined"),BR=ze(v.jsx("path",{d:"M3 18h6v-2H3zM3 6v2h18V6zm0 7h12v-2H3z"}),"Sort"),RR=ze(v.jsx("path",{d:"M6.85 7.08C6.85 4.37 9.45 3 12.24 3c1.64 0 3 .49 3.9 1.28.77.65 1.46 1.73 1.46 3.24h-3.01c0-.31-.05-.59-.15-.85-.29-.86-1.2-1.28-2.25-1.28-1.86 0-2.34 1.02-2.34 1.7 0 .48.25.88.74 1.21.38.25.77.48 1.41.7H7.39c-.21-.34-.54-.89-.54-1.92M21 12v-2H3v2h9.62c1.15.45 1.96.75 1.96 1.97 0 1-.81 1.67-2.28 1.67-1.54 0-2.93-.54-2.93-2.51H6.4c0 .55.08 1.13.24 1.58.81 2.29 3.29 3.3 5.67 3.3 2.27 0 5.3-.89 5.3-4.05 0-.3-.01-1.16-.48-1.94H21z"}),"StrikethroughS"),zR=ze(v.jsx("path",{d:"M22 18h-2v1h3v1h-4v-2c0-.55.45-1 1-1h2v-1h-3v-1h3c.55 0 1 .45 1 1v1c0 .55-.45 1-1 1M5.88 18h2.66l3.4-5.42h.12l3.4 5.42h2.66l-4.65-7.27L17.81 4h-2.68l-3.07 4.99h-.12L8.85 4H6.19l4.32 6.73z"}),"Subscript"),VR=ze(v.jsx("path",{d:"M22 7h-2v1h3v1h-4V7c0-.55.45-1 1-1h2V5h-3V4h3c.55 0 1 .45 1 1v1c0 .55-.45 1-1 1M5.88 20h2.66l3.4-5.42h.12l3.4 5.42h2.66l-4.65-7.27L17.81 6h-2.68l-3.07 4.99h-.12L8.85 6H6.19l4.32 6.73z"}),"Superscript"),HR=ze(v.jsx("path",{d:"M12.5 8c-2.65 0-5.05.99-6.9 2.6L2 7v9h9l-3.62-3.62c1.39-1.16 3.16-1.88 5.12-1.88 3.54 0 6.55 2.31 7.6 5.5l2.37-.78C21.08 11.03 17.15 8 12.5 8"}),"Undo"),jR=t=>{const{onSearch:e,initialValue:n="",lazySearch:r=!1}=t,[o,i]=J.useState(n),s=f=>{i(f.target.value),r||e(f.target.value)},a=f=>{f.key==="Enter"&&l()},l=()=>{e(o)},u=()=>{i(""),e("")};return v.jsx(F.TextField,{type:"text",placeholder:"Search...",value:o,onChange:s,onKeyDown:a,className:"search-bar",size:"small",fullWidth:!0,slotProps:{input:{startAdornment:v.jsx(F.InputAdornment,{position:"start",children:v.jsx(F.IconButton,{"data-testid":"search-button",style:{marginLeft:-10},onClick:l,children:v.jsx($R,{})})}),endAdornment:o&&v.jsx(F.IconButton,{style:{marginRight:-10},"aria-label":"clear search","data-testid":"clear-search",onClick:u,children:v.jsx(aR,{})})}}})};function ne(){return ne=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)({}).hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},ne.apply(null,arguments)}function rt(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.includes(r))continue;n[r]=t[r]}return n}function Wt({props:t,name:e}){return E5({props:t,name:e,defaultTheme:qu,themeId:Pl})}const WR=["localeText"],Zu=I.createContext(null);process.env.NODE_ENV!=="production"&&(Zu.displayName="MuiPickersAdapterContext");const ag=function(e){const{localeText:n}=e,r=rt(e,WR),{utils:o,localeText:i}=I.useContext(Zu)??{utils:void 0,localeText:void 0},s=Wt({props:r,name:"MuiLocalizationProvider"}),{children:a,dateAdapter:l,dateFormats:u,dateLibInstance:f,adapterLocale:p,localeText:g}=s,m=I.useMemo(()=>ne({},g,i,n),[g,i,n]),y=I.useMemo(()=>{if(!l)return o||null;const C=new l({locale:p,formats:u,instance:f});if(!C.isMUIAdapter)throw new Error(["MUI X: The date adapter should be imported from `@mui/x-date-pickers` or `@mui/x-date-pickers-pro`, not from `@date-io`","For example, `import { AdapterDayjs } from '@mui/x-date-pickers/AdapterDayjs'` instead of `import AdapterDayjs from '@date-io/dayjs'`","More information on the installation documentation: https://mui.com/x/react-date-pickers/getting-started/#installation"].join(`
|
|
106
|
-
`));return C},[l,p,u,f,o]),b=I.useMemo(()=>y?{minDate:y.date("1900-01-01T00:00:00.000"),maxDate:y.date("2099-12-31T00:00:00.000")}:null,[y]),S=I.useMemo(()=>({utils:y,defaultDates:b,localeText:m}),[b,y,m]);return v.jsx(Zu.Provider,{value:S,children:a})};process.env.NODE_ENV!=="production"&&(ag.propTypes={adapterLocale:c.any,children:c.node,dateAdapter:c.func,dateFormats:c.shape({dayOfMonth:c.string,dayOfMonthFull:c.string,fullDate:c.string,fullTime:c.string,fullTime12h:c.string,fullTime24h:c.string,hours12h:c.string,hours24h:c.string,keyboardDate:c.string,keyboardDateTime:c.string,keyboardDateTime12h:c.string,keyboardDateTime24h:c.string,meridiem:c.string,minutes:c.string,month:c.string,monthShort:c.string,normalDate:c.string,normalDateWithWeekday:c.string,seconds:c.string,shortDate:c.string,weekday:c.string,weekdayShort:c.string,year:c.string}),dateLibInstance:c.any,localeText:c.object});var Xu={exports:{}},qR=Xu.exports,VC;function UR(){return VC||(VC=1,function(t,e){(function(n,r){t.exports=r()})(qR,function(){var n=1e3,r=6e4,o=36e5,i="millisecond",s="second",a="minute",l="hour",u="day",f="week",p="month",g="quarter",m="year",y="date",b="Invalid Date",S=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,C=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,T={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(R){var B=["th","st","nd","rd"],z=R%100;return"["+R+(B[(z-20)%10]||B[z]||B[0])+"]"}},_=function(R,B,z){var q=String(R);return!q||q.length>=B?R:""+Array(B+1-q.length).join(z)+R},w={s:_,z:function(R){var B=-R.utcOffset(),z=Math.abs(B),q=Math.floor(z/60),K=z%60;return(B<=0?"+":"-")+_(q,2,"0")+":"+_(K,2,"0")},m:function R(B,z){if(B.date()<z.date())return-R(z,B);var q=12*(z.year()-B.year())+(z.month()-B.month()),K=B.clone().add(q,p),G=z-K<0,Y=B.clone().add(q+(G?-1:1),p);return+(-(q+(z-K)/(G?K-Y:Y-K))||0)},a:function(R){return R<0?Math.ceil(R)||0:Math.floor(R)},p:function(R){return{M:p,y:m,w:f,d:u,D:y,h:l,m:a,s,ms:i,Q:g}[R]||String(R||"").toLowerCase().replace(/s$/,"")},u:function(R){return R===void 0}},E="en",O={};O[E]=T;var L="$isDayjsObject",P=function(R){return R instanceof N||!(!R||!R[L])},$=function R(B,z,q){var K;if(!B)return E;if(typeof B=="string"){var G=B.toLowerCase();O[G]&&(K=G),z&&(O[G]=z,K=G);var Y=B.split("-");if(!K&&Y.length>1)return R(Y[0])}else{var Z=B.name;O[Z]=B,K=Z}return!q&&K&&(E=K),K||!q&&E},M=function(R,B){if(P(R))return R.clone();var z=typeof B=="object"?B:{};return z.date=R,z.args=arguments,new N(z)},A=w;A.l=$,A.i=P,A.w=function(R,B){return M(R,{locale:B.$L,utc:B.$u,x:B.$x,$offset:B.$offset})};var N=function(){function R(z){this.$L=$(z.locale,null,!0),this.parse(z),this.$x=this.$x||z.x||{},this[L]=!0}var B=R.prototype;return B.parse=function(z){this.$d=function(q){var K=q.date,G=q.utc;if(K===null)return new Date(NaN);if(A.u(K))return new Date;if(K instanceof Date)return new Date(K);if(typeof K=="string"&&!/Z$/i.test(K)){var Y=K.match(S);if(Y){var Z=Y[2]-1||0,me=(Y[7]||"0").substring(0,3);return G?new Date(Date.UTC(Y[1],Z,Y[3]||1,Y[4]||0,Y[5]||0,Y[6]||0,me)):new Date(Y[1],Z,Y[3]||1,Y[4]||0,Y[5]||0,Y[6]||0,me)}}return new Date(K)}(z),this.init()},B.init=function(){var z=this.$d;this.$y=z.getFullYear(),this.$M=z.getMonth(),this.$D=z.getDate(),this.$W=z.getDay(),this.$H=z.getHours(),this.$m=z.getMinutes(),this.$s=z.getSeconds(),this.$ms=z.getMilliseconds()},B.$utils=function(){return A},B.isValid=function(){return this.$d.toString()!==b},B.isSame=function(z,q){var K=M(z);return this.startOf(q)<=K&&K<=this.endOf(q)},B.isAfter=function(z,q){return M(z)<this.startOf(q)},B.isBefore=function(z,q){return this.endOf(q)<M(z)},B.$g=function(z,q,K){return A.u(z)?this[q]:this.set(K,z)},B.unix=function(){return Math.floor(this.valueOf()/1e3)},B.valueOf=function(){return this.$d.getTime()},B.startOf=function(z,q){var K=this,G=!!A.u(q)||q,Y=A.p(z),Z=function(W,te){var ue=A.w(K.$u?Date.UTC(K.$y,te,W):new Date(K.$y,te,W),K);return G?ue:ue.endOf(u)},me=function(W,te){return A.w(K.toDate()[W].apply(K.toDate("s"),(G?[0,0,0,0]:[23,59,59,999]).slice(te)),K)},he=this.$W,oe=this.$M,Q=this.$D,fe="set"+(this.$u?"UTC":"");switch(Y){case m:return G?Z(1,0):Z(31,11);case p:return G?Z(1,oe):Z(0,oe+1);case f:var ce=this.$locale().weekStart||0,ae=(he<ce?he+7:he)-ce;return Z(G?Q-ae:Q+(6-ae),oe);case u:case y:return me(fe+"Hours",0);case l:return me(fe+"Minutes",1);case a:return me(fe+"Seconds",2);case s:return me(fe+"Milliseconds",3);default:return this.clone()}},B.endOf=function(z){return this.startOf(z,!1)},B.$set=function(z,q){var K,G=A.p(z),Y="set"+(this.$u?"UTC":""),Z=(K={},K[u]=Y+"Date",K[y]=Y+"Date",K[p]=Y+"Month",K[m]=Y+"FullYear",K[l]=Y+"Hours",K[a]=Y+"Minutes",K[s]=Y+"Seconds",K[i]=Y+"Milliseconds",K)[G],me=G===u?this.$D+(q-this.$W):q;if(G===p||G===m){var he=this.clone().set(y,1);he.$d[Z](me),he.init(),this.$d=he.set(y,Math.min(this.$D,he.daysInMonth())).$d}else Z&&this.$d[Z](me);return this.init(),this},B.set=function(z,q){return this.clone().$set(z,q)},B.get=function(z){return this[A.p(z)]()},B.add=function(z,q){var K,G=this;z=Number(z);var Y=A.p(q),Z=function(oe){var Q=M(G);return A.w(Q.date(Q.date()+Math.round(oe*z)),G)};if(Y===p)return this.set(p,this.$M+z);if(Y===m)return this.set(m,this.$y+z);if(Y===u)return Z(1);if(Y===f)return Z(7);var me=(K={},K[a]=r,K[l]=o,K[s]=n,K)[Y]||1,he=this.$d.getTime()+z*me;return A.w(he,this)},B.subtract=function(z,q){return this.add(-1*z,q)},B.format=function(z){var q=this,K=this.$locale();if(!this.isValid())return K.invalidDate||b;var G=z||"YYYY-MM-DDTHH:mm:ssZ",Y=A.z(this),Z=this.$H,me=this.$m,he=this.$M,oe=K.weekdays,Q=K.months,fe=K.meridiem,ce=function(te,ue,ee,se){return te&&(te[ue]||te(q,G))||ee[ue].slice(0,se)},ae=function(te){return A.s(Z%12||12,te,"0")},W=fe||function(te,ue,ee){var se=te<12?"AM":"PM";return ee?se.toLowerCase():se};return G.replace(C,function(te,ue){return ue||function(ee){switch(ee){case"YY":return String(q.$y).slice(-2);case"YYYY":return A.s(q.$y,4,"0");case"M":return he+1;case"MM":return A.s(he+1,2,"0");case"MMM":return ce(K.monthsShort,he,Q,3);case"MMMM":return ce(Q,he);case"D":return q.$D;case"DD":return A.s(q.$D,2,"0");case"d":return String(q.$W);case"dd":return ce(K.weekdaysMin,q.$W,oe,2);case"ddd":return ce(K.weekdaysShort,q.$W,oe,3);case"dddd":return oe[q.$W];case"H":return String(Z);case"HH":return A.s(Z,2,"0");case"h":return ae(1);case"hh":return ae(2);case"a":return W(Z,me,!0);case"A":return W(Z,me,!1);case"m":return String(me);case"mm":return A.s(me,2,"0");case"s":return String(q.$s);case"ss":return A.s(q.$s,2,"0");case"SSS":return A.s(q.$ms,3,"0");case"Z":return Y}return null}(te)||Y.replace(":","")})},B.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},B.diff=function(z,q,K){var G,Y=this,Z=A.p(q),me=M(z),he=(me.utcOffset()-this.utcOffset())*r,oe=this-me,Q=function(){return A.m(Y,me)};switch(Z){case m:G=Q()/12;break;case p:G=Q();break;case g:G=Q()/3;break;case f:G=(oe-he)/6048e5;break;case u:G=(oe-he)/864e5;break;case l:G=oe/o;break;case a:G=oe/r;break;case s:G=oe/n;break;default:G=oe}return K?G:A.a(G)},B.daysInMonth=function(){return this.endOf(p).$D},B.$locale=function(){return O[this.$L]},B.locale=function(z,q){if(!z)return this.$L;var K=this.clone(),G=$(z,q,!0);return G&&(K.$L=G),K},B.clone=function(){return A.w(this.$d,this)},B.toDate=function(){return new Date(this.valueOf())},B.toJSON=function(){return this.isValid()?this.toISOString():null},B.toISOString=function(){return this.$d.toISOString()},B.toString=function(){return this.$d.toUTCString()},R}(),V=N.prototype;return M.prototype=V,[["$ms",i],["$s",s],["$m",a],["$H",l],["$W",u],["$M",p],["$y",m],["$D",y]].forEach(function(R){V[R[1]]=function(B){return this.$g(B,R[0],R[1])}}),M.extend=function(R,B){return R.$i||(R(B,N,M),R.$i=!0),M},M.locale=$,M.isDayjs=P,M.unix=function(R){return M(1e3*R)},M.en=O[E],M.Ls=O,M.p={},M})}(Xu)),Xu.exports}var KR=UR();const pn=Zn(KR);var Qu={exports:{}},YR=Qu.exports,HC;function GR(){return HC||(HC=1,function(t,e){(function(n,r){t.exports=r()})(YR,function(){var n="week",r="year";return function(o,i,s){var a=i.prototype;a.week=function(l){if(l===void 0&&(l=null),l!==null)return this.add(7*(l-this.week()),"day");var u=this.$locale().yearStart||1;if(this.month()===11&&this.date()>25){var f=s(this).startOf(r).add(1,r).date(u),p=s(this).endOf(n);if(f.isBefore(p))return 1}var g=s(this).startOf(r).date(u).startOf(n).subtract(1,"millisecond"),m=this.diff(g,n,!0);return m<0?s(this).startOf("week").week():Math.ceil(m)},a.weeks=function(l){return l===void 0&&(l=null),this.week(l)}}})}(Qu)),Qu.exports}var JR=GR();const ZR=Zn(JR);var ed={exports:{}},XR=ed.exports,jC;function QR(){return jC||(jC=1,function(t,e){(function(n,r){t.exports=r()})(XR,function(){var n={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},r=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|Q|YYYY|YY?|ww?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,o=/\d/,i=/\d\d/,s=/\d\d?/,a=/\d*[^-_:/,()\s\d]+/,l={},u=function(S){return(S=+S)+(S>68?1900:2e3)},f=function(S){return function(C){this[S]=+C}},p=[/[+-]\d\d:?(\d\d)?|Z/,function(S){(this.zone||(this.zone={})).offset=function(C){if(!C||C==="Z")return 0;var T=C.match(/([+-]|\d\d)/g),_=60*T[1]+(+T[2]||0);return _===0?0:T[0]==="+"?-_:_}(S)}],g=function(S){var C=l[S];return C&&(C.indexOf?C:C.s.concat(C.f))},m=function(S,C){var T,_=l.meridiem;if(_){for(var w=1;w<=24;w+=1)if(S.indexOf(_(w,0,C))>-1){T=w>12;break}}else T=S===(C?"pm":"PM");return T},y={A:[a,function(S){this.afternoon=m(S,!1)}],a:[a,function(S){this.afternoon=m(S,!0)}],Q:[o,function(S){this.month=3*(S-1)+1}],S:[o,function(S){this.milliseconds=100*+S}],SS:[i,function(S){this.milliseconds=10*+S}],SSS:[/\d{3}/,function(S){this.milliseconds=+S}],s:[s,f("seconds")],ss:[s,f("seconds")],m:[s,f("minutes")],mm:[s,f("minutes")],H:[s,f("hours")],h:[s,f("hours")],HH:[s,f("hours")],hh:[s,f("hours")],D:[s,f("day")],DD:[i,f("day")],Do:[a,function(S){var C=l.ordinal,T=S.match(/\d+/);if(this.day=T[0],C)for(var _=1;_<=31;_+=1)C(_).replace(/\[|\]/g,"")===S&&(this.day=_)}],w:[s,f("week")],ww:[i,f("week")],M:[s,f("month")],MM:[i,f("month")],MMM:[a,function(S){var C=g("months"),T=(g("monthsShort")||C.map(function(_){return _.slice(0,3)})).indexOf(S)+1;if(T<1)throw new Error;this.month=T%12||T}],MMMM:[a,function(S){var C=g("months").indexOf(S)+1;if(C<1)throw new Error;this.month=C%12||C}],Y:[/[+-]?\d+/,f("year")],YY:[i,function(S){this.year=u(S)}],YYYY:[/\d{4}/,f("year")],Z:p,ZZ:p};function b(S){var C,T;C=S,T=l&&l.formats;for(var _=(S=C.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(M,A,N){var V=N&&N.toUpperCase();return A||T[N]||n[N]||T[V].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(R,B,z){return B||z.slice(1)})})).match(r),w=_.length,E=0;E<w;E+=1){var O=_[E],L=y[O],P=L&&L[0],$=L&&L[1];_[E]=$?{regex:P,parser:$}:O.replace(/^\[|\]$/g,"")}return function(M){for(var A={},N=0,V=0;N<w;N+=1){var R=_[N];if(typeof R=="string")V+=R.length;else{var B=R.regex,z=R.parser,q=M.slice(V),K=B.exec(q)[0];z.call(A,K),M=M.replace(K,"")}}return function(G){var Y=G.afternoon;if(Y!==void 0){var Z=G.hours;Y?Z<12&&(G.hours+=12):Z===12&&(G.hours=0),delete G.afternoon}}(A),A}}return function(S,C,T){T.p.customParseFormat=!0,S&&S.parseTwoDigitYear&&(u=S.parseTwoDigitYear);var _=C.prototype,w=_.parse;_.parse=function(E){var O=E.date,L=E.utc,P=E.args;this.$u=L;var $=P[1];if(typeof $=="string"){var M=P[2]===!0,A=P[3]===!0,N=M||A,V=P[2];A&&(V=P[2]),l=this.$locale(),!M&&V&&(l=T.Ls[V]),this.$d=function(q,K,G,Y){try{if(["x","X"].indexOf(K)>-1)return new Date((K==="X"?1e3:1)*q);var Z=b(K)(q),me=Z.year,he=Z.month,oe=Z.day,Q=Z.hours,fe=Z.minutes,ce=Z.seconds,ae=Z.milliseconds,W=Z.zone,te=Z.week,ue=new Date,ee=oe||(me||he?1:ue.getDate()),se=me||ue.getFullYear(),de=0;me&&!he||(de=he>0?he-1:ue.getMonth());var ye,_e=Q||0,Se=fe||0,Me=ce||0,Fe=ae||0;return W?new Date(Date.UTC(se,de,ee,_e,Se,Me,Fe+60*W.offset*1e3)):G?new Date(Date.UTC(se,de,ee,_e,Se,Me,Fe)):(ye=new Date(se,de,ee,_e,Se,Me,Fe),te&&(ye=Y(ye).week(te).toDate()),ye)}catch{return new Date("")}}(O,$,L,T),this.init(),V&&V!==!0&&(this.$L=this.locale(V).$L),N&&O!=this.format($)&&(this.$d=new Date("")),l={}}else if($ instanceof Array)for(var R=$.length,B=1;B<=R;B+=1){P[1]=$[B-1];var z=T.apply(this,P);if(z.isValid()){this.$d=z.$d,this.$L=z.$L,this.init();break}B===R&&(this.$d=new Date(""))}else w.call(this,E)}}})}(ed)),ed.exports}var e3=QR();const t3=Zn(e3);var td={exports:{}},n3=td.exports,WC;function r3(){return WC||(WC=1,function(t,e){(function(n,r){t.exports=r()})(n3,function(){var n={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"};return function(r,o,i){var s=o.prototype,a=s.format;i.en.formats=n,s.format=function(l){l===void 0&&(l="YYYY-MM-DDTHH:mm:ssZ");var u=this.$locale().formats,f=function(p,g){return p.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(m,y,b){var S=b&&b.toUpperCase();return y||g[b]||n[b]||g[S].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(C,T,_){return T||_.slice(1)})})}(l,u===void 0?{}:u);return a.call(this,f)}}})}(td)),td.exports}var o3=r3();const i3=Zn(o3);var nd={exports:{}},s3=nd.exports,qC;function a3(){return qC||(qC=1,function(t,e){(function(n,r){t.exports=r()})(s3,function(){return function(n,r,o){r.prototype.isBetween=function(i,s,a,l){var u=o(i),f=o(s),p=(l=l||"()")[0]==="(",g=l[1]===")";return(p?this.isAfter(u,a):!this.isBefore(u,a))&&(g?this.isBefore(f,a):!this.isAfter(f,a))||(p?this.isBefore(u,a):!this.isAfter(u,a))&&(g?this.isAfter(f,a):!this.isBefore(f,a))}}})}(nd)),nd.exports}var l3=a3();const c3=Zn(l3);var rd={exports:{}},u3=rd.exports,UC;function d3(){return UC||(UC=1,function(t,e){(function(n,r){t.exports=r()})(u3,function(){return function(n,r){var o=r.prototype,i=o.format;o.format=function(s){var a=this,l=this.$locale();if(!this.isValid())return i.bind(this)(s);var u=this.$utils(),f=(s||"YYYY-MM-DDTHH:mm:ssZ").replace(/\[([^\]]+)]|Q|wo|ww|w|WW|W|zzz|z|gggg|GGGG|Do|X|x|k{1,2}|S/g,function(p){switch(p){case"Q":return Math.ceil((a.$M+1)/3);case"Do":return l.ordinal(a.$D);case"gggg":return a.weekYear();case"GGGG":return a.isoWeekYear();case"wo":return l.ordinal(a.week(),"W");case"w":case"ww":return u.s(a.week(),p==="w"?1:2,"0");case"W":case"WW":return u.s(a.isoWeek(),p==="W"?1:2,"0");case"k":case"kk":return u.s(String(a.$H===0?24:a.$H),p==="k"?1:2,"0");case"X":return Math.floor(a.$d.getTime()/1e3);case"x":return a.$d.getTime();case"z":return"["+a.offsetName()+"]";case"zzz":return"["+a.offsetName("long")+"]";default:return p}});return i.bind(this)(f)}}})}(rd)),rd.exports}var f3=d3();const p3=Zn(f3),KC=new Set;function YC(t,e="warning"){if(process.env.NODE_ENV==="production")return;const n=Array.isArray(t)?t.join(`
|
|
105
|
+
}`;var ut=TF(function(){return _t(j,We+"return "+Ee).apply(n,K)});if(ut.source=Ee,Mx(ut))throw ut;return ut}function Ece(d){return Mt(d).toLowerCase()}function Mce(d){return Mt(d).toUpperCase()}function Oce(d,h,x){if(d=Mt(d),d&&(x||h===n))return NN(d);if(!d||!(h=Er(h)))return d;var k=po(d),D=po(h),j=LN(k,D),K=FN(k,D)+1;return ss(k,j,K).join("")}function Ace(d,h,x){if(d=Mt(d),d&&(x||h===n))return d.slice(0,BN(d)+1);if(!d||!(h=Er(h)))return d;var k=po(d),D=FN(k,po(h))+1;return ss(k,0,D).join("")}function Ice(d,h,x){if(d=Mt(d),d&&(x||h===n))return d.replace(M1,"");if(!d||!(h=Er(h)))return d;var k=po(d),D=LN(k,po(h));return ss(k,D).join("")}function Dce(d,h){var x=M,k=A;if(nn(h)){var D="separator"in h?h.separator:D;x="length"in h?st(h.length):x,k="omission"in h?Er(h.omission):k}d=Mt(d);var j=d.length;if(al(d)){var K=po(d);j=K.length}if(x>=j)return d;var Q=x-ll(k);if(Q<1)return k;var ie=K?ss(K,0,Q).join(""):d.slice(0,Q);if(D===n)return ie+k;if(K&&(Q+=ie.length-Q),Ox(D)){if(d.slice(Q).search(D)){var Ce,we=ie;for(D.global||(D=q1(D.source,Mt(nN.exec(D))+"g")),D.lastIndex=0;Ce=D.exec(we);)var Ee=Ce.index;ie=ie.slice(0,Ee===n?Q:Ee)}}else if(d.indexOf(Er(D),Q)!=Q){var Ne=ie.lastIndexOf(D);Ne>-1&&(ie=ie.slice(0,Ne))}return ie+k}function Pce(d){return d=Mt(d),d&&si.test(d)?d.replace(rr,loe):d}var Nce=gl(function(d,h,x){return d+(x?" ":"")+h.toUpperCase()}),Dx=kL("toUpperCase");function _F(d,h,x){return d=Mt(d),h=x?n:h,h===n?roe(d)?doe(d):Yre(d):d.match(h)||[]}var TF=dt(function(d,h){try{return Tr(d,n,h)}catch(x){return Mx(x)?x:new ot(x)}}),Lce=di(function(d,h){return Kr(h,function(x){x=Ro(x),ci(d,x,kx(d[x],d))}),d});function Fce(d){var h=d==null?0:d.length,x=Xe();return d=h?Qt(d,function(k){if(typeof k[1]!="function")throw new Yr(s);return[x(k[0]),k[1]]}):[],dt(function(k){for(var D=-1;++D<h;){var j=d[D];if(Tr(j[0],this,k))return Tr(j[1],this,k)}})}function $ce(d){return lie(Jr(d,p))}function Px(d){return function(){return d}}function Bce(d,h){return d==null||d!==d?h:d}var Rce=ML(),zce=ML(!0);function br(d){return d}function Nx(d){return oL(typeof d=="function"?d:Jr(d,p))}function Vce(d){return sL(Jr(d,p))}function Hce(d,h){return aL(d,Jr(h,p))}var jce=dt(function(d,h){return function(x){return mu(x,d,h)}}),Wce=dt(function(d,h){return function(x){return mu(d,x,h)}});function Lx(d,h,x){var k=Dn(h),D=nh(h,k);x==null&&!(nn(h)&&(D.length||!k.length))&&(x=h,h=d,d=this,D=nh(h,Dn(h)));var j=!(nn(x)&&"chain"in x)||!!x.chain,K=pi(d);return Kr(D,function(Q){var ie=h[Q];d[Q]=ie,K&&(d.prototype[Q]=function(){var Ce=this.__chain__;if(j||Ce){var we=d(this.__wrapped__),Ee=we.__actions__=gr(this.__actions__);return Ee.push({func:ie,args:arguments,thisArg:d}),we.__chain__=Ce,we}return ie.apply(d,Qi([this.value()],arguments))})}),d}function qce(){return Bn._===this&&(Bn._=yoe),this}function Fx(){}function Uce(d){return d=st(d),dt(function(h){return lL(h,d)})}var Kce=px(Qt),Yce=px(ON),Gce=px(B1);function kF(d){return xx(d)?R1(Ro(d)):Tie(d)}function Jce(d){return function(h){return d==null?n:Qs(d,h)}}var Zce=AL(),Xce=AL(!0);function $x(){return[]}function Bx(){return!1}function Qce(){return{}}function eue(){return""}function tue(){return!0}function nue(d,h){if(d=st(d),d<1||d>U)return[];var x=Z,k=Yn(d,Z);h=Xe(h),d-=Z;for(var D=H1(k,h);++x<d;)h(x);return D}function rue(d){return it(d)?Qt(d,Ro):Mr(d)?[d]:gr(UL(Mt(d)))}function oue(d){var h=++goe;return Mt(d)+h}var iue=lh(function(d,h){return d+h},0),sue=hx("ceil"),aue=lh(function(d,h){return d/h},1),lue=hx("floor");function cue(d){return d&&d.length?th(d,br,Q1):n}function uue(d,h){return d&&d.length?th(d,Xe(h,2),Q1):n}function due(d){return DN(d,br)}function fue(d,h){return DN(d,Xe(h,2))}function pue(d){return d&&d.length?th(d,br,rx):n}function hue(d,h){return d&&d.length?th(d,Xe(h,2),rx):n}var gue=lh(function(d,h){return d*h},1),mue=hx("round"),yue=lh(function(d,h){return d-h},0);function bue(d){return d&&d.length?V1(d,br):0}function vue(d,h){return d&&d.length?V1(d,Xe(h,2)):0}return H.after=Vae,H.ary=rF,H.assign=Mle,H.assignIn=yF,H.assignInWith=Sh,H.assignWith=Ole,H.at=Ale,H.before=oF,H.bind=kx,H.bindAll=Lce,H.bindKey=iF,H.castArray=Qae,H.chain=eF,H.chunk=lse,H.compact=cse,H.concat=use,H.cond=Fce,H.conforms=$ce,H.constant=Px,H.countBy=bae,H.create=Ile,H.curry=sF,H.curryRight=aF,H.debounce=lF,H.defaults=Dle,H.defaultsDeep=Ple,H.defer=Hae,H.delay=jae,H.difference=dse,H.differenceBy=fse,H.differenceWith=pse,H.drop=hse,H.dropRight=gse,H.dropRightWhile=mse,H.dropWhile=yse,H.fill=bse,H.filter=xae,H.flatMap=wae,H.flatMapDeep=_ae,H.flatMapDepth=Tae,H.flatten=JL,H.flattenDeep=vse,H.flattenDepth=xse,H.flip=Wae,H.flow=Rce,H.flowRight=zce,H.fromPairs=Sse,H.functions=zle,H.functionsIn=Vle,H.groupBy=kae,H.initial=wse,H.intersection=_se,H.intersectionBy=Tse,H.intersectionWith=kse,H.invert=jle,H.invertBy=Wle,H.invokeMap=Mae,H.iteratee=Nx,H.keyBy=Oae,H.keys=Dn,H.keysIn=yr,H.map=gh,H.mapKeys=Ule,H.mapValues=Kle,H.matches=Vce,H.matchesProperty=Hce,H.memoize=yh,H.merge=Yle,H.mergeWith=bF,H.method=jce,H.methodOf=Wce,H.mixin=Lx,H.negate=bh,H.nthArg=Uce,H.omit=Gle,H.omitBy=Jle,H.once=qae,H.orderBy=Aae,H.over=Kce,H.overArgs=Uae,H.overEvery=Yce,H.overSome=Gce,H.partial=Ex,H.partialRight=cF,H.partition=Iae,H.pick=Zle,H.pickBy=vF,H.property=kF,H.propertyOf=Jce,H.pull=Ase,H.pullAll=XL,H.pullAllBy=Ise,H.pullAllWith=Dse,H.pullAt=Pse,H.range=Zce,H.rangeRight=Xce,H.rearg=Kae,H.reject=Nae,H.remove=Nse,H.rest=Yae,H.reverse=_x,H.sampleSize=Fae,H.set=Qle,H.setWith=ece,H.shuffle=$ae,H.slice=Lse,H.sortBy=zae,H.sortedUniq=Hse,H.sortedUniqBy=jse,H.split=wce,H.spread=Gae,H.tail=Wse,H.take=qse,H.takeRight=Use,H.takeRightWhile=Kse,H.takeWhile=Yse,H.tap=cae,H.throttle=Jae,H.thru=hh,H.toArray=hF,H.toPairs=xF,H.toPairsIn=SF,H.toPath=rue,H.toPlainObject=mF,H.transform=tce,H.unary=Zae,H.union=Gse,H.unionBy=Jse,H.unionWith=Zse,H.uniq=Xse,H.uniqBy=Qse,H.uniqWith=eae,H.unset=nce,H.unzip=Tx,H.unzipWith=QL,H.update=rce,H.updateWith=oce,H.values=bl,H.valuesIn=ice,H.without=tae,H.words=_F,H.wrap=Xae,H.xor=nae,H.xorBy=rae,H.xorWith=oae,H.zip=iae,H.zipObject=sae,H.zipObjectDeep=aae,H.zipWith=lae,H.entries=xF,H.entriesIn=SF,H.extend=yF,H.extendWith=Sh,Lx(H,H),H.add=iue,H.attempt=TF,H.camelCase=cce,H.capitalize=CF,H.ceil=sue,H.clamp=sce,H.clone=ele,H.cloneDeep=nle,H.cloneDeepWith=rle,H.cloneWith=tle,H.conformsTo=ole,H.deburr=wF,H.defaultTo=Bce,H.divide=aue,H.endsWith=uce,H.eq=go,H.escape=dce,H.escapeRegExp=fce,H.every=vae,H.find=Sae,H.findIndex=YL,H.findKey=Nle,H.findLast=Cae,H.findLastIndex=GL,H.findLastKey=Lle,H.floor=lue,H.forEach=tF,H.forEachRight=nF,H.forIn=Fle,H.forInRight=$le,H.forOwn=Ble,H.forOwnRight=Rle,H.get=Ax,H.gt=ile,H.gte=sle,H.has=Hle,H.hasIn=Ix,H.head=ZL,H.identity=br,H.includes=Eae,H.indexOf=Cse,H.inRange=ace,H.invoke=qle,H.isArguments=na,H.isArray=it,H.isArrayBuffer=ale,H.isArrayLike=mr,H.isArrayLikeObject=hn,H.isBoolean=lle,H.isBuffer=as,H.isDate=cle,H.isElement=ule,H.isEmpty=dle,H.isEqual=fle,H.isEqualWith=ple,H.isError=Mx,H.isFinite=hle,H.isFunction=pi,H.isInteger=uF,H.isLength=vh,H.isMap=dF,H.isMatch=gle,H.isMatchWith=mle,H.isNaN=yle,H.isNative=ble,H.isNil=xle,H.isNull=vle,H.isNumber=fF,H.isObject=nn,H.isObjectLike=dn,H.isPlainObject=Cu,H.isRegExp=Ox,H.isSafeInteger=Sle,H.isSet=pF,H.isString=xh,H.isSymbol=Mr,H.isTypedArray=yl,H.isUndefined=Cle,H.isWeakMap=wle,H.isWeakSet=_le,H.join=Ese,H.kebabCase=pce,H.last=Xr,H.lastIndexOf=Mse,H.lowerCase=hce,H.lowerFirst=gce,H.lt=Tle,H.lte=kle,H.max=cue,H.maxBy=uue,H.mean=due,H.meanBy=fue,H.min=pue,H.minBy=hue,H.stubArray=$x,H.stubFalse=Bx,H.stubObject=Qce,H.stubString=eue,H.stubTrue=tue,H.multiply=gue,H.nth=Ose,H.noConflict=qce,H.noop=Fx,H.now=mh,H.pad=mce,H.padEnd=yce,H.padStart=bce,H.parseInt=vce,H.random=lce,H.reduce=Dae,H.reduceRight=Pae,H.repeat=xce,H.replace=Sce,H.result=Xle,H.round=mue,H.runInContext=oe,H.sample=Lae,H.size=Bae,H.snakeCase=Cce,H.some=Rae,H.sortedIndex=Fse,H.sortedIndexBy=$se,H.sortedIndexOf=Bse,H.sortedLastIndex=Rse,H.sortedLastIndexBy=zse,H.sortedLastIndexOf=Vse,H.startCase=_ce,H.startsWith=Tce,H.subtract=yue,H.sum=bue,H.sumBy=vue,H.template=kce,H.times=nue,H.toFinite=hi,H.toInteger=st,H.toLength=gF,H.toLower=Ece,H.toNumber=Qr,H.toSafeInteger=Ele,H.toString=Mt,H.toUpper=Mce,H.trim=Oce,H.trimEnd=Ace,H.trimStart=Ice,H.truncate=Dce,H.unescape=Pce,H.uniqueId=oue,H.upperCase=Nce,H.upperFirst=Dx,H.each=tF,H.eachRight=nF,H.first=ZL,Lx(H,function(){var d={};return $o(H,function(h,x){Ot.call(H.prototype,x)||(d[x]=h)}),d}(),{chain:!1}),H.VERSION=r,Kr(["bind","bindKey","curry","curryRight","partial","partialRight"],function(d){H[d].placeholder=H}),Kr(["drop","take"],function(d,h){mt.prototype[d]=function(x){x=x===n?1:wn(st(x),0);var k=this.__filtered__&&!h?new mt(this):this.clone();return k.__filtered__?k.__takeCount__=Yn(x,k.__takeCount__):k.__views__.push({size:Yn(x,Z),type:d+(k.__dir__<0?"Right":"")}),k},mt.prototype[d+"Right"]=function(x){return this.reverse()[d](x).reverse()}}),Kr(["filter","map","takeWhile"],function(d,h){var x=h+1,k=x==V||x==R;mt.prototype[d]=function(D){var j=this.clone();return j.__iteratees__.push({iteratee:Xe(D,3),type:x}),j.__filtered__=j.__filtered__||k,j}}),Kr(["head","last"],function(d,h){var x="take"+(h?"Right":"");mt.prototype[d]=function(){return this[x](1).value()[0]}}),Kr(["initial","tail"],function(d,h){var x="drop"+(h?"":"Right");mt.prototype[d]=function(){return this.__filtered__?new mt(this):this[x](1)}}),mt.prototype.compact=function(){return this.filter(br)},mt.prototype.find=function(d){return this.filter(d).head()},mt.prototype.findLast=function(d){return this.reverse().find(d)},mt.prototype.invokeMap=dt(function(d,h){return typeof d=="function"?new mt(this):this.map(function(x){return mu(x,d,h)})}),mt.prototype.reject=function(d){return this.filter(bh(Xe(d)))},mt.prototype.slice=function(d,h){d=st(d);var x=this;return x.__filtered__&&(d>0||h<0)?new mt(x):(d<0?x=x.takeRight(-d):d&&(x=x.drop(d)),h!==n&&(h=st(h),x=h<0?x.dropRight(-h):x.take(h-d)),x)},mt.prototype.takeRightWhile=function(d){return this.reverse().takeWhile(d).reverse()},mt.prototype.toArray=function(){return this.take(Z)},$o(mt.prototype,function(d,h){var x=/^(?:filter|find|map|reject)|While$/.test(h),k=/^(?:head|last)$/.test(h),D=H[k?"take"+(h=="last"?"Right":""):h],j=k||/^find/.test(h);D&&(H.prototype[h]=function(){var K=this.__wrapped__,Q=k?[1]:arguments,ie=K instanceof mt,Ce=Q[0],we=ie||it(K),Ee=function(ht){var xt=D.apply(H,Qi([ht],Q));return k&&Ne?xt[0]:xt};we&&x&&typeof Ce=="function"&&Ce.length!=1&&(ie=we=!1);var Ne=this.__chain__,We=!!this.__actions__.length,et=j&&!Ne,ut=ie&&!We;if(!j&&we){K=ut?K:new mt(this);var tt=d.apply(K,Q);return tt.__actions__.push({func:hh,args:[Ee],thisArg:n}),new Gr(tt,Ne)}return et&&ut?d.apply(this,Q):(tt=this.thru(Ee),et?k?tt.value()[0]:tt.value():tt)})}),Kr(["pop","push","shift","sort","splice","unshift"],function(d){var h=zp[d],x=/^(?:push|sort|unshift)$/.test(d)?"tap":"thru",k=/^(?:pop|shift)$/.test(d);H.prototype[d]=function(){var D=arguments;if(k&&!this.__chain__){var j=this.value();return h.apply(it(j)?j:[],D)}return this[x](function(K){return h.apply(it(K)?K:[],D)})}}),$o(mt.prototype,function(d,h){var x=H[h];if(x){var k=x.name+"";Ot.call(fl,k)||(fl[k]=[]),fl[k].push({name:h,func:x})}}),fl[ah(n,C).name]=[{name:"wrapper",func:n}],mt.prototype.clone=Poe,mt.prototype.reverse=Noe,mt.prototype.value=Loe,H.prototype.at=uae,H.prototype.chain=dae,H.prototype.commit=fae,H.prototype.next=pae,H.prototype.plant=gae,H.prototype.reverse=mae,H.prototype.toJSON=H.prototype.valueOf=H.prototype.value=yae,H.prototype.first=H.prototype.head,cu&&(H.prototype[cu]=hae),H},cl=foe();Ys?((Ys.exports=cl)._=cl,N1._=cl):Bn._=cl}).call(MB)}(Nl,Nl.exports)),Nl.exports}var Ku=OB();const AB=t=>{const{name:e,onInputChange:n,onChange:r,onFilter:o,onFilterError:i,fetchOnCount:s=1,preFilterMessage:a=s?"Start typing to see options...":t.noOptionsText,noOptionsText:l,filterOptions:u=P=>P,includeInputInList:f=!0,autoComplete:p=!0,...g}=t,[m,y,b]=jt.useField(e),{setValue:S}=b,[C,T]=J.useState(""),[_,w]=J.useState([]),[E,O]=J.useState(!1),L=Ku.debounce(async(P,$)=>{try{O(!0);const M=await o(P.input);$(M)}catch(M){throw M}finally{O(!1)}},400);return J.useEffect(()=>{if(C===""){w(m.value?[m.value]:[]);return}C.length>=s&&L({input:C},P=>{let $=[];P?($=P,m.value&&($=[m.value,...P.filter(M=>JSON.stringify(M)!==JSON.stringify(m.value))])):m.value&&($=[m.value]),w($)})},[m.value,C]),v.jsx(fC,{name:e,loading:E,filterOptions:u,noOptionsText:C.length<s?a:l,options:_,autoComplete:p,includeInputInList:f,onChange:(P,$,M,A)=>{w($?[$,..._]:_),S($),r&&r(P,$,M,A)},onInputChange:(P,$,M)=>{T($),n&&n(P,$,M)},...g})},IB=t=>{const{name:e,label:n=_n(e),options:r=[],filterSelectedOptions:o=!0,variant:i="outlined",staticLabel:s=!1,staticLabelProps:a={fontSize:".9em",color:"#808080"},readOnly:l,margin:u="dense",fullWidth:f=!0,required:p,onChange:g,getOptionLabel:m=P=>typeof P=="string"?P:String(P),isOptionEqualToValue:y=(P,$)=>JSON.stringify(P)===JSON.stringify($),useFieldAsValue:b,...S}=t,[C,T,_]=jt.useField(e),{setValue:w}=_,{error:E}=T,O={...Jn(S,["useFieldAsValue"]),getOptionLabel:m,options:r,filterSelectedOptions:o,isOptionEqualToValue:y,renderInput:P=>v.jsx(F.TextField,{...P,variant:i,label:s?void 0:n,error:!!E,required:p}),onChange:(P,$,M,A)=>{w(b?$.map(N=>N[b]):$),g&&g(P,$,M,A)},fullWidth:!0,value:b?r.filter(P=>C.value.includes(P[b]))||[]:C.value,slotProps:{paper:{elevation:8,sx:{borderRadius:2}}}},L=()=>C.value.length===0?"":(b?r.filter($=>C.value.includes($[b]))||[]:C.value).map($=>m($)).join(", ");return v.jsxs(F.FormControl,{margin:u,fullWidth:f,required:p,children:[(s||l)&&v.jsx(F.Typography,{...a,children:n}),l?v.jsx(F.Typography,{children:L()}):v.jsxs(F.Box,{children:[v.jsx(F.Autocomplete,{...O,multiple:!0}),v.jsx(Xn,{name:e,id:`${e}-err`})]})]})},DB=t=>{const{name:e,label:n=_n(e),sublabel:r,required:o=!1,labelPlacement:i="end",labelAlignment:s=i==="end"||i==="start"?"top":"center",readOnly:a=!1,staticLabelProps:l={fontSize:".9em",color:"#808080"},onChange:u,...f}=t;s==="top"&&(i==="bottom"||i==="top")&&console.error(`Checkbox: Ignoring labelAlignment='top'. labelAlignment cannot be 'top' when labelPlacement=${i}`);const p=jt.useField({name:e}),g=p[0],m=p[2],y=r?v.jsxs("div",{children:[v.jsx("p",{style:{margin:0},children:n}),v.jsx(F.Typography,{variant:"caption",style:{fontSize:"0.85rem"},children:r})]}):n,b=s==="top"&&(i==="start"||i==="end");return a?g.value&&v.jsx(F.Typography,{...l,children:y}):v.jsxs(F.Box,{children:[v.jsx(F.FormControlLabel,{sx:{alignItems:b?"flex-start":"center"},label:v.jsx("span",{"data-testid":n,style:{display:"inline-block",marginTop:b?"10px":0},children:y}),required:o,labelPlacement:i,control:v.jsx(F.Checkbox,{"data-testid":"checkbox",...f,...g,onChange:(S,C)=>{m.setValue(S.target.checked),u&&u(S,C)},checked:g.value})}),v.jsx(Xn,{name:e,id:`${e}-err`})]})},da=t=>{const{name:e,label:n=_n(e),format:r="",autoFormat:o=r,placeholder:i=n,staticLabel:s=!1,staticLabelProps:a={fontSize:".9em",color:"#808080"},readOnly:l=!1,startIcon:u,endIcon:f,margin:p="dense",noTrimOnBlur:g=!1}=t,[m,y,b]=jt.useField({name:e}),{setValue:S}=b,{value:C}=m,{error:T}=y;C===void 0&&console.error(`Please set an initial value for ${e}`),!r&&o&&console.error("Can't auto format when there is no format");const _=E=>{if(o){const O=LF(E.target.value,r,C,E.target);S(O)}else S(E.target.value);t.onChange&&t.onChange(E)},w=["autoFormat","format","staticLabel","staticLabelProps","endIcon","startIcon"];return v.jsxs(F.FormControl,{margin:p,fullWidth:!0,children:[(s||l)&&v.jsx(F.Typography,{...a,children:n}),l?v.jsx(F.Typography,{children:C}):v.jsxs(F.Box,{children:[v.jsx(F.TextField,{variant:"outlined",fullWidth:!0,...m,id:`${e}-tf`,error:!!T,placeholder:i,...Jn({...t},w),onChange:_,label:s?void 0:n,slotProps:{input:{endAdornment:f,startAdornment:u}},onBlur:E=>{g||S(E.target.value.trim()),t.onBlur&&t.onBlur(E)}}),v.jsx(Xn,{name:e,id:`${e}-err`})]})]})},PB=t=>{const{name:e,checkboxes:n=[],label:r=_n(e),labelPlacement:o="end",labelAlignment:i=o==="end"||o==="start"?"top":"center",required:s=!1,disabled:a=!1,readOnly:l=!1,min:u=0,max:f=n.length,minMaxSubtitle:p="Please select between {min} and {max} options",maxSubtitle:g="Up to {max} max",minSubtitle:m="Please select {min} or more",margin:y="dense",staticLabelProps:b={fontSize:".9em",color:"#808080"}}=t,[S,C,T]=jt.useField({name:e}),{setValue:_}=T,{value:w}=S,{error:E}=C,{setFieldValue:O}=jt.useFormikContext();(u<0||u>=n.length)&&console.error(`CheckboxGroup: "min" cannot be ${u}. It must be a value between 0 and ${n.length-1}.`),(f<=1||f>n.length)&&console.error(`CheckboxGroup: "max" must be a value between 2 and ${n.length}.`),i==="top"&&(o==="bottom"||o==="top")&&console.error(`CheckboxGroup: Ignoring labelAlignment='top'. labelAlignment cannot be 'top' when labelPlacement=${o}`);const L=()=>t.labelPlacement=="start"?"right":t.labelPlacement=="top"||t.labelPlacement=="bottom"?"center":"left",P=N=>typeof N=="string"?N:!N.textField&&!N.sublabel?N.label:v.jsxs(F.Box,{display:"flex",flexDirection:"row",justifyContent:"center",gap:"0.5rem",alignItems:"baseline",children:[v.jsxs(F.Box,{display:"flex",flexDirection:"column",justifyContent:"center",children:[v.jsx("p",{style:{margin:0},children:N.label}),N.sublabel&&v.jsx(F.Typography,{variant:"caption",style:{fontSize:"0.85rem"},children:N.sublabel})]}),N.textField&&v.jsx(da,{label:"",size:"small",margin:"none",sx:{"& .MuiInputBase-input":{height:14}},...N.textField})]}),$=n.map(N=>{const z=typeof N=="string"?N:N.label,V=i==="top"&&(o==="start"||o==="end");return v.jsx(F.FormControlLabel,{sx:{alignItems:V?"flex-start":"center"},value:z,control:v.jsx(F.Checkbox,{}),label:v.jsx("div",{"data-testid":typeof N=="string"?N:N.label,style:{marginTop:V?"10px":0},children:P(N)}),labelPlacement:o,checked:w.includes(z),disabled:a||!w.includes(z)&&w.length===f,style:{textAlign:L()}},`checkbox-group-${z}`)}),M=()=>{if(f<n.length&&u>0)return v.jsx(F.Typography,{variant:"subtitle2",children:p.replace("{min}",`${u}`).replace("{max}",`${f}`)});if(f<n.length)return v.jsx(F.Typography,{variant:"subtitle2",children:g.replace("{max}",`${f}`)});if(u>0)return v.jsx(F.Typography,{variant:"subtitle2",children:m.replace("{min}",`${u}`)})};return l?v.jsxs(F.Box,{children:[v.jsx(F.Typography,{...b,children:r}),w.join(", ")]}):v.jsxs(F.FormControl,{onChange:N=>{const z=N.target.value,V=N.target.checked,B=n.find(R=>typeof R=="string"?R===z:R.label===z);V?_([...w,z]):(B&&typeof B=="object"&&B.textField&&B.textField.name&&O(B.textField.name,""),_(w.filter(R=>R!=z)))},fullWidth:!0,margin:y,error:!!E,children:[v.jsx(F.FormLabel,{focused:t.focused,htmlFor:e,required:s,disabled:t.disableLabel,children:r}),M(),$,v.jsx(Xn,{name:e,id:`${e}-err`})]})},hC=ze(v.jsx("path",{d:"M19.35 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.6 5.64 5.35 8.04 2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96M14 13v4h-4v-4H7l5-5 5 5z"}),"CloudUpload"),gC=t=>{const{name:e,multiple:n=!1,readOnly:r=!1,variant:o=n?"drag-and-drop":"button",duplicateFilesCallback:i,incorrectFileTypesCallback:s,staticLabelProps:a={fontSize:".9em",color:"#808080"}}=t,[l,u,f]=jt.useField({name:e}),{setValue:p}=f,g=l.value,m=t.fileType?Array.isArray(t.fileType)?t.fileType:[t.fileType]:[],y=t.subtitle??(m.length>0?`Allowed file extensions: ${m.join(", ")}`:""),b=L=>{C(Array.from(L.target.files??[]))},S=L=>{L.preventDefault(),C(Array.from(L.dataTransfer.files))},C=L=>{if(L&&L.length>0){const P=g?Array.isArray(g)?g:[g]:[],$=Ku.partition(L,M=>P.find(A=>_(M,A)));if(L=$[1],i&&$[0].length>0&&i($[0]),m.length>0){const M=Ku.partition(L,A=>m.find(N=>A.name.endsWith(N)));L=M[0],s&&M[1].length>0&&s(M[1])}n?p([...T(),...L]):!Array.isArray(g)&&L.length>0&&p(L[0])}},T=()=>g?Array.isArray(g)?g:[g]:[],_=(L,P)=>L.lastModified===P.lastModified&&L.name===P.name&&L.type===P.type&&L.size===P.size,w=()=>T().map(L=>L.name).join(", ");return r?v.jsx(F.Typography,{"data-testid":"fileupload-readonly",...a,children:w()}):o==="drag-and-drop"?v.jsxs("div",{style:{border:`4px dashed ${u.error?"red":"lightgray"}`,padding:"30px 10px",display:"flex",alignItems:"center",flexDirection:"column"},onDrop:S,onDragOver:L=>L.preventDefault(),"data-testid":"dropzone",children:[v.jsx(hC,{color:"primary",sx:{fontSize:"40px"}}),v.jsxs("div",{style:{display:"flex",flexDirection:"row",alignItems:"baseline"},children:[v.jsx(F.Typography,{children:"Drag and drop or"}),v.jsxs(F.Button,{component:"label",role:void 0,variant:"text",tabIndex:-1,sx:{textTransform:"none",fontSize:"16px",textDecoration:"underline"},children:["browse",v.jsx("input",{"data-testid":"file-input",id:e,hidden:!0,type:"file",onChange:b,multiple:!0,accept:m==null?void 0:m.toString()})]})]}),y&&v.jsx(F.Typography,{variant:"caption",children:y}),v.jsx(Xn,{name:e,id:`${e}-err`})]}):v.jsxs("div",{style:{display:"flex",flexDirection:"column"},children:[v.jsx("div",{style:{display:"flex",alignItems:"center",marginBottom:"4px"},children:v.jsxs(F.Button,{component:"label",role:void 0,variant:"contained",tabIndex:-1,startIcon:v.jsx(hC,{}),children:["Upload a file",v.jsx("input",{"data-testid":"file-input",id:e,hidden:!0,type:"file",onChange:b,accept:m==null?void 0:m.toString()})]})}),v.jsx(Xn,{name:e,id:`${e}-err`})]})},NB=ze(v.jsx("path",{d:"M15 2H6c-1.1 0-2 .9-2 2v16c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V7zM6 20V4h8v4h4v12zm10-10v5c0 2.21-1.79 4-4 4s-4-1.79-4-4V8.5c0-1.47 1.26-2.64 2.76-2.49 1.3.13 2.24 1.32 2.24 2.63V15h-2V8.5c0-.28-.22-.5-.5-.5s-.5.22-.5.5V15c0 1.1.9 2 2 2s2-.9 2-2v-5z"}),"FilePresent"),qh=ze(v.jsx("path",{d:"M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6zM19 4h-3.5l-1-1h-5l-1 1H5v2h14z"}),"Delete"),LB=t=>{const{name:e}=t,[n,,r]=jt.useField({name:e}),{setValue:o}=r,i=n.value;return v.jsx("div",{style:{width:"100%"},children:i.map(s=>v.jsx(F.Card,{sx:{margin:"10px 0px"},children:v.jsxs(F.CardContent,{style:{display:"flex",alignItems:"center",padding:"8px 12px"},children:[v.jsx(NB,{sx:{color:"gray",fontSize:"20px"}}),v.jsx(F.Typography,{sx:{padding:"8px",overflowWrap:"anywhere"},children:s.name}),v.jsx(F.IconButton,{"aria-label":"remove file",onClick:()=>o(i.filter(a=>a!==s)),edge:"end",style:{marginLeft:"auto",order:"2"},children:v.jsx(qh,{})})]})},`${s.name}-${s.type}-${s.size}-${s.lastModified}`))})};var Uh,mC;function Uo(){if(mC)return Uh;mC=1;function t(e){var n=typeof e;return e!=null&&(n=="object"||n=="function")}return Uh=t,Uh}var Kh,yC;function bC(){if(yC)return Kh;yC=1;var t=typeof yi=="object"&&yi&&yi.Object===Object&&yi;return Kh=t,Kh}var Yh,vC;function oo(){if(vC)return Yh;vC=1;var t=bC(),e=typeof self=="object"&&self&&self.Object===Object&&self,n=t||e||Function("return this")();return Yh=n,Yh}var Gh,xC;function FB(){if(xC)return Gh;xC=1;var t=oo(),e=function(){return t.Date.now()};return Gh=e,Gh}var Jh,SC;function $B(){if(SC)return Jh;SC=1;var t=/\s/;function e(n){for(var r=n.length;r--&&t.test(n.charAt(r)););return r}return Jh=e,Jh}var Zh,CC;function BB(){if(CC)return Zh;CC=1;var t=$B(),e=/^\s+/;function n(r){return r&&r.slice(0,t(r)+1).replace(e,"")}return Zh=n,Zh}var Xh,wC;function Ll(){if(wC)return Xh;wC=1;var t=oo(),e=t.Symbol;return Xh=e,Xh}var Qh,_C;function RB(){if(_C)return Qh;_C=1;var t=Ll(),e=Object.prototype,n=e.hasOwnProperty,r=e.toString,o=t?t.toStringTag:void 0;function i(s){var a=n.call(s,o),l=s[o];try{s[o]=void 0;var u=!0}catch{}var f=r.call(s);return u&&(a?s[o]=l:delete s[o]),f}return Qh=i,Qh}var eg,TC;function zB(){if(TC)return eg;TC=1;var t=Object.prototype,e=t.toString;function n(r){return e.call(r)}return eg=n,eg}var tg,kC;function us(){if(kC)return tg;kC=1;var t=Ll(),e=RB(),n=zB(),r="[object Null]",o="[object Undefined]",i=t?t.toStringTag:void 0;function s(a){return a==null?a===void 0?o:r:i&&i in Object(a)?e(a):n(a)}return tg=s,tg}var ng,EC;function Ci(){if(EC)return ng;EC=1;function t(e){return e!=null&&typeof e=="object"}return ng=t,ng}var rg,MC;function Yu(){if(MC)return rg;MC=1;var t=us(),e=Ci(),n="[object Symbol]";function r(o){return typeof o=="symbol"||e(o)&&t(o)==n}return rg=r,rg}var og,OC;function AC(){if(OC)return og;OC=1;var t=BB(),e=Uo(),n=Yu(),r=NaN,o=/^[-+]0x[0-9a-f]+$/i,i=/^0b[01]+$/i,s=/^0o[0-7]+$/i,a=parseInt;function l(u){if(typeof u=="number")return u;if(n(u))return r;if(e(u)){var f=typeof u.valueOf=="function"?u.valueOf():u;u=e(f)?f+"":f}if(typeof u!="string")return u===0?u:+u;u=t(u);var p=i.test(u);return p||s.test(u)?a(u.slice(2),p?2:8):o.test(u)?r:+u}return og=l,og}var ig,IC;function DC(){if(IC)return ig;IC=1;var t=Uo(),e=FB(),n=AC(),r="Expected a function",o=Math.max,i=Math.min;function s(a,l,u){var f,p,g,m,y,b,S=0,C=!1,T=!1,_=!0;if(typeof a!="function")throw new TypeError(r);l=n(l)||0,t(u)&&(C=!!u.leading,T="maxWait"in u,g=T?o(n(u.maxWait)||0,l):g,_="trailing"in u?!!u.trailing:_);function w(z){var V=f,B=p;return f=p=void 0,S=z,m=a.apply(B,V),m}function E(z){return S=z,y=setTimeout(P,l),C?w(z):m}function O(z){var V=z-b,B=z-S,R=l-V;return T?i(R,g-B):R}function L(z){var V=z-b,B=z-S;return b===void 0||V>=l||V<0||T&&B>=g}function P(){var z=e();if(L(z))return $(z);y=setTimeout(P,O(z))}function $(z){return y=void 0,_&&f?w(z):(f=p=void 0,m)}function M(){y!==void 0&&clearTimeout(y),S=0,f=b=p=y=void 0}function A(){return y===void 0?m:$(e())}function N(){var z=e(),V=L(z);if(f=arguments,p=this,b=z,V){if(y===void 0)return E(b);if(T)return clearTimeout(y),y=setTimeout(P,l),w(b)}return y===void 0&&(y=setTimeout(P,l)),m}return N.cancel=M,N.flush=A,N}return ig=s,ig}var sg,PC;function VB(){if(PC)return sg;PC=1;var t=DC(),e=Uo(),n="Expected a function";function r(o,i,s){var a=!0,l=!0;if(typeof o!="function")throw new TypeError(n);return e(s)&&(a="leading"in s?!!s.leading:a,l="trailing"in s?!!s.trailing:l),t(o,i,{leading:a,maxWait:i,trailing:l})}return sg=r,sg}var HB=VB();const NC=Zn(HB),jB=ze(v.jsx("path",{d:"M12 2C8.13 2 5 5.13 5 9c0 5.25 7 13 7 13s7-7.75 7-13c0-3.87-3.13-7-7-7m0 9.5c-1.38 0-2.5-1.12-2.5-2.5s1.12-2.5 2.5-2.5 2.5 1.12 2.5 2.5-1.12 2.5-2.5 2.5"}),"LocationOn");var Gu={exports:{}},WB=Gu.exports,LC;function qB(){return LC||(LC=1,function(t,e){(function(n,r){t.exports=r()})(WB,()=>{return n={705:o=>{o.exports=function(i,s){const a=[];return s.length===0?a.push({text:i,highlight:!1}):s[0][0]>0&&a.push({text:i.slice(0,s[0][0]),highlight:!1}),s.forEach((l,u)=>{const f=l[0],p=l[1];a.push({text:i.slice(f,p),highlight:!0}),u===s.length-1?p<i.length&&a.push({text:i.slice(p,i.length),highlight:!1}):p<s[u+1][0]&&a.push({text:i.slice(p,s[u+1][0]),highlight:!1})}),a}}},r={},function o(i){var s=r[i];if(s!==void 0)return s.exports;var a=r[i]={exports:{}};return n[i](a,a.exports,o),a.exports}(705);var n,r})}(Gu)),Gu.exports}var UB=qB();const KB=Zn(UB),YB=t=>{const{listItemProps:e,option:n,resultIcon:r,highlightMatches:o}=t,{main_text:i,secondary_text:s,main_text_matched_substrings:a}=n.structured_formatting,l=KB(i,a.map(u=>[u.offset,u.offset+u.length]));return v.jsx("li",{...Jn({...e},["key"]),"data-testid":`loc-${n.place_id}`,children:v.jsxs(F.Box,{display:"flex",flexDirection:"row",alignItems:"center",children:[r?I.cloneElement(r):null,v.jsxs(F.Box,{children:[l.map(u=>{const f=o&&u.highlight?700:400;return v.jsx("span",{style:{fontWeight:f},children:u.text},`${n.place_id}_${u.text}`)}),v.jsx(F.Typography,{variant:"body2",color:"textSecondary",children:s})]})]})})};function GB(t,e,n){if(!e)return;const r=document.createElement("script");r.setAttribute("async",""),r.setAttribute("id",n),r.src=t,r.onerror=()=>console.error(`Failed to load script: ${t}`),e.appendChild(r)}const Fl={current:null},JB=t=>{const{name:e,label:n=_n(e),resultIcon:r=v.jsx(jB,{}),apiKey:o,highlightMatches:i=!0,types:s,variant:a="outlined",staticLabel:l=!1,staticLabelProps:u={fontSize:".9em",color:"#808080"},readOnly:f=!1,margin:p="dense"}=t,[g,m]=I.useState(null),[y,b]=I.useState(""),[S,C]=I.useState([]),T=I.useRef(!1),[,_,w]=jt.useField(e),{setValue:E}=w,{error:O}=_;typeof window<"u"&&!T.current&&(document.querySelector("#google-maps")||GB(`https://maps.googleapis.com/maps/api/js?key=${o}&libraries=places`,document.querySelector("head"),"google-maps"),T.current=!0);const L=I.useMemo(()=>NC((B,R)=>{Fl.current&&Fl.current.getPlacePredictions(B,R)},200),[]);I.useEffect(()=>{let B=!0;if(!Fl.current&&window.google&&(Fl.current=new window.google.maps.places.AutocompleteService),!Fl.current)return;if(y===""){C(g?[g]:[]);return}return L({input:y,types:s?[s]:[]},U=>{if(B){let G=[];g&&(G=[g]),U&&(G=[...G,...U]);const Y=G.filter((Z,fe,pe)=>fe===pe.findIndex(me=>me.place_id===Z.place_id));C(Y)}}),()=>{B=!1}},[g,y,L,s]);const P=I.useCallback(B=>{const q=(B?[B,...S]:S).filter((U,G,Y)=>G===Y.findIndex(Z=>Z.place_id===U.place_id));C(q),m(B),E(B?B.description:"")},[S,C,m,E]),$=B=>{b(B)},M=["name","apiKey","resultIcon","highlightMatches","variant","staticLabel","staticLabelProps","margin"],A=B=>v.jsx(F.TextField,{margin:p,variant:a,...B,...Jn({...t},M),label:l?void 0:n,hiddenLabel:l,error:!!O}),N=B=>typeof B=="string"?B:B.description,z=(B,R)=>v.jsx(YB,{listItemProps:B,option:R,resultIcon:r,highlightMatches:i},R.place_id);I.useEffect(()=>{const B=R=>{R.key==="Enter"&&S.length>0&&P(S[0])};return window.addEventListener("keydown",B),()=>{window.removeEventListener("keydown",B)}},[S,P]);const V=v.jsx(F.Autocomplete,{id:`${e}-loc`,"data-testid":"location-autocomplete",getOptionLabel:N,filterOptions:B=>B,options:S,autoComplete:!0,includeInputInList:!0,filterSelectedOptions:!0,value:g,onChange:(B,R)=>P(R),onInputChange:(B,R)=>$(R),disabled:t.disabled,renderOption:z,renderInput:A});return v.jsxs(F.FormControl,{margin:p,fullWidth:!0,children:[(l||f)&&v.jsx(F.Typography,{...u,children:n}),f?v.jsx(F.Typography,{children:g==null?void 0:g.description}):v.jsxs(F.Box,{children:[V,v.jsx(Xn,{name:e,id:`${e}-err`})]})]})},FC=t=>{const{name:e,radios:n=[],label:r=_n(e),labelPlacement:o="end",labelAlignment:i=o==="end"||o==="start"?"top":"center",required:s=!1,disabled:a=!1,readOnly:l=!1,margin:u="dense",onChange:f,staticLabelProps:p={fontSize:".9em",color:"#808080"}}=t;i==="top"&&(o==="bottom"||o==="top")&&console.error(`RadioGroup: Ignoring labelAlignment='top'. labelAlignment cannot be 'top' when labelPlacement=${o}`);const[g,m,y]=jt.useField({name:e}),{setValue:b}=y,{value:S}=g,{error:C}=m,T=["radioProps","labelPlacement"],_=["disableRedLabelOnError","disableLabel","sameButtonColor","labelPlacement","focused","margin","fullWidth","labelAlignment"],w=()=>t.labelPlacement=="start"?"right":t.labelPlacement=="top"||t.labelPlacement=="bottom"?"center":"left",E=n.map(($,M)=>{const A=i==="top"&&(o==="start"||o==="end"),N=$.sublabel?v.jsxs("div",{children:[v.jsx("p",{style:{margin:0},children:$.label}),v.jsx(F.Typography,{variant:"caption",style:{fontSize:"0.85rem"},children:$.sublabel})]}):$.label;return v.jsx(F.FormControlLabel,{sx:{alignItems:A?"flex-start":"center"},value:M.toString(),control:v.jsx(F.Radio,{id:`${$.value}-rb`,color:t.sameButtonColor?t.sameButtonColor:$.color??"default",...Jn({...$},T)}),label:v.jsx("div",{style:{marginTop:A?"10px":0},children:N}),labelPlacement:o,disabled:$.disabled||a,style:{textAlign:w()}},`rb-${M}-${r}`)}),O=()=>{const $=n.find(M=>M.value===g.value);return v.jsxs(F.Box,{children:[v.jsx(F.Typography,{...p,children:r}),L($)]})},L=$=>v.jsxs(F.Box,{children:[v.jsx(F.Typography,{children:$==null?void 0:$.label}),($==null?void 0:$.sublabel)&&v.jsx(F.Typography,{variant:"caption",style:{fontSize:"0.85rem"},children:$.sublabel})]}),P=$=>{b($.target.value),f&&f($.target.value)};return l?O():v.jsxs(F.FormControl,{focused:t.focused,margin:u,fullWidth:t.fullWidth,error:!!C,children:[v.jsx(F.FormLabel,{htmlFor:e,required:s,disabled:t.disableLabel,children:r}),v.jsx(F.RadioGroup,{id:e,value:S??"",...Jn({...t},_),onChange:P,children:E}),v.jsx(Xn,{name:e,id:`${e}-err`})]})},ZB=t=>{const{name:e,label:n=_n(e),min:r=0,max:o=100,step:i=1,readOnly:s,staticLabelProps:a={fontSize:".9em",color:"#808080"}}=t,l=jt.useField(e),{value:u}=l[0],{setValue:f}=l[2],p=["label"];return s?(()=>{let m;return Array.isArray(u)?m=s==="percent"?`${100*(u[0]??0)/o}% - ${100*(u[1]??0)/o}%`:`${u[0]??0} - ${u[1]??0}`:m=s==="percent"?`${100*(u??0)/o}%`:`${u??0}`,v.jsxs(F.Box,{children:[v.jsx(F.Typography,{...a,children:n}),v.jsx(F.Typography,{children:m})]})})():v.jsxs(F.FormControl,{fullWidth:!0,children:[v.jsx(F.Typography,{gutterBottom:!0,color:"textSecondary",children:n}),v.jsx(F.Slider,{...Jn({...t},p),id:t.name,value:u??0,onChange:(m,y)=>{f(y)},min:r,max:o,step:i})]})},XB=t=>{const{name:e,options:n=[],label:r=_n(e),selectedOptionIcon:o=void 0,staticLabel:i=!1,staticLabelProps:s={fontSize:".9em",color:"#808080"},variant:a="outlined",readOnly:l=!1,margin:u="dense",required:f}=t,[p,g,m]=jt.useField({name:e}),{setValue:y}=m,{value:b}=p,{error:S}=g,C=I.useCallback(()=>{let A="";for(let N=0;N<n.length;N++)JSON.stringify(n[N].value)===JSON.stringify(b)&&(A=N.toString());return A},[n,b]),T=I.useCallback(()=>{const A=[],N=b.toString().split(",");for(const z of N)for(let V=0;V<n.length;V++)n[V].value===z&&A.push(V);return A},[n,b]);I.useEffect(()=>{E(t.multiple?T():C())},[n,t.multiple,b,T,C]);const _=(A,N)=>t.multiple?!!b.toString().split(",").find(z=>z===JSON.stringify(A.value)):N===n.findIndex(z=>b===z.value),[w,E]=I.useState(t.multiple?T:C),O=n.map((A,N)=>{const z=o&&_(A,N)?o:void 0;return v.jsxs(F.MenuItem,{id:`select-${e}-option-${A.value}`,value:N,disabled:A.disabled,children:[o&&v.jsx(F.ListItemIcon,{children:z}),A.label]},N.toString())}),L=A=>{if(t.multiple){const N=[];A.target.value.forEach(z=>{n[z].value&&N.push(n[z].value)}),y(N.join(","))}else y(n[A.target.value].value);E(A.target.value)},P=["name","options",i?"label":"","required","selectedOptionIcon","variant","staticLabel","staticLabelProps"],$=()=>FF(n,b,t.multiple),M=t.renderValue??$;return v.jsxs(F.FormControl,{fullWidth:!0,variant:a,error:!!S,margin:u,required:f,children:[i||l?v.jsx(F.Typography,{...s,children:r}):v.jsx(F.InputLabel,{id:`${e}-select-label`,children:r}),l?v.jsx(F.Typography,{children:$()}):v.jsxs(F.Box,{children:[v.jsx(F.Select,{id:`${e}-sel`,labelId:`${e}-select-label`,label:i?void 0:r,...Jn({...t},P),name:e,value:w,fullWidth:!0,onChange:A=>L(A),displayEmpty:i,renderValue:M,children:O}),v.jsx(Xn,{name:e,id:`${e}-err`})]})]})},QB=t=>{const{name:e,label:n=_n(e),labelPlacement:r="end",readOnly:o,staticLabelProps:i={fontSize:".9em",color:"#808080"},onChange:s,color:a="primary",chipColor:l,activeValue:u=!0,inactiveValue:f=!1}=t,[p,,g]=jt.useField({name:e}),{setValue:m}=g,{value:y}=p;y===void 0&&console.error(`Please set an initial value for ${e}`);const b=["labelPlacement","chipColor","activeValue","inactiveValue"],S=C=>{if(typeof C!="boolean")return String(C);switch(o){case"YES_NO":return C===u?"Yes":"No";case"ON_OFF":return C===u?"On":"Off";default:return C===u?"True":"False"}};return o?v.jsxs(F.Box,{children:[v.jsx(F.Typography,{...i,children:n}),v.jsx(F.Typography,{children:S(y)})]}):v.jsxs(F.Box,{bgcolor:l??"inherit",sx:l?{display:"inline-flex",justifyContent:"center",alignItems:"center",borderRadius:"32px",padding:"2px 0px 2px 12px"}:{},children:[v.jsx(F.FormControlLabel,{label:n,sx:{"& .MuiFormControlLabel-label":{color:a}},labelPlacement:r,control:v.jsx(F.Switch,{...Jn({...t},b),id:e,...p,onChange:C=>{if(typeof u=="string"&&typeof f=="string"){const T=C.target.checked?u:f;m(T),s&&s(T)}else m(C.target.checked),s&&s(C.target.checked)},checked:y===u})}),v.jsx(Xn,{name:e,id:`${e}-err`})]})},eR=ze([v.jsx("path",{d:"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2M12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8"},"0"),v.jsx("path",{d:"M12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z"},"1")],"AccessTime"),tR=ze(v.jsx("path",{d:"M13 7h-2v4H7v2h4v4h2v-4h4v-2h-4zm-1-5C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8"}),"AddCircleOutline"),nR=ze(v.jsx("path",{d:"M19 7v2.99s-1.99.01-2 0V7h-3s.01-1.99 0-2h3V2h2v3h3v2zm-3 4V8h-3V5H5c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2v-8zM5 19l3-4 2 3 3-4 4 5z"}),"AddPhotoAlternate"),rR=ze(v.jsx("path",{d:"m19 18 2 1V3c0-1.1-.9-2-2-2H8.99C7.89 1 7 1.9 7 3h10c1.1 0 2 .9 2 2zM15 5H5c-1.1 0-2 .9-2 2v16l7-3 7 3V7c0-1.1-.9-2-2-2"}),"Bookmarks"),oR=ze(v.jsx("path",{d:"M9 16.17 4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"}),"Check"),iR=ze(v.jsx("path",{d:"M22 7h-9v2h9zm0 8h-9v2h9zM5.54 11 2 7.46l1.41-1.41 2.12 2.12 4.24-4.24 1.41 1.41zm0 8L2 15.46l1.41-1.41 2.12 2.12 4.24-4.24 1.41 1.41z"}),"Checklist"),sR=ze(v.jsx("path",{d:"M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}),"Close"),aR=ze(v.jsx("path",{d:"M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}),"CloseOutlined"),lR=ze(v.jsx("path",{d:"M9.4 16.6 4.8 12l4.6-4.6L8 6l-6 6 6 6zm5.2 0 4.6-4.6-4.6-4.6L16 6l6 6-6 6z"}),"Code"),$C=ze(v.jsx("path",{d:"M12 3c-4.97 0-9 4.03-9 9s4.03 9 9 9 9-4.03 9-9c0-.46-.04-.92-.1-1.36-.98 1.37-2.58 2.26-4.4 2.26-2.98 0-5.4-2.42-5.4-5.4 0-1.81.89-3.42 2.26-4.4-.44-.06-.9-.1-1.36-.1"}),"DarkMode"),BC=ze(v.jsx("path",{d:"M14 2H6c-1.1 0-1.99.9-1.99 2L4 20c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8zm2 16H8v-2h8zm0-4H8v-2h8zm-3-5V3.5L18.5 9z"}),"Description"),cR=ze(v.jsx("path",{d:"M5 20h14v-2H5zM19 9h-4V3H9v6H5l7 7z"}),"Download"),uR=ze(v.jsx("path",{d:"M3 17.25V21h3.75L17.81 9.94l-3.75-3.75zM20.71 7.04c.39-.39.39-1.02 0-1.41l-2.34-2.34a.996.996 0 0 0-1.41 0l-1.83 1.83 3.75 3.75z"}),"Edit"),dR=ze(v.jsx("path",{d:"M7 15v2h10v-2zm-4 6h18v-2H3zm0-8h18v-2H3zm4-6v2h10V7zM3 3v2h18V3z"}),"FormatAlignCenter"),fR=ze(v.jsx("path",{d:"M3 21h18v-2H3zm0-4h18v-2H3zm0-4h18v-2H3zm0-4h18V7H3zm0-6v2h18V3z"}),"FormatAlignJustify"),pR=ze(v.jsx("path",{d:"M15 15H3v2h12zm0-8H3v2h12zM3 13h18v-2H3zm0 8h18v-2H3zM3 3v2h18V3z"}),"FormatAlignLeft"),hR=ze(v.jsx("path",{d:"M3 21h18v-2H3zm6-4h12v-2H9zm-6-4h18v-2H3zm6-4h12V7H9zM3 3v2h18V3z"}),"FormatAlignRight"),gR=ze(v.jsx("path",{d:"M15.6 10.79c.97-.67 1.65-1.77 1.65-2.79 0-2.26-1.75-4-4-4H7v14h7.04c2.09 0 3.71-1.7 3.71-3.79 0-1.52-.86-2.82-2.15-3.42M10 6.5h3c.83 0 1.5.67 1.5 1.5s-.67 1.5-1.5 1.5h-3zm3.5 9H10v-3h3.5c.83 0 1.5.67 1.5 1.5s-.67 1.5-1.5 1.5"}),"FormatBold"),mR=ze(v.jsx("path",{d:"M3.27 5 2 6.27l6.97 6.97L6.5 19h3l1.57-3.66L16.73 21 18 19.73 3.55 5.27zM6 5v.18L8.82 8h2.4l-.72 1.68 2.1 2.1L14.21 8H20V5z"}),"FormatClear"),yR=ze(v.jsx("path",{d:"M16.56 8.94 7.62 0 6.21 1.41l2.38 2.38-5.15 5.15c-.59.59-.59 1.54 0 2.12l5.5 5.5c.29.29.68.44 1.06.44s.77-.15 1.06-.44l5.5-5.5c.59-.58.59-1.53 0-2.12M5.21 10 10 5.21 14.79 10zM19 11.5s-2 2.17-2 3.5c0 1.1.9 2 2 2s2-.9 2-2c0-1.33-2-3.5-2-3.5M2 20h20v4H2z"}),"FormatColorFill"),bR=ze(v.jsx("path",{d:"M11 17h10v-2H11zm-8-5 4 4V8zm0 9h18v-2H3zM3 3v2h18V3zm8 6h10V7H11zm0 4h10v-2H11z"}),"FormatIndentDecrease"),vR=ze(v.jsx("path",{d:"M3 21h18v-2H3zM3 8v8l4-4zm8 9h10v-2H11zM3 3v2h18V3zm8 6h10V7H11zm0 4h10v-2H11z"}),"FormatIndentIncrease"),xR=ze(v.jsx("path",{d:"M10 4v3h2.21l-3.42 8H6v3h8v-3h-2.21l3.42-8H18V4z"}),"FormatItalic"),SR=ze(v.jsx("path",{d:"M4 10.5c-.83 0-1.5.67-1.5 1.5s.67 1.5 1.5 1.5 1.5-.67 1.5-1.5-.67-1.5-1.5-1.5m0-6c-.83 0-1.5.67-1.5 1.5S3.17 7.5 4 7.5 5.5 6.83 5.5 6 4.83 4.5 4 4.5m0 12c-.83 0-1.5.68-1.5 1.5s.68 1.5 1.5 1.5 1.5-.68 1.5-1.5-.67-1.5-1.5-1.5M7 19h14v-2H7zm0-6h14v-2H7zm0-8v2h14V5z"}),"FormatListBulleted"),CR=ze(v.jsx("path",{d:"M2 17h2v.5H3v1h1v.5H2v1h3v-4H2zm1-9h1V4H2v1h1zm-1 3h1.8L2 13.1v.9h3v-1H3.2L5 10.9V10H2zm5-6v2h14V5zm0 14h14v-2H7zm0-6h14v-2H7z"}),"FormatListNumbered"),wR=ze(v.jsx("path",{d:"M6 17h3l2-4V7H5v6h3zm8 0h3l2-4V7h-6v6h3z"}),"FormatQuote"),_R=ze(v.jsx("path",{d:"M9 4v3h5v12h3V7h5V4zm-6 8h3v7h3v-7h3V9H3z"}),"FormatSize"),TR=ze(v.jsx("path",{d:"M12 17c3.31 0 6-2.69 6-6V3h-2.5v8c0 1.93-1.57 3.5-3.5 3.5S8.5 12.93 8.5 11V3H6v8c0 3.31 2.69 6 6 6m-7 2v2h14v-2z"}),"FormatUnderlined"),kR=ze(v.jsx("path",{d:"M8 4v1.45l2 2V4h4v4h-3.45l2 2H14v1.45l2 2V10h4v4h-3.45l2 2H20v1.45l2 2V4c0-1.1-.9-2-2-2H4.55l2 2zm8 0h4v4h-4zM1.27 1.27 0 2.55l2 2V20c0 1.1.9 2 2 2h15.46l2 2 1.27-1.27zM10 12.55 11.45 14H10zm-6-6L5.45 8H4zM8 20H4v-4h4zm0-6H4v-4h3.45l.55.55zm6 6h-4v-4h3.45l.55.54zm2 0v-1.46L17.46 20z"}),"GridOff"),ER=ze(v.jsx("path",{fillRule:"evenodd",d:"M4 11h16v2H4z"}),"HorizontalRule"),MR=ze(v.jsx("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m1 15h-2v-6h2zm0-8h-2V7h2z"}),"Info"),OR=ze(v.jsx("path",{d:"M7.41 8.59 12 13.17l4.59-4.58L18 10l-6 6-6-6z"}),"KeyboardArrowDown"),RC=ze(v.jsx("path",{d:"M7.41 15.41 12 10.83l4.59 4.58L18 14l-6-6-6 6z"}),"KeyboardArrowUp"),zC=ze(v.jsx("path",{d:"M12 7c-2.76 0-5 2.24-5 5s2.24 5 5 5 5-2.24 5-5-2.24-5-5-5M2 13h2c.55 0 1-.45 1-1s-.45-1-1-1H2c-.55 0-1 .45-1 1s.45 1 1 1m18 0h2c.55 0 1-.45 1-1s-.45-1-1-1h-2c-.55 0-1 .45-1 1s.45 1 1 1M11 2v2c0 .55.45 1 1 1s1-.45 1-1V2c0-.55-.45-1-1-1s-1 .45-1 1m0 18v2c0 .55.45 1 1 1s1-.45 1-1v-2c0-.55-.45-1-1-1s-1 .45-1 1M5.99 4.58c-.39-.39-1.03-.39-1.41 0-.39.39-.39 1.03 0 1.41l1.06 1.06c.39.39 1.03.39 1.41 0s.39-1.03 0-1.41zm12.37 12.37c-.39-.39-1.03-.39-1.41 0-.39.39-.39 1.03 0 1.41l1.06 1.06c.39.39 1.03.39 1.41 0 .39-.39.39-1.03 0-1.41zm1.06-10.96c.39-.39.39-1.03 0-1.41-.39-.39-1.03-.39-1.41 0l-1.06 1.06c-.39.39-.39 1.03 0 1.41s1.03.39 1.41 0zM7.05 18.36c.39-.39.39-1.03 0-1.41-.39-.39-1.03-.39-1.41 0l-1.06 1.06c-.39.39-.39 1.03 0 1.41s1.03.39 1.41 0z"}),"LightMode"),Ju=ze(v.jsx("path",{d:"M3.9 12c0-1.71 1.39-3.1 3.1-3.1h4V7H7c-2.76 0-5 2.24-5 5s2.24 5 5 5h4v-1.9H7c-1.71 0-3.1-1.39-3.1-3.1M8 13h8v-2H8zm9-6h-4v1.9h4c1.71 0 3.1 1.39 3.1 3.1s-1.39 3.1-3.1 3.1h-4V17h4c2.76 0 5-2.24 5-5s-2.24-5-5-5"}),"Link"),AR=ze(v.jsx("path",{d:"m17 7-1.41 1.41L18.17 11H8v2h10.17l-2.58 2.58L17 17l5-5zM4 5h8V3H4c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h8v-2H4z"}),"Logout"),IR=ze(v.jsx("path",{d:"M3 18h18v-2H3zm0-5h18v-2H3zm0-7v2h18V6z"}),"Menu"),DR=ze(v.jsx("path",{d:"M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"}),"NavigateNext"),PR=ze(v.jsx("path",{d:"M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4m0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4"}),"Person"),NR=ze(v.jsx("path",{d:"M18.4 10.6C16.55 8.99 14.15 8 11.5 8c-4.65 0-8.58 3.03-9.96 7.22L3.9 16c1.05-3.19 4.05-5.5 7.6-5.5 1.95 0 3.73.72 5.12 1.88L13 16h9V7z"}),"Redo"),LR=ze(v.jsx("path",{d:"M19 13H5v-2h14z"}),"Remove"),FR=ze(v.jsx("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m5 11H7v-2h10z"}),"RemoveCircle"),$R=ze(v.jsx("path",{d:"M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14"}),"SearchOutlined"),BR=ze(v.jsx("path",{d:"M3 18h6v-2H3zM3 6v2h18V6zm0 7h12v-2H3z"}),"Sort"),RR=ze(v.jsx("path",{d:"M6.85 7.08C6.85 4.37 9.45 3 12.24 3c1.64 0 3 .49 3.9 1.28.77.65 1.46 1.73 1.46 3.24h-3.01c0-.31-.05-.59-.15-.85-.29-.86-1.2-1.28-2.25-1.28-1.86 0-2.34 1.02-2.34 1.7 0 .48.25.88.74 1.21.38.25.77.48 1.41.7H7.39c-.21-.34-.54-.89-.54-1.92M21 12v-2H3v2h9.62c1.15.45 1.96.75 1.96 1.97 0 1-.81 1.67-2.28 1.67-1.54 0-2.93-.54-2.93-2.51H6.4c0 .55.08 1.13.24 1.58.81 2.29 3.29 3.3 5.67 3.3 2.27 0 5.3-.89 5.3-4.05 0-.3-.01-1.16-.48-1.94H21z"}),"StrikethroughS"),zR=ze(v.jsx("path",{d:"M22 18h-2v1h3v1h-4v-2c0-.55.45-1 1-1h2v-1h-3v-1h3c.55 0 1 .45 1 1v1c0 .55-.45 1-1 1M5.88 18h2.66l3.4-5.42h.12l3.4 5.42h2.66l-4.65-7.27L17.81 4h-2.68l-3.07 4.99h-.12L8.85 4H6.19l4.32 6.73z"}),"Subscript"),VR=ze(v.jsx("path",{d:"M22 7h-2v1h3v1h-4V7c0-.55.45-1 1-1h2V5h-3V4h3c.55 0 1 .45 1 1v1c0 .55-.45 1-1 1M5.88 20h2.66l3.4-5.42h.12l3.4 5.42h2.66l-4.65-7.27L17.81 6h-2.68l-3.07 4.99h-.12L8.85 6H6.19l4.32 6.73z"}),"Superscript"),HR=ze(v.jsx("path",{d:"M12.5 8c-2.65 0-5.05.99-6.9 2.6L2 7v9h9l-3.62-3.62c1.39-1.16 3.16-1.88 5.12-1.88 3.54 0 6.55 2.31 7.6 5.5l2.37-.78C21.08 11.03 17.15 8 12.5 8"}),"Undo"),jR=t=>{const{onSearch:e,initialValue:n="",lazySearch:r=!1}=t,[o,i]=J.useState(n),s=f=>{i(f.target.value),r||e(f.target.value)},a=f=>{f.key==="Enter"&&l()},l=()=>{e(o)},u=()=>{i(""),e("")};return v.jsx(F.TextField,{type:"text",placeholder:"Search...",value:o,onChange:s,onKeyDown:a,className:"search-bar",size:"small",fullWidth:!0,slotProps:{input:{startAdornment:v.jsx(F.InputAdornment,{position:"start",children:v.jsx(F.IconButton,{"data-testid":"search-button",style:{marginLeft:-10},onClick:l,children:v.jsx($R,{})})}),endAdornment:o&&v.jsx(F.IconButton,{style:{marginRight:-10},"aria-label":"clear search","data-testid":"clear-search",onClick:u,children:v.jsx(aR,{})})}}})};function ne(){return ne=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)({}).hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},ne.apply(null,arguments)}function rt(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.includes(r))continue;n[r]=t[r]}return n}function Wt({props:t,name:e}){return E5({props:t,name:e,defaultTheme:qu,themeId:Pl})}const WR=["localeText"],Zu=I.createContext(null);process.env.NODE_ENV!=="production"&&(Zu.displayName="MuiPickersAdapterContext");const ag=function(e){const{localeText:n}=e,r=rt(e,WR),{utils:o,localeText:i}=I.useContext(Zu)??{utils:void 0,localeText:void 0},s=Wt({props:r,name:"MuiLocalizationProvider"}),{children:a,dateAdapter:l,dateFormats:u,dateLibInstance:f,adapterLocale:p,localeText:g}=s,m=I.useMemo(()=>ne({},g,i,n),[g,i,n]),y=I.useMemo(()=>{if(!l)return o||null;const C=new l({locale:p,formats:u,instance:f});if(!C.isMUIAdapter)throw new Error(["MUI X: The date adapter should be imported from `@mui/x-date-pickers` or `@mui/x-date-pickers-pro`, not from `@date-io`","For example, `import { AdapterDayjs } from '@mui/x-date-pickers/AdapterDayjs'` instead of `import AdapterDayjs from '@date-io/dayjs'`","More information on the installation documentation: https://mui.com/x/react-date-pickers/getting-started/#installation"].join(`
|
|
106
|
+
`));return C},[l,p,u,f,o]),b=I.useMemo(()=>y?{minDate:y.date("1900-01-01T00:00:00.000"),maxDate:y.date("2099-12-31T00:00:00.000")}:null,[y]),S=I.useMemo(()=>({utils:y,defaultDates:b,localeText:m}),[b,y,m]);return v.jsx(Zu.Provider,{value:S,children:a})};process.env.NODE_ENV!=="production"&&(ag.propTypes={adapterLocale:c.any,children:c.node,dateAdapter:c.func,dateFormats:c.shape({dayOfMonth:c.string,dayOfMonthFull:c.string,fullDate:c.string,fullTime:c.string,fullTime12h:c.string,fullTime24h:c.string,hours12h:c.string,hours24h:c.string,keyboardDate:c.string,keyboardDateTime:c.string,keyboardDateTime12h:c.string,keyboardDateTime24h:c.string,meridiem:c.string,minutes:c.string,month:c.string,monthShort:c.string,normalDate:c.string,normalDateWithWeekday:c.string,seconds:c.string,shortDate:c.string,weekday:c.string,weekdayShort:c.string,year:c.string}),dateLibInstance:c.any,localeText:c.object});var Xu={exports:{}},qR=Xu.exports,VC;function UR(){return VC||(VC=1,function(t,e){(function(n,r){t.exports=r()})(qR,function(){var n=1e3,r=6e4,o=36e5,i="millisecond",s="second",a="minute",l="hour",u="day",f="week",p="month",g="quarter",m="year",y="date",b="Invalid Date",S=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,C=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,T={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(V){var B=["th","st","nd","rd"],R=V%100;return"["+V+(B[(R-20)%10]||B[R]||B[0])+"]"}},_=function(V,B,R){var q=String(V);return!q||q.length>=B?V:""+Array(B+1-q.length).join(R)+V},w={s:_,z:function(V){var B=-V.utcOffset(),R=Math.abs(B),q=Math.floor(R/60),U=R%60;return(B<=0?"+":"-")+_(q,2,"0")+":"+_(U,2,"0")},m:function V(B,R){if(B.date()<R.date())return-V(R,B);var q=12*(R.year()-B.year())+(R.month()-B.month()),U=B.clone().add(q,p),G=R-U<0,Y=B.clone().add(q+(G?-1:1),p);return+(-(q+(R-U)/(G?U-Y:Y-U))||0)},a:function(V){return V<0?Math.ceil(V)||0:Math.floor(V)},p:function(V){return{M:p,y:m,w:f,d:u,D:y,h:l,m:a,s,ms:i,Q:g}[V]||String(V||"").toLowerCase().replace(/s$/,"")},u:function(V){return V===void 0}},E="en",O={};O[E]=T;var L="$isDayjsObject",P=function(V){return V instanceof N||!(!V||!V[L])},$=function V(B,R,q){var U;if(!B)return E;if(typeof B=="string"){var G=B.toLowerCase();O[G]&&(U=G),R&&(O[G]=R,U=G);var Y=B.split("-");if(!U&&Y.length>1)return V(Y[0])}else{var Z=B.name;O[Z]=B,U=Z}return!q&&U&&(E=U),U||!q&&E},M=function(V,B){if(P(V))return V.clone();var R=typeof B=="object"?B:{};return R.date=V,R.args=arguments,new N(R)},A=w;A.l=$,A.i=P,A.w=function(V,B){return M(V,{locale:B.$L,utc:B.$u,x:B.$x,$offset:B.$offset})};var N=function(){function V(R){this.$L=$(R.locale,null,!0),this.parse(R),this.$x=this.$x||R.x||{},this[L]=!0}var B=V.prototype;return B.parse=function(R){this.$d=function(q){var U=q.date,G=q.utc;if(U===null)return new Date(NaN);if(A.u(U))return new Date;if(U instanceof Date)return new Date(U);if(typeof U=="string"&&!/Z$/i.test(U)){var Y=U.match(S);if(Y){var Z=Y[2]-1||0,fe=(Y[7]||"0").substring(0,3);return G?new Date(Date.UTC(Y[1],Z,Y[3]||1,Y[4]||0,Y[5]||0,Y[6]||0,fe)):new Date(Y[1],Z,Y[3]||1,Y[4]||0,Y[5]||0,Y[6]||0,fe)}}return new Date(U)}(R),this.init()},B.init=function(){var R=this.$d;this.$y=R.getFullYear(),this.$M=R.getMonth(),this.$D=R.getDate(),this.$W=R.getDay(),this.$H=R.getHours(),this.$m=R.getMinutes(),this.$s=R.getSeconds(),this.$ms=R.getMilliseconds()},B.$utils=function(){return A},B.isValid=function(){return this.$d.toString()!==b},B.isSame=function(R,q){var U=M(R);return this.startOf(q)<=U&&U<=this.endOf(q)},B.isAfter=function(R,q){return M(R)<this.startOf(q)},B.isBefore=function(R,q){return this.endOf(q)<M(R)},B.$g=function(R,q,U){return A.u(R)?this[q]:this.set(U,R)},B.unix=function(){return Math.floor(this.valueOf()/1e3)},B.valueOf=function(){return this.$d.getTime()},B.startOf=function(R,q){var U=this,G=!!A.u(q)||q,Y=A.p(R),Z=function(W,ee){var ce=A.w(U.$u?Date.UTC(U.$y,ee,W):new Date(U.$y,ee,W),U);return G?ce:ce.endOf(u)},fe=function(W,ee){return A.w(U.toDate()[W].apply(U.toDate("s"),(G?[0,0,0,0]:[23,59,59,999]).slice(ee)),U)},pe=this.$W,me=this.$M,re=this.$D,he="set"+(this.$u?"UTC":"");switch(Y){case m:return G?Z(1,0):Z(31,11);case p:return G?Z(1,me):Z(0,me+1);case f:var le=this.$locale().weekStart||0,X=(pe<le?pe+7:pe)-le;return Z(G?re-X:re+(6-X),me);case u:case y:return fe(he+"Hours",0);case l:return fe(he+"Minutes",1);case a:return fe(he+"Seconds",2);case s:return fe(he+"Milliseconds",3);default:return this.clone()}},B.endOf=function(R){return this.startOf(R,!1)},B.$set=function(R,q){var U,G=A.p(R),Y="set"+(this.$u?"UTC":""),Z=(U={},U[u]=Y+"Date",U[y]=Y+"Date",U[p]=Y+"Month",U[m]=Y+"FullYear",U[l]=Y+"Hours",U[a]=Y+"Minutes",U[s]=Y+"Seconds",U[i]=Y+"Milliseconds",U)[G],fe=G===u?this.$D+(q-this.$W):q;if(G===p||G===m){var pe=this.clone().set(y,1);pe.$d[Z](fe),pe.init(),this.$d=pe.set(y,Math.min(this.$D,pe.daysInMonth())).$d}else Z&&this.$d[Z](fe);return this.init(),this},B.set=function(R,q){return this.clone().$set(R,q)},B.get=function(R){return this[A.p(R)]()},B.add=function(R,q){var U,G=this;R=Number(R);var Y=A.p(q),Z=function(me){var re=M(G);return A.w(re.date(re.date()+Math.round(me*R)),G)};if(Y===p)return this.set(p,this.$M+R);if(Y===m)return this.set(m,this.$y+R);if(Y===u)return Z(1);if(Y===f)return Z(7);var fe=(U={},U[a]=r,U[l]=o,U[s]=n,U)[Y]||1,pe=this.$d.getTime()+R*fe;return A.w(pe,this)},B.subtract=function(R,q){return this.add(-1*R,q)},B.format=function(R){var q=this,U=this.$locale();if(!this.isValid())return U.invalidDate||b;var G=R||"YYYY-MM-DDTHH:mm:ssZ",Y=A.z(this),Z=this.$H,fe=this.$m,pe=this.$M,me=U.weekdays,re=U.months,he=U.meridiem,le=function(ee,ce,te,se){return ee&&(ee[ce]||ee(q,G))||te[ce].slice(0,se)},X=function(ee){return A.s(Z%12||12,ee,"0")},W=he||function(ee,ce,te){var se=ee<12?"AM":"PM";return te?se.toLowerCase():se};return G.replace(C,function(ee,ce){return ce||function(te){switch(te){case"YY":return String(q.$y).slice(-2);case"YYYY":return A.s(q.$y,4,"0");case"M":return pe+1;case"MM":return A.s(pe+1,2,"0");case"MMM":return le(U.monthsShort,pe,re,3);case"MMMM":return le(re,pe);case"D":return q.$D;case"DD":return A.s(q.$D,2,"0");case"d":return String(q.$W);case"dd":return le(U.weekdaysMin,q.$W,me,2);case"ddd":return le(U.weekdaysShort,q.$W,me,3);case"dddd":return me[q.$W];case"H":return String(Z);case"HH":return A.s(Z,2,"0");case"h":return X(1);case"hh":return X(2);case"a":return W(Z,fe,!0);case"A":return W(Z,fe,!1);case"m":return String(fe);case"mm":return A.s(fe,2,"0");case"s":return String(q.$s);case"ss":return A.s(q.$s,2,"0");case"SSS":return A.s(q.$ms,3,"0");case"Z":return Y}return null}(ee)||Y.replace(":","")})},B.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},B.diff=function(R,q,U){var G,Y=this,Z=A.p(q),fe=M(R),pe=(fe.utcOffset()-this.utcOffset())*r,me=this-fe,re=function(){return A.m(Y,fe)};switch(Z){case m:G=re()/12;break;case p:G=re();break;case g:G=re()/3;break;case f:G=(me-pe)/6048e5;break;case u:G=(me-pe)/864e5;break;case l:G=me/o;break;case a:G=me/r;break;case s:G=me/n;break;default:G=me}return U?G:A.a(G)},B.daysInMonth=function(){return this.endOf(p).$D},B.$locale=function(){return O[this.$L]},B.locale=function(R,q){if(!R)return this.$L;var U=this.clone(),G=$(R,q,!0);return G&&(U.$L=G),U},B.clone=function(){return A.w(this.$d,this)},B.toDate=function(){return new Date(this.valueOf())},B.toJSON=function(){return this.isValid()?this.toISOString():null},B.toISOString=function(){return this.$d.toISOString()},B.toString=function(){return this.$d.toUTCString()},V}(),z=N.prototype;return M.prototype=z,[["$ms",i],["$s",s],["$m",a],["$H",l],["$W",u],["$M",p],["$y",m],["$D",y]].forEach(function(V){z[V[1]]=function(B){return this.$g(B,V[0],V[1])}}),M.extend=function(V,B){return V.$i||(V(B,N,M),V.$i=!0),M},M.locale=$,M.isDayjs=P,M.unix=function(V){return M(1e3*V)},M.en=O[E],M.Ls=O,M.p={},M})}(Xu)),Xu.exports}var KR=UR();const pn=Zn(KR);var Qu={exports:{}},YR=Qu.exports,HC;function GR(){return HC||(HC=1,function(t,e){(function(n,r){t.exports=r()})(YR,function(){var n="week",r="year";return function(o,i,s){var a=i.prototype;a.week=function(l){if(l===void 0&&(l=null),l!==null)return this.add(7*(l-this.week()),"day");var u=this.$locale().yearStart||1;if(this.month()===11&&this.date()>25){var f=s(this).startOf(r).add(1,r).date(u),p=s(this).endOf(n);if(f.isBefore(p))return 1}var g=s(this).startOf(r).date(u).startOf(n).subtract(1,"millisecond"),m=this.diff(g,n,!0);return m<0?s(this).startOf("week").week():Math.ceil(m)},a.weeks=function(l){return l===void 0&&(l=null),this.week(l)}}})}(Qu)),Qu.exports}var JR=GR();const ZR=Zn(JR);var ed={exports:{}},XR=ed.exports,jC;function QR(){return jC||(jC=1,function(t,e){(function(n,r){t.exports=r()})(XR,function(){var n={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},r=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|Q|YYYY|YY?|ww?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,o=/\d/,i=/\d\d/,s=/\d\d?/,a=/\d*[^-_:/,()\s\d]+/,l={},u=function(S){return(S=+S)+(S>68?1900:2e3)},f=function(S){return function(C){this[S]=+C}},p=[/[+-]\d\d:?(\d\d)?|Z/,function(S){(this.zone||(this.zone={})).offset=function(C){if(!C||C==="Z")return 0;var T=C.match(/([+-]|\d\d)/g),_=60*T[1]+(+T[2]||0);return _===0?0:T[0]==="+"?-_:_}(S)}],g=function(S){var C=l[S];return C&&(C.indexOf?C:C.s.concat(C.f))},m=function(S,C){var T,_=l.meridiem;if(_){for(var w=1;w<=24;w+=1)if(S.indexOf(_(w,0,C))>-1){T=w>12;break}}else T=S===(C?"pm":"PM");return T},y={A:[a,function(S){this.afternoon=m(S,!1)}],a:[a,function(S){this.afternoon=m(S,!0)}],Q:[o,function(S){this.month=3*(S-1)+1}],S:[o,function(S){this.milliseconds=100*+S}],SS:[i,function(S){this.milliseconds=10*+S}],SSS:[/\d{3}/,function(S){this.milliseconds=+S}],s:[s,f("seconds")],ss:[s,f("seconds")],m:[s,f("minutes")],mm:[s,f("minutes")],H:[s,f("hours")],h:[s,f("hours")],HH:[s,f("hours")],hh:[s,f("hours")],D:[s,f("day")],DD:[i,f("day")],Do:[a,function(S){var C=l.ordinal,T=S.match(/\d+/);if(this.day=T[0],C)for(var _=1;_<=31;_+=1)C(_).replace(/\[|\]/g,"")===S&&(this.day=_)}],w:[s,f("week")],ww:[i,f("week")],M:[s,f("month")],MM:[i,f("month")],MMM:[a,function(S){var C=g("months"),T=(g("monthsShort")||C.map(function(_){return _.slice(0,3)})).indexOf(S)+1;if(T<1)throw new Error;this.month=T%12||T}],MMMM:[a,function(S){var C=g("months").indexOf(S)+1;if(C<1)throw new Error;this.month=C%12||C}],Y:[/[+-]?\d+/,f("year")],YY:[i,function(S){this.year=u(S)}],YYYY:[/\d{4}/,f("year")],Z:p,ZZ:p};function b(S){var C,T;C=S,T=l&&l.formats;for(var _=(S=C.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(M,A,N){var z=N&&N.toUpperCase();return A||T[N]||n[N]||T[z].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(V,B,R){return B||R.slice(1)})})).match(r),w=_.length,E=0;E<w;E+=1){var O=_[E],L=y[O],P=L&&L[0],$=L&&L[1];_[E]=$?{regex:P,parser:$}:O.replace(/^\[|\]$/g,"")}return function(M){for(var A={},N=0,z=0;N<w;N+=1){var V=_[N];if(typeof V=="string")z+=V.length;else{var B=V.regex,R=V.parser,q=M.slice(z),U=B.exec(q)[0];R.call(A,U),M=M.replace(U,"")}}return function(G){var Y=G.afternoon;if(Y!==void 0){var Z=G.hours;Y?Z<12&&(G.hours+=12):Z===12&&(G.hours=0),delete G.afternoon}}(A),A}}return function(S,C,T){T.p.customParseFormat=!0,S&&S.parseTwoDigitYear&&(u=S.parseTwoDigitYear);var _=C.prototype,w=_.parse;_.parse=function(E){var O=E.date,L=E.utc,P=E.args;this.$u=L;var $=P[1];if(typeof $=="string"){var M=P[2]===!0,A=P[3]===!0,N=M||A,z=P[2];A&&(z=P[2]),l=this.$locale(),!M&&z&&(l=T.Ls[z]),this.$d=function(q,U,G,Y){try{if(["x","X"].indexOf(U)>-1)return new Date((U==="X"?1e3:1)*q);var Z=b(U)(q),fe=Z.year,pe=Z.month,me=Z.day,re=Z.hours,he=Z.minutes,le=Z.seconds,X=Z.milliseconds,W=Z.zone,ee=Z.week,ce=new Date,te=me||(fe||pe?1:ce.getDate()),se=fe||ce.getFullYear(),ue=0;fe&&!pe||(ue=pe>0?pe-1:ce.getMonth());var ye,_e=re||0,Se=he||0,Me=le||0,Fe=X||0;return W?new Date(Date.UTC(se,ue,te,_e,Se,Me,Fe+60*W.offset*1e3)):G?new Date(Date.UTC(se,ue,te,_e,Se,Me,Fe)):(ye=new Date(se,ue,te,_e,Se,Me,Fe),ee&&(ye=Y(ye).week(ee).toDate()),ye)}catch{return new Date("")}}(O,$,L,T),this.init(),z&&z!==!0&&(this.$L=this.locale(z).$L),N&&O!=this.format($)&&(this.$d=new Date("")),l={}}else if($ instanceof Array)for(var V=$.length,B=1;B<=V;B+=1){P[1]=$[B-1];var R=T.apply(this,P);if(R.isValid()){this.$d=R.$d,this.$L=R.$L,this.init();break}B===V&&(this.$d=new Date(""))}else w.call(this,E)}}})}(ed)),ed.exports}var e3=QR();const t3=Zn(e3);var td={exports:{}},n3=td.exports,WC;function r3(){return WC||(WC=1,function(t,e){(function(n,r){t.exports=r()})(n3,function(){var n={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"};return function(r,o,i){var s=o.prototype,a=s.format;i.en.formats=n,s.format=function(l){l===void 0&&(l="YYYY-MM-DDTHH:mm:ssZ");var u=this.$locale().formats,f=function(p,g){return p.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(m,y,b){var S=b&&b.toUpperCase();return y||g[b]||n[b]||g[S].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(C,T,_){return T||_.slice(1)})})}(l,u===void 0?{}:u);return a.call(this,f)}}})}(td)),td.exports}var o3=r3();const i3=Zn(o3);var nd={exports:{}},s3=nd.exports,qC;function a3(){return qC||(qC=1,function(t,e){(function(n,r){t.exports=r()})(s3,function(){return function(n,r,o){r.prototype.isBetween=function(i,s,a,l){var u=o(i),f=o(s),p=(l=l||"()")[0]==="(",g=l[1]===")";return(p?this.isAfter(u,a):!this.isBefore(u,a))&&(g?this.isBefore(f,a):!this.isAfter(f,a))||(p?this.isBefore(u,a):!this.isAfter(u,a))&&(g?this.isAfter(f,a):!this.isBefore(f,a))}}})}(nd)),nd.exports}var l3=a3();const c3=Zn(l3);var rd={exports:{}},u3=rd.exports,UC;function d3(){return UC||(UC=1,function(t,e){(function(n,r){t.exports=r()})(u3,function(){return function(n,r){var o=r.prototype,i=o.format;o.format=function(s){var a=this,l=this.$locale();if(!this.isValid())return i.bind(this)(s);var u=this.$utils(),f=(s||"YYYY-MM-DDTHH:mm:ssZ").replace(/\[([^\]]+)]|Q|wo|ww|w|WW|W|zzz|z|gggg|GGGG|Do|X|x|k{1,2}|S/g,function(p){switch(p){case"Q":return Math.ceil((a.$M+1)/3);case"Do":return l.ordinal(a.$D);case"gggg":return a.weekYear();case"GGGG":return a.isoWeekYear();case"wo":return l.ordinal(a.week(),"W");case"w":case"ww":return u.s(a.week(),p==="w"?1:2,"0");case"W":case"WW":return u.s(a.isoWeek(),p==="W"?1:2,"0");case"k":case"kk":return u.s(String(a.$H===0?24:a.$H),p==="k"?1:2,"0");case"X":return Math.floor(a.$d.getTime()/1e3);case"x":return a.$d.getTime();case"z":return"["+a.offsetName()+"]";case"zzz":return"["+a.offsetName("long")+"]";default:return p}});return i.bind(this)(f)}}})}(rd)),rd.exports}var f3=d3();const p3=Zn(f3),KC=new Set;function YC(t,e="warning"){if(process.env.NODE_ENV==="production")return;const n=Array.isArray(t)?t.join(`
|
|
107
107
|
`):t;KC.has(n)||(KC.add(n),e==="error"?console.error(n):console.warn(n))}pn.extend(i3),pn.extend(ZR),pn.extend(c3),pn.extend(p3);const h3={YY:"year",YYYY:{sectionType:"year",contentType:"digit",maxLength:4},M:{sectionType:"month",contentType:"digit",maxLength:2},MM:"month",MMM:{sectionType:"month",contentType:"letter"},MMMM:{sectionType:"month",contentType:"letter"},D:{sectionType:"day",contentType:"digit",maxLength:2},DD:"day",Do:{sectionType:"day",contentType:"digit-with-letter"},d:{sectionType:"weekDay",contentType:"digit",maxLength:2},dd:{sectionType:"weekDay",contentType:"letter"},ddd:{sectionType:"weekDay",contentType:"letter"},dddd:{sectionType:"weekDay",contentType:"letter"},A:"meridiem",a:"meridiem",H:{sectionType:"hours",contentType:"digit",maxLength:2},HH:"hours",h:{sectionType:"hours",contentType:"digit",maxLength:2},hh:"hours",m:{sectionType:"minutes",contentType:"digit",maxLength:2},mm:"minutes",s:{sectionType:"seconds",contentType:"digit",maxLength:2},ss:"seconds"},g3={year:"YYYY",month:"MMMM",monthShort:"MMM",dayOfMonth:"D",dayOfMonthFull:"Do",weekday:"dddd",weekdayShort:"dd",hours24h:"HH",hours12h:"hh",meridiem:"A",minutes:"mm",seconds:"ss",fullDate:"ll",keyboardDate:"L",shortDate:"MMM D",normalDate:"D MMMM",normalDateWithWeekday:"ddd, MMM D",fullTime:"LT",fullTime12h:"hh:mm A",fullTime24h:"HH:mm",keyboardDateTime:"L LT",keyboardDateTime12h:"L hh:mm A",keyboardDateTime24h:"L HH:mm"},lg=["Missing UTC plugin","To be able to use UTC or timezones, you have to enable the `utc` plugin","Find more information on https://mui.com/x/react-date-pickers/timezone/#day-js-and-utc"].join(`
|
|
108
108
|
`),GC=["Missing timezone plugin","To be able to use timezones, you have to enable both the `utc` and the `timezone` plugin","Find more information on https://mui.com/x/react-date-pickers/timezone/#day-js-and-timezone"].join(`
|
|
109
109
|
`),m3=(t,e)=>e?(...n)=>t(...n).locale(e):t;class y3{constructor({locale:e,formats:n}={}){this.isMUIAdapter=!0,this.isTimezoneCompatible=!0,this.lib="dayjs",this.dayjs=void 0,this.locale=void 0,this.formats=void 0,this.escapedCharacters={start:"[",end:"]"},this.formatTokenMap=h3,this.setLocaleToValue=r=>{const o=this.getCurrentLocaleCode();return o===r.locale()?r:r.locale(o)},this.hasUTCPlugin=()=>typeof pn.utc<"u",this.hasTimezonePlugin=()=>typeof pn.tz<"u",this.isSame=(r,o,i)=>{const s=this.setTimezone(o,this.getTimezone(r));return r.format(i)===s.format(i)},this.cleanTimezone=r=>{switch(r){case"default":return;case"system":return pn.tz.guess();default:return r}},this.createSystemDate=r=>{if(this.hasUTCPlugin()&&this.hasTimezonePlugin()){const o=pn.tz.guess();return o!=="UTC"?pn.tz(r,o):pn(r)}return pn(r)},this.createUTCDate=r=>{if(!this.hasUTCPlugin())throw new Error(lg);return pn.utc(r)},this.createTZDate=(r,o)=>{if(!this.hasUTCPlugin())throw new Error(lg);if(!this.hasTimezonePlugin())throw new Error(GC);const i=r!==void 0&&!r.endsWith("Z");return pn(r).tz(this.cleanTimezone(o),i)},this.getLocaleFormats=()=>{const r=pn.Ls,o=this.locale||"en";let i=r[o];return i===void 0&&(process.env.NODE_ENV!=="production"&&YC(["MUI X: Your locale has not been found.","Either the locale key is not a supported one. Locales supported by dayjs are available here: https://github.com/iamkun/dayjs/tree/dev/src/locale.","Or you forget to import the locale from 'dayjs/locale/{localeUsed}'","fallback on English locale."]),i=r.en),i.formats},this.adjustOffset=r=>{if(!this.hasTimezonePlugin())return r;const o=this.getTimezone(r);if(o!=="UTC"){const i=r.tz(this.cleanTimezone(o),!0);if(i.$offset===(r.$offset??0))return r;r.$offset=i.$offset}return r},this.date=(r,o="default")=>{if(r===null)return null;let i;return o==="UTC"?i=this.createUTCDate(r):o==="system"||o==="default"&&!this.hasTimezonePlugin()?i=this.createSystemDate(r):i=this.createTZDate(r,o),this.locale===void 0?i:i.locale(this.locale)},this.getInvalidDate=()=>pn(new Date("Invalid date")),this.getTimezone=r=>{var o;if(this.hasTimezonePlugin()){const i=(o=r.$x)==null?void 0:o.$timezone;if(i)return i}return this.hasUTCPlugin()&&r.isUTC()?"UTC":"system"},this.setTimezone=(r,o)=>{if(this.getTimezone(r)===o)return r;if(o==="UTC"){if(!this.hasUTCPlugin())throw new Error(lg);return r.utc()}if(o==="system")return r.local();if(!this.hasTimezonePlugin()){if(o==="default")return r;throw new Error(GC)}return pn.tz(r,this.cleanTimezone(o))},this.toJsDate=r=>r.toDate(),this.parse=(r,o)=>r===""?null:this.dayjs(r,o,this.locale,!0),this.getCurrentLocaleCode=()=>this.locale||"en",this.is12HourCycleInCurrentLocale=()=>/A|a/.test(this.getLocaleFormats().LT||""),this.expandFormat=r=>{const o=this.getLocaleFormats(),i=s=>s.replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,(a,l,u)=>l||u.slice(1));return r.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,(s,a,l)=>{const u=l&&l.toUpperCase();return a||o[l]||i(o[u])})},this.isValid=r=>r==null?!1:r.isValid(),this.format=(r,o)=>this.formatByString(r,this.formats[o]),this.formatByString=(r,o)=>this.dayjs(r).format(o),this.formatNumber=r=>r,this.isEqual=(r,o)=>r===null&&o===null?!0:r===null||o===null?!1:r.toDate().getTime()===o.toDate().getTime(),this.isSameYear=(r,o)=>this.isSame(r,o,"YYYY"),this.isSameMonth=(r,o)=>this.isSame(r,o,"YYYY-MM"),this.isSameDay=(r,o)=>this.isSame(r,o,"YYYY-MM-DD"),this.isSameHour=(r,o)=>r.isSame(o,"hour"),this.isAfter=(r,o)=>r>o,this.isAfterYear=(r,o)=>this.hasUTCPlugin()?!this.isSameYear(r,o)&&r.utc()>o.utc():r.isAfter(o,"year"),this.isAfterDay=(r,o)=>this.hasUTCPlugin()?!this.isSameDay(r,o)&&r.utc()>o.utc():r.isAfter(o,"day"),this.isBefore=(r,o)=>r<o,this.isBeforeYear=(r,o)=>this.hasUTCPlugin()?!this.isSameYear(r,o)&&r.utc()<o.utc():r.isBefore(o,"year"),this.isBeforeDay=(r,o)=>this.hasUTCPlugin()?!this.isSameDay(r,o)&&r.utc()<o.utc():r.isBefore(o,"day"),this.isWithinRange=(r,[o,i])=>r>=o&&r<=i,this.startOfYear=r=>this.adjustOffset(r.startOf("year")),this.startOfMonth=r=>this.adjustOffset(r.startOf("month")),this.startOfWeek=r=>this.adjustOffset(this.setLocaleToValue(r).startOf("week")),this.startOfDay=r=>this.adjustOffset(r.startOf("day")),this.endOfYear=r=>this.adjustOffset(r.endOf("year")),this.endOfMonth=r=>this.adjustOffset(r.endOf("month")),this.endOfWeek=r=>this.adjustOffset(this.setLocaleToValue(r).endOf("week")),this.endOfDay=r=>this.adjustOffset(r.endOf("day")),this.addYears=(r,o)=>this.adjustOffset(o<0?r.subtract(Math.abs(o),"year"):r.add(o,"year")),this.addMonths=(r,o)=>this.adjustOffset(o<0?r.subtract(Math.abs(o),"month"):r.add(o,"month")),this.addWeeks=(r,o)=>this.adjustOffset(o<0?r.subtract(Math.abs(o),"week"):r.add(o,"week")),this.addDays=(r,o)=>this.adjustOffset(o<0?r.subtract(Math.abs(o),"day"):r.add(o,"day")),this.addHours=(r,o)=>this.adjustOffset(o<0?r.subtract(Math.abs(o),"hour"):r.add(o,"hour")),this.addMinutes=(r,o)=>this.adjustOffset(o<0?r.subtract(Math.abs(o),"minute"):r.add(o,"minute")),this.addSeconds=(r,o)=>this.adjustOffset(o<0?r.subtract(Math.abs(o),"second"):r.add(o,"second")),this.getYear=r=>r.year(),this.getMonth=r=>r.month(),this.getDate=r=>r.date(),this.getHours=r=>r.hour(),this.getMinutes=r=>r.minute(),this.getSeconds=r=>r.second(),this.getMilliseconds=r=>r.millisecond(),this.setYear=(r,o)=>this.adjustOffset(r.set("year",o)),this.setMonth=(r,o)=>this.adjustOffset(r.set("month",o)),this.setDate=(r,o)=>this.adjustOffset(r.set("date",o)),this.setHours=(r,o)=>this.adjustOffset(r.set("hour",o)),this.setMinutes=(r,o)=>this.adjustOffset(r.set("minute",o)),this.setSeconds=(r,o)=>this.adjustOffset(r.set("second",o)),this.setMilliseconds=(r,o)=>this.adjustOffset(r.set("millisecond",o)),this.getDaysInMonth=r=>r.daysInMonth(),this.getWeekArray=r=>{const o=this.startOfWeek(this.startOfMonth(r)),i=this.endOfWeek(this.endOfMonth(r));let s=0,a=o;const l=[];for(;a<i;){const u=Math.floor(s/7);l[u]=l[u]||[],l[u].push(a),a=this.addDays(a,1),s+=1}return l},this.getWeekNumber=r=>r.week(),this.getYearRange=([r,o])=>{const i=this.startOfYear(r),s=this.endOfYear(o),a=[];let l=i;for(;this.isBefore(l,s);)a.push(l),l=this.addYears(l,1);return a},this.dayjs=m3(pn,e),this.locale=e,this.formats=ne({},g3,n),pn.extend(t3)}getDayOfWeek(e){return e.day()+1}}function od(t){return parseInt(t,10)||0}const b3={shadow:{visibility:"hidden",position:"absolute",overflow:"hidden",height:0,top:0,left:0,transform:"translateZ(0)"}};function v3(t){for(const e in t)return!1;return!0}function JC(t){return v3(t)||t.outerHeightStyle===0&&!t.overflowing}const ZC=I.forwardRef(function(e,n){const{onChange:r,maxRows:o,minRows:i=1,style:s,value:a,...l}=e,{current:u}=I.useRef(a!=null),f=I.useRef(null),p=Et(n,f),g=I.useRef(null),m=I.useRef(null),y=I.useCallback(()=>{const _=f.current,w=m.current;if(!_||!w)return;const O=Ho(_).getComputedStyle(_);if(O.width==="0px")return{outerHeightStyle:0,overflowing:!1};w.style.width=O.width,w.value=_.value||e.placeholder||"x",w.value.slice(-1)===`
|
|
110
|
-
`&&(w.value+=" ");const L=O.boxSizing,P=od(O.paddingBottom)+od(O.paddingTop),$=od(O.borderBottomWidth)+od(O.borderTopWidth),M=w.scrollHeight;w.value="x";const A=w.scrollHeight;let N=M;i&&(N=Math.max(Number(i)*A,N)),o&&(N=Math.min(Number(o)*A,N)),N=Math.max(N,A);const
|
|
111
|
-
`))},[]),ue=Et(W,w,_.ref,te),[ee,se]=I.useState(!1),de=io();process.env.NODE_ENV!=="production"&&I.useEffect(()=>{if(de)return de.registerEffect()},[de]);const ye=fa({props:r,muiFormControl:de,states:["color","disabled","error","hiddenLabel","size","required","filled"]});ye.focused=de?de.focused:ee,I.useEffect(()=>{!de&&g&&ee&&(se(!1),M&&M())},[de,g,ee,M]);const _e=de&&de.onFilled,Se=de&&de.onEmpty,Me=I.useCallback(ft=>{id(ft)?_e&&_e():Se&&Se()},[_e,Se]);Tn(()=>{ae&&Me({value:ce})},[ce,Me,ae]);const Fe=ft=>{V&&V(ft),_.onFocus&&_.onFocus(ft),de&&de.onFocus?de.onFocus(ft):se(!0)},je=ft=>{M&&M(ft),_.onBlur&&_.onBlur(ft),de&&de.onBlur?de.onBlur(ft):se(!1)},Je=(ft,...$n)=>{if(!ae){const Yt=ft.target||W.current;if(Yt==null)throw new Error(process.env.NODE_ENV!=="production"?"MUI: Expected valid input target. Did you use a custom `inputComponent` and forget to forward refs? See https://mui.com/r/input-component-ref-interface for more info.":bo(1));Me({value:Yt.value})}_.onChange&&_.onChange(ft,...$n),A&&A(ft,...$n)};I.useEffect(()=>{Me(W.current)},[]);const De=ft=>{W.current&&ft.currentTarget===ft.target&&W.current.focus(),N&&N(ft)};let ct=T,Ct=_;P&&ct==="input"&&(G?(process.env.NODE_ENV!=="production"&&(L||O)&&console.warn("MUI: You can not use the `minRows` or `maxRows` props when the input `rows` prop is set."),Ct={type:void 0,minRows:G,maxRows:G,...Ct}):Ct={type:void 0,maxRows:O,minRows:L,...Ct},ct=ZC);const Xt=ft=>{Me(ft.animationName==="mui-auto-fill-cancel"?W.current:{value:"x"})};I.useEffect(()=>{de&&de.setAdornedStart(!!he)},[de,he]);const Sn={...r,color:ye.color||"primary",disabled:ye.disabled,endAdornment:y,error:ye.error,focused:ye.focused,formControl:de,fullWidth:S,hiddenLabel:ye.hiddenLabel,multiline:P,size:ye.size,startAdornment:he,type:oe},un=C3(Sn),$t=me.root||u.Root||ld,In=Z.root||f.root||{},Kn=me.input||u.Input||cd;return Ct={...Ct,...Z.input??f.input},v.jsxs(I.Fragment,{children:[!m&&typeof ew=="function"&&(QC||(QC=v.jsx(ew,{}))),v.jsxs($t,{...In,ref:n,onClick:De,...fe,...!$l($t)&&{ownerState:{...Sn,...In.ownerState}},className:Le(un.root,In.className,a,q&&"MuiInputBase-readOnly"),children:[he,v.jsx(Bl.Provider,{value:null,children:v.jsx(Kn,{"aria-invalid":ye.error,"aria-describedby":o,autoComplete:i,autoFocus:s,defaultValue:p,disabled:ye.disabled,id:C,onAnimationStart:Xt,name:$,placeholder:z,readOnly:q,required:ye.required,rows:G,value:ce,onKeyDown:R,onKeyUp:B,type:oe,...Ct,...!$l(Kn)&&{as:ct,ownerState:{...Sn,...Ct.ownerState}},ref:ue,className:Le(un.input,Ct.className,q&&"MuiInputBase-readOnly"),onBlur:je,onChange:Je,onFocus:Fe})}),y,K?K({...ye,startAdornment:he}):null]})]})});process.env.NODE_ENV!=="production"&&(ud.propTypes={"aria-describedby":c.string,autoComplete:c.string,autoFocus:c.bool,classes:c.object,className:c.string,color:c.oneOfType([c.oneOf(["primary","secondary","error","info","success","warning"]),c.string]),components:c.shape({Input:c.elementType,Root:c.elementType}),componentsProps:c.shape({input:c.object,root:c.object}),defaultValue:c.any,disabled:c.bool,disableInjectingGlobalStyles:c.bool,endAdornment:c.node,error:c.bool,fullWidth:c.bool,id:c.string,inputComponent:Eu,inputProps:c.object,inputRef:mn,margin:c.oneOf(["dense","none"]),maxRows:c.oneOfType([c.number,c.string]),minRows:c.oneOfType([c.number,c.string]),multiline:c.bool,name:c.string,onBlur:c.func,onChange:c.func,onClick:c.func,onFocus:c.func,onInvalid:c.func,onKeyDown:c.func,onKeyUp:c.func,placeholder:c.string,readOnly:c.bool,renderSuffix:c.func,required:c.bool,rows:c.oneOfType([c.number,c.string]),size:c.oneOfType([c.oneOf(["medium","small"]),c.string]),slotProps:c.shape({input:c.object,root:c.object}),slots:c.shape({input:c.elementType,root:c.elementType}),startAdornment:c.node,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),type:c.string,value:c.any});function w3(t){return typeof t.main=="string"}function _3(t,e=[]){if(!w3(t))return!1;for(const n of e)if(!t.hasOwnProperty(n)||typeof t[n]!="string")return!1;return!0}function Hn(t=[]){return([,e])=>e&&_3(e,t)}function T3(t){return Ke("MuiInput",t)}const Rl={...pa,...qe("MuiInput",["root","underline","input"])},k3=t=>{const{classes:e,disableUnderline:n}=t,o=Ue({root:["root",!n&&"underline"],input:["input"]},T3,e);return{...e,...o}},E3=be(ld,{shouldForwardProp:t=>ro(t)||t==="classes",name:"MuiInput",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[...sd(t,e),!n.disableUnderline&&e.underline]}})(Dt(({theme:t})=>{let n=t.palette.mode==="light"?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)";return t.vars&&(n=`rgba(${t.vars.palette.common.onBackgroundChannel} / ${t.vars.opacity.inputUnderline})`),{position:"relative",variants:[{props:({ownerState:r})=>r.formControl,style:{"label + &":{marginTop:16}}},{props:({ownerState:r})=>!r.disableUnderline,style:{"&::after":{left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:t.transitions.create("transform",{duration:t.transitions.duration.shorter,easing:t.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${Rl.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${Rl.error}`]:{"&::before, &::after":{borderBottomColor:(t.vars||t).palette.error.main}},"&::before":{borderBottom:`1px solid ${n}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:t.transitions.create("border-bottom-color",{duration:t.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${Rl.disabled}, .${Rl.error}):before`]:{borderBottom:`2px solid ${(t.vars||t).palette.text.primary}`,"@media (hover: none)":{borderBottom:`1px solid ${n}`}},[`&.${Rl.disabled}:before`]:{borderBottomStyle:"dotted"}}},...Object.entries(t.palette).filter(Hn()).map(([r])=>({props:{color:r,disableUnderline:!1},style:{"&::after":{borderBottom:`2px solid ${(t.vars||t).palette[r].main}`}}}))]}})),M3=be(cd,{name:"MuiInput",slot:"Input",overridesResolver:ad})({}),dd=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiInput"}),{disableUnderline:o=!1,components:i={},componentsProps:s,fullWidth:a=!1,inputComponent:l="input",multiline:u=!1,slotProps:f,slots:p={},type:g="text",...m}=r,y=k3(r),S={root:{ownerState:{disableUnderline:o}}},C=f??s?zn(f??s,S):S,T=p.root??i.Root??E3,_=p.input??i.Input??M3;return v.jsx(ud,{slots:{root:T,input:_},slotProps:C,fullWidth:a,inputComponent:l,multiline:u,ref:n,type:g,...m,classes:y})});process.env.NODE_ENV!=="production"&&(dd.propTypes={autoComplete:c.string,autoFocus:c.bool,classes:c.object,color:c.oneOfType([c.oneOf(["primary","secondary"]),c.string]),components:c.shape({Input:c.elementType,Root:c.elementType}),componentsProps:c.shape({input:c.object,root:c.object}),defaultValue:c.any,disabled:c.bool,disableUnderline:c.bool,endAdornment:c.node,error:c.bool,fullWidth:c.bool,id:c.string,inputComponent:c.elementType,inputProps:c.object,inputRef:mn,margin:c.oneOf(["dense","none"]),maxRows:c.oneOfType([c.number,c.string]),minRows:c.oneOfType([c.number,c.string]),multiline:c.bool,name:c.string,onChange:c.func,placeholder:c.string,readOnly:c.bool,required:c.bool,rows:c.oneOfType([c.number,c.string]),slotProps:c.shape({input:c.object,root:c.object}),slots:c.shape({input:c.elementType,root:c.elementType}),startAdornment:c.node,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),type:c.string,value:c.any}),dd.muiName="Input";function O3(t){return Ke("MuiFilledInput",t)}const ds={...pa,...qe("MuiFilledInput",["root","underline","input","adornedStart","adornedEnd","sizeSmall","multiline","hiddenLabel"])},A3=t=>{const{classes:e,disableUnderline:n,startAdornment:r,endAdornment:o,size:i,hiddenLabel:s,multiline:a}=t,l={root:["root",!n&&"underline",r&&"adornedStart",o&&"adornedEnd",i==="small"&&`size${Ae(i)}`,s&&"hiddenLabel",a&&"multiline"],input:["input"]},u=Ue(l,O3,e);return{...e,...u}},I3=be(ld,{shouldForwardProp:t=>ro(t)||t==="classes",name:"MuiFilledInput",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[...sd(t,e),!n.disableUnderline&&e.underline]}})(Dt(({theme:t})=>{const e=t.palette.mode==="light",n=e?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)",r=e?"rgba(0, 0, 0, 0.06)":"rgba(255, 255, 255, 0.09)",o=e?"rgba(0, 0, 0, 0.09)":"rgba(255, 255, 255, 0.13)",i=e?"rgba(0, 0, 0, 0.12)":"rgba(255, 255, 255, 0.12)";return{position:"relative",backgroundColor:t.vars?t.vars.palette.FilledInput.bg:r,borderTopLeftRadius:(t.vars||t).shape.borderRadius,borderTopRightRadius:(t.vars||t).shape.borderRadius,transition:t.transitions.create("background-color",{duration:t.transitions.duration.shorter,easing:t.transitions.easing.easeOut}),"&:hover":{backgroundColor:t.vars?t.vars.palette.FilledInput.hoverBg:o,"@media (hover: none)":{backgroundColor:t.vars?t.vars.palette.FilledInput.bg:r}},[`&.${ds.focused}`]:{backgroundColor:t.vars?t.vars.palette.FilledInput.bg:r},[`&.${ds.disabled}`]:{backgroundColor:t.vars?t.vars.palette.FilledInput.disabledBg:i},variants:[{props:({ownerState:s})=>!s.disableUnderline,style:{"&::after":{left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:t.transitions.create("transform",{duration:t.transitions.duration.shorter,easing:t.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${ds.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${ds.error}`]:{"&::before, &::after":{borderBottomColor:(t.vars||t).palette.error.main}},"&::before":{borderBottom:`1px solid ${t.vars?`rgba(${t.vars.palette.common.onBackgroundChannel} / ${t.vars.opacity.inputUnderline})`:n}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:t.transitions.create("border-bottom-color",{duration:t.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${ds.disabled}, .${ds.error}):before`]:{borderBottom:`1px solid ${(t.vars||t).palette.text.primary}`},[`&.${ds.disabled}:before`]:{borderBottomStyle:"dotted"}}},...Object.entries(t.palette).filter(Hn()).map(([s])=>{var a;return{props:{disableUnderline:!1,color:s},style:{"&::after":{borderBottom:`2px solid ${(a=(t.vars||t).palette[s])==null?void 0:a.main}`}}}}),{props:({ownerState:s})=>s.startAdornment,style:{paddingLeft:12}},{props:({ownerState:s})=>s.endAdornment,style:{paddingRight:12}},{props:({ownerState:s})=>s.multiline,style:{padding:"25px 12px 8px"}},{props:({ownerState:s,size:a})=>s.multiline&&a==="small",style:{paddingTop:21,paddingBottom:4}},{props:({ownerState:s})=>s.multiline&&s.hiddenLabel,style:{paddingTop:16,paddingBottom:17}},{props:({ownerState:s})=>s.multiline&&s.hiddenLabel&&s.size==="small",style:{paddingTop:8,paddingBottom:9}}]}})),D3=be(cd,{name:"MuiFilledInput",slot:"Input",overridesResolver:ad})(Dt(({theme:t})=>({paddingTop:25,paddingRight:12,paddingBottom:8,paddingLeft:12,...!t.vars&&{"&:-webkit-autofill":{WebkitBoxShadow:t.palette.mode==="light"?null:"0 0 0 100px #266798 inset",WebkitTextFillColor:t.palette.mode==="light"?null:"#fff",caretColor:t.palette.mode==="light"?null:"#fff",borderTopLeftRadius:"inherit",borderTopRightRadius:"inherit"}},...t.vars&&{"&:-webkit-autofill":{borderTopLeftRadius:"inherit",borderTopRightRadius:"inherit"},[t.getColorSchemeSelector("dark")]:{"&:-webkit-autofill":{WebkitBoxShadow:"0 0 0 100px #266798 inset",WebkitTextFillColor:"#fff",caretColor:"#fff"}}},variants:[{props:{size:"small"},style:{paddingTop:21,paddingBottom:4}},{props:({ownerState:e})=>e.hiddenLabel,style:{paddingTop:16,paddingBottom:17}},{props:({ownerState:e})=>e.startAdornment,style:{paddingLeft:0}},{props:({ownerState:e})=>e.endAdornment,style:{paddingRight:0}},{props:({ownerState:e})=>e.hiddenLabel&&e.size==="small",style:{paddingTop:8,paddingBottom:9}},{props:({ownerState:e})=>e.multiline,style:{paddingTop:0,paddingBottom:0,paddingLeft:0,paddingRight:0}}]}))),fd=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiFilledInput"}),{disableUnderline:o=!1,components:i={},componentsProps:s,fullWidth:a=!1,hiddenLabel:l,inputComponent:u="input",multiline:f=!1,slotProps:p,slots:g={},type:m="text",...y}=r,b={...r,disableUnderline:o,fullWidth:a,inputComponent:u,multiline:f,type:m},S=A3(r),C={root:{ownerState:b},input:{ownerState:b}},T=p??s?zn(C,p??s):C,_=g.root??i.Root??I3,w=g.input??i.Input??D3;return v.jsx(ud,{slots:{root:_,input:w},slotProps:T,fullWidth:a,inputComponent:u,multiline:f,ref:n,type:m,...y,classes:S})});process.env.NODE_ENV!=="production"&&(fd.propTypes={autoComplete:c.string,autoFocus:c.bool,classes:c.object,color:c.oneOfType([c.oneOf(["primary","secondary"]),c.string]),components:c.shape({Input:c.elementType,Root:c.elementType}),componentsProps:c.shape({input:c.object,root:c.object}),defaultValue:c.any,disabled:c.bool,disableUnderline:c.bool,endAdornment:c.node,error:c.bool,fullWidth:c.bool,hiddenLabel:c.bool,id:c.string,inputComponent:c.elementType,inputProps:c.object,inputRef:mn,margin:c.oneOf(["dense","none"]),maxRows:c.oneOfType([c.number,c.string]),minRows:c.oneOfType([c.number,c.string]),multiline:c.bool,name:c.string,onChange:c.func,placeholder:c.string,readOnly:c.bool,required:c.bool,rows:c.oneOfType([c.number,c.string]),slotProps:c.shape({input:c.object,root:c.object}),slots:c.shape({input:c.elementType,root:c.elementType}),startAdornment:c.node,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),type:c.string,value:c.any}),fd.muiName="Input";var tw;const P3=be("fieldset",{shouldForwardProp:ro})({textAlign:"left",position:"absolute",bottom:0,right:0,top:-5,left:0,margin:0,padding:"0 8px",pointerEvents:"none",borderRadius:"inherit",borderStyle:"solid",borderWidth:1,overflow:"hidden",minWidth:"0%"}),N3=be("legend",{shouldForwardProp:ro})(Dt(({theme:t})=>({float:"unset",width:"auto",overflow:"hidden",variants:[{props:({ownerState:e})=>!e.withLabel,style:{padding:0,lineHeight:"11px",transition:t.transitions.create("width",{duration:150,easing:t.transitions.easing.easeOut})}},{props:({ownerState:e})=>e.withLabel,style:{display:"block",padding:0,height:11,fontSize:"0.75em",visibility:"hidden",maxWidth:.01,transition:t.transitions.create("max-width",{duration:50,easing:t.transitions.easing.easeOut}),whiteSpace:"nowrap","& > span":{paddingLeft:5,paddingRight:5,display:"inline-block",opacity:0,visibility:"visible"}}},{props:({ownerState:e})=>e.withLabel&&e.notched,style:{maxWidth:"100%",transition:t.transitions.create("max-width",{duration:100,easing:t.transitions.easing.easeOut,delay:50})}}]})));function nw(t){const{children:e,classes:n,className:r,label:o,notched:i,...s}=t,a=o!=null&&o!=="",l={...t,notched:i,withLabel:a};return v.jsx(P3,{"aria-hidden":!0,className:r,ownerState:l,...s,children:v.jsx(N3,{ownerState:l,children:a?v.jsx("span",{children:o}):tw||(tw=v.jsx("span",{className:"notranslate","aria-hidden":!0,children:""}))})})}process.env.NODE_ENV!=="production"&&(nw.propTypes={children:c.node,classes:c.object,className:c.string,label:c.node,notched:c.bool.isRequired,style:c.object});function L3(t){return Ke("MuiOutlinedInput",t)}const So={...pa,...qe("MuiOutlinedInput",["root","notchedOutline","input"])},F3=t=>{const{classes:e}=t,r=Ue({root:["root"],notchedOutline:["notchedOutline"],input:["input"]},L3,e);return{...e,...r}},$3=be(ld,{shouldForwardProp:t=>ro(t)||t==="classes",name:"MuiOutlinedInput",slot:"Root",overridesResolver:sd})(Dt(({theme:t})=>{const e=t.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return{position:"relative",borderRadius:(t.vars||t).shape.borderRadius,[`&:hover .${So.notchedOutline}`]:{borderColor:(t.vars||t).palette.text.primary},"@media (hover: none)":{[`&:hover .${So.notchedOutline}`]:{borderColor:t.vars?`rgba(${t.vars.palette.common.onBackgroundChannel} / 0.23)`:e}},[`&.${So.focused} .${So.notchedOutline}`]:{borderWidth:2},variants:[...Object.entries(t.palette).filter(Hn()).map(([n])=>({props:{color:n},style:{[`&.${So.focused} .${So.notchedOutline}`]:{borderColor:(t.vars||t).palette[n].main}}})),{props:{},style:{[`&.${So.error} .${So.notchedOutline}`]:{borderColor:(t.vars||t).palette.error.main},[`&.${So.disabled} .${So.notchedOutline}`]:{borderColor:(t.vars||t).palette.action.disabled}}},{props:({ownerState:n})=>n.startAdornment,style:{paddingLeft:14}},{props:({ownerState:n})=>n.endAdornment,style:{paddingRight:14}},{props:({ownerState:n})=>n.multiline,style:{padding:"16.5px 14px"}},{props:({ownerState:n,size:r})=>n.multiline&&r==="small",style:{padding:"8.5px 14px"}}]}})),B3=be(nw,{name:"MuiOutlinedInput",slot:"NotchedOutline",overridesResolver:(t,e)=>e.notchedOutline})(Dt(({theme:t})=>{const e=t.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return{borderColor:t.vars?`rgba(${t.vars.palette.common.onBackgroundChannel} / 0.23)`:e}})),R3=be(cd,{name:"MuiOutlinedInput",slot:"Input",overridesResolver:ad})(Dt(({theme:t})=>({padding:"16.5px 14px",...!t.vars&&{"&:-webkit-autofill":{WebkitBoxShadow:t.palette.mode==="light"?null:"0 0 0 100px #266798 inset",WebkitTextFillColor:t.palette.mode==="light"?null:"#fff",caretColor:t.palette.mode==="light"?null:"#fff",borderRadius:"inherit"}},...t.vars&&{"&:-webkit-autofill":{borderRadius:"inherit"},[t.getColorSchemeSelector("dark")]:{"&:-webkit-autofill":{WebkitBoxShadow:"0 0 0 100px #266798 inset",WebkitTextFillColor:"#fff",caretColor:"#fff"}}},variants:[{props:{size:"small"},style:{padding:"8.5px 14px"}},{props:({ownerState:e})=>e.multiline,style:{padding:0}},{props:({ownerState:e})=>e.startAdornment,style:{paddingLeft:0}},{props:({ownerState:e})=>e.endAdornment,style:{paddingRight:0}}]}))),pd=I.forwardRef(function(e,n){var r;const o=St({props:e,name:"MuiOutlinedInput"}),{components:i={},fullWidth:s=!1,inputComponent:a="input",label:l,multiline:u=!1,notched:f,slots:p={},type:g="text",...m}=o,y=F3(o),b=io(),S=fa({props:o,muiFormControl:b,states:["color","disabled","error","focused","hiddenLabel","size","required"]}),C={...o,color:S.color||"primary",disabled:S.disabled,error:S.error,focused:S.focused,formControl:b,fullWidth:s,hiddenLabel:S.hiddenLabel,multiline:u,size:S.size,type:g},T=p.root??i.Root??$3,_=p.input??i.Input??R3;return v.jsx(ud,{slots:{root:T,input:_},renderSuffix:w=>v.jsx(B3,{ownerState:C,className:y.notchedOutline,label:l!=null&&l!==""&&S.required?r||(r=v.jsxs(I.Fragment,{children:[l," ","*"]})):l,notched:typeof f<"u"?f:!!(w.startAdornment||w.filled||w.focused)}),fullWidth:s,inputComponent:a,multiline:u,ref:n,type:g,...m,classes:{...y,notchedOutline:null}})});process.env.NODE_ENV!=="production"&&(pd.propTypes={autoComplete:c.string,autoFocus:c.bool,classes:c.object,color:c.oneOfType([c.oneOf(["primary","secondary"]),c.string]),components:c.shape({Input:c.elementType,Root:c.elementType}),defaultValue:c.any,disabled:c.bool,endAdornment:c.node,error:c.bool,fullWidth:c.bool,id:c.string,inputComponent:c.elementType,inputProps:c.object,inputRef:mn,label:c.node,margin:c.oneOf(["dense","none"]),maxRows:c.oneOfType([c.number,c.string]),minRows:c.oneOfType([c.number,c.string]),multiline:c.bool,name:c.string,notched:c.bool,onChange:c.func,placeholder:c.string,readOnly:c.bool,required:c.bool,rows:c.oneOfType([c.number,c.string]),slots:c.shape({input:c.elementType,root:c.elementType}),startAdornment:c.node,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),type:c.string,value:c.any}),pd.muiName="Input";function z3(t){return Ke("MuiFormLabel",t)}const zl=qe("MuiFormLabel",["root","colorSecondary","focused","disabled","error","filled","required","asterisk"]),V3=t=>{const{classes:e,color:n,focused:r,disabled:o,error:i,filled:s,required:a}=t,l={root:["root",`color${Ae(n)}`,o&&"disabled",i&&"error",s&&"filled",r&&"focused",a&&"required"],asterisk:["asterisk",i&&"error"]};return Ue(l,z3,e)},H3=be("label",{name:"MuiFormLabel",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,n.color==="secondary"&&e.colorSecondary,n.filled&&e.filled]}})(Dt(({theme:t})=>({color:(t.vars||t).palette.text.secondary,...t.typography.body1,lineHeight:"1.4375em",padding:0,position:"relative",variants:[...Object.entries(t.palette).filter(Hn()).map(([e])=>({props:{color:e},style:{[`&.${zl.focused}`]:{color:(t.vars||t).palette[e].main}}})),{props:{},style:{[`&.${zl.disabled}`]:{color:(t.vars||t).palette.text.disabled},[`&.${zl.error}`]:{color:(t.vars||t).palette.error.main}}}]}))),j3=be("span",{name:"MuiFormLabel",slot:"Asterisk",overridesResolver:(t,e)=>e.asterisk})(Dt(({theme:t})=>({[`&.${zl.error}`]:{color:(t.vars||t).palette.error.main}}))),rw=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiFormLabel"}),{children:o,className:i,color:s,component:a="label",disabled:l,error:u,filled:f,focused:p,required:g,...m}=r,y=io(),b=fa({props:r,muiFormControl:y,states:["color","required","focused","disabled","error","filled"]}),S={...r,color:b.color||"primary",component:a,disabled:b.disabled,error:b.error,filled:b.filled,focused:b.focused,required:b.required},C=V3(S);return v.jsxs(H3,{as:a,ownerState:S,className:Le(C.root,i),ref:n,...m,children:[o,b.required&&v.jsxs(j3,{ownerState:S,"aria-hidden":!0,className:C.asterisk,children:[" ","*"]})]})});process.env.NODE_ENV!=="production"&&(rw.propTypes={children:c.node,classes:c.object,className:c.string,color:c.oneOfType([c.oneOf(["error","info","primary","secondary","success","warning"]),c.string]),component:c.elementType,disabled:c.bool,error:c.bool,filled:c.bool,focused:c.bool,required:c.bool,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object])});function W3(t){return Ke("MuiInputLabel",t)}qe("MuiInputLabel",["root","focused","disabled","error","required","asterisk","formControl","sizeSmall","shrink","animated","standard","filled","outlined"]);const q3=t=>{const{classes:e,formControl:n,size:r,shrink:o,disableAnimation:i,variant:s,required:a}=t,l={root:["root",n&&"formControl",!i&&"animated",o&&"shrink",r&&r!=="normal"&&`size${Ae(r)}`,s],asterisk:[a&&"asterisk"]},u=Ue(l,W3,e);return{...e,...u}},U3=be(rw,{shouldForwardProp:t=>ro(t)||t==="classes",name:"MuiInputLabel",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[{[`& .${zl.asterisk}`]:e.asterisk},e.root,n.formControl&&e.formControl,n.size==="small"&&e.sizeSmall,n.shrink&&e.shrink,!n.disableAnimation&&e.animated,n.focused&&e.focused,e[n.variant]]}})(Dt(({theme:t})=>({display:"block",transformOrigin:"top left",whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",maxWidth:"100%",variants:[{props:({ownerState:e})=>e.formControl,style:{position:"absolute",left:0,top:0,transform:"translate(0, 20px) scale(1)"}},{props:{size:"small"},style:{transform:"translate(0, 17px) scale(1)"}},{props:({ownerState:e})=>e.shrink,style:{transform:"translate(0, -1.5px) scale(0.75)",transformOrigin:"top left",maxWidth:"133%"}},{props:({ownerState:e})=>!e.disableAnimation,style:{transition:t.transitions.create(["color","transform","max-width"],{duration:t.transitions.duration.shorter,easing:t.transitions.easing.easeOut})}},{props:{variant:"filled"},style:{zIndex:1,pointerEvents:"none",transform:"translate(12px, 16px) scale(1)",maxWidth:"calc(100% - 24px)"}},{props:{variant:"filled",size:"small"},style:{transform:"translate(12px, 13px) scale(1)"}},{props:({variant:e,ownerState:n})=>e==="filled"&&n.shrink,style:{userSelect:"none",pointerEvents:"auto",transform:"translate(12px, 7px) scale(0.75)",maxWidth:"calc(133% - 24px)"}},{props:({variant:e,ownerState:n,size:r})=>e==="filled"&&n.shrink&&r==="small",style:{transform:"translate(12px, 4px) scale(0.75)"}},{props:{variant:"outlined"},style:{zIndex:1,pointerEvents:"none",transform:"translate(14px, 16px) scale(1)",maxWidth:"calc(100% - 24px)"}},{props:{variant:"outlined",size:"small"},style:{transform:"translate(14px, 9px) scale(1)"}},{props:({variant:e,ownerState:n})=>e==="outlined"&&n.shrink,style:{userSelect:"none",pointerEvents:"auto",maxWidth:"calc(133% - 32px)",transform:"translate(14px, -9px) scale(0.75)"}}]}))),cg=I.forwardRef(function(e,n){const r=St({name:"MuiInputLabel",props:e}),{disableAnimation:o=!1,margin:i,shrink:s,variant:a,className:l,...u}=r,f=io();let p=s;typeof p>"u"&&f&&(p=f.filled||f.focused||f.adornedStart);const g=fa({props:r,muiFormControl:f,states:["size","variant","required","focused"]}),m={...r,disableAnimation:o,formControl:f,shrink:p,size:g.size,variant:g.variant,required:g.required,focused:g.focused},y=q3(m);return v.jsx(U3,{"data-shrink":p,ref:n,className:Le(y.root,l),...u,ownerState:m,classes:y})});process.env.NODE_ENV!=="production"&&(cg.propTypes={children:c.node,classes:c.object,className:c.string,color:c.oneOfType([c.oneOf(["error","info","primary","secondary","success","warning"]),c.string]),disableAnimation:c.bool,disabled:c.bool,error:c.bool,focused:c.bool,margin:c.oneOf(["dense"]),required:c.bool,shrink:c.bool,size:c.oneOfType([c.oneOf(["normal","small"]),c.string]),sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),variant:c.oneOf(["filled","outlined","standard"])});function K3(t){return Ke("MuiFormControl",t)}qe("MuiFormControl",["root","marginNone","marginNormal","marginDense","fullWidth","disabled"]);const Y3=t=>{const{classes:e,margin:n,fullWidth:r}=t,o={root:["root",n!=="none"&&`margin${Ae(n)}`,r&&"fullWidth"]};return Ue(o,K3,e)},G3=be("div",{name:"MuiFormControl",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,e[`margin${Ae(n.margin)}`],n.fullWidth&&e.fullWidth]}})({display:"inline-flex",flexDirection:"column",position:"relative",minWidth:0,padding:0,margin:0,border:0,verticalAlign:"top",variants:[{props:{margin:"normal"},style:{marginTop:16,marginBottom:8}},{props:{margin:"dense"},style:{marginTop:8,marginBottom:4}},{props:{fullWidth:!0},style:{width:"100%"}}]}),ug=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiFormControl"}),{children:o,className:i,color:s="primary",component:a="div",disabled:l=!1,error:u=!1,focused:f,fullWidth:p=!1,hiddenLabel:g=!1,margin:m="none",required:y=!1,size:b="medium",variant:S="outlined",...C}=r,T={...r,color:s,component:a,disabled:l,error:u,fullWidth:p,hiddenLabel:g,margin:m,required:y,size:b,variant:S},_=Y3(T),[w,E]=I.useState(()=>{let z=!1;return o&&I.Children.forEach(o,q=>{if(!Sl(q,["Input","Select"]))return;const K=Sl(q,["Select"])?q.props.input:q;K&&x3(K.props)&&(z=!0)}),z}),[O,L]=I.useState(()=>{let z=!1;return o&&I.Children.forEach(o,q=>{Sl(q,["Input","Select"])&&(id(q.props,!0)||id(q.props.inputProps,!0))&&(z=!0)}),z}),[P,$]=I.useState(!1);l&&P&&$(!1);const M=f!==void 0&&!l?f:P;let A;const N=I.useRef(!1);process.env.NODE_ENV!=="production"&&(A=()=>(N.current&&console.error(["MUI: There are multiple `InputBase` components inside a FormControl.","This creates visual inconsistencies, only use one `InputBase`."].join(`
|
|
112
|
-
`)),N.current=!0,()=>{N.current=!1}));const
|
|
113
|
-
`)),_.props.disabled||(p==="selectedMenu"&&_.props.selected||C===-1)&&(C=w),C===w&&(_.props.disabled||_.props.muiSkipListHighlight||_.type.muiSkipListHighlight)&&(C+=1,C>=s.length&&(C=-1))});const T=I.Children.map(s,(_,w)=>{if(w===C){const E={};return i&&(E.autoFocus=!0),_.props.tabIndex===void 0&&p==="selectedMenu"&&(E.tabIndex=0),I.cloneElement(_,E)}return _});return v.jsx(fg,{role:"menu",ref:S,className:a,onKeyDown:b,tabIndex:o?0:-1,...g,children:T})});process.env.NODE_ENV!=="production"&&(lw.propTypes={autoFocus:c.bool,autoFocusItem:c.bool,children:c.node,className:c.string,disabledItemsFocusable:c.bool,disableListWrap:c.bool,onKeyDown:c.func,variant:c.oneOf(["menu","selectedMenu"])});function hg(t,e){return hg=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,r){return n.__proto__=r,n},hg(t,e)}function gg(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,hg(t,e)}function nz(t,e){return t.classList?!!e&&t.classList.contains(e):(" "+(t.className.baseVal||t.className)+" ").indexOf(" "+e+" ")!==-1}function rz(t,e){t.classList?t.classList.add(e):nz(t,e)||(typeof t.className=="string"?t.className=t.className+" "+e:t.setAttribute("class",(t.className&&t.className.baseVal||"")+" "+e))}function cw(t,e){return t.replace(new RegExp("(^|\\s)"+e+"(?:\\s|$)","g"),"$1").replace(/\s+/g," ").replace(/^\s*|\s*$/g,"")}function oz(t,e){t.classList?t.classList.remove(e):typeof t.className=="string"?t.className=cw(t.className,e):t.setAttribute("class",cw(t.className&&t.className.baseVal||"",e))}const uw={disabled:!1};var iz=process.env.NODE_ENV!=="production"?c.oneOfType([c.number,c.shape({enter:c.number,exit:c.number,appear:c.number}).isRequired]):null,sz=process.env.NODE_ENV!=="production"?c.oneOfType([c.string,c.shape({enter:c.string,exit:c.string,active:c.string}),c.shape({enter:c.string,enterDone:c.string,enterActive:c.string,exit:c.string,exitDone:c.string,exitActive:c.string})]):null;const hd=J.createContext(null);var dw=function(e){return e.scrollTop},Hl="unmounted",fs="exited",ps="entering",ga="entered",mg="exiting",Pr=function(t){gg(e,t);function e(r,o){var i;i=t.call(this,r,o)||this;var s=o,a=s&&!s.isMounting?r.enter:r.appear,l;return i.appearStatus=null,r.in?a?(l=fs,i.appearStatus=ps):l=ga:r.unmountOnExit||r.mountOnEnter?l=Hl:l=fs,i.state={status:l},i.nextCallback=null,i}e.getDerivedStateFromProps=function(o,i){var s=o.in;return s&&i.status===Hl?{status:fs}:null};var n=e.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var i=null;if(o!==this.props){var s=this.state.status;this.props.in?s!==ps&&s!==ga&&(i=ps):(s===ps||s===ga)&&(i=mg)}this.updateStatus(!1,i)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,i,s,a;return i=s=a=o,o!=null&&typeof o!="number"&&(i=o.exit,s=o.enter,a=o.appear!==void 0?o.appear:s),{exit:i,enter:s,appear:a}},n.updateStatus=function(o,i){if(o===void 0&&(o=!1),i!==null)if(this.cancelNextCallback(),i===ps){if(this.props.unmountOnExit||this.props.mountOnEnter){var s=this.props.nodeRef?this.props.nodeRef.current:ls.findDOMNode(this);s&&dw(s)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===fs&&this.setState({status:Hl})},n.performEnter=function(o){var i=this,s=this.props.enter,a=this.context?this.context.isMounting:o,l=this.props.nodeRef?[a]:[ls.findDOMNode(this),a],u=l[0],f=l[1],p=this.getTimeouts(),g=a?p.appear:p.enter;if(!o&&!s||uw.disabled){this.safeSetState({status:ga},function(){i.props.onEntered(u)});return}this.props.onEnter(u,f),this.safeSetState({status:ps},function(){i.props.onEntering(u,f),i.onTransitionEnd(g,function(){i.safeSetState({status:ga},function(){i.props.onEntered(u,f)})})})},n.performExit=function(){var o=this,i=this.props.exit,s=this.getTimeouts(),a=this.props.nodeRef?void 0:ls.findDOMNode(this);if(!i||uw.disabled){this.safeSetState({status:fs},function(){o.props.onExited(a)});return}this.props.onExit(a),this.safeSetState({status:mg},function(){o.props.onExiting(a),o.onTransitionEnd(s.exit,function(){o.safeSetState({status:fs},function(){o.props.onExited(a)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,i){i=this.setNextCallback(i),this.setState(o,i)},n.setNextCallback=function(o){var i=this,s=!0;return this.nextCallback=function(a){s&&(s=!1,i.nextCallback=null,o(a))},this.nextCallback.cancel=function(){s=!1},this.nextCallback},n.onTransitionEnd=function(o,i){this.setNextCallback(i);var s=this.props.nodeRef?this.props.nodeRef.current:ls.findDOMNode(this),a=o==null&&!this.props.addEndListener;if(!s||a){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var l=this.props.nodeRef?[this.nextCallback]:[s,this.nextCallback],u=l[0],f=l[1];this.props.addEndListener(u,f)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===Hl)return null;var i=this.props,s=i.children;i.in,i.mountOnEnter,i.unmountOnExit,i.appear,i.enter,i.exit,i.timeout,i.addEndListener,i.onEnter,i.onEntering,i.onEntered,i.onExit,i.onExiting,i.onExited,i.nodeRef;var a=rt(i,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return J.createElement(hd.Provider,{value:null},typeof s=="function"?s(o,a):J.cloneElement(J.Children.only(s),a))},e}(J.Component);Pr.contextType=hd,Pr.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:c.shape({current:typeof Element>"u"?c.any:function(t,e,n,r,o,i){var s=t[e];return c.instanceOf(s&&"ownerDocument"in s?s.ownerDocument.defaultView.Element:Element)(t,e,n,r,o,i)}}),children:c.oneOfType([c.func.isRequired,c.element.isRequired]).isRequired,in:c.bool,mountOnEnter:c.bool,unmountOnExit:c.bool,appear:c.bool,enter:c.bool,exit:c.bool,timeout:function(e){var n=iz;e.addEndListener||(n=n.isRequired);for(var r=arguments.length,o=new Array(r>1?r-1:0),i=1;i<r;i++)o[i-1]=arguments[i];return n.apply(void 0,[e].concat(o))},addEndListener:c.func,onEnter:c.func,onEntering:c.func,onEntered:c.func,onExit:c.func,onExiting:c.func,onExited:c.func}:{};function ma(){}Pr.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:ma,onEntering:ma,onEntered:ma,onExit:ma,onExiting:ma,onExited:ma},Pr.UNMOUNTED=Hl,Pr.EXITED=fs,Pr.ENTERING=ps,Pr.ENTERED=ga,Pr.EXITING=mg;var az=function(e,n){return e&&n&&n.split(" ").forEach(function(r){return rz(e,r)})},yg=function(e,n){return e&&n&&n.split(" ").forEach(function(r){return oz(e,r)})},bg=function(t){gg(e,t);function e(){for(var r,o=arguments.length,i=new Array(o),s=0;s<o;s++)i[s]=arguments[s];return r=t.call.apply(t,[this].concat(i))||this,r.appliedClasses={appear:{},enter:{},exit:{}},r.onEnter=function(a,l){var u=r.resolveArguments(a,l),f=u[0],p=u[1];r.removeClasses(f,"exit"),r.addClass(f,p?"appear":"enter","base"),r.props.onEnter&&r.props.onEnter(a,l)},r.onEntering=function(a,l){var u=r.resolveArguments(a,l),f=u[0],p=u[1],g=p?"appear":"enter";r.addClass(f,g,"active"),r.props.onEntering&&r.props.onEntering(a,l)},r.onEntered=function(a,l){var u=r.resolveArguments(a,l),f=u[0],p=u[1],g=p?"appear":"enter";r.removeClasses(f,g),r.addClass(f,g,"done"),r.props.onEntered&&r.props.onEntered(a,l)},r.onExit=function(a){var l=r.resolveArguments(a),u=l[0];r.removeClasses(u,"appear"),r.removeClasses(u,"enter"),r.addClass(u,"exit","base"),r.props.onExit&&r.props.onExit(a)},r.onExiting=function(a){var l=r.resolveArguments(a),u=l[0];r.addClass(u,"exit","active"),r.props.onExiting&&r.props.onExiting(a)},r.onExited=function(a){var l=r.resolveArguments(a),u=l[0];r.removeClasses(u,"exit"),r.addClass(u,"exit","done"),r.props.onExited&&r.props.onExited(a)},r.resolveArguments=function(a,l){return r.props.nodeRef?[r.props.nodeRef.current,a]:[a,l]},r.getClassNames=function(a){var l=r.props.classNames,u=typeof l=="string",f=u&&l?l+"-":"",p=u?""+f+a:l[a],g=u?p+"-active":l[a+"Active"],m=u?p+"-done":l[a+"Done"];return{baseClassName:p,activeClassName:g,doneClassName:m}},r}var n=e.prototype;return n.addClass=function(o,i,s){var a=this.getClassNames(i)[s+"ClassName"],l=this.getClassNames("enter"),u=l.doneClassName;i==="appear"&&s==="done"&&u&&(a+=" "+u),s==="active"&&o&&dw(o),a&&(this.appliedClasses[i][s]=a,az(o,a))},n.removeClasses=function(o,i){var s=this.appliedClasses[i],a=s.base,l=s.active,u=s.done;this.appliedClasses[i]={},a&&yg(o,a),l&&yg(o,l),u&&yg(o,u)},n.render=function(){var o=this.props;o.classNames;var i=rt(o,["classNames"]);return J.createElement(Pr,ne({},i,{onEnter:this.onEnter,onEntered:this.onEntered,onEntering:this.onEntering,onExit:this.onExit,onExiting:this.onExiting,onExited:this.onExited}))},e}(J.Component);bg.defaultProps={classNames:""},bg.propTypes=process.env.NODE_ENV!=="production"?ne({},Pr.propTypes,{classNames:sz,onEnter:c.func,onEntering:c.func,onEntered:c.func,onExit:c.func,onExiting:c.func,onExited:c.func}):{};function lz(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function vg(t,e){var n=function(i){return e&&J.isValidElement(i)?e(i):i},r=Object.create(null);return t&&J.Children.map(t,function(o){return o}).forEach(function(o){r[o.key]=n(o)}),r}function cz(t,e){t=t||{},e=e||{};function n(f){return f in e?e[f]:t[f]}var r=Object.create(null),o=[];for(var i in t)i in e?o.length&&(r[i]=o,o=[]):o.push(i);var s,a={};for(var l in e){if(r[l])for(s=0;s<r[l].length;s++){var u=r[l][s];a[r[l][s]]=n(u)}a[l]=n(l)}for(s=0;s<o.length;s++)a[o[s]]=n(o[s]);return a}function hs(t,e,n){return n[e]!=null?n[e]:t.props[e]}function uz(t,e){return vg(t.children,function(n){return J.cloneElement(n,{onExited:e.bind(null,n),in:!0,appear:hs(n,"appear",t),enter:hs(n,"enter",t),exit:hs(n,"exit",t)})})}function dz(t,e,n){var r=vg(t.children),o=cz(e,r);return Object.keys(o).forEach(function(i){var s=o[i];if(J.isValidElement(s)){var a=i in e,l=i in r,u=e[i],f=J.isValidElement(u)&&!u.props.in;l&&(!a||f)?o[i]=J.cloneElement(s,{onExited:n.bind(null,s),in:!0,exit:hs(s,"exit",t),enter:hs(s,"enter",t)}):!l&&a&&!f?o[i]=J.cloneElement(s,{in:!1}):l&&a&&J.isValidElement(u)&&(o[i]=J.cloneElement(s,{onExited:n.bind(null,s),in:u.props.in,exit:hs(s,"exit",t),enter:hs(s,"enter",t)}))}}),o}var fz=Object.values||function(t){return Object.keys(t).map(function(e){return t[e]})},pz={component:"div",childFactory:function(e){return e}},jl=function(t){gg(e,t);function e(r,o){var i;i=t.call(this,r,o)||this;var s=i.handleExited.bind(lz(i));return i.state={contextValue:{isMounting:!0},handleExited:s,firstRender:!0},i}var n=e.prototype;return n.componentDidMount=function(){this.mounted=!0,this.setState({contextValue:{isMounting:!1}})},n.componentWillUnmount=function(){this.mounted=!1},e.getDerivedStateFromProps=function(o,i){var s=i.children,a=i.handleExited,l=i.firstRender;return{children:l?uz(o,a):dz(o,s,a),firstRender:!1}},n.handleExited=function(o,i){var s=vg(this.props.children);o.key in s||(o.props.onExited&&o.props.onExited(i),this.mounted&&this.setState(function(a){var l=ne({},a.children);return delete l[o.key],{children:l}}))},n.render=function(){var o=this.props,i=o.component,s=o.childFactory,a=rt(o,["component","childFactory"]),l=this.state.contextValue,u=fz(this.state.children).map(s);return delete a.appear,delete a.enter,delete a.exit,i===null?J.createElement(hd.Provider,{value:l},u):J.createElement(hd.Provider,{value:l},J.createElement(i,a,u))},e}(J.Component);jl.propTypes=process.env.NODE_ENV!=="production"?{component:c.any,children:c.node,appear:c.bool,enter:c.bool,exit:c.bool,childFactory:c.func}:{},jl.defaultProps=pz;const fw=t=>t.scrollTop;function gd(t,e){const{timeout:n,easing:r,style:o={}}=t;return{duration:o.transitionDuration??(typeof n=="number"?n:n[e.mode]||0),easing:o.transitionTimingFunction??(typeof r=="object"?r[e.mode]:r),delay:o.transitionDelay}}function xg(t){return`scale(${t}, ${t**2})`}const hz={entering:{opacity:1,transform:xg(1)},entered:{opacity:1,transform:"none"}},Sg=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),Wl=I.forwardRef(function(e,n){const{addEndListener:r,appear:o=!0,children:i,easing:s,in:a,onEnter:l,onEntered:u,onEntering:f,onExit:p,onExited:g,onExiting:m,style:y,timeout:b="auto",TransitionComponent:S=Pr,...C}=e,T=yS(),_=I.useRef(),w=Si(),E=I.useRef(null),O=Et(E,wl(i),n),L=B=>z=>{if(B){const q=E.current;z===void 0?B(q):B(q,z)}},P=L(f),$=L((B,z)=>{fw(B);const{duration:q,delay:K,easing:G}=gd({style:y,timeout:b,easing:s},{mode:"enter"});let Y;b==="auto"?(Y=w.transitions.getAutoHeightDuration(B.clientHeight),_.current=Y):Y=q,B.style.transition=[w.transitions.create("opacity",{duration:Y,delay:K}),w.transitions.create("transform",{duration:Sg?Y:Y*.666,delay:K,easing:G})].join(","),l&&l(B,z)}),M=L(u),A=L(m),N=L(B=>{const{duration:z,delay:q,easing:K}=gd({style:y,timeout:b,easing:s},{mode:"exit"});let G;b==="auto"?(G=w.transitions.getAutoHeightDuration(B.clientHeight),_.current=G):G=z,B.style.transition=[w.transitions.create("opacity",{duration:G,delay:q}),w.transitions.create("transform",{duration:Sg?G:G*.666,delay:Sg?q:q||G*.333,easing:K})].join(","),B.style.opacity=0,B.style.transform=xg(.75),p&&p(B)}),V=L(g),R=B=>{b==="auto"&&T.start(_.current||0,B),r&&r(E.current,B)};return v.jsx(S,{appear:o,in:a,nodeRef:E,onEnter:$,onEntered:M,onEntering:P,onExit:N,onExited:V,onExiting:A,addEndListener:R,timeout:b==="auto"?null:b,...C,children:(B,{ownerState:z,...q})=>I.cloneElement(i,{style:{opacity:0,transform:xg(.75),visibility:B==="exited"&&!a?"hidden":void 0,...hz[B],...y,...i.props.style},ref:O,...q})})});process.env.NODE_ENV!=="production"&&(Wl.propTypes={addEndListener:c.func,appear:c.bool,children:xl.isRequired,easing:c.oneOfType([c.shape({enter:c.string,exit:c.string}),c.string]),in:c.bool,onEnter:c.func,onEntered:c.func,onEntering:c.func,onExit:c.func,onExited:c.func,onExiting:c.func,style:c.object,timeout:c.oneOfType([c.oneOf(["auto"]),c.number,c.shape({appear:c.number,enter:c.number,exit:c.number})])}),Wl&&(Wl.muiSupportAuto=!0);function gz(t){const e=Vn(t);return e.body===t?Ho(t).innerWidth>e.documentElement.clientWidth:t.scrollHeight>t.clientHeight}function ql(t,e){e?t.setAttribute("aria-hidden","true"):t.removeAttribute("aria-hidden")}function pw(t){return parseInt(Ho(t).getComputedStyle(t).paddingRight,10)||0}function mz(t){const n=["TEMPLATE","SCRIPT","STYLE","LINK","MAP","META","NOSCRIPT","PICTURE","COL","COLGROUP","PARAM","SLOT","SOURCE","TRACK"].includes(t.tagName),r=t.tagName==="INPUT"&&t.getAttribute("type")==="hidden";return n||r}function hw(t,e,n,r,o){const i=[e,n,...r];[].forEach.call(t.children,s=>{const a=!i.includes(s),l=!mz(s);a&&l&&ql(s,o)})}function Cg(t,e){let n=-1;return t.some((r,o)=>e(r)?(n=o,!0):!1),n}function yz(t,e){const n=[],r=t.container;if(!e.disableScrollLock){if(gz(r)){const s=vS(Ho(r));n.push({value:r.style.paddingRight,property:"padding-right",el:r}),r.style.paddingRight=`${pw(r)+s}px`;const a=Vn(r).querySelectorAll(".mui-fixed");[].forEach.call(a,l=>{n.push({value:l.style.paddingRight,property:"padding-right",el:l}),l.style.paddingRight=`${pw(l)+s}px`})}let i;if(r.parentNode instanceof DocumentFragment)i=Vn(r).body;else{const s=r.parentElement,a=Ho(r);i=(s==null?void 0:s.nodeName)==="HTML"&&a.getComputedStyle(s).overflowY==="scroll"?s:r}n.push({value:i.style.overflow,property:"overflow",el:i},{value:i.style.overflowX,property:"overflow-x",el:i},{value:i.style.overflowY,property:"overflow-y",el:i}),i.style.overflow="hidden"}return()=>{n.forEach(({value:i,el:s,property:a})=>{i?s.style.setProperty(a,i):s.style.removeProperty(a)})}}function bz(t){const e=[];return[].forEach.call(t.children,n=>{n.getAttribute("aria-hidden")==="true"&&e.push(n)}),e}class vz{constructor(){this.modals=[],this.containers=[]}add(e,n){let r=this.modals.indexOf(e);if(r!==-1)return r;r=this.modals.length,this.modals.push(e),e.modalRef&&ql(e.modalRef,!1);const o=bz(n);hw(n,e.mount,e.modalRef,o,!0);const i=Cg(this.containers,s=>s.container===n);return i!==-1?(this.containers[i].modals.push(e),r):(this.containers.push({modals:[e],container:n,restore:null,hiddenSiblings:o}),r)}mount(e,n){const r=Cg(this.containers,i=>i.modals.includes(e)),o=this.containers[r];o.restore||(o.restore=yz(o,n))}remove(e,n=!0){const r=this.modals.indexOf(e);if(r===-1)return r;const o=Cg(this.containers,s=>s.modals.includes(e)),i=this.containers[o];if(i.modals.splice(i.modals.indexOf(e),1),this.modals.splice(r,1),i.modals.length===0)i.restore&&i.restore(),e.modalRef&&ql(e.modalRef,n),hw(i.container,e.mount,e.modalRef,i.hiddenSiblings,!1),this.containers.splice(o,1);else{const s=i.modals[i.modals.length-1];s.modalRef&&ql(s.modalRef,!1)}return r}isTopModal(e){return this.modals.length>0&&this.modals[this.modals.length-1]===e}}const xz=["input","select","textarea","a[href]","button","[tabindex]","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'].join(",");function Sz(t){const e=parseInt(t.getAttribute("tabindex")||"",10);return Number.isNaN(e)?t.contentEditable==="true"||(t.nodeName==="AUDIO"||t.nodeName==="VIDEO"||t.nodeName==="DETAILS")&&t.getAttribute("tabindex")===null?0:t.tabIndex:e}function Cz(t){if(t.tagName!=="INPUT"||t.type!=="radio"||!t.name)return!1;const e=r=>t.ownerDocument.querySelector(`input[type="radio"]${r}`);let n=e(`[name="${t.name}"]:checked`);return n||(n=e(`[name="${t.name}"]`)),n!==t}function wz(t){return!(t.disabled||t.tagName==="INPUT"&&t.type==="hidden"||Cz(t))}function _z(t){const e=[],n=[];return Array.from(t.querySelectorAll(xz)).forEach((r,o)=>{const i=Sz(r);i===-1||!wz(r)||(i===0?e.push(r):n.push({documentOrder:o,tabIndex:i,node:r}))}),n.sort((r,o)=>r.tabIndex===o.tabIndex?r.documentOrder-o.documentOrder:r.tabIndex-o.tabIndex).map(r=>r.node).concat(e)}function Tz(){return!0}function Ul(t){const{children:e,disableAutoFocus:n=!1,disableEnforceFocus:r=!1,disableRestoreFocus:o=!1,getTabbable:i=_z,isEnabled:s=Tz,open:a}=t,l=I.useRef(!1),u=I.useRef(null),f=I.useRef(null),p=I.useRef(null),g=I.useRef(null),m=I.useRef(!1),y=I.useRef(null),b=Et(wl(e),y),S=I.useRef(null);I.useEffect(()=>{!a||!y.current||(m.current=!n)},[n,a]),I.useEffect(()=>{if(!a||!y.current)return;const _=Vn(y.current);return y.current.contains(_.activeElement)||(y.current.hasAttribute("tabIndex")||(process.env.NODE_ENV!=="production"&&console.error(["MUI: The modal content node does not accept focus.",'For the benefit of assistive technologies, the tabIndex of the node is being set to "-1".'].join(`
|
|
114
|
-
`)),y.current.setAttribute("tabIndex","-1")),m.current&&y.current.focus()),()=>{o||(p.current&&p.current.focus&&(l.current=!0,p.current.focus()),p.current=null)}},[a]),I.useEffect(()=>{if(!a||!y.current)return;const _=Vn(y.current),w=L=>{S.current=L,!(r||!s()||L.key!=="Tab")&&_.activeElement===y.current&&L.shiftKey&&(l.current=!0,f.current&&f.current.focus())},E=()=>{var $,M;const L=y.current;if(L===null)return;if(!_.hasFocus()||!s()||l.current){l.current=!1;return}if(L.contains(_.activeElement)||r&&_.activeElement!==u.current&&_.activeElement!==f.current)return;if(_.activeElement!==g.current)g.current=null;else if(g.current!==null)return;if(!m.current)return;let P=[];if((_.activeElement===u.current||_.activeElement===f.current)&&(P=i(y.current)),P.length>0){const A=!!(($=S.current)!=null&&$.shiftKey&&((M=S.current)==null?void 0:M.key)==="Tab"),N=P[0],V=P[P.length-1];typeof N!="string"&&typeof V!="string"&&(A?V.focus():N.focus())}else L.focus()};_.addEventListener("focusin",E),_.addEventListener("keydown",w,!0);const O=setInterval(()=>{_.activeElement&&_.activeElement.tagName==="BODY"&&E()},50);return()=>{clearInterval(O),_.removeEventListener("focusin",E),_.removeEventListener("keydown",w,!0)}},[n,r,o,s,a,i]);const C=_=>{p.current===null&&(p.current=_.relatedTarget),m.current=!0,g.current=_.target;const w=e.props.onFocus;w&&w(_)},T=_=>{p.current===null&&(p.current=_.relatedTarget),m.current=!0};return v.jsxs(I.Fragment,{children:[v.jsx("div",{tabIndex:a?0:-1,onFocus:T,ref:u,"data-testid":"sentinelStart"}),I.cloneElement(e,{ref:b,onFocus:C}),v.jsx("div",{tabIndex:a?0:-1,onFocus:T,ref:f,"data-testid":"sentinelEnd"})]})}process.env.NODE_ENV!=="production"&&(Ul.propTypes={children:xl,disableAutoFocus:c.bool,disableEnforceFocus:c.bool,disableRestoreFocus:c.bool,getTabbable:c.func,isEnabled:c.func,open:c.bool.isRequired}),process.env.NODE_ENV!=="production"&&(Ul.propTypes=lS(Ul.propTypes));function kz(t){return typeof t=="function"?t():t}const Kl=I.forwardRef(function(e,n){const{children:r,container:o,disablePortal:i=!1}=e,[s,a]=I.useState(null),l=Et(I.isValidElement(r)?wl(r):null,n);if(Tn(()=>{i||a(kz(o)||document.body)},[o,i]),Tn(()=>{if(s&&!i)return Ah(n,s),()=>{Ah(n,null)}},[n,s,i]),i){if(I.isValidElement(r)){const u={ref:l};return I.cloneElement(r,u)}return r}return s&&IF.createPortal(r,s)});process.env.NODE_ENV!=="production"&&(Kl.propTypes={children:c.node,container:c.oneOfType([Vo,c.func]),disablePortal:c.bool}),process.env.NODE_ENV!=="production"&&(Kl.propTypes=lS(Kl.propTypes));function zt(t,e){const{className:n,elementType:r,ownerState:o,externalForwardedProps:i,internalForwardedProps:s,shouldForwardComponentProp:a=!1,...l}=e,{component:u,slots:f={[t]:void 0},slotProps:p={[t]:void 0},...g}=i,m=f[t]||r,y=Mu(p[t],o),{props:{component:b,...S},internalRef:C}=MS({className:n,...l,externalForwardedProps:t==="root"?g:void 0,externalSlotProps:y}),T=Et(C,y==null?void 0:y.ref,e.ref),_=t==="root"?b||u:b,w=_S(m,{...t==="root"&&!u&&!f[t]&&s,...t!=="root"&&!f[t]&&s,...S,..._&&!a&&{as:_},..._&&a&&{component:_},ref:T},o);return[m,w]}const Ez={entering:{opacity:1},entered:{opacity:1}},wi=I.forwardRef(function(e,n){const r=Si(),o={enter:r.transitions.duration.enteringScreen,exit:r.transitions.duration.leavingScreen},{addEndListener:i,appear:s=!0,children:a,easing:l,in:u,onEnter:f,onEntered:p,onEntering:g,onExit:m,onExited:y,onExiting:b,style:S,timeout:C=o,TransitionComponent:T=Pr,..._}=e,w=I.useRef(null),E=Et(w,wl(a),n),O=R=>B=>{if(R){const z=w.current;B===void 0?R(z):R(z,B)}},L=O(g),P=O((R,B)=>{fw(R);const z=gd({style:S,timeout:C,easing:l},{mode:"enter"});R.style.webkitTransition=r.transitions.create("opacity",z),R.style.transition=r.transitions.create("opacity",z),f&&f(R,B)}),$=O(p),M=O(b),A=O(R=>{const B=gd({style:S,timeout:C,easing:l},{mode:"exit"});R.style.webkitTransition=r.transitions.create("opacity",B),R.style.transition=r.transitions.create("opacity",B),m&&m(R)}),N=O(y),V=R=>{i&&i(w.current,R)};return v.jsx(T,{appear:s,in:u,nodeRef:w,onEnter:P,onEntered:$,onEntering:L,onExit:A,onExited:N,onExiting:M,addEndListener:V,timeout:C,..._,children:(R,{ownerState:B,...z})=>I.cloneElement(a,{style:{opacity:0,visibility:R==="exited"&&!u?"hidden":void 0,...Ez[R],...S,...a.props.style},ref:E,...z})})});process.env.NODE_ENV!=="production"&&(wi.propTypes={addEndListener:c.func,appear:c.bool,children:xl.isRequired,easing:c.oneOfType([c.shape({enter:c.string,exit:c.string}),c.string]),in:c.bool,onEnter:c.func,onEntered:c.func,onEntering:c.func,onExit:c.func,onExited:c.func,onExiting:c.func,style:c.object,timeout:c.oneOfType([c.number,c.shape({appear:c.number,enter:c.number,exit:c.number})])});function Mz(t){return Ke("MuiBackdrop",t)}qe("MuiBackdrop",["root","invisible"]);const Oz=t=>{const{classes:e,invisible:n}=t;return Ue({root:["root",n&&"invisible"]},Mz,e)},Az=be("div",{name:"MuiBackdrop",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,n.invisible&&e.invisible]}})({position:"fixed",display:"flex",alignItems:"center",justifyContent:"center",right:0,bottom:0,top:0,left:0,backgroundColor:"rgba(0, 0, 0, 0.5)",WebkitTapHighlightColor:"transparent",variants:[{props:{invisible:!0},style:{backgroundColor:"transparent"}}]}),wg=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiBackdrop"}),{children:o,className:i,component:s="div",invisible:a=!1,open:l,components:u={},componentsProps:f={},slotProps:p={},slots:g={},TransitionComponent:m,transitionDuration:y,...b}=r,S={...r,component:s,invisible:a},C=Oz(S),T={transition:m,root:u.Root,...g},_={...f,...p},w={slots:T,slotProps:_},[E,O]=zt("root",{elementType:Az,externalForwardedProps:w,className:Le(C.root,i),ownerState:S}),[L,P]=zt("transition",{elementType:wi,externalForwardedProps:w,ownerState:S});return v.jsx(L,{in:l,timeout:y,...b,...P,children:v.jsx(E,{"aria-hidden":!0,...O,classes:C,ref:n,children:o})})});process.env.NODE_ENV!=="production"&&(wg.propTypes={children:c.node,classes:c.object,className:c.string,component:c.elementType,components:c.shape({Root:c.elementType}),componentsProps:c.shape({root:c.object}),invisible:c.bool,open:c.bool.isRequired,slotProps:c.shape({root:c.oneOfType([c.func,c.object]),transition:c.oneOfType([c.func,c.object])}),slots:c.shape({root:c.elementType,transition:c.elementType}),sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),TransitionComponent:c.elementType,transitionDuration:c.oneOfType([c.number,c.shape({appear:c.number,enter:c.number,exit:c.number})])});function Iz(t){return typeof t=="function"?t():t}function Dz(t){return t?t.props.hasOwnProperty("in"):!1}const gw=()=>{},md=new vz;function Pz(t){const{container:e,disableEscapeKeyDown:n=!1,disableScrollLock:r=!1,closeAfterTransition:o=!1,onTransitionEnter:i,onTransitionExited:s,children:a,onClose:l,open:u,rootRef:f}=t,p=I.useRef({}),g=I.useRef(null),m=I.useRef(null),y=Et(m,f),[b,S]=I.useState(!u),C=Dz(a);let T=!0;(t["aria-hidden"]==="false"||t["aria-hidden"]===!1)&&(T=!1);const _=()=>Vn(g.current),w=()=>(p.current.modalRef=m.current,p.current.mount=g.current,p.current),E=()=>{md.mount(w(),{disableScrollLock:r}),m.current&&(m.current.scrollTop=0)},O=Be(()=>{const B=Iz(e)||_().body;md.add(w(),B),m.current&&E()}),L=()=>md.isTopModal(w()),P=Be(B=>{g.current=B,B&&(u&&L()?E():m.current&&ql(m.current,T))}),$=I.useCallback(()=>{md.remove(w(),T)},[T]);I.useEffect(()=>()=>{$()},[$]),I.useEffect(()=>{u?O():(!C||!o)&&$()},[u,$,C,o,O]);const M=B=>z=>{var q;(q=B.onKeyDown)==null||q.call(B,z),!(z.key!=="Escape"||z.which===229||!L())&&(n||(z.stopPropagation(),l&&l(z,"escapeKeyDown")))},A=B=>z=>{var q;(q=B.onClick)==null||q.call(B,z),z.target===z.currentTarget&&l&&l(z,"backdropClick")};return{getRootProps:(B={})=>{const z=kS(t);delete z.onTransitionEnter,delete z.onTransitionExited;const q={...z,...B};return{role:"presentation",...q,onKeyDown:M(q),ref:y}},getBackdropProps:(B={})=>{const z=B;return{"aria-hidden":!0,...z,onClick:A(z),open:u}},getTransitionProps:()=>{const B=()=>{S(!1),i&&i()},z=()=>{S(!0),s&&s(),o&&$()};return{onEnter:dS(B,(a==null?void 0:a.props.onEnter)??gw),onExited:dS(z,(a==null?void 0:a.props.onExited)??gw)}},rootRef:y,portalRef:P,isTopModal:L,exited:b,hasTransition:C}}function Nz(t){return Ke("MuiModal",t)}qe("MuiModal",["root","hidden","backdrop"]);const Lz=t=>{const{open:e,exited:n,classes:r}=t;return Ue({root:["root",!e&&n&&"hidden"],backdrop:["backdrop"]},Nz,r)},Fz=be("div",{name:"MuiModal",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,!n.open&&n.exited&&e.hidden]}})(Dt(({theme:t})=>({position:"fixed",zIndex:(t.vars||t).zIndex.modal,right:0,bottom:0,top:0,left:0,variants:[{props:({ownerState:e})=>!e.open&&e.exited,style:{visibility:"hidden"}}]}))),$z=be(wg,{name:"MuiModal",slot:"Backdrop",overridesResolver:(t,e)=>e.backdrop})({zIndex:-1}),_g=I.forwardRef(function(e,n){const r=St({name:"MuiModal",props:e}),{BackdropComponent:o=$z,BackdropProps:i,classes:s,className:a,closeAfterTransition:l=!1,children:u,container:f,component:p,components:g={},componentsProps:m={},disableAutoFocus:y=!1,disableEnforceFocus:b=!1,disableEscapeKeyDown:S=!1,disablePortal:C=!1,disableRestoreFocus:T=!1,disableScrollLock:_=!1,hideBackdrop:w=!1,keepMounted:E=!1,onBackdropClick:O,onClose:L,onTransitionEnter:P,onTransitionExited:$,open:M,slotProps:A={},slots:N={},theme:V,...R}=r,B={...r,closeAfterTransition:l,disableAutoFocus:y,disableEnforceFocus:b,disableEscapeKeyDown:S,disablePortal:C,disableRestoreFocus:T,disableScrollLock:_,hideBackdrop:w,keepMounted:E},{getRootProps:z,getBackdropProps:q,getTransitionProps:K,portalRef:G,isTopModal:Y,exited:Z,hasTransition:me}=Pz({...B,rootRef:n}),he={...B,exited:Z},oe=Lz(he),Q={};if(u.props.tabIndex===void 0&&(Q.tabIndex="-1"),me){const{onEnter:ue,onExited:ee}=K();Q.onEnter=ue,Q.onExited=ee}const fe={slots:{root:g.Root,backdrop:g.Backdrop,...N},slotProps:{...m,...A}},[ce,ae]=zt("root",{ref:n,elementType:Fz,externalForwardedProps:{...fe,...R,component:p},getSlotProps:z,ownerState:he,className:Le(a,oe==null?void 0:oe.root,!he.open&&he.exited&&(oe==null?void 0:oe.hidden))}),[W,te]=zt("backdrop",{ref:i==null?void 0:i.ref,elementType:o,externalForwardedProps:fe,shouldForwardComponentProp:!0,additionalProps:i,getSlotProps:ue=>q({...ue,onClick:ee=>{O&&O(ee),ue!=null&&ue.onClick&&ue.onClick(ee)}}),className:Le(i==null?void 0:i.className,oe==null?void 0:oe.backdrop),ownerState:he});return!E&&!M&&(!me||Z)?null:v.jsx(Kl,{ref:G,container:f,disablePortal:C,children:v.jsxs(ce,{...ae,children:[!w&&o?v.jsx(W,{...te}):null,v.jsx(Ul,{disableEnforceFocus:b,disableAutoFocus:y,disableRestoreFocus:T,isEnabled:Y,open:M,children:I.cloneElement(u,Q)})]})})});process.env.NODE_ENV!=="production"&&(_g.propTypes={BackdropComponent:c.elementType,BackdropProps:c.object,children:xl.isRequired,classes:c.object,className:c.string,closeAfterTransition:c.bool,component:c.elementType,components:c.shape({Backdrop:c.elementType,Root:c.elementType}),componentsProps:c.shape({backdrop:c.oneOfType([c.func,c.object]),root:c.oneOfType([c.func,c.object])}),container:c.oneOfType([Vo,c.func]),disableAutoFocus:c.bool,disableEnforceFocus:c.bool,disableEscapeKeyDown:c.bool,disablePortal:c.bool,disableRestoreFocus:c.bool,disableScrollLock:c.bool,hideBackdrop:c.bool,keepMounted:c.bool,onBackdropClick:c.func,onClose:c.func,onTransitionEnter:c.func,onTransitionExited:c.func,open:c.bool.isRequired,slotProps:c.shape({backdrop:c.oneOfType([c.func,c.object]),root:c.oneOfType([c.func,c.object])}),slots:c.shape({backdrop:c.elementType,root:c.elementType}),sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object])});function Bz(t){return Ke("MuiPaper",t)}qe("MuiPaper",["root","rounded","outlined","elevation","elevation0","elevation1","elevation2","elevation3","elevation4","elevation5","elevation6","elevation7","elevation8","elevation9","elevation10","elevation11","elevation12","elevation13","elevation14","elevation15","elevation16","elevation17","elevation18","elevation19","elevation20","elevation21","elevation22","elevation23","elevation24"]);const Rz=t=>{const{square:e,elevation:n,variant:r,classes:o}=t,i={root:["root",r,!e&&"rounded",r==="elevation"&&`elevation${n}`]};return Ue(i,Bz,o)},zz=be("div",{name:"MuiPaper",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,e[n.variant],!n.square&&e.rounded,n.variant==="elevation"&&e[`elevation${n.elevation}`]]}})(Dt(({theme:t})=>({backgroundColor:(t.vars||t).palette.background.paper,color:(t.vars||t).palette.text.primary,transition:t.transitions.create("box-shadow"),variants:[{props:({ownerState:e})=>!e.square,style:{borderRadius:t.shape.borderRadius}},{props:{variant:"outlined"},style:{border:`1px solid ${(t.vars||t).palette.divider}`}},{props:{variant:"elevation"},style:{boxShadow:"var(--Paper-shadow)",backgroundImage:"var(--Paper-overlay)"}}]}))),ya=I.forwardRef(function(e,n){var m;const r=St({props:e,name:"MuiPaper"}),o=Si(),{className:i,component:s="div",elevation:a=1,square:l=!1,variant:u="elevation",...f}=r,p={...r,component:s,elevation:a,square:l,variant:u},g=Rz(p);return process.env.NODE_ENV!=="production"&&o.shadows[a]===void 0&&console.error([`MUI: The elevation provided <Paper elevation={${a}}> is not available in the theme.`,`Please make sure that \`theme.shadows[${a}]\` is defined.`].join(`
|
|
115
|
-
`)),v.jsx(zz,{as:s,ownerState:p,className:Le(g.root,i),ref:n,...f,style:{...u==="elevation"&&{"--Paper-shadow":(o.vars||o).shadows[a],...o.vars&&{"--Paper-overlay":(m=o.vars.overlays)==null?void 0:m[a]},...!o.vars&&o.palette.mode==="dark"&&{"--Paper-overlay":`linear-gradient(${Rt("#fff",jh(a))}, ${Rt("#fff",jh(a))})`}},...f.style}})});process.env.NODE_ENV!=="production"&&(ya.propTypes={children:c.node,classes:c.object,className:c.string,component:c.elementType,elevation:zo(CS,t=>{const{elevation:e,variant:n}=t;return e>0&&n==="outlined"?new Error(`MUI: Combining \`elevation={${e}}\` with \`variant="${n}"\` has no effect. Either use \`elevation={0}\` or use a different \`variant\`.`):null}),square:c.bool,style:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),variant:c.oneOfType([c.oneOf(["elevation","outlined"]),c.string])});function Vz(t){return Ke("MuiPopover",t)}qe("MuiPopover",["root","paper"]);function mw(t,e){let n=0;return typeof e=="number"?n=e:e==="center"?n=t.height/2:e==="bottom"&&(n=t.height),n}function yw(t,e){let n=0;return typeof e=="number"?n=e:e==="center"?n=t.width/2:e==="right"&&(n=t.width),n}function bw(t){return[t.horizontal,t.vertical].map(e=>typeof e=="number"?`${e}px`:e).join(" ")}function yd(t){return typeof t=="function"?t():t}const Hz=t=>{const{classes:e}=t;return Ue({root:["root"],paper:["paper"]},Vz,e)},jz=be(_g,{name:"MuiPopover",slot:"Root",overridesResolver:(t,e)=>e.root})({}),vw=be(ya,{name:"MuiPopover",slot:"Paper",overridesResolver:(t,e)=>e.paper})({position:"absolute",overflowY:"auto",overflowX:"hidden",minWidth:16,minHeight:16,maxWidth:"calc(100% - 32px)",maxHeight:"calc(100% - 32px)",outline:0}),xw=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiPopover"}),{action:o,anchorEl:i,anchorOrigin:s={vertical:"top",horizontal:"left"},anchorPosition:a,anchorReference:l="anchorEl",children:u,className:f,container:p,elevation:g=8,marginThreshold:m=16,open:y,PaperProps:b={},slots:S={},slotProps:C={},transformOrigin:T={vertical:"top",horizontal:"left"},TransitionComponent:_,transitionDuration:w="auto",TransitionProps:E={},disableScrollLock:O=!1,...L}=r,P=I.useRef(),$={...r,anchorOrigin:s,anchorReference:l,elevation:g,marginThreshold:m,transformOrigin:T,TransitionComponent:_,transitionDuration:w,TransitionProps:E},M=Hz($),A=I.useCallback(()=>{if(l==="anchorPosition")return process.env.NODE_ENV!=="production"&&(a||console.error('MUI: You need to provide a `anchorPosition` prop when using <Popover anchorReference="anchorPosition" />.')),a;const
|
|
116
|
-
`))}return{top:
|
|
117
|
-
`)),m!==null&&ye<m){const Je=ye-m;ye-=Je,
|
|
110
|
+
`&&(w.value+=" ");const L=O.boxSizing,P=od(O.paddingBottom)+od(O.paddingTop),$=od(O.borderBottomWidth)+od(O.borderTopWidth),M=w.scrollHeight;w.value="x";const A=w.scrollHeight;let N=M;i&&(N=Math.max(Number(i)*A,N)),o&&(N=Math.min(Number(o)*A,N)),N=Math.max(N,A);const z=N+(L==="border-box"?P+$:0),V=Math.abs(N-M)<=1;return{outerHeightStyle:z,overflowing:V}},[o,i,e.placeholder]),b=Be(()=>{const _=f.current,w=y();if(!_||!w||JC(w))return!1;const E=w.outerHeightStyle;return g.current!=null&&g.current!==E}),S=I.useCallback(()=>{const _=f.current,w=y();if(!_||!w||JC(w))return;const E=w.outerHeightStyle;g.current!==E&&(g.current=E,_.style.height=`${E}px`),_.style.overflow=w.overflowing?"hidden":""},[y]),C=I.useRef(-1);Tn(()=>{const _=fS(S),w=f==null?void 0:f.current;if(!w)return;const E=Ho(w);E.addEventListener("resize",_);let O;return typeof ResizeObserver<"u"&&(O=new ResizeObserver(()=>{b()&&(O.unobserve(w),cancelAnimationFrame(C.current),S(),C.current=requestAnimationFrame(()=>{O.observe(w)}))}),O.observe(w)),()=>{_.clear(),cancelAnimationFrame(C.current),E.removeEventListener("resize",_),O&&O.disconnect()}},[y,S,b]),Tn(()=>{S()});const T=_=>{u||S(),r&&r(_)};return v.jsxs(I.Fragment,{children:[v.jsx("textarea",{value:a,onChange:T,ref:p,rows:i,style:s,...l}),v.jsx("textarea",{"aria-hidden":!0,className:e.className,readOnly:!0,ref:m,tabIndex:-1,style:{...b3.shadow,...s,paddingTop:0,paddingBottom:0}})]})});process.env.NODE_ENV!=="production"&&(ZC.propTypes={className:c.string,maxRows:c.oneOfType([c.number,c.string]),minRows:c.oneOfType([c.number,c.string]),onChange:c.func,placeholder:c.string,style:c.object,value:c.oneOfType([c.arrayOf(c.string),c.number,c.string])});function $l(t){return typeof t=="string"}function fa({props:t,states:e,muiFormControl:n}){return e.reduce((r,o)=>(r[o]=t[o],n&&typeof t[o]>"u"&&(r[o]=n[o]),r),{})}const Bl=I.createContext(void 0);process.env.NODE_ENV!=="production"&&(Bl.displayName="FormControlContext");function io(){return I.useContext(Bl)}function XC(t){return t!=null&&!(Array.isArray(t)&&t.length===0)}function id(t,e=!1){return t&&(XC(t.value)&&t.value!==""||e&&XC(t.defaultValue)&&t.defaultValue!=="")}function x3(t){return t.startAdornment}function S3(t){return Ke("MuiInputBase",t)}const pa=qe("MuiInputBase",["root","formControl","focused","disabled","adornedStart","adornedEnd","error","sizeSmall","multiline","colorSecondary","fullWidth","hiddenLabel","readOnly","input","inputSizeSmall","inputMultiline","inputTypeSearch","inputAdornedStart","inputAdornedEnd","inputHiddenLabel"]);var QC;const sd=(t,e)=>{const{ownerState:n}=t;return[e.root,n.formControl&&e.formControl,n.startAdornment&&e.adornedStart,n.endAdornment&&e.adornedEnd,n.error&&e.error,n.size==="small"&&e.sizeSmall,n.multiline&&e.multiline,n.color&&e[`color${Ae(n.color)}`],n.fullWidth&&e.fullWidth,n.hiddenLabel&&e.hiddenLabel]},ad=(t,e)=>{const{ownerState:n}=t;return[e.input,n.size==="small"&&e.inputSizeSmall,n.multiline&&e.inputMultiline,n.type==="search"&&e.inputTypeSearch,n.startAdornment&&e.inputAdornedStart,n.endAdornment&&e.inputAdornedEnd,n.hiddenLabel&&e.inputHiddenLabel]},C3=t=>{const{classes:e,color:n,disabled:r,error:o,endAdornment:i,focused:s,formControl:a,fullWidth:l,hiddenLabel:u,multiline:f,readOnly:p,size:g,startAdornment:m,type:y}=t,b={root:["root",`color${Ae(n)}`,r&&"disabled",o&&"error",l&&"fullWidth",s&&"focused",a&&"formControl",g&&g!=="medium"&&`size${Ae(g)}`,f&&"multiline",m&&"adornedStart",i&&"adornedEnd",u&&"hiddenLabel",p&&"readOnly"],input:["input",r&&"disabled",y==="search"&&"inputTypeSearch",f&&"inputMultiline",g==="small"&&"inputSizeSmall",u&&"inputHiddenLabel",m&&"inputAdornedStart",i&&"inputAdornedEnd",p&&"readOnly"]};return Ue(b,S3,e)},ld=be("div",{name:"MuiInputBase",slot:"Root",overridesResolver:sd})(Dt(({theme:t})=>({...t.typography.body1,color:(t.vars||t).palette.text.primary,lineHeight:"1.4375em",boxSizing:"border-box",position:"relative",cursor:"text",display:"inline-flex",alignItems:"center",[`&.${pa.disabled}`]:{color:(t.vars||t).palette.text.disabled,cursor:"default"},variants:[{props:({ownerState:e})=>e.multiline,style:{padding:"4px 0 5px"}},{props:({ownerState:e,size:n})=>e.multiline&&n==="small",style:{paddingTop:1}},{props:({ownerState:e})=>e.fullWidth,style:{width:"100%"}}]}))),cd=be("input",{name:"MuiInputBase",slot:"Input",overridesResolver:ad})(Dt(({theme:t})=>{const e=t.palette.mode==="light",n={color:"currentColor",...t.vars?{opacity:t.vars.opacity.inputPlaceholder}:{opacity:e?.42:.5},transition:t.transitions.create("opacity",{duration:t.transitions.duration.shorter})},r={opacity:"0 !important"},o=t.vars?{opacity:t.vars.opacity.inputPlaceholder}:{opacity:e?.42:.5};return{font:"inherit",letterSpacing:"inherit",color:"currentColor",padding:"4px 0 5px",border:0,boxSizing:"content-box",background:"none",height:"1.4375em",margin:0,WebkitTapHighlightColor:"transparent",display:"block",minWidth:0,width:"100%","&::-webkit-input-placeholder":n,"&::-moz-placeholder":n,"&::-ms-input-placeholder":n,"&:focus":{outline:0},"&:invalid":{boxShadow:"none"},"&::-webkit-search-decoration":{WebkitAppearance:"none"},[`label[data-shrink=false] + .${pa.formControl} &`]:{"&::-webkit-input-placeholder":r,"&::-moz-placeholder":r,"&::-ms-input-placeholder":r,"&:focus::-webkit-input-placeholder":o,"&:focus::-moz-placeholder":o,"&:focus::-ms-input-placeholder":o},[`&.${pa.disabled}`]:{opacity:1,WebkitTextFillColor:(t.vars||t).palette.text.disabled},variants:[{props:({ownerState:i})=>!i.disableInjectingGlobalStyles,style:{animationName:"mui-auto-fill-cancel",animationDuration:"10ms","&:-webkit-autofill":{animationDuration:"5000s",animationName:"mui-auto-fill"}}},{props:{size:"small"},style:{paddingTop:1}},{props:({ownerState:i})=>i.multiline,style:{height:"auto",resize:"none",padding:0,paddingTop:0}},{props:{type:"search"},style:{MozAppearance:"textfield"}}]}})),ew=CB({"@keyframes mui-auto-fill":{from:{display:"block"}},"@keyframes mui-auto-fill-cancel":{from:{display:"block"}}}),ud=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiInputBase"}),{"aria-describedby":o,autoComplete:i,autoFocus:s,className:a,color:l,components:u={},componentsProps:f={},defaultValue:p,disabled:g,disableInjectingGlobalStyles:m,endAdornment:y,error:b,fullWidth:S=!1,id:C,inputComponent:T="input",inputProps:_={},inputRef:w,margin:E,maxRows:O,minRows:L,multiline:P=!1,name:$,onBlur:M,onChange:A,onClick:N,onFocus:z,onKeyDown:V,onKeyUp:B,placeholder:R,readOnly:q,renderSuffix:U,rows:G,size:Y,slotProps:Z={},slots:fe={},startAdornment:pe,type:me="text",value:re,...he}=r,le=_.value!=null?_.value:re,{current:X}=I.useRef(le!=null),W=I.useRef(),ee=I.useCallback(ft=>{process.env.NODE_ENV!=="production"&&ft&&ft.nodeName!=="INPUT"&&!ft.focus&&console.error(["MUI: You have provided a `inputComponent` to the input component","that does not correctly handle the `ref` prop.","Make sure the `ref` prop is called with a HTMLInputElement."].join(`
|
|
111
|
+
`))},[]),ce=Et(W,w,_.ref,ee),[te,se]=I.useState(!1),ue=io();process.env.NODE_ENV!=="production"&&I.useEffect(()=>{if(ue)return ue.registerEffect()},[ue]);const ye=fa({props:r,muiFormControl:ue,states:["color","disabled","error","hiddenLabel","size","required","filled"]});ye.focused=ue?ue.focused:te,I.useEffect(()=>{!ue&&g&&te&&(se(!1),M&&M())},[ue,g,te,M]);const _e=ue&&ue.onFilled,Se=ue&&ue.onEmpty,Me=I.useCallback(ft=>{id(ft)?_e&&_e():Se&&Se()},[_e,Se]);Tn(()=>{X&&Me({value:le})},[le,Me,X]);const Fe=ft=>{z&&z(ft),_.onFocus&&_.onFocus(ft),ue&&ue.onFocus?ue.onFocus(ft):se(!0)},je=ft=>{M&&M(ft),_.onBlur&&_.onBlur(ft),ue&&ue.onBlur?ue.onBlur(ft):se(!1)},Je=(ft,...$n)=>{if(!X){const Yt=ft.target||W.current;if(Yt==null)throw new Error(process.env.NODE_ENV!=="production"?"MUI: Expected valid input target. Did you use a custom `inputComponent` and forget to forward refs? See https://mui.com/r/input-component-ref-interface for more info.":bo(1));Me({value:Yt.value})}_.onChange&&_.onChange(ft,...$n),A&&A(ft,...$n)};I.useEffect(()=>{Me(W.current)},[]);const De=ft=>{W.current&&ft.currentTarget===ft.target&&W.current.focus(),N&&N(ft)};let ct=T,Ct=_;P&&ct==="input"&&(G?(process.env.NODE_ENV!=="production"&&(L||O)&&console.warn("MUI: You can not use the `minRows` or `maxRows` props when the input `rows` prop is set."),Ct={type:void 0,minRows:G,maxRows:G,...Ct}):Ct={type:void 0,maxRows:O,minRows:L,...Ct},ct=ZC);const Xt=ft=>{Me(ft.animationName==="mui-auto-fill-cancel"?W.current:{value:"x"})};I.useEffect(()=>{ue&&ue.setAdornedStart(!!pe)},[ue,pe]);const Sn={...r,color:ye.color||"primary",disabled:ye.disabled,endAdornment:y,error:ye.error,focused:ye.focused,formControl:ue,fullWidth:S,hiddenLabel:ye.hiddenLabel,multiline:P,size:ye.size,startAdornment:pe,type:me},un=C3(Sn),$t=fe.root||u.Root||ld,In=Z.root||f.root||{},Kn=fe.input||u.Input||cd;return Ct={...Ct,...Z.input??f.input},v.jsxs(I.Fragment,{children:[!m&&typeof ew=="function"&&(QC||(QC=v.jsx(ew,{}))),v.jsxs($t,{...In,ref:n,onClick:De,...he,...!$l($t)&&{ownerState:{...Sn,...In.ownerState}},className:Le(un.root,In.className,a,q&&"MuiInputBase-readOnly"),children:[pe,v.jsx(Bl.Provider,{value:null,children:v.jsx(Kn,{"aria-invalid":ye.error,"aria-describedby":o,autoComplete:i,autoFocus:s,defaultValue:p,disabled:ye.disabled,id:C,onAnimationStart:Xt,name:$,placeholder:R,readOnly:q,required:ye.required,rows:G,value:le,onKeyDown:V,onKeyUp:B,type:me,...Ct,...!$l(Kn)&&{as:ct,ownerState:{...Sn,...Ct.ownerState}},ref:ce,className:Le(un.input,Ct.className,q&&"MuiInputBase-readOnly"),onBlur:je,onChange:Je,onFocus:Fe})}),y,U?U({...ye,startAdornment:pe}):null]})]})});process.env.NODE_ENV!=="production"&&(ud.propTypes={"aria-describedby":c.string,autoComplete:c.string,autoFocus:c.bool,classes:c.object,className:c.string,color:c.oneOfType([c.oneOf(["primary","secondary","error","info","success","warning"]),c.string]),components:c.shape({Input:c.elementType,Root:c.elementType}),componentsProps:c.shape({input:c.object,root:c.object}),defaultValue:c.any,disabled:c.bool,disableInjectingGlobalStyles:c.bool,endAdornment:c.node,error:c.bool,fullWidth:c.bool,id:c.string,inputComponent:Eu,inputProps:c.object,inputRef:mn,margin:c.oneOf(["dense","none"]),maxRows:c.oneOfType([c.number,c.string]),minRows:c.oneOfType([c.number,c.string]),multiline:c.bool,name:c.string,onBlur:c.func,onChange:c.func,onClick:c.func,onFocus:c.func,onInvalid:c.func,onKeyDown:c.func,onKeyUp:c.func,placeholder:c.string,readOnly:c.bool,renderSuffix:c.func,required:c.bool,rows:c.oneOfType([c.number,c.string]),size:c.oneOfType([c.oneOf(["medium","small"]),c.string]),slotProps:c.shape({input:c.object,root:c.object}),slots:c.shape({input:c.elementType,root:c.elementType}),startAdornment:c.node,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),type:c.string,value:c.any});function w3(t){return typeof t.main=="string"}function _3(t,e=[]){if(!w3(t))return!1;for(const n of e)if(!t.hasOwnProperty(n)||typeof t[n]!="string")return!1;return!0}function Hn(t=[]){return([,e])=>e&&_3(e,t)}function T3(t){return Ke("MuiInput",t)}const Rl={...pa,...qe("MuiInput",["root","underline","input"])},k3=t=>{const{classes:e,disableUnderline:n}=t,o=Ue({root:["root",!n&&"underline"],input:["input"]},T3,e);return{...e,...o}},E3=be(ld,{shouldForwardProp:t=>ro(t)||t==="classes",name:"MuiInput",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[...sd(t,e),!n.disableUnderline&&e.underline]}})(Dt(({theme:t})=>{let n=t.palette.mode==="light"?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)";return t.vars&&(n=`rgba(${t.vars.palette.common.onBackgroundChannel} / ${t.vars.opacity.inputUnderline})`),{position:"relative",variants:[{props:({ownerState:r})=>r.formControl,style:{"label + &":{marginTop:16}}},{props:({ownerState:r})=>!r.disableUnderline,style:{"&::after":{left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:t.transitions.create("transform",{duration:t.transitions.duration.shorter,easing:t.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${Rl.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${Rl.error}`]:{"&::before, &::after":{borderBottomColor:(t.vars||t).palette.error.main}},"&::before":{borderBottom:`1px solid ${n}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:t.transitions.create("border-bottom-color",{duration:t.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${Rl.disabled}, .${Rl.error}):before`]:{borderBottom:`2px solid ${(t.vars||t).palette.text.primary}`,"@media (hover: none)":{borderBottom:`1px solid ${n}`}},[`&.${Rl.disabled}:before`]:{borderBottomStyle:"dotted"}}},...Object.entries(t.palette).filter(Hn()).map(([r])=>({props:{color:r,disableUnderline:!1},style:{"&::after":{borderBottom:`2px solid ${(t.vars||t).palette[r].main}`}}}))]}})),M3=be(cd,{name:"MuiInput",slot:"Input",overridesResolver:ad})({}),dd=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiInput"}),{disableUnderline:o=!1,components:i={},componentsProps:s,fullWidth:a=!1,inputComponent:l="input",multiline:u=!1,slotProps:f,slots:p={},type:g="text",...m}=r,y=k3(r),S={root:{ownerState:{disableUnderline:o}}},C=f??s?zn(f??s,S):S,T=p.root??i.Root??E3,_=p.input??i.Input??M3;return v.jsx(ud,{slots:{root:T,input:_},slotProps:C,fullWidth:a,inputComponent:l,multiline:u,ref:n,type:g,...m,classes:y})});process.env.NODE_ENV!=="production"&&(dd.propTypes={autoComplete:c.string,autoFocus:c.bool,classes:c.object,color:c.oneOfType([c.oneOf(["primary","secondary"]),c.string]),components:c.shape({Input:c.elementType,Root:c.elementType}),componentsProps:c.shape({input:c.object,root:c.object}),defaultValue:c.any,disabled:c.bool,disableUnderline:c.bool,endAdornment:c.node,error:c.bool,fullWidth:c.bool,id:c.string,inputComponent:c.elementType,inputProps:c.object,inputRef:mn,margin:c.oneOf(["dense","none"]),maxRows:c.oneOfType([c.number,c.string]),minRows:c.oneOfType([c.number,c.string]),multiline:c.bool,name:c.string,onChange:c.func,placeholder:c.string,readOnly:c.bool,required:c.bool,rows:c.oneOfType([c.number,c.string]),slotProps:c.shape({input:c.object,root:c.object}),slots:c.shape({input:c.elementType,root:c.elementType}),startAdornment:c.node,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),type:c.string,value:c.any}),dd.muiName="Input";function O3(t){return Ke("MuiFilledInput",t)}const ds={...pa,...qe("MuiFilledInput",["root","underline","input","adornedStart","adornedEnd","sizeSmall","multiline","hiddenLabel"])},A3=t=>{const{classes:e,disableUnderline:n,startAdornment:r,endAdornment:o,size:i,hiddenLabel:s,multiline:a}=t,l={root:["root",!n&&"underline",r&&"adornedStart",o&&"adornedEnd",i==="small"&&`size${Ae(i)}`,s&&"hiddenLabel",a&&"multiline"],input:["input"]},u=Ue(l,O3,e);return{...e,...u}},I3=be(ld,{shouldForwardProp:t=>ro(t)||t==="classes",name:"MuiFilledInput",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[...sd(t,e),!n.disableUnderline&&e.underline]}})(Dt(({theme:t})=>{const e=t.palette.mode==="light",n=e?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)",r=e?"rgba(0, 0, 0, 0.06)":"rgba(255, 255, 255, 0.09)",o=e?"rgba(0, 0, 0, 0.09)":"rgba(255, 255, 255, 0.13)",i=e?"rgba(0, 0, 0, 0.12)":"rgba(255, 255, 255, 0.12)";return{position:"relative",backgroundColor:t.vars?t.vars.palette.FilledInput.bg:r,borderTopLeftRadius:(t.vars||t).shape.borderRadius,borderTopRightRadius:(t.vars||t).shape.borderRadius,transition:t.transitions.create("background-color",{duration:t.transitions.duration.shorter,easing:t.transitions.easing.easeOut}),"&:hover":{backgroundColor:t.vars?t.vars.palette.FilledInput.hoverBg:o,"@media (hover: none)":{backgroundColor:t.vars?t.vars.palette.FilledInput.bg:r}},[`&.${ds.focused}`]:{backgroundColor:t.vars?t.vars.palette.FilledInput.bg:r},[`&.${ds.disabled}`]:{backgroundColor:t.vars?t.vars.palette.FilledInput.disabledBg:i},variants:[{props:({ownerState:s})=>!s.disableUnderline,style:{"&::after":{left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:t.transitions.create("transform",{duration:t.transitions.duration.shorter,easing:t.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${ds.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${ds.error}`]:{"&::before, &::after":{borderBottomColor:(t.vars||t).palette.error.main}},"&::before":{borderBottom:`1px solid ${t.vars?`rgba(${t.vars.palette.common.onBackgroundChannel} / ${t.vars.opacity.inputUnderline})`:n}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:t.transitions.create("border-bottom-color",{duration:t.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${ds.disabled}, .${ds.error}):before`]:{borderBottom:`1px solid ${(t.vars||t).palette.text.primary}`},[`&.${ds.disabled}:before`]:{borderBottomStyle:"dotted"}}},...Object.entries(t.palette).filter(Hn()).map(([s])=>{var a;return{props:{disableUnderline:!1,color:s},style:{"&::after":{borderBottom:`2px solid ${(a=(t.vars||t).palette[s])==null?void 0:a.main}`}}}}),{props:({ownerState:s})=>s.startAdornment,style:{paddingLeft:12}},{props:({ownerState:s})=>s.endAdornment,style:{paddingRight:12}},{props:({ownerState:s})=>s.multiline,style:{padding:"25px 12px 8px"}},{props:({ownerState:s,size:a})=>s.multiline&&a==="small",style:{paddingTop:21,paddingBottom:4}},{props:({ownerState:s})=>s.multiline&&s.hiddenLabel,style:{paddingTop:16,paddingBottom:17}},{props:({ownerState:s})=>s.multiline&&s.hiddenLabel&&s.size==="small",style:{paddingTop:8,paddingBottom:9}}]}})),D3=be(cd,{name:"MuiFilledInput",slot:"Input",overridesResolver:ad})(Dt(({theme:t})=>({paddingTop:25,paddingRight:12,paddingBottom:8,paddingLeft:12,...!t.vars&&{"&:-webkit-autofill":{WebkitBoxShadow:t.palette.mode==="light"?null:"0 0 0 100px #266798 inset",WebkitTextFillColor:t.palette.mode==="light"?null:"#fff",caretColor:t.palette.mode==="light"?null:"#fff",borderTopLeftRadius:"inherit",borderTopRightRadius:"inherit"}},...t.vars&&{"&:-webkit-autofill":{borderTopLeftRadius:"inherit",borderTopRightRadius:"inherit"},[t.getColorSchemeSelector("dark")]:{"&:-webkit-autofill":{WebkitBoxShadow:"0 0 0 100px #266798 inset",WebkitTextFillColor:"#fff",caretColor:"#fff"}}},variants:[{props:{size:"small"},style:{paddingTop:21,paddingBottom:4}},{props:({ownerState:e})=>e.hiddenLabel,style:{paddingTop:16,paddingBottom:17}},{props:({ownerState:e})=>e.startAdornment,style:{paddingLeft:0}},{props:({ownerState:e})=>e.endAdornment,style:{paddingRight:0}},{props:({ownerState:e})=>e.hiddenLabel&&e.size==="small",style:{paddingTop:8,paddingBottom:9}},{props:({ownerState:e})=>e.multiline,style:{paddingTop:0,paddingBottom:0,paddingLeft:0,paddingRight:0}}]}))),fd=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiFilledInput"}),{disableUnderline:o=!1,components:i={},componentsProps:s,fullWidth:a=!1,hiddenLabel:l,inputComponent:u="input",multiline:f=!1,slotProps:p,slots:g={},type:m="text",...y}=r,b={...r,disableUnderline:o,fullWidth:a,inputComponent:u,multiline:f,type:m},S=A3(r),C={root:{ownerState:b},input:{ownerState:b}},T=p??s?zn(C,p??s):C,_=g.root??i.Root??I3,w=g.input??i.Input??D3;return v.jsx(ud,{slots:{root:_,input:w},slotProps:T,fullWidth:a,inputComponent:u,multiline:f,ref:n,type:m,...y,classes:S})});process.env.NODE_ENV!=="production"&&(fd.propTypes={autoComplete:c.string,autoFocus:c.bool,classes:c.object,color:c.oneOfType([c.oneOf(["primary","secondary"]),c.string]),components:c.shape({Input:c.elementType,Root:c.elementType}),componentsProps:c.shape({input:c.object,root:c.object}),defaultValue:c.any,disabled:c.bool,disableUnderline:c.bool,endAdornment:c.node,error:c.bool,fullWidth:c.bool,hiddenLabel:c.bool,id:c.string,inputComponent:c.elementType,inputProps:c.object,inputRef:mn,margin:c.oneOf(["dense","none"]),maxRows:c.oneOfType([c.number,c.string]),minRows:c.oneOfType([c.number,c.string]),multiline:c.bool,name:c.string,onChange:c.func,placeholder:c.string,readOnly:c.bool,required:c.bool,rows:c.oneOfType([c.number,c.string]),slotProps:c.shape({input:c.object,root:c.object}),slots:c.shape({input:c.elementType,root:c.elementType}),startAdornment:c.node,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),type:c.string,value:c.any}),fd.muiName="Input";var tw;const P3=be("fieldset",{shouldForwardProp:ro})({textAlign:"left",position:"absolute",bottom:0,right:0,top:-5,left:0,margin:0,padding:"0 8px",pointerEvents:"none",borderRadius:"inherit",borderStyle:"solid",borderWidth:1,overflow:"hidden",minWidth:"0%"}),N3=be("legend",{shouldForwardProp:ro})(Dt(({theme:t})=>({float:"unset",width:"auto",overflow:"hidden",variants:[{props:({ownerState:e})=>!e.withLabel,style:{padding:0,lineHeight:"11px",transition:t.transitions.create("width",{duration:150,easing:t.transitions.easing.easeOut})}},{props:({ownerState:e})=>e.withLabel,style:{display:"block",padding:0,height:11,fontSize:"0.75em",visibility:"hidden",maxWidth:.01,transition:t.transitions.create("max-width",{duration:50,easing:t.transitions.easing.easeOut}),whiteSpace:"nowrap","& > span":{paddingLeft:5,paddingRight:5,display:"inline-block",opacity:0,visibility:"visible"}}},{props:({ownerState:e})=>e.withLabel&&e.notched,style:{maxWidth:"100%",transition:t.transitions.create("max-width",{duration:100,easing:t.transitions.easing.easeOut,delay:50})}}]})));function nw(t){const{children:e,classes:n,className:r,label:o,notched:i,...s}=t,a=o!=null&&o!=="",l={...t,notched:i,withLabel:a};return v.jsx(P3,{"aria-hidden":!0,className:r,ownerState:l,...s,children:v.jsx(N3,{ownerState:l,children:a?v.jsx("span",{children:o}):tw||(tw=v.jsx("span",{className:"notranslate","aria-hidden":!0,children:""}))})})}process.env.NODE_ENV!=="production"&&(nw.propTypes={children:c.node,classes:c.object,className:c.string,label:c.node,notched:c.bool.isRequired,style:c.object});function L3(t){return Ke("MuiOutlinedInput",t)}const So={...pa,...qe("MuiOutlinedInput",["root","notchedOutline","input"])},F3=t=>{const{classes:e}=t,r=Ue({root:["root"],notchedOutline:["notchedOutline"],input:["input"]},L3,e);return{...e,...r}},$3=be(ld,{shouldForwardProp:t=>ro(t)||t==="classes",name:"MuiOutlinedInput",slot:"Root",overridesResolver:sd})(Dt(({theme:t})=>{const e=t.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return{position:"relative",borderRadius:(t.vars||t).shape.borderRadius,[`&:hover .${So.notchedOutline}`]:{borderColor:(t.vars||t).palette.text.primary},"@media (hover: none)":{[`&:hover .${So.notchedOutline}`]:{borderColor:t.vars?`rgba(${t.vars.palette.common.onBackgroundChannel} / 0.23)`:e}},[`&.${So.focused} .${So.notchedOutline}`]:{borderWidth:2},variants:[...Object.entries(t.palette).filter(Hn()).map(([n])=>({props:{color:n},style:{[`&.${So.focused} .${So.notchedOutline}`]:{borderColor:(t.vars||t).palette[n].main}}})),{props:{},style:{[`&.${So.error} .${So.notchedOutline}`]:{borderColor:(t.vars||t).palette.error.main},[`&.${So.disabled} .${So.notchedOutline}`]:{borderColor:(t.vars||t).palette.action.disabled}}},{props:({ownerState:n})=>n.startAdornment,style:{paddingLeft:14}},{props:({ownerState:n})=>n.endAdornment,style:{paddingRight:14}},{props:({ownerState:n})=>n.multiline,style:{padding:"16.5px 14px"}},{props:({ownerState:n,size:r})=>n.multiline&&r==="small",style:{padding:"8.5px 14px"}}]}})),B3=be(nw,{name:"MuiOutlinedInput",slot:"NotchedOutline",overridesResolver:(t,e)=>e.notchedOutline})(Dt(({theme:t})=>{const e=t.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return{borderColor:t.vars?`rgba(${t.vars.palette.common.onBackgroundChannel} / 0.23)`:e}})),R3=be(cd,{name:"MuiOutlinedInput",slot:"Input",overridesResolver:ad})(Dt(({theme:t})=>({padding:"16.5px 14px",...!t.vars&&{"&:-webkit-autofill":{WebkitBoxShadow:t.palette.mode==="light"?null:"0 0 0 100px #266798 inset",WebkitTextFillColor:t.palette.mode==="light"?null:"#fff",caretColor:t.palette.mode==="light"?null:"#fff",borderRadius:"inherit"}},...t.vars&&{"&:-webkit-autofill":{borderRadius:"inherit"},[t.getColorSchemeSelector("dark")]:{"&:-webkit-autofill":{WebkitBoxShadow:"0 0 0 100px #266798 inset",WebkitTextFillColor:"#fff",caretColor:"#fff"}}},variants:[{props:{size:"small"},style:{padding:"8.5px 14px"}},{props:({ownerState:e})=>e.multiline,style:{padding:0}},{props:({ownerState:e})=>e.startAdornment,style:{paddingLeft:0}},{props:({ownerState:e})=>e.endAdornment,style:{paddingRight:0}}]}))),pd=I.forwardRef(function(e,n){var r;const o=St({props:e,name:"MuiOutlinedInput"}),{components:i={},fullWidth:s=!1,inputComponent:a="input",label:l,multiline:u=!1,notched:f,slots:p={},type:g="text",...m}=o,y=F3(o),b=io(),S=fa({props:o,muiFormControl:b,states:["color","disabled","error","focused","hiddenLabel","size","required"]}),C={...o,color:S.color||"primary",disabled:S.disabled,error:S.error,focused:S.focused,formControl:b,fullWidth:s,hiddenLabel:S.hiddenLabel,multiline:u,size:S.size,type:g},T=p.root??i.Root??$3,_=p.input??i.Input??R3;return v.jsx(ud,{slots:{root:T,input:_},renderSuffix:w=>v.jsx(B3,{ownerState:C,className:y.notchedOutline,label:l!=null&&l!==""&&S.required?r||(r=v.jsxs(I.Fragment,{children:[l," ","*"]})):l,notched:typeof f<"u"?f:!!(w.startAdornment||w.filled||w.focused)}),fullWidth:s,inputComponent:a,multiline:u,ref:n,type:g,...m,classes:{...y,notchedOutline:null}})});process.env.NODE_ENV!=="production"&&(pd.propTypes={autoComplete:c.string,autoFocus:c.bool,classes:c.object,color:c.oneOfType([c.oneOf(["primary","secondary"]),c.string]),components:c.shape({Input:c.elementType,Root:c.elementType}),defaultValue:c.any,disabled:c.bool,endAdornment:c.node,error:c.bool,fullWidth:c.bool,id:c.string,inputComponent:c.elementType,inputProps:c.object,inputRef:mn,label:c.node,margin:c.oneOf(["dense","none"]),maxRows:c.oneOfType([c.number,c.string]),minRows:c.oneOfType([c.number,c.string]),multiline:c.bool,name:c.string,notched:c.bool,onChange:c.func,placeholder:c.string,readOnly:c.bool,required:c.bool,rows:c.oneOfType([c.number,c.string]),slots:c.shape({input:c.elementType,root:c.elementType}),startAdornment:c.node,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),type:c.string,value:c.any}),pd.muiName="Input";function z3(t){return Ke("MuiFormLabel",t)}const zl=qe("MuiFormLabel",["root","colorSecondary","focused","disabled","error","filled","required","asterisk"]),V3=t=>{const{classes:e,color:n,focused:r,disabled:o,error:i,filled:s,required:a}=t,l={root:["root",`color${Ae(n)}`,o&&"disabled",i&&"error",s&&"filled",r&&"focused",a&&"required"],asterisk:["asterisk",i&&"error"]};return Ue(l,z3,e)},H3=be("label",{name:"MuiFormLabel",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,n.color==="secondary"&&e.colorSecondary,n.filled&&e.filled]}})(Dt(({theme:t})=>({color:(t.vars||t).palette.text.secondary,...t.typography.body1,lineHeight:"1.4375em",padding:0,position:"relative",variants:[...Object.entries(t.palette).filter(Hn()).map(([e])=>({props:{color:e},style:{[`&.${zl.focused}`]:{color:(t.vars||t).palette[e].main}}})),{props:{},style:{[`&.${zl.disabled}`]:{color:(t.vars||t).palette.text.disabled},[`&.${zl.error}`]:{color:(t.vars||t).palette.error.main}}}]}))),j3=be("span",{name:"MuiFormLabel",slot:"Asterisk",overridesResolver:(t,e)=>e.asterisk})(Dt(({theme:t})=>({[`&.${zl.error}`]:{color:(t.vars||t).palette.error.main}}))),rw=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiFormLabel"}),{children:o,className:i,color:s,component:a="label",disabled:l,error:u,filled:f,focused:p,required:g,...m}=r,y=io(),b=fa({props:r,muiFormControl:y,states:["color","required","focused","disabled","error","filled"]}),S={...r,color:b.color||"primary",component:a,disabled:b.disabled,error:b.error,filled:b.filled,focused:b.focused,required:b.required},C=V3(S);return v.jsxs(H3,{as:a,ownerState:S,className:Le(C.root,i),ref:n,...m,children:[o,b.required&&v.jsxs(j3,{ownerState:S,"aria-hidden":!0,className:C.asterisk,children:[" ","*"]})]})});process.env.NODE_ENV!=="production"&&(rw.propTypes={children:c.node,classes:c.object,className:c.string,color:c.oneOfType([c.oneOf(["error","info","primary","secondary","success","warning"]),c.string]),component:c.elementType,disabled:c.bool,error:c.bool,filled:c.bool,focused:c.bool,required:c.bool,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object])});function W3(t){return Ke("MuiInputLabel",t)}qe("MuiInputLabel",["root","focused","disabled","error","required","asterisk","formControl","sizeSmall","shrink","animated","standard","filled","outlined"]);const q3=t=>{const{classes:e,formControl:n,size:r,shrink:o,disableAnimation:i,variant:s,required:a}=t,l={root:["root",n&&"formControl",!i&&"animated",o&&"shrink",r&&r!=="normal"&&`size${Ae(r)}`,s],asterisk:[a&&"asterisk"]},u=Ue(l,W3,e);return{...e,...u}},U3=be(rw,{shouldForwardProp:t=>ro(t)||t==="classes",name:"MuiInputLabel",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[{[`& .${zl.asterisk}`]:e.asterisk},e.root,n.formControl&&e.formControl,n.size==="small"&&e.sizeSmall,n.shrink&&e.shrink,!n.disableAnimation&&e.animated,n.focused&&e.focused,e[n.variant]]}})(Dt(({theme:t})=>({display:"block",transformOrigin:"top left",whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",maxWidth:"100%",variants:[{props:({ownerState:e})=>e.formControl,style:{position:"absolute",left:0,top:0,transform:"translate(0, 20px) scale(1)"}},{props:{size:"small"},style:{transform:"translate(0, 17px) scale(1)"}},{props:({ownerState:e})=>e.shrink,style:{transform:"translate(0, -1.5px) scale(0.75)",transformOrigin:"top left",maxWidth:"133%"}},{props:({ownerState:e})=>!e.disableAnimation,style:{transition:t.transitions.create(["color","transform","max-width"],{duration:t.transitions.duration.shorter,easing:t.transitions.easing.easeOut})}},{props:{variant:"filled"},style:{zIndex:1,pointerEvents:"none",transform:"translate(12px, 16px) scale(1)",maxWidth:"calc(100% - 24px)"}},{props:{variant:"filled",size:"small"},style:{transform:"translate(12px, 13px) scale(1)"}},{props:({variant:e,ownerState:n})=>e==="filled"&&n.shrink,style:{userSelect:"none",pointerEvents:"auto",transform:"translate(12px, 7px) scale(0.75)",maxWidth:"calc(133% - 24px)"}},{props:({variant:e,ownerState:n,size:r})=>e==="filled"&&n.shrink&&r==="small",style:{transform:"translate(12px, 4px) scale(0.75)"}},{props:{variant:"outlined"},style:{zIndex:1,pointerEvents:"none",transform:"translate(14px, 16px) scale(1)",maxWidth:"calc(100% - 24px)"}},{props:{variant:"outlined",size:"small"},style:{transform:"translate(14px, 9px) scale(1)"}},{props:({variant:e,ownerState:n})=>e==="outlined"&&n.shrink,style:{userSelect:"none",pointerEvents:"auto",maxWidth:"calc(133% - 32px)",transform:"translate(14px, -9px) scale(0.75)"}}]}))),cg=I.forwardRef(function(e,n){const r=St({name:"MuiInputLabel",props:e}),{disableAnimation:o=!1,margin:i,shrink:s,variant:a,className:l,...u}=r,f=io();let p=s;typeof p>"u"&&f&&(p=f.filled||f.focused||f.adornedStart);const g=fa({props:r,muiFormControl:f,states:["size","variant","required","focused"]}),m={...r,disableAnimation:o,formControl:f,shrink:p,size:g.size,variant:g.variant,required:g.required,focused:g.focused},y=q3(m);return v.jsx(U3,{"data-shrink":p,ref:n,className:Le(y.root,l),...u,ownerState:m,classes:y})});process.env.NODE_ENV!=="production"&&(cg.propTypes={children:c.node,classes:c.object,className:c.string,color:c.oneOfType([c.oneOf(["error","info","primary","secondary","success","warning"]),c.string]),disableAnimation:c.bool,disabled:c.bool,error:c.bool,focused:c.bool,margin:c.oneOf(["dense"]),required:c.bool,shrink:c.bool,size:c.oneOfType([c.oneOf(["normal","small"]),c.string]),sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),variant:c.oneOf(["filled","outlined","standard"])});function K3(t){return Ke("MuiFormControl",t)}qe("MuiFormControl",["root","marginNone","marginNormal","marginDense","fullWidth","disabled"]);const Y3=t=>{const{classes:e,margin:n,fullWidth:r}=t,o={root:["root",n!=="none"&&`margin${Ae(n)}`,r&&"fullWidth"]};return Ue(o,K3,e)},G3=be("div",{name:"MuiFormControl",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,e[`margin${Ae(n.margin)}`],n.fullWidth&&e.fullWidth]}})({display:"inline-flex",flexDirection:"column",position:"relative",minWidth:0,padding:0,margin:0,border:0,verticalAlign:"top",variants:[{props:{margin:"normal"},style:{marginTop:16,marginBottom:8}},{props:{margin:"dense"},style:{marginTop:8,marginBottom:4}},{props:{fullWidth:!0},style:{width:"100%"}}]}),ug=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiFormControl"}),{children:o,className:i,color:s="primary",component:a="div",disabled:l=!1,error:u=!1,focused:f,fullWidth:p=!1,hiddenLabel:g=!1,margin:m="none",required:y=!1,size:b="medium",variant:S="outlined",...C}=r,T={...r,color:s,component:a,disabled:l,error:u,fullWidth:p,hiddenLabel:g,margin:m,required:y,size:b,variant:S},_=Y3(T),[w,E]=I.useState(()=>{let R=!1;return o&&I.Children.forEach(o,q=>{if(!Sl(q,["Input","Select"]))return;const U=Sl(q,["Select"])?q.props.input:q;U&&x3(U.props)&&(R=!0)}),R}),[O,L]=I.useState(()=>{let R=!1;return o&&I.Children.forEach(o,q=>{Sl(q,["Input","Select"])&&(id(q.props,!0)||id(q.props.inputProps,!0))&&(R=!0)}),R}),[P,$]=I.useState(!1);l&&P&&$(!1);const M=f!==void 0&&!l?f:P;let A;const N=I.useRef(!1);process.env.NODE_ENV!=="production"&&(A=()=>(N.current&&console.error(["MUI: There are multiple `InputBase` components inside a FormControl.","This creates visual inconsistencies, only use one `InputBase`."].join(`
|
|
112
|
+
`)),N.current=!0,()=>{N.current=!1}));const z=I.useCallback(()=>{L(!0)},[]),V=I.useCallback(()=>{L(!1)},[]),B=I.useMemo(()=>({adornedStart:w,setAdornedStart:E,color:s,disabled:l,error:u,filled:O,focused:M,fullWidth:p,hiddenLabel:g,size:b,onBlur:()=>{$(!1)},onFocus:()=>{$(!0)},onEmpty:V,onFilled:z,registerEffect:A,required:y,variant:S}),[w,s,l,u,O,M,p,g,A,V,z,y,b,S]);return v.jsx(Bl.Provider,{value:B,children:v.jsx(G3,{as:a,ownerState:T,className:Le(_.root,i),ref:n,...C,children:o})})});process.env.NODE_ENV!=="production"&&(ug.propTypes={children:c.node,classes:c.object,className:c.string,color:c.oneOfType([c.oneOf(["primary","secondary","error","info","success","warning"]),c.string]),component:c.elementType,disabled:c.bool,error:c.bool,focused:c.bool,fullWidth:c.bool,hiddenLabel:c.bool,margin:c.oneOf(["dense","none","normal"]),required:c.bool,size:c.oneOfType([c.oneOf(["medium","small"]),c.string]),sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),variant:c.oneOf(["filled","outlined","standard"])});function J3(t){return Ke("MuiFormHelperText",t)}const ow=qe("MuiFormHelperText",["root","error","disabled","sizeSmall","sizeMedium","contained","focused","filled","required"]);var iw;const Z3=t=>{const{classes:e,contained:n,size:r,disabled:o,error:i,filled:s,focused:a,required:l}=t,u={root:["root",o&&"disabled",i&&"error",r&&`size${Ae(r)}`,n&&"contained",a&&"focused",s&&"filled",l&&"required"]};return Ue(u,J3,e)},X3=be("p",{name:"MuiFormHelperText",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,n.size&&e[`size${Ae(n.size)}`],n.contained&&e.contained,n.filled&&e.filled]}})(Dt(({theme:t})=>({color:(t.vars||t).palette.text.secondary,...t.typography.caption,textAlign:"left",marginTop:3,marginRight:0,marginBottom:0,marginLeft:0,[`&.${ow.disabled}`]:{color:(t.vars||t).palette.text.disabled},[`&.${ow.error}`]:{color:(t.vars||t).palette.error.main},variants:[{props:{size:"small"},style:{marginTop:4}},{props:({ownerState:e})=>e.contained,style:{marginLeft:14,marginRight:14}}]}))),dg=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiFormHelperText"}),{children:o,className:i,component:s="p",disabled:a,error:l,filled:u,focused:f,margin:p,required:g,variant:m,...y}=r,b=io(),S=fa({props:r,muiFormControl:b,states:["variant","size","disabled","error","filled","focused","required"]}),C={...r,component:s,contained:S.variant==="filled"||S.variant==="outlined",variant:S.variant,size:S.size,disabled:S.disabled,error:S.error,filled:S.filled,focused:S.focused,required:S.required};delete C.ownerState;const T=Z3(C);return v.jsx(X3,{as:s,className:Le(T.root,i),ref:n,...y,ownerState:C,children:o===" "?iw||(iw=v.jsx("span",{className:"notranslate","aria-hidden":!0,children:""})):o})});process.env.NODE_ENV!=="production"&&(dg.propTypes={children:c.node,classes:c.object,className:c.string,component:c.elementType,disabled:c.bool,error:c.bool,filled:c.bool,focused:c.bool,margin:c.oneOf(["dense"]),required:c.bool,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),variant:c.oneOfType([c.oneOf(["filled","outlined","standard"]),c.string])});const ha=I.createContext({});process.env.NODE_ENV!=="production"&&(ha.displayName="ListContext");function Q3(t){return Ke("MuiList",t)}qe("MuiList",["root","padding","dense","subheader"]);const ez=t=>{const{classes:e,disablePadding:n,dense:r,subheader:o}=t;return Ue({root:["root",!n&&"padding",r&&"dense",o&&"subheader"]},Q3,e)},tz=be("ul",{name:"MuiList",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,!n.disablePadding&&e.padding,n.dense&&e.dense,n.subheader&&e.subheader]}})({listStyle:"none",margin:0,padding:0,position:"relative",variants:[{props:({ownerState:t})=>!t.disablePadding,style:{paddingTop:8,paddingBottom:8}},{props:({ownerState:t})=>t.subheader,style:{paddingTop:0}}]}),fg=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiList"}),{children:o,className:i,component:s="ul",dense:a=!1,disablePadding:l=!1,subheader:u,...f}=r,p=I.useMemo(()=>({dense:a}),[a]),g={...r,component:s,dense:a,disablePadding:l},m=ez(g);return v.jsx(ha.Provider,{value:p,children:v.jsxs(tz,{as:s,className:Le(m.root,i),ref:n,ownerState:g,...f,children:[u,o]})})});process.env.NODE_ENV!=="production"&&(fg.propTypes={children:c.node,classes:c.object,className:c.string,component:c.elementType,dense:c.bool,disablePadding:c.bool,subheader:c.node,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object])});function pg(t,e,n){return t===e?t.firstChild:e&&e.nextElementSibling?e.nextElementSibling:n?null:t.firstChild}function sw(t,e,n){return t===e?n?t.firstChild:t.lastChild:e&&e.previousElementSibling?e.previousElementSibling:n?null:t.lastChild}function aw(t,e){if(e===void 0)return!0;let n=t.innerText;return n===void 0&&(n=t.textContent),n=n.trim().toLowerCase(),n.length===0?!1:e.repeating?n[0]===e.keys[0]:n.startsWith(e.keys.join(""))}function Vl(t,e,n,r,o,i){let s=!1,a=o(t,e,e?n:!1);for(;a;){if(a===t.firstChild){if(s)return!1;s=!0}const l=r?!1:a.disabled||a.getAttribute("aria-disabled")==="true";if(!a.hasAttribute("tabindex")||!aw(a,i)||l)a=o(t,a,n);else return a.focus(),!0}return!1}const lw=I.forwardRef(function(e,n){const{actions:r,autoFocus:o=!1,autoFocusItem:i=!1,children:s,className:a,disabledItemsFocusable:l=!1,disableListWrap:u=!1,onKeyDown:f,variant:p="selectedMenu",...g}=e,m=I.useRef(null),y=I.useRef({keys:[],repeating:!0,previousKeyMatched:!0,lastTime:null});Tn(()=>{o&&m.current.focus()},[o]),I.useImperativeHandle(r,()=>({adjustStyleForScrollbar:(_,{direction:w})=>{const E=!m.current.style.width;if(_.clientHeight<m.current.clientHeight&&E){const O=`${vS(Ho(_))}px`;m.current.style[w==="rtl"?"paddingLeft":"paddingRight"]=O,m.current.style.width=`calc(100% + ${O})`}return m.current}}),[]);const b=_=>{const w=m.current,E=_.key;if(_.ctrlKey||_.metaKey||_.altKey){f&&f(_);return}const L=Vn(w).activeElement;if(E==="ArrowDown")_.preventDefault(),Vl(w,L,u,l,pg);else if(E==="ArrowUp")_.preventDefault(),Vl(w,L,u,l,sw);else if(E==="Home")_.preventDefault(),Vl(w,null,u,l,pg);else if(E==="End")_.preventDefault(),Vl(w,null,u,l,sw);else if(E.length===1){const P=y.current,$=E.toLowerCase(),M=performance.now();P.keys.length>0&&(M-P.lastTime>500?(P.keys=[],P.repeating=!0,P.previousKeyMatched=!0):P.repeating&&$!==P.keys[0]&&(P.repeating=!1)),P.lastTime=M,P.keys.push($);const A=L&&!P.repeating&&aw(L,P);P.previousKeyMatched&&(A||Vl(w,L,!1,l,pg,P))?_.preventDefault():P.previousKeyMatched=!1}f&&f(_)},S=Et(m,n);let C=-1;I.Children.forEach(s,(_,w)=>{if(!I.isValidElement(_)){C===w&&(C+=1,C>=s.length&&(C=-1));return}process.env.NODE_ENV!=="production"&&cs.isFragment(_)&&console.error(["MUI: The Menu component doesn't accept a Fragment as a child.","Consider providing an array instead."].join(`
|
|
113
|
+
`)),_.props.disabled||(p==="selectedMenu"&&_.props.selected||C===-1)&&(C=w),C===w&&(_.props.disabled||_.props.muiSkipListHighlight||_.type.muiSkipListHighlight)&&(C+=1,C>=s.length&&(C=-1))});const T=I.Children.map(s,(_,w)=>{if(w===C){const E={};return i&&(E.autoFocus=!0),_.props.tabIndex===void 0&&p==="selectedMenu"&&(E.tabIndex=0),I.cloneElement(_,E)}return _});return v.jsx(fg,{role:"menu",ref:S,className:a,onKeyDown:b,tabIndex:o?0:-1,...g,children:T})});process.env.NODE_ENV!=="production"&&(lw.propTypes={autoFocus:c.bool,autoFocusItem:c.bool,children:c.node,className:c.string,disabledItemsFocusable:c.bool,disableListWrap:c.bool,onKeyDown:c.func,variant:c.oneOf(["menu","selectedMenu"])});function hg(t,e){return hg=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,r){return n.__proto__=r,n},hg(t,e)}function gg(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,hg(t,e)}function nz(t,e){return t.classList?!!e&&t.classList.contains(e):(" "+(t.className.baseVal||t.className)+" ").indexOf(" "+e+" ")!==-1}function rz(t,e){t.classList?t.classList.add(e):nz(t,e)||(typeof t.className=="string"?t.className=t.className+" "+e:t.setAttribute("class",(t.className&&t.className.baseVal||"")+" "+e))}function cw(t,e){return t.replace(new RegExp("(^|\\s)"+e+"(?:\\s|$)","g"),"$1").replace(/\s+/g," ").replace(/^\s*|\s*$/g,"")}function oz(t,e){t.classList?t.classList.remove(e):typeof t.className=="string"?t.className=cw(t.className,e):t.setAttribute("class",cw(t.className&&t.className.baseVal||"",e))}const uw={disabled:!1};var iz=process.env.NODE_ENV!=="production"?c.oneOfType([c.number,c.shape({enter:c.number,exit:c.number,appear:c.number}).isRequired]):null,sz=process.env.NODE_ENV!=="production"?c.oneOfType([c.string,c.shape({enter:c.string,exit:c.string,active:c.string}),c.shape({enter:c.string,enterDone:c.string,enterActive:c.string,exit:c.string,exitDone:c.string,exitActive:c.string})]):null;const hd=J.createContext(null);var dw=function(e){return e.scrollTop},Hl="unmounted",fs="exited",ps="entering",ga="entered",mg="exiting",Pr=function(t){gg(e,t);function e(r,o){var i;i=t.call(this,r,o)||this;var s=o,a=s&&!s.isMounting?r.enter:r.appear,l;return i.appearStatus=null,r.in?a?(l=fs,i.appearStatus=ps):l=ga:r.unmountOnExit||r.mountOnEnter?l=Hl:l=fs,i.state={status:l},i.nextCallback=null,i}e.getDerivedStateFromProps=function(o,i){var s=o.in;return s&&i.status===Hl?{status:fs}:null};var n=e.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(o){var i=null;if(o!==this.props){var s=this.state.status;this.props.in?s!==ps&&s!==ga&&(i=ps):(s===ps||s===ga)&&(i=mg)}this.updateStatus(!1,i)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var o=this.props.timeout,i,s,a;return i=s=a=o,o!=null&&typeof o!="number"&&(i=o.exit,s=o.enter,a=o.appear!==void 0?o.appear:s),{exit:i,enter:s,appear:a}},n.updateStatus=function(o,i){if(o===void 0&&(o=!1),i!==null)if(this.cancelNextCallback(),i===ps){if(this.props.unmountOnExit||this.props.mountOnEnter){var s=this.props.nodeRef?this.props.nodeRef.current:ls.findDOMNode(this);s&&dw(s)}this.performEnter(o)}else this.performExit();else this.props.unmountOnExit&&this.state.status===fs&&this.setState({status:Hl})},n.performEnter=function(o){var i=this,s=this.props.enter,a=this.context?this.context.isMounting:o,l=this.props.nodeRef?[a]:[ls.findDOMNode(this),a],u=l[0],f=l[1],p=this.getTimeouts(),g=a?p.appear:p.enter;if(!o&&!s||uw.disabled){this.safeSetState({status:ga},function(){i.props.onEntered(u)});return}this.props.onEnter(u,f),this.safeSetState({status:ps},function(){i.props.onEntering(u,f),i.onTransitionEnd(g,function(){i.safeSetState({status:ga},function(){i.props.onEntered(u,f)})})})},n.performExit=function(){var o=this,i=this.props.exit,s=this.getTimeouts(),a=this.props.nodeRef?void 0:ls.findDOMNode(this);if(!i||uw.disabled){this.safeSetState({status:fs},function(){o.props.onExited(a)});return}this.props.onExit(a),this.safeSetState({status:mg},function(){o.props.onExiting(a),o.onTransitionEnd(s.exit,function(){o.safeSetState({status:fs},function(){o.props.onExited(a)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(o,i){i=this.setNextCallback(i),this.setState(o,i)},n.setNextCallback=function(o){var i=this,s=!0;return this.nextCallback=function(a){s&&(s=!1,i.nextCallback=null,o(a))},this.nextCallback.cancel=function(){s=!1},this.nextCallback},n.onTransitionEnd=function(o,i){this.setNextCallback(i);var s=this.props.nodeRef?this.props.nodeRef.current:ls.findDOMNode(this),a=o==null&&!this.props.addEndListener;if(!s||a){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var l=this.props.nodeRef?[this.nextCallback]:[s,this.nextCallback],u=l[0],f=l[1];this.props.addEndListener(u,f)}o!=null&&setTimeout(this.nextCallback,o)},n.render=function(){var o=this.state.status;if(o===Hl)return null;var i=this.props,s=i.children;i.in,i.mountOnEnter,i.unmountOnExit,i.appear,i.enter,i.exit,i.timeout,i.addEndListener,i.onEnter,i.onEntering,i.onEntered,i.onExit,i.onExiting,i.onExited,i.nodeRef;var a=rt(i,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return J.createElement(hd.Provider,{value:null},typeof s=="function"?s(o,a):J.cloneElement(J.Children.only(s),a))},e}(J.Component);Pr.contextType=hd,Pr.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:c.shape({current:typeof Element>"u"?c.any:function(t,e,n,r,o,i){var s=t[e];return c.instanceOf(s&&"ownerDocument"in s?s.ownerDocument.defaultView.Element:Element)(t,e,n,r,o,i)}}),children:c.oneOfType([c.func.isRequired,c.element.isRequired]).isRequired,in:c.bool,mountOnEnter:c.bool,unmountOnExit:c.bool,appear:c.bool,enter:c.bool,exit:c.bool,timeout:function(e){var n=iz;e.addEndListener||(n=n.isRequired);for(var r=arguments.length,o=new Array(r>1?r-1:0),i=1;i<r;i++)o[i-1]=arguments[i];return n.apply(void 0,[e].concat(o))},addEndListener:c.func,onEnter:c.func,onEntering:c.func,onEntered:c.func,onExit:c.func,onExiting:c.func,onExited:c.func}:{};function ma(){}Pr.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:ma,onEntering:ma,onEntered:ma,onExit:ma,onExiting:ma,onExited:ma},Pr.UNMOUNTED=Hl,Pr.EXITED=fs,Pr.ENTERING=ps,Pr.ENTERED=ga,Pr.EXITING=mg;var az=function(e,n){return e&&n&&n.split(" ").forEach(function(r){return rz(e,r)})},yg=function(e,n){return e&&n&&n.split(" ").forEach(function(r){return oz(e,r)})},bg=function(t){gg(e,t);function e(){for(var r,o=arguments.length,i=new Array(o),s=0;s<o;s++)i[s]=arguments[s];return r=t.call.apply(t,[this].concat(i))||this,r.appliedClasses={appear:{},enter:{},exit:{}},r.onEnter=function(a,l){var u=r.resolveArguments(a,l),f=u[0],p=u[1];r.removeClasses(f,"exit"),r.addClass(f,p?"appear":"enter","base"),r.props.onEnter&&r.props.onEnter(a,l)},r.onEntering=function(a,l){var u=r.resolveArguments(a,l),f=u[0],p=u[1],g=p?"appear":"enter";r.addClass(f,g,"active"),r.props.onEntering&&r.props.onEntering(a,l)},r.onEntered=function(a,l){var u=r.resolveArguments(a,l),f=u[0],p=u[1],g=p?"appear":"enter";r.removeClasses(f,g),r.addClass(f,g,"done"),r.props.onEntered&&r.props.onEntered(a,l)},r.onExit=function(a){var l=r.resolveArguments(a),u=l[0];r.removeClasses(u,"appear"),r.removeClasses(u,"enter"),r.addClass(u,"exit","base"),r.props.onExit&&r.props.onExit(a)},r.onExiting=function(a){var l=r.resolveArguments(a),u=l[0];r.addClass(u,"exit","active"),r.props.onExiting&&r.props.onExiting(a)},r.onExited=function(a){var l=r.resolveArguments(a),u=l[0];r.removeClasses(u,"exit"),r.addClass(u,"exit","done"),r.props.onExited&&r.props.onExited(a)},r.resolveArguments=function(a,l){return r.props.nodeRef?[r.props.nodeRef.current,a]:[a,l]},r.getClassNames=function(a){var l=r.props.classNames,u=typeof l=="string",f=u&&l?l+"-":"",p=u?""+f+a:l[a],g=u?p+"-active":l[a+"Active"],m=u?p+"-done":l[a+"Done"];return{baseClassName:p,activeClassName:g,doneClassName:m}},r}var n=e.prototype;return n.addClass=function(o,i,s){var a=this.getClassNames(i)[s+"ClassName"],l=this.getClassNames("enter"),u=l.doneClassName;i==="appear"&&s==="done"&&u&&(a+=" "+u),s==="active"&&o&&dw(o),a&&(this.appliedClasses[i][s]=a,az(o,a))},n.removeClasses=function(o,i){var s=this.appliedClasses[i],a=s.base,l=s.active,u=s.done;this.appliedClasses[i]={},a&&yg(o,a),l&&yg(o,l),u&&yg(o,u)},n.render=function(){var o=this.props;o.classNames;var i=rt(o,["classNames"]);return J.createElement(Pr,ne({},i,{onEnter:this.onEnter,onEntered:this.onEntered,onEntering:this.onEntering,onExit:this.onExit,onExiting:this.onExiting,onExited:this.onExited}))},e}(J.Component);bg.defaultProps={classNames:""},bg.propTypes=process.env.NODE_ENV!=="production"?ne({},Pr.propTypes,{classNames:sz,onEnter:c.func,onEntering:c.func,onEntered:c.func,onExit:c.func,onExiting:c.func,onExited:c.func}):{};function lz(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function vg(t,e){var n=function(i){return e&&J.isValidElement(i)?e(i):i},r=Object.create(null);return t&&J.Children.map(t,function(o){return o}).forEach(function(o){r[o.key]=n(o)}),r}function cz(t,e){t=t||{},e=e||{};function n(f){return f in e?e[f]:t[f]}var r=Object.create(null),o=[];for(var i in t)i in e?o.length&&(r[i]=o,o=[]):o.push(i);var s,a={};for(var l in e){if(r[l])for(s=0;s<r[l].length;s++){var u=r[l][s];a[r[l][s]]=n(u)}a[l]=n(l)}for(s=0;s<o.length;s++)a[o[s]]=n(o[s]);return a}function hs(t,e,n){return n[e]!=null?n[e]:t.props[e]}function uz(t,e){return vg(t.children,function(n){return J.cloneElement(n,{onExited:e.bind(null,n),in:!0,appear:hs(n,"appear",t),enter:hs(n,"enter",t),exit:hs(n,"exit",t)})})}function dz(t,e,n){var r=vg(t.children),o=cz(e,r);return Object.keys(o).forEach(function(i){var s=o[i];if(J.isValidElement(s)){var a=i in e,l=i in r,u=e[i],f=J.isValidElement(u)&&!u.props.in;l&&(!a||f)?o[i]=J.cloneElement(s,{onExited:n.bind(null,s),in:!0,exit:hs(s,"exit",t),enter:hs(s,"enter",t)}):!l&&a&&!f?o[i]=J.cloneElement(s,{in:!1}):l&&a&&J.isValidElement(u)&&(o[i]=J.cloneElement(s,{onExited:n.bind(null,s),in:u.props.in,exit:hs(s,"exit",t),enter:hs(s,"enter",t)}))}}),o}var fz=Object.values||function(t){return Object.keys(t).map(function(e){return t[e]})},pz={component:"div",childFactory:function(e){return e}},jl=function(t){gg(e,t);function e(r,o){var i;i=t.call(this,r,o)||this;var s=i.handleExited.bind(lz(i));return i.state={contextValue:{isMounting:!0},handleExited:s,firstRender:!0},i}var n=e.prototype;return n.componentDidMount=function(){this.mounted=!0,this.setState({contextValue:{isMounting:!1}})},n.componentWillUnmount=function(){this.mounted=!1},e.getDerivedStateFromProps=function(o,i){var s=i.children,a=i.handleExited,l=i.firstRender;return{children:l?uz(o,a):dz(o,s,a),firstRender:!1}},n.handleExited=function(o,i){var s=vg(this.props.children);o.key in s||(o.props.onExited&&o.props.onExited(i),this.mounted&&this.setState(function(a){var l=ne({},a.children);return delete l[o.key],{children:l}}))},n.render=function(){var o=this.props,i=o.component,s=o.childFactory,a=rt(o,["component","childFactory"]),l=this.state.contextValue,u=fz(this.state.children).map(s);return delete a.appear,delete a.enter,delete a.exit,i===null?J.createElement(hd.Provider,{value:l},u):J.createElement(hd.Provider,{value:l},J.createElement(i,a,u))},e}(J.Component);jl.propTypes=process.env.NODE_ENV!=="production"?{component:c.any,children:c.node,appear:c.bool,enter:c.bool,exit:c.bool,childFactory:c.func}:{},jl.defaultProps=pz;const fw=t=>t.scrollTop;function gd(t,e){const{timeout:n,easing:r,style:o={}}=t;return{duration:o.transitionDuration??(typeof n=="number"?n:n[e.mode]||0),easing:o.transitionTimingFunction??(typeof r=="object"?r[e.mode]:r),delay:o.transitionDelay}}function xg(t){return`scale(${t}, ${t**2})`}const hz={entering:{opacity:1,transform:xg(1)},entered:{opacity:1,transform:"none"}},Sg=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),Wl=I.forwardRef(function(e,n){const{addEndListener:r,appear:o=!0,children:i,easing:s,in:a,onEnter:l,onEntered:u,onEntering:f,onExit:p,onExited:g,onExiting:m,style:y,timeout:b="auto",TransitionComponent:S=Pr,...C}=e,T=yS(),_=I.useRef(),w=Si(),E=I.useRef(null),O=Et(E,wl(i),n),L=B=>R=>{if(B){const q=E.current;R===void 0?B(q):B(q,R)}},P=L(f),$=L((B,R)=>{fw(B);const{duration:q,delay:U,easing:G}=gd({style:y,timeout:b,easing:s},{mode:"enter"});let Y;b==="auto"?(Y=w.transitions.getAutoHeightDuration(B.clientHeight),_.current=Y):Y=q,B.style.transition=[w.transitions.create("opacity",{duration:Y,delay:U}),w.transitions.create("transform",{duration:Sg?Y:Y*.666,delay:U,easing:G})].join(","),l&&l(B,R)}),M=L(u),A=L(m),N=L(B=>{const{duration:R,delay:q,easing:U}=gd({style:y,timeout:b,easing:s},{mode:"exit"});let G;b==="auto"?(G=w.transitions.getAutoHeightDuration(B.clientHeight),_.current=G):G=R,B.style.transition=[w.transitions.create("opacity",{duration:G,delay:q}),w.transitions.create("transform",{duration:Sg?G:G*.666,delay:Sg?q:q||G*.333,easing:U})].join(","),B.style.opacity=0,B.style.transform=xg(.75),p&&p(B)}),z=L(g),V=B=>{b==="auto"&&T.start(_.current||0,B),r&&r(E.current,B)};return v.jsx(S,{appear:o,in:a,nodeRef:E,onEnter:$,onEntered:M,onEntering:P,onExit:N,onExited:z,onExiting:A,addEndListener:V,timeout:b==="auto"?null:b,...C,children:(B,{ownerState:R,...q})=>I.cloneElement(i,{style:{opacity:0,transform:xg(.75),visibility:B==="exited"&&!a?"hidden":void 0,...hz[B],...y,...i.props.style},ref:O,...q})})});process.env.NODE_ENV!=="production"&&(Wl.propTypes={addEndListener:c.func,appear:c.bool,children:xl.isRequired,easing:c.oneOfType([c.shape({enter:c.string,exit:c.string}),c.string]),in:c.bool,onEnter:c.func,onEntered:c.func,onEntering:c.func,onExit:c.func,onExited:c.func,onExiting:c.func,style:c.object,timeout:c.oneOfType([c.oneOf(["auto"]),c.number,c.shape({appear:c.number,enter:c.number,exit:c.number})])}),Wl&&(Wl.muiSupportAuto=!0);function gz(t){const e=Vn(t);return e.body===t?Ho(t).innerWidth>e.documentElement.clientWidth:t.scrollHeight>t.clientHeight}function ql(t,e){e?t.setAttribute("aria-hidden","true"):t.removeAttribute("aria-hidden")}function pw(t){return parseInt(Ho(t).getComputedStyle(t).paddingRight,10)||0}function mz(t){const n=["TEMPLATE","SCRIPT","STYLE","LINK","MAP","META","NOSCRIPT","PICTURE","COL","COLGROUP","PARAM","SLOT","SOURCE","TRACK"].includes(t.tagName),r=t.tagName==="INPUT"&&t.getAttribute("type")==="hidden";return n||r}function hw(t,e,n,r,o){const i=[e,n,...r];[].forEach.call(t.children,s=>{const a=!i.includes(s),l=!mz(s);a&&l&&ql(s,o)})}function Cg(t,e){let n=-1;return t.some((r,o)=>e(r)?(n=o,!0):!1),n}function yz(t,e){const n=[],r=t.container;if(!e.disableScrollLock){if(gz(r)){const s=vS(Ho(r));n.push({value:r.style.paddingRight,property:"padding-right",el:r}),r.style.paddingRight=`${pw(r)+s}px`;const a=Vn(r).querySelectorAll(".mui-fixed");[].forEach.call(a,l=>{n.push({value:l.style.paddingRight,property:"padding-right",el:l}),l.style.paddingRight=`${pw(l)+s}px`})}let i;if(r.parentNode instanceof DocumentFragment)i=Vn(r).body;else{const s=r.parentElement,a=Ho(r);i=(s==null?void 0:s.nodeName)==="HTML"&&a.getComputedStyle(s).overflowY==="scroll"?s:r}n.push({value:i.style.overflow,property:"overflow",el:i},{value:i.style.overflowX,property:"overflow-x",el:i},{value:i.style.overflowY,property:"overflow-y",el:i}),i.style.overflow="hidden"}return()=>{n.forEach(({value:i,el:s,property:a})=>{i?s.style.setProperty(a,i):s.style.removeProperty(a)})}}function bz(t){const e=[];return[].forEach.call(t.children,n=>{n.getAttribute("aria-hidden")==="true"&&e.push(n)}),e}class vz{constructor(){this.modals=[],this.containers=[]}add(e,n){let r=this.modals.indexOf(e);if(r!==-1)return r;r=this.modals.length,this.modals.push(e),e.modalRef&&ql(e.modalRef,!1);const o=bz(n);hw(n,e.mount,e.modalRef,o,!0);const i=Cg(this.containers,s=>s.container===n);return i!==-1?(this.containers[i].modals.push(e),r):(this.containers.push({modals:[e],container:n,restore:null,hiddenSiblings:o}),r)}mount(e,n){const r=Cg(this.containers,i=>i.modals.includes(e)),o=this.containers[r];o.restore||(o.restore=yz(o,n))}remove(e,n=!0){const r=this.modals.indexOf(e);if(r===-1)return r;const o=Cg(this.containers,s=>s.modals.includes(e)),i=this.containers[o];if(i.modals.splice(i.modals.indexOf(e),1),this.modals.splice(r,1),i.modals.length===0)i.restore&&i.restore(),e.modalRef&&ql(e.modalRef,n),hw(i.container,e.mount,e.modalRef,i.hiddenSiblings,!1),this.containers.splice(o,1);else{const s=i.modals[i.modals.length-1];s.modalRef&&ql(s.modalRef,!1)}return r}isTopModal(e){return this.modals.length>0&&this.modals[this.modals.length-1]===e}}const xz=["input","select","textarea","a[href]","button","[tabindex]","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'].join(",");function Sz(t){const e=parseInt(t.getAttribute("tabindex")||"",10);return Number.isNaN(e)?t.contentEditable==="true"||(t.nodeName==="AUDIO"||t.nodeName==="VIDEO"||t.nodeName==="DETAILS")&&t.getAttribute("tabindex")===null?0:t.tabIndex:e}function Cz(t){if(t.tagName!=="INPUT"||t.type!=="radio"||!t.name)return!1;const e=r=>t.ownerDocument.querySelector(`input[type="radio"]${r}`);let n=e(`[name="${t.name}"]:checked`);return n||(n=e(`[name="${t.name}"]`)),n!==t}function wz(t){return!(t.disabled||t.tagName==="INPUT"&&t.type==="hidden"||Cz(t))}function _z(t){const e=[],n=[];return Array.from(t.querySelectorAll(xz)).forEach((r,o)=>{const i=Sz(r);i===-1||!wz(r)||(i===0?e.push(r):n.push({documentOrder:o,tabIndex:i,node:r}))}),n.sort((r,o)=>r.tabIndex===o.tabIndex?r.documentOrder-o.documentOrder:r.tabIndex-o.tabIndex).map(r=>r.node).concat(e)}function Tz(){return!0}function Ul(t){const{children:e,disableAutoFocus:n=!1,disableEnforceFocus:r=!1,disableRestoreFocus:o=!1,getTabbable:i=_z,isEnabled:s=Tz,open:a}=t,l=I.useRef(!1),u=I.useRef(null),f=I.useRef(null),p=I.useRef(null),g=I.useRef(null),m=I.useRef(!1),y=I.useRef(null),b=Et(wl(e),y),S=I.useRef(null);I.useEffect(()=>{!a||!y.current||(m.current=!n)},[n,a]),I.useEffect(()=>{if(!a||!y.current)return;const _=Vn(y.current);return y.current.contains(_.activeElement)||(y.current.hasAttribute("tabIndex")||(process.env.NODE_ENV!=="production"&&console.error(["MUI: The modal content node does not accept focus.",'For the benefit of assistive technologies, the tabIndex of the node is being set to "-1".'].join(`
|
|
114
|
+
`)),y.current.setAttribute("tabIndex","-1")),m.current&&y.current.focus()),()=>{o||(p.current&&p.current.focus&&(l.current=!0,p.current.focus()),p.current=null)}},[a]),I.useEffect(()=>{if(!a||!y.current)return;const _=Vn(y.current),w=L=>{S.current=L,!(r||!s()||L.key!=="Tab")&&_.activeElement===y.current&&L.shiftKey&&(l.current=!0,f.current&&f.current.focus())},E=()=>{var $,M;const L=y.current;if(L===null)return;if(!_.hasFocus()||!s()||l.current){l.current=!1;return}if(L.contains(_.activeElement)||r&&_.activeElement!==u.current&&_.activeElement!==f.current)return;if(_.activeElement!==g.current)g.current=null;else if(g.current!==null)return;if(!m.current)return;let P=[];if((_.activeElement===u.current||_.activeElement===f.current)&&(P=i(y.current)),P.length>0){const A=!!(($=S.current)!=null&&$.shiftKey&&((M=S.current)==null?void 0:M.key)==="Tab"),N=P[0],z=P[P.length-1];typeof N!="string"&&typeof z!="string"&&(A?z.focus():N.focus())}else L.focus()};_.addEventListener("focusin",E),_.addEventListener("keydown",w,!0);const O=setInterval(()=>{_.activeElement&&_.activeElement.tagName==="BODY"&&E()},50);return()=>{clearInterval(O),_.removeEventListener("focusin",E),_.removeEventListener("keydown",w,!0)}},[n,r,o,s,a,i]);const C=_=>{p.current===null&&(p.current=_.relatedTarget),m.current=!0,g.current=_.target;const w=e.props.onFocus;w&&w(_)},T=_=>{p.current===null&&(p.current=_.relatedTarget),m.current=!0};return v.jsxs(I.Fragment,{children:[v.jsx("div",{tabIndex:a?0:-1,onFocus:T,ref:u,"data-testid":"sentinelStart"}),I.cloneElement(e,{ref:b,onFocus:C}),v.jsx("div",{tabIndex:a?0:-1,onFocus:T,ref:f,"data-testid":"sentinelEnd"})]})}process.env.NODE_ENV!=="production"&&(Ul.propTypes={children:xl,disableAutoFocus:c.bool,disableEnforceFocus:c.bool,disableRestoreFocus:c.bool,getTabbable:c.func,isEnabled:c.func,open:c.bool.isRequired}),process.env.NODE_ENV!=="production"&&(Ul.propTypes=lS(Ul.propTypes));function kz(t){return typeof t=="function"?t():t}const Kl=I.forwardRef(function(e,n){const{children:r,container:o,disablePortal:i=!1}=e,[s,a]=I.useState(null),l=Et(I.isValidElement(r)?wl(r):null,n);if(Tn(()=>{i||a(kz(o)||document.body)},[o,i]),Tn(()=>{if(s&&!i)return Ah(n,s),()=>{Ah(n,null)}},[n,s,i]),i){if(I.isValidElement(r)){const u={ref:l};return I.cloneElement(r,u)}return r}return s&&IF.createPortal(r,s)});process.env.NODE_ENV!=="production"&&(Kl.propTypes={children:c.node,container:c.oneOfType([Vo,c.func]),disablePortal:c.bool}),process.env.NODE_ENV!=="production"&&(Kl.propTypes=lS(Kl.propTypes));function zt(t,e){const{className:n,elementType:r,ownerState:o,externalForwardedProps:i,internalForwardedProps:s,shouldForwardComponentProp:a=!1,...l}=e,{component:u,slots:f={[t]:void 0},slotProps:p={[t]:void 0},...g}=i,m=f[t]||r,y=Mu(p[t],o),{props:{component:b,...S},internalRef:C}=MS({className:n,...l,externalForwardedProps:t==="root"?g:void 0,externalSlotProps:y}),T=Et(C,y==null?void 0:y.ref,e.ref),_=t==="root"?b||u:b,w=_S(m,{...t==="root"&&!u&&!f[t]&&s,...t!=="root"&&!f[t]&&s,...S,..._&&!a&&{as:_},..._&&a&&{component:_},ref:T},o);return[m,w]}const Ez={entering:{opacity:1},entered:{opacity:1}},wi=I.forwardRef(function(e,n){const r=Si(),o={enter:r.transitions.duration.enteringScreen,exit:r.transitions.duration.leavingScreen},{addEndListener:i,appear:s=!0,children:a,easing:l,in:u,onEnter:f,onEntered:p,onEntering:g,onExit:m,onExited:y,onExiting:b,style:S,timeout:C=o,TransitionComponent:T=Pr,..._}=e,w=I.useRef(null),E=Et(w,wl(a),n),O=V=>B=>{if(V){const R=w.current;B===void 0?V(R):V(R,B)}},L=O(g),P=O((V,B)=>{fw(V);const R=gd({style:S,timeout:C,easing:l},{mode:"enter"});V.style.webkitTransition=r.transitions.create("opacity",R),V.style.transition=r.transitions.create("opacity",R),f&&f(V,B)}),$=O(p),M=O(b),A=O(V=>{const B=gd({style:S,timeout:C,easing:l},{mode:"exit"});V.style.webkitTransition=r.transitions.create("opacity",B),V.style.transition=r.transitions.create("opacity",B),m&&m(V)}),N=O(y),z=V=>{i&&i(w.current,V)};return v.jsx(T,{appear:s,in:u,nodeRef:w,onEnter:P,onEntered:$,onEntering:L,onExit:A,onExited:N,onExiting:M,addEndListener:z,timeout:C,..._,children:(V,{ownerState:B,...R})=>I.cloneElement(a,{style:{opacity:0,visibility:V==="exited"&&!u?"hidden":void 0,...Ez[V],...S,...a.props.style},ref:E,...R})})});process.env.NODE_ENV!=="production"&&(wi.propTypes={addEndListener:c.func,appear:c.bool,children:xl.isRequired,easing:c.oneOfType([c.shape({enter:c.string,exit:c.string}),c.string]),in:c.bool,onEnter:c.func,onEntered:c.func,onEntering:c.func,onExit:c.func,onExited:c.func,onExiting:c.func,style:c.object,timeout:c.oneOfType([c.number,c.shape({appear:c.number,enter:c.number,exit:c.number})])});function Mz(t){return Ke("MuiBackdrop",t)}qe("MuiBackdrop",["root","invisible"]);const Oz=t=>{const{classes:e,invisible:n}=t;return Ue({root:["root",n&&"invisible"]},Mz,e)},Az=be("div",{name:"MuiBackdrop",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,n.invisible&&e.invisible]}})({position:"fixed",display:"flex",alignItems:"center",justifyContent:"center",right:0,bottom:0,top:0,left:0,backgroundColor:"rgba(0, 0, 0, 0.5)",WebkitTapHighlightColor:"transparent",variants:[{props:{invisible:!0},style:{backgroundColor:"transparent"}}]}),wg=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiBackdrop"}),{children:o,className:i,component:s="div",invisible:a=!1,open:l,components:u={},componentsProps:f={},slotProps:p={},slots:g={},TransitionComponent:m,transitionDuration:y,...b}=r,S={...r,component:s,invisible:a},C=Oz(S),T={transition:m,root:u.Root,...g},_={...f,...p},w={slots:T,slotProps:_},[E,O]=zt("root",{elementType:Az,externalForwardedProps:w,className:Le(C.root,i),ownerState:S}),[L,P]=zt("transition",{elementType:wi,externalForwardedProps:w,ownerState:S});return v.jsx(L,{in:l,timeout:y,...b,...P,children:v.jsx(E,{"aria-hidden":!0,...O,classes:C,ref:n,children:o})})});process.env.NODE_ENV!=="production"&&(wg.propTypes={children:c.node,classes:c.object,className:c.string,component:c.elementType,components:c.shape({Root:c.elementType}),componentsProps:c.shape({root:c.object}),invisible:c.bool,open:c.bool.isRequired,slotProps:c.shape({root:c.oneOfType([c.func,c.object]),transition:c.oneOfType([c.func,c.object])}),slots:c.shape({root:c.elementType,transition:c.elementType}),sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),TransitionComponent:c.elementType,transitionDuration:c.oneOfType([c.number,c.shape({appear:c.number,enter:c.number,exit:c.number})])});function Iz(t){return typeof t=="function"?t():t}function Dz(t){return t?t.props.hasOwnProperty("in"):!1}const gw=()=>{},md=new vz;function Pz(t){const{container:e,disableEscapeKeyDown:n=!1,disableScrollLock:r=!1,closeAfterTransition:o=!1,onTransitionEnter:i,onTransitionExited:s,children:a,onClose:l,open:u,rootRef:f}=t,p=I.useRef({}),g=I.useRef(null),m=I.useRef(null),y=Et(m,f),[b,S]=I.useState(!u),C=Dz(a);let T=!0;(t["aria-hidden"]==="false"||t["aria-hidden"]===!1)&&(T=!1);const _=()=>Vn(g.current),w=()=>(p.current.modalRef=m.current,p.current.mount=g.current,p.current),E=()=>{md.mount(w(),{disableScrollLock:r}),m.current&&(m.current.scrollTop=0)},O=Be(()=>{const B=Iz(e)||_().body;md.add(w(),B),m.current&&E()}),L=()=>md.isTopModal(w()),P=Be(B=>{g.current=B,B&&(u&&L()?E():m.current&&ql(m.current,T))}),$=I.useCallback(()=>{md.remove(w(),T)},[T]);I.useEffect(()=>()=>{$()},[$]),I.useEffect(()=>{u?O():(!C||!o)&&$()},[u,$,C,o,O]);const M=B=>R=>{var q;(q=B.onKeyDown)==null||q.call(B,R),!(R.key!=="Escape"||R.which===229||!L())&&(n||(R.stopPropagation(),l&&l(R,"escapeKeyDown")))},A=B=>R=>{var q;(q=B.onClick)==null||q.call(B,R),R.target===R.currentTarget&&l&&l(R,"backdropClick")};return{getRootProps:(B={})=>{const R=kS(t);delete R.onTransitionEnter,delete R.onTransitionExited;const q={...R,...B};return{role:"presentation",...q,onKeyDown:M(q),ref:y}},getBackdropProps:(B={})=>{const R=B;return{"aria-hidden":!0,...R,onClick:A(R),open:u}},getTransitionProps:()=>{const B=()=>{S(!1),i&&i()},R=()=>{S(!0),s&&s(),o&&$()};return{onEnter:dS(B,(a==null?void 0:a.props.onEnter)??gw),onExited:dS(R,(a==null?void 0:a.props.onExited)??gw)}},rootRef:y,portalRef:P,isTopModal:L,exited:b,hasTransition:C}}function Nz(t){return Ke("MuiModal",t)}qe("MuiModal",["root","hidden","backdrop"]);const Lz=t=>{const{open:e,exited:n,classes:r}=t;return Ue({root:["root",!e&&n&&"hidden"],backdrop:["backdrop"]},Nz,r)},Fz=be("div",{name:"MuiModal",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,!n.open&&n.exited&&e.hidden]}})(Dt(({theme:t})=>({position:"fixed",zIndex:(t.vars||t).zIndex.modal,right:0,bottom:0,top:0,left:0,variants:[{props:({ownerState:e})=>!e.open&&e.exited,style:{visibility:"hidden"}}]}))),$z=be(wg,{name:"MuiModal",slot:"Backdrop",overridesResolver:(t,e)=>e.backdrop})({zIndex:-1}),_g=I.forwardRef(function(e,n){const r=St({name:"MuiModal",props:e}),{BackdropComponent:o=$z,BackdropProps:i,classes:s,className:a,closeAfterTransition:l=!1,children:u,container:f,component:p,components:g={},componentsProps:m={},disableAutoFocus:y=!1,disableEnforceFocus:b=!1,disableEscapeKeyDown:S=!1,disablePortal:C=!1,disableRestoreFocus:T=!1,disableScrollLock:_=!1,hideBackdrop:w=!1,keepMounted:E=!1,onBackdropClick:O,onClose:L,onTransitionEnter:P,onTransitionExited:$,open:M,slotProps:A={},slots:N={},theme:z,...V}=r,B={...r,closeAfterTransition:l,disableAutoFocus:y,disableEnforceFocus:b,disableEscapeKeyDown:S,disablePortal:C,disableRestoreFocus:T,disableScrollLock:_,hideBackdrop:w,keepMounted:E},{getRootProps:R,getBackdropProps:q,getTransitionProps:U,portalRef:G,isTopModal:Y,exited:Z,hasTransition:fe}=Pz({...B,rootRef:n}),pe={...B,exited:Z},me=Lz(pe),re={};if(u.props.tabIndex===void 0&&(re.tabIndex="-1"),fe){const{onEnter:ce,onExited:te}=U();re.onEnter=ce,re.onExited=te}const he={slots:{root:g.Root,backdrop:g.Backdrop,...N},slotProps:{...m,...A}},[le,X]=zt("root",{ref:n,elementType:Fz,externalForwardedProps:{...he,...V,component:p},getSlotProps:R,ownerState:pe,className:Le(a,me==null?void 0:me.root,!pe.open&&pe.exited&&(me==null?void 0:me.hidden))}),[W,ee]=zt("backdrop",{ref:i==null?void 0:i.ref,elementType:o,externalForwardedProps:he,shouldForwardComponentProp:!0,additionalProps:i,getSlotProps:ce=>q({...ce,onClick:te=>{O&&O(te),ce!=null&&ce.onClick&&ce.onClick(te)}}),className:Le(i==null?void 0:i.className,me==null?void 0:me.backdrop),ownerState:pe});return!E&&!M&&(!fe||Z)?null:v.jsx(Kl,{ref:G,container:f,disablePortal:C,children:v.jsxs(le,{...X,children:[!w&&o?v.jsx(W,{...ee}):null,v.jsx(Ul,{disableEnforceFocus:b,disableAutoFocus:y,disableRestoreFocus:T,isEnabled:Y,open:M,children:I.cloneElement(u,re)})]})})});process.env.NODE_ENV!=="production"&&(_g.propTypes={BackdropComponent:c.elementType,BackdropProps:c.object,children:xl.isRequired,classes:c.object,className:c.string,closeAfterTransition:c.bool,component:c.elementType,components:c.shape({Backdrop:c.elementType,Root:c.elementType}),componentsProps:c.shape({backdrop:c.oneOfType([c.func,c.object]),root:c.oneOfType([c.func,c.object])}),container:c.oneOfType([Vo,c.func]),disableAutoFocus:c.bool,disableEnforceFocus:c.bool,disableEscapeKeyDown:c.bool,disablePortal:c.bool,disableRestoreFocus:c.bool,disableScrollLock:c.bool,hideBackdrop:c.bool,keepMounted:c.bool,onBackdropClick:c.func,onClose:c.func,onTransitionEnter:c.func,onTransitionExited:c.func,open:c.bool.isRequired,slotProps:c.shape({backdrop:c.oneOfType([c.func,c.object]),root:c.oneOfType([c.func,c.object])}),slots:c.shape({backdrop:c.elementType,root:c.elementType}),sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object])});function Bz(t){return Ke("MuiPaper",t)}qe("MuiPaper",["root","rounded","outlined","elevation","elevation0","elevation1","elevation2","elevation3","elevation4","elevation5","elevation6","elevation7","elevation8","elevation9","elevation10","elevation11","elevation12","elevation13","elevation14","elevation15","elevation16","elevation17","elevation18","elevation19","elevation20","elevation21","elevation22","elevation23","elevation24"]);const Rz=t=>{const{square:e,elevation:n,variant:r,classes:o}=t,i={root:["root",r,!e&&"rounded",r==="elevation"&&`elevation${n}`]};return Ue(i,Bz,o)},zz=be("div",{name:"MuiPaper",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,e[n.variant],!n.square&&e.rounded,n.variant==="elevation"&&e[`elevation${n.elevation}`]]}})(Dt(({theme:t})=>({backgroundColor:(t.vars||t).palette.background.paper,color:(t.vars||t).palette.text.primary,transition:t.transitions.create("box-shadow"),variants:[{props:({ownerState:e})=>!e.square,style:{borderRadius:t.shape.borderRadius}},{props:{variant:"outlined"},style:{border:`1px solid ${(t.vars||t).palette.divider}`}},{props:{variant:"elevation"},style:{boxShadow:"var(--Paper-shadow)",backgroundImage:"var(--Paper-overlay)"}}]}))),ya=I.forwardRef(function(e,n){var m;const r=St({props:e,name:"MuiPaper"}),o=Si(),{className:i,component:s="div",elevation:a=1,square:l=!1,variant:u="elevation",...f}=r,p={...r,component:s,elevation:a,square:l,variant:u},g=Rz(p);return process.env.NODE_ENV!=="production"&&o.shadows[a]===void 0&&console.error([`MUI: The elevation provided <Paper elevation={${a}}> is not available in the theme.`,`Please make sure that \`theme.shadows[${a}]\` is defined.`].join(`
|
|
115
|
+
`)),v.jsx(zz,{as:s,ownerState:p,className:Le(g.root,i),ref:n,...f,style:{...u==="elevation"&&{"--Paper-shadow":(o.vars||o).shadows[a],...o.vars&&{"--Paper-overlay":(m=o.vars.overlays)==null?void 0:m[a]},...!o.vars&&o.palette.mode==="dark"&&{"--Paper-overlay":`linear-gradient(${Rt("#fff",jh(a))}, ${Rt("#fff",jh(a))})`}},...f.style}})});process.env.NODE_ENV!=="production"&&(ya.propTypes={children:c.node,classes:c.object,className:c.string,component:c.elementType,elevation:zo(CS,t=>{const{elevation:e,variant:n}=t;return e>0&&n==="outlined"?new Error(`MUI: Combining \`elevation={${e}}\` with \`variant="${n}"\` has no effect. Either use \`elevation={0}\` or use a different \`variant\`.`):null}),square:c.bool,style:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),variant:c.oneOfType([c.oneOf(["elevation","outlined"]),c.string])});function Vz(t){return Ke("MuiPopover",t)}qe("MuiPopover",["root","paper"]);function mw(t,e){let n=0;return typeof e=="number"?n=e:e==="center"?n=t.height/2:e==="bottom"&&(n=t.height),n}function yw(t,e){let n=0;return typeof e=="number"?n=e:e==="center"?n=t.width/2:e==="right"&&(n=t.width),n}function bw(t){return[t.horizontal,t.vertical].map(e=>typeof e=="number"?`${e}px`:e).join(" ")}function yd(t){return typeof t=="function"?t():t}const Hz=t=>{const{classes:e}=t;return Ue({root:["root"],paper:["paper"]},Vz,e)},jz=be(_g,{name:"MuiPopover",slot:"Root",overridesResolver:(t,e)=>e.root})({}),vw=be(ya,{name:"MuiPopover",slot:"Paper",overridesResolver:(t,e)=>e.paper})({position:"absolute",overflowY:"auto",overflowX:"hidden",minWidth:16,minHeight:16,maxWidth:"calc(100% - 32px)",maxHeight:"calc(100% - 32px)",outline:0}),xw=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiPopover"}),{action:o,anchorEl:i,anchorOrigin:s={vertical:"top",horizontal:"left"},anchorPosition:a,anchorReference:l="anchorEl",children:u,className:f,container:p,elevation:g=8,marginThreshold:m=16,open:y,PaperProps:b={},slots:S={},slotProps:C={},transformOrigin:T={vertical:"top",horizontal:"left"},TransitionComponent:_,transitionDuration:w="auto",TransitionProps:E={},disableScrollLock:O=!1,...L}=r,P=I.useRef(),$={...r,anchorOrigin:s,anchorReference:l,elevation:g,marginThreshold:m,transformOrigin:T,TransitionComponent:_,transitionDuration:w,TransitionProps:E},M=Hz($),A=I.useCallback(()=>{if(l==="anchorPosition")return process.env.NODE_ENV!=="production"&&(a||console.error('MUI: You need to provide a `anchorPosition` prop when using <Popover anchorReference="anchorPosition" />.')),a;const ee=yd(i),ce=ee&&ee.nodeType===1?ee:Vn(P.current).body,te=ce.getBoundingClientRect();if(process.env.NODE_ENV!=="production"){const se=ce.getBoundingClientRect();process.env.NODE_ENV!=="test"&&se.top===0&&se.left===0&&se.right===0&&se.bottom===0&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(`
|
|
116
|
+
`))}return{top:te.top+mw(te,s.vertical),left:te.left+yw(te,s.horizontal)}},[i,s.horizontal,s.vertical,a,l]),N=I.useCallback(ee=>({vertical:mw(ee,T.vertical),horizontal:yw(ee,T.horizontal)}),[T.horizontal,T.vertical]),z=I.useCallback(ee=>{const ce={width:ee.offsetWidth,height:ee.offsetHeight},te=N(ce);if(l==="none")return{top:null,left:null,transformOrigin:bw(te)};const se=A();let ue=se.top-te.vertical,ye=se.left-te.horizontal;const _e=ue+ce.height,Se=ye+ce.width,Me=Ho(yd(i)),Fe=Me.innerHeight-m,je=Me.innerWidth-m;if(m!==null&&ue<m){const Je=ue-m;ue-=Je,te.vertical+=Je}else if(m!==null&&_e>Fe){const Je=_e-Fe;ue-=Je,te.vertical+=Je}if(process.env.NODE_ENV!=="production"&&ce.height>Fe&&ce.height&&Fe&&console.error(["MUI: The popover component is too tall.",`Some part of it can not be seen on the screen (${ce.height-Fe}px).`,"Please consider adding a `max-height` to improve the user-experience."].join(`
|
|
117
|
+
`)),m!==null&&ye<m){const Je=ye-m;ye-=Je,te.horizontal+=Je}else if(Se>je){const Je=Se-je;ye-=Je,te.horizontal+=Je}return{top:`${Math.round(ue)}px`,left:`${Math.round(ye)}px`,transformOrigin:bw(te)}},[i,l,A,N,m]),[V,B]=I.useState(y),R=I.useCallback(()=>{const ee=P.current;if(!ee)return;const ce=z(ee);ce.top!==null&&ee.style.setProperty("top",ce.top),ce.left!==null&&(ee.style.left=ce.left),ee.style.transformOrigin=ce.transformOrigin,B(!0)},[z]);I.useEffect(()=>(O&&window.addEventListener("scroll",R),()=>window.removeEventListener("scroll",R)),[i,O,R]);const q=()=>{R()},U=()=>{B(!1)};I.useEffect(()=>{y&&R()}),I.useImperativeHandle(o,()=>y?{updatePosition:()=>{R()}}:null,[y,R]),I.useEffect(()=>{if(!y)return;const ee=fS(()=>{R()}),ce=Ho(i);return ce.addEventListener("resize",ee),()=>{ee.clear(),ce.removeEventListener("resize",ee)}},[i,y,R]);let G=w;const Y={slots:{transition:_,...S},slotProps:{transition:E,paper:b,...C}},[Z,fe]=zt("transition",{elementType:Wl,externalForwardedProps:Y,ownerState:$,getSlotProps:ee=>({...ee,onEntering:(ce,te)=>{var se;(se=ee.onEntering)==null||se.call(ee,ce,te),q()},onExited:ce=>{var te;(te=ee.onExited)==null||te.call(ee,ce),U()}}),additionalProps:{appear:!0,in:y}});w==="auto"&&!Z.muiSupportAuto&&(G=void 0);const pe=p||(i?Vn(yd(i)).body:void 0),[me,{slots:re,slotProps:he,...le}]=zt("root",{ref:n,elementType:jz,externalForwardedProps:{...Y,...L},shouldForwardComponentProp:!0,additionalProps:{slots:{backdrop:S.backdrop},slotProps:{backdrop:EB(typeof C.backdrop=="function"?C.backdrop($):C.backdrop,{invisible:!0})},container:pe,open:y},ownerState:$,className:Le(M.root,f)}),[X,W]=zt("paper",{ref:P,className:M.paper,elementType:vw,externalForwardedProps:Y,shouldForwardComponentProp:!0,additionalProps:{elevation:g,style:V?void 0:{opacity:0}},ownerState:$});return v.jsx(me,{...le,...!$l(me)&&{slots:re,slotProps:he,disableScrollLock:O},children:v.jsx(Z,{...fe,timeout:G,children:v.jsx(X,{...W,children:u})})})});process.env.NODE_ENV!=="production"&&(xw.propTypes={action:mn,anchorEl:zo(c.oneOfType([Vo,c.func]),t=>{if(t.open&&(!t.anchorReference||t.anchorReference==="anchorEl")){const e=yd(t.anchorEl);if(e&&e.nodeType===1){const n=e.getBoundingClientRect();if(process.env.NODE_ENV!=="test"&&n.top===0&&n.left===0&&n.right===0&&n.bottom===0)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(`
|
|
118
118
|
`))}else return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.",`It should be an Element or PopoverVirtualElement instance but it's \`${e}\` instead.`].join(`
|
|
119
119
|
`))}return null}),anchorOrigin:c.shape({horizontal:c.oneOfType([c.oneOf(["center","left","right"]),c.number]).isRequired,vertical:c.oneOfType([c.oneOf(["bottom","center","top"]),c.number]).isRequired}),anchorPosition:c.shape({left:c.number.isRequired,top:c.number.isRequired}),anchorReference:c.oneOf(["anchorEl","anchorPosition","none"]),BackdropComponent:c.elementType,BackdropProps:c.object,children:c.node,classes:c.object,className:c.string,container:c.oneOfType([Vo,c.func]),disableScrollLock:c.bool,elevation:CS,marginThreshold:c.number,onClose:c.func,open:c.bool.isRequired,PaperProps:c.shape({component:Eu}),slotProps:c.shape({backdrop:c.oneOfType([c.func,c.object]),paper:c.oneOfType([c.func,c.object]),root:c.oneOfType([c.func,c.object]),transition:c.oneOfType([c.func,c.object])}),slots:c.shape({backdrop:c.elementType,paper:c.elementType,root:c.elementType,transition:c.elementType}),sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),transformOrigin:c.shape({horizontal:c.oneOfType([c.oneOf(["center","left","right"]),c.number]).isRequired,vertical:c.oneOfType([c.oneOf(["bottom","center","top"]),c.number]).isRequired}),TransitionComponent:c.elementType,transitionDuration:c.oneOfType([c.oneOf(["auto"]),c.number,c.shape({appear:c.number,enter:c.number,exit:c.number})]),TransitionProps:c.object});function Wz(t){return Ke("MuiMenu",t)}qe("MuiMenu",["root","paper","list"]);const qz={vertical:"top",horizontal:"right"},Uz={vertical:"top",horizontal:"left"},Kz=t=>{const{classes:e}=t;return Ue({root:["root"],paper:["paper"],list:["list"]},Wz,e)},Yz=be(xw,{shouldForwardProp:t=>ro(t)||t==="classes",name:"MuiMenu",slot:"Root",overridesResolver:(t,e)=>e.root})({}),Gz=be(vw,{name:"MuiMenu",slot:"Paper",overridesResolver:(t,e)=>e.paper})({maxHeight:"calc(100% - 96px)",WebkitOverflowScrolling:"touch"}),Jz=be(lw,{name:"MuiMenu",slot:"List",overridesResolver:(t,e)=>e.list})({outline:0}),Sw=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiMenu"}),{autoFocus:o=!0,children:i,className:s,disableAutoFocusItem:a=!1,MenuListProps:l={},onClose:u,open:f,PaperProps:p={},PopoverClasses:g,transitionDuration:m="auto",TransitionProps:{onEntering:y,...b}={},variant:S="selectedMenu",slots:C={},slotProps:T={},..._}=r,w=no(),E={...r,autoFocus:o,disableAutoFocusItem:a,MenuListProps:l,onEntering:y,PaperProps:p,transitionDuration:m,TransitionProps:b,variant:S},O=Kz(E),L=o&&!a&&f,P=I.useRef(null),$=(G,Y)=>{P.current&&P.current.adjustStyleForScrollbar(G,{direction:w?"rtl":"ltr"}),y&&y(G,Y)},M=G=>{G.key==="Tab"&&(G.preventDefault(),u&&u(G,"tabKeyDown"))};let A=-1;I.Children.map(i,(G,Y)=>{I.isValidElement(G)&&(process.env.NODE_ENV!=="production"&&cs.isFragment(G)&&console.error(["MUI: The Menu component doesn't accept a Fragment as a child.","Consider providing an array instead."].join(`
|
|
120
|
-
`)),G.props.disabled||(S==="selectedMenu"&&G.props.selected||A===-1)&&(A=Y))});const N={slots:C,slotProps:{list:l,transition:b,paper:p,...T}},
|
|
120
|
+
`)),G.props.disabled||(S==="selectedMenu"&&G.props.selected||A===-1)&&(A=Y))});const N={slots:C,slotProps:{list:l,transition:b,paper:p,...T}},z=wt({elementType:C.root,externalSlotProps:T.root,ownerState:E,className:[O.root,s]}),[V,B]=zt("paper",{className:O.paper,elementType:Gz,externalForwardedProps:N,shouldForwardComponentProp:!0,ownerState:E}),[R,q]=zt("list",{className:Le(O.list,l.className),elementType:Jz,shouldForwardComponentProp:!0,externalForwardedProps:N,getSlotProps:G=>({...G,onKeyDown:Y=>{var Z;M(Y),(Z=G.onKeyDown)==null||Z.call(G,Y)}}),ownerState:E}),U=typeof N.slotProps.transition=="function"?N.slotProps.transition(E):N.slotProps.transition;return v.jsx(Yz,{onClose:u,anchorOrigin:{vertical:"bottom",horizontal:w?"right":"left"},transformOrigin:w?qz:Uz,slots:{root:C.root,paper:V,backdrop:C.backdrop,...C.transition&&{transition:C.transition}},slotProps:{root:z,paper:B,backdrop:typeof T.backdrop=="function"?T.backdrop(E):T.backdrop,transition:{...U,onEntering:(...G)=>{var Y;$(...G),(Y=U==null?void 0:U.onEntering)==null||Y.call(U,...G)}}},open:f,ref:n,transitionDuration:m,ownerState:E,..._,classes:g,children:v.jsx(R,{actions:P,autoFocus:o&&(A===-1||a),autoFocusItem:L,variant:S,...q,children:i})})});process.env.NODE_ENV!=="production"&&(Sw.propTypes={anchorEl:c.oneOfType([Vo,c.func]),autoFocus:c.bool,children:c.node,classes:c.object,className:c.string,disableAutoFocusItem:c.bool,MenuListProps:c.object,onClose:c.func,open:c.bool.isRequired,PaperProps:c.object,PopoverClasses:c.object,slotProps:c.shape({backdrop:c.oneOfType([c.func,c.object]),list:c.oneOfType([c.func,c.object]),paper:c.oneOfType([c.func,c.object]),root:c.oneOfType([c.func,c.object]),transition:c.oneOfType([c.func,c.object])}),slots:c.shape({backdrop:c.elementType,list:c.elementType,paper:c.elementType,root:c.elementType,transition:c.elementType}),sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),transitionDuration:c.oneOfType([c.oneOf(["auto"]),c.number,c.shape({appear:c.number,enter:c.number,exit:c.number})]),TransitionProps:c.object,variant:c.oneOf(["menu","selectedMenu"])});function Zz(t){return Ke("MuiNativeSelect",t)}const Tg=qe("MuiNativeSelect",["root","select","multiple","filled","outlined","standard","disabled","icon","iconOpen","iconFilled","iconOutlined","iconStandard","nativeInput","error"]),Xz=t=>{const{classes:e,variant:n,disabled:r,multiple:o,open:i,error:s}=t,a={select:["select",n,r&&"disabled",o&&"multiple",s&&"error"],icon:["icon",`icon${Ae(n)}`,i&&"iconOpen",r&&"disabled"]};return Ue(a,Zz,e)},Cw=be("select")(({theme:t})=>({MozAppearance:"none",WebkitAppearance:"none",userSelect:"none",borderRadius:0,cursor:"pointer","&:focus":{borderRadius:0},[`&.${Tg.disabled}`]:{cursor:"default"},"&[multiple]":{height:"auto"},"&:not([multiple]) option, &:not([multiple]) optgroup":{backgroundColor:(t.vars||t).palette.background.paper},variants:[{props:({ownerState:e})=>e.variant!=="filled"&&e.variant!=="outlined",style:{"&&&":{paddingRight:24,minWidth:16}}},{props:{variant:"filled"},style:{"&&&":{paddingRight:32}}},{props:{variant:"outlined"},style:{borderRadius:(t.vars||t).shape.borderRadius,"&:focus":{borderRadius:(t.vars||t).shape.borderRadius},"&&&":{paddingRight:32}}}]})),Qz=be(Cw,{name:"MuiNativeSelect",slot:"Select",shouldForwardProp:ro,overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.select,e[n.variant],n.error&&e.error,{[`&.${Tg.multiple}`]:e.multiple}]}})({}),ww=be("svg")(({theme:t})=>({position:"absolute",right:0,top:"calc(50% - .5em)",pointerEvents:"none",color:(t.vars||t).palette.action.active,[`&.${Tg.disabled}`]:{color:(t.vars||t).palette.action.disabled},variants:[{props:({ownerState:e})=>e.open,style:{transform:"rotate(180deg)"}},{props:{variant:"filled"},style:{right:7}},{props:{variant:"outlined"},style:{right:7}}]})),e4=be(ww,{name:"MuiNativeSelect",slot:"Icon",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.icon,n.variant&&e[`icon${Ae(n.variant)}`],n.open&&e.iconOpen]}})({}),_w=I.forwardRef(function(e,n){const{className:r,disabled:o,error:i,IconComponent:s,inputRef:a,variant:l="standard",...u}=e,f={...e,disabled:o,variant:l,error:i},p=Xz(f);return v.jsxs(I.Fragment,{children:[v.jsx(Qz,{ownerState:f,className:Le(p.select,r),disabled:o,ref:a||n,...u}),e.multiple?null:v.jsx(e4,{as:s,ownerState:f,className:p.icon})]})});process.env.NODE_ENV!=="production"&&(_w.propTypes={children:c.node,classes:c.object,className:c.string,disabled:c.bool,error:c.bool,IconComponent:c.elementType.isRequired,inputRef:mn,multiple:c.bool,name:c.string,onChange:c.func,value:c.any,variant:c.oneOf(["standard","outlined","filled"])});function Tw(t){return Ke("MuiSelect",t)}const Yl=qe("MuiSelect",["root","select","multiple","filled","outlined","standard","disabled","focused","icon","iconOpen","iconFilled","iconOutlined","iconStandard","nativeInput","error"]);var kw;const t4=be(Cw,{name:"MuiSelect",slot:"Select",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[{[`&.${Yl.select}`]:e.select},{[`&.${Yl.select}`]:e[n.variant]},{[`&.${Yl.error}`]:e.error},{[`&.${Yl.multiple}`]:e.multiple}]}})({[`&.${Yl.select}`]:{height:"auto",minHeight:"1.4375em",textOverflow:"ellipsis",whiteSpace:"nowrap",overflow:"hidden"}}),n4=be(ww,{name:"MuiSelect",slot:"Icon",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.icon,n.variant&&e[`icon${Ae(n.variant)}`],n.open&&e.iconOpen]}})({}),r4=be("input",{shouldForwardProp:t=>uC(t)&&t!=="classes",name:"MuiSelect",slot:"NativeInput",overridesResolver:(t,e)=>e.nativeInput})({bottom:0,left:0,position:"absolute",opacity:0,pointerEvents:"none",width:"100%",boxSizing:"border-box"});function Ew(t,e){return typeof e=="object"&&e!==null?t===e:String(t)===String(e)}function o4(t){return t==null||typeof t=="string"&&!t.trim()}const i4=t=>{const{classes:e,variant:n,disabled:r,multiple:o,open:i,error:s}=t,a={select:["select",n,r&&"disabled",o&&"multiple",s&&"error"],icon:["icon",`icon${Ae(n)}`,i&&"iconOpen",r&&"disabled"],nativeInput:["nativeInput"]};return Ue(a,Tw,e)},Mw=I.forwardRef(function(e,n){var $e;const{"aria-describedby":r,"aria-label":o,autoFocus:i,autoWidth:s,children:a,className:l,defaultOpen:u,defaultValue:f,disabled:p,displayEmpty:g,error:m=!1,IconComponent:y,inputRef:b,labelId:S,MenuProps:C={},multiple:T,name:_,onBlur:w,onChange:E,onClose:O,onFocus:L,onOpen:P,open:$,readOnly:M,renderValue:A,required:N,SelectDisplayProps:z={},tabIndex:V,type:B,value:R,variant:q="standard",...U}=e,[G,Y]=jo({controlled:R,default:f,name:"Select"}),[Z,fe]=jo({controlled:$,default:u,name:"Select"}),pe=I.useRef(null),me=I.useRef(null),[re,he]=I.useState(null),{current:le}=I.useRef($!=null),[X,W]=I.useState(),ee=Et(n,b),ce=I.useCallback(ke=>{me.current=ke,ke&&he(ke)},[]),te=re==null?void 0:re.parentNode;I.useImperativeHandle(ee,()=>({focus:()=>{me.current.focus()},node:pe.current,value:G}),[G]),I.useEffect(()=>{u&&Z&&re&&!le&&(W(s?null:te.clientWidth),me.current.focus())},[re,s]),I.useEffect(()=>{i&&me.current.focus()},[i]),I.useEffect(()=>{if(!S)return;const ke=Vn(me.current).getElementById(S);if(ke){const Re=()=>{getSelection().isCollapsed&&me.current.focus()};return ke.addEventListener("click",Re),()=>{ke.removeEventListener("click",Re)}}},[S]);const se=(ke,Re)=>{ke?P&&P(Re):O&&O(Re),le||(W(s?null:te.clientWidth),fe(ke))},ue=ke=>{ke.button===0&&(ke.preventDefault(),me.current.focus(),se(!0,ke))},ye=ke=>{se(!1,ke)},_e=I.Children.toArray(a),Se=ke=>{const Re=_e.find(Ge=>Ge.props.value===ke.target.value);Re!==void 0&&(Y(Re.props.value),E&&E(ke,Re))},Me=ke=>Re=>{let Ge;if(Re.currentTarget.hasAttribute("tabindex")){if(T){Ge=Array.isArray(G)?G.slice():[];const nt=G.indexOf(ke.props.value);nt===-1?Ge.push(ke.props.value):Ge.splice(nt,1)}else Ge=ke.props.value;if(ke.props.onClick&&ke.props.onClick(Re),G!==Ge&&(Y(Ge),E)){const nt=Re.nativeEvent||Re,Pt=new nt.constructor(nt.type,nt);Object.defineProperty(Pt,"target",{writable:!0,value:{value:Ge,name:_}}),E(Pt,ke)}T||se(!1,Re)}},Fe=ke=>{M||[" ","ArrowUp","ArrowDown","Enter"].includes(ke.key)&&(ke.preventDefault(),se(!0,ke))},je=re!==null&&Z,Je=ke=>{!je&&w&&(Object.defineProperty(ke,"target",{writable:!0,value:{value:G,name:_}}),w(ke))};delete U["aria-invalid"];let De,ct;const Ct=[];let Xt=!1,Sn=!1;(id({value:G})||g)&&(A?De=A(G):Xt=!0);const un=_e.map(ke=>{if(!I.isValidElement(ke))return null;process.env.NODE_ENV!=="production"&&cs.isFragment(ke)&&console.error(["MUI: The Select component doesn't accept a Fragment as a child.","Consider providing an array instead."].join(`
|
|
121
121
|
`));let Re;if(T){if(!Array.isArray(G))throw new Error(process.env.NODE_ENV!=="production"?"MUI: The `value` prop must be an array when using the `Select` component with `multiple`.":bo(2));Re=G.some(Ge=>Ew(Ge,ke.props.value)),Re&&Xt&&Ct.push(ke.props.children)}else Re=Ew(G,ke.props.value),Re&&Xt&&(ct=ke.props.children);return Re&&(Sn=!0),I.cloneElement(ke,{"aria-selected":Re?"true":"false",onClick:Me(ke),onKeyUp:Ge=>{Ge.key===" "&&Ge.preventDefault(),ke.props.onKeyUp&&ke.props.onKeyUp(Ge)},role:"option",selected:Re,value:void 0,"data-value":ke.props.value})});process.env.NODE_ENV!=="production"&&I.useEffect(()=>{if(!Sn&&!T&&G!==""){const ke=_e.map(Re=>Re.props.value);console.warn([`MUI: You have provided an out-of-range value \`${G}\` for the select ${_?`(name="${_}") `:""}component.`,"Consider providing a value that matches one of the available options or ''.",`The available values are ${ke.filter(Re=>Re!=null).map(Re=>`\`${Re}\``).join(", ")||'""'}.`].join(`
|
|
122
|
-
`))}},[Sn,_e,T,_,G]),Xt&&(T?Ct.length===0?De=null:De=Ct.reduce((ke,Re,Ge)=>(ke.push(Re),Ge<Ct.length-1&&ke.push(", "),ke),[]):De=ct);let $t=ae;!s&&ce&&Q&&($t=ee.clientWidth);let In;typeof R<"u"?In=R:In=p?null:0;const Kn=V.id||(_?`mui-component-select-${_}`:void 0),ft={...e,variant:q,value:G,open:je,error:m},$n=i4(ft),Yt={...C.PaperProps,...($e=C.slotProps)==null?void 0:$e.paper},ge=vo();return v.jsxs(I.Fragment,{children:[v.jsx(t4,{as:"div",ref:ue,tabIndex:In,role:"combobox","aria-controls":je?ge:void 0,"aria-disabled":p?"true":void 0,"aria-expanded":je?"true":"false","aria-haspopup":"listbox","aria-label":o,"aria-labelledby":[S,Kn].filter(Boolean).join(" ")||void 0,"aria-describedby":r,"aria-required":N?"true":void 0,"aria-invalid":m?"true":void 0,onKeyDown:Fe,onMouseDown:p||M?null:de,onBlur:Je,onFocus:L,...V,ownerState:ft,className:Le(V.className,$n.select,l),id:Kn,children:o4(De)?kw||(kw=v.jsx("span",{className:"notranslate","aria-hidden":!0,children:""})):De}),v.jsx(r4,{"aria-invalid":m,value:Array.isArray(G)?G.join(","):G,name:_,ref:he,"aria-hidden":!0,onChange:Se,tabIndex:-1,disabled:p,className:$n.nativeInput,autoFocus:i,required:N,...K,ownerState:ft}),v.jsx(n4,{as:y,className:$n.icon,ownerState:ft}),v.jsx(Sw,{id:`menu-${_||""}`,anchorEl:ee,open:je,onClose:ye,anchorOrigin:{vertical:"bottom",horizontal:"center"},transformOrigin:{vertical:"top",horizontal:"center"},...C,slotProps:{...C.slotProps,list:{"aria-labelledby":S,role:"listbox","aria-multiselectable":T?"true":void 0,disableListWrap:!0,id:ge,...C.MenuListProps},paper:{...Yt,style:{minWidth:$t,...Yt!=null?Yt.style:null}}},children:un})]})});process.env.NODE_ENV!=="production"&&(Mw.propTypes={"aria-describedby":c.string,"aria-label":c.string,autoFocus:c.bool,autoWidth:c.bool,children:c.node,classes:c.object,className:c.string,defaultOpen:c.bool,defaultValue:c.any,disabled:c.bool,displayEmpty:c.bool,error:c.bool,IconComponent:c.elementType.isRequired,inputRef:mn,labelId:c.string,MenuProps:c.object,multiple:c.bool,name:c.string,onBlur:c.func,onChange:c.func,onClose:c.func,onFocus:c.func,onOpen:c.func,open:c.bool,readOnly:c.bool,renderValue:c.func,required:c.bool,SelectDisplayProps:c.object,tabIndex:c.oneOfType([c.number,c.string]),type:c.any,value:c.any,variant:c.oneOf(["standard","outlined","filled"])});const s4=ze(v.jsx("path",{d:"M7 10l5 5 5-5z"}),"ArrowDropDown"),a4=t=>{const{classes:e}=t,r=Ue({root:["root"]},Tw,e);return{...e,...r}},kg={name:"MuiSelect",overridesResolver:(t,e)=>e.root,shouldForwardProp:t=>ro(t)&&t!=="variant",slot:"Root"},l4=be(dd,kg)(""),c4=be(pd,kg)(""),u4=be(fd,kg)(""),Eg=I.forwardRef(function(e,n){const r=St({name:"MuiSelect",props:e}),{autoWidth:o=!1,children:i,classes:s={},className:a,defaultOpen:l=!1,displayEmpty:u=!1,IconComponent:f=s4,id:p,input:g,inputProps:m,label:y,labelId:b,MenuProps:S,multiple:C=!1,native:T=!1,onClose:_,onOpen:w,open:E,renderValue:O,SelectDisplayProps:L,variant:P="outlined",...$}=r,M=T?_w:Mw,A=io(),N=fa({props:r,muiFormControl:A,states:["variant","error"]}),V=N.variant||P,R={...r,variant:V,classes:s},B=a4(R),{root:z,...q}=B,K=g||{standard:v.jsx(l4,{ownerState:R}),outlined:v.jsx(c4,{label:y,ownerState:R}),filled:v.jsx(u4,{ownerState:R})}[V],G=Et(n,wl(K));return v.jsx(I.Fragment,{children:I.cloneElement(K,{inputComponent:M,inputProps:{children:i,error:N.error,IconComponent:f,variant:V,type:void 0,multiple:C,...T?{id:p}:{autoWidth:o,defaultOpen:l,displayEmpty:u,labelId:b,MenuProps:S,onClose:_,onOpen:w,open:E,renderValue:O,SelectDisplayProps:{id:p,...L}},...m,classes:m?zn(q,m.classes):q,...g?g.props.inputProps:{}},...(C&&T||u)&&V==="outlined"?{notched:!0}:{},ref:G,className:Le(K.props.className,a,B.root),...!g&&{variant:V},...$})})});process.env.NODE_ENV!=="production"&&(Eg.propTypes={autoWidth:c.bool,children:c.node,classes:c.object,className:c.string,defaultOpen:c.bool,defaultValue:c.any,displayEmpty:c.bool,IconComponent:c.elementType,id:c.string,input:c.element,inputProps:c.object,label:c.node,labelId:c.string,MenuProps:c.object,multiple:c.bool,native:c.bool,onChange:c.func,onClose:c.func,onOpen:c.func,open:c.bool,renderValue:c.func,SelectDisplayProps:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),value:c.oneOfType([c.oneOf([""]),c.any]),variant:c.oneOf(["filled","outlined","standard"])}),Eg.muiName="Select";function d4(t){return Ke("MuiTextField",t)}qe("MuiTextField",["root"]);const f4={standard:dd,filled:fd,outlined:pd},p4=t=>{const{classes:e}=t;return Ue({root:["root"]},d4,e)},h4=be(ug,{name:"MuiTextField",slot:"Root",overridesResolver:(t,e)=>e.root})({}),Ow=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiTextField"}),{autoComplete:o,autoFocus:i=!1,children:s,className:a,color:l="primary",defaultValue:u,disabled:f=!1,error:p=!1,FormHelperTextProps:g,fullWidth:m=!1,helperText:y,id:b,InputLabelProps:S,inputProps:C,InputProps:T,inputRef:_,label:w,maxRows:E,minRows:O,multiline:L=!1,name:P,onBlur:$,onChange:M,onFocus:A,placeholder:N,required:V=!1,rows:R,select:B=!1,SelectProps:z,slots:q={},slotProps:K={},type:G,value:Y,variant:Z="outlined",...me}=r,he={...r,autoFocus:i,color:l,disabled:f,error:p,fullWidth:m,multiline:L,required:V,select:B,variant:Z},oe=p4(he);process.env.NODE_ENV!=="production"&&B&&!s&&console.error("MUI: `children` must be passed when using the `TextField` component with `select`.");const Q=vo(b),fe=y&&Q?`${Q}-helper-text`:void 0,ce=w&&Q?`${Q}-label`:void 0,ae=f4[Z],W={slots:q,slotProps:{input:T,inputLabel:S,htmlInput:C,formHelperText:g,select:z,...K}},te={},ue=W.slotProps.inputLabel;Z==="outlined"&&(ue&&typeof ue.shrink<"u"&&(te.notched=ue.shrink),te.label=w),B&&((!z||!z.native)&&(te.id=void 0),te["aria-describedby"]=void 0);const[ee,se]=zt("root",{elementType:h4,shouldForwardComponentProp:!0,externalForwardedProps:{...W,...me},ownerState:he,className:Le(oe.root,a),ref:n,additionalProps:{disabled:f,error:p,fullWidth:m,required:V,color:l,variant:Z}}),[de,ye]=zt("input",{elementType:ae,externalForwardedProps:W,additionalProps:te,ownerState:he}),[_e,Se]=zt("inputLabel",{elementType:cg,externalForwardedProps:W,ownerState:he}),[Me,Fe]=zt("htmlInput",{elementType:"input",externalForwardedProps:W,ownerState:he}),[je,Je]=zt("formHelperText",{elementType:dg,externalForwardedProps:W,ownerState:he}),[De,ct]=zt("select",{elementType:Eg,externalForwardedProps:W,ownerState:he}),Ct=v.jsx(de,{"aria-describedby":fe,autoComplete:o,autoFocus:i,defaultValue:u,fullWidth:m,multiline:L,name:P,rows:R,maxRows:E,minRows:O,type:G,value:Y,id:Q,inputRef:_,onBlur:$,onChange:M,onFocus:A,placeholder:N,inputProps:Fe,slots:{input:q.htmlInput?Me:void 0},...ye});return v.jsxs(ee,{...se,children:[w!=null&&w!==""&&v.jsx(_e,{htmlFor:Q,id:ce,...Se,children:w}),B?v.jsx(De,{"aria-describedby":fe,id:Q,labelId:ce,value:Y,input:Ct,...ct,children:s}):Ct,y&&v.jsx(je,{id:fe,...Je,children:y})]})});process.env.NODE_ENV!=="production"&&(Ow.propTypes={autoComplete:c.string,autoFocus:c.bool,children:c.node,classes:c.object,className:c.string,color:c.oneOfType([c.oneOf(["primary","secondary","error","info","success","warning"]),c.string]),defaultValue:c.any,disabled:c.bool,error:c.bool,FormHelperTextProps:c.object,fullWidth:c.bool,helperText:c.node,id:c.string,InputLabelProps:c.object,inputProps:c.object,InputProps:c.object,inputRef:mn,label:c.node,margin:c.oneOf(["dense","none","normal"]),maxRows:c.oneOfType([c.number,c.string]),minRows:c.oneOfType([c.number,c.string]),multiline:c.bool,name:c.string,onBlur:c.func,onChange:c.func,onFocus:c.func,placeholder:c.string,required:c.bool,rows:c.oneOfType([c.number,c.string]),select:c.bool,SelectProps:c.object,size:c.oneOfType([c.oneOf(["medium","small"]),c.string]),slotProps:c.shape({formHelperText:c.oneOfType([c.func,c.object]),htmlInput:c.oneOfType([c.func,c.object]),input:c.oneOfType([c.func,c.object]),inputLabel:c.oneOfType([c.func,c.object]),select:c.oneOfType([c.func,c.object])}),slots:c.shape({formHelperText:c.elementType,htmlInput:c.elementType,input:c.elementType,inputLabel:c.elementType,root:c.elementType,select:c.elementType}),sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),type:c.string,value:c.any,variant:c.oneOf(["filled","outlined","standard"])});const Gl=(t,e)=>t.length!==e.length?!1:e.every(n=>t.includes(n)),g4=({openTo:t,defaultOpenTo:e,views:n,defaultViews:r})=>{const o=n??r;let i;if(t!=null)i=t;else if(o.includes(e))i=e;else if(o.length>0)i=o[0];else throw new Error("MUI X: The `views` prop must contain at least one view.");return{views:o,openTo:i}},bd=(t,e,n)=>{let r=e;return r=t.setHours(r,t.getHours(n)),r=t.setMinutes(r,t.getMinutes(n)),r=t.setSeconds(r,t.getSeconds(n)),r=t.setMilliseconds(r,t.getMilliseconds(n)),r},Jl=({date:t,disableFuture:e,disablePast:n,maxDate:r,minDate:o,isDateDisabled:i,utils:s,timezone:a})=>{const l=bd(s,s.date(void 0,a),t);n&&s.isBefore(o,l)&&(o=l),e&&s.isAfter(r,l)&&(r=l);let u=t,f=t;for(s.isBefore(t,o)&&(u=o,f=null),s.isAfter(t,r)&&(f&&(f=r),u=null);u||f;){if(u&&s.isAfter(u,r)&&(u=null),f&&s.isBefore(f,o)&&(f=null),u){if(!i(u))return u;u=s.addDays(u,1)}if(f){if(!i(f))return f;f=s.addDays(f,-1)}}return null},m4=(t,e)=>e==null||!t.isValid(e)?null:e,Nr=(t,e,n)=>e==null||!t.isValid(e)?n:e,y4=(t,e,n)=>!t.isValid(e)&&e!=null&&!t.isValid(n)&&n!=null?!0:t.isEqual(e,n),Mg=(t,e)=>{const r=[t.startOfYear(e)];for(;r.length<12;){const o=r[r.length-1];r.push(t.addMonths(o,1))}return r},Aw=(t,e,n)=>n==="date"?t.startOfDay(t.date(void 0,e)):t.date(void 0,e),b4=["year","month","day"],Iw=t=>b4.includes(t),Og=(t,{format:e,views:n},r)=>{if(e!=null)return e;const o=t.formats;return Gl(n,["year"])?o.year:Gl(n,["month"])?o.month:Gl(n,["day"])?o.dayOfMonth:Gl(n,["month","year"])?`${o.month} ${o.year}`:Gl(n,["day","month"])?`${o.month} ${o.dayOfMonth}`:r?/en/.test(t.getCurrentLocaleCode())?o.normalDateWithWeekday:o.normalDate:o.keyboardDate},v4=(t,e)=>{const n=t.startOfWeek(e);return[0,1,2,3,4,5,6].map(r=>t.addDays(n,r))},x4=["hours","minutes","seconds"],S4=t=>x4.includes(t),Dw=(t,e)=>e.getHours(t)*3600+e.getMinutes(t)*60+e.getSeconds(t),C4=(t,e)=>(n,r)=>t?e.isAfter(n,r):Dw(n,e)>Dw(r,e),Co={year:1,month:2,day:3,hours:4,minutes:5,seconds:6,milliseconds:7},w4=t=>Math.max(...t.map(e=>Co[e.type]??1)),Zl=(t,e,n)=>{if(e===Co.year)return t.startOfYear(n);if(e===Co.month)return t.startOfMonth(n);if(e===Co.day)return t.startOfDay(n);let r=n;return e<Co.minutes&&(r=t.setMinutes(r,0)),e<Co.seconds&&(r=t.setSeconds(r,0)),e<Co.milliseconds&&(r=t.setMilliseconds(r,0)),r},_4=({props:t,utils:e,granularity:n,timezone:r,getTodayDate:o})=>{let i=o?o():Zl(e,n,Aw(e,r));t.minDate!=null&&e.isAfterDay(t.minDate,i)&&(i=Zl(e,n,t.minDate)),t.maxDate!=null&&e.isBeforeDay(t.maxDate,i)&&(i=Zl(e,n,t.maxDate));const s=C4(t.disableIgnoringDatePartForTimeValidation??!1,e);return t.minTime!=null&&s(t.minTime,i)&&(i=Zl(e,n,t.disableIgnoringDatePartForTimeValidation?t.minTime:bd(e,i,t.minTime))),t.maxTime!=null&&s(i,t.maxTime)&&(i=Zl(e,n,t.disableIgnoringDatePartForTimeValidation?t.maxTime:bd(e,i,t.maxTime))),i},Ag=(t,e)=>{const n=t.formatTokenMap[e];if(n==null)throw new Error([`MUI X: The token "${e}" is not supported by the Date and Time Pickers.`,"Please try using another token or open an issue on https://github.com/mui/mui-x/issues/new/choose if you think it should be supported."].join(`
|
|
122
|
+
`))}},[Sn,_e,T,_,G]),Xt&&(T?Ct.length===0?De=null:De=Ct.reduce((ke,Re,Ge)=>(ke.push(Re),Ge<Ct.length-1&&ke.push(", "),ke),[]):De=ct);let $t=X;!s&&le&&re&&($t=te.clientWidth);let In;typeof V<"u"?In=V:In=p?null:0;const Kn=z.id||(_?`mui-component-select-${_}`:void 0),ft={...e,variant:q,value:G,open:je,error:m},$n=i4(ft),Yt={...C.PaperProps,...($e=C.slotProps)==null?void 0:$e.paper},ge=vo();return v.jsxs(I.Fragment,{children:[v.jsx(t4,{as:"div",ref:ce,tabIndex:In,role:"combobox","aria-controls":je?ge:void 0,"aria-disabled":p?"true":void 0,"aria-expanded":je?"true":"false","aria-haspopup":"listbox","aria-label":o,"aria-labelledby":[S,Kn].filter(Boolean).join(" ")||void 0,"aria-describedby":r,"aria-required":N?"true":void 0,"aria-invalid":m?"true":void 0,onKeyDown:Fe,onMouseDown:p||M?null:ue,onBlur:Je,onFocus:L,...z,ownerState:ft,className:Le(z.className,$n.select,l),id:Kn,children:o4(De)?kw||(kw=v.jsx("span",{className:"notranslate","aria-hidden":!0,children:""})):De}),v.jsx(r4,{"aria-invalid":m,value:Array.isArray(G)?G.join(","):G,name:_,ref:pe,"aria-hidden":!0,onChange:Se,tabIndex:-1,disabled:p,className:$n.nativeInput,autoFocus:i,required:N,...U,ownerState:ft}),v.jsx(n4,{as:y,className:$n.icon,ownerState:ft}),v.jsx(Sw,{id:`menu-${_||""}`,anchorEl:te,open:je,onClose:ye,anchorOrigin:{vertical:"bottom",horizontal:"center"},transformOrigin:{vertical:"top",horizontal:"center"},...C,slotProps:{...C.slotProps,list:{"aria-labelledby":S,role:"listbox","aria-multiselectable":T?"true":void 0,disableListWrap:!0,id:ge,...C.MenuListProps},paper:{...Yt,style:{minWidth:$t,...Yt!=null?Yt.style:null}}},children:un})]})});process.env.NODE_ENV!=="production"&&(Mw.propTypes={"aria-describedby":c.string,"aria-label":c.string,autoFocus:c.bool,autoWidth:c.bool,children:c.node,classes:c.object,className:c.string,defaultOpen:c.bool,defaultValue:c.any,disabled:c.bool,displayEmpty:c.bool,error:c.bool,IconComponent:c.elementType.isRequired,inputRef:mn,labelId:c.string,MenuProps:c.object,multiple:c.bool,name:c.string,onBlur:c.func,onChange:c.func,onClose:c.func,onFocus:c.func,onOpen:c.func,open:c.bool,readOnly:c.bool,renderValue:c.func,required:c.bool,SelectDisplayProps:c.object,tabIndex:c.oneOfType([c.number,c.string]),type:c.any,value:c.any,variant:c.oneOf(["standard","outlined","filled"])});const s4=ze(v.jsx("path",{d:"M7 10l5 5 5-5z"}),"ArrowDropDown"),a4=t=>{const{classes:e}=t,r=Ue({root:["root"]},Tw,e);return{...e,...r}},kg={name:"MuiSelect",overridesResolver:(t,e)=>e.root,shouldForwardProp:t=>ro(t)&&t!=="variant",slot:"Root"},l4=be(dd,kg)(""),c4=be(pd,kg)(""),u4=be(fd,kg)(""),Eg=I.forwardRef(function(e,n){const r=St({name:"MuiSelect",props:e}),{autoWidth:o=!1,children:i,classes:s={},className:a,defaultOpen:l=!1,displayEmpty:u=!1,IconComponent:f=s4,id:p,input:g,inputProps:m,label:y,labelId:b,MenuProps:S,multiple:C=!1,native:T=!1,onClose:_,onOpen:w,open:E,renderValue:O,SelectDisplayProps:L,variant:P="outlined",...$}=r,M=T?_w:Mw,A=io(),N=fa({props:r,muiFormControl:A,states:["variant","error"]}),z=N.variant||P,V={...r,variant:z,classes:s},B=a4(V),{root:R,...q}=B,U=g||{standard:v.jsx(l4,{ownerState:V}),outlined:v.jsx(c4,{label:y,ownerState:V}),filled:v.jsx(u4,{ownerState:V})}[z],G=Et(n,wl(U));return v.jsx(I.Fragment,{children:I.cloneElement(U,{inputComponent:M,inputProps:{children:i,error:N.error,IconComponent:f,variant:z,type:void 0,multiple:C,...T?{id:p}:{autoWidth:o,defaultOpen:l,displayEmpty:u,labelId:b,MenuProps:S,onClose:_,onOpen:w,open:E,renderValue:O,SelectDisplayProps:{id:p,...L}},...m,classes:m?zn(q,m.classes):q,...g?g.props.inputProps:{}},...(C&&T||u)&&z==="outlined"?{notched:!0}:{},ref:G,className:Le(U.props.className,a,B.root),...!g&&{variant:z},...$})})});process.env.NODE_ENV!=="production"&&(Eg.propTypes={autoWidth:c.bool,children:c.node,classes:c.object,className:c.string,defaultOpen:c.bool,defaultValue:c.any,displayEmpty:c.bool,IconComponent:c.elementType,id:c.string,input:c.element,inputProps:c.object,label:c.node,labelId:c.string,MenuProps:c.object,multiple:c.bool,native:c.bool,onChange:c.func,onClose:c.func,onOpen:c.func,open:c.bool,renderValue:c.func,SelectDisplayProps:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),value:c.oneOfType([c.oneOf([""]),c.any]),variant:c.oneOf(["filled","outlined","standard"])}),Eg.muiName="Select";function d4(t){return Ke("MuiTextField",t)}qe("MuiTextField",["root"]);const f4={standard:dd,filled:fd,outlined:pd},p4=t=>{const{classes:e}=t;return Ue({root:["root"]},d4,e)},h4=be(ug,{name:"MuiTextField",slot:"Root",overridesResolver:(t,e)=>e.root})({}),Ow=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiTextField"}),{autoComplete:o,autoFocus:i=!1,children:s,className:a,color:l="primary",defaultValue:u,disabled:f=!1,error:p=!1,FormHelperTextProps:g,fullWidth:m=!1,helperText:y,id:b,InputLabelProps:S,inputProps:C,InputProps:T,inputRef:_,label:w,maxRows:E,minRows:O,multiline:L=!1,name:P,onBlur:$,onChange:M,onFocus:A,placeholder:N,required:z=!1,rows:V,select:B=!1,SelectProps:R,slots:q={},slotProps:U={},type:G,value:Y,variant:Z="outlined",...fe}=r,pe={...r,autoFocus:i,color:l,disabled:f,error:p,fullWidth:m,multiline:L,required:z,select:B,variant:Z},me=p4(pe);process.env.NODE_ENV!=="production"&&B&&!s&&console.error("MUI: `children` must be passed when using the `TextField` component with `select`.");const re=vo(b),he=y&&re?`${re}-helper-text`:void 0,le=w&&re?`${re}-label`:void 0,X=f4[Z],W={slots:q,slotProps:{input:T,inputLabel:S,htmlInput:C,formHelperText:g,select:R,...U}},ee={},ce=W.slotProps.inputLabel;Z==="outlined"&&(ce&&typeof ce.shrink<"u"&&(ee.notched=ce.shrink),ee.label=w),B&&((!R||!R.native)&&(ee.id=void 0),ee["aria-describedby"]=void 0);const[te,se]=zt("root",{elementType:h4,shouldForwardComponentProp:!0,externalForwardedProps:{...W,...fe},ownerState:pe,className:Le(me.root,a),ref:n,additionalProps:{disabled:f,error:p,fullWidth:m,required:z,color:l,variant:Z}}),[ue,ye]=zt("input",{elementType:X,externalForwardedProps:W,additionalProps:ee,ownerState:pe}),[_e,Se]=zt("inputLabel",{elementType:cg,externalForwardedProps:W,ownerState:pe}),[Me,Fe]=zt("htmlInput",{elementType:"input",externalForwardedProps:W,ownerState:pe}),[je,Je]=zt("formHelperText",{elementType:dg,externalForwardedProps:W,ownerState:pe}),[De,ct]=zt("select",{elementType:Eg,externalForwardedProps:W,ownerState:pe}),Ct=v.jsx(ue,{"aria-describedby":he,autoComplete:o,autoFocus:i,defaultValue:u,fullWidth:m,multiline:L,name:P,rows:V,maxRows:E,minRows:O,type:G,value:Y,id:re,inputRef:_,onBlur:$,onChange:M,onFocus:A,placeholder:N,inputProps:Fe,slots:{input:q.htmlInput?Me:void 0},...ye});return v.jsxs(te,{...se,children:[w!=null&&w!==""&&v.jsx(_e,{htmlFor:re,id:le,...Se,children:w}),B?v.jsx(De,{"aria-describedby":he,id:re,labelId:le,value:Y,input:Ct,...ct,children:s}):Ct,y&&v.jsx(je,{id:he,...Je,children:y})]})});process.env.NODE_ENV!=="production"&&(Ow.propTypes={autoComplete:c.string,autoFocus:c.bool,children:c.node,classes:c.object,className:c.string,color:c.oneOfType([c.oneOf(["primary","secondary","error","info","success","warning"]),c.string]),defaultValue:c.any,disabled:c.bool,error:c.bool,FormHelperTextProps:c.object,fullWidth:c.bool,helperText:c.node,id:c.string,InputLabelProps:c.object,inputProps:c.object,InputProps:c.object,inputRef:mn,label:c.node,margin:c.oneOf(["dense","none","normal"]),maxRows:c.oneOfType([c.number,c.string]),minRows:c.oneOfType([c.number,c.string]),multiline:c.bool,name:c.string,onBlur:c.func,onChange:c.func,onFocus:c.func,placeholder:c.string,required:c.bool,rows:c.oneOfType([c.number,c.string]),select:c.bool,SelectProps:c.object,size:c.oneOfType([c.oneOf(["medium","small"]),c.string]),slotProps:c.shape({formHelperText:c.oneOfType([c.func,c.object]),htmlInput:c.oneOfType([c.func,c.object]),input:c.oneOfType([c.func,c.object]),inputLabel:c.oneOfType([c.func,c.object]),select:c.oneOfType([c.func,c.object])}),slots:c.shape({formHelperText:c.elementType,htmlInput:c.elementType,input:c.elementType,inputLabel:c.elementType,root:c.elementType,select:c.elementType}),sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),type:c.string,value:c.any,variant:c.oneOf(["filled","outlined","standard"])});const Gl=(t,e)=>t.length!==e.length?!1:e.every(n=>t.includes(n)),g4=({openTo:t,defaultOpenTo:e,views:n,defaultViews:r})=>{const o=n??r;let i;if(t!=null)i=t;else if(o.includes(e))i=e;else if(o.length>0)i=o[0];else throw new Error("MUI X: The `views` prop must contain at least one view.");return{views:o,openTo:i}},bd=(t,e,n)=>{let r=e;return r=t.setHours(r,t.getHours(n)),r=t.setMinutes(r,t.getMinutes(n)),r=t.setSeconds(r,t.getSeconds(n)),r=t.setMilliseconds(r,t.getMilliseconds(n)),r},Jl=({date:t,disableFuture:e,disablePast:n,maxDate:r,minDate:o,isDateDisabled:i,utils:s,timezone:a})=>{const l=bd(s,s.date(void 0,a),t);n&&s.isBefore(o,l)&&(o=l),e&&s.isAfter(r,l)&&(r=l);let u=t,f=t;for(s.isBefore(t,o)&&(u=o,f=null),s.isAfter(t,r)&&(f&&(f=r),u=null);u||f;){if(u&&s.isAfter(u,r)&&(u=null),f&&s.isBefore(f,o)&&(f=null),u){if(!i(u))return u;u=s.addDays(u,1)}if(f){if(!i(f))return f;f=s.addDays(f,-1)}}return null},m4=(t,e)=>e==null||!t.isValid(e)?null:e,Nr=(t,e,n)=>e==null||!t.isValid(e)?n:e,y4=(t,e,n)=>!t.isValid(e)&&e!=null&&!t.isValid(n)&&n!=null?!0:t.isEqual(e,n),Mg=(t,e)=>{const r=[t.startOfYear(e)];for(;r.length<12;){const o=r[r.length-1];r.push(t.addMonths(o,1))}return r},Aw=(t,e,n)=>n==="date"?t.startOfDay(t.date(void 0,e)):t.date(void 0,e),b4=["year","month","day"],Iw=t=>b4.includes(t),Og=(t,{format:e,views:n},r)=>{if(e!=null)return e;const o=t.formats;return Gl(n,["year"])?o.year:Gl(n,["month"])?o.month:Gl(n,["day"])?o.dayOfMonth:Gl(n,["month","year"])?`${o.month} ${o.year}`:Gl(n,["day","month"])?`${o.month} ${o.dayOfMonth}`:r?/en/.test(t.getCurrentLocaleCode())?o.normalDateWithWeekday:o.normalDate:o.keyboardDate},v4=(t,e)=>{const n=t.startOfWeek(e);return[0,1,2,3,4,5,6].map(r=>t.addDays(n,r))},x4=["hours","minutes","seconds"],S4=t=>x4.includes(t),Dw=(t,e)=>e.getHours(t)*3600+e.getMinutes(t)*60+e.getSeconds(t),C4=(t,e)=>(n,r)=>t?e.isAfter(n,r):Dw(n,e)>Dw(r,e),Co={year:1,month:2,day:3,hours:4,minutes:5,seconds:6,milliseconds:7},w4=t=>Math.max(...t.map(e=>Co[e.type]??1)),Zl=(t,e,n)=>{if(e===Co.year)return t.startOfYear(n);if(e===Co.month)return t.startOfMonth(n);if(e===Co.day)return t.startOfDay(n);let r=n;return e<Co.minutes&&(r=t.setMinutes(r,0)),e<Co.seconds&&(r=t.setSeconds(r,0)),e<Co.milliseconds&&(r=t.setMilliseconds(r,0)),r},_4=({props:t,utils:e,granularity:n,timezone:r,getTodayDate:o})=>{let i=o?o():Zl(e,n,Aw(e,r));t.minDate!=null&&e.isAfterDay(t.minDate,i)&&(i=Zl(e,n,t.minDate)),t.maxDate!=null&&e.isBeforeDay(t.maxDate,i)&&(i=Zl(e,n,t.maxDate));const s=C4(t.disableIgnoringDatePartForTimeValidation??!1,e);return t.minTime!=null&&s(t.minTime,i)&&(i=Zl(e,n,t.disableIgnoringDatePartForTimeValidation?t.minTime:bd(e,i,t.minTime))),t.maxTime!=null&&s(i,t.maxTime)&&(i=Zl(e,n,t.disableIgnoringDatePartForTimeValidation?t.maxTime:bd(e,i,t.maxTime))),i},Ag=(t,e)=>{const n=t.formatTokenMap[e];if(n==null)throw new Error([`MUI X: The token "${e}" is not supported by the Date and Time Pickers.`,"Please try using another token or open an issue on https://github.com/mui/mui-x/issues/new/choose if you think it should be supported."].join(`
|
|
123
123
|
`));return typeof n=="string"?{type:n,contentType:n==="meridiem"?"letter":"digit",maxLength:void 0}:{type:n.sectionType,contentType:n.contentType,maxLength:n.maxLength}},T4=t=>{switch(t){case"ArrowUp":return 1;case"ArrowDown":return-1;case"PageUp":return 5;case"PageDown":return-5;default:return 0}},vd=(t,e)=>{const n=[],r=t.date(void 0,"default"),o=t.startOfWeek(r),i=t.endOfWeek(r);let s=o;for(;t.isBefore(s,i);)n.push(s),s=t.addDays(s,1);return n.map(a=>t.formatByString(a,e))},Pw=(t,e,n,r)=>{switch(n){case"month":return Mg(t,t.date(void 0,e)).map(o=>t.formatByString(o,r));case"weekDay":return vd(t,r);case"meridiem":{const o=t.date(void 0,e);return[t.startOfDay(o),t.endOfDay(o)].map(i=>t.formatByString(i,r))}default:return[]}},Nw="s",k4=["0","1","2","3","4","5","6","7","8","9"],E4=t=>{const e=t.date(void 0);return t.formatByString(t.setSeconds(e,0),Nw)==="0"?k4:Array.from({length:10}).map((r,o)=>t.formatByString(t.setSeconds(e,o),Nw))},gs=(t,e)=>{if(e[0]==="0")return t;const n=[];let r="";for(let o=0;o<t.length;o+=1){r+=t[o];const i=e.indexOf(r);i>-1&&(n.push(i.toString()),r="")}return n.join("")},Ig=(t,e)=>e[0]==="0"?t:t.split("").map(n=>e[Number(n)]).join(""),Lw=(t,e)=>{const n=gs(t,e);return n!==" "&&!Number.isNaN(Number(n))},Fw=(t,e)=>{let n=t;for(n=Number(n).toString();n.length<e;)n=`0${n}`;return n},$w=(t,e,n,r,o)=>{if(process.env.NODE_ENV!=="production"&&o.type!=="day"&&o.contentType==="digit-with-letter")throw new Error([`MUI X: The token "${o.format}" is a digit format with letter in it.'
|
|
124
124
|
This type of format is only supported for 'day' sections`].join(`
|
|
125
125
|
`));if(o.type==="day"&&o.contentType==="digit-with-letter"){const s=t.setDate(n.longestMonth,e);return t.formatByString(s,o.format)}let i=e.toString();return o.hasLeadingZerosInInput&&(i=Fw(i,o.maxLength)),Ig(i,r)},M4=(t,e,n,r,o,i,s,a)=>{const l=T4(r),u=r==="Home",f=r==="End",p=n.value===""||u||f,g=()=>{const y=o[n.type]({currentDate:s,format:n.format,contentType:n.contentType}),b=_=>$w(t,_,y,i,n),S=n.type==="minutes"&&(a!=null&&a.minutesStep)?a.minutesStep:1;let T=parseInt(gs(n.value,i),10)+l*S;if(p){if(n.type==="year"&&!f&&!u)return t.formatByString(t.date(void 0,e),n.format);l>0||u?T=y.minimum:T=y.maximum}return T%S!==0&&((l<0||u)&&(T+=S-(S+T)%S),(l>0||f)&&(T-=T%S)),T>y.maximum?b(y.minimum+(T-y.maximum-1)%(y.maximum-y.minimum+1)):T<y.minimum?b(y.maximum-(y.minimum-T-1)%(y.maximum-y.minimum+1)):b(T)},m=()=>{const y=Pw(t,e,n.type,n.format);if(y.length===0)return n.value;if(p)return l>0||u?y[0]:y[y.length-1];const C=((y.indexOf(n.value)+l)%y.length+y.length)%y.length;return y[C]};return n.contentType==="digit"||n.contentType==="digit-with-letter"?g():m()},Dg=(t,e,n)=>{let r=t.value||t.placeholder;const o=e==="non-input"?t.hasLeadingZerosInFormat:t.hasLeadingZerosInInput;return e==="non-input"&&t.hasLeadingZerosInInput&&!t.hasLeadingZerosInFormat&&(r=Number(gs(r,n)).toString()),["input-rtl","input-ltr"].includes(e)&&t.contentType==="digit"&&!o&&r.length===1&&(r=`${r}`),e==="input-rtl"&&(r=`${r}`),r},Bw=(t,e,n,r)=>{if(process.env.NODE_ENV!=="production"&&Ag(t,n).type==="weekDay")throw new Error("changeSectionValueFormat doesn't support week day formats");return t.formatByString(t.parse(e,n),r)},Rw=(t,e)=>t.formatByString(t.date(void 0,"system"),e).length===4,zw=(t,e,n,r)=>{if(e!=="digit")return!1;const o=t.date(void 0,"default");switch(n){case"year":return Rw(t,r)?t.formatByString(t.setYear(o,1),r)==="0001":t.formatByString(t.setYear(o,2001),r)==="01";case"month":return t.formatByString(t.startOfYear(o),r).length>1;case"day":return t.formatByString(t.startOfMonth(o),r).length>1;case"weekDay":return t.formatByString(t.startOfWeek(o),r).length>1;case"hours":return t.formatByString(t.setHours(o,1),r).length>1;case"minutes":return t.formatByString(t.setMinutes(o,1),r).length>1;case"seconds":return t.formatByString(t.setSeconds(o,1),r).length>1;default:throw new Error("Invalid section type")}},O4=(t,e,n)=>{const r=e.some(l=>l.type==="day"),o=[],i=[];for(let l=0;l<e.length;l+=1){const u=e[l];r&&u.type==="weekDay"||(o.push(u.format),i.push(Dg(u,"non-input",n)))}const s=o.join(" "),a=i.join(" ");return t.parse(a,s)},A4=t=>t.map(e=>`${e.startSeparator}${e.value||e.placeholder}${e.endSeparator}`).join(""),I4=(t,e,n)=>{const o=t.map(i=>{const s=Dg(i,n?"input-rtl":"input-ltr",e);return`${i.startSeparator}${s}${i.endSeparator}`}).join("");return n?`${o}`:o},D4=(t,e,n)=>{const r=t.date(void 0,n),o=t.endOfYear(r),i=t.endOfDay(r),{maxDaysInMonth:s,longestMonth:a}=Mg(t,r).reduce((l,u)=>{const f=t.getDaysInMonth(u);return f>l.maxDaysInMonth?{maxDaysInMonth:f,longestMonth:u}:l},{maxDaysInMonth:0,longestMonth:null});return{year:({format:l})=>({minimum:0,maximum:Rw(t,l)?9999:99}),month:()=>({minimum:1,maximum:t.getMonth(o)+1}),day:({currentDate:l})=>({minimum:1,maximum:l!=null&&t.isValid(l)?t.getDaysInMonth(l):s,longestMonth:a}),weekDay:({format:l,contentType:u})=>{if(u==="digit"){const f=vd(t,l).map(Number);return{minimum:Math.min(...f),maximum:Math.max(...f)}}return{minimum:1,maximum:7}},hours:({format:l})=>{const u=t.getHours(i);return gs(t.formatByString(t.endOfDay(r),l),e)!==u.toString()?{minimum:1,maximum:Number(gs(t.formatByString(t.startOfDay(r),l),e))}:{minimum:0,maximum:u}},minutes:()=>({minimum:0,maximum:t.getMinutes(i)}),seconds:()=>({minimum:0,maximum:t.getSeconds(i)}),meridiem:()=>({minimum:0,maximum:1}),empty:()=>({minimum:0,maximum:0})}};let Vw=!1;const Hw=(t,e)=>{if(process.env.NODE_ENV!=="production"&&!Vw){const n=["empty"];["date","date-time"].includes(e)&&n.push("weekDay","day","month","year"),["time","date-time"].includes(e)&&n.push("hours","minutes","seconds","meridiem");const r=t.find(o=>!n.includes(o.type));r&&(console.warn(`MUI X: The field component you are using is not compatible with the "${r.type}" date section.`,`The supported date sections are ["${n.join('", "')}"]\`.`),Vw=!0)}},P4=(t,e,n,r)=>{switch(e.type){case"year":return t.setYear(r,t.getYear(n));case"month":return t.setMonth(r,t.getMonth(n));case"weekDay":{const o=vd(t,e.format),i=t.formatByString(n,e.format),s=o.indexOf(i),l=o.indexOf(e.value)-s;return t.addDays(n,l)}case"day":return t.setDate(r,t.getDate(n));case"meridiem":{const o=t.getHours(n)<12,i=t.getHours(r);return o&&i>=12?t.addHours(r,-12):!o&&i<12?t.addHours(r,12):r}case"hours":return t.setHours(r,t.getHours(n));case"minutes":return t.setMinutes(r,t.getMinutes(n));case"seconds":return t.setSeconds(r,t.getSeconds(n));default:return r}},jw={year:1,month:2,day:3,weekDay:4,hours:5,minutes:6,seconds:7,meridiem:8,empty:9},Ww=(t,e,n,r,o)=>[...n].sort((i,s)=>jw[i.type]-jw[s.type]).reduce((i,s)=>!o||s.modified?P4(t,s,e,i):i,r),N4=()=>navigator.userAgent.toLowerCase().includes("android"),L4=(t,e)=>{const n={};if(!e)return t.forEach((l,u)=>{const f=u===0?null:u-1,p=u===t.length-1?null:u+1;n[u]={leftIndex:f,rightIndex:p}}),{neighbors:n,startIndex:0,endIndex:t.length-1};const r={},o={};let i=0,s=0,a=t.length-1;for(;a>=0;){s=t.findIndex((l,u)=>{var f;return u>=i&&((f=l.endSeparator)==null?void 0:f.includes(" "))&&l.endSeparator!==" / "}),s===-1&&(s=t.length-1);for(let l=s;l>=i;l-=1)o[l]=a,r[a]=l,a-=1;i=s+1}return t.forEach((l,u)=>{const f=o[u],p=f===0?null:r[f-1],g=f===t.length-1?null:r[f+1];n[u]={leftIndex:p,rightIndex:g}}),{neighbors:n,startIndex:r[0],endIndex:r[t.length-1]}},Pg=(t,e)=>{if(t==null)return null;if(t==="all")return"all";if(typeof t=="string"){const n=e.findIndex(r=>r.type===t);return n===-1?null:n}return t},F4=(t,e)=>{if(t.value)switch(t.type){case"month":{if(t.contentType==="digit")return e.format(e.setMonth(e.date(),Number(t.value)-1),"month");const n=e.parse(t.value,t.format);return n?e.format(n,"month"):void 0}case"day":return t.contentType==="digit"?e.format(e.setDate(e.startOfYear(e.date()),Number(t.value)),"dayOfMonthFull"):t.value;case"weekDay":return;default:return}},$4=(t,e)=>{if(t.value)switch(t.type){case"weekDay":return t.contentType==="letter"?void 0:Number(t.value);case"meridiem":{const n=e.parse(`01:00 ${t.value}`,`${e.formats.hours12h}:${e.formats.minutes} ${t.format}`);return n?e.getHours(n)>=12?1:0:void 0}case"day":return t.contentType==="digit-with-letter"?parseInt(t.value,10):Number(t.value);case"month":{if(t.contentType==="digit")return Number(t.value);const n=e.parse(t.value,t.format);return n?e.getMonth(n)+1:void 0}default:return t.contentType!=="letter"?Number(t.value):void 0}},B4=["value","referenceDate"],wo={emptyValue:null,getTodayValue:Aw,getInitialReferenceValue:t=>{let{value:e,referenceDate:n}=t,r=rt(t,B4);return e!=null&&r.utils.isValid(e)?e:n??_4(r)},cleanValue:m4,areValuesEqual:y4,isSameError:(t,e)=>t===e,hasError:t=>t!=null,defaultErrorState:null,getTimezone:(t,e)=>e==null||!t.isValid(e)?null:t.getTimezone(e),setTimezone:(t,e,n)=>n==null?null:t.setTimezone(n,e)},R4={updateReferenceValue:(t,e,n)=>e==null||!t.isValid(e)?n:e,getSectionsFromValue:(t,e,n,r)=>!t.isValid(e)&&!!n?n:r(e),getV7HiddenInputValueFromSections:A4,getV6InputValueFromSections:I4,getActiveDateManager:(t,e)=>({date:e.value,referenceDate:e.referenceValue,getSections:n=>n,getNewValuesFromNewActiveDate:n=>({value:n,referenceValue:n==null||!t.isValid(n)?e.referenceValue:n})}),parseValueStr:(t,e,n)=>n(t.trim(),e)},Xl=({props:t,value:e,timezone:n,adapter:r})=>{if(e===null)return null;const{shouldDisableDate:o,shouldDisableMonth:i,shouldDisableYear:s,disablePast:a,disableFuture:l}=t,u=r.utils.date(void 0,n),f=Nr(r.utils,t.minDate,r.defaultDates.minDate),p=Nr(r.utils,t.maxDate,r.defaultDates.maxDate);switch(!0){case!r.utils.isValid(e):return"invalidDate";case!!(o&&o(e)):return"shouldDisableDate";case!!(i&&i(e)):return"shouldDisableMonth";case!!(s&&s(e)):return"shouldDisableYear";case!!(l&&r.utils.isAfterDay(e,u)):return"disableFuture";case!!(a&&r.utils.isBeforeDay(e,u)):return"disablePast";case!!(f&&r.utils.isBeforeDay(e,f)):return"minDate";case!!(p&&r.utils.isAfterDay(e,p)):return"maxDate";default:return null}};Xl.valueManager=wo;const qw=["disablePast","disableFuture","minDate","maxDate","shouldDisableDate","shouldDisableMonth","shouldDisableYear"],z4=["disablePast","disableFuture","minTime","maxTime","shouldDisableTime","minutesStep","ampm","disableIgnoringDatePartForTimeValidation"],V4=["minDateTime","maxDateTime"],H4=[...qw,...z4,...V4],Uw=t=>H4.reduce((e,n)=>(t.hasOwnProperty(n)&&(e[n]=t[n]),e),{}),j4=t=>({components:{MuiLocalizationProvider:{defaultProps:{localeText:ne({},t)}}}}),Kw=t=>{const{utils:e,formatKey:n,contextTranslation:r,propsTranslation:o}=t;return i=>{const s=i!==null&&e.isValid(i)?e.format(i,n):null;return(o??r)(i,e,s)}},Yw={previousMonth:"Previous month",nextMonth:"Next month",openPreviousView:"Open previous view",openNextView:"Open next view",calendarViewSwitchingButtonAriaLabel:t=>t==="year"?"year view is open, switch to calendar view":"calendar view is open, switch to year view",start:"Start",end:"End",startDate:"Start date",startTime:"Start time",endDate:"End date",endTime:"End time",cancelButtonLabel:"Cancel",clearButtonLabel:"Clear",okButtonLabel:"OK",todayButtonLabel:"Today",datePickerToolbarTitle:"Select date",dateTimePickerToolbarTitle:"Select date & time",timePickerToolbarTitle:"Select time",dateRangePickerToolbarTitle:"Select date range",clockLabelText:(t,e,n,r)=>`Select ${t}. ${!r&&(e===null||!n.isValid(e))?"No time selected":`Selected time is ${r??n.format(e,"fullTime")}`}`,hoursClockNumberText:t=>`${t} hours`,minutesClockNumberText:t=>`${t} minutes`,secondsClockNumberText:t=>`${t} seconds`,selectViewText:t=>`Select ${t}`,calendarWeekNumberHeaderLabel:"Week number",calendarWeekNumberHeaderText:"#",calendarWeekNumberAriaLabelText:t=>`Week ${t}`,calendarWeekNumberText:t=>`${t}`,openDatePickerDialogue:(t,e,n)=>n||t!==null&&e.isValid(t)?`Choose date, selected date is ${n??e.format(t,"fullDate")}`:"Choose date",openTimePickerDialogue:(t,e,n)=>n||t!==null&&e.isValid(t)?`Choose time, selected time is ${n??e.format(t,"fullTime")}`:"Choose time",fieldClearLabel:"Clear",timeTableLabel:"pick time",dateTableLabel:"pick date",fieldYearPlaceholder:t=>"Y".repeat(t.digitAmount),fieldMonthPlaceholder:t=>t.contentType==="letter"?"MMMM":"MM",fieldDayPlaceholder:()=>"DD",fieldWeekDayPlaceholder:t=>t.contentType==="letter"?"EEEE":"EE",fieldHoursPlaceholder:()=>"hh",fieldMinutesPlaceholder:()=>"mm",fieldSecondsPlaceholder:()=>"ss",fieldMeridiemPlaceholder:()=>"aa",year:"Year",month:"Month",day:"Day",weekDay:"Week day",hours:"Hours",minutes:"Minutes",seconds:"Seconds",meridiem:"Meridiem",empty:"Empty"},W4=Yw;j4(Yw);const ms=()=>{const t=I.useContext(Zu);if(t===null)throw new Error(["MUI X: Can not find the date and time pickers localization context.","It looks like you forgot to wrap your component in LocalizationProvider.","This can also happen if you are bundling multiple versions of the `@mui/x-date-pickers` package"].join(`
|
|
126
126
|
`));if(t.utils===null)throw new Error(["MUI X: Can not find the date and time pickers adapter from its localization context.","It looks like you forgot to pass a `dateAdapter` to your LocalizationProvider."].join(`
|
|
127
|
-
`));const e=I.useMemo(()=>ne({},W4,t.localeText),[t.localeText]);return I.useMemo(()=>ne({},t,{localeText:e}),[t,e])},qt=()=>ms().utils,Ql=()=>ms().defaultDates,xd=t=>{const e=qt(),n=I.useRef();return n.current===void 0&&(n.current=e.date(void 0,t)),n.current};function Gw(t){const{props:e,validator:n,value:r,timezone:o,onError:i}=t,s=ms(),a=I.useRef(n.valueManager.defaultErrorState),l=n({adapter:s,value:r,timezone:o,props:e}),u=n.valueManager.hasError(l);I.useEffect(()=>{i&&!n.valueManager.isSameError(l,a.current)&&i(l,r),a.current=l},[n,i,l,r]);const f=Be(p=>n({adapter:s,value:p,timezone:o,props:e}));return{validationError:l,hasValidationError:u,getValidationErrorForNewValue:f}}const Ko=()=>ms().localeText,q4=({utils:t,format:e})=>{let n=10,r=e,o=t.expandFormat(e);for(;o!==r;)if(r=o,o=t.expandFormat(r),n-=1,n<0)throw new Error("MUI X: The format expansion seems to be in an infinite loop. Please open an issue with the format passed to the picker component.");return o},U4=({utils:t,expandedFormat:e})=>{const n=[],{start:r,end:o}=t.escapedCharacters,i=new RegExp(`(\\${r}[^\\${o}]*\\${o})+`,"g");let s=null;for(;s=i.exec(e);)n.push({start:s.index,end:i.lastIndex-1});return n},K4=(t,e,n,r)=>{switch(n.type){case"year":return e.fieldYearPlaceholder({digitAmount:t.formatByString(t.date(void 0,"default"),r).length,format:r});case"month":return e.fieldMonthPlaceholder({contentType:n.contentType,format:r});case"day":return e.fieldDayPlaceholder({format:r});case"weekDay":return e.fieldWeekDayPlaceholder({contentType:n.contentType,format:r});case"hours":return e.fieldHoursPlaceholder({format:r});case"minutes":return e.fieldMinutesPlaceholder({format:r});case"seconds":return e.fieldSecondsPlaceholder({format:r});case"meridiem":return e.fieldMeridiemPlaceholder({format:r});default:return r}},Y4=({utils:t,date:e,shouldRespectLeadingZeros:n,localeText:r,localizedDigits:o,now:i,token:s,startSeparator:a})=>{if(s==="")throw new Error("MUI X: Should not call `commitToken` with an empty token");const l=Ag(t,s),u=zw(t,l.contentType,l.type,s),f=n?u:l.contentType==="digit",p=e!=null&&t.isValid(e);let g=p?t.formatByString(e,s):"",m=null;if(f)if(u)m=g===""?t.formatByString(i,s).length:g.length;else{if(l.maxLength==null)throw new Error(`MUI X: The token ${s} should have a 'maxDigitNumber' property on it's adapter`);m=l.maxLength,p&&(g=Ig(Fw(gs(g,o),m),o))}return ne({},l,{format:s,maxLength:m,value:g,placeholder:K4(t,r,l,s),hasLeadingZerosInFormat:u,hasLeadingZerosInInput:f,startSeparator:a,endSeparator:"",modified:!1})},G4=t=>{var m;const{utils:e,expandedFormat:n,escapedParts:r}=t,o=e.date(void 0),i=[];let s="";const a=Object.keys(e.formatTokenMap).sort((y,b)=>b.length-y.length),l=/^([a-zA-Z]+)/,u=new RegExp(`^(${a.join("|")})*$`),f=new RegExp(`^(${a.join("|")})`),p=y=>r.find(b=>b.start<=y&&b.end>=y);let g=0;for(;g<n.length;){const y=p(g),b=y!=null,S=(m=l.exec(n.slice(g)))==null?void 0:m[1];if(!b&&S!=null&&u.test(S)){let C=S;for(;C.length>0;){const T=f.exec(C)[1];C=C.slice(T.length),i.push(Y4(ne({},t,{now:o,token:T,startSeparator:s}))),s=""}g+=S.length}else{const C=n[g];b&&(y==null?void 0:y.start)===g||(y==null?void 0:y.end)===g||(i.length===0?s+=C:i[i.length-1].endSeparator+=C),g+=1}}return i.length===0&&s.length>0&&i.push({type:"empty",contentType:"letter",maxLength:null,format:"",value:"",placeholder:"",hasLeadingZerosInFormat:!1,hasLeadingZerosInInput:!1,startSeparator:s,endSeparator:"",modified:!1}),i},J4=({isRtl:t,formatDensity:e,sections:n})=>n.map(r=>{const o=i=>{let s=i;return t&&s!==null&&s.includes(" ")&&(s=`${s}`),e==="spacious"&&["/",".","-"].includes(s)&&(s=` ${s} `),s};return r.startSeparator=o(r.startSeparator),r.endSeparator=o(r.endSeparator),r}),Jw=t=>{let e=q4(t);t.isRtl&&t.enableAccessibleFieldDOMStructure&&(e=e.split(" ").reverse().join(" "));const n=U4(ne({},t,{expandedFormat:e})),r=G4(ne({},t,{expandedFormat:e,escapedParts:n}));return J4(ne({},t,{sections:r}))},Ng=({timezone:t,value:e,defaultValue:n,referenceDate:r,onChange:o,valueManager:i})=>{const s=qt(),a=I.useRef(n),l=e??a.current??i.emptyValue,u=I.useMemo(()=>i.getTimezone(s,l),[s,i,l]),f=Be(y=>u==null?y:i.setTimezone(s,u,y));let p;t?p=t:u?p=u:r?p=s.getTimezone(r):p="default";const g=I.useMemo(()=>i.setTimezone(s,p,l),[i,s,p,l]),m=Be((y,...b)=>{const S=f(y);o==null||o(S,...b)});return{value:g,handleValueChange:m,timezone:p}},Lg=({name:t,timezone:e,value:n,defaultValue:r,referenceDate:o,onChange:i,valueManager:s})=>{const[a,l]=jo({name:t,state:"value",controlled:n,default:r??s.emptyValue}),u=Be((f,...p)=>{l(f),i==null||i(f,...p)});return Ng({timezone:e,value:a,defaultValue:void 0,referenceDate:o,onChange:u,valueManager:s})},Z4=t=>{const e=qt(),n=Ko(),r=ms(),o=no(),{valueManager:i,fieldValueManager:s,valueType:a,validator:l,internalProps:u,internalProps:{value:f,defaultValue:p,referenceDate:g,onChange:m,format:y,formatDensity:b="dense",selectedSections:S,onSelectedSectionsChange:C,shouldRespectLeadingZeros:T=!1,timezone:_,enableAccessibleFieldDOMStructure:w=!1}}=t,{timezone:E,value:O,handleValueChange:L}=Ng({timezone:_,value:f,defaultValue:p,referenceDate:g,onChange:m,valueManager:i}),P=I.useMemo(()=>E4(e),[e]),$=I.useMemo(()=>D4(e,P,E),[e,P,E]),M=I.useCallback((Q,fe=null)=>s.getSectionsFromValue(e,Q,fe,ce=>Jw({utils:e,localeText:n,localizedDigits:P,format:y,date:ce,formatDensity:b,shouldRespectLeadingZeros:T,enableAccessibleFieldDOMStructure:w,isRtl:o})),[s,y,n,P,o,T,e,b,w]),[A,N]=I.useState(()=>{const Q=M(O);Hw(Q,a);const fe={sections:Q,value:O,referenceValue:i.emptyValue,tempValueStrAndroid:null},ce=w4(Q),ae=i.getInitialReferenceValue({referenceDate:g,value:O,utils:e,props:u,granularity:ce,timezone:E});return ne({},fe,{referenceValue:ae})}),[V,R]=jo({controlled:S,default:null,name:"useField",state:"selectedSections"}),B=Q=>{R(Q),C==null||C(Q)},z=I.useMemo(()=>Pg(V,A.sections),[V,A.sections]),q=z==="all"?0:z,K=({value:Q,referenceValue:fe,sections:ce})=>{if(N(W=>ne({},W,{sections:ce,value:Q,referenceValue:fe,tempValueStrAndroid:null})),i.areValuesEqual(e,A.value,Q))return;const ae={validationError:l({adapter:r,value:Q,timezone:E,props:u})};L(Q,ae)},G=(Q,fe)=>{const ce=[...A.sections];return ce[Q]=ne({},ce[Q],{value:fe,modified:!0}),ce},Y=()=>{K({value:i.emptyValue,referenceValue:A.referenceValue,sections:M(i.emptyValue)})},Z=()=>{if(q==null)return;const Q=A.sections[q],fe=s.getActiveDateManager(e,A,Q),ae=fe.getSections(A.sections).filter(ee=>ee.value!=="").length===(Q.value===""?0:1),W=G(q,""),te=ae?null:e.getInvalidDate(),ue=fe.getNewValuesFromNewActiveDate(te);K(ne({},ue,{sections:W}))},me=Q=>{const fe=(W,te)=>{const ue=e.parse(W,y);if(ue==null||!e.isValid(ue))return null;const ee=Jw({utils:e,localeText:n,localizedDigits:P,format:y,date:ue,formatDensity:b,shouldRespectLeadingZeros:T,enableAccessibleFieldDOMStructure:w,isRtl:o});return Ww(e,ue,ee,te,!1)},ce=s.parseValueStr(Q,A.referenceValue,fe),ae=s.updateReferenceValue(e,ce,A.referenceValue);K({value:ce,referenceValue:ae,sections:M(ce,A.sections)})},he=({activeSection:Q,newSectionValue:fe,shouldGoToNextSection:ce})=>{ce&&q<A.sections.length-1&&B(q+1);const ae=s.getActiveDateManager(e,A,Q),W=G(q,fe),te=ae.getSections(W),ue=O4(e,te,P);let ee,se;if(ue!=null&&e.isValid(ue)){const de=Ww(e,ue,te,ae.referenceDate,!0);ee=ae.getNewValuesFromNewActiveDate(de),se=!0}else ee=ae.getNewValuesFromNewActiveDate(ue),se=(ue!=null&&!e.isValid(ue))!=(ae.date!=null&&!e.isValid(ae.date));return se?K(ne({},ee,{sections:W})):N(de=>ne({},de,ee,{sections:W,tempValueStrAndroid:null}))},oe=Q=>N(fe=>ne({},fe,{tempValueStrAndroid:Q}));return I.useEffect(()=>{const Q=M(A.value);Hw(Q,a),N(fe=>ne({},fe,{sections:Q}))},[y,e.locale,o]),I.useEffect(()=>{let Q;i.areValuesEqual(e,A.value,O)?Q=i.getTimezone(e,A.value)!==i.getTimezone(e,O):Q=!0,Q&&N(fe=>ne({},fe,{value:O,referenceValue:s.updateReferenceValue(e,O,fe.referenceValue),sections:M(O)}))},[O]),{state:A,activeSectionIndex:q,parsedSelectedSections:z,setSelectedSections:B,clearValue:Y,clearActiveSection:Z,updateSectionValue:he,updateValueFromValueStr:me,setTempAndroidValueStr:oe,getSectionsFromValue:M,sectionsValueBoundaries:$,localizedDigits:P,timezone:E}},X4=5e3,ba=t=>t.saveQuery!=null,Q4=({sections:t,updateSectionValue:e,sectionsValueBoundaries:n,localizedDigits:r,setTempAndroidValueStr:o,timezone:i})=>{const s=qt(),[a,l]=I.useState(null),u=Be(()=>l(null));I.useEffect(()=>{var y;a!=null&&((y=t[a.sectionIndex])==null?void 0:y.type)!==a.sectionType&&u()},[t,a,u]),I.useEffect(()=>{if(a!=null){const y=setTimeout(()=>u(),X4);return()=>{clearTimeout(y)}}return()=>{}},[a,u]);const f=({keyPressed:y,sectionIndex:b},S,C)=>{const T=y.toLowerCase(),_=t[b];if(a!=null&&(!C||C(a.value))&&a.sectionIndex===b){const E=`${a.value}${T}`,O=S(E,_);if(!ba(O))return l({sectionIndex:b,value:E,sectionType:_.type}),O}const w=S(T,_);return ba(w)&&!w.saveQuery?(u(),null):(l({sectionIndex:b,value:T,sectionType:_.type}),ba(w)?null:w)},p=y=>{const b=(T,_,w)=>{const E=_.filter(O=>O.toLowerCase().startsWith(w));return E.length===0?{saveQuery:!1}:{sectionValue:E[0],shouldGoToNextSection:E.length===1}},S=(T,_,w,E)=>{const O=L=>Pw(s,i,_.type,L);if(_.contentType==="letter")return b(_.format,O(_.format),T);if(w&&E!=null&&Ag(s,w).contentType==="letter"){const L=O(w),P=b(w,L,T);return ba(P)?{saveQuery:!1}:ne({},P,{sectionValue:E(P.sectionValue,L)})}return{saveQuery:!1}};return f(y,(T,_)=>{switch(_.type){case"month":{const w=E=>Bw(s,E,s.formats.month,_.format);return S(T,_,s.formats.month,w)}case"weekDay":{const w=(E,O)=>O.indexOf(E).toString();return S(T,_,s.formats.weekday,w)}case"meridiem":return S(T,_);default:return{saveQuery:!1}}})},g=y=>{const b=(C,T)=>{const _=gs(C,r),w=Number(_),E=n[T.type]({currentDate:null,format:T.format,contentType:T.contentType});if(w>E.maximum)return{saveQuery:!1};if(w<E.minimum)return{saveQuery:!0};const O=w*10>E.maximum||_.length===E.maximum.toString().length;return{sectionValue:$w(s,w,E,r,T),shouldGoToNextSection:O}};return f(y,(C,T)=>{if(T.contentType==="digit"||T.contentType==="digit-with-letter")return b(C,T);if(T.type==="month"){const _=zw(s,"digit","month","MM"),w=b(C,{type:T.type,format:"MM",hasLeadingZerosInFormat:_,hasLeadingZerosInInput:!0,contentType:"digit",maxLength:2});if(ba(w))return w;const E=Bw(s,w.sectionValue,"MM",T.format);return ne({},w,{sectionValue:E})}if(T.type==="weekDay"){const _=b(C,T);if(ba(_))return _;const w=vd(s,T.format)[Number(_.sectionValue)-1];return ne({},_,{sectionValue:w})}return{saveQuery:!1}},C=>Lw(C,r))};return{applyCharacterEditing:Be(y=>{const b=t[y.sectionIndex],C=Lw(y.keyPressed,r)?g(ne({},y,{keyPressed:Ig(y.keyPressed,r)})):p(y);if(C==null){o(null);return}e({activeSection:b,newSectionValue:C.sectionValue,shouldGoToNextSection:C.shouldGoToNextSection})}),resetCharacterQuery:u}};function eV(t,e){return Array.isArray(e)?e.every(n=>t.indexOf(n)!==-1):t.indexOf(e)!==-1}const tV=(t,e)=>n=>{(n.key==="Enter"||n.key===" ")&&(t(n),n.preventDefault(),n.stopPropagation())},xr=(t=document)=>{const e=t.activeElement;return e?e.shadowRoot?xr(e.shadowRoot):e:null},nV="@media (pointer: fine)",rV=t=>{const{internalProps:{disabled:e,readOnly:n=!1},forwardedProps:{sectionListRef:r,onBlur:o,onClick:i,onFocus:s,onInput:a,onPaste:l,focused:u,autoFocus:f=!1},fieldValueManager:p,applyCharacterEditing:g,resetCharacterQuery:m,setSelectedSections:y,parsedSelectedSections:b,state:S,clearActiveSection:C,clearValue:T,updateSectionValue:_,updateValueFromValueStr:w,sectionOrder:E,areAllSectionsEmpty:O,sectionsValueBoundaries:L}=t,P=I.useRef(null),$=Et(r,P),M=Ko(),A=qt(),N=vo(),[V,R]=I.useState(!1),B=I.useMemo(()=>({syncSelectionToDOM:()=>{if(!P.current)return;const se=document.getSelection();if(!se)return;if(b==null){se.rangeCount>0&&P.current.getRoot().contains(se.getRangeAt(0).startContainer)&&se.removeAllRanges(),V&&P.current.getRoot().blur();return}if(!P.current.getRoot().contains(xr(document)))return;const de=new window.Range;let ye;b==="all"?ye=P.current.getRoot():S.sections[b].type==="empty"?ye=P.current.getSectionContainer(b):ye=P.current.getSectionContent(b),de.selectNodeContents(ye),ye.focus(),se.removeAllRanges(),se.addRange(de)},getActiveSectionIndexFromDOM:()=>{const se=xr(document);return!se||!P.current||!P.current.getRoot().contains(se)?null:P.current.getSectionIndexFromDOMElement(se)},focusField:(se=0)=>{if(!P.current)return;const de=Pg(se,S.sections);R(!0),P.current.getSectionContent(de).focus()},setSelectedSections:se=>{if(!P.current)return;const de=Pg(se,S.sections);R((de==="all"?0:de)!==null),y(se)},isFieldFocused:()=>{const se=xr(document);return!!P.current&&P.current.getRoot().contains(se)}}),[b,y,S.sections,V]),z=Be(se=>{if(!P.current)return;const de=S.sections[se];P.current.getSectionContent(se).innerHTML=de.value||de.placeholder,B.syncSelectionToDOM()}),q=Be((se,...de)=>{se.isDefaultPrevented()||!P.current||(R(!0),i==null||i(se,...de),b==="all"?setTimeout(()=>{const ye=document.getSelection().getRangeAt(0).startOffset;if(ye===0){y(E.startIndex);return}let _e=0,Se=0;for(;Se<ye&&_e<S.sections.length;){const Me=S.sections[_e];_e+=1,Se+=`${Me.startSeparator}${Me.value||Me.placeholder}${Me.endSeparator}`.length}y(_e-1)}):V?P.current.getRoot().contains(se.target)||y(E.startIndex):(R(!0),y(E.startIndex)))}),K=Be(se=>{if(a==null||a(se),!P.current||b!=="all")return;const ye=se.target.textContent??"";P.current.getRoot().innerHTML=S.sections.map(_e=>`${_e.startSeparator}${_e.value||_e.placeholder}${_e.endSeparator}`).join(""),B.syncSelectionToDOM(),ye.length===0||ye.charCodeAt(0)===10?(m(),T(),y("all")):ye.length>1?w(ye):g({keyPressed:ye,sectionIndex:0})}),G=Be(se=>{if(l==null||l(se),n||b!=="all"){se.preventDefault();return}const de=se.clipboardData.getData("text");se.preventDefault(),m(),w(de)}),Y=Be((...se)=>{if(s==null||s(...se),V||!P.current)return;R(!0),P.current.getSectionIndexFromDOMElement(xr(document))!=null||y(E.startIndex)}),Z=Be((...se)=>{o==null||o(...se),setTimeout(()=>{if(!P.current)return;const de=xr(document);!P.current.getRoot().contains(de)&&(R(!1),y(null))})}),me=Be(se=>de=>{de.isDefaultPrevented()||y(se)}),he=Be(se=>{se.preventDefault()}),oe=Be(se=>()=>{y(se)}),Q=Be(se=>{if(se.preventDefault(),n||e||typeof b!="number")return;const de=S.sections[b],ye=se.clipboardData.getData("text"),_e=/^[a-zA-Z]+$/.test(ye),Se=/^[0-9]+$/.test(ye),Me=/^(([a-zA-Z]+)|)([0-9]+)(([a-zA-Z]+)|)$/.test(ye);de.contentType==="letter"&&_e||de.contentType==="digit"&&Se||de.contentType==="digit-with-letter"&&Me?(m(),_({activeSection:de,newSectionValue:ye,shouldGoToNextSection:!0})):!_e&&!Se&&(m(),w(ye))}),fe=Be(se=>{se.preventDefault(),se.dataTransfer.dropEffect="none"}),ce=Be(se=>{if(!P.current)return;const de=se.target,ye=de.textContent??"",_e=P.current.getSectionIndexFromDOMElement(de),Se=S.sections[_e];if(n||!P.current){z(_e);return}if(ye.length===0){if(Se.value===""){z(_e);return}const Me=se.nativeEvent.inputType;if(Me==="insertParagraph"||Me==="insertLineBreak"){z(_e);return}m(),C();return}g({keyPressed:ye,sectionIndex:_e}),z(_e)});Tn(()=>{if(!(!V||!P.current)){if(b==="all")P.current.getRoot().focus();else if(typeof b=="number"){const se=P.current.getSectionContent(b);se&&se.focus()}}},[b,V]);const ae=I.useMemo(()=>S.sections.reduce((se,de)=>(se[de.type]=L[de.type]({currentDate:null,contentType:de.contentType,format:de.format}),se),{}),[L,S.sections]),W=b==="all",te=I.useMemo(()=>S.sections.map((se,de)=>{const ye=!W&&!e&&!n;return{container:{"data-sectionindex":de,onClick:me(de)},content:{tabIndex:W||de>0?-1:0,contentEditable:!W&&!e&&!n,role:"spinbutton",id:`${N}-${se.type}`,"aria-labelledby":`${N}-${se.type}`,"aria-readonly":n,"aria-valuenow":$4(se,A),"aria-valuemin":ae[se.type].minimum,"aria-valuemax":ae[se.type].maximum,"aria-valuetext":se.value?F4(se,A):M.empty,"aria-label":M[se.type],"aria-disabled":e,spellCheck:ye?!1:void 0,autoCapitalize:ye?"off":void 0,autoCorrect:ye?"off":void 0,[parseInt(I.version,10)>=17?"enterKeyHint":"enterkeyhint"]:ye?"next":void 0,children:se.value||se.placeholder,onInput:ce,onPaste:Q,onFocus:oe(de),onDragOver:fe,onMouseUp:he,inputMode:se.contentType==="letter"?"text":"numeric"},before:{children:se.startSeparator},after:{children:se.endSeparator}}}),[S.sections,oe,Q,fe,ce,me,he,e,n,W,M,A,ae,N]),ue=Be(se=>{w(se.target.value)}),ee=I.useMemo(()=>O?"":p.getV7HiddenInputValueFromSections(S.sections),[O,S.sections,p]);return I.useEffect(()=>{if(P.current==null)throw new Error(["MUI X: The `sectionListRef` prop has not been initialized by `PickersSectionList`","You probably tried to pass a component to the `textField` slot that contains an `<input />` element instead of a `PickersSectionList`.","","If you want to keep using an `<input />` HTML element for the editing, please remove the `enableAccessibleFieldDOMStructure` prop from your picker or field component:","","<DatePicker slots={{ textField: MyCustomTextField }} />","","Learn more about the field accessible DOM structure on the MUI documentation: https://mui.com/x/react-date-pickers/fields/#fields-to-edit-a-single-element"].join(`
|
|
128
|
-
`));f&&P.current&&P.current.getSectionContent(E.startIndex).focus()},[]),{interactions:B,returnedValue:{autoFocus:f,readOnly:n,focused:u??
|
|
127
|
+
`));const e=I.useMemo(()=>ne({},W4,t.localeText),[t.localeText]);return I.useMemo(()=>ne({},t,{localeText:e}),[t,e])},qt=()=>ms().utils,Ql=()=>ms().defaultDates,xd=t=>{const e=qt(),n=I.useRef();return n.current===void 0&&(n.current=e.date(void 0,t)),n.current};function Gw(t){const{props:e,validator:n,value:r,timezone:o,onError:i}=t,s=ms(),a=I.useRef(n.valueManager.defaultErrorState),l=n({adapter:s,value:r,timezone:o,props:e}),u=n.valueManager.hasError(l);I.useEffect(()=>{i&&!n.valueManager.isSameError(l,a.current)&&i(l,r),a.current=l},[n,i,l,r]);const f=Be(p=>n({adapter:s,value:p,timezone:o,props:e}));return{validationError:l,hasValidationError:u,getValidationErrorForNewValue:f}}const Ko=()=>ms().localeText,q4=({utils:t,format:e})=>{let n=10,r=e,o=t.expandFormat(e);for(;o!==r;)if(r=o,o=t.expandFormat(r),n-=1,n<0)throw new Error("MUI X: The format expansion seems to be in an infinite loop. Please open an issue with the format passed to the picker component.");return o},U4=({utils:t,expandedFormat:e})=>{const n=[],{start:r,end:o}=t.escapedCharacters,i=new RegExp(`(\\${r}[^\\${o}]*\\${o})+`,"g");let s=null;for(;s=i.exec(e);)n.push({start:s.index,end:i.lastIndex-1});return n},K4=(t,e,n,r)=>{switch(n.type){case"year":return e.fieldYearPlaceholder({digitAmount:t.formatByString(t.date(void 0,"default"),r).length,format:r});case"month":return e.fieldMonthPlaceholder({contentType:n.contentType,format:r});case"day":return e.fieldDayPlaceholder({format:r});case"weekDay":return e.fieldWeekDayPlaceholder({contentType:n.contentType,format:r});case"hours":return e.fieldHoursPlaceholder({format:r});case"minutes":return e.fieldMinutesPlaceholder({format:r});case"seconds":return e.fieldSecondsPlaceholder({format:r});case"meridiem":return e.fieldMeridiemPlaceholder({format:r});default:return r}},Y4=({utils:t,date:e,shouldRespectLeadingZeros:n,localeText:r,localizedDigits:o,now:i,token:s,startSeparator:a})=>{if(s==="")throw new Error("MUI X: Should not call `commitToken` with an empty token");const l=Ag(t,s),u=zw(t,l.contentType,l.type,s),f=n?u:l.contentType==="digit",p=e!=null&&t.isValid(e);let g=p?t.formatByString(e,s):"",m=null;if(f)if(u)m=g===""?t.formatByString(i,s).length:g.length;else{if(l.maxLength==null)throw new Error(`MUI X: The token ${s} should have a 'maxDigitNumber' property on it's adapter`);m=l.maxLength,p&&(g=Ig(Fw(gs(g,o),m),o))}return ne({},l,{format:s,maxLength:m,value:g,placeholder:K4(t,r,l,s),hasLeadingZerosInFormat:u,hasLeadingZerosInInput:f,startSeparator:a,endSeparator:"",modified:!1})},G4=t=>{var m;const{utils:e,expandedFormat:n,escapedParts:r}=t,o=e.date(void 0),i=[];let s="";const a=Object.keys(e.formatTokenMap).sort((y,b)=>b.length-y.length),l=/^([a-zA-Z]+)/,u=new RegExp(`^(${a.join("|")})*$`),f=new RegExp(`^(${a.join("|")})`),p=y=>r.find(b=>b.start<=y&&b.end>=y);let g=0;for(;g<n.length;){const y=p(g),b=y!=null,S=(m=l.exec(n.slice(g)))==null?void 0:m[1];if(!b&&S!=null&&u.test(S)){let C=S;for(;C.length>0;){const T=f.exec(C)[1];C=C.slice(T.length),i.push(Y4(ne({},t,{now:o,token:T,startSeparator:s}))),s=""}g+=S.length}else{const C=n[g];b&&(y==null?void 0:y.start)===g||(y==null?void 0:y.end)===g||(i.length===0?s+=C:i[i.length-1].endSeparator+=C),g+=1}}return i.length===0&&s.length>0&&i.push({type:"empty",contentType:"letter",maxLength:null,format:"",value:"",placeholder:"",hasLeadingZerosInFormat:!1,hasLeadingZerosInInput:!1,startSeparator:s,endSeparator:"",modified:!1}),i},J4=({isRtl:t,formatDensity:e,sections:n})=>n.map(r=>{const o=i=>{let s=i;return t&&s!==null&&s.includes(" ")&&(s=`${s}`),e==="spacious"&&["/",".","-"].includes(s)&&(s=` ${s} `),s};return r.startSeparator=o(r.startSeparator),r.endSeparator=o(r.endSeparator),r}),Jw=t=>{let e=q4(t);t.isRtl&&t.enableAccessibleFieldDOMStructure&&(e=e.split(" ").reverse().join(" "));const n=U4(ne({},t,{expandedFormat:e})),r=G4(ne({},t,{expandedFormat:e,escapedParts:n}));return J4(ne({},t,{sections:r}))},Ng=({timezone:t,value:e,defaultValue:n,referenceDate:r,onChange:o,valueManager:i})=>{const s=qt(),a=I.useRef(n),l=e??a.current??i.emptyValue,u=I.useMemo(()=>i.getTimezone(s,l),[s,i,l]),f=Be(y=>u==null?y:i.setTimezone(s,u,y));let p;t?p=t:u?p=u:r?p=s.getTimezone(r):p="default";const g=I.useMemo(()=>i.setTimezone(s,p,l),[i,s,p,l]),m=Be((y,...b)=>{const S=f(y);o==null||o(S,...b)});return{value:g,handleValueChange:m,timezone:p}},Lg=({name:t,timezone:e,value:n,defaultValue:r,referenceDate:o,onChange:i,valueManager:s})=>{const[a,l]=jo({name:t,state:"value",controlled:n,default:r??s.emptyValue}),u=Be((f,...p)=>{l(f),i==null||i(f,...p)});return Ng({timezone:e,value:a,defaultValue:void 0,referenceDate:o,onChange:u,valueManager:s})},Z4=t=>{const e=qt(),n=Ko(),r=ms(),o=no(),{valueManager:i,fieldValueManager:s,valueType:a,validator:l,internalProps:u,internalProps:{value:f,defaultValue:p,referenceDate:g,onChange:m,format:y,formatDensity:b="dense",selectedSections:S,onSelectedSectionsChange:C,shouldRespectLeadingZeros:T=!1,timezone:_,enableAccessibleFieldDOMStructure:w=!1}}=t,{timezone:E,value:O,handleValueChange:L}=Ng({timezone:_,value:f,defaultValue:p,referenceDate:g,onChange:m,valueManager:i}),P=I.useMemo(()=>E4(e),[e]),$=I.useMemo(()=>D4(e,P,E),[e,P,E]),M=I.useCallback((re,he=null)=>s.getSectionsFromValue(e,re,he,le=>Jw({utils:e,localeText:n,localizedDigits:P,format:y,date:le,formatDensity:b,shouldRespectLeadingZeros:T,enableAccessibleFieldDOMStructure:w,isRtl:o})),[s,y,n,P,o,T,e,b,w]),[A,N]=I.useState(()=>{const re=M(O);Hw(re,a);const he={sections:re,value:O,referenceValue:i.emptyValue,tempValueStrAndroid:null},le=w4(re),X=i.getInitialReferenceValue({referenceDate:g,value:O,utils:e,props:u,granularity:le,timezone:E});return ne({},he,{referenceValue:X})}),[z,V]=jo({controlled:S,default:null,name:"useField",state:"selectedSections"}),B=re=>{V(re),C==null||C(re)},R=I.useMemo(()=>Pg(z,A.sections),[z,A.sections]),q=R==="all"?0:R,U=({value:re,referenceValue:he,sections:le})=>{if(N(W=>ne({},W,{sections:le,value:re,referenceValue:he,tempValueStrAndroid:null})),i.areValuesEqual(e,A.value,re))return;const X={validationError:l({adapter:r,value:re,timezone:E,props:u})};L(re,X)},G=(re,he)=>{const le=[...A.sections];return le[re]=ne({},le[re],{value:he,modified:!0}),le},Y=()=>{U({value:i.emptyValue,referenceValue:A.referenceValue,sections:M(i.emptyValue)})},Z=()=>{if(q==null)return;const re=A.sections[q],he=s.getActiveDateManager(e,A,re),X=he.getSections(A.sections).filter(te=>te.value!=="").length===(re.value===""?0:1),W=G(q,""),ee=X?null:e.getInvalidDate(),ce=he.getNewValuesFromNewActiveDate(ee);U(ne({},ce,{sections:W}))},fe=re=>{const he=(W,ee)=>{const ce=e.parse(W,y);if(ce==null||!e.isValid(ce))return null;const te=Jw({utils:e,localeText:n,localizedDigits:P,format:y,date:ce,formatDensity:b,shouldRespectLeadingZeros:T,enableAccessibleFieldDOMStructure:w,isRtl:o});return Ww(e,ce,te,ee,!1)},le=s.parseValueStr(re,A.referenceValue,he),X=s.updateReferenceValue(e,le,A.referenceValue);U({value:le,referenceValue:X,sections:M(le,A.sections)})},pe=({activeSection:re,newSectionValue:he,shouldGoToNextSection:le})=>{le&&q<A.sections.length-1&&B(q+1);const X=s.getActiveDateManager(e,A,re),W=G(q,he),ee=X.getSections(W),ce=O4(e,ee,P);let te,se;if(ce!=null&&e.isValid(ce)){const ue=Ww(e,ce,ee,X.referenceDate,!0);te=X.getNewValuesFromNewActiveDate(ue),se=!0}else te=X.getNewValuesFromNewActiveDate(ce),se=(ce!=null&&!e.isValid(ce))!=(X.date!=null&&!e.isValid(X.date));return se?U(ne({},te,{sections:W})):N(ue=>ne({},ue,te,{sections:W,tempValueStrAndroid:null}))},me=re=>N(he=>ne({},he,{tempValueStrAndroid:re}));return I.useEffect(()=>{const re=M(A.value);Hw(re,a),N(he=>ne({},he,{sections:re}))},[y,e.locale,o]),I.useEffect(()=>{let re;i.areValuesEqual(e,A.value,O)?re=i.getTimezone(e,A.value)!==i.getTimezone(e,O):re=!0,re&&N(he=>ne({},he,{value:O,referenceValue:s.updateReferenceValue(e,O,he.referenceValue),sections:M(O)}))},[O]),{state:A,activeSectionIndex:q,parsedSelectedSections:R,setSelectedSections:B,clearValue:Y,clearActiveSection:Z,updateSectionValue:pe,updateValueFromValueStr:fe,setTempAndroidValueStr:me,getSectionsFromValue:M,sectionsValueBoundaries:$,localizedDigits:P,timezone:E}},X4=5e3,ba=t=>t.saveQuery!=null,Q4=({sections:t,updateSectionValue:e,sectionsValueBoundaries:n,localizedDigits:r,setTempAndroidValueStr:o,timezone:i})=>{const s=qt(),[a,l]=I.useState(null),u=Be(()=>l(null));I.useEffect(()=>{var y;a!=null&&((y=t[a.sectionIndex])==null?void 0:y.type)!==a.sectionType&&u()},[t,a,u]),I.useEffect(()=>{if(a!=null){const y=setTimeout(()=>u(),X4);return()=>{clearTimeout(y)}}return()=>{}},[a,u]);const f=({keyPressed:y,sectionIndex:b},S,C)=>{const T=y.toLowerCase(),_=t[b];if(a!=null&&(!C||C(a.value))&&a.sectionIndex===b){const E=`${a.value}${T}`,O=S(E,_);if(!ba(O))return l({sectionIndex:b,value:E,sectionType:_.type}),O}const w=S(T,_);return ba(w)&&!w.saveQuery?(u(),null):(l({sectionIndex:b,value:T,sectionType:_.type}),ba(w)?null:w)},p=y=>{const b=(T,_,w)=>{const E=_.filter(O=>O.toLowerCase().startsWith(w));return E.length===0?{saveQuery:!1}:{sectionValue:E[0],shouldGoToNextSection:E.length===1}},S=(T,_,w,E)=>{const O=L=>Pw(s,i,_.type,L);if(_.contentType==="letter")return b(_.format,O(_.format),T);if(w&&E!=null&&Ag(s,w).contentType==="letter"){const L=O(w),P=b(w,L,T);return ba(P)?{saveQuery:!1}:ne({},P,{sectionValue:E(P.sectionValue,L)})}return{saveQuery:!1}};return f(y,(T,_)=>{switch(_.type){case"month":{const w=E=>Bw(s,E,s.formats.month,_.format);return S(T,_,s.formats.month,w)}case"weekDay":{const w=(E,O)=>O.indexOf(E).toString();return S(T,_,s.formats.weekday,w)}case"meridiem":return S(T,_);default:return{saveQuery:!1}}})},g=y=>{const b=(C,T)=>{const _=gs(C,r),w=Number(_),E=n[T.type]({currentDate:null,format:T.format,contentType:T.contentType});if(w>E.maximum)return{saveQuery:!1};if(w<E.minimum)return{saveQuery:!0};const O=w*10>E.maximum||_.length===E.maximum.toString().length;return{sectionValue:$w(s,w,E,r,T),shouldGoToNextSection:O}};return f(y,(C,T)=>{if(T.contentType==="digit"||T.contentType==="digit-with-letter")return b(C,T);if(T.type==="month"){const _=zw(s,"digit","month","MM"),w=b(C,{type:T.type,format:"MM",hasLeadingZerosInFormat:_,hasLeadingZerosInInput:!0,contentType:"digit",maxLength:2});if(ba(w))return w;const E=Bw(s,w.sectionValue,"MM",T.format);return ne({},w,{sectionValue:E})}if(T.type==="weekDay"){const _=b(C,T);if(ba(_))return _;const w=vd(s,T.format)[Number(_.sectionValue)-1];return ne({},_,{sectionValue:w})}return{saveQuery:!1}},C=>Lw(C,r))};return{applyCharacterEditing:Be(y=>{const b=t[y.sectionIndex],C=Lw(y.keyPressed,r)?g(ne({},y,{keyPressed:Ig(y.keyPressed,r)})):p(y);if(C==null){o(null);return}e({activeSection:b,newSectionValue:C.sectionValue,shouldGoToNextSection:C.shouldGoToNextSection})}),resetCharacterQuery:u}};function eV(t,e){return Array.isArray(e)?e.every(n=>t.indexOf(n)!==-1):t.indexOf(e)!==-1}const tV=(t,e)=>n=>{(n.key==="Enter"||n.key===" ")&&(t(n),n.preventDefault(),n.stopPropagation())},xr=(t=document)=>{const e=t.activeElement;return e?e.shadowRoot?xr(e.shadowRoot):e:null},nV="@media (pointer: fine)",rV=t=>{const{internalProps:{disabled:e,readOnly:n=!1},forwardedProps:{sectionListRef:r,onBlur:o,onClick:i,onFocus:s,onInput:a,onPaste:l,focused:u,autoFocus:f=!1},fieldValueManager:p,applyCharacterEditing:g,resetCharacterQuery:m,setSelectedSections:y,parsedSelectedSections:b,state:S,clearActiveSection:C,clearValue:T,updateSectionValue:_,updateValueFromValueStr:w,sectionOrder:E,areAllSectionsEmpty:O,sectionsValueBoundaries:L}=t,P=I.useRef(null),$=Et(r,P),M=Ko(),A=qt(),N=vo(),[z,V]=I.useState(!1),B=I.useMemo(()=>({syncSelectionToDOM:()=>{if(!P.current)return;const se=document.getSelection();if(!se)return;if(b==null){se.rangeCount>0&&P.current.getRoot().contains(se.getRangeAt(0).startContainer)&&se.removeAllRanges(),z&&P.current.getRoot().blur();return}if(!P.current.getRoot().contains(xr(document)))return;const ue=new window.Range;let ye;b==="all"?ye=P.current.getRoot():S.sections[b].type==="empty"?ye=P.current.getSectionContainer(b):ye=P.current.getSectionContent(b),ue.selectNodeContents(ye),ye.focus(),se.removeAllRanges(),se.addRange(ue)},getActiveSectionIndexFromDOM:()=>{const se=xr(document);return!se||!P.current||!P.current.getRoot().contains(se)?null:P.current.getSectionIndexFromDOMElement(se)},focusField:(se=0)=>{if(!P.current)return;const ue=Pg(se,S.sections);V(!0),P.current.getSectionContent(ue).focus()},setSelectedSections:se=>{if(!P.current)return;const ue=Pg(se,S.sections);V((ue==="all"?0:ue)!==null),y(se)},isFieldFocused:()=>{const se=xr(document);return!!P.current&&P.current.getRoot().contains(se)}}),[b,y,S.sections,z]),R=Be(se=>{if(!P.current)return;const ue=S.sections[se];P.current.getSectionContent(se).innerHTML=ue.value||ue.placeholder,B.syncSelectionToDOM()}),q=Be((se,...ue)=>{se.isDefaultPrevented()||!P.current||(V(!0),i==null||i(se,...ue),b==="all"?setTimeout(()=>{const ye=document.getSelection().getRangeAt(0).startOffset;if(ye===0){y(E.startIndex);return}let _e=0,Se=0;for(;Se<ye&&_e<S.sections.length;){const Me=S.sections[_e];_e+=1,Se+=`${Me.startSeparator}${Me.value||Me.placeholder}${Me.endSeparator}`.length}y(_e-1)}):z?P.current.getRoot().contains(se.target)||y(E.startIndex):(V(!0),y(E.startIndex)))}),U=Be(se=>{if(a==null||a(se),!P.current||b!=="all")return;const ye=se.target.textContent??"";P.current.getRoot().innerHTML=S.sections.map(_e=>`${_e.startSeparator}${_e.value||_e.placeholder}${_e.endSeparator}`).join(""),B.syncSelectionToDOM(),ye.length===0||ye.charCodeAt(0)===10?(m(),T(),y("all")):ye.length>1?w(ye):g({keyPressed:ye,sectionIndex:0})}),G=Be(se=>{if(l==null||l(se),n||b!=="all"){se.preventDefault();return}const ue=se.clipboardData.getData("text");se.preventDefault(),m(),w(ue)}),Y=Be((...se)=>{if(s==null||s(...se),z||!P.current)return;V(!0),P.current.getSectionIndexFromDOMElement(xr(document))!=null||y(E.startIndex)}),Z=Be((...se)=>{o==null||o(...se),setTimeout(()=>{if(!P.current)return;const ue=xr(document);!P.current.getRoot().contains(ue)&&(V(!1),y(null))})}),fe=Be(se=>ue=>{ue.isDefaultPrevented()||y(se)}),pe=Be(se=>{se.preventDefault()}),me=Be(se=>()=>{y(se)}),re=Be(se=>{if(se.preventDefault(),n||e||typeof b!="number")return;const ue=S.sections[b],ye=se.clipboardData.getData("text"),_e=/^[a-zA-Z]+$/.test(ye),Se=/^[0-9]+$/.test(ye),Me=/^(([a-zA-Z]+)|)([0-9]+)(([a-zA-Z]+)|)$/.test(ye);ue.contentType==="letter"&&_e||ue.contentType==="digit"&&Se||ue.contentType==="digit-with-letter"&&Me?(m(),_({activeSection:ue,newSectionValue:ye,shouldGoToNextSection:!0})):!_e&&!Se&&(m(),w(ye))}),he=Be(se=>{se.preventDefault(),se.dataTransfer.dropEffect="none"}),le=Be(se=>{if(!P.current)return;const ue=se.target,ye=ue.textContent??"",_e=P.current.getSectionIndexFromDOMElement(ue),Se=S.sections[_e];if(n||!P.current){R(_e);return}if(ye.length===0){if(Se.value===""){R(_e);return}const Me=se.nativeEvent.inputType;if(Me==="insertParagraph"||Me==="insertLineBreak"){R(_e);return}m(),C();return}g({keyPressed:ye,sectionIndex:_e}),R(_e)});Tn(()=>{if(!(!z||!P.current)){if(b==="all")P.current.getRoot().focus();else if(typeof b=="number"){const se=P.current.getSectionContent(b);se&&se.focus()}}},[b,z]);const X=I.useMemo(()=>S.sections.reduce((se,ue)=>(se[ue.type]=L[ue.type]({currentDate:null,contentType:ue.contentType,format:ue.format}),se),{}),[L,S.sections]),W=b==="all",ee=I.useMemo(()=>S.sections.map((se,ue)=>{const ye=!W&&!e&&!n;return{container:{"data-sectionindex":ue,onClick:fe(ue)},content:{tabIndex:W||ue>0?-1:0,contentEditable:!W&&!e&&!n,role:"spinbutton",id:`${N}-${se.type}`,"aria-labelledby":`${N}-${se.type}`,"aria-readonly":n,"aria-valuenow":$4(se,A),"aria-valuemin":X[se.type].minimum,"aria-valuemax":X[se.type].maximum,"aria-valuetext":se.value?F4(se,A):M.empty,"aria-label":M[se.type],"aria-disabled":e,spellCheck:ye?!1:void 0,autoCapitalize:ye?"off":void 0,autoCorrect:ye?"off":void 0,[parseInt(I.version,10)>=17?"enterKeyHint":"enterkeyhint"]:ye?"next":void 0,children:se.value||se.placeholder,onInput:le,onPaste:re,onFocus:me(ue),onDragOver:he,onMouseUp:pe,inputMode:se.contentType==="letter"?"text":"numeric"},before:{children:se.startSeparator},after:{children:se.endSeparator}}}),[S.sections,me,re,he,le,fe,pe,e,n,W,M,A,X,N]),ce=Be(se=>{w(se.target.value)}),te=I.useMemo(()=>O?"":p.getV7HiddenInputValueFromSections(S.sections),[O,S.sections,p]);return I.useEffect(()=>{if(P.current==null)throw new Error(["MUI X: The `sectionListRef` prop has not been initialized by `PickersSectionList`","You probably tried to pass a component to the `textField` slot that contains an `<input />` element instead of a `PickersSectionList`.","","If you want to keep using an `<input />` HTML element for the editing, please remove the `enableAccessibleFieldDOMStructure` prop from your picker or field component:","","<DatePicker slots={{ textField: MyCustomTextField }} />","","Learn more about the field accessible DOM structure on the MUI documentation: https://mui.com/x/react-date-pickers/fields/#fields-to-edit-a-single-element"].join(`
|
|
128
|
+
`));f&&P.current&&P.current.getSectionContent(E.startIndex).focus()},[]),{interactions:B,returnedValue:{autoFocus:f,readOnly:n,focused:u??z,sectionListRef:$,onBlur:Z,onClick:q,onFocus:Y,onInput:U,onPaste:G,enableAccessibleFieldDOMStructure:!0,elements:ee,tabIndex:b===0?-1:0,contentEditable:W,value:te,onChange:ce,areAllSectionsEmpty:O}}},va=t=>t.replace(/[\u2066\u2067\u2068\u2069]/g,""),oV=(t,e,n)=>{let r=0,o=n?1:0;const i=[];for(let s=0;s<t.length;s+=1){const a=t[s],l=Dg(a,n?"input-rtl":"input-ltr",e),u=`${a.startSeparator}${l}${a.endSeparator}`,f=va(u).length,p=u.length,g=va(l),m=o+(g===""?0:l.indexOf(g[0]))+a.startSeparator.length,y=m+g.length;i.push(ne({},a,{start:r,end:r+f,startInInput:m,endInInput:y})),r+=f,o+=p}return i},iV=t=>{const e=no(),n=I.useRef(),r=I.useRef(),{forwardedProps:{onFocus:o,onClick:i,onPaste:s,onBlur:a,inputRef:l,placeholder:u},internalProps:{readOnly:f=!1,disabled:p=!1},parsedSelectedSections:g,activeSectionIndex:m,state:y,fieldValueManager:b,valueManager:S,applyCharacterEditing:C,resetCharacterQuery:T,updateSectionValue:_,updateValueFromValueStr:w,clearActiveSection:E,clearValue:O,setTempAndroidValueStr:L,setSelectedSections:P,getSectionsFromValue:$,areAllSectionsEmpty:M,localizedDigits:A}=t,N=I.useRef(null),z=Et(l,N),V=I.useMemo(()=>oV(y.sections,A,e),[y.sections,A,e]),B=I.useMemo(()=>({syncSelectionToDOM:()=>{if(!N.current)return;if(g==null){N.current.scrollLeft&&(N.current.scrollLeft=0);return}if(N.current!==xr(document))return;const le=N.current.scrollTop;if(g==="all")N.current.select();else{const X=V[g],W=X.type==="empty"?X.startInInput-X.startSeparator.length:X.startInInput,ee=X.type==="empty"?X.endInInput+X.endSeparator.length:X.endInInput;(W!==N.current.selectionStart||ee!==N.current.selectionEnd)&&N.current===xr(document)&&N.current.setSelectionRange(W,ee),clearTimeout(r.current),r.current=setTimeout(()=>{N.current&&N.current===xr(document)&&N.current.selectionStart===N.current.selectionEnd&&(N.current.selectionStart!==W||N.current.selectionEnd!==ee)&&B.syncSelectionToDOM()})}N.current.scrollTop=le},getActiveSectionIndexFromDOM:()=>{const le=N.current.selectionStart??0,X=N.current.selectionEnd??0;if(le===0&&X===0)return null;const W=le<=V[0].startInInput?1:V.findIndex(ee=>ee.startInInput-ee.startSeparator.length>le);return W===-1?V.length-1:W-1},focusField:(le=0)=>{var X;(X=N.current)==null||X.focus(),P(le)},setSelectedSections:le=>P(le),isFieldFocused:()=>N.current===xr(document)}),[N,g,V,P]),R=()=>{const le=N.current.selectionStart??0;let X;le<=V[0].startInInput||le>=V[V.length-1].endInInput?X=1:X=V.findIndex(ee=>ee.startInInput-ee.startSeparator.length>le);const W=X===-1?V.length-1:X-1;P(W)},q=Be((...le)=>{o==null||o(...le);const X=N.current;clearTimeout(n.current),n.current=setTimeout(()=>{!X||X!==N.current||m==null&&(X.value.length&&Number(X.selectionEnd)-Number(X.selectionStart)===X.value.length?P("all"):R())})}),U=Be((le,...X)=>{le.isDefaultPrevented()||(i==null||i(le,...X),R())}),G=Be(le=>{if(s==null||s(le),le.preventDefault(),f||p)return;const X=le.clipboardData.getData("text");if(typeof g=="number"){const W=y.sections[g],ee=/^[a-zA-Z]+$/.test(X),ce=/^[0-9]+$/.test(X),te=/^(([a-zA-Z]+)|)([0-9]+)(([a-zA-Z]+)|)$/.test(X);if(W.contentType==="letter"&&ee||W.contentType==="digit"&&ce||W.contentType==="digit-with-letter"&&te){T(),_({activeSection:W,newSectionValue:X,shouldGoToNextSection:!0});return}if(ee||ce)return}T(),w(X)}),Y=Be((...le)=>{a==null||a(...le),P(null)}),Z=Be(le=>{if(f)return;const X=le.target.value;if(X===""){T(),O();return}const W=le.nativeEvent.data,ee=W&&W.length>1,ce=ee?W:X,te=va(ce);if(m==null||ee){w(ee?W:te);return}let se;if(g==="all"&&te.length===1)se=te;else{const ue=va(b.getV6InputValueFromSections(V,A,e));let ye=-1,_e=-1;for(let je=0;je<ue.length;je+=1)ye===-1&&ue[je]!==te[je]&&(ye=je),_e===-1&&ue[ue.length-je-1]!==te[te.length-je-1]&&(_e=je);const Se=V[m];if(ye<Se.start||ue.length-_e-1>Se.end)return;const Fe=te.length-ue.length+Se.end-va(Se.endSeparator||"").length;se=te.slice(Se.start+va(Se.startSeparator||"").length,Fe)}if(se.length===0){N4()&&L(ce),T(),E();return}C({keyPressed:se,sectionIndex:m})}),fe=I.useMemo(()=>u!==void 0?u:b.getV6InputValueFromSections($(S.emptyValue),A,e),[u,b,$,S.emptyValue,A,e]),pe=I.useMemo(()=>y.tempValueStrAndroid??b.getV6InputValueFromSections(y.sections,A,e),[y.sections,b,y.tempValueStrAndroid,A,e]);I.useEffect(()=>(N.current&&N.current===xr(document)&&P("all"),()=>{clearTimeout(n.current),clearTimeout(r.current)}),[]);const me=I.useMemo(()=>m==null||y.sections[m].contentType==="letter"?"text":"numeric",[m,y.sections]),he=!(N.current&&N.current===xr(document))&&M;return{interactions:B,returnedValue:{readOnly:f,onBlur:Y,onClick:U,onFocus:q,onPaste:G,inputRef:z,enableAccessibleFieldDOMStructure:!1,placeholder:fe,inputMode:me,autoComplete:"off",value:he?"":pe,onChange:Z}}},sV=t=>{const e=qt(),{internalProps:n,internalProps:{unstableFieldRef:r,minutesStep:o,enableAccessibleFieldDOMStructure:i=!1,disabled:s=!1,readOnly:a=!1},forwardedProps:{onKeyDown:l,error:u,clearable:f,onClear:p},fieldValueManager:g,valueManager:m,validator:y}=t,b=no(),S=Z4(t),{state:C,activeSectionIndex:T,parsedSelectedSections:_,setSelectedSections:w,clearValue:E,clearActiveSection:O,updateSectionValue:L,setTempAndroidValueStr:P,sectionsValueBoundaries:$,localizedDigits:M,timezone:A}=S,N=Q4({sections:C.sections,updateSectionValue:L,sectionsValueBoundaries:$,localizedDigits:M,setTempAndroidValueStr:P,timezone:A}),{resetCharacterQuery:z}=N,V=m.areValuesEqual(e,C.value,m.emptyValue),B=i?rV:iV,R=I.useMemo(()=>L4(C.sections,b&&!i),[C.sections,b,i]),{returnedValue:q,interactions:U}=B(ne({},t,S,N,{areAllSectionsEmpty:V,sectionOrder:R})),G=Be(re=>{if(l==null||l(re),!s)switch(!0){case((re.ctrlKey||re.metaKey)&&String.fromCharCode(re.keyCode)==="A"&&!re.shiftKey&&!re.altKey):{re.preventDefault(),w("all");break}case re.key==="ArrowRight":{if(re.preventDefault(),_==null)w(R.startIndex);else if(_==="all")w(R.endIndex);else{const he=R.neighbors[_].rightIndex;he!==null&&w(he)}break}case re.key==="ArrowLeft":{if(re.preventDefault(),_==null)w(R.endIndex);else if(_==="all")w(R.startIndex);else{const he=R.neighbors[_].leftIndex;he!==null&&w(he)}break}case re.key==="Delete":{if(re.preventDefault(),a)break;_==null||_==="all"?E():O(),z();break}case["ArrowUp","ArrowDown","Home","End","PageUp","PageDown"].includes(re.key):{if(re.preventDefault(),a||T==null)break;const he=C.sections[T],le=g.getActiveDateManager(e,C,he),X=M4(e,A,he,re.key,$,M,le.date,{minutesStep:o});L({activeSection:he,newSectionValue:X,shouldGoToNextSection:!1});break}}});Tn(()=>{U.syncSelectionToDOM()});const{hasValidationError:Y}=Gw({props:n,validator:y,timezone:A,value:C.value,onError:n.onError}),Z=I.useMemo(()=>u!==void 0?u:Y,[Y,u]);I.useEffect(()=>{!Z&&T==null&&z()},[C.referenceValue,T,Z]),I.useEffect(()=>{C.tempValueStrAndroid!=null&&T!=null&&(z(),O())},[C.sections]),I.useImperativeHandle(r,()=>({getSections:()=>C.sections,getActiveSectionIndex:U.getActiveSectionIndexFromDOM,setSelectedSections:U.setSelectedSections,focusField:U.focusField,isFieldFocused:U.isFieldFocused}));const fe=Be((re,...he)=>{re.preventDefault(),p==null||p(re,...he),E(),U.isFieldFocused()?w(R.startIndex):U.focusField(0)}),pe={onKeyDown:G,onClear:fe,error:Z,clearable:!!(f&&!V&&!a&&!s)},me={disabled:s,readOnly:a};return ne({},t.forwardedProps,pe,me,q)};class Sd{constructor(){wu(this,"mountEffect",()=>{this.shouldMount&&!this.didMount&&this.ref.current!==null&&(this.didMount=!0,this.mounted.resolve())});this.ref={current:null},this.mounted=null,this.didMount=!1,this.shouldMount=!1,this.setShouldMount=null}static create(){return new Sd}static use(){const e=mS(Sd.create).current,[n,r]=I.useState(!1);return e.shouldMount=n,e.setShouldMount=r,I.useEffect(e.mountEffect,[n]),e}mount(){return this.mounted||(this.mounted=lV(),this.shouldMount=!0,this.setShouldMount(this.shouldMount)),this.mounted}start(...e){this.mount().then(()=>{var n;return(n=this.ref.current)==null?void 0:n.start(...e)})}stop(...e){this.mount().then(()=>{var n;return(n=this.ref.current)==null?void 0:n.stop(...e)})}pulsate(...e){this.mount().then(()=>{var n;return(n=this.ref.current)==null?void 0:n.pulsate(...e)})}}function aV(){return Sd.use()}function lV(){let t,e;const n=new Promise((r,o)=>{t=r,e=o});return n.resolve=t,n.reject=e,n}function Zw(t){const{className:e,classes:n,pulsate:r=!1,rippleX:o,rippleY:i,rippleSize:s,in:a,onExited:l,timeout:u}=t,[f,p]=I.useState(!1),g=Le(e,n.ripple,n.rippleVisible,r&&n.ripplePulsate),m={width:s,height:s,top:-(s/2)+i,left:-(s/2)+o},y=Le(n.child,f&&n.childLeaving,r&&n.childPulsate);return!a&&!f&&p(!0),I.useEffect(()=>{if(!a&&l!=null){const b=setTimeout(l,u);return()=>{clearTimeout(b)}}},[l,a,u]),v.jsx("span",{className:g,style:m,children:v.jsx("span",{className:y})})}process.env.NODE_ENV!=="production"&&(Zw.propTypes={classes:c.object.isRequired,className:c.string,in:c.bool,onExited:c.func,pulsate:c.bool,rippleSize:c.number,rippleX:c.number,rippleY:c.number,timeout:c.number.isRequired});const Lr=qe("MuiTouchRipple",["root","ripple","rippleVisible","ripplePulsate","child","childLeaving","childPulsate"]),Fg=550,cV=80,uV=to.keyframes`
|
|
129
129
|
0% {
|
|
130
130
|
transform: scale(0);
|
|
131
131
|
opacity: 0.1;
|
|
@@ -198,7 +198,7 @@ function print() { __p += __j.call(arguments, '') }
|
|
|
198
198
|
animation-iteration-count: infinite;
|
|
199
199
|
animation-delay: 200ms;
|
|
200
200
|
}
|
|
201
|
-
`,Xw=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiTouchRipple"}),{center:o=!1,classes:i={},className:s,...a}=r,[l,u]=I.useState([]),f=I.useRef(0),p=I.useRef(null);I.useEffect(()=>{p.current&&(p.current(),p.current=null)},[l]);const g=I.useRef(!1),m=yS(),y=I.useRef(null),b=I.useRef(null),S=I.useCallback(w=>{const{pulsate:E,rippleX:O,rippleY:L,rippleSize:P,cb:$}=w;u(M=>[...M,v.jsx(hV,{classes:{ripple:Le(i.ripple,Lr.ripple),rippleVisible:Le(i.rippleVisible,Lr.rippleVisible),ripplePulsate:Le(i.ripplePulsate,Lr.ripplePulsate),child:Le(i.child,Lr.child),childLeaving:Le(i.childLeaving,Lr.childLeaving),childPulsate:Le(i.childPulsate,Lr.childPulsate)},timeout:Fg,pulsate:E,rippleX:O,rippleY:L,rippleSize:P},f.current)]),f.current+=1,p.current=$},[i]),C=I.useCallback((w={},E={},O=()=>{})=>{const{pulsate:L=!1,center:P=o||E.pulsate,fakeElement:$=!1}=E;if((w==null?void 0:w.type)==="mousedown"&&g.current){g.current=!1;return}(w==null?void 0:w.type)==="touchstart"&&(g.current=!0);const M=$?null:b.current,A=M?M.getBoundingClientRect():{width:0,height:0,left:0,top:0};let N,V
|
|
201
|
+
`,Xw=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiTouchRipple"}),{center:o=!1,classes:i={},className:s,...a}=r,[l,u]=I.useState([]),f=I.useRef(0),p=I.useRef(null);I.useEffect(()=>{p.current&&(p.current(),p.current=null)},[l]);const g=I.useRef(!1),m=yS(),y=I.useRef(null),b=I.useRef(null),S=I.useCallback(w=>{const{pulsate:E,rippleX:O,rippleY:L,rippleSize:P,cb:$}=w;u(M=>[...M,v.jsx(hV,{classes:{ripple:Le(i.ripple,Lr.ripple),rippleVisible:Le(i.rippleVisible,Lr.rippleVisible),ripplePulsate:Le(i.ripplePulsate,Lr.ripplePulsate),child:Le(i.child,Lr.child),childLeaving:Le(i.childLeaving,Lr.childLeaving),childPulsate:Le(i.childPulsate,Lr.childPulsate)},timeout:Fg,pulsate:E,rippleX:O,rippleY:L,rippleSize:P},f.current)]),f.current+=1,p.current=$},[i]),C=I.useCallback((w={},E={},O=()=>{})=>{const{pulsate:L=!1,center:P=o||E.pulsate,fakeElement:$=!1}=E;if((w==null?void 0:w.type)==="mousedown"&&g.current){g.current=!1;return}(w==null?void 0:w.type)==="touchstart"&&(g.current=!0);const M=$?null:b.current,A=M?M.getBoundingClientRect():{width:0,height:0,left:0,top:0};let N,z,V;if(P||w===void 0||w.clientX===0&&w.clientY===0||!w.clientX&&!w.touches)N=Math.round(A.width/2),z=Math.round(A.height/2);else{const{clientX:B,clientY:R}=w.touches&&w.touches.length>0?w.touches[0]:w;N=Math.round(B-A.left),z=Math.round(R-A.top)}if(P)V=Math.sqrt((2*A.width**2+A.height**2)/3),V%2===0&&(V+=1);else{const B=Math.max(Math.abs((M?M.clientWidth:0)-N),N)*2+2,R=Math.max(Math.abs((M?M.clientHeight:0)-z),z)*2+2;V=Math.sqrt(B**2+R**2)}w!=null&&w.touches?y.current===null&&(y.current=()=>{S({pulsate:L,rippleX:N,rippleY:z,rippleSize:V,cb:O})},m.start(cV,()=>{y.current&&(y.current(),y.current=null)})):S({pulsate:L,rippleX:N,rippleY:z,rippleSize:V,cb:O})},[o,S,m]),T=I.useCallback(()=>{C({},{pulsate:!0})},[C]),_=I.useCallback((w,E)=>{if(m.clear(),(w==null?void 0:w.type)==="touchend"&&y.current){y.current(),y.current=null,m.start(0,()=>{_(w,E)});return}y.current=null,u(O=>O.length>0?O.slice(1):O),p.current=E},[m]);return I.useImperativeHandle(n,()=>({pulsate:T,start:C,stop:_}),[T,C,_]),v.jsx(pV,{className:Le(Lr.root,i.root,s),ref:b,...a,children:v.jsx(jl,{component:null,exit:!0,children:l})})});process.env.NODE_ENV!=="production"&&(Xw.propTypes={center:c.bool,classes:c.object,className:c.string});function gV(t){return Ke("MuiButtonBase",t)}const mV=qe("MuiButtonBase",["root","disabled","focusVisible"]),yV=t=>{const{disabled:e,focusVisible:n,focusVisibleClassName:r,classes:o}=t,s=Ue({root:["root",e&&"disabled",n&&"focusVisible"]},gV,o);return n&&r&&(s.root+=` ${r}`),s},bV=be("button",{name:"MuiButtonBase",slot:"Root",overridesResolver:(t,e)=>e.root})({display:"inline-flex",alignItems:"center",justifyContent:"center",position:"relative",boxSizing:"border-box",WebkitTapHighlightColor:"transparent",backgroundColor:"transparent",outline:0,border:0,margin:0,borderRadius:0,padding:0,cursor:"pointer",userSelect:"none",verticalAlign:"middle",MozAppearance:"none",WebkitAppearance:"none",textDecoration:"none",color:"inherit","&::-moz-focus-inner":{borderStyle:"none"},[`&.${mV.disabled}`]:{pointerEvents:"none",cursor:"default"},"@media print":{colorAdjust:"exact"}}),xa=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiButtonBase"}),{action:o,centerRipple:i=!1,children:s,className:a,component:l="button",disabled:u=!1,disableRipple:f=!1,disableTouchRipple:p=!1,focusRipple:g=!1,focusVisibleClassName:m,LinkComponent:y="a",onBlur:b,onClick:S,onContextMenu:C,onDragLeave:T,onFocus:_,onFocusVisible:w,onKeyDown:E,onKeyUp:O,onMouseDown:L,onMouseLeave:P,onMouseUp:$,onTouchEnd:M,onTouchMove:A,onTouchStart:N,tabIndex:z=0,TouchRippleProps:V,touchRippleRef:B,type:R,...q}=r,U=I.useRef(null),G=aV(),Y=Et(G.ref,B),[Z,fe]=I.useState(!1);u&&Z&&fe(!1),I.useImperativeHandle(o,()=>({focusVisible:()=>{fe(!0),U.current.focus()}}),[]);const pe=G.shouldMount&&!f&&!u;I.useEffect(()=>{Z&&g&&!f&&G.pulsate()},[f,g,Z,G]);const me=Yo(G,"start",L,p),re=Yo(G,"stop",C,p),he=Yo(G,"stop",T,p),le=Yo(G,"stop",$,p),X=Yo(G,"stop",De=>{Z&&De.preventDefault(),P&&P(De)},p),W=Yo(G,"start",N,p),ee=Yo(G,"stop",M,p),ce=Yo(G,"stop",A,p),te=Yo(G,"stop",De=>{bS(De.target)||fe(!1),b&&b(De)},!1),se=Be(De=>{U.current||(U.current=De.currentTarget),bS(De.target)&&(fe(!0),w&&w(De)),_&&_(De)}),ue=()=>{const De=U.current;return l&&l!=="button"&&!(De.tagName==="A"&&De.href)},ye=Be(De=>{g&&!De.repeat&&Z&&De.key===" "&&G.stop(De,()=>{G.start(De)}),De.target===De.currentTarget&&ue()&&De.key===" "&&De.preventDefault(),E&&E(De),De.target===De.currentTarget&&ue()&&De.key==="Enter"&&!u&&(De.preventDefault(),S&&S(De))}),_e=Be(De=>{g&&De.key===" "&&Z&&!De.defaultPrevented&&G.stop(De,()=>{G.pulsate(De)}),O&&O(De),S&&De.target===De.currentTarget&&ue()&&De.key===" "&&!De.defaultPrevented&&S(De)});let Se=l;Se==="button"&&(q.href||q.to)&&(Se=y);const Me={};Se==="button"?(Me.type=R===void 0?"button":R,Me.disabled=u):(!q.href&&!q.to&&(Me.role="button"),u&&(Me["aria-disabled"]=u));const Fe=Et(n,U),je={...r,centerRipple:i,component:l,disabled:u,disableRipple:f,disableTouchRipple:p,focusRipple:g,tabIndex:z,focusVisible:Z},Je=yV(je);return v.jsxs(bV,{as:Se,className:Le(Je.root,a),ownerState:je,onBlur:te,onClick:S,onContextMenu:re,onFocus:se,onKeyDown:ye,onKeyUp:_e,onMouseDown:me,onMouseLeave:X,onMouseUp:le,onDragLeave:he,onTouchEnd:ee,onTouchMove:ce,onTouchStart:W,ref:Fe,tabIndex:u?-1:z,type:R,...Me,...q,children:[s,pe?v.jsx(Xw,{ref:Y,center:i,...V}):null]})});function Yo(t,e,n,r=!1){return Be(o=>(n&&n(o),r||t[e](o),!0))}process.env.NODE_ENV!=="production"&&(xa.propTypes={action:mn,centerRipple:c.bool,children:c.node,classes:c.object,className:c.string,component:Eu,disabled:c.bool,disableRipple:c.bool,disableTouchRipple:c.bool,focusRipple:c.bool,focusVisibleClassName:c.string,href:c.any,LinkComponent:c.elementType,onBlur:c.func,onClick:c.func,onContextMenu:c.func,onDragLeave:c.func,onFocus:c.func,onFocusVisible:c.func,onKeyDown:c.func,onKeyUp:c.func,onMouseDown:c.func,onMouseLeave:c.func,onMouseUp:c.func,onTouchEnd:c.func,onTouchMove:c.func,onTouchStart:c.func,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),tabIndex:c.number,TouchRippleProps:c.object,touchRippleRef:c.oneOfType([c.func,c.shape({current:c.shape({pulsate:c.func.isRequired,start:c.func.isRequired,stop:c.func.isRequired})})]),type:c.oneOfType([c.oneOf(["button","reset","submit"]),c.string])});function vV(t){return Ke("MuiCircularProgress",t)}qe("MuiCircularProgress",["root","determinate","indeterminate","colorPrimary","colorSecondary","svg","circle","circleDeterminate","circleIndeterminate","circleDisableShrink"]);const _i=44,$g=to.keyframes`
|
|
202
202
|
0% {
|
|
203
203
|
transform: rotate(0deg);
|
|
204
204
|
}
|
|
@@ -226,12 +226,12 @@ function print() { __p += __j.call(arguments, '') }
|
|
|
226
226
|
`:null,SV=typeof Bg!="string"?to.css`
|
|
227
227
|
animation: ${Bg} 1.4s ease-in-out infinite;
|
|
228
228
|
`:null,CV=t=>{const{classes:e,variant:n,color:r,disableShrink:o}=t,i={root:["root",n,`color${Ae(r)}`],svg:["svg"],circle:["circle",`circle${Ae(n)}`,o&&"circleDisableShrink"]};return Ue(i,vV,e)},wV=be("span",{name:"MuiCircularProgress",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,e[n.variant],e[`color${Ae(n.color)}`]]}})(Dt(({theme:t})=>({display:"inline-block",variants:[{props:{variant:"determinate"},style:{transition:t.transitions.create("transform")}},{props:{variant:"indeterminate"},style:xV||{animation:`${$g} 1.4s linear infinite`}},...Object.entries(t.palette).filter(Hn()).map(([e])=>({props:{color:e},style:{color:(t.vars||t).palette[e].main}}))]}))),_V=be("svg",{name:"MuiCircularProgress",slot:"Svg",overridesResolver:(t,e)=>e.svg})({display:"block"}),TV=be("circle",{name:"MuiCircularProgress",slot:"Circle",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.circle,e[`circle${Ae(n.variant)}`],n.disableShrink&&e.circleDisableShrink]}})(Dt(({theme:t})=>({stroke:"currentColor",variants:[{props:{variant:"determinate"},style:{transition:t.transitions.create("stroke-dashoffset")}},{props:{variant:"indeterminate"},style:{strokeDasharray:"80px, 200px",strokeDashoffset:0}},{props:({ownerState:e})=>e.variant==="indeterminate"&&!e.disableShrink,style:SV||{animation:`${Bg} 1.4s ease-in-out infinite`}}]}))),Rg=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiCircularProgress"}),{className:o,color:i="primary",disableShrink:s=!1,size:a=40,style:l,thickness:u=3.6,value:f=0,variant:p="indeterminate",...g}=r,m={...r,color:i,disableShrink:s,size:a,thickness:u,value:f,variant:p},y=CV(m),b={},S={},C={};if(p==="determinate"){const T=2*Math.PI*((_i-u)/2);b.strokeDasharray=T.toFixed(3),C["aria-valuenow"]=Math.round(f),b.strokeDashoffset=`${((100-f)/100*T).toFixed(3)}px`,S.transform="rotate(-90deg)"}return v.jsx(wV,{className:Le(y.root,o),style:{width:a,height:a,...S,...l},ownerState:m,ref:n,role:"progressbar",...C,...g,children:v.jsx(_V,{className:y.svg,ownerState:m,viewBox:`${_i/2} ${_i/2} ${_i} ${_i}`,children:v.jsx(TV,{className:y.circle,style:b,ownerState:m,cx:_i,cy:_i,r:(_i-u)/2,fill:"none",strokeWidth:u})})})});process.env.NODE_ENV!=="production"&&(Rg.propTypes={classes:c.object,className:c.string,color:c.oneOfType([c.oneOf(["inherit","primary","secondary","error","info","success","warning"]),c.string]),disableShrink:zo(c.bool,t=>t.disableShrink&&t.variant&&t.variant!=="indeterminate"?new Error("MUI: You have provided the `disableShrink` prop with a variant other than `indeterminate`. This will have no effect."):null),size:c.oneOfType([c.number,c.string]),style:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),thickness:c.number,value:c.number,variant:c.oneOf(["determinate","indeterminate"])});function kV(t){return Ke("MuiIconButton",t)}const Qw=qe("MuiIconButton",["root","disabled","colorInherit","colorPrimary","colorSecondary","colorError","colorInfo","colorSuccess","colorWarning","edgeStart","edgeEnd","sizeSmall","sizeMedium","sizeLarge","loading","loadingIndicator","loadingWrapper"]),EV=t=>{const{classes:e,disabled:n,color:r,edge:o,size:i,loading:s}=t,a={root:["root",s&&"loading",n&&"disabled",r!=="default"&&`color${Ae(r)}`,o&&`edge${Ae(o)}`,`size${Ae(i)}`],loadingIndicator:["loadingIndicator"],loadingWrapper:["loadingWrapper"]};return Ue(a,kV,e)},MV=be(xa,{name:"MuiIconButton",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,n.loading&&e.loading,n.color!=="default"&&e[`color${Ae(n.color)}`],n.edge&&e[`edge${Ae(n.edge)}`],e[`size${Ae(n.size)}`]]}})(Dt(({theme:t})=>({textAlign:"center",flex:"0 0 auto",fontSize:t.typography.pxToRem(24),padding:8,borderRadius:"50%",color:(t.vars||t).palette.action.active,transition:t.transitions.create("background-color",{duration:t.transitions.duration.shortest}),variants:[{props:e=>!e.disableRipple,style:{"--IconButton-hoverBg":t.vars?`rgba(${t.vars.palette.action.activeChannel} / ${t.vars.palette.action.hoverOpacity})`:Rt(t.palette.action.active,t.palette.action.hoverOpacity),"&:hover":{backgroundColor:"var(--IconButton-hoverBg)","@media (hover: none)":{backgroundColor:"transparent"}}}},{props:{edge:"start"},style:{marginLeft:-12}},{props:{edge:"start",size:"small"},style:{marginLeft:-3}},{props:{edge:"end"},style:{marginRight:-12}},{props:{edge:"end",size:"small"},style:{marginRight:-3}}]})),Dt(({theme:t})=>({variants:[{props:{color:"inherit"},style:{color:"inherit"}},...Object.entries(t.palette).filter(Hn()).map(([e])=>({props:{color:e},style:{color:(t.vars||t).palette[e].main}})),...Object.entries(t.palette).filter(Hn()).map(([e])=>({props:{color:e},style:{"--IconButton-hoverBg":t.vars?`rgba(${(t.vars||t).palette[e].mainChannel} / ${t.vars.palette.action.hoverOpacity})`:Rt((t.vars||t).palette[e].main,t.palette.action.hoverOpacity)}})),{props:{size:"small"},style:{padding:5,fontSize:t.typography.pxToRem(18)}},{props:{size:"large"},style:{padding:12,fontSize:t.typography.pxToRem(28)}}],[`&.${Qw.disabled}`]:{backgroundColor:"transparent",color:(t.vars||t).palette.action.disabled},[`&.${Qw.loading}`]:{color:"transparent"}}))),OV=be("span",{name:"MuiIconButton",slot:"LoadingIndicator",overridesResolver:(t,e)=>e.loadingIndicator})(({theme:t})=>({display:"none",position:"absolute",visibility:"visible",top:"50%",left:"50%",transform:"translate(-50%, -50%)",color:(t.vars||t).palette.action.disabled,variants:[{props:{loading:!0},style:{display:"flex"}}]})),Sa=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiIconButton"}),{edge:o=!1,children:i,className:s,color:a="default",disabled:l=!1,disableFocusRipple:u=!1,size:f="medium",id:p,loading:g=null,loadingIndicator:m,...y}=r,b=vo(p),S=m??v.jsx(Rg,{"aria-labelledby":b,color:"inherit",size:16}),C={...r,edge:o,color:a,disabled:l,disableFocusRipple:u,loading:g,loadingIndicator:S,size:f},T=EV(C);return v.jsxs(MV,{id:g?b:p,className:Le(T.root,s),centerRipple:!0,focusRipple:!u,disabled:l||g,ref:n,...y,ownerState:C,children:[typeof g=="boolean"&&v.jsx("span",{className:T.loadingWrapper,style:{display:"contents"},children:v.jsx(OV,{className:T.loadingIndicator,ownerState:C,children:g&&S})}),i]})});process.env.NODE_ENV!=="production"&&(Sa.propTypes={children:zo(c.node,t=>I.Children.toArray(t.children).some(n=>I.isValidElement(n)&&n.props.onClick)?new Error(["MUI: You are providing an onClick event listener to a child of a button element.","Prefer applying it to the IconButton directly.","This guarantees that the whole <button> will be responsive to click events."].join(`
|
|
229
|
-
`)):null),classes:c.object,className:c.string,color:c.oneOfType([c.oneOf(["inherit","default","primary","secondary","error","info","success","warning"]),c.string]),disabled:c.bool,disableFocusRipple:c.bool,disableRipple:c.bool,edge:c.oneOf(["end","start",!1]),id:c.string,loading:c.bool,loadingIndicator:c.node,size:c.oneOfType([c.oneOf(["small","medium","large"]),c.string]),sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object])});function AV(t){return Ke("MuiTypography",t)}qe("MuiTypography",["root","h1","h2","h3","h4","h5","h6","subtitle1","subtitle2","body1","body2","inherit","button","caption","overline","alignLeft","alignRight","alignCenter","alignJustify","noWrap","gutterBottom","paragraph"]);const IV={primary:!0,secondary:!0,error:!0,info:!0,success:!0,warning:!0,textPrimary:!0,textSecondary:!0,textDisabled:!0},DV=wB(),PV=t=>{const{align:e,gutterBottom:n,noWrap:r,paragraph:o,variant:i,classes:s}=t,a={root:["root",i,t.align!=="inherit"&&`align${Ae(e)}`,n&&"gutterBottom",r&&"noWrap",o&&"paragraph"]};return Ue(a,AV,s)},NV=be("span",{name:"MuiTypography",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,n.variant&&e[n.variant],n.align!=="inherit"&&e[`align${Ae(n.align)}`],n.noWrap&&e.noWrap,n.gutterBottom&&e.gutterBottom,n.paragraph&&e.paragraph]}})(Dt(({theme:t})=>{var e;return{margin:0,variants:[{props:{variant:"inherit"},style:{font:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}},...Object.entries(t.typography).filter(([n,r])=>n!=="inherit"&&r&&typeof r=="object").map(([n,r])=>({props:{variant:n},style:r})),...Object.entries(t.palette).filter(Hn()).map(([n])=>({props:{color:n},style:{color:(t.vars||t).palette[n].main}})),...Object.entries(((e=t.palette)==null?void 0:e.text)||{}).filter(([,n])=>typeof n=="string").map(([n])=>({props:{color:`text${Ae(n)}`},style:{color:(t.vars||t).palette.text[n]}})),{props:({ownerState:n})=>n.align!=="inherit",style:{textAlign:"var(--Typography-textAlign)"}},{props:({ownerState:n})=>n.noWrap,style:{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"}},{props:({ownerState:n})=>n.gutterBottom,style:{marginBottom:"0.35em"}},{props:({ownerState:n})=>n.paragraph,style:{marginBottom:16}}]}})),e_={h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",subtitle1:"h6",subtitle2:"h6",body1:"p",body2:"p",inherit:"p"},Ti=I.forwardRef(function(e,n){const{color:r,...o}=St({props:e,name:"MuiTypography"}),i=!IV[r],s=DV({...o,...i&&{color:r}}),{align:a="inherit",className:l,component:u,gutterBottom:f=!1,noWrap:p=!1,paragraph:g=!1,variant:m="body1",variantMapping:y=e_,...b}=s,S={...s,align:a,color:r,className:l,component:u,gutterBottom:f,noWrap:p,paragraph:g,variant:m,variantMapping:y},C=u||(g?"p":y[m]||e_[m])||"span",T=PV(S);return v.jsx(NV,{as:C,ref:n,className:Le(T.root,l),...b,ownerState:S,style:{...a!=="inherit"&&{"--Typography-textAlign":a},...b.style}})});process.env.NODE_ENV!=="production"&&(Ti.propTypes={align:c.oneOf(["center","inherit","justify","left","right"]),children:c.node,classes:c.object,className:c.string,color:c.oneOfType([c.oneOf(["primary","secondary","success","error","info","warning","textPrimary","textSecondary","textDisabled"]),c.string]),component:c.elementType,gutterBottom:c.bool,noWrap:c.bool,paragraph:c.bool,style:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),variant:c.oneOfType([c.oneOf(["body1","body2","button","caption","h1","h2","h3","h4","h5","h6","inherit","overline","subtitle1","subtitle2"]),c.string]),variantMapping:c.object});function LV(t){return Ke("MuiInputAdornment",t)}const t_=qe("MuiInputAdornment",["root","filled","standard","outlined","positionStart","positionEnd","disablePointerEvents","hiddenLabel","sizeSmall"]);var n_;const FV=(t,e)=>{const{ownerState:n}=t;return[e.root,e[`position${Ae(n.position)}`],n.disablePointerEvents===!0&&e.disablePointerEvents,e[n.variant]]},$V=t=>{const{classes:e,disablePointerEvents:n,hiddenLabel:r,position:o,size:i,variant:s}=t,a={root:["root",n&&"disablePointerEvents",o&&`position${Ae(o)}`,s,r&&"hiddenLabel",i&&`size${Ae(i)}`]};return Ue(a,LV,e)},BV=be("div",{name:"MuiInputAdornment",slot:"Root",overridesResolver:FV})(Dt(({theme:t})=>({display:"flex",maxHeight:"2em",alignItems:"center",whiteSpace:"nowrap",color:(t.vars||t).palette.action.active,variants:[{props:{variant:"filled"},style:{[`&.${t_.positionStart}&:not(.${t_.hiddenLabel})`]:{marginTop:16}}},{props:{position:"start"},style:{marginRight:8}},{props:{position:"end"},style:{marginLeft:8}},{props:{disablePointerEvents:!0},style:{pointerEvents:"none"}}]}))),zg=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiInputAdornment"}),{children:o,className:i,component:s="div",disablePointerEvents:a=!1,disableTypography:l=!1,position:u,variant:f,...p}=r,g=io()||{};let m=f;f&&g.variant&&process.env.NODE_ENV!=="production"&&f===g.variant&&console.error("MUI: The `InputAdornment` variant infers the variant prop you do not have to provide one."),m||(m=g.variant);const y={...r,hiddenLabel:g.hiddenLabel,size:g.size,disablePointerEvents:a,position:u,variant:m},b=$V(y);return v.jsx(Bl.Provider,{value:null,children:v.jsx(BV,{as:s,ownerState:y,className:Le(b.root,i),ref:n,...p,children:typeof o=="string"&&!l?v.jsx(Ti,{color:"textSecondary",children:o}):v.jsxs(I.Fragment,{children:[u==="start"?n_||(n_=v.jsx("span",{className:"notranslate","aria-hidden":!0,children:""})):null,o]})})})});process.env.NODE_ENV!=="production"&&(zg.propTypes={children:c.node,classes:c.object,className:c.string,component:c.elementType,disablePointerEvents:c.bool,disableTypography:c.bool,position:c.oneOf(["end","start"]).isRequired,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),variant:c.oneOf(["filled","outlined","standard"])});const RV=ze(v.jsx("path",{d:"M7 10l5 5 5-5z"}),"ArrowDropDown"),zV=ze(v.jsx("path",{d:"M15.41 16.59L10.83 12l4.58-4.59L14 6l-6 6 6 6 1.41-1.41z"}),"ArrowLeft"),VV=ze(v.jsx("path",{d:"M8.59 16.59L13.17 12 8.59 7.41 10 6l6 6-6 6-1.41-1.41z"}),"ArrowRight"),HV=ze(v.jsx("path",{d:"M17 12h-5v5h5v-5zM16 1v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2h-1V1h-2zm3 18H5V8h14v11z"}),"Calendar");ze(v.jsxs(I.Fragment,{children:[v.jsx("path",{d:"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"}),v.jsx("path",{d:"M12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z"})]}),"Clock"),ze(v.jsx("path",{d:"M9 11H7v2h2v-2zm4 0h-2v2h2v-2zm4 0h-2v2h2v-2zm2-7h-1V2h-2v2H8V2H6v2H5c-1.11 0-1.99.9-1.99 2L3 20c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 16H5V9h14v11z"}),"DateRange"),ze(v.jsxs(I.Fragment,{children:[v.jsx("path",{d:"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"}),v.jsx("path",{d:"M12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z"})]}),"Time");const jV=ze(v.jsx("path",{d:"M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}),"Clear"),WV=["clearable","onClear","InputProps","sx","slots","slotProps"],qV=["ownerState"],UV=t=>{const e=Ko(),{clearable:n,onClear:r,InputProps:o,sx:i,slots:s,slotProps:a}=t,l=rt(t,WV),u=(s==null?void 0:s.clearButton)??Sa,f=wt({elementType:u,externalSlotProps:a==null?void 0:a.clearButton,ownerState:{},className:"clearButton",additionalProps:{title:e.fieldClearLabel}}),p=rt(f,qV),g=(s==null?void 0:s.clearIcon)??jV,m=wt({elementType:g,externalSlotProps:a==null?void 0:a.clearIcon,ownerState:{}});return ne({},l,{InputProps:ne({},o,{endAdornment:v.jsxs(I.Fragment,{children:[n&&v.jsx(zg,{position:"end",sx:{marginRight:o!=null&&o.endAdornment?-1:-1.5},children:v.jsx(u,ne({},p,{onClick:r,children:v.jsx(g,ne({fontSize:"small"},m))}))}),o==null?void 0:o.endAdornment]})}),sx:[{"& .clearButton":{opacity:1},"@media (pointer: fine)":{"& .clearButton":{opacity:0},"&:hover, &:focus-within":{".clearButton":{opacity:1}}}},...Array.isArray(i)?i:[i]]})},KV=["value","defaultValue","referenceDate","format","formatDensity","onChange","timezone","onError","shouldRespectLeadingZeros","selectedSections","onSelectedSectionsChange","unstableFieldRef","enableAccessibleFieldDOMStructure","disabled","readOnly","dateSeparator"],YV=(t,e)=>I.useMemo(()=>{const n=ne({},t),r={},o=i=>{n.hasOwnProperty(i)&&(r[i]=n[i],delete n[i])};return KV.forEach(o),qw.forEach(o),{forwardedProps:n,internalProps:r}},[t,e]),GV=I.createContext(null);function r_(t){const{contextValue:e,localeText:n,children:r}=t;return v.jsx(GV.Provider,{value:e,children:v.jsx(ag,{localeText:n,children:r})})}const JV=t=>{const e=qt(),n=Ql();return ne({},t,{disablePast:t.disablePast??!1,disableFuture:t.disableFuture??!1,format:t.format??e.formats.keyboardDate,minDate:Nr(e,t.minDate,n.minDate),maxDate:Nr(e,t.maxDate,n.maxDate)})},ZV=t=>{const e=JV(t),{forwardedProps:n,internalProps:r}=YV(e,"date");return sV({forwardedProps:n,internalProps:r,valueManager:wo,fieldValueManager:R4,validator:Xl,valueType:"date"})};function XV(t){return Ke("MuiPickersTextField",t)}qe("MuiPickersTextField",["root","focused","disabled","error","required"]);function QV(t){return Ke("MuiPickersInputBase",t)}const Ca=qe("MuiPickersInputBase",["root","focused","disabled","error","notchedOutline","sectionContent","sectionBefore","sectionAfter","adornedStart","adornedEnd","input"]);function eH(t){return Ke("MuiPickersSectionList",t)}const ec=qe("MuiPickersSectionList",["root","section","sectionContent"]),tH=["slots","slotProps","elements","sectionListRef"],o_=be("div",{name:"MuiPickersSectionList",slot:"Root",overridesResolver:(t,e)=>e.root})({direction:"ltr /*! @noflip */",outline:"none"}),i_=be("span",{name:"MuiPickersSectionList",slot:"Section",overridesResolver:(t,e)=>e.section})({}),s_=be("span",{name:"MuiPickersSectionList",slot:"SectionSeparator",overridesResolver:(t,e)=>e.sectionSeparator})({whiteSpace:"pre"}),a_=be("span",{name:"MuiPickersSectionList",slot:"SectionContent",overridesResolver:(t,e)=>e.sectionContent})({outline:"none"}),nH=t=>{const{classes:e}=t;return Ue({root:["root"],section:["section"],sectionContent:["sectionContent"]},eH,e)};function l_(t){const{slots:e,slotProps:n,element:r,classes:o}=t,i=(e==null?void 0:e.section)??i_,s=wt({elementType:i,externalSlotProps:n==null?void 0:n.section,externalForwardedProps:r.container,className:o.section,ownerState:{}}),a=(e==null?void 0:e.sectionContent)??a_,l=wt({elementType:a,externalSlotProps:n==null?void 0:n.sectionContent,externalForwardedProps:r.content,additionalProps:{suppressContentEditableWarning:!0},className:o.sectionContent,ownerState:{}}),u=(e==null?void 0:e.sectionSeparator)??s_,f=wt({elementType:u,externalSlotProps:n==null?void 0:n.sectionSeparator,externalForwardedProps:r.before,ownerState:{position:"before"}}),p=wt({elementType:u,externalSlotProps:n==null?void 0:n.sectionSeparator,externalForwardedProps:r.after,ownerState:{position:"after"}});return v.jsxs(i,ne({},s,{children:[v.jsx(u,ne({},f)),v.jsx(a,ne({},l)),v.jsx(u,ne({},p))]}))}process.env.NODE_ENV!=="production"&&(l_.propTypes={classes:c.object.isRequired,element:c.shape({after:c.object.isRequired,before:c.object.isRequired,container:c.object.isRequired,content:c.object.isRequired}).isRequired,slotProps:c.object,slots:c.object});const c_=I.forwardRef(function(e,n){const r=Wt({props:e,name:"MuiPickersSectionList"}),{slots:o,slotProps:i,elements:s,sectionListRef:a}=r,l=rt(r,tH),u=nH(r),f=I.useRef(null),p=Et(n,f),g=b=>{if(!f.current)throw new Error(`MUI X: Cannot call sectionListRef.${b} before the mount of the component.`);return f.current};I.useImperativeHandle(a,()=>({getRoot(){return g("getRoot")},getSectionContainer(b){return g("getSectionContainer").querySelector(`.${ec.section}[data-sectionindex="${b}"]`)},getSectionContent(b){return g("getSectionContent").querySelector(`.${ec.section}[data-sectionindex="${b}"] .${ec.sectionContent}`)},getSectionIndexFromDOMElement(b){const S=g("getSectionIndexFromDOMElement");if(b==null||!S.contains(b))return null;let C=null;return b.classList.contains(ec.section)?C=b:b.classList.contains(ec.sectionContent)&&(C=b.parentElement),C==null?null:Number(C.dataset.sectionindex)}}));const m=(o==null?void 0:o.root)??o_,y=wt({elementType:m,externalSlotProps:i==null?void 0:i.root,externalForwardedProps:l,additionalProps:{ref:p,suppressContentEditableWarning:!0},className:u.root,ownerState:{}});return v.jsx(m,ne({},y,{children:y.contentEditable?s.map(({content:b,before:S,after:C})=>`${S.children}${b.children}${C.children}`).join(""):v.jsx(I.Fragment,{children:s.map((b,S)=>v.jsx(l_,{slots:o,slotProps:i,element:b,classes:u},S))})}))});process.env.NODE_ENV!=="production"&&(c_.propTypes={classes:c.object,contentEditable:c.bool.isRequired,elements:c.arrayOf(c.shape({after:c.object.isRequired,before:c.object.isRequired,container:c.object.isRequired,content:c.object.isRequired})).isRequired,sectionListRef:c.oneOfType([c.func,c.shape({current:c.shape({getRoot:c.func.isRequired,getSectionContainer:c.func.isRequired,getSectionContent:c.func.isRequired,getSectionIndexFromDOMElement:c.func.isRequired})})]),slotProps:c.object,slots:c.object});const rH=["elements","areAllSectionsEmpty","defaultValue","label","value","onChange","id","autoFocus","endAdornment","startAdornment","renderSuffix","slots","slotProps","contentEditable","tabIndex","onInput","onPaste","onKeyDown","fullWidth","name","readOnly","inputProps","inputRef","sectionListRef"],oH=t=>Math.round(t*1e5)/1e5,Cd=be("div",{name:"MuiPickersInputBase",slot:"Root",overridesResolver:(t,e)=>e.root})(({theme:t})=>ne({},t.typography.body1,{color:(t.vars||t).palette.text.primary,cursor:"text",padding:0,display:"flex",justifyContent:"flex-start",alignItems:"center",position:"relative",boxSizing:"border-box",letterSpacing:`${oH(.15/16)}em`,variants:[{props:{fullWidth:!0},style:{width:"100%"}}]})),Vg=be(o_,{name:"MuiPickersInputBase",slot:"SectionsContainer",overridesResolver:(t,e)=>e.sectionsContainer})(({theme:t})=>({padding:"4px 0 5px",fontFamily:t.typography.fontFamily,fontSize:"inherit",lineHeight:"1.4375em",flexGrow:1,outline:"none",display:"flex",flexWrap:"nowrap",overflow:"hidden",letterSpacing:"inherit",width:"182px",variants:[{props:{isRtl:!0},style:{textAlign:"right /*! @noflip */"}},{props:{size:"small"},style:{paddingTop:1}},{props:{adornedStart:!1,focused:!1,filled:!1},style:{color:"currentColor",opacity:0}},{props:({adornedStart:e,focused:n,filled:r,label:o})=>!e&&!n&&!r&&o==null,style:t.vars?{opacity:t.vars.opacity.inputPlaceholder}:{opacity:t.palette.mode==="light"?.42:.5}}]})),iH=be(i_,{name:"MuiPickersInputBase",slot:"Section",overridesResolver:(t,e)=>e.section})(({theme:t})=>({fontFamily:t.typography.fontFamily,fontSize:"inherit",letterSpacing:"inherit",lineHeight:"1.4375em",display:"flex"})),sH=be(a_,{name:"MuiPickersInputBase",slot:"SectionContent",overridesResolver:(t,e)=>e.content})(({theme:t})=>({fontFamily:t.typography.fontFamily,lineHeight:"1.4375em",letterSpacing:"inherit",width:"fit-content",outline:"none"})),aH=be(s_,{name:"MuiPickersInputBase",slot:"Separator",overridesResolver:(t,e)=>e.separator})(()=>({whiteSpace:"pre",letterSpacing:"inherit"})),lH=be("input",{name:"MuiPickersInputBase",slot:"Input",overridesResolver:(t,e)=>e.hiddenInput})(ne({},r$)),cH=t=>{const{focused:e,disabled:n,error:r,classes:o,fullWidth:i,readOnly:s,color:a,size:l,endAdornment:u,startAdornment:f}=t,p={root:["root",e&&!n&&"focused",n&&"disabled",s&&"readOnly",r&&"error",i&&"fullWidth",`color${Ae(a)}`,l==="small"&&"inputSizeSmall",!!f&&"adornedStart",!!u&&"adornedEnd"],notchedOutline:["notchedOutline"],input:["input"],sectionsContainer:["sectionsContainer"],sectionContent:["sectionContent"],sectionBefore:["sectionBefore"],sectionAfter:["sectionAfter"]};return Ue(p,QV,o)},wd=I.forwardRef(function(e,n){const r=Wt({props:e,name:"MuiPickersInputBase"}),{elements:o,areAllSectionsEmpty:i,value:s,onChange:a,id:l,endAdornment:u,startAdornment:f,renderSuffix:p,slots:g,slotProps:m,contentEditable:y,tabIndex:b,onInput:S,onPaste:C,onKeyDown:T,name:_,readOnly:w,inputProps:E,inputRef:O,sectionListRef:L}=r,P=rt(r,rH),$=I.useRef(null),M=Et(n,$),A=Et(E==null?void 0:E.ref,O),N=no(),V=io();if(!V)throw new Error("MUI X: PickersInputBase should always be used inside a PickersTextField component");const R=Y=>{var Z;if(V.disabled){Y.stopPropagation();return}(Z=V.onFocus)==null||Z.call(V,Y)};I.useEffect(()=>{V&&V.setAdornedStart(!!f)},[V,f]),I.useEffect(()=>{V&&(i?V.onEmpty():V.onFilled())},[V,i]);const B=ne({},r,V,{isRtl:N}),z=cH(B),q=(g==null?void 0:g.root)||Cd,K=wt({elementType:q,externalSlotProps:m==null?void 0:m.root,externalForwardedProps:P,additionalProps:{"aria-invalid":V.error,ref:M},className:z.root,ownerState:B}),G=(g==null?void 0:g.input)||Vg;return v.jsxs(q,ne({},K,{children:[f,v.jsx(c_,{sectionListRef:L,elements:o,contentEditable:y,tabIndex:b,className:z.sectionsContainer,onFocus:R,onBlur:V.onBlur,onInput:S,onPaste:C,onKeyDown:T,slots:{root:G,section:iH,sectionContent:sH,sectionSeparator:aH},slotProps:{root:{ownerState:B},sectionContent:{className:Ca.sectionContent},sectionSeparator:({position:Y})=>({className:Y==="before"?Ca.sectionBefore:Ca.sectionAfter})}}),u,p?p(ne({},V)):null,v.jsx(lH,ne({name:_,className:z.input,value:s,onChange:a,id:l,"aria-hidden":"true",tabIndex:-1,readOnly:w,required:V.required,disabled:V.disabled},E,{ref:A}))]}))});process.env.NODE_ENV!=="production"&&(wd.propTypes={areAllSectionsEmpty:c.bool.isRequired,className:c.string,component:c.elementType,contentEditable:c.bool.isRequired,elements:c.arrayOf(c.shape({after:c.object.isRequired,before:c.object.isRequired,container:c.object.isRequired,content:c.object.isRequired})).isRequired,endAdornment:c.node,fullWidth:c.bool,id:c.string,inputProps:c.object,inputRef:mn,label:c.node,margin:c.oneOf(["dense","none","normal"]),name:c.string,onChange:c.func.isRequired,onClick:c.func.isRequired,onInput:c.func.isRequired,onKeyDown:c.func.isRequired,onPaste:c.func.isRequired,ownerState:c.any,readOnly:c.bool,renderSuffix:c.func,sectionListRef:c.oneOfType([c.func,c.shape({current:c.shape({getRoot:c.func.isRequired,getSectionContainer:c.func.isRequired,getSectionContent:c.func.isRequired,getSectionIndexFromDOMElement:c.func.isRequired})})]),slotProps:c.object,slots:c.object,startAdornment:c.node,style:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),value:c.string.isRequired});function uH(t){return Ke("MuiPickersOutlinedInput",t)}const so=ne({},Ca,qe("MuiPickersOutlinedInput",["root","notchedOutline","input"])),dH=["children","className","label","notched","shrink"],fH=be("fieldset",{name:"MuiPickersOutlinedInput",slot:"NotchedOutline",overridesResolver:(t,e)=>e.notchedOutline})(({theme:t})=>{const e=t.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return{textAlign:"left",position:"absolute",bottom:0,right:0,top:-5,left:0,margin:0,padding:"0 8px",pointerEvents:"none",borderRadius:"inherit",borderStyle:"solid",borderWidth:1,overflow:"hidden",minWidth:"0%",borderColor:t.vars?`rgba(${t.vars.palette.common.onBackgroundChannel} / 0.23)`:e}}),u_=be("span")(({theme:t})=>({fontFamily:t.typography.fontFamily,fontSize:"inherit"})),pH=be("legend")(({theme:t})=>({float:"unset",width:"auto",overflow:"hidden",variants:[{props:{withLabel:!1},style:{padding:0,lineHeight:"11px",transition:t.transitions.create("width",{duration:150,easing:t.transitions.easing.easeOut})}},{props:{withLabel:!0},style:{display:"block",padding:0,height:11,fontSize:"0.75em",visibility:"hidden",maxWidth:.01,transition:t.transitions.create("max-width",{duration:50,easing:t.transitions.easing.easeOut}),whiteSpace:"nowrap","& > span":{paddingLeft:5,paddingRight:5,display:"inline-block",opacity:0,visibility:"visible"}}},{props:{withLabel:!0,notched:!0},style:{maxWidth:"100%",transition:t.transitions.create("max-width",{duration:100,easing:t.transitions.easing.easeOut,delay:50})}}]}));function hH(t){const{className:e,label:n}=t,r=rt(t,dH),o=n!=null&&n!=="",i=ne({},t,{withLabel:o});return v.jsx(fH,ne({"aria-hidden":!0,className:e},r,{ownerState:i,children:v.jsx(pH,{ownerState:i,children:o?v.jsx(u_,{children:n}):v.jsx(u_,{className:"notranslate",children:""})})}))}const gH=["label","autoFocus","ownerState","notched"],mH=be(Cd,{name:"MuiPickersOutlinedInput",slot:"Root",overridesResolver:(t,e)=>e.root})(({theme:t})=>{const e=t.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return{padding:"0 14px",borderRadius:(t.vars||t).shape.borderRadius,[`&:hover .${so.notchedOutline}`]:{borderColor:(t.vars||t).palette.text.primary},"@media (hover: none)":{[`&:hover .${so.notchedOutline}`]:{borderColor:t.vars?`rgba(${t.vars.palette.common.onBackgroundChannel} / 0.23)`:e}},[`&.${so.focused} .${so.notchedOutline}`]:{borderStyle:"solid",borderWidth:2},[`&.${so.disabled}`]:{[`& .${so.notchedOutline}`]:{borderColor:(t.vars||t).palette.action.disabled},"*":{color:(t.vars||t).palette.action.disabled}},[`&.${so.error} .${so.notchedOutline}`]:{borderColor:(t.vars||t).palette.error.main},variants:Object.keys((t.vars??t).palette).filter(n=>{var r;return((r=(t.vars??t).palette[n])==null?void 0:r.main)??!1}).map(n=>({props:{color:n},style:{[`&.${so.focused}:not(.${so.error}) .${so.notchedOutline}`]:{borderColor:(t.vars||t).palette[n].main}}}))}}),yH=be(Vg,{name:"MuiPickersOutlinedInput",slot:"SectionsContainer",overridesResolver:(t,e)=>e.sectionsContainer})({padding:"16.5px 0",variants:[{props:{size:"small"},style:{padding:"8.5px 0"}}]}),bH=t=>{const{classes:e}=t,r=Ue({root:["root"],notchedOutline:["notchedOutline"],input:["input"]},uH,e);return ne({},e,r)},Hg=I.forwardRef(function(e,n){const r=Wt({props:e,name:"MuiPickersOutlinedInput"}),{label:o,ownerState:i,notched:s}=r,a=rt(r,gH),l=io(),u=ne({},r,i,l,{color:(l==null?void 0:l.color)||"primary"}),f=bH(u);return v.jsx(wd,ne({slots:{root:mH,input:yH},renderSuffix:p=>v.jsx(hH,{shrink:!!(s||p.adornedStart||p.focused||p.filled),notched:!!(s||p.adornedStart||p.focused||p.filled),className:f.notchedOutline,label:o!=null&&o!==""&&(l!=null&&l.required)?v.jsxs(I.Fragment,{children:[o," ","*"]}):o,ownerState:u})},a,{label:o,classes:f,ref:n}))});process.env.NODE_ENV!=="production"&&(Hg.propTypes={areAllSectionsEmpty:c.bool.isRequired,className:c.string,component:c.elementType,contentEditable:c.bool.isRequired,elements:c.arrayOf(c.shape({after:c.object.isRequired,before:c.object.isRequired,container:c.object.isRequired,content:c.object.isRequired})).isRequired,endAdornment:c.node,fullWidth:c.bool,id:c.string,inputProps:c.object,inputRef:mn,label:c.node,margin:c.oneOf(["dense","none","normal"]),name:c.string,notched:c.bool,onChange:c.func.isRequired,onClick:c.func.isRequired,onInput:c.func.isRequired,onKeyDown:c.func.isRequired,onPaste:c.func.isRequired,ownerState:c.any,readOnly:c.bool,renderSuffix:c.func,sectionListRef:c.oneOfType([c.func,c.shape({current:c.shape({getRoot:c.func.isRequired,getSectionContainer:c.func.isRequired,getSectionContent:c.func.isRequired,getSectionIndexFromDOMElement:c.func.isRequired})})]),slotProps:c.object,slots:c.object,startAdornment:c.node,style:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),value:c.string.isRequired}),Hg.muiName="Input";function vH(t){return Ke("MuiPickersFilledInput",t)}const ys=ne({},Ca,qe("MuiPickersFilledInput",["root","underline","input"])),xH=["label","autoFocus","disableUnderline","ownerState"],SH=be(Cd,{name:"MuiPickersFilledInput",slot:"Root",overridesResolver:(t,e)=>e.root,shouldForwardProp:t=>zu(t)&&t!=="disableUnderline"})(({theme:t})=>{const e=t.palette.mode==="light",n=e?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)",r=e?"rgba(0, 0, 0, 0.06)":"rgba(255, 255, 255, 0.09)",o=e?"rgba(0, 0, 0, 0.09)":"rgba(255, 255, 255, 0.13)",i=e?"rgba(0, 0, 0, 0.12)":"rgba(255, 255, 255, 0.12)";return{backgroundColor:t.vars?t.vars.palette.FilledInput.bg:r,borderTopLeftRadius:(t.vars||t).shape.borderRadius,borderTopRightRadius:(t.vars||t).shape.borderRadius,transition:t.transitions.create("background-color",{duration:t.transitions.duration.shorter,easing:t.transitions.easing.easeOut}),"&:hover":{backgroundColor:t.vars?t.vars.palette.FilledInput.hoverBg:o,"@media (hover: none)":{backgroundColor:t.vars?t.vars.palette.FilledInput.bg:r}},[`&.${ys.focused}`]:{backgroundColor:t.vars?t.vars.palette.FilledInput.bg:r},[`&.${ys.disabled}`]:{backgroundColor:t.vars?t.vars.palette.FilledInput.disabledBg:i},variants:[...Object.keys((t.vars??t).palette).filter(s=>(t.vars??t).palette[s].main).map(s=>{var a;return{props:{color:s,disableUnderline:!1},style:{"&::after":{borderBottom:`2px solid ${(a=(t.vars||t).palette[s])==null?void 0:a.main}`}}}}),{props:{disableUnderline:!1},style:{"&::after":{left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:t.transitions.create("transform",{duration:t.transitions.duration.shorter,easing:t.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${ys.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${ys.error}`]:{"&:before, &:after":{borderBottomColor:(t.vars||t).palette.error.main}},"&::before":{borderBottom:`1px solid ${t.vars?`rgba(${t.vars.palette.common.onBackgroundChannel} / ${t.vars.opacity.inputUnderline})`:n}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:t.transitions.create("border-bottom-color",{duration:t.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${ys.disabled}, .${ys.error}):before`]:{borderBottom:`1px solid ${(t.vars||t).palette.text.primary}`},[`&.${ys.disabled}:before`]:{borderBottomStyle:"dotted"}}},{props:({startAdornment:s})=>!!s,style:{paddingLeft:12}},{props:({endAdornment:s})=>!!s,style:{paddingRight:12}}]}}),CH=be(Vg,{name:"MuiPickersFilledInput",slot:"sectionsContainer",overridesResolver:(t,e)=>e.sectionsContainer})({paddingTop:25,paddingRight:12,paddingBottom:8,paddingLeft:12,variants:[{props:{size:"small"},style:{paddingTop:21,paddingBottom:4}},{props:({startAdornment:t})=>!!t,style:{paddingLeft:0}},{props:({endAdornment:t})=>!!t,style:{paddingRight:0}},{props:{hiddenLabel:!0},style:{paddingTop:16,paddingBottom:17}},{props:{hiddenLabel:!0,size:"small"},style:{paddingTop:8,paddingBottom:9}}]}),wH=t=>{const{classes:e,disableUnderline:n}=t,o=Ue({root:["root",!n&&"underline"],input:["input"]},vH,e);return ne({},e,o)},jg=I.forwardRef(function(e,n){const r=Wt({props:e,name:"MuiPickersFilledInput"}),{label:o,disableUnderline:i=!1,ownerState:s}=r,a=rt(r,xH),l=io(),u=ne({},r,s,l,{color:(l==null?void 0:l.color)||"primary"}),f=wH(u);return v.jsx(wd,ne({slots:{root:SH,input:CH},slotProps:{root:{disableUnderline:i}}},a,{label:o,classes:f,ref:n}))});process.env.NODE_ENV!=="production"&&(jg.propTypes={areAllSectionsEmpty:c.bool.isRequired,className:c.string,component:c.elementType,contentEditable:c.bool.isRequired,disableUnderline:c.bool,elements:c.arrayOf(c.shape({after:c.object.isRequired,before:c.object.isRequired,container:c.object.isRequired,content:c.object.isRequired})).isRequired,endAdornment:c.node,fullWidth:c.bool,hiddenLabel:c.bool,id:c.string,inputProps:c.object,inputRef:mn,label:c.node,margin:c.oneOf(["dense","none","normal"]),name:c.string,onChange:c.func.isRequired,onClick:c.func.isRequired,onInput:c.func.isRequired,onKeyDown:c.func.isRequired,onPaste:c.func.isRequired,ownerState:c.any,readOnly:c.bool,renderSuffix:c.func,sectionListRef:c.oneOfType([c.func,c.shape({current:c.shape({getRoot:c.func.isRequired,getSectionContainer:c.func.isRequired,getSectionContent:c.func.isRequired,getSectionIndexFromDOMElement:c.func.isRequired})})]),slotProps:c.object,slots:c.object,startAdornment:c.node,style:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),value:c.string.isRequired}),jg.muiName="Input";function _H(t){return Ke("MuiPickersFilledInput",t)}const tc=ne({},Ca,qe("MuiPickersInput",["root","input"])),TH=["label","autoFocus","disableUnderline","ownerState"],kH=be(Cd,{name:"MuiPickersInput",slot:"Root",overridesResolver:(t,e)=>e.root})(({theme:t})=>{let n=t.palette.mode==="light"?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)";return t.vars&&(n=`rgba(${t.vars.palette.common.onBackgroundChannel} / ${t.vars.opacity.inputUnderline})`),{"label + &":{marginTop:16},variants:[...Object.keys((t.vars??t).palette).filter(r=>(t.vars??t).palette[r].main).map(r=>({props:{color:r},style:{"&::after":{borderBottom:`2px solid ${(t.vars||t).palette[r].main}`}}})),{props:{disableUnderline:!1},style:{"&::after":{background:"red",left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:t.transitions.create("transform",{duration:t.transitions.duration.shorter,easing:t.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${tc.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${tc.error}`]:{"&:before, &:after":{borderBottomColor:(t.vars||t).palette.error.main}},"&::before":{borderBottom:`1px solid ${n}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:t.transitions.create("border-bottom-color",{duration:t.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${tc.disabled}, .${tc.error}):before`]:{borderBottom:`2px solid ${(t.vars||t).palette.text.primary}`,"@media (hover: none)":{borderBottom:`1px solid ${n}`}},[`&.${tc.disabled}:before`]:{borderBottomStyle:"dotted"}}}]}}),EH=t=>{const{classes:e,disableUnderline:n}=t,o=Ue({root:["root",!n&&"underline"],input:["input"]},_H,e);return ne({},e,o)},Wg=I.forwardRef(function(e,n){const r=Wt({props:e,name:"MuiPickersInput"}),{label:o,disableUnderline:i=!1,ownerState:s}=r,a=rt(r,TH),l=io(),u=ne({},r,s,l,{disableUnderline:i,color:(l==null?void 0:l.color)||"primary"}),f=EH(u);return v.jsx(wd,ne({slots:{root:kH}},a,{label:o,classes:f,ref:n}))});process.env.NODE_ENV!=="production"&&(Wg.propTypes={areAllSectionsEmpty:c.bool.isRequired,className:c.string,component:c.elementType,contentEditable:c.bool.isRequired,disableUnderline:c.bool,elements:c.arrayOf(c.shape({after:c.object.isRequired,before:c.object.isRequired,container:c.object.isRequired,content:c.object.isRequired})).isRequired,endAdornment:c.node,fullWidth:c.bool,id:c.string,inputProps:c.object,inputRef:mn,label:c.node,margin:c.oneOf(["dense","none","normal"]),name:c.string,onChange:c.func.isRequired,onClick:c.func.isRequired,onInput:c.func.isRequired,onKeyDown:c.func.isRequired,onPaste:c.func.isRequired,ownerState:c.any,readOnly:c.bool,renderSuffix:c.func,sectionListRef:c.oneOfType([c.func,c.shape({current:c.shape({getRoot:c.func.isRequired,getSectionContainer:c.func.isRequired,getSectionContent:c.func.isRequired,getSectionIndexFromDOMElement:c.func.isRequired})})]),slotProps:c.object,slots:c.object,startAdornment:c.node,style:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),value:c.string.isRequired}),Wg.muiName="Input";const MH=["onFocus","onBlur","className","color","disabled","error","variant","required","InputProps","inputProps","inputRef","sectionListRef","elements","areAllSectionsEmpty","onClick","onKeyDown","onKeyUp","onPaste","onInput","endAdornment","startAdornment","tabIndex","contentEditable","focused","value","onChange","fullWidth","id","name","helperText","FormHelperTextProps","label","InputLabelProps"],OH={standard:Wg,filled:jg,outlined:Hg},AH=be(ug,{name:"MuiPickersTextField",slot:"Root",overridesResolver:(t,e)=>e.root})({}),IH=t=>{const{focused:e,disabled:n,classes:r,required:o}=t;return Ue({root:["root",e&&!n&&"focused",n&&"disabled",o&&"required"]},XV,r)},d_=I.forwardRef(function(e,n){const r=Wt({props:e,name:"MuiPickersTextField"}),{onFocus:o,onBlur:i,className:s,color:a="primary",disabled:l=!1,error:u=!1,variant:f="outlined",required:p=!1,InputProps:g,inputProps:m,inputRef:y,sectionListRef:b,elements:S,areAllSectionsEmpty:C,onClick:T,onKeyDown:_,onKeyUp:w,onPaste:E,onInput:O,endAdornment:L,startAdornment:P,tabIndex:$,contentEditable:M,focused:A,value:N,onChange:V,fullWidth:R,id:B,name:z,helperText:q,FormHelperTextProps:K,label:G,InputLabelProps:Y}=r,Z=rt(r,MH),me=I.useRef(null),he=Et(n,me),oe=vo(B),Q=q&&oe?`${oe}-helper-text`:void 0,fe=G&&oe?`${oe}-label`:void 0,ce=ne({},r,{color:a,disabled:l,error:u,focused:A,required:p,variant:f}),ae=IH(ce),W=OH[f];return v.jsxs(AH,ne({className:Le(ae.root,s),ref:he,focused:A,onFocus:o,onBlur:i,disabled:l,variant:f,error:u,color:a,fullWidth:R,required:p,ownerState:ce},Z,{children:[v.jsx(cg,ne({htmlFor:oe,id:fe},Y,{children:G})),v.jsx(W,ne({elements:S,areAllSectionsEmpty:C,onClick:T,onKeyDown:_,onKeyUp:w,onInput:O,onPaste:E,endAdornment:L,startAdornment:P,tabIndex:$,contentEditable:M,value:N,onChange:V,id:oe,fullWidth:R,inputProps:m,inputRef:y,sectionListRef:b,label:G,name:z,role:"group","aria-labelledby":fe},g)),q&&v.jsx(dg,ne({id:Q},K,{children:q}))]}))});process.env.NODE_ENV!=="production"&&(d_.propTypes={areAllSectionsEmpty:c.bool.isRequired,className:c.string,color:c.oneOf(["error","info","primary","secondary","success","warning"]),component:c.elementType,contentEditable:c.bool.isRequired,disabled:c.bool.isRequired,elements:c.arrayOf(c.shape({after:c.object.isRequired,before:c.object.isRequired,container:c.object.isRequired,content:c.object.isRequired})).isRequired,endAdornment:c.node,error:c.bool.isRequired,focused:c.bool,FormHelperTextProps:c.object,fullWidth:c.bool,helperText:c.node,hiddenLabel:c.bool,id:c.string,InputLabelProps:c.object,inputProps:c.object,InputProps:c.object,inputRef:mn,label:c.node,margin:c.oneOf(["dense","none","normal"]),name:c.string,onBlur:c.func.isRequired,onChange:c.func.isRequired,onClick:c.func.isRequired,onFocus:c.func.isRequired,onInput:c.func.isRequired,onKeyDown:c.func.isRequired,onPaste:c.func.isRequired,readOnly:c.bool,required:c.bool,sectionListRef:c.oneOfType([c.func,c.shape({current:c.shape({getRoot:c.func.isRequired,getSectionContainer:c.func.isRequired,getSectionContent:c.func.isRequired,getSectionIndexFromDOMElement:c.func.isRequired})})]),size:c.oneOf(["medium","small"]),startAdornment:c.node,style:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),value:c.string.isRequired,variant:c.oneOf(["filled","outlined","standard"])});const DH=["enableAccessibleFieldDOMStructure"],PH=["InputProps","readOnly"],NH=["onPaste","onKeyDown","inputMode","readOnly","InputProps","inputProps","inputRef"],LH=t=>{let{enableAccessibleFieldDOMStructure:e}=t,n=rt(t,DH);if(e){const{InputProps:p,readOnly:g}=n,m=rt(n,PH);return ne({},m,{InputProps:ne({},p??{},{readOnly:g})})}const{onPaste:r,onKeyDown:o,inputMode:i,readOnly:s,InputProps:a,inputProps:l,inputRef:u}=n,f=rt(n,NH);return ne({},f,{InputProps:ne({},a??{},{readOnly:s}),inputProps:ne({},l??{},{inputMode:i,onPaste:r,onKeyDown:o,ref:u})})},FH=["slots","slotProps","InputProps","inputProps"],_d=I.forwardRef(function(e,n){const r=Wt({props:e,name:"MuiDateField"}),{slots:o,slotProps:i,InputProps:s,inputProps:a}=r,l=rt(r,FH),u=r,f=(o==null?void 0:o.textField)??(e.enableAccessibleFieldDOMStructure?d_:Ow),p=wt({elementType:f,externalSlotProps:i==null?void 0:i.textField,externalForwardedProps:l,additionalProps:{ref:n},ownerState:u});p.inputProps=ne({},a,p.inputProps),p.InputProps=ne({},s,p.InputProps);const g=ZV(p),m=LH(g),y=UV(ne({},m,{slots:o,slotProps:i}));return v.jsx(f,ne({},y))});process.env.NODE_ENV!=="production"&&(_d.propTypes={autoFocus:c.bool,className:c.string,clearable:c.bool,color:c.oneOf(["error","info","primary","secondary","success","warning"]),component:c.elementType,defaultValue:c.object,disabled:c.bool,disableFuture:c.bool,disablePast:c.bool,enableAccessibleFieldDOMStructure:c.bool,focused:c.bool,format:c.string,formatDensity:c.oneOf(["dense","spacious"]),FormHelperTextProps:c.object,fullWidth:c.bool,helperText:c.node,hiddenLabel:c.bool,id:c.string,InputLabelProps:c.object,inputProps:c.object,InputProps:c.object,inputRef:mn,label:c.node,margin:c.oneOf(["dense","none","normal"]),maxDate:c.object,minDate:c.object,name:c.string,onBlur:c.func,onChange:c.func,onClear:c.func,onError:c.func,onFocus:c.func,onSelectedSectionsChange:c.func,readOnly:c.bool,referenceDate:c.object,required:c.bool,selectedSections:c.oneOfType([c.oneOf(["all","day","empty","hours","meridiem","minutes","month","seconds","weekDay","year"]),c.number]),shouldDisableDate:c.func,shouldDisableMonth:c.func,shouldDisableYear:c.func,shouldRespectLeadingZeros:c.bool,size:c.oneOf(["medium","small"]),slotProps:c.object,slots:c.object,style:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),timezone:c.string,unstableFieldRef:c.oneOfType([c.func,c.object]),value:c.object,variant:c.oneOf(["filled","outlined","standard"])});var Td={exports:{}},$H=Td.exports,f_;function BH(){return f_||(f_=1,function(t,e){(function(n,r){t.exports=r()})($H,function(){var n="minute",r=/[+-]\d\d(?::?\d\d)?/g,o=/([+-]|\d\d)/g;return function(i,s,a){var l=s.prototype;a.utc=function(b){var S={date:b,utc:!0,args:arguments};return new s(S)},l.utc=function(b){var S=a(this.toDate(),{locale:this.$L,utc:!0});return b?S.add(this.utcOffset(),n):S},l.local=function(){return a(this.toDate(),{locale:this.$L,utc:!1})};var u=l.parse;l.parse=function(b){b.utc&&(this.$u=!0),this.$utils().u(b.$offset)||(this.$offset=b.$offset),u.call(this,b)};var f=l.init;l.init=function(){if(this.$u){var b=this.$d;this.$y=b.getUTCFullYear(),this.$M=b.getUTCMonth(),this.$D=b.getUTCDate(),this.$W=b.getUTCDay(),this.$H=b.getUTCHours(),this.$m=b.getUTCMinutes(),this.$s=b.getUTCSeconds(),this.$ms=b.getUTCMilliseconds()}else f.call(this)};var p=l.utcOffset;l.utcOffset=function(b,S){var C=this.$utils().u;if(C(b))return this.$u?0:C(this.$offset)?p.call(this):this.$offset;if(typeof b=="string"&&(b=function(E){E===void 0&&(E="");var O=E.match(r);if(!O)return null;var L=(""+O[0]).match(o)||["-",0,0],P=L[0],$=60*+L[1]+ +L[2];return $===0?0:P==="+"?$:-$}(b),b===null))return this;var T=Math.abs(b)<=16?60*b:b,_=this;if(S)return _.$offset=T,_.$u=b===0,_;if(b!==0){var w=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();(_=this.local().add(T+w,n)).$offset=T,_.$x.$localOffset=w}else _=this.utc();return _};var g=l.format;l.format=function(b){var S=b||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return g.call(this,S)},l.valueOf=function(){var b=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*b},l.isUTC=function(){return!!this.$u},l.toISOString=function(){return this.toDate().toISOString()},l.toString=function(){return this.toDate().toUTCString()};var m=l.toDate;l.toDate=function(b){return b==="s"&&this.$offset?a(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():m.call(this)};var y=l.diff;l.diff=function(b,S,C){if(b&&this.$u===b.$u)return y.call(this,b,S,C);var T=this.local(),_=a(b).local();return y.call(T,_,S,C)}}})}(Td)),Td.exports}var RH=BH();const zH=Zn(RH);pn.extend(zH);const p_=A5({themeId:Pl});function VH(t){return Ke("MuiPickersToolbar",t)}qe("MuiPickersToolbar",["root","content"]);const HH=["children","className","toolbarTitle","hidden","titleId","isLandscape","classes","landscapeDirection"],jH=t=>{const{classes:e}=t;return Ue({root:["root"],content:["content"]},VH,e)},WH=be("div",{name:"MuiPickersToolbar",slot:"Root",overridesResolver:(t,e)=>e.root})(({theme:t})=>({display:"flex",flexDirection:"column",alignItems:"flex-start",justifyContent:"space-between",padding:t.spacing(2,3),variants:[{props:{isLandscape:!0},style:{height:"auto",maxWidth:160,padding:16,justifyContent:"flex-start",flexWrap:"wrap"}}]})),qH=be("div",{name:"MuiPickersToolbar",slot:"Content",overridesResolver:(t,e)=>e.content})({display:"flex",flexWrap:"wrap",width:"100%",flex:1,justifyContent:"space-between",alignItems:"center",flexDirection:"row",variants:[{props:{isLandscape:!0},style:{justifyContent:"flex-start",alignItems:"flex-start",flexDirection:"column"}},{props:{isLandscape:!0,landscapeDirection:"row"},style:{flexDirection:"row"}}]}),UH=I.forwardRef(function(e,n){const r=Wt({props:e,name:"MuiPickersToolbar"}),{children:o,className:i,toolbarTitle:s,hidden:a,titleId:l}=r,u=rt(r,HH),f=r,p=jH(f);return a?null:v.jsxs(WH,ne({ref:n,className:Le(p.root,i),ownerState:f},u,{children:[v.jsx(Ti,{color:"text.secondary",variant:"overline",id:l,children:s}),v.jsx(qH,{className:p.content,ownerState:f,children:o})]}))});function KH(t){return Ke("MuiDatePickerToolbar",t)}qe("MuiDatePickerToolbar",["root","title"]);const YH=["value","isLandscape","onChange","toolbarFormat","toolbarPlaceholder","views","className","onViewChange","view"],GH=t=>{const{classes:e}=t;return Ue({root:["root"],title:["title"]},KH,e)},JH=be(UH,{name:"MuiDatePickerToolbar",slot:"Root",overridesResolver:(t,e)=>e.root})({}),ZH=be(Ti,{name:"MuiDatePickerToolbar",slot:"Title",overridesResolver:(t,e)=>e.title})({variants:[{props:{isLandscape:!0},style:{margin:"auto 16px auto auto"}}]}),h_=I.forwardRef(function(e,n){const r=Wt({props:e,name:"MuiDatePickerToolbar"}),{value:o,isLandscape:i,toolbarFormat:s,toolbarPlaceholder:a="––",views:l,className:u}=r,f=rt(r,YH),p=qt(),g=Ko(),m=GH(r),y=I.useMemo(()=>{if(!o)return a;const S=Og(p,{format:s,views:l},!0);return p.formatByString(o,S)},[o,s,a,p,l]),b=r;return v.jsx(JH,ne({ref:n,toolbarTitle:g.datePickerToolbarTitle,isLandscape:i,className:Le(m.root,u)},f,{children:v.jsx(ZH,{variant:"h4",align:i?"left":"center",ownerState:b,className:m.title,children:y})}))});process.env.NODE_ENV!=="production"&&(h_.propTypes={classes:c.object,className:c.string,disabled:c.bool,hidden:c.bool,isLandscape:c.bool.isRequired,onChange:c.func.isRequired,onViewChange:c.func.isRequired,readOnly:c.bool,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),titleId:c.string,toolbarFormat:c.string,toolbarPlaceholder:c.node,value:c.object,view:c.oneOf(["day","month","year"]).isRequired,views:c.arrayOf(c.oneOf(["day","month","year"]).isRequired).isRequired});function g_(t,e){const n=qt(),r=Ql(),o=Wt({props:t,name:e}),i=I.useMemo(()=>{var s;return((s=o.localeText)==null?void 0:s.toolbarTitle)==null?o.localeText:ne({},o.localeText,{datePickerToolbarTitle:o.localeText.toolbarTitle})},[o.localeText]);return ne({},o,{localeText:i},g4({views:o.views,openTo:o.openTo,defaultViews:["year","day"],defaultOpenTo:"day"}),{disableFuture:o.disableFuture??!1,disablePast:o.disablePast??!1,minDate:Nr(n,o.minDate,r.minDate),maxDate:Nr(n,o.maxDate,r.maxDate),slots:ne({toolbar:h_},o.slots)})}var ar="top",Fr="bottom",$r="right",lr="left",qg="auto",nc=[ar,Fr,$r,lr],wa="start",rc="end",XH="clippingParents",m_="viewport",oc="popper",QH="reference",y_=nc.reduce(function(t,e){return t.concat([e+"-"+wa,e+"-"+rc])},[]),b_=[].concat(nc,[qg]).reduce(function(t,e){return t.concat([e,e+"-"+wa,e+"-"+rc])},[]),e6="beforeRead",t6="read",n6="afterRead",r6="beforeMain",o6="main",i6="afterMain",s6="beforeWrite",a6="write",l6="afterWrite",c6=[e6,t6,n6,r6,o6,i6,s6,a6,l6];function _o(t){return t?(t.nodeName||"").toLowerCase():null}function Sr(t){if(t==null)return window;if(t.toString()!=="[object Window]"){var e=t.ownerDocument;return e&&e.defaultView||window}return t}function bs(t){var e=Sr(t).Element;return t instanceof e||t instanceof Element}function Br(t){var e=Sr(t).HTMLElement;return t instanceof e||t instanceof HTMLElement}function Ug(t){if(typeof ShadowRoot>"u")return!1;var e=Sr(t).ShadowRoot;return t instanceof e||t instanceof ShadowRoot}function u6(t){var e=t.state;Object.keys(e.elements).forEach(function(n){var r=e.styles[n]||{},o=e.attributes[n]||{},i=e.elements[n];!Br(i)||!_o(i)||(Object.assign(i.style,r),Object.keys(o).forEach(function(s){var a=o[s];a===!1?i.removeAttribute(s):i.setAttribute(s,a===!0?"":a)}))})}function d6(t){var e=t.state,n={popper:{position:e.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(e.elements.popper.style,n.popper),e.styles=n,e.elements.arrow&&Object.assign(e.elements.arrow.style,n.arrow),function(){Object.keys(e.elements).forEach(function(r){var o=e.elements[r],i=e.attributes[r]||{},s=Object.keys(e.styles.hasOwnProperty(r)?e.styles[r]:n[r]),a=s.reduce(function(l,u){return l[u]="",l},{});!Br(o)||!_o(o)||(Object.assign(o.style,a),Object.keys(i).forEach(function(l){o.removeAttribute(l)}))})}}const v_={name:"applyStyles",enabled:!0,phase:"write",fn:u6,effect:d6,requires:["computeStyles"]};function To(t){return t.split("-")[0]}var vs=Math.max,kd=Math.min,_a=Math.round;function Kg(){var t=navigator.userAgentData;return t!=null&&t.brands&&Array.isArray(t.brands)?t.brands.map(function(e){return e.brand+"/"+e.version}).join(" "):navigator.userAgent}function x_(){return!/^((?!chrome|android).)*safari/i.test(Kg())}function Ta(t,e,n){e===void 0&&(e=!1),n===void 0&&(n=!1);var r=t.getBoundingClientRect(),o=1,i=1;e&&Br(t)&&(o=t.offsetWidth>0&&_a(r.width)/t.offsetWidth||1,i=t.offsetHeight>0&&_a(r.height)/t.offsetHeight||1);var s=bs(t)?Sr(t):window,a=s.visualViewport,l=!x_()&&n,u=(r.left+(l&&a?a.offsetLeft:0))/o,f=(r.top+(l&&a?a.offsetTop:0))/i,p=r.width/o,g=r.height/i;return{width:p,height:g,top:f,right:u+p,bottom:f+g,left:u,x:u,y:f}}function Yg(t){var e=Ta(t),n=t.offsetWidth,r=t.offsetHeight;return Math.abs(e.width-n)<=1&&(n=e.width),Math.abs(e.height-r)<=1&&(r=e.height),{x:t.offsetLeft,y:t.offsetTop,width:n,height:r}}function S_(t,e){var n=e.getRootNode&&e.getRootNode();if(t.contains(e))return!0;if(n&&Ug(n)){var r=e;do{if(r&&t.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function Go(t){return Sr(t).getComputedStyle(t)}function f6(t){return["table","td","th"].indexOf(_o(t))>=0}function ki(t){return((bs(t)?t.ownerDocument:t.document)||window.document).documentElement}function Ed(t){return _o(t)==="html"?t:t.assignedSlot||t.parentNode||(Ug(t)?t.host:null)||ki(t)}function C_(t){return!Br(t)||Go(t).position==="fixed"?null:t.offsetParent}function p6(t){var e=/firefox/i.test(Kg()),n=/Trident/i.test(Kg());if(n&&Br(t)){var r=Go(t);if(r.position==="fixed")return null}var o=Ed(t);for(Ug(o)&&(o=o.host);Br(o)&&["html","body"].indexOf(_o(o))<0;){var i=Go(o);if(i.transform!=="none"||i.perspective!=="none"||i.contain==="paint"||["transform","perspective"].indexOf(i.willChange)!==-1||e&&i.willChange==="filter"||e&&i.filter&&i.filter!=="none")return o;o=o.parentNode}return null}function ic(t){for(var e=Sr(t),n=C_(t);n&&f6(n)&&Go(n).position==="static";)n=C_(n);return n&&(_o(n)==="html"||_o(n)==="body"&&Go(n).position==="static")?e:n||p6(t)||e}function Gg(t){return["top","bottom"].indexOf(t)>=0?"x":"y"}function sc(t,e,n){return vs(t,kd(e,n))}function h6(t,e,n){var r=sc(t,e,n);return r>n?n:r}function w_(){return{top:0,right:0,bottom:0,left:0}}function __(t){return Object.assign({},w_(),t)}function T_(t,e){return e.reduce(function(n,r){return n[r]=t,n},{})}var g6=function(e,n){return e=typeof e=="function"?e(Object.assign({},n.rects,{placement:n.placement})):e,__(typeof e!="number"?e:T_(e,nc))};function m6(t){var e,n=t.state,r=t.name,o=t.options,i=n.elements.arrow,s=n.modifiersData.popperOffsets,a=To(n.placement),l=Gg(a),u=[lr,$r].indexOf(a)>=0,f=u?"height":"width";if(!(!i||!s)){var p=g6(o.padding,n),g=Yg(i),m=l==="y"?ar:lr,y=l==="y"?Fr:$r,b=n.rects.reference[f]+n.rects.reference[l]-s[l]-n.rects.popper[f],S=s[l]-n.rects.reference[l],C=ic(i),T=C?l==="y"?C.clientHeight||0:C.clientWidth||0:0,_=b/2-S/2,w=p[m],E=T-g[f]-p[y],O=T/2-g[f]/2+_,L=sc(w,O,E),P=l;n.modifiersData[r]=(e={},e[P]=L,e.centerOffset=L-O,e)}}function y6(t){var e=t.state,n=t.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=e.elements.popper.querySelector(o),!o)||S_(e.elements.popper,o)&&(e.elements.arrow=o))}const b6={name:"arrow",enabled:!0,phase:"main",fn:m6,effect:y6,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function ka(t){return t.split("-")[1]}var v6={top:"auto",right:"auto",bottom:"auto",left:"auto"};function x6(t,e){var n=t.x,r=t.y,o=e.devicePixelRatio||1;return{x:_a(n*o)/o||0,y:_a(r*o)/o||0}}function k_(t){var e,n=t.popper,r=t.popperRect,o=t.placement,i=t.variation,s=t.offsets,a=t.position,l=t.gpuAcceleration,u=t.adaptive,f=t.roundOffsets,p=t.isFixed,g=s.x,m=g===void 0?0:g,y=s.y,b=y===void 0?0:y,S=typeof f=="function"?f({x:m,y:b}):{x:m,y:b};m=S.x,b=S.y;var C=s.hasOwnProperty("x"),T=s.hasOwnProperty("y"),_=lr,w=ar,E=window;if(u){var O=ic(n),L="clientHeight",P="clientWidth";if(O===Sr(n)&&(O=ki(n),Go(O).position!=="static"&&a==="absolute"&&(L="scrollHeight",P="scrollWidth")),O=O,o===ar||(o===lr||o===$r)&&i===rc){w=Fr;var $=p&&O===E&&E.visualViewport?E.visualViewport.height:O[L];b-=$-r.height,b*=l?1:-1}if(o===lr||(o===ar||o===Fr)&&i===rc){_=$r;var M=p&&O===E&&E.visualViewport?E.visualViewport.width:O[P];m-=M-r.width,m*=l?1:-1}}var A=Object.assign({position:a},u&&v6),N=f===!0?x6({x:m,y:b},Sr(n)):{x:m,y:b};if(m=N.x,b=N.y,l){var V;return Object.assign({},A,(V={},V[w]=T?"0":"",V[_]=C?"0":"",V.transform=(E.devicePixelRatio||1)<=1?"translate("+m+"px, "+b+"px)":"translate3d("+m+"px, "+b+"px, 0)",V))}return Object.assign({},A,(e={},e[w]=T?b+"px":"",e[_]=C?m+"px":"",e.transform="",e))}function S6(t){var e=t.state,n=t.options,r=n.gpuAcceleration,o=r===void 0?!0:r,i=n.adaptive,s=i===void 0?!0:i,a=n.roundOffsets,l=a===void 0?!0:a,u={placement:To(e.placement),variation:ka(e.placement),popper:e.elements.popper,popperRect:e.rects.popper,gpuAcceleration:o,isFixed:e.options.strategy==="fixed"};e.modifiersData.popperOffsets!=null&&(e.styles.popper=Object.assign({},e.styles.popper,k_(Object.assign({},u,{offsets:e.modifiersData.popperOffsets,position:e.options.strategy,adaptive:s,roundOffsets:l})))),e.modifiersData.arrow!=null&&(e.styles.arrow=Object.assign({},e.styles.arrow,k_(Object.assign({},u,{offsets:e.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),e.attributes.popper=Object.assign({},e.attributes.popper,{"data-popper-placement":e.placement})}const C6={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:S6,data:{}};var Md={passive:!0};function w6(t){var e=t.state,n=t.instance,r=t.options,o=r.scroll,i=o===void 0?!0:o,s=r.resize,a=s===void 0?!0:s,l=Sr(e.elements.popper),u=[].concat(e.scrollParents.reference,e.scrollParents.popper);return i&&u.forEach(function(f){f.addEventListener("scroll",n.update,Md)}),a&&l.addEventListener("resize",n.update,Md),function(){i&&u.forEach(function(f){f.removeEventListener("scroll",n.update,Md)}),a&&l.removeEventListener("resize",n.update,Md)}}const _6={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:w6,data:{}};var T6={left:"right",right:"left",bottom:"top",top:"bottom"};function Od(t){return t.replace(/left|right|bottom|top/g,function(e){return T6[e]})}var k6={start:"end",end:"start"};function E_(t){return t.replace(/start|end/g,function(e){return k6[e]})}function Jg(t){var e=Sr(t),n=e.pageXOffset,r=e.pageYOffset;return{scrollLeft:n,scrollTop:r}}function Zg(t){return Ta(ki(t)).left+Jg(t).scrollLeft}function E6(t,e){var n=Sr(t),r=ki(t),o=n.visualViewport,i=r.clientWidth,s=r.clientHeight,a=0,l=0;if(o){i=o.width,s=o.height;var u=x_();(u||!u&&e==="fixed")&&(a=o.offsetLeft,l=o.offsetTop)}return{width:i,height:s,x:a+Zg(t),y:l}}function M6(t){var e,n=ki(t),r=Jg(t),o=(e=t.ownerDocument)==null?void 0:e.body,i=vs(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),s=vs(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),a=-r.scrollLeft+Zg(t),l=-r.scrollTop;return Go(o||n).direction==="rtl"&&(a+=vs(n.clientWidth,o?o.clientWidth:0)-i),{width:i,height:s,x:a,y:l}}function Xg(t){var e=Go(t),n=e.overflow,r=e.overflowX,o=e.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+r)}function M_(t){return["html","body","#document"].indexOf(_o(t))>=0?t.ownerDocument.body:Br(t)&&Xg(t)?t:M_(Ed(t))}function ac(t,e){var n;e===void 0&&(e=[]);var r=M_(t),o=r===((n=t.ownerDocument)==null?void 0:n.body),i=Sr(r),s=o?[i].concat(i.visualViewport||[],Xg(r)?r:[]):r,a=e.concat(s);return o?a:a.concat(ac(Ed(s)))}function Qg(t){return Object.assign({},t,{left:t.x,top:t.y,right:t.x+t.width,bottom:t.y+t.height})}function O6(t,e){var n=Ta(t,!1,e==="fixed");return n.top=n.top+t.clientTop,n.left=n.left+t.clientLeft,n.bottom=n.top+t.clientHeight,n.right=n.left+t.clientWidth,n.width=t.clientWidth,n.height=t.clientHeight,n.x=n.left,n.y=n.top,n}function O_(t,e,n){return e===m_?Qg(E6(t,n)):bs(e)?O6(e,n):Qg(M6(ki(t)))}function A6(t){var e=ac(Ed(t)),n=["absolute","fixed"].indexOf(Go(t).position)>=0,r=n&&Br(t)?ic(t):t;return bs(r)?e.filter(function(o){return bs(o)&&S_(o,r)&&_o(o)!=="body"}):[]}function I6(t,e,n,r){var o=e==="clippingParents"?A6(t):[].concat(e),i=[].concat(o,[n]),s=i[0],a=i.reduce(function(l,u){var f=O_(t,u,r);return l.top=vs(f.top,l.top),l.right=kd(f.right,l.right),l.bottom=kd(f.bottom,l.bottom),l.left=vs(f.left,l.left),l},O_(t,s,r));return a.width=a.right-a.left,a.height=a.bottom-a.top,a.x=a.left,a.y=a.top,a}function A_(t){var e=t.reference,n=t.element,r=t.placement,o=r?To(r):null,i=r?ka(r):null,s=e.x+e.width/2-n.width/2,a=e.y+e.height/2-n.height/2,l;switch(o){case ar:l={x:s,y:e.y-n.height};break;case Fr:l={x:s,y:e.y+e.height};break;case $r:l={x:e.x+e.width,y:a};break;case lr:l={x:e.x-n.width,y:a};break;default:l={x:e.x,y:e.y}}var u=o?Gg(o):null;if(u!=null){var f=u==="y"?"height":"width";switch(i){case wa:l[u]=l[u]-(e[f]/2-n[f]/2);break;case rc:l[u]=l[u]+(e[f]/2-n[f]/2);break}}return l}function lc(t,e){e===void 0&&(e={});var n=e,r=n.placement,o=r===void 0?t.placement:r,i=n.strategy,s=i===void 0?t.strategy:i,a=n.boundary,l=a===void 0?XH:a,u=n.rootBoundary,f=u===void 0?m_:u,p=n.elementContext,g=p===void 0?oc:p,m=n.altBoundary,y=m===void 0?!1:m,b=n.padding,S=b===void 0?0:b,C=__(typeof S!="number"?S:T_(S,nc)),T=g===oc?QH:oc,_=t.rects.popper,w=t.elements[y?T:g],E=I6(bs(w)?w:w.contextElement||ki(t.elements.popper),l,f,s),O=Ta(t.elements.reference),L=A_({reference:O,element:_,strategy:"absolute",placement:o}),P=Qg(Object.assign({},_,L)),$=g===oc?P:O,M={top:E.top-$.top+C.top,bottom:$.bottom-E.bottom+C.bottom,left:E.left-$.left+C.left,right:$.right-E.right+C.right},A=t.modifiersData.offset;if(g===oc&&A){var N=A[o];Object.keys(M).forEach(function(V){var R=[$r,Fr].indexOf(V)>=0?1:-1,B=[ar,Fr].indexOf(V)>=0?"y":"x";M[V]+=N[B]*R})}return M}function D6(t,e){e===void 0&&(e={});var n=e,r=n.placement,o=n.boundary,i=n.rootBoundary,s=n.padding,a=n.flipVariations,l=n.allowedAutoPlacements,u=l===void 0?b_:l,f=ka(r),p=f?a?y_:y_.filter(function(y){return ka(y)===f}):nc,g=p.filter(function(y){return u.indexOf(y)>=0});g.length===0&&(g=p);var m=g.reduce(function(y,b){return y[b]=lc(t,{placement:b,boundary:o,rootBoundary:i,padding:s})[To(b)],y},{});return Object.keys(m).sort(function(y,b){return m[y]-m[b]})}function P6(t){if(To(t)===qg)return[];var e=Od(t);return[E_(t),e,E_(e)]}function N6(t){var e=t.state,n=t.options,r=t.name;if(!e.modifiersData[r]._skip){for(var o=n.mainAxis,i=o===void 0?!0:o,s=n.altAxis,a=s===void 0?!0:s,l=n.fallbackPlacements,u=n.padding,f=n.boundary,p=n.rootBoundary,g=n.altBoundary,m=n.flipVariations,y=m===void 0?!0:m,b=n.allowedAutoPlacements,S=e.options.placement,C=To(S),T=C===S,_=l||(T||!y?[Od(S)]:P6(S)),w=[S].concat(_).reduce(function(oe,Q){return oe.concat(To(Q)===qg?D6(e,{placement:Q,boundary:f,rootBoundary:p,padding:u,flipVariations:y,allowedAutoPlacements:b}):Q)},[]),E=e.rects.reference,O=e.rects.popper,L=new Map,P=!0,$=w[0],M=0;M<w.length;M++){var A=w[M],N=To(A),V=ka(A)===wa,R=[ar,Fr].indexOf(N)>=0,B=R?"width":"height",z=lc(e,{placement:A,boundary:f,rootBoundary:p,altBoundary:g,padding:u}),q=R?V?$r:lr:V?Fr:ar;E[B]>O[B]&&(q=Od(q));var K=Od(q),G=[];if(i&&G.push(z[N]<=0),a&&G.push(z[q]<=0,z[K]<=0),G.every(function(oe){return oe})){$=A,P=!1;break}L.set(A,G)}if(P)for(var Y=y?3:1,Z=function(Q){var fe=w.find(function(ce){var ae=L.get(ce);if(ae)return ae.slice(0,Q).every(function(W){return W})});if(fe)return $=fe,"break"},me=Y;me>0;me--){var he=Z(me);if(he==="break")break}e.placement!==$&&(e.modifiersData[r]._skip=!0,e.placement=$,e.reset=!0)}}const L6={name:"flip",enabled:!0,phase:"main",fn:N6,requiresIfExists:["offset"],data:{_skip:!1}};function I_(t,e,n){return n===void 0&&(n={x:0,y:0}),{top:t.top-e.height-n.y,right:t.right-e.width+n.x,bottom:t.bottom-e.height+n.y,left:t.left-e.width-n.x}}function D_(t){return[ar,$r,Fr,lr].some(function(e){return t[e]>=0})}function F6(t){var e=t.state,n=t.name,r=e.rects.reference,o=e.rects.popper,i=e.modifiersData.preventOverflow,s=lc(e,{elementContext:"reference"}),a=lc(e,{altBoundary:!0}),l=I_(s,r),u=I_(a,o,i),f=D_(l),p=D_(u);e.modifiersData[n]={referenceClippingOffsets:l,popperEscapeOffsets:u,isReferenceHidden:f,hasPopperEscaped:p},e.attributes.popper=Object.assign({},e.attributes.popper,{"data-popper-reference-hidden":f,"data-popper-escaped":p})}const $6={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:F6};function B6(t,e,n){var r=To(t),o=[lr,ar].indexOf(r)>=0?-1:1,i=typeof n=="function"?n(Object.assign({},e,{placement:t})):n,s=i[0],a=i[1];return s=s||0,a=(a||0)*o,[lr,$r].indexOf(r)>=0?{x:a,y:s}:{x:s,y:a}}function R6(t){var e=t.state,n=t.options,r=t.name,o=n.offset,i=o===void 0?[0,0]:o,s=b_.reduce(function(f,p){return f[p]=B6(p,e.rects,i),f},{}),a=s[e.placement],l=a.x,u=a.y;e.modifiersData.popperOffsets!=null&&(e.modifiersData.popperOffsets.x+=l,e.modifiersData.popperOffsets.y+=u),e.modifiersData[r]=s}const z6={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:R6};function V6(t){var e=t.state,n=t.name;e.modifiersData[n]=A_({reference:e.rects.reference,element:e.rects.popper,strategy:"absolute",placement:e.placement})}const H6={name:"popperOffsets",enabled:!0,phase:"read",fn:V6,data:{}};function j6(t){return t==="x"?"y":"x"}function W6(t){var e=t.state,n=t.options,r=t.name,o=n.mainAxis,i=o===void 0?!0:o,s=n.altAxis,a=s===void 0?!1:s,l=n.boundary,u=n.rootBoundary,f=n.altBoundary,p=n.padding,g=n.tether,m=g===void 0?!0:g,y=n.tetherOffset,b=y===void 0?0:y,S=lc(e,{boundary:l,rootBoundary:u,padding:p,altBoundary:f}),C=To(e.placement),T=ka(e.placement),_=!T,w=Gg(C),E=j6(w),O=e.modifiersData.popperOffsets,L=e.rects.reference,P=e.rects.popper,$=typeof b=="function"?b(Object.assign({},e.rects,{placement:e.placement})):b,M=typeof $=="number"?{mainAxis:$,altAxis:$}:Object.assign({mainAxis:0,altAxis:0},$),A=e.modifiersData.offset?e.modifiersData.offset[e.placement]:null,N={x:0,y:0};if(O){if(i){var V,R=w==="y"?ar:lr,B=w==="y"?Fr:$r,z=w==="y"?"height":"width",q=O[w],K=q+S[R],G=q-S[B],Y=m?-P[z]/2:0,Z=T===wa?L[z]:P[z],me=T===wa?-P[z]:-L[z],he=e.elements.arrow,oe=m&&he?Yg(he):{width:0,height:0},Q=e.modifiersData["arrow#persistent"]?e.modifiersData["arrow#persistent"].padding:w_(),fe=Q[R],ce=Q[B],ae=sc(0,L[z],oe[z]),W=_?L[z]/2-Y-ae-fe-M.mainAxis:Z-ae-fe-M.mainAxis,te=_?-L[z]/2+Y+ae+ce+M.mainAxis:me+ae+ce+M.mainAxis,ue=e.elements.arrow&&ic(e.elements.arrow),ee=ue?w==="y"?ue.clientTop||0:ue.clientLeft||0:0,se=(V=A==null?void 0:A[w])!=null?V:0,de=q+W-se-ee,ye=q+te-se,_e=sc(m?kd(K,de):K,q,m?vs(G,ye):G);O[w]=_e,N[w]=_e-q}if(a){var Se,Me=w==="x"?ar:lr,Fe=w==="x"?Fr:$r,je=O[E],Je=E==="y"?"height":"width",De=je+S[Me],ct=je-S[Fe],Ct=[ar,lr].indexOf(C)!==-1,Xt=(Se=A==null?void 0:A[E])!=null?Se:0,Sn=Ct?De:je-L[Je]-P[Je]-Xt+M.altAxis,un=Ct?je+L[Je]+P[Je]-Xt-M.altAxis:ct,$t=m&&Ct?h6(Sn,je,un):sc(m?Sn:De,je,m?un:ct);O[E]=$t,N[E]=$t-je}e.modifiersData[r]=N}}const q6={name:"preventOverflow",enabled:!0,phase:"main",fn:W6,requiresIfExists:["offset"]};function U6(t){return{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}}function K6(t){return t===Sr(t)||!Br(t)?Jg(t):U6(t)}function Y6(t){var e=t.getBoundingClientRect(),n=_a(e.width)/t.offsetWidth||1,r=_a(e.height)/t.offsetHeight||1;return n!==1||r!==1}function G6(t,e,n){n===void 0&&(n=!1);var r=Br(e),o=Br(e)&&Y6(e),i=ki(e),s=Ta(t,o,n),a={scrollLeft:0,scrollTop:0},l={x:0,y:0};return(r||!r&&!n)&&((_o(e)!=="body"||Xg(i))&&(a=K6(e)),Br(e)?(l=Ta(e,!0),l.x+=e.clientLeft,l.y+=e.clientTop):i&&(l.x=Zg(i))),{x:s.left+a.scrollLeft-l.x,y:s.top+a.scrollTop-l.y,width:s.width,height:s.height}}function J6(t){var e=new Map,n=new Set,r=[];t.forEach(function(i){e.set(i.name,i)});function o(i){n.add(i.name);var s=[].concat(i.requires||[],i.requiresIfExists||[]);s.forEach(function(a){if(!n.has(a)){var l=e.get(a);l&&o(l)}}),r.push(i)}return t.forEach(function(i){n.has(i.name)||o(i)}),r}function Z6(t){var e=J6(t);return c6.reduce(function(n,r){return n.concat(e.filter(function(o){return o.phase===r}))},[])}function X6(t){var e;return function(){return e||(e=new Promise(function(n){Promise.resolve().then(function(){e=void 0,n(t())})})),e}}function Q6(t){var e=t.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(e).map(function(n){return e[n]})}var P_={placement:"bottom",modifiers:[],strategy:"absolute"};function N_(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return!e.some(function(r){return!(r&&typeof r.getBoundingClientRect=="function")})}function ej(t){t===void 0&&(t={});var e=t,n=e.defaultModifiers,r=n===void 0?[]:n,o=e.defaultOptions,i=o===void 0?P_:o;return function(a,l,u){u===void 0&&(u=i);var f={placement:"bottom",orderedModifiers:[],options:Object.assign({},P_,i),modifiersData:{},elements:{reference:a,popper:l},attributes:{},styles:{}},p=[],g=!1,m={state:f,setOptions:function(C){var T=typeof C=="function"?C(f.options):C;b(),f.options=Object.assign({},i,f.options,T),f.scrollParents={reference:bs(a)?ac(a):a.contextElement?ac(a.contextElement):[],popper:ac(l)};var _=Z6(Q6([].concat(r,f.options.modifiers)));return f.orderedModifiers=_.filter(function(w){return w.enabled}),y(),m.update()},forceUpdate:function(){if(!g){var C=f.elements,T=C.reference,_=C.popper;if(N_(T,_)){f.rects={reference:G6(T,ic(_),f.options.strategy==="fixed"),popper:Yg(_)},f.reset=!1,f.placement=f.options.placement,f.orderedModifiers.forEach(function(M){return f.modifiersData[M.name]=Object.assign({},M.data)});for(var w=0;w<f.orderedModifiers.length;w++){if(f.reset===!0){f.reset=!1,w=-1;continue}var E=f.orderedModifiers[w],O=E.fn,L=E.options,P=L===void 0?{}:L,$=E.name;typeof O=="function"&&(f=O({state:f,options:P,name:$,instance:m})||f)}}}},update:X6(function(){return new Promise(function(S){m.forceUpdate(),S(f)})}),destroy:function(){b(),g=!0}};if(!N_(a,l))return m;m.setOptions(u).then(function(S){!g&&u.onFirstUpdate&&u.onFirstUpdate(S)});function y(){f.orderedModifiers.forEach(function(S){var C=S.name,T=S.options,_=T===void 0?{}:T,w=S.effect;if(typeof w=="function"){var E=w({state:f,name:C,instance:m,options:_}),O=function(){};p.push(E||O)}})}function b(){p.forEach(function(S){return S()}),p=[]}return m}}var tj=[_6,H6,C6,v_,z6,L6,q6,b6,$6],L_=ej({defaultModifiers:tj});function nj(t){return Ke("MuiPopper",t)}qe("MuiPopper",["root"]);function rj(t,e){if(e==="ltr")return t;switch(t){case"bottom-end":return"bottom-start";case"bottom-start":return"bottom-end";case"top-end":return"top-start";case"top-start":return"top-end";default:return t}}function Ad(t){return typeof t=="function"?t():t}function Id(t){return t.nodeType!==void 0}function oj(t){return!Id(t)}const ij=t=>{const{classes:e}=t;return Ue({root:["root"]},nj,e)},sj={},aj=I.forwardRef(function(e,n){const{anchorEl:r,children:o,direction:i,disablePortal:s,modifiers:a,open:l,placement:u,popperOptions:f,popperRef:p,slotProps:g={},slots:m={},TransitionProps:y,ownerState:b,...S}=e,C=I.useRef(null),T=Et(C,n),_=I.useRef(null),w=Et(_,p),E=I.useRef(w);Tn(()=>{E.current=w},[w]),I.useImperativeHandle(p,()=>_.current,[]);const O=rj(u,i),[L,P]=I.useState(O),[$,M]=I.useState(Ad(r));I.useEffect(()=>{_.current&&_.current.forceUpdate()}),I.useEffect(()=>{r&&M(Ad(r))},[r]),Tn(()=>{if(!$||!l)return;const B=K=>{P(K.placement)};if(process.env.NODE_ENV!=="production"&&$&&Id($)&&$.nodeType===1){const K=$.getBoundingClientRect();process.env.NODE_ENV!=="test"&&K.top===0&&K.left===0&&K.right===0&&K.bottom===0&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(`
|
|
230
|
-
`))}let
|
|
229
|
+
`)):null),classes:c.object,className:c.string,color:c.oneOfType([c.oneOf(["inherit","default","primary","secondary","error","info","success","warning"]),c.string]),disabled:c.bool,disableFocusRipple:c.bool,disableRipple:c.bool,edge:c.oneOf(["end","start",!1]),id:c.string,loading:c.bool,loadingIndicator:c.node,size:c.oneOfType([c.oneOf(["small","medium","large"]),c.string]),sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object])});function AV(t){return Ke("MuiTypography",t)}qe("MuiTypography",["root","h1","h2","h3","h4","h5","h6","subtitle1","subtitle2","body1","body2","inherit","button","caption","overline","alignLeft","alignRight","alignCenter","alignJustify","noWrap","gutterBottom","paragraph"]);const IV={primary:!0,secondary:!0,error:!0,info:!0,success:!0,warning:!0,textPrimary:!0,textSecondary:!0,textDisabled:!0},DV=wB(),PV=t=>{const{align:e,gutterBottom:n,noWrap:r,paragraph:o,variant:i,classes:s}=t,a={root:["root",i,t.align!=="inherit"&&`align${Ae(e)}`,n&&"gutterBottom",r&&"noWrap",o&&"paragraph"]};return Ue(a,AV,s)},NV=be("span",{name:"MuiTypography",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,n.variant&&e[n.variant],n.align!=="inherit"&&e[`align${Ae(n.align)}`],n.noWrap&&e.noWrap,n.gutterBottom&&e.gutterBottom,n.paragraph&&e.paragraph]}})(Dt(({theme:t})=>{var e;return{margin:0,variants:[{props:{variant:"inherit"},style:{font:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}},...Object.entries(t.typography).filter(([n,r])=>n!=="inherit"&&r&&typeof r=="object").map(([n,r])=>({props:{variant:n},style:r})),...Object.entries(t.palette).filter(Hn()).map(([n])=>({props:{color:n},style:{color:(t.vars||t).palette[n].main}})),...Object.entries(((e=t.palette)==null?void 0:e.text)||{}).filter(([,n])=>typeof n=="string").map(([n])=>({props:{color:`text${Ae(n)}`},style:{color:(t.vars||t).palette.text[n]}})),{props:({ownerState:n})=>n.align!=="inherit",style:{textAlign:"var(--Typography-textAlign)"}},{props:({ownerState:n})=>n.noWrap,style:{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"}},{props:({ownerState:n})=>n.gutterBottom,style:{marginBottom:"0.35em"}},{props:({ownerState:n})=>n.paragraph,style:{marginBottom:16}}]}})),e_={h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",subtitle1:"h6",subtitle2:"h6",body1:"p",body2:"p",inherit:"p"},Ti=I.forwardRef(function(e,n){const{color:r,...o}=St({props:e,name:"MuiTypography"}),i=!IV[r],s=DV({...o,...i&&{color:r}}),{align:a="inherit",className:l,component:u,gutterBottom:f=!1,noWrap:p=!1,paragraph:g=!1,variant:m="body1",variantMapping:y=e_,...b}=s,S={...s,align:a,color:r,className:l,component:u,gutterBottom:f,noWrap:p,paragraph:g,variant:m,variantMapping:y},C=u||(g?"p":y[m]||e_[m])||"span",T=PV(S);return v.jsx(NV,{as:C,ref:n,className:Le(T.root,l),...b,ownerState:S,style:{...a!=="inherit"&&{"--Typography-textAlign":a},...b.style}})});process.env.NODE_ENV!=="production"&&(Ti.propTypes={align:c.oneOf(["center","inherit","justify","left","right"]),children:c.node,classes:c.object,className:c.string,color:c.oneOfType([c.oneOf(["primary","secondary","success","error","info","warning","textPrimary","textSecondary","textDisabled"]),c.string]),component:c.elementType,gutterBottom:c.bool,noWrap:c.bool,paragraph:c.bool,style:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),variant:c.oneOfType([c.oneOf(["body1","body2","button","caption","h1","h2","h3","h4","h5","h6","inherit","overline","subtitle1","subtitle2"]),c.string]),variantMapping:c.object});function LV(t){return Ke("MuiInputAdornment",t)}const t_=qe("MuiInputAdornment",["root","filled","standard","outlined","positionStart","positionEnd","disablePointerEvents","hiddenLabel","sizeSmall"]);var n_;const FV=(t,e)=>{const{ownerState:n}=t;return[e.root,e[`position${Ae(n.position)}`],n.disablePointerEvents===!0&&e.disablePointerEvents,e[n.variant]]},$V=t=>{const{classes:e,disablePointerEvents:n,hiddenLabel:r,position:o,size:i,variant:s}=t,a={root:["root",n&&"disablePointerEvents",o&&`position${Ae(o)}`,s,r&&"hiddenLabel",i&&`size${Ae(i)}`]};return Ue(a,LV,e)},BV=be("div",{name:"MuiInputAdornment",slot:"Root",overridesResolver:FV})(Dt(({theme:t})=>({display:"flex",maxHeight:"2em",alignItems:"center",whiteSpace:"nowrap",color:(t.vars||t).palette.action.active,variants:[{props:{variant:"filled"},style:{[`&.${t_.positionStart}&:not(.${t_.hiddenLabel})`]:{marginTop:16}}},{props:{position:"start"},style:{marginRight:8}},{props:{position:"end"},style:{marginLeft:8}},{props:{disablePointerEvents:!0},style:{pointerEvents:"none"}}]}))),zg=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiInputAdornment"}),{children:o,className:i,component:s="div",disablePointerEvents:a=!1,disableTypography:l=!1,position:u,variant:f,...p}=r,g=io()||{};let m=f;f&&g.variant&&process.env.NODE_ENV!=="production"&&f===g.variant&&console.error("MUI: The `InputAdornment` variant infers the variant prop you do not have to provide one."),m||(m=g.variant);const y={...r,hiddenLabel:g.hiddenLabel,size:g.size,disablePointerEvents:a,position:u,variant:m},b=$V(y);return v.jsx(Bl.Provider,{value:null,children:v.jsx(BV,{as:s,ownerState:y,className:Le(b.root,i),ref:n,...p,children:typeof o=="string"&&!l?v.jsx(Ti,{color:"textSecondary",children:o}):v.jsxs(I.Fragment,{children:[u==="start"?n_||(n_=v.jsx("span",{className:"notranslate","aria-hidden":!0,children:""})):null,o]})})})});process.env.NODE_ENV!=="production"&&(zg.propTypes={children:c.node,classes:c.object,className:c.string,component:c.elementType,disablePointerEvents:c.bool,disableTypography:c.bool,position:c.oneOf(["end","start"]).isRequired,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),variant:c.oneOf(["filled","outlined","standard"])});const RV=ze(v.jsx("path",{d:"M7 10l5 5 5-5z"}),"ArrowDropDown"),zV=ze(v.jsx("path",{d:"M15.41 16.59L10.83 12l4.58-4.59L14 6l-6 6 6 6 1.41-1.41z"}),"ArrowLeft"),VV=ze(v.jsx("path",{d:"M8.59 16.59L13.17 12 8.59 7.41 10 6l6 6-6 6-1.41-1.41z"}),"ArrowRight"),HV=ze(v.jsx("path",{d:"M17 12h-5v5h5v-5zM16 1v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2h-1V1h-2zm3 18H5V8h14v11z"}),"Calendar");ze(v.jsxs(I.Fragment,{children:[v.jsx("path",{d:"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"}),v.jsx("path",{d:"M12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z"})]}),"Clock"),ze(v.jsx("path",{d:"M9 11H7v2h2v-2zm4 0h-2v2h2v-2zm4 0h-2v2h2v-2zm2-7h-1V2h-2v2H8V2H6v2H5c-1.11 0-1.99.9-1.99 2L3 20c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 16H5V9h14v11z"}),"DateRange"),ze(v.jsxs(I.Fragment,{children:[v.jsx("path",{d:"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"}),v.jsx("path",{d:"M12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z"})]}),"Time");const jV=ze(v.jsx("path",{d:"M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}),"Clear"),WV=["clearable","onClear","InputProps","sx","slots","slotProps"],qV=["ownerState"],UV=t=>{const e=Ko(),{clearable:n,onClear:r,InputProps:o,sx:i,slots:s,slotProps:a}=t,l=rt(t,WV),u=(s==null?void 0:s.clearButton)??Sa,f=wt({elementType:u,externalSlotProps:a==null?void 0:a.clearButton,ownerState:{},className:"clearButton",additionalProps:{title:e.fieldClearLabel}}),p=rt(f,qV),g=(s==null?void 0:s.clearIcon)??jV,m=wt({elementType:g,externalSlotProps:a==null?void 0:a.clearIcon,ownerState:{}});return ne({},l,{InputProps:ne({},o,{endAdornment:v.jsxs(I.Fragment,{children:[n&&v.jsx(zg,{position:"end",sx:{marginRight:o!=null&&o.endAdornment?-1:-1.5},children:v.jsx(u,ne({},p,{onClick:r,children:v.jsx(g,ne({fontSize:"small"},m))}))}),o==null?void 0:o.endAdornment]})}),sx:[{"& .clearButton":{opacity:1},"@media (pointer: fine)":{"& .clearButton":{opacity:0},"&:hover, &:focus-within":{".clearButton":{opacity:1}}}},...Array.isArray(i)?i:[i]]})},KV=["value","defaultValue","referenceDate","format","formatDensity","onChange","timezone","onError","shouldRespectLeadingZeros","selectedSections","onSelectedSectionsChange","unstableFieldRef","enableAccessibleFieldDOMStructure","disabled","readOnly","dateSeparator"],YV=(t,e)=>I.useMemo(()=>{const n=ne({},t),r={},o=i=>{n.hasOwnProperty(i)&&(r[i]=n[i],delete n[i])};return KV.forEach(o),qw.forEach(o),{forwardedProps:n,internalProps:r}},[t,e]),GV=I.createContext(null);function r_(t){const{contextValue:e,localeText:n,children:r}=t;return v.jsx(GV.Provider,{value:e,children:v.jsx(ag,{localeText:n,children:r})})}const JV=t=>{const e=qt(),n=Ql();return ne({},t,{disablePast:t.disablePast??!1,disableFuture:t.disableFuture??!1,format:t.format??e.formats.keyboardDate,minDate:Nr(e,t.minDate,n.minDate),maxDate:Nr(e,t.maxDate,n.maxDate)})},ZV=t=>{const e=JV(t),{forwardedProps:n,internalProps:r}=YV(e,"date");return sV({forwardedProps:n,internalProps:r,valueManager:wo,fieldValueManager:R4,validator:Xl,valueType:"date"})};function XV(t){return Ke("MuiPickersTextField",t)}qe("MuiPickersTextField",["root","focused","disabled","error","required"]);function QV(t){return Ke("MuiPickersInputBase",t)}const Ca=qe("MuiPickersInputBase",["root","focused","disabled","error","notchedOutline","sectionContent","sectionBefore","sectionAfter","adornedStart","adornedEnd","input"]);function eH(t){return Ke("MuiPickersSectionList",t)}const ec=qe("MuiPickersSectionList",["root","section","sectionContent"]),tH=["slots","slotProps","elements","sectionListRef"],o_=be("div",{name:"MuiPickersSectionList",slot:"Root",overridesResolver:(t,e)=>e.root})({direction:"ltr /*! @noflip */",outline:"none"}),i_=be("span",{name:"MuiPickersSectionList",slot:"Section",overridesResolver:(t,e)=>e.section})({}),s_=be("span",{name:"MuiPickersSectionList",slot:"SectionSeparator",overridesResolver:(t,e)=>e.sectionSeparator})({whiteSpace:"pre"}),a_=be("span",{name:"MuiPickersSectionList",slot:"SectionContent",overridesResolver:(t,e)=>e.sectionContent})({outline:"none"}),nH=t=>{const{classes:e}=t;return Ue({root:["root"],section:["section"],sectionContent:["sectionContent"]},eH,e)};function l_(t){const{slots:e,slotProps:n,element:r,classes:o}=t,i=(e==null?void 0:e.section)??i_,s=wt({elementType:i,externalSlotProps:n==null?void 0:n.section,externalForwardedProps:r.container,className:o.section,ownerState:{}}),a=(e==null?void 0:e.sectionContent)??a_,l=wt({elementType:a,externalSlotProps:n==null?void 0:n.sectionContent,externalForwardedProps:r.content,additionalProps:{suppressContentEditableWarning:!0},className:o.sectionContent,ownerState:{}}),u=(e==null?void 0:e.sectionSeparator)??s_,f=wt({elementType:u,externalSlotProps:n==null?void 0:n.sectionSeparator,externalForwardedProps:r.before,ownerState:{position:"before"}}),p=wt({elementType:u,externalSlotProps:n==null?void 0:n.sectionSeparator,externalForwardedProps:r.after,ownerState:{position:"after"}});return v.jsxs(i,ne({},s,{children:[v.jsx(u,ne({},f)),v.jsx(a,ne({},l)),v.jsx(u,ne({},p))]}))}process.env.NODE_ENV!=="production"&&(l_.propTypes={classes:c.object.isRequired,element:c.shape({after:c.object.isRequired,before:c.object.isRequired,container:c.object.isRequired,content:c.object.isRequired}).isRequired,slotProps:c.object,slots:c.object});const c_=I.forwardRef(function(e,n){const r=Wt({props:e,name:"MuiPickersSectionList"}),{slots:o,slotProps:i,elements:s,sectionListRef:a}=r,l=rt(r,tH),u=nH(r),f=I.useRef(null),p=Et(n,f),g=b=>{if(!f.current)throw new Error(`MUI X: Cannot call sectionListRef.${b} before the mount of the component.`);return f.current};I.useImperativeHandle(a,()=>({getRoot(){return g("getRoot")},getSectionContainer(b){return g("getSectionContainer").querySelector(`.${ec.section}[data-sectionindex="${b}"]`)},getSectionContent(b){return g("getSectionContent").querySelector(`.${ec.section}[data-sectionindex="${b}"] .${ec.sectionContent}`)},getSectionIndexFromDOMElement(b){const S=g("getSectionIndexFromDOMElement");if(b==null||!S.contains(b))return null;let C=null;return b.classList.contains(ec.section)?C=b:b.classList.contains(ec.sectionContent)&&(C=b.parentElement),C==null?null:Number(C.dataset.sectionindex)}}));const m=(o==null?void 0:o.root)??o_,y=wt({elementType:m,externalSlotProps:i==null?void 0:i.root,externalForwardedProps:l,additionalProps:{ref:p,suppressContentEditableWarning:!0},className:u.root,ownerState:{}});return v.jsx(m,ne({},y,{children:y.contentEditable?s.map(({content:b,before:S,after:C})=>`${S.children}${b.children}${C.children}`).join(""):v.jsx(I.Fragment,{children:s.map((b,S)=>v.jsx(l_,{slots:o,slotProps:i,element:b,classes:u},S))})}))});process.env.NODE_ENV!=="production"&&(c_.propTypes={classes:c.object,contentEditable:c.bool.isRequired,elements:c.arrayOf(c.shape({after:c.object.isRequired,before:c.object.isRequired,container:c.object.isRequired,content:c.object.isRequired})).isRequired,sectionListRef:c.oneOfType([c.func,c.shape({current:c.shape({getRoot:c.func.isRequired,getSectionContainer:c.func.isRequired,getSectionContent:c.func.isRequired,getSectionIndexFromDOMElement:c.func.isRequired})})]),slotProps:c.object,slots:c.object});const rH=["elements","areAllSectionsEmpty","defaultValue","label","value","onChange","id","autoFocus","endAdornment","startAdornment","renderSuffix","slots","slotProps","contentEditable","tabIndex","onInput","onPaste","onKeyDown","fullWidth","name","readOnly","inputProps","inputRef","sectionListRef"],oH=t=>Math.round(t*1e5)/1e5,Cd=be("div",{name:"MuiPickersInputBase",slot:"Root",overridesResolver:(t,e)=>e.root})(({theme:t})=>ne({},t.typography.body1,{color:(t.vars||t).palette.text.primary,cursor:"text",padding:0,display:"flex",justifyContent:"flex-start",alignItems:"center",position:"relative",boxSizing:"border-box",letterSpacing:`${oH(.15/16)}em`,variants:[{props:{fullWidth:!0},style:{width:"100%"}}]})),Vg=be(o_,{name:"MuiPickersInputBase",slot:"SectionsContainer",overridesResolver:(t,e)=>e.sectionsContainer})(({theme:t})=>({padding:"4px 0 5px",fontFamily:t.typography.fontFamily,fontSize:"inherit",lineHeight:"1.4375em",flexGrow:1,outline:"none",display:"flex",flexWrap:"nowrap",overflow:"hidden",letterSpacing:"inherit",width:"182px",variants:[{props:{isRtl:!0},style:{textAlign:"right /*! @noflip */"}},{props:{size:"small"},style:{paddingTop:1}},{props:{adornedStart:!1,focused:!1,filled:!1},style:{color:"currentColor",opacity:0}},{props:({adornedStart:e,focused:n,filled:r,label:o})=>!e&&!n&&!r&&o==null,style:t.vars?{opacity:t.vars.opacity.inputPlaceholder}:{opacity:t.palette.mode==="light"?.42:.5}}]})),iH=be(i_,{name:"MuiPickersInputBase",slot:"Section",overridesResolver:(t,e)=>e.section})(({theme:t})=>({fontFamily:t.typography.fontFamily,fontSize:"inherit",letterSpacing:"inherit",lineHeight:"1.4375em",display:"flex"})),sH=be(a_,{name:"MuiPickersInputBase",slot:"SectionContent",overridesResolver:(t,e)=>e.content})(({theme:t})=>({fontFamily:t.typography.fontFamily,lineHeight:"1.4375em",letterSpacing:"inherit",width:"fit-content",outline:"none"})),aH=be(s_,{name:"MuiPickersInputBase",slot:"Separator",overridesResolver:(t,e)=>e.separator})(()=>({whiteSpace:"pre",letterSpacing:"inherit"})),lH=be("input",{name:"MuiPickersInputBase",slot:"Input",overridesResolver:(t,e)=>e.hiddenInput})(ne({},r$)),cH=t=>{const{focused:e,disabled:n,error:r,classes:o,fullWidth:i,readOnly:s,color:a,size:l,endAdornment:u,startAdornment:f}=t,p={root:["root",e&&!n&&"focused",n&&"disabled",s&&"readOnly",r&&"error",i&&"fullWidth",`color${Ae(a)}`,l==="small"&&"inputSizeSmall",!!f&&"adornedStart",!!u&&"adornedEnd"],notchedOutline:["notchedOutline"],input:["input"],sectionsContainer:["sectionsContainer"],sectionContent:["sectionContent"],sectionBefore:["sectionBefore"],sectionAfter:["sectionAfter"]};return Ue(p,QV,o)},wd=I.forwardRef(function(e,n){const r=Wt({props:e,name:"MuiPickersInputBase"}),{elements:o,areAllSectionsEmpty:i,value:s,onChange:a,id:l,endAdornment:u,startAdornment:f,renderSuffix:p,slots:g,slotProps:m,contentEditable:y,tabIndex:b,onInput:S,onPaste:C,onKeyDown:T,name:_,readOnly:w,inputProps:E,inputRef:O,sectionListRef:L}=r,P=rt(r,rH),$=I.useRef(null),M=Et(n,$),A=Et(E==null?void 0:E.ref,O),N=no(),z=io();if(!z)throw new Error("MUI X: PickersInputBase should always be used inside a PickersTextField component");const V=Y=>{var Z;if(z.disabled){Y.stopPropagation();return}(Z=z.onFocus)==null||Z.call(z,Y)};I.useEffect(()=>{z&&z.setAdornedStart(!!f)},[z,f]),I.useEffect(()=>{z&&(i?z.onEmpty():z.onFilled())},[z,i]);const B=ne({},r,z,{isRtl:N}),R=cH(B),q=(g==null?void 0:g.root)||Cd,U=wt({elementType:q,externalSlotProps:m==null?void 0:m.root,externalForwardedProps:P,additionalProps:{"aria-invalid":z.error,ref:M},className:R.root,ownerState:B}),G=(g==null?void 0:g.input)||Vg;return v.jsxs(q,ne({},U,{children:[f,v.jsx(c_,{sectionListRef:L,elements:o,contentEditable:y,tabIndex:b,className:R.sectionsContainer,onFocus:V,onBlur:z.onBlur,onInput:S,onPaste:C,onKeyDown:T,slots:{root:G,section:iH,sectionContent:sH,sectionSeparator:aH},slotProps:{root:{ownerState:B},sectionContent:{className:Ca.sectionContent},sectionSeparator:({position:Y})=>({className:Y==="before"?Ca.sectionBefore:Ca.sectionAfter})}}),u,p?p(ne({},z)):null,v.jsx(lH,ne({name:_,className:R.input,value:s,onChange:a,id:l,"aria-hidden":"true",tabIndex:-1,readOnly:w,required:z.required,disabled:z.disabled},E,{ref:A}))]}))});process.env.NODE_ENV!=="production"&&(wd.propTypes={areAllSectionsEmpty:c.bool.isRequired,className:c.string,component:c.elementType,contentEditable:c.bool.isRequired,elements:c.arrayOf(c.shape({after:c.object.isRequired,before:c.object.isRequired,container:c.object.isRequired,content:c.object.isRequired})).isRequired,endAdornment:c.node,fullWidth:c.bool,id:c.string,inputProps:c.object,inputRef:mn,label:c.node,margin:c.oneOf(["dense","none","normal"]),name:c.string,onChange:c.func.isRequired,onClick:c.func.isRequired,onInput:c.func.isRequired,onKeyDown:c.func.isRequired,onPaste:c.func.isRequired,ownerState:c.any,readOnly:c.bool,renderSuffix:c.func,sectionListRef:c.oneOfType([c.func,c.shape({current:c.shape({getRoot:c.func.isRequired,getSectionContainer:c.func.isRequired,getSectionContent:c.func.isRequired,getSectionIndexFromDOMElement:c.func.isRequired})})]),slotProps:c.object,slots:c.object,startAdornment:c.node,style:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),value:c.string.isRequired});function uH(t){return Ke("MuiPickersOutlinedInput",t)}const so=ne({},Ca,qe("MuiPickersOutlinedInput",["root","notchedOutline","input"])),dH=["children","className","label","notched","shrink"],fH=be("fieldset",{name:"MuiPickersOutlinedInput",slot:"NotchedOutline",overridesResolver:(t,e)=>e.notchedOutline})(({theme:t})=>{const e=t.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return{textAlign:"left",position:"absolute",bottom:0,right:0,top:-5,left:0,margin:0,padding:"0 8px",pointerEvents:"none",borderRadius:"inherit",borderStyle:"solid",borderWidth:1,overflow:"hidden",minWidth:"0%",borderColor:t.vars?`rgba(${t.vars.palette.common.onBackgroundChannel} / 0.23)`:e}}),u_=be("span")(({theme:t})=>({fontFamily:t.typography.fontFamily,fontSize:"inherit"})),pH=be("legend")(({theme:t})=>({float:"unset",width:"auto",overflow:"hidden",variants:[{props:{withLabel:!1},style:{padding:0,lineHeight:"11px",transition:t.transitions.create("width",{duration:150,easing:t.transitions.easing.easeOut})}},{props:{withLabel:!0},style:{display:"block",padding:0,height:11,fontSize:"0.75em",visibility:"hidden",maxWidth:.01,transition:t.transitions.create("max-width",{duration:50,easing:t.transitions.easing.easeOut}),whiteSpace:"nowrap","& > span":{paddingLeft:5,paddingRight:5,display:"inline-block",opacity:0,visibility:"visible"}}},{props:{withLabel:!0,notched:!0},style:{maxWidth:"100%",transition:t.transitions.create("max-width",{duration:100,easing:t.transitions.easing.easeOut,delay:50})}}]}));function hH(t){const{className:e,label:n}=t,r=rt(t,dH),o=n!=null&&n!=="",i=ne({},t,{withLabel:o});return v.jsx(fH,ne({"aria-hidden":!0,className:e},r,{ownerState:i,children:v.jsx(pH,{ownerState:i,children:o?v.jsx(u_,{children:n}):v.jsx(u_,{className:"notranslate",children:""})})}))}const gH=["label","autoFocus","ownerState","notched"],mH=be(Cd,{name:"MuiPickersOutlinedInput",slot:"Root",overridesResolver:(t,e)=>e.root})(({theme:t})=>{const e=t.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return{padding:"0 14px",borderRadius:(t.vars||t).shape.borderRadius,[`&:hover .${so.notchedOutline}`]:{borderColor:(t.vars||t).palette.text.primary},"@media (hover: none)":{[`&:hover .${so.notchedOutline}`]:{borderColor:t.vars?`rgba(${t.vars.palette.common.onBackgroundChannel} / 0.23)`:e}},[`&.${so.focused} .${so.notchedOutline}`]:{borderStyle:"solid",borderWidth:2},[`&.${so.disabled}`]:{[`& .${so.notchedOutline}`]:{borderColor:(t.vars||t).palette.action.disabled},"*":{color:(t.vars||t).palette.action.disabled}},[`&.${so.error} .${so.notchedOutline}`]:{borderColor:(t.vars||t).palette.error.main},variants:Object.keys((t.vars??t).palette).filter(n=>{var r;return((r=(t.vars??t).palette[n])==null?void 0:r.main)??!1}).map(n=>({props:{color:n},style:{[`&.${so.focused}:not(.${so.error}) .${so.notchedOutline}`]:{borderColor:(t.vars||t).palette[n].main}}}))}}),yH=be(Vg,{name:"MuiPickersOutlinedInput",slot:"SectionsContainer",overridesResolver:(t,e)=>e.sectionsContainer})({padding:"16.5px 0",variants:[{props:{size:"small"},style:{padding:"8.5px 0"}}]}),bH=t=>{const{classes:e}=t,r=Ue({root:["root"],notchedOutline:["notchedOutline"],input:["input"]},uH,e);return ne({},e,r)},Hg=I.forwardRef(function(e,n){const r=Wt({props:e,name:"MuiPickersOutlinedInput"}),{label:o,ownerState:i,notched:s}=r,a=rt(r,gH),l=io(),u=ne({},r,i,l,{color:(l==null?void 0:l.color)||"primary"}),f=bH(u);return v.jsx(wd,ne({slots:{root:mH,input:yH},renderSuffix:p=>v.jsx(hH,{shrink:!!(s||p.adornedStart||p.focused||p.filled),notched:!!(s||p.adornedStart||p.focused||p.filled),className:f.notchedOutline,label:o!=null&&o!==""&&(l!=null&&l.required)?v.jsxs(I.Fragment,{children:[o," ","*"]}):o,ownerState:u})},a,{label:o,classes:f,ref:n}))});process.env.NODE_ENV!=="production"&&(Hg.propTypes={areAllSectionsEmpty:c.bool.isRequired,className:c.string,component:c.elementType,contentEditable:c.bool.isRequired,elements:c.arrayOf(c.shape({after:c.object.isRequired,before:c.object.isRequired,container:c.object.isRequired,content:c.object.isRequired})).isRequired,endAdornment:c.node,fullWidth:c.bool,id:c.string,inputProps:c.object,inputRef:mn,label:c.node,margin:c.oneOf(["dense","none","normal"]),name:c.string,notched:c.bool,onChange:c.func.isRequired,onClick:c.func.isRequired,onInput:c.func.isRequired,onKeyDown:c.func.isRequired,onPaste:c.func.isRequired,ownerState:c.any,readOnly:c.bool,renderSuffix:c.func,sectionListRef:c.oneOfType([c.func,c.shape({current:c.shape({getRoot:c.func.isRequired,getSectionContainer:c.func.isRequired,getSectionContent:c.func.isRequired,getSectionIndexFromDOMElement:c.func.isRequired})})]),slotProps:c.object,slots:c.object,startAdornment:c.node,style:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),value:c.string.isRequired}),Hg.muiName="Input";function vH(t){return Ke("MuiPickersFilledInput",t)}const ys=ne({},Ca,qe("MuiPickersFilledInput",["root","underline","input"])),xH=["label","autoFocus","disableUnderline","ownerState"],SH=be(Cd,{name:"MuiPickersFilledInput",slot:"Root",overridesResolver:(t,e)=>e.root,shouldForwardProp:t=>zu(t)&&t!=="disableUnderline"})(({theme:t})=>{const e=t.palette.mode==="light",n=e?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)",r=e?"rgba(0, 0, 0, 0.06)":"rgba(255, 255, 255, 0.09)",o=e?"rgba(0, 0, 0, 0.09)":"rgba(255, 255, 255, 0.13)",i=e?"rgba(0, 0, 0, 0.12)":"rgba(255, 255, 255, 0.12)";return{backgroundColor:t.vars?t.vars.palette.FilledInput.bg:r,borderTopLeftRadius:(t.vars||t).shape.borderRadius,borderTopRightRadius:(t.vars||t).shape.borderRadius,transition:t.transitions.create("background-color",{duration:t.transitions.duration.shorter,easing:t.transitions.easing.easeOut}),"&:hover":{backgroundColor:t.vars?t.vars.palette.FilledInput.hoverBg:o,"@media (hover: none)":{backgroundColor:t.vars?t.vars.palette.FilledInput.bg:r}},[`&.${ys.focused}`]:{backgroundColor:t.vars?t.vars.palette.FilledInput.bg:r},[`&.${ys.disabled}`]:{backgroundColor:t.vars?t.vars.palette.FilledInput.disabledBg:i},variants:[...Object.keys((t.vars??t).palette).filter(s=>(t.vars??t).palette[s].main).map(s=>{var a;return{props:{color:s,disableUnderline:!1},style:{"&::after":{borderBottom:`2px solid ${(a=(t.vars||t).palette[s])==null?void 0:a.main}`}}}}),{props:{disableUnderline:!1},style:{"&::after":{left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:t.transitions.create("transform",{duration:t.transitions.duration.shorter,easing:t.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${ys.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${ys.error}`]:{"&:before, &:after":{borderBottomColor:(t.vars||t).palette.error.main}},"&::before":{borderBottom:`1px solid ${t.vars?`rgba(${t.vars.palette.common.onBackgroundChannel} / ${t.vars.opacity.inputUnderline})`:n}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:t.transitions.create("border-bottom-color",{duration:t.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${ys.disabled}, .${ys.error}):before`]:{borderBottom:`1px solid ${(t.vars||t).palette.text.primary}`},[`&.${ys.disabled}:before`]:{borderBottomStyle:"dotted"}}},{props:({startAdornment:s})=>!!s,style:{paddingLeft:12}},{props:({endAdornment:s})=>!!s,style:{paddingRight:12}}]}}),CH=be(Vg,{name:"MuiPickersFilledInput",slot:"sectionsContainer",overridesResolver:(t,e)=>e.sectionsContainer})({paddingTop:25,paddingRight:12,paddingBottom:8,paddingLeft:12,variants:[{props:{size:"small"},style:{paddingTop:21,paddingBottom:4}},{props:({startAdornment:t})=>!!t,style:{paddingLeft:0}},{props:({endAdornment:t})=>!!t,style:{paddingRight:0}},{props:{hiddenLabel:!0},style:{paddingTop:16,paddingBottom:17}},{props:{hiddenLabel:!0,size:"small"},style:{paddingTop:8,paddingBottom:9}}]}),wH=t=>{const{classes:e,disableUnderline:n}=t,o=Ue({root:["root",!n&&"underline"],input:["input"]},vH,e);return ne({},e,o)},jg=I.forwardRef(function(e,n){const r=Wt({props:e,name:"MuiPickersFilledInput"}),{label:o,disableUnderline:i=!1,ownerState:s}=r,a=rt(r,xH),l=io(),u=ne({},r,s,l,{color:(l==null?void 0:l.color)||"primary"}),f=wH(u);return v.jsx(wd,ne({slots:{root:SH,input:CH},slotProps:{root:{disableUnderline:i}}},a,{label:o,classes:f,ref:n}))});process.env.NODE_ENV!=="production"&&(jg.propTypes={areAllSectionsEmpty:c.bool.isRequired,className:c.string,component:c.elementType,contentEditable:c.bool.isRequired,disableUnderline:c.bool,elements:c.arrayOf(c.shape({after:c.object.isRequired,before:c.object.isRequired,container:c.object.isRequired,content:c.object.isRequired})).isRequired,endAdornment:c.node,fullWidth:c.bool,hiddenLabel:c.bool,id:c.string,inputProps:c.object,inputRef:mn,label:c.node,margin:c.oneOf(["dense","none","normal"]),name:c.string,onChange:c.func.isRequired,onClick:c.func.isRequired,onInput:c.func.isRequired,onKeyDown:c.func.isRequired,onPaste:c.func.isRequired,ownerState:c.any,readOnly:c.bool,renderSuffix:c.func,sectionListRef:c.oneOfType([c.func,c.shape({current:c.shape({getRoot:c.func.isRequired,getSectionContainer:c.func.isRequired,getSectionContent:c.func.isRequired,getSectionIndexFromDOMElement:c.func.isRequired})})]),slotProps:c.object,slots:c.object,startAdornment:c.node,style:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),value:c.string.isRequired}),jg.muiName="Input";function _H(t){return Ke("MuiPickersFilledInput",t)}const tc=ne({},Ca,qe("MuiPickersInput",["root","input"])),TH=["label","autoFocus","disableUnderline","ownerState"],kH=be(Cd,{name:"MuiPickersInput",slot:"Root",overridesResolver:(t,e)=>e.root})(({theme:t})=>{let n=t.palette.mode==="light"?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)";return t.vars&&(n=`rgba(${t.vars.palette.common.onBackgroundChannel} / ${t.vars.opacity.inputUnderline})`),{"label + &":{marginTop:16},variants:[...Object.keys((t.vars??t).palette).filter(r=>(t.vars??t).palette[r].main).map(r=>({props:{color:r},style:{"&::after":{borderBottom:`2px solid ${(t.vars||t).palette[r].main}`}}})),{props:{disableUnderline:!1},style:{"&::after":{background:"red",left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:t.transitions.create("transform",{duration:t.transitions.duration.shorter,easing:t.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${tc.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${tc.error}`]:{"&:before, &:after":{borderBottomColor:(t.vars||t).palette.error.main}},"&::before":{borderBottom:`1px solid ${n}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:t.transitions.create("border-bottom-color",{duration:t.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${tc.disabled}, .${tc.error}):before`]:{borderBottom:`2px solid ${(t.vars||t).palette.text.primary}`,"@media (hover: none)":{borderBottom:`1px solid ${n}`}},[`&.${tc.disabled}:before`]:{borderBottomStyle:"dotted"}}}]}}),EH=t=>{const{classes:e,disableUnderline:n}=t,o=Ue({root:["root",!n&&"underline"],input:["input"]},_H,e);return ne({},e,o)},Wg=I.forwardRef(function(e,n){const r=Wt({props:e,name:"MuiPickersInput"}),{label:o,disableUnderline:i=!1,ownerState:s}=r,a=rt(r,TH),l=io(),u=ne({},r,s,l,{disableUnderline:i,color:(l==null?void 0:l.color)||"primary"}),f=EH(u);return v.jsx(wd,ne({slots:{root:kH}},a,{label:o,classes:f,ref:n}))});process.env.NODE_ENV!=="production"&&(Wg.propTypes={areAllSectionsEmpty:c.bool.isRequired,className:c.string,component:c.elementType,contentEditable:c.bool.isRequired,disableUnderline:c.bool,elements:c.arrayOf(c.shape({after:c.object.isRequired,before:c.object.isRequired,container:c.object.isRequired,content:c.object.isRequired})).isRequired,endAdornment:c.node,fullWidth:c.bool,id:c.string,inputProps:c.object,inputRef:mn,label:c.node,margin:c.oneOf(["dense","none","normal"]),name:c.string,onChange:c.func.isRequired,onClick:c.func.isRequired,onInput:c.func.isRequired,onKeyDown:c.func.isRequired,onPaste:c.func.isRequired,ownerState:c.any,readOnly:c.bool,renderSuffix:c.func,sectionListRef:c.oneOfType([c.func,c.shape({current:c.shape({getRoot:c.func.isRequired,getSectionContainer:c.func.isRequired,getSectionContent:c.func.isRequired,getSectionIndexFromDOMElement:c.func.isRequired})})]),slotProps:c.object,slots:c.object,startAdornment:c.node,style:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),value:c.string.isRequired}),Wg.muiName="Input";const MH=["onFocus","onBlur","className","color","disabled","error","variant","required","InputProps","inputProps","inputRef","sectionListRef","elements","areAllSectionsEmpty","onClick","onKeyDown","onKeyUp","onPaste","onInput","endAdornment","startAdornment","tabIndex","contentEditable","focused","value","onChange","fullWidth","id","name","helperText","FormHelperTextProps","label","InputLabelProps"],OH={standard:Wg,filled:jg,outlined:Hg},AH=be(ug,{name:"MuiPickersTextField",slot:"Root",overridesResolver:(t,e)=>e.root})({}),IH=t=>{const{focused:e,disabled:n,classes:r,required:o}=t;return Ue({root:["root",e&&!n&&"focused",n&&"disabled",o&&"required"]},XV,r)},d_=I.forwardRef(function(e,n){const r=Wt({props:e,name:"MuiPickersTextField"}),{onFocus:o,onBlur:i,className:s,color:a="primary",disabled:l=!1,error:u=!1,variant:f="outlined",required:p=!1,InputProps:g,inputProps:m,inputRef:y,sectionListRef:b,elements:S,areAllSectionsEmpty:C,onClick:T,onKeyDown:_,onKeyUp:w,onPaste:E,onInput:O,endAdornment:L,startAdornment:P,tabIndex:$,contentEditable:M,focused:A,value:N,onChange:z,fullWidth:V,id:B,name:R,helperText:q,FormHelperTextProps:U,label:G,InputLabelProps:Y}=r,Z=rt(r,MH),fe=I.useRef(null),pe=Et(n,fe),me=vo(B),re=q&&me?`${me}-helper-text`:void 0,he=G&&me?`${me}-label`:void 0,le=ne({},r,{color:a,disabled:l,error:u,focused:A,required:p,variant:f}),X=IH(le),W=OH[f];return v.jsxs(AH,ne({className:Le(X.root,s),ref:pe,focused:A,onFocus:o,onBlur:i,disabled:l,variant:f,error:u,color:a,fullWidth:V,required:p,ownerState:le},Z,{children:[v.jsx(cg,ne({htmlFor:me,id:he},Y,{children:G})),v.jsx(W,ne({elements:S,areAllSectionsEmpty:C,onClick:T,onKeyDown:_,onKeyUp:w,onInput:O,onPaste:E,endAdornment:L,startAdornment:P,tabIndex:$,contentEditable:M,value:N,onChange:z,id:me,fullWidth:V,inputProps:m,inputRef:y,sectionListRef:b,label:G,name:R,role:"group","aria-labelledby":he},g)),q&&v.jsx(dg,ne({id:re},U,{children:q}))]}))});process.env.NODE_ENV!=="production"&&(d_.propTypes={areAllSectionsEmpty:c.bool.isRequired,className:c.string,color:c.oneOf(["error","info","primary","secondary","success","warning"]),component:c.elementType,contentEditable:c.bool.isRequired,disabled:c.bool.isRequired,elements:c.arrayOf(c.shape({after:c.object.isRequired,before:c.object.isRequired,container:c.object.isRequired,content:c.object.isRequired})).isRequired,endAdornment:c.node,error:c.bool.isRequired,focused:c.bool,FormHelperTextProps:c.object,fullWidth:c.bool,helperText:c.node,hiddenLabel:c.bool,id:c.string,InputLabelProps:c.object,inputProps:c.object,InputProps:c.object,inputRef:mn,label:c.node,margin:c.oneOf(["dense","none","normal"]),name:c.string,onBlur:c.func.isRequired,onChange:c.func.isRequired,onClick:c.func.isRequired,onFocus:c.func.isRequired,onInput:c.func.isRequired,onKeyDown:c.func.isRequired,onPaste:c.func.isRequired,readOnly:c.bool,required:c.bool,sectionListRef:c.oneOfType([c.func,c.shape({current:c.shape({getRoot:c.func.isRequired,getSectionContainer:c.func.isRequired,getSectionContent:c.func.isRequired,getSectionIndexFromDOMElement:c.func.isRequired})})]),size:c.oneOf(["medium","small"]),startAdornment:c.node,style:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),value:c.string.isRequired,variant:c.oneOf(["filled","outlined","standard"])});const DH=["enableAccessibleFieldDOMStructure"],PH=["InputProps","readOnly"],NH=["onPaste","onKeyDown","inputMode","readOnly","InputProps","inputProps","inputRef"],LH=t=>{let{enableAccessibleFieldDOMStructure:e}=t,n=rt(t,DH);if(e){const{InputProps:p,readOnly:g}=n,m=rt(n,PH);return ne({},m,{InputProps:ne({},p??{},{readOnly:g})})}const{onPaste:r,onKeyDown:o,inputMode:i,readOnly:s,InputProps:a,inputProps:l,inputRef:u}=n,f=rt(n,NH);return ne({},f,{InputProps:ne({},a??{},{readOnly:s}),inputProps:ne({},l??{},{inputMode:i,onPaste:r,onKeyDown:o,ref:u})})},FH=["slots","slotProps","InputProps","inputProps"],_d=I.forwardRef(function(e,n){const r=Wt({props:e,name:"MuiDateField"}),{slots:o,slotProps:i,InputProps:s,inputProps:a}=r,l=rt(r,FH),u=r,f=(o==null?void 0:o.textField)??(e.enableAccessibleFieldDOMStructure?d_:Ow),p=wt({elementType:f,externalSlotProps:i==null?void 0:i.textField,externalForwardedProps:l,additionalProps:{ref:n},ownerState:u});p.inputProps=ne({},a,p.inputProps),p.InputProps=ne({},s,p.InputProps);const g=ZV(p),m=LH(g),y=UV(ne({},m,{slots:o,slotProps:i}));return v.jsx(f,ne({},y))});process.env.NODE_ENV!=="production"&&(_d.propTypes={autoFocus:c.bool,className:c.string,clearable:c.bool,color:c.oneOf(["error","info","primary","secondary","success","warning"]),component:c.elementType,defaultValue:c.object,disabled:c.bool,disableFuture:c.bool,disablePast:c.bool,enableAccessibleFieldDOMStructure:c.bool,focused:c.bool,format:c.string,formatDensity:c.oneOf(["dense","spacious"]),FormHelperTextProps:c.object,fullWidth:c.bool,helperText:c.node,hiddenLabel:c.bool,id:c.string,InputLabelProps:c.object,inputProps:c.object,InputProps:c.object,inputRef:mn,label:c.node,margin:c.oneOf(["dense","none","normal"]),maxDate:c.object,minDate:c.object,name:c.string,onBlur:c.func,onChange:c.func,onClear:c.func,onError:c.func,onFocus:c.func,onSelectedSectionsChange:c.func,readOnly:c.bool,referenceDate:c.object,required:c.bool,selectedSections:c.oneOfType([c.oneOf(["all","day","empty","hours","meridiem","minutes","month","seconds","weekDay","year"]),c.number]),shouldDisableDate:c.func,shouldDisableMonth:c.func,shouldDisableYear:c.func,shouldRespectLeadingZeros:c.bool,size:c.oneOf(["medium","small"]),slotProps:c.object,slots:c.object,style:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),timezone:c.string,unstableFieldRef:c.oneOfType([c.func,c.object]),value:c.object,variant:c.oneOf(["filled","outlined","standard"])});var Td={exports:{}},$H=Td.exports,f_;function BH(){return f_||(f_=1,function(t,e){(function(n,r){t.exports=r()})($H,function(){var n="minute",r=/[+-]\d\d(?::?\d\d)?/g,o=/([+-]|\d\d)/g;return function(i,s,a){var l=s.prototype;a.utc=function(b){var S={date:b,utc:!0,args:arguments};return new s(S)},l.utc=function(b){var S=a(this.toDate(),{locale:this.$L,utc:!0});return b?S.add(this.utcOffset(),n):S},l.local=function(){return a(this.toDate(),{locale:this.$L,utc:!1})};var u=l.parse;l.parse=function(b){b.utc&&(this.$u=!0),this.$utils().u(b.$offset)||(this.$offset=b.$offset),u.call(this,b)};var f=l.init;l.init=function(){if(this.$u){var b=this.$d;this.$y=b.getUTCFullYear(),this.$M=b.getUTCMonth(),this.$D=b.getUTCDate(),this.$W=b.getUTCDay(),this.$H=b.getUTCHours(),this.$m=b.getUTCMinutes(),this.$s=b.getUTCSeconds(),this.$ms=b.getUTCMilliseconds()}else f.call(this)};var p=l.utcOffset;l.utcOffset=function(b,S){var C=this.$utils().u;if(C(b))return this.$u?0:C(this.$offset)?p.call(this):this.$offset;if(typeof b=="string"&&(b=function(E){E===void 0&&(E="");var O=E.match(r);if(!O)return null;var L=(""+O[0]).match(o)||["-",0,0],P=L[0],$=60*+L[1]+ +L[2];return $===0?0:P==="+"?$:-$}(b),b===null))return this;var T=Math.abs(b)<=16?60*b:b,_=this;if(S)return _.$offset=T,_.$u=b===0,_;if(b!==0){var w=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();(_=this.local().add(T+w,n)).$offset=T,_.$x.$localOffset=w}else _=this.utc();return _};var g=l.format;l.format=function(b){var S=b||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return g.call(this,S)},l.valueOf=function(){var b=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*b},l.isUTC=function(){return!!this.$u},l.toISOString=function(){return this.toDate().toISOString()},l.toString=function(){return this.toDate().toUTCString()};var m=l.toDate;l.toDate=function(b){return b==="s"&&this.$offset?a(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():m.call(this)};var y=l.diff;l.diff=function(b,S,C){if(b&&this.$u===b.$u)return y.call(this,b,S,C);var T=this.local(),_=a(b).local();return y.call(T,_,S,C)}}})}(Td)),Td.exports}var RH=BH();const zH=Zn(RH);pn.extend(zH);const p_=A5({themeId:Pl});function VH(t){return Ke("MuiPickersToolbar",t)}qe("MuiPickersToolbar",["root","content"]);const HH=["children","className","toolbarTitle","hidden","titleId","isLandscape","classes","landscapeDirection"],jH=t=>{const{classes:e}=t;return Ue({root:["root"],content:["content"]},VH,e)},WH=be("div",{name:"MuiPickersToolbar",slot:"Root",overridesResolver:(t,e)=>e.root})(({theme:t})=>({display:"flex",flexDirection:"column",alignItems:"flex-start",justifyContent:"space-between",padding:t.spacing(2,3),variants:[{props:{isLandscape:!0},style:{height:"auto",maxWidth:160,padding:16,justifyContent:"flex-start",flexWrap:"wrap"}}]})),qH=be("div",{name:"MuiPickersToolbar",slot:"Content",overridesResolver:(t,e)=>e.content})({display:"flex",flexWrap:"wrap",width:"100%",flex:1,justifyContent:"space-between",alignItems:"center",flexDirection:"row",variants:[{props:{isLandscape:!0},style:{justifyContent:"flex-start",alignItems:"flex-start",flexDirection:"column"}},{props:{isLandscape:!0,landscapeDirection:"row"},style:{flexDirection:"row"}}]}),UH=I.forwardRef(function(e,n){const r=Wt({props:e,name:"MuiPickersToolbar"}),{children:o,className:i,toolbarTitle:s,hidden:a,titleId:l}=r,u=rt(r,HH),f=r,p=jH(f);return a?null:v.jsxs(WH,ne({ref:n,className:Le(p.root,i),ownerState:f},u,{children:[v.jsx(Ti,{color:"text.secondary",variant:"overline",id:l,children:s}),v.jsx(qH,{className:p.content,ownerState:f,children:o})]}))});function KH(t){return Ke("MuiDatePickerToolbar",t)}qe("MuiDatePickerToolbar",["root","title"]);const YH=["value","isLandscape","onChange","toolbarFormat","toolbarPlaceholder","views","className","onViewChange","view"],GH=t=>{const{classes:e}=t;return Ue({root:["root"],title:["title"]},KH,e)},JH=be(UH,{name:"MuiDatePickerToolbar",slot:"Root",overridesResolver:(t,e)=>e.root})({}),ZH=be(Ti,{name:"MuiDatePickerToolbar",slot:"Title",overridesResolver:(t,e)=>e.title})({variants:[{props:{isLandscape:!0},style:{margin:"auto 16px auto auto"}}]}),h_=I.forwardRef(function(e,n){const r=Wt({props:e,name:"MuiDatePickerToolbar"}),{value:o,isLandscape:i,toolbarFormat:s,toolbarPlaceholder:a="––",views:l,className:u}=r,f=rt(r,YH),p=qt(),g=Ko(),m=GH(r),y=I.useMemo(()=>{if(!o)return a;const S=Og(p,{format:s,views:l},!0);return p.formatByString(o,S)},[o,s,a,p,l]),b=r;return v.jsx(JH,ne({ref:n,toolbarTitle:g.datePickerToolbarTitle,isLandscape:i,className:Le(m.root,u)},f,{children:v.jsx(ZH,{variant:"h4",align:i?"left":"center",ownerState:b,className:m.title,children:y})}))});process.env.NODE_ENV!=="production"&&(h_.propTypes={classes:c.object,className:c.string,disabled:c.bool,hidden:c.bool,isLandscape:c.bool.isRequired,onChange:c.func.isRequired,onViewChange:c.func.isRequired,readOnly:c.bool,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),titleId:c.string,toolbarFormat:c.string,toolbarPlaceholder:c.node,value:c.object,view:c.oneOf(["day","month","year"]).isRequired,views:c.arrayOf(c.oneOf(["day","month","year"]).isRequired).isRequired});function g_(t,e){const n=qt(),r=Ql(),o=Wt({props:t,name:e}),i=I.useMemo(()=>{var s;return((s=o.localeText)==null?void 0:s.toolbarTitle)==null?o.localeText:ne({},o.localeText,{datePickerToolbarTitle:o.localeText.toolbarTitle})},[o.localeText]);return ne({},o,{localeText:i},g4({views:o.views,openTo:o.openTo,defaultViews:["year","day"],defaultOpenTo:"day"}),{disableFuture:o.disableFuture??!1,disablePast:o.disablePast??!1,minDate:Nr(n,o.minDate,r.minDate),maxDate:Nr(n,o.maxDate,r.maxDate),slots:ne({toolbar:h_},o.slots)})}var ar="top",Fr="bottom",$r="right",lr="left",qg="auto",nc=[ar,Fr,$r,lr],wa="start",rc="end",XH="clippingParents",m_="viewport",oc="popper",QH="reference",y_=nc.reduce(function(t,e){return t.concat([e+"-"+wa,e+"-"+rc])},[]),b_=[].concat(nc,[qg]).reduce(function(t,e){return t.concat([e,e+"-"+wa,e+"-"+rc])},[]),e6="beforeRead",t6="read",n6="afterRead",r6="beforeMain",o6="main",i6="afterMain",s6="beforeWrite",a6="write",l6="afterWrite",c6=[e6,t6,n6,r6,o6,i6,s6,a6,l6];function _o(t){return t?(t.nodeName||"").toLowerCase():null}function Sr(t){if(t==null)return window;if(t.toString()!=="[object Window]"){var e=t.ownerDocument;return e&&e.defaultView||window}return t}function bs(t){var e=Sr(t).Element;return t instanceof e||t instanceof Element}function Br(t){var e=Sr(t).HTMLElement;return t instanceof e||t instanceof HTMLElement}function Ug(t){if(typeof ShadowRoot>"u")return!1;var e=Sr(t).ShadowRoot;return t instanceof e||t instanceof ShadowRoot}function u6(t){var e=t.state;Object.keys(e.elements).forEach(function(n){var r=e.styles[n]||{},o=e.attributes[n]||{},i=e.elements[n];!Br(i)||!_o(i)||(Object.assign(i.style,r),Object.keys(o).forEach(function(s){var a=o[s];a===!1?i.removeAttribute(s):i.setAttribute(s,a===!0?"":a)}))})}function d6(t){var e=t.state,n={popper:{position:e.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(e.elements.popper.style,n.popper),e.styles=n,e.elements.arrow&&Object.assign(e.elements.arrow.style,n.arrow),function(){Object.keys(e.elements).forEach(function(r){var o=e.elements[r],i=e.attributes[r]||{},s=Object.keys(e.styles.hasOwnProperty(r)?e.styles[r]:n[r]),a=s.reduce(function(l,u){return l[u]="",l},{});!Br(o)||!_o(o)||(Object.assign(o.style,a),Object.keys(i).forEach(function(l){o.removeAttribute(l)}))})}}const v_={name:"applyStyles",enabled:!0,phase:"write",fn:u6,effect:d6,requires:["computeStyles"]};function To(t){return t.split("-")[0]}var vs=Math.max,kd=Math.min,_a=Math.round;function Kg(){var t=navigator.userAgentData;return t!=null&&t.brands&&Array.isArray(t.brands)?t.brands.map(function(e){return e.brand+"/"+e.version}).join(" "):navigator.userAgent}function x_(){return!/^((?!chrome|android).)*safari/i.test(Kg())}function Ta(t,e,n){e===void 0&&(e=!1),n===void 0&&(n=!1);var r=t.getBoundingClientRect(),o=1,i=1;e&&Br(t)&&(o=t.offsetWidth>0&&_a(r.width)/t.offsetWidth||1,i=t.offsetHeight>0&&_a(r.height)/t.offsetHeight||1);var s=bs(t)?Sr(t):window,a=s.visualViewport,l=!x_()&&n,u=(r.left+(l&&a?a.offsetLeft:0))/o,f=(r.top+(l&&a?a.offsetTop:0))/i,p=r.width/o,g=r.height/i;return{width:p,height:g,top:f,right:u+p,bottom:f+g,left:u,x:u,y:f}}function Yg(t){var e=Ta(t),n=t.offsetWidth,r=t.offsetHeight;return Math.abs(e.width-n)<=1&&(n=e.width),Math.abs(e.height-r)<=1&&(r=e.height),{x:t.offsetLeft,y:t.offsetTop,width:n,height:r}}function S_(t,e){var n=e.getRootNode&&e.getRootNode();if(t.contains(e))return!0;if(n&&Ug(n)){var r=e;do{if(r&&t.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function Go(t){return Sr(t).getComputedStyle(t)}function f6(t){return["table","td","th"].indexOf(_o(t))>=0}function ki(t){return((bs(t)?t.ownerDocument:t.document)||window.document).documentElement}function Ed(t){return _o(t)==="html"?t:t.assignedSlot||t.parentNode||(Ug(t)?t.host:null)||ki(t)}function C_(t){return!Br(t)||Go(t).position==="fixed"?null:t.offsetParent}function p6(t){var e=/firefox/i.test(Kg()),n=/Trident/i.test(Kg());if(n&&Br(t)){var r=Go(t);if(r.position==="fixed")return null}var o=Ed(t);for(Ug(o)&&(o=o.host);Br(o)&&["html","body"].indexOf(_o(o))<0;){var i=Go(o);if(i.transform!=="none"||i.perspective!=="none"||i.contain==="paint"||["transform","perspective"].indexOf(i.willChange)!==-1||e&&i.willChange==="filter"||e&&i.filter&&i.filter!=="none")return o;o=o.parentNode}return null}function ic(t){for(var e=Sr(t),n=C_(t);n&&f6(n)&&Go(n).position==="static";)n=C_(n);return n&&(_o(n)==="html"||_o(n)==="body"&&Go(n).position==="static")?e:n||p6(t)||e}function Gg(t){return["top","bottom"].indexOf(t)>=0?"x":"y"}function sc(t,e,n){return vs(t,kd(e,n))}function h6(t,e,n){var r=sc(t,e,n);return r>n?n:r}function w_(){return{top:0,right:0,bottom:0,left:0}}function __(t){return Object.assign({},w_(),t)}function T_(t,e){return e.reduce(function(n,r){return n[r]=t,n},{})}var g6=function(e,n){return e=typeof e=="function"?e(Object.assign({},n.rects,{placement:n.placement})):e,__(typeof e!="number"?e:T_(e,nc))};function m6(t){var e,n=t.state,r=t.name,o=t.options,i=n.elements.arrow,s=n.modifiersData.popperOffsets,a=To(n.placement),l=Gg(a),u=[lr,$r].indexOf(a)>=0,f=u?"height":"width";if(!(!i||!s)){var p=g6(o.padding,n),g=Yg(i),m=l==="y"?ar:lr,y=l==="y"?Fr:$r,b=n.rects.reference[f]+n.rects.reference[l]-s[l]-n.rects.popper[f],S=s[l]-n.rects.reference[l],C=ic(i),T=C?l==="y"?C.clientHeight||0:C.clientWidth||0:0,_=b/2-S/2,w=p[m],E=T-g[f]-p[y],O=T/2-g[f]/2+_,L=sc(w,O,E),P=l;n.modifiersData[r]=(e={},e[P]=L,e.centerOffset=L-O,e)}}function y6(t){var e=t.state,n=t.options,r=n.element,o=r===void 0?"[data-popper-arrow]":r;o!=null&&(typeof o=="string"&&(o=e.elements.popper.querySelector(o),!o)||S_(e.elements.popper,o)&&(e.elements.arrow=o))}const b6={name:"arrow",enabled:!0,phase:"main",fn:m6,effect:y6,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function ka(t){return t.split("-")[1]}var v6={top:"auto",right:"auto",bottom:"auto",left:"auto"};function x6(t,e){var n=t.x,r=t.y,o=e.devicePixelRatio||1;return{x:_a(n*o)/o||0,y:_a(r*o)/o||0}}function k_(t){var e,n=t.popper,r=t.popperRect,o=t.placement,i=t.variation,s=t.offsets,a=t.position,l=t.gpuAcceleration,u=t.adaptive,f=t.roundOffsets,p=t.isFixed,g=s.x,m=g===void 0?0:g,y=s.y,b=y===void 0?0:y,S=typeof f=="function"?f({x:m,y:b}):{x:m,y:b};m=S.x,b=S.y;var C=s.hasOwnProperty("x"),T=s.hasOwnProperty("y"),_=lr,w=ar,E=window;if(u){var O=ic(n),L="clientHeight",P="clientWidth";if(O===Sr(n)&&(O=ki(n),Go(O).position!=="static"&&a==="absolute"&&(L="scrollHeight",P="scrollWidth")),O=O,o===ar||(o===lr||o===$r)&&i===rc){w=Fr;var $=p&&O===E&&E.visualViewport?E.visualViewport.height:O[L];b-=$-r.height,b*=l?1:-1}if(o===lr||(o===ar||o===Fr)&&i===rc){_=$r;var M=p&&O===E&&E.visualViewport?E.visualViewport.width:O[P];m-=M-r.width,m*=l?1:-1}}var A=Object.assign({position:a},u&&v6),N=f===!0?x6({x:m,y:b},Sr(n)):{x:m,y:b};if(m=N.x,b=N.y,l){var z;return Object.assign({},A,(z={},z[w]=T?"0":"",z[_]=C?"0":"",z.transform=(E.devicePixelRatio||1)<=1?"translate("+m+"px, "+b+"px)":"translate3d("+m+"px, "+b+"px, 0)",z))}return Object.assign({},A,(e={},e[w]=T?b+"px":"",e[_]=C?m+"px":"",e.transform="",e))}function S6(t){var e=t.state,n=t.options,r=n.gpuAcceleration,o=r===void 0?!0:r,i=n.adaptive,s=i===void 0?!0:i,a=n.roundOffsets,l=a===void 0?!0:a,u={placement:To(e.placement),variation:ka(e.placement),popper:e.elements.popper,popperRect:e.rects.popper,gpuAcceleration:o,isFixed:e.options.strategy==="fixed"};e.modifiersData.popperOffsets!=null&&(e.styles.popper=Object.assign({},e.styles.popper,k_(Object.assign({},u,{offsets:e.modifiersData.popperOffsets,position:e.options.strategy,adaptive:s,roundOffsets:l})))),e.modifiersData.arrow!=null&&(e.styles.arrow=Object.assign({},e.styles.arrow,k_(Object.assign({},u,{offsets:e.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),e.attributes.popper=Object.assign({},e.attributes.popper,{"data-popper-placement":e.placement})}const C6={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:S6,data:{}};var Md={passive:!0};function w6(t){var e=t.state,n=t.instance,r=t.options,o=r.scroll,i=o===void 0?!0:o,s=r.resize,a=s===void 0?!0:s,l=Sr(e.elements.popper),u=[].concat(e.scrollParents.reference,e.scrollParents.popper);return i&&u.forEach(function(f){f.addEventListener("scroll",n.update,Md)}),a&&l.addEventListener("resize",n.update,Md),function(){i&&u.forEach(function(f){f.removeEventListener("scroll",n.update,Md)}),a&&l.removeEventListener("resize",n.update,Md)}}const _6={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:w6,data:{}};var T6={left:"right",right:"left",bottom:"top",top:"bottom"};function Od(t){return t.replace(/left|right|bottom|top/g,function(e){return T6[e]})}var k6={start:"end",end:"start"};function E_(t){return t.replace(/start|end/g,function(e){return k6[e]})}function Jg(t){var e=Sr(t),n=e.pageXOffset,r=e.pageYOffset;return{scrollLeft:n,scrollTop:r}}function Zg(t){return Ta(ki(t)).left+Jg(t).scrollLeft}function E6(t,e){var n=Sr(t),r=ki(t),o=n.visualViewport,i=r.clientWidth,s=r.clientHeight,a=0,l=0;if(o){i=o.width,s=o.height;var u=x_();(u||!u&&e==="fixed")&&(a=o.offsetLeft,l=o.offsetTop)}return{width:i,height:s,x:a+Zg(t),y:l}}function M6(t){var e,n=ki(t),r=Jg(t),o=(e=t.ownerDocument)==null?void 0:e.body,i=vs(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),s=vs(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),a=-r.scrollLeft+Zg(t),l=-r.scrollTop;return Go(o||n).direction==="rtl"&&(a+=vs(n.clientWidth,o?o.clientWidth:0)-i),{width:i,height:s,x:a,y:l}}function Xg(t){var e=Go(t),n=e.overflow,r=e.overflowX,o=e.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+r)}function M_(t){return["html","body","#document"].indexOf(_o(t))>=0?t.ownerDocument.body:Br(t)&&Xg(t)?t:M_(Ed(t))}function ac(t,e){var n;e===void 0&&(e=[]);var r=M_(t),o=r===((n=t.ownerDocument)==null?void 0:n.body),i=Sr(r),s=o?[i].concat(i.visualViewport||[],Xg(r)?r:[]):r,a=e.concat(s);return o?a:a.concat(ac(Ed(s)))}function Qg(t){return Object.assign({},t,{left:t.x,top:t.y,right:t.x+t.width,bottom:t.y+t.height})}function O6(t,e){var n=Ta(t,!1,e==="fixed");return n.top=n.top+t.clientTop,n.left=n.left+t.clientLeft,n.bottom=n.top+t.clientHeight,n.right=n.left+t.clientWidth,n.width=t.clientWidth,n.height=t.clientHeight,n.x=n.left,n.y=n.top,n}function O_(t,e,n){return e===m_?Qg(E6(t,n)):bs(e)?O6(e,n):Qg(M6(ki(t)))}function A6(t){var e=ac(Ed(t)),n=["absolute","fixed"].indexOf(Go(t).position)>=0,r=n&&Br(t)?ic(t):t;return bs(r)?e.filter(function(o){return bs(o)&&S_(o,r)&&_o(o)!=="body"}):[]}function I6(t,e,n,r){var o=e==="clippingParents"?A6(t):[].concat(e),i=[].concat(o,[n]),s=i[0],a=i.reduce(function(l,u){var f=O_(t,u,r);return l.top=vs(f.top,l.top),l.right=kd(f.right,l.right),l.bottom=kd(f.bottom,l.bottom),l.left=vs(f.left,l.left),l},O_(t,s,r));return a.width=a.right-a.left,a.height=a.bottom-a.top,a.x=a.left,a.y=a.top,a}function A_(t){var e=t.reference,n=t.element,r=t.placement,o=r?To(r):null,i=r?ka(r):null,s=e.x+e.width/2-n.width/2,a=e.y+e.height/2-n.height/2,l;switch(o){case ar:l={x:s,y:e.y-n.height};break;case Fr:l={x:s,y:e.y+e.height};break;case $r:l={x:e.x+e.width,y:a};break;case lr:l={x:e.x-n.width,y:a};break;default:l={x:e.x,y:e.y}}var u=o?Gg(o):null;if(u!=null){var f=u==="y"?"height":"width";switch(i){case wa:l[u]=l[u]-(e[f]/2-n[f]/2);break;case rc:l[u]=l[u]+(e[f]/2-n[f]/2);break}}return l}function lc(t,e){e===void 0&&(e={});var n=e,r=n.placement,o=r===void 0?t.placement:r,i=n.strategy,s=i===void 0?t.strategy:i,a=n.boundary,l=a===void 0?XH:a,u=n.rootBoundary,f=u===void 0?m_:u,p=n.elementContext,g=p===void 0?oc:p,m=n.altBoundary,y=m===void 0?!1:m,b=n.padding,S=b===void 0?0:b,C=__(typeof S!="number"?S:T_(S,nc)),T=g===oc?QH:oc,_=t.rects.popper,w=t.elements[y?T:g],E=I6(bs(w)?w:w.contextElement||ki(t.elements.popper),l,f,s),O=Ta(t.elements.reference),L=A_({reference:O,element:_,strategy:"absolute",placement:o}),P=Qg(Object.assign({},_,L)),$=g===oc?P:O,M={top:E.top-$.top+C.top,bottom:$.bottom-E.bottom+C.bottom,left:E.left-$.left+C.left,right:$.right-E.right+C.right},A=t.modifiersData.offset;if(g===oc&&A){var N=A[o];Object.keys(M).forEach(function(z){var V=[$r,Fr].indexOf(z)>=0?1:-1,B=[ar,Fr].indexOf(z)>=0?"y":"x";M[z]+=N[B]*V})}return M}function D6(t,e){e===void 0&&(e={});var n=e,r=n.placement,o=n.boundary,i=n.rootBoundary,s=n.padding,a=n.flipVariations,l=n.allowedAutoPlacements,u=l===void 0?b_:l,f=ka(r),p=f?a?y_:y_.filter(function(y){return ka(y)===f}):nc,g=p.filter(function(y){return u.indexOf(y)>=0});g.length===0&&(g=p);var m=g.reduce(function(y,b){return y[b]=lc(t,{placement:b,boundary:o,rootBoundary:i,padding:s})[To(b)],y},{});return Object.keys(m).sort(function(y,b){return m[y]-m[b]})}function P6(t){if(To(t)===qg)return[];var e=Od(t);return[E_(t),e,E_(e)]}function N6(t){var e=t.state,n=t.options,r=t.name;if(!e.modifiersData[r]._skip){for(var o=n.mainAxis,i=o===void 0?!0:o,s=n.altAxis,a=s===void 0?!0:s,l=n.fallbackPlacements,u=n.padding,f=n.boundary,p=n.rootBoundary,g=n.altBoundary,m=n.flipVariations,y=m===void 0?!0:m,b=n.allowedAutoPlacements,S=e.options.placement,C=To(S),T=C===S,_=l||(T||!y?[Od(S)]:P6(S)),w=[S].concat(_).reduce(function(me,re){return me.concat(To(re)===qg?D6(e,{placement:re,boundary:f,rootBoundary:p,padding:u,flipVariations:y,allowedAutoPlacements:b}):re)},[]),E=e.rects.reference,O=e.rects.popper,L=new Map,P=!0,$=w[0],M=0;M<w.length;M++){var A=w[M],N=To(A),z=ka(A)===wa,V=[ar,Fr].indexOf(N)>=0,B=V?"width":"height",R=lc(e,{placement:A,boundary:f,rootBoundary:p,altBoundary:g,padding:u}),q=V?z?$r:lr:z?Fr:ar;E[B]>O[B]&&(q=Od(q));var U=Od(q),G=[];if(i&&G.push(R[N]<=0),a&&G.push(R[q]<=0,R[U]<=0),G.every(function(me){return me})){$=A,P=!1;break}L.set(A,G)}if(P)for(var Y=y?3:1,Z=function(re){var he=w.find(function(le){var X=L.get(le);if(X)return X.slice(0,re).every(function(W){return W})});if(he)return $=he,"break"},fe=Y;fe>0;fe--){var pe=Z(fe);if(pe==="break")break}e.placement!==$&&(e.modifiersData[r]._skip=!0,e.placement=$,e.reset=!0)}}const L6={name:"flip",enabled:!0,phase:"main",fn:N6,requiresIfExists:["offset"],data:{_skip:!1}};function I_(t,e,n){return n===void 0&&(n={x:0,y:0}),{top:t.top-e.height-n.y,right:t.right-e.width+n.x,bottom:t.bottom-e.height+n.y,left:t.left-e.width-n.x}}function D_(t){return[ar,$r,Fr,lr].some(function(e){return t[e]>=0})}function F6(t){var e=t.state,n=t.name,r=e.rects.reference,o=e.rects.popper,i=e.modifiersData.preventOverflow,s=lc(e,{elementContext:"reference"}),a=lc(e,{altBoundary:!0}),l=I_(s,r),u=I_(a,o,i),f=D_(l),p=D_(u);e.modifiersData[n]={referenceClippingOffsets:l,popperEscapeOffsets:u,isReferenceHidden:f,hasPopperEscaped:p},e.attributes.popper=Object.assign({},e.attributes.popper,{"data-popper-reference-hidden":f,"data-popper-escaped":p})}const $6={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:F6};function B6(t,e,n){var r=To(t),o=[lr,ar].indexOf(r)>=0?-1:1,i=typeof n=="function"?n(Object.assign({},e,{placement:t})):n,s=i[0],a=i[1];return s=s||0,a=(a||0)*o,[lr,$r].indexOf(r)>=0?{x:a,y:s}:{x:s,y:a}}function R6(t){var e=t.state,n=t.options,r=t.name,o=n.offset,i=o===void 0?[0,0]:o,s=b_.reduce(function(f,p){return f[p]=B6(p,e.rects,i),f},{}),a=s[e.placement],l=a.x,u=a.y;e.modifiersData.popperOffsets!=null&&(e.modifiersData.popperOffsets.x+=l,e.modifiersData.popperOffsets.y+=u),e.modifiersData[r]=s}const z6={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:R6};function V6(t){var e=t.state,n=t.name;e.modifiersData[n]=A_({reference:e.rects.reference,element:e.rects.popper,strategy:"absolute",placement:e.placement})}const H6={name:"popperOffsets",enabled:!0,phase:"read",fn:V6,data:{}};function j6(t){return t==="x"?"y":"x"}function W6(t){var e=t.state,n=t.options,r=t.name,o=n.mainAxis,i=o===void 0?!0:o,s=n.altAxis,a=s===void 0?!1:s,l=n.boundary,u=n.rootBoundary,f=n.altBoundary,p=n.padding,g=n.tether,m=g===void 0?!0:g,y=n.tetherOffset,b=y===void 0?0:y,S=lc(e,{boundary:l,rootBoundary:u,padding:p,altBoundary:f}),C=To(e.placement),T=ka(e.placement),_=!T,w=Gg(C),E=j6(w),O=e.modifiersData.popperOffsets,L=e.rects.reference,P=e.rects.popper,$=typeof b=="function"?b(Object.assign({},e.rects,{placement:e.placement})):b,M=typeof $=="number"?{mainAxis:$,altAxis:$}:Object.assign({mainAxis:0,altAxis:0},$),A=e.modifiersData.offset?e.modifiersData.offset[e.placement]:null,N={x:0,y:0};if(O){if(i){var z,V=w==="y"?ar:lr,B=w==="y"?Fr:$r,R=w==="y"?"height":"width",q=O[w],U=q+S[V],G=q-S[B],Y=m?-P[R]/2:0,Z=T===wa?L[R]:P[R],fe=T===wa?-P[R]:-L[R],pe=e.elements.arrow,me=m&&pe?Yg(pe):{width:0,height:0},re=e.modifiersData["arrow#persistent"]?e.modifiersData["arrow#persistent"].padding:w_(),he=re[V],le=re[B],X=sc(0,L[R],me[R]),W=_?L[R]/2-Y-X-he-M.mainAxis:Z-X-he-M.mainAxis,ee=_?-L[R]/2+Y+X+le+M.mainAxis:fe+X+le+M.mainAxis,ce=e.elements.arrow&&ic(e.elements.arrow),te=ce?w==="y"?ce.clientTop||0:ce.clientLeft||0:0,se=(z=A==null?void 0:A[w])!=null?z:0,ue=q+W-se-te,ye=q+ee-se,_e=sc(m?kd(U,ue):U,q,m?vs(G,ye):G);O[w]=_e,N[w]=_e-q}if(a){var Se,Me=w==="x"?ar:lr,Fe=w==="x"?Fr:$r,je=O[E],Je=E==="y"?"height":"width",De=je+S[Me],ct=je-S[Fe],Ct=[ar,lr].indexOf(C)!==-1,Xt=(Se=A==null?void 0:A[E])!=null?Se:0,Sn=Ct?De:je-L[Je]-P[Je]-Xt+M.altAxis,un=Ct?je+L[Je]+P[Je]-Xt-M.altAxis:ct,$t=m&&Ct?h6(Sn,je,un):sc(m?Sn:De,je,m?un:ct);O[E]=$t,N[E]=$t-je}e.modifiersData[r]=N}}const q6={name:"preventOverflow",enabled:!0,phase:"main",fn:W6,requiresIfExists:["offset"]};function U6(t){return{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}}function K6(t){return t===Sr(t)||!Br(t)?Jg(t):U6(t)}function Y6(t){var e=t.getBoundingClientRect(),n=_a(e.width)/t.offsetWidth||1,r=_a(e.height)/t.offsetHeight||1;return n!==1||r!==1}function G6(t,e,n){n===void 0&&(n=!1);var r=Br(e),o=Br(e)&&Y6(e),i=ki(e),s=Ta(t,o,n),a={scrollLeft:0,scrollTop:0},l={x:0,y:0};return(r||!r&&!n)&&((_o(e)!=="body"||Xg(i))&&(a=K6(e)),Br(e)?(l=Ta(e,!0),l.x+=e.clientLeft,l.y+=e.clientTop):i&&(l.x=Zg(i))),{x:s.left+a.scrollLeft-l.x,y:s.top+a.scrollTop-l.y,width:s.width,height:s.height}}function J6(t){var e=new Map,n=new Set,r=[];t.forEach(function(i){e.set(i.name,i)});function o(i){n.add(i.name);var s=[].concat(i.requires||[],i.requiresIfExists||[]);s.forEach(function(a){if(!n.has(a)){var l=e.get(a);l&&o(l)}}),r.push(i)}return t.forEach(function(i){n.has(i.name)||o(i)}),r}function Z6(t){var e=J6(t);return c6.reduce(function(n,r){return n.concat(e.filter(function(o){return o.phase===r}))},[])}function X6(t){var e;return function(){return e||(e=new Promise(function(n){Promise.resolve().then(function(){e=void 0,n(t())})})),e}}function Q6(t){var e=t.reduce(function(n,r){var o=n[r.name];return n[r.name]=o?Object.assign({},o,r,{options:Object.assign({},o.options,r.options),data:Object.assign({},o.data,r.data)}):r,n},{});return Object.keys(e).map(function(n){return e[n]})}var P_={placement:"bottom",modifiers:[],strategy:"absolute"};function N_(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return!e.some(function(r){return!(r&&typeof r.getBoundingClientRect=="function")})}function ej(t){t===void 0&&(t={});var e=t,n=e.defaultModifiers,r=n===void 0?[]:n,o=e.defaultOptions,i=o===void 0?P_:o;return function(a,l,u){u===void 0&&(u=i);var f={placement:"bottom",orderedModifiers:[],options:Object.assign({},P_,i),modifiersData:{},elements:{reference:a,popper:l},attributes:{},styles:{}},p=[],g=!1,m={state:f,setOptions:function(C){var T=typeof C=="function"?C(f.options):C;b(),f.options=Object.assign({},i,f.options,T),f.scrollParents={reference:bs(a)?ac(a):a.contextElement?ac(a.contextElement):[],popper:ac(l)};var _=Z6(Q6([].concat(r,f.options.modifiers)));return f.orderedModifiers=_.filter(function(w){return w.enabled}),y(),m.update()},forceUpdate:function(){if(!g){var C=f.elements,T=C.reference,_=C.popper;if(N_(T,_)){f.rects={reference:G6(T,ic(_),f.options.strategy==="fixed"),popper:Yg(_)},f.reset=!1,f.placement=f.options.placement,f.orderedModifiers.forEach(function(M){return f.modifiersData[M.name]=Object.assign({},M.data)});for(var w=0;w<f.orderedModifiers.length;w++){if(f.reset===!0){f.reset=!1,w=-1;continue}var E=f.orderedModifiers[w],O=E.fn,L=E.options,P=L===void 0?{}:L,$=E.name;typeof O=="function"&&(f=O({state:f,options:P,name:$,instance:m})||f)}}}},update:X6(function(){return new Promise(function(S){m.forceUpdate(),S(f)})}),destroy:function(){b(),g=!0}};if(!N_(a,l))return m;m.setOptions(u).then(function(S){!g&&u.onFirstUpdate&&u.onFirstUpdate(S)});function y(){f.orderedModifiers.forEach(function(S){var C=S.name,T=S.options,_=T===void 0?{}:T,w=S.effect;if(typeof w=="function"){var E=w({state:f,name:C,instance:m,options:_}),O=function(){};p.push(E||O)}})}function b(){p.forEach(function(S){return S()}),p=[]}return m}}var tj=[_6,H6,C6,v_,z6,L6,q6,b6,$6],L_=ej({defaultModifiers:tj});function nj(t){return Ke("MuiPopper",t)}qe("MuiPopper",["root"]);function rj(t,e){if(e==="ltr")return t;switch(t){case"bottom-end":return"bottom-start";case"bottom-start":return"bottom-end";case"top-end":return"top-start";case"top-start":return"top-end";default:return t}}function Ad(t){return typeof t=="function"?t():t}function Id(t){return t.nodeType!==void 0}function oj(t){return!Id(t)}const ij=t=>{const{classes:e}=t;return Ue({root:["root"]},nj,e)},sj={},aj=I.forwardRef(function(e,n){const{anchorEl:r,children:o,direction:i,disablePortal:s,modifiers:a,open:l,placement:u,popperOptions:f,popperRef:p,slotProps:g={},slots:m={},TransitionProps:y,ownerState:b,...S}=e,C=I.useRef(null),T=Et(C,n),_=I.useRef(null),w=Et(_,p),E=I.useRef(w);Tn(()=>{E.current=w},[w]),I.useImperativeHandle(p,()=>_.current,[]);const O=rj(u,i),[L,P]=I.useState(O),[$,M]=I.useState(Ad(r));I.useEffect(()=>{_.current&&_.current.forceUpdate()}),I.useEffect(()=>{r&&M(Ad(r))},[r]),Tn(()=>{if(!$||!l)return;const B=U=>{P(U.placement)};if(process.env.NODE_ENV!=="production"&&$&&Id($)&&$.nodeType===1){const U=$.getBoundingClientRect();process.env.NODE_ENV!=="test"&&U.top===0&&U.left===0&&U.right===0&&U.bottom===0&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(`
|
|
230
|
+
`))}let R=[{name:"preventOverflow",options:{altBoundary:s}},{name:"flip",options:{altBoundary:s}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:U})=>{B(U)}}];a!=null&&(R=R.concat(a)),f&&f.modifiers!=null&&(R=R.concat(f.modifiers));const q=L_($,C.current,{placement:O,...f,modifiers:R});return E.current(q),()=>{q.destroy(),E.current(null)}},[$,s,a,l,f,O]);const A={placement:L};y!==null&&(A.TransitionProps=y);const N=ij(e),z=m.root??"div",V=wt({elementType:z,externalSlotProps:g.root,externalForwardedProps:S,additionalProps:{role:"tooltip",ref:T},ownerState:e,className:N.root});return v.jsx(z,{...V,children:typeof o=="function"?o(A):o})}),F_=I.forwardRef(function(e,n){const{anchorEl:r,children:o,container:i,direction:s="ltr",disablePortal:a=!1,keepMounted:l=!1,modifiers:u,open:f,placement:p="bottom",popperOptions:g=sj,popperRef:m,style:y,transition:b=!1,slotProps:S={},slots:C={},...T}=e,[_,w]=I.useState(!0),E=()=>{w(!1)},O=()=>{w(!0)};if(!l&&!f&&(!b||_))return null;let L;if(i)L=i;else if(r){const M=Ad(r);L=M&&Id(M)?Vn(M).body:Vn(null).body}const P=!f&&l&&(!b||_)?"none":void 0,$=b?{in:f,onEnter:E,onExited:O}:void 0;return v.jsx(Kl,{disablePortal:a,container:L,children:v.jsx(aj,{anchorEl:r,direction:s,disablePortal:a,modifiers:u,ref:n,open:b?!_:f,placement:p,popperOptions:g,popperRef:m,slotProps:S,slots:C,...T,style:{position:"fixed",top:0,left:0,display:P,...y},TransitionProps:$,children:o})})});process.env.NODE_ENV!=="production"&&(F_.propTypes={anchorEl:zo(c.oneOfType([Vo,c.object,c.func]),t=>{if(t.open){const e=Ad(t.anchorEl);if(e&&Id(e)&&e.nodeType===1){const n=e.getBoundingClientRect();if(process.env.NODE_ENV!=="test"&&n.top===0&&n.left===0&&n.right===0&&n.bottom===0)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(`
|
|
231
231
|
`))}else if(!e||typeof e.getBoundingClientRect!="function"||oj(e)&&e.contextElement!=null&&e.contextElement.nodeType!==1)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","It should be an HTML element instance or a virtualElement ","(https://popper.js.org/docs/v2/virtual-elements/)."].join(`
|
|
232
|
-
`))}return null}),children:c.oneOfType([c.node,c.func]),container:c.oneOfType([Vo,c.func]),direction:c.oneOf(["ltr","rtl"]),disablePortal:c.bool,keepMounted:c.bool,modifiers:c.arrayOf(c.shape({data:c.object,effect:c.func,enabled:c.bool,fn:c.func,name:c.any,options:c.object,phase:c.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:c.arrayOf(c.string),requiresIfExists:c.arrayOf(c.string)})),open:c.bool.isRequired,placement:c.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:c.shape({modifiers:c.array,onFirstUpdate:c.func,placement:c.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:c.oneOf(["absolute","fixed"])}),popperRef:mn,slotProps:c.shape({root:c.oneOfType([c.func,c.object])}),slots:c.shape({root:c.elementType}),transition:c.bool});const lj=be(F_,{name:"MuiPopper",slot:"Root",overridesResolver:(t,e)=>e.root})({}),$_=I.forwardRef(function(e,n){const r=no(),o=St({props:e,name:"MuiPopper"}),{anchorEl:i,component:s,components:a,componentsProps:l,container:u,disablePortal:f,keepMounted:p,modifiers:g,open:m,placement:y,popperOptions:b,popperRef:S,transition:C,slots:T,slotProps:_,...w}=o,E=(T==null?void 0:T.root)??(a==null?void 0:a.Root),O={anchorEl:i,container:u,disablePortal:f,keepMounted:p,modifiers:g,open:m,placement:y,popperOptions:b,popperRef:S,transition:C,...w};return v.jsx(lj,{as:s,direction:r?"rtl":"ltr",slots:{root:E},slotProps:_??l,...O,ref:n})});process.env.NODE_ENV!=="production"&&($_.propTypes={anchorEl:c.oneOfType([Vo,c.object,c.func]),children:c.oneOfType([c.node,c.func]),component:c.elementType,components:c.shape({Root:c.elementType}),componentsProps:c.shape({root:c.oneOfType([c.func,c.object])}),container:c.oneOfType([Vo,c.func]),disablePortal:c.bool,keepMounted:c.bool,modifiers:c.arrayOf(c.shape({data:c.object,effect:c.func,enabled:c.bool,fn:c.func,name:c.any,options:c.object,phase:c.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:c.arrayOf(c.string),requiresIfExists:c.arrayOf(c.string)})),open:c.bool.isRequired,placement:c.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:c.shape({modifiers:c.array,onFirstUpdate:c.func,placement:c.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:c.oneOf(["absolute","fixed"])}),popperRef:mn,slotProps:c.shape({root:c.oneOfType([c.func,c.object])}),slots:c.shape({root:c.elementType}),sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),transition:c.bool});function cj(t){return Ke("MuiPickersPopper",t)}qe("MuiPickersPopper",["root","paper"]);const uj="@media (prefers-reduced-motion: reduce)",Ea=typeof navigator<"u"&&navigator.userAgent.match(/android\s(\d+)|OS\s(\d+)/i),B_=Ea&&Ea[1]?parseInt(Ea[1],10):null,R_=Ea&&Ea[2]?parseInt(Ea[2],10):null,dj=B_&&B_<10||R_&&R_<13||!1,z_=()=>p_(uj,{defaultMatches:!1})||dj,fj=["PaperComponent","popperPlacement","ownerState","children","paperSlotProps","paperClasses","onPaperClick","onPaperTouchStart"],pj=t=>{const{classes:e}=t;return Ue({root:["root"],paper:["paper"]},cj,e)},hj=be($_,{name:"MuiPickersPopper",slot:"Root",overridesResolver:(t,e)=>e.root})(({theme:t})=>({zIndex:t.zIndex.modal})),gj=be(ya,{name:"MuiPickersPopper",slot:"Paper",overridesResolver:(t,e)=>e.paper})({outline:0,transformOrigin:"top center",variants:[{props:({placement:t})=>["top","top-start","top-end"].includes(t),style:{transformOrigin:"bottom center"}}]});function mj(t,e){return e.documentElement.clientWidth<t.clientX||e.documentElement.clientHeight<t.clientY}function yj(t,e){const n=I.useRef(!1),r=I.useRef(!1),o=I.useRef(null),i=I.useRef(!1);I.useEffect(()=>{if(!t)return;function l(){i.current=!0}return document.addEventListener("mousedown",l,!0),document.addEventListener("touchstart",l,!0),()=>{document.removeEventListener("mousedown",l,!0),document.removeEventListener("touchstart",l,!0),i.current=!1}},[t]);const s=Be(l=>{if(!i.current)return;const u=r.current;r.current=!1;const f=Vn(o.current);if(!o.current||"clientX"in l&&mj(l,f))return;if(n.current){n.current=!1;return}let p;l.composedPath?p=l.composedPath().indexOf(o.current)>-1:p=!f.documentElement.contains(l.target)||o.current.contains(l.target),!p&&!u&&e(l)}),a=()=>{r.current=!0};return I.useEffect(()=>{if(t){const l=Vn(o.current),u=()=>{n.current=!0};return l.addEventListener("touchstart",s),l.addEventListener("touchmove",u),()=>{l.removeEventListener("touchstart",s),l.removeEventListener("touchmove",u)}}},[t,s]),I.useEffect(()=>{if(t){const l=Vn(o.current);return l.addEventListener("click",s),()=>{l.removeEventListener("click",s),r.current=!1}}},[t,s]),[o,a,a]}const bj=I.forwardRef((t,e)=>{const{PaperComponent:n,popperPlacement:r,ownerState:o,children:i,paperSlotProps:s,paperClasses:a,onPaperClick:l,onPaperTouchStart:u}=t,f=rt(t,fj),p=ne({},o,{placement:r}),g=wt({elementType:n,externalSlotProps:s,additionalProps:{tabIndex:-1,elevation:8,ref:e},className:a,ownerState:p});return v.jsx(n,ne({},f,g,{onClick:m=>{var y;l(m),(y=g.onClick)==null||y.call(g,m)},onTouchStart:m=>{var y;u(m),(y=g.onTouchStart)==null||y.call(g,m)},ownerState:p,children:i}))});function vj(t){const e=Wt({props:t,name:"MuiPickersPopper"}),{anchorEl:n,children:r,containerRef:o=null,shouldRestoreFocus:i,onBlur:s,onDismiss:a,open:l,role:u,placement:f,slots:p,slotProps:g,reduceAnimations:m}=e;I.useEffect(()=>{function B(
|
|
232
|
+
`))}return null}),children:c.oneOfType([c.node,c.func]),container:c.oneOfType([Vo,c.func]),direction:c.oneOf(["ltr","rtl"]),disablePortal:c.bool,keepMounted:c.bool,modifiers:c.arrayOf(c.shape({data:c.object,effect:c.func,enabled:c.bool,fn:c.func,name:c.any,options:c.object,phase:c.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:c.arrayOf(c.string),requiresIfExists:c.arrayOf(c.string)})),open:c.bool.isRequired,placement:c.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:c.shape({modifiers:c.array,onFirstUpdate:c.func,placement:c.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:c.oneOf(["absolute","fixed"])}),popperRef:mn,slotProps:c.shape({root:c.oneOfType([c.func,c.object])}),slots:c.shape({root:c.elementType}),transition:c.bool});const lj=be(F_,{name:"MuiPopper",slot:"Root",overridesResolver:(t,e)=>e.root})({}),$_=I.forwardRef(function(e,n){const r=no(),o=St({props:e,name:"MuiPopper"}),{anchorEl:i,component:s,components:a,componentsProps:l,container:u,disablePortal:f,keepMounted:p,modifiers:g,open:m,placement:y,popperOptions:b,popperRef:S,transition:C,slots:T,slotProps:_,...w}=o,E=(T==null?void 0:T.root)??(a==null?void 0:a.Root),O={anchorEl:i,container:u,disablePortal:f,keepMounted:p,modifiers:g,open:m,placement:y,popperOptions:b,popperRef:S,transition:C,...w};return v.jsx(lj,{as:s,direction:r?"rtl":"ltr",slots:{root:E},slotProps:_??l,...O,ref:n})});process.env.NODE_ENV!=="production"&&($_.propTypes={anchorEl:c.oneOfType([Vo,c.object,c.func]),children:c.oneOfType([c.node,c.func]),component:c.elementType,components:c.shape({Root:c.elementType}),componentsProps:c.shape({root:c.oneOfType([c.func,c.object])}),container:c.oneOfType([Vo,c.func]),disablePortal:c.bool,keepMounted:c.bool,modifiers:c.arrayOf(c.shape({data:c.object,effect:c.func,enabled:c.bool,fn:c.func,name:c.any,options:c.object,phase:c.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:c.arrayOf(c.string),requiresIfExists:c.arrayOf(c.string)})),open:c.bool.isRequired,placement:c.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:c.shape({modifiers:c.array,onFirstUpdate:c.func,placement:c.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:c.oneOf(["absolute","fixed"])}),popperRef:mn,slotProps:c.shape({root:c.oneOfType([c.func,c.object])}),slots:c.shape({root:c.elementType}),sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),transition:c.bool});function cj(t){return Ke("MuiPickersPopper",t)}qe("MuiPickersPopper",["root","paper"]);const uj="@media (prefers-reduced-motion: reduce)",Ea=typeof navigator<"u"&&navigator.userAgent.match(/android\s(\d+)|OS\s(\d+)/i),B_=Ea&&Ea[1]?parseInt(Ea[1],10):null,R_=Ea&&Ea[2]?parseInt(Ea[2],10):null,dj=B_&&B_<10||R_&&R_<13||!1,z_=()=>p_(uj,{defaultMatches:!1})||dj,fj=["PaperComponent","popperPlacement","ownerState","children","paperSlotProps","paperClasses","onPaperClick","onPaperTouchStart"],pj=t=>{const{classes:e}=t;return Ue({root:["root"],paper:["paper"]},cj,e)},hj=be($_,{name:"MuiPickersPopper",slot:"Root",overridesResolver:(t,e)=>e.root})(({theme:t})=>({zIndex:t.zIndex.modal})),gj=be(ya,{name:"MuiPickersPopper",slot:"Paper",overridesResolver:(t,e)=>e.paper})({outline:0,transformOrigin:"top center",variants:[{props:({placement:t})=>["top","top-start","top-end"].includes(t),style:{transformOrigin:"bottom center"}}]});function mj(t,e){return e.documentElement.clientWidth<t.clientX||e.documentElement.clientHeight<t.clientY}function yj(t,e){const n=I.useRef(!1),r=I.useRef(!1),o=I.useRef(null),i=I.useRef(!1);I.useEffect(()=>{if(!t)return;function l(){i.current=!0}return document.addEventListener("mousedown",l,!0),document.addEventListener("touchstart",l,!0),()=>{document.removeEventListener("mousedown",l,!0),document.removeEventListener("touchstart",l,!0),i.current=!1}},[t]);const s=Be(l=>{if(!i.current)return;const u=r.current;r.current=!1;const f=Vn(o.current);if(!o.current||"clientX"in l&&mj(l,f))return;if(n.current){n.current=!1;return}let p;l.composedPath?p=l.composedPath().indexOf(o.current)>-1:p=!f.documentElement.contains(l.target)||o.current.contains(l.target),!p&&!u&&e(l)}),a=()=>{r.current=!0};return I.useEffect(()=>{if(t){const l=Vn(o.current),u=()=>{n.current=!0};return l.addEventListener("touchstart",s),l.addEventListener("touchmove",u),()=>{l.removeEventListener("touchstart",s),l.removeEventListener("touchmove",u)}}},[t,s]),I.useEffect(()=>{if(t){const l=Vn(o.current);return l.addEventListener("click",s),()=>{l.removeEventListener("click",s),r.current=!1}}},[t,s]),[o,a,a]}const bj=I.forwardRef((t,e)=>{const{PaperComponent:n,popperPlacement:r,ownerState:o,children:i,paperSlotProps:s,paperClasses:a,onPaperClick:l,onPaperTouchStart:u}=t,f=rt(t,fj),p=ne({},o,{placement:r}),g=wt({elementType:n,externalSlotProps:s,additionalProps:{tabIndex:-1,elevation:8,ref:e},className:a,ownerState:p});return v.jsx(n,ne({},f,g,{onClick:m=>{var y;l(m),(y=g.onClick)==null||y.call(g,m)},onTouchStart:m=>{var y;u(m),(y=g.onTouchStart)==null||y.call(g,m)},ownerState:p,children:i}))});function vj(t){const e=Wt({props:t,name:"MuiPickersPopper"}),{anchorEl:n,children:r,containerRef:o=null,shouldRestoreFocus:i,onBlur:s,onDismiss:a,open:l,role:u,placement:f,slots:p,slotProps:g,reduceAnimations:m}=e;I.useEffect(()=>{function B(R){l&&R.key==="Escape"&&a()}return document.addEventListener("keydown",B),()=>{document.removeEventListener("keydown",B)}},[a,l]);const y=I.useRef(null);I.useEffect(()=>{u==="tooltip"||i&&!i()||(l?y.current=xr(document):y.current&&y.current instanceof HTMLElement&&setTimeout(()=>{y.current instanceof HTMLElement&&y.current.focus()}))},[l,u,i]);const[b,S,C]=yj(l,s??a),T=I.useRef(null),_=Et(T,o),w=Et(_,b),E=e,O=pj(E),L=z_(),P=m??L,$=B=>{B.key==="Escape"&&(B.stopPropagation(),a())},M=(p==null?void 0:p.desktopTransition)??P?wi:Wl,A=(p==null?void 0:p.desktopTrapFocus)??Ul,N=(p==null?void 0:p.desktopPaper)??gj,z=(p==null?void 0:p.popper)??hj,V=wt({elementType:z,externalSlotProps:g==null?void 0:g.popper,additionalProps:{transition:!0,role:u,open:l,anchorEl:n,placement:f,onKeyDown:$},className:O.root,ownerState:e});return v.jsx(z,ne({},V,{children:({TransitionProps:B,placement:R})=>v.jsx(A,ne({open:l,disableAutoFocus:!0,disableRestoreFocus:!0,disableEnforceFocus:u==="tooltip",isEnabled:()=>!0},g==null?void 0:g.desktopTrapFocus,{children:v.jsx(M,ne({},B,g==null?void 0:g.desktopTransition,{children:v.jsx(bj,{PaperComponent:N,ownerState:E,popperPlacement:R,ref:w,onPaperClick:S,onPaperTouchStart:C,paperClasses:O.paper,paperSlotProps:g==null?void 0:g.desktopPaper,children:r})}))}))}))}const xj=({open:t,onOpen:e,onClose:n})=>{const r=I.useRef(typeof t=="boolean").current,[o,i]=I.useState(!1);I.useEffect(()=>{if(r){if(typeof t!="boolean")throw new Error("You must not mix controlling and uncontrolled mode for `open` prop");i(t)}},[r,t]);const s=I.useCallback(a=>{r||i(a),a&&e&&e(),!a&&n&&n()},[r,e,n]);return{isOpen:o,setIsOpen:s}},Sj=t=>{const{action:e,hasChanged:n,dateState:r,isControlled:o}=t,i=!o&&!r.hasBeenModifiedSinceMount;return e.name==="setValueFromField"?!0:e.name==="setValueFromAction"?i&&["accept","today","clear"].includes(e.pickerAction)?!0:n(r.lastPublishedValue):e.name==="setValueFromView"&&e.selectionState!=="shallow"||e.name==="setValueFromShortcut"?i?!0:n(r.lastPublishedValue):!1},Cj=t=>{const{action:e,hasChanged:n,dateState:r,isControlled:o,closeOnSelect:i}=t,s=!o&&!r.hasBeenModifiedSinceMount;return e.name==="setValueFromAction"?s&&["accept","today","clear"].includes(e.pickerAction)?!0:n(r.lastCommittedValue):e.name==="setValueFromView"&&e.selectionState==="finish"&&i?s?!0:n(r.lastCommittedValue):e.name==="setValueFromShortcut"?e.changeImportance==="accept"&&n(r.lastCommittedValue):!1},wj=t=>{const{action:e,closeOnSelect:n}=t;return e.name==="setValueFromAction"?!0:e.name==="setValueFromView"?e.selectionState==="finish"&&n:e.name==="setValueFromShortcut"?e.changeImportance==="accept":!1},_j=({props:t,valueManager:e,valueType:n,wrapperVariant:r,validator:o})=>{const{onAccept:i,onChange:s,value:a,defaultValue:l,closeOnSelect:u=r==="desktop",timezone:f,referenceDate:p}=t,{current:g}=I.useRef(l),{current:m}=I.useRef(a!==void 0),[y,b]=I.useState(f);process.env.NODE_ENV!=="production"&&(I.useEffect(()=>{m!==(a!==void 0)&&console.error([`MUI X: A component is changing the ${m?"":"un"}controlled value of a picker to be ${m?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).","Decide between using a controlled or uncontrolled valuefor the lifetime of the component.","The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(`
|
|
233
233
|
`))},[a]),I.useEffect(()=>{!m&&g!==l&&console.error(["MUI X: A component is changing the defaultValue of an uncontrolled picker after being initialized. To suppress this warning opt to use a controlled value."].join(`
|
|
234
|
-
`))},[JSON.stringify(g)]));const S=qt(),C=ms(),{isOpen:T,setIsOpen:_}=xj(t),{timezone:w,value:E,handleValueChange:O}=Ng({timezone:f,value:a,defaultValue:g,referenceDate:p,onChange:s,valueManager:e}),[L,P]=I.useState(()=>{let W;return E!==void 0?W=E:g!==void 0?W=g:W=e.emptyValue,{draft:W,lastPublishedValue:W,lastCommittedValue:W,lastControlledValue:a,hasBeenModifiedSinceMount:!1}}),$=e.getTimezone(S,L.draft);y!==f&&(b(f),f&&$&&f!==$&&P(W=>ne({},W,{draft:e.setTimezone(S,f,W.draft)})));const{getValidationErrorForNewValue:M}=Gw({props:t,validator:o,timezone:w,value:L.draft,onError:t.onError}),A=Be(W=>{const te={action:W,dateState:L,hasChanged:_e=>!e.areValuesEqual(S,W.value,_e),isControlled:m,closeOnSelect:u},ue=Sj(te),ee=Cj(te),se=wj(te);P(_e=>ne({},_e,{draft:W.value,lastPublishedValue:ue?W.value:_e.lastPublishedValue,lastCommittedValue:ee?W.value:_e.lastCommittedValue,hasBeenModifiedSinceMount:!0}));let de=null;const ye=()=>(de||(de={validationError:W.name==="setValueFromField"?W.context.validationError:M(W.value)},W.name==="setValueFromShortcut"&&(de.shortcut=W.shortcut)),de);ue&&O(W.value,ye()),ee&&i&&i(W.value,ye()),se&&_(!1)});if(L.lastControlledValue!==a){const W=e.areValuesEqual(S,L.draft,E);P(te=>ne({},te,{lastControlledValue:a},W?{}:{lastCommittedValue:E,lastPublishedValue:E,draft:E,hasBeenModifiedSinceMount:!0}))}const N=Be(()=>{A({value:e.emptyValue,name:"setValueFromAction",pickerAction:"clear"})}),V=Be(()=>{A({value:L.lastPublishedValue,name:"setValueFromAction",pickerAction:"accept"})}),R=Be(()=>{A({value:L.lastPublishedValue,name:"setValueFromAction",pickerAction:"dismiss"})}),B=Be(()=>{A({value:L.lastCommittedValue,name:"setValueFromAction",pickerAction:"cancel"})}),z=Be(()=>{A({value:e.getTodayValue(S,w,n),name:"setValueFromAction",pickerAction:"today"})}),q=Be(W=>{W.preventDefault(),_(!0)}),K=Be(W=>{W==null||W.preventDefault(),_(!1)}),G=Be((W,te="partial")=>A({name:"setValueFromView",value:W,selectionState:te})),Y=Be((W,te,ue)=>A({name:"setValueFromShortcut",value:W,changeImportance:te,shortcut:ue})),Z=Be((W,te)=>A({name:"setValueFromField",value:W,context:te})),me={onClear:N,onAccept:V,onDismiss:R,onCancel:B,onSetToday:z,onOpen:q,onClose:K},he={value:L.draft,onChange:Z},oe=I.useMemo(()=>e.cleanValue(S,L.draft),[S,e,L.draft]),Q={value:oe,onChange:G,onClose:K,open:T},ce=ne({},me,{value:oe,onChange:G,onSelectShortcut:Y,isValid:W=>{const te=o({adapter:C,value:W,timezone:w,props:t});return!e.hasError(te)}}),ae=I.useMemo(()=>({onOpen:q,onClose:K,open:T}),[T,K,q]);return{open:T,fieldProps:he,viewProps:Q,layoutProps:ce,actions:me,contextValue:ae}};let em=!1;function V_({onChange:t,onViewChange:e,openTo:n,view:r,views:o,autoFocus:i,focusedView:s,onFocusedViewChange:a}){process.env.NODE_ENV!=="production"&&(em||(r!=null&&!o.includes(r)&&(console.warn(`MUI X: \`view="${r}"\` is not a valid prop.`,`It must be an element of \`views=["${o.join('", "')}"]\`.`),em=!0),r==null&&n!=null&&!o.includes(n)&&(console.warn(`MUI X: \`openTo="${n}"\` is not a valid prop.`,`It must be an element of \`views=["${o.join('", "')}"]\`.`),em=!0)));const l=I.useRef(n),u=I.useRef(o),f=I.useRef(o.includes(n)?n:o[0]),[p,g]=jo({name:"useViews",state:"view",controlled:r,default:f.current}),m=I.useRef(i?p:null),[y,b]=jo({name:"useViews",state:"focusedView",controlled:s,default:m.current});I.useEffect(()=>{(l.current&&l.current!==n||u.current&&u.current.some(L=>!o.includes(L)))&&(g(o.includes(n)?n:o[0]),u.current=o,l.current=n)},[n,g,p,o]);const S=o.indexOf(p),C=o[S-1]??null,T=o[S+1]??null,_=Be((L,P)=>{b(P?L:$=>L===$?null:$),a==null||a(L,P)}),w=Be(L=>{_(L,!0),L!==p&&(g(L),e&&e(L))}),E=Be(()=>{T&&w(T)}),O=Be((L,P,$)=>{const M=P==="finish",A=$?o.indexOf($)<o.length-1:!!T;if(t(L,M&&A?"partial":P,$),$&&$!==p){const V=o[o.indexOf($)+1];V&&w(V)}else M&&E()});return{view:p,setView:w,focusedView:y,setFocusedView:_,nextView:T,previousView:C,defaultView:o.includes(n)?n:o[0],goToNextView:E,setValueAndGoToNextView:O}}const Tj=["className","sx"],kj=({props:t,propsFromPickerValue:e,additionalViewProps:n,autoFocusView:r,rendererInterceptor:o,fieldRef:i})=>{const{onChange:s,open:a,onClose:l}=e,{view:u,views:f,openTo:p,onViewChange:g,viewRenderers:m,timezone:y}=t,b=rt(t,Tj),{view:S,setView:C,defaultView:T,focusedView:_,setFocusedView:w,setValueAndGoToNextView:E}=V_({view:u,views:f,openTo:p,onChange:s,onViewChange:g,autoFocus:r}),{hasUIView:O,viewModeLookup:L}=I.useMemo(()=>f.reduce((R,B)=>{let z;return m[B]!=null?z="UI":z="field",R.viewModeLookup[B]=z,z==="UI"&&(R.hasUIView=!0),R},{hasUIView:!1,viewModeLookup:{}}),[m,f]),P=I.useMemo(()=>f.reduce((R,B)=>m[B]!=null&&S4(B)?R+1:R,0),[m,f]),$=L[S],M=Be(()=>$==="UI"),[A,N]=I.useState($==="UI"?S:null);return A!==S&&L[S]==="UI"&&N(S),Tn(()=>{$==="field"&&a&&(l(),setTimeout(()=>{var R,B;(R=i==null?void 0:i.current)==null||R.setSelectedSections(S),(B=i==null?void 0:i.current)==null||B.focusField(S)}))},[S]),Tn(()=>{if(!a)return;let R=S;$==="field"&&A!=null&&(R=A),R!==T&&L[R]==="UI"&&L[T]==="UI"&&(R=T),R!==S&&C(R),w(R,!0)},[a]),{hasUIView:O,shouldRestoreFocus:M,layoutProps:{views:f,view:A,onViewChange:C},renderCurrentView:()=>{if(A==null)return null;const R=m[A];if(R==null)return null;const B=ne({},b,n,e,{views:f,timezone:y,onChange:E,view:A,onViewChange:C,focusedView:_,onFocusedViewChange:w,showViewSwitcher:P>1,timeViewsCount:P});return o?o(m,A,B):R(B)}}};function H_(){return typeof window>"u"?"portrait":window.screen&&window.screen.orientation&&window.screen.orientation.angle?Math.abs(window.screen.orientation.angle)===90?"landscape":"portrait":window.orientation&&Math.abs(Number(window.orientation))===90?"landscape":"portrait"}const Ej=(t,e)=>{const[n,r]=I.useState(H_);return Tn(()=>{const i=()=>{r(H_())};return window.addEventListener("orientationchange",i),()=>{window.removeEventListener("orientationchange",i)}},[]),eV(t,["hours","minutes","seconds"])?!1:(e||n)==="landscape"},Mj=({props:t,propsFromPickerValue:e,propsFromPickerViews:n,wrapperVariant:r})=>{const{orientation:o}=t,i=Ej(n.views,o),s=no();return{layoutProps:ne({},n,e,{isLandscape:i,isRtl:s,wrapperVariant:r,disabled:t.disabled,readOnly:t.readOnly})}};function Oj(t){const{props:e,pickerValueResponse:n}=t;return I.useMemo(()=>({value:n.viewProps.value,open:n.open,disabled:e.disabled??!1,readOnly:e.readOnly??!1}),[n.viewProps.value,n.open,e.disabled,e.readOnly])}const j_=({props:t,valueManager:e,valueType:n,wrapperVariant:r,additionalViewProps:o,validator:i,autoFocusView:s,rendererInterceptor:a,fieldRef:l})=>{process.env.NODE_ENV!=="production"&&t.renderInput!=null&&YC(["MUI X: The `renderInput` prop has been removed in version 6.0 of the Date and Time Pickers.","You can replace it with the `textField` component slot in most cases.","For more information, please have a look at the migration guide (https://mui.com/x/migration/migration-pickers-v5/#input-renderer-required-in-v5)."]);const u=_j({props:t,valueManager:e,valueType:n,wrapperVariant:r,validator:i}),f=kj({props:t,additionalViewProps:o,autoFocusView:s,fieldRef:l,propsFromPickerValue:u.viewProps,rendererInterceptor:a}),p=Mj({props:t,wrapperVariant:r,propsFromPickerValue:u.layoutProps,propsFromPickerViews:f.layoutProps}),g=Oj({props:t,pickerValueResponse:u});return{open:u.open,actions:u.actions,fieldProps:u.fieldProps,renderCurrentView:f.renderCurrentView,hasUIView:f.hasUIView,shouldRestoreFocus:f.shouldRestoreFocus,layoutProps:p.layoutProps,contextValue:u.contextValue,ownerState:g}};function W_(t){return Ke("MuiPickersLayout",t)}const xs=qe("MuiPickersLayout",["root","landscape","contentWrapper","toolbar","actionBar","tabs","shortcuts"]);function Aj(t){return Ke("MuiButton",t)}const Ss=qe("MuiButton",["root","text","textInherit","textPrimary","textSecondary","textSuccess","textError","textInfo","textWarning","outlined","outlinedInherit","outlinedPrimary","outlinedSecondary","outlinedSuccess","outlinedError","outlinedInfo","outlinedWarning","contained","containedInherit","containedPrimary","containedSecondary","containedSuccess","containedError","containedInfo","containedWarning","disableElevation","focusVisible","disabled","colorInherit","colorPrimary","colorSecondary","colorSuccess","colorError","colorInfo","colorWarning","textSizeSmall","textSizeMedium","textSizeLarge","outlinedSizeSmall","outlinedSizeMedium","outlinedSizeLarge","containedSizeSmall","containedSizeMedium","containedSizeLarge","sizeMedium","sizeSmall","sizeLarge","fullWidth","startIcon","endIcon","icon","iconSizeSmall","iconSizeMedium","iconSizeLarge","loading","loadingWrapper","loadingIconPlaceholder","loadingIndicator","loadingPositionCenter","loadingPositionStart","loadingPositionEnd"]),q_=I.createContext({});process.env.NODE_ENV!=="production"&&(q_.displayName="ButtonGroupContext");const U_=I.createContext(void 0);process.env.NODE_ENV!=="production"&&(U_.displayName="ButtonGroupButtonContext");const Ij=t=>{const{color:e,disableElevation:n,fullWidth:r,size:o,variant:i,loading:s,loadingPosition:a,classes:l}=t,u={root:["root",s&&"loading",i,`${i}${Ae(e)}`,`size${Ae(o)}`,`${i}Size${Ae(o)}`,`color${Ae(e)}`,n&&"disableElevation",r&&"fullWidth",s&&`loadingPosition${Ae(a)}`],startIcon:["icon","startIcon",`iconSize${Ae(o)}`],endIcon:["icon","endIcon",`iconSize${Ae(o)}`],loadingIndicator:["loadingIndicator"],loadingWrapper:["loadingWrapper"]},f=Ue(u,Aj,l);return{...l,...f}},K_=[{props:{size:"small"},style:{"& > *:nth-of-type(1)":{fontSize:18}}},{props:{size:"medium"},style:{"& > *:nth-of-type(1)":{fontSize:20}}},{props:{size:"large"},style:{"& > *:nth-of-type(1)":{fontSize:22}}}],Dj=be(xa,{shouldForwardProp:t=>ro(t)||t==="classes",name:"MuiButton",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,e[n.variant],e[`${n.variant}${Ae(n.color)}`],e[`size${Ae(n.size)}`],e[`${n.variant}Size${Ae(n.size)}`],n.color==="inherit"&&e.colorInherit,n.disableElevation&&e.disableElevation,n.fullWidth&&e.fullWidth,n.loading&&e.loading]}})(Dt(({theme:t})=>{const e=t.palette.mode==="light"?t.palette.grey[300]:t.palette.grey[800],n=t.palette.mode==="light"?t.palette.grey.A100:t.palette.grey[700];return{...t.typography.button,minWidth:64,padding:"6px 16px",border:0,borderRadius:(t.vars||t).shape.borderRadius,transition:t.transitions.create(["background-color","box-shadow","border-color","color"],{duration:t.transitions.duration.short}),"&:hover":{textDecoration:"none"},[`&.${Ss.disabled}`]:{color:(t.vars||t).palette.action.disabled},variants:[{props:{variant:"contained"},style:{color:"var(--variant-containedColor)",backgroundColor:"var(--variant-containedBg)",boxShadow:(t.vars||t).shadows[2],"&:hover":{boxShadow:(t.vars||t).shadows[4],"@media (hover: none)":{boxShadow:(t.vars||t).shadows[2]}},"&:active":{boxShadow:(t.vars||t).shadows[8]},[`&.${Ss.focusVisible}`]:{boxShadow:(t.vars||t).shadows[6]},[`&.${Ss.disabled}`]:{color:(t.vars||t).palette.action.disabled,boxShadow:(t.vars||t).shadows[0],backgroundColor:(t.vars||t).palette.action.disabledBackground}}},{props:{variant:"outlined"},style:{padding:"5px 15px",border:"1px solid currentColor",borderColor:"var(--variant-outlinedBorder, currentColor)",backgroundColor:"var(--variant-outlinedBg)",color:"var(--variant-outlinedColor)",[`&.${Ss.disabled}`]:{border:`1px solid ${(t.vars||t).palette.action.disabledBackground}`}}},{props:{variant:"text"},style:{padding:"6px 8px",color:"var(--variant-textColor)",backgroundColor:"var(--variant-textBg)"}},...Object.entries(t.palette).filter(Hn()).map(([r])=>({props:{color:r},style:{"--variant-textColor":(t.vars||t).palette[r].main,"--variant-outlinedColor":(t.vars||t).palette[r].main,"--variant-outlinedBorder":t.vars?`rgba(${t.vars.palette[r].mainChannel} / 0.5)`:Rt(t.palette[r].main,.5),"--variant-containedColor":(t.vars||t).palette[r].contrastText,"--variant-containedBg":(t.vars||t).palette[r].main,"@media (hover: hover)":{"&:hover":{"--variant-containedBg":(t.vars||t).palette[r].dark,"--variant-textBg":t.vars?`rgba(${t.vars.palette[r].mainChannel} / ${t.vars.palette.action.hoverOpacity})`:Rt(t.palette[r].main,t.palette.action.hoverOpacity),"--variant-outlinedBorder":(t.vars||t).palette[r].main,"--variant-outlinedBg":t.vars?`rgba(${t.vars.palette[r].mainChannel} / ${t.vars.palette.action.hoverOpacity})`:Rt(t.palette[r].main,t.palette.action.hoverOpacity)}}}})),{props:{color:"inherit"},style:{color:"inherit",borderColor:"currentColor","--variant-containedBg":t.vars?t.vars.palette.Button.inheritContainedBg:e,"@media (hover: hover)":{"&:hover":{"--variant-containedBg":t.vars?t.vars.palette.Button.inheritContainedHoverBg:n,"--variant-textBg":t.vars?`rgba(${t.vars.palette.text.primaryChannel} / ${t.vars.palette.action.hoverOpacity})`:Rt(t.palette.text.primary,t.palette.action.hoverOpacity),"--variant-outlinedBg":t.vars?`rgba(${t.vars.palette.text.primaryChannel} / ${t.vars.palette.action.hoverOpacity})`:Rt(t.palette.text.primary,t.palette.action.hoverOpacity)}}}},{props:{size:"small",variant:"text"},style:{padding:"4px 5px",fontSize:t.typography.pxToRem(13)}},{props:{size:"large",variant:"text"},style:{padding:"8px 11px",fontSize:t.typography.pxToRem(15)}},{props:{size:"small",variant:"outlined"},style:{padding:"3px 9px",fontSize:t.typography.pxToRem(13)}},{props:{size:"large",variant:"outlined"},style:{padding:"7px 21px",fontSize:t.typography.pxToRem(15)}},{props:{size:"small",variant:"contained"},style:{padding:"4px 10px",fontSize:t.typography.pxToRem(13)}},{props:{size:"large",variant:"contained"},style:{padding:"8px 22px",fontSize:t.typography.pxToRem(15)}},{props:{disableElevation:!0},style:{boxShadow:"none","&:hover":{boxShadow:"none"},[`&.${Ss.focusVisible}`]:{boxShadow:"none"},"&:active":{boxShadow:"none"},[`&.${Ss.disabled}`]:{boxShadow:"none"}}},{props:{fullWidth:!0},style:{width:"100%"}},{props:{loadingPosition:"center"},style:{transition:t.transitions.create(["background-color","box-shadow","border-color"],{duration:t.transitions.duration.short}),[`&.${Ss.loading}`]:{color:"transparent"}}}]}})),Pj=be("span",{name:"MuiButton",slot:"StartIcon",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.startIcon,n.loading&&e.startIconLoadingStart,e[`iconSize${Ae(n.size)}`]]}})(({theme:t})=>({display:"inherit",marginRight:8,marginLeft:-4,variants:[{props:{size:"small"},style:{marginLeft:-2}},{props:{loadingPosition:"start",loading:!0},style:{transition:t.transitions.create(["opacity"],{duration:t.transitions.duration.short}),opacity:0}},{props:{loadingPosition:"start",loading:!0,fullWidth:!0},style:{marginRight:-8}},...K_]})),Nj=be("span",{name:"MuiButton",slot:"EndIcon",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.endIcon,n.loading&&e.endIconLoadingEnd,e[`iconSize${Ae(n.size)}`]]}})(({theme:t})=>({display:"inherit",marginRight:-4,marginLeft:8,variants:[{props:{size:"small"},style:{marginRight:-2}},{props:{loadingPosition:"end",loading:!0},style:{transition:t.transitions.create(["opacity"],{duration:t.transitions.duration.short}),opacity:0}},{props:{loadingPosition:"end",loading:!0,fullWidth:!0},style:{marginLeft:-8}},...K_]})),Lj=be("span",{name:"MuiButton",slot:"LoadingIndicator",overridesResolver:(t,e)=>e.loadingIndicator})(({theme:t})=>({display:"none",position:"absolute",visibility:"visible",variants:[{props:{loading:!0},style:{display:"flex"}},{props:{loadingPosition:"start"},style:{left:14}},{props:{loadingPosition:"start",size:"small"},style:{left:10}},{props:{variant:"text",loadingPosition:"start"},style:{left:6}},{props:{loadingPosition:"center"},style:{left:"50%",transform:"translate(-50%)",color:(t.vars||t).palette.action.disabled}},{props:{loadingPosition:"end"},style:{right:14}},{props:{loadingPosition:"end",size:"small"},style:{right:10}},{props:{variant:"text",loadingPosition:"end"},style:{right:6}},{props:{loadingPosition:"start",fullWidth:!0},style:{position:"relative",left:-10}},{props:{loadingPosition:"end",fullWidth:!0},style:{position:"relative",right:-10}}]})),Y_=be("span",{name:"MuiButton",slot:"LoadingIconPlaceholder",overridesResolver:(t,e)=>e.loadingIconPlaceholder})({display:"inline-block",width:"1em",height:"1em"}),cc=I.forwardRef(function(e,n){const r=I.useContext(q_),o=I.useContext(U_),i=Cl(r,e),s=St({props:i,name:"MuiButton"}),{children:a,color:l="primary",component:u="button",className:f,disabled:p=!1,disableElevation:g=!1,disableFocusRipple:m=!1,endIcon:y,focusVisibleClassName:b,fullWidth:S=!1,id:C,loading:T=null,loadingIndicator:_,loadingPosition:w="center",size:E="medium",startIcon:O,type:L,variant:P="text",...$}=s,M=vo(C),A=_??v.jsx(Rg,{"aria-labelledby":M,color:"inherit",size:16}),N={...s,color:l,component:u,disabled:p,disableElevation:g,disableFocusRipple:m,fullWidth:S,loading:T,loadingIndicator:A,loadingPosition:w,size:E,type:L,variant:P},V=Ij(N),R=(O||T&&w==="start")&&v.jsx(Pj,{className:V.startIcon,ownerState:N,children:O||v.jsx(Y_,{className:V.loadingIconPlaceholder,ownerState:N})}),B=(y||T&&w==="end")&&v.jsx(Nj,{className:V.endIcon,ownerState:N,children:y||v.jsx(Y_,{className:V.loadingIconPlaceholder,ownerState:N})}),z=o||"",q=typeof T=="boolean"?v.jsx("span",{className:V.loadingWrapper,style:{display:"contents"},children:T&&v.jsx(Lj,{className:V.loadingIndicator,ownerState:N,children:A})}):null;return v.jsxs(Dj,{ownerState:N,className:Le(r.className,V.root,f,z),component:u,disabled:p||T,focusRipple:!m,focusVisibleClassName:Le(V.focusVisible,b),ref:n,type:L,id:T?M:C,...$,classes:V,children:[R,w!=="end"&&q,a,w==="end"&&q,B]})});process.env.NODE_ENV!=="production"&&(cc.propTypes={children:c.node,classes:c.object,className:c.string,color:c.oneOfType([c.oneOf(["inherit","primary","secondary","success","error","info","warning"]),c.string]),component:c.elementType,disabled:c.bool,disableElevation:c.bool,disableFocusRipple:c.bool,disableRipple:c.bool,endIcon:c.node,focusVisibleClassName:c.string,fullWidth:c.bool,href:c.string,id:c.string,loading:c.bool,loadingIndicator:c.node,loadingPosition:c.oneOf(["center","end","start"]),size:c.oneOfType([c.oneOf(["small","medium","large"]),c.string]),startIcon:c.node,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),type:c.oneOfType([c.oneOf(["button","reset","submit"]),c.string]),variant:c.oneOfType([c.oneOf(["contained","outlined","text"]),c.string])});function Fj(t){return Ke("MuiDialogActions",t)}qe("MuiDialogActions",["root","spacing"]);const $j=t=>{const{classes:e,disableSpacing:n}=t;return Ue({root:["root",!n&&"spacing"]},Fj,e)},Bj=be("div",{name:"MuiDialogActions",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,!n.disableSpacing&&e.spacing]}})({display:"flex",alignItems:"center",padding:8,justifyContent:"flex-end",flex:"0 0 auto",variants:[{props:({ownerState:t})=>!t.disableSpacing,style:{"& > :not(style) ~ :not(style)":{marginLeft:8}}}]}),G_=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiDialogActions"}),{className:o,disableSpacing:i=!1,...s}=r,a={...r,disableSpacing:i},l=$j(a);return v.jsx(Bj,{className:Le(l.root,o),ownerState:a,ref:n,...s})});process.env.NODE_ENV!=="production"&&(G_.propTypes={children:c.node,classes:c.object,className:c.string,disableSpacing:c.bool,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object])});const Rj=["onAccept","onClear","onCancel","onSetToday","actions"];function J_(t){const{onAccept:e,onClear:n,onCancel:r,onSetToday:o,actions:i}=t,s=rt(t,Rj),a=Ko();if(i==null||i.length===0)return null;const l=i==null?void 0:i.map(u=>{switch(u){case"clear":return v.jsx(cc,{onClick:n,children:a.clearButtonLabel},u);case"cancel":return v.jsx(cc,{onClick:r,children:a.cancelButtonLabel},u);case"accept":return v.jsx(cc,{onClick:e,children:a.okButtonLabel},u);case"today":return v.jsx(cc,{onClick:o,children:a.todayButtonLabel},u);default:return null}});return v.jsx(G_,ne({},s,{children:l}))}process.env.NODE_ENV!=="production"&&(J_.propTypes={actions:c.arrayOf(c.oneOf(["accept","cancel","clear","today"]).isRequired),disableSpacing:c.bool,onAccept:c.func.isRequired,onCancel:c.func.isRequired,onClear:c.func.isRequired,onSetToday:c.func.isRequired,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object])});function zj(t){return Ke("MuiListItem",t)}qe("MuiListItem",["root","container","dense","alignItemsFlexStart","divider","gutters","padding","secondaryAction"]);const Vj=qe("MuiListItemButton",["root","focusVisible","dense","alignItemsFlexStart","disabled","divider","gutters","selected"]);function Hj(t){return Ke("MuiListItemSecondaryAction",t)}qe("MuiListItemSecondaryAction",["root","disableGutters"]);const jj=t=>{const{disableGutters:e,classes:n}=t;return Ue({root:["root",e&&"disableGutters"]},Hj,n)},Wj=be("div",{name:"MuiListItemSecondaryAction",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,n.disableGutters&&e.disableGutters]}})({position:"absolute",right:16,top:"50%",transform:"translateY(-50%)",variants:[{props:({ownerState:t})=>t.disableGutters,style:{right:0}}]}),tm=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiListItemSecondaryAction"}),{className:o,...i}=r,s=I.useContext(ha),a={...r,disableGutters:s.disableGutters},l=jj(a);return v.jsx(Wj,{className:Le(l.root,o),ownerState:a,ref:n,...i})});process.env.NODE_ENV!=="production"&&(tm.propTypes={children:c.node,classes:c.object,className:c.string,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object])}),tm.muiName="ListItemSecondaryAction";const qj=(t,e)=>{const{ownerState:n}=t;return[e.root,n.dense&&e.dense,n.alignItems==="flex-start"&&e.alignItemsFlexStart,n.divider&&e.divider,!n.disableGutters&&e.gutters,!n.disablePadding&&e.padding,n.hasSecondaryAction&&e.secondaryAction]},Uj=t=>{const{alignItems:e,classes:n,dense:r,disableGutters:o,disablePadding:i,divider:s,hasSecondaryAction:a}=t;return Ue({root:["root",r&&"dense",!o&&"gutters",!i&&"padding",s&&"divider",e==="flex-start"&&"alignItemsFlexStart",a&&"secondaryAction"],container:["container"]},zj,n)},Kj=be("div",{name:"MuiListItem",slot:"Root",overridesResolver:qj})(Dt(({theme:t})=>({display:"flex",justifyContent:"flex-start",alignItems:"center",position:"relative",textDecoration:"none",width:"100%",boxSizing:"border-box",textAlign:"left",variants:[{props:({ownerState:e})=>!e.disablePadding,style:{paddingTop:8,paddingBottom:8}},{props:({ownerState:e})=>!e.disablePadding&&e.dense,style:{paddingTop:4,paddingBottom:4}},{props:({ownerState:e})=>!e.disablePadding&&!e.disableGutters,style:{paddingLeft:16,paddingRight:16}},{props:({ownerState:e})=>!e.disablePadding&&!!e.secondaryAction,style:{paddingRight:48}},{props:({ownerState:e})=>!!e.secondaryAction,style:{[`& > .${Vj.root}`]:{paddingRight:48}}},{props:{alignItems:"flex-start"},style:{alignItems:"flex-start"}},{props:({ownerState:e})=>e.divider,style:{borderBottom:`1px solid ${(t.vars||t).palette.divider}`,backgroundClip:"padding-box"}},{props:({ownerState:e})=>e.button,style:{transition:t.transitions.create("background-color",{duration:t.transitions.duration.shortest}),"&:hover":{textDecoration:"none",backgroundColor:(t.vars||t).palette.action.hover,"@media (hover: none)":{backgroundColor:"transparent"}}}},{props:({ownerState:e})=>e.hasSecondaryAction,style:{paddingRight:48}}]}))),Yj=be("li",{name:"MuiListItem",slot:"Container",overridesResolver:(t,e)=>e.container})({position:"relative"}),Z_=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiListItem"}),{alignItems:o="center",children:i,className:s,component:a,components:l={},componentsProps:u={},ContainerComponent:f="li",ContainerProps:{className:p,...g}={},dense:m=!1,disableGutters:y=!1,disablePadding:b=!1,divider:S=!1,secondaryAction:C,slotProps:T={},slots:_={},...w}=r,E=I.useContext(ha),O=I.useMemo(()=>({dense:m||E.dense||!1,alignItems:o,disableGutters:y}),[o,E.dense,m,y]),L=I.useRef(null),P=I.Children.toArray(i),$=P.length&&Sl(P[P.length-1],["ListItemSecondaryAction"]),M={...r,alignItems:o,dense:O.dense,disableGutters:y,disablePadding:b,divider:S,hasSecondaryAction:$},A=Uj(M),N=Et(L,n),V=_.root||l.Root||Kj,R=T.root||u.root||{},B={className:Le(A.root,R.className,s),...w};let z=a||"li";return $?(z=!B.component&&!a?"div":z,f==="li"&&(z==="li"?z="div":B.component==="li"&&(B.component="div")),v.jsx(ha.Provider,{value:O,children:v.jsxs(Yj,{as:f,className:Le(A.container,p),ref:N,ownerState:M,...g,children:[v.jsx(V,{...R,...!$l(V)&&{as:z,ownerState:{...M,...R.ownerState}},...B,children:P}),P.pop()]})})):v.jsx(ha.Provider,{value:O,children:v.jsxs(V,{...R,as:z,ref:N,...!$l(V)&&{ownerState:{...M,...R.ownerState}},...B,children:[P,C&&v.jsx(tm,{children:C})]})})});process.env.NODE_ENV!=="production"&&(Z_.propTypes={alignItems:c.oneOf(["center","flex-start"]),children:zo(c.node,t=>{const e=I.Children.toArray(t.children);let n=-1;for(let r=e.length-1;r>=0;r-=1){const o=e[r];if(Sl(o,["ListItemSecondaryAction"])){n=r;break}}return n!==-1&&n!==e.length-1?new Error("MUI: You used an element after ListItemSecondaryAction. For ListItem to detect that it has a secondary action you must pass it as the last child to ListItem."):null}),classes:c.object,className:c.string,component:c.elementType,components:c.shape({Root:c.elementType}),componentsProps:c.shape({root:c.object}),ContainerComponent:Eu,ContainerProps:c.object,dense:c.bool,disableGutters:c.bool,disablePadding:c.bool,divider:c.bool,secondaryAction:c.node,slotProps:c.shape({root:c.object}),slots:c.shape({root:c.elementType}),sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object])});const Gj=ze(v.jsx("path",{d:"M12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2zm5 13.59L15.59 17 12 13.41 8.41 17 7 15.59 10.59 12 7 8.41 8.41 7 12 10.59 15.59 7 17 8.41 13.41 12 17 15.59z"}),"Cancel");function Jj(t){return Ke("MuiChip",t)}const pt=qe("MuiChip",["root","sizeSmall","sizeMedium","colorDefault","colorError","colorInfo","colorPrimary","colorSecondary","colorSuccess","colorWarning","disabled","clickable","clickableColorPrimary","clickableColorSecondary","deletable","deletableColorPrimary","deletableColorSecondary","outlined","filled","outlinedPrimary","outlinedSecondary","filledPrimary","filledSecondary","avatar","avatarSmall","avatarMedium","avatarColorPrimary","avatarColorSecondary","icon","iconSmall","iconMedium","iconColorPrimary","iconColorSecondary","label","labelSmall","labelMedium","deleteIcon","deleteIconSmall","deleteIconMedium","deleteIconColorPrimary","deleteIconColorSecondary","deleteIconOutlinedColorPrimary","deleteIconOutlinedColorSecondary","deleteIconFilledColorPrimary","deleteIconFilledColorSecondary","focusVisible"]),Zj=t=>{const{classes:e,disabled:n,size:r,color:o,iconColor:i,onDelete:s,clickable:a,variant:l}=t,u={root:["root",l,n&&"disabled",`size${Ae(r)}`,`color${Ae(o)}`,a&&"clickable",a&&`clickableColor${Ae(o)}`,s&&"deletable",s&&`deletableColor${Ae(o)}`,`${l}${Ae(o)}`],label:["label",`label${Ae(r)}`],avatar:["avatar",`avatar${Ae(r)}`,`avatarColor${Ae(o)}`],icon:["icon",`icon${Ae(r)}`,`iconColor${Ae(i)}`],deleteIcon:["deleteIcon",`deleteIcon${Ae(r)}`,`deleteIconColor${Ae(o)}`,`deleteIcon${Ae(l)}Color${Ae(o)}`]};return Ue(u,Jj,e)},Xj=be("div",{name:"MuiChip",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t,{color:r,iconColor:o,clickable:i,onDelete:s,size:a,variant:l}=n;return[{[`& .${pt.avatar}`]:e.avatar},{[`& .${pt.avatar}`]:e[`avatar${Ae(a)}`]},{[`& .${pt.avatar}`]:e[`avatarColor${Ae(r)}`]},{[`& .${pt.icon}`]:e.icon},{[`& .${pt.icon}`]:e[`icon${Ae(a)}`]},{[`& .${pt.icon}`]:e[`iconColor${Ae(o)}`]},{[`& .${pt.deleteIcon}`]:e.deleteIcon},{[`& .${pt.deleteIcon}`]:e[`deleteIcon${Ae(a)}`]},{[`& .${pt.deleteIcon}`]:e[`deleteIconColor${Ae(r)}`]},{[`& .${pt.deleteIcon}`]:e[`deleteIcon${Ae(l)}Color${Ae(r)}`]},e.root,e[`size${Ae(a)}`],e[`color${Ae(r)}`],i&&e.clickable,i&&r!=="default"&&e[`clickableColor${Ae(r)})`],s&&e.deletable,s&&r!=="default"&&e[`deletableColor${Ae(r)}`],e[l],e[`${l}${Ae(r)}`]]}})(Dt(({theme:t})=>{const e=t.palette.mode==="light"?t.palette.grey[700]:t.palette.grey[300];return{maxWidth:"100%",fontFamily:t.typography.fontFamily,fontSize:t.typography.pxToRem(13),display:"inline-flex",alignItems:"center",justifyContent:"center",height:32,color:(t.vars||t).palette.text.primary,backgroundColor:(t.vars||t).palette.action.selected,borderRadius:32/2,whiteSpace:"nowrap",transition:t.transitions.create(["background-color","box-shadow"]),cursor:"unset",outline:0,textDecoration:"none",border:0,padding:0,verticalAlign:"middle",boxSizing:"border-box",[`&.${pt.disabled}`]:{opacity:(t.vars||t).palette.action.disabledOpacity,pointerEvents:"none"},[`& .${pt.avatar}`]:{marginLeft:5,marginRight:-6,width:24,height:24,color:t.vars?t.vars.palette.Chip.defaultAvatarColor:e,fontSize:t.typography.pxToRem(12)},[`& .${pt.avatarColorPrimary}`]:{color:(t.vars||t).palette.primary.contrastText,backgroundColor:(t.vars||t).palette.primary.dark},[`& .${pt.avatarColorSecondary}`]:{color:(t.vars||t).palette.secondary.contrastText,backgroundColor:(t.vars||t).palette.secondary.dark},[`& .${pt.avatarSmall}`]:{marginLeft:4,marginRight:-4,width:18,height:18,fontSize:t.typography.pxToRem(10)},[`& .${pt.icon}`]:{marginLeft:5,marginRight:-6},[`& .${pt.deleteIcon}`]:{WebkitTapHighlightColor:"transparent",color:t.vars?`rgba(${t.vars.palette.text.primaryChannel} / 0.26)`:Rt(t.palette.text.primary,.26),fontSize:22,cursor:"pointer",margin:"0 5px 0 -6px","&:hover":{color:t.vars?`rgba(${t.vars.palette.text.primaryChannel} / 0.4)`:Rt(t.palette.text.primary,.4)}},variants:[{props:{size:"small"},style:{height:24,[`& .${pt.icon}`]:{fontSize:18,marginLeft:4,marginRight:-4},[`& .${pt.deleteIcon}`]:{fontSize:16,marginRight:4,marginLeft:-4}}},...Object.entries(t.palette).filter(Hn(["contrastText"])).map(([n])=>({props:{color:n},style:{backgroundColor:(t.vars||t).palette[n].main,color:(t.vars||t).palette[n].contrastText,[`& .${pt.deleteIcon}`]:{color:t.vars?`rgba(${t.vars.palette[n].contrastTextChannel} / 0.7)`:Rt(t.palette[n].contrastText,.7),"&:hover, &:active":{color:(t.vars||t).palette[n].contrastText}}}})),{props:n=>n.iconColor===n.color,style:{[`& .${pt.icon}`]:{color:t.vars?t.vars.palette.Chip.defaultIconColor:e}}},{props:n=>n.iconColor===n.color&&n.color!=="default",style:{[`& .${pt.icon}`]:{color:"inherit"}}},{props:{onDelete:!0},style:{[`&.${pt.focusVisible}`]:{backgroundColor:t.vars?`rgba(${t.vars.palette.action.selectedChannel} / calc(${t.vars.palette.action.selectedOpacity} + ${t.vars.palette.action.focusOpacity}))`:Rt(t.palette.action.selected,t.palette.action.selectedOpacity+t.palette.action.focusOpacity)}}},...Object.entries(t.palette).filter(Hn(["dark"])).map(([n])=>({props:{color:n,onDelete:!0},style:{[`&.${pt.focusVisible}`]:{background:(t.vars||t).palette[n].dark}}})),{props:{clickable:!0},style:{userSelect:"none",WebkitTapHighlightColor:"transparent",cursor:"pointer","&:hover":{backgroundColor:t.vars?`rgba(${t.vars.palette.action.selectedChannel} / calc(${t.vars.palette.action.selectedOpacity} + ${t.vars.palette.action.hoverOpacity}))`:Rt(t.palette.action.selected,t.palette.action.selectedOpacity+t.palette.action.hoverOpacity)},[`&.${pt.focusVisible}`]:{backgroundColor:t.vars?`rgba(${t.vars.palette.action.selectedChannel} / calc(${t.vars.palette.action.selectedOpacity} + ${t.vars.palette.action.focusOpacity}))`:Rt(t.palette.action.selected,t.palette.action.selectedOpacity+t.palette.action.focusOpacity)},"&:active":{boxShadow:(t.vars||t).shadows[1]}}},...Object.entries(t.palette).filter(Hn(["dark"])).map(([n])=>({props:{color:n,clickable:!0},style:{[`&:hover, &.${pt.focusVisible}`]:{backgroundColor:(t.vars||t).palette[n].dark}}})),{props:{variant:"outlined"},style:{backgroundColor:"transparent",border:t.vars?`1px solid ${t.vars.palette.Chip.defaultBorder}`:`1px solid ${t.palette.mode==="light"?t.palette.grey[400]:t.palette.grey[700]}`,[`&.${pt.clickable}:hover`]:{backgroundColor:(t.vars||t).palette.action.hover},[`&.${pt.focusVisible}`]:{backgroundColor:(t.vars||t).palette.action.focus},[`& .${pt.avatar}`]:{marginLeft:4},[`& .${pt.avatarSmall}`]:{marginLeft:2},[`& .${pt.icon}`]:{marginLeft:4},[`& .${pt.iconSmall}`]:{marginLeft:2},[`& .${pt.deleteIcon}`]:{marginRight:5},[`& .${pt.deleteIconSmall}`]:{marginRight:3}}},...Object.entries(t.palette).filter(Hn()).map(([n])=>({props:{variant:"outlined",color:n},style:{color:(t.vars||t).palette[n].main,border:`1px solid ${t.vars?`rgba(${t.vars.palette[n].mainChannel} / 0.7)`:Rt(t.palette[n].main,.7)}`,[`&.${pt.clickable}:hover`]:{backgroundColor:t.vars?`rgba(${t.vars.palette[n].mainChannel} / ${t.vars.palette.action.hoverOpacity})`:Rt(t.palette[n].main,t.palette.action.hoverOpacity)},[`&.${pt.focusVisible}`]:{backgroundColor:t.vars?`rgba(${t.vars.palette[n].mainChannel} / ${t.vars.palette.action.focusOpacity})`:Rt(t.palette[n].main,t.palette.action.focusOpacity)},[`& .${pt.deleteIcon}`]:{color:t.vars?`rgba(${t.vars.palette[n].mainChannel} / 0.7)`:Rt(t.palette[n].main,.7),"&:hover, &:active":{color:(t.vars||t).palette[n].main}}}}))]}})),Qj=be("span",{name:"MuiChip",slot:"Label",overridesResolver:(t,e)=>{const{ownerState:n}=t,{size:r}=n;return[e.label,e[`label${Ae(r)}`]]}})({overflow:"hidden",textOverflow:"ellipsis",paddingLeft:12,paddingRight:12,whiteSpace:"nowrap",variants:[{props:{variant:"outlined"},style:{paddingLeft:11,paddingRight:11}},{props:{size:"small"},style:{paddingLeft:8,paddingRight:8}},{props:{size:"small",variant:"outlined"},style:{paddingLeft:7,paddingRight:7}}]});function X_(t){return t.key==="Backspace"||t.key==="Delete"}const Q_=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiChip"}),{avatar:o,className:i,clickable:s,color:a="default",component:l,deleteIcon:u,disabled:f=!1,icon:p,label:g,onClick:m,onDelete:y,onKeyDown:b,onKeyUp:S,size:C="medium",variant:T="filled",tabIndex:_,skipFocusWhenDisabled:w=!1,...E}=r,O=I.useRef(null),L=Et(O,n),P=G=>{G.stopPropagation(),y&&y(G)},$=G=>{G.currentTarget===G.target&&X_(G)&&G.preventDefault(),b&&b(G)},M=G=>{G.currentTarget===G.target&&y&&X_(G)&&y(G),S&&S(G)},A=s!==!1&&m?!0:s,N=A||y?xa:l||"div",V={...r,component:N,disabled:f,size:C,color:a,iconColor:I.isValidElement(p)&&p.props.color||a,onDelete:!!y,clickable:A,variant:T},R=Zj(V),B=N===xa?{component:l||"div",focusVisibleClassName:R.focusVisible,...y&&{disableRipple:!0}}:{};let z=null;y&&(z=u&&I.isValidElement(u)?I.cloneElement(u,{className:Le(u.props.className,R.deleteIcon),onClick:P}):v.jsx(Gj,{className:Le(R.deleteIcon),onClick:P}));let q=null;o&&I.isValidElement(o)&&(q=I.cloneElement(o,{className:Le(R.avatar,o.props.className)}));let K=null;return p&&I.isValidElement(p)&&(K=I.cloneElement(p,{className:Le(R.icon,p.props.className)})),process.env.NODE_ENV!=="production"&&q&&K&&console.error("MUI: The Chip component can not handle the avatar and the icon prop at the same time. Pick one."),v.jsxs(Xj,{as:N,className:Le(R.root,i),disabled:A&&f?!0:void 0,onClick:m,onKeyDown:$,onKeyUp:M,ref:L,tabIndex:w&&f?-1:_,ownerState:V,...B,...E,children:[q||K,v.jsx(Qj,{className:Le(R.label),ownerState:V,children:g}),z]})});process.env.NODE_ENV!=="production"&&(Q_.propTypes={avatar:c.element,children:e$,classes:c.object,className:c.string,clickable:c.bool,color:c.oneOfType([c.oneOf(["default","primary","secondary","error","info","success","warning"]),c.string]),component:c.elementType,deleteIcon:c.element,disabled:c.bool,icon:c.element,label:c.node,onClick:c.func,onDelete:c.func,onKeyDown:c.func,onKeyUp:c.func,size:c.oneOfType([c.oneOf(["medium","small"]),c.string]),skipFocusWhenDisabled:c.bool,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),tabIndex:c.number,variant:c.oneOfType([c.oneOf(["filled","outlined"]),c.string])});const uc=36,Dd=2,Pd=320,eW=280,nm=336,tW=["items","changeImportance","isLandscape","onChange","isValid"],nW=["getValue"];function eT(t){const{items:e,changeImportance:n="accept",onChange:r,isValid:o}=t,i=rt(t,tW);if(e==null||e.length===0)return null;const s=e.map(a=>{let{getValue:l}=a,u=rt(a,nW);const f=l({isValid:o});return ne({},u,{label:u.label,onClick:()=>{r(f,n,u)},disabled:!o(f)})});return v.jsx(fg,ne({dense:!0,sx:[{maxHeight:nm,maxWidth:200,overflow:"auto"},...Array.isArray(i.sx)?i.sx:[i.sx]]},i,{children:s.map(a=>v.jsx(Z_,{children:v.jsx(Q_,ne({},a))},a.id??a.label))}))}process.env.NODE_ENV!=="production"&&(eT.propTypes={changeImportance:c.oneOf(["accept","set"]),className:c.string,component:c.elementType,dense:c.bool,disablePadding:c.bool,isLandscape:c.bool.isRequired,isValid:c.func.isRequired,items:c.arrayOf(c.shape({getValue:c.func.isRequired,id:c.string,label:c.string.isRequired})),onChange:c.func.isRequired,style:c.object,subheader:c.node,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object])});function rW(t){return t.view!==null}const oW=t=>{const{classes:e,isLandscape:n}=t;return Ue({root:["root",n&&"landscape"],contentWrapper:["contentWrapper"],toolbar:["toolbar"],actionBar:["actionBar"],tabs:["tabs"],landscape:["landscape"],shortcuts:["shortcuts"]},W_,e)},iW=t=>{const{wrapperVariant:e,onAccept:n,onClear:r,onCancel:o,onSetToday:i,view:s,views:a,onViewChange:l,value:u,onChange:f,onSelectShortcut:p,isValid:g,isLandscape:m,disabled:y,readOnly:b,children:S,slots:C,slotProps:T}=t,_=oW(t),w=(C==null?void 0:C.actionBar)??J_,E=wt({elementType:w,externalSlotProps:T==null?void 0:T.actionBar,additionalProps:{onAccept:n,onClear:r,onCancel:o,onSetToday:i,actions:e==="desktop"?[]:["cancel","accept"]},className:_.actionBar,ownerState:ne({},t,{wrapperVariant:e})}),O=v.jsx(w,ne({},E)),L=C==null?void 0:C.toolbar,P=wt({elementType:L,externalSlotProps:T==null?void 0:T.toolbar,additionalProps:{isLandscape:m,onChange:f,value:u,view:s,onViewChange:l,views:a,disabled:y,readOnly:b},className:_.toolbar,ownerState:ne({},t,{wrapperVariant:e})}),$=rW(P)&&L?v.jsx(L,ne({},P)):null,M=S,A=C==null?void 0:C.tabs,N=s&&A?v.jsx(A,ne({view:s,onViewChange:l,className:_.tabs},T==null?void 0:T.tabs)):null,V=(C==null?void 0:C.shortcuts)??eT,R=wt({elementType:V,externalSlotProps:T==null?void 0:T.shortcuts,additionalProps:{isValid:g,isLandscape:m,onChange:p},className:_.shortcuts,ownerState:{isValid:g,isLandscape:m,onChange:p,wrapperVariant:e}}),B=s&&V?v.jsx(V,ne({},R)):null;return{toolbar:$,content:M,tabs:N,actionBar:O,shortcuts:B}},sW=t=>{const{isLandscape:e,classes:n}=t;return Ue({root:["root",e&&"landscape"],contentWrapper:["contentWrapper"]},W_,n)},aW=be("div",{name:"MuiPickersLayout",slot:"Root",overridesResolver:(t,e)=>e.root})({display:"grid",gridAutoColumns:"max-content auto max-content",gridAutoRows:"max-content auto max-content",[`& .${xs.actionBar}`]:{gridColumn:"1 / 4",gridRow:3},variants:[{props:{isLandscape:!0},style:{[`& .${xs.toolbar}`]:{gridColumn:1,gridRow:"2 / 3"},[`.${xs.shortcuts}`]:{gridColumn:"2 / 4",gridRow:1}}},{props:{isLandscape:!0,isRtl:!0},style:{[`& .${xs.toolbar}`]:{gridColumn:3}}},{props:{isLandscape:!1},style:{[`& .${xs.toolbar}`]:{gridColumn:"2 / 4",gridRow:1},[`& .${xs.shortcuts}`]:{gridColumn:1,gridRow:"2 / 3"}}},{props:{isLandscape:!1,isRtl:!0},style:{[`& .${xs.shortcuts}`]:{gridColumn:3}}}]}),lW=be("div",{name:"MuiPickersLayout",slot:"ContentWrapper",overridesResolver:(t,e)=>e.contentWrapper})({gridColumn:2,gridRow:2,display:"flex",flexDirection:"column"}),rm=I.forwardRef(function(e,n){const r=Wt({props:e,name:"MuiPickersLayout"}),{toolbar:o,content:i,tabs:s,actionBar:a,shortcuts:l}=iW(r),{sx:u,className:f,isLandscape:p,wrapperVariant:g}=r,m=sW(r);return v.jsxs(aW,{ref:n,sx:u,className:Le(m.root,f),ownerState:r,children:[p?l:o,p?o:l,v.jsx(lW,{className:m.contentWrapper,children:g==="desktop"?v.jsxs(I.Fragment,{children:[i,s]}):v.jsxs(I.Fragment,{children:[s,i]})}),a]})});process.env.NODE_ENV!=="production"&&(rm.propTypes={children:c.node,classes:c.object,className:c.string,disabled:c.bool,isLandscape:c.bool.isRequired,isRtl:c.bool.isRequired,isValid:c.func.isRequired,onAccept:c.func.isRequired,onCancel:c.func.isRequired,onChange:c.func.isRequired,onClear:c.func.isRequired,onClose:c.func.isRequired,onDismiss:c.func.isRequired,onOpen:c.func.isRequired,onSelectShortcut:c.func.isRequired,onSetToday:c.func.isRequired,onViewChange:c.func.isRequired,orientation:c.oneOf(["landscape","portrait"]),readOnly:c.bool,slotProps:c.object,slots:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),value:c.any,view:c.oneOf(["day","hours","meridiem","minutes","month","seconds","year"]),views:c.arrayOf(c.oneOf(["day","hours","meridiem","minutes","month","seconds","year"]).isRequired).isRequired,wrapperVariant:c.oneOf(["desktop","mobile"])});const cW=["props","getOpenDialogAriaText"],uW=["ownerState"],dW=["ownerState"],fW=t=>{var ye;let{props:e,getOpenDialogAriaText:n}=t,r=rt(t,cW);const{slots:o,slotProps:i,className:s,sx:a,format:l,formatDensity:u,enableAccessibleFieldDOMStructure:f,selectedSections:p,onSelectedSectionsChange:g,timezone:m,name:y,label:b,inputRef:S,readOnly:C,disabled:T,autoFocus:_,localeText:w,reduceAnimations:E}=e,O=I.useRef(null),L=I.useRef(null),P=vo(),$=((ye=i==null?void 0:i.toolbar)==null?void 0:ye.hidden)??!1,{open:M,actions:A,hasUIView:N,layoutProps:V,renderCurrentView:R,shouldRestoreFocus:B,fieldProps:z,contextValue:q,ownerState:K}=j_(ne({},r,{props:e,fieldRef:L,autoFocusView:!0,additionalViewProps:{},wrapperVariant:"desktop"})),G=o.inputAdornment??zg,Y=wt({elementType:G,externalSlotProps:i==null?void 0:i.inputAdornment,additionalProps:{position:"end"},ownerState:e}),Z=rt(Y,uW),me=o.openPickerButton??Sa,he=wt({elementType:me,externalSlotProps:i==null?void 0:i.openPickerButton,additionalProps:{disabled:T||C,onClick:M?A.onClose:A.onOpen,"aria-label":n(z.value),edge:Z.position},ownerState:e}),oe=rt(he,dW),Q=o.openPickerIcon,fe=wt({elementType:Q,externalSlotProps:i==null?void 0:i.openPickerIcon,ownerState:K}),ce=o.field,ae=wt({elementType:ce,externalSlotProps:i==null?void 0:i.field,additionalProps:ne({},z,$&&{id:P},{readOnly:C,disabled:T,className:s,sx:a,format:l,formatDensity:u,enableAccessibleFieldDOMStructure:f,selectedSections:p,onSelectedSectionsChange:g,timezone:m,label:b,name:y,autoFocus:_&&!e.open,focused:M?!0:void 0},S?{inputRef:S}:{}),ownerState:e});N&&(ae.InputProps=ne({},ae.InputProps,{ref:O},!e.disableOpenPicker&&{[`${Z.position}Adornment`]:v.jsx(G,ne({},Z,{children:v.jsx(me,ne({},oe,{children:v.jsx(Q,ne({},fe))}))}))}));const W=ne({textField:o.textField,clearIcon:o.clearIcon,clearButton:o.clearButton},ae.slots),te=o.layout??rm;let ue=P;$&&(b?ue=`${P}-label`:ue=void 0);const ee=ne({},i,{toolbar:ne({},i==null?void 0:i.toolbar,{titleId:P}),popper:ne({"aria-labelledby":ue},i==null?void 0:i.popper)}),se=Et(L,ae.unstableFieldRef);return{renderPicker:()=>v.jsxs(r_,{contextValue:q,localeText:w,children:[v.jsx(ce,ne({},ae,{slots:W,slotProps:ee,unstableFieldRef:se})),v.jsx(vj,ne({role:"dialog",placement:"bottom-start",anchorEl:O.current},A,{open:M,slots:o,slotProps:ee,shouldRestoreFocus:B,reduceAnimations:E,children:v.jsx(te,ne({},V,ee==null?void 0:ee.layout,{slots:o,slotProps:ee,children:R()}))}))]})}},tT=({shouldDisableDate:t,shouldDisableMonth:e,shouldDisableYear:n,minDate:r,maxDate:o,disableFuture:i,disablePast:s,timezone:a})=>{const l=ms();return I.useCallback(u=>Xl({adapter:l,value:u,timezone:a,props:{shouldDisableDate:t,shouldDisableMonth:e,shouldDisableYear:n,minDate:r,maxDate:o,disableFuture:i,disablePast:s}})!==null,[l,t,e,n,r,o,i,s,a])},pW=(t,e,n)=>(r,o)=>{switch(o.type){case"changeMonth":return ne({},r,{slideDirection:o.direction,currentMonth:o.newMonth,isMonthSwitchingAnimating:!t});case"changeMonthTimezone":{const i=o.newTimezone;if(n.getTimezone(r.currentMonth)===i)return r;let s=n.setTimezone(r.currentMonth,i);return n.getMonth(s)!==n.getMonth(r.currentMonth)&&(s=n.setMonth(s,n.getMonth(r.currentMonth))),ne({},r,{currentMonth:s})}case"finishMonthSwitchingAnimation":return ne({},r,{isMonthSwitchingAnimating:!1});case"changeFocusedDay":{if(r.focusedDay!=null&&o.focusedDay!=null&&n.isSameDay(o.focusedDay,r.focusedDay))return r;const i=o.focusedDay!=null&&!e&&!n.isSameMonth(r.currentMonth,o.focusedDay);return ne({},r,{focusedDay:o.focusedDay,isMonthSwitchingAnimating:i&&!t&&!o.withoutMonthSwitchingAnimation,currentMonth:i?n.startOfMonth(o.focusedDay):r.currentMonth,slideDirection:o.focusedDay!=null&&n.isAfterDay(o.focusedDay,r.currentMonth)?"left":"right"})}default:throw new Error("missing support")}},hW=t=>{const{value:e,referenceDate:n,disableFuture:r,disablePast:o,disableSwitchToMonthOnDayFocus:i=!1,maxDate:s,minDate:a,onMonthChange:l,reduceAnimations:u,shouldDisableDate:f,timezone:p}=t,g=qt(),m=I.useRef(pW(!!u,i,g)).current,y=I.useMemo(()=>wo.getInitialReferenceValue({value:e,utils:g,timezone:p,props:t,referenceDate:n,granularity:Co.day}),[n,p]),[b,S]=I.useReducer(m,{isMonthSwitchingAnimating:!1,focusedDay:y,currentMonth:g.startOfMonth(y),slideDirection:"left"});I.useEffect(()=>{S({type:"changeMonthTimezone",newTimezone:g.getTimezone(y)})},[y,g]);const C=I.useCallback(O=>{S(ne({type:"changeMonth"},O)),l&&l(O.newMonth)},[l]),T=I.useCallback(O=>{const L=O;g.isSameMonth(L,b.currentMonth)||C({newMonth:g.startOfMonth(L),direction:g.isAfterDay(L,b.currentMonth)?"left":"right"})},[b.currentMonth,C,g]),_=tT({shouldDisableDate:f,minDate:a,maxDate:s,disableFuture:r,disablePast:o,timezone:p}),w=I.useCallback(()=>{S({type:"finishMonthSwitchingAnimation"})},[]),E=Be((O,L)=>{_(O)||S({type:"changeFocusedDay",focusedDay:O,withoutMonthSwitchingAnimation:L})});return{referenceDate:y,calendarState:b,changeMonth:T,changeFocusedDay:E,isDateDisabled:_,onMonthSwitchingAnimationEnd:w,handleChangeMonth:C}},gW=t=>Ke("MuiPickersFadeTransitionGroup",t);qe("MuiPickersFadeTransitionGroup",["root"]);const mW=t=>{const{classes:e}=t;return Ue({root:["root"]},gW,e)},yW=be(jl,{name:"MuiPickersFadeTransitionGroup",slot:"Root",overridesResolver:(t,e)=>e.root})({display:"block",position:"relative"});function nT(t){const e=Wt({props:t,name:"MuiPickersFadeTransitionGroup"}),{children:n,className:r,reduceAnimations:o,transKey:i}=e,s=mW(e),a=Si();return o?n:v.jsx(yW,{className:Le(s.root,r),children:v.jsx(wi,{appear:!1,mountOnEnter:!0,unmountOnExit:!0,timeout:{appear:a.transitions.duration.enteringScreen,enter:a.transitions.duration.enteringScreen,exit:0},children:n},i)})}function bW(t){return Ke("MuiPickersDay",t)}const Cs=qe("MuiPickersDay",["root","dayWithMargin","dayOutsideMonth","hiddenDaySpacingFiller","today","selected","disabled"]),vW=["autoFocus","className","day","disabled","disableHighlightToday","disableMargin","hidden","isAnimating","onClick","onDaySelect","onFocus","onBlur","onKeyDown","onMouseDown","onMouseEnter","outsideCurrentMonth","selected","showDaysOutsideCurrentMonth","children","today","isFirstVisibleCell","isLastVisibleCell"],xW=t=>{const{selected:e,disableMargin:n,disableHighlightToday:r,today:o,disabled:i,outsideCurrentMonth:s,showDaysOutsideCurrentMonth:a,classes:l}=t,u=s&&!a;return Ue({root:["root",e&&!u&&"selected",i&&"disabled",!n&&"dayWithMargin",!r&&o&&"today",s&&a&&"dayOutsideMonth",u&&"hiddenDaySpacingFiller"],hiddenDaySpacingFiller:["hiddenDaySpacingFiller"]},bW,l)},rT=({theme:t})=>ne({},t.typography.caption,{width:uc,height:uc,borderRadius:"50%",padding:0,backgroundColor:"transparent",transition:t.transitions.create("background-color",{duration:t.transitions.duration.short}),color:(t.vars||t).palette.text.primary,"@media (pointer: fine)":{"&:hover":{backgroundColor:t.vars?`rgba(${t.vars.palette.primary.mainChannel} / ${t.vars.palette.action.hoverOpacity})`:Rt(t.palette.primary.main,t.palette.action.hoverOpacity)}},"&:focus":{backgroundColor:t.vars?`rgba(${t.vars.palette.primary.mainChannel} / ${t.vars.palette.action.focusOpacity})`:Rt(t.palette.primary.main,t.palette.action.focusOpacity),[`&.${Cs.selected}`]:{willChange:"background-color",backgroundColor:(t.vars||t).palette.primary.dark}},[`&.${Cs.selected}`]:{color:(t.vars||t).palette.primary.contrastText,backgroundColor:(t.vars||t).palette.primary.main,fontWeight:t.typography.fontWeightMedium,"&:hover":{willChange:"background-color",backgroundColor:(t.vars||t).palette.primary.dark}},[`&.${Cs.disabled}:not(.${Cs.selected})`]:{color:(t.vars||t).palette.text.disabled},[`&.${Cs.disabled}&.${Cs.selected}`]:{opacity:.6},variants:[{props:{disableMargin:!1},style:{margin:`0 ${Dd}px`}},{props:{outsideCurrentMonth:!0,showDaysOutsideCurrentMonth:!0},style:{color:(t.vars||t).palette.text.secondary}},{props:{disableHighlightToday:!1,today:!0},style:{[`&:not(.${Cs.selected})`]:{border:`1px solid ${(t.vars||t).palette.text.secondary}`}}}]}),oT=(t,e)=>{const{ownerState:n}=t;return[e.root,!n.disableMargin&&e.dayWithMargin,!n.disableHighlightToday&&n.today&&e.today,!n.outsideCurrentMonth&&n.showDaysOutsideCurrentMonth&&e.dayOutsideMonth,n.outsideCurrentMonth&&!n.showDaysOutsideCurrentMonth&&e.hiddenDaySpacingFiller]},SW=be(xa,{name:"MuiPickersDay",slot:"Root",overridesResolver:oT})(rT),CW=be("div",{name:"MuiPickersDay",slot:"Root",overridesResolver:oT})(({theme:t})=>ne({},rT({theme:t}),{opacity:0,pointerEvents:"none"})),dc=()=>{},iT=I.forwardRef(function(e,n){const r=Wt({props:e,name:"MuiPickersDay"}),{autoFocus:o=!1,className:i,day:s,disabled:a=!1,disableHighlightToday:l=!1,disableMargin:u=!1,isAnimating:f,onClick:p,onDaySelect:g,onFocus:m=dc,onBlur:y=dc,onKeyDown:b=dc,onMouseDown:S=dc,onMouseEnter:C=dc,outsideCurrentMonth:T,selected:_=!1,showDaysOutsideCurrentMonth:w=!1,children:E,today:O=!1}=r,L=rt(r,vW),P=ne({},r,{autoFocus:o,disabled:a,disableHighlightToday:l,disableMargin:u,selected:_,showDaysOutsideCurrentMonth:w,today:O}),$=xW(P),M=qt(),A=I.useRef(null),N=Et(A,n);Tn(()=>{o&&!a&&!f&&!T&&A.current.focus()},[o,a,f,T]);const V=B=>{S(B),T&&B.preventDefault()},R=B=>{a||g(s),T&&B.currentTarget.focus(),p&&p(B)};return T&&!w?v.jsx(CW,{className:Le($.root,$.hiddenDaySpacingFiller,i),ownerState:P,role:L.role}):v.jsx(SW,ne({className:Le($.root,i),ref:N,centerRipple:!0,disabled:a,tabIndex:_?0:-1,onKeyDown:B=>b(B,s),onFocus:B=>m(B,s),onBlur:B=>y(B,s),onMouseEnter:B=>C(B,s),onClick:R,onMouseDown:V},L,{ownerState:P,children:E||M.format(s,"dayOfMonth")}))});process.env.NODE_ENV!=="production"&&(iT.propTypes={action:c.oneOfType([c.func,c.shape({current:c.shape({focusVisible:c.func.isRequired})})]),centerRipple:c.bool,classes:c.object,className:c.string,component:c.elementType,day:c.object.isRequired,disabled:c.bool,disableHighlightToday:c.bool,disableMargin:c.bool,disableRipple:c.bool,disableTouchRipple:c.bool,focusRipple:c.bool,focusVisibleClassName:c.string,isAnimating:c.bool,isFirstVisibleCell:c.bool.isRequired,isLastVisibleCell:c.bool.isRequired,onBlur:c.func,onDaySelect:c.func.isRequired,onFocus:c.func,onFocusVisible:c.func,onKeyDown:c.func,onMouseEnter:c.func,outsideCurrentMonth:c.bool.isRequired,selected:c.bool,showDaysOutsideCurrentMonth:c.bool,style:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),tabIndex:c.number,today:c.bool,TouchRippleProps:c.object,touchRippleRef:c.oneOfType([c.func,c.shape({current:c.shape({pulsate:c.func.isRequired,start:c.func.isRequired,stop:c.func.isRequired})})])});const wW=I.memo(iT),_W=t=>Ke("MuiPickersSlideTransition",t),Rr=qe("MuiPickersSlideTransition",["root","slideEnter-left","slideEnter-right","slideEnterActive","slideExit","slideExitActiveLeft-left","slideExitActiveLeft-right"]),TW=["children","className","reduceAnimations","slideDirection","transKey","classes"],kW=t=>{const{classes:e,slideDirection:n}=t,r={root:["root"],exit:["slideExit"],enterActive:["slideEnterActive"],enter:[`slideEnter-${n}`],exitActive:[`slideExitActiveLeft-${n}`]};return Ue(r,_W,e)},EW=be(jl,{name:"MuiPickersSlideTransition",slot:"Root",overridesResolver:(t,e)=>[e.root,{[`.${Rr["slideEnter-left"]}`]:e["slideEnter-left"]},{[`.${Rr["slideEnter-right"]}`]:e["slideEnter-right"]},{[`.${Rr.slideEnterActive}`]:e.slideEnterActive},{[`.${Rr.slideExit}`]:e.slideExit},{[`.${Rr["slideExitActiveLeft-left"]}`]:e["slideExitActiveLeft-left"]},{[`.${Rr["slideExitActiveLeft-right"]}`]:e["slideExitActiveLeft-right"]}]})(({theme:t})=>{const e=t.transitions.create("transform",{duration:t.transitions.duration.complex,easing:"cubic-bezier(0.35, 0.8, 0.4, 1)"});return{display:"block",position:"relative",overflowX:"hidden","& > *":{position:"absolute",top:0,right:0,left:0},[`& .${Rr["slideEnter-left"]}`]:{willChange:"transform",transform:"translate(100%)",zIndex:1},[`& .${Rr["slideEnter-right"]}`]:{willChange:"transform",transform:"translate(-100%)",zIndex:1},[`& .${Rr.slideEnterActive}`]:{transform:"translate(0%)",transition:e},[`& .${Rr.slideExit}`]:{transform:"translate(0%)"},[`& .${Rr["slideExitActiveLeft-left"]}`]:{willChange:"transform",transform:"translate(-100%)",transition:e,zIndex:0},[`& .${Rr["slideExitActiveLeft-right"]}`]:{willChange:"transform",transform:"translate(100%)",transition:e,zIndex:0}}});function MW(t){const e=Wt({props:t,name:"MuiPickersSlideTransition"}),{children:n,className:r,reduceAnimations:o,transKey:i}=e,s=rt(e,TW),a=kW(e),l=Si();if(o)return v.jsx("div",{className:Le(a.root,r),children:n});const u={exit:a.exit,enterActive:a.enterActive,enter:a.enter,exitActive:a.exitActive};return v.jsx(EW,{className:Le(a.root,r),childFactory:f=>I.cloneElement(f,{classNames:u}),role:"presentation",children:v.jsx(bg,ne({mountOnEnter:!0,unmountOnExit:!0,timeout:l.transitions.duration.complex,classNames:u},s,{children:n}),i)})}const OW=t=>Ke("MuiDayCalendar",t);qe("MuiDayCalendar",["root","header","weekDayLabel","loadingContainer","slideTransition","monthContainer","weekContainer","weekNumberLabel","weekNumber"]);const AW=["parentProps","day","focusableDay","selectedDays","isDateDisabled","currentMonthNumber","isViewFocused"],IW=["ownerState"],DW=t=>{const{classes:e}=t;return Ue({root:["root"],header:["header"],weekDayLabel:["weekDayLabel"],loadingContainer:["loadingContainer"],slideTransition:["slideTransition"],monthContainer:["monthContainer"],weekContainer:["weekContainer"],weekNumberLabel:["weekNumberLabel"],weekNumber:["weekNumber"]},OW,e)},sT=(uc+Dd*2)*6,PW=be("div",{name:"MuiDayCalendar",slot:"Root",overridesResolver:(t,e)=>e.root})({}),NW=be("div",{name:"MuiDayCalendar",slot:"Header",overridesResolver:(t,e)=>e.header})({display:"flex",justifyContent:"center",alignItems:"center"}),LW=be(Ti,{name:"MuiDayCalendar",slot:"WeekDayLabel",overridesResolver:(t,e)=>e.weekDayLabel})(({theme:t})=>({width:36,height:40,margin:"0 2px",textAlign:"center",display:"flex",justifyContent:"center",alignItems:"center",color:(t.vars||t).palette.text.secondary})),FW=be(Ti,{name:"MuiDayCalendar",slot:"WeekNumberLabel",overridesResolver:(t,e)=>e.weekNumberLabel})(({theme:t})=>({width:36,height:40,margin:"0 2px",textAlign:"center",display:"flex",justifyContent:"center",alignItems:"center",color:t.palette.text.disabled})),$W=be(Ti,{name:"MuiDayCalendar",slot:"WeekNumber",overridesResolver:(t,e)=>e.weekNumber})(({theme:t})=>ne({},t.typography.caption,{width:uc,height:uc,padding:0,margin:`0 ${Dd}px`,color:t.palette.text.disabled,fontSize:"0.75rem",alignItems:"center",justifyContent:"center",display:"inline-flex"})),BW=be("div",{name:"MuiDayCalendar",slot:"LoadingContainer",overridesResolver:(t,e)=>e.loadingContainer})({display:"flex",justifyContent:"center",alignItems:"center",minHeight:sT}),RW=be(MW,{name:"MuiDayCalendar",slot:"SlideTransition",overridesResolver:(t,e)=>e.slideTransition})({minHeight:sT}),zW=be("div",{name:"MuiDayCalendar",slot:"MonthContainer",overridesResolver:(t,e)=>e.monthContainer})({overflow:"hidden"}),VW=be("div",{name:"MuiDayCalendar",slot:"WeekContainer",overridesResolver:(t,e)=>e.weekContainer})({margin:`${Dd}px 0`,display:"flex",justifyContent:"center"});function HW(t){let{parentProps:e,day:n,focusableDay:r,selectedDays:o,isDateDisabled:i,currentMonthNumber:s,isViewFocused:a}=t,l=rt(t,AW);const{disabled:u,disableHighlightToday:f,isMonthSwitchingAnimating:p,showDaysOutsideCurrentMonth:g,slots:m,slotProps:y,timezone:b}=e,S=qt(),C=xd(b),T=r!==null&&S.isSameDay(n,r),_=o.some(N=>S.isSameDay(N,n)),w=S.isSameDay(n,C),E=(m==null?void 0:m.day)??wW,O=wt({elementType:E,externalSlotProps:y==null?void 0:y.day,additionalProps:ne({disableHighlightToday:f,showDaysOutsideCurrentMonth:g,role:"gridcell",isAnimating:p,"data-timestamp":S.toJsDate(n).valueOf()},l),ownerState:ne({},e,{day:n,selected:_})}),L=rt(O,IW),P=I.useMemo(()=>u||i(n),[u,i,n]),$=I.useMemo(()=>S.getMonth(n)!==s,[S,n,s]),M=I.useMemo(()=>{const N=S.startOfMonth(S.setMonth(n,s));return g?S.isSameDay(n,S.startOfWeek(N)):S.isSameDay(n,N)},[s,n,g,S]),A=I.useMemo(()=>{const N=S.endOfMonth(S.setMonth(n,s));return g?S.isSameDay(n,S.endOfWeek(N)):S.isSameDay(n,N)},[s,n,g,S]);return v.jsx(E,ne({},L,{day:n,disabled:P,autoFocus:a&&T,today:w,outsideCurrentMonth:$,isFirstVisibleCell:M,isLastVisibleCell:A,selected:_,tabIndex:T?0:-1,"aria-selected":_,"aria-current":w?"date":void 0}))}function jW(t){const e=Wt({props:t,name:"MuiDayCalendar"}),n=qt(),{onFocusedDayChange:r,className:o,currentMonth:i,selectedDays:s,focusedDay:a,loading:l,onSelectedDaysChange:u,onMonthSwitchingAnimationEnd:f,readOnly:p,reduceAnimations:g,renderLoading:m=()=>v.jsx("span",{children:"..."}),slideDirection:y,TransitionProps:b,disablePast:S,disableFuture:C,minDate:T,maxDate:_,shouldDisableDate:w,shouldDisableMonth:E,shouldDisableYear:O,dayOfWeekFormatter:L=_e=>n.format(_e,"weekdayShort").charAt(0).toUpperCase(),hasFocus:P,onFocusedViewChange:$,gridLabelId:M,displayWeekNumber:A,fixedWeekNumber:N,autoFocus:V,timezone:R}=e,B=xd(R),z=DW(e),q=no(),K=tT({shouldDisableDate:w,shouldDisableMonth:E,shouldDisableYear:O,minDate:T,maxDate:_,disablePast:S,disableFuture:C,timezone:R}),G=Ko(),[Y,Z]=jo({name:"DayCalendar",state:"hasFocus",controlled:P,default:V??!1}),[me,he]=I.useState(()=>a||B),oe=Be(_e=>{p||u(_e)}),Q=_e=>{K(_e)||(r(_e),he(_e),$==null||$(!0),Z(!0))},fe=Be((_e,Se)=>{switch(_e.key){case"ArrowUp":Q(n.addDays(Se,-7)),_e.preventDefault();break;case"ArrowDown":Q(n.addDays(Se,7)),_e.preventDefault();break;case"ArrowLeft":{const Me=n.addDays(Se,q?1:-1),Fe=n.addMonths(Se,q?1:-1),je=Jl({utils:n,date:Me,minDate:q?Me:n.startOfMonth(Fe),maxDate:q?n.endOfMonth(Fe):Me,isDateDisabled:K,timezone:R});Q(je||Me),_e.preventDefault();break}case"ArrowRight":{const Me=n.addDays(Se,q?-1:1),Fe=n.addMonths(Se,q?-1:1),je=Jl({utils:n,date:Me,minDate:q?n.startOfMonth(Fe):Me,maxDate:q?Me:n.endOfMonth(Fe),isDateDisabled:K,timezone:R});Q(je||Me),_e.preventDefault();break}case"Home":Q(n.startOfWeek(Se)),_e.preventDefault();break;case"End":Q(n.endOfWeek(Se)),_e.preventDefault();break;case"PageUp":Q(n.addMonths(Se,1)),_e.preventDefault();break;case"PageDown":Q(n.addMonths(Se,-1)),_e.preventDefault();break}}),ce=Be((_e,Se)=>Q(Se)),ae=Be((_e,Se)=>{Y&&n.isSameDay(me,Se)&&($==null||$(!1))}),W=n.getMonth(i),te=n.getYear(i),ue=I.useMemo(()=>s.filter(_e=>!!_e).map(_e=>n.startOfDay(_e)),[n,s]),ee=`${te}-${W}`,se=I.useMemo(()=>I.createRef(),[ee]),de=I.useMemo(()=>{const _e=n.startOfMonth(i),Se=n.endOfMonth(i);return K(me)||n.isAfterDay(me,Se)||n.isBeforeDay(me,_e)?Jl({utils:n,date:me,minDate:_e,maxDate:Se,disablePast:S,disableFuture:C,isDateDisabled:K,timezone:R}):me},[i,C,S,me,K,n,R]),ye=I.useMemo(()=>{const _e=n.getWeekArray(i);let Se=n.addMonths(i,1);for(;N&&_e.length<N;){const Me=n.getWeekArray(Se),Fe=n.isSameDay(_e[_e.length-1][0],Me[0][0]);Me.slice(Fe?1:0).forEach(je=>{_e.length<N&&_e.push(je)}),Se=n.addMonths(Se,1)}return _e},[i,N,n]);return v.jsxs(PW,{role:"grid","aria-labelledby":M,className:z.root,children:[v.jsxs(NW,{role:"row",className:z.header,children:[A&&v.jsx(FW,{variant:"caption",role:"columnheader","aria-label":G.calendarWeekNumberHeaderLabel,className:z.weekNumberLabel,children:G.calendarWeekNumberHeaderText}),v4(n,B).map((_e,Se)=>v.jsx(LW,{variant:"caption",role:"columnheader","aria-label":n.format(_e,"weekday"),className:z.weekDayLabel,children:L(_e)},Se.toString()))]}),l?v.jsx(BW,{className:z.loadingContainer,children:m()}):v.jsx(RW,ne({transKey:ee,onExited:f,reduceAnimations:g,slideDirection:y,className:Le(o,z.slideTransition)},b,{nodeRef:se,children:v.jsx(zW,{ref:se,role:"rowgroup",className:z.monthContainer,children:ye.map((_e,Se)=>v.jsxs(VW,{role:"row",className:z.weekContainer,"aria-rowindex":Se+1,children:[A&&v.jsx($W,{className:z.weekNumber,role:"rowheader","aria-label":G.calendarWeekNumberAriaLabelText(n.getWeekNumber(_e[0])),children:G.calendarWeekNumberText(n.getWeekNumber(_e[0]))}),_e.map((Me,Fe)=>v.jsx(HW,{parentProps:e,day:Me,selectedDays:ue,focusableDay:de,onKeyDown:fe,onFocus:ce,onBlur:ae,onDaySelect:oe,isDateDisabled:K,currentMonthNumber:W,isViewFocused:Y,"aria-colindex":Fe+1},Me.toString()))]},`week-${_e[0]}`))})}))]})}function WW(t){return Ke("MuiPickersMonth",t)}const Nd=qe("MuiPickersMonth",["root","monthButton","disabled","selected"]),qW=["autoFocus","className","children","disabled","selected","value","tabIndex","onClick","onKeyDown","onFocus","onBlur","aria-current","aria-label","monthsPerRow","slots","slotProps"],UW=t=>{const{disabled:e,selected:n,classes:r}=t;return Ue({root:["root"],monthButton:["monthButton",e&&"disabled",n&&"selected"]},WW,r)},KW=be("div",{name:"MuiPickersMonth",slot:"Root",overridesResolver:(t,e)=>[e.root]})({display:"flex",alignItems:"center",justifyContent:"center",flexBasis:"33.3%",variants:[{props:{monthsPerRow:4},style:{flexBasis:"25%"}}]}),YW=be("button",{name:"MuiPickersMonth",slot:"MonthButton",overridesResolver:(t,e)=>[e.monthButton,{[`&.${Nd.disabled}`]:e.disabled},{[`&.${Nd.selected}`]:e.selected}]})(({theme:t})=>ne({color:"unset",backgroundColor:"transparent",border:0,outline:0},t.typography.subtitle1,{margin:"8px 0",height:36,width:72,borderRadius:18,cursor:"pointer","&:focus":{backgroundColor:t.vars?`rgba(${t.vars.palette.action.activeChannel} / ${t.vars.palette.action.hoverOpacity})`:Rt(t.palette.action.active,t.palette.action.hoverOpacity)},"&:hover":{backgroundColor:t.vars?`rgba(${t.vars.palette.action.activeChannel} / ${t.vars.palette.action.hoverOpacity})`:Rt(t.palette.action.active,t.palette.action.hoverOpacity)},"&:disabled":{cursor:"auto",pointerEvents:"none"},[`&.${Nd.disabled}`]:{color:(t.vars||t).palette.text.secondary},[`&.${Nd.selected}`]:{color:(t.vars||t).palette.primary.contrastText,backgroundColor:(t.vars||t).palette.primary.main,"&:focus, &:hover":{backgroundColor:(t.vars||t).palette.primary.dark}}})),GW=I.memo(function(e){const n=Wt({props:e,name:"MuiPickersMonth"}),{autoFocus:r,className:o,children:i,disabled:s,selected:a,value:l,tabIndex:u,onClick:f,onKeyDown:p,onFocus:g,onBlur:m,"aria-current":y,"aria-label":b,slots:S,slotProps:C}=n,T=rt(n,qW),_=I.useRef(null),w=UW(n);Tn(()=>{var L;r&&((L=_.current)==null||L.focus())},[r]);const E=(S==null?void 0:S.monthButton)??YW,O=wt({elementType:E,externalSlotProps:C==null?void 0:C.monthButton,additionalProps:{children:i,disabled:s,tabIndex:u,ref:_,type:"button",role:"radio","aria-current":y,"aria-checked":a,"aria-label":b,onClick:L=>f(L,l),onKeyDown:L=>p(L,l),onFocus:L=>g(L,l),onBlur:L=>m(L,l)},ownerState:n,className:w.monthButton});return v.jsx(KW,ne({className:Le(w.root,o),ownerState:n},T,{children:v.jsx(E,ne({},O))}))});function JW(t){return Ke("MuiMonthCalendar",t)}qe("MuiMonthCalendar",["root"]);const ZW=["className","value","defaultValue","referenceDate","disabled","disableFuture","disablePast","maxDate","minDate","onChange","shouldDisableMonth","readOnly","disableHighlightToday","autoFocus","onMonthFocus","hasFocus","onFocusedViewChange","monthsPerRow","timezone","gridLabelId","slots","slotProps"],XW=t=>{const{classes:e}=t;return Ue({root:["root"]},JW,e)};function QW(t,e){const n=qt(),r=Ql(),o=Wt({props:t,name:e});return ne({disableFuture:!1,disablePast:!1},o,{minDate:Nr(n,o.minDate,r.minDate),maxDate:Nr(n,o.maxDate,r.maxDate)})}const e9=be("div",{name:"MuiMonthCalendar",slot:"Root",overridesResolver:(t,e)=>e.root})({display:"flex",flexWrap:"wrap",alignContent:"stretch",padding:"0 4px",width:Pd,boxSizing:"border-box"}),aT=I.forwardRef(function(e,n){const r=QW(e,"MuiMonthCalendar"),{className:o,value:i,defaultValue:s,referenceDate:a,disabled:l,disableFuture:u,disablePast:f,maxDate:p,minDate:g,onChange:m,shouldDisableMonth:y,readOnly:b,autoFocus:S=!1,onMonthFocus:C,hasFocus:T,onFocusedViewChange:_,monthsPerRow:w=3,timezone:E,gridLabelId:O,slots:L,slotProps:P}=r,$=rt(r,ZW),{value:M,handleValueChange:A,timezone:N}=Lg({name:"MonthCalendar",timezone:E,value:i,defaultValue:s,referenceDate:a,onChange:m,valueManager:wo}),V=xd(N),R=no(),B=qt(),z=I.useMemo(()=>wo.getInitialReferenceValue({value:M,utils:B,props:r,timezone:N,referenceDate:a,granularity:Co.month}),[]),q=r,K=XW(q),G=I.useMemo(()=>B.getMonth(V),[B,V]),Y=I.useMemo(()=>M!=null?B.getMonth(M):null,[M,B]),[Z,me]=I.useState(()=>Y||B.getMonth(z)),[he,oe]=jo({name:"MonthCalendar",state:"hasFocus",controlled:T,default:S??!1}),Q=Be(ee=>{oe(ee),_&&_(ee)}),fe=I.useCallback(ee=>{const se=B.startOfMonth(f&&B.isAfter(V,g)?V:g),de=B.startOfMonth(u&&B.isBefore(V,p)?V:p),ye=B.startOfMonth(ee);return B.isBefore(ye,se)||B.isAfter(ye,de)?!0:y?y(ye):!1},[u,f,p,g,V,y,B]),ce=Be((ee,se)=>{if(b)return;const de=B.setMonth(M??z,se);A(de)}),ae=Be(ee=>{fe(B.setMonth(M??z,ee))||(me(ee),Q(!0),C&&C(ee))});I.useEffect(()=>{me(ee=>Y!==null&&ee!==Y?Y:ee)},[Y]);const W=Be((ee,se)=>{switch(ee.key){case"ArrowUp":ae((12+se-3)%12),ee.preventDefault();break;case"ArrowDown":ae((12+se+3)%12),ee.preventDefault();break;case"ArrowLeft":ae((12+se+(R?1:-1))%12),ee.preventDefault();break;case"ArrowRight":ae((12+se+(R?-1:1))%12),ee.preventDefault();break}}),te=Be((ee,se)=>{ae(se)}),ue=Be((ee,se)=>{Z===se&&Q(!1)});return v.jsx(e9,ne({ref:n,className:Le(K.root,o),ownerState:q,role:"radiogroup","aria-labelledby":O},$,{children:Mg(B,M??z).map(ee=>{const se=B.getMonth(ee),de=B.format(ee,"monthShort"),ye=B.format(ee,"month"),_e=se===Y,Se=l||fe(ee);return v.jsx(GW,{selected:_e,value:se,onClick:ce,onKeyDown:W,autoFocus:he&&se===Z,disabled:Se,tabIndex:se===Z&&!Se?0:-1,onFocus:te,onBlur:ue,"aria-current":G===se?"date":void 0,"aria-label":ye,monthsPerRow:w,slots:L,slotProps:P,children:de},de)})}))});process.env.NODE_ENV!=="production"&&(aT.propTypes={autoFocus:c.bool,classes:c.object,className:c.string,defaultValue:c.object,disabled:c.bool,disableFuture:c.bool,disableHighlightToday:c.bool,disablePast:c.bool,gridLabelId:c.string,hasFocus:c.bool,maxDate:c.object,minDate:c.object,monthsPerRow:c.oneOf([3,4]),onChange:c.func,onFocusedViewChange:c.func,onMonthFocus:c.func,readOnly:c.bool,referenceDate:c.object,shouldDisableMonth:c.func,slotProps:c.object,slots:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),timezone:c.string,value:c.object});function t9(t){return Ke("MuiPickersYear",t)}const Ld=qe("MuiPickersYear",["root","yearButton","selected","disabled"]),n9=["autoFocus","className","children","disabled","selected","value","tabIndex","onClick","onKeyDown","onFocus","onBlur","aria-current","yearsPerRow","slots","slotProps"],r9=t=>{const{disabled:e,selected:n,classes:r}=t;return Ue({root:["root"],yearButton:["yearButton",e&&"disabled",n&&"selected"]},t9,r)},o9=be("div",{name:"MuiPickersYear",slot:"Root",overridesResolver:(t,e)=>[e.root]})({display:"flex",alignItems:"center",justifyContent:"center",flexBasis:"33.3%",variants:[{props:{yearsPerRow:4},style:{flexBasis:"25%"}}]}),i9=be("button",{name:"MuiPickersYear",slot:"YearButton",overridesResolver:(t,e)=>[e.yearButton,{[`&.${Ld.disabled}`]:e.disabled},{[`&.${Ld.selected}`]:e.selected}]})(({theme:t})=>ne({color:"unset",backgroundColor:"transparent",border:0,outline:0},t.typography.subtitle1,{margin:"6px 0",height:36,width:72,borderRadius:18,cursor:"pointer","&:focus":{backgroundColor:t.vars?`rgba(${t.vars.palette.action.activeChannel} / ${t.vars.palette.action.focusOpacity})`:Rt(t.palette.action.active,t.palette.action.focusOpacity)},"&:hover":{backgroundColor:t.vars?`rgba(${t.vars.palette.action.activeChannel} / ${t.vars.palette.action.hoverOpacity})`:Rt(t.palette.action.active,t.palette.action.hoverOpacity)},"&:disabled":{cursor:"auto",pointerEvents:"none"},[`&.${Ld.disabled}`]:{color:(t.vars||t).palette.text.secondary},[`&.${Ld.selected}`]:{color:(t.vars||t).palette.primary.contrastText,backgroundColor:(t.vars||t).palette.primary.main,"&:focus, &:hover":{backgroundColor:(t.vars||t).palette.primary.dark}}})),s9=I.memo(function(e){const n=Wt({props:e,name:"MuiPickersYear"}),{autoFocus:r,className:o,children:i,disabled:s,selected:a,value:l,tabIndex:u,onClick:f,onKeyDown:p,onFocus:g,onBlur:m,"aria-current":y,slots:b,slotProps:S}=n,C=rt(n,n9),T=I.useRef(null),_=r9(n);Tn(()=>{var O;r&&((O=T.current)==null||O.focus())},[r]);const w=(b==null?void 0:b.yearButton)??i9,E=wt({elementType:w,externalSlotProps:S==null?void 0:S.yearButton,additionalProps:{children:i,disabled:s,tabIndex:u,ref:T,type:"button",role:"radio","aria-current":y,"aria-checked":a,onClick:O=>f(O,l),onKeyDown:O=>p(O,l),onFocus:O=>g(O,l),onBlur:O=>m(O,l)},ownerState:n,className:_.yearButton});return v.jsx(o9,ne({className:Le(_.root,o),ownerState:n},C,{children:v.jsx(w,ne({},E))}))});function a9(t){return Ke("MuiYearCalendar",t)}qe("MuiYearCalendar",["root"]);const l9=["autoFocus","className","value","defaultValue","referenceDate","disabled","disableFuture","disablePast","maxDate","minDate","onChange","readOnly","shouldDisableYear","disableHighlightToday","onYearFocus","hasFocus","onFocusedViewChange","yearsOrder","yearsPerRow","timezone","gridLabelId","slots","slotProps"],c9=t=>{const{classes:e}=t;return Ue({root:["root"]},a9,e)};function u9(t,e){const n=qt(),r=Ql(),o=Wt({props:t,name:e});return ne({disablePast:!1,disableFuture:!1},o,{yearsPerRow:o.yearsPerRow??3,minDate:Nr(n,o.minDate,r.minDate),maxDate:Nr(n,o.maxDate,r.maxDate)})}const d9=be("div",{name:"MuiYearCalendar",slot:"Root",overridesResolver:(t,e)=>e.root})({display:"flex",flexDirection:"row",flexWrap:"wrap",overflowY:"auto",height:"100%",padding:"0 4px",width:Pd,maxHeight:eW,boxSizing:"border-box",position:"relative"}),lT=I.forwardRef(function(e,n){const r=u9(e,"MuiYearCalendar"),{autoFocus:o,className:i,value:s,defaultValue:a,referenceDate:l,disabled:u,disableFuture:f,disablePast:p,maxDate:g,minDate:m,onChange:y,readOnly:b,shouldDisableYear:S,onYearFocus:C,hasFocus:T,onFocusedViewChange:_,yearsOrder:w="asc",yearsPerRow:E,timezone:O,gridLabelId:L,slots:P,slotProps:$}=r,M=rt(r,l9),{value:A,handleValueChange:N,timezone:V}=Lg({name:"YearCalendar",timezone:O,value:s,defaultValue:a,referenceDate:l,onChange:y,valueManager:wo}),R=xd(V),B=no(),z=qt(),q=I.useMemo(()=>wo.getInitialReferenceValue({value:A,utils:z,props:r,timezone:V,referenceDate:l,granularity:Co.year}),[]),K=r,G=c9(K),Y=I.useMemo(()=>z.getYear(R),[z,R]),Z=I.useMemo(()=>A!=null?z.getYear(A):null,[A,z]),[me,he]=I.useState(()=>Z||z.getYear(q)),[oe,Q]=jo({name:"YearCalendar",state:"hasFocus",controlled:T,default:o??!1}),fe=Be(Me=>{Q(Me),_&&_(Me)}),ce=I.useCallback(Me=>{if(p&&z.isBeforeYear(Me,R)||f&&z.isAfterYear(Me,R)||m&&z.isBeforeYear(Me,m)||g&&z.isAfterYear(Me,g))return!0;if(!S)return!1;const Fe=z.startOfYear(Me);return S(Fe)},[f,p,g,m,R,S,z]),ae=Be((Me,Fe)=>{if(b)return;const je=z.setYear(A??q,Fe);N(je)}),W=Be(Me=>{ce(z.setYear(A??q,Me))||(he(Me),fe(!0),C==null||C(Me))});I.useEffect(()=>{he(Me=>Z!==null&&Me!==Z?Z:Me)},[Z]);const te=w!=="desc"?E*1:E*-1,ue=B&&w==="asc"||!B&&w==="desc"?-1:1,ee=Be((Me,Fe)=>{switch(Me.key){case"ArrowUp":W(Fe-te),Me.preventDefault();break;case"ArrowDown":W(Fe+te),Me.preventDefault();break;case"ArrowLeft":W(Fe-ue),Me.preventDefault();break;case"ArrowRight":W(Fe+ue),Me.preventDefault();break}}),se=Be((Me,Fe)=>{W(Fe)}),de=Be((Me,Fe)=>{me===Fe&&fe(!1)}),ye=I.useRef(null),_e=Et(n,ye);I.useEffect(()=>{if(o||ye.current===null)return;const Me=ye.current.querySelector('[tabindex="0"]');if(!Me)return;const Fe=Me.offsetHeight,je=Me.offsetTop,Je=ye.current.clientHeight,De=ye.current.scrollTop,ct=je+Fe;Fe>Je||je<De||(ye.current.scrollTop=ct-Je/2-Fe/2)},[o]);const Se=z.getYearRange([m,g]);return w==="desc"&&Se.reverse(),v.jsx(d9,ne({ref:_e,className:Le(G.root,i),ownerState:K,role:"radiogroup","aria-labelledby":L},M,{children:Se.map(Me=>{const Fe=z.getYear(Me),je=Fe===Z,Je=u||ce(Me);return v.jsx(s9,{selected:je,value:Fe,onClick:ae,onKeyDown:ee,autoFocus:oe&&Fe===me,disabled:Je,tabIndex:Fe===me&&!Je?0:-1,onFocus:se,onBlur:de,"aria-current":Y===Fe?"date":void 0,yearsPerRow:E,slots:P,slotProps:$,children:z.format(Me,"year")},z.format(Me,"year"))})}))});process.env.NODE_ENV!=="production"&&(lT.propTypes={autoFocus:c.bool,classes:c.object,className:c.string,defaultValue:c.object,disabled:c.bool,disableFuture:c.bool,disableHighlightToday:c.bool,disablePast:c.bool,gridLabelId:c.string,hasFocus:c.bool,maxDate:c.object,minDate:c.object,onChange:c.func,onFocusedViewChange:c.func,onYearFocus:c.func,readOnly:c.bool,referenceDate:c.object,shouldDisableYear:c.func,slotProps:c.object,slots:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),timezone:c.string,value:c.object,yearsOrder:c.oneOf(["asc","desc"]),yearsPerRow:c.oneOf([3,4])});const f9=t=>Ke("MuiPickersCalendarHeader",t),p9=qe("MuiPickersCalendarHeader",["root","labelContainer","label","switchViewButton","switchViewIcon"]);function h9(t){return Ke("MuiPickersArrowSwitcher",t)}qe("MuiPickersArrowSwitcher",["root","spacer","button","previousIconButton","nextIconButton","leftArrowIcon","rightArrowIcon"]);const g9=["children","className","slots","slotProps","isNextDisabled","isNextHidden","onGoToNext","nextLabel","isPreviousDisabled","isPreviousHidden","onGoToPrevious","previousLabel","labelId"],m9=["ownerState"],y9=["ownerState"],b9=be("div",{name:"MuiPickersArrowSwitcher",slot:"Root",overridesResolver:(t,e)=>e.root})({display:"flex"}),v9=be("div",{name:"MuiPickersArrowSwitcher",slot:"Spacer",overridesResolver:(t,e)=>e.spacer})(({theme:t})=>({width:t.spacing(3)})),cT=be(Sa,{name:"MuiPickersArrowSwitcher",slot:"Button",overridesResolver:(t,e)=>e.button})({variants:[{props:{hidden:!0},style:{visibility:"hidden"}}]}),x9=t=>{const{classes:e}=t;return Ue({root:["root"],spacer:["spacer"],button:["button"],previousIconButton:["previousIconButton"],nextIconButton:["nextIconButton"],leftArrowIcon:["leftArrowIcon"],rightArrowIcon:["rightArrowIcon"]},h9,e)},S9=I.forwardRef(function(e,n){const r=no(),o=Wt({props:e,name:"MuiPickersArrowSwitcher"}),{children:i,className:s,slots:a,slotProps:l,isNextDisabled:u,isNextHidden:f,onGoToNext:p,nextLabel:g,isPreviousDisabled:m,isPreviousHidden:y,onGoToPrevious:b,previousLabel:S,labelId:C}=o,T=rt(o,g9),_=o,w=x9(_),E={isDisabled:u,isHidden:f,goTo:p,label:g},O={isDisabled:m,isHidden:y,goTo:b,label:S},L=(a==null?void 0:a.previousIconButton)??cT,P=wt({elementType:L,externalSlotProps:l==null?void 0:l.previousIconButton,additionalProps:{size:"medium",title:O.label,"aria-label":O.label,disabled:O.isDisabled,edge:"end",onClick:O.goTo},ownerState:ne({},_,{hidden:O.isHidden}),className:Le(w.button,w.previousIconButton)}),$=(a==null?void 0:a.nextIconButton)??cT,M=wt({elementType:$,externalSlotProps:l==null?void 0:l.nextIconButton,additionalProps:{size:"medium",title:E.label,"aria-label":E.label,disabled:E.isDisabled,edge:"start",onClick:E.goTo},ownerState:ne({},_,{hidden:E.isHidden}),className:Le(w.button,w.nextIconButton)}),A=(a==null?void 0:a.leftArrowIcon)??zV,N=wt({elementType:A,externalSlotProps:l==null?void 0:l.leftArrowIcon,additionalProps:{fontSize:"inherit"},ownerState:_,className:w.leftArrowIcon}),V=rt(N,m9),R=(a==null?void 0:a.rightArrowIcon)??VV,B=wt({elementType:R,externalSlotProps:l==null?void 0:l.rightArrowIcon,additionalProps:{fontSize:"inherit"},ownerState:_,className:w.rightArrowIcon}),z=rt(B,y9);return v.jsxs(b9,ne({ref:n,className:Le(w.root,s),ownerState:_},T,{children:[v.jsx(L,ne({},P,{children:r?v.jsx(R,ne({},z)):v.jsx(A,ne({},V))})),i?v.jsx(Ti,{variant:"subtitle1",component:"span",id:C,children:i}):v.jsx(v9,{className:w.spacer,ownerState:_}),v.jsx($,ne({},M,{children:r?v.jsx(A,ne({},V)):v.jsx(R,ne({},z))}))]}))});function C9(t,{disableFuture:e,maxDate:n,timezone:r}){const o=qt();return I.useMemo(()=>{const i=o.date(void 0,r),s=o.startOfMonth(e&&o.isBefore(i,n)?i:n);return!o.isAfter(s,t)},[e,n,t,o,r])}function w9(t,{disablePast:e,minDate:n,timezone:r}){const o=qt();return I.useMemo(()=>{const i=o.date(void 0,r),s=o.startOfMonth(e&&o.isAfter(i,n)?i:n);return!o.isBefore(s,t)},[e,n,t,o,r])}const _9=["slots","slotProps","currentMonth","disabled","disableFuture","disablePast","maxDate","minDate","onMonthChange","onViewChange","view","reduceAnimations","views","labelId","className","timezone","format"],T9=["ownerState"],k9=t=>{const{classes:e}=t;return Ue({root:["root"],labelContainer:["labelContainer"],label:["label"],switchViewButton:["switchViewButton"],switchViewIcon:["switchViewIcon"]},f9,e)},E9=be("div",{name:"MuiPickersCalendarHeader",slot:"Root",overridesResolver:(t,e)=>e.root})({display:"flex",alignItems:"center",marginTop:12,marginBottom:4,paddingLeft:24,paddingRight:12,maxHeight:40,minHeight:40}),M9=be("div",{name:"MuiPickersCalendarHeader",slot:"LabelContainer",overridesResolver:(t,e)=>e.labelContainer})(({theme:t})=>ne({display:"flex",overflow:"hidden",alignItems:"center",cursor:"pointer",marginRight:"auto"},t.typography.body1,{fontWeight:t.typography.fontWeightMedium})),O9=be("div",{name:"MuiPickersCalendarHeader",slot:"Label",overridesResolver:(t,e)=>e.label})({marginRight:6}),A9=be(Sa,{name:"MuiPickersCalendarHeader",slot:"SwitchViewButton",overridesResolver:(t,e)=>e.switchViewButton})({marginRight:"auto",variants:[{props:{view:"year"},style:{[`.${p9.switchViewIcon}`]:{transform:"rotate(180deg)"}}}]}),I9=be(RV,{name:"MuiPickersCalendarHeader",slot:"SwitchViewIcon",overridesResolver:(t,e)=>e.switchViewIcon})(({theme:t})=>({willChange:"transform",transition:t.transitions.create("transform"),transform:"rotate(0deg)"})),uT=I.forwardRef(function(e,n){const r=Ko(),o=qt(),i=Wt({props:e,name:"MuiPickersCalendarHeader"}),{slots:s,slotProps:a,currentMonth:l,disabled:u,disableFuture:f,disablePast:p,maxDate:g,minDate:m,onMonthChange:y,onViewChange:b,view:S,reduceAnimations:C,views:T,labelId:_,className:w,timezone:E,format:O=`${o.formats.month} ${o.formats.year}`}=i,L=rt(i,_9),P=i,$=k9(i),M=(s==null?void 0:s.switchViewButton)??A9,A=wt({elementType:M,externalSlotProps:a==null?void 0:a.switchViewButton,additionalProps:{size:"small","aria-label":r.calendarViewSwitchingButtonAriaLabel(S)},ownerState:P,className:$.switchViewButton}),N=(s==null?void 0:s.switchViewIcon)??I9,V=wt({elementType:N,externalSlotProps:a==null?void 0:a.switchViewIcon,ownerState:P,className:$.switchViewIcon}),R=rt(V,T9),B=()=>y(o.addMonths(l,1),"left"),z=()=>y(o.addMonths(l,-1),"right"),q=C9(l,{disableFuture:f,maxDate:g,timezone:E}),K=w9(l,{disablePast:p,minDate:m,timezone:E}),G=()=>{if(!(T.length===1||!b||u))if(T.length===2)b(T.find(Z=>Z!==S)||T[0]);else{const Z=T.indexOf(S)!==0?0:1;b(T[Z])}};if(T.length===1&&T[0]==="year")return null;const Y=o.formatByString(l,O);return v.jsxs(E9,ne({},L,{ownerState:P,className:Le($.root,w),ref:n,children:[v.jsxs(M9,{role:"presentation",onClick:G,ownerState:P,"aria-live":"polite",className:$.labelContainer,children:[v.jsx(nT,{reduceAnimations:C,transKey:Y,children:v.jsx(O9,{id:_,ownerState:P,className:$.label,children:Y})}),T.length>1&&!u&&v.jsx(M,ne({},A,{children:v.jsx(N,ne({},R))}))]}),v.jsx(wi,{in:S==="day",children:v.jsx(S9,{slots:s,slotProps:a,onGoToPrevious:z,isPreviousDisabled:K,previousLabel:r.previousMonth,onGoToNext:B,isNextDisabled:q,nextLabel:r.nextMonth})})]}))});process.env.NODE_ENV!=="production"&&(uT.propTypes={classes:c.object,className:c.string,currentMonth:c.object.isRequired,disabled:c.bool,disableFuture:c.bool,disablePast:c.bool,format:c.string,labelId:c.string,maxDate:c.object.isRequired,minDate:c.object.isRequired,onMonthChange:c.func.isRequired,onViewChange:c.func,reduceAnimations:c.bool.isRequired,slotProps:c.object,slots:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),timezone:c.string.isRequired,view:c.oneOf(["day","month","year"]).isRequired,views:c.arrayOf(c.oneOf(["day","month","year"]).isRequired).isRequired});const D9=be("div")({overflow:"hidden",width:Pd,maxHeight:nm,display:"flex",flexDirection:"column",margin:"0 auto"}),P9=t=>Ke("MuiDateCalendar",t);qe("MuiDateCalendar",["root","viewTransitionContainer"]);const N9=["autoFocus","onViewChange","value","defaultValue","referenceDate","disableFuture","disablePast","onChange","onYearChange","onMonthChange","reduceAnimations","shouldDisableDate","shouldDisableMonth","shouldDisableYear","view","views","openTo","className","disabled","readOnly","minDate","maxDate","disableHighlightToday","focusedView","onFocusedViewChange","showDaysOutsideCurrentMonth","fixedWeekNumber","dayOfWeekFormatter","slots","slotProps","loading","renderLoading","displayWeekNumber","yearsOrder","yearsPerRow","monthsPerRow","timezone"],L9=t=>{const{classes:e}=t;return Ue({root:["root"],viewTransitionContainer:["viewTransitionContainer"]},P9,e)};function F9(t,e){const n=qt(),r=Ql(),o=z_(),i=Wt({props:t,name:e});return ne({},i,{loading:i.loading??!1,disablePast:i.disablePast??!1,disableFuture:i.disableFuture??!1,openTo:i.openTo??"day",views:i.views??["year","day"],reduceAnimations:i.reduceAnimations??o,renderLoading:i.renderLoading??(()=>v.jsx("span",{children:"..."})),minDate:Nr(n,i.minDate,r.minDate),maxDate:Nr(n,i.maxDate,r.maxDate)})}const $9=be(D9,{name:"MuiDateCalendar",slot:"Root",overridesResolver:(t,e)=>e.root})({display:"flex",flexDirection:"column",height:nm}),B9=be(nT,{name:"MuiDateCalendar",slot:"ViewTransitionContainer",overridesResolver:(t,e)=>e.viewTransitionContainer})({}),dT=I.forwardRef(function(e,n){const r=qt(),o=vo(),i=F9(e,"MuiDateCalendar"),{autoFocus:s,onViewChange:a,value:l,defaultValue:u,referenceDate:f,disableFuture:p,disablePast:g,onChange:m,onYearChange:y,onMonthChange:b,reduceAnimations:S,shouldDisableDate:C,shouldDisableMonth:T,shouldDisableYear:_,view:w,views:E,openTo:O,className:L,disabled:P,readOnly:$,minDate:M,maxDate:A,disableHighlightToday:N,focusedView:V,onFocusedViewChange:R,showDaysOutsideCurrentMonth:B,fixedWeekNumber:z,dayOfWeekFormatter:q,slots:K,slotProps:G,loading:Y,renderLoading:Z,displayWeekNumber:me,yearsOrder:he,yearsPerRow:oe,monthsPerRow:Q,timezone:fe}=i,ce=rt(i,N9),{value:ae,handleValueChange:W,timezone:te}=Lg({name:"DateCalendar",timezone:fe,value:l,defaultValue:u,referenceDate:f,onChange:m,valueManager:wo}),{view:ue,setView:ee,focusedView:se,setFocusedView:de,goToNextView:ye,setValueAndGoToNextView:_e}=V_({view:w,views:E,openTo:O,onChange:W,onViewChange:a,autoFocus:s,focusedView:V,onFocusedViewChange:R}),{referenceDate:Se,calendarState:Me,changeFocusedDay:Fe,changeMonth:je,handleChangeMonth:Je,isDateDisabled:De,onMonthSwitchingAnimationEnd:ct}=hW({value:ae,referenceDate:f,reduceAnimations:S,onMonthChange:b,minDate:M,maxDate:A,shouldDisableDate:C,disablePast:g,disableFuture:p,timezone:te}),Ct=P&&ae||M,Xt=P&&ae||A,Sn=`${o}-grid-label`,un=se!==null,$t=(K==null?void 0:K.calendarHeader)??uT,In=wt({elementType:$t,externalSlotProps:G==null?void 0:G.calendarHeader,additionalProps:{views:E,view:ue,currentMonth:Me.currentMonth,onViewChange:ee,onMonthChange:(nt,Pt)=>Je({newMonth:nt,direction:Pt}),minDate:Ct,maxDate:Xt,disabled:P,disablePast:g,disableFuture:p,reduceAnimations:S,timezone:te,labelId:Sn},ownerState:i}),Kn=Be(nt=>{const Pt=r.startOfMonth(nt),rr=r.endOfMonth(nt),hr=De(nt)?Jl({utils:r,date:nt,minDate:r.isBefore(M,Pt)?Pt:M,maxDate:r.isAfter(A,rr)?rr:A,disablePast:g,disableFuture:p,isDateDisabled:De,timezone:te}):nt;hr?(_e(hr,"finish"),b==null||b(Pt)):(ye(),je(Pt)),Fe(hr,!0)}),ft=Be(nt=>{const Pt=r.startOfYear(nt),rr=r.endOfYear(nt),hr=De(nt)?Jl({utils:r,date:nt,minDate:r.isBefore(M,Pt)?Pt:M,maxDate:r.isAfter(A,rr)?rr:A,disablePast:g,disableFuture:p,isDateDisabled:De,timezone:te}):nt;hr?(_e(hr,"finish"),y==null||y(hr)):(ye(),je(Pt)),Fe(hr,!0)}),$n=Be(nt=>W(nt&&bd(r,nt,ae??Se),"finish",ue));I.useEffect(()=>{ae!=null&&r.isValid(ae)&&je(ae)},[ae]);const Yt=i,ge=L9(Yt),$e={disablePast:g,disableFuture:p,maxDate:A,minDate:M},ke={disableHighlightToday:N,readOnly:$,disabled:P,timezone:te,gridLabelId:Sn,slots:K,slotProps:G},Re=I.useRef(ue);I.useEffect(()=>{Re.current!==ue&&(se===Re.current&&de(ue,!0),Re.current=ue)},[se,de,ue]);const Ge=I.useMemo(()=>[ae],[ae]);return v.jsxs($9,ne({ref:n,className:Le(ge.root,L),ownerState:Yt},ce,{children:[v.jsx($t,ne({},In,{slots:K,slotProps:G})),v.jsx(B9,{reduceAnimations:S,className:ge.viewTransitionContainer,transKey:ue,ownerState:Yt,children:v.jsxs("div",{children:[ue==="year"&&v.jsx(lT,ne({},$e,ke,{value:ae,onChange:ft,shouldDisableYear:_,hasFocus:un,onFocusedViewChange:nt=>de("year",nt),yearsOrder:he,yearsPerRow:oe,referenceDate:Se})),ue==="month"&&v.jsx(aT,ne({},$e,ke,{hasFocus:un,className:L,value:ae,onChange:Kn,shouldDisableMonth:T,onFocusedViewChange:nt=>de("month",nt),monthsPerRow:Q,referenceDate:Se})),ue==="day"&&v.jsx(jW,ne({},Me,$e,ke,{onMonthSwitchingAnimationEnd:ct,onFocusedDayChange:Fe,reduceAnimations:S,selectedDays:Ge,onSelectedDaysChange:$n,shouldDisableDate:C,shouldDisableMonth:T,shouldDisableYear:_,hasFocus:un,onFocusedViewChange:nt=>de("day",nt),showDaysOutsideCurrentMonth:B,fixedWeekNumber:z,dayOfWeekFormatter:q,displayWeekNumber:me,loading:Y,renderLoading:Z}))]})})]}))});process.env.NODE_ENV!=="production"&&(dT.propTypes={autoFocus:c.bool,classes:c.object,className:c.string,dayOfWeekFormatter:c.func,defaultValue:c.object,disabled:c.bool,disableFuture:c.bool,disableHighlightToday:c.bool,disablePast:c.bool,displayWeekNumber:c.bool,fixedWeekNumber:c.number,focusedView:c.oneOf(["day","month","year"]),loading:c.bool,maxDate:c.object,minDate:c.object,monthsPerRow:c.oneOf([3,4]),onChange:c.func,onFocusedViewChange:c.func,onMonthChange:c.func,onViewChange:c.func,onYearChange:c.func,openTo:c.oneOf(["day","month","year"]),readOnly:c.bool,reduceAnimations:c.bool,referenceDate:c.object,renderLoading:c.func,shouldDisableDate:c.func,shouldDisableMonth:c.func,shouldDisableYear:c.func,showDaysOutsideCurrentMonth:c.bool,slotProps:c.object,slots:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),timezone:c.string,value:c.object,view:c.oneOf(["day","month","year"]),views:c.arrayOf(c.oneOf(["day","month","year"]).isRequired),yearsOrder:c.oneOf(["asc","desc"]),yearsPerRow:c.oneOf([3,4])});const Ma=({view:t,onViewChange:e,views:n,focusedView:r,onFocusedViewChange:o,value:i,defaultValue:s,referenceDate:a,onChange:l,className:u,classes:f,disableFuture:p,disablePast:g,minDate:m,maxDate:y,shouldDisableDate:b,shouldDisableMonth:S,shouldDisableYear:C,reduceAnimations:T,onMonthChange:_,monthsPerRow:w,onYearChange:E,yearsOrder:O,yearsPerRow:L,slots:P,slotProps:$,loading:M,renderLoading:A,disableHighlightToday:N,readOnly:V,disabled:R,showDaysOutsideCurrentMonth:B,dayOfWeekFormatter:z,sx:q,autoFocus:K,fixedWeekNumber:G,displayWeekNumber:Y,timezone:Z})=>v.jsx(dT,{view:t,onViewChange:e,views:n.filter(Iw),focusedView:r&&Iw(r)?r:null,onFocusedViewChange:o,value:i,defaultValue:s,referenceDate:a,onChange:l,className:u,classes:f,disableFuture:p,disablePast:g,minDate:m,maxDate:y,shouldDisableDate:b,shouldDisableMonth:S,shouldDisableYear:C,reduceAnimations:T,onMonthChange:_,monthsPerRow:w,onYearChange:E,yearsOrder:O,yearsPerRow:L,slots:P,slotProps:$,loading:M,renderLoading:A,disableHighlightToday:N,readOnly:V,disabled:R,showDaysOutsideCurrentMonth:B,dayOfWeekFormatter:z,sx:q,autoFocus:K,fixedWeekNumber:G,displayWeekNumber:Y,timezone:Z}),fT=I.forwardRef(function(e,n){var u,f;const r=Ko(),o=qt(),i=g_(e,"MuiDesktopDatePicker"),s=ne({day:Ma,month:Ma,year:Ma},i.viewRenderers),a=ne({},i,{viewRenderers:s,format:Og(o,i,!1),yearsPerRow:i.yearsPerRow??4,slots:ne({openPickerIcon:HV,field:_d},i.slots),slotProps:ne({},i.slotProps,{field:p=>{var g;return ne({},Mu((g=i.slotProps)==null?void 0:g.field,p),Uw(i),{ref:n})},toolbar:ne({hidden:!0},(u=i.slotProps)==null?void 0:u.toolbar)})}),{renderPicker:l}=fW({props:a,valueManager:wo,valueType:"date",getOpenDialogAriaText:Kw({utils:o,formatKey:"fullDate",contextTranslation:r.openDatePickerDialogue,propsTranslation:(f=a.localeText)==null?void 0:f.openDatePickerDialogue}),validator:Xl});return l()});fT.propTypes={autoFocus:c.bool,className:c.string,closeOnSelect:c.bool,dayOfWeekFormatter:c.func,defaultValue:c.object,disabled:c.bool,disableFuture:c.bool,disableHighlightToday:c.bool,disableOpenPicker:c.bool,disablePast:c.bool,displayWeekNumber:c.bool,enableAccessibleFieldDOMStructure:c.any,fixedWeekNumber:c.number,format:c.string,formatDensity:c.oneOf(["dense","spacious"]),inputRef:mn,label:c.node,loading:c.bool,localeText:c.object,maxDate:c.object,minDate:c.object,monthsPerRow:c.oneOf([3,4]),name:c.string,onAccept:c.func,onChange:c.func,onClose:c.func,onError:c.func,onMonthChange:c.func,onOpen:c.func,onSelectedSectionsChange:c.func,onViewChange:c.func,onYearChange:c.func,open:c.bool,openTo:c.oneOf(["day","month","year"]),orientation:c.oneOf(["landscape","portrait"]),readOnly:c.bool,reduceAnimations:c.bool,referenceDate:c.object,renderLoading:c.func,selectedSections:c.oneOfType([c.oneOf(["all","day","empty","hours","meridiem","minutes","month","seconds","weekDay","year"]),c.number]),shouldDisableDate:c.func,shouldDisableMonth:c.func,shouldDisableYear:c.func,showDaysOutsideCurrentMonth:c.bool,slotProps:c.object,slots:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),timezone:c.string,value:c.object,view:c.oneOf(["day","month","year"]),viewRenderers:c.shape({day:c.func,month:c.func,year:c.func}),views:c.arrayOf(c.oneOf(["day","month","year"]).isRequired),yearsOrder:c.oneOf(["asc","desc"]),yearsPerRow:c.oneOf([3,4])};function R9(t){return Ke("MuiDialogContent",t)}qe("MuiDialogContent",["root","dividers"]);const z9=qe("MuiDialogTitle",["root"]),V9=t=>{const{classes:e,dividers:n}=t;return Ue({root:["root",n&&"dividers"]},R9,e)},H9=be("div",{name:"MuiDialogContent",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,n.dividers&&e.dividers]}})(Dt(({theme:t})=>({flex:"1 1 auto",WebkitOverflowScrolling:"touch",overflowY:"auto",padding:"20px 24px",variants:[{props:({ownerState:e})=>e.dividers,style:{padding:"16px 24px",borderTop:`1px solid ${(t.vars||t).palette.divider}`,borderBottom:`1px solid ${(t.vars||t).palette.divider}`}},{props:({ownerState:e})=>!e.dividers,style:{[`.${z9.root} + &`]:{paddingTop:0}}}]}))),pT=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiDialogContent"}),{className:o,dividers:i=!1,...s}=r,a={...r,dividers:i},l=V9(a);return v.jsx(H9,{className:Le(l.root,o),ownerState:a,ref:n,...s})});process.env.NODE_ENV!=="production"&&(pT.propTypes={children:c.node,classes:c.object,className:c.string,dividers:c.bool,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object])});function j9(t){return Ke("MuiDialog",t)}const fc=qe("MuiDialog",["root","scrollPaper","scrollBody","container","paper","paperScrollPaper","paperScrollBody","paperWidthFalse","paperWidthXs","paperWidthSm","paperWidthMd","paperWidthLg","paperWidthXl","paperFullWidth","paperFullScreen"]),hT=I.createContext({});process.env.NODE_ENV!=="production"&&(hT.displayName="DialogContext");const W9=be(wg,{name:"MuiDialog",slot:"Backdrop",overrides:(t,e)=>e.backdrop})({zIndex:-1}),q9=t=>{const{classes:e,scroll:n,maxWidth:r,fullWidth:o,fullScreen:i}=t,s={root:["root"],container:["container",`scroll${Ae(n)}`],paper:["paper",`paperScroll${Ae(n)}`,`paperWidth${Ae(String(r))}`,o&&"paperFullWidth",i&&"paperFullScreen"]};return Ue(s,j9,e)},U9=be(_g,{name:"MuiDialog",slot:"Root",overridesResolver:(t,e)=>e.root})({"@media print":{position:"absolute !important"}}),K9=be("div",{name:"MuiDialog",slot:"Container",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.container,e[`scroll${Ae(n.scroll)}`]]}})({height:"100%","@media print":{height:"auto"},outline:0,variants:[{props:{scroll:"paper"},style:{display:"flex",justifyContent:"center",alignItems:"center"}},{props:{scroll:"body"},style:{overflowY:"auto",overflowX:"hidden",textAlign:"center","&::after":{content:'""',display:"inline-block",verticalAlign:"middle",height:"100%",width:"0"}}}]}),Y9=be(ya,{name:"MuiDialog",slot:"Paper",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.paper,e[`scrollPaper${Ae(n.scroll)}`],e[`paperWidth${Ae(String(n.maxWidth))}`],n.fullWidth&&e.paperFullWidth,n.fullScreen&&e.paperFullScreen]}})(Dt(({theme:t})=>({margin:32,position:"relative",overflowY:"auto","@media print":{overflowY:"visible",boxShadow:"none"},variants:[{props:{scroll:"paper"},style:{display:"flex",flexDirection:"column",maxHeight:"calc(100% - 64px)"}},{props:{scroll:"body"},style:{display:"inline-block",verticalAlign:"middle",textAlign:"initial"}},{props:({ownerState:e})=>!e.maxWidth,style:{maxWidth:"calc(100% - 64px)"}},{props:{maxWidth:"xs"},style:{maxWidth:t.breakpoints.unit==="px"?Math.max(t.breakpoints.values.xs,444):`max(${t.breakpoints.values.xs}${t.breakpoints.unit}, 444px)`,[`&.${fc.paperScrollBody}`]:{[t.breakpoints.down(Math.max(t.breakpoints.values.xs,444)+32*2)]:{maxWidth:"calc(100% - 64px)"}}}},...Object.keys(t.breakpoints.values).filter(e=>e!=="xs").map(e=>({props:{maxWidth:e},style:{maxWidth:`${t.breakpoints.values[e]}${t.breakpoints.unit}`,[`&.${fc.paperScrollBody}`]:{[t.breakpoints.down(t.breakpoints.values[e]+32*2)]:{maxWidth:"calc(100% - 64px)"}}}})),{props:({ownerState:e})=>e.fullWidth,style:{width:"calc(100% - 64px)"}},{props:({ownerState:e})=>e.fullScreen,style:{margin:0,width:"100%",maxWidth:"100%",height:"100%",maxHeight:"none",borderRadius:0,[`&.${fc.paperScrollBody}`]:{margin:0,maxWidth:"100%"}}}]}))),gT=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiDialog"}),o=Si(),i={enter:o.transitions.duration.enteringScreen,exit:o.transitions.duration.leavingScreen},{"aria-describedby":s,"aria-labelledby":a,"aria-modal":l=!0,BackdropComponent:u,BackdropProps:f,children:p,className:g,disableEscapeKeyDown:m=!1,fullScreen:y=!1,fullWidth:b=!1,maxWidth:S="sm",onBackdropClick:C,onClick:T,onClose:_,open:w,PaperComponent:E=ya,PaperProps:O={},scroll:L="paper",slots:P={},slotProps:$={},TransitionComponent:M=wi,transitionDuration:A=i,TransitionProps:N,...V}=r,R={...r,disableEscapeKeyDown:m,fullScreen:y,fullWidth:b,maxWidth:S,scroll:L},B=q9(R),z=I.useRef(),q=de=>{z.current=de.target===de.currentTarget},K=de=>{T&&T(de),z.current&&(z.current=null,C&&C(de),_&&_(de,"backdropClick"))},G=vo(a),Y=I.useMemo(()=>({titleId:G}),[G]),Z={transition:M,...P},me={transition:N,paper:O,backdrop:f,...$},he={slots:Z,slotProps:me},[oe,Q]=zt("root",{elementType:U9,shouldForwardComponentProp:!0,externalForwardedProps:he,ownerState:R,className:Le(B.root,g),ref:n}),[fe,ce]=zt("backdrop",{elementType:W9,shouldForwardComponentProp:!0,externalForwardedProps:he,ownerState:R}),[ae,W]=zt("paper",{elementType:Y9,shouldForwardComponentProp:!0,externalForwardedProps:he,ownerState:R,className:Le(B.paper,O.className)}),[te,ue]=zt("container",{elementType:K9,externalForwardedProps:he,ownerState:R,className:Le(B.container)}),[ee,se]=zt("transition",{elementType:wi,externalForwardedProps:he,ownerState:R,additionalProps:{appear:!0,in:w,timeout:A,role:"presentation"}});return v.jsx(oe,{closeAfterTransition:!0,slots:{backdrop:fe},slotProps:{backdrop:{transitionDuration:A,as:u,...ce}},disableEscapeKeyDown:m,onClose:_,open:w,onClick:K,...Q,...V,children:v.jsx(ee,{...se,children:v.jsx(te,{onMouseDown:q,...ue,children:v.jsx(ae,{as:E,elevation:24,role:"dialog","aria-describedby":s,"aria-labelledby":G,"aria-modal":l,...W,children:v.jsx(hT.Provider,{value:Y,children:p})})})})})});process.env.NODE_ENV!=="production"&&(gT.propTypes={"aria-describedby":c.string,"aria-labelledby":c.string,"aria-modal":c.oneOfType([c.oneOf(["false","true"]),c.bool]),BackdropComponent:c.elementType,BackdropProps:c.object,children:c.node,classes:c.object,className:c.string,disableEscapeKeyDown:c.bool,fullScreen:c.bool,fullWidth:c.bool,maxWidth:c.oneOfType([c.oneOf(["xs","sm","md","lg","xl",!1]),c.string]),onBackdropClick:c.func,onClick:c.func,onClose:c.func,open:c.bool.isRequired,PaperComponent:c.elementType,PaperProps:c.object,scroll:c.oneOf(["body","paper"]),slotProps:c.shape({backdrop:c.oneOfType([c.func,c.object]),container:c.oneOfType([c.func,c.object]),paper:c.oneOfType([c.func,c.object]),root:c.oneOfType([c.func,c.object]),transition:c.oneOfType([c.func,c.object])}),slots:c.shape({backdrop:c.elementType,container:c.elementType,paper:c.elementType,root:c.elementType,transition:c.elementType}),sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),TransitionComponent:c.elementType,transitionDuration:c.oneOfType([c.number,c.shape({appear:c.number,enter:c.number,exit:c.number})]),TransitionProps:c.object});const G9=be(gT)({[`& .${fc.container}`]:{outline:0},[`& .${fc.paper}`]:{outline:0,minWidth:Pd}}),J9=be(pT)({"&:first-of-type":{padding:0}});function Z9(t){const{children:e,onDismiss:n,open:r,slots:o,slotProps:i}=t,s=(o==null?void 0:o.dialog)??G9,a=(o==null?void 0:o.mobileTransition)??wi;return v.jsx(s,ne({open:r,onClose:n},i==null?void 0:i.dialog,{TransitionComponent:a,TransitionProps:i==null?void 0:i.mobileTransition,PaperComponent:o==null?void 0:o.mobilePaper,PaperProps:i==null?void 0:i.mobilePaper,children:v.jsx(J9,{children:e})}))}const X9=["props","getOpenDialogAriaText"],Q9=t=>{var Z;let{props:e,getOpenDialogAriaText:n}=t,r=rt(t,X9);const{slots:o,slotProps:i,className:s,sx:a,format:l,formatDensity:u,enableAccessibleFieldDOMStructure:f,selectedSections:p,onSelectedSectionsChange:g,timezone:m,name:y,label:b,inputRef:S,readOnly:C,disabled:T,localeText:_}=e,w=I.useRef(null),E=vo(),O=((Z=i==null?void 0:i.toolbar)==null?void 0:Z.hidden)??!1,{open:L,actions:P,layoutProps:$,renderCurrentView:M,fieldProps:A,contextValue:N}=j_(ne({},r,{props:e,fieldRef:w,autoFocusView:!0,additionalViewProps:{},wrapperVariant:"mobile"})),V=o.field,R=wt({elementType:V,externalSlotProps:i==null?void 0:i.field,additionalProps:ne({},A,O&&{id:E},!(T||C)&&{onClick:P.onOpen,onKeyDown:tV(P.onOpen)},{readOnly:C??!0,disabled:T,className:s,sx:a,format:l,formatDensity:u,enableAccessibleFieldDOMStructure:f,selectedSections:p,onSelectedSectionsChange:g,timezone:m,label:b,name:y},S?{inputRef:S}:{}),ownerState:e});R.inputProps=ne({},R.inputProps,{"aria-label":n(A.value)});const B=ne({textField:o.textField},R.slots),z=o.layout??rm;let q=E;O&&(b?q=`${E}-label`:q=void 0);const K=ne({},i,{toolbar:ne({},i==null?void 0:i.toolbar,{titleId:E}),mobilePaper:ne({"aria-labelledby":q},i==null?void 0:i.mobilePaper)}),G=Et(w,R.unstableFieldRef);return{renderPicker:()=>v.jsxs(r_,{contextValue:N,localeText:_,children:[v.jsx(V,ne({},R,{slots:B,slotProps:K,unstableFieldRef:G})),v.jsx(Z9,ne({},P,{open:L,slots:o,slotProps:K,children:v.jsx(z,ne({},$,K==null?void 0:K.layout,{slots:o,slotProps:K,children:M()}))}))]})}},mT=I.forwardRef(function(e,n){var u,f;const r=Ko(),o=qt(),i=g_(e,"MuiMobileDatePicker"),s=ne({day:Ma,month:Ma,year:Ma},i.viewRenderers),a=ne({},i,{viewRenderers:s,format:Og(o,i,!1),slots:ne({field:_d},i.slots),slotProps:ne({},i.slotProps,{field:p=>{var g;return ne({},Mu((g=i.slotProps)==null?void 0:g.field,p),Uw(i),{ref:n})},toolbar:ne({hidden:!1},(u=i.slotProps)==null?void 0:u.toolbar)})}),{renderPicker:l}=Q9({props:a,valueManager:wo,valueType:"date",getOpenDialogAriaText:Kw({utils:o,formatKey:"fullDate",contextTranslation:r.openDatePickerDialogue,propsTranslation:(f=a.localeText)==null?void 0:f.openDatePickerDialogue}),validator:Xl});return l()});mT.propTypes={autoFocus:c.bool,className:c.string,closeOnSelect:c.bool,dayOfWeekFormatter:c.func,defaultValue:c.object,disabled:c.bool,disableFuture:c.bool,disableHighlightToday:c.bool,disableOpenPicker:c.bool,disablePast:c.bool,displayWeekNumber:c.bool,enableAccessibleFieldDOMStructure:c.any,fixedWeekNumber:c.number,format:c.string,formatDensity:c.oneOf(["dense","spacious"]),inputRef:mn,label:c.node,loading:c.bool,localeText:c.object,maxDate:c.object,minDate:c.object,monthsPerRow:c.oneOf([3,4]),name:c.string,onAccept:c.func,onChange:c.func,onClose:c.func,onError:c.func,onMonthChange:c.func,onOpen:c.func,onSelectedSectionsChange:c.func,onViewChange:c.func,onYearChange:c.func,open:c.bool,openTo:c.oneOf(["day","month","year"]),orientation:c.oneOf(["landscape","portrait"]),readOnly:c.bool,reduceAnimations:c.bool,referenceDate:c.object,renderLoading:c.func,selectedSections:c.oneOfType([c.oneOf(["all","day","empty","hours","meridiem","minutes","month","seconds","weekDay","year"]),c.number]),shouldDisableDate:c.func,shouldDisableMonth:c.func,shouldDisableYear:c.func,showDaysOutsideCurrentMonth:c.bool,slotProps:c.object,slots:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),timezone:c.string,value:c.object,view:c.oneOf(["day","month","year"]),viewRenderers:c.shape({day:c.func,month:c.func,year:c.func}),views:c.arrayOf(c.oneOf(["day","month","year"]).isRequired),yearsOrder:c.oneOf(["asc","desc"]),yearsPerRow:c.oneOf([3,4])};const eq=["desktopModeMediaQuery"],yT=I.forwardRef(function(e,n){const r=Wt({props:e,name:"MuiDatePicker"}),{desktopModeMediaQuery:o=nV}=r,i=rt(r,eq);return p_(o,{defaultMatches:!0})?v.jsx(fT,ne({ref:n},i)):v.jsx(mT,ne({ref:n},i))});process.env.NODE_ENV!=="production"&&(yT.propTypes={autoFocus:c.bool,className:c.string,closeOnSelect:c.bool,dayOfWeekFormatter:c.func,defaultValue:c.object,desktopModeMediaQuery:c.string,disabled:c.bool,disableFuture:c.bool,disableHighlightToday:c.bool,disableOpenPicker:c.bool,disablePast:c.bool,displayWeekNumber:c.bool,enableAccessibleFieldDOMStructure:c.any,fixedWeekNumber:c.number,format:c.string,formatDensity:c.oneOf(["dense","spacious"]),inputRef:mn,label:c.node,loading:c.bool,localeText:c.object,maxDate:c.object,minDate:c.object,monthsPerRow:c.oneOf([3,4]),name:c.string,onAccept:c.func,onChange:c.func,onClose:c.func,onError:c.func,onMonthChange:c.func,onOpen:c.func,onSelectedSectionsChange:c.func,onViewChange:c.func,onYearChange:c.func,open:c.bool,openTo:c.oneOf(["day","month","year"]),orientation:c.oneOf(["landscape","portrait"]),readOnly:c.bool,reduceAnimations:c.bool,referenceDate:c.object,renderLoading:c.func,selectedSections:c.oneOfType([c.oneOf(["all","day","empty","hours","meridiem","minutes","month","seconds","weekDay","year"]),c.number]),shouldDisableDate:c.func,shouldDisableMonth:c.func,shouldDisableYear:c.func,showDaysOutsideCurrentMonth:c.bool,slotProps:c.object,slots:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),timezone:c.string,value:c.object,view:c.oneOf(["day","month","year"]),viewRenderers:c.shape({day:c.func,month:c.func,year:c.func}),views:c.arrayOf(c.oneOf(["day","month","year"]).isRequired),yearsOrder:c.oneOf(["asc","desc"]),yearsPerRow:c.oneOf([3,4])});const tq={invalidDate:"Date selected is invalid",minDate:"Date selected is too far in the past",maxDate:"Date selected is too far in the future",disableFuture:"Date selected cannot be in the future",disablePast:"Date selected cannot be in the past"},Fd=t=>{const{name:e,label:n=_n(e),required:r=!1,readOnly:o=!1,format:i="MM/DD/YYYY",errorMessages:s,isDatePicker:a=!1,margin:l="dense",staticLabel:u=!1,staticLabelProps:f={fontSize:".9em",color:"#808080"}}=t,[p,g,m]=jt.useField({name:e}),{setValue:y,setError:b}=m,{value:S}=p,{error:C}=g,T=N=>{if(!N)return null;const V=pn.utc(N);return V&&V.isValid()?pn(V):null},_=N=>{const V=N==null?void 0:N.utc();return!V||!V.isValid()?"":V.toISOString()},[w,E]=I.useState(T(S)),[O,L]=I.useState(null),P={...tq,...s},$=["staticLabel","staticLabelProps","label","errorMessages","isDatePicker","dateFieldProps","datePickerProps","onChange"],M=(N,V)=>_(N)!==V;I.useEffect(()=>{M(w,S)&&y(_(w))},[w]),I.useEffect(()=>{M(w,S)&&E(T(S))},[S]),I.useEffect(()=>{const N=O?P[O]??O:"";b(N)},[O]);const A={label:u?void 0:n,format:i,onError:L,value:w,onChange:(N,V)=>{var R;E(N?N.utc():null),(R=t.onChange)==null||R.call(t,_(N),V)},...Jn({...t},$)};return v.jsxs(F.FormControl,{fullWidth:!0,margin:l,children:[(u||o)&&v.jsx(F.Typography,{...f,children:n}),o?v.jsx(F.Typography,{"data-testid":"date-field_readonly-value",children:w!=null&&w.isValid()?w.format(i):""}):v.jsxs(F.Box,{children:[v.jsx(ag,{dateAdapter:y3,children:v.jsx(F.Box,{children:a?v.jsx(yT,{...A,slotProps:{textField:{fullWidth:!0,error:!!C,required:!!r}}}):v.jsx(_d,{id:`${e}-df`,...A,fullWidth:!0,slotProps:{textField:{error:!!C}}})})}),v.jsx(Xn,{name:e,id:`${e}-err`})]})]})},nq=t=>{const{nameTo:e,nameFrom:n,labelTo:r=_n(e),labelFrom:o=_n(n),fromFieldProps:i,toFieldProps:s,staticLabels:a=!1}=t,l=["nameTo","nameFrom","toFieldProps","fromFieldProps","labelTo","labelFrom"],u=F.useMediaQuery(F.useTheme().breakpoints.down("sm"));return v.jsxs("div",{style:{display:"flex",flexDirection:u?"column":"row",justifyContent:"space-between",gap:"10px"},children:[v.jsx(Fd,{name:n,staticLabel:a,label:o,...Jn({...t,...i},l)}),v.jsx(Fd,{name:e,staticLabel:a,label:r,...Jn({...t,...s},l)})]})};function Pn(t){this.content=t}Pn.prototype={constructor:Pn,find:function(t){for(var e=0;e<this.content.length;e+=2)if(this.content[e]===t)return e;return-1},get:function(t){var e=this.find(t);return e==-1?void 0:this.content[e+1]},update:function(t,e,n){var r=n&&n!=t?this.remove(n):this,o=r.find(t),i=r.content.slice();return o==-1?i.push(n||t,e):(i[o+1]=e,n&&(i[o]=n)),new Pn(i)},remove:function(t){var e=this.find(t);if(e==-1)return this;var n=this.content.slice();return n.splice(e,2),new Pn(n)},addToStart:function(t,e){return new Pn([t,e].concat(this.remove(t).content))},addToEnd:function(t,e){var n=this.remove(t).content.slice();return n.push(t,e),new Pn(n)},addBefore:function(t,e,n){var r=this.remove(e),o=r.content.slice(),i=r.find(t);return o.splice(i==-1?o.length:i,0,e,n),new Pn(o)},forEach:function(t){for(var e=0;e<this.content.length;e+=2)t(this.content[e],this.content[e+1])},prepend:function(t){return t=Pn.from(t),t.size?new Pn(t.content.concat(this.subtract(t).content)):this},append:function(t){return t=Pn.from(t),t.size?new Pn(this.subtract(t).content.concat(t.content)):this},subtract:function(t){var e=this;t=Pn.from(t);for(var n=0;n<t.content.length;n+=2)e=e.remove(t.content[n]);return e},toObject:function(){var t={};return this.forEach(function(e,n){t[e]=n}),t},get size(){return this.content.length>>1}},Pn.from=function(t){if(t instanceof Pn)return t;var e=[];if(t)for(var n in t)e.push(n,t[n]);return new Pn(e)};function bT(t,e,n){for(let r=0;;r++){if(r==t.childCount||r==e.childCount)return t.childCount==e.childCount?null:n;let o=t.child(r),i=e.child(r);if(o==i){n+=o.nodeSize;continue}if(!o.sameMarkup(i))return n;if(o.isText&&o.text!=i.text){for(let s=0;o.text[s]==i.text[s];s++)n++;return n}if(o.content.size||i.content.size){let s=bT(o.content,i.content,n+1);if(s!=null)return s}n+=o.nodeSize}}function vT(t,e,n,r){for(let o=t.childCount,i=e.childCount;;){if(o==0||i==0)return o==i?null:{a:n,b:r};let s=t.child(--o),a=e.child(--i),l=s.nodeSize;if(s==a){n-=l,r-=l;continue}if(!s.sameMarkup(a))return{a:n,b:r};if(s.isText&&s.text!=a.text){let u=0,f=Math.min(s.text.length,a.text.length);for(;u<f&&s.text[s.text.length-u-1]==a.text[a.text.length-u-1];)u++,n--,r--;return{a:n,b:r}}if(s.content.size||a.content.size){let u=vT(s.content,a.content,n-1,r-1);if(u)return u}n-=l,r-=l}}class Te{constructor(e,n){if(this.content=e,this.size=n||0,n==null)for(let r=0;r<e.length;r++)this.size+=e[r].nodeSize}nodesBetween(e,n,r,o=0,i){for(let s=0,a=0;a<n;s++){let l=this.content[s],u=a+l.nodeSize;if(u>e&&r(l,o+a,i||null,s)!==!1&&l.content.size){let f=a+1;l.nodesBetween(Math.max(0,e-f),Math.min(l.content.size,n-f),r,o+f)}a=u}}descendants(e){this.nodesBetween(0,this.size,e)}textBetween(e,n,r,o){let i="",s=!0;return this.nodesBetween(e,n,(a,l)=>{let u=a.isText?a.text.slice(Math.max(e,l)-l,n-l):a.isLeaf?o?typeof o=="function"?o(a):o:a.type.spec.leafText?a.type.spec.leafText(a):"":"";a.isBlock&&(a.isLeaf&&u||a.isTextblock)&&r&&(s?s=!1:i+=r),i+=u},0),i}append(e){if(!e.size)return this;if(!this.size)return e;let n=this.lastChild,r=e.firstChild,o=this.content.slice(),i=0;for(n.isText&&n.sameMarkup(r)&&(o[o.length-1]=n.withText(n.text+r.text),i=1);i<e.content.length;i++)o.push(e.content[i]);return new Te(o,this.size+e.size)}cut(e,n=this.size){if(e==0&&n==this.size)return this;let r=[],o=0;if(n>e)for(let i=0,s=0;s<n;i++){let a=this.content[i],l=s+a.nodeSize;l>e&&((s<e||l>n)&&(a.isText?a=a.cut(Math.max(0,e-s),Math.min(a.text.length,n-s)):a=a.cut(Math.max(0,e-s-1),Math.min(a.content.size,n-s-1))),r.push(a),o+=a.nodeSize),s=l}return new Te(r,o)}cutByIndex(e,n){return e==n?Te.empty:e==0&&n==this.content.length?this:new Te(this.content.slice(e,n))}replaceChild(e,n){let r=this.content[e];if(r==n)return this;let o=this.content.slice(),i=this.size+n.nodeSize-r.nodeSize;return o[e]=n,new Te(o,i)}addToStart(e){return new Te([e].concat(this.content),this.size+e.nodeSize)}addToEnd(e){return new Te(this.content.concat(e),this.size+e.nodeSize)}eq(e){if(this.content.length!=e.content.length)return!1;for(let n=0;n<this.content.length;n++)if(!this.content[n].eq(e.content[n]))return!1;return!0}get firstChild(){return this.content.length?this.content[0]:null}get lastChild(){return this.content.length?this.content[this.content.length-1]:null}get childCount(){return this.content.length}child(e){let n=this.content[e];if(!n)throw new RangeError("Index "+e+" out of range for "+this);return n}maybeChild(e){return this.content[e]||null}forEach(e){for(let n=0,r=0;n<this.content.length;n++){let o=this.content[n];e(o,r,n),r+=o.nodeSize}}findDiffStart(e,n=0){return bT(this,e,n)}findDiffEnd(e,n=this.size,r=e.size){return vT(this,e,n,r)}findIndex(e,n=-1){if(e==0)return $d(0,e);if(e==this.size)return $d(this.content.length,e);if(e>this.size||e<0)throw new RangeError(`Position ${e} outside of fragment (${this})`);for(let r=0,o=0;;r++){let i=this.child(r),s=o+i.nodeSize;if(s>=e)return s==e||n>0?$d(r+1,s):$d(r,o);o=s}}toString(){return"<"+this.toStringInner()+">"}toStringInner(){return this.content.join(", ")}toJSON(){return this.content.length?this.content.map(e=>e.toJSON()):null}static fromJSON(e,n){if(!n)return Te.empty;if(!Array.isArray(n))throw new RangeError("Invalid input for Fragment.fromJSON");return new Te(n.map(e.nodeFromJSON))}static fromArray(e){if(!e.length)return Te.empty;let n,r=0;for(let o=0;o<e.length;o++){let i=e[o];r+=i.nodeSize,o&&i.isText&&e[o-1].sameMarkup(i)?(n||(n=e.slice(0,o)),n[n.length-1]=i.withText(n[n.length-1].text+i.text)):n&&n.push(i)}return new Te(n||e,r)}static from(e){if(!e)return Te.empty;if(e instanceof Te)return e;if(Array.isArray(e))return this.fromArray(e);if(e.attrs)return new Te([e],e.nodeSize);throw new RangeError("Can not convert "+e+" to a Fragment"+(e.nodesBetween?" (looks like multiple versions of prosemirror-model were loaded)":""))}}Te.empty=new Te([],0);const om={index:0,offset:0};function $d(t,e){return om.index=t,om.offset=e,om}function Bd(t,e){if(t===e)return!0;if(!(t&&typeof t=="object")||!(e&&typeof e=="object"))return!1;let n=Array.isArray(t);if(Array.isArray(e)!=n)return!1;if(n){if(t.length!=e.length)return!1;for(let r=0;r<t.length;r++)if(!Bd(t[r],e[r]))return!1}else{for(let r in t)if(!(r in e)||!Bd(t[r],e[r]))return!1;for(let r in e)if(!(r in t))return!1}return!0}let Ft=class Rx{constructor(e,n){this.type=e,this.attrs=n}addToSet(e){let n,r=!1;for(let o=0;o<e.length;o++){let i=e[o];if(this.eq(i))return e;if(this.type.excludes(i.type))n||(n=e.slice(0,o));else{if(i.type.excludes(this.type))return e;!r&&i.type.rank>this.type.rank&&(n||(n=e.slice(0,o)),n.push(this),r=!0),n&&n.push(i)}}return n||(n=e.slice()),r||n.push(this),n}removeFromSet(e){for(let n=0;n<e.length;n++)if(this.eq(e[n]))return e.slice(0,n).concat(e.slice(n+1));return e}isInSet(e){for(let n=0;n<e.length;n++)if(this.eq(e[n]))return!0;return!1}eq(e){return this==e||this.type==e.type&&Bd(this.attrs,e.attrs)}toJSON(){let e={type:this.type.name};for(let n in this.attrs){e.attrs=this.attrs;break}return e}static fromJSON(e,n){if(!n)throw new RangeError("Invalid input for Mark.fromJSON");let r=e.marks[n.type];if(!r)throw new RangeError(`There is no mark type ${n.type} in this schema`);let o=r.create(n.attrs);return r.checkAttrs(o.attrs),o}static sameSet(e,n){if(e==n)return!0;if(e.length!=n.length)return!1;for(let r=0;r<e.length;r++)if(!e[r].eq(n[r]))return!1;return!0}static setFrom(e){if(!e||Array.isArray(e)&&e.length==0)return Rx.none;if(e instanceof Rx)return[e];let n=e.slice();return n.sort((r,o)=>r.type.rank-o.type.rank),n}};Ft.none=[];class Rd extends Error{}class Ie{constructor(e,n,r){this.content=e,this.openStart=n,this.openEnd=r}get size(){return this.content.size-this.openStart-this.openEnd}insertAt(e,n){let r=ST(this.content,e+this.openStart,n);return r&&new Ie(r,this.openStart,this.openEnd)}removeBetween(e,n){return new Ie(xT(this.content,e+this.openStart,n+this.openStart),this.openStart,this.openEnd)}eq(e){return this.content.eq(e.content)&&this.openStart==e.openStart&&this.openEnd==e.openEnd}toString(){return this.content+"("+this.openStart+","+this.openEnd+")"}toJSON(){if(!this.content.size)return null;let e={content:this.content.toJSON()};return this.openStart>0&&(e.openStart=this.openStart),this.openEnd>0&&(e.openEnd=this.openEnd),e}static fromJSON(e,n){if(!n)return Ie.empty;let r=n.openStart||0,o=n.openEnd||0;if(typeof r!="number"||typeof o!="number")throw new RangeError("Invalid input for Slice.fromJSON");return new Ie(Te.fromJSON(e,n.content),r,o)}static maxOpen(e,n=!0){let r=0,o=0;for(let i=e.firstChild;i&&!i.isLeaf&&(n||!i.type.spec.isolating);i=i.firstChild)r++;for(let i=e.lastChild;i&&!i.isLeaf&&(n||!i.type.spec.isolating);i=i.lastChild)o++;return new Ie(e,r,o)}}Ie.empty=new Ie(Te.empty,0,0);function xT(t,e,n){let{index:r,offset:o}=t.findIndex(e),i=t.maybeChild(r),{index:s,offset:a}=t.findIndex(n);if(o==e||i.isText){if(a!=n&&!t.child(s).isText)throw new RangeError("Removing non-flat range");return t.cut(0,e).append(t.cut(n))}if(r!=s)throw new RangeError("Removing non-flat range");return t.replaceChild(r,i.copy(xT(i.content,e-o-1,n-o-1)))}function ST(t,e,n,r){let{index:o,offset:i}=t.findIndex(e),s=t.maybeChild(o);if(i==e||s.isText)return t.cut(0,e).append(n).append(t.cut(e));let a=ST(s.content,e-i-1,n);return a&&t.replaceChild(o,s.copy(a))}function rq(t,e,n){if(n.openStart>t.depth)throw new Rd("Inserted content deeper than insertion position");if(t.depth-n.openStart!=e.depth-n.openEnd)throw new Rd("Inconsistent open depths");return CT(t,e,n,0)}function CT(t,e,n,r){let o=t.index(r),i=t.node(r);if(o==e.index(r)&&r<t.depth-n.openStart){let s=CT(t,e,n,r+1);return i.copy(i.content.replaceChild(o,s))}else if(n.content.size)if(!n.openStart&&!n.openEnd&&t.depth==r&&e.depth==r){let s=t.parent,a=s.content;return _s(s,a.cut(0,t.parentOffset).append(n.content).append(a.cut(e.parentOffset)))}else{let{start:s,end:a}=oq(n,t);return _s(i,_T(t,s,a,e,r))}else return _s(i,zd(t,e,r))}function wT(t,e){if(!e.type.compatibleContent(t.type))throw new Rd("Cannot join "+e.type.name+" onto "+t.type.name)}function im(t,e,n){let r=t.node(n);return wT(r,e.node(n)),r}function ws(t,e){let n=e.length-1;n>=0&&t.isText&&t.sameMarkup(e[n])?e[n]=t.withText(e[n].text+t.text):e.push(t)}function pc(t,e,n,r){let o=(e||t).node(n),i=0,s=e?e.index(n):o.childCount;t&&(i=t.index(n),t.depth>n?i++:t.textOffset&&(ws(t.nodeAfter,r),i++));for(let a=i;a<s;a++)ws(o.child(a),r);e&&e.depth==n&&e.textOffset&&ws(e.nodeBefore,r)}function _s(t,e){return t.type.checkContent(e),t.copy(e)}function _T(t,e,n,r,o){let i=t.depth>o&&im(t,e,o+1),s=r.depth>o&&im(n,r,o+1),a=[];return pc(null,t,o,a),i&&s&&e.index(o)==n.index(o)?(wT(i,s),ws(_s(i,_T(t,e,n,r,o+1)),a)):(i&&ws(_s(i,zd(t,e,o+1)),a),pc(e,n,o,a),s&&ws(_s(s,zd(n,r,o+1)),a)),pc(r,null,o,a),new Te(a)}function zd(t,e,n){let r=[];if(pc(null,t,n,r),t.depth>n){let o=im(t,e,n+1);ws(_s(o,zd(t,e,n+1)),r)}return pc(e,null,n,r),new Te(r)}function oq(t,e){let n=e.depth-t.openStart,o=e.node(n).copy(t.content);for(let i=n-1;i>=0;i--)o=e.node(i).copy(Te.from(o));return{start:o.resolveNoCache(t.openStart+n),end:o.resolveNoCache(o.content.size-t.openEnd-n)}}class hc{constructor(e,n,r){this.pos=e,this.path=n,this.parentOffset=r,this.depth=n.length/3-1}resolveDepth(e){return e==null?this.depth:e<0?this.depth+e:e}get parent(){return this.node(this.depth)}get doc(){return this.node(0)}node(e){return this.path[this.resolveDepth(e)*3]}index(e){return this.path[this.resolveDepth(e)*3+1]}indexAfter(e){return e=this.resolveDepth(e),this.index(e)+(e==this.depth&&!this.textOffset?0:1)}start(e){return e=this.resolveDepth(e),e==0?0:this.path[e*3-1]+1}end(e){return e=this.resolveDepth(e),this.start(e)+this.node(e).content.size}before(e){if(e=this.resolveDepth(e),!e)throw new RangeError("There is no position before the top-level node");return e==this.depth+1?this.pos:this.path[e*3-1]}after(e){if(e=this.resolveDepth(e),!e)throw new RangeError("There is no position after the top-level node");return e==this.depth+1?this.pos:this.path[e*3-1]+this.path[e*3].nodeSize}get textOffset(){return this.pos-this.path[this.path.length-1]}get nodeAfter(){let e=this.parent,n=this.index(this.depth);if(n==e.childCount)return null;let r=this.pos-this.path[this.path.length-1],o=e.child(n);return r?e.child(n).cut(r):o}get nodeBefore(){let e=this.index(this.depth),n=this.pos-this.path[this.path.length-1];return n?this.parent.child(e).cut(0,n):e==0?null:this.parent.child(e-1)}posAtIndex(e,n){n=this.resolveDepth(n);let r=this.path[n*3],o=n==0?0:this.path[n*3-1]+1;for(let i=0;i<e;i++)o+=r.child(i).nodeSize;return o}marks(){let e=this.parent,n=this.index();if(e.content.size==0)return Ft.none;if(this.textOffset)return e.child(n).marks;let r=e.maybeChild(n-1),o=e.maybeChild(n);if(!r){let a=r;r=o,o=a}let i=r.marks;for(var s=0;s<i.length;s++)i[s].type.spec.inclusive===!1&&(!o||!i[s].isInSet(o.marks))&&(i=i[s--].removeFromSet(i));return i}marksAcross(e){let n=this.parent.maybeChild(this.index());if(!n||!n.isInline)return null;let r=n.marks,o=e.parent.maybeChild(e.index());for(var i=0;i<r.length;i++)r[i].type.spec.inclusive===!1&&(!o||!r[i].isInSet(o.marks))&&(r=r[i--].removeFromSet(r));return r}sharedDepth(e){for(let n=this.depth;n>0;n--)if(this.start(n)<=e&&this.end(n)>=e)return n;return 0}blockRange(e=this,n){if(e.pos<this.pos)return e.blockRange(this);for(let r=this.depth-(this.parent.inlineContent||this.pos==e.pos?1:0);r>=0;r--)if(e.pos<=this.end(r)&&(!n||n(this.node(r))))return new Vd(this,e,r);return null}sameParent(e){return this.pos-this.parentOffset==e.pos-e.parentOffset}max(e){return e.pos>this.pos?e:this}min(e){return e.pos<this.pos?e:this}toString(){let e="";for(let n=1;n<=this.depth;n++)e+=(e?"/":"")+this.node(n).type.name+"_"+this.index(n-1);return e+":"+this.parentOffset}static resolve(e,n){if(!(n>=0&&n<=e.content.size))throw new RangeError("Position "+n+" out of range");let r=[],o=0,i=n;for(let s=e;;){let{index:a,offset:l}=s.content.findIndex(i),u=i-l;if(r.push(s,a,o+l),!u||(s=s.child(a),s.isText))break;i=u-1,o+=l+1}return new hc(n,r,i)}static resolveCached(e,n){let r=TT.get(e);if(r)for(let i=0;i<r.elts.length;i++){let s=r.elts[i];if(s.pos==n)return s}else TT.set(e,r=new iq);let o=r.elts[r.i]=hc.resolve(e,n);return r.i=(r.i+1)%sq,o}}class iq{constructor(){this.elts=[],this.i=0}}const sq=12,TT=new WeakMap;class Vd{constructor(e,n,r){this.$from=e,this.$to=n,this.depth=r}get start(){return this.$from.before(this.depth+1)}get end(){return this.$to.after(this.depth+1)}get parent(){return this.$from.node(this.depth)}get startIndex(){return this.$from.index(this.depth)}get endIndex(){return this.$to.indexAfter(this.depth)}}const aq=Object.create(null);let Ei=class zx{constructor(e,n,r,o=Ft.none){this.type=e,this.attrs=n,this.marks=o,this.content=r||Te.empty}get children(){return this.content.content}get nodeSize(){return this.isLeaf?1:2+this.content.size}get childCount(){return this.content.childCount}child(e){return this.content.child(e)}maybeChild(e){return this.content.maybeChild(e)}forEach(e){this.content.forEach(e)}nodesBetween(e,n,r,o=0){this.content.nodesBetween(e,n,r,o,this)}descendants(e){this.nodesBetween(0,this.content.size,e)}get textContent(){return this.isLeaf&&this.type.spec.leafText?this.type.spec.leafText(this):this.textBetween(0,this.content.size,"")}textBetween(e,n,r,o){return this.content.textBetween(e,n,r,o)}get firstChild(){return this.content.firstChild}get lastChild(){return this.content.lastChild}eq(e){return this==e||this.sameMarkup(e)&&this.content.eq(e.content)}sameMarkup(e){return this.hasMarkup(e.type,e.attrs,e.marks)}hasMarkup(e,n,r){return this.type==e&&Bd(this.attrs,n||e.defaultAttrs||aq)&&Ft.sameSet(this.marks,r||Ft.none)}copy(e=null){return e==this.content?this:new zx(this.type,this.attrs,e,this.marks)}mark(e){return e==this.marks?this:new zx(this.type,this.attrs,this.content,e)}cut(e,n=this.content.size){return e==0&&n==this.content.size?this:this.copy(this.content.cut(e,n))}slice(e,n=this.content.size,r=!1){if(e==n)return Ie.empty;let o=this.resolve(e),i=this.resolve(n),s=r?0:o.sharedDepth(n),a=o.start(s),u=o.node(s).content.cut(o.pos-a,i.pos-a);return new Ie(u,o.depth-s,i.depth-s)}replace(e,n,r){return rq(this.resolve(e),this.resolve(n),r)}nodeAt(e){for(let n=this;;){let{index:r,offset:o}=n.content.findIndex(e);if(n=n.maybeChild(r),!n)return null;if(o==e||n.isText)return n;e-=o+1}}childAfter(e){let{index:n,offset:r}=this.content.findIndex(e);return{node:this.content.maybeChild(n),index:n,offset:r}}childBefore(e){if(e==0)return{node:null,index:0,offset:0};let{index:n,offset:r}=this.content.findIndex(e);if(r<e)return{node:this.content.child(n),index:n,offset:r};let o=this.content.child(n-1);return{node:o,index:n-1,offset:r-o.nodeSize}}resolve(e){return hc.resolveCached(this,e)}resolveNoCache(e){return hc.resolve(this,e)}rangeHasMark(e,n,r){let o=!1;return n>e&&this.nodesBetween(e,n,i=>(r.isInSet(i.marks)&&(o=!0),!o)),o}get isBlock(){return this.type.isBlock}get isTextblock(){return this.type.isTextblock}get inlineContent(){return this.type.inlineContent}get isInline(){return this.type.isInline}get isText(){return this.type.isText}get isLeaf(){return this.type.isLeaf}get isAtom(){return this.type.isAtom}toString(){if(this.type.spec.toDebugString)return this.type.spec.toDebugString(this);let e=this.type.name;return this.content.size&&(e+="("+this.content.toStringInner()+")"),kT(this.marks,e)}contentMatchAt(e){let n=this.type.contentMatch.matchFragment(this.content,0,e);if(!n)throw new Error("Called contentMatchAt on a node with invalid content");return n}canReplace(e,n,r=Te.empty,o=0,i=r.childCount){let s=this.contentMatchAt(e).matchFragment(r,o,i),a=s&&s.matchFragment(this.content,n);if(!a||!a.validEnd)return!1;for(let l=o;l<i;l++)if(!this.type.allowsMarks(r.child(l).marks))return!1;return!0}canReplaceWith(e,n,r,o){if(o&&!this.type.allowsMarks(o))return!1;let i=this.contentMatchAt(e).matchType(r),s=i&&i.matchFragment(this.content,n);return s?s.validEnd:!1}canAppend(e){return e.content.size?this.canReplace(this.childCount,this.childCount,e.content):this.type.compatibleContent(e.type)}check(){this.type.checkContent(this.content),this.type.checkAttrs(this.attrs);let e=Ft.none;for(let n=0;n<this.marks.length;n++){let r=this.marks[n];r.type.checkAttrs(r.attrs),e=r.addToSet(e)}if(!Ft.sameSet(e,this.marks))throw new RangeError(`Invalid collection of marks for node ${this.type.name}: ${this.marks.map(n=>n.type.name)}`);this.content.forEach(n=>n.check())}toJSON(){let e={type:this.type.name};for(let n in this.attrs){e.attrs=this.attrs;break}return this.content.size&&(e.content=this.content.toJSON()),this.marks.length&&(e.marks=this.marks.map(n=>n.toJSON())),e}static fromJSON(e,n){if(!n)throw new RangeError("Invalid input for Node.fromJSON");let r;if(n.marks){if(!Array.isArray(n.marks))throw new RangeError("Invalid mark data for Node.fromJSON");r=n.marks.map(e.markFromJSON)}if(n.type=="text"){if(typeof n.text!="string")throw new RangeError("Invalid text node in JSON");return e.text(n.text,r)}let o=Te.fromJSON(e,n.content),i=e.nodeType(n.type).create(n.attrs,o,r);return i.type.checkAttrs(i.attrs),i}};Ei.prototype.text=void 0;class Hd extends Ei{constructor(e,n,r,o){if(super(e,n,null,o),!r)throw new RangeError("Empty text nodes are not allowed");this.text=r}toString(){return this.type.spec.toDebugString?this.type.spec.toDebugString(this):kT(this.marks,JSON.stringify(this.text))}get textContent(){return this.text}textBetween(e,n){return this.text.slice(e,n)}get nodeSize(){return this.text.length}mark(e){return e==this.marks?this:new Hd(this.type,this.attrs,this.text,e)}withText(e){return e==this.text?this:new Hd(this.type,this.attrs,e,this.marks)}cut(e=0,n=this.text.length){return e==0&&n==this.text.length?this:this.withText(this.text.slice(e,n))}eq(e){return this.sameMarkup(e)&&this.text==e.text}toJSON(){let e=super.toJSON();return e.text=this.text,e}}function kT(t,e){for(let n=t.length-1;n>=0;n--)e=t[n].type.name+"("+e+")";return e}class Ts{constructor(e){this.validEnd=e,this.next=[],this.wrapCache=[]}static parse(e,n){let r=new lq(e,n);if(r.next==null)return Ts.empty;let o=ET(r);r.next&&r.err("Unexpected trailing text");let i=gq(hq(o));return mq(i,r),i}matchType(e){for(let n=0;n<this.next.length;n++)if(this.next[n].type==e)return this.next[n].next;return null}matchFragment(e,n=0,r=e.childCount){let o=this;for(let i=n;o&&i<r;i++)o=o.matchType(e.child(i).type);return o}get inlineContent(){return this.next.length!=0&&this.next[0].type.isInline}get defaultType(){for(let e=0;e<this.next.length;e++){let{type:n}=this.next[e];if(!(n.isText||n.hasRequiredAttrs()))return n}return null}compatible(e){for(let n=0;n<this.next.length;n++)for(let r=0;r<e.next.length;r++)if(this.next[n].type==e.next[r].type)return!0;return!1}fillBefore(e,n=!1,r=0){let o=[this];function i(s,a){let l=s.matchFragment(e,r);if(l&&(!n||l.validEnd))return Te.from(a.map(u=>u.createAndFill()));for(let u=0;u<s.next.length;u++){let{type:f,next:p}=s.next[u];if(!(f.isText||f.hasRequiredAttrs())&&o.indexOf(p)==-1){o.push(p);let g=i(p,a.concat(f));if(g)return g}}return null}return i(this,[])}findWrapping(e){for(let r=0;r<this.wrapCache.length;r+=2)if(this.wrapCache[r]==e)return this.wrapCache[r+1];let n=this.computeWrapping(e);return this.wrapCache.push(e,n),n}computeWrapping(e){let n=Object.create(null),r=[{match:this,type:null,via:null}];for(;r.length;){let o=r.shift(),i=o.match;if(i.matchType(e)){let s=[];for(let a=o;a.type;a=a.via)s.push(a.type);return s.reverse()}for(let s=0;s<i.next.length;s++){let{type:a,next:l}=i.next[s];!a.isLeaf&&!a.hasRequiredAttrs()&&!(a.name in n)&&(!o.type||l.validEnd)&&(r.push({match:a.contentMatch,type:a,via:o}),n[a.name]=!0)}}return null}get edgeCount(){return this.next.length}edge(e){if(e>=this.next.length)throw new RangeError(`There's no ${e}th edge in this content match`);return this.next[e]}toString(){let e=[];function n(r){e.push(r);for(let o=0;o<r.next.length;o++)e.indexOf(r.next[o].next)==-1&&n(r.next[o].next)}return n(this),e.map((r,o)=>{let i=o+(r.validEnd?"*":" ")+" ";for(let s=0;s<r.next.length;s++)i+=(s?", ":"")+r.next[s].type.name+"->"+e.indexOf(r.next[s].next);return i}).join(`
|
|
234
|
+
`))},[JSON.stringify(g)]));const S=qt(),C=ms(),{isOpen:T,setIsOpen:_}=xj(t),{timezone:w,value:E,handleValueChange:O}=Ng({timezone:f,value:a,defaultValue:g,referenceDate:p,onChange:s,valueManager:e}),[L,P]=I.useState(()=>{let W;return E!==void 0?W=E:g!==void 0?W=g:W=e.emptyValue,{draft:W,lastPublishedValue:W,lastCommittedValue:W,lastControlledValue:a,hasBeenModifiedSinceMount:!1}}),$=e.getTimezone(S,L.draft);y!==f&&(b(f),f&&$&&f!==$&&P(W=>ne({},W,{draft:e.setTimezone(S,f,W.draft)})));const{getValidationErrorForNewValue:M}=Gw({props:t,validator:o,timezone:w,value:L.draft,onError:t.onError}),A=Be(W=>{const ee={action:W,dateState:L,hasChanged:_e=>!e.areValuesEqual(S,W.value,_e),isControlled:m,closeOnSelect:u},ce=Sj(ee),te=Cj(ee),se=wj(ee);P(_e=>ne({},_e,{draft:W.value,lastPublishedValue:ce?W.value:_e.lastPublishedValue,lastCommittedValue:te?W.value:_e.lastCommittedValue,hasBeenModifiedSinceMount:!0}));let ue=null;const ye=()=>(ue||(ue={validationError:W.name==="setValueFromField"?W.context.validationError:M(W.value)},W.name==="setValueFromShortcut"&&(ue.shortcut=W.shortcut)),ue);ce&&O(W.value,ye()),te&&i&&i(W.value,ye()),se&&_(!1)});if(L.lastControlledValue!==a){const W=e.areValuesEqual(S,L.draft,E);P(ee=>ne({},ee,{lastControlledValue:a},W?{}:{lastCommittedValue:E,lastPublishedValue:E,draft:E,hasBeenModifiedSinceMount:!0}))}const N=Be(()=>{A({value:e.emptyValue,name:"setValueFromAction",pickerAction:"clear"})}),z=Be(()=>{A({value:L.lastPublishedValue,name:"setValueFromAction",pickerAction:"accept"})}),V=Be(()=>{A({value:L.lastPublishedValue,name:"setValueFromAction",pickerAction:"dismiss"})}),B=Be(()=>{A({value:L.lastCommittedValue,name:"setValueFromAction",pickerAction:"cancel"})}),R=Be(()=>{A({value:e.getTodayValue(S,w,n),name:"setValueFromAction",pickerAction:"today"})}),q=Be(W=>{W.preventDefault(),_(!0)}),U=Be(W=>{W==null||W.preventDefault(),_(!1)}),G=Be((W,ee="partial")=>A({name:"setValueFromView",value:W,selectionState:ee})),Y=Be((W,ee,ce)=>A({name:"setValueFromShortcut",value:W,changeImportance:ee,shortcut:ce})),Z=Be((W,ee)=>A({name:"setValueFromField",value:W,context:ee})),fe={onClear:N,onAccept:z,onDismiss:V,onCancel:B,onSetToday:R,onOpen:q,onClose:U},pe={value:L.draft,onChange:Z},me=I.useMemo(()=>e.cleanValue(S,L.draft),[S,e,L.draft]),re={value:me,onChange:G,onClose:U,open:T},le=ne({},fe,{value:me,onChange:G,onSelectShortcut:Y,isValid:W=>{const ee=o({adapter:C,value:W,timezone:w,props:t});return!e.hasError(ee)}}),X=I.useMemo(()=>({onOpen:q,onClose:U,open:T}),[T,U,q]);return{open:T,fieldProps:pe,viewProps:re,layoutProps:le,actions:fe,contextValue:X}};let em=!1;function V_({onChange:t,onViewChange:e,openTo:n,view:r,views:o,autoFocus:i,focusedView:s,onFocusedViewChange:a}){process.env.NODE_ENV!=="production"&&(em||(r!=null&&!o.includes(r)&&(console.warn(`MUI X: \`view="${r}"\` is not a valid prop.`,`It must be an element of \`views=["${o.join('", "')}"]\`.`),em=!0),r==null&&n!=null&&!o.includes(n)&&(console.warn(`MUI X: \`openTo="${n}"\` is not a valid prop.`,`It must be an element of \`views=["${o.join('", "')}"]\`.`),em=!0)));const l=I.useRef(n),u=I.useRef(o),f=I.useRef(o.includes(n)?n:o[0]),[p,g]=jo({name:"useViews",state:"view",controlled:r,default:f.current}),m=I.useRef(i?p:null),[y,b]=jo({name:"useViews",state:"focusedView",controlled:s,default:m.current});I.useEffect(()=>{(l.current&&l.current!==n||u.current&&u.current.some(L=>!o.includes(L)))&&(g(o.includes(n)?n:o[0]),u.current=o,l.current=n)},[n,g,p,o]);const S=o.indexOf(p),C=o[S-1]??null,T=o[S+1]??null,_=Be((L,P)=>{b(P?L:$=>L===$?null:$),a==null||a(L,P)}),w=Be(L=>{_(L,!0),L!==p&&(g(L),e&&e(L))}),E=Be(()=>{T&&w(T)}),O=Be((L,P,$)=>{const M=P==="finish",A=$?o.indexOf($)<o.length-1:!!T;if(t(L,M&&A?"partial":P,$),$&&$!==p){const z=o[o.indexOf($)+1];z&&w(z)}else M&&E()});return{view:p,setView:w,focusedView:y,setFocusedView:_,nextView:T,previousView:C,defaultView:o.includes(n)?n:o[0],goToNextView:E,setValueAndGoToNextView:O}}const Tj=["className","sx"],kj=({props:t,propsFromPickerValue:e,additionalViewProps:n,autoFocusView:r,rendererInterceptor:o,fieldRef:i})=>{const{onChange:s,open:a,onClose:l}=e,{view:u,views:f,openTo:p,onViewChange:g,viewRenderers:m,timezone:y}=t,b=rt(t,Tj),{view:S,setView:C,defaultView:T,focusedView:_,setFocusedView:w,setValueAndGoToNextView:E}=V_({view:u,views:f,openTo:p,onChange:s,onViewChange:g,autoFocus:r}),{hasUIView:O,viewModeLookup:L}=I.useMemo(()=>f.reduce((V,B)=>{let R;return m[B]!=null?R="UI":R="field",V.viewModeLookup[B]=R,R==="UI"&&(V.hasUIView=!0),V},{hasUIView:!1,viewModeLookup:{}}),[m,f]),P=I.useMemo(()=>f.reduce((V,B)=>m[B]!=null&&S4(B)?V+1:V,0),[m,f]),$=L[S],M=Be(()=>$==="UI"),[A,N]=I.useState($==="UI"?S:null);return A!==S&&L[S]==="UI"&&N(S),Tn(()=>{$==="field"&&a&&(l(),setTimeout(()=>{var V,B;(V=i==null?void 0:i.current)==null||V.setSelectedSections(S),(B=i==null?void 0:i.current)==null||B.focusField(S)}))},[S]),Tn(()=>{if(!a)return;let V=S;$==="field"&&A!=null&&(V=A),V!==T&&L[V]==="UI"&&L[T]==="UI"&&(V=T),V!==S&&C(V),w(V,!0)},[a]),{hasUIView:O,shouldRestoreFocus:M,layoutProps:{views:f,view:A,onViewChange:C},renderCurrentView:()=>{if(A==null)return null;const V=m[A];if(V==null)return null;const B=ne({},b,n,e,{views:f,timezone:y,onChange:E,view:A,onViewChange:C,focusedView:_,onFocusedViewChange:w,showViewSwitcher:P>1,timeViewsCount:P});return o?o(m,A,B):V(B)}}};function H_(){return typeof window>"u"?"portrait":window.screen&&window.screen.orientation&&window.screen.orientation.angle?Math.abs(window.screen.orientation.angle)===90?"landscape":"portrait":window.orientation&&Math.abs(Number(window.orientation))===90?"landscape":"portrait"}const Ej=(t,e)=>{const[n,r]=I.useState(H_);return Tn(()=>{const i=()=>{r(H_())};return window.addEventListener("orientationchange",i),()=>{window.removeEventListener("orientationchange",i)}},[]),eV(t,["hours","minutes","seconds"])?!1:(e||n)==="landscape"},Mj=({props:t,propsFromPickerValue:e,propsFromPickerViews:n,wrapperVariant:r})=>{const{orientation:o}=t,i=Ej(n.views,o),s=no();return{layoutProps:ne({},n,e,{isLandscape:i,isRtl:s,wrapperVariant:r,disabled:t.disabled,readOnly:t.readOnly})}};function Oj(t){const{props:e,pickerValueResponse:n}=t;return I.useMemo(()=>({value:n.viewProps.value,open:n.open,disabled:e.disabled??!1,readOnly:e.readOnly??!1}),[n.viewProps.value,n.open,e.disabled,e.readOnly])}const j_=({props:t,valueManager:e,valueType:n,wrapperVariant:r,additionalViewProps:o,validator:i,autoFocusView:s,rendererInterceptor:a,fieldRef:l})=>{process.env.NODE_ENV!=="production"&&t.renderInput!=null&&YC(["MUI X: The `renderInput` prop has been removed in version 6.0 of the Date and Time Pickers.","You can replace it with the `textField` component slot in most cases.","For more information, please have a look at the migration guide (https://mui.com/x/migration/migration-pickers-v5/#input-renderer-required-in-v5)."]);const u=_j({props:t,valueManager:e,valueType:n,wrapperVariant:r,validator:i}),f=kj({props:t,additionalViewProps:o,autoFocusView:s,fieldRef:l,propsFromPickerValue:u.viewProps,rendererInterceptor:a}),p=Mj({props:t,wrapperVariant:r,propsFromPickerValue:u.layoutProps,propsFromPickerViews:f.layoutProps}),g=Oj({props:t,pickerValueResponse:u});return{open:u.open,actions:u.actions,fieldProps:u.fieldProps,renderCurrentView:f.renderCurrentView,hasUIView:f.hasUIView,shouldRestoreFocus:f.shouldRestoreFocus,layoutProps:p.layoutProps,contextValue:u.contextValue,ownerState:g}};function W_(t){return Ke("MuiPickersLayout",t)}const xs=qe("MuiPickersLayout",["root","landscape","contentWrapper","toolbar","actionBar","tabs","shortcuts"]);function Aj(t){return Ke("MuiButton",t)}const Ss=qe("MuiButton",["root","text","textInherit","textPrimary","textSecondary","textSuccess","textError","textInfo","textWarning","outlined","outlinedInherit","outlinedPrimary","outlinedSecondary","outlinedSuccess","outlinedError","outlinedInfo","outlinedWarning","contained","containedInherit","containedPrimary","containedSecondary","containedSuccess","containedError","containedInfo","containedWarning","disableElevation","focusVisible","disabled","colorInherit","colorPrimary","colorSecondary","colorSuccess","colorError","colorInfo","colorWarning","textSizeSmall","textSizeMedium","textSizeLarge","outlinedSizeSmall","outlinedSizeMedium","outlinedSizeLarge","containedSizeSmall","containedSizeMedium","containedSizeLarge","sizeMedium","sizeSmall","sizeLarge","fullWidth","startIcon","endIcon","icon","iconSizeSmall","iconSizeMedium","iconSizeLarge","loading","loadingWrapper","loadingIconPlaceholder","loadingIndicator","loadingPositionCenter","loadingPositionStart","loadingPositionEnd"]),q_=I.createContext({});process.env.NODE_ENV!=="production"&&(q_.displayName="ButtonGroupContext");const U_=I.createContext(void 0);process.env.NODE_ENV!=="production"&&(U_.displayName="ButtonGroupButtonContext");const Ij=t=>{const{color:e,disableElevation:n,fullWidth:r,size:o,variant:i,loading:s,loadingPosition:a,classes:l}=t,u={root:["root",s&&"loading",i,`${i}${Ae(e)}`,`size${Ae(o)}`,`${i}Size${Ae(o)}`,`color${Ae(e)}`,n&&"disableElevation",r&&"fullWidth",s&&`loadingPosition${Ae(a)}`],startIcon:["icon","startIcon",`iconSize${Ae(o)}`],endIcon:["icon","endIcon",`iconSize${Ae(o)}`],loadingIndicator:["loadingIndicator"],loadingWrapper:["loadingWrapper"]},f=Ue(u,Aj,l);return{...l,...f}},K_=[{props:{size:"small"},style:{"& > *:nth-of-type(1)":{fontSize:18}}},{props:{size:"medium"},style:{"& > *:nth-of-type(1)":{fontSize:20}}},{props:{size:"large"},style:{"& > *:nth-of-type(1)":{fontSize:22}}}],Dj=be(xa,{shouldForwardProp:t=>ro(t)||t==="classes",name:"MuiButton",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,e[n.variant],e[`${n.variant}${Ae(n.color)}`],e[`size${Ae(n.size)}`],e[`${n.variant}Size${Ae(n.size)}`],n.color==="inherit"&&e.colorInherit,n.disableElevation&&e.disableElevation,n.fullWidth&&e.fullWidth,n.loading&&e.loading]}})(Dt(({theme:t})=>{const e=t.palette.mode==="light"?t.palette.grey[300]:t.palette.grey[800],n=t.palette.mode==="light"?t.palette.grey.A100:t.palette.grey[700];return{...t.typography.button,minWidth:64,padding:"6px 16px",border:0,borderRadius:(t.vars||t).shape.borderRadius,transition:t.transitions.create(["background-color","box-shadow","border-color","color"],{duration:t.transitions.duration.short}),"&:hover":{textDecoration:"none"},[`&.${Ss.disabled}`]:{color:(t.vars||t).palette.action.disabled},variants:[{props:{variant:"contained"},style:{color:"var(--variant-containedColor)",backgroundColor:"var(--variant-containedBg)",boxShadow:(t.vars||t).shadows[2],"&:hover":{boxShadow:(t.vars||t).shadows[4],"@media (hover: none)":{boxShadow:(t.vars||t).shadows[2]}},"&:active":{boxShadow:(t.vars||t).shadows[8]},[`&.${Ss.focusVisible}`]:{boxShadow:(t.vars||t).shadows[6]},[`&.${Ss.disabled}`]:{color:(t.vars||t).palette.action.disabled,boxShadow:(t.vars||t).shadows[0],backgroundColor:(t.vars||t).palette.action.disabledBackground}}},{props:{variant:"outlined"},style:{padding:"5px 15px",border:"1px solid currentColor",borderColor:"var(--variant-outlinedBorder, currentColor)",backgroundColor:"var(--variant-outlinedBg)",color:"var(--variant-outlinedColor)",[`&.${Ss.disabled}`]:{border:`1px solid ${(t.vars||t).palette.action.disabledBackground}`}}},{props:{variant:"text"},style:{padding:"6px 8px",color:"var(--variant-textColor)",backgroundColor:"var(--variant-textBg)"}},...Object.entries(t.palette).filter(Hn()).map(([r])=>({props:{color:r},style:{"--variant-textColor":(t.vars||t).palette[r].main,"--variant-outlinedColor":(t.vars||t).palette[r].main,"--variant-outlinedBorder":t.vars?`rgba(${t.vars.palette[r].mainChannel} / 0.5)`:Rt(t.palette[r].main,.5),"--variant-containedColor":(t.vars||t).palette[r].contrastText,"--variant-containedBg":(t.vars||t).palette[r].main,"@media (hover: hover)":{"&:hover":{"--variant-containedBg":(t.vars||t).palette[r].dark,"--variant-textBg":t.vars?`rgba(${t.vars.palette[r].mainChannel} / ${t.vars.palette.action.hoverOpacity})`:Rt(t.palette[r].main,t.palette.action.hoverOpacity),"--variant-outlinedBorder":(t.vars||t).palette[r].main,"--variant-outlinedBg":t.vars?`rgba(${t.vars.palette[r].mainChannel} / ${t.vars.palette.action.hoverOpacity})`:Rt(t.palette[r].main,t.palette.action.hoverOpacity)}}}})),{props:{color:"inherit"},style:{color:"inherit",borderColor:"currentColor","--variant-containedBg":t.vars?t.vars.palette.Button.inheritContainedBg:e,"@media (hover: hover)":{"&:hover":{"--variant-containedBg":t.vars?t.vars.palette.Button.inheritContainedHoverBg:n,"--variant-textBg":t.vars?`rgba(${t.vars.palette.text.primaryChannel} / ${t.vars.palette.action.hoverOpacity})`:Rt(t.palette.text.primary,t.palette.action.hoverOpacity),"--variant-outlinedBg":t.vars?`rgba(${t.vars.palette.text.primaryChannel} / ${t.vars.palette.action.hoverOpacity})`:Rt(t.palette.text.primary,t.palette.action.hoverOpacity)}}}},{props:{size:"small",variant:"text"},style:{padding:"4px 5px",fontSize:t.typography.pxToRem(13)}},{props:{size:"large",variant:"text"},style:{padding:"8px 11px",fontSize:t.typography.pxToRem(15)}},{props:{size:"small",variant:"outlined"},style:{padding:"3px 9px",fontSize:t.typography.pxToRem(13)}},{props:{size:"large",variant:"outlined"},style:{padding:"7px 21px",fontSize:t.typography.pxToRem(15)}},{props:{size:"small",variant:"contained"},style:{padding:"4px 10px",fontSize:t.typography.pxToRem(13)}},{props:{size:"large",variant:"contained"},style:{padding:"8px 22px",fontSize:t.typography.pxToRem(15)}},{props:{disableElevation:!0},style:{boxShadow:"none","&:hover":{boxShadow:"none"},[`&.${Ss.focusVisible}`]:{boxShadow:"none"},"&:active":{boxShadow:"none"},[`&.${Ss.disabled}`]:{boxShadow:"none"}}},{props:{fullWidth:!0},style:{width:"100%"}},{props:{loadingPosition:"center"},style:{transition:t.transitions.create(["background-color","box-shadow","border-color"],{duration:t.transitions.duration.short}),[`&.${Ss.loading}`]:{color:"transparent"}}}]}})),Pj=be("span",{name:"MuiButton",slot:"StartIcon",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.startIcon,n.loading&&e.startIconLoadingStart,e[`iconSize${Ae(n.size)}`]]}})(({theme:t})=>({display:"inherit",marginRight:8,marginLeft:-4,variants:[{props:{size:"small"},style:{marginLeft:-2}},{props:{loadingPosition:"start",loading:!0},style:{transition:t.transitions.create(["opacity"],{duration:t.transitions.duration.short}),opacity:0}},{props:{loadingPosition:"start",loading:!0,fullWidth:!0},style:{marginRight:-8}},...K_]})),Nj=be("span",{name:"MuiButton",slot:"EndIcon",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.endIcon,n.loading&&e.endIconLoadingEnd,e[`iconSize${Ae(n.size)}`]]}})(({theme:t})=>({display:"inherit",marginRight:-4,marginLeft:8,variants:[{props:{size:"small"},style:{marginRight:-2}},{props:{loadingPosition:"end",loading:!0},style:{transition:t.transitions.create(["opacity"],{duration:t.transitions.duration.short}),opacity:0}},{props:{loadingPosition:"end",loading:!0,fullWidth:!0},style:{marginLeft:-8}},...K_]})),Lj=be("span",{name:"MuiButton",slot:"LoadingIndicator",overridesResolver:(t,e)=>e.loadingIndicator})(({theme:t})=>({display:"none",position:"absolute",visibility:"visible",variants:[{props:{loading:!0},style:{display:"flex"}},{props:{loadingPosition:"start"},style:{left:14}},{props:{loadingPosition:"start",size:"small"},style:{left:10}},{props:{variant:"text",loadingPosition:"start"},style:{left:6}},{props:{loadingPosition:"center"},style:{left:"50%",transform:"translate(-50%)",color:(t.vars||t).palette.action.disabled}},{props:{loadingPosition:"end"},style:{right:14}},{props:{loadingPosition:"end",size:"small"},style:{right:10}},{props:{variant:"text",loadingPosition:"end"},style:{right:6}},{props:{loadingPosition:"start",fullWidth:!0},style:{position:"relative",left:-10}},{props:{loadingPosition:"end",fullWidth:!0},style:{position:"relative",right:-10}}]})),Y_=be("span",{name:"MuiButton",slot:"LoadingIconPlaceholder",overridesResolver:(t,e)=>e.loadingIconPlaceholder})({display:"inline-block",width:"1em",height:"1em"}),cc=I.forwardRef(function(e,n){const r=I.useContext(q_),o=I.useContext(U_),i=Cl(r,e),s=St({props:i,name:"MuiButton"}),{children:a,color:l="primary",component:u="button",className:f,disabled:p=!1,disableElevation:g=!1,disableFocusRipple:m=!1,endIcon:y,focusVisibleClassName:b,fullWidth:S=!1,id:C,loading:T=null,loadingIndicator:_,loadingPosition:w="center",size:E="medium",startIcon:O,type:L,variant:P="text",...$}=s,M=vo(C),A=_??v.jsx(Rg,{"aria-labelledby":M,color:"inherit",size:16}),N={...s,color:l,component:u,disabled:p,disableElevation:g,disableFocusRipple:m,fullWidth:S,loading:T,loadingIndicator:A,loadingPosition:w,size:E,type:L,variant:P},z=Ij(N),V=(O||T&&w==="start")&&v.jsx(Pj,{className:z.startIcon,ownerState:N,children:O||v.jsx(Y_,{className:z.loadingIconPlaceholder,ownerState:N})}),B=(y||T&&w==="end")&&v.jsx(Nj,{className:z.endIcon,ownerState:N,children:y||v.jsx(Y_,{className:z.loadingIconPlaceholder,ownerState:N})}),R=o||"",q=typeof T=="boolean"?v.jsx("span",{className:z.loadingWrapper,style:{display:"contents"},children:T&&v.jsx(Lj,{className:z.loadingIndicator,ownerState:N,children:A})}):null;return v.jsxs(Dj,{ownerState:N,className:Le(r.className,z.root,f,R),component:u,disabled:p||T,focusRipple:!m,focusVisibleClassName:Le(z.focusVisible,b),ref:n,type:L,id:T?M:C,...$,classes:z,children:[V,w!=="end"&&q,a,w==="end"&&q,B]})});process.env.NODE_ENV!=="production"&&(cc.propTypes={children:c.node,classes:c.object,className:c.string,color:c.oneOfType([c.oneOf(["inherit","primary","secondary","success","error","info","warning"]),c.string]),component:c.elementType,disabled:c.bool,disableElevation:c.bool,disableFocusRipple:c.bool,disableRipple:c.bool,endIcon:c.node,focusVisibleClassName:c.string,fullWidth:c.bool,href:c.string,id:c.string,loading:c.bool,loadingIndicator:c.node,loadingPosition:c.oneOf(["center","end","start"]),size:c.oneOfType([c.oneOf(["small","medium","large"]),c.string]),startIcon:c.node,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),type:c.oneOfType([c.oneOf(["button","reset","submit"]),c.string]),variant:c.oneOfType([c.oneOf(["contained","outlined","text"]),c.string])});function Fj(t){return Ke("MuiDialogActions",t)}qe("MuiDialogActions",["root","spacing"]);const $j=t=>{const{classes:e,disableSpacing:n}=t;return Ue({root:["root",!n&&"spacing"]},Fj,e)},Bj=be("div",{name:"MuiDialogActions",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,!n.disableSpacing&&e.spacing]}})({display:"flex",alignItems:"center",padding:8,justifyContent:"flex-end",flex:"0 0 auto",variants:[{props:({ownerState:t})=>!t.disableSpacing,style:{"& > :not(style) ~ :not(style)":{marginLeft:8}}}]}),G_=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiDialogActions"}),{className:o,disableSpacing:i=!1,...s}=r,a={...r,disableSpacing:i},l=$j(a);return v.jsx(Bj,{className:Le(l.root,o),ownerState:a,ref:n,...s})});process.env.NODE_ENV!=="production"&&(G_.propTypes={children:c.node,classes:c.object,className:c.string,disableSpacing:c.bool,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object])});const Rj=["onAccept","onClear","onCancel","onSetToday","actions"];function J_(t){const{onAccept:e,onClear:n,onCancel:r,onSetToday:o,actions:i}=t,s=rt(t,Rj),a=Ko();if(i==null||i.length===0)return null;const l=i==null?void 0:i.map(u=>{switch(u){case"clear":return v.jsx(cc,{onClick:n,children:a.clearButtonLabel},u);case"cancel":return v.jsx(cc,{onClick:r,children:a.cancelButtonLabel},u);case"accept":return v.jsx(cc,{onClick:e,children:a.okButtonLabel},u);case"today":return v.jsx(cc,{onClick:o,children:a.todayButtonLabel},u);default:return null}});return v.jsx(G_,ne({},s,{children:l}))}process.env.NODE_ENV!=="production"&&(J_.propTypes={actions:c.arrayOf(c.oneOf(["accept","cancel","clear","today"]).isRequired),disableSpacing:c.bool,onAccept:c.func.isRequired,onCancel:c.func.isRequired,onClear:c.func.isRequired,onSetToday:c.func.isRequired,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object])});function zj(t){return Ke("MuiListItem",t)}qe("MuiListItem",["root","container","dense","alignItemsFlexStart","divider","gutters","padding","secondaryAction"]);const Vj=qe("MuiListItemButton",["root","focusVisible","dense","alignItemsFlexStart","disabled","divider","gutters","selected"]);function Hj(t){return Ke("MuiListItemSecondaryAction",t)}qe("MuiListItemSecondaryAction",["root","disableGutters"]);const jj=t=>{const{disableGutters:e,classes:n}=t;return Ue({root:["root",e&&"disableGutters"]},Hj,n)},Wj=be("div",{name:"MuiListItemSecondaryAction",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,n.disableGutters&&e.disableGutters]}})({position:"absolute",right:16,top:"50%",transform:"translateY(-50%)",variants:[{props:({ownerState:t})=>t.disableGutters,style:{right:0}}]}),tm=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiListItemSecondaryAction"}),{className:o,...i}=r,s=I.useContext(ha),a={...r,disableGutters:s.disableGutters},l=jj(a);return v.jsx(Wj,{className:Le(l.root,o),ownerState:a,ref:n,...i})});process.env.NODE_ENV!=="production"&&(tm.propTypes={children:c.node,classes:c.object,className:c.string,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object])}),tm.muiName="ListItemSecondaryAction";const qj=(t,e)=>{const{ownerState:n}=t;return[e.root,n.dense&&e.dense,n.alignItems==="flex-start"&&e.alignItemsFlexStart,n.divider&&e.divider,!n.disableGutters&&e.gutters,!n.disablePadding&&e.padding,n.hasSecondaryAction&&e.secondaryAction]},Uj=t=>{const{alignItems:e,classes:n,dense:r,disableGutters:o,disablePadding:i,divider:s,hasSecondaryAction:a}=t;return Ue({root:["root",r&&"dense",!o&&"gutters",!i&&"padding",s&&"divider",e==="flex-start"&&"alignItemsFlexStart",a&&"secondaryAction"],container:["container"]},zj,n)},Kj=be("div",{name:"MuiListItem",slot:"Root",overridesResolver:qj})(Dt(({theme:t})=>({display:"flex",justifyContent:"flex-start",alignItems:"center",position:"relative",textDecoration:"none",width:"100%",boxSizing:"border-box",textAlign:"left",variants:[{props:({ownerState:e})=>!e.disablePadding,style:{paddingTop:8,paddingBottom:8}},{props:({ownerState:e})=>!e.disablePadding&&e.dense,style:{paddingTop:4,paddingBottom:4}},{props:({ownerState:e})=>!e.disablePadding&&!e.disableGutters,style:{paddingLeft:16,paddingRight:16}},{props:({ownerState:e})=>!e.disablePadding&&!!e.secondaryAction,style:{paddingRight:48}},{props:({ownerState:e})=>!!e.secondaryAction,style:{[`& > .${Vj.root}`]:{paddingRight:48}}},{props:{alignItems:"flex-start"},style:{alignItems:"flex-start"}},{props:({ownerState:e})=>e.divider,style:{borderBottom:`1px solid ${(t.vars||t).palette.divider}`,backgroundClip:"padding-box"}},{props:({ownerState:e})=>e.button,style:{transition:t.transitions.create("background-color",{duration:t.transitions.duration.shortest}),"&:hover":{textDecoration:"none",backgroundColor:(t.vars||t).palette.action.hover,"@media (hover: none)":{backgroundColor:"transparent"}}}},{props:({ownerState:e})=>e.hasSecondaryAction,style:{paddingRight:48}}]}))),Yj=be("li",{name:"MuiListItem",slot:"Container",overridesResolver:(t,e)=>e.container})({position:"relative"}),Z_=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiListItem"}),{alignItems:o="center",children:i,className:s,component:a,components:l={},componentsProps:u={},ContainerComponent:f="li",ContainerProps:{className:p,...g}={},dense:m=!1,disableGutters:y=!1,disablePadding:b=!1,divider:S=!1,secondaryAction:C,slotProps:T={},slots:_={},...w}=r,E=I.useContext(ha),O=I.useMemo(()=>({dense:m||E.dense||!1,alignItems:o,disableGutters:y}),[o,E.dense,m,y]),L=I.useRef(null),P=I.Children.toArray(i),$=P.length&&Sl(P[P.length-1],["ListItemSecondaryAction"]),M={...r,alignItems:o,dense:O.dense,disableGutters:y,disablePadding:b,divider:S,hasSecondaryAction:$},A=Uj(M),N=Et(L,n),z=_.root||l.Root||Kj,V=T.root||u.root||{},B={className:Le(A.root,V.className,s),...w};let R=a||"li";return $?(R=!B.component&&!a?"div":R,f==="li"&&(R==="li"?R="div":B.component==="li"&&(B.component="div")),v.jsx(ha.Provider,{value:O,children:v.jsxs(Yj,{as:f,className:Le(A.container,p),ref:N,ownerState:M,...g,children:[v.jsx(z,{...V,...!$l(z)&&{as:R,ownerState:{...M,...V.ownerState}},...B,children:P}),P.pop()]})})):v.jsx(ha.Provider,{value:O,children:v.jsxs(z,{...V,as:R,ref:N,...!$l(z)&&{ownerState:{...M,...V.ownerState}},...B,children:[P,C&&v.jsx(tm,{children:C})]})})});process.env.NODE_ENV!=="production"&&(Z_.propTypes={alignItems:c.oneOf(["center","flex-start"]),children:zo(c.node,t=>{const e=I.Children.toArray(t.children);let n=-1;for(let r=e.length-1;r>=0;r-=1){const o=e[r];if(Sl(o,["ListItemSecondaryAction"])){n=r;break}}return n!==-1&&n!==e.length-1?new Error("MUI: You used an element after ListItemSecondaryAction. For ListItem to detect that it has a secondary action you must pass it as the last child to ListItem."):null}),classes:c.object,className:c.string,component:c.elementType,components:c.shape({Root:c.elementType}),componentsProps:c.shape({root:c.object}),ContainerComponent:Eu,ContainerProps:c.object,dense:c.bool,disableGutters:c.bool,disablePadding:c.bool,divider:c.bool,secondaryAction:c.node,slotProps:c.shape({root:c.object}),slots:c.shape({root:c.elementType}),sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object])});const Gj=ze(v.jsx("path",{d:"M12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2zm5 13.59L15.59 17 12 13.41 8.41 17 7 15.59 10.59 12 7 8.41 8.41 7 12 10.59 15.59 7 17 8.41 13.41 12 17 15.59z"}),"Cancel");function Jj(t){return Ke("MuiChip",t)}const pt=qe("MuiChip",["root","sizeSmall","sizeMedium","colorDefault","colorError","colorInfo","colorPrimary","colorSecondary","colorSuccess","colorWarning","disabled","clickable","clickableColorPrimary","clickableColorSecondary","deletable","deletableColorPrimary","deletableColorSecondary","outlined","filled","outlinedPrimary","outlinedSecondary","filledPrimary","filledSecondary","avatar","avatarSmall","avatarMedium","avatarColorPrimary","avatarColorSecondary","icon","iconSmall","iconMedium","iconColorPrimary","iconColorSecondary","label","labelSmall","labelMedium","deleteIcon","deleteIconSmall","deleteIconMedium","deleteIconColorPrimary","deleteIconColorSecondary","deleteIconOutlinedColorPrimary","deleteIconOutlinedColorSecondary","deleteIconFilledColorPrimary","deleteIconFilledColorSecondary","focusVisible"]),Zj=t=>{const{classes:e,disabled:n,size:r,color:o,iconColor:i,onDelete:s,clickable:a,variant:l}=t,u={root:["root",l,n&&"disabled",`size${Ae(r)}`,`color${Ae(o)}`,a&&"clickable",a&&`clickableColor${Ae(o)}`,s&&"deletable",s&&`deletableColor${Ae(o)}`,`${l}${Ae(o)}`],label:["label",`label${Ae(r)}`],avatar:["avatar",`avatar${Ae(r)}`,`avatarColor${Ae(o)}`],icon:["icon",`icon${Ae(r)}`,`iconColor${Ae(i)}`],deleteIcon:["deleteIcon",`deleteIcon${Ae(r)}`,`deleteIconColor${Ae(o)}`,`deleteIcon${Ae(l)}Color${Ae(o)}`]};return Ue(u,Jj,e)},Xj=be("div",{name:"MuiChip",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t,{color:r,iconColor:o,clickable:i,onDelete:s,size:a,variant:l}=n;return[{[`& .${pt.avatar}`]:e.avatar},{[`& .${pt.avatar}`]:e[`avatar${Ae(a)}`]},{[`& .${pt.avatar}`]:e[`avatarColor${Ae(r)}`]},{[`& .${pt.icon}`]:e.icon},{[`& .${pt.icon}`]:e[`icon${Ae(a)}`]},{[`& .${pt.icon}`]:e[`iconColor${Ae(o)}`]},{[`& .${pt.deleteIcon}`]:e.deleteIcon},{[`& .${pt.deleteIcon}`]:e[`deleteIcon${Ae(a)}`]},{[`& .${pt.deleteIcon}`]:e[`deleteIconColor${Ae(r)}`]},{[`& .${pt.deleteIcon}`]:e[`deleteIcon${Ae(l)}Color${Ae(r)}`]},e.root,e[`size${Ae(a)}`],e[`color${Ae(r)}`],i&&e.clickable,i&&r!=="default"&&e[`clickableColor${Ae(r)})`],s&&e.deletable,s&&r!=="default"&&e[`deletableColor${Ae(r)}`],e[l],e[`${l}${Ae(r)}`]]}})(Dt(({theme:t})=>{const e=t.palette.mode==="light"?t.palette.grey[700]:t.palette.grey[300];return{maxWidth:"100%",fontFamily:t.typography.fontFamily,fontSize:t.typography.pxToRem(13),display:"inline-flex",alignItems:"center",justifyContent:"center",height:32,color:(t.vars||t).palette.text.primary,backgroundColor:(t.vars||t).palette.action.selected,borderRadius:32/2,whiteSpace:"nowrap",transition:t.transitions.create(["background-color","box-shadow"]),cursor:"unset",outline:0,textDecoration:"none",border:0,padding:0,verticalAlign:"middle",boxSizing:"border-box",[`&.${pt.disabled}`]:{opacity:(t.vars||t).palette.action.disabledOpacity,pointerEvents:"none"},[`& .${pt.avatar}`]:{marginLeft:5,marginRight:-6,width:24,height:24,color:t.vars?t.vars.palette.Chip.defaultAvatarColor:e,fontSize:t.typography.pxToRem(12)},[`& .${pt.avatarColorPrimary}`]:{color:(t.vars||t).palette.primary.contrastText,backgroundColor:(t.vars||t).palette.primary.dark},[`& .${pt.avatarColorSecondary}`]:{color:(t.vars||t).palette.secondary.contrastText,backgroundColor:(t.vars||t).palette.secondary.dark},[`& .${pt.avatarSmall}`]:{marginLeft:4,marginRight:-4,width:18,height:18,fontSize:t.typography.pxToRem(10)},[`& .${pt.icon}`]:{marginLeft:5,marginRight:-6},[`& .${pt.deleteIcon}`]:{WebkitTapHighlightColor:"transparent",color:t.vars?`rgba(${t.vars.palette.text.primaryChannel} / 0.26)`:Rt(t.palette.text.primary,.26),fontSize:22,cursor:"pointer",margin:"0 5px 0 -6px","&:hover":{color:t.vars?`rgba(${t.vars.palette.text.primaryChannel} / 0.4)`:Rt(t.palette.text.primary,.4)}},variants:[{props:{size:"small"},style:{height:24,[`& .${pt.icon}`]:{fontSize:18,marginLeft:4,marginRight:-4},[`& .${pt.deleteIcon}`]:{fontSize:16,marginRight:4,marginLeft:-4}}},...Object.entries(t.palette).filter(Hn(["contrastText"])).map(([n])=>({props:{color:n},style:{backgroundColor:(t.vars||t).palette[n].main,color:(t.vars||t).palette[n].contrastText,[`& .${pt.deleteIcon}`]:{color:t.vars?`rgba(${t.vars.palette[n].contrastTextChannel} / 0.7)`:Rt(t.palette[n].contrastText,.7),"&:hover, &:active":{color:(t.vars||t).palette[n].contrastText}}}})),{props:n=>n.iconColor===n.color,style:{[`& .${pt.icon}`]:{color:t.vars?t.vars.palette.Chip.defaultIconColor:e}}},{props:n=>n.iconColor===n.color&&n.color!=="default",style:{[`& .${pt.icon}`]:{color:"inherit"}}},{props:{onDelete:!0},style:{[`&.${pt.focusVisible}`]:{backgroundColor:t.vars?`rgba(${t.vars.palette.action.selectedChannel} / calc(${t.vars.palette.action.selectedOpacity} + ${t.vars.palette.action.focusOpacity}))`:Rt(t.palette.action.selected,t.palette.action.selectedOpacity+t.palette.action.focusOpacity)}}},...Object.entries(t.palette).filter(Hn(["dark"])).map(([n])=>({props:{color:n,onDelete:!0},style:{[`&.${pt.focusVisible}`]:{background:(t.vars||t).palette[n].dark}}})),{props:{clickable:!0},style:{userSelect:"none",WebkitTapHighlightColor:"transparent",cursor:"pointer","&:hover":{backgroundColor:t.vars?`rgba(${t.vars.palette.action.selectedChannel} / calc(${t.vars.palette.action.selectedOpacity} + ${t.vars.palette.action.hoverOpacity}))`:Rt(t.palette.action.selected,t.palette.action.selectedOpacity+t.palette.action.hoverOpacity)},[`&.${pt.focusVisible}`]:{backgroundColor:t.vars?`rgba(${t.vars.palette.action.selectedChannel} / calc(${t.vars.palette.action.selectedOpacity} + ${t.vars.palette.action.focusOpacity}))`:Rt(t.palette.action.selected,t.palette.action.selectedOpacity+t.palette.action.focusOpacity)},"&:active":{boxShadow:(t.vars||t).shadows[1]}}},...Object.entries(t.palette).filter(Hn(["dark"])).map(([n])=>({props:{color:n,clickable:!0},style:{[`&:hover, &.${pt.focusVisible}`]:{backgroundColor:(t.vars||t).palette[n].dark}}})),{props:{variant:"outlined"},style:{backgroundColor:"transparent",border:t.vars?`1px solid ${t.vars.palette.Chip.defaultBorder}`:`1px solid ${t.palette.mode==="light"?t.palette.grey[400]:t.palette.grey[700]}`,[`&.${pt.clickable}:hover`]:{backgroundColor:(t.vars||t).palette.action.hover},[`&.${pt.focusVisible}`]:{backgroundColor:(t.vars||t).palette.action.focus},[`& .${pt.avatar}`]:{marginLeft:4},[`& .${pt.avatarSmall}`]:{marginLeft:2},[`& .${pt.icon}`]:{marginLeft:4},[`& .${pt.iconSmall}`]:{marginLeft:2},[`& .${pt.deleteIcon}`]:{marginRight:5},[`& .${pt.deleteIconSmall}`]:{marginRight:3}}},...Object.entries(t.palette).filter(Hn()).map(([n])=>({props:{variant:"outlined",color:n},style:{color:(t.vars||t).palette[n].main,border:`1px solid ${t.vars?`rgba(${t.vars.palette[n].mainChannel} / 0.7)`:Rt(t.palette[n].main,.7)}`,[`&.${pt.clickable}:hover`]:{backgroundColor:t.vars?`rgba(${t.vars.palette[n].mainChannel} / ${t.vars.palette.action.hoverOpacity})`:Rt(t.palette[n].main,t.palette.action.hoverOpacity)},[`&.${pt.focusVisible}`]:{backgroundColor:t.vars?`rgba(${t.vars.palette[n].mainChannel} / ${t.vars.palette.action.focusOpacity})`:Rt(t.palette[n].main,t.palette.action.focusOpacity)},[`& .${pt.deleteIcon}`]:{color:t.vars?`rgba(${t.vars.palette[n].mainChannel} / 0.7)`:Rt(t.palette[n].main,.7),"&:hover, &:active":{color:(t.vars||t).palette[n].main}}}}))]}})),Qj=be("span",{name:"MuiChip",slot:"Label",overridesResolver:(t,e)=>{const{ownerState:n}=t,{size:r}=n;return[e.label,e[`label${Ae(r)}`]]}})({overflow:"hidden",textOverflow:"ellipsis",paddingLeft:12,paddingRight:12,whiteSpace:"nowrap",variants:[{props:{variant:"outlined"},style:{paddingLeft:11,paddingRight:11}},{props:{size:"small"},style:{paddingLeft:8,paddingRight:8}},{props:{size:"small",variant:"outlined"},style:{paddingLeft:7,paddingRight:7}}]});function X_(t){return t.key==="Backspace"||t.key==="Delete"}const Q_=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiChip"}),{avatar:o,className:i,clickable:s,color:a="default",component:l,deleteIcon:u,disabled:f=!1,icon:p,label:g,onClick:m,onDelete:y,onKeyDown:b,onKeyUp:S,size:C="medium",variant:T="filled",tabIndex:_,skipFocusWhenDisabled:w=!1,...E}=r,O=I.useRef(null),L=Et(O,n),P=G=>{G.stopPropagation(),y&&y(G)},$=G=>{G.currentTarget===G.target&&X_(G)&&G.preventDefault(),b&&b(G)},M=G=>{G.currentTarget===G.target&&y&&X_(G)&&y(G),S&&S(G)},A=s!==!1&&m?!0:s,N=A||y?xa:l||"div",z={...r,component:N,disabled:f,size:C,color:a,iconColor:I.isValidElement(p)&&p.props.color||a,onDelete:!!y,clickable:A,variant:T},V=Zj(z),B=N===xa?{component:l||"div",focusVisibleClassName:V.focusVisible,...y&&{disableRipple:!0}}:{};let R=null;y&&(R=u&&I.isValidElement(u)?I.cloneElement(u,{className:Le(u.props.className,V.deleteIcon),onClick:P}):v.jsx(Gj,{className:Le(V.deleteIcon),onClick:P}));let q=null;o&&I.isValidElement(o)&&(q=I.cloneElement(o,{className:Le(V.avatar,o.props.className)}));let U=null;return p&&I.isValidElement(p)&&(U=I.cloneElement(p,{className:Le(V.icon,p.props.className)})),process.env.NODE_ENV!=="production"&&q&&U&&console.error("MUI: The Chip component can not handle the avatar and the icon prop at the same time. Pick one."),v.jsxs(Xj,{as:N,className:Le(V.root,i),disabled:A&&f?!0:void 0,onClick:m,onKeyDown:$,onKeyUp:M,ref:L,tabIndex:w&&f?-1:_,ownerState:z,...B,...E,children:[q||U,v.jsx(Qj,{className:Le(V.label),ownerState:z,children:g}),R]})});process.env.NODE_ENV!=="production"&&(Q_.propTypes={avatar:c.element,children:e$,classes:c.object,className:c.string,clickable:c.bool,color:c.oneOfType([c.oneOf(["default","primary","secondary","error","info","success","warning"]),c.string]),component:c.elementType,deleteIcon:c.element,disabled:c.bool,icon:c.element,label:c.node,onClick:c.func,onDelete:c.func,onKeyDown:c.func,onKeyUp:c.func,size:c.oneOfType([c.oneOf(["medium","small"]),c.string]),skipFocusWhenDisabled:c.bool,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),tabIndex:c.number,variant:c.oneOfType([c.oneOf(["filled","outlined"]),c.string])});const uc=36,Dd=2,Pd=320,eW=280,nm=336,tW=["items","changeImportance","isLandscape","onChange","isValid"],nW=["getValue"];function eT(t){const{items:e,changeImportance:n="accept",onChange:r,isValid:o}=t,i=rt(t,tW);if(e==null||e.length===0)return null;const s=e.map(a=>{let{getValue:l}=a,u=rt(a,nW);const f=l({isValid:o});return ne({},u,{label:u.label,onClick:()=>{r(f,n,u)},disabled:!o(f)})});return v.jsx(fg,ne({dense:!0,sx:[{maxHeight:nm,maxWidth:200,overflow:"auto"},...Array.isArray(i.sx)?i.sx:[i.sx]]},i,{children:s.map(a=>v.jsx(Z_,{children:v.jsx(Q_,ne({},a))},a.id??a.label))}))}process.env.NODE_ENV!=="production"&&(eT.propTypes={changeImportance:c.oneOf(["accept","set"]),className:c.string,component:c.elementType,dense:c.bool,disablePadding:c.bool,isLandscape:c.bool.isRequired,isValid:c.func.isRequired,items:c.arrayOf(c.shape({getValue:c.func.isRequired,id:c.string,label:c.string.isRequired})),onChange:c.func.isRequired,style:c.object,subheader:c.node,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object])});function rW(t){return t.view!==null}const oW=t=>{const{classes:e,isLandscape:n}=t;return Ue({root:["root",n&&"landscape"],contentWrapper:["contentWrapper"],toolbar:["toolbar"],actionBar:["actionBar"],tabs:["tabs"],landscape:["landscape"],shortcuts:["shortcuts"]},W_,e)},iW=t=>{const{wrapperVariant:e,onAccept:n,onClear:r,onCancel:o,onSetToday:i,view:s,views:a,onViewChange:l,value:u,onChange:f,onSelectShortcut:p,isValid:g,isLandscape:m,disabled:y,readOnly:b,children:S,slots:C,slotProps:T}=t,_=oW(t),w=(C==null?void 0:C.actionBar)??J_,E=wt({elementType:w,externalSlotProps:T==null?void 0:T.actionBar,additionalProps:{onAccept:n,onClear:r,onCancel:o,onSetToday:i,actions:e==="desktop"?[]:["cancel","accept"]},className:_.actionBar,ownerState:ne({},t,{wrapperVariant:e})}),O=v.jsx(w,ne({},E)),L=C==null?void 0:C.toolbar,P=wt({elementType:L,externalSlotProps:T==null?void 0:T.toolbar,additionalProps:{isLandscape:m,onChange:f,value:u,view:s,onViewChange:l,views:a,disabled:y,readOnly:b},className:_.toolbar,ownerState:ne({},t,{wrapperVariant:e})}),$=rW(P)&&L?v.jsx(L,ne({},P)):null,M=S,A=C==null?void 0:C.tabs,N=s&&A?v.jsx(A,ne({view:s,onViewChange:l,className:_.tabs},T==null?void 0:T.tabs)):null,z=(C==null?void 0:C.shortcuts)??eT,V=wt({elementType:z,externalSlotProps:T==null?void 0:T.shortcuts,additionalProps:{isValid:g,isLandscape:m,onChange:p},className:_.shortcuts,ownerState:{isValid:g,isLandscape:m,onChange:p,wrapperVariant:e}}),B=s&&z?v.jsx(z,ne({},V)):null;return{toolbar:$,content:M,tabs:N,actionBar:O,shortcuts:B}},sW=t=>{const{isLandscape:e,classes:n}=t;return Ue({root:["root",e&&"landscape"],contentWrapper:["contentWrapper"]},W_,n)},aW=be("div",{name:"MuiPickersLayout",slot:"Root",overridesResolver:(t,e)=>e.root})({display:"grid",gridAutoColumns:"max-content auto max-content",gridAutoRows:"max-content auto max-content",[`& .${xs.actionBar}`]:{gridColumn:"1 / 4",gridRow:3},variants:[{props:{isLandscape:!0},style:{[`& .${xs.toolbar}`]:{gridColumn:1,gridRow:"2 / 3"},[`.${xs.shortcuts}`]:{gridColumn:"2 / 4",gridRow:1}}},{props:{isLandscape:!0,isRtl:!0},style:{[`& .${xs.toolbar}`]:{gridColumn:3}}},{props:{isLandscape:!1},style:{[`& .${xs.toolbar}`]:{gridColumn:"2 / 4",gridRow:1},[`& .${xs.shortcuts}`]:{gridColumn:1,gridRow:"2 / 3"}}},{props:{isLandscape:!1,isRtl:!0},style:{[`& .${xs.shortcuts}`]:{gridColumn:3}}}]}),lW=be("div",{name:"MuiPickersLayout",slot:"ContentWrapper",overridesResolver:(t,e)=>e.contentWrapper})({gridColumn:2,gridRow:2,display:"flex",flexDirection:"column"}),rm=I.forwardRef(function(e,n){const r=Wt({props:e,name:"MuiPickersLayout"}),{toolbar:o,content:i,tabs:s,actionBar:a,shortcuts:l}=iW(r),{sx:u,className:f,isLandscape:p,wrapperVariant:g}=r,m=sW(r);return v.jsxs(aW,{ref:n,sx:u,className:Le(m.root,f),ownerState:r,children:[p?l:o,p?o:l,v.jsx(lW,{className:m.contentWrapper,children:g==="desktop"?v.jsxs(I.Fragment,{children:[i,s]}):v.jsxs(I.Fragment,{children:[s,i]})}),a]})});process.env.NODE_ENV!=="production"&&(rm.propTypes={children:c.node,classes:c.object,className:c.string,disabled:c.bool,isLandscape:c.bool.isRequired,isRtl:c.bool.isRequired,isValid:c.func.isRequired,onAccept:c.func.isRequired,onCancel:c.func.isRequired,onChange:c.func.isRequired,onClear:c.func.isRequired,onClose:c.func.isRequired,onDismiss:c.func.isRequired,onOpen:c.func.isRequired,onSelectShortcut:c.func.isRequired,onSetToday:c.func.isRequired,onViewChange:c.func.isRequired,orientation:c.oneOf(["landscape","portrait"]),readOnly:c.bool,slotProps:c.object,slots:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),value:c.any,view:c.oneOf(["day","hours","meridiem","minutes","month","seconds","year"]),views:c.arrayOf(c.oneOf(["day","hours","meridiem","minutes","month","seconds","year"]).isRequired).isRequired,wrapperVariant:c.oneOf(["desktop","mobile"])});const cW=["props","getOpenDialogAriaText"],uW=["ownerState"],dW=["ownerState"],fW=t=>{var ye;let{props:e,getOpenDialogAriaText:n}=t,r=rt(t,cW);const{slots:o,slotProps:i,className:s,sx:a,format:l,formatDensity:u,enableAccessibleFieldDOMStructure:f,selectedSections:p,onSelectedSectionsChange:g,timezone:m,name:y,label:b,inputRef:S,readOnly:C,disabled:T,autoFocus:_,localeText:w,reduceAnimations:E}=e,O=I.useRef(null),L=I.useRef(null),P=vo(),$=((ye=i==null?void 0:i.toolbar)==null?void 0:ye.hidden)??!1,{open:M,actions:A,hasUIView:N,layoutProps:z,renderCurrentView:V,shouldRestoreFocus:B,fieldProps:R,contextValue:q,ownerState:U}=j_(ne({},r,{props:e,fieldRef:L,autoFocusView:!0,additionalViewProps:{},wrapperVariant:"desktop"})),G=o.inputAdornment??zg,Y=wt({elementType:G,externalSlotProps:i==null?void 0:i.inputAdornment,additionalProps:{position:"end"},ownerState:e}),Z=rt(Y,uW),fe=o.openPickerButton??Sa,pe=wt({elementType:fe,externalSlotProps:i==null?void 0:i.openPickerButton,additionalProps:{disabled:T||C,onClick:M?A.onClose:A.onOpen,"aria-label":n(R.value),edge:Z.position},ownerState:e}),me=rt(pe,dW),re=o.openPickerIcon,he=wt({elementType:re,externalSlotProps:i==null?void 0:i.openPickerIcon,ownerState:U}),le=o.field,X=wt({elementType:le,externalSlotProps:i==null?void 0:i.field,additionalProps:ne({},R,$&&{id:P},{readOnly:C,disabled:T,className:s,sx:a,format:l,formatDensity:u,enableAccessibleFieldDOMStructure:f,selectedSections:p,onSelectedSectionsChange:g,timezone:m,label:b,name:y,autoFocus:_&&!e.open,focused:M?!0:void 0},S?{inputRef:S}:{}),ownerState:e});N&&(X.InputProps=ne({},X.InputProps,{ref:O},!e.disableOpenPicker&&{[`${Z.position}Adornment`]:v.jsx(G,ne({},Z,{children:v.jsx(fe,ne({},me,{children:v.jsx(re,ne({},he))}))}))}));const W=ne({textField:o.textField,clearIcon:o.clearIcon,clearButton:o.clearButton},X.slots),ee=o.layout??rm;let ce=P;$&&(b?ce=`${P}-label`:ce=void 0);const te=ne({},i,{toolbar:ne({},i==null?void 0:i.toolbar,{titleId:P}),popper:ne({"aria-labelledby":ce},i==null?void 0:i.popper)}),se=Et(L,X.unstableFieldRef);return{renderPicker:()=>v.jsxs(r_,{contextValue:q,localeText:w,children:[v.jsx(le,ne({},X,{slots:W,slotProps:te,unstableFieldRef:se})),v.jsx(vj,ne({role:"dialog",placement:"bottom-start",anchorEl:O.current},A,{open:M,slots:o,slotProps:te,shouldRestoreFocus:B,reduceAnimations:E,children:v.jsx(ee,ne({},z,te==null?void 0:te.layout,{slots:o,slotProps:te,children:V()}))}))]})}},tT=({shouldDisableDate:t,shouldDisableMonth:e,shouldDisableYear:n,minDate:r,maxDate:o,disableFuture:i,disablePast:s,timezone:a})=>{const l=ms();return I.useCallback(u=>Xl({adapter:l,value:u,timezone:a,props:{shouldDisableDate:t,shouldDisableMonth:e,shouldDisableYear:n,minDate:r,maxDate:o,disableFuture:i,disablePast:s}})!==null,[l,t,e,n,r,o,i,s,a])},pW=(t,e,n)=>(r,o)=>{switch(o.type){case"changeMonth":return ne({},r,{slideDirection:o.direction,currentMonth:o.newMonth,isMonthSwitchingAnimating:!t});case"changeMonthTimezone":{const i=o.newTimezone;if(n.getTimezone(r.currentMonth)===i)return r;let s=n.setTimezone(r.currentMonth,i);return n.getMonth(s)!==n.getMonth(r.currentMonth)&&(s=n.setMonth(s,n.getMonth(r.currentMonth))),ne({},r,{currentMonth:s})}case"finishMonthSwitchingAnimation":return ne({},r,{isMonthSwitchingAnimating:!1});case"changeFocusedDay":{if(r.focusedDay!=null&&o.focusedDay!=null&&n.isSameDay(o.focusedDay,r.focusedDay))return r;const i=o.focusedDay!=null&&!e&&!n.isSameMonth(r.currentMonth,o.focusedDay);return ne({},r,{focusedDay:o.focusedDay,isMonthSwitchingAnimating:i&&!t&&!o.withoutMonthSwitchingAnimation,currentMonth:i?n.startOfMonth(o.focusedDay):r.currentMonth,slideDirection:o.focusedDay!=null&&n.isAfterDay(o.focusedDay,r.currentMonth)?"left":"right"})}default:throw new Error("missing support")}},hW=t=>{const{value:e,referenceDate:n,disableFuture:r,disablePast:o,disableSwitchToMonthOnDayFocus:i=!1,maxDate:s,minDate:a,onMonthChange:l,reduceAnimations:u,shouldDisableDate:f,timezone:p}=t,g=qt(),m=I.useRef(pW(!!u,i,g)).current,y=I.useMemo(()=>wo.getInitialReferenceValue({value:e,utils:g,timezone:p,props:t,referenceDate:n,granularity:Co.day}),[n,p]),[b,S]=I.useReducer(m,{isMonthSwitchingAnimating:!1,focusedDay:y,currentMonth:g.startOfMonth(y),slideDirection:"left"});I.useEffect(()=>{S({type:"changeMonthTimezone",newTimezone:g.getTimezone(y)})},[y,g]);const C=I.useCallback(O=>{S(ne({type:"changeMonth"},O)),l&&l(O.newMonth)},[l]),T=I.useCallback(O=>{const L=O;g.isSameMonth(L,b.currentMonth)||C({newMonth:g.startOfMonth(L),direction:g.isAfterDay(L,b.currentMonth)?"left":"right"})},[b.currentMonth,C,g]),_=tT({shouldDisableDate:f,minDate:a,maxDate:s,disableFuture:r,disablePast:o,timezone:p}),w=I.useCallback(()=>{S({type:"finishMonthSwitchingAnimation"})},[]),E=Be((O,L)=>{_(O)||S({type:"changeFocusedDay",focusedDay:O,withoutMonthSwitchingAnimation:L})});return{referenceDate:y,calendarState:b,changeMonth:T,changeFocusedDay:E,isDateDisabled:_,onMonthSwitchingAnimationEnd:w,handleChangeMonth:C}},gW=t=>Ke("MuiPickersFadeTransitionGroup",t);qe("MuiPickersFadeTransitionGroup",["root"]);const mW=t=>{const{classes:e}=t;return Ue({root:["root"]},gW,e)},yW=be(jl,{name:"MuiPickersFadeTransitionGroup",slot:"Root",overridesResolver:(t,e)=>e.root})({display:"block",position:"relative"});function nT(t){const e=Wt({props:t,name:"MuiPickersFadeTransitionGroup"}),{children:n,className:r,reduceAnimations:o,transKey:i}=e,s=mW(e),a=Si();return o?n:v.jsx(yW,{className:Le(s.root,r),children:v.jsx(wi,{appear:!1,mountOnEnter:!0,unmountOnExit:!0,timeout:{appear:a.transitions.duration.enteringScreen,enter:a.transitions.duration.enteringScreen,exit:0},children:n},i)})}function bW(t){return Ke("MuiPickersDay",t)}const Cs=qe("MuiPickersDay",["root","dayWithMargin","dayOutsideMonth","hiddenDaySpacingFiller","today","selected","disabled"]),vW=["autoFocus","className","day","disabled","disableHighlightToday","disableMargin","hidden","isAnimating","onClick","onDaySelect","onFocus","onBlur","onKeyDown","onMouseDown","onMouseEnter","outsideCurrentMonth","selected","showDaysOutsideCurrentMonth","children","today","isFirstVisibleCell","isLastVisibleCell"],xW=t=>{const{selected:e,disableMargin:n,disableHighlightToday:r,today:o,disabled:i,outsideCurrentMonth:s,showDaysOutsideCurrentMonth:a,classes:l}=t,u=s&&!a;return Ue({root:["root",e&&!u&&"selected",i&&"disabled",!n&&"dayWithMargin",!r&&o&&"today",s&&a&&"dayOutsideMonth",u&&"hiddenDaySpacingFiller"],hiddenDaySpacingFiller:["hiddenDaySpacingFiller"]},bW,l)},rT=({theme:t})=>ne({},t.typography.caption,{width:uc,height:uc,borderRadius:"50%",padding:0,backgroundColor:"transparent",transition:t.transitions.create("background-color",{duration:t.transitions.duration.short}),color:(t.vars||t).palette.text.primary,"@media (pointer: fine)":{"&:hover":{backgroundColor:t.vars?`rgba(${t.vars.palette.primary.mainChannel} / ${t.vars.palette.action.hoverOpacity})`:Rt(t.palette.primary.main,t.palette.action.hoverOpacity)}},"&:focus":{backgroundColor:t.vars?`rgba(${t.vars.palette.primary.mainChannel} / ${t.vars.palette.action.focusOpacity})`:Rt(t.palette.primary.main,t.palette.action.focusOpacity),[`&.${Cs.selected}`]:{willChange:"background-color",backgroundColor:(t.vars||t).palette.primary.dark}},[`&.${Cs.selected}`]:{color:(t.vars||t).palette.primary.contrastText,backgroundColor:(t.vars||t).palette.primary.main,fontWeight:t.typography.fontWeightMedium,"&:hover":{willChange:"background-color",backgroundColor:(t.vars||t).palette.primary.dark}},[`&.${Cs.disabled}:not(.${Cs.selected})`]:{color:(t.vars||t).palette.text.disabled},[`&.${Cs.disabled}&.${Cs.selected}`]:{opacity:.6},variants:[{props:{disableMargin:!1},style:{margin:`0 ${Dd}px`}},{props:{outsideCurrentMonth:!0,showDaysOutsideCurrentMonth:!0},style:{color:(t.vars||t).palette.text.secondary}},{props:{disableHighlightToday:!1,today:!0},style:{[`&:not(.${Cs.selected})`]:{border:`1px solid ${(t.vars||t).palette.text.secondary}`}}}]}),oT=(t,e)=>{const{ownerState:n}=t;return[e.root,!n.disableMargin&&e.dayWithMargin,!n.disableHighlightToday&&n.today&&e.today,!n.outsideCurrentMonth&&n.showDaysOutsideCurrentMonth&&e.dayOutsideMonth,n.outsideCurrentMonth&&!n.showDaysOutsideCurrentMonth&&e.hiddenDaySpacingFiller]},SW=be(xa,{name:"MuiPickersDay",slot:"Root",overridesResolver:oT})(rT),CW=be("div",{name:"MuiPickersDay",slot:"Root",overridesResolver:oT})(({theme:t})=>ne({},rT({theme:t}),{opacity:0,pointerEvents:"none"})),dc=()=>{},iT=I.forwardRef(function(e,n){const r=Wt({props:e,name:"MuiPickersDay"}),{autoFocus:o=!1,className:i,day:s,disabled:a=!1,disableHighlightToday:l=!1,disableMargin:u=!1,isAnimating:f,onClick:p,onDaySelect:g,onFocus:m=dc,onBlur:y=dc,onKeyDown:b=dc,onMouseDown:S=dc,onMouseEnter:C=dc,outsideCurrentMonth:T,selected:_=!1,showDaysOutsideCurrentMonth:w=!1,children:E,today:O=!1}=r,L=rt(r,vW),P=ne({},r,{autoFocus:o,disabled:a,disableHighlightToday:l,disableMargin:u,selected:_,showDaysOutsideCurrentMonth:w,today:O}),$=xW(P),M=qt(),A=I.useRef(null),N=Et(A,n);Tn(()=>{o&&!a&&!f&&!T&&A.current.focus()},[o,a,f,T]);const z=B=>{S(B),T&&B.preventDefault()},V=B=>{a||g(s),T&&B.currentTarget.focus(),p&&p(B)};return T&&!w?v.jsx(CW,{className:Le($.root,$.hiddenDaySpacingFiller,i),ownerState:P,role:L.role}):v.jsx(SW,ne({className:Le($.root,i),ref:N,centerRipple:!0,disabled:a,tabIndex:_?0:-1,onKeyDown:B=>b(B,s),onFocus:B=>m(B,s),onBlur:B=>y(B,s),onMouseEnter:B=>C(B,s),onClick:V,onMouseDown:z},L,{ownerState:P,children:E||M.format(s,"dayOfMonth")}))});process.env.NODE_ENV!=="production"&&(iT.propTypes={action:c.oneOfType([c.func,c.shape({current:c.shape({focusVisible:c.func.isRequired})})]),centerRipple:c.bool,classes:c.object,className:c.string,component:c.elementType,day:c.object.isRequired,disabled:c.bool,disableHighlightToday:c.bool,disableMargin:c.bool,disableRipple:c.bool,disableTouchRipple:c.bool,focusRipple:c.bool,focusVisibleClassName:c.string,isAnimating:c.bool,isFirstVisibleCell:c.bool.isRequired,isLastVisibleCell:c.bool.isRequired,onBlur:c.func,onDaySelect:c.func.isRequired,onFocus:c.func,onFocusVisible:c.func,onKeyDown:c.func,onMouseEnter:c.func,outsideCurrentMonth:c.bool.isRequired,selected:c.bool,showDaysOutsideCurrentMonth:c.bool,style:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),tabIndex:c.number,today:c.bool,TouchRippleProps:c.object,touchRippleRef:c.oneOfType([c.func,c.shape({current:c.shape({pulsate:c.func.isRequired,start:c.func.isRequired,stop:c.func.isRequired})})])});const wW=I.memo(iT),_W=t=>Ke("MuiPickersSlideTransition",t),Rr=qe("MuiPickersSlideTransition",["root","slideEnter-left","slideEnter-right","slideEnterActive","slideExit","slideExitActiveLeft-left","slideExitActiveLeft-right"]),TW=["children","className","reduceAnimations","slideDirection","transKey","classes"],kW=t=>{const{classes:e,slideDirection:n}=t,r={root:["root"],exit:["slideExit"],enterActive:["slideEnterActive"],enter:[`slideEnter-${n}`],exitActive:[`slideExitActiveLeft-${n}`]};return Ue(r,_W,e)},EW=be(jl,{name:"MuiPickersSlideTransition",slot:"Root",overridesResolver:(t,e)=>[e.root,{[`.${Rr["slideEnter-left"]}`]:e["slideEnter-left"]},{[`.${Rr["slideEnter-right"]}`]:e["slideEnter-right"]},{[`.${Rr.slideEnterActive}`]:e.slideEnterActive},{[`.${Rr.slideExit}`]:e.slideExit},{[`.${Rr["slideExitActiveLeft-left"]}`]:e["slideExitActiveLeft-left"]},{[`.${Rr["slideExitActiveLeft-right"]}`]:e["slideExitActiveLeft-right"]}]})(({theme:t})=>{const e=t.transitions.create("transform",{duration:t.transitions.duration.complex,easing:"cubic-bezier(0.35, 0.8, 0.4, 1)"});return{display:"block",position:"relative",overflowX:"hidden","& > *":{position:"absolute",top:0,right:0,left:0},[`& .${Rr["slideEnter-left"]}`]:{willChange:"transform",transform:"translate(100%)",zIndex:1},[`& .${Rr["slideEnter-right"]}`]:{willChange:"transform",transform:"translate(-100%)",zIndex:1},[`& .${Rr.slideEnterActive}`]:{transform:"translate(0%)",transition:e},[`& .${Rr.slideExit}`]:{transform:"translate(0%)"},[`& .${Rr["slideExitActiveLeft-left"]}`]:{willChange:"transform",transform:"translate(-100%)",transition:e,zIndex:0},[`& .${Rr["slideExitActiveLeft-right"]}`]:{willChange:"transform",transform:"translate(100%)",transition:e,zIndex:0}}});function MW(t){const e=Wt({props:t,name:"MuiPickersSlideTransition"}),{children:n,className:r,reduceAnimations:o,transKey:i}=e,s=rt(e,TW),a=kW(e),l=Si();if(o)return v.jsx("div",{className:Le(a.root,r),children:n});const u={exit:a.exit,enterActive:a.enterActive,enter:a.enter,exitActive:a.exitActive};return v.jsx(EW,{className:Le(a.root,r),childFactory:f=>I.cloneElement(f,{classNames:u}),role:"presentation",children:v.jsx(bg,ne({mountOnEnter:!0,unmountOnExit:!0,timeout:l.transitions.duration.complex,classNames:u},s,{children:n}),i)})}const OW=t=>Ke("MuiDayCalendar",t);qe("MuiDayCalendar",["root","header","weekDayLabel","loadingContainer","slideTransition","monthContainer","weekContainer","weekNumberLabel","weekNumber"]);const AW=["parentProps","day","focusableDay","selectedDays","isDateDisabled","currentMonthNumber","isViewFocused"],IW=["ownerState"],DW=t=>{const{classes:e}=t;return Ue({root:["root"],header:["header"],weekDayLabel:["weekDayLabel"],loadingContainer:["loadingContainer"],slideTransition:["slideTransition"],monthContainer:["monthContainer"],weekContainer:["weekContainer"],weekNumberLabel:["weekNumberLabel"],weekNumber:["weekNumber"]},OW,e)},sT=(uc+Dd*2)*6,PW=be("div",{name:"MuiDayCalendar",slot:"Root",overridesResolver:(t,e)=>e.root})({}),NW=be("div",{name:"MuiDayCalendar",slot:"Header",overridesResolver:(t,e)=>e.header})({display:"flex",justifyContent:"center",alignItems:"center"}),LW=be(Ti,{name:"MuiDayCalendar",slot:"WeekDayLabel",overridesResolver:(t,e)=>e.weekDayLabel})(({theme:t})=>({width:36,height:40,margin:"0 2px",textAlign:"center",display:"flex",justifyContent:"center",alignItems:"center",color:(t.vars||t).palette.text.secondary})),FW=be(Ti,{name:"MuiDayCalendar",slot:"WeekNumberLabel",overridesResolver:(t,e)=>e.weekNumberLabel})(({theme:t})=>({width:36,height:40,margin:"0 2px",textAlign:"center",display:"flex",justifyContent:"center",alignItems:"center",color:t.palette.text.disabled})),$W=be(Ti,{name:"MuiDayCalendar",slot:"WeekNumber",overridesResolver:(t,e)=>e.weekNumber})(({theme:t})=>ne({},t.typography.caption,{width:uc,height:uc,padding:0,margin:`0 ${Dd}px`,color:t.palette.text.disabled,fontSize:"0.75rem",alignItems:"center",justifyContent:"center",display:"inline-flex"})),BW=be("div",{name:"MuiDayCalendar",slot:"LoadingContainer",overridesResolver:(t,e)=>e.loadingContainer})({display:"flex",justifyContent:"center",alignItems:"center",minHeight:sT}),RW=be(MW,{name:"MuiDayCalendar",slot:"SlideTransition",overridesResolver:(t,e)=>e.slideTransition})({minHeight:sT}),zW=be("div",{name:"MuiDayCalendar",slot:"MonthContainer",overridesResolver:(t,e)=>e.monthContainer})({overflow:"hidden"}),VW=be("div",{name:"MuiDayCalendar",slot:"WeekContainer",overridesResolver:(t,e)=>e.weekContainer})({margin:`${Dd}px 0`,display:"flex",justifyContent:"center"});function HW(t){let{parentProps:e,day:n,focusableDay:r,selectedDays:o,isDateDisabled:i,currentMonthNumber:s,isViewFocused:a}=t,l=rt(t,AW);const{disabled:u,disableHighlightToday:f,isMonthSwitchingAnimating:p,showDaysOutsideCurrentMonth:g,slots:m,slotProps:y,timezone:b}=e,S=qt(),C=xd(b),T=r!==null&&S.isSameDay(n,r),_=o.some(N=>S.isSameDay(N,n)),w=S.isSameDay(n,C),E=(m==null?void 0:m.day)??wW,O=wt({elementType:E,externalSlotProps:y==null?void 0:y.day,additionalProps:ne({disableHighlightToday:f,showDaysOutsideCurrentMonth:g,role:"gridcell",isAnimating:p,"data-timestamp":S.toJsDate(n).valueOf()},l),ownerState:ne({},e,{day:n,selected:_})}),L=rt(O,IW),P=I.useMemo(()=>u||i(n),[u,i,n]),$=I.useMemo(()=>S.getMonth(n)!==s,[S,n,s]),M=I.useMemo(()=>{const N=S.startOfMonth(S.setMonth(n,s));return g?S.isSameDay(n,S.startOfWeek(N)):S.isSameDay(n,N)},[s,n,g,S]),A=I.useMemo(()=>{const N=S.endOfMonth(S.setMonth(n,s));return g?S.isSameDay(n,S.endOfWeek(N)):S.isSameDay(n,N)},[s,n,g,S]);return v.jsx(E,ne({},L,{day:n,disabled:P,autoFocus:a&&T,today:w,outsideCurrentMonth:$,isFirstVisibleCell:M,isLastVisibleCell:A,selected:_,tabIndex:T?0:-1,"aria-selected":_,"aria-current":w?"date":void 0}))}function jW(t){const e=Wt({props:t,name:"MuiDayCalendar"}),n=qt(),{onFocusedDayChange:r,className:o,currentMonth:i,selectedDays:s,focusedDay:a,loading:l,onSelectedDaysChange:u,onMonthSwitchingAnimationEnd:f,readOnly:p,reduceAnimations:g,renderLoading:m=()=>v.jsx("span",{children:"..."}),slideDirection:y,TransitionProps:b,disablePast:S,disableFuture:C,minDate:T,maxDate:_,shouldDisableDate:w,shouldDisableMonth:E,shouldDisableYear:O,dayOfWeekFormatter:L=_e=>n.format(_e,"weekdayShort").charAt(0).toUpperCase(),hasFocus:P,onFocusedViewChange:$,gridLabelId:M,displayWeekNumber:A,fixedWeekNumber:N,autoFocus:z,timezone:V}=e,B=xd(V),R=DW(e),q=no(),U=tT({shouldDisableDate:w,shouldDisableMonth:E,shouldDisableYear:O,minDate:T,maxDate:_,disablePast:S,disableFuture:C,timezone:V}),G=Ko(),[Y,Z]=jo({name:"DayCalendar",state:"hasFocus",controlled:P,default:z??!1}),[fe,pe]=I.useState(()=>a||B),me=Be(_e=>{p||u(_e)}),re=_e=>{U(_e)||(r(_e),pe(_e),$==null||$(!0),Z(!0))},he=Be((_e,Se)=>{switch(_e.key){case"ArrowUp":re(n.addDays(Se,-7)),_e.preventDefault();break;case"ArrowDown":re(n.addDays(Se,7)),_e.preventDefault();break;case"ArrowLeft":{const Me=n.addDays(Se,q?1:-1),Fe=n.addMonths(Se,q?1:-1),je=Jl({utils:n,date:Me,minDate:q?Me:n.startOfMonth(Fe),maxDate:q?n.endOfMonth(Fe):Me,isDateDisabled:U,timezone:V});re(je||Me),_e.preventDefault();break}case"ArrowRight":{const Me=n.addDays(Se,q?-1:1),Fe=n.addMonths(Se,q?-1:1),je=Jl({utils:n,date:Me,minDate:q?n.startOfMonth(Fe):Me,maxDate:q?Me:n.endOfMonth(Fe),isDateDisabled:U,timezone:V});re(je||Me),_e.preventDefault();break}case"Home":re(n.startOfWeek(Se)),_e.preventDefault();break;case"End":re(n.endOfWeek(Se)),_e.preventDefault();break;case"PageUp":re(n.addMonths(Se,1)),_e.preventDefault();break;case"PageDown":re(n.addMonths(Se,-1)),_e.preventDefault();break}}),le=Be((_e,Se)=>re(Se)),X=Be((_e,Se)=>{Y&&n.isSameDay(fe,Se)&&($==null||$(!1))}),W=n.getMonth(i),ee=n.getYear(i),ce=I.useMemo(()=>s.filter(_e=>!!_e).map(_e=>n.startOfDay(_e)),[n,s]),te=`${ee}-${W}`,se=I.useMemo(()=>I.createRef(),[te]),ue=I.useMemo(()=>{const _e=n.startOfMonth(i),Se=n.endOfMonth(i);return U(fe)||n.isAfterDay(fe,Se)||n.isBeforeDay(fe,_e)?Jl({utils:n,date:fe,minDate:_e,maxDate:Se,disablePast:S,disableFuture:C,isDateDisabled:U,timezone:V}):fe},[i,C,S,fe,U,n,V]),ye=I.useMemo(()=>{const _e=n.getWeekArray(i);let Se=n.addMonths(i,1);for(;N&&_e.length<N;){const Me=n.getWeekArray(Se),Fe=n.isSameDay(_e[_e.length-1][0],Me[0][0]);Me.slice(Fe?1:0).forEach(je=>{_e.length<N&&_e.push(je)}),Se=n.addMonths(Se,1)}return _e},[i,N,n]);return v.jsxs(PW,{role:"grid","aria-labelledby":M,className:R.root,children:[v.jsxs(NW,{role:"row",className:R.header,children:[A&&v.jsx(FW,{variant:"caption",role:"columnheader","aria-label":G.calendarWeekNumberHeaderLabel,className:R.weekNumberLabel,children:G.calendarWeekNumberHeaderText}),v4(n,B).map((_e,Se)=>v.jsx(LW,{variant:"caption",role:"columnheader","aria-label":n.format(_e,"weekday"),className:R.weekDayLabel,children:L(_e)},Se.toString()))]}),l?v.jsx(BW,{className:R.loadingContainer,children:m()}):v.jsx(RW,ne({transKey:te,onExited:f,reduceAnimations:g,slideDirection:y,className:Le(o,R.slideTransition)},b,{nodeRef:se,children:v.jsx(zW,{ref:se,role:"rowgroup",className:R.monthContainer,children:ye.map((_e,Se)=>v.jsxs(VW,{role:"row",className:R.weekContainer,"aria-rowindex":Se+1,children:[A&&v.jsx($W,{className:R.weekNumber,role:"rowheader","aria-label":G.calendarWeekNumberAriaLabelText(n.getWeekNumber(_e[0])),children:G.calendarWeekNumberText(n.getWeekNumber(_e[0]))}),_e.map((Me,Fe)=>v.jsx(HW,{parentProps:e,day:Me,selectedDays:ce,focusableDay:ue,onKeyDown:he,onFocus:le,onBlur:X,onDaySelect:me,isDateDisabled:U,currentMonthNumber:W,isViewFocused:Y,"aria-colindex":Fe+1},Me.toString()))]},`week-${_e[0]}`))})}))]})}function WW(t){return Ke("MuiPickersMonth",t)}const Nd=qe("MuiPickersMonth",["root","monthButton","disabled","selected"]),qW=["autoFocus","className","children","disabled","selected","value","tabIndex","onClick","onKeyDown","onFocus","onBlur","aria-current","aria-label","monthsPerRow","slots","slotProps"],UW=t=>{const{disabled:e,selected:n,classes:r}=t;return Ue({root:["root"],monthButton:["monthButton",e&&"disabled",n&&"selected"]},WW,r)},KW=be("div",{name:"MuiPickersMonth",slot:"Root",overridesResolver:(t,e)=>[e.root]})({display:"flex",alignItems:"center",justifyContent:"center",flexBasis:"33.3%",variants:[{props:{monthsPerRow:4},style:{flexBasis:"25%"}}]}),YW=be("button",{name:"MuiPickersMonth",slot:"MonthButton",overridesResolver:(t,e)=>[e.monthButton,{[`&.${Nd.disabled}`]:e.disabled},{[`&.${Nd.selected}`]:e.selected}]})(({theme:t})=>ne({color:"unset",backgroundColor:"transparent",border:0,outline:0},t.typography.subtitle1,{margin:"8px 0",height:36,width:72,borderRadius:18,cursor:"pointer","&:focus":{backgroundColor:t.vars?`rgba(${t.vars.palette.action.activeChannel} / ${t.vars.palette.action.hoverOpacity})`:Rt(t.palette.action.active,t.palette.action.hoverOpacity)},"&:hover":{backgroundColor:t.vars?`rgba(${t.vars.palette.action.activeChannel} / ${t.vars.palette.action.hoverOpacity})`:Rt(t.palette.action.active,t.palette.action.hoverOpacity)},"&:disabled":{cursor:"auto",pointerEvents:"none"},[`&.${Nd.disabled}`]:{color:(t.vars||t).palette.text.secondary},[`&.${Nd.selected}`]:{color:(t.vars||t).palette.primary.contrastText,backgroundColor:(t.vars||t).palette.primary.main,"&:focus, &:hover":{backgroundColor:(t.vars||t).palette.primary.dark}}})),GW=I.memo(function(e){const n=Wt({props:e,name:"MuiPickersMonth"}),{autoFocus:r,className:o,children:i,disabled:s,selected:a,value:l,tabIndex:u,onClick:f,onKeyDown:p,onFocus:g,onBlur:m,"aria-current":y,"aria-label":b,slots:S,slotProps:C}=n,T=rt(n,qW),_=I.useRef(null),w=UW(n);Tn(()=>{var L;r&&((L=_.current)==null||L.focus())},[r]);const E=(S==null?void 0:S.monthButton)??YW,O=wt({elementType:E,externalSlotProps:C==null?void 0:C.monthButton,additionalProps:{children:i,disabled:s,tabIndex:u,ref:_,type:"button",role:"radio","aria-current":y,"aria-checked":a,"aria-label":b,onClick:L=>f(L,l),onKeyDown:L=>p(L,l),onFocus:L=>g(L,l),onBlur:L=>m(L,l)},ownerState:n,className:w.monthButton});return v.jsx(KW,ne({className:Le(w.root,o),ownerState:n},T,{children:v.jsx(E,ne({},O))}))});function JW(t){return Ke("MuiMonthCalendar",t)}qe("MuiMonthCalendar",["root"]);const ZW=["className","value","defaultValue","referenceDate","disabled","disableFuture","disablePast","maxDate","minDate","onChange","shouldDisableMonth","readOnly","disableHighlightToday","autoFocus","onMonthFocus","hasFocus","onFocusedViewChange","monthsPerRow","timezone","gridLabelId","slots","slotProps"],XW=t=>{const{classes:e}=t;return Ue({root:["root"]},JW,e)};function QW(t,e){const n=qt(),r=Ql(),o=Wt({props:t,name:e});return ne({disableFuture:!1,disablePast:!1},o,{minDate:Nr(n,o.minDate,r.minDate),maxDate:Nr(n,o.maxDate,r.maxDate)})}const e9=be("div",{name:"MuiMonthCalendar",slot:"Root",overridesResolver:(t,e)=>e.root})({display:"flex",flexWrap:"wrap",alignContent:"stretch",padding:"0 4px",width:Pd,boxSizing:"border-box"}),aT=I.forwardRef(function(e,n){const r=QW(e,"MuiMonthCalendar"),{className:o,value:i,defaultValue:s,referenceDate:a,disabled:l,disableFuture:u,disablePast:f,maxDate:p,minDate:g,onChange:m,shouldDisableMonth:y,readOnly:b,autoFocus:S=!1,onMonthFocus:C,hasFocus:T,onFocusedViewChange:_,monthsPerRow:w=3,timezone:E,gridLabelId:O,slots:L,slotProps:P}=r,$=rt(r,ZW),{value:M,handleValueChange:A,timezone:N}=Lg({name:"MonthCalendar",timezone:E,value:i,defaultValue:s,referenceDate:a,onChange:m,valueManager:wo}),z=xd(N),V=no(),B=qt(),R=I.useMemo(()=>wo.getInitialReferenceValue({value:M,utils:B,props:r,timezone:N,referenceDate:a,granularity:Co.month}),[]),q=r,U=XW(q),G=I.useMemo(()=>B.getMonth(z),[B,z]),Y=I.useMemo(()=>M!=null?B.getMonth(M):null,[M,B]),[Z,fe]=I.useState(()=>Y||B.getMonth(R)),[pe,me]=jo({name:"MonthCalendar",state:"hasFocus",controlled:T,default:S??!1}),re=Be(te=>{me(te),_&&_(te)}),he=I.useCallback(te=>{const se=B.startOfMonth(f&&B.isAfter(z,g)?z:g),ue=B.startOfMonth(u&&B.isBefore(z,p)?z:p),ye=B.startOfMonth(te);return B.isBefore(ye,se)||B.isAfter(ye,ue)?!0:y?y(ye):!1},[u,f,p,g,z,y,B]),le=Be((te,se)=>{if(b)return;const ue=B.setMonth(M??R,se);A(ue)}),X=Be(te=>{he(B.setMonth(M??R,te))||(fe(te),re(!0),C&&C(te))});I.useEffect(()=>{fe(te=>Y!==null&&te!==Y?Y:te)},[Y]);const W=Be((te,se)=>{switch(te.key){case"ArrowUp":X((12+se-3)%12),te.preventDefault();break;case"ArrowDown":X((12+se+3)%12),te.preventDefault();break;case"ArrowLeft":X((12+se+(V?1:-1))%12),te.preventDefault();break;case"ArrowRight":X((12+se+(V?-1:1))%12),te.preventDefault();break}}),ee=Be((te,se)=>{X(se)}),ce=Be((te,se)=>{Z===se&&re(!1)});return v.jsx(e9,ne({ref:n,className:Le(U.root,o),ownerState:q,role:"radiogroup","aria-labelledby":O},$,{children:Mg(B,M??R).map(te=>{const se=B.getMonth(te),ue=B.format(te,"monthShort"),ye=B.format(te,"month"),_e=se===Y,Se=l||he(te);return v.jsx(GW,{selected:_e,value:se,onClick:le,onKeyDown:W,autoFocus:pe&&se===Z,disabled:Se,tabIndex:se===Z&&!Se?0:-1,onFocus:ee,onBlur:ce,"aria-current":G===se?"date":void 0,"aria-label":ye,monthsPerRow:w,slots:L,slotProps:P,children:ue},ue)})}))});process.env.NODE_ENV!=="production"&&(aT.propTypes={autoFocus:c.bool,classes:c.object,className:c.string,defaultValue:c.object,disabled:c.bool,disableFuture:c.bool,disableHighlightToday:c.bool,disablePast:c.bool,gridLabelId:c.string,hasFocus:c.bool,maxDate:c.object,minDate:c.object,monthsPerRow:c.oneOf([3,4]),onChange:c.func,onFocusedViewChange:c.func,onMonthFocus:c.func,readOnly:c.bool,referenceDate:c.object,shouldDisableMonth:c.func,slotProps:c.object,slots:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),timezone:c.string,value:c.object});function t9(t){return Ke("MuiPickersYear",t)}const Ld=qe("MuiPickersYear",["root","yearButton","selected","disabled"]),n9=["autoFocus","className","children","disabled","selected","value","tabIndex","onClick","onKeyDown","onFocus","onBlur","aria-current","yearsPerRow","slots","slotProps"],r9=t=>{const{disabled:e,selected:n,classes:r}=t;return Ue({root:["root"],yearButton:["yearButton",e&&"disabled",n&&"selected"]},t9,r)},o9=be("div",{name:"MuiPickersYear",slot:"Root",overridesResolver:(t,e)=>[e.root]})({display:"flex",alignItems:"center",justifyContent:"center",flexBasis:"33.3%",variants:[{props:{yearsPerRow:4},style:{flexBasis:"25%"}}]}),i9=be("button",{name:"MuiPickersYear",slot:"YearButton",overridesResolver:(t,e)=>[e.yearButton,{[`&.${Ld.disabled}`]:e.disabled},{[`&.${Ld.selected}`]:e.selected}]})(({theme:t})=>ne({color:"unset",backgroundColor:"transparent",border:0,outline:0},t.typography.subtitle1,{margin:"6px 0",height:36,width:72,borderRadius:18,cursor:"pointer","&:focus":{backgroundColor:t.vars?`rgba(${t.vars.palette.action.activeChannel} / ${t.vars.palette.action.focusOpacity})`:Rt(t.palette.action.active,t.palette.action.focusOpacity)},"&:hover":{backgroundColor:t.vars?`rgba(${t.vars.palette.action.activeChannel} / ${t.vars.palette.action.hoverOpacity})`:Rt(t.palette.action.active,t.palette.action.hoverOpacity)},"&:disabled":{cursor:"auto",pointerEvents:"none"},[`&.${Ld.disabled}`]:{color:(t.vars||t).palette.text.secondary},[`&.${Ld.selected}`]:{color:(t.vars||t).palette.primary.contrastText,backgroundColor:(t.vars||t).palette.primary.main,"&:focus, &:hover":{backgroundColor:(t.vars||t).palette.primary.dark}}})),s9=I.memo(function(e){const n=Wt({props:e,name:"MuiPickersYear"}),{autoFocus:r,className:o,children:i,disabled:s,selected:a,value:l,tabIndex:u,onClick:f,onKeyDown:p,onFocus:g,onBlur:m,"aria-current":y,slots:b,slotProps:S}=n,C=rt(n,n9),T=I.useRef(null),_=r9(n);Tn(()=>{var O;r&&((O=T.current)==null||O.focus())},[r]);const w=(b==null?void 0:b.yearButton)??i9,E=wt({elementType:w,externalSlotProps:S==null?void 0:S.yearButton,additionalProps:{children:i,disabled:s,tabIndex:u,ref:T,type:"button",role:"radio","aria-current":y,"aria-checked":a,onClick:O=>f(O,l),onKeyDown:O=>p(O,l),onFocus:O=>g(O,l),onBlur:O=>m(O,l)},ownerState:n,className:_.yearButton});return v.jsx(o9,ne({className:Le(_.root,o),ownerState:n},C,{children:v.jsx(w,ne({},E))}))});function a9(t){return Ke("MuiYearCalendar",t)}qe("MuiYearCalendar",["root"]);const l9=["autoFocus","className","value","defaultValue","referenceDate","disabled","disableFuture","disablePast","maxDate","minDate","onChange","readOnly","shouldDisableYear","disableHighlightToday","onYearFocus","hasFocus","onFocusedViewChange","yearsOrder","yearsPerRow","timezone","gridLabelId","slots","slotProps"],c9=t=>{const{classes:e}=t;return Ue({root:["root"]},a9,e)};function u9(t,e){const n=qt(),r=Ql(),o=Wt({props:t,name:e});return ne({disablePast:!1,disableFuture:!1},o,{yearsPerRow:o.yearsPerRow??3,minDate:Nr(n,o.minDate,r.minDate),maxDate:Nr(n,o.maxDate,r.maxDate)})}const d9=be("div",{name:"MuiYearCalendar",slot:"Root",overridesResolver:(t,e)=>e.root})({display:"flex",flexDirection:"row",flexWrap:"wrap",overflowY:"auto",height:"100%",padding:"0 4px",width:Pd,maxHeight:eW,boxSizing:"border-box",position:"relative"}),lT=I.forwardRef(function(e,n){const r=u9(e,"MuiYearCalendar"),{autoFocus:o,className:i,value:s,defaultValue:a,referenceDate:l,disabled:u,disableFuture:f,disablePast:p,maxDate:g,minDate:m,onChange:y,readOnly:b,shouldDisableYear:S,onYearFocus:C,hasFocus:T,onFocusedViewChange:_,yearsOrder:w="asc",yearsPerRow:E,timezone:O,gridLabelId:L,slots:P,slotProps:$}=r,M=rt(r,l9),{value:A,handleValueChange:N,timezone:z}=Lg({name:"YearCalendar",timezone:O,value:s,defaultValue:a,referenceDate:l,onChange:y,valueManager:wo}),V=xd(z),B=no(),R=qt(),q=I.useMemo(()=>wo.getInitialReferenceValue({value:A,utils:R,props:r,timezone:z,referenceDate:l,granularity:Co.year}),[]),U=r,G=c9(U),Y=I.useMemo(()=>R.getYear(V),[R,V]),Z=I.useMemo(()=>A!=null?R.getYear(A):null,[A,R]),[fe,pe]=I.useState(()=>Z||R.getYear(q)),[me,re]=jo({name:"YearCalendar",state:"hasFocus",controlled:T,default:o??!1}),he=Be(Me=>{re(Me),_&&_(Me)}),le=I.useCallback(Me=>{if(p&&R.isBeforeYear(Me,V)||f&&R.isAfterYear(Me,V)||m&&R.isBeforeYear(Me,m)||g&&R.isAfterYear(Me,g))return!0;if(!S)return!1;const Fe=R.startOfYear(Me);return S(Fe)},[f,p,g,m,V,S,R]),X=Be((Me,Fe)=>{if(b)return;const je=R.setYear(A??q,Fe);N(je)}),W=Be(Me=>{le(R.setYear(A??q,Me))||(pe(Me),he(!0),C==null||C(Me))});I.useEffect(()=>{pe(Me=>Z!==null&&Me!==Z?Z:Me)},[Z]);const ee=w!=="desc"?E*1:E*-1,ce=B&&w==="asc"||!B&&w==="desc"?-1:1,te=Be((Me,Fe)=>{switch(Me.key){case"ArrowUp":W(Fe-ee),Me.preventDefault();break;case"ArrowDown":W(Fe+ee),Me.preventDefault();break;case"ArrowLeft":W(Fe-ce),Me.preventDefault();break;case"ArrowRight":W(Fe+ce),Me.preventDefault();break}}),se=Be((Me,Fe)=>{W(Fe)}),ue=Be((Me,Fe)=>{fe===Fe&&he(!1)}),ye=I.useRef(null),_e=Et(n,ye);I.useEffect(()=>{if(o||ye.current===null)return;const Me=ye.current.querySelector('[tabindex="0"]');if(!Me)return;const Fe=Me.offsetHeight,je=Me.offsetTop,Je=ye.current.clientHeight,De=ye.current.scrollTop,ct=je+Fe;Fe>Je||je<De||(ye.current.scrollTop=ct-Je/2-Fe/2)},[o]);const Se=R.getYearRange([m,g]);return w==="desc"&&Se.reverse(),v.jsx(d9,ne({ref:_e,className:Le(G.root,i),ownerState:U,role:"radiogroup","aria-labelledby":L},M,{children:Se.map(Me=>{const Fe=R.getYear(Me),je=Fe===Z,Je=u||le(Me);return v.jsx(s9,{selected:je,value:Fe,onClick:X,onKeyDown:te,autoFocus:me&&Fe===fe,disabled:Je,tabIndex:Fe===fe&&!Je?0:-1,onFocus:se,onBlur:ue,"aria-current":Y===Fe?"date":void 0,yearsPerRow:E,slots:P,slotProps:$,children:R.format(Me,"year")},R.format(Me,"year"))})}))});process.env.NODE_ENV!=="production"&&(lT.propTypes={autoFocus:c.bool,classes:c.object,className:c.string,defaultValue:c.object,disabled:c.bool,disableFuture:c.bool,disableHighlightToday:c.bool,disablePast:c.bool,gridLabelId:c.string,hasFocus:c.bool,maxDate:c.object,minDate:c.object,onChange:c.func,onFocusedViewChange:c.func,onYearFocus:c.func,readOnly:c.bool,referenceDate:c.object,shouldDisableYear:c.func,slotProps:c.object,slots:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),timezone:c.string,value:c.object,yearsOrder:c.oneOf(["asc","desc"]),yearsPerRow:c.oneOf([3,4])});const f9=t=>Ke("MuiPickersCalendarHeader",t),p9=qe("MuiPickersCalendarHeader",["root","labelContainer","label","switchViewButton","switchViewIcon"]);function h9(t){return Ke("MuiPickersArrowSwitcher",t)}qe("MuiPickersArrowSwitcher",["root","spacer","button","previousIconButton","nextIconButton","leftArrowIcon","rightArrowIcon"]);const g9=["children","className","slots","slotProps","isNextDisabled","isNextHidden","onGoToNext","nextLabel","isPreviousDisabled","isPreviousHidden","onGoToPrevious","previousLabel","labelId"],m9=["ownerState"],y9=["ownerState"],b9=be("div",{name:"MuiPickersArrowSwitcher",slot:"Root",overridesResolver:(t,e)=>e.root})({display:"flex"}),v9=be("div",{name:"MuiPickersArrowSwitcher",slot:"Spacer",overridesResolver:(t,e)=>e.spacer})(({theme:t})=>({width:t.spacing(3)})),cT=be(Sa,{name:"MuiPickersArrowSwitcher",slot:"Button",overridesResolver:(t,e)=>e.button})({variants:[{props:{hidden:!0},style:{visibility:"hidden"}}]}),x9=t=>{const{classes:e}=t;return Ue({root:["root"],spacer:["spacer"],button:["button"],previousIconButton:["previousIconButton"],nextIconButton:["nextIconButton"],leftArrowIcon:["leftArrowIcon"],rightArrowIcon:["rightArrowIcon"]},h9,e)},S9=I.forwardRef(function(e,n){const r=no(),o=Wt({props:e,name:"MuiPickersArrowSwitcher"}),{children:i,className:s,slots:a,slotProps:l,isNextDisabled:u,isNextHidden:f,onGoToNext:p,nextLabel:g,isPreviousDisabled:m,isPreviousHidden:y,onGoToPrevious:b,previousLabel:S,labelId:C}=o,T=rt(o,g9),_=o,w=x9(_),E={isDisabled:u,isHidden:f,goTo:p,label:g},O={isDisabled:m,isHidden:y,goTo:b,label:S},L=(a==null?void 0:a.previousIconButton)??cT,P=wt({elementType:L,externalSlotProps:l==null?void 0:l.previousIconButton,additionalProps:{size:"medium",title:O.label,"aria-label":O.label,disabled:O.isDisabled,edge:"end",onClick:O.goTo},ownerState:ne({},_,{hidden:O.isHidden}),className:Le(w.button,w.previousIconButton)}),$=(a==null?void 0:a.nextIconButton)??cT,M=wt({elementType:$,externalSlotProps:l==null?void 0:l.nextIconButton,additionalProps:{size:"medium",title:E.label,"aria-label":E.label,disabled:E.isDisabled,edge:"start",onClick:E.goTo},ownerState:ne({},_,{hidden:E.isHidden}),className:Le(w.button,w.nextIconButton)}),A=(a==null?void 0:a.leftArrowIcon)??zV,N=wt({elementType:A,externalSlotProps:l==null?void 0:l.leftArrowIcon,additionalProps:{fontSize:"inherit"},ownerState:_,className:w.leftArrowIcon}),z=rt(N,m9),V=(a==null?void 0:a.rightArrowIcon)??VV,B=wt({elementType:V,externalSlotProps:l==null?void 0:l.rightArrowIcon,additionalProps:{fontSize:"inherit"},ownerState:_,className:w.rightArrowIcon}),R=rt(B,y9);return v.jsxs(b9,ne({ref:n,className:Le(w.root,s),ownerState:_},T,{children:[v.jsx(L,ne({},P,{children:r?v.jsx(V,ne({},R)):v.jsx(A,ne({},z))})),i?v.jsx(Ti,{variant:"subtitle1",component:"span",id:C,children:i}):v.jsx(v9,{className:w.spacer,ownerState:_}),v.jsx($,ne({},M,{children:r?v.jsx(A,ne({},z)):v.jsx(V,ne({},R))}))]}))});function C9(t,{disableFuture:e,maxDate:n,timezone:r}){const o=qt();return I.useMemo(()=>{const i=o.date(void 0,r),s=o.startOfMonth(e&&o.isBefore(i,n)?i:n);return!o.isAfter(s,t)},[e,n,t,o,r])}function w9(t,{disablePast:e,minDate:n,timezone:r}){const o=qt();return I.useMemo(()=>{const i=o.date(void 0,r),s=o.startOfMonth(e&&o.isAfter(i,n)?i:n);return!o.isBefore(s,t)},[e,n,t,o,r])}const _9=["slots","slotProps","currentMonth","disabled","disableFuture","disablePast","maxDate","minDate","onMonthChange","onViewChange","view","reduceAnimations","views","labelId","className","timezone","format"],T9=["ownerState"],k9=t=>{const{classes:e}=t;return Ue({root:["root"],labelContainer:["labelContainer"],label:["label"],switchViewButton:["switchViewButton"],switchViewIcon:["switchViewIcon"]},f9,e)},E9=be("div",{name:"MuiPickersCalendarHeader",slot:"Root",overridesResolver:(t,e)=>e.root})({display:"flex",alignItems:"center",marginTop:12,marginBottom:4,paddingLeft:24,paddingRight:12,maxHeight:40,minHeight:40}),M9=be("div",{name:"MuiPickersCalendarHeader",slot:"LabelContainer",overridesResolver:(t,e)=>e.labelContainer})(({theme:t})=>ne({display:"flex",overflow:"hidden",alignItems:"center",cursor:"pointer",marginRight:"auto"},t.typography.body1,{fontWeight:t.typography.fontWeightMedium})),O9=be("div",{name:"MuiPickersCalendarHeader",slot:"Label",overridesResolver:(t,e)=>e.label})({marginRight:6}),A9=be(Sa,{name:"MuiPickersCalendarHeader",slot:"SwitchViewButton",overridesResolver:(t,e)=>e.switchViewButton})({marginRight:"auto",variants:[{props:{view:"year"},style:{[`.${p9.switchViewIcon}`]:{transform:"rotate(180deg)"}}}]}),I9=be(RV,{name:"MuiPickersCalendarHeader",slot:"SwitchViewIcon",overridesResolver:(t,e)=>e.switchViewIcon})(({theme:t})=>({willChange:"transform",transition:t.transitions.create("transform"),transform:"rotate(0deg)"})),uT=I.forwardRef(function(e,n){const r=Ko(),o=qt(),i=Wt({props:e,name:"MuiPickersCalendarHeader"}),{slots:s,slotProps:a,currentMonth:l,disabled:u,disableFuture:f,disablePast:p,maxDate:g,minDate:m,onMonthChange:y,onViewChange:b,view:S,reduceAnimations:C,views:T,labelId:_,className:w,timezone:E,format:O=`${o.formats.month} ${o.formats.year}`}=i,L=rt(i,_9),P=i,$=k9(i),M=(s==null?void 0:s.switchViewButton)??A9,A=wt({elementType:M,externalSlotProps:a==null?void 0:a.switchViewButton,additionalProps:{size:"small","aria-label":r.calendarViewSwitchingButtonAriaLabel(S)},ownerState:P,className:$.switchViewButton}),N=(s==null?void 0:s.switchViewIcon)??I9,z=wt({elementType:N,externalSlotProps:a==null?void 0:a.switchViewIcon,ownerState:P,className:$.switchViewIcon}),V=rt(z,T9),B=()=>y(o.addMonths(l,1),"left"),R=()=>y(o.addMonths(l,-1),"right"),q=C9(l,{disableFuture:f,maxDate:g,timezone:E}),U=w9(l,{disablePast:p,minDate:m,timezone:E}),G=()=>{if(!(T.length===1||!b||u))if(T.length===2)b(T.find(Z=>Z!==S)||T[0]);else{const Z=T.indexOf(S)!==0?0:1;b(T[Z])}};if(T.length===1&&T[0]==="year")return null;const Y=o.formatByString(l,O);return v.jsxs(E9,ne({},L,{ownerState:P,className:Le($.root,w),ref:n,children:[v.jsxs(M9,{role:"presentation",onClick:G,ownerState:P,"aria-live":"polite",className:$.labelContainer,children:[v.jsx(nT,{reduceAnimations:C,transKey:Y,children:v.jsx(O9,{id:_,ownerState:P,className:$.label,children:Y})}),T.length>1&&!u&&v.jsx(M,ne({},A,{children:v.jsx(N,ne({},V))}))]}),v.jsx(wi,{in:S==="day",children:v.jsx(S9,{slots:s,slotProps:a,onGoToPrevious:R,isPreviousDisabled:U,previousLabel:r.previousMonth,onGoToNext:B,isNextDisabled:q,nextLabel:r.nextMonth})})]}))});process.env.NODE_ENV!=="production"&&(uT.propTypes={classes:c.object,className:c.string,currentMonth:c.object.isRequired,disabled:c.bool,disableFuture:c.bool,disablePast:c.bool,format:c.string,labelId:c.string,maxDate:c.object.isRequired,minDate:c.object.isRequired,onMonthChange:c.func.isRequired,onViewChange:c.func,reduceAnimations:c.bool.isRequired,slotProps:c.object,slots:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),timezone:c.string.isRequired,view:c.oneOf(["day","month","year"]).isRequired,views:c.arrayOf(c.oneOf(["day","month","year"]).isRequired).isRequired});const D9=be("div")({overflow:"hidden",width:Pd,maxHeight:nm,display:"flex",flexDirection:"column",margin:"0 auto"}),P9=t=>Ke("MuiDateCalendar",t);qe("MuiDateCalendar",["root","viewTransitionContainer"]);const N9=["autoFocus","onViewChange","value","defaultValue","referenceDate","disableFuture","disablePast","onChange","onYearChange","onMonthChange","reduceAnimations","shouldDisableDate","shouldDisableMonth","shouldDisableYear","view","views","openTo","className","disabled","readOnly","minDate","maxDate","disableHighlightToday","focusedView","onFocusedViewChange","showDaysOutsideCurrentMonth","fixedWeekNumber","dayOfWeekFormatter","slots","slotProps","loading","renderLoading","displayWeekNumber","yearsOrder","yearsPerRow","monthsPerRow","timezone"],L9=t=>{const{classes:e}=t;return Ue({root:["root"],viewTransitionContainer:["viewTransitionContainer"]},P9,e)};function F9(t,e){const n=qt(),r=Ql(),o=z_(),i=Wt({props:t,name:e});return ne({},i,{loading:i.loading??!1,disablePast:i.disablePast??!1,disableFuture:i.disableFuture??!1,openTo:i.openTo??"day",views:i.views??["year","day"],reduceAnimations:i.reduceAnimations??o,renderLoading:i.renderLoading??(()=>v.jsx("span",{children:"..."})),minDate:Nr(n,i.minDate,r.minDate),maxDate:Nr(n,i.maxDate,r.maxDate)})}const $9=be(D9,{name:"MuiDateCalendar",slot:"Root",overridesResolver:(t,e)=>e.root})({display:"flex",flexDirection:"column",height:nm}),B9=be(nT,{name:"MuiDateCalendar",slot:"ViewTransitionContainer",overridesResolver:(t,e)=>e.viewTransitionContainer})({}),dT=I.forwardRef(function(e,n){const r=qt(),o=vo(),i=F9(e,"MuiDateCalendar"),{autoFocus:s,onViewChange:a,value:l,defaultValue:u,referenceDate:f,disableFuture:p,disablePast:g,onChange:m,onYearChange:y,onMonthChange:b,reduceAnimations:S,shouldDisableDate:C,shouldDisableMonth:T,shouldDisableYear:_,view:w,views:E,openTo:O,className:L,disabled:P,readOnly:$,minDate:M,maxDate:A,disableHighlightToday:N,focusedView:z,onFocusedViewChange:V,showDaysOutsideCurrentMonth:B,fixedWeekNumber:R,dayOfWeekFormatter:q,slots:U,slotProps:G,loading:Y,renderLoading:Z,displayWeekNumber:fe,yearsOrder:pe,yearsPerRow:me,monthsPerRow:re,timezone:he}=i,le=rt(i,N9),{value:X,handleValueChange:W,timezone:ee}=Lg({name:"DateCalendar",timezone:he,value:l,defaultValue:u,referenceDate:f,onChange:m,valueManager:wo}),{view:ce,setView:te,focusedView:se,setFocusedView:ue,goToNextView:ye,setValueAndGoToNextView:_e}=V_({view:w,views:E,openTo:O,onChange:W,onViewChange:a,autoFocus:s,focusedView:z,onFocusedViewChange:V}),{referenceDate:Se,calendarState:Me,changeFocusedDay:Fe,changeMonth:je,handleChangeMonth:Je,isDateDisabled:De,onMonthSwitchingAnimationEnd:ct}=hW({value:X,referenceDate:f,reduceAnimations:S,onMonthChange:b,minDate:M,maxDate:A,shouldDisableDate:C,disablePast:g,disableFuture:p,timezone:ee}),Ct=P&&X||M,Xt=P&&X||A,Sn=`${o}-grid-label`,un=se!==null,$t=(U==null?void 0:U.calendarHeader)??uT,In=wt({elementType:$t,externalSlotProps:G==null?void 0:G.calendarHeader,additionalProps:{views:E,view:ce,currentMonth:Me.currentMonth,onViewChange:te,onMonthChange:(nt,Pt)=>Je({newMonth:nt,direction:Pt}),minDate:Ct,maxDate:Xt,disabled:P,disablePast:g,disableFuture:p,reduceAnimations:S,timezone:ee,labelId:Sn},ownerState:i}),Kn=Be(nt=>{const Pt=r.startOfMonth(nt),rr=r.endOfMonth(nt),hr=De(nt)?Jl({utils:r,date:nt,minDate:r.isBefore(M,Pt)?Pt:M,maxDate:r.isAfter(A,rr)?rr:A,disablePast:g,disableFuture:p,isDateDisabled:De,timezone:ee}):nt;hr?(_e(hr,"finish"),b==null||b(Pt)):(ye(),je(Pt)),Fe(hr,!0)}),ft=Be(nt=>{const Pt=r.startOfYear(nt),rr=r.endOfYear(nt),hr=De(nt)?Jl({utils:r,date:nt,minDate:r.isBefore(M,Pt)?Pt:M,maxDate:r.isAfter(A,rr)?rr:A,disablePast:g,disableFuture:p,isDateDisabled:De,timezone:ee}):nt;hr?(_e(hr,"finish"),y==null||y(hr)):(ye(),je(Pt)),Fe(hr,!0)}),$n=Be(nt=>W(nt&&bd(r,nt,X??Se),"finish",ce));I.useEffect(()=>{X!=null&&r.isValid(X)&&je(X)},[X]);const Yt=i,ge=L9(Yt),$e={disablePast:g,disableFuture:p,maxDate:A,minDate:M},ke={disableHighlightToday:N,readOnly:$,disabled:P,timezone:ee,gridLabelId:Sn,slots:U,slotProps:G},Re=I.useRef(ce);I.useEffect(()=>{Re.current!==ce&&(se===Re.current&&ue(ce,!0),Re.current=ce)},[se,ue,ce]);const Ge=I.useMemo(()=>[X],[X]);return v.jsxs($9,ne({ref:n,className:Le(ge.root,L),ownerState:Yt},le,{children:[v.jsx($t,ne({},In,{slots:U,slotProps:G})),v.jsx(B9,{reduceAnimations:S,className:ge.viewTransitionContainer,transKey:ce,ownerState:Yt,children:v.jsxs("div",{children:[ce==="year"&&v.jsx(lT,ne({},$e,ke,{value:X,onChange:ft,shouldDisableYear:_,hasFocus:un,onFocusedViewChange:nt=>ue("year",nt),yearsOrder:pe,yearsPerRow:me,referenceDate:Se})),ce==="month"&&v.jsx(aT,ne({},$e,ke,{hasFocus:un,className:L,value:X,onChange:Kn,shouldDisableMonth:T,onFocusedViewChange:nt=>ue("month",nt),monthsPerRow:re,referenceDate:Se})),ce==="day"&&v.jsx(jW,ne({},Me,$e,ke,{onMonthSwitchingAnimationEnd:ct,onFocusedDayChange:Fe,reduceAnimations:S,selectedDays:Ge,onSelectedDaysChange:$n,shouldDisableDate:C,shouldDisableMonth:T,shouldDisableYear:_,hasFocus:un,onFocusedViewChange:nt=>ue("day",nt),showDaysOutsideCurrentMonth:B,fixedWeekNumber:R,dayOfWeekFormatter:q,displayWeekNumber:fe,loading:Y,renderLoading:Z}))]})})]}))});process.env.NODE_ENV!=="production"&&(dT.propTypes={autoFocus:c.bool,classes:c.object,className:c.string,dayOfWeekFormatter:c.func,defaultValue:c.object,disabled:c.bool,disableFuture:c.bool,disableHighlightToday:c.bool,disablePast:c.bool,displayWeekNumber:c.bool,fixedWeekNumber:c.number,focusedView:c.oneOf(["day","month","year"]),loading:c.bool,maxDate:c.object,minDate:c.object,monthsPerRow:c.oneOf([3,4]),onChange:c.func,onFocusedViewChange:c.func,onMonthChange:c.func,onViewChange:c.func,onYearChange:c.func,openTo:c.oneOf(["day","month","year"]),readOnly:c.bool,reduceAnimations:c.bool,referenceDate:c.object,renderLoading:c.func,shouldDisableDate:c.func,shouldDisableMonth:c.func,shouldDisableYear:c.func,showDaysOutsideCurrentMonth:c.bool,slotProps:c.object,slots:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),timezone:c.string,value:c.object,view:c.oneOf(["day","month","year"]),views:c.arrayOf(c.oneOf(["day","month","year"]).isRequired),yearsOrder:c.oneOf(["asc","desc"]),yearsPerRow:c.oneOf([3,4])});const Ma=({view:t,onViewChange:e,views:n,focusedView:r,onFocusedViewChange:o,value:i,defaultValue:s,referenceDate:a,onChange:l,className:u,classes:f,disableFuture:p,disablePast:g,minDate:m,maxDate:y,shouldDisableDate:b,shouldDisableMonth:S,shouldDisableYear:C,reduceAnimations:T,onMonthChange:_,monthsPerRow:w,onYearChange:E,yearsOrder:O,yearsPerRow:L,slots:P,slotProps:$,loading:M,renderLoading:A,disableHighlightToday:N,readOnly:z,disabled:V,showDaysOutsideCurrentMonth:B,dayOfWeekFormatter:R,sx:q,autoFocus:U,fixedWeekNumber:G,displayWeekNumber:Y,timezone:Z})=>v.jsx(dT,{view:t,onViewChange:e,views:n.filter(Iw),focusedView:r&&Iw(r)?r:null,onFocusedViewChange:o,value:i,defaultValue:s,referenceDate:a,onChange:l,className:u,classes:f,disableFuture:p,disablePast:g,minDate:m,maxDate:y,shouldDisableDate:b,shouldDisableMonth:S,shouldDisableYear:C,reduceAnimations:T,onMonthChange:_,monthsPerRow:w,onYearChange:E,yearsOrder:O,yearsPerRow:L,slots:P,slotProps:$,loading:M,renderLoading:A,disableHighlightToday:N,readOnly:z,disabled:V,showDaysOutsideCurrentMonth:B,dayOfWeekFormatter:R,sx:q,autoFocus:U,fixedWeekNumber:G,displayWeekNumber:Y,timezone:Z}),fT=I.forwardRef(function(e,n){var u,f;const r=Ko(),o=qt(),i=g_(e,"MuiDesktopDatePicker"),s=ne({day:Ma,month:Ma,year:Ma},i.viewRenderers),a=ne({},i,{viewRenderers:s,format:Og(o,i,!1),yearsPerRow:i.yearsPerRow??4,slots:ne({openPickerIcon:HV,field:_d},i.slots),slotProps:ne({},i.slotProps,{field:p=>{var g;return ne({},Mu((g=i.slotProps)==null?void 0:g.field,p),Uw(i),{ref:n})},toolbar:ne({hidden:!0},(u=i.slotProps)==null?void 0:u.toolbar)})}),{renderPicker:l}=fW({props:a,valueManager:wo,valueType:"date",getOpenDialogAriaText:Kw({utils:o,formatKey:"fullDate",contextTranslation:r.openDatePickerDialogue,propsTranslation:(f=a.localeText)==null?void 0:f.openDatePickerDialogue}),validator:Xl});return l()});fT.propTypes={autoFocus:c.bool,className:c.string,closeOnSelect:c.bool,dayOfWeekFormatter:c.func,defaultValue:c.object,disabled:c.bool,disableFuture:c.bool,disableHighlightToday:c.bool,disableOpenPicker:c.bool,disablePast:c.bool,displayWeekNumber:c.bool,enableAccessibleFieldDOMStructure:c.any,fixedWeekNumber:c.number,format:c.string,formatDensity:c.oneOf(["dense","spacious"]),inputRef:mn,label:c.node,loading:c.bool,localeText:c.object,maxDate:c.object,minDate:c.object,monthsPerRow:c.oneOf([3,4]),name:c.string,onAccept:c.func,onChange:c.func,onClose:c.func,onError:c.func,onMonthChange:c.func,onOpen:c.func,onSelectedSectionsChange:c.func,onViewChange:c.func,onYearChange:c.func,open:c.bool,openTo:c.oneOf(["day","month","year"]),orientation:c.oneOf(["landscape","portrait"]),readOnly:c.bool,reduceAnimations:c.bool,referenceDate:c.object,renderLoading:c.func,selectedSections:c.oneOfType([c.oneOf(["all","day","empty","hours","meridiem","minutes","month","seconds","weekDay","year"]),c.number]),shouldDisableDate:c.func,shouldDisableMonth:c.func,shouldDisableYear:c.func,showDaysOutsideCurrentMonth:c.bool,slotProps:c.object,slots:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),timezone:c.string,value:c.object,view:c.oneOf(["day","month","year"]),viewRenderers:c.shape({day:c.func,month:c.func,year:c.func}),views:c.arrayOf(c.oneOf(["day","month","year"]).isRequired),yearsOrder:c.oneOf(["asc","desc"]),yearsPerRow:c.oneOf([3,4])};function R9(t){return Ke("MuiDialogContent",t)}qe("MuiDialogContent",["root","dividers"]);const z9=qe("MuiDialogTitle",["root"]),V9=t=>{const{classes:e,dividers:n}=t;return Ue({root:["root",n&&"dividers"]},R9,e)},H9=be("div",{name:"MuiDialogContent",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,n.dividers&&e.dividers]}})(Dt(({theme:t})=>({flex:"1 1 auto",WebkitOverflowScrolling:"touch",overflowY:"auto",padding:"20px 24px",variants:[{props:({ownerState:e})=>e.dividers,style:{padding:"16px 24px",borderTop:`1px solid ${(t.vars||t).palette.divider}`,borderBottom:`1px solid ${(t.vars||t).palette.divider}`}},{props:({ownerState:e})=>!e.dividers,style:{[`.${z9.root} + &`]:{paddingTop:0}}}]}))),pT=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiDialogContent"}),{className:o,dividers:i=!1,...s}=r,a={...r,dividers:i},l=V9(a);return v.jsx(H9,{className:Le(l.root,o),ownerState:a,ref:n,...s})});process.env.NODE_ENV!=="production"&&(pT.propTypes={children:c.node,classes:c.object,className:c.string,dividers:c.bool,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object])});function j9(t){return Ke("MuiDialog",t)}const fc=qe("MuiDialog",["root","scrollPaper","scrollBody","container","paper","paperScrollPaper","paperScrollBody","paperWidthFalse","paperWidthXs","paperWidthSm","paperWidthMd","paperWidthLg","paperWidthXl","paperFullWidth","paperFullScreen"]),hT=I.createContext({});process.env.NODE_ENV!=="production"&&(hT.displayName="DialogContext");const W9=be(wg,{name:"MuiDialog",slot:"Backdrop",overrides:(t,e)=>e.backdrop})({zIndex:-1}),q9=t=>{const{classes:e,scroll:n,maxWidth:r,fullWidth:o,fullScreen:i}=t,s={root:["root"],container:["container",`scroll${Ae(n)}`],paper:["paper",`paperScroll${Ae(n)}`,`paperWidth${Ae(String(r))}`,o&&"paperFullWidth",i&&"paperFullScreen"]};return Ue(s,j9,e)},U9=be(_g,{name:"MuiDialog",slot:"Root",overridesResolver:(t,e)=>e.root})({"@media print":{position:"absolute !important"}}),K9=be("div",{name:"MuiDialog",slot:"Container",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.container,e[`scroll${Ae(n.scroll)}`]]}})({height:"100%","@media print":{height:"auto"},outline:0,variants:[{props:{scroll:"paper"},style:{display:"flex",justifyContent:"center",alignItems:"center"}},{props:{scroll:"body"},style:{overflowY:"auto",overflowX:"hidden",textAlign:"center","&::after":{content:'""',display:"inline-block",verticalAlign:"middle",height:"100%",width:"0"}}}]}),Y9=be(ya,{name:"MuiDialog",slot:"Paper",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.paper,e[`scrollPaper${Ae(n.scroll)}`],e[`paperWidth${Ae(String(n.maxWidth))}`],n.fullWidth&&e.paperFullWidth,n.fullScreen&&e.paperFullScreen]}})(Dt(({theme:t})=>({margin:32,position:"relative",overflowY:"auto","@media print":{overflowY:"visible",boxShadow:"none"},variants:[{props:{scroll:"paper"},style:{display:"flex",flexDirection:"column",maxHeight:"calc(100% - 64px)"}},{props:{scroll:"body"},style:{display:"inline-block",verticalAlign:"middle",textAlign:"initial"}},{props:({ownerState:e})=>!e.maxWidth,style:{maxWidth:"calc(100% - 64px)"}},{props:{maxWidth:"xs"},style:{maxWidth:t.breakpoints.unit==="px"?Math.max(t.breakpoints.values.xs,444):`max(${t.breakpoints.values.xs}${t.breakpoints.unit}, 444px)`,[`&.${fc.paperScrollBody}`]:{[t.breakpoints.down(Math.max(t.breakpoints.values.xs,444)+32*2)]:{maxWidth:"calc(100% - 64px)"}}}},...Object.keys(t.breakpoints.values).filter(e=>e!=="xs").map(e=>({props:{maxWidth:e},style:{maxWidth:`${t.breakpoints.values[e]}${t.breakpoints.unit}`,[`&.${fc.paperScrollBody}`]:{[t.breakpoints.down(t.breakpoints.values[e]+32*2)]:{maxWidth:"calc(100% - 64px)"}}}})),{props:({ownerState:e})=>e.fullWidth,style:{width:"calc(100% - 64px)"}},{props:({ownerState:e})=>e.fullScreen,style:{margin:0,width:"100%",maxWidth:"100%",height:"100%",maxHeight:"none",borderRadius:0,[`&.${fc.paperScrollBody}`]:{margin:0,maxWidth:"100%"}}}]}))),gT=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiDialog"}),o=Si(),i={enter:o.transitions.duration.enteringScreen,exit:o.transitions.duration.leavingScreen},{"aria-describedby":s,"aria-labelledby":a,"aria-modal":l=!0,BackdropComponent:u,BackdropProps:f,children:p,className:g,disableEscapeKeyDown:m=!1,fullScreen:y=!1,fullWidth:b=!1,maxWidth:S="sm",onBackdropClick:C,onClick:T,onClose:_,open:w,PaperComponent:E=ya,PaperProps:O={},scroll:L="paper",slots:P={},slotProps:$={},TransitionComponent:M=wi,transitionDuration:A=i,TransitionProps:N,...z}=r,V={...r,disableEscapeKeyDown:m,fullScreen:y,fullWidth:b,maxWidth:S,scroll:L},B=q9(V),R=I.useRef(),q=ue=>{R.current=ue.target===ue.currentTarget},U=ue=>{T&&T(ue),R.current&&(R.current=null,C&&C(ue),_&&_(ue,"backdropClick"))},G=vo(a),Y=I.useMemo(()=>({titleId:G}),[G]),Z={transition:M,...P},fe={transition:N,paper:O,backdrop:f,...$},pe={slots:Z,slotProps:fe},[me,re]=zt("root",{elementType:U9,shouldForwardComponentProp:!0,externalForwardedProps:pe,ownerState:V,className:Le(B.root,g),ref:n}),[he,le]=zt("backdrop",{elementType:W9,shouldForwardComponentProp:!0,externalForwardedProps:pe,ownerState:V}),[X,W]=zt("paper",{elementType:Y9,shouldForwardComponentProp:!0,externalForwardedProps:pe,ownerState:V,className:Le(B.paper,O.className)}),[ee,ce]=zt("container",{elementType:K9,externalForwardedProps:pe,ownerState:V,className:Le(B.container)}),[te,se]=zt("transition",{elementType:wi,externalForwardedProps:pe,ownerState:V,additionalProps:{appear:!0,in:w,timeout:A,role:"presentation"}});return v.jsx(me,{closeAfterTransition:!0,slots:{backdrop:he},slotProps:{backdrop:{transitionDuration:A,as:u,...le}},disableEscapeKeyDown:m,onClose:_,open:w,onClick:U,...re,...z,children:v.jsx(te,{...se,children:v.jsx(ee,{onMouseDown:q,...ce,children:v.jsx(X,{as:E,elevation:24,role:"dialog","aria-describedby":s,"aria-labelledby":G,"aria-modal":l,...W,children:v.jsx(hT.Provider,{value:Y,children:p})})})})})});process.env.NODE_ENV!=="production"&&(gT.propTypes={"aria-describedby":c.string,"aria-labelledby":c.string,"aria-modal":c.oneOfType([c.oneOf(["false","true"]),c.bool]),BackdropComponent:c.elementType,BackdropProps:c.object,children:c.node,classes:c.object,className:c.string,disableEscapeKeyDown:c.bool,fullScreen:c.bool,fullWidth:c.bool,maxWidth:c.oneOfType([c.oneOf(["xs","sm","md","lg","xl",!1]),c.string]),onBackdropClick:c.func,onClick:c.func,onClose:c.func,open:c.bool.isRequired,PaperComponent:c.elementType,PaperProps:c.object,scroll:c.oneOf(["body","paper"]),slotProps:c.shape({backdrop:c.oneOfType([c.func,c.object]),container:c.oneOfType([c.func,c.object]),paper:c.oneOfType([c.func,c.object]),root:c.oneOfType([c.func,c.object]),transition:c.oneOfType([c.func,c.object])}),slots:c.shape({backdrop:c.elementType,container:c.elementType,paper:c.elementType,root:c.elementType,transition:c.elementType}),sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),TransitionComponent:c.elementType,transitionDuration:c.oneOfType([c.number,c.shape({appear:c.number,enter:c.number,exit:c.number})]),TransitionProps:c.object});const G9=be(gT)({[`& .${fc.container}`]:{outline:0},[`& .${fc.paper}`]:{outline:0,minWidth:Pd}}),J9=be(pT)({"&:first-of-type":{padding:0}});function Z9(t){const{children:e,onDismiss:n,open:r,slots:o,slotProps:i}=t,s=(o==null?void 0:o.dialog)??G9,a=(o==null?void 0:o.mobileTransition)??wi;return v.jsx(s,ne({open:r,onClose:n},i==null?void 0:i.dialog,{TransitionComponent:a,TransitionProps:i==null?void 0:i.mobileTransition,PaperComponent:o==null?void 0:o.mobilePaper,PaperProps:i==null?void 0:i.mobilePaper,children:v.jsx(J9,{children:e})}))}const X9=["props","getOpenDialogAriaText"],Q9=t=>{var Z;let{props:e,getOpenDialogAriaText:n}=t,r=rt(t,X9);const{slots:o,slotProps:i,className:s,sx:a,format:l,formatDensity:u,enableAccessibleFieldDOMStructure:f,selectedSections:p,onSelectedSectionsChange:g,timezone:m,name:y,label:b,inputRef:S,readOnly:C,disabled:T,localeText:_}=e,w=I.useRef(null),E=vo(),O=((Z=i==null?void 0:i.toolbar)==null?void 0:Z.hidden)??!1,{open:L,actions:P,layoutProps:$,renderCurrentView:M,fieldProps:A,contextValue:N}=j_(ne({},r,{props:e,fieldRef:w,autoFocusView:!0,additionalViewProps:{},wrapperVariant:"mobile"})),z=o.field,V=wt({elementType:z,externalSlotProps:i==null?void 0:i.field,additionalProps:ne({},A,O&&{id:E},!(T||C)&&{onClick:P.onOpen,onKeyDown:tV(P.onOpen)},{readOnly:C??!0,disabled:T,className:s,sx:a,format:l,formatDensity:u,enableAccessibleFieldDOMStructure:f,selectedSections:p,onSelectedSectionsChange:g,timezone:m,label:b,name:y},S?{inputRef:S}:{}),ownerState:e});V.inputProps=ne({},V.inputProps,{"aria-label":n(A.value)});const B=ne({textField:o.textField},V.slots),R=o.layout??rm;let q=E;O&&(b?q=`${E}-label`:q=void 0);const U=ne({},i,{toolbar:ne({},i==null?void 0:i.toolbar,{titleId:E}),mobilePaper:ne({"aria-labelledby":q},i==null?void 0:i.mobilePaper)}),G=Et(w,V.unstableFieldRef);return{renderPicker:()=>v.jsxs(r_,{contextValue:N,localeText:_,children:[v.jsx(z,ne({},V,{slots:B,slotProps:U,unstableFieldRef:G})),v.jsx(Z9,ne({},P,{open:L,slots:o,slotProps:U,children:v.jsx(R,ne({},$,U==null?void 0:U.layout,{slots:o,slotProps:U,children:M()}))}))]})}},mT=I.forwardRef(function(e,n){var u,f;const r=Ko(),o=qt(),i=g_(e,"MuiMobileDatePicker"),s=ne({day:Ma,month:Ma,year:Ma},i.viewRenderers),a=ne({},i,{viewRenderers:s,format:Og(o,i,!1),slots:ne({field:_d},i.slots),slotProps:ne({},i.slotProps,{field:p=>{var g;return ne({},Mu((g=i.slotProps)==null?void 0:g.field,p),Uw(i),{ref:n})},toolbar:ne({hidden:!1},(u=i.slotProps)==null?void 0:u.toolbar)})}),{renderPicker:l}=Q9({props:a,valueManager:wo,valueType:"date",getOpenDialogAriaText:Kw({utils:o,formatKey:"fullDate",contextTranslation:r.openDatePickerDialogue,propsTranslation:(f=a.localeText)==null?void 0:f.openDatePickerDialogue}),validator:Xl});return l()});mT.propTypes={autoFocus:c.bool,className:c.string,closeOnSelect:c.bool,dayOfWeekFormatter:c.func,defaultValue:c.object,disabled:c.bool,disableFuture:c.bool,disableHighlightToday:c.bool,disableOpenPicker:c.bool,disablePast:c.bool,displayWeekNumber:c.bool,enableAccessibleFieldDOMStructure:c.any,fixedWeekNumber:c.number,format:c.string,formatDensity:c.oneOf(["dense","spacious"]),inputRef:mn,label:c.node,loading:c.bool,localeText:c.object,maxDate:c.object,minDate:c.object,monthsPerRow:c.oneOf([3,4]),name:c.string,onAccept:c.func,onChange:c.func,onClose:c.func,onError:c.func,onMonthChange:c.func,onOpen:c.func,onSelectedSectionsChange:c.func,onViewChange:c.func,onYearChange:c.func,open:c.bool,openTo:c.oneOf(["day","month","year"]),orientation:c.oneOf(["landscape","portrait"]),readOnly:c.bool,reduceAnimations:c.bool,referenceDate:c.object,renderLoading:c.func,selectedSections:c.oneOfType([c.oneOf(["all","day","empty","hours","meridiem","minutes","month","seconds","weekDay","year"]),c.number]),shouldDisableDate:c.func,shouldDisableMonth:c.func,shouldDisableYear:c.func,showDaysOutsideCurrentMonth:c.bool,slotProps:c.object,slots:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),timezone:c.string,value:c.object,view:c.oneOf(["day","month","year"]),viewRenderers:c.shape({day:c.func,month:c.func,year:c.func}),views:c.arrayOf(c.oneOf(["day","month","year"]).isRequired),yearsOrder:c.oneOf(["asc","desc"]),yearsPerRow:c.oneOf([3,4])};const eq=["desktopModeMediaQuery"],yT=I.forwardRef(function(e,n){const r=Wt({props:e,name:"MuiDatePicker"}),{desktopModeMediaQuery:o=nV}=r,i=rt(r,eq);return p_(o,{defaultMatches:!0})?v.jsx(fT,ne({ref:n},i)):v.jsx(mT,ne({ref:n},i))});process.env.NODE_ENV!=="production"&&(yT.propTypes={autoFocus:c.bool,className:c.string,closeOnSelect:c.bool,dayOfWeekFormatter:c.func,defaultValue:c.object,desktopModeMediaQuery:c.string,disabled:c.bool,disableFuture:c.bool,disableHighlightToday:c.bool,disableOpenPicker:c.bool,disablePast:c.bool,displayWeekNumber:c.bool,enableAccessibleFieldDOMStructure:c.any,fixedWeekNumber:c.number,format:c.string,formatDensity:c.oneOf(["dense","spacious"]),inputRef:mn,label:c.node,loading:c.bool,localeText:c.object,maxDate:c.object,minDate:c.object,monthsPerRow:c.oneOf([3,4]),name:c.string,onAccept:c.func,onChange:c.func,onClose:c.func,onError:c.func,onMonthChange:c.func,onOpen:c.func,onSelectedSectionsChange:c.func,onViewChange:c.func,onYearChange:c.func,open:c.bool,openTo:c.oneOf(["day","month","year"]),orientation:c.oneOf(["landscape","portrait"]),readOnly:c.bool,reduceAnimations:c.bool,referenceDate:c.object,renderLoading:c.func,selectedSections:c.oneOfType([c.oneOf(["all","day","empty","hours","meridiem","minutes","month","seconds","weekDay","year"]),c.number]),shouldDisableDate:c.func,shouldDisableMonth:c.func,shouldDisableYear:c.func,showDaysOutsideCurrentMonth:c.bool,slotProps:c.object,slots:c.object,sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),timezone:c.string,value:c.object,view:c.oneOf(["day","month","year"]),viewRenderers:c.shape({day:c.func,month:c.func,year:c.func}),views:c.arrayOf(c.oneOf(["day","month","year"]).isRequired),yearsOrder:c.oneOf(["asc","desc"]),yearsPerRow:c.oneOf([3,4])});const tq={invalidDate:"Date selected is invalid",minDate:"Date selected is too far in the past",maxDate:"Date selected is too far in the future",disableFuture:"Date selected cannot be in the future",disablePast:"Date selected cannot be in the past"},Fd=t=>{const{name:e,label:n=_n(e),required:r=!1,readOnly:o=!1,format:i="MM/DD/YYYY",errorMessages:s,isDatePicker:a=!1,margin:l="dense",staticLabel:u=!1,staticLabelProps:f={fontSize:".9em",color:"#808080"}}=t,[p,g,m]=jt.useField({name:e}),{setValue:y,setError:b}=m,{value:S}=p,{error:C}=g,T=N=>{if(!N)return null;const z=pn.utc(N);return z&&z.isValid()?pn(z):null},_=N=>{const z=N==null?void 0:N.utc();return!z||!z.isValid()?"":z.toISOString()},[w,E]=I.useState(T(S)),[O,L]=I.useState(null),P={...tq,...s},$=["staticLabel","staticLabelProps","label","errorMessages","isDatePicker","dateFieldProps","datePickerProps","onChange"],M=(N,z)=>_(N)!==z;I.useEffect(()=>{M(w,S)&&y(_(w))},[w]),I.useEffect(()=>{M(w,S)&&E(T(S))},[S]),I.useEffect(()=>{const N=O?P[O]??O:"";b(N)},[O]);const A={label:u?void 0:n,format:i,onError:L,value:w,onChange:(N,z)=>{var V;E(N?N.utc():null),(V=t.onChange)==null||V.call(t,_(N),z)},...Jn({...t},$)};return v.jsxs(F.FormControl,{fullWidth:!0,margin:l,children:[(u||o)&&v.jsx(F.Typography,{...f,children:n}),o?v.jsx(F.Typography,{"data-testid":"date-field_readonly-value",children:w!=null&&w.isValid()?w.format(i):""}):v.jsxs(F.Box,{children:[v.jsx(ag,{dateAdapter:y3,children:v.jsx(F.Box,{children:a?v.jsx(yT,{...A,slotProps:{textField:{fullWidth:!0,error:!!C,required:!!r}}}):v.jsx(_d,{id:`${e}-df`,...A,fullWidth:!0,slotProps:{textField:{error:!!C}}})})}),v.jsx(Xn,{name:e,id:`${e}-err`})]})]})},nq=t=>{const{nameTo:e,nameFrom:n,labelTo:r=_n(e),labelFrom:o=_n(n),fromFieldProps:i,toFieldProps:s,staticLabels:a=!1}=t,l=["nameTo","nameFrom","toFieldProps","fromFieldProps","labelTo","labelFrom"],u=F.useMediaQuery(F.useTheme().breakpoints.down("sm"));return v.jsxs("div",{style:{display:"flex",flexDirection:u?"column":"row",justifyContent:"space-between",gap:"10px"},children:[v.jsx(Fd,{name:n,staticLabel:a,label:o,...Jn({...t,...i},l)}),v.jsx(Fd,{name:e,staticLabel:a,label:r,...Jn({...t,...s},l)})]})};function Pn(t){this.content=t}Pn.prototype={constructor:Pn,find:function(t){for(var e=0;e<this.content.length;e+=2)if(this.content[e]===t)return e;return-1},get:function(t){var e=this.find(t);return e==-1?void 0:this.content[e+1]},update:function(t,e,n){var r=n&&n!=t?this.remove(n):this,o=r.find(t),i=r.content.slice();return o==-1?i.push(n||t,e):(i[o+1]=e,n&&(i[o]=n)),new Pn(i)},remove:function(t){var e=this.find(t);if(e==-1)return this;var n=this.content.slice();return n.splice(e,2),new Pn(n)},addToStart:function(t,e){return new Pn([t,e].concat(this.remove(t).content))},addToEnd:function(t,e){var n=this.remove(t).content.slice();return n.push(t,e),new Pn(n)},addBefore:function(t,e,n){var r=this.remove(e),o=r.content.slice(),i=r.find(t);return o.splice(i==-1?o.length:i,0,e,n),new Pn(o)},forEach:function(t){for(var e=0;e<this.content.length;e+=2)t(this.content[e],this.content[e+1])},prepend:function(t){return t=Pn.from(t),t.size?new Pn(t.content.concat(this.subtract(t).content)):this},append:function(t){return t=Pn.from(t),t.size?new Pn(this.subtract(t).content.concat(t.content)):this},subtract:function(t){var e=this;t=Pn.from(t);for(var n=0;n<t.content.length;n+=2)e=e.remove(t.content[n]);return e},toObject:function(){var t={};return this.forEach(function(e,n){t[e]=n}),t},get size(){return this.content.length>>1}},Pn.from=function(t){if(t instanceof Pn)return t;var e=[];if(t)for(var n in t)e.push(n,t[n]);return new Pn(e)};function bT(t,e,n){for(let r=0;;r++){if(r==t.childCount||r==e.childCount)return t.childCount==e.childCount?null:n;let o=t.child(r),i=e.child(r);if(o==i){n+=o.nodeSize;continue}if(!o.sameMarkup(i))return n;if(o.isText&&o.text!=i.text){for(let s=0;o.text[s]==i.text[s];s++)n++;return n}if(o.content.size||i.content.size){let s=bT(o.content,i.content,n+1);if(s!=null)return s}n+=o.nodeSize}}function vT(t,e,n,r){for(let o=t.childCount,i=e.childCount;;){if(o==0||i==0)return o==i?null:{a:n,b:r};let s=t.child(--o),a=e.child(--i),l=s.nodeSize;if(s==a){n-=l,r-=l;continue}if(!s.sameMarkup(a))return{a:n,b:r};if(s.isText&&s.text!=a.text){let u=0,f=Math.min(s.text.length,a.text.length);for(;u<f&&s.text[s.text.length-u-1]==a.text[a.text.length-u-1];)u++,n--,r--;return{a:n,b:r}}if(s.content.size||a.content.size){let u=vT(s.content,a.content,n-1,r-1);if(u)return u}n-=l,r-=l}}class Te{constructor(e,n){if(this.content=e,this.size=n||0,n==null)for(let r=0;r<e.length;r++)this.size+=e[r].nodeSize}nodesBetween(e,n,r,o=0,i){for(let s=0,a=0;a<n;s++){let l=this.content[s],u=a+l.nodeSize;if(u>e&&r(l,o+a,i||null,s)!==!1&&l.content.size){let f=a+1;l.nodesBetween(Math.max(0,e-f),Math.min(l.content.size,n-f),r,o+f)}a=u}}descendants(e){this.nodesBetween(0,this.size,e)}textBetween(e,n,r,o){let i="",s=!0;return this.nodesBetween(e,n,(a,l)=>{let u=a.isText?a.text.slice(Math.max(e,l)-l,n-l):a.isLeaf?o?typeof o=="function"?o(a):o:a.type.spec.leafText?a.type.spec.leafText(a):"":"";a.isBlock&&(a.isLeaf&&u||a.isTextblock)&&r&&(s?s=!1:i+=r),i+=u},0),i}append(e){if(!e.size)return this;if(!this.size)return e;let n=this.lastChild,r=e.firstChild,o=this.content.slice(),i=0;for(n.isText&&n.sameMarkup(r)&&(o[o.length-1]=n.withText(n.text+r.text),i=1);i<e.content.length;i++)o.push(e.content[i]);return new Te(o,this.size+e.size)}cut(e,n=this.size){if(e==0&&n==this.size)return this;let r=[],o=0;if(n>e)for(let i=0,s=0;s<n;i++){let a=this.content[i],l=s+a.nodeSize;l>e&&((s<e||l>n)&&(a.isText?a=a.cut(Math.max(0,e-s),Math.min(a.text.length,n-s)):a=a.cut(Math.max(0,e-s-1),Math.min(a.content.size,n-s-1))),r.push(a),o+=a.nodeSize),s=l}return new Te(r,o)}cutByIndex(e,n){return e==n?Te.empty:e==0&&n==this.content.length?this:new Te(this.content.slice(e,n))}replaceChild(e,n){let r=this.content[e];if(r==n)return this;let o=this.content.slice(),i=this.size+n.nodeSize-r.nodeSize;return o[e]=n,new Te(o,i)}addToStart(e){return new Te([e].concat(this.content),this.size+e.nodeSize)}addToEnd(e){return new Te(this.content.concat(e),this.size+e.nodeSize)}eq(e){if(this.content.length!=e.content.length)return!1;for(let n=0;n<this.content.length;n++)if(!this.content[n].eq(e.content[n]))return!1;return!0}get firstChild(){return this.content.length?this.content[0]:null}get lastChild(){return this.content.length?this.content[this.content.length-1]:null}get childCount(){return this.content.length}child(e){let n=this.content[e];if(!n)throw new RangeError("Index "+e+" out of range for "+this);return n}maybeChild(e){return this.content[e]||null}forEach(e){for(let n=0,r=0;n<this.content.length;n++){let o=this.content[n];e(o,r,n),r+=o.nodeSize}}findDiffStart(e,n=0){return bT(this,e,n)}findDiffEnd(e,n=this.size,r=e.size){return vT(this,e,n,r)}findIndex(e,n=-1){if(e==0)return $d(0,e);if(e==this.size)return $d(this.content.length,e);if(e>this.size||e<0)throw new RangeError(`Position ${e} outside of fragment (${this})`);for(let r=0,o=0;;r++){let i=this.child(r),s=o+i.nodeSize;if(s>=e)return s==e||n>0?$d(r+1,s):$d(r,o);o=s}}toString(){return"<"+this.toStringInner()+">"}toStringInner(){return this.content.join(", ")}toJSON(){return this.content.length?this.content.map(e=>e.toJSON()):null}static fromJSON(e,n){if(!n)return Te.empty;if(!Array.isArray(n))throw new RangeError("Invalid input for Fragment.fromJSON");return new Te(n.map(e.nodeFromJSON))}static fromArray(e){if(!e.length)return Te.empty;let n,r=0;for(let o=0;o<e.length;o++){let i=e[o];r+=i.nodeSize,o&&i.isText&&e[o-1].sameMarkup(i)?(n||(n=e.slice(0,o)),n[n.length-1]=i.withText(n[n.length-1].text+i.text)):n&&n.push(i)}return new Te(n||e,r)}static from(e){if(!e)return Te.empty;if(e instanceof Te)return e;if(Array.isArray(e))return this.fromArray(e);if(e.attrs)return new Te([e],e.nodeSize);throw new RangeError("Can not convert "+e+" to a Fragment"+(e.nodesBetween?" (looks like multiple versions of prosemirror-model were loaded)":""))}}Te.empty=new Te([],0);const om={index:0,offset:0};function $d(t,e){return om.index=t,om.offset=e,om}function Bd(t,e){if(t===e)return!0;if(!(t&&typeof t=="object")||!(e&&typeof e=="object"))return!1;let n=Array.isArray(t);if(Array.isArray(e)!=n)return!1;if(n){if(t.length!=e.length)return!1;for(let r=0;r<t.length;r++)if(!Bd(t[r],e[r]))return!1}else{for(let r in t)if(!(r in e)||!Bd(t[r],e[r]))return!1;for(let r in e)if(!(r in t))return!1}return!0}let Ft=class Rx{constructor(e,n){this.type=e,this.attrs=n}addToSet(e){let n,r=!1;for(let o=0;o<e.length;o++){let i=e[o];if(this.eq(i))return e;if(this.type.excludes(i.type))n||(n=e.slice(0,o));else{if(i.type.excludes(this.type))return e;!r&&i.type.rank>this.type.rank&&(n||(n=e.slice(0,o)),n.push(this),r=!0),n&&n.push(i)}}return n||(n=e.slice()),r||n.push(this),n}removeFromSet(e){for(let n=0;n<e.length;n++)if(this.eq(e[n]))return e.slice(0,n).concat(e.slice(n+1));return e}isInSet(e){for(let n=0;n<e.length;n++)if(this.eq(e[n]))return!0;return!1}eq(e){return this==e||this.type==e.type&&Bd(this.attrs,e.attrs)}toJSON(){let e={type:this.type.name};for(let n in this.attrs){e.attrs=this.attrs;break}return e}static fromJSON(e,n){if(!n)throw new RangeError("Invalid input for Mark.fromJSON");let r=e.marks[n.type];if(!r)throw new RangeError(`There is no mark type ${n.type} in this schema`);let o=r.create(n.attrs);return r.checkAttrs(o.attrs),o}static sameSet(e,n){if(e==n)return!0;if(e.length!=n.length)return!1;for(let r=0;r<e.length;r++)if(!e[r].eq(n[r]))return!1;return!0}static setFrom(e){if(!e||Array.isArray(e)&&e.length==0)return Rx.none;if(e instanceof Rx)return[e];let n=e.slice();return n.sort((r,o)=>r.type.rank-o.type.rank),n}};Ft.none=[];class Rd extends Error{}class Ie{constructor(e,n,r){this.content=e,this.openStart=n,this.openEnd=r}get size(){return this.content.size-this.openStart-this.openEnd}insertAt(e,n){let r=ST(this.content,e+this.openStart,n);return r&&new Ie(r,this.openStart,this.openEnd)}removeBetween(e,n){return new Ie(xT(this.content,e+this.openStart,n+this.openStart),this.openStart,this.openEnd)}eq(e){return this.content.eq(e.content)&&this.openStart==e.openStart&&this.openEnd==e.openEnd}toString(){return this.content+"("+this.openStart+","+this.openEnd+")"}toJSON(){if(!this.content.size)return null;let e={content:this.content.toJSON()};return this.openStart>0&&(e.openStart=this.openStart),this.openEnd>0&&(e.openEnd=this.openEnd),e}static fromJSON(e,n){if(!n)return Ie.empty;let r=n.openStart||0,o=n.openEnd||0;if(typeof r!="number"||typeof o!="number")throw new RangeError("Invalid input for Slice.fromJSON");return new Ie(Te.fromJSON(e,n.content),r,o)}static maxOpen(e,n=!0){let r=0,o=0;for(let i=e.firstChild;i&&!i.isLeaf&&(n||!i.type.spec.isolating);i=i.firstChild)r++;for(let i=e.lastChild;i&&!i.isLeaf&&(n||!i.type.spec.isolating);i=i.lastChild)o++;return new Ie(e,r,o)}}Ie.empty=new Ie(Te.empty,0,0);function xT(t,e,n){let{index:r,offset:o}=t.findIndex(e),i=t.maybeChild(r),{index:s,offset:a}=t.findIndex(n);if(o==e||i.isText){if(a!=n&&!t.child(s).isText)throw new RangeError("Removing non-flat range");return t.cut(0,e).append(t.cut(n))}if(r!=s)throw new RangeError("Removing non-flat range");return t.replaceChild(r,i.copy(xT(i.content,e-o-1,n-o-1)))}function ST(t,e,n,r){let{index:o,offset:i}=t.findIndex(e),s=t.maybeChild(o);if(i==e||s.isText)return t.cut(0,e).append(n).append(t.cut(e));let a=ST(s.content,e-i-1,n);return a&&t.replaceChild(o,s.copy(a))}function rq(t,e,n){if(n.openStart>t.depth)throw new Rd("Inserted content deeper than insertion position");if(t.depth-n.openStart!=e.depth-n.openEnd)throw new Rd("Inconsistent open depths");return CT(t,e,n,0)}function CT(t,e,n,r){let o=t.index(r),i=t.node(r);if(o==e.index(r)&&r<t.depth-n.openStart){let s=CT(t,e,n,r+1);return i.copy(i.content.replaceChild(o,s))}else if(n.content.size)if(!n.openStart&&!n.openEnd&&t.depth==r&&e.depth==r){let s=t.parent,a=s.content;return _s(s,a.cut(0,t.parentOffset).append(n.content).append(a.cut(e.parentOffset)))}else{let{start:s,end:a}=oq(n,t);return _s(i,_T(t,s,a,e,r))}else return _s(i,zd(t,e,r))}function wT(t,e){if(!e.type.compatibleContent(t.type))throw new Rd("Cannot join "+e.type.name+" onto "+t.type.name)}function im(t,e,n){let r=t.node(n);return wT(r,e.node(n)),r}function ws(t,e){let n=e.length-1;n>=0&&t.isText&&t.sameMarkup(e[n])?e[n]=t.withText(e[n].text+t.text):e.push(t)}function pc(t,e,n,r){let o=(e||t).node(n),i=0,s=e?e.index(n):o.childCount;t&&(i=t.index(n),t.depth>n?i++:t.textOffset&&(ws(t.nodeAfter,r),i++));for(let a=i;a<s;a++)ws(o.child(a),r);e&&e.depth==n&&e.textOffset&&ws(e.nodeBefore,r)}function _s(t,e){return t.type.checkContent(e),t.copy(e)}function _T(t,e,n,r,o){let i=t.depth>o&&im(t,e,o+1),s=r.depth>o&&im(n,r,o+1),a=[];return pc(null,t,o,a),i&&s&&e.index(o)==n.index(o)?(wT(i,s),ws(_s(i,_T(t,e,n,r,o+1)),a)):(i&&ws(_s(i,zd(t,e,o+1)),a),pc(e,n,o,a),s&&ws(_s(s,zd(n,r,o+1)),a)),pc(r,null,o,a),new Te(a)}function zd(t,e,n){let r=[];if(pc(null,t,n,r),t.depth>n){let o=im(t,e,n+1);ws(_s(o,zd(t,e,n+1)),r)}return pc(e,null,n,r),new Te(r)}function oq(t,e){let n=e.depth-t.openStart,o=e.node(n).copy(t.content);for(let i=n-1;i>=0;i--)o=e.node(i).copy(Te.from(o));return{start:o.resolveNoCache(t.openStart+n),end:o.resolveNoCache(o.content.size-t.openEnd-n)}}class hc{constructor(e,n,r){this.pos=e,this.path=n,this.parentOffset=r,this.depth=n.length/3-1}resolveDepth(e){return e==null?this.depth:e<0?this.depth+e:e}get parent(){return this.node(this.depth)}get doc(){return this.node(0)}node(e){return this.path[this.resolveDepth(e)*3]}index(e){return this.path[this.resolveDepth(e)*3+1]}indexAfter(e){return e=this.resolveDepth(e),this.index(e)+(e==this.depth&&!this.textOffset?0:1)}start(e){return e=this.resolveDepth(e),e==0?0:this.path[e*3-1]+1}end(e){return e=this.resolveDepth(e),this.start(e)+this.node(e).content.size}before(e){if(e=this.resolveDepth(e),!e)throw new RangeError("There is no position before the top-level node");return e==this.depth+1?this.pos:this.path[e*3-1]}after(e){if(e=this.resolveDepth(e),!e)throw new RangeError("There is no position after the top-level node");return e==this.depth+1?this.pos:this.path[e*3-1]+this.path[e*3].nodeSize}get textOffset(){return this.pos-this.path[this.path.length-1]}get nodeAfter(){let e=this.parent,n=this.index(this.depth);if(n==e.childCount)return null;let r=this.pos-this.path[this.path.length-1],o=e.child(n);return r?e.child(n).cut(r):o}get nodeBefore(){let e=this.index(this.depth),n=this.pos-this.path[this.path.length-1];return n?this.parent.child(e).cut(0,n):e==0?null:this.parent.child(e-1)}posAtIndex(e,n){n=this.resolveDepth(n);let r=this.path[n*3],o=n==0?0:this.path[n*3-1]+1;for(let i=0;i<e;i++)o+=r.child(i).nodeSize;return o}marks(){let e=this.parent,n=this.index();if(e.content.size==0)return Ft.none;if(this.textOffset)return e.child(n).marks;let r=e.maybeChild(n-1),o=e.maybeChild(n);if(!r){let a=r;r=o,o=a}let i=r.marks;for(var s=0;s<i.length;s++)i[s].type.spec.inclusive===!1&&(!o||!i[s].isInSet(o.marks))&&(i=i[s--].removeFromSet(i));return i}marksAcross(e){let n=this.parent.maybeChild(this.index());if(!n||!n.isInline)return null;let r=n.marks,o=e.parent.maybeChild(e.index());for(var i=0;i<r.length;i++)r[i].type.spec.inclusive===!1&&(!o||!r[i].isInSet(o.marks))&&(r=r[i--].removeFromSet(r));return r}sharedDepth(e){for(let n=this.depth;n>0;n--)if(this.start(n)<=e&&this.end(n)>=e)return n;return 0}blockRange(e=this,n){if(e.pos<this.pos)return e.blockRange(this);for(let r=this.depth-(this.parent.inlineContent||this.pos==e.pos?1:0);r>=0;r--)if(e.pos<=this.end(r)&&(!n||n(this.node(r))))return new Vd(this,e,r);return null}sameParent(e){return this.pos-this.parentOffset==e.pos-e.parentOffset}max(e){return e.pos>this.pos?e:this}min(e){return e.pos<this.pos?e:this}toString(){let e="";for(let n=1;n<=this.depth;n++)e+=(e?"/":"")+this.node(n).type.name+"_"+this.index(n-1);return e+":"+this.parentOffset}static resolve(e,n){if(!(n>=0&&n<=e.content.size))throw new RangeError("Position "+n+" out of range");let r=[],o=0,i=n;for(let s=e;;){let{index:a,offset:l}=s.content.findIndex(i),u=i-l;if(r.push(s,a,o+l),!u||(s=s.child(a),s.isText))break;i=u-1,o+=l+1}return new hc(n,r,i)}static resolveCached(e,n){let r=TT.get(e);if(r)for(let i=0;i<r.elts.length;i++){let s=r.elts[i];if(s.pos==n)return s}else TT.set(e,r=new iq);let o=r.elts[r.i]=hc.resolve(e,n);return r.i=(r.i+1)%sq,o}}class iq{constructor(){this.elts=[],this.i=0}}const sq=12,TT=new WeakMap;class Vd{constructor(e,n,r){this.$from=e,this.$to=n,this.depth=r}get start(){return this.$from.before(this.depth+1)}get end(){return this.$to.after(this.depth+1)}get parent(){return this.$from.node(this.depth)}get startIndex(){return this.$from.index(this.depth)}get endIndex(){return this.$to.indexAfter(this.depth)}}const aq=Object.create(null);let Ei=class zx{constructor(e,n,r,o=Ft.none){this.type=e,this.attrs=n,this.marks=o,this.content=r||Te.empty}get children(){return this.content.content}get nodeSize(){return this.isLeaf?1:2+this.content.size}get childCount(){return this.content.childCount}child(e){return this.content.child(e)}maybeChild(e){return this.content.maybeChild(e)}forEach(e){this.content.forEach(e)}nodesBetween(e,n,r,o=0){this.content.nodesBetween(e,n,r,o,this)}descendants(e){this.nodesBetween(0,this.content.size,e)}get textContent(){return this.isLeaf&&this.type.spec.leafText?this.type.spec.leafText(this):this.textBetween(0,this.content.size,"")}textBetween(e,n,r,o){return this.content.textBetween(e,n,r,o)}get firstChild(){return this.content.firstChild}get lastChild(){return this.content.lastChild}eq(e){return this==e||this.sameMarkup(e)&&this.content.eq(e.content)}sameMarkup(e){return this.hasMarkup(e.type,e.attrs,e.marks)}hasMarkup(e,n,r){return this.type==e&&Bd(this.attrs,n||e.defaultAttrs||aq)&&Ft.sameSet(this.marks,r||Ft.none)}copy(e=null){return e==this.content?this:new zx(this.type,this.attrs,e,this.marks)}mark(e){return e==this.marks?this:new zx(this.type,this.attrs,this.content,e)}cut(e,n=this.content.size){return e==0&&n==this.content.size?this:this.copy(this.content.cut(e,n))}slice(e,n=this.content.size,r=!1){if(e==n)return Ie.empty;let o=this.resolve(e),i=this.resolve(n),s=r?0:o.sharedDepth(n),a=o.start(s),u=o.node(s).content.cut(o.pos-a,i.pos-a);return new Ie(u,o.depth-s,i.depth-s)}replace(e,n,r){return rq(this.resolve(e),this.resolve(n),r)}nodeAt(e){for(let n=this;;){let{index:r,offset:o}=n.content.findIndex(e);if(n=n.maybeChild(r),!n)return null;if(o==e||n.isText)return n;e-=o+1}}childAfter(e){let{index:n,offset:r}=this.content.findIndex(e);return{node:this.content.maybeChild(n),index:n,offset:r}}childBefore(e){if(e==0)return{node:null,index:0,offset:0};let{index:n,offset:r}=this.content.findIndex(e);if(r<e)return{node:this.content.child(n),index:n,offset:r};let o=this.content.child(n-1);return{node:o,index:n-1,offset:r-o.nodeSize}}resolve(e){return hc.resolveCached(this,e)}resolveNoCache(e){return hc.resolve(this,e)}rangeHasMark(e,n,r){let o=!1;return n>e&&this.nodesBetween(e,n,i=>(r.isInSet(i.marks)&&(o=!0),!o)),o}get isBlock(){return this.type.isBlock}get isTextblock(){return this.type.isTextblock}get inlineContent(){return this.type.inlineContent}get isInline(){return this.type.isInline}get isText(){return this.type.isText}get isLeaf(){return this.type.isLeaf}get isAtom(){return this.type.isAtom}toString(){if(this.type.spec.toDebugString)return this.type.spec.toDebugString(this);let e=this.type.name;return this.content.size&&(e+="("+this.content.toStringInner()+")"),kT(this.marks,e)}contentMatchAt(e){let n=this.type.contentMatch.matchFragment(this.content,0,e);if(!n)throw new Error("Called contentMatchAt on a node with invalid content");return n}canReplace(e,n,r=Te.empty,o=0,i=r.childCount){let s=this.contentMatchAt(e).matchFragment(r,o,i),a=s&&s.matchFragment(this.content,n);if(!a||!a.validEnd)return!1;for(let l=o;l<i;l++)if(!this.type.allowsMarks(r.child(l).marks))return!1;return!0}canReplaceWith(e,n,r,o){if(o&&!this.type.allowsMarks(o))return!1;let i=this.contentMatchAt(e).matchType(r),s=i&&i.matchFragment(this.content,n);return s?s.validEnd:!1}canAppend(e){return e.content.size?this.canReplace(this.childCount,this.childCount,e.content):this.type.compatibleContent(e.type)}check(){this.type.checkContent(this.content),this.type.checkAttrs(this.attrs);let e=Ft.none;for(let n=0;n<this.marks.length;n++){let r=this.marks[n];r.type.checkAttrs(r.attrs),e=r.addToSet(e)}if(!Ft.sameSet(e,this.marks))throw new RangeError(`Invalid collection of marks for node ${this.type.name}: ${this.marks.map(n=>n.type.name)}`);this.content.forEach(n=>n.check())}toJSON(){let e={type:this.type.name};for(let n in this.attrs){e.attrs=this.attrs;break}return this.content.size&&(e.content=this.content.toJSON()),this.marks.length&&(e.marks=this.marks.map(n=>n.toJSON())),e}static fromJSON(e,n){if(!n)throw new RangeError("Invalid input for Node.fromJSON");let r;if(n.marks){if(!Array.isArray(n.marks))throw new RangeError("Invalid mark data for Node.fromJSON");r=n.marks.map(e.markFromJSON)}if(n.type=="text"){if(typeof n.text!="string")throw new RangeError("Invalid text node in JSON");return e.text(n.text,r)}let o=Te.fromJSON(e,n.content),i=e.nodeType(n.type).create(n.attrs,o,r);return i.type.checkAttrs(i.attrs),i}};Ei.prototype.text=void 0;class Hd extends Ei{constructor(e,n,r,o){if(super(e,n,null,o),!r)throw new RangeError("Empty text nodes are not allowed");this.text=r}toString(){return this.type.spec.toDebugString?this.type.spec.toDebugString(this):kT(this.marks,JSON.stringify(this.text))}get textContent(){return this.text}textBetween(e,n){return this.text.slice(e,n)}get nodeSize(){return this.text.length}mark(e){return e==this.marks?this:new Hd(this.type,this.attrs,this.text,e)}withText(e){return e==this.text?this:new Hd(this.type,this.attrs,e,this.marks)}cut(e=0,n=this.text.length){return e==0&&n==this.text.length?this:this.withText(this.text.slice(e,n))}eq(e){return this.sameMarkup(e)&&this.text==e.text}toJSON(){let e=super.toJSON();return e.text=this.text,e}}function kT(t,e){for(let n=t.length-1;n>=0;n--)e=t[n].type.name+"("+e+")";return e}class Ts{constructor(e){this.validEnd=e,this.next=[],this.wrapCache=[]}static parse(e,n){let r=new lq(e,n);if(r.next==null)return Ts.empty;let o=ET(r);r.next&&r.err("Unexpected trailing text");let i=gq(hq(o));return mq(i,r),i}matchType(e){for(let n=0;n<this.next.length;n++)if(this.next[n].type==e)return this.next[n].next;return null}matchFragment(e,n=0,r=e.childCount){let o=this;for(let i=n;o&&i<r;i++)o=o.matchType(e.child(i).type);return o}get inlineContent(){return this.next.length!=0&&this.next[0].type.isInline}get defaultType(){for(let e=0;e<this.next.length;e++){let{type:n}=this.next[e];if(!(n.isText||n.hasRequiredAttrs()))return n}return null}compatible(e){for(let n=0;n<this.next.length;n++)for(let r=0;r<e.next.length;r++)if(this.next[n].type==e.next[r].type)return!0;return!1}fillBefore(e,n=!1,r=0){let o=[this];function i(s,a){let l=s.matchFragment(e,r);if(l&&(!n||l.validEnd))return Te.from(a.map(u=>u.createAndFill()));for(let u=0;u<s.next.length;u++){let{type:f,next:p}=s.next[u];if(!(f.isText||f.hasRequiredAttrs())&&o.indexOf(p)==-1){o.push(p);let g=i(p,a.concat(f));if(g)return g}}return null}return i(this,[])}findWrapping(e){for(let r=0;r<this.wrapCache.length;r+=2)if(this.wrapCache[r]==e)return this.wrapCache[r+1];let n=this.computeWrapping(e);return this.wrapCache.push(e,n),n}computeWrapping(e){let n=Object.create(null),r=[{match:this,type:null,via:null}];for(;r.length;){let o=r.shift(),i=o.match;if(i.matchType(e)){let s=[];for(let a=o;a.type;a=a.via)s.push(a.type);return s.reverse()}for(let s=0;s<i.next.length;s++){let{type:a,next:l}=i.next[s];!a.isLeaf&&!a.hasRequiredAttrs()&&!(a.name in n)&&(!o.type||l.validEnd)&&(r.push({match:a.contentMatch,type:a,via:o}),n[a.name]=!0)}}return null}get edgeCount(){return this.next.length}edge(e){if(e>=this.next.length)throw new RangeError(`There's no ${e}th edge in this content match`);return this.next[e]}toString(){let e=[];function n(r){e.push(r);for(let o=0;o<r.next.length;o++)e.indexOf(r.next[o].next)==-1&&n(r.next[o].next)}return n(this),e.map((r,o)=>{let i=o+(r.validEnd?"*":" ")+" ";for(let s=0;s<r.next.length;s++)i+=(s?", ":"")+r.next[s].type.name+"->"+e.indexOf(r.next[s].next);return i}).join(`
|
|
235
235
|
`)}}Ts.empty=new Ts(!0);class lq{constructor(e,n){this.string=e,this.nodeTypes=n,this.inline=null,this.pos=0,this.tokens=e.split(/\s*(?=\b|\W|$)/),this.tokens[this.tokens.length-1]==""&&this.tokens.pop(),this.tokens[0]==""&&this.tokens.shift()}get next(){return this.tokens[this.pos]}eat(e){return this.next==e&&(this.pos++||!0)}err(e){throw new SyntaxError(e+" (in content expression '"+this.string+"')")}}function ET(t){let e=[];do e.push(cq(t));while(t.eat("|"));return e.length==1?e[0]:{type:"choice",exprs:e}}function cq(t){let e=[];do e.push(uq(t));while(t.next&&t.next!=")"&&t.next!="|");return e.length==1?e[0]:{type:"seq",exprs:e}}function uq(t){let e=pq(t);for(;;)if(t.eat("+"))e={type:"plus",expr:e};else if(t.eat("*"))e={type:"star",expr:e};else if(t.eat("?"))e={type:"opt",expr:e};else if(t.eat("{"))e=dq(t,e);else break;return e}function MT(t){/\D/.test(t.next)&&t.err("Expected number, got '"+t.next+"'");let e=Number(t.next);return t.pos++,e}function dq(t,e){let n=MT(t),r=n;return t.eat(",")&&(t.next!="}"?r=MT(t):r=-1),t.eat("}")||t.err("Unclosed braced range"),{type:"range",min:n,max:r,expr:e}}function fq(t,e){let n=t.nodeTypes,r=n[e];if(r)return[r];let o=[];for(let i in n){let s=n[i];s.isInGroup(e)&&o.push(s)}return o.length==0&&t.err("No node type or group '"+e+"' found"),o}function pq(t){if(t.eat("(")){let e=ET(t);return t.eat(")")||t.err("Missing closing paren"),e}else if(/\W/.test(t.next))t.err("Unexpected token '"+t.next+"'");else{let e=fq(t,t.next).map(n=>(t.inline==null?t.inline=n.isInline:t.inline!=n.isInline&&t.err("Mixing inline and block content"),{type:"name",value:n}));return t.pos++,e.length==1?e[0]:{type:"choice",exprs:e}}}function hq(t){let e=[[]];return o(i(t,0),n()),e;function n(){return e.push([])-1}function r(s,a,l){let u={term:l,to:a};return e[s].push(u),u}function o(s,a){s.forEach(l=>l.to=a)}function i(s,a){if(s.type=="choice")return s.exprs.reduce((l,u)=>l.concat(i(u,a)),[]);if(s.type=="seq")for(let l=0;;l++){let u=i(s.exprs[l],a);if(l==s.exprs.length-1)return u;o(u,a=n())}else if(s.type=="star"){let l=n();return r(a,l),o(i(s.expr,l),l),[r(l)]}else if(s.type=="plus"){let l=n();return o(i(s.expr,a),l),o(i(s.expr,l),l),[r(l)]}else{if(s.type=="opt")return[r(a)].concat(i(s.expr,a));if(s.type=="range"){let l=a;for(let u=0;u<s.min;u++){let f=n();o(i(s.expr,l),f),l=f}if(s.max==-1)o(i(s.expr,l),l);else for(let u=s.min;u<s.max;u++){let f=n();r(l,f),o(i(s.expr,l),f),l=f}return[r(l)]}else{if(s.type=="name")return[r(a,void 0,s.value)];throw new Error("Unknown expr type")}}}}function OT(t,e){return e-t}function AT(t,e){let n=[];return r(e),n.sort(OT);function r(o){let i=t[o];if(i.length==1&&!i[0].term)return r(i[0].to);n.push(o);for(let s=0;s<i.length;s++){let{term:a,to:l}=i[s];!a&&n.indexOf(l)==-1&&r(l)}}}function gq(t){let e=Object.create(null);return n(AT(t,0));function n(r){let o=[];r.forEach(s=>{t[s].forEach(({term:a,to:l})=>{if(!a)return;let u;for(let f=0;f<o.length;f++)o[f][0]==a&&(u=o[f][1]);AT(t,l).forEach(f=>{u||o.push([a,u=[]]),u.indexOf(f)==-1&&u.push(f)})})});let i=e[r.join(",")]=new Ts(r.indexOf(t.length-1)>-1);for(let s=0;s<o.length;s++){let a=o[s][1].sort(OT);i.next.push({type:o[s][0],next:e[a.join(",")]||n(a)})}return i}}function mq(t,e){for(let n=0,r=[t];n<r.length;n++){let o=r[n],i=!o.validEnd,s=[];for(let a=0;a<o.next.length;a++){let{type:l,next:u}=o.next[a];s.push(l.name),i&&!(l.isText||l.hasRequiredAttrs())&&(i=!1),r.indexOf(u)==-1&&r.push(u)}i&&e.err("Only non-generatable nodes ("+s.join(", ")+") in a required position (see https://prosemirror.net/docs/guide/#generatable)")}}function IT(t){let e=Object.create(null);for(let n in t){let r=t[n];if(!r.hasDefault)return null;e[n]=r.default}return e}function DT(t,e){let n=Object.create(null);for(let r in t){let o=e&&e[r];if(o===void 0){let i=t[r];if(i.hasDefault)o=i.default;else throw new RangeError("No value supplied for attribute "+r)}n[r]=o}return n}function PT(t,e,n,r){for(let o in e)if(!(o in t))throw new RangeError(`Unsupported attribute ${o} for ${n} of type ${o}`);for(let o in t){let i=t[o];i.validate&&i.validate(e[o])}}function NT(t,e){let n=Object.create(null);if(e)for(let r in e)n[r]=new bq(t,r,e[r]);return n}let LT=class MF{constructor(e,n,r){this.name=e,this.schema=n,this.spec=r,this.markSet=null,this.groups=r.group?r.group.split(" "):[],this.attrs=NT(e,r.attrs),this.defaultAttrs=IT(this.attrs),this.contentMatch=null,this.inlineContent=null,this.isBlock=!(r.inline||e=="text"),this.isText=e=="text"}get isInline(){return!this.isBlock}get isTextblock(){return this.isBlock&&this.inlineContent}get isLeaf(){return this.contentMatch==Ts.empty}get isAtom(){return this.isLeaf||!!this.spec.atom}isInGroup(e){return this.groups.indexOf(e)>-1}get whitespace(){return this.spec.whitespace||(this.spec.code?"pre":"normal")}hasRequiredAttrs(){for(let e in this.attrs)if(this.attrs[e].isRequired)return!0;return!1}compatibleContent(e){return this==e||this.contentMatch.compatible(e.contentMatch)}computeAttrs(e){return!e&&this.defaultAttrs?this.defaultAttrs:DT(this.attrs,e)}create(e=null,n,r){if(this.isText)throw new Error("NodeType.create can't construct text nodes");return new Ei(this,this.computeAttrs(e),Te.from(n),Ft.setFrom(r))}createChecked(e=null,n,r){return n=Te.from(n),this.checkContent(n),new Ei(this,this.computeAttrs(e),n,Ft.setFrom(r))}createAndFill(e=null,n,r){if(e=this.computeAttrs(e),n=Te.from(n),n.size){let s=this.contentMatch.fillBefore(n);if(!s)return null;n=s.append(n)}let o=this.contentMatch.matchFragment(n),i=o&&o.fillBefore(Te.empty,!0);return i?new Ei(this,e,n.append(i),Ft.setFrom(r)):null}validContent(e){let n=this.contentMatch.matchFragment(e);if(!n||!n.validEnd)return!1;for(let r=0;r<e.childCount;r++)if(!this.allowsMarks(e.child(r).marks))return!1;return!0}checkContent(e){if(!this.validContent(e))throw new RangeError(`Invalid content for node ${this.name}: ${e.toString().slice(0,50)}`)}checkAttrs(e){PT(this.attrs,e,"node",this.name)}allowsMarkType(e){return this.markSet==null||this.markSet.indexOf(e)>-1}allowsMarks(e){if(this.markSet==null)return!0;for(let n=0;n<e.length;n++)if(!this.allowsMarkType(e[n].type))return!1;return!0}allowedMarks(e){if(this.markSet==null)return e;let n;for(let r=0;r<e.length;r++)this.allowsMarkType(e[r].type)?n&&n.push(e[r]):n||(n=e.slice(0,r));return n?n.length?n:Ft.none:e}static compile(e,n){let r=Object.create(null);e.forEach((i,s)=>r[i]=new MF(i,n,s));let o=n.spec.topNode||"doc";if(!r[o])throw new RangeError("Schema is missing its top node type ('"+o+"')");if(!r.text)throw new RangeError("Every schema needs a 'text' type");for(let i in r.text.attrs)throw new RangeError("The text node type should not have attributes");return r}};function yq(t,e,n){let r=n.split("|");return o=>{let i=o===null?"null":typeof o;if(r.indexOf(i)<0)throw new RangeError(`Expected value of type ${r} for attribute ${e} on type ${t}, got ${i}`)}}class bq{constructor(e,n,r){this.hasDefault=Object.prototype.hasOwnProperty.call(r,"default"),this.default=r.default,this.validate=typeof r.validate=="string"?yq(e,n,r.validate):r.validate}get isRequired(){return!this.hasDefault}}class jd{constructor(e,n,r,o){this.name=e,this.rank=n,this.schema=r,this.spec=o,this.attrs=NT(e,o.attrs),this.excluded=null;let i=IT(this.attrs);this.instance=i?new Ft(this,i):null}create(e=null){return!e&&this.instance?this.instance:new Ft(this,DT(this.attrs,e))}static compile(e,n){let r=Object.create(null),o=0;return e.forEach((i,s)=>r[i]=new jd(i,o++,n,s)),r}removeFromSet(e){for(var n=0;n<e.length;n++)e[n].type==this&&(e=e.slice(0,n).concat(e.slice(n+1)),n--);return e}isInSet(e){for(let n=0;n<e.length;n++)if(e[n].type==this)return e[n]}checkAttrs(e){PT(this.attrs,e,"mark",this.name)}excludes(e){return this.excluded.indexOf(e)>-1}}let FT=class{constructor(e){this.linebreakReplacement=null,this.cached=Object.create(null);let n=this.spec={};for(let o in e)n[o]=e[o];n.nodes=Pn.from(e.nodes),n.marks=Pn.from(e.marks||{}),this.nodes=LT.compile(this.spec.nodes,this),this.marks=jd.compile(this.spec.marks,this);let r=Object.create(null);for(let o in this.nodes){if(o in this.marks)throw new RangeError(o+" can not be both a node and a mark");let i=this.nodes[o],s=i.spec.content||"",a=i.spec.marks;if(i.contentMatch=r[s]||(r[s]=Ts.parse(s,this.nodes)),i.inlineContent=i.contentMatch.inlineContent,i.spec.linebreakReplacement){if(this.linebreakReplacement)throw new RangeError("Multiple linebreak nodes defined");if(!i.isInline||!i.isLeaf)throw new RangeError("Linebreak replacement nodes must be inline leaf nodes");this.linebreakReplacement=i}i.markSet=a=="_"?null:a?$T(this,a.split(" ")):a==""||!i.inlineContent?[]:null}for(let o in this.marks){let i=this.marks[o],s=i.spec.excludes;i.excluded=s==null?[i]:s==""?[]:$T(this,s.split(" "))}this.nodeFromJSON=this.nodeFromJSON.bind(this),this.markFromJSON=this.markFromJSON.bind(this),this.topNodeType=this.nodes[this.spec.topNode||"doc"],this.cached.wrappings=Object.create(null)}node(e,n=null,r,o){if(typeof e=="string")e=this.nodeType(e);else if(e instanceof LT){if(e.schema!=this)throw new RangeError("Node type from different schema used ("+e.name+")")}else throw new RangeError("Invalid node type: "+e);return e.createChecked(n,r,o)}text(e,n){let r=this.nodes.text;return new Hd(r,r.defaultAttrs,e,Ft.setFrom(n))}mark(e,n){return typeof e=="string"&&(e=this.marks[e]),e.create(n)}nodeFromJSON(e){return Ei.fromJSON(this,e)}markFromJSON(e){return Ft.fromJSON(this,e)}nodeType(e){let n=this.nodes[e];if(!n)throw new RangeError("Unknown node type: "+e);return n}};function $T(t,e){let n=[];for(let r=0;r<e.length;r++){let o=e[r],i=t.marks[o],s=i;if(i)n.push(i);else for(let a in t.marks){let l=t.marks[a];(o=="_"||l.spec.group&&l.spec.group.split(" ").indexOf(o)>-1)&&n.push(s=l)}if(!s)throw new SyntaxError("Unknown mark type: '"+e[r]+"'")}return n}function vq(t){return t.tag!=null}function xq(t){return t.style!=null}class Mi{constructor(e,n){this.schema=e,this.rules=n,this.tags=[],this.styles=[];let r=this.matchedStyles=[];n.forEach(o=>{if(vq(o))this.tags.push(o);else if(xq(o)){let i=/[^=]*/.exec(o.style)[0];r.indexOf(i)<0&&r.push(i),this.styles.push(o)}}),this.normalizeLists=!this.tags.some(o=>{if(!/^(ul|ol)\b/.test(o.tag)||!o.node)return!1;let i=e.nodes[o.node];return i.contentMatch.matchType(i)})}parse(e,n={}){let r=new VT(this,n,!1);return r.addAll(e,Ft.none,n.from,n.to),r.finish()}parseSlice(e,n={}){let r=new VT(this,n,!0);return r.addAll(e,Ft.none,n.from,n.to),Ie.maxOpen(r.finish())}matchTag(e,n,r){for(let o=r?this.tags.indexOf(r)+1:0;o<this.tags.length;o++){let i=this.tags[o];if(wq(e,i.tag)&&(i.namespace===void 0||e.namespaceURI==i.namespace)&&(!i.context||n.matchesContext(i.context))){if(i.getAttrs){let s=i.getAttrs(e);if(s===!1)continue;i.attrs=s||void 0}return i}}}matchStyle(e,n,r,o){for(let i=o?this.styles.indexOf(o)+1:0;i<this.styles.length;i++){let s=this.styles[i],a=s.style;if(!(a.indexOf(e)!=0||s.context&&!r.matchesContext(s.context)||a.length>e.length&&(a.charCodeAt(e.length)!=61||a.slice(e.length+1)!=n))){if(s.getAttrs){let l=s.getAttrs(n);if(l===!1)continue;s.attrs=l||void 0}return s}}}static schemaRules(e){let n=[];function r(o){let i=o.priority==null?50:o.priority,s=0;for(;s<n.length;s++){let a=n[s];if((a.priority==null?50:a.priority)<i)break}n.splice(s,0,o)}for(let o in e.marks){let i=e.marks[o].spec.parseDOM;i&&i.forEach(s=>{r(s=HT(s)),s.mark||s.ignore||s.clearMark||(s.mark=o)})}for(let o in e.nodes){let i=e.nodes[o].spec.parseDOM;i&&i.forEach(s=>{r(s=HT(s)),s.node||s.ignore||s.mark||(s.node=o)})}return n}static fromSchema(e){return e.cached.domParser||(e.cached.domParser=new Mi(e,Mi.schemaRules(e)))}}const BT={address:!0,article:!0,aside:!0,blockquote:!0,canvas:!0,dd:!0,div:!0,dl:!0,fieldset:!0,figcaption:!0,figure:!0,footer:!0,form:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,header:!0,hgroup:!0,hr:!0,li:!0,noscript:!0,ol:!0,output:!0,p:!0,pre:!0,section:!0,table:!0,tfoot:!0,ul:!0},Sq={head:!0,noscript:!0,object:!0,script:!0,style:!0,title:!0},RT={ol:!0,ul:!0},gc=1,sm=2,mc=4;function zT(t,e,n){return e!=null?(e?gc:0)|(e==="full"?sm:0):t&&t.whitespace=="pre"?gc|sm:n&~mc}class Wd{constructor(e,n,r,o,i,s){this.type=e,this.attrs=n,this.marks=r,this.solid=o,this.options=s,this.content=[],this.activeMarks=Ft.none,this.match=i||(s&mc?null:e.contentMatch)}findWrapping(e){if(!this.match){if(!this.type)return[];let n=this.type.contentMatch.fillBefore(Te.from(e));if(n)this.match=this.type.contentMatch.matchFragment(n);else{let r=this.type.contentMatch,o;return(o=r.findWrapping(e.type))?(this.match=r,o):null}}return this.match.findWrapping(e.type)}finish(e){if(!(this.options&gc)){let r=this.content[this.content.length-1],o;if(r&&r.isText&&(o=/[ \t\r\n\u000c]+$/.exec(r.text))){let i=r;r.text.length==o[0].length?this.content.pop():this.content[this.content.length-1]=i.withText(i.text.slice(0,i.text.length-o[0].length))}}let n=Te.from(this.content);return!e&&this.match&&(n=n.append(this.match.fillBefore(Te.empty,!0))),this.type?this.type.create(this.attrs,n,this.marks):n}inlineContext(e){return this.type?this.type.inlineContent:this.content.length?this.content[0].isInline:e.parentNode&&!BT.hasOwnProperty(e.parentNode.nodeName.toLowerCase())}}class VT{constructor(e,n,r){this.parser=e,this.options=n,this.isOpen=r,this.open=0,this.localPreserveWS=!1;let o=n.topNode,i,s=zT(null,n.preserveWhitespace,0)|(r?mc:0);o?i=new Wd(o.type,o.attrs,Ft.none,!0,n.topMatch||o.type.contentMatch,s):r?i=new Wd(null,null,Ft.none,!0,null,s):i=new Wd(e.schema.topNodeType,null,Ft.none,!0,null,s),this.nodes=[i],this.find=n.findPositions,this.needsBlock=!1}get top(){return this.nodes[this.open]}addDOM(e,n){e.nodeType==3?this.addTextNode(e,n):e.nodeType==1&&this.addElement(e,n)}addTextNode(e,n){let r=e.nodeValue,o=this.top,i=o.options&sm?"full":this.localPreserveWS||(o.options&gc)>0;if(i==="full"||o.inlineContext(e)||/[^ \t\r\n\u000c]/.test(r)){if(i)i!=="full"?r=r.replace(/\r?\n|\r/g," "):r=r.replace(/\r\n?/g,`
|
|
236
236
|
`);else if(r=r.replace(/[ \t\r\n\u000c]+/g," "),/^[ \t\r\n\u000c]/.test(r)&&this.open==this.nodes.length-1){let s=o.content[o.content.length-1],a=e.previousSibling;(!s||a&&a.nodeName=="BR"||s.isText&&/[ \t\r\n\u000c]$/.test(s.text))&&(r=r.slice(1))}r&&this.insertNode(this.parser.schema.text(r),n),this.findInText(e)}else this.findInside(e)}addElement(e,n,r){let o=this.localPreserveWS,i=this.top;(e.tagName=="PRE"||/pre/.test(e.style&&e.style.whiteSpace))&&(this.localPreserveWS=!0);let s=e.nodeName.toLowerCase(),a;RT.hasOwnProperty(s)&&this.parser.normalizeLists&&Cq(e);let l=this.options.ruleFromNode&&this.options.ruleFromNode(e)||(a=this.parser.matchTag(e,this,r));e:if(l?l.ignore:Sq.hasOwnProperty(s))this.findInside(e),this.ignoreFallback(e,n);else if(!l||l.skip||l.closeParent){l&&l.closeParent?this.open=Math.max(0,this.open-1):l&&l.skip.nodeType&&(e=l.skip);let u,f=this.needsBlock;if(BT.hasOwnProperty(s))i.content.length&&i.content[0].isInline&&this.open&&(this.open--,i=this.top),u=!0,i.type||(this.needsBlock=!0);else if(!e.firstChild){this.leafFallback(e,n);break e}let p=l&&l.skip?n:this.readStyles(e,n);p&&this.addAll(e,p),u&&this.sync(i),this.needsBlock=f}else{let u=this.readStyles(e,n);u&&this.addElementByRule(e,l,u,l.consuming===!1?a:void 0)}this.localPreserveWS=o}leafFallback(e,n){e.nodeName=="BR"&&this.top.type&&this.top.type.inlineContent&&this.addTextNode(e.ownerDocument.createTextNode(`
|
|
237
237
|
`),n)}ignoreFallback(e,n){e.nodeName=="BR"&&(!this.top.type||!this.top.type.inlineContent)&&this.findPlace(this.parser.schema.text("-"),n)}readStyles(e,n){let r=e.style;if(r&&r.length)for(let o=0;o<this.parser.matchedStyles.length;o++){let i=this.parser.matchedStyles[o],s=r.getPropertyValue(i);if(s)for(let a=void 0;;){let l=this.parser.matchStyle(i,s,this,a);if(!l)break;if(l.ignore)return null;if(l.clearMark?n=n.filter(u=>!l.clearMark(u)):n=n.concat(this.parser.schema.marks[l.mark].create(l.attrs)),l.consuming===!1)a=l;else break}}return n}addElementByRule(e,n,r,o){let i,s;if(n.node)if(s=this.parser.schema.nodes[n.node],s.isLeaf)this.insertNode(s.create(n.attrs),r)||this.leafFallback(e,r);else{let l=this.enter(s,n.attrs||null,r,n.preserveWhitespace);l&&(i=!0,r=l)}else{let l=this.parser.schema.marks[n.mark];r=r.concat(l.create(n.attrs))}let a=this.top;if(s&&s.isLeaf)this.findInside(e);else if(o)this.addElement(e,r,o);else if(n.getContent)this.findInside(e),n.getContent(e,this.parser.schema).forEach(l=>this.insertNode(l,r));else{let l=e;typeof n.contentElement=="string"?l=e.querySelector(n.contentElement):typeof n.contentElement=="function"?l=n.contentElement(e):n.contentElement&&(l=n.contentElement),this.findAround(e,l,!0),this.addAll(l,r),this.findAround(e,l,!1)}i&&this.sync(a)&&this.open--}addAll(e,n,r,o){let i=r||0;for(let s=r?e.childNodes[r]:e.firstChild,a=o==null?null:e.childNodes[o];s!=a;s=s.nextSibling,++i)this.findAtPoint(e,i),this.addDOM(s,n);this.findAtPoint(e,i)}findPlace(e,n){let r,o;for(let i=this.open;i>=0;i--){let s=this.nodes[i],a=s.findWrapping(e);if(a&&(!r||r.length>a.length)&&(r=a,o=s,!a.length)||s.solid)break}if(!r)return null;this.sync(o);for(let i=0;i<r.length;i++)n=this.enterInner(r[i],null,n,!1);return n}insertNode(e,n){if(e.isInline&&this.needsBlock&&!this.top.type){let o=this.textblockFromContext();o&&(n=this.enterInner(o,null,n))}let r=this.findPlace(e,n);if(r){this.closeExtra();let o=this.top;o.match&&(o.match=o.match.matchType(e.type));let i=Ft.none;for(let s of r.concat(e.marks))(o.type?o.type.allowsMarkType(s.type):jT(s.type,e.type))&&(i=s.addToSet(i));return o.content.push(e.mark(i)),!0}return!1}enter(e,n,r,o){let i=this.findPlace(e.create(n),r);return i&&(i=this.enterInner(e,n,r,!0,o)),i}enterInner(e,n,r,o=!1,i){this.closeExtra();let s=this.top;s.match=s.match&&s.match.matchType(e);let a=zT(e,i,s.options);s.options&mc&&s.content.length==0&&(a|=mc);let l=Ft.none;return r=r.filter(u=>(s.type?s.type.allowsMarkType(u.type):jT(u.type,e))?(l=u.addToSet(l),!1):!0),this.nodes.push(new Wd(e,n,l,o,null,a)),this.open++,r}closeExtra(e=!1){let n=this.nodes.length-1;if(n>this.open){for(;n>this.open;n--)this.nodes[n-1].content.push(this.nodes[n].finish(e));this.nodes.length=this.open+1}}finish(){return this.open=0,this.closeExtra(this.isOpen),this.nodes[0].finish(!!(this.isOpen||this.options.topOpen))}sync(e){for(let n=this.open;n>=0;n--){if(this.nodes[n]==e)return this.open=n,!0;this.localPreserveWS&&(this.nodes[n].options|=gc)}return!1}get currentPos(){this.closeExtra();let e=0;for(let n=this.open;n>=0;n--){let r=this.nodes[n].content;for(let o=r.length-1;o>=0;o--)e+=r[o].nodeSize;n&&e++}return e}findAtPoint(e,n){if(this.find)for(let r=0;r<this.find.length;r++)this.find[r].node==e&&this.find[r].offset==n&&(this.find[r].pos=this.currentPos)}findInside(e){if(this.find)for(let n=0;n<this.find.length;n++)this.find[n].pos==null&&e.nodeType==1&&e.contains(this.find[n].node)&&(this.find[n].pos=this.currentPos)}findAround(e,n,r){if(e!=n&&this.find)for(let o=0;o<this.find.length;o++)this.find[o].pos==null&&e.nodeType==1&&e.contains(this.find[o].node)&&n.compareDocumentPosition(this.find[o].node)&(r?2:4)&&(this.find[o].pos=this.currentPos)}findInText(e){if(this.find)for(let n=0;n<this.find.length;n++)this.find[n].node==e&&(this.find[n].pos=this.currentPos-(e.nodeValue.length-this.find[n].offset))}matchesContext(e){if(e.indexOf("|")>-1)return e.split(/\s*\|\s*/).some(this.matchesContext,this);let n=e.split("/"),r=this.options.context,o=!this.isOpen&&(!r||r.parent.type==this.nodes[0].type),i=-(r?r.depth+1:0)+(o?0:1),s=(a,l)=>{for(;a>=0;a--){let u=n[a];if(u==""){if(a==n.length-1||a==0)continue;for(;l>=i;l--)if(s(a-1,l))return!0;return!1}else{let f=l>0||l==0&&o?this.nodes[l].type:r&&l>=i?r.node(l-i).type:null;if(!f||f.name!=u&&!f.isInGroup(u))return!1;l--}}return!0};return s(n.length-1,this.open)}textblockFromContext(){let e=this.options.context;if(e)for(let n=e.depth;n>=0;n--){let r=e.node(n).contentMatchAt(e.indexAfter(n)).defaultType;if(r&&r.isTextblock&&r.defaultAttrs)return r}for(let n in this.parser.schema.nodes){let r=this.parser.schema.nodes[n];if(r.isTextblock&&r.defaultAttrs)return r}}}function Cq(t){for(let e=t.firstChild,n=null;e;e=e.nextSibling){let r=e.nodeType==1?e.nodeName.toLowerCase():null;r&&RT.hasOwnProperty(r)&&n?(n.appendChild(e),e=n):r=="li"?n=e:r&&(n=null)}}function wq(t,e){return(t.matches||t.msMatchesSelector||t.webkitMatchesSelector||t.mozMatchesSelector).call(t,e)}function HT(t){let e={};for(let n in t)e[n]=t[n];return e}function jT(t,e){let n=e.schema.nodes;for(let r in n){let o=n[r];if(!o.allowsMarkType(t))continue;let i=[],s=a=>{i.push(a);for(let l=0;l<a.edgeCount;l++){let{type:u,next:f}=a.edge(l);if(u==e||i.indexOf(f)<0&&s(f))return!0}};if(s(o.contentMatch))return!0}}class ks{constructor(e,n){this.nodes=e,this.marks=n}serializeFragment(e,n={},r){r||(r=am(n).createDocumentFragment());let o=r,i=[];return e.forEach(s=>{if(i.length||s.marks.length){let a=0,l=0;for(;a<i.length&&l<s.marks.length;){let u=s.marks[l];if(!this.marks[u.type.name]){l++;continue}if(!u.eq(i[a][0])||u.type.spec.spanning===!1)break;a++,l++}for(;a<i.length;)o=i.pop()[1];for(;l<s.marks.length;){let u=s.marks[l++],f=this.serializeMark(u,s.isInline,n);f&&(i.push([u,o]),o.appendChild(f.dom),o=f.contentDOM||f.dom)}}o.appendChild(this.serializeNodeInner(s,n))}),r}serializeNodeInner(e,n){let{dom:r,contentDOM:o}=qd(am(n),this.nodes[e.type.name](e),null,e.attrs);if(o){if(e.isLeaf)throw new RangeError("Content hole not allowed in a leaf node spec");this.serializeFragment(e.content,n,o)}return r}serializeNode(e,n={}){let r=this.serializeNodeInner(e,n);for(let o=e.marks.length-1;o>=0;o--){let i=this.serializeMark(e.marks[o],e.isInline,n);i&&((i.contentDOM||i.dom).appendChild(r),r=i.dom)}return r}serializeMark(e,n,r={}){let o=this.marks[e.type.name];return o&&qd(am(r),o(e,n),null,e.attrs)}static renderSpec(e,n,r=null,o){return qd(e,n,r,o)}static fromSchema(e){return e.cached.domSerializer||(e.cached.domSerializer=new ks(this.nodesFromSchema(e),this.marksFromSchema(e)))}static nodesFromSchema(e){let n=WT(e.nodes);return n.text||(n.text=r=>r.text),n}static marksFromSchema(e){return WT(e.marks)}}function WT(t){let e={};for(let n in t){let r=t[n].spec.toDOM;r&&(e[n]=r)}return e}function am(t){return t.document||window.document}const qT=new WeakMap;function _q(t){let e=qT.get(t);return e===void 0&&qT.set(t,e=Tq(t)),e}function Tq(t){let e=null;function n(r){if(r&&typeof r=="object")if(Array.isArray(r))if(typeof r[0]=="string")e||(e=[]),e.push(r);else for(let o=0;o<r.length;o++)n(r[o]);else for(let o in r)n(r[o])}return n(t),e}function qd(t,e,n,r){if(typeof e=="string")return{dom:t.createTextNode(e)};if(e.nodeType!=null)return{dom:e};if(e.dom&&e.dom.nodeType!=null)return e;let o=e[0],i;if(typeof o!="string")throw new RangeError("Invalid array passed to renderSpec");if(r&&(i=_q(r))&&i.indexOf(e)>-1)throw new RangeError("Using an array from an attribute object as a DOM spec. This may be an attempted cross site scripting attack.");let s=o.indexOf(" ");s>0&&(n=o.slice(0,s),o=o.slice(s+1));let a,l=n?t.createElementNS(n,o):t.createElement(o),u=e[1],f=1;if(u&&typeof u=="object"&&u.nodeType==null&&!Array.isArray(u)){f=2;for(let p in u)if(u[p]!=null){let g=p.indexOf(" ");g>0?l.setAttributeNS(p.slice(0,g),p.slice(g+1),u[p]):l.setAttribute(p,u[p])}}for(let p=f;p<e.length;p++){let g=e[p];if(g===0){if(p<e.length-1||p>f)throw new RangeError("Content hole must be the only child of its parent node");return{dom:l,contentDOM:l}}else{let{dom:m,contentDOM:y}=qd(t,g,n,r);if(l.appendChild(m),y){if(a)throw new RangeError("Multiple content holes");a=y}}}return{dom:l,contentDOM:a}}const UT=65535,KT=Math.pow(2,16);function kq(t,e){return t+e*KT}function YT(t){return t&UT}function Eq(t){return(t-(t&UT))/KT}const GT=1,JT=2,Ud=4,ZT=8;class lm{constructor(e,n,r){this.pos=e,this.delInfo=n,this.recover=r}get deleted(){return(this.delInfo&ZT)>0}get deletedBefore(){return(this.delInfo&(GT|Ud))>0}get deletedAfter(){return(this.delInfo&(JT|Ud))>0}get deletedAcross(){return(this.delInfo&Ud)>0}}class Cr{constructor(e,n=!1){if(this.ranges=e,this.inverted=n,!e.length&&Cr.empty)return Cr.empty}recover(e){let n=0,r=YT(e);if(!this.inverted)for(let o=0;o<r;o++)n+=this.ranges[o*3+2]-this.ranges[o*3+1];return this.ranges[r*3]+n+Eq(e)}mapResult(e,n=1){return this._map(e,n,!1)}map(e,n=1){return this._map(e,n,!0)}_map(e,n,r){let o=0,i=this.inverted?2:1,s=this.inverted?1:2;for(let a=0;a<this.ranges.length;a+=3){let l=this.ranges[a]-(this.inverted?o:0);if(l>e)break;let u=this.ranges[a+i],f=this.ranges[a+s],p=l+u;if(e<=p){let g=u?e==l?-1:e==p?1:n:n,m=l+o+(g<0?0:f);if(r)return m;let y=e==(n<0?l:p)?null:kq(a/3,e-l),b=e==l?JT:e==p?GT:Ud;return(n<0?e!=l:e!=p)&&(b|=ZT),new lm(m,b,y)}o+=f-u}return r?e+o:new lm(e+o,0,null)}touches(e,n){let r=0,o=YT(n),i=this.inverted?2:1,s=this.inverted?1:2;for(let a=0;a<this.ranges.length;a+=3){let l=this.ranges[a]-(this.inverted?r:0);if(l>e)break;let u=this.ranges[a+i],f=l+u;if(e<=f&&a==o*3)return!0;r+=this.ranges[a+s]-u}return!1}forEach(e){let n=this.inverted?2:1,r=this.inverted?1:2;for(let o=0,i=0;o<this.ranges.length;o+=3){let s=this.ranges[o],a=s-(this.inverted?i:0),l=s+(this.inverted?0:i),u=this.ranges[o+n],f=this.ranges[o+r];e(a,a+u,l,l+f),i+=f-u}}invert(){return new Cr(this.ranges,!this.inverted)}toString(){return(this.inverted?"-":"")+JSON.stringify(this.ranges)}static offset(e){return e==0?Cr.empty:new Cr(e<0?[0,-e,0]:[0,0,e])}}Cr.empty=new Cr([]);class yc{constructor(e,n,r=0,o=e?e.length:0){this.mirror=n,this.from=r,this.to=o,this._maps=e||[],this.ownData=!(e||n)}get maps(){return this._maps}slice(e=0,n=this.maps.length){return new yc(this._maps,this.mirror,e,n)}appendMap(e,n){this.ownData||(this._maps=this._maps.slice(),this.mirror=this.mirror&&this.mirror.slice(),this.ownData=!0),this.to=this._maps.push(e),n!=null&&this.setMirror(this._maps.length-1,n)}appendMapping(e){for(let n=0,r=this._maps.length;n<e._maps.length;n++){let o=e.getMirror(n);this.appendMap(e._maps[n],o!=null&&o<n?r+o:void 0)}}getMirror(e){if(this.mirror){for(let n=0;n<this.mirror.length;n++)if(this.mirror[n]==e)return this.mirror[n+(n%2?-1:1)]}}setMirror(e,n){this.mirror||(this.mirror=[]),this.mirror.push(e,n)}appendMappingInverted(e){for(let n=e.maps.length-1,r=this._maps.length+e._maps.length;n>=0;n--){let o=e.getMirror(n);this.appendMap(e._maps[n].invert(),o!=null&&o>n?r-o-1:void 0)}}invert(){let e=new yc;return e.appendMappingInverted(this),e}map(e,n=1){if(this.mirror)return this._map(e,n,!0);for(let r=this.from;r<this.to;r++)e=this._maps[r].map(e,n);return e}mapResult(e,n=1){return this._map(e,n,!1)}_map(e,n,r){let o=0;for(let i=this.from;i<this.to;i++){let s=this._maps[i],a=s.mapResult(e,n);if(a.recover!=null){let l=this.getMirror(i);if(l!=null&&l>i&&l<this.to){i=l,e=this._maps[l].recover(a.recover);continue}}o|=a.delInfo,e=a.pos}return r?e:new lm(e,o,null)}}const cm=Object.create(null);class jn{getMap(){return Cr.empty}merge(e){return null}static fromJSON(e,n){if(!n||!n.stepType)throw new RangeError("Invalid input for Step.fromJSON");let r=cm[n.stepType];if(!r)throw new RangeError(`No step type ${n.stepType} defined`);return r.fromJSON(e,n)}static jsonID(e,n){if(e in cm)throw new RangeError("Duplicate use of step JSON ID "+e);return cm[e]=n,n.prototype.jsonID=e,n}}class yn{constructor(e,n){this.doc=e,this.failed=n}static ok(e){return new yn(e,null)}static fail(e){return new yn(null,e)}static fromReplace(e,n,r,o){try{return yn.ok(e.replace(n,r,o))}catch(i){if(i instanceof Rd)return yn.fail(i.message);throw i}}}function um(t,e,n){let r=[];for(let o=0;o<t.childCount;o++){let i=t.child(o);i.content.size&&(i=i.copy(um(i.content,e,i))),i.isInline&&(i=e(i,n,o)),r.push(i)}return Te.fromArray(r)}class Oi extends jn{constructor(e,n,r){super(),this.from=e,this.to=n,this.mark=r}apply(e){let n=e.slice(this.from,this.to),r=e.resolve(this.from),o=r.node(r.sharedDepth(this.to)),i=new Ie(um(n.content,(s,a)=>!s.isAtom||!a.type.allowsMarkType(this.mark.type)?s:s.mark(this.mark.addToSet(s.marks)),o),n.openStart,n.openEnd);return yn.fromReplace(e,this.from,this.to,i)}invert(){return new ko(this.from,this.to,this.mark)}map(e){let n=e.mapResult(this.from,1),r=e.mapResult(this.to,-1);return n.deleted&&r.deleted||n.pos>=r.pos?null:new Oi(n.pos,r.pos,this.mark)}merge(e){return e instanceof Oi&&e.mark.eq(this.mark)&&this.from<=e.to&&this.to>=e.from?new Oi(Math.min(this.from,e.from),Math.max(this.to,e.to),this.mark):null}toJSON(){return{stepType:"addMark",mark:this.mark.toJSON(),from:this.from,to:this.to}}static fromJSON(e,n){if(typeof n.from!="number"||typeof n.to!="number")throw new RangeError("Invalid input for AddMarkStep.fromJSON");return new Oi(n.from,n.to,e.markFromJSON(n.mark))}}jn.jsonID("addMark",Oi);class ko extends jn{constructor(e,n,r){super(),this.from=e,this.to=n,this.mark=r}apply(e){let n=e.slice(this.from,this.to),r=new Ie(um(n.content,o=>o.mark(this.mark.removeFromSet(o.marks)),e),n.openStart,n.openEnd);return yn.fromReplace(e,this.from,this.to,r)}invert(){return new Oi(this.from,this.to,this.mark)}map(e){let n=e.mapResult(this.from,1),r=e.mapResult(this.to,-1);return n.deleted&&r.deleted||n.pos>=r.pos?null:new ko(n.pos,r.pos,this.mark)}merge(e){return e instanceof ko&&e.mark.eq(this.mark)&&this.from<=e.to&&this.to>=e.from?new ko(Math.min(this.from,e.from),Math.max(this.to,e.to),this.mark):null}toJSON(){return{stepType:"removeMark",mark:this.mark.toJSON(),from:this.from,to:this.to}}static fromJSON(e,n){if(typeof n.from!="number"||typeof n.to!="number")throw new RangeError("Invalid input for RemoveMarkStep.fromJSON");return new ko(n.from,n.to,e.markFromJSON(n.mark))}}jn.jsonID("removeMark",ko);class Ai extends jn{constructor(e,n){super(),this.pos=e,this.mark=n}apply(e){let n=e.nodeAt(this.pos);if(!n)return yn.fail("No node at mark step's position");let r=n.type.create(n.attrs,null,this.mark.addToSet(n.marks));return yn.fromReplace(e,this.pos,this.pos+1,new Ie(Te.from(r),0,n.isLeaf?0:1))}invert(e){let n=e.nodeAt(this.pos);if(n){let r=this.mark.addToSet(n.marks);if(r.length==n.marks.length){for(let o=0;o<n.marks.length;o++)if(!n.marks[o].isInSet(r))return new Ai(this.pos,n.marks[o]);return new Ai(this.pos,this.mark)}}return new Oa(this.pos,this.mark)}map(e){let n=e.mapResult(this.pos,1);return n.deletedAfter?null:new Ai(n.pos,this.mark)}toJSON(){return{stepType:"addNodeMark",pos:this.pos,mark:this.mark.toJSON()}}static fromJSON(e,n){if(typeof n.pos!="number")throw new RangeError("Invalid input for AddNodeMarkStep.fromJSON");return new Ai(n.pos,e.markFromJSON(n.mark))}}jn.jsonID("addNodeMark",Ai);class Oa extends jn{constructor(e,n){super(),this.pos=e,this.mark=n}apply(e){let n=e.nodeAt(this.pos);if(!n)return yn.fail("No node at mark step's position");let r=n.type.create(n.attrs,null,this.mark.removeFromSet(n.marks));return yn.fromReplace(e,this.pos,this.pos+1,new Ie(Te.from(r),0,n.isLeaf?0:1))}invert(e){let n=e.nodeAt(this.pos);return!n||!this.mark.isInSet(n.marks)?this:new Ai(this.pos,this.mark)}map(e){let n=e.mapResult(this.pos,1);return n.deletedAfter?null:new Oa(n.pos,this.mark)}toJSON(){return{stepType:"removeNodeMark",pos:this.pos,mark:this.mark.toJSON()}}static fromJSON(e,n){if(typeof n.pos!="number")throw new RangeError("Invalid input for RemoveNodeMarkStep.fromJSON");return new Oa(n.pos,e.markFromJSON(n.mark))}}jn.jsonID("removeNodeMark",Oa);class kn extends jn{constructor(e,n,r,o=!1){super(),this.from=e,this.to=n,this.slice=r,this.structure=o}apply(e){return this.structure&&dm(e,this.from,this.to)?yn.fail("Structure replace would overwrite content"):yn.fromReplace(e,this.from,this.to,this.slice)}getMap(){return new Cr([this.from,this.to-this.from,this.slice.size])}invert(e){return new kn(this.from,this.from+this.slice.size,e.slice(this.from,this.to))}map(e){let n=e.mapResult(this.from,1),r=e.mapResult(this.to,-1);return n.deletedAcross&&r.deletedAcross?null:new kn(n.pos,Math.max(n.pos,r.pos),this.slice)}merge(e){if(!(e instanceof kn)||e.structure||this.structure)return null;if(this.from+this.slice.size==e.from&&!this.slice.openEnd&&!e.slice.openStart){let n=this.slice.size+e.slice.size==0?Ie.empty:new Ie(this.slice.content.append(e.slice.content),this.slice.openStart,e.slice.openEnd);return new kn(this.from,this.to+(e.to-e.from),n,this.structure)}else if(e.to==this.from&&!this.slice.openStart&&!e.slice.openEnd){let n=this.slice.size+e.slice.size==0?Ie.empty:new Ie(e.slice.content.append(this.slice.content),e.slice.openStart,this.slice.openEnd);return new kn(e.from,this.to,n,this.structure)}else return null}toJSON(){let e={stepType:"replace",from:this.from,to:this.to};return this.slice.size&&(e.slice=this.slice.toJSON()),this.structure&&(e.structure=!0),e}static fromJSON(e,n){if(typeof n.from!="number"||typeof n.to!="number")throw new RangeError("Invalid input for ReplaceStep.fromJSON");return new kn(n.from,n.to,Ie.fromJSON(e,n.slice),!!n.structure)}}jn.jsonID("replace",kn);class En extends jn{constructor(e,n,r,o,i,s,a=!1){super(),this.from=e,this.to=n,this.gapFrom=r,this.gapTo=o,this.slice=i,this.insert=s,this.structure=a}apply(e){if(this.structure&&(dm(e,this.from,this.gapFrom)||dm(e,this.gapTo,this.to)))return yn.fail("Structure gap-replace would overwrite content");let n=e.slice(this.gapFrom,this.gapTo);if(n.openStart||n.openEnd)return yn.fail("Gap is not a flat range");let r=this.slice.insertAt(this.insert,n.content);return r?yn.fromReplace(e,this.from,this.to,r):yn.fail("Content does not fit in gap")}getMap(){return new Cr([this.from,this.gapFrom-this.from,this.insert,this.gapTo,this.to-this.gapTo,this.slice.size-this.insert])}invert(e){let n=this.gapTo-this.gapFrom;return new En(this.from,this.from+this.slice.size+n,this.from+this.insert,this.from+this.insert+n,e.slice(this.from,this.to).removeBetween(this.gapFrom-this.from,this.gapTo-this.from),this.gapFrom-this.from,this.structure)}map(e){let n=e.mapResult(this.from,1),r=e.mapResult(this.to,-1),o=this.from==this.gapFrom?n.pos:e.map(this.gapFrom,-1),i=this.to==this.gapTo?r.pos:e.map(this.gapTo,1);return n.deletedAcross&&r.deletedAcross||o<n.pos||i>r.pos?null:new En(n.pos,r.pos,o,i,this.slice,this.insert,this.structure)}toJSON(){let e={stepType:"replaceAround",from:this.from,to:this.to,gapFrom:this.gapFrom,gapTo:this.gapTo,insert:this.insert};return this.slice.size&&(e.slice=this.slice.toJSON()),this.structure&&(e.structure=!0),e}static fromJSON(e,n){if(typeof n.from!="number"||typeof n.to!="number"||typeof n.gapFrom!="number"||typeof n.gapTo!="number"||typeof n.insert!="number")throw new RangeError("Invalid input for ReplaceAroundStep.fromJSON");return new En(n.from,n.to,n.gapFrom,n.gapTo,Ie.fromJSON(e,n.slice),n.insert,!!n.structure)}}jn.jsonID("replaceAround",En);function dm(t,e,n){let r=t.resolve(e),o=n-e,i=r.depth;for(;o>0&&i>0&&r.indexAfter(i)==r.node(i).childCount;)i--,o--;if(o>0){let s=r.node(i).maybeChild(r.indexAfter(i));for(;o>0;){if(!s||s.isLeaf)return!0;s=s.firstChild,o--}}return!1}function Mq(t,e,n,r){let o=[],i=[],s,a;t.doc.nodesBetween(e,n,(l,u,f)=>{if(!l.isInline)return;let p=l.marks;if(!r.isInSet(p)&&f.type.allowsMarkType(r.type)){let g=Math.max(u,e),m=Math.min(u+l.nodeSize,n),y=r.addToSet(p);for(let b=0;b<p.length;b++)p[b].isInSet(y)||(s&&s.to==g&&s.mark.eq(p[b])?s.to=m:o.push(s=new ko(g,m,p[b])));a&&a.to==g?a.to=m:i.push(a=new Oi(g,m,r))}}),o.forEach(l=>t.step(l)),i.forEach(l=>t.step(l))}function Oq(t,e,n,r){let o=[],i=0;t.doc.nodesBetween(e,n,(s,a)=>{if(!s.isInline)return;i++;let l=null;if(r instanceof jd){let u=s.marks,f;for(;f=r.isInSet(u);)(l||(l=[])).push(f),u=f.removeFromSet(u)}else r?r.isInSet(s.marks)&&(l=[r]):l=s.marks;if(l&&l.length){let u=Math.min(a+s.nodeSize,n);for(let f=0;f<l.length;f++){let p=l[f],g;for(let m=0;m<o.length;m++){let y=o[m];y.step==i-1&&p.eq(o[m].style)&&(g=y)}g?(g.to=u,g.step=i):o.push({style:p,from:Math.max(a,e),to:u,step:i})}}}),o.forEach(s=>t.step(new ko(s.from,s.to,s.style)))}function fm(t,e,n,r=n.contentMatch,o=!0){let i=t.doc.nodeAt(e),s=[],a=e+1;for(let l=0;l<i.childCount;l++){let u=i.child(l),f=a+u.nodeSize,p=r.matchType(u.type);if(!p)s.push(new kn(a,f,Ie.empty));else{r=p;for(let g=0;g<u.marks.length;g++)n.allowsMarkType(u.marks[g].type)||t.step(new ko(a,f,u.marks[g]));if(o&&u.isText&&n.whitespace!="pre"){let g,m=/\r?\n|\r/g,y;for(;g=m.exec(u.text);)y||(y=new Ie(Te.from(n.schema.text(" ",n.allowedMarks(u.marks))),0,0)),s.push(new kn(a+g.index,a+g.index+g[0].length,y))}}a=f}if(!r.validEnd){let l=r.fillBefore(Te.empty,!0);t.replace(a,a,new Ie(l,0,0))}for(let l=s.length-1;l>=0;l--)t.step(s[l])}function Aq(t,e,n){return(e==0||t.canReplace(e,t.childCount))&&(n==t.childCount||t.canReplace(0,n))}function Aa(t){let n=t.parent.content.cutByIndex(t.startIndex,t.endIndex);for(let r=t.depth;;--r){let o=t.$from.node(r),i=t.$from.index(r),s=t.$to.indexAfter(r);if(r<t.depth&&o.canReplace(i,s,n))return r;if(r==0||o.type.spec.isolating||!Aq(o,i,s))break}return null}function Iq(t,e,n){let{$from:r,$to:o,depth:i}=e,s=r.before(i+1),a=o.after(i+1),l=s,u=a,f=Te.empty,p=0;for(let y=i,b=!1;y>n;y--)b||r.index(y)>0?(b=!0,f=Te.from(r.node(y).copy(f)),p++):l--;let g=Te.empty,m=0;for(let y=i,b=!1;y>n;y--)b||o.after(y+1)<o.end(y)?(b=!0,g=Te.from(o.node(y).copy(g)),m++):u++;t.step(new En(l,u,s,a,new Ie(f.append(g),p,m),f.size-p,!0))}function pm(t,e,n=null,r=t){let o=Dq(t,e),i=o&&Pq(r,e);return i?o.map(XT).concat({type:e,attrs:n}).concat(i.map(XT)):null}function XT(t){return{type:t,attrs:null}}function Dq(t,e){let{parent:n,startIndex:r,endIndex:o}=t,i=n.contentMatchAt(r).findWrapping(e);if(!i)return null;let s=i.length?i[0]:e;return n.canReplaceWith(r,o,s)?i:null}function Pq(t,e){let{parent:n,startIndex:r,endIndex:o}=t,i=n.child(r),s=e.contentMatch.findWrapping(i.type);if(!s)return null;let l=(s.length?s[s.length-1]:e).contentMatch;for(let u=r;l&&u<o;u++)l=l.matchType(n.child(u).type);return!l||!l.validEnd?null:s}function Nq(t,e,n){let r=Te.empty;for(let s=n.length-1;s>=0;s--){if(r.size){let a=n[s].type.contentMatch.matchFragment(r);if(!a||!a.validEnd)throw new RangeError("Wrapper type given to Transform.wrap does not form valid content of its parent wrapper")}r=Te.from(n[s].type.create(n[s].attrs,r))}let o=e.start,i=e.end;t.step(new En(o,i,o,i,new Ie(r,0,0),n.length,!0))}function Lq(t,e,n,r,o){if(!r.isTextblock)throw new RangeError("Type given to setBlockType should be a textblock");let i=t.steps.length;t.doc.nodesBetween(e,n,(s,a)=>{let l=typeof o=="function"?o(s):o;if(s.isTextblock&&!s.hasMarkup(r,l)&&Fq(t.doc,t.mapping.slice(i).map(a),r)){let u=null;if(r.schema.linebreakReplacement){let m=r.whitespace=="pre",y=!!r.contentMatch.matchType(r.schema.linebreakReplacement);m&&!y?u=!1:!m&&y&&(u=!0)}u===!1&&ek(t,s,a,i),fm(t,t.mapping.slice(i).map(a,1),r,void 0,u===null);let f=t.mapping.slice(i),p=f.map(a,1),g=f.map(a+s.nodeSize,1);return t.step(new En(p,g,p+1,g-1,new Ie(Te.from(r.create(l,null,s.marks)),0,0),1,!0)),u===!0&&QT(t,s,a,i),!1}})}function QT(t,e,n,r){e.forEach((o,i)=>{if(o.isText){let s,a=/\r?\n|\r/g;for(;s=a.exec(o.text);){let l=t.mapping.slice(r).map(n+1+i+s.index);t.replaceWith(l,l+1,e.type.schema.linebreakReplacement.create())}}})}function ek(t,e,n,r){e.forEach((o,i)=>{if(o.type==o.type.schema.linebreakReplacement){let s=t.mapping.slice(r).map(n+1+i);t.replaceWith(s,s+1,e.type.schema.text(`
|
|
@@ -321,10 +321,10 @@ img.ProseMirror-separator {
|
|
|
321
321
|
|
|
322
322
|
`,textSerializers:r={}}=e||{};return JE(this.state.doc,{blockSeparator:n,textSerializers:{...Qm(this.schema),...r}})}get isEmpty(){return xf(this.state.doc)}getCharacterCount(){return console.warn('[tiptap warn]: "editor.getCharacterCount()" is deprecated. Please use "editor.storage.characterCount.characters()" instead.'),this.state.doc.content.size-2}destroy(){if(this.emit("destroy"),this.view){const e=this.view.dom;e&&e.editor&&delete e.editor,this.view.destroy()}this.removeAllListeners()}get isDestroyed(){var e;return!(!((e=this.view)===null||e===void 0)&&e.docView)}$node(e,n){var r;return((r=this.$doc)===null||r===void 0?void 0:r.querySelector(e,n))||null}$nodes(e,n){var r;return((r=this.$doc)===null||r===void 0?void 0:r.querySelectorAll(e,n))||null}$pos(e){const n=this.state.doc.resolve(e);return new Ns(n,this)}get $doc(){return this.$pos(0)}}function Ls(t){return new Ic({find:t.find,handler:({state:e,range:n,match:r})=>{const o=at(t.getAttributes,void 0,r);if(o===!1||o===null)return null;const{tr:i}=e,s=r[r.length-1],a=r[0];if(s){const l=a.search(/\S/),u=n.from+a.indexOf(s),f=u+s.length;if(oy(n.from,n.to,e.doc).filter(m=>m.mark.type.excluded.find(b=>b===t.type&&b!==m.mark.type)).filter(m=>m.to>u).length)return null;f<n.to&&i.delete(f,n.to),u>n.from&&i.delete(n.from+l,u);const g=n.from+l+s.length;i.addMark(n.from+l,g,t.type.create(o||{})),i.removeStoredMark(t.type)}}})}function tM(t){return new Ic({find:t.find,handler:({state:e,range:n,match:r})=>{const o=at(t.getAttributes,void 0,r)||{},{tr:i}=e,s=n.from;let a=n.to;const l=t.type.create(o);if(r[1]){const u=r[0].lastIndexOf(r[1]);let f=s+u;f>a?f=a:a=f+r[1].length;const p=r[0][r[0].length-1];i.insertText(p,s+r[0].length-1),i.replaceWith(f,a,l)}else if(r[0]){const u=t.type.isInline?s:s-1;i.insert(u,t.type.create(o)).delete(i.mapping.map(s),i.mapping.map(a))}i.scrollIntoView()}})}function ly(t){return new Ic({find:t.find,handler:({state:e,range:n,match:r})=>{const o=e.doc.resolve(n.from),i=at(t.getAttributes,void 0,r)||{};if(!o.node(-1).canReplaceWith(o.index(-1),o.indexAfter(-1),t.type))return null;e.tr.delete(n.from,n.to).setBlockType(n.from,n.from,t.type,i)}})}function Wa(t){return new Ic({find:t.find,handler:({state:e,range:n,match:r,chain:o})=>{const i=at(t.getAttributes,void 0,r)||{},s=e.tr.delete(n.from,n.to),l=s.doc.resolve(n.from).blockRange(),u=l&&pm(l,t.type,i);if(!u)return null;if(s.wrap(l,u),t.keepMarks&&t.editor){const{selection:p,storedMarks:g}=e,{splittableMarks:m}=t.editor.extensionManager,y=g||p.$to.parentOffset&&p.$from.marks();if(y){const b=y.filter(S=>m.includes(S.type.name));s.ensureMarks(b)}}if(t.keepAttributes){const p=t.type.name==="bulletList"||t.type.name==="orderedList"?"listItem":"taskList";o().updateAttributes(p,i).run()}const f=s.doc.resolve(n.from-1).nodeBefore;f&&f.type===t.type&&Ii(s.doc,n.from-1)&&(!t.joinPredicate||t.joinPredicate(r,f))&&s.join(n.from-1)}})}class tn{constructor(e={}){this.type="node",this.name="node",this.parent=null,this.child=null,this.config={name:this.name,defaultOptions:{}},this.config={...this.config,...e},this.name=this.config.name,e.defaultOptions&&Object.keys(e.defaultOptions).length>0&&console.warn(`[tiptap warn]: BREAKING CHANGE: "defaultOptions" is deprecated. Please use "addOptions" instead. Found in extension: "${this.name}".`),this.options=this.config.defaultOptions,this.config.addOptions&&(this.options=at(He(this,"addOptions",{name:this.name}))),this.storage=at(He(this,"addStorage",{name:this.name,options:this.options}))||{}}static create(e={}){return new tn(e)}configure(e={}){const n=this.extend({...this.config,addOptions:()=>pf(this.options,e)});return n.name=this.name,n.parent=this.parent,n}extend(e={}){const n=new tn(e);return n.parent=this,this.child=n,n.name=e.name?e.name:n.parent.name,e.defaultOptions&&Object.keys(e.defaultOptions).length>0&&console.warn(`[tiptap warn]: BREAKING CHANGE: "defaultOptions" is deprecated. Please use "addOptions" instead. Found in extension: "${n.name}".`),n.options=at(He(n,"addOptions",{name:n.name})),n.storage=at(He(n,"addStorage",{name:n.name,options:n.options})),n}}class WK{constructor(e,n,r){this.isDragging=!1,this.component=e,this.editor=n.editor,this.options={stopEvent:null,ignoreMutation:null,...r},this.extension=n.extension,this.node=n.node,this.decorations=n.decorations,this.innerDecorations=n.innerDecorations,this.view=n.view,this.HTMLAttributes=n.HTMLAttributes,this.getPos=n.getPos,this.mount()}mount(){}get dom(){return this.editor.view.dom}get contentDOM(){return null}onDragStart(e){var n,r,o,i,s,a,l;const{view:u}=this.editor,f=e.target,p=f.nodeType===3?(n=f.parentElement)===null||n===void 0?void 0:n.closest("[data-drag-handle]"):f.closest("[data-drag-handle]");if(!this.dom||!((r=this.contentDOM)===null||r===void 0)&&r.contains(f)||!p)return;let g=0,m=0;if(this.dom!==p){const C=this.dom.getBoundingClientRect(),T=p.getBoundingClientRect(),_=(o=e.offsetX)!==null&&o!==void 0?o:(i=e.nativeEvent)===null||i===void 0?void 0:i.offsetX,w=(s=e.offsetY)!==null&&s!==void 0?s:(a=e.nativeEvent)===null||a===void 0?void 0:a.offsetY;g=T.x-C.x+_,m=T.y-C.y+w}(l=e.dataTransfer)===null||l===void 0||l.setDragImage(this.dom,g,m);const y=this.getPos();if(typeof y!="number")return;const b=Ye.create(u.state.doc,y),S=u.state.tr.setSelection(b);u.dispatch(S)}stopEvent(e){var n;if(!this.dom)return!1;if(typeof this.options.stopEvent=="function")return this.options.stopEvent({event:e});const r=e.target;if(!(this.dom.contains(r)&&!(!((n=this.contentDOM)===null||n===void 0)&&n.contains(r))))return!1;const i=e.type.startsWith("drag"),s=e.type==="drop";if((["INPUT","BUTTON","SELECT","TEXTAREA"].includes(r.tagName)||r.isContentEditable)&&!s&&!i)return!0;const{isEditable:l}=this.editor,{isDragging:u}=this,f=!!this.node.type.spec.draggable,p=Ye.isSelectable(this.node),g=e.type==="copy",m=e.type==="paste",y=e.type==="cut",b=e.type==="mousedown";if(!f&&p&&i&&e.target===this.dom&&e.preventDefault(),f&&i&&!u&&e.target===this.dom)return e.preventDefault(),!1;if(f&&l&&!u&&b){const S=r.closest("[data-drag-handle]");S&&(this.dom===S||this.dom.contains(S))&&(this.isDragging=!0,document.addEventListener("dragend",()=>{this.isDragging=!1},{once:!0}),document.addEventListener("drop",()=>{this.isDragging=!1},{once:!0}),document.addEventListener("mouseup",()=>{this.isDragging=!1},{once:!0}))}return!(u||s||g||m||y||b&&p)}ignoreMutation(e){return!this.dom||!this.contentDOM?!0:typeof this.options.ignoreMutation=="function"?this.options.ignoreMutation({mutation:e}):this.node.isLeaf||this.node.isAtom?!0:e.type==="selection"||this.dom.contains(e.target)&&e.type==="childList"&&(mf()||qE())&&this.editor.isFocused&&[...Array.from(e.addedNodes),...Array.from(e.removedNodes)].every(r=>r.isContentEditable)?!1:this.contentDOM===e.target&&e.type==="attributes"?!0:!this.contentDOM.contains(e.target)}updateAttributes(e){this.editor.commands.command(({tr:n})=>{const r=this.getPos();return typeof r!="number"?!1:(n.setNodeMarkup(r,void 0,{...this.node.attrs,...e}),!0)})}deleteNode(){const e=this.getPos();if(typeof e!="number")return;const n=e+this.node.nodeSize;this.editor.commands.deleteRange({from:e,to:n})}}function Vi(t){return new vU({find:t.find,handler:({state:e,range:n,match:r,pasteEvent:o})=>{const i=at(t.getAttributes,void 0,r,o);if(i===!1||i===null)return null;const{tr:s}=e,a=r[r.length-1],l=r[0];let u=n.to;if(a){const f=l.search(/\S/),p=n.from+l.indexOf(a),g=p+a.length;if(oy(n.from,n.to,e.doc).filter(y=>y.mark.type.excluded.find(S=>S===t.type&&S!==y.mark.type)).filter(y=>y.to>p).length)return null;g<n.to&&s.delete(g,n.to),p>n.from&&s.delete(n.from+f,p),u=n.from+f+a.length,s.addMark(n.from+f,u,t.type.create(i||{})),s.removeStoredMark(t.type)}}})}function qK(t){return t.replace(/[-/\\^$*+?.()|[\]{}]/g,"\\$&")}const nM=Object.fromEntries?Object.fromEntries:t=>{if(!t||!t[Symbol.iterator])throw new Error("Object.fromEntries() requires a single iterable argument");const e={};return Object.keys(t).forEach(n=>{const[r,o]=t[n];e[r]=o}),e};function Hi(t){return Object.keys(t)}function Fs(t,e){if(!t)throw new Error(e)}function cy(t,e){return e}const uy=t=>{const e=t.length;let n=0,r="";for(;n<e;n++){const o=t[n];if(o==null)continue;let i;switch(typeof o){case"boolean":break;case"object":{if(Array.isArray(o))i=uy(o);else{Fs(!cy(o,!1)),process.env.NODE_ENV!=="production"&&o.styles!==void 0&&o.name!==void 0&&console.error("You have passed styles created with `css` from `@emotion/react` package to the `cx`.\n`cx` is meant to compose class names (strings) so you should convert those styles to a class name by passing them to the `css` received from <ClassNames/> component."),i="";for(const s in o)o[s]&&s&&(i&&(i+=" "),i+=s)}break}default:i=o}i&&(r&&(r+=" "),r+=i)}return r};function UK(t,e,n){var r="";return n.split(" ").forEach(function(o){t[o]!==void 0?e.push(t[o]+";"):o&&(r+=o+" ")}),r}var KK=function(e,n,r){var o=e.key+"-"+n.name;e.registered[o]===void 0&&(e.registered[o]=n.styles)},YK=function(e,n,r){KK(e,n);var o=e.key+"-"+n.name;if(e.inserted[n.name]===void 0){var i=n;do e.insert(n===i?"."+o:"",i,e.sheet,!0),i=i.next;while(i!==void 0)}};function GK(t,e){var n;const r=J.useRef();return(!r.current||e.length!==((n=r.current.prevDeps)===null||n===void 0?void 0:n.length)||r.current.prevDeps.map((o,i)=>o===e[i]).indexOf(!1)>=0)&&(r.current={v:t(),prevDeps:[...e]}),r.current.v}function JK(t){return t instanceof Object&&!("styles"in t)&&!("length"in t)&&!("__emotion_styles"in t)}const{createCssAndCx:ZK}=(()=>{function t(n,r,o){const i=[],s=UK(n,i,o);return i.length<2?o:s+r(i)}function e(n){const{cache:r}=n,o=(...s)=>{const a=FS(s,r.registered);YK(r,a);const l=`${r.key}-${a.name}`;e:{const u=s[0];if(!JK(u))break e;oM.saveClassNameCSSObjectMapping(r,l,u)}return l};return{css:o,cx:(...s)=>{const a=uy(s),l=oM.fixClassName(r,a,o);return t(r.registered,o,l)}}}return{createCssAndCx:e}})();function rM(t){const{useCache:e}=t;function n(){const r=e(),{css:o,cx:i}=GK(()=>ZK({cache:r}),[r]);return{css:o,cx:i}}return{useCssAndCx:n}}const oM=(()=>{const t=new WeakMap;return{saveClassNameCSSObjectMapping:(e,n,r)=>{let o=t.get(e);o===void 0&&(o=new Map,t.set(e,o)),o.set(n,r)},fixClassName:(()=>{function e(n){let r=!1;return n.map(([o,i])=>{if(i===void 0)return o;let s;if(r)s={"&&":i};else{s=o;for(const a in i)if(a.startsWith("@media")){r=!0;break}}return s})}return(n,r,o)=>{const i=t.get(n);return uy(e(r.split(" ").map(s=>[s,i==null?void 0:i.get(s)])).map(s=>typeof s=="string"?s:o(s)))}})()}})();function ji(t){if(!(t instanceof Object)||typeof t=="function")return t;const e=[];for(const n in t){const r=t[n],o=typeof r;if(!(o==="string"||o==="number"&&!isNaN(r)||o==="boolean"||r===void 0||r===null))return t;e.push(`${n}:${o}_${r}`)}return"xSqLiJdLMd9s"+e.join("|")}function dy(t,e,n){if(!(e instanceof Object))return t;const r={};return Hi(t).forEach(o=>r[o]=n(t[o],e[o])),Hi(e).forEach(o=>{if(o in t)return;const i=e[o];typeof i=="string"&&(r[o]=i)}),r}const iM=({classes:t,theme:e,muiStyleOverridesParams:n,css:r,cx:o,name:i})=>{var s,a;e:{if(i==="makeStyle no name"){i=void 0;break e}if(n!==void 0&&i===void 0)throw new Error("To use muiStyleOverridesParams, you must specify a name using .withName('MyComponent')")}let l;try{l=i===void 0?void 0:((a=(s=e.components)===null||s===void 0?void 0:s[i])===null||a===void 0?void 0:a.styleOverrides)||void 0}catch{}const u=J.useMemo(()=>{if(l===void 0)return;const f={};for(const p in l){const g=l[p];g instanceof Object&&(f[p]=r(typeof g=="function"?g({theme:e,ownerState:n==null?void 0:n.ownerState,...n==null?void 0:n.props}):g))}return f},[l,ji(n==null?void 0:n.props),ji(n==null?void 0:n.ownerState),r]);return t=J.useMemo(()=>dy(t,u,o),[t,u,o]),{classes:t}};let XK=0;function sM(t){const{useTheme:e,cache:n}=t,{useCache:r}=aM({cacheProvidedAtInception:n}),{useCssAndCx:o}=rM({useCache:r});function i(a){const{name:l,uniqId:u=`${XK++}`}=a??{},f=typeof l!="object"?l:Object.keys(l)[0];return function(p){const g=typeof p=="function"?p:()=>p;return function(y,b){const S=e();let{css:C,cx:T}=o();const _=r();let w=J.useMemo(()=>{const E={},O=typeof Proxy<"u"&&new Proxy({},{get:($,M)=>(typeof M=="symbol"&&Fs(!1),E[M]=`${_.key}-${u}${f!==void 0?`-${f}`:""}-${M}-ref`)}),L=g(S,y,O||{}),P=nM(Hi(L).map($=>{const M=L[$];return M.label||(M.label=`${f!==void 0?`${f}-`:""}${$}`),[$,`${C(M)}${cy($,$ in E)?` ${E[$]}`:""}`]}));return Hi(E).forEach($=>{$ in P||(P[$]=E[$])}),P},[_,C,T,S,ji(y)]);{const E=b==null?void 0:b.props.classes;w=J.useMemo(()=>dy(w,E,T),[w,ji(E),T])}{const E=iM({classes:w,css:C,cx:T,name:f??"makeStyle no name",idOfUseStyles:u,muiStyleOverridesParams:b,theme:S});E.classes!==void 0&&(w=E.classes),E.css!==void 0&&(C=E.css),E.cx!==void 0&&(T=E.cx)}return{classes:w,theme:S,css:C,cx:T}}}}function s(){const a=e(),{css:l,cx:u}=o();return{theme:a,css:l,cx:u}}return{makeStyles:i,useStyles:s}}const QK=J.createContext(void 0),{createUseCache:aM}=(()=>{function t(){return J.useContext(QK)}function e(n){const{cacheProvidedAtInception:r}=n;function o(){var i;const s=to.__unsafe_useEmotionCache(),a=t(),l=(i=r??a)!==null&&i!==void 0?i:s;if(l===null)throw new Error(["In order to get SSR working with tss-react you need to explicitly provide an Emotion cache.","MUI users be aware: This is not an error strictly related to tss-react, with or without tss-react,","MUI needs an Emotion cache to be provided for SSR to work.","Here is the MUI documentation related to SSR setup: https://mui.com/material-ui/guides/server-rendering/","TSS provides helper that makes the process of setting up SSR easier: https://docs.tss-react.dev/ssr"].join(`
|
|
323
323
|
`));return l}return{useCache:o}}return{createUseCache:e}})();function lM(t){return t.charAt(0).toUpperCase()+t.slice(1)}function eY(t){const{useTheme:e,cache:n}=t,{makeStyles:r}=sM({useTheme:e,cache:n});function o(i,s,a){const l=typeof i=="string"?(()=>{const m=i,y=function({children:b,...S}){return J.createElement(m,S,b)};return Object.defineProperty(y,"name",{value:lM(m)}),y})():i,u=(()=>{{const{name:y}=a??{};if(y!==void 0)return typeof y!="object"?y:Object.keys(y)[0]}let m;e:{const y=l.displayName;if(typeof y!="string"||y==="")break e;m=y}e:{if(m!==void 0)break e;const y=l.name;if(typeof y!="string"||y==="")break e;m=y}if(m!==void 0)return m=m.replace(/\$/g,"usd"),m=m.replace(/\(/g,"_").replace(/\)/g,"_"),m=m.replace(/[^a-zA-Z0-9-_]/g,"_"),m})(),f=r({...a,name:u})(typeof s=="function"?(m,y,b)=>dM(s(m,y,b)):dM(s));function p(m){for(const y in m)if(y!=="root")return!0;return!1}const g=J.forwardRef(function(m,y){const{className:b,classes:S,...C}=m,{classes:T,cx:_}=f(m,{props:m}),w=_(T.root,b);return cM.set(T,{...T,root:w}),J.createElement(l,{ref:y,className:p(T)?b:w,...typeof i=="string"?{}:{classes:T},...C})});return u!==void 0&&(g.displayName=`${lM(u)}WithStyles`,Object.defineProperty(g,"name",{value:g.displayName})),g}return o.getClasses=tY,{withStyles:o}}const cM=new WeakMap,uM="getClasses should only be used in conjunction with withStyles";function tY(t){const e=t.classes;if(e===void 0)throw new Error(uM);const n=cM.get(e);if(n===void 0)throw new Error(uM);return n}function dM(t){const e={},n={};return Object.keys(t).forEach(r=>(r.startsWith("@media")?n:e)[r]=t[r]),Object.keys(n).forEach(r=>{const o=n[r];Object.keys(o).forEach(i=>{var s;return e[i]={...(s=e[i])!==null&&s!==void 0?s:{},[r]:o[i]}})}),e}const nY=!(typeof document=="object"&&typeof(document==null?void 0:document.getElementById)=="function")&&!(typeof jest<"u")&&!(typeof mocha<"u")&&!(typeof __vitest_worker__<"u");function fM(t){pM=0,Wi.splice(0,Wi.length);const{useContext:e,usePlugin:n,cache:r}=t,{useCache:o}=aM({cacheProvidedAtInception:r}),{useCssAndCx:i}=rM({useCache:o});return{tss:Sf({useContext:e,useCache:o,useCssAndCx:i,usePlugin:n??(({classes:l,cx:u,css:f})=>({classes:l,cx:u,css:f})),name:void 0,doesUseNestedSelectors:!1})}}let pM=0;const Wi=[];function Sf(t){const{useContext:e,useCache:n,useCssAndCx:r,usePlugin:o,name:i,doesUseNestedSelectors:s}=t;return{withParams:()=>Sf({...t}),withName:a=>Sf({...t,name:typeof a!="object"?a:Object.keys(a)[0]}),withNestedSelectors:()=>Sf({...t,doesUseNestedSelectors:!0}),create:a=>{const l=`x${pM++}`;if(i!==void 0)for(;;){const f=Wi.find(p=>p.name===i);if(f===void 0)break;Wi.splice(Wi.indexOf(f),1)}const u=typeof a=="function"?a:()=>a;return function(p){var g,m,y;const{classesOverrides:b,...S}=p??{},C=e(),{css:T,cx:_}=r(),w=n(),E=()=>{const P={},$=u({...p,...C,...s?{classes:typeof Proxy>"u"?{}:new Proxy({},{get:(A,N)=>{if(typeof N=="symbol"&&Fs(!1),nY&&i===void 0)throw new Error(["tss-react: In SSR setups, in order to use nested selectors, you must also give a unique name to the useStyle function.",'Solution: Use tss.withName("ComponentName").withNestedSelectors<...>()... to set a name.'].join(`
|
|
324
|
-
`));e:{if(i===void 0)break e;let
|
|
324
|
+
`));e:{if(i===void 0)break e;let z=Wi.find(V=>V.name===i&&V.idOfUseStyles===l);z===void 0&&(z={name:i,idOfUseStyles:l,nestedSelectorRuleNames:new Set},Wi.push(z)),z.nestedSelectorRuleNames.add(N)}e:{if(i===void 0||!(Wi.find(V=>V.name===i&&V.idOfUseStyles!==l&&V.nestedSelectorRuleNames.has(N))!==void 0))break e;throw new Error([`tss-react: There are in your codebase two different useStyles named "${i}" that`,`both use use the nested selector ${N}.
|
|
325
325
|
`,`This may lead to CSS class name collisions, causing nested selectors to target elements outside of the intended scope.
|
|
326
326
|
`,`Solution: Ensure each useStyles using nested selectors has a unique name.
|
|
327
|
-
`,'Use: tss.withName("UniqueName").withNestedSelectors<...>()...'].join(" "))}return P[N]=`${w.key}-${i!==void 0?i:l}-${N}-ref`}})}:{}});let M=nM(Hi($).map(A=>{const N=$[A];return N.label||(N.label=`${i!==void 0?`${i}-`:""}${A}`),[A,`${T(N)}${cy(A,A in P)?` ${P[A]}`:""}`]}));return Hi(P).forEach(A=>{A in M||(M[A]=P[A])}),M=dy(M,b,_),M},O=rY({cache:w,cssObjectByRuleNameOrGetCssObjectByRuleName:a,classesOverridesRef:ji(b),paramsAndPluginParamsRef:ji(S),idOfUseStyles:l,context:C,getClasses:E}),L=o({classes:O,css:T,cx:_,idOfUseStyles:l,name:i,...C,...S});return{classes:(g=L.classes)!==null&&g!==void 0?g:O,css:(m=L.css)!==null&&m!==void 0?m:T,cx:(y=L.cx)!==null&&y!==void 0?y:_,...C}}}}}const Cf=new WeakMap;function rY(t){const{cache:e,cssObjectByRuleNameOrGetCssObjectByRuleName:n,classesOverridesRef:r,paramsAndPluginParamsRef:o,idOfUseStyles:i,context:s,getClasses:a}=t;e:{const u=Cf.get(e);if(u===void 0)break e;const f=u.get(n);if(f===void 0)break e;const p=f.get(r);if(p===void 0)break e;const g=p.get(o);if(g===void 0)break e;const m=g.find(({context:y})=>{if(y===s)return!0;if(Hi(y).length!==Hi(s).length)return!1;for(const b in y)if(ji(y[b])!==ji(s[b]))return!1;return!0});if(m===void 0)break e;if((m==null?void 0:m.idOfUseStyles)!==i){g.splice(g.indexOf(m),1);break e}return m.result}const l=a();{Cf.has(e)||Cf.set(e,new WeakMap);const u=Cf.get(e);Fs(u!==void 0),u.has(n)||u.set(n,new Map);const f=u.get(n);Fs(f!==void 0),f.has(r)||(f.size>200&&f.clear(),f.set(r,new Map));const p=f.get(r);if(Fs(p!==void 0),!p.has(o)){e:{const m=typeof o=="string"?257:5;if(p.size<m)break e;p.clear()}p.set(o,[])}let g=p.get(o);Fs(g!==void 0),g.length>5&&(g=[]),g.push({idOfUseStyles:i,context:s,result:l})}return l}function oY(t){return{...sM(t),...eY(t)}}const{tss:iY}=fM({useContext:()=>({})});iY.create({});const{makeStyles:Ut,withStyles:Rpe}=oY({useTheme:Si}),{tss:sY}=fM({useContext:function(){return{theme:Si()}},usePlugin:iM});sY.create({});var fy,hM;function gM(){if(hM)return fy;hM=1;function t(e,n){for(var r=-1,o=e==null?0:e.length,i=Array(o);++r<o;)i[r]=n(e[r],r,e);return i}return fy=t,fy}var py,mM;function aY(){if(mM)return py;mM=1;function t(){this.__data__=[],this.size=0}return py=t,py}var hy,yM;function bM(){if(yM)return hy;yM=1;function t(e,n){return e===n||e!==e&&n!==n}return hy=t,hy}var gy,vM;function wf(){if(vM)return gy;vM=1;var t=bM();function e(n,r){for(var o=n.length;o--;)if(t(n[o][0],r))return o;return-1}return gy=e,gy}var my,xM;function lY(){if(xM)return my;xM=1;var t=wf(),e=Array.prototype,n=e.splice;function r(o){var i=this.__data__,s=t(i,o);if(s<0)return!1;var a=i.length-1;return s==a?i.pop():n.call(i,s,1),--this.size,!0}return my=r,my}var yy,SM;function cY(){if(SM)return yy;SM=1;var t=wf();function e(n){var r=this.__data__,o=t(r,n);return o<0?void 0:r[o][1]}return yy=e,yy}var by,CM;function uY(){if(CM)return by;CM=1;var t=wf();function e(n){return t(this.__data__,n)>-1}return by=e,by}var vy,wM;function dY(){if(wM)return vy;wM=1;var t=wf();function e(n,r){var o=this.__data__,i=t(o,n);return i<0?(++this.size,o.push([n,r])):o[i][1]=r,this}return vy=e,vy}var xy,_M;function _f(){if(_M)return xy;_M=1;var t=aY(),e=lY(),n=cY(),r=uY(),o=dY();function i(s){var a=-1,l=s==null?0:s.length;for(this.clear();++a<l;){var u=s[a];this.set(u[0],u[1])}}return i.prototype.clear=t,i.prototype.delete=e,i.prototype.get=n,i.prototype.has=r,i.prototype.set=o,xy=i,xy}var Sy,TM;function fY(){if(TM)return Sy;TM=1;var t=_f();function e(){this.__data__=new t,this.size=0}return Sy=e,Sy}var Cy,kM;function pY(){if(kM)return Cy;kM=1;function t(e){var n=this.__data__,r=n.delete(e);return this.size=n.size,r}return Cy=t,Cy}var wy,EM;function hY(){if(EM)return wy;EM=1;function t(e){return this.__data__.get(e)}return wy=t,wy}var _y,MM;function gY(){if(MM)return _y;MM=1;function t(e){return this.__data__.has(e)}return _y=t,_y}var Ty,OM;function AM(){if(OM)return Ty;OM=1;var t=us(),e=Uo(),n="[object AsyncFunction]",r="[object Function]",o="[object GeneratorFunction]",i="[object Proxy]";function s(a){if(!e(a))return!1;var l=t(a);return l==r||l==o||l==n||l==i}return Ty=s,Ty}var ky,IM;function mY(){if(IM)return ky;IM=1;var t=oo(),e=t["__core-js_shared__"];return ky=e,ky}var Ey,DM;function yY(){if(DM)return Ey;DM=1;var t=mY(),e=function(){var r=/[^.]+$/.exec(t&&t.keys&&t.keys.IE_PROTO||"");return r?"Symbol(src)_1."+r:""}();function n(r){return!!e&&e in r}return Ey=n,Ey}var My,PM;function NM(){if(PM)return My;PM=1;var t=Function.prototype,e=t.toString;function n(r){if(r!=null){try{return e.call(r)}catch{}try{return r+""}catch{}}return""}return My=n,My}var Oy,LM;function bY(){if(LM)return Oy;LM=1;var t=AM(),e=yY(),n=Uo(),r=NM(),o=/[\\^$.*+?()[\]{}|]/g,i=/^\[object .+?Constructor\]$/,s=Function.prototype,a=Object.prototype,l=s.toString,u=a.hasOwnProperty,f=RegExp("^"+l.call(u).replace(o,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function p(g){if(!n(g)||e(g))return!1;var m=t(g)?f:i;return m.test(r(g))}return Oy=p,Oy}var Ay,FM;function vY(){if(FM)return Ay;FM=1;function t(e,n){return e==null?void 0:e[n]}return Ay=t,Ay}var Iy,$M;function $s(){if($M)return Iy;$M=1;var t=bY(),e=vY();function n(r,o){var i=e(r,o);return t(i)?i:void 0}return Iy=n,Iy}var Dy,BM;function Py(){if(BM)return Dy;BM=1;var t=$s(),e=oo(),n=t(e,"Map");return Dy=n,Dy}var Ny,RM;function Tf(){if(RM)return Ny;RM=1;var t=$s(),e=t(Object,"create");return Ny=e,Ny}var Ly,zM;function xY(){if(zM)return Ly;zM=1;var t=Tf();function e(){this.__data__=t?t(null):{},this.size=0}return Ly=e,Ly}var Fy,VM;function SY(){if(VM)return Fy;VM=1;function t(e){var n=this.has(e)&&delete this.__data__[e];return this.size-=n?1:0,n}return Fy=t,Fy}var $y,HM;function CY(){if(HM)return $y;HM=1;var t=Tf(),e="__lodash_hash_undefined__",n=Object.prototype,r=n.hasOwnProperty;function o(i){var s=this.__data__;if(t){var a=s[i];return a===e?void 0:a}return r.call(s,i)?s[i]:void 0}return $y=o,$y}var By,jM;function wY(){if(jM)return By;jM=1;var t=Tf(),e=Object.prototype,n=e.hasOwnProperty;function r(o){var i=this.__data__;return t?i[o]!==void 0:n.call(i,o)}return By=r,By}var Ry,WM;function _Y(){if(WM)return Ry;WM=1;var t=Tf(),e="__lodash_hash_undefined__";function n(r,o){var i=this.__data__;return this.size+=this.has(r)?0:1,i[r]=t&&o===void 0?e:o,this}return Ry=n,Ry}var zy,qM;function TY(){if(qM)return zy;qM=1;var t=xY(),e=SY(),n=CY(),r=wY(),o=_Y();function i(s){var a=-1,l=s==null?0:s.length;for(this.clear();++a<l;){var u=s[a];this.set(u[0],u[1])}}return i.prototype.clear=t,i.prototype.delete=e,i.prototype.get=n,i.prototype.has=r,i.prototype.set=o,zy=i,zy}var Vy,UM;function kY(){if(UM)return Vy;UM=1;var t=TY(),e=_f(),n=Py();function r(){this.size=0,this.__data__={hash:new t,map:new(n||e),string:new t}}return Vy=r,Vy}var Hy,KM;function EY(){if(KM)return Hy;KM=1;function t(e){var n=typeof e;return n=="string"||n=="number"||n=="symbol"||n=="boolean"?e!=="__proto__":e===null}return Hy=t,Hy}var jy,YM;function kf(){if(YM)return jy;YM=1;var t=EY();function e(n,r){var o=n.__data__;return t(r)?o[typeof r=="string"?"string":"hash"]:o.map}return jy=e,jy}var Wy,GM;function MY(){if(GM)return Wy;GM=1;var t=kf();function e(n){var r=t(this,n).delete(n);return this.size-=r?1:0,r}return Wy=e,Wy}var qy,JM;function OY(){if(JM)return qy;JM=1;var t=kf();function e(n){return t(this,n).get(n)}return qy=e,qy}var Uy,ZM;function AY(){if(ZM)return Uy;ZM=1;var t=kf();function e(n){return t(this,n).has(n)}return Uy=e,Uy}var Ky,XM;function IY(){if(XM)return Ky;XM=1;var t=kf();function e(n,r){var o=t(this,n),i=o.size;return o.set(n,r),this.size+=o.size==i?0:1,this}return Ky=e,Ky}var Yy,QM;function eO(){if(QM)return Yy;QM=1;var t=kY(),e=MY(),n=OY(),r=AY(),o=IY();function i(s){var a=-1,l=s==null?0:s.length;for(this.clear();++a<l;){var u=s[a];this.set(u[0],u[1])}}return i.prototype.clear=t,i.prototype.delete=e,i.prototype.get=n,i.prototype.has=r,i.prototype.set=o,Yy=i,Yy}var Gy,tO;function DY(){if(tO)return Gy;tO=1;var t=_f(),e=Py(),n=eO(),r=200;function o(i,s){var a=this.__data__;if(a instanceof t){var l=a.__data__;if(!e||l.length<r-1)return l.push([i,s]),this.size=++a.size,this;a=this.__data__=new n(l)}return a.set(i,s),this.size=a.size,this}return Gy=o,Gy}var Jy,nO;function PY(){if(nO)return Jy;nO=1;var t=_f(),e=fY(),n=pY(),r=hY(),o=gY(),i=DY();function s(a){var l=this.__data__=new t(a);this.size=l.size}return s.prototype.clear=e,s.prototype.delete=n,s.prototype.get=r,s.prototype.has=o,s.prototype.set=i,Jy=s,Jy}var Zy,rO;function NY(){if(rO)return Zy;rO=1;function t(e,n){for(var r=-1,o=e==null?0:e.length;++r<o&&n(e[r],r,e)!==!1;);return e}return Zy=t,Zy}var Xy,oO;function iO(){if(oO)return Xy;oO=1;var t=$s(),e=function(){try{var n=t(Object,"defineProperty");return n({},"",{}),n}catch{}}();return Xy=e,Xy}var Qy,sO;function aO(){if(sO)return Qy;sO=1;var t=iO();function e(n,r,o){r=="__proto__"&&t?t(n,r,{configurable:!0,enumerable:!0,value:o,writable:!0}):n[r]=o}return Qy=e,Qy}var eb,lO;function cO(){if(lO)return eb;lO=1;var t=aO(),e=bM(),n=Object.prototype,r=n.hasOwnProperty;function o(i,s,a){var l=i[s];(!(r.call(i,s)&&e(l,a))||a===void 0&&!(s in i))&&t(i,s,a)}return eb=o,eb}var tb,uO;function Lc(){if(uO)return tb;uO=1;var t=cO(),e=aO();function n(r,o,i,s){var a=!i;i||(i={});for(var l=-1,u=o.length;++l<u;){var f=o[l],p=s?s(i[f],r[f],f,i,r):void 0;p===void 0&&(p=r[f]),a?e(i,f,p):t(i,f,p)}return i}return tb=n,tb}var nb,dO;function LY(){if(dO)return nb;dO=1;function t(e,n){for(var r=-1,o=Array(e);++r<e;)o[r]=n(r);return o}return nb=t,nb}var rb,fO;function FY(){if(fO)return rb;fO=1;var t=us(),e=Ci(),n="[object Arguments]";function r(o){return e(o)&&t(o)==n}return rb=r,rb}var ob,pO;function hO(){if(pO)return ob;pO=1;var t=FY(),e=Ci(),n=Object.prototype,r=n.hasOwnProperty,o=n.propertyIsEnumerable,i=t(function(){return arguments}())?t:function(s){return e(s)&&r.call(s,"callee")&&!o.call(s,"callee")};return ob=i,ob}var ib,gO;function Bs(){if(gO)return ib;gO=1;var t=Array.isArray;return ib=t,ib}var Fc={exports:{}},sb,mO;function $Y(){if(mO)return sb;mO=1;function t(){return!1}return sb=t,sb}Fc.exports;var yO;function bO(){return yO||(yO=1,function(t,e){var n=oo(),r=$Y(),o=e&&!e.nodeType&&e,i=o&&!0&&t&&!t.nodeType&&t,s=i&&i.exports===o,a=s?n.Buffer:void 0,l=a?a.isBuffer:void 0,u=l||r;t.exports=u}(Fc,Fc.exports)),Fc.exports}var ab,vO;function BY(){if(vO)return ab;vO=1;var t=9007199254740991,e=/^(?:0|[1-9]\d*)$/;function n(r,o){var i=typeof r;return o=o??t,!!o&&(i=="number"||i!="symbol"&&e.test(r))&&r>-1&&r%1==0&&r<o}return ab=n,ab}var lb,xO;function SO(){if(xO)return lb;xO=1;var t=9007199254740991;function e(n){return typeof n=="number"&&n>-1&&n%1==0&&n<=t}return lb=e,lb}var cb,CO;function RY(){if(CO)return cb;CO=1;var t=us(),e=SO(),n=Ci(),r="[object Arguments]",o="[object Array]",i="[object Boolean]",s="[object Date]",a="[object Error]",l="[object Function]",u="[object Map]",f="[object Number]",p="[object Object]",g="[object RegExp]",m="[object Set]",y="[object String]",b="[object WeakMap]",S="[object ArrayBuffer]",C="[object DataView]",T="[object Float32Array]",_="[object Float64Array]",w="[object Int8Array]",E="[object Int16Array]",O="[object Int32Array]",L="[object Uint8Array]",P="[object Uint8ClampedArray]",$="[object Uint16Array]",M="[object Uint32Array]",A={};A[T]=A[_]=A[w]=A[E]=A[O]=A[L]=A[P]=A[$]=A[M]=!0,A[r]=A[o]=A[S]=A[i]=A[C]=A[s]=A[a]=A[l]=A[u]=A[f]=A[p]=A[g]=A[m]=A[y]=A[b]=!1;function N(V){return n(V)&&e(V.length)&&!!A[t(V)]}return cb=N,cb}var ub,wO;function Ef(){if(wO)return ub;wO=1;function t(e){return function(n){return e(n)}}return ub=t,ub}var $c={exports:{}};$c.exports;var _O;function Mf(){return _O||(_O=1,function(t,e){var n=bC(),r=e&&!e.nodeType&&e,o=r&&!0&&t&&!t.nodeType&&t,i=o&&o.exports===r,s=i&&n.process,a=function(){try{var l=o&&o.require&&o.require("util").types;return l||s&&s.binding&&s.binding("util")}catch{}}();t.exports=a}($c,$c.exports)),$c.exports}var db,TO;function zY(){if(TO)return db;TO=1;var t=RY(),e=Ef(),n=Mf(),r=n&&n.isTypedArray,o=r?e(r):t;return db=o,db}var fb,kO;function EO(){if(kO)return fb;kO=1;var t=LY(),e=hO(),n=Bs(),r=bO(),o=BY(),i=zY(),s=Object.prototype,a=s.hasOwnProperty;function l(u,f){var p=n(u),g=!p&&e(u),m=!p&&!g&&r(u),y=!p&&!g&&!m&&i(u),b=p||g||m||y,S=b?t(u.length,String):[],C=S.length;for(var T in u)(f||a.call(u,T))&&!(b&&(T=="length"||m&&(T=="offset"||T=="parent")||y&&(T=="buffer"||T=="byteLength"||T=="byteOffset")||o(T,C)))&&S.push(T);return S}return fb=l,fb}var pb,MO;function hb(){if(MO)return pb;MO=1;var t=Object.prototype;function e(n){var r=n&&n.constructor,o=typeof r=="function"&&r.prototype||t;return n===o}return pb=e,pb}var gb,OO;function AO(){if(OO)return gb;OO=1;function t(e,n){return function(r){return e(n(r))}}return gb=t,gb}var mb,IO;function VY(){if(IO)return mb;IO=1;var t=AO(),e=t(Object.keys,Object);return mb=e,mb}var yb,DO;function HY(){if(DO)return yb;DO=1;var t=hb(),e=VY(),n=Object.prototype,r=n.hasOwnProperty;function o(i){if(!t(i))return e(i);var s=[];for(var a in Object(i))r.call(i,a)&&a!="constructor"&&s.push(a);return s}return yb=o,yb}var bb,PO;function NO(){if(PO)return bb;PO=1;var t=AM(),e=SO();function n(r){return r!=null&&e(r.length)&&!t(r)}return bb=n,bb}var vb,LO;function xb(){if(LO)return vb;LO=1;var t=EO(),e=HY(),n=NO();function r(o){return n(o)?t(o):e(o)}return vb=r,vb}var Sb,FO;function jY(){if(FO)return Sb;FO=1;var t=Lc(),e=xb();function n(r,o){return r&&t(o,e(o),r)}return Sb=n,Sb}var Cb,$O;function WY(){if($O)return Cb;$O=1;function t(e){var n=[];if(e!=null)for(var r in Object(e))n.push(r);return n}return Cb=t,Cb}var wb,BO;function qY(){if(BO)return wb;BO=1;var t=Uo(),e=hb(),n=WY(),r=Object.prototype,o=r.hasOwnProperty;function i(s){if(!t(s))return n(s);var a=e(s),l=[];for(var u in s)u=="constructor"&&(a||!o.call(s,u))||l.push(u);return l}return wb=i,wb}var _b,RO;function Tb(){if(RO)return _b;RO=1;var t=EO(),e=qY(),n=NO();function r(o){return n(o)?t(o,!0):e(o)}return _b=r,_b}var kb,zO;function UY(){if(zO)return kb;zO=1;var t=Lc(),e=Tb();function n(r,o){return r&&t(o,e(o),r)}return kb=n,kb}var Bc={exports:{}};Bc.exports;var VO;function KY(){return VO||(VO=1,function(t,e){var n=oo(),r=e&&!e.nodeType&&e,o=r&&!0&&t&&!t.nodeType&&t,i=o&&o.exports===r,s=i?n.Buffer:void 0,a=s?s.allocUnsafe:void 0;function l(u,f){if(f)return u.slice();var p=u.length,g=a?a(p):new u.constructor(p);return u.copy(g),g}t.exports=l}(Bc,Bc.exports)),Bc.exports}var Eb,HO;function YY(){if(HO)return Eb;HO=1;function t(e,n){var r=-1,o=e.length;for(n||(n=Array(o));++r<o;)n[r]=e[r];return n}return Eb=t,Eb}var Mb,jO;function GY(){if(jO)return Mb;jO=1;function t(e,n){for(var r=-1,o=e==null?0:e.length,i=0,s=[];++r<o;){var a=e[r];n(a,r,e)&&(s[i++]=a)}return s}return Mb=t,Mb}var Ob,WO;function qO(){if(WO)return Ob;WO=1;function t(){return[]}return Ob=t,Ob}var Ab,UO;function Ib(){if(UO)return Ab;UO=1;var t=GY(),e=qO(),n=Object.prototype,r=n.propertyIsEnumerable,o=Object.getOwnPropertySymbols,i=o?function(s){return s==null?[]:(s=Object(s),t(o(s),function(a){return r.call(s,a)}))}:e;return Ab=i,Ab}var Db,KO;function JY(){if(KO)return Db;KO=1;var t=Lc(),e=Ib();function n(r,o){return t(r,e(r),o)}return Db=n,Db}var Pb,YO;function Nb(){if(YO)return Pb;YO=1;function t(e,n){for(var r=-1,o=n.length,i=e.length;++r<o;)e[i+r]=n[r];return e}return Pb=t,Pb}var Lb,GO;function Fb(){if(GO)return Lb;GO=1;var t=AO(),e=t(Object.getPrototypeOf,Object);return Lb=e,Lb}var $b,JO;function ZO(){if(JO)return $b;JO=1;var t=Nb(),e=Fb(),n=Ib(),r=qO(),o=Object.getOwnPropertySymbols,i=o?function(s){for(var a=[];s;)t(a,n(s)),s=e(s);return a}:r;return $b=i,$b}var Bb,XO;function ZY(){if(XO)return Bb;XO=1;var t=Lc(),e=ZO();function n(r,o){return t(r,e(r),o)}return Bb=n,Bb}var Rb,QO;function eA(){if(QO)return Rb;QO=1;var t=Nb(),e=Bs();function n(r,o,i){var s=o(r);return e(r)?s:t(s,i(r))}return Rb=n,Rb}var zb,tA;function XY(){if(tA)return zb;tA=1;var t=eA(),e=Ib(),n=xb();function r(o){return t(o,n,e)}return zb=r,zb}var Vb,nA;function rA(){if(nA)return Vb;nA=1;var t=eA(),e=ZO(),n=Tb();function r(o){return t(o,n,e)}return Vb=r,Vb}var Hb,oA;function QY(){if(oA)return Hb;oA=1;var t=$s(),e=oo(),n=t(e,"DataView");return Hb=n,Hb}var jb,iA;function eG(){if(iA)return jb;iA=1;var t=$s(),e=oo(),n=t(e,"Promise");return jb=n,jb}var Wb,sA;function tG(){if(sA)return Wb;sA=1;var t=$s(),e=oo(),n=t(e,"Set");return Wb=n,Wb}var qb,aA;function nG(){if(aA)return qb;aA=1;var t=$s(),e=oo(),n=t(e,"WeakMap");return qb=n,qb}var Ub,lA;function Kb(){if(lA)return Ub;lA=1;var t=QY(),e=Py(),n=eG(),r=tG(),o=nG(),i=us(),s=NM(),a="[object Map]",l="[object Object]",u="[object Promise]",f="[object Set]",p="[object WeakMap]",g="[object DataView]",m=s(t),y=s(e),b=s(n),S=s(r),C=s(o),T=i;return(t&&T(new t(new ArrayBuffer(1)))!=g||e&&T(new e)!=a||n&&T(n.resolve())!=u||r&&T(new r)!=f||o&&T(new o)!=p)&&(T=function(_){var w=i(_),E=w==l?_.constructor:void 0,O=E?s(E):"";if(O)switch(O){case m:return g;case y:return a;case b:return u;case S:return f;case C:return p}return w}),Ub=T,Ub}var Yb,cA;function rG(){if(cA)return Yb;cA=1;var t=Object.prototype,e=t.hasOwnProperty;function n(r){var o=r.length,i=new r.constructor(o);return o&&typeof r[0]=="string"&&e.call(r,"index")&&(i.index=r.index,i.input=r.input),i}return Yb=n,Yb}var Gb,uA;function oG(){if(uA)return Gb;uA=1;var t=oo(),e=t.Uint8Array;return Gb=e,Gb}var Jb,dA;function Zb(){if(dA)return Jb;dA=1;var t=oG();function e(n){var r=new n.constructor(n.byteLength);return new t(r).set(new t(n)),r}return Jb=e,Jb}var Xb,fA;function iG(){if(fA)return Xb;fA=1;var t=Zb();function e(n,r){var o=r?t(n.buffer):n.buffer;return new n.constructor(o,n.byteOffset,n.byteLength)}return Xb=e,Xb}var Qb,pA;function sG(){if(pA)return Qb;pA=1;var t=/\w*$/;function e(n){var r=new n.constructor(n.source,t.exec(n));return r.lastIndex=n.lastIndex,r}return Qb=e,Qb}var e0,hA;function aG(){if(hA)return e0;hA=1;var t=Ll(),e=t?t.prototype:void 0,n=e?e.valueOf:void 0;function r(o){return n?Object(n.call(o)):{}}return e0=r,e0}var t0,gA;function lG(){if(gA)return t0;gA=1;var t=Zb();function e(n,r){var o=r?t(n.buffer):n.buffer;return new n.constructor(o,n.byteOffset,n.length)}return t0=e,t0}var n0,mA;function cG(){if(mA)return n0;mA=1;var t=Zb(),e=iG(),n=sG(),r=aG(),o=lG(),i="[object Boolean]",s="[object Date]",a="[object Map]",l="[object Number]",u="[object RegExp]",f="[object Set]",p="[object String]",g="[object Symbol]",m="[object ArrayBuffer]",y="[object DataView]",b="[object Float32Array]",S="[object Float64Array]",C="[object Int8Array]",T="[object Int16Array]",_="[object Int32Array]",w="[object Uint8Array]",E="[object Uint8ClampedArray]",O="[object Uint16Array]",L="[object Uint32Array]";function P($,M,A){var N=$.constructor;switch(M){case m:return t($);case i:case s:return new N(+$);case y:return e($,A);case b:case S:case C:case T:case _:case w:case E:case O:case L:return o($,A);case a:return new N;case l:case p:return new N($);case u:return n($);case f:return new N;case g:return r($)}}return n0=P,n0}var r0,yA;function uG(){if(yA)return r0;yA=1;var t=Uo(),e=Object.create,n=function(){function r(){}return function(o){if(!t(o))return{};if(e)return e(o);r.prototype=o;var i=new r;return r.prototype=void 0,i}}();return r0=n,r0}var o0,bA;function dG(){if(bA)return o0;bA=1;var t=uG(),e=Fb(),n=hb();function r(o){return typeof o.constructor=="function"&&!n(o)?t(e(o)):{}}return o0=r,o0}var i0,vA;function fG(){if(vA)return i0;vA=1;var t=Kb(),e=Ci(),n="[object Map]";function r(o){return e(o)&&t(o)==n}return i0=r,i0}var s0,xA;function pG(){if(xA)return s0;xA=1;var t=fG(),e=Ef(),n=Mf(),r=n&&n.isMap,o=r?e(r):t;return s0=o,s0}var a0,SA;function hG(){if(SA)return a0;SA=1;var t=Kb(),e=Ci(),n="[object Set]";function r(o){return e(o)&&t(o)==n}return a0=r,a0}var l0,CA;function gG(){if(CA)return l0;CA=1;var t=hG(),e=Ef(),n=Mf(),r=n&&n.isSet,o=r?e(r):t;return l0=o,l0}var c0,wA;function mG(){if(wA)return c0;wA=1;var t=PY(),e=NY(),n=cO(),r=jY(),o=UY(),i=KY(),s=YY(),a=JY(),l=ZY(),u=XY(),f=rA(),p=Kb(),g=rG(),m=cG(),y=dG(),b=Bs(),S=bO(),C=pG(),T=Uo(),_=gG(),w=xb(),E=Tb(),O=1,L=2,P=4,$="[object Arguments]",M="[object Array]",A="[object Boolean]",N="[object Date]",V="[object Error]",R="[object Function]",B="[object GeneratorFunction]",z="[object Map]",q="[object Number]",K="[object Object]",G="[object RegExp]",Y="[object Set]",Z="[object String]",me="[object Symbol]",he="[object WeakMap]",oe="[object ArrayBuffer]",Q="[object DataView]",fe="[object Float32Array]",ce="[object Float64Array]",ae="[object Int8Array]",W="[object Int16Array]",te="[object Int32Array]",ue="[object Uint8Array]",ee="[object Uint8ClampedArray]",se="[object Uint16Array]",de="[object Uint32Array]",ye={};ye[$]=ye[M]=ye[oe]=ye[Q]=ye[A]=ye[N]=ye[fe]=ye[ce]=ye[ae]=ye[W]=ye[te]=ye[z]=ye[q]=ye[K]=ye[G]=ye[Y]=ye[Z]=ye[me]=ye[ue]=ye[ee]=ye[se]=ye[de]=!0,ye[V]=ye[R]=ye[he]=!1;function _e(Se,Me,Fe,je,Je,De){var ct,Ct=Me&O,Xt=Me&L,Sn=Me&P;if(Fe&&(ct=Je?Fe(Se,je,Je,De):Fe(Se)),ct!==void 0)return ct;if(!T(Se))return Se;var un=b(Se);if(un){if(ct=g(Se),!Ct)return s(Se,ct)}else{var $t=p(Se),In=$t==R||$t==B;if(S(Se))return i(Se,Ct);if($t==K||$t==$||In&&!Je){if(ct=Xt||In?{}:y(Se),!Ct)return Xt?l(Se,o(ct,Se)):a(Se,r(ct,Se))}else{if(!ye[$t])return Je?Se:{};ct=m(Se,$t,Ct)}}De||(De=new t);var Kn=De.get(Se);if(Kn)return Kn;De.set(Se,ct),_(Se)?Se.forEach(function(Yt){ct.add(_e(Yt,Me,Fe,Yt,Se,De))}):C(Se)&&Se.forEach(function(Yt,ge){ct.set(ge,_e(Yt,Me,Fe,ge,Se,De))});var ft=Sn?Xt?f:u:Xt?E:w,$n=un?void 0:ft(Se);return e($n||Se,function(Yt,ge){$n&&(ge=Yt,Yt=Se[ge]),n(ct,ge,_e(Yt,Me,Fe,ge,Se,De))}),ct}return c0=_e,c0}var u0,_A;function yG(){if(_A)return u0;_A=1;var t=Bs(),e=Yu(),n=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,r=/^\w*$/;function o(i,s){if(t(i))return!1;var a=typeof i;return a=="number"||a=="symbol"||a=="boolean"||i==null||e(i)?!0:r.test(i)||!n.test(i)||s!=null&&i in Object(s)}return u0=o,u0}var d0,TA;function bG(){if(TA)return d0;TA=1;var t=eO(),e="Expected a function";function n(r,o){if(typeof r!="function"||o!=null&&typeof o!="function")throw new TypeError(e);var i=function(){var s=arguments,a=o?o.apply(this,s):s[0],l=i.cache;if(l.has(a))return l.get(a);var u=r.apply(this,s);return i.cache=l.set(a,u)||l,u};return i.cache=new(n.Cache||t),i}return n.Cache=t,d0=n,d0}var f0,kA;function vG(){if(kA)return f0;kA=1;var t=bG(),e=500;function n(r){var o=t(r,function(s){return i.size===e&&i.clear(),s}),i=o.cache;return o}return f0=n,f0}var p0,EA;function xG(){if(EA)return p0;EA=1;var t=vG(),e=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,n=/\\(\\)?/g,r=t(function(o){var i=[];return o.charCodeAt(0)===46&&i.push(""),o.replace(e,function(s,a,l,u){i.push(l?u.replace(n,"$1"):a||s)}),i});return p0=r,p0}var h0,MA;function OA(){if(MA)return h0;MA=1;var t=Ll(),e=gM(),n=Bs(),r=Yu(),o=1/0,i=t?t.prototype:void 0,s=i?i.toString:void 0;function a(l){if(typeof l=="string")return l;if(n(l))return e(l,a)+"";if(r(l))return s?s.call(l):"";var u=l+"";return u=="0"&&1/l==-o?"-0":u}return h0=a,h0}var g0,AA;function IA(){if(AA)return g0;AA=1;var t=OA();function e(n){return n==null?"":t(n)}return g0=e,g0}var m0,DA;function y0(){if(DA)return m0;DA=1;var t=Bs(),e=yG(),n=xG(),r=IA();function o(i,s){return t(i)?i:e(i,s)?[i]:n(r(i))}return m0=o,m0}var b0,PA;function SG(){if(PA)return b0;PA=1;function t(e){var n=e==null?0:e.length;return n?e[n-1]:void 0}return b0=t,b0}var v0,NA;function LA(){if(NA)return v0;NA=1;var t=Yu(),e=1/0;function n(r){if(typeof r=="string"||t(r))return r;var o=r+"";return o=="0"&&1/r==-e?"-0":o}return v0=n,v0}var x0,FA;function CG(){if(FA)return x0;FA=1;var t=y0(),e=LA();function n(r,o){o=t(o,r);for(var i=0,s=o.length;r!=null&&i<s;)r=r[e(o[i++])];return i&&i==s?r:void 0}return x0=n,x0}var S0,$A;function BA(){if($A)return S0;$A=1;function t(e,n,r){var o=-1,i=e.length;n<0&&(n=-n>i?0:i+n),r=r>i?i:r,r<0&&(r+=i),i=n>r?0:r-n>>>0,n>>>=0;for(var s=Array(i);++o<i;)s[o]=e[o+n];return s}return S0=t,S0}var C0,RA;function wG(){if(RA)return C0;RA=1;var t=CG(),e=BA();function n(r,o){return o.length<2?r:t(r,e(o,0,-1))}return C0=n,C0}var w0,zA;function _G(){if(zA)return w0;zA=1;var t=y0(),e=SG(),n=wG(),r=LA();function o(i,s){return s=t(s,i),i=n(i,s),i==null||delete i[r(e(s))]}return w0=o,w0}var _0,VA;function TG(){if(VA)return _0;VA=1;var t=us(),e=Fb(),n=Ci(),r="[object Object]",o=Function.prototype,i=Object.prototype,s=o.toString,a=i.hasOwnProperty,l=s.call(Object);function u(f){if(!n(f)||t(f)!=r)return!1;var p=e(f);if(p===null)return!0;var g=a.call(p,"constructor")&&p.constructor;return typeof g=="function"&&g instanceof g&&s.call(g)==l}return _0=u,_0}var T0,HA;function kG(){if(HA)return T0;HA=1;var t=TG();function e(n){return t(n)?void 0:n}return T0=e,T0}var k0,jA;function EG(){if(jA)return k0;jA=1;var t=Ll(),e=hO(),n=Bs(),r=t?t.isConcatSpreadable:void 0;function o(i){return n(i)||e(i)||!!(r&&i&&i[r])}return k0=o,k0}var E0,WA;function MG(){if(WA)return E0;WA=1;var t=Nb(),e=EG();function n(r,o,i,s,a){var l=-1,u=r.length;for(i||(i=e),a||(a=[]);++l<u;){var f=r[l];o>0&&i(f)?o>1?n(f,o-1,i,s,a):t(a,f):s||(a[a.length]=f)}return a}return E0=n,E0}var M0,qA;function OG(){if(qA)return M0;qA=1;var t=MG();function e(n){var r=n==null?0:n.length;return r?t(n,1):[]}return M0=e,M0}var O0,UA;function AG(){if(UA)return O0;UA=1;function t(e,n,r){switch(r.length){case 0:return e.call(n);case 1:return e.call(n,r[0]);case 2:return e.call(n,r[0],r[1]);case 3:return e.call(n,r[0],r[1],r[2])}return e.apply(n,r)}return O0=t,O0}var A0,KA;function IG(){if(KA)return A0;KA=1;var t=AG(),e=Math.max;function n(r,o,i){return o=e(o===void 0?r.length-1:o,0),function(){for(var s=arguments,a=-1,l=e(s.length-o,0),u=Array(l);++a<l;)u[a]=s[o+a];a=-1;for(var f=Array(o+1);++a<o;)f[a]=s[a];return f[o]=i(u),t(r,this,f)}}return A0=n,A0}var I0,YA;function DG(){if(YA)return I0;YA=1;function t(e){return function(){return e}}return I0=t,I0}var D0,GA;function PG(){if(GA)return D0;GA=1;function t(e){return e}return D0=t,D0}var P0,JA;function NG(){if(JA)return P0;JA=1;var t=DG(),e=iO(),n=PG(),r=e?function(o,i){return e(o,"toString",{configurable:!0,enumerable:!1,value:t(i),writable:!0})}:n;return P0=r,P0}var N0,ZA;function LG(){if(ZA)return N0;ZA=1;var t=800,e=16,n=Date.now;function r(o){var i=0,s=0;return function(){var a=n(),l=e-(a-s);if(s=a,l>0){if(++i>=t)return arguments[0]}else i=0;return o.apply(void 0,arguments)}}return N0=r,N0}var L0,XA;function FG(){if(XA)return L0;XA=1;var t=NG(),e=LG(),n=e(t);return L0=n,L0}var F0,QA;function $G(){if(QA)return F0;QA=1;var t=OG(),e=IG(),n=FG();function r(o){return n(e(o,void 0,t),o+"")}return F0=r,F0}var $0,e2;function BG(){if(e2)return $0;e2=1;var t=gM(),e=mG(),n=_G(),r=y0(),o=Lc(),i=kG(),s=$G(),a=rA(),l=1,u=2,f=4,p=s(function(g,m){var y={};if(g==null)return y;var b=!1;m=t(m,function(C){return C=r(C,g),b||(b=C.length>1),C}),o(g,a(g),y),b&&(y=e(y,l|u|f,i));for(var S=m.length;S--;)n(y,m[S]);return y});return $0=p,$0}var RG=BG();const qa=Zn(RG),Of={TABLE_ELEMENT:1,MENU_BAR:2,NOTCHED_OUTLINE:2};function t2(t){const e=Object.keys(t.typography.h1).some(r=>r.includes("@media")),n=to.keyframes`
|
|
327
|
+
`,'Use: tss.withName("UniqueName").withNestedSelectors<...>()...'].join(" "))}return P[N]=`${w.key}-${i!==void 0?i:l}-${N}-ref`}})}:{}});let M=nM(Hi($).map(A=>{const N=$[A];return N.label||(N.label=`${i!==void 0?`${i}-`:""}${A}`),[A,`${T(N)}${cy(A,A in P)?` ${P[A]}`:""}`]}));return Hi(P).forEach(A=>{A in M||(M[A]=P[A])}),M=dy(M,b,_),M},O=rY({cache:w,cssObjectByRuleNameOrGetCssObjectByRuleName:a,classesOverridesRef:ji(b),paramsAndPluginParamsRef:ji(S),idOfUseStyles:l,context:C,getClasses:E}),L=o({classes:O,css:T,cx:_,idOfUseStyles:l,name:i,...C,...S});return{classes:(g=L.classes)!==null&&g!==void 0?g:O,css:(m=L.css)!==null&&m!==void 0?m:T,cx:(y=L.cx)!==null&&y!==void 0?y:_,...C}}}}}const Cf=new WeakMap;function rY(t){const{cache:e,cssObjectByRuleNameOrGetCssObjectByRuleName:n,classesOverridesRef:r,paramsAndPluginParamsRef:o,idOfUseStyles:i,context:s,getClasses:a}=t;e:{const u=Cf.get(e);if(u===void 0)break e;const f=u.get(n);if(f===void 0)break e;const p=f.get(r);if(p===void 0)break e;const g=p.get(o);if(g===void 0)break e;const m=g.find(({context:y})=>{if(y===s)return!0;if(Hi(y).length!==Hi(s).length)return!1;for(const b in y)if(ji(y[b])!==ji(s[b]))return!1;return!0});if(m===void 0)break e;if((m==null?void 0:m.idOfUseStyles)!==i){g.splice(g.indexOf(m),1);break e}return m.result}const l=a();{Cf.has(e)||Cf.set(e,new WeakMap);const u=Cf.get(e);Fs(u!==void 0),u.has(n)||u.set(n,new Map);const f=u.get(n);Fs(f!==void 0),f.has(r)||(f.size>200&&f.clear(),f.set(r,new Map));const p=f.get(r);if(Fs(p!==void 0),!p.has(o)){e:{const m=typeof o=="string"?257:5;if(p.size<m)break e;p.clear()}p.set(o,[])}let g=p.get(o);Fs(g!==void 0),g.length>5&&(g=[]),g.push({idOfUseStyles:i,context:s,result:l})}return l}function oY(t){return{...sM(t),...eY(t)}}const{tss:iY}=fM({useContext:()=>({})});iY.create({});const{makeStyles:Ut,withStyles:Rpe}=oY({useTheme:Si}),{tss:sY}=fM({useContext:function(){return{theme:Si()}},usePlugin:iM});sY.create({});var fy,hM;function gM(){if(hM)return fy;hM=1;function t(e,n){for(var r=-1,o=e==null?0:e.length,i=Array(o);++r<o;)i[r]=n(e[r],r,e);return i}return fy=t,fy}var py,mM;function aY(){if(mM)return py;mM=1;function t(){this.__data__=[],this.size=0}return py=t,py}var hy,yM;function bM(){if(yM)return hy;yM=1;function t(e,n){return e===n||e!==e&&n!==n}return hy=t,hy}var gy,vM;function wf(){if(vM)return gy;vM=1;var t=bM();function e(n,r){for(var o=n.length;o--;)if(t(n[o][0],r))return o;return-1}return gy=e,gy}var my,xM;function lY(){if(xM)return my;xM=1;var t=wf(),e=Array.prototype,n=e.splice;function r(o){var i=this.__data__,s=t(i,o);if(s<0)return!1;var a=i.length-1;return s==a?i.pop():n.call(i,s,1),--this.size,!0}return my=r,my}var yy,SM;function cY(){if(SM)return yy;SM=1;var t=wf();function e(n){var r=this.__data__,o=t(r,n);return o<0?void 0:r[o][1]}return yy=e,yy}var by,CM;function uY(){if(CM)return by;CM=1;var t=wf();function e(n){return t(this.__data__,n)>-1}return by=e,by}var vy,wM;function dY(){if(wM)return vy;wM=1;var t=wf();function e(n,r){var o=this.__data__,i=t(o,n);return i<0?(++this.size,o.push([n,r])):o[i][1]=r,this}return vy=e,vy}var xy,_M;function _f(){if(_M)return xy;_M=1;var t=aY(),e=lY(),n=cY(),r=uY(),o=dY();function i(s){var a=-1,l=s==null?0:s.length;for(this.clear();++a<l;){var u=s[a];this.set(u[0],u[1])}}return i.prototype.clear=t,i.prototype.delete=e,i.prototype.get=n,i.prototype.has=r,i.prototype.set=o,xy=i,xy}var Sy,TM;function fY(){if(TM)return Sy;TM=1;var t=_f();function e(){this.__data__=new t,this.size=0}return Sy=e,Sy}var Cy,kM;function pY(){if(kM)return Cy;kM=1;function t(e){var n=this.__data__,r=n.delete(e);return this.size=n.size,r}return Cy=t,Cy}var wy,EM;function hY(){if(EM)return wy;EM=1;function t(e){return this.__data__.get(e)}return wy=t,wy}var _y,MM;function gY(){if(MM)return _y;MM=1;function t(e){return this.__data__.has(e)}return _y=t,_y}var Ty,OM;function AM(){if(OM)return Ty;OM=1;var t=us(),e=Uo(),n="[object AsyncFunction]",r="[object Function]",o="[object GeneratorFunction]",i="[object Proxy]";function s(a){if(!e(a))return!1;var l=t(a);return l==r||l==o||l==n||l==i}return Ty=s,Ty}var ky,IM;function mY(){if(IM)return ky;IM=1;var t=oo(),e=t["__core-js_shared__"];return ky=e,ky}var Ey,DM;function yY(){if(DM)return Ey;DM=1;var t=mY(),e=function(){var r=/[^.]+$/.exec(t&&t.keys&&t.keys.IE_PROTO||"");return r?"Symbol(src)_1."+r:""}();function n(r){return!!e&&e in r}return Ey=n,Ey}var My,PM;function NM(){if(PM)return My;PM=1;var t=Function.prototype,e=t.toString;function n(r){if(r!=null){try{return e.call(r)}catch{}try{return r+""}catch{}}return""}return My=n,My}var Oy,LM;function bY(){if(LM)return Oy;LM=1;var t=AM(),e=yY(),n=Uo(),r=NM(),o=/[\\^$.*+?()[\]{}|]/g,i=/^\[object .+?Constructor\]$/,s=Function.prototype,a=Object.prototype,l=s.toString,u=a.hasOwnProperty,f=RegExp("^"+l.call(u).replace(o,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function p(g){if(!n(g)||e(g))return!1;var m=t(g)?f:i;return m.test(r(g))}return Oy=p,Oy}var Ay,FM;function vY(){if(FM)return Ay;FM=1;function t(e,n){return e==null?void 0:e[n]}return Ay=t,Ay}var Iy,$M;function $s(){if($M)return Iy;$M=1;var t=bY(),e=vY();function n(r,o){var i=e(r,o);return t(i)?i:void 0}return Iy=n,Iy}var Dy,BM;function Py(){if(BM)return Dy;BM=1;var t=$s(),e=oo(),n=t(e,"Map");return Dy=n,Dy}var Ny,RM;function Tf(){if(RM)return Ny;RM=1;var t=$s(),e=t(Object,"create");return Ny=e,Ny}var Ly,zM;function xY(){if(zM)return Ly;zM=1;var t=Tf();function e(){this.__data__=t?t(null):{},this.size=0}return Ly=e,Ly}var Fy,VM;function SY(){if(VM)return Fy;VM=1;function t(e){var n=this.has(e)&&delete this.__data__[e];return this.size-=n?1:0,n}return Fy=t,Fy}var $y,HM;function CY(){if(HM)return $y;HM=1;var t=Tf(),e="__lodash_hash_undefined__",n=Object.prototype,r=n.hasOwnProperty;function o(i){var s=this.__data__;if(t){var a=s[i];return a===e?void 0:a}return r.call(s,i)?s[i]:void 0}return $y=o,$y}var By,jM;function wY(){if(jM)return By;jM=1;var t=Tf(),e=Object.prototype,n=e.hasOwnProperty;function r(o){var i=this.__data__;return t?i[o]!==void 0:n.call(i,o)}return By=r,By}var Ry,WM;function _Y(){if(WM)return Ry;WM=1;var t=Tf(),e="__lodash_hash_undefined__";function n(r,o){var i=this.__data__;return this.size+=this.has(r)?0:1,i[r]=t&&o===void 0?e:o,this}return Ry=n,Ry}var zy,qM;function TY(){if(qM)return zy;qM=1;var t=xY(),e=SY(),n=CY(),r=wY(),o=_Y();function i(s){var a=-1,l=s==null?0:s.length;for(this.clear();++a<l;){var u=s[a];this.set(u[0],u[1])}}return i.prototype.clear=t,i.prototype.delete=e,i.prototype.get=n,i.prototype.has=r,i.prototype.set=o,zy=i,zy}var Vy,UM;function kY(){if(UM)return Vy;UM=1;var t=TY(),e=_f(),n=Py();function r(){this.size=0,this.__data__={hash:new t,map:new(n||e),string:new t}}return Vy=r,Vy}var Hy,KM;function EY(){if(KM)return Hy;KM=1;function t(e){var n=typeof e;return n=="string"||n=="number"||n=="symbol"||n=="boolean"?e!=="__proto__":e===null}return Hy=t,Hy}var jy,YM;function kf(){if(YM)return jy;YM=1;var t=EY();function e(n,r){var o=n.__data__;return t(r)?o[typeof r=="string"?"string":"hash"]:o.map}return jy=e,jy}var Wy,GM;function MY(){if(GM)return Wy;GM=1;var t=kf();function e(n){var r=t(this,n).delete(n);return this.size-=r?1:0,r}return Wy=e,Wy}var qy,JM;function OY(){if(JM)return qy;JM=1;var t=kf();function e(n){return t(this,n).get(n)}return qy=e,qy}var Uy,ZM;function AY(){if(ZM)return Uy;ZM=1;var t=kf();function e(n){return t(this,n).has(n)}return Uy=e,Uy}var Ky,XM;function IY(){if(XM)return Ky;XM=1;var t=kf();function e(n,r){var o=t(this,n),i=o.size;return o.set(n,r),this.size+=o.size==i?0:1,this}return Ky=e,Ky}var Yy,QM;function eO(){if(QM)return Yy;QM=1;var t=kY(),e=MY(),n=OY(),r=AY(),o=IY();function i(s){var a=-1,l=s==null?0:s.length;for(this.clear();++a<l;){var u=s[a];this.set(u[0],u[1])}}return i.prototype.clear=t,i.prototype.delete=e,i.prototype.get=n,i.prototype.has=r,i.prototype.set=o,Yy=i,Yy}var Gy,tO;function DY(){if(tO)return Gy;tO=1;var t=_f(),e=Py(),n=eO(),r=200;function o(i,s){var a=this.__data__;if(a instanceof t){var l=a.__data__;if(!e||l.length<r-1)return l.push([i,s]),this.size=++a.size,this;a=this.__data__=new n(l)}return a.set(i,s),this.size=a.size,this}return Gy=o,Gy}var Jy,nO;function PY(){if(nO)return Jy;nO=1;var t=_f(),e=fY(),n=pY(),r=hY(),o=gY(),i=DY();function s(a){var l=this.__data__=new t(a);this.size=l.size}return s.prototype.clear=e,s.prototype.delete=n,s.prototype.get=r,s.prototype.has=o,s.prototype.set=i,Jy=s,Jy}var Zy,rO;function NY(){if(rO)return Zy;rO=1;function t(e,n){for(var r=-1,o=e==null?0:e.length;++r<o&&n(e[r],r,e)!==!1;);return e}return Zy=t,Zy}var Xy,oO;function iO(){if(oO)return Xy;oO=1;var t=$s(),e=function(){try{var n=t(Object,"defineProperty");return n({},"",{}),n}catch{}}();return Xy=e,Xy}var Qy,sO;function aO(){if(sO)return Qy;sO=1;var t=iO();function e(n,r,o){r=="__proto__"&&t?t(n,r,{configurable:!0,enumerable:!0,value:o,writable:!0}):n[r]=o}return Qy=e,Qy}var eb,lO;function cO(){if(lO)return eb;lO=1;var t=aO(),e=bM(),n=Object.prototype,r=n.hasOwnProperty;function o(i,s,a){var l=i[s];(!(r.call(i,s)&&e(l,a))||a===void 0&&!(s in i))&&t(i,s,a)}return eb=o,eb}var tb,uO;function Lc(){if(uO)return tb;uO=1;var t=cO(),e=aO();function n(r,o,i,s){var a=!i;i||(i={});for(var l=-1,u=o.length;++l<u;){var f=o[l],p=s?s(i[f],r[f],f,i,r):void 0;p===void 0&&(p=r[f]),a?e(i,f,p):t(i,f,p)}return i}return tb=n,tb}var nb,dO;function LY(){if(dO)return nb;dO=1;function t(e,n){for(var r=-1,o=Array(e);++r<e;)o[r]=n(r);return o}return nb=t,nb}var rb,fO;function FY(){if(fO)return rb;fO=1;var t=us(),e=Ci(),n="[object Arguments]";function r(o){return e(o)&&t(o)==n}return rb=r,rb}var ob,pO;function hO(){if(pO)return ob;pO=1;var t=FY(),e=Ci(),n=Object.prototype,r=n.hasOwnProperty,o=n.propertyIsEnumerable,i=t(function(){return arguments}())?t:function(s){return e(s)&&r.call(s,"callee")&&!o.call(s,"callee")};return ob=i,ob}var ib,gO;function Bs(){if(gO)return ib;gO=1;var t=Array.isArray;return ib=t,ib}var Fc={exports:{}},sb,mO;function $Y(){if(mO)return sb;mO=1;function t(){return!1}return sb=t,sb}Fc.exports;var yO;function bO(){return yO||(yO=1,function(t,e){var n=oo(),r=$Y(),o=e&&!e.nodeType&&e,i=o&&!0&&t&&!t.nodeType&&t,s=i&&i.exports===o,a=s?n.Buffer:void 0,l=a?a.isBuffer:void 0,u=l||r;t.exports=u}(Fc,Fc.exports)),Fc.exports}var ab,vO;function BY(){if(vO)return ab;vO=1;var t=9007199254740991,e=/^(?:0|[1-9]\d*)$/;function n(r,o){var i=typeof r;return o=o??t,!!o&&(i=="number"||i!="symbol"&&e.test(r))&&r>-1&&r%1==0&&r<o}return ab=n,ab}var lb,xO;function SO(){if(xO)return lb;xO=1;var t=9007199254740991;function e(n){return typeof n=="number"&&n>-1&&n%1==0&&n<=t}return lb=e,lb}var cb,CO;function RY(){if(CO)return cb;CO=1;var t=us(),e=SO(),n=Ci(),r="[object Arguments]",o="[object Array]",i="[object Boolean]",s="[object Date]",a="[object Error]",l="[object Function]",u="[object Map]",f="[object Number]",p="[object Object]",g="[object RegExp]",m="[object Set]",y="[object String]",b="[object WeakMap]",S="[object ArrayBuffer]",C="[object DataView]",T="[object Float32Array]",_="[object Float64Array]",w="[object Int8Array]",E="[object Int16Array]",O="[object Int32Array]",L="[object Uint8Array]",P="[object Uint8ClampedArray]",$="[object Uint16Array]",M="[object Uint32Array]",A={};A[T]=A[_]=A[w]=A[E]=A[O]=A[L]=A[P]=A[$]=A[M]=!0,A[r]=A[o]=A[S]=A[i]=A[C]=A[s]=A[a]=A[l]=A[u]=A[f]=A[p]=A[g]=A[m]=A[y]=A[b]=!1;function N(z){return n(z)&&e(z.length)&&!!A[t(z)]}return cb=N,cb}var ub,wO;function Ef(){if(wO)return ub;wO=1;function t(e){return function(n){return e(n)}}return ub=t,ub}var $c={exports:{}};$c.exports;var _O;function Mf(){return _O||(_O=1,function(t,e){var n=bC(),r=e&&!e.nodeType&&e,o=r&&!0&&t&&!t.nodeType&&t,i=o&&o.exports===r,s=i&&n.process,a=function(){try{var l=o&&o.require&&o.require("util").types;return l||s&&s.binding&&s.binding("util")}catch{}}();t.exports=a}($c,$c.exports)),$c.exports}var db,TO;function zY(){if(TO)return db;TO=1;var t=RY(),e=Ef(),n=Mf(),r=n&&n.isTypedArray,o=r?e(r):t;return db=o,db}var fb,kO;function EO(){if(kO)return fb;kO=1;var t=LY(),e=hO(),n=Bs(),r=bO(),o=BY(),i=zY(),s=Object.prototype,a=s.hasOwnProperty;function l(u,f){var p=n(u),g=!p&&e(u),m=!p&&!g&&r(u),y=!p&&!g&&!m&&i(u),b=p||g||m||y,S=b?t(u.length,String):[],C=S.length;for(var T in u)(f||a.call(u,T))&&!(b&&(T=="length"||m&&(T=="offset"||T=="parent")||y&&(T=="buffer"||T=="byteLength"||T=="byteOffset")||o(T,C)))&&S.push(T);return S}return fb=l,fb}var pb,MO;function hb(){if(MO)return pb;MO=1;var t=Object.prototype;function e(n){var r=n&&n.constructor,o=typeof r=="function"&&r.prototype||t;return n===o}return pb=e,pb}var gb,OO;function AO(){if(OO)return gb;OO=1;function t(e,n){return function(r){return e(n(r))}}return gb=t,gb}var mb,IO;function VY(){if(IO)return mb;IO=1;var t=AO(),e=t(Object.keys,Object);return mb=e,mb}var yb,DO;function HY(){if(DO)return yb;DO=1;var t=hb(),e=VY(),n=Object.prototype,r=n.hasOwnProperty;function o(i){if(!t(i))return e(i);var s=[];for(var a in Object(i))r.call(i,a)&&a!="constructor"&&s.push(a);return s}return yb=o,yb}var bb,PO;function NO(){if(PO)return bb;PO=1;var t=AM(),e=SO();function n(r){return r!=null&&e(r.length)&&!t(r)}return bb=n,bb}var vb,LO;function xb(){if(LO)return vb;LO=1;var t=EO(),e=HY(),n=NO();function r(o){return n(o)?t(o):e(o)}return vb=r,vb}var Sb,FO;function jY(){if(FO)return Sb;FO=1;var t=Lc(),e=xb();function n(r,o){return r&&t(o,e(o),r)}return Sb=n,Sb}var Cb,$O;function WY(){if($O)return Cb;$O=1;function t(e){var n=[];if(e!=null)for(var r in Object(e))n.push(r);return n}return Cb=t,Cb}var wb,BO;function qY(){if(BO)return wb;BO=1;var t=Uo(),e=hb(),n=WY(),r=Object.prototype,o=r.hasOwnProperty;function i(s){if(!t(s))return n(s);var a=e(s),l=[];for(var u in s)u=="constructor"&&(a||!o.call(s,u))||l.push(u);return l}return wb=i,wb}var _b,RO;function Tb(){if(RO)return _b;RO=1;var t=EO(),e=qY(),n=NO();function r(o){return n(o)?t(o,!0):e(o)}return _b=r,_b}var kb,zO;function UY(){if(zO)return kb;zO=1;var t=Lc(),e=Tb();function n(r,o){return r&&t(o,e(o),r)}return kb=n,kb}var Bc={exports:{}};Bc.exports;var VO;function KY(){return VO||(VO=1,function(t,e){var n=oo(),r=e&&!e.nodeType&&e,o=r&&!0&&t&&!t.nodeType&&t,i=o&&o.exports===r,s=i?n.Buffer:void 0,a=s?s.allocUnsafe:void 0;function l(u,f){if(f)return u.slice();var p=u.length,g=a?a(p):new u.constructor(p);return u.copy(g),g}t.exports=l}(Bc,Bc.exports)),Bc.exports}var Eb,HO;function YY(){if(HO)return Eb;HO=1;function t(e,n){var r=-1,o=e.length;for(n||(n=Array(o));++r<o;)n[r]=e[r];return n}return Eb=t,Eb}var Mb,jO;function GY(){if(jO)return Mb;jO=1;function t(e,n){for(var r=-1,o=e==null?0:e.length,i=0,s=[];++r<o;){var a=e[r];n(a,r,e)&&(s[i++]=a)}return s}return Mb=t,Mb}var Ob,WO;function qO(){if(WO)return Ob;WO=1;function t(){return[]}return Ob=t,Ob}var Ab,UO;function Ib(){if(UO)return Ab;UO=1;var t=GY(),e=qO(),n=Object.prototype,r=n.propertyIsEnumerable,o=Object.getOwnPropertySymbols,i=o?function(s){return s==null?[]:(s=Object(s),t(o(s),function(a){return r.call(s,a)}))}:e;return Ab=i,Ab}var Db,KO;function JY(){if(KO)return Db;KO=1;var t=Lc(),e=Ib();function n(r,o){return t(r,e(r),o)}return Db=n,Db}var Pb,YO;function Nb(){if(YO)return Pb;YO=1;function t(e,n){for(var r=-1,o=n.length,i=e.length;++r<o;)e[i+r]=n[r];return e}return Pb=t,Pb}var Lb,GO;function Fb(){if(GO)return Lb;GO=1;var t=AO(),e=t(Object.getPrototypeOf,Object);return Lb=e,Lb}var $b,JO;function ZO(){if(JO)return $b;JO=1;var t=Nb(),e=Fb(),n=Ib(),r=qO(),o=Object.getOwnPropertySymbols,i=o?function(s){for(var a=[];s;)t(a,n(s)),s=e(s);return a}:r;return $b=i,$b}var Bb,XO;function ZY(){if(XO)return Bb;XO=1;var t=Lc(),e=ZO();function n(r,o){return t(r,e(r),o)}return Bb=n,Bb}var Rb,QO;function eA(){if(QO)return Rb;QO=1;var t=Nb(),e=Bs();function n(r,o,i){var s=o(r);return e(r)?s:t(s,i(r))}return Rb=n,Rb}var zb,tA;function XY(){if(tA)return zb;tA=1;var t=eA(),e=Ib(),n=xb();function r(o){return t(o,n,e)}return zb=r,zb}var Vb,nA;function rA(){if(nA)return Vb;nA=1;var t=eA(),e=ZO(),n=Tb();function r(o){return t(o,n,e)}return Vb=r,Vb}var Hb,oA;function QY(){if(oA)return Hb;oA=1;var t=$s(),e=oo(),n=t(e,"DataView");return Hb=n,Hb}var jb,iA;function eG(){if(iA)return jb;iA=1;var t=$s(),e=oo(),n=t(e,"Promise");return jb=n,jb}var Wb,sA;function tG(){if(sA)return Wb;sA=1;var t=$s(),e=oo(),n=t(e,"Set");return Wb=n,Wb}var qb,aA;function nG(){if(aA)return qb;aA=1;var t=$s(),e=oo(),n=t(e,"WeakMap");return qb=n,qb}var Ub,lA;function Kb(){if(lA)return Ub;lA=1;var t=QY(),e=Py(),n=eG(),r=tG(),o=nG(),i=us(),s=NM(),a="[object Map]",l="[object Object]",u="[object Promise]",f="[object Set]",p="[object WeakMap]",g="[object DataView]",m=s(t),y=s(e),b=s(n),S=s(r),C=s(o),T=i;return(t&&T(new t(new ArrayBuffer(1)))!=g||e&&T(new e)!=a||n&&T(n.resolve())!=u||r&&T(new r)!=f||o&&T(new o)!=p)&&(T=function(_){var w=i(_),E=w==l?_.constructor:void 0,O=E?s(E):"";if(O)switch(O){case m:return g;case y:return a;case b:return u;case S:return f;case C:return p}return w}),Ub=T,Ub}var Yb,cA;function rG(){if(cA)return Yb;cA=1;var t=Object.prototype,e=t.hasOwnProperty;function n(r){var o=r.length,i=new r.constructor(o);return o&&typeof r[0]=="string"&&e.call(r,"index")&&(i.index=r.index,i.input=r.input),i}return Yb=n,Yb}var Gb,uA;function oG(){if(uA)return Gb;uA=1;var t=oo(),e=t.Uint8Array;return Gb=e,Gb}var Jb,dA;function Zb(){if(dA)return Jb;dA=1;var t=oG();function e(n){var r=new n.constructor(n.byteLength);return new t(r).set(new t(n)),r}return Jb=e,Jb}var Xb,fA;function iG(){if(fA)return Xb;fA=1;var t=Zb();function e(n,r){var o=r?t(n.buffer):n.buffer;return new n.constructor(o,n.byteOffset,n.byteLength)}return Xb=e,Xb}var Qb,pA;function sG(){if(pA)return Qb;pA=1;var t=/\w*$/;function e(n){var r=new n.constructor(n.source,t.exec(n));return r.lastIndex=n.lastIndex,r}return Qb=e,Qb}var e0,hA;function aG(){if(hA)return e0;hA=1;var t=Ll(),e=t?t.prototype:void 0,n=e?e.valueOf:void 0;function r(o){return n?Object(n.call(o)):{}}return e0=r,e0}var t0,gA;function lG(){if(gA)return t0;gA=1;var t=Zb();function e(n,r){var o=r?t(n.buffer):n.buffer;return new n.constructor(o,n.byteOffset,n.length)}return t0=e,t0}var n0,mA;function cG(){if(mA)return n0;mA=1;var t=Zb(),e=iG(),n=sG(),r=aG(),o=lG(),i="[object Boolean]",s="[object Date]",a="[object Map]",l="[object Number]",u="[object RegExp]",f="[object Set]",p="[object String]",g="[object Symbol]",m="[object ArrayBuffer]",y="[object DataView]",b="[object Float32Array]",S="[object Float64Array]",C="[object Int8Array]",T="[object Int16Array]",_="[object Int32Array]",w="[object Uint8Array]",E="[object Uint8ClampedArray]",O="[object Uint16Array]",L="[object Uint32Array]";function P($,M,A){var N=$.constructor;switch(M){case m:return t($);case i:case s:return new N(+$);case y:return e($,A);case b:case S:case C:case T:case _:case w:case E:case O:case L:return o($,A);case a:return new N;case l:case p:return new N($);case u:return n($);case f:return new N;case g:return r($)}}return n0=P,n0}var r0,yA;function uG(){if(yA)return r0;yA=1;var t=Uo(),e=Object.create,n=function(){function r(){}return function(o){if(!t(o))return{};if(e)return e(o);r.prototype=o;var i=new r;return r.prototype=void 0,i}}();return r0=n,r0}var o0,bA;function dG(){if(bA)return o0;bA=1;var t=uG(),e=Fb(),n=hb();function r(o){return typeof o.constructor=="function"&&!n(o)?t(e(o)):{}}return o0=r,o0}var i0,vA;function fG(){if(vA)return i0;vA=1;var t=Kb(),e=Ci(),n="[object Map]";function r(o){return e(o)&&t(o)==n}return i0=r,i0}var s0,xA;function pG(){if(xA)return s0;xA=1;var t=fG(),e=Ef(),n=Mf(),r=n&&n.isMap,o=r?e(r):t;return s0=o,s0}var a0,SA;function hG(){if(SA)return a0;SA=1;var t=Kb(),e=Ci(),n="[object Set]";function r(o){return e(o)&&t(o)==n}return a0=r,a0}var l0,CA;function gG(){if(CA)return l0;CA=1;var t=hG(),e=Ef(),n=Mf(),r=n&&n.isSet,o=r?e(r):t;return l0=o,l0}var c0,wA;function mG(){if(wA)return c0;wA=1;var t=PY(),e=NY(),n=cO(),r=jY(),o=UY(),i=KY(),s=YY(),a=JY(),l=ZY(),u=XY(),f=rA(),p=Kb(),g=rG(),m=cG(),y=dG(),b=Bs(),S=bO(),C=pG(),T=Uo(),_=gG(),w=xb(),E=Tb(),O=1,L=2,P=4,$="[object Arguments]",M="[object Array]",A="[object Boolean]",N="[object Date]",z="[object Error]",V="[object Function]",B="[object GeneratorFunction]",R="[object Map]",q="[object Number]",U="[object Object]",G="[object RegExp]",Y="[object Set]",Z="[object String]",fe="[object Symbol]",pe="[object WeakMap]",me="[object ArrayBuffer]",re="[object DataView]",he="[object Float32Array]",le="[object Float64Array]",X="[object Int8Array]",W="[object Int16Array]",ee="[object Int32Array]",ce="[object Uint8Array]",te="[object Uint8ClampedArray]",se="[object Uint16Array]",ue="[object Uint32Array]",ye={};ye[$]=ye[M]=ye[me]=ye[re]=ye[A]=ye[N]=ye[he]=ye[le]=ye[X]=ye[W]=ye[ee]=ye[R]=ye[q]=ye[U]=ye[G]=ye[Y]=ye[Z]=ye[fe]=ye[ce]=ye[te]=ye[se]=ye[ue]=!0,ye[z]=ye[V]=ye[pe]=!1;function _e(Se,Me,Fe,je,Je,De){var ct,Ct=Me&O,Xt=Me&L,Sn=Me&P;if(Fe&&(ct=Je?Fe(Se,je,Je,De):Fe(Se)),ct!==void 0)return ct;if(!T(Se))return Se;var un=b(Se);if(un){if(ct=g(Se),!Ct)return s(Se,ct)}else{var $t=p(Se),In=$t==V||$t==B;if(S(Se))return i(Se,Ct);if($t==U||$t==$||In&&!Je){if(ct=Xt||In?{}:y(Se),!Ct)return Xt?l(Se,o(ct,Se)):a(Se,r(ct,Se))}else{if(!ye[$t])return Je?Se:{};ct=m(Se,$t,Ct)}}De||(De=new t);var Kn=De.get(Se);if(Kn)return Kn;De.set(Se,ct),_(Se)?Se.forEach(function(Yt){ct.add(_e(Yt,Me,Fe,Yt,Se,De))}):C(Se)&&Se.forEach(function(Yt,ge){ct.set(ge,_e(Yt,Me,Fe,ge,Se,De))});var ft=Sn?Xt?f:u:Xt?E:w,$n=un?void 0:ft(Se);return e($n||Se,function(Yt,ge){$n&&(ge=Yt,Yt=Se[ge]),n(ct,ge,_e(Yt,Me,Fe,ge,Se,De))}),ct}return c0=_e,c0}var u0,_A;function yG(){if(_A)return u0;_A=1;var t=Bs(),e=Yu(),n=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,r=/^\w*$/;function o(i,s){if(t(i))return!1;var a=typeof i;return a=="number"||a=="symbol"||a=="boolean"||i==null||e(i)?!0:r.test(i)||!n.test(i)||s!=null&&i in Object(s)}return u0=o,u0}var d0,TA;function bG(){if(TA)return d0;TA=1;var t=eO(),e="Expected a function";function n(r,o){if(typeof r!="function"||o!=null&&typeof o!="function")throw new TypeError(e);var i=function(){var s=arguments,a=o?o.apply(this,s):s[0],l=i.cache;if(l.has(a))return l.get(a);var u=r.apply(this,s);return i.cache=l.set(a,u)||l,u};return i.cache=new(n.Cache||t),i}return n.Cache=t,d0=n,d0}var f0,kA;function vG(){if(kA)return f0;kA=1;var t=bG(),e=500;function n(r){var o=t(r,function(s){return i.size===e&&i.clear(),s}),i=o.cache;return o}return f0=n,f0}var p0,EA;function xG(){if(EA)return p0;EA=1;var t=vG(),e=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,n=/\\(\\)?/g,r=t(function(o){var i=[];return o.charCodeAt(0)===46&&i.push(""),o.replace(e,function(s,a,l,u){i.push(l?u.replace(n,"$1"):a||s)}),i});return p0=r,p0}var h0,MA;function OA(){if(MA)return h0;MA=1;var t=Ll(),e=gM(),n=Bs(),r=Yu(),o=1/0,i=t?t.prototype:void 0,s=i?i.toString:void 0;function a(l){if(typeof l=="string")return l;if(n(l))return e(l,a)+"";if(r(l))return s?s.call(l):"";var u=l+"";return u=="0"&&1/l==-o?"-0":u}return h0=a,h0}var g0,AA;function IA(){if(AA)return g0;AA=1;var t=OA();function e(n){return n==null?"":t(n)}return g0=e,g0}var m0,DA;function y0(){if(DA)return m0;DA=1;var t=Bs(),e=yG(),n=xG(),r=IA();function o(i,s){return t(i)?i:e(i,s)?[i]:n(r(i))}return m0=o,m0}var b0,PA;function SG(){if(PA)return b0;PA=1;function t(e){var n=e==null?0:e.length;return n?e[n-1]:void 0}return b0=t,b0}var v0,NA;function LA(){if(NA)return v0;NA=1;var t=Yu(),e=1/0;function n(r){if(typeof r=="string"||t(r))return r;var o=r+"";return o=="0"&&1/r==-e?"-0":o}return v0=n,v0}var x0,FA;function CG(){if(FA)return x0;FA=1;var t=y0(),e=LA();function n(r,o){o=t(o,r);for(var i=0,s=o.length;r!=null&&i<s;)r=r[e(o[i++])];return i&&i==s?r:void 0}return x0=n,x0}var S0,$A;function BA(){if($A)return S0;$A=1;function t(e,n,r){var o=-1,i=e.length;n<0&&(n=-n>i?0:i+n),r=r>i?i:r,r<0&&(r+=i),i=n>r?0:r-n>>>0,n>>>=0;for(var s=Array(i);++o<i;)s[o]=e[o+n];return s}return S0=t,S0}var C0,RA;function wG(){if(RA)return C0;RA=1;var t=CG(),e=BA();function n(r,o){return o.length<2?r:t(r,e(o,0,-1))}return C0=n,C0}var w0,zA;function _G(){if(zA)return w0;zA=1;var t=y0(),e=SG(),n=wG(),r=LA();function o(i,s){return s=t(s,i),i=n(i,s),i==null||delete i[r(e(s))]}return w0=o,w0}var _0,VA;function TG(){if(VA)return _0;VA=1;var t=us(),e=Fb(),n=Ci(),r="[object Object]",o=Function.prototype,i=Object.prototype,s=o.toString,a=i.hasOwnProperty,l=s.call(Object);function u(f){if(!n(f)||t(f)!=r)return!1;var p=e(f);if(p===null)return!0;var g=a.call(p,"constructor")&&p.constructor;return typeof g=="function"&&g instanceof g&&s.call(g)==l}return _0=u,_0}var T0,HA;function kG(){if(HA)return T0;HA=1;var t=TG();function e(n){return t(n)?void 0:n}return T0=e,T0}var k0,jA;function EG(){if(jA)return k0;jA=1;var t=Ll(),e=hO(),n=Bs(),r=t?t.isConcatSpreadable:void 0;function o(i){return n(i)||e(i)||!!(r&&i&&i[r])}return k0=o,k0}var E0,WA;function MG(){if(WA)return E0;WA=1;var t=Nb(),e=EG();function n(r,o,i,s,a){var l=-1,u=r.length;for(i||(i=e),a||(a=[]);++l<u;){var f=r[l];o>0&&i(f)?o>1?n(f,o-1,i,s,a):t(a,f):s||(a[a.length]=f)}return a}return E0=n,E0}var M0,qA;function OG(){if(qA)return M0;qA=1;var t=MG();function e(n){var r=n==null?0:n.length;return r?t(n,1):[]}return M0=e,M0}var O0,UA;function AG(){if(UA)return O0;UA=1;function t(e,n,r){switch(r.length){case 0:return e.call(n);case 1:return e.call(n,r[0]);case 2:return e.call(n,r[0],r[1]);case 3:return e.call(n,r[0],r[1],r[2])}return e.apply(n,r)}return O0=t,O0}var A0,KA;function IG(){if(KA)return A0;KA=1;var t=AG(),e=Math.max;function n(r,o,i){return o=e(o===void 0?r.length-1:o,0),function(){for(var s=arguments,a=-1,l=e(s.length-o,0),u=Array(l);++a<l;)u[a]=s[o+a];a=-1;for(var f=Array(o+1);++a<o;)f[a]=s[a];return f[o]=i(u),t(r,this,f)}}return A0=n,A0}var I0,YA;function DG(){if(YA)return I0;YA=1;function t(e){return function(){return e}}return I0=t,I0}var D0,GA;function PG(){if(GA)return D0;GA=1;function t(e){return e}return D0=t,D0}var P0,JA;function NG(){if(JA)return P0;JA=1;var t=DG(),e=iO(),n=PG(),r=e?function(o,i){return e(o,"toString",{configurable:!0,enumerable:!1,value:t(i),writable:!0})}:n;return P0=r,P0}var N0,ZA;function LG(){if(ZA)return N0;ZA=1;var t=800,e=16,n=Date.now;function r(o){var i=0,s=0;return function(){var a=n(),l=e-(a-s);if(s=a,l>0){if(++i>=t)return arguments[0]}else i=0;return o.apply(void 0,arguments)}}return N0=r,N0}var L0,XA;function FG(){if(XA)return L0;XA=1;var t=NG(),e=LG(),n=e(t);return L0=n,L0}var F0,QA;function $G(){if(QA)return F0;QA=1;var t=OG(),e=IG(),n=FG();function r(o){return n(e(o,void 0,t),o+"")}return F0=r,F0}var $0,e2;function BG(){if(e2)return $0;e2=1;var t=gM(),e=mG(),n=_G(),r=y0(),o=Lc(),i=kG(),s=$G(),a=rA(),l=1,u=2,f=4,p=s(function(g,m){var y={};if(g==null)return y;var b=!1;m=t(m,function(C){return C=r(C,g),b||(b=C.length>1),C}),o(g,a(g),y),b&&(y=e(y,l|u|f,i));for(var S=m.length;S--;)n(y,m[S]);return y});return $0=p,$0}var RG=BG();const qa=Zn(RG),Of={TABLE_ELEMENT:1,MENU_BAR:2,NOTCHED_OUTLINE:2};function t2(t){const e=Object.keys(t.typography.h1).some(r=>r.includes("@media")),n=to.keyframes`
|
|
328
328
|
0%, 95% {
|
|
329
329
|
opacity: 1;
|
|
330
330
|
}
|
|
@@ -335,7 +335,7 @@ img.ProseMirror-separator {
|
|
|
335
335
|
* encodeurl
|
|
336
336
|
* Copyright(c) 2016 Douglas Christopher Wilson
|
|
337
337
|
* MIT Licensed
|
|
338
|
-
*/var B0,i2;function qG(){if(i2)return B0;i2=1,B0=r;var t=/(?:[^\x21\x25\x26-\x3B\x3D\x3F-\x5B\x5D\x5F\x61-\x7A\x7E]|%(?:[^0-9A-Fa-f]|[0-9A-Fa-f][^0-9A-Fa-f]|$))+/g,e=/(^|[^\uD800-\uDBFF])[\uDC00-\uDFFF]|[\uD800-\uDBFF]([^\uDC00-\uDFFF]|$)/g,n="$1�$2";function r(o){return String(o).replace(e,n).replace(t,encodeURI)}return B0}var UG=qG();const KG=Zn(UG);function s2(t){let e=t.trim();return e&&!/^(https?:\/\/|mailto:|tel:|sms:|\/|#)/.test(e)&&(e=`http://${e}`),KG(e)}function YG({editor:t,onCancel:e,onSave:n,labels:r,formatHref:o=s2}){var i,s,a,l,u,f;const p=t.isActive("link")?t.getAttributes("link").href:"",g=Dc(t.state.selection.$from,lo("link",t.schema)),m=g?t.state.doc.textBetween(g.from,g.to):"",y=t.state.doc.textBetween(t.state.selection.$from.pos,t.state.selection.$to.pos),b=m||y,[S,C]=J.useState(b),[T,_]=J.useState(p),w=J.useRef(null),E=J.useRef(null),O=!p,L=(i=r==null?void 0:r.editLinkAddTitle)!==null&&i!==void 0?i:"Add link",P=(s=r==null?void 0:r.editLinkEditTitle)!==null&&s!==void 0?s:"Edit link",$=O?L:P;J.useEffect(()=>{var V,R;!O||!b?(V=w.current)===null||V===void 0||V.focus():(R=E.current)===null||R===void 0||R.focus()},[O,b]),o2("Escape",e);function M(){E.current&&_(o(E.current.value))}const[A,N]=J.useState(!1);return v.jsxs("form",{onSubmit:V=>{var R,B,z,q;V.preventDefault(),V.stopPropagation(),N(!0);const K=(B=(R=w.current)===null||R===void 0?void 0:R.value)!==null&&B!==void 0?B:"",G=(q=(z=E.current)===null||z===void 0?void 0:z.value)!==null&&q!==void 0?q:"";n({text:K,link:G}),N(!1)},autoComplete:"off",children:[v.jsx(F.Typography,{variant:"h6",children:$}),v.jsx(F.TextField,{inputRef:w,value:S,disabled:A,onChange:V=>{C(V.target.value)},label:(a=r==null?void 0:r.editLinkTextInputLabel)!==null&&a!==void 0?a:"Text",margin:"normal",size:"small",fullWidth:!0,required:!0}),v.jsx(F.TextField,{inputRef:E,value:T,onChange:V=>{_(V.target.value)},disabled:A,label:(l=r==null?void 0:r.editLinkHrefInputLabel)!==null&&l!==void 0?l:"Link",margin:"dense",size:"small",type:"text",onBlur:M,onKeyDown:V=>{V.key==="Enter"&&M()},fullWidth:!0,required:!0}),v.jsxs(F.DialogActions,{sx:{px:0},children:[v.jsx(F.Button,{onClick:e,variant:"outlined",size:"small",children:(u=r==null?void 0:r.editLinkCancelButtonLabel)!==null&&u!==void 0?u:"Cancel"}),v.jsx(F.Button,{type:"submit",color:"primary",variant:"outlined",size:"small",disabled:A,children:(f=r==null?void 0:r.editLinkSaveButtonLabel)!==null&&f!==void 0?f:"Save"})]})]})}var R0,a2;function GG(){if(a2)return R0;a2=1;var t=BA();function e(n,r,o){var i=n.length;return o=o===void 0?i:o,!r&&o>=i?n:t(n,r,o)}return R0=e,R0}var z0,l2;function V0(){if(l2)return z0;l2=1;var t="\\ud800-\\udfff",e="\\u0300-\\u036f",n="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",o=e+n+r,i="\\ufe0e\\ufe0f",s="\\u200d",a=RegExp("["+s+t+o+i+"]");function l(u){return a.test(u)}return z0=l,z0}var H0,c2;function JG(){if(c2)return H0;c2=1;var t=us(),e=Ci(),n="[object RegExp]";function r(o){return e(o)&&t(o)==n}return H0=r,H0}var j0,u2;function ZG(){if(u2)return j0;u2=1;var t=JG(),e=Ef(),n=Mf(),r=n&&n.isRegExp,o=r?e(r):t;return j0=o,j0}var W0,d2;function XG(){if(d2)return W0;d2=1;function t(e){return function(n){return n==null?void 0:n[e]}}return W0=t,W0}var q0,f2;function QG(){if(f2)return q0;f2=1;var t=XG(),e=t("length");return q0=e,q0}var U0,p2;function eJ(){if(p2)return U0;p2=1;var t="\\ud800-\\udfff",e="\\u0300-\\u036f",n="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",o=e+n+r,i="\\ufe0e\\ufe0f",s="["+t+"]",a="["+o+"]",l="\\ud83c[\\udffb-\\udfff]",u="(?:"+a+"|"+l+")",f="[^"+t+"]",p="(?:\\ud83c[\\udde6-\\uddff]){2}",g="[\\ud800-\\udbff][\\udc00-\\udfff]",m="\\u200d",y=u+"?",b="["+i+"]?",S="(?:"+m+"(?:"+[f,p,g].join("|")+")"+b+y+")*",C=b+y+S,T="(?:"+[f+a+"?",a,p,g,s].join("|")+")",_=RegExp(l+"(?="+l+")|"+T+C,"g");function w(E){for(var O=_.lastIndex=0;_.test(E);)++O;return O}return U0=w,U0}var K0,h2;function tJ(){if(h2)return K0;h2=1;var t=QG(),e=V0(),n=eJ();function r(o){return e(o)?n(o):t(o)}return K0=r,K0}var Y0,g2;function nJ(){if(g2)return Y0;g2=1;function t(e){return e.split("")}return Y0=t,Y0}var G0,m2;function rJ(){if(m2)return G0;m2=1;var t="\\ud800-\\udfff",e="\\u0300-\\u036f",n="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",o=e+n+r,i="\\ufe0e\\ufe0f",s="["+t+"]",a="["+o+"]",l="\\ud83c[\\udffb-\\udfff]",u="(?:"+a+"|"+l+")",f="[^"+t+"]",p="(?:\\ud83c[\\udde6-\\uddff]){2}",g="[\\ud800-\\udbff][\\udc00-\\udfff]",m="\\u200d",y=u+"?",b="["+i+"]?",S="(?:"+m+"(?:"+[f,p,g].join("|")+")"+b+y+")*",C=b+y+S,T="(?:"+[f+a+"?",a,p,g,s].join("|")+")",_=RegExp(l+"(?="+l+")|"+T+C,"g");function w(E){return E.match(_)||[]}return G0=w,G0}var J0,y2;function oJ(){if(y2)return J0;y2=1;var t=nJ(),e=V0(),n=rJ();function r(o){return e(o)?n(o):t(o)}return J0=r,J0}var Z0,b2;function iJ(){if(b2)return Z0;b2=1;var t=AC(),e=1/0,n=17976931348623157e292;function r(o){if(!o)return o===0?o:0;if(o=t(o),o===e||o===-e){var i=o<0?-1:1;return i*n}return o===o?o:0}return Z0=r,Z0}var X0,v2;function sJ(){if(v2)return X0;v2=1;var t=iJ();function e(n){var r=t(n),o=r%1;return r===r?o?r-o:r:0}return X0=e,X0}var Q0,x2;function aJ(){if(x2)return Q0;x2=1;var t=OA(),e=GG(),n=V0(),r=Uo(),o=ZG(),i=tJ(),s=oJ(),a=sJ(),l=IA(),u=30,f="...",p=/\w*$/;function g(m,y){var b=u,S=f;if(r(y)){var C="separator"in y?y.separator:C;b="length"in y?a(y.length):b,S="omission"in y?t(y.omission):S}m=l(m);var T=m.length;if(n(m)){var _=s(m);T=_.length}if(b>=T)return m;var w=b-i(S);if(w<1)return S;var E=_?e(_,0,w).join(""):m.slice(0,w);if(C===void 0)return E+S;if(_&&(w+=E.length-w),o(C)){if(m.slice(w).search(C)){var O,L=E;for(C.global||(C=RegExp(C.source,l(p.exec(C))+"g")),C.lastIndex=0;O=C.exec(L);)var P=O.index;E=E.slice(0,P===void 0?w:P)}}else if(m.indexOf(t(C),w)!=w){var $=E.lastIndexOf(C);$>-1&&(E=E.slice(0,$))}return E+S}return Q0=g,Q0}var lJ=aJ();const cJ=Zn(lJ);function uJ(t,e=20){if(t.length<=e)return t;const n=Math.floor(e/2);return`${t.slice(0,n).trim()}…${t.slice(-n).trim()}`}const dJ=Ut({name:{ViewLinkMenuContent:S2}})({linkPreviewText:{overflowWrap:"anywhere"}});function S2({editor:t,onCancel:e,onEdit:n,onRemove:r,labels:o}){var i,s,a;const{classes:l}=dJ(),u=Dc(t.state.selection.$to,lo("link",t.schema)),f=u?t.state.doc.textBetween(u.from,u.to):"",p=(i=t.getAttributes("link").href)!==null&&i!==void 0?i:"";return o2("Escape",e),v.jsxs(v.Fragment,{children:[v.jsx("div",{className:l.linkPreviewText,children:cJ(f,{length:50,omission:"…"})}),v.jsx("div",{className:l.linkPreviewText,children:v.jsx(F.Link,{href:p,target:"_blank",rel:"noopener",children:uJ(p,50)})}),v.jsxs(F.DialogActions,{sx:{px:0},children:[v.jsx(F.Button,{onClick:n,color:"primary",variant:"outlined",size:"small",children:(s=o==null?void 0:o.viewLinkEditButtonLabel)!==null&&s!==void 0?s:"Edit"}),v.jsx(F.Button,{onClick:r,color:"error",variant:"outlined",size:"small",children:(a=o==null?void 0:o.viewLinkRemoveButtonLabel)!==null&&a!==void 0?a:"Remove"})]})]})}const fJ=Ut({name:{LinkBubbleMenu:C2}})(t=>({content:{padding:t.spacing(1.5,2,.5)}}));function C2({labels:t,formatHref:e,...n}){const{classes:r}=fJ(),o=bt();if(!(o!=null&&o.isEditable))return null;if(!("linkBubbleMenuHandler"in o.storage))throw new Error("You must add the LinkBubbleMenuHandler extension to the useEditor `extensions` array in order to use this component!");const i=o.storage.linkBubbleMenuHandler,s=i.state;let a=null;return s===nr.VIEW_LINK_DETAILS?a=v.jsx(S2,{editor:o,onCancel:o.commands.closeLinkBubbleMenu,onEdit:o.commands.editLinkInBubbleMenu,onRemove:()=>{o.chain().unsetLink().setTextSelection(o.state.selection.to).focus().run()},labels:t}):s===nr.EDIT_LINK&&(a=v.jsx(YG,{editor:o,onCancel:o.commands.closeLinkBubbleMenu,onSave:({text:l,link:u})=>{o.chain().extendMarkRange("link").insertContent({type:"text",marks:[{type:"link",attrs:{href:u}}],text:l}).setLink({href:u}).focus().run(),o.commands.closeLinkBubbleMenu()},labels:t,formatHref:e})),v.jsx(Af,{editor:o,open:s!==nr.HIDDEN,...i.bubbleMenuOptions,...n,children:v.jsx("div",{className:r.content,children:a})})}const ev=Rs("MenuBar",["root","sticky","nonSticky","content"]),pJ=Ut({name:{MenuBar:w2}})((t,{stickyOffset:e})=>({root:{borderBottomColor:t.palette.divider,borderBottomStyle:"solid",borderBottomWidth:1},sticky:{position:"sticky",top:e??0,zIndex:Of.MENU_BAR,background:t.palette.background.default},nonSticky:{},content:{}}));function w2({hide:t,disableSticky:e,stickyOffset:n,children:r,className:o,classes:i}){const{classes:s,cx:a}=pJ({stickyOffset:n},{props:{classes:i}});return v.jsx(F.Collapse,{in:!t,unmountOnExit:!0,className:a(ev.root,s.root,e?[ev.nonSticky,s.nonSticky]:[ev.sticky,s.sticky],o),children:v.jsx("div",{className:s.content,children:r})})}const hJ=Ut({name:{MenuDivider:Mn}})(t=>({root:{height:18,margin:t.spacing(0,.5)}}));function Mn(t){const{classes:e,cx:n}=hJ();return v.jsx(F.Divider,{orientation:"vertical",...t,className:n(e.root,t.className)})}var gJ="tippy-box",_2="tippy-content",mJ="tippy-backdrop",T2="tippy-arrow",k2="tippy-svg-arrow",zs={passive:!0,capture:!0},E2=function(){return document.body};function yJ(t,e){return{}.hasOwnProperty.call(t,e)}function tv(t,e,n){if(Array.isArray(t)){var r=t[e];return r??(Array.isArray(n)?n[e]:n)}return t}function nv(t,e){var n={}.toString.call(t);return n.indexOf("[object")===0&&n.indexOf(e+"]")>-1}function M2(t,e){return typeof t=="function"?t.apply(void 0,e):t}function O2(t,e){if(e===0)return t;var n;return function(r){clearTimeout(n),n=setTimeout(function(){t(r)},e)}}function bJ(t,e){var n=Object.assign({},t);return e.forEach(function(r){delete n[r]}),n}function vJ(t){return t.split(/\s+/).filter(Boolean)}function Ua(t){return[].concat(t)}function A2(t,e){t.indexOf(e)===-1&&t.push(e)}function xJ(t){return t.filter(function(e,n){return t.indexOf(e)===n})}function SJ(t){return t.split("-")[0]}function If(t){return[].slice.call(t)}function I2(t){return Object.keys(t).reduce(function(e,n){return t[n]!==void 0&&(e[n]=t[n]),e},{})}function Rc(){return document.createElement("div")}function zc(t){return["Element","Fragment"].some(function(e){return nv(t,e)})}function CJ(t){return nv(t,"NodeList")}function wJ(t){return nv(t,"MouseEvent")}function _J(t){return!!(t&&t._tippy&&t._tippy.reference===t)}function TJ(t){return zc(t)?[t]:CJ(t)?If(t):Array.isArray(t)?t:If(document.querySelectorAll(t))}function rv(t,e){t.forEach(function(n){n&&(n.style.transitionDuration=e+"ms")})}function D2(t,e){t.forEach(function(n){n&&n.setAttribute("data-state",e)})}function kJ(t){var e,n=Ua(t),r=n[0];return r!=null&&(e=r.ownerDocument)!=null&&e.body?r.ownerDocument:document}function EJ(t,e){var n=e.clientX,r=e.clientY;return t.every(function(o){var i=o.popperRect,s=o.popperState,a=o.props,l=a.interactiveBorder,u=SJ(s.placement),f=s.modifiersData.offset;if(!f)return!0;var p=u==="bottom"?f.top.y:0,g=u==="top"?f.bottom.y:0,m=u==="right"?f.left.x:0,y=u==="left"?f.right.x:0,b=i.top-r+p>l,S=r-i.bottom-g>l,C=i.left-n+m>l,T=n-i.right-y>l;return b||S||C||T})}function ov(t,e,n){var r=e+"EventListener";["transitionend","webkitTransitionEnd"].forEach(function(o){t[r](o,n)})}function P2(t,e){for(var n=e;n;){var r;if(t.contains(n))return!0;n=n.getRootNode==null||(r=n.getRootNode())==null?void 0:r.host}return!1}var Oo={isTouch:!1},N2=0;function MJ(){Oo.isTouch||(Oo.isTouch=!0,window.performance&&document.addEventListener("mousemove",L2))}function L2(){var t=performance.now();t-N2<20&&(Oo.isTouch=!1,document.removeEventListener("mousemove",L2)),N2=t}function OJ(){var t=document.activeElement;if(_J(t)){var e=t._tippy;t.blur&&!e.state.isVisible&&t.blur()}}function AJ(){document.addEventListener("touchstart",MJ,zs),window.addEventListener("blur",OJ)}var IJ=typeof window<"u"&&typeof document<"u",DJ=IJ?!!window.msCrypto:!1;function Ka(t){var e=t==="destroy"?"n already-":" ";return[t+"() was called on a"+e+"destroyed instance. This is a no-op but","indicates a potential memory leak."].join(" ")}function F2(t){var e=/[ \t]{2,}/g,n=/^[ \t]*/gm;return t.replace(e," ").replace(n,"").trim()}function PJ(t){return F2(`
|
|
338
|
+
*/var B0,i2;function qG(){if(i2)return B0;i2=1,B0=r;var t=/(?:[^\x21\x25\x26-\x3B\x3D\x3F-\x5B\x5D\x5F\x61-\x7A\x7E]|%(?:[^0-9A-Fa-f]|[0-9A-Fa-f][^0-9A-Fa-f]|$))+/g,e=/(^|[^\uD800-\uDBFF])[\uDC00-\uDFFF]|[\uD800-\uDBFF]([^\uDC00-\uDFFF]|$)/g,n="$1�$2";function r(o){return String(o).replace(e,n).replace(t,encodeURI)}return B0}var UG=qG();const KG=Zn(UG);function s2(t){let e=t.trim();return e&&!/^(https?:\/\/|mailto:|tel:|sms:|\/|#)/.test(e)&&(e=`http://${e}`),KG(e)}function YG({editor:t,onCancel:e,onSave:n,labels:r,formatHref:o=s2}){var i,s,a,l,u,f;const p=t.isActive("link")?t.getAttributes("link").href:"",g=Dc(t.state.selection.$from,lo("link",t.schema)),m=g?t.state.doc.textBetween(g.from,g.to):"",y=t.state.doc.textBetween(t.state.selection.$from.pos,t.state.selection.$to.pos),b=m||y,[S,C]=J.useState(b),[T,_]=J.useState(p),w=J.useRef(null),E=J.useRef(null),O=!p,L=(i=r==null?void 0:r.editLinkAddTitle)!==null&&i!==void 0?i:"Add link",P=(s=r==null?void 0:r.editLinkEditTitle)!==null&&s!==void 0?s:"Edit link",$=O?L:P;J.useEffect(()=>{var z,V;!O||!b?(z=w.current)===null||z===void 0||z.focus():(V=E.current)===null||V===void 0||V.focus()},[O,b]),o2("Escape",e);function M(){E.current&&_(o(E.current.value))}const[A,N]=J.useState(!1);return v.jsxs("form",{onSubmit:z=>{var V,B,R,q;z.preventDefault(),z.stopPropagation(),N(!0);const U=(B=(V=w.current)===null||V===void 0?void 0:V.value)!==null&&B!==void 0?B:"",G=(q=(R=E.current)===null||R===void 0?void 0:R.value)!==null&&q!==void 0?q:"";n({text:U,link:G}),N(!1)},autoComplete:"off",children:[v.jsx(F.Typography,{variant:"h6",children:$}),v.jsx(F.TextField,{inputRef:w,value:S,disabled:A,onChange:z=>{C(z.target.value)},label:(a=r==null?void 0:r.editLinkTextInputLabel)!==null&&a!==void 0?a:"Text",margin:"normal",size:"small",fullWidth:!0,required:!0}),v.jsx(F.TextField,{inputRef:E,value:T,onChange:z=>{_(z.target.value)},disabled:A,label:(l=r==null?void 0:r.editLinkHrefInputLabel)!==null&&l!==void 0?l:"Link",margin:"dense",size:"small",type:"text",onBlur:M,onKeyDown:z=>{z.key==="Enter"&&M()},fullWidth:!0,required:!0}),v.jsxs(F.DialogActions,{sx:{px:0},children:[v.jsx(F.Button,{onClick:e,variant:"outlined",size:"small",children:(u=r==null?void 0:r.editLinkCancelButtonLabel)!==null&&u!==void 0?u:"Cancel"}),v.jsx(F.Button,{type:"submit",color:"primary",variant:"outlined",size:"small",disabled:A,children:(f=r==null?void 0:r.editLinkSaveButtonLabel)!==null&&f!==void 0?f:"Save"})]})]})}var R0,a2;function GG(){if(a2)return R0;a2=1;var t=BA();function e(n,r,o){var i=n.length;return o=o===void 0?i:o,!r&&o>=i?n:t(n,r,o)}return R0=e,R0}var z0,l2;function V0(){if(l2)return z0;l2=1;var t="\\ud800-\\udfff",e="\\u0300-\\u036f",n="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",o=e+n+r,i="\\ufe0e\\ufe0f",s="\\u200d",a=RegExp("["+s+t+o+i+"]");function l(u){return a.test(u)}return z0=l,z0}var H0,c2;function JG(){if(c2)return H0;c2=1;var t=us(),e=Ci(),n="[object RegExp]";function r(o){return e(o)&&t(o)==n}return H0=r,H0}var j0,u2;function ZG(){if(u2)return j0;u2=1;var t=JG(),e=Ef(),n=Mf(),r=n&&n.isRegExp,o=r?e(r):t;return j0=o,j0}var W0,d2;function XG(){if(d2)return W0;d2=1;function t(e){return function(n){return n==null?void 0:n[e]}}return W0=t,W0}var q0,f2;function QG(){if(f2)return q0;f2=1;var t=XG(),e=t("length");return q0=e,q0}var U0,p2;function eJ(){if(p2)return U0;p2=1;var t="\\ud800-\\udfff",e="\\u0300-\\u036f",n="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",o=e+n+r,i="\\ufe0e\\ufe0f",s="["+t+"]",a="["+o+"]",l="\\ud83c[\\udffb-\\udfff]",u="(?:"+a+"|"+l+")",f="[^"+t+"]",p="(?:\\ud83c[\\udde6-\\uddff]){2}",g="[\\ud800-\\udbff][\\udc00-\\udfff]",m="\\u200d",y=u+"?",b="["+i+"]?",S="(?:"+m+"(?:"+[f,p,g].join("|")+")"+b+y+")*",C=b+y+S,T="(?:"+[f+a+"?",a,p,g,s].join("|")+")",_=RegExp(l+"(?="+l+")|"+T+C,"g");function w(E){for(var O=_.lastIndex=0;_.test(E);)++O;return O}return U0=w,U0}var K0,h2;function tJ(){if(h2)return K0;h2=1;var t=QG(),e=V0(),n=eJ();function r(o){return e(o)?n(o):t(o)}return K0=r,K0}var Y0,g2;function nJ(){if(g2)return Y0;g2=1;function t(e){return e.split("")}return Y0=t,Y0}var G0,m2;function rJ(){if(m2)return G0;m2=1;var t="\\ud800-\\udfff",e="\\u0300-\\u036f",n="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",o=e+n+r,i="\\ufe0e\\ufe0f",s="["+t+"]",a="["+o+"]",l="\\ud83c[\\udffb-\\udfff]",u="(?:"+a+"|"+l+")",f="[^"+t+"]",p="(?:\\ud83c[\\udde6-\\uddff]){2}",g="[\\ud800-\\udbff][\\udc00-\\udfff]",m="\\u200d",y=u+"?",b="["+i+"]?",S="(?:"+m+"(?:"+[f,p,g].join("|")+")"+b+y+")*",C=b+y+S,T="(?:"+[f+a+"?",a,p,g,s].join("|")+")",_=RegExp(l+"(?="+l+")|"+T+C,"g");function w(E){return E.match(_)||[]}return G0=w,G0}var J0,y2;function oJ(){if(y2)return J0;y2=1;var t=nJ(),e=V0(),n=rJ();function r(o){return e(o)?n(o):t(o)}return J0=r,J0}var Z0,b2;function iJ(){if(b2)return Z0;b2=1;var t=AC(),e=1/0,n=17976931348623157e292;function r(o){if(!o)return o===0?o:0;if(o=t(o),o===e||o===-e){var i=o<0?-1:1;return i*n}return o===o?o:0}return Z0=r,Z0}var X0,v2;function sJ(){if(v2)return X0;v2=1;var t=iJ();function e(n){var r=t(n),o=r%1;return r===r?o?r-o:r:0}return X0=e,X0}var Q0,x2;function aJ(){if(x2)return Q0;x2=1;var t=OA(),e=GG(),n=V0(),r=Uo(),o=ZG(),i=tJ(),s=oJ(),a=sJ(),l=IA(),u=30,f="...",p=/\w*$/;function g(m,y){var b=u,S=f;if(r(y)){var C="separator"in y?y.separator:C;b="length"in y?a(y.length):b,S="omission"in y?t(y.omission):S}m=l(m);var T=m.length;if(n(m)){var _=s(m);T=_.length}if(b>=T)return m;var w=b-i(S);if(w<1)return S;var E=_?e(_,0,w).join(""):m.slice(0,w);if(C===void 0)return E+S;if(_&&(w+=E.length-w),o(C)){if(m.slice(w).search(C)){var O,L=E;for(C.global||(C=RegExp(C.source,l(p.exec(C))+"g")),C.lastIndex=0;O=C.exec(L);)var P=O.index;E=E.slice(0,P===void 0?w:P)}}else if(m.indexOf(t(C),w)!=w){var $=E.lastIndexOf(C);$>-1&&(E=E.slice(0,$))}return E+S}return Q0=g,Q0}var lJ=aJ();const cJ=Zn(lJ);function uJ(t,e=20){if(t.length<=e)return t;const n=Math.floor(e/2);return`${t.slice(0,n).trim()}…${t.slice(-n).trim()}`}const dJ=Ut({name:{ViewLinkMenuContent:S2}})({linkPreviewText:{overflowWrap:"anywhere"}});function S2({editor:t,onCancel:e,onEdit:n,onRemove:r,labels:o}){var i,s,a;const{classes:l}=dJ(),u=Dc(t.state.selection.$to,lo("link",t.schema)),f=u?t.state.doc.textBetween(u.from,u.to):"",p=(i=t.getAttributes("link").href)!==null&&i!==void 0?i:"";return o2("Escape",e),v.jsxs(v.Fragment,{children:[v.jsx("div",{className:l.linkPreviewText,children:cJ(f,{length:50,omission:"…"})}),v.jsx("div",{className:l.linkPreviewText,children:v.jsx(F.Link,{href:p,target:"_blank",rel:"noopener",children:uJ(p,50)})}),v.jsxs(F.DialogActions,{sx:{px:0},children:[v.jsx(F.Button,{onClick:n,color:"primary",variant:"outlined",size:"small",children:(s=o==null?void 0:o.viewLinkEditButtonLabel)!==null&&s!==void 0?s:"Edit"}),v.jsx(F.Button,{onClick:r,color:"error",variant:"outlined",size:"small",children:(a=o==null?void 0:o.viewLinkRemoveButtonLabel)!==null&&a!==void 0?a:"Remove"})]})]})}const fJ=Ut({name:{LinkBubbleMenu:C2}})(t=>({content:{padding:t.spacing(1.5,2,.5)}}));function C2({labels:t,formatHref:e,...n}){const{classes:r}=fJ(),o=bt();if(!(o!=null&&o.isEditable))return null;if(!("linkBubbleMenuHandler"in o.storage))throw new Error("You must add the LinkBubbleMenuHandler extension to the useEditor `extensions` array in order to use this component!");const i=o.storage.linkBubbleMenuHandler,s=i.state;let a=null;return s===nr.VIEW_LINK_DETAILS?a=v.jsx(S2,{editor:o,onCancel:o.commands.closeLinkBubbleMenu,onEdit:o.commands.editLinkInBubbleMenu,onRemove:()=>{o.chain().unsetLink().setTextSelection(o.state.selection.to).focus().run()},labels:t}):s===nr.EDIT_LINK&&(a=v.jsx(YG,{editor:o,onCancel:o.commands.closeLinkBubbleMenu,onSave:({text:l,link:u})=>{o.chain().extendMarkRange("link").insertContent({type:"text",marks:[{type:"link",attrs:{href:u}}],text:l}).setLink({href:u}).focus().run(),o.commands.closeLinkBubbleMenu()},labels:t,formatHref:e})),v.jsx(Af,{editor:o,open:s!==nr.HIDDEN,...i.bubbleMenuOptions,...n,children:v.jsx("div",{className:r.content,children:a})})}const ev=Rs("MenuBar",["root","sticky","nonSticky","content"]),pJ=Ut({name:{MenuBar:w2}})((t,{stickyOffset:e})=>({root:{borderBottomColor:t.palette.divider,borderBottomStyle:"solid",borderBottomWidth:1},sticky:{position:"sticky",top:e??0,zIndex:Of.MENU_BAR,background:t.palette.background.default},nonSticky:{},content:{}}));function w2({hide:t,disableSticky:e,stickyOffset:n,children:r,className:o,classes:i}){const{classes:s,cx:a}=pJ({stickyOffset:n},{props:{classes:i}});return v.jsx(F.Collapse,{in:!t,unmountOnExit:!0,className:a(ev.root,s.root,e?[ev.nonSticky,s.nonSticky]:[ev.sticky,s.sticky],o),children:v.jsx("div",{className:s.content,children:r})})}const hJ=Ut({name:{MenuDivider:Mn}})(t=>({root:{height:18,margin:t.spacing(0,.5)}}));function Mn(t){const{classes:e,cx:n}=hJ();return v.jsx(F.Divider,{orientation:"vertical",...t,className:n(e.root,t.className)})}var gJ="tippy-box",_2="tippy-content",mJ="tippy-backdrop",T2="tippy-arrow",k2="tippy-svg-arrow",zs={passive:!0,capture:!0},E2=function(){return document.body};function yJ(t,e){return{}.hasOwnProperty.call(t,e)}function tv(t,e,n){if(Array.isArray(t)){var r=t[e];return r??(Array.isArray(n)?n[e]:n)}return t}function nv(t,e){var n={}.toString.call(t);return n.indexOf("[object")===0&&n.indexOf(e+"]")>-1}function M2(t,e){return typeof t=="function"?t.apply(void 0,e):t}function O2(t,e){if(e===0)return t;var n;return function(r){clearTimeout(n),n=setTimeout(function(){t(r)},e)}}function bJ(t,e){var n=Object.assign({},t);return e.forEach(function(r){delete n[r]}),n}function vJ(t){return t.split(/\s+/).filter(Boolean)}function Ua(t){return[].concat(t)}function A2(t,e){t.indexOf(e)===-1&&t.push(e)}function xJ(t){return t.filter(function(e,n){return t.indexOf(e)===n})}function SJ(t){return t.split("-")[0]}function If(t){return[].slice.call(t)}function I2(t){return Object.keys(t).reduce(function(e,n){return t[n]!==void 0&&(e[n]=t[n]),e},{})}function Rc(){return document.createElement("div")}function zc(t){return["Element","Fragment"].some(function(e){return nv(t,e)})}function CJ(t){return nv(t,"NodeList")}function wJ(t){return nv(t,"MouseEvent")}function _J(t){return!!(t&&t._tippy&&t._tippy.reference===t)}function TJ(t){return zc(t)?[t]:CJ(t)?If(t):Array.isArray(t)?t:If(document.querySelectorAll(t))}function rv(t,e){t.forEach(function(n){n&&(n.style.transitionDuration=e+"ms")})}function D2(t,e){t.forEach(function(n){n&&n.setAttribute("data-state",e)})}function kJ(t){var e,n=Ua(t),r=n[0];return r!=null&&(e=r.ownerDocument)!=null&&e.body?r.ownerDocument:document}function EJ(t,e){var n=e.clientX,r=e.clientY;return t.every(function(o){var i=o.popperRect,s=o.popperState,a=o.props,l=a.interactiveBorder,u=SJ(s.placement),f=s.modifiersData.offset;if(!f)return!0;var p=u==="bottom"?f.top.y:0,g=u==="top"?f.bottom.y:0,m=u==="right"?f.left.x:0,y=u==="left"?f.right.x:0,b=i.top-r+p>l,S=r-i.bottom-g>l,C=i.left-n+m>l,T=n-i.right-y>l;return b||S||C||T})}function ov(t,e,n){var r=e+"EventListener";["transitionend","webkitTransitionEnd"].forEach(function(o){t[r](o,n)})}function P2(t,e){for(var n=e;n;){var r;if(t.contains(n))return!0;n=n.getRootNode==null||(r=n.getRootNode())==null?void 0:r.host}return!1}var Oo={isTouch:!1},N2=0;function MJ(){Oo.isTouch||(Oo.isTouch=!0,window.performance&&document.addEventListener("mousemove",L2))}function L2(){var t=performance.now();t-N2<20&&(Oo.isTouch=!1,document.removeEventListener("mousemove",L2)),N2=t}function OJ(){var t=document.activeElement;if(_J(t)){var e=t._tippy;t.blur&&!e.state.isVisible&&t.blur()}}function AJ(){document.addEventListener("touchstart",MJ,zs),window.addEventListener("blur",OJ)}var IJ=typeof window<"u"&&typeof document<"u",DJ=IJ?!!window.msCrypto:!1;function Ka(t){var e=t==="destroy"?"n already-":" ";return[t+"() was called on a"+e+"destroyed instance. This is a no-op but","indicates a potential memory leak."].join(" ")}function F2(t){var e=/[ \t]{2,}/g,n=/^[ \t]*/gm;return t.replace(e," ").replace(n,"").trim()}function PJ(t){return F2(`
|
|
339
339
|
%ctippy.js
|
|
340
340
|
|
|
341
341
|
%c`+F2(t)+`
|
|
@@ -344,13 +344,13 @@ img.ProseMirror-separator {
|
|
|
344
344
|
`)}function $2(t){return[PJ(t),"color: #00C584; font-size: 1.3em; font-weight: bold;","line-height: 1.5","color: #a6a095;"]}var Vc;process.env.NODE_ENV!=="production"&&NJ();function NJ(){Vc=new Set}function ti(t,e){if(t&&!Vc.has(e)){var n;Vc.add(e),(n=console).warn.apply(n,$2(e))}}function iv(t,e){if(t&&!Vc.has(e)){var n;Vc.add(e),(n=console).error.apply(n,$2(e))}}function LJ(t){var e=!t,n=Object.prototype.toString.call(t)==="[object Object]"&&!t.addEventListener;iv(e,["tippy() was passed","`"+String(t)+"`","as its targets (first) argument. Valid types are: String, Element,","Element[], or NodeList."].join(" ")),iv(n,["tippy() was passed a plain object which is not supported as an argument","for virtual positioning. Use props.getReferenceClientRect instead."].join(" "))}var B2={animateFill:!1,followCursor:!1,inlinePositioning:!1,sticky:!1},FJ={allowHTML:!1,animation:"fade",arrow:!0,content:"",inertia:!1,maxWidth:350,role:"tooltip",theme:"",zIndex:9999},wr=Object.assign({appendTo:E2,aria:{content:"auto",expanded:"auto"},delay:0,duration:[300,250],getReferenceClientRect:null,hideOnClick:!0,ignoreAttributes:!1,interactive:!1,interactiveBorder:2,interactiveDebounce:0,moveTransition:"",offset:[0,10],onAfterUpdate:function(){},onBeforeUpdate:function(){},onCreate:function(){},onDestroy:function(){},onHidden:function(){},onHide:function(){},onMount:function(){},onShow:function(){},onShown:function(){},onTrigger:function(){},onUntrigger:function(){},onClickOutside:function(){},placement:"top",plugins:[],popperOptions:{},render:null,showOnCreate:!1,touch:!0,trigger:"mouseenter focus",triggerTarget:null},B2,FJ),$J=Object.keys(wr),BJ=function(e){process.env.NODE_ENV!=="production"&&V2(e,[]);var n=Object.keys(e);n.forEach(function(r){wr[r]=e[r]})};function R2(t){var e=t.plugins||[],n=e.reduce(function(r,o){var i=o.name,s=o.defaultValue;if(i){var a;r[i]=t[i]!==void 0?t[i]:(a=wr[i])!=null?a:s}return r},{});return Object.assign({},t,n)}function RJ(t,e){var n=e?Object.keys(R2(Object.assign({},wr,{plugins:e}))):$J,r=n.reduce(function(o,i){var s=(t.getAttribute("data-tippy-"+i)||"").trim();if(!s)return o;if(i==="content")o[i]=s;else try{o[i]=JSON.parse(s)}catch{o[i]=s}return o},{});return r}function z2(t,e){var n=Object.assign({},e,{content:M2(e.content,[t])},e.ignoreAttributes?{}:RJ(t,e.plugins));return n.aria=Object.assign({},wr.aria,n.aria),n.aria={expanded:n.aria.expanded==="auto"?e.interactive:n.aria.expanded,content:n.aria.content==="auto"?e.interactive?null:"describedby":n.aria.content},n}function V2(t,e){t===void 0&&(t={}),e===void 0&&(e=[]);var n=Object.keys(t);n.forEach(function(r){var o=bJ(wr,Object.keys(B2)),i=!yJ(o,r);i&&(i=e.filter(function(s){return s.name===r}).length===0),ti(i,["`"+r+"`","is not a valid prop. You may have spelled it incorrectly, or if it's","a plugin, forgot to pass it in an array as props.plugins.",`
|
|
345
345
|
|
|
346
346
|
`,`All props: https://atomiks.github.io/tippyjs/v6/all-props/
|
|
347
|
-
`,"Plugins: https://atomiks.github.io/tippyjs/v6/plugins/"].join(" "))})}var zJ=function(){return"innerHTML"};function sv(t,e){t[zJ()]=e}function H2(t){var e=Rc();return t===!0?e.className=T2:(e.className=k2,zc(t)?e.appendChild(t):sv(e,t)),e}function j2(t,e){zc(e.content)?(sv(t,""),t.appendChild(e.content)):typeof e.content!="function"&&(e.allowHTML?sv(t,e.content):t.textContent=e.content)}function av(t){var e=t.firstElementChild,n=If(e.children);return{box:e,content:n.find(function(r){return r.classList.contains(_2)}),arrow:n.find(function(r){return r.classList.contains(T2)||r.classList.contains(k2)}),backdrop:n.find(function(r){return r.classList.contains(mJ)})}}function W2(t){var e=Rc(),n=Rc();n.className=gJ,n.setAttribute("data-state","hidden"),n.setAttribute("tabindex","-1");var r=Rc();r.className=_2,r.setAttribute("data-state","hidden"),j2(r,t.props),e.appendChild(n),n.appendChild(r),o(t.props,t.props);function o(i,s){var a=av(e),l=a.box,u=a.content,f=a.arrow;s.theme?l.setAttribute("data-theme",s.theme):l.removeAttribute("data-theme"),typeof s.animation=="string"?l.setAttribute("data-animation",s.animation):l.removeAttribute("data-animation"),s.inertia?l.setAttribute("data-inertia",""):l.removeAttribute("data-inertia"),l.style.maxWidth=typeof s.maxWidth=="number"?s.maxWidth+"px":s.maxWidth,s.role?l.setAttribute("role",s.role):l.removeAttribute("role"),(i.content!==s.content||i.allowHTML!==s.allowHTML)&&j2(u,t.props),s.arrow?f?i.arrow!==s.arrow&&(l.removeChild(f),l.appendChild(H2(s.arrow))):l.appendChild(H2(s.arrow)):f&&l.removeChild(f)}return{popper:e,onUpdate:o}}W2.$$tippy=!0;var VJ=1,Df=[],lv=[];function HJ(t,e){var n=z2(t,Object.assign({},wr,R2(I2(e)))),r,o,i,s=!1,a=!1,l=!1,u=!1,f,p,g,m=[],y=O2(
|
|
347
|
+
`,"Plugins: https://atomiks.github.io/tippyjs/v6/plugins/"].join(" "))})}var zJ=function(){return"innerHTML"};function sv(t,e){t[zJ()]=e}function H2(t){var e=Rc();return t===!0?e.className=T2:(e.className=k2,zc(t)?e.appendChild(t):sv(e,t)),e}function j2(t,e){zc(e.content)?(sv(t,""),t.appendChild(e.content)):typeof e.content!="function"&&(e.allowHTML?sv(t,e.content):t.textContent=e.content)}function av(t){var e=t.firstElementChild,n=If(e.children);return{box:e,content:n.find(function(r){return r.classList.contains(_2)}),arrow:n.find(function(r){return r.classList.contains(T2)||r.classList.contains(k2)}),backdrop:n.find(function(r){return r.classList.contains(mJ)})}}function W2(t){var e=Rc(),n=Rc();n.className=gJ,n.setAttribute("data-state","hidden"),n.setAttribute("tabindex","-1");var r=Rc();r.className=_2,r.setAttribute("data-state","hidden"),j2(r,t.props),e.appendChild(n),n.appendChild(r),o(t.props,t.props);function o(i,s){var a=av(e),l=a.box,u=a.content,f=a.arrow;s.theme?l.setAttribute("data-theme",s.theme):l.removeAttribute("data-theme"),typeof s.animation=="string"?l.setAttribute("data-animation",s.animation):l.removeAttribute("data-animation"),s.inertia?l.setAttribute("data-inertia",""):l.removeAttribute("data-inertia"),l.style.maxWidth=typeof s.maxWidth=="number"?s.maxWidth+"px":s.maxWidth,s.role?l.setAttribute("role",s.role):l.removeAttribute("role"),(i.content!==s.content||i.allowHTML!==s.allowHTML)&&j2(u,t.props),s.arrow?f?i.arrow!==s.arrow&&(l.removeChild(f),l.appendChild(H2(s.arrow))):l.appendChild(H2(s.arrow)):f&&l.removeChild(f)}return{popper:e,onUpdate:o}}W2.$$tippy=!0;var VJ=1,Df=[],lv=[];function HJ(t,e){var n=z2(t,Object.assign({},wr,R2(I2(e)))),r,o,i,s=!1,a=!1,l=!1,u=!1,f,p,g,m=[],y=O2(ue,n.interactiveDebounce),b,S=VJ++,C=null,T=xJ(n.plugins),_={isEnabled:!0,isVisible:!1,isDestroyed:!1,isMounted:!1,isShown:!1},w={id:S,reference:t,popper:Rc(),popperInstance:C,props:n,state:_,plugins:T,clearDelayTimeouts:Sn,setProps:un,setContent:$t,show:In,hide:Kn,hideWithInteractivity:ft,enable:Ct,disable:Xt,unmount:$n,destroy:Yt};if(!n.render)return process.env.NODE_ENV!=="production"&&iv(!0,"render() function has not been supplied."),w;var E=n.render(w),O=E.popper,L=E.onUpdate;O.setAttribute("data-tippy-root",""),O.id="tippy-"+w.id,w.popper=O,t._tippy=w,O._tippy=w;var P=T.map(function(ge){return ge.fn(w)}),$=t.hasAttribute("aria-expanded");return ce(),Y(),q(),U("onCreate",[w]),n.showOnCreate&&De(),O.addEventListener("mouseenter",function(){w.props.interactive&&w.state.isVisible&&w.clearDelayTimeouts()}),O.addEventListener("mouseleave",function(){w.props.interactive&&w.props.trigger.indexOf("mouseenter")>=0&&V().addEventListener("mousemove",y)}),w;function M(){var ge=w.props.touch;return Array.isArray(ge)?ge:[ge,0]}function A(){return M()[0]==="hold"}function N(){var ge;return!!((ge=w.props.render)!=null&&ge.$$tippy)}function z(){return b||t}function V(){var ge=z().parentNode;return ge?kJ(ge):document}function B(){return av(O)}function R(ge){return w.state.isMounted&&!w.state.isVisible||Oo.isTouch||f&&f.type==="focus"?0:tv(w.props.delay,ge?0:1,wr.delay)}function q(ge){ge===void 0&&(ge=!1),O.style.pointerEvents=w.props.interactive&&!ge?"":"none",O.style.zIndex=""+w.props.zIndex}function U(ge,$e,ke){if(ke===void 0&&(ke=!0),P.forEach(function(Ge){Ge[ge]&&Ge[ge].apply(Ge,$e)}),ke){var Re;(Re=w.props)[ge].apply(Re,$e)}}function G(){var ge=w.props.aria;if(ge.content){var $e="aria-"+ge.content,ke=O.id,Re=Ua(w.props.triggerTarget||t);Re.forEach(function(Ge){var nt=Ge.getAttribute($e);if(w.state.isVisible)Ge.setAttribute($e,nt?nt+" "+ke:ke);else{var Pt=nt&&nt.replace(ke,"").trim();Pt?Ge.setAttribute($e,Pt):Ge.removeAttribute($e)}})}}function Y(){if(!($||!w.props.aria.expanded)){var ge=Ua(w.props.triggerTarget||t);ge.forEach(function($e){w.props.interactive?$e.setAttribute("aria-expanded",w.state.isVisible&&$e===z()?"true":"false"):$e.removeAttribute("aria-expanded")})}}function Z(){V().removeEventListener("mousemove",y),Df=Df.filter(function(ge){return ge!==y})}function fe(ge){if(!(Oo.isTouch&&(l||ge.type==="mousedown"))){var $e=ge.composedPath&&ge.composedPath()[0]||ge.target;if(!(w.props.interactive&&P2(O,$e))){if(Ua(w.props.triggerTarget||t).some(function(ke){return P2(ke,$e)})){if(Oo.isTouch||w.state.isVisible&&w.props.trigger.indexOf("click")>=0)return}else U("onClickOutside",[w,ge]);w.props.hideOnClick===!0&&(w.clearDelayTimeouts(),w.hide(),a=!0,setTimeout(function(){a=!1}),w.state.isMounted||he())}}}function pe(){l=!0}function me(){l=!1}function re(){var ge=V();ge.addEventListener("mousedown",fe,!0),ge.addEventListener("touchend",fe,zs),ge.addEventListener("touchstart",me,zs),ge.addEventListener("touchmove",pe,zs)}function he(){var ge=V();ge.removeEventListener("mousedown",fe,!0),ge.removeEventListener("touchend",fe,zs),ge.removeEventListener("touchstart",me,zs),ge.removeEventListener("touchmove",pe,zs)}function le(ge,$e){W(ge,function(){!w.state.isVisible&&O.parentNode&&O.parentNode.contains(O)&&$e()})}function X(ge,$e){W(ge,$e)}function W(ge,$e){var ke=B().box;function Re(Ge){Ge.target===ke&&(ov(ke,"remove",Re),$e())}if(ge===0)return $e();ov(ke,"remove",p),ov(ke,"add",Re),p=Re}function ee(ge,$e,ke){ke===void 0&&(ke=!1);var Re=Ua(w.props.triggerTarget||t);Re.forEach(function(Ge){Ge.addEventListener(ge,$e,ke),m.push({node:Ge,eventType:ge,handler:$e,options:ke})})}function ce(){A()&&(ee("touchstart",se,{passive:!0}),ee("touchend",ye,{passive:!0})),vJ(w.props.trigger).forEach(function(ge){if(ge!=="manual")switch(ee(ge,se),ge){case"mouseenter":ee("mouseleave",ye);break;case"focus":ee(DJ?"focusout":"blur",_e);break;case"focusin":ee("focusout",_e);break}})}function te(){m.forEach(function(ge){var $e=ge.node,ke=ge.eventType,Re=ge.handler,Ge=ge.options;$e.removeEventListener(ke,Re,Ge)}),m=[]}function se(ge){var $e,ke=!1;if(!(!w.state.isEnabled||Se(ge)||a)){var Re=(($e=f)==null?void 0:$e.type)==="focus";f=ge,b=ge.currentTarget,Y(),!w.state.isVisible&&wJ(ge)&&Df.forEach(function(Ge){return Ge(ge)}),ge.type==="click"&&(w.props.trigger.indexOf("mouseenter")<0||s)&&w.props.hideOnClick!==!1&&w.state.isVisible?ke=!0:De(ge),ge.type==="click"&&(s=!ke),ke&&!Re&&ct(ge)}}function ue(ge){var $e=ge.target,ke=z().contains($e)||O.contains($e);if(!(ge.type==="mousemove"&&ke)){var Re=Je().concat(O).map(function(Ge){var nt,Pt=Ge._tippy,rr=(nt=Pt.popperInstance)==null?void 0:nt.state;return rr?{popperRect:Ge.getBoundingClientRect(),popperState:rr,props:n}:null}).filter(Boolean);EJ(Re,ge)&&(Z(),ct(ge))}}function ye(ge){var $e=Se(ge)||w.props.trigger.indexOf("click")>=0&&s;if(!$e){if(w.props.interactive){w.hideWithInteractivity(ge);return}ct(ge)}}function _e(ge){w.props.trigger.indexOf("focusin")<0&&ge.target!==z()||w.props.interactive&&ge.relatedTarget&&O.contains(ge.relatedTarget)||ct(ge)}function Se(ge){return Oo.isTouch?A()!==ge.type.indexOf("touch")>=0:!1}function Me(){Fe();var ge=w.props,$e=ge.popperOptions,ke=ge.placement,Re=ge.offset,Ge=ge.getReferenceClientRect,nt=ge.moveTransition,Pt=N()?av(O).arrow:null,rr=Ge?{getBoundingClientRect:Ge,contextElement:Ge.contextElement||z()}:t,hr={name:"$$tippy",enabled:!0,phase:"beforeWrite",requires:["computeStyles"],fn:function(rl){var Zi=rl.state;if(N()){var Pp=B(),au=Pp.box;["placement","reference-hidden","escaped"].forEach(function(ol){ol==="placement"?au.setAttribute("data-placement",Zi.placement):Zi.attributes.popper["data-popper-"+ol]?au.setAttribute("data-"+ol,""):au.removeAttribute("data-"+ol)}),Zi.attributes.popper={}}}},si=[{name:"offset",options:{offset:Re}},{name:"preventOverflow",options:{padding:{top:2,bottom:2,left:5,right:5}}},{name:"flip",options:{padding:5}},{name:"computeStyles",options:{adaptive:!nt}},hr];N()&&Pt&&si.push({name:"arrow",options:{element:Pt,padding:3}}),si.push.apply(si,($e==null?void 0:$e.modifiers)||[]),w.popperInstance=L_(rr,O,Object.assign({},$e,{placement:ke,onFirstUpdate:g,modifiers:si}))}function Fe(){w.popperInstance&&(w.popperInstance.destroy(),w.popperInstance=null)}function je(){var ge=w.props.appendTo,$e,ke=z();w.props.interactive&&ge===E2||ge==="parent"?$e=ke.parentNode:$e=M2(ge,[ke]),$e.contains(O)||$e.appendChild(O),w.state.isMounted=!0,Me(),process.env.NODE_ENV!=="production"&&ti(w.props.interactive&&ge===wr.appendTo&&ke.nextElementSibling!==O,["Interactive tippy element may not be accessible via keyboard","navigation because it is not directly after the reference element","in the DOM source order.",`
|
|
348
348
|
|
|
349
349
|
`,"Using a wrapper <div> or <span> tag around the reference element","solves this by creating a new parentNode context.",`
|
|
350
350
|
|
|
351
351
|
`,"Specifying `appendTo: document.body` silences this warning, but it","assumes you are using a focus management solution to handle","keyboard navigation.",`
|
|
352
352
|
|
|
353
|
-
`,"See: https://atomiks.github.io/tippyjs/v6/accessibility/#interactivity"].join(" "))}function Je(){return If(O.querySelectorAll("[data-tippy-root]"))}function De(ge){w.clearDelayTimeouts(),ge&&
|
|
353
|
+
`,"See: https://atomiks.github.io/tippyjs/v6/accessibility/#interactivity"].join(" "))}function Je(){return If(O.querySelectorAll("[data-tippy-root]"))}function De(ge){w.clearDelayTimeouts(),ge&&U("onTrigger",[w,ge]),re();var $e=R(!0),ke=M(),Re=ke[0],Ge=ke[1];Oo.isTouch&&Re==="hold"&&Ge&&($e=Ge),$e?r=setTimeout(function(){w.show()},$e):w.show()}function ct(ge){if(w.clearDelayTimeouts(),U("onUntrigger",[w,ge]),!w.state.isVisible){he();return}if(!(w.props.trigger.indexOf("mouseenter")>=0&&w.props.trigger.indexOf("click")>=0&&["mouseleave","mousemove"].indexOf(ge.type)>=0&&s)){var $e=R(!1);$e?o=setTimeout(function(){w.state.isVisible&&w.hide()},$e):i=requestAnimationFrame(function(){w.hide()})}}function Ct(){w.state.isEnabled=!0}function Xt(){w.hide(),w.state.isEnabled=!1}function Sn(){clearTimeout(r),clearTimeout(o),cancelAnimationFrame(i)}function un(ge){if(process.env.NODE_ENV!=="production"&&ti(w.state.isDestroyed,Ka("setProps")),!w.state.isDestroyed){U("onBeforeUpdate",[w,ge]),te();var $e=w.props,ke=z2(t,Object.assign({},$e,I2(ge),{ignoreAttributes:!0}));w.props=ke,ce(),$e.interactiveDebounce!==ke.interactiveDebounce&&(Z(),y=O2(ue,ke.interactiveDebounce)),$e.triggerTarget&&!ke.triggerTarget?Ua($e.triggerTarget).forEach(function(Re){Re.removeAttribute("aria-expanded")}):ke.triggerTarget&&t.removeAttribute("aria-expanded"),Y(),q(),L&&L($e,ke),w.popperInstance&&(Me(),Je().forEach(function(Re){requestAnimationFrame(Re._tippy.popperInstance.forceUpdate)})),U("onAfterUpdate",[w,ge])}}function $t(ge){w.setProps({content:ge})}function In(){process.env.NODE_ENV!=="production"&&ti(w.state.isDestroyed,Ka("show"));var ge=w.state.isVisible,$e=w.state.isDestroyed,ke=!w.state.isEnabled,Re=Oo.isTouch&&!w.props.touch,Ge=tv(w.props.duration,0,wr.duration);if(!(ge||$e||ke||Re)&&!z().hasAttribute("disabled")&&(U("onShow",[w],!1),w.props.onShow(w)!==!1)){if(w.state.isVisible=!0,N()&&(O.style.visibility="visible"),q(),re(),w.state.isMounted||(O.style.transition="none"),N()){var nt=B(),Pt=nt.box,rr=nt.content;rv([Pt,rr],0)}g=function(){var si;if(!(!w.state.isVisible||u)){if(u=!0,O.offsetHeight,O.style.transition=w.props.moveTransition,N()&&w.props.animation){var su=B(),rl=su.box,Zi=su.content;rv([rl,Zi],Ge),D2([rl,Zi],"visible")}G(),Y(),A2(lv,w),(si=w.popperInstance)==null||si.forceUpdate(),U("onMount",[w]),w.props.animation&&N()&&X(Ge,function(){w.state.isShown=!0,U("onShown",[w])})}},je()}}function Kn(){process.env.NODE_ENV!=="production"&&ti(w.state.isDestroyed,Ka("hide"));var ge=!w.state.isVisible,$e=w.state.isDestroyed,ke=!w.state.isEnabled,Re=tv(w.props.duration,1,wr.duration);if(!(ge||$e||ke)&&(U("onHide",[w],!1),w.props.onHide(w)!==!1)){if(w.state.isVisible=!1,w.state.isShown=!1,u=!1,s=!1,N()&&(O.style.visibility="hidden"),Z(),he(),q(!0),N()){var Ge=B(),nt=Ge.box,Pt=Ge.content;w.props.animation&&(rv([nt,Pt],Re),D2([nt,Pt],"hidden"))}G(),Y(),w.props.animation?N()&&le(Re,w.unmount):w.unmount()}}function ft(ge){process.env.NODE_ENV!=="production"&&ti(w.state.isDestroyed,Ka("hideWithInteractivity")),V().addEventListener("mousemove",y),A2(Df,y),y(ge)}function $n(){process.env.NODE_ENV!=="production"&&ti(w.state.isDestroyed,Ka("unmount")),w.state.isVisible&&w.hide(),w.state.isMounted&&(Fe(),Je().forEach(function(ge){ge._tippy.unmount()}),O.parentNode&&O.parentNode.removeChild(O),lv=lv.filter(function(ge){return ge!==w}),w.state.isMounted=!1,U("onHidden",[w]))}function Yt(){process.env.NODE_ENV!=="production"&&ti(w.state.isDestroyed,Ka("destroy")),!w.state.isDestroyed&&(w.clearDelayTimeouts(),w.unmount(),te(),delete t._tippy,w.state.isDestroyed=!0,U("onDestroy",[w]))}}function Hc(t,e){e===void 0&&(e={});var n=wr.plugins.concat(e.plugins||[]);process.env.NODE_ENV!=="production"&&(LJ(t),V2(e,n)),AJ();var r=Object.assign({},e,{plugins:n}),o=TJ(t);if(process.env.NODE_ENV!=="production"){var i=zc(r.content),s=o.length>1;ti(i&&s,["tippy() was passed an Element as the `content` prop, but more than","one tippy instance was created by this invocation. This means the","content element will only be appended to the last tippy instance.",`
|
|
354
354
|
|
|
355
355
|
`,"Instead, pass the .innerHTML of the element, or use a function that","returns a cloned version of the element instead.",`
|
|
356
356
|
|
|
@@ -387,17 +387,17 @@ img.ProseMirror-separator {
|
|
|
387
387
|
*
|
|
388
388
|
* This source code is licensed under the MIT license found in the
|
|
389
389
|
* LICENSE file in the root directory of this source tree.
|
|
390
|
-
*/var Y2;function tZ(){return Y2||(Y2=1,process.env.NODE_ENV!=="production"&&function(){typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(new Error);var t=J,e=Pf;function n(f,p){return f===p&&(f!==0||1/f===1/p)||f!==f&&p!==p}var r=typeof Object.is=="function"?Object.is:n,o=e.useSyncExternalStore,i=t.useRef,s=t.useEffect,a=t.useMemo,l=t.useDebugValue;function u(f,p,g,m,y){var b=i(null),S;b.current===null?(S={hasValue:!1,value:null},b.current=S):S=b.current;var C=a(function(){var E=!1,O,L,P=function(N){if(!E){E=!0,O=N;var V=m(N);if(y!==void 0&&S.hasValue){var R=S.value;if(y(R,V))return L=R,R}return L=V,V}var B=O,z=L;if(r(B,N))return z;var q=m(N);return y!==void 0&&y(z,q)?z:(O=N,L=q,q)},$=g===void 0?null:g,M=function(){return P(p())},A=$===null?void 0:function(){return P($())};return[M,A]},[p,g,m,y]),T=C[0],_=C[1],w=o(f,T,_);return s(function(){S.hasValue=!0,S.value=w},[w]),l(w),w}hv.useSyncExternalStoreWithSelector=u,typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(new Error)}()),hv}process.env.NODE_ENV==="production"?fv.exports=eZ():fv.exports=tZ();var nZ=fv.exports;const rZ=typeof window<"u"?J.useLayoutEffect:J.useEffect;class oZ{constructor(e){this.transactionNumber=0,this.lastTransactionNumber=0,this.subscribers=new Set,this.editor=e,this.lastSnapshot={editor:e,transactionNumber:0},this.getSnapshot=this.getSnapshot.bind(this),this.getServerSnapshot=this.getServerSnapshot.bind(this),this.watch=this.watch.bind(this),this.subscribe=this.subscribe.bind(this)}getSnapshot(){return this.transactionNumber===this.lastTransactionNumber?this.lastSnapshot:(this.lastTransactionNumber=this.transactionNumber,this.lastSnapshot={editor:this.editor,transactionNumber:this.transactionNumber},this.lastSnapshot)}getServerSnapshot(){return{editor:null,transactionNumber:0}}subscribe(e){return this.subscribers.add(e),()=>{this.subscribers.delete(e)}}watch(e){if(this.editor=e,this.editor){const n=()=>{this.transactionNumber+=1,this.subscribers.forEach(o=>o())},r=this.editor;return r.on("transaction",n),()=>{r.off("transaction",n)}}}}function iZ(t){var e;const[n]=J.useState(()=>new oZ(t.editor)),r=nZ.useSyncExternalStoreWithSelector(n.subscribe,n.getSnapshot,n.getServerSnapshot,t.selector,(e=t.equalityFn)!==null&&e!==void 0?e:QJ);return rZ(()=>n.watch(t.editor),[t.editor,n]),J.useDebugValue(r),r}const G2=process.env.NODE_ENV!=="production",gv=typeof window>"u",sZ=gv||!!(typeof window<"u"&&window.next);class mv{constructor(e){this.editor=null,this.subscriptions=new Set,this.isComponentMounted=!1,this.previousDeps=null,this.instanceId="",this.options=e,this.subscriptions=new Set,this.setEditor(this.getInitialEditor()),this.scheduleDestroy(),this.getEditor=this.getEditor.bind(this),this.getServerSnapshot=this.getServerSnapshot.bind(this),this.subscribe=this.subscribe.bind(this),this.refreshEditorInstance=this.refreshEditorInstance.bind(this),this.scheduleDestroy=this.scheduleDestroy.bind(this),this.onRender=this.onRender.bind(this),this.createEditor=this.createEditor.bind(this)}setEditor(e){this.editor=e,this.instanceId=Math.random().toString(36).slice(2,9),this.subscriptions.forEach(n=>n())}getInitialEditor(){if(this.options.current.immediatelyRender===void 0)return gv||sZ?(G2&&console.warn("Tiptap Error: SSR has been detected, please set `immediatelyRender` explicitly to `false` to avoid hydration mismatches."),null):this.createEditor();if(this.options.current.immediatelyRender&&gv&&G2)throw new Error("Tiptap Error: SSR has been detected, and `immediatelyRender` has been set to `true` this is an unsupported configuration that may result in errors, explicitly set `immediatelyRender` to `false` to avoid hydration mismatches.");return this.options.current.immediatelyRender?this.createEditor():null}createEditor(){const e={...this.options.current,onBeforeCreate:(...r)=>{var o,i;return(i=(o=this.options.current).onBeforeCreate)===null||i===void 0?void 0:i.call(o,...r)},onBlur:(...r)=>{var o,i;return(i=(o=this.options.current).onBlur)===null||i===void 0?void 0:i.call(o,...r)},onCreate:(...r)=>{var o,i;return(i=(o=this.options.current).onCreate)===null||i===void 0?void 0:i.call(o,...r)},onDestroy:(...r)=>{var o,i;return(i=(o=this.options.current).onDestroy)===null||i===void 0?void 0:i.call(o,...r)},onFocus:(...r)=>{var o,i;return(i=(o=this.options.current).onFocus)===null||i===void 0?void 0:i.call(o,...r)},onSelectionUpdate:(...r)=>{var o,i;return(i=(o=this.options.current).onSelectionUpdate)===null||i===void 0?void 0:i.call(o,...r)},onTransaction:(...r)=>{var o,i;return(i=(o=this.options.current).onTransaction)===null||i===void 0?void 0:i.call(o,...r)},onUpdate:(...r)=>{var o,i;return(i=(o=this.options.current).onUpdate)===null||i===void 0?void 0:i.call(o,...r)},onContentError:(...r)=>{var o,i;return(i=(o=this.options.current).onContentError)===null||i===void 0?void 0:i.call(o,...r)},onDrop:(...r)=>{var o,i;return(i=(o=this.options.current).onDrop)===null||i===void 0?void 0:i.call(o,...r)},onPaste:(...r)=>{var o,i;return(i=(o=this.options.current).onPaste)===null||i===void 0?void 0:i.call(o,...r)}};return new jK(e)}getEditor(){return this.editor}getServerSnapshot(){return null}subscribe(e){return this.subscriptions.add(e),()=>{this.subscriptions.delete(e)}}static compareOptions(e,n){return Object.keys(e).every(r=>["onCreate","onBeforeCreate","onDestroy","onUpdate","onTransaction","onFocus","onBlur","onSelectionUpdate","onContentError","onDrop","onPaste"].includes(r)?!0:r==="extensions"&&e.extensions&&n.extensions?e.extensions.length!==n.extensions.length?!1:e.extensions.every((o,i)=>{var s;return o===((s=n.extensions)===null||s===void 0?void 0:s[i])}):e[r]===n[r])}onRender(e){return()=>(this.isComponentMounted=!0,clearTimeout(this.scheduledDestructionTimeout),this.editor&&!this.editor.isDestroyed&&e.length===0?mv.compareOptions(this.options.current,this.editor.options)||this.editor.setOptions({...this.options.current,editable:this.editor.isEditable}):this.refreshEditorInstance(e),()=>{this.isComponentMounted=!1,this.scheduleDestroy()})}refreshEditorInstance(e){if(this.editor&&!this.editor.isDestroyed){if(this.previousDeps===null){this.previousDeps=e;return}if(this.previousDeps.length===e.length&&this.previousDeps.every((r,o)=>r===e[o]))return}this.editor&&!this.editor.isDestroyed&&this.editor.destroy(),this.setEditor(this.createEditor()),this.previousDeps=e}scheduleDestroy(){const e=this.instanceId,n=this.editor;this.scheduledDestructionTimeout=setTimeout(()=>{if(this.isComponentMounted&&this.instanceId===e){n&&n.setOptions(this.options.current);return}n&&!n.isDestroyed&&(n.destroy(),this.instanceId===e&&this.setEditor(null))},1)}}function J2(t={},e=[]){const n=J.useRef(t);n.current=t;const[r]=J.useState(()=>new mv(n)),o=Pf.useSyncExternalStore(r.subscribe,r.getEditor,r.getServerSnapshot);return J.useDebugValue(o),J.useEffect(r.onRender(e)),iZ({editor:o,selector:({transactionNumber:i})=>t.shouldRerenderOnTransaction===!1?null:t.immediatelyRender&&i===0?0:i+1}),o}J.createContext({editor:null}).Consumer;const Z2=J.createContext({onDragStart:void 0}),X2=()=>J.useContext(Z2),aZ=t=>{const e=t.as||"div",{nodeViewContentRef:n}=X2();return J.createElement(e,{...t,ref:n,"data-node-view-content":"",style:{whiteSpace:"pre-wrap",...t.style}})},yv=J.forwardRef((t,e)=>{const{onDragStart:n}=X2(),r=t.as||"div";return J.createElement(r,{...t,ref:e,"data-node-view-wrapper":"",onDragStart:n,style:{whiteSpace:"normal",...t.style}})});function lZ(t){return!!(typeof t=="function"&&t.prototype&&t.prototype.isReactComponent)}function cZ(t){var e;return typeof t=="object"&&((e=t.$$typeof)===null||e===void 0?void 0:e.toString())==="Symbol(react.forward_ref)"}class Q2{constructor(e,{editor:n,props:r={},as:o="div",className:i=""}){this.ref=null,this.id=Math.floor(Math.random()*4294967295).toString(),this.component=e,this.editor=n,this.props=r,this.element=document.createElement(o),this.element.classList.add("react-renderer"),i&&this.element.classList.add(...i.split(" ")),this.editor.isInitialized?ls.flushSync(()=>{this.render()}):this.render()}render(){var e;const n=this.component,r=this.props,o=this.editor;(lZ(n)||cZ(n))&&(r.ref=i=>{this.ref=i}),this.reactElement=J.createElement(n,{...r}),(e=o==null?void 0:o.contentComponent)===null||e===void 0||e.setRenderer(this.id,this)}updateProps(e={}){this.props={...this.props,...e},this.render()}destroy(){var e;const n=this.editor;(e=n==null?void 0:n.contentComponent)===null||e===void 0||e.removeRenderer(this.id)}updateAttributes(e){Object.keys(e).forEach(n=>{this.element.setAttribute(n,e[n])})}}class uZ extends WK{mount(){const e={editor:this.editor,node:this.node,decorations:this.decorations,innerDecorations:this.innerDecorations,view:this.view,selected:!1,extension:this.extension,HTMLAttributes:this.HTMLAttributes,getPos:()=>this.getPos(),updateAttributes:(u={})=>this.updateAttributes(u),deleteNode:()=>this.deleteNode()};if(!this.component.displayName){const u=f=>f.charAt(0).toUpperCase()+f.substring(1);this.component.displayName=u(this.extension.name)}const o={onDragStart:this.onDragStart.bind(this),nodeViewContentRef:u=>{u&&this.contentDOMElement&&u.firstChild!==this.contentDOMElement&&u.appendChild(this.contentDOMElement)}},i=this.component,s=J.memo(u=>J.createElement(Z2.Provider,{value:o},J.createElement(i,u)));s.displayName="ReactNodeView",this.node.isLeaf?this.contentDOMElement=null:this.options.contentDOMElementTag?this.contentDOMElement=document.createElement(this.options.contentDOMElementTag):this.contentDOMElement=document.createElement(this.node.isInline?"span":"div"),this.contentDOMElement&&(this.contentDOMElement.dataset.nodeViewContentReact="",this.contentDOMElement.style.whiteSpace="inherit");let a=this.node.isInline?"span":"div";this.options.as&&(a=this.options.as);const{className:l=""}=this.options;this.handleSelectionUpdate=this.handleSelectionUpdate.bind(this),this.renderer=new Q2(s,{editor:this.editor,props:e,as:a,className:`node-${this.node.type.name} ${l}`.trim()}),this.editor.on("selectionUpdate",this.handleSelectionUpdate),this.updateElementAttributes()}get dom(){var e;if(this.renderer.element.firstElementChild&&!(!((e=this.renderer.element.firstElementChild)===null||e===void 0)&&e.hasAttribute("data-node-view-wrapper")))throw Error("Please use the NodeViewWrapper component for your node view.");return this.renderer.element}get contentDOM(){return this.node.isLeaf?null:this.contentDOMElement}handleSelectionUpdate(){const{from:e,to:n}=this.editor.state.selection,r=this.getPos();if(typeof r=="number")if(e<=r&&n>=r+this.node.nodeSize){if(this.renderer.props.selected)return;this.selectNode()}else{if(!this.renderer.props.selected)return;this.deselectNode()}}update(e,n,r){const o=i=>{this.renderer.updateProps(i),typeof this.options.attrs=="function"&&this.updateElementAttributes()};if(e.type!==this.node.type)return!1;if(typeof this.options.update=="function"){const i=this.node,s=this.decorations,a=this.innerDecorations;return this.node=e,this.decorations=n,this.innerDecorations=r,this.options.update({oldNode:i,oldDecorations:s,newNode:e,newDecorations:n,oldInnerDecorations:a,innerDecorations:r,updateProps:()=>o({node:e,decorations:n,innerDecorations:r})})}return e===this.node&&this.decorations===n&&this.innerDecorations===r||(this.node=e,this.decorations=n,this.innerDecorations=r,o({node:e,decorations:n,innerDecorations:r})),!0}selectNode(){this.renderer.updateProps({selected:!0}),this.renderer.element.classList.add("ProseMirror-selectednode")}deselectNode(){this.renderer.updateProps({selected:!1}),this.renderer.element.classList.remove("ProseMirror-selectednode")}destroy(){this.renderer.destroy(),this.editor.off("selectionUpdate",this.handleSelectionUpdate),this.contentDOMElement=null}updateElementAttributes(){if(this.options.attrs){let e={};if(typeof this.options.attrs=="function"){const n=this.editor.extensionManager.attributes,r=uf(this.node,n);e=this.options.attrs({node:this.node,HTMLAttributes:r})}else e=this.options.attrs;this.renderer.updateAttributes(e)}}}function bv(t,e){return n=>n.editor.contentComponent?new uZ(t,n,e):{}}const vv=Rs("RichTextContent",["root","readonly","editable"]),dZ=Ut({name:{RichTextContent:xv}})(t=>({root:{"& .ProseMirror":{...t2(t)}},readonly:{},editable:{}}));function xv({className:t,classes:e={}}){const{classes:n,cx:r}=dZ(void 0,{props:{classes:e}}),o=bt(),i=J.useMemo(()=>r(vv.root,t,n.root,o!=null&&o.isEditable?[vv.editable,n.editable]:[vv.readonly,n.readonly]),[t,n,r,o==null?void 0:o.isEditable]);return v.jsx(F.Box,{className:i,component:ZJ,editor:o})}function eI({editor:t,children:e}){return v.jsx(r2.Provider,{value:t,children:e})}const Ya=Rs("FieldContainer",["root","outlined","standard","focused","disabled","notchedOutline"]),fZ=Ut({name:{FieldContainer:tI},uniqId:"Os7ZPW"})((t,e,n)=>({root:{},outlined:{borderRadius:t.shape.borderRadius,padding:1,position:"relative",[`&:hover .${n.notchedOutline}`]:{borderColor:t.palette.text.primary},[`&.${n.focused} .${n.notchedOutline}`]:{borderColor:t.palette.primary.main,borderWidth:2},[`&.${n.disabled} .${n.notchedOutline}`]:{borderColor:t.palette.action.disabled}},standard:{},focused:{},disabled:{},notchedOutline:{position:"absolute",inset:0,borderRadius:"inherit",borderColor:t.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)",borderStyle:"solid",borderWidth:1,pointerEvents:"none",overflow:"hidden",zIndex:Of.NOTCHED_OUTLINE}}));function tI({variant:t="outlined",children:e,focused:n,disabled:r,classes:o={},className:i}){const{classes:s,cx:a}=fZ(void 0,{props:{classes:o}});return v.jsxs("div",{className:a(Ya.root,s.root,t==="outlined"?[Ya.outlined,s.outlined]:[Ya.standard,s.standard],n&&[Ya.focused,s.focused],r&&[Ya.disabled,s.disabled],i),children:[e,t==="outlined"&&v.jsx("div",{className:a(Ya.notchedOutline,s.notchedOutline),"aria-hidden":!0})]})}var pZ=DC();const nI=Zn(pZ);function rI({editor:t,wait:e=250}){const[n,r]=J.useState(!!(t!=null&&t.isFocused)),o=J.useMemo(()=>nI(i=>{r(i)},e),[e]);return J.useEffect(()=>{const i=!!(t!=null&&t.isFocused);return o(i),i&&o.flush(),()=>{o.cancel()}},[t==null?void 0:t.isFocused,o]),n}class Sv extends J.Component{constructor(e){var n,r;super(e),this.updateDebounced=nI(this.forceUpdate,(n=e.wait)!==null&&n!==void 0?n:170,(r=e.options)!==null&&r!==void 0?r:{leading:!0,trailing:!0,maxWait:300})}shouldComponentUpdate(){return this.updateDebounced(),!1}componentWillUnmount(){this.updateDebounced.cancel()}render(){return this.props.children}}const Ga=Rs("RichTextField",["root","standard","outlined","menuBar","menuBarContent","content"]),hZ=Ut({name:{RichTextField:oI},uniqId:"E2Alw3"})((t,e,n)=>({root:{},standard:{[`& .${n.content}`]:{padding:t.spacing(1.5,0)},[`& .${n.menuBarContent}`]:{padding:t.spacing(1,0)}},outlined:{[`& .${n.content}`]:{padding:t.spacing(1.5)},[`& .${n.menuBarContent}`]:{padding:t.spacing(1,1.5)}},menuBar:{},menuBarContent:{},content:{}}));function oI({variant:t="outlined",controls:e,disableDebounceRenderControls:n=!1,disabled:r,className:o,classes:i={},footer:s,MenuBarProps:a,RichTextContentProps:l}){var u,f;const{classes:p,cx:g}=hZ(void 0,{props:{classes:i}}),m=bt(),y=rI({editor:m});return v.jsxs(tI,{variant:t,focused:!r&&y,disabled:r,className:g(Ga.root,p.root,t==="outlined"?[Ga.outlined,p.outlined]:[Ga.standard,p.standard],o),children:[e&&v.jsx(w2,{...a,classes:{...a==null?void 0:a.classes,root:g(Ga.menuBar,p.menuBar,(u=a==null?void 0:a.classes)===null||u===void 0?void 0:u.root),content:g(Ga.content,p.menuBarContent,(f=a==null?void 0:a.classes)===null||f===void 0?void 0:f.content)},children:n?e:v.jsx(Sv,{children:e})}),v.jsx(xv,{...l,className:g(Ga.content,p.content,l==null?void 0:l.className)}),s]})}const iI=J.forwardRef(function({className:e,renderControls:n,RichTextFieldProps:r={},children:o,editorDependencies:i=[],editable:s=!0,...a},l){const u=J2({editable:s,...a},i);return J.useImperativeHandle(l,()=>({editor:u}),[u]),J.useEffect(()=>{!u||u.isDestroyed||u.isEditable===s||queueMicrotask(()=>{u.setEditable(s)})},[s,u]),v.jsxs(eI,{editor:u,children:[v.jsx(oI,{disabled:!s,controls:n==null?void 0:n(u),className:e,...r}),o==null?void 0:o(u)]})});function gZ(t){const e=J2({...t,editable:!1}),n=J.useRef(t.content);return J.useEffect(()=>{!e||e.isDestroyed||t.content===void 0||t.content===n.current||queueMicrotask(()=>{t.content!==void 0&&e.commands.setContent(t.content)})},[t.content,e]),J.useEffect(()=>{n.current=t.content},[t.content]),v.jsx(eI,{editor:e,children:v.jsx(xv,{})})}function mZ(t){return t.content?v.jsx(gZ,{...t}):null}const yZ=F.createSvgIcon(v.jsxs(v.Fragment,{children:[v.jsx("path",{d:"M20 3H4c-1.103 0-2 .897-2 2v14c0 1.103.897 2 2 2h16c1.103 0 2-.897 2-2V5c0-1.103-.897-2-2-2zM4 19V7h16l.002 12H4z"}),v.jsx("path",{d:"M9.293 9.293 5.586 13l3.707 3.707 1.414-1.414L8.414 13l2.293-2.293zm5.414 0-1.414 1.414L15.586 13l-2.293 2.293 1.414 1.414L18.414 13z"})]}),"CodeBlock"),bZ=F.createSvgIcon(v.jsx("path",{d:"M12 3C12.5523 3 13 3.44772 13 4L12.9998 11.9998C13.8355 11.372 14.8743 11 16 11C18.7614 11 21 13.2386 21 16C21 18.7614 18.7614 21 16 21C14.9681 21 14.0092 20.6874 13.2129 20.1518L13 20C13 20.5523 12.5523 21 12 21H6C5.44772 21 5 20.5523 5 20V4C5 3.44772 5.44772 3 6 3H12ZM11 5H7V19H11V5ZM19 15H13V17H19V15Z"}),"DeleteColumn"),vZ=F.createSvgIcon(v.jsx("path",{d:"M20 5C20.5523 5 21 5.44772 21 6V12C21 12.5523 20.5523 13 20 13C20.628 13.8355 21 14.8743 21 16C21 18.7614 18.7614 21 16 21C13.2386 21 11 18.7614 11 16C11 14.8743 11.372 13.8355 11.9998 12.9998L4 13C3.44772 13 3 12.5523 3 12V6C3 5.44772 3.44772 5 4 5H20ZM13 15V17H19V15H13ZM19 7H5V11H19V7Z"}),"DeleteRow"),xZ=F.createSvgIcon(v.jsx("path",{d:"M 2 20 h 20 v 4 H 2 v -4 z"}),"FormatColorBar"),SZ=F.createSvgIcon(v.jsx("path",{d:"M 5.49 17 h 2.42 l 1.27 -3.58 h 5.65 L 16.09 17 h 2.42 L 13.25 3 h -2.5 L 5.49 17 z m 4.42 -5.61 l 2.03 -5.79 h 0.12 l 2.03 5.79 H 9.91 z"}),"FormatColorTextNoBar"),CZ=F.createSvgIcon(v.jsx("path",{d:"M 10.6 8 l 5.4 5.425 l -4 4 q -0.6 0.6 -1.413 0.6 t -1.412 -0.6 L 8.5 18 h -5 l 3.15 -3.125 q -0.6 -0.6 -0.625 -1.438 T 6.6 12 l 4 -4 Z M 12 6.575 L 16 2.6 q 0.6 -0.6 1.413 -0.6 t 1.412 0.6 l 2.6 2.575 q 0.6 0.6 0.6 1.413 T 21.425 8 l -4 4 L 12 6.575 Z"}),"FormatInkHighlighterNoBar"),wZ=F.createSvgIcon(v.jsx("path",{d:"M20 3C20.5523 3 21 3.44772 21 4V20C21 20.5523 20.5523 21 20 21H14C13.4477 21 13 20.5523 13 20V4C13 3.44772 13.4477 3 14 3H20ZM19 5H15V19H19V5ZM6 7C8.76142 7 11 9.23858 11 12C11 14.7614 8.76142 17 6 17C3.23858 17 1 14.7614 1 12C1 9.23858 3.23858 7 6 7ZM7 9H5V10.999L3 11V13L5 12.999V15H7V12.999L9 13V11L7 10.999V9Z"}),"InsertColumnLeft"),_Z=F.createSvgIcon(v.jsx("path",{d:"M10 3C10.5523 3 11 3.44772 11 4V20C11 20.5523 10.5523 21 10 21H4C3.44772 21 3 20.5523 3 20V4C3 3.44772 3.44772 3 4 3H10ZM9 5H5V19H9V5ZM18 7C20.7614 7 23 9.23858 23 12C23 14.7614 20.7614 17 18 17C15.2386 17 13 14.7614 13 12C13 9.23858 15.2386 7 18 7ZM19 9H17V10.999L15 11V13L17 12.999V15H19V12.999L21 13V11L19 10.999V9Z"}),"InsertColumnRight"),TZ=F.createSvgIcon(v.jsx("path",{d:"M12 13C14.7614 13 17 15.2386 17 18C17 20.7614 14.7614 23 12 23C9.23858 23 7 20.7614 7 18C7 15.2386 9.23858 13 12 13ZM13 15H11V16.999L9 17V19L11 18.999V21H13V18.999L15 19V17L13 16.999V15ZM20 3C20.5523 3 21 3.44772 21 4V10C21 10.5523 20.5523 11 20 11H4C3.44772 11 3 10.5523 3 10V4C3 3.44772 3.44772 3 4 3H20ZM5 5V9H19V5H5Z"}),"InsertRowBottom"),kZ=F.createSvgIcon(v.jsx("path",{d:"M20 13C20.5523 13 21 13.4477 21 14V20C21 20.5523 20.5523 21 20 21H4C3.44772 21 3 20.5523 3 20V14C3 13.4477 3.44772 13 4 13H20ZM19 15H5V19H19V15ZM12 1C14.7614 1 17 3.23858 17 6C17 8.76142 14.7614 11 12 11C9.23858 11 7 8.76142 7 6C7 3.23858 9.23858 1 12 1ZM13 3H11V4.999L9 5V7L11 6.999V9H13V6.999L15 7V5L13 4.999V3Z"}),"InsertRowTop"),EZ=F.createSvgIcon(v.jsx("path",{d:"M12 5V19H19V5H12ZM4 3H20C20.5523 3 21 3.44772 21 4V20C21 20.5523 20.5523 21 20 21H4C3.44772 21 3 20.5523 3 20V4C3 3.44772 3.44772 3 4 3Z"}),"LayoutColumnFill"),MZ=F.createSvgIcon(v.jsx("path",{d:"M19 12H5V19H19V12ZM4 3H20C20.5523 3 21 3.44772 21 4V20C21 20.5523 20.5523 21 20 21H4C3.44772 21 3 20.5523 3 20V4C3 3.44772 3.44772 3 4 3Z"}),"LayoutRowFill"),OZ=F.createSvgIcon(v.jsx("path",{d:"M20 3C20.5523 3 21 3.44772 21 4V20C21 20.5523 20.5523 21 20 21H4C3.44772 21 3 20.5523 3 20V4C3 3.44772 3.44772 3 4 3H20ZM11 5H5V10.999H7V9L10 12L7 15V13H5V19H11V17H13V19H19V13H17V15L14 12L17 9V10.999H19V5H13V7H11V5ZM13 13V15H11V13H13ZM13 9V11H11V9H13Z"}),"MergeCellsHorizontal"),AZ=F.createSvgIcon(v.jsx("path",{d:"M20 3C20.5523 3 21 3.44772 21 4V20C21 20.5523 20.5523 21 20 21H4C3.44772 21 3 20.5523 3 20V4C3 3.44772 3.44772 3 4 3H20ZM11 5H5V19H11V15H13V19H19V5H13V9H11V5ZM15 9L18 12L15 15V13H9V15L6 12L9 9V11H15V9Z"}),"SplitCellsHorizontal"),IZ=F.createSvgIcon(v.jsx("path",{d:"M4 21h15.893c1.103 0 2-.897 2-2V5c0-1.103-.897-2-2-2H4c-1.103 0-2 .897-2 2v14c0 1.103.897 2 2 2zm0-2v-5h4v5H4zM14 7v5h-4V7h4zM8 7v5H4V7h4zm2 12v-5h4v5h-4zm6 0v-5h3.894v5H16zm3.893-7H16V7h3.893v5z"}),"Table");let Cv,wv;function DZ(){return Cv===void 0&&(Cv=navigator.platform.includes("Mac")),Cv}function PZ(){return DZ()?"⌘":"Ctrl"}function NZ(){return wv===void 0&&(wv=window&&"ontouchstart"in window||navigator.maxTouchPoints>0||navigator.msMaxTouchPoints>0),wv}const LZ=Ut({name:{MenuButtonTooltip:co}})(t=>({titleContainer:{textAlign:"center"},label:{fontSize:t.typography.pxToRem(13)},shortcutKey:{fontSize:t.typography.pxToRem(12),border:`1px solid ${F.alpha(t.palette.text.secondary,.2)}`,backgroundColor:F.alpha(t.palette.background.paper,.3),height:"19px",lineHeight:"19px",padding:"0 4px",minWidth:17,borderRadius:t.shape.borderRadius,display:"inline-block","&:not(:first-of-type)":{marginLeft:1}}}));function co({label:t,shortcutKeys:e,placement:n="top",contentWrapperClassName:r,children:o,...i}){const{classes:s}=LZ();return v.jsx(F.Tooltip,{title:t||e&&e.length>0?v.jsxs("div",{className:s.titleContainer,children:[v.jsx("div",{className:s.label,children:t}),e&&e.length>0&&v.jsx(F.Typography,{variant:"body2",component:"div",children:e.map((a,l)=>v.jsx("span",{className:s.shortcutKey,children:a==="mod"?PZ():a},l))})]}):"",placement:n,arrow:!0,...i,children:v.jsx("span",{className:r,children:o})})}const jc="1.25rem",FZ=Ut({name:{MenuButton:gt}})({root:{[`&& .${F.toggleButtonClasses.root}`]:{border:"none",padding:5}},menuButtonIcon:{fontSize:jc}});function gt({tooltipLabel:t,tooltipShortcutKeys:e,IconComponent:n,buttonRef:r,children:o,...i}){const{classes:s}=FZ();return v.jsx("span",{className:s.root,children:v.jsx(co,{label:t,shortcutKeys:e,children:v.jsx(F.ToggleButton,{ref:r,size:"small",value:t,...i,children:o??(n&&v.jsx(n,{className:s.menuButtonIcon}))})})})}const $Z=Ut({name:{MenuControlsContainer:Nf}})(t=>({root:{display:"flex",rowGap:t.spacing(.3),columnGap:t.spacing(.3),alignItems:"center",flexWrap:"wrap"}}));function Nf({children:t,className:e,debounced:n,DebounceProps:r}){const{classes:o,cx:i}=$Z(),s=v.jsx("div",{className:i(o.root,e),children:t});return n?v.jsx(Sv,{...r,children:s}):s}function BZ({className:t,labels:e}){var n,r,o,i,s,a,l,u,f,p,g,m,y;const b=bt();return v.jsxs(Nf,{className:t,children:[v.jsx(gt,{tooltipLabel:(n=e==null?void 0:e.insertColumnBefore)!==null&&n!==void 0?n:"Insert column before",IconComponent:wZ,onClick:()=>b==null?void 0:b.chain().focus().addColumnBefore().run(),disabled:!(b!=null&&b.can().addColumnBefore())}),v.jsx(gt,{tooltipLabel:(r=e==null?void 0:e.insertColumnAfter)!==null&&r!==void 0?r:"Insert column after",IconComponent:_Z,onClick:()=>b==null?void 0:b.chain().focus().addColumnAfter().run(),disabled:!(b!=null&&b.can().addColumnAfter())}),v.jsx(gt,{tooltipLabel:(o=e==null?void 0:e.deleteColumn)!==null&&o!==void 0?o:"Delete column",IconComponent:bZ,onClick:()=>b==null?void 0:b.chain().focus().deleteColumn().run(),disabled:!(b!=null&&b.can().deleteColumn())}),v.jsx(Mn,{}),v.jsx(gt,{tooltipLabel:(i=e==null?void 0:e.insertRowAbove)!==null&&i!==void 0?i:"Insert row above",IconComponent:kZ,onClick:()=>b==null?void 0:b.chain().focus().addRowBefore().run(),disabled:!(b!=null&&b.can().addRowBefore())}),v.jsx(gt,{tooltipLabel:(s=e==null?void 0:e.insertRowBelow)!==null&&s!==void 0?s:"Insert row below",IconComponent:TZ,onClick:()=>b==null?void 0:b.chain().focus().addRowAfter().run(),disabled:!(b!=null&&b.can().addRowAfter())}),v.jsx(gt,{tooltipLabel:(a=e==null?void 0:e.deleteRow)!==null&&a!==void 0?a:"Delete row",IconComponent:vZ,onClick:()=>b==null?void 0:b.chain().focus().deleteRow().run(),disabled:!(b!=null&&b.can().deleteRow())}),v.jsx(Mn,{}),v.jsx(gt,{tooltipLabel:(l=e==null?void 0:e.mergeCells)!==null&&l!==void 0?l:"Merge cells",IconComponent:OZ,onClick:()=>b==null?void 0:b.chain().focus().mergeCells().run(),disabled:!(b!=null&&b.can().mergeCells())}),v.jsx(gt,{tooltipLabel:(u=e==null?void 0:e.splitCell)!==null&&u!==void 0?u:"Split cell",IconComponent:AZ,onClick:()=>b==null?void 0:b.chain().focus().splitCell().run(),disabled:!(b!=null&&b.can().splitCell())}),v.jsx(Mn,{}),v.jsx(gt,{tooltipLabel:(f=e==null?void 0:e.toggleHeaderRow)!==null&&f!==void 0?f:"Toggle header row",IconComponent:MZ,onClick:()=>b==null?void 0:b.chain().focus().toggleHeaderRow().run(),disabled:!(b!=null&&b.can().toggleHeaderRow())}),v.jsx(gt,{tooltipLabel:(p=e==null?void 0:e.toggleHeaderColumn)!==null&&p!==void 0?p:"Toggle header column",IconComponent:EZ,onClick:()=>b==null?void 0:b.chain().focus().toggleHeaderColumn().run(),disabled:!(b!=null&&b.can().toggleHeaderColumn())}),v.jsx(gt,{tooltipLabel:(g=e==null?void 0:e.toggleHeaderCell)!==null&&g!==void 0?g:"Toggle header cell",IconComponent:yR,onClick:()=>b==null?void 0:b.chain().focus().toggleHeaderCell().run(),disabled:!(b!=null&&b.can().toggleHeaderCell()),selected:(m=b==null?void 0:b.isActive("tableHeader"))!==null&&m!==void 0?m:!1}),v.jsx(Mn,{}),v.jsx(gt,{tooltipLabel:(y=e==null?void 0:e.deleteTable)!==null&&y!==void 0?y:"Delete table",IconComponent:kR,onClick:()=>b==null?void 0:b.chain().focus().deleteTable().run(),disabled:!(b!=null&&b.can().deleteTable())})]})}const RZ=Ut({name:{TableBubbleMenu:sI}})(t=>({controls:{maxWidth:"90vw",padding:t.spacing(.5,1)}}));function sI({disableDebounce:t=!1,DebounceProps:e,labels:n,...r}){const o=bt(),{classes:i}=RZ(),s=rI({editor:o}),a=J.useMemo(()=>o?{getBoundingClientRect:()=>{const u=o.isActive("table")?ty(o.state.selection.$anchor,m=>m.type.name==="table"):null;if(u){const m=o.view.nodeDOM(u.pos),y=m==null?void 0:m.querySelector("table");if(y)return y.getBoundingClientRect()}const{ranges:f}=o.state.selection,p=Math.min(...f.map(m=>m.$from.pos)),g=Math.max(...f.map(m=>m.$to.pos));return QE(o.view,p,g)}}:null,[o]);if(!(o!=null&&o.isEditable))return null;const l=v.jsx(BZ,{className:i.controls,labels:n});return v.jsx(Af,{editor:o,open:s&&o.isActive("table"),anchorEl:a,placement:"top-start",fallbackPlacements:["bottom-start","top","bottom","top-end","bottom-end"],flipPadding:{top:35,left:8,right:8,bottom:-1/0},...r,children:t?l:v.jsx(Sv,{...e,children:l})})}function Ja(){return(Ja=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t}).apply(this,arguments)}function _v(t,e){if(t==null)return{};var n,r,o={},i=Object.keys(t);for(r=0;r<i.length;r++)e.indexOf(n=i[r])>=0||(o[n]=t[n]);return o}function Tv(t){var e=J.useRef(t),n=J.useRef(function(r){e.current&&e.current(r)});return e.current=t,n.current}var Za=function(t,e,n){return e===void 0&&(e=0),n===void 0&&(n=1),t>n?n:t<e?e:t},Wc=function(t){return"touches"in t},kv=function(t){return t&&t.ownerDocument.defaultView||self},aI=function(t,e,n){var r=t.getBoundingClientRect(),o=Wc(e)?function(i,s){for(var a=0;a<i.length;a++)if(i[a].identifier===s)return i[a];return i[0]}(e.touches,n):e;return{left:Za((o.pageX-(r.left+kv(t).pageXOffset))/r.width),top:Za((o.pageY-(r.top+kv(t).pageYOffset))/r.height)}},lI=function(t){!Wc(t)&&t.preventDefault()},Ev=J.memo(function(t){var e=t.onMove,n=t.onKey,r=_v(t,["onMove","onKey"]),o=J.useRef(null),i=Tv(e),s=Tv(n),a=J.useRef(null),l=J.useRef(!1),u=J.useMemo(function(){var m=function(S){lI(S),(Wc(S)?S.touches.length>0:S.buttons>0)&&o.current?i(aI(o.current,S,a.current)):b(!1)},y=function(){return b(!1)};function b(S){var C=l.current,T=kv(o.current),_=S?T.addEventListener:T.removeEventListener;_(C?"touchmove":"mousemove",m),_(C?"touchend":"mouseup",y)}return[function(S){var C=S.nativeEvent,T=o.current;if(T&&(lI(C),!function(w,E){return E&&!Wc(w)}(C,l.current)&&T)){if(Wc(C)){l.current=!0;var _=C.changedTouches||[];_.length&&(a.current=_[0].identifier)}T.focus(),i(aI(T,C,a.current)),b(!0)}},function(S){var C=S.which||S.keyCode;C<37||C>40||(S.preventDefault(),s({left:C===39?.05:C===37?-.05:0,top:C===40?.05:C===38?-.05:0}))},b]},[s,i]),f=u[0],p=u[1],g=u[2];return J.useEffect(function(){return g},[g]),J.createElement("div",Ja({},r,{onTouchStart:f,onMouseDown:f,className:"react-colorful__interactive",ref:o,onKeyDown:p,tabIndex:0,role:"slider"}))}),qc=function(t){return t.filter(Boolean).join(" ")},Mv=function(t){var e=t.color,n=t.left,r=t.top,o=r===void 0?.5:r,i=qc(["react-colorful__pointer",t.className]);return J.createElement("div",{className:i,style:{top:100*o+"%",left:100*n+"%"}},J.createElement("div",{className:"react-colorful__pointer-fill",style:{backgroundColor:e}}))},On=function(t,e,n){return e===void 0&&(e=0),n===void 0&&(n=Math.pow(10,e)),Math.round(n*t)/n},cI=function(t){return HZ(Ov(t))},Ov=function(t){return t[0]==="#"&&(t=t.substring(1)),t.length<6?{r:parseInt(t[0]+t[0],16),g:parseInt(t[1]+t[1],16),b:parseInt(t[2]+t[2],16),a:t.length===4?On(parseInt(t[3]+t[3],16)/255,2):1}:{r:parseInt(t.substring(0,2),16),g:parseInt(t.substring(2,4),16),b:parseInt(t.substring(4,6),16),a:t.length===8?On(parseInt(t.substring(6,8),16)/255,2):1}},uI=function(t){return VZ(zZ(t))},dI=function(t){var e=t.s,n=t.v,r=t.a,o=(200-e)*n/100;return{h:On(t.h),s:On(o>0&&o<200?e*n/100/(o<=100?o:200-o)*100:0),l:On(o/2),a:On(r,2)}},Av=function(t){var e=dI(t);return"hsl("+e.h+", "+e.s+"%, "+e.l+"%)"},Iv=function(t){var e=dI(t);return"hsla("+e.h+", "+e.s+"%, "+e.l+"%, "+e.a+")"},zZ=function(t){var e=t.h,n=t.s,r=t.v,o=t.a;e=e/360*6,n/=100,r/=100;var i=Math.floor(e),s=r*(1-n),a=r*(1-(e-i)*n),l=r*(1-(1-e+i)*n),u=i%6;return{r:On(255*[r,a,s,s,l,r][u]),g:On(255*[l,r,r,a,s,s][u]),b:On(255*[s,s,l,r,r,a][u]),a:On(o,2)}},Lf=function(t){var e=t.toString(16);return e.length<2?"0"+e:e},VZ=function(t){var e=t.r,n=t.g,r=t.b,o=t.a,i=o<1?Lf(On(255*o)):"";return"#"+Lf(e)+Lf(n)+Lf(r)+i},HZ=function(t){var e=t.r,n=t.g,r=t.b,o=t.a,i=Math.max(e,n,r),s=i-Math.min(e,n,r),a=s?i===e?(n-r)/s:i===n?2+(r-e)/s:4+(e-n)/s:0;return{h:On(60*(a<0?a+6:a)),s:On(i?s/i*100:0),v:On(i/255*100),a:o}},fI=J.memo(function(t){var e=t.hue,n=t.onChange,r=qc(["react-colorful__hue",t.className]);return J.createElement("div",{className:r},J.createElement(Ev,{onMove:function(o){n({h:360*o.left})},onKey:function(o){n({h:Za(e+360*o.left,0,360)})},"aria-label":"Hue","aria-valuenow":On(e),"aria-valuemax":"360","aria-valuemin":"0"},J.createElement(Mv,{className:"react-colorful__hue-pointer",left:e/360,color:Av({h:e,s:100,v:100,a:1})})))}),pI=J.memo(function(t){var e=t.hsva,n=t.onChange,r={backgroundColor:Av({h:e.h,s:100,v:100,a:1})};return J.createElement("div",{className:"react-colorful__saturation",style:r},J.createElement(Ev,{onMove:function(o){n({s:100*o.left,v:100-100*o.top})},onKey:function(o){n({s:Za(e.s+100*o.left,0,100),v:Za(e.v-100*o.top,0,100)})},"aria-label":"Color","aria-valuetext":"Saturation "+On(e.s)+"%, Brightness "+On(e.v)+"%"},J.createElement(Mv,{className:"react-colorful__saturation-pointer",top:1-e.v/100,left:e.s/100,color:Av(e)})))}),hI=function(t,e){if(t===e)return!0;for(var n in t)if(t[n]!==e[n])return!1;return!0},gI=function(t,e){return t.toLowerCase()===e.toLowerCase()||hI(Ov(t),Ov(e))};function mI(t,e,n){var r=Tv(n),o=J.useState(function(){return t.toHsva(e)}),i=o[0],s=o[1],a=J.useRef({color:e,hsva:i});J.useEffect(function(){if(!t.equal(e,a.current.color)){var u=t.toHsva(e);a.current={hsva:u,color:e},s(u)}},[e,t]),J.useEffect(function(){var u;hI(i,a.current.hsva)||t.equal(u=t.fromHsva(i),a.current.color)||(a.current={hsva:i,color:u},r(u))},[i,t,r]);var l=J.useCallback(function(u){s(function(f){return Object.assign({},f,u)})},[]);return[i,l]}var jZ=typeof window<"u"?J.useLayoutEffect:J.useEffect,WZ=function(){return typeof __webpack_nonce__<"u"?__webpack_nonce__:void 0},yI=new Map,bI=function(t){jZ(function(){var e=t.current?t.current.ownerDocument:document;if(e!==void 0&&!yI.has(e)){var n=e.createElement("style");n.innerHTML=`.react-colorful{position:relative;display:flex;flex-direction:column;width:200px;height:200px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:default}.react-colorful__saturation{position:relative;flex-grow:1;border-color:transparent;border-bottom:12px solid #000;border-radius:8px 8px 0 0;background-image:linear-gradient(0deg,#000,transparent),linear-gradient(90deg,#fff,hsla(0,0%,100%,0))}.react-colorful__alpha-gradient,.react-colorful__pointer-fill{content:"";position:absolute;left:0;top:0;right:0;bottom:0;pointer-events:none;border-radius:inherit}.react-colorful__alpha-gradient,.react-colorful__saturation{box-shadow:inset 0 0 0 1px rgba(0,0,0,.05)}.react-colorful__alpha,.react-colorful__hue{position:relative;height:24px}.react-colorful__hue{background:linear-gradient(90deg,red 0,#ff0 17%,#0f0 33%,#0ff 50%,#00f 67%,#f0f 83%,red)}.react-colorful__last-control{border-radius:0 0 8px 8px}.react-colorful__interactive{position:absolute;left:0;top:0;right:0;bottom:0;border-radius:inherit;outline:none;touch-action:none}.react-colorful__pointer{position:absolute;z-index:1;box-sizing:border-box;width:28px;height:28px;transform:translate(-50%,-50%);background-color:#fff;border:2px solid #fff;border-radius:50%;box-shadow:0 2px 4px rgba(0,0,0,.2)}.react-colorful__interactive:focus .react-colorful__pointer{transform:translate(-50%,-50%) scale(1.1)}.react-colorful__alpha,.react-colorful__alpha-pointer{background-color:#fff;background-image:url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill-opacity=".05"><path d="M8 0h8v8H8zM0 8h8v8H0z"/></svg>')}.react-colorful__saturation-pointer{z-index:3}.react-colorful__hue-pointer{z-index:2}`,yI.set(e,n);var r=WZ();r&&n.setAttribute("nonce",r),e.head.appendChild(n)}},[])},qZ=function(t){var e=t.className,n=t.colorModel,r=t.color,o=r===void 0?n.defaultColor:r,i=t.onChange,s=_v(t,["className","colorModel","color","onChange"]),a=J.useRef(null);bI(a);var l=mI(n,o,i),u=l[0],f=l[1],p=qc(["react-colorful",e]);return J.createElement("div",Ja({},s,{ref:a,className:p}),J.createElement(pI,{hsva:u,onChange:f}),J.createElement(fI,{hue:u.h,onChange:f,className:"react-colorful__last-control"}))},UZ={defaultColor:"000",toHsva:cI,fromHsva:function(t){return uI({h:t.h,s:t.s,v:t.v,a:1})},equal:gI},KZ=function(t){return J.createElement(qZ,Ja({},t,{colorModel:UZ}))},YZ=function(t){var e=t.className,n=t.hsva,r=t.onChange,o={backgroundImage:"linear-gradient(90deg, "+Iv(Object.assign({},n,{a:0}))+", "+Iv(Object.assign({},n,{a:1}))+")"},i=qc(["react-colorful__alpha",e]),s=On(100*n.a);return J.createElement("div",{className:i},J.createElement("div",{className:"react-colorful__alpha-gradient",style:o}),J.createElement(Ev,{onMove:function(a){r({a:a.left})},onKey:function(a){r({a:Za(n.a+a.left)})},"aria-label":"Alpha","aria-valuetext":s+"%","aria-valuenow":s,"aria-valuemin":"0","aria-valuemax":"100"},J.createElement(Mv,{className:"react-colorful__alpha-pointer",left:n.a,color:Iv(n)})))},GZ=function(t){var e=t.className,n=t.colorModel,r=t.color,o=r===void 0?n.defaultColor:r,i=t.onChange,s=_v(t,["className","colorModel","color","onChange"]),a=J.useRef(null);bI(a);var l=mI(n,o,i),u=l[0],f=l[1],p=qc(["react-colorful",e]);return J.createElement("div",Ja({},s,{ref:a,className:p}),J.createElement(pI,{hsva:u,onChange:f}),J.createElement(fI,{hue:u.h,onChange:f}),J.createElement(YZ,{hsva:u,onChange:f,className:"react-colorful__last-control"}))},JZ={defaultColor:"0001",toHsva:cI,fromHsva:uI,equal:gI},ZZ=function(t){return J.createElement(GZ,Ja({},t,{colorModel:JZ}))};function XZ(t){try{return F.rgbToHex(t)}catch{return null}}const Dv=J.forwardRef(({value:t,label:e,padding:n,active:r,...o},i)=>{const{classes:s,cx:a,theme:l}=QZ();return v.jsx("button",{ref:i,type:"button",style:{backgroundColor:t,padding:n},"aria-label":e??t,value:t,...o,className:a(s.root,!t&&s.colorNotSet,o.className),children:r&&v.jsx(oR,{fontSize:"small",className:s.activeIcon,style:{color:t?l.palette.getContrastText(t):void 0}})})}),QZ=Ut({name:{ColorSwatchButton:Dv}})(t=>({root:{height:t.spacing(2.5),width:t.spacing(2.5),minWidth:t.spacing(2.5),borderRadius:t.shape.borderRadius,borderColor:t.palette.mode==="dark"?t.palette.grey[700]:t.palette.grey[400],borderStyle:"solid",borderWidth:1,cursor:"pointer",padding:0,backgroundClip:"content-box"},activeIcon:{height:"100%",width:"80%",verticalAlign:"middle"},colorNotSet:{background:`repeating-conic-gradient(
|
|
390
|
+
*/var Y2;function tZ(){return Y2||(Y2=1,process.env.NODE_ENV!=="production"&&function(){typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(new Error);var t=J,e=Pf;function n(f,p){return f===p&&(f!==0||1/f===1/p)||f!==f&&p!==p}var r=typeof Object.is=="function"?Object.is:n,o=e.useSyncExternalStore,i=t.useRef,s=t.useEffect,a=t.useMemo,l=t.useDebugValue;function u(f,p,g,m,y){var b=i(null),S;b.current===null?(S={hasValue:!1,value:null},b.current=S):S=b.current;var C=a(function(){var E=!1,O,L,P=function(N){if(!E){E=!0,O=N;var z=m(N);if(y!==void 0&&S.hasValue){var V=S.value;if(y(V,z))return L=V,V}return L=z,z}var B=O,R=L;if(r(B,N))return R;var q=m(N);return y!==void 0&&y(R,q)?R:(O=N,L=q,q)},$=g===void 0?null:g,M=function(){return P(p())},A=$===null?void 0:function(){return P($())};return[M,A]},[p,g,m,y]),T=C[0],_=C[1],w=o(f,T,_);return s(function(){S.hasValue=!0,S.value=w},[w]),l(w),w}hv.useSyncExternalStoreWithSelector=u,typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(new Error)}()),hv}process.env.NODE_ENV==="production"?fv.exports=eZ():fv.exports=tZ();var nZ=fv.exports;const rZ=typeof window<"u"?J.useLayoutEffect:J.useEffect;class oZ{constructor(e){this.transactionNumber=0,this.lastTransactionNumber=0,this.subscribers=new Set,this.editor=e,this.lastSnapshot={editor:e,transactionNumber:0},this.getSnapshot=this.getSnapshot.bind(this),this.getServerSnapshot=this.getServerSnapshot.bind(this),this.watch=this.watch.bind(this),this.subscribe=this.subscribe.bind(this)}getSnapshot(){return this.transactionNumber===this.lastTransactionNumber?this.lastSnapshot:(this.lastTransactionNumber=this.transactionNumber,this.lastSnapshot={editor:this.editor,transactionNumber:this.transactionNumber},this.lastSnapshot)}getServerSnapshot(){return{editor:null,transactionNumber:0}}subscribe(e){return this.subscribers.add(e),()=>{this.subscribers.delete(e)}}watch(e){if(this.editor=e,this.editor){const n=()=>{this.transactionNumber+=1,this.subscribers.forEach(o=>o())},r=this.editor;return r.on("transaction",n),()=>{r.off("transaction",n)}}}}function iZ(t){var e;const[n]=J.useState(()=>new oZ(t.editor)),r=nZ.useSyncExternalStoreWithSelector(n.subscribe,n.getSnapshot,n.getServerSnapshot,t.selector,(e=t.equalityFn)!==null&&e!==void 0?e:QJ);return rZ(()=>n.watch(t.editor),[t.editor,n]),J.useDebugValue(r),r}const G2=process.env.NODE_ENV!=="production",gv=typeof window>"u",sZ=gv||!!(typeof window<"u"&&window.next);class mv{constructor(e){this.editor=null,this.subscriptions=new Set,this.isComponentMounted=!1,this.previousDeps=null,this.instanceId="",this.options=e,this.subscriptions=new Set,this.setEditor(this.getInitialEditor()),this.scheduleDestroy(),this.getEditor=this.getEditor.bind(this),this.getServerSnapshot=this.getServerSnapshot.bind(this),this.subscribe=this.subscribe.bind(this),this.refreshEditorInstance=this.refreshEditorInstance.bind(this),this.scheduleDestroy=this.scheduleDestroy.bind(this),this.onRender=this.onRender.bind(this),this.createEditor=this.createEditor.bind(this)}setEditor(e){this.editor=e,this.instanceId=Math.random().toString(36).slice(2,9),this.subscriptions.forEach(n=>n())}getInitialEditor(){if(this.options.current.immediatelyRender===void 0)return gv||sZ?(G2&&console.warn("Tiptap Error: SSR has been detected, please set `immediatelyRender` explicitly to `false` to avoid hydration mismatches."),null):this.createEditor();if(this.options.current.immediatelyRender&&gv&&G2)throw new Error("Tiptap Error: SSR has been detected, and `immediatelyRender` has been set to `true` this is an unsupported configuration that may result in errors, explicitly set `immediatelyRender` to `false` to avoid hydration mismatches.");return this.options.current.immediatelyRender?this.createEditor():null}createEditor(){const e={...this.options.current,onBeforeCreate:(...r)=>{var o,i;return(i=(o=this.options.current).onBeforeCreate)===null||i===void 0?void 0:i.call(o,...r)},onBlur:(...r)=>{var o,i;return(i=(o=this.options.current).onBlur)===null||i===void 0?void 0:i.call(o,...r)},onCreate:(...r)=>{var o,i;return(i=(o=this.options.current).onCreate)===null||i===void 0?void 0:i.call(o,...r)},onDestroy:(...r)=>{var o,i;return(i=(o=this.options.current).onDestroy)===null||i===void 0?void 0:i.call(o,...r)},onFocus:(...r)=>{var o,i;return(i=(o=this.options.current).onFocus)===null||i===void 0?void 0:i.call(o,...r)},onSelectionUpdate:(...r)=>{var o,i;return(i=(o=this.options.current).onSelectionUpdate)===null||i===void 0?void 0:i.call(o,...r)},onTransaction:(...r)=>{var o,i;return(i=(o=this.options.current).onTransaction)===null||i===void 0?void 0:i.call(o,...r)},onUpdate:(...r)=>{var o,i;return(i=(o=this.options.current).onUpdate)===null||i===void 0?void 0:i.call(o,...r)},onContentError:(...r)=>{var o,i;return(i=(o=this.options.current).onContentError)===null||i===void 0?void 0:i.call(o,...r)},onDrop:(...r)=>{var o,i;return(i=(o=this.options.current).onDrop)===null||i===void 0?void 0:i.call(o,...r)},onPaste:(...r)=>{var o,i;return(i=(o=this.options.current).onPaste)===null||i===void 0?void 0:i.call(o,...r)}};return new jK(e)}getEditor(){return this.editor}getServerSnapshot(){return null}subscribe(e){return this.subscriptions.add(e),()=>{this.subscriptions.delete(e)}}static compareOptions(e,n){return Object.keys(e).every(r=>["onCreate","onBeforeCreate","onDestroy","onUpdate","onTransaction","onFocus","onBlur","onSelectionUpdate","onContentError","onDrop","onPaste"].includes(r)?!0:r==="extensions"&&e.extensions&&n.extensions?e.extensions.length!==n.extensions.length?!1:e.extensions.every((o,i)=>{var s;return o===((s=n.extensions)===null||s===void 0?void 0:s[i])}):e[r]===n[r])}onRender(e){return()=>(this.isComponentMounted=!0,clearTimeout(this.scheduledDestructionTimeout),this.editor&&!this.editor.isDestroyed&&e.length===0?mv.compareOptions(this.options.current,this.editor.options)||this.editor.setOptions({...this.options.current,editable:this.editor.isEditable}):this.refreshEditorInstance(e),()=>{this.isComponentMounted=!1,this.scheduleDestroy()})}refreshEditorInstance(e){if(this.editor&&!this.editor.isDestroyed){if(this.previousDeps===null){this.previousDeps=e;return}if(this.previousDeps.length===e.length&&this.previousDeps.every((r,o)=>r===e[o]))return}this.editor&&!this.editor.isDestroyed&&this.editor.destroy(),this.setEditor(this.createEditor()),this.previousDeps=e}scheduleDestroy(){const e=this.instanceId,n=this.editor;this.scheduledDestructionTimeout=setTimeout(()=>{if(this.isComponentMounted&&this.instanceId===e){n&&n.setOptions(this.options.current);return}n&&!n.isDestroyed&&(n.destroy(),this.instanceId===e&&this.setEditor(null))},1)}}function J2(t={},e=[]){const n=J.useRef(t);n.current=t;const[r]=J.useState(()=>new mv(n)),o=Pf.useSyncExternalStore(r.subscribe,r.getEditor,r.getServerSnapshot);return J.useDebugValue(o),J.useEffect(r.onRender(e)),iZ({editor:o,selector:({transactionNumber:i})=>t.shouldRerenderOnTransaction===!1?null:t.immediatelyRender&&i===0?0:i+1}),o}J.createContext({editor:null}).Consumer;const Z2=J.createContext({onDragStart:void 0}),X2=()=>J.useContext(Z2),aZ=t=>{const e=t.as||"div",{nodeViewContentRef:n}=X2();return J.createElement(e,{...t,ref:n,"data-node-view-content":"",style:{whiteSpace:"pre-wrap",...t.style}})},yv=J.forwardRef((t,e)=>{const{onDragStart:n}=X2(),r=t.as||"div";return J.createElement(r,{...t,ref:e,"data-node-view-wrapper":"",onDragStart:n,style:{whiteSpace:"normal",...t.style}})});function lZ(t){return!!(typeof t=="function"&&t.prototype&&t.prototype.isReactComponent)}function cZ(t){var e;return typeof t=="object"&&((e=t.$$typeof)===null||e===void 0?void 0:e.toString())==="Symbol(react.forward_ref)"}class Q2{constructor(e,{editor:n,props:r={},as:o="div",className:i=""}){this.ref=null,this.id=Math.floor(Math.random()*4294967295).toString(),this.component=e,this.editor=n,this.props=r,this.element=document.createElement(o),this.element.classList.add("react-renderer"),i&&this.element.classList.add(...i.split(" ")),this.editor.isInitialized?ls.flushSync(()=>{this.render()}):this.render()}render(){var e;const n=this.component,r=this.props,o=this.editor;(lZ(n)||cZ(n))&&(r.ref=i=>{this.ref=i}),this.reactElement=J.createElement(n,{...r}),(e=o==null?void 0:o.contentComponent)===null||e===void 0||e.setRenderer(this.id,this)}updateProps(e={}){this.props={...this.props,...e},this.render()}destroy(){var e;const n=this.editor;(e=n==null?void 0:n.contentComponent)===null||e===void 0||e.removeRenderer(this.id)}updateAttributes(e){Object.keys(e).forEach(n=>{this.element.setAttribute(n,e[n])})}}class uZ extends WK{mount(){const e={editor:this.editor,node:this.node,decorations:this.decorations,innerDecorations:this.innerDecorations,view:this.view,selected:!1,extension:this.extension,HTMLAttributes:this.HTMLAttributes,getPos:()=>this.getPos(),updateAttributes:(u={})=>this.updateAttributes(u),deleteNode:()=>this.deleteNode()};if(!this.component.displayName){const u=f=>f.charAt(0).toUpperCase()+f.substring(1);this.component.displayName=u(this.extension.name)}const o={onDragStart:this.onDragStart.bind(this),nodeViewContentRef:u=>{u&&this.contentDOMElement&&u.firstChild!==this.contentDOMElement&&u.appendChild(this.contentDOMElement)}},i=this.component,s=J.memo(u=>J.createElement(Z2.Provider,{value:o},J.createElement(i,u)));s.displayName="ReactNodeView",this.node.isLeaf?this.contentDOMElement=null:this.options.contentDOMElementTag?this.contentDOMElement=document.createElement(this.options.contentDOMElementTag):this.contentDOMElement=document.createElement(this.node.isInline?"span":"div"),this.contentDOMElement&&(this.contentDOMElement.dataset.nodeViewContentReact="",this.contentDOMElement.style.whiteSpace="inherit");let a=this.node.isInline?"span":"div";this.options.as&&(a=this.options.as);const{className:l=""}=this.options;this.handleSelectionUpdate=this.handleSelectionUpdate.bind(this),this.renderer=new Q2(s,{editor:this.editor,props:e,as:a,className:`node-${this.node.type.name} ${l}`.trim()}),this.editor.on("selectionUpdate",this.handleSelectionUpdate),this.updateElementAttributes()}get dom(){var e;if(this.renderer.element.firstElementChild&&!(!((e=this.renderer.element.firstElementChild)===null||e===void 0)&&e.hasAttribute("data-node-view-wrapper")))throw Error("Please use the NodeViewWrapper component for your node view.");return this.renderer.element}get contentDOM(){return this.node.isLeaf?null:this.contentDOMElement}handleSelectionUpdate(){const{from:e,to:n}=this.editor.state.selection,r=this.getPos();if(typeof r=="number")if(e<=r&&n>=r+this.node.nodeSize){if(this.renderer.props.selected)return;this.selectNode()}else{if(!this.renderer.props.selected)return;this.deselectNode()}}update(e,n,r){const o=i=>{this.renderer.updateProps(i),typeof this.options.attrs=="function"&&this.updateElementAttributes()};if(e.type!==this.node.type)return!1;if(typeof this.options.update=="function"){const i=this.node,s=this.decorations,a=this.innerDecorations;return this.node=e,this.decorations=n,this.innerDecorations=r,this.options.update({oldNode:i,oldDecorations:s,newNode:e,newDecorations:n,oldInnerDecorations:a,innerDecorations:r,updateProps:()=>o({node:e,decorations:n,innerDecorations:r})})}return e===this.node&&this.decorations===n&&this.innerDecorations===r||(this.node=e,this.decorations=n,this.innerDecorations=r,o({node:e,decorations:n,innerDecorations:r})),!0}selectNode(){this.renderer.updateProps({selected:!0}),this.renderer.element.classList.add("ProseMirror-selectednode")}deselectNode(){this.renderer.updateProps({selected:!1}),this.renderer.element.classList.remove("ProseMirror-selectednode")}destroy(){this.renderer.destroy(),this.editor.off("selectionUpdate",this.handleSelectionUpdate),this.contentDOMElement=null}updateElementAttributes(){if(this.options.attrs){let e={};if(typeof this.options.attrs=="function"){const n=this.editor.extensionManager.attributes,r=uf(this.node,n);e=this.options.attrs({node:this.node,HTMLAttributes:r})}else e=this.options.attrs;this.renderer.updateAttributes(e)}}}function bv(t,e){return n=>n.editor.contentComponent?new uZ(t,n,e):{}}const vv=Rs("RichTextContent",["root","readonly","editable"]),dZ=Ut({name:{RichTextContent:xv}})(t=>({root:{"& .ProseMirror":{...t2(t)}},readonly:{},editable:{}}));function xv({className:t,classes:e={}}){const{classes:n,cx:r}=dZ(void 0,{props:{classes:e}}),o=bt(),i=J.useMemo(()=>r(vv.root,t,n.root,o!=null&&o.isEditable?[vv.editable,n.editable]:[vv.readonly,n.readonly]),[t,n,r,o==null?void 0:o.isEditable]);return v.jsx(F.Box,{className:i,component:ZJ,editor:o})}function eI({editor:t,children:e}){return v.jsx(r2.Provider,{value:t,children:e})}const Ya=Rs("FieldContainer",["root","outlined","standard","focused","disabled","notchedOutline"]),fZ=Ut({name:{FieldContainer:tI},uniqId:"Os7ZPW"})((t,e,n)=>({root:{},outlined:{borderRadius:t.shape.borderRadius,padding:1,position:"relative",[`&:hover .${n.notchedOutline}`]:{borderColor:t.palette.text.primary},[`&.${n.focused} .${n.notchedOutline}`]:{borderColor:t.palette.primary.main,borderWidth:2},[`&.${n.disabled} .${n.notchedOutline}`]:{borderColor:t.palette.action.disabled}},standard:{},focused:{},disabled:{},notchedOutline:{position:"absolute",inset:0,borderRadius:"inherit",borderColor:t.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)",borderStyle:"solid",borderWidth:1,pointerEvents:"none",overflow:"hidden",zIndex:Of.NOTCHED_OUTLINE}}));function tI({variant:t="outlined",children:e,focused:n,disabled:r,classes:o={},className:i}){const{classes:s,cx:a}=fZ(void 0,{props:{classes:o}});return v.jsxs("div",{className:a(Ya.root,s.root,t==="outlined"?[Ya.outlined,s.outlined]:[Ya.standard,s.standard],n&&[Ya.focused,s.focused],r&&[Ya.disabled,s.disabled],i),children:[e,t==="outlined"&&v.jsx("div",{className:a(Ya.notchedOutline,s.notchedOutline),"aria-hidden":!0})]})}var pZ=DC();const nI=Zn(pZ);function rI({editor:t,wait:e=250}){const[n,r]=J.useState(!!(t!=null&&t.isFocused)),o=J.useMemo(()=>nI(i=>{r(i)},e),[e]);return J.useEffect(()=>{const i=!!(t!=null&&t.isFocused);return o(i),i&&o.flush(),()=>{o.cancel()}},[t==null?void 0:t.isFocused,o]),n}class Sv extends J.Component{constructor(e){var n,r;super(e),this.updateDebounced=nI(this.forceUpdate,(n=e.wait)!==null&&n!==void 0?n:170,(r=e.options)!==null&&r!==void 0?r:{leading:!0,trailing:!0,maxWait:300})}shouldComponentUpdate(){return this.updateDebounced(),!1}componentWillUnmount(){this.updateDebounced.cancel()}render(){return this.props.children}}const Ga=Rs("RichTextField",["root","standard","outlined","menuBar","menuBarContent","content"]),hZ=Ut({name:{RichTextField:oI},uniqId:"E2Alw3"})((t,e,n)=>({root:{},standard:{[`& .${n.content}`]:{padding:t.spacing(1.5,0)},[`& .${n.menuBarContent}`]:{padding:t.spacing(1,0)}},outlined:{[`& .${n.content}`]:{padding:t.spacing(1.5)},[`& .${n.menuBarContent}`]:{padding:t.spacing(1,1.5)}},menuBar:{},menuBarContent:{},content:{}}));function oI({variant:t="outlined",controls:e,disableDebounceRenderControls:n=!1,disabled:r,className:o,classes:i={},footer:s,MenuBarProps:a,RichTextContentProps:l}){var u,f;const{classes:p,cx:g}=hZ(void 0,{props:{classes:i}}),m=bt(),y=rI({editor:m});return v.jsxs(tI,{variant:t,focused:!r&&y,disabled:r,className:g(Ga.root,p.root,t==="outlined"?[Ga.outlined,p.outlined]:[Ga.standard,p.standard],o),children:[e&&v.jsx(w2,{...a,classes:{...a==null?void 0:a.classes,root:g(Ga.menuBar,p.menuBar,(u=a==null?void 0:a.classes)===null||u===void 0?void 0:u.root),content:g(Ga.content,p.menuBarContent,(f=a==null?void 0:a.classes)===null||f===void 0?void 0:f.content)},children:n?e:v.jsx(Sv,{children:e})}),v.jsx(xv,{...l,className:g(Ga.content,p.content,l==null?void 0:l.className)}),s]})}const iI=J.forwardRef(function({className:e,renderControls:n,RichTextFieldProps:r={},children:o,editorDependencies:i=[],editable:s=!0,...a},l){const u=J2({editable:s,...a},i);return J.useImperativeHandle(l,()=>({editor:u}),[u]),J.useEffect(()=>{!u||u.isDestroyed||u.isEditable===s||queueMicrotask(()=>{u.setEditable(s)})},[s,u]),v.jsxs(eI,{editor:u,children:[v.jsx(oI,{disabled:!s,controls:n==null?void 0:n(u),className:e,...r}),o==null?void 0:o(u)]})});function gZ(t){const e=J2({...t,editable:!1}),n=J.useRef(t.content);return J.useEffect(()=>{!e||e.isDestroyed||t.content===void 0||t.content===n.current||queueMicrotask(()=>{t.content!==void 0&&e.commands.setContent(t.content)})},[t.content,e]),J.useEffect(()=>{n.current=t.content},[t.content]),v.jsx(eI,{editor:e,children:v.jsx(xv,{})})}function mZ(t){return t.content?v.jsx(gZ,{...t}):null}const yZ=F.createSvgIcon(v.jsxs(v.Fragment,{children:[v.jsx("path",{d:"M20 3H4c-1.103 0-2 .897-2 2v14c0 1.103.897 2 2 2h16c1.103 0 2-.897 2-2V5c0-1.103-.897-2-2-2zM4 19V7h16l.002 12H4z"}),v.jsx("path",{d:"M9.293 9.293 5.586 13l3.707 3.707 1.414-1.414L8.414 13l2.293-2.293zm5.414 0-1.414 1.414L15.586 13l-2.293 2.293 1.414 1.414L18.414 13z"})]}),"CodeBlock"),bZ=F.createSvgIcon(v.jsx("path",{d:"M12 3C12.5523 3 13 3.44772 13 4L12.9998 11.9998C13.8355 11.372 14.8743 11 16 11C18.7614 11 21 13.2386 21 16C21 18.7614 18.7614 21 16 21C14.9681 21 14.0092 20.6874 13.2129 20.1518L13 20C13 20.5523 12.5523 21 12 21H6C5.44772 21 5 20.5523 5 20V4C5 3.44772 5.44772 3 6 3H12ZM11 5H7V19H11V5ZM19 15H13V17H19V15Z"}),"DeleteColumn"),vZ=F.createSvgIcon(v.jsx("path",{d:"M20 5C20.5523 5 21 5.44772 21 6V12C21 12.5523 20.5523 13 20 13C20.628 13.8355 21 14.8743 21 16C21 18.7614 18.7614 21 16 21C13.2386 21 11 18.7614 11 16C11 14.8743 11.372 13.8355 11.9998 12.9998L4 13C3.44772 13 3 12.5523 3 12V6C3 5.44772 3.44772 5 4 5H20ZM13 15V17H19V15H13ZM19 7H5V11H19V7Z"}),"DeleteRow"),xZ=F.createSvgIcon(v.jsx("path",{d:"M 2 20 h 20 v 4 H 2 v -4 z"}),"FormatColorBar"),SZ=F.createSvgIcon(v.jsx("path",{d:"M 5.49 17 h 2.42 l 1.27 -3.58 h 5.65 L 16.09 17 h 2.42 L 13.25 3 h -2.5 L 5.49 17 z m 4.42 -5.61 l 2.03 -5.79 h 0.12 l 2.03 5.79 H 9.91 z"}),"FormatColorTextNoBar"),CZ=F.createSvgIcon(v.jsx("path",{d:"M 10.6 8 l 5.4 5.425 l -4 4 q -0.6 0.6 -1.413 0.6 t -1.412 -0.6 L 8.5 18 h -5 l 3.15 -3.125 q -0.6 -0.6 -0.625 -1.438 T 6.6 12 l 4 -4 Z M 12 6.575 L 16 2.6 q 0.6 -0.6 1.413 -0.6 t 1.412 0.6 l 2.6 2.575 q 0.6 0.6 0.6 1.413 T 21.425 8 l -4 4 L 12 6.575 Z"}),"FormatInkHighlighterNoBar"),wZ=F.createSvgIcon(v.jsx("path",{d:"M20 3C20.5523 3 21 3.44772 21 4V20C21 20.5523 20.5523 21 20 21H14C13.4477 21 13 20.5523 13 20V4C13 3.44772 13.4477 3 14 3H20ZM19 5H15V19H19V5ZM6 7C8.76142 7 11 9.23858 11 12C11 14.7614 8.76142 17 6 17C3.23858 17 1 14.7614 1 12C1 9.23858 3.23858 7 6 7ZM7 9H5V10.999L3 11V13L5 12.999V15H7V12.999L9 13V11L7 10.999V9Z"}),"InsertColumnLeft"),_Z=F.createSvgIcon(v.jsx("path",{d:"M10 3C10.5523 3 11 3.44772 11 4V20C11 20.5523 10.5523 21 10 21H4C3.44772 21 3 20.5523 3 20V4C3 3.44772 3.44772 3 4 3H10ZM9 5H5V19H9V5ZM18 7C20.7614 7 23 9.23858 23 12C23 14.7614 20.7614 17 18 17C15.2386 17 13 14.7614 13 12C13 9.23858 15.2386 7 18 7ZM19 9H17V10.999L15 11V13L17 12.999V15H19V12.999L21 13V11L19 10.999V9Z"}),"InsertColumnRight"),TZ=F.createSvgIcon(v.jsx("path",{d:"M12 13C14.7614 13 17 15.2386 17 18C17 20.7614 14.7614 23 12 23C9.23858 23 7 20.7614 7 18C7 15.2386 9.23858 13 12 13ZM13 15H11V16.999L9 17V19L11 18.999V21H13V18.999L15 19V17L13 16.999V15ZM20 3C20.5523 3 21 3.44772 21 4V10C21 10.5523 20.5523 11 20 11H4C3.44772 11 3 10.5523 3 10V4C3 3.44772 3.44772 3 4 3H20ZM5 5V9H19V5H5Z"}),"InsertRowBottom"),kZ=F.createSvgIcon(v.jsx("path",{d:"M20 13C20.5523 13 21 13.4477 21 14V20C21 20.5523 20.5523 21 20 21H4C3.44772 21 3 20.5523 3 20V14C3 13.4477 3.44772 13 4 13H20ZM19 15H5V19H19V15ZM12 1C14.7614 1 17 3.23858 17 6C17 8.76142 14.7614 11 12 11C9.23858 11 7 8.76142 7 6C7 3.23858 9.23858 1 12 1ZM13 3H11V4.999L9 5V7L11 6.999V9H13V6.999L15 7V5L13 4.999V3Z"}),"InsertRowTop"),EZ=F.createSvgIcon(v.jsx("path",{d:"M12 5V19H19V5H12ZM4 3H20C20.5523 3 21 3.44772 21 4V20C21 20.5523 20.5523 21 20 21H4C3.44772 21 3 20.5523 3 20V4C3 3.44772 3.44772 3 4 3Z"}),"LayoutColumnFill"),MZ=F.createSvgIcon(v.jsx("path",{d:"M19 12H5V19H19V12ZM4 3H20C20.5523 3 21 3.44772 21 4V20C21 20.5523 20.5523 21 20 21H4C3.44772 21 3 20.5523 3 20V4C3 3.44772 3.44772 3 4 3Z"}),"LayoutRowFill"),OZ=F.createSvgIcon(v.jsx("path",{d:"M20 3C20.5523 3 21 3.44772 21 4V20C21 20.5523 20.5523 21 20 21H4C3.44772 21 3 20.5523 3 20V4C3 3.44772 3.44772 3 4 3H20ZM11 5H5V10.999H7V9L10 12L7 15V13H5V19H11V17H13V19H19V13H17V15L14 12L17 9V10.999H19V5H13V7H11V5ZM13 13V15H11V13H13ZM13 9V11H11V9H13Z"}),"MergeCellsHorizontal"),AZ=F.createSvgIcon(v.jsx("path",{d:"M20 3C20.5523 3 21 3.44772 21 4V20C21 20.5523 20.5523 21 20 21H4C3.44772 21 3 20.5523 3 20V4C3 3.44772 3.44772 3 4 3H20ZM11 5H5V19H11V15H13V19H19V5H13V9H11V5ZM15 9L18 12L15 15V13H9V15L6 12L9 9V11H15V9Z"}),"SplitCellsHorizontal"),IZ=F.createSvgIcon(v.jsx("path",{d:"M4 21h15.893c1.103 0 2-.897 2-2V5c0-1.103-.897-2-2-2H4c-1.103 0-2 .897-2 2v14c0 1.103.897 2 2 2zm0-2v-5h4v5H4zM14 7v5h-4V7h4zM8 7v5H4V7h4zm2 12v-5h4v5h-4zm6 0v-5h3.894v5H16zm3.893-7H16V7h3.893v5z"}),"Table");let Cv,wv;function DZ(){return Cv===void 0&&(Cv=navigator.platform.includes("Mac")),Cv}function PZ(){return DZ()?"⌘":"Ctrl"}function NZ(){return wv===void 0&&(wv=window&&"ontouchstart"in window||navigator.maxTouchPoints>0||navigator.msMaxTouchPoints>0),wv}const LZ=Ut({name:{MenuButtonTooltip:co}})(t=>({titleContainer:{textAlign:"center"},label:{fontSize:t.typography.pxToRem(13)},shortcutKey:{fontSize:t.typography.pxToRem(12),border:`1px solid ${F.alpha(t.palette.text.secondary,.2)}`,backgroundColor:F.alpha(t.palette.background.paper,.3),height:"19px",lineHeight:"19px",padding:"0 4px",minWidth:17,borderRadius:t.shape.borderRadius,display:"inline-block","&:not(:first-of-type)":{marginLeft:1}}}));function co({label:t,shortcutKeys:e,placement:n="top",contentWrapperClassName:r,children:o,...i}){const{classes:s}=LZ();return v.jsx(F.Tooltip,{title:t||e&&e.length>0?v.jsxs("div",{className:s.titleContainer,children:[v.jsx("div",{className:s.label,children:t}),e&&e.length>0&&v.jsx(F.Typography,{variant:"body2",component:"div",children:e.map((a,l)=>v.jsx("span",{className:s.shortcutKey,children:a==="mod"?PZ():a},l))})]}):"",placement:n,arrow:!0,...i,children:v.jsx("span",{className:r,children:o})})}const jc="1.25rem",FZ=Ut({name:{MenuButton:gt}})({root:{[`&& .${F.toggleButtonClasses.root}`]:{border:"none",padding:5}},menuButtonIcon:{fontSize:jc}});function gt({tooltipLabel:t,tooltipShortcutKeys:e,IconComponent:n,buttonRef:r,children:o,...i}){const{classes:s}=FZ();return v.jsx("span",{className:s.root,children:v.jsx(co,{label:t,shortcutKeys:e,children:v.jsx(F.ToggleButton,{ref:r,size:"small",value:t,...i,children:o??(n&&v.jsx(n,{className:s.menuButtonIcon}))})})})}const $Z=Ut({name:{MenuControlsContainer:Nf}})(t=>({root:{display:"flex",rowGap:t.spacing(.3),columnGap:t.spacing(.3),alignItems:"center",flexWrap:"wrap"}}));function Nf({children:t,className:e,debounced:n,DebounceProps:r}){const{classes:o,cx:i}=$Z(),s=v.jsx("div",{className:i(o.root,e),children:t});return n?v.jsx(Sv,{...r,children:s}):s}function BZ({className:t,labels:e}){var n,r,o,i,s,a,l,u,f,p,g,m,y;const b=bt();return v.jsxs(Nf,{className:t,children:[v.jsx(gt,{tooltipLabel:(n=e==null?void 0:e.insertColumnBefore)!==null&&n!==void 0?n:"Insert column before",IconComponent:wZ,onClick:()=>b==null?void 0:b.chain().focus().addColumnBefore().run(),disabled:!(b!=null&&b.can().addColumnBefore())}),v.jsx(gt,{tooltipLabel:(r=e==null?void 0:e.insertColumnAfter)!==null&&r!==void 0?r:"Insert column after",IconComponent:_Z,onClick:()=>b==null?void 0:b.chain().focus().addColumnAfter().run(),disabled:!(b!=null&&b.can().addColumnAfter())}),v.jsx(gt,{tooltipLabel:(o=e==null?void 0:e.deleteColumn)!==null&&o!==void 0?o:"Delete column",IconComponent:bZ,onClick:()=>b==null?void 0:b.chain().focus().deleteColumn().run(),disabled:!(b!=null&&b.can().deleteColumn())}),v.jsx(Mn,{}),v.jsx(gt,{tooltipLabel:(i=e==null?void 0:e.insertRowAbove)!==null&&i!==void 0?i:"Insert row above",IconComponent:kZ,onClick:()=>b==null?void 0:b.chain().focus().addRowBefore().run(),disabled:!(b!=null&&b.can().addRowBefore())}),v.jsx(gt,{tooltipLabel:(s=e==null?void 0:e.insertRowBelow)!==null&&s!==void 0?s:"Insert row below",IconComponent:TZ,onClick:()=>b==null?void 0:b.chain().focus().addRowAfter().run(),disabled:!(b!=null&&b.can().addRowAfter())}),v.jsx(gt,{tooltipLabel:(a=e==null?void 0:e.deleteRow)!==null&&a!==void 0?a:"Delete row",IconComponent:vZ,onClick:()=>b==null?void 0:b.chain().focus().deleteRow().run(),disabled:!(b!=null&&b.can().deleteRow())}),v.jsx(Mn,{}),v.jsx(gt,{tooltipLabel:(l=e==null?void 0:e.mergeCells)!==null&&l!==void 0?l:"Merge cells",IconComponent:OZ,onClick:()=>b==null?void 0:b.chain().focus().mergeCells().run(),disabled:!(b!=null&&b.can().mergeCells())}),v.jsx(gt,{tooltipLabel:(u=e==null?void 0:e.splitCell)!==null&&u!==void 0?u:"Split cell",IconComponent:AZ,onClick:()=>b==null?void 0:b.chain().focus().splitCell().run(),disabled:!(b!=null&&b.can().splitCell())}),v.jsx(Mn,{}),v.jsx(gt,{tooltipLabel:(f=e==null?void 0:e.toggleHeaderRow)!==null&&f!==void 0?f:"Toggle header row",IconComponent:MZ,onClick:()=>b==null?void 0:b.chain().focus().toggleHeaderRow().run(),disabled:!(b!=null&&b.can().toggleHeaderRow())}),v.jsx(gt,{tooltipLabel:(p=e==null?void 0:e.toggleHeaderColumn)!==null&&p!==void 0?p:"Toggle header column",IconComponent:EZ,onClick:()=>b==null?void 0:b.chain().focus().toggleHeaderColumn().run(),disabled:!(b!=null&&b.can().toggleHeaderColumn())}),v.jsx(gt,{tooltipLabel:(g=e==null?void 0:e.toggleHeaderCell)!==null&&g!==void 0?g:"Toggle header cell",IconComponent:yR,onClick:()=>b==null?void 0:b.chain().focus().toggleHeaderCell().run(),disabled:!(b!=null&&b.can().toggleHeaderCell()),selected:(m=b==null?void 0:b.isActive("tableHeader"))!==null&&m!==void 0?m:!1}),v.jsx(Mn,{}),v.jsx(gt,{tooltipLabel:(y=e==null?void 0:e.deleteTable)!==null&&y!==void 0?y:"Delete table",IconComponent:kR,onClick:()=>b==null?void 0:b.chain().focus().deleteTable().run(),disabled:!(b!=null&&b.can().deleteTable())})]})}const RZ=Ut({name:{TableBubbleMenu:sI}})(t=>({controls:{maxWidth:"90vw",padding:t.spacing(.5,1)}}));function sI({disableDebounce:t=!1,DebounceProps:e,labels:n,...r}){const o=bt(),{classes:i}=RZ(),s=rI({editor:o}),a=J.useMemo(()=>o?{getBoundingClientRect:()=>{const u=o.isActive("table")?ty(o.state.selection.$anchor,m=>m.type.name==="table"):null;if(u){const m=o.view.nodeDOM(u.pos),y=m==null?void 0:m.querySelector("table");if(y)return y.getBoundingClientRect()}const{ranges:f}=o.state.selection,p=Math.min(...f.map(m=>m.$from.pos)),g=Math.max(...f.map(m=>m.$to.pos));return QE(o.view,p,g)}}:null,[o]);if(!(o!=null&&o.isEditable))return null;const l=v.jsx(BZ,{className:i.controls,labels:n});return v.jsx(Af,{editor:o,open:s&&o.isActive("table"),anchorEl:a,placement:"top-start",fallbackPlacements:["bottom-start","top","bottom","top-end","bottom-end"],flipPadding:{top:35,left:8,right:8,bottom:-1/0},...r,children:t?l:v.jsx(Sv,{...e,children:l})})}function Ja(){return(Ja=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t}).apply(this,arguments)}function _v(t,e){if(t==null)return{};var n,r,o={},i=Object.keys(t);for(r=0;r<i.length;r++)e.indexOf(n=i[r])>=0||(o[n]=t[n]);return o}function Tv(t){var e=J.useRef(t),n=J.useRef(function(r){e.current&&e.current(r)});return e.current=t,n.current}var Za=function(t,e,n){return e===void 0&&(e=0),n===void 0&&(n=1),t>n?n:t<e?e:t},Wc=function(t){return"touches"in t},kv=function(t){return t&&t.ownerDocument.defaultView||self},aI=function(t,e,n){var r=t.getBoundingClientRect(),o=Wc(e)?function(i,s){for(var a=0;a<i.length;a++)if(i[a].identifier===s)return i[a];return i[0]}(e.touches,n):e;return{left:Za((o.pageX-(r.left+kv(t).pageXOffset))/r.width),top:Za((o.pageY-(r.top+kv(t).pageYOffset))/r.height)}},lI=function(t){!Wc(t)&&t.preventDefault()},Ev=J.memo(function(t){var e=t.onMove,n=t.onKey,r=_v(t,["onMove","onKey"]),o=J.useRef(null),i=Tv(e),s=Tv(n),a=J.useRef(null),l=J.useRef(!1),u=J.useMemo(function(){var m=function(S){lI(S),(Wc(S)?S.touches.length>0:S.buttons>0)&&o.current?i(aI(o.current,S,a.current)):b(!1)},y=function(){return b(!1)};function b(S){var C=l.current,T=kv(o.current),_=S?T.addEventListener:T.removeEventListener;_(C?"touchmove":"mousemove",m),_(C?"touchend":"mouseup",y)}return[function(S){var C=S.nativeEvent,T=o.current;if(T&&(lI(C),!function(w,E){return E&&!Wc(w)}(C,l.current)&&T)){if(Wc(C)){l.current=!0;var _=C.changedTouches||[];_.length&&(a.current=_[0].identifier)}T.focus(),i(aI(T,C,a.current)),b(!0)}},function(S){var C=S.which||S.keyCode;C<37||C>40||(S.preventDefault(),s({left:C===39?.05:C===37?-.05:0,top:C===40?.05:C===38?-.05:0}))},b]},[s,i]),f=u[0],p=u[1],g=u[2];return J.useEffect(function(){return g},[g]),J.createElement("div",Ja({},r,{onTouchStart:f,onMouseDown:f,className:"react-colorful__interactive",ref:o,onKeyDown:p,tabIndex:0,role:"slider"}))}),qc=function(t){return t.filter(Boolean).join(" ")},Mv=function(t){var e=t.color,n=t.left,r=t.top,o=r===void 0?.5:r,i=qc(["react-colorful__pointer",t.className]);return J.createElement("div",{className:i,style:{top:100*o+"%",left:100*n+"%"}},J.createElement("div",{className:"react-colorful__pointer-fill",style:{backgroundColor:e}}))},On=function(t,e,n){return e===void 0&&(e=0),n===void 0&&(n=Math.pow(10,e)),Math.round(n*t)/n},cI=function(t){return HZ(Ov(t))},Ov=function(t){return t[0]==="#"&&(t=t.substring(1)),t.length<6?{r:parseInt(t[0]+t[0],16),g:parseInt(t[1]+t[1],16),b:parseInt(t[2]+t[2],16),a:t.length===4?On(parseInt(t[3]+t[3],16)/255,2):1}:{r:parseInt(t.substring(0,2),16),g:parseInt(t.substring(2,4),16),b:parseInt(t.substring(4,6),16),a:t.length===8?On(parseInt(t.substring(6,8),16)/255,2):1}},uI=function(t){return VZ(zZ(t))},dI=function(t){var e=t.s,n=t.v,r=t.a,o=(200-e)*n/100;return{h:On(t.h),s:On(o>0&&o<200?e*n/100/(o<=100?o:200-o)*100:0),l:On(o/2),a:On(r,2)}},Av=function(t){var e=dI(t);return"hsl("+e.h+", "+e.s+"%, "+e.l+"%)"},Iv=function(t){var e=dI(t);return"hsla("+e.h+", "+e.s+"%, "+e.l+"%, "+e.a+")"},zZ=function(t){var e=t.h,n=t.s,r=t.v,o=t.a;e=e/360*6,n/=100,r/=100;var i=Math.floor(e),s=r*(1-n),a=r*(1-(e-i)*n),l=r*(1-(1-e+i)*n),u=i%6;return{r:On(255*[r,a,s,s,l,r][u]),g:On(255*[l,r,r,a,s,s][u]),b:On(255*[s,s,l,r,r,a][u]),a:On(o,2)}},Lf=function(t){var e=t.toString(16);return e.length<2?"0"+e:e},VZ=function(t){var e=t.r,n=t.g,r=t.b,o=t.a,i=o<1?Lf(On(255*o)):"";return"#"+Lf(e)+Lf(n)+Lf(r)+i},HZ=function(t){var e=t.r,n=t.g,r=t.b,o=t.a,i=Math.max(e,n,r),s=i-Math.min(e,n,r),a=s?i===e?(n-r)/s:i===n?2+(r-e)/s:4+(e-n)/s:0;return{h:On(60*(a<0?a+6:a)),s:On(i?s/i*100:0),v:On(i/255*100),a:o}},fI=J.memo(function(t){var e=t.hue,n=t.onChange,r=qc(["react-colorful__hue",t.className]);return J.createElement("div",{className:r},J.createElement(Ev,{onMove:function(o){n({h:360*o.left})},onKey:function(o){n({h:Za(e+360*o.left,0,360)})},"aria-label":"Hue","aria-valuenow":On(e),"aria-valuemax":"360","aria-valuemin":"0"},J.createElement(Mv,{className:"react-colorful__hue-pointer",left:e/360,color:Av({h:e,s:100,v:100,a:1})})))}),pI=J.memo(function(t){var e=t.hsva,n=t.onChange,r={backgroundColor:Av({h:e.h,s:100,v:100,a:1})};return J.createElement("div",{className:"react-colorful__saturation",style:r},J.createElement(Ev,{onMove:function(o){n({s:100*o.left,v:100-100*o.top})},onKey:function(o){n({s:Za(e.s+100*o.left,0,100),v:Za(e.v-100*o.top,0,100)})},"aria-label":"Color","aria-valuetext":"Saturation "+On(e.s)+"%, Brightness "+On(e.v)+"%"},J.createElement(Mv,{className:"react-colorful__saturation-pointer",top:1-e.v/100,left:e.s/100,color:Av(e)})))}),hI=function(t,e){if(t===e)return!0;for(var n in t)if(t[n]!==e[n])return!1;return!0},gI=function(t,e){return t.toLowerCase()===e.toLowerCase()||hI(Ov(t),Ov(e))};function mI(t,e,n){var r=Tv(n),o=J.useState(function(){return t.toHsva(e)}),i=o[0],s=o[1],a=J.useRef({color:e,hsva:i});J.useEffect(function(){if(!t.equal(e,a.current.color)){var u=t.toHsva(e);a.current={hsva:u,color:e},s(u)}},[e,t]),J.useEffect(function(){var u;hI(i,a.current.hsva)||t.equal(u=t.fromHsva(i),a.current.color)||(a.current={hsva:i,color:u},r(u))},[i,t,r]);var l=J.useCallback(function(u){s(function(f){return Object.assign({},f,u)})},[]);return[i,l]}var jZ=typeof window<"u"?J.useLayoutEffect:J.useEffect,WZ=function(){return typeof __webpack_nonce__<"u"?__webpack_nonce__:void 0},yI=new Map,bI=function(t){jZ(function(){var e=t.current?t.current.ownerDocument:document;if(e!==void 0&&!yI.has(e)){var n=e.createElement("style");n.innerHTML=`.react-colorful{position:relative;display:flex;flex-direction:column;width:200px;height:200px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:default}.react-colorful__saturation{position:relative;flex-grow:1;border-color:transparent;border-bottom:12px solid #000;border-radius:8px 8px 0 0;background-image:linear-gradient(0deg,#000,transparent),linear-gradient(90deg,#fff,hsla(0,0%,100%,0))}.react-colorful__alpha-gradient,.react-colorful__pointer-fill{content:"";position:absolute;left:0;top:0;right:0;bottom:0;pointer-events:none;border-radius:inherit}.react-colorful__alpha-gradient,.react-colorful__saturation{box-shadow:inset 0 0 0 1px rgba(0,0,0,.05)}.react-colorful__alpha,.react-colorful__hue{position:relative;height:24px}.react-colorful__hue{background:linear-gradient(90deg,red 0,#ff0 17%,#0f0 33%,#0ff 50%,#00f 67%,#f0f 83%,red)}.react-colorful__last-control{border-radius:0 0 8px 8px}.react-colorful__interactive{position:absolute;left:0;top:0;right:0;bottom:0;border-radius:inherit;outline:none;touch-action:none}.react-colorful__pointer{position:absolute;z-index:1;box-sizing:border-box;width:28px;height:28px;transform:translate(-50%,-50%);background-color:#fff;border:2px solid #fff;border-radius:50%;box-shadow:0 2px 4px rgba(0,0,0,.2)}.react-colorful__interactive:focus .react-colorful__pointer{transform:translate(-50%,-50%) scale(1.1)}.react-colorful__alpha,.react-colorful__alpha-pointer{background-color:#fff;background-image:url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill-opacity=".05"><path d="M8 0h8v8H8zM0 8h8v8H0z"/></svg>')}.react-colorful__saturation-pointer{z-index:3}.react-colorful__hue-pointer{z-index:2}`,yI.set(e,n);var r=WZ();r&&n.setAttribute("nonce",r),e.head.appendChild(n)}},[])},qZ=function(t){var e=t.className,n=t.colorModel,r=t.color,o=r===void 0?n.defaultColor:r,i=t.onChange,s=_v(t,["className","colorModel","color","onChange"]),a=J.useRef(null);bI(a);var l=mI(n,o,i),u=l[0],f=l[1],p=qc(["react-colorful",e]);return J.createElement("div",Ja({},s,{ref:a,className:p}),J.createElement(pI,{hsva:u,onChange:f}),J.createElement(fI,{hue:u.h,onChange:f,className:"react-colorful__last-control"}))},UZ={defaultColor:"000",toHsva:cI,fromHsva:function(t){return uI({h:t.h,s:t.s,v:t.v,a:1})},equal:gI},KZ=function(t){return J.createElement(qZ,Ja({},t,{colorModel:UZ}))},YZ=function(t){var e=t.className,n=t.hsva,r=t.onChange,o={backgroundImage:"linear-gradient(90deg, "+Iv(Object.assign({},n,{a:0}))+", "+Iv(Object.assign({},n,{a:1}))+")"},i=qc(["react-colorful__alpha",e]),s=On(100*n.a);return J.createElement("div",{className:i},J.createElement("div",{className:"react-colorful__alpha-gradient",style:o}),J.createElement(Ev,{onMove:function(a){r({a:a.left})},onKey:function(a){r({a:Za(n.a+a.left)})},"aria-label":"Alpha","aria-valuetext":s+"%","aria-valuenow":s,"aria-valuemin":"0","aria-valuemax":"100"},J.createElement(Mv,{className:"react-colorful__alpha-pointer",left:n.a,color:Iv(n)})))},GZ=function(t){var e=t.className,n=t.colorModel,r=t.color,o=r===void 0?n.defaultColor:r,i=t.onChange,s=_v(t,["className","colorModel","color","onChange"]),a=J.useRef(null);bI(a);var l=mI(n,o,i),u=l[0],f=l[1],p=qc(["react-colorful",e]);return J.createElement("div",Ja({},s,{ref:a,className:p}),J.createElement(pI,{hsva:u,onChange:f}),J.createElement(fI,{hue:u.h,onChange:f}),J.createElement(YZ,{hsva:u,onChange:f,className:"react-colorful__last-control"}))},JZ={defaultColor:"0001",toHsva:cI,fromHsva:uI,equal:gI},ZZ=function(t){return J.createElement(GZ,Ja({},t,{colorModel:JZ}))};function XZ(t){try{return F.rgbToHex(t)}catch{return null}}const Dv=J.forwardRef(({value:t,label:e,padding:n,active:r,...o},i)=>{const{classes:s,cx:a,theme:l}=QZ();return v.jsx("button",{ref:i,type:"button",style:{backgroundColor:t,padding:n},"aria-label":e??t,value:t,...o,className:a(s.root,!t&&s.colorNotSet,o.className),children:r&&v.jsx(oR,{fontSize:"small",className:s.activeIcon,style:{color:t?l.palette.getContrastText(t):void 0}})})}),QZ=Ut({name:{ColorSwatchButton:Dv}})(t=>({root:{height:t.spacing(2.5),width:t.spacing(2.5),minWidth:t.spacing(2.5),borderRadius:t.shape.borderRadius,borderColor:t.palette.mode==="dark"?t.palette.grey[700]:t.palette.grey[400],borderStyle:"solid",borderWidth:1,cursor:"pointer",padding:0,backgroundClip:"content-box"},activeIcon:{height:"100%",width:"80%",verticalAlign:"middle"},colorNotSet:{background:`repeating-conic-gradient(
|
|
391
391
|
${t.palette.grey[400]} 0% 25%, ${t.palette.common.white} 0% 50%)
|
|
392
392
|
50% / 12px 12px`,backgroundClip:"content-box"}}));Dv.displayName="ColorSwatchButton";const Ff=Rs("ColorPicker",["gradientPicker","colorTextInput","swatchContainer"]),eX=Ut({name:{ColorPicker:vI}})(t=>({gradientPicker:{"&&":{width:"100%"}},colorTextInput:{marginTop:t.spacing(1)},swatchContainer:{display:"flex",flexWrap:"wrap",gap:5,marginTop:t.spacing(1)}}));function vI({value:t,onChange:e,swatchColors:n,colorToHex:r=XZ,disableAlpha:o=!1,labels:i={},classes:s={}}){const{classes:a,cx:l}=eX(void 0,{props:{classes:s}}),{textFieldPlaceholder:u='Ex: "#7cb5ec"'}=i,f=J.useRef(null);J.useEffect(()=>{f.current&&f.current!==document.activeElement&&(f.current.value=t)},[t]);const p=(n??[]).map(m=>typeof m=="string"?{value:m}:m),g=r(t);return v.jsxs(v.Fragment,{children:[o?v.jsx(KZ,{color:g??"#000000",className:l(Ff.gradientPicker,a.gradientPicker),onChange:m=>{e(m,"gradient")}}):v.jsx(ZZ,{color:g??"#000000",className:l(Ff.gradientPicker,a.gradientPicker),onChange:m=>{e(m,"gradient")}}),v.jsx(F.TextField,{placeholder:u,variant:"outlined",size:"small",defaultValue:t||"",inputRef:f,spellCheck:!1,className:l(Ff.colorTextInput,a.colorTextInput),onChange:m=>{const y=m.target.value,b=r(y);b&&e(b,"text")},fullWidth:!0}),p.length>0&&v.jsx("div",{className:l(Ff.swatchContainer,a.swatchContainer),children:p.map(m=>v.jsx(Dv,{value:m.value,label:m.label,onClick:()=>{var y;e((y=m.value)!==null&&y!==void 0?y:"","swatch")},active:m.value==t||!m.value&&!t||!!m.value&&!!g&&r(m.value)===g},m.value))})]})}function tX({value:t,onCancel:e,onSave:n,swatchColors:r,labels:o={},ColorPickerProps:i}){const{removeColorButton:s="None",removeColorButtonTooltipTitle:a="",cancelButton:l="Cancel",saveButton:u="OK"}=o,[f,p]=J.useState(t);return J.useEffect(()=>{p(t)},[t]),v.jsxs(v.Fragment,{children:[v.jsx(vI,{swatchColors:r,value:f,onChange:g=>{p(g)},labels:o,...i}),v.jsxs(F.Stack,{direction:"row",justifyContent:"space-between",sx:{mt:1},children:[v.jsx(F.Tooltip,{title:a,arrow:!0,children:v.jsx(F.Button,{onClick:()=>{n("")},size:"small",children:s})}),v.jsx(F.Button,{onClick:e,size:"small",children:l}),v.jsx(F.Button,{onClick:()=>{n(f)},size:"small",children:u})]})]})}const nX=Ut({name:{ColorPickerPopper:xI}})(t=>({root:{zIndex:t.zIndex.tooltip,width:235}}));function xI({value:t,onSave:e,onCancel:n,swatchColors:r,ColorPickerProps:o,labels:i,...s}){const{classes:a,cx:l}=nX();return v.jsx(F.Popper,{transition:!0,placement:"bottom-start",...s,className:l(a.root,s.className),children:({TransitionProps:u})=>v.jsx(F.Fade,{...u,timeout:100,children:v.jsx("div",{children:v.jsx(F.ClickAwayListener,{mouseEvent:"onMouseDown",touchEvent:"onTouchStart",onClickAway:n,children:v.jsx(F.Paper,{elevation:5,sx:{p:2.5,pb:1},children:v.jsx(tX,{value:t||"",onSave:e,onCancel:n,swatchColors:r,ColorPickerProps:o,labels:i})})})})})})}function rX({...t}){const e=bt();return v.jsx(gt,{tooltipLabel:"Insert image",IconComponent:nR,disabled:!(e!=null&&e.isEditable)||!e.can().setImage({src:"http://example.com"}),...t})}function oX(t){const e=bt();return v.jsx(gt,{tooltipLabel:"Insert table",IconComponent:IZ,disabled:!(e!=null&&e.isEditable)||!e.can().insertTable(),onClick:()=>e==null?void 0:e.chain().focus().insertTable({rows:3,cols:3,withHeaderRow:!0}).run(),...t})}function iX(t){var e;const n=bt();return v.jsx(gt,{tooltipLabel:"Blockquote",tooltipShortcutKeys:["mod","Shift","B"],IconComponent:wR,selected:(e=n==null?void 0:n.isActive("blockquote"))!==null&&e!==void 0?e:!1,disabled:!(n!=null&&n.isEditable)||!n.can().toggleBlockquote(),onClick:()=>n==null?void 0:n.chain().focus().toggleBlockquote().run(),...t})}function sX(t){var e;const n=bt();return v.jsx(gt,{tooltipLabel:"Bold",tooltipShortcutKeys:["mod","B"],IconComponent:gR,selected:(e=n==null?void 0:n.isActive("bold"))!==null&&e!==void 0?e:!1,disabled:!(n!=null&&n.isEditable)||!n.can().toggleBold(),onClick:()=>n==null?void 0:n.chain().focus().toggleBold().run(),...t})}function aX(t){var e;const n=bt();return v.jsx(gt,{tooltipLabel:"Bulleted list",tooltipShortcutKeys:["mod","Shift","8"],IconComponent:SR,selected:(e=n==null?void 0:n.isActive("bulletList"))!==null&&e!==void 0?e:!1,disabled:!(n!=null&&n.isEditable)||!n.can().toggleBulletList(),onClick:()=>n==null?void 0:n.chain().focus().toggleBulletList().run(),...t})}function lX(t){var e;const n=bt();return v.jsx(gt,{tooltipLabel:"Code",tooltipShortcutKeys:["mod","E"],IconComponent:lR,selected:(e=n==null?void 0:n.isActive("code"))!==null&&e!==void 0?e:!1,disabled:!(n!=null&&n.isEditable)||!n.can().toggleCode(),onClick:()=>n==null?void 0:n.chain().focus().toggleCode().run(),...t})}function cX(t){var e;const n=bt();return v.jsx(gt,{tooltipLabel:"Code block",tooltipShortcutKeys:["mod","Alt","C"],IconComponent:yZ,selected:(e=n==null?void 0:n.isActive("codeBlock"))!==null&&e!==void 0?e:!1,disabled:!(n!=null&&n.isEditable)||!n.can().toggleCodeBlock(),onClick:()=>n==null?void 0:n.chain().focus().toggleCodeBlock().run(),...t})}const uX=Ut({name:{MenuButtonColorPicker:Pv}})(t=>({menuButtonIcon:{fontSize:jc},colorIndicatorIcon:{position:"absolute"},colorIndicatorIconDisabled:{color:t.palette.action.disabled}}));function Pv({value:t,onChange:e,swatchColors:n,labels:r,hideColorIndicator:o=!1,popperId:i,PopperProps:s,ColorPickerProps:a,...l}){const{classes:u,cx:f}=uX(),[p,g]=J.useState(null),m=()=>{g(null)},{IconComponent:y,children:b,...S}=l;return v.jsxs(v.Fragment,{children:[v.jsx(gt,{onClick:C=>{p?m():g(C.currentTarget)},"aria-describedby":i,...S,children:b??v.jsxs(v.Fragment,{children:[y&&v.jsx(y,{className:u.menuButtonIcon}),!o&&t&&v.jsx(xZ,{className:f(u.menuButtonIcon,u.colorIndicatorIcon,l.disabled&&u.colorIndicatorIconDisabled),style:l.disabled?void 0:{color:t}})]})}),v.jsx(xI,{id:i,open:!!p,anchorEl:p,value:t??"",onSave:C=>{e(C),m()},onCancel:m,swatchColors:n,ColorPickerProps:a,labels:r,...s})]})}function dX(t){const e=bt(),n=J.useRef(null);return v.jsx(gt,{buttonRef:n,tooltipLabel:"Link",tooltipShortcutKeys:["mod","Shift","U"],IconComponent:Ju,selected:e==null?void 0:e.isActive("link"),disabled:!(e!=null&&e.isEditable),onClick:()=>e==null?void 0:e.commands.openLinkBubbleMenu({anchorEl:n.current,placement:"bottom"}),...t})}function fX({defaultMarkColor:t="#ffff00",...e}){const n=bt(),r=n!=null&&n.isActive("highlight")?n.getAttributes("highlight").color||t:"";return v.jsx(Pv,{IconComponent:CZ,tooltipLabel:"Highlight color",tooltipShortcutKeys:["mod","Shift","H"],value:r,onChange:o=>{o?n==null||n.chain().focus().setHighlight({color:o}).run():n==null||n.chain().focus().unsetHighlight().run()},disabled:!(n!=null&&n.isEditable)||!n.can().toggleHighlight(),...e,labels:{removeColorButton:"None",removeColorButtonTooltipTitle:"Remove highlighting from this text",...e.labels}})}function pX(t){const e=bt();return v.jsx(gt,{tooltipLabel:"Insert horizontal line",IconComponent:ER,disabled:!(e!=null&&e.isEditable)||!e.can().setHorizontalRule(),onClick:()=>e==null?void 0:e.chain().focus().setHorizontalRule().run(),...t})}function hX(t,e){const n=lo(e,t.schema),{from:r,to:o,empty:i}=t.selection,s=[];return i?(t.storedMarks&&s.push(...t.storedMarks),s.push(...t.selection.$head.marks())):t.doc.nodesBetween(r,o,a=>{s.push(...a.marks)}),s.filter(a=>a.type.name===n.name).map(a=>({...a.attrs}))}function gX(t,e){const n=xn(e,t.schema),{from:r,to:o}=t.selection,i=[];return t.doc.nodesBetween(r,o,s=>{i.push(s)}),i.reverse().filter(s=>s.type.name===n.name).map(s=>({...s.attrs}))}function $f(t,e){const n=Nc(typeof e=="string"?e:e.name,t.schema);return n==="node"?gX(t,e):n==="mark"?hX(t,e):[]}function Nv({images:t,editor:e,position:n}){if(!e||e.isDestroyed||t.length===0)return;const r=t.filter(o=>!!o.src).map(o=>({type:e.schema.nodes.image.name,attrs:o}));e.chain().command(({commands:o})=>n==null?o.insertContent(r):o.insertContentAt(n,r)).focus().run()}function mX(t){return t.toLowerCase().normalize("NFKD").replace(/[^\w\s-]+/g,"").replace(/[-\s]+/g,"-").replace(/^[\s-_]+|[\s-_]+$/g,"")}function yX({onUploadFiles:t,inputProps:e,insertImages:n=Nv,...r}){const o=bt(),i=J.useRef(null),s=async a=>{if(!o||o.isDestroyed||a.length===0)return;const l=await t(Array.from(a));n({editor:o,images:l})};return v.jsxs(v.Fragment,{children:[v.jsx(rX,{tooltipLabel:"Upload images",onClick:()=>{var a;return(a=i.current)===null||a===void 0?void 0:a.click()},...r}),v.jsx("input",{ref:i,type:"file",accept:"image/*",multiple:!0,onChange:async a=>{a.target.files&&await s(a.target.files),a.target.value=""},style:{display:"none"},...e})]})}function bX(t){const e=bt();return v.jsx(gt,{tooltipLabel:"Indent",tooltipShortcutKeys:["Tab"],IconComponent:vR,disabled:!(e!=null&&e.isEditable)||!e.can().sinkListItem("listItem"),onClick:()=>e==null?void 0:e.chain().focus().sinkListItem("listItem").run(),...t})}function vX(t){var e;const n=bt();return v.jsx(gt,{tooltipLabel:"Italic",tooltipShortcutKeys:["mod","I"],IconComponent:xR,selected:(e=n==null?void 0:n.isActive("italic"))!==null&&e!==void 0?e:!1,disabled:!(n!=null&&n.isEditable)||!n.can().toggleItalic(),onClick:()=>n==null?void 0:n.chain().focus().toggleItalic().run(),...t})}function xX(t){var e;const n=bt();return v.jsx(gt,{tooltipLabel:"Ordered list",tooltipShortcutKeys:["mod","Shift","7"],IconComponent:CR,selected:(e=n==null?void 0:n.isActive("orderedList"))!==null&&e!==void 0?e:!1,disabled:!(n!=null&&n.isEditable)||!n.can().toggleOrderedList(),onClick:()=>n==null?void 0:n.chain().focus().toggleOrderedList().run(),...t})}function SX(t){const e=bt();return v.jsx(gt,{tooltipLabel:"Redo",tooltipShortcutKeys:["mod","Shift","Z"],IconComponent:NR,disabled:!(e!=null&&e.isEditable)||!e.can().redo(),onClick:()=>e==null?void 0:e.chain().focus().redo().run(),...t})}function CX(t){const e=bt();return v.jsx(gt,{tooltipLabel:"Remove inline formatting",IconComponent:mR,disabled:!(e!=null&&e.isEditable)||!e.can().unsetAllMarks(),onClick:()=>e==null?void 0:e.chain().focus().unsetAllMarks().run(),...t})}function wX(t){var e;const n=bt();return v.jsx(gt,{tooltipLabel:"Strikethrough",tooltipShortcutKeys:["mod","Shift","S"],IconComponent:RR,selected:(e=n==null?void 0:n.isActive("strike"))!==null&&e!==void 0?e:!1,disabled:!(n!=null&&n.isEditable)||!n.can().toggleStrike(),onClick:()=>n==null?void 0:n.chain().focus().toggleStrike().run(),...t})}function _X(t){var e;const n=bt();return v.jsx(gt,{tooltipLabel:"Subscript",tooltipShortcutKeys:["mod",","],IconComponent:zR,selected:(e=n==null?void 0:n.isActive("subscript"))!==null&&e!==void 0?e:!1,disabled:!(n!=null&&n.isEditable)||!n.can().toggleSubscript(),onClick:()=>n==null?void 0:n.chain().focus().toggleSubscript().run(),...t})}function TX(t){var e;const n=bt();return v.jsx(gt,{tooltipLabel:"Superscript",tooltipShortcutKeys:["mod","."],IconComponent:VR,selected:(e=n==null?void 0:n.isActive("superscript"))!==null&&e!==void 0?e:!1,disabled:!(n!=null&&n.isEditable)||!n.can().toggleSuperscript(),onClick:()=>n==null?void 0:n.chain().focus().toggleSuperscript().run(),...t})}function kX(t){var e;const n=bt();return v.jsx(gt,{tooltipLabel:"Task checklist",tooltipShortcutKeys:["mod","Shift","9"],IconComponent:iR,selected:(e=n==null?void 0:n.isActive("taskList"))!==null&&e!==void 0?e:!1,disabled:!(n!=null&&n.isEditable)||!n.can().toggleTaskList(),onClick:()=>n==null?void 0:n.chain().focus().toggleTaskList().run(),...t})}function EX({IconComponent:t=SZ,tooltipLabel:e="Text color",defaultTextColor:n="",...r}){const o=bt(),i=o?$f(o.state,"textStyle"):[],s=!!(o!=null&&o.isActive("textStyle")),a=i.map(f=>f.color||n);s||a.push(n);const l=new Set(a).size;let u;return l===1?u=a[0]:l>1?u="":u=n,v.jsx(Pv,{IconComponent:t,tooltipLabel:e,value:u,onChange:f=>{o==null||o.chain().focus().setColor(f).run()},disabled:!(o!=null&&o.isEditable)||!o.can().setColor("#000"),...r,labels:{removeColorButton:"Reset",...r.labels}})}function MX(t){var e;const n=bt();return v.jsx(gt,{tooltipLabel:"Underline",tooltipShortcutKeys:["mod","U"],IconComponent:TR,selected:(e=n==null?void 0:n.isActive("underline"))!==null&&e!==void 0?e:!1,disabled:!(n!=null&&n.isEditable)||!n.can().toggleUnderline(),onClick:()=>n==null?void 0:n.chain().focus().toggleUnderline().run(),...t})}function OX(t){const e=bt();return v.jsx(gt,{tooltipLabel:"Undo",tooltipShortcutKeys:["mod","Z"],IconComponent:HR,disabled:!(e!=null&&e.isEditable)||!e.can().undo(),onClick:()=>e==null?void 0:e.chain().focus().undo().run(),...t})}function AX(t){const e=bt();return v.jsx(gt,{tooltipLabel:"Unindent",tooltipShortcutKeys:["Shift","Tab"],IconComponent:bR,disabled:!(e!=null&&e.isEditable)||!e.can().liftListItem("listItem"),onClick:()=>e==null?void 0:e.chain().focus().liftListItem("listItem").run(),...t})}const IX=Ut({name:{MenuSelect:Uc}})(t=>({rootTooltipWrapper:{display:"inline-flex"},selectRoot:{[`&:not(:hover):not(.${F.outlinedInputClasses.focused}) .${F.outlinedInputClasses.notchedOutline}`]:{borderWidth:0},[`& .${F.svgIconClasses.root}`]:{color:t.palette.action.active},[`&.${F.selectClasses.disabled} .${F.svgIconClasses.root}`]:{color:t.palette.action.disabled}},select:{"&&&":{paddingLeft:t.spacing(1),paddingRight:t.spacing(3)}},selectDropdownIcon:{right:1},input:{paddingTop:"3px",paddingBottom:"3px",fontSize:"0.9em"}}));function Uc({tooltipTitle:t,...e}){var n,r,o;const{classes:i,cx:s}=IX(),[a,l]=J.useState(!1),u=v.jsx(F.Select,{margin:"none",variant:"outlined",size:"small",...e,onMouseEnter:(...f)=>{var p;l(!0),(p=e.onMouseEnter)===null||p===void 0||p.call(e,...f)},onMouseLeave:(...f)=>{var p;l(!1),(p=e.onMouseLeave)===null||p===void 0||p.call(e,...f)},onClick:(...f)=>{var p;l(!1),(p=e.onClick)===null||p===void 0||p.call(e,...f)},onOpen:(...f)=>{var p;l(!1),(p=e.onOpen)===null||p===void 0||p.call(e,...f)},inputProps:{...e.inputProps,className:s(i.input,(n=e.inputProps)===null||n===void 0?void 0:n.className)},MenuProps:{anchorOrigin:{vertical:"bottom",horizontal:"left"},transformOrigin:{vertical:"top",horizontal:"left"},...e.MenuProps},className:s(i.selectRoot,e.className),classes:{...e.classes,select:s(i.select,(r=e.classes)===null||r===void 0?void 0:r.select),icon:s(i.selectDropdownIcon,(o=e.classes)===null||o===void 0?void 0:o.icon)}});return t?v.jsx(co,{label:t,contentWrapperClassName:i.rootTooltipWrapper,open:a,children:u}):u}const DX=Ut({name:{MenuSelectFontFamily:SI}})({selectInput:{width:55}}),Lv="MULTIPLE";function SI({options:t,hideUnsetOption:e=!1,unsetOptionLabel:n="Default",emptyLabel:r="Font",...o}){var i;const{classes:s,cx:a}=DX(),l=bt(),u=l?$f(l.state,"textStyle"):[],f=!!(l!=null&&l.isActive("textStyle")),p=u.map(y=>{var b;return(b=y.fontFamily)!==null&&b!==void 0?b:""});f||p.push("");const g=new Set(p).size;let m;return g===1?m=p[0]:g>1?m=Lv:m="",v.jsxs(Uc,{onChange:y=>{const b=y.target.value;b?l==null||l.chain().setFontFamily(b).focus().run():l==null||l.chain().unsetFontFamily().focus().run()},disabled:!(l!=null&&l.isEditable)||!l.can().setFontFamily("serif"),renderValue:y=>{var b,S;return!y||y===Lv?r:(S=(b=t.find(C=>C.value===y))===null||b===void 0?void 0:b.label)!==null&&S!==void 0?S:y},displayEmpty:!0,"aria-label":"Font families",tooltipTitle:"Font",...o,value:m||"",inputProps:{...o.inputProps,className:a(s.selectInput,(i=o.inputProps)===null||i===void 0?void 0:i.className)},children:[!e&&v.jsx(F.MenuItem,{value:"",children:n}),v.jsx(F.MenuItem,{style:{display:"none"},value:Lv}),t.map(y=>{var b;return v.jsx(F.MenuItem,{value:y.value,children:v.jsx("span",{style:{fontFamily:y.value},children:(b=y.label)!==null&&b!==void 0?b:y.value})},y.value)})]})}const PX=Ut({name:{MenuSelectFontSize:wI}})({selectInput:{width:17,display:"flex",alignItems:"center"},fontSizeIcon:{fontSize:jc}}),NX=["8px","9px","10px","11px","12px","14px","16px","18px","24px","30px","36px","48px","60px","72px","96px"];function CI(t){return t.replace("px","")}const Fv="MULTIPLE";function wI({options:t=NX,sizeOptions:e,hideUnsetOption:n=!1,unsetOptionLabel:r="Default",unsetOptionContent:o,emptyLabel:i,emptyValue:s,...a}){var l;const{classes:u,cx:f}=PX(),p=bt();i=s??i,r=o??r,t=e??t;const g=(t??[]).map(T=>typeof T=="string"?{value:T}:T),m=p?$f(p.state,"textStyle"):[],y=!!(p!=null&&p.isActive("textStyle")),b=m.map(T=>{var _;return(_=T.fontSize)!==null&&_!==void 0?_:""});y||b.push("");const S=new Set(b).size;let C;return S===1?C=b[0]:S>1?C=Fv:C="",v.jsxs(Uc,{onChange:T=>{const _=T.target.value;_?p==null||p.chain().setFontSize(_).focus().run():p==null||p.chain().unsetFontSize().focus().run()},disabled:!(p!=null&&p.isEditable)||!p.can().setFontSize("12px"),renderValue:T=>!T||T===Fv?i??v.jsx(_R,{className:u.fontSizeIcon}):CI(T),displayEmpty:!0,"aria-label":"Font sizes",tooltipTitle:"Font size",...a,value:C||"",inputProps:{...a.inputProps,className:f(u.selectInput,(l=a.inputProps)===null||l===void 0?void 0:l.className)},children:[!n&&v.jsx(F.MenuItem,{value:"",children:r}),v.jsx(F.MenuItem,{style:{display:"none"},value:Fv}),g.map(T=>{var _;return v.jsx(F.MenuItem,{value:T.value,children:(_=T.label)!==null&&_!==void 0?_:CI(T.value)},T.value)})]})}const LX=Ut({name:{MenuSelectHeading:kI}})(t=>{const e=t2(t);return{selectInput:{width:77},menuOption:{display:"block",width:"100%"},headingOption:{marginBlockStart:0,marginBlockEnd:0,fontWeight:"bold"},headingOption1:{fontSize:e["& h1"].fontSize},headingOption2:{fontSize:e["& h2"].fontSize},headingOption3:{fontSize:e["& h3"].fontSize},headingOption4:{fontSize:e["& h4"].fontSize},headingOption5:{fontSize:e["& h5"].fontSize},headingOption6:{fontSize:e["& h6"].fontSize}}}),vt={Paragraph:"Paragraph",Heading1:"Heading 1",Heading2:"Heading 2",Heading3:"Heading 3",Heading4:"Heading 4",Heading5:"Heading 5",Heading6:"Heading 6"},_I={[vt.Heading1]:1,[vt.Heading2]:2,[vt.Heading3]:3,[vt.Heading4]:4,[vt.Heading5]:5,[vt.Heading6]:6},TI={1:vt.Heading1,2:vt.Heading2,3:vt.Heading3,4:vt.Heading4,5:vt.Heading5,6:vt.Heading6};function kI({labels:t,hideShortcuts:e=!1,...n}){var r,o,i,s,a,l,u,f;const{classes:p,cx:g}=LX(),m=bt(),y=J.useCallback(L=>{const P=L.target.value;P===vt.Paragraph?m==null||m.chain().setParagraph().focus().run():P in _I&&(m==null||m.chain().setHeading({level:_I[P]}).focus().run())},[m]);let b="",S;if(m!=null&&m.isActive("paragraph"))b=vt.Paragraph;else if(m!=null&&m.isActive("heading")){const P=$f(m.state,"heading").map(M=>M.level);S=new Set(P).size===1?P[0]:void 0,S&&S in TI&&(b=TI[S])}const C=b!=="",T=!!(m!=null&&m.can().setParagraph()),_=J.useMemo(()=>{var L;const P=m==null?void 0:m.extensionManager.extensions.find($=>$.name=="heading");return new Set((L=P==null?void 0:P.options.levels)!==null&&L!==void 0?L:[])},[m]),w=_.values().next(),E=w.done?void 0:w.value,O=E!==void 0&&(S===E||!!(m!=null&&m.can().setHeading({level:E})));return v.jsxs(Uc,{onChange:y,disabled:!(m!=null&&m.isEditable)||!C&&!T&&!O,displayEmpty:!0,renderValue:L=>{var P,$;let M;return L===""?M=($=(P=t==null?void 0:t.emptyValue)!==null&&P!==void 0?P:t==null?void 0:t.empty)!==null&&$!==void 0?$:v.jsx("em",{children:"Change to…"}):L===vt.Paragraph?M=t==null?void 0:t.paragraph:L===vt.Heading1?M=t==null?void 0:t.heading1:L===vt.Heading2?M=t==null?void 0:t.heading2:L===vt.Heading3?M=t==null?void 0:t.heading3:L===vt.Heading4?M=t==null?void 0:t.heading4:L===vt.Heading5?M=t==null?void 0:t.heading5:L===vt.Heading6&&(M=t==null?void 0:t.heading6),M??L},"aria-label":"Text headings",tooltipTitle:"Styles",...n,value:b,inputProps:{...n.inputProps,className:g(p.selectInput,(r=n.inputProps)===null||r===void 0?void 0:r.className)},children:[v.jsx(F.MenuItem,{value:vt.Paragraph,disabled:!C&&!T,children:v.jsx(co,{label:"",shortcutKeys:e?void 0:["mod","alt","0"],placement:"right",contentWrapperClassName:p.menuOption,children:(o=t==null?void 0:t.paragraph)!==null&&o!==void 0?o:vt.Paragraph})}),_.has(1)&&v.jsx(F.MenuItem,{value:vt.Heading1,disabled:!O,children:v.jsx(co,{label:"",shortcutKeys:e?void 0:["mod","alt","1"],placement:"right",contentWrapperClassName:g(p.menuOption,p.headingOption,p.headingOption1),children:(i=t==null?void 0:t.heading1)!==null&&i!==void 0?i:vt.Heading1})}),_.has(2)&&v.jsx(F.MenuItem,{value:vt.Heading2,disabled:!O,children:v.jsx(co,{label:"",shortcutKeys:e?void 0:["mod","alt","2"],placement:"right",contentWrapperClassName:g(p.menuOption,p.headingOption,p.headingOption2),children:(s=t==null?void 0:t.heading2)!==null&&s!==void 0?s:vt.Heading2})}),_.has(3)&&v.jsx(F.MenuItem,{value:vt.Heading3,disabled:!O,children:v.jsx(co,{label:"",shortcutKeys:e?void 0:["mod","alt","3"],placement:"right",contentWrapperClassName:g(p.menuOption,p.headingOption,p.headingOption3),children:(a=t==null?void 0:t.heading3)!==null&&a!==void 0?a:vt.Heading3})}),_.has(4)&&v.jsx(F.MenuItem,{value:vt.Heading4,disabled:!O,children:v.jsx(co,{label:"",shortcutKeys:e?void 0:["mod","alt","4"],placement:"right",contentWrapperClassName:g(p.menuOption,p.headingOption,p.headingOption4),children:(l=t==null?void 0:t.heading4)!==null&&l!==void 0?l:vt.Heading4})}),_.has(5)&&v.jsx(F.MenuItem,{value:vt.Heading5,disabled:!O,children:v.jsx(co,{label:"",shortcutKeys:e?void 0:["mod","alt","5"],placement:"right",contentWrapperClassName:g(p.menuOption,p.headingOption,p.headingOption5),children:(u=t==null?void 0:t.heading5)!==null&&u!==void 0?u:vt.Heading5})}),_.has(6)&&v.jsx(F.MenuItem,{value:vt.Heading6,disabled:!O,children:v.jsx(co,{label:"",shortcutKeys:e?void 0:["mod","alt","6"],placement:"right",contentWrapperClassName:g(p.menuOption,p.headingOption,p.headingOption6),children:(f=t==null?void 0:t.heading6)!==null&&f!==void 0?f:vt.Heading6})})]})}const FX=Ut({name:{MenuSelectTextAlign:EI}})(t=>({selectInput:{width:jc},menuItem:{paddingLeft:0,paddingRight:0},menuOption:{display:"flex",width:"100%",justifyContent:"center"},menuButtonIcon:{fontSize:jc,color:t.palette.action.active}})),$X=[{value:"left",label:"Left",shortcutKeys:["mod","Shift","L"],IconComponent:pR},{value:"center",label:"Center",shortcutKeys:["mod","Shift","E"],IconComponent:dR},{value:"right",label:"Right",shortcutKeys:["mod","Shift","R"],IconComponent:hR},{value:"justify",label:"Justify",shortcutKeys:["mod","Shift","J"],IconComponent:fR}];function EI({options:t=$X,emptyLabel:e="",alignmentOptions:n,...r}){var o,i,s;const{classes:a,cx:l}=FX(),u=bt();t=(o=n==null?void 0:n.map(y=>({...y,value:y.alignment})))!==null&&o!==void 0?o:t;const f=J.useCallback(y=>{const b=y.target.value;u==null||u.chain().setTextAlign(b).focus().run()},[u]),p=J.useMemo(()=>{const y=u==null?void 0:u.extensionManager.extensions.find(b=>b.name=="textAlign");return y==null?void 0:y.options},[u]),g=J.useMemo(()=>new Set(p==null?void 0:p.alignments),[p]),m=(i=Array.from(g).find(y=>u==null?void 0:u.isActive({textAlign:y})))!==null&&i!==void 0?i:"";return v.jsx(Uc,{onChange:f,disabled:!(u!=null&&u.isEditable)||!Array.from(g).some(y=>u.can().setTextAlign(y)),renderValue:y=>{let b;if(y){const S=t.find(C=>C.value===y);b=S?v.jsx(S.IconComponent,{className:a.menuButtonIcon}):y}else b=e;return v.jsx("span",{className:a.menuOption,children:b})},"aria-label":"Text alignments",tooltipTitle:"Align",value:m,displayEmpty:!0,...r,inputProps:{...r.inputProps,className:l(a.selectInput,(s=r.inputProps)===null||s===void 0?void 0:s.className)},children:t.filter(y=>g.has(y.value)).map(y=>{var b;return v.jsx(F.MenuItem,{value:y.value,disabled:!(u!=null&&u.can().setTextAlign(y.value)),className:a.menuItem,children:v.jsx(co,{label:(b=y.label)!==null&&b!==void 0?b:"",shortcutKeys:y.shortcutKeys,placement:"right",contentWrapperClassName:a.menuOption,children:v.jsx(y.IconComponent,{className:a.menuButtonIcon})})},y.value)})})}const BX=sn.create({name:"fontSize",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{fontSize:{default:null,parseHTML:t=>t.style.fontSize.replace(/['"]+/g,""),renderHTML:t=>t.fontSize?{style:`font-size: ${t.fontSize}`}:{}}}}]},addCommands(){return{setFontSize:t=>({chain:e})=>e().setMark("textStyle",{fontSize:t}).run(),unsetFontSize:()=>({chain:t})=>t().setMark("textStyle",{fontSize:null}).removeEmptyTextStyle().run()}}}),MI=tn.create({name:"heading",addOptions(){return{levels:[1,2,3,4,5,6],HTMLAttributes:{}}},content:"inline*",group:"block",defining:!0,addAttributes(){return{level:{default:1,rendered:!1}}},parseHTML(){return this.options.levels.map(t=>({tag:`h${t}`,attrs:{level:t}}))},renderHTML({node:t,HTMLAttributes:e}){return[`h${this.options.levels.includes(t.attrs.level)?t.attrs.level:this.options.levels[0]}`,yt(this.options.HTMLAttributes,e),0]},addCommands(){return{setHeading:t=>({commands:e})=>this.options.levels.includes(t.level)?e.setNode(this.name,t):!1,toggleHeading:t=>({commands:e})=>this.options.levels.includes(t.level)?e.toggleNode(this.name,"paragraph",t):!1}},addKeyboardShortcuts(){return this.options.levels.reduce((t,e)=>({...t,[`Mod-Alt-${e}`]:()=>this.editor.commands.toggleHeading({level:e})}),{})},addInputRules(){return this.options.levels.map(t=>ly({find:new RegExp(`^(#{${Math.min(...this.options.levels)},${t}})\\s$`),type:this.type,getAttributes:{level:t}}))}}),RX=Ut({name:{HeadingWithAnchorComponent:OI},uniqId:"kNc4LD"})((t,e,n)=>({root:{[`&:hover .${n.link}`]:{opacity:100}},container:{display:"inline-block",position:"relative"},link:{position:"absolute",left:-21,color:`${t.palette.text.secondary} !important`,opacity:0,transition:t.transitions.create("opacity"),textDecoration:"none",outline:"none",[t.breakpoints.down("sm")]:{left:-18},'.ProseMirror[contenteditable="true"] &':{display:"none"}},linkIcon:{transform:"rotate(-45deg)",fontSize:"1.25rem",[t.breakpoints.down("sm")]:{fontSize:"1.15rem"}}})),Bf=Rs("HeadingWithAnchorComponent",["root","container","link","linkIcon"]);function OI({editor:t,node:e,extension:n}){const{classes:r,cx:o}=RX(),a=`h${n.options.levels.includes(e.attrs.level)?e.attrs.level:n.options.levels[0]}`,l=J.useMemo(()=>Qm(t.schema),[t.schema]),u=mX(JE(e,{textSerializers:l}));return v.jsx(yv,{as:a,id:u,...n.options.HTMLAttributes,className:o(Bf.root,r.root),style:{textAlign:e.attrs.textAlign},children:v.jsxs("span",{className:o(Bf.container,r.container),children:[v.jsx("a",{href:`#${u}`,contentEditable:!1,className:o(Bf.link,r.link),children:v.jsx(Ju,{className:o(Bf.linkIcon,r.linkIcon)})}),v.jsx(aZ,{as:"span"})]})})}const zX=MI.extend({addOptions(){var t;return{...(t=this.parent)===null||t===void 0?void 0:t.call(this),scrollToAnchorOnMount:!0}},onCreate(){this.options.scrollToAnchorOnMount&&setTimeout(()=>{VX(this.editor)})},addNodeView(){return bv(OI)}});function VX(t){if(t.isDestroyed||!("heading"in t.storage))return;const n=window.location.hash.slice(1);if(!n)return;const r=window.document.getElementById(n);r&&t.options.element.contains(r)&&r.scrollIntoView({behavior:"smooth",block:"start",inline:"nearest"})}const HX=/(?:^|\s)(!\[(.+|:?)]\((\S+)(?:(?:\s+)["'](\S+)["'])?\))$/,jX=tn.create({name:"image",addOptions(){return{inline:!1,allowBase64:!1,HTMLAttributes:{}}},inline(){return this.options.inline},group(){return this.options.inline?"inline":"block"},draggable:!0,addAttributes(){return{src:{default:null},alt:{default:null},title:{default:null}}},parseHTML(){return[{tag:this.options.allowBase64?"img[src]":'img[src]:not([src^="data:"])'}]},renderHTML({HTMLAttributes:t}){return["img",yt(this.options.HTMLAttributes,t)]},addCommands(){return{setImage:t=>({commands:e})=>e.insertContent({type:this.name,attrs:t})}},addInputRules(){return[tM({find:HX,type:this.type,getAttributes:t=>{const[,,e,n,r]=t;return{src:n,alt:e,title:r}}})]}}),WX=Ut({name:{ResizableImageResizer:AI}})(t=>({root:{position:"absolute",bottom:-3,right:-3,width:12,height:12,background:t.palette.primary.main,cursor:"nwse-resize"}}));function AI({onResize:t,className:e,mouseDown:n,setMouseDown:r}){const{classes:o,cx:i}=WX();J.useEffect(()=>{if(!n)return;const a=l=>{t(l)};return window.addEventListener("mousemove",a),()=>{window.removeEventListener("mousemove",a)}},[n,t]),J.useEffect(()=>{const a=()=>{r(!1)};return window.addEventListener("mouseup",a),()=>{window.removeEventListener("mouseup",a)}},[r]);const s=J.useCallback(a=>{r(!0)},[r]);return v.jsx("div",{className:i(o.root,e),onMouseDown:s})}const qX=15,UX=Ut({name:{ResizableImageComponent:II}})(t=>({imageContainer:{display:"inline-flex",position:"relative"},image:{display:"block"},imageSelected:{outline:`3px solid ${t.palette.primary.main}`},resizer:{'.ProseMirror[contenteditable="false"] &':{display:"none"}}}));function II(t){var e;const{node:n,selected:r,updateAttributes:o,extension:i}=t,{classes:s,cx:a}=UX(),{attrs:l}=n,u=J.useRef(null),[f,p]=J.useState(!1),g=r||f,m=J.useMemo(()=>NC(b=>{if(!u.current)return;const S=u.current.getBoundingClientRect(),C=b.clientX-S.x,T=b.clientY-S.y,_=Math.max(C,S.width/S.height*T,qX);o({width:Math.round(_)})},50,{trailing:!0}),[o]),y=i.options.ChildComponent;return v.jsx(yv,{style:{textAlign:l.textAlign,width:"100%"},as:i.options.inline?"span":"div",children:v.jsxs("div",{className:s.imageContainer,children:[v.jsx("img",{ref:u,src:l.src,height:"auto",width:l.width?l.width:void 0,alt:l.alt||void 0,title:l.title||void 0,className:a(s.image,g&&"ProseMirror-selectednode",g&&s.imageSelected),style:{maxWidth:l.width?void 0:"auto",aspectRatio:(e=l.aspectRatio)!==null&&e!==void 0?e:void 0},"data-drag-handle":!0,onLoad:b=>{const S={};l.width||(S.width=b.currentTarget.naturalWidth),l.aspectRatio||(S.aspectRatio=String(b.currentTarget.naturalWidth/b.currentTarget.naturalHeight)),(S.width||S.aspectRatio)&&o(S)}}),g&&v.jsx(AI,{onResize:m,className:s.resizer,mouseDown:f,setMouseDown:p}),y&&v.jsx(y,{...t})]})})}const KX=jX.extend({addOptions(){var t;return{...(t=this.parent)===null||t===void 0?void 0:t.call(this),isAllowedImgSrc:e=>!!e}},addAttributes(){var t;return{...(t=this.parent)===null||t===void 0?void 0:t.call(this),width:{default:null,renderHTML:e=>({width:e.width}),parseHTML:e=>e.getAttribute("width")},aspectRatio:{default:null,renderHTML:e=>e.aspectRatio?{style:`aspect-ratio: ${e.aspectRatio}`}:{},parseHTML:e=>e.style.aspectRatio}}},renderHTML({HTMLAttributes:t}){return["img",yt({height:"auto"},this.options.HTMLAttributes,t)]},parseHTML(){return[{tag:this.options.allowBase64?"img[src]":'img[src]:not([src^="data:"])',getAttrs:t=>{if(!(t instanceof Element))return!1;const e=t.getAttribute("src");return this.options.isAllowedImgSrc(e)&&null}}]},addInputRules(){var t;const e=(t=this.parent)===null||t===void 0?void 0:t.call(this);if(!e)return[];const n=r=>{const[,,o,i,s]=r;return{src:i,alt:o,title:s}};return e.map(r=>new Ic({find:r.find,handler:o=>{const i=n(o.match);if(this.options.isAllowedImgSrc(i.src))return r.handler(o)}}))},addNodeView(){return bv(II)}});var $v,Bv;if(typeof WeakMap<"u"){let t=new WeakMap;$v=e=>t.get(e),Bv=(e,n)=>(t.set(e,n),n)}else{const t=[];let n=0;$v=r=>{for(let o=0;o<t.length;o+=2)if(t[o]==r)return t[o+1]},Bv=(r,o)=>(n==10&&(n=0),t[n++]=r,t[n++]=o)}var an=class{constructor(t,e,n,r){this.width=t,this.height=e,this.map=n,this.problems=r}findCell(t){for(let e=0;e<this.map.length;e++){const n=this.map[e];if(n!=t)continue;const r=e%this.width,o=e/this.width|0;let i=r+1,s=o+1;for(let a=1;i<this.width&&this.map[e+a]==n;a++)i++;for(let a=1;s<this.height&&this.map[e+this.width*a]==n;a++)s++;return{left:r,top:o,right:i,bottom:s}}throw new RangeError(`No cell with offset ${t} found`)}colCount(t){for(let e=0;e<this.map.length;e++)if(this.map[e]==t)return e%this.width;throw new RangeError(`No cell with offset ${t} found`)}nextCell(t,e,n){const{left:r,right:o,top:i,bottom:s}=this.findCell(t);return e=="horiz"?(n<0?r==0:o==this.width)?null:this.map[i*this.width+(n<0?r-1:o)]:(n<0?i==0:s==this.height)?null:this.map[r+this.width*(n<0?i-1:s)]}rectBetween(t,e){const{left:n,right:r,top:o,bottom:i}=this.findCell(t),{left:s,right:a,top:l,bottom:u}=this.findCell(e);return{left:Math.min(n,s),top:Math.min(o,l),right:Math.max(r,a),bottom:Math.max(i,u)}}cellsInRect(t){const e=[],n={};for(let r=t.top;r<t.bottom;r++)for(let o=t.left;o<t.right;o++){const i=r*this.width+o,s=this.map[i];n[s]||(n[s]=!0,!(o==t.left&&o&&this.map[i-1]==s||r==t.top&&r&&this.map[i-this.width]==s)&&e.push(s))}return e}positionAt(t,e,n){for(let r=0,o=0;;r++){const i=o+n.child(r).nodeSize;if(r==t){let s=e+t*this.width;const a=(t+1)*this.width;for(;s<a&&this.map[s]<o;)s++;return s==a?i-1:this.map[s]}o=i}}static get(t){return $v(t)||Bv(t,YX(t))}};function YX(t){if(t.type.spec.tableRole!="table")throw new RangeError("Not a table node: "+t.type.name);const e=GX(t),n=t.childCount,r=[];let o=0,i=null;const s=[];for(let u=0,f=e*n;u<f;u++)r[u]=0;for(let u=0,f=0;u<n;u++){const p=t.child(u);f++;for(let y=0;;y++){for(;o<r.length&&r[o]!=0;)o++;if(y==p.childCount)break;const b=p.child(y),{colspan:S,rowspan:C,colwidth:T}=b.attrs;for(let _=0;_<C;_++){if(_+u>=n){(i||(i=[])).push({type:"overlong_rowspan",pos:f,n:C-_});break}const w=o+_*e;for(let E=0;E<S;E++){r[w+E]==0?r[w+E]=f:(i||(i=[])).push({type:"collision",row:u,pos:f,n:S-E});const O=T&&T[E];if(O){const L=(w+E)%e*2,P=s[L];P==null||P!=O&&s[L+1]==1?(s[L]=O,s[L+1]=1):P==O&&s[L+1]++}}}o+=S,f+=b.nodeSize}const g=(u+1)*e;let m=0;for(;o<g;)r[o++]==0&&m++;m&&(i||(i=[])).push({type:"missing",row:u,n:m}),f++}(e===0||n===0)&&(i||(i=[])).push({type:"zero_sized"});const a=new an(e,n,r,i);let l=!1;for(let u=0;!l&&u<s.length;u+=2)s[u]!=null&&s[u+1]<n&&(l=!0);return l&&JX(a,s,t),a}function GX(t){let e=-1,n=!1;for(let r=0;r<t.childCount;r++){const o=t.child(r);let i=0;if(n)for(let s=0;s<r;s++){const a=t.child(s);for(let l=0;l<a.childCount;l++){const u=a.child(l);s+u.attrs.rowspan>r&&(i+=u.attrs.colspan)}}for(let s=0;s<o.childCount;s++){const a=o.child(s);i+=a.attrs.colspan,a.attrs.rowspan>1&&(n=!0)}e==-1?e=i:e!=i&&(e=Math.max(e,i))}return e}function JX(t,e,n){t.problems||(t.problems=[]);const r={};for(let o=0;o<t.map.length;o++){const i=t.map[o];if(r[i])continue;r[i]=!0;const s=n.nodeAt(i);if(!s)throw new RangeError(`No cell with offset ${i} found`);let a=null;const l=s.attrs;for(let u=0;u<l.colspan;u++){const f=(o+u)%t.width,p=e[f*2];p!=null&&(!l.colwidth||l.colwidth[u]!=p)&&((a||(a=ZX(l)))[u]=p)}a&&t.problems.unshift({type:"colwidth mismatch",pos:i,colwidth:a})}}function ZX(t){if(t.colwidth)return t.colwidth.slice();const e=[];for(let n=0;n<t.colspan;n++)e.push(0);return e}function Un(t){let e=t.cached.tableNodeTypes;if(!e){e=t.cached.tableNodeTypes={};for(const n in t.nodes){const r=t.nodes[n],o=r.spec.tableRole;o&&(e[o]=r)}}return e}var qi=new bn("selectingCells");function Xa(t){for(let e=t.depth-1;e>0;e--)if(t.node(e).type.spec.tableRole=="row")return t.node(0).resolve(t.before(e+1));return null}function XX(t){for(let e=t.depth;e>0;e--){const n=t.node(e).type.spec.tableRole;if(n==="cell"||n==="header_cell")return t.node(e)}return null}function uo(t){const e=t.selection.$head;for(let n=e.depth;n>0;n--)if(e.node(n).type.spec.tableRole=="row")return!0;return!1}function Rf(t){const e=t.selection;if("$anchorCell"in e&&e.$anchorCell)return e.$anchorCell.pos>e.$headCell.pos?e.$anchorCell:e.$headCell;if("node"in e&&e.node&&e.node.type.spec.tableRole=="cell")return e.$anchor;const n=Xa(e.$head)||QX(e.$head);if(n)return n;throw new RangeError(`No cell found around position ${e.head}`)}function QX(t){for(let e=t.nodeAfter,n=t.pos;e;e=e.firstChild,n++){const r=e.type.spec.tableRole;if(r=="cell"||r=="header_cell")return t.doc.resolve(n)}for(let e=t.nodeBefore,n=t.pos;e;e=e.lastChild,n--){const r=e.type.spec.tableRole;if(r=="cell"||r=="header_cell")return t.doc.resolve(n-e.nodeSize)}}function Rv(t){return t.parent.type.spec.tableRole=="row"&&!!t.nodeAfter}function eQ(t){return t.node(0).resolve(t.pos+t.nodeAfter.nodeSize)}function zv(t,e){return t.depth==e.depth&&t.pos>=e.start(-1)&&t.pos<=e.end(-1)}function DI(t,e,n){const r=t.node(-1),o=an.get(r),i=t.start(-1),s=o.nextCell(t.pos-i,e,n);return s==null?null:t.node(0).resolve(i+s)}function Vs(t,e,n=1){const r={...t,colspan:t.colspan-n};return r.colwidth&&(r.colwidth=r.colwidth.slice(),r.colwidth.splice(e,n),r.colwidth.some(o=>o>0)||(r.colwidth=null)),r}function PI(t,e,n=1){const r={...t,colspan:t.colspan+n};if(r.colwidth){r.colwidth=r.colwidth.slice();for(let o=0;o<n;o++)r.colwidth.splice(e,0,0)}return r}function tQ(t,e,n){const r=Un(e.type.schema).header_cell;for(let o=0;o<t.height;o++)if(e.nodeAt(t.map[n+o*t.width]).type!=r)return!1;return!0}var Vt=class mi extends Qe{constructor(e,n=e){const r=e.node(-1),o=an.get(r),i=e.start(-1),s=o.rectBetween(e.pos-i,n.pos-i),a=e.node(0),l=o.cellsInRect(s).filter(f=>f!=n.pos-i);l.unshift(n.pos-i);const u=l.map(f=>{const p=r.nodeAt(f);if(!p)throw RangeError(`No cell with offset ${f} found`);const g=i+f+1;return new ak(a.resolve(g),a.resolve(g+p.content.size))});super(u[0].$from,u[0].$to,u),this.$anchorCell=e,this.$headCell=n}map(e,n){const r=e.resolve(n.map(this.$anchorCell.pos)),o=e.resolve(n.map(this.$headCell.pos));if(Rv(r)&&Rv(o)&&zv(r,o)){const i=this.$anchorCell.node(-1)!=r.node(-1);return i&&this.isRowSelection()?mi.rowSelection(r,o):i&&this.isColSelection()?mi.colSelection(r,o):new mi(r,o)}return Ze.between(r,o)}content(){const e=this.$anchorCell.node(-1),n=an.get(e),r=this.$anchorCell.start(-1),o=n.rectBetween(this.$anchorCell.pos-r,this.$headCell.pos-r),i={},s=[];for(let l=o.top;l<o.bottom;l++){const u=[];for(let f=l*n.width+o.left,p=o.left;p<o.right;p++,f++){const g=n.map[f];if(i[g])continue;i[g]=!0;const m=n.findCell(g);let y=e.nodeAt(g);if(!y)throw RangeError(`No cell with offset ${g} found`);const b=o.left-m.left,S=m.right-o.right;if(b>0||S>0){let C=y.attrs;if(b>0&&(C=Vs(C,0,b)),S>0&&(C=Vs(C,C.colspan-S,S)),m.left<o.left){if(y=y.type.createAndFill(C),!y)throw RangeError(`Could not create cell with attrs ${JSON.stringify(C)}`)}else y=y.type.create(C,y.content)}if(m.top<o.top||m.bottom>o.bottom){const C={...y.attrs,rowspan:Math.min(m.bottom,o.bottom)-Math.max(m.top,o.top)};m.top<o.top?y=y.type.createAndFill(C):y=y.type.create(C,y.content)}u.push(y)}s.push(e.child(l).copy(Te.from(u)))}const a=this.isColSelection()&&this.isRowSelection()?e:s;return new Ie(Te.from(a),1,1)}replace(e,n=Ie.empty){const r=e.steps.length,o=this.ranges;for(let s=0;s<o.length;s++){const{$from:a,$to:l}=o[s],u=e.mapping.slice(r);e.replace(u.map(a.pos),u.map(l.pos),s?Ie.empty:n)}const i=Qe.findFrom(e.doc.resolve(e.mapping.slice(r).map(this.to)),-1);i&&e.setSelection(i)}replaceWith(e,n){this.replace(e,new Ie(Te.from(n),0,0))}forEachCell(e){const n=this.$anchorCell.node(-1),r=an.get(n),o=this.$anchorCell.start(-1),i=r.cellsInRect(r.rectBetween(this.$anchorCell.pos-o,this.$headCell.pos-o));for(let s=0;s<i.length;s++)e(n.nodeAt(i[s]),o+i[s])}isColSelection(){const e=this.$anchorCell.index(-1),n=this.$headCell.index(-1);if(Math.min(e,n)>0)return!1;const r=e+this.$anchorCell.nodeAfter.attrs.rowspan,o=n+this.$headCell.nodeAfter.attrs.rowspan;return Math.max(r,o)==this.$headCell.node(-1).childCount}static colSelection(e,n=e){const r=e.node(-1),o=an.get(r),i=e.start(-1),s=o.findCell(e.pos-i),a=o.findCell(n.pos-i),l=e.node(0);return s.top<=a.top?(s.top>0&&(e=l.resolve(i+o.map[s.left])),a.bottom<o.height&&(n=l.resolve(i+o.map[o.width*(o.height-1)+a.right-1]))):(a.top>0&&(n=l.resolve(i+o.map[a.left])),s.bottom<o.height&&(e=l.resolve(i+o.map[o.width*(o.height-1)+s.right-1]))),new mi(e,n)}isRowSelection(){const e=this.$anchorCell.node(-1),n=an.get(e),r=this.$anchorCell.start(-1),o=n.colCount(this.$anchorCell.pos-r),i=n.colCount(this.$headCell.pos-r);if(Math.min(o,i)>0)return!1;const s=o+this.$anchorCell.nodeAfter.attrs.colspan,a=i+this.$headCell.nodeAfter.attrs.colspan;return Math.max(s,a)==n.width}eq(e){return e instanceof mi&&e.$anchorCell.pos==this.$anchorCell.pos&&e.$headCell.pos==this.$headCell.pos}static rowSelection(e,n=e){const r=e.node(-1),o=an.get(r),i=e.start(-1),s=o.findCell(e.pos-i),a=o.findCell(n.pos-i),l=e.node(0);return s.left<=a.left?(s.left>0&&(e=l.resolve(i+o.map[s.top*o.width])),a.right<o.width&&(n=l.resolve(i+o.map[o.width*(a.top+1)-1]))):(a.left>0&&(n=l.resolve(i+o.map[a.top*o.width])),s.right<o.width&&(e=l.resolve(i+o.map[o.width*(s.top+1)-1]))),new mi(e,n)}toJSON(){return{type:"cell",anchor:this.$anchorCell.pos,head:this.$headCell.pos}}static fromJSON(e,n){return new mi(e.resolve(n.anchor),e.resolve(n.head))}static create(e,n,r=n){return new mi(e.resolve(n),e.resolve(r))}getBookmark(){return new nQ(this.$anchorCell.pos,this.$headCell.pos)}};Vt.prototype.visible=!1,Qe.jsonID("cell",Vt);var nQ=class OF{constructor(e,n){this.anchor=e,this.head=n}map(e){return new OF(e.map(this.anchor),e.map(this.head))}resolve(e){const n=e.resolve(this.anchor),r=e.resolve(this.head);return n.parent.type.spec.tableRole=="row"&&r.parent.type.spec.tableRole=="row"&&n.index()<n.parent.childCount&&r.index()<r.parent.childCount&&zv(n,r)?new Vt(n,r):Qe.near(r,1)}};function rQ(t){if(!(t.selection instanceof Vt))return null;const e=[];return t.selection.forEachCell((n,r)=>{e.push(Ln.node(r,r+n.nodeSize,{class:"selectedCell"}))}),Zt.create(t.doc,e)}function oQ({$from:t,$to:e}){if(t.pos==e.pos||t.pos<e.pos-6)return!1;let n=t.pos,r=e.pos,o=t.depth;for(;o>=0&&!(t.after(o+1)<t.end(o));o--,n++);for(let i=e.depth;i>=0&&!(e.before(i+1)>e.start(i));i--,r--);return n==r&&/row|table/.test(t.node(o).type.spec.tableRole)}function iQ({$from:t,$to:e}){let n,r;for(let o=t.depth;o>0;o--){const i=t.node(o);if(i.type.spec.tableRole==="cell"||i.type.spec.tableRole==="header_cell"){n=i;break}}for(let o=e.depth;o>0;o--){const i=e.node(o);if(i.type.spec.tableRole==="cell"||i.type.spec.tableRole==="header_cell"){r=i;break}}return n!==r&&e.parentOffset===0}function sQ(t,e,n){const r=(e||t).selection,o=(e||t).doc;let i,s;if(r instanceof Ye&&(s=r.node.type.spec.tableRole)){if(s=="cell"||s=="header_cell")i=Vt.create(o,r.from);else if(s=="row"){const a=o.resolve(r.from+1);i=Vt.rowSelection(a,a)}else if(!n){const a=an.get(r.node),l=r.from+1,u=l+a.map[a.width*a.height-1];i=Vt.create(o,l+1,u)}}else r instanceof Ze&&oQ(r)?i=Ze.create(o,r.from):r instanceof Ze&&iQ(r)&&(i=Ze.create(o,r.$from.start(),r.$from.end()));return i&&(e||(e=t.tr)).setSelection(i),e}var aQ=new bn("fix-tables");function NI(t,e,n,r){const o=t.childCount,i=e.childCount;e:for(let s=0,a=0;s<i;s++){const l=e.child(s);for(let u=a,f=Math.min(o,s+3);u<f;u++)if(t.child(u)==l){a=u+1,n+=l.nodeSize;continue e}r(l,n),a<o&&t.child(a).sameMarkup(l)?NI(t.child(a),l,n+1,r):l.nodesBetween(0,l.content.size,r,n+1),n+=l.nodeSize}}function LI(t,e){let n;const r=(o,i)=>{o.type.spec.tableRole=="table"&&(n=lQ(t,o,i,n))};return e?e.doc!=t.doc&&NI(e.doc,t.doc,0,r):t.doc.descendants(r),n}function lQ(t,e,n,r){const o=an.get(e);if(!o.problems)return r;r||(r=t.tr);const i=[];for(let l=0;l<o.height;l++)i.push(0);for(let l=0;l<o.problems.length;l++){const u=o.problems[l];if(u.type=="collision"){const f=e.nodeAt(u.pos);if(!f)continue;const p=f.attrs;for(let g=0;g<p.rowspan;g++)i[u.row+g]+=u.n;r.setNodeMarkup(r.mapping.map(n+1+u.pos),null,Vs(p,p.colspan-u.n,u.n))}else if(u.type=="missing")i[u.row]+=u.n;else if(u.type=="overlong_rowspan"){const f=e.nodeAt(u.pos);if(!f)continue;r.setNodeMarkup(r.mapping.map(n+1+u.pos),null,{...f.attrs,rowspan:f.attrs.rowspan-u.n})}else if(u.type=="colwidth mismatch"){const f=e.nodeAt(u.pos);if(!f)continue;r.setNodeMarkup(r.mapping.map(n+1+u.pos),null,{...f.attrs,colwidth:u.colwidth})}else if(u.type=="zero_sized"){const f=r.mapping.map(n);r.delete(f,f+e.nodeSize)}}let s,a;for(let l=0;l<i.length;l++)i[l]&&(s==null&&(s=l),a=l);for(let l=0,u=n+1;l<o.height;l++){const f=e.child(l),p=u+f.nodeSize,g=i[l];if(g>0){let m="cell";f.firstChild&&(m=f.firstChild.type.spec.tableRole);const y=[];for(let S=0;S<g;S++){const C=Un(t.schema)[m].createAndFill();C&&y.push(C)}const b=(l==0||s==l-1)&&a==l?u+1:p-1;r.insert(r.mapping.map(b),y)}u=p}return r.setMeta(aQ,{fixTables:!0})}function Ao(t){const e=t.selection,n=Rf(t),r=n.node(-1),o=n.start(-1),i=an.get(r);return{...e instanceof Vt?i.rectBetween(e.$anchorCell.pos-o,e.$headCell.pos-o):i.findCell(n.pos-o),tableStart:o,map:i,table:r}}function FI(t,{map:e,tableStart:n,table:r},o){let i=o>0?-1:0;tQ(e,r,o+i)&&(i=o==0||o==e.width?null:0);for(let s=0;s<e.height;s++){const a=s*e.width+o;if(o>0&&o<e.width&&e.map[a-1]==e.map[a]){const l=e.map[a],u=r.nodeAt(l);t.setNodeMarkup(t.mapping.map(n+l),null,PI(u.attrs,o-e.colCount(l))),s+=u.attrs.rowspan-1}else{const l=i==null?Un(r.type.schema).cell:r.nodeAt(e.map[a+i]).type,u=e.positionAt(s,o,r);t.insert(t.mapping.map(n+u),l.createAndFill())}}return t}function cQ(t,e){if(!uo(t))return!1;if(e){const n=Ao(t);e(FI(t.tr,n,n.left))}return!0}function uQ(t,e){if(!uo(t))return!1;if(e){const n=Ao(t);e(FI(t.tr,n,n.right))}return!0}function dQ(t,{map:e,table:n,tableStart:r},o){const i=t.mapping.maps.length;for(let s=0;s<e.height;){const a=s*e.width+o,l=e.map[a],u=n.nodeAt(l),f=u.attrs;if(o>0&&e.map[a-1]==l||o<e.width-1&&e.map[a+1]==l)t.setNodeMarkup(t.mapping.slice(i).map(r+l),null,Vs(f,o-e.colCount(l)));else{const p=t.mapping.slice(i).map(r+l);t.delete(p,p+u.nodeSize)}s+=f.rowspan}}function fQ(t,e){if(!uo(t))return!1;if(e){const n=Ao(t),r=t.tr;if(n.left==0&&n.right==n.map.width)return!1;for(let o=n.right-1;dQ(r,n,o),o!=n.left;o--){const i=n.tableStart?r.doc.nodeAt(n.tableStart-1):r.doc;if(!i)throw RangeError("No table found");n.table=i,n.map=an.get(i)}e(r)}return!0}function pQ(t,e,n){var r;const o=Un(e.type.schema).header_cell;for(let i=0;i<t.width;i++)if(((r=e.nodeAt(t.map[i+n*t.width]))==null?void 0:r.type)!=o)return!1;return!0}function $I(t,{map:e,tableStart:n,table:r},o){var i;let s=n;for(let u=0;u<o;u++)s+=r.child(u).nodeSize;const a=[];let l=o>0?-1:0;pQ(e,r,o+l)&&(l=o==0||o==e.height?null:0);for(let u=0,f=e.width*o;u<e.width;u++,f++)if(o>0&&o<e.height&&e.map[f]==e.map[f-e.width]){const p=e.map[f],g=r.nodeAt(p).attrs;t.setNodeMarkup(n+p,null,{...g,rowspan:g.rowspan+1}),u+=g.colspan-1}else{const p=l==null?Un(r.type.schema).cell:(i=r.nodeAt(e.map[f+l*e.width]))==null?void 0:i.type,g=p==null?void 0:p.createAndFill();g&&a.push(g)}return t.insert(s,Un(r.type.schema).row.create(null,a)),t}function hQ(t,e){if(!uo(t))return!1;if(e){const n=Ao(t);e($I(t.tr,n,n.top))}return!0}function gQ(t,e){if(!uo(t))return!1;if(e){const n=Ao(t);e($I(t.tr,n,n.bottom))}return!0}function mQ(t,{map:e,table:n,tableStart:r},o){let i=0;for(let u=0;u<o;u++)i+=n.child(u).nodeSize;const s=i+n.child(o).nodeSize,a=t.mapping.maps.length;t.delete(i+r,s+r);const l=new Set;for(let u=0,f=o*e.width;u<e.width;u++,f++){const p=e.map[f];if(!l.has(p)){if(l.add(p),o>0&&p==e.map[f-e.width]){const g=n.nodeAt(p).attrs;t.setNodeMarkup(t.mapping.slice(a).map(p+r),null,{...g,rowspan:g.rowspan-1}),u+=g.colspan-1}else if(o<e.height&&p==e.map[f+e.width]){const g=n.nodeAt(p),m=g.attrs,y=g.type.create({...m,rowspan:g.attrs.rowspan-1},g.content),b=e.positionAt(o+1,u,n);t.insert(t.mapping.slice(a).map(r+b),y),u+=m.colspan-1}}}}function yQ(t,e){if(!uo(t))return!1;if(e){const n=Ao(t),r=t.tr;if(n.top==0&&n.bottom==n.map.height)return!1;for(let o=n.bottom-1;mQ(r,n,o),o!=n.top;o--){const i=n.tableStart?r.doc.nodeAt(n.tableStart-1):r.doc;if(!i)throw RangeError("No table found");n.table=i,n.map=an.get(n.table)}e(r)}return!0}function BI(t){const e=t.content;return e.childCount==1&&e.child(0).isTextblock&&e.child(0).childCount==0}function bQ({width:t,height:e,map:n},r){let o=r.top*t+r.left,i=o,s=(r.bottom-1)*t+r.left,a=o+(r.right-r.left-1);for(let l=r.top;l<r.bottom;l++){if(r.left>0&&n[i]==n[i-1]||r.right<t&&n[a]==n[a+1])return!0;i+=t,a+=t}for(let l=r.left;l<r.right;l++){if(r.top>0&&n[o]==n[o-t]||r.bottom<e&&n[s]==n[s+t])return!0;o++,s++}return!1}function RI(t,e){const n=t.selection;if(!(n instanceof Vt)||n.$anchorCell.pos==n.$headCell.pos)return!1;const r=Ao(t),{map:o}=r;if(bQ(o,r))return!1;if(e){const i=t.tr,s={};let a=Te.empty,l,u;for(let f=r.top;f<r.bottom;f++)for(let p=r.left;p<r.right;p++){const g=o.map[f*o.width+p],m=r.table.nodeAt(g);if(!(s[g]||!m))if(s[g]=!0,l==null)l=g,u=m;else{BI(m)||(a=a.append(m.content));const y=i.mapping.map(g+r.tableStart);i.delete(y,y+m.nodeSize)}}if(l==null||u==null)return!0;if(i.setNodeMarkup(l+r.tableStart,null,{...PI(u.attrs,u.attrs.colspan,r.right-r.left-u.attrs.colspan),rowspan:r.bottom-r.top}),a.size){const f=l+1+u.content.size,p=BI(u)?l+1:f;i.replaceWith(p+r.tableStart,f+r.tableStart,a)}i.setSelection(new Vt(i.doc.resolve(l+r.tableStart))),e(i)}return!0}function zI(t,e){const n=Un(t.schema);return vQ(({node:r})=>n[r.type.spec.tableRole])(t,e)}function vQ(t){return(e,n)=>{var r;const o=e.selection;let i,s;if(o instanceof Vt){if(o.$anchorCell.pos!=o.$headCell.pos)return!1;i=o.$anchorCell.nodeAfter,s=o.$anchorCell.pos}else{if(i=XX(o.$from),!i)return!1;s=(r=Xa(o.$from))==null?void 0:r.pos}if(i==null||s==null||i.attrs.colspan==1&&i.attrs.rowspan==1)return!1;if(n){let a=i.attrs;const l=[],u=a.colwidth;a.rowspan>1&&(a={...a,rowspan:1}),a.colspan>1&&(a={...a,colspan:1});const f=Ao(e),p=e.tr;for(let m=0;m<f.right-f.left;m++)l.push(u?{...a,colwidth:u&&u[m]?[u[m]]:null}:a);let g;for(let m=f.top;m<f.bottom;m++){let y=f.map.positionAt(m,f.left,f.table);m==f.top&&(y+=i.nodeSize);for(let b=f.left,S=0;b<f.right;b++,S++)b==f.left&&m==f.top||p.insert(g=p.mapping.map(y+f.tableStart,1),t({node:i,row:m,col:b}).createAndFill(l[S]))}p.setNodeMarkup(s,t({node:i,row:f.top,col:f.left}),l[0]),o instanceof Vt&&p.setSelection(new Vt(p.doc.resolve(o.$anchorCell.pos),g?p.doc.resolve(g):void 0)),n(p)}return!0}}function xQ(t,e){return function(n,r){if(!uo(n))return!1;const o=Rf(n);if(o.nodeAfter.attrs[t]===e)return!1;if(r){const i=n.tr;n.selection instanceof Vt?n.selection.forEachCell((s,a)=>{s.attrs[t]!==e&&i.setNodeMarkup(a,null,{...s.attrs,[t]:e})}):i.setNodeMarkup(o.pos,null,{...o.nodeAfter.attrs,[t]:e}),r(i)}return!0}}function SQ(t){return function(e,n){if(!uo(e))return!1;if(n){const r=Un(e.schema),o=Ao(e),i=e.tr,s=o.map.cellsInRect(t=="column"?{left:o.left,top:0,right:o.right,bottom:o.map.height}:t=="row"?{left:0,top:o.top,right:o.map.width,bottom:o.bottom}:o),a=s.map(l=>o.table.nodeAt(l));for(let l=0;l<s.length;l++)a[l].type==r.header_cell&&i.setNodeMarkup(o.tableStart+s[l],r.cell,a[l].attrs);if(i.steps.length==0)for(let l=0;l<s.length;l++)i.setNodeMarkup(o.tableStart+s[l],r.header_cell,a[l].attrs);n(i)}return!0}}function VI(t,e,n){const r=e.map.cellsInRect({left:0,top:0,right:t=="row"?e.map.width:1,bottom:t=="column"?e.map.height:1});for(let o=0;o<r.length;o++){const i=e.table.nodeAt(r[o]);if(i&&i.type!==n.header_cell)return!1}return!0}function Kc(t,e){return e=e||{useDeprecatedLogic:!1},e.useDeprecatedLogic?SQ(t):function(n,r){if(!uo(n))return!1;if(r){const o=Un(n.schema),i=Ao(n),s=n.tr,a=VI("row",i,o),l=VI("column",i,o),f=(t==="column"?a:t==="row"?l:!1)?1:0,p=t=="column"?{left:0,top:f,right:1,bottom:i.map.height}:t=="row"?{left:f,top:0,right:i.map.width,bottom:1}:i,g=t=="column"?l?o.cell:o.header_cell:t=="row"?a?o.cell:o.header_cell:o.cell;i.map.cellsInRect(p).forEach(m=>{const y=m+i.tableStart,b=s.doc.nodeAt(y);b&&s.setNodeMarkup(y,g,b.attrs)}),r(s)}return!0}}Kc("row",{useDeprecatedLogic:!0}),Kc("column",{useDeprecatedLogic:!0});var CQ=Kc("cell",{useDeprecatedLogic:!0});function wQ(t,e){if(e<0){const n=t.nodeBefore;if(n)return t.pos-n.nodeSize;for(let r=t.index(-1)-1,o=t.before();r>=0;r--){const i=t.node(-1).child(r),s=i.lastChild;if(s)return o-1-s.nodeSize;o-=i.nodeSize}}else{if(t.index()<t.parent.childCount-1)return t.pos+t.nodeAfter.nodeSize;const n=t.node(-1);for(let r=t.indexAfter(-1),o=t.after();r<n.childCount;r++){const i=n.child(r);if(i.childCount)return o+1;o+=i.nodeSize}}return null}function HI(t){return function(e,n){if(!uo(e))return!1;const r=wQ(Rf(e),t);if(r==null)return!1;if(n){const o=e.doc.resolve(r);n(e.tr.setSelection(Ze.between(o,eQ(o))).scrollIntoView())}return!0}}function _Q(t,e){const n=t.selection.$anchor;for(let r=n.depth;r>0;r--)if(n.node(r).type.spec.tableRole=="table")return e&&e(t.tr.delete(n.before(r),n.after(r)).scrollIntoView()),!0;return!1}function zf(t,e){const n=t.selection;if(!(n instanceof Vt))return!1;if(e){const r=t.tr,o=Un(t.schema).cell.createAndFill().content;n.forEachCell((i,s)=>{i.content.eq(o)||r.replace(r.mapping.map(s+1),r.mapping.map(s+i.nodeSize-1),new Ie(o,0,0))}),r.docChanged&&e(r)}return!0}function TQ(t){if(!t.size)return null;let{content:e,openStart:n,openEnd:r}=t;for(;e.childCount==1&&(n>0&&r>0||e.child(0).type.spec.tableRole=="table");)n--,r--,e=e.child(0).content;const o=e.child(0),i=o.type.spec.tableRole,s=o.type.schema,a=[];if(i=="row")for(let l=0;l<e.childCount;l++){let u=e.child(l).content;const f=l?0:Math.max(0,n-1),p=l<e.childCount-1?0:Math.max(0,r-1);(f||p)&&(u=Vv(Un(s).row,new Ie(u,f,p)).content),a.push(u)}else if(i=="cell"||i=="header_cell")a.push(n||r?Vv(Un(s).row,new Ie(e,n,r)).content:e);else return null;return kQ(s,a)}function kQ(t,e){const n=[];for(let o=0;o<e.length;o++){const i=e[o];for(let s=i.childCount-1;s>=0;s--){const{rowspan:a,colspan:l}=i.child(s).attrs;for(let u=o;u<o+a;u++)n[u]=(n[u]||0)+l}}let r=0;for(let o=0;o<n.length;o++)r=Math.max(r,n[o]);for(let o=0;o<n.length;o++)if(o>=e.length&&e.push(Te.empty),n[o]<r){const i=Un(t).cell.createAndFill(),s=[];for(let a=n[o];a<r;a++)s.push(i);e[o]=e[o].append(Te.from(s))}return{height:e.length,width:r,rows:e}}function Vv(t,e){const n=t.createAndFill();return new mm(n).replace(0,n.content.size,e).doc}function EQ({width:t,height:e,rows:n},r,o){if(t!=r){const i=[],s=[];for(let a=0;a<n.length;a++){const l=n[a],u=[];for(let f=i[a]||0,p=0;f<r;p++){let g=l.child(p%l.childCount);f+g.attrs.colspan>r&&(g=g.type.createChecked(Vs(g.attrs,g.attrs.colspan,f+g.attrs.colspan-r),g.content)),u.push(g),f+=g.attrs.colspan;for(let m=1;m<g.attrs.rowspan;m++)i[a+m]=(i[a+m]||0)+g.attrs.colspan}s.push(Te.from(u))}n=s,t=r}if(e!=o){const i=[];for(let s=0,a=0;s<o;s++,a++){const l=[],u=n[a%e];for(let f=0;f<u.childCount;f++){let p=u.child(f);s+p.attrs.rowspan>o&&(p=p.type.create({...p.attrs,rowspan:Math.max(1,o-p.attrs.rowspan)},p.content)),l.push(p)}i.push(Te.from(l))}n=i,e=o}return{width:t,height:e,rows:n}}function MQ(t,e,n,r,o,i,s){const a=t.doc.type.schema,l=Un(a);let u,f;if(o>e.width)for(let p=0,g=0;p<e.height;p++){const m=n.child(p);g+=m.nodeSize;const y=[];let b;m.lastChild==null||m.lastChild.type==l.cell?b=u||(u=l.cell.createAndFill()):b=f||(f=l.header_cell.createAndFill());for(let S=e.width;S<o;S++)y.push(b);t.insert(t.mapping.slice(s).map(g-1+r),y)}if(i>e.height){const p=[];for(let y=0,b=(e.height-1)*e.width;y<Math.max(e.width,o);y++){const S=y>=e.width?!1:n.nodeAt(e.map[b+y]).type==l.header_cell;p.push(S?f||(f=l.header_cell.createAndFill()):u||(u=l.cell.createAndFill()))}const g=l.row.create(null,Te.from(p)),m=[];for(let y=e.height;y<i;y++)m.push(g);t.insert(t.mapping.slice(s).map(r+n.nodeSize-2),m)}return!!(u||f)}function jI(t,e,n,r,o,i,s,a){if(s==0||s==e.height)return!1;let l=!1;for(let u=o;u<i;u++){const f=s*e.width+u,p=e.map[f];if(e.map[f-e.width]==p){l=!0;const g=n.nodeAt(p),{top:m,left:y}=e.findCell(p);t.setNodeMarkup(t.mapping.slice(a).map(p+r),null,{...g.attrs,rowspan:s-m}),t.insert(t.mapping.slice(a).map(e.positionAt(s,y,n)),g.type.createAndFill({...g.attrs,rowspan:m+g.attrs.rowspan-s})),u+=g.attrs.colspan-1}}return l}function WI(t,e,n,r,o,i,s,a){if(s==0||s==e.width)return!1;let l=!1;for(let u=o;u<i;u++){const f=u*e.width+s,p=e.map[f];if(e.map[f-1]==p){l=!0;const g=n.nodeAt(p),m=e.colCount(p),y=t.mapping.slice(a).map(p+r);t.setNodeMarkup(y,null,Vs(g.attrs,s-m,g.attrs.colspan-(s-m))),t.insert(y+g.nodeSize,g.type.createAndFill(Vs(g.attrs,0,s-m))),u+=g.attrs.rowspan-1}}return l}function qI(t,e,n,r,o){let i=n?t.doc.nodeAt(n-1):t.doc;if(!i)throw new Error("No table found");let s=an.get(i);const{top:a,left:l}=r,u=l+o.width,f=a+o.height,p=t.tr;let g=0;function m(){if(i=n?p.doc.nodeAt(n-1):p.doc,!i)throw new Error("No table found");s=an.get(i),g=p.mapping.maps.length}MQ(p,s,i,n,u,f,g)&&m(),jI(p,s,i,n,l,u,a,g)&&m(),jI(p,s,i,n,l,u,f,g)&&m(),WI(p,s,i,n,a,f,l,g)&&m(),WI(p,s,i,n,a,f,u,g)&&m();for(let y=a;y<f;y++){const b=s.positionAt(y,l,i),S=s.positionAt(y,u,i);p.replace(p.mapping.slice(g).map(b+n),p.mapping.slice(g).map(S+n),new Ie(o.rows[y-a],0,0))}m(),p.setSelection(new Vt(p.doc.resolve(n+s.positionAt(a,l,i)),p.doc.resolve(n+s.positionAt(f-1,u-1,i)))),e(p)}var OQ=Km({ArrowLeft:Hf("horiz",-1),ArrowRight:Hf("horiz",1),ArrowUp:Hf("vert",-1),ArrowDown:Hf("vert",1),"Shift-ArrowLeft":jf("horiz",-1),"Shift-ArrowRight":jf("horiz",1),"Shift-ArrowUp":jf("vert",-1),"Shift-ArrowDown":jf("vert",1),Backspace:zf,"Mod-Backspace":zf,Delete:zf,"Mod-Delete":zf});function Vf(t,e,n){return n.eq(t.selection)?!1:(e&&e(t.tr.setSelection(n).scrollIntoView()),!0)}function Hf(t,e){return(n,r,o)=>{if(!o)return!1;const i=n.selection;if(i instanceof Vt)return Vf(n,r,Qe.near(i.$headCell,e));if(t!="horiz"&&!i.empty)return!1;const s=UI(o,t,e);if(s==null)return!1;if(t=="horiz")return Vf(n,r,Qe.near(n.doc.resolve(i.head+e),e));{const a=n.doc.resolve(s),l=DI(a,t,e);let u;return l?u=Qe.near(l,1):e<0?u=Qe.near(n.doc.resolve(a.before(-1)),-1):u=Qe.near(n.doc.resolve(a.after(-1)),1),Vf(n,r,u)}}}function jf(t,e){return(n,r,o)=>{if(!o)return!1;const i=n.selection;let s;if(i instanceof Vt)s=i;else{const l=UI(o,t,e);if(l==null)return!1;s=new Vt(n.doc.resolve(l))}const a=DI(s.$headCell,t,e);return a?Vf(n,r,new Vt(s.$anchorCell,a)):!1}}function AQ(t,e){const n=t.state.doc,r=Xa(n.resolve(e));return r?(t.dispatch(t.state.tr.setSelection(new Vt(r))),!0):!1}function IQ(t,e,n){if(!uo(t.state))return!1;let r=TQ(n);const o=t.state.selection;if(o instanceof Vt){r||(r={width:1,height:1,rows:[Te.from(Vv(Un(t.state.schema).cell,n))]});const i=o.$anchorCell.node(-1),s=o.$anchorCell.start(-1),a=an.get(i).rectBetween(o.$anchorCell.pos-s,o.$headCell.pos-s);return r=EQ(r,a.right-a.left,a.bottom-a.top),qI(t.state,t.dispatch,s,a,r),!0}else if(r){const i=Rf(t.state),s=i.start(-1);return qI(t.state,t.dispatch,s,an.get(i.node(-1)).findCell(i.pos-s),r),!0}else return!1}function DQ(t,e){var n;if(e.ctrlKey||e.metaKey)return;const r=KI(t,e.target);let o;if(e.shiftKey&&t.state.selection instanceof Vt)i(t.state.selection.$anchorCell,e),e.preventDefault();else if(e.shiftKey&&r&&(o=Xa(t.state.selection.$anchor))!=null&&((n=Hv(t,e))==null?void 0:n.pos)!=o.pos)i(o,e),e.preventDefault();else if(!r)return;function i(l,u){let f=Hv(t,u);const p=qi.getState(t.state)==null;if(!f||!zv(l,f))if(p)f=l;else return;const g=new Vt(l,f);if(p||!t.state.selection.eq(g)){const m=t.state.tr.setSelection(g);p&&m.setMeta(qi,l.pos),t.dispatch(m)}}function s(){t.root.removeEventListener("mouseup",s),t.root.removeEventListener("dragstart",s),t.root.removeEventListener("mousemove",a),qi.getState(t.state)!=null&&t.dispatch(t.state.tr.setMeta(qi,-1))}function a(l){const u=l,f=qi.getState(t.state);let p;if(f!=null)p=t.state.doc.resolve(f);else if(KI(t,u.target)!=r&&(p=Hv(t,e),!p))return s();p&&i(p,u)}t.root.addEventListener("mouseup",s),t.root.addEventListener("dragstart",s),t.root.addEventListener("mousemove",a)}function UI(t,e,n){if(!(t.state.selection instanceof Ze))return null;const{$head:r}=t.state.selection;for(let o=r.depth-1;o>=0;o--){const i=r.node(o);if((n<0?r.index(o):r.indexAfter(o))!=(n<0?0:i.childCount))return null;if(i.type.spec.tableRole=="cell"||i.type.spec.tableRole=="header_cell"){const a=r.before(o),l=e=="vert"?n>0?"down":"up":n>0?"right":"left";return t.endOfTextblock(l)?a:null}}return null}function KI(t,e){for(;e&&e!=t.dom;e=e.parentNode)if(e.nodeName=="TD"||e.nodeName=="TH")return e;return null}function Hv(t,e){const n=t.posAtCoords({left:e.clientX,top:e.clientY});return n&&n?Xa(t.state.doc.resolve(n.pos)):null}var PQ=class{constructor(e,n){this.node=e,this.defaultCellMinWidth=n,this.dom=document.createElement("div"),this.dom.className="tableWrapper",this.table=this.dom.appendChild(document.createElement("table")),this.table.style.setProperty("--default-cell-min-width",`${n}px`),this.colgroup=this.table.appendChild(document.createElement("colgroup")),jv(e,this.colgroup,this.table,n),this.contentDOM=this.table.appendChild(document.createElement("tbody"))}update(e){return e.type!=this.node.type?!1:(this.node=e,jv(e,this.colgroup,this.table,this.defaultCellMinWidth),!0)}ignoreMutation(e){return e.type=="attributes"&&(e.target==this.table||this.colgroup.contains(e.target))}};function jv(t,e,n,r,o,i){var s;let a=0,l=!0,u=e.firstChild;const f=t.firstChild;if(f){for(let p=0,g=0;p<f.childCount;p++){const{colspan:m,colwidth:y}=f.child(p).attrs;for(let b=0;b<m;b++,g++){const S=o==g?i:y&&y[b],C=S?S+"px":"";if(a+=S||r,S||(l=!1),u)u.style.width!=C&&(u.style.width=C),u=u.nextSibling;else{const T=document.createElement("col");T.style.width=C,e.appendChild(T)}}}for(;u;){const p=u.nextSibling;(s=u.parentNode)==null||s.removeChild(u),u=p}l?(n.style.width=a+"px",n.style.minWidth=""):(n.style.width="",n.style.minWidth=a+"px")}}var _r=new bn("tableColumnResizing");function YI({handleWidth:t=5,cellMinWidth:e=25,defaultCellMinWidth:n=100,View:r=PQ,lastColumnResizable:o=!0}={}){const i=new en({key:_r,state:{init(s,a){var l,u;const f=(u=(l=i.spec)==null?void 0:l.props)==null?void 0:u.nodeViews,p=Un(a.schema).table.name;return r&&f&&(f[p]=(g,m)=>new r(g,n,m)),new NQ(-1,!1)},apply(s,a){return a.apply(s)}},props:{attributes:s=>{const a=_r.getState(s);return a&&a.activeHandle>-1?{class:"resize-cursor"}:{}},handleDOMEvents:{mousemove:(s,a)=>{LQ(s,a,t,o)},mouseleave:s=>{FQ(s)},mousedown:(s,a)=>{$Q(s,a,e,n)}},decorations:s=>{const a=_r.getState(s);if(a&&a.activeHandle>-1)return HQ(s,a.activeHandle)},nodeViews:{}}});return i}var NQ=class Ch{constructor(e,n){this.activeHandle=e,this.dragging=n}apply(e){const n=this,r=e.getMeta(_r);if(r&&r.setHandle!=null)return new Ch(r.setHandle,!1);if(r&&r.setDragging!==void 0)return new Ch(n.activeHandle,r.setDragging);if(n.activeHandle>-1&&e.docChanged){let o=e.mapping.map(n.activeHandle,-1);return Rv(e.doc.resolve(o))||(o=-1),new Ch(o,n.dragging)}return n}};function LQ(t,e,n,r){if(!t.editable)return;const o=_r.getState(t.state);if(o&&!o.dragging){const i=RQ(e.target);let s=-1;if(i){const{left:a,right:l}=i.getBoundingClientRect();e.clientX-a<=n?s=GI(t,e,"left",n):l-e.clientX<=n&&(s=GI(t,e,"right",n))}if(s!=o.activeHandle){if(!r&&s!==-1){const a=t.state.doc.resolve(s),l=a.node(-1),u=an.get(l),f=a.start(-1);if(u.colCount(a.pos-f)+a.nodeAfter.attrs.colspan-1==u.width-1)return}ZI(t,s)}}}function FQ(t){if(!t.editable)return;const e=_r.getState(t.state);e&&e.activeHandle>-1&&!e.dragging&&ZI(t,-1)}function $Q(t,e,n,r){var o;if(!t.editable)return!1;const i=(o=t.dom.ownerDocument.defaultView)!=null?o:window,s=_r.getState(t.state);if(!s||s.activeHandle==-1||s.dragging)return!1;const a=t.state.doc.nodeAt(s.activeHandle),l=BQ(t,s.activeHandle,a.attrs);t.dispatch(t.state.tr.setMeta(_r,{setDragging:{startX:e.clientX,startWidth:l}}));function u(p){i.removeEventListener("mouseup",u),i.removeEventListener("mousemove",f);const g=_r.getState(t.state);g!=null&&g.dragging&&(zQ(t,g.activeHandle,JI(g.dragging,p,n)),t.dispatch(t.state.tr.setMeta(_r,{setDragging:null})))}function f(p){if(!p.which)return u(p);const g=_r.getState(t.state);if(g&&g.dragging){const m=JI(g.dragging,p,n);XI(t,g.activeHandle,m,r)}}return XI(t,s.activeHandle,l,r),i.addEventListener("mouseup",u),i.addEventListener("mousemove",f),e.preventDefault(),!0}function BQ(t,e,{colspan:n,colwidth:r}){const o=r&&r[r.length-1];if(o)return o;const i=t.domAtPos(e);let a=i.node.childNodes[i.offset].offsetWidth,l=n;if(r)for(let u=0;u<n;u++)r[u]&&(a-=r[u],l--);return a/l}function RQ(t){for(;t&&t.nodeName!="TD"&&t.nodeName!="TH";)t=t.classList&&t.classList.contains("ProseMirror")?null:t.parentNode;return t}function GI(t,e,n,r){const o=n=="right"?-r:r,i=t.posAtCoords({left:e.clientX+o,top:e.clientY});if(!i)return-1;const{pos:s}=i,a=Xa(t.state.doc.resolve(s));if(!a)return-1;if(n=="right")return a.pos;const l=an.get(a.node(-1)),u=a.start(-1),f=l.map.indexOf(a.pos-u);return f%l.width==0?-1:u+l.map[f-1]}function JI(t,e,n){const r=e.clientX-t.startX;return Math.max(n,t.startWidth+r)}function ZI(t,e){t.dispatch(t.state.tr.setMeta(_r,{setHandle:e}))}function zQ(t,e,n){const r=t.state.doc.resolve(e),o=r.node(-1),i=an.get(o),s=r.start(-1),a=i.colCount(r.pos-s)+r.nodeAfter.attrs.colspan-1,l=t.state.tr;for(let u=0;u<i.height;u++){const f=u*i.width+a;if(u&&i.map[f]==i.map[f-i.width])continue;const p=i.map[f],g=o.nodeAt(p).attrs,m=g.colspan==1?0:a-i.colCount(p);if(g.colwidth&&g.colwidth[m]==n)continue;const y=g.colwidth?g.colwidth.slice():VQ(g.colspan);y[m]=n,l.setNodeMarkup(s+p,null,{...g,colwidth:y})}l.docChanged&&t.dispatch(l)}function XI(t,e,n,r){const o=t.state.doc.resolve(e),i=o.node(-1),s=o.start(-1),a=an.get(i).colCount(o.pos-s)+o.nodeAfter.attrs.colspan-1;let l=t.domAtPos(o.start(-1)).node;for(;l&&l.nodeName!="TABLE";)l=l.parentNode;l&&jv(i,l.firstChild,l,r,a,n)}function VQ(t){return Array(t).fill(0)}function HQ(t,e){var n;const r=[],o=t.doc.resolve(e),i=o.node(-1);if(!i)return Zt.empty;const s=an.get(i),a=o.start(-1),l=s.colCount(o.pos-a)+o.nodeAfter.attrs.colspan-1;for(let u=0;u<s.height;u++){const f=l+u*s.width;if((l==s.width-1||s.map[f]!=s.map[f+1])&&(u==0||s.map[f]!=s.map[f-s.width])){const p=s.map[f],g=a+p+i.nodeAt(p).nodeSize-1,m=document.createElement("div");m.className="column-resize-handle",(n=_r.getState(t))!=null&&n.dragging&&r.push(Ln.node(a+p,a+p+i.nodeAt(p).nodeSize,{class:"column-resize-dragging"})),r.push(Ln.widget(g,m))}}return Zt.create(t.doc,r)}function QI({allowTableNodeSelection:t=!1}={}){return new en({key:qi,state:{init(){return null},apply(e,n){const r=e.getMeta(qi);if(r!=null)return r==-1?null:r;if(n==null||!e.docChanged)return n;const{deleted:o,pos:i}=e.mapping.mapResult(n);return o?null:i}},props:{decorations:rQ,handleDOMEvents:{mousedown:DQ},createSelectionBetween(e){return qi.getState(e.state)!=null?e.state.selection:null},handleTripleClick:AQ,handleKeyDown:OQ,handlePaste:IQ},appendTransaction(e,n,r){return sQ(r,LI(r,n),t)}})}function Wv(t,e){return e?["width",`${Math.max(e,t)}px`]:["min-width",`${t}px`]}function eD(t,e,n,r,o,i){var s;let a=0,l=!0,u=e.firstChild;const f=t.firstChild;if(f!==null)for(let p=0,g=0;p<f.childCount;p+=1){const{colspan:m,colwidth:y}=f.child(p).attrs;for(let b=0;b<m;b+=1,g+=1){const S=o===g?i:y&&y[b],C=S?`${S}px`:"";if(a+=S||r,S||(l=!1),u){if(u.style.width!==C){const[T,_]=Wv(r,S);u.style.setProperty(T,_)}u=u.nextSibling}else{const T=document.createElement("col"),[_,w]=Wv(r,S);T.style.setProperty(_,w),e.appendChild(T)}}}for(;u;){const p=u.nextSibling;(s=u.parentNode)===null||s===void 0||s.removeChild(u),u=p}l?(n.style.width=`${a}px`,n.style.minWidth=""):(n.style.width="",n.style.minWidth=`${a}px`)}class jQ{constructor(e,n){this.node=e,this.cellMinWidth=n,this.dom=document.createElement("div"),this.dom.className="tableWrapper",this.table=this.dom.appendChild(document.createElement("table")),this.colgroup=this.table.appendChild(document.createElement("colgroup")),eD(e,this.colgroup,this.table,n),this.contentDOM=this.table.appendChild(document.createElement("tbody"))}update(e){return e.type!==this.node.type?!1:(this.node=e,eD(e,this.colgroup,this.table,this.cellMinWidth),!0)}ignoreMutation(e){return e.type==="attributes"&&(e.target===this.table||this.colgroup.contains(e.target))}}function WQ(t,e,n,r){let o=0,i=!0;const s=[],a=t.firstChild;if(!a)return{};for(let p=0,g=0;p<a.childCount;p+=1){const{colspan:m,colwidth:y}=a.child(p).attrs;for(let b=0;b<m;b+=1,g+=1){const S=n===g?r:y&&y[b];o+=S||e,S||(i=!1);const[C,T]=Wv(e,S);s.push(["col",{style:`${C}: ${T}`}])}}const l=i?`${o}px`:"",u=i?"":`${o}px`;return{colgroup:["colgroup",{},...s],tableWidth:l,tableMinWidth:u}}function tD(t,e){return t.createAndFill()}function qQ(t){if(t.cached.tableNodeTypes)return t.cached.tableNodeTypes;const e={};return Object.keys(t.nodes).forEach(n=>{const r=t.nodes[n];r.spec.tableRole&&(e[r.spec.tableRole]=r)}),t.cached.tableNodeTypes=e,e}function UQ(t,e,n,r,o){const i=qQ(t),s=[],a=[];for(let u=0;u<n;u+=1){const f=tD(i.cell);if(f&&a.push(f),r){const p=tD(i.header_cell);p&&s.push(p)}}const l=[];for(let u=0;u<e;u+=1)l.push(i.row.createChecked(null,r&&u===0?s:a));return i.table.createChecked(null,l)}function KQ(t){return t instanceof Vt}const Wf=({editor:t})=>{const{selection:e}=t.state;if(!KQ(e))return!1;let n=0;const r=ty(e.ranges[0].$from,i=>i.type.name==="table");return r==null||r.node.descendants(i=>{if(i.type.name==="table")return!1;["tableCell","tableHeader"].includes(i.type.name)&&(n+=1)}),n===e.ranges.length?(t.commands.deleteTable(),!0):!1},YQ=tn.create({name:"table",addOptions(){return{HTMLAttributes:{},resizable:!1,handleWidth:5,cellMinWidth:25,View:jQ,lastColumnResizable:!0,allowTableNodeSelection:!1}},content:"tableRow+",tableRole:"table",isolating:!0,group:"block",parseHTML(){return[{tag:"table"}]},renderHTML({node:t,HTMLAttributes:e}){const{colgroup:n,tableWidth:r,tableMinWidth:o}=WQ(t,this.options.cellMinWidth);return["table",yt(this.options.HTMLAttributes,e,{style:r?`width: ${r}`:`min-width: ${o}`}),n,["tbody",0]]},addCommands(){return{insertTable:({rows:t=3,cols:e=3,withHeaderRow:n=!0}={})=>({tr:r,dispatch:o,editor:i})=>{const s=UQ(i.schema,t,e,n);if(o){const a=r.selection.from+1;r.replaceSelectionWith(s).scrollIntoView().setSelection(Ze.near(r.doc.resolve(a)))}return!0},addColumnBefore:()=>({state:t,dispatch:e})=>cQ(t,e),addColumnAfter:()=>({state:t,dispatch:e})=>uQ(t,e),deleteColumn:()=>({state:t,dispatch:e})=>fQ(t,e),addRowBefore:()=>({state:t,dispatch:e})=>hQ(t,e),addRowAfter:()=>({state:t,dispatch:e})=>gQ(t,e),deleteRow:()=>({state:t,dispatch:e})=>yQ(t,e),deleteTable:()=>({state:t,dispatch:e})=>_Q(t,e),mergeCells:()=>({state:t,dispatch:e})=>RI(t,e),splitCell:()=>({state:t,dispatch:e})=>zI(t,e),toggleHeaderColumn:()=>({state:t,dispatch:e})=>Kc("column")(t,e),toggleHeaderRow:()=>({state:t,dispatch:e})=>Kc("row")(t,e),toggleHeaderCell:()=>({state:t,dispatch:e})=>CQ(t,e),mergeOrSplit:()=>({state:t,dispatch:e})=>RI(t,e)?!0:zI(t,e),setCellAttribute:(t,e)=>({state:n,dispatch:r})=>xQ(t,e)(n,r),goToNextCell:()=>({state:t,dispatch:e})=>HI(1)(t,e),goToPreviousCell:()=>({state:t,dispatch:e})=>HI(-1)(t,e),fixTables:()=>({state:t,dispatch:e})=>(e&&LI(t),!0),setCellSelection:t=>({tr:e,dispatch:n})=>{if(n){const r=Vt.create(e.doc,t.anchorCell,t.headCell);e.setSelection(r)}return!0}}},addKeyboardShortcuts(){return{Tab:()=>this.editor.commands.goToNextCell()?!0:this.editor.can().addRowAfter()?this.editor.chain().addRowAfter().goToNextCell().run():!1,"Shift-Tab":()=>this.editor.commands.goToPreviousCell(),Backspace:Wf,"Mod-Backspace":Wf,Delete:Wf,"Mod-Delete":Wf}},addProseMirrorPlugins(){return[...this.options.resizable&&this.editor.isEditable?[YI({handleWidth:this.options.handleWidth,cellMinWidth:this.options.cellMinWidth,defaultCellMinWidth:this.options.cellMinWidth,View:this.options.View,lastColumnResizable:this.options.lastColumnResizable})]:[],QI({allowTableNodeSelection:this.options.allowTableNodeSelection})]},extendNodeSchema(t){const e={name:t.name,options:t.options,storage:t.storage};return{tableRole:at(He(t,"tableRole",e))}}}).extend({addProseMirrorPlugins(){return[...this.options.resizable?[YI({handleWidth:this.options.handleWidth,cellMinWidth:this.options.cellMinWidth,View:this.options.View,lastColumnResizable:this.options.lastColumnResizable})]:[],QI({allowTableNodeSelection:this.options.allowTableNodeSelection})]}}),GQ=t=>{const{onUploadFiles:e}=t,n=F.useTheme();return v.jsxs(Nf,{children:[v.jsx(SI,{options:[{label:"Monospace",value:"monospace"},{label:"Serif",value:"serif"}]}),v.jsx(Mn,{}),v.jsx(kI,{}),v.jsx(Mn,{}),v.jsx(wI,{}),v.jsx(Mn,{}),v.jsx(sX,{}),v.jsx(vX,{}),v.jsx(MX,{}),v.jsx(wX,{}),v.jsx(_X,{}),v.jsx(TX,{}),v.jsx(Mn,{}),v.jsx(EX,{defaultTextColor:n.palette.text.primary,swatchColors:[{value:"#000000",label:"Black"},{value:"#ffffff",label:"White"},{value:"#888888",label:"Grey"},{value:"#ff0000",label:"Red"},{value:"#ff9900",label:"Orange"},{value:"#ffff00",label:"Yellow"},{value:"#00d000",label:"Green"},{value:"#0000ff",label:"Blue"}]}),v.jsx(fX,{swatchColors:[{value:"#595959",label:"Dark grey"},{value:"#dddddd",label:"Light grey"},{value:"#ffa6a6",label:"Light red"},{value:"#ffd699",label:"Light orange"},{value:"#ffff00",label:"Yellow"},{value:"#99cc99",label:"Light green"},{value:"#90c6ff",label:"Light blue"},{value:"#8085e9",label:"Light purple"}]}),v.jsx(Mn,{}),v.jsx(dX,{}),v.jsx(Mn,{}),v.jsx(EI,{}),v.jsx(Mn,{}),v.jsx(xX,{}),v.jsx(aX,{}),v.jsx(kX,{}),NZ()&&v.jsxs(v.Fragment,{children:[v.jsx(bX,{}),v.jsx(AX,{})]}),v.jsx(Mn,{}),v.jsx(iX,{}),v.jsx(Mn,{}),v.jsx(lX,{}),v.jsx(cX,{}),v.jsx(Mn,{}),e&&v.jsx(yX,{onUploadFiles:e}),v.jsx(Mn,{}),v.jsx(pX,{}),v.jsx(oX,{}),v.jsx(Mn,{}),v.jsx(CX,{}),v.jsx(Mn,{}),v.jsx(OX,{}),v.jsx(SX,{})]})},JQ=/^\s*>\s$/,nD=tn.create({name:"blockquote",addOptions(){return{HTMLAttributes:{}}},content:"block+",group:"block",defining:!0,parseHTML(){return[{tag:"blockquote"}]},renderHTML({HTMLAttributes:t}){return["blockquote",yt(this.options.HTMLAttributes,t),0]},addCommands(){return{setBlockquote:()=>({commands:t})=>t.wrapIn(this.name),toggleBlockquote:()=>({commands:t})=>t.toggleWrap(this.name),unsetBlockquote:()=>({commands:t})=>t.lift(this.name)}},addKeyboardShortcuts(){return{"Mod-Shift-b":()=>this.editor.commands.toggleBlockquote()}},addInputRules(){return[Wa({find:JQ,type:this.type})]}}),ZQ=/(?:^|\s)(\*\*(?!\s+\*\*)((?:[^*]+))\*\*(?!\s+\*\*))$/,XQ=/(?:^|\s)(\*\*(?!\s+\*\*)((?:[^*]+))\*\*(?!\s+\*\*))/g,QQ=/(?:^|\s)(__(?!\s+__)((?:[^_]+))__(?!\s+__))$/,eee=/(?:^|\s)(__(?!\s+__)((?:[^_]+))__(?!\s+__))/g,rD=ur.create({name:"bold",addOptions(){return{HTMLAttributes:{}}},parseHTML(){return[{tag:"strong"},{tag:"b",getAttrs:t=>t.style.fontWeight!=="normal"&&null},{style:"font-weight=400",clearMark:t=>t.type.name===this.name},{style:"font-weight",getAttrs:t=>/^(bold(er)?|[5-9]\d{2,})$/.test(t)&&null}]},renderHTML({HTMLAttributes:t}){return["strong",yt(this.options.HTMLAttributes,t),0]},addCommands(){return{setBold:()=>({commands:t})=>t.setMark(this.name),toggleBold:()=>({commands:t})=>t.toggleMark(this.name),unsetBold:()=>({commands:t})=>t.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-b":()=>this.editor.commands.toggleBold(),"Mod-B":()=>this.editor.commands.toggleBold()}},addInputRules(){return[Ls({find:ZQ,type:this.type}),Ls({find:QQ,type:this.type})]},addPasteRules(){return[Vi({find:XQ,type:this.type}),Vi({find:eee,type:this.type})]}}),tee="listItem",oD="textStyle",iD=/^\s*([-+*])\s$/,sD=tn.create({name:"bulletList",addOptions(){return{itemTypeName:"listItem",HTMLAttributes:{},keepMarks:!1,keepAttributes:!1}},group:"block list",content(){return`${this.options.itemTypeName}+`},parseHTML(){return[{tag:"ul"}]},renderHTML({HTMLAttributes:t}){return["ul",yt(this.options.HTMLAttributes,t),0]},addCommands(){return{toggleBulletList:()=>({commands:t,chain:e})=>this.options.keepAttributes?e().toggleList(this.name,this.options.itemTypeName,this.options.keepMarks).updateAttributes(tee,this.editor.getAttributes(oD)).run():t.toggleList(this.name,this.options.itemTypeName,this.options.keepMarks)}},addKeyboardShortcuts(){return{"Mod-Shift-8":()=>this.editor.commands.toggleBulletList()}},addInputRules(){let t=Wa({find:iD,type:this.type});return(this.options.keepMarks||this.options.keepAttributes)&&(t=Wa({find:iD,type:this.type,keepMarks:this.options.keepMarks,keepAttributes:this.options.keepAttributes,getAttributes:()=>this.editor.getAttributes(oD),editor:this.editor})),[t]}}),nee=/(^|[^`])`([^`]+)`(?!`)/,ree=/(^|[^`])`([^`]+)`(?!`)/g,aD=ur.create({name:"code",addOptions(){return{HTMLAttributes:{}}},excludes:"_",code:!0,exitable:!0,parseHTML(){return[{tag:"code"}]},renderHTML({HTMLAttributes:t}){return["code",yt(this.options.HTMLAttributes,t),0]},addCommands(){return{setCode:()=>({commands:t})=>t.setMark(this.name),toggleCode:()=>({commands:t})=>t.toggleMark(this.name),unsetCode:()=>({commands:t})=>t.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-e":()=>this.editor.commands.toggleCode()}},addInputRules(){return[Ls({find:nee,type:this.type})]},addPasteRules(){return[Vi({find:ree,type:this.type})]}}),oee=/^```([a-z]+)?[\s\n]$/,iee=/^~~~([a-z]+)?[\s\n]$/,lD=tn.create({name:"codeBlock",addOptions(){return{languageClassPrefix:"language-",exitOnTripleEnter:!0,exitOnArrowDown:!0,defaultLanguage:null,HTMLAttributes:{}}},content:"text*",marks:"",group:"block",code:!0,defining:!0,addAttributes(){return{language:{default:this.options.defaultLanguage,parseHTML:t=>{var e;const{languageClassPrefix:n}=this.options,i=[...((e=t.firstElementChild)===null||e===void 0?void 0:e.classList)||[]].filter(s=>s.startsWith(n)).map(s=>s.replace(n,""))[0];return i||null},rendered:!1}}},parseHTML(){return[{tag:"pre",preserveWhitespace:"full"}]},renderHTML({node:t,HTMLAttributes:e}){return["pre",yt(this.options.HTMLAttributes,e),["code",{class:t.attrs.language?this.options.languageClassPrefix+t.attrs.language:null},0]]},addCommands(){return{setCodeBlock:t=>({commands:e})=>e.setNode(this.name,t),toggleCodeBlock:t=>({commands:e})=>e.toggleNode(this.name,"paragraph",t)}},addKeyboardShortcuts(){return{"Mod-Alt-c":()=>this.editor.commands.toggleCodeBlock(),Backspace:()=>{const{empty:t,$anchor:e}=this.editor.state.selection,n=e.pos===1;return!t||e.parent.type.name!==this.name?!1:n||!e.parent.textContent.length?this.editor.commands.clearNodes():!1},Enter:({editor:t})=>{if(!this.options.exitOnTripleEnter)return!1;const{state:e}=t,{selection:n}=e,{$from:r,empty:o}=n;if(!o||r.parent.type!==this.type)return!1;const i=r.parentOffset===r.parent.nodeSize-2,s=r.parent.textContent.endsWith(`
|
|
393
393
|
|
|
394
394
|
`);return!i||!s?!1:t.chain().command(({tr:a})=>(a.delete(r.pos-2,r.pos),!0)).exitCode().run()},ArrowDown:({editor:t})=>{if(!this.options.exitOnArrowDown)return!1;const{state:e}=t,{selection:n,doc:r}=e,{$from:o,empty:i}=n;if(!i||o.parent.type!==this.type||!(o.parentOffset===o.parent.nodeSize-2))return!1;const a=o.after();return a===void 0?!1:r.nodeAt(a)?t.commands.command(({tr:u})=>(u.setSelection(Qe.near(r.resolve(a))),!0)):t.commands.exitCode()}}},addInputRules(){return[ly({find:oee,type:this.type,getAttributes:t=>({language:t[1]})}),ly({find:iee,type:this.type,getAttributes:t=>({language:t[1]})})]},addProseMirrorPlugins(){return[new en({key:new bn("codeBlockVSCodeHandler"),props:{handlePaste:(t,e)=>{if(!e.clipboardData||this.editor.isActive(this.type.name))return!1;const n=e.clipboardData.getData("text/plain"),r=e.clipboardData.getData("vscode-editor-data"),o=r?JSON.parse(r):void 0,i=o==null?void 0:o.mode;if(!n||!i)return!1;const{tr:s,schema:a}=t.state,l=a.text(n.replace(/\r\n?/g,`
|
|
395
395
|
`));return s.replaceSelectionWith(this.type.create({language:i},l)),s.selection.$from.parent.type!==this.type&&s.setSelection(Ze.near(s.doc.resolve(Math.max(0,s.selection.from-2)))),s.setMeta("paste",!0),t.dispatch(s),!0}}})]}}),see=t=>{if(!t.children.length)return;const e=t.querySelectorAll("span");e&&e.forEach(n=>{var r,o;const i=n.getAttribute("style"),s=(o=(r=n.parentElement)===null||r===void 0?void 0:r.closest("span"))===null||o===void 0?void 0:o.getAttribute("style");n.setAttribute("style",`${s};${i}`)})},aee=ur.create({name:"textStyle",priority:101,addOptions(){return{HTMLAttributes:{},mergeNestedSpanStyles:!1}},parseHTML(){return[{tag:"span",getAttrs:t=>t.hasAttribute("style")?(this.options.mergeNestedSpanStyles&&see(t),{}):!1}]},renderHTML({HTMLAttributes:t}){return["span",yt(this.options.HTMLAttributes,t),0]},addCommands(){return{removeEmptyTextStyle:()=>({tr:t})=>{const{selection:e}=t;return t.doc.nodesBetween(e.from,e.to,(n,r)=>{if(n.isTextblock)return!0;n.marks.filter(o=>o.type===this.type).some(o=>Object.values(o.attrs).some(i=>!!i))||t.removeMark(r,r+n.nodeSize,this.type)}),!0}}}}),lee=sn.create({name:"color",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{color:{default:null,parseHTML:t=>{var e;return(e=t.style.color)===null||e===void 0?void 0:e.replace(/['"]+/g,"")},renderHTML:t=>t.color?{style:`color: ${t.color}`}:{}}}}]},addCommands(){return{setColor:t=>({chain:e})=>e().setMark("textStyle",{color:t}).run(),unsetColor:()=>({chain:t})=>t().setMark("textStyle",{color:null}).removeEmptyTextStyle().run()}}}),cD=tn.create({name:"doc",topNode:!0,content:"block+"});function cee(t={}){return new en({view(e){return new uee(e,t)}})}class uee{constructor(e,n){var r;this.editorView=e,this.cursorPos=null,this.element=null,this.timeout=-1,this.width=(r=n.width)!==null&&r!==void 0?r:1,this.color=n.color===!1?void 0:n.color||"black",this.class=n.class,this.handlers=["dragover","dragend","drop","dragleave"].map(o=>{let i=s=>{this[o](s)};return e.dom.addEventListener(o,i),{name:o,handler:i}})}destroy(){this.handlers.forEach(({name:e,handler:n})=>this.editorView.dom.removeEventListener(e,n))}update(e,n){this.cursorPos!=null&&n.doc!=e.state.doc&&(this.cursorPos>e.state.doc.content.size?this.setCursor(null):this.updateOverlay())}setCursor(e){e!=this.cursorPos&&(this.cursorPos=e,e==null?(this.element.parentNode.removeChild(this.element),this.element=null):this.updateOverlay())}updateOverlay(){let e=this.editorView.state.doc.resolve(this.cursorPos),n=!e.parent.inlineContent,r;if(n){let a=e.nodeBefore,l=e.nodeAfter;if(a||l){let u=this.editorView.nodeDOM(this.cursorPos-(a?a.nodeSize:0));if(u){let f=u.getBoundingClientRect(),p=a?f.bottom:f.top;a&&l&&(p=(p+this.editorView.nodeDOM(this.cursorPos).getBoundingClientRect().top)/2),r={left:f.left,right:f.right,top:p-this.width/2,bottom:p+this.width/2}}}}if(!r){let a=this.editorView.coordsAtPos(this.cursorPos);r={left:a.left-this.width/2,right:a.left+this.width/2,top:a.top,bottom:a.bottom}}let o=this.editorView.dom.offsetParent;this.element||(this.element=o.appendChild(document.createElement("div")),this.class&&(this.element.className=this.class),this.element.style.cssText="position: absolute; z-index: 50; pointer-events: none;",this.color&&(this.element.style.backgroundColor=this.color)),this.element.classList.toggle("prosemirror-dropcursor-block",n),this.element.classList.toggle("prosemirror-dropcursor-inline",!n);let i,s;if(!o||o==document.body&&getComputedStyle(o).position=="static")i=-pageXOffset,s=-pageYOffset;else{let a=o.getBoundingClientRect();i=a.left-o.scrollLeft,s=a.top-o.scrollTop}this.element.style.left=r.left-i+"px",this.element.style.top=r.top-s+"px",this.element.style.width=r.right-r.left+"px",this.element.style.height=r.bottom-r.top+"px"}scheduleRemoval(e){clearTimeout(this.timeout),this.timeout=setTimeout(()=>this.setCursor(null),e)}dragover(e){if(!this.editorView.editable)return;let n=this.editorView.posAtCoords({left:e.clientX,top:e.clientY}),r=n&&n.inside>=0&&this.editorView.state.doc.nodeAt(n.inside),o=r&&r.type.spec.disableDropCursor,i=typeof o=="function"?o(this.editorView,n,e):o;if(n&&!i){let s=n.pos;if(this.editorView.dragging&&this.editorView.dragging.slice){let a=nk(this.editorView.state.doc,s,this.editorView.dragging.slice);a!=null&&(s=a)}this.setCursor(s),this.scheduleRemoval(5e3)}}dragend(){this.scheduleRemoval(20)}drop(){this.scheduleRemoval(20)}dragleave(e){(e.target==this.editorView.dom||!this.editorView.dom.contains(e.relatedTarget))&&this.setCursor(null)}}const uD=sn.create({name:"dropCursor",addOptions(){return{color:"currentColor",width:1,class:void 0}},addProseMirrorPlugins(){return[cee(this.options)]}}),dee=sn.create({name:"fontFamily",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{fontFamily:{default:null,parseHTML:t=>t.style.fontFamily,renderHTML:t=>t.fontFamily?{style:`font-family: ${t.fontFamily}`}:{}}}}]},addCommands(){return{setFontFamily:t=>({chain:e})=>e().setMark("textStyle",{fontFamily:t}).run(),unsetFontFamily:()=>({chain:t})=>t().setMark("textStyle",{fontFamily:null}).removeEmptyTextStyle().run()}}});class ln extends Qe{constructor(e){super(e,e)}map(e,n){let r=e.resolve(n.map(this.head));return ln.valid(r)?new ln(r):Qe.near(r)}content(){return Ie.empty}eq(e){return e instanceof ln&&e.head==this.head}toJSON(){return{type:"gapcursor",pos:this.head}}static fromJSON(e,n){if(typeof n.pos!="number")throw new RangeError("Invalid input for GapCursor.fromJSON");return new ln(e.resolve(n.pos))}getBookmark(){return new qv(this.anchor)}static valid(e){let n=e.parent;if(n.isTextblock||!fee(e)||!pee(e))return!1;let r=n.type.spec.allowGapCursor;if(r!=null)return r;let o=n.contentMatchAt(e.index()).defaultType;return o&&o.isTextblock}static findGapCursorFrom(e,n,r=!1){e:for(;;){if(!r&&ln.valid(e))return e;let o=e.pos,i=null;for(let s=e.depth;;s--){let a=e.node(s);if(n>0?e.indexAfter(s)<a.childCount:e.index(s)>0){i=a.child(n>0?e.indexAfter(s):e.index(s)-1);break}else if(s==0)return null;o+=n;let l=e.doc.resolve(o);if(ln.valid(l))return l}for(;;){let s=n>0?i.firstChild:i.lastChild;if(!s){if(i.isAtom&&!i.isText&&!Ye.isSelectable(i)){e=e.doc.resolve(o+i.nodeSize*n),r=!1;continue e}break}i=s,o+=n;let a=e.doc.resolve(o);if(ln.valid(a))return a}return null}}}ln.prototype.visible=!1,ln.findFrom=ln.findGapCursorFrom,Qe.jsonID("gapcursor",ln);class qv{constructor(e){this.pos=e}map(e){return new qv(e.map(this.pos))}resolve(e){let n=e.resolve(this.pos);return ln.valid(n)?new ln(n):Qe.near(n)}}function fee(t){for(let e=t.depth;e>=0;e--){let n=t.index(e),r=t.node(e);if(n==0){if(r.type.spec.isolating)return!0;continue}for(let o=r.child(n-1);;o=o.lastChild){if(o.childCount==0&&!o.inlineContent||o.isAtom||o.type.spec.isolating)return!0;if(o.inlineContent)return!1}}return!0}function pee(t){for(let e=t.depth;e>=0;e--){let n=t.indexAfter(e),r=t.node(e);if(n==r.childCount){if(r.type.spec.isolating)return!0;continue}for(let o=r.child(n);;o=o.firstChild){if(o.childCount==0&&!o.inlineContent||o.isAtom||o.type.spec.isolating)return!0;if(o.inlineContent)return!1}}return!0}function hee(){return new en({props:{decorations:bee,createSelectionBetween(t,e,n){return e.pos==n.pos&&ln.valid(n)?new ln(n):null},handleClick:mee,handleKeyDown:gee,handleDOMEvents:{beforeinput:yee}}})}const gee=Km({ArrowLeft:qf("horiz",-1),ArrowRight:qf("horiz",1),ArrowUp:qf("vert",-1),ArrowDown:qf("vert",1)});function qf(t,e){const n=t=="vert"?e>0?"down":"up":e>0?"right":"left";return function(r,o,i){let s=r.selection,a=e>0?s.$to:s.$from,l=s.empty;if(s instanceof Ze){if(!i.endOfTextblock(n)||a.depth==0)return!1;l=!1,a=r.doc.resolve(e>0?a.after():a.before())}let u=ln.findGapCursorFrom(a,e,l);return u?(o&&o(r.tr.setSelection(new ln(u))),!0):!1}}function mee(t,e,n){if(!t||!t.editable)return!1;let r=t.state.doc.resolve(e);if(!ln.valid(r))return!1;let o=t.posAtCoords({left:n.clientX,top:n.clientY});return o&&o.inside>-1&&Ye.isSelectable(t.state.doc.nodeAt(o.inside))?!1:(t.dispatch(t.state.tr.setSelection(new ln(r))),!0)}function yee(t,e){if(e.inputType!="insertCompositionText"||!(t.state.selection instanceof ln))return!1;let{$from:n}=t.state.selection,r=n.parent.contentMatchAt(n.index()).findWrapping(t.state.schema.nodes.text);if(!r)return!1;let o=Te.empty;for(let s=r.length-1;s>=0;s--)o=Te.from(r[s].createAndFill(null,o));let i=t.state.tr.replace(n.pos,n.pos,new Ie(o,0,0));return i.setSelection(Ze.near(i.doc.resolve(n.pos+1))),t.dispatch(i),!1}function bee(t){if(!(t.selection instanceof ln))return null;let e=document.createElement("div");return e.className="ProseMirror-gapcursor",Zt.create(t.doc,[Ln.widget(t.selection.head,e,{key:"gapcursor"})])}const dD=sn.create({name:"gapCursor",addProseMirrorPlugins(){return[hee()]},extendNodeSchema(t){var e;const n={name:t.name,options:t.options,storage:t.storage};return{allowGapCursor:(e=at(He(t,"allowGapCursor",n)))!==null&&e!==void 0?e:null}}}),fD=tn.create({name:"hardBreak",addOptions(){return{keepMarks:!0,HTMLAttributes:{}}},inline:!0,group:"inline",selectable:!1,linebreakReplacement:!0,parseHTML(){return[{tag:"br"}]},renderHTML({HTMLAttributes:t}){return["br",yt(this.options.HTMLAttributes,t)]},renderText(){return`
|
|
396
396
|
`},addCommands(){return{setHardBreak:()=>({commands:t,chain:e,state:n,editor:r})=>t.first([()=>t.exitCode(),()=>t.command(()=>{const{selection:o,storedMarks:i}=n;if(o.$from.parent.type.spec.isolating)return!1;const{keepMarks:s}=this.options,{splittableMarks:a}=r.extensionManager,l=i||o.$to.parentOffset&&o.$from.marks();return e().insertContent({type:this.name}).command(({tr:u,dispatch:f})=>{if(f&&l&&s){const p=l.filter(g=>a.includes(g.type.name));u.ensureMarks(p)}return!0}).run()})])}},addKeyboardShortcuts(){return{"Mod-Enter":()=>this.editor.commands.setHardBreak(),"Shift-Enter":()=>this.editor.commands.setHardBreak()}}}),vee=/(?:^|\s)(==(?!\s+==)((?:[^=]+))==(?!\s+==))$/,xee=/(?:^|\s)(==(?!\s+==)((?:[^=]+))==(?!\s+==))/g,See=ur.create({name:"highlight",addOptions(){return{multicolor:!1,HTMLAttributes:{}}},addAttributes(){return this.options.multicolor?{color:{default:null,parseHTML:t=>t.getAttribute("data-color")||t.style.backgroundColor,renderHTML:t=>t.color?{"data-color":t.color,style:`background-color: ${t.color}; color: inherit`}:{}}}:{}},parseHTML(){return[{tag:"mark"}]},renderHTML({HTMLAttributes:t}){return["mark",yt(this.options.HTMLAttributes,t),0]},addCommands(){return{setHighlight:t=>({commands:e})=>e.setMark(this.name,t),toggleHighlight:t=>({commands:e})=>e.toggleMark(this.name,t),unsetHighlight:()=>({commands:t})=>t.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-Shift-h":()=>this.editor.commands.toggleHighlight()}},addInputRules(){return[Ls({find:vee,type:this.type})]},addPasteRules(){return[Vi({find:xee,type:this.type})]}});var Uf=200,An=function(){};An.prototype.append=function(e){return e.length?(e=An.from(e),!this.length&&e||e.length<Uf&&this.leafAppend(e)||this.length<Uf&&e.leafPrepend(this)||this.appendInner(e)):this},An.prototype.prepend=function(e){return e.length?An.from(e).append(this):this},An.prototype.appendInner=function(e){return new Cee(this,e)},An.prototype.slice=function(e,n){return e===void 0&&(e=0),n===void 0&&(n=this.length),e>=n?An.empty:this.sliceInner(Math.max(0,e),Math.min(this.length,n))},An.prototype.get=function(e){if(!(e<0||e>=this.length))return this.getInner(e)},An.prototype.forEach=function(e,n,r){n===void 0&&(n=0),r===void 0&&(r=this.length),n<=r?this.forEachInner(e,n,r,0):this.forEachInvertedInner(e,n,r,0)},An.prototype.map=function(e,n,r){n===void 0&&(n=0),r===void 0&&(r=this.length);var o=[];return this.forEach(function(i,s){return o.push(e(i,s))},n,r),o},An.from=function(e){return e instanceof An?e:e&&e.length?new pD(e):An.empty};var pD=function(t){function e(r){t.call(this),this.values=r}e.__proto__=t,e.prototype=Object.create(t.prototype),e.prototype.constructor=e;var n={length:{configurable:!0},depth:{configurable:!0}};return e.prototype.flatten=function(){return this.values},e.prototype.sliceInner=function(o,i){return o==0&&i==this.length?this:new e(this.values.slice(o,i))},e.prototype.getInner=function(o){return this.values[o]},e.prototype.forEachInner=function(o,i,s,a){for(var l=i;l<s;l++)if(o(this.values[l],a+l)===!1)return!1},e.prototype.forEachInvertedInner=function(o,i,s,a){for(var l=i-1;l>=s;l--)if(o(this.values[l],a+l)===!1)return!1},e.prototype.leafAppend=function(o){if(this.length+o.length<=Uf)return new e(this.values.concat(o.flatten()))},e.prototype.leafPrepend=function(o){if(this.length+o.length<=Uf)return new e(o.flatten().concat(this.values))},n.length.get=function(){return this.values.length},n.depth.get=function(){return 0},Object.defineProperties(e.prototype,n),e}(An);An.empty=new pD([]);var Cee=function(t){function e(n,r){t.call(this),this.left=n,this.right=r,this.length=n.length+r.length,this.depth=Math.max(n.depth,r.depth)+1}return e.__proto__=t,e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.prototype.flatten=function(){return this.left.flatten().concat(this.right.flatten())},e.prototype.getInner=function(r){return r<this.left.length?this.left.get(r):this.right.get(r-this.left.length)},e.prototype.forEachInner=function(r,o,i,s){var a=this.left.length;if(o<a&&this.left.forEachInner(r,o,Math.min(i,a),s)===!1||i>a&&this.right.forEachInner(r,Math.max(o-a,0),Math.min(this.length,i)-a,s+a)===!1)return!1},e.prototype.forEachInvertedInner=function(r,o,i,s){var a=this.left.length;if(o>a&&this.right.forEachInvertedInner(r,o-a,Math.max(i,a)-a,s+a)===!1||i<a&&this.left.forEachInvertedInner(r,Math.min(o,a),i,s)===!1)return!1},e.prototype.sliceInner=function(r,o){if(r==0&&o==this.length)return this;var i=this.left.length;return o<=i?this.left.slice(r,o):r>=i?this.right.slice(r-i,o-i):this.left.slice(r,i).append(this.right.slice(0,o-i))},e.prototype.leafAppend=function(r){var o=this.right.leafAppend(r);if(o)return new e(this.left,o)},e.prototype.leafPrepend=function(r){var o=this.left.leafPrepend(r);if(o)return new e(o,this.right)},e.prototype.appendInner=function(r){return this.left.depth>=Math.max(this.right.depth,r.depth)+1?new e(this.left,new e(this.right,r)):new e(this,r)},e}(An);const wee=500;class fo{constructor(e,n){this.items=e,this.eventCount=n}popEvent(e,n){if(this.eventCount==0)return null;let r=this.items.length;for(;;r--)if(this.items.get(r-1).selection){--r;break}let o,i;n&&(o=this.remapping(r,this.items.length),i=o.maps.length);let s=e.tr,a,l,u=[],f=[];return this.items.forEach((p,g)=>{if(!p.step){o||(o=this.remapping(r,g+1),i=o.maps.length),i--,f.push(p);return}if(o){f.push(new Io(p.map));let m=p.step.map(o.slice(i)),y;m&&s.maybeStep(m).doc&&(y=s.mapping.maps[s.mapping.maps.length-1],u.push(new Io(y,void 0,void 0,u.length+f.length))),i--,y&&o.appendMap(y,i)}else s.maybeStep(p.step);if(p.selection)return a=o?p.selection.map(o.slice(i)):p.selection,l=new fo(this.items.slice(0,r).append(f.reverse().concat(u)),this.eventCount-1),!1},this.items.length,0),{remaining:l,transform:s,selection:a}}addTransform(e,n,r,o){let i=[],s=this.eventCount,a=this.items,l=!o&&a.length?a.get(a.length-1):null;for(let f=0;f<e.steps.length;f++){let p=e.steps[f].invert(e.docs[f]),g=new Io(e.mapping.maps[f],p,n),m;(m=l&&l.merge(g))&&(g=m,f?i.pop():a=a.slice(0,a.length-1)),i.push(g),n&&(s++,n=void 0),o||(l=g)}let u=s-r.depth;return u>Tee&&(a=_ee(a,u),s-=u),new fo(a.append(i),s)}remapping(e,n){let r=new yc;return this.items.forEach((o,i)=>{let s=o.mirrorOffset!=null&&i-o.mirrorOffset>=e?r.maps.length-o.mirrorOffset:void 0;r.appendMap(o.map,s)},e,n),r}addMaps(e){return this.eventCount==0?this:new fo(this.items.append(e.map(n=>new Io(n))),this.eventCount)}rebased(e,n){if(!this.eventCount)return this;let r=[],o=Math.max(0,this.items.length-n),i=e.mapping,s=e.steps.length,a=this.eventCount;this.items.forEach(g=>{g.selection&&a--},o);let l=n;this.items.forEach(g=>{let m=i.getMirror(--l);if(m==null)return;s=Math.min(s,m);let y=i.maps[m];if(g.step){let b=e.steps[m].invert(e.docs[m]),S=g.selection&&g.selection.map(i.slice(l+1,m));S&&a++,r.push(new Io(y,b,S))}else r.push(new Io(y))},o);let u=[];for(let g=n;g<s;g++)u.push(new Io(i.maps[g]));let f=this.items.slice(0,o).append(u).append(r),p=new fo(f,a);return p.emptyItemCount()>wee&&(p=p.compress(this.items.length-r.length)),p}emptyItemCount(){let e=0;return this.items.forEach(n=>{n.step||e++}),e}compress(e=this.items.length){let n=this.remapping(0,e),r=n.maps.length,o=[],i=0;return this.items.forEach((s,a)=>{if(a>=e)o.push(s),s.selection&&i++;else if(s.step){let l=s.step.map(n.slice(r)),u=l&&l.getMap();if(r--,u&&n.appendMap(u,r),l){let f=s.selection&&s.selection.map(n.slice(r));f&&i++;let p=new Io(u.invert(),l,f),g,m=o.length-1;(g=o.length&&o[m].merge(p))?o[m]=g:o.push(p)}}else s.map&&r--},this.items.length,0),new fo(An.from(o.reverse()),i)}}fo.empty=new fo(An.empty,0);function _ee(t,e){let n;return t.forEach((r,o)=>{if(r.selection&&e--==0)return n=o,!1}),t.slice(n)}class Io{constructor(e,n,r,o){this.map=e,this.step=n,this.selection=r,this.mirrorOffset=o}merge(e){if(this.step&&e.step&&!e.selection){let n=e.step.merge(this.step);if(n)return new Io(n.getMap().invert(),n,this.selection)}}}class Ui{constructor(e,n,r,o,i){this.done=e,this.undone=n,this.prevRanges=r,this.prevTime=o,this.prevComposition=i}}const Tee=20;function kee(t,e,n,r){let o=n.getMeta(Hs),i;if(o)return o.historyState;n.getMeta(Oee)&&(t=new Ui(t.done,t.undone,null,0,-1));let s=n.getMeta("appendedTransaction");if(n.steps.length==0)return t;if(s&&s.getMeta(Hs))return s.getMeta(Hs).redo?new Ui(t.done.addTransform(n,void 0,r,Kf(e)),t.undone,hD(n.mapping.maps),t.prevTime,t.prevComposition):new Ui(t.done,t.undone.addTransform(n,void 0,r,Kf(e)),null,t.prevTime,t.prevComposition);if(n.getMeta("addToHistory")!==!1&&!(s&&s.getMeta("addToHistory")===!1)){let a=n.getMeta("composition"),l=t.prevTime==0||!s&&t.prevComposition!=a&&(t.prevTime<(n.time||0)-r.newGroupDelay||!Eee(n,t.prevRanges)),u=s?Uv(t.prevRanges,n.mapping):hD(n.mapping.maps);return new Ui(t.done.addTransform(n,l?e.selection.getBookmark():void 0,r,Kf(e)),fo.empty,u,n.time,a??t.prevComposition)}else return(i=n.getMeta("rebased"))?new Ui(t.done.rebased(n,i),t.undone.rebased(n,i),Uv(t.prevRanges,n.mapping),t.prevTime,t.prevComposition):new Ui(t.done.addMaps(n.mapping.maps),t.undone.addMaps(n.mapping.maps),Uv(t.prevRanges,n.mapping),t.prevTime,t.prevComposition)}function Eee(t,e){if(!e)return!1;if(!t.docChanged)return!0;let n=!1;return t.mapping.maps[0].forEach((r,o)=>{for(let i=0;i<e.length;i+=2)r<=e[i+1]&&o>=e[i]&&(n=!0)}),n}function hD(t){let e=[];for(let n=t.length-1;n>=0&&e.length==0;n--)t[n].forEach((r,o,i,s)=>e.push(i,s));return e}function Uv(t,e){if(!t)return null;let n=[];for(let r=0;r<t.length;r+=2){let o=e.map(t[r],1),i=e.map(t[r+1],-1);o<=i&&n.push(o,i)}return n}function Mee(t,e,n){let r=Kf(e),o=Hs.get(e).spec.config,i=(n?t.undone:t.done).popEvent(e,r);if(!i)return null;let s=i.selection.resolve(i.transform.doc),a=(n?t.done:t.undone).addTransform(i.transform,e.selection.getBookmark(),o,r),l=new Ui(n?a:i.remaining,n?i.remaining:a,null,0,-1);return i.transform.setSelection(s).setMeta(Hs,{redo:n,historyState:l})}let Kv=!1,gD=null;function Kf(t){let e=t.plugins;if(gD!=e){Kv=!1,gD=e;for(let n=0;n<e.length;n++)if(e[n].spec.historyPreserveItems){Kv=!0;break}}return Kv}const Hs=new bn("history"),Oee=new bn("closeHistory");function Aee(t={}){return t={depth:t.depth||100,newGroupDelay:t.newGroupDelay||500},new en({key:Hs,state:{init(){return new Ui(fo.empty,fo.empty,null,0,-1)},apply(e,n,r){return kee(n,r,e,t)}},config:t,props:{handleDOMEvents:{beforeinput(e,n){let r=n.inputType,o=r=="historyUndo"?yD:r=="historyRedo"?bD:null;return o?(n.preventDefault(),o(e.state,e.dispatch)):!1}}}})}function mD(t,e){return(n,r)=>{let o=Hs.getState(n);if(!o||(t?o.undone:o.done).eventCount==0)return!1;if(r){let i=Mee(o,n,t);i&&r(e?i.scrollIntoView():i)}return!0}}const yD=mD(!1,!0),bD=mD(!0,!0),vD=sn.create({name:"history",addOptions(){return{depth:100,newGroupDelay:500}},addCommands(){return{undo:()=>({state:t,dispatch:e})=>yD(t,e),redo:()=>({state:t,dispatch:e})=>bD(t,e)}},addProseMirrorPlugins(){return[Aee(this.options)]},addKeyboardShortcuts(){return{"Mod-z":()=>this.editor.commands.undo(),"Shift-Mod-z":()=>this.editor.commands.redo(),"Mod-y":()=>this.editor.commands.redo(),"Mod-я":()=>this.editor.commands.undo(),"Shift-Mod-я":()=>this.editor.commands.redo()}}}),xD=tn.create({name:"horizontalRule",addOptions(){return{HTMLAttributes:{}}},group:"block",parseHTML(){return[{tag:"hr"}]},renderHTML({HTMLAttributes:t}){return["hr",yt(this.options.HTMLAttributes,t)]},addCommands(){return{setHorizontalRule:()=>({chain:t,state:e})=>{const{selection:n}=e,{$from:r,$to:o}=n,i=t();return r.parentOffset===0?i.insertContentAt({from:Math.max(r.pos-1,0),to:o.pos},{type:this.name}):XE(n)?i.insertContentAt(o.pos,{type:this.name}):i.insertContent({type:this.name}),i.command(({tr:s,dispatch:a})=>{var l;if(a){const{$to:u}=s.selection,f=u.end();if(u.nodeAfter)u.nodeAfter.isTextblock?s.setSelection(Ze.create(s.doc,u.pos+1)):u.nodeAfter.isBlock?s.setSelection(Ye.create(s.doc,u.pos)):s.setSelection(Ze.create(s.doc,u.pos));else{const p=(l=u.parent.type.contentMatch.defaultType)===null||l===void 0?void 0:l.create();p&&(s.insert(f,p),s.setSelection(Ze.create(s.doc,f+1)))}s.scrollIntoView()}return!0}).run()}}},addInputRules(){return[tM({find:/^(?:---|—-|___\s|\*\*\*\s)$/,type:this.type})]}}),Iee=/(?:^|\s)(\*(?!\s+\*)((?:[^*]+))\*(?!\s+\*))$/,Dee=/(?:^|\s)(\*(?!\s+\*)((?:[^*]+))\*(?!\s+\*))/g,Pee=/(?:^|\s)(_(?!\s+_)((?:[^_]+))_(?!\s+_))$/,Nee=/(?:^|\s)(_(?!\s+_)((?:[^_]+))_(?!\s+_))/g,SD=ur.create({name:"italic",addOptions(){return{HTMLAttributes:{}}},parseHTML(){return[{tag:"em"},{tag:"i",getAttrs:t=>t.style.fontStyle!=="normal"&&null},{style:"font-style=normal",clearMark:t=>t.type.name===this.name},{style:"font-style=italic"}]},renderHTML({HTMLAttributes:t}){return["em",yt(this.options.HTMLAttributes,t),0]},addCommands(){return{setItalic:()=>({commands:t})=>t.setMark(this.name),toggleItalic:()=>({commands:t})=>t.toggleMark(this.name),unsetItalic:()=>({commands:t})=>t.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-i":()=>this.editor.commands.toggleItalic(),"Mod-I":()=>this.editor.commands.toggleItalic()}},addInputRules(){return[Ls({find:Iee,type:this.type}),Ls({find:Pee,type:this.type})]},addPasteRules(){return[Vi({find:Dee,type:this.type}),Vi({find:Nee,type:this.type})]}}),Lee="aaa1rp3bb0ott3vie4c1le2ogado5udhabi7c0ademy5centure6ountant0s9o1tor4d0s1ult4e0g1ro2tna4f0l1rica5g0akhan5ency5i0g1rbus3force5tel5kdn3l0ibaba4pay4lfinanz6state5y2sace3tom5m0azon4ericanexpress7family11x2fam3ica3sterdam8nalytics7droid5quan4z2o0l2partments8p0le4q0uarelle8r0ab1mco4chi3my2pa2t0e3s0da2ia2sociates9t0hleta5torney7u0ction5di0ble3o3spost5thor3o0s4w0s2x0a2z0ure5ba0by2idu3namex4d1k2r0celona5laycard4s5efoot5gains6seball5ketball8uhaus5yern5b0c1t1va3cg1n2d1e0ats2uty4er2ntley5rlin4st0buy5t2f1g1h0arti5i0ble3d1ke2ng0o3o1z2j1lack0friday9ockbuster8g1omberg7ue3m0s1w2n0pparibas9o0ats3ehringer8fa2m1nd2o0k0ing5sch2tik2on4t1utique6x2r0adesco6idgestone9oadway5ker3ther5ussels7s1t1uild0ers6siness6y1zz3v1w1y1z0h3ca0b1fe2l0l1vinklein9m0era3p2non3petown5ital0one8r0avan4ds2e0er0s4s2sa1e1h1ino4t0ering5holic7ba1n1re3c1d1enter4o1rn3f0a1d2g1h0anel2nel4rity4se2t2eap3intai5ristmas6ome4urch5i0priani6rcle4sco3tadel4i0c2y3k1l0aims4eaning6ick2nic1que6othing5ud3ub0med6m1n1o0ach3des3ffee4llege4ogne5m0mbank4unity6pany2re3uter5sec4ndos3struction8ulting7tact3ractors9oking4l1p2rsica5untry4pon0s4rses6pa2r0edit0card4union9icket5own3s1uise0s6u0isinella9v1w1x1y0mru3ou3z2dad1nce3ta1e1ing3sun4y2clk3ds2e0al0er2s3gree4livery5l1oitte5ta3mocrat6ntal2ist5si0gn4v2hl2iamonds6et2gital5rect0ory7scount3ver5h2y2j1k1m1np2o0cs1tor4g1mains5t1wnload7rive4tv2ubai3nlop4pont4rban5vag2r2z2earth3t2c0o2deka3u0cation8e1g1mail3erck5nergy4gineer0ing9terprises10pson4quipment8r0icsson6ni3s0q1tate5t1u0rovision8s2vents5xchange6pert3osed4ress5traspace10fage2il1rwinds6th3mily4n0s2rm0ers5shion4t3edex3edback6rrari3ero6i0delity5o2lm2nal1nce1ial7re0stone6mdale6sh0ing5t0ness6j1k1lickr3ghts4r2orist4wers5y2m1o0o0d1tball6rd1ex2sale4um3undation8x2r0ee1senius7l1ogans4ntier7tr2ujitsu5n0d2rniture7tbol5yi3ga0l0lery3o1up4me0s3p1rden4y2b0iz3d0n2e0a1nt0ing5orge5f1g0ee3h1i0ft0s3ves2ing5l0ass3e1obal2o4m0ail3bh2o1x2n1odaddy5ld0point6f2o0dyear5g0le4p1t1v2p1q1r0ainger5phics5tis4een3ipe3ocery4up4s1t1u0cci3ge2ide2tars5ru3w1y2hair2mburg5ngout5us3bo2dfc0bank7ealth0care8lp1sinki6re1mes5iphop4samitsu7tachi5v2k0t2m1n1ockey4ldings5iday5medepot5goods5s0ense7nda3rse3spital5t0ing5t0els3mail5use3w2r1sbc3t1u0ghes5yatt3undai7ibm2cbc2e1u2d1e0ee3fm2kano4l1m0amat4db2mo0bilien9n0c1dustries8finiti5o2g1k1stitute6urance4e4t0ernational10uit4vestments10o1piranga7q1r0ish4s0maili5t0anbul7t0au2v3jaguar4va3cb2e0ep2tzt3welry6io2ll2m0p2nj2o0bs1urg4t1y2p0morgan6rs3uegos4niper7kaufen5ddi3e0rryhotels6logistics9properties14fh2g1h1i0a1ds2m1ndle4tchen5wi3m1n1oeln3matsu5sher5p0mg2n2r0d1ed3uokgroup8w1y0oto4z2la0caixa5mborghini8er3ncaster6d0rover6xess5salle5t0ino3robe5w0yer5b1c1ds2ease3clerc5frak4gal2o2xus4gbt3i0dl2fe0insurance9style7ghting6ke2lly3mited4o2ncoln4k2psy3ve1ing5k1lc1p2oan0s3cker3us3l1ndon4tte1o3ve3pl0financial11r1s1t0d0a3u0ndbeck6xe1ury5v1y2ma0drid4if1son4keup4n0agement7go3p1rket0ing3s4riott5shalls7ttel5ba2c0kinsey7d1e0d0ia3et2lbourne7me1orial6n0u2rckmsd7g1h1iami3crosoft7l1ni1t2t0subishi9k1l0b1s2m0a2n1o0bi0le4da2e1i1m1nash3ey2ster5rmon3tgage6scow4to0rcycles9v0ie4p1q1r1s0d2t0n1r2u0seum3ic4v1w1x1y1z2na0b1goya4me2vy3ba2c1e0c1t0bank4flix4work5ustar5w0s2xt0direct7us4f0l2g0o2hk2i0co2ke1on3nja3ssan1y5l1o0kia3rton4w0ruz3tv4p1r0a1w2tt2u1yc2z2obi1server7ffice5kinawa6layan0group9lo3m0ega4ne1g1l0ine5oo2pen3racle3nge4g0anic5igins6saka4tsuka4t2vh3pa0ge2nasonic7ris2s1tners4s1y3y2ccw3e0t2f0izer5g1h0armacy6d1ilips5one2to0graphy6s4ysio5ics1tet2ures6d1n0g1k2oneer5zza4k1l0ace2y0station9umbing5s3m1n0c2ohl2ker3litie5rn2st3r0america6xi3ess3ime3o0d0uctions8f1gressive8mo2perties3y5tection8u0dential9s1t1ub2w0c2y2qa1pon3uebec3st5racing4dio4e0ad1lestate6tor2y4cipes5d0stone5umbrella9hab3ise0n3t2liance6n0t0als5pair3ort3ublican8st0aurant8view0s5xroth6ich0ardli6oh3l1o1p2o0cks3deo3gers4om3s0vp3u0gby3hr2n2w0e2yukyu6sa0arland6fe0ty4kura4le1on3msclub4ung5ndvik0coromant12ofi4p1rl2s1ve2xo3b0i1s2c0b1haeffler7midt4olarships8ol3ule3warz5ience5ot3d1e0arch3t2cure1ity6ek2lect4ner3rvices6ven3w1x0y3fr2g1h0angrila6rp3ell3ia1ksha5oes2p0ping5uji3w3i0lk2na1gles5te3j1k0i0n2y0pe4l0ing4m0art3ile4n0cf3o0ccer3ial4ftbank4ware6hu2lar2utions7ng1y2y2pa0ce3ort2t3r0l2s1t0ada2ples4r1tebank4farm7c0group6ockholm6rage3e3ream4udio2y3yle4u0cks3pplies3y2ort5rf1gery5zuki5v1watch4iss4x1y0dney4stems6z2tab1ipei4lk2obao4rget4tamotors6r2too4x0i3c0i2d0k2eam2ch0nology8l1masek5nnis4va3f1g1h0d1eater2re6iaa2ckets5enda4ps2res2ol4j0maxx4x2k0maxx5l1m0all4n1o0day3kyo3ols3p1ray3shiba5tal3urs3wn2yota3s3r0ade1ing4ining5vel0ers0insurance16ust3v2t1ube2i1nes3shu4v0s2w1z2ua1bank3s2g1k1nicom3versity8o2ol2ps2s1y1z2va0cations7na1guard7c1e0gas3ntures6risign5mögensberater2ung14sicherung10t2g1i0ajes4deo3g1king4llas4n1p1rgin4sa1ion4va1o3laanderen9n1odka3lvo3te1ing3o2yage5u2wales2mart4ter4ng0gou5tch0es6eather0channel12bcam3er2site5d0ding5ibo2r3f1hoswho6ien2ki2lliamhill9n0dows4e1ners6me2olterskluwer11odside6rk0s2ld3w2s1tc1f3xbox3erox4ihuan4n2xx2yz3yachts4hoo3maxun5ndex5e1odobashi7ga2kohama6u0tube6t1un3za0ppos4ra3ero3ip2m1one3uerich6w2",Fee="ελ1υ2бг1ел3дети4ею2католик6ом3мкд2он1сква6онлайн5рг3рус2ф2сайт3рб3укр3қаз3հայ3ישראל5קום3ابوظبي5رامكو5لاردن4بحرين5جزائر5سعودية6عليان5مغرب5مارات5یران5بارت2زار4يتك3ھارت5تونس4سودان3رية5شبكة4عراق2ب2مان4فلسطين6قطر3كاثوليك6وم3مصر2ليسيا5وريتانيا7قع4همراه5پاکستان7ڀارت4कॉम3नेट3भारत0म्3ोत5संगठन5বাংলা5ভারত2ৰত4ਭਾਰਤ4ભારત4ଭାରତ4இந்தியா6லங்கை6சிங்கப்பூர்11భారత్5ಭಾರತ4ഭാരതം5ලංකා4คอม3ไทย3ລາວ3გე2みんな3アマゾン4クラウド4グーグル4コム2ストア3セール3ファッション6ポイント4世界2中信1国1國1文网3亚马逊3企业2佛山2信息2健康2八卦2公司1益2台湾1灣2商城1店1标2嘉里0大酒店5在线2大拿2天主教3娱乐2家電2广东2微博2慈善2我爱你3手机2招聘2政务1府2新加坡2闻2时尚2書籍2机构2淡马锡3游戏2澳門2点看2移动2组织机构4网址1店1站1络2联通2谷歌2购物2通販2集团2電訊盈科4飞利浦3食品2餐厅2香格里拉3港2닷넷1컴2삼성2한국2",Qa=(t,e)=>{for(const n in e)t[n]=e[n];return t},Yv="numeric",Gv="ascii",Jv="alpha",Yc="asciinumeric",Gc="alphanumeric",Zv="domain",CD="emoji",$ee="scheme",Bee="slashscheme",Xv="whitespace";function Ree(t,e){return t in e||(e[t]=[]),e[t]}function js(t,e,n){e[Yv]&&(e[Yc]=!0,e[Gc]=!0),e[Gv]&&(e[Yc]=!0,e[Jv]=!0),e[Yc]&&(e[Gc]=!0),e[Jv]&&(e[Gc]=!0),e[Gc]&&(e[Zv]=!0),e[CD]&&(e[Zv]=!0);for(const r in e){const o=Ree(r,n);o.indexOf(t)<0&&o.push(t)}}function zee(t,e){const n={};for(const r in e)e[r].indexOf(t)>=0&&(n[r]=!0);return n}function dr(t=null){this.j={},this.jr=[],this.jd=null,this.t=t}dr.groups={},dr.prototype={accepts(){return!!this.t},go(t){const e=this,n=e.j[t];if(n)return n;for(let r=0;r<e.jr.length;r++){const o=e.jr[r][0],i=e.jr[r][1];if(i&&o.test(t))return i}return e.jd},has(t,e=!1){return e?t in this.j:!!this.go(t)},ta(t,e,n,r){for(let o=0;o<t.length;o++)this.tt(t[o],e,n,r)},tr(t,e,n,r){r=r||dr.groups;let o;return e&&e.j?o=e:(o=new dr(e),n&&r&&js(e,n,r)),this.jr.push([t,o]),o},ts(t,e,n,r){let o=this;const i=t.length;if(!i)return o;for(let s=0;s<i-1;s++)o=o.tt(t[s]);return o.tt(t[i-1],e,n,r)},tt(t,e,n,r){r=r||dr.groups;const o=this;if(e&&e.j)return o.j[t]=e,e;const i=e;let s,a=o.go(t);if(a?(s=new dr,Qa(s.j,a.j),s.jr.push.apply(s.jr,a.jr),s.jd=a.jd,s.t=a.t):s=new dr,i){if(r)if(s.t&&typeof s.t=="string"){const l=Qa(zee(s.t,r),n);js(i,l,r)}else n&&js(i,n,r);s.t=i}return o.j[t]=s,s}};const lt=(t,e,n,r,o)=>t.ta(e,n,r,o),cn=(t,e,n,r,o)=>t.tr(e,n,r,o),wD=(t,e,n,r,o)=>t.ts(e,n,r,o),Oe=(t,e,n,r,o)=>t.tt(e,n,r,o),ni="WORD",Qv="UWORD",_D="ASCIINUMERICAL",TD="ALPHANUMERICAL",Jc="LOCALHOST",e1="TLD",t1="UTLD",Yf="SCHEME",el="SLASH_SCHEME",n1="NUM",r1="WS",o1="NL",Zc="OPENBRACE",Xc="CLOSEBRACE",Gf="OPENBRACKET",Jf="CLOSEBRACKET",Zf="OPENPAREN",Xf="CLOSEPAREN",Qf="OPENANGLEBRACKET",ep="CLOSEANGLEBRACKET",tp="FULLWIDTHLEFTPAREN",np="FULLWIDTHRIGHTPAREN",rp="LEFTCORNERBRACKET",op="RIGHTCORNERBRACKET",ip="LEFTWHITECORNERBRACKET",sp="RIGHTWHITECORNERBRACKET",ap="FULLWIDTHLESSTHAN",lp="FULLWIDTHGREATERTHAN",cp="AMPERSAND",i1="APOSTROPHE",up="ASTERISK",Ki="AT",dp="BACKSLASH",fp="BACKTICK",pp="CARET",Yi="COLON",s1="COMMA",hp="DOLLAR",Do="DOT",gp="EQUALS",a1="EXCLAMATION",Wr="HYPHEN",Qc="PERCENT",mp="PIPE",yp="PLUS",bp="POUND",eu="QUERY",l1="QUOTE",kD="FULLWIDTHMIDDLEDOT",c1="SEMI",Po="SLASH",tu="TILDE",vp="UNDERSCORE",ED="EMOJI",xp="SYM";var MD=Object.freeze({__proto__:null,WORD:ni,UWORD:Qv,ASCIINUMERICAL:_D,ALPHANUMERICAL:TD,LOCALHOST:Jc,TLD:e1,UTLD:t1,SCHEME:Yf,SLASH_SCHEME:el,NUM:n1,WS:r1,NL:o1,OPENBRACE:Zc,CLOSEBRACE:Xc,OPENBRACKET:Gf,CLOSEBRACKET:Jf,OPENPAREN:Zf,CLOSEPAREN:Xf,OPENANGLEBRACKET:Qf,CLOSEANGLEBRACKET:ep,FULLWIDTHLEFTPAREN:tp,FULLWIDTHRIGHTPAREN:np,LEFTCORNERBRACKET:rp,RIGHTCORNERBRACKET:op,LEFTWHITECORNERBRACKET:ip,RIGHTWHITECORNERBRACKET:sp,FULLWIDTHLESSTHAN:ap,FULLWIDTHGREATERTHAN:lp,AMPERSAND:cp,APOSTROPHE:i1,ASTERISK:up,AT:Ki,BACKSLASH:dp,BACKTICK:fp,CARET:pp,COLON:Yi,COMMA:s1,DOLLAR:hp,DOT:Do,EQUALS:gp,EXCLAMATION:a1,HYPHEN:Wr,PERCENT:Qc,PIPE:mp,PLUS:yp,POUND:bp,QUERY:eu,QUOTE:l1,FULLWIDTHMIDDLEDOT:kD,SEMI:c1,SLASH:Po,TILDE:tu,UNDERSCORE:vp,EMOJI:ED,SYM:xp});const ri=/[a-z]/,nu=new RegExp("\\p{L}","u"),u1=new RegExp("\\p{Emoji}","u"),oi=/\d/,d1=/\s/,OD="\r",f1=`
|
|
397
|
-
`,Vee="️",Hee="",p1="";let Sp=null,Cp=null;function jee(t=[]){const e={};dr.groups=e;const n=new dr;Sp==null&&(Sp=ID(Lee)),Cp==null&&(Cp=ID(Fee)),Oe(n,"'",i1),Oe(n,"{",Zc),Oe(n,"}",Xc),Oe(n,"[",Gf),Oe(n,"]",Jf),Oe(n,"(",Zf),Oe(n,")",Xf),Oe(n,"<",Qf),Oe(n,">",ep),Oe(n,"(",tp),Oe(n,")",np),Oe(n,"「",rp),Oe(n,"」",op),Oe(n,"『",ip),Oe(n,"』",sp),Oe(n,"<",ap),Oe(n,">",lp),Oe(n,"&",cp),Oe(n,"*",up),Oe(n,"@",Ki),Oe(n,"`",fp),Oe(n,"^",pp),Oe(n,":",Yi),Oe(n,",",s1),Oe(n,"$",hp),Oe(n,".",Do),Oe(n,"=",gp),Oe(n,"!",a1),Oe(n,"-",Wr),Oe(n,"%",Qc),Oe(n,"|",mp),Oe(n,"+",yp),Oe(n,"#",bp),Oe(n,"?",eu),Oe(n,'"',l1),Oe(n,"/",Po),Oe(n,";",c1),Oe(n,"~",tu),Oe(n,"_",vp),Oe(n,"\\",dp),Oe(n,"・",kD);const r=cn(n,oi,n1,{[Yv]:!0});cn(r,oi,r);const o=cn(r,ri,_D,{[Yc]:!0}),i=cn(r,nu,TD,{[Gc]:!0}),s=cn(n,ri,ni,{[Gv]:!0});cn(s,oi,o),cn(s,ri,s),cn(o,oi,o),cn(o,ri,o);const a=cn(n,nu,Qv,{[Jv]:!0});cn(a,ri),cn(a,oi,i),cn(a,nu,a),cn(i,oi,i),cn(i,ri),cn(i,nu,i);const l=Oe(n,f1,o1,{[Xv]:!0}),u=Oe(n,OD,r1,{[Xv]:!0}),f=cn(n,d1,r1,{[Xv]:!0});Oe(n,p1,f),Oe(u,f1,l),Oe(u,p1,f),cn(u,d1,f),Oe(f,OD),Oe(f,f1),cn(f,d1,f),Oe(f,p1,f);const p=cn(n,u1,ED,{[CD]:!0});Oe(p,"#"),cn(p,u1,p),Oe(p,Vee,p);const g=Oe(p,Hee);Oe(g,"#"),cn(g,u1,p);const m=[[ri,s],[oi,o]],y=[[ri,null],[nu,a],[oi,i]];for(let b=0;b<Sp.length;b++)Gi(n,Sp[b],e1,ni,m);for(let b=0;b<Cp.length;b++)Gi(n,Cp[b],t1,Qv,y);js(e1,{tld:!0,ascii:!0},e),js(t1,{utld:!0,alpha:!0},e),Gi(n,"file",Yf,ni,m),Gi(n,"mailto",Yf,ni,m),Gi(n,"http",el,ni,m),Gi(n,"https",el,ni,m),Gi(n,"ftp",el,ni,m),Gi(n,"ftps",el,ni,m),js(Yf,{scheme:!0,ascii:!0},e),js(el,{slashscheme:!0,ascii:!0},e),t=t.sort((b,S)=>b[0]>S[0]?1:-1);for(let b=0;b<t.length;b++){const S=t[b][0],T=t[b][1]?{[$ee]:!0}:{[Bee]:!0};S.indexOf("-")>=0?T[Zv]=!0:ri.test(S)?oi.test(S)?T[Yc]=!0:T[Gv]=!0:T[Yv]=!0,wD(n,S,S,T)}return wD(n,"localhost",Jc,{ascii:!0}),n.jd=new dr(xp),{start:n,tokens:Qa({groups:e},MD)}}function AD(t,e){const n=Wee(e.replace(/[A-Z]/g,a=>a.toLowerCase())),r=n.length,o=[];let i=0,s=0;for(;s<r;){let a=t,l=null,u=0,f=null,p=-1,g=-1;for(;s<r&&(l=a.go(n[s]));)a=l,a.accepts()?(p=0,g=0,f=a):p>=0&&(p+=n[s].length,g++),u+=n[s].length,i+=n[s].length,s++;i-=p,s-=g,u-=p,o.push({t:f.t,v:e.slice(i-u,i),s:i-u,e:i})}return o}function Wee(t){const e=[],n=t.length;let r=0;for(;r<n;){let o=t.charCodeAt(r),i,s=o<55296||o>56319||r+1===n||(i=t.charCodeAt(r+1))<56320||i>57343?t[r]:t.slice(r,r+2);e.push(s),r+=s.length}return e}function Gi(t,e,n,r,o){let i;const s=e.length;for(let a=0;a<s-1;a++){const l=e[a];t.j[l]?i=t.j[l]:(i=new dr(r),i.jr=o.slice(),t.j[l]=i),t=i}return i=new dr(n),i.jr=o.slice(),t.j[e[s-1]]=i,i}function ID(t){const e=[],n=[];let r=0,o="0123456789";for(;r<t.length;){let i=0;for(;o.indexOf(t[r+i])>=0;)i++;if(i>0){e.push(n.join(""));for(let s=parseInt(t.substring(r,r+i),10);s>0;s--)n.pop();r+=i}else n.push(t[r]),r++}return e}const ru={defaultProtocol:"http",events:null,format:DD,formatHref:DD,nl2br:!1,tagName:"a",target:null,rel:null,validate:!0,truncate:1/0,className:null,attributes:null,ignoreTags:[],render:null};function h1(t,e=null){let n=Qa({},ru);t&&(n=Qa(n,t instanceof h1?t.o:t));const r=n.ignoreTags,o=[];for(let i=0;i<r.length;i++)o.push(r[i].toUpperCase());this.o=n,e&&(this.defaultRender=e),this.ignoreTags=o}h1.prototype={o:ru,ignoreTags:[],defaultRender(t){return t},check(t){return this.get("validate",t.toString(),t)},get(t,e,n){const r=e!=null;let o=this.o[t];return o&&(typeof o=="object"?(o=n.t in o?o[n.t]:ru[t],typeof o=="function"&&r&&(o=o(e,n))):typeof o=="function"&&r&&(o=o(e,n.t,n)),o)},getObj(t,e,n){let r=this.o[t];return typeof r=="function"&&e!=null&&(r=r(e,n.t,n)),r},render(t){const e=t.render(this);return(this.get("render",null,t)||this.defaultRender)(e,t.t,t)}};function DD(t){return t}function PD(t,e){this.t="token",this.v=t,this.tk=e}PD.prototype={isLink:!1,toString(){return this.v},toHref(t){return this.toString()},toFormattedString(t){const e=this.toString(),n=t.get("truncate",e,this),r=t.get("format",e,this);return n&&r.length>n?r.substring(0,n)+"…":r},toFormattedHref(t){return t.get("formatHref",this.toHref(t.get("defaultProtocol")),this)},startIndex(){return this.tk[0].s},endIndex(){return this.tk[this.tk.length-1].e},toObject(t=ru.defaultProtocol){return{type:this.t,value:this.toString(),isLink:this.isLink,href:this.toHref(t),start:this.startIndex(),end:this.endIndex()}},toFormattedObject(t){return{type:this.t,value:this.toFormattedString(t),isLink:this.isLink,href:this.toFormattedHref(t),start:this.startIndex(),end:this.endIndex()}},validate(t){return t.get("validate",this.toString(),this)},render(t){const e=this,n=this.toHref(t.get("defaultProtocol")),r=t.get("formatHref",n,this),o=t.get("tagName",n,e),i=this.toFormattedString(t),s={},a=t.get("className",n,e),l=t.get("target",n,e),u=t.get("rel",n,e),f=t.getObj("attributes",n,e),p=t.getObj("events",n,e);return s.href=r,a&&(s.class=a),l&&(s.target=l),u&&(s.rel=u),f&&Qa(s,f),{tagName:o,attributes:s,content:i,eventListeners:p}}};function wp(t,e){class n extends PD{constructor(o,i){super(o,i),this.t=t}}for(const r in e)n.prototype[r]=e[r];return n.t=t,n}const ND=wp("email",{isLink:!0,toHref(){return"mailto:"+this.toString()}}),LD=wp("text"),qee=wp("nl"),_p=wp("url",{isLink:!0,toHref(t=ru.defaultProtocol){return this.hasProtocol()?this.v:`${t}://${this.v}`},hasProtocol(){const t=this.tk;return t.length>=2&&t[0].t!==Jc&&t[1].t===Yi}}),qr=t=>new dr(t);function Uee({groups:t}){const e=t.domain.concat([cp,up,Ki,dp,fp,pp,hp,gp,Wr,n1,Qc,mp,yp,bp,Po,xp,tu,vp]),n=[Yi,s1,Do,a1,Qc,eu,l1,c1,Qf,ep,Zc,Xc,Jf,Gf,Zf,Xf,tp,np,rp,op,ip,sp,ap,lp],r=[cp,i1,up,dp,fp,pp,hp,gp,Wr,Zc,Xc,Qc,mp,yp,bp,eu,Po,xp,tu,vp],o=qr(),i=Oe(o,tu);lt(i,r,i),lt(i,t.domain,i);const s=qr(),a=qr(),l=qr();lt(o,t.domain,s),lt(o,t.scheme,a),lt(o,t.slashscheme,l),lt(s,r,i),lt(s,t.domain,s);const u=Oe(s,Ki);Oe(i,Ki,u),Oe(a,Ki,u),Oe(l,Ki,u);const f=Oe(i,Do);lt(f,r,i),lt(f,t.domain,i);const p=qr();lt(u,t.domain,p),lt(p,t.domain,p);const g=Oe(p,Do);lt(g,t.domain,p);const m=qr(ND);lt(g,t.tld,m),lt(g,t.utld,m),Oe(u,Jc,m);const y=Oe(p,Wr);Oe(y,Wr,y),lt(y,t.domain,p),lt(m,t.domain,p),Oe(m,Do,g),Oe(m,Wr,y);const b=Oe(m,Yi);lt(b,t.numeric,ND);const S=Oe(s,Wr),C=Oe(s,Do);Oe(S,Wr,S),lt(S,t.domain,s),lt(C,r,i),lt(C,t.domain,s);const T=qr(_p);lt(C,t.tld,T),lt(C,t.utld,T),lt(T,t.domain,s),lt(T,r,i),Oe(T,Do,C),Oe(T,Wr,S),Oe(T,Ki,u);const _=Oe(T,Yi),w=qr(_p);lt(_,t.numeric,w);const E=qr(_p),O=qr();lt(E,e,E),lt(E,n,O),lt(O,e,E),lt(O,n,O),Oe(T,Po,E),Oe(w,Po,E);const L=Oe(a,Yi),P=Oe(l,Yi),$=Oe(P,Po),M=Oe($,Po);lt(a,t.domain,s),Oe(a,Do,C),Oe(a,Wr,S),lt(l,t.domain,s),Oe(l,Do,C),Oe(l,Wr,S),lt(L,t.domain,E),Oe(L,Po,E),Oe(L,eu,E),lt(M,t.domain,E),lt(M,e,E),Oe(M,Po,E);const A=[[Zc,Xc],[Gf,Jf],[Zf,Xf],[Qf,ep],[tp,np],[rp,op],[ip,sp],[ap,lp]];for(let N=0;N<A.length;N++){const[V
|
|
397
|
+
`,Vee="️",Hee="",p1="";let Sp=null,Cp=null;function jee(t=[]){const e={};dr.groups=e;const n=new dr;Sp==null&&(Sp=ID(Lee)),Cp==null&&(Cp=ID(Fee)),Oe(n,"'",i1),Oe(n,"{",Zc),Oe(n,"}",Xc),Oe(n,"[",Gf),Oe(n,"]",Jf),Oe(n,"(",Zf),Oe(n,")",Xf),Oe(n,"<",Qf),Oe(n,">",ep),Oe(n,"(",tp),Oe(n,")",np),Oe(n,"「",rp),Oe(n,"」",op),Oe(n,"『",ip),Oe(n,"』",sp),Oe(n,"<",ap),Oe(n,">",lp),Oe(n,"&",cp),Oe(n,"*",up),Oe(n,"@",Ki),Oe(n,"`",fp),Oe(n,"^",pp),Oe(n,":",Yi),Oe(n,",",s1),Oe(n,"$",hp),Oe(n,".",Do),Oe(n,"=",gp),Oe(n,"!",a1),Oe(n,"-",Wr),Oe(n,"%",Qc),Oe(n,"|",mp),Oe(n,"+",yp),Oe(n,"#",bp),Oe(n,"?",eu),Oe(n,'"',l1),Oe(n,"/",Po),Oe(n,";",c1),Oe(n,"~",tu),Oe(n,"_",vp),Oe(n,"\\",dp),Oe(n,"・",kD);const r=cn(n,oi,n1,{[Yv]:!0});cn(r,oi,r);const o=cn(r,ri,_D,{[Yc]:!0}),i=cn(r,nu,TD,{[Gc]:!0}),s=cn(n,ri,ni,{[Gv]:!0});cn(s,oi,o),cn(s,ri,s),cn(o,oi,o),cn(o,ri,o);const a=cn(n,nu,Qv,{[Jv]:!0});cn(a,ri),cn(a,oi,i),cn(a,nu,a),cn(i,oi,i),cn(i,ri),cn(i,nu,i);const l=Oe(n,f1,o1,{[Xv]:!0}),u=Oe(n,OD,r1,{[Xv]:!0}),f=cn(n,d1,r1,{[Xv]:!0});Oe(n,p1,f),Oe(u,f1,l),Oe(u,p1,f),cn(u,d1,f),Oe(f,OD),Oe(f,f1),cn(f,d1,f),Oe(f,p1,f);const p=cn(n,u1,ED,{[CD]:!0});Oe(p,"#"),cn(p,u1,p),Oe(p,Vee,p);const g=Oe(p,Hee);Oe(g,"#"),cn(g,u1,p);const m=[[ri,s],[oi,o]],y=[[ri,null],[nu,a],[oi,i]];for(let b=0;b<Sp.length;b++)Gi(n,Sp[b],e1,ni,m);for(let b=0;b<Cp.length;b++)Gi(n,Cp[b],t1,Qv,y);js(e1,{tld:!0,ascii:!0},e),js(t1,{utld:!0,alpha:!0},e),Gi(n,"file",Yf,ni,m),Gi(n,"mailto",Yf,ni,m),Gi(n,"http",el,ni,m),Gi(n,"https",el,ni,m),Gi(n,"ftp",el,ni,m),Gi(n,"ftps",el,ni,m),js(Yf,{scheme:!0,ascii:!0},e),js(el,{slashscheme:!0,ascii:!0},e),t=t.sort((b,S)=>b[0]>S[0]?1:-1);for(let b=0;b<t.length;b++){const S=t[b][0],T=t[b][1]?{[$ee]:!0}:{[Bee]:!0};S.indexOf("-")>=0?T[Zv]=!0:ri.test(S)?oi.test(S)?T[Yc]=!0:T[Gv]=!0:T[Yv]=!0,wD(n,S,S,T)}return wD(n,"localhost",Jc,{ascii:!0}),n.jd=new dr(xp),{start:n,tokens:Qa({groups:e},MD)}}function AD(t,e){const n=Wee(e.replace(/[A-Z]/g,a=>a.toLowerCase())),r=n.length,o=[];let i=0,s=0;for(;s<r;){let a=t,l=null,u=0,f=null,p=-1,g=-1;for(;s<r&&(l=a.go(n[s]));)a=l,a.accepts()?(p=0,g=0,f=a):p>=0&&(p+=n[s].length,g++),u+=n[s].length,i+=n[s].length,s++;i-=p,s-=g,u-=p,o.push({t:f.t,v:e.slice(i-u,i),s:i-u,e:i})}return o}function Wee(t){const e=[],n=t.length;let r=0;for(;r<n;){let o=t.charCodeAt(r),i,s=o<55296||o>56319||r+1===n||(i=t.charCodeAt(r+1))<56320||i>57343?t[r]:t.slice(r,r+2);e.push(s),r+=s.length}return e}function Gi(t,e,n,r,o){let i;const s=e.length;for(let a=0;a<s-1;a++){const l=e[a];t.j[l]?i=t.j[l]:(i=new dr(r),i.jr=o.slice(),t.j[l]=i),t=i}return i=new dr(n),i.jr=o.slice(),t.j[e[s-1]]=i,i}function ID(t){const e=[],n=[];let r=0,o="0123456789";for(;r<t.length;){let i=0;for(;o.indexOf(t[r+i])>=0;)i++;if(i>0){e.push(n.join(""));for(let s=parseInt(t.substring(r,r+i),10);s>0;s--)n.pop();r+=i}else n.push(t[r]),r++}return e}const ru={defaultProtocol:"http",events:null,format:DD,formatHref:DD,nl2br:!1,tagName:"a",target:null,rel:null,validate:!0,truncate:1/0,className:null,attributes:null,ignoreTags:[],render:null};function h1(t,e=null){let n=Qa({},ru);t&&(n=Qa(n,t instanceof h1?t.o:t));const r=n.ignoreTags,o=[];for(let i=0;i<r.length;i++)o.push(r[i].toUpperCase());this.o=n,e&&(this.defaultRender=e),this.ignoreTags=o}h1.prototype={o:ru,ignoreTags:[],defaultRender(t){return t},check(t){return this.get("validate",t.toString(),t)},get(t,e,n){const r=e!=null;let o=this.o[t];return o&&(typeof o=="object"?(o=n.t in o?o[n.t]:ru[t],typeof o=="function"&&r&&(o=o(e,n))):typeof o=="function"&&r&&(o=o(e,n.t,n)),o)},getObj(t,e,n){let r=this.o[t];return typeof r=="function"&&e!=null&&(r=r(e,n.t,n)),r},render(t){const e=t.render(this);return(this.get("render",null,t)||this.defaultRender)(e,t.t,t)}};function DD(t){return t}function PD(t,e){this.t="token",this.v=t,this.tk=e}PD.prototype={isLink:!1,toString(){return this.v},toHref(t){return this.toString()},toFormattedString(t){const e=this.toString(),n=t.get("truncate",e,this),r=t.get("format",e,this);return n&&r.length>n?r.substring(0,n)+"…":r},toFormattedHref(t){return t.get("formatHref",this.toHref(t.get("defaultProtocol")),this)},startIndex(){return this.tk[0].s},endIndex(){return this.tk[this.tk.length-1].e},toObject(t=ru.defaultProtocol){return{type:this.t,value:this.toString(),isLink:this.isLink,href:this.toHref(t),start:this.startIndex(),end:this.endIndex()}},toFormattedObject(t){return{type:this.t,value:this.toFormattedString(t),isLink:this.isLink,href:this.toFormattedHref(t),start:this.startIndex(),end:this.endIndex()}},validate(t){return t.get("validate",this.toString(),this)},render(t){const e=this,n=this.toHref(t.get("defaultProtocol")),r=t.get("formatHref",n,this),o=t.get("tagName",n,e),i=this.toFormattedString(t),s={},a=t.get("className",n,e),l=t.get("target",n,e),u=t.get("rel",n,e),f=t.getObj("attributes",n,e),p=t.getObj("events",n,e);return s.href=r,a&&(s.class=a),l&&(s.target=l),u&&(s.rel=u),f&&Qa(s,f),{tagName:o,attributes:s,content:i,eventListeners:p}}};function wp(t,e){class n extends PD{constructor(o,i){super(o,i),this.t=t}}for(const r in e)n.prototype[r]=e[r];return n.t=t,n}const ND=wp("email",{isLink:!0,toHref(){return"mailto:"+this.toString()}}),LD=wp("text"),qee=wp("nl"),_p=wp("url",{isLink:!0,toHref(t=ru.defaultProtocol){return this.hasProtocol()?this.v:`${t}://${this.v}`},hasProtocol(){const t=this.tk;return t.length>=2&&t[0].t!==Jc&&t[1].t===Yi}}),qr=t=>new dr(t);function Uee({groups:t}){const e=t.domain.concat([cp,up,Ki,dp,fp,pp,hp,gp,Wr,n1,Qc,mp,yp,bp,Po,xp,tu,vp]),n=[Yi,s1,Do,a1,Qc,eu,l1,c1,Qf,ep,Zc,Xc,Jf,Gf,Zf,Xf,tp,np,rp,op,ip,sp,ap,lp],r=[cp,i1,up,dp,fp,pp,hp,gp,Wr,Zc,Xc,Qc,mp,yp,bp,eu,Po,xp,tu,vp],o=qr(),i=Oe(o,tu);lt(i,r,i),lt(i,t.domain,i);const s=qr(),a=qr(),l=qr();lt(o,t.domain,s),lt(o,t.scheme,a),lt(o,t.slashscheme,l),lt(s,r,i),lt(s,t.domain,s);const u=Oe(s,Ki);Oe(i,Ki,u),Oe(a,Ki,u),Oe(l,Ki,u);const f=Oe(i,Do);lt(f,r,i),lt(f,t.domain,i);const p=qr();lt(u,t.domain,p),lt(p,t.domain,p);const g=Oe(p,Do);lt(g,t.domain,p);const m=qr(ND);lt(g,t.tld,m),lt(g,t.utld,m),Oe(u,Jc,m);const y=Oe(p,Wr);Oe(y,Wr,y),lt(y,t.domain,p),lt(m,t.domain,p),Oe(m,Do,g),Oe(m,Wr,y);const b=Oe(m,Yi);lt(b,t.numeric,ND);const S=Oe(s,Wr),C=Oe(s,Do);Oe(S,Wr,S),lt(S,t.domain,s),lt(C,r,i),lt(C,t.domain,s);const T=qr(_p);lt(C,t.tld,T),lt(C,t.utld,T),lt(T,t.domain,s),lt(T,r,i),Oe(T,Do,C),Oe(T,Wr,S),Oe(T,Ki,u);const _=Oe(T,Yi),w=qr(_p);lt(_,t.numeric,w);const E=qr(_p),O=qr();lt(E,e,E),lt(E,n,O),lt(O,e,E),lt(O,n,O),Oe(T,Po,E),Oe(w,Po,E);const L=Oe(a,Yi),P=Oe(l,Yi),$=Oe(P,Po),M=Oe($,Po);lt(a,t.domain,s),Oe(a,Do,C),Oe(a,Wr,S),lt(l,t.domain,s),Oe(l,Do,C),Oe(l,Wr,S),lt(L,t.domain,E),Oe(L,Po,E),Oe(L,eu,E),lt(M,t.domain,E),lt(M,e,E),Oe(M,Po,E);const A=[[Zc,Xc],[Gf,Jf],[Zf,Xf],[Qf,ep],[tp,np],[rp,op],[ip,sp],[ap,lp]];for(let N=0;N<A.length;N++){const[z,V]=A[N],B=Oe(E,z);Oe(O,z,B),Oe(B,V,E);const R=qr(_p);lt(B,e,R);const q=qr();lt(B,n),lt(R,e,R),lt(R,n,q),lt(q,e,R),lt(q,n,q),Oe(R,V,E),Oe(q,V,E)}return Oe(o,Jc,T),Oe(o,o1,qee),{start:o,tokens:MD}}function Kee(t,e,n){let r=n.length,o=0,i=[],s=[];for(;o<r;){let a=t,l=null,u=null,f=0,p=null,g=-1;for(;o<r&&!(l=a.go(n[o].t));)s.push(n[o++]);for(;o<r&&(u=l||a.go(n[o].t));)l=null,a=u,a.accepts()?(g=0,p=a):g>=0&&g++,o++,f++;if(g<0)o-=f,o<r&&(s.push(n[o]),o++);else{s.length>0&&(i.push(g1(LD,e,s)),s=[]),o-=g,f-=g;const m=p.t,y=n.slice(o-f,o);i.push(g1(m,e,y))}}return s.length>0&&i.push(g1(LD,e,s)),i}function g1(t,e,n){const r=n[0].s,o=n[n.length-1].e,i=e.slice(r,o);return new t(i,n)}const Yee=typeof console<"u"&&console&&console.warn||(()=>{}),Gee="until manual call of linkify.init(). Register all schemes and plugins before invoking linkify the first time.",Kt={scanner:null,parser:null,tokenQueue:[],pluginQueue:[],customSchemes:[],initialized:!1};function Jee(){return dr.groups={},Kt.scanner=null,Kt.parser=null,Kt.tokenQueue=[],Kt.pluginQueue=[],Kt.customSchemes=[],Kt.initialized=!1,Kt}function FD(t,e=!1){if(Kt.initialized&&Yee(`linkifyjs: already initialized - will not register custom scheme "${t}" ${Gee}`),!/^[0-9a-z]+(-[0-9a-z]+)*$/.test(t))throw new Error(`linkifyjs: incorrect scheme format.
|
|
398
398
|
1. Must only contain digits, lowercase ASCII letters or "-"
|
|
399
399
|
2. Cannot start or end with "-"
|
|
400
|
-
3. "-" cannot repeat`);Kt.customSchemes.push([t,e])}function Zee(){Kt.scanner=jee(Kt.customSchemes);for(let t=0;t<Kt.tokenQueue.length;t++)Kt.tokenQueue[t][1]({scanner:Kt.scanner});Kt.parser=Uee(Kt.scanner.tokens);for(let t=0;t<Kt.pluginQueue.length;t++)Kt.pluginQueue[t][1]({scanner:Kt.scanner,parser:Kt.parser});return Kt.initialized=!0,Kt}function m1(t){return Kt.initialized||Zee(),Kee(Kt.parser.start,t,AD(Kt.scanner.start,t))}m1.scan=AD;function $D(t,e=null,n=null){if(e&&typeof e=="object"){if(n)throw Error(`linkifyjs: Invalid link type ${e}; must be a string`);n=e,e=null}const r=new h1(n),o=m1(t),i=[];for(let s=0;s<o.length;s++){const a=o[s];a.isLink&&(!e||a.t===e)&&r.check(a)&&i.push(a.toFormattedObject(r))}return i}function Xee(t){return t.length===1?t[0].isLink:t.length===3&&t[1].isLink?["()","[]"].includes(t[0].value+t[2].value):!1}function Qee(t){return new en({key:new bn("autolink"),appendTransaction:(e,n,r)=>{const o=e.some(u=>u.docChanged)&&!n.doc.eq(r.doc),i=e.some(u=>u.getMeta("preventAutolink"));if(!o||i)return;const{tr:s}=r,a=gK(n.doc,[...e]);if(SK(a).forEach(({newRange:u})=>{const f=yK(r.doc,u,m=>m.isTextblock);let p,g;if(f.length>1?(p=f[0],g=r.doc.textBetween(p.pos,p.pos+p.node.nodeSize,void 0," ")):f.length&&r.doc.textBetween(u.from,u.to," "," ").endsWith(" ")&&(p=f[0],g=r.doc.textBetween(p.pos,u.to,void 0," ")),p&&g){const m=g.split(" ").filter(C=>C!=="");if(m.length<=0)return!1;const y=m[m.length-1],b=p.pos+g.lastIndexOf(y);if(!y)return!1;const S=m1(y).map(C=>C.toObject(t.defaultProtocol));if(!Xee(S))return!1;S.filter(C=>C.isLink).map(C=>({...C,from:b+C.start+1,to:b+C.end+1})).filter(C=>r.schema.marks.code?!r.doc.rangeHasMark(C.from,C.to,r.schema.marks.code):!0).filter(C=>t.validate(C.value)).filter(C=>t.shouldAutoLink(C.value)).forEach(C=>{oy(C.from,C.to,r.doc).some(T=>T.mark.type===t.type)||s.addMark(C.from,C.to,t.type.create({href:C.href}))})}}),!!s.steps.length)return s}})}function ete(t){return new en({key:new bn("handleClickLink"),props:{handleClick:(e,n,r)=>{var o,i;if(r.button!==0||!e.editable)return!1;let s=r.target;const a=[];for(;s.nodeName!=="DIV";)a.push(s),s=s.parentNode;if(!a.find(g=>g.nodeName==="A"))return!1;const l=ry(e.state,t.type.name),u=r.target,f=(o=u==null?void 0:u.href)!==null&&o!==void 0?o:l.href,p=(i=u==null?void 0:u.target)!==null&&i!==void 0?i:l.target;return u&&f?(window.open(f,p),!0):!1}}})}function tte(t){return new en({key:new bn("handlePasteLink"),props:{handlePaste:(e,n,r)=>{const{state:o}=e,{selection:i}=o,{empty:s}=i;if(s)return!1;let a="";r.content.forEach(u=>{a+=u.textContent});const l=$D(a,{defaultProtocol:t.defaultProtocol}).find(u=>u.isLink&&u.value===a);return!a||!l?!1:t.editor.commands.setMark(t.type,{href:l.href})}}})}const nte=/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g;function Ws(t,e){const n=["http","https","ftp","ftps","mailto","tel","callto","sms","cid","xmpp"];return e&&e.forEach(r=>{const o=typeof r=="string"?r:r.scheme;o&&n.push(o)}),!t||t.replace(nte,"").match(new RegExp(`^(?:(?:${n.join("|")}):|[^a-z]|[a-z0-9+.-]+(?:[^a-z+.-:]|$))`,"i"))}const rte=ur.create({name:"link",priority:1e3,keepOnSplit:!1,exitable:!0,onCreate(){this.options.validate&&!this.options.shouldAutoLink&&(this.options.shouldAutoLink=this.options.validate,console.warn("The `validate` option is deprecated. Rename to the `shouldAutoLink` option instead.")),this.options.protocols.forEach(t=>{if(typeof t=="string"){FD(t);return}FD(t.scheme,t.optionalSlashes)})},onDestroy(){Jee()},inclusive(){return this.options.autolink},addOptions(){return{openOnClick:!0,linkOnPaste:!0,autolink:!0,protocols:[],defaultProtocol:"http",HTMLAttributes:{target:"_blank",rel:"noopener noreferrer nofollow",class:null},isAllowedUri:(t,e)=>!!Ws(t,e.protocols),validate:t=>!!t,shouldAutoLink:t=>!!t}},addAttributes(){return{href:{default:null,parseHTML(t){return t.getAttribute("href")}},target:{default:this.options.HTMLAttributes.target},rel:{default:this.options.HTMLAttributes.rel},class:{default:this.options.HTMLAttributes.class}}},parseHTML(){return[{tag:"a[href]",getAttrs:t=>{const e=t.getAttribute("href");return!e||!this.options.isAllowedUri(e,{defaultValidate:n=>!!Ws(n,this.options.protocols),protocols:this.options.protocols,defaultProtocol:this.options.defaultProtocol})?!1:null}}]},renderHTML({HTMLAttributes:t}){return this.options.isAllowedUri(t.href,{defaultValidate:e=>!!Ws(e,this.options.protocols),protocols:this.options.protocols,defaultProtocol:this.options.defaultProtocol})?["a",yt(this.options.HTMLAttributes,t),0]:["a",yt(this.options.HTMLAttributes,{...t,href:""}),0]},addCommands(){return{setLink:t=>({chain:e})=>{const{href:n}=t;return this.options.isAllowedUri(n,{defaultValidate:r=>!!Ws(r,this.options.protocols),protocols:this.options.protocols,defaultProtocol:this.options.defaultProtocol})?e().setMark(this.name,t).setMeta("preventAutolink",!0).run():!1},toggleLink:t=>({chain:e})=>{const{href:n}=t;return this.options.isAllowedUri(n,{defaultValidate:r=>!!Ws(r,this.options.protocols),protocols:this.options.protocols,defaultProtocol:this.options.defaultProtocol})?e().toggleMark(this.name,t,{extendEmptyMarkRange:!0}).setMeta("preventAutolink",!0).run():!1},unsetLink:()=>({chain:t})=>t().unsetMark(this.name,{extendEmptyMarkRange:!0}).setMeta("preventAutolink",!0).run()}},addPasteRules(){return[Vi({find:t=>{const e=[];if(t){const{protocols:n,defaultProtocol:r}=this.options,o=$D(t).filter(i=>i.isLink&&this.options.isAllowedUri(i.value,{defaultValidate:s=>!!Ws(s,n),protocols:n,defaultProtocol:r}));o.length&&o.forEach(i=>e.push({text:i.value,data:{href:i.href},index:i.start}))}return e},type:this.type,getAttributes:t=>{var e;return{href:(e=t.data)===null||e===void 0?void 0:e.href}}})]},addProseMirrorPlugins(){const t=[],{protocols:e,defaultProtocol:n}=this.options;return this.options.autolink&&t.push(Qee({type:this.type,defaultProtocol:this.options.defaultProtocol,validate:r=>this.options.isAllowedUri(r,{defaultValidate:o=>!!Ws(o,e),protocols:e,defaultProtocol:n}),shouldAutoLink:this.options.shouldAutoLink})),this.options.openOnClick===!0&&t.push(ete({type:this.type})),this.options.linkOnPaste&&t.push(tte({editor:this.editor,defaultProtocol:this.options.defaultProtocol,type:this.type})),t}}),BD=tn.create({name:"listItem",addOptions(){return{HTMLAttributes:{},bulletListTypeName:"bulletList",orderedListTypeName:"orderedList"}},content:"paragraph block*",defining:!0,parseHTML(){return[{tag:"li"}]},renderHTML({HTMLAttributes:t}){return["li",yt(this.options.HTMLAttributes,t),0]},addKeyboardShortcuts(){return{Enter:()=>this.editor.commands.splitListItem(this.name),Tab:()=>this.editor.commands.sinkListItem(this.name),"Shift-Tab":()=>this.editor.commands.liftListItem(this.name)}}});function ote(t){var e;const{char:n,allowSpaces:r,allowToIncludeChar:o,allowedPrefixes:i,startOfLine:s,$position:a}=t,l=r&&!o,u=qK(n),f=new RegExp(`\\s${u}$`),p=s?"^":"",g=o?"":u,m=l?new RegExp(`${p}${u}.*?(?=\\s${g}|$)`,"gm"):new RegExp(`${p}(?:^)?${u}[^\\s${g}]*`,"gm"),y=((e=a.nodeBefore)===null||e===void 0?void 0:e.isText)&&a.nodeBefore.text;if(!y)return null;const b=a.pos-y.length,S=Array.from(y.matchAll(m)).pop();if(!S||S.input===void 0||S.index===void 0)return null;const C=S.input.slice(Math.max(0,S.index-1),S.index),T=new RegExp(`^[${i==null?void 0:i.join("")}\0]?$`).test(C);if(i!==null&&!T)return null;const _=b+S.index;let w=_+S[0].length;return l&&f.test(y.slice(w-1,w+1))&&(S[0]+=" ",w+=1),_<a.pos&&w>=a.pos?{range:{from:_,to:w},query:S[0].slice(n.length),text:S[0]}:null}const ite=new bn("suggestion");function ste({pluginKey:t=ite,editor:e,char:n="@",allowSpaces:r=!1,allowToIncludeChar:o=!1,allowedPrefixes:i=[" "],startOfLine:s=!1,decorationTag:a="span",decorationClass:l="suggestion",command:u=()=>null,items:f=()=>[],render:p=()=>({}),allow:g=()=>!0,findSuggestionMatch:m=ote}){let y;const b=p==null?void 0:p(),S=new en({key:t,view(){return{update:async(C,T)=>{var _,w,E,O,L,P,$;const M=(_=this.key)===null||_===void 0?void 0:_.getState(T),A=(w=this.key)===null||w===void 0?void 0:w.getState(C.state),N=M.active&&A.active&&M.range.from!==A.range.from,V=!M.active&&A.active,R=M.active&&!A.active,B=!V&&!R&&M.query!==A.query,z=V||N&&B,q=B||N,K=R||N&&B;if(!z&&!q&&!K)return;const G=K&&!z?M:A,Y=C.dom.querySelector(`[data-decoration-id="${G.decorationId}"]`);y={editor:e,range:G.range,query:G.query,text:G.text,items:[],command:Z=>u({editor:e,range:G.range,props:Z}),decorationNode:Y,clientRect:Y?()=>{var Z;const{decorationId:me}=(Z=this.key)===null||Z===void 0?void 0:Z.getState(e.state),he=C.dom.querySelector(`[data-decoration-id="${me}"]`);return(he==null?void 0:he.getBoundingClientRect())||null}:null},z&&((E=b==null?void 0:b.onBeforeStart)===null||E===void 0||E.call(b,y)),q&&((O=b==null?void 0:b.onBeforeUpdate)===null||O===void 0||O.call(b,y)),(q||z)&&(y.items=await f({editor:e,query:G.query})),K&&((L=b==null?void 0:b.onExit)===null||L===void 0||L.call(b,y)),q&&((P=b==null?void 0:b.onUpdate)===null||P===void 0||P.call(b,y)),z&&(($=b==null?void 0:b.onStart)===null||$===void 0||$.call(b,y))},destroy:()=>{var C;y&&((C=b==null?void 0:b.onExit)===null||C===void 0||C.call(b,y))}}},state:{init(){return{active:!1,range:{from:0,to:0},query:null,text:null,composing:!1}},apply(C,T,_,w){const{isEditable:E}=e,{composing:O}=e.view,{selection:L}=C,{empty:P,from:$}=L,M={...T};if(M.composing=O,E&&(P||e.view.composing)){($<T.range.from||$>T.range.to)&&!O&&!T.composing&&(M.active=!1);const A=m({char:n,allowSpaces:r,allowToIncludeChar:o,allowedPrefixes:i,startOfLine:s,$position:L.$from}),N=`id_${Math.floor(Math.random()*4294967295)}`;A&&g({editor:e,state:w,range:A.range,isActive:T.active})?(M.active=!0,M.decorationId=T.decorationId?T.decorationId:N,M.range=A.range,M.query=A.query,M.text=A.text):M.active=!1}else M.active=!1;return M.active||(M.decorationId=null,M.range={from:0,to:0},M.query=null,M.text=null),M}},props:{handleKeyDown(C,T){var _;const{active:w,range:E}=S.getState(C.state);return w&&((_=b==null?void 0:b.onKeyDown)===null||_===void 0?void 0:_.call(b,{view:C,event:T,range:E}))||!1},decorations(C){const{active:T,range:_,decorationId:w}=S.getState(C);return T?Zt.create(C.doc,[Ln.inline(_.from,_.to,{nodeName:a,class:l,"data-decoration-id":w})]):null}}});return S}const ate=new bn("mention"),lte=tn.create({name:"mention",priority:101,addOptions(){return{HTMLAttributes:{},renderText({options:t,node:e}){var n;return`${t.suggestion.char}${(n=e.attrs.label)!==null&&n!==void 0?n:e.attrs.id}`},deleteTriggerWithBackspace:!1,renderHTML({options:t,node:e}){var n;return["span",yt(this.HTMLAttributes,t.HTMLAttributes),`${t.suggestion.char}${(n=e.attrs.label)!==null&&n!==void 0?n:e.attrs.id}`]},suggestion:{char:"@",pluginKey:ate,command:({editor:t,range:e,props:n})=>{var r,o,i;const s=t.view.state.selection.$to.nodeAfter;((r=s==null?void 0:s.text)===null||r===void 0?void 0:r.startsWith(" "))&&(e.to+=1),t.chain().focus().insertContentAt(e,[{type:this.name,attrs:n},{type:"text",text:" "}]).run(),(i=(o=t.view.dom.ownerDocument.defaultView)===null||o===void 0?void 0:o.getSelection())===null||i===void 0||i.collapseToEnd()},allow:({state:t,range:e})=>{const n=t.doc.resolve(e.from),r=t.schema.nodes[this.name];return!!n.parent.type.contentMatch.matchType(r)}}}},group:"inline",inline:!0,selectable:!1,atom:!0,addAttributes(){return{id:{default:null,parseHTML:t=>t.getAttribute("data-id"),renderHTML:t=>t.id?{"data-id":t.id}:{}},label:{default:null,parseHTML:t=>t.getAttribute("data-label"),renderHTML:t=>t.label?{"data-label":t.label}:{}}}},parseHTML(){return[{tag:`span[data-type="${this.name}"]`}]},renderHTML({node:t,HTMLAttributes:e}){if(this.options.renderLabel!==void 0)return console.warn("renderLabel is deprecated use renderText and renderHTML instead"),["span",yt({"data-type":this.name},this.options.HTMLAttributes,e),this.options.renderLabel({options:this.options,node:t})];const n={...this.options};n.HTMLAttributes=yt({"data-type":this.name},this.options.HTMLAttributes,e);const r=this.options.renderHTML({options:n,node:t});return typeof r=="string"?["span",yt({"data-type":this.name},this.options.HTMLAttributes,e),r]:r},renderText({node:t}){return this.options.renderLabel!==void 0?(console.warn("renderLabel is deprecated use renderText and renderHTML instead"),this.options.renderLabel({options:this.options,node:t})):this.options.renderText({options:this.options,node:t})},addKeyboardShortcuts(){return{Backspace:()=>this.editor.commands.command(({tr:t,state:e})=>{let n=!1;const{selection:r}=e,{empty:o,anchor:i}=r;return o?(e.doc.nodesBetween(i-1,i,(s,a)=>{if(s.type.name===this.name)return n=!0,t.insertText(this.options.deleteTriggerWithBackspace?"":this.options.suggestion.char||"",a,a+s.nodeSize),!1}),n):!1})}},addProseMirrorPlugins(){return[ste({editor:this.editor,...this.options.suggestion})]}}),cte="listItem",RD="textStyle",zD=/^(\d+)\.\s$/,VD=tn.create({name:"orderedList",addOptions(){return{itemTypeName:"listItem",HTMLAttributes:{},keepMarks:!1,keepAttributes:!1}},group:"block list",content(){return`${this.options.itemTypeName}+`},addAttributes(){return{start:{default:1,parseHTML:t=>t.hasAttribute("start")?parseInt(t.getAttribute("start")||"",10):1},type:{default:null,parseHTML:t=>t.getAttribute("type")}}},parseHTML(){return[{tag:"ol"}]},renderHTML({HTMLAttributes:t}){const{start:e,...n}=t;return e===1?["ol",yt(this.options.HTMLAttributes,n),0]:["ol",yt(this.options.HTMLAttributes,t),0]},addCommands(){return{toggleOrderedList:()=>({commands:t,chain:e})=>this.options.keepAttributes?e().toggleList(this.name,this.options.itemTypeName,this.options.keepMarks).updateAttributes(cte,this.editor.getAttributes(RD)).run():t.toggleList(this.name,this.options.itemTypeName,this.options.keepMarks)}},addKeyboardShortcuts(){return{"Mod-Shift-7":()=>this.editor.commands.toggleOrderedList()}},addInputRules(){let t=Wa({find:zD,type:this.type,getAttributes:e=>({start:+e[1]}),joinPredicate:(e,n)=>n.childCount+n.attrs.start===+e[1]});return(this.options.keepMarks||this.options.keepAttributes)&&(t=Wa({find:zD,type:this.type,keepMarks:this.options.keepMarks,keepAttributes:this.options.keepAttributes,getAttributes:e=>({start:+e[1],...this.editor.getAttributes(RD)}),joinPredicate:(e,n)=>n.childCount+n.attrs.start===+e[1],editor:this.editor})),[t]}}),HD=tn.create({name:"paragraph",priority:1e3,addOptions(){return{HTMLAttributes:{}}},group:"block",content:"inline*",parseHTML(){return[{tag:"p"}]},renderHTML({HTMLAttributes:t}){return["p",yt(this.options.HTMLAttributes,t),0]},addCommands(){return{setParagraph:()=>({commands:t})=>t.setNode(this.name)}},addKeyboardShortcuts(){return{"Mod-Alt-0":()=>this.editor.commands.setParagraph()}}}),jD=sn.create({name:"placeholder",addOptions(){return{emptyEditorClass:"is-editor-empty",emptyNodeClass:"is-empty",placeholder:"Write something …",showOnlyWhenEditable:!0,showOnlyCurrent:!0,includeChildren:!1}},addProseMirrorPlugins(){return[new en({key:new bn("placeholder"),props:{decorations:({doc:t,selection:e})=>{const n=this.editor.isEditable||!this.options.showOnlyWhenEditable,{anchor:r}=e,o=[];if(!n)return null;const i=this.editor.isEmpty;return t.descendants((s,a)=>{const l=r>=a&&r<=a+s.nodeSize,u=!s.isLeaf&&xf(s);if((l||!this.options.showOnlyCurrent)&&u){const f=[this.options.emptyNodeClass];i&&f.push(this.options.emptyEditorClass);const p=Ln.node(a,a+s.nodeSize,{class:f.join(" "),"data-placeholder":typeof this.options.placeholder=="function"?this.options.placeholder({editor:this.editor,node:s,pos:a,hasAnchor:l}):this.options.placeholder});o.push(p)}return this.options.includeChildren}),Zt.create(t,o)}}})]}}),ute=/(?:^|\s)(~~(?!\s+~~)((?:[^~]+))~~(?!\s+~~))$/,dte=/(?:^|\s)(~~(?!\s+~~)((?:[^~]+))~~(?!\s+~~))/g,WD=ur.create({name:"strike",addOptions(){return{HTMLAttributes:{}}},parseHTML(){return[{tag:"s"},{tag:"del"},{tag:"strike"},{style:"text-decoration",consuming:!1,getAttrs:t=>t.includes("line-through")?{}:!1}]},renderHTML({HTMLAttributes:t}){return["s",yt(this.options.HTMLAttributes,t),0]},addCommands(){return{setStrike:()=>({commands:t})=>t.setMark(this.name),toggleStrike:()=>({commands:t})=>t.toggleMark(this.name),unsetStrike:()=>({commands:t})=>t.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-Shift-s":()=>this.editor.commands.toggleStrike()}},addInputRules(){return[Ls({find:ute,type:this.type})]},addPasteRules(){return[Vi({find:dte,type:this.type})]}}),fte=ur.create({name:"subscript",addOptions(){return{HTMLAttributes:{}}},parseHTML(){return[{tag:"sub"},{style:"vertical-align",getAttrs(t){return t!=="sub"?!1:null}}]},renderHTML({HTMLAttributes:t}){return["sub",yt(this.options.HTMLAttributes,t),0]},addCommands(){return{setSubscript:()=>({commands:t})=>t.setMark(this.name),toggleSubscript:()=>({commands:t})=>t.toggleMark(this.name),unsetSubscript:()=>({commands:t})=>t.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-,":()=>this.editor.commands.toggleSubscript()}}}),pte=ur.create({name:"superscript",addOptions(){return{HTMLAttributes:{}}},parseHTML(){return[{tag:"sup"},{style:"vertical-align",getAttrs(t){return t!=="super"?!1:null}}]},renderHTML({HTMLAttributes:t}){return["sup",yt(this.options.HTMLAttributes,t),0]},addCommands(){return{setSuperscript:()=>({commands:t})=>t.setMark(this.name),toggleSuperscript:()=>({commands:t})=>t.toggleMark(this.name),unsetSuperscript:()=>({commands:t})=>t.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-.":()=>this.editor.commands.toggleSuperscript()}}}),hte=tn.create({name:"tableCell",addOptions(){return{HTMLAttributes:{}}},content:"block+",addAttributes(){return{colspan:{default:1},rowspan:{default:1},colwidth:{default:null,parseHTML:t=>{const e=t.getAttribute("colwidth");return e?e.split(",").map(r=>parseInt(r,10)):null}}}},tableRole:"cell",isolating:!0,parseHTML(){return[{tag:"td"}]},renderHTML({HTMLAttributes:t}){return["td",yt(this.options.HTMLAttributes,t),0]}}),gte=tn.create({name:"tableHeader",addOptions(){return{HTMLAttributes:{}}},content:"block+",addAttributes(){return{colspan:{default:1},rowspan:{default:1},colwidth:{default:null,parseHTML:t=>{const e=t.getAttribute("colwidth");return e?e.split(",").map(r=>parseInt(r,10)):null}}}},tableRole:"header_cell",isolating:!0,parseHTML(){return[{tag:"th"}]},renderHTML({HTMLAttributes:t}){return["th",yt(this.options.HTMLAttributes,t),0]}}),mte=tn.create({name:"tableRow",addOptions(){return{HTMLAttributes:{}}},content:"(tableCell | tableHeader)*",tableRole:"row",parseHTML(){return[{tag:"tr"}]},renderHTML({HTMLAttributes:t}){return["tr",yt(this.options.HTMLAttributes,t),0]}}),yte=/^\s*(\[([( |x])?\])\s$/,bte=tn.create({name:"taskItem",addOptions(){return{nested:!1,HTMLAttributes:{},taskListTypeName:"taskList"}},content(){return this.options.nested?"paragraph block*":"paragraph+"},defining:!0,addAttributes(){return{checked:{default:!1,keepOnSplit:!1,parseHTML:t=>{const e=t.getAttribute("data-checked");return e===""||e==="true"},renderHTML:t=>({"data-checked":t.checked})}}},parseHTML(){return[{tag:`li[data-type="${this.name}"]`,priority:51}]},renderHTML({node:t,HTMLAttributes:e}){return["li",yt(this.options.HTMLAttributes,e,{"data-type":this.name}),["label",["input",{type:"checkbox",checked:t.attrs.checked?"checked":null}],["span"]],["div",0]]},addKeyboardShortcuts(){const t={Enter:()=>this.editor.commands.splitListItem(this.name),"Shift-Tab":()=>this.editor.commands.liftListItem(this.name)};return this.options.nested?{...t,Tab:()=>this.editor.commands.sinkListItem(this.name)}:t},addNodeView(){return({node:t,HTMLAttributes:e,getPos:n,editor:r})=>{const o=document.createElement("li"),i=document.createElement("label"),s=document.createElement("span"),a=document.createElement("input"),l=document.createElement("div");return i.contentEditable="false",a.type="checkbox",a.addEventListener("mousedown",u=>u.preventDefault()),a.addEventListener("change",u=>{if(!r.isEditable&&!this.options.onReadOnlyChecked){a.checked=!a.checked;return}const{checked:f}=u.target;r.isEditable&&typeof n=="function"&&r.chain().focus(void 0,{scrollIntoView:!1}).command(({tr:p})=>{const g=n();if(typeof g!="number")return!1;const m=p.doc.nodeAt(g);return p.setNodeMarkup(g,void 0,{...m==null?void 0:m.attrs,checked:f}),!0}).run(),!r.isEditable&&this.options.onReadOnlyChecked&&(this.options.onReadOnlyChecked(t,f)||(a.checked=!a.checked))}),Object.entries(this.options.HTMLAttributes).forEach(([u,f])=>{o.setAttribute(u,f)}),o.dataset.checked=t.attrs.checked,a.checked=t.attrs.checked,i.append(a,s),o.append(i,l),Object.entries(e).forEach(([u,f])=>{o.setAttribute(u,f)}),{dom:o,contentDOM:l,update:u=>u.type!==this.type?!1:(o.dataset.checked=u.attrs.checked,a.checked=u.attrs.checked,!0)}}},addInputRules(){return[Wa({find:yte,type:this.type,getAttributes:t=>({checked:t[t.length-1]==="x"})})]}}),vte=tn.create({name:"taskList",addOptions(){return{itemTypeName:"taskItem",HTMLAttributes:{}}},group:"block list",content(){return`${this.options.itemTypeName}+`},parseHTML(){return[{tag:`ul[data-type="${this.name}"]`,priority:51}]},renderHTML({HTMLAttributes:t}){return["ul",yt(this.options.HTMLAttributes,t,{"data-type":this.name}),0]},addCommands(){return{toggleTaskList:()=>({commands:t})=>t.toggleList(this.name,this.options.itemTypeName)}},addKeyboardShortcuts(){return{"Mod-Shift-9":()=>this.editor.commands.toggleTaskList()}}}),qD=tn.create({name:"text",group:"inline"}),xte=sn.create({name:"textAlign",addOptions(){return{types:[],alignments:["left","center","right","justify"],defaultAlignment:null}},addGlobalAttributes(){return[{types:this.options.types,attributes:{textAlign:{default:this.options.defaultAlignment,parseHTML:t=>{const e=t.style.textAlign;return this.options.alignments.includes(e)?e:this.options.defaultAlignment},renderHTML:t=>t.textAlign?{style:`text-align: ${t.textAlign}`}:{}}}}]},addCommands(){return{setTextAlign:t=>({commands:e})=>this.options.alignments.includes(t)?this.options.types.map(n=>e.updateAttributes(n,{textAlign:t})).every(n=>n):!1,unsetTextAlign:()=>({commands:t})=>this.options.types.map(e=>t.resetAttributes(e,"textAlign")).every(e=>e)}},addKeyboardShortcuts(){return{"Mod-Shift-l":()=>this.editor.commands.setTextAlign("left"),"Mod-Shift-e":()=>this.editor.commands.setTextAlign("center"),"Mod-Shift-r":()=>this.editor.commands.setTextAlign("right"),"Mod-Shift-j":()=>this.editor.commands.setTextAlign("justify")}}}),Ste=ur.create({name:"underline",addOptions(){return{HTMLAttributes:{}}},parseHTML(){return[{tag:"u"},{style:"text-decoration",consuming:!1,getAttrs:t=>t.includes("underline")?{}:!1}]},renderHTML({HTMLAttributes:t}){return["u",yt(this.options.HTMLAttributes,t),0]},addCommands(){return{setUnderline:()=>({commands:t})=>t.setMark(this.name),toggleUnderline:()=>({commands:t})=>t.toggleMark(this.name),unsetUnderline:()=>({commands:t})=>t.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-u":()=>this.editor.commands.toggleUnderline(),"Mod-U":()=>this.editor.commands.toggleUnderline()}}}),UD=J.forwardRef((t,e)=>{const[n,r]=J.useState(0),o=l=>{if(l>=t.items.length)return;const u=t.items[l],f={id:u.id,label:u.mentionLabel};t.command(f)},i=()=>{r((n+t.items.length-1)%t.items.length)},s=()=>{r((n+1)%t.items.length)},a=()=>{o(n)};return J.useEffect(()=>r(0),[t.items]),J.useImperativeHandle(e,()=>({onKeyDown:({event:l})=>l.key==="ArrowUp"?(i(),!0):l.key==="ArrowDown"?(s(),!0):l.key==="Enter"?(a(),!0):!1})),t.items.length>0?v.jsx(F.Paper,{elevation:5,children:v.jsx(F.List,{dense:!0,sx:{overflow:"hidden"},children:t.items.map((l,u)=>v.jsx(F.ListItem,{disablePadding:!0,children:v.jsx(F.ListItemButton,{selected:u===n,onClick:()=>o(u),children:l.mentionLabel})},l.id))})}):null});UD.displayName="SuggestionList";const KD={bottom:0,height:0,left:0,right:0,top:0,width:0,x:0,y:0,toJSON(){return{}}},Cte={items:async({query:t})=>Promise.resolve(["Lea Thompson","Cyndi Lauper","Tom Cruise","Madonna","Jerry Hall","Joan Collins","Winona Ryder","Christina Applegate","Alyssa Milano","Molly Ringwald","Ally Sheedy","Debbie Harry","Olivia Newton-John","Elton John","Michael J. Fox","Axl Rose","Emilio Estevez","Ralph Macchio","Rob Lowe","Jennifer Grey","Mickey Rourke","John Cusack","Matthew Broderick","Justine Bateman","Lisa Bonet","Benicio Monserrate Rafael del Toro Sánchez"].map((e,n)=>({mentionLabel:e,id:n.toString()})).filter(e=>e.mentionLabel.toLowerCase().startsWith(t.toLowerCase())).slice(0,5)),render:()=>{let t,e;return{onStart:n=>{t=new Q2(UD,{props:n,editor:n.editor}),e=Hc("body",{getReferenceClientRect:()=>{var r;return((r=n.clientRect)==null?void 0:r.call(n))??KD},appendTo:()=>document.body,content:t.element,showOnCreate:!0,interactive:!0,trigger:"manual",placement:"bottom-start"})[0]},onUpdate(n){t==null||t.updateProps(n),e==null||e.setProps({getReferenceClientRect:()=>{var r;return((r=n.clientRect)==null?void 0:r.call(n))??KD}})},onKeyDown(n){return n.event.key==="Escape"?(e==null||e.hide(),!0):t!=null&&t.ref?t.ref.onKeyDown(n):!1},onExit(){e==null||e.destroy(),t==null||t.destroy(),e=void 0,t=void 0}}}},wte=rte.extend({inclusive:!1}),_te=fte.extend({excludes:"superscript"}),Tte=pte.extend({excludes:"subscript"});function kte({placeholder:t}={}){return J.useMemo(()=>[YQ.configure({resizable:!0}),mte,gte,hte,sD,lD,cD,fD,BD,VD,HD,_te,Tte,qD,rD,nD,aD,SD,Ste,WD,wte.configure({autolink:!0,linkOnPaste:!0,openOnClick:!1}),WG,dD,zX,xte.configure({types:["heading","paragraph","image"]}),aee,lee,dee,BX,See.configure({multicolor:!0}),xD,KX,uD,vte,bte.configure({nested:!0}),lte.configure({suggestion:Cte}),jD.configure({placeholder:t}),vD],[t])}function YD(t){return Array.from(t).filter(e=>(e.type||"").toLowerCase().startsWith("image/"))}const Ete=t=>{const e=kte({placeholder:"Add your own content here..."});if(t.renderContentOnly)return v.jsx(mZ,{content:t.renderContentOnly,extensions:e});const{name:n,label:r,labelProps:o={fontSize:"0.9em",color:"#808080",fontWeight:"400"},onUploadFiles:i,readOnly:s=!1}=t,[a,l,u]=jt.useField({name:n}),{setValue:f}=u,{value:p}=a;J.useEffect(()=>{var C,T,_;(_=(T=(C=g==null?void 0:g.current)==null?void 0:C.editor)==null?void 0:T.commands)==null||_.setContent(p)},[p]);const g=J.useRef(null),m=J.useCallback((C,T)=>{var w;const _=(w=g.current)==null?void 0:w.editor;if(!(!_||!i))if(i instanceof Promise)i(C).then(E=>{Nv({images:E,editor:_,position:T})});else{const E=i(C);Nv({images:E,editor:_,position:T})}},[]),y=J.useCallback((C,T,_,w)=>{var O;if(!(T instanceof DragEvent)||!T.dataTransfer)return!1;const E=YD(T.dataTransfer.files);if(E.length>0){const L=(O=C.posAtCoords({left:T.clientX,top:T.clientY}))==null?void 0:O.pos;return m(E,L),T.preventDefault(),!0}return!1},[m]),b=J.useCallback((C,T,_)=>{if(!T.clipboardData)return!1;const w=YD(T.clipboardData.files);return w.length>0?(m(w),!0):!1},[m]),S=v.jsx(F.Box,{sx:{"& .ProseMirror":{"& h1, & h2, & h3, & h4, & h5, & h6":{scrollMarginTop:s?0:50}}},children:v.jsx(iI,{ref:g,extensions:e,content:p,editable:!s,editorProps:{handleDrop:y,handlePaste:b},renderControls:s?void 0:()=>v.jsx(GQ,{onUploadFiles:i}),onBlur:()=>{var C,T;return f(((T=(C=g.current)==null?void 0:C.editor)==null?void 0:T.getHTML())??"")},RichTextFieldProps:{variant:"outlined",MenuBarProps:{hide:s}},children:()=>v.jsxs(v.Fragment,{children:[v.jsx(C2,{}),v.jsx(sI,{})]})})});return v.jsxs(F.Box,{display:"flex",flexDirection:"column",children:[r&&v.jsx(F.Typography,{...o,children:r}),S]})},y1=t=>{const{title:e="Loading...",message:n}=t;return v.jsxs(F.Box,{className:"loading-page",sx:{gap:2},"data-testid":"loading-page",children:[v.jsxs(F.Box,{className:"text-content",children:[v.jsx(F.Typography,{variant:"h1","data-testid":"title",children:e}),n&&v.jsx(F.Typography,{"data-testid":"message",children:n})]}),v.jsx(F.CircularProgress,{size:75,"data-testid":"loading-spinner"})]})},GD=t=>{const{colSpan:e,isExpanded:n,renderExpand:r,obj:o,asMobileCard:i=!1,reRenderExpand:s=!1}=t,[a,l]=J.useState(!1),[u,f]=J.useState(void 0);return J.useEffect(()=>{n&&(!a||s)&&(l(!0),f(r(o)))},[n,o]),i?v.jsx(F.Box,{children:v.jsx(F.Collapse,{in:n,children:u})}):v.jsx(F.TableRow,{children:v.jsx(F.TableCell,{style:{paddingBottom:0,paddingTop:0},colSpan:e,children:v.jsx(F.Collapse,{in:n,children:u})})})},JD=t=>{const{id:e,getRowKey:n=W=>"id"in W&&(typeof W.id=="string"||typeof W.id=="number")?W.id:(console.warn(`Table: "id: string | number" not found in ${JSON.stringify(W)}. Please implement the Table.getRowKey prop so Table knows how to uniquely identify this row.`),JSON.stringify(W)),columns:r,data:o=[],onRowClick:i,renderExpand:s,hideColumnsOnMobile:a=[],sortField:l,sortOrder:u,onSortChange:f,allowSortCols:p,fixedLayout:g=!1,className:m,emptyTableMsg:y="No items to display",errorTableMsg:b,retryCallback:S,isLoading:C=!1,disableMobileCards:T=!1,highlightSelectedRow:_=!1,headerRowStyle:w={},stickyHeader:E,reRenderExpand:O=!1,...L}=t,{palette:P}=F.useTheme(),[$,M]=J.useState(void 0),[A,N]=J.useState(void 0);Array.isArray(g)&&g.length!==r.length&&console.error('Table component: Length of "fixedLayout" is not equal to the length of "columns".');const V=W=>{W!==l?f&&f(W,"asc"):f&&f(l,u==="asc"?"desc":"asc")},R=W=>l===W?u:null,B=F.useMediaQuery(F.useTheme().breakpoints.down("sm")),z=B&&a?r.filter(W=>!a.includes(W.fieldName)):r,q=(W,te)=>te.split(".").reduce((ue,ee)=>{if(ue&&typeof ue=="object")return ue[ee]},W),K=(W,te)=>{const ue=q(te,W.fieldName);return W.render?W.render(ue,te,B):ue},G=f!==void 0,Y=W=>G?p?p.includes(W):!0:!1,Z=v.jsxs(F.Box,{display:"flex",justifyContent:"center",alignItems:"center",flexDirection:"row",children:[v.jsx(MR,{})," ",y]}),me=v.jsxs(F.Box,{"data-testid":"table-fetch-error-msg",display:"flex",justifyContent:"center",alignItems:"center",flexDirection:"row",children:[v.jsx(dC,{color:"error"})," ",b,S&&v.jsx(F.Button,{variant:"text",onClick:S,children:"Retry?"})]}),he=()=>{if(C)return v.jsx(F.TableRow,{children:v.jsx(F.TableCell,{colSpan:r.length,align:"center",children:v.jsx(F.Box,{display:"flex",justifyContent:"center",alignItems:"center",flexDirection:"row",children:v.jsx(y1,{})})})});if(b)return v.jsx(F.TableRow,{children:v.jsx(F.TableCell,{colSpan:r.length,align:"center",children:me})});if(o.length===0)return v.jsx(F.TableRow,{children:v.jsx(F.TableCell,{colSpan:r.length,align:"center",children:Z})})},oe=()=>{if(C)return v.jsx(y1,{});if(b)return me;if(o.length===0)return Z},Q=W=>{_&&N(W)},fe=W=>{if(i&&(i(W),Q(W)),s){const te=$===W?void 0:W;M(te),Q(te)}},ce=typeof _=="string"?_:P.grey[P.mode=="dark"?600:50],ae=W=>{const te=A===n(W)?ce:"inherit";return{cursor:i||s?"pointer":"default",backgroundColor:te,...i&&{"&:hover":{backgroundColor:te===ce?ia(te,.1):ce}}}};return B&&!T?v.jsxs("div",{...e?{id:`mobile-table-${e}`}:{},className:m,"data-testid":"mui-table-mobile",children:[G&&v.jsxs(v.Fragment,{children:[v.jsxs(F.Box,{display:"flex",className:"MBv2_Table_Stack_Sort",children:[v.jsx(F.TextField,{select:!0,sx:{flexGrow:1},id:"demo-simple-select",size:"small",value:l??"",label:"Sort By...",onChange:W=>V(W.target.value),fullWidth:!0,children:z.map(W=>{if(Y(W.fieldName))return v.jsx(F.MenuItem,{value:W.sortName??W.fieldName,children:W.label??_n(W.fieldName)},`${W.key??"rowHeader"}-${W.fieldName}`)})}),v.jsx(F.IconButton,{onClick:()=>{l&&V(l)},children:v.jsx(BR,{className:`sort-icon-${u}`})})]}),v.jsx(F.Divider,{sx:{margin:"10px 0"}})]}),oe()??o.map(W=>v.jsxs(F.Card,{className:"MBv2_Table_Stack_Container",sx:{margin:"5px 0",padding:"5px",overflowX:"auto",...ae(W)},onClick:()=>fe(n(W)),"data-testid":`card-${n(W)}`,children:[v.jsx("table",{className:"MBv2_Table_Stack",children:v.jsx("tbody",{className:"MBv2_Table_Stack_Body",children:z.map(te=>v.jsxs("tr",{className:"MBv2_Table_Stack_Row",children:[v.jsx("td",{className:`MBv2_Table_Stack_Cell_Label MBv2_Table_Stack_Col_${te.fieldName}`,style:{textWrap:"nowrap"},children:te.label??_n(te.fieldName)}),v.jsx("td",{className:`MBv2_Table_Stack_Cell_Value MBv2_Table_Stack_Val_${te.fieldName}`,style:{paddingLeft:"10px"},children:K(te,W)})]},`${te.key??"row"}-${n(W)}-${te.fieldName}`))})}),s&&v.jsx(GD,{colSpan:r.length,isExpanded:n(W)===$,obj:W,renderExpand:te=>s(te),asMobileCard:!0})]},n(W)))]}):v.jsx(F.TableContainer,{component:F.Card,"data-testid":"mui-table",...e?{id:`table-${e}`}:{},className:m,style:E?{maxHeight:E,overflow:"auto"}:{},children:v.jsxs(F.Table,{stickyHeader:E!=="undefined",style:{tableLayout:g?"fixed":"auto"},className:"MBv2_Table",sx:w?{"& .MuiTableCell-head":{...w}}:{},...L,children:[v.jsx(F.TableHead,{className:"MBv2_Table_Head",children:v.jsx(F.TableRow,{className:"MBv2_Table_Head_Row",children:z.map((W,te)=>{const ue=Y(W.fieldName);return v.jsx(F.TableCell,{width:Array.isArray(g)?g[te]:"auto",sx:W.tableCellSx??{},children:v.jsx(F.Box,{style:{display:"flex",alignItems:"center"},children:v.jsxs(F.Box,{sx:[ue&&{"&:hover":{cursor:"pointer",backgroundColor:P.mode==="dark"?"#222222":"#ededed",borderRadius:2}}],style:{display:"flex",alignItems:"center",padding:"5px",paddingLeft:"6px",marginLeft:"-6px"},onClick:ue?()=>V(W.sortName??W.fieldName):void 0,children:[v.jsx("strong",{className:"MBv2_Table_Col_Label",style:{wordBreak:"normal"},children:W.label??_n(W.fieldName)}),ue&&R(W.fieldName)==="asc"&&v.jsx(RC,{style:{marginLeft:"5px"}}),ue&&R(W.fieldName)==="desc"&&v.jsx(OR,{style:{marginLeft:"5px"}}),ue&&R(W.fieldName)!=="asc"&&R(W.fieldName)!=="desc"&&v.jsx(LR,{style:{marginLeft:"5px"}})]})})},`${W.key??"rowHeader"}-${W.fieldName}`)})})}),v.jsx(F.TableBody,{className:"MBv2_Table_Body",children:he()??o.map(W=>v.jsxs(J.Fragment,{children:[v.jsx(F.TableRow,{"data-testid":`row-${n(W)}`,className:"MBv2_Table_Body_Row",onClick:()=>fe(n(W)),sx:ae(W),children:z.map(te=>v.jsx(F.TableCell,{className:`MBv2_Table_Body_Cell MBv2_Table_Body_Col_${te.fieldName}`,children:K(te,W)},`${te.key??"row"}-${n(W)}-${te.fieldName}`))}),s&&v.jsx(GD,{colSpan:r.length,isExpanded:n(W)===$,obj:W,renderExpand:te=>s(te),reRenderExpand:O})]},n(W)))})]})})},ZD=t=>{const{paginationState:e,onPageChange:n,onRowsPerPageChange:r,hidePaginationControls:o=!1,rowsPerPageOptions:i=[5,10,25],...s}=t,{pageNo:a,pageSize:l,totalCount:u,sortField:f,sortOrder:p}=e,g=S=>{n(S)},m=S=>{r(parseInt(S.target.value,10))},y=F.useMediaQuery(F.useTheme().breakpoints.down("sm")),b=!t.data||t.data&&t.data.length===0;return v.jsxs(F.Box,{children:[v.jsx(JD,{sortOrder:p,sortField:f,...s}),!o&&!b&&v.jsx(F.TablePagination,{"data-testid":"pagination-controls",component:"div",rowsPerPageOptions:y?[]:i,count:u,rowsPerPage:l,page:a,onPageChange:(S,C)=>g(C),onRowsPerPageChange:m,sx:{flexGrow:1,marginRight:{xs:0,md:15}}})]})},XD=()=>({height:window.innerHeight,width:window.innerWidth}),QD=()=>{const[t,e]=J.useState(XD());return J.useEffect(()=>{const n=()=>{e(XD())};return window.addEventListener("resize",n),()=>window.removeEventListener("resize",n)},[]),t},No=t=>{const{name:e="button",color:n="primary",fullWidthOnMobile:r=!0,type:o="button",variant:i="contained"}=t,{width:s}=QD(),a=["locationInBar","closeDialog","fullWidthOnMobile"],l=r&&s<600;return v.jsx(F.Button,{role:"button",name:e,color:n,variant:i,type:o,fullWidth:t.fullWidth?!0:l,...Jn({...t},a)})},Mte=t=>{const{title:e,onCancel:n,onNewCitation:r,onNewAttachment:o,onEditCitation:i,onEditAttachment:s,onDeleteCitation:a,onDownloadAttachment:l,onSelect:u,getCitationsPaginated:f,selectedIds:p,setSelectedIds:g,onError:m=()=>{},setError:y,setSuccess:b,condenseTable:S=!1,canCreate:C=!1,canSelect:T=!1,addlActions:_}=t,{palette:w}=F.useTheme(),[E,O]=J.useState([]),[L,P]=J.useState(!1),[$,M]=J.useState(!0),[A,N]=J.useState(null),[V,R]=J.useState(null),[B,z]=J.useState({pageNo:0,pageSize:5,totalCount:0}),q=()=>{P(!1),M(!0),f({pageNo:B.pageNo,pageSize:B.pageSize}).then(oe=>(O(oe.data),z({...B,totalCount:oe.totalCount}),oe)).catch(oe=>{m(oe),P(!0),O([])}).finally(()=>M(!1))};J.useEffect(q,[B.pageNo,B.pageSize]);const K=()=>{R(null),N(null)},G=v.jsx(No,{variant:T?"outlined":"contained",size:T?"small":"medium",onClick:r,startIcon:v.jsx(Ju,{}),children:"Add Citation"}),Y=v.jsx(No,{variant:T?"outlined":"contained",size:T?"small":"medium",onClick:o,startIcon:v.jsx(BC,{}),children:"Add Attachment"}),Z=oe=>v.jsx(F.IconButton,{color:"primary",onClick:()=>oe.fileName?s(oe):i(oe),"data-testid":`citation-table_edit-btn-${oe.id}`,children:v.jsx(uR,{})}),me=oe=>{if(a)return v.jsx(F.IconButton,{color:"error",onClick:Q=>{R(oe.id),N(Q.currentTarget)},"data-testid":`citation-table_delete-btn-${oe.id}`,children:v.jsx(qh,{})})},he=oe=>{if(l)return v.jsx(F.IconButton,{color:"primary",onClick:()=>{l(oe).catch(Q=>y({title:`Failed to download ${oe.fileName}`,err:Q}))},"data-testid":`citation-table_download-btn-${oe.id}`,sx:{visibility:oe.fileName?"visible":"hidden"},children:v.jsx(cR,{})})};return v.jsxs(v.Fragment,{children:[v.jsxs(F.Box,{display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center",paddingBottom:"10px",children:[v.jsx(F.Typography,{variant:S?"h6":"h2",children:e}),!T&&C&&v.jsxs(F.Box,{display:"flex",flexDirection:"row",gap:1,children:[G,Y]})]}),v.jsx(ZD,{"data-testid":"citation-table",title:e,size:S?"x-small":"medium",isLoading:$,columns:[...T?[{fieldName:"id",key:"select",label:"",render:(oe,Q)=>v.jsx(F.Checkbox,{"data-testid":`citation-table_checkbox-${oe}`,onChange:()=>{const fe=p.includes(Q.id);g(fe?p.filter(ce=>ce!==Q.id):[...p,Q.id])},checked:p.includes(oe)})}]:[],{fieldName:"fileName",key:"CitationOrAttachment",label:"Type",render:(oe,Q)=>v.jsx(F.Tooltip,{title:oe?"Attachment":"URL",children:oe?v.jsx(BC,{sx:{color:w.grey[500],marginTop:"4px"},"data-testid":`attachment-icon-${Q.id}`}):v.jsx(Ju,{sx:{color:w.grey[500],marginTop:"6px"},"data-testid":`url-icon-${Q.id}`})})},{fieldName:"title",tableCellSx:{width:S?"100%":"auto"}},...S?[]:[{fieldName:"fileName",key:"URL/File Name",label:"URL/File Name",render:(oe,Q)=>v.jsx("span",{style:{wordBreak:"break-all"},children:oe||Q.url})},{fieldName:"source"},{fieldName:"accessedAt",render:(oe,Q)=>{if(!Q.fileName)return(oe==null?void 0:oe.slice(0,10))??""}},{fieldName:"classification"}],{fieldName:"id",key:"Action",label:"Action",render:(oe,Q)=>v.jsxs(F.Box,{display:"flex",flexDirection:"row",children:[he(Q),Z(Q),me(Q),_==null?void 0:_(Q),v.jsx(F.Popper,{open:V===oe,anchorEl:A,placement:"bottom-end",style:{zIndex:1300},children:v.jsxs(F.Box,{component:F.Paper,p:1,display:"flex",gap:1,boxShadow:9,"data-testid":`citation-table_delete-prompt-${oe}`,children:[v.jsxs(F.Typography,{variant:"body2",children:["Are you sure you want to delete this"," ",Q.fileName?"attachment":"citation","?"]}),v.jsxs(F.Box,{display:"flex",flexDirection:"row",children:[v.jsx(No,{size:"small",variant:"text",onClick:K,"data-testid":`citation-table_delete-prompt-${oe}-noBtn`,children:"No"}),v.jsx(No,{size:"small",color:"error",startIcon:v.jsx(qh,{}),onClick:()=>{a==null||a(oe).then(()=>{q(),g(p.filter(fe=>fe!==oe)),b(`Successfully deleted "${Q.title}"`)}).catch(fe=>y({title:`Failed to delete ${Q.fileName?"attachment":"citation"}`,err:fe})).finally(K)},"data-testid":`citation-table_delete-prompt-${oe}-yesBtn`,children:"Yes"})]})]})})]})}],data:E,paginationState:B,onPageChange:oe=>z({...B,pageNo:oe}),onRowsPerPageChange:oe=>z({...B,pageSize:oe,pageNo:0}),errorTableMsg:L?"Failed to load citations.":void 0,retryCallback:q}),T&&v.jsxs(F.Box,{display:"flex",flexDirection:"row",justifyContent:"space-between",marginTop:"20px",children:[v.jsx(F.Box,{display:"flex",flexDirection:"row",gap:".25rem",children:C&&v.jsxs(v.Fragment,{children:[G,Y]})}),v.jsxs(F.Box,{display:"flex",flexDirection:"row",gap:".25rem",children:[v.jsx(No,{variant:"outlined",size:"small",onClick:n,children:"Cancel"}),v.jsxs(No,{variant:"contained",size:"small",onClick:()=>u(p),children:["Select",p.length>0&&` (${p.length})`]})]})]})]})},b1=t=>{const{loading:e=!1,type:n="submit",size:r="medium",...o}=t,s={small:16,medium:20,large:24}[r];return v.jsx(No,{type:n,disabled:e,size:r,startIcon:e?v.jsx(F.CircularProgress,{size:s,color:"inherit"}):null,...o})},Ote=t=>{const{id:e,title:n,onSave:r,onCancel:o,getCitationById:i,setError:s}=t,a=J.useRef(null),[l,u]=J.useState(!0),[f,p]=J.useState({type:"Url",source:"",title:"",accessedAt:null,url:"",classification:""});J.useEffect(()=>{if(e===void 0){u(!1);return}i(e).then(m=>{p({...m,type:"Url"}),u(!1)}).catch(m=>{u(!1),s({title:"Failed to retrieve citation",err:m})})},[]);const g=()=>{var y,b,S;const m=(b=(y=a==null?void 0:a.current)==null?void 0:y.values)==null?void 0:b.url;m&&((S=a==null?void 0:a.current)==null||S.setFieldValue("url",s2(m)))};return v.jsxs(v.Fragment,{children:[n&&v.jsx(F.Typography,{variant:"h6",margin:"10px 0",children:n}),v.jsx(jt.Formik,{innerRef:a,enableReinitialize:!0,initialValues:f,onSubmit:async m=>{u(!0),r(m).catch(y=>{u(!1),s({title:`Failed to ${e===void 0?"save":"update"} citation`,err:y})}).finally(()=>u(!1))},children:v.jsxs(jt.Form,{autoComplete:"off",children:[v.jsx(da,{name:"source",disabled:l,required:!0,margin:"none"}),v.jsx(da,{name:"title",disabled:l,required:!0,margin:"none"}),v.jsx(Fd,{name:"accessedAt",disabled:l,required:!0,margin:"none",isDatePicker:!0}),v.jsx(da,{name:"url",disabled:l,required:!0,onBlur:g,margin:"none"}),v.jsx(FC,{row:!0,name:"classification",required:!0,radios:[{label:"Public Source",value:"Public Source"},{label:"Proprietary Source",value:"Proprietary Source"}],margin:"none"}),v.jsxs(F.DialogActions,{sx:{px:0},children:[v.jsx(F.Button,{onClick:o,variant:"outlined",size:"small",children:"Cancel"}),v.jsx(b1,{size:"small",loading:l,children:e?"Update Citation":"Add New Citation"})]})]})})]})};var v1,eP;function Ate(){if(eP)return v1;eP=1;function t(C){this._maxSize=C,this.clear()}t.prototype.clear=function(){this._size=0,this._values=Object.create(null)},t.prototype.get=function(C){return this._values[C]},t.prototype.set=function(C,T){return this._size>=this._maxSize&&this.clear(),C in this._values||this._size++,this._values[C]=T};var e=/[^.^\]^[]+|(?=\[\]|\.\.)/g,n=/^\d+$/,r=/^\d/,o=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,i=/^\s*(['"]?)(.*?)(\1)\s*$/,s=512,a=new t(s),l=new t(s),u=new t(s);v1={Cache:t,split:p,normalizePath:f,setter:function(C){var T=f(C);return l.get(C)||l.set(C,function(w,E){for(var O=0,L=T.length,P=w;O<L-1;){var $=T[O];if($==="__proto__"||$==="constructor"||$==="prototype")return w;P=P[T[O++]]}P[T[O]]=E})},getter:function(C,T){var _=f(C);return u.get(C)||u.set(C,function(E){for(var O=0,L=_.length;O<L;)if(E!=null||!T)E=E[_[O++]];else return;return E})},join:function(C){return C.reduce(function(T,_){return T+(m(_)||n.test(_)?"["+_+"]":(T?".":"")+_)},"")},forEach:function(C,T,_){g(Array.isArray(C)?C:p(C),T,_)}};function f(C){return a.get(C)||a.set(C,p(C).map(function(T){return T.replace(i,"$2")}))}function p(C){return C.match(e)||[""]}function g(C,T,_){var w=C.length,E,O,L,P;for(O=0;O<w;O++)E=C[O],E&&(S(E)&&(E='"'+E+'"'),P=m(E),L=!P&&/^\d+$/.test(E),T.call(_,E,P,L,O,C))}function m(C){return typeof C=="string"&&C&&["'",'"'].indexOf(C.charAt(0))!==-1}function y(C){return C.match(r)&&!C.match(n)}function b(C){return o.test(C)}function S(C){return!m(C)&&(y(C)||b(C))}return v1}var qs=Ate(),x1,tP;function Ite(){if(tP)return x1;tP=1;const t=/[A-Z\xc0-\xd6\xd8-\xde]?[a-z\xdf-\xf6\xf8-\xff]+(?:['’](?:d|ll|m|re|s|t|ve))?(?=[\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000]|[A-Z\xc0-\xd6\xd8-\xde]|$)|(?:[A-Z\xc0-\xd6\xd8-\xde]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])+(?:['’](?:D|LL|M|RE|S|T|VE))?(?=[\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000]|[A-Z\xc0-\xd6\xd8-\xde](?:[a-z\xdf-\xf6\xf8-\xff]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])|$)|[A-Z\xc0-\xd6\xd8-\xde]?(?:[a-z\xdf-\xf6\xf8-\xff]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])+(?:['’](?:d|ll|m|re|s|t|ve))?|[A-Z\xc0-\xd6\xd8-\xde]+(?:['’](?:D|LL|M|RE|S|T|VE))?|\d*(?:1ST|2ND|3RD|(?![123])\dTH)(?=\b|[a-z_])|\d*(?:1st|2nd|3rd|(?![123])\dth)(?=\b|[A-Z_])|\d+|(?:[\u2700-\u27bf]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff])[\ufe0e\ufe0f]?(?:[\u0300-\u036f\ufe20-\ufe2f\u20d0-\u20ff]|\ud83c[\udffb-\udfff])?(?:\u200d(?:[^\ud800-\udfff]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff])[\ufe0e\ufe0f]?(?:[\u0300-\u036f\ufe20-\ufe2f\u20d0-\u20ff]|\ud83c[\udffb-\udfff])?)*/g,e=f=>f.match(t)||[],n=f=>f[0].toUpperCase()+f.slice(1),r=(f,p)=>e(f).join(p).toLowerCase(),o=f=>e(f).reduce((p,g)=>`${p}${p?g[0].toUpperCase()+g.slice(1).toLowerCase():g.toLowerCase()}`,"");return x1={words:e,upperFirst:n,camelCase:o,pascalCase:f=>n(o(f)),snakeCase:f=>r(f,"_"),kebabCase:f=>r(f,"-"),sentenceCase:f=>n(r(f," ")),titleCase:f=>e(f).map(n).join(" ")},x1}var S1=Ite(),Tp={exports:{}},nP;function Dte(){if(nP)return Tp.exports;nP=1,Tp.exports=function(o){return t(e(o),o)},Tp.exports.array=t;function t(o,i){var s=o.length,a=new Array(s),l={},u=s,f=n(i),p=r(o);for(i.forEach(function(m){if(!p.has(m[0])||!p.has(m[1]))throw new Error("Unknown node. There is an unknown node in the supplied edges.")});u--;)l[u]||g(o[u],u,new Set);return a;function g(m,y,b){if(b.has(m)){var S;try{S=", node was:"+JSON.stringify(m)}catch{S=""}throw new Error("Cyclic dependency"+S)}if(!p.has(m))throw new Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(m));if(!l[y]){l[y]=!0;var C=f.get(m)||new Set;if(C=Array.from(C),y=C.length){b.add(m);do{var T=C[--y];g(T,p.get(T),b)}while(y);b.delete(m)}a[--s]=m}}}function e(o){for(var i=new Set,s=0,a=o.length;s<a;s++){var l=o[s];i.add(l[0]),i.add(l[1])}return Array.from(i)}function n(o){for(var i=new Map,s=0,a=o.length;s<a;s++){var l=o[s];i.has(l[0])||i.set(l[0],new Set),i.has(l[1])||i.set(l[1],new Set),i.get(l[0]).add(l[1])}return i}function r(o){for(var i=new Map,s=0,a=o.length;s<a;s++)i.set(o[s],s);return i}return Tp.exports}var Pte=Dte();const Nte=Zn(Pte),Lte=Object.prototype.toString,Fte=Error.prototype.toString,$te=RegExp.prototype.toString,Bte=typeof Symbol<"u"?Symbol.prototype.toString:()=>"",Rte=/^Symbol\((.*)\)(.*)$/;function zte(t){return t!=+t?"NaN":t===0&&1/t<0?"-0":""+t}function rP(t,e=!1){if(t==null||t===!0||t===!1)return""+t;const n=typeof t;if(n==="number")return zte(t);if(n==="string")return e?`"${t}"`:t;if(n==="function")return"[Function "+(t.name||"anonymous")+"]";if(n==="symbol")return Bte.call(t).replace(Rte,"Symbol($1)");const r=Lte.call(t).slice(8,-1);return r==="Date"?isNaN(t.getTime())?""+t:t.toISOString(t):r==="Error"||t instanceof Error?"["+Fte.call(t)+"]":r==="RegExp"?$te.call(t):null}function Ji(t,e){let n=rP(t,e);return n!==null?n:JSON.stringify(t,function(r,o){let i=rP(this[r],e);return i!==null?i:o},2)}function oP(t){return t==null?[]:[].concat(t)}let iP,sP,aP,Vte=/\$\{\s*(\w+)\s*\}/g;iP=Symbol.toStringTag;class lP{constructor(e,n,r,o){this.name=void 0,this.message=void 0,this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=void 0,this.inner=void 0,this[iP]="Error",this.name="ValidationError",this.value=n,this.path=r,this.type=o,this.errors=[],this.inner=[],oP(e).forEach(i=>{if(fr.isError(i)){this.errors.push(...i.errors);const s=i.inner.length?i.inner:[i];this.inner.push(...s)}else this.errors.push(i)}),this.message=this.errors.length>1?`${this.errors.length} errors occurred`:this.errors[0]}}sP=Symbol.hasInstance,aP=Symbol.toStringTag;class fr extends Error{static formatError(e,n){const r=n.label||n.path||"this";return n=Object.assign({},n,{path:r,originalPath:n.path}),typeof e=="string"?e.replace(Vte,(o,i)=>Ji(n[i])):typeof e=="function"?e(n):e}static isError(e){return e&&e.name==="ValidationError"}constructor(e,n,r,o,i){const s=new lP(e,n,r,o);if(i)return s;super(),this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=[],this.inner=[],this[aP]="Error",this.name=s.name,this.message=s.message,this.type=s.type,this.value=s.value,this.path=s.path,this.errors=s.errors,this.inner=s.inner,Error.captureStackTrace&&Error.captureStackTrace(this,fr)}static[sP](e){return lP[Symbol.hasInstance](e)||super[Symbol.hasInstance](e)}}let Lo={default:"${path} is invalid",required:"${path} is a required field",defined:"${path} must be defined",notNull:"${path} cannot be null",oneOf:"${path} must be one of the following values: ${values}",notOneOf:"${path} must not be one of the following values: ${values}",notType:({path:t,type:e,value:n,originalValue:r})=>{const o=r!=null&&r!==n?` (cast from the value \`${Ji(r,!0)}\`).`:".";return e!=="mixed"?`${t} must be a \`${e}\` type, but the final value was: \`${Ji(n,!0)}\``+o:`${t} must match the configured type. The validated value was: \`${Ji(n,!0)}\``+o}},pr={length:"${path} must be exactly ${length} characters",min:"${path} must be at least ${min} characters",max:"${path} must be at most ${max} characters",matches:'${path} must match the following: "${regex}"',email:"${path} must be a valid email",url:"${path} must be a valid URL",uuid:"${path} must be a valid UUID",datetime:"${path} must be a valid ISO date-time",datetime_precision:"${path} must be a valid ISO date-time with a sub-second precision of exactly ${precision} digits",datetime_offset:'${path} must be a valid ISO date-time with UTC "Z" timezone',trim:"${path} must be a trimmed string",lowercase:"${path} must be a lowercase string",uppercase:"${path} must be a upper case string"},Hte={min:"${path} must be greater than or equal to ${min}",max:"${path} must be less than or equal to ${max}",lessThan:"${path} must be less than ${less}",moreThan:"${path} must be greater than ${more}",positive:"${path} must be a positive number",negative:"${path} must be a negative number",integer:"${path} must be an integer"},C1={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"},jte={isValue:"${path} field must be ${value}"},kp={noUnknown:"${path} field has unspecified keys: ${unknown}",exact:"${path} object contains unknown properties: ${properties}"};Object.assign(Object.create(null),{mixed:Lo,string:pr,number:Hte,date:C1,object:kp,array:{min:"${path} field must have at least ${min} items",max:"${path} field must have less than or equal to ${max} items",length:"${path} must have ${length} items"},boolean:jte,tuple:{notType:t=>{const{path:e,value:n,spec:r}=t,o=r.types.length;if(Array.isArray(n)){if(n.length<o)return`${e} tuple value has too few items, expected a length of ${o} but got ${n.length} for value: \`${Ji(n,!0)}\``;if(n.length>o)return`${e} tuple value has too many items, expected a length of ${o} but got ${n.length} for value: \`${Ji(n,!0)}\``}return fr.formatError(Lo.notType,t)}}});const w1=t=>t&&t.__isYupSchema__;class Ep{static fromOptions(e,n){if(!n.then&&!n.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");let{is:r,then:o,otherwise:i}=n,s=typeof r=="function"?r:(...a)=>a.every(l=>l===r);return new Ep(e,(a,l)=>{var u;let f=s(...a)?o:i;return(u=f==null?void 0:f(l))!=null?u:l})}constructor(e,n){this.fn=void 0,this.refs=e,this.refs=e,this.fn=n}resolve(e,n){let r=this.refs.map(i=>i.getValue(n==null?void 0:n.value,n==null?void 0:n.parent,n==null?void 0:n.context)),o=this.fn(r,e,n);if(o===void 0||o===e)return e;if(!w1(o))throw new TypeError("conditions must return a schema object");return o.resolve(n)}}const Mp={context:"$",value:"."};class Us{constructor(e,n={}){if(this.key=void 0,this.isContext=void 0,this.isValue=void 0,this.isSibling=void 0,this.path=void 0,this.getter=void 0,this.map=void 0,typeof e!="string")throw new TypeError("ref must be a string, got: "+e);if(this.key=e.trim(),e==="")throw new TypeError("ref must be a non-empty string");this.isContext=this.key[0]===Mp.context,this.isValue=this.key[0]===Mp.value,this.isSibling=!this.isContext&&!this.isValue;let r=this.isContext?Mp.context:this.isValue?Mp.value:"";this.path=this.key.slice(r.length),this.getter=this.path&&qs.getter(this.path,!0),this.map=n.map}getValue(e,n,r){let o=this.isContext?r:this.isValue?e:n;return this.getter&&(o=this.getter(o||{})),this.map&&(o=this.map(o)),o}cast(e,n){return this.getValue(e,n==null?void 0:n.parent,n==null?void 0:n.context)}resolve(){return this}describe(){return{type:"ref",key:this.key}}toString(){return`Ref(${this.key})`}static isRef(e){return e&&e.__isYupRef}}Us.prototype.__isYupRef=!0;const Ks=t=>t==null;function tl(t){function e({value:n,path:r="",options:o,originalValue:i,schema:s},a,l){const{name:u,test:f,params:p,message:g,skipAbsent:m}=t;let{parent:y,context:b,abortEarly:S=s.spec.abortEarly,disableStackTrace:C=s.spec.disableStackTrace}=o;function T(A){return Us.isRef(A)?A.getValue(n,y,b):A}function _(A={}){const N=Object.assign({value:n,originalValue:i,label:s.spec.label,path:A.path||r,spec:s.spec,disableStackTrace:A.disableStackTrace||C},p,A.params);for(const R of Object.keys(N))N[R]=T(N[R]);const V=new fr(fr.formatError(A.message||g,N),n,N.path,A.type||u,N.disableStackTrace);return V.params=N,V}const w=S?a:l;let E={path:r,parent:y,type:u,from:o.from,createError:_,resolve:T,options:o,originalValue:i,schema:s};const O=A=>{fr.isError(A)?w(A):A?l(null):w(_())},L=A=>{fr.isError(A)?w(A):a(A)};if(m&&Ks(n))return O(!0);let $;try{var M;if($=f.call(E,n,E),typeof((M=$)==null?void 0:M.then)=="function"){if(o.sync)throw new Error(`Validation test of type: "${E.type}" returned a Promise during a synchronous validate. This test will finish after the validate call has returned`);return Promise.resolve($).then(O,L)}}catch(A){L(A);return}O($)}return e.OPTIONS=t,e}function Wte(t,e,n,r=n){let o,i,s;return e?(qs.forEach(e,(a,l,u)=>{let f=l?a.slice(1,a.length-1):a;t=t.resolve({context:r,parent:o,value:n});let p=t.type==="tuple",g=u?parseInt(f,10):0;if(t.innerType||p){if(p&&!u)throw new Error(`Yup.reach cannot implicitly index into a tuple type. the path part "${s}" must contain an index to the tuple element, e.g. "${s}[0]"`);if(n&&g>=n.length)throw new Error(`Yup.reach cannot resolve an array item at index: ${a}, in the path: ${e}. because there is no value at that index. `);o=n,n=n&&n[g],t=p?t.spec.types[g]:t.innerType}if(!u){if(!t.fields||!t.fields[f])throw new Error(`The schema does not contain the path: ${e}. (failed at: ${s} which is a type: "${t.type}")`);o=n,n=n&&n[f],t=t.fields[f]}i=f,s=l?"["+a+"]":"."+a}),{schema:t,parent:o,parentPath:i}):{parent:o,parentPath:e,schema:t}}class Op extends Set{describe(){const e=[];for(const n of this.values())e.push(Us.isRef(n)?n.describe():n);return e}resolveAll(e){let n=[];for(const r of this.values())n.push(e(r));return n}clone(){return new Op(this.values())}merge(e,n){const r=this.clone();return e.forEach(o=>r.add(o)),n.forEach(o=>r.delete(o)),r}}function nl(t,e=new Map){if(w1(t)||!t||typeof t!="object")return t;if(e.has(t))return e.get(t);let n;if(t instanceof Date)n=new Date(t.getTime()),e.set(t,n);else if(t instanceof RegExp)n=new RegExp(t),e.set(t,n);else if(Array.isArray(t)){n=new Array(t.length),e.set(t,n);for(let r=0;r<t.length;r++)n[r]=nl(t[r],e)}else if(t instanceof Map){n=new Map,e.set(t,n);for(const[r,o]of t.entries())n.set(r,nl(o,e))}else if(t instanceof Set){n=new Set,e.set(t,n);for(const r of t)n.add(nl(r,e))}else if(t instanceof Object){n={},e.set(t,n);for(const[r,o]of Object.entries(t))n[r]=nl(o,e)}else throw Error(`Unable to clone ${t}`);return n}class Fo{constructor(e){this.type=void 0,this.deps=[],this.tests=void 0,this.transforms=void 0,this.conditions=[],this._mutate=void 0,this.internalTests={},this._whitelist=new Op,this._blacklist=new Op,this.exclusiveTests=Object.create(null),this._typeCheck=void 0,this.spec=void 0,this.tests=[],this.transforms=[],this.withMutation(()=>{this.typeError(Lo.notType)}),this.type=e.type,this._typeCheck=e.check,this.spec=Object.assign({strip:!1,strict:!1,abortEarly:!0,recursive:!0,disableStackTrace:!1,nullable:!1,optional:!0,coerce:!0},e==null?void 0:e.spec),this.withMutation(n=>{n.nonNullable()})}get _type(){return this.type}clone(e){if(this._mutate)return e&&Object.assign(this.spec,e),this;const n=Object.create(Object.getPrototypeOf(this));return n.type=this.type,n._typeCheck=this._typeCheck,n._whitelist=this._whitelist.clone(),n._blacklist=this._blacklist.clone(),n.internalTests=Object.assign({},this.internalTests),n.exclusiveTests=Object.assign({},this.exclusiveTests),n.deps=[...this.deps],n.conditions=[...this.conditions],n.tests=[...this.tests],n.transforms=[...this.transforms],n.spec=nl(Object.assign({},this.spec,e)),n}label(e){let n=this.clone();return n.spec.label=e,n}meta(...e){if(e.length===0)return this.spec.meta;let n=this.clone();return n.spec.meta=Object.assign(n.spec.meta||{},e[0]),n}withMutation(e){let n=this._mutate;this._mutate=!0;let r=e(this);return this._mutate=n,r}concat(e){if(!e||e===this)return this;if(e.type!==this.type&&this.type!=="mixed")throw new TypeError(`You cannot \`concat()\` schema's of different types: ${this.type} and ${e.type}`);let n=this,r=e.clone();const o=Object.assign({},n.spec,r.spec);return r.spec=o,r.internalTests=Object.assign({},n.internalTests,r.internalTests),r._whitelist=n._whitelist.merge(e._whitelist,e._blacklist),r._blacklist=n._blacklist.merge(e._blacklist,e._whitelist),r.tests=n.tests,r.exclusiveTests=n.exclusiveTests,r.withMutation(i=>{e.tests.forEach(s=>{i.test(s.OPTIONS)})}),r.transforms=[...n.transforms,...r.transforms],r}isType(e){return e==null?!!(this.spec.nullable&&e===null||this.spec.optional&&e===void 0):this._typeCheck(e)}resolve(e){let n=this;if(n.conditions.length){let r=n.conditions;n=n.clone(),n.conditions=[],n=r.reduce((o,i)=>i.resolve(o,e),n),n=n.resolve(e)}return n}resolveOptions(e){var n,r,o,i;return Object.assign({},e,{from:e.from||[],strict:(n=e.strict)!=null?n:this.spec.strict,abortEarly:(r=e.abortEarly)!=null?r:this.spec.abortEarly,recursive:(o=e.recursive)!=null?o:this.spec.recursive,disableStackTrace:(i=e.disableStackTrace)!=null?i:this.spec.disableStackTrace})}cast(e,n={}){let r=this.resolve(Object.assign({value:e},n)),o=n.assert==="ignore-optionality",i=r._cast(e,n);if(n.assert!==!1&&!r.isType(i)){if(o&&Ks(i))return i;let s=Ji(e),a=Ji(i);throw new TypeError(`The value of ${n.path||"field"} could not be cast to a value that satisfies the schema type: "${r.type}".
|
|
400
|
+
3. "-" cannot repeat`);Kt.customSchemes.push([t,e])}function Zee(){Kt.scanner=jee(Kt.customSchemes);for(let t=0;t<Kt.tokenQueue.length;t++)Kt.tokenQueue[t][1]({scanner:Kt.scanner});Kt.parser=Uee(Kt.scanner.tokens);for(let t=0;t<Kt.pluginQueue.length;t++)Kt.pluginQueue[t][1]({scanner:Kt.scanner,parser:Kt.parser});return Kt.initialized=!0,Kt}function m1(t){return Kt.initialized||Zee(),Kee(Kt.parser.start,t,AD(Kt.scanner.start,t))}m1.scan=AD;function $D(t,e=null,n=null){if(e&&typeof e=="object"){if(n)throw Error(`linkifyjs: Invalid link type ${e}; must be a string`);n=e,e=null}const r=new h1(n),o=m1(t),i=[];for(let s=0;s<o.length;s++){const a=o[s];a.isLink&&(!e||a.t===e)&&r.check(a)&&i.push(a.toFormattedObject(r))}return i}function Xee(t){return t.length===1?t[0].isLink:t.length===3&&t[1].isLink?["()","[]"].includes(t[0].value+t[2].value):!1}function Qee(t){return new en({key:new bn("autolink"),appendTransaction:(e,n,r)=>{const o=e.some(u=>u.docChanged)&&!n.doc.eq(r.doc),i=e.some(u=>u.getMeta("preventAutolink"));if(!o||i)return;const{tr:s}=r,a=gK(n.doc,[...e]);if(SK(a).forEach(({newRange:u})=>{const f=yK(r.doc,u,m=>m.isTextblock);let p,g;if(f.length>1?(p=f[0],g=r.doc.textBetween(p.pos,p.pos+p.node.nodeSize,void 0," ")):f.length&&r.doc.textBetween(u.from,u.to," "," ").endsWith(" ")&&(p=f[0],g=r.doc.textBetween(p.pos,u.to,void 0," ")),p&&g){const m=g.split(" ").filter(C=>C!=="");if(m.length<=0)return!1;const y=m[m.length-1],b=p.pos+g.lastIndexOf(y);if(!y)return!1;const S=m1(y).map(C=>C.toObject(t.defaultProtocol));if(!Xee(S))return!1;S.filter(C=>C.isLink).map(C=>({...C,from:b+C.start+1,to:b+C.end+1})).filter(C=>r.schema.marks.code?!r.doc.rangeHasMark(C.from,C.to,r.schema.marks.code):!0).filter(C=>t.validate(C.value)).filter(C=>t.shouldAutoLink(C.value)).forEach(C=>{oy(C.from,C.to,r.doc).some(T=>T.mark.type===t.type)||s.addMark(C.from,C.to,t.type.create({href:C.href}))})}}),!!s.steps.length)return s}})}function ete(t){return new en({key:new bn("handleClickLink"),props:{handleClick:(e,n,r)=>{var o,i;if(r.button!==0||!e.editable)return!1;let s=r.target;const a=[];for(;s.nodeName!=="DIV";)a.push(s),s=s.parentNode;if(!a.find(g=>g.nodeName==="A"))return!1;const l=ry(e.state,t.type.name),u=r.target,f=(o=u==null?void 0:u.href)!==null&&o!==void 0?o:l.href,p=(i=u==null?void 0:u.target)!==null&&i!==void 0?i:l.target;return u&&f?(window.open(f,p),!0):!1}}})}function tte(t){return new en({key:new bn("handlePasteLink"),props:{handlePaste:(e,n,r)=>{const{state:o}=e,{selection:i}=o,{empty:s}=i;if(s)return!1;let a="";r.content.forEach(u=>{a+=u.textContent});const l=$D(a,{defaultProtocol:t.defaultProtocol}).find(u=>u.isLink&&u.value===a);return!a||!l?!1:t.editor.commands.setMark(t.type,{href:l.href})}}})}const nte=/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g;function Ws(t,e){const n=["http","https","ftp","ftps","mailto","tel","callto","sms","cid","xmpp"];return e&&e.forEach(r=>{const o=typeof r=="string"?r:r.scheme;o&&n.push(o)}),!t||t.replace(nte,"").match(new RegExp(`^(?:(?:${n.join("|")}):|[^a-z]|[a-z0-9+.-]+(?:[^a-z+.-:]|$))`,"i"))}const rte=ur.create({name:"link",priority:1e3,keepOnSplit:!1,exitable:!0,onCreate(){this.options.validate&&!this.options.shouldAutoLink&&(this.options.shouldAutoLink=this.options.validate,console.warn("The `validate` option is deprecated. Rename to the `shouldAutoLink` option instead.")),this.options.protocols.forEach(t=>{if(typeof t=="string"){FD(t);return}FD(t.scheme,t.optionalSlashes)})},onDestroy(){Jee()},inclusive(){return this.options.autolink},addOptions(){return{openOnClick:!0,linkOnPaste:!0,autolink:!0,protocols:[],defaultProtocol:"http",HTMLAttributes:{target:"_blank",rel:"noopener noreferrer nofollow",class:null},isAllowedUri:(t,e)=>!!Ws(t,e.protocols),validate:t=>!!t,shouldAutoLink:t=>!!t}},addAttributes(){return{href:{default:null,parseHTML(t){return t.getAttribute("href")}},target:{default:this.options.HTMLAttributes.target},rel:{default:this.options.HTMLAttributes.rel},class:{default:this.options.HTMLAttributes.class}}},parseHTML(){return[{tag:"a[href]",getAttrs:t=>{const e=t.getAttribute("href");return!e||!this.options.isAllowedUri(e,{defaultValidate:n=>!!Ws(n,this.options.protocols),protocols:this.options.protocols,defaultProtocol:this.options.defaultProtocol})?!1:null}}]},renderHTML({HTMLAttributes:t}){return this.options.isAllowedUri(t.href,{defaultValidate:e=>!!Ws(e,this.options.protocols),protocols:this.options.protocols,defaultProtocol:this.options.defaultProtocol})?["a",yt(this.options.HTMLAttributes,t),0]:["a",yt(this.options.HTMLAttributes,{...t,href:""}),0]},addCommands(){return{setLink:t=>({chain:e})=>{const{href:n}=t;return this.options.isAllowedUri(n,{defaultValidate:r=>!!Ws(r,this.options.protocols),protocols:this.options.protocols,defaultProtocol:this.options.defaultProtocol})?e().setMark(this.name,t).setMeta("preventAutolink",!0).run():!1},toggleLink:t=>({chain:e})=>{const{href:n}=t;return this.options.isAllowedUri(n,{defaultValidate:r=>!!Ws(r,this.options.protocols),protocols:this.options.protocols,defaultProtocol:this.options.defaultProtocol})?e().toggleMark(this.name,t,{extendEmptyMarkRange:!0}).setMeta("preventAutolink",!0).run():!1},unsetLink:()=>({chain:t})=>t().unsetMark(this.name,{extendEmptyMarkRange:!0}).setMeta("preventAutolink",!0).run()}},addPasteRules(){return[Vi({find:t=>{const e=[];if(t){const{protocols:n,defaultProtocol:r}=this.options,o=$D(t).filter(i=>i.isLink&&this.options.isAllowedUri(i.value,{defaultValidate:s=>!!Ws(s,n),protocols:n,defaultProtocol:r}));o.length&&o.forEach(i=>e.push({text:i.value,data:{href:i.href},index:i.start}))}return e},type:this.type,getAttributes:t=>{var e;return{href:(e=t.data)===null||e===void 0?void 0:e.href}}})]},addProseMirrorPlugins(){const t=[],{protocols:e,defaultProtocol:n}=this.options;return this.options.autolink&&t.push(Qee({type:this.type,defaultProtocol:this.options.defaultProtocol,validate:r=>this.options.isAllowedUri(r,{defaultValidate:o=>!!Ws(o,e),protocols:e,defaultProtocol:n}),shouldAutoLink:this.options.shouldAutoLink})),this.options.openOnClick===!0&&t.push(ete({type:this.type})),this.options.linkOnPaste&&t.push(tte({editor:this.editor,defaultProtocol:this.options.defaultProtocol,type:this.type})),t}}),BD=tn.create({name:"listItem",addOptions(){return{HTMLAttributes:{},bulletListTypeName:"bulletList",orderedListTypeName:"orderedList"}},content:"paragraph block*",defining:!0,parseHTML(){return[{tag:"li"}]},renderHTML({HTMLAttributes:t}){return["li",yt(this.options.HTMLAttributes,t),0]},addKeyboardShortcuts(){return{Enter:()=>this.editor.commands.splitListItem(this.name),Tab:()=>this.editor.commands.sinkListItem(this.name),"Shift-Tab":()=>this.editor.commands.liftListItem(this.name)}}});function ote(t){var e;const{char:n,allowSpaces:r,allowToIncludeChar:o,allowedPrefixes:i,startOfLine:s,$position:a}=t,l=r&&!o,u=qK(n),f=new RegExp(`\\s${u}$`),p=s?"^":"",g=o?"":u,m=l?new RegExp(`${p}${u}.*?(?=\\s${g}|$)`,"gm"):new RegExp(`${p}(?:^)?${u}[^\\s${g}]*`,"gm"),y=((e=a.nodeBefore)===null||e===void 0?void 0:e.isText)&&a.nodeBefore.text;if(!y)return null;const b=a.pos-y.length,S=Array.from(y.matchAll(m)).pop();if(!S||S.input===void 0||S.index===void 0)return null;const C=S.input.slice(Math.max(0,S.index-1),S.index),T=new RegExp(`^[${i==null?void 0:i.join("")}\0]?$`).test(C);if(i!==null&&!T)return null;const _=b+S.index;let w=_+S[0].length;return l&&f.test(y.slice(w-1,w+1))&&(S[0]+=" ",w+=1),_<a.pos&&w>=a.pos?{range:{from:_,to:w},query:S[0].slice(n.length),text:S[0]}:null}const ite=new bn("suggestion");function ste({pluginKey:t=ite,editor:e,char:n="@",allowSpaces:r=!1,allowToIncludeChar:o=!1,allowedPrefixes:i=[" "],startOfLine:s=!1,decorationTag:a="span",decorationClass:l="suggestion",command:u=()=>null,items:f=()=>[],render:p=()=>({}),allow:g=()=>!0,findSuggestionMatch:m=ote}){let y;const b=p==null?void 0:p(),S=new en({key:t,view(){return{update:async(C,T)=>{var _,w,E,O,L,P,$;const M=(_=this.key)===null||_===void 0?void 0:_.getState(T),A=(w=this.key)===null||w===void 0?void 0:w.getState(C.state),N=M.active&&A.active&&M.range.from!==A.range.from,z=!M.active&&A.active,V=M.active&&!A.active,B=!z&&!V&&M.query!==A.query,R=z||N&&B,q=B||N,U=V||N&&B;if(!R&&!q&&!U)return;const G=U&&!R?M:A,Y=C.dom.querySelector(`[data-decoration-id="${G.decorationId}"]`);y={editor:e,range:G.range,query:G.query,text:G.text,items:[],command:Z=>u({editor:e,range:G.range,props:Z}),decorationNode:Y,clientRect:Y?()=>{var Z;const{decorationId:fe}=(Z=this.key)===null||Z===void 0?void 0:Z.getState(e.state),pe=C.dom.querySelector(`[data-decoration-id="${fe}"]`);return(pe==null?void 0:pe.getBoundingClientRect())||null}:null},R&&((E=b==null?void 0:b.onBeforeStart)===null||E===void 0||E.call(b,y)),q&&((O=b==null?void 0:b.onBeforeUpdate)===null||O===void 0||O.call(b,y)),(q||R)&&(y.items=await f({editor:e,query:G.query})),U&&((L=b==null?void 0:b.onExit)===null||L===void 0||L.call(b,y)),q&&((P=b==null?void 0:b.onUpdate)===null||P===void 0||P.call(b,y)),R&&(($=b==null?void 0:b.onStart)===null||$===void 0||$.call(b,y))},destroy:()=>{var C;y&&((C=b==null?void 0:b.onExit)===null||C===void 0||C.call(b,y))}}},state:{init(){return{active:!1,range:{from:0,to:0},query:null,text:null,composing:!1}},apply(C,T,_,w){const{isEditable:E}=e,{composing:O}=e.view,{selection:L}=C,{empty:P,from:$}=L,M={...T};if(M.composing=O,E&&(P||e.view.composing)){($<T.range.from||$>T.range.to)&&!O&&!T.composing&&(M.active=!1);const A=m({char:n,allowSpaces:r,allowToIncludeChar:o,allowedPrefixes:i,startOfLine:s,$position:L.$from}),N=`id_${Math.floor(Math.random()*4294967295)}`;A&&g({editor:e,state:w,range:A.range,isActive:T.active})?(M.active=!0,M.decorationId=T.decorationId?T.decorationId:N,M.range=A.range,M.query=A.query,M.text=A.text):M.active=!1}else M.active=!1;return M.active||(M.decorationId=null,M.range={from:0,to:0},M.query=null,M.text=null),M}},props:{handleKeyDown(C,T){var _;const{active:w,range:E}=S.getState(C.state);return w&&((_=b==null?void 0:b.onKeyDown)===null||_===void 0?void 0:_.call(b,{view:C,event:T,range:E}))||!1},decorations(C){const{active:T,range:_,decorationId:w}=S.getState(C);return T?Zt.create(C.doc,[Ln.inline(_.from,_.to,{nodeName:a,class:l,"data-decoration-id":w})]):null}}});return S}const ate=new bn("mention"),lte=tn.create({name:"mention",priority:101,addOptions(){return{HTMLAttributes:{},renderText({options:t,node:e}){var n;return`${t.suggestion.char}${(n=e.attrs.label)!==null&&n!==void 0?n:e.attrs.id}`},deleteTriggerWithBackspace:!1,renderHTML({options:t,node:e}){var n;return["span",yt(this.HTMLAttributes,t.HTMLAttributes),`${t.suggestion.char}${(n=e.attrs.label)!==null&&n!==void 0?n:e.attrs.id}`]},suggestion:{char:"@",pluginKey:ate,command:({editor:t,range:e,props:n})=>{var r,o,i;const s=t.view.state.selection.$to.nodeAfter;((r=s==null?void 0:s.text)===null||r===void 0?void 0:r.startsWith(" "))&&(e.to+=1),t.chain().focus().insertContentAt(e,[{type:this.name,attrs:n},{type:"text",text:" "}]).run(),(i=(o=t.view.dom.ownerDocument.defaultView)===null||o===void 0?void 0:o.getSelection())===null||i===void 0||i.collapseToEnd()},allow:({state:t,range:e})=>{const n=t.doc.resolve(e.from),r=t.schema.nodes[this.name];return!!n.parent.type.contentMatch.matchType(r)}}}},group:"inline",inline:!0,selectable:!1,atom:!0,addAttributes(){return{id:{default:null,parseHTML:t=>t.getAttribute("data-id"),renderHTML:t=>t.id?{"data-id":t.id}:{}},label:{default:null,parseHTML:t=>t.getAttribute("data-label"),renderHTML:t=>t.label?{"data-label":t.label}:{}}}},parseHTML(){return[{tag:`span[data-type="${this.name}"]`}]},renderHTML({node:t,HTMLAttributes:e}){if(this.options.renderLabel!==void 0)return console.warn("renderLabel is deprecated use renderText and renderHTML instead"),["span",yt({"data-type":this.name},this.options.HTMLAttributes,e),this.options.renderLabel({options:this.options,node:t})];const n={...this.options};n.HTMLAttributes=yt({"data-type":this.name},this.options.HTMLAttributes,e);const r=this.options.renderHTML({options:n,node:t});return typeof r=="string"?["span",yt({"data-type":this.name},this.options.HTMLAttributes,e),r]:r},renderText({node:t}){return this.options.renderLabel!==void 0?(console.warn("renderLabel is deprecated use renderText and renderHTML instead"),this.options.renderLabel({options:this.options,node:t})):this.options.renderText({options:this.options,node:t})},addKeyboardShortcuts(){return{Backspace:()=>this.editor.commands.command(({tr:t,state:e})=>{let n=!1;const{selection:r}=e,{empty:o,anchor:i}=r;return o?(e.doc.nodesBetween(i-1,i,(s,a)=>{if(s.type.name===this.name)return n=!0,t.insertText(this.options.deleteTriggerWithBackspace?"":this.options.suggestion.char||"",a,a+s.nodeSize),!1}),n):!1})}},addProseMirrorPlugins(){return[ste({editor:this.editor,...this.options.suggestion})]}}),cte="listItem",RD="textStyle",zD=/^(\d+)\.\s$/,VD=tn.create({name:"orderedList",addOptions(){return{itemTypeName:"listItem",HTMLAttributes:{},keepMarks:!1,keepAttributes:!1}},group:"block list",content(){return`${this.options.itemTypeName}+`},addAttributes(){return{start:{default:1,parseHTML:t=>t.hasAttribute("start")?parseInt(t.getAttribute("start")||"",10):1},type:{default:null,parseHTML:t=>t.getAttribute("type")}}},parseHTML(){return[{tag:"ol"}]},renderHTML({HTMLAttributes:t}){const{start:e,...n}=t;return e===1?["ol",yt(this.options.HTMLAttributes,n),0]:["ol",yt(this.options.HTMLAttributes,t),0]},addCommands(){return{toggleOrderedList:()=>({commands:t,chain:e})=>this.options.keepAttributes?e().toggleList(this.name,this.options.itemTypeName,this.options.keepMarks).updateAttributes(cte,this.editor.getAttributes(RD)).run():t.toggleList(this.name,this.options.itemTypeName,this.options.keepMarks)}},addKeyboardShortcuts(){return{"Mod-Shift-7":()=>this.editor.commands.toggleOrderedList()}},addInputRules(){let t=Wa({find:zD,type:this.type,getAttributes:e=>({start:+e[1]}),joinPredicate:(e,n)=>n.childCount+n.attrs.start===+e[1]});return(this.options.keepMarks||this.options.keepAttributes)&&(t=Wa({find:zD,type:this.type,keepMarks:this.options.keepMarks,keepAttributes:this.options.keepAttributes,getAttributes:e=>({start:+e[1],...this.editor.getAttributes(RD)}),joinPredicate:(e,n)=>n.childCount+n.attrs.start===+e[1],editor:this.editor})),[t]}}),HD=tn.create({name:"paragraph",priority:1e3,addOptions(){return{HTMLAttributes:{}}},group:"block",content:"inline*",parseHTML(){return[{tag:"p"}]},renderHTML({HTMLAttributes:t}){return["p",yt(this.options.HTMLAttributes,t),0]},addCommands(){return{setParagraph:()=>({commands:t})=>t.setNode(this.name)}},addKeyboardShortcuts(){return{"Mod-Alt-0":()=>this.editor.commands.setParagraph()}}}),jD=sn.create({name:"placeholder",addOptions(){return{emptyEditorClass:"is-editor-empty",emptyNodeClass:"is-empty",placeholder:"Write something …",showOnlyWhenEditable:!0,showOnlyCurrent:!0,includeChildren:!1}},addProseMirrorPlugins(){return[new en({key:new bn("placeholder"),props:{decorations:({doc:t,selection:e})=>{const n=this.editor.isEditable||!this.options.showOnlyWhenEditable,{anchor:r}=e,o=[];if(!n)return null;const i=this.editor.isEmpty;return t.descendants((s,a)=>{const l=r>=a&&r<=a+s.nodeSize,u=!s.isLeaf&&xf(s);if((l||!this.options.showOnlyCurrent)&&u){const f=[this.options.emptyNodeClass];i&&f.push(this.options.emptyEditorClass);const p=Ln.node(a,a+s.nodeSize,{class:f.join(" "),"data-placeholder":typeof this.options.placeholder=="function"?this.options.placeholder({editor:this.editor,node:s,pos:a,hasAnchor:l}):this.options.placeholder});o.push(p)}return this.options.includeChildren}),Zt.create(t,o)}}})]}}),ute=/(?:^|\s)(~~(?!\s+~~)((?:[^~]+))~~(?!\s+~~))$/,dte=/(?:^|\s)(~~(?!\s+~~)((?:[^~]+))~~(?!\s+~~))/g,WD=ur.create({name:"strike",addOptions(){return{HTMLAttributes:{}}},parseHTML(){return[{tag:"s"},{tag:"del"},{tag:"strike"},{style:"text-decoration",consuming:!1,getAttrs:t=>t.includes("line-through")?{}:!1}]},renderHTML({HTMLAttributes:t}){return["s",yt(this.options.HTMLAttributes,t),0]},addCommands(){return{setStrike:()=>({commands:t})=>t.setMark(this.name),toggleStrike:()=>({commands:t})=>t.toggleMark(this.name),unsetStrike:()=>({commands:t})=>t.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-Shift-s":()=>this.editor.commands.toggleStrike()}},addInputRules(){return[Ls({find:ute,type:this.type})]},addPasteRules(){return[Vi({find:dte,type:this.type})]}}),fte=ur.create({name:"subscript",addOptions(){return{HTMLAttributes:{}}},parseHTML(){return[{tag:"sub"},{style:"vertical-align",getAttrs(t){return t!=="sub"?!1:null}}]},renderHTML({HTMLAttributes:t}){return["sub",yt(this.options.HTMLAttributes,t),0]},addCommands(){return{setSubscript:()=>({commands:t})=>t.setMark(this.name),toggleSubscript:()=>({commands:t})=>t.toggleMark(this.name),unsetSubscript:()=>({commands:t})=>t.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-,":()=>this.editor.commands.toggleSubscript()}}}),pte=ur.create({name:"superscript",addOptions(){return{HTMLAttributes:{}}},parseHTML(){return[{tag:"sup"},{style:"vertical-align",getAttrs(t){return t!=="super"?!1:null}}]},renderHTML({HTMLAttributes:t}){return["sup",yt(this.options.HTMLAttributes,t),0]},addCommands(){return{setSuperscript:()=>({commands:t})=>t.setMark(this.name),toggleSuperscript:()=>({commands:t})=>t.toggleMark(this.name),unsetSuperscript:()=>({commands:t})=>t.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-.":()=>this.editor.commands.toggleSuperscript()}}}),hte=tn.create({name:"tableCell",addOptions(){return{HTMLAttributes:{}}},content:"block+",addAttributes(){return{colspan:{default:1},rowspan:{default:1},colwidth:{default:null,parseHTML:t=>{const e=t.getAttribute("colwidth");return e?e.split(",").map(r=>parseInt(r,10)):null}}}},tableRole:"cell",isolating:!0,parseHTML(){return[{tag:"td"}]},renderHTML({HTMLAttributes:t}){return["td",yt(this.options.HTMLAttributes,t),0]}}),gte=tn.create({name:"tableHeader",addOptions(){return{HTMLAttributes:{}}},content:"block+",addAttributes(){return{colspan:{default:1},rowspan:{default:1},colwidth:{default:null,parseHTML:t=>{const e=t.getAttribute("colwidth");return e?e.split(",").map(r=>parseInt(r,10)):null}}}},tableRole:"header_cell",isolating:!0,parseHTML(){return[{tag:"th"}]},renderHTML({HTMLAttributes:t}){return["th",yt(this.options.HTMLAttributes,t),0]}}),mte=tn.create({name:"tableRow",addOptions(){return{HTMLAttributes:{}}},content:"(tableCell | tableHeader)*",tableRole:"row",parseHTML(){return[{tag:"tr"}]},renderHTML({HTMLAttributes:t}){return["tr",yt(this.options.HTMLAttributes,t),0]}}),yte=/^\s*(\[([( |x])?\])\s$/,bte=tn.create({name:"taskItem",addOptions(){return{nested:!1,HTMLAttributes:{},taskListTypeName:"taskList"}},content(){return this.options.nested?"paragraph block*":"paragraph+"},defining:!0,addAttributes(){return{checked:{default:!1,keepOnSplit:!1,parseHTML:t=>{const e=t.getAttribute("data-checked");return e===""||e==="true"},renderHTML:t=>({"data-checked":t.checked})}}},parseHTML(){return[{tag:`li[data-type="${this.name}"]`,priority:51}]},renderHTML({node:t,HTMLAttributes:e}){return["li",yt(this.options.HTMLAttributes,e,{"data-type":this.name}),["label",["input",{type:"checkbox",checked:t.attrs.checked?"checked":null}],["span"]],["div",0]]},addKeyboardShortcuts(){const t={Enter:()=>this.editor.commands.splitListItem(this.name),"Shift-Tab":()=>this.editor.commands.liftListItem(this.name)};return this.options.nested?{...t,Tab:()=>this.editor.commands.sinkListItem(this.name)}:t},addNodeView(){return({node:t,HTMLAttributes:e,getPos:n,editor:r})=>{const o=document.createElement("li"),i=document.createElement("label"),s=document.createElement("span"),a=document.createElement("input"),l=document.createElement("div");return i.contentEditable="false",a.type="checkbox",a.addEventListener("mousedown",u=>u.preventDefault()),a.addEventListener("change",u=>{if(!r.isEditable&&!this.options.onReadOnlyChecked){a.checked=!a.checked;return}const{checked:f}=u.target;r.isEditable&&typeof n=="function"&&r.chain().focus(void 0,{scrollIntoView:!1}).command(({tr:p})=>{const g=n();if(typeof g!="number")return!1;const m=p.doc.nodeAt(g);return p.setNodeMarkup(g,void 0,{...m==null?void 0:m.attrs,checked:f}),!0}).run(),!r.isEditable&&this.options.onReadOnlyChecked&&(this.options.onReadOnlyChecked(t,f)||(a.checked=!a.checked))}),Object.entries(this.options.HTMLAttributes).forEach(([u,f])=>{o.setAttribute(u,f)}),o.dataset.checked=t.attrs.checked,a.checked=t.attrs.checked,i.append(a,s),o.append(i,l),Object.entries(e).forEach(([u,f])=>{o.setAttribute(u,f)}),{dom:o,contentDOM:l,update:u=>u.type!==this.type?!1:(o.dataset.checked=u.attrs.checked,a.checked=u.attrs.checked,!0)}}},addInputRules(){return[Wa({find:yte,type:this.type,getAttributes:t=>({checked:t[t.length-1]==="x"})})]}}),vte=tn.create({name:"taskList",addOptions(){return{itemTypeName:"taskItem",HTMLAttributes:{}}},group:"block list",content(){return`${this.options.itemTypeName}+`},parseHTML(){return[{tag:`ul[data-type="${this.name}"]`,priority:51}]},renderHTML({HTMLAttributes:t}){return["ul",yt(this.options.HTMLAttributes,t,{"data-type":this.name}),0]},addCommands(){return{toggleTaskList:()=>({commands:t})=>t.toggleList(this.name,this.options.itemTypeName)}},addKeyboardShortcuts(){return{"Mod-Shift-9":()=>this.editor.commands.toggleTaskList()}}}),qD=tn.create({name:"text",group:"inline"}),xte=sn.create({name:"textAlign",addOptions(){return{types:[],alignments:["left","center","right","justify"],defaultAlignment:null}},addGlobalAttributes(){return[{types:this.options.types,attributes:{textAlign:{default:this.options.defaultAlignment,parseHTML:t=>{const e=t.style.textAlign;return this.options.alignments.includes(e)?e:this.options.defaultAlignment},renderHTML:t=>t.textAlign?{style:`text-align: ${t.textAlign}`}:{}}}}]},addCommands(){return{setTextAlign:t=>({commands:e})=>this.options.alignments.includes(t)?this.options.types.map(n=>e.updateAttributes(n,{textAlign:t})).every(n=>n):!1,unsetTextAlign:()=>({commands:t})=>this.options.types.map(e=>t.resetAttributes(e,"textAlign")).every(e=>e)}},addKeyboardShortcuts(){return{"Mod-Shift-l":()=>this.editor.commands.setTextAlign("left"),"Mod-Shift-e":()=>this.editor.commands.setTextAlign("center"),"Mod-Shift-r":()=>this.editor.commands.setTextAlign("right"),"Mod-Shift-j":()=>this.editor.commands.setTextAlign("justify")}}}),Ste=ur.create({name:"underline",addOptions(){return{HTMLAttributes:{}}},parseHTML(){return[{tag:"u"},{style:"text-decoration",consuming:!1,getAttrs:t=>t.includes("underline")?{}:!1}]},renderHTML({HTMLAttributes:t}){return["u",yt(this.options.HTMLAttributes,t),0]},addCommands(){return{setUnderline:()=>({commands:t})=>t.setMark(this.name),toggleUnderline:()=>({commands:t})=>t.toggleMark(this.name),unsetUnderline:()=>({commands:t})=>t.unsetMark(this.name)}},addKeyboardShortcuts(){return{"Mod-u":()=>this.editor.commands.toggleUnderline(),"Mod-U":()=>this.editor.commands.toggleUnderline()}}}),UD=J.forwardRef((t,e)=>{const[n,r]=J.useState(0),o=l=>{if(l>=t.items.length)return;const u=t.items[l],f={id:u.id,label:u.mentionLabel};t.command(f)},i=()=>{r((n+t.items.length-1)%t.items.length)},s=()=>{r((n+1)%t.items.length)},a=()=>{o(n)};return J.useEffect(()=>r(0),[t.items]),J.useImperativeHandle(e,()=>({onKeyDown:({event:l})=>l.key==="ArrowUp"?(i(),!0):l.key==="ArrowDown"?(s(),!0):l.key==="Enter"?(a(),!0):!1})),t.items.length>0?v.jsx(F.Paper,{elevation:5,children:v.jsx(F.List,{dense:!0,sx:{overflow:"hidden"},children:t.items.map((l,u)=>v.jsx(F.ListItem,{disablePadding:!0,children:v.jsx(F.ListItemButton,{selected:u===n,onClick:()=>o(u),children:l.mentionLabel})},l.id))})}):null});UD.displayName="SuggestionList";const KD={bottom:0,height:0,left:0,right:0,top:0,width:0,x:0,y:0,toJSON(){return{}}},Cte={items:async({query:t})=>Promise.resolve(["Lea Thompson","Cyndi Lauper","Tom Cruise","Madonna","Jerry Hall","Joan Collins","Winona Ryder","Christina Applegate","Alyssa Milano","Molly Ringwald","Ally Sheedy","Debbie Harry","Olivia Newton-John","Elton John","Michael J. Fox","Axl Rose","Emilio Estevez","Ralph Macchio","Rob Lowe","Jennifer Grey","Mickey Rourke","John Cusack","Matthew Broderick","Justine Bateman","Lisa Bonet","Benicio Monserrate Rafael del Toro Sánchez"].map((e,n)=>({mentionLabel:e,id:n.toString()})).filter(e=>e.mentionLabel.toLowerCase().startsWith(t.toLowerCase())).slice(0,5)),render:()=>{let t,e;return{onStart:n=>{t=new Q2(UD,{props:n,editor:n.editor}),e=Hc("body",{getReferenceClientRect:()=>{var r;return((r=n.clientRect)==null?void 0:r.call(n))??KD},appendTo:()=>document.body,content:t.element,showOnCreate:!0,interactive:!0,trigger:"manual",placement:"bottom-start"})[0]},onUpdate(n){t==null||t.updateProps(n),e==null||e.setProps({getReferenceClientRect:()=>{var r;return((r=n.clientRect)==null?void 0:r.call(n))??KD}})},onKeyDown(n){return n.event.key==="Escape"?(e==null||e.hide(),!0):t!=null&&t.ref?t.ref.onKeyDown(n):!1},onExit(){e==null||e.destroy(),t==null||t.destroy(),e=void 0,t=void 0}}}},wte=rte.extend({inclusive:!1}),_te=fte.extend({excludes:"superscript"}),Tte=pte.extend({excludes:"subscript"});function kte({placeholder:t}={}){return J.useMemo(()=>[YQ.configure({resizable:!0}),mte,gte,hte,sD,lD,cD,fD,BD,VD,HD,_te,Tte,qD,rD,nD,aD,SD,Ste,WD,wte.configure({autolink:!0,linkOnPaste:!0,openOnClick:!1}),WG,dD,zX,xte.configure({types:["heading","paragraph","image"]}),aee,lee,dee,BX,See.configure({multicolor:!0}),xD,KX,uD,vte,bte.configure({nested:!0}),lte.configure({suggestion:Cte}),jD.configure({placeholder:t}),vD],[t])}function YD(t){return Array.from(t).filter(e=>(e.type||"").toLowerCase().startsWith("image/"))}const Ete=t=>{const e=kte({placeholder:"Add your own content here..."});if(t.renderContentOnly)return v.jsx(mZ,{content:t.renderContentOnly,extensions:e});const{name:n,label:r,labelProps:o={fontSize:"0.9em",color:"#808080",fontWeight:"400"},onUploadFiles:i,readOnly:s=!1}=t,[a,l,u]=jt.useField({name:n}),{setValue:f}=u,{value:p}=a;J.useEffect(()=>{var C,T,_;(_=(T=(C=g==null?void 0:g.current)==null?void 0:C.editor)==null?void 0:T.commands)==null||_.setContent(p)},[p]);const g=J.useRef(null),m=J.useCallback((C,T)=>{var w;const _=(w=g.current)==null?void 0:w.editor;if(!(!_||!i))if(i instanceof Promise)i(C).then(E=>{Nv({images:E,editor:_,position:T})});else{const E=i(C);Nv({images:E,editor:_,position:T})}},[]),y=J.useCallback((C,T,_,w)=>{var O;if(!(T instanceof DragEvent)||!T.dataTransfer)return!1;const E=YD(T.dataTransfer.files);if(E.length>0){const L=(O=C.posAtCoords({left:T.clientX,top:T.clientY}))==null?void 0:O.pos;return m(E,L),T.preventDefault(),!0}return!1},[m]),b=J.useCallback((C,T,_)=>{if(!T.clipboardData)return!1;const w=YD(T.clipboardData.files);return w.length>0?(m(w),!0):!1},[m]),S=v.jsx(F.Box,{sx:{"& .ProseMirror":{"& h1, & h2, & h3, & h4, & h5, & h6":{scrollMarginTop:s?0:50}}},children:v.jsx(iI,{ref:g,extensions:e,content:p,editable:!s,editorProps:{handleDrop:y,handlePaste:b},renderControls:s?void 0:()=>v.jsx(GQ,{onUploadFiles:i}),onBlur:()=>{var C,T;return f(((T=(C=g.current)==null?void 0:C.editor)==null?void 0:T.getHTML())??"")},RichTextFieldProps:{variant:"outlined",MenuBarProps:{hide:s}},children:()=>v.jsxs(v.Fragment,{children:[v.jsx(C2,{}),v.jsx(sI,{})]})})});return v.jsxs(F.Box,{display:"flex",flexDirection:"column",children:[r&&v.jsx(F.Typography,{...o,children:r}),S]})},y1=t=>{const{title:e="Loading...",message:n}=t;return v.jsxs(F.Box,{className:"loading-page",sx:{gap:2},"data-testid":"loading-page",children:[v.jsxs(F.Box,{className:"text-content",children:[v.jsx(F.Typography,{variant:"h1","data-testid":"title",children:e}),n&&v.jsx(F.Typography,{"data-testid":"message",children:n})]}),v.jsx(F.CircularProgress,{size:75,"data-testid":"loading-spinner"})]})},GD=t=>{const{colSpan:e,isExpanded:n,renderExpand:r,obj:o,asMobileCard:i=!1,reRenderExpand:s=!1}=t,[a,l]=J.useState(!1),[u,f]=J.useState(void 0);return J.useEffect(()=>{n&&(!a||s)&&(l(!0),f(r(o)))},[n,o]),i?v.jsx(F.Box,{children:v.jsx(F.Collapse,{in:n,children:u})}):v.jsx(F.TableRow,{children:v.jsx(F.TableCell,{style:{paddingBottom:0,paddingTop:0},colSpan:e,children:v.jsx(F.Collapse,{in:n,children:u})})})},JD=t=>{const{id:e,getRowKey:n=W=>"id"in W&&(typeof W.id=="string"||typeof W.id=="number")?W.id:(console.warn(`Table: "id: string | number" not found in ${JSON.stringify(W)}. Please implement the Table.getRowKey prop so Table knows how to uniquely identify this row.`),JSON.stringify(W)),columns:r,data:o=[],onRowClick:i,renderExpand:s,hideColumnsOnMobile:a=[],sortField:l,sortOrder:u,onSortChange:f,allowSortCols:p,fixedLayout:g=!1,className:m,emptyTableMsg:y="No items to display",errorTableMsg:b,retryCallback:S,isLoading:C=!1,disableMobileCards:T=!1,highlightSelectedRow:_=!1,headerRowStyle:w={},stickyHeader:E,reRenderExpand:O=!1,...L}=t,{palette:P}=F.useTheme(),[$,M]=J.useState(void 0),[A,N]=J.useState(void 0);Array.isArray(g)&&g.length!==r.length&&console.error('Table component: Length of "fixedLayout" is not equal to the length of "columns".');const z=W=>{W!==l?f&&f(W,"asc"):f&&f(l,u==="asc"?"desc":"asc")},V=W=>l===W?u:null,B=F.useMediaQuery(F.useTheme().breakpoints.down("sm")),R=B&&a?r.filter(W=>!(a.includes(W.fieldName)||W.hideCol)):r.filter(W=>!W.hideCol),q=(W,ee)=>ee.split(".").reduce((ce,te)=>{if(ce&&typeof ce=="object")return ce[te]},W),U=(W,ee)=>{const ce=q(ee,W.fieldName);return W.render?W.render(ce,ee,B):ce},G=f!==void 0,Y=W=>G?p?p.includes(W):!0:!1,Z=v.jsxs(F.Box,{display:"flex",justifyContent:"center",alignItems:"center",flexDirection:"row",children:[v.jsx(MR,{})," ",y]}),fe=v.jsxs(F.Box,{"data-testid":"table-fetch-error-msg",display:"flex",justifyContent:"center",alignItems:"center",flexDirection:"row",children:[v.jsx(dC,{color:"error"})," ",b,S&&v.jsx(F.Button,{variant:"text",onClick:S,children:"Retry?"})]}),pe=()=>{if(C)return v.jsx(F.TableRow,{children:v.jsx(F.TableCell,{colSpan:r.length,align:"center",children:v.jsx(F.Box,{display:"flex",justifyContent:"center",alignItems:"center",flexDirection:"row",children:v.jsx(y1,{})})})});if(b)return v.jsx(F.TableRow,{children:v.jsx(F.TableCell,{colSpan:r.length,align:"center",children:fe})});if(o.length===0)return v.jsx(F.TableRow,{children:v.jsx(F.TableCell,{colSpan:r.length,align:"center",children:Z})})},me=()=>{if(C)return v.jsx(y1,{});if(b)return fe;if(o.length===0)return Z},re=W=>{_&&N(W)},he=W=>{if(i&&(i(W),re(W)),s){const ee=$===W?void 0:W;M(ee),re(ee)}},le=typeof _=="string"?_:P.grey[P.mode=="dark"?600:50],X=W=>{const ee=A===n(W)?le:"inherit";return{cursor:i||s?"pointer":"default",backgroundColor:ee,...i&&{"&:hover":{backgroundColor:ee===le?ia(ee,.1):le}}}};return B&&!T?v.jsxs("div",{...e?{id:`mobile-table-${e}`}:{},className:m,"data-testid":"mui-table-mobile",children:[G&&v.jsxs(v.Fragment,{children:[v.jsxs(F.Box,{display:"flex",className:"MBv2_Table_Stack_Sort",children:[v.jsx(F.TextField,{select:!0,sx:{flexGrow:1},id:"demo-simple-select",size:"small",value:l??"",label:"Sort By...",onChange:W=>z(W.target.value),fullWidth:!0,children:R.map(W=>{if(Y(W.fieldName))return v.jsx(F.MenuItem,{value:W.sortName??W.fieldName,children:W.label??_n(W.fieldName)},`${W.key??"rowHeader"}-${W.fieldName}`)})}),v.jsx(F.IconButton,{onClick:()=>{l&&z(l)},children:v.jsx(BR,{className:`sort-icon-${u}`})})]}),v.jsx(F.Divider,{sx:{margin:"10px 0"}})]}),me()??o.map(W=>v.jsxs(F.Card,{className:"MBv2_Table_Stack_Container",sx:{margin:"5px 0",padding:"5px",overflowX:"auto",...X(W)},onClick:()=>he(n(W)),"data-testid":`card-${n(W)}`,children:[v.jsx("table",{className:"MBv2_Table_Stack",children:v.jsx("tbody",{className:"MBv2_Table_Stack_Body",children:R.map(ee=>v.jsxs("tr",{className:"MBv2_Table_Stack_Row",children:[v.jsx("td",{className:`MBv2_Table_Stack_Cell_Label MBv2_Table_Stack_Col_${ee.fieldName}`,style:{textWrap:"nowrap"},children:ee.label??_n(ee.fieldName)}),v.jsx("td",{className:`MBv2_Table_Stack_Cell_Value MBv2_Table_Stack_Val_${ee.fieldName}`,style:{paddingLeft:"10px"},children:U(ee,W)})]},`${ee.key??"row"}-${n(W)}-${ee.fieldName}`))})}),s&&v.jsx(GD,{colSpan:r.length,isExpanded:n(W)===$,obj:W,renderExpand:ee=>s(ee),asMobileCard:!0})]},n(W)))]}):v.jsx(F.TableContainer,{component:F.Card,"data-testid":"mui-table",...e?{id:`table-${e}`}:{},className:m,style:E?{maxHeight:E,overflow:"auto"}:{},children:v.jsxs(F.Table,{stickyHeader:E!=="undefined",style:{tableLayout:g?"fixed":"auto"},className:"MBv2_Table",sx:w?{"& .MuiTableCell-head":{...w}}:{},...L,children:[v.jsx(F.TableHead,{className:"MBv2_Table_Head",children:v.jsx(F.TableRow,{className:"MBv2_Table_Head_Row",children:R.map((W,ee)=>{const ce=Y(W.fieldName);return v.jsx(F.TableCell,{width:Array.isArray(g)?g[ee]:"auto",sx:W.tableCellSx??{},children:v.jsx(F.Box,{style:{display:"flex",alignItems:"center"},children:v.jsxs(F.Box,{sx:[ce&&{"&:hover":{cursor:"pointer",backgroundColor:P.mode==="dark"?"#222222":"#ededed",borderRadius:2}}],style:{display:"flex",alignItems:"center",padding:"5px",paddingLeft:"6px",marginLeft:"-6px"},onClick:ce?()=>z(W.sortName??W.fieldName):void 0,children:[v.jsx("strong",{className:"MBv2_Table_Col_Label",style:{wordBreak:"normal"},children:W.label??_n(W.fieldName)}),ce&&V(W.fieldName)==="asc"&&v.jsx(RC,{style:{marginLeft:"5px"}}),ce&&V(W.fieldName)==="desc"&&v.jsx(OR,{style:{marginLeft:"5px"}}),ce&&V(W.fieldName)!=="asc"&&V(W.fieldName)!=="desc"&&v.jsx(LR,{style:{marginLeft:"5px"}})]})})},`${W.key??"rowHeader"}-${W.fieldName}`)})})}),v.jsx(F.TableBody,{className:"MBv2_Table_Body",children:pe()??o.map(W=>v.jsxs(J.Fragment,{children:[v.jsx(F.TableRow,{"data-testid":`row-${n(W)}`,className:"MBv2_Table_Body_Row",onClick:()=>he(n(W)),sx:X(W),children:R.map(ee=>v.jsx(F.TableCell,{className:`MBv2_Table_Body_Cell MBv2_Table_Body_Col_${ee.fieldName}`,children:U(ee,W)},`${ee.key??"row"}-${n(W)}-${ee.fieldName}`))}),s&&v.jsx(GD,{colSpan:r.length,isExpanded:n(W)===$,obj:W,renderExpand:ee=>s(ee),reRenderExpand:O})]},n(W)))})]})})},ZD=t=>{const{paginationState:e,onPageChange:n,onRowsPerPageChange:r,hidePaginationControls:o=!1,rowsPerPageOptions:i=[5,10,25],...s}=t,{pageNo:a,pageSize:l,totalCount:u,sortField:f,sortOrder:p}=e,g=S=>{n(S)},m=S=>{r(parseInt(S.target.value,10))},y=F.useMediaQuery(F.useTheme().breakpoints.down("sm")),b=!t.data||t.data&&t.data.length===0;return v.jsxs(F.Box,{children:[v.jsx(JD,{sortOrder:p,sortField:f,...s}),!o&&!b&&v.jsx(F.TablePagination,{"data-testid":"pagination-controls",component:"div",rowsPerPageOptions:y?[]:i,count:u,rowsPerPage:l,page:a,onPageChange:(S,C)=>g(C),onRowsPerPageChange:m,sx:{flexGrow:1,marginRight:{xs:0,md:15}}})]})},XD=()=>({height:window.innerHeight,width:window.innerWidth}),QD=()=>{const[t,e]=J.useState(XD());return J.useEffect(()=>{const n=()=>{e(XD())};return window.addEventListener("resize",n),()=>window.removeEventListener("resize",n)},[]),t},No=t=>{const{name:e="button",color:n="primary",fullWidthOnMobile:r=!0,type:o="button",variant:i="contained"}=t,{width:s}=QD(),a=["locationInBar","closeDialog","fullWidthOnMobile"],l=r&&s<600;return v.jsx(F.Button,{role:"button",name:e,color:n,variant:i,type:o,fullWidth:t.fullWidth?!0:l,...Jn({...t},a)})},Mte=t=>{const{refreshKey:e,title:n,onCancel:r,onNewCitation:o,onNewAttachment:i,onEditCitation:s,onEditAttachment:a,onDeleteCitation:l,onDownloadAttachment:u,onSelect:f,getCitationsPaginated:p,selectedIds:g,setSelectedIds:m,onError:y=()=>{},setError:b,setSuccess:S,condenseTable:C=!1,canCreate:T=!1,canEdit:_=!1,canSelect:w=!1,addlActions:E}=t,{palette:O}=F.useTheme(),[L,P]=J.useState([]),[$,M]=J.useState(!1),[A,N]=J.useState(!0),[z,V]=J.useState(null),[B,R]=J.useState(null),[q,U]=J.useState({pageNo:0,pageSize:C?5:10,totalCount:0}),G=()=>{M(!1),N(!0),p({pageNo:q.pageNo,pageSize:q.pageSize}).then(X=>(P(X.data),U({...q,totalCount:X.totalCount}),X)).catch(X=>{y(X),M(!0),P([])}).finally(()=>N(!1))};J.useEffect(G,[q.pageNo,q.pageSize,e]);const Y=()=>{R(null),V(null)},Z=v.jsx(No,{variant:w?"outlined":"contained",size:w?"small":"medium",onClick:o,startIcon:v.jsx(Ju,{}),children:"Add Citation"}),fe=v.jsx(No,{variant:w?"outlined":"contained",size:w?"small":"medium",onClick:i,startIcon:v.jsx(BC,{}),children:"Add Attachment"}),pe=X=>{if(_)return v.jsx(F.IconButton,{color:"primary",onClick:()=>X.fileName?a(X):s(X),"data-testid":`citation-table_edit-btn-${X.id}`,children:v.jsx(uR,{})})},me=X=>{if(l)return v.jsx(F.IconButton,{color:"error",onClick:W=>{R(X.id),V(W.currentTarget)},"data-testid":`citation-table_delete-btn-${X.id}`,children:v.jsx(qh,{})})},re=X=>{if(u)return v.jsx(F.IconButton,{color:"primary",onClick:()=>{u(X).catch(W=>b({title:`Failed to download ${X.fileName}`,err:W}))},"data-testid":`citation-table_download-btn-${X.id}`,sx:{visibility:X.fileName?"visible":"hidden"},children:v.jsx(cR,{})})},le=[{fieldName:"id",key:"select",label:"",hideCol:!w,render:(X,W)=>v.jsx(F.Checkbox,{"data-testid":`citation-table_checkbox-${X}`,onChange:()=>{const ee=g.includes(W.id);m(ee?g.filter(ce=>ce!==W.id):[...g,W.id])},checked:g.includes(X)})},{fieldName:"fileName",key:"CitationOrAttachment",label:"Type",render:(X,W)=>v.jsx(F.Tooltip,{title:X?"Attachment":"URL",children:X?v.jsx(BC,{sx:{color:O.grey[500],marginTop:"4px"},"data-testid":`attachment-icon-${W.id}`}):v.jsx(Ju,{sx:{color:O.grey[500],marginTop:"6px"},"data-testid":`url-icon-${W.id}`})})},{fieldName:"title",tableCellSx:{width:C?"100%":"auto"}},{fieldName:"fileName",key:"URL/File Name",label:"URL/File Name",hideCol:C,render:(X,W)=>v.jsx("span",{style:{wordBreak:"break-all"},children:X||W.url})},{fieldName:"source",hideCol:C},{fieldName:"accessedAt",hideCol:C,render:(X,W)=>{if(!W.fileName)return(X==null?void 0:X.slice(0,10))??""}},{fieldName:"classification",hideCol:C},{fieldName:"id",key:"Action",label:"Action",hideCol:!(_||u||l||E),render:(X,W)=>v.jsxs(F.Box,{display:"flex",flexDirection:"row",children:[re(W),pe(W),me(W),E==null?void 0:E(W),v.jsx(F.Popper,{open:B===X,anchorEl:z,placement:"bottom-end",style:{zIndex:1300},children:v.jsxs(F.Box,{component:F.Paper,p:1,display:"flex",gap:1,boxShadow:9,"data-testid":`citation-table_delete-prompt-${X}`,children:[v.jsxs(F.Typography,{variant:"body2",children:["Are you sure you want to delete this ",W.fileName?"attachment":"citation","?"]}),v.jsxs(F.Box,{display:"flex",flexDirection:"row",children:[v.jsx(No,{size:"small",variant:"text",onClick:Y,"data-testid":`citation-table_delete-prompt-${X}-noBtn`,children:"No"}),v.jsx(No,{size:"small",color:"error",startIcon:v.jsx(qh,{}),onClick:()=>{l==null||l(X).then(()=>{G(),m(g.filter(ee=>ee!==X)),S(`Successfully deleted "${W.title}"`)}).catch(ee=>b({title:`Failed to delete ${W.fileName?"attachment":"citation"}`,err:ee})).finally(Y)},"data-testid":`citation-table_delete-prompt-${X}-yesBtn`,children:"Yes"})]})]})})]})}];return v.jsxs(v.Fragment,{children:[v.jsxs(F.Box,{display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center",paddingBottom:"10px",children:[v.jsx(F.Typography,{variant:C?"h6":"h2",children:n}),!w&&T&&v.jsxs(F.Box,{display:"flex",flexDirection:"row",gap:1,children:[Z,fe]})]}),v.jsx(ZD,{"data-testid":"citation-table",title:n,size:C?"x-small":"medium",isLoading:A,columns:le,data:L,paginationState:q,onPageChange:X=>U({...q,pageNo:X}),onRowsPerPageChange:X=>U({...q,pageSize:X,pageNo:0}),errorTableMsg:$?"Failed to load citations.":void 0,retryCallback:G}),w&&v.jsxs(F.Box,{display:"flex",flexDirection:"row",justifyContent:"space-between",marginTop:"20px",children:[v.jsx(F.Box,{display:"flex",flexDirection:"row",gap:".25rem",children:T&&v.jsxs(v.Fragment,{children:[Z,fe]})}),v.jsxs(F.Box,{display:"flex",flexDirection:"row",gap:".25rem",children:[v.jsx(No,{variant:"outlined",size:"small",onClick:r,children:"Cancel"}),v.jsxs(No,{variant:"contained",size:"small",onClick:()=>f(g),children:["Select",g.length>0&&` (${g.length})`]})]})]})]})},b1=t=>{const{loading:e=!1,type:n="submit",size:r="medium",...o}=t,s={small:16,medium:20,large:24}[r];return v.jsx(No,{type:n,disabled:e,size:r,startIcon:e?v.jsx(F.CircularProgress,{size:s,color:"inherit"}):null,...o})},Ote=t=>{const{id:e,title:n,onSave:r,onCancel:o,getCitationById:i,setError:s}=t,a=J.useRef(null),[l,u]=J.useState(!0),[f,p]=J.useState({type:"Url",source:"",title:"",accessedAt:null,url:"",classification:""});J.useEffect(()=>{if(e===void 0){u(!1);return}i(e).then(m=>{p({...m,type:"Url"}),u(!1)}).catch(m=>{u(!1),s({title:"Failed to retrieve citation",err:m})})},[]);const g=()=>{var y,b,S;const m=(b=(y=a==null?void 0:a.current)==null?void 0:y.values)==null?void 0:b.url;m&&((S=a==null?void 0:a.current)==null||S.setFieldValue("url",s2(m)))};return v.jsxs(v.Fragment,{children:[n&&v.jsx(F.Typography,{variant:"h6",margin:"10px 0",children:n}),v.jsx(jt.Formik,{innerRef:a,enableReinitialize:!0,initialValues:f,onSubmit:async m=>{u(!0),r(m).catch(y=>{u(!1),s({title:`Failed to ${e===void 0?"save":"update"} citation`,err:y})}).finally(()=>u(!1))},children:v.jsxs(jt.Form,{autoComplete:"off",children:[v.jsx(da,{name:"source",disabled:l,required:!0,margin:"none"}),v.jsx(da,{name:"title",disabled:l,required:!0,margin:"none"}),v.jsx(Fd,{name:"accessedAt",disabled:l,required:!0,margin:"none",isDatePicker:!0}),v.jsx(da,{name:"url",disabled:l,required:!0,onBlur:g,margin:"none"}),v.jsx(FC,{row:!0,name:"classification",required:!0,radios:[{label:"Public Source",value:"Public Source"},{label:"Proprietary Source",value:"Proprietary Source"}],margin:"none"}),v.jsxs(F.DialogActions,{sx:{px:0},children:[v.jsx(F.Button,{onClick:o,variant:"outlined",size:"small",children:"Cancel"}),v.jsx(b1,{size:"small",loading:l,children:e?"Update Citation":"Add New Citation"})]})]})})]})};var v1,eP;function Ate(){if(eP)return v1;eP=1;function t(C){this._maxSize=C,this.clear()}t.prototype.clear=function(){this._size=0,this._values=Object.create(null)},t.prototype.get=function(C){return this._values[C]},t.prototype.set=function(C,T){return this._size>=this._maxSize&&this.clear(),C in this._values||this._size++,this._values[C]=T};var e=/[^.^\]^[]+|(?=\[\]|\.\.)/g,n=/^\d+$/,r=/^\d/,o=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,i=/^\s*(['"]?)(.*?)(\1)\s*$/,s=512,a=new t(s),l=new t(s),u=new t(s);v1={Cache:t,split:p,normalizePath:f,setter:function(C){var T=f(C);return l.get(C)||l.set(C,function(w,E){for(var O=0,L=T.length,P=w;O<L-1;){var $=T[O];if($==="__proto__"||$==="constructor"||$==="prototype")return w;P=P[T[O++]]}P[T[O]]=E})},getter:function(C,T){var _=f(C);return u.get(C)||u.set(C,function(E){for(var O=0,L=_.length;O<L;)if(E!=null||!T)E=E[_[O++]];else return;return E})},join:function(C){return C.reduce(function(T,_){return T+(m(_)||n.test(_)?"["+_+"]":(T?".":"")+_)},"")},forEach:function(C,T,_){g(Array.isArray(C)?C:p(C),T,_)}};function f(C){return a.get(C)||a.set(C,p(C).map(function(T){return T.replace(i,"$2")}))}function p(C){return C.match(e)||[""]}function g(C,T,_){var w=C.length,E,O,L,P;for(O=0;O<w;O++)E=C[O],E&&(S(E)&&(E='"'+E+'"'),P=m(E),L=!P&&/^\d+$/.test(E),T.call(_,E,P,L,O,C))}function m(C){return typeof C=="string"&&C&&["'",'"'].indexOf(C.charAt(0))!==-1}function y(C){return C.match(r)&&!C.match(n)}function b(C){return o.test(C)}function S(C){return!m(C)&&(y(C)||b(C))}return v1}var qs=Ate(),x1,tP;function Ite(){if(tP)return x1;tP=1;const t=/[A-Z\xc0-\xd6\xd8-\xde]?[a-z\xdf-\xf6\xf8-\xff]+(?:['’](?:d|ll|m|re|s|t|ve))?(?=[\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000]|[A-Z\xc0-\xd6\xd8-\xde]|$)|(?:[A-Z\xc0-\xd6\xd8-\xde]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])+(?:['’](?:D|LL|M|RE|S|T|VE))?(?=[\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000]|[A-Z\xc0-\xd6\xd8-\xde](?:[a-z\xdf-\xf6\xf8-\xff]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])|$)|[A-Z\xc0-\xd6\xd8-\xde]?(?:[a-z\xdf-\xf6\xf8-\xff]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])+(?:['’](?:d|ll|m|re|s|t|ve))?|[A-Z\xc0-\xd6\xd8-\xde]+(?:['’](?:D|LL|M|RE|S|T|VE))?|\d*(?:1ST|2ND|3RD|(?![123])\dTH)(?=\b|[a-z_])|\d*(?:1st|2nd|3rd|(?![123])\dth)(?=\b|[A-Z_])|\d+|(?:[\u2700-\u27bf]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff])[\ufe0e\ufe0f]?(?:[\u0300-\u036f\ufe20-\ufe2f\u20d0-\u20ff]|\ud83c[\udffb-\udfff])?(?:\u200d(?:[^\ud800-\udfff]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff])[\ufe0e\ufe0f]?(?:[\u0300-\u036f\ufe20-\ufe2f\u20d0-\u20ff]|\ud83c[\udffb-\udfff])?)*/g,e=f=>f.match(t)||[],n=f=>f[0].toUpperCase()+f.slice(1),r=(f,p)=>e(f).join(p).toLowerCase(),o=f=>e(f).reduce((p,g)=>`${p}${p?g[0].toUpperCase()+g.slice(1).toLowerCase():g.toLowerCase()}`,"");return x1={words:e,upperFirst:n,camelCase:o,pascalCase:f=>n(o(f)),snakeCase:f=>r(f,"_"),kebabCase:f=>r(f,"-"),sentenceCase:f=>n(r(f," ")),titleCase:f=>e(f).map(n).join(" ")},x1}var S1=Ite(),Tp={exports:{}},nP;function Dte(){if(nP)return Tp.exports;nP=1,Tp.exports=function(o){return t(e(o),o)},Tp.exports.array=t;function t(o,i){var s=o.length,a=new Array(s),l={},u=s,f=n(i),p=r(o);for(i.forEach(function(m){if(!p.has(m[0])||!p.has(m[1]))throw new Error("Unknown node. There is an unknown node in the supplied edges.")});u--;)l[u]||g(o[u],u,new Set);return a;function g(m,y,b){if(b.has(m)){var S;try{S=", node was:"+JSON.stringify(m)}catch{S=""}throw new Error("Cyclic dependency"+S)}if(!p.has(m))throw new Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(m));if(!l[y]){l[y]=!0;var C=f.get(m)||new Set;if(C=Array.from(C),y=C.length){b.add(m);do{var T=C[--y];g(T,p.get(T),b)}while(y);b.delete(m)}a[--s]=m}}}function e(o){for(var i=new Set,s=0,a=o.length;s<a;s++){var l=o[s];i.add(l[0]),i.add(l[1])}return Array.from(i)}function n(o){for(var i=new Map,s=0,a=o.length;s<a;s++){var l=o[s];i.has(l[0])||i.set(l[0],new Set),i.has(l[1])||i.set(l[1],new Set),i.get(l[0]).add(l[1])}return i}function r(o){for(var i=new Map,s=0,a=o.length;s<a;s++)i.set(o[s],s);return i}return Tp.exports}var Pte=Dte();const Nte=Zn(Pte),Lte=Object.prototype.toString,Fte=Error.prototype.toString,$te=RegExp.prototype.toString,Bte=typeof Symbol<"u"?Symbol.prototype.toString:()=>"",Rte=/^Symbol\((.*)\)(.*)$/;function zte(t){return t!=+t?"NaN":t===0&&1/t<0?"-0":""+t}function rP(t,e=!1){if(t==null||t===!0||t===!1)return""+t;const n=typeof t;if(n==="number")return zte(t);if(n==="string")return e?`"${t}"`:t;if(n==="function")return"[Function "+(t.name||"anonymous")+"]";if(n==="symbol")return Bte.call(t).replace(Rte,"Symbol($1)");const r=Lte.call(t).slice(8,-1);return r==="Date"?isNaN(t.getTime())?""+t:t.toISOString(t):r==="Error"||t instanceof Error?"["+Fte.call(t)+"]":r==="RegExp"?$te.call(t):null}function Ji(t,e){let n=rP(t,e);return n!==null?n:JSON.stringify(t,function(r,o){let i=rP(this[r],e);return i!==null?i:o},2)}function oP(t){return t==null?[]:[].concat(t)}let iP,sP,aP,Vte=/\$\{\s*(\w+)\s*\}/g;iP=Symbol.toStringTag;class lP{constructor(e,n,r,o){this.name=void 0,this.message=void 0,this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=void 0,this.inner=void 0,this[iP]="Error",this.name="ValidationError",this.value=n,this.path=r,this.type=o,this.errors=[],this.inner=[],oP(e).forEach(i=>{if(fr.isError(i)){this.errors.push(...i.errors);const s=i.inner.length?i.inner:[i];this.inner.push(...s)}else this.errors.push(i)}),this.message=this.errors.length>1?`${this.errors.length} errors occurred`:this.errors[0]}}sP=Symbol.hasInstance,aP=Symbol.toStringTag;class fr extends Error{static formatError(e,n){const r=n.label||n.path||"this";return n=Object.assign({},n,{path:r,originalPath:n.path}),typeof e=="string"?e.replace(Vte,(o,i)=>Ji(n[i])):typeof e=="function"?e(n):e}static isError(e){return e&&e.name==="ValidationError"}constructor(e,n,r,o,i){const s=new lP(e,n,r,o);if(i)return s;super(),this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=[],this.inner=[],this[aP]="Error",this.name=s.name,this.message=s.message,this.type=s.type,this.value=s.value,this.path=s.path,this.errors=s.errors,this.inner=s.inner,Error.captureStackTrace&&Error.captureStackTrace(this,fr)}static[sP](e){return lP[Symbol.hasInstance](e)||super[Symbol.hasInstance](e)}}let Lo={default:"${path} is invalid",required:"${path} is a required field",defined:"${path} must be defined",notNull:"${path} cannot be null",oneOf:"${path} must be one of the following values: ${values}",notOneOf:"${path} must not be one of the following values: ${values}",notType:({path:t,type:e,value:n,originalValue:r})=>{const o=r!=null&&r!==n?` (cast from the value \`${Ji(r,!0)}\`).`:".";return e!=="mixed"?`${t} must be a \`${e}\` type, but the final value was: \`${Ji(n,!0)}\``+o:`${t} must match the configured type. The validated value was: \`${Ji(n,!0)}\``+o}},pr={length:"${path} must be exactly ${length} characters",min:"${path} must be at least ${min} characters",max:"${path} must be at most ${max} characters",matches:'${path} must match the following: "${regex}"',email:"${path} must be a valid email",url:"${path} must be a valid URL",uuid:"${path} must be a valid UUID",datetime:"${path} must be a valid ISO date-time",datetime_precision:"${path} must be a valid ISO date-time with a sub-second precision of exactly ${precision} digits",datetime_offset:'${path} must be a valid ISO date-time with UTC "Z" timezone',trim:"${path} must be a trimmed string",lowercase:"${path} must be a lowercase string",uppercase:"${path} must be a upper case string"},Hte={min:"${path} must be greater than or equal to ${min}",max:"${path} must be less than or equal to ${max}",lessThan:"${path} must be less than ${less}",moreThan:"${path} must be greater than ${more}",positive:"${path} must be a positive number",negative:"${path} must be a negative number",integer:"${path} must be an integer"},C1={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"},jte={isValue:"${path} field must be ${value}"},kp={noUnknown:"${path} field has unspecified keys: ${unknown}",exact:"${path} object contains unknown properties: ${properties}"};Object.assign(Object.create(null),{mixed:Lo,string:pr,number:Hte,date:C1,object:kp,array:{min:"${path} field must have at least ${min} items",max:"${path} field must have less than or equal to ${max} items",length:"${path} must have ${length} items"},boolean:jte,tuple:{notType:t=>{const{path:e,value:n,spec:r}=t,o=r.types.length;if(Array.isArray(n)){if(n.length<o)return`${e} tuple value has too few items, expected a length of ${o} but got ${n.length} for value: \`${Ji(n,!0)}\``;if(n.length>o)return`${e} tuple value has too many items, expected a length of ${o} but got ${n.length} for value: \`${Ji(n,!0)}\``}return fr.formatError(Lo.notType,t)}}});const w1=t=>t&&t.__isYupSchema__;class Ep{static fromOptions(e,n){if(!n.then&&!n.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");let{is:r,then:o,otherwise:i}=n,s=typeof r=="function"?r:(...a)=>a.every(l=>l===r);return new Ep(e,(a,l)=>{var u;let f=s(...a)?o:i;return(u=f==null?void 0:f(l))!=null?u:l})}constructor(e,n){this.fn=void 0,this.refs=e,this.refs=e,this.fn=n}resolve(e,n){let r=this.refs.map(i=>i.getValue(n==null?void 0:n.value,n==null?void 0:n.parent,n==null?void 0:n.context)),o=this.fn(r,e,n);if(o===void 0||o===e)return e;if(!w1(o))throw new TypeError("conditions must return a schema object");return o.resolve(n)}}const Mp={context:"$",value:"."};class Us{constructor(e,n={}){if(this.key=void 0,this.isContext=void 0,this.isValue=void 0,this.isSibling=void 0,this.path=void 0,this.getter=void 0,this.map=void 0,typeof e!="string")throw new TypeError("ref must be a string, got: "+e);if(this.key=e.trim(),e==="")throw new TypeError("ref must be a non-empty string");this.isContext=this.key[0]===Mp.context,this.isValue=this.key[0]===Mp.value,this.isSibling=!this.isContext&&!this.isValue;let r=this.isContext?Mp.context:this.isValue?Mp.value:"";this.path=this.key.slice(r.length),this.getter=this.path&&qs.getter(this.path,!0),this.map=n.map}getValue(e,n,r){let o=this.isContext?r:this.isValue?e:n;return this.getter&&(o=this.getter(o||{})),this.map&&(o=this.map(o)),o}cast(e,n){return this.getValue(e,n==null?void 0:n.parent,n==null?void 0:n.context)}resolve(){return this}describe(){return{type:"ref",key:this.key}}toString(){return`Ref(${this.key})`}static isRef(e){return e&&e.__isYupRef}}Us.prototype.__isYupRef=!0;const Ks=t=>t==null;function tl(t){function e({value:n,path:r="",options:o,originalValue:i,schema:s},a,l){const{name:u,test:f,params:p,message:g,skipAbsent:m}=t;let{parent:y,context:b,abortEarly:S=s.spec.abortEarly,disableStackTrace:C=s.spec.disableStackTrace}=o;function T(A){return Us.isRef(A)?A.getValue(n,y,b):A}function _(A={}){const N=Object.assign({value:n,originalValue:i,label:s.spec.label,path:A.path||r,spec:s.spec,disableStackTrace:A.disableStackTrace||C},p,A.params);for(const V of Object.keys(N))N[V]=T(N[V]);const z=new fr(fr.formatError(A.message||g,N),n,N.path,A.type||u,N.disableStackTrace);return z.params=N,z}const w=S?a:l;let E={path:r,parent:y,type:u,from:o.from,createError:_,resolve:T,options:o,originalValue:i,schema:s};const O=A=>{fr.isError(A)?w(A):A?l(null):w(_())},L=A=>{fr.isError(A)?w(A):a(A)};if(m&&Ks(n))return O(!0);let $;try{var M;if($=f.call(E,n,E),typeof((M=$)==null?void 0:M.then)=="function"){if(o.sync)throw new Error(`Validation test of type: "${E.type}" returned a Promise during a synchronous validate. This test will finish after the validate call has returned`);return Promise.resolve($).then(O,L)}}catch(A){L(A);return}O($)}return e.OPTIONS=t,e}function Wte(t,e,n,r=n){let o,i,s;return e?(qs.forEach(e,(a,l,u)=>{let f=l?a.slice(1,a.length-1):a;t=t.resolve({context:r,parent:o,value:n});let p=t.type==="tuple",g=u?parseInt(f,10):0;if(t.innerType||p){if(p&&!u)throw new Error(`Yup.reach cannot implicitly index into a tuple type. the path part "${s}" must contain an index to the tuple element, e.g. "${s}[0]"`);if(n&&g>=n.length)throw new Error(`Yup.reach cannot resolve an array item at index: ${a}, in the path: ${e}. because there is no value at that index. `);o=n,n=n&&n[g],t=p?t.spec.types[g]:t.innerType}if(!u){if(!t.fields||!t.fields[f])throw new Error(`The schema does not contain the path: ${e}. (failed at: ${s} which is a type: "${t.type}")`);o=n,n=n&&n[f],t=t.fields[f]}i=f,s=l?"["+a+"]":"."+a}),{schema:t,parent:o,parentPath:i}):{parent:o,parentPath:e,schema:t}}class Op extends Set{describe(){const e=[];for(const n of this.values())e.push(Us.isRef(n)?n.describe():n);return e}resolveAll(e){let n=[];for(const r of this.values())n.push(e(r));return n}clone(){return new Op(this.values())}merge(e,n){const r=this.clone();return e.forEach(o=>r.add(o)),n.forEach(o=>r.delete(o)),r}}function nl(t,e=new Map){if(w1(t)||!t||typeof t!="object")return t;if(e.has(t))return e.get(t);let n;if(t instanceof Date)n=new Date(t.getTime()),e.set(t,n);else if(t instanceof RegExp)n=new RegExp(t),e.set(t,n);else if(Array.isArray(t)){n=new Array(t.length),e.set(t,n);for(let r=0;r<t.length;r++)n[r]=nl(t[r],e)}else if(t instanceof Map){n=new Map,e.set(t,n);for(const[r,o]of t.entries())n.set(r,nl(o,e))}else if(t instanceof Set){n=new Set,e.set(t,n);for(const r of t)n.add(nl(r,e))}else if(t instanceof Object){n={},e.set(t,n);for(const[r,o]of Object.entries(t))n[r]=nl(o,e)}else throw Error(`Unable to clone ${t}`);return n}class Fo{constructor(e){this.type=void 0,this.deps=[],this.tests=void 0,this.transforms=void 0,this.conditions=[],this._mutate=void 0,this.internalTests={},this._whitelist=new Op,this._blacklist=new Op,this.exclusiveTests=Object.create(null),this._typeCheck=void 0,this.spec=void 0,this.tests=[],this.transforms=[],this.withMutation(()=>{this.typeError(Lo.notType)}),this.type=e.type,this._typeCheck=e.check,this.spec=Object.assign({strip:!1,strict:!1,abortEarly:!0,recursive:!0,disableStackTrace:!1,nullable:!1,optional:!0,coerce:!0},e==null?void 0:e.spec),this.withMutation(n=>{n.nonNullable()})}get _type(){return this.type}clone(e){if(this._mutate)return e&&Object.assign(this.spec,e),this;const n=Object.create(Object.getPrototypeOf(this));return n.type=this.type,n._typeCheck=this._typeCheck,n._whitelist=this._whitelist.clone(),n._blacklist=this._blacklist.clone(),n.internalTests=Object.assign({},this.internalTests),n.exclusiveTests=Object.assign({},this.exclusiveTests),n.deps=[...this.deps],n.conditions=[...this.conditions],n.tests=[...this.tests],n.transforms=[...this.transforms],n.spec=nl(Object.assign({},this.spec,e)),n}label(e){let n=this.clone();return n.spec.label=e,n}meta(...e){if(e.length===0)return this.spec.meta;let n=this.clone();return n.spec.meta=Object.assign(n.spec.meta||{},e[0]),n}withMutation(e){let n=this._mutate;this._mutate=!0;let r=e(this);return this._mutate=n,r}concat(e){if(!e||e===this)return this;if(e.type!==this.type&&this.type!=="mixed")throw new TypeError(`You cannot \`concat()\` schema's of different types: ${this.type} and ${e.type}`);let n=this,r=e.clone();const o=Object.assign({},n.spec,r.spec);return r.spec=o,r.internalTests=Object.assign({},n.internalTests,r.internalTests),r._whitelist=n._whitelist.merge(e._whitelist,e._blacklist),r._blacklist=n._blacklist.merge(e._blacklist,e._whitelist),r.tests=n.tests,r.exclusiveTests=n.exclusiveTests,r.withMutation(i=>{e.tests.forEach(s=>{i.test(s.OPTIONS)})}),r.transforms=[...n.transforms,...r.transforms],r}isType(e){return e==null?!!(this.spec.nullable&&e===null||this.spec.optional&&e===void 0):this._typeCheck(e)}resolve(e){let n=this;if(n.conditions.length){let r=n.conditions;n=n.clone(),n.conditions=[],n=r.reduce((o,i)=>i.resolve(o,e),n),n=n.resolve(e)}return n}resolveOptions(e){var n,r,o,i;return Object.assign({},e,{from:e.from||[],strict:(n=e.strict)!=null?n:this.spec.strict,abortEarly:(r=e.abortEarly)!=null?r:this.spec.abortEarly,recursive:(o=e.recursive)!=null?o:this.spec.recursive,disableStackTrace:(i=e.disableStackTrace)!=null?i:this.spec.disableStackTrace})}cast(e,n={}){let r=this.resolve(Object.assign({value:e},n)),o=n.assert==="ignore-optionality",i=r._cast(e,n);if(n.assert!==!1&&!r.isType(i)){if(o&&Ks(i))return i;let s=Ji(e),a=Ji(i);throw new TypeError(`The value of ${n.path||"field"} could not be cast to a value that satisfies the schema type: "${r.type}".
|
|
401
401
|
|
|
402
402
|
attempted value: ${s}
|
|
403
|
-
`+(a!==s?`result of cast: ${a}`:""))}return i}_cast(e,n){let r=e===void 0?e:this.transforms.reduce((o,i)=>i.call(this,o,e,this),e);return r===void 0&&(r=this.getDefault(n)),r}_validate(e,n={},r,o){let{path:i,originalValue:s=e,strict:a=this.spec.strict}=n,l=e;a||(l=this._cast(l,Object.assign({assert:!1},n)));let u=[];for(let f of Object.values(this.internalTests))f&&u.push(f);this.runTests({path:i,value:l,originalValue:s,options:n,tests:u},r,f=>{if(f.length)return o(f,l);this.runTests({path:i,value:l,originalValue:s,options:n,tests:this.tests},r,o)})}runTests(e,n,r){let o=!1,{tests:i,value:s,originalValue:a,path:l,options:u}=e,f=b=>{o||(o=!0,n(b,s))},p=b=>{o||(o=!0,r(b,s))},g=i.length,m=[];if(!g)return p([]);let y={value:s,originalValue:a,path:l,options:u,schema:this};for(let b=0;b<i.length;b++){const S=i[b];S(y,f,function(T){T&&(Array.isArray(T)?m.push(...T):m.push(T)),--g<=0&&p(m)})}}asNestedTest({key:e,index:n,parent:r,parentPath:o,originalParent:i,options:s}){const a=e??n;if(a==null)throw TypeError("Must include `key` or `index` for nested validations");const l=typeof a=="number";let u=r[a];const f=Object.assign({},s,{strict:!0,parent:r,value:u,originalValue:i[a],key:void 0,[l?"index":"key"]:a,path:l||a.includes(".")?`${o||""}[${l?a:`"${a}"`}]`:(o?`${o}.`:"")+e});return(p,g,m)=>this.resolve(f)._validate(u,f,g,m)}validate(e,n){var r;let o=this.resolve(Object.assign({},n,{value:e})),i=(r=n==null?void 0:n.disableStackTrace)!=null?r:o.spec.disableStackTrace;return new Promise((s,a)=>o._validate(e,n,(l,u)=>{fr.isError(l)&&(l.value=u),a(l)},(l,u)=>{l.length?a(new fr(l,u,void 0,void 0,i)):s(u)}))}validateSync(e,n){var r;let o=this.resolve(Object.assign({},n,{value:e})),i,s=(r=n==null?void 0:n.disableStackTrace)!=null?r:o.spec.disableStackTrace;return o._validate(e,Object.assign({},n,{sync:!0}),(a,l)=>{throw fr.isError(a)&&(a.value=l),a},(a,l)=>{if(a.length)throw new fr(a,e,void 0,void 0,s);i=l}),i}isValid(e,n){return this.validate(e,n).then(()=>!0,r=>{if(fr.isError(r))return!1;throw r})}isValidSync(e,n){try{return this.validateSync(e,n),!0}catch(r){if(fr.isError(r))return!1;throw r}}_getDefault(e){let n=this.spec.default;return n==null?n:typeof n=="function"?n.call(this,e):nl(n)}getDefault(e){return this.resolve(e||{})._getDefault(e)}default(e){return arguments.length===0?this._getDefault():this.clone({default:e})}strict(e=!0){return this.clone({strict:e})}nullability(e,n){const r=this.clone({nullable:e});return r.internalTests.nullable=tl({message:n,name:"nullable",test(o){return o===null?this.schema.spec.nullable:!0}}),r}optionality(e,n){const r=this.clone({optional:e});return r.internalTests.optionality=tl({message:n,name:"optionality",test(o){return o===void 0?this.schema.spec.optional:!0}}),r}optional(){return this.optionality(!0)}defined(e=Lo.defined){return this.optionality(!1,e)}nullable(){return this.nullability(!0)}nonNullable(e=Lo.notNull){return this.nullability(!1,e)}required(e=Lo.required){return this.clone().withMutation(n=>n.nonNullable(e).defined(e))}notRequired(){return this.clone().withMutation(e=>e.nullable().optional())}transform(e){let n=this.clone();return n.transforms.push(e),n}test(...e){let n;if(e.length===1?typeof e[0]=="function"?n={test:e[0]}:n=e[0]:e.length===2?n={name:e[0],test:e[1]}:n={name:e[0],message:e[1],test:e[2]},n.message===void 0&&(n.message=Lo.default),typeof n.test!="function")throw new TypeError("`test` is a required parameters");let r=this.clone(),o=tl(n),i=n.exclusive||n.name&&r.exclusiveTests[n.name]===!0;if(n.exclusive&&!n.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return n.name&&(r.exclusiveTests[n.name]=!!n.exclusive),r.tests=r.tests.filter(s=>!(s.OPTIONS.name===n.name&&(i||s.OPTIONS.test===o.OPTIONS.test))),r.tests.push(o),r}when(e,n){!Array.isArray(e)&&typeof e!="string"&&(n=e,e=".");let r=this.clone(),o=oP(e).map(i=>new Us(i));return o.forEach(i=>{i.isSibling&&r.deps.push(i.key)}),r.conditions.push(typeof n=="function"?new Ep(o,n):Ep.fromOptions(o,n)),r}typeError(e){let n=this.clone();return n.internalTests.typeError=tl({message:e,name:"typeError",skipAbsent:!0,test(r){return this.schema._typeCheck(r)?!0:this.createError({params:{type:this.schema.type}})}}),n}oneOf(e,n=Lo.oneOf){let r=this.clone();return e.forEach(o=>{r._whitelist.add(o),r._blacklist.delete(o)}),r.internalTests.whiteList=tl({message:n,name:"oneOf",skipAbsent:!0,test(o){let i=this.schema._whitelist,s=i.resolveAll(this.resolve);return s.includes(o)?!0:this.createError({params:{values:Array.from(i).join(", "),resolved:s}})}}),r}notOneOf(e,n=Lo.notOneOf){let r=this.clone();return e.forEach(o=>{r._blacklist.add(o),r._whitelist.delete(o)}),r.internalTests.blacklist=tl({message:n,name:"notOneOf",test(o){let i=this.schema._blacklist,s=i.resolveAll(this.resolve);return s.includes(o)?this.createError({params:{values:Array.from(i).join(", "),resolved:s}}):!0}}),r}strip(e=!0){let n=this.clone();return n.spec.strip=e,n}describe(e){const n=(e?this.resolve(e):this).clone(),{label:r,meta:o,optional:i,nullable:s}=n.spec;return{meta:o,label:r,optional:i,nullable:s,default:n.getDefault(e),type:n.type,oneOf:n._whitelist.describe(),notOneOf:n._blacklist.describe(),tests:n.tests.map(l=>({name:l.OPTIONS.name,params:l.OPTIONS.params})).filter((l,u,f)=>f.findIndex(p=>p.name===l.name)===u)}}}Fo.prototype.__isYupSchema__=!0;for(const t of["validate","validateSync"])Fo.prototype[`${t}At`]=function(e,n,r={}){const{parent:o,parentPath:i,schema:s}=Wte(this,e,n,r.context);return s[t](o&&o[i],Object.assign({},r,{parent:o,path:e}))};for(const t of["equals","is"])Fo.prototype[t]=Fo.prototype.oneOf;for(const t of["not","nope"])Fo.prototype[t]=Fo.prototype.notOneOf;const qte=/^(\d{4}|[+-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,.](\d{1,}))?)?(?:(Z)|([+-])(\d{2})(?::?(\d{2}))?)?)?$/;function Ute(t){const e=_1(t);if(!e)return Date.parse?Date.parse(t):Number.NaN;if(e.z===void 0&&e.plusMinus===void 0)return new Date(e.year,e.month,e.day,e.hour,e.minute,e.second,e.millisecond).valueOf();let n=0;return e.z!=="Z"&&e.plusMinus!==void 0&&(n=e.hourOffset*60+e.minuteOffset,e.plusMinus==="+"&&(n=0-n)),Date.UTC(e.year,e.month,e.day,e.hour,e.minute+n,e.second,e.millisecond)}function _1(t){var e,n;const r=qte.exec(t);return r?{year:ii(r[1]),month:ii(r[2],1)-1,day:ii(r[3],1),hour:ii(r[4]),minute:ii(r[5]),second:ii(r[6]),millisecond:r[7]?ii(r[7].substring(0,3)):0,precision:(e=(n=r[7])==null?void 0:n.length)!=null?e:void 0,z:r[8]||void 0,plusMinus:r[9]||void 0,hourOffset:ii(r[10]),minuteOffset:ii(r[11])}:null}function ii(t,e=0){return Number(t)||e}let Kte=/^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,Yte=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,Gte=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,Jte="^\\d{4}-\\d{2}-\\d{2}",Zte="\\d{2}:\\d{2}:\\d{2}",Xte="(([+-]\\d{2}(:?\\d{2})?)|Z)",Qte=new RegExp(`${Jte}T${Zte}(\\.\\d+)?${Xte}$`),ene=t=>Ks(t)||t===t.trim(),tne={}.toString();function T1(){return new cP}class cP extends Fo{constructor(){super({type:"string",check(e){return e instanceof String&&(e=e.valueOf()),typeof e=="string"}}),this.withMutation(()=>{this.transform((e,n,r)=>{if(!r.spec.coerce||r.isType(e)||Array.isArray(e))return e;const o=e!=null&&e.toString?e.toString():e;return o===tne?e:o})})}required(e){return super.required(e).withMutation(n=>n.test({message:e||Lo.required,name:"required",skipAbsent:!0,test:r=>!!r.length}))}notRequired(){return super.notRequired().withMutation(e=>(e.tests=e.tests.filter(n=>n.OPTIONS.name!=="required"),e))}length(e,n=pr.length){return this.test({message:n,name:"length",exclusive:!0,params:{length:e},skipAbsent:!0,test(r){return r.length===this.resolve(e)}})}min(e,n=pr.min){return this.test({message:n,name:"min",exclusive:!0,params:{min:e},skipAbsent:!0,test(r){return r.length>=this.resolve(e)}})}max(e,n=pr.max){return this.test({name:"max",exclusive:!0,message:n,params:{max:e},skipAbsent:!0,test(r){return r.length<=this.resolve(e)}})}matches(e,n){let r=!1,o,i;return n&&(typeof n=="object"?{excludeEmptyString:r=!1,message:o,name:i}=n:o=n),this.test({name:i||"matches",message:o||pr.matches,params:{regex:e},skipAbsent:!0,test:s=>s===""&&r||s.search(e)!==-1})}email(e=pr.email){return this.matches(Kte,{name:"email",message:e,excludeEmptyString:!0})}url(e=pr.url){return this.matches(Yte,{name:"url",message:e,excludeEmptyString:!0})}uuid(e=pr.uuid){return this.matches(Gte,{name:"uuid",message:e,excludeEmptyString:!1})}datetime(e){let n="",r,o;return e&&(typeof e=="object"?{message:n="",allowOffset:r=!1,precision:o=void 0}=e:n=e),this.matches(Qte,{name:"datetime",message:n||pr.datetime,excludeEmptyString:!0}).test({name:"datetime_offset",message:n||pr.datetime_offset,params:{allowOffset:r},skipAbsent:!0,test:i=>{if(!i||r)return!0;const s=_1(i);return s?!!s.z:!1}}).test({name:"datetime_precision",message:n||pr.datetime_precision,params:{precision:o},skipAbsent:!0,test:i=>{if(!i||o==null)return!0;const s=_1(i);return s?s.precision===o:!1}})}ensure(){return this.default("").transform(e=>e===null?"":e)}trim(e=pr.trim){return this.transform(n=>n!=null?n.trim():n).test({message:e,name:"trim",test:ene})}lowercase(e=pr.lowercase){return this.transform(n=>Ks(n)?n:n.toLowerCase()).test({message:e,name:"string_case",exclusive:!0,skipAbsent:!0,test:n=>Ks(n)||n===n.toLowerCase()})}uppercase(e=pr.uppercase){return this.transform(n=>Ks(n)?n:n.toUpperCase()).test({message:e,name:"string_case",exclusive:!0,skipAbsent:!0,test:n=>Ks(n)||n===n.toUpperCase()})}}T1.prototype=cP.prototype;let nne=new Date(""),rne=t=>Object.prototype.toString.call(t)==="[object Date]";class Ap extends Fo{constructor(){super({type:"date",check(e){return rne(e)&&!isNaN(e.getTime())}}),this.withMutation(()=>{this.transform((e,n,r)=>!r.spec.coerce||r.isType(e)||e===null?e:(e=Ute(e),isNaN(e)?Ap.INVALID_DATE:new Date(e)))})}prepareParam(e,n){let r;if(Us.isRef(e))r=e;else{let o=this.cast(e);if(!this._typeCheck(o))throw new TypeError(`\`${n}\` must be a Date or a value that can be \`cast()\` to a Date`);r=o}return r}min(e,n=C1.min){let r=this.prepareParam(e,"min");return this.test({message:n,name:"min",exclusive:!0,params:{min:e},skipAbsent:!0,test(o){return o>=this.resolve(r)}})}max(e,n=C1.max){let r=this.prepareParam(e,"max");return this.test({message:n,name:"max",exclusive:!0,params:{max:e},skipAbsent:!0,test(o){return o<=this.resolve(r)}})}}Ap.INVALID_DATE=nne,Ap.prototype;function one(t,e=[]){let n=[],r=new Set,o=new Set(e.map(([s,a])=>`${s}-${a}`));function i(s,a){let l=qs.split(s)[0];r.add(l),o.has(`${a}-${l}`)||n.push([a,l])}for(const s of Object.keys(t)){let a=t[s];r.add(s),Us.isRef(a)&&a.isSibling?i(a.path,s):w1(a)&&"deps"in a&&a.deps.forEach(l=>i(l,s))}return Nte.array(Array.from(r),n).reverse()}function uP(t,e){let n=1/0;return t.some((r,o)=>{var i;if((i=e.path)!=null&&i.includes(r))return n=o,!0}),n}function dP(t){return(e,n)=>uP(t,e)-uP(t,n)}const ine=(t,e,n)=>{if(typeof t!="string")return t;let r=t;try{r=JSON.parse(t)}catch{}return n.isType(r)?r:t};function Ip(t){if("fields"in t){const e={};for(const[n,r]of Object.entries(t.fields))e[n]=Ip(r);return t.setFields(e)}if(t.type==="array"){const e=t.optional();return e.innerType&&(e.innerType=Ip(e.innerType)),e}return t.type==="tuple"?t.optional().clone({types:t.spec.types.map(Ip)}):"optional"in t?t.optional():t}const sne=(t,e)=>{const n=[...qs.normalizePath(e)];if(n.length===1)return n[0]in t;let r=n.pop(),o=qs.getter(qs.join(n),!0)(t);return!!(o&&r in o)};let fP=t=>Object.prototype.toString.call(t)==="[object Object]";function pP(t,e){let n=Object.keys(t.fields);return Object.keys(e).filter(r=>n.indexOf(r)===-1)}const ane=dP([]);function hP(t){return new gP(t)}class gP extends Fo{constructor(e){super({type:"object",check(n){return fP(n)||typeof n=="function"}}),this.fields=Object.create(null),this._sortErrors=ane,this._nodes=[],this._excludedEdges=[],this.withMutation(()=>{e&&this.shape(e)})}_cast(e,n={}){var r;let o=super._cast(e,n);if(o===void 0)return this.getDefault(n);if(!this._typeCheck(o))return o;let i=this.fields,s=(r=n.stripUnknown)!=null?r:this.spec.noUnknown,a=[].concat(this._nodes,Object.keys(o).filter(p=>!this._nodes.includes(p))),l={},u=Object.assign({},n,{parent:l,__validating:n.__validating||!1}),f=!1;for(const p of a){let g=i[p],m=p in o;if(g){let y,b=o[p];u.path=(n.path?`${n.path}.`:"")+p,g=g.resolve({value:b,context:n.context,parent:l});let S=g instanceof Fo?g.spec:void 0,C=S==null?void 0:S.strict;if(S!=null&&S.strip){f=f||p in o;continue}y=!n.__validating||!C?g.cast(o[p],u):o[p],y!==void 0&&(l[p]=y)}else m&&!s&&(l[p]=o[p]);(m!==p in l||l[p]!==o[p])&&(f=!0)}return f?l:o}_validate(e,n={},r,o){let{from:i=[],originalValue:s=e,recursive:a=this.spec.recursive}=n;n.from=[{schema:this,value:s},...i],n.__validating=!0,n.originalValue=s,super._validate(e,n,r,(l,u)=>{if(!a||!fP(u)){o(l,u);return}s=s||u;let f=[];for(let p of this._nodes){let g=this.fields[p];!g||Us.isRef(g)||f.push(g.asNestedTest({options:n,key:p,parent:u,parentPath:n.path,originalParent:s}))}this.runTests({tests:f,value:u,originalValue:s,options:n},r,p=>{o(p.sort(this._sortErrors).concat(l),u)})})}clone(e){const n=super.clone(e);return n.fields=Object.assign({},this.fields),n._nodes=this._nodes,n._excludedEdges=this._excludedEdges,n._sortErrors=this._sortErrors,n}concat(e){let n=super.concat(e),r=n.fields;for(let[o,i]of Object.entries(this.fields)){const s=r[o];r[o]=s===void 0?i:s}return n.withMutation(o=>o.setFields(r,[...this._excludedEdges,...e._excludedEdges]))}_getDefault(e){if("default"in this.spec)return super._getDefault(e);if(!this._nodes.length)return;let n={};return this._nodes.forEach(r=>{var o;const i=this.fields[r];let s=e;(o=s)!=null&&o.value&&(s=Object.assign({},s,{parent:s.value,value:s.value[r]})),n[r]=i&&"getDefault"in i?i.getDefault(s):void 0}),n}setFields(e,n){let r=this.clone();return r.fields=e,r._nodes=one(e,n),r._sortErrors=dP(Object.keys(e)),n&&(r._excludedEdges=n),r}shape(e,n=[]){return this.clone().withMutation(r=>{let o=r._excludedEdges;return n.length&&(Array.isArray(n[0])||(n=[n]),o=[...r._excludedEdges,...n]),r.setFields(Object.assign(r.fields,e),o)})}partial(){const e={};for(const[n,r]of Object.entries(this.fields))e[n]="optional"in r&&r.optional instanceof Function?r.optional():r;return this.setFields(e)}deepPartial(){return Ip(this)}pick(e){const n={};for(const r of e)this.fields[r]&&(n[r]=this.fields[r]);return this.setFields(n,this._excludedEdges.filter(([r,o])=>e.includes(r)&&e.includes(o)))}omit(e){const n=[];for(const r of Object.keys(this.fields))e.includes(r)||n.push(r);return this.pick(n)}from(e,n,r){let o=qs.getter(e,!0);return this.transform(i=>{if(!i)return i;let s=i;return sne(i,e)&&(s=Object.assign({},i),r||delete s[e],s[n]=o(i)),s})}json(){return this.transform(ine)}exact(e){return this.test({name:"exact",exclusive:!0,message:e||kp.exact,test(n){if(n==null)return!0;const r=pP(this.schema,n);return r.length===0||this.createError({params:{properties:r.join(", ")}})}})}stripUnknown(){return this.clone({noUnknown:!0})}noUnknown(e=!0,n=kp.noUnknown){typeof e!="boolean"&&(n=e,e=!0);let r=this.test({name:"noUnknown",exclusive:!0,message:n,test(o){if(o==null)return!0;const i=pP(this.schema,o);return!e||i.length===0||this.createError({params:{unknown:i.join(", ")}})}});return r.spec.noUnknown=e,r}unknown(e=!0,n=kp.noUnknown){return this.noUnknown(!e,n)}transformKeys(e){return this.transform(n=>{if(!n)return n;const r={};for(const o of Object.keys(n))r[e(o)]=n[o];return r})}camelCase(){return this.transformKeys(S1.camelCase)}snakeCase(){return this.transformKeys(S1.snakeCase)}constantCase(){return this.transformKeys(e=>S1.snakeCase(e).toUpperCase())}describe(e){const n=(e?this.resolve(e):this).clone(),r=super.describe(e);r.fields={};for(const[i,s]of Object.entries(n.fields)){var o;let a=e;(o=a)!=null&&o.value&&(a=Object.assign({},a,{parent:a.value,value:a.value[i]})),r.fields[i]=s.describe(a)}return r}}hP.prototype=gP.prototype;const lne=t=>{const{id:e,title:n,onSave:r,onCancel:o,getCitationById:i,disableFileUpload:s=!1,setError:a}=t,l=J.useRef(null),[u,f]=J.useState(!0),[p,g]=J.useState({type:"Attachment",title:"",file:void 0,fileName:""});return J.useEffect(()=>{if(e===void 0){f(!1);return}i(e).then(m=>{g({...m,type:"Attachment",file:void 0}),f(!1)}).catch(m=>{f(!1),a({title:"Failed to retrieve attachment",err:m})})},[]),v.jsxs(v.Fragment,{children:[n&&v.jsx(F.Typography,{variant:"h6",margin:"10px 0",children:n}),v.jsx(jt.Formik,{innerRef:l,enableReinitialize:!0,initialValues:p,validationSchema:hP().shape({title:T1().required("Title is required"),fileName:T1().required("A file is required")}),onSubmit:async m=>{f(!0),r(m).catch(y=>{f(!1),a({title:`Failed to ${e===void 0?"save":"update"} attachment`,err:y})}).finally(()=>f(!1))},children:({values:m,setFieldValue:y})=>{var b;return J.useEffect(()=>{var S,C;(S=m.file)!=null&&S.name&&y("fileName",(C=m.file)==null?void 0:C.name)},[(b=m.file)==null?void 0:b.name]),v.jsxs(jt.Form,{autoComplete:"off",children:[v.jsx(da,{name:"title",disabled:u,required:!0,margin:"none"}),v.jsxs(F.Box,{display:"flex",flexDirection:"row",alignItems:"flex-start",children:[v.jsx(gC,{name:"file",readOnly:s}),m.fileName&&v.jsx("span",{style:{margin:"6px 0 0 10px"},children:m.fileName}),v.jsx(Xn,{name:"fileName",id:"fileName-err"})]}),v.jsxs(F.DialogActions,{sx:{px:0},children:[v.jsx(F.Button,{onClick:o,variant:"outlined",size:"small",children:"Cancel"}),v.jsx(b1,{size:"small",loading:u,children:e?"Update Attachment":"Add New Attachment"})]})]})}})]})},ou=t=>{const{open:e=!1,onClose:n,title:r,children:o,actions:i,closeBtnLabel:s,closeButtonPosition:a,closeButtonProps:l={},disableDismiss:u=!1,...f}=t;if(!e)return null;const p=a==="bottom"||a==="top-and-bottom",g=a==="top"||a==="top-and-bottom",m=()=>{if(s&&p)return v.jsx(F.Button,{className:"MBv2_Modal_Close",onClick:t.onClose,...l,children:s})},y=()=>{if(i)return v.jsx(F.DialogActions,{className:"MBv2_Modal_Actions",children:v.jsxs(F.Box,{display:"flex",flexDirection:"row",justifyContent:"space-between",width:"100%",gap:"0.25rem",children:[v.jsx(F.Box,{children:m()}),v.jsxs(F.Box,{display:"flex",gap:".25rem",children:[...i]})]})});if(s&&p)return v.jsx(F.DialogActions,{className:"MBv2_Modal_Actions",children:v.jsx(F.Box,{children:m()})})};return v.jsxs(F.Dialog,{className:"MBv2_Modal",open:e,onClose:()=>{u||n==null||n()},...f,children:[typeof r=="string"?v.jsx(F.DialogTitle,{className:"MBv2_Modal_Title",children:v.jsxs(F.Box,{display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center",children:[r,g&&v.jsx(F.IconButton,{"data-testid":"modal-header-close-btn",onClick:n,children:v.jsx(sR,{})})]})}):r,o&&(typeof o=="string"?v.jsx(F.DialogContent,{className:"MBv2_Modal_Content",children:v.jsx(F.DialogContentText,{className:"MBv2_Modal_Content_Text",children:o})}):o),y()]})};function cne(t){return Ke("MuiAlert",t)}const mP=qe("MuiAlert",["root","action","icon","message","filled","colorSuccess","colorInfo","colorWarning","colorError","filledSuccess","filledInfo","filledWarning","filledError","outlined","outlinedSuccess","outlinedInfo","outlinedWarning","outlinedError","standard","standardSuccess","standardInfo","standardWarning","standardError"]),une=ze(v.jsx("path",{d:"M20,12A8,8 0 0,1 12,20A8,8 0 0,1 4,12A8,8 0 0,1 12,4C12.76,4 13.5,4.11 14.2, 4.31L15.77,2.74C14.61,2.26 13.34,2 12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0, 0 22,12M7.91,10.08L6.5,11.5L11,16L21,6L19.59,4.58L11,13.17L7.91,10.08Z"}),"SuccessOutlined"),dne=ze(v.jsx("path",{d:"M12 5.99L19.53 19H4.47L12 5.99M12 2L1 21h22L12 2zm1 14h-2v2h2v-2zm0-6h-2v4h2v-4z"}),"ReportProblemOutlined"),fne=ze(v.jsx("path",{d:"M11 15h2v2h-2zm0-8h2v6h-2zm.99-5C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"}),"ErrorOutline"),pne=ze(v.jsx("path",{d:"M11,9H13V7H11M12,20C7.59,20 4,16.41 4,12C4,7.59 7.59,4 12,4C16.41,4 20,7.59 20, 12C20,16.41 16.41,20 12,20M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10, 10 0 0,0 12,2M11,17H13V11H11V17Z"}),"InfoOutlined"),hne=ze(v.jsx("path",{d:"M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}),"Close"),gne=t=>{const{variant:e,color:n,severity:r,classes:o}=t,i={root:["root",`color${Ae(n||r)}`,`${e}${Ae(n||r)}`,`${e}`],icon:["icon"],message:["message"],action:["action"]};return Ue(i,cne,o)},mne=be(ya,{name:"MuiAlert",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,e[n.variant],e[`${n.variant}${Ae(n.color||n.severity)}`]]}})(Dt(({theme:t})=>{const e=t.palette.mode==="light"?ia:Ol,n=t.palette.mode==="light"?Ol:ia;return{...t.typography.body2,backgroundColor:"transparent",display:"flex",padding:"6px 16px",variants:[...Object.entries(t.palette).filter(Hn(["light"])).map(([r])=>({props:{colorSeverity:r,variant:"standard"},style:{color:t.vars?t.vars.palette.Alert[`${r}Color`]:e(t.palette[r].light,.6),backgroundColor:t.vars?t.vars.palette.Alert[`${r}StandardBg`]:n(t.palette[r].light,.9),[`& .${mP.icon}`]:t.vars?{color:t.vars.palette.Alert[`${r}IconColor`]}:{color:t.palette[r].main}}})),...Object.entries(t.palette).filter(Hn(["light"])).map(([r])=>({props:{colorSeverity:r,variant:"outlined"},style:{color:t.vars?t.vars.palette.Alert[`${r}Color`]:e(t.palette[r].light,.6),border:`1px solid ${(t.vars||t).palette[r].light}`,[`& .${mP.icon}`]:t.vars?{color:t.vars.palette.Alert[`${r}IconColor`]}:{color:t.palette[r].main}}})),...Object.entries(t.palette).filter(Hn(["dark"])).map(([r])=>({props:{colorSeverity:r,variant:"filled"},style:{fontWeight:t.typography.fontWeightMedium,...t.vars?{color:t.vars.palette.Alert[`${r}FilledColor`],backgroundColor:t.vars.palette.Alert[`${r}FilledBg`]}:{backgroundColor:t.palette.mode==="dark"?t.palette[r].dark:t.palette[r].main,color:t.palette.getContrastText(t.palette[r].main)}}}))]}})),yne=be("div",{name:"MuiAlert",slot:"Icon",overridesResolver:(t,e)=>e.icon})({marginRight:12,padding:"7px 0",display:"flex",fontSize:22,opacity:.9}),bne=be("div",{name:"MuiAlert",slot:"Message",overridesResolver:(t,e)=>e.message})({padding:"8px 0",minWidth:0,overflow:"auto"}),vne=be("div",{name:"MuiAlert",slot:"Action",overridesResolver:(t,e)=>e.action})({display:"flex",alignItems:"flex-start",padding:"4px 0 0 16px",marginLeft:"auto",marginRight:-8}),yP={success:v.jsx(une,{fontSize:"inherit"}),warning:v.jsx(dne,{fontSize:"inherit"}),error:v.jsx(fne,{fontSize:"inherit"}),info:v.jsx(pne,{fontSize:"inherit"})},bP=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiAlert"}),{action:o,children:i,className:s,closeText:a="Close",color:l,components:u={},componentsProps:f={},icon:p,iconMapping:g=yP,onClose:m,role:y="alert",severity:b="success",slotProps:S={},slots:C={},variant:T="standard",..._}=r,w={...r,color:l,severity:b,variant:T,colorSeverity:l||b},E=gne(w),O={slots:{closeButton:u.CloseButton,closeIcon:u.CloseIcon,...C},slotProps:{...f,...S}},[L,P]=zt("root",{ref:n,shouldForwardComponentProp:!0,className:Le(E.root,s),elementType:mne,externalForwardedProps:{...O,..._},ownerState:w,additionalProps:{role:y,elevation:0}}),[$,M]=zt("icon",{className:E.icon,elementType:yne,externalForwardedProps:O,ownerState:w}),[A,N]=zt("message",{className:E.message,elementType:bne,externalForwardedProps:O,ownerState:w}),[V,R]=zt("action",{className:E.action,elementType:vne,externalForwardedProps:O,ownerState:w}),[B,z]=zt("closeButton",{elementType:Sa,externalForwardedProps:O,ownerState:w}),[q,K]=zt("closeIcon",{elementType:hne,externalForwardedProps:O,ownerState:w});return v.jsxs(L,{...P,children:[p!==!1?v.jsx($,{...M,children:p||g[b]||yP[b]}):null,v.jsx(A,{...N,children:i}),o!=null?v.jsx(V,{...R,children:o}):null,o==null&&m?v.jsx(V,{...R,children:v.jsx(B,{size:"small","aria-label":a,title:a,color:"inherit",onClick:m,...z,children:v.jsx(q,{fontSize:"small",...K})})}):null]})});process.env.NODE_ENV!=="production"&&(bP.propTypes={action:c.node,children:c.node,classes:c.object,className:c.string,closeText:c.string,color:c.oneOfType([c.oneOf(["error","info","success","warning"]),c.string]),components:c.shape({CloseButton:c.elementType,CloseIcon:c.elementType}),componentsProps:c.shape({closeButton:c.object,closeIcon:c.object}),icon:c.node,iconMapping:c.shape({error:c.node,info:c.node,success:c.node,warning:c.node}),onClose:c.func,role:c.string,severity:c.oneOfType([c.oneOf(["error","info","success","warning"]),c.string]),slotProps:c.shape({action:c.oneOfType([c.func,c.object]),closeButton:c.oneOfType([c.func,c.object]),closeIcon:c.oneOfType([c.func,c.object]),icon:c.oneOfType([c.func,c.object]),message:c.oneOfType([c.func,c.object]),root:c.oneOfType([c.func,c.object])}),slots:c.shape({action:c.elementType,closeButton:c.elementType,closeIcon:c.elementType,icon:c.elementType,message:c.elementType,root:c.elementType}),sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),variant:c.oneOfType([c.oneOf(["filled","outlined","standard"]),c.string])});const iu=t=>{var m;const{noIcon:e=!1,children:n,severity:r="success",variant:o="leftBorder",sx:i,title:s,...a}=t,{palette:l}=F.useTheme(),u=e?{icon:!1}:{},f=o==="leftBorder"?"standard":o,p=o==="leftBorder"?{...i,borderLeft:`4px solid ${(m=l[r])==null?void 0:m.main}`}:i,g=s?{icon:{sx:{mt:"6px"}}}:{};return v.jsxs(bP,{severity:r,variant:f,sx:p,slotProps:g,...u,...a,children:[s&&v.jsx(F.Typography,{variant:"h3",children:s}),n]})},vP=t=>v.jsx(iu,{severity:"error",...t}),xP=t=>v.jsx(iu,{severity:"success",...t}),xne=t=>{const{error:e,setError:n,success:r,setSuccess:o}=t;return v.jsxs(v.Fragment,{children:[e&&v.jsx(vP,{"data-testid":"citation-menu-error",onClose:()=>n(void 0),children:e.title}),r&&v.jsx(xP,{"data-testid":"citation-menu-success",onClose:()=>o(void 0),children:r})]})};function k1({getCitationsPaginated:t,onCreateCitation:e,onUpdateCitation:n,onDeleteCitation:r,getCitationById:o,onDownloadAttachment:i,onSelectCitations:s,onCancel:a,initialSelectedIds:l=[],onContentChange:u,onError:f=()=>{},renderAsSelectablePopup:p=!1,addlActions:g}){const[m,y]=J.useState("Insert Citation/Attachment(s)"),[b,S]=J.useState(l),[C,T]=J.useState(void 0),[_,w]=J.useState(void 0),[E,O]=J.useState(void 0);J.useEffect(()=>{u==null||u()},[m,_,E,u]),J.useEffect(()=>{p&&w(void 0)},[m]),J.useEffect(()=>{_&&f(_.err)},[_]);const L=async R=>{if(m==="Edit Citation"||m==="Edit Attachment"){if(R.id===void 0)throw Error("Failed to update citation. Citation is missing id");await n(R).then(()=>y("Insert Citation/Attachment(s)")).catch(B=>w({title:"Failed to update citation",err:B}))}else(m==="Add Citation"||m==="Add Attachment")&&await(e==null?void 0:e(R).then(B=>{S([...b,B.id]),y("Insert Citation/Attachment(s)")}).catch(B=>w({title:"Failed to create citation",err:B})))},P=v.jsx(Mte,{getCitationsPaginated:R=>t(R).then(B=>(u==null||u(),B)),onCancel:a,onNewCitation:()=>{T(void 0),y("Add Citation")},onNewAttachment:()=>{T(void 0),y("Add Attachment")},onEditCitation:R=>{T(R.id),y("Edit Citation")},onEditAttachment:R=>{T(R.id),y("Edit Attachment")},onDeleteCitation:r,onDownloadAttachment:i,onSelect:s,setSelectedIds:S,selectedIds:b,onError:f,setError:w,setSuccess:O,condenseTable:p,canSelect:p,title:p?m:"Attachments & Citations",addlActions:g,canCreate:!!e}),$=v.jsx(Ote,{id:C,onSave:L,onCancel:()=>y("Insert Citation/Attachment(s)"),getCitationById:o,setError:w,title:m}),M=v.jsx(lne,{id:C,onSave:L,onCancel:()=>y("Insert Citation/Attachment(s)"),getCitationById:o,disableFileUpload:m==="Edit Attachment",setError:w,title:m}),A=v.jsx(xne,{error:_,setError:w,success:E,setSuccess:O}),N=m==="Add Citation"||m==="Edit Citation",V=m==="Add Attachment"||m==="Edit Attachment";if(p){let R=null;return!p||m==="Insert Citation/Attachment(s)"?R=P:N?R=$:V&&(R=M),v.jsxs(F.Box,{width:"500px",children:[A,v.jsx(F.Box,{paddingTop:"8px",children:R})]})}return v.jsxs(F.Box,{width:"100%",children:[m==="Insert Citation/Attachment(s)"&&A,v.jsx(F.Box,{paddingTop:"8px",children:P}),v.jsx(ou,{open:N||V,children:v.jsxs(F.Box,{padding:"10px 20px",minWidth:"400px","data-testid":"citation-form-modal",children:[A,N?$:M]})})]})}const Sne=Ut({name:{CitationBubbleMenuTipTap:SP}})(t=>({content:{padding:t.spacing(1.5,2,.5),backgroundColor:"#f9f9f9"}}));function SP({getCitationsPaginated:t,onCreateCitation:e,onUpdateCitation:n,onDeleteCitation:r,getCitationById:o,onDownloadAttachment:i,...s}){const{classes:a}=Sne(),l=bt();if(!(l!=null&&l.isEditable))return null;if(!("citationBubbleMenuHandler"in l.storage))throw new Error("You must add the CitationBubbleMenuHandler extension to the useEditor `extensions` array in order to use this component!");const u=l.storage.citationBubbleMenuHandler,f=u.isOpen,p=u.selectedIds,g=u.selectedNodePos,m=C=>{l&&(C.length===0?l.commands.deleteCitation(g):p.length===0?l.commands.insertCitation({ids:C}):l.commands.updateCitation({ids:C},g))},y=C=>{m(C),l.commands.closeCitationBubbleMenu()},b=()=>{m(p),l.commands.closeCitationBubbleMenu()},S=J.useCallback(()=>{requestAnimationFrame(()=>{l!=null&&l.view&&l.view.dispatch(l.view.state.tr)})},[l]);return v.jsx(Af,{editor:l,open:f,...u.bubbleMenuOptions,...s,children:v.jsx("div",{className:a.content,children:v.jsx(k1,{getCitationsPaginated:t,onCreateCitation:e,onUpdateCitation:n,onDeleteCitation:r,getCitationById:o,onDownloadAttachment:i,onSelectCitations:y,onCancel:b,initialSelectedIds:p,onContentChange:S,renderAsSelectablePopup:!0})})})}const Cne=sn.create({name:"starterKit",addExtensions(){const t=[];return this.options.bold!==!1&&t.push(rD.configure(this.options.bold)),this.options.blockquote!==!1&&t.push(nD.configure(this.options.blockquote)),this.options.bulletList!==!1&&t.push(sD.configure(this.options.bulletList)),this.options.code!==!1&&t.push(aD.configure(this.options.code)),this.options.codeBlock!==!1&&t.push(lD.configure(this.options.codeBlock)),this.options.document!==!1&&t.push(cD.configure(this.options.document)),this.options.dropcursor!==!1&&t.push(uD.configure(this.options.dropcursor)),this.options.gapcursor!==!1&&t.push(dD.configure(this.options.gapcursor)),this.options.hardBreak!==!1&&t.push(fD.configure(this.options.hardBreak)),this.options.heading!==!1&&t.push(MI.configure(this.options.heading)),this.options.history!==!1&&t.push(vD.configure(this.options.history)),this.options.horizontalRule!==!1&&t.push(xD.configure(this.options.horizontalRule)),this.options.italic!==!1&&t.push(SD.configure(this.options.italic)),this.options.listItem!==!1&&t.push(BD.configure(this.options.listItem)),this.options.orderedList!==!1&&t.push(VD.configure(this.options.orderedList)),this.options.paragraph!==!1&&t.push(HD.configure(this.options.paragraph)),this.options.strike!==!1&&t.push(WD.configure(this.options.strike)),this.options.text!==!1&&t.push(qD.configure(this.options.text)),t}}),wne=()=>sn.create({name:"citationBubbleMenuHandler",addStorage(){return{isOpen:!1,selectedIds:[],bubbleMenuOptions:void 0,selectedNodePos:0}},addCommands(){return{openCitationBubbleMenu:(t={},e)=>({editor:n,dispatch:r})=>{var a;const{doc:o}=n.state,i=o.nodeAt(e??0),s=((a=i==null?void 0:i.attrs)==null?void 0:a.ids)??[];return r&&(this.storage.isOpen=!0,this.storage.selectedIds=s,this.storage.bubbleMenuOptions=t,this.storage.selectedNodePos=e??0),!0},closeCitationBubbleMenu:()=>({commands:t,dispatch:e})=>this.storage.isOpen?(t.focus(),e&&(this.storage.isOpen=!1,this.storage.selectedIds=[],this.storage.selectedNodePos=0),!0):!1}},onSelectionUpdate(){this.storage.isOpen&&!this.editor.isActive("citation")&&this.editor.commands.closeCitationBubbleMenu()},addKeyboardShortcuts(){return{"Mod-Shift-c":()=>(this.editor.commands.openCitationBubbleMenu(),!0)}}});function _ne(t){const e=bt(),n=J.useRef(null);return v.jsx(gt,{buttonRef:n,tooltipLabel:"Insert Citation/Attachment",tooltipShortcutKeys:["mod","Shift","C"],disabled:!(e!=null&&e.isEditable),onClick:()=>e==null?void 0:e.commands.openCitationBubbleMenu({anchorEl:n.current,placement:"bottom"}),...t,children:v.jsxs(F.Box,{display:"flex",flexDirection:"row",gap:"4px",alignItems:"center",children:[v.jsx(rR,{fontSize:"small"}),v.jsx(F.Typography,{variant:"body2",children:"Insert Citation/Attachment"})]})})}const CP=J.createContext(void 0),wP=()=>{const t=J.useContext(CP);if(!t)throw new Error("useSync must be used inside CitationFieldProvider");return t},Tne=({node:t,HTMLAttributes:e,selected:n,extension:r,updateAttributes:o,deleteNode:i})=>{const s=t.attrs.ids||[],{citations:a,isLoaded:l}=wP(),[u,f]=J.useState(String(s)),[p,g]=J.useState([]),m=r.options.citationMaxLength;if(J.useEffect(()=>{if(!l)return;const y=a.filter(C=>s.includes(C.id)),b=y.map(C=>Ku.truncate(C.title,{length:m,omission:"..."})).join(", ");f(b),g(y);const S=y.map(C=>C.id);S.length===0?setTimeout(i,0):S.length!==s.length&&setTimeout(()=>o({ids:y.map(C=>C.id)}),0)},[a,s,l]),p.length!==0)return v.jsx(yv,{as:"span",...e,"data-testid":"citation-node-component",children:v.jsx(F.Tooltip,{title:v.jsx(F.Box,{className:"citation-tooltip",children:p.map((y,b)=>{var C;const S=[y.source,y.title,y.fileName,y.url,(C=y.accessedAt)==null?void 0:C.slice(0,10),y.classification];return v.jsxs(F.Typography,{variant:"subtitle2",children:[S.filter(Boolean).join(" | "),b<p.length-1&&v.jsx(F.Divider,{className:"citation-tooltip-divider"})]},y.id)})}),slotProps:{tooltip:{sx:{maxWidth:500}}},children:v.jsx("a",{href:"#",onClick:y=>{y.preventDefault(),y.stopPropagation()},className:n?"selected-citation-link":"citation-link",children:u})})})},kne=tn.create({name:"citation",group:"inline",inline:!0,atom:!0,selectable:!0,addAttributes(){return{ids:{default:[],parseHTML:t=>{const e=t.getAttribute("ids");return e?e.split(",").map(n=>parseInt(n.trim(),10)).filter(n=>!isNaN(n)):[]},renderHTML:t=>({ids:Array.isArray(t.ids)?t.ids.join(","):""})}}},parseHTML(){return[{tag:"citation"}]},renderHTML({HTMLAttributes:t}){return["citation",yt(t)]},addNodeView(){return bv(Tne)},addProseMirrorPlugins(){return[new en({props:{handleClickOn:(t,e,n,r,o,i)=>n&&n.type.name==="citation"?(this.editor.commands.openCitationBubbleMenu({},r),!0):!1}})]},addCommands(){return{insertCitation:t=>({commands:e})=>e.insertContent({type:"citation",attrs:t}),updateCitation:(t,e)=>({state:n,dispatch:r,tr:o})=>{const i=n.doc.nodeAt(e);return!i||i.type.name!=="citation"?!1:(o.setNodeMarkup(e,void 0,t),r&&r(o),!0)},deleteCitation:t=>({tr:e,dispatch:n})=>{if(typeof t!="number")return!1;const r=t,o=t+1;return n&&n(e.delete(r,o)),!0}}}}),Ene=t=>{const{name:e,label:n=_n(e),hideLabel:r=!1,required:o=!1,readOnly:i=!1,margin:s="dense",citationMaxLength:a=24,getCitationsPaginated:l,onCreateCitation:u,onUpdateCitation:f,onDeleteCitation:p,getCitationById:g,onDownloadAttachment:m,onError:y=()=>{}}=t,b=[Cne,jD.configure({placeholder:"Start typing here..."}),wne(),kne.configure({citationMaxLength:a})],[S,C,T]=jt.useField({name:e}),{setValue:_}=T,{value:w}=S,{addUpdateCitation:E,deleteCitation:O,batchUpdate:L}=wP();J.useEffect(()=>{var R;const N=(R=P==null?void 0:P.current)==null?void 0:R.editor;if(!N||!w)return;N.getHTML()!==w&&setTimeout(()=>{N.commands.setContent(w)},0)},[w]);const P=J.useRef(null),$={normal:{marginTop:"16px",marginBottom:"8px"},dense:{marginTop:"8px",marginBottom:"4px"},none:{margin:0}},M=()=>{var R,B;const N=((B=(R=P.current)==null?void 0:R.editor)==null?void 0:B.getHTML())??"<p></p>",V=!N.replace(/<\/?p>|<br>/g,"").trim();_(V?"<p></p>":N)},A=v.jsxs(F.Box,{id:`citation-field_${e}`,sx:{"& .ProseMirror":{"& h1, & h2, & h3, & h4, & h5, & h6":{scrollMarginTop:i?0:50}}},...$[s],children:[v.jsx(iI,{ref:P,extensions:b,content:w,editable:!i,renderControls:i?void 0:()=>v.jsx(Nf,{children:v.jsx(_ne,{})}),onBlur:M,RichTextFieldProps:{variant:"outlined",MenuBarProps:{hide:i}},children:()=>v.jsx(SP,{getCitationsPaginated:N=>l(N).then(V=>(L(V.data),V)),onCreateCitation:u&&(N=>u(N).then(V=>(E(V),V))),onUpdateCitation:N=>f(N).then(V=>(E(V),V)),onDeleteCitation:p&&(N=>p(N).then(()=>O(N))),getCitationById:g,onDownloadAttachment:m,onError:y})}),v.jsx(Xn,{name:e,id:`${e}-err`})]});return v.jsxs(F.Box,{display:"flex",flexDirection:"column",width:"100%",children:[!r&&v.jsx(F.InputLabel,{htmlFor:`citation-field_${e}`,required:o,children:n}),A]})},Mne=t=>{const{name:e="submit"}=t;return v.jsx(No,{name:e,type:"submit",...t})},One=t=>{const{label:e="Return to Top",icon:n=RC,scrollThresholdPx:r=100}=t,o=F.useScrollTrigger({threshold:r}),i=J.useCallback(()=>{window.scrollTo({top:0,behavior:"smooth"})},[]);return v.jsx(F.Zoom,{in:o,children:v.jsx(F.Box,{sx:{position:"fixed",bottom:32,right:32,zIndex:1},children:v.jsxs(F.Fab,{onClick:i,color:"primary",size:"small",variant:"extended","aria-label":"Scroll back to top",children:[v.jsx(n,{fontSize:"medium"}),e]})})})},Ane=()=>{const{values:t,errors:e,status:n}=jt.useFormikContext(),{palette:r}=F.useTheme();return v.jsx(F.Paper,{style:{backgroundColor:r.mode==="dark"?"#303030":"#f0f0f0",margin:"10px 0"},children:v.jsxs(F.List,{children:[v.jsxs(F.ListItem,{children:[v.jsx(F.Typography,{display:"block",variant:"h6",children:"Values"}),v.jsx("br",{}),v.jsx(F.Divider,{variant:"inset"}),v.jsx("pre",{children:JSON.stringify(t,null,2)})]}),v.jsx(F.Divider,{variant:"inset",component:"li"}),v.jsxs(F.ListItem,{id:"testing",children:[v.jsx(F.Typography,{display:"block",variant:"h6",children:"Errors"}),v.jsx("br",{}),v.jsx(F.Divider,{variant:"inset"}),v.jsx("pre",{children:JSON.stringify(e,null,2)})]}),v.jsxs(F.ListItem,{children:[v.jsx(F.Typography,{display:"block",variant:"h6",children:"Status"}),v.jsx("br",{}),v.jsx(F.Divider,{variant:"inset"}),v.jsx("pre",{children:JSON.stringify(n,null,2)})]})]})})},Ine=t=>{const{steps:e,orientation:n,inlineLabel:r=n=="vertical",isResponsive:o=!1}=t,{width:i}=QD();let s=!r,a=n;o&&(n&&console.warn("Stepper: Ignoring orientation. isResponsive is set to true, so the orientation is determined automatically based on the window size."),a=i<600?"vertical":"horizontal",a=="vertical"?s=!1:s=!r),n=="vertical"&&!r&&(console.warn("Stepper: ignoring inlineLabel={false}. Must use inline labels when orientation is vertical"),s=!1);const l=["steps","inlineLabel","orientation","isResponsive"],u={alternativeLabel:s,orientation:a,...Jn({...t},l)};return v.jsx(F.Stepper,{...u,children:e.map(f=>v.jsx(F.Step,{children:v.jsx(F.StepLabel,{children:f})},f))})},Dne=t=>{const{name:e,label:n=_n(e),labelProps:r={fontSize:"1.1em",color:"#808080",fontWeight:"600"},initialState:o,renderFormGroup:i,addButtonContent:s="Add Another",removeButtonContent:a=t.removePosition==="right"?v.jsx(FR,{}):"Remove",variant:l="card",addButtonSx:u,removeButtonSx:f,allowRemoveAll:p=!1,readOnly:g=!1,emptyListMsg:m="None",showDivider:y=!1,removePosition:b="bottom"}=t,[S]=jt.useField({name:e}),{value:C}=S,T=_=>({display:"flex",flexDirection:_==="bottom"?"column":"row",alignItems:_==="bottom"?"flex-start":"center"});return v.jsxs(F.FormControl,{fullWidth:!0,children:[v.jsx(F.Typography,{...r,children:n}),g&&S.value.length===0?v.jsx(F.Typography,{children:m}):v.jsx(jt.FieldArray,{name:e,render:_=>v.jsxs("div",{children:[C.map((w,E)=>v.jsx(J.Fragment,{children:v.jsx(Pne,{variant:l,content:v.jsxs(F.Box,{"data-testid":"form-group-container",sx:typeof b=="string"?T(b):{...b},children:[v.jsxs(F.Box,{width:"100%",children:[i(`${e}.${E}`,E),y&&E!==C.length-1&&v.jsx(F.Divider,{"data-testid":"divider"})]}),!g&&C.length>(p?0:1)&&v.jsx(F.Button,{"data-testid":"repeatable-form-group_remove-btn",sx:f,onClick:()=>_.remove(E),children:a})]})})},`${e}-${E}`)),!g&&v.jsx(F.Button,{"data-testid":"repeatable-form-group_add-btn",onClick:()=>_.push(o),sx:u,children:s})]})})]})},Pne=({variant:t,content:e})=>{switch(t){case"card":return v.jsx(F.Card,{"data-testid":"repeatable-form-group_card",sx:{padding:"8px",marginBottom:"8px"},children:v.jsx(F.CardContent,{children:e})});case"elevatedCard":return v.jsx(F.Card,{"data-testid":"repeatable-form-group_elevated-card",elevation:4,sx:{border:"unset",padding:"8px",marginBottom:"8px"},children:v.jsx(F.CardContent,{children:e})});case"none":return e}},Nne=t=>{const{confirmBtnLabel:e,onConfirm:n,confirmButtonProps:r={color:"primary",variant:"contained"},closeBtnLabel:o="Cancel",closeButtonPosition:i="bottom",...s}=t;return v.jsx(ou,{actions:[v.jsx(F.Button,{className:"MBv2_ConfirmationModal_ConfirmBtn",onClick:n,...r,children:e})],closeBtnLabel:o,closeButtonPosition:i,...s})},Lne=t=>{const{closeBtnLabel:e="OK",closeButtonPosition:n="bottom",closeButtonProps:r={color:"primary",variant:"contained"},...o}=t;return v.jsx(ou,{closeBtnLabel:e,closeButtonPosition:n,closeButtonProps:r,...o})},Fne=t=>{const{primaryBtnLabel:e,onPrimaryAction:n,primaryActionProps:r={color:"primary",variant:"contained"},secondaryBtnLabel:o,onSecondaryAction:i,secondaryActionProps:s={color:"primary",variant:"outlined"},closeBtnLabel:a="Cancel",closeButtonPosition:l="bottom",...u}=t;return v.jsx(ou,{actions:[v.jsx(F.Button,{className:"MBv2_DecisionModal_SecondaryAction",onClick:i,...s,children:o}),v.jsx(F.Button,{className:"MBv2_DecisionModal_PrimaryAction",onClick:n,...r,children:e})],closeBtnLabel:a,closeButtonPosition:l,...u})},$ne=t=>{const{featureMenuOptions:e=[],copyright:n,logo:r,sx:o={},fontColor:i="primary"}=t,{palette:s}=F.useTheme(),a=eo.useNavigate();return v.jsxs(F.Box,{className:"MBv2_Footer",sx:{backgroundColor:s.mode==="dark"?"#222222":"#ededed",padding:"25px 30px",...o},children:[v.jsx(F.Box,{className:"MBv2_Footer_Logo",sx:{display:"flex",gap:2,alignItems:"center",paddingBottom:1},children:typeof r=="string"?v.jsx("img",{draggable:"false",src:r,style:{width:"200px"},alt:"logo"}):r}),v.jsxs(F.Box,{display:"flex",justifyContent:"space-between",flexWrap:"wrap",className:"MBv2_Footer_Nav_Links_Container",gap:2,children:[v.jsx(F.Box,{sx:{flexGrow:1},className:"MBv2_Footer_Nav_Links",display:"flex",flexDirection:"row",justifyContent:"flex-start",gap:3,children:e==null?void 0:e.map(l=>v.jsx(F.Link,{"data-testid":l.label,sx:{cursor:"pointer",fontSize:15},color:i,...vl(l,a),children:l.label},l.label))}),n&&v.jsx(F.Typography,{style:{fontSize:15},"data-testid":"copyright",className:"MBv2_Footer_Copyright",color:i,children:n})]})]})},_P=t=>{const{menuOptionLists:e,anchor:n="left",children:r}=t,{pathname:o}=eo.useLocation(),i=eo.useNavigate(),[s,a]=J.useState(!1),l=(g,m)=>v.jsx(F.MenuList,{children:g.map(y=>v.jsxs(F.MenuItem,{...vl(y,i,()=>a(!1)),children:[y.icon&&v.jsx(F.ListItemIcon,{children:y.icon}),v.jsx(F.ListItemText,{primary:y.label})]},`mobile-drawer-group-${m}-item-${y.path}`))}),f=(()=>{if(e){const g=e.filter(m=>m&&m.length>0);return g.length===0?null:g.map((m,y)=>v.jsxs(J.Fragment,{children:[l(m,y),y<g.length-1&&v.jsx(F.Divider,{})]},`mobile-drawer-group-${y}`))}return r?v.jsx(F.Box,{role:"presentation",onClick:()=>a(!1),children:r}):null})(),p=f??!1;return J.useEffect(()=>{a(!1)},[o]),p&&v.jsxs(v.Fragment,{children:[v.jsx(F.IconButton,{onClick:()=>a(!0),color:"inherit",title:"Menu",children:v.jsx(IR,{})}),v.jsx(F.Drawer,{"data-testid":"mobile-drawer",anchor:n,open:s,onClose:()=>a(!1),children:v.jsx(F.Box,{sx:{width:300},display:"flex",flexDirection:"column",justifyContent:"space-between",children:v.jsx(F.Box,{display:"flex",justifyContent:"start",flexDirection:"column",children:f})})})]})},TP=t=>{const{env:e,isProd:n}=t;return n?null:v.jsx(F.Paper,{sx:{borderRadius:0,display:"flex",alignItems:"center",justifyContent:"center"},children:v.jsxs(F.Typography,{variant:"h6",color:"error",children:[e," Environment - Test Data Only"]})})},kP=t=>{const{label:e,menuOptions:n=[],icon:r}=t,o=eo.useNavigate(),[i,s]=I.useState(null),a=!!i,l=f=>{s(f.currentTarget)},u=()=>{s(null)};return n.length===0?null:v.jsxs(v.Fragment,{children:[v.jsx(F.Button,{startIcon:r,variant:"outlined",color:"inherit",sx:{minWidth:0,padding:1},onClick:l,children:e}),v.jsx(F.Menu,{anchorEl:i,open:a,onClick:u,children:n.map(f=>v.jsxs(F.MenuItem,{...vl(f,o),children:[f.icon&&v.jsx(F.ListItemIcon,{children:f.icon}),v.jsx(F.ListItemText,{primary:f.label})]},f.label))})]})},EP=t=>{const{displayName:e,userMenuOptions:n}=t;return v.jsx(kP,{label:e,menuOptions:n,icon:v.jsx(PR,{})})},Dp=t=>{const{menuOptions:e,orientation:n="horizontal",activeTabIdx:r,sx:o=n=="vertical"?{"& .MuiTabs-indicator":{left:0}}:void 0,slotProps:i={indicator:{sx:n=="horizontal"?{height:4}:{width:4}}}}=t,{palette:s}=F.useTheme(),a=eo.useNavigate();return v.jsx(F.Tabs,{orientation:n,value:r??!1,sx:o,slotProps:i,children:e.map((l,u)=>v.jsx(F.Tab,{icon:l.icon,label:l.label,value:u,...vl(l,a),sx:{alignItems:n=="vertical"?"flex-start":void 0,borderBottom:n=="vertical"?"1px solid":void 0,borderColor:"divider","&.Mui-selected":{backgroundColor:n=="vertical"?s.grey[s.mode=="dark"?800:50]:void 0,color:"inherit"}}},l.label))})},MP=t=>{const{featureMenuOptions:e=[],activeTabIdx:n,sx:r}=t;return e.length>0&&v.jsx(F.Paper,{sx:{pl:4,pr:4,borderRadius:0},"data-testid":"navBar",children:v.jsx(Dp,{menuOptions:e,activeTabIdx:n,sx:r})})},OP=t=>{const{onToggle:e}=t,{palette:n}=F.useTheme(),r=n.mode==="dark";return v.jsx(F.IconButton,{onClick:e,color:"inherit",title:"Dark Mode Toggle",children:r?v.jsx(zC,{}):v.jsx($C,{})})},Bne=t=>{const{envInfo:e,headerRef:n,logo:r,featureMenuOptions:o=[],userMenuOptions:i=[],onToggleDarkMode:s,quickLinks:a=[],displayName:l,banner:u,position:f="fixed",children:p,sx:g,navBarSx:m}=t,y=eo.useNavigate(),b=F.useMediaQuery(F.useTheme().breakpoints.down("sm")),{palette:S}=F.useTheme(),{pathname:C}=eo.useLocation(),T=S.mode==="dark",[_,w]=I.useState(void 0);I.useEffect(()=>{const L=o.findIndex(P=>P.path&&C.startsWith(P.path));w(L>=0?L:void 0)},[C,o]);const E=s&&v.jsx(OP,{onToggle:s}),O=s&&(b||!b&&l)?[{icon:T?v.jsx(zC,{}):v.jsx($C,{}),label:`Switch to ${T?"Light":"Dark"} mode`,onClick:s},...i]:i;return v.jsxs(F.AppBar,{ref:n,position:f,sx:g,elevation:4,children:[e&&v.jsx(TP,{...e}),u,v.jsxs(F.Toolbar,{sx:{color:"white",display:"flex",justifyContent:"space-between",gap:2},children:[v.jsx(F.Button,{disableRipple:!0,component:eo.Link,to:"/",children:r&&typeof r=="string"?v.jsx("img",{draggable:"false",src:r,style:{width:"200px",filter:"brightness(0) invert(1)"},alt:"logo"}):r}),v.jsxs(F.Box,{display:"flex",gap:2,alignItems:"center",children:[!l&&!b&&E,b&&v.jsx(_P,{menuOptionLists:[o,a,O],anchor:"right"}),!b&&v.jsxs(v.Fragment,{children:[v.jsx(F.Box,{display:"flex",gap:0,children:a==null?void 0:a.map((L,P)=>v.jsxs(F.Box,{display:"flex",alignItems:"center",children:[P>0&&v.jsx(F.Typography,{className:"quickLink-divider",color:S.primary.contrastText,children:"|"}),v.jsx(F.Button,{variant:"text",sx:{color:"white"},...vl(L,y),children:v.jsxs(F.Box,{display:"flex",gap:"3px",alignItems:"center",children:[L.icon,L.label]})})]},L.label))}),p,l&&v.jsx(EP,{displayName:l,userMenuOptions:O})]})]})]}),!b&&v.jsx(MP,{featureMenuOptions:o,activeTabIdx:_,sx:m})]})},Rne=t=>{const{sx:e,menuOptions:n=[]}=t,{pathname:r}=eo.useLocation(),o=F.useMediaQuery(F.useTheme().breakpoints.down("sm")),[i,s]=J.useState(void 0);return J.useEffect(()=>{const a=n.findIndex(l=>l.path&&r.startsWith(l.path))??-1;s(a>=0?a:void 0)},[r,n]),!o&&n.length>0&&v.jsx(F.Box,{sx:e,children:v.jsx(F.Card,{sx:{height:"100%",width:200},children:v.jsx(Dp,{orientation:"vertical",menuOptions:n,activeTabIdx:i})})})},zne=t=>{const{featureMenuOptions:e=[],activeTabIdx:n,sx:r}=t,{palette:o}=F.useTheme();return e.length>0&&v.jsx(Dp,{menuOptions:e,activeTabIdx:n,sx:{margin:"8px",backgroundColor:o.primary.dark,borderRadius:"8px","& .MuiTab-root":{color:o.secondary.light,flexDirection:"row",gap:"2px","& .MuiTab-icon":{marginBottom:"unset"},minHeight:"58px"},"& .MuiTab-root.Mui-selected":{color:o.primary.contrastText,fontSize:"120%"},"& .MuiTabs-indicator":{display:"none"},...r}})},Vne=t=>v.jsx(iu,{severity:"info",...t}),Hne=t=>v.jsx(iu,{severity:"warning",...t}),AP=t=>{const{crumbInfo:e}=t,n=eo.useNavigate();return v.jsx(F.Breadcrumbs,{"aria-label":"breadcrumb",separator:v.jsx(DR,{color:"primary"}),sx:{marginBottom:2},children:e.map(({label:r,path:o},i)=>o&&i<e.length-1?v.jsx(F.Link,{color:"primary",sx:{cursor:"pointer"},onClick:()=>n(o),children:r},r):v.jsx(F.Typography,{color:"primary",children:r},r))})},jne=t=>{const{title:e,message:n,type:r,onClose:o,autoHideDuration:i=8e3,variant:s="leftBorder",elevation:a=6}=t,l=Wne(r);return v.jsx(F.Snackbar,{"data-testid":"message-snackbar",anchorOrigin:{vertical:"bottom",horizontal:"right"},open:!0,onClose:u=>{u==null&&o()},autoHideDuration:i,children:v.jsx(iu,{"data-testid":"message-snackbar-alert",severity:l,iconMapping:{info:IP(r),warning:IP(r)},onClose:o,elevation:a,variant:s,children:n?v.jsxs(v.Fragment,{children:[v.jsx(F.AlertTitle,{"data-testid":"alertTitle",sx:{fontWeight:"bold"},children:e}),n]}):e})})},Wne=t=>t=="logout"?"info":t=="timeout"?"warning":t,IP=t=>{if(t=="timeout")return v.jsx(eR,{});if(t=="logout")return v.jsx(AR,{})},qne=t=>{const{title:e,createButtonLabel:n,showAddButton:r=!1,onAdd:o=()=>alert("Not implemented yet"),breadcrumbs:i=[],children:s,sx:a}=t,l=F.useMediaQuery(F.useTheme().breakpoints.down("sm"));return r&&o.toString()==='() => alert("Not implemented yet")'&&console.warn('PageHeader: "showAddButton" is true but "onAdd" is not defined.'),v.jsxs(F.Box,{sx:a,children:[i.length>0&&v.jsx(AP,{crumbInfo:i}),v.jsxs(F.Box,{className:"MBv2_PageHeader_Header",display:"flex",flexDirection:l?"column":"row",justifyContent:"space-between",alignItems:"center",gap:1,children:[v.jsxs(F.Box,{className:"MBv2_PageHeader_TitleAndCreateBtn",display:"flex",flexDirection:"row",justifyContent:l||!s?"space-between":"start",alignItems:"center",width:"100%",gap:1,children:[typeof e=="string"?v.jsx(F.Typography,{className:"MBv2_PageHeader_Title",variant:"h2",children:e}):e,r&&v.jsxs(No,{className:"MBv2_PageHeader_CreateBtn",onClick:()=>o(),children:[v.jsx(tR,{style:{marginRight:"0.5rem"}}),n]})]}),s&&v.jsx(F.Box,{width:l?"100%":"50%",children:s})]})]})},Une=t=>{const{title:e,titleIcon:n,fullWidthIcon:r=!1,children:o,actionLabel:i,action:s,sx:a}=t,l=F.useMediaQuery(F.useTheme().breakpoints.down("sm"));return v.jsxs(F.Card,{sx:a||{padding:"30px 40px",display:"flex",flexDirection:"column",gap:"1rem"},children:[n&&v.jsx(F.Box,{className:"MBv2_SingleActionCard_Img",sx:[r?{display:"flex",flexDirection:"row",justifyContent:"center",alignItems:"center",gap:"20px",marginBottom:"10px"}:{display:"inline"}],children:n}),v.jsx(F.Typography,{variant:"h1",display:"inline",fontSize:"calc(20px + .9vw)",className:"MBv2_SingleActionCard_Title",children:e}),o,v.jsx(F.Button,{variant:"contained",color:"primary",onClick:s,fullWidth:l,className:"MBv2_SingleActionCard_ActionButton",children:i})]})};function Kne({...t}){return v.jsx(k1,{renderAsSelectablePopup:!0,...t})}function Yne({...t}){return v.jsx(k1,{onSelectCitations:()=>{},onCancel:()=>{},renderAsSelectablePopup:!1,...t})}const Gne=({children:t,getCitations:e})=>{const[n,r]=J.useState([]),[o,i]=J.useState(!1);J.useEffect(()=>{(async()=>e().then(f=>{r(p=>{const g=new Set(p.map(y=>y.id));return[...p.filter(y=>!g.has(y.id)),...f]}),i(!0)}).catch(f=>{console.error(`Error fetching citations: ${f==null?void 0:f.toString()}`)}))()},[]);const s=J.useCallback(u=>{r(f=>{const p=f.map(y=>{const b=u.find(S=>S.id===y.id);return b||y}),g=new Set(f.map(y=>y.id)),m=u.filter(y=>!g.has(y.id));return[...p,...m]})},[]),a=J.useCallback(u=>{const f=n.findIndex(p=>p.id===u.id);r(f!==-1?p=>{const g=[...p];return g[f]=u,g}:[...n,u])},[n]),l=J.useCallback(u=>r(n.filter(f=>f.id!==u)),[n]);return v.jsx(CP.Provider,{value:{citations:n,isLoaded:o,addUpdateCitation:a,deleteCitation:l,batchUpdate:s},children:t})};Pe.AlertModal=Lne,Pe.Autocomplete=fC,Pe.Breadcrumbs=AP,Pe.Button=No,Pe.Checkbox=DB,Pe.CheckboxGroup=PB,Pe.CitationField=Ene,Pe.CitationFieldProvider=Gne,Pe.CitationManager=Yne,Pe.ConfirmationModal=Nne,Pe.DarkModeToggle=OP,Pe.DateField=Fd,Pe.DateRangeField=nq,Pe.DecisionModal=Fne,Pe.Drawer=_P,Pe.DynamicAutocomplete=AB,Pe.EnvironmentBanner=TP,Pe.Error=Xn,Pe.ErrorAlert=vP,Pe.FileList=LB,Pe.FileUpload=gC,Pe.FloatingNavBar=zne,Pe.Footer=$ne,Pe.FormDebugger=Ane,Pe.Header=Bne,Pe.InfoAlert=Vne,Pe.LoadingButton=b1,Pe.LoadingIndicator=y1,Pe.Location=JB,Pe.MenuButton=kP,Pe.Modal=ou,Pe.MultiAutocomplete=IB,Pe.NavBar=MP,Pe.PageHeader=qne,Pe.PaginatedTable=ZD,Pe.ProfileMenu=EP,Pe.RadioGroup=FC,Pe.RangeSlider=ZB,Pe.RepeatableFormGroup=Dne,Pe.RichTextField=Ete,Pe.ScrollToTop=One,Pe.SearchField=jR,Pe.Select=XB,Pe.SelectableCitationManager=Kne,Pe.Sidebar=Rne,Pe.SingleActionCard=Une,Pe.Snackbar=jne,Pe.Stepper=Ine,Pe.Submit=Mne,Pe.SuccessAlert=xP,Pe.Switch=QB,Pe.Table=JD,Pe.Tabs=Dp,Pe.TextField=da,Pe.WarningAlert=Hne,Pe.commonTheme=vn,Pe.darkTheme=PF,Pe.lightTheme=DF,Object.defineProperty(Pe,Symbol.toStringTag,{value:"Module"})});
|
|
403
|
+
`+(a!==s?`result of cast: ${a}`:""))}return i}_cast(e,n){let r=e===void 0?e:this.transforms.reduce((o,i)=>i.call(this,o,e,this),e);return r===void 0&&(r=this.getDefault(n)),r}_validate(e,n={},r,o){let{path:i,originalValue:s=e,strict:a=this.spec.strict}=n,l=e;a||(l=this._cast(l,Object.assign({assert:!1},n)));let u=[];for(let f of Object.values(this.internalTests))f&&u.push(f);this.runTests({path:i,value:l,originalValue:s,options:n,tests:u},r,f=>{if(f.length)return o(f,l);this.runTests({path:i,value:l,originalValue:s,options:n,tests:this.tests},r,o)})}runTests(e,n,r){let o=!1,{tests:i,value:s,originalValue:a,path:l,options:u}=e,f=b=>{o||(o=!0,n(b,s))},p=b=>{o||(o=!0,r(b,s))},g=i.length,m=[];if(!g)return p([]);let y={value:s,originalValue:a,path:l,options:u,schema:this};for(let b=0;b<i.length;b++){const S=i[b];S(y,f,function(T){T&&(Array.isArray(T)?m.push(...T):m.push(T)),--g<=0&&p(m)})}}asNestedTest({key:e,index:n,parent:r,parentPath:o,originalParent:i,options:s}){const a=e??n;if(a==null)throw TypeError("Must include `key` or `index` for nested validations");const l=typeof a=="number";let u=r[a];const f=Object.assign({},s,{strict:!0,parent:r,value:u,originalValue:i[a],key:void 0,[l?"index":"key"]:a,path:l||a.includes(".")?`${o||""}[${l?a:`"${a}"`}]`:(o?`${o}.`:"")+e});return(p,g,m)=>this.resolve(f)._validate(u,f,g,m)}validate(e,n){var r;let o=this.resolve(Object.assign({},n,{value:e})),i=(r=n==null?void 0:n.disableStackTrace)!=null?r:o.spec.disableStackTrace;return new Promise((s,a)=>o._validate(e,n,(l,u)=>{fr.isError(l)&&(l.value=u),a(l)},(l,u)=>{l.length?a(new fr(l,u,void 0,void 0,i)):s(u)}))}validateSync(e,n){var r;let o=this.resolve(Object.assign({},n,{value:e})),i,s=(r=n==null?void 0:n.disableStackTrace)!=null?r:o.spec.disableStackTrace;return o._validate(e,Object.assign({},n,{sync:!0}),(a,l)=>{throw fr.isError(a)&&(a.value=l),a},(a,l)=>{if(a.length)throw new fr(a,e,void 0,void 0,s);i=l}),i}isValid(e,n){return this.validate(e,n).then(()=>!0,r=>{if(fr.isError(r))return!1;throw r})}isValidSync(e,n){try{return this.validateSync(e,n),!0}catch(r){if(fr.isError(r))return!1;throw r}}_getDefault(e){let n=this.spec.default;return n==null?n:typeof n=="function"?n.call(this,e):nl(n)}getDefault(e){return this.resolve(e||{})._getDefault(e)}default(e){return arguments.length===0?this._getDefault():this.clone({default:e})}strict(e=!0){return this.clone({strict:e})}nullability(e,n){const r=this.clone({nullable:e});return r.internalTests.nullable=tl({message:n,name:"nullable",test(o){return o===null?this.schema.spec.nullable:!0}}),r}optionality(e,n){const r=this.clone({optional:e});return r.internalTests.optionality=tl({message:n,name:"optionality",test(o){return o===void 0?this.schema.spec.optional:!0}}),r}optional(){return this.optionality(!0)}defined(e=Lo.defined){return this.optionality(!1,e)}nullable(){return this.nullability(!0)}nonNullable(e=Lo.notNull){return this.nullability(!1,e)}required(e=Lo.required){return this.clone().withMutation(n=>n.nonNullable(e).defined(e))}notRequired(){return this.clone().withMutation(e=>e.nullable().optional())}transform(e){let n=this.clone();return n.transforms.push(e),n}test(...e){let n;if(e.length===1?typeof e[0]=="function"?n={test:e[0]}:n=e[0]:e.length===2?n={name:e[0],test:e[1]}:n={name:e[0],message:e[1],test:e[2]},n.message===void 0&&(n.message=Lo.default),typeof n.test!="function")throw new TypeError("`test` is a required parameters");let r=this.clone(),o=tl(n),i=n.exclusive||n.name&&r.exclusiveTests[n.name]===!0;if(n.exclusive&&!n.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return n.name&&(r.exclusiveTests[n.name]=!!n.exclusive),r.tests=r.tests.filter(s=>!(s.OPTIONS.name===n.name&&(i||s.OPTIONS.test===o.OPTIONS.test))),r.tests.push(o),r}when(e,n){!Array.isArray(e)&&typeof e!="string"&&(n=e,e=".");let r=this.clone(),o=oP(e).map(i=>new Us(i));return o.forEach(i=>{i.isSibling&&r.deps.push(i.key)}),r.conditions.push(typeof n=="function"?new Ep(o,n):Ep.fromOptions(o,n)),r}typeError(e){let n=this.clone();return n.internalTests.typeError=tl({message:e,name:"typeError",skipAbsent:!0,test(r){return this.schema._typeCheck(r)?!0:this.createError({params:{type:this.schema.type}})}}),n}oneOf(e,n=Lo.oneOf){let r=this.clone();return e.forEach(o=>{r._whitelist.add(o),r._blacklist.delete(o)}),r.internalTests.whiteList=tl({message:n,name:"oneOf",skipAbsent:!0,test(o){let i=this.schema._whitelist,s=i.resolveAll(this.resolve);return s.includes(o)?!0:this.createError({params:{values:Array.from(i).join(", "),resolved:s}})}}),r}notOneOf(e,n=Lo.notOneOf){let r=this.clone();return e.forEach(o=>{r._blacklist.add(o),r._whitelist.delete(o)}),r.internalTests.blacklist=tl({message:n,name:"notOneOf",test(o){let i=this.schema._blacklist,s=i.resolveAll(this.resolve);return s.includes(o)?this.createError({params:{values:Array.from(i).join(", "),resolved:s}}):!0}}),r}strip(e=!0){let n=this.clone();return n.spec.strip=e,n}describe(e){const n=(e?this.resolve(e):this).clone(),{label:r,meta:o,optional:i,nullable:s}=n.spec;return{meta:o,label:r,optional:i,nullable:s,default:n.getDefault(e),type:n.type,oneOf:n._whitelist.describe(),notOneOf:n._blacklist.describe(),tests:n.tests.map(l=>({name:l.OPTIONS.name,params:l.OPTIONS.params})).filter((l,u,f)=>f.findIndex(p=>p.name===l.name)===u)}}}Fo.prototype.__isYupSchema__=!0;for(const t of["validate","validateSync"])Fo.prototype[`${t}At`]=function(e,n,r={}){const{parent:o,parentPath:i,schema:s}=Wte(this,e,n,r.context);return s[t](o&&o[i],Object.assign({},r,{parent:o,path:e}))};for(const t of["equals","is"])Fo.prototype[t]=Fo.prototype.oneOf;for(const t of["not","nope"])Fo.prototype[t]=Fo.prototype.notOneOf;const qte=/^(\d{4}|[+-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,.](\d{1,}))?)?(?:(Z)|([+-])(\d{2})(?::?(\d{2}))?)?)?$/;function Ute(t){const e=_1(t);if(!e)return Date.parse?Date.parse(t):Number.NaN;if(e.z===void 0&&e.plusMinus===void 0)return new Date(e.year,e.month,e.day,e.hour,e.minute,e.second,e.millisecond).valueOf();let n=0;return e.z!=="Z"&&e.plusMinus!==void 0&&(n=e.hourOffset*60+e.minuteOffset,e.plusMinus==="+"&&(n=0-n)),Date.UTC(e.year,e.month,e.day,e.hour,e.minute+n,e.second,e.millisecond)}function _1(t){var e,n;const r=qte.exec(t);return r?{year:ii(r[1]),month:ii(r[2],1)-1,day:ii(r[3],1),hour:ii(r[4]),minute:ii(r[5]),second:ii(r[6]),millisecond:r[7]?ii(r[7].substring(0,3)):0,precision:(e=(n=r[7])==null?void 0:n.length)!=null?e:void 0,z:r[8]||void 0,plusMinus:r[9]||void 0,hourOffset:ii(r[10]),minuteOffset:ii(r[11])}:null}function ii(t,e=0){return Number(t)||e}let Kte=/^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,Yte=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,Gte=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,Jte="^\\d{4}-\\d{2}-\\d{2}",Zte="\\d{2}:\\d{2}:\\d{2}",Xte="(([+-]\\d{2}(:?\\d{2})?)|Z)",Qte=new RegExp(`${Jte}T${Zte}(\\.\\d+)?${Xte}$`),ene=t=>Ks(t)||t===t.trim(),tne={}.toString();function T1(){return new cP}class cP extends Fo{constructor(){super({type:"string",check(e){return e instanceof String&&(e=e.valueOf()),typeof e=="string"}}),this.withMutation(()=>{this.transform((e,n,r)=>{if(!r.spec.coerce||r.isType(e)||Array.isArray(e))return e;const o=e!=null&&e.toString?e.toString():e;return o===tne?e:o})})}required(e){return super.required(e).withMutation(n=>n.test({message:e||Lo.required,name:"required",skipAbsent:!0,test:r=>!!r.length}))}notRequired(){return super.notRequired().withMutation(e=>(e.tests=e.tests.filter(n=>n.OPTIONS.name!=="required"),e))}length(e,n=pr.length){return this.test({message:n,name:"length",exclusive:!0,params:{length:e},skipAbsent:!0,test(r){return r.length===this.resolve(e)}})}min(e,n=pr.min){return this.test({message:n,name:"min",exclusive:!0,params:{min:e},skipAbsent:!0,test(r){return r.length>=this.resolve(e)}})}max(e,n=pr.max){return this.test({name:"max",exclusive:!0,message:n,params:{max:e},skipAbsent:!0,test(r){return r.length<=this.resolve(e)}})}matches(e,n){let r=!1,o,i;return n&&(typeof n=="object"?{excludeEmptyString:r=!1,message:o,name:i}=n:o=n),this.test({name:i||"matches",message:o||pr.matches,params:{regex:e},skipAbsent:!0,test:s=>s===""&&r||s.search(e)!==-1})}email(e=pr.email){return this.matches(Kte,{name:"email",message:e,excludeEmptyString:!0})}url(e=pr.url){return this.matches(Yte,{name:"url",message:e,excludeEmptyString:!0})}uuid(e=pr.uuid){return this.matches(Gte,{name:"uuid",message:e,excludeEmptyString:!1})}datetime(e){let n="",r,o;return e&&(typeof e=="object"?{message:n="",allowOffset:r=!1,precision:o=void 0}=e:n=e),this.matches(Qte,{name:"datetime",message:n||pr.datetime,excludeEmptyString:!0}).test({name:"datetime_offset",message:n||pr.datetime_offset,params:{allowOffset:r},skipAbsent:!0,test:i=>{if(!i||r)return!0;const s=_1(i);return s?!!s.z:!1}}).test({name:"datetime_precision",message:n||pr.datetime_precision,params:{precision:o},skipAbsent:!0,test:i=>{if(!i||o==null)return!0;const s=_1(i);return s?s.precision===o:!1}})}ensure(){return this.default("").transform(e=>e===null?"":e)}trim(e=pr.trim){return this.transform(n=>n!=null?n.trim():n).test({message:e,name:"trim",test:ene})}lowercase(e=pr.lowercase){return this.transform(n=>Ks(n)?n:n.toLowerCase()).test({message:e,name:"string_case",exclusive:!0,skipAbsent:!0,test:n=>Ks(n)||n===n.toLowerCase()})}uppercase(e=pr.uppercase){return this.transform(n=>Ks(n)?n:n.toUpperCase()).test({message:e,name:"string_case",exclusive:!0,skipAbsent:!0,test:n=>Ks(n)||n===n.toUpperCase()})}}T1.prototype=cP.prototype;let nne=new Date(""),rne=t=>Object.prototype.toString.call(t)==="[object Date]";class Ap extends Fo{constructor(){super({type:"date",check(e){return rne(e)&&!isNaN(e.getTime())}}),this.withMutation(()=>{this.transform((e,n,r)=>!r.spec.coerce||r.isType(e)||e===null?e:(e=Ute(e),isNaN(e)?Ap.INVALID_DATE:new Date(e)))})}prepareParam(e,n){let r;if(Us.isRef(e))r=e;else{let o=this.cast(e);if(!this._typeCheck(o))throw new TypeError(`\`${n}\` must be a Date or a value that can be \`cast()\` to a Date`);r=o}return r}min(e,n=C1.min){let r=this.prepareParam(e,"min");return this.test({message:n,name:"min",exclusive:!0,params:{min:e},skipAbsent:!0,test(o){return o>=this.resolve(r)}})}max(e,n=C1.max){let r=this.prepareParam(e,"max");return this.test({message:n,name:"max",exclusive:!0,params:{max:e},skipAbsent:!0,test(o){return o<=this.resolve(r)}})}}Ap.INVALID_DATE=nne,Ap.prototype;function one(t,e=[]){let n=[],r=new Set,o=new Set(e.map(([s,a])=>`${s}-${a}`));function i(s,a){let l=qs.split(s)[0];r.add(l),o.has(`${a}-${l}`)||n.push([a,l])}for(const s of Object.keys(t)){let a=t[s];r.add(s),Us.isRef(a)&&a.isSibling?i(a.path,s):w1(a)&&"deps"in a&&a.deps.forEach(l=>i(l,s))}return Nte.array(Array.from(r),n).reverse()}function uP(t,e){let n=1/0;return t.some((r,o)=>{var i;if((i=e.path)!=null&&i.includes(r))return n=o,!0}),n}function dP(t){return(e,n)=>uP(t,e)-uP(t,n)}const ine=(t,e,n)=>{if(typeof t!="string")return t;let r=t;try{r=JSON.parse(t)}catch{}return n.isType(r)?r:t};function Ip(t){if("fields"in t){const e={};for(const[n,r]of Object.entries(t.fields))e[n]=Ip(r);return t.setFields(e)}if(t.type==="array"){const e=t.optional();return e.innerType&&(e.innerType=Ip(e.innerType)),e}return t.type==="tuple"?t.optional().clone({types:t.spec.types.map(Ip)}):"optional"in t?t.optional():t}const sne=(t,e)=>{const n=[...qs.normalizePath(e)];if(n.length===1)return n[0]in t;let r=n.pop(),o=qs.getter(qs.join(n),!0)(t);return!!(o&&r in o)};let fP=t=>Object.prototype.toString.call(t)==="[object Object]";function pP(t,e){let n=Object.keys(t.fields);return Object.keys(e).filter(r=>n.indexOf(r)===-1)}const ane=dP([]);function hP(t){return new gP(t)}class gP extends Fo{constructor(e){super({type:"object",check(n){return fP(n)||typeof n=="function"}}),this.fields=Object.create(null),this._sortErrors=ane,this._nodes=[],this._excludedEdges=[],this.withMutation(()=>{e&&this.shape(e)})}_cast(e,n={}){var r;let o=super._cast(e,n);if(o===void 0)return this.getDefault(n);if(!this._typeCheck(o))return o;let i=this.fields,s=(r=n.stripUnknown)!=null?r:this.spec.noUnknown,a=[].concat(this._nodes,Object.keys(o).filter(p=>!this._nodes.includes(p))),l={},u=Object.assign({},n,{parent:l,__validating:n.__validating||!1}),f=!1;for(const p of a){let g=i[p],m=p in o;if(g){let y,b=o[p];u.path=(n.path?`${n.path}.`:"")+p,g=g.resolve({value:b,context:n.context,parent:l});let S=g instanceof Fo?g.spec:void 0,C=S==null?void 0:S.strict;if(S!=null&&S.strip){f=f||p in o;continue}y=!n.__validating||!C?g.cast(o[p],u):o[p],y!==void 0&&(l[p]=y)}else m&&!s&&(l[p]=o[p]);(m!==p in l||l[p]!==o[p])&&(f=!0)}return f?l:o}_validate(e,n={},r,o){let{from:i=[],originalValue:s=e,recursive:a=this.spec.recursive}=n;n.from=[{schema:this,value:s},...i],n.__validating=!0,n.originalValue=s,super._validate(e,n,r,(l,u)=>{if(!a||!fP(u)){o(l,u);return}s=s||u;let f=[];for(let p of this._nodes){let g=this.fields[p];!g||Us.isRef(g)||f.push(g.asNestedTest({options:n,key:p,parent:u,parentPath:n.path,originalParent:s}))}this.runTests({tests:f,value:u,originalValue:s,options:n},r,p=>{o(p.sort(this._sortErrors).concat(l),u)})})}clone(e){const n=super.clone(e);return n.fields=Object.assign({},this.fields),n._nodes=this._nodes,n._excludedEdges=this._excludedEdges,n._sortErrors=this._sortErrors,n}concat(e){let n=super.concat(e),r=n.fields;for(let[o,i]of Object.entries(this.fields)){const s=r[o];r[o]=s===void 0?i:s}return n.withMutation(o=>o.setFields(r,[...this._excludedEdges,...e._excludedEdges]))}_getDefault(e){if("default"in this.spec)return super._getDefault(e);if(!this._nodes.length)return;let n={};return this._nodes.forEach(r=>{var o;const i=this.fields[r];let s=e;(o=s)!=null&&o.value&&(s=Object.assign({},s,{parent:s.value,value:s.value[r]})),n[r]=i&&"getDefault"in i?i.getDefault(s):void 0}),n}setFields(e,n){let r=this.clone();return r.fields=e,r._nodes=one(e,n),r._sortErrors=dP(Object.keys(e)),n&&(r._excludedEdges=n),r}shape(e,n=[]){return this.clone().withMutation(r=>{let o=r._excludedEdges;return n.length&&(Array.isArray(n[0])||(n=[n]),o=[...r._excludedEdges,...n]),r.setFields(Object.assign(r.fields,e),o)})}partial(){const e={};for(const[n,r]of Object.entries(this.fields))e[n]="optional"in r&&r.optional instanceof Function?r.optional():r;return this.setFields(e)}deepPartial(){return Ip(this)}pick(e){const n={};for(const r of e)this.fields[r]&&(n[r]=this.fields[r]);return this.setFields(n,this._excludedEdges.filter(([r,o])=>e.includes(r)&&e.includes(o)))}omit(e){const n=[];for(const r of Object.keys(this.fields))e.includes(r)||n.push(r);return this.pick(n)}from(e,n,r){let o=qs.getter(e,!0);return this.transform(i=>{if(!i)return i;let s=i;return sne(i,e)&&(s=Object.assign({},i),r||delete s[e],s[n]=o(i)),s})}json(){return this.transform(ine)}exact(e){return this.test({name:"exact",exclusive:!0,message:e||kp.exact,test(n){if(n==null)return!0;const r=pP(this.schema,n);return r.length===0||this.createError({params:{properties:r.join(", ")}})}})}stripUnknown(){return this.clone({noUnknown:!0})}noUnknown(e=!0,n=kp.noUnknown){typeof e!="boolean"&&(n=e,e=!0);let r=this.test({name:"noUnknown",exclusive:!0,message:n,test(o){if(o==null)return!0;const i=pP(this.schema,o);return!e||i.length===0||this.createError({params:{unknown:i.join(", ")}})}});return r.spec.noUnknown=e,r}unknown(e=!0,n=kp.noUnknown){return this.noUnknown(!e,n)}transformKeys(e){return this.transform(n=>{if(!n)return n;const r={};for(const o of Object.keys(n))r[e(o)]=n[o];return r})}camelCase(){return this.transformKeys(S1.camelCase)}snakeCase(){return this.transformKeys(S1.snakeCase)}constantCase(){return this.transformKeys(e=>S1.snakeCase(e).toUpperCase())}describe(e){const n=(e?this.resolve(e):this).clone(),r=super.describe(e);r.fields={};for(const[i,s]of Object.entries(n.fields)){var o;let a=e;(o=a)!=null&&o.value&&(a=Object.assign({},a,{parent:a.value,value:a.value[i]})),r.fields[i]=s.describe(a)}return r}}hP.prototype=gP.prototype;const lne=t=>{const{id:e,title:n,onSave:r,onCancel:o,getCitationById:i,disableFileUpload:s=!1,setError:a}=t,l=J.useRef(null),[u,f]=J.useState(!0),[p,g]=J.useState({type:"Attachment",title:"",file:void 0,fileName:""});return J.useEffect(()=>{if(e===void 0){f(!1);return}i(e).then(m=>{g({...m,type:"Attachment",file:void 0}),f(!1)}).catch(m=>{f(!1),a({title:"Failed to retrieve attachment",err:m})})},[]),v.jsxs(v.Fragment,{children:[n&&v.jsx(F.Typography,{variant:"h6",margin:"10px 0",children:n}),v.jsx(jt.Formik,{innerRef:l,enableReinitialize:!0,initialValues:p,validationSchema:hP().shape({title:T1().required("Title is required"),fileName:T1().required("A file is required")}),onSubmit:async m=>{f(!0),r(m).catch(y=>{f(!1),a({title:`Failed to ${e===void 0?"save":"update"} attachment`,err:y})}).finally(()=>f(!1))},children:({values:m,setFieldValue:y})=>{var b;return J.useEffect(()=>{var S,C;(S=m.file)!=null&&S.name&&y("fileName",(C=m.file)==null?void 0:C.name)},[(b=m.file)==null?void 0:b.name]),v.jsxs(jt.Form,{autoComplete:"off",children:[v.jsx(da,{name:"title",disabled:u,required:!0,margin:"none"}),v.jsxs(F.Box,{display:"flex",flexDirection:"row",alignItems:"flex-start",children:[v.jsx(gC,{name:"file",readOnly:s}),m.fileName&&v.jsx("span",{style:{margin:"6px 0 0 10px"},children:m.fileName}),v.jsx(Xn,{name:"fileName",id:"fileName-err"})]}),v.jsxs(F.DialogActions,{sx:{px:0},children:[v.jsx(F.Button,{onClick:o,variant:"outlined",size:"small",children:"Cancel"}),v.jsx(b1,{size:"small",loading:u,children:e?"Update Attachment":"Add New Attachment"})]})]})}})]})},ou=t=>{const{open:e=!1,onClose:n,title:r,children:o,actions:i,closeBtnLabel:s,closeButtonPosition:a,closeButtonProps:l={},disableDismiss:u=!1,...f}=t;if(!e)return null;const p=a==="bottom"||a==="top-and-bottom",g=a==="top"||a==="top-and-bottom",m=()=>{if(s&&p)return v.jsx(F.Button,{className:"MBv2_Modal_Close",onClick:t.onClose,...l,children:s})},y=()=>{if(i)return v.jsx(F.DialogActions,{className:"MBv2_Modal_Actions",children:v.jsxs(F.Box,{display:"flex",flexDirection:"row",justifyContent:"space-between",width:"100%",gap:"0.25rem",children:[v.jsx(F.Box,{children:m()}),v.jsxs(F.Box,{display:"flex",gap:".25rem",children:[...i]})]})});if(s&&p)return v.jsx(F.DialogActions,{className:"MBv2_Modal_Actions",children:v.jsx(F.Box,{children:m()})})};return v.jsxs(F.Dialog,{className:"MBv2_Modal",open:e,onClose:()=>{u||n==null||n()},...f,children:[typeof r=="string"?v.jsx(F.DialogTitle,{className:"MBv2_Modal_Title",children:v.jsxs(F.Box,{display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center",children:[r,g&&v.jsx(F.IconButton,{"data-testid":"modal-header-close-btn",onClick:n,children:v.jsx(sR,{})})]})}):r,o&&(typeof o=="string"?v.jsx(F.DialogContent,{className:"MBv2_Modal_Content",children:v.jsx(F.DialogContentText,{className:"MBv2_Modal_Content_Text",children:o})}):o),y()]})};function cne(t){return Ke("MuiAlert",t)}const mP=qe("MuiAlert",["root","action","icon","message","filled","colorSuccess","colorInfo","colorWarning","colorError","filledSuccess","filledInfo","filledWarning","filledError","outlined","outlinedSuccess","outlinedInfo","outlinedWarning","outlinedError","standard","standardSuccess","standardInfo","standardWarning","standardError"]),une=ze(v.jsx("path",{d:"M20,12A8,8 0 0,1 12,20A8,8 0 0,1 4,12A8,8 0 0,1 12,4C12.76,4 13.5,4.11 14.2, 4.31L15.77,2.74C14.61,2.26 13.34,2 12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0, 0 22,12M7.91,10.08L6.5,11.5L11,16L21,6L19.59,4.58L11,13.17L7.91,10.08Z"}),"SuccessOutlined"),dne=ze(v.jsx("path",{d:"M12 5.99L19.53 19H4.47L12 5.99M12 2L1 21h22L12 2zm1 14h-2v2h2v-2zm0-6h-2v4h2v-4z"}),"ReportProblemOutlined"),fne=ze(v.jsx("path",{d:"M11 15h2v2h-2zm0-8h2v6h-2zm.99-5C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"}),"ErrorOutline"),pne=ze(v.jsx("path",{d:"M11,9H13V7H11M12,20C7.59,20 4,16.41 4,12C4,7.59 7.59,4 12,4C16.41,4 20,7.59 20, 12C20,16.41 16.41,20 12,20M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10, 10 0 0,0 12,2M11,17H13V11H11V17Z"}),"InfoOutlined"),hne=ze(v.jsx("path",{d:"M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}),"Close"),gne=t=>{const{variant:e,color:n,severity:r,classes:o}=t,i={root:["root",`color${Ae(n||r)}`,`${e}${Ae(n||r)}`,`${e}`],icon:["icon"],message:["message"],action:["action"]};return Ue(i,cne,o)},mne=be(ya,{name:"MuiAlert",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:n}=t;return[e.root,e[n.variant],e[`${n.variant}${Ae(n.color||n.severity)}`]]}})(Dt(({theme:t})=>{const e=t.palette.mode==="light"?ia:Ol,n=t.palette.mode==="light"?Ol:ia;return{...t.typography.body2,backgroundColor:"transparent",display:"flex",padding:"6px 16px",variants:[...Object.entries(t.palette).filter(Hn(["light"])).map(([r])=>({props:{colorSeverity:r,variant:"standard"},style:{color:t.vars?t.vars.palette.Alert[`${r}Color`]:e(t.palette[r].light,.6),backgroundColor:t.vars?t.vars.palette.Alert[`${r}StandardBg`]:n(t.palette[r].light,.9),[`& .${mP.icon}`]:t.vars?{color:t.vars.palette.Alert[`${r}IconColor`]}:{color:t.palette[r].main}}})),...Object.entries(t.palette).filter(Hn(["light"])).map(([r])=>({props:{colorSeverity:r,variant:"outlined"},style:{color:t.vars?t.vars.palette.Alert[`${r}Color`]:e(t.palette[r].light,.6),border:`1px solid ${(t.vars||t).palette[r].light}`,[`& .${mP.icon}`]:t.vars?{color:t.vars.palette.Alert[`${r}IconColor`]}:{color:t.palette[r].main}}})),...Object.entries(t.palette).filter(Hn(["dark"])).map(([r])=>({props:{colorSeverity:r,variant:"filled"},style:{fontWeight:t.typography.fontWeightMedium,...t.vars?{color:t.vars.palette.Alert[`${r}FilledColor`],backgroundColor:t.vars.palette.Alert[`${r}FilledBg`]}:{backgroundColor:t.palette.mode==="dark"?t.palette[r].dark:t.palette[r].main,color:t.palette.getContrastText(t.palette[r].main)}}}))]}})),yne=be("div",{name:"MuiAlert",slot:"Icon",overridesResolver:(t,e)=>e.icon})({marginRight:12,padding:"7px 0",display:"flex",fontSize:22,opacity:.9}),bne=be("div",{name:"MuiAlert",slot:"Message",overridesResolver:(t,e)=>e.message})({padding:"8px 0",minWidth:0,overflow:"auto"}),vne=be("div",{name:"MuiAlert",slot:"Action",overridesResolver:(t,e)=>e.action})({display:"flex",alignItems:"flex-start",padding:"4px 0 0 16px",marginLeft:"auto",marginRight:-8}),yP={success:v.jsx(une,{fontSize:"inherit"}),warning:v.jsx(dne,{fontSize:"inherit"}),error:v.jsx(fne,{fontSize:"inherit"}),info:v.jsx(pne,{fontSize:"inherit"})},bP=I.forwardRef(function(e,n){const r=St({props:e,name:"MuiAlert"}),{action:o,children:i,className:s,closeText:a="Close",color:l,components:u={},componentsProps:f={},icon:p,iconMapping:g=yP,onClose:m,role:y="alert",severity:b="success",slotProps:S={},slots:C={},variant:T="standard",..._}=r,w={...r,color:l,severity:b,variant:T,colorSeverity:l||b},E=gne(w),O={slots:{closeButton:u.CloseButton,closeIcon:u.CloseIcon,...C},slotProps:{...f,...S}},[L,P]=zt("root",{ref:n,shouldForwardComponentProp:!0,className:Le(E.root,s),elementType:mne,externalForwardedProps:{...O,..._},ownerState:w,additionalProps:{role:y,elevation:0}}),[$,M]=zt("icon",{className:E.icon,elementType:yne,externalForwardedProps:O,ownerState:w}),[A,N]=zt("message",{className:E.message,elementType:bne,externalForwardedProps:O,ownerState:w}),[z,V]=zt("action",{className:E.action,elementType:vne,externalForwardedProps:O,ownerState:w}),[B,R]=zt("closeButton",{elementType:Sa,externalForwardedProps:O,ownerState:w}),[q,U]=zt("closeIcon",{elementType:hne,externalForwardedProps:O,ownerState:w});return v.jsxs(L,{...P,children:[p!==!1?v.jsx($,{...M,children:p||g[b]||yP[b]}):null,v.jsx(A,{...N,children:i}),o!=null?v.jsx(z,{...V,children:o}):null,o==null&&m?v.jsx(z,{...V,children:v.jsx(B,{size:"small","aria-label":a,title:a,color:"inherit",onClick:m,...R,children:v.jsx(q,{fontSize:"small",...U})})}):null]})});process.env.NODE_ENV!=="production"&&(bP.propTypes={action:c.node,children:c.node,classes:c.object,className:c.string,closeText:c.string,color:c.oneOfType([c.oneOf(["error","info","success","warning"]),c.string]),components:c.shape({CloseButton:c.elementType,CloseIcon:c.elementType}),componentsProps:c.shape({closeButton:c.object,closeIcon:c.object}),icon:c.node,iconMapping:c.shape({error:c.node,info:c.node,success:c.node,warning:c.node}),onClose:c.func,role:c.string,severity:c.oneOfType([c.oneOf(["error","info","success","warning"]),c.string]),slotProps:c.shape({action:c.oneOfType([c.func,c.object]),closeButton:c.oneOfType([c.func,c.object]),closeIcon:c.oneOfType([c.func,c.object]),icon:c.oneOfType([c.func,c.object]),message:c.oneOfType([c.func,c.object]),root:c.oneOfType([c.func,c.object])}),slots:c.shape({action:c.elementType,closeButton:c.elementType,closeIcon:c.elementType,icon:c.elementType,message:c.elementType,root:c.elementType}),sx:c.oneOfType([c.arrayOf(c.oneOfType([c.func,c.object,c.bool])),c.func,c.object]),variant:c.oneOfType([c.oneOf(["filled","outlined","standard"]),c.string])});const iu=t=>{var m;const{noIcon:e=!1,children:n,severity:r="success",variant:o="leftBorder",sx:i,title:s,...a}=t,{palette:l}=F.useTheme(),u=e?{icon:!1}:{},f=o==="leftBorder"?"standard":o,p=o==="leftBorder"?{...i,borderLeft:`4px solid ${(m=l[r])==null?void 0:m.main}`}:i,g=s?{icon:{sx:{mt:"6px"}}}:{};return v.jsxs(bP,{severity:r,variant:f,sx:p,slotProps:g,...u,...a,children:[s&&v.jsx(F.Typography,{variant:"h3",children:s}),n]})},vP=t=>v.jsx(iu,{severity:"error",...t}),xP=t=>v.jsx(iu,{severity:"success",...t}),xne=t=>{const{error:e,setError:n,success:r,setSuccess:o}=t;return v.jsxs(v.Fragment,{children:[e&&v.jsx(vP,{"data-testid":"citation-menu-error",onClose:()=>n(void 0),children:e.title}),r&&v.jsx(xP,{"data-testid":"citation-menu-success",onClose:()=>o(void 0),children:r})]})};function k1({getCitationsPaginated:t,onCreateCitation:e,onUpdateCitation:n,onDeleteCitation:r,getCitationById:o,onDownloadAttachment:i,onSelectCitations:s,onCancel:a,initialSelectedIds:l=[],onContentChange:u,onError:f=()=>{},renderAsSelectablePopup:p=!1,addlActions:g}){const[m,y]=J.useState("Insert Citation/Attachment(s)"),[b,S]=J.useState(l),[C,T]=J.useState(void 0),[_,w]=J.useState(void 0),[E,O]=J.useState(void 0),[L,P]=J.useState(0);J.useEffect(()=>{u==null||u()},[m,_,E,u]),J.useEffect(()=>{p&&w(void 0)},[m]),J.useEffect(()=>{_&&f(_.err)},[_]);const $=()=>{p||P(q=>q+1)},M=async q=>{if(m==="Edit Citation"||m==="Edit Attachment"){if(q.id===void 0)throw Error("Failed to update citation. Citation is missing id");await(n==null?void 0:n(q).then(()=>{y("Insert Citation/Attachment(s)"),$()}).catch(U=>w({title:"Failed to update citation",err:U})))}else(m==="Add Citation"||m==="Add Attachment")&&await(e==null?void 0:e(q).then(U=>{S([...b,U.id]),y("Insert Citation/Attachment(s)"),$()}).catch(U=>w({title:"Failed to create citation",err:U})))},A=v.jsx(Mte,{refreshKey:L,getCitationsPaginated:q=>t(q).then(U=>(u==null||u(),U)),onCancel:a,onNewCitation:()=>{T(void 0),y("Add Citation")},onNewAttachment:()=>{T(void 0),y("Add Attachment")},onEditCitation:q=>{T(q.id),y("Edit Citation")},onEditAttachment:q=>{T(q.id),y("Edit Attachment")},onDeleteCitation:r,onDownloadAttachment:i,onSelect:s,setSelectedIds:S,selectedIds:b,onError:f,setError:w,setSuccess:O,condenseTable:p,canSelect:p,title:p?m:"Attachments & Citations",addlActions:g,canCreate:!!e,canEdit:!!n}),N=v.jsx(Ote,{id:C,onSave:M,onCancel:()=>y("Insert Citation/Attachment(s)"),getCitationById:o,setError:w,title:m}),z=v.jsx(lne,{id:C,onSave:M,onCancel:()=>y("Insert Citation/Attachment(s)"),getCitationById:o,disableFileUpload:m==="Edit Attachment",setError:w,title:m}),V=v.jsx(xne,{error:_,setError:w,success:E,setSuccess:O}),B=m==="Add Citation"||m==="Edit Citation",R=m==="Add Attachment"||m==="Edit Attachment";if(p){let q=null;return!p||m==="Insert Citation/Attachment(s)"?q=A:B?q=N:R&&(q=z),v.jsxs(F.Box,{width:"500px",children:[V,v.jsx(F.Box,{paddingTop:"8px",children:q})]})}return v.jsxs(F.Box,{width:"100%",children:[m==="Insert Citation/Attachment(s)"&&V,v.jsx(F.Box,{paddingTop:"8px",children:A}),v.jsx(ou,{open:B||R,children:v.jsxs(F.Box,{padding:"10px 20px",minWidth:"400px","data-testid":"citation-form-modal",children:[V,B?N:z]})})]})}const Sne=Ut({name:{CitationBubbleMenuTipTap:SP}})(t=>({content:{padding:t.spacing(1.5,2,.5),backgroundColor:"#f9f9f9"}}));function SP({getCitationsPaginated:t,onCreateCitation:e,onUpdateCitation:n,onDeleteCitation:r,getCitationById:o,onDownloadAttachment:i,...s}){const{classes:a}=Sne(),l=bt();if(!(l!=null&&l.isEditable))return null;if(!("citationBubbleMenuHandler"in l.storage))throw new Error("You must add the CitationBubbleMenuHandler extension to the useEditor `extensions` array in order to use this component!");const u=l.storage.citationBubbleMenuHandler,f=u.isOpen,p=u.selectedIds,g=u.selectedNodePos,m=C=>{l&&(C.length===0?l.commands.deleteCitation(g):p.length===0?l.commands.insertCitation({ids:C}):l.commands.updateCitation({ids:C},g))},y=C=>{m(C),l.commands.closeCitationBubbleMenu()},b=()=>{m(p),l.commands.closeCitationBubbleMenu()},S=J.useCallback(()=>{requestAnimationFrame(()=>{l!=null&&l.view&&l.view.dispatch(l.view.state.tr)})},[l]);return v.jsx(Af,{editor:l,open:f,...u.bubbleMenuOptions,...s,children:v.jsx("div",{className:a.content,children:v.jsx(k1,{getCitationsPaginated:t,onCreateCitation:e,onUpdateCitation:n,onDeleteCitation:r,getCitationById:o,onDownloadAttachment:i,onSelectCitations:y,onCancel:b,initialSelectedIds:p,onContentChange:S,renderAsSelectablePopup:!0})})})}const Cne=sn.create({name:"starterKit",addExtensions(){const t=[];return this.options.bold!==!1&&t.push(rD.configure(this.options.bold)),this.options.blockquote!==!1&&t.push(nD.configure(this.options.blockquote)),this.options.bulletList!==!1&&t.push(sD.configure(this.options.bulletList)),this.options.code!==!1&&t.push(aD.configure(this.options.code)),this.options.codeBlock!==!1&&t.push(lD.configure(this.options.codeBlock)),this.options.document!==!1&&t.push(cD.configure(this.options.document)),this.options.dropcursor!==!1&&t.push(uD.configure(this.options.dropcursor)),this.options.gapcursor!==!1&&t.push(dD.configure(this.options.gapcursor)),this.options.hardBreak!==!1&&t.push(fD.configure(this.options.hardBreak)),this.options.heading!==!1&&t.push(MI.configure(this.options.heading)),this.options.history!==!1&&t.push(vD.configure(this.options.history)),this.options.horizontalRule!==!1&&t.push(xD.configure(this.options.horizontalRule)),this.options.italic!==!1&&t.push(SD.configure(this.options.italic)),this.options.listItem!==!1&&t.push(BD.configure(this.options.listItem)),this.options.orderedList!==!1&&t.push(VD.configure(this.options.orderedList)),this.options.paragraph!==!1&&t.push(HD.configure(this.options.paragraph)),this.options.strike!==!1&&t.push(WD.configure(this.options.strike)),this.options.text!==!1&&t.push(qD.configure(this.options.text)),t}}),wne=()=>sn.create({name:"citationBubbleMenuHandler",addStorage(){return{isOpen:!1,selectedIds:[],bubbleMenuOptions:void 0,selectedNodePos:0}},addCommands(){return{openCitationBubbleMenu:(t={},e)=>({editor:n,dispatch:r})=>{var a;const{doc:o}=n.state,i=o.nodeAt(e??0),s=((a=i==null?void 0:i.attrs)==null?void 0:a.ids)??[];return r&&(this.storage.isOpen=!0,this.storage.selectedIds=s,this.storage.bubbleMenuOptions=t,this.storage.selectedNodePos=e??0),!0},closeCitationBubbleMenu:()=>({commands:t,dispatch:e})=>this.storage.isOpen?(t.focus(),e&&(this.storage.isOpen=!1,this.storage.selectedIds=[],this.storage.selectedNodePos=0),!0):!1}},onSelectionUpdate(){this.storage.isOpen&&!this.editor.isActive("citation")&&this.editor.commands.closeCitationBubbleMenu()},addKeyboardShortcuts(){return{"Mod-Shift-c":()=>(this.editor.commands.openCitationBubbleMenu(),!0)}}});function _ne(t){const e=bt(),n=J.useRef(null);return v.jsx(gt,{buttonRef:n,tooltipLabel:"Insert Citation/Attachment",tooltipShortcutKeys:["mod","Shift","C"],disabled:!(e!=null&&e.isEditable),onClick:()=>e==null?void 0:e.commands.openCitationBubbleMenu({anchorEl:n.current,placement:"bottom"}),...t,children:v.jsxs(F.Box,{display:"flex",flexDirection:"row",gap:"4px",alignItems:"center",children:[v.jsx(rR,{fontSize:"small"}),v.jsx(F.Typography,{variant:"body2",children:"Insert Citation/Attachment"})]})})}const CP=J.createContext(void 0),wP=()=>{const t=J.useContext(CP);if(!t)throw new Error("useSync must be used inside CitationFieldProvider");return t},Tne=({node:t,HTMLAttributes:e,selected:n,extension:r,updateAttributes:o,deleteNode:i})=>{const s=t.attrs.ids||[],{citations:a,isLoaded:l}=wP(),[u,f]=J.useState(String(s)),[p,g]=J.useState([]),m=r.options.citationMaxLength;if(J.useEffect(()=>{if(!l)return;const y=a.filter(C=>s.includes(C.id)),b=y.map(C=>Ku.truncate(C.title,{length:m,omission:"..."})).join(", ");f(b),g(y);const S=y.map(C=>C.id);S.length===0?setTimeout(i,0):S.length!==s.length&&setTimeout(()=>o({ids:y.map(C=>C.id)}),0)},[a,s,l]),p.length!==0)return v.jsx(yv,{as:"span",...e,"data-testid":"citation-node-component",children:v.jsx(F.Tooltip,{title:v.jsx(F.Box,{className:"citation-tooltip",children:p.map((y,b)=>{var C;const S=[y.source,y.title,y.fileName,y.url,(C=y.accessedAt)==null?void 0:C.slice(0,10),y.classification];return v.jsxs(F.Typography,{variant:"subtitle2",children:[S.filter(Boolean).join(" | "),b<p.length-1&&v.jsx(F.Divider,{className:"citation-tooltip-divider"})]},y.id)})}),slotProps:{tooltip:{sx:{maxWidth:500}}},children:v.jsx("a",{href:"#",onClick:y=>{y.preventDefault(),y.stopPropagation()},className:n?"selected-citation-link":"citation-link",children:u})})})},kne=tn.create({name:"citation",group:"inline",inline:!0,atom:!0,selectable:!0,addAttributes(){return{ids:{default:[],parseHTML:t=>{const e=t.getAttribute("ids");return e?e.split(",").map(n=>parseInt(n.trim(),10)).filter(n=>!isNaN(n)):[]},renderHTML:t=>({ids:Array.isArray(t.ids)?t.ids.join(","):""})}}},parseHTML(){return[{tag:"citation"}]},renderHTML({HTMLAttributes:t}){return["citation",yt(t)]},addNodeView(){return bv(Tne)},addProseMirrorPlugins(){return[new en({props:{handleClickOn:(t,e,n,r,o,i)=>n&&n.type.name==="citation"?(this.editor.commands.openCitationBubbleMenu({},r),!0):!1}})]},addCommands(){return{insertCitation:t=>({commands:e})=>e.insertContent({type:"citation",attrs:t}),updateCitation:(t,e)=>({state:n,dispatch:r,tr:o})=>{const i=n.doc.nodeAt(e);return!i||i.type.name!=="citation"?!1:(o.setNodeMarkup(e,void 0,t),r&&r(o),!0)},deleteCitation:t=>({tr:e,dispatch:n})=>{if(typeof t!="number")return!1;const r=t,o=t+1;return n&&n(e.delete(r,o)),!0}}}}),Ene=t=>{const{name:e,label:n=_n(e),hideLabel:r=!1,required:o=!1,readOnly:i=!1,margin:s="dense",citationMaxLength:a=24,getCitationsPaginated:l,onCreateCitation:u,onUpdateCitation:f,onDeleteCitation:p,getCitationById:g,onDownloadAttachment:m,onError:y=()=>{}}=t,b=[Cne,jD.configure({placeholder:"Start typing here..."}),wne(),kne.configure({citationMaxLength:a})],[S,C,T]=jt.useField({name:e}),{setValue:_}=T,{value:w}=S,{addUpdateCitation:E,deleteCitation:O,batchUpdate:L}=wP();J.useEffect(()=>{var V;const N=(V=P==null?void 0:P.current)==null?void 0:V.editor;if(!N||!w)return;N.getHTML()!==w&&setTimeout(()=>{N.commands.setContent(w)},0)},[w]);const P=J.useRef(null),$={normal:{marginTop:"16px",marginBottom:"8px"},dense:{marginTop:"8px",marginBottom:"4px"},none:{margin:0}},M=()=>{var V,B;const N=((B=(V=P.current)==null?void 0:V.editor)==null?void 0:B.getHTML())??"<p></p>",z=!N.replace(/<\/?p>|<br>/g,"").trim();_(z?"<p></p>":N)},A=v.jsxs(F.Box,{id:`citation-field_${e}`,sx:{"& .ProseMirror":{"& h1, & h2, & h3, & h4, & h5, & h6":{scrollMarginTop:i?0:50}}},...$[s],children:[v.jsx(iI,{ref:P,extensions:b,content:w,editable:!i,renderControls:i?void 0:()=>v.jsx(Nf,{children:v.jsx(_ne,{})}),onBlur:M,RichTextFieldProps:{variant:"outlined",MenuBarProps:{hide:i}},children:()=>v.jsx(SP,{getCitationsPaginated:N=>l(N).then(z=>(L(z.data),z)),onCreateCitation:u&&(N=>u(N).then(z=>(E(z),z))),onUpdateCitation:f&&(N=>f(N).then(z=>(E(z),z))),onDeleteCitation:p&&(N=>p(N).then(()=>O(N))),getCitationById:g,onDownloadAttachment:m,onError:y})}),v.jsx(Xn,{name:e,id:`${e}-err`})]});return v.jsxs(F.Box,{display:"flex",flexDirection:"column",width:"100%",children:[!r&&v.jsx(F.InputLabel,{htmlFor:`citation-field_${e}`,required:o,children:n}),A]})},Mne=t=>{const{name:e="submit"}=t;return v.jsx(No,{name:e,type:"submit",...t})},One=t=>{const{label:e="Return to Top",icon:n=RC,scrollThresholdPx:r=100}=t,o=F.useScrollTrigger({threshold:r}),i=J.useCallback(()=>{window.scrollTo({top:0,behavior:"smooth"})},[]);return v.jsx(F.Zoom,{in:o,children:v.jsx(F.Box,{sx:{position:"fixed",bottom:32,right:32,zIndex:1},children:v.jsxs(F.Fab,{onClick:i,color:"primary",size:"small",variant:"extended","aria-label":"Scroll back to top",children:[v.jsx(n,{fontSize:"medium"}),e]})})})},Ane=()=>{const{values:t,errors:e,status:n}=jt.useFormikContext(),{palette:r}=F.useTheme();return v.jsx(F.Paper,{style:{backgroundColor:r.mode==="dark"?"#303030":"#f0f0f0",margin:"10px 0"},children:v.jsxs(F.List,{children:[v.jsxs(F.ListItem,{children:[v.jsx(F.Typography,{display:"block",variant:"h6",children:"Values"}),v.jsx("br",{}),v.jsx(F.Divider,{variant:"inset"}),v.jsx("pre",{children:JSON.stringify(t,null,2)})]}),v.jsx(F.Divider,{variant:"inset",component:"li"}),v.jsxs(F.ListItem,{id:"testing",children:[v.jsx(F.Typography,{display:"block",variant:"h6",children:"Errors"}),v.jsx("br",{}),v.jsx(F.Divider,{variant:"inset"}),v.jsx("pre",{children:JSON.stringify(e,null,2)})]}),v.jsxs(F.ListItem,{children:[v.jsx(F.Typography,{display:"block",variant:"h6",children:"Status"}),v.jsx("br",{}),v.jsx(F.Divider,{variant:"inset"}),v.jsx("pre",{children:JSON.stringify(n,null,2)})]})]})})},Ine=t=>{const{steps:e,orientation:n,inlineLabel:r=n=="vertical",isResponsive:o=!1}=t,{width:i}=QD();let s=!r,a=n;o&&(n&&console.warn("Stepper: Ignoring orientation. isResponsive is set to true, so the orientation is determined automatically based on the window size."),a=i<600?"vertical":"horizontal",a=="vertical"?s=!1:s=!r),n=="vertical"&&!r&&(console.warn("Stepper: ignoring inlineLabel={false}. Must use inline labels when orientation is vertical"),s=!1);const l=["steps","inlineLabel","orientation","isResponsive"],u={alternativeLabel:s,orientation:a,...Jn({...t},l)};return v.jsx(F.Stepper,{...u,children:e.map(f=>v.jsx(F.Step,{children:v.jsx(F.StepLabel,{children:f})},f))})},Dne=t=>{const{name:e,label:n=_n(e),labelProps:r={fontSize:"1.1em",color:"#808080",fontWeight:"600"},initialState:o,renderFormGroup:i,addButtonContent:s="Add Another",removeButtonContent:a=t.removePosition==="right"?v.jsx(FR,{}):"Remove",variant:l="card",addButtonSx:u,removeButtonSx:f,allowRemoveAll:p=!1,readOnly:g=!1,emptyListMsg:m="None",showDivider:y=!1,removePosition:b="bottom"}=t,[S]=jt.useField({name:e}),{value:C}=S,T=_=>({display:"flex",flexDirection:_==="bottom"?"column":"row",alignItems:_==="bottom"?"flex-start":"center"});return v.jsxs(F.FormControl,{fullWidth:!0,children:[v.jsx(F.Typography,{...r,children:n}),g&&S.value.length===0?v.jsx(F.Typography,{children:m}):v.jsx(jt.FieldArray,{name:e,render:_=>v.jsxs("div",{children:[C.map((w,E)=>v.jsx(J.Fragment,{children:v.jsx(Pne,{variant:l,content:v.jsxs(F.Box,{"data-testid":"form-group-container",sx:typeof b=="string"?T(b):{...b},children:[v.jsxs(F.Box,{width:"100%",children:[i(`${e}.${E}`,E),y&&E!==C.length-1&&v.jsx(F.Divider,{"data-testid":"divider"})]}),!g&&C.length>(p?0:1)&&v.jsx(F.Button,{"data-testid":"repeatable-form-group_remove-btn",sx:f,onClick:()=>_.remove(E),children:a})]})})},`${e}-${E}`)),!g&&v.jsx(F.Button,{"data-testid":"repeatable-form-group_add-btn",onClick:()=>_.push(o),sx:u,children:s})]})})]})},Pne=({variant:t,content:e})=>{switch(t){case"card":return v.jsx(F.Card,{"data-testid":"repeatable-form-group_card",sx:{padding:"8px",marginBottom:"8px"},children:v.jsx(F.CardContent,{children:e})});case"elevatedCard":return v.jsx(F.Card,{"data-testid":"repeatable-form-group_elevated-card",elevation:4,sx:{border:"unset",padding:"8px",marginBottom:"8px"},children:v.jsx(F.CardContent,{children:e})});case"none":return e}},Nne=t=>{const{confirmBtnLabel:e,onConfirm:n,confirmButtonProps:r={color:"primary",variant:"contained"},closeBtnLabel:o="Cancel",closeButtonPosition:i="bottom",...s}=t;return v.jsx(ou,{actions:[v.jsx(F.Button,{className:"MBv2_ConfirmationModal_ConfirmBtn",onClick:n,...r,children:e})],closeBtnLabel:o,closeButtonPosition:i,...s})},Lne=t=>{const{closeBtnLabel:e="OK",closeButtonPosition:n="bottom",closeButtonProps:r={color:"primary",variant:"contained"},...o}=t;return v.jsx(ou,{closeBtnLabel:e,closeButtonPosition:n,closeButtonProps:r,...o})},Fne=t=>{const{primaryBtnLabel:e,onPrimaryAction:n,primaryActionProps:r={color:"primary",variant:"contained"},secondaryBtnLabel:o,onSecondaryAction:i,secondaryActionProps:s={color:"primary",variant:"outlined"},closeBtnLabel:a="Cancel",closeButtonPosition:l="bottom",...u}=t;return v.jsx(ou,{actions:[v.jsx(F.Button,{className:"MBv2_DecisionModal_SecondaryAction",onClick:i,...s,children:o}),v.jsx(F.Button,{className:"MBv2_DecisionModal_PrimaryAction",onClick:n,...r,children:e})],closeBtnLabel:a,closeButtonPosition:l,...u})},$ne=t=>{const{featureMenuOptions:e=[],copyright:n,logo:r,sx:o={},fontColor:i="primary"}=t,{palette:s}=F.useTheme(),a=eo.useNavigate();return v.jsxs(F.Box,{className:"MBv2_Footer",sx:{backgroundColor:s.mode==="dark"?"#222222":"#ededed",padding:"25px 30px",...o},children:[v.jsx(F.Box,{className:"MBv2_Footer_Logo",sx:{display:"flex",gap:2,alignItems:"center",paddingBottom:1},children:typeof r=="string"?v.jsx("img",{draggable:"false",src:r,style:{width:"200px"},alt:"logo"}):r}),v.jsxs(F.Box,{display:"flex",justifyContent:"space-between",flexWrap:"wrap",className:"MBv2_Footer_Nav_Links_Container",gap:2,children:[v.jsx(F.Box,{sx:{flexGrow:1},className:"MBv2_Footer_Nav_Links",display:"flex",flexDirection:"row",justifyContent:"flex-start",gap:3,children:e==null?void 0:e.map(l=>v.jsx(F.Link,{"data-testid":l.label,sx:{cursor:"pointer",fontSize:15},color:i,...vl(l,a),children:l.label},l.label))}),n&&v.jsx(F.Typography,{style:{fontSize:15},"data-testid":"copyright",className:"MBv2_Footer_Copyright",color:i,children:n})]})]})},_P=t=>{const{menuOptionLists:e,anchor:n="left",children:r}=t,{pathname:o}=eo.useLocation(),i=eo.useNavigate(),[s,a]=J.useState(!1),l=(g,m)=>v.jsx(F.MenuList,{children:g.map(y=>v.jsxs(F.MenuItem,{...vl(y,i,()=>a(!1)),children:[y.icon&&v.jsx(F.ListItemIcon,{children:y.icon}),v.jsx(F.ListItemText,{primary:y.label})]},`mobile-drawer-group-${m}-item-${y.path}`))}),f=(()=>{if(e){const g=e.filter(m=>m&&m.length>0);return g.length===0?null:g.map((m,y)=>v.jsxs(J.Fragment,{children:[l(m,y),y<g.length-1&&v.jsx(F.Divider,{})]},`mobile-drawer-group-${y}`))}return r?v.jsx(F.Box,{role:"presentation",onClick:()=>a(!1),children:r}):null})(),p=f??!1;return J.useEffect(()=>{a(!1)},[o]),p&&v.jsxs(v.Fragment,{children:[v.jsx(F.IconButton,{onClick:()=>a(!0),color:"inherit",title:"Menu",children:v.jsx(IR,{})}),v.jsx(F.Drawer,{"data-testid":"mobile-drawer",anchor:n,open:s,onClose:()=>a(!1),children:v.jsx(F.Box,{sx:{width:300},display:"flex",flexDirection:"column",justifyContent:"space-between",children:v.jsx(F.Box,{display:"flex",justifyContent:"start",flexDirection:"column",children:f})})})]})},TP=t=>{const{env:e,isProd:n}=t;return n?null:v.jsx(F.Paper,{sx:{borderRadius:0,display:"flex",alignItems:"center",justifyContent:"center"},children:v.jsxs(F.Typography,{variant:"h6",color:"error",children:[e," Environment - Test Data Only"]})})},kP=t=>{const{label:e,menuOptions:n=[],icon:r}=t,o=eo.useNavigate(),[i,s]=I.useState(null),a=!!i,l=f=>{s(f.currentTarget)},u=()=>{s(null)};return n.length===0?null:v.jsxs(v.Fragment,{children:[v.jsx(F.Button,{startIcon:r,variant:"outlined",color:"inherit",sx:{minWidth:0,padding:1},onClick:l,children:e}),v.jsx(F.Menu,{anchorEl:i,open:a,onClick:u,children:n.map(f=>v.jsxs(F.MenuItem,{...vl(f,o),children:[f.icon&&v.jsx(F.ListItemIcon,{children:f.icon}),v.jsx(F.ListItemText,{primary:f.label})]},f.label))})]})},EP=t=>{const{displayName:e,userMenuOptions:n}=t;return v.jsx(kP,{label:e,menuOptions:n,icon:v.jsx(PR,{})})},Dp=t=>{const{menuOptions:e,orientation:n="horizontal",activeTabIdx:r,sx:o=n=="vertical"?{"& .MuiTabs-indicator":{left:0}}:void 0,slotProps:i={indicator:{sx:n=="horizontal"?{height:4}:{width:4}}}}=t,{palette:s}=F.useTheme(),a=eo.useNavigate();return v.jsx(F.Tabs,{orientation:n,value:r??!1,sx:o,slotProps:i,children:e.map((l,u)=>v.jsx(F.Tab,{icon:l.icon,label:l.label,value:u,...vl(l,a),sx:{alignItems:n=="vertical"?"flex-start":void 0,borderBottom:n=="vertical"?"1px solid":void 0,borderColor:"divider","&.Mui-selected":{backgroundColor:n=="vertical"?s.grey[s.mode=="dark"?800:50]:void 0,color:"inherit"}}},l.label))})},MP=t=>{const{featureMenuOptions:e=[],activeTabIdx:n,sx:r}=t;return e.length>0&&v.jsx(F.Paper,{sx:{pl:4,pr:4,borderRadius:0},"data-testid":"navBar",children:v.jsx(Dp,{menuOptions:e,activeTabIdx:n,sx:r})})},OP=t=>{const{onToggle:e}=t,{palette:n}=F.useTheme(),r=n.mode==="dark";return v.jsx(F.IconButton,{onClick:e,color:"inherit",title:"Dark Mode Toggle",children:r?v.jsx(zC,{}):v.jsx($C,{})})},Bne=t=>{const{envInfo:e,headerRef:n,logo:r,featureMenuOptions:o=[],userMenuOptions:i=[],onToggleDarkMode:s,quickLinks:a=[],displayName:l,banner:u,position:f="fixed",children:p,sx:g,navBarSx:m}=t,y=eo.useNavigate(),b=F.useMediaQuery(F.useTheme().breakpoints.down("sm")),{palette:S}=F.useTheme(),{pathname:C}=eo.useLocation(),T=S.mode==="dark",[_,w]=I.useState(void 0);I.useEffect(()=>{const L=o.findIndex(P=>P.path&&C.startsWith(P.path));w(L>=0?L:void 0)},[C,o]);const E=s&&v.jsx(OP,{onToggle:s}),O=s&&(b||!b&&l)?[{icon:T?v.jsx(zC,{}):v.jsx($C,{}),label:`Switch to ${T?"Light":"Dark"} mode`,onClick:s},...i]:i;return v.jsxs(F.AppBar,{ref:n,position:f,sx:g,elevation:4,children:[e&&v.jsx(TP,{...e}),u,v.jsxs(F.Toolbar,{sx:{color:"white",display:"flex",justifyContent:"space-between",gap:2},children:[v.jsx(F.Button,{disableRipple:!0,component:eo.Link,to:"/",children:r&&typeof r=="string"?v.jsx("img",{draggable:"false",src:r,style:{width:"200px",filter:"brightness(0) invert(1)"},alt:"logo"}):r}),v.jsxs(F.Box,{display:"flex",gap:2,alignItems:"center",children:[!l&&!b&&E,b&&v.jsx(_P,{menuOptionLists:[o,a,O],anchor:"right"}),!b&&v.jsxs(v.Fragment,{children:[v.jsx(F.Box,{display:"flex",gap:0,children:a==null?void 0:a.map((L,P)=>v.jsxs(F.Box,{display:"flex",alignItems:"center",children:[P>0&&v.jsx(F.Typography,{className:"quickLink-divider",color:S.primary.contrastText,children:"|"}),v.jsx(F.Button,{variant:"text",sx:{color:"white"},...vl(L,y),children:v.jsxs(F.Box,{display:"flex",gap:"3px",alignItems:"center",children:[L.icon,L.label]})})]},L.label))}),p,l&&v.jsx(EP,{displayName:l,userMenuOptions:O})]})]})]}),!b&&v.jsx(MP,{featureMenuOptions:o,activeTabIdx:_,sx:m})]})},Rne=t=>{const{sx:e,menuOptions:n=[]}=t,{pathname:r}=eo.useLocation(),o=F.useMediaQuery(F.useTheme().breakpoints.down("sm")),[i,s]=J.useState(void 0);return J.useEffect(()=>{const a=n.findIndex(l=>l.path&&r.startsWith(l.path))??-1;s(a>=0?a:void 0)},[r,n]),!o&&n.length>0&&v.jsx(F.Box,{sx:e,children:v.jsx(F.Card,{sx:{height:"100%",width:200},children:v.jsx(Dp,{orientation:"vertical",menuOptions:n,activeTabIdx:i})})})},zne=t=>{const{featureMenuOptions:e=[],activeTabIdx:n,sx:r}=t,{palette:o}=F.useTheme();return e.length>0&&v.jsx(Dp,{menuOptions:e,activeTabIdx:n,sx:{margin:"8px",backgroundColor:o.primary.dark,borderRadius:"8px","& .MuiTab-root":{color:o.secondary.light,flexDirection:"row",gap:"2px","& .MuiTab-icon":{marginBottom:"unset"},minHeight:"58px"},"& .MuiTab-root.Mui-selected":{color:o.primary.contrastText,fontSize:"120%"},"& .MuiTabs-indicator":{display:"none"},...r}})},Vne=t=>v.jsx(iu,{severity:"info",...t}),Hne=t=>v.jsx(iu,{severity:"warning",...t}),AP=t=>{const{crumbInfo:e}=t,n=eo.useNavigate();return v.jsx(F.Breadcrumbs,{"aria-label":"breadcrumb",separator:v.jsx(DR,{color:"primary"}),sx:{marginBottom:2},children:e.map(({label:r,path:o},i)=>o&&i<e.length-1?v.jsx(F.Link,{color:"primary",sx:{cursor:"pointer"},onClick:()=>n(o),children:r},r):v.jsx(F.Typography,{color:"primary",children:r},r))})},jne=t=>{const{title:e,message:n,type:r,onClose:o,autoHideDuration:i=8e3,variant:s="leftBorder",elevation:a=6}=t,l=Wne(r);return v.jsx(F.Snackbar,{"data-testid":"message-snackbar",anchorOrigin:{vertical:"bottom",horizontal:"right"},open:!0,onClose:u=>{u==null&&o()},autoHideDuration:i,children:v.jsx(iu,{"data-testid":"message-snackbar-alert",severity:l,iconMapping:{info:IP(r),warning:IP(r)},onClose:o,elevation:a,variant:s,children:n?v.jsxs(v.Fragment,{children:[v.jsx(F.AlertTitle,{"data-testid":"alertTitle",sx:{fontWeight:"bold"},children:e}),n]}):e})})},Wne=t=>t=="logout"?"info":t=="timeout"?"warning":t,IP=t=>{if(t=="timeout")return v.jsx(eR,{});if(t=="logout")return v.jsx(AR,{})},qne=t=>{const{title:e,createButtonLabel:n,showAddButton:r=!1,onAdd:o=()=>alert("Not implemented yet"),breadcrumbs:i=[],children:s,sx:a}=t,l=F.useMediaQuery(F.useTheme().breakpoints.down("sm"));return r&&o.toString()==='() => alert("Not implemented yet")'&&console.warn('PageHeader: "showAddButton" is true but "onAdd" is not defined.'),v.jsxs(F.Box,{sx:a,children:[i.length>0&&v.jsx(AP,{crumbInfo:i}),v.jsxs(F.Box,{className:"MBv2_PageHeader_Header",display:"flex",flexDirection:l?"column":"row",justifyContent:"space-between",alignItems:"center",gap:1,children:[v.jsxs(F.Box,{className:"MBv2_PageHeader_TitleAndCreateBtn",display:"flex",flexDirection:"row",justifyContent:l||!s?"space-between":"start",alignItems:"center",width:"100%",gap:1,children:[typeof e=="string"?v.jsx(F.Typography,{className:"MBv2_PageHeader_Title",variant:"h2",children:e}):e,r&&v.jsxs(No,{className:"MBv2_PageHeader_CreateBtn",onClick:()=>o(),children:[v.jsx(tR,{style:{marginRight:"0.5rem"}}),n]})]}),s&&v.jsx(F.Box,{width:l?"100%":"50%",children:s})]})]})},Une=t=>{const{title:e,titleIcon:n,fullWidthIcon:r=!1,children:o,actionLabel:i,action:s,sx:a}=t,l=F.useMediaQuery(F.useTheme().breakpoints.down("sm"));return v.jsxs(F.Card,{sx:a||{padding:"30px 40px",display:"flex",flexDirection:"column",gap:"1rem"},children:[n&&v.jsx(F.Box,{className:"MBv2_SingleActionCard_Img",sx:[r?{display:"flex",flexDirection:"row",justifyContent:"center",alignItems:"center",gap:"20px",marginBottom:"10px"}:{display:"inline"}],children:n}),v.jsx(F.Typography,{variant:"h1",display:"inline",fontSize:"calc(20px + .9vw)",className:"MBv2_SingleActionCard_Title",children:e}),o,v.jsx(F.Button,{variant:"contained",color:"primary",onClick:s,fullWidth:l,className:"MBv2_SingleActionCard_ActionButton",children:i})]})};function Kne({...t}){return v.jsx(k1,{renderAsSelectablePopup:!0,...t})}function Yne({...t}){return v.jsx(k1,{onSelectCitations:()=>{},onCancel:()=>{},renderAsSelectablePopup:!1,...t})}const Gne=({children:t,getCitations:e})=>{const[n,r]=J.useState([]),[o,i]=J.useState(!1);J.useEffect(()=>{(async()=>e().then(f=>{r(p=>{const g=new Set(p.map(y=>y.id));return[...p.filter(y=>!g.has(y.id)),...f]}),i(!0)}).catch(f=>{console.error(`Error fetching citations: ${f==null?void 0:f.toString()}`)}))()},[]);const s=J.useCallback(u=>{r(f=>{const p=f.map(y=>{const b=u.find(S=>S.id===y.id);return b||y}),g=new Set(f.map(y=>y.id)),m=u.filter(y=>!g.has(y.id));return[...p,...m]})},[]),a=J.useCallback(u=>{const f=n.findIndex(p=>p.id===u.id);r(f!==-1?p=>{const g=[...p];return g[f]=u,g}:[...n,u])},[n]),l=J.useCallback(u=>r(n.filter(f=>f.id!==u)),[n]);return v.jsx(CP.Provider,{value:{citations:n,isLoaded:o,addUpdateCitation:a,deleteCitation:l,batchUpdate:s},children:t})};Pe.AlertModal=Lne,Pe.Autocomplete=fC,Pe.Breadcrumbs=AP,Pe.Button=No,Pe.Checkbox=DB,Pe.CheckboxGroup=PB,Pe.CitationField=Ene,Pe.CitationFieldProvider=Gne,Pe.CitationManager=Yne,Pe.ConfirmationModal=Nne,Pe.DarkModeToggle=OP,Pe.DateField=Fd,Pe.DateRangeField=nq,Pe.DecisionModal=Fne,Pe.Drawer=_P,Pe.DynamicAutocomplete=AB,Pe.EnvironmentBanner=TP,Pe.Error=Xn,Pe.ErrorAlert=vP,Pe.FileList=LB,Pe.FileUpload=gC,Pe.FloatingNavBar=zne,Pe.Footer=$ne,Pe.FormDebugger=Ane,Pe.Header=Bne,Pe.InfoAlert=Vne,Pe.LoadingButton=b1,Pe.LoadingIndicator=y1,Pe.Location=JB,Pe.MenuButton=kP,Pe.Modal=ou,Pe.MultiAutocomplete=IB,Pe.NavBar=MP,Pe.PageHeader=qne,Pe.PaginatedTable=ZD,Pe.ProfileMenu=EP,Pe.RadioGroup=FC,Pe.RangeSlider=ZB,Pe.RepeatableFormGroup=Dne,Pe.RichTextField=Ete,Pe.ScrollToTop=One,Pe.SearchField=jR,Pe.Select=XB,Pe.SelectableCitationManager=Kne,Pe.Sidebar=Rne,Pe.SingleActionCard=Une,Pe.Snackbar=jne,Pe.Stepper=Ine,Pe.Submit=Mne,Pe.SuccessAlert=xP,Pe.Switch=QB,Pe.Table=JD,Pe.Tabs=Dp,Pe.TextField=da,Pe.WarningAlert=Hne,Pe.commonTheme=vn,Pe.darkTheme=PF,Pe.lightTheme=DF,Object.defineProperty(Pe,Symbol.toStringTag,{value:"Module"})});
|