slick-table 1.1.4 → 1.1.5
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/dist/index.cjs.js +13 -13
- package/dist/index.es.js +576 -572
- package/dist/types/features/header-context-menu/lib/visibility/hideColumns.d.ts.map +1 -1
- package/dist/types/index.d.ts +1 -1
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/shared/lib/slickgrid/index.d.ts +1 -1
- package/dist/types/shared/lib/slickgrid/index.d.ts.map +1 -1
- package/dist/types/shared/lib/slickgrid/model/SlickTable/index.d.ts +1 -0
- package/dist/types/shared/lib/slickgrid/model/SlickTable/index.d.ts.map +1 -1
- package/dist/types/shared/lib/slickgrid/model/SlickTable/table/SlickTable.d.ts +2 -1
- package/dist/types/shared/lib/slickgrid/model/SlickTable/table/SlickTable.d.ts.map +1 -1
- package/dist/types/shared/lib/slickgrid/model/index.d.ts +1 -1
- package/dist/types/shared/lib/slickgrid/model/index.d.ts.map +1 -1
- package/dist/types/shared/lib/slickgrid/ui/SlickgridTable/lib/hooks/useGrid.d.ts.map +1 -1
- package/dist/types/shared/model/types/ISlickTable.d.ts +1 -1
- package/dist/types/shared/model/types/ISlickTable.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/features/header-context-menu/lib/visibility/hideColumns.ts +2 -1
- package/src/features/header-context-menu/ui/ButtonCheckAll/ButtonCheckAll.tsx +1 -1
- package/src/features/header-context-menu/ui/HeaderContextMenu.tsx +2 -2
- package/src/index.ts +1 -0
- package/src/shared/lib/slickgrid/index.ts +1 -0
- package/src/shared/lib/slickgrid/model/SlickTable/filters/decorators/ColumnFilter/DecoratorColumnFilter.ts +1 -1
- package/src/shared/lib/slickgrid/model/SlickTable/index.ts +1 -0
- package/src/shared/lib/slickgrid/model/SlickTable/table/SlickTable.ts +4 -2
- package/src/shared/lib/slickgrid/model/index.ts +1 -0
- package/src/shared/lib/slickgrid/ui/SlickgridTable/lib/hooks/useGrid.ts +6 -1
- package/src/shared/model/types/ISlickTable.ts +1 -1
package/dist/index.cjs.js
CHANGED
|
@@ -261,17 +261,17 @@ To suppress this warning, you need to explicitly provide the \`palette.${t}Chann
|
|
|
261
261
|
transparent,
|
|
262
262
|
${(e.vars||e).palette.action.hover},
|
|
263
263
|
transparent
|
|
264
|
-
)`,content:'""',position:"absolute",transform:"translateX(-100%)",bottom:0,left:0,right:0,top:0}}},{props:{animation:"wave"},style:W1||{"&::after":{animation:`${zd} 2s linear 0.5s infinite`}}}]}})),Sy=k.forwardRef(function(t,n){const o=Ke({props:t,name:"MuiSkeleton"}),{animation:r="pulse",className:i,component:a="span",height:l,style:d,variant:u="text",width:f,...p}=o,y={...o,animation:r,component:a,variant:u,hasChildren:!!p.children},b=j1(y);return D.jsx(H1,{as:a,ref:n,className:Se(b.root,i),ownerState:y,...p,style:{width:f,height:l,...d}})});process.env.NODE_ENV!=="production"&&(Sy.propTypes={animation:s.oneOf(["pulse","wave",!1]),children:s.node,classes:s.object,className:s.string,component:s.elementType,height:s.oneOfType([s.number,s.string]),style:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),variant:s.oneOfType([s.oneOf(["circular","rectangular","rounded","text"]),s.string]),width:s.oneOfType([s.number,s.string])});function z1(e){return Oe("MuiTextField",e)}De("MuiTextField",["root"]);const Y1={standard:zi,filled:Wi,outlined:Os},U1=e=>{const{classes:t}=e;return Me({root:["root"]},z1,t)},q1=ae(ca,{name:"MuiTextField",slot:"Root",overridesResolver:(e,t)=>t.root})({}),Ms=k.forwardRef(function(t,n){const o=Ke({props:t,name:"MuiTextField"}),{autoComplete:r,autoFocus:i=!1,children:a,className:l,color:d="primary",defaultValue:u,disabled:f=!1,error:p=!1,FormHelperTextProps:y,fullWidth:b=!1,helperText:w,id:g,InputLabelProps:v,inputProps:E,InputProps:P,inputRef:x,label:S,maxRows:C,minRows:O,multiline:N=!1,name:F,onBlur:z,onChange:R,onFocus:$,placeholder:K,required:X=!1,rows:q,select:Y=!1,SelectProps:H,slots:le={},slotProps:A={},type:M,value:V,variant:B="outlined",...ne}=o,oe={...o,autoFocus:i,color:d,disabled:f,error:p,fullWidth:b,multiline:N,required:X,select:Y,variant:B},se=U1(oe);process.env.NODE_ENV!=="production"&&Y&&!a&&console.error("MUI: `children` must be passed when using the `TextField` component with `select`.");const j=yr(g),J=w&&j?`${j}-helper-text`:void 0,ee=S&&j?`${j}-label`:void 0,te=Y1[B],ce={slots:le,slotProps:{input:P,inputLabel:v,htmlInput:E,formHelperText:y,select:H,...A}},ie={},he=ce.slotProps.inputLabel;B==="outlined"&&(he&&typeof he.shrink<"u"&&(ie.notched=he.shrink),ie.label=S),Y&&((!H||!H.native)&&(ie.id=void 0),ie["aria-describedby"]=void 0);const[W,re]=Rn("input",{elementType:te,externalForwardedProps:ce,additionalProps:ie,ownerState:oe}),[Q,fe]=Rn("inputLabel",{elementType:da,externalForwardedProps:ce,ownerState:oe}),[me,Ce]=Rn("htmlInput",{elementType:"input",externalForwardedProps:ce,ownerState:oe}),[ve,xe]=Rn("formHelperText",{elementType:Iu,externalForwardedProps:ce,ownerState:oe}),[Ve,Ae]=Rn("select",{elementType:ua,externalForwardedProps:ce,ownerState:oe}),st=D.jsx(W,{"aria-describedby":J,autoComplete:r,autoFocus:i,defaultValue:u,fullWidth:b,multiline:N,name:F,rows:q,maxRows:C,minRows:O,type:M,value:V,id:j,inputRef:x,onBlur:z,onChange:R,onFocus:$,placeholder:K,inputProps:Ce,slots:{input:le.htmlInput?me:void 0},...re});return D.jsxs(q1,{className:Se(se.root,l),disabled:f,error:p,fullWidth:b,ref:n,required:X,color:d,variant:B,ownerState:oe,...ne,children:[S!=null&&S!==""&&D.jsx(Q,{htmlFor:j,id:ee,...fe,children:S}),Y?D.jsx(Ve,{"aria-describedby":J,id:j,labelId:ee,value:V,input:st,...Ae,children:a}):st,w&&D.jsx(ve,{id:J,...xe,children:w})]})});process.env.NODE_ENV!=="production"&&(Ms.propTypes={autoComplete:s.string,autoFocus:s.bool,children:s.node,classes:s.object,className:s.string,color:s.oneOfType([s.oneOf(["primary","secondary","error","info","success","warning"]),s.string]),defaultValue:s.any,disabled:s.bool,error:s.bool,FormHelperTextProps:s.object,fullWidth:s.bool,helperText:s.node,id:s.string,InputLabelProps:s.object,inputProps:s.object,InputProps:s.object,inputRef:Bt,label:s.node,margin:s.oneOf(["dense","none","normal"]),maxRows:s.oneOfType([s.number,s.string]),minRows:s.oneOfType([s.number,s.string]),multiline:s.bool,name:s.string,onBlur:s.func,onChange:s.func,onFocus:s.func,placeholder:s.string,required:s.bool,rows:s.oneOfType([s.number,s.string]),select:s.bool,SelectProps:s.object,size:s.oneOfType([s.oneOf(["medium","small"]),s.string]),slotProps:s.shape({formHelperText:s.oneOfType([s.func,s.object]),htmlInput:s.oneOfType([s.func,s.object]),input:s.oneOfType([s.func,s.object]),inputLabel:s.oneOfType([s.func,s.object]),select:s.oneOfType([s.func,s.object])}),slots:s.shape({formHelperText:s.elementType,htmlInput:s.elementType,input:s.elementType,inputLabel:s.elementType,select:s.elementType}),sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),type:s.string,value:s.any,variant:s.oneOf(["filled","outlined","standard"])});const G1=ae(Sy)({width:"100%",borderRadius:"10px"}),K1={Skeleton:G1},X1=({height:e="calc(100% - 1em)"})=>D.jsx(K1.Skeleton,{variant:"rectangular",height:e});var je=(e=>(e[e.Boolean=1]="Boolean",e[e.DateBetween=2]="DateBetween",e[e.DateEqual=3]="DateEqual",e[e.DateFrom=4]="DateFrom",e[e.DateTo=5]="DateTo",e[e.MultipleSelect=6]="MultipleSelect",e[e.NumberBetween=7]="NumberBetween",e[e.NumberEqual=8]="NumberEqual",e[e.NumberFrom=9]="NumberFrom",e[e.NumberTo=10]="NumberTo",e[e.TextContain=11]="TextContain",e[e.TextEqual=12]="TextEqual",e[e.TextNotContain=13]="TextNotContain",e[e.TextNotEqual=14]="TextNotEqual",e))(je||{}),sn=(e=>(e.Boolean="Boolean",e.Date="Date",e.MultipleSelect="MultipleSelect",e.Number="Number",e.NumberFormatted="NumberFormatted",e.Text="Text",e))(sn||{}),jr=(e=>(e.db="YYYY-MM-DD",e.ui="MM/DD/YY",e))(jr||{}),Or=(e=>(e.ArrowDown="ArrowDown",e.ArrowLeft="ArrowLeft",e.ArrowRight="ArrowRight",e.ArrowUp="ArrowUp",e.Control="Control",e.Enter="Enter",e.Tab="Tab",e))(Or||{}),Vs=(e=>(e[e.KeyB=66]="KeyB",e[e.KeyDel=46]="KeyDel",e[e.KeyEnter=13]="KeyEnter",e[e.KeyR=82]="KeyR",e[e.KeyY=89]="KeyY",e[e.KeyZ=90]="KeyZ",e))(Vs||{}),yo=(e=>(e[e.DATE=1]="DATE",e[e.NUMBER=2]="NUMBER",e[e.NUMBER_FORMATTED=3]="NUMBER_FORMATTED",e[e.TEXT_NUMERIC=4]="TEXT_NUMERIC",e[e.TEXT=5]="TEXT",e))(yo||{});function Vu(e,t,n){const{scrollWidth:o}=document.documentElement,{left:r,right:i}=e.getBoundingClientRect(),a=i-r,l=t+i>=o;e.style.left=`${l?t-a:t}px`,e.style.top=`${n}px`,e.style.visibility="visible"}const Z1=ae(Do)({position:"fixed",top:"0",left:"0",right:"0",bottom:"0",zIndex:"2"}),Q1={Wrapper:Z1},ju=({setIsOpened:e})=>D.jsx(Q1.Wrapper,{onClick:()=>e(!1),onContextMenu:t=>{t.preventDefault(),e(!1)},"data-testid":"overlay"}),J1=ae(Do)({visibility:"hidden",borderRadius:"5px",backgroundColor:"#FFFFFF",boxShadow:"1px 1px 1px 1px gray",padding:"0.5em",position:"absolute",zIndex:10,userSelect:"none",fontSize:"inherit",top:0,left:0}),eD={Wrapper:J1},Bu=({children:e,id:t})=>D.jsx(eD.Wrapper,{id:t,children:e});function _y(e,t=300){let n;return function(...o){const r=()=>e.apply(this,o);clearTimeout(n),n=setTimeout(r,t)}}const Kp=e=>t=>{t.keyCode===Vs.KeyEnter&&(t.stopImmediatePropagation(),e.navigateNext())},tD=e=>(t,n)=>{const{grid:o,item:r}=n;r.isEdited=!0,o.invalidate(),e.isEdited=!0,e.hotKeysBehavior.pushToCommandQueue(o)},nD=e=>(t,n)=>{e.invalidateRows(n.rows),e.render()},oD=e=>()=>{const t=e.grid;t&&(t.updateRowCount(),t.render())},id=e=>e!==e?"":String(e??"").replace(/(^")|("$)/g,"");function xy(e){const t=document.createElement("div");return t.innerHTML=e,t.textContent||t.innerText||""}const
|
|
265
|
-
`}}class
|
|
264
|
+
)`,content:'""',position:"absolute",transform:"translateX(-100%)",bottom:0,left:0,right:0,top:0}}},{props:{animation:"wave"},style:W1||{"&::after":{animation:`${zd} 2s linear 0.5s infinite`}}}]}})),Sy=k.forwardRef(function(t,n){const o=Ke({props:t,name:"MuiSkeleton"}),{animation:r="pulse",className:i,component:a="span",height:l,style:d,variant:u="text",width:f,...p}=o,y={...o,animation:r,component:a,variant:u,hasChildren:!!p.children},b=j1(y);return D.jsx(H1,{as:a,ref:n,className:Se(b.root,i),ownerState:y,...p,style:{width:f,height:l,...d}})});process.env.NODE_ENV!=="production"&&(Sy.propTypes={animation:s.oneOf(["pulse","wave",!1]),children:s.node,classes:s.object,className:s.string,component:s.elementType,height:s.oneOfType([s.number,s.string]),style:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),variant:s.oneOfType([s.oneOf(["circular","rectangular","rounded","text"]),s.string]),width:s.oneOfType([s.number,s.string])});function z1(e){return Oe("MuiTextField",e)}De("MuiTextField",["root"]);const Y1={standard:zi,filled:Wi,outlined:Os},U1=e=>{const{classes:t}=e;return Me({root:["root"]},z1,t)},q1=ae(ca,{name:"MuiTextField",slot:"Root",overridesResolver:(e,t)=>t.root})({}),Ms=k.forwardRef(function(t,n){const o=Ke({props:t,name:"MuiTextField"}),{autoComplete:r,autoFocus:i=!1,children:a,className:l,color:d="primary",defaultValue:u,disabled:f=!1,error:p=!1,FormHelperTextProps:y,fullWidth:b=!1,helperText:w,id:g,InputLabelProps:v,inputProps:E,InputProps:P,inputRef:x,label:S,maxRows:C,minRows:O,multiline:N=!1,name:F,onBlur:z,onChange:R,onFocus:$,placeholder:K,required:X=!1,rows:q,select:Y=!1,SelectProps:H,slots:le={},slotProps:A={},type:M,value:V,variant:B="outlined",...ne}=o,oe={...o,autoFocus:i,color:d,disabled:f,error:p,fullWidth:b,multiline:N,required:X,select:Y,variant:B},se=U1(oe);process.env.NODE_ENV!=="production"&&Y&&!a&&console.error("MUI: `children` must be passed when using the `TextField` component with `select`.");const j=yr(g),J=w&&j?`${j}-helper-text`:void 0,ee=S&&j?`${j}-label`:void 0,te=Y1[B],ce={slots:le,slotProps:{input:P,inputLabel:v,htmlInput:E,formHelperText:y,select:H,...A}},ie={},he=ce.slotProps.inputLabel;B==="outlined"&&(he&&typeof he.shrink<"u"&&(ie.notched=he.shrink),ie.label=S),Y&&((!H||!H.native)&&(ie.id=void 0),ie["aria-describedby"]=void 0);const[W,re]=Rn("input",{elementType:te,externalForwardedProps:ce,additionalProps:ie,ownerState:oe}),[Q,fe]=Rn("inputLabel",{elementType:da,externalForwardedProps:ce,ownerState:oe}),[me,Ce]=Rn("htmlInput",{elementType:"input",externalForwardedProps:ce,ownerState:oe}),[ve,xe]=Rn("formHelperText",{elementType:Iu,externalForwardedProps:ce,ownerState:oe}),[Ve,Ae]=Rn("select",{elementType:ua,externalForwardedProps:ce,ownerState:oe}),st=D.jsx(W,{"aria-describedby":J,autoComplete:r,autoFocus:i,defaultValue:u,fullWidth:b,multiline:N,name:F,rows:q,maxRows:C,minRows:O,type:M,value:V,id:j,inputRef:x,onBlur:z,onChange:R,onFocus:$,placeholder:K,inputProps:Ce,slots:{input:le.htmlInput?me:void 0},...re});return D.jsxs(q1,{className:Se(se.root,l),disabled:f,error:p,fullWidth:b,ref:n,required:X,color:d,variant:B,ownerState:oe,...ne,children:[S!=null&&S!==""&&D.jsx(Q,{htmlFor:j,id:ee,...fe,children:S}),Y?D.jsx(Ve,{"aria-describedby":J,id:j,labelId:ee,value:V,input:st,...Ae,children:a}):st,w&&D.jsx(ve,{id:J,...xe,children:w})]})});process.env.NODE_ENV!=="production"&&(Ms.propTypes={autoComplete:s.string,autoFocus:s.bool,children:s.node,classes:s.object,className:s.string,color:s.oneOfType([s.oneOf(["primary","secondary","error","info","success","warning"]),s.string]),defaultValue:s.any,disabled:s.bool,error:s.bool,FormHelperTextProps:s.object,fullWidth:s.bool,helperText:s.node,id:s.string,InputLabelProps:s.object,inputProps:s.object,InputProps:s.object,inputRef:Bt,label:s.node,margin:s.oneOf(["dense","none","normal"]),maxRows:s.oneOfType([s.number,s.string]),minRows:s.oneOfType([s.number,s.string]),multiline:s.bool,name:s.string,onBlur:s.func,onChange:s.func,onFocus:s.func,placeholder:s.string,required:s.bool,rows:s.oneOfType([s.number,s.string]),select:s.bool,SelectProps:s.object,size:s.oneOfType([s.oneOf(["medium","small"]),s.string]),slotProps:s.shape({formHelperText:s.oneOfType([s.func,s.object]),htmlInput:s.oneOfType([s.func,s.object]),input:s.oneOfType([s.func,s.object]),inputLabel:s.oneOfType([s.func,s.object]),select:s.oneOfType([s.func,s.object])}),slots:s.shape({formHelperText:s.elementType,htmlInput:s.elementType,input:s.elementType,inputLabel:s.elementType,select:s.elementType}),sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),type:s.string,value:s.any,variant:s.oneOf(["filled","outlined","standard"])});const G1=ae(Sy)({width:"100%",borderRadius:"10px"}),K1={Skeleton:G1},X1=({height:e="calc(100% - 1em)"})=>D.jsx(K1.Skeleton,{variant:"rectangular",height:e});var je=(e=>(e[e.Boolean=1]="Boolean",e[e.DateBetween=2]="DateBetween",e[e.DateEqual=3]="DateEqual",e[e.DateFrom=4]="DateFrom",e[e.DateTo=5]="DateTo",e[e.MultipleSelect=6]="MultipleSelect",e[e.NumberBetween=7]="NumberBetween",e[e.NumberEqual=8]="NumberEqual",e[e.NumberFrom=9]="NumberFrom",e[e.NumberTo=10]="NumberTo",e[e.TextContain=11]="TextContain",e[e.TextEqual=12]="TextEqual",e[e.TextNotContain=13]="TextNotContain",e[e.TextNotEqual=14]="TextNotEqual",e))(je||{}),sn=(e=>(e.Boolean="Boolean",e.Date="Date",e.MultipleSelect="MultipleSelect",e.Number="Number",e.NumberFormatted="NumberFormatted",e.Text="Text",e))(sn||{}),jr=(e=>(e.db="YYYY-MM-DD",e.ui="MM/DD/YY",e))(jr||{}),Or=(e=>(e.ArrowDown="ArrowDown",e.ArrowLeft="ArrowLeft",e.ArrowRight="ArrowRight",e.ArrowUp="ArrowUp",e.Control="Control",e.Enter="Enter",e.Tab="Tab",e))(Or||{}),Vs=(e=>(e[e.KeyB=66]="KeyB",e[e.KeyDel=46]="KeyDel",e[e.KeyEnter=13]="KeyEnter",e[e.KeyR=82]="KeyR",e[e.KeyY=89]="KeyY",e[e.KeyZ=90]="KeyZ",e))(Vs||{}),yo=(e=>(e[e.DATE=1]="DATE",e[e.NUMBER=2]="NUMBER",e[e.NUMBER_FORMATTED=3]="NUMBER_FORMATTED",e[e.TEXT_NUMERIC=4]="TEXT_NUMERIC",e[e.TEXT=5]="TEXT",e))(yo||{});function Vu(e,t,n){const{scrollWidth:o}=document.documentElement,{left:r,right:i}=e.getBoundingClientRect(),a=i-r,l=t+i>=o;e.style.left=`${l?t-a:t}px`,e.style.top=`${n}px`,e.style.visibility="visible"}const Z1=ae(Do)({position:"fixed",top:"0",left:"0",right:"0",bottom:"0",zIndex:"2"}),Q1={Wrapper:Z1},ju=({setIsOpened:e})=>D.jsx(Q1.Wrapper,{onClick:()=>e(!1),onContextMenu:t=>{t.preventDefault(),e(!1)},"data-testid":"overlay"}),J1=ae(Do)({visibility:"hidden",borderRadius:"5px",backgroundColor:"#FFFFFF",boxShadow:"1px 1px 1px 1px gray",padding:"0.5em",position:"absolute",zIndex:10,userSelect:"none",fontSize:"inherit",top:0,left:0}),eD={Wrapper:J1},Bu=({children:e,id:t})=>D.jsx(eD.Wrapper,{id:t,children:e});function _y(e,t=300){let n;return function(...o){const r=()=>e.apply(this,o);clearTimeout(n),n=setTimeout(r,t)}}const Kp=e=>t=>{t.keyCode===Vs.KeyEnter&&(t.stopImmediatePropagation(),e.navigateNext())},tD=e=>(t,n)=>{const{grid:o,item:r}=n;r.isEdited=!0,o.invalidate(),e.isEdited=!0,e.hotKeysBehavior.pushToCommandQueue(o)},nD=e=>(t,n)=>{e.invalidateRows(n.rows),e.render()},oD=e=>()=>{const t=e.grid;t&&(t.updateRowCount(),t.render())};class rD{constructor(){this._initialColumns=[],this._visibleColumnIds=[]}get visibleColumnIds(){return this._visibleColumnIds}set visibleColumnIds(t){this._visibleColumnIds=t}get initialColumns(){return this._initialColumns}set initialColumns(t){this.visibleColumnIds.length||(this.visibleColumnIds=t.map(({id:n})=>n)),this._initialColumns=t}}const id=e=>e!==e?"":String(e??"").replace(/(^")|("$)/g,"");function xy(e){const t=document.createElement("div");return t.innerHTML=e,t.textContent||t.innerText||""}const sD=["FormatterStatus","FormatterNumber"];class iD{constructor(){this.table=null}download(t,n,o){if(this.table||(this.table=t),this.table=t,!t.grid)return;const i=this.createCSV(t),a=document.createElement("a");a.href="data:text/csv;charset=utf-8,"+encodeURIComponent(i),a.target="_blank",a.download=`${n}-${o}-${t.id}.csv`,a.click()}createCSV(t){this.table||(this.table=t);const n=t.grid;if(!n)return"";const o=this.getTitle(),r=this.getCSVHeader(n),i=this.getCSVBody(n);return`${o}${r}${i}`}getTitle(){return""}getCSVHeader(t){const r=t.getColumns().filter(i=>i.forPrint).reduce((i,a)=>{if(typeof a.name=="string"){const l=id(a.name);return i.concat(`"${l}",`)}else return i.concat('" ",')},"");return this.addRowSeparator(r)}getCSVBody(t){const n=t.getData(),r=t.getColumns().filter(i=>i.forPrint);return JA(t).reduce((i,a)=>{const l=n.getItemMetadata(a),d=n.getItem(a),u=d.__group,f=d.__groupTotals;let p="";if(u){const y=id(xy(d.title));p+=`"${y}",`}else for(let y=0;y<r.length;++y){const b=r[y],w=b.field,g=l?.columns?.[w]?.formatter,v=b.printer||g||b.formatter;let E=d[w];if(f){const x=b.groupTotalsFormatter;E=x?x(d,b,t):""}else v&&!sD.includes(v.name)&&(E=v(0,0,E,b,d,t));const P=id(E);p+=`"${P}",`}return this.addRowSeparator(`${i}${p}`)},"")}addRowSeparator(t){return`${t}
|
|
265
|
+
`}}class aD{constructor(){this.externalVariables={},this.commandQueue=[],this.queueIndex=-1}getQueueIndex(){return this.queueIndex}setQueueIndex(t){this.queueIndex=t}handleKeyboardEvent(t,n){const o=n.grid;if(!n.isActive||!o)return;const r=o.getData();if(kv(t)){if(t.preventDefault(),t.stopImmediatePropagation(),IA(o)||this.externalVariables.editingAllowed===!1)return;Pv(o),o.invalidate(),this.pushToCommandQueue(o),n.isEdited=!0}else if(MA(t)){t.preventDefault(),t.stopImmediatePropagation();const i=o.getSelectedRows();if(!i.length)return;i.forEach(a=>{const l=r.getItem(a);l.isDeleted=!0}),o.setSelectedRows([]),r.refresh(),o.invalidate(),this.pushToCommandQueue(o),n.isEdited=!0}else if(Ev(t)){t.preventDefault(),t.stopImmediatePropagation();const i=this.getQueueIndex();if(i<1)return;const a=i-1;this.setQueueIndex(a),r.setItems(ad(this.commandQueue[a])),o.invalidate(),n.isEdited=a!==0}else if(Tv(t)){t.preventDefault(),t.stopImmediatePropagation();const i=this.getQueueIndex();if(i===this.commandQueue.length-1)return;const a=i+1;this.setQueueIndex(a),r.setItems(ad(this.commandQueue[a])),o.invalidate(),n.isEdited=!0}}pushToCommandQueue(t){if(!t)return;const o=t.getData().getItems(),i=this.getQueueIndex()+1;this.commandQueue.length=i,this.commandQueue.push(ad(o)),this.setQueueIndex(i)}resetQueue(){this.commandQueue.length=0,this.queueIndex=-1}setExternalVariables(t){this.externalVariables={...this.externalVariables,...t}}getExternalVariables(){return this.externalVariables}}function ad(e){return e.map(t=>({...t}))}class lD{handleKeyboardEvent(){}pushToCommandQueue(){}resetQueue(){}setExternalVariables(t){}getExternalVariables(){return{}}}class Wu{constructor(t){this.hotKeysBehaviour=t}handleKeyboardEvent(t,n){this.hotKeysBehaviour.handleKeyboardEvent(t,n)}pushToCommandQueue(t){this.hotKeysBehaviour.pushToCommandQueue(t)}resetQueue(){this.hotKeysBehaviour.resetQueue()}setExternalVariables(t){this.hotKeysBehaviour.setExternalVariables(t)}getExternalVariables(){return this.hotKeysBehaviour.getExternalVariables()}}class cD extends Wu{handleKeyboardEvent(t,n){n.isActive&&(kv(t)||super.handleKeyboardEvent.call(this,t,n))}}class dD extends Wu{handleKeyboardEvent(t,n){n.isActive&&(Tv(t)||Ev(t))&&super.handleKeyboardEvent.call(this,t,n)}}const Yd="checkboxSelector";//! moment.js
|
|
266
266
|
//! version : 2.30.1
|
|
267
267
|
//! authors : Tim Wood, Iskren Chernev, Moment.js contributors
|
|
268
268
|
//! license : MIT
|
|
269
269
|
//! momentjs.com
|
|
270
|
-
var Ry;function _e(){return Ry.apply(null,arguments)}function
|
|
270
|
+
var Ry;function _e(){return Ry.apply(null,arguments)}function uD(e){Ry=e}function io(e){return e instanceof Array||Object.prototype.toString.call(e)==="[object Array]"}function Fr(e){return e!=null&&Object.prototype.toString.call(e)==="[object Object]"}function ut(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function Hu(e){if(Object.getOwnPropertyNames)return Object.getOwnPropertyNames(e).length===0;var t;for(t in e)if(ut(e,t))return!1;return!0}function xn(e){return e===void 0}function Jo(e){return typeof e=="number"||Object.prototype.toString.call(e)==="[object Number]"}function ha(e){return e instanceof Date||Object.prototype.toString.call(e)==="[object Date]"}function ky(e,t){var n=[],o,r=e.length;for(o=0;o<r;++o)n.push(t(e[o],o));return n}function dr(e,t){for(var n in t)ut(t,n)&&(e[n]=t[n]);return ut(t,"toString")&&(e.toString=t.toString),ut(t,"valueOf")&&(e.valueOf=t.valueOf),e}function Oo(e,t,n,o){return Ky(e,t,n,o,!0).utc()}function hD(){return{empty:!1,unusedTokens:[],unusedInput:[],overflow:-2,charsLeftOver:0,nullInput:!1,invalidEra:null,invalidMonth:null,invalidFormat:!1,userInvalidated:!1,iso:!1,parsedDateParts:[],era:null,meridiem:null,rfc2822:!1,weekdayMismatch:!1}}function ze(e){return e._pf==null&&(e._pf=hD()),e._pf}var Ud;Array.prototype.some?Ud=Array.prototype.some:Ud=function(e){var t=Object(this),n=t.length>>>0,o;for(o=0;o<n;o++)if(o in t&&e.call(this,t[o],o,t))return!0;return!1};function zu(e){var t=null,n=!1,o=e._d&&!isNaN(e._d.getTime());if(o&&(t=ze(e),n=Ud.call(t.parsedDateParts,function(r){return r!=null}),o=t.overflow<0&&!t.empty&&!t.invalidEra&&!t.invalidMonth&&!t.invalidWeekday&&!t.weekdayMismatch&&!t.nullInput&&!t.invalidFormat&&!t.userInvalidated&&(!t.meridiem||t.meridiem&&n),e._strict&&(o=o&&t.charsLeftOver===0&&t.unusedTokens.length===0&&t.bigHour===void 0)),Object.isFrozen==null||!Object.isFrozen(e))e._isValid=o;else return o;return e._isValid}function nc(e){var t=Oo(NaN);return e!=null?dr(ze(t),e):ze(t).userInvalidated=!0,t}var Xp=_e.momentProperties=[],ld=!1;function Yu(e,t){var n,o,r,i=Xp.length;if(xn(t._isAMomentObject)||(e._isAMomentObject=t._isAMomentObject),xn(t._i)||(e._i=t._i),xn(t._f)||(e._f=t._f),xn(t._l)||(e._l=t._l),xn(t._strict)||(e._strict=t._strict),xn(t._tzm)||(e._tzm=t._tzm),xn(t._isUTC)||(e._isUTC=t._isUTC),xn(t._offset)||(e._offset=t._offset),xn(t._pf)||(e._pf=ze(t)),xn(t._locale)||(e._locale=t._locale),i>0)for(n=0;n<i;n++)o=Xp[n],r=t[o],xn(r)||(e[o]=r);return e}function fa(e){Yu(this,e),this._d=new Date(e._d!=null?e._d.getTime():NaN),this.isValid()||(this._d=new Date(NaN)),ld===!1&&(ld=!0,_e.updateOffset(this),ld=!1)}function ao(e){return e instanceof fa||e!=null&&e._isAMomentObject!=null}function Ty(e){_e.suppressDeprecationWarnings===!1&&typeof console<"u"&&console.warn&&console.warn("Deprecation warning: "+e)}function Jn(e,t){var n=!0;return dr(function(){if(_e.deprecationHandler!=null&&_e.deprecationHandler(null,e),n){var o=[],r,i,a,l=arguments.length;for(i=0;i<l;i++){if(r="",typeof arguments[i]=="object"){r+=`
|
|
271
271
|
[`+i+"] ";for(a in arguments[0])ut(arguments[0],a)&&(r+=a+": "+arguments[0][a]+", ");r=r.slice(0,-2)}else r=arguments[i];o.push(r)}Ty(e+`
|
|
272
272
|
Arguments: `+Array.prototype.slice.call(o).join("")+`
|
|
273
|
-
`+new Error().stack),n=!1}return t.apply(this,arguments)},t)}var Zp={};function Ey(e,t){_e.deprecationHandler!=null&&_e.deprecationHandler(e,t),Zp[e]||(Ty(t),Zp[e]=!0)}_e.suppressDeprecationWarnings=!1;_e.deprecationHandler=null;function Mo(e){return typeof Function<"u"&&e instanceof Function||Object.prototype.toString.call(e)==="[object Function]"}function hD(e){var t,n;for(n in e)ut(e,n)&&(t=e[n],Mo(t)?this[n]=t:this["_"+n]=t);this._config=e,this._dayOfMonthOrdinalParseLenient=new RegExp((this._dayOfMonthOrdinalParse.source||this._ordinalParse.source)+"|"+/\d{1,2}/.source)}function qd(e,t){var n=dr({},e),o;for(o in t)ut(t,o)&&(Fr(e[o])&&Fr(t[o])?(n[o]={},dr(n[o],e[o]),dr(n[o],t[o])):t[o]!=null?n[o]=t[o]:delete n[o]);for(o in e)ut(e,o)&&!ut(t,o)&&Fr(e[o])&&(n[o]=dr({},n[o]));return n}function Uu(e){e!=null&&this.set(e)}var Gd;Object.keys?Gd=Object.keys:Gd=function(e){var t,n=[];for(t in e)ut(e,t)&&n.push(t);return n};var fD={sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"};function pD(e,t,n){var o=this._calendar[e]||this._calendar.sameElse;return Mo(o)?o.call(t,n):o}function Eo(e,t,n){var o=""+Math.abs(e),r=t-o.length,i=e>=0;return(i?n?"+":"":"-")+Math.pow(10,Math.max(0,r)).toString().substr(1)+o}var qu=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,Ha=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,cd={},bs={};function Le(e,t,n,o){var r=o;typeof o=="string"&&(r=function(){return this[o]()}),e&&(bs[e]=r),t&&(bs[t[0]]=function(){return Eo(r.apply(this,arguments),t[1],t[2])}),n&&(bs[n]=function(){return this.localeData().ordinal(r.apply(this,arguments),e)})}function mD(e){return e.match(/\[[\s\S]/)?e.replace(/^\[|\]$/g,""):e.replace(/\\/g,"")}function gD(e){var t=e.match(qu),n,o;for(n=0,o=t.length;n<o;n++)bs[t[n]]?t[n]=bs[t[n]]:t[n]=mD(t[n]);return function(r){var i="",a;for(a=0;a<o;a++)i+=Mo(t[a])?t[a].call(r,e):t[a];return i}}function rl(e,t){return e.isValid()?(t=Py(t,e.localeData()),cd[t]=cd[t]||gD(t),cd[t](e)):e.localeData().invalidDate()}function Py(e,t){var n=5;function o(r){return t.longDateFormat(r)||r}for(Ha.lastIndex=0;n>=0&&Ha.test(e);)e=e.replace(Ha,o),Ha.lastIndex=0,n-=1;return e}var yD={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"};function vD(e){var t=this._longDateFormat[e],n=this._longDateFormat[e.toUpperCase()];return t||!n?t:(this._longDateFormat[e]=n.match(qu).map(function(o){return o==="MMMM"||o==="MM"||o==="DD"||o==="dddd"?o.slice(1):o}).join(""),this._longDateFormat[e])}var bD="Invalid date";function wD(){return this._invalidDate}var CD="%d",SD=/\d{1,2}/;function _D(e){return this._ordinal.replace("%d",e)}var xD={future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",w:"a week",ww:"%d weeks",M:"a month",MM:"%d months",y:"a year",yy:"%d years"};function RD(e,t,n,o){var r=this._relativeTime[n];return Mo(r)?r(e,t,n,o):r.replace(/%d/i,e)}function kD(e,t){var n=this._relativeTime[e>0?"future":"past"];return Mo(n)?n(t):n.replace(/%s/i,t)}var Qp={D:"date",dates:"date",date:"date",d:"day",days:"day",day:"day",e:"weekday",weekdays:"weekday",weekday:"weekday",E:"isoWeekday",isoweekdays:"isoWeekday",isoweekday:"isoWeekday",DDD:"dayOfYear",dayofyears:"dayOfYear",dayofyear:"dayOfYear",h:"hour",hours:"hour",hour:"hour",ms:"millisecond",milliseconds:"millisecond",millisecond:"millisecond",m:"minute",minutes:"minute",minute:"minute",M:"month",months:"month",month:"month",Q:"quarter",quarters:"quarter",quarter:"quarter",s:"second",seconds:"second",second:"second",gg:"weekYear",weekyears:"weekYear",weekyear:"weekYear",GG:"isoWeekYear",isoweekyears:"isoWeekYear",isoweekyear:"isoWeekYear",w:"week",weeks:"week",week:"week",W:"isoWeek",isoweeks:"isoWeek",isoweek:"isoWeek",y:"year",years:"year",year:"year"};function eo(e){return typeof e=="string"?Qp[e]||Qp[e.toLowerCase()]:void 0}function Gu(e){var t={},n,o;for(o in e)ut(e,o)&&(n=eo(o),n&&(t[n]=e[o]));return t}var TD={date:9,day:11,weekday:11,isoWeekday:11,dayOfYear:4,hour:13,millisecond:16,minute:14,month:8,quarter:7,second:15,weekYear:1,isoWeekYear:1,week:5,isoWeek:5,year:1};function ED(e){var t=[],n;for(n in e)ut(e,n)&&t.push({unit:n,priority:TD[n]});return t.sort(function(o,r){return o.priority-r.priority}),t}var Dy=/\d/,$n=/\d\d/,Oy=/\d{3}/,Ku=/\d{4}/,oc=/[+-]?\d{6}/,It=/\d\d?/,My=/\d\d\d\d?/,Iy=/\d\d\d\d\d\d?/,rc=/\d{1,3}/,Xu=/\d{1,4}/,sc=/[+-]?\d{1,6}/,js=/\d+/,ic=/[+-]?\d+/,PD=/Z|[+-]\d\d:?\d\d/gi,ac=/Z|[+-]\d\d(?::?\d\d)?/gi,DD=/[+-]?\d+(\.\d{1,3})?/,pa=/[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i,Bs=/^[1-9]\d?/,Zu=/^([1-9]\d|\d)/,wl;wl={};function Ee(e,t,n){wl[e]=Mo(t)?t:function(o,r){return o&&n?n:t}}function OD(e,t){return ut(wl,e)?wl[e](t._strict,t._locale):new RegExp(MD(e))}function MD(e){return qo(e.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(t,n,o,r,i){return n||o||r||i}))}function qo(e){return e.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function Un(e){return e<0?Math.ceil(e)||0:Math.floor(e)}function Qe(e){var t=+e,n=0;return t!==0&&isFinite(t)&&(n=Un(t)),n}var Kd={};function Tt(e,t){var n,o=t,r;for(typeof e=="string"&&(e=[e]),Jo(t)&&(o=function(i,a){a[t]=Qe(i)}),r=e.length,n=0;n<r;n++)Kd[e[n]]=o}function ma(e,t){Tt(e,function(n,o,r,i){r._w=r._w||{},t(n,r._w,r,i)})}function ID(e,t,n){t!=null&&ut(Kd,e)&&Kd[e](t,n._a,n,e)}function lc(e){return e%4===0&&e%100!==0||e%400===0}var yn=0,zo=1,So=2,tn=3,ro=4,Yo=5,Ir=6,ND=7,AD=8;Le("Y",0,0,function(){var e=this.year();return e<=9999?Eo(e,4):"+"+e});Le(0,["YY",2],0,function(){return this.year()%100});Le(0,["YYYY",4],0,"year");Le(0,["YYYYY",5],0,"year");Le(0,["YYYYYY",6,!0],0,"year");Ee("Y",ic);Ee("YY",It,$n);Ee("YYYY",Xu,Ku);Ee("YYYYY",sc,oc);Ee("YYYYYY",sc,oc);Tt(["YYYYY","YYYYYY"],yn);Tt("YYYY",function(e,t){t[yn]=e.length===2?_e.parseTwoDigitYear(e):Qe(e)});Tt("YY",function(e,t){t[yn]=_e.parseTwoDigitYear(e)});Tt("Y",function(e,t){t[yn]=parseInt(e,10)});function Ti(e){return lc(e)?366:365}_e.parseTwoDigitYear=function(e){return Qe(e)+(Qe(e)>68?1900:2e3)};var Ny=Ws("FullYear",!0);function FD(){return lc(this.year())}function Ws(e,t){return function(n){return n!=null?(Ay(this,e,n),_e.updateOffset(this,t),this):Yi(this,e)}}function Yi(e,t){if(!e.isValid())return NaN;var n=e._d,o=e._isUTC;switch(t){case"Milliseconds":return o?n.getUTCMilliseconds():n.getMilliseconds();case"Seconds":return o?n.getUTCSeconds():n.getSeconds();case"Minutes":return o?n.getUTCMinutes():n.getMinutes();case"Hours":return o?n.getUTCHours():n.getHours();case"Date":return o?n.getUTCDate():n.getDate();case"Day":return o?n.getUTCDay():n.getDay();case"Month":return o?n.getUTCMonth():n.getMonth();case"FullYear":return o?n.getUTCFullYear():n.getFullYear();default:return NaN}}function Ay(e,t,n){var o,r,i,a,l;if(!(!e.isValid()||isNaN(n))){switch(o=e._d,r=e._isUTC,t){case"Milliseconds":return void(r?o.setUTCMilliseconds(n):o.setMilliseconds(n));case"Seconds":return void(r?o.setUTCSeconds(n):o.setSeconds(n));case"Minutes":return void(r?o.setUTCMinutes(n):o.setMinutes(n));case"Hours":return void(r?o.setUTCHours(n):o.setHours(n));case"Date":return void(r?o.setUTCDate(n):o.setDate(n));case"FullYear":break;default:return}i=n,a=e.month(),l=e.date(),l=l===29&&a===1&&!lc(i)?28:l,r?o.setUTCFullYear(i,a,l):o.setFullYear(i,a,l)}}function LD(e){return e=eo(e),Mo(this[e])?this[e]():this}function $D(e,t){if(typeof e=="object"){e=Gu(e);var n=ED(e),o,r=n.length;for(o=0;o<r;o++)this[n[o].unit](e[n[o].unit])}else if(e=eo(e),Mo(this[e]))return this[e](t);return this}function VD(e,t){return(e%t+t)%t}var qt;Array.prototype.indexOf?qt=Array.prototype.indexOf:qt=function(e){var t;for(t=0;t<this.length;++t)if(this[t]===e)return t;return-1};function Qu(e,t){if(isNaN(e)||isNaN(t))return NaN;var n=VD(t,12);return e+=(t-n)/12,n===1?lc(e)?29:28:31-n%7%2}Le("M",["MM",2],"Mo",function(){return this.month()+1});Le("MMM",0,0,function(e){return this.localeData().monthsShort(this,e)});Le("MMMM",0,0,function(e){return this.localeData().months(this,e)});Ee("M",It,Bs);Ee("MM",It,$n);Ee("MMM",function(e,t){return t.monthsShortRegex(e)});Ee("MMMM",function(e,t){return t.monthsRegex(e)});Tt(["M","MM"],function(e,t){t[zo]=Qe(e)-1});Tt(["MMM","MMMM"],function(e,t,n,o){var r=n._locale.monthsParse(e,o,n._strict);r!=null?t[zo]=r:ze(n).invalidMonth=e});var jD="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),Fy="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),Ly=/D[oD]?(\[[^\[\]]*\]|\s)+MMMM?/,BD=pa,WD=pa;function HD(e,t){return e?io(this._months)?this._months[e.month()]:this._months[(this._months.isFormat||Ly).test(t)?"format":"standalone"][e.month()]:io(this._months)?this._months:this._months.standalone}function zD(e,t){return e?io(this._monthsShort)?this._monthsShort[e.month()]:this._monthsShort[Ly.test(t)?"format":"standalone"][e.month()]:io(this._monthsShort)?this._monthsShort:this._monthsShort.standalone}function YD(e,t,n){var o,r,i,a=e.toLocaleLowerCase();if(!this._monthsParse)for(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[],o=0;o<12;++o)i=Oo([2e3,o]),this._shortMonthsParse[o]=this.monthsShort(i,"").toLocaleLowerCase(),this._longMonthsParse[o]=this.months(i,"").toLocaleLowerCase();return n?t==="MMM"?(r=qt.call(this._shortMonthsParse,a),r!==-1?r:null):(r=qt.call(this._longMonthsParse,a),r!==-1?r:null):t==="MMM"?(r=qt.call(this._shortMonthsParse,a),r!==-1?r:(r=qt.call(this._longMonthsParse,a),r!==-1?r:null)):(r=qt.call(this._longMonthsParse,a),r!==-1?r:(r=qt.call(this._shortMonthsParse,a),r!==-1?r:null))}function UD(e,t,n){var o,r,i;if(this._monthsParseExact)return YD.call(this,e,t,n);for(this._monthsParse||(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[]),o=0;o<12;o++){if(r=Oo([2e3,o]),n&&!this._longMonthsParse[o]&&(this._longMonthsParse[o]=new RegExp("^"+this.months(r,"").replace(".","")+"$","i"),this._shortMonthsParse[o]=new RegExp("^"+this.monthsShort(r,"").replace(".","")+"$","i")),!n&&!this._monthsParse[o]&&(i="^"+this.months(r,"")+"|^"+this.monthsShort(r,""),this._monthsParse[o]=new RegExp(i.replace(".",""),"i")),n&&t==="MMMM"&&this._longMonthsParse[o].test(e))return o;if(n&&t==="MMM"&&this._shortMonthsParse[o].test(e))return o;if(!n&&this._monthsParse[o].test(e))return o}}function $y(e,t){if(!e.isValid())return e;if(typeof t=="string"){if(/^\d+$/.test(t))t=Qe(t);else if(t=e.localeData().monthsParse(t),!Jo(t))return e}var n=t,o=e.date();return o=o<29?o:Math.min(o,Qu(e.year(),n)),e._isUTC?e._d.setUTCMonth(n,o):e._d.setMonth(n,o),e}function Vy(e){return e!=null?($y(this,e),_e.updateOffset(this,!0),this):Yi(this,"Month")}function qD(){return Qu(this.year(),this.month())}function GD(e){return this._monthsParseExact?(ut(this,"_monthsRegex")||jy.call(this),e?this._monthsShortStrictRegex:this._monthsShortRegex):(ut(this,"_monthsShortRegex")||(this._monthsShortRegex=BD),this._monthsShortStrictRegex&&e?this._monthsShortStrictRegex:this._monthsShortRegex)}function KD(e){return this._monthsParseExact?(ut(this,"_monthsRegex")||jy.call(this),e?this._monthsStrictRegex:this._monthsRegex):(ut(this,"_monthsRegex")||(this._monthsRegex=WD),this._monthsStrictRegex&&e?this._monthsStrictRegex:this._monthsRegex)}function jy(){function e(d,u){return u.length-d.length}var t=[],n=[],o=[],r,i,a,l;for(r=0;r<12;r++)i=Oo([2e3,r]),a=qo(this.monthsShort(i,"")),l=qo(this.months(i,"")),t.push(a),n.push(l),o.push(l),o.push(a);t.sort(e),n.sort(e),o.sort(e),this._monthsRegex=new RegExp("^("+o.join("|")+")","i"),this._monthsShortRegex=this._monthsRegex,this._monthsStrictRegex=new RegExp("^("+n.join("|")+")","i"),this._monthsShortStrictRegex=new RegExp("^("+t.join("|")+")","i")}function XD(e,t,n,o,r,i,a){var l;return e<100&&e>=0?(l=new Date(e+400,t,n,o,r,i,a),isFinite(l.getFullYear())&&l.setFullYear(e)):l=new Date(e,t,n,o,r,i,a),l}function Ui(e){var t,n;return e<100&&e>=0?(n=Array.prototype.slice.call(arguments),n[0]=e+400,t=new Date(Date.UTC.apply(null,n)),isFinite(t.getUTCFullYear())&&t.setUTCFullYear(e)):t=new Date(Date.UTC.apply(null,arguments)),t}function Cl(e,t,n){var o=7+t-n,r=(7+Ui(e,0,o).getUTCDay()-t)%7;return-r+o-1}function By(e,t,n,o,r){var i=(7+n-o)%7,a=Cl(e,o,r),l=1+7*(t-1)+i+a,d,u;return l<=0?(d=e-1,u=Ti(d)+l):l>Ti(e)?(d=e+1,u=l-Ti(e)):(d=e,u=l),{year:d,dayOfYear:u}}function qi(e,t,n){var o=Cl(e.year(),t,n),r=Math.floor((e.dayOfYear()-o-1)/7)+1,i,a;return r<1?(a=e.year()-1,i=r+Go(a,t,n)):r>Go(e.year(),t,n)?(i=r-Go(e.year(),t,n),a=e.year()+1):(a=e.year(),i=r),{week:i,year:a}}function Go(e,t,n){var o=Cl(e,t,n),r=Cl(e+1,t,n);return(Ti(e)-o+r)/7}Le("w",["ww",2],"wo","week");Le("W",["WW",2],"Wo","isoWeek");Ee("w",It,Bs);Ee("ww",It,$n);Ee("W",It,Bs);Ee("WW",It,$n);ma(["w","ww","W","WW"],function(e,t,n,o){t[o.substr(0,1)]=Qe(e)});function ZD(e){return qi(e,this._week.dow,this._week.doy).week}var QD={dow:0,doy:6};function JD(){return this._week.dow}function eO(){return this._week.doy}function tO(e){var t=this.localeData().week(this);return e==null?t:this.add((e-t)*7,"d")}function nO(e){var t=qi(this,1,4).week;return e==null?t:this.add((e-t)*7,"d")}Le("d",0,"do","day");Le("dd",0,0,function(e){return this.localeData().weekdaysMin(this,e)});Le("ddd",0,0,function(e){return this.localeData().weekdaysShort(this,e)});Le("dddd",0,0,function(e){return this.localeData().weekdays(this,e)});Le("e",0,0,"weekday");Le("E",0,0,"isoWeekday");Ee("d",It);Ee("e",It);Ee("E",It);Ee("dd",function(e,t){return t.weekdaysMinRegex(e)});Ee("ddd",function(e,t){return t.weekdaysShortRegex(e)});Ee("dddd",function(e,t){return t.weekdaysRegex(e)});ma(["dd","ddd","dddd"],function(e,t,n,o){var r=n._locale.weekdaysParse(e,o,n._strict);r!=null?t.d=r:ze(n).invalidWeekday=e});ma(["d","e","E"],function(e,t,n,o){t[o]=Qe(e)});function oO(e,t){return typeof e!="string"?e:isNaN(e)?(e=t.weekdaysParse(e),typeof e=="number"?e:null):parseInt(e,10)}function rO(e,t){return typeof e=="string"?t.weekdaysParse(e)%7||7:isNaN(e)?null:e}function Ju(e,t){return e.slice(t,7).concat(e.slice(0,t))}var sO="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),Wy="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),iO="Su_Mo_Tu_We_Th_Fr_Sa".split("_"),aO=pa,lO=pa,cO=pa;function dO(e,t){var n=io(this._weekdays)?this._weekdays:this._weekdays[e&&e!==!0&&this._weekdays.isFormat.test(t)?"format":"standalone"];return e===!0?Ju(n,this._week.dow):e?n[e.day()]:n}function uO(e){return e===!0?Ju(this._weekdaysShort,this._week.dow):e?this._weekdaysShort[e.day()]:this._weekdaysShort}function hO(e){return e===!0?Ju(this._weekdaysMin,this._week.dow):e?this._weekdaysMin[e.day()]:this._weekdaysMin}function fO(e,t,n){var o,r,i,a=e.toLocaleLowerCase();if(!this._weekdaysParse)for(this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[],o=0;o<7;++o)i=Oo([2e3,1]).day(o),this._minWeekdaysParse[o]=this.weekdaysMin(i,"").toLocaleLowerCase(),this._shortWeekdaysParse[o]=this.weekdaysShort(i,"").toLocaleLowerCase(),this._weekdaysParse[o]=this.weekdays(i,"").toLocaleLowerCase();return n?t==="dddd"?(r=qt.call(this._weekdaysParse,a),r!==-1?r:null):t==="ddd"?(r=qt.call(this._shortWeekdaysParse,a),r!==-1?r:null):(r=qt.call(this._minWeekdaysParse,a),r!==-1?r:null):t==="dddd"?(r=qt.call(this._weekdaysParse,a),r!==-1||(r=qt.call(this._shortWeekdaysParse,a),r!==-1)?r:(r=qt.call(this._minWeekdaysParse,a),r!==-1?r:null)):t==="ddd"?(r=qt.call(this._shortWeekdaysParse,a),r!==-1||(r=qt.call(this._weekdaysParse,a),r!==-1)?r:(r=qt.call(this._minWeekdaysParse,a),r!==-1?r:null)):(r=qt.call(this._minWeekdaysParse,a),r!==-1||(r=qt.call(this._weekdaysParse,a),r!==-1)?r:(r=qt.call(this._shortWeekdaysParse,a),r!==-1?r:null))}function pO(e,t,n){var o,r,i;if(this._weekdaysParseExact)return fO.call(this,e,t,n);for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),o=0;o<7;o++){if(r=Oo([2e3,1]).day(o),n&&!this._fullWeekdaysParse[o]&&(this._fullWeekdaysParse[o]=new RegExp("^"+this.weekdays(r,"").replace(".","\\.?")+"$","i"),this._shortWeekdaysParse[o]=new RegExp("^"+this.weekdaysShort(r,"").replace(".","\\.?")+"$","i"),this._minWeekdaysParse[o]=new RegExp("^"+this.weekdaysMin(r,"").replace(".","\\.?")+"$","i")),this._weekdaysParse[o]||(i="^"+this.weekdays(r,"")+"|^"+this.weekdaysShort(r,"")+"|^"+this.weekdaysMin(r,""),this._weekdaysParse[o]=new RegExp(i.replace(".",""),"i")),n&&t==="dddd"&&this._fullWeekdaysParse[o].test(e))return o;if(n&&t==="ddd"&&this._shortWeekdaysParse[o].test(e))return o;if(n&&t==="dd"&&this._minWeekdaysParse[o].test(e))return o;if(!n&&this._weekdaysParse[o].test(e))return o}}function mO(e){if(!this.isValid())return e!=null?this:NaN;var t=Yi(this,"Day");return e!=null?(e=oO(e,this.localeData()),this.add(e-t,"d")):t}function gO(e){if(!this.isValid())return e!=null?this:NaN;var t=(this.day()+7-this.localeData()._week.dow)%7;return e==null?t:this.add(e-t,"d")}function yO(e){if(!this.isValid())return e!=null?this:NaN;if(e!=null){var t=rO(e,this.localeData());return this.day(this.day()%7?t:t-7)}else return this.day()||7}function vO(e){return this._weekdaysParseExact?(ut(this,"_weekdaysRegex")||eh.call(this),e?this._weekdaysStrictRegex:this._weekdaysRegex):(ut(this,"_weekdaysRegex")||(this._weekdaysRegex=aO),this._weekdaysStrictRegex&&e?this._weekdaysStrictRegex:this._weekdaysRegex)}function bO(e){return this._weekdaysParseExact?(ut(this,"_weekdaysRegex")||eh.call(this),e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex):(ut(this,"_weekdaysShortRegex")||(this._weekdaysShortRegex=lO),this._weekdaysShortStrictRegex&&e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex)}function wO(e){return this._weekdaysParseExact?(ut(this,"_weekdaysRegex")||eh.call(this),e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex):(ut(this,"_weekdaysMinRegex")||(this._weekdaysMinRegex=cO),this._weekdaysMinStrictRegex&&e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex)}function eh(){function e(f,p){return p.length-f.length}var t=[],n=[],o=[],r=[],i,a,l,d,u;for(i=0;i<7;i++)a=Oo([2e3,1]).day(i),l=qo(this.weekdaysMin(a,"")),d=qo(this.weekdaysShort(a,"")),u=qo(this.weekdays(a,"")),t.push(l),n.push(d),o.push(u),r.push(l),r.push(d),r.push(u);t.sort(e),n.sort(e),o.sort(e),r.sort(e),this._weekdaysRegex=new RegExp("^("+r.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=new RegExp("^("+o.join("|")+")","i"),this._weekdaysShortStrictRegex=new RegExp("^("+n.join("|")+")","i"),this._weekdaysMinStrictRegex=new RegExp("^("+t.join("|")+")","i")}function th(){return this.hours()%12||12}function CO(){return this.hours()||24}Le("H",["HH",2],0,"hour");Le("h",["hh",2],0,th);Le("k",["kk",2],0,CO);Le("hmm",0,0,function(){return""+th.apply(this)+Eo(this.minutes(),2)});Le("hmmss",0,0,function(){return""+th.apply(this)+Eo(this.minutes(),2)+Eo(this.seconds(),2)});Le("Hmm",0,0,function(){return""+this.hours()+Eo(this.minutes(),2)});Le("Hmmss",0,0,function(){return""+this.hours()+Eo(this.minutes(),2)+Eo(this.seconds(),2)});function Hy(e,t){Le(e,0,0,function(){return this.localeData().meridiem(this.hours(),this.minutes(),t)})}Hy("a",!0);Hy("A",!1);function zy(e,t){return t._meridiemParse}Ee("a",zy);Ee("A",zy);Ee("H",It,Zu);Ee("h",It,Bs);Ee("k",It,Bs);Ee("HH",It,$n);Ee("hh",It,$n);Ee("kk",It,$n);Ee("hmm",My);Ee("hmmss",Iy);Ee("Hmm",My);Ee("Hmmss",Iy);Tt(["H","HH"],tn);Tt(["k","kk"],function(e,t,n){var o=Qe(e);t[tn]=o===24?0:o});Tt(["a","A"],function(e,t,n){n._isPm=n._locale.isPM(e),n._meridiem=e});Tt(["h","hh"],function(e,t,n){t[tn]=Qe(e),ze(n).bigHour=!0});Tt("hmm",function(e,t,n){var o=e.length-2;t[tn]=Qe(e.substr(0,o)),t[ro]=Qe(e.substr(o)),ze(n).bigHour=!0});Tt("hmmss",function(e,t,n){var o=e.length-4,r=e.length-2;t[tn]=Qe(e.substr(0,o)),t[ro]=Qe(e.substr(o,2)),t[Yo]=Qe(e.substr(r)),ze(n).bigHour=!0});Tt("Hmm",function(e,t,n){var o=e.length-2;t[tn]=Qe(e.substr(0,o)),t[ro]=Qe(e.substr(o))});Tt("Hmmss",function(e,t,n){var o=e.length-4,r=e.length-2;t[tn]=Qe(e.substr(0,o)),t[ro]=Qe(e.substr(o,2)),t[Yo]=Qe(e.substr(r))});function SO(e){return(e+"").toLowerCase().charAt(0)==="p"}var _O=/[ap]\.?m?\.?/i,xO=Ws("Hours",!0);function RO(e,t,n){return e>11?n?"pm":"PM":n?"am":"AM"}var Yy={calendar:fD,longDateFormat:yD,invalidDate:bD,ordinal:CD,dayOfMonthOrdinalParse:SD,relativeTime:xD,months:jD,monthsShort:Fy,week:QD,weekdays:sO,weekdaysMin:iO,weekdaysShort:Wy,meridiemParse:_O},$t={},ri={},Gi;function kO(e,t){var n,o=Math.min(e.length,t.length);for(n=0;n<o;n+=1)if(e[n]!==t[n])return n;return o}function Jp(e){return e&&e.toLowerCase().replace("_","-")}function TO(e){for(var t=0,n,o,r,i;t<e.length;){for(i=Jp(e[t]).split("-"),n=i.length,o=Jp(e[t+1]),o=o?o.split("-"):null;n>0;){if(r=cc(i.slice(0,n).join("-")),r)return r;if(o&&o.length>=n&&kO(i,o)>=n-1)break;n--}t++}return Gi}function EO(e){return!!(e&&e.match("^[^/\\\\]*$"))}function cc(e){var t=null,n;if($t[e]===void 0&&typeof module<"u"&&module&&module.exports&&EO(e))try{t=Gi._abbr,n=require,n("./locale/"+e),hr(t)}catch{$t[e]=null}return $t[e]}function hr(e,t){var n;return e&&(xn(t)?n=nr(e):n=nh(e,t),n?Gi=n:typeof console<"u"&&console.warn&&console.warn("Locale "+e+" not found. Did you forget to load it?")),Gi._abbr}function nh(e,t){if(t!==null){var n,o=Yy;if(t.abbr=e,$t[e]!=null)Ey("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."),o=$t[e]._config;else if(t.parentLocale!=null)if($t[t.parentLocale]!=null)o=$t[t.parentLocale]._config;else if(n=cc(t.parentLocale),n!=null)o=n._config;else return ri[t.parentLocale]||(ri[t.parentLocale]=[]),ri[t.parentLocale].push({name:e,config:t}),null;return $t[e]=new Uu(qd(o,t)),ri[e]&&ri[e].forEach(function(r){nh(r.name,r.config)}),hr(e),$t[e]}else return delete $t[e],null}function PO(e,t){if(t!=null){var n,o,r=Yy;$t[e]!=null&&$t[e].parentLocale!=null?$t[e].set(qd($t[e]._config,t)):(o=cc(e),o!=null&&(r=o._config),t=qd(r,t),o==null&&(t.abbr=e),n=new Uu(t),n.parentLocale=$t[e],$t[e]=n),hr(e)}else $t[e]!=null&&($t[e].parentLocale!=null?($t[e]=$t[e].parentLocale,e===hr()&&hr(e)):$t[e]!=null&&delete $t[e]);return $t[e]}function nr(e){var t;if(e&&e._locale&&e._locale._abbr&&(e=e._locale._abbr),!e)return Gi;if(!io(e)){if(t=cc(e),t)return t;e=[e]}return TO(e)}function DO(){return Gd($t)}function oh(e){var t,n=e._a;return n&&ze(e).overflow===-2&&(t=n[zo]<0||n[zo]>11?zo:n[So]<1||n[So]>Qu(n[yn],n[zo])?So:n[tn]<0||n[tn]>24||n[tn]===24&&(n[ro]!==0||n[Yo]!==0||n[Ir]!==0)?tn:n[ro]<0||n[ro]>59?ro:n[Yo]<0||n[Yo]>59?Yo:n[Ir]<0||n[Ir]>999?Ir:-1,ze(e)._overflowDayOfYear&&(t<yn||t>So)&&(t=So),ze(e)._overflowWeeks&&t===-1&&(t=ND),ze(e)._overflowWeekday&&t===-1&&(t=AD),ze(e).overflow=t),e}var OO=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,MO=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d|))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,IO=/Z|[+-]\d\d(?::?\d\d)?/,za=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/],["YYYYMM",/\d{6}/,!1],["YYYY",/\d{4}/,!1]],dd=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],NO=/^\/?Date\((-?\d+)/i,AO=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/,FO={UT:0,GMT:0,EDT:-4*60,EST:-5*60,CDT:-5*60,CST:-6*60,MDT:-6*60,MST:-7*60,PDT:-7*60,PST:-8*60};function Uy(e){var t,n,o=e._i,r=OO.exec(o)||MO.exec(o),i,a,l,d,u=za.length,f=dd.length;if(r){for(ze(e).iso=!0,t=0,n=u;t<n;t++)if(za[t][1].exec(r[1])){a=za[t][0],i=za[t][2]!==!1;break}if(a==null){e._isValid=!1;return}if(r[3]){for(t=0,n=f;t<n;t++)if(dd[t][1].exec(r[3])){l=(r[2]||" ")+dd[t][0];break}if(l==null){e._isValid=!1;return}}if(!i&&l!=null){e._isValid=!1;return}if(r[4])if(IO.exec(r[4]))d="Z";else{e._isValid=!1;return}e._f=a+(l||"")+(d||""),sh(e)}else e._isValid=!1}function LO(e,t,n,o,r,i){var a=[$O(e),Fy.indexOf(t),parseInt(n,10),parseInt(o,10),parseInt(r,10)];return i&&a.push(parseInt(i,10)),a}function $O(e){var t=parseInt(e,10);return t<=49?2e3+t:t<=999?1900+t:t}function VO(e){return e.replace(/\([^()]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").replace(/^\s\s*/,"").replace(/\s\s*$/,"")}function jO(e,t,n){if(e){var o=Wy.indexOf(e),r=new Date(t[0],t[1],t[2]).getDay();if(o!==r)return ze(n).weekdayMismatch=!0,n._isValid=!1,!1}return!0}function BO(e,t,n){if(e)return FO[e];if(t)return 0;var o=parseInt(n,10),r=o%100,i=(o-r)/100;return i*60+r}function qy(e){var t=AO.exec(VO(e._i)),n;if(t){if(n=LO(t[4],t[3],t[2],t[5],t[6],t[7]),!jO(t[1],n,e))return;e._a=n,e._tzm=BO(t[8],t[9],t[10]),e._d=Ui.apply(null,e._a),e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),ze(e).rfc2822=!0}else e._isValid=!1}function WO(e){var t=NO.exec(e._i);if(t!==null){e._d=new Date(+t[1]);return}if(Uy(e),e._isValid===!1)delete e._isValid;else return;if(qy(e),e._isValid===!1)delete e._isValid;else return;e._strict?e._isValid=!1:_e.createFromInputFallback(e)}_e.createFromInputFallback=Jn("value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are discouraged. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.",function(e){e._d=new Date(e._i+(e._useUTC?" UTC":""))});function hs(e,t,n){return e??t??n}function HO(e){var t=new Date(_e.now());return e._useUTC?[t.getUTCFullYear(),t.getUTCMonth(),t.getUTCDate()]:[t.getFullYear(),t.getMonth(),t.getDate()]}function rh(e){var t,n,o=[],r,i,a;if(!e._d){for(r=HO(e),e._w&&e._a[So]==null&&e._a[zo]==null&&zO(e),e._dayOfYear!=null&&(a=hs(e._a[yn],r[yn]),(e._dayOfYear>Ti(a)||e._dayOfYear===0)&&(ze(e)._overflowDayOfYear=!0),n=Ui(a,0,e._dayOfYear),e._a[zo]=n.getUTCMonth(),e._a[So]=n.getUTCDate()),t=0;t<3&&e._a[t]==null;++t)e._a[t]=o[t]=r[t];for(;t<7;t++)e._a[t]=o[t]=e._a[t]==null?t===2?1:0:e._a[t];e._a[tn]===24&&e._a[ro]===0&&e._a[Yo]===0&&e._a[Ir]===0&&(e._nextDay=!0,e._a[tn]=0),e._d=(e._useUTC?Ui:XD).apply(null,o),i=e._useUTC?e._d.getUTCDay():e._d.getDay(),e._tzm!=null&&e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),e._nextDay&&(e._a[tn]=24),e._w&&typeof e._w.d<"u"&&e._w.d!==i&&(ze(e).weekdayMismatch=!0)}}function zO(e){var t,n,o,r,i,a,l,d,u;t=e._w,t.GG!=null||t.W!=null||t.E!=null?(i=1,a=4,n=hs(t.GG,e._a[yn],qi(Ot(),1,4).year),o=hs(t.W,1),r=hs(t.E,1),(r<1||r>7)&&(d=!0)):(i=e._locale._week.dow,a=e._locale._week.doy,u=qi(Ot(),i,a),n=hs(t.gg,e._a[yn],u.year),o=hs(t.w,u.week),t.d!=null?(r=t.d,(r<0||r>6)&&(d=!0)):t.e!=null?(r=t.e+i,(t.e<0||t.e>6)&&(d=!0)):r=i),o<1||o>Go(n,i,a)?ze(e)._overflowWeeks=!0:d!=null?ze(e)._overflowWeekday=!0:(l=By(n,o,r,i,a),e._a[yn]=l.year,e._dayOfYear=l.dayOfYear)}_e.ISO_8601=function(){};_e.RFC_2822=function(){};function sh(e){if(e._f===_e.ISO_8601){Uy(e);return}if(e._f===_e.RFC_2822){qy(e);return}e._a=[],ze(e).empty=!0;var t=""+e._i,n,o,r,i,a,l=t.length,d=0,u,f;for(r=Py(e._f,e._locale).match(qu)||[],f=r.length,n=0;n<f;n++)i=r[n],o=(t.match(OD(i,e))||[])[0],o&&(a=t.substr(0,t.indexOf(o)),a.length>0&&ze(e).unusedInput.push(a),t=t.slice(t.indexOf(o)+o.length),d+=o.length),bs[i]?(o?ze(e).empty=!1:ze(e).unusedTokens.push(i),ID(i,o,e)):e._strict&&!o&&ze(e).unusedTokens.push(i);ze(e).charsLeftOver=l-d,t.length>0&&ze(e).unusedInput.push(t),e._a[tn]<=12&&ze(e).bigHour===!0&&e._a[tn]>0&&(ze(e).bigHour=void 0),ze(e).parsedDateParts=e._a.slice(0),ze(e).meridiem=e._meridiem,e._a[tn]=YO(e._locale,e._a[tn],e._meridiem),u=ze(e).era,u!==null&&(e._a[yn]=e._locale.erasConvertYear(u,e._a[yn])),rh(e),oh(e)}function YO(e,t,n){var o;return n==null?t:e.meridiemHour!=null?e.meridiemHour(t,n):(e.isPM!=null&&(o=e.isPM(n),o&&t<12&&(t+=12),!o&&t===12&&(t=0)),t)}function UO(e){var t,n,o,r,i,a,l=!1,d=e._f.length;if(d===0){ze(e).invalidFormat=!0,e._d=new Date(NaN);return}for(r=0;r<d;r++)i=0,a=!1,t=Yu({},e),e._useUTC!=null&&(t._useUTC=e._useUTC),t._f=e._f[r],sh(t),zu(t)&&(a=!0),i+=ze(t).charsLeftOver,i+=ze(t).unusedTokens.length*10,ze(t).score=i,l?i<o&&(o=i,n=t):(o==null||i<o||a)&&(o=i,n=t,a&&(l=!0));dr(e,n||t)}function qO(e){if(!e._d){var t=Gu(e._i),n=t.day===void 0?t.date:t.day;e._a=ky([t.year,t.month,n,t.hour,t.minute,t.second,t.millisecond],function(o){return o&&parseInt(o,10)}),rh(e)}}function GO(e){var t=new fa(oh(Gy(e)));return t._nextDay&&(t.add(1,"d"),t._nextDay=void 0),t}function Gy(e){var t=e._i,n=e._f;return e._locale=e._locale||nr(e._l),t===null||n===void 0&&t===""?nc({nullInput:!0}):(typeof t=="string"&&(e._i=t=e._locale.preparse(t)),ao(t)?new fa(oh(t)):(ha(t)?e._d=t:io(n)?UO(e):n?sh(e):KO(e),zu(e)||(e._d=null),e))}function KO(e){var t=e._i;xn(t)?e._d=new Date(_e.now()):ha(t)?e._d=new Date(t.valueOf()):typeof t=="string"?WO(e):io(t)?(e._a=ky(t.slice(0),function(n){return parseInt(n,10)}),rh(e)):Fr(t)?qO(e):Jo(t)?e._d=new Date(t):_e.createFromInputFallback(e)}function Ky(e,t,n,o,r){var i={};return(t===!0||t===!1)&&(o=t,t=void 0),(n===!0||n===!1)&&(o=n,n=void 0),(Fr(e)&&Hu(e)||io(e)&&e.length===0)&&(e=void 0),i._isAMomentObject=!0,i._useUTC=i._isUTC=r,i._l=n,i._i=e,i._f=t,i._strict=o,GO(i)}function Ot(e,t,n,o){return Ky(e,t,n,o,!1)}var XO=Jn("moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var e=Ot.apply(null,arguments);return this.isValid()&&e.isValid()?e<this?this:e:nc()}),ZO=Jn("moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var e=Ot.apply(null,arguments);return this.isValid()&&e.isValid()?e>this?this:e:nc()});function Xy(e,t){var n,o;if(t.length===1&&io(t[0])&&(t=t[0]),!t.length)return Ot();for(n=t[0],o=1;o<t.length;++o)(!t[o].isValid()||t[o][e](n))&&(n=t[o]);return n}function QO(){var e=[].slice.call(arguments,0);return Xy("isBefore",e)}function JO(){var e=[].slice.call(arguments,0);return Xy("isAfter",e)}var eM=function(){return Date.now?Date.now():+new Date},si=["year","quarter","month","week","day","hour","minute","second","millisecond"];function tM(e){var t,n=!1,o,r=si.length;for(t in e)if(ut(e,t)&&!(qt.call(si,t)!==-1&&(e[t]==null||!isNaN(e[t]))))return!1;for(o=0;o<r;++o)if(e[si[o]]){if(n)return!1;parseFloat(e[si[o]])!==Qe(e[si[o]])&&(n=!0)}return!0}function nM(){return this._isValid}function oM(){return co(NaN)}function dc(e){var t=Gu(e),n=t.year||0,o=t.quarter||0,r=t.month||0,i=t.week||t.isoWeek||0,a=t.day||0,l=t.hour||0,d=t.minute||0,u=t.second||0,f=t.millisecond||0;this._isValid=tM(t),this._milliseconds=+f+u*1e3+d*6e4+l*1e3*60*60,this._days=+a+i*7,this._months=+r+o*3+n*12,this._data={},this._locale=nr(),this._bubble()}function sl(e){return e instanceof dc}function Xd(e){return e<0?Math.round(-1*e)*-1:Math.round(e)}function rM(e,t,n){var o=Math.min(e.length,t.length),r=Math.abs(e.length-t.length),i=0,a;for(a=0;a<o;a++)Qe(e[a])!==Qe(t[a])&&i++;return i+r}function Zy(e,t){Le(e,0,0,function(){var n=this.utcOffset(),o="+";return n<0&&(n=-n,o="-"),o+Eo(~~(n/60),2)+t+Eo(~~n%60,2)})}Zy("Z",":");Zy("ZZ","");Ee("Z",ac);Ee("ZZ",ac);Tt(["Z","ZZ"],function(e,t,n){n._useUTC=!0,n._tzm=ih(ac,e)});var sM=/([\+\-]|\d\d)/gi;function ih(e,t){var n=(t||"").match(e),o,r,i;return n===null?null:(o=n[n.length-1]||[],r=(o+"").match(sM)||["-",0,0],i=+(r[1]*60)+Qe(r[2]),i===0?0:r[0]==="+"?i:-i)}function ah(e,t){var n,o;return t._isUTC?(n=t.clone(),o=(ao(e)||ha(e)?e.valueOf():Ot(e).valueOf())-n.valueOf(),n._d.setTime(n._d.valueOf()+o),_e.updateOffset(n,!1),n):Ot(e).local()}function Zd(e){return-Math.round(e._d.getTimezoneOffset())}_e.updateOffset=function(){};function iM(e,t,n){var o=this._offset||0,r;if(!this.isValid())return e!=null?this:NaN;if(e!=null){if(typeof e=="string"){if(e=ih(ac,e),e===null)return this}else Math.abs(e)<16&&!n&&(e=e*60);return!this._isUTC&&t&&(r=Zd(this)),this._offset=e,this._isUTC=!0,r!=null&&this.add(r,"m"),o!==e&&(!t||this._changeInProgress?ev(this,co(e-o,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,_e.updateOffset(this,!0),this._changeInProgress=null)),this}else return this._isUTC?o:Zd(this)}function aM(e,t){return e!=null?(typeof e!="string"&&(e=-e),this.utcOffset(e,t),this):-this.utcOffset()}function lM(e){return this.utcOffset(0,e)}function cM(e){return this._isUTC&&(this.utcOffset(0,e),this._isUTC=!1,e&&this.subtract(Zd(this),"m")),this}function dM(){if(this._tzm!=null)this.utcOffset(this._tzm,!1,!0);else if(typeof this._i=="string"){var e=ih(PD,this._i);e!=null?this.utcOffset(e):this.utcOffset(0,!0)}return this}function uM(e){return this.isValid()?(e=e?Ot(e).utcOffset():0,(this.utcOffset()-e)%60===0):!1}function hM(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()}function fM(){if(!xn(this._isDSTShifted))return this._isDSTShifted;var e={},t;return Yu(e,this),e=Gy(e),e._a?(t=e._isUTC?Oo(e._a):Ot(e._a),this._isDSTShifted=this.isValid()&&rM(e._a,t.toArray())>0):this._isDSTShifted=!1,this._isDSTShifted}function pM(){return this.isValid()?!this._isUTC:!1}function mM(){return this.isValid()?this._isUTC:!1}function Qy(){return this.isValid()?this._isUTC&&this._offset===0:!1}var gM=/^(-|\+)?(?:(\d*)[. ])?(\d+):(\d+)(?::(\d+)(\.\d*)?)?$/,yM=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;function co(e,t){var n=e,o=null,r,i,a;return sl(e)?n={ms:e._milliseconds,d:e._days,M:e._months}:Jo(e)||!isNaN(+e)?(n={},t?n[t]=+e:n.milliseconds=+e):(o=gM.exec(e))?(r=o[1]==="-"?-1:1,n={y:0,d:Qe(o[So])*r,h:Qe(o[tn])*r,m:Qe(o[ro])*r,s:Qe(o[Yo])*r,ms:Qe(Xd(o[Ir]*1e3))*r}):(o=yM.exec(e))?(r=o[1]==="-"?-1:1,n={y:xr(o[2],r),M:xr(o[3],r),w:xr(o[4],r),d:xr(o[5],r),h:xr(o[6],r),m:xr(o[7],r),s:xr(o[8],r)}):n==null?n={}:typeof n=="object"&&("from"in n||"to"in n)&&(a=vM(Ot(n.from),Ot(n.to)),n={},n.ms=a.milliseconds,n.M=a.months),i=new dc(n),sl(e)&&ut(e,"_locale")&&(i._locale=e._locale),sl(e)&&ut(e,"_isValid")&&(i._isValid=e._isValid),i}co.fn=dc.prototype;co.invalid=oM;function xr(e,t){var n=e&&parseFloat(e.replace(",","."));return(isNaN(n)?0:n)*t}function em(e,t){var n={};return n.months=t.month()-e.month()+(t.year()-e.year())*12,e.clone().add(n.months,"M").isAfter(t)&&--n.months,n.milliseconds=+t-+e.clone().add(n.months,"M"),n}function vM(e,t){var n;return e.isValid()&&t.isValid()?(t=ah(t,e),e.isBefore(t)?n=em(e,t):(n=em(t,e),n.milliseconds=-n.milliseconds,n.months=-n.months),n):{milliseconds:0,months:0}}function Jy(e,t){return function(n,o){var r,i;return o!==null&&!isNaN(+o)&&(Ey(t,"moment()."+t+"(period, number) is deprecated. Please use moment()."+t+"(number, period). See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info."),i=n,n=o,o=i),r=co(n,o),ev(this,r,e),this}}function ev(e,t,n,o){var r=t._milliseconds,i=Xd(t._days),a=Xd(t._months);e.isValid()&&(o=o??!0,a&&$y(e,Yi(e,"Month")+a*n),i&&Ay(e,"Date",Yi(e,"Date")+i*n),r&&e._d.setTime(e._d.valueOf()+r*n),o&&_e.updateOffset(e,i||a))}var bM=Jy(1,"add"),wM=Jy(-1,"subtract");function tv(e){return typeof e=="string"||e instanceof String}function CM(e){return ao(e)||ha(e)||tv(e)||Jo(e)||_M(e)||SM(e)||e===null||e===void 0}function SM(e){var t=Fr(e)&&!Hu(e),n=!1,o=["years","year","y","months","month","M","days","day","d","dates","date","D","hours","hour","h","minutes","minute","m","seconds","second","s","milliseconds","millisecond","ms"],r,i,a=o.length;for(r=0;r<a;r+=1)i=o[r],n=n||ut(e,i);return t&&n}function _M(e){var t=io(e),n=!1;return t&&(n=e.filter(function(o){return!Jo(o)&&tv(e)}).length===0),t&&n}function xM(e){var t=Fr(e)&&!Hu(e),n=!1,o=["sameDay","nextDay","lastDay","nextWeek","lastWeek","sameElse"],r,i;for(r=0;r<o.length;r+=1)i=o[r],n=n||ut(e,i);return t&&n}function RM(e,t){var n=e.diff(t,"days",!0);return n<-6?"sameElse":n<-1?"lastWeek":n<0?"lastDay":n<1?"sameDay":n<2?"nextDay":n<7?"nextWeek":"sameElse"}function kM(e,t){arguments.length===1&&(arguments[0]?CM(arguments[0])?(e=arguments[0],t=void 0):xM(arguments[0])&&(t=arguments[0],e=void 0):(e=void 0,t=void 0));var n=e||Ot(),o=ah(n,this).startOf("day"),r=_e.calendarFormat(this,o)||"sameElse",i=t&&(Mo(t[r])?t[r].call(this,n):t[r]);return this.format(i||this.localeData().calendar(r,this,Ot(n)))}function TM(){return new fa(this)}function EM(e,t){var n=ao(e)?e:Ot(e);return this.isValid()&&n.isValid()?(t=eo(t)||"millisecond",t==="millisecond"?this.valueOf()>n.valueOf():n.valueOf()<this.clone().startOf(t).valueOf()):!1}function PM(e,t){var n=ao(e)?e:Ot(e);return this.isValid()&&n.isValid()?(t=eo(t)||"millisecond",t==="millisecond"?this.valueOf()<n.valueOf():this.clone().endOf(t).valueOf()<n.valueOf()):!1}function DM(e,t,n,o){var r=ao(e)?e:Ot(e),i=ao(t)?t:Ot(t);return this.isValid()&&r.isValid()&&i.isValid()?(o=o||"()",(o[0]==="("?this.isAfter(r,n):!this.isBefore(r,n))&&(o[1]===")"?this.isBefore(i,n):!this.isAfter(i,n))):!1}function OM(e,t){var n=ao(e)?e:Ot(e),o;return this.isValid()&&n.isValid()?(t=eo(t)||"millisecond",t==="millisecond"?this.valueOf()===n.valueOf():(o=n.valueOf(),this.clone().startOf(t).valueOf()<=o&&o<=this.clone().endOf(t).valueOf())):!1}function MM(e,t){return this.isSame(e,t)||this.isAfter(e,t)}function IM(e,t){return this.isSame(e,t)||this.isBefore(e,t)}function NM(e,t,n){var o,r,i;if(!this.isValid())return NaN;if(o=ah(e,this),!o.isValid())return NaN;switch(r=(o.utcOffset()-this.utcOffset())*6e4,t=eo(t),t){case"year":i=il(this,o)/12;break;case"month":i=il(this,o);break;case"quarter":i=il(this,o)/3;break;case"second":i=(this-o)/1e3;break;case"minute":i=(this-o)/6e4;break;case"hour":i=(this-o)/36e5;break;case"day":i=(this-o-r)/864e5;break;case"week":i=(this-o-r)/6048e5;break;default:i=this-o}return n?i:Un(i)}function il(e,t){if(e.date()<t.date())return-il(t,e);var n=(t.year()-e.year())*12+(t.month()-e.month()),o=e.clone().add(n,"months"),r,i;return t-o<0?(r=e.clone().add(n-1,"months"),i=(t-o)/(o-r)):(r=e.clone().add(n+1,"months"),i=(t-o)/(r-o)),-(n+i)||0}_e.defaultFormat="YYYY-MM-DDTHH:mm:ssZ";_e.defaultFormatUtc="YYYY-MM-DDTHH:mm:ss[Z]";function AM(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")}function FM(e){if(!this.isValid())return null;var t=e!==!0,n=t?this.clone().utc():this;return n.year()<0||n.year()>9999?rl(n,t?"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYYYY-MM-DD[T]HH:mm:ss.SSSZ"):Mo(Date.prototype.toISOString)?t?this.toDate().toISOString():new Date(this.valueOf()+this.utcOffset()*60*1e3).toISOString().replace("Z",rl(n,"Z")):rl(n,t?"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYY-MM-DD[T]HH:mm:ss.SSSZ")}function LM(){if(!this.isValid())return"moment.invalid(/* "+this._i+" */)";var e="moment",t="",n,o,r,i;return this.isLocal()||(e=this.utcOffset()===0?"moment.utc":"moment.parseZone",t="Z"),n="["+e+'("]',o=0<=this.year()&&this.year()<=9999?"YYYY":"YYYYYY",r="-MM-DD[T]HH:mm:ss.SSS",i=t+'[")]',this.format(n+o+r+i)}function $M(e){e||(e=this.isUtc()?_e.defaultFormatUtc:_e.defaultFormat);var t=rl(this,e);return this.localeData().postformat(t)}function VM(e,t){return this.isValid()&&(ao(e)&&e.isValid()||Ot(e).isValid())?co({to:this,from:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()}function jM(e){return this.from(Ot(),e)}function BM(e,t){return this.isValid()&&(ao(e)&&e.isValid()||Ot(e).isValid())?co({from:this,to:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()}function WM(e){return this.to(Ot(),e)}function nv(e){var t;return e===void 0?this._locale._abbr:(t=nr(e),t!=null&&(this._locale=t),this)}var ov=Jn("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(e){return e===void 0?this.localeData():this.locale(e)});function rv(){return this._locale}var Sl=1e3,ws=60*Sl,_l=60*ws,sv=(365*400+97)*24*_l;function Cs(e,t){return(e%t+t)%t}function iv(e,t,n){return e<100&&e>=0?new Date(e+400,t,n)-sv:new Date(e,t,n).valueOf()}function av(e,t,n){return e<100&&e>=0?Date.UTC(e+400,t,n)-sv:Date.UTC(e,t,n)}function HM(e){var t,n;if(e=eo(e),e===void 0||e==="millisecond"||!this.isValid())return this;switch(n=this._isUTC?av:iv,e){case"year":t=n(this.year(),0,1);break;case"quarter":t=n(this.year(),this.month()-this.month()%3,1);break;case"month":t=n(this.year(),this.month(),1);break;case"week":t=n(this.year(),this.month(),this.date()-this.weekday());break;case"isoWeek":t=n(this.year(),this.month(),this.date()-(this.isoWeekday()-1));break;case"day":case"date":t=n(this.year(),this.month(),this.date());break;case"hour":t=this._d.valueOf(),t-=Cs(t+(this._isUTC?0:this.utcOffset()*ws),_l);break;case"minute":t=this._d.valueOf(),t-=Cs(t,ws);break;case"second":t=this._d.valueOf(),t-=Cs(t,Sl);break}return this._d.setTime(t),_e.updateOffset(this,!0),this}function zM(e){var t,n;if(e=eo(e),e===void 0||e==="millisecond"||!this.isValid())return this;switch(n=this._isUTC?av:iv,e){case"year":t=n(this.year()+1,0,1)-1;break;case"quarter":t=n(this.year(),this.month()-this.month()%3+3,1)-1;break;case"month":t=n(this.year(),this.month()+1,1)-1;break;case"week":t=n(this.year(),this.month(),this.date()-this.weekday()+7)-1;break;case"isoWeek":t=n(this.year(),this.month(),this.date()-(this.isoWeekday()-1)+7)-1;break;case"day":case"date":t=n(this.year(),this.month(),this.date()+1)-1;break;case"hour":t=this._d.valueOf(),t+=_l-Cs(t+(this._isUTC?0:this.utcOffset()*ws),_l)-1;break;case"minute":t=this._d.valueOf(),t+=ws-Cs(t,ws)-1;break;case"second":t=this._d.valueOf(),t+=Sl-Cs(t,Sl)-1;break}return this._d.setTime(t),_e.updateOffset(this,!0),this}function YM(){return this._d.valueOf()-(this._offset||0)*6e4}function UM(){return Math.floor(this.valueOf()/1e3)}function qM(){return new Date(this.valueOf())}function GM(){var e=this;return[e.year(),e.month(),e.date(),e.hour(),e.minute(),e.second(),e.millisecond()]}function KM(){var e=this;return{years:e.year(),months:e.month(),date:e.date(),hours:e.hours(),minutes:e.minutes(),seconds:e.seconds(),milliseconds:e.milliseconds()}}function XM(){return this.isValid()?this.toISOString():null}function ZM(){return zu(this)}function QM(){return dr({},ze(this))}function JM(){return ze(this).overflow}function eI(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}}Le("N",0,0,"eraAbbr");Le("NN",0,0,"eraAbbr");Le("NNN",0,0,"eraAbbr");Le("NNNN",0,0,"eraName");Le("NNNNN",0,0,"eraNarrow");Le("y",["y",1],"yo","eraYear");Le("y",["yy",2],0,"eraYear");Le("y",["yyy",3],0,"eraYear");Le("y",["yyyy",4],0,"eraYear");Ee("N",lh);Ee("NN",lh);Ee("NNN",lh);Ee("NNNN",uI);Ee("NNNNN",hI);Tt(["N","NN","NNN","NNNN","NNNNN"],function(e,t,n,o){var r=n._locale.erasParse(e,o,n._strict);r?ze(n).era=r:ze(n).invalidEra=e});Ee("y",js);Ee("yy",js);Ee("yyy",js);Ee("yyyy",js);Ee("yo",fI);Tt(["y","yy","yyy","yyyy"],yn);Tt(["yo"],function(e,t,n,o){var r;n._locale._eraYearOrdinalRegex&&(r=e.match(n._locale._eraYearOrdinalRegex)),n._locale.eraYearOrdinalParse?t[yn]=n._locale.eraYearOrdinalParse(e,r):t[yn]=parseInt(e,10)});function tI(e,t){var n,o,r,i=this._eras||nr("en")._eras;for(n=0,o=i.length;n<o;++n){switch(typeof i[n].since){case"string":r=_e(i[n].since).startOf("day"),i[n].since=r.valueOf();break}switch(typeof i[n].until){case"undefined":i[n].until=1/0;break;case"string":r=_e(i[n].until).startOf("day").valueOf(),i[n].until=r.valueOf();break}}return i}function nI(e,t,n){var o,r,i=this.eras(),a,l,d;for(e=e.toUpperCase(),o=0,r=i.length;o<r;++o)if(a=i[o].name.toUpperCase(),l=i[o].abbr.toUpperCase(),d=i[o].narrow.toUpperCase(),n)switch(t){case"N":case"NN":case"NNN":if(l===e)return i[o];break;case"NNNN":if(a===e)return i[o];break;case"NNNNN":if(d===e)return i[o];break}else if([a,l,d].indexOf(e)>=0)return i[o]}function oI(e,t){var n=e.since<=e.until?1:-1;return t===void 0?_e(e.since).year():_e(e.since).year()+(t-e.offset)*n}function rI(){var e,t,n,o=this.localeData().eras();for(e=0,t=o.length;e<t;++e)if(n=this.clone().startOf("day").valueOf(),o[e].since<=n&&n<=o[e].until||o[e].until<=n&&n<=o[e].since)return o[e].name;return""}function sI(){var e,t,n,o=this.localeData().eras();for(e=0,t=o.length;e<t;++e)if(n=this.clone().startOf("day").valueOf(),o[e].since<=n&&n<=o[e].until||o[e].until<=n&&n<=o[e].since)return o[e].narrow;return""}function iI(){var e,t,n,o=this.localeData().eras();for(e=0,t=o.length;e<t;++e)if(n=this.clone().startOf("day").valueOf(),o[e].since<=n&&n<=o[e].until||o[e].until<=n&&n<=o[e].since)return o[e].abbr;return""}function aI(){var e,t,n,o,r=this.localeData().eras();for(e=0,t=r.length;e<t;++e)if(n=r[e].since<=r[e].until?1:-1,o=this.clone().startOf("day").valueOf(),r[e].since<=o&&o<=r[e].until||r[e].until<=o&&o<=r[e].since)return(this.year()-_e(r[e].since).year())*n+r[e].offset;return this.year()}function lI(e){return ut(this,"_erasNameRegex")||ch.call(this),e?this._erasNameRegex:this._erasRegex}function cI(e){return ut(this,"_erasAbbrRegex")||ch.call(this),e?this._erasAbbrRegex:this._erasRegex}function dI(e){return ut(this,"_erasNarrowRegex")||ch.call(this),e?this._erasNarrowRegex:this._erasRegex}function lh(e,t){return t.erasAbbrRegex(e)}function uI(e,t){return t.erasNameRegex(e)}function hI(e,t){return t.erasNarrowRegex(e)}function fI(e,t){return t._eraYearOrdinalRegex||js}function ch(){var e=[],t=[],n=[],o=[],r,i,a,l,d,u=this.eras();for(r=0,i=u.length;r<i;++r)a=qo(u[r].name),l=qo(u[r].abbr),d=qo(u[r].narrow),t.push(a),e.push(l),n.push(d),o.push(a),o.push(l),o.push(d);this._erasRegex=new RegExp("^("+o.join("|")+")","i"),this._erasNameRegex=new RegExp("^("+t.join("|")+")","i"),this._erasAbbrRegex=new RegExp("^("+e.join("|")+")","i"),this._erasNarrowRegex=new RegExp("^("+n.join("|")+")","i")}Le(0,["gg",2],0,function(){return this.weekYear()%100});Le(0,["GG",2],0,function(){return this.isoWeekYear()%100});function uc(e,t){Le(0,[e,e.length],0,t)}uc("gggg","weekYear");uc("ggggg","weekYear");uc("GGGG","isoWeekYear");uc("GGGGG","isoWeekYear");Ee("G",ic);Ee("g",ic);Ee("GG",It,$n);Ee("gg",It,$n);Ee("GGGG",Xu,Ku);Ee("gggg",Xu,Ku);Ee("GGGGG",sc,oc);Ee("ggggg",sc,oc);ma(["gggg","ggggg","GGGG","GGGGG"],function(e,t,n,o){t[o.substr(0,2)]=Qe(e)});ma(["gg","GG"],function(e,t,n,o){t[o]=_e.parseTwoDigitYear(e)});function pI(e){return lv.call(this,e,this.week(),this.weekday()+this.localeData()._week.dow,this.localeData()._week.dow,this.localeData()._week.doy)}function mI(e){return lv.call(this,e,this.isoWeek(),this.isoWeekday(),1,4)}function gI(){return Go(this.year(),1,4)}function yI(){return Go(this.isoWeekYear(),1,4)}function vI(){var e=this.localeData()._week;return Go(this.year(),e.dow,e.doy)}function bI(){var e=this.localeData()._week;return Go(this.weekYear(),e.dow,e.doy)}function lv(e,t,n,o,r){var i;return e==null?qi(this,o,r).year:(i=Go(e,o,r),t>i&&(t=i),wI.call(this,e,t,n,o,r))}function wI(e,t,n,o,r){var i=By(e,t,n,o,r),a=Ui(i.year,0,i.dayOfYear);return this.year(a.getUTCFullYear()),this.month(a.getUTCMonth()),this.date(a.getUTCDate()),this}Le("Q",0,"Qo","quarter");Ee("Q",Dy);Tt("Q",function(e,t){t[zo]=(Qe(e)-1)*3});function CI(e){return e==null?Math.ceil((this.month()+1)/3):this.month((e-1)*3+this.month()%3)}Le("D",["DD",2],"Do","date");Ee("D",It,Bs);Ee("DD",It,$n);Ee("Do",function(e,t){return e?t._dayOfMonthOrdinalParse||t._ordinalParse:t._dayOfMonthOrdinalParseLenient});Tt(["D","DD"],So);Tt("Do",function(e,t){t[So]=Qe(e.match(It)[0])});var cv=Ws("Date",!0);Le("DDD",["DDDD",3],"DDDo","dayOfYear");Ee("DDD",rc);Ee("DDDD",Oy);Tt(["DDD","DDDD"],function(e,t,n){n._dayOfYear=Qe(e)});function SI(e){var t=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return e==null?t:this.add(e-t,"d")}Le("m",["mm",2],0,"minute");Ee("m",It,Zu);Ee("mm",It,$n);Tt(["m","mm"],ro);var _I=Ws("Minutes",!1);Le("s",["ss",2],0,"second");Ee("s",It,Zu);Ee("ss",It,$n);Tt(["s","ss"],Yo);var xI=Ws("Seconds",!1);Le("S",0,0,function(){return~~(this.millisecond()/100)});Le(0,["SS",2],0,function(){return~~(this.millisecond()/10)});Le(0,["SSS",3],0,"millisecond");Le(0,["SSSS",4],0,function(){return this.millisecond()*10});Le(0,["SSSSS",5],0,function(){return this.millisecond()*100});Le(0,["SSSSSS",6],0,function(){return this.millisecond()*1e3});Le(0,["SSSSSSS",7],0,function(){return this.millisecond()*1e4});Le(0,["SSSSSSSS",8],0,function(){return this.millisecond()*1e5});Le(0,["SSSSSSSSS",9],0,function(){return this.millisecond()*1e6});Ee("S",rc,Dy);Ee("SS",rc,$n);Ee("SSS",rc,Oy);var ur,dv;for(ur="SSSS";ur.length<=9;ur+="S")Ee(ur,js);function RI(e,t){t[Ir]=Qe(("0."+e)*1e3)}for(ur="S";ur.length<=9;ur+="S")Tt(ur,RI);dv=Ws("Milliseconds",!1);Le("z",0,0,"zoneAbbr");Le("zz",0,0,"zoneName");function kI(){return this._isUTC?"UTC":""}function TI(){return this._isUTC?"Coordinated Universal Time":""}var ye=fa.prototype;ye.add=bM;ye.calendar=kM;ye.clone=TM;ye.diff=NM;ye.endOf=zM;ye.format=$M;ye.from=VM;ye.fromNow=jM;ye.to=BM;ye.toNow=WM;ye.get=LD;ye.invalidAt=JM;ye.isAfter=EM;ye.isBefore=PM;ye.isBetween=DM;ye.isSame=OM;ye.isSameOrAfter=MM;ye.isSameOrBefore=IM;ye.isValid=ZM;ye.lang=ov;ye.locale=nv;ye.localeData=rv;ye.max=ZO;ye.min=XO;ye.parsingFlags=QM;ye.set=$D;ye.startOf=HM;ye.subtract=wM;ye.toArray=GM;ye.toObject=KM;ye.toDate=qM;ye.toISOString=FM;ye.inspect=LM;typeof Symbol<"u"&&Symbol.for!=null&&(ye[Symbol.for("nodejs.util.inspect.custom")]=function(){return"Moment<"+this.format()+">"});ye.toJSON=XM;ye.toString=AM;ye.unix=UM;ye.valueOf=YM;ye.creationData=eI;ye.eraName=rI;ye.eraNarrow=sI;ye.eraAbbr=iI;ye.eraYear=aI;ye.year=Ny;ye.isLeapYear=FD;ye.weekYear=pI;ye.isoWeekYear=mI;ye.quarter=ye.quarters=CI;ye.month=Vy;ye.daysInMonth=qD;ye.week=ye.weeks=tO;ye.isoWeek=ye.isoWeeks=nO;ye.weeksInYear=vI;ye.weeksInWeekYear=bI;ye.isoWeeksInYear=gI;ye.isoWeeksInISOWeekYear=yI;ye.date=cv;ye.day=ye.days=mO;ye.weekday=gO;ye.isoWeekday=yO;ye.dayOfYear=SI;ye.hour=ye.hours=xO;ye.minute=ye.minutes=_I;ye.second=ye.seconds=xI;ye.millisecond=ye.milliseconds=dv;ye.utcOffset=iM;ye.utc=lM;ye.local=cM;ye.parseZone=dM;ye.hasAlignedHourOffset=uM;ye.isDST=hM;ye.isLocal=pM;ye.isUtcOffset=mM;ye.isUtc=Qy;ye.isUTC=Qy;ye.zoneAbbr=kI;ye.zoneName=TI;ye.dates=Jn("dates accessor is deprecated. Use date instead.",cv);ye.months=Jn("months accessor is deprecated. Use month instead",Vy);ye.years=Jn("years accessor is deprecated. Use year instead",Ny);ye.zone=Jn("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",aM);ye.isDSTShifted=Jn("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",fM);function EI(e){return Ot(e*1e3)}function PI(){return Ot.apply(null,arguments).parseZone()}function uv(e){return e}var ht=Uu.prototype;ht.calendar=pD;ht.longDateFormat=vD;ht.invalidDate=wD;ht.ordinal=_D;ht.preparse=uv;ht.postformat=uv;ht.relativeTime=RD;ht.pastFuture=kD;ht.set=hD;ht.eras=tI;ht.erasParse=nI;ht.erasConvertYear=oI;ht.erasAbbrRegex=cI;ht.erasNameRegex=lI;ht.erasNarrowRegex=dI;ht.months=HD;ht.monthsShort=zD;ht.monthsParse=UD;ht.monthsRegex=KD;ht.monthsShortRegex=GD;ht.week=ZD;ht.firstDayOfYear=eO;ht.firstDayOfWeek=JD;ht.weekdays=dO;ht.weekdaysMin=hO;ht.weekdaysShort=uO;ht.weekdaysParse=pO;ht.weekdaysRegex=vO;ht.weekdaysShortRegex=bO;ht.weekdaysMinRegex=wO;ht.isPM=SO;ht.meridiem=RO;function xl(e,t,n,o){var r=nr(),i=Oo().set(o,t);return r[n](i,e)}function hv(e,t,n){if(Jo(e)&&(t=e,e=void 0),e=e||"",t!=null)return xl(e,t,n,"month");var o,r=[];for(o=0;o<12;o++)r[o]=xl(e,o,n,"month");return r}function dh(e,t,n,o){typeof e=="boolean"?(Jo(t)&&(n=t,t=void 0),t=t||""):(t=e,n=t,e=!1,Jo(t)&&(n=t,t=void 0),t=t||"");var r=nr(),i=e?r._week.dow:0,a,l=[];if(n!=null)return xl(t,(n+i)%7,o,"day");for(a=0;a<7;a++)l[a]=xl(t,(a+i)%7,o,"day");return l}function DI(e,t){return hv(e,t,"months")}function OI(e,t){return hv(e,t,"monthsShort")}function MI(e,t,n){return dh(e,t,n,"weekdays")}function II(e,t,n){return dh(e,t,n,"weekdaysShort")}function NI(e,t,n){return dh(e,t,n,"weekdaysMin")}hr("en",{eras:[{since:"0001-01-01",until:1/0,offset:1,name:"Anno Domini",narrow:"AD",abbr:"AD"},{since:"0000-12-31",until:-1/0,offset:1,name:"Before Christ",narrow:"BC",abbr:"BC"}],dayOfMonthOrdinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(e){var t=e%10,n=Qe(e%100/10)===1?"th":t===1?"st":t===2?"nd":t===3?"rd":"th";return e+n}});_e.lang=Jn("moment.lang is deprecated. Use moment.locale instead.",hr);_e.langData=Jn("moment.langData is deprecated. Use moment.localeData instead.",nr);var jo=Math.abs;function AI(){var e=this._data;return this._milliseconds=jo(this._milliseconds),this._days=jo(this._days),this._months=jo(this._months),e.milliseconds=jo(e.milliseconds),e.seconds=jo(e.seconds),e.minutes=jo(e.minutes),e.hours=jo(e.hours),e.months=jo(e.months),e.years=jo(e.years),this}function fv(e,t,n,o){var r=co(t,n);return e._milliseconds+=o*r._milliseconds,e._days+=o*r._days,e._months+=o*r._months,e._bubble()}function FI(e,t){return fv(this,e,t,1)}function LI(e,t){return fv(this,e,t,-1)}function tm(e){return e<0?Math.floor(e):Math.ceil(e)}function $I(){var e=this._milliseconds,t=this._days,n=this._months,o=this._data,r,i,a,l,d;return e>=0&&t>=0&&n>=0||e<=0&&t<=0&&n<=0||(e+=tm(Qd(n)+t)*864e5,t=0,n=0),o.milliseconds=e%1e3,r=Un(e/1e3),o.seconds=r%60,i=Un(r/60),o.minutes=i%60,a=Un(i/60),o.hours=a%24,t+=Un(a/24),d=Un(pv(t)),n+=d,t-=tm(Qd(d)),l=Un(n/12),n%=12,o.days=t,o.months=n,o.years=l,this}function pv(e){return e*4800/146097}function Qd(e){return e*146097/4800}function VI(e){if(!this.isValid())return NaN;var t,n,o=this._milliseconds;if(e=eo(e),e==="month"||e==="quarter"||e==="year")switch(t=this._days+o/864e5,n=this._months+pv(t),e){case"month":return n;case"quarter":return n/3;case"year":return n/12}else switch(t=this._days+Math.round(Qd(this._months)),e){case"week":return t/7+o/6048e5;case"day":return t+o/864e5;case"hour":return t*24+o/36e5;case"minute":return t*1440+o/6e4;case"second":return t*86400+o/1e3;case"millisecond":return Math.floor(t*864e5)+o;default:throw new Error("Unknown unit "+e)}}function or(e){return function(){return this.as(e)}}var mv=or("ms"),jI=or("s"),BI=or("m"),WI=or("h"),HI=or("d"),zI=or("w"),YI=or("M"),UI=or("Q"),qI=or("y"),GI=mv;function KI(){return co(this)}function XI(e){return e=eo(e),this.isValid()?this[e+"s"]():NaN}function Hr(e){return function(){return this.isValid()?this._data[e]:NaN}}var ZI=Hr("milliseconds"),QI=Hr("seconds"),JI=Hr("minutes"),eN=Hr("hours"),tN=Hr("days"),nN=Hr("months"),oN=Hr("years");function rN(){return Un(this.days()/7)}var Wo=Math.round,ps={ss:44,s:45,m:45,h:22,d:26,w:null,M:11};function sN(e,t,n,o,r){return r.relativeTime(t||1,!!n,e,o)}function iN(e,t,n,o){var r=co(e).abs(),i=Wo(r.as("s")),a=Wo(r.as("m")),l=Wo(r.as("h")),d=Wo(r.as("d")),u=Wo(r.as("M")),f=Wo(r.as("w")),p=Wo(r.as("y")),y=i<=n.ss&&["s",i]||i<n.s&&["ss",i]||a<=1&&["m"]||a<n.m&&["mm",a]||l<=1&&["h"]||l<n.h&&["hh",l]||d<=1&&["d"]||d<n.d&&["dd",d];return n.w!=null&&(y=y||f<=1&&["w"]||f<n.w&&["ww",f]),y=y||u<=1&&["M"]||u<n.M&&["MM",u]||p<=1&&["y"]||["yy",p],y[2]=t,y[3]=+e>0,y[4]=o,sN.apply(null,y)}function aN(e){return e===void 0?Wo:typeof e=="function"?(Wo=e,!0):!1}function lN(e,t){return ps[e]===void 0?!1:t===void 0?ps[e]:(ps[e]=t,e==="s"&&(ps.ss=t-1),!0)}function cN(e,t){if(!this.isValid())return this.localeData().invalidDate();var n=!1,o=ps,r,i;return typeof e=="object"&&(t=e,e=!1),typeof e=="boolean"&&(n=e),typeof t=="object"&&(o=Object.assign({},ps,t),t.s!=null&&t.ss==null&&(o.ss=t.s-1)),r=this.localeData(),i=iN(this,!n,o,r),n&&(i=r.pastFuture(+this,i)),r.postformat(i)}var ud=Math.abs;function ls(e){return(e>0)-(e<0)||+e}function hc(){if(!this.isValid())return this.localeData().invalidDate();var e=ud(this._milliseconds)/1e3,t=ud(this._days),n=ud(this._months),o,r,i,a,l=this.asSeconds(),d,u,f,p;return l?(o=Un(e/60),r=Un(o/60),e%=60,o%=60,i=Un(n/12),n%=12,a=e?e.toFixed(3).replace(/\.?0+$/,""):"",d=l<0?"-":"",u=ls(this._months)!==ls(l)?"-":"",f=ls(this._days)!==ls(l)?"-":"",p=ls(this._milliseconds)!==ls(l)?"-":"",d+"P"+(i?u+i+"Y":"")+(n?u+n+"M":"")+(t?f+t+"D":"")+(r||o||e?"T":"")+(r?p+r+"H":"")+(o?p+o+"M":"")+(e?p+a+"S":"")):"P0D"}var rt=dc.prototype;rt.isValid=nM;rt.abs=AI;rt.add=FI;rt.subtract=LI;rt.as=VI;rt.asMilliseconds=mv;rt.asSeconds=jI;rt.asMinutes=BI;rt.asHours=WI;rt.asDays=HI;rt.asWeeks=zI;rt.asMonths=YI;rt.asQuarters=UI;rt.asYears=qI;rt.valueOf=GI;rt._bubble=$I;rt.clone=KI;rt.get=XI;rt.milliseconds=ZI;rt.seconds=QI;rt.minutes=JI;rt.hours=eN;rt.days=tN;rt.weeks=rN;rt.months=nN;rt.years=oN;rt.humanize=cN;rt.toISOString=hc;rt.toString=hc;rt.toJSON=hc;rt.locale=nv;rt.localeData=rv;rt.toIsoString=Jn("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",hc);rt.lang=ov;Le("X",0,0,"unix");Le("x",0,0,"valueOf");Ee("x",ic);Ee("X",DD);Tt("X",function(e,t,n){n._d=new Date(parseFloat(e)*1e3)});Tt("x",function(e,t,n){n._d=new Date(Qe(e))});//! moment.js
|
|
274
|
-
_e.version="2.30.1";dD(Ot);_e.fn=ye;_e.min=QO;_e.max=JO;_e.now=eM;_e.utc=Oo;_e.unix=EI;_e.months=DI;_e.isDate=ha;_e.locale=hr;_e.invalid=nc;_e.duration=co;_e.isMoment=ao;_e.weekdays=MI;_e.parseZone=PI;_e.localeData=nr;_e.isDuration=sl;_e.monthsShort=OI;_e.weekdaysMin=NI;_e.defineLocale=nh;_e.updateLocale=PO;_e.locales=DO;_e.weekdaysShort=II;_e.normalizeUnits=eo;_e.relativeTimeRounding=aN;_e.relativeTimeThreshold=lN;_e.calendarFormat=RM;_e.prototype=ye;_e.HTML5_FMT={DATETIME_LOCAL:"YYYY-MM-DDTHH:mm",DATETIME_LOCAL_SECONDS:"YYYY-MM-DDTHH:mm:ss",DATETIME_LOCAL_MS:"YYYY-MM-DDTHH:mm:ss.SSS",DATE:"YYYY-MM-DD",TIME:"HH:mm",TIME_SECONDS:"HH:mm:ss",TIME_MS:"HH:mm:ss.SSS",WEEK:"GGGG-[W]WW",MONTH:"YYYY-MM"};const dN=Object.freeze(Object.defineProperty({__proto__:null,default:_e},Symbol.toStringTag,{value:"Module"})),uN=[_e.ISO_8601,jr.ui,jr.db],Jd="Invalid date";ae(Bg)({width:"100%","& .MuiAlert-message":{fontSize:"0.8rem"}," [data-testid=CloseIcon]":{fill:"white"}});let gv=class{constructor(){this._args={},this._grid=null,this._tableId=""}getFilterFn(){return()=>!0}register(t,n){this.tableId=n,this.grid=t;const o=t.getData();o.setFilter(this.getFilterFn()),o.setFilterArgs(this.args),o.refresh()}reset(){if(!this.grid)return;this.args={};const t=this.grid.getData();t.setFilterArgs(this.args),t.refresh()}print(){return[]}set grid(t){this._grid=t}get grid(){return this._grid}set args(t){if(this._args=t,!this.grid)return;const n=this.grid.getData();n.setFilterArgs(t),n.refresh()}get args(){return this._args}set tableId(t){this._tableId=t}get tableId(){return this._tableId}};class hN extends gv{getFilterFn(){return t=>!t?.isDeleted}}class fN{constructor(){this._args={},this._grid=null,this._tableId=""}getFilterFn(){return()=>!0}register(){}print(){return[]}reset(){}get args(){return this._args}get grid(){return this._grid}get tableId(){return this._tableId}set args(t){}set grid(t){}set tableId(t){}}function ms(e){return new Date(e).getTime()}class yv{constructor(t){this.filter=t}getFilterFn(){const t=this.filter.getFilterFn();return(n,o)=>this.filterFn(n,o)&&t(n,o)}register(t,n){this.tableId=n,this.grid=t;const o=t.getData();o.setFilter(this.getFilterFn()),o.setFilterArgs(this.args),o.refresh()}reset(){this.filter.reset()}print(t){return this.filter.print(t)}set args(t){this.filter.args=t}set grid(t){this.filter.grid=t}set tableId(t){this.filter.tableId=t}get args(){return this.filter.args}get grid(){return this.filter.grid}get tableId(){return this.filter.tableId}}function pN(e){return{tooltip:"Apply column filter",command:e}}class fc{constructor(){this.observers=[]}subscribe(t){~this.observers.indexOf(t)||this.observers.push(t)}unsubscribe(t){const n=this.observers.indexOf(t);~this.observers.indexOf(t)&&this.observers.splice(n,1)}notify(){for(const t of this.observers)t()}}class mN extends fc{constructor(){super(...arguments),this.columnId="",this.group=sn.Text,this.target=null,this.x=0,this.y=0}}const wn=new mN;class gN{highlightAllColumns(t,n){const o=document.getElementById(n);if(!o)return;const r=Object.keys(t.columnFilters||{});if(r.length)for(const i of r){const a=o.querySelector(`[data-id="${i}"]`);a&&(t.columnFilters[i].value[1]||t.columnFilters[i].value[2]?a.classList.add("filter-active"):a.classList.remove("filter-active"))}else{const i=o.querySelectorAll(".slick-header-column");for(const a of i)a.classList.remove("filter-active")}}highlightColumn(t,n){const o=document.getElementById(t.id);if(!o)return;const r=o.querySelector(`[data-id="${n}"]`);r&&r.classList.add("filter-active")}resetColumn(t,n){const o=document.getElementById(t.id);if(!o)return;const r=o.querySelector(`[data-id="${n}"]`);r&&r.classList.remove("filter-active")}}const er=new gN;function vv(e){return er.highlightAllColumns(e.filter.args,e.id),function(t,n){t.preventDefault(),wn.columnId=n.column.id||"",wn.group=n.command,wn.table=e,wn.target=t.target,wn.x=t.x||0,wn.y=t.y||0,wn.notify()}}var yN=Object.defineProperty,vN=(e,t,n)=>t in e?yN(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,T=(e,t,n)=>vN(e,typeof t!="symbol"?t+"":t,n),Ki=class{constructor(e,t){this.event=e,this.args=t,T(this,"_isPropagationStopped",!1),T(this,"_isImmediatePropagationStopped",!1),T(this,"_isDefaultPrevented",!1),T(this,"returnValues",[]),T(this,"returnValue"),T(this,"_eventTarget"),T(this,"nativeEvent"),T(this,"arguments_"),T(this,"altKey"),T(this,"ctrlKey"),T(this,"metaKey"),T(this,"shiftKey"),T(this,"key"),T(this,"keyCode"),T(this,"clientX"),T(this,"clientY"),T(this,"offsetX"),T(this,"offsetY"),T(this,"pageX"),T(this,"pageY"),T(this,"bubbles"),T(this,"target"),T(this,"type"),T(this,"which"),T(this,"x"),T(this,"y"),this.nativeEvent=e,this.arguments_=t,e&&["altKey","ctrlKey","metaKey","shiftKey","key","keyCode","clientX","clientY","offsetX","offsetY","pageX","pageY","bubbles","target","type","which","x","y"].forEach(n=>this[n]=e[n]),this._eventTarget=this.nativeEvent?this.nativeEvent.target:void 0}get defaultPrevented(){return this._isDefaultPrevented}stopPropagation(){this._isPropagationStopped=!0,this.nativeEvent?.stopPropagation()}isPropagationStopped(){return this._isPropagationStopped}stopImmediatePropagation(){this._isImmediatePropagationStopped=!0,this.nativeEvent&&this.nativeEvent.stopImmediatePropagation()}isImmediatePropagationStopped(){return this._isImmediatePropagationStopped}getNativeEvent(){return this.nativeEvent}preventDefault(){this.nativeEvent&&this.nativeEvent.preventDefault(),this._isDefaultPrevented=!0}isDefaultPrevented(){return this.nativeEvent?this.nativeEvent.defaultPrevented:this._isDefaultPrevented}addReturnValue(e){this.returnValues.push(e),this.returnValue===void 0&&e!==void 0&&(this.returnValue=e)}getReturnValue(){return this.returnValue}getArguments(){return this.arguments_}},zr=class{constructor(e,t){this.eventName=e,this.pubSub=t,T(this,"_handlers",[]),T(this,"_pubSubService"),this._pubSubService=t}get subscriberCount(){return this._handlers.length}subscribe(e){this._handlers.push(e)}unsubscribe(e){for(let t=this._handlers.length-1;t>=0;t--)this._handlers[t]===e&&this._handlers.splice(t,1)}notify(e,t,n){let o=t instanceof Ki?t:new Ki(t,e);n=n||this;for(let r=0;r<this._handlers.length&&!(o.isPropagationStopped()||o.isImmediatePropagationStopped());r++){let i=this._handlers[r].call(n,o,e);o.addReturnValue(i)}if(typeof this._pubSubService?.publish=="function"&&this.eventName){let r=this._pubSubService.publish(this.eventName,{args:e,eventData:o});o.addReturnValue(r)}return o}setPubSubService(e){this._pubSubService=e}},ga=class{constructor(){T(this,"handlers",[])}subscribe(e,t){return this.handlers.push({event:e,handler:t}),e.subscribe(t),this}unsubscribe(e,t){let n=this.handlers.length;for(;n--;)if(this.handlers[n].event===e&&this.handlers[n].handler===t){this.handlers.splice(n,1),e.unsubscribe(t);return}return this}unsubscribeAll(){let e=this.handlers.length;for(;e--;)this.handlers[e].event.unsubscribe(this.handlers[e].handler);return this.handlers=[],this}},uh=class{constructor(e,t,n,o){T(this,"fromRow"),T(this,"fromCell"),T(this,"toCell"),T(this,"toRow"),n===void 0&&o===void 0&&(n=e,o=t),this.fromRow=Math.min(e,n),this.fromCell=Math.min(t,o),this.toCell=Math.max(t,o),this.toRow=Math.max(e,n)}isSingleRow(){return this.fromRow===this.toRow}isSingleCell(){return this.fromRow===this.toRow&&this.fromCell===this.toCell}contains(e,t){return e>=this.fromRow&&e<=this.toRow&&t>=this.fromCell&&t<=this.toCell}toString(){return this.isSingleCell()?`(${this.fromRow}:${this.fromCell})`:`(${this.fromRow}:${this.fromCell} - ${this.toRow}:${this.toCell})`}},bv=class{constructor(){T(this,"__nonDataRow",!0)}},wv=class extends bv{constructor(){super(),T(this,"__group",!0),T(this,"level",0),T(this,"count",0),T(this,"value",null),T(this,"title",null),T(this,"collapsed",!1),T(this,"selectChecked",!1),T(this,"totals",null),T(this,"rows",[]),T(this,"groups",null),T(this,"groupingKey",null)}equals(e){return this.value===e.value&&this.count===e.count&&this.collapsed===e.collapsed&&this.title===e.title}},bN=class extends bv{constructor(){super(),T(this,"__groupTotals",!0),T(this,"group",null),T(this,"initialized",!1)}},wN=class{constructor(){T(this,"activeEditController",null)}isActive(e){return e?this.activeEditController===e:this.activeEditController!==null}activate(e){if(e!==this.activeEditController){if(this.activeEditController!==null)throw new Error("Slick.EditorLock.activate: an editController is still active, can't activate another editController");if(!e.commitCurrentEdit)throw new Error("Slick.EditorLock.activate: editController must implement .commitCurrentEdit()");if(!e.cancelCurrentEdit)throw new Error("Slick.EditorLock.activate: editController must implement .cancelCurrentEdit()");this.activeEditController=e}}deactivate(e){if(this.activeEditController){if(this.activeEditController!==e)throw new Error("Slick.EditorLock.deactivate: specified editController is not the currently active one");this.activeEditController=null}}commitCurrentEdit(){return this.activeEditController?this.activeEditController.commitCurrentEdit():!0}cancelCurrentEdit(){return this.activeEditController?this.activeEditController.cancelCurrentEdit():!0}},pc=class{constructor(){T(this,"_boundedEvents",[])}getBoundedEvents(){return this._boundedEvents}destroy(){this.unbindAll()}bind(e,t,n,o,r=""){e&&(e.addEventListener(t,n,o),this._boundedEvents.push({element:e,eventName:t,listener:n,groupName:r}))}unbind(e,t,n){e?.removeEventListener&&e.removeEventListener(t,n)}unbindByEventName(e,t){let n=this._boundedEvents.find(o=>o.element===e&&o.eventName===t);n&&this.unbind(n.element,n.eventName,n.listener)}unbindAll(e){if(e){let t=Array.isArray(e)?e:[e];for(let n=this._boundedEvents.length-1;n>=0;--n){let o=this._boundedEvents[n];if(t.some(r=>r===o.groupName)){let{element:r,eventName:i,listener:a}=o;this.unbind(r,i,a),this._boundedEvents.splice(n,1)}}}else for(;this._boundedEvents.length>0;){let t=this._boundedEvents.pop(),{element:n,eventName:o,listener:r}=t;this.unbind(n,o,r)}}},Hn=class jt{static isFunction(t){return typeof t=="function"&&typeof t.nodeType!="number"&&typeof t.item!="function"}static isPlainObject(t){if(!t||jt.toString.call(t)!=="[object Object]")return!1;let n=jt.getProto(t);if(!n)return!0;let o=jt.hasOwn.call(n,"constructor")&&n.constructor;return typeof o=="function"&&jt.fnToString.call(o)===jt.ObjectFunctionString}static calculateAvailableSpace(t){let n=0,o=0,r=0,i=0,a=window.innerHeight||0,l=window.innerWidth||0,d=jt.windowScrollPosition(),u=d.top,f=d.left,p=jt.offset(t);if(p){let y=p.top||0,b=p.left||0;o=y-u,n=a-(y-u),r=b-f,i=l-(b-f)}return{top:o,bottom:n,left:r,right:i}}static extend(...t){let n,o,r,i,a,l,d=t[0],u=1,f=!1,p=t.length;for(typeof d=="boolean"?(f=d,d=t[u]||{},u++):d=d||{},typeof d!="object"&&!jt.isFunction(d)&&(d={}),u===p&&(d=this,u--);u<p;u++)if(jt.isDefined(n=t[u]))for(o in n)i=n[o],!(o==="__proto__"||d===i)&&(f&&i&&(jt.isPlainObject(i)||(a=Array.isArray(i)))?(r=d[o],a&&!Array.isArray(r)?l=[]:!a&&!jt.isPlainObject(r)?l={}:l=r,a=!1,d[o]=jt.extend(f,l,i)):i!==void 0&&(d[o]=i));return d}static createDomElement(t,n,o){let r=document.createElement(t);return n&&Object.keys(n).forEach(i=>{i==="innerHTML"&&console.warn(`[SlickGrid] For better CSP (Content Security Policy) support, do not use "innerHTML" directly in "createDomElement('${t}', { innerHTML: 'some html'})", it is better as separate assignment: "const elm = createDomElement('span'); elm.innerHTML = 'some html';"`);let a=n[i];typeof a=="object"?Object.assign(r[i],a):r[i]=n[i]}),o?.appendChild&&o.appendChild(r),r}static getHtmlStringOutput(t,n="innerHTML"){return t instanceof DocumentFragment?[].map.call(t.childNodes,o=>o[n]).join("")||t.textContent||"":t instanceof HTMLElement?t[n]:String(t)}static emptyElement(t){for(;t?.firstChild;)t.removeChild(t.firstChild);return t}static classNameToList(t=""){return t.split(" ").filter(n=>n)}static innerSize(t,n){let o=0;if(t){let r=n==="height"?"clientHeight":"clientWidth",i=n==="height"?["top","bottom"]:["left","right"];o=t[r];for(let a of i){let l=parseFloat(jt.getElementProp(t,`padding-${a}`)||"")||0;o-=l}}return o}static isDefined(t){return t!=null&&t!==""}static getElementProp(t,n){return t?.getComputedStyle?window.getComputedStyle(t,null).getPropertyValue(n):null}static getFunctionDetails(t,n=!0){let o=!1,r=i=>{let a=i.toString();if(o=a.includes("async "),a.replaceAll(" ","").includes("=>({")){let u=a.match(/(({.*}))/g)||[];return u.length>=1?`return ${u[0].trimStart()}`:a}let l=!a.includes("{")&&a.includes("=>"),d=a.substring(a.indexOf("{")+1||a.indexOf("=>")+2,a.includes("}")?a.lastIndexOf("}"):a.length);return n&&l&&!d.startsWith("return")?"return "+d.trimStart():d};return{params:(i=>{let a=/(\/\/.*$)|(\/\*[\s\S]*?\*\/)|(\s*=[^,)]*(('(?:\\'|[^'\r\n])*')|("(?:\\"|[^"\r\n])*"))|(\s*=[^,)]*))/mg,l=/([^\s,]+)/g,d=i.toString().replace(a,"");return d.slice(d.indexOf("(")+1,d.indexOf(")")).match(l)??[]})(t),body:r(t),isAsync:o}}static insertAfterElement(t,n){t.parentNode?.insertBefore(n,t.nextSibling)}static isEmptyObject(t){return t==null?!0:Object.entries(t).length===0}static noop(){}static offset(t){if(!t||!t.getBoundingClientRect)return;let n=t.getBoundingClientRect(),o=document.documentElement;return{top:n.top+window.pageYOffset-o.clientTop,left:n.left+window.pageXOffset-o.clientLeft}}static windowScrollPosition(){return{left:window.pageXOffset||document.documentElement.scrollLeft||0,top:window.pageYOffset||document.documentElement.scrollTop||0}}static width(t,n){if(!(!t||!t.getBoundingClientRect)){if(n===void 0)return t.getBoundingClientRect().width;jt.setStyleSize(t,"width",n)}}static height(t,n){if(t){if(n===void 0)return t.getBoundingClientRect().height;jt.setStyleSize(t,"height",n)}}static setStyleSize(t,n,o){typeof o=="function"?o=o():typeof o=="string"?t.style[n]=o:t.style[n]=o+"px"}static contains(t,n){return!t||!n?!1:!jt.parents(n).every(o=>t!==o)}static isHidden(t){return t.offsetWidth===0&&t.offsetHeight===0}static parents(t,n){let o=[],r=n===":visible",i=n===":hidden";for(;(t=t.parentNode)&&t!==document&&!(!t||!t.parentNode);)i?jt.isHidden(t)&&o.push(t):r?jt.isHidden(t)||o.push(t):(!n||t.matches(n))&&o.push(t);return o}static toFloat(t){let n=parseFloat(t);return isNaN(n)?0:n}static show(t,n=""){Array.isArray(t)?t.forEach(o=>o.style.display=n):t.style.display=n}static hide(t){Array.isArray(t)?t.forEach(n=>n.style.display="none"):t.style.display="none"}static slideUp(t,n){return jt.slideAnimation(t,"slideUp",n)}static slideDown(t,n){return jt.slideAnimation(t,"slideDown",n)}static slideAnimation(t,n,o){if(window.jQuery!==void 0){window.jQuery(t)[n]("fast",o);return}n==="slideUp"?jt.hide(t):jt.show(t),o()}static applyDefaults(t,n){typeof n=="object"&&Object.keys(n).forEach(o=>{n.hasOwnProperty(o)&&!t.hasOwnProperty(o)&&(t[o]=n[o])})}static addSlickEventPubSubWhenDefined(t,n){if(t)for(let o in n)n[o]instanceof zr&&typeof n[o].setPubSubService=="function"&&n[o].setPubSubService(t)}};T(Hn,"getProto",Object.getPrototypeOf),T(Hn,"class2type",{}),T(Hn,"toString",Hn.class2type.toString),T(Hn,"hasOwn",Hn.class2type.hasOwnProperty),T(Hn,"fnToString",Hn.hasOwn.toString),T(Hn,"ObjectFunctionString",Hn.fnToString.call(Object)),T(Hn,"storage",{_storage:new WeakMap,put:function(e,t,n){this._storage.has(e)||this._storage.set(e,new Map),this._storage.get(e).set(t,n)},get:function(e,t){let n=this._storage.get(e);return n?n.get(t):null},remove:function(e,t){let n=this._storage.get(e).delete(t);return this._storage.get(e).size!==0&&this._storage.delete(e),n}});var uo=Hn,Cv=new wN,CN={Event:zr,EventHandler:ga,GlobalEditorLock:Cv,keyCode:{SPACE:8,DOWN:40,ENTER:13,ESCAPE:27,LEFT:37,PAGE_DOWN:34,PAGE_UP:33,RIGHT:39,TAB:9,UP:38},preClickClassName:"slick-edit-preclick",GridAutosizeColsMode:{None:"NOA",LegacyOff:"LOF",LegacyForceFit:"LFF",IgnoreViewport:"IGV",FitColsToViewport:"FCV",FitViewportToCols:"FVC"},ColAutosizeMode:{Locked:"LCK",Guide:"GUI",ContentExpandOnly:"CXO",ContentIntelligent:"CTI"},RowSelectionMode:{FirstRow:"FS1",FirstNRows:"FSN",AllRows:"ALL",LastRow:"LS1"},ValueFilterMode:{None:"NONE",DeDuplicate:"DEDP",GetGreatestAndSub:"GR8T",GetLongestTextAndSub:"LNSB",GetLongestText:"LNSC"},WidthEvalMode:{Auto:"AUTO",TextOnly:"CANV"}},{Event:SN,EventHandler:_N,GlobalEditorLock:xN,keyCode:Lr,preClickClassName:RN,GridAutosizeColsMode:Sv,ColAutosizeMode:kN,RowSelectionMode:TN,ValueFilterMode:EN,WidthEvalMode:PN}=CN,DN=uo,_v=class{constructor(e,t){this.grid=e,T(this,"pluginName","CellRangeDecorator"),T(this,"_options"),T(this,"_elem"),T(this,"_defaults",{selectionCssClass:"slick-range-decorator",selectionCss:{zIndex:"9999",border:"2px dashed red"},offset:{top:-1,left:-1,height:-2,width:-2}}),this._options=DN.extend(!0,{},this._defaults,t)}destroy(){this.hide()}init(){}hide(){this._elem?.remove(),this._elem=null}show(e){if(!this._elem){this._elem=document.createElement("div"),this._elem.className=this._options.selectionCssClass,Object.keys(this._options.selectionCss).forEach(r=>{this._elem.style[r]=this._options.selectionCss[r]}),this._elem.style.position="absolute";let o=this.grid.getActiveCanvasNode();o&&o.appendChild(this._elem)}let t=this.grid.getCellNodeBox(e.fromRow,e.fromCell),n=this.grid.getCellNodeBox(e.toRow,e.toCell);return t&&n&&this._options?.offset&&(this._elem.style.top=`${t.top+this._options.offset.top}px`,this._elem.style.left=`${t.left+this._options.offset.left}px`,this._elem.style.height=`${n.bottom-t.top+this._options.offset.height}px`,this._elem.style.width=`${n.right-t.left+this._options.offset.width}px`),this._elem}},ON=uo;function hh(e){let{containerElement:t}=e,{onDragInit:n,onDragStart:o,onDrag:r,onDragEnd:i,preventDragFromKeys:a}=e,l,d,u,f,p,y;t||(t=document.body);let b={dragSource:t,dragHandle:null};function w(){t&&(t.addEventListener("mousedown",P),t.addEventListener("touchstart",P))}function g(C,O,N){if(typeof C=="function")return C(O,N)}function v(){t&&(t.removeEventListener("mousedown",P),t.removeEventListener("touchstart",P))}function E(C){let O=!1;return a&&a.forEach(N=>{C[N]&&(O=!0)}),O}function P(C){if(!E(C)){l=C.target;let O=C?.touches?.[0]??C,{target:N}=O;if(!e.allowDragFrom||e.allowDragFrom&&l.matches(e.allowDragFrom)||e.allowDragFromClosest&&l.closest(e.allowDragFromClosest)){b.dragHandle=l;let F=ON.windowScrollPosition();d=F.left+O.clientX,u=F.top+O.clientY,f=O.clientX-O.clientX,p=O.clientY-O.clientY,b=Object.assign(b,{deltaX:f,deltaY:p,startX:d,startY:u,target:N}),g(n,C,b)!==!1&&(document.body.addEventListener("mousemove",x),document.body.addEventListener("touchmove",x),document.body.addEventListener("mouseup",S),document.body.addEventListener("touchend",S),document.body.addEventListener("touchcancel",S))}}}function x(C){if(!E(C)){let O=C?.touches?.[0]??C;f=O.clientX-d,p=O.clientY-u;let{target:N}=O;y||(b=Object.assign(b,{deltaX:f,deltaY:p,startX:d,startY:u,target:N}),g(o,C,b),y=!0),b=Object.assign(b,{deltaX:f,deltaY:p,startX:d,startY:u,target:N}),g(r,C,b)}}function S(C){if(document.body.removeEventListener("mousemove",x),document.body.removeEventListener("touchmove",x),document.body.removeEventListener("mouseup",S),document.body.removeEventListener("touchend",S),document.body.removeEventListener("touchcancel",S),y){let{target:O}=C;b=Object.assign(b,{target:O}),g(i,C,b),y=!1}}return w(),{destroy:v}}function MN(e){let{element:t,onMouseWheel:n}=e;function o(){t.removeEventListener("wheel",i),t.removeEventListener("mousewheel",i)}function r(){t.addEventListener("wheel",i),t.addEventListener("mousewheel",i)}function i(a){let l=a||window.event,d=0,u=0,f=0;l.wheelDelta&&(d=l.wheelDelta/120),l.detail&&(d=-l.detail/3),f=d,l.axis!==void 0&&l.axis===l.HORIZONTAL_AXIS&&(f=0,u=-1*d),l.wheelDeltaY!==void 0&&(f=l.wheelDeltaY/120),l.wheelDeltaX!==void 0&&(u=-1*l.wheelDeltaX/120),typeof n=="function"&&n(a,d,u,f)}return r(),{destroy:o}}function IN(e){let{resizeableElement:t,resizeableHandleElement:n,onResizeStart:o,onResize:r,onResizeEnd:i}=e;if(!n||typeof n.addEventListener!="function")throw new Error("[Slick.Resizable] You did not provide a valid html element that will be used for the handle to resize.");function a(){n.addEventListener("mousedown",u),n.addEventListener("touchstart",u)}function l(){typeof n?.removeEventListener=="function"&&(n.removeEventListener("mousedown",u),n.removeEventListener("touchstart",u))}function d(y,b){if(typeof y=="function")return y(b,{resizeableElement:t,resizeableHandleElement:n})}function u(y){y.preventDefault();let b=y.touches?y.changedTouches[0]:y;d(o,b)!==!1&&(document.body.addEventListener("mousemove",f),document.body.addEventListener("mouseup",p),document.body.addEventListener("touchmove",f),document.body.addEventListener("touchend",p))}function f(y){y.preventDefault&&y.type!=="touchmove"&&y.preventDefault();let b=y.touches?y.changedTouches[0]:y;typeof r=="function"&&r(b,{resizeableElement:t,resizeableHandleElement:n})}function p(y){let b=y.touches?y.changedTouches[0]:y;d(i,b),document.body.removeEventListener("mousemove",f),document.body.removeEventListener("mouseup",p),document.body.removeEventListener("touchmove",f),document.body.removeEventListener("touchend",p)}return a(),{destroy:l}}var hd=zr,NN=ga,fd=uh,AN=hh,FN=_v,ii=uo,LN=class{constructor(e){T(this,"pluginName","CellRangeSelector"),T(this,"onBeforeCellRangeSelected",new hd("onBeforeCellRangeSelected")),T(this,"onCellRangeSelected",new hd("onCellRangeSelected")),T(this,"onCellRangeSelecting",new hd("onCellRangeSelecting")),T(this,"_grid"),T(this,"_currentlySelectedRange",null),T(this,"_canvas",null),T(this,"_decorator"),T(this,"_gridOptions"),T(this,"_activeCanvas"),T(this,"_dragging",!1),T(this,"_handler",new NN),T(this,"_options"),T(this,"_defaults",{autoScroll:!0,minIntervalToShowNextCell:30,maxIntervalToShowNextCell:600,accelerateInterval:5,selectionCss:{border:"2px dashed blue"}}),T(this,"_rowOffset",0),T(this,"_columnOffset",0),T(this,"_isRightCanvas",!1),T(this,"_isBottomCanvas",!1),T(this,"_activeViewport"),T(this,"_autoScrollTimerId"),T(this,"_draggingMouseOffset"),T(this,"_moveDistanceForOneCell"),T(this,"_xDelayForNextCell",0),T(this,"_yDelayForNextCell",0),T(this,"_viewportHeight",0),T(this,"_viewportWidth",0),T(this,"_isRowMoveRegistered",!1),T(this,"_scrollLeft",0),T(this,"_scrollTop",0),this._options=ii.extend(!0,{},this._defaults,e)}init(e){if(AN===void 0)throw new Error('Slick.Draggable is undefined, make sure to import "slick.interactions.js"');this._decorator=this._options.cellDecorator||new FN(e,this._options),this._grid=e,ii.addSlickEventPubSubWhenDefined(e.getPubSubService(),this),this._canvas=this._grid.getCanvasNode(),this._gridOptions=this._grid.getOptions(),this._handler.subscribe(this._grid.onScroll,this.handleScroll.bind(this)).subscribe(this._grid.onDragInit,this.handleDragInit.bind(this)).subscribe(this._grid.onDragStart,this.handleDragStart.bind(this)).subscribe(this._grid.onDrag,this.handleDrag.bind(this)).subscribe(this._grid.onDragEnd,this.handleDragEnd.bind(this))}destroy(){this._handler.unsubscribeAll(),this._activeCanvas=null,this._activeViewport=null,this._canvas=null,this._decorator?.destroy()}getCellDecorator(){return this._decorator}handleScroll(e,t){this._scrollTop=t.scrollTop,this._scrollLeft=t.scrollLeft}handleDragInit(e){this._activeCanvas=this._grid.getActiveCanvasNode(e),this._activeViewport=this._grid.getActiveViewportNode(e);let t=this._grid.getDisplayedScrollbarDimensions();if(this._viewportWidth=this._activeViewport.offsetWidth-t.width,this._viewportHeight=this._activeViewport.offsetHeight-t.height,this._moveDistanceForOneCell={x:this._grid.getAbsoluteColumnMinWidth()/2,y:this._grid.getOptions().rowHeight/2},this._isRowMoveRegistered=this.hasRowMoveManager(),this._rowOffset=0,this._columnOffset=0,this._isBottomCanvas=this._activeCanvas.classList.contains("grid-canvas-bottom"),this._gridOptions.frozenRow>-1&&this._isBottomCanvas){let n=`.${this._grid.getUID()} .grid-canvas-${this._gridOptions.frozenBottom?"bottom":"top"}`,o=document.querySelector(n);o&&(this._rowOffset=o.clientHeight||0)}if(this._isRightCanvas=this._activeCanvas.classList.contains("grid-canvas-right"),this._gridOptions.frozenColumn>-1&&this._isRightCanvas){let n=document.querySelector(`.${this._grid.getUID()} .grid-canvas-left`);n&&(this._columnOffset=n.clientWidth||0)}e.stopImmediatePropagation(),e.preventDefault()}handleDragStart(e,t){let n=this._grid.getCellFromEvent(e);if(n&&this.onBeforeCellRangeSelected.notify(n).getReturnValue()!==!1&&this._grid.canCellBeSelected(n.row,n.cell)&&(this._dragging=!0,e.stopImmediatePropagation()),!this._dragging)return;this._grid.focus();let o=ii.offset(this._canvas),r=t.startX-(o?.left??0);this._gridOptions.frozenColumn>=0&&this._isRightCanvas&&(r+=this._scrollLeft);let i=t.startY-(o?.top??0);this._gridOptions.frozenRow>=0&&this._isBottomCanvas&&(i+=this._scrollTop);let a=this._grid.getCellFromPoint(r,i);return t.range={start:a,end:{}},this._currentlySelectedRange=t.range,this._decorator.show(new fd(a.row,a.cell))}handleDrag(e,t){if(!this._dragging&&!this._isRowMoveRegistered)return;this._isRowMoveRegistered||e.stopImmediatePropagation();let n=e.getNativeEvent();if(this._options.autoScroll&&(this._draggingMouseOffset=this.getMouseOffsetViewport(n,t),this._draggingMouseOffset.isOutsideViewport))return this.handleDragOutsideViewport();this.stopIntervalTimer(),this.handleDragTo(n,t)}getMouseOffsetViewport(e,t){let n=e?.touches?.[0]??e,o=this._activeViewport.scrollLeft,r=this._activeViewport.scrollTop,i=o+this._viewportWidth,a=r+this._viewportHeight,l=ii.offset(this._activeViewport),d=l?.left??0,u=l?.top??0,f=d+this._viewportWidth,p=u+this._viewportHeight,y={e,dd:t,viewport:{left:o,top:r,right:i,bottom:a,offset:{left:d,top:u,right:f,bottom:p}},offset:{x:0,y:0},isOutsideViewport:!1};return n.pageX<d?y.offset.x=n.pageX-d:n.pageX>f&&(y.offset.x=n.pageX-f),n.pageY<u?y.offset.y=u-n.pageY:n.pageY>p&&(y.offset.y=p-n.pageY),y.isOutsideViewport=!!y.offset.x||!!y.offset.y,y}handleDragOutsideViewport(){if(this._xDelayForNextCell=this._options.maxIntervalToShowNextCell-Math.abs(this._draggingMouseOffset.offset.x)*this._options.accelerateInterval,this._yDelayForNextCell=this._options.maxIntervalToShowNextCell-Math.abs(this._draggingMouseOffset.offset.y)*this._options.accelerateInterval,!this._autoScrollTimerId){let e=0,t=0;this._autoScrollTimerId=window.setInterval(()=>{let n=!1,o=!1;this._draggingMouseOffset.offset.x?(e+=this._options.minIntervalToShowNextCell,n=e>=this._xDelayForNextCell):e=0,this._draggingMouseOffset.offset.y?(t+=this._options.minIntervalToShowNextCell,o=t>=this._yDelayForNextCell):t=0,(n||o)&&(n&&(e=0),o&&(t=0),this.handleDragToNewPosition(n,o))},this._options.minIntervalToShowNextCell)}}handleDragToNewPosition(e,t){let n=this._draggingMouseOffset.e.pageX,o=this._draggingMouseOffset.e.pageY,r=this._draggingMouseOffset.offset.x,i=this._draggingMouseOffset.offset.y,a=this._draggingMouseOffset.viewport.offset;e&&r&&(r>0?n=a.right+this._moveDistanceForOneCell.x:n=a.left-this._moveDistanceForOneCell.x),t&&i&&(i>0?o=a.top-this._moveDistanceForOneCell.y:o=a.bottom+this._moveDistanceForOneCell.y),this.handleDragTo({pageX:n,pageY:o},this._draggingMouseOffset.dd)}stopIntervalTimer(){this._autoScrollTimerId&&(window.clearInterval(this._autoScrollTimerId),this._autoScrollTimerId=void 0)}handleDragTo(e,t){let n=e?.touches?.[0]??e,o=ii.offset(this._activeCanvas),r=this._grid.getCellFromPoint(n.pageX-(o?.left??0)+this._columnOffset,n.pageY-(o?.top??0)+this._rowOffset);if(!(this._gridOptions.frozenColumn>=0&&!this._isRightCanvas&&r.cell>this._gridOptions.frozenColumn||this._isRightCanvas&&r.cell<=this._gridOptions.frozenColumn)&&!(this._gridOptions.frozenRow>=0&&!this._isBottomCanvas&&r.row>=this._gridOptions.frozenRow||this._isBottomCanvas&&r.row<this._gridOptions.frozenRow)){if(this._options.autoScroll&&this._draggingMouseOffset){let i=this._grid.getCellNodeBox(r.row,r.cell);if(!i)return;let a=this._draggingMouseOffset.viewport;(i.left<a.left||i.right>a.right||i.top<a.top||i.bottom>a.bottom)&&this._grid.scrollCellIntoView(r.row,r.cell)}if(this._grid.canCellBeSelected(r.row,r.cell)&&t?.range){t.range.end=r;let i=new fd(t.range.start.row??0,t.range.start.cell??0,r.row,r.cell);this._decorator.show(i),this.onCellRangeSelecting.notify({range:i})}}}hasRowMoveManager(){return!!(this._grid.getPluginByName("RowMoveManager")||this._grid.getPluginByName("CrossGridRowMoveManager"))}handleDragEnd(e,t){this._decorator.hide(),this._dragging&&(this._dragging=!1,e.stopImmediatePropagation(),this.stopIntervalTimer(),this.onCellRangeSelected.notify({range:new fd(t.range.start.row??0,t.range.start.cell??0,t.range.end.row,t.range.end.cell)}))}getCurrentRange(){return this._currentlySelectedRange}},$N=pc,VN=ga,lr=uo,jN=class{constructor(e){T(this,"pluginName","CheckboxSelectColumn"),T(this,"_dataView"),T(this,"_grid"),T(this,"_isUsingDataView",!1),T(this,"_selectableOverride",null),T(this,"_headerRowNode"),T(this,"_selectAll_UID"),T(this,"_handler",new VN),T(this,"_selectedRowsLookup",{}),T(this,"_checkboxColumnCellIndex",null),T(this,"_options"),T(this,"_defaults",{columnId:"_checkbox_selector",cssClass:void 0,hideSelectAllCheckbox:!1,name:"",toolTip:"Select/Deselect All",width:30,reorderable:!1,applySelectOnAllPages:!1,hideInColumnTitleRow:!1,hideInFilterHeaderRow:!0}),T(this,"_isSelectAllChecked",!1),T(this,"_bindingEventService"),this._bindingEventService=new $N,this._options=lr.extend(!0,{},this._defaults,e),this._selectAll_UID=this.createUID(),typeof this._options.selectableOverride=="function"&&this.selectableOverride(this._options.selectableOverride)}init(e){this._grid=e,this._isUsingDataView=!Array.isArray(e.getData()),this._isUsingDataView&&(this._dataView=e.getData()),this._handler.subscribe(this._grid.onSelectedRowsChanged,this.handleSelectedRowsChanged.bind(this)).subscribe(this._grid.onClick,this.handleClick.bind(this)).subscribe(this._grid.onKeyDown,this.handleKeyDown.bind(this)).subscribe(this._grid.onAfterSetColumns,()=>this.renderSelectAllCheckbox(this._isSelectAllChecked)),this._isUsingDataView&&this._dataView&&this._options.applySelectOnAllPages&&this._handler.subscribe(this._dataView.onSelectedRowIdsChanged,this.handleDataViewSelectedIdsChanged.bind(this)).subscribe(this._dataView.onPagingInfoChanged,this.handleDataViewSelectedIdsChanged.bind(this)),this._options.hideInFilterHeaderRow||this.addCheckboxToFilterHeaderRow(e),this._options.hideInColumnTitleRow||this._handler.subscribe(this._grid.onHeaderClick,this.handleHeaderClick.bind(this))}destroy(){this._handler.unsubscribeAll(),this._bindingEventService.unbindAll()}getOptions(){return this._options}setOptions(e){if(this._options=lr.extend(!0,{},this._options,e),this._options.hideSelectAllCheckbox)this.hideSelectAllFromColumnHeaderTitleRow(),this.hideSelectAllFromColumnHeaderFilterRow();else if(this._options.hideInColumnTitleRow?(this.hideSelectAllFromColumnHeaderTitleRow(),this._options.name&&this._grid.updateColumnHeader(this._options.columnId||"",this._options.name,"")):(this.renderSelectAllCheckbox(this._isSelectAllChecked),this._handler.subscribe(this._grid.onHeaderClick,this.handleHeaderClick.bind(this))),this._options.hideInFilterHeaderRow)this.hideSelectAllFromColumnHeaderFilterRow();else{let t=this._headerRowNode?.querySelector("#filter-checkbox-selectall-container");if(t){t.style.display="flex";let n=t.querySelector('input[type="checkbox"]');n&&(n.checked=this._isSelectAllChecked)}}}hideSelectAllFromColumnHeaderTitleRow(){this._grid.updateColumnHeader(this._options.columnId||"",this._options.name||"","")}hideSelectAllFromColumnHeaderFilterRow(){let e=this._headerRowNode?.querySelector("#filter-checkbox-selectall-container");e&&(e.style.display="none")}handleSelectedRowsChanged(){let e=this._grid.getSelectedRows(),t={},n=0,o=0,r=0,i=0;if(typeof this._selectableOverride=="function")for(r=0;r<this._grid.getDataLength();r++){let l=this._grid.getDataItem(r);this.checkSelectableOverride(o,l,this._grid)||i++}let a=[];for(o=0;o<e.length;o++){n=e[o];let l=this._grid.getDataItem(n);this.checkSelectableOverride(o,l,this._grid)?(t[n]=!0,t[n]!==this._selectedRowsLookup[n]&&(this._grid.invalidateRow(n),delete this._selectedRowsLookup[n])):a.push(n)}if(typeof this._selectedRowsLookup=="object"&&Object.keys(this._selectedRowsLookup).forEach(l=>{l!==void 0&&this._grid.invalidateRow(+l)}),this._selectedRowsLookup=t,this._grid.render(),this._isSelectAllChecked=(e?.length??0)+i>=this._grid.getDataLength(),(!this._isUsingDataView||!this._options.applySelectOnAllPages)&&(!this._options.hideInColumnTitleRow&&!this._options.hideSelectAllCheckbox&&this.renderSelectAllCheckbox(this._isSelectAllChecked),!this._options.hideInFilterHeaderRow)){let l=this._headerRowNode?.querySelector(`#header-filter-selector${this._selectAll_UID}`);l&&(l.checked=this._isSelectAllChecked)}if(a.length>0){for(o=0;o<a.length;o++){let l=e.indexOf(a[o]);e.splice(l,1)}this._grid.setSelectedRows(e,"click.cleanup")}}handleDataViewSelectedIdsChanged(){let e=this._dataView.getAllSelectedFilteredIds(),t=this._dataView.getFilteredItems(),n=0;if(typeof this._selectableOverride=="function"&&e.length>0)for(let o=0;o<this._dataView.getItemCount();o++){let r=this._dataView.getItemByIdx(o),i=this._dataView.getIdPropertyName(),a=r[i];t.findIndex(function(l){return l[i]===a})>=0&&!this.checkSelectableOverride(o,r,this._grid)&&n++}if(this._isSelectAllChecked=(e&&e.length)+n>=t.length,!this._options.hideInColumnTitleRow&&!this._options.hideSelectAllCheckbox&&this.renderSelectAllCheckbox(this._isSelectAllChecked),!this._options.hideInFilterHeaderRow){let o=this._headerRowNode?.querySelector(`#header-filter-selector${this._selectAll_UID}`);o&&(o.checked=this._isSelectAllChecked)}}handleKeyDown(e,t){e.which===32&&this._grid.getColumns()[t.cell].id===this._options.columnId&&((!this._grid.getEditorLock().isActive()||this._grid.getEditorLock().commitCurrentEdit())&&this.toggleRowSelection(t.row),e.preventDefault(),e.stopImmediatePropagation())}handleClick(e,t){if(this._grid.getColumns()[t.cell].id===this._options.columnId&&e.target.type==="checkbox"){if(this._grid.getEditorLock().isActive()&&!this._grid.getEditorLock().commitCurrentEdit()){e.preventDefault(),e.stopImmediatePropagation();return}this.toggleRowSelection(t.row),e.stopPropagation(),e.stopImmediatePropagation()}}toggleRowSelection(e){let t=this._grid.getDataItem(e);if(this.checkSelectableOverride(e,t,this._grid)){if(this._selectedRowsLookup[e]){let n=this._grid.getSelectedRows().filter(o=>o!==e);this._grid.setSelectedRows(n,"click.toggle")}else this._grid.setSelectedRows(this._grid.getSelectedRows().concat(e),"click.toggle");this._grid.setActiveCell(e,this.getCheckboxColumnCellIndex())}}selectRows(e){let t=[];for(let n=0,o=e.length;n<o;n++)this._selectedRowsLookup[e[n]]||(t[t.length]=e[n]);this._grid.setSelectedRows(this._grid.getSelectedRows().concat(t),"SlickCheckboxSelectColumn.selectRows")}deSelectRows(e){let t=[];for(let n=0,o=e.length;n<o;n++)this._selectedRowsLookup[e[n]]&&(t[t.length]=e[n]);this._grid.setSelectedRows(this._grid.getSelectedRows().filter(n=>t.indexOf(n)<0),"SlickCheckboxSelectColumn.deSelectRows")}handleHeaderClick(e,t){if(t.column.id===this._options.columnId&&e.target.type==="checkbox"){if(this._grid.getEditorLock().isActive()&&!this._grid.getEditorLock().commitCurrentEdit()){e.preventDefault(),e.stopImmediatePropagation();return}let n=e.target.checked,o=n?"click.selectAll":"click.unselectAll",r=[];if(n){for(let i=0;i<this._grid.getDataLength();i++){let a=this._grid.getDataItem(i);!a.__group&&!a.__groupTotals&&this.checkSelectableOverride(i,a,this._grid)&&r.push(i)}n=!0}if(this._isUsingDataView&&this._dataView&&this._options.applySelectOnAllPages){let i=[],a=this._dataView.getFilteredItems();for(let l=0;l<a.length;l++){let d=a[l];this.checkSelectableOverride(l,d,this._grid)&&i.push(d[this._dataView.getIdPropertyName()])}this._dataView.setSelectedIds(i,{isRowBeingAdded:n})}this._grid.setSelectedRows(r,o),e.stopPropagation(),e.stopImmediatePropagation()}}getCheckboxColumnCellIndex(){if(this._checkboxColumnCellIndex===null){this._checkboxColumnCellIndex=0;let e=this._grid.getColumns();for(let t=0;t<e.length;t++)e[t].id===this._options.columnId&&(this._checkboxColumnCellIndex=t)}return this._checkboxColumnCellIndex}createCheckboxElement(e,t=!1){let n=new DocumentFragment;return n.appendChild(lr.createDomElement("input",{id:e,type:"checkbox",checked:t,ariaChecked:String(t)})),n.appendChild(lr.createDomElement("label",{htmlFor:e})),n}getColumnDefinition(){return{id:this._options.columnId,reorderable:this._options.reorderable,name:this._options.hideSelectAllCheckbox||this._options.hideInColumnTitleRow?this._options.name||"":this.createCheckboxElement(`header-selector${this._selectAll_UID}`),toolTip:this._options.hideSelectAllCheckbox||this._options.hideInColumnTitleRow?"":this._options.toolTip,field:"sel",width:this._options.width,resizable:!1,sortable:!1,cssClass:this._options.cssClass,hideSelectAllCheckbox:this._options.hideSelectAllCheckbox,formatter:this.checkboxSelectionFormatter.bind(this),excludeFromColumnPicker:this._options.excludeFromColumnPicker??!0,excludeFromGridMenu:this._options.excludeFromGridMenu??!0,excludeFromHeaderMenu:this._options.excludeFromHeaderMenu??!0}}addCheckboxToFilterHeaderRow(e){this._handler.subscribe(e.onHeaderRowCellRendered,(t,n)=>{if(n.column.field==="sel"){lr.emptyElement(n.node);let o=lr.createDomElement("span",{id:"filter-checkbox-selectall-container",ariaChecked:"false"});o.appendChild(lr.createDomElement("input",{type:"checkbox",id:`header-filter-selector${this._selectAll_UID}`})),o.appendChild(lr.createDomElement("label",{htmlFor:`header-filter-selector${this._selectAll_UID}`})),n.node.appendChild(o),this._headerRowNode=n.node,this._bindingEventService.bind(o,"click",r=>this.handleHeaderClick(r,n))}})}createUID(){return Math.round(1e7*Math.random())}checkboxSelectionFormatter(e,t,n,o,r,i){if(r&&this.checkSelectableOverride(e,r,i)){let a=this.createUID()+e;return this.createCheckboxElement(`selector${a}`,!!this._selectedRowsLookup[e])}return null}checkSelectableOverride(e,t,n){return typeof this._selectableOverride=="function"?this._selectableOverride(e,t,n):!0}renderSelectAllCheckbox(e){this._grid.updateColumnHeader(this._options.columnId||"",this.createCheckboxElement(`header-selector${this._selectAll_UID}`,!!e),this._options.toolTip)}selectableOverride(e){this._selectableOverride=e}},BN=pc,WN=zr,HN=_N,pd=uo,zN=class{constructor(e){T(this,"pluginName","HeaderButtons"),T(this,"onCommand",new WN("onCommand")),T(this,"_grid"),T(this,"_handler",new HN),T(this,"_bindingEventService",new BN),T(this,"_defaults",{buttonCssClass:"slick-header-button"}),T(this,"_options"),this._options=pd.extend(!0,{},this._defaults,e)}init(e){this._grid=e,pd.addSlickEventPubSubWhenDefined(e.getPubSubService(),this),this._handler.subscribe(this._grid.onHeaderCellRendered,this.handleHeaderCellRendered.bind(this)).subscribe(this._grid.onBeforeHeaderCellDestroy,this.handleBeforeHeaderCellDestroy.bind(this)),this._grid.setColumns(this._grid.getColumns())}destroy(){this._handler.unsubscribeAll(),this._bindingEventService.unbindAll()}handleHeaderCellRendered(e,t){let n=t.column;if(n.header?.buttons){let o=n.header.buttons.length;for(;o--;){let r=n.header.buttons[o],i=this.runOverrideFunctionWhenExists(r.itemVisibilityOverride,t),a=this.runOverrideFunctionWhenExists(r.itemUsabilityOverride,t);if(!i)continue;Object.prototype.hasOwnProperty.call(r,"itemUsabilityOverride")&&(r.disabled=!a);let l=document.createElement("div");l.className=this._options.buttonCssClass||"",l.ariaLabel="Header Button",l.role="button",r.disabled&&l.classList.add("slick-header-button-disabled"),r.showOnHover&&l.classList.add("slick-header-button-hidden"),r.image&&(l.style.backgroundImage=`url(${r.image})`),r.cssClass&&l.classList.add(...pd.classNameToList(r.cssClass)),r.tooltip&&(l.title=r.tooltip),r.handler&&!r.disabled&&this._bindingEventService.bind(l,"click",r.handler),this._bindingEventService.bind(l,"click",this.handleButtonClick.bind(this,r,t.column)),t.node.appendChild(l)}}}handleBeforeHeaderCellDestroy(e,t){if(t.column.header?.buttons){let n=(this._options.buttonCssClass||"").replace(/(\s+)/g,".");n&&t.node.querySelectorAll(`.${n}`).forEach(o=>o.remove())}}handleButtonClick(e,t,n){let o=e.command||"",r={grid:this._grid,column:t,button:e};o&&(r.command=o),typeof e.action=="function"&&e.action.call(this,n,r),o&&!e.disabled&&(this.onCommand.notify(r,n,this),this._grid.updateColumnHeader(t.id)),n.preventDefault(),n.stopPropagation()}runOverrideFunctionWhenExists(e,t){return typeof e=="function"?e.call(this,t):!0}},YN=pc,md=SN,UN=ga,In=uo,qN=class{constructor(e){T(this,"pluginName","HeaderMenu"),T(this,"onAfterMenuShow",new md("onAfterMenuShow")),T(this,"onBeforeMenuShow",new md("onBeforeMenuShow")),T(this,"onCommand",new md("onCommand")),T(this,"_grid"),T(this,"_gridUid",""),T(this,"_handler",new UN),T(this,"_bindingEventService",new YN),T(this,"_defaults",{buttonCssClass:void 0,buttonImage:void 0,minWidth:100,autoAlign:!0,autoAlignOffset:0,subMenuOpenByEvent:"mouseover"}),T(this,"_options"),T(this,"_activeHeaderColumnElm"),T(this,"_menuElm"),T(this,"_subMenuParentId",""),this._options=In.extend(!0,{},e,this._defaults)}init(e){this._grid=e,this._gridUid=e?.getUID()||"",In.addSlickEventPubSubWhenDefined(e.getPubSubService(),this),this._handler.subscribe(this._grid.onHeaderCellRendered,this.handleHeaderCellRendered.bind(this)).subscribe(this._grid.onBeforeHeaderCellDestroy,this.handleBeforeHeaderCellDestroy.bind(this)),this._grid.setColumns(this._grid.getColumns()),this._bindingEventService.bind(document.body,"click",this.handleBodyMouseDown.bind(this))}setOptions(e){this._options=In.extend(!0,{},this._options,e)}getGridUidSelector(){let e=this._grid.getUID()||"";return e?`.${e}`:""}destroy(){this._handler.unsubscribeAll(),this._bindingEventService.unbindAll(),this._menuElm=this._menuElm||document.body.querySelector(`.slick-header-menu${this.getGridUidSelector()}`),this._menuElm?.remove(),this._activeHeaderColumnElm=void 0}destroyAllMenus(){this.destroySubMenus(),this._bindingEventService.unbindAll("parent-menu"),document.querySelectorAll(`.slick-header-menu${this.getGridUidSelector()}`).forEach(e=>e.remove())}destroySubMenus(){this._bindingEventService.unbindAll("sub-menu"),document.querySelectorAll(`.slick-header-menu.slick-submenu${this.getGridUidSelector()}`).forEach(e=>e.remove())}handleBodyMouseDown(e){let t=!1;this._menuElm?.contains(e.target)&&(t=!0),t||document.querySelectorAll(`.slick-header-menu.slick-submenu${this.getGridUidSelector()}`).forEach(n=>{n.contains(e.target)&&(t=!0)}),(this._menuElm!==e.target&&!t&&!e.defaultPrevented||e.target.className==="close")&&this.hideMenu()}hideMenu(){this._menuElm&&(this._menuElm.remove(),this._menuElm=void 0),this._activeHeaderColumnElm?.classList.remove("slick-header-column-active"),this.destroySubMenus()}handleHeaderCellRendered(e,t){let n=t.column?.header?.menu;if(n?.items&&console.warn('[SlickGrid] Header Menu "items" property was deprecated in favor of "commandItems" to align with all other Menu plugins.'),n){if(!this.runOverrideFunctionWhenExists(this._options.menuUsabilityOverride,t))return;let o=document.createElement("div");if(o.className="slick-header-menubutton",o.ariaLabel="Header Menu",o.role="button",!this._options.buttonCssClass&&!this._options.buttonImage&&(this._options.buttonCssClass="caret"),this._options.buttonCssClass){let r=document.createElement("span");r.classList.add(...In.classNameToList(this._options.buttonCssClass)),o.appendChild(r)}this._options.buttonImage&&(o.style.backgroundImage=`url(${this._options.buttonImage})`),this._options.tooltip&&(o.title=this._options.tooltip),this._bindingEventService.bind(o,"click",r=>{this.destroyAllMenus(),this.createParentMenu(r,n,t.column)}),t.node.appendChild(o)}}handleBeforeHeaderCellDestroy(e,t){t.column.header?.menu&&t.node.querySelectorAll(".slick-header-menubutton").forEach(n=>n.remove())}addSubMenuTitleWhenExists(e,t){if(e!=="divider"&&e?.subMenuTitle){let n=document.createElement("div");n.className="slick-menu-title",n.textContent=e.subMenuTitle;let o=e.subMenuTitleCssClass;o&&n.classList.add(...In.classNameToList(o)),t.appendChild(n)}}createParentMenu(e,t,n){let o={grid:this._grid,column:n,menu:t};if(this.onBeforeMenuShow.notify(o,e,this).getReturnValue()===!1)return;this._menuElm=this.createMenu(t.commandItems||t.items,n);let r=this._grid.getContainerNode();r&&r.appendChild(this._menuElm),this.repositionMenu(e,this._menuElm),this.onAfterMenuShow.notify(o,e,this).getReturnValue()!==!1&&(e.preventDefault(),e.stopPropagation())}createMenu(e,t,n=0,o){let r=n>0,i=o?.command,a=n===1&&i?i.replaceAll(" ",""):"";a&&(this._subMenuParentId=a),r&&(a=this._subMenuParentId);let l=`slick-header-menu slick-menu-level-${n} ${this._gridUid}`,d=document.body.querySelector(`.slick-header-menu.slick-menu-level-${n}${this.getGridUidSelector()}`);if(d){if(d.dataset.subMenuParent===a)return d;this.destroySubMenus()}let u=document.createElement("div");u.className=l,n>0&&(u.classList.add("slick-submenu"),a&&(u.dataset.subMenuParent=a)),u.classList.add(this._gridUid),u.role="menu",u.ariaLabel=n>1?"SubMenu":"Header Menu",u.style.minWidth=`${this._options.minWidth}px`,u.setAttribute("aria-expanded","true");let f={grid:this._grid,column:t,menu:{items:e}};o&&n>0&&this.addSubMenuTitleWhenExists(o,u);for(let p=0;p<e.length;p++){let y=!0,b=e[p],w=this.runOverrideFunctionWhenExists(b.itemVisibilityOverride,f),g=this.runOverrideFunctionWhenExists(b.itemUsabilityOverride,f);if(!w)continue;Object.prototype.hasOwnProperty.call(b,"itemUsabilityOverride")&&(b.disabled=!g);let v=document.createElement("div");v.className="slick-header-menuitem",v.role="menuitem",(b.divider||b==="divider")&&(v.classList.add("slick-header-menuitem-divider"),y=!1),b.disabled&&v.classList.add("slick-header-menuitem-disabled"),b.hidden&&v.classList.add("slick-header-menuitem-hidden"),b.cssClass&&v.classList.add(...In.classNameToList(b.cssClass)),b.tooltip&&(v.title=b.tooltip||"");let E=document.createElement("div");E.className="slick-header-menuicon",v.appendChild(E),b.iconCssClass&&E.classList.add(...In.classNameToList(b.iconCssClass)),b.iconImage&&(E.style.backgroundImage="url("+b.iconImage+")");let P=document.createElement("span");if(P.className="slick-header-menucontent",P.textContent=b.title||"",v.appendChild(P),b.textCssClass&&P.classList.add(...In.classNameToList(b.textCssClass)),u.appendChild(v),y){let x=r?"sub-menu":"parent-menu";this._bindingEventService.bind(v,"click",this.handleMenuItemClick.bind(this,b,t,n),void 0,x)}if(this._options.subMenuOpenByEvent==="mouseover"&&this._bindingEventService.bind(v,"mouseover",x=>{b.commandItems||b.items?this.repositionSubMenu(b,t,n,x):r||this.destroySubMenus()}),b.commandItems||b.items){let x=document.createElement("div");x.className="sub-item-chevron",this._options.subItemChevronClass?x.classList.add(...In.classNameToList(this._options.subItemChevronClass)):x.textContent="⮞",v.classList.add("slick-submenu-item"),v.appendChild(x)}}return u}handleMenuItemClick(e,t,n=0,o){if(e!=="divider"&&!e.disabled&&!e.divider){let r=e.command||"";if(In.isDefined(r)&&!e.commandItems&&!e.items){let i={grid:this._grid,column:t,command:r,item:e};this.onCommand.notify(i,o,this),typeof e.action=="function"&&e.action.call(this,o,i),o.defaultPrevented||this.hideMenu()}else e.commandItems||e.items?this.repositionSubMenu(e,t,n,o):this.destroySubMenus()}}repositionSubMenu(e,t,n,o){o.target.classList.contains("slick-header-menubutton")&&this.destroySubMenus();let r=this.createMenu(e.commandItems||e.items||[],t,n+1,e);document.body.appendChild(r),this.repositionMenu(o,r)}repositionMenu(e,t){let n=e.target,o=t.classList.contains("slick-submenu"),r=o?e.target.closest(".slick-header-menuitem"):n,i=In.offset(n),a=this._grid.getGridPosition(),l=t.offsetWidth,d=In.offset(this._menuElm),u=In.offset(r),f=o?u?.top??0:n.clientHeight??i?.top??0+(this._options?.menuOffsetTop??0),p=o?u?.left??0:i?.left??0;if(o&&r){let y=p+Number(l);o&&(y+=r.clientWidth);let b=document.documentElement.clientWidth;(y>=a.width||y>=b?"left":"right")=="left"?(t.classList.remove("dropright"),t.classList.add("dropleft"),p-=l):(t.classList.remove("dropleft"),t.classList.add("dropright"),o&&(p+=r.offsetWidth))}else p+t.offsetWidth>=a.width&&(p=p+n.clientWidth-t.clientWidth+(this._options.autoAlignOffset||0)),p-=d?.left??0;t.style.top=`${f}px`,t.style.left=`${p}px`,this._activeHeaderColumnElm=t.closest(".slick-header-column"),this._activeHeaderColumnElm&&this._activeHeaderColumnElm.classList.add("slick-header-column-active")}runOverrideFunctionWhenExists(e,t){return typeof e=="function"?e.call(this,t):!0}},GN=hh,gd=Lr,KN=_v,XN=LN,ZN=zr,QN=Ki,JN=ga,yd=uh,Ya=uo,eA=class{constructor(e){T(this,"pluginName","RowSelectionModel"),T(this,"onSelectedRangesChanged",new ZN("onSelectedRangesChanged")),T(this,"_grid"),T(this,"_ranges",[]),T(this,"_eventHandler",new JN),T(this,"_inHandler",!1),T(this,"_selector"),T(this,"_isRowMoveManagerHandler"),T(this,"_options"),T(this,"_defaults",{selectActiveRow:!0,dragToSelect:!1,autoScrollWhenDrag:!0,cellRangeSelector:void 0}),this._options=Ya.extend(!0,{},this._defaults,e)}init(e){if(GN===void 0)throw new Error('Slick.Draggable is undefined, make sure to import "slick.interactions.js"');if(this._selector=this._options.cellRangeSelector,this._grid=e,Ya.addSlickEventPubSubWhenDefined(e.getPubSubService(),this),!this._selector&&this._options.dragToSelect){if(!KN)throw new Error("Slick.CellRangeDecorator is required when option dragToSelect set to true");this._selector=new XN({selectionCss:{border:"none"},autoScroll:this._options.autoScrollWhenDrag})}this._eventHandler.subscribe(this._grid.onActiveCellChanged,this.wrapHandler(this.handleActiveCellChange).bind(this)),this._eventHandler.subscribe(this._grid.onKeyDown,this.wrapHandler(this.handleKeyDown).bind(this)),this._eventHandler.subscribe(this._grid.onClick,this.wrapHandler(this.handleClick).bind(this)),this._selector&&(e.registerPlugin(this._selector),this._selector.onCellRangeSelecting.subscribe(this.handleCellRangeSelected.bind(this)),this._selector.onCellRangeSelected.subscribe(this.handleCellRangeSelected.bind(this)),this._selector.onBeforeCellRangeSelected.subscribe(this.handleBeforeCellRangeSelected.bind(this)))}destroy(){this._eventHandler.unsubscribeAll(),this._selector&&(this._selector.onCellRangeSelecting.unsubscribe(this.handleCellRangeSelected.bind(this)),this._selector.onCellRangeSelected.unsubscribe(this.handleCellRangeSelected.bind(this)),this._selector.onBeforeCellRangeSelected.unsubscribe(this.handleBeforeCellRangeSelected.bind(this)),this._grid.unregisterPlugin(this._selector),this._selector.destroy&&this._selector.destroy())}wrapHandler(e){return(...t)=>{this._inHandler||(this._inHandler=!0,e.apply(this,t),this._inHandler=!1)}}rangesToRows(e){let t=[];for(let n=0;n<e.length;n++)for(let o=e[n].fromRow;o<=e[n].toRow;o++)t.push(o);return t}rowsToRanges(e){let t=[],n=this._grid.getColumns().length-1;return e.forEach(o=>t.push(new yd(o,0,o,n))),t}getRowsRange(e,t){let n,o=[];for(n=e;n<=t;n++)o.push(n);for(n=t;n<e;n++)o.push(n);return o}getSelectedRows(){return this.rangesToRows(this._ranges)}setSelectedRows(e){this.setSelectedRanges(this.rowsToRanges(e),"SlickRowSelectionModel.setSelectedRows")}setSelectedRanges(e,t="SlickRowSelectionModel.setSelectedRanges"){if((!this._ranges||this._ranges.length===0)&&(!e||e.length===0))return;this._ranges=e;let n=new QN(new CustomEvent("click",{detail:{caller:t}}),this._ranges);this.onSelectedRangesChanged.notify(this._ranges,n)}getSelectedRanges(){return this._ranges}refreshSelections(){this.setSelectedRows(this.getSelectedRows())}handleActiveCellChange(e,t){this._options.selectActiveRow&&Ya.isDefined(t.row)&&this.setSelectedRanges([new yd(t.row,0,t.row,this._grid.getColumns().length-1)])}handleKeyDown(e){let t=this._grid.getActiveCell();if(this._grid.getOptions().multiSelect&&t&&e.shiftKey&&!e.ctrlKey&&!e.altKey&&!e.metaKey&&(e.which===gd.UP||e.which===gd.DOWN)){let n=this.getSelectedRows();n.sort(function(a,l){return a-l}),n.length||(n=[t.row]);let o=n[0],r=n[n.length-1],i;if(e.which===gd.DOWN?i=t.row<r||o===r?++r:++o:i=t.row<r?--r:--o,i>=0&&i<this._grid.getDataLength()){this._grid.scrollRowIntoView(i);let a=this.rowsToRanges(this.getRowsRange(o,r));this.setSelectedRanges(a)}e.preventDefault(),e.stopPropagation()}}handleClick(e){let t=this._grid.getCellFromEvent(e);if(!t||!this._grid.canCellBeActive(t.row,t.cell)||!this._grid.getOptions().multiSelect||!e.ctrlKey&&!e.shiftKey&&!e.metaKey)return!1;let n=this.rangesToRows(this._ranges),o=n.indexOf(t.row);if(o===-1&&(e.ctrlKey||e.metaKey))n.push(t.row),this._grid.setActiveCell(t.row,t.cell);else if(o!==-1&&(e.ctrlKey||e.metaKey))n=n.filter(i=>i!==t.row),this._grid.setActiveCell(t.row,t.cell);else if(n.length&&e.shiftKey){let i=n.pop(),a=Math.min(t.row,i),l=Math.max(t.row,i);n=[];for(let d=a;d<=l;d++)d!==i&&n.push(d);n.push(i),this._grid.setActiveCell(t.row,t.cell)}let r=this.rowsToRanges(n);return this.setSelectedRanges(r),e.stopImmediatePropagation(),!0}handleBeforeCellRangeSelected(e,t){if(!this._isRowMoveManagerHandler){let n=this._grid.getPluginByName("RowMoveManager")||this._grid.getPluginByName("CrossGridRowMoveManager");this._isRowMoveManagerHandler=n?n.isHandlerColumn:Ya.noop}if(this._grid.getEditorLock().isActive()||this._isRowMoveManagerHandler(t.cell))return e.stopPropagation(),!1;this._grid.setActiveCell(t.row,t.cell)}handleCellRangeSelected(e,t){if(!this._grid.getOptions().multiSelect||!this._options.selectActiveRow)return!1;this.setSelectedRanges([new yd(t.range.fromRow,0,t.range.toRow,this._grid.getColumns().length-1)])}},tA=Lr,vd=wv,ai=uo,xv=class{constructor(e){T(this,"pluginName","GroupItemMetadataProvider"),T(this,"_grid"),T(this,"_options"),T(this,"_defaults",{checkboxSelect:!1,checkboxSelectCssClass:"slick-group-select-checkbox",checkboxSelectPlugin:null,groupCssClass:"slick-group",groupTitleCssClass:"slick-group-title",totalsCssClass:"slick-group-totals",groupFocusable:!0,totalsFocusable:!1,toggleCssClass:"slick-group-toggle",toggleExpandedCssClass:"expanded",toggleCollapsedCssClass:"collapsed",enableExpandCollapse:!0,groupFormatter:this.defaultGroupCellFormatter.bind(this),totalsFormatter:this.defaultTotalsCellFormatter.bind(this),includeHeaderTotals:!1}),this._options=ai.extend(!0,{},this._defaults,e)}get dataView(){return this._grid?.getData?.()??{}}getOptions(){return this._options}setOptions(e){ai.extend(!0,this._options,e)}defaultGroupCellFormatter(e,t,n,o,r){if(!this._options.enableExpandCollapse)return r.title;let i=`${r.level*15}px`,a=r.collapsed?this._options.toggleCollapsedCssClass:this._options.toggleExpandedCssClass,l=document.createDocumentFragment();this._options.checkboxSelect&&l.appendChild(ai.createDomElement("span",{className:`${this._options.checkboxSelectCssClass} ${r.selectChecked?"checked":"unchecked"}`})),l.appendChild(ai.createDomElement("span",{className:`${this._options.toggleCssClass} ${a}`,ariaExpanded:String(!r.collapsed),style:{marginLeft:i}}));let d=ai.createDomElement("span",{className:this._options.groupTitleCssClass||""});return d.setAttribute("level",r.level),r.title instanceof HTMLElement?d.appendChild(r.title):this._grid.applyHtmlCode(d,r.title??""),l.appendChild(d),l}defaultTotalsCellFormatter(e,t,n,o,r,i){return o?.groupTotalsFormatter?.(r,o,i)??""}init(e){this._grid=e,this._grid.onClick.subscribe(this.handleGridClick.bind(this)),this._grid.onKeyDown.subscribe(this.handleGridKeyDown.bind(this))}destroy(){this._grid&&(this._grid.onClick.unsubscribe(this.handleGridClick.bind(this)),this._grid.onKeyDown.unsubscribe(this.handleGridKeyDown.bind(this)))}handleGridClick(e,t){let n=e.target,o=this._grid.getDataItem(t.row);if(o&&o instanceof vd&&n.classList.contains(this._options.toggleCssClass||"")&&(this.handleDataViewExpandOrCollapse(o),e.stopImmediatePropagation(),e.preventDefault()),o&&o instanceof vd&&n.classList.contains(this._options.checkboxSelectCssClass||"")){o.selectChecked=!o.selectChecked,n.classList.remove(o.selectChecked?"unchecked":"checked"),n.classList.add(o.selectChecked?"checked":"unchecked");let r=this.dataView.mapItemsToRows(o.rows);o.selectChecked?this._options.checkboxSelectPlugin.selectRows(r):this._options.checkboxSelectPlugin.deSelectRows(r)}}handleGridKeyDown(e){if(this._options.enableExpandCollapse&&e.which===tA.SPACE){let t=this._grid.getActiveCell();if(t){let n=this._grid.getDataItem(t.row);n&&n instanceof vd&&(this.handleDataViewExpandOrCollapse(n),e.stopImmediatePropagation(),e.preventDefault())}}}handleDataViewExpandOrCollapse(e){let t=this._grid.getRenderedRange();this.dataView.setRefreshHints({ignoreDiffsBefore:t.top,ignoreDiffsAfter:t.bottom+1}),e.collapsed?this.dataView.expandGroup(e.groupingKey):this.dataView.collapseGroup(e.groupingKey)}getGroupRowMetadata(e,t,n){let o=e?.level;return{selectable:!1,focusable:this._options.groupFocusable,cssClasses:`${this._options.groupCssClass} slick-group-level-${o}`,formatter:this._options.includeHeaderTotals&&this._options.totalsFormatter||void 0,columns:{0:{colspan:this._options.includeHeaderTotals?"1":"*",formatter:this._options.groupFormatter,editor:null}}}}getTotalsRowMetadata(e,t,n){let o=e?.group?.level;return{selectable:!1,focusable:this._options.totalsFocusable,cssClasses:`${this._options.totalsCssClass} slick-group-level-${o}`,formatter:this._options.totalsFormatter,editor:null}}},Bo=zr,bd=Ki,nm=wv,nA=bN,Bn=uo,oA=xv,rA=class{constructor(e,t){this.externalPubSub=t,T(this,"defaults",{globalItemMetadataProvider:null,groupItemMetadataProvider:null,inlineFilters:!1,useCSPSafeFilter:!1}),T(this,"idProperty","id"),T(this,"items",[]),T(this,"rows",[]),T(this,"idxById",new Map),T(this,"rowsById"),T(this,"filter",null),T(this,"filterCSPSafe",null),T(this,"updated",null),T(this,"suspend",!1),T(this,"isBulkSuspend",!1),T(this,"bulkDeleteIds",new Map),T(this,"sortAsc",!0),T(this,"fastSortField"),T(this,"sortComparer"),T(this,"refreshHints",{}),T(this,"prevRefreshHints",{}),T(this,"filterArgs"),T(this,"filteredItems",[]),T(this,"compiledFilter"),T(this,"compiledFilterCSPSafe"),T(this,"compiledFilterWithCaching"),T(this,"compiledFilterWithCachingCSPSafe"),T(this,"filterCache",[]),T(this,"_grid"),T(this,"groupingInfoDefaults",{getter:void 0,formatter:void 0,comparer:(n,o)=>n.value===o.value?0:n.value>o.value?1:-1,predefinedValues:[],aggregators:[],aggregateEmpty:!1,aggregateCollapsed:!1,aggregateChildGroups:!1,collapsed:!1,displayTotalsRow:!0,lazyTotalsCalculation:!1}),T(this,"groupingInfos",[]),T(this,"groups",[]),T(this,"toggledGroupsByLevel",[]),T(this,"groupingDelimiter",":|:"),T(this,"selectedRowIds",[]),T(this,"preSelectedRowIdsChangeFn"),T(this,"pagesize",0),T(this,"pagenum",0),T(this,"totalRows",0),T(this,"_options"),T(this,"_container"),T(this,"onBeforePagingInfoChanged"),T(this,"onGroupExpanded"),T(this,"onGroupCollapsed"),T(this,"onPagingInfoChanged"),T(this,"onRowCountChanged"),T(this,"onRowsChanged"),T(this,"onRowsOrCountChanged"),T(this,"onSelectedRowIdsChanged"),T(this,"onSetItemsCalled"),this.onBeforePagingInfoChanged=new Bo("onBeforePagingInfoChanged",t),this.onGroupExpanded=new Bo("onGroupExpanded",t),this.onGroupCollapsed=new Bo("onGroupCollapsed",t),this.onPagingInfoChanged=new Bo("onPagingInfoChanged",t),this.onRowCountChanged=new Bo("onRowCountChanged",t),this.onRowsChanged=new Bo("onRowsChanged",t),this.onRowsOrCountChanged=new Bo("onRowsOrCountChanged",t),this.onSelectedRowIdsChanged=new Bo("onSelectedRowIdsChanged",t),this.onSetItemsCalled=new Bo("onSetItemsCalled",t),this._options=Bn.extend(!0,{},this.defaults,e)}beginUpdate(e){this.suspend=!0,this.isBulkSuspend=e===!0}endUpdate(){let e=this.isBulkSuspend;this.isBulkSuspend=!1,this.suspend=!1,e&&(this.processBulkDelete(),this.ensureIdUniqueness()),this.refresh()}destroy(){this.items=[],this.idxById=null,this.rowsById=null,this.filter=null,this.filterCSPSafe=null,this.updated=null,this.sortComparer=null,this.filterCache=[],this.filteredItems=[],this.compiledFilter=null,this.compiledFilterCSPSafe=null,this.compiledFilterWithCaching=null,this.compiledFilterWithCachingCSPSafe=null,this._grid&&this._grid.onSelectedRowsChanged&&this._grid.onCellCssStylesChanged&&(this._grid.onSelectedRowsChanged.unsubscribe(),this._grid.onCellCssStylesChanged.unsubscribe()),this.onRowsOrCountChanged&&this.onRowsOrCountChanged.unsubscribe()}setRefreshHints(e){this.refreshHints=e}getFilterArgs(){return this.filterArgs}setFilterArgs(e){this.filterArgs=e}processBulkDelete(){if(!this.idxById)return;let e,t,n=0;for(let o=0,r=this.items.length;o<r;o++){if(t=this.items[o],e=t[this.idProperty],e===void 0)throw new Error("[SlickGrid DataView] Each data element must implement a unique 'id' property");this.bulkDeleteIds.has(e)?this.idxById.delete(e):(this.items[n]=t,this.idxById.set(e,n),++n)}this.items.length=n,this.bulkDeleteIds=new Map}updateIdxById(e){if(this.isBulkSuspend||!this.idxById)return;e=e||0;let t;for(let n=e,o=this.items.length;n<o;n++){if(t=this.items[n][this.idProperty],t===void 0)throw new Error("[SlickGrid DataView] Each data element must implement a unique 'id' property");this.idxById.set(t,n)}}ensureIdUniqueness(){if(this.isBulkSuspend||!this.idxById)return;let e;for(let t=0,n=this.items.length;t<n;t++)if(e=this.items[t][this.idProperty],e===void 0||this.idxById.get(e)!==t)throw new Error("[SlickGrid DataView] Each data element must implement a unique 'id' property")}getItems(){return this.items}getIdPropertyName(){return this.idProperty}setItems(e,t){t!==void 0&&(this.idProperty=t),this.items=this.filteredItems=e,this.onSetItemsCalled.notify({idProperty:this.idProperty,itemCount:this.items.length},null,this),this.idxById=new Map,this.updateIdxById(),this.ensureIdUniqueness(),this.refresh()}setPagingOptions(e){this.onBeforePagingInfoChanged.notify(this.getPagingInfo(),null,this).getReturnValue()!==!1&&(Bn.isDefined(e.pageSize)&&(this.pagesize=e.pageSize,this.pagenum=this.pagesize?Math.min(this.pagenum,Math.max(0,Math.ceil(this.totalRows/this.pagesize)-1)):0),Bn.isDefined(e.pageNum)&&(this.pagenum=Math.min(e.pageNum,Math.max(0,Math.ceil(this.totalRows/this.pagesize)-1))),this.onPagingInfoChanged.notify(this.getPagingInfo(),null,this),this.refresh())}getPagingInfo(){let e=this.pagesize?Math.max(1,Math.ceil(this.totalRows/this.pagesize)):1;return{pageSize:this.pagesize,pageNum:this.pagenum,totalRows:this.totalRows,totalPages:e,dataView:this}}sort(e,t){this.sortAsc=t,this.sortComparer=e,this.fastSortField=null,t===!1&&this.items.reverse(),this.items.sort(e),t===!1&&this.items.reverse(),this.idxById=new Map,this.updateIdxById(),this.refresh()}fastSort(e,t){this.sortAsc=t,this.fastSortField=e,this.sortComparer=null;let n=Object.prototype.toString;Object.prototype.toString=typeof e=="function"?e:function(){return this[e]},t===!1&&this.items.reverse(),this.items.sort(),Object.prototype.toString=n,t===!1&&this.items.reverse(),this.idxById=new Map,this.updateIdxById(),this.refresh()}reSort(){this.sortComparer?this.sort(this.sortComparer,this.sortAsc):this.fastSortField&&this.fastSort(this.fastSortField,this.sortAsc)}getFilteredItems(){return this.filteredItems}getFilteredItemCount(){return this.filteredItems.length}getFilter(){return this._options.useCSPSafeFilter?this.filterCSPSafe:this.filter}setFilter(e){this.filterCSPSafe=e,this.filter=e,this._options.inlineFilters&&(this.compiledFilterCSPSafe=this.compileFilterCSPSafe,this.compiledFilterWithCachingCSPSafe=this.compileFilterWithCachingCSPSafe,this.compiledFilter=this.compileFilter(this._options.useCSPSafeFilter),this.compiledFilterWithCaching=this.compileFilterWithCaching(this._options.useCSPSafeFilter)),this.refresh()}getGrouping(){return this.groupingInfos}setGrouping(e){this._options.groupItemMetadataProvider||(this._options.groupItemMetadataProvider=new oA),this.groups=[],this.toggledGroupsByLevel=[],e=e||[],this.groupingInfos=e instanceof Array?e:[e];for(let t=0;t<this.groupingInfos.length;t++){let n=this.groupingInfos[t]=Bn.extend(!0,{},this.groupingInfoDefaults,this.groupingInfos[t]);n.getterIsAFn=typeof n.getter=="function",n.compiledAccumulators=[];let o=n.aggregators.length;for(;o--;)n.compiledAccumulators[o]=this.compileAccumulatorLoopCSPSafe(n.aggregators[o]);this.toggledGroupsByLevel[t]={}}this.refresh()}getItemByIdx(e){return this.items[e]}getIdxById(e){return this.idxById?.get(e)}ensureRowsByIdCache(){if(!this.rowsById){this.rowsById={};for(let e=0,t=this.rows.length;e<t;e++)this.rowsById[this.rows[e][this.idProperty]]=e}}getRowByItem(e){return this.ensureRowsByIdCache(),this.rowsById?.[e[this.idProperty]]}getRowById(e){return this.ensureRowsByIdCache(),this.rowsById?.[e]}getItemById(e){return this.items[this.idxById.get(e)]}mapItemsToRows(e){let t=[];this.ensureRowsByIdCache();for(let n=0,o=e.length;n<o;n++){let r=this.rowsById?.[e[n][this.idProperty]];Bn.isDefined(r)&&(t[t.length]=r)}return t}mapIdsToRows(e){let t=[];this.ensureRowsByIdCache();for(let n=0,o=e.length;n<o;n++){let r=this.rowsById?.[e[n]];Bn.isDefined(r)&&(t[t.length]=r)}return t}mapRowsToIds(e){let t=[];for(let n=0,o=e.length;n<o;n++)if(e[n]<this.rows.length){let r=this.rows[e[n]];t[t.length]=r[this.idProperty]}return t}updateSingleItem(e,t){if(this.idxById){if(!this.idxById.has(e))throw new Error("[SlickGrid DataView] Invalid id");if(e!==t[this.idProperty]){let n=t[this.idProperty];if(!Bn.isDefined(n))throw new Error("[SlickGrid DataView] Cannot update item to associate with a null id");if(this.idxById.has(n))throw new Error("[SlickGrid DataView] Cannot update item to associate with a non-unique id");this.idxById.set(n,this.idxById.get(e)),this.idxById.delete(e),this.updated?.[e]&&delete this.updated[e],e=n}this.items[this.idxById.get(e)]=t,this.updated||(this.updated={}),this.updated[e]=!0}}updateItem(e,t){this.updateSingleItem(e,t),this.refresh()}updateItems(e,t){if(e.length!==t.length)throw new Error("[SlickGrid DataView] Mismatch on the length of ids and items provided to update");for(let n=0,o=t.length;n<o;n++)this.updateSingleItem(e[n],t[n]);this.refresh()}insertItem(e,t){this.items.splice(e,0,t),this.updateIdxById(e),this.refresh()}insertItems(e,t){Array.prototype.splice.apply(this.items,[e,0].concat(t)),this.updateIdxById(e),this.refresh()}addItem(e){this.items.push(e),this.updateIdxById(this.items.length-1),this.refresh()}addItems(e){this.items=this.items.concat(e),this.updateIdxById(this.items.length-e.length),this.refresh()}deleteItem(e){if(this.idxById)if(this.isBulkSuspend)this.bulkDeleteIds.set(e,!0);else{let t=this.idxById.get(e);if(t===void 0)throw new Error("[SlickGrid DataView] Invalid id");this.idxById.delete(e),this.items.splice(t,1),this.updateIdxById(t),this.refresh()}}deleteItems(e){if(!(e.length===0||!this.idxById))if(this.isBulkSuspend)for(let t=0,n=e.length;t<n;t++){let o=e[t];if(this.idxById.get(o)===void 0)throw new Error("[SlickGrid DataView] Invalid id");this.bulkDeleteIds.set(o,!0)}else{let t=[];for(let n=0,o=e.length;n<o;n++){let r=e[n],i=this.idxById.get(r);if(i===void 0)throw new Error("[SlickGrid DataView] Invalid id");this.idxById.delete(r),t.push(i)}t.sort();for(let n=t.length-1;n>=0;--n)this.items.splice(t[n],1);this.updateIdxById(t[0]),this.refresh()}}sortedAddItem(e){if(!this.sortComparer)throw new Error("[SlickGrid DataView] sortedAddItem() requires a sort comparer, use sort()");this.insertItem(this.sortedIndex(e),e)}sortedUpdateItem(e,t){if(!this.idxById)return;if(!this.idxById.has(e)||e!==t[this.idProperty])throw new Error("[SlickGrid DataView] Invalid or non-matching id "+this.idxById.get(e));if(!this.sortComparer)throw new Error("[SlickGrid DataView] sortedUpdateItem() requires a sort comparer, use sort()");let n=this.getItemById(e);this.sortComparer(n,t)!==0?(this.deleteItem(e),this.sortedAddItem(t)):this.updateItem(e,t)}sortedIndex(e){let t=0,n=this.items.length;for(;t<n;){let o=t+n>>>1;this.sortComparer(this.items[o],e)===-1?t=o+1:n=o}return t}getItemCount(){return this.items.length}getLength(){return this.rows.length}getItem(e){let t=this.rows[e];if(t?.__group&&t.totals&&!t.totals?.initialized){let n=this.groupingInfos[t.level];n.displayTotalsRow||(this.calculateTotals(t.totals),t.title=n.formatter?n.formatter(t):t.value)}else t?.__groupTotals&&!t.initialized&&this.calculateTotals(t);return t}getItemMetadata(e){let t=this.rows[e];return t===void 0?null:this._options.globalItemMetadataProvider?.getRowMetadata?this._options.globalItemMetadataProvider.getRowMetadata(t,e):t.__group&&this._options.groupItemMetadataProvider?.getGroupRowMetadata?this._options.groupItemMetadataProvider.getGroupRowMetadata(t,e):t.__groupTotals&&this._options.groupItemMetadataProvider?.getTotalsRowMetadata?this._options.groupItemMetadataProvider.getTotalsRowMetadata(t,e):null}expandCollapseAllGroups(e,t){if(Bn.isDefined(e))this.toggledGroupsByLevel[e]={},this.groupingInfos[e].collapsed=t,t===!0?this.onGroupCollapsed.notify({level:e,groupingKey:null}):this.onGroupExpanded.notify({level:e,groupingKey:null});else for(let n=0;n<this.groupingInfos.length;n++)this.toggledGroupsByLevel[n]={},this.groupingInfos[n].collapsed=t,t===!0?this.onGroupCollapsed.notify({level:n,groupingKey:null}):this.onGroupExpanded.notify({level:n,groupingKey:null});this.refresh()}collapseAllGroups(e){this.expandCollapseAllGroups(e,!0)}expandAllGroups(e){this.expandCollapseAllGroups(e,!1)}expandCollapseGroup(e,t,n){this.toggledGroupsByLevel[e][t]=this.groupingInfos[e].collapsed^n,this.refresh()}collapseGroup(...e){let t=Array.prototype.slice.call(e)[0],n,o;e.length===1&&t.indexOf(this.groupingDelimiter)!==-1?(n=t,o=t.split(this.groupingDelimiter).length-1):(n=e.join(this.groupingDelimiter),o=e.length-1),this.expandCollapseGroup(o,n,!0),this.onGroupCollapsed.notify({level:o,groupingKey:n})}expandGroup(...e){let t=Array.prototype.slice.call(e)[0],n,o;e.length===1&&t.indexOf(this.groupingDelimiter)!==-1?(o=t.split(this.groupingDelimiter).length-1,n=t):(o=e.length-1,n=e.join(this.groupingDelimiter)),this.expandCollapseGroup(o,n,!1),this.onGroupExpanded.notify({level:o,groupingKey:n})}getGroups(){return this.groups}extractGroups(e,t){let n,o,r=[],i={},a,l=t?t.level+1:0,d=this.groupingInfos[l];for(let u=0,f=d.predefinedValues?.length??0;u<f;u++)o=d.predefinedValues?.[u],n=i[o],n||(n=new nm,n.value=o,n.level=l,n.groupingKey=(t?t.groupingKey+this.groupingDelimiter:"")+o,r[r.length]=n,i[o]=n);for(let u=0,f=e.length;u<f;u++)a=e[u],o=d.getterIsAFn?d.getter(a):a[d.getter],n=i[o],n||(n=new nm,n.value=o,n.level=l,n.groupingKey=(t?t.groupingKey+this.groupingDelimiter:"")+o,r[r.length]=n,i[o]=n),n.rows[n.count++]=a;if(l<this.groupingInfos.length-1)for(let u=0;u<r.length;u++)n=r[u],n.groups=this.extractGroups(n.rows,n);return r.length&&this.addTotals(r,l),r.sort(this.groupingInfos[l].comparer),r}calculateTotals(e){let t=e.group,n=this.groupingInfos[t.level??0],o=t.level===this.groupingInfos.length,r,i=n.aggregators.length;if(!o&&n.aggregateChildGroups){let a=t.groups?.length??0;for(;a--;)t.groups[a].totals.initialized||this.calculateTotals(t.groups[a].totals)}for(;i--;)r=n.aggregators[i],r.init(),!o&&n.aggregateChildGroups?n.compiledAccumulators[i].call(r,t.groups):n.compiledAccumulators[i].call(r,t.rows),r.storeResult(e);e.initialized=!0}addGroupTotals(e){let t=this.groupingInfos[e.level],n=new nA;n.group=e,e.totals=n,t.lazyTotalsCalculation||this.calculateTotals(n)}addTotals(e,t){t=t||0;let n=this.groupingInfos[t],o=n.collapsed,r=this.toggledGroupsByLevel[t],i=e.length,a;for(;i--;)a=e[i],!(a.collapsed&&!n.aggregateCollapsed)&&(a.groups&&this.addTotals(a.groups,t+1),n.aggregators?.length&&(n.aggregateEmpty||a.rows.length||a.groups?.length)&&this.addGroupTotals(a),a.collapsed=o^r[a.groupingKey],a.title=n.formatter?n.formatter(a):a.value)}flattenGroupedRows(e,t){t=t||0;let n=this.groupingInfos[t],o=[],r,i=0,a;for(let l=0,d=e.length;l<d;l++){if(a=e[l],o[i++]=a,!a.collapsed){r=a.groups?this.flattenGroupedRows(a.groups,t+1):a.rows;for(let u=0,f=r.length;u<f;u++)o[i++]=r[u]}a.totals&&n.displayTotalsRow&&(!a.collapsed||n.aggregateCollapsed)&&(o[i++]=a.totals)}return o}compileAccumulatorLoopCSPSafe(e){return e.accumulate?function(t){let n;for(let o=0;o<t.length;o++){let r=t[o];n=e.accumulate.call(e,r)}return n}:function(){}}compileFilterCSPSafe(e,t){if(typeof this.filterCSPSafe!="function")return[];let n=[],o=e.length;for(let r=0;r<o;r++)this.filterCSPSafe(e[r],t)&&n.push(e[r]);return n}compileFilter(e=!1){if(e)return null;let t=Bn.getFunctionDetails(this.filter),n="{ continue _coreloop; }$1",o="{ _retval[_idx++] = $item$; continue _coreloop; }$1",r=t.body.replace(/return false\s*([;}]|\}|$)/gi,n).replace(/return!1([;}]|\}|$)/gi,n).replace(/return true\s*([;}]|\}|$)/gi,o).replace(/return!0([;}]|\}|$)/gi,o).replace(/return ([^;}]+?)\s*([;}]|$)/gi,"{ if ($1) { _retval[_idx++] = $item$; }; continue _coreloop; }$2"),i=["var _retval = [], _idx = 0; ","var $item$, $args$ = _args; ","_coreloop: ","for (var _i = 0, _il = _items.length; _i < _il; _i++) { ","$item$ = _items[_i]; ","$filter$; ","} ","return _retval; "].join("");i=i.replace(/\$filter\$/gi,r),i=i.replace(/\$item\$/gi,t.params[0]),i=i.replace(/\$args\$/gi,t.params[1]);let a=new Function("_items,_args",i),l="compiledFilter";return a.displayName=l,a.name=this.setFunctionName(a,l),a}compileFilterWithCaching(e=!1){if(e)return null;let t=Bn.getFunctionDetails(this.filter),n="{ continue _coreloop; }$1",o="{ _cache[_i] = true;_retval[_idx++] = $item$; continue _coreloop; }$1",r=t.body.replace(/return false\s*([;}]|\}|$)/gi,n).replace(/return!1([;}]|\}|$)/gi,n).replace(/return true\s*([;}]|\}|$)/gi,o).replace(/return!0([;}]|\}|$)/gi,o).replace(/return ([^;}]+?)\s*([;}]|$)/gi,"{ if ((_cache[_i] = $1)) { _retval[_idx++] = $item$; }; continue _coreloop; }$2"),i=["var _retval = [], _idx = 0; ","var $item$, $args$ = _args; ","_coreloop: ","for (var _i = 0, _il = _items.length; _i < _il; _i++) { ","$item$ = _items[_i]; ","if (_cache[_i]) { ","_retval[_idx++] = $item$; ","continue _coreloop; ","} ","$filter$; ","} ","return _retval; "].join("");i=i.replace(/\$filter\$/gi,r),i=i.replace(/\$item\$/gi,t.params[0]),i=i.replace(/\$args\$/gi,t.params[1]);let a=new Function("_items,_args,_cache",i),l="compiledFilterWithCaching";return a.displayName=l,a.name=this.setFunctionName(a,l),a}compileFilterWithCachingCSPSafe(e,t,n){if(typeof this.filterCSPSafe!="function")return[];let o=[],r=e.length;for(let i=0;i<r;i++)(n[i]||this.filterCSPSafe(e[i],t))&&o.push(e[i]);return o}setFunctionName(e,t){try{Object.defineProperty(e,"name",{writable:!0,value:t})}catch{e.name=t}}uncompiledFilter(e,t){let n=[],o=0;for(let r=0,i=e.length;r<i;r++)this.filter?.(e[r],t)&&(n[o++]=e[r]);return n}uncompiledFilterWithCaching(e,t,n){let o=[],r=0,i;for(let a=0,l=e.length;a<l;a++)i=e[a],n[a]?o[r++]=i:this.filter?.(i,t)&&(o[r++]=i,n[a]=!0);return o}getFilteredAndPagedItems(e){if(this._options.useCSPSafeFilter?this.filterCSPSafe:this.filter){let n,o;this._options.useCSPSafeFilter?(n=this._options.inlineFilters?this.compiledFilterCSPSafe:this.uncompiledFilter,o=this._options.inlineFilters?this.compiledFilterWithCachingCSPSafe:this.uncompiledFilterWithCaching):(n=this._options.inlineFilters?this.compiledFilter:this.uncompiledFilter,o=this._options.inlineFilters?this.compiledFilterWithCaching:this.uncompiledFilterWithCaching),this.refreshHints.isFilterNarrowing?this.filteredItems=n.call(this,this.filteredItems,this.filterArgs):this.refreshHints.isFilterExpanding?this.filteredItems=o.call(this,e,this.filterArgs,this.filterCache):this.refreshHints.isFilterUnchanged||(this.filteredItems=n.call(this,e,this.filterArgs))}else this.filteredItems=this.pagesize?e:e.concat();let t;return this.pagesize?(this.filteredItems.length<=this.pagenum*this.pagesize&&(this.filteredItems.length===0?this.pagenum=0:this.pagenum=Math.floor((this.filteredItems.length-1)/this.pagesize)),t=this.filteredItems.slice(this.pagesize*this.pagenum,this.pagesize*this.pagenum+this.pagesize)):t=this.filteredItems,{totalRows:this.filteredItems.length,rows:t}}getRowDiffs(e,t){let n,o,r,i=[],a=0,l=Math.max(t.length,e.length);this.refreshHints?.ignoreDiffsBefore&&(a=Math.max(0,Math.min(t.length,this.refreshHints.ignoreDiffsBefore))),this.refreshHints?.ignoreDiffsAfter&&(l=Math.min(t.length,Math.max(0,this.refreshHints.ignoreDiffsAfter)));for(let d=a,u=e.length;d<l;d++)d>=u?i[i.length]=d:(n=t[d],o=e[d],(!n||this.groupingInfos.length&&(r=n.__nonDataRow||o.__nonDataRow)&&n.__group!==o.__group||n.__group&&!n.equals(o)||r&&(n.__groupTotals||o.__groupTotals)||n[this.idProperty]!==o[this.idProperty]||this.updated?.[n[this.idProperty]])&&(i[i.length]=d));return i}recalc(e){this.rowsById=void 0,(this.refreshHints.isFilterNarrowing!==this.prevRefreshHints.isFilterNarrowing||this.refreshHints.isFilterExpanding!==this.prevRefreshHints.isFilterExpanding)&&(this.filterCache=[]);let t=this.getFilteredAndPagedItems(e);this.totalRows=t.totalRows;let n=t.rows;this.groups=[],this.groupingInfos.length&&(this.groups=this.extractGroups(n),this.groups.length&&(n=this.flattenGroupedRows(this.groups)));let o=this.getRowDiffs(this.rows,n);return this.rows=n,o}refresh(){if(this.suspend)return;let e=Bn.extend(!0,{},this.getPagingInfo()),t=this.rows.length,n=this.totalRows,o=this.recalc(this.items);this.pagesize&&this.totalRows<this.pagenum*this.pagesize&&(this.pagenum=Math.max(0,Math.ceil(this.totalRows/this.pagesize)-1),o=this.recalc(this.items)),this.updated=null,this.prevRefreshHints=this.refreshHints,this.refreshHints={},n!==this.totalRows&&this.onBeforePagingInfoChanged.notify(e,null,this).getReturnValue()!==!1&&this.onPagingInfoChanged.notify(this.getPagingInfo(),null,this),t!==this.rows.length&&this.onRowCountChanged.notify({previous:t,current:this.rows.length,itemCount:this.items.length,dataView:this,callingOnRowsChanged:o.length>0},null,this),o.length>0&&this.onRowsChanged.notify({rows:o,itemCount:this.items.length,dataView:this,calledOnRowCountChanged:t!==this.rows.length},null,this),(t!==this.rows.length||o.length>0)&&this.onRowsOrCountChanged.notify({rowsDiff:o,previousRowCount:t,currentRowCount:this.rows.length,itemCount:this.items.length,rowCountChanged:t!==this.rows.length,rowsChanged:o.length>0,dataView:this},null,this)}syncGridSelection(e,t,n){this._grid=e;let o;this.selectedRowIds=this.mapRowsToIds(e.getSelectedRows());let r=a=>{a===!1?this.selectedRowIds=[]:this.selectedRowIds.sort().join(",")!==a.sort().join(",")&&(this.selectedRowIds=a)},i=()=>{if((this.selectedRowIds||[]).length>0&&!o){o=!0;let a=this.mapIdsToRows(this.selectedRowIds||[]);if(!t){let l={grid:this._grid,ids:this.mapRowsToIds(a),rows:a,dataView:this};this.preSelectedRowIdsChangeFn(l),this.onSelectedRowIdsChanged.notify(Object.assign(l,{selectedRowIds:this.selectedRowIds,filteredIds:this.getAllSelectedFilteredIds()}),new bd,this)}e.setSelectedRows(a),o=!1}};return e.onSelectedRowsChanged.subscribe((a,l)=>{if(!o){let d=this.mapRowsToIds(l.rows),u={grid:this._grid,ids:d,rows:l.rows,added:!0,dataView:this};this.preSelectedRowIdsChangeFn(u),this.onSelectedRowIdsChanged.notify(Object.assign(u,{selectedRowIds:this.selectedRowIds,filteredIds:this.getAllSelectedFilteredIds()}),new bd,this)}}),this.preSelectedRowIdsChangeFn=a=>{if(!o){if(o=!0,typeof a.added>"u")r(a.ids);else{let l;if(a.added)n&&e.getOptions().multiSelect?l=(this.selectedRowIds?.filter(d=>this.getRowById(d)===void 0)).concat(a.ids):l=a.ids;else if(n&&e.getOptions().multiSelect){let d=new Set(a.ids);l=this.selectedRowIds?.filter(u=>!d.has(u))}else l=[];r(l)}o=!1}},this.onRowsOrCountChanged.subscribe(i.bind(this)),this.onSelectedRowIdsChanged}getAllSelectedIds(){return this.selectedRowIds}getAllSelectedFilteredIds(){return this.getAllSelectedFilteredItems().map(e=>e[this.idProperty])}setSelectedIds(e,t){let n=t?.isRowBeingAdded,o=t?.shouldTriggerEvent,r=t?.applyRowSelectionToGrid;n!==!1&&(n=!0);let i=this.mapIdsToRows(e),a={grid:this._grid,ids:e,rows:i,added:n,dataView:this};this.preSelectedRowIdsChangeFn?.(a),o!==!1&&this.onSelectedRowIdsChanged.notify(Object.assign(a,{selectedRowIds:this.selectedRowIds,filteredIds:this.getAllSelectedFilteredIds()}),new bd,this),r!==!1&&this._grid&&this._grid.setSelectedRows(i)}getAllSelectedItems(){let e=[];return this.getAllSelectedIds().forEach(t=>{e.push(this.getItemById(t))}),e}getAllSelectedFilteredItems(){if(!Array.isArray(this.selectedRowIds))return[];let e=new Set(this.selectedRowIds);return this.filteredItems.filter(t=>e.has(t[this.idProperty]))||[]}syncGridCellCssStyles(e,t){let n,o,r=a=>{n={},typeof a=="object"&&Object.keys(a).forEach(l=>{if(a){let d=this.rows[l][this.idProperty];n[d]=a[l]}})};r(e.getCellCssStyles(t));let i=()=>{if(typeof n=="object"){o=!0,this.ensureRowsByIdCache();let a={};Object.keys(n).forEach(l=>{let d=this.rowsById?.[l];Bn.isDefined(d)&&(a[d]=n[l])}),e.setCellCssStyles(t,a),o=!1}};e.onCellCssStylesChanged.subscribe((a,l)=>{o||t===l.key&&(l.hash?r(l.hash):(e.onCellCssStylesChanged.unsubscribe(),this.onRowsOrCountChanged.unsubscribe(i)))}),this.onRowsOrCountChanged.subscribe(i.bind(this))}},Rl=Lr,wd=uo,eu=class tu{constructor(t){this.args=t,T(this,"input"),T(this,"defaultValue"),T(this,"navOnLR"),this.init()}init(){this.navOnLR=this.args.grid.getOptions().editorCellNavOnLRKeys,this.input=wd.createDomElement("input",{type:"text",className:"editor-text"},this.args.container),this.input.addEventListener("keydown",this.navOnLR?rm:sm),this.input.focus(),this.input.select(),this.args.compositeEditorOptions&&this.input.addEventListener("change",this.onChange.bind(this))}onChange(){let t=this.args.grid.getActiveCell();this.validate().valid&&this.applyValue(this.args.item,this.serializeValue()),this.applyValue(this.args.compositeEditorOptions.formValues,this.serializeValue()),this.args.grid.onCompositeEditorChange.notify({row:t?.row??0,cell:t?.cell??0,item:this.args.item,column:this.args.column,formValues:this.args.compositeEditorOptions.formValues,grid:this.args.grid,editors:this.args.compositeEditorOptions.editors})}destroy(){this.input.removeEventListener("keydown",this.navOnLR?rm:sm),this.input.removeEventListener("change",this.onChange.bind(this)),this.input.remove()}focus(){this.input.focus()}getDecimalPlaces(){let t=this.args.column.editorFixedDecimalPlaces;return wd.isDefined(t)||(t=tu.DefaultDecimalPlaces),!t&&t!==0?null:t}loadValue(t){this.defaultValue=t[this.args.column.field];let n=this.getDecimalPlaces();n!==null&&(this.defaultValue||this.defaultValue===0)&&this.defaultValue?.toFixed&&(this.defaultValue=this.defaultValue.toFixed(n)),this.input.value=String(this.defaultValue??""),this.input.defaultValue=String(this.defaultValue??""),this.input.select()}serializeValue(){let t=parseFloat(this.input.value);tu.AllowEmptyValue?!t&&t!==0&&(t=void 0):t=t||0;let n=this.getDecimalPlaces();return n!==null&&(t||t===0)&&t.toFixed&&(t=parseFloat(t.toFixed(n))),t}applyValue(t,n){t[this.args.column.field]=n}isValueChanged(){return!(this.input.value===""&&!wd.isDefined(this.defaultValue))&&this.input.value!==this.defaultValue}validate(){if(isNaN(this.input.value))return{valid:!1,msg:"Please enter a valid number"};if(this.args.column.validator){let t=this.args.column.validator(this.input.value,this.args);if(!t.valid)return t}return{valid:!0,msg:null}}};T(eu,"DefaultDecimalPlaces"),T(eu,"AllowEmptyValue",!1);var om=eu;function rm(e){let t=e.selectionStart,n=e.target.value.length;(e.keyCode===Rl.LEFT&&t>0||e.keyCode===Rl.RIGHT&&t<n-1)&&e.stopImmediatePropagation()}function sm(e){(e.keyCode===Rl.LEFT||e.keyCode===Rl.RIGHT)&&e.stopImmediatePropagation()}var sA=pc,cr=kN,Fe=zr,li=Ki,iA=xN,_n=Sv,go=Lr,aA=RN,lA=uh,cs=TN,Rr=EN,L=uo,Cd=PN,im=hh,am=MN,lm=IN,cA=class{constructor(e,t,n,o,r){if(this.container=e,this.data=t,this.columns=n,this.externalPubSub=r,T(this,"slickGridVersion","5.15.5"),T(this,"cid",""),T(this,"onActiveCellChanged"),T(this,"onActiveCellPositionChanged"),T(this,"onAddNewRow"),T(this,"onAfterSetColumns"),T(this,"onAutosizeColumns"),T(this,"onBeforeAppendCell"),T(this,"onBeforeCellEditorDestroy"),T(this,"onBeforeColumnsResize"),T(this,"onBeforeDestroy"),T(this,"onBeforeEditCell"),T(this,"onBeforeFooterRowCellDestroy"),T(this,"onBeforeHeaderCellDestroy"),T(this,"onBeforeHeaderRowCellDestroy"),T(this,"onBeforeRemoveCachedRow"),T(this,"onBeforeSetColumns"),T(this,"onBeforeSort"),T(this,"onBeforeUpdateColumns"),T(this,"onCellChange"),T(this,"onCellCssStylesChanged"),T(this,"onClick"),T(this,"onColumnsReordered"),T(this,"onColumnsDrag"),T(this,"onColumnsResized"),T(this,"onColumnsResizeDblClick"),T(this,"onCompositeEditorChange"),T(this,"onContextMenu"),T(this,"onDrag"),T(this,"onDblClick"),T(this,"onDragInit"),T(this,"onDragStart"),T(this,"onDragEnd"),T(this,"onFooterClick"),T(this,"onFooterContextMenu"),T(this,"onFooterRowCellRendered"),T(this,"onHeaderCellRendered"),T(this,"onHeaderClick"),T(this,"onHeaderContextMenu"),T(this,"onHeaderMouseEnter"),T(this,"onHeaderMouseLeave"),T(this,"onHeaderRowCellRendered"),T(this,"onHeaderRowMouseEnter"),T(this,"onHeaderRowMouseLeave"),T(this,"onPreHeaderContextMenu"),T(this,"onPreHeaderClick"),T(this,"onKeyDown"),T(this,"onMouseEnter"),T(this,"onMouseLeave"),T(this,"onRendered"),T(this,"onScroll"),T(this,"onSelectedRowsChanged"),T(this,"onSetOptions"),T(this,"onActivateChangedOptions"),T(this,"onSort"),T(this,"onValidationError"),T(this,"onViewportChanged"),T(this,"scrollbarDimensions"),T(this,"maxSupportedCssHeight"),T(this,"canvas",null),T(this,"canvas_context",null),T(this,"_options"),T(this,"_defaults",{alwaysShowVerticalScroll:!1,alwaysAllowHorizontalScroll:!1,explicitInitialization:!1,rowHeight:25,defaultColumnWidth:80,enableHtmlRendering:!0,enableAddRow:!1,leaveSpaceForNewRows:!1,editable:!1,autoEdit:!0,autoEditNewRow:!0,autoCommitEdit:!1,suppressActiveCellChangeOnEdit:!1,enableCellNavigation:!0,enableColumnReorder:!0,unorderableColumnCssClass:"unorderable",asyncEditorLoading:!1,asyncEditorLoadDelay:100,forceFitColumns:!1,enableAsyncPostRender:!1,asyncPostRenderDelay:50,enableAsyncPostRenderCleanup:!1,asyncPostRenderCleanupDelay:40,auto:!1,nonce:"",editorLock:iA,showColumnHeader:!0,showHeaderRow:!1,headerRowHeight:25,createFooterRow:!1,showFooterRow:!1,footerRowHeight:25,createPreHeaderPanel:!1,createTopHeaderPanel:!1,showPreHeaderPanel:!1,showTopHeaderPanel:!1,preHeaderPanelHeight:25,showTopPanel:!1,topPanelHeight:25,preHeaderPanelWidth:"auto",topHeaderPanelHeight:25,topHeaderPanelWidth:"auto",formatterFactory:null,editorFactory:null,cellFlashingCssClass:"flashing",rowHighlightCssClass:"highlight-animate",rowHighlightDuration:400,selectedCellCssClass:"selected",multiSelect:!0,enableCellRowSpan:!1,enableTextSelectionOnCells:!1,dataItemColumnValueExtractor:null,frozenBottom:!1,frozenColumn:-1,frozenRow:-1,frozenRightViewportMinWidth:100,throwWhenFrozenNotAllViewable:!1,fullWidthRows:!1,multiColumnSort:!1,numberedMultiColumnSort:!1,tristateMultiColumnSort:!1,sortColNumberInSeparateSpan:!1,defaultFormatter:this.defaultFormatter,forceSyncScrolling:!1,addNewRowCssClass:"new-row",preserveCopiedSelectionOnPaste:!1,preventDragFromKeys:["ctrlKey","metaKey"],showCellSelection:!0,viewportClass:void 0,minRowBuffer:3,emulatePagingWhenScrolling:!0,editorCellNavOnLRKeys:!1,enableMouseWheelScrollHandler:!0,doPaging:!0,autosizeColsMode:_n.LegacyOff,autosizeColPaddingPx:4,rowTopOffsetRenderType:"top",scrollRenderThrottling:10,autosizeTextAvgToMWidthRatio:.75,viewportSwitchToScrollModeWidthPercent:void 0,viewportMinWidthPx:void 0,viewportMaxWidthPx:void 0,suppressCssChangesOnHiddenInit:!1,ffMaxSupportedCssHeight:6e6,maxSupportedCssHeight:1e9,maxPartialRowSpanRemap:5e3,sanitizer:void 0,logSanitizedHtml:!1,mixinDefaults:!0,shadowRoot:void 0}),T(this,"_columnDefaults",{name:"",headerCssClass:null,defaultSortAsc:!0,focusable:!0,hidden:!1,minWidth:30,maxWidth:void 0,rerenderOnResize:!1,reorderable:!0,resizable:!0,sortable:!1,selectable:!0}),T(this,"_columnAutosizeDefaults",{ignoreHeaderText:!1,colValueArray:void 0,allowAddlPercent:void 0,formatterOverride:void 0,autosizeMode:cr.ContentIntelligent,rowSelectionModeOnInit:void 0,rowSelectionMode:cs.FirstNRows,rowSelectionCount:100,valueFilterMode:Rr.None,widthEvalMode:Cd.Auto,sizeToRemaining:void 0,widthPx:void 0,contentSizePx:0,headerWidthPx:0,colDataTypeOf:void 0}),T(this,"_columnResizeTimer"),T(this,"_executionBlockTimer"),T(this,"_flashCellTimer"),T(this,"_highlightRowTimer"),T(this,"th"),T(this,"h"),T(this,"ph"),T(this,"n"),T(this,"cj"),T(this,"page",0),T(this,"offset",0),T(this,"vScrollDir",1),T(this,"_bindingEventService",new sA),T(this,"initialized",!1),T(this,"_container"),T(this,"uid",`slickgrid_${Math.round(1e6*Math.random())}`),T(this,"_focusSink"),T(this,"_focusSink2"),T(this,"_groupHeaders",[]),T(this,"_headerScroller",[]),T(this,"_headers",[]),T(this,"_headerRows"),T(this,"_headerRowScroller"),T(this,"_headerRowSpacerL"),T(this,"_headerRowSpacerR"),T(this,"_footerRow"),T(this,"_footerRowScroller"),T(this,"_footerRowSpacerL"),T(this,"_footerRowSpacerR"),T(this,"_preHeaderPanel"),T(this,"_preHeaderPanelScroller"),T(this,"_preHeaderPanelSpacer"),T(this,"_preHeaderPanelR"),T(this,"_preHeaderPanelScrollerR"),T(this,"_preHeaderPanelSpacerR"),T(this,"_topHeaderPanel"),T(this,"_topHeaderPanelScroller"),T(this,"_topHeaderPanelSpacer"),T(this,"_topPanelScrollers"),T(this,"_topPanels"),T(this,"_viewport"),T(this,"_canvas"),T(this,"_style"),T(this,"_boundAncestors",[]),T(this,"stylesheet"),T(this,"columnCssRulesL"),T(this,"columnCssRulesR"),T(this,"viewportH",0),T(this,"viewportW",0),T(this,"canvasWidth",0),T(this,"canvasWidthL",0),T(this,"canvasWidthR",0),T(this,"headersWidth",0),T(this,"headersWidthL",0),T(this,"headersWidthR",0),T(this,"viewportHasHScroll",!1),T(this,"viewportHasVScroll",!1),T(this,"headerColumnWidthDiff",0),T(this,"headerColumnHeightDiff",0),T(this,"cellWidthDiff",0),T(this,"cellHeightDiff",0),T(this,"absoluteColumnMinWidth"),T(this,"hasFrozenRows",!1),T(this,"frozenRowsHeight",0),T(this,"actualFrozenRow",-1),T(this,"paneTopH",0),T(this,"paneBottomH",0),T(this,"viewportTopH",0),T(this,"viewportBottomH",0),T(this,"topPanelH",0),T(this,"headerRowH",0),T(this,"footerRowH",0),T(this,"tabbingDirection",1),T(this,"_activeCanvasNode"),T(this,"_activeViewportNode"),T(this,"activePosX"),T(this,"activePosY"),T(this,"activeRow"),T(this,"activeCell"),T(this,"activeCellNode",null),T(this,"currentEditor",null),T(this,"serializedEditorValue"),T(this,"editController"),T(this,"_prevDataLength",0),T(this,"_prevInvalidatedRowsCount",0),T(this,"_rowSpanIsCached",!1),T(this,"_colsWithRowSpanCache",{}),T(this,"rowsCache",{}),T(this,"renderedRows",0),T(this,"numVisibleRows",0),T(this,"prevScrollTop",0),T(this,"scrollHeight",0),T(this,"scrollTop",0),T(this,"lastRenderedScrollTop",0),T(this,"lastRenderedScrollLeft",0),T(this,"prevScrollLeft",0),T(this,"scrollLeft",0),T(this,"selectionModel"),T(this,"selectedRows",[]),T(this,"plugins",[]),T(this,"cellCssClasses",{}),T(this,"columnsById",{}),T(this,"sortColumns",[]),T(this,"columnPosLeft",[]),T(this,"columnPosRight",[]),T(this,"pagingActive",!1),T(this,"pagingIsLastPage",!1),T(this,"scrollThrottle"),T(this,"h_editorLoader"),T(this,"h_postrender"),T(this,"h_postrenderCleanup"),T(this,"postProcessedRows",{}),T(this,"postProcessToRow",null),T(this,"postProcessFromRow",null),T(this,"postProcessedCleanupQueue",[]),T(this,"postProcessgroupId",0),T(this,"counter_rows_rendered",0),T(this,"counter_rows_removed",0),T(this,"_paneHeaderL"),T(this,"_paneHeaderR"),T(this,"_paneTopL"),T(this,"_paneTopR"),T(this,"_paneBottomL"),T(this,"_paneBottomR"),T(this,"_headerScrollerL"),T(this,"_headerScrollerR"),T(this,"_headerL"),T(this,"_headerR"),T(this,"_groupHeadersL"),T(this,"_groupHeadersR"),T(this,"_headerRowScrollerL"),T(this,"_headerRowScrollerR"),T(this,"_footerRowScrollerL"),T(this,"_footerRowScrollerR"),T(this,"_headerRowL"),T(this,"_headerRowR"),T(this,"_footerRowL"),T(this,"_footerRowR"),T(this,"_topPanelScrollerL"),T(this,"_topPanelScrollerR"),T(this,"_topPanelL"),T(this,"_topPanelR"),T(this,"_viewportTopL"),T(this,"_viewportTopR"),T(this,"_viewportBottomL"),T(this,"_viewportBottomR"),T(this,"_canvasTopL"),T(this,"_canvasTopR"),T(this,"_canvasBottomL"),T(this,"_canvasBottomR"),T(this,"_viewportScrollContainerX"),T(this,"_viewportScrollContainerY"),T(this,"_headerScrollContainer"),T(this,"_headerRowScrollContainer"),T(this,"_footerRowScrollContainer"),T(this,"cssShow",{position:"absolute",visibility:"hidden",display:"block"}),T(this,"_hiddenParents",[]),T(this,"oldProps",[]),T(this,"enforceFrozenRowHeightRecalc",!1),T(this,"columnResizeDragging",!1),T(this,"slickDraggableInstance",null),T(this,"slickMouseWheelInstances",[]),T(this,"slickResizableInstances",[]),T(this,"sortableSideLeftInstance"),T(this,"sortableSideRightInstance"),T(this,"logMessageCount",0),T(this,"logMessageMaxCount",30),T(this,"_pubSubService"),this._container=typeof this.container=="string"?document.querySelector(this.container):this.container,!this._container)throw new Error(`SlickGrid requires a valid container, ${this.container} does not exist in the DOM.`);this._pubSubService=r,this.onActiveCellChanged=new Fe("onActiveCellChanged",r),this.onActiveCellPositionChanged=new Fe("onActiveCellPositionChanged",r),this.onAddNewRow=new Fe("onAddNewRow",r),this.onAfterSetColumns=new Fe("onAfterSetColumns",r),this.onAutosizeColumns=new Fe("onAutosizeColumns",r),this.onBeforeAppendCell=new Fe("onBeforeAppendCell",r),this.onBeforeCellEditorDestroy=new Fe("onBeforeCellEditorDestroy",r),this.onBeforeColumnsResize=new Fe("onBeforeColumnsResize",r),this.onBeforeDestroy=new Fe("onBeforeDestroy",r),this.onBeforeEditCell=new Fe("onBeforeEditCell",r),this.onBeforeFooterRowCellDestroy=new Fe("onBeforeFooterRowCellDestroy",r),this.onBeforeHeaderCellDestroy=new Fe("onBeforeHeaderCellDestroy",r),this.onBeforeHeaderRowCellDestroy=new Fe("onBeforeHeaderRowCellDestroy",r),this.onBeforeRemoveCachedRow=new Fe("onRowRemovedFromCache",r),this.onBeforeSetColumns=new Fe("onBeforeSetColumns",r),this.onBeforeSort=new Fe("onBeforeSort",r),this.onBeforeUpdateColumns=new Fe("onBeforeUpdateColumns",r),this.onCellChange=new Fe("onCellChange",r),this.onCellCssStylesChanged=new Fe("onCellCssStylesChanged",r),this.onClick=new Fe("onClick",r),this.onColumnsReordered=new Fe("onColumnsReordered",r),this.onColumnsDrag=new Fe("onColumnsDrag",r),this.onColumnsResized=new Fe("onColumnsResized",r),this.onColumnsResizeDblClick=new Fe("onColumnsResizeDblClick",r),this.onCompositeEditorChange=new Fe("onCompositeEditorChange",r),this.onContextMenu=new Fe("onContextMenu",r),this.onDrag=new Fe("onDrag",r),this.onDblClick=new Fe("onDblClick",r),this.onDragInit=new Fe("onDragInit",r),this.onDragStart=new Fe("onDragStart",r),this.onDragEnd=new Fe("onDragEnd",r),this.onFooterClick=new Fe("onFooterClick",r),this.onFooterContextMenu=new Fe("onFooterContextMenu",r),this.onFooterRowCellRendered=new Fe("onFooterRowCellRendered",r),this.onHeaderCellRendered=new Fe("onHeaderCellRendered",r),this.onHeaderClick=new Fe("onHeaderClick",r),this.onHeaderContextMenu=new Fe("onHeaderContextMenu",r),this.onHeaderMouseEnter=new Fe("onHeaderMouseEnter",r),this.onHeaderMouseLeave=new Fe("onHeaderMouseLeave",r),this.onHeaderRowCellRendered=new Fe("onHeaderRowCellRendered",r),this.onHeaderRowMouseEnter=new Fe("onHeaderRowMouseEnter",r),this.onHeaderRowMouseLeave=new Fe("onHeaderRowMouseLeave",r),this.onPreHeaderClick=new Fe("onPreHeaderClick",r),this.onPreHeaderContextMenu=new Fe("onPreHeaderContextMenu",r),this.onKeyDown=new Fe("onKeyDown",r),this.onMouseEnter=new Fe("onMouseEnter",r),this.onMouseLeave=new Fe("onMouseLeave",r),this.onRendered=new Fe("onRendered",r),this.onScroll=new Fe("onScroll",r),this.onSelectedRowsChanged=new Fe("onSelectedRowsChanged",r),this.onSetOptions=new Fe("onSetOptions",r),this.onActivateChangedOptions=new Fe("onActivateChangedOptions",r),this.onSort=new Fe("onSort",r),this.onValidationError=new Fe("onValidationError",r),this.onViewportChanged=new Fe("onViewportChanged",r),this.initialize(o)}init(){this.finishInitialization()}initialize(e){if(e?.mixinDefaults?(this._options||(this._options=e),L.applyDefaults(this._options,this._defaults)):this._options=L.extend(!0,{},this._defaults,e),this.scrollThrottle=this.actionThrottle(this.render.bind(this),this._options.scrollRenderThrottling),this.maxSupportedCssHeight=this.maxSupportedCssHeight||this.getMaxSupportedCssHeight(),this.validateAndEnforceOptions(),this._columnDefaults.width=this._options.defaultColumnWidth,this._options.suppressCssChangesOnHiddenInit||this.cacheCssForHiddenInit(),this.updateColumnProps(),this._options.enableColumnReorder&&(!Sortable||!Sortable.create))throw new Error("SlickGrid requires Sortable.js module to be loaded");this.editController={commitCurrentEdit:this.commitCurrentEdit.bind(this),cancelCurrentEdit:this.cancelCurrentEdit.bind(this)},L.emptyElement(this._container),this._container.style.outline=String(0),this._container.classList.add(this.uid),this._container.classList.add("ui-widget"),this._container.setAttribute("role","grid");let t=window.getComputedStyle(this._container);/relative|absolute|fixed/.test(t.position)||(this._container.style.position="relative"),this._focusSink=L.createDomElement("div",{tabIndex:0,style:{position:"fixed",width:"0px",height:"0px",top:"0px",left:"0px",outline:"0px"}},this._container),this._options.createTopHeaderPanel&&(this._topHeaderPanelScroller=L.createDomElement("div",{className:"slick-topheader-panel slick-state-default",style:{overflow:"hidden",position:"relative"}},this._container),this._topHeaderPanelScroller.appendChild(document.createElement("div")),this._topHeaderPanel=L.createDomElement("div",null,this._topHeaderPanelScroller),this._topHeaderPanelSpacer=L.createDomElement("div",{style:{display:"block",height:"1px",position:"absolute",top:"0px",left:"0px"}},this._topHeaderPanelScroller),this._options.showTopHeaderPanel||L.hide(this._topHeaderPanelScroller)),this._paneHeaderL=L.createDomElement("div",{className:"slick-pane slick-pane-header slick-pane-left",tabIndex:0},this._container),this._paneHeaderR=L.createDomElement("div",{className:"slick-pane slick-pane-header slick-pane-right",tabIndex:0},this._container),this._paneTopL=L.createDomElement("div",{className:"slick-pane slick-pane-top slick-pane-left",tabIndex:0},this._container),this._paneTopR=L.createDomElement("div",{className:"slick-pane slick-pane-top slick-pane-right",tabIndex:0},this._container),this._paneBottomL=L.createDomElement("div",{className:"slick-pane slick-pane-bottom slick-pane-left",tabIndex:0},this._container),this._paneBottomR=L.createDomElement("div",{className:"slick-pane slick-pane-bottom slick-pane-right",tabIndex:0},this._container),this._options.createPreHeaderPanel&&(this._preHeaderPanelScroller=L.createDomElement("div",{className:"slick-preheader-panel ui-state-default slick-state-default",style:{overflow:"hidden",position:"relative"}},this._paneHeaderL),this._preHeaderPanelScroller.appendChild(document.createElement("div")),this._preHeaderPanel=L.createDomElement("div",null,this._preHeaderPanelScroller),this._preHeaderPanelSpacer=L.createDomElement("div",{style:{display:"block",height:"1px",position:"absolute",top:"0px",left:"0px"}},this._preHeaderPanelScroller),this._preHeaderPanelScrollerR=L.createDomElement("div",{className:"slick-preheader-panel ui-state-default slick-state-default",style:{overflow:"hidden",position:"relative"}},this._paneHeaderR),this._preHeaderPanelR=L.createDomElement("div",null,this._preHeaderPanelScrollerR),this._preHeaderPanelSpacerR=L.createDomElement("div",{style:{display:"block",height:"1px",position:"absolute",top:"0px",left:"0px"}},this._preHeaderPanelScrollerR),this._options.showPreHeaderPanel||(L.hide(this._preHeaderPanelScroller),L.hide(this._preHeaderPanelScrollerR))),this._headerScrollerL=L.createDomElement("div",{className:"slick-header ui-state-default slick-state-default slick-header-left"},this._paneHeaderL),this._headerScrollerR=L.createDomElement("div",{className:"slick-header ui-state-default slick-state-default slick-header-right"},this._paneHeaderR),this._headerScroller.push(this._headerScrollerL),this._headerScroller.push(this._headerScrollerR),this._headerL=L.createDomElement("div",{className:"slick-header-columns slick-header-columns-left",role:"row",style:{left:"-1000px"}},this._headerScrollerL),this._headerR=L.createDomElement("div",{className:"slick-header-columns slick-header-columns-right",role:"row",style:{left:"-1000px"}},this._headerScrollerR),this._headers=[this._headerL,this._headerR],this._headerRowScrollerL=L.createDomElement("div",{className:"slick-headerrow ui-state-default slick-state-default"},this._paneTopL),this._headerRowScrollerR=L.createDomElement("div",{className:"slick-headerrow ui-state-default slick-state-default"},this._paneTopR),this._headerRowScroller=[this._headerRowScrollerL,this._headerRowScrollerR],this._headerRowSpacerL=L.createDomElement("div",{style:{display:"block",height:"1px",position:"absolute",top:"0px",left:"0px"}},this._headerRowScrollerL),this._headerRowSpacerR=L.createDomElement("div",{style:{display:"block",height:"1px",position:"absolute",top:"0px",left:"0px"}},this._headerRowScrollerR),this._headerRowL=L.createDomElement("div",{className:"slick-headerrow-columns slick-headerrow-columns-left"},this._headerRowScrollerL),this._headerRowR=L.createDomElement("div",{className:"slick-headerrow-columns slick-headerrow-columns-right"},this._headerRowScrollerR),this._headerRows=[this._headerRowL,this._headerRowR],this._topPanelScrollerL=L.createDomElement("div",{className:"slick-top-panel-scroller ui-state-default slick-state-default"},this._paneTopL),this._topPanelScrollerR=L.createDomElement("div",{className:"slick-top-panel-scroller ui-state-default slick-state-default"},this._paneTopR),this._topPanelScrollers=[this._topPanelScrollerL,this._topPanelScrollerR],this._topPanelL=L.createDomElement("div",{className:"slick-top-panel",style:{width:"10000px"}},this._topPanelScrollerL),this._topPanelR=L.createDomElement("div",{className:"slick-top-panel",style:{width:"10000px"}},this._topPanelScrollerR),this._topPanels=[this._topPanelL,this._topPanelR],this._options.showColumnHeader||this._headerScroller.forEach(o=>{L.hide(o)}),this._options.showTopPanel||this._topPanelScrollers.forEach(o=>{L.hide(o)}),this._options.showHeaderRow||this._headerRowScroller.forEach(o=>{L.hide(o)}),this._viewportTopL=L.createDomElement("div",{className:"slick-viewport slick-viewport-top slick-viewport-left",tabIndex:0},this._paneTopL),this._viewportTopR=L.createDomElement("div",{className:"slick-viewport slick-viewport-top slick-viewport-right",tabIndex:0},this._paneTopR),this._viewportBottomL=L.createDomElement("div",{className:"slick-viewport slick-viewport-bottom slick-viewport-left",tabIndex:0},this._paneBottomL),this._viewportBottomR=L.createDomElement("div",{className:"slick-viewport slick-viewport-bottom slick-viewport-right",tabIndex:0},this._paneBottomR),this._viewport=[this._viewportTopL,this._viewportTopR,this._viewportBottomL,this._viewportBottomR],this._options.viewportClass&&this._viewport.forEach(o=>{o.classList.add(...L.classNameToList(this._options.viewportClass))}),this._activeViewportNode=this._viewportTopL,this._canvasTopL=L.createDomElement("div",{className:"grid-canvas grid-canvas-top grid-canvas-left",tabIndex:0},this._viewportTopL),this._canvasTopR=L.createDomElement("div",{className:"grid-canvas grid-canvas-top grid-canvas-right",tabIndex:0},this._viewportTopR),this._canvasBottomL=L.createDomElement("div",{className:"grid-canvas grid-canvas-bottom grid-canvas-left",tabIndex:0},this._viewportBottomL),this._canvasBottomR=L.createDomElement("div",{className:"grid-canvas grid-canvas-bottom grid-canvas-right",tabIndex:0},this._viewportBottomR),this._canvas=[this._canvasTopL,this._canvasTopR,this._canvasBottomL,this._canvasBottomR],this.scrollbarDimensions=this.scrollbarDimensions||this.measureScrollbar();let n=this.getCanvasWidth()+this.scrollbarDimensions.width;this._activeCanvasNode=this._canvasTopL,this._topHeaderPanelSpacer&&L.width(this._topHeaderPanelSpacer,n),this._preHeaderPanelSpacer&&L.width(this._preHeaderPanelSpacer,n),this._headers.forEach(o=>{L.width(o,this.getHeadersWidth())}),L.width(this._headerRowSpacerL,n),L.width(this._headerRowSpacerR,n),this._options.createFooterRow&&(this._footerRowScrollerR=L.createDomElement("div",{className:"slick-footerrow ui-state-default slick-state-default"},this._paneTopR),this._footerRowScrollerL=L.createDomElement("div",{className:"slick-footerrow ui-state-default slick-state-default"},this._paneTopL),this._footerRowScroller=[this._footerRowScrollerL,this._footerRowScrollerR],this._footerRowSpacerL=L.createDomElement("div",{style:{display:"block",height:"1px",position:"absolute",top:"0px",left:"0px"}},this._footerRowScrollerL),L.width(this._footerRowSpacerL,n),this._footerRowSpacerR=L.createDomElement("div",{style:{display:"block",height:"1px",position:"absolute",top:"0px",left:"0px"}},this._footerRowScrollerR),L.width(this._footerRowSpacerR,n),this._footerRowL=L.createDomElement("div",{className:"slick-footerrow-columns slick-footerrow-columns-left"},this._footerRowScrollerL),this._footerRowR=L.createDomElement("div",{className:"slick-footerrow-columns slick-footerrow-columns-right"},this._footerRowScrollerR),this._footerRow=[this._footerRowL,this._footerRowR],this._options.showFooterRow||this._footerRowScroller.forEach(o=>{L.hide(o)})),this._focusSink2=this._focusSink.cloneNode(!0),this._container.appendChild(this._focusSink2),this._options.explicitInitialization||this.finishInitialization()}finishInitialization(){this.initialized||(this.initialized=!0,this.getViewportWidth(),this.getViewportHeight(),this.measureCellPaddingAndBorder(),this.disableSelection(this._headers),this._options.enableTextSelectionOnCells||this._viewport.forEach(e=>{this._bindingEventService.bind(e,"selectstart",t=>{t.target instanceof HTMLInputElement||t.target instanceof HTMLTextAreaElement})}),this.setFrozenOptions(),this.setPaneFrozenClasses(),this.setPaneVisibility(),this.setScroller(),this.setOverflow(),this.updateColumnCaches(),this.createColumnHeaders(),this.createColumnFooter(),this.setupColumnSort(),this.createCssRules(),this.resizeCanvas(),this.bindAncestorScrollEvents(),this._bindingEventService.bind(this._container,"resize",this.resizeCanvas.bind(this)),this._viewport.forEach(e=>{this._bindingEventService.bind(e,"scroll",this.handleScroll.bind(this))}),this._options.enableMouseWheelScrollHandler&&this._viewport.forEach(e=>{this.slickMouseWheelInstances.push(am({element:e,onMouseWheel:this.handleMouseWheel.bind(this)}))}),this._headerScroller.forEach(e=>{this._bindingEventService.bind(e,"contextmenu",this.handleHeaderContextMenu.bind(this)),this._bindingEventService.bind(e,"click",this.handleHeaderClick.bind(this))}),this._headerRowScroller.forEach(e=>{this._bindingEventService.bind(e,"scroll",this.handleHeaderRowScroll.bind(this))}),this._options.createFooterRow&&(this._footerRow.forEach(e=>{this._bindingEventService.bind(e,"contextmenu",this.handleFooterContextMenu.bind(this)),this._bindingEventService.bind(e,"click",this.handleFooterClick.bind(this))}),this._footerRowScroller.forEach(e=>{this._bindingEventService.bind(e,"scroll",this.handleFooterRowScroll.bind(this))})),this._options.createTopHeaderPanel&&this._bindingEventService.bind(this._topHeaderPanelScroller,"scroll",this.handleTopHeaderPanelScroll.bind(this)),this._options.createPreHeaderPanel&&(this._bindingEventService.bind(this._preHeaderPanelScroller,"scroll",this.handlePreHeaderPanelScroll.bind(this)),this._bindingEventService.bind(this._preHeaderPanelScroller,"contextmenu",this.handlePreHeaderContextMenu.bind(this)),this._bindingEventService.bind(this._preHeaderPanelScrollerR,"contextmenu",this.handlePreHeaderContextMenu.bind(this)),this._bindingEventService.bind(this._preHeaderPanelScroller,"click",this.handlePreHeaderClick.bind(this)),this._bindingEventService.bind(this._preHeaderPanelScrollerR,"click",this.handlePreHeaderClick.bind(this))),this._bindingEventService.bind(this._focusSink,"keydown",this.handleKeyDown.bind(this)),this._bindingEventService.bind(this._focusSink2,"keydown",this.handleKeyDown.bind(this)),this._canvas.forEach(e=>{this._bindingEventService.bind(e,"keydown",this.handleKeyDown.bind(this)),this._bindingEventService.bind(e,"click",this.handleClick.bind(this)),this._bindingEventService.bind(e,"dblclick",this.handleDblClick.bind(this)),this._bindingEventService.bind(e,"contextmenu",this.handleContextMenu.bind(this)),this._bindingEventService.bind(e,"mouseover",this.handleCellMouseOver.bind(this)),this._bindingEventService.bind(e,"mouseout",this.handleCellMouseOut.bind(this))}),im&&(this.slickDraggableInstance=im({containerElement:this._container,allowDragFrom:"div.slick-cell",allowDragFromClosest:"div.slick-cell.dnd, div.slick-cell.cell-reorder",preventDragFromKeys:this._options.preventDragFromKeys,onDragInit:this.handleDragInit.bind(this),onDragStart:this.handleDragStart.bind(this),onDrag:this.handleDrag.bind(this),onDragEnd:this.handleDragEnd.bind(this)})),this._options.suppressCssChangesOnHiddenInit||this.restoreCssFromHiddenInit())}cacheCssForHiddenInit(){this._hiddenParents=L.parents(this._container,":hidden"),this.oldProps=[],this._hiddenParents.forEach(e=>{let t={};Object.keys(this.cssShow).forEach(n=>{this.cssShow&&(t[n]=e.style[n],e.style[n]=this.cssShow[n])}),this.oldProps.push(t)})}restoreCssFromHiddenInit(){let e=0;this._hiddenParents&&(this._hiddenParents.forEach(t=>{let n=this.oldProps[e++];Object.keys(this.cssShow).forEach(o=>{this.cssShow&&(t.style[o]=n[o])})}),this._hiddenParents=[])}registerPlugin(e){this.plugins.unshift(e),e.init(this)}unregisterPlugin(e){for(let t=this.plugins.length;t>=0;t--)if(this.plugins[t]===e){this.plugins[t]?.destroy(),this.plugins.splice(t,1);break}}destroy(e){this._bindingEventService.unbindAll(),this.slickDraggableInstance=this.destroyAllInstances(this.slickDraggableInstance),this.slickMouseWheelInstances=this.destroyAllInstances(this.slickMouseWheelInstances),this.slickResizableInstances=this.destroyAllInstances(this.slickResizableInstances),this.getEditorLock()?.cancelCurrentEdit(),this.trigger(this.onBeforeDestroy,{});let t=this.plugins.length;for(;t--;)this.unregisterPlugin(this.plugins[t]);this._options.enableColumnReorder&&typeof this.sortableSideLeftInstance?.destroy=="function"&&(this.sortableSideLeftInstance?.destroy(),this.sortableSideRightInstance?.destroy()),this.unbindAncestorScrollEvents(),this._bindingEventService.unbindByEventName(this._container,"resize"),this.removeCssRules(),this._canvas.forEach(r=>{this._bindingEventService.unbindByEventName(r,"keydown"),this._bindingEventService.unbindByEventName(r,"click"),this._bindingEventService.unbindByEventName(r,"dblclick"),this._bindingEventService.unbindByEventName(r,"contextmenu"),this._bindingEventService.unbindByEventName(r,"mouseover"),this._bindingEventService.unbindByEventName(r,"mouseout")}),this._viewport.forEach(r=>{this._bindingEventService.unbindByEventName(r,"scroll")}),this._headerScroller.forEach(r=>{this._bindingEventService.unbindByEventName(r,"contextmenu"),this._bindingEventService.unbindByEventName(r,"click")}),this._headerRowScroller.forEach(r=>{this._bindingEventService.unbindByEventName(r,"scroll")}),this._footerRow&&this._footerRow.forEach(r=>{this._bindingEventService.unbindByEventName(r,"contextmenu"),this._bindingEventService.unbindByEventName(r,"click")}),this._footerRowScroller&&this._footerRowScroller.forEach(r=>{this._bindingEventService.unbindByEventName(r,"scroll")}),this._preHeaderPanelScroller&&this._bindingEventService.unbindByEventName(this._preHeaderPanelScroller,"scroll"),this._topHeaderPanelScroller&&this._bindingEventService.unbindByEventName(this._topHeaderPanelScroller,"scroll"),this._bindingEventService.unbindByEventName(this._focusSink,"keydown"),this._bindingEventService.unbindByEventName(this._focusSink2,"keydown");let n=this._container.querySelectorAll(".slick-resizable-handle");[].forEach.call(n,r=>{this._bindingEventService.unbindByEventName(r,"dblclick")});let o=this._container.querySelectorAll(".slick-header-column");[].forEach.call(o,r=>{this._bindingEventService.unbindByEventName(r,"mouseenter"),this._bindingEventService.unbindByEventName(r,"mouseleave"),this._bindingEventService.unbindByEventName(r,"mouseenter"),this._bindingEventService.unbindByEventName(r,"mouseleave")}),L.emptyElement(this._container),this._container.classList.remove(this.uid),this.clearAllTimers(),e&&this.destroyAllElements()}destroyAllInstances(e){if(e){let t=Array.isArray(e)?e:[e],n;for(;L.isDefined(n=t.pop());)n&&typeof n.destroy=="function"&&n.destroy()}return e=Array.isArray(e)?[]:null,e}destroyAllElements(){this._activeCanvasNode=null,this._activeViewportNode=null,this._boundAncestors=null,this._canvas=null,this._canvasTopL=null,this._canvasTopR=null,this._canvasBottomL=null,this._canvasBottomR=null,this._container=null,this._focusSink=null,this._focusSink2=null,this._groupHeaders=null,this._groupHeadersL=null,this._groupHeadersR=null,this._headerL=null,this._headerR=null,this._headers=null,this._headerRows=null,this._headerRowL=null,this._headerRowR=null,this._headerRowSpacerL=null,this._headerRowSpacerR=null,this._headerRowScrollContainer=null,this._headerRowScroller=null,this._headerRowScrollerL=null,this._headerRowScrollerR=null,this._headerScrollContainer=null,this._headerScroller=null,this._headerScrollerL=null,this._headerScrollerR=null,this._hiddenParents=null,this._footerRow=null,this._footerRowL=null,this._footerRowR=null,this._footerRowSpacerL=null,this._footerRowSpacerR=null,this._footerRowScroller=null,this._footerRowScrollerL=null,this._footerRowScrollerR=null,this._footerRowScrollContainer=null,this._preHeaderPanel=null,this._preHeaderPanelR=null,this._preHeaderPanelScroller=null,this._preHeaderPanelScrollerR=null,this._preHeaderPanelSpacer=null,this._preHeaderPanelSpacerR=null,this._topPanels=null,this._topPanelScrollers=null,this._style=null,this._topPanelScrollerL=null,this._topPanelScrollerR=null,this._topPanelL=null,this._topPanelR=null,this._paneHeaderL=null,this._paneHeaderR=null,this._paneTopL=null,this._paneTopR=null,this._paneBottomL=null,this._paneBottomR=null,this._viewport=null,this._viewportTopL=null,this._viewportTopR=null,this._viewportBottomL=null,this._viewportBottomR=null,this._viewportScrollContainerX=null,this._viewportScrollContainerY=null}getOptions(){return this._options}setOptions(e,t,n,o){this.prepareForOptionsChange(),this._options.enableAddRow!==e.enableAddRow&&this.invalidateRow(this.getDataLength()),e.frozenColumn!==void 0&&e.frozenColumn>=0&&(this.getViewports().forEach(i=>i.scrollLeft=0),this.handleScroll());let r=L.extend(!0,{},this._options);this._options=L.extend(this._options,e),this.trigger(this.onSetOptions,{optionsBefore:r,optionsAfter:this._options}),this.internal_setOptions(t,n,o)}activateChangedOptions(e,t,n){this.prepareForOptionsChange(),this.invalidateRow(this.getDataLength()),this.trigger(this.onActivateChangedOptions,{options:this._options}),this.internal_setOptions(e,t,n)}prepareForOptionsChange(){this.getEditorLock().commitCurrentEdit()&&this.makeActiveCellNormal()}internal_setOptions(e,t,n){this._options.showColumnHeader!==void 0&&this.setColumnHeaderVisibility(this._options.showColumnHeader),this.validateAndEnforceOptions(),this.setFrozenOptions(),this._options.frozenBottom!==void 0&&(this.enforceFrozenRowHeightRecalc=!0),this._viewport.forEach(o=>{o.style.overflowY=this._options.autoHeight?"hidden":"auto"}),e||this.render(),this.setScroller(),n||this.setOverflow(),t||this.setColumns(this.columns),this._options.enableMouseWheelScrollHandler&&this._viewport&&(!this.slickMouseWheelInstances||this.slickMouseWheelInstances.length===0)?this._viewport.forEach(o=>{this.slickMouseWheelInstances.push(am({element:o,onMouseWheel:this.handleMouseWheel.bind(this)}))}):this._options.enableMouseWheelScrollHandler===!1&&this.destroyAllInstances(this.slickMouseWheelInstances)}validateAndEnforceOptions(){this._options.autoHeight&&(this._options.leaveSpaceForNewRows=!1),this._options.forceFitColumns&&(this._options.autosizeColsMode=_n.LegacyForceFit)}setSelectionModel(e){this.selectionModel&&(this.selectionModel.onSelectedRangesChanged.unsubscribe(this.handleSelectedRangesChanged.bind(this)),this.selectionModel.destroy&&this.selectionModel.destroy()),this.selectionModel=e,this.selectionModel&&(this.selectionModel.init(this),this.selectionModel.onSelectedRangesChanged.subscribe(this.handleSelectedRangesChanged.bind(this)))}getSelectionModel(){return this.selectionModel}setPaneFrozenClasses(){let e=this.hasFrozenColumns()?"add":"remove";for(let t of[this._paneHeaderL,this._paneTopL,this._paneBottomL])t.classList[e]("frozen")}hasFrozenColumns(){return this._options.frozenColumn>-1}updateColumnHeader(e,t,n){if(this.initialized){let o=this.getColumnIndex(e);if(!L.isDefined(o))return;let r=this.columns[o],i=this.getColumnByIndex(o);i&&(t!==void 0&&(this.columns[o].name=t),n!==void 0&&(this.columns[o].toolTip=n),this.trigger(this.onBeforeHeaderCellDestroy,{node:i,column:r,grid:this}),i.setAttribute("title",n||""),t!==void 0&&this.applyHtmlCode(i.children[0],t),this.trigger(this.onHeaderCellRendered,{node:i,column:r,grid:this}))}}getHeader(e){if(!e)return this.hasFrozenColumns()?this._headers:this._headerL;let t=this.getColumnIndex(e.id);return this.hasFrozenColumns()?t<=this._options.frozenColumn?this._headerL:this._headerR:this._headerL}getHeaderColumn(e){let t=typeof e=="number"?e:this.getColumnIndex(e),n=this.hasFrozenColumns()?t<=this._options.frozenColumn?this._headerL:this._headerR:this._headerL,o=this.hasFrozenColumns()?t<=this._options.frozenColumn?t:t-this._options.frozenColumn-1:t;return n.children[o]}getHeaderRow(){return this.hasFrozenColumns()?this._headerRows:this._headerRows[0]}getFooterRow(){return this.hasFrozenColumns()?this._footerRow:this._footerRow[0]}getHeaderRowColumn(e){let t=typeof e=="number"?e:this.getColumnIndex(e),n;return this.hasFrozenColumns()?t<=this._options.frozenColumn?n=this._headerRowL:(n=this._headerRowR,t-=this._options.frozenColumn+1):n=this._headerRowL,n.children[t]}getFooterRowColumn(e){let t=typeof e=="number"?e:this.getColumnIndex(e),n;return this.hasFrozenColumns()?t<=this._options.frozenColumn?n=this._footerRowL:(n=this._footerRowR,t-=this._options.frozenColumn+1):n=this._footerRowL,n.children[t]}createColumnFooter(){if(this._options.createFooterRow){this._footerRow.forEach(e=>{e.querySelectorAll(".slick-footerrow-column").forEach(t=>{let n=L.storage.get(t,"column");this.trigger(this.onBeforeFooterRowCellDestroy,{node:t,column:n,grid:this})})}),L.emptyElement(this._footerRowL),L.emptyElement(this._footerRowR);for(let e=0;e<this.columns.length;e++){let t=this.columns[e];if(!t||t.hidden)continue;let n=L.createDomElement("div",{className:`ui-state-default slick-state-default slick-footerrow-column l${e} r${e}`},this.hasFrozenColumns()&&e>this._options.frozenColumn?this._footerRowR:this._footerRowL),o=this.hasFrozenColumns()&&e<=this._options.frozenColumn?"frozen":null;o&&n.classList.add(o),L.storage.put(n,"column",t),this.trigger(this.onFooterRowCellRendered,{node:n,column:t,grid:this})}}}setupColumnSort(){this._headers.forEach(e=>{this._bindingEventService.bind(e,"click",t=>{if(this.columnResizeDragging||t.target.classList.contains("slick-resizable-handle"))return;let n=t.target.closest(".slick-header-column");if(!n)return;let o=L.storage.get(n,"column");if(o.sortable){if(!this.getEditorLock()?.commitCurrentEdit())return;let r=this.sortColumns.slice(),i=null,a=0;for(;a<this.sortColumns.length;a++)if(this.sortColumns[a].columnId===o.id){i=this.sortColumns[a],i.sortAsc=!i.sortAsc;break}let l=!!i;this._options.tristateMultiColumnSort?(i||(i={columnId:o.id,sortAsc:o.defaultSortAsc,sortCol:o}),l&&i.sortAsc&&(this.sortColumns.splice(a,1),i=null),this._options.multiColumnSort||(this.sortColumns=[]),i&&(!l||!this._options.multiColumnSort)&&this.sortColumns.push(i)):t.metaKey&&this._options.multiColumnSort?i&&this.sortColumns.splice(a,1):((!t.shiftKey&&!t.metaKey||!this._options.multiColumnSort)&&(this.sortColumns=[]),i?this.sortColumns.length===0&&this.sortColumns.push(i):(i={columnId:o.id,sortAsc:o.defaultSortAsc,sortCol:o},this.sortColumns.push(i)));let d;this._options.multiColumnSort?d={multiColumnSort:!0,previousSortColumns:r,sortCols:this.sortColumns.map(u=>{let f=this.columns[this.getColumnIndex(u.columnId)];return!f||f.hidden?null:{columnId:f.id,sortCol:f,sortAsc:u.sortAsc}}).filter(u=>u)}:d={multiColumnSort:!1,previousSortColumns:r,columnId:this.sortColumns.length>0?o.id:null,sortCol:this.sortColumns.length>0?o:null,sortAsc:this.sortColumns.length>0?this.sortColumns[0].sortAsc:!0},this.trigger(this.onBeforeSort,d,t).getReturnValue()!==!1&&(this.setSortColumns(this.sortColumns),this.trigger(this.onSort,d,t))}})})}createColumnHeaders(){this._headers.forEach(e=>{e.querySelectorAll(".slick-header-column").forEach(t=>{let n=L.storage.get(t,"column");n&&this.trigger(this.onBeforeHeaderCellDestroy,{node:t,column:n,grid:this})})}),L.emptyElement(this._headerL),L.emptyElement(this._headerR),this.getHeadersWidth(),L.width(this._headerL,this.headersWidthL),L.width(this._headerR,this.headersWidthR),this._headerRows.forEach(e=>{e.querySelectorAll(".slick-headerrow-column").forEach(t=>{let n=L.storage.get(t,"column");n&&this.trigger(this.onBeforeHeaderRowCellDestroy,{node:this,column:n,grid:this})})}),L.emptyElement(this._headerRowL),L.emptyElement(this._headerRowR),this._options.createFooterRow&&(this._footerRowL.querySelectorAll(".slick-footerrow-column").forEach(e=>{let t=L.storage.get(e,"column");t&&this.trigger(this.onBeforeFooterRowCellDestroy,{node:this,column:t,grid:this})}),L.emptyElement(this._footerRowL),this.hasFrozenColumns()&&(this._footerRowR.querySelectorAll(".slick-footerrow-column").forEach(e=>{let t=L.storage.get(e,"column");t&&this.trigger(this.onBeforeFooterRowCellDestroy,{node:this,column:t,grid:this})}),L.emptyElement(this._footerRowR)));for(let e=0;e<this.columns.length;e++){let t=this.columns[e];if(t.hidden)continue;let n=this.hasFrozenColumns()?e<=this._options.frozenColumn?this._headerL:this._headerR:this._headerL,o=this.hasFrozenColumns()?e<=this._options.frozenColumn?this._headerRowL:this._headerRowR:this._headerRowL,r=L.createDomElement("div",{id:`${this.uid+t.id}`,dataset:{id:String(t.id)},role:"columnheader",className:"ui-state-default slick-state-default slick-header-column"},n);t.toolTip&&(r.title=t.toolTip),t.reorderable||r.classList.add(this._options.unorderableColumnCssClass);let i=L.createDomElement("span",{className:"slick-column-name"},r);this.applyHtmlCode(i,t.name),L.width(r,t.width-this.headerColumnWidthDiff);let a=t.headerCssClass||null;if(a&&r.classList.add(...L.classNameToList(a)),a=this.hasFrozenColumns()&&e<=this._options.frozenColumn?"frozen":null,a&&r.classList.add(a),this._bindingEventService.bind(r,"mouseenter",this.handleHeaderMouseEnter.bind(this)),this._bindingEventService.bind(r,"mouseleave",this.handleHeaderMouseLeave.bind(this)),L.storage.put(r,"column",t),(this._options.enableColumnReorder||t.sortable)&&(this._bindingEventService.bind(r,"mouseenter",this.handleHeaderMouseHoverOn.bind(this)),this._bindingEventService.bind(r,"mouseleave",this.handleHeaderMouseHoverOff.bind(this))),t.hasOwnProperty("headerCellAttrs")&&t.headerCellAttrs instanceof Object&&Object.keys(t.headerCellAttrs).forEach(l=>{t.headerCellAttrs.hasOwnProperty(l)&&r.setAttribute(l,t.headerCellAttrs[l])}),t.sortable&&(r.classList.add("slick-header-sortable"),L.createDomElement("div",{className:`slick-sort-indicator ${this._options.numberedMultiColumnSort&&!this._options.sortColNumberInSeparateSpan?" slick-sort-indicator-numbered":""}`},r),this._options.numberedMultiColumnSort&&this._options.sortColNumberInSeparateSpan&&L.createDomElement("div",{className:"slick-sort-indicator-numbered"},r)),this.trigger(this.onHeaderCellRendered,{node:r,column:t,grid:this}),this._options.showHeaderRow){let l=L.createDomElement("div",{className:`ui-state-default slick-state-default slick-headerrow-column l${e} r${e}`},o),d=this.hasFrozenColumns()&&e<=this._options.frozenColumn?"frozen":null;d&&l.classList.add(d),this._bindingEventService.bind(l,"mouseenter",this.handleHeaderRowMouseEnter.bind(this)),this._bindingEventService.bind(l,"mouseleave",this.handleHeaderRowMouseLeave.bind(this)),L.storage.put(l,"column",t),this.trigger(this.onHeaderRowCellRendered,{node:l,column:t,grid:this})}if(this._options.createFooterRow&&this._options.showFooterRow){let l=this.hasFrozenColumns()?e<=this._options.frozenColumn?this._footerRow[0]:this._footerRow[1]:this._footerRow[0],d=L.createDomElement("div",{className:`ui-state-default slick-state-default slick-footerrow-column l${e} r${e}`},l);L.storage.put(d,"column",t),this.trigger(this.onFooterRowCellRendered,{node:d,column:t,grid:this})}}this.setSortColumns(this.sortColumns),this.setupColumnResize(),this._options.enableColumnReorder&&(typeof this._options.enableColumnReorder=="function"?this._options.enableColumnReorder(this,this._headers,this.headerColumnWidthDiff,this.setColumns,this.setupColumnResize,this.columns,this.getColumnIndex,this.uid,this.trigger):this.setupColumnReorder())}setupColumnReorder(){this.sortableSideLeftInstance?.destroy(),this.sortableSideRightInstance?.destroy();let e=null,t=()=>this._viewportScrollContainerX.scrollLeft=this._viewportScrollContainerX.scrollLeft+10,n=()=>this._viewportScrollContainerX.scrollLeft=this._viewportScrollContainerX.scrollLeft-10,o=!1,r={animation:50,direction:"horizontal",chosenClass:"slick-header-column-active",ghostClass:"slick-sortable-placeholder",draggable:".slick-header-column",dragoverBubble:!1,revertClone:!0,scroll:!this.hasFrozenColumns(),filter:`.${this._options.unorderableColumnCssClass}`,onMove:i=>!i.related.classList.contains(this._options.unorderableColumnCssClass),onStart:i=>{i.item.classList.add("slick-header-column-active"),o=!this.hasFrozenColumns()||L.offset(i.item).left>L.offset(this._viewportScrollContainerX).left,o&&i.originalEvent.pageX>this._container.clientWidth?e||(e=window.setInterval(t,100)):o&&i.originalEvent.pageX<L.offset(this._viewportScrollContainerX).left?e||(e=window.setInterval(n,100)):(window.clearInterval(e),e=null)},onEnd:i=>{if(i.item.classList.remove("slick-header-column-active"),window.clearInterval(e),e=null,!this.getEditorLock()?.commitCurrentEdit())return;let a=this.sortableSideLeftInstance?.toArray()??[];a=a.concat(this.sortableSideRightInstance?.toArray()??[]);let l=[];for(let d=0;d<a.length;d++)l.push(this.columns[this.getColumnIndex(a[d])]);this.setColumns(l),this.trigger(this.onColumnsReordered,{impactedColumns:this.columns}),i.stopPropagation(),this.setupColumnResize(),this.activeCellNode&&this.setFocus()}};this.sortableSideLeftInstance=Sortable.create(this._headerL,r),this.sortableSideRightInstance=Sortable.create(this._headerR,r)}getHeaderChildren(){let e=Array.from(this._headers[0].children),t=Array.from(this._headers[1].children);return e.concat(t)}handleResizeableDoubleClick(e){let t=e.target.parentElement.id.replace(this.uid,"");this.trigger(this.onColumnsResizeDblClick,{triggeredByColumn:t})}setupColumnResize(){if(typeof lm>"u")throw new Error('Slick.Resizable is undefined, make sure to import "slick.interactions.js"');let e,t,n,o,r,i,a,l=-1,d=0,u=this.getHeaderChildren(),f=this.getVisibleColumns();for(let p=0;p<u.length;p++)u[p].querySelectorAll(".slick-resizable-handle").forEach(y=>y.remove()),!(p>=f.length||!f[p])&&f[p].resizable&&(a===void 0&&(a=p),l=p);if(a!==void 0)for(let p=0;p<u.length;p++){let y=u[p];if(p>=f.length||!f[p]||p<a||this._options.forceFitColumns&&p>=l)continue;let b=L.createDomElement("div",{className:"slick-resizable-handle",role:"separator",ariaOrientation:"horizontal"},y);this._bindingEventService.bind(b,"dblclick",this.handleResizeableDoubleClick.bind(this)),this.slickResizableInstances.push(lm({resizeableElement:y,resizeableHandleElement:b,onResizeStart:(w,g)=>{let v=w.touches?w.changedTouches[0]:w;if(!this.getEditorLock()?.commitCurrentEdit())return!1;o=v.pageX,d=0,g.resizeableElement.classList.add("slick-header-column-active");let E=null,P=null;for(let C=0;C<u.length;C++)C>=f.length||!f[C]||(f[C].previousWidth=u[C].offsetWidth);if(this._options.forceFitColumns)for(E=0,P=0,e=p+1;e<f.length;e++)n=f[e],n?.resizable&&(P!==null&&(n.maxWidth?P+=n.maxWidth-(n.previousWidth||0):P=null),E+=(n.previousWidth||0)-Math.max(n.minWidth||0,this.absoluteColumnMinWidth));let x=0,S=0;for(e=0;e<=p;e++)n=f[e],n?.resizable&&(S!==null&&(n.maxWidth?S+=n.maxWidth-(n.previousWidth||0):S=null),x+=(n.previousWidth||0)-Math.max(n.minWidth||0,this.absoluteColumnMinWidth));E===null&&(E=1e5),x===null&&(x=1e5),P===null&&(P=1e5),S===null&&(S=1e5),i=o+Math.min(E,S),r=o-Math.min(x,P)},onResize:(w,g)=>{let v=w.touches?w.changedTouches[0]:w;this.columnResizeDragging=!0;let E,P=Math.min(i,Math.max(r,v.pageX))-o,x,S=0,C=0,O=this.getViewportInnerWidth();if(P<0){for(x=P,e=p;e>=0;e--)n=f[e],n?.resizable&&!n.hidden&&(E=Math.max(n.minWidth||0,this.absoluteColumnMinWidth),x&&(n.previousWidth||0)+x<E?(x+=(n.previousWidth||0)-E,n.width=E):(n.width=(n.previousWidth||0)+x,x=0));for(t=0;t<=p;t++)n=f[t],!(!n||n.hidden)&&(this.hasFrozenColumns()&&t>this._options.frozenColumn?C+=n.width||0:S+=n.width||0);if(this._options.forceFitColumns)for(x=-P,e=p+1;e<f.length;e++)n=f[e],!(!n||n.hidden)&&n.resizable&&(x&&n.maxWidth&&n.maxWidth-(n.previousWidth||0)<x?(x-=n.maxWidth-(n.previousWidth||0),n.width=n.maxWidth):(n.width=(n.previousWidth||0)+x,x=0),this.hasFrozenColumns()&&e>this._options.frozenColumn?C+=n.width||0:S+=n.width||0);else for(e=p+1;e<f.length;e++)n=f[e],!(!n||n.hidden)&&(this.hasFrozenColumns()&&e>this._options.frozenColumn?C+=n.width||0:S+=n.width||0);if(this._options.forceFitColumns)for(x=-P,e=p+1;e<f.length;e++)n=f[e],!(!n||n.hidden)&&n.resizable&&(x&&n.maxWidth&&n.maxWidth-(n.previousWidth||0)<x?(x-=n.maxWidth-(n.previousWidth||0),n.width=n.maxWidth):(n.width=(n.previousWidth||0)+x,x=0))}else{for(x=P,S=0,C=0,e=p;e>=0;e--)if(n=f[e],!(!n||n.hidden)&&n.resizable)if(x&&n.maxWidth&&n.maxWidth-(n.previousWidth||0)<x)x-=n.maxWidth-(n.previousWidth||0),n.width=n.maxWidth;else{let N=(n.previousWidth||0)+x,F=this.canvasWidthL+x;this.hasFrozenColumns()&&e<=this._options.frozenColumn?(N>d&&F<O-this._options.frozenRightViewportMinWidth&&(d=N),n.width=F+this._options.frozenRightViewportMinWidth>O?d:N):n.width=N,x=0}for(t=0;t<=p;t++)n=f[t],!(!n||n.hidden)&&(this.hasFrozenColumns()&&t>this._options.frozenColumn?C+=n.width||0:S+=n.width||0);if(this._options.forceFitColumns)for(x=-P,e=p+1;e<f.length;e++)n=f[e],!(!n||n.hidden)&&n.resizable&&(E=Math.max(n.minWidth||0,this.absoluteColumnMinWidth),x&&(n.previousWidth||0)+x<E?(x+=(n.previousWidth||0)-E,n.width=E):(n.width=(n.previousWidth||0)+x,x=0),this.hasFrozenColumns()&&e>this._options.frozenColumn?C+=n.width||0:S+=n.width||0);else for(e=p+1;e<f.length;e++)n=f[e],!(!n||n.hidden)&&(this.hasFrozenColumns()&&e>this._options.frozenColumn?C+=n.width||0:S+=n.width||0)}this.hasFrozenColumns()&&S!==this.canvasWidthL&&(L.width(this._headerL,S+1e3),L.setStyleSize(this._paneHeaderR,"left",S)),this.applyColumnHeaderWidths(),this._options.syncColumnCellResize&&this.applyColumnWidths(),this.trigger(this.onColumnsDrag,{triggeredByColumn:g.resizeableElement,resizeHandle:g.resizeableHandleElement})},onResizeEnd:(w,g)=>{g.resizeableElement.classList.remove("slick-header-column-active");let v=g.resizeableElement.id.replace(this.uid,"");this.trigger(this.onBeforeColumnsResize,{triggeredByColumn:v}).getReturnValue()===!0&&this.applyColumnHeaderWidths();let E;for(e=0;e<f.length;e++)n=f[e],!(!n||n.hidden)&&(E=u[e].offsetWidth,n.previousWidth!==E&&n.rerenderOnResize&&this.invalidateAllRows());this.updateCanvasWidth(!0),this.render(),this.trigger(this.onColumnsResized,{triggeredByColumn:v}),window.clearTimeout(this._columnResizeTimer),this._columnResizeTimer=window.setTimeout(()=>{this.columnResizeDragging=!1},300)}}))}}setFrozenOptions(){if(this._options.frozenColumn=this._options.frozenColumn>=0&&this._options.frozenColumn<this.columns.length?parseInt(this._options.frozenColumn,10):-1,this._options.frozenRow>-1){this.hasFrozenRows=!0,this.frozenRowsHeight=this._options.frozenRow*this._options.rowHeight;let e=this.getDataLength();this.actualFrozenRow=this._options.frozenBottom?e-this._options.frozenRow:this._options.frozenRow}else this.hasFrozenRows=!1}autosizeColumn(e,t){let n=null,o=-1;if(typeof e=="number")n=this.columns[e],o=e;else if(typeof e=="string")for(let i=0;i<this.columns.length;i++)this.columns[i].id===e&&(n=this.columns[i],o=i);if(!n)return;let r=this.getCanvasNode(0,0);this.getColAutosizeWidth(n,o,r,t||!1,o)}treatAsLocked(e={}){return!e.ignoreHeaderText&&!e.sizeToRemaining&&e.contentSizePx===e.headerWidthPx&&(e.widthPx??0)<100}autosizeColumns(e,t){let n=!this._hiddenParents?.length;n&&this.cacheCssForHiddenInit(),this.internalAutosizeColumns(e,t),n&&this.restoreCssFromHiddenInit()}internalAutosizeColumns(e,t){if(e=e||this._options.autosizeColsMode,e===_n.LegacyForceFit||e===_n.LegacyOff){this.legacyAutosizeColumns();return}if(e===_n.None)return;this.canvas=document.createElement("canvas"),this.canvas?.getContext&&(this.canvas_context=this.canvas.getContext("2d"));let n=this.getCanvasNode(0,0),o=this.getViewportInnerWidth(),r,i,a,l=!1,d=0,u=0,f=0,p=0,y=0;for(r=0;r<this.columns.length;r++)i=this.columns[r],this.getColAutosizeWidth(i,r,n,t||!1,r),y+=i.autoSize?.autosizeMode===cr.Locked?i.width||0:this.treatAsLocked(i.autoSize)&&i.autoSize?.widthPx||0,p+=i.autoSize?.autosizeMode===cr.Locked?i.width||0:this.treatAsLocked(i.autoSize)?i.autoSize?.widthPx||0:i.minWidth||0,d+=i.autoSize?.widthPx||0,u+=i.autoSize?.sizeToRemaining?0:i.autoSize?.widthPx||0,f+=i.autoSize?.sizeToRemaining&&i.minWidth||0;let b=d-u;if(e===_n.FitViewportToCols){let w=d+(this.scrollbarDimensions?.width??0);e=_n.IgnoreViewport,this._options.viewportMaxWidthPx&&w>this._options.viewportMaxWidthPx?(w=this._options.viewportMaxWidthPx,e=_n.FitColsToViewport):this._options.viewportMinWidthPx&&w<this._options.viewportMinWidthPx&&(w=this._options.viewportMinWidthPx,e=_n.FitColsToViewport),L.width(this._container,w)}if(e===_n.FitColsToViewport)if(b>0&&u<o-f)for(r=0;r<this.columns.length;r++){if(i=this.columns[r],!i||i.hidden)continue;let w=o-u;i.autoSize?.sizeToRemaining?a=w*(i.autoSize?.widthPx||0)/b:a=i.autoSize?.widthPx||0,i.rerenderOnResize&&(i.width||0)!==a&&(l=!0),i.width=a}else if(this._options.viewportSwitchToScrollModeWidthPercent&&u+f>o*this._options.viewportSwitchToScrollModeWidthPercent/100||p>o)e=_n.IgnoreViewport;else{let w=u-y,g=o-y-f;for(r=0;r<this.columns.length;r++)i=this.columns[r],!(!i||i.hidden)&&(a=i.width||0,i.autoSize?.autosizeMode!==cr.Locked&&!this.treatAsLocked(i.autoSize)&&(i.autoSize?.sizeToRemaining?a=i.minWidth||0:(a=g/w*(i.autoSize?.widthPx||0)-1,a<(i.minWidth||0)&&(a=i.minWidth||0),w-=i.autoSize?.widthPx||0,g-=a)),this.treatAsLocked(i.autoSize)&&(a=i.autoSize?.widthPx||0,a<(i.minWidth||0)&&(a=i.minWidth||0)),i.rerenderOnResize&&i.width!==a&&(l=!0),i.width=a)}if(e===_n.IgnoreViewport)for(r=0;r<this.columns.length;r++)!this.columns[r]||this.columns[r].hidden||(a=this.columns[r].autoSize?.widthPx||0,this.columns[r].rerenderOnResize&&this.columns[r].width!==a&&(l=!0),this.columns[r].width=a);this.reRenderColumns(l)}getColAutosizeWidth(e,t,n,o,r){let i=e.autoSize;if(i.widthPx=e.width,i.autosizeMode===cr.Locked||i.autosizeMode===cr.Guide)return;let a=this.getDataLength(),l=new RegExp(/\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d{3})?Z/);if(i.autosizeMode===cr.ContentIntelligent){let f=i.colDataTypeOf,p;if(a>0){let y=this.getDataItem(0);y&&(p=y[e.field],l.test(p)&&(p=Date.parse(p)),f=typeof p,f==="object"&&(p instanceof Date&&(f="date"),typeof moment<"u"&&p instanceof moment&&(f="moment")))}f==="boolean"&&(i.colValueArray=[!0,!1]),f==="number"&&(i.valueFilterMode=Rr.GetGreatestAndSub,i.rowSelectionMode=cs.AllRows),f==="string"&&(i.valueFilterMode=Rr.GetLongestText,i.rowSelectionMode=cs.AllRows,i.allowAddlPercent=5),f==="date"&&(i.colValueArray=[new Date(2009,8,30,12,20,20)]),f==="moment"&&typeof moment<"u"&&(i.colValueArray=[moment([2009,8,30,12,20,20])])}let d=i.contentSizePx=this.getColContentSize(e,t,n,o,r);d===0&&(d=i.widthPx||0);let u=i.allowAddlPercent?1+i.allowAddlPercent/100:1;d=d*u+(this._options.autosizeColPaddingPx||0),e.minWidth&&d<e.minWidth&&(d=e.minWidth),e.maxWidth&&d>e.maxWidth&&(d=e.maxWidth),(i.autosizeMode===cr.ContentExpandOnly||e?.editor?.ControlFillsColumn)&&d<(e.width||0)&&(d=e.width||0),i.widthPx=d}getColContentSize(e,t,n,o,r){let i=e.autoSize,a=1,l,d,u=0,f=0;if(i.headerWidthPx=0,i.ignoreHeaderText||(i.headerWidthPx=this.getColHeaderWidth(e)),i.headerWidthPx===0&&(i.headerWidthPx=e.width?e.width:e.maxWidth?e.maxWidth:e.minWidth?e.minWidth:20),i.colValueArray)return f=this.getColWidth(e,n,i.colValueArray),Math.max(i.headerWidthPx,f);let p={};p.colIndex=t,p.rowCount=this.getDataLength(),p.startIndex=0,p.endIndex=p.rowCount-1,p.valueArr=null,p.getRowVal=b=>this.getDataItem(b)[e.field];let y=(o?i.rowSelectionModeOnInit:void 0)||i.rowSelectionMode;if(y===cs.FirstRow&&(p.endIndex=0),y===cs.LastRow&&(p.endIndex=p.startIndex=p.rowCount-1),y===cs.FirstNRows&&(p.endIndex=Math.min(i.rowSelectionCount||0,p.rowCount)-1),i.valueFilterMode===Rr.DeDuplicate){let b={};for(l=p.startIndex;l<=p.endIndex;l++)b[p.getRowVal(l)]=!0;if(Object.keys)p.valueArr=Object.keys(b);else{p.valueArr=[];for(let w in b)b&&p.valueArr.push(w)}p.startIndex=0,p.endIndex=p.length-1}if(i.valueFilterMode===Rr.GetGreatestAndSub){let b,w=0;for(l=p.startIndex;l<=p.endIndex;l++)d=p.getRowVal(l),Math.abs(d)>w&&(b=d,w=Math.abs(d));b=""+b,b=Array(b.length+1).join("9"),b=+b,p.valueArr=[b],p.startIndex=p.endIndex=0}if(i.valueFilterMode===Rr.GetLongestTextAndSub){for(l=p.startIndex;l<=p.endIndex;l++)d=p.getRowVal(l),(d||"").length>u&&(u=d.length);d=Array(u+1).join("m"),a=this._options.autosizeTextAvgToMWidthRatio||0,p.maxLen=u,p.valueArr=[d],p.startIndex=p.endIndex=0}if(i.valueFilterMode===Rr.GetLongestText){u=0;let b=0;for(l=p.startIndex;l<=p.endIndex;l++)d=p.getRowVal(l),(d||"").length>u&&(u=d.length,b=l);d=p.getRowVal(b),p.maxLen=u,p.valueArr=[d],p.startIndex=p.endIndex=0}return p.maxLen&&p.maxLen>30&&r>1&&(i.sizeToRemaining=!0),f=this.getColWidth(e,n,p)*a,Math.max(i.headerWidthPx,f)}getColWidth(e,t,n){let o=L.createDomElement("div",{className:"slick-row ui-widget-content"},t),r=L.createDomElement("div",{className:"slick-cell"},o);r.style.position="absolute",r.style.visibility="hidden",r.style.textOverflow="initial",r.style.whiteSpace="nowrap";let i,a,l=0,d="",u,f,p=e.autoSize.widthEvalMode===Cd.TextOnly;if(e.autoSize?.widthEvalMode===Cd.Auto){let y=!e.formatterOverride&&!e.formatter,b=e?.formatterOverride?.ReturnsTextOnly||!e.formatterOverride&&e.formatter?.ReturnsTextOnly;p=y||b}if(this.canvas_context&&p){let y=getComputedStyle(r);for(this.canvas_context.font=y.fontSize+" "+y.fontFamily,i=n.startIndex;i<=n.endIndex;i++)f=n.valueArr?n.valueArr[i]:n.getRowVal(i),e.formatterOverride?u=e.formatterOverride(i,n.colIndex,f,e,this.getDataItem(i),this):e.formatter?u=e.formatter(i,n.colIndex,f,e,this.getDataItem(i),this):u=""+f,a=u?this.canvas_context.measureText(u).width:0,a>l&&(l=a,d=u);return r.textContent=d,a=r.offsetWidth,o.remove(),a}for(i=n.startIndex;i<=n.endIndex;i++)f=n.valueArr?n.valueArr[i]:n.getRowVal(i),e.formatterOverride?u=e.formatterOverride(i,n.colIndex,f,e,this.getDataItem(i),this):e.formatter?u=e.formatter(i,n.colIndex,f,e,this.getDataItem(i),this):u=""+f,this.applyFormatResultToCellNode(u,r),a=r.offsetWidth,a>l&&(l=a);return o.remove(),l}getColHeaderWidth(e){let t=0,n=this.getUID()+e.id,o=document.getElementById(n),r=`${n}_`,i=o.cloneNode(!0);if(o)i.id=r,i.style.cssText="position: absolute; visibility: hidden;right: auto;text-overflow: initial;white-space: nowrap;",o.parentNode.insertBefore(i,o),t=i.offsetWidth,i.parentNode.removeChild(i);else{let a=this.getHeader(e);o=L.createDomElement("div",{id:r,className:"ui-state-default slick-state-default slick-header-column"},a);let l=L.createDomElement("span",{className:"slick-column-name"},o);this.applyHtmlCode(l,e.name),i.style.cssText="position: absolute; visibility: hidden;right: auto;text-overflow: initial;white-space: nowrap;",e.headerCssClass&&o.classList.add(...L.classNameToList(e.headerCssClass)),t=o.offsetWidth,a.removeChild(o)}return t}legacyAutosizeColumns(){let e,t,n=0,o=0,r=0,i=[],a=this.getViewportInnerWidth();for(e=0;e<this.columns.length;e++){if(t=this.columns[e],!t||t.hidden){i.push(0);continue}i.push(t.width||0),o+=t.width||0,t.resizable&&(n+=(t.width||0)-Math.max(t.minWidth||0,this.absoluteColumnMinWidth))}for(r=o;o>a&&n;){let d=(o-a)/n;for(e=0;e<this.columns.length&&o>a;e++){if(t=this.columns[e],!t||t.hidden)continue;let u=i[e];if(!t.resizable||u<=t.minWidth||u<=this.absoluteColumnMinWidth)continue;let f=Math.max(t.minWidth,this.absoluteColumnMinWidth),p=Math.floor(d*(u-f))||1;p=Math.min(p,u-f),o-=p,n-=p,i[e]-=p}if(r<=o)break;r=o}for(r=o;o<a;){let d=a/o;for(e=0;e<this.columns.length&&o<a;e++){if(t=this.columns[e],!t||t.hidden)continue;let u=i[e],f;!t.resizable||t.maxWidth<=u?f=0:f=Math.min(Math.floor(d*u)-u,t.maxWidth-u||1e6)||1,o+=f,i[e]+=o<=a?f:0}if(r>=o)break;r=o}let l=!1;for(e=0;e<this.columns.length;e++)!t||t.hidden||(this.columns[e].rerenderOnResize&&this.columns[e].width!==i[e]&&(l=!0),this.columns[e].width=i[e]);this.reRenderColumns(l)}reRenderColumns(e){this.applyColumnHeaderWidths(),this.updateCanvasWidth(!0),this.trigger(this.onAutosizeColumns,{columns:this.columns}),e&&(this.invalidateAllRows(),this.render())}getVisibleColumns(){return this.columns.filter(e=>!e.hidden)}getColumnIndex(e){return this.columnsById[e]}applyColumnHeaderWidths(){if(!this.initialized)return;let e=0,t=this.getVisibleColumns();this._headers.forEach(n=>{for(let o=0;o<n.children.length;o++,e++){let r=n.children[o],i=((t[e]||{}).width||0)-this.headerColumnWidthDiff;L.width(r)!==i&&L.width(r,i)}}),this.updateColumnCaches()}applyColumnWidths(){let e=0,t=0,n;for(let o=0;o<this.columns.length;o++)this.columns[o]?.hidden||(t=this.columns[o].width||0,n=this.getColumnCssRules(o),n.left.style.left=`${e}px`,n.right.style.right=(this._options.frozenColumn!==-1&&o>this._options.frozenColumn?this.canvasWidthR:this.canvasWidthL)-e-t+"px",this._options.frozenColumn!==o&&(e+=this.columns[o].width)),this._options.frozenColumn===o&&(e=0)}setSortColumn(e,t){this.setSortColumns([{columnId:e,sortAsc:t}])}getColumnByIndex(e){let t;return this._headers.every(n=>{let o=n.children.length;return e<o?(t=n.children[e],!1):(e-=o,!0)}),t}setSortColumns(e){this.sortColumns=e;let t=this._options.numberedMultiColumnSort&&this.sortColumns.length>1;this._headers.forEach(o=>{let r=o.querySelectorAll(".slick-header-column-sorted");r.forEach(i=>{i.classList.remove("slick-header-column-sorted")}),r=o.querySelectorAll(".slick-sort-indicator"),r.forEach(i=>{i.classList.remove("slick-sort-indicator-asc"),i.classList.remove("slick-sort-indicator-desc")}),r=o.querySelectorAll(".slick-sort-indicator-numbered"),r.forEach(i=>{i.textContent=""})});let n=1;this.sortColumns.forEach(o=>{L.isDefined(o.sortAsc)||(o.sortAsc=!0);let r=this.getColumnIndex(o.columnId);if(L.isDefined(r)){let i=this.getColumnByIndex(r);if(i){i.classList.add("slick-header-column-sorted");let a=i.querySelector(".slick-sort-indicator");a?.classList.add(o.sortAsc?"slick-sort-indicator-asc":"slick-sort-indicator-desc"),t&&(a=i.querySelector(".slick-sort-indicator-numbered"),a&&(a.textContent=String(n)))}}n++})}getColumns(){return this.columns}getSortColumns(){return this.sortColumns}updateColumnCaches(){this.columnPosLeft=[],this.columnPosRight=[];let e=0;for(let t=0,n=this.columns.length;t<n;t++)!this.columns[t]||this.columns[t].hidden||(this.columnPosLeft[t]=e,this.columnPosRight[t]=e+(this.columns[t].width||0),this._options.frozenColumn===t?e=0:e+=this.columns[t].width||0)}updateColumnProps(){this.columnsById={};for(let e=0;e<this.columns.length;e++){let t=this.columns[e];t.width&&(t.widthRequest=t.width),this._options.mixinDefaults?(L.applyDefaults(t,this._columnDefaults),t.autoSize||(t.autoSize={}),L.applyDefaults(t.autoSize,this._columnAutosizeDefaults)):(t=this.columns[e]=L.extend({},this._columnDefaults,t),t.autoSize=L.extend({},this._columnAutosizeDefaults,t.autoSize)),this.columnsById[t.id]=e,t.minWidth&&(t.width||0)<t.minWidth&&(t.width=t.minWidth),t.maxWidth&&(t.width||0)>t.maxWidth&&(t.width=t.maxWidth)}}setColumns(e){this.trigger(this.onBeforeSetColumns,{previousColumns:this.columns,newColumns:e,grid:this}),this.columns=e,this.updateColumnsInternal(),this.trigger(this.onAfterSetColumns,{newColumns:e,grid:this})}updateColumns(){this.trigger(this.onBeforeUpdateColumns,{columns:this.columns,grid:this}),this.updateColumnsInternal()}updateColumnsInternal(){this.updateColumnProps(),this.updateColumnCaches(),this.initialized&&(this.setPaneFrozenClasses(),this.setPaneVisibility(),this.setOverflow(),this.invalidateAllRows(),this.createColumnHeaders(),this.createColumnFooter(),this.removeCssRules(),this.createCssRules(),this.resizeCanvas(),this.updateCanvasWidth(),this.applyColumnHeaderWidths(),this.applyColumnWidths(),this.handleScroll(),this.getSelectionModel()?.refreshSelections())}getEditorLock(){return this._options.editorLock}getEditController(){return this.editController}setData(e,t){this.data=e,this.invalidateAllRows(),this.updateRowCount(),t&&this.scrollTo(0)}getData(){return this.data}getDataLength(){return this.data.getLength?this.data.getLength():this.data?.length??0}getDataLengthIncludingAddNew(){return this.getDataLength()+(this._options.enableAddRow&&(!this.pagingActive||this.pagingIsLastPage)?1:0)}getDataItem(e){return this.data.getItem?this.data.getItem(e):this.data[e]}hasDataView(){return!Array.isArray(this.data)}getItemMetadaWhenExists(e){return"getItemMetadata"in this.data?this.data.getItemMetadata(e):null}getFormatter(e,t){let n=this.data?.getItemMetadata?.(e);return(n?.columns&&(n.columns[t.id]||n.columns[this.getColumnIndex(t.id)]))?.formatter||n?.formatter||t.formatter||this._options.formatterFactory?.getFormatter(t)||this._options.defaultFormatter}getEditor(e,t){let n=this.columns[t],o=this.getItemMetadaWhenExists(e)?.columns;return o?.[n.id]?.editor!==void 0?o[n.id].editor:o?.[t]?.editor!==void 0?o[t].editor:n.editor||this._options?.editorFactory?.getEditor(n)}getDataItemValueForColumn(e,t){return this._options.dataItemColumnValueExtractor?this._options.dataItemColumnValueExtractor(e,t):e[t.field]}resetActiveCell(){this.setActiveCellInternal(null,!1)}unsetActiveCell(){L.isDefined(this.activeCellNode)&&(this.makeActiveCellNormal(),this.activeCellNode.classList.remove("active"),this.rowsCache[this.activeRow]?.rowNode?.forEach(e=>e.classList.remove("active")))}focus(){this.setFocus()}setFocus(){this.tabbingDirection===-1?this._focusSink.focus():this._focusSink2.focus()}setActiveCellInternal(e,t,n,o,r){if(this.unsetActiveCell(),this.activeCellNode=e,L.isDefined(this.activeCellNode)){let i=L.offset(this.activeCellNode),a=Math.floor(L.offset(L.parents(this.activeCellNode,".grid-canvas")[0]).top),l=L.parents(this.activeCellNode,".grid-canvas-bottom").length;this.hasFrozenRows&&l&&(a-=this._options.frozenBottom?L.height(this._canvasTopL):this.frozenRowsHeight);let d=this.getCellFromPoint(i.left,Math.ceil(i.top)-a);this.activeRow=d.row,this.activePosY=d.row,this.activeCell=this.activePosX=this.getCellFromNode(this.activeCellNode),!L.isDefined(t)&&this._options.autoEditNewRow&&(t=this.activeRow===this.getDataLength()||this._options.autoEdit),this._options.showCellSelection&&(document.querySelectorAll(".slick-cell.active").forEach(u=>u.classList.remove("active")),this.activeCellNode.classList.add("active"),this.rowsCache[this.activeRow]?.rowNode?.forEach(u=>u.classList.add("active"))),this._options.editable&&t&&this.isCellPotentiallyEditable(this.activeRow,this.activeCell)&&(this._options.asyncEditorLoading?(window.clearTimeout(this.h_editorLoader),this.h_editorLoader=window.setTimeout(()=>{this.makeActiveCellEditable(void 0,n,r)},this._options.asyncEditorLoadDelay)):this.makeActiveCellEditable(void 0,n,r))}else this.activeRow=this.activeCell=null;o||this.trigger(this.onActiveCellChanged,this.getActiveCell())}isCellPotentiallyEditable(e,t){let n=this.getDataLength();return!(e<n&&!this.getDataItem(e)||this.columns[t].cannotTriggerInsert&&e>=n||!this.columns[t]||this.columns[t].hidden||!this.getEditor(e,t))}makeActiveCellNormal(e=!1){if(this.currentEditor){if(this.trigger(this.onBeforeCellEditorDestroy,{editor:this.currentEditor}),this.currentEditor.destroy(),this.currentEditor=null,this.activeCellNode){let t=this.getDataItem(this.activeRow);if(this.activeCellNode.classList.remove("editable"),this.activeCellNode.classList.remove("invalid"),t){let n=this.columns[this.activeCell],o=this.getFormatter(this.activeRow,n)(this.activeRow,this.activeCell,this.getDataItemValueForColumn(t,n),n,t,this);this.applyFormatResultToCellNode(o,this.activeCellNode),this.invalidatePostProcessingResults(this.activeRow)}e&&this.setFocus()}navigator.userAgent.toLowerCase().match(/msie/)&&this.clearTextSelection(),this.getEditorLock()?.deactivate(this.editController)}}editActiveCell(e,t,n){this.makeActiveCellEditable(e,t,n)}makeActiveCellEditable(e,t,n){if(!this.activeCellNode)return;if(!this._options.editable)throw new Error("SlickGrid makeActiveCellEditable : should never get called when this._options.editable is false");if(window.clearTimeout(this.h_editorLoader),!this.isCellPotentiallyEditable(this.activeRow,this.activeCell))return;let o=this.columns[this.activeCell],r=this.getDataItem(this.activeRow);if(this.trigger(this.onBeforeEditCell,{row:this.activeRow,cell:this.activeCell,item:r,column:o,target:"grid"}).getReturnValue()===!1){this.setFocus();return}this.getEditorLock()?.activate(this.editController),this.activeCellNode.classList.add("editable");let i=e||this.getEditor(this.activeRow,this.activeCell);if(!i||typeof i!="function")return;!e&&!i.suppressClearOnEdit&&L.emptyElement(this.activeCellNode);let a=this.getItemMetadaWhenExists(this.activeRow);a=a?.columns;let l=a&&(a[o.id]||a[this.activeCell]),d={grid:this,gridPosition:this.absBox(this._container),position:this.absBox(this.activeCellNode),container:this.activeCellNode,column:o,columnMetaData:l,item:r||{},event:n,commitChanges:this.commitEditAndSetFocus.bind(this),cancelChanges:this.cancelEditAndSetFocus.bind(this)};this.currentEditor=new i(d),r&&this.currentEditor&&(this.currentEditor.loadValue(r),t&&this.currentEditor?.preClick&&this.currentEditor.preClick()),this.serializedEditorValue=this.currentEditor?.serializeValue(),this.currentEditor?.position&&this.handleActiveCellPositionChange()}commitEditAndSetFocus(){this.getEditorLock()?.commitCurrentEdit()&&(this.setFocus(),this._options.autoEdit&&!this._options.autoCommitEdit&&this.navigateDown())}cancelEditAndSetFocus(){this.getEditorLock()?.cancelCurrentEdit()&&this.setFocus()}commitCurrentEdit(){let e=this,t=e.getDataItem(e.activeRow),n=e.columns[e.activeCell];if(e.currentEditor){if(e.currentEditor.isValueChanged()){let o=e.currentEditor.validate();if(o.valid){let r=e.activeRow,i=e.activeCell,a=e.currentEditor,l=e.currentEditor.serializeValue(),d=e.serializedEditorValue;if(e.activeRow<e.getDataLength()){let u={row:r,cell:i,editor:a,serializedValue:l,prevSerializedValue:d,execute:()=>{a.applyValue(t,l),e.updateRow(r),e.trigger(e.onCellChange,{command:"execute",row:r,cell:i,item:t,column:n})},undo:()=>{a.applyValue(t,d),e.updateRow(r),e.trigger(e.onCellChange,{command:"undo",row:r,cell:i,item:t,column:n})}};e._options.editCommandHandler?(e.makeActiveCellNormal(!0),e._options.editCommandHandler(t,n,u)):(u.execute(),e.makeActiveCellNormal(!0))}else{let u={};e.currentEditor.applyValue(u,e.currentEditor.serializeValue()),e.makeActiveCellNormal(!0),e.trigger(e.onAddNewRow,{item:u,column:n})}return!e.getEditorLock()?.isActive()}else return e.activeCellNode&&(e.activeCellNode.classList.remove("invalid"),L.width(e.activeCellNode),e.activeCellNode.classList.add("invalid")),e.trigger(e.onValidationError,{editor:e.currentEditor,cellNode:e.activeCellNode,validationResults:o,row:e.activeRow,cell:e.activeCell,column:n}),e.currentEditor.focus(),!1}e.makeActiveCellNormal(!0)}return!0}cancelCurrentEdit(){return this.makeActiveCellNormal(),!0}getSelectedRows(){if(!this.selectionModel)throw new Error("SlickGrid Selection model is not set");return this.selectedRows.slice(0)}setSelectedRows(e,t){if(!this.selectionModel)throw new Error("SlickGrid Selection model is not set");this&&this.getEditorLock&&!this.getEditorLock()?.isActive()&&this.selectionModel.setSelectedRanges(this.rowsToRanges(e),t||"SlickGrid.setSelectedRows")}trigger(e,t,n){let o=n||new li(n,t),r=t||{};return r.grid=this,e.notify(r,o,this)}handleCellMouseOut(e){this.trigger(this.onMouseLeave,{},e)}handleHeaderMouseHoverOn(e){e?.target.classList.add("ui-state-hover","slick-state-hover")}handleHeaderMouseHoverOff(e){e?.target.classList.remove("ui-state-hover","slick-state-hover")}handleSelectedRangesChanged(e,t){let n=e.getNativeEvent(),o=this.selectedRows.slice(0);this.selectedRows=[];let r={};for(let i=0;i<t.length;i++)for(let a=t[i].fromRow;a<=t[i].toRow;a++){r[a]||(this.selectedRows.push(a),r[a]={});for(let l=t[i].fromCell;l<=t[i].toCell;l++)this.canCellBeSelected(a,l)&&(r[a][this.columns[l].id]=this._options.selectedCellCssClass)}if(this.setCellCssStyles(this._options.selectedCellCssClass||"",r),this.simpleArrayEquals(o,this.selectedRows)){let i=n?.detail?.caller??"click",a=new Set(this.getSelectedRows()),l=new Set(o),d=Array.from(a).filter(f=>!l.has(f)),u=Array.from(l).filter(f=>!a.has(f));this.trigger(this.onSelectedRowsChanged,{rows:this.getSelectedRows(),previousSelectedRows:o,caller:i,changedSelectedRows:d,changedUnselectedRows:u},e)}}handleMouseWheel(e,t,n,o){this.scrollHeight=this._viewportScrollContainerY.scrollHeight,e.shiftKey?this.scrollLeft=this._viewportScrollContainerX.scrollLeft+n*10:(this.scrollTop=Math.max(0,this._viewportScrollContainerY.scrollTop-o*this._options.rowHeight),this.scrollLeft=this._viewportScrollContainerX.scrollLeft+n*10),this._handleScroll("mousewheel")&&e.stopPropagation()}handleDragInit(e,t){let n=this.getCellFromEvent(e);if(!n||!this.cellExists(n.row,n.cell))return!1;let o=this.trigger(this.onDragInit,t,e);return o.isImmediatePropagationStopped()?o.getReturnValue():!1}handleDragStart(e,t){let n=this.getCellFromEvent(e);if(!n||!this.cellExists(n.row,n.cell))return!1;let o=this.trigger(this.onDragStart,t,e);return o.isImmediatePropagationStopped()?o.getReturnValue():!1}handleDrag(e,t){return this.trigger(this.onDrag,t,e).getReturnValue()}handleDragEnd(e,t){this.trigger(this.onDragEnd,t,e)}handleKeyDown(e){let t=this.trigger(this.onKeyDown,{row:this.activeRow,cell:this.activeCell},e).isImmediatePropagationStopped();if(!t&&!e.shiftKey&&!e.altKey){if(this._options.editable&&this.currentEditor?.keyCaptureList&&this.currentEditor.keyCaptureList.indexOf(e.which)>-1)return;e.ctrlKey&&e.key==="Home"?this.navigateTopStart():e.ctrlKey&&e.key==="End"?this.navigateBottomEnd():e.ctrlKey&&e.key==="ArrowUp"?this.navigateTop():e.ctrlKey&&e.key==="ArrowDown"?this.navigateBottom():e.ctrlKey&&e.key==="ArrowLeft"||!e.ctrlKey&&e.key==="Home"?this.navigateRowStart():(e.ctrlKey&&e.key==="ArrowRight"||!e.ctrlKey&&e.key==="End")&&this.navigateRowEnd()}if(!t)if(!e.shiftKey&&!e.altKey&&!e.ctrlKey){if(this._options.editable&&this.currentEditor?.keyCaptureList&&this.currentEditor.keyCaptureList.indexOf(e.which)>-1)return;if(e.which===go.ESCAPE){if(!this.getEditorLock()?.isActive())return;this.cancelEditAndSetFocus()}else e.which===go.PAGE_DOWN?(this.navigatePageDown(),t=!0):e.which===go.PAGE_UP?(this.navigatePageUp(),t=!0):e.which===go.LEFT?t=this.navigateLeft():e.which===go.RIGHT?t=this.navigateRight():e.which===go.UP?t=this.navigateUp():e.which===go.DOWN?t=this.navigateDown():e.which===go.TAB?t=this.navigateNext():e.which===go.ENTER&&(this._options.editable&&(this.currentEditor?this.activeRow===this.getDataLength()?this.navigateDown():this.commitEditAndSetFocus():this.getEditorLock()?.commitCurrentEdit()&&this.makeActiveCellEditable(void 0,void 0,e)),t=!0)}else e.which===go.TAB&&e.shiftKey&&!e.ctrlKey&&!e.altKey&&(t=this.navigatePrev());if(t){e.stopPropagation(),e.preventDefault();try{e.originalEvent.keyCode=0}catch{}}}handleClick(e){let t=e instanceof li?e.getNativeEvent():e;if(!this.currentEditor&&(t.target!==document.activeElement||t.target.classList.contains("slick-cell"))){let o=this.getTextSelection();this.setFocus(),this.setTextSelection(o)}let n=this.getCellFromEvent(t);if(!(!n||this.currentEditor!==null&&this.activeRow===n.row&&this.activeCell===n.cell)&&(e=this.trigger(this.onClick,{row:n.row,cell:n.cell},e||t),!e.isImmediatePropagationStopped()&&this.canCellBeActive(n.row,n.cell)&&(!this.getEditorLock()?.isActive()||this.getEditorLock()?.commitCurrentEdit()))){this.scrollRowIntoView(n.row,!1);let o=t.target?.className===aA,r=this.columns[n.cell],i=!!(this._options.editable&&r?.editor&&this._options.suppressActiveCellChangeOnEdit);this.setActiveCellInternal(this.getCellNode(n.row,n.cell),null,o,i,t)}}handleContextMenu(e){let t=e.target.closest(".slick-cell");t&&(this.activeCellNode===t&&this.currentEditor!==null||this.trigger(this.onContextMenu,{},e))}handleDblClick(e){let t=this.getCellFromEvent(e);!t||this.currentEditor!==null&&this.activeRow===t.row&&this.activeCell===t.cell||(this.trigger(this.onDblClick,{row:t.row,cell:t.cell},e),!e.defaultPrevented&&this._options.editable&&this.gotoCell(t.row,t.cell,!0,e))}handleHeaderMouseEnter(e){let t=L.storage.get(e.target.closest(".slick-header-column"),"column");t&&this.trigger(this.onHeaderMouseEnter,{column:t,grid:this},e)}handleHeaderMouseLeave(e){let t=L.storage.get(e.target.closest(".slick-header-column"),"column");t&&this.trigger(this.onHeaderMouseLeave,{column:t,grid:this},e)}handleHeaderRowMouseEnter(e){let t=L.storage.get(e.target.closest(".slick-headerrow-column"),"column");t&&this.trigger(this.onHeaderRowMouseEnter,{column:t,grid:this},e)}handleHeaderRowMouseLeave(e){let t=L.storage.get(e.target.closest(".slick-headerrow-column"),"column");t&&this.trigger(this.onHeaderRowMouseLeave,{column:t,grid:this},e)}handleHeaderContextMenu(e){let t=e.target.closest(".slick-header-column"),n=t&&L.storage.get(t,"column");this.trigger(this.onHeaderContextMenu,{column:n},e)}handleHeaderClick(e){if(!this.columnResizeDragging){let t=e.target.closest(".slick-header-column"),n=t&&L.storage.get(t,"column");n&&this.trigger(this.onHeaderClick,{column:n},e)}}handlePreHeaderContextMenu(e){this.trigger(this.onPreHeaderContextMenu,{node:e.target},e)}handlePreHeaderClick(e){this.columnResizeDragging||this.trigger(this.onPreHeaderClick,{node:e.target},e)}handleFooterContextMenu(e){let t=e.target.closest(".slick-footerrow-column"),n=t&&L.storage.get(t,"column");this.trigger(this.onFooterContextMenu,{column:n},e)}handleFooterClick(e){let t=e.target.closest(".slick-footerrow-column"),n=t&&L.storage.get(t,"column");this.trigger(this.onFooterClick,{column:n},e)}handleCellMouseOver(e){this.trigger(this.onMouseEnter,{},e)}handleActiveCellPositionChange(){if(this.activeCellNode&&(this.trigger(this.onActiveCellPositionChanged,{}),this.currentEditor)){let e=this.getActiveCellPosition();this.currentEditor.show&&this.currentEditor.hide&&(e.visible?this.currentEditor.show():this.currentEditor.hide()),this.currentEditor.position&&this.currentEditor.position(e)}}actionThrottle(e,t){let n=!1,o=!1,r=()=>{n?o=!0:a()},i=()=>{o=!1},a=()=>{n=!0,window.clearTimeout(this._executionBlockTimer),this._executionBlockTimer=window.setTimeout(l,t),e.call(this)},l=()=>{o?(i(),a()):n=!1};return{enqueue:r.bind(this),dequeue:i.bind(this)}}getCellFromEvent(e){let t=e instanceof li?e.getNativeEvent():e,n=t.touches?t.touches[0]:t,o=t.target.closest(".slick-cell");if(!o)return null;let r=this.getRowFromNode(o.parentNode);if(this.hasFrozenRows){let a=0,l=L.offset(L.parents(o,".grid-canvas")[0]);L.parents(o,".grid-canvas-bottom").length&&(a=this._options.frozenBottom?L.height(this._canvasTopL):this.frozenRowsHeight),r=this.getCellFromPoint(n.clientX-l.left,n.clientY-l.top+a+document.documentElement.scrollTop).row}let i=this.getCellFromNode(o);return!L.isDefined(r)||!L.isDefined(i)?null:{row:r,cell:i}}applyHtmlCode(e,t,n){if(e)if(t instanceof HTMLElement||t instanceof DocumentFragment)n?.emptyTarget!==!1&&L.emptyElement(e),e.appendChild(t);else{if(n?.skipEmptyReassignment!==!1&&!L.isDefined(t)&&!e.innerHTML)return;let o=t;typeof o=="number"||typeof o=="boolean"?e.textContent=o:(o=this.sanitizeHtmlString(t),this._options.enableHtmlRendering&&o?e.innerHTML=o:e.textContent=o)}}getCanvasNode(e,t){return this._getContainerElement(this.getCanvases(),e,t)}getActiveCanvasNode(e){return e===void 0?this._activeCanvasNode:(e instanceof li&&(e=e.getNativeEvent()),this._activeCanvasNode=e?.target.closest(".grid-canvas"),this._activeCanvasNode)}getCanvases(){return this._canvas}getViewportNode(e,t){return this._getContainerElement(this.getViewports(),e,t)}getViewports(){return this._viewport}getActiveViewportNode(e){return this.setActiveViewportNode(e),this._activeViewportNode}setActiveViewportNode(e){return e instanceof li&&(e=e.getNativeEvent()),this._activeViewportNode=e?.target.closest(".slick-viewport"),this._activeViewportNode}getHeadersWidth(){this.headersWidth=this.headersWidthL=this.headersWidthR=0;let e=!this._options.autoHeight,t=0,n=this.columns.length;for(t=0;t<n;t++){if(!this.columns[t]||this.columns[t].hidden)continue;let o=this.columns[t].width;this._options.frozenColumn>-1&&t>this._options.frozenColumn?this.headersWidthR+=o||0:this.headersWidthL+=o||0}return e&&(this._options.frozenColumn>-1&&t>this._options.frozenColumn?this.headersWidthR+=this.scrollbarDimensions?.width??0:this.headersWidthL+=this.scrollbarDimensions?.width??0),this.hasFrozenColumns()?(this.headersWidthL=this.headersWidthL+1e3,this.headersWidthR=Math.max(this.headersWidthR,this.viewportW)+this.headersWidthL,this.headersWidthR+=this.scrollbarDimensions?.width??0):(this.headersWidthL+=this.scrollbarDimensions?.width??0,this.headersWidthL=Math.max(this.headersWidthL,this.viewportW)+1e3),this.headersWidth=this.headersWidthL+this.headersWidthR,Math.max(this.headersWidth,this.viewportW)+1e3}getCanvasWidth(){let e=this.getViewportInnerWidth(),t=this.columns.length;for(this.canvasWidthL=this.canvasWidthR=0;t--;)!this.columns[t]||this.columns[t].hidden||(this.hasFrozenColumns()&&t>this._options.frozenColumn?this.canvasWidthR+=this.columns[t].width||0:this.canvasWidthL+=this.columns[t].width||0);let n=this.canvasWidthL+this.canvasWidthR;if(this._options.fullWidthRows){let o=Math.max(n,e)-n;o>0&&(n+=o,this.hasFrozenColumns()?this.canvasWidthR+=o:this.canvasWidthL+=o)}return n}updateCanvasWidth(e){let t=this.canvasWidth,n=this.canvasWidthL,o=this.canvasWidthR;this.canvasWidth=this.getCanvasWidth(),this._options.createTopHeaderPanel&&L.width(this._topHeaderPanel,this._options.topHeaderPanelWidth??this.canvasWidth);let r=this.canvasWidth!==t||this.canvasWidthL!==n||this.canvasWidthR!==o;if(r||this.hasFrozenColumns()||this.hasFrozenRows)if(L.width(this._canvasTopL,this.canvasWidthL),this.getHeadersWidth(),L.width(this._headerL,this.headersWidthL),L.width(this._headerR,this.headersWidthR),this.hasFrozenColumns()){let i=L.width(this._container)||0;if(i>0&&this.canvasWidthL>i&&this._options.throwWhenFrozenNotAllViewable)throw new Error("[SlickGrid] Frozen columns cannot be wider than the actual grid container width. Make sure to have less columns freezed or make your grid container wider");L.width(this._canvasTopR,this.canvasWidthR),L.width(this._paneHeaderL,this.canvasWidthL),L.setStyleSize(this._paneHeaderR,"left",this.canvasWidthL),L.setStyleSize(this._paneHeaderR,"width",this.viewportW-this.canvasWidthL),L.width(this._paneTopL,this.canvasWidthL),L.setStyleSize(this._paneTopR,"left",this.canvasWidthL),L.width(this._paneTopR,this.viewportW-this.canvasWidthL),L.width(this._headerRowScrollerL,this.canvasWidthL),L.width(this._headerRowScrollerR,this.viewportW-this.canvasWidthL),L.width(this._headerRowL,this.canvasWidthL),L.width(this._headerRowR,this.canvasWidthR),this._options.createFooterRow&&(L.width(this._footerRowScrollerL,this.canvasWidthL),L.width(this._footerRowScrollerR,this.viewportW-this.canvasWidthL),L.width(this._footerRowL,this.canvasWidthL),L.width(this._footerRowR,this.canvasWidthR)),this._options.createPreHeaderPanel&&L.width(this._preHeaderPanel,this._options.preHeaderPanelWidth??this.canvasWidth),L.width(this._viewportTopL,this.canvasWidthL),L.width(this._viewportTopR,this.viewportW-this.canvasWidthL),this.hasFrozenRows&&(L.width(this._paneBottomL,this.canvasWidthL),L.setStyleSize(this._paneBottomR,"left",this.canvasWidthL),L.width(this._viewportBottomL,this.canvasWidthL),L.width(this._viewportBottomR,this.viewportW-this.canvasWidthL),L.width(this._canvasBottomL,this.canvasWidthL),L.width(this._canvasBottomR,this.canvasWidthR))}else L.width(this._paneHeaderL,"100%"),L.width(this._paneTopL,"100%"),L.width(this._headerRowScrollerL,"100%"),L.width(this._headerRowL,this.canvasWidth),this._options.createFooterRow&&(L.width(this._footerRowScrollerL,"100%"),L.width(this._footerRowL,this.canvasWidth)),this._options.createPreHeaderPanel&&L.width(this._preHeaderPanel,this._options.preHeaderPanelWidth??this.canvasWidth),L.width(this._viewportTopL,"100%"),this.hasFrozenRows&&(L.width(this._viewportBottomL,"100%"),L.width(this._canvasBottomL,this.canvasWidthL));this.viewportHasHScroll=this.canvasWidth>=this.viewportW-(this.scrollbarDimensions?.width??0),L.width(this._headerRowSpacerL,this.canvasWidth+(this.viewportHasVScroll?this.scrollbarDimensions?.width??0:0)),L.width(this._headerRowSpacerR,this.canvasWidth+(this.viewportHasVScroll?this.scrollbarDimensions?.width??0:0)),this._options.createFooterRow&&(L.width(this._footerRowSpacerL,this.canvasWidth+(this.viewportHasVScroll?this.scrollbarDimensions?.width??0:0)),L.width(this._footerRowSpacerR,this.canvasWidth+(this.viewportHasVScroll?this.scrollbarDimensions?.width??0:0))),(r||e)&&this.applyColumnWidths()}getPreHeaderPanel(){return this._preHeaderPanel}getPreHeaderPanelLeft(){return this._preHeaderPanel}getPreHeaderPanelRight(){return this._preHeaderPanelR}getTopHeaderPanel(){return this._topHeaderPanel}setPaneVisibility(){this.hasFrozenColumns()?(L.show(this._paneHeaderR),L.show(this._paneTopR),this.hasFrozenRows?(L.show(this._paneBottomL),L.show(this._paneBottomR)):(L.hide(this._paneBottomR),L.hide(this._paneBottomL))):(L.hide(this._paneHeaderR),L.hide(this._paneTopR),L.hide(this._paneBottomR),this.hasFrozenRows?L.show(this._paneBottomL):(L.hide(this._paneBottomR),L.hide(this._paneBottomL)))}setOverflow(){if(this._viewportTopL.style.overflowX=this.hasFrozenColumns()?this.hasFrozenRows&&!this._options.alwaysAllowHorizontalScroll?"hidden":"scroll":this.hasFrozenRows&&!this._options.alwaysAllowHorizontalScroll?"hidden":"auto",this._viewportTopL.style.overflowY=!this.hasFrozenColumns()&&this._options.alwaysShowVerticalScroll?"scroll":this.hasFrozenColumns()?(this.hasFrozenRows,"hidden"):this.hasFrozenRows?"scroll":"auto",this._viewportTopR.style.overflowX=this.hasFrozenColumns()?this.hasFrozenRows&&!this._options.alwaysAllowHorizontalScroll?"hidden":"scroll":this.hasFrozenRows&&!this._options.alwaysAllowHorizontalScroll?"hidden":"auto",this._viewportTopR.style.overflowY=this._options.alwaysShowVerticalScroll?"scroll":this.hasFrozenColumns()?this.hasFrozenRows?"scroll":"auto":this.hasFrozenRows?"scroll":"auto",this._viewportBottomL.style.overflowX=this.hasFrozenColumns()?this.hasFrozenRows&&!this._options.alwaysAllowHorizontalScroll?"scroll":"auto":(this.hasFrozenRows&&this._options.alwaysAllowHorizontalScroll,"auto"),this._viewportBottomL.style.overflowY=!this.hasFrozenColumns()&&this._options.alwaysShowVerticalScroll?"scroll":this.hasFrozenColumns()?(this.hasFrozenRows,"hidden"):this.hasFrozenRows?"scroll":"auto",this._viewportBottomR.style.overflowX=this.hasFrozenColumns()?this.hasFrozenRows&&!this._options.alwaysAllowHorizontalScroll?"scroll":"auto":(this.hasFrozenRows&&this._options.alwaysAllowHorizontalScroll,"auto"),this._viewportBottomR.style.overflowY=this._options.alwaysShowVerticalScroll?"scroll":this.hasFrozenColumns()?(this.hasFrozenRows,"auto"):(this.hasFrozenRows,"auto"),this._options.viewportClass){let e=L.classNameToList(this._options.viewportClass);this._viewportTopL.classList.add(...e),this._viewportTopR.classList.add(...e),this._viewportBottomL.classList.add(...e),this._viewportBottomR.classList.add(...e)}}createCssRules(){this._style=document.createElement("style"),this._style.nonce=this._options.nonce||"",(this._options.shadowRoot||document.head).appendChild(this._style);let e=this._options.rowHeight-this.cellHeightDiff,t=[`.${this.uid} .slick-group-header-column { left: 1000px; }`,`.${this.uid} .slick-header-column { left: 1000px; }`,`.${this.uid} .slick-top-panel { height: ${this._options.topPanelHeight}px; }`,`.${this.uid} .slick-preheader-panel { height: ${this._options.preHeaderPanelHeight}px; }`,`.${this.uid} .slick-topheader-panel { height: ${this._options.topHeaderPanelHeight}px; }`,`.${this.uid} .slick-headerrow-columns { height: ${this._options.headerRowHeight}px; }`,`.${this.uid} .slick-footerrow-columns { height: ${this._options.footerRowHeight}px; }`,`.${this.uid} .slick-cell { height: ${e}px; }`,`.${this.uid} .slick-row { height: ${this._options.rowHeight}px; }`],n=this._style.sheet;if(n){t.forEach(o=>{n.insertRule(o)});for(let o=0;o<this.columns.length;o++)!this.columns[o]||this.columns[o].hidden||(n.insertRule(`.${this.uid} .l${o} { }`),n.insertRule(`.${this.uid} .r${o} { }`))}else this.createCssRulesAlternative(t)}createCssRulesAlternative(e){let t=document.createElement("template");t.innerHTML='<style type="text/css" rel="stylesheet" />',this._style=t.content.firstChild,(this._options.shadowRoot||document.head).appendChild(this._style);for(let n=0;n<this.columns.length;n++)!this.columns[n]||this.columns[n].hidden||(e.push(`.${this.uid} .l${n} { }`),e.push(`.${this.uid} .r${n} { }`));this._style.styleSheet?this._style.styleSheet.cssText=e.join(" "):this._style.appendChild(document.createTextNode(e.join(" ")))}getColumnCssRules(e){let t;if(!this.stylesheet){let n=(this._options.shadowRoot||document).styleSheets;for(this._options.devMode&&typeof this._options.devMode?.ownerNodeIndex=="number"&&this._options.devMode.ownerNodeIndex>=0&&(n[this._options.devMode.ownerNodeIndex].ownerNode=this._style),t=0;t<n.length;t++)if((n[t].ownerNode||n[t].owningElement)===this._style){this.stylesheet=n[t];break}if(!this.stylesheet)throw new Error("SlickGrid Cannot find stylesheet.");this.columnCssRulesL=[],this.columnCssRulesR=[];let o=this.stylesheet.cssRules||this.stylesheet.rules,r,i;for(t=0;t<o.length;t++){let a=o[t].selectorText;(r=/\.l\d+/.exec(a))?(i=parseInt(r[0].substr(2,r[0].length-2),10),this.columnCssRulesL[i]=o[t]):(r=/\.r\d+/.exec(a))&&(i=parseInt(r[0].substr(2,r[0].length-2),10),this.columnCssRulesR[i]=o[t])}}return{left:this.columnCssRulesL[e],right:this.columnCssRulesR[e]}}removeCssRules(){this._style?.remove(),this.stylesheet=null}getTopPanel(){return this._topPanels[0]}getTopPanels(){return this._topPanels}togglePanelVisibility(e,t,n,o){let r=o!==!1;if(this._options[e]!==n)if(this._options[e]=n,n){if(r){L.slideDown(t,this.resizeCanvas.bind(this));return}L.show(t),this.resizeCanvas()}else{if(r){L.slideUp(t,this.resizeCanvas.bind(this));return}L.hide(t),this.resizeCanvas()}}setTopPanelVisibility(e,t){this.togglePanelVisibility("showTopPanel",this._topPanelScrollers,e,t)}setHeaderRowVisibility(e,t){this.togglePanelVisibility("showHeaderRow",this._headerRowScroller,e,t)}setColumnHeaderVisibility(e,t){this.togglePanelVisibility("showColumnHeader",this._headerScroller,e,t)}setFooterRowVisibility(e,t){this.togglePanelVisibility("showFooterRow",this._footerRowScroller,e,t)}setPreHeaderPanelVisibility(e,t){this.togglePanelVisibility("showPreHeaderPanel",[this._preHeaderPanelScroller,this._preHeaderPanelScrollerR],e,t)}setTopHeaderPanelVisibility(e){this.togglePanelVisibility("showTopHeaderPanel",this._topHeaderPanelScroller,e)}getRowHeight(){return this._options.rowHeight}getRowTop(e){return Math.round(this._options.rowHeight*e-this.offset)}getRowBottom(e){return this.getRowTop(e)+this._options.rowHeight}getRowFromPosition(e){return Math.floor((e+this.offset)/this._options.rowHeight)}appendRowHtml(e,t,n,o,r){let i=this.getDataItem(n),a=n<r&&!i,l="slick-row"+(this.hasFrozenRows&&n<=this._options.frozenRow?" frozen":"")+(a?" loading":"")+(n===this.activeRow&&this._options.showCellSelection?" active":"")+(n%2===1?" odd":" even");i||(l+=` ${this._options.addNewRowCssClass}`);let d=this.getItemMetadaWhenExists(n);d?.cssClasses&&(l+=` ${d.cssClasses}`);let u=L.createDomElement("div",{className:`ui-widget-content ${l}`,role:"row",dataset:{row:`${n}`}}),f=this.getFrozenRowOffset(n),p=this.getRowTop(n)-f;this._options.rowTopOffsetRenderType==="transform"?u.style.transform=`translateY(${p}px)`:u.style.top=`${p}px`;let y;e.push(u),this.hasFrozenColumns()&&(y=u.cloneNode(!0),t.push(y));let b=this.columns.length,w,g,v,E,P=!0;for(let x=0,S=b;x<S;x++){if(P=!0,E=this.columns[x],!E||E.hidden)continue;g=1,v=1,w=null,d?.columns&&(w=d.columns[E.id]||d.columns[x],g=w?.colspan||1,v=w?.rowspan||1,g==="*"&&(g=S-x),v>r-n&&(v=r-n)),!this._options.enableCellRowSpan&&v>1&&console.warn('[SlickGrid] Cell "rowspan" is an opt-in grid option because of its small perf hit, you must enable it via the "enableCellRowSpan" grid option.');let C=g;if(!this.getParentRowSpanByCell(n,x)){if(this.columnPosRight[Math.min(S-1,x+C-1)]>o.leftPx){if(!E.alwaysRenderColumn&&this.columnPosLeft[x]>o.rightPx&&(P=!1),P){let O=this.hasFrozenColumns()&&x>this._options.frozenColumn?y:u;this.appendCellHtml(O,n,x,C,v,w,i)}}else(E.alwaysRenderColumn||this.hasFrozenColumns()&&x<=this._options.frozenColumn)&&this.appendCellHtml(u,n,x,C,v,w,i);C>1&&(x+=C-1)}}}appendCellHtml(e,t,n,o,r,i,a){let l=this.columns[n],d=`slick-cell l${n} r${Math.min(this.columns.length-1,n+o-1)}`+(l.cssClass?` ${l.cssClass}`:"")+(r>1?" rowspan":"")+(i?.cssClass?` ${i.cssClass}`:"");this.hasFrozenColumns()&&n<=this._options.frozenColumn&&(d+=" frozen"),t===this.activeRow&&n===this.activeCell&&this._options.showCellSelection&&(d+=" active"),Object.keys(this.cellCssClasses).forEach(v=>{this.cellCssClasses[v][t]?.[l.id]&&(d+=` ${this.cellCssClasses[v][t][l.id]}`)});let u=null,f="";a&&(u=this.getDataItemValueForColumn(a,l),f=this.getFormatter(t,l)(t,n,u,l,a,this),f==null&&(f=""));let p=this.trigger(this.onBeforeAppendCell,{row:t,cell:n,value:u,dataContext:a}).getReturnValue(),y=typeof p=="string"?p:"";f?.addClasses&&(y+=L.classNameToList((y?" ":"")+f.addClasses).join(" "));let b=f?.toolTip?`${f.toolTip}`:"",w=L.createDomElement("div",{className:L.classNameToList(`${d} ${y||""}`).join(" "),role:"gridcell",tabIndex:-1});w.setAttribute("aria-describedby",this.uid+l.id),b&&w.setAttribute("title",b);let g=this.getCellHeight(t,r);if(r>1&&g!==this._options.rowHeight-this.cellHeightDiff&&(w.style.height=`${g||0}px`),l.hasOwnProperty("cellAttrs")&&l.cellAttrs instanceof Object&&Object.keys(l.cellAttrs).forEach(v=>{l.cellAttrs.hasOwnProperty(v)&&w.setAttribute(v,l.cellAttrs[v])}),a){let v=Object.prototype.toString.call(f)!=="[object Object]"?f:f.html||f.text;this.applyHtmlCode(w,v)}e.appendChild(w),f.insertElementAfterTarget&&L.insertAfterElement(w,f.insertElementAfterTarget),this.rowsCache[t].cellRenderQueue.push(n),this.rowsCache[t].cellColSpans[n]=o}cleanupRows(e){let t=new Set;if(this._options.enableCellRowSpan)for(let n=e.top,o=e.bottom;n<=o;n++){let r=this.getRowSpanIntersect(n);r!==null&&t.add(r)}Object.keys(this.rowsCache).forEach(n=>{if(this.rowsCache){let o=+n,r=!0;this.hasFrozenRows&&(this._options.frozenBottom&&o>=this.actualFrozenRow||!this._options.frozenBottom&&o<=this.actualFrozenRow)&&(r=!1),(o=parseInt(n,10))!==this.activeRow&&(o<e.top||o>e.bottom)&&r&&!t.has(o)&&this.removeRowFromCache(o)}}),this._options.enableAsyncPostRenderCleanup&&this.startPostProcessingCleanup()}invalidate(){this.updateRowCount(),this.invalidateAllRows(),this.render()}invalidateAllRows(){this.currentEditor&&this.makeActiveCellNormal(),typeof this.rowsCache=="object"&&Object.keys(this.rowsCache).forEach(e=>{this.rowsCache&&this.removeRowFromCache(+e)}),this._options.enableAsyncPostRenderCleanup&&this.startPostProcessingCleanup()}invalidateRows(e){if(!e||!e.length)return;let t;this.vScrollDir=0;let n=e.length,o=new Set,r=new Set,i=e.length>this._options.maxPartialRowSpanRemap||e.length===this.getDataLength()||this._prevInvalidatedRowsCount+e.length===this.getDataLength();for(let a=0;a<n;a++)if(t=e[a],this.currentEditor&&this.activeRow===t&&this.makeActiveCellNormal(),this.rowsCache[t]&&this.removeRowFromCache(t),this._options.enableCellRowSpan&&!i){o.add(t);let l=this.getRowSpanIntersect(t);l!==null&&o.add(l)}if(this._options.enableCellRowSpan&&!i){for(let a of Array.from(o)){let l=this.getRowSpanColumnIntersects(a);for(let d of l){let u=this.getParentRowSpanByCell(a,d);u&&this._colsWithRowSpanCache[d]&&(this._colsWithRowSpanCache[d].delete(u.range),r.add(u.range.split(":").map(Number)[0]))}}for(let a of Array.from(r))this.remapRowSpanMetadataByRow(a)}this._options.enableAsyncPostRenderCleanup&&this.startPostProcessingCleanup(),this._prevInvalidatedRowsCount=e.length}invalidateRow(e){if(e>=0){let t=[e];if(this._options.enableCellRowSpan){let n=this.getRowSpanIntersect(e);n!==null&&t.push(n)}this.invalidateRows(t)}}removeRowFromCache(e){let t=this.rowsCache[e];t?.rowNode&&(this.trigger(this.onBeforeRemoveCachedRow,{row:e}),this._options.enableAsyncPostRenderCleanup&&this.postProcessedRows[e]?this.queuePostProcessedRowForCleanup(t,this.postProcessedRows[e],e):t.rowNode?.forEach(n=>n.parentElement?.removeChild(n)),delete this.rowsCache[e],delete this.postProcessedRows[e],this.renderedRows--,this.counter_rows_removed++)}updateCell(e,t){let n=this.getCellNode(e,t);if(!n)return;let o=this.columns[t],r=this.getDataItem(e);if(this.currentEditor&&this.activeRow===e&&this.activeCell===t)this.currentEditor.loadValue(r);else{let i=r?this.getFormatter(e,o)(e,t,this.getDataItemValueForColumn(r,o),o,r,this):"";this.applyFormatResultToCellNode(i,n),this.invalidatePostProcessingResults(e)}}updateRow(e){let t=this.rowsCache[e];if(!t)return;this.ensureCellNodesInRowsCache(e);let n,o=this.getDataItem(e);Object.keys(t.cellNodesByColumnIdx).forEach(r=>{if(!t.cellNodesByColumnIdx.hasOwnProperty(r))return;let i=+r,a=this.columns[i],l=t.cellNodesByColumnIdx[i];e===this.activeRow&&i===this.activeCell&&this.currentEditor?this.currentEditor.loadValue(o):o?(n=this.getFormatter(e,a)(e,i,this.getDataItemValueForColumn(o,a),a,o,this),this.applyFormatResultToCellNode(n,l)):L.emptyElement(l)}),this.invalidatePostProcessingResults(e)}getViewportRowCount(){let e=this.getViewportHeight(),t=this.getScrollbarDimensions()?.height??0;return Math.floor((e-t)/this._options.rowHeight)}getViewportHeight(){if((!this._options.autoHeight||this._options.frozenColumn!==-1)&&(this.topPanelH=this._options.showTopPanel?this._options.topPanelHeight+this.getVBoxDelta(this._topPanelScrollers[0]):0,this.headerRowH=this._options.showHeaderRow?this._options.headerRowHeight+this.getVBoxDelta(this._headerRowScroller[0]):0,this.footerRowH=this._options.showFooterRow?this._options.footerRowHeight+this.getVBoxDelta(this._footerRowScroller[0]):0),this._options.autoHeight){let e=this._paneHeaderL.offsetHeight;e+=this._options.showPreHeaderPanel?this._options.preHeaderPanelHeight+this.getVBoxDelta(this._preHeaderPanelScroller):0,e+=this._options.showHeaderRow?this._options.headerRowHeight+this.getVBoxDelta(this._headerRowScroller[0]):0,e+=this._options.showFooterRow?this._options.footerRowHeight+this.getVBoxDelta(this._footerRowScroller[0]):0,e+=this.getCanvasWidth()>this.viewportW?this.scrollbarDimensions?.height??0:0,this.viewportH=this._options.rowHeight*this.getDataLengthIncludingAddNew()+(this._options.frozenColumn===-1?e:0)}else{let e=getComputedStyle(this._container),t=e.boxSizing!=="content-box"?this.getVBoxDelta(this._container):0,n=this._options.createTopHeaderPanel&&this._options.showTopHeaderPanel?this._options.topHeaderPanelHeight+this.getVBoxDelta(this._topHeaderPanelScroller):0,o=this._options.createPreHeaderPanel&&this._options.showPreHeaderPanel?this._options.preHeaderPanelHeight+this.getVBoxDelta(this._preHeaderPanelScroller):0,r=this._options.showColumnHeader?L.toFloat(L.height(this._headerScroller[0])):0;this.viewportH=L.toFloat(e.height)-L.toFloat(e.paddingTop)-L.toFloat(e.paddingBottom)-this.topPanelH-n-o-this.headerRowH-r-this.footerRowH-t}return this.numVisibleRows=Math.ceil(this.viewportH/this._options.rowHeight),this.viewportH}getViewportInnerWidth(){return this.viewportHasVScroll?this.viewportW-(this.scrollbarDimensions?.width||0):this.viewportW}getViewportWidth(){return this.viewportW=parseFloat(L.innerSize(this._container,"width"))||this._options.devMode&&this._options.devMode.containerClientWidth||0,this.viewportW}resizeCanvas(){if(!this.initialized)return;if(this.paneTopH=0,this.paneBottomH=0,this.viewportTopH=0,this.viewportBottomH=0,this.getViewportWidth(),this.getViewportHeight(),this.hasFrozenRows?this._options.frozenBottom?(this.paneTopH=this.viewportH-this.frozenRowsHeight-(this.scrollbarDimensions?.height??0),this.paneBottomH=this.frozenRowsHeight+(this.scrollbarDimensions?.height??0)):(this.paneTopH=this.frozenRowsHeight,this.paneBottomH=this.viewportH-this.frozenRowsHeight):this.paneTopH=this.viewportH,this.paneTopH+=this.topPanelH+this.headerRowH+this.footerRowH,this.hasFrozenColumns()&&this._options.autoHeight&&(this.paneTopH+=this.scrollbarDimensions?.height??0),this.viewportTopH=this.paneTopH-this.topPanelH-this.headerRowH-this.footerRowH,this._options.autoHeight){if(this.hasFrozenColumns()){let n=this.paneTopH+this._headerScrollerL.offsetHeight;n+=this.getVBoxDelta(this._container),this._options.showPreHeaderPanel&&(n+=this._options.preHeaderPanelHeight),L.height(this._container,n)}this._paneTopL.style.position="relative"}let e=L.height(this._paneHeaderL);e?e+=this._options.showTopHeaderPanel?this._options.topHeaderPanelHeight:0:e=(this._options.showHeaderRow?this._options.headerRowHeight:0)+(this._options.showPreHeaderPanel?this._options.preHeaderPanelHeight:0),L.setStyleSize(this._paneTopL,"top",e||e),L.height(this._paneTopL,this.paneTopH);let t=this._paneTopL.offsetTop+this.paneTopH;if(this._options.autoHeight||L.height(this._viewportTopL,this.viewportTopH),this.hasFrozenColumns()){let n=L.height(this._paneHeaderL);n&&(n+=this._options.showTopHeaderPanel?this._options.topHeaderPanelHeight:0),L.setStyleSize(this._paneTopR,"top",n),L.height(this._paneTopR,this.paneTopH),L.height(this._viewportTopR,this.viewportTopH),this.hasFrozenRows&&(L.setStyleSize(this._paneBottomL,"top",t),L.height(this._paneBottomL,this.paneBottomH),L.setStyleSize(this._paneBottomR,"top",t),L.height(this._paneBottomR,this.paneBottomH),L.height(this._viewportBottomR,this.paneBottomH))}else this.hasFrozenRows&&(L.width(this._paneBottomL,"100%"),L.height(this._paneBottomL,this.paneBottomH),L.setStyleSize(this._paneBottomL,"top",t));this.hasFrozenRows?(L.height(this._viewportBottomL,this.paneBottomH),this._options.frozenBottom?(L.height(this._canvasBottomL,this.frozenRowsHeight),this.hasFrozenColumns()&&L.height(this._canvasBottomR,this.frozenRowsHeight)):(L.height(this._canvasTopL,this.frozenRowsHeight),this.hasFrozenColumns()&&L.height(this._canvasTopR,this.frozenRowsHeight))):L.height(this._viewportTopR,this.viewportTopH),(!this.scrollbarDimensions||!this.scrollbarDimensions.width)&&(this.scrollbarDimensions=this.measureScrollbar()),this._options.autosizeColsMode===_n.LegacyForceFit&&this.autosizeColumns(),this.updateRowCount(),this.handleScroll(),this.lastRenderedScrollLeft=-1,this.render()}updateRowCount(){if(!this.initialized)return;let e=this.getDataLength();e>0&&e!==this._prevDataLength&&(this._rowSpanIsCached=!1),this._options.enableCellRowSpan&&!this._rowSpanIsCached&&this.remapAllColumnsRowSpan(),this._prevDataLength=e;let t=this.getDataLengthIncludingAddNew(),n=0,o=this.hasFrozenRows&&!this._options.frozenBottom?L.height(this._canvasBottomL):L.height(this._canvasTopL);this.hasFrozenRows?n=this.getDataLength()-this._options.frozenRow:n=t+(this._options.leaveSpaceForNewRows?this.numVisibleRows-1:0);let r=L.height(this._viewportScrollContainerY),i=this.viewportHasVScroll;this.viewportHasVScroll=this._options.alwaysShowVerticalScroll||!this._options.autoHeight&&n*this._options.rowHeight>r,this.makeActiveCellNormal();let a=e-1;typeof this.rowsCache=="object"&&Object.keys(this.rowsCache).forEach(d=>{let u=+d;u>a&&this.removeRowFromCache(u)}),this._options.enableAsyncPostRenderCleanup&&this.startPostProcessingCleanup(),this.activeCellNode&&this.activeRow>a&&this.resetActiveCell(),o=this.h,this._options.autoHeight?this.h=this._options.rowHeight*n:(this.th=Math.max(this._options.rowHeight*n,r-(this.scrollbarDimensions?.height??0)),this.th<this.maxSupportedCssHeight?(this.h=this.ph=this.th,this.n=1,this.cj=0):(this.h=this.maxSupportedCssHeight,this.ph=this.h/100,this.n=Math.floor(this.th/this.ph),this.cj=(this.th-this.h)/(this.n-1))),(this.h!==o||this.enforceFrozenRowHeightRecalc)&&(this.hasFrozenRows&&!this._options.frozenBottom?(L.height(this._canvasBottomL,this.h),this.hasFrozenColumns()&&L.height(this._canvasBottomR,this.h)):(L.height(this._canvasTopL,this.h),L.height(this._canvasTopR,this.h)),this.scrollTop=this._viewportScrollContainerY.scrollTop,this.scrollHeight=this._viewportScrollContainerY.scrollHeight,this.enforceFrozenRowHeightRecalc=!1);let l=this.scrollTop+this.offset<=this.th-r;this.th===0||this.scrollTop===0?this.page=this.offset=0:l?this.scrollTo(this.scrollTop+this.offset):this.scrollTo(this.th-r+(this.scrollbarDimensions?.height??0)),this.h!==o&&this._options.autoHeight&&this.resizeCanvas(),this._options.autosizeColsMode===_n.LegacyForceFit&&i!==this.viewportHasVScroll&&this.autosizeColumns(),this.updateCanvasWidth(!1)}getViewport(e,t){return this.getVisibleRange(e,t)}getVisibleRange(e,t){return e??(e=this.scrollTop),t??(t=this.scrollLeft),{top:this.getRowFromPosition(e),bottom:this.getRowFromPosition(e+this.viewportH)+1,leftPx:t,rightPx:t+this.viewportW}}getRenderedRange(e,t){let n=this.getVisibleRange(e,t),o=Math.round(this.viewportH/this._options.rowHeight),r=this._options.minRowBuffer;return this.vScrollDir===-1?(n.top-=o,n.bottom+=r):this.vScrollDir===1?(n.top-=r,n.bottom+=o):(n.top-=r,n.bottom+=r),n.top=Math.max(0,n.top),n.bottom=Math.min(this.getDataLengthIncludingAddNew()-1,n.bottom),n.leftPx-=this.viewportW,n.rightPx+=this.viewportW,n.leftPx=Math.max(0,n.leftPx),n.rightPx=Math.min(this.canvasWidth,n.rightPx),n}getRowCache(){return this.rowsCache}ensureCellNodesInRowsCache(e){let t=this.rowsCache[e];if(t?.cellRenderQueue.length&&t.rowNode?.length){let n=t.rowNode,o=Array.from(n[0].children);n.length>1&&(o=o.concat(Array.from(n[1].children)));let r=o.length-1;for(;t.cellRenderQueue.length;){let i=t.cellRenderQueue.pop();t.cellNodesByColumnIdx[i]=o[r--]}}}cleanUpCells(e,t){if(this.hasFrozenRows&&(this._options.frozenBottom&&t>this.actualFrozenRow||t<=this.actualFrozenRow))return;let n=this.rowsCache[t],o=[];Object.keys(n.cellNodesByColumnIdx).forEach(a=>{if(!n.cellNodesByColumnIdx.hasOwnProperty(a))return;let l=+a;if(l<=this._options.frozenColumn||Array.isArray(this.columns)&&this.columns[l]?.alwaysRenderColumn)return;let d=n.cellColSpans[l];(this.columnPosLeft[l]>e.rightPx||this.columnPosRight[Math.min(this.columns.length-1,(l||0)+d-1)]<e.leftPx)&&(t===this.activeRow&&Number(l)===this.activeCell||o.push(l))});let r,i;for(;L.isDefined(r=o.pop());)i=n.cellNodesByColumnIdx[r],this._options.enableAsyncPostRenderCleanup&&this.postProcessedRows[t]?.[r]?this.queuePostProcessedCellForCleanup(i,r,t):i.parentElement?.removeChild(i),delete n.cellColSpans[r],delete n.cellNodesByColumnIdx[r],this.postProcessedRows[t]&&delete this.postProcessedRows[t][r]}cleanUpAndRenderCells(e){let t,n=document.createElement("div"),o=[],r,i,a,l=this.columns.length;for(let f=e.top,p=e.bottom;f<=p;f++){if(t=this.rowsCache[f],!t)continue;this.ensureCellNodesInRowsCache(f),(!this._options.enableCellRowSpan||this.getRowSpanIntersect(f)===null)&&this.cleanUpCells(e,f),r=0;let y=this.getItemMetadaWhenExists(f);y=y?.columns;let b=this.getDataItem(f);for(let w=0,g=l;w<g;w++){if(!this.columns[w]||this.columns[w].hidden)continue;if(this.columnPosLeft[w]>e.rightPx)break;if(L.isDefined(i=t.cellColSpans[w])){w+=i>1?i-1:0;continue}i=1,a=null,y&&(a=y[this.columns[w].id]||y[w],i=a?.colspan??1,i==="*"&&(i=g-w));let v=i;if(!this.getParentRowSpanByCell(f,w)){if(this.columnPosRight[Math.min(g-1,w+v-1)]>e.leftPx){let E=this.getRowspan(f,w);this.appendCellHtml(n,f,w,v,E,a,b),r++}w+=v>1?v-1:0}}r&&o.push(f)}if(!n.children.length)return;let d,u;for(;L.isDefined(d=o.pop());){t=this.rowsCache[d];let f;for(;L.isDefined(f=t.cellRenderQueue.pop());)u=n.lastChild,u&&(this.hasFrozenColumns()&&f>this._options.frozenColumn?t.rowNode[1].appendChild(u):t.rowNode[0].appendChild(u),t.cellNodesByColumnIdx[f]=u)}}renderRows(e){let t=[],n=[],o=[],r=!1,i=this.getDataLength(),a=new Set,l=new Set;for(let u=e.top,f=e.bottom;u<=f;u++)if(!(this.rowsCache[u]||this.hasFrozenRows&&this._options.frozenBottom&&u===this.getDataLength())){if(this.renderedRows++,o.push(u),l.add(u),this.rowsCache[u]=this.createEmptyCachingRow(),this._options.enableCellRowSpan){let p=this.getRowSpanIntersect(u);p!==null&&l.add(p)}this.appendRowHtml(t,n,u,e,i),a.add(u),this.activeCellNode&&this.activeRow===u&&(r=!0),this.counter_rows_rendered++}let d=this.setDifference(l,a);if(d.size>0&&d.forEach(u=>{this.removeRowFromCache(u),o.push(u),this.rowsCache[u]=this.createEmptyCachingRow(),this.appendRowHtml(t,n,u,e,i)}),o.length){let u=document.createElement("div"),f=document.createElement("div");t.forEach(p=>u.appendChild(p)),n.forEach(p=>f.appendChild(p));for(let p=0,y=o.length;p<y;p++)this.hasFrozenRows&&o[p]>=this.actualFrozenRow?this.hasFrozenColumns()?this.rowsCache?.hasOwnProperty(o[p])&&u.firstChild&&f.firstChild&&(this.rowsCache[o[p]].rowNode=[u.firstChild,f.firstChild],this._canvasBottomL.appendChild(u.firstChild),this._canvasBottomR.appendChild(f.firstChild)):this.rowsCache?.hasOwnProperty(o[p])&&u.firstChild&&(this.rowsCache[o[p]].rowNode=[u.firstChild],this._canvasBottomL.appendChild(u.firstChild)):this.hasFrozenColumns()?this.rowsCache?.hasOwnProperty(o[p])&&u.firstChild&&f.firstChild&&(this.rowsCache[o[p]].rowNode=[u.firstChild,f.firstChild],this._canvasTopL.appendChild(u.firstChild),this._canvasTopR.appendChild(f.firstChild)):this.rowsCache?.hasOwnProperty(o[p])&&u.firstChild&&(this.rowsCache[o[p]].rowNode=[u.firstChild],this._canvasTopL.appendChild(u.firstChild));r&&(this.activeCellNode=this.getCellNode(this.activeRow,this.activeCell))}}updateRowPositions(){for(let e in this.rowsCache)if(this.rowsCache){let t=e?parseInt(e,10):0,n=this.rowsCache[t].rowNode[0];this._options.rowTopOffsetRenderType==="transform"?n.style.transform=`translateY(${this.getRowTop(t)}px)`:n.style.top=`${this.getRowTop(t)}px`}}render(){if(!this.initialized)return;this.scrollThrottle.dequeue();let e=this.getVisibleRange(),t=this.getRenderedRange();if(this.cleanupRows(t),this.lastRenderedScrollLeft!==this.scrollLeft){if(this.hasFrozenRows){let n=L.extend(!0,{},t);this._options.frozenBottom?(n.top=this.actualFrozenRow,n.bottom=this.getDataLength()):(n.top=0,n.bottom=this._options.frozenRow),this.cleanUpAndRenderCells(n)}this.cleanUpAndRenderCells(t)}this.renderRows(t),this.hasFrozenRows&&(this._options.frozenBottom?this.renderRows({top:this.actualFrozenRow,bottom:this.getDataLength()-1,leftPx:t.leftPx,rightPx:t.rightPx}):this.renderRows({top:0,bottom:this._options.frozenRow-1,leftPx:t.leftPx,rightPx:t.rightPx})),this.postProcessFromRow=e.top,this.postProcessToRow=Math.min(this.getDataLengthIncludingAddNew()-1,e.bottom),this.startPostProcessing(),this.lastRenderedScrollTop=this.scrollTop,this.lastRenderedScrollLeft=this.scrollLeft,this.trigger(this.onRendered,{startRow:e.top,endRow:e.bottom,grid:this})}getFrozenRowOffset(e){let t=0;return this.hasFrozenRows?this._options.frozenBottom?e>=this.actualFrozenRow?this.h<this.viewportTopH?t=this.actualFrozenRow*this._options.rowHeight:t=this.h:t=0:e>=this.actualFrozenRow?t=this.frozenRowsHeight:t=0:t=0,t}bindAncestorScrollEvents(){let e=this.hasFrozenRows&&!this._options.frozenBottom?this._canvasBottomL:this._canvasTopL;for(;(e=e.parentNode)!==document.body&&e;)(e===this._viewportTopL||e.scrollWidth!==e.clientWidth||e.scrollHeight!==e.clientHeight)&&(this._boundAncestors.push(e),this._bindingEventService.bind(e,"scroll",this.handleActiveCellPositionChange.bind(this)))}unbindAncestorScrollEvents(){this._boundAncestors.forEach(e=>{this._bindingEventService.unbindByEventName(e,"scroll")}),this._boundAncestors=[]}setScroller(){this.hasFrozenColumns()?(this._headerScrollContainer=this._headerScrollerR,this._headerRowScrollContainer=this._headerRowScrollerR,this._footerRowScrollContainer=this._footerRowScrollerR,this.hasFrozenRows?this._options.frozenBottom?(this._viewportScrollContainerX=this._viewportBottomR,this._viewportScrollContainerY=this._viewportTopR):this._viewportScrollContainerX=this._viewportScrollContainerY=this._viewportBottomR:this._viewportScrollContainerX=this._viewportScrollContainerY=this._viewportTopR):(this._headerScrollContainer=this._headerScrollerL,this._headerRowScrollContainer=this._headerRowScrollerL,this._footerRowScrollContainer=this._footerRowScrollerL,this.hasFrozenRows?this._options.frozenBottom?(this._viewportScrollContainerX=this._viewportBottomL,this._viewportScrollContainerY=this._viewportTopL):this._viewportScrollContainerX=this._viewportScrollContainerY=this._viewportBottomL:this._viewportScrollContainerX=this._viewportScrollContainerY=this._viewportTopL)}scrollTo(e){e=Math.max(e,0),e=Math.min(e,(this.th||0)-L.height(this._viewportScrollContainerY)+(this.viewportHasHScroll||this.hasFrozenColumns()?this.scrollbarDimensions?.height??0:0));let t=this.offset;this.offset=Math.round(this.page*(this.cj||0)),this.page=Math.min((this.n||0)-1,Math.floor(e/(this.ph||0)));let n=e-this.offset;if(this.offset!==t){let o=this.getVisibleRange(n);this.cleanupRows(o),this.updateRowPositions()}this.prevScrollTop!==n&&(this.vScrollDir=this.prevScrollTop+t<n+this.offset?1:-1,this.lastRenderedScrollTop=this.scrollTop=this.prevScrollTop=n,this.hasFrozenColumns()&&(this._viewportTopL.scrollTop=n),this.hasFrozenRows&&(this._viewportBottomL.scrollTop=this._viewportBottomR.scrollTop=n),this._viewportScrollContainerY&&(this._viewportScrollContainerY.scrollTop=n),this.trigger(this.onViewportChanged,{}))}handleHeaderRowScroll(){let e=this._headerRowScrollContainer.scrollLeft;e!==this._viewportScrollContainerX.scrollLeft&&(this._viewportScrollContainerX.scrollLeft=e)}handleFooterRowScroll(){let e=this._footerRowScrollContainer.scrollLeft;e!==this._viewportScrollContainerX.scrollLeft&&(this._viewportScrollContainerX.scrollLeft=e)}handlePreHeaderPanelScroll(){this.handleElementScroll(this._preHeaderPanelScroller)}handleTopHeaderPanelScroll(){this.handleElementScroll(this._topHeaderPanelScroller)}handleElementScroll(e){let t=e.scrollLeft;t!==this._viewportScrollContainerX.scrollLeft&&(this._viewportScrollContainerX.scrollLeft=t)}handleScroll(e){return this.scrollHeight=this._viewportScrollContainerY.scrollHeight,this.scrollTop=this._viewportScrollContainerY.scrollTop,this.scrollLeft=this._viewportScrollContainerX.scrollLeft,this._handleScroll(e?"scroll":"system")}_handleScroll(e="system"){let t=this._viewportScrollContainerY.scrollHeight-this._viewportScrollContainerY.clientHeight,n=this._viewportScrollContainerY.scrollWidth-this._viewportScrollContainerY.clientWidth;t=Math.max(0,t),n=Math.max(0,n),this.scrollTop>t&&(this.scrollTop=t,this.scrollHeight=t),this.scrollLeft>n&&(this.scrollLeft=n);let o=Math.abs(this.scrollTop-this.prevScrollTop),r=Math.abs(this.scrollLeft-this.prevScrollLeft);if(r&&(this.prevScrollLeft=this.scrollLeft,this._viewportScrollContainerX.scrollLeft=this.scrollLeft,this._headerScrollContainer.scrollLeft=this.scrollLeft,this._topPanelScrollers[0].scrollLeft=this.scrollLeft,this._options.createFooterRow&&(this._footerRowScrollContainer.scrollLeft=this.scrollLeft),this._options.createPreHeaderPanel&&(this.hasFrozenColumns()?this._preHeaderPanelScrollerR.scrollLeft=this.scrollLeft:this._preHeaderPanelScroller.scrollLeft=this.scrollLeft),this._options.createTopHeaderPanel&&(this._topHeaderPanelScroller.scrollLeft=this.scrollLeft),this.hasFrozenColumns()?(this.hasFrozenRows&&(this._viewportTopR.scrollLeft=this.scrollLeft),this._headerRowScrollerR.scrollLeft=this.scrollLeft):(this.hasFrozenRows&&(this._viewportTopL.scrollLeft=this.scrollLeft),this._headerRowScrollerL.scrollLeft=this.scrollLeft)),o&&!this._options.autoHeight)if(this.vScrollDir=this.prevScrollTop<this.scrollTop?1:-1,this.prevScrollTop=this.scrollTop,e==="mousewheel"&&(this._viewportScrollContainerY.scrollTop=this.scrollTop),this.hasFrozenColumns()&&(this.hasFrozenRows&&!this._options.frozenBottom?this._viewportBottomL.scrollTop=this.scrollTop:this._viewportTopL.scrollTop=this.scrollTop),o<this.viewportH)this.scrollTo(this.scrollTop+this.offset);else{let i=this.offset;this.h===this.viewportH?this.page=0:this.page=Math.min(this.n-1,Math.floor(this.scrollTop*((this.th-this.viewportH)/(this.h-this.viewportH))*(1/this.ph))),this.offset=Math.round(this.page*this.cj),i!==this.offset&&this.invalidateAllRows()}if(r||o){let i=Math.abs(this.lastRenderedScrollLeft-this.scrollLeft),a=Math.abs(this.lastRenderedScrollTop-this.scrollTop);(i>20||a>20)&&(this._options.forceSyncScrolling||a<this.viewportH&&i<this.viewportW?this.render():this.scrollThrottle.enqueue(),this.trigger(this.onViewportChanged,{}))}return this.trigger(this.onScroll,{triggeredBy:e,scrollHeight:this.scrollHeight,scrollLeft:this.scrollLeft,scrollTop:this.scrollTop}),!!(r||o)}scrollCellIntoView(e,t,n){if(this.scrollRowIntoView(e,n),t<=this._options.frozenColumn)return;let o=this.getColspan(e,t);this.internalScrollColumnIntoView(this.columnPosLeft[t],this.columnPosRight[t+(o>1?o-1:0)])}internalScrollColumnIntoView(e,t){let n=this.scrollLeft+L.width(this._viewportScrollContainerX)-(this.viewportHasVScroll?this.scrollbarDimensions?.width??0:0);e<this.scrollLeft?(this._viewportScrollContainerX.scrollLeft=e,this.handleScroll(),this.render()):t>n&&(this._viewportScrollContainerX.scrollLeft=Math.min(e,t-this._viewportScrollContainerX.clientWidth),this.handleScroll(),this.render())}scrollColumnIntoView(e){this.internalScrollColumnIntoView(this.columnPosLeft[e],this.columnPosRight[e])}updatePagingStatusFromView(e){this.pagingActive=e.pageSize!==0,this.pagingIsLastPage=e.pageNum===e.totalPages-1}getRowSpanColumnIntersects(e){return this.getRowSpanIntersection(e,"columns")}getRowSpanIntersect(e){return this.getRowSpanIntersection(e)}getRowSpanIntersection(e,t){let n=[],o=null;for(let r=0,i=this.columns.length;r<i;r++){let a=this._colsWithRowSpanCache[r];if(a)for(let l of Array.from(a)){let[d,u]=l.split(":").map(Number);if(e>=d&&e<=u)if(t==="columns")n.push(r);else{o=d;break}}}return t==="columns"?n:o}getParentRowSpanByCell(e,t,n=!0){let o=null,r=this._colsWithRowSpanCache[t]||new Set;for(let i of Array.from(r)){let[a,l]=i.split(":").map(Number);if((n?e>a:e>=a)&&e<=l){o={start:a,end:l,range:i};break}}return o}remapAllColumnsRowSpan(){let e=this.getDataLength();if(e>0){this._colsWithRowSpanCache={};for(let t=0;t<e;t++)this.remapRowSpanMetadataByRow(t);this._rowSpanIsCached=!0}}remapRowSpanMetadataByRow(e){let t=this.getItemMetadaWhenExists(e);t?.columns&&Object.keys(t.columns).forEach(n=>{let o=+n,r=t.columns[o],i=+(r?.colspan||1),a=+(r?.rowspan||1);this.remapRowSpanMetadata(e,o,i,a)})}remapRowSpanMetadata(e,t,n,o){var r,i,a;if(o>1){let l=`${e}:${e+o-1}`;if((r=this._colsWithRowSpanCache)[t]??(r[t]=new Set),this._colsWithRowSpanCache[t].add(l),n>1)for(let d=1;d<n;d++)(i=this._colsWithRowSpanCache)[a=t+d]??(i[a]=new Set),this._colsWithRowSpanCache[t+d].add(l)}}createEmptyCachingRow(){return{rowNode:null,cellColSpans:[],cellNodesByColumnIdx:[],cellRenderQueue:[]}}scrollRowIntoView(e,t){if(!this.hasFrozenRows||!this._options.frozenBottom&&e>this.actualFrozenRow-1||this._options.frozenBottom&&e<this.actualFrozenRow-1){let n=L.height(this._viewportScrollContainerY),o=this.hasFrozenRows&&!this._options.frozenBottom?e-this._options.frozenRow:e,r=o*this._options.rowHeight,i=(o+1)*this._options.rowHeight-n+(this.viewportHasHScroll?this.scrollbarDimensions?.height??0:0);(o+1)*this._options.rowHeight>this.scrollTop+n+this.offset?(this.scrollTo(t?r:i),this.render()):o*this._options.rowHeight<this.scrollTop+this.offset&&(this.scrollTo(t?i:r),this.render())}}scrollRowToTop(e){this.scrollTo(e*this._options.rowHeight),this.render()}scrollPage(e){let t=e*this.numVisibleRows,n=this.scrollTop+this._options.rowHeight-1;if(this.scrollTo((this.getRowFromPosition(n)+t)*this._options.rowHeight),this.render(),this._options.enableCellNavigation&&L.isDefined(this.activeRow)){let o=this.activeRow+t,r=this.getDataLengthIncludingAddNew();o>=r&&(o=r-1),o<0&&(o=0);let i=e===1?this.gotoDown(o-1||0,this.activeCell,this.activePosY,this.activePosX):this.gotoUp(o+1,this.activeCell,this.activePosY,this.activePosX);this.navigateToPos(i)}}navigatePageDown(){this.scrollPage(1)}navigatePageUp(){this.scrollPage(-1)}navigateTop(){this.unsetActiveCell(),this.navigateToRow(0)}navigateBottom(){let e=this.getDataLength()-1,t=this.getParentRowSpanByCell(e,this.activeCell)?.start??e;do if(this._options.enableCellRowSpan&&this.setActiveRow(t),this.navigateToRow(t)&&this.activeCell===this.activePosX||!L.isDefined(this.activeCell))break;while(--t>0)}navigateToRow(e){let t=this.getDataLength();if(!t)return!1;e<0?e=0:e>=t&&(e=t-1),this.scrollCellIntoView(e,0,!0);let n=!L.isDefined(this.activeCell)||!L.isDefined(this.activeRow);if(this._options.enableCellNavigation&&L.isDefined(this.activeRow)){let o=0,r=null,i=this.activePosX;for(;o<=this.activePosX;)this.canCellBeActive(e,o)&&(r=o,(!L.isDefined(this.activeCell)||o===this.activeCell)&&(n=!0)),o+=this.getColspan(e,o);r!==null?(this.setActiveCellInternal(this.getCellNode(e,r)),this.activePosX=i):this.resetActiveCell()}return n}getColspan(e,t){let n=this.getItemMetadaWhenExists(e);if(!n||!n.columns)return 1;t>=this.columns.length&&(t=this.columns.length-1);let o=(n.columns[this.columns[t].id]||n.columns[t])?.colspan;return o==="*"?o=this.columns.length-t:o=o||1,o}queuePostProcessedRowForCleanup(e,t,n){this.postProcessgroupId++,typeof t=="object"&&Object.keys(t).forEach(o=>{t.hasOwnProperty(o)&&this.postProcessedCleanupQueue.push({actionType:"C",groupId:this.postProcessgroupId,node:e.cellNodesByColumnIdx[+o],columnIdx:+o,rowIdx:n})}),e.rowNode||(e.rowNode=[]),this.postProcessedCleanupQueue.push({actionType:"R",groupId:this.postProcessgroupId,node:e.rowNode}),e.rowNode?.forEach(o=>o.remove())}queuePostProcessedCellForCleanup(e,t,n){this.postProcessedCleanupQueue.push({actionType:"C",groupId:this.postProcessgroupId,node:e,columnIdx:t,rowIdx:n}),e.remove()}applyFormatResultToCellNode(e,t,n){if(e==null&&(e=""),Object.prototype.toString.call(e)!=="[object Object]"){this.applyHtmlCode(t,e);return}let o=e.html||e.text;this.applyHtmlCode(t,o),e.removeClasses&&!n&&t.classList.remove(...L.classNameToList(e.removeClasses)),e.addClasses&&t.classList.add(...L.classNameToList(e.addClasses)),e.toolTip&&t.setAttribute("title",e.toolTip)}startPostProcessing(){this._options.enableAsyncPostRender&&(window.clearTimeout(this.h_postrender),this.h_postrender=window.setTimeout(this.asyncPostProcessRows.bind(this),this._options.asyncPostRenderDelay))}startPostProcessingCleanup(){this._options.enableAsyncPostRenderCleanup&&(window.clearTimeout(this.h_postrenderCleanup),this.h_postrenderCleanup=window.setTimeout(this.asyncPostProcessCleanupRows.bind(this),this._options.asyncPostRenderCleanupDelay))}invalidatePostProcessingResults(e){typeof this.postProcessedRows[e]=="object"&&Object.keys(this.postProcessedRows[e]).forEach(t=>{this.postProcessedRows[e].hasOwnProperty(t)&&(this.postProcessedRows[e][t]="C")}),this.postProcessFromRow=Math.min(this.postProcessFromRow,e),this.postProcessToRow=Math.max(this.postProcessToRow,e),this.startPostProcessing()}asyncPostProcessRows(){let e=this.getDataLength();for(;this.postProcessFromRow<=this.postProcessToRow;){let t=this.vScrollDir>=0?this.postProcessFromRow++:this.postProcessToRow--,n=this.rowsCache[t];if(!(!n||t>=e)){this.postProcessedRows[t]||(this.postProcessedRows[t]={}),this.ensureCellNodesInRowsCache(t),Object.keys(n.cellNodesByColumnIdx).forEach(o=>{if(n.cellNodesByColumnIdx.hasOwnProperty(o)){let r=+o,i=this.columns[r],a=this.postProcessedRows[t][r];if(i.asyncPostRender&&a!=="R"){let l=n.cellNodesByColumnIdx[r];l&&i.asyncPostRender(l,t,this.getDataItem(t),i,a==="C"),this.postProcessedRows[t][r]="R"}}}),this.h_postrender=window.setTimeout(this.asyncPostProcessRows.bind(this),this._options.asyncPostRenderDelay);return}}}asyncPostProcessCleanupRows(){if(this.postProcessedCleanupQueue.length>0){let e=this.postProcessedCleanupQueue[0].groupId;for(;this.postProcessedCleanupQueue.length>0&&this.postProcessedCleanupQueue[0].groupId===e;){let t=this.postProcessedCleanupQueue.shift();if(t?.actionType==="R"&&t.node.forEach(n=>{n.remove()}),t?.actionType==="C"){let n=this.columns[t.columnIdx];n.asyncPostRenderCleanup&&t.node&&n.asyncPostRenderCleanup(t.node,t.rowIdx,n)}}this.h_postrenderCleanup=window.setTimeout(this.asyncPostProcessCleanupRows.bind(this),this._options.asyncPostRenderCleanupDelay)}}updateCellCssStylesOnRenderedRows(e,t){let n,o,r;typeof this.rowsCache=="object"&&Object.keys(this.rowsCache).forEach(i=>{this.rowsCache&&(r=t?.[i],o=e?.[i],r&&Object.keys(r).forEach(a=>{(!o||r[a]!==o[a])&&(n=this.getCellNode(+i,this.getColumnIndex(a)),n&&n.classList.remove(r[a]))}),o&&Object.keys(o).forEach(a=>{(!r||r[a]!==o[a])&&(n=this.getCellNode(+i,this.getColumnIndex(a)),n&&n.classList.add(o[a]))}))})}addCellCssStyles(e,t){if(this.cellCssClasses[e])throw new Error(`SlickGrid addCellCssStyles: cell CSS hash with key "${e}" already exists.`);this.cellCssClasses[e]=t,this.updateCellCssStylesOnRenderedRows(t,null),this.trigger(this.onCellCssStylesChanged,{key:e,hash:t,grid:this})}removeCellCssStyles(e){this.cellCssClasses[e]&&(this.updateCellCssStylesOnRenderedRows(null,this.cellCssClasses[e]),delete this.cellCssClasses[e],this.trigger(this.onCellCssStylesChanged,{key:e,hash:null,grid:this}))}setCellCssStyles(e,t){let n=this.cellCssClasses[e];this.cellCssClasses[e]=t,this.updateCellCssStylesOnRenderedRows(t,n),this.trigger(this.onCellCssStylesChanged,{key:e,hash:t,grid:this})}getCellCssStyles(e){return this.cellCssClasses[e]}flashCell(e,t,n=250){let o=(r,i)=>{i<1||(window.clearTimeout(this._flashCellTimer),this._flashCellTimer=window.setTimeout(()=>{i%2===0?r.classList.add(this._options.cellFlashingCssClass||""):r.classList.remove(this._options.cellFlashingCssClass||""),o(r,i-1)},n))};if(this.rowsCache[e]){let r=this.getCellNode(e,t);r&&o(r,5)}}highlightRow(e,t){let n=this.rowsCache[e];t||(t=this._options.rowHighlightDuration),Array.isArray(n?.rowNode)&&this._options.rowHighlightCssClass&&(n.rowNode.forEach(o=>o.classList.add(...L.classNameToList(this._options.rowHighlightCssClass))),window.clearTimeout(this._highlightRowTimer),this._highlightRowTimer=window.setTimeout(()=>{n.rowNode?.forEach(o=>o.classList.remove(...L.classNameToList(this._options.rowHighlightCssClass)))},t))}_getContainerElement(e,t,n){if(!e)return;t||(t=0),n||(n=0);let o=typeof t=="number"?t:this.getColumnIndex(t),r=this.hasFrozenRows&&n>=this.actualFrozenRow+(this._options.frozenBottom?0:1),i=this.hasFrozenColumns()&&o>this._options.frozenColumn;return e[(r?2:0)+(i?1:0)]}measureScrollbar(){let e="";this._viewport.forEach(r=>e+=r.className);let t=L.createDomElement("div",{className:e,style:{position:"absolute",top:"-10000px",left:"-10000px",overflow:"auto",width:"100px",height:"100px"}},document.body),n=L.createDomElement("div",{style:{width:"200px",height:"200px",overflow:"auto"}},t),o={width:t.offsetWidth-t.clientWidth,height:t.offsetHeight-t.clientHeight};return n.remove(),t.remove(),o}getMaxSupportedCssHeight(){let e=1e6,t=navigator.userAgent.toLowerCase().match(/firefox/)?this._options.ffMaxSupportedCssHeight:this._options.maxSupportedCssHeight,n=L.createDomElement("div",{style:{display:"hidden"}},document.body);for(;;){let o=e*2;L.height(n,o);let r=L.height(n);if(o>t||r!==o)break;e=o}return n.remove(),e}getUID(){return this.uid}getHeaderColumnWidthDiff(){return this.headerColumnWidthDiff}getScrollbarDimensions(){return this.scrollbarDimensions}getDisplayedScrollbarDimensions(){return{width:this.viewportHasVScroll?this.scrollbarDimensions?.width??0:0,height:this.viewportHasHScroll?this.scrollbarDimensions?.height??0:0}}getAbsoluteColumnMinWidth(){return this.absoluteColumnMinWidth}getVBoxDelta(e){let t=["borderTopWidth","borderBottomWidth","paddingTop","paddingBottom"],n=getComputedStyle(e),o=0;return t.forEach(r=>o+=L.toFloat(n[r])),o}measureCellPaddingAndBorder(){let e=["borderLeftWidth","borderRightWidth","paddingLeft","paddingRight"],t=["borderTopWidth","borderBottomWidth","paddingTop","paddingBottom"],n=this._headers[0];this.headerColumnWidthDiff=this.headerColumnHeightDiff=0,this.cellWidthDiff=this.cellHeightDiff=0;let o=L.createDomElement("div",{className:"ui-state-default slick-state-default slick-header-column",style:{visibility:"hidden"},textContent:"-"},n),r=getComputedStyle(o);r.boxSizing!=="border-box"&&(e.forEach(a=>this.headerColumnWidthDiff+=L.toFloat(r[a])),t.forEach(a=>this.headerColumnHeightDiff+=L.toFloat(r[a]))),o.remove();let i=L.createDomElement("div",{className:"slick-row"},this._canvas[0]);o=L.createDomElement("div",{className:"slick-cell",id:"",style:{visibility:"hidden"},textContent:"-"},i),r=getComputedStyle(o),r.boxSizing!=="border-box"&&(e.forEach(a=>this.cellWidthDiff+=L.toFloat(r[a])),t.forEach(a=>this.cellHeightDiff+=L.toFloat(r[a]))),i.remove(),this.absoluteColumnMinWidth=Math.max(this.headerColumnWidthDiff,this.cellWidthDiff)}clearAllTimers(){window.clearTimeout(this._columnResizeTimer),window.clearTimeout(this._executionBlockTimer),window.clearTimeout(this._flashCellTimer),window.clearTimeout(this._highlightRowTimer),window.clearTimeout(this.h_editorLoader)}LogColWidths(){let e="Col Widths:";for(let t=0;t<this.columns.length;t++)e+=" "+(this.columns[t].hidden?"H":this.columns[t].width);console.log(e)}simpleArrayEquals(e,t){return Array.isArray(e)&&Array.isArray(t)&&t.sort().toString()!==e.sort().toString()}defaultFormatter(e,t,n){return L.isDefined(n)?(n+"").replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">"):""}cellExists(e,t){return!(e<0||e>=this.getDataLength()||t<0||t>=this.columns.length)}getCellFromNode(e){let t=/l\d+/.exec(e.className);if(!t)throw new Error(`SlickGrid getCellFromNode: cannot get cell - ${e.className}`);return parseInt(t[0].substr(1,t[0].length-1),10)}getRowFromNode(e){for(let t in this.rowsCache)if(this.rowsCache){for(let n in this.rowsCache[t].rowNode)if(this.rowsCache[t].rowNode?.[+n]===e)return t?parseInt(t,10):0}return null}clearTextSelection(){if(document.selection?.empty)try{document.selection.empty()}catch{}else if(window.getSelection){let e=window.getSelection();e?.removeAllRanges&&e.removeAllRanges()}}disableSelection(e){e.forEach(t=>{t.setAttribute("unselectable","on"),t.style.mozUserSelect="none",this._bindingEventService.bind(t,"selectstart",()=>!1)})}getPubSubService(){return this._pubSubService}getCellFromPoint(e,t){let n=this.getRowFromPosition(t),o=0,r=0;for(let i=0;i<this.columns.length&&r<=e;i++)this.columns[i]&&(r+=this.columns[i].width,o++);return o-=1,n<-1&&(n=-1),{row:n,cell:o}}getPluginByName(e){for(let t=this.plugins.length-1;t>=0;t--)if(this.plugins[t]?.pluginName===e)return this.plugins[t]}getContainerNode(){return this._container}getCellHeight(e,t){let n=this._options.rowHeight||0;if(t>1){let o=e+t-1;n=this.getRowBottom(o)-this.getRowTop(e)}else{let o=this.getRowHeight();o!==n-this.cellHeightDiff&&(n=o)}return n-=this.cellHeightDiff,Math.ceil(n)}setDifference(e,t){return new Set(Array.from(e).filter(n=>!t.has(n)))}getCellNodeBox(e,t){if(!this.cellExists(e,t))return null;let n=this.getFrozenRowOffset(e),o=this.getRowTop(e)-n,r=o+this._options.rowHeight-1,i=0;for(let l=0;l<t;l++)!this.columns[l]||this.columns[l].hidden||(i+=this.columns[l].width||0,this._options.frozenColumn===l&&(i=0));let a=i+(this.columns[t]?.width||0);return{top:o,left:i,bottom:r,right:a}}absBox(e){let t={top:e.offsetTop,left:e.offsetLeft,bottom:0,right:0,width:e.offsetWidth,height:e.offsetWidth,visible:!0};t.bottom=t.top+t.height,t.right=t.left+t.width;let n=e.offsetParent;for(;(e=e.parentNode)!==document.body&&!(!e||!e.parentNode);){let o=getComputedStyle(e);t.visible&&e.scrollHeight!==e.offsetHeight&&o.overflowY!=="visible"&&(t.visible=t.bottom>e.scrollTop&&t.top<e.scrollTop+e.clientHeight),t.visible&&e.scrollWidth!==e.offsetWidth&&o.overflowX!=="visible"&&(t.visible=t.right>e.scrollLeft&&t.left<e.scrollLeft+e.clientWidth),t.left-=e.scrollLeft,t.top-=e.scrollTop,e===n&&(t.left+=e.offsetLeft,t.top+=e.offsetTop,n=e.offsetParent),t.bottom=t.top+t.height,t.right=t.left+t.width}return t}getActiveCellPosition(){return this.absBox(this.activeCellNode)}getGridPosition(){return this.absBox(this._container)}getCellEditor(){return this.currentEditor}getActiveCell(){return this.activeCellNode?{row:this.activeRow,cell:this.activeCell}:null}getActiveCellNode(){return this.activeCellNode}getTextSelection(){let e=null;if(window.getSelection){let t=window.getSelection();(t?.rangeCount??0)>0&&(e=t.getRangeAt(0))}return e}setTextSelection(e){if(window.getSelection&&e){let t=window.getSelection();t&&(t.removeAllRanges(),t.addRange(e))}}sanitizeHtmlString(e,t){if(!this._options.sanitizer||typeof e!="string")return e;let n=this._options.sanitizer(e);return!t&&this._options.logSanitizedHtml&&this.logMessageCount<=this.logMessageMaxCount&&n!==e&&(console.log(`sanitizer altered html: ${e} --> ${n}`),this.logMessageCount===this.logMessageMaxCount&&console.log(`sanitizer: silencing messages after first ${this.logMessageMaxCount}`),this.logMessageCount++),n}getRowspan(e,t){let n=1,o=this.getItemMetadaWhenExists(e);return o?.columns&&Object.keys(o.columns).forEach(r=>{let i=Number(r);if(i===t){let a=o.columns[i];n=Number(a?.rowspan||1)}}),n}findFocusableRow(e,t,n){let o=e,r=this._colsWithRowSpanCache[t]||new Set,i=!1;return Array.from(r).forEach(a=>{let[l,d]=a.split(":").map(Number);!i&&e>=l&&e<=d&&(o=n==="up"?l:d,this.canCellBeActive(o,t)&&(i=!0))}),o<0&&(o=0),o}findFirstFocusableCell(e){let t=0,n=e,o=-1;for(;t<this.columns.length;){let r=this.getParentRowSpanByCell(e,t);if(n=r!==null&&r.start!==e?r.start:e,this.canCellBeActive(n,t)){o=t;break}t+=this.getColspan(n,t)}return{cell:o,row:n}}findLastFocusableCell(e){let t=0,n=e,o=-1;for(;t<this.columns.length;){let r=this.getParentRowSpanByCell(e,t);n=r!==null&&r.start!==e?r.start:e,this.canCellBeActive(n,t)&&(o=t),t+=this.getColspan(n,t)}return{cell:o,row:n}}rowsToRanges(e){let t=[],n=this.columns.length-1;for(let o=0;o<e.length;o++)t.push(new lA(e[o],0,e[o],n));return t}findSpanStartingCell(e,t){let n=this.getParentRowSpanByCell(e,t),o=n!==null&&n.start!==e?n.start:e,r=0,i=0;for(;r<this.columns.length;){if(r+=this.getColspan(o,r),r>t)return r=i,{cell:r,row:o};i=r}return{cell:r,row:o}}gotoRight(e,t,n,o){if(t>=this.columns.length)return null;let r=t+1,i=n;do{let a=this.findSpanStartingCell(n,r);if(i=a.row,r=a.cell,this.canCellBeActive(i,r)&&r>t)break;r+=this.getColspan(i,a.cell)}while(r<this.columns.length);return r<this.columns.length?{row:i,cell:r,posX:r,posY:n}:null}gotoLeft(e,t,n,o){if(t<=0)return null;let r=this.findFirstFocusableCell(e);if(r.cell===null||r.cell>=t)return null;let i,a={row:e,cell:r.cell,posX:r.cell,posY:n};for(;;){if(i=this.gotoRight(a.row,a.cell,a.posY,a.posX),!i)return null;if(i.cell>=t){let l=this.findFocusableRow(n,a.cell,"up");return l!==a.row&&(a.row=l),a}a=i}}gotoDown(e,t,n,o){let r,i=this.getDataLengthIncludingAddNew();do for(e+=this.getRowspan(e,o),r=t=0;t<=o;)r=t,t+=this.getColspan(e,t);while(e<=i&&!this.canCellBeActive(e,r));return e<=i?{row:e,cell:r,posX:o,posY:e}:null}gotoUp(e,t,n,o){let r;if(e<=0)return null;do for(e=this.findFocusableRow(e-1,o,"up"),r=t=0;t<=o;)r=t,t+=this.getColspan(e,t);while(e>=0&&!this.canCellBeActive(e,r));return t<=this.columns.length?{row:e,cell:r,posX:o,posY:e}:null}gotoNext(e,t,n,o){if(!L.isDefined(e)&&!L.isDefined(t)&&(e=t=n=o=0,this.canCellBeActive(e,t)))return{row:e,cell:t,posX:t,posY:n};let r=this.gotoRight(e,t,n,o);if(!r){let i;for(;!r&&++n<this.getDataLength()+(this._options.enableAddRow?1:0);)i=this.findFirstFocusableCell(n),i.cell!==null&&(e=this.getParentRowSpanByCell(n,i.cell)?.start??n,r={row:e,cell:i.cell,posX:i.cell,posY:n})}return r}gotoPrev(e,t,n,o){if(!L.isDefined(e)&&!L.isDefined(t)&&(e=n=this.getDataLengthIncludingAddNew()-1,t=o=this.columns.length-1,this.canCellBeActive(e,t)))return{row:e,cell:t,posX:t,posY:n};let r=this.gotoLeft(e,t,n,o);if(!r){let i;for(;!r&&--n>=0;)i=this.findLastFocusableCell(n),i.cell>-1&&(e=this.getParentRowSpanByCell(n,i.cell)?.start??n,r={row:e,cell:i.cell,posX:i.cell,posY:n})}return r}gotoRowStart(e,t,n,o){let r=this.findFirstFocusableCell(e);return r.cell===null?null:{row:r.row,cell:r.cell,posX:r.cell,posY:e}}gotoRowEnd(e,t,n,o){let r=this.findLastFocusableCell(e);return r.cell===-1?null:{row:r.row,cell:r.cell,posX:r.cell,posY:e}}navigateRight(){return this.navigate("right")}navigateLeft(){return this.navigate("left")}navigateDown(){return this.navigate("down")}navigateUp(){return this.navigate("up")}navigateNext(){return this.navigate("next")}navigatePrev(){return this.navigate("prev")}navigateRowStart(){return this.navigate("home")}navigateRowEnd(){return this.navigate("end")}navigateTopStart(){return this.navigateToRow(0),this.navigate("home")}navigateBottomEnd(){return this.navigateBottom(),this.navigate("end")}navigate(e){if(!this._options.enableCellNavigation||!this.activeCellNode&&e!=="prev"&&e!=="next")return!1;if(!this.getEditorLock()?.commitCurrentEdit())return!0;this.setFocus(),this.unsetActiveCell();let t={up:-1,down:1,left:-1,right:1,prev:-1,next:1,home:-1,end:1};this.tabbingDirection=t[e];let n={up:this.gotoUp,down:this.gotoDown,left:this.gotoLeft,right:this.gotoRight,prev:this.gotoPrev,next:this.gotoNext,home:this.gotoRowStart,end:this.gotoRowEnd}[e].call(this,this.activeRow,this.activeCell,this.activePosY,this.activePosX);return this.navigateToPos(n)}navigateToPos(e){if(e){if(this.hasFrozenRows&&this._options.frozenBottom&&e.row===this.getDataLength())return;let t=e.row===this.getDataLength();return(!this._options.frozenBottom&&e.row>=this.actualFrozenRow||this._options.frozenBottom&&e.row<this.actualFrozenRow)&&this.scrollCellIntoView(e.row,e.cell,!t&&this._options.emulatePagingWhenScrolling),this.setActiveCellInternal(this.getCellNode(e.row,e.cell)),this.activePosX=e.posX,this.activePosY=e.posY,!0}else return this.setActiveCellInternal(this.getCellNode(this.activeRow,this.activeCell)),!1}getCellNode(e,t){if(this.rowsCache[e]){this.ensureCellNodesInRowsCache(e);try{return this.rowsCache[e].cellNodesByColumnIdx.length>t?this.rowsCache[e].cellNodesByColumnIdx[t]:null}catch{return this.rowsCache[e].cellNodesByColumnIdx[t]}}return null}setActiveCell(e,t,n,o,r){this.initialized&&(e>this.getDataLength()||e<0||t>=this.columns.length||t<0||this._options.enableCellNavigation&&(this.scrollCellIntoView(e,t,!1),this.setActiveCellInternal(this.getCellNode(e,t),n,o,r)))}setActiveRow(e,t,n){this.initialized&&(e>this.getDataLength()||e<0||(t??0)>=this.columns.length||(t??0)<0||(this.activeRow=e,n||this.scrollCellIntoView(e,t||0,!1)))}canCellBeActive(e,t){if(!this._options.enableCellNavigation||e>=this.getDataLengthIncludingAddNew()||e<0||t>=this.columns.length||t<0||!this.columns[t]||this.columns[t].hidden||(this.getParentRowSpanByCell(e,t)?.start??e)!==e)return!1;let n=this.getItemMetadaWhenExists(e);if(n?.focusable!==void 0)return!!n.focusable;let o=n?.columns;return o?.[this.columns[t].id]?.focusable!==void 0?!!o[this.columns[t].id].focusable:o?.[t]?.focusable!==void 0?!!o[t].focusable:!!this.columns[t].focusable}canCellBeSelected(e,t){if(e>=this.getDataLength()||e<0||t>=this.columns.length||t<0||!this.columns[t]||this.columns[t].hidden)return!1;let n=this.getItemMetadaWhenExists(e);if(n?.selectable!==void 0)return!!n.selectable;let o=n?.columns&&(n.columns[this.columns[t].id]||n.columns[t]);return o?.selectable!==void 0?!!o.selectable:!!this.columns[t].selectable}gotoCell(e,t,n,o){if(!this.initialized||!this.canCellBeActive(e,t)||!this.getEditorLock()?.commitCurrentEdit())return;this.scrollCellIntoView(e,t,!1);let r=this.getCellNode(e,t),i=this.columns[t],a=!!(this._options.editable&&i?.editor&&this._options.suppressActiveCellChangeOnEdit);this.setActiveCellInternal(r,n||e===this.getDataLength()||this._options.autoEdit,null,a,o),this.currentEditor||this.setFocus()}};/**
|
|
273
|
+
`+new Error().stack),n=!1}return t.apply(this,arguments)},t)}var Zp={};function Ey(e,t){_e.deprecationHandler!=null&&_e.deprecationHandler(e,t),Zp[e]||(Ty(t),Zp[e]=!0)}_e.suppressDeprecationWarnings=!1;_e.deprecationHandler=null;function Mo(e){return typeof Function<"u"&&e instanceof Function||Object.prototype.toString.call(e)==="[object Function]"}function fD(e){var t,n;for(n in e)ut(e,n)&&(t=e[n],Mo(t)?this[n]=t:this["_"+n]=t);this._config=e,this._dayOfMonthOrdinalParseLenient=new RegExp((this._dayOfMonthOrdinalParse.source||this._ordinalParse.source)+"|"+/\d{1,2}/.source)}function qd(e,t){var n=dr({},e),o;for(o in t)ut(t,o)&&(Fr(e[o])&&Fr(t[o])?(n[o]={},dr(n[o],e[o]),dr(n[o],t[o])):t[o]!=null?n[o]=t[o]:delete n[o]);for(o in e)ut(e,o)&&!ut(t,o)&&Fr(e[o])&&(n[o]=dr({},n[o]));return n}function Uu(e){e!=null&&this.set(e)}var Gd;Object.keys?Gd=Object.keys:Gd=function(e){var t,n=[];for(t in e)ut(e,t)&&n.push(t);return n};var pD={sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"};function mD(e,t,n){var o=this._calendar[e]||this._calendar.sameElse;return Mo(o)?o.call(t,n):o}function Eo(e,t,n){var o=""+Math.abs(e),r=t-o.length,i=e>=0;return(i?n?"+":"":"-")+Math.pow(10,Math.max(0,r)).toString().substr(1)+o}var qu=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,Ha=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,cd={},bs={};function Le(e,t,n,o){var r=o;typeof o=="string"&&(r=function(){return this[o]()}),e&&(bs[e]=r),t&&(bs[t[0]]=function(){return Eo(r.apply(this,arguments),t[1],t[2])}),n&&(bs[n]=function(){return this.localeData().ordinal(r.apply(this,arguments),e)})}function gD(e){return e.match(/\[[\s\S]/)?e.replace(/^\[|\]$/g,""):e.replace(/\\/g,"")}function yD(e){var t=e.match(qu),n,o;for(n=0,o=t.length;n<o;n++)bs[t[n]]?t[n]=bs[t[n]]:t[n]=gD(t[n]);return function(r){var i="",a;for(a=0;a<o;a++)i+=Mo(t[a])?t[a].call(r,e):t[a];return i}}function rl(e,t){return e.isValid()?(t=Py(t,e.localeData()),cd[t]=cd[t]||yD(t),cd[t](e)):e.localeData().invalidDate()}function Py(e,t){var n=5;function o(r){return t.longDateFormat(r)||r}for(Ha.lastIndex=0;n>=0&&Ha.test(e);)e=e.replace(Ha,o),Ha.lastIndex=0,n-=1;return e}var vD={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"};function bD(e){var t=this._longDateFormat[e],n=this._longDateFormat[e.toUpperCase()];return t||!n?t:(this._longDateFormat[e]=n.match(qu).map(function(o){return o==="MMMM"||o==="MM"||o==="DD"||o==="dddd"?o.slice(1):o}).join(""),this._longDateFormat[e])}var wD="Invalid date";function CD(){return this._invalidDate}var SD="%d",_D=/\d{1,2}/;function xD(e){return this._ordinal.replace("%d",e)}var RD={future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",w:"a week",ww:"%d weeks",M:"a month",MM:"%d months",y:"a year",yy:"%d years"};function kD(e,t,n,o){var r=this._relativeTime[n];return Mo(r)?r(e,t,n,o):r.replace(/%d/i,e)}function TD(e,t){var n=this._relativeTime[e>0?"future":"past"];return Mo(n)?n(t):n.replace(/%s/i,t)}var Qp={D:"date",dates:"date",date:"date",d:"day",days:"day",day:"day",e:"weekday",weekdays:"weekday",weekday:"weekday",E:"isoWeekday",isoweekdays:"isoWeekday",isoweekday:"isoWeekday",DDD:"dayOfYear",dayofyears:"dayOfYear",dayofyear:"dayOfYear",h:"hour",hours:"hour",hour:"hour",ms:"millisecond",milliseconds:"millisecond",millisecond:"millisecond",m:"minute",minutes:"minute",minute:"minute",M:"month",months:"month",month:"month",Q:"quarter",quarters:"quarter",quarter:"quarter",s:"second",seconds:"second",second:"second",gg:"weekYear",weekyears:"weekYear",weekyear:"weekYear",GG:"isoWeekYear",isoweekyears:"isoWeekYear",isoweekyear:"isoWeekYear",w:"week",weeks:"week",week:"week",W:"isoWeek",isoweeks:"isoWeek",isoweek:"isoWeek",y:"year",years:"year",year:"year"};function eo(e){return typeof e=="string"?Qp[e]||Qp[e.toLowerCase()]:void 0}function Gu(e){var t={},n,o;for(o in e)ut(e,o)&&(n=eo(o),n&&(t[n]=e[o]));return t}var ED={date:9,day:11,weekday:11,isoWeekday:11,dayOfYear:4,hour:13,millisecond:16,minute:14,month:8,quarter:7,second:15,weekYear:1,isoWeekYear:1,week:5,isoWeek:5,year:1};function PD(e){var t=[],n;for(n in e)ut(e,n)&&t.push({unit:n,priority:ED[n]});return t.sort(function(o,r){return o.priority-r.priority}),t}var Dy=/\d/,$n=/\d\d/,Oy=/\d{3}/,Ku=/\d{4}/,oc=/[+-]?\d{6}/,It=/\d\d?/,My=/\d\d\d\d?/,Iy=/\d\d\d\d\d\d?/,rc=/\d{1,3}/,Xu=/\d{1,4}/,sc=/[+-]?\d{1,6}/,js=/\d+/,ic=/[+-]?\d+/,DD=/Z|[+-]\d\d:?\d\d/gi,ac=/Z|[+-]\d\d(?::?\d\d)?/gi,OD=/[+-]?\d+(\.\d{1,3})?/,pa=/[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i,Bs=/^[1-9]\d?/,Zu=/^([1-9]\d|\d)/,wl;wl={};function Ee(e,t,n){wl[e]=Mo(t)?t:function(o,r){return o&&n?n:t}}function MD(e,t){return ut(wl,e)?wl[e](t._strict,t._locale):new RegExp(ID(e))}function ID(e){return qo(e.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(t,n,o,r,i){return n||o||r||i}))}function qo(e){return e.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function Un(e){return e<0?Math.ceil(e)||0:Math.floor(e)}function Qe(e){var t=+e,n=0;return t!==0&&isFinite(t)&&(n=Un(t)),n}var Kd={};function Tt(e,t){var n,o=t,r;for(typeof e=="string"&&(e=[e]),Jo(t)&&(o=function(i,a){a[t]=Qe(i)}),r=e.length,n=0;n<r;n++)Kd[e[n]]=o}function ma(e,t){Tt(e,function(n,o,r,i){r._w=r._w||{},t(n,r._w,r,i)})}function ND(e,t,n){t!=null&&ut(Kd,e)&&Kd[e](t,n._a,n,e)}function lc(e){return e%4===0&&e%100!==0||e%400===0}var yn=0,zo=1,So=2,tn=3,ro=4,Yo=5,Ir=6,AD=7,FD=8;Le("Y",0,0,function(){var e=this.year();return e<=9999?Eo(e,4):"+"+e});Le(0,["YY",2],0,function(){return this.year()%100});Le(0,["YYYY",4],0,"year");Le(0,["YYYYY",5],0,"year");Le(0,["YYYYYY",6,!0],0,"year");Ee("Y",ic);Ee("YY",It,$n);Ee("YYYY",Xu,Ku);Ee("YYYYY",sc,oc);Ee("YYYYYY",sc,oc);Tt(["YYYYY","YYYYYY"],yn);Tt("YYYY",function(e,t){t[yn]=e.length===2?_e.parseTwoDigitYear(e):Qe(e)});Tt("YY",function(e,t){t[yn]=_e.parseTwoDigitYear(e)});Tt("Y",function(e,t){t[yn]=parseInt(e,10)});function Ti(e){return lc(e)?366:365}_e.parseTwoDigitYear=function(e){return Qe(e)+(Qe(e)>68?1900:2e3)};var Ny=Ws("FullYear",!0);function LD(){return lc(this.year())}function Ws(e,t){return function(n){return n!=null?(Ay(this,e,n),_e.updateOffset(this,t),this):Yi(this,e)}}function Yi(e,t){if(!e.isValid())return NaN;var n=e._d,o=e._isUTC;switch(t){case"Milliseconds":return o?n.getUTCMilliseconds():n.getMilliseconds();case"Seconds":return o?n.getUTCSeconds():n.getSeconds();case"Minutes":return o?n.getUTCMinutes():n.getMinutes();case"Hours":return o?n.getUTCHours():n.getHours();case"Date":return o?n.getUTCDate():n.getDate();case"Day":return o?n.getUTCDay():n.getDay();case"Month":return o?n.getUTCMonth():n.getMonth();case"FullYear":return o?n.getUTCFullYear():n.getFullYear();default:return NaN}}function Ay(e,t,n){var o,r,i,a,l;if(!(!e.isValid()||isNaN(n))){switch(o=e._d,r=e._isUTC,t){case"Milliseconds":return void(r?o.setUTCMilliseconds(n):o.setMilliseconds(n));case"Seconds":return void(r?o.setUTCSeconds(n):o.setSeconds(n));case"Minutes":return void(r?o.setUTCMinutes(n):o.setMinutes(n));case"Hours":return void(r?o.setUTCHours(n):o.setHours(n));case"Date":return void(r?o.setUTCDate(n):o.setDate(n));case"FullYear":break;default:return}i=n,a=e.month(),l=e.date(),l=l===29&&a===1&&!lc(i)?28:l,r?o.setUTCFullYear(i,a,l):o.setFullYear(i,a,l)}}function $D(e){return e=eo(e),Mo(this[e])?this[e]():this}function VD(e,t){if(typeof e=="object"){e=Gu(e);var n=PD(e),o,r=n.length;for(o=0;o<r;o++)this[n[o].unit](e[n[o].unit])}else if(e=eo(e),Mo(this[e]))return this[e](t);return this}function jD(e,t){return(e%t+t)%t}var qt;Array.prototype.indexOf?qt=Array.prototype.indexOf:qt=function(e){var t;for(t=0;t<this.length;++t)if(this[t]===e)return t;return-1};function Qu(e,t){if(isNaN(e)||isNaN(t))return NaN;var n=jD(t,12);return e+=(t-n)/12,n===1?lc(e)?29:28:31-n%7%2}Le("M",["MM",2],"Mo",function(){return this.month()+1});Le("MMM",0,0,function(e){return this.localeData().monthsShort(this,e)});Le("MMMM",0,0,function(e){return this.localeData().months(this,e)});Ee("M",It,Bs);Ee("MM",It,$n);Ee("MMM",function(e,t){return t.monthsShortRegex(e)});Ee("MMMM",function(e,t){return t.monthsRegex(e)});Tt(["M","MM"],function(e,t){t[zo]=Qe(e)-1});Tt(["MMM","MMMM"],function(e,t,n,o){var r=n._locale.monthsParse(e,o,n._strict);r!=null?t[zo]=r:ze(n).invalidMonth=e});var BD="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),Fy="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),Ly=/D[oD]?(\[[^\[\]]*\]|\s)+MMMM?/,WD=pa,HD=pa;function zD(e,t){return e?io(this._months)?this._months[e.month()]:this._months[(this._months.isFormat||Ly).test(t)?"format":"standalone"][e.month()]:io(this._months)?this._months:this._months.standalone}function YD(e,t){return e?io(this._monthsShort)?this._monthsShort[e.month()]:this._monthsShort[Ly.test(t)?"format":"standalone"][e.month()]:io(this._monthsShort)?this._monthsShort:this._monthsShort.standalone}function UD(e,t,n){var o,r,i,a=e.toLocaleLowerCase();if(!this._monthsParse)for(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[],o=0;o<12;++o)i=Oo([2e3,o]),this._shortMonthsParse[o]=this.monthsShort(i,"").toLocaleLowerCase(),this._longMonthsParse[o]=this.months(i,"").toLocaleLowerCase();return n?t==="MMM"?(r=qt.call(this._shortMonthsParse,a),r!==-1?r:null):(r=qt.call(this._longMonthsParse,a),r!==-1?r:null):t==="MMM"?(r=qt.call(this._shortMonthsParse,a),r!==-1?r:(r=qt.call(this._longMonthsParse,a),r!==-1?r:null)):(r=qt.call(this._longMonthsParse,a),r!==-1?r:(r=qt.call(this._shortMonthsParse,a),r!==-1?r:null))}function qD(e,t,n){var o,r,i;if(this._monthsParseExact)return UD.call(this,e,t,n);for(this._monthsParse||(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[]),o=0;o<12;o++){if(r=Oo([2e3,o]),n&&!this._longMonthsParse[o]&&(this._longMonthsParse[o]=new RegExp("^"+this.months(r,"").replace(".","")+"$","i"),this._shortMonthsParse[o]=new RegExp("^"+this.monthsShort(r,"").replace(".","")+"$","i")),!n&&!this._monthsParse[o]&&(i="^"+this.months(r,"")+"|^"+this.monthsShort(r,""),this._monthsParse[o]=new RegExp(i.replace(".",""),"i")),n&&t==="MMMM"&&this._longMonthsParse[o].test(e))return o;if(n&&t==="MMM"&&this._shortMonthsParse[o].test(e))return o;if(!n&&this._monthsParse[o].test(e))return o}}function $y(e,t){if(!e.isValid())return e;if(typeof t=="string"){if(/^\d+$/.test(t))t=Qe(t);else if(t=e.localeData().monthsParse(t),!Jo(t))return e}var n=t,o=e.date();return o=o<29?o:Math.min(o,Qu(e.year(),n)),e._isUTC?e._d.setUTCMonth(n,o):e._d.setMonth(n,o),e}function Vy(e){return e!=null?($y(this,e),_e.updateOffset(this,!0),this):Yi(this,"Month")}function GD(){return Qu(this.year(),this.month())}function KD(e){return this._monthsParseExact?(ut(this,"_monthsRegex")||jy.call(this),e?this._monthsShortStrictRegex:this._monthsShortRegex):(ut(this,"_monthsShortRegex")||(this._monthsShortRegex=WD),this._monthsShortStrictRegex&&e?this._monthsShortStrictRegex:this._monthsShortRegex)}function XD(e){return this._monthsParseExact?(ut(this,"_monthsRegex")||jy.call(this),e?this._monthsStrictRegex:this._monthsRegex):(ut(this,"_monthsRegex")||(this._monthsRegex=HD),this._monthsStrictRegex&&e?this._monthsStrictRegex:this._monthsRegex)}function jy(){function e(d,u){return u.length-d.length}var t=[],n=[],o=[],r,i,a,l;for(r=0;r<12;r++)i=Oo([2e3,r]),a=qo(this.monthsShort(i,"")),l=qo(this.months(i,"")),t.push(a),n.push(l),o.push(l),o.push(a);t.sort(e),n.sort(e),o.sort(e),this._monthsRegex=new RegExp("^("+o.join("|")+")","i"),this._monthsShortRegex=this._monthsRegex,this._monthsStrictRegex=new RegExp("^("+n.join("|")+")","i"),this._monthsShortStrictRegex=new RegExp("^("+t.join("|")+")","i")}function ZD(e,t,n,o,r,i,a){var l;return e<100&&e>=0?(l=new Date(e+400,t,n,o,r,i,a),isFinite(l.getFullYear())&&l.setFullYear(e)):l=new Date(e,t,n,o,r,i,a),l}function Ui(e){var t,n;return e<100&&e>=0?(n=Array.prototype.slice.call(arguments),n[0]=e+400,t=new Date(Date.UTC.apply(null,n)),isFinite(t.getUTCFullYear())&&t.setUTCFullYear(e)):t=new Date(Date.UTC.apply(null,arguments)),t}function Cl(e,t,n){var o=7+t-n,r=(7+Ui(e,0,o).getUTCDay()-t)%7;return-r+o-1}function By(e,t,n,o,r){var i=(7+n-o)%7,a=Cl(e,o,r),l=1+7*(t-1)+i+a,d,u;return l<=0?(d=e-1,u=Ti(d)+l):l>Ti(e)?(d=e+1,u=l-Ti(e)):(d=e,u=l),{year:d,dayOfYear:u}}function qi(e,t,n){var o=Cl(e.year(),t,n),r=Math.floor((e.dayOfYear()-o-1)/7)+1,i,a;return r<1?(a=e.year()-1,i=r+Go(a,t,n)):r>Go(e.year(),t,n)?(i=r-Go(e.year(),t,n),a=e.year()+1):(a=e.year(),i=r),{week:i,year:a}}function Go(e,t,n){var o=Cl(e,t,n),r=Cl(e+1,t,n);return(Ti(e)-o+r)/7}Le("w",["ww",2],"wo","week");Le("W",["WW",2],"Wo","isoWeek");Ee("w",It,Bs);Ee("ww",It,$n);Ee("W",It,Bs);Ee("WW",It,$n);ma(["w","ww","W","WW"],function(e,t,n,o){t[o.substr(0,1)]=Qe(e)});function QD(e){return qi(e,this._week.dow,this._week.doy).week}var JD={dow:0,doy:6};function eO(){return this._week.dow}function tO(){return this._week.doy}function nO(e){var t=this.localeData().week(this);return e==null?t:this.add((e-t)*7,"d")}function oO(e){var t=qi(this,1,4).week;return e==null?t:this.add((e-t)*7,"d")}Le("d",0,"do","day");Le("dd",0,0,function(e){return this.localeData().weekdaysMin(this,e)});Le("ddd",0,0,function(e){return this.localeData().weekdaysShort(this,e)});Le("dddd",0,0,function(e){return this.localeData().weekdays(this,e)});Le("e",0,0,"weekday");Le("E",0,0,"isoWeekday");Ee("d",It);Ee("e",It);Ee("E",It);Ee("dd",function(e,t){return t.weekdaysMinRegex(e)});Ee("ddd",function(e,t){return t.weekdaysShortRegex(e)});Ee("dddd",function(e,t){return t.weekdaysRegex(e)});ma(["dd","ddd","dddd"],function(e,t,n,o){var r=n._locale.weekdaysParse(e,o,n._strict);r!=null?t.d=r:ze(n).invalidWeekday=e});ma(["d","e","E"],function(e,t,n,o){t[o]=Qe(e)});function rO(e,t){return typeof e!="string"?e:isNaN(e)?(e=t.weekdaysParse(e),typeof e=="number"?e:null):parseInt(e,10)}function sO(e,t){return typeof e=="string"?t.weekdaysParse(e)%7||7:isNaN(e)?null:e}function Ju(e,t){return e.slice(t,7).concat(e.slice(0,t))}var iO="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),Wy="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),aO="Su_Mo_Tu_We_Th_Fr_Sa".split("_"),lO=pa,cO=pa,dO=pa;function uO(e,t){var n=io(this._weekdays)?this._weekdays:this._weekdays[e&&e!==!0&&this._weekdays.isFormat.test(t)?"format":"standalone"];return e===!0?Ju(n,this._week.dow):e?n[e.day()]:n}function hO(e){return e===!0?Ju(this._weekdaysShort,this._week.dow):e?this._weekdaysShort[e.day()]:this._weekdaysShort}function fO(e){return e===!0?Ju(this._weekdaysMin,this._week.dow):e?this._weekdaysMin[e.day()]:this._weekdaysMin}function pO(e,t,n){var o,r,i,a=e.toLocaleLowerCase();if(!this._weekdaysParse)for(this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[],o=0;o<7;++o)i=Oo([2e3,1]).day(o),this._minWeekdaysParse[o]=this.weekdaysMin(i,"").toLocaleLowerCase(),this._shortWeekdaysParse[o]=this.weekdaysShort(i,"").toLocaleLowerCase(),this._weekdaysParse[o]=this.weekdays(i,"").toLocaleLowerCase();return n?t==="dddd"?(r=qt.call(this._weekdaysParse,a),r!==-1?r:null):t==="ddd"?(r=qt.call(this._shortWeekdaysParse,a),r!==-1?r:null):(r=qt.call(this._minWeekdaysParse,a),r!==-1?r:null):t==="dddd"?(r=qt.call(this._weekdaysParse,a),r!==-1||(r=qt.call(this._shortWeekdaysParse,a),r!==-1)?r:(r=qt.call(this._minWeekdaysParse,a),r!==-1?r:null)):t==="ddd"?(r=qt.call(this._shortWeekdaysParse,a),r!==-1||(r=qt.call(this._weekdaysParse,a),r!==-1)?r:(r=qt.call(this._minWeekdaysParse,a),r!==-1?r:null)):(r=qt.call(this._minWeekdaysParse,a),r!==-1||(r=qt.call(this._weekdaysParse,a),r!==-1)?r:(r=qt.call(this._shortWeekdaysParse,a),r!==-1?r:null))}function mO(e,t,n){var o,r,i;if(this._weekdaysParseExact)return pO.call(this,e,t,n);for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),o=0;o<7;o++){if(r=Oo([2e3,1]).day(o),n&&!this._fullWeekdaysParse[o]&&(this._fullWeekdaysParse[o]=new RegExp("^"+this.weekdays(r,"").replace(".","\\.?")+"$","i"),this._shortWeekdaysParse[o]=new RegExp("^"+this.weekdaysShort(r,"").replace(".","\\.?")+"$","i"),this._minWeekdaysParse[o]=new RegExp("^"+this.weekdaysMin(r,"").replace(".","\\.?")+"$","i")),this._weekdaysParse[o]||(i="^"+this.weekdays(r,"")+"|^"+this.weekdaysShort(r,"")+"|^"+this.weekdaysMin(r,""),this._weekdaysParse[o]=new RegExp(i.replace(".",""),"i")),n&&t==="dddd"&&this._fullWeekdaysParse[o].test(e))return o;if(n&&t==="ddd"&&this._shortWeekdaysParse[o].test(e))return o;if(n&&t==="dd"&&this._minWeekdaysParse[o].test(e))return o;if(!n&&this._weekdaysParse[o].test(e))return o}}function gO(e){if(!this.isValid())return e!=null?this:NaN;var t=Yi(this,"Day");return e!=null?(e=rO(e,this.localeData()),this.add(e-t,"d")):t}function yO(e){if(!this.isValid())return e!=null?this:NaN;var t=(this.day()+7-this.localeData()._week.dow)%7;return e==null?t:this.add(e-t,"d")}function vO(e){if(!this.isValid())return e!=null?this:NaN;if(e!=null){var t=sO(e,this.localeData());return this.day(this.day()%7?t:t-7)}else return this.day()||7}function bO(e){return this._weekdaysParseExact?(ut(this,"_weekdaysRegex")||eh.call(this),e?this._weekdaysStrictRegex:this._weekdaysRegex):(ut(this,"_weekdaysRegex")||(this._weekdaysRegex=lO),this._weekdaysStrictRegex&&e?this._weekdaysStrictRegex:this._weekdaysRegex)}function wO(e){return this._weekdaysParseExact?(ut(this,"_weekdaysRegex")||eh.call(this),e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex):(ut(this,"_weekdaysShortRegex")||(this._weekdaysShortRegex=cO),this._weekdaysShortStrictRegex&&e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex)}function CO(e){return this._weekdaysParseExact?(ut(this,"_weekdaysRegex")||eh.call(this),e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex):(ut(this,"_weekdaysMinRegex")||(this._weekdaysMinRegex=dO),this._weekdaysMinStrictRegex&&e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex)}function eh(){function e(f,p){return p.length-f.length}var t=[],n=[],o=[],r=[],i,a,l,d,u;for(i=0;i<7;i++)a=Oo([2e3,1]).day(i),l=qo(this.weekdaysMin(a,"")),d=qo(this.weekdaysShort(a,"")),u=qo(this.weekdays(a,"")),t.push(l),n.push(d),o.push(u),r.push(l),r.push(d),r.push(u);t.sort(e),n.sort(e),o.sort(e),r.sort(e),this._weekdaysRegex=new RegExp("^("+r.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=new RegExp("^("+o.join("|")+")","i"),this._weekdaysShortStrictRegex=new RegExp("^("+n.join("|")+")","i"),this._weekdaysMinStrictRegex=new RegExp("^("+t.join("|")+")","i")}function th(){return this.hours()%12||12}function SO(){return this.hours()||24}Le("H",["HH",2],0,"hour");Le("h",["hh",2],0,th);Le("k",["kk",2],0,SO);Le("hmm",0,0,function(){return""+th.apply(this)+Eo(this.minutes(),2)});Le("hmmss",0,0,function(){return""+th.apply(this)+Eo(this.minutes(),2)+Eo(this.seconds(),2)});Le("Hmm",0,0,function(){return""+this.hours()+Eo(this.minutes(),2)});Le("Hmmss",0,0,function(){return""+this.hours()+Eo(this.minutes(),2)+Eo(this.seconds(),2)});function Hy(e,t){Le(e,0,0,function(){return this.localeData().meridiem(this.hours(),this.minutes(),t)})}Hy("a",!0);Hy("A",!1);function zy(e,t){return t._meridiemParse}Ee("a",zy);Ee("A",zy);Ee("H",It,Zu);Ee("h",It,Bs);Ee("k",It,Bs);Ee("HH",It,$n);Ee("hh",It,$n);Ee("kk",It,$n);Ee("hmm",My);Ee("hmmss",Iy);Ee("Hmm",My);Ee("Hmmss",Iy);Tt(["H","HH"],tn);Tt(["k","kk"],function(e,t,n){var o=Qe(e);t[tn]=o===24?0:o});Tt(["a","A"],function(e,t,n){n._isPm=n._locale.isPM(e),n._meridiem=e});Tt(["h","hh"],function(e,t,n){t[tn]=Qe(e),ze(n).bigHour=!0});Tt("hmm",function(e,t,n){var o=e.length-2;t[tn]=Qe(e.substr(0,o)),t[ro]=Qe(e.substr(o)),ze(n).bigHour=!0});Tt("hmmss",function(e,t,n){var o=e.length-4,r=e.length-2;t[tn]=Qe(e.substr(0,o)),t[ro]=Qe(e.substr(o,2)),t[Yo]=Qe(e.substr(r)),ze(n).bigHour=!0});Tt("Hmm",function(e,t,n){var o=e.length-2;t[tn]=Qe(e.substr(0,o)),t[ro]=Qe(e.substr(o))});Tt("Hmmss",function(e,t,n){var o=e.length-4,r=e.length-2;t[tn]=Qe(e.substr(0,o)),t[ro]=Qe(e.substr(o,2)),t[Yo]=Qe(e.substr(r))});function _O(e){return(e+"").toLowerCase().charAt(0)==="p"}var xO=/[ap]\.?m?\.?/i,RO=Ws("Hours",!0);function kO(e,t,n){return e>11?n?"pm":"PM":n?"am":"AM"}var Yy={calendar:pD,longDateFormat:vD,invalidDate:wD,ordinal:SD,dayOfMonthOrdinalParse:_D,relativeTime:RD,months:BD,monthsShort:Fy,week:JD,weekdays:iO,weekdaysMin:aO,weekdaysShort:Wy,meridiemParse:xO},$t={},ri={},Gi;function TO(e,t){var n,o=Math.min(e.length,t.length);for(n=0;n<o;n+=1)if(e[n]!==t[n])return n;return o}function Jp(e){return e&&e.toLowerCase().replace("_","-")}function EO(e){for(var t=0,n,o,r,i;t<e.length;){for(i=Jp(e[t]).split("-"),n=i.length,o=Jp(e[t+1]),o=o?o.split("-"):null;n>0;){if(r=cc(i.slice(0,n).join("-")),r)return r;if(o&&o.length>=n&&TO(i,o)>=n-1)break;n--}t++}return Gi}function PO(e){return!!(e&&e.match("^[^/\\\\]*$"))}function cc(e){var t=null,n;if($t[e]===void 0&&typeof module<"u"&&module&&module.exports&&PO(e))try{t=Gi._abbr,n=require,n("./locale/"+e),hr(t)}catch{$t[e]=null}return $t[e]}function hr(e,t){var n;return e&&(xn(t)?n=nr(e):n=nh(e,t),n?Gi=n:typeof console<"u"&&console.warn&&console.warn("Locale "+e+" not found. Did you forget to load it?")),Gi._abbr}function nh(e,t){if(t!==null){var n,o=Yy;if(t.abbr=e,$t[e]!=null)Ey("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."),o=$t[e]._config;else if(t.parentLocale!=null)if($t[t.parentLocale]!=null)o=$t[t.parentLocale]._config;else if(n=cc(t.parentLocale),n!=null)o=n._config;else return ri[t.parentLocale]||(ri[t.parentLocale]=[]),ri[t.parentLocale].push({name:e,config:t}),null;return $t[e]=new Uu(qd(o,t)),ri[e]&&ri[e].forEach(function(r){nh(r.name,r.config)}),hr(e),$t[e]}else return delete $t[e],null}function DO(e,t){if(t!=null){var n,o,r=Yy;$t[e]!=null&&$t[e].parentLocale!=null?$t[e].set(qd($t[e]._config,t)):(o=cc(e),o!=null&&(r=o._config),t=qd(r,t),o==null&&(t.abbr=e),n=new Uu(t),n.parentLocale=$t[e],$t[e]=n),hr(e)}else $t[e]!=null&&($t[e].parentLocale!=null?($t[e]=$t[e].parentLocale,e===hr()&&hr(e)):$t[e]!=null&&delete $t[e]);return $t[e]}function nr(e){var t;if(e&&e._locale&&e._locale._abbr&&(e=e._locale._abbr),!e)return Gi;if(!io(e)){if(t=cc(e),t)return t;e=[e]}return EO(e)}function OO(){return Gd($t)}function oh(e){var t,n=e._a;return n&&ze(e).overflow===-2&&(t=n[zo]<0||n[zo]>11?zo:n[So]<1||n[So]>Qu(n[yn],n[zo])?So:n[tn]<0||n[tn]>24||n[tn]===24&&(n[ro]!==0||n[Yo]!==0||n[Ir]!==0)?tn:n[ro]<0||n[ro]>59?ro:n[Yo]<0||n[Yo]>59?Yo:n[Ir]<0||n[Ir]>999?Ir:-1,ze(e)._overflowDayOfYear&&(t<yn||t>So)&&(t=So),ze(e)._overflowWeeks&&t===-1&&(t=AD),ze(e)._overflowWeekday&&t===-1&&(t=FD),ze(e).overflow=t),e}var MO=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,IO=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d|))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,NO=/Z|[+-]\d\d(?::?\d\d)?/,za=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/],["YYYYMM",/\d{6}/,!1],["YYYY",/\d{4}/,!1]],dd=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],AO=/^\/?Date\((-?\d+)/i,FO=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/,LO={UT:0,GMT:0,EDT:-4*60,EST:-5*60,CDT:-5*60,CST:-6*60,MDT:-6*60,MST:-7*60,PDT:-7*60,PST:-8*60};function Uy(e){var t,n,o=e._i,r=MO.exec(o)||IO.exec(o),i,a,l,d,u=za.length,f=dd.length;if(r){for(ze(e).iso=!0,t=0,n=u;t<n;t++)if(za[t][1].exec(r[1])){a=za[t][0],i=za[t][2]!==!1;break}if(a==null){e._isValid=!1;return}if(r[3]){for(t=0,n=f;t<n;t++)if(dd[t][1].exec(r[3])){l=(r[2]||" ")+dd[t][0];break}if(l==null){e._isValid=!1;return}}if(!i&&l!=null){e._isValid=!1;return}if(r[4])if(NO.exec(r[4]))d="Z";else{e._isValid=!1;return}e._f=a+(l||"")+(d||""),sh(e)}else e._isValid=!1}function $O(e,t,n,o,r,i){var a=[VO(e),Fy.indexOf(t),parseInt(n,10),parseInt(o,10),parseInt(r,10)];return i&&a.push(parseInt(i,10)),a}function VO(e){var t=parseInt(e,10);return t<=49?2e3+t:t<=999?1900+t:t}function jO(e){return e.replace(/\([^()]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").replace(/^\s\s*/,"").replace(/\s\s*$/,"")}function BO(e,t,n){if(e){var o=Wy.indexOf(e),r=new Date(t[0],t[1],t[2]).getDay();if(o!==r)return ze(n).weekdayMismatch=!0,n._isValid=!1,!1}return!0}function WO(e,t,n){if(e)return LO[e];if(t)return 0;var o=parseInt(n,10),r=o%100,i=(o-r)/100;return i*60+r}function qy(e){var t=FO.exec(jO(e._i)),n;if(t){if(n=$O(t[4],t[3],t[2],t[5],t[6],t[7]),!BO(t[1],n,e))return;e._a=n,e._tzm=WO(t[8],t[9],t[10]),e._d=Ui.apply(null,e._a),e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),ze(e).rfc2822=!0}else e._isValid=!1}function HO(e){var t=AO.exec(e._i);if(t!==null){e._d=new Date(+t[1]);return}if(Uy(e),e._isValid===!1)delete e._isValid;else return;if(qy(e),e._isValid===!1)delete e._isValid;else return;e._strict?e._isValid=!1:_e.createFromInputFallback(e)}_e.createFromInputFallback=Jn("value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are discouraged. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.",function(e){e._d=new Date(e._i+(e._useUTC?" UTC":""))});function hs(e,t,n){return e??t??n}function zO(e){var t=new Date(_e.now());return e._useUTC?[t.getUTCFullYear(),t.getUTCMonth(),t.getUTCDate()]:[t.getFullYear(),t.getMonth(),t.getDate()]}function rh(e){var t,n,o=[],r,i,a;if(!e._d){for(r=zO(e),e._w&&e._a[So]==null&&e._a[zo]==null&&YO(e),e._dayOfYear!=null&&(a=hs(e._a[yn],r[yn]),(e._dayOfYear>Ti(a)||e._dayOfYear===0)&&(ze(e)._overflowDayOfYear=!0),n=Ui(a,0,e._dayOfYear),e._a[zo]=n.getUTCMonth(),e._a[So]=n.getUTCDate()),t=0;t<3&&e._a[t]==null;++t)e._a[t]=o[t]=r[t];for(;t<7;t++)e._a[t]=o[t]=e._a[t]==null?t===2?1:0:e._a[t];e._a[tn]===24&&e._a[ro]===0&&e._a[Yo]===0&&e._a[Ir]===0&&(e._nextDay=!0,e._a[tn]=0),e._d=(e._useUTC?Ui:ZD).apply(null,o),i=e._useUTC?e._d.getUTCDay():e._d.getDay(),e._tzm!=null&&e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),e._nextDay&&(e._a[tn]=24),e._w&&typeof e._w.d<"u"&&e._w.d!==i&&(ze(e).weekdayMismatch=!0)}}function YO(e){var t,n,o,r,i,a,l,d,u;t=e._w,t.GG!=null||t.W!=null||t.E!=null?(i=1,a=4,n=hs(t.GG,e._a[yn],qi(Ot(),1,4).year),o=hs(t.W,1),r=hs(t.E,1),(r<1||r>7)&&(d=!0)):(i=e._locale._week.dow,a=e._locale._week.doy,u=qi(Ot(),i,a),n=hs(t.gg,e._a[yn],u.year),o=hs(t.w,u.week),t.d!=null?(r=t.d,(r<0||r>6)&&(d=!0)):t.e!=null?(r=t.e+i,(t.e<0||t.e>6)&&(d=!0)):r=i),o<1||o>Go(n,i,a)?ze(e)._overflowWeeks=!0:d!=null?ze(e)._overflowWeekday=!0:(l=By(n,o,r,i,a),e._a[yn]=l.year,e._dayOfYear=l.dayOfYear)}_e.ISO_8601=function(){};_e.RFC_2822=function(){};function sh(e){if(e._f===_e.ISO_8601){Uy(e);return}if(e._f===_e.RFC_2822){qy(e);return}e._a=[],ze(e).empty=!0;var t=""+e._i,n,o,r,i,a,l=t.length,d=0,u,f;for(r=Py(e._f,e._locale).match(qu)||[],f=r.length,n=0;n<f;n++)i=r[n],o=(t.match(MD(i,e))||[])[0],o&&(a=t.substr(0,t.indexOf(o)),a.length>0&&ze(e).unusedInput.push(a),t=t.slice(t.indexOf(o)+o.length),d+=o.length),bs[i]?(o?ze(e).empty=!1:ze(e).unusedTokens.push(i),ND(i,o,e)):e._strict&&!o&&ze(e).unusedTokens.push(i);ze(e).charsLeftOver=l-d,t.length>0&&ze(e).unusedInput.push(t),e._a[tn]<=12&&ze(e).bigHour===!0&&e._a[tn]>0&&(ze(e).bigHour=void 0),ze(e).parsedDateParts=e._a.slice(0),ze(e).meridiem=e._meridiem,e._a[tn]=UO(e._locale,e._a[tn],e._meridiem),u=ze(e).era,u!==null&&(e._a[yn]=e._locale.erasConvertYear(u,e._a[yn])),rh(e),oh(e)}function UO(e,t,n){var o;return n==null?t:e.meridiemHour!=null?e.meridiemHour(t,n):(e.isPM!=null&&(o=e.isPM(n),o&&t<12&&(t+=12),!o&&t===12&&(t=0)),t)}function qO(e){var t,n,o,r,i,a,l=!1,d=e._f.length;if(d===0){ze(e).invalidFormat=!0,e._d=new Date(NaN);return}for(r=0;r<d;r++)i=0,a=!1,t=Yu({},e),e._useUTC!=null&&(t._useUTC=e._useUTC),t._f=e._f[r],sh(t),zu(t)&&(a=!0),i+=ze(t).charsLeftOver,i+=ze(t).unusedTokens.length*10,ze(t).score=i,l?i<o&&(o=i,n=t):(o==null||i<o||a)&&(o=i,n=t,a&&(l=!0));dr(e,n||t)}function GO(e){if(!e._d){var t=Gu(e._i),n=t.day===void 0?t.date:t.day;e._a=ky([t.year,t.month,n,t.hour,t.minute,t.second,t.millisecond],function(o){return o&&parseInt(o,10)}),rh(e)}}function KO(e){var t=new fa(oh(Gy(e)));return t._nextDay&&(t.add(1,"d"),t._nextDay=void 0),t}function Gy(e){var t=e._i,n=e._f;return e._locale=e._locale||nr(e._l),t===null||n===void 0&&t===""?nc({nullInput:!0}):(typeof t=="string"&&(e._i=t=e._locale.preparse(t)),ao(t)?new fa(oh(t)):(ha(t)?e._d=t:io(n)?qO(e):n?sh(e):XO(e),zu(e)||(e._d=null),e))}function XO(e){var t=e._i;xn(t)?e._d=new Date(_e.now()):ha(t)?e._d=new Date(t.valueOf()):typeof t=="string"?HO(e):io(t)?(e._a=ky(t.slice(0),function(n){return parseInt(n,10)}),rh(e)):Fr(t)?GO(e):Jo(t)?e._d=new Date(t):_e.createFromInputFallback(e)}function Ky(e,t,n,o,r){var i={};return(t===!0||t===!1)&&(o=t,t=void 0),(n===!0||n===!1)&&(o=n,n=void 0),(Fr(e)&&Hu(e)||io(e)&&e.length===0)&&(e=void 0),i._isAMomentObject=!0,i._useUTC=i._isUTC=r,i._l=n,i._i=e,i._f=t,i._strict=o,KO(i)}function Ot(e,t,n,o){return Ky(e,t,n,o,!1)}var ZO=Jn("moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var e=Ot.apply(null,arguments);return this.isValid()&&e.isValid()?e<this?this:e:nc()}),QO=Jn("moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var e=Ot.apply(null,arguments);return this.isValid()&&e.isValid()?e>this?this:e:nc()});function Xy(e,t){var n,o;if(t.length===1&&io(t[0])&&(t=t[0]),!t.length)return Ot();for(n=t[0],o=1;o<t.length;++o)(!t[o].isValid()||t[o][e](n))&&(n=t[o]);return n}function JO(){var e=[].slice.call(arguments,0);return Xy("isBefore",e)}function eM(){var e=[].slice.call(arguments,0);return Xy("isAfter",e)}var tM=function(){return Date.now?Date.now():+new Date},si=["year","quarter","month","week","day","hour","minute","second","millisecond"];function nM(e){var t,n=!1,o,r=si.length;for(t in e)if(ut(e,t)&&!(qt.call(si,t)!==-1&&(e[t]==null||!isNaN(e[t]))))return!1;for(o=0;o<r;++o)if(e[si[o]]){if(n)return!1;parseFloat(e[si[o]])!==Qe(e[si[o]])&&(n=!0)}return!0}function oM(){return this._isValid}function rM(){return co(NaN)}function dc(e){var t=Gu(e),n=t.year||0,o=t.quarter||0,r=t.month||0,i=t.week||t.isoWeek||0,a=t.day||0,l=t.hour||0,d=t.minute||0,u=t.second||0,f=t.millisecond||0;this._isValid=nM(t),this._milliseconds=+f+u*1e3+d*6e4+l*1e3*60*60,this._days=+a+i*7,this._months=+r+o*3+n*12,this._data={},this._locale=nr(),this._bubble()}function sl(e){return e instanceof dc}function Xd(e){return e<0?Math.round(-1*e)*-1:Math.round(e)}function sM(e,t,n){var o=Math.min(e.length,t.length),r=Math.abs(e.length-t.length),i=0,a;for(a=0;a<o;a++)Qe(e[a])!==Qe(t[a])&&i++;return i+r}function Zy(e,t){Le(e,0,0,function(){var n=this.utcOffset(),o="+";return n<0&&(n=-n,o="-"),o+Eo(~~(n/60),2)+t+Eo(~~n%60,2)})}Zy("Z",":");Zy("ZZ","");Ee("Z",ac);Ee("ZZ",ac);Tt(["Z","ZZ"],function(e,t,n){n._useUTC=!0,n._tzm=ih(ac,e)});var iM=/([\+\-]|\d\d)/gi;function ih(e,t){var n=(t||"").match(e),o,r,i;return n===null?null:(o=n[n.length-1]||[],r=(o+"").match(iM)||["-",0,0],i=+(r[1]*60)+Qe(r[2]),i===0?0:r[0]==="+"?i:-i)}function ah(e,t){var n,o;return t._isUTC?(n=t.clone(),o=(ao(e)||ha(e)?e.valueOf():Ot(e).valueOf())-n.valueOf(),n._d.setTime(n._d.valueOf()+o),_e.updateOffset(n,!1),n):Ot(e).local()}function Zd(e){return-Math.round(e._d.getTimezoneOffset())}_e.updateOffset=function(){};function aM(e,t,n){var o=this._offset||0,r;if(!this.isValid())return e!=null?this:NaN;if(e!=null){if(typeof e=="string"){if(e=ih(ac,e),e===null)return this}else Math.abs(e)<16&&!n&&(e=e*60);return!this._isUTC&&t&&(r=Zd(this)),this._offset=e,this._isUTC=!0,r!=null&&this.add(r,"m"),o!==e&&(!t||this._changeInProgress?ev(this,co(e-o,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,_e.updateOffset(this,!0),this._changeInProgress=null)),this}else return this._isUTC?o:Zd(this)}function lM(e,t){return e!=null?(typeof e!="string"&&(e=-e),this.utcOffset(e,t),this):-this.utcOffset()}function cM(e){return this.utcOffset(0,e)}function dM(e){return this._isUTC&&(this.utcOffset(0,e),this._isUTC=!1,e&&this.subtract(Zd(this),"m")),this}function uM(){if(this._tzm!=null)this.utcOffset(this._tzm,!1,!0);else if(typeof this._i=="string"){var e=ih(DD,this._i);e!=null?this.utcOffset(e):this.utcOffset(0,!0)}return this}function hM(e){return this.isValid()?(e=e?Ot(e).utcOffset():0,(this.utcOffset()-e)%60===0):!1}function fM(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()}function pM(){if(!xn(this._isDSTShifted))return this._isDSTShifted;var e={},t;return Yu(e,this),e=Gy(e),e._a?(t=e._isUTC?Oo(e._a):Ot(e._a),this._isDSTShifted=this.isValid()&&sM(e._a,t.toArray())>0):this._isDSTShifted=!1,this._isDSTShifted}function mM(){return this.isValid()?!this._isUTC:!1}function gM(){return this.isValid()?this._isUTC:!1}function Qy(){return this.isValid()?this._isUTC&&this._offset===0:!1}var yM=/^(-|\+)?(?:(\d*)[. ])?(\d+):(\d+)(?::(\d+)(\.\d*)?)?$/,vM=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;function co(e,t){var n=e,o=null,r,i,a;return sl(e)?n={ms:e._milliseconds,d:e._days,M:e._months}:Jo(e)||!isNaN(+e)?(n={},t?n[t]=+e:n.milliseconds=+e):(o=yM.exec(e))?(r=o[1]==="-"?-1:1,n={y:0,d:Qe(o[So])*r,h:Qe(o[tn])*r,m:Qe(o[ro])*r,s:Qe(o[Yo])*r,ms:Qe(Xd(o[Ir]*1e3))*r}):(o=vM.exec(e))?(r=o[1]==="-"?-1:1,n={y:xr(o[2],r),M:xr(o[3],r),w:xr(o[4],r),d:xr(o[5],r),h:xr(o[6],r),m:xr(o[7],r),s:xr(o[8],r)}):n==null?n={}:typeof n=="object"&&("from"in n||"to"in n)&&(a=bM(Ot(n.from),Ot(n.to)),n={},n.ms=a.milliseconds,n.M=a.months),i=new dc(n),sl(e)&&ut(e,"_locale")&&(i._locale=e._locale),sl(e)&&ut(e,"_isValid")&&(i._isValid=e._isValid),i}co.fn=dc.prototype;co.invalid=rM;function xr(e,t){var n=e&&parseFloat(e.replace(",","."));return(isNaN(n)?0:n)*t}function em(e,t){var n={};return n.months=t.month()-e.month()+(t.year()-e.year())*12,e.clone().add(n.months,"M").isAfter(t)&&--n.months,n.milliseconds=+t-+e.clone().add(n.months,"M"),n}function bM(e,t){var n;return e.isValid()&&t.isValid()?(t=ah(t,e),e.isBefore(t)?n=em(e,t):(n=em(t,e),n.milliseconds=-n.milliseconds,n.months=-n.months),n):{milliseconds:0,months:0}}function Jy(e,t){return function(n,o){var r,i;return o!==null&&!isNaN(+o)&&(Ey(t,"moment()."+t+"(period, number) is deprecated. Please use moment()."+t+"(number, period). See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info."),i=n,n=o,o=i),r=co(n,o),ev(this,r,e),this}}function ev(e,t,n,o){var r=t._milliseconds,i=Xd(t._days),a=Xd(t._months);e.isValid()&&(o=o??!0,a&&$y(e,Yi(e,"Month")+a*n),i&&Ay(e,"Date",Yi(e,"Date")+i*n),r&&e._d.setTime(e._d.valueOf()+r*n),o&&_e.updateOffset(e,i||a))}var wM=Jy(1,"add"),CM=Jy(-1,"subtract");function tv(e){return typeof e=="string"||e instanceof String}function SM(e){return ao(e)||ha(e)||tv(e)||Jo(e)||xM(e)||_M(e)||e===null||e===void 0}function _M(e){var t=Fr(e)&&!Hu(e),n=!1,o=["years","year","y","months","month","M","days","day","d","dates","date","D","hours","hour","h","minutes","minute","m","seconds","second","s","milliseconds","millisecond","ms"],r,i,a=o.length;for(r=0;r<a;r+=1)i=o[r],n=n||ut(e,i);return t&&n}function xM(e){var t=io(e),n=!1;return t&&(n=e.filter(function(o){return!Jo(o)&&tv(e)}).length===0),t&&n}function RM(e){var t=Fr(e)&&!Hu(e),n=!1,o=["sameDay","nextDay","lastDay","nextWeek","lastWeek","sameElse"],r,i;for(r=0;r<o.length;r+=1)i=o[r],n=n||ut(e,i);return t&&n}function kM(e,t){var n=e.diff(t,"days",!0);return n<-6?"sameElse":n<-1?"lastWeek":n<0?"lastDay":n<1?"sameDay":n<2?"nextDay":n<7?"nextWeek":"sameElse"}function TM(e,t){arguments.length===1&&(arguments[0]?SM(arguments[0])?(e=arguments[0],t=void 0):RM(arguments[0])&&(t=arguments[0],e=void 0):(e=void 0,t=void 0));var n=e||Ot(),o=ah(n,this).startOf("day"),r=_e.calendarFormat(this,o)||"sameElse",i=t&&(Mo(t[r])?t[r].call(this,n):t[r]);return this.format(i||this.localeData().calendar(r,this,Ot(n)))}function EM(){return new fa(this)}function PM(e,t){var n=ao(e)?e:Ot(e);return this.isValid()&&n.isValid()?(t=eo(t)||"millisecond",t==="millisecond"?this.valueOf()>n.valueOf():n.valueOf()<this.clone().startOf(t).valueOf()):!1}function DM(e,t){var n=ao(e)?e:Ot(e);return this.isValid()&&n.isValid()?(t=eo(t)||"millisecond",t==="millisecond"?this.valueOf()<n.valueOf():this.clone().endOf(t).valueOf()<n.valueOf()):!1}function OM(e,t,n,o){var r=ao(e)?e:Ot(e),i=ao(t)?t:Ot(t);return this.isValid()&&r.isValid()&&i.isValid()?(o=o||"()",(o[0]==="("?this.isAfter(r,n):!this.isBefore(r,n))&&(o[1]===")"?this.isBefore(i,n):!this.isAfter(i,n))):!1}function MM(e,t){var n=ao(e)?e:Ot(e),o;return this.isValid()&&n.isValid()?(t=eo(t)||"millisecond",t==="millisecond"?this.valueOf()===n.valueOf():(o=n.valueOf(),this.clone().startOf(t).valueOf()<=o&&o<=this.clone().endOf(t).valueOf())):!1}function IM(e,t){return this.isSame(e,t)||this.isAfter(e,t)}function NM(e,t){return this.isSame(e,t)||this.isBefore(e,t)}function AM(e,t,n){var o,r,i;if(!this.isValid())return NaN;if(o=ah(e,this),!o.isValid())return NaN;switch(r=(o.utcOffset()-this.utcOffset())*6e4,t=eo(t),t){case"year":i=il(this,o)/12;break;case"month":i=il(this,o);break;case"quarter":i=il(this,o)/3;break;case"second":i=(this-o)/1e3;break;case"minute":i=(this-o)/6e4;break;case"hour":i=(this-o)/36e5;break;case"day":i=(this-o-r)/864e5;break;case"week":i=(this-o-r)/6048e5;break;default:i=this-o}return n?i:Un(i)}function il(e,t){if(e.date()<t.date())return-il(t,e);var n=(t.year()-e.year())*12+(t.month()-e.month()),o=e.clone().add(n,"months"),r,i;return t-o<0?(r=e.clone().add(n-1,"months"),i=(t-o)/(o-r)):(r=e.clone().add(n+1,"months"),i=(t-o)/(r-o)),-(n+i)||0}_e.defaultFormat="YYYY-MM-DDTHH:mm:ssZ";_e.defaultFormatUtc="YYYY-MM-DDTHH:mm:ss[Z]";function FM(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")}function LM(e){if(!this.isValid())return null;var t=e!==!0,n=t?this.clone().utc():this;return n.year()<0||n.year()>9999?rl(n,t?"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYYYY-MM-DD[T]HH:mm:ss.SSSZ"):Mo(Date.prototype.toISOString)?t?this.toDate().toISOString():new Date(this.valueOf()+this.utcOffset()*60*1e3).toISOString().replace("Z",rl(n,"Z")):rl(n,t?"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYY-MM-DD[T]HH:mm:ss.SSSZ")}function $M(){if(!this.isValid())return"moment.invalid(/* "+this._i+" */)";var e="moment",t="",n,o,r,i;return this.isLocal()||(e=this.utcOffset()===0?"moment.utc":"moment.parseZone",t="Z"),n="["+e+'("]',o=0<=this.year()&&this.year()<=9999?"YYYY":"YYYYYY",r="-MM-DD[T]HH:mm:ss.SSS",i=t+'[")]',this.format(n+o+r+i)}function VM(e){e||(e=this.isUtc()?_e.defaultFormatUtc:_e.defaultFormat);var t=rl(this,e);return this.localeData().postformat(t)}function jM(e,t){return this.isValid()&&(ao(e)&&e.isValid()||Ot(e).isValid())?co({to:this,from:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()}function BM(e){return this.from(Ot(),e)}function WM(e,t){return this.isValid()&&(ao(e)&&e.isValid()||Ot(e).isValid())?co({from:this,to:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()}function HM(e){return this.to(Ot(),e)}function nv(e){var t;return e===void 0?this._locale._abbr:(t=nr(e),t!=null&&(this._locale=t),this)}var ov=Jn("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(e){return e===void 0?this.localeData():this.locale(e)});function rv(){return this._locale}var Sl=1e3,ws=60*Sl,_l=60*ws,sv=(365*400+97)*24*_l;function Cs(e,t){return(e%t+t)%t}function iv(e,t,n){return e<100&&e>=0?new Date(e+400,t,n)-sv:new Date(e,t,n).valueOf()}function av(e,t,n){return e<100&&e>=0?Date.UTC(e+400,t,n)-sv:Date.UTC(e,t,n)}function zM(e){var t,n;if(e=eo(e),e===void 0||e==="millisecond"||!this.isValid())return this;switch(n=this._isUTC?av:iv,e){case"year":t=n(this.year(),0,1);break;case"quarter":t=n(this.year(),this.month()-this.month()%3,1);break;case"month":t=n(this.year(),this.month(),1);break;case"week":t=n(this.year(),this.month(),this.date()-this.weekday());break;case"isoWeek":t=n(this.year(),this.month(),this.date()-(this.isoWeekday()-1));break;case"day":case"date":t=n(this.year(),this.month(),this.date());break;case"hour":t=this._d.valueOf(),t-=Cs(t+(this._isUTC?0:this.utcOffset()*ws),_l);break;case"minute":t=this._d.valueOf(),t-=Cs(t,ws);break;case"second":t=this._d.valueOf(),t-=Cs(t,Sl);break}return this._d.setTime(t),_e.updateOffset(this,!0),this}function YM(e){var t,n;if(e=eo(e),e===void 0||e==="millisecond"||!this.isValid())return this;switch(n=this._isUTC?av:iv,e){case"year":t=n(this.year()+1,0,1)-1;break;case"quarter":t=n(this.year(),this.month()-this.month()%3+3,1)-1;break;case"month":t=n(this.year(),this.month()+1,1)-1;break;case"week":t=n(this.year(),this.month(),this.date()-this.weekday()+7)-1;break;case"isoWeek":t=n(this.year(),this.month(),this.date()-(this.isoWeekday()-1)+7)-1;break;case"day":case"date":t=n(this.year(),this.month(),this.date()+1)-1;break;case"hour":t=this._d.valueOf(),t+=_l-Cs(t+(this._isUTC?0:this.utcOffset()*ws),_l)-1;break;case"minute":t=this._d.valueOf(),t+=ws-Cs(t,ws)-1;break;case"second":t=this._d.valueOf(),t+=Sl-Cs(t,Sl)-1;break}return this._d.setTime(t),_e.updateOffset(this,!0),this}function UM(){return this._d.valueOf()-(this._offset||0)*6e4}function qM(){return Math.floor(this.valueOf()/1e3)}function GM(){return new Date(this.valueOf())}function KM(){var e=this;return[e.year(),e.month(),e.date(),e.hour(),e.minute(),e.second(),e.millisecond()]}function XM(){var e=this;return{years:e.year(),months:e.month(),date:e.date(),hours:e.hours(),minutes:e.minutes(),seconds:e.seconds(),milliseconds:e.milliseconds()}}function ZM(){return this.isValid()?this.toISOString():null}function QM(){return zu(this)}function JM(){return dr({},ze(this))}function eI(){return ze(this).overflow}function tI(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}}Le("N",0,0,"eraAbbr");Le("NN",0,0,"eraAbbr");Le("NNN",0,0,"eraAbbr");Le("NNNN",0,0,"eraName");Le("NNNNN",0,0,"eraNarrow");Le("y",["y",1],"yo","eraYear");Le("y",["yy",2],0,"eraYear");Le("y",["yyy",3],0,"eraYear");Le("y",["yyyy",4],0,"eraYear");Ee("N",lh);Ee("NN",lh);Ee("NNN",lh);Ee("NNNN",hI);Ee("NNNNN",fI);Tt(["N","NN","NNN","NNNN","NNNNN"],function(e,t,n,o){var r=n._locale.erasParse(e,o,n._strict);r?ze(n).era=r:ze(n).invalidEra=e});Ee("y",js);Ee("yy",js);Ee("yyy",js);Ee("yyyy",js);Ee("yo",pI);Tt(["y","yy","yyy","yyyy"],yn);Tt(["yo"],function(e,t,n,o){var r;n._locale._eraYearOrdinalRegex&&(r=e.match(n._locale._eraYearOrdinalRegex)),n._locale.eraYearOrdinalParse?t[yn]=n._locale.eraYearOrdinalParse(e,r):t[yn]=parseInt(e,10)});function nI(e,t){var n,o,r,i=this._eras||nr("en")._eras;for(n=0,o=i.length;n<o;++n){switch(typeof i[n].since){case"string":r=_e(i[n].since).startOf("day"),i[n].since=r.valueOf();break}switch(typeof i[n].until){case"undefined":i[n].until=1/0;break;case"string":r=_e(i[n].until).startOf("day").valueOf(),i[n].until=r.valueOf();break}}return i}function oI(e,t,n){var o,r,i=this.eras(),a,l,d;for(e=e.toUpperCase(),o=0,r=i.length;o<r;++o)if(a=i[o].name.toUpperCase(),l=i[o].abbr.toUpperCase(),d=i[o].narrow.toUpperCase(),n)switch(t){case"N":case"NN":case"NNN":if(l===e)return i[o];break;case"NNNN":if(a===e)return i[o];break;case"NNNNN":if(d===e)return i[o];break}else if([a,l,d].indexOf(e)>=0)return i[o]}function rI(e,t){var n=e.since<=e.until?1:-1;return t===void 0?_e(e.since).year():_e(e.since).year()+(t-e.offset)*n}function sI(){var e,t,n,o=this.localeData().eras();for(e=0,t=o.length;e<t;++e)if(n=this.clone().startOf("day").valueOf(),o[e].since<=n&&n<=o[e].until||o[e].until<=n&&n<=o[e].since)return o[e].name;return""}function iI(){var e,t,n,o=this.localeData().eras();for(e=0,t=o.length;e<t;++e)if(n=this.clone().startOf("day").valueOf(),o[e].since<=n&&n<=o[e].until||o[e].until<=n&&n<=o[e].since)return o[e].narrow;return""}function aI(){var e,t,n,o=this.localeData().eras();for(e=0,t=o.length;e<t;++e)if(n=this.clone().startOf("day").valueOf(),o[e].since<=n&&n<=o[e].until||o[e].until<=n&&n<=o[e].since)return o[e].abbr;return""}function lI(){var e,t,n,o,r=this.localeData().eras();for(e=0,t=r.length;e<t;++e)if(n=r[e].since<=r[e].until?1:-1,o=this.clone().startOf("day").valueOf(),r[e].since<=o&&o<=r[e].until||r[e].until<=o&&o<=r[e].since)return(this.year()-_e(r[e].since).year())*n+r[e].offset;return this.year()}function cI(e){return ut(this,"_erasNameRegex")||ch.call(this),e?this._erasNameRegex:this._erasRegex}function dI(e){return ut(this,"_erasAbbrRegex")||ch.call(this),e?this._erasAbbrRegex:this._erasRegex}function uI(e){return ut(this,"_erasNarrowRegex")||ch.call(this),e?this._erasNarrowRegex:this._erasRegex}function lh(e,t){return t.erasAbbrRegex(e)}function hI(e,t){return t.erasNameRegex(e)}function fI(e,t){return t.erasNarrowRegex(e)}function pI(e,t){return t._eraYearOrdinalRegex||js}function ch(){var e=[],t=[],n=[],o=[],r,i,a,l,d,u=this.eras();for(r=0,i=u.length;r<i;++r)a=qo(u[r].name),l=qo(u[r].abbr),d=qo(u[r].narrow),t.push(a),e.push(l),n.push(d),o.push(a),o.push(l),o.push(d);this._erasRegex=new RegExp("^("+o.join("|")+")","i"),this._erasNameRegex=new RegExp("^("+t.join("|")+")","i"),this._erasAbbrRegex=new RegExp("^("+e.join("|")+")","i"),this._erasNarrowRegex=new RegExp("^("+n.join("|")+")","i")}Le(0,["gg",2],0,function(){return this.weekYear()%100});Le(0,["GG",2],0,function(){return this.isoWeekYear()%100});function uc(e,t){Le(0,[e,e.length],0,t)}uc("gggg","weekYear");uc("ggggg","weekYear");uc("GGGG","isoWeekYear");uc("GGGGG","isoWeekYear");Ee("G",ic);Ee("g",ic);Ee("GG",It,$n);Ee("gg",It,$n);Ee("GGGG",Xu,Ku);Ee("gggg",Xu,Ku);Ee("GGGGG",sc,oc);Ee("ggggg",sc,oc);ma(["gggg","ggggg","GGGG","GGGGG"],function(e,t,n,o){t[o.substr(0,2)]=Qe(e)});ma(["gg","GG"],function(e,t,n,o){t[o]=_e.parseTwoDigitYear(e)});function mI(e){return lv.call(this,e,this.week(),this.weekday()+this.localeData()._week.dow,this.localeData()._week.dow,this.localeData()._week.doy)}function gI(e){return lv.call(this,e,this.isoWeek(),this.isoWeekday(),1,4)}function yI(){return Go(this.year(),1,4)}function vI(){return Go(this.isoWeekYear(),1,4)}function bI(){var e=this.localeData()._week;return Go(this.year(),e.dow,e.doy)}function wI(){var e=this.localeData()._week;return Go(this.weekYear(),e.dow,e.doy)}function lv(e,t,n,o,r){var i;return e==null?qi(this,o,r).year:(i=Go(e,o,r),t>i&&(t=i),CI.call(this,e,t,n,o,r))}function CI(e,t,n,o,r){var i=By(e,t,n,o,r),a=Ui(i.year,0,i.dayOfYear);return this.year(a.getUTCFullYear()),this.month(a.getUTCMonth()),this.date(a.getUTCDate()),this}Le("Q",0,"Qo","quarter");Ee("Q",Dy);Tt("Q",function(e,t){t[zo]=(Qe(e)-1)*3});function SI(e){return e==null?Math.ceil((this.month()+1)/3):this.month((e-1)*3+this.month()%3)}Le("D",["DD",2],"Do","date");Ee("D",It,Bs);Ee("DD",It,$n);Ee("Do",function(e,t){return e?t._dayOfMonthOrdinalParse||t._ordinalParse:t._dayOfMonthOrdinalParseLenient});Tt(["D","DD"],So);Tt("Do",function(e,t){t[So]=Qe(e.match(It)[0])});var cv=Ws("Date",!0);Le("DDD",["DDDD",3],"DDDo","dayOfYear");Ee("DDD",rc);Ee("DDDD",Oy);Tt(["DDD","DDDD"],function(e,t,n){n._dayOfYear=Qe(e)});function _I(e){var t=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return e==null?t:this.add(e-t,"d")}Le("m",["mm",2],0,"minute");Ee("m",It,Zu);Ee("mm",It,$n);Tt(["m","mm"],ro);var xI=Ws("Minutes",!1);Le("s",["ss",2],0,"second");Ee("s",It,Zu);Ee("ss",It,$n);Tt(["s","ss"],Yo);var RI=Ws("Seconds",!1);Le("S",0,0,function(){return~~(this.millisecond()/100)});Le(0,["SS",2],0,function(){return~~(this.millisecond()/10)});Le(0,["SSS",3],0,"millisecond");Le(0,["SSSS",4],0,function(){return this.millisecond()*10});Le(0,["SSSSS",5],0,function(){return this.millisecond()*100});Le(0,["SSSSSS",6],0,function(){return this.millisecond()*1e3});Le(0,["SSSSSSS",7],0,function(){return this.millisecond()*1e4});Le(0,["SSSSSSSS",8],0,function(){return this.millisecond()*1e5});Le(0,["SSSSSSSSS",9],0,function(){return this.millisecond()*1e6});Ee("S",rc,Dy);Ee("SS",rc,$n);Ee("SSS",rc,Oy);var ur,dv;for(ur="SSSS";ur.length<=9;ur+="S")Ee(ur,js);function kI(e,t){t[Ir]=Qe(("0."+e)*1e3)}for(ur="S";ur.length<=9;ur+="S")Tt(ur,kI);dv=Ws("Milliseconds",!1);Le("z",0,0,"zoneAbbr");Le("zz",0,0,"zoneName");function TI(){return this._isUTC?"UTC":""}function EI(){return this._isUTC?"Coordinated Universal Time":""}var ye=fa.prototype;ye.add=wM;ye.calendar=TM;ye.clone=EM;ye.diff=AM;ye.endOf=YM;ye.format=VM;ye.from=jM;ye.fromNow=BM;ye.to=WM;ye.toNow=HM;ye.get=$D;ye.invalidAt=eI;ye.isAfter=PM;ye.isBefore=DM;ye.isBetween=OM;ye.isSame=MM;ye.isSameOrAfter=IM;ye.isSameOrBefore=NM;ye.isValid=QM;ye.lang=ov;ye.locale=nv;ye.localeData=rv;ye.max=QO;ye.min=ZO;ye.parsingFlags=JM;ye.set=VD;ye.startOf=zM;ye.subtract=CM;ye.toArray=KM;ye.toObject=XM;ye.toDate=GM;ye.toISOString=LM;ye.inspect=$M;typeof Symbol<"u"&&Symbol.for!=null&&(ye[Symbol.for("nodejs.util.inspect.custom")]=function(){return"Moment<"+this.format()+">"});ye.toJSON=ZM;ye.toString=FM;ye.unix=qM;ye.valueOf=UM;ye.creationData=tI;ye.eraName=sI;ye.eraNarrow=iI;ye.eraAbbr=aI;ye.eraYear=lI;ye.year=Ny;ye.isLeapYear=LD;ye.weekYear=mI;ye.isoWeekYear=gI;ye.quarter=ye.quarters=SI;ye.month=Vy;ye.daysInMonth=GD;ye.week=ye.weeks=nO;ye.isoWeek=ye.isoWeeks=oO;ye.weeksInYear=bI;ye.weeksInWeekYear=wI;ye.isoWeeksInYear=yI;ye.isoWeeksInISOWeekYear=vI;ye.date=cv;ye.day=ye.days=gO;ye.weekday=yO;ye.isoWeekday=vO;ye.dayOfYear=_I;ye.hour=ye.hours=RO;ye.minute=ye.minutes=xI;ye.second=ye.seconds=RI;ye.millisecond=ye.milliseconds=dv;ye.utcOffset=aM;ye.utc=cM;ye.local=dM;ye.parseZone=uM;ye.hasAlignedHourOffset=hM;ye.isDST=fM;ye.isLocal=mM;ye.isUtcOffset=gM;ye.isUtc=Qy;ye.isUTC=Qy;ye.zoneAbbr=TI;ye.zoneName=EI;ye.dates=Jn("dates accessor is deprecated. Use date instead.",cv);ye.months=Jn("months accessor is deprecated. Use month instead",Vy);ye.years=Jn("years accessor is deprecated. Use year instead",Ny);ye.zone=Jn("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",lM);ye.isDSTShifted=Jn("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",pM);function PI(e){return Ot(e*1e3)}function DI(){return Ot.apply(null,arguments).parseZone()}function uv(e){return e}var ht=Uu.prototype;ht.calendar=mD;ht.longDateFormat=bD;ht.invalidDate=CD;ht.ordinal=xD;ht.preparse=uv;ht.postformat=uv;ht.relativeTime=kD;ht.pastFuture=TD;ht.set=fD;ht.eras=nI;ht.erasParse=oI;ht.erasConvertYear=rI;ht.erasAbbrRegex=dI;ht.erasNameRegex=cI;ht.erasNarrowRegex=uI;ht.months=zD;ht.monthsShort=YD;ht.monthsParse=qD;ht.monthsRegex=XD;ht.monthsShortRegex=KD;ht.week=QD;ht.firstDayOfYear=tO;ht.firstDayOfWeek=eO;ht.weekdays=uO;ht.weekdaysMin=fO;ht.weekdaysShort=hO;ht.weekdaysParse=mO;ht.weekdaysRegex=bO;ht.weekdaysShortRegex=wO;ht.weekdaysMinRegex=CO;ht.isPM=_O;ht.meridiem=kO;function xl(e,t,n,o){var r=nr(),i=Oo().set(o,t);return r[n](i,e)}function hv(e,t,n){if(Jo(e)&&(t=e,e=void 0),e=e||"",t!=null)return xl(e,t,n,"month");var o,r=[];for(o=0;o<12;o++)r[o]=xl(e,o,n,"month");return r}function dh(e,t,n,o){typeof e=="boolean"?(Jo(t)&&(n=t,t=void 0),t=t||""):(t=e,n=t,e=!1,Jo(t)&&(n=t,t=void 0),t=t||"");var r=nr(),i=e?r._week.dow:0,a,l=[];if(n!=null)return xl(t,(n+i)%7,o,"day");for(a=0;a<7;a++)l[a]=xl(t,(a+i)%7,o,"day");return l}function OI(e,t){return hv(e,t,"months")}function MI(e,t){return hv(e,t,"monthsShort")}function II(e,t,n){return dh(e,t,n,"weekdays")}function NI(e,t,n){return dh(e,t,n,"weekdaysShort")}function AI(e,t,n){return dh(e,t,n,"weekdaysMin")}hr("en",{eras:[{since:"0001-01-01",until:1/0,offset:1,name:"Anno Domini",narrow:"AD",abbr:"AD"},{since:"0000-12-31",until:-1/0,offset:1,name:"Before Christ",narrow:"BC",abbr:"BC"}],dayOfMonthOrdinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(e){var t=e%10,n=Qe(e%100/10)===1?"th":t===1?"st":t===2?"nd":t===3?"rd":"th";return e+n}});_e.lang=Jn("moment.lang is deprecated. Use moment.locale instead.",hr);_e.langData=Jn("moment.langData is deprecated. Use moment.localeData instead.",nr);var jo=Math.abs;function FI(){var e=this._data;return this._milliseconds=jo(this._milliseconds),this._days=jo(this._days),this._months=jo(this._months),e.milliseconds=jo(e.milliseconds),e.seconds=jo(e.seconds),e.minutes=jo(e.minutes),e.hours=jo(e.hours),e.months=jo(e.months),e.years=jo(e.years),this}function fv(e,t,n,o){var r=co(t,n);return e._milliseconds+=o*r._milliseconds,e._days+=o*r._days,e._months+=o*r._months,e._bubble()}function LI(e,t){return fv(this,e,t,1)}function $I(e,t){return fv(this,e,t,-1)}function tm(e){return e<0?Math.floor(e):Math.ceil(e)}function VI(){var e=this._milliseconds,t=this._days,n=this._months,o=this._data,r,i,a,l,d;return e>=0&&t>=0&&n>=0||e<=0&&t<=0&&n<=0||(e+=tm(Qd(n)+t)*864e5,t=0,n=0),o.milliseconds=e%1e3,r=Un(e/1e3),o.seconds=r%60,i=Un(r/60),o.minutes=i%60,a=Un(i/60),o.hours=a%24,t+=Un(a/24),d=Un(pv(t)),n+=d,t-=tm(Qd(d)),l=Un(n/12),n%=12,o.days=t,o.months=n,o.years=l,this}function pv(e){return e*4800/146097}function Qd(e){return e*146097/4800}function jI(e){if(!this.isValid())return NaN;var t,n,o=this._milliseconds;if(e=eo(e),e==="month"||e==="quarter"||e==="year")switch(t=this._days+o/864e5,n=this._months+pv(t),e){case"month":return n;case"quarter":return n/3;case"year":return n/12}else switch(t=this._days+Math.round(Qd(this._months)),e){case"week":return t/7+o/6048e5;case"day":return t+o/864e5;case"hour":return t*24+o/36e5;case"minute":return t*1440+o/6e4;case"second":return t*86400+o/1e3;case"millisecond":return Math.floor(t*864e5)+o;default:throw new Error("Unknown unit "+e)}}function or(e){return function(){return this.as(e)}}var mv=or("ms"),BI=or("s"),WI=or("m"),HI=or("h"),zI=or("d"),YI=or("w"),UI=or("M"),qI=or("Q"),GI=or("y"),KI=mv;function XI(){return co(this)}function ZI(e){return e=eo(e),this.isValid()?this[e+"s"]():NaN}function Hr(e){return function(){return this.isValid()?this._data[e]:NaN}}var QI=Hr("milliseconds"),JI=Hr("seconds"),eN=Hr("minutes"),tN=Hr("hours"),nN=Hr("days"),oN=Hr("months"),rN=Hr("years");function sN(){return Un(this.days()/7)}var Wo=Math.round,ps={ss:44,s:45,m:45,h:22,d:26,w:null,M:11};function iN(e,t,n,o,r){return r.relativeTime(t||1,!!n,e,o)}function aN(e,t,n,o){var r=co(e).abs(),i=Wo(r.as("s")),a=Wo(r.as("m")),l=Wo(r.as("h")),d=Wo(r.as("d")),u=Wo(r.as("M")),f=Wo(r.as("w")),p=Wo(r.as("y")),y=i<=n.ss&&["s",i]||i<n.s&&["ss",i]||a<=1&&["m"]||a<n.m&&["mm",a]||l<=1&&["h"]||l<n.h&&["hh",l]||d<=1&&["d"]||d<n.d&&["dd",d];return n.w!=null&&(y=y||f<=1&&["w"]||f<n.w&&["ww",f]),y=y||u<=1&&["M"]||u<n.M&&["MM",u]||p<=1&&["y"]||["yy",p],y[2]=t,y[3]=+e>0,y[4]=o,iN.apply(null,y)}function lN(e){return e===void 0?Wo:typeof e=="function"?(Wo=e,!0):!1}function cN(e,t){return ps[e]===void 0?!1:t===void 0?ps[e]:(ps[e]=t,e==="s"&&(ps.ss=t-1),!0)}function dN(e,t){if(!this.isValid())return this.localeData().invalidDate();var n=!1,o=ps,r,i;return typeof e=="object"&&(t=e,e=!1),typeof e=="boolean"&&(n=e),typeof t=="object"&&(o=Object.assign({},ps,t),t.s!=null&&t.ss==null&&(o.ss=t.s-1)),r=this.localeData(),i=aN(this,!n,o,r),n&&(i=r.pastFuture(+this,i)),r.postformat(i)}var ud=Math.abs;function ls(e){return(e>0)-(e<0)||+e}function hc(){if(!this.isValid())return this.localeData().invalidDate();var e=ud(this._milliseconds)/1e3,t=ud(this._days),n=ud(this._months),o,r,i,a,l=this.asSeconds(),d,u,f,p;return l?(o=Un(e/60),r=Un(o/60),e%=60,o%=60,i=Un(n/12),n%=12,a=e?e.toFixed(3).replace(/\.?0+$/,""):"",d=l<0?"-":"",u=ls(this._months)!==ls(l)?"-":"",f=ls(this._days)!==ls(l)?"-":"",p=ls(this._milliseconds)!==ls(l)?"-":"",d+"P"+(i?u+i+"Y":"")+(n?u+n+"M":"")+(t?f+t+"D":"")+(r||o||e?"T":"")+(r?p+r+"H":"")+(o?p+o+"M":"")+(e?p+a+"S":"")):"P0D"}var rt=dc.prototype;rt.isValid=oM;rt.abs=FI;rt.add=LI;rt.subtract=$I;rt.as=jI;rt.asMilliseconds=mv;rt.asSeconds=BI;rt.asMinutes=WI;rt.asHours=HI;rt.asDays=zI;rt.asWeeks=YI;rt.asMonths=UI;rt.asQuarters=qI;rt.asYears=GI;rt.valueOf=KI;rt._bubble=VI;rt.clone=XI;rt.get=ZI;rt.milliseconds=QI;rt.seconds=JI;rt.minutes=eN;rt.hours=tN;rt.days=nN;rt.weeks=sN;rt.months=oN;rt.years=rN;rt.humanize=dN;rt.toISOString=hc;rt.toString=hc;rt.toJSON=hc;rt.locale=nv;rt.localeData=rv;rt.toIsoString=Jn("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",hc);rt.lang=ov;Le("X",0,0,"unix");Le("x",0,0,"valueOf");Ee("x",ic);Ee("X",OD);Tt("X",function(e,t,n){n._d=new Date(parseFloat(e)*1e3)});Tt("x",function(e,t,n){n._d=new Date(Qe(e))});//! moment.js
|
|
274
|
+
_e.version="2.30.1";uD(Ot);_e.fn=ye;_e.min=JO;_e.max=eM;_e.now=tM;_e.utc=Oo;_e.unix=PI;_e.months=OI;_e.isDate=ha;_e.locale=hr;_e.invalid=nc;_e.duration=co;_e.isMoment=ao;_e.weekdays=II;_e.parseZone=DI;_e.localeData=nr;_e.isDuration=sl;_e.monthsShort=MI;_e.weekdaysMin=AI;_e.defineLocale=nh;_e.updateLocale=DO;_e.locales=OO;_e.weekdaysShort=NI;_e.normalizeUnits=eo;_e.relativeTimeRounding=lN;_e.relativeTimeThreshold=cN;_e.calendarFormat=kM;_e.prototype=ye;_e.HTML5_FMT={DATETIME_LOCAL:"YYYY-MM-DDTHH:mm",DATETIME_LOCAL_SECONDS:"YYYY-MM-DDTHH:mm:ss",DATETIME_LOCAL_MS:"YYYY-MM-DDTHH:mm:ss.SSS",DATE:"YYYY-MM-DD",TIME:"HH:mm",TIME_SECONDS:"HH:mm:ss",TIME_MS:"HH:mm:ss.SSS",WEEK:"GGGG-[W]WW",MONTH:"YYYY-MM"};const uN=Object.freeze(Object.defineProperty({__proto__:null,default:_e},Symbol.toStringTag,{value:"Module"})),hN=[_e.ISO_8601,jr.ui,jr.db],Jd="Invalid date";ae(Bg)({width:"100%","& .MuiAlert-message":{fontSize:"0.8rem"}," [data-testid=CloseIcon]":{fill:"white"}});let gv=class{constructor(){this._args={},this._grid=null,this._tableId=""}getFilterFn(){return()=>!0}register(t,n){this.tableId=n,this.grid=t;const o=t.getData();o.setFilter(this.getFilterFn()),o.setFilterArgs(this.args),o.refresh()}reset(){if(!this.grid)return;this.args={};const t=this.grid.getData();t.setFilterArgs(this.args),t.refresh()}print(){return[]}set grid(t){this._grid=t}get grid(){return this._grid}set args(t){if(this._args=t,!this.grid)return;const n=this.grid.getData();n.setFilterArgs(t),n.refresh()}get args(){return this._args}set tableId(t){this._tableId=t}get tableId(){return this._tableId}};class fN extends gv{getFilterFn(){return t=>!t?.isDeleted}}class pN{constructor(){this._args={},this._grid=null,this._tableId=""}getFilterFn(){return()=>!0}register(){}print(){return[]}reset(){}get args(){return this._args}get grid(){return this._grid}get tableId(){return this._tableId}set args(t){}set grid(t){}set tableId(t){}}function ms(e){return new Date(e).getTime()}class yv{constructor(t){this.filter=t}getFilterFn(){const t=this.filter.getFilterFn();return(n,o)=>this.filterFn(n,o)&&t(n,o)}register(t,n){this.tableId=n,this.grid=t;const o=t.getData();o.setFilter(this.getFilterFn()),o.setFilterArgs(this.args),o.refresh()}reset(){this.filter.reset()}print(t){return this.filter.print(t)}set args(t){this.filter.args=t}set grid(t){this.filter.grid=t}set tableId(t){this.filter.tableId=t}get args(){return this.filter.args}get grid(){return this.filter.grid}get tableId(){return this.filter.tableId}}function mN(e){return{tooltip:"Apply column filter",command:e}}class fc{constructor(){this.observers=[]}subscribe(t){~this.observers.indexOf(t)||this.observers.push(t)}unsubscribe(t){const n=this.observers.indexOf(t);~this.observers.indexOf(t)&&this.observers.splice(n,1)}notify(){for(const t of this.observers)t()}}class gN extends fc{constructor(){super(...arguments),this.columnId="",this.group=sn.Text,this.target=null,this.x=0,this.y=0}}const wn=new gN;class yN{highlightAllColumns(t,n){const o=document.getElementById(n);if(!o)return;const r=Object.keys(t.columnFilters||{});if(r.length)for(const i of r){const a=o.querySelector(`[data-id="${i}"]`);a&&(t.columnFilters[i].value[1]||t.columnFilters[i].value[2]?a.classList.add("filter-active"):a.classList.remove("filter-active"))}else{const i=o.querySelectorAll(".slick-header-column");for(const a of i)a.classList.remove("filter-active")}}highlightColumn(t,n){const o=document.getElementById(t.id);if(!o)return;const r=o.querySelector(`[data-id="${n}"]`);r&&r.classList.add("filter-active")}resetColumn(t,n){const o=document.getElementById(t.id);if(!o)return;const r=o.querySelector(`[data-id="${n}"]`);r&&r.classList.remove("filter-active")}}const er=new yN;function vv(e){return er.highlightAllColumns(e.filter.args,e.id),function(t,n){t.preventDefault(),wn.columnId=n.column.id||"",wn.group=n.command,wn.table=e,wn.target=t.target,wn.x=t.x||0,wn.y=t.y||0,wn.notify()}}var vN=Object.defineProperty,bN=(e,t,n)=>t in e?vN(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,T=(e,t,n)=>bN(e,typeof t!="symbol"?t+"":t,n),Ki=class{constructor(e,t){this.event=e,this.args=t,T(this,"_isPropagationStopped",!1),T(this,"_isImmediatePropagationStopped",!1),T(this,"_isDefaultPrevented",!1),T(this,"returnValues",[]),T(this,"returnValue"),T(this,"_eventTarget"),T(this,"nativeEvent"),T(this,"arguments_"),T(this,"altKey"),T(this,"ctrlKey"),T(this,"metaKey"),T(this,"shiftKey"),T(this,"key"),T(this,"keyCode"),T(this,"clientX"),T(this,"clientY"),T(this,"offsetX"),T(this,"offsetY"),T(this,"pageX"),T(this,"pageY"),T(this,"bubbles"),T(this,"target"),T(this,"type"),T(this,"which"),T(this,"x"),T(this,"y"),this.nativeEvent=e,this.arguments_=t,e&&["altKey","ctrlKey","metaKey","shiftKey","key","keyCode","clientX","clientY","offsetX","offsetY","pageX","pageY","bubbles","target","type","which","x","y"].forEach(n=>this[n]=e[n]),this._eventTarget=this.nativeEvent?this.nativeEvent.target:void 0}get defaultPrevented(){return this._isDefaultPrevented}stopPropagation(){this._isPropagationStopped=!0,this.nativeEvent?.stopPropagation()}isPropagationStopped(){return this._isPropagationStopped}stopImmediatePropagation(){this._isImmediatePropagationStopped=!0,this.nativeEvent&&this.nativeEvent.stopImmediatePropagation()}isImmediatePropagationStopped(){return this._isImmediatePropagationStopped}getNativeEvent(){return this.nativeEvent}preventDefault(){this.nativeEvent&&this.nativeEvent.preventDefault(),this._isDefaultPrevented=!0}isDefaultPrevented(){return this.nativeEvent?this.nativeEvent.defaultPrevented:this._isDefaultPrevented}addReturnValue(e){this.returnValues.push(e),this.returnValue===void 0&&e!==void 0&&(this.returnValue=e)}getReturnValue(){return this.returnValue}getArguments(){return this.arguments_}},zr=class{constructor(e,t){this.eventName=e,this.pubSub=t,T(this,"_handlers",[]),T(this,"_pubSubService"),this._pubSubService=t}get subscriberCount(){return this._handlers.length}subscribe(e){this._handlers.push(e)}unsubscribe(e){for(let t=this._handlers.length-1;t>=0;t--)this._handlers[t]===e&&this._handlers.splice(t,1)}notify(e,t,n){let o=t instanceof Ki?t:new Ki(t,e);n=n||this;for(let r=0;r<this._handlers.length&&!(o.isPropagationStopped()||o.isImmediatePropagationStopped());r++){let i=this._handlers[r].call(n,o,e);o.addReturnValue(i)}if(typeof this._pubSubService?.publish=="function"&&this.eventName){let r=this._pubSubService.publish(this.eventName,{args:e,eventData:o});o.addReturnValue(r)}return o}setPubSubService(e){this._pubSubService=e}},ga=class{constructor(){T(this,"handlers",[])}subscribe(e,t){return this.handlers.push({event:e,handler:t}),e.subscribe(t),this}unsubscribe(e,t){let n=this.handlers.length;for(;n--;)if(this.handlers[n].event===e&&this.handlers[n].handler===t){this.handlers.splice(n,1),e.unsubscribe(t);return}return this}unsubscribeAll(){let e=this.handlers.length;for(;e--;)this.handlers[e].event.unsubscribe(this.handlers[e].handler);return this.handlers=[],this}},uh=class{constructor(e,t,n,o){T(this,"fromRow"),T(this,"fromCell"),T(this,"toCell"),T(this,"toRow"),n===void 0&&o===void 0&&(n=e,o=t),this.fromRow=Math.min(e,n),this.fromCell=Math.min(t,o),this.toCell=Math.max(t,o),this.toRow=Math.max(e,n)}isSingleRow(){return this.fromRow===this.toRow}isSingleCell(){return this.fromRow===this.toRow&&this.fromCell===this.toCell}contains(e,t){return e>=this.fromRow&&e<=this.toRow&&t>=this.fromCell&&t<=this.toCell}toString(){return this.isSingleCell()?`(${this.fromRow}:${this.fromCell})`:`(${this.fromRow}:${this.fromCell} - ${this.toRow}:${this.toCell})`}},bv=class{constructor(){T(this,"__nonDataRow",!0)}},wv=class extends bv{constructor(){super(),T(this,"__group",!0),T(this,"level",0),T(this,"count",0),T(this,"value",null),T(this,"title",null),T(this,"collapsed",!1),T(this,"selectChecked",!1),T(this,"totals",null),T(this,"rows",[]),T(this,"groups",null),T(this,"groupingKey",null)}equals(e){return this.value===e.value&&this.count===e.count&&this.collapsed===e.collapsed&&this.title===e.title}},wN=class extends bv{constructor(){super(),T(this,"__groupTotals",!0),T(this,"group",null),T(this,"initialized",!1)}},CN=class{constructor(){T(this,"activeEditController",null)}isActive(e){return e?this.activeEditController===e:this.activeEditController!==null}activate(e){if(e!==this.activeEditController){if(this.activeEditController!==null)throw new Error("Slick.EditorLock.activate: an editController is still active, can't activate another editController");if(!e.commitCurrentEdit)throw new Error("Slick.EditorLock.activate: editController must implement .commitCurrentEdit()");if(!e.cancelCurrentEdit)throw new Error("Slick.EditorLock.activate: editController must implement .cancelCurrentEdit()");this.activeEditController=e}}deactivate(e){if(this.activeEditController){if(this.activeEditController!==e)throw new Error("Slick.EditorLock.deactivate: specified editController is not the currently active one");this.activeEditController=null}}commitCurrentEdit(){return this.activeEditController?this.activeEditController.commitCurrentEdit():!0}cancelCurrentEdit(){return this.activeEditController?this.activeEditController.cancelCurrentEdit():!0}},pc=class{constructor(){T(this,"_boundedEvents",[])}getBoundedEvents(){return this._boundedEvents}destroy(){this.unbindAll()}bind(e,t,n,o,r=""){e&&(e.addEventListener(t,n,o),this._boundedEvents.push({element:e,eventName:t,listener:n,groupName:r}))}unbind(e,t,n){e?.removeEventListener&&e.removeEventListener(t,n)}unbindByEventName(e,t){let n=this._boundedEvents.find(o=>o.element===e&&o.eventName===t);n&&this.unbind(n.element,n.eventName,n.listener)}unbindAll(e){if(e){let t=Array.isArray(e)?e:[e];for(let n=this._boundedEvents.length-1;n>=0;--n){let o=this._boundedEvents[n];if(t.some(r=>r===o.groupName)){let{element:r,eventName:i,listener:a}=o;this.unbind(r,i,a),this._boundedEvents.splice(n,1)}}}else for(;this._boundedEvents.length>0;){let t=this._boundedEvents.pop(),{element:n,eventName:o,listener:r}=t;this.unbind(n,o,r)}}},Hn=class jt{static isFunction(t){return typeof t=="function"&&typeof t.nodeType!="number"&&typeof t.item!="function"}static isPlainObject(t){if(!t||jt.toString.call(t)!=="[object Object]")return!1;let n=jt.getProto(t);if(!n)return!0;let o=jt.hasOwn.call(n,"constructor")&&n.constructor;return typeof o=="function"&&jt.fnToString.call(o)===jt.ObjectFunctionString}static calculateAvailableSpace(t){let n=0,o=0,r=0,i=0,a=window.innerHeight||0,l=window.innerWidth||0,d=jt.windowScrollPosition(),u=d.top,f=d.left,p=jt.offset(t);if(p){let y=p.top||0,b=p.left||0;o=y-u,n=a-(y-u),r=b-f,i=l-(b-f)}return{top:o,bottom:n,left:r,right:i}}static extend(...t){let n,o,r,i,a,l,d=t[0],u=1,f=!1,p=t.length;for(typeof d=="boolean"?(f=d,d=t[u]||{},u++):d=d||{},typeof d!="object"&&!jt.isFunction(d)&&(d={}),u===p&&(d=this,u--);u<p;u++)if(jt.isDefined(n=t[u]))for(o in n)i=n[o],!(o==="__proto__"||d===i)&&(f&&i&&(jt.isPlainObject(i)||(a=Array.isArray(i)))?(r=d[o],a&&!Array.isArray(r)?l=[]:!a&&!jt.isPlainObject(r)?l={}:l=r,a=!1,d[o]=jt.extend(f,l,i)):i!==void 0&&(d[o]=i));return d}static createDomElement(t,n,o){let r=document.createElement(t);return n&&Object.keys(n).forEach(i=>{i==="innerHTML"&&console.warn(`[SlickGrid] For better CSP (Content Security Policy) support, do not use "innerHTML" directly in "createDomElement('${t}', { innerHTML: 'some html'})", it is better as separate assignment: "const elm = createDomElement('span'); elm.innerHTML = 'some html';"`);let a=n[i];typeof a=="object"?Object.assign(r[i],a):r[i]=n[i]}),o?.appendChild&&o.appendChild(r),r}static getHtmlStringOutput(t,n="innerHTML"){return t instanceof DocumentFragment?[].map.call(t.childNodes,o=>o[n]).join("")||t.textContent||"":t instanceof HTMLElement?t[n]:String(t)}static emptyElement(t){for(;t?.firstChild;)t.removeChild(t.firstChild);return t}static classNameToList(t=""){return t.split(" ").filter(n=>n)}static innerSize(t,n){let o=0;if(t){let r=n==="height"?"clientHeight":"clientWidth",i=n==="height"?["top","bottom"]:["left","right"];o=t[r];for(let a of i){let l=parseFloat(jt.getElementProp(t,`padding-${a}`)||"")||0;o-=l}}return o}static isDefined(t){return t!=null&&t!==""}static getElementProp(t,n){return t?.getComputedStyle?window.getComputedStyle(t,null).getPropertyValue(n):null}static getFunctionDetails(t,n=!0){let o=!1,r=i=>{let a=i.toString();if(o=a.includes("async "),a.replaceAll(" ","").includes("=>({")){let u=a.match(/(({.*}))/g)||[];return u.length>=1?`return ${u[0].trimStart()}`:a}let l=!a.includes("{")&&a.includes("=>"),d=a.substring(a.indexOf("{")+1||a.indexOf("=>")+2,a.includes("}")?a.lastIndexOf("}"):a.length);return n&&l&&!d.startsWith("return")?"return "+d.trimStart():d};return{params:(i=>{let a=/(\/\/.*$)|(\/\*[\s\S]*?\*\/)|(\s*=[^,)]*(('(?:\\'|[^'\r\n])*')|("(?:\\"|[^"\r\n])*"))|(\s*=[^,)]*))/mg,l=/([^\s,]+)/g,d=i.toString().replace(a,"");return d.slice(d.indexOf("(")+1,d.indexOf(")")).match(l)??[]})(t),body:r(t),isAsync:o}}static insertAfterElement(t,n){t.parentNode?.insertBefore(n,t.nextSibling)}static isEmptyObject(t){return t==null?!0:Object.entries(t).length===0}static noop(){}static offset(t){if(!t||!t.getBoundingClientRect)return;let n=t.getBoundingClientRect(),o=document.documentElement;return{top:n.top+window.pageYOffset-o.clientTop,left:n.left+window.pageXOffset-o.clientLeft}}static windowScrollPosition(){return{left:window.pageXOffset||document.documentElement.scrollLeft||0,top:window.pageYOffset||document.documentElement.scrollTop||0}}static width(t,n){if(!(!t||!t.getBoundingClientRect)){if(n===void 0)return t.getBoundingClientRect().width;jt.setStyleSize(t,"width",n)}}static height(t,n){if(t){if(n===void 0)return t.getBoundingClientRect().height;jt.setStyleSize(t,"height",n)}}static setStyleSize(t,n,o){typeof o=="function"?o=o():typeof o=="string"?t.style[n]=o:t.style[n]=o+"px"}static contains(t,n){return!t||!n?!1:!jt.parents(n).every(o=>t!==o)}static isHidden(t){return t.offsetWidth===0&&t.offsetHeight===0}static parents(t,n){let o=[],r=n===":visible",i=n===":hidden";for(;(t=t.parentNode)&&t!==document&&!(!t||!t.parentNode);)i?jt.isHidden(t)&&o.push(t):r?jt.isHidden(t)||o.push(t):(!n||t.matches(n))&&o.push(t);return o}static toFloat(t){let n=parseFloat(t);return isNaN(n)?0:n}static show(t,n=""){Array.isArray(t)?t.forEach(o=>o.style.display=n):t.style.display=n}static hide(t){Array.isArray(t)?t.forEach(n=>n.style.display="none"):t.style.display="none"}static slideUp(t,n){return jt.slideAnimation(t,"slideUp",n)}static slideDown(t,n){return jt.slideAnimation(t,"slideDown",n)}static slideAnimation(t,n,o){if(window.jQuery!==void 0){window.jQuery(t)[n]("fast",o);return}n==="slideUp"?jt.hide(t):jt.show(t),o()}static applyDefaults(t,n){typeof n=="object"&&Object.keys(n).forEach(o=>{n.hasOwnProperty(o)&&!t.hasOwnProperty(o)&&(t[o]=n[o])})}static addSlickEventPubSubWhenDefined(t,n){if(t)for(let o in n)n[o]instanceof zr&&typeof n[o].setPubSubService=="function"&&n[o].setPubSubService(t)}};T(Hn,"getProto",Object.getPrototypeOf),T(Hn,"class2type",{}),T(Hn,"toString",Hn.class2type.toString),T(Hn,"hasOwn",Hn.class2type.hasOwnProperty),T(Hn,"fnToString",Hn.hasOwn.toString),T(Hn,"ObjectFunctionString",Hn.fnToString.call(Object)),T(Hn,"storage",{_storage:new WeakMap,put:function(e,t,n){this._storage.has(e)||this._storage.set(e,new Map),this._storage.get(e).set(t,n)},get:function(e,t){let n=this._storage.get(e);return n?n.get(t):null},remove:function(e,t){let n=this._storage.get(e).delete(t);return this._storage.get(e).size!==0&&this._storage.delete(e),n}});var uo=Hn,Cv=new CN,SN={Event:zr,EventHandler:ga,GlobalEditorLock:Cv,keyCode:{SPACE:8,DOWN:40,ENTER:13,ESCAPE:27,LEFT:37,PAGE_DOWN:34,PAGE_UP:33,RIGHT:39,TAB:9,UP:38},preClickClassName:"slick-edit-preclick",GridAutosizeColsMode:{None:"NOA",LegacyOff:"LOF",LegacyForceFit:"LFF",IgnoreViewport:"IGV",FitColsToViewport:"FCV",FitViewportToCols:"FVC"},ColAutosizeMode:{Locked:"LCK",Guide:"GUI",ContentExpandOnly:"CXO",ContentIntelligent:"CTI"},RowSelectionMode:{FirstRow:"FS1",FirstNRows:"FSN",AllRows:"ALL",LastRow:"LS1"},ValueFilterMode:{None:"NONE",DeDuplicate:"DEDP",GetGreatestAndSub:"GR8T",GetLongestTextAndSub:"LNSB",GetLongestText:"LNSC"},WidthEvalMode:{Auto:"AUTO",TextOnly:"CANV"}},{Event:_N,EventHandler:xN,GlobalEditorLock:RN,keyCode:Lr,preClickClassName:kN,GridAutosizeColsMode:Sv,ColAutosizeMode:TN,RowSelectionMode:EN,ValueFilterMode:PN,WidthEvalMode:DN}=SN,ON=uo,_v=class{constructor(e,t){this.grid=e,T(this,"pluginName","CellRangeDecorator"),T(this,"_options"),T(this,"_elem"),T(this,"_defaults",{selectionCssClass:"slick-range-decorator",selectionCss:{zIndex:"9999",border:"2px dashed red"},offset:{top:-1,left:-1,height:-2,width:-2}}),this._options=ON.extend(!0,{},this._defaults,t)}destroy(){this.hide()}init(){}hide(){this._elem?.remove(),this._elem=null}show(e){if(!this._elem){this._elem=document.createElement("div"),this._elem.className=this._options.selectionCssClass,Object.keys(this._options.selectionCss).forEach(r=>{this._elem.style[r]=this._options.selectionCss[r]}),this._elem.style.position="absolute";let o=this.grid.getActiveCanvasNode();o&&o.appendChild(this._elem)}let t=this.grid.getCellNodeBox(e.fromRow,e.fromCell),n=this.grid.getCellNodeBox(e.toRow,e.toCell);return t&&n&&this._options?.offset&&(this._elem.style.top=`${t.top+this._options.offset.top}px`,this._elem.style.left=`${t.left+this._options.offset.left}px`,this._elem.style.height=`${n.bottom-t.top+this._options.offset.height}px`,this._elem.style.width=`${n.right-t.left+this._options.offset.width}px`),this._elem}},MN=uo;function hh(e){let{containerElement:t}=e,{onDragInit:n,onDragStart:o,onDrag:r,onDragEnd:i,preventDragFromKeys:a}=e,l,d,u,f,p,y;t||(t=document.body);let b={dragSource:t,dragHandle:null};function w(){t&&(t.addEventListener("mousedown",P),t.addEventListener("touchstart",P))}function g(C,O,N){if(typeof C=="function")return C(O,N)}function v(){t&&(t.removeEventListener("mousedown",P),t.removeEventListener("touchstart",P))}function E(C){let O=!1;return a&&a.forEach(N=>{C[N]&&(O=!0)}),O}function P(C){if(!E(C)){l=C.target;let O=C?.touches?.[0]??C,{target:N}=O;if(!e.allowDragFrom||e.allowDragFrom&&l.matches(e.allowDragFrom)||e.allowDragFromClosest&&l.closest(e.allowDragFromClosest)){b.dragHandle=l;let F=MN.windowScrollPosition();d=F.left+O.clientX,u=F.top+O.clientY,f=O.clientX-O.clientX,p=O.clientY-O.clientY,b=Object.assign(b,{deltaX:f,deltaY:p,startX:d,startY:u,target:N}),g(n,C,b)!==!1&&(document.body.addEventListener("mousemove",x),document.body.addEventListener("touchmove",x),document.body.addEventListener("mouseup",S),document.body.addEventListener("touchend",S),document.body.addEventListener("touchcancel",S))}}}function x(C){if(!E(C)){let O=C?.touches?.[0]??C;f=O.clientX-d,p=O.clientY-u;let{target:N}=O;y||(b=Object.assign(b,{deltaX:f,deltaY:p,startX:d,startY:u,target:N}),g(o,C,b),y=!0),b=Object.assign(b,{deltaX:f,deltaY:p,startX:d,startY:u,target:N}),g(r,C,b)}}function S(C){if(document.body.removeEventListener("mousemove",x),document.body.removeEventListener("touchmove",x),document.body.removeEventListener("mouseup",S),document.body.removeEventListener("touchend",S),document.body.removeEventListener("touchcancel",S),y){let{target:O}=C;b=Object.assign(b,{target:O}),g(i,C,b),y=!1}}return w(),{destroy:v}}function IN(e){let{element:t,onMouseWheel:n}=e;function o(){t.removeEventListener("wheel",i),t.removeEventListener("mousewheel",i)}function r(){t.addEventListener("wheel",i),t.addEventListener("mousewheel",i)}function i(a){let l=a||window.event,d=0,u=0,f=0;l.wheelDelta&&(d=l.wheelDelta/120),l.detail&&(d=-l.detail/3),f=d,l.axis!==void 0&&l.axis===l.HORIZONTAL_AXIS&&(f=0,u=-1*d),l.wheelDeltaY!==void 0&&(f=l.wheelDeltaY/120),l.wheelDeltaX!==void 0&&(u=-1*l.wheelDeltaX/120),typeof n=="function"&&n(a,d,u,f)}return r(),{destroy:o}}function NN(e){let{resizeableElement:t,resizeableHandleElement:n,onResizeStart:o,onResize:r,onResizeEnd:i}=e;if(!n||typeof n.addEventListener!="function")throw new Error("[Slick.Resizable] You did not provide a valid html element that will be used for the handle to resize.");function a(){n.addEventListener("mousedown",u),n.addEventListener("touchstart",u)}function l(){typeof n?.removeEventListener=="function"&&(n.removeEventListener("mousedown",u),n.removeEventListener("touchstart",u))}function d(y,b){if(typeof y=="function")return y(b,{resizeableElement:t,resizeableHandleElement:n})}function u(y){y.preventDefault();let b=y.touches?y.changedTouches[0]:y;d(o,b)!==!1&&(document.body.addEventListener("mousemove",f),document.body.addEventListener("mouseup",p),document.body.addEventListener("touchmove",f),document.body.addEventListener("touchend",p))}function f(y){y.preventDefault&&y.type!=="touchmove"&&y.preventDefault();let b=y.touches?y.changedTouches[0]:y;typeof r=="function"&&r(b,{resizeableElement:t,resizeableHandleElement:n})}function p(y){let b=y.touches?y.changedTouches[0]:y;d(i,b),document.body.removeEventListener("mousemove",f),document.body.removeEventListener("mouseup",p),document.body.removeEventListener("touchmove",f),document.body.removeEventListener("touchend",p)}return a(),{destroy:l}}var hd=zr,AN=ga,fd=uh,FN=hh,LN=_v,ii=uo,$N=class{constructor(e){T(this,"pluginName","CellRangeSelector"),T(this,"onBeforeCellRangeSelected",new hd("onBeforeCellRangeSelected")),T(this,"onCellRangeSelected",new hd("onCellRangeSelected")),T(this,"onCellRangeSelecting",new hd("onCellRangeSelecting")),T(this,"_grid"),T(this,"_currentlySelectedRange",null),T(this,"_canvas",null),T(this,"_decorator"),T(this,"_gridOptions"),T(this,"_activeCanvas"),T(this,"_dragging",!1),T(this,"_handler",new AN),T(this,"_options"),T(this,"_defaults",{autoScroll:!0,minIntervalToShowNextCell:30,maxIntervalToShowNextCell:600,accelerateInterval:5,selectionCss:{border:"2px dashed blue"}}),T(this,"_rowOffset",0),T(this,"_columnOffset",0),T(this,"_isRightCanvas",!1),T(this,"_isBottomCanvas",!1),T(this,"_activeViewport"),T(this,"_autoScrollTimerId"),T(this,"_draggingMouseOffset"),T(this,"_moveDistanceForOneCell"),T(this,"_xDelayForNextCell",0),T(this,"_yDelayForNextCell",0),T(this,"_viewportHeight",0),T(this,"_viewportWidth",0),T(this,"_isRowMoveRegistered",!1),T(this,"_scrollLeft",0),T(this,"_scrollTop",0),this._options=ii.extend(!0,{},this._defaults,e)}init(e){if(FN===void 0)throw new Error('Slick.Draggable is undefined, make sure to import "slick.interactions.js"');this._decorator=this._options.cellDecorator||new LN(e,this._options),this._grid=e,ii.addSlickEventPubSubWhenDefined(e.getPubSubService(),this),this._canvas=this._grid.getCanvasNode(),this._gridOptions=this._grid.getOptions(),this._handler.subscribe(this._grid.onScroll,this.handleScroll.bind(this)).subscribe(this._grid.onDragInit,this.handleDragInit.bind(this)).subscribe(this._grid.onDragStart,this.handleDragStart.bind(this)).subscribe(this._grid.onDrag,this.handleDrag.bind(this)).subscribe(this._grid.onDragEnd,this.handleDragEnd.bind(this))}destroy(){this._handler.unsubscribeAll(),this._activeCanvas=null,this._activeViewport=null,this._canvas=null,this._decorator?.destroy()}getCellDecorator(){return this._decorator}handleScroll(e,t){this._scrollTop=t.scrollTop,this._scrollLeft=t.scrollLeft}handleDragInit(e){this._activeCanvas=this._grid.getActiveCanvasNode(e),this._activeViewport=this._grid.getActiveViewportNode(e);let t=this._grid.getDisplayedScrollbarDimensions();if(this._viewportWidth=this._activeViewport.offsetWidth-t.width,this._viewportHeight=this._activeViewport.offsetHeight-t.height,this._moveDistanceForOneCell={x:this._grid.getAbsoluteColumnMinWidth()/2,y:this._grid.getOptions().rowHeight/2},this._isRowMoveRegistered=this.hasRowMoveManager(),this._rowOffset=0,this._columnOffset=0,this._isBottomCanvas=this._activeCanvas.classList.contains("grid-canvas-bottom"),this._gridOptions.frozenRow>-1&&this._isBottomCanvas){let n=`.${this._grid.getUID()} .grid-canvas-${this._gridOptions.frozenBottom?"bottom":"top"}`,o=document.querySelector(n);o&&(this._rowOffset=o.clientHeight||0)}if(this._isRightCanvas=this._activeCanvas.classList.contains("grid-canvas-right"),this._gridOptions.frozenColumn>-1&&this._isRightCanvas){let n=document.querySelector(`.${this._grid.getUID()} .grid-canvas-left`);n&&(this._columnOffset=n.clientWidth||0)}e.stopImmediatePropagation(),e.preventDefault()}handleDragStart(e,t){let n=this._grid.getCellFromEvent(e);if(n&&this.onBeforeCellRangeSelected.notify(n).getReturnValue()!==!1&&this._grid.canCellBeSelected(n.row,n.cell)&&(this._dragging=!0,e.stopImmediatePropagation()),!this._dragging)return;this._grid.focus();let o=ii.offset(this._canvas),r=t.startX-(o?.left??0);this._gridOptions.frozenColumn>=0&&this._isRightCanvas&&(r+=this._scrollLeft);let i=t.startY-(o?.top??0);this._gridOptions.frozenRow>=0&&this._isBottomCanvas&&(i+=this._scrollTop);let a=this._grid.getCellFromPoint(r,i);return t.range={start:a,end:{}},this._currentlySelectedRange=t.range,this._decorator.show(new fd(a.row,a.cell))}handleDrag(e,t){if(!this._dragging&&!this._isRowMoveRegistered)return;this._isRowMoveRegistered||e.stopImmediatePropagation();let n=e.getNativeEvent();if(this._options.autoScroll&&(this._draggingMouseOffset=this.getMouseOffsetViewport(n,t),this._draggingMouseOffset.isOutsideViewport))return this.handleDragOutsideViewport();this.stopIntervalTimer(),this.handleDragTo(n,t)}getMouseOffsetViewport(e,t){let n=e?.touches?.[0]??e,o=this._activeViewport.scrollLeft,r=this._activeViewport.scrollTop,i=o+this._viewportWidth,a=r+this._viewportHeight,l=ii.offset(this._activeViewport),d=l?.left??0,u=l?.top??0,f=d+this._viewportWidth,p=u+this._viewportHeight,y={e,dd:t,viewport:{left:o,top:r,right:i,bottom:a,offset:{left:d,top:u,right:f,bottom:p}},offset:{x:0,y:0},isOutsideViewport:!1};return n.pageX<d?y.offset.x=n.pageX-d:n.pageX>f&&(y.offset.x=n.pageX-f),n.pageY<u?y.offset.y=u-n.pageY:n.pageY>p&&(y.offset.y=p-n.pageY),y.isOutsideViewport=!!y.offset.x||!!y.offset.y,y}handleDragOutsideViewport(){if(this._xDelayForNextCell=this._options.maxIntervalToShowNextCell-Math.abs(this._draggingMouseOffset.offset.x)*this._options.accelerateInterval,this._yDelayForNextCell=this._options.maxIntervalToShowNextCell-Math.abs(this._draggingMouseOffset.offset.y)*this._options.accelerateInterval,!this._autoScrollTimerId){let e=0,t=0;this._autoScrollTimerId=window.setInterval(()=>{let n=!1,o=!1;this._draggingMouseOffset.offset.x?(e+=this._options.minIntervalToShowNextCell,n=e>=this._xDelayForNextCell):e=0,this._draggingMouseOffset.offset.y?(t+=this._options.minIntervalToShowNextCell,o=t>=this._yDelayForNextCell):t=0,(n||o)&&(n&&(e=0),o&&(t=0),this.handleDragToNewPosition(n,o))},this._options.minIntervalToShowNextCell)}}handleDragToNewPosition(e,t){let n=this._draggingMouseOffset.e.pageX,o=this._draggingMouseOffset.e.pageY,r=this._draggingMouseOffset.offset.x,i=this._draggingMouseOffset.offset.y,a=this._draggingMouseOffset.viewport.offset;e&&r&&(r>0?n=a.right+this._moveDistanceForOneCell.x:n=a.left-this._moveDistanceForOneCell.x),t&&i&&(i>0?o=a.top-this._moveDistanceForOneCell.y:o=a.bottom+this._moveDistanceForOneCell.y),this.handleDragTo({pageX:n,pageY:o},this._draggingMouseOffset.dd)}stopIntervalTimer(){this._autoScrollTimerId&&(window.clearInterval(this._autoScrollTimerId),this._autoScrollTimerId=void 0)}handleDragTo(e,t){let n=e?.touches?.[0]??e,o=ii.offset(this._activeCanvas),r=this._grid.getCellFromPoint(n.pageX-(o?.left??0)+this._columnOffset,n.pageY-(o?.top??0)+this._rowOffset);if(!(this._gridOptions.frozenColumn>=0&&!this._isRightCanvas&&r.cell>this._gridOptions.frozenColumn||this._isRightCanvas&&r.cell<=this._gridOptions.frozenColumn)&&!(this._gridOptions.frozenRow>=0&&!this._isBottomCanvas&&r.row>=this._gridOptions.frozenRow||this._isBottomCanvas&&r.row<this._gridOptions.frozenRow)){if(this._options.autoScroll&&this._draggingMouseOffset){let i=this._grid.getCellNodeBox(r.row,r.cell);if(!i)return;let a=this._draggingMouseOffset.viewport;(i.left<a.left||i.right>a.right||i.top<a.top||i.bottom>a.bottom)&&this._grid.scrollCellIntoView(r.row,r.cell)}if(this._grid.canCellBeSelected(r.row,r.cell)&&t?.range){t.range.end=r;let i=new fd(t.range.start.row??0,t.range.start.cell??0,r.row,r.cell);this._decorator.show(i),this.onCellRangeSelecting.notify({range:i})}}}hasRowMoveManager(){return!!(this._grid.getPluginByName("RowMoveManager")||this._grid.getPluginByName("CrossGridRowMoveManager"))}handleDragEnd(e,t){this._decorator.hide(),this._dragging&&(this._dragging=!1,e.stopImmediatePropagation(),this.stopIntervalTimer(),this.onCellRangeSelected.notify({range:new fd(t.range.start.row??0,t.range.start.cell??0,t.range.end.row,t.range.end.cell)}))}getCurrentRange(){return this._currentlySelectedRange}},VN=pc,jN=ga,lr=uo,BN=class{constructor(e){T(this,"pluginName","CheckboxSelectColumn"),T(this,"_dataView"),T(this,"_grid"),T(this,"_isUsingDataView",!1),T(this,"_selectableOverride",null),T(this,"_headerRowNode"),T(this,"_selectAll_UID"),T(this,"_handler",new jN),T(this,"_selectedRowsLookup",{}),T(this,"_checkboxColumnCellIndex",null),T(this,"_options"),T(this,"_defaults",{columnId:"_checkbox_selector",cssClass:void 0,hideSelectAllCheckbox:!1,name:"",toolTip:"Select/Deselect All",width:30,reorderable:!1,applySelectOnAllPages:!1,hideInColumnTitleRow:!1,hideInFilterHeaderRow:!0}),T(this,"_isSelectAllChecked",!1),T(this,"_bindingEventService"),this._bindingEventService=new VN,this._options=lr.extend(!0,{},this._defaults,e),this._selectAll_UID=this.createUID(),typeof this._options.selectableOverride=="function"&&this.selectableOverride(this._options.selectableOverride)}init(e){this._grid=e,this._isUsingDataView=!Array.isArray(e.getData()),this._isUsingDataView&&(this._dataView=e.getData()),this._handler.subscribe(this._grid.onSelectedRowsChanged,this.handleSelectedRowsChanged.bind(this)).subscribe(this._grid.onClick,this.handleClick.bind(this)).subscribe(this._grid.onKeyDown,this.handleKeyDown.bind(this)).subscribe(this._grid.onAfterSetColumns,()=>this.renderSelectAllCheckbox(this._isSelectAllChecked)),this._isUsingDataView&&this._dataView&&this._options.applySelectOnAllPages&&this._handler.subscribe(this._dataView.onSelectedRowIdsChanged,this.handleDataViewSelectedIdsChanged.bind(this)).subscribe(this._dataView.onPagingInfoChanged,this.handleDataViewSelectedIdsChanged.bind(this)),this._options.hideInFilterHeaderRow||this.addCheckboxToFilterHeaderRow(e),this._options.hideInColumnTitleRow||this._handler.subscribe(this._grid.onHeaderClick,this.handleHeaderClick.bind(this))}destroy(){this._handler.unsubscribeAll(),this._bindingEventService.unbindAll()}getOptions(){return this._options}setOptions(e){if(this._options=lr.extend(!0,{},this._options,e),this._options.hideSelectAllCheckbox)this.hideSelectAllFromColumnHeaderTitleRow(),this.hideSelectAllFromColumnHeaderFilterRow();else if(this._options.hideInColumnTitleRow?(this.hideSelectAllFromColumnHeaderTitleRow(),this._options.name&&this._grid.updateColumnHeader(this._options.columnId||"",this._options.name,"")):(this.renderSelectAllCheckbox(this._isSelectAllChecked),this._handler.subscribe(this._grid.onHeaderClick,this.handleHeaderClick.bind(this))),this._options.hideInFilterHeaderRow)this.hideSelectAllFromColumnHeaderFilterRow();else{let t=this._headerRowNode?.querySelector("#filter-checkbox-selectall-container");if(t){t.style.display="flex";let n=t.querySelector('input[type="checkbox"]');n&&(n.checked=this._isSelectAllChecked)}}}hideSelectAllFromColumnHeaderTitleRow(){this._grid.updateColumnHeader(this._options.columnId||"",this._options.name||"","")}hideSelectAllFromColumnHeaderFilterRow(){let e=this._headerRowNode?.querySelector("#filter-checkbox-selectall-container");e&&(e.style.display="none")}handleSelectedRowsChanged(){let e=this._grid.getSelectedRows(),t={},n=0,o=0,r=0,i=0;if(typeof this._selectableOverride=="function")for(r=0;r<this._grid.getDataLength();r++){let l=this._grid.getDataItem(r);this.checkSelectableOverride(o,l,this._grid)||i++}let a=[];for(o=0;o<e.length;o++){n=e[o];let l=this._grid.getDataItem(n);this.checkSelectableOverride(o,l,this._grid)?(t[n]=!0,t[n]!==this._selectedRowsLookup[n]&&(this._grid.invalidateRow(n),delete this._selectedRowsLookup[n])):a.push(n)}if(typeof this._selectedRowsLookup=="object"&&Object.keys(this._selectedRowsLookup).forEach(l=>{l!==void 0&&this._grid.invalidateRow(+l)}),this._selectedRowsLookup=t,this._grid.render(),this._isSelectAllChecked=(e?.length??0)+i>=this._grid.getDataLength(),(!this._isUsingDataView||!this._options.applySelectOnAllPages)&&(!this._options.hideInColumnTitleRow&&!this._options.hideSelectAllCheckbox&&this.renderSelectAllCheckbox(this._isSelectAllChecked),!this._options.hideInFilterHeaderRow)){let l=this._headerRowNode?.querySelector(`#header-filter-selector${this._selectAll_UID}`);l&&(l.checked=this._isSelectAllChecked)}if(a.length>0){for(o=0;o<a.length;o++){let l=e.indexOf(a[o]);e.splice(l,1)}this._grid.setSelectedRows(e,"click.cleanup")}}handleDataViewSelectedIdsChanged(){let e=this._dataView.getAllSelectedFilteredIds(),t=this._dataView.getFilteredItems(),n=0;if(typeof this._selectableOverride=="function"&&e.length>0)for(let o=0;o<this._dataView.getItemCount();o++){let r=this._dataView.getItemByIdx(o),i=this._dataView.getIdPropertyName(),a=r[i];t.findIndex(function(l){return l[i]===a})>=0&&!this.checkSelectableOverride(o,r,this._grid)&&n++}if(this._isSelectAllChecked=(e&&e.length)+n>=t.length,!this._options.hideInColumnTitleRow&&!this._options.hideSelectAllCheckbox&&this.renderSelectAllCheckbox(this._isSelectAllChecked),!this._options.hideInFilterHeaderRow){let o=this._headerRowNode?.querySelector(`#header-filter-selector${this._selectAll_UID}`);o&&(o.checked=this._isSelectAllChecked)}}handleKeyDown(e,t){e.which===32&&this._grid.getColumns()[t.cell].id===this._options.columnId&&((!this._grid.getEditorLock().isActive()||this._grid.getEditorLock().commitCurrentEdit())&&this.toggleRowSelection(t.row),e.preventDefault(),e.stopImmediatePropagation())}handleClick(e,t){if(this._grid.getColumns()[t.cell].id===this._options.columnId&&e.target.type==="checkbox"){if(this._grid.getEditorLock().isActive()&&!this._grid.getEditorLock().commitCurrentEdit()){e.preventDefault(),e.stopImmediatePropagation();return}this.toggleRowSelection(t.row),e.stopPropagation(),e.stopImmediatePropagation()}}toggleRowSelection(e){let t=this._grid.getDataItem(e);if(this.checkSelectableOverride(e,t,this._grid)){if(this._selectedRowsLookup[e]){let n=this._grid.getSelectedRows().filter(o=>o!==e);this._grid.setSelectedRows(n,"click.toggle")}else this._grid.setSelectedRows(this._grid.getSelectedRows().concat(e),"click.toggle");this._grid.setActiveCell(e,this.getCheckboxColumnCellIndex())}}selectRows(e){let t=[];for(let n=0,o=e.length;n<o;n++)this._selectedRowsLookup[e[n]]||(t[t.length]=e[n]);this._grid.setSelectedRows(this._grid.getSelectedRows().concat(t),"SlickCheckboxSelectColumn.selectRows")}deSelectRows(e){let t=[];for(let n=0,o=e.length;n<o;n++)this._selectedRowsLookup[e[n]]&&(t[t.length]=e[n]);this._grid.setSelectedRows(this._grid.getSelectedRows().filter(n=>t.indexOf(n)<0),"SlickCheckboxSelectColumn.deSelectRows")}handleHeaderClick(e,t){if(t.column.id===this._options.columnId&&e.target.type==="checkbox"){if(this._grid.getEditorLock().isActive()&&!this._grid.getEditorLock().commitCurrentEdit()){e.preventDefault(),e.stopImmediatePropagation();return}let n=e.target.checked,o=n?"click.selectAll":"click.unselectAll",r=[];if(n){for(let i=0;i<this._grid.getDataLength();i++){let a=this._grid.getDataItem(i);!a.__group&&!a.__groupTotals&&this.checkSelectableOverride(i,a,this._grid)&&r.push(i)}n=!0}if(this._isUsingDataView&&this._dataView&&this._options.applySelectOnAllPages){let i=[],a=this._dataView.getFilteredItems();for(let l=0;l<a.length;l++){let d=a[l];this.checkSelectableOverride(l,d,this._grid)&&i.push(d[this._dataView.getIdPropertyName()])}this._dataView.setSelectedIds(i,{isRowBeingAdded:n})}this._grid.setSelectedRows(r,o),e.stopPropagation(),e.stopImmediatePropagation()}}getCheckboxColumnCellIndex(){if(this._checkboxColumnCellIndex===null){this._checkboxColumnCellIndex=0;let e=this._grid.getColumns();for(let t=0;t<e.length;t++)e[t].id===this._options.columnId&&(this._checkboxColumnCellIndex=t)}return this._checkboxColumnCellIndex}createCheckboxElement(e,t=!1){let n=new DocumentFragment;return n.appendChild(lr.createDomElement("input",{id:e,type:"checkbox",checked:t,ariaChecked:String(t)})),n.appendChild(lr.createDomElement("label",{htmlFor:e})),n}getColumnDefinition(){return{id:this._options.columnId,reorderable:this._options.reorderable,name:this._options.hideSelectAllCheckbox||this._options.hideInColumnTitleRow?this._options.name||"":this.createCheckboxElement(`header-selector${this._selectAll_UID}`),toolTip:this._options.hideSelectAllCheckbox||this._options.hideInColumnTitleRow?"":this._options.toolTip,field:"sel",width:this._options.width,resizable:!1,sortable:!1,cssClass:this._options.cssClass,hideSelectAllCheckbox:this._options.hideSelectAllCheckbox,formatter:this.checkboxSelectionFormatter.bind(this),excludeFromColumnPicker:this._options.excludeFromColumnPicker??!0,excludeFromGridMenu:this._options.excludeFromGridMenu??!0,excludeFromHeaderMenu:this._options.excludeFromHeaderMenu??!0}}addCheckboxToFilterHeaderRow(e){this._handler.subscribe(e.onHeaderRowCellRendered,(t,n)=>{if(n.column.field==="sel"){lr.emptyElement(n.node);let o=lr.createDomElement("span",{id:"filter-checkbox-selectall-container",ariaChecked:"false"});o.appendChild(lr.createDomElement("input",{type:"checkbox",id:`header-filter-selector${this._selectAll_UID}`})),o.appendChild(lr.createDomElement("label",{htmlFor:`header-filter-selector${this._selectAll_UID}`})),n.node.appendChild(o),this._headerRowNode=n.node,this._bindingEventService.bind(o,"click",r=>this.handleHeaderClick(r,n))}})}createUID(){return Math.round(1e7*Math.random())}checkboxSelectionFormatter(e,t,n,o,r,i){if(r&&this.checkSelectableOverride(e,r,i)){let a=this.createUID()+e;return this.createCheckboxElement(`selector${a}`,!!this._selectedRowsLookup[e])}return null}checkSelectableOverride(e,t,n){return typeof this._selectableOverride=="function"?this._selectableOverride(e,t,n):!0}renderSelectAllCheckbox(e){this._grid.updateColumnHeader(this._options.columnId||"",this.createCheckboxElement(`header-selector${this._selectAll_UID}`,!!e),this._options.toolTip)}selectableOverride(e){this._selectableOverride=e}},WN=pc,HN=zr,zN=xN,pd=uo,YN=class{constructor(e){T(this,"pluginName","HeaderButtons"),T(this,"onCommand",new HN("onCommand")),T(this,"_grid"),T(this,"_handler",new zN),T(this,"_bindingEventService",new WN),T(this,"_defaults",{buttonCssClass:"slick-header-button"}),T(this,"_options"),this._options=pd.extend(!0,{},this._defaults,e)}init(e){this._grid=e,pd.addSlickEventPubSubWhenDefined(e.getPubSubService(),this),this._handler.subscribe(this._grid.onHeaderCellRendered,this.handleHeaderCellRendered.bind(this)).subscribe(this._grid.onBeforeHeaderCellDestroy,this.handleBeforeHeaderCellDestroy.bind(this)),this._grid.setColumns(this._grid.getColumns())}destroy(){this._handler.unsubscribeAll(),this._bindingEventService.unbindAll()}handleHeaderCellRendered(e,t){let n=t.column;if(n.header?.buttons){let o=n.header.buttons.length;for(;o--;){let r=n.header.buttons[o],i=this.runOverrideFunctionWhenExists(r.itemVisibilityOverride,t),a=this.runOverrideFunctionWhenExists(r.itemUsabilityOverride,t);if(!i)continue;Object.prototype.hasOwnProperty.call(r,"itemUsabilityOverride")&&(r.disabled=!a);let l=document.createElement("div");l.className=this._options.buttonCssClass||"",l.ariaLabel="Header Button",l.role="button",r.disabled&&l.classList.add("slick-header-button-disabled"),r.showOnHover&&l.classList.add("slick-header-button-hidden"),r.image&&(l.style.backgroundImage=`url(${r.image})`),r.cssClass&&l.classList.add(...pd.classNameToList(r.cssClass)),r.tooltip&&(l.title=r.tooltip),r.handler&&!r.disabled&&this._bindingEventService.bind(l,"click",r.handler),this._bindingEventService.bind(l,"click",this.handleButtonClick.bind(this,r,t.column)),t.node.appendChild(l)}}}handleBeforeHeaderCellDestroy(e,t){if(t.column.header?.buttons){let n=(this._options.buttonCssClass||"").replace(/(\s+)/g,".");n&&t.node.querySelectorAll(`.${n}`).forEach(o=>o.remove())}}handleButtonClick(e,t,n){let o=e.command||"",r={grid:this._grid,column:t,button:e};o&&(r.command=o),typeof e.action=="function"&&e.action.call(this,n,r),o&&!e.disabled&&(this.onCommand.notify(r,n,this),this._grid.updateColumnHeader(t.id)),n.preventDefault(),n.stopPropagation()}runOverrideFunctionWhenExists(e,t){return typeof e=="function"?e.call(this,t):!0}},UN=pc,md=_N,qN=ga,In=uo,GN=class{constructor(e){T(this,"pluginName","HeaderMenu"),T(this,"onAfterMenuShow",new md("onAfterMenuShow")),T(this,"onBeforeMenuShow",new md("onBeforeMenuShow")),T(this,"onCommand",new md("onCommand")),T(this,"_grid"),T(this,"_gridUid",""),T(this,"_handler",new qN),T(this,"_bindingEventService",new UN),T(this,"_defaults",{buttonCssClass:void 0,buttonImage:void 0,minWidth:100,autoAlign:!0,autoAlignOffset:0,subMenuOpenByEvent:"mouseover"}),T(this,"_options"),T(this,"_activeHeaderColumnElm"),T(this,"_menuElm"),T(this,"_subMenuParentId",""),this._options=In.extend(!0,{},e,this._defaults)}init(e){this._grid=e,this._gridUid=e?.getUID()||"",In.addSlickEventPubSubWhenDefined(e.getPubSubService(),this),this._handler.subscribe(this._grid.onHeaderCellRendered,this.handleHeaderCellRendered.bind(this)).subscribe(this._grid.onBeforeHeaderCellDestroy,this.handleBeforeHeaderCellDestroy.bind(this)),this._grid.setColumns(this._grid.getColumns()),this._bindingEventService.bind(document.body,"click",this.handleBodyMouseDown.bind(this))}setOptions(e){this._options=In.extend(!0,{},this._options,e)}getGridUidSelector(){let e=this._grid.getUID()||"";return e?`.${e}`:""}destroy(){this._handler.unsubscribeAll(),this._bindingEventService.unbindAll(),this._menuElm=this._menuElm||document.body.querySelector(`.slick-header-menu${this.getGridUidSelector()}`),this._menuElm?.remove(),this._activeHeaderColumnElm=void 0}destroyAllMenus(){this.destroySubMenus(),this._bindingEventService.unbindAll("parent-menu"),document.querySelectorAll(`.slick-header-menu${this.getGridUidSelector()}`).forEach(e=>e.remove())}destroySubMenus(){this._bindingEventService.unbindAll("sub-menu"),document.querySelectorAll(`.slick-header-menu.slick-submenu${this.getGridUidSelector()}`).forEach(e=>e.remove())}handleBodyMouseDown(e){let t=!1;this._menuElm?.contains(e.target)&&(t=!0),t||document.querySelectorAll(`.slick-header-menu.slick-submenu${this.getGridUidSelector()}`).forEach(n=>{n.contains(e.target)&&(t=!0)}),(this._menuElm!==e.target&&!t&&!e.defaultPrevented||e.target.className==="close")&&this.hideMenu()}hideMenu(){this._menuElm&&(this._menuElm.remove(),this._menuElm=void 0),this._activeHeaderColumnElm?.classList.remove("slick-header-column-active"),this.destroySubMenus()}handleHeaderCellRendered(e,t){let n=t.column?.header?.menu;if(n?.items&&console.warn('[SlickGrid] Header Menu "items" property was deprecated in favor of "commandItems" to align with all other Menu plugins.'),n){if(!this.runOverrideFunctionWhenExists(this._options.menuUsabilityOverride,t))return;let o=document.createElement("div");if(o.className="slick-header-menubutton",o.ariaLabel="Header Menu",o.role="button",!this._options.buttonCssClass&&!this._options.buttonImage&&(this._options.buttonCssClass="caret"),this._options.buttonCssClass){let r=document.createElement("span");r.classList.add(...In.classNameToList(this._options.buttonCssClass)),o.appendChild(r)}this._options.buttonImage&&(o.style.backgroundImage=`url(${this._options.buttonImage})`),this._options.tooltip&&(o.title=this._options.tooltip),this._bindingEventService.bind(o,"click",r=>{this.destroyAllMenus(),this.createParentMenu(r,n,t.column)}),t.node.appendChild(o)}}handleBeforeHeaderCellDestroy(e,t){t.column.header?.menu&&t.node.querySelectorAll(".slick-header-menubutton").forEach(n=>n.remove())}addSubMenuTitleWhenExists(e,t){if(e!=="divider"&&e?.subMenuTitle){let n=document.createElement("div");n.className="slick-menu-title",n.textContent=e.subMenuTitle;let o=e.subMenuTitleCssClass;o&&n.classList.add(...In.classNameToList(o)),t.appendChild(n)}}createParentMenu(e,t,n){let o={grid:this._grid,column:n,menu:t};if(this.onBeforeMenuShow.notify(o,e,this).getReturnValue()===!1)return;this._menuElm=this.createMenu(t.commandItems||t.items,n);let r=this._grid.getContainerNode();r&&r.appendChild(this._menuElm),this.repositionMenu(e,this._menuElm),this.onAfterMenuShow.notify(o,e,this).getReturnValue()!==!1&&(e.preventDefault(),e.stopPropagation())}createMenu(e,t,n=0,o){let r=n>0,i=o?.command,a=n===1&&i?i.replaceAll(" ",""):"";a&&(this._subMenuParentId=a),r&&(a=this._subMenuParentId);let l=`slick-header-menu slick-menu-level-${n} ${this._gridUid}`,d=document.body.querySelector(`.slick-header-menu.slick-menu-level-${n}${this.getGridUidSelector()}`);if(d){if(d.dataset.subMenuParent===a)return d;this.destroySubMenus()}let u=document.createElement("div");u.className=l,n>0&&(u.classList.add("slick-submenu"),a&&(u.dataset.subMenuParent=a)),u.classList.add(this._gridUid),u.role="menu",u.ariaLabel=n>1?"SubMenu":"Header Menu",u.style.minWidth=`${this._options.minWidth}px`,u.setAttribute("aria-expanded","true");let f={grid:this._grid,column:t,menu:{items:e}};o&&n>0&&this.addSubMenuTitleWhenExists(o,u);for(let p=0;p<e.length;p++){let y=!0,b=e[p],w=this.runOverrideFunctionWhenExists(b.itemVisibilityOverride,f),g=this.runOverrideFunctionWhenExists(b.itemUsabilityOverride,f);if(!w)continue;Object.prototype.hasOwnProperty.call(b,"itemUsabilityOverride")&&(b.disabled=!g);let v=document.createElement("div");v.className="slick-header-menuitem",v.role="menuitem",(b.divider||b==="divider")&&(v.classList.add("slick-header-menuitem-divider"),y=!1),b.disabled&&v.classList.add("slick-header-menuitem-disabled"),b.hidden&&v.classList.add("slick-header-menuitem-hidden"),b.cssClass&&v.classList.add(...In.classNameToList(b.cssClass)),b.tooltip&&(v.title=b.tooltip||"");let E=document.createElement("div");E.className="slick-header-menuicon",v.appendChild(E),b.iconCssClass&&E.classList.add(...In.classNameToList(b.iconCssClass)),b.iconImage&&(E.style.backgroundImage="url("+b.iconImage+")");let P=document.createElement("span");if(P.className="slick-header-menucontent",P.textContent=b.title||"",v.appendChild(P),b.textCssClass&&P.classList.add(...In.classNameToList(b.textCssClass)),u.appendChild(v),y){let x=r?"sub-menu":"parent-menu";this._bindingEventService.bind(v,"click",this.handleMenuItemClick.bind(this,b,t,n),void 0,x)}if(this._options.subMenuOpenByEvent==="mouseover"&&this._bindingEventService.bind(v,"mouseover",x=>{b.commandItems||b.items?this.repositionSubMenu(b,t,n,x):r||this.destroySubMenus()}),b.commandItems||b.items){let x=document.createElement("div");x.className="sub-item-chevron",this._options.subItemChevronClass?x.classList.add(...In.classNameToList(this._options.subItemChevronClass)):x.textContent="⮞",v.classList.add("slick-submenu-item"),v.appendChild(x)}}return u}handleMenuItemClick(e,t,n=0,o){if(e!=="divider"&&!e.disabled&&!e.divider){let r=e.command||"";if(In.isDefined(r)&&!e.commandItems&&!e.items){let i={grid:this._grid,column:t,command:r,item:e};this.onCommand.notify(i,o,this),typeof e.action=="function"&&e.action.call(this,o,i),o.defaultPrevented||this.hideMenu()}else e.commandItems||e.items?this.repositionSubMenu(e,t,n,o):this.destroySubMenus()}}repositionSubMenu(e,t,n,o){o.target.classList.contains("slick-header-menubutton")&&this.destroySubMenus();let r=this.createMenu(e.commandItems||e.items||[],t,n+1,e);document.body.appendChild(r),this.repositionMenu(o,r)}repositionMenu(e,t){let n=e.target,o=t.classList.contains("slick-submenu"),r=o?e.target.closest(".slick-header-menuitem"):n,i=In.offset(n),a=this._grid.getGridPosition(),l=t.offsetWidth,d=In.offset(this._menuElm),u=In.offset(r),f=o?u?.top??0:n.clientHeight??i?.top??0+(this._options?.menuOffsetTop??0),p=o?u?.left??0:i?.left??0;if(o&&r){let y=p+Number(l);o&&(y+=r.clientWidth);let b=document.documentElement.clientWidth;(y>=a.width||y>=b?"left":"right")=="left"?(t.classList.remove("dropright"),t.classList.add("dropleft"),p-=l):(t.classList.remove("dropleft"),t.classList.add("dropright"),o&&(p+=r.offsetWidth))}else p+t.offsetWidth>=a.width&&(p=p+n.clientWidth-t.clientWidth+(this._options.autoAlignOffset||0)),p-=d?.left??0;t.style.top=`${f}px`,t.style.left=`${p}px`,this._activeHeaderColumnElm=t.closest(".slick-header-column"),this._activeHeaderColumnElm&&this._activeHeaderColumnElm.classList.add("slick-header-column-active")}runOverrideFunctionWhenExists(e,t){return typeof e=="function"?e.call(this,t):!0}},KN=hh,gd=Lr,XN=_v,ZN=$N,QN=zr,JN=Ki,eA=ga,yd=uh,Ya=uo,tA=class{constructor(e){T(this,"pluginName","RowSelectionModel"),T(this,"onSelectedRangesChanged",new QN("onSelectedRangesChanged")),T(this,"_grid"),T(this,"_ranges",[]),T(this,"_eventHandler",new eA),T(this,"_inHandler",!1),T(this,"_selector"),T(this,"_isRowMoveManagerHandler"),T(this,"_options"),T(this,"_defaults",{selectActiveRow:!0,dragToSelect:!1,autoScrollWhenDrag:!0,cellRangeSelector:void 0}),this._options=Ya.extend(!0,{},this._defaults,e)}init(e){if(KN===void 0)throw new Error('Slick.Draggable is undefined, make sure to import "slick.interactions.js"');if(this._selector=this._options.cellRangeSelector,this._grid=e,Ya.addSlickEventPubSubWhenDefined(e.getPubSubService(),this),!this._selector&&this._options.dragToSelect){if(!XN)throw new Error("Slick.CellRangeDecorator is required when option dragToSelect set to true");this._selector=new ZN({selectionCss:{border:"none"},autoScroll:this._options.autoScrollWhenDrag})}this._eventHandler.subscribe(this._grid.onActiveCellChanged,this.wrapHandler(this.handleActiveCellChange).bind(this)),this._eventHandler.subscribe(this._grid.onKeyDown,this.wrapHandler(this.handleKeyDown).bind(this)),this._eventHandler.subscribe(this._grid.onClick,this.wrapHandler(this.handleClick).bind(this)),this._selector&&(e.registerPlugin(this._selector),this._selector.onCellRangeSelecting.subscribe(this.handleCellRangeSelected.bind(this)),this._selector.onCellRangeSelected.subscribe(this.handleCellRangeSelected.bind(this)),this._selector.onBeforeCellRangeSelected.subscribe(this.handleBeforeCellRangeSelected.bind(this)))}destroy(){this._eventHandler.unsubscribeAll(),this._selector&&(this._selector.onCellRangeSelecting.unsubscribe(this.handleCellRangeSelected.bind(this)),this._selector.onCellRangeSelected.unsubscribe(this.handleCellRangeSelected.bind(this)),this._selector.onBeforeCellRangeSelected.unsubscribe(this.handleBeforeCellRangeSelected.bind(this)),this._grid.unregisterPlugin(this._selector),this._selector.destroy&&this._selector.destroy())}wrapHandler(e){return(...t)=>{this._inHandler||(this._inHandler=!0,e.apply(this,t),this._inHandler=!1)}}rangesToRows(e){let t=[];for(let n=0;n<e.length;n++)for(let o=e[n].fromRow;o<=e[n].toRow;o++)t.push(o);return t}rowsToRanges(e){let t=[],n=this._grid.getColumns().length-1;return e.forEach(o=>t.push(new yd(o,0,o,n))),t}getRowsRange(e,t){let n,o=[];for(n=e;n<=t;n++)o.push(n);for(n=t;n<e;n++)o.push(n);return o}getSelectedRows(){return this.rangesToRows(this._ranges)}setSelectedRows(e){this.setSelectedRanges(this.rowsToRanges(e),"SlickRowSelectionModel.setSelectedRows")}setSelectedRanges(e,t="SlickRowSelectionModel.setSelectedRanges"){if((!this._ranges||this._ranges.length===0)&&(!e||e.length===0))return;this._ranges=e;let n=new JN(new CustomEvent("click",{detail:{caller:t}}),this._ranges);this.onSelectedRangesChanged.notify(this._ranges,n)}getSelectedRanges(){return this._ranges}refreshSelections(){this.setSelectedRows(this.getSelectedRows())}handleActiveCellChange(e,t){this._options.selectActiveRow&&Ya.isDefined(t.row)&&this.setSelectedRanges([new yd(t.row,0,t.row,this._grid.getColumns().length-1)])}handleKeyDown(e){let t=this._grid.getActiveCell();if(this._grid.getOptions().multiSelect&&t&&e.shiftKey&&!e.ctrlKey&&!e.altKey&&!e.metaKey&&(e.which===gd.UP||e.which===gd.DOWN)){let n=this.getSelectedRows();n.sort(function(a,l){return a-l}),n.length||(n=[t.row]);let o=n[0],r=n[n.length-1],i;if(e.which===gd.DOWN?i=t.row<r||o===r?++r:++o:i=t.row<r?--r:--o,i>=0&&i<this._grid.getDataLength()){this._grid.scrollRowIntoView(i);let a=this.rowsToRanges(this.getRowsRange(o,r));this.setSelectedRanges(a)}e.preventDefault(),e.stopPropagation()}}handleClick(e){let t=this._grid.getCellFromEvent(e);if(!t||!this._grid.canCellBeActive(t.row,t.cell)||!this._grid.getOptions().multiSelect||!e.ctrlKey&&!e.shiftKey&&!e.metaKey)return!1;let n=this.rangesToRows(this._ranges),o=n.indexOf(t.row);if(o===-1&&(e.ctrlKey||e.metaKey))n.push(t.row),this._grid.setActiveCell(t.row,t.cell);else if(o!==-1&&(e.ctrlKey||e.metaKey))n=n.filter(i=>i!==t.row),this._grid.setActiveCell(t.row,t.cell);else if(n.length&&e.shiftKey){let i=n.pop(),a=Math.min(t.row,i),l=Math.max(t.row,i);n=[];for(let d=a;d<=l;d++)d!==i&&n.push(d);n.push(i),this._grid.setActiveCell(t.row,t.cell)}let r=this.rowsToRanges(n);return this.setSelectedRanges(r),e.stopImmediatePropagation(),!0}handleBeforeCellRangeSelected(e,t){if(!this._isRowMoveManagerHandler){let n=this._grid.getPluginByName("RowMoveManager")||this._grid.getPluginByName("CrossGridRowMoveManager");this._isRowMoveManagerHandler=n?n.isHandlerColumn:Ya.noop}if(this._grid.getEditorLock().isActive()||this._isRowMoveManagerHandler(t.cell))return e.stopPropagation(),!1;this._grid.setActiveCell(t.row,t.cell)}handleCellRangeSelected(e,t){if(!this._grid.getOptions().multiSelect||!this._options.selectActiveRow)return!1;this.setSelectedRanges([new yd(t.range.fromRow,0,t.range.toRow,this._grid.getColumns().length-1)])}},nA=Lr,vd=wv,ai=uo,xv=class{constructor(e){T(this,"pluginName","GroupItemMetadataProvider"),T(this,"_grid"),T(this,"_options"),T(this,"_defaults",{checkboxSelect:!1,checkboxSelectCssClass:"slick-group-select-checkbox",checkboxSelectPlugin:null,groupCssClass:"slick-group",groupTitleCssClass:"slick-group-title",totalsCssClass:"slick-group-totals",groupFocusable:!0,totalsFocusable:!1,toggleCssClass:"slick-group-toggle",toggleExpandedCssClass:"expanded",toggleCollapsedCssClass:"collapsed",enableExpandCollapse:!0,groupFormatter:this.defaultGroupCellFormatter.bind(this),totalsFormatter:this.defaultTotalsCellFormatter.bind(this),includeHeaderTotals:!1}),this._options=ai.extend(!0,{},this._defaults,e)}get dataView(){return this._grid?.getData?.()??{}}getOptions(){return this._options}setOptions(e){ai.extend(!0,this._options,e)}defaultGroupCellFormatter(e,t,n,o,r){if(!this._options.enableExpandCollapse)return r.title;let i=`${r.level*15}px`,a=r.collapsed?this._options.toggleCollapsedCssClass:this._options.toggleExpandedCssClass,l=document.createDocumentFragment();this._options.checkboxSelect&&l.appendChild(ai.createDomElement("span",{className:`${this._options.checkboxSelectCssClass} ${r.selectChecked?"checked":"unchecked"}`})),l.appendChild(ai.createDomElement("span",{className:`${this._options.toggleCssClass} ${a}`,ariaExpanded:String(!r.collapsed),style:{marginLeft:i}}));let d=ai.createDomElement("span",{className:this._options.groupTitleCssClass||""});return d.setAttribute("level",r.level),r.title instanceof HTMLElement?d.appendChild(r.title):this._grid.applyHtmlCode(d,r.title??""),l.appendChild(d),l}defaultTotalsCellFormatter(e,t,n,o,r,i){return o?.groupTotalsFormatter?.(r,o,i)??""}init(e){this._grid=e,this._grid.onClick.subscribe(this.handleGridClick.bind(this)),this._grid.onKeyDown.subscribe(this.handleGridKeyDown.bind(this))}destroy(){this._grid&&(this._grid.onClick.unsubscribe(this.handleGridClick.bind(this)),this._grid.onKeyDown.unsubscribe(this.handleGridKeyDown.bind(this)))}handleGridClick(e,t){let n=e.target,o=this._grid.getDataItem(t.row);if(o&&o instanceof vd&&n.classList.contains(this._options.toggleCssClass||"")&&(this.handleDataViewExpandOrCollapse(o),e.stopImmediatePropagation(),e.preventDefault()),o&&o instanceof vd&&n.classList.contains(this._options.checkboxSelectCssClass||"")){o.selectChecked=!o.selectChecked,n.classList.remove(o.selectChecked?"unchecked":"checked"),n.classList.add(o.selectChecked?"checked":"unchecked");let r=this.dataView.mapItemsToRows(o.rows);o.selectChecked?this._options.checkboxSelectPlugin.selectRows(r):this._options.checkboxSelectPlugin.deSelectRows(r)}}handleGridKeyDown(e){if(this._options.enableExpandCollapse&&e.which===nA.SPACE){let t=this._grid.getActiveCell();if(t){let n=this._grid.getDataItem(t.row);n&&n instanceof vd&&(this.handleDataViewExpandOrCollapse(n),e.stopImmediatePropagation(),e.preventDefault())}}}handleDataViewExpandOrCollapse(e){let t=this._grid.getRenderedRange();this.dataView.setRefreshHints({ignoreDiffsBefore:t.top,ignoreDiffsAfter:t.bottom+1}),e.collapsed?this.dataView.expandGroup(e.groupingKey):this.dataView.collapseGroup(e.groupingKey)}getGroupRowMetadata(e,t,n){let o=e?.level;return{selectable:!1,focusable:this._options.groupFocusable,cssClasses:`${this._options.groupCssClass} slick-group-level-${o}`,formatter:this._options.includeHeaderTotals&&this._options.totalsFormatter||void 0,columns:{0:{colspan:this._options.includeHeaderTotals?"1":"*",formatter:this._options.groupFormatter,editor:null}}}}getTotalsRowMetadata(e,t,n){let o=e?.group?.level;return{selectable:!1,focusable:this._options.totalsFocusable,cssClasses:`${this._options.totalsCssClass} slick-group-level-${o}`,formatter:this._options.totalsFormatter,editor:null}}},Bo=zr,bd=Ki,nm=wv,oA=wN,Bn=uo,rA=xv,sA=class{constructor(e,t){this.externalPubSub=t,T(this,"defaults",{globalItemMetadataProvider:null,groupItemMetadataProvider:null,inlineFilters:!1,useCSPSafeFilter:!1}),T(this,"idProperty","id"),T(this,"items",[]),T(this,"rows",[]),T(this,"idxById",new Map),T(this,"rowsById"),T(this,"filter",null),T(this,"filterCSPSafe",null),T(this,"updated",null),T(this,"suspend",!1),T(this,"isBulkSuspend",!1),T(this,"bulkDeleteIds",new Map),T(this,"sortAsc",!0),T(this,"fastSortField"),T(this,"sortComparer"),T(this,"refreshHints",{}),T(this,"prevRefreshHints",{}),T(this,"filterArgs"),T(this,"filteredItems",[]),T(this,"compiledFilter"),T(this,"compiledFilterCSPSafe"),T(this,"compiledFilterWithCaching"),T(this,"compiledFilterWithCachingCSPSafe"),T(this,"filterCache",[]),T(this,"_grid"),T(this,"groupingInfoDefaults",{getter:void 0,formatter:void 0,comparer:(n,o)=>n.value===o.value?0:n.value>o.value?1:-1,predefinedValues:[],aggregators:[],aggregateEmpty:!1,aggregateCollapsed:!1,aggregateChildGroups:!1,collapsed:!1,displayTotalsRow:!0,lazyTotalsCalculation:!1}),T(this,"groupingInfos",[]),T(this,"groups",[]),T(this,"toggledGroupsByLevel",[]),T(this,"groupingDelimiter",":|:"),T(this,"selectedRowIds",[]),T(this,"preSelectedRowIdsChangeFn"),T(this,"pagesize",0),T(this,"pagenum",0),T(this,"totalRows",0),T(this,"_options"),T(this,"_container"),T(this,"onBeforePagingInfoChanged"),T(this,"onGroupExpanded"),T(this,"onGroupCollapsed"),T(this,"onPagingInfoChanged"),T(this,"onRowCountChanged"),T(this,"onRowsChanged"),T(this,"onRowsOrCountChanged"),T(this,"onSelectedRowIdsChanged"),T(this,"onSetItemsCalled"),this.onBeforePagingInfoChanged=new Bo("onBeforePagingInfoChanged",t),this.onGroupExpanded=new Bo("onGroupExpanded",t),this.onGroupCollapsed=new Bo("onGroupCollapsed",t),this.onPagingInfoChanged=new Bo("onPagingInfoChanged",t),this.onRowCountChanged=new Bo("onRowCountChanged",t),this.onRowsChanged=new Bo("onRowsChanged",t),this.onRowsOrCountChanged=new Bo("onRowsOrCountChanged",t),this.onSelectedRowIdsChanged=new Bo("onSelectedRowIdsChanged",t),this.onSetItemsCalled=new Bo("onSetItemsCalled",t),this._options=Bn.extend(!0,{},this.defaults,e)}beginUpdate(e){this.suspend=!0,this.isBulkSuspend=e===!0}endUpdate(){let e=this.isBulkSuspend;this.isBulkSuspend=!1,this.suspend=!1,e&&(this.processBulkDelete(),this.ensureIdUniqueness()),this.refresh()}destroy(){this.items=[],this.idxById=null,this.rowsById=null,this.filter=null,this.filterCSPSafe=null,this.updated=null,this.sortComparer=null,this.filterCache=[],this.filteredItems=[],this.compiledFilter=null,this.compiledFilterCSPSafe=null,this.compiledFilterWithCaching=null,this.compiledFilterWithCachingCSPSafe=null,this._grid&&this._grid.onSelectedRowsChanged&&this._grid.onCellCssStylesChanged&&(this._grid.onSelectedRowsChanged.unsubscribe(),this._grid.onCellCssStylesChanged.unsubscribe()),this.onRowsOrCountChanged&&this.onRowsOrCountChanged.unsubscribe()}setRefreshHints(e){this.refreshHints=e}getFilterArgs(){return this.filterArgs}setFilterArgs(e){this.filterArgs=e}processBulkDelete(){if(!this.idxById)return;let e,t,n=0;for(let o=0,r=this.items.length;o<r;o++){if(t=this.items[o],e=t[this.idProperty],e===void 0)throw new Error("[SlickGrid DataView] Each data element must implement a unique 'id' property");this.bulkDeleteIds.has(e)?this.idxById.delete(e):(this.items[n]=t,this.idxById.set(e,n),++n)}this.items.length=n,this.bulkDeleteIds=new Map}updateIdxById(e){if(this.isBulkSuspend||!this.idxById)return;e=e||0;let t;for(let n=e,o=this.items.length;n<o;n++){if(t=this.items[n][this.idProperty],t===void 0)throw new Error("[SlickGrid DataView] Each data element must implement a unique 'id' property");this.idxById.set(t,n)}}ensureIdUniqueness(){if(this.isBulkSuspend||!this.idxById)return;let e;for(let t=0,n=this.items.length;t<n;t++)if(e=this.items[t][this.idProperty],e===void 0||this.idxById.get(e)!==t)throw new Error("[SlickGrid DataView] Each data element must implement a unique 'id' property")}getItems(){return this.items}getIdPropertyName(){return this.idProperty}setItems(e,t){t!==void 0&&(this.idProperty=t),this.items=this.filteredItems=e,this.onSetItemsCalled.notify({idProperty:this.idProperty,itemCount:this.items.length},null,this),this.idxById=new Map,this.updateIdxById(),this.ensureIdUniqueness(),this.refresh()}setPagingOptions(e){this.onBeforePagingInfoChanged.notify(this.getPagingInfo(),null,this).getReturnValue()!==!1&&(Bn.isDefined(e.pageSize)&&(this.pagesize=e.pageSize,this.pagenum=this.pagesize?Math.min(this.pagenum,Math.max(0,Math.ceil(this.totalRows/this.pagesize)-1)):0),Bn.isDefined(e.pageNum)&&(this.pagenum=Math.min(e.pageNum,Math.max(0,Math.ceil(this.totalRows/this.pagesize)-1))),this.onPagingInfoChanged.notify(this.getPagingInfo(),null,this),this.refresh())}getPagingInfo(){let e=this.pagesize?Math.max(1,Math.ceil(this.totalRows/this.pagesize)):1;return{pageSize:this.pagesize,pageNum:this.pagenum,totalRows:this.totalRows,totalPages:e,dataView:this}}sort(e,t){this.sortAsc=t,this.sortComparer=e,this.fastSortField=null,t===!1&&this.items.reverse(),this.items.sort(e),t===!1&&this.items.reverse(),this.idxById=new Map,this.updateIdxById(),this.refresh()}fastSort(e,t){this.sortAsc=t,this.fastSortField=e,this.sortComparer=null;let n=Object.prototype.toString;Object.prototype.toString=typeof e=="function"?e:function(){return this[e]},t===!1&&this.items.reverse(),this.items.sort(),Object.prototype.toString=n,t===!1&&this.items.reverse(),this.idxById=new Map,this.updateIdxById(),this.refresh()}reSort(){this.sortComparer?this.sort(this.sortComparer,this.sortAsc):this.fastSortField&&this.fastSort(this.fastSortField,this.sortAsc)}getFilteredItems(){return this.filteredItems}getFilteredItemCount(){return this.filteredItems.length}getFilter(){return this._options.useCSPSafeFilter?this.filterCSPSafe:this.filter}setFilter(e){this.filterCSPSafe=e,this.filter=e,this._options.inlineFilters&&(this.compiledFilterCSPSafe=this.compileFilterCSPSafe,this.compiledFilterWithCachingCSPSafe=this.compileFilterWithCachingCSPSafe,this.compiledFilter=this.compileFilter(this._options.useCSPSafeFilter),this.compiledFilterWithCaching=this.compileFilterWithCaching(this._options.useCSPSafeFilter)),this.refresh()}getGrouping(){return this.groupingInfos}setGrouping(e){this._options.groupItemMetadataProvider||(this._options.groupItemMetadataProvider=new rA),this.groups=[],this.toggledGroupsByLevel=[],e=e||[],this.groupingInfos=e instanceof Array?e:[e];for(let t=0;t<this.groupingInfos.length;t++){let n=this.groupingInfos[t]=Bn.extend(!0,{},this.groupingInfoDefaults,this.groupingInfos[t]);n.getterIsAFn=typeof n.getter=="function",n.compiledAccumulators=[];let o=n.aggregators.length;for(;o--;)n.compiledAccumulators[o]=this.compileAccumulatorLoopCSPSafe(n.aggregators[o]);this.toggledGroupsByLevel[t]={}}this.refresh()}getItemByIdx(e){return this.items[e]}getIdxById(e){return this.idxById?.get(e)}ensureRowsByIdCache(){if(!this.rowsById){this.rowsById={};for(let e=0,t=this.rows.length;e<t;e++)this.rowsById[this.rows[e][this.idProperty]]=e}}getRowByItem(e){return this.ensureRowsByIdCache(),this.rowsById?.[e[this.idProperty]]}getRowById(e){return this.ensureRowsByIdCache(),this.rowsById?.[e]}getItemById(e){return this.items[this.idxById.get(e)]}mapItemsToRows(e){let t=[];this.ensureRowsByIdCache();for(let n=0,o=e.length;n<o;n++){let r=this.rowsById?.[e[n][this.idProperty]];Bn.isDefined(r)&&(t[t.length]=r)}return t}mapIdsToRows(e){let t=[];this.ensureRowsByIdCache();for(let n=0,o=e.length;n<o;n++){let r=this.rowsById?.[e[n]];Bn.isDefined(r)&&(t[t.length]=r)}return t}mapRowsToIds(e){let t=[];for(let n=0,o=e.length;n<o;n++)if(e[n]<this.rows.length){let r=this.rows[e[n]];t[t.length]=r[this.idProperty]}return t}updateSingleItem(e,t){if(this.idxById){if(!this.idxById.has(e))throw new Error("[SlickGrid DataView] Invalid id");if(e!==t[this.idProperty]){let n=t[this.idProperty];if(!Bn.isDefined(n))throw new Error("[SlickGrid DataView] Cannot update item to associate with a null id");if(this.idxById.has(n))throw new Error("[SlickGrid DataView] Cannot update item to associate with a non-unique id");this.idxById.set(n,this.idxById.get(e)),this.idxById.delete(e),this.updated?.[e]&&delete this.updated[e],e=n}this.items[this.idxById.get(e)]=t,this.updated||(this.updated={}),this.updated[e]=!0}}updateItem(e,t){this.updateSingleItem(e,t),this.refresh()}updateItems(e,t){if(e.length!==t.length)throw new Error("[SlickGrid DataView] Mismatch on the length of ids and items provided to update");for(let n=0,o=t.length;n<o;n++)this.updateSingleItem(e[n],t[n]);this.refresh()}insertItem(e,t){this.items.splice(e,0,t),this.updateIdxById(e),this.refresh()}insertItems(e,t){Array.prototype.splice.apply(this.items,[e,0].concat(t)),this.updateIdxById(e),this.refresh()}addItem(e){this.items.push(e),this.updateIdxById(this.items.length-1),this.refresh()}addItems(e){this.items=this.items.concat(e),this.updateIdxById(this.items.length-e.length),this.refresh()}deleteItem(e){if(this.idxById)if(this.isBulkSuspend)this.bulkDeleteIds.set(e,!0);else{let t=this.idxById.get(e);if(t===void 0)throw new Error("[SlickGrid DataView] Invalid id");this.idxById.delete(e),this.items.splice(t,1),this.updateIdxById(t),this.refresh()}}deleteItems(e){if(!(e.length===0||!this.idxById))if(this.isBulkSuspend)for(let t=0,n=e.length;t<n;t++){let o=e[t];if(this.idxById.get(o)===void 0)throw new Error("[SlickGrid DataView] Invalid id");this.bulkDeleteIds.set(o,!0)}else{let t=[];for(let n=0,o=e.length;n<o;n++){let r=e[n],i=this.idxById.get(r);if(i===void 0)throw new Error("[SlickGrid DataView] Invalid id");this.idxById.delete(r),t.push(i)}t.sort();for(let n=t.length-1;n>=0;--n)this.items.splice(t[n],1);this.updateIdxById(t[0]),this.refresh()}}sortedAddItem(e){if(!this.sortComparer)throw new Error("[SlickGrid DataView] sortedAddItem() requires a sort comparer, use sort()");this.insertItem(this.sortedIndex(e),e)}sortedUpdateItem(e,t){if(!this.idxById)return;if(!this.idxById.has(e)||e!==t[this.idProperty])throw new Error("[SlickGrid DataView] Invalid or non-matching id "+this.idxById.get(e));if(!this.sortComparer)throw new Error("[SlickGrid DataView] sortedUpdateItem() requires a sort comparer, use sort()");let n=this.getItemById(e);this.sortComparer(n,t)!==0?(this.deleteItem(e),this.sortedAddItem(t)):this.updateItem(e,t)}sortedIndex(e){let t=0,n=this.items.length;for(;t<n;){let o=t+n>>>1;this.sortComparer(this.items[o],e)===-1?t=o+1:n=o}return t}getItemCount(){return this.items.length}getLength(){return this.rows.length}getItem(e){let t=this.rows[e];if(t?.__group&&t.totals&&!t.totals?.initialized){let n=this.groupingInfos[t.level];n.displayTotalsRow||(this.calculateTotals(t.totals),t.title=n.formatter?n.formatter(t):t.value)}else t?.__groupTotals&&!t.initialized&&this.calculateTotals(t);return t}getItemMetadata(e){let t=this.rows[e];return t===void 0?null:this._options.globalItemMetadataProvider?.getRowMetadata?this._options.globalItemMetadataProvider.getRowMetadata(t,e):t.__group&&this._options.groupItemMetadataProvider?.getGroupRowMetadata?this._options.groupItemMetadataProvider.getGroupRowMetadata(t,e):t.__groupTotals&&this._options.groupItemMetadataProvider?.getTotalsRowMetadata?this._options.groupItemMetadataProvider.getTotalsRowMetadata(t,e):null}expandCollapseAllGroups(e,t){if(Bn.isDefined(e))this.toggledGroupsByLevel[e]={},this.groupingInfos[e].collapsed=t,t===!0?this.onGroupCollapsed.notify({level:e,groupingKey:null}):this.onGroupExpanded.notify({level:e,groupingKey:null});else for(let n=0;n<this.groupingInfos.length;n++)this.toggledGroupsByLevel[n]={},this.groupingInfos[n].collapsed=t,t===!0?this.onGroupCollapsed.notify({level:n,groupingKey:null}):this.onGroupExpanded.notify({level:n,groupingKey:null});this.refresh()}collapseAllGroups(e){this.expandCollapseAllGroups(e,!0)}expandAllGroups(e){this.expandCollapseAllGroups(e,!1)}expandCollapseGroup(e,t,n){this.toggledGroupsByLevel[e][t]=this.groupingInfos[e].collapsed^n,this.refresh()}collapseGroup(...e){let t=Array.prototype.slice.call(e)[0],n,o;e.length===1&&t.indexOf(this.groupingDelimiter)!==-1?(n=t,o=t.split(this.groupingDelimiter).length-1):(n=e.join(this.groupingDelimiter),o=e.length-1),this.expandCollapseGroup(o,n,!0),this.onGroupCollapsed.notify({level:o,groupingKey:n})}expandGroup(...e){let t=Array.prototype.slice.call(e)[0],n,o;e.length===1&&t.indexOf(this.groupingDelimiter)!==-1?(o=t.split(this.groupingDelimiter).length-1,n=t):(o=e.length-1,n=e.join(this.groupingDelimiter)),this.expandCollapseGroup(o,n,!1),this.onGroupExpanded.notify({level:o,groupingKey:n})}getGroups(){return this.groups}extractGroups(e,t){let n,o,r=[],i={},a,l=t?t.level+1:0,d=this.groupingInfos[l];for(let u=0,f=d.predefinedValues?.length??0;u<f;u++)o=d.predefinedValues?.[u],n=i[o],n||(n=new nm,n.value=o,n.level=l,n.groupingKey=(t?t.groupingKey+this.groupingDelimiter:"")+o,r[r.length]=n,i[o]=n);for(let u=0,f=e.length;u<f;u++)a=e[u],o=d.getterIsAFn?d.getter(a):a[d.getter],n=i[o],n||(n=new nm,n.value=o,n.level=l,n.groupingKey=(t?t.groupingKey+this.groupingDelimiter:"")+o,r[r.length]=n,i[o]=n),n.rows[n.count++]=a;if(l<this.groupingInfos.length-1)for(let u=0;u<r.length;u++)n=r[u],n.groups=this.extractGroups(n.rows,n);return r.length&&this.addTotals(r,l),r.sort(this.groupingInfos[l].comparer),r}calculateTotals(e){let t=e.group,n=this.groupingInfos[t.level??0],o=t.level===this.groupingInfos.length,r,i=n.aggregators.length;if(!o&&n.aggregateChildGroups){let a=t.groups?.length??0;for(;a--;)t.groups[a].totals.initialized||this.calculateTotals(t.groups[a].totals)}for(;i--;)r=n.aggregators[i],r.init(),!o&&n.aggregateChildGroups?n.compiledAccumulators[i].call(r,t.groups):n.compiledAccumulators[i].call(r,t.rows),r.storeResult(e);e.initialized=!0}addGroupTotals(e){let t=this.groupingInfos[e.level],n=new oA;n.group=e,e.totals=n,t.lazyTotalsCalculation||this.calculateTotals(n)}addTotals(e,t){t=t||0;let n=this.groupingInfos[t],o=n.collapsed,r=this.toggledGroupsByLevel[t],i=e.length,a;for(;i--;)a=e[i],!(a.collapsed&&!n.aggregateCollapsed)&&(a.groups&&this.addTotals(a.groups,t+1),n.aggregators?.length&&(n.aggregateEmpty||a.rows.length||a.groups?.length)&&this.addGroupTotals(a),a.collapsed=o^r[a.groupingKey],a.title=n.formatter?n.formatter(a):a.value)}flattenGroupedRows(e,t){t=t||0;let n=this.groupingInfos[t],o=[],r,i=0,a;for(let l=0,d=e.length;l<d;l++){if(a=e[l],o[i++]=a,!a.collapsed){r=a.groups?this.flattenGroupedRows(a.groups,t+1):a.rows;for(let u=0,f=r.length;u<f;u++)o[i++]=r[u]}a.totals&&n.displayTotalsRow&&(!a.collapsed||n.aggregateCollapsed)&&(o[i++]=a.totals)}return o}compileAccumulatorLoopCSPSafe(e){return e.accumulate?function(t){let n;for(let o=0;o<t.length;o++){let r=t[o];n=e.accumulate.call(e,r)}return n}:function(){}}compileFilterCSPSafe(e,t){if(typeof this.filterCSPSafe!="function")return[];let n=[],o=e.length;for(let r=0;r<o;r++)this.filterCSPSafe(e[r],t)&&n.push(e[r]);return n}compileFilter(e=!1){if(e)return null;let t=Bn.getFunctionDetails(this.filter),n="{ continue _coreloop; }$1",o="{ _retval[_idx++] = $item$; continue _coreloop; }$1",r=t.body.replace(/return false\s*([;}]|\}|$)/gi,n).replace(/return!1([;}]|\}|$)/gi,n).replace(/return true\s*([;}]|\}|$)/gi,o).replace(/return!0([;}]|\}|$)/gi,o).replace(/return ([^;}]+?)\s*([;}]|$)/gi,"{ if ($1) { _retval[_idx++] = $item$; }; continue _coreloop; }$2"),i=["var _retval = [], _idx = 0; ","var $item$, $args$ = _args; ","_coreloop: ","for (var _i = 0, _il = _items.length; _i < _il; _i++) { ","$item$ = _items[_i]; ","$filter$; ","} ","return _retval; "].join("");i=i.replace(/\$filter\$/gi,r),i=i.replace(/\$item\$/gi,t.params[0]),i=i.replace(/\$args\$/gi,t.params[1]);let a=new Function("_items,_args",i),l="compiledFilter";return a.displayName=l,a.name=this.setFunctionName(a,l),a}compileFilterWithCaching(e=!1){if(e)return null;let t=Bn.getFunctionDetails(this.filter),n="{ continue _coreloop; }$1",o="{ _cache[_i] = true;_retval[_idx++] = $item$; continue _coreloop; }$1",r=t.body.replace(/return false\s*([;}]|\}|$)/gi,n).replace(/return!1([;}]|\}|$)/gi,n).replace(/return true\s*([;}]|\}|$)/gi,o).replace(/return!0([;}]|\}|$)/gi,o).replace(/return ([^;}]+?)\s*([;}]|$)/gi,"{ if ((_cache[_i] = $1)) { _retval[_idx++] = $item$; }; continue _coreloop; }$2"),i=["var _retval = [], _idx = 0; ","var $item$, $args$ = _args; ","_coreloop: ","for (var _i = 0, _il = _items.length; _i < _il; _i++) { ","$item$ = _items[_i]; ","if (_cache[_i]) { ","_retval[_idx++] = $item$; ","continue _coreloop; ","} ","$filter$; ","} ","return _retval; "].join("");i=i.replace(/\$filter\$/gi,r),i=i.replace(/\$item\$/gi,t.params[0]),i=i.replace(/\$args\$/gi,t.params[1]);let a=new Function("_items,_args,_cache",i),l="compiledFilterWithCaching";return a.displayName=l,a.name=this.setFunctionName(a,l),a}compileFilterWithCachingCSPSafe(e,t,n){if(typeof this.filterCSPSafe!="function")return[];let o=[],r=e.length;for(let i=0;i<r;i++)(n[i]||this.filterCSPSafe(e[i],t))&&o.push(e[i]);return o}setFunctionName(e,t){try{Object.defineProperty(e,"name",{writable:!0,value:t})}catch{e.name=t}}uncompiledFilter(e,t){let n=[],o=0;for(let r=0,i=e.length;r<i;r++)this.filter?.(e[r],t)&&(n[o++]=e[r]);return n}uncompiledFilterWithCaching(e,t,n){let o=[],r=0,i;for(let a=0,l=e.length;a<l;a++)i=e[a],n[a]?o[r++]=i:this.filter?.(i,t)&&(o[r++]=i,n[a]=!0);return o}getFilteredAndPagedItems(e){if(this._options.useCSPSafeFilter?this.filterCSPSafe:this.filter){let n,o;this._options.useCSPSafeFilter?(n=this._options.inlineFilters?this.compiledFilterCSPSafe:this.uncompiledFilter,o=this._options.inlineFilters?this.compiledFilterWithCachingCSPSafe:this.uncompiledFilterWithCaching):(n=this._options.inlineFilters?this.compiledFilter:this.uncompiledFilter,o=this._options.inlineFilters?this.compiledFilterWithCaching:this.uncompiledFilterWithCaching),this.refreshHints.isFilterNarrowing?this.filteredItems=n.call(this,this.filteredItems,this.filterArgs):this.refreshHints.isFilterExpanding?this.filteredItems=o.call(this,e,this.filterArgs,this.filterCache):this.refreshHints.isFilterUnchanged||(this.filteredItems=n.call(this,e,this.filterArgs))}else this.filteredItems=this.pagesize?e:e.concat();let t;return this.pagesize?(this.filteredItems.length<=this.pagenum*this.pagesize&&(this.filteredItems.length===0?this.pagenum=0:this.pagenum=Math.floor((this.filteredItems.length-1)/this.pagesize)),t=this.filteredItems.slice(this.pagesize*this.pagenum,this.pagesize*this.pagenum+this.pagesize)):t=this.filteredItems,{totalRows:this.filteredItems.length,rows:t}}getRowDiffs(e,t){let n,o,r,i=[],a=0,l=Math.max(t.length,e.length);this.refreshHints?.ignoreDiffsBefore&&(a=Math.max(0,Math.min(t.length,this.refreshHints.ignoreDiffsBefore))),this.refreshHints?.ignoreDiffsAfter&&(l=Math.min(t.length,Math.max(0,this.refreshHints.ignoreDiffsAfter)));for(let d=a,u=e.length;d<l;d++)d>=u?i[i.length]=d:(n=t[d],o=e[d],(!n||this.groupingInfos.length&&(r=n.__nonDataRow||o.__nonDataRow)&&n.__group!==o.__group||n.__group&&!n.equals(o)||r&&(n.__groupTotals||o.__groupTotals)||n[this.idProperty]!==o[this.idProperty]||this.updated?.[n[this.idProperty]])&&(i[i.length]=d));return i}recalc(e){this.rowsById=void 0,(this.refreshHints.isFilterNarrowing!==this.prevRefreshHints.isFilterNarrowing||this.refreshHints.isFilterExpanding!==this.prevRefreshHints.isFilterExpanding)&&(this.filterCache=[]);let t=this.getFilteredAndPagedItems(e);this.totalRows=t.totalRows;let n=t.rows;this.groups=[],this.groupingInfos.length&&(this.groups=this.extractGroups(n),this.groups.length&&(n=this.flattenGroupedRows(this.groups)));let o=this.getRowDiffs(this.rows,n);return this.rows=n,o}refresh(){if(this.suspend)return;let e=Bn.extend(!0,{},this.getPagingInfo()),t=this.rows.length,n=this.totalRows,o=this.recalc(this.items);this.pagesize&&this.totalRows<this.pagenum*this.pagesize&&(this.pagenum=Math.max(0,Math.ceil(this.totalRows/this.pagesize)-1),o=this.recalc(this.items)),this.updated=null,this.prevRefreshHints=this.refreshHints,this.refreshHints={},n!==this.totalRows&&this.onBeforePagingInfoChanged.notify(e,null,this).getReturnValue()!==!1&&this.onPagingInfoChanged.notify(this.getPagingInfo(),null,this),t!==this.rows.length&&this.onRowCountChanged.notify({previous:t,current:this.rows.length,itemCount:this.items.length,dataView:this,callingOnRowsChanged:o.length>0},null,this),o.length>0&&this.onRowsChanged.notify({rows:o,itemCount:this.items.length,dataView:this,calledOnRowCountChanged:t!==this.rows.length},null,this),(t!==this.rows.length||o.length>0)&&this.onRowsOrCountChanged.notify({rowsDiff:o,previousRowCount:t,currentRowCount:this.rows.length,itemCount:this.items.length,rowCountChanged:t!==this.rows.length,rowsChanged:o.length>0,dataView:this},null,this)}syncGridSelection(e,t,n){this._grid=e;let o;this.selectedRowIds=this.mapRowsToIds(e.getSelectedRows());let r=a=>{a===!1?this.selectedRowIds=[]:this.selectedRowIds.sort().join(",")!==a.sort().join(",")&&(this.selectedRowIds=a)},i=()=>{if((this.selectedRowIds||[]).length>0&&!o){o=!0;let a=this.mapIdsToRows(this.selectedRowIds||[]);if(!t){let l={grid:this._grid,ids:this.mapRowsToIds(a),rows:a,dataView:this};this.preSelectedRowIdsChangeFn(l),this.onSelectedRowIdsChanged.notify(Object.assign(l,{selectedRowIds:this.selectedRowIds,filteredIds:this.getAllSelectedFilteredIds()}),new bd,this)}e.setSelectedRows(a),o=!1}};return e.onSelectedRowsChanged.subscribe((a,l)=>{if(!o){let d=this.mapRowsToIds(l.rows),u={grid:this._grid,ids:d,rows:l.rows,added:!0,dataView:this};this.preSelectedRowIdsChangeFn(u),this.onSelectedRowIdsChanged.notify(Object.assign(u,{selectedRowIds:this.selectedRowIds,filteredIds:this.getAllSelectedFilteredIds()}),new bd,this)}}),this.preSelectedRowIdsChangeFn=a=>{if(!o){if(o=!0,typeof a.added>"u")r(a.ids);else{let l;if(a.added)n&&e.getOptions().multiSelect?l=(this.selectedRowIds?.filter(d=>this.getRowById(d)===void 0)).concat(a.ids):l=a.ids;else if(n&&e.getOptions().multiSelect){let d=new Set(a.ids);l=this.selectedRowIds?.filter(u=>!d.has(u))}else l=[];r(l)}o=!1}},this.onRowsOrCountChanged.subscribe(i.bind(this)),this.onSelectedRowIdsChanged}getAllSelectedIds(){return this.selectedRowIds}getAllSelectedFilteredIds(){return this.getAllSelectedFilteredItems().map(e=>e[this.idProperty])}setSelectedIds(e,t){let n=t?.isRowBeingAdded,o=t?.shouldTriggerEvent,r=t?.applyRowSelectionToGrid;n!==!1&&(n=!0);let i=this.mapIdsToRows(e),a={grid:this._grid,ids:e,rows:i,added:n,dataView:this};this.preSelectedRowIdsChangeFn?.(a),o!==!1&&this.onSelectedRowIdsChanged.notify(Object.assign(a,{selectedRowIds:this.selectedRowIds,filteredIds:this.getAllSelectedFilteredIds()}),new bd,this),r!==!1&&this._grid&&this._grid.setSelectedRows(i)}getAllSelectedItems(){let e=[];return this.getAllSelectedIds().forEach(t=>{e.push(this.getItemById(t))}),e}getAllSelectedFilteredItems(){if(!Array.isArray(this.selectedRowIds))return[];let e=new Set(this.selectedRowIds);return this.filteredItems.filter(t=>e.has(t[this.idProperty]))||[]}syncGridCellCssStyles(e,t){let n,o,r=a=>{n={},typeof a=="object"&&Object.keys(a).forEach(l=>{if(a){let d=this.rows[l][this.idProperty];n[d]=a[l]}})};r(e.getCellCssStyles(t));let i=()=>{if(typeof n=="object"){o=!0,this.ensureRowsByIdCache();let a={};Object.keys(n).forEach(l=>{let d=this.rowsById?.[l];Bn.isDefined(d)&&(a[d]=n[l])}),e.setCellCssStyles(t,a),o=!1}};e.onCellCssStylesChanged.subscribe((a,l)=>{o||t===l.key&&(l.hash?r(l.hash):(e.onCellCssStylesChanged.unsubscribe(),this.onRowsOrCountChanged.unsubscribe(i)))}),this.onRowsOrCountChanged.subscribe(i.bind(this))}},Rl=Lr,wd=uo,eu=class tu{constructor(t){this.args=t,T(this,"input"),T(this,"defaultValue"),T(this,"navOnLR"),this.init()}init(){this.navOnLR=this.args.grid.getOptions().editorCellNavOnLRKeys,this.input=wd.createDomElement("input",{type:"text",className:"editor-text"},this.args.container),this.input.addEventListener("keydown",this.navOnLR?rm:sm),this.input.focus(),this.input.select(),this.args.compositeEditorOptions&&this.input.addEventListener("change",this.onChange.bind(this))}onChange(){let t=this.args.grid.getActiveCell();this.validate().valid&&this.applyValue(this.args.item,this.serializeValue()),this.applyValue(this.args.compositeEditorOptions.formValues,this.serializeValue()),this.args.grid.onCompositeEditorChange.notify({row:t?.row??0,cell:t?.cell??0,item:this.args.item,column:this.args.column,formValues:this.args.compositeEditorOptions.formValues,grid:this.args.grid,editors:this.args.compositeEditorOptions.editors})}destroy(){this.input.removeEventListener("keydown",this.navOnLR?rm:sm),this.input.removeEventListener("change",this.onChange.bind(this)),this.input.remove()}focus(){this.input.focus()}getDecimalPlaces(){let t=this.args.column.editorFixedDecimalPlaces;return wd.isDefined(t)||(t=tu.DefaultDecimalPlaces),!t&&t!==0?null:t}loadValue(t){this.defaultValue=t[this.args.column.field];let n=this.getDecimalPlaces();n!==null&&(this.defaultValue||this.defaultValue===0)&&this.defaultValue?.toFixed&&(this.defaultValue=this.defaultValue.toFixed(n)),this.input.value=String(this.defaultValue??""),this.input.defaultValue=String(this.defaultValue??""),this.input.select()}serializeValue(){let t=parseFloat(this.input.value);tu.AllowEmptyValue?!t&&t!==0&&(t=void 0):t=t||0;let n=this.getDecimalPlaces();return n!==null&&(t||t===0)&&t.toFixed&&(t=parseFloat(t.toFixed(n))),t}applyValue(t,n){t[this.args.column.field]=n}isValueChanged(){return!(this.input.value===""&&!wd.isDefined(this.defaultValue))&&this.input.value!==this.defaultValue}validate(){if(isNaN(this.input.value))return{valid:!1,msg:"Please enter a valid number"};if(this.args.column.validator){let t=this.args.column.validator(this.input.value,this.args);if(!t.valid)return t}return{valid:!0,msg:null}}};T(eu,"DefaultDecimalPlaces"),T(eu,"AllowEmptyValue",!1);var om=eu;function rm(e){let t=e.selectionStart,n=e.target.value.length;(e.keyCode===Rl.LEFT&&t>0||e.keyCode===Rl.RIGHT&&t<n-1)&&e.stopImmediatePropagation()}function sm(e){(e.keyCode===Rl.LEFT||e.keyCode===Rl.RIGHT)&&e.stopImmediatePropagation()}var iA=pc,cr=TN,Fe=zr,li=Ki,aA=RN,_n=Sv,go=Lr,lA=kN,cA=uh,cs=EN,Rr=PN,L=uo,Cd=DN,im=hh,am=IN,lm=NN,dA=class{constructor(e,t,n,o,r){if(this.container=e,this.data=t,this.columns=n,this.externalPubSub=r,T(this,"slickGridVersion","5.15.5"),T(this,"cid",""),T(this,"onActiveCellChanged"),T(this,"onActiveCellPositionChanged"),T(this,"onAddNewRow"),T(this,"onAfterSetColumns"),T(this,"onAutosizeColumns"),T(this,"onBeforeAppendCell"),T(this,"onBeforeCellEditorDestroy"),T(this,"onBeforeColumnsResize"),T(this,"onBeforeDestroy"),T(this,"onBeforeEditCell"),T(this,"onBeforeFooterRowCellDestroy"),T(this,"onBeforeHeaderCellDestroy"),T(this,"onBeforeHeaderRowCellDestroy"),T(this,"onBeforeRemoveCachedRow"),T(this,"onBeforeSetColumns"),T(this,"onBeforeSort"),T(this,"onBeforeUpdateColumns"),T(this,"onCellChange"),T(this,"onCellCssStylesChanged"),T(this,"onClick"),T(this,"onColumnsReordered"),T(this,"onColumnsDrag"),T(this,"onColumnsResized"),T(this,"onColumnsResizeDblClick"),T(this,"onCompositeEditorChange"),T(this,"onContextMenu"),T(this,"onDrag"),T(this,"onDblClick"),T(this,"onDragInit"),T(this,"onDragStart"),T(this,"onDragEnd"),T(this,"onFooterClick"),T(this,"onFooterContextMenu"),T(this,"onFooterRowCellRendered"),T(this,"onHeaderCellRendered"),T(this,"onHeaderClick"),T(this,"onHeaderContextMenu"),T(this,"onHeaderMouseEnter"),T(this,"onHeaderMouseLeave"),T(this,"onHeaderRowCellRendered"),T(this,"onHeaderRowMouseEnter"),T(this,"onHeaderRowMouseLeave"),T(this,"onPreHeaderContextMenu"),T(this,"onPreHeaderClick"),T(this,"onKeyDown"),T(this,"onMouseEnter"),T(this,"onMouseLeave"),T(this,"onRendered"),T(this,"onScroll"),T(this,"onSelectedRowsChanged"),T(this,"onSetOptions"),T(this,"onActivateChangedOptions"),T(this,"onSort"),T(this,"onValidationError"),T(this,"onViewportChanged"),T(this,"scrollbarDimensions"),T(this,"maxSupportedCssHeight"),T(this,"canvas",null),T(this,"canvas_context",null),T(this,"_options"),T(this,"_defaults",{alwaysShowVerticalScroll:!1,alwaysAllowHorizontalScroll:!1,explicitInitialization:!1,rowHeight:25,defaultColumnWidth:80,enableHtmlRendering:!0,enableAddRow:!1,leaveSpaceForNewRows:!1,editable:!1,autoEdit:!0,autoEditNewRow:!0,autoCommitEdit:!1,suppressActiveCellChangeOnEdit:!1,enableCellNavigation:!0,enableColumnReorder:!0,unorderableColumnCssClass:"unorderable",asyncEditorLoading:!1,asyncEditorLoadDelay:100,forceFitColumns:!1,enableAsyncPostRender:!1,asyncPostRenderDelay:50,enableAsyncPostRenderCleanup:!1,asyncPostRenderCleanupDelay:40,auto:!1,nonce:"",editorLock:aA,showColumnHeader:!0,showHeaderRow:!1,headerRowHeight:25,createFooterRow:!1,showFooterRow:!1,footerRowHeight:25,createPreHeaderPanel:!1,createTopHeaderPanel:!1,showPreHeaderPanel:!1,showTopHeaderPanel:!1,preHeaderPanelHeight:25,showTopPanel:!1,topPanelHeight:25,preHeaderPanelWidth:"auto",topHeaderPanelHeight:25,topHeaderPanelWidth:"auto",formatterFactory:null,editorFactory:null,cellFlashingCssClass:"flashing",rowHighlightCssClass:"highlight-animate",rowHighlightDuration:400,selectedCellCssClass:"selected",multiSelect:!0,enableCellRowSpan:!1,enableTextSelectionOnCells:!1,dataItemColumnValueExtractor:null,frozenBottom:!1,frozenColumn:-1,frozenRow:-1,frozenRightViewportMinWidth:100,throwWhenFrozenNotAllViewable:!1,fullWidthRows:!1,multiColumnSort:!1,numberedMultiColumnSort:!1,tristateMultiColumnSort:!1,sortColNumberInSeparateSpan:!1,defaultFormatter:this.defaultFormatter,forceSyncScrolling:!1,addNewRowCssClass:"new-row",preserveCopiedSelectionOnPaste:!1,preventDragFromKeys:["ctrlKey","metaKey"],showCellSelection:!0,viewportClass:void 0,minRowBuffer:3,emulatePagingWhenScrolling:!0,editorCellNavOnLRKeys:!1,enableMouseWheelScrollHandler:!0,doPaging:!0,autosizeColsMode:_n.LegacyOff,autosizeColPaddingPx:4,rowTopOffsetRenderType:"top",scrollRenderThrottling:10,autosizeTextAvgToMWidthRatio:.75,viewportSwitchToScrollModeWidthPercent:void 0,viewportMinWidthPx:void 0,viewportMaxWidthPx:void 0,suppressCssChangesOnHiddenInit:!1,ffMaxSupportedCssHeight:6e6,maxSupportedCssHeight:1e9,maxPartialRowSpanRemap:5e3,sanitizer:void 0,logSanitizedHtml:!1,mixinDefaults:!0,shadowRoot:void 0}),T(this,"_columnDefaults",{name:"",headerCssClass:null,defaultSortAsc:!0,focusable:!0,hidden:!1,minWidth:30,maxWidth:void 0,rerenderOnResize:!1,reorderable:!0,resizable:!0,sortable:!1,selectable:!0}),T(this,"_columnAutosizeDefaults",{ignoreHeaderText:!1,colValueArray:void 0,allowAddlPercent:void 0,formatterOverride:void 0,autosizeMode:cr.ContentIntelligent,rowSelectionModeOnInit:void 0,rowSelectionMode:cs.FirstNRows,rowSelectionCount:100,valueFilterMode:Rr.None,widthEvalMode:Cd.Auto,sizeToRemaining:void 0,widthPx:void 0,contentSizePx:0,headerWidthPx:0,colDataTypeOf:void 0}),T(this,"_columnResizeTimer"),T(this,"_executionBlockTimer"),T(this,"_flashCellTimer"),T(this,"_highlightRowTimer"),T(this,"th"),T(this,"h"),T(this,"ph"),T(this,"n"),T(this,"cj"),T(this,"page",0),T(this,"offset",0),T(this,"vScrollDir",1),T(this,"_bindingEventService",new iA),T(this,"initialized",!1),T(this,"_container"),T(this,"uid",`slickgrid_${Math.round(1e6*Math.random())}`),T(this,"_focusSink"),T(this,"_focusSink2"),T(this,"_groupHeaders",[]),T(this,"_headerScroller",[]),T(this,"_headers",[]),T(this,"_headerRows"),T(this,"_headerRowScroller"),T(this,"_headerRowSpacerL"),T(this,"_headerRowSpacerR"),T(this,"_footerRow"),T(this,"_footerRowScroller"),T(this,"_footerRowSpacerL"),T(this,"_footerRowSpacerR"),T(this,"_preHeaderPanel"),T(this,"_preHeaderPanelScroller"),T(this,"_preHeaderPanelSpacer"),T(this,"_preHeaderPanelR"),T(this,"_preHeaderPanelScrollerR"),T(this,"_preHeaderPanelSpacerR"),T(this,"_topHeaderPanel"),T(this,"_topHeaderPanelScroller"),T(this,"_topHeaderPanelSpacer"),T(this,"_topPanelScrollers"),T(this,"_topPanels"),T(this,"_viewport"),T(this,"_canvas"),T(this,"_style"),T(this,"_boundAncestors",[]),T(this,"stylesheet"),T(this,"columnCssRulesL"),T(this,"columnCssRulesR"),T(this,"viewportH",0),T(this,"viewportW",0),T(this,"canvasWidth",0),T(this,"canvasWidthL",0),T(this,"canvasWidthR",0),T(this,"headersWidth",0),T(this,"headersWidthL",0),T(this,"headersWidthR",0),T(this,"viewportHasHScroll",!1),T(this,"viewportHasVScroll",!1),T(this,"headerColumnWidthDiff",0),T(this,"headerColumnHeightDiff",0),T(this,"cellWidthDiff",0),T(this,"cellHeightDiff",0),T(this,"absoluteColumnMinWidth"),T(this,"hasFrozenRows",!1),T(this,"frozenRowsHeight",0),T(this,"actualFrozenRow",-1),T(this,"paneTopH",0),T(this,"paneBottomH",0),T(this,"viewportTopH",0),T(this,"viewportBottomH",0),T(this,"topPanelH",0),T(this,"headerRowH",0),T(this,"footerRowH",0),T(this,"tabbingDirection",1),T(this,"_activeCanvasNode"),T(this,"_activeViewportNode"),T(this,"activePosX"),T(this,"activePosY"),T(this,"activeRow"),T(this,"activeCell"),T(this,"activeCellNode",null),T(this,"currentEditor",null),T(this,"serializedEditorValue"),T(this,"editController"),T(this,"_prevDataLength",0),T(this,"_prevInvalidatedRowsCount",0),T(this,"_rowSpanIsCached",!1),T(this,"_colsWithRowSpanCache",{}),T(this,"rowsCache",{}),T(this,"renderedRows",0),T(this,"numVisibleRows",0),T(this,"prevScrollTop",0),T(this,"scrollHeight",0),T(this,"scrollTop",0),T(this,"lastRenderedScrollTop",0),T(this,"lastRenderedScrollLeft",0),T(this,"prevScrollLeft",0),T(this,"scrollLeft",0),T(this,"selectionModel"),T(this,"selectedRows",[]),T(this,"plugins",[]),T(this,"cellCssClasses",{}),T(this,"columnsById",{}),T(this,"sortColumns",[]),T(this,"columnPosLeft",[]),T(this,"columnPosRight",[]),T(this,"pagingActive",!1),T(this,"pagingIsLastPage",!1),T(this,"scrollThrottle"),T(this,"h_editorLoader"),T(this,"h_postrender"),T(this,"h_postrenderCleanup"),T(this,"postProcessedRows",{}),T(this,"postProcessToRow",null),T(this,"postProcessFromRow",null),T(this,"postProcessedCleanupQueue",[]),T(this,"postProcessgroupId",0),T(this,"counter_rows_rendered",0),T(this,"counter_rows_removed",0),T(this,"_paneHeaderL"),T(this,"_paneHeaderR"),T(this,"_paneTopL"),T(this,"_paneTopR"),T(this,"_paneBottomL"),T(this,"_paneBottomR"),T(this,"_headerScrollerL"),T(this,"_headerScrollerR"),T(this,"_headerL"),T(this,"_headerR"),T(this,"_groupHeadersL"),T(this,"_groupHeadersR"),T(this,"_headerRowScrollerL"),T(this,"_headerRowScrollerR"),T(this,"_footerRowScrollerL"),T(this,"_footerRowScrollerR"),T(this,"_headerRowL"),T(this,"_headerRowR"),T(this,"_footerRowL"),T(this,"_footerRowR"),T(this,"_topPanelScrollerL"),T(this,"_topPanelScrollerR"),T(this,"_topPanelL"),T(this,"_topPanelR"),T(this,"_viewportTopL"),T(this,"_viewportTopR"),T(this,"_viewportBottomL"),T(this,"_viewportBottomR"),T(this,"_canvasTopL"),T(this,"_canvasTopR"),T(this,"_canvasBottomL"),T(this,"_canvasBottomR"),T(this,"_viewportScrollContainerX"),T(this,"_viewportScrollContainerY"),T(this,"_headerScrollContainer"),T(this,"_headerRowScrollContainer"),T(this,"_footerRowScrollContainer"),T(this,"cssShow",{position:"absolute",visibility:"hidden",display:"block"}),T(this,"_hiddenParents",[]),T(this,"oldProps",[]),T(this,"enforceFrozenRowHeightRecalc",!1),T(this,"columnResizeDragging",!1),T(this,"slickDraggableInstance",null),T(this,"slickMouseWheelInstances",[]),T(this,"slickResizableInstances",[]),T(this,"sortableSideLeftInstance"),T(this,"sortableSideRightInstance"),T(this,"logMessageCount",0),T(this,"logMessageMaxCount",30),T(this,"_pubSubService"),this._container=typeof this.container=="string"?document.querySelector(this.container):this.container,!this._container)throw new Error(`SlickGrid requires a valid container, ${this.container} does not exist in the DOM.`);this._pubSubService=r,this.onActiveCellChanged=new Fe("onActiveCellChanged",r),this.onActiveCellPositionChanged=new Fe("onActiveCellPositionChanged",r),this.onAddNewRow=new Fe("onAddNewRow",r),this.onAfterSetColumns=new Fe("onAfterSetColumns",r),this.onAutosizeColumns=new Fe("onAutosizeColumns",r),this.onBeforeAppendCell=new Fe("onBeforeAppendCell",r),this.onBeforeCellEditorDestroy=new Fe("onBeforeCellEditorDestroy",r),this.onBeforeColumnsResize=new Fe("onBeforeColumnsResize",r),this.onBeforeDestroy=new Fe("onBeforeDestroy",r),this.onBeforeEditCell=new Fe("onBeforeEditCell",r),this.onBeforeFooterRowCellDestroy=new Fe("onBeforeFooterRowCellDestroy",r),this.onBeforeHeaderCellDestroy=new Fe("onBeforeHeaderCellDestroy",r),this.onBeforeHeaderRowCellDestroy=new Fe("onBeforeHeaderRowCellDestroy",r),this.onBeforeRemoveCachedRow=new Fe("onRowRemovedFromCache",r),this.onBeforeSetColumns=new Fe("onBeforeSetColumns",r),this.onBeforeSort=new Fe("onBeforeSort",r),this.onBeforeUpdateColumns=new Fe("onBeforeUpdateColumns",r),this.onCellChange=new Fe("onCellChange",r),this.onCellCssStylesChanged=new Fe("onCellCssStylesChanged",r),this.onClick=new Fe("onClick",r),this.onColumnsReordered=new Fe("onColumnsReordered",r),this.onColumnsDrag=new Fe("onColumnsDrag",r),this.onColumnsResized=new Fe("onColumnsResized",r),this.onColumnsResizeDblClick=new Fe("onColumnsResizeDblClick",r),this.onCompositeEditorChange=new Fe("onCompositeEditorChange",r),this.onContextMenu=new Fe("onContextMenu",r),this.onDrag=new Fe("onDrag",r),this.onDblClick=new Fe("onDblClick",r),this.onDragInit=new Fe("onDragInit",r),this.onDragStart=new Fe("onDragStart",r),this.onDragEnd=new Fe("onDragEnd",r),this.onFooterClick=new Fe("onFooterClick",r),this.onFooterContextMenu=new Fe("onFooterContextMenu",r),this.onFooterRowCellRendered=new Fe("onFooterRowCellRendered",r),this.onHeaderCellRendered=new Fe("onHeaderCellRendered",r),this.onHeaderClick=new Fe("onHeaderClick",r),this.onHeaderContextMenu=new Fe("onHeaderContextMenu",r),this.onHeaderMouseEnter=new Fe("onHeaderMouseEnter",r),this.onHeaderMouseLeave=new Fe("onHeaderMouseLeave",r),this.onHeaderRowCellRendered=new Fe("onHeaderRowCellRendered",r),this.onHeaderRowMouseEnter=new Fe("onHeaderRowMouseEnter",r),this.onHeaderRowMouseLeave=new Fe("onHeaderRowMouseLeave",r),this.onPreHeaderClick=new Fe("onPreHeaderClick",r),this.onPreHeaderContextMenu=new Fe("onPreHeaderContextMenu",r),this.onKeyDown=new Fe("onKeyDown",r),this.onMouseEnter=new Fe("onMouseEnter",r),this.onMouseLeave=new Fe("onMouseLeave",r),this.onRendered=new Fe("onRendered",r),this.onScroll=new Fe("onScroll",r),this.onSelectedRowsChanged=new Fe("onSelectedRowsChanged",r),this.onSetOptions=new Fe("onSetOptions",r),this.onActivateChangedOptions=new Fe("onActivateChangedOptions",r),this.onSort=new Fe("onSort",r),this.onValidationError=new Fe("onValidationError",r),this.onViewportChanged=new Fe("onViewportChanged",r),this.initialize(o)}init(){this.finishInitialization()}initialize(e){if(e?.mixinDefaults?(this._options||(this._options=e),L.applyDefaults(this._options,this._defaults)):this._options=L.extend(!0,{},this._defaults,e),this.scrollThrottle=this.actionThrottle(this.render.bind(this),this._options.scrollRenderThrottling),this.maxSupportedCssHeight=this.maxSupportedCssHeight||this.getMaxSupportedCssHeight(),this.validateAndEnforceOptions(),this._columnDefaults.width=this._options.defaultColumnWidth,this._options.suppressCssChangesOnHiddenInit||this.cacheCssForHiddenInit(),this.updateColumnProps(),this._options.enableColumnReorder&&(!Sortable||!Sortable.create))throw new Error("SlickGrid requires Sortable.js module to be loaded");this.editController={commitCurrentEdit:this.commitCurrentEdit.bind(this),cancelCurrentEdit:this.cancelCurrentEdit.bind(this)},L.emptyElement(this._container),this._container.style.outline=String(0),this._container.classList.add(this.uid),this._container.classList.add("ui-widget"),this._container.setAttribute("role","grid");let t=window.getComputedStyle(this._container);/relative|absolute|fixed/.test(t.position)||(this._container.style.position="relative"),this._focusSink=L.createDomElement("div",{tabIndex:0,style:{position:"fixed",width:"0px",height:"0px",top:"0px",left:"0px",outline:"0px"}},this._container),this._options.createTopHeaderPanel&&(this._topHeaderPanelScroller=L.createDomElement("div",{className:"slick-topheader-panel slick-state-default",style:{overflow:"hidden",position:"relative"}},this._container),this._topHeaderPanelScroller.appendChild(document.createElement("div")),this._topHeaderPanel=L.createDomElement("div",null,this._topHeaderPanelScroller),this._topHeaderPanelSpacer=L.createDomElement("div",{style:{display:"block",height:"1px",position:"absolute",top:"0px",left:"0px"}},this._topHeaderPanelScroller),this._options.showTopHeaderPanel||L.hide(this._topHeaderPanelScroller)),this._paneHeaderL=L.createDomElement("div",{className:"slick-pane slick-pane-header slick-pane-left",tabIndex:0},this._container),this._paneHeaderR=L.createDomElement("div",{className:"slick-pane slick-pane-header slick-pane-right",tabIndex:0},this._container),this._paneTopL=L.createDomElement("div",{className:"slick-pane slick-pane-top slick-pane-left",tabIndex:0},this._container),this._paneTopR=L.createDomElement("div",{className:"slick-pane slick-pane-top slick-pane-right",tabIndex:0},this._container),this._paneBottomL=L.createDomElement("div",{className:"slick-pane slick-pane-bottom slick-pane-left",tabIndex:0},this._container),this._paneBottomR=L.createDomElement("div",{className:"slick-pane slick-pane-bottom slick-pane-right",tabIndex:0},this._container),this._options.createPreHeaderPanel&&(this._preHeaderPanelScroller=L.createDomElement("div",{className:"slick-preheader-panel ui-state-default slick-state-default",style:{overflow:"hidden",position:"relative"}},this._paneHeaderL),this._preHeaderPanelScroller.appendChild(document.createElement("div")),this._preHeaderPanel=L.createDomElement("div",null,this._preHeaderPanelScroller),this._preHeaderPanelSpacer=L.createDomElement("div",{style:{display:"block",height:"1px",position:"absolute",top:"0px",left:"0px"}},this._preHeaderPanelScroller),this._preHeaderPanelScrollerR=L.createDomElement("div",{className:"slick-preheader-panel ui-state-default slick-state-default",style:{overflow:"hidden",position:"relative"}},this._paneHeaderR),this._preHeaderPanelR=L.createDomElement("div",null,this._preHeaderPanelScrollerR),this._preHeaderPanelSpacerR=L.createDomElement("div",{style:{display:"block",height:"1px",position:"absolute",top:"0px",left:"0px"}},this._preHeaderPanelScrollerR),this._options.showPreHeaderPanel||(L.hide(this._preHeaderPanelScroller),L.hide(this._preHeaderPanelScrollerR))),this._headerScrollerL=L.createDomElement("div",{className:"slick-header ui-state-default slick-state-default slick-header-left"},this._paneHeaderL),this._headerScrollerR=L.createDomElement("div",{className:"slick-header ui-state-default slick-state-default slick-header-right"},this._paneHeaderR),this._headerScroller.push(this._headerScrollerL),this._headerScroller.push(this._headerScrollerR),this._headerL=L.createDomElement("div",{className:"slick-header-columns slick-header-columns-left",role:"row",style:{left:"-1000px"}},this._headerScrollerL),this._headerR=L.createDomElement("div",{className:"slick-header-columns slick-header-columns-right",role:"row",style:{left:"-1000px"}},this._headerScrollerR),this._headers=[this._headerL,this._headerR],this._headerRowScrollerL=L.createDomElement("div",{className:"slick-headerrow ui-state-default slick-state-default"},this._paneTopL),this._headerRowScrollerR=L.createDomElement("div",{className:"slick-headerrow ui-state-default slick-state-default"},this._paneTopR),this._headerRowScroller=[this._headerRowScrollerL,this._headerRowScrollerR],this._headerRowSpacerL=L.createDomElement("div",{style:{display:"block",height:"1px",position:"absolute",top:"0px",left:"0px"}},this._headerRowScrollerL),this._headerRowSpacerR=L.createDomElement("div",{style:{display:"block",height:"1px",position:"absolute",top:"0px",left:"0px"}},this._headerRowScrollerR),this._headerRowL=L.createDomElement("div",{className:"slick-headerrow-columns slick-headerrow-columns-left"},this._headerRowScrollerL),this._headerRowR=L.createDomElement("div",{className:"slick-headerrow-columns slick-headerrow-columns-right"},this._headerRowScrollerR),this._headerRows=[this._headerRowL,this._headerRowR],this._topPanelScrollerL=L.createDomElement("div",{className:"slick-top-panel-scroller ui-state-default slick-state-default"},this._paneTopL),this._topPanelScrollerR=L.createDomElement("div",{className:"slick-top-panel-scroller ui-state-default slick-state-default"},this._paneTopR),this._topPanelScrollers=[this._topPanelScrollerL,this._topPanelScrollerR],this._topPanelL=L.createDomElement("div",{className:"slick-top-panel",style:{width:"10000px"}},this._topPanelScrollerL),this._topPanelR=L.createDomElement("div",{className:"slick-top-panel",style:{width:"10000px"}},this._topPanelScrollerR),this._topPanels=[this._topPanelL,this._topPanelR],this._options.showColumnHeader||this._headerScroller.forEach(o=>{L.hide(o)}),this._options.showTopPanel||this._topPanelScrollers.forEach(o=>{L.hide(o)}),this._options.showHeaderRow||this._headerRowScroller.forEach(o=>{L.hide(o)}),this._viewportTopL=L.createDomElement("div",{className:"slick-viewport slick-viewport-top slick-viewport-left",tabIndex:0},this._paneTopL),this._viewportTopR=L.createDomElement("div",{className:"slick-viewport slick-viewport-top slick-viewport-right",tabIndex:0},this._paneTopR),this._viewportBottomL=L.createDomElement("div",{className:"slick-viewport slick-viewport-bottom slick-viewport-left",tabIndex:0},this._paneBottomL),this._viewportBottomR=L.createDomElement("div",{className:"slick-viewport slick-viewport-bottom slick-viewport-right",tabIndex:0},this._paneBottomR),this._viewport=[this._viewportTopL,this._viewportTopR,this._viewportBottomL,this._viewportBottomR],this._options.viewportClass&&this._viewport.forEach(o=>{o.classList.add(...L.classNameToList(this._options.viewportClass))}),this._activeViewportNode=this._viewportTopL,this._canvasTopL=L.createDomElement("div",{className:"grid-canvas grid-canvas-top grid-canvas-left",tabIndex:0},this._viewportTopL),this._canvasTopR=L.createDomElement("div",{className:"grid-canvas grid-canvas-top grid-canvas-right",tabIndex:0},this._viewportTopR),this._canvasBottomL=L.createDomElement("div",{className:"grid-canvas grid-canvas-bottom grid-canvas-left",tabIndex:0},this._viewportBottomL),this._canvasBottomR=L.createDomElement("div",{className:"grid-canvas grid-canvas-bottom grid-canvas-right",tabIndex:0},this._viewportBottomR),this._canvas=[this._canvasTopL,this._canvasTopR,this._canvasBottomL,this._canvasBottomR],this.scrollbarDimensions=this.scrollbarDimensions||this.measureScrollbar();let n=this.getCanvasWidth()+this.scrollbarDimensions.width;this._activeCanvasNode=this._canvasTopL,this._topHeaderPanelSpacer&&L.width(this._topHeaderPanelSpacer,n),this._preHeaderPanelSpacer&&L.width(this._preHeaderPanelSpacer,n),this._headers.forEach(o=>{L.width(o,this.getHeadersWidth())}),L.width(this._headerRowSpacerL,n),L.width(this._headerRowSpacerR,n),this._options.createFooterRow&&(this._footerRowScrollerR=L.createDomElement("div",{className:"slick-footerrow ui-state-default slick-state-default"},this._paneTopR),this._footerRowScrollerL=L.createDomElement("div",{className:"slick-footerrow ui-state-default slick-state-default"},this._paneTopL),this._footerRowScroller=[this._footerRowScrollerL,this._footerRowScrollerR],this._footerRowSpacerL=L.createDomElement("div",{style:{display:"block",height:"1px",position:"absolute",top:"0px",left:"0px"}},this._footerRowScrollerL),L.width(this._footerRowSpacerL,n),this._footerRowSpacerR=L.createDomElement("div",{style:{display:"block",height:"1px",position:"absolute",top:"0px",left:"0px"}},this._footerRowScrollerR),L.width(this._footerRowSpacerR,n),this._footerRowL=L.createDomElement("div",{className:"slick-footerrow-columns slick-footerrow-columns-left"},this._footerRowScrollerL),this._footerRowR=L.createDomElement("div",{className:"slick-footerrow-columns slick-footerrow-columns-right"},this._footerRowScrollerR),this._footerRow=[this._footerRowL,this._footerRowR],this._options.showFooterRow||this._footerRowScroller.forEach(o=>{L.hide(o)})),this._focusSink2=this._focusSink.cloneNode(!0),this._container.appendChild(this._focusSink2),this._options.explicitInitialization||this.finishInitialization()}finishInitialization(){this.initialized||(this.initialized=!0,this.getViewportWidth(),this.getViewportHeight(),this.measureCellPaddingAndBorder(),this.disableSelection(this._headers),this._options.enableTextSelectionOnCells||this._viewport.forEach(e=>{this._bindingEventService.bind(e,"selectstart",t=>{t.target instanceof HTMLInputElement||t.target instanceof HTMLTextAreaElement})}),this.setFrozenOptions(),this.setPaneFrozenClasses(),this.setPaneVisibility(),this.setScroller(),this.setOverflow(),this.updateColumnCaches(),this.createColumnHeaders(),this.createColumnFooter(),this.setupColumnSort(),this.createCssRules(),this.resizeCanvas(),this.bindAncestorScrollEvents(),this._bindingEventService.bind(this._container,"resize",this.resizeCanvas.bind(this)),this._viewport.forEach(e=>{this._bindingEventService.bind(e,"scroll",this.handleScroll.bind(this))}),this._options.enableMouseWheelScrollHandler&&this._viewport.forEach(e=>{this.slickMouseWheelInstances.push(am({element:e,onMouseWheel:this.handleMouseWheel.bind(this)}))}),this._headerScroller.forEach(e=>{this._bindingEventService.bind(e,"contextmenu",this.handleHeaderContextMenu.bind(this)),this._bindingEventService.bind(e,"click",this.handleHeaderClick.bind(this))}),this._headerRowScroller.forEach(e=>{this._bindingEventService.bind(e,"scroll",this.handleHeaderRowScroll.bind(this))}),this._options.createFooterRow&&(this._footerRow.forEach(e=>{this._bindingEventService.bind(e,"contextmenu",this.handleFooterContextMenu.bind(this)),this._bindingEventService.bind(e,"click",this.handleFooterClick.bind(this))}),this._footerRowScroller.forEach(e=>{this._bindingEventService.bind(e,"scroll",this.handleFooterRowScroll.bind(this))})),this._options.createTopHeaderPanel&&this._bindingEventService.bind(this._topHeaderPanelScroller,"scroll",this.handleTopHeaderPanelScroll.bind(this)),this._options.createPreHeaderPanel&&(this._bindingEventService.bind(this._preHeaderPanelScroller,"scroll",this.handlePreHeaderPanelScroll.bind(this)),this._bindingEventService.bind(this._preHeaderPanelScroller,"contextmenu",this.handlePreHeaderContextMenu.bind(this)),this._bindingEventService.bind(this._preHeaderPanelScrollerR,"contextmenu",this.handlePreHeaderContextMenu.bind(this)),this._bindingEventService.bind(this._preHeaderPanelScroller,"click",this.handlePreHeaderClick.bind(this)),this._bindingEventService.bind(this._preHeaderPanelScrollerR,"click",this.handlePreHeaderClick.bind(this))),this._bindingEventService.bind(this._focusSink,"keydown",this.handleKeyDown.bind(this)),this._bindingEventService.bind(this._focusSink2,"keydown",this.handleKeyDown.bind(this)),this._canvas.forEach(e=>{this._bindingEventService.bind(e,"keydown",this.handleKeyDown.bind(this)),this._bindingEventService.bind(e,"click",this.handleClick.bind(this)),this._bindingEventService.bind(e,"dblclick",this.handleDblClick.bind(this)),this._bindingEventService.bind(e,"contextmenu",this.handleContextMenu.bind(this)),this._bindingEventService.bind(e,"mouseover",this.handleCellMouseOver.bind(this)),this._bindingEventService.bind(e,"mouseout",this.handleCellMouseOut.bind(this))}),im&&(this.slickDraggableInstance=im({containerElement:this._container,allowDragFrom:"div.slick-cell",allowDragFromClosest:"div.slick-cell.dnd, div.slick-cell.cell-reorder",preventDragFromKeys:this._options.preventDragFromKeys,onDragInit:this.handleDragInit.bind(this),onDragStart:this.handleDragStart.bind(this),onDrag:this.handleDrag.bind(this),onDragEnd:this.handleDragEnd.bind(this)})),this._options.suppressCssChangesOnHiddenInit||this.restoreCssFromHiddenInit())}cacheCssForHiddenInit(){this._hiddenParents=L.parents(this._container,":hidden"),this.oldProps=[],this._hiddenParents.forEach(e=>{let t={};Object.keys(this.cssShow).forEach(n=>{this.cssShow&&(t[n]=e.style[n],e.style[n]=this.cssShow[n])}),this.oldProps.push(t)})}restoreCssFromHiddenInit(){let e=0;this._hiddenParents&&(this._hiddenParents.forEach(t=>{let n=this.oldProps[e++];Object.keys(this.cssShow).forEach(o=>{this.cssShow&&(t.style[o]=n[o])})}),this._hiddenParents=[])}registerPlugin(e){this.plugins.unshift(e),e.init(this)}unregisterPlugin(e){for(let t=this.plugins.length;t>=0;t--)if(this.plugins[t]===e){this.plugins[t]?.destroy(),this.plugins.splice(t,1);break}}destroy(e){this._bindingEventService.unbindAll(),this.slickDraggableInstance=this.destroyAllInstances(this.slickDraggableInstance),this.slickMouseWheelInstances=this.destroyAllInstances(this.slickMouseWheelInstances),this.slickResizableInstances=this.destroyAllInstances(this.slickResizableInstances),this.getEditorLock()?.cancelCurrentEdit(),this.trigger(this.onBeforeDestroy,{});let t=this.plugins.length;for(;t--;)this.unregisterPlugin(this.plugins[t]);this._options.enableColumnReorder&&typeof this.sortableSideLeftInstance?.destroy=="function"&&(this.sortableSideLeftInstance?.destroy(),this.sortableSideRightInstance?.destroy()),this.unbindAncestorScrollEvents(),this._bindingEventService.unbindByEventName(this._container,"resize"),this.removeCssRules(),this._canvas.forEach(r=>{this._bindingEventService.unbindByEventName(r,"keydown"),this._bindingEventService.unbindByEventName(r,"click"),this._bindingEventService.unbindByEventName(r,"dblclick"),this._bindingEventService.unbindByEventName(r,"contextmenu"),this._bindingEventService.unbindByEventName(r,"mouseover"),this._bindingEventService.unbindByEventName(r,"mouseout")}),this._viewport.forEach(r=>{this._bindingEventService.unbindByEventName(r,"scroll")}),this._headerScroller.forEach(r=>{this._bindingEventService.unbindByEventName(r,"contextmenu"),this._bindingEventService.unbindByEventName(r,"click")}),this._headerRowScroller.forEach(r=>{this._bindingEventService.unbindByEventName(r,"scroll")}),this._footerRow&&this._footerRow.forEach(r=>{this._bindingEventService.unbindByEventName(r,"contextmenu"),this._bindingEventService.unbindByEventName(r,"click")}),this._footerRowScroller&&this._footerRowScroller.forEach(r=>{this._bindingEventService.unbindByEventName(r,"scroll")}),this._preHeaderPanelScroller&&this._bindingEventService.unbindByEventName(this._preHeaderPanelScroller,"scroll"),this._topHeaderPanelScroller&&this._bindingEventService.unbindByEventName(this._topHeaderPanelScroller,"scroll"),this._bindingEventService.unbindByEventName(this._focusSink,"keydown"),this._bindingEventService.unbindByEventName(this._focusSink2,"keydown");let n=this._container.querySelectorAll(".slick-resizable-handle");[].forEach.call(n,r=>{this._bindingEventService.unbindByEventName(r,"dblclick")});let o=this._container.querySelectorAll(".slick-header-column");[].forEach.call(o,r=>{this._bindingEventService.unbindByEventName(r,"mouseenter"),this._bindingEventService.unbindByEventName(r,"mouseleave"),this._bindingEventService.unbindByEventName(r,"mouseenter"),this._bindingEventService.unbindByEventName(r,"mouseleave")}),L.emptyElement(this._container),this._container.classList.remove(this.uid),this.clearAllTimers(),e&&this.destroyAllElements()}destroyAllInstances(e){if(e){let t=Array.isArray(e)?e:[e],n;for(;L.isDefined(n=t.pop());)n&&typeof n.destroy=="function"&&n.destroy()}return e=Array.isArray(e)?[]:null,e}destroyAllElements(){this._activeCanvasNode=null,this._activeViewportNode=null,this._boundAncestors=null,this._canvas=null,this._canvasTopL=null,this._canvasTopR=null,this._canvasBottomL=null,this._canvasBottomR=null,this._container=null,this._focusSink=null,this._focusSink2=null,this._groupHeaders=null,this._groupHeadersL=null,this._groupHeadersR=null,this._headerL=null,this._headerR=null,this._headers=null,this._headerRows=null,this._headerRowL=null,this._headerRowR=null,this._headerRowSpacerL=null,this._headerRowSpacerR=null,this._headerRowScrollContainer=null,this._headerRowScroller=null,this._headerRowScrollerL=null,this._headerRowScrollerR=null,this._headerScrollContainer=null,this._headerScroller=null,this._headerScrollerL=null,this._headerScrollerR=null,this._hiddenParents=null,this._footerRow=null,this._footerRowL=null,this._footerRowR=null,this._footerRowSpacerL=null,this._footerRowSpacerR=null,this._footerRowScroller=null,this._footerRowScrollerL=null,this._footerRowScrollerR=null,this._footerRowScrollContainer=null,this._preHeaderPanel=null,this._preHeaderPanelR=null,this._preHeaderPanelScroller=null,this._preHeaderPanelScrollerR=null,this._preHeaderPanelSpacer=null,this._preHeaderPanelSpacerR=null,this._topPanels=null,this._topPanelScrollers=null,this._style=null,this._topPanelScrollerL=null,this._topPanelScrollerR=null,this._topPanelL=null,this._topPanelR=null,this._paneHeaderL=null,this._paneHeaderR=null,this._paneTopL=null,this._paneTopR=null,this._paneBottomL=null,this._paneBottomR=null,this._viewport=null,this._viewportTopL=null,this._viewportTopR=null,this._viewportBottomL=null,this._viewportBottomR=null,this._viewportScrollContainerX=null,this._viewportScrollContainerY=null}getOptions(){return this._options}setOptions(e,t,n,o){this.prepareForOptionsChange(),this._options.enableAddRow!==e.enableAddRow&&this.invalidateRow(this.getDataLength()),e.frozenColumn!==void 0&&e.frozenColumn>=0&&(this.getViewports().forEach(i=>i.scrollLeft=0),this.handleScroll());let r=L.extend(!0,{},this._options);this._options=L.extend(this._options,e),this.trigger(this.onSetOptions,{optionsBefore:r,optionsAfter:this._options}),this.internal_setOptions(t,n,o)}activateChangedOptions(e,t,n){this.prepareForOptionsChange(),this.invalidateRow(this.getDataLength()),this.trigger(this.onActivateChangedOptions,{options:this._options}),this.internal_setOptions(e,t,n)}prepareForOptionsChange(){this.getEditorLock().commitCurrentEdit()&&this.makeActiveCellNormal()}internal_setOptions(e,t,n){this._options.showColumnHeader!==void 0&&this.setColumnHeaderVisibility(this._options.showColumnHeader),this.validateAndEnforceOptions(),this.setFrozenOptions(),this._options.frozenBottom!==void 0&&(this.enforceFrozenRowHeightRecalc=!0),this._viewport.forEach(o=>{o.style.overflowY=this._options.autoHeight?"hidden":"auto"}),e||this.render(),this.setScroller(),n||this.setOverflow(),t||this.setColumns(this.columns),this._options.enableMouseWheelScrollHandler&&this._viewport&&(!this.slickMouseWheelInstances||this.slickMouseWheelInstances.length===0)?this._viewport.forEach(o=>{this.slickMouseWheelInstances.push(am({element:o,onMouseWheel:this.handleMouseWheel.bind(this)}))}):this._options.enableMouseWheelScrollHandler===!1&&this.destroyAllInstances(this.slickMouseWheelInstances)}validateAndEnforceOptions(){this._options.autoHeight&&(this._options.leaveSpaceForNewRows=!1),this._options.forceFitColumns&&(this._options.autosizeColsMode=_n.LegacyForceFit)}setSelectionModel(e){this.selectionModel&&(this.selectionModel.onSelectedRangesChanged.unsubscribe(this.handleSelectedRangesChanged.bind(this)),this.selectionModel.destroy&&this.selectionModel.destroy()),this.selectionModel=e,this.selectionModel&&(this.selectionModel.init(this),this.selectionModel.onSelectedRangesChanged.subscribe(this.handleSelectedRangesChanged.bind(this)))}getSelectionModel(){return this.selectionModel}setPaneFrozenClasses(){let e=this.hasFrozenColumns()?"add":"remove";for(let t of[this._paneHeaderL,this._paneTopL,this._paneBottomL])t.classList[e]("frozen")}hasFrozenColumns(){return this._options.frozenColumn>-1}updateColumnHeader(e,t,n){if(this.initialized){let o=this.getColumnIndex(e);if(!L.isDefined(o))return;let r=this.columns[o],i=this.getColumnByIndex(o);i&&(t!==void 0&&(this.columns[o].name=t),n!==void 0&&(this.columns[o].toolTip=n),this.trigger(this.onBeforeHeaderCellDestroy,{node:i,column:r,grid:this}),i.setAttribute("title",n||""),t!==void 0&&this.applyHtmlCode(i.children[0],t),this.trigger(this.onHeaderCellRendered,{node:i,column:r,grid:this}))}}getHeader(e){if(!e)return this.hasFrozenColumns()?this._headers:this._headerL;let t=this.getColumnIndex(e.id);return this.hasFrozenColumns()?t<=this._options.frozenColumn?this._headerL:this._headerR:this._headerL}getHeaderColumn(e){let t=typeof e=="number"?e:this.getColumnIndex(e),n=this.hasFrozenColumns()?t<=this._options.frozenColumn?this._headerL:this._headerR:this._headerL,o=this.hasFrozenColumns()?t<=this._options.frozenColumn?t:t-this._options.frozenColumn-1:t;return n.children[o]}getHeaderRow(){return this.hasFrozenColumns()?this._headerRows:this._headerRows[0]}getFooterRow(){return this.hasFrozenColumns()?this._footerRow:this._footerRow[0]}getHeaderRowColumn(e){let t=typeof e=="number"?e:this.getColumnIndex(e),n;return this.hasFrozenColumns()?t<=this._options.frozenColumn?n=this._headerRowL:(n=this._headerRowR,t-=this._options.frozenColumn+1):n=this._headerRowL,n.children[t]}getFooterRowColumn(e){let t=typeof e=="number"?e:this.getColumnIndex(e),n;return this.hasFrozenColumns()?t<=this._options.frozenColumn?n=this._footerRowL:(n=this._footerRowR,t-=this._options.frozenColumn+1):n=this._footerRowL,n.children[t]}createColumnFooter(){if(this._options.createFooterRow){this._footerRow.forEach(e=>{e.querySelectorAll(".slick-footerrow-column").forEach(t=>{let n=L.storage.get(t,"column");this.trigger(this.onBeforeFooterRowCellDestroy,{node:t,column:n,grid:this})})}),L.emptyElement(this._footerRowL),L.emptyElement(this._footerRowR);for(let e=0;e<this.columns.length;e++){let t=this.columns[e];if(!t||t.hidden)continue;let n=L.createDomElement("div",{className:`ui-state-default slick-state-default slick-footerrow-column l${e} r${e}`},this.hasFrozenColumns()&&e>this._options.frozenColumn?this._footerRowR:this._footerRowL),o=this.hasFrozenColumns()&&e<=this._options.frozenColumn?"frozen":null;o&&n.classList.add(o),L.storage.put(n,"column",t),this.trigger(this.onFooterRowCellRendered,{node:n,column:t,grid:this})}}}setupColumnSort(){this._headers.forEach(e=>{this._bindingEventService.bind(e,"click",t=>{if(this.columnResizeDragging||t.target.classList.contains("slick-resizable-handle"))return;let n=t.target.closest(".slick-header-column");if(!n)return;let o=L.storage.get(n,"column");if(o.sortable){if(!this.getEditorLock()?.commitCurrentEdit())return;let r=this.sortColumns.slice(),i=null,a=0;for(;a<this.sortColumns.length;a++)if(this.sortColumns[a].columnId===o.id){i=this.sortColumns[a],i.sortAsc=!i.sortAsc;break}let l=!!i;this._options.tristateMultiColumnSort?(i||(i={columnId:o.id,sortAsc:o.defaultSortAsc,sortCol:o}),l&&i.sortAsc&&(this.sortColumns.splice(a,1),i=null),this._options.multiColumnSort||(this.sortColumns=[]),i&&(!l||!this._options.multiColumnSort)&&this.sortColumns.push(i)):t.metaKey&&this._options.multiColumnSort?i&&this.sortColumns.splice(a,1):((!t.shiftKey&&!t.metaKey||!this._options.multiColumnSort)&&(this.sortColumns=[]),i?this.sortColumns.length===0&&this.sortColumns.push(i):(i={columnId:o.id,sortAsc:o.defaultSortAsc,sortCol:o},this.sortColumns.push(i)));let d;this._options.multiColumnSort?d={multiColumnSort:!0,previousSortColumns:r,sortCols:this.sortColumns.map(u=>{let f=this.columns[this.getColumnIndex(u.columnId)];return!f||f.hidden?null:{columnId:f.id,sortCol:f,sortAsc:u.sortAsc}}).filter(u=>u)}:d={multiColumnSort:!1,previousSortColumns:r,columnId:this.sortColumns.length>0?o.id:null,sortCol:this.sortColumns.length>0?o:null,sortAsc:this.sortColumns.length>0?this.sortColumns[0].sortAsc:!0},this.trigger(this.onBeforeSort,d,t).getReturnValue()!==!1&&(this.setSortColumns(this.sortColumns),this.trigger(this.onSort,d,t))}})})}createColumnHeaders(){this._headers.forEach(e=>{e.querySelectorAll(".slick-header-column").forEach(t=>{let n=L.storage.get(t,"column");n&&this.trigger(this.onBeforeHeaderCellDestroy,{node:t,column:n,grid:this})})}),L.emptyElement(this._headerL),L.emptyElement(this._headerR),this.getHeadersWidth(),L.width(this._headerL,this.headersWidthL),L.width(this._headerR,this.headersWidthR),this._headerRows.forEach(e=>{e.querySelectorAll(".slick-headerrow-column").forEach(t=>{let n=L.storage.get(t,"column");n&&this.trigger(this.onBeforeHeaderRowCellDestroy,{node:this,column:n,grid:this})})}),L.emptyElement(this._headerRowL),L.emptyElement(this._headerRowR),this._options.createFooterRow&&(this._footerRowL.querySelectorAll(".slick-footerrow-column").forEach(e=>{let t=L.storage.get(e,"column");t&&this.trigger(this.onBeforeFooterRowCellDestroy,{node:this,column:t,grid:this})}),L.emptyElement(this._footerRowL),this.hasFrozenColumns()&&(this._footerRowR.querySelectorAll(".slick-footerrow-column").forEach(e=>{let t=L.storage.get(e,"column");t&&this.trigger(this.onBeforeFooterRowCellDestroy,{node:this,column:t,grid:this})}),L.emptyElement(this._footerRowR)));for(let e=0;e<this.columns.length;e++){let t=this.columns[e];if(t.hidden)continue;let n=this.hasFrozenColumns()?e<=this._options.frozenColumn?this._headerL:this._headerR:this._headerL,o=this.hasFrozenColumns()?e<=this._options.frozenColumn?this._headerRowL:this._headerRowR:this._headerRowL,r=L.createDomElement("div",{id:`${this.uid+t.id}`,dataset:{id:String(t.id)},role:"columnheader",className:"ui-state-default slick-state-default slick-header-column"},n);t.toolTip&&(r.title=t.toolTip),t.reorderable||r.classList.add(this._options.unorderableColumnCssClass);let i=L.createDomElement("span",{className:"slick-column-name"},r);this.applyHtmlCode(i,t.name),L.width(r,t.width-this.headerColumnWidthDiff);let a=t.headerCssClass||null;if(a&&r.classList.add(...L.classNameToList(a)),a=this.hasFrozenColumns()&&e<=this._options.frozenColumn?"frozen":null,a&&r.classList.add(a),this._bindingEventService.bind(r,"mouseenter",this.handleHeaderMouseEnter.bind(this)),this._bindingEventService.bind(r,"mouseleave",this.handleHeaderMouseLeave.bind(this)),L.storage.put(r,"column",t),(this._options.enableColumnReorder||t.sortable)&&(this._bindingEventService.bind(r,"mouseenter",this.handleHeaderMouseHoverOn.bind(this)),this._bindingEventService.bind(r,"mouseleave",this.handleHeaderMouseHoverOff.bind(this))),t.hasOwnProperty("headerCellAttrs")&&t.headerCellAttrs instanceof Object&&Object.keys(t.headerCellAttrs).forEach(l=>{t.headerCellAttrs.hasOwnProperty(l)&&r.setAttribute(l,t.headerCellAttrs[l])}),t.sortable&&(r.classList.add("slick-header-sortable"),L.createDomElement("div",{className:`slick-sort-indicator ${this._options.numberedMultiColumnSort&&!this._options.sortColNumberInSeparateSpan?" slick-sort-indicator-numbered":""}`},r),this._options.numberedMultiColumnSort&&this._options.sortColNumberInSeparateSpan&&L.createDomElement("div",{className:"slick-sort-indicator-numbered"},r)),this.trigger(this.onHeaderCellRendered,{node:r,column:t,grid:this}),this._options.showHeaderRow){let l=L.createDomElement("div",{className:`ui-state-default slick-state-default slick-headerrow-column l${e} r${e}`},o),d=this.hasFrozenColumns()&&e<=this._options.frozenColumn?"frozen":null;d&&l.classList.add(d),this._bindingEventService.bind(l,"mouseenter",this.handleHeaderRowMouseEnter.bind(this)),this._bindingEventService.bind(l,"mouseleave",this.handleHeaderRowMouseLeave.bind(this)),L.storage.put(l,"column",t),this.trigger(this.onHeaderRowCellRendered,{node:l,column:t,grid:this})}if(this._options.createFooterRow&&this._options.showFooterRow){let l=this.hasFrozenColumns()?e<=this._options.frozenColumn?this._footerRow[0]:this._footerRow[1]:this._footerRow[0],d=L.createDomElement("div",{className:`ui-state-default slick-state-default slick-footerrow-column l${e} r${e}`},l);L.storage.put(d,"column",t),this.trigger(this.onFooterRowCellRendered,{node:d,column:t,grid:this})}}this.setSortColumns(this.sortColumns),this.setupColumnResize(),this._options.enableColumnReorder&&(typeof this._options.enableColumnReorder=="function"?this._options.enableColumnReorder(this,this._headers,this.headerColumnWidthDiff,this.setColumns,this.setupColumnResize,this.columns,this.getColumnIndex,this.uid,this.trigger):this.setupColumnReorder())}setupColumnReorder(){this.sortableSideLeftInstance?.destroy(),this.sortableSideRightInstance?.destroy();let e=null,t=()=>this._viewportScrollContainerX.scrollLeft=this._viewportScrollContainerX.scrollLeft+10,n=()=>this._viewportScrollContainerX.scrollLeft=this._viewportScrollContainerX.scrollLeft-10,o=!1,r={animation:50,direction:"horizontal",chosenClass:"slick-header-column-active",ghostClass:"slick-sortable-placeholder",draggable:".slick-header-column",dragoverBubble:!1,revertClone:!0,scroll:!this.hasFrozenColumns(),filter:`.${this._options.unorderableColumnCssClass}`,onMove:i=>!i.related.classList.contains(this._options.unorderableColumnCssClass),onStart:i=>{i.item.classList.add("slick-header-column-active"),o=!this.hasFrozenColumns()||L.offset(i.item).left>L.offset(this._viewportScrollContainerX).left,o&&i.originalEvent.pageX>this._container.clientWidth?e||(e=window.setInterval(t,100)):o&&i.originalEvent.pageX<L.offset(this._viewportScrollContainerX).left?e||(e=window.setInterval(n,100)):(window.clearInterval(e),e=null)},onEnd:i=>{if(i.item.classList.remove("slick-header-column-active"),window.clearInterval(e),e=null,!this.getEditorLock()?.commitCurrentEdit())return;let a=this.sortableSideLeftInstance?.toArray()??[];a=a.concat(this.sortableSideRightInstance?.toArray()??[]);let l=[];for(let d=0;d<a.length;d++)l.push(this.columns[this.getColumnIndex(a[d])]);this.setColumns(l),this.trigger(this.onColumnsReordered,{impactedColumns:this.columns}),i.stopPropagation(),this.setupColumnResize(),this.activeCellNode&&this.setFocus()}};this.sortableSideLeftInstance=Sortable.create(this._headerL,r),this.sortableSideRightInstance=Sortable.create(this._headerR,r)}getHeaderChildren(){let e=Array.from(this._headers[0].children),t=Array.from(this._headers[1].children);return e.concat(t)}handleResizeableDoubleClick(e){let t=e.target.parentElement.id.replace(this.uid,"");this.trigger(this.onColumnsResizeDblClick,{triggeredByColumn:t})}setupColumnResize(){if(typeof lm>"u")throw new Error('Slick.Resizable is undefined, make sure to import "slick.interactions.js"');let e,t,n,o,r,i,a,l=-1,d=0,u=this.getHeaderChildren(),f=this.getVisibleColumns();for(let p=0;p<u.length;p++)u[p].querySelectorAll(".slick-resizable-handle").forEach(y=>y.remove()),!(p>=f.length||!f[p])&&f[p].resizable&&(a===void 0&&(a=p),l=p);if(a!==void 0)for(let p=0;p<u.length;p++){let y=u[p];if(p>=f.length||!f[p]||p<a||this._options.forceFitColumns&&p>=l)continue;let b=L.createDomElement("div",{className:"slick-resizable-handle",role:"separator",ariaOrientation:"horizontal"},y);this._bindingEventService.bind(b,"dblclick",this.handleResizeableDoubleClick.bind(this)),this.slickResizableInstances.push(lm({resizeableElement:y,resizeableHandleElement:b,onResizeStart:(w,g)=>{let v=w.touches?w.changedTouches[0]:w;if(!this.getEditorLock()?.commitCurrentEdit())return!1;o=v.pageX,d=0,g.resizeableElement.classList.add("slick-header-column-active");let E=null,P=null;for(let C=0;C<u.length;C++)C>=f.length||!f[C]||(f[C].previousWidth=u[C].offsetWidth);if(this._options.forceFitColumns)for(E=0,P=0,e=p+1;e<f.length;e++)n=f[e],n?.resizable&&(P!==null&&(n.maxWidth?P+=n.maxWidth-(n.previousWidth||0):P=null),E+=(n.previousWidth||0)-Math.max(n.minWidth||0,this.absoluteColumnMinWidth));let x=0,S=0;for(e=0;e<=p;e++)n=f[e],n?.resizable&&(S!==null&&(n.maxWidth?S+=n.maxWidth-(n.previousWidth||0):S=null),x+=(n.previousWidth||0)-Math.max(n.minWidth||0,this.absoluteColumnMinWidth));E===null&&(E=1e5),x===null&&(x=1e5),P===null&&(P=1e5),S===null&&(S=1e5),i=o+Math.min(E,S),r=o-Math.min(x,P)},onResize:(w,g)=>{let v=w.touches?w.changedTouches[0]:w;this.columnResizeDragging=!0;let E,P=Math.min(i,Math.max(r,v.pageX))-o,x,S=0,C=0,O=this.getViewportInnerWidth();if(P<0){for(x=P,e=p;e>=0;e--)n=f[e],n?.resizable&&!n.hidden&&(E=Math.max(n.minWidth||0,this.absoluteColumnMinWidth),x&&(n.previousWidth||0)+x<E?(x+=(n.previousWidth||0)-E,n.width=E):(n.width=(n.previousWidth||0)+x,x=0));for(t=0;t<=p;t++)n=f[t],!(!n||n.hidden)&&(this.hasFrozenColumns()&&t>this._options.frozenColumn?C+=n.width||0:S+=n.width||0);if(this._options.forceFitColumns)for(x=-P,e=p+1;e<f.length;e++)n=f[e],!(!n||n.hidden)&&n.resizable&&(x&&n.maxWidth&&n.maxWidth-(n.previousWidth||0)<x?(x-=n.maxWidth-(n.previousWidth||0),n.width=n.maxWidth):(n.width=(n.previousWidth||0)+x,x=0),this.hasFrozenColumns()&&e>this._options.frozenColumn?C+=n.width||0:S+=n.width||0);else for(e=p+1;e<f.length;e++)n=f[e],!(!n||n.hidden)&&(this.hasFrozenColumns()&&e>this._options.frozenColumn?C+=n.width||0:S+=n.width||0);if(this._options.forceFitColumns)for(x=-P,e=p+1;e<f.length;e++)n=f[e],!(!n||n.hidden)&&n.resizable&&(x&&n.maxWidth&&n.maxWidth-(n.previousWidth||0)<x?(x-=n.maxWidth-(n.previousWidth||0),n.width=n.maxWidth):(n.width=(n.previousWidth||0)+x,x=0))}else{for(x=P,S=0,C=0,e=p;e>=0;e--)if(n=f[e],!(!n||n.hidden)&&n.resizable)if(x&&n.maxWidth&&n.maxWidth-(n.previousWidth||0)<x)x-=n.maxWidth-(n.previousWidth||0),n.width=n.maxWidth;else{let N=(n.previousWidth||0)+x,F=this.canvasWidthL+x;this.hasFrozenColumns()&&e<=this._options.frozenColumn?(N>d&&F<O-this._options.frozenRightViewportMinWidth&&(d=N),n.width=F+this._options.frozenRightViewportMinWidth>O?d:N):n.width=N,x=0}for(t=0;t<=p;t++)n=f[t],!(!n||n.hidden)&&(this.hasFrozenColumns()&&t>this._options.frozenColumn?C+=n.width||0:S+=n.width||0);if(this._options.forceFitColumns)for(x=-P,e=p+1;e<f.length;e++)n=f[e],!(!n||n.hidden)&&n.resizable&&(E=Math.max(n.minWidth||0,this.absoluteColumnMinWidth),x&&(n.previousWidth||0)+x<E?(x+=(n.previousWidth||0)-E,n.width=E):(n.width=(n.previousWidth||0)+x,x=0),this.hasFrozenColumns()&&e>this._options.frozenColumn?C+=n.width||0:S+=n.width||0);else for(e=p+1;e<f.length;e++)n=f[e],!(!n||n.hidden)&&(this.hasFrozenColumns()&&e>this._options.frozenColumn?C+=n.width||0:S+=n.width||0)}this.hasFrozenColumns()&&S!==this.canvasWidthL&&(L.width(this._headerL,S+1e3),L.setStyleSize(this._paneHeaderR,"left",S)),this.applyColumnHeaderWidths(),this._options.syncColumnCellResize&&this.applyColumnWidths(),this.trigger(this.onColumnsDrag,{triggeredByColumn:g.resizeableElement,resizeHandle:g.resizeableHandleElement})},onResizeEnd:(w,g)=>{g.resizeableElement.classList.remove("slick-header-column-active");let v=g.resizeableElement.id.replace(this.uid,"");this.trigger(this.onBeforeColumnsResize,{triggeredByColumn:v}).getReturnValue()===!0&&this.applyColumnHeaderWidths();let E;for(e=0;e<f.length;e++)n=f[e],!(!n||n.hidden)&&(E=u[e].offsetWidth,n.previousWidth!==E&&n.rerenderOnResize&&this.invalidateAllRows());this.updateCanvasWidth(!0),this.render(),this.trigger(this.onColumnsResized,{triggeredByColumn:v}),window.clearTimeout(this._columnResizeTimer),this._columnResizeTimer=window.setTimeout(()=>{this.columnResizeDragging=!1},300)}}))}}setFrozenOptions(){if(this._options.frozenColumn=this._options.frozenColumn>=0&&this._options.frozenColumn<this.columns.length?parseInt(this._options.frozenColumn,10):-1,this._options.frozenRow>-1){this.hasFrozenRows=!0,this.frozenRowsHeight=this._options.frozenRow*this._options.rowHeight;let e=this.getDataLength();this.actualFrozenRow=this._options.frozenBottom?e-this._options.frozenRow:this._options.frozenRow}else this.hasFrozenRows=!1}autosizeColumn(e,t){let n=null,o=-1;if(typeof e=="number")n=this.columns[e],o=e;else if(typeof e=="string")for(let i=0;i<this.columns.length;i++)this.columns[i].id===e&&(n=this.columns[i],o=i);if(!n)return;let r=this.getCanvasNode(0,0);this.getColAutosizeWidth(n,o,r,t||!1,o)}treatAsLocked(e={}){return!e.ignoreHeaderText&&!e.sizeToRemaining&&e.contentSizePx===e.headerWidthPx&&(e.widthPx??0)<100}autosizeColumns(e,t){let n=!this._hiddenParents?.length;n&&this.cacheCssForHiddenInit(),this.internalAutosizeColumns(e,t),n&&this.restoreCssFromHiddenInit()}internalAutosizeColumns(e,t){if(e=e||this._options.autosizeColsMode,e===_n.LegacyForceFit||e===_n.LegacyOff){this.legacyAutosizeColumns();return}if(e===_n.None)return;this.canvas=document.createElement("canvas"),this.canvas?.getContext&&(this.canvas_context=this.canvas.getContext("2d"));let n=this.getCanvasNode(0,0),o=this.getViewportInnerWidth(),r,i,a,l=!1,d=0,u=0,f=0,p=0,y=0;for(r=0;r<this.columns.length;r++)i=this.columns[r],this.getColAutosizeWidth(i,r,n,t||!1,r),y+=i.autoSize?.autosizeMode===cr.Locked?i.width||0:this.treatAsLocked(i.autoSize)&&i.autoSize?.widthPx||0,p+=i.autoSize?.autosizeMode===cr.Locked?i.width||0:this.treatAsLocked(i.autoSize)?i.autoSize?.widthPx||0:i.minWidth||0,d+=i.autoSize?.widthPx||0,u+=i.autoSize?.sizeToRemaining?0:i.autoSize?.widthPx||0,f+=i.autoSize?.sizeToRemaining&&i.minWidth||0;let b=d-u;if(e===_n.FitViewportToCols){let w=d+(this.scrollbarDimensions?.width??0);e=_n.IgnoreViewport,this._options.viewportMaxWidthPx&&w>this._options.viewportMaxWidthPx?(w=this._options.viewportMaxWidthPx,e=_n.FitColsToViewport):this._options.viewportMinWidthPx&&w<this._options.viewportMinWidthPx&&(w=this._options.viewportMinWidthPx,e=_n.FitColsToViewport),L.width(this._container,w)}if(e===_n.FitColsToViewport)if(b>0&&u<o-f)for(r=0;r<this.columns.length;r++){if(i=this.columns[r],!i||i.hidden)continue;let w=o-u;i.autoSize?.sizeToRemaining?a=w*(i.autoSize?.widthPx||0)/b:a=i.autoSize?.widthPx||0,i.rerenderOnResize&&(i.width||0)!==a&&(l=!0),i.width=a}else if(this._options.viewportSwitchToScrollModeWidthPercent&&u+f>o*this._options.viewportSwitchToScrollModeWidthPercent/100||p>o)e=_n.IgnoreViewport;else{let w=u-y,g=o-y-f;for(r=0;r<this.columns.length;r++)i=this.columns[r],!(!i||i.hidden)&&(a=i.width||0,i.autoSize?.autosizeMode!==cr.Locked&&!this.treatAsLocked(i.autoSize)&&(i.autoSize?.sizeToRemaining?a=i.minWidth||0:(a=g/w*(i.autoSize?.widthPx||0)-1,a<(i.minWidth||0)&&(a=i.minWidth||0),w-=i.autoSize?.widthPx||0,g-=a)),this.treatAsLocked(i.autoSize)&&(a=i.autoSize?.widthPx||0,a<(i.minWidth||0)&&(a=i.minWidth||0)),i.rerenderOnResize&&i.width!==a&&(l=!0),i.width=a)}if(e===_n.IgnoreViewport)for(r=0;r<this.columns.length;r++)!this.columns[r]||this.columns[r].hidden||(a=this.columns[r].autoSize?.widthPx||0,this.columns[r].rerenderOnResize&&this.columns[r].width!==a&&(l=!0),this.columns[r].width=a);this.reRenderColumns(l)}getColAutosizeWidth(e,t,n,o,r){let i=e.autoSize;if(i.widthPx=e.width,i.autosizeMode===cr.Locked||i.autosizeMode===cr.Guide)return;let a=this.getDataLength(),l=new RegExp(/\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}(\.\d{3})?Z/);if(i.autosizeMode===cr.ContentIntelligent){let f=i.colDataTypeOf,p;if(a>0){let y=this.getDataItem(0);y&&(p=y[e.field],l.test(p)&&(p=Date.parse(p)),f=typeof p,f==="object"&&(p instanceof Date&&(f="date"),typeof moment<"u"&&p instanceof moment&&(f="moment")))}f==="boolean"&&(i.colValueArray=[!0,!1]),f==="number"&&(i.valueFilterMode=Rr.GetGreatestAndSub,i.rowSelectionMode=cs.AllRows),f==="string"&&(i.valueFilterMode=Rr.GetLongestText,i.rowSelectionMode=cs.AllRows,i.allowAddlPercent=5),f==="date"&&(i.colValueArray=[new Date(2009,8,30,12,20,20)]),f==="moment"&&typeof moment<"u"&&(i.colValueArray=[moment([2009,8,30,12,20,20])])}let d=i.contentSizePx=this.getColContentSize(e,t,n,o,r);d===0&&(d=i.widthPx||0);let u=i.allowAddlPercent?1+i.allowAddlPercent/100:1;d=d*u+(this._options.autosizeColPaddingPx||0),e.minWidth&&d<e.minWidth&&(d=e.minWidth),e.maxWidth&&d>e.maxWidth&&(d=e.maxWidth),(i.autosizeMode===cr.ContentExpandOnly||e?.editor?.ControlFillsColumn)&&d<(e.width||0)&&(d=e.width||0),i.widthPx=d}getColContentSize(e,t,n,o,r){let i=e.autoSize,a=1,l,d,u=0,f=0;if(i.headerWidthPx=0,i.ignoreHeaderText||(i.headerWidthPx=this.getColHeaderWidth(e)),i.headerWidthPx===0&&(i.headerWidthPx=e.width?e.width:e.maxWidth?e.maxWidth:e.minWidth?e.minWidth:20),i.colValueArray)return f=this.getColWidth(e,n,i.colValueArray),Math.max(i.headerWidthPx,f);let p={};p.colIndex=t,p.rowCount=this.getDataLength(),p.startIndex=0,p.endIndex=p.rowCount-1,p.valueArr=null,p.getRowVal=b=>this.getDataItem(b)[e.field];let y=(o?i.rowSelectionModeOnInit:void 0)||i.rowSelectionMode;if(y===cs.FirstRow&&(p.endIndex=0),y===cs.LastRow&&(p.endIndex=p.startIndex=p.rowCount-1),y===cs.FirstNRows&&(p.endIndex=Math.min(i.rowSelectionCount||0,p.rowCount)-1),i.valueFilterMode===Rr.DeDuplicate){let b={};for(l=p.startIndex;l<=p.endIndex;l++)b[p.getRowVal(l)]=!0;if(Object.keys)p.valueArr=Object.keys(b);else{p.valueArr=[];for(let w in b)b&&p.valueArr.push(w)}p.startIndex=0,p.endIndex=p.length-1}if(i.valueFilterMode===Rr.GetGreatestAndSub){let b,w=0;for(l=p.startIndex;l<=p.endIndex;l++)d=p.getRowVal(l),Math.abs(d)>w&&(b=d,w=Math.abs(d));b=""+b,b=Array(b.length+1).join("9"),b=+b,p.valueArr=[b],p.startIndex=p.endIndex=0}if(i.valueFilterMode===Rr.GetLongestTextAndSub){for(l=p.startIndex;l<=p.endIndex;l++)d=p.getRowVal(l),(d||"").length>u&&(u=d.length);d=Array(u+1).join("m"),a=this._options.autosizeTextAvgToMWidthRatio||0,p.maxLen=u,p.valueArr=[d],p.startIndex=p.endIndex=0}if(i.valueFilterMode===Rr.GetLongestText){u=0;let b=0;for(l=p.startIndex;l<=p.endIndex;l++)d=p.getRowVal(l),(d||"").length>u&&(u=d.length,b=l);d=p.getRowVal(b),p.maxLen=u,p.valueArr=[d],p.startIndex=p.endIndex=0}return p.maxLen&&p.maxLen>30&&r>1&&(i.sizeToRemaining=!0),f=this.getColWidth(e,n,p)*a,Math.max(i.headerWidthPx,f)}getColWidth(e,t,n){let o=L.createDomElement("div",{className:"slick-row ui-widget-content"},t),r=L.createDomElement("div",{className:"slick-cell"},o);r.style.position="absolute",r.style.visibility="hidden",r.style.textOverflow="initial",r.style.whiteSpace="nowrap";let i,a,l=0,d="",u,f,p=e.autoSize.widthEvalMode===Cd.TextOnly;if(e.autoSize?.widthEvalMode===Cd.Auto){let y=!e.formatterOverride&&!e.formatter,b=e?.formatterOverride?.ReturnsTextOnly||!e.formatterOverride&&e.formatter?.ReturnsTextOnly;p=y||b}if(this.canvas_context&&p){let y=getComputedStyle(r);for(this.canvas_context.font=y.fontSize+" "+y.fontFamily,i=n.startIndex;i<=n.endIndex;i++)f=n.valueArr?n.valueArr[i]:n.getRowVal(i),e.formatterOverride?u=e.formatterOverride(i,n.colIndex,f,e,this.getDataItem(i),this):e.formatter?u=e.formatter(i,n.colIndex,f,e,this.getDataItem(i),this):u=""+f,a=u?this.canvas_context.measureText(u).width:0,a>l&&(l=a,d=u);return r.textContent=d,a=r.offsetWidth,o.remove(),a}for(i=n.startIndex;i<=n.endIndex;i++)f=n.valueArr?n.valueArr[i]:n.getRowVal(i),e.formatterOverride?u=e.formatterOverride(i,n.colIndex,f,e,this.getDataItem(i),this):e.formatter?u=e.formatter(i,n.colIndex,f,e,this.getDataItem(i),this):u=""+f,this.applyFormatResultToCellNode(u,r),a=r.offsetWidth,a>l&&(l=a);return o.remove(),l}getColHeaderWidth(e){let t=0,n=this.getUID()+e.id,o=document.getElementById(n),r=`${n}_`,i=o.cloneNode(!0);if(o)i.id=r,i.style.cssText="position: absolute; visibility: hidden;right: auto;text-overflow: initial;white-space: nowrap;",o.parentNode.insertBefore(i,o),t=i.offsetWidth,i.parentNode.removeChild(i);else{let a=this.getHeader(e);o=L.createDomElement("div",{id:r,className:"ui-state-default slick-state-default slick-header-column"},a);let l=L.createDomElement("span",{className:"slick-column-name"},o);this.applyHtmlCode(l,e.name),i.style.cssText="position: absolute; visibility: hidden;right: auto;text-overflow: initial;white-space: nowrap;",e.headerCssClass&&o.classList.add(...L.classNameToList(e.headerCssClass)),t=o.offsetWidth,a.removeChild(o)}return t}legacyAutosizeColumns(){let e,t,n=0,o=0,r=0,i=[],a=this.getViewportInnerWidth();for(e=0;e<this.columns.length;e++){if(t=this.columns[e],!t||t.hidden){i.push(0);continue}i.push(t.width||0),o+=t.width||0,t.resizable&&(n+=(t.width||0)-Math.max(t.minWidth||0,this.absoluteColumnMinWidth))}for(r=o;o>a&&n;){let d=(o-a)/n;for(e=0;e<this.columns.length&&o>a;e++){if(t=this.columns[e],!t||t.hidden)continue;let u=i[e];if(!t.resizable||u<=t.minWidth||u<=this.absoluteColumnMinWidth)continue;let f=Math.max(t.minWidth,this.absoluteColumnMinWidth),p=Math.floor(d*(u-f))||1;p=Math.min(p,u-f),o-=p,n-=p,i[e]-=p}if(r<=o)break;r=o}for(r=o;o<a;){let d=a/o;for(e=0;e<this.columns.length&&o<a;e++){if(t=this.columns[e],!t||t.hidden)continue;let u=i[e],f;!t.resizable||t.maxWidth<=u?f=0:f=Math.min(Math.floor(d*u)-u,t.maxWidth-u||1e6)||1,o+=f,i[e]+=o<=a?f:0}if(r>=o)break;r=o}let l=!1;for(e=0;e<this.columns.length;e++)!t||t.hidden||(this.columns[e].rerenderOnResize&&this.columns[e].width!==i[e]&&(l=!0),this.columns[e].width=i[e]);this.reRenderColumns(l)}reRenderColumns(e){this.applyColumnHeaderWidths(),this.updateCanvasWidth(!0),this.trigger(this.onAutosizeColumns,{columns:this.columns}),e&&(this.invalidateAllRows(),this.render())}getVisibleColumns(){return this.columns.filter(e=>!e.hidden)}getColumnIndex(e){return this.columnsById[e]}applyColumnHeaderWidths(){if(!this.initialized)return;let e=0,t=this.getVisibleColumns();this._headers.forEach(n=>{for(let o=0;o<n.children.length;o++,e++){let r=n.children[o],i=((t[e]||{}).width||0)-this.headerColumnWidthDiff;L.width(r)!==i&&L.width(r,i)}}),this.updateColumnCaches()}applyColumnWidths(){let e=0,t=0,n;for(let o=0;o<this.columns.length;o++)this.columns[o]?.hidden||(t=this.columns[o].width||0,n=this.getColumnCssRules(o),n.left.style.left=`${e}px`,n.right.style.right=(this._options.frozenColumn!==-1&&o>this._options.frozenColumn?this.canvasWidthR:this.canvasWidthL)-e-t+"px",this._options.frozenColumn!==o&&(e+=this.columns[o].width)),this._options.frozenColumn===o&&(e=0)}setSortColumn(e,t){this.setSortColumns([{columnId:e,sortAsc:t}])}getColumnByIndex(e){let t;return this._headers.every(n=>{let o=n.children.length;return e<o?(t=n.children[e],!1):(e-=o,!0)}),t}setSortColumns(e){this.sortColumns=e;let t=this._options.numberedMultiColumnSort&&this.sortColumns.length>1;this._headers.forEach(o=>{let r=o.querySelectorAll(".slick-header-column-sorted");r.forEach(i=>{i.classList.remove("slick-header-column-sorted")}),r=o.querySelectorAll(".slick-sort-indicator"),r.forEach(i=>{i.classList.remove("slick-sort-indicator-asc"),i.classList.remove("slick-sort-indicator-desc")}),r=o.querySelectorAll(".slick-sort-indicator-numbered"),r.forEach(i=>{i.textContent=""})});let n=1;this.sortColumns.forEach(o=>{L.isDefined(o.sortAsc)||(o.sortAsc=!0);let r=this.getColumnIndex(o.columnId);if(L.isDefined(r)){let i=this.getColumnByIndex(r);if(i){i.classList.add("slick-header-column-sorted");let a=i.querySelector(".slick-sort-indicator");a?.classList.add(o.sortAsc?"slick-sort-indicator-asc":"slick-sort-indicator-desc"),t&&(a=i.querySelector(".slick-sort-indicator-numbered"),a&&(a.textContent=String(n)))}}n++})}getColumns(){return this.columns}getSortColumns(){return this.sortColumns}updateColumnCaches(){this.columnPosLeft=[],this.columnPosRight=[];let e=0;for(let t=0,n=this.columns.length;t<n;t++)!this.columns[t]||this.columns[t].hidden||(this.columnPosLeft[t]=e,this.columnPosRight[t]=e+(this.columns[t].width||0),this._options.frozenColumn===t?e=0:e+=this.columns[t].width||0)}updateColumnProps(){this.columnsById={};for(let e=0;e<this.columns.length;e++){let t=this.columns[e];t.width&&(t.widthRequest=t.width),this._options.mixinDefaults?(L.applyDefaults(t,this._columnDefaults),t.autoSize||(t.autoSize={}),L.applyDefaults(t.autoSize,this._columnAutosizeDefaults)):(t=this.columns[e]=L.extend({},this._columnDefaults,t),t.autoSize=L.extend({},this._columnAutosizeDefaults,t.autoSize)),this.columnsById[t.id]=e,t.minWidth&&(t.width||0)<t.minWidth&&(t.width=t.minWidth),t.maxWidth&&(t.width||0)>t.maxWidth&&(t.width=t.maxWidth)}}setColumns(e){this.trigger(this.onBeforeSetColumns,{previousColumns:this.columns,newColumns:e,grid:this}),this.columns=e,this.updateColumnsInternal(),this.trigger(this.onAfterSetColumns,{newColumns:e,grid:this})}updateColumns(){this.trigger(this.onBeforeUpdateColumns,{columns:this.columns,grid:this}),this.updateColumnsInternal()}updateColumnsInternal(){this.updateColumnProps(),this.updateColumnCaches(),this.initialized&&(this.setPaneFrozenClasses(),this.setPaneVisibility(),this.setOverflow(),this.invalidateAllRows(),this.createColumnHeaders(),this.createColumnFooter(),this.removeCssRules(),this.createCssRules(),this.resizeCanvas(),this.updateCanvasWidth(),this.applyColumnHeaderWidths(),this.applyColumnWidths(),this.handleScroll(),this.getSelectionModel()?.refreshSelections())}getEditorLock(){return this._options.editorLock}getEditController(){return this.editController}setData(e,t){this.data=e,this.invalidateAllRows(),this.updateRowCount(),t&&this.scrollTo(0)}getData(){return this.data}getDataLength(){return this.data.getLength?this.data.getLength():this.data?.length??0}getDataLengthIncludingAddNew(){return this.getDataLength()+(this._options.enableAddRow&&(!this.pagingActive||this.pagingIsLastPage)?1:0)}getDataItem(e){return this.data.getItem?this.data.getItem(e):this.data[e]}hasDataView(){return!Array.isArray(this.data)}getItemMetadaWhenExists(e){return"getItemMetadata"in this.data?this.data.getItemMetadata(e):null}getFormatter(e,t){let n=this.data?.getItemMetadata?.(e);return(n?.columns&&(n.columns[t.id]||n.columns[this.getColumnIndex(t.id)]))?.formatter||n?.formatter||t.formatter||this._options.formatterFactory?.getFormatter(t)||this._options.defaultFormatter}getEditor(e,t){let n=this.columns[t],o=this.getItemMetadaWhenExists(e)?.columns;return o?.[n.id]?.editor!==void 0?o[n.id].editor:o?.[t]?.editor!==void 0?o[t].editor:n.editor||this._options?.editorFactory?.getEditor(n)}getDataItemValueForColumn(e,t){return this._options.dataItemColumnValueExtractor?this._options.dataItemColumnValueExtractor(e,t):e[t.field]}resetActiveCell(){this.setActiveCellInternal(null,!1)}unsetActiveCell(){L.isDefined(this.activeCellNode)&&(this.makeActiveCellNormal(),this.activeCellNode.classList.remove("active"),this.rowsCache[this.activeRow]?.rowNode?.forEach(e=>e.classList.remove("active")))}focus(){this.setFocus()}setFocus(){this.tabbingDirection===-1?this._focusSink.focus():this._focusSink2.focus()}setActiveCellInternal(e,t,n,o,r){if(this.unsetActiveCell(),this.activeCellNode=e,L.isDefined(this.activeCellNode)){let i=L.offset(this.activeCellNode),a=Math.floor(L.offset(L.parents(this.activeCellNode,".grid-canvas")[0]).top),l=L.parents(this.activeCellNode,".grid-canvas-bottom").length;this.hasFrozenRows&&l&&(a-=this._options.frozenBottom?L.height(this._canvasTopL):this.frozenRowsHeight);let d=this.getCellFromPoint(i.left,Math.ceil(i.top)-a);this.activeRow=d.row,this.activePosY=d.row,this.activeCell=this.activePosX=this.getCellFromNode(this.activeCellNode),!L.isDefined(t)&&this._options.autoEditNewRow&&(t=this.activeRow===this.getDataLength()||this._options.autoEdit),this._options.showCellSelection&&(document.querySelectorAll(".slick-cell.active").forEach(u=>u.classList.remove("active")),this.activeCellNode.classList.add("active"),this.rowsCache[this.activeRow]?.rowNode?.forEach(u=>u.classList.add("active"))),this._options.editable&&t&&this.isCellPotentiallyEditable(this.activeRow,this.activeCell)&&(this._options.asyncEditorLoading?(window.clearTimeout(this.h_editorLoader),this.h_editorLoader=window.setTimeout(()=>{this.makeActiveCellEditable(void 0,n,r)},this._options.asyncEditorLoadDelay)):this.makeActiveCellEditable(void 0,n,r))}else this.activeRow=this.activeCell=null;o||this.trigger(this.onActiveCellChanged,this.getActiveCell())}isCellPotentiallyEditable(e,t){let n=this.getDataLength();return!(e<n&&!this.getDataItem(e)||this.columns[t].cannotTriggerInsert&&e>=n||!this.columns[t]||this.columns[t].hidden||!this.getEditor(e,t))}makeActiveCellNormal(e=!1){if(this.currentEditor){if(this.trigger(this.onBeforeCellEditorDestroy,{editor:this.currentEditor}),this.currentEditor.destroy(),this.currentEditor=null,this.activeCellNode){let t=this.getDataItem(this.activeRow);if(this.activeCellNode.classList.remove("editable"),this.activeCellNode.classList.remove("invalid"),t){let n=this.columns[this.activeCell],o=this.getFormatter(this.activeRow,n)(this.activeRow,this.activeCell,this.getDataItemValueForColumn(t,n),n,t,this);this.applyFormatResultToCellNode(o,this.activeCellNode),this.invalidatePostProcessingResults(this.activeRow)}e&&this.setFocus()}navigator.userAgent.toLowerCase().match(/msie/)&&this.clearTextSelection(),this.getEditorLock()?.deactivate(this.editController)}}editActiveCell(e,t,n){this.makeActiveCellEditable(e,t,n)}makeActiveCellEditable(e,t,n){if(!this.activeCellNode)return;if(!this._options.editable)throw new Error("SlickGrid makeActiveCellEditable : should never get called when this._options.editable is false");if(window.clearTimeout(this.h_editorLoader),!this.isCellPotentiallyEditable(this.activeRow,this.activeCell))return;let o=this.columns[this.activeCell],r=this.getDataItem(this.activeRow);if(this.trigger(this.onBeforeEditCell,{row:this.activeRow,cell:this.activeCell,item:r,column:o,target:"grid"}).getReturnValue()===!1){this.setFocus();return}this.getEditorLock()?.activate(this.editController),this.activeCellNode.classList.add("editable");let i=e||this.getEditor(this.activeRow,this.activeCell);if(!i||typeof i!="function")return;!e&&!i.suppressClearOnEdit&&L.emptyElement(this.activeCellNode);let a=this.getItemMetadaWhenExists(this.activeRow);a=a?.columns;let l=a&&(a[o.id]||a[this.activeCell]),d={grid:this,gridPosition:this.absBox(this._container),position:this.absBox(this.activeCellNode),container:this.activeCellNode,column:o,columnMetaData:l,item:r||{},event:n,commitChanges:this.commitEditAndSetFocus.bind(this),cancelChanges:this.cancelEditAndSetFocus.bind(this)};this.currentEditor=new i(d),r&&this.currentEditor&&(this.currentEditor.loadValue(r),t&&this.currentEditor?.preClick&&this.currentEditor.preClick()),this.serializedEditorValue=this.currentEditor?.serializeValue(),this.currentEditor?.position&&this.handleActiveCellPositionChange()}commitEditAndSetFocus(){this.getEditorLock()?.commitCurrentEdit()&&(this.setFocus(),this._options.autoEdit&&!this._options.autoCommitEdit&&this.navigateDown())}cancelEditAndSetFocus(){this.getEditorLock()?.cancelCurrentEdit()&&this.setFocus()}commitCurrentEdit(){let e=this,t=e.getDataItem(e.activeRow),n=e.columns[e.activeCell];if(e.currentEditor){if(e.currentEditor.isValueChanged()){let o=e.currentEditor.validate();if(o.valid){let r=e.activeRow,i=e.activeCell,a=e.currentEditor,l=e.currentEditor.serializeValue(),d=e.serializedEditorValue;if(e.activeRow<e.getDataLength()){let u={row:r,cell:i,editor:a,serializedValue:l,prevSerializedValue:d,execute:()=>{a.applyValue(t,l),e.updateRow(r),e.trigger(e.onCellChange,{command:"execute",row:r,cell:i,item:t,column:n})},undo:()=>{a.applyValue(t,d),e.updateRow(r),e.trigger(e.onCellChange,{command:"undo",row:r,cell:i,item:t,column:n})}};e._options.editCommandHandler?(e.makeActiveCellNormal(!0),e._options.editCommandHandler(t,n,u)):(u.execute(),e.makeActiveCellNormal(!0))}else{let u={};e.currentEditor.applyValue(u,e.currentEditor.serializeValue()),e.makeActiveCellNormal(!0),e.trigger(e.onAddNewRow,{item:u,column:n})}return!e.getEditorLock()?.isActive()}else return e.activeCellNode&&(e.activeCellNode.classList.remove("invalid"),L.width(e.activeCellNode),e.activeCellNode.classList.add("invalid")),e.trigger(e.onValidationError,{editor:e.currentEditor,cellNode:e.activeCellNode,validationResults:o,row:e.activeRow,cell:e.activeCell,column:n}),e.currentEditor.focus(),!1}e.makeActiveCellNormal(!0)}return!0}cancelCurrentEdit(){return this.makeActiveCellNormal(),!0}getSelectedRows(){if(!this.selectionModel)throw new Error("SlickGrid Selection model is not set");return this.selectedRows.slice(0)}setSelectedRows(e,t){if(!this.selectionModel)throw new Error("SlickGrid Selection model is not set");this&&this.getEditorLock&&!this.getEditorLock()?.isActive()&&this.selectionModel.setSelectedRanges(this.rowsToRanges(e),t||"SlickGrid.setSelectedRows")}trigger(e,t,n){let o=n||new li(n,t),r=t||{};return r.grid=this,e.notify(r,o,this)}handleCellMouseOut(e){this.trigger(this.onMouseLeave,{},e)}handleHeaderMouseHoverOn(e){e?.target.classList.add("ui-state-hover","slick-state-hover")}handleHeaderMouseHoverOff(e){e?.target.classList.remove("ui-state-hover","slick-state-hover")}handleSelectedRangesChanged(e,t){let n=e.getNativeEvent(),o=this.selectedRows.slice(0);this.selectedRows=[];let r={};for(let i=0;i<t.length;i++)for(let a=t[i].fromRow;a<=t[i].toRow;a++){r[a]||(this.selectedRows.push(a),r[a]={});for(let l=t[i].fromCell;l<=t[i].toCell;l++)this.canCellBeSelected(a,l)&&(r[a][this.columns[l].id]=this._options.selectedCellCssClass)}if(this.setCellCssStyles(this._options.selectedCellCssClass||"",r),this.simpleArrayEquals(o,this.selectedRows)){let i=n?.detail?.caller??"click",a=new Set(this.getSelectedRows()),l=new Set(o),d=Array.from(a).filter(f=>!l.has(f)),u=Array.from(l).filter(f=>!a.has(f));this.trigger(this.onSelectedRowsChanged,{rows:this.getSelectedRows(),previousSelectedRows:o,caller:i,changedSelectedRows:d,changedUnselectedRows:u},e)}}handleMouseWheel(e,t,n,o){this.scrollHeight=this._viewportScrollContainerY.scrollHeight,e.shiftKey?this.scrollLeft=this._viewportScrollContainerX.scrollLeft+n*10:(this.scrollTop=Math.max(0,this._viewportScrollContainerY.scrollTop-o*this._options.rowHeight),this.scrollLeft=this._viewportScrollContainerX.scrollLeft+n*10),this._handleScroll("mousewheel")&&e.stopPropagation()}handleDragInit(e,t){let n=this.getCellFromEvent(e);if(!n||!this.cellExists(n.row,n.cell))return!1;let o=this.trigger(this.onDragInit,t,e);return o.isImmediatePropagationStopped()?o.getReturnValue():!1}handleDragStart(e,t){let n=this.getCellFromEvent(e);if(!n||!this.cellExists(n.row,n.cell))return!1;let o=this.trigger(this.onDragStart,t,e);return o.isImmediatePropagationStopped()?o.getReturnValue():!1}handleDrag(e,t){return this.trigger(this.onDrag,t,e).getReturnValue()}handleDragEnd(e,t){this.trigger(this.onDragEnd,t,e)}handleKeyDown(e){let t=this.trigger(this.onKeyDown,{row:this.activeRow,cell:this.activeCell},e).isImmediatePropagationStopped();if(!t&&!e.shiftKey&&!e.altKey){if(this._options.editable&&this.currentEditor?.keyCaptureList&&this.currentEditor.keyCaptureList.indexOf(e.which)>-1)return;e.ctrlKey&&e.key==="Home"?this.navigateTopStart():e.ctrlKey&&e.key==="End"?this.navigateBottomEnd():e.ctrlKey&&e.key==="ArrowUp"?this.navigateTop():e.ctrlKey&&e.key==="ArrowDown"?this.navigateBottom():e.ctrlKey&&e.key==="ArrowLeft"||!e.ctrlKey&&e.key==="Home"?this.navigateRowStart():(e.ctrlKey&&e.key==="ArrowRight"||!e.ctrlKey&&e.key==="End")&&this.navigateRowEnd()}if(!t)if(!e.shiftKey&&!e.altKey&&!e.ctrlKey){if(this._options.editable&&this.currentEditor?.keyCaptureList&&this.currentEditor.keyCaptureList.indexOf(e.which)>-1)return;if(e.which===go.ESCAPE){if(!this.getEditorLock()?.isActive())return;this.cancelEditAndSetFocus()}else e.which===go.PAGE_DOWN?(this.navigatePageDown(),t=!0):e.which===go.PAGE_UP?(this.navigatePageUp(),t=!0):e.which===go.LEFT?t=this.navigateLeft():e.which===go.RIGHT?t=this.navigateRight():e.which===go.UP?t=this.navigateUp():e.which===go.DOWN?t=this.navigateDown():e.which===go.TAB?t=this.navigateNext():e.which===go.ENTER&&(this._options.editable&&(this.currentEditor?this.activeRow===this.getDataLength()?this.navigateDown():this.commitEditAndSetFocus():this.getEditorLock()?.commitCurrentEdit()&&this.makeActiveCellEditable(void 0,void 0,e)),t=!0)}else e.which===go.TAB&&e.shiftKey&&!e.ctrlKey&&!e.altKey&&(t=this.navigatePrev());if(t){e.stopPropagation(),e.preventDefault();try{e.originalEvent.keyCode=0}catch{}}}handleClick(e){let t=e instanceof li?e.getNativeEvent():e;if(!this.currentEditor&&(t.target!==document.activeElement||t.target.classList.contains("slick-cell"))){let o=this.getTextSelection();this.setFocus(),this.setTextSelection(o)}let n=this.getCellFromEvent(t);if(!(!n||this.currentEditor!==null&&this.activeRow===n.row&&this.activeCell===n.cell)&&(e=this.trigger(this.onClick,{row:n.row,cell:n.cell},e||t),!e.isImmediatePropagationStopped()&&this.canCellBeActive(n.row,n.cell)&&(!this.getEditorLock()?.isActive()||this.getEditorLock()?.commitCurrentEdit()))){this.scrollRowIntoView(n.row,!1);let o=t.target?.className===lA,r=this.columns[n.cell],i=!!(this._options.editable&&r?.editor&&this._options.suppressActiveCellChangeOnEdit);this.setActiveCellInternal(this.getCellNode(n.row,n.cell),null,o,i,t)}}handleContextMenu(e){let t=e.target.closest(".slick-cell");t&&(this.activeCellNode===t&&this.currentEditor!==null||this.trigger(this.onContextMenu,{},e))}handleDblClick(e){let t=this.getCellFromEvent(e);!t||this.currentEditor!==null&&this.activeRow===t.row&&this.activeCell===t.cell||(this.trigger(this.onDblClick,{row:t.row,cell:t.cell},e),!e.defaultPrevented&&this._options.editable&&this.gotoCell(t.row,t.cell,!0,e))}handleHeaderMouseEnter(e){let t=L.storage.get(e.target.closest(".slick-header-column"),"column");t&&this.trigger(this.onHeaderMouseEnter,{column:t,grid:this},e)}handleHeaderMouseLeave(e){let t=L.storage.get(e.target.closest(".slick-header-column"),"column");t&&this.trigger(this.onHeaderMouseLeave,{column:t,grid:this},e)}handleHeaderRowMouseEnter(e){let t=L.storage.get(e.target.closest(".slick-headerrow-column"),"column");t&&this.trigger(this.onHeaderRowMouseEnter,{column:t,grid:this},e)}handleHeaderRowMouseLeave(e){let t=L.storage.get(e.target.closest(".slick-headerrow-column"),"column");t&&this.trigger(this.onHeaderRowMouseLeave,{column:t,grid:this},e)}handleHeaderContextMenu(e){let t=e.target.closest(".slick-header-column"),n=t&&L.storage.get(t,"column");this.trigger(this.onHeaderContextMenu,{column:n},e)}handleHeaderClick(e){if(!this.columnResizeDragging){let t=e.target.closest(".slick-header-column"),n=t&&L.storage.get(t,"column");n&&this.trigger(this.onHeaderClick,{column:n},e)}}handlePreHeaderContextMenu(e){this.trigger(this.onPreHeaderContextMenu,{node:e.target},e)}handlePreHeaderClick(e){this.columnResizeDragging||this.trigger(this.onPreHeaderClick,{node:e.target},e)}handleFooterContextMenu(e){let t=e.target.closest(".slick-footerrow-column"),n=t&&L.storage.get(t,"column");this.trigger(this.onFooterContextMenu,{column:n},e)}handleFooterClick(e){let t=e.target.closest(".slick-footerrow-column"),n=t&&L.storage.get(t,"column");this.trigger(this.onFooterClick,{column:n},e)}handleCellMouseOver(e){this.trigger(this.onMouseEnter,{},e)}handleActiveCellPositionChange(){if(this.activeCellNode&&(this.trigger(this.onActiveCellPositionChanged,{}),this.currentEditor)){let e=this.getActiveCellPosition();this.currentEditor.show&&this.currentEditor.hide&&(e.visible?this.currentEditor.show():this.currentEditor.hide()),this.currentEditor.position&&this.currentEditor.position(e)}}actionThrottle(e,t){let n=!1,o=!1,r=()=>{n?o=!0:a()},i=()=>{o=!1},a=()=>{n=!0,window.clearTimeout(this._executionBlockTimer),this._executionBlockTimer=window.setTimeout(l,t),e.call(this)},l=()=>{o?(i(),a()):n=!1};return{enqueue:r.bind(this),dequeue:i.bind(this)}}getCellFromEvent(e){let t=e instanceof li?e.getNativeEvent():e,n=t.touches?t.touches[0]:t,o=t.target.closest(".slick-cell");if(!o)return null;let r=this.getRowFromNode(o.parentNode);if(this.hasFrozenRows){let a=0,l=L.offset(L.parents(o,".grid-canvas")[0]);L.parents(o,".grid-canvas-bottom").length&&(a=this._options.frozenBottom?L.height(this._canvasTopL):this.frozenRowsHeight),r=this.getCellFromPoint(n.clientX-l.left,n.clientY-l.top+a+document.documentElement.scrollTop).row}let i=this.getCellFromNode(o);return!L.isDefined(r)||!L.isDefined(i)?null:{row:r,cell:i}}applyHtmlCode(e,t,n){if(e)if(t instanceof HTMLElement||t instanceof DocumentFragment)n?.emptyTarget!==!1&&L.emptyElement(e),e.appendChild(t);else{if(n?.skipEmptyReassignment!==!1&&!L.isDefined(t)&&!e.innerHTML)return;let o=t;typeof o=="number"||typeof o=="boolean"?e.textContent=o:(o=this.sanitizeHtmlString(t),this._options.enableHtmlRendering&&o?e.innerHTML=o:e.textContent=o)}}getCanvasNode(e,t){return this._getContainerElement(this.getCanvases(),e,t)}getActiveCanvasNode(e){return e===void 0?this._activeCanvasNode:(e instanceof li&&(e=e.getNativeEvent()),this._activeCanvasNode=e?.target.closest(".grid-canvas"),this._activeCanvasNode)}getCanvases(){return this._canvas}getViewportNode(e,t){return this._getContainerElement(this.getViewports(),e,t)}getViewports(){return this._viewport}getActiveViewportNode(e){return this.setActiveViewportNode(e),this._activeViewportNode}setActiveViewportNode(e){return e instanceof li&&(e=e.getNativeEvent()),this._activeViewportNode=e?.target.closest(".slick-viewport"),this._activeViewportNode}getHeadersWidth(){this.headersWidth=this.headersWidthL=this.headersWidthR=0;let e=!this._options.autoHeight,t=0,n=this.columns.length;for(t=0;t<n;t++){if(!this.columns[t]||this.columns[t].hidden)continue;let o=this.columns[t].width;this._options.frozenColumn>-1&&t>this._options.frozenColumn?this.headersWidthR+=o||0:this.headersWidthL+=o||0}return e&&(this._options.frozenColumn>-1&&t>this._options.frozenColumn?this.headersWidthR+=this.scrollbarDimensions?.width??0:this.headersWidthL+=this.scrollbarDimensions?.width??0),this.hasFrozenColumns()?(this.headersWidthL=this.headersWidthL+1e3,this.headersWidthR=Math.max(this.headersWidthR,this.viewportW)+this.headersWidthL,this.headersWidthR+=this.scrollbarDimensions?.width??0):(this.headersWidthL+=this.scrollbarDimensions?.width??0,this.headersWidthL=Math.max(this.headersWidthL,this.viewportW)+1e3),this.headersWidth=this.headersWidthL+this.headersWidthR,Math.max(this.headersWidth,this.viewportW)+1e3}getCanvasWidth(){let e=this.getViewportInnerWidth(),t=this.columns.length;for(this.canvasWidthL=this.canvasWidthR=0;t--;)!this.columns[t]||this.columns[t].hidden||(this.hasFrozenColumns()&&t>this._options.frozenColumn?this.canvasWidthR+=this.columns[t].width||0:this.canvasWidthL+=this.columns[t].width||0);let n=this.canvasWidthL+this.canvasWidthR;if(this._options.fullWidthRows){let o=Math.max(n,e)-n;o>0&&(n+=o,this.hasFrozenColumns()?this.canvasWidthR+=o:this.canvasWidthL+=o)}return n}updateCanvasWidth(e){let t=this.canvasWidth,n=this.canvasWidthL,o=this.canvasWidthR;this.canvasWidth=this.getCanvasWidth(),this._options.createTopHeaderPanel&&L.width(this._topHeaderPanel,this._options.topHeaderPanelWidth??this.canvasWidth);let r=this.canvasWidth!==t||this.canvasWidthL!==n||this.canvasWidthR!==o;if(r||this.hasFrozenColumns()||this.hasFrozenRows)if(L.width(this._canvasTopL,this.canvasWidthL),this.getHeadersWidth(),L.width(this._headerL,this.headersWidthL),L.width(this._headerR,this.headersWidthR),this.hasFrozenColumns()){let i=L.width(this._container)||0;if(i>0&&this.canvasWidthL>i&&this._options.throwWhenFrozenNotAllViewable)throw new Error("[SlickGrid] Frozen columns cannot be wider than the actual grid container width. Make sure to have less columns freezed or make your grid container wider");L.width(this._canvasTopR,this.canvasWidthR),L.width(this._paneHeaderL,this.canvasWidthL),L.setStyleSize(this._paneHeaderR,"left",this.canvasWidthL),L.setStyleSize(this._paneHeaderR,"width",this.viewportW-this.canvasWidthL),L.width(this._paneTopL,this.canvasWidthL),L.setStyleSize(this._paneTopR,"left",this.canvasWidthL),L.width(this._paneTopR,this.viewportW-this.canvasWidthL),L.width(this._headerRowScrollerL,this.canvasWidthL),L.width(this._headerRowScrollerR,this.viewportW-this.canvasWidthL),L.width(this._headerRowL,this.canvasWidthL),L.width(this._headerRowR,this.canvasWidthR),this._options.createFooterRow&&(L.width(this._footerRowScrollerL,this.canvasWidthL),L.width(this._footerRowScrollerR,this.viewportW-this.canvasWidthL),L.width(this._footerRowL,this.canvasWidthL),L.width(this._footerRowR,this.canvasWidthR)),this._options.createPreHeaderPanel&&L.width(this._preHeaderPanel,this._options.preHeaderPanelWidth??this.canvasWidth),L.width(this._viewportTopL,this.canvasWidthL),L.width(this._viewportTopR,this.viewportW-this.canvasWidthL),this.hasFrozenRows&&(L.width(this._paneBottomL,this.canvasWidthL),L.setStyleSize(this._paneBottomR,"left",this.canvasWidthL),L.width(this._viewportBottomL,this.canvasWidthL),L.width(this._viewportBottomR,this.viewportW-this.canvasWidthL),L.width(this._canvasBottomL,this.canvasWidthL),L.width(this._canvasBottomR,this.canvasWidthR))}else L.width(this._paneHeaderL,"100%"),L.width(this._paneTopL,"100%"),L.width(this._headerRowScrollerL,"100%"),L.width(this._headerRowL,this.canvasWidth),this._options.createFooterRow&&(L.width(this._footerRowScrollerL,"100%"),L.width(this._footerRowL,this.canvasWidth)),this._options.createPreHeaderPanel&&L.width(this._preHeaderPanel,this._options.preHeaderPanelWidth??this.canvasWidth),L.width(this._viewportTopL,"100%"),this.hasFrozenRows&&(L.width(this._viewportBottomL,"100%"),L.width(this._canvasBottomL,this.canvasWidthL));this.viewportHasHScroll=this.canvasWidth>=this.viewportW-(this.scrollbarDimensions?.width??0),L.width(this._headerRowSpacerL,this.canvasWidth+(this.viewportHasVScroll?this.scrollbarDimensions?.width??0:0)),L.width(this._headerRowSpacerR,this.canvasWidth+(this.viewportHasVScroll?this.scrollbarDimensions?.width??0:0)),this._options.createFooterRow&&(L.width(this._footerRowSpacerL,this.canvasWidth+(this.viewportHasVScroll?this.scrollbarDimensions?.width??0:0)),L.width(this._footerRowSpacerR,this.canvasWidth+(this.viewportHasVScroll?this.scrollbarDimensions?.width??0:0))),(r||e)&&this.applyColumnWidths()}getPreHeaderPanel(){return this._preHeaderPanel}getPreHeaderPanelLeft(){return this._preHeaderPanel}getPreHeaderPanelRight(){return this._preHeaderPanelR}getTopHeaderPanel(){return this._topHeaderPanel}setPaneVisibility(){this.hasFrozenColumns()?(L.show(this._paneHeaderR),L.show(this._paneTopR),this.hasFrozenRows?(L.show(this._paneBottomL),L.show(this._paneBottomR)):(L.hide(this._paneBottomR),L.hide(this._paneBottomL))):(L.hide(this._paneHeaderR),L.hide(this._paneTopR),L.hide(this._paneBottomR),this.hasFrozenRows?L.show(this._paneBottomL):(L.hide(this._paneBottomR),L.hide(this._paneBottomL)))}setOverflow(){if(this._viewportTopL.style.overflowX=this.hasFrozenColumns()?this.hasFrozenRows&&!this._options.alwaysAllowHorizontalScroll?"hidden":"scroll":this.hasFrozenRows&&!this._options.alwaysAllowHorizontalScroll?"hidden":"auto",this._viewportTopL.style.overflowY=!this.hasFrozenColumns()&&this._options.alwaysShowVerticalScroll?"scroll":this.hasFrozenColumns()?(this.hasFrozenRows,"hidden"):this.hasFrozenRows?"scroll":"auto",this._viewportTopR.style.overflowX=this.hasFrozenColumns()?this.hasFrozenRows&&!this._options.alwaysAllowHorizontalScroll?"hidden":"scroll":this.hasFrozenRows&&!this._options.alwaysAllowHorizontalScroll?"hidden":"auto",this._viewportTopR.style.overflowY=this._options.alwaysShowVerticalScroll?"scroll":this.hasFrozenColumns()?this.hasFrozenRows?"scroll":"auto":this.hasFrozenRows?"scroll":"auto",this._viewportBottomL.style.overflowX=this.hasFrozenColumns()?this.hasFrozenRows&&!this._options.alwaysAllowHorizontalScroll?"scroll":"auto":(this.hasFrozenRows&&this._options.alwaysAllowHorizontalScroll,"auto"),this._viewportBottomL.style.overflowY=!this.hasFrozenColumns()&&this._options.alwaysShowVerticalScroll?"scroll":this.hasFrozenColumns()?(this.hasFrozenRows,"hidden"):this.hasFrozenRows?"scroll":"auto",this._viewportBottomR.style.overflowX=this.hasFrozenColumns()?this.hasFrozenRows&&!this._options.alwaysAllowHorizontalScroll?"scroll":"auto":(this.hasFrozenRows&&this._options.alwaysAllowHorizontalScroll,"auto"),this._viewportBottomR.style.overflowY=this._options.alwaysShowVerticalScroll?"scroll":this.hasFrozenColumns()?(this.hasFrozenRows,"auto"):(this.hasFrozenRows,"auto"),this._options.viewportClass){let e=L.classNameToList(this._options.viewportClass);this._viewportTopL.classList.add(...e),this._viewportTopR.classList.add(...e),this._viewportBottomL.classList.add(...e),this._viewportBottomR.classList.add(...e)}}createCssRules(){this._style=document.createElement("style"),this._style.nonce=this._options.nonce||"",(this._options.shadowRoot||document.head).appendChild(this._style);let e=this._options.rowHeight-this.cellHeightDiff,t=[`.${this.uid} .slick-group-header-column { left: 1000px; }`,`.${this.uid} .slick-header-column { left: 1000px; }`,`.${this.uid} .slick-top-panel { height: ${this._options.topPanelHeight}px; }`,`.${this.uid} .slick-preheader-panel { height: ${this._options.preHeaderPanelHeight}px; }`,`.${this.uid} .slick-topheader-panel { height: ${this._options.topHeaderPanelHeight}px; }`,`.${this.uid} .slick-headerrow-columns { height: ${this._options.headerRowHeight}px; }`,`.${this.uid} .slick-footerrow-columns { height: ${this._options.footerRowHeight}px; }`,`.${this.uid} .slick-cell { height: ${e}px; }`,`.${this.uid} .slick-row { height: ${this._options.rowHeight}px; }`],n=this._style.sheet;if(n){t.forEach(o=>{n.insertRule(o)});for(let o=0;o<this.columns.length;o++)!this.columns[o]||this.columns[o].hidden||(n.insertRule(`.${this.uid} .l${o} { }`),n.insertRule(`.${this.uid} .r${o} { }`))}else this.createCssRulesAlternative(t)}createCssRulesAlternative(e){let t=document.createElement("template");t.innerHTML='<style type="text/css" rel="stylesheet" />',this._style=t.content.firstChild,(this._options.shadowRoot||document.head).appendChild(this._style);for(let n=0;n<this.columns.length;n++)!this.columns[n]||this.columns[n].hidden||(e.push(`.${this.uid} .l${n} { }`),e.push(`.${this.uid} .r${n} { }`));this._style.styleSheet?this._style.styleSheet.cssText=e.join(" "):this._style.appendChild(document.createTextNode(e.join(" ")))}getColumnCssRules(e){let t;if(!this.stylesheet){let n=(this._options.shadowRoot||document).styleSheets;for(this._options.devMode&&typeof this._options.devMode?.ownerNodeIndex=="number"&&this._options.devMode.ownerNodeIndex>=0&&(n[this._options.devMode.ownerNodeIndex].ownerNode=this._style),t=0;t<n.length;t++)if((n[t].ownerNode||n[t].owningElement)===this._style){this.stylesheet=n[t];break}if(!this.stylesheet)throw new Error("SlickGrid Cannot find stylesheet.");this.columnCssRulesL=[],this.columnCssRulesR=[];let o=this.stylesheet.cssRules||this.stylesheet.rules,r,i;for(t=0;t<o.length;t++){let a=o[t].selectorText;(r=/\.l\d+/.exec(a))?(i=parseInt(r[0].substr(2,r[0].length-2),10),this.columnCssRulesL[i]=o[t]):(r=/\.r\d+/.exec(a))&&(i=parseInt(r[0].substr(2,r[0].length-2),10),this.columnCssRulesR[i]=o[t])}}return{left:this.columnCssRulesL[e],right:this.columnCssRulesR[e]}}removeCssRules(){this._style?.remove(),this.stylesheet=null}getTopPanel(){return this._topPanels[0]}getTopPanels(){return this._topPanels}togglePanelVisibility(e,t,n,o){let r=o!==!1;if(this._options[e]!==n)if(this._options[e]=n,n){if(r){L.slideDown(t,this.resizeCanvas.bind(this));return}L.show(t),this.resizeCanvas()}else{if(r){L.slideUp(t,this.resizeCanvas.bind(this));return}L.hide(t),this.resizeCanvas()}}setTopPanelVisibility(e,t){this.togglePanelVisibility("showTopPanel",this._topPanelScrollers,e,t)}setHeaderRowVisibility(e,t){this.togglePanelVisibility("showHeaderRow",this._headerRowScroller,e,t)}setColumnHeaderVisibility(e,t){this.togglePanelVisibility("showColumnHeader",this._headerScroller,e,t)}setFooterRowVisibility(e,t){this.togglePanelVisibility("showFooterRow",this._footerRowScroller,e,t)}setPreHeaderPanelVisibility(e,t){this.togglePanelVisibility("showPreHeaderPanel",[this._preHeaderPanelScroller,this._preHeaderPanelScrollerR],e,t)}setTopHeaderPanelVisibility(e){this.togglePanelVisibility("showTopHeaderPanel",this._topHeaderPanelScroller,e)}getRowHeight(){return this._options.rowHeight}getRowTop(e){return Math.round(this._options.rowHeight*e-this.offset)}getRowBottom(e){return this.getRowTop(e)+this._options.rowHeight}getRowFromPosition(e){return Math.floor((e+this.offset)/this._options.rowHeight)}appendRowHtml(e,t,n,o,r){let i=this.getDataItem(n),a=n<r&&!i,l="slick-row"+(this.hasFrozenRows&&n<=this._options.frozenRow?" frozen":"")+(a?" loading":"")+(n===this.activeRow&&this._options.showCellSelection?" active":"")+(n%2===1?" odd":" even");i||(l+=` ${this._options.addNewRowCssClass}`);let d=this.getItemMetadaWhenExists(n);d?.cssClasses&&(l+=` ${d.cssClasses}`);let u=L.createDomElement("div",{className:`ui-widget-content ${l}`,role:"row",dataset:{row:`${n}`}}),f=this.getFrozenRowOffset(n),p=this.getRowTop(n)-f;this._options.rowTopOffsetRenderType==="transform"?u.style.transform=`translateY(${p}px)`:u.style.top=`${p}px`;let y;e.push(u),this.hasFrozenColumns()&&(y=u.cloneNode(!0),t.push(y));let b=this.columns.length,w,g,v,E,P=!0;for(let x=0,S=b;x<S;x++){if(P=!0,E=this.columns[x],!E||E.hidden)continue;g=1,v=1,w=null,d?.columns&&(w=d.columns[E.id]||d.columns[x],g=w?.colspan||1,v=w?.rowspan||1,g==="*"&&(g=S-x),v>r-n&&(v=r-n)),!this._options.enableCellRowSpan&&v>1&&console.warn('[SlickGrid] Cell "rowspan" is an opt-in grid option because of its small perf hit, you must enable it via the "enableCellRowSpan" grid option.');let C=g;if(!this.getParentRowSpanByCell(n,x)){if(this.columnPosRight[Math.min(S-1,x+C-1)]>o.leftPx){if(!E.alwaysRenderColumn&&this.columnPosLeft[x]>o.rightPx&&(P=!1),P){let O=this.hasFrozenColumns()&&x>this._options.frozenColumn?y:u;this.appendCellHtml(O,n,x,C,v,w,i)}}else(E.alwaysRenderColumn||this.hasFrozenColumns()&&x<=this._options.frozenColumn)&&this.appendCellHtml(u,n,x,C,v,w,i);C>1&&(x+=C-1)}}}appendCellHtml(e,t,n,o,r,i,a){let l=this.columns[n],d=`slick-cell l${n} r${Math.min(this.columns.length-1,n+o-1)}`+(l.cssClass?` ${l.cssClass}`:"")+(r>1?" rowspan":"")+(i?.cssClass?` ${i.cssClass}`:"");this.hasFrozenColumns()&&n<=this._options.frozenColumn&&(d+=" frozen"),t===this.activeRow&&n===this.activeCell&&this._options.showCellSelection&&(d+=" active"),Object.keys(this.cellCssClasses).forEach(v=>{this.cellCssClasses[v][t]?.[l.id]&&(d+=` ${this.cellCssClasses[v][t][l.id]}`)});let u=null,f="";a&&(u=this.getDataItemValueForColumn(a,l),f=this.getFormatter(t,l)(t,n,u,l,a,this),f==null&&(f=""));let p=this.trigger(this.onBeforeAppendCell,{row:t,cell:n,value:u,dataContext:a}).getReturnValue(),y=typeof p=="string"?p:"";f?.addClasses&&(y+=L.classNameToList((y?" ":"")+f.addClasses).join(" "));let b=f?.toolTip?`${f.toolTip}`:"",w=L.createDomElement("div",{className:L.classNameToList(`${d} ${y||""}`).join(" "),role:"gridcell",tabIndex:-1});w.setAttribute("aria-describedby",this.uid+l.id),b&&w.setAttribute("title",b);let g=this.getCellHeight(t,r);if(r>1&&g!==this._options.rowHeight-this.cellHeightDiff&&(w.style.height=`${g||0}px`),l.hasOwnProperty("cellAttrs")&&l.cellAttrs instanceof Object&&Object.keys(l.cellAttrs).forEach(v=>{l.cellAttrs.hasOwnProperty(v)&&w.setAttribute(v,l.cellAttrs[v])}),a){let v=Object.prototype.toString.call(f)!=="[object Object]"?f:f.html||f.text;this.applyHtmlCode(w,v)}e.appendChild(w),f.insertElementAfterTarget&&L.insertAfterElement(w,f.insertElementAfterTarget),this.rowsCache[t].cellRenderQueue.push(n),this.rowsCache[t].cellColSpans[n]=o}cleanupRows(e){let t=new Set;if(this._options.enableCellRowSpan)for(let n=e.top,o=e.bottom;n<=o;n++){let r=this.getRowSpanIntersect(n);r!==null&&t.add(r)}Object.keys(this.rowsCache).forEach(n=>{if(this.rowsCache){let o=+n,r=!0;this.hasFrozenRows&&(this._options.frozenBottom&&o>=this.actualFrozenRow||!this._options.frozenBottom&&o<=this.actualFrozenRow)&&(r=!1),(o=parseInt(n,10))!==this.activeRow&&(o<e.top||o>e.bottom)&&r&&!t.has(o)&&this.removeRowFromCache(o)}}),this._options.enableAsyncPostRenderCleanup&&this.startPostProcessingCleanup()}invalidate(){this.updateRowCount(),this.invalidateAllRows(),this.render()}invalidateAllRows(){this.currentEditor&&this.makeActiveCellNormal(),typeof this.rowsCache=="object"&&Object.keys(this.rowsCache).forEach(e=>{this.rowsCache&&this.removeRowFromCache(+e)}),this._options.enableAsyncPostRenderCleanup&&this.startPostProcessingCleanup()}invalidateRows(e){if(!e||!e.length)return;let t;this.vScrollDir=0;let n=e.length,o=new Set,r=new Set,i=e.length>this._options.maxPartialRowSpanRemap||e.length===this.getDataLength()||this._prevInvalidatedRowsCount+e.length===this.getDataLength();for(let a=0;a<n;a++)if(t=e[a],this.currentEditor&&this.activeRow===t&&this.makeActiveCellNormal(),this.rowsCache[t]&&this.removeRowFromCache(t),this._options.enableCellRowSpan&&!i){o.add(t);let l=this.getRowSpanIntersect(t);l!==null&&o.add(l)}if(this._options.enableCellRowSpan&&!i){for(let a of Array.from(o)){let l=this.getRowSpanColumnIntersects(a);for(let d of l){let u=this.getParentRowSpanByCell(a,d);u&&this._colsWithRowSpanCache[d]&&(this._colsWithRowSpanCache[d].delete(u.range),r.add(u.range.split(":").map(Number)[0]))}}for(let a of Array.from(r))this.remapRowSpanMetadataByRow(a)}this._options.enableAsyncPostRenderCleanup&&this.startPostProcessingCleanup(),this._prevInvalidatedRowsCount=e.length}invalidateRow(e){if(e>=0){let t=[e];if(this._options.enableCellRowSpan){let n=this.getRowSpanIntersect(e);n!==null&&t.push(n)}this.invalidateRows(t)}}removeRowFromCache(e){let t=this.rowsCache[e];t?.rowNode&&(this.trigger(this.onBeforeRemoveCachedRow,{row:e}),this._options.enableAsyncPostRenderCleanup&&this.postProcessedRows[e]?this.queuePostProcessedRowForCleanup(t,this.postProcessedRows[e],e):t.rowNode?.forEach(n=>n.parentElement?.removeChild(n)),delete this.rowsCache[e],delete this.postProcessedRows[e],this.renderedRows--,this.counter_rows_removed++)}updateCell(e,t){let n=this.getCellNode(e,t);if(!n)return;let o=this.columns[t],r=this.getDataItem(e);if(this.currentEditor&&this.activeRow===e&&this.activeCell===t)this.currentEditor.loadValue(r);else{let i=r?this.getFormatter(e,o)(e,t,this.getDataItemValueForColumn(r,o),o,r,this):"";this.applyFormatResultToCellNode(i,n),this.invalidatePostProcessingResults(e)}}updateRow(e){let t=this.rowsCache[e];if(!t)return;this.ensureCellNodesInRowsCache(e);let n,o=this.getDataItem(e);Object.keys(t.cellNodesByColumnIdx).forEach(r=>{if(!t.cellNodesByColumnIdx.hasOwnProperty(r))return;let i=+r,a=this.columns[i],l=t.cellNodesByColumnIdx[i];e===this.activeRow&&i===this.activeCell&&this.currentEditor?this.currentEditor.loadValue(o):o?(n=this.getFormatter(e,a)(e,i,this.getDataItemValueForColumn(o,a),a,o,this),this.applyFormatResultToCellNode(n,l)):L.emptyElement(l)}),this.invalidatePostProcessingResults(e)}getViewportRowCount(){let e=this.getViewportHeight(),t=this.getScrollbarDimensions()?.height??0;return Math.floor((e-t)/this._options.rowHeight)}getViewportHeight(){if((!this._options.autoHeight||this._options.frozenColumn!==-1)&&(this.topPanelH=this._options.showTopPanel?this._options.topPanelHeight+this.getVBoxDelta(this._topPanelScrollers[0]):0,this.headerRowH=this._options.showHeaderRow?this._options.headerRowHeight+this.getVBoxDelta(this._headerRowScroller[0]):0,this.footerRowH=this._options.showFooterRow?this._options.footerRowHeight+this.getVBoxDelta(this._footerRowScroller[0]):0),this._options.autoHeight){let e=this._paneHeaderL.offsetHeight;e+=this._options.showPreHeaderPanel?this._options.preHeaderPanelHeight+this.getVBoxDelta(this._preHeaderPanelScroller):0,e+=this._options.showHeaderRow?this._options.headerRowHeight+this.getVBoxDelta(this._headerRowScroller[0]):0,e+=this._options.showFooterRow?this._options.footerRowHeight+this.getVBoxDelta(this._footerRowScroller[0]):0,e+=this.getCanvasWidth()>this.viewportW?this.scrollbarDimensions?.height??0:0,this.viewportH=this._options.rowHeight*this.getDataLengthIncludingAddNew()+(this._options.frozenColumn===-1?e:0)}else{let e=getComputedStyle(this._container),t=e.boxSizing!=="content-box"?this.getVBoxDelta(this._container):0,n=this._options.createTopHeaderPanel&&this._options.showTopHeaderPanel?this._options.topHeaderPanelHeight+this.getVBoxDelta(this._topHeaderPanelScroller):0,o=this._options.createPreHeaderPanel&&this._options.showPreHeaderPanel?this._options.preHeaderPanelHeight+this.getVBoxDelta(this._preHeaderPanelScroller):0,r=this._options.showColumnHeader?L.toFloat(L.height(this._headerScroller[0])):0;this.viewportH=L.toFloat(e.height)-L.toFloat(e.paddingTop)-L.toFloat(e.paddingBottom)-this.topPanelH-n-o-this.headerRowH-r-this.footerRowH-t}return this.numVisibleRows=Math.ceil(this.viewportH/this._options.rowHeight),this.viewportH}getViewportInnerWidth(){return this.viewportHasVScroll?this.viewportW-(this.scrollbarDimensions?.width||0):this.viewportW}getViewportWidth(){return this.viewportW=parseFloat(L.innerSize(this._container,"width"))||this._options.devMode&&this._options.devMode.containerClientWidth||0,this.viewportW}resizeCanvas(){if(!this.initialized)return;if(this.paneTopH=0,this.paneBottomH=0,this.viewportTopH=0,this.viewportBottomH=0,this.getViewportWidth(),this.getViewportHeight(),this.hasFrozenRows?this._options.frozenBottom?(this.paneTopH=this.viewportH-this.frozenRowsHeight-(this.scrollbarDimensions?.height??0),this.paneBottomH=this.frozenRowsHeight+(this.scrollbarDimensions?.height??0)):(this.paneTopH=this.frozenRowsHeight,this.paneBottomH=this.viewportH-this.frozenRowsHeight):this.paneTopH=this.viewportH,this.paneTopH+=this.topPanelH+this.headerRowH+this.footerRowH,this.hasFrozenColumns()&&this._options.autoHeight&&(this.paneTopH+=this.scrollbarDimensions?.height??0),this.viewportTopH=this.paneTopH-this.topPanelH-this.headerRowH-this.footerRowH,this._options.autoHeight){if(this.hasFrozenColumns()){let n=this.paneTopH+this._headerScrollerL.offsetHeight;n+=this.getVBoxDelta(this._container),this._options.showPreHeaderPanel&&(n+=this._options.preHeaderPanelHeight),L.height(this._container,n)}this._paneTopL.style.position="relative"}let e=L.height(this._paneHeaderL);e?e+=this._options.showTopHeaderPanel?this._options.topHeaderPanelHeight:0:e=(this._options.showHeaderRow?this._options.headerRowHeight:0)+(this._options.showPreHeaderPanel?this._options.preHeaderPanelHeight:0),L.setStyleSize(this._paneTopL,"top",e||e),L.height(this._paneTopL,this.paneTopH);let t=this._paneTopL.offsetTop+this.paneTopH;if(this._options.autoHeight||L.height(this._viewportTopL,this.viewportTopH),this.hasFrozenColumns()){let n=L.height(this._paneHeaderL);n&&(n+=this._options.showTopHeaderPanel?this._options.topHeaderPanelHeight:0),L.setStyleSize(this._paneTopR,"top",n),L.height(this._paneTopR,this.paneTopH),L.height(this._viewportTopR,this.viewportTopH),this.hasFrozenRows&&(L.setStyleSize(this._paneBottomL,"top",t),L.height(this._paneBottomL,this.paneBottomH),L.setStyleSize(this._paneBottomR,"top",t),L.height(this._paneBottomR,this.paneBottomH),L.height(this._viewportBottomR,this.paneBottomH))}else this.hasFrozenRows&&(L.width(this._paneBottomL,"100%"),L.height(this._paneBottomL,this.paneBottomH),L.setStyleSize(this._paneBottomL,"top",t));this.hasFrozenRows?(L.height(this._viewportBottomL,this.paneBottomH),this._options.frozenBottom?(L.height(this._canvasBottomL,this.frozenRowsHeight),this.hasFrozenColumns()&&L.height(this._canvasBottomR,this.frozenRowsHeight)):(L.height(this._canvasTopL,this.frozenRowsHeight),this.hasFrozenColumns()&&L.height(this._canvasTopR,this.frozenRowsHeight))):L.height(this._viewportTopR,this.viewportTopH),(!this.scrollbarDimensions||!this.scrollbarDimensions.width)&&(this.scrollbarDimensions=this.measureScrollbar()),this._options.autosizeColsMode===_n.LegacyForceFit&&this.autosizeColumns(),this.updateRowCount(),this.handleScroll(),this.lastRenderedScrollLeft=-1,this.render()}updateRowCount(){if(!this.initialized)return;let e=this.getDataLength();e>0&&e!==this._prevDataLength&&(this._rowSpanIsCached=!1),this._options.enableCellRowSpan&&!this._rowSpanIsCached&&this.remapAllColumnsRowSpan(),this._prevDataLength=e;let t=this.getDataLengthIncludingAddNew(),n=0,o=this.hasFrozenRows&&!this._options.frozenBottom?L.height(this._canvasBottomL):L.height(this._canvasTopL);this.hasFrozenRows?n=this.getDataLength()-this._options.frozenRow:n=t+(this._options.leaveSpaceForNewRows?this.numVisibleRows-1:0);let r=L.height(this._viewportScrollContainerY),i=this.viewportHasVScroll;this.viewportHasVScroll=this._options.alwaysShowVerticalScroll||!this._options.autoHeight&&n*this._options.rowHeight>r,this.makeActiveCellNormal();let a=e-1;typeof this.rowsCache=="object"&&Object.keys(this.rowsCache).forEach(d=>{let u=+d;u>a&&this.removeRowFromCache(u)}),this._options.enableAsyncPostRenderCleanup&&this.startPostProcessingCleanup(),this.activeCellNode&&this.activeRow>a&&this.resetActiveCell(),o=this.h,this._options.autoHeight?this.h=this._options.rowHeight*n:(this.th=Math.max(this._options.rowHeight*n,r-(this.scrollbarDimensions?.height??0)),this.th<this.maxSupportedCssHeight?(this.h=this.ph=this.th,this.n=1,this.cj=0):(this.h=this.maxSupportedCssHeight,this.ph=this.h/100,this.n=Math.floor(this.th/this.ph),this.cj=(this.th-this.h)/(this.n-1))),(this.h!==o||this.enforceFrozenRowHeightRecalc)&&(this.hasFrozenRows&&!this._options.frozenBottom?(L.height(this._canvasBottomL,this.h),this.hasFrozenColumns()&&L.height(this._canvasBottomR,this.h)):(L.height(this._canvasTopL,this.h),L.height(this._canvasTopR,this.h)),this.scrollTop=this._viewportScrollContainerY.scrollTop,this.scrollHeight=this._viewportScrollContainerY.scrollHeight,this.enforceFrozenRowHeightRecalc=!1);let l=this.scrollTop+this.offset<=this.th-r;this.th===0||this.scrollTop===0?this.page=this.offset=0:l?this.scrollTo(this.scrollTop+this.offset):this.scrollTo(this.th-r+(this.scrollbarDimensions?.height??0)),this.h!==o&&this._options.autoHeight&&this.resizeCanvas(),this._options.autosizeColsMode===_n.LegacyForceFit&&i!==this.viewportHasVScroll&&this.autosizeColumns(),this.updateCanvasWidth(!1)}getViewport(e,t){return this.getVisibleRange(e,t)}getVisibleRange(e,t){return e??(e=this.scrollTop),t??(t=this.scrollLeft),{top:this.getRowFromPosition(e),bottom:this.getRowFromPosition(e+this.viewportH)+1,leftPx:t,rightPx:t+this.viewportW}}getRenderedRange(e,t){let n=this.getVisibleRange(e,t),o=Math.round(this.viewportH/this._options.rowHeight),r=this._options.minRowBuffer;return this.vScrollDir===-1?(n.top-=o,n.bottom+=r):this.vScrollDir===1?(n.top-=r,n.bottom+=o):(n.top-=r,n.bottom+=r),n.top=Math.max(0,n.top),n.bottom=Math.min(this.getDataLengthIncludingAddNew()-1,n.bottom),n.leftPx-=this.viewportW,n.rightPx+=this.viewportW,n.leftPx=Math.max(0,n.leftPx),n.rightPx=Math.min(this.canvasWidth,n.rightPx),n}getRowCache(){return this.rowsCache}ensureCellNodesInRowsCache(e){let t=this.rowsCache[e];if(t?.cellRenderQueue.length&&t.rowNode?.length){let n=t.rowNode,o=Array.from(n[0].children);n.length>1&&(o=o.concat(Array.from(n[1].children)));let r=o.length-1;for(;t.cellRenderQueue.length;){let i=t.cellRenderQueue.pop();t.cellNodesByColumnIdx[i]=o[r--]}}}cleanUpCells(e,t){if(this.hasFrozenRows&&(this._options.frozenBottom&&t>this.actualFrozenRow||t<=this.actualFrozenRow))return;let n=this.rowsCache[t],o=[];Object.keys(n.cellNodesByColumnIdx).forEach(a=>{if(!n.cellNodesByColumnIdx.hasOwnProperty(a))return;let l=+a;if(l<=this._options.frozenColumn||Array.isArray(this.columns)&&this.columns[l]?.alwaysRenderColumn)return;let d=n.cellColSpans[l];(this.columnPosLeft[l]>e.rightPx||this.columnPosRight[Math.min(this.columns.length-1,(l||0)+d-1)]<e.leftPx)&&(t===this.activeRow&&Number(l)===this.activeCell||o.push(l))});let r,i;for(;L.isDefined(r=o.pop());)i=n.cellNodesByColumnIdx[r],this._options.enableAsyncPostRenderCleanup&&this.postProcessedRows[t]?.[r]?this.queuePostProcessedCellForCleanup(i,r,t):i.parentElement?.removeChild(i),delete n.cellColSpans[r],delete n.cellNodesByColumnIdx[r],this.postProcessedRows[t]&&delete this.postProcessedRows[t][r]}cleanUpAndRenderCells(e){let t,n=document.createElement("div"),o=[],r,i,a,l=this.columns.length;for(let f=e.top,p=e.bottom;f<=p;f++){if(t=this.rowsCache[f],!t)continue;this.ensureCellNodesInRowsCache(f),(!this._options.enableCellRowSpan||this.getRowSpanIntersect(f)===null)&&this.cleanUpCells(e,f),r=0;let y=this.getItemMetadaWhenExists(f);y=y?.columns;let b=this.getDataItem(f);for(let w=0,g=l;w<g;w++){if(!this.columns[w]||this.columns[w].hidden)continue;if(this.columnPosLeft[w]>e.rightPx)break;if(L.isDefined(i=t.cellColSpans[w])){w+=i>1?i-1:0;continue}i=1,a=null,y&&(a=y[this.columns[w].id]||y[w],i=a?.colspan??1,i==="*"&&(i=g-w));let v=i;if(!this.getParentRowSpanByCell(f,w)){if(this.columnPosRight[Math.min(g-1,w+v-1)]>e.leftPx){let E=this.getRowspan(f,w);this.appendCellHtml(n,f,w,v,E,a,b),r++}w+=v>1?v-1:0}}r&&o.push(f)}if(!n.children.length)return;let d,u;for(;L.isDefined(d=o.pop());){t=this.rowsCache[d];let f;for(;L.isDefined(f=t.cellRenderQueue.pop());)u=n.lastChild,u&&(this.hasFrozenColumns()&&f>this._options.frozenColumn?t.rowNode[1].appendChild(u):t.rowNode[0].appendChild(u),t.cellNodesByColumnIdx[f]=u)}}renderRows(e){let t=[],n=[],o=[],r=!1,i=this.getDataLength(),a=new Set,l=new Set;for(let u=e.top,f=e.bottom;u<=f;u++)if(!(this.rowsCache[u]||this.hasFrozenRows&&this._options.frozenBottom&&u===this.getDataLength())){if(this.renderedRows++,o.push(u),l.add(u),this.rowsCache[u]=this.createEmptyCachingRow(),this._options.enableCellRowSpan){let p=this.getRowSpanIntersect(u);p!==null&&l.add(p)}this.appendRowHtml(t,n,u,e,i),a.add(u),this.activeCellNode&&this.activeRow===u&&(r=!0),this.counter_rows_rendered++}let d=this.setDifference(l,a);if(d.size>0&&d.forEach(u=>{this.removeRowFromCache(u),o.push(u),this.rowsCache[u]=this.createEmptyCachingRow(),this.appendRowHtml(t,n,u,e,i)}),o.length){let u=document.createElement("div"),f=document.createElement("div");t.forEach(p=>u.appendChild(p)),n.forEach(p=>f.appendChild(p));for(let p=0,y=o.length;p<y;p++)this.hasFrozenRows&&o[p]>=this.actualFrozenRow?this.hasFrozenColumns()?this.rowsCache?.hasOwnProperty(o[p])&&u.firstChild&&f.firstChild&&(this.rowsCache[o[p]].rowNode=[u.firstChild,f.firstChild],this._canvasBottomL.appendChild(u.firstChild),this._canvasBottomR.appendChild(f.firstChild)):this.rowsCache?.hasOwnProperty(o[p])&&u.firstChild&&(this.rowsCache[o[p]].rowNode=[u.firstChild],this._canvasBottomL.appendChild(u.firstChild)):this.hasFrozenColumns()?this.rowsCache?.hasOwnProperty(o[p])&&u.firstChild&&f.firstChild&&(this.rowsCache[o[p]].rowNode=[u.firstChild,f.firstChild],this._canvasTopL.appendChild(u.firstChild),this._canvasTopR.appendChild(f.firstChild)):this.rowsCache?.hasOwnProperty(o[p])&&u.firstChild&&(this.rowsCache[o[p]].rowNode=[u.firstChild],this._canvasTopL.appendChild(u.firstChild));r&&(this.activeCellNode=this.getCellNode(this.activeRow,this.activeCell))}}updateRowPositions(){for(let e in this.rowsCache)if(this.rowsCache){let t=e?parseInt(e,10):0,n=this.rowsCache[t].rowNode[0];this._options.rowTopOffsetRenderType==="transform"?n.style.transform=`translateY(${this.getRowTop(t)}px)`:n.style.top=`${this.getRowTop(t)}px`}}render(){if(!this.initialized)return;this.scrollThrottle.dequeue();let e=this.getVisibleRange(),t=this.getRenderedRange();if(this.cleanupRows(t),this.lastRenderedScrollLeft!==this.scrollLeft){if(this.hasFrozenRows){let n=L.extend(!0,{},t);this._options.frozenBottom?(n.top=this.actualFrozenRow,n.bottom=this.getDataLength()):(n.top=0,n.bottom=this._options.frozenRow),this.cleanUpAndRenderCells(n)}this.cleanUpAndRenderCells(t)}this.renderRows(t),this.hasFrozenRows&&(this._options.frozenBottom?this.renderRows({top:this.actualFrozenRow,bottom:this.getDataLength()-1,leftPx:t.leftPx,rightPx:t.rightPx}):this.renderRows({top:0,bottom:this._options.frozenRow-1,leftPx:t.leftPx,rightPx:t.rightPx})),this.postProcessFromRow=e.top,this.postProcessToRow=Math.min(this.getDataLengthIncludingAddNew()-1,e.bottom),this.startPostProcessing(),this.lastRenderedScrollTop=this.scrollTop,this.lastRenderedScrollLeft=this.scrollLeft,this.trigger(this.onRendered,{startRow:e.top,endRow:e.bottom,grid:this})}getFrozenRowOffset(e){let t=0;return this.hasFrozenRows?this._options.frozenBottom?e>=this.actualFrozenRow?this.h<this.viewportTopH?t=this.actualFrozenRow*this._options.rowHeight:t=this.h:t=0:e>=this.actualFrozenRow?t=this.frozenRowsHeight:t=0:t=0,t}bindAncestorScrollEvents(){let e=this.hasFrozenRows&&!this._options.frozenBottom?this._canvasBottomL:this._canvasTopL;for(;(e=e.parentNode)!==document.body&&e;)(e===this._viewportTopL||e.scrollWidth!==e.clientWidth||e.scrollHeight!==e.clientHeight)&&(this._boundAncestors.push(e),this._bindingEventService.bind(e,"scroll",this.handleActiveCellPositionChange.bind(this)))}unbindAncestorScrollEvents(){this._boundAncestors.forEach(e=>{this._bindingEventService.unbindByEventName(e,"scroll")}),this._boundAncestors=[]}setScroller(){this.hasFrozenColumns()?(this._headerScrollContainer=this._headerScrollerR,this._headerRowScrollContainer=this._headerRowScrollerR,this._footerRowScrollContainer=this._footerRowScrollerR,this.hasFrozenRows?this._options.frozenBottom?(this._viewportScrollContainerX=this._viewportBottomR,this._viewportScrollContainerY=this._viewportTopR):this._viewportScrollContainerX=this._viewportScrollContainerY=this._viewportBottomR:this._viewportScrollContainerX=this._viewportScrollContainerY=this._viewportTopR):(this._headerScrollContainer=this._headerScrollerL,this._headerRowScrollContainer=this._headerRowScrollerL,this._footerRowScrollContainer=this._footerRowScrollerL,this.hasFrozenRows?this._options.frozenBottom?(this._viewportScrollContainerX=this._viewportBottomL,this._viewportScrollContainerY=this._viewportTopL):this._viewportScrollContainerX=this._viewportScrollContainerY=this._viewportBottomL:this._viewportScrollContainerX=this._viewportScrollContainerY=this._viewportTopL)}scrollTo(e){e=Math.max(e,0),e=Math.min(e,(this.th||0)-L.height(this._viewportScrollContainerY)+(this.viewportHasHScroll||this.hasFrozenColumns()?this.scrollbarDimensions?.height??0:0));let t=this.offset;this.offset=Math.round(this.page*(this.cj||0)),this.page=Math.min((this.n||0)-1,Math.floor(e/(this.ph||0)));let n=e-this.offset;if(this.offset!==t){let o=this.getVisibleRange(n);this.cleanupRows(o),this.updateRowPositions()}this.prevScrollTop!==n&&(this.vScrollDir=this.prevScrollTop+t<n+this.offset?1:-1,this.lastRenderedScrollTop=this.scrollTop=this.prevScrollTop=n,this.hasFrozenColumns()&&(this._viewportTopL.scrollTop=n),this.hasFrozenRows&&(this._viewportBottomL.scrollTop=this._viewportBottomR.scrollTop=n),this._viewportScrollContainerY&&(this._viewportScrollContainerY.scrollTop=n),this.trigger(this.onViewportChanged,{}))}handleHeaderRowScroll(){let e=this._headerRowScrollContainer.scrollLeft;e!==this._viewportScrollContainerX.scrollLeft&&(this._viewportScrollContainerX.scrollLeft=e)}handleFooterRowScroll(){let e=this._footerRowScrollContainer.scrollLeft;e!==this._viewportScrollContainerX.scrollLeft&&(this._viewportScrollContainerX.scrollLeft=e)}handlePreHeaderPanelScroll(){this.handleElementScroll(this._preHeaderPanelScroller)}handleTopHeaderPanelScroll(){this.handleElementScroll(this._topHeaderPanelScroller)}handleElementScroll(e){let t=e.scrollLeft;t!==this._viewportScrollContainerX.scrollLeft&&(this._viewportScrollContainerX.scrollLeft=t)}handleScroll(e){return this.scrollHeight=this._viewportScrollContainerY.scrollHeight,this.scrollTop=this._viewportScrollContainerY.scrollTop,this.scrollLeft=this._viewportScrollContainerX.scrollLeft,this._handleScroll(e?"scroll":"system")}_handleScroll(e="system"){let t=this._viewportScrollContainerY.scrollHeight-this._viewportScrollContainerY.clientHeight,n=this._viewportScrollContainerY.scrollWidth-this._viewportScrollContainerY.clientWidth;t=Math.max(0,t),n=Math.max(0,n),this.scrollTop>t&&(this.scrollTop=t,this.scrollHeight=t),this.scrollLeft>n&&(this.scrollLeft=n);let o=Math.abs(this.scrollTop-this.prevScrollTop),r=Math.abs(this.scrollLeft-this.prevScrollLeft);if(r&&(this.prevScrollLeft=this.scrollLeft,this._viewportScrollContainerX.scrollLeft=this.scrollLeft,this._headerScrollContainer.scrollLeft=this.scrollLeft,this._topPanelScrollers[0].scrollLeft=this.scrollLeft,this._options.createFooterRow&&(this._footerRowScrollContainer.scrollLeft=this.scrollLeft),this._options.createPreHeaderPanel&&(this.hasFrozenColumns()?this._preHeaderPanelScrollerR.scrollLeft=this.scrollLeft:this._preHeaderPanelScroller.scrollLeft=this.scrollLeft),this._options.createTopHeaderPanel&&(this._topHeaderPanelScroller.scrollLeft=this.scrollLeft),this.hasFrozenColumns()?(this.hasFrozenRows&&(this._viewportTopR.scrollLeft=this.scrollLeft),this._headerRowScrollerR.scrollLeft=this.scrollLeft):(this.hasFrozenRows&&(this._viewportTopL.scrollLeft=this.scrollLeft),this._headerRowScrollerL.scrollLeft=this.scrollLeft)),o&&!this._options.autoHeight)if(this.vScrollDir=this.prevScrollTop<this.scrollTop?1:-1,this.prevScrollTop=this.scrollTop,e==="mousewheel"&&(this._viewportScrollContainerY.scrollTop=this.scrollTop),this.hasFrozenColumns()&&(this.hasFrozenRows&&!this._options.frozenBottom?this._viewportBottomL.scrollTop=this.scrollTop:this._viewportTopL.scrollTop=this.scrollTop),o<this.viewportH)this.scrollTo(this.scrollTop+this.offset);else{let i=this.offset;this.h===this.viewportH?this.page=0:this.page=Math.min(this.n-1,Math.floor(this.scrollTop*((this.th-this.viewportH)/(this.h-this.viewportH))*(1/this.ph))),this.offset=Math.round(this.page*this.cj),i!==this.offset&&this.invalidateAllRows()}if(r||o){let i=Math.abs(this.lastRenderedScrollLeft-this.scrollLeft),a=Math.abs(this.lastRenderedScrollTop-this.scrollTop);(i>20||a>20)&&(this._options.forceSyncScrolling||a<this.viewportH&&i<this.viewportW?this.render():this.scrollThrottle.enqueue(),this.trigger(this.onViewportChanged,{}))}return this.trigger(this.onScroll,{triggeredBy:e,scrollHeight:this.scrollHeight,scrollLeft:this.scrollLeft,scrollTop:this.scrollTop}),!!(r||o)}scrollCellIntoView(e,t,n){if(this.scrollRowIntoView(e,n),t<=this._options.frozenColumn)return;let o=this.getColspan(e,t);this.internalScrollColumnIntoView(this.columnPosLeft[t],this.columnPosRight[t+(o>1?o-1:0)])}internalScrollColumnIntoView(e,t){let n=this.scrollLeft+L.width(this._viewportScrollContainerX)-(this.viewportHasVScroll?this.scrollbarDimensions?.width??0:0);e<this.scrollLeft?(this._viewportScrollContainerX.scrollLeft=e,this.handleScroll(),this.render()):t>n&&(this._viewportScrollContainerX.scrollLeft=Math.min(e,t-this._viewportScrollContainerX.clientWidth),this.handleScroll(),this.render())}scrollColumnIntoView(e){this.internalScrollColumnIntoView(this.columnPosLeft[e],this.columnPosRight[e])}updatePagingStatusFromView(e){this.pagingActive=e.pageSize!==0,this.pagingIsLastPage=e.pageNum===e.totalPages-1}getRowSpanColumnIntersects(e){return this.getRowSpanIntersection(e,"columns")}getRowSpanIntersect(e){return this.getRowSpanIntersection(e)}getRowSpanIntersection(e,t){let n=[],o=null;for(let r=0,i=this.columns.length;r<i;r++){let a=this._colsWithRowSpanCache[r];if(a)for(let l of Array.from(a)){let[d,u]=l.split(":").map(Number);if(e>=d&&e<=u)if(t==="columns")n.push(r);else{o=d;break}}}return t==="columns"?n:o}getParentRowSpanByCell(e,t,n=!0){let o=null,r=this._colsWithRowSpanCache[t]||new Set;for(let i of Array.from(r)){let[a,l]=i.split(":").map(Number);if((n?e>a:e>=a)&&e<=l){o={start:a,end:l,range:i};break}}return o}remapAllColumnsRowSpan(){let e=this.getDataLength();if(e>0){this._colsWithRowSpanCache={};for(let t=0;t<e;t++)this.remapRowSpanMetadataByRow(t);this._rowSpanIsCached=!0}}remapRowSpanMetadataByRow(e){let t=this.getItemMetadaWhenExists(e);t?.columns&&Object.keys(t.columns).forEach(n=>{let o=+n,r=t.columns[o],i=+(r?.colspan||1),a=+(r?.rowspan||1);this.remapRowSpanMetadata(e,o,i,a)})}remapRowSpanMetadata(e,t,n,o){var r,i,a;if(o>1){let l=`${e}:${e+o-1}`;if((r=this._colsWithRowSpanCache)[t]??(r[t]=new Set),this._colsWithRowSpanCache[t].add(l),n>1)for(let d=1;d<n;d++)(i=this._colsWithRowSpanCache)[a=t+d]??(i[a]=new Set),this._colsWithRowSpanCache[t+d].add(l)}}createEmptyCachingRow(){return{rowNode:null,cellColSpans:[],cellNodesByColumnIdx:[],cellRenderQueue:[]}}scrollRowIntoView(e,t){if(!this.hasFrozenRows||!this._options.frozenBottom&&e>this.actualFrozenRow-1||this._options.frozenBottom&&e<this.actualFrozenRow-1){let n=L.height(this._viewportScrollContainerY),o=this.hasFrozenRows&&!this._options.frozenBottom?e-this._options.frozenRow:e,r=o*this._options.rowHeight,i=(o+1)*this._options.rowHeight-n+(this.viewportHasHScroll?this.scrollbarDimensions?.height??0:0);(o+1)*this._options.rowHeight>this.scrollTop+n+this.offset?(this.scrollTo(t?r:i),this.render()):o*this._options.rowHeight<this.scrollTop+this.offset&&(this.scrollTo(t?i:r),this.render())}}scrollRowToTop(e){this.scrollTo(e*this._options.rowHeight),this.render()}scrollPage(e){let t=e*this.numVisibleRows,n=this.scrollTop+this._options.rowHeight-1;if(this.scrollTo((this.getRowFromPosition(n)+t)*this._options.rowHeight),this.render(),this._options.enableCellNavigation&&L.isDefined(this.activeRow)){let o=this.activeRow+t,r=this.getDataLengthIncludingAddNew();o>=r&&(o=r-1),o<0&&(o=0);let i=e===1?this.gotoDown(o-1||0,this.activeCell,this.activePosY,this.activePosX):this.gotoUp(o+1,this.activeCell,this.activePosY,this.activePosX);this.navigateToPos(i)}}navigatePageDown(){this.scrollPage(1)}navigatePageUp(){this.scrollPage(-1)}navigateTop(){this.unsetActiveCell(),this.navigateToRow(0)}navigateBottom(){let e=this.getDataLength()-1,t=this.getParentRowSpanByCell(e,this.activeCell)?.start??e;do if(this._options.enableCellRowSpan&&this.setActiveRow(t),this.navigateToRow(t)&&this.activeCell===this.activePosX||!L.isDefined(this.activeCell))break;while(--t>0)}navigateToRow(e){let t=this.getDataLength();if(!t)return!1;e<0?e=0:e>=t&&(e=t-1),this.scrollCellIntoView(e,0,!0);let n=!L.isDefined(this.activeCell)||!L.isDefined(this.activeRow);if(this._options.enableCellNavigation&&L.isDefined(this.activeRow)){let o=0,r=null,i=this.activePosX;for(;o<=this.activePosX;)this.canCellBeActive(e,o)&&(r=o,(!L.isDefined(this.activeCell)||o===this.activeCell)&&(n=!0)),o+=this.getColspan(e,o);r!==null?(this.setActiveCellInternal(this.getCellNode(e,r)),this.activePosX=i):this.resetActiveCell()}return n}getColspan(e,t){let n=this.getItemMetadaWhenExists(e);if(!n||!n.columns)return 1;t>=this.columns.length&&(t=this.columns.length-1);let o=(n.columns[this.columns[t].id]||n.columns[t])?.colspan;return o==="*"?o=this.columns.length-t:o=o||1,o}queuePostProcessedRowForCleanup(e,t,n){this.postProcessgroupId++,typeof t=="object"&&Object.keys(t).forEach(o=>{t.hasOwnProperty(o)&&this.postProcessedCleanupQueue.push({actionType:"C",groupId:this.postProcessgroupId,node:e.cellNodesByColumnIdx[+o],columnIdx:+o,rowIdx:n})}),e.rowNode||(e.rowNode=[]),this.postProcessedCleanupQueue.push({actionType:"R",groupId:this.postProcessgroupId,node:e.rowNode}),e.rowNode?.forEach(o=>o.remove())}queuePostProcessedCellForCleanup(e,t,n){this.postProcessedCleanupQueue.push({actionType:"C",groupId:this.postProcessgroupId,node:e,columnIdx:t,rowIdx:n}),e.remove()}applyFormatResultToCellNode(e,t,n){if(e==null&&(e=""),Object.prototype.toString.call(e)!=="[object Object]"){this.applyHtmlCode(t,e);return}let o=e.html||e.text;this.applyHtmlCode(t,o),e.removeClasses&&!n&&t.classList.remove(...L.classNameToList(e.removeClasses)),e.addClasses&&t.classList.add(...L.classNameToList(e.addClasses)),e.toolTip&&t.setAttribute("title",e.toolTip)}startPostProcessing(){this._options.enableAsyncPostRender&&(window.clearTimeout(this.h_postrender),this.h_postrender=window.setTimeout(this.asyncPostProcessRows.bind(this),this._options.asyncPostRenderDelay))}startPostProcessingCleanup(){this._options.enableAsyncPostRenderCleanup&&(window.clearTimeout(this.h_postrenderCleanup),this.h_postrenderCleanup=window.setTimeout(this.asyncPostProcessCleanupRows.bind(this),this._options.asyncPostRenderCleanupDelay))}invalidatePostProcessingResults(e){typeof this.postProcessedRows[e]=="object"&&Object.keys(this.postProcessedRows[e]).forEach(t=>{this.postProcessedRows[e].hasOwnProperty(t)&&(this.postProcessedRows[e][t]="C")}),this.postProcessFromRow=Math.min(this.postProcessFromRow,e),this.postProcessToRow=Math.max(this.postProcessToRow,e),this.startPostProcessing()}asyncPostProcessRows(){let e=this.getDataLength();for(;this.postProcessFromRow<=this.postProcessToRow;){let t=this.vScrollDir>=0?this.postProcessFromRow++:this.postProcessToRow--,n=this.rowsCache[t];if(!(!n||t>=e)){this.postProcessedRows[t]||(this.postProcessedRows[t]={}),this.ensureCellNodesInRowsCache(t),Object.keys(n.cellNodesByColumnIdx).forEach(o=>{if(n.cellNodesByColumnIdx.hasOwnProperty(o)){let r=+o,i=this.columns[r],a=this.postProcessedRows[t][r];if(i.asyncPostRender&&a!=="R"){let l=n.cellNodesByColumnIdx[r];l&&i.asyncPostRender(l,t,this.getDataItem(t),i,a==="C"),this.postProcessedRows[t][r]="R"}}}),this.h_postrender=window.setTimeout(this.asyncPostProcessRows.bind(this),this._options.asyncPostRenderDelay);return}}}asyncPostProcessCleanupRows(){if(this.postProcessedCleanupQueue.length>0){let e=this.postProcessedCleanupQueue[0].groupId;for(;this.postProcessedCleanupQueue.length>0&&this.postProcessedCleanupQueue[0].groupId===e;){let t=this.postProcessedCleanupQueue.shift();if(t?.actionType==="R"&&t.node.forEach(n=>{n.remove()}),t?.actionType==="C"){let n=this.columns[t.columnIdx];n.asyncPostRenderCleanup&&t.node&&n.asyncPostRenderCleanup(t.node,t.rowIdx,n)}}this.h_postrenderCleanup=window.setTimeout(this.asyncPostProcessCleanupRows.bind(this),this._options.asyncPostRenderCleanupDelay)}}updateCellCssStylesOnRenderedRows(e,t){let n,o,r;typeof this.rowsCache=="object"&&Object.keys(this.rowsCache).forEach(i=>{this.rowsCache&&(r=t?.[i],o=e?.[i],r&&Object.keys(r).forEach(a=>{(!o||r[a]!==o[a])&&(n=this.getCellNode(+i,this.getColumnIndex(a)),n&&n.classList.remove(r[a]))}),o&&Object.keys(o).forEach(a=>{(!r||r[a]!==o[a])&&(n=this.getCellNode(+i,this.getColumnIndex(a)),n&&n.classList.add(o[a]))}))})}addCellCssStyles(e,t){if(this.cellCssClasses[e])throw new Error(`SlickGrid addCellCssStyles: cell CSS hash with key "${e}" already exists.`);this.cellCssClasses[e]=t,this.updateCellCssStylesOnRenderedRows(t,null),this.trigger(this.onCellCssStylesChanged,{key:e,hash:t,grid:this})}removeCellCssStyles(e){this.cellCssClasses[e]&&(this.updateCellCssStylesOnRenderedRows(null,this.cellCssClasses[e]),delete this.cellCssClasses[e],this.trigger(this.onCellCssStylesChanged,{key:e,hash:null,grid:this}))}setCellCssStyles(e,t){let n=this.cellCssClasses[e];this.cellCssClasses[e]=t,this.updateCellCssStylesOnRenderedRows(t,n),this.trigger(this.onCellCssStylesChanged,{key:e,hash:t,grid:this})}getCellCssStyles(e){return this.cellCssClasses[e]}flashCell(e,t,n=250){let o=(r,i)=>{i<1||(window.clearTimeout(this._flashCellTimer),this._flashCellTimer=window.setTimeout(()=>{i%2===0?r.classList.add(this._options.cellFlashingCssClass||""):r.classList.remove(this._options.cellFlashingCssClass||""),o(r,i-1)},n))};if(this.rowsCache[e]){let r=this.getCellNode(e,t);r&&o(r,5)}}highlightRow(e,t){let n=this.rowsCache[e];t||(t=this._options.rowHighlightDuration),Array.isArray(n?.rowNode)&&this._options.rowHighlightCssClass&&(n.rowNode.forEach(o=>o.classList.add(...L.classNameToList(this._options.rowHighlightCssClass))),window.clearTimeout(this._highlightRowTimer),this._highlightRowTimer=window.setTimeout(()=>{n.rowNode?.forEach(o=>o.classList.remove(...L.classNameToList(this._options.rowHighlightCssClass)))},t))}_getContainerElement(e,t,n){if(!e)return;t||(t=0),n||(n=0);let o=typeof t=="number"?t:this.getColumnIndex(t),r=this.hasFrozenRows&&n>=this.actualFrozenRow+(this._options.frozenBottom?0:1),i=this.hasFrozenColumns()&&o>this._options.frozenColumn;return e[(r?2:0)+(i?1:0)]}measureScrollbar(){let e="";this._viewport.forEach(r=>e+=r.className);let t=L.createDomElement("div",{className:e,style:{position:"absolute",top:"-10000px",left:"-10000px",overflow:"auto",width:"100px",height:"100px"}},document.body),n=L.createDomElement("div",{style:{width:"200px",height:"200px",overflow:"auto"}},t),o={width:t.offsetWidth-t.clientWidth,height:t.offsetHeight-t.clientHeight};return n.remove(),t.remove(),o}getMaxSupportedCssHeight(){let e=1e6,t=navigator.userAgent.toLowerCase().match(/firefox/)?this._options.ffMaxSupportedCssHeight:this._options.maxSupportedCssHeight,n=L.createDomElement("div",{style:{display:"hidden"}},document.body);for(;;){let o=e*2;L.height(n,o);let r=L.height(n);if(o>t||r!==o)break;e=o}return n.remove(),e}getUID(){return this.uid}getHeaderColumnWidthDiff(){return this.headerColumnWidthDiff}getScrollbarDimensions(){return this.scrollbarDimensions}getDisplayedScrollbarDimensions(){return{width:this.viewportHasVScroll?this.scrollbarDimensions?.width??0:0,height:this.viewportHasHScroll?this.scrollbarDimensions?.height??0:0}}getAbsoluteColumnMinWidth(){return this.absoluteColumnMinWidth}getVBoxDelta(e){let t=["borderTopWidth","borderBottomWidth","paddingTop","paddingBottom"],n=getComputedStyle(e),o=0;return t.forEach(r=>o+=L.toFloat(n[r])),o}measureCellPaddingAndBorder(){let e=["borderLeftWidth","borderRightWidth","paddingLeft","paddingRight"],t=["borderTopWidth","borderBottomWidth","paddingTop","paddingBottom"],n=this._headers[0];this.headerColumnWidthDiff=this.headerColumnHeightDiff=0,this.cellWidthDiff=this.cellHeightDiff=0;let o=L.createDomElement("div",{className:"ui-state-default slick-state-default slick-header-column",style:{visibility:"hidden"},textContent:"-"},n),r=getComputedStyle(o);r.boxSizing!=="border-box"&&(e.forEach(a=>this.headerColumnWidthDiff+=L.toFloat(r[a])),t.forEach(a=>this.headerColumnHeightDiff+=L.toFloat(r[a]))),o.remove();let i=L.createDomElement("div",{className:"slick-row"},this._canvas[0]);o=L.createDomElement("div",{className:"slick-cell",id:"",style:{visibility:"hidden"},textContent:"-"},i),r=getComputedStyle(o),r.boxSizing!=="border-box"&&(e.forEach(a=>this.cellWidthDiff+=L.toFloat(r[a])),t.forEach(a=>this.cellHeightDiff+=L.toFloat(r[a]))),i.remove(),this.absoluteColumnMinWidth=Math.max(this.headerColumnWidthDiff,this.cellWidthDiff)}clearAllTimers(){window.clearTimeout(this._columnResizeTimer),window.clearTimeout(this._executionBlockTimer),window.clearTimeout(this._flashCellTimer),window.clearTimeout(this._highlightRowTimer),window.clearTimeout(this.h_editorLoader)}LogColWidths(){let e="Col Widths:";for(let t=0;t<this.columns.length;t++)e+=" "+(this.columns[t].hidden?"H":this.columns[t].width);console.log(e)}simpleArrayEquals(e,t){return Array.isArray(e)&&Array.isArray(t)&&t.sort().toString()!==e.sort().toString()}defaultFormatter(e,t,n){return L.isDefined(n)?(n+"").replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">"):""}cellExists(e,t){return!(e<0||e>=this.getDataLength()||t<0||t>=this.columns.length)}getCellFromNode(e){let t=/l\d+/.exec(e.className);if(!t)throw new Error(`SlickGrid getCellFromNode: cannot get cell - ${e.className}`);return parseInt(t[0].substr(1,t[0].length-1),10)}getRowFromNode(e){for(let t in this.rowsCache)if(this.rowsCache){for(let n in this.rowsCache[t].rowNode)if(this.rowsCache[t].rowNode?.[+n]===e)return t?parseInt(t,10):0}return null}clearTextSelection(){if(document.selection?.empty)try{document.selection.empty()}catch{}else if(window.getSelection){let e=window.getSelection();e?.removeAllRanges&&e.removeAllRanges()}}disableSelection(e){e.forEach(t=>{t.setAttribute("unselectable","on"),t.style.mozUserSelect="none",this._bindingEventService.bind(t,"selectstart",()=>!1)})}getPubSubService(){return this._pubSubService}getCellFromPoint(e,t){let n=this.getRowFromPosition(t),o=0,r=0;for(let i=0;i<this.columns.length&&r<=e;i++)this.columns[i]&&(r+=this.columns[i].width,o++);return o-=1,n<-1&&(n=-1),{row:n,cell:o}}getPluginByName(e){for(let t=this.plugins.length-1;t>=0;t--)if(this.plugins[t]?.pluginName===e)return this.plugins[t]}getContainerNode(){return this._container}getCellHeight(e,t){let n=this._options.rowHeight||0;if(t>1){let o=e+t-1;n=this.getRowBottom(o)-this.getRowTop(e)}else{let o=this.getRowHeight();o!==n-this.cellHeightDiff&&(n=o)}return n-=this.cellHeightDiff,Math.ceil(n)}setDifference(e,t){return new Set(Array.from(e).filter(n=>!t.has(n)))}getCellNodeBox(e,t){if(!this.cellExists(e,t))return null;let n=this.getFrozenRowOffset(e),o=this.getRowTop(e)-n,r=o+this._options.rowHeight-1,i=0;for(let l=0;l<t;l++)!this.columns[l]||this.columns[l].hidden||(i+=this.columns[l].width||0,this._options.frozenColumn===l&&(i=0));let a=i+(this.columns[t]?.width||0);return{top:o,left:i,bottom:r,right:a}}absBox(e){let t={top:e.offsetTop,left:e.offsetLeft,bottom:0,right:0,width:e.offsetWidth,height:e.offsetWidth,visible:!0};t.bottom=t.top+t.height,t.right=t.left+t.width;let n=e.offsetParent;for(;(e=e.parentNode)!==document.body&&!(!e||!e.parentNode);){let o=getComputedStyle(e);t.visible&&e.scrollHeight!==e.offsetHeight&&o.overflowY!=="visible"&&(t.visible=t.bottom>e.scrollTop&&t.top<e.scrollTop+e.clientHeight),t.visible&&e.scrollWidth!==e.offsetWidth&&o.overflowX!=="visible"&&(t.visible=t.right>e.scrollLeft&&t.left<e.scrollLeft+e.clientWidth),t.left-=e.scrollLeft,t.top-=e.scrollTop,e===n&&(t.left+=e.offsetLeft,t.top+=e.offsetTop,n=e.offsetParent),t.bottom=t.top+t.height,t.right=t.left+t.width}return t}getActiveCellPosition(){return this.absBox(this.activeCellNode)}getGridPosition(){return this.absBox(this._container)}getCellEditor(){return this.currentEditor}getActiveCell(){return this.activeCellNode?{row:this.activeRow,cell:this.activeCell}:null}getActiveCellNode(){return this.activeCellNode}getTextSelection(){let e=null;if(window.getSelection){let t=window.getSelection();(t?.rangeCount??0)>0&&(e=t.getRangeAt(0))}return e}setTextSelection(e){if(window.getSelection&&e){let t=window.getSelection();t&&(t.removeAllRanges(),t.addRange(e))}}sanitizeHtmlString(e,t){if(!this._options.sanitizer||typeof e!="string")return e;let n=this._options.sanitizer(e);return!t&&this._options.logSanitizedHtml&&this.logMessageCount<=this.logMessageMaxCount&&n!==e&&(console.log(`sanitizer altered html: ${e} --> ${n}`),this.logMessageCount===this.logMessageMaxCount&&console.log(`sanitizer: silencing messages after first ${this.logMessageMaxCount}`),this.logMessageCount++),n}getRowspan(e,t){let n=1,o=this.getItemMetadaWhenExists(e);return o?.columns&&Object.keys(o.columns).forEach(r=>{let i=Number(r);if(i===t){let a=o.columns[i];n=Number(a?.rowspan||1)}}),n}findFocusableRow(e,t,n){let o=e,r=this._colsWithRowSpanCache[t]||new Set,i=!1;return Array.from(r).forEach(a=>{let[l,d]=a.split(":").map(Number);!i&&e>=l&&e<=d&&(o=n==="up"?l:d,this.canCellBeActive(o,t)&&(i=!0))}),o<0&&(o=0),o}findFirstFocusableCell(e){let t=0,n=e,o=-1;for(;t<this.columns.length;){let r=this.getParentRowSpanByCell(e,t);if(n=r!==null&&r.start!==e?r.start:e,this.canCellBeActive(n,t)){o=t;break}t+=this.getColspan(n,t)}return{cell:o,row:n}}findLastFocusableCell(e){let t=0,n=e,o=-1;for(;t<this.columns.length;){let r=this.getParentRowSpanByCell(e,t);n=r!==null&&r.start!==e?r.start:e,this.canCellBeActive(n,t)&&(o=t),t+=this.getColspan(n,t)}return{cell:o,row:n}}rowsToRanges(e){let t=[],n=this.columns.length-1;for(let o=0;o<e.length;o++)t.push(new cA(e[o],0,e[o],n));return t}findSpanStartingCell(e,t){let n=this.getParentRowSpanByCell(e,t),o=n!==null&&n.start!==e?n.start:e,r=0,i=0;for(;r<this.columns.length;){if(r+=this.getColspan(o,r),r>t)return r=i,{cell:r,row:o};i=r}return{cell:r,row:o}}gotoRight(e,t,n,o){if(t>=this.columns.length)return null;let r=t+1,i=n;do{let a=this.findSpanStartingCell(n,r);if(i=a.row,r=a.cell,this.canCellBeActive(i,r)&&r>t)break;r+=this.getColspan(i,a.cell)}while(r<this.columns.length);return r<this.columns.length?{row:i,cell:r,posX:r,posY:n}:null}gotoLeft(e,t,n,o){if(t<=0)return null;let r=this.findFirstFocusableCell(e);if(r.cell===null||r.cell>=t)return null;let i,a={row:e,cell:r.cell,posX:r.cell,posY:n};for(;;){if(i=this.gotoRight(a.row,a.cell,a.posY,a.posX),!i)return null;if(i.cell>=t){let l=this.findFocusableRow(n,a.cell,"up");return l!==a.row&&(a.row=l),a}a=i}}gotoDown(e,t,n,o){let r,i=this.getDataLengthIncludingAddNew();do for(e+=this.getRowspan(e,o),r=t=0;t<=o;)r=t,t+=this.getColspan(e,t);while(e<=i&&!this.canCellBeActive(e,r));return e<=i?{row:e,cell:r,posX:o,posY:e}:null}gotoUp(e,t,n,o){let r;if(e<=0)return null;do for(e=this.findFocusableRow(e-1,o,"up"),r=t=0;t<=o;)r=t,t+=this.getColspan(e,t);while(e>=0&&!this.canCellBeActive(e,r));return t<=this.columns.length?{row:e,cell:r,posX:o,posY:e}:null}gotoNext(e,t,n,o){if(!L.isDefined(e)&&!L.isDefined(t)&&(e=t=n=o=0,this.canCellBeActive(e,t)))return{row:e,cell:t,posX:t,posY:n};let r=this.gotoRight(e,t,n,o);if(!r){let i;for(;!r&&++n<this.getDataLength()+(this._options.enableAddRow?1:0);)i=this.findFirstFocusableCell(n),i.cell!==null&&(e=this.getParentRowSpanByCell(n,i.cell)?.start??n,r={row:e,cell:i.cell,posX:i.cell,posY:n})}return r}gotoPrev(e,t,n,o){if(!L.isDefined(e)&&!L.isDefined(t)&&(e=n=this.getDataLengthIncludingAddNew()-1,t=o=this.columns.length-1,this.canCellBeActive(e,t)))return{row:e,cell:t,posX:t,posY:n};let r=this.gotoLeft(e,t,n,o);if(!r){let i;for(;!r&&--n>=0;)i=this.findLastFocusableCell(n),i.cell>-1&&(e=this.getParentRowSpanByCell(n,i.cell)?.start??n,r={row:e,cell:i.cell,posX:i.cell,posY:n})}return r}gotoRowStart(e,t,n,o){let r=this.findFirstFocusableCell(e);return r.cell===null?null:{row:r.row,cell:r.cell,posX:r.cell,posY:e}}gotoRowEnd(e,t,n,o){let r=this.findLastFocusableCell(e);return r.cell===-1?null:{row:r.row,cell:r.cell,posX:r.cell,posY:e}}navigateRight(){return this.navigate("right")}navigateLeft(){return this.navigate("left")}navigateDown(){return this.navigate("down")}navigateUp(){return this.navigate("up")}navigateNext(){return this.navigate("next")}navigatePrev(){return this.navigate("prev")}navigateRowStart(){return this.navigate("home")}navigateRowEnd(){return this.navigate("end")}navigateTopStart(){return this.navigateToRow(0),this.navigate("home")}navigateBottomEnd(){return this.navigateBottom(),this.navigate("end")}navigate(e){if(!this._options.enableCellNavigation||!this.activeCellNode&&e!=="prev"&&e!=="next")return!1;if(!this.getEditorLock()?.commitCurrentEdit())return!0;this.setFocus(),this.unsetActiveCell();let t={up:-1,down:1,left:-1,right:1,prev:-1,next:1,home:-1,end:1};this.tabbingDirection=t[e];let n={up:this.gotoUp,down:this.gotoDown,left:this.gotoLeft,right:this.gotoRight,prev:this.gotoPrev,next:this.gotoNext,home:this.gotoRowStart,end:this.gotoRowEnd}[e].call(this,this.activeRow,this.activeCell,this.activePosY,this.activePosX);return this.navigateToPos(n)}navigateToPos(e){if(e){if(this.hasFrozenRows&&this._options.frozenBottom&&e.row===this.getDataLength())return;let t=e.row===this.getDataLength();return(!this._options.frozenBottom&&e.row>=this.actualFrozenRow||this._options.frozenBottom&&e.row<this.actualFrozenRow)&&this.scrollCellIntoView(e.row,e.cell,!t&&this._options.emulatePagingWhenScrolling),this.setActiveCellInternal(this.getCellNode(e.row,e.cell)),this.activePosX=e.posX,this.activePosY=e.posY,!0}else return this.setActiveCellInternal(this.getCellNode(this.activeRow,this.activeCell)),!1}getCellNode(e,t){if(this.rowsCache[e]){this.ensureCellNodesInRowsCache(e);try{return this.rowsCache[e].cellNodesByColumnIdx.length>t?this.rowsCache[e].cellNodesByColumnIdx[t]:null}catch{return this.rowsCache[e].cellNodesByColumnIdx[t]}}return null}setActiveCell(e,t,n,o,r){this.initialized&&(e>this.getDataLength()||e<0||t>=this.columns.length||t<0||this._options.enableCellNavigation&&(this.scrollCellIntoView(e,t,!1),this.setActiveCellInternal(this.getCellNode(e,t),n,o,r)))}setActiveRow(e,t,n){this.initialized&&(e>this.getDataLength()||e<0||(t??0)>=this.columns.length||(t??0)<0||(this.activeRow=e,n||this.scrollCellIntoView(e,t||0,!1)))}canCellBeActive(e,t){if(!this._options.enableCellNavigation||e>=this.getDataLengthIncludingAddNew()||e<0||t>=this.columns.length||t<0||!this.columns[t]||this.columns[t].hidden||(this.getParentRowSpanByCell(e,t)?.start??e)!==e)return!1;let n=this.getItemMetadaWhenExists(e);if(n?.focusable!==void 0)return!!n.focusable;let o=n?.columns;return o?.[this.columns[t].id]?.focusable!==void 0?!!o[this.columns[t].id].focusable:o?.[t]?.focusable!==void 0?!!o[t].focusable:!!this.columns[t].focusable}canCellBeSelected(e,t){if(e>=this.getDataLength()||e<0||t>=this.columns.length||t<0||!this.columns[t]||this.columns[t].hidden)return!1;let n=this.getItemMetadaWhenExists(e);if(n?.selectable!==void 0)return!!n.selectable;let o=n?.columns&&(n.columns[this.columns[t].id]||n.columns[t]);return o?.selectable!==void 0?!!o.selectable:!!this.columns[t].selectable}gotoCell(e,t,n,o){if(!this.initialized||!this.canCellBeActive(e,t)||!this.getEditorLock()?.commitCurrentEdit())return;this.scrollCellIntoView(e,t,!1);let r=this.getCellNode(e,t),i=this.columns[t],a=!!(this._options.editable&&i?.editor&&this._options.suppressActiveCellChangeOnEdit);this.setActiveCellInternal(r,n||e===this.getDataLength()||this._options.autoEdit,null,a,o),this.currentEditor||this.setFocus()}};/**
|
|
275
275
|
* @license
|
|
276
276
|
* (c) 2009-present Michael Leibman
|
|
277
277
|
* michael{dot}leibman{at}gmail{dot}com
|
|
@@ -287,15 +287,15 @@ _e.version="2.30.1";dD(Ot);_e.fn=ye;_e.min=QO;_e.max=JO;_e.now=eM;_e.utc=Oo;_e.u
|
|
|
287
287
|
* This increases the speed dramatically, but can only be done safely because there are no event handlers
|
|
288
288
|
* or data associated with any cell/row DOM nodes. Cell editors must make sure they implement .destroy()
|
|
289
289
|
* and do proper cleanup.
|
|
290
|
-
*/const
|
|
290
|
+
*/const uA={asyncEditorLoading:!1,autosizeColsMode:Sv.LegacyForceFit,enableAutoSizeColumns:!0,enableColumnReorder:!1};function hA({SlickDataView:e=sA,applyCellCssStyles:t,assignIds:n=!1,columnSorter:o=oF,columns:r,getItemMetadata:i,groups:a,idPropertyName:l="id",items:d,onAddNewRow:u,onBeforeEditCell:f,onCellChange:p,onClick:y,onDblClick:b,onHeaderMenuCommand:w,onRowCountChanged:g=oD,onSelectedRowsChanged:v,options:E={},table:P}){$e.useEffect(()=>{const x=new xv,S=new YN({}),C=new GN({}),O=new e({groupItemMetadataProvider:a?x:void 0}),N=P.createGrid(O,[],E);N.setSelectionModel(new tA({selectActiveRow:!1})),N.registerPlugin(S),N.registerPlugin(x),i&&(O.getItemMetadata=i(O)),O.setItems(n?d.map((z,R)=>({...z,[l]:++R})):d.map(z=>({...z})),l),N.invalidate(),O.onRowCountChanged.subscribe(g(P)),O.onRowsChanged.subscribe(nD(N)),N.onAddNewRow.subscribe(u),N.onCellChange.subscribe(p),v&&N.onSelectedRowsChanged.subscribe(v),f&&N.onBeforeEditCell.subscribe(f),y&&N.onClick.subscribe(y),b&&N.onDblClick.subscribe(b),N.onSort.subscribe(o.getSortFunction(P.id)),N.onContextMenu.subscribe(Dv(P)),P.columnPicker&&N.onHeaderContextMenu.subscribe(FA(P));const F=vv(P);return S.onCommand.subscribe(F),w&&(C.onCommand.subscribe(w),N.registerPlugin(C)),a&&(P.grouping={groups:a,isGrouped:P.grouping.isGrouped??!0}),t?.(N),P.hotKeysBehavior.pushToCommandQueue(N),()=>{S.onCommand.unsubscribe(F),w&&C.onCommand.unsubscribe(w),N.onAddNewRow.unsubscribe(u),N.onCellChange.unsubscribe(p),v&&N.onSelectedRowsChanged.subscribe(v),f&&N.onBeforeEditCell.unsubscribe(f),y&&N.onClick.unsubscribe(y),b&&N.onDblClick.unsubscribe(b),P.reset()}},[d]),$e.useEffect(()=>{const x=P.grid;!x||!E||(x.setOptions({...uA,...E}),x.render())},[E,d]),$e.useEffect(()=>{const x=P.grid;if(x&&r.length){if(r[0].id===Yd){const S=new BN;x.setColumns([{...S.getColumnDefinition(),focusable:!1},...r.slice(1)]),x.registerPlugin(S)}else x.setColumns(r);er.highlightAllColumns(P.filter.args,P.id),P.filter.register(x,P.id),x.invalidate(),P.totalCalculator?.calculate(x),P.notifyObservers(),o.restoreSorting(P)}},[r,d]),$e.useEffect(()=>{if(!P.columnPicker)return;const x=P.grid;x&&(P.columnPicker.initialColumns=x.getColumns(),P.columnPicker.visibleColumnIds=x.getColumns().map(({id:S})=>S))},[r])}const fA=e=>(t,{grid:n,item:o})=>{pA(n,o),n.updateRowCount(),n.invalidate(),e.isEdited=!0,e.hotKeysBehavior.pushToCommandQueue(n)},pA=(e,t)=>{const n=e.getData(),o=n.getIdPropertyName(),i={...OA(n),...t,[o]:kl(e),isEdited:!0,isNew:!0};n.addItem(i)},mA=({SlickDataView:e,applyCellCssStyles:t,assignIds:n,columnSorter:o,columns:r,getItemMetadata:i,groups:a,idPropertyName:l,items:d,onAddNewRow:u,onBeforeEditCell:f,onCellChange:p,onClick:y,onDblClick:b,onHeaderMenuCommand:w,onRowCountChanged:g,onSelectedRowsChanged:v,options:E,table:P})=>(hA({SlickDataView:e,applyCellCssStyles:t,assignIds:n,columnSorter:o,columns:r,getItemMetadata:i,groups:a,idPropertyName:l,items:d,onAddNewRow:u||fA(P),onBeforeEditCell:f,onCellChange:p||tD(P),onClick:y,onDblClick:b,onHeaderMenuCommand:w,onRowCountChanged:g,onSelectedRowsChanged:v,options:E,table:P}),$A(P),WA(P),BA(P),D.jsx("div",{id:P.id,className:"slick-container"})),cm=As`
|
|
291
291
|
50% {
|
|
292
292
|
background-color: #ffb1b1;
|
|
293
293
|
}
|
|
294
|
-
`;ae(Do)(({theme:e})=>({"& .slick-container":{userSelect:"none",maxWidth:"100%",height:"100%",maxHeight:"100%",color:e.palette.text.primary,borderColor:e.palette.background.paper,fontFamily:"inherit",fontSize:"0.75rem","& .slick-header-column":{"&.filter-active .slick-header-button::after":{width:"7px",height:"7px",content:"''",backgroundColor:"#2196f3",position:"absolute",borderRadius:"50%",border:"2px solid #f8f8f8",top:"3px",right:"3px"},"&:not([data-id=_checkbox_selector]):not([data-id=isEdited])":{"& .slick-column-name":{textOverflow:"ellipsis",whiteSpace:"nowrap",overflow:"hidden",maxWidth:"calc(100% - 16px)"}},"&.slick-state-hover":{"&.filter-active .slick-header-button::after":{border:"2px solid #e8e8e8"},"& .slick-header-button":{"&::before":{backgroundColor:"#e8e8e8"}}},"& .slick-header-button":{width:"19px",height:"12px","&::before":{position:"absolute",content:"''",width:"19px",height:"12px",top:"6px",right:"5px",backgroundImage:"repeating-linear-gradient(0deg, #808080, #808080 2px, transparent 2px, transparent 4px)",clipPath:"polygon(0% 0%, 100% 0%, 50% 110%)",backgroundColor:"#f8f8f8"}}},"& .slick-viewport":{backgroundColor:e.palette.background.paper,"& .grid-canvas":{"& .ui-widget-content.slick-row":{"&.even":{backgroundColor:e.palette.background.default},"& .slick-cell":{"&.active":{borderColor:"#007bff","& input":{color:e.palette.text.primary}},"&.selected":{color:e.palette.text.primary},"&.text-right":{textAlign:"right"},"&.bold":{fontWeight:"bold"},"&.wink":{animation:`${cm} infinite 0.5s linear`,"& input":{animation:`${cm} infinite 0.5s linear`}},"& input.editor-text":{textAlign:"inherit"},"& select":{color:e.palette.text.primary,backgroundColor:e.palette.background.default},"& #autocomplete":{margin:0,padding:0,maxHeight:"300px",width:"100%",overflow:"auto",backgroundColor:e.palette.background.default,fontSize:"12px",boxShadow:"0 0 5px 1px gray","& div":{"&:hover":{cursor:"pointer"},"&.active":{},"& strong":{color:"#007bff"}}}}}}},"& .slick-footerrow":{backgroundColor:e.palette.background.default,borderTop:"1px solid silver","& .slick-footerrow-column":{height:"100%",display:"flex",justifyContent:"flex-end",alignItems:"center",paddingRight:"5px",borderBottom:"none",fontWeight:"bold","&:last-child":{borderRight:"none"}}}}}));const
|
|
294
|
+
`;ae(Do)(({theme:e})=>({"& .slick-container":{userSelect:"none",maxWidth:"100%",height:"100%",maxHeight:"100%",color:e.palette.text.primary,borderColor:e.palette.background.paper,fontFamily:"inherit",fontSize:"0.75rem","& .slick-header-column":{"&.filter-active .slick-header-button::after":{width:"7px",height:"7px",content:"''",backgroundColor:"#2196f3",position:"absolute",borderRadius:"50%",border:"2px solid #f8f8f8",top:"3px",right:"3px"},"&:not([data-id=_checkbox_selector]):not([data-id=isEdited])":{"& .slick-column-name":{textOverflow:"ellipsis",whiteSpace:"nowrap",overflow:"hidden",maxWidth:"calc(100% - 16px)"}},"&.slick-state-hover":{"&.filter-active .slick-header-button::after":{border:"2px solid #e8e8e8"},"& .slick-header-button":{"&::before":{backgroundColor:"#e8e8e8"}}},"& .slick-header-button":{width:"19px",height:"12px","&::before":{position:"absolute",content:"''",width:"19px",height:"12px",top:"6px",right:"5px",backgroundImage:"repeating-linear-gradient(0deg, #808080, #808080 2px, transparent 2px, transparent 4px)",clipPath:"polygon(0% 0%, 100% 0%, 50% 110%)",backgroundColor:"#f8f8f8"}}},"& .slick-viewport":{backgroundColor:e.palette.background.paper,"& .grid-canvas":{"& .ui-widget-content.slick-row":{"&.even":{backgroundColor:e.palette.background.default},"& .slick-cell":{"&.active":{borderColor:"#007bff","& input":{color:e.palette.text.primary}},"&.selected":{color:e.palette.text.primary},"&.text-right":{textAlign:"right"},"&.bold":{fontWeight:"bold"},"&.wink":{animation:`${cm} infinite 0.5s linear`,"& input":{animation:`${cm} infinite 0.5s linear`}},"& input.editor-text":{textAlign:"inherit"},"& select":{color:e.palette.text.primary,backgroundColor:e.palette.background.default},"& #autocomplete":{margin:0,padding:0,maxHeight:"300px",width:"100%",overflow:"auto",backgroundColor:e.palette.background.default,fontSize:"12px",boxShadow:"0 0 5px 1px gray","& div":{"&:hover":{cursor:"pointer"},"&.active":{},"& strong":{color:"#007bff"}}}}}}},"& .slick-footerrow":{backgroundColor:e.palette.background.default,borderTop:"1px solid silver","& .slick-footerrow-column":{height:"100%",display:"flex",justifyContent:"flex-end",alignItems:"center",paddingRight:"5px",borderBottom:"none",fontWeight:"bold","&:last-child":{borderRight:"none"}}}}}));const gA={id:Yd,field:Yd};function yA(e,t,n){return n?"<span>✎</span>":""}const vA={id:"isEdited",name:"✎",field:"isEdited",formatter:yA,focusable:!1,sortable:!0,sortAs:yo.NUMBER,cssClass:"text-center",maxWidth:30};class bA{passed(t,n,o){if(!n[1]&&!n[2])return!0;switch(o){case je.Boolean:return this.boolean(t,n);case je.DateBetween:return this.dateBetween(t,n);case je.DateEqual:return this.dateEqual(t,n[1]);case je.DateFrom:return this.dateFrom(t,n[1]);case je.DateTo:return this.dateTo(t,n[1]);case je.MultipleSelect:return this.multipleSelect(t,n[1]);case je.NumberBetween:return this.numberBetween(t,n);case je.NumberEqual:return this.numberEqual(t,n[1]);case je.NumberFrom:return this.numberFrom(t,n[1]);case je.NumberTo:return this.numberTo(t,n[1]);case je.TextContain:return this.textContain(t,n[1]);case je.TextEqual:return this.textEqual(t,n[1]);case je.TextNotContain:return!this.textContain(t,n[1]);case je.TextNotEqual:return!this.textEqual(t,n[1])}}boolean(t,n){return n[1]?!!t:n[2]?!t:!0}dateBetween(t,n){const o=n[1],r=n[2];return o?r?this.dateFrom(t,o)&&this.dateTo(t,r):this.dateFrom(t,o):this.dateTo(t,r)}dateEqual(t,n){return n===t}dateFrom(t,n){return ms(t)>=ms(n)}dateTo(t,n){return ms(t)<=ms(n)}multipleSelect(t,n){const o=JSON.parse(n);return o.includes("All")?!0:o.includes(t)}numberBetween(t,n){const o=n[1]||0,r=n[2]||0;return o?r?this.numberFrom(t,o)&&this.numberTo(t,r):Number(t)>=Number(o):Number(t)<=Number(r)}numberEqual(t,n){return Number(n)===Number(t)}numberFrom(t,n){return Number(t)>=Number(n)}numberTo(t,n){return Number(t)<=Number(n)}textEqual(t,n){return(t||"").toLowerCase()===n.toLowerCase()}textContain(t,n){return(t||"").toLowerCase().match(n.toLowerCase())}}const wA=new bA,CA=[sn.Date,sn.Boolean,sn.Number];class SA extends yv{filterFn(t,n){if(!n.columnFilters)return!0;const o=this.grid;if(!o)return!0;const r=o.getColumns(),i=Object.keys(n.columnFilters);for(let a=0;a<i.length;a++){const l=i[a],d=r[o.getColumnIndex(l)];if(!d)continue;const{filterId:u,group:f,value:p}=n.columnFilters[l];let y=t[d?.field];if(!CA.includes(f)){const b=d?.formatter;b&&(y=b(0,0,y,d,t,o))}if(!wA.passed(y,p,u))return!1}return!0}reset(){this.filter.reset(),this.tableId&&er.highlightAllColumns(this.args,this.tableId)}}function _A(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var al={exports:{}},xA=al.exports,dm;function RA(){return dm||(dm=1,function(e,t){(function(n,o){e.exports=o()})(xA,function(){var n;function o(){return n.apply(null,arguments)}function r(c){n=c}function i(c){return c instanceof Array||Object.prototype.toString.call(c)==="[object Array]"}function a(c){return c!=null&&Object.prototype.toString.call(c)==="[object Object]"}function l(c,h){return Object.prototype.hasOwnProperty.call(c,h)}function d(c){if(Object.getOwnPropertyNames)return Object.getOwnPropertyNames(c).length===0;var h;for(h in c)if(l(c,h))return!1;return!0}function u(c){return c===void 0}function f(c){return typeof c=="number"||Object.prototype.toString.call(c)==="[object Number]"}function p(c){return c instanceof Date||Object.prototype.toString.call(c)==="[object Date]"}function y(c,h){var m=[],_,I=c.length;for(_=0;_<I;++_)m.push(h(c[_],_));return m}function b(c,h){for(var m in h)l(h,m)&&(c[m]=h[m]);return l(h,"toString")&&(c.toString=h.toString),l(h,"valueOf")&&(c.valueOf=h.valueOf),c}function w(c,h,m,_){return Hh(c,h,m,_,!0).utc()}function g(){return{empty:!1,unusedTokens:[],unusedInput:[],overflow:-2,charsLeftOver:0,nullInput:!1,invalidEra:null,invalidMonth:null,invalidFormat:!1,userInvalidated:!1,iso:!1,parsedDateParts:[],era:null,meridiem:null,rfc2822:!1,weekdayMismatch:!1}}function v(c){return c._pf==null&&(c._pf=g()),c._pf}var E;Array.prototype.some?E=Array.prototype.some:E=function(c){var h=Object(this),m=h.length>>>0,_;for(_=0;_<m;_++)if(_ in h&&c.call(this,h[_],_,h))return!0;return!1};function P(c){var h=null,m=!1,_=c._d&&!isNaN(c._d.getTime());if(_&&(h=v(c),m=E.call(h.parsedDateParts,function(I){return I!=null}),_=h.overflow<0&&!h.empty&&!h.invalidEra&&!h.invalidMonth&&!h.invalidWeekday&&!h.weekdayMismatch&&!h.nullInput&&!h.invalidFormat&&!h.userInvalidated&&(!h.meridiem||h.meridiem&&m),c._strict&&(_=_&&h.charsLeftOver===0&&h.unusedTokens.length===0&&h.bigHour===void 0)),Object.isFrozen==null||!Object.isFrozen(c))c._isValid=_;else return _;return c._isValid}function x(c){var h=w(NaN);return c!=null?b(v(h),c):v(h).userInvalidated=!0,h}var S=o.momentProperties=[],C=!1;function O(c,h){var m,_,I,G=S.length;if(u(h._isAMomentObject)||(c._isAMomentObject=h._isAMomentObject),u(h._i)||(c._i=h._i),u(h._f)||(c._f=h._f),u(h._l)||(c._l=h._l),u(h._strict)||(c._strict=h._strict),u(h._tzm)||(c._tzm=h._tzm),u(h._isUTC)||(c._isUTC=h._isUTC),u(h._offset)||(c._offset=h._offset),u(h._pf)||(c._pf=v(h)),u(h._locale)||(c._locale=h._locale),G>0)for(m=0;m<G;m++)_=S[m],I=h[_],u(I)||(c[_]=I);return c}function N(c){O(this,c),this._d=new Date(c._d!=null?c._d.getTime():NaN),this.isValid()||(this._d=new Date(NaN)),C===!1&&(C=!0,o.updateOffset(this),C=!1)}function F(c){return c instanceof N||c!=null&&c._isAMomentObject!=null}function z(c){o.suppressDeprecationWarnings===!1&&typeof console<"u"&&console.warn&&console.warn("Deprecation warning: "+c)}function R(c,h){var m=!0;return b(function(){if(o.deprecationHandler!=null&&o.deprecationHandler(null,c),m){var _=[],I,G,de,Te=arguments.length;for(G=0;G<Te;G++){if(I="",typeof arguments[G]=="object"){I+=`
|
|
295
295
|
[`+G+"] ";for(de in arguments[0])l(arguments[0],de)&&(I+=de+": "+arguments[0][de]+", ");I=I.slice(0,-2)}else I=arguments[G];_.push(I)}z(c+`
|
|
296
296
|
Arguments: `+Array.prototype.slice.call(_).join("")+`
|
|
297
|
-
`+new Error().stack),m=!1}return h.apply(this,arguments)},h)}var $={};function K(c,h){o.deprecationHandler!=null&&o.deprecationHandler(c,h),$[c]||(z(h),$[c]=!0)}o.suppressDeprecationWarnings=!1,o.deprecationHandler=null;function X(c){return typeof Function<"u"&&c instanceof Function||Object.prototype.toString.call(c)==="[object Function]"}function q(c){var h,m;for(m in c)l(c,m)&&(h=c[m],X(h)?this[m]=h:this["_"+m]=h);this._config=c,this._dayOfMonthOrdinalParseLenient=new RegExp((this._dayOfMonthOrdinalParse.source||this._ordinalParse.source)+"|"+/\d{1,2}/.source)}function Y(c,h){var m=b({},c),_;for(_ in h)l(h,_)&&(a(c[_])&&a(h[_])?(m[_]={},b(m[_],c[_]),b(m[_],h[_])):h[_]!=null?m[_]=h[_]:delete m[_]);for(_ in c)l(c,_)&&!l(h,_)&&a(c[_])&&(m[_]=b({},m[_]));return m}function H(c){c!=null&&this.set(c)}var le;Object.keys?le=Object.keys:le=function(c){var h,m=[];for(h in c)l(c,h)&&m.push(h);return m};var A={sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"};function M(c,h,m){var _=this._calendar[c]||this._calendar.sameElse;return X(_)?_.call(h,m):_}function V(c,h,m){var _=""+Math.abs(c),I=h-_.length,G=c>=0;return(G?m?"+":"":"-")+Math.pow(10,Math.max(0,I)).toString().substr(1)+_}var B=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,ne=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,oe={},se={};function j(c,h,m,_){var I=_;typeof _=="string"&&(I=function(){return this[_]()}),c&&(se[c]=I),h&&(se[h[0]]=function(){return V(I.apply(this,arguments),h[1],h[2])}),m&&(se[m]=function(){return this.localeData().ordinal(I.apply(this,arguments),c)})}function J(c){return c.match(/\[[\s\S]/)?c.replace(/^\[|\]$/g,""):c.replace(/\\/g,"")}function ee(c){var h=c.match(B),m,_;for(m=0,_=h.length;m<_;m++)se[h[m]]?h[m]=se[h[m]]:h[m]=J(h[m]);return function(I){var G="",de;for(de=0;de<_;de++)G+=X(h[de])?h[de].call(I,c):h[de];return G}}function te(c,h){return c.isValid()?(h=ce(h,c.localeData()),oe[h]=oe[h]||ee(h),oe[h](c)):c.localeData().invalidDate()}function ce(c,h){var m=5;function _(I){return h.longDateFormat(I)||I}for(ne.lastIndex=0;m>=0&&ne.test(c);)c=c.replace(ne,_),ne.lastIndex=0,m-=1;return c}var ie={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"};function he(c){var h=this._longDateFormat[c],m=this._longDateFormat[c.toUpperCase()];return h||!m?h:(this._longDateFormat[c]=m.match(B).map(function(_){return _==="MMMM"||_==="MM"||_==="DD"||_==="dddd"?_.slice(1):_}).join(""),this._longDateFormat[c])}var W="Invalid date";function re(){return this._invalidDate}var Q="%d",fe=/\d{1,2}/;function me(c){return this._ordinal.replace("%d",c)}var Ce={future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",w:"a week",ww:"%d weeks",M:"a month",MM:"%d months",y:"a year",yy:"%d years"};function ve(c,h,m,_){var I=this._relativeTime[m];return X(I)?I(c,h,m,_):I.replace(/%d/i,c)}function xe(c,h){var m=this._relativeTime[c>0?"future":"past"];return X(m)?m(h):m.replace(/%s/i,h)}var Ve={D:"date",dates:"date",date:"date",d:"day",days:"day",day:"day",e:"weekday",weekdays:"weekday",weekday:"weekday",E:"isoWeekday",isoweekdays:"isoWeekday",isoweekday:"isoWeekday",DDD:"dayOfYear",dayofyears:"dayOfYear",dayofyear:"dayOfYear",h:"hour",hours:"hour",hour:"hour",ms:"millisecond",milliseconds:"millisecond",millisecond:"millisecond",m:"minute",minutes:"minute",minute:"minute",M:"month",months:"month",month:"month",Q:"quarter",quarters:"quarter",quarter:"quarter",s:"second",seconds:"second",second:"second",gg:"weekYear",weekyears:"weekYear",weekyear:"weekYear",GG:"isoWeekYear",isoweekyears:"isoWeekYear",isoweekyear:"isoWeekYear",w:"week",weeks:"week",week:"week",W:"isoWeek",isoweeks:"isoWeek",isoweek:"isoWeek",y:"year",years:"year",year:"year"};function Ae(c){return typeof c=="string"?Ve[c]||Ve[c.toLowerCase()]:void 0}function st(c){var h={},m,_;for(_ in c)l(c,_)&&(m=Ae(_),m&&(h[m]=c[_]));return h}var Pe={date:9,day:11,weekday:11,isoWeekday:11,dayOfYear:4,hour:13,millisecond:16,minute:14,month:8,quarter:7,second:15,weekYear:1,isoWeekYear:1,week:5,isoWeek:5,year:1};function ft(c){var h=[],m;for(m in c)l(c,m)&&h.push({unit:m,priority:Pe[m]});return h.sort(function(_,I){return _.priority-I.priority}),h}var Kt=/\d/,it=/\d\d/,Yt=/\d{3}/,Xt=/\d{4}/,on=/[+-]?\d{6}/,Ue=/\d\d?/,tt=/\d\d\d\d?/,Mn=/\d\d\d\d\d\d?/,hn=/\d{1,3}/,Ie=/\d{1,4}/,He=/[+-]?\d{1,6}/,vt=/\d+/,ln=/[+-]?\d+/,ho=/Z|[+-]\d\d:?\d\d/gi,pt=/Z|[+-]\d\d(?::?\d\d)?/gi,Qt=/[+-]?\d+(\.\d{1,3})?/,vn=/[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i,Jt=/^[1-9]\d?/,Ur=/^([1-9]\d|\d)/,qr;qr={};function Re(c,h,m){qr[c]=X(h)?h:function(_,I){return _&&m?m:h}}function xc(c,h){return l(qr,c)?qr[c](h._strict,h._locale):new RegExp(ba(c))}function ba(c){return Vn(c.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(h,m,_,I,G){return m||_||I||G}))}function Vn(c){return c.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function Sn(c){return c<0?Math.ceil(c)||0:Math.floor(c)}function qe(c){var h=+c,m=0;return h!==0&&isFinite(h)&&(m=Sn(h)),m}var Gr={};function mt(c,h){var m,_=h,I;for(typeof c=="string"&&(c=[c]),f(h)&&(_=function(G,de){de[h]=qe(G)}),I=c.length,m=0;m<I;m++)Gr[c[m]]=_}function wr(c,h){mt(c,function(m,_,I,G){I._w=I._w||{},h(m,I._w,I,G)})}function Rc(c,h,m){h!=null&&l(Gr,c)&&Gr[c](h,m._a,m,c)}function Kr(c){return c%4===0&&c%100!==0||c%400===0}var rn=0,U=1,pe=2,we=3,Ne=4,Ye=5,Je=6,Ze=7,Ge=8;j("Y",0,0,function(){var c=this.year();return c<=9999?V(c,4):"+"+c}),j(0,["YY",2],0,function(){return this.year()%100}),j(0,["YYYY",4],0,"year"),j(0,["YYYYY",5],0,"year"),j(0,["YYYYYY",6,!0],0,"year"),Re("Y",ln),Re("YY",Ue,it),Re("YYYY",Ie,Xt),Re("YYYYY",He,on),Re("YYYYYY",He,on),mt(["YYYYY","YYYYYY"],rn),mt("YYYY",function(c,h){h[rn]=c.length===2?o.parseTwoDigitYear(c):qe(c)}),mt("YY",function(c,h){h[rn]=o.parseTwoDigitYear(c)}),mt("Y",function(c,h){h[rn]=parseInt(c,10)});function Ut(c){return Kr(c)?366:365}o.parseTwoDigitYear=function(c){return qe(c)+(qe(c)>68?1900:2e3)};var At=en("FullYear",!0);function Wt(){return Kr(this.year())}function en(c,h){return function(m){return m!=null?(fo(this,c,m),o.updateOffset(this,h),this):jn(this,c)}}function jn(c,h){if(!c.isValid())return NaN;var m=c._d,_=c._isUTC;switch(h){case"Milliseconds":return _?m.getUTCMilliseconds():m.getMilliseconds();case"Seconds":return _?m.getUTCSeconds():m.getSeconds();case"Minutes":return _?m.getUTCMinutes():m.getMinutes();case"Hours":return _?m.getUTCHours():m.getHours();case"Date":return _?m.getUTCDate():m.getDate();case"Day":return _?m.getUTCDay():m.getDay();case"Month":return _?m.getUTCMonth():m.getMonth();case"FullYear":return _?m.getUTCFullYear():m.getFullYear();default:return NaN}}function fo(c,h,m){var _,I,G,de,Te;if(!(!c.isValid()||isNaN(m))){switch(_=c._d,I=c._isUTC,h){case"Milliseconds":return void(I?_.setUTCMilliseconds(m):_.setMilliseconds(m));case"Seconds":return void(I?_.setUTCSeconds(m):_.setSeconds(m));case"Minutes":return void(I?_.setUTCMinutes(m):_.setMinutes(m));case"Hours":return void(I?_.setUTCHours(m):_.setHours(m));case"Date":return void(I?_.setUTCDate(m):_.setDate(m));case"FullYear":break;default:return}G=m,de=c.month(),Te=c.date(),Te=Te===29&&de===1&&!Kr(G)?28:Te,I?_.setUTCFullYear(G,de,Te):_.setFullYear(G,de,Te)}}function fn(c){return c=Ae(c),X(this[c])?this[c]():this}function Hs(c,h){if(typeof c=="object"){c=st(c);var m=ft(c),_,I=m.length;for(_=0;_<I;_++)this[m[_].unit](c[m[_].unit])}else if(c=Ae(c),X(this[c]))return this[c](h);return this}function kc(c,h){return(c%h+h)%h}var Vt;Array.prototype.indexOf?Vt=Array.prototype.indexOf:Vt=function(c){var h;for(h=0;h<this.length;++h)if(this[h]===c)return h;return-1};function Tc(c,h){if(isNaN(c)||isNaN(h))return NaN;var m=kc(h,12);return c+=(h-m)/12,m===1?Kr(c)?29:28:31-m%7%2}j("M",["MM",2],"Mo",function(){return this.month()+1}),j("MMM",0,0,function(c){return this.localeData().monthsShort(this,c)}),j("MMMM",0,0,function(c){return this.localeData().months(this,c)}),Re("M",Ue,Jt),Re("MM",Ue,it),Re("MMM",function(c,h){return h.monthsShortRegex(c)}),Re("MMMM",function(c,h){return h.monthsRegex(c)}),mt(["M","MM"],function(c,h){h[U]=qe(c)-1}),mt(["MMM","MMMM"],function(c,h,m,_){var I=m._locale.monthsParse(c,_,m._strict);I!=null?h[U]=I:v(m).invalidMonth=c});var Sb="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),Ph="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),Dh=/D[oD]?(\[[^\[\]]*\]|\s)+MMMM?/,_b=vn,xb=vn;function Rb(c,h){return c?i(this._months)?this._months[c.month()]:this._months[(this._months.isFormat||Dh).test(h)?"format":"standalone"][c.month()]:i(this._months)?this._months:this._months.standalone}function kb(c,h){return c?i(this._monthsShort)?this._monthsShort[c.month()]:this._monthsShort[Dh.test(h)?"format":"standalone"][c.month()]:i(this._monthsShort)?this._monthsShort:this._monthsShort.standalone}function Tb(c,h,m){var _,I,G,de=c.toLocaleLowerCase();if(!this._monthsParse)for(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[],_=0;_<12;++_)G=w([2e3,_]),this._shortMonthsParse[_]=this.monthsShort(G,"").toLocaleLowerCase(),this._longMonthsParse[_]=this.months(G,"").toLocaleLowerCase();return m?h==="MMM"?(I=Vt.call(this._shortMonthsParse,de),I!==-1?I:null):(I=Vt.call(this._longMonthsParse,de),I!==-1?I:null):h==="MMM"?(I=Vt.call(this._shortMonthsParse,de),I!==-1?I:(I=Vt.call(this._longMonthsParse,de),I!==-1?I:null)):(I=Vt.call(this._longMonthsParse,de),I!==-1?I:(I=Vt.call(this._shortMonthsParse,de),I!==-1?I:null))}function Eb(c,h,m){var _,I,G;if(this._monthsParseExact)return Tb.call(this,c,h,m);for(this._monthsParse||(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[]),_=0;_<12;_++){if(I=w([2e3,_]),m&&!this._longMonthsParse[_]&&(this._longMonthsParse[_]=new RegExp("^"+this.months(I,"").replace(".","")+"$","i"),this._shortMonthsParse[_]=new RegExp("^"+this.monthsShort(I,"").replace(".","")+"$","i")),!m&&!this._monthsParse[_]&&(G="^"+this.months(I,"")+"|^"+this.monthsShort(I,""),this._monthsParse[_]=new RegExp(G.replace(".",""),"i")),m&&h==="MMMM"&&this._longMonthsParse[_].test(c))return _;if(m&&h==="MMM"&&this._shortMonthsParse[_].test(c))return _;if(!m&&this._monthsParse[_].test(c))return _}}function Oh(c,h){if(!c.isValid())return c;if(typeof h=="string"){if(/^\d+$/.test(h))h=qe(h);else if(h=c.localeData().monthsParse(h),!f(h))return c}var m=h,_=c.date();return _=_<29?_:Math.min(_,Tc(c.year(),m)),c._isUTC?c._d.setUTCMonth(m,_):c._d.setMonth(m,_),c}function Mh(c){return c!=null?(Oh(this,c),o.updateOffset(this,!0),this):jn(this,"Month")}function Pb(){return Tc(this.year(),this.month())}function Db(c){return this._monthsParseExact?(l(this,"_monthsRegex")||Ih.call(this),c?this._monthsShortStrictRegex:this._monthsShortRegex):(l(this,"_monthsShortRegex")||(this._monthsShortRegex=_b),this._monthsShortStrictRegex&&c?this._monthsShortStrictRegex:this._monthsShortRegex)}function Ob(c){return this._monthsParseExact?(l(this,"_monthsRegex")||Ih.call(this),c?this._monthsStrictRegex:this._monthsRegex):(l(this,"_monthsRegex")||(this._monthsRegex=xb),this._monthsStrictRegex&&c?this._monthsStrictRegex:this._monthsRegex)}function Ih(){function c(Be,et){return et.length-Be.length}var h=[],m=[],_=[],I,G,de,Te;for(I=0;I<12;I++)G=w([2e3,I]),de=Vn(this.monthsShort(G,"")),Te=Vn(this.months(G,"")),h.push(de),m.push(Te),_.push(Te),_.push(de);h.sort(c),m.sort(c),_.sort(c),this._monthsRegex=new RegExp("^("+_.join("|")+")","i"),this._monthsShortRegex=this._monthsRegex,this._monthsStrictRegex=new RegExp("^("+m.join("|")+")","i"),this._monthsShortStrictRegex=new RegExp("^("+h.join("|")+")","i")}function Mb(c,h,m,_,I,G,de){var Te;return c<100&&c>=0?(Te=new Date(c+400,h,m,_,I,G,de),isFinite(Te.getFullYear())&&Te.setFullYear(c)):Te=new Date(c,h,m,_,I,G,de),Te}function zs(c){var h,m;return c<100&&c>=0?(m=Array.prototype.slice.call(arguments),m[0]=c+400,h=new Date(Date.UTC.apply(null,m)),isFinite(h.getUTCFullYear())&&h.setUTCFullYear(c)):h=new Date(Date.UTC.apply(null,arguments)),h}function wa(c,h,m){var _=7+h-m,I=(7+zs(c,0,_).getUTCDay()-h)%7;return-I+_-1}function Nh(c,h,m,_,I){var G=(7+m-_)%7,de=wa(c,_,I),Te=1+7*(h-1)+G+de,Be,et;return Te<=0?(Be=c-1,et=Ut(Be)+Te):Te>Ut(c)?(Be=c+1,et=Te-Ut(c)):(Be=c,et=Te),{year:Be,dayOfYear:et}}function Ys(c,h,m){var _=wa(c.year(),h,m),I=Math.floor((c.dayOfYear()-_-1)/7)+1,G,de;return I<1?(de=c.year()-1,G=I+Io(de,h,m)):I>Io(c.year(),h,m)?(G=I-Io(c.year(),h,m),de=c.year()+1):(de=c.year(),G=I),{week:G,year:de}}function Io(c,h,m){var _=wa(c,h,m),I=wa(c+1,h,m);return(Ut(c)-_+I)/7}j("w",["ww",2],"wo","week"),j("W",["WW",2],"Wo","isoWeek"),Re("w",Ue,Jt),Re("ww",Ue,it),Re("W",Ue,Jt),Re("WW",Ue,it),wr(["w","ww","W","WW"],function(c,h,m,_){h[_.substr(0,1)]=qe(c)});function Ib(c){return Ys(c,this._week.dow,this._week.doy).week}var Nb={dow:0,doy:6};function Ab(){return this._week.dow}function Fb(){return this._week.doy}function Lb(c){var h=this.localeData().week(this);return c==null?h:this.add((c-h)*7,"d")}function $b(c){var h=Ys(this,1,4).week;return c==null?h:this.add((c-h)*7,"d")}j("d",0,"do","day"),j("dd",0,0,function(c){return this.localeData().weekdaysMin(this,c)}),j("ddd",0,0,function(c){return this.localeData().weekdaysShort(this,c)}),j("dddd",0,0,function(c){return this.localeData().weekdays(this,c)}),j("e",0,0,"weekday"),j("E",0,0,"isoWeekday"),Re("d",Ue),Re("e",Ue),Re("E",Ue),Re("dd",function(c,h){return h.weekdaysMinRegex(c)}),Re("ddd",function(c,h){return h.weekdaysShortRegex(c)}),Re("dddd",function(c,h){return h.weekdaysRegex(c)}),wr(["dd","ddd","dddd"],function(c,h,m,_){var I=m._locale.weekdaysParse(c,_,m._strict);I!=null?h.d=I:v(m).invalidWeekday=c}),wr(["d","e","E"],function(c,h,m,_){h[_]=qe(c)});function Vb(c,h){return typeof c!="string"?c:isNaN(c)?(c=h.weekdaysParse(c),typeof c=="number"?c:null):parseInt(c,10)}function jb(c,h){return typeof c=="string"?h.weekdaysParse(c)%7||7:isNaN(c)?null:c}function Ec(c,h){return c.slice(h,7).concat(c.slice(0,h))}var Bb="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),Ah="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),Wb="Su_Mo_Tu_We_Th_Fr_Sa".split("_"),Hb=vn,zb=vn,Yb=vn;function Ub(c,h){var m=i(this._weekdays)?this._weekdays:this._weekdays[c&&c!==!0&&this._weekdays.isFormat.test(h)?"format":"standalone"];return c===!0?Ec(m,this._week.dow):c?m[c.day()]:m}function qb(c){return c===!0?Ec(this._weekdaysShort,this._week.dow):c?this._weekdaysShort[c.day()]:this._weekdaysShort}function Gb(c){return c===!0?Ec(this._weekdaysMin,this._week.dow):c?this._weekdaysMin[c.day()]:this._weekdaysMin}function Kb(c,h,m){var _,I,G,de=c.toLocaleLowerCase();if(!this._weekdaysParse)for(this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[],_=0;_<7;++_)G=w([2e3,1]).day(_),this._minWeekdaysParse[_]=this.weekdaysMin(G,"").toLocaleLowerCase(),this._shortWeekdaysParse[_]=this.weekdaysShort(G,"").toLocaleLowerCase(),this._weekdaysParse[_]=this.weekdays(G,"").toLocaleLowerCase();return m?h==="dddd"?(I=Vt.call(this._weekdaysParse,de),I!==-1?I:null):h==="ddd"?(I=Vt.call(this._shortWeekdaysParse,de),I!==-1?I:null):(I=Vt.call(this._minWeekdaysParse,de),I!==-1?I:null):h==="dddd"?(I=Vt.call(this._weekdaysParse,de),I!==-1||(I=Vt.call(this._shortWeekdaysParse,de),I!==-1)?I:(I=Vt.call(this._minWeekdaysParse,de),I!==-1?I:null)):h==="ddd"?(I=Vt.call(this._shortWeekdaysParse,de),I!==-1||(I=Vt.call(this._weekdaysParse,de),I!==-1)?I:(I=Vt.call(this._minWeekdaysParse,de),I!==-1?I:null)):(I=Vt.call(this._minWeekdaysParse,de),I!==-1||(I=Vt.call(this._weekdaysParse,de),I!==-1)?I:(I=Vt.call(this._shortWeekdaysParse,de),I!==-1?I:null))}function Xb(c,h,m){var _,I,G;if(this._weekdaysParseExact)return Kb.call(this,c,h,m);for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),_=0;_<7;_++){if(I=w([2e3,1]).day(_),m&&!this._fullWeekdaysParse[_]&&(this._fullWeekdaysParse[_]=new RegExp("^"+this.weekdays(I,"").replace(".","\\.?")+"$","i"),this._shortWeekdaysParse[_]=new RegExp("^"+this.weekdaysShort(I,"").replace(".","\\.?")+"$","i"),this._minWeekdaysParse[_]=new RegExp("^"+this.weekdaysMin(I,"").replace(".","\\.?")+"$","i")),this._weekdaysParse[_]||(G="^"+this.weekdays(I,"")+"|^"+this.weekdaysShort(I,"")+"|^"+this.weekdaysMin(I,""),this._weekdaysParse[_]=new RegExp(G.replace(".",""),"i")),m&&h==="dddd"&&this._fullWeekdaysParse[_].test(c))return _;if(m&&h==="ddd"&&this._shortWeekdaysParse[_].test(c))return _;if(m&&h==="dd"&&this._minWeekdaysParse[_].test(c))return _;if(!m&&this._weekdaysParse[_].test(c))return _}}function Zb(c){if(!this.isValid())return c!=null?this:NaN;var h=jn(this,"Day");return c!=null?(c=Vb(c,this.localeData()),this.add(c-h,"d")):h}function Qb(c){if(!this.isValid())return c!=null?this:NaN;var h=(this.day()+7-this.localeData()._week.dow)%7;return c==null?h:this.add(c-h,"d")}function Jb(c){if(!this.isValid())return c!=null?this:NaN;if(c!=null){var h=jb(c,this.localeData());return this.day(this.day()%7?h:h-7)}else return this.day()||7}function ew(c){return this._weekdaysParseExact?(l(this,"_weekdaysRegex")||Pc.call(this),c?this._weekdaysStrictRegex:this._weekdaysRegex):(l(this,"_weekdaysRegex")||(this._weekdaysRegex=Hb),this._weekdaysStrictRegex&&c?this._weekdaysStrictRegex:this._weekdaysRegex)}function tw(c){return this._weekdaysParseExact?(l(this,"_weekdaysRegex")||Pc.call(this),c?this._weekdaysShortStrictRegex:this._weekdaysShortRegex):(l(this,"_weekdaysShortRegex")||(this._weekdaysShortRegex=zb),this._weekdaysShortStrictRegex&&c?this._weekdaysShortStrictRegex:this._weekdaysShortRegex)}function nw(c){return this._weekdaysParseExact?(l(this,"_weekdaysRegex")||Pc.call(this),c?this._weekdaysMinStrictRegex:this._weekdaysMinRegex):(l(this,"_weekdaysMinRegex")||(this._weekdaysMinRegex=Yb),this._weekdaysMinStrictRegex&&c?this._weekdaysMinStrictRegex:this._weekdaysMinRegex)}function Pc(){function c(bn,$o){return $o.length-bn.length}var h=[],m=[],_=[],I=[],G,de,Te,Be,et;for(G=0;G<7;G++)de=w([2e3,1]).day(G),Te=Vn(this.weekdaysMin(de,"")),Be=Vn(this.weekdaysShort(de,"")),et=Vn(this.weekdays(de,"")),h.push(Te),m.push(Be),_.push(et),I.push(Te),I.push(Be),I.push(et);h.sort(c),m.sort(c),_.sort(c),I.sort(c),this._weekdaysRegex=new RegExp("^("+I.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=new RegExp("^("+_.join("|")+")","i"),this._weekdaysShortStrictRegex=new RegExp("^("+m.join("|")+")","i"),this._weekdaysMinStrictRegex=new RegExp("^("+h.join("|")+")","i")}function Dc(){return this.hours()%12||12}function ow(){return this.hours()||24}j("H",["HH",2],0,"hour"),j("h",["hh",2],0,Dc),j("k",["kk",2],0,ow),j("hmm",0,0,function(){return""+Dc.apply(this)+V(this.minutes(),2)}),j("hmmss",0,0,function(){return""+Dc.apply(this)+V(this.minutes(),2)+V(this.seconds(),2)}),j("Hmm",0,0,function(){return""+this.hours()+V(this.minutes(),2)}),j("Hmmss",0,0,function(){return""+this.hours()+V(this.minutes(),2)+V(this.seconds(),2)});function Fh(c,h){j(c,0,0,function(){return this.localeData().meridiem(this.hours(),this.minutes(),h)})}Fh("a",!0),Fh("A",!1);function Lh(c,h){return h._meridiemParse}Re("a",Lh),Re("A",Lh),Re("H",Ue,Ur),Re("h",Ue,Jt),Re("k",Ue,Jt),Re("HH",Ue,it),Re("hh",Ue,it),Re("kk",Ue,it),Re("hmm",tt),Re("hmmss",Mn),Re("Hmm",tt),Re("Hmmss",Mn),mt(["H","HH"],we),mt(["k","kk"],function(c,h,m){var _=qe(c);h[we]=_===24?0:_}),mt(["a","A"],function(c,h,m){m._isPm=m._locale.isPM(c),m._meridiem=c}),mt(["h","hh"],function(c,h,m){h[we]=qe(c),v(m).bigHour=!0}),mt("hmm",function(c,h,m){var _=c.length-2;h[we]=qe(c.substr(0,_)),h[Ne]=qe(c.substr(_)),v(m).bigHour=!0}),mt("hmmss",function(c,h,m){var _=c.length-4,I=c.length-2;h[we]=qe(c.substr(0,_)),h[Ne]=qe(c.substr(_,2)),h[Ye]=qe(c.substr(I)),v(m).bigHour=!0}),mt("Hmm",function(c,h,m){var _=c.length-2;h[we]=qe(c.substr(0,_)),h[Ne]=qe(c.substr(_))}),mt("Hmmss",function(c,h,m){var _=c.length-4,I=c.length-2;h[we]=qe(c.substr(0,_)),h[Ne]=qe(c.substr(_,2)),h[Ye]=qe(c.substr(I))});function rw(c){return(c+"").toLowerCase().charAt(0)==="p"}var sw=/[ap]\.?m?\.?/i,iw=en("Hours",!0);function aw(c,h,m){return c>11?m?"pm":"PM":m?"am":"AM"}var $h={calendar:A,longDateFormat:ie,invalidDate:W,ordinal:Q,dayOfMonthOrdinalParse:fe,relativeTime:Ce,months:Sb,monthsShort:Ph,week:Nb,weekdays:Bb,weekdaysMin:Wb,weekdaysShort:Ah,meridiemParse:sw},Ft={},Us={},qs;function lw(c,h){var m,_=Math.min(c.length,h.length);for(m=0;m<_;m+=1)if(c[m]!==h[m])return m;return _}function Vh(c){return c&&c.toLowerCase().replace("_","-")}function cw(c){for(var h=0,m,_,I,G;h<c.length;){for(G=Vh(c[h]).split("-"),m=G.length,_=Vh(c[h+1]),_=_?_.split("-"):null;m>0;){if(I=Ca(G.slice(0,m).join("-")),I)return I;if(_&&_.length>=m&&lw(G,_)>=m-1)break;m--}h++}return qs}function dw(c){return!!(c&&c.match("^[^/\\\\]*$"))}function Ca(c){var h=null,m;if(Ft[c]===void 0&&e&&e.exports&&dw(c))try{h=qs._abbr,m=SA,m("./locale/"+c),sr(h)}catch{Ft[c]=null}return Ft[c]}function sr(c,h){var m;return c&&(u(h)?m=No(c):m=Oc(c,h),m?qs=m:typeof console<"u"&&console.warn&&console.warn("Locale "+c+" not found. Did you forget to load it?")),qs._abbr}function Oc(c,h){if(h!==null){var m,_=$h;if(h.abbr=c,Ft[c]!=null)K("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."),_=Ft[c]._config;else if(h.parentLocale!=null)if(Ft[h.parentLocale]!=null)_=Ft[h.parentLocale]._config;else if(m=Ca(h.parentLocale),m!=null)_=m._config;else return Us[h.parentLocale]||(Us[h.parentLocale]=[]),Us[h.parentLocale].push({name:c,config:h}),null;return Ft[c]=new H(Y(_,h)),Us[c]&&Us[c].forEach(function(I){Oc(I.name,I.config)}),sr(c),Ft[c]}else return delete Ft[c],null}function uw(c,h){if(h!=null){var m,_,I=$h;Ft[c]!=null&&Ft[c].parentLocale!=null?Ft[c].set(Y(Ft[c]._config,h)):(_=Ca(c),_!=null&&(I=_._config),h=Y(I,h),_==null&&(h.abbr=c),m=new H(h),m.parentLocale=Ft[c],Ft[c]=m),sr(c)}else Ft[c]!=null&&(Ft[c].parentLocale!=null?(Ft[c]=Ft[c].parentLocale,c===sr()&&sr(c)):Ft[c]!=null&&delete Ft[c]);return Ft[c]}function No(c){var h;if(c&&c._locale&&c._locale._abbr&&(c=c._locale._abbr),!c)return qs;if(!i(c)){if(h=Ca(c),h)return h;c=[c]}return cw(c)}function hw(){return le(Ft)}function Mc(c){var h,m=c._a;return m&&v(c).overflow===-2&&(h=m[U]<0||m[U]>11?U:m[pe]<1||m[pe]>Tc(m[rn],m[U])?pe:m[we]<0||m[we]>24||m[we]===24&&(m[Ne]!==0||m[Ye]!==0||m[Je]!==0)?we:m[Ne]<0||m[Ne]>59?Ne:m[Ye]<0||m[Ye]>59?Ye:m[Je]<0||m[Je]>999?Je:-1,v(c)._overflowDayOfYear&&(h<rn||h>pe)&&(h=pe),v(c)._overflowWeeks&&h===-1&&(h=Ze),v(c)._overflowWeekday&&h===-1&&(h=Ge),v(c).overflow=h),c}var fw=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,pw=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d|))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,mw=/Z|[+-]\d\d(?::?\d\d)?/,Sa=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/],["YYYYMM",/\d{6}/,!1],["YYYY",/\d{4}/,!1]],Ic=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],gw=/^\/?Date\((-?\d+)/i,yw=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/,vw={UT:0,GMT:0,EDT:-4*60,EST:-5*60,CDT:-5*60,CST:-6*60,MDT:-6*60,MST:-7*60,PDT:-7*60,PST:-8*60};function jh(c){var h,m,_=c._i,I=fw.exec(_)||pw.exec(_),G,de,Te,Be,et=Sa.length,bn=Ic.length;if(I){for(v(c).iso=!0,h=0,m=et;h<m;h++)if(Sa[h][1].exec(I[1])){de=Sa[h][0],G=Sa[h][2]!==!1;break}if(de==null){c._isValid=!1;return}if(I[3]){for(h=0,m=bn;h<m;h++)if(Ic[h][1].exec(I[3])){Te=(I[2]||" ")+Ic[h][0];break}if(Te==null){c._isValid=!1;return}}if(!G&&Te!=null){c._isValid=!1;return}if(I[4])if(mw.exec(I[4]))Be="Z";else{c._isValid=!1;return}c._f=de+(Te||"")+(Be||""),Ac(c)}else c._isValid=!1}function bw(c,h,m,_,I,G){var de=[ww(c),Ph.indexOf(h),parseInt(m,10),parseInt(_,10),parseInt(I,10)];return G&&de.push(parseInt(G,10)),de}function ww(c){var h=parseInt(c,10);return h<=49?2e3+h:h<=999?1900+h:h}function Cw(c){return c.replace(/\([^()]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").replace(/^\s\s*/,"").replace(/\s\s*$/,"")}function Sw(c,h,m){if(c){var _=Ah.indexOf(c),I=new Date(h[0],h[1],h[2]).getDay();if(_!==I)return v(m).weekdayMismatch=!0,m._isValid=!1,!1}return!0}function _w(c,h,m){if(c)return vw[c];if(h)return 0;var _=parseInt(m,10),I=_%100,G=(_-I)/100;return G*60+I}function Bh(c){var h=yw.exec(Cw(c._i)),m;if(h){if(m=bw(h[4],h[3],h[2],h[5],h[6],h[7]),!Sw(h[1],m,c))return;c._a=m,c._tzm=_w(h[8],h[9],h[10]),c._d=zs.apply(null,c._a),c._d.setUTCMinutes(c._d.getUTCMinutes()-c._tzm),v(c).rfc2822=!0}else c._isValid=!1}function xw(c){var h=gw.exec(c._i);if(h!==null){c._d=new Date(+h[1]);return}if(jh(c),c._isValid===!1)delete c._isValid;else return;if(Bh(c),c._isValid===!1)delete c._isValid;else return;c._strict?c._isValid=!1:o.createFromInputFallback(c)}o.createFromInputFallback=R("value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are discouraged. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.",function(c){c._d=new Date(c._i+(c._useUTC?" UTC":""))});function Xr(c,h,m){return c??h??m}function Rw(c){var h=new Date(o.now());return c._useUTC?[h.getUTCFullYear(),h.getUTCMonth(),h.getUTCDate()]:[h.getFullYear(),h.getMonth(),h.getDate()]}function Nc(c){var h,m,_=[],I,G,de;if(!c._d){for(I=Rw(c),c._w&&c._a[pe]==null&&c._a[U]==null&&kw(c),c._dayOfYear!=null&&(de=Xr(c._a[rn],I[rn]),(c._dayOfYear>Ut(de)||c._dayOfYear===0)&&(v(c)._overflowDayOfYear=!0),m=zs(de,0,c._dayOfYear),c._a[U]=m.getUTCMonth(),c._a[pe]=m.getUTCDate()),h=0;h<3&&c._a[h]==null;++h)c._a[h]=_[h]=I[h];for(;h<7;h++)c._a[h]=_[h]=c._a[h]==null?h===2?1:0:c._a[h];c._a[we]===24&&c._a[Ne]===0&&c._a[Ye]===0&&c._a[Je]===0&&(c._nextDay=!0,c._a[we]=0),c._d=(c._useUTC?zs:Mb).apply(null,_),G=c._useUTC?c._d.getUTCDay():c._d.getDay(),c._tzm!=null&&c._d.setUTCMinutes(c._d.getUTCMinutes()-c._tzm),c._nextDay&&(c._a[we]=24),c._w&&typeof c._w.d<"u"&&c._w.d!==G&&(v(c).weekdayMismatch=!0)}}function kw(c){var h,m,_,I,G,de,Te,Be,et;h=c._w,h.GG!=null||h.W!=null||h.E!=null?(G=1,de=4,m=Xr(h.GG,c._a[rn],Ys(Dt(),1,4).year),_=Xr(h.W,1),I=Xr(h.E,1),(I<1||I>7)&&(Be=!0)):(G=c._locale._week.dow,de=c._locale._week.doy,et=Ys(Dt(),G,de),m=Xr(h.gg,c._a[rn],et.year),_=Xr(h.w,et.week),h.d!=null?(I=h.d,(I<0||I>6)&&(Be=!0)):h.e!=null?(I=h.e+G,(h.e<0||h.e>6)&&(Be=!0)):I=G),_<1||_>Io(m,G,de)?v(c)._overflowWeeks=!0:Be!=null?v(c)._overflowWeekday=!0:(Te=Nh(m,_,I,G,de),c._a[rn]=Te.year,c._dayOfYear=Te.dayOfYear)}o.ISO_8601=function(){},o.RFC_2822=function(){};function Ac(c){if(c._f===o.ISO_8601){jh(c);return}if(c._f===o.RFC_2822){Bh(c);return}c._a=[],v(c).empty=!0;var h=""+c._i,m,_,I,G,de,Te=h.length,Be=0,et,bn;for(I=ce(c._f,c._locale).match(B)||[],bn=I.length,m=0;m<bn;m++)G=I[m],_=(h.match(xc(G,c))||[])[0],_&&(de=h.substr(0,h.indexOf(_)),de.length>0&&v(c).unusedInput.push(de),h=h.slice(h.indexOf(_)+_.length),Be+=_.length),se[G]?(_?v(c).empty=!1:v(c).unusedTokens.push(G),Rc(G,_,c)):c._strict&&!_&&v(c).unusedTokens.push(G);v(c).charsLeftOver=Te-Be,h.length>0&&v(c).unusedInput.push(h),c._a[we]<=12&&v(c).bigHour===!0&&c._a[we]>0&&(v(c).bigHour=void 0),v(c).parsedDateParts=c._a.slice(0),v(c).meridiem=c._meridiem,c._a[we]=Tw(c._locale,c._a[we],c._meridiem),et=v(c).era,et!==null&&(c._a[rn]=c._locale.erasConvertYear(et,c._a[rn])),Nc(c),Mc(c)}function Tw(c,h,m){var _;return m==null?h:c.meridiemHour!=null?c.meridiemHour(h,m):(c.isPM!=null&&(_=c.isPM(m),_&&h<12&&(h+=12),!_&&h===12&&(h=0)),h)}function Ew(c){var h,m,_,I,G,de,Te=!1,Be=c._f.length;if(Be===0){v(c).invalidFormat=!0,c._d=new Date(NaN);return}for(I=0;I<Be;I++)G=0,de=!1,h=O({},c),c._useUTC!=null&&(h._useUTC=c._useUTC),h._f=c._f[I],Ac(h),P(h)&&(de=!0),G+=v(h).charsLeftOver,G+=v(h).unusedTokens.length*10,v(h).score=G,Te?G<_&&(_=G,m=h):(_==null||G<_||de)&&(_=G,m=h,de&&(Te=!0));b(c,m||h)}function Pw(c){if(!c._d){var h=st(c._i),m=h.day===void 0?h.date:h.day;c._a=y([h.year,h.month,m,h.hour,h.minute,h.second,h.millisecond],function(_){return _&&parseInt(_,10)}),Nc(c)}}function Dw(c){var h=new N(Mc(Wh(c)));return h._nextDay&&(h.add(1,"d"),h._nextDay=void 0),h}function Wh(c){var h=c._i,m=c._f;return c._locale=c._locale||No(c._l),h===null||m===void 0&&h===""?x({nullInput:!0}):(typeof h=="string"&&(c._i=h=c._locale.preparse(h)),F(h)?new N(Mc(h)):(p(h)?c._d=h:i(m)?Ew(c):m?Ac(c):Ow(c),P(c)||(c._d=null),c))}function Ow(c){var h=c._i;u(h)?c._d=new Date(o.now()):p(h)?c._d=new Date(h.valueOf()):typeof h=="string"?xw(c):i(h)?(c._a=y(h.slice(0),function(m){return parseInt(m,10)}),Nc(c)):a(h)?Pw(c):f(h)?c._d=new Date(h):o.createFromInputFallback(c)}function Hh(c,h,m,_,I){var G={};return(h===!0||h===!1)&&(_=h,h=void 0),(m===!0||m===!1)&&(_=m,m=void 0),(a(c)&&d(c)||i(c)&&c.length===0)&&(c=void 0),G._isAMomentObject=!0,G._useUTC=G._isUTC=I,G._l=m,G._i=c,G._f=h,G._strict=_,Dw(G)}function Dt(c,h,m,_){return Hh(c,h,m,_,!1)}var Mw=R("moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var c=Dt.apply(null,arguments);return this.isValid()&&c.isValid()?c<this?this:c:x()}),Iw=R("moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var c=Dt.apply(null,arguments);return this.isValid()&&c.isValid()?c>this?this:c:x()});function zh(c,h){var m,_;if(h.length===1&&i(h[0])&&(h=h[0]),!h.length)return Dt();for(m=h[0],_=1;_<h.length;++_)(!h[_].isValid()||h[_][c](m))&&(m=h[_]);return m}function Nw(){var c=[].slice.call(arguments,0);return zh("isBefore",c)}function Aw(){var c=[].slice.call(arguments,0);return zh("isAfter",c)}var Fw=function(){return Date.now?Date.now():+new Date},Gs=["year","quarter","month","week","day","hour","minute","second","millisecond"];function Lw(c){var h,m=!1,_,I=Gs.length;for(h in c)if(l(c,h)&&!(Vt.call(Gs,h)!==-1&&(c[h]==null||!isNaN(c[h]))))return!1;for(_=0;_<I;++_)if(c[Gs[_]]){if(m)return!1;parseFloat(c[Gs[_]])!==qe(c[Gs[_]])&&(m=!0)}return!0}function $w(){return this._isValid}function Vw(){return to(NaN)}function _a(c){var h=st(c),m=h.year||0,_=h.quarter||0,I=h.month||0,G=h.week||h.isoWeek||0,de=h.day||0,Te=h.hour||0,Be=h.minute||0,et=h.second||0,bn=h.millisecond||0;this._isValid=Lw(h),this._milliseconds=+bn+et*1e3+Be*6e4+Te*1e3*60*60,this._days=+de+G*7,this._months=+I+_*3+m*12,this._data={},this._locale=No(),this._bubble()}function xa(c){return c instanceof _a}function Fc(c){return c<0?Math.round(-1*c)*-1:Math.round(c)}function jw(c,h,m){var _=Math.min(c.length,h.length),I=Math.abs(c.length-h.length),G=0,de;for(de=0;de<_;de++)qe(c[de])!==qe(h[de])&&G++;return G+I}function Yh(c,h){j(c,0,0,function(){var m=this.utcOffset(),_="+";return m<0&&(m=-m,_="-"),_+V(~~(m/60),2)+h+V(~~m%60,2)})}Yh("Z",":"),Yh("ZZ",""),Re("Z",pt),Re("ZZ",pt),mt(["Z","ZZ"],function(c,h,m){m._useUTC=!0,m._tzm=Lc(pt,c)});var Bw=/([\+\-]|\d\d)/gi;function Lc(c,h){var m=(h||"").match(c),_,I,G;return m===null?null:(_=m[m.length-1]||[],I=(_+"").match(Bw)||["-",0,0],G=+(I[1]*60)+qe(I[2]),G===0?0:I[0]==="+"?G:-G)}function $c(c,h){var m,_;return h._isUTC?(m=h.clone(),_=(F(c)||p(c)?c.valueOf():Dt(c).valueOf())-m.valueOf(),m._d.setTime(m._d.valueOf()+_),o.updateOffset(m,!1),m):Dt(c).local()}function Vc(c){return-Math.round(c._d.getTimezoneOffset())}o.updateOffset=function(){};function Ww(c,h,m){var _=this._offset||0,I;if(!this.isValid())return c!=null?this:NaN;if(c!=null){if(typeof c=="string"){if(c=Lc(pt,c),c===null)return this}else Math.abs(c)<16&&!m&&(c=c*60);return!this._isUTC&&h&&(I=Vc(this)),this._offset=c,this._isUTC=!0,I!=null&&this.add(I,"m"),_!==c&&(!h||this._changeInProgress?Kh(this,to(c-_,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,o.updateOffset(this,!0),this._changeInProgress=null)),this}else return this._isUTC?_:Vc(this)}function Hw(c,h){return c!=null?(typeof c!="string"&&(c=-c),this.utcOffset(c,h),this):-this.utcOffset()}function zw(c){return this.utcOffset(0,c)}function Yw(c){return this._isUTC&&(this.utcOffset(0,c),this._isUTC=!1,c&&this.subtract(Vc(this),"m")),this}function Uw(){if(this._tzm!=null)this.utcOffset(this._tzm,!1,!0);else if(typeof this._i=="string"){var c=Lc(ho,this._i);c!=null?this.utcOffset(c):this.utcOffset(0,!0)}return this}function qw(c){return this.isValid()?(c=c?Dt(c).utcOffset():0,(this.utcOffset()-c)%60===0):!1}function Gw(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()}function Kw(){if(!u(this._isDSTShifted))return this._isDSTShifted;var c={},h;return O(c,this),c=Wh(c),c._a?(h=c._isUTC?w(c._a):Dt(c._a),this._isDSTShifted=this.isValid()&&jw(c._a,h.toArray())>0):this._isDSTShifted=!1,this._isDSTShifted}function Xw(){return this.isValid()?!this._isUTC:!1}function Zw(){return this.isValid()?this._isUTC:!1}function Uh(){return this.isValid()?this._isUTC&&this._offset===0:!1}var Qw=/^(-|\+)?(?:(\d*)[. ])?(\d+):(\d+)(?::(\d+)(\.\d*)?)?$/,Jw=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;function to(c,h){var m=c,_=null,I,G,de;return xa(c)?m={ms:c._milliseconds,d:c._days,M:c._months}:f(c)||!isNaN(+c)?(m={},h?m[h]=+c:m.milliseconds=+c):(_=Qw.exec(c))?(I=_[1]==="-"?-1:1,m={y:0,d:qe(_[pe])*I,h:qe(_[we])*I,m:qe(_[Ne])*I,s:qe(_[Ye])*I,ms:qe(Fc(_[Je]*1e3))*I}):(_=Jw.exec(c))?(I=_[1]==="-"?-1:1,m={y:Cr(_[2],I),M:Cr(_[3],I),w:Cr(_[4],I),d:Cr(_[5],I),h:Cr(_[6],I),m:Cr(_[7],I),s:Cr(_[8],I)}):m==null?m={}:typeof m=="object"&&("from"in m||"to"in m)&&(de=eC(Dt(m.from),Dt(m.to)),m={},m.ms=de.milliseconds,m.M=de.months),G=new _a(m),xa(c)&&l(c,"_locale")&&(G._locale=c._locale),xa(c)&&l(c,"_isValid")&&(G._isValid=c._isValid),G}to.fn=_a.prototype,to.invalid=Vw;function Cr(c,h){var m=c&&parseFloat(c.replace(",","."));return(isNaN(m)?0:m)*h}function qh(c,h){var m={};return m.months=h.month()-c.month()+(h.year()-c.year())*12,c.clone().add(m.months,"M").isAfter(h)&&--m.months,m.milliseconds=+h-+c.clone().add(m.months,"M"),m}function eC(c,h){var m;return c.isValid()&&h.isValid()?(h=$c(h,c),c.isBefore(h)?m=qh(c,h):(m=qh(h,c),m.milliseconds=-m.milliseconds,m.months=-m.months),m):{milliseconds:0,months:0}}function Gh(c,h){return function(m,_){var I,G;return _!==null&&!isNaN(+_)&&(K(h,"moment()."+h+"(period, number) is deprecated. Please use moment()."+h+"(number, period). See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info."),G=m,m=_,_=G),I=to(m,_),Kh(this,I,c),this}}function Kh(c,h,m,_){var I=h._milliseconds,G=Fc(h._days),de=Fc(h._months);c.isValid()&&(_=_??!0,de&&Oh(c,jn(c,"Month")+de*m),G&&fo(c,"Date",jn(c,"Date")+G*m),I&&c._d.setTime(c._d.valueOf()+I*m),_&&o.updateOffset(c,G||de))}var tC=Gh(1,"add"),nC=Gh(-1,"subtract");function Xh(c){return typeof c=="string"||c instanceof String}function oC(c){return F(c)||p(c)||Xh(c)||f(c)||sC(c)||rC(c)||c===null||c===void 0}function rC(c){var h=a(c)&&!d(c),m=!1,_=["years","year","y","months","month","M","days","day","d","dates","date","D","hours","hour","h","minutes","minute","m","seconds","second","s","milliseconds","millisecond","ms"],I,G,de=_.length;for(I=0;I<de;I+=1)G=_[I],m=m||l(c,G);return h&&m}function sC(c){var h=i(c),m=!1;return h&&(m=c.filter(function(_){return!f(_)&&Xh(c)}).length===0),h&&m}function iC(c){var h=a(c)&&!d(c),m=!1,_=["sameDay","nextDay","lastDay","nextWeek","lastWeek","sameElse"],I,G;for(I=0;I<_.length;I+=1)G=_[I],m=m||l(c,G);return h&&m}function aC(c,h){var m=c.diff(h,"days",!0);return m<-6?"sameElse":m<-1?"lastWeek":m<0?"lastDay":m<1?"sameDay":m<2?"nextDay":m<7?"nextWeek":"sameElse"}function lC(c,h){arguments.length===1&&(arguments[0]?oC(arguments[0])?(c=arguments[0],h=void 0):iC(arguments[0])&&(h=arguments[0],c=void 0):(c=void 0,h=void 0));var m=c||Dt(),_=$c(m,this).startOf("day"),I=o.calendarFormat(this,_)||"sameElse",G=h&&(X(h[I])?h[I].call(this,m):h[I]);return this.format(G||this.localeData().calendar(I,this,Dt(m)))}function cC(){return new N(this)}function dC(c,h){var m=F(c)?c:Dt(c);return this.isValid()&&m.isValid()?(h=Ae(h)||"millisecond",h==="millisecond"?this.valueOf()>m.valueOf():m.valueOf()<this.clone().startOf(h).valueOf()):!1}function uC(c,h){var m=F(c)?c:Dt(c);return this.isValid()&&m.isValid()?(h=Ae(h)||"millisecond",h==="millisecond"?this.valueOf()<m.valueOf():this.clone().endOf(h).valueOf()<m.valueOf()):!1}function hC(c,h,m,_){var I=F(c)?c:Dt(c),G=F(h)?h:Dt(h);return this.isValid()&&I.isValid()&&G.isValid()?(_=_||"()",(_[0]==="("?this.isAfter(I,m):!this.isBefore(I,m))&&(_[1]===")"?this.isBefore(G,m):!this.isAfter(G,m))):!1}function fC(c,h){var m=F(c)?c:Dt(c),_;return this.isValid()&&m.isValid()?(h=Ae(h)||"millisecond",h==="millisecond"?this.valueOf()===m.valueOf():(_=m.valueOf(),this.clone().startOf(h).valueOf()<=_&&_<=this.clone().endOf(h).valueOf())):!1}function pC(c,h){return this.isSame(c,h)||this.isAfter(c,h)}function mC(c,h){return this.isSame(c,h)||this.isBefore(c,h)}function gC(c,h,m){var _,I,G;if(!this.isValid())return NaN;if(_=$c(c,this),!_.isValid())return NaN;switch(I=(_.utcOffset()-this.utcOffset())*6e4,h=Ae(h),h){case"year":G=Ra(this,_)/12;break;case"month":G=Ra(this,_);break;case"quarter":G=Ra(this,_)/3;break;case"second":G=(this-_)/1e3;break;case"minute":G=(this-_)/6e4;break;case"hour":G=(this-_)/36e5;break;case"day":G=(this-_-I)/864e5;break;case"week":G=(this-_-I)/6048e5;break;default:G=this-_}return m?G:Sn(G)}function Ra(c,h){if(c.date()<h.date())return-Ra(h,c);var m=(h.year()-c.year())*12+(h.month()-c.month()),_=c.clone().add(m,"months"),I,G;return h-_<0?(I=c.clone().add(m-1,"months"),G=(h-_)/(_-I)):(I=c.clone().add(m+1,"months"),G=(h-_)/(I-_)),-(m+G)||0}o.defaultFormat="YYYY-MM-DDTHH:mm:ssZ",o.defaultFormatUtc="YYYY-MM-DDTHH:mm:ss[Z]";function yC(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")}function vC(c){if(!this.isValid())return null;var h=c!==!0,m=h?this.clone().utc():this;return m.year()<0||m.year()>9999?te(m,h?"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYYYY-MM-DD[T]HH:mm:ss.SSSZ"):X(Date.prototype.toISOString)?h?this.toDate().toISOString():new Date(this.valueOf()+this.utcOffset()*60*1e3).toISOString().replace("Z",te(m,"Z")):te(m,h?"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYY-MM-DD[T]HH:mm:ss.SSSZ")}function bC(){if(!this.isValid())return"moment.invalid(/* "+this._i+" */)";var c="moment",h="",m,_,I,G;return this.isLocal()||(c=this.utcOffset()===0?"moment.utc":"moment.parseZone",h="Z"),m="["+c+'("]',_=0<=this.year()&&this.year()<=9999?"YYYY":"YYYYYY",I="-MM-DD[T]HH:mm:ss.SSS",G=h+'[")]',this.format(m+_+I+G)}function wC(c){c||(c=this.isUtc()?o.defaultFormatUtc:o.defaultFormat);var h=te(this,c);return this.localeData().postformat(h)}function CC(c,h){return this.isValid()&&(F(c)&&c.isValid()||Dt(c).isValid())?to({to:this,from:c}).locale(this.locale()).humanize(!h):this.localeData().invalidDate()}function SC(c){return this.from(Dt(),c)}function _C(c,h){return this.isValid()&&(F(c)&&c.isValid()||Dt(c).isValid())?to({from:this,to:c}).locale(this.locale()).humanize(!h):this.localeData().invalidDate()}function xC(c){return this.to(Dt(),c)}function Zh(c){var h;return c===void 0?this._locale._abbr:(h=No(c),h!=null&&(this._locale=h),this)}var Qh=R("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(c){return c===void 0?this.localeData():this.locale(c)});function Jh(){return this._locale}var ka=1e3,Zr=60*ka,Ta=60*Zr,ef=(365*400+97)*24*Ta;function Qr(c,h){return(c%h+h)%h}function tf(c,h,m){return c<100&&c>=0?new Date(c+400,h,m)-ef:new Date(c,h,m).valueOf()}function nf(c,h,m){return c<100&&c>=0?Date.UTC(c+400,h,m)-ef:Date.UTC(c,h,m)}function RC(c){var h,m;if(c=Ae(c),c===void 0||c==="millisecond"||!this.isValid())return this;switch(m=this._isUTC?nf:tf,c){case"year":h=m(this.year(),0,1);break;case"quarter":h=m(this.year(),this.month()-this.month()%3,1);break;case"month":h=m(this.year(),this.month(),1);break;case"week":h=m(this.year(),this.month(),this.date()-this.weekday());break;case"isoWeek":h=m(this.year(),this.month(),this.date()-(this.isoWeekday()-1));break;case"day":case"date":h=m(this.year(),this.month(),this.date());break;case"hour":h=this._d.valueOf(),h-=Qr(h+(this._isUTC?0:this.utcOffset()*Zr),Ta);break;case"minute":h=this._d.valueOf(),h-=Qr(h,Zr);break;case"second":h=this._d.valueOf(),h-=Qr(h,ka);break}return this._d.setTime(h),o.updateOffset(this,!0),this}function kC(c){var h,m;if(c=Ae(c),c===void 0||c==="millisecond"||!this.isValid())return this;switch(m=this._isUTC?nf:tf,c){case"year":h=m(this.year()+1,0,1)-1;break;case"quarter":h=m(this.year(),this.month()-this.month()%3+3,1)-1;break;case"month":h=m(this.year(),this.month()+1,1)-1;break;case"week":h=m(this.year(),this.month(),this.date()-this.weekday()+7)-1;break;case"isoWeek":h=m(this.year(),this.month(),this.date()-(this.isoWeekday()-1)+7)-1;break;case"day":case"date":h=m(this.year(),this.month(),this.date()+1)-1;break;case"hour":h=this._d.valueOf(),h+=Ta-Qr(h+(this._isUTC?0:this.utcOffset()*Zr),Ta)-1;break;case"minute":h=this._d.valueOf(),h+=Zr-Qr(h,Zr)-1;break;case"second":h=this._d.valueOf(),h+=ka-Qr(h,ka)-1;break}return this._d.setTime(h),o.updateOffset(this,!0),this}function TC(){return this._d.valueOf()-(this._offset||0)*6e4}function EC(){return Math.floor(this.valueOf()/1e3)}function PC(){return new Date(this.valueOf())}function DC(){var c=this;return[c.year(),c.month(),c.date(),c.hour(),c.minute(),c.second(),c.millisecond()]}function OC(){var c=this;return{years:c.year(),months:c.month(),date:c.date(),hours:c.hours(),minutes:c.minutes(),seconds:c.seconds(),milliseconds:c.milliseconds()}}function MC(){return this.isValid()?this.toISOString():null}function IC(){return P(this)}function NC(){return b({},v(this))}function AC(){return v(this).overflow}function FC(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}}j("N",0,0,"eraAbbr"),j("NN",0,0,"eraAbbr"),j("NNN",0,0,"eraAbbr"),j("NNNN",0,0,"eraName"),j("NNNNN",0,0,"eraNarrow"),j("y",["y",1],"yo","eraYear"),j("y",["yy",2],0,"eraYear"),j("y",["yyy",3],0,"eraYear"),j("y",["yyyy",4],0,"eraYear"),Re("N",jc),Re("NN",jc),Re("NNN",jc),Re("NNNN",qC),Re("NNNNN",GC),mt(["N","NN","NNN","NNNN","NNNNN"],function(c,h,m,_){var I=m._locale.erasParse(c,_,m._strict);I?v(m).era=I:v(m).invalidEra=c}),Re("y",vt),Re("yy",vt),Re("yyy",vt),Re("yyyy",vt),Re("yo",KC),mt(["y","yy","yyy","yyyy"],rn),mt(["yo"],function(c,h,m,_){var I;m._locale._eraYearOrdinalRegex&&(I=c.match(m._locale._eraYearOrdinalRegex)),m._locale.eraYearOrdinalParse?h[rn]=m._locale.eraYearOrdinalParse(c,I):h[rn]=parseInt(c,10)});function LC(c,h){var m,_,I,G=this._eras||No("en")._eras;for(m=0,_=G.length;m<_;++m){switch(typeof G[m].since){case"string":I=o(G[m].since).startOf("day"),G[m].since=I.valueOf();break}switch(typeof G[m].until){case"undefined":G[m].until=1/0;break;case"string":I=o(G[m].until).startOf("day").valueOf(),G[m].until=I.valueOf();break}}return G}function $C(c,h,m){var _,I,G=this.eras(),de,Te,Be;for(c=c.toUpperCase(),_=0,I=G.length;_<I;++_)if(de=G[_].name.toUpperCase(),Te=G[_].abbr.toUpperCase(),Be=G[_].narrow.toUpperCase(),m)switch(h){case"N":case"NN":case"NNN":if(Te===c)return G[_];break;case"NNNN":if(de===c)return G[_];break;case"NNNNN":if(Be===c)return G[_];break}else if([de,Te,Be].indexOf(c)>=0)return G[_]}function VC(c,h){var m=c.since<=c.until?1:-1;return h===void 0?o(c.since).year():o(c.since).year()+(h-c.offset)*m}function jC(){var c,h,m,_=this.localeData().eras();for(c=0,h=_.length;c<h;++c)if(m=this.clone().startOf("day").valueOf(),_[c].since<=m&&m<=_[c].until||_[c].until<=m&&m<=_[c].since)return _[c].name;return""}function BC(){var c,h,m,_=this.localeData().eras();for(c=0,h=_.length;c<h;++c)if(m=this.clone().startOf("day").valueOf(),_[c].since<=m&&m<=_[c].until||_[c].until<=m&&m<=_[c].since)return _[c].narrow;return""}function WC(){var c,h,m,_=this.localeData().eras();for(c=0,h=_.length;c<h;++c)if(m=this.clone().startOf("day").valueOf(),_[c].since<=m&&m<=_[c].until||_[c].until<=m&&m<=_[c].since)return _[c].abbr;return""}function HC(){var c,h,m,_,I=this.localeData().eras();for(c=0,h=I.length;c<h;++c)if(m=I[c].since<=I[c].until?1:-1,_=this.clone().startOf("day").valueOf(),I[c].since<=_&&_<=I[c].until||I[c].until<=_&&_<=I[c].since)return(this.year()-o(I[c].since).year())*m+I[c].offset;return this.year()}function zC(c){return l(this,"_erasNameRegex")||Bc.call(this),c?this._erasNameRegex:this._erasRegex}function YC(c){return l(this,"_erasAbbrRegex")||Bc.call(this),c?this._erasAbbrRegex:this._erasRegex}function UC(c){return l(this,"_erasNarrowRegex")||Bc.call(this),c?this._erasNarrowRegex:this._erasRegex}function jc(c,h){return h.erasAbbrRegex(c)}function qC(c,h){return h.erasNameRegex(c)}function GC(c,h){return h.erasNarrowRegex(c)}function KC(c,h){return h._eraYearOrdinalRegex||vt}function Bc(){var c=[],h=[],m=[],_=[],I,G,de,Te,Be,et=this.eras();for(I=0,G=et.length;I<G;++I)de=Vn(et[I].name),Te=Vn(et[I].abbr),Be=Vn(et[I].narrow),h.push(de),c.push(Te),m.push(Be),_.push(de),_.push(Te),_.push(Be);this._erasRegex=new RegExp("^("+_.join("|")+")","i"),this._erasNameRegex=new RegExp("^("+h.join("|")+")","i"),this._erasAbbrRegex=new RegExp("^("+c.join("|")+")","i"),this._erasNarrowRegex=new RegExp("^("+m.join("|")+")","i")}j(0,["gg",2],0,function(){return this.weekYear()%100}),j(0,["GG",2],0,function(){return this.isoWeekYear()%100});function Ea(c,h){j(0,[c,c.length],0,h)}Ea("gggg","weekYear"),Ea("ggggg","weekYear"),Ea("GGGG","isoWeekYear"),Ea("GGGGG","isoWeekYear"),Re("G",ln),Re("g",ln),Re("GG",Ue,it),Re("gg",Ue,it),Re("GGGG",Ie,Xt),Re("gggg",Ie,Xt),Re("GGGGG",He,on),Re("ggggg",He,on),wr(["gggg","ggggg","GGGG","GGGGG"],function(c,h,m,_){h[_.substr(0,2)]=qe(c)}),wr(["gg","GG"],function(c,h,m,_){h[_]=o.parseTwoDigitYear(c)});function XC(c){return of.call(this,c,this.week(),this.weekday()+this.localeData()._week.dow,this.localeData()._week.dow,this.localeData()._week.doy)}function ZC(c){return of.call(this,c,this.isoWeek(),this.isoWeekday(),1,4)}function QC(){return Io(this.year(),1,4)}function JC(){return Io(this.isoWeekYear(),1,4)}function eS(){var c=this.localeData()._week;return Io(this.year(),c.dow,c.doy)}function tS(){var c=this.localeData()._week;return Io(this.weekYear(),c.dow,c.doy)}function of(c,h,m,_,I){var G;return c==null?Ys(this,_,I).year:(G=Io(c,_,I),h>G&&(h=G),nS.call(this,c,h,m,_,I))}function nS(c,h,m,_,I){var G=Nh(c,h,m,_,I),de=zs(G.year,0,G.dayOfYear);return this.year(de.getUTCFullYear()),this.month(de.getUTCMonth()),this.date(de.getUTCDate()),this}j("Q",0,"Qo","quarter"),Re("Q",Kt),mt("Q",function(c,h){h[U]=(qe(c)-1)*3});function oS(c){return c==null?Math.ceil((this.month()+1)/3):this.month((c-1)*3+this.month()%3)}j("D",["DD",2],"Do","date"),Re("D",Ue,Jt),Re("DD",Ue,it),Re("Do",function(c,h){return c?h._dayOfMonthOrdinalParse||h._ordinalParse:h._dayOfMonthOrdinalParseLenient}),mt(["D","DD"],pe),mt("Do",function(c,h){h[pe]=qe(c.match(Ue)[0])});var rf=en("Date",!0);j("DDD",["DDDD",3],"DDDo","dayOfYear"),Re("DDD",hn),Re("DDDD",Yt),mt(["DDD","DDDD"],function(c,h,m){m._dayOfYear=qe(c)});function rS(c){var h=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return c==null?h:this.add(c-h,"d")}j("m",["mm",2],0,"minute"),Re("m",Ue,Ur),Re("mm",Ue,it),mt(["m","mm"],Ne);var sS=en("Minutes",!1);j("s",["ss",2],0,"second"),Re("s",Ue,Ur),Re("ss",Ue,it),mt(["s","ss"],Ye);var iS=en("Seconds",!1);j("S",0,0,function(){return~~(this.millisecond()/100)}),j(0,["SS",2],0,function(){return~~(this.millisecond()/10)}),j(0,["SSS",3],0,"millisecond"),j(0,["SSSS",4],0,function(){return this.millisecond()*10}),j(0,["SSSSS",5],0,function(){return this.millisecond()*100}),j(0,["SSSSSS",6],0,function(){return this.millisecond()*1e3}),j(0,["SSSSSSS",7],0,function(){return this.millisecond()*1e4}),j(0,["SSSSSSSS",8],0,function(){return this.millisecond()*1e5}),j(0,["SSSSSSSSS",9],0,function(){return this.millisecond()*1e6}),Re("S",hn,Kt),Re("SS",hn,it),Re("SSS",hn,Yt);var ir,sf;for(ir="SSSS";ir.length<=9;ir+="S")Re(ir,vt);function aS(c,h){h[Je]=qe(("0."+c)*1e3)}for(ir="S";ir.length<=9;ir+="S")mt(ir,aS);sf=en("Milliseconds",!1),j("z",0,0,"zoneAbbr"),j("zz",0,0,"zoneName");function lS(){return this._isUTC?"UTC":""}function cS(){return this._isUTC?"Coordinated Universal Time":""}var ge=N.prototype;ge.add=tC,ge.calendar=lC,ge.clone=cC,ge.diff=gC,ge.endOf=kC,ge.format=wC,ge.from=CC,ge.fromNow=SC,ge.to=_C,ge.toNow=xC,ge.get=fn,ge.invalidAt=AC,ge.isAfter=dC,ge.isBefore=uC,ge.isBetween=hC,ge.isSame=fC,ge.isSameOrAfter=pC,ge.isSameOrBefore=mC,ge.isValid=IC,ge.lang=Qh,ge.locale=Zh,ge.localeData=Jh,ge.max=Iw,ge.min=Mw,ge.parsingFlags=NC,ge.set=Hs,ge.startOf=RC,ge.subtract=nC,ge.toArray=DC,ge.toObject=OC,ge.toDate=PC,ge.toISOString=vC,ge.inspect=bC,typeof Symbol<"u"&&Symbol.for!=null&&(ge[Symbol.for("nodejs.util.inspect.custom")]=function(){return"Moment<"+this.format()+">"}),ge.toJSON=MC,ge.toString=yC,ge.unix=EC,ge.valueOf=TC,ge.creationData=FC,ge.eraName=jC,ge.eraNarrow=BC,ge.eraAbbr=WC,ge.eraYear=HC,ge.year=At,ge.isLeapYear=Wt,ge.weekYear=XC,ge.isoWeekYear=ZC,ge.quarter=ge.quarters=oS,ge.month=Mh,ge.daysInMonth=Pb,ge.week=ge.weeks=Lb,ge.isoWeek=ge.isoWeeks=$b,ge.weeksInYear=eS,ge.weeksInWeekYear=tS,ge.isoWeeksInYear=QC,ge.isoWeeksInISOWeekYear=JC,ge.date=rf,ge.day=ge.days=Zb,ge.weekday=Qb,ge.isoWeekday=Jb,ge.dayOfYear=rS,ge.hour=ge.hours=iw,ge.minute=ge.minutes=sS,ge.second=ge.seconds=iS,ge.millisecond=ge.milliseconds=sf,ge.utcOffset=Ww,ge.utc=zw,ge.local=Yw,ge.parseZone=Uw,ge.hasAlignedHourOffset=qw,ge.isDST=Gw,ge.isLocal=Xw,ge.isUtcOffset=Zw,ge.isUtc=Uh,ge.isUTC=Uh,ge.zoneAbbr=lS,ge.zoneName=cS,ge.dates=R("dates accessor is deprecated. Use date instead.",rf),ge.months=R("months accessor is deprecated. Use month instead",Mh),ge.years=R("years accessor is deprecated. Use year instead",At),ge.zone=R("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",Hw),ge.isDSTShifted=R("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",Kw);function dS(c){return Dt(c*1e3)}function uS(){return Dt.apply(null,arguments).parseZone()}function af(c){return c}var ct=H.prototype;ct.calendar=M,ct.longDateFormat=he,ct.invalidDate=re,ct.ordinal=me,ct.preparse=af,ct.postformat=af,ct.relativeTime=ve,ct.pastFuture=xe,ct.set=q,ct.eras=LC,ct.erasParse=$C,ct.erasConvertYear=VC,ct.erasAbbrRegex=YC,ct.erasNameRegex=zC,ct.erasNarrowRegex=UC,ct.months=Rb,ct.monthsShort=kb,ct.monthsParse=Eb,ct.monthsRegex=Ob,ct.monthsShortRegex=Db,ct.week=Ib,ct.firstDayOfYear=Fb,ct.firstDayOfWeek=Ab,ct.weekdays=Ub,ct.weekdaysMin=Gb,ct.weekdaysShort=qb,ct.weekdaysParse=Xb,ct.weekdaysRegex=ew,ct.weekdaysShortRegex=tw,ct.weekdaysMinRegex=nw,ct.isPM=rw,ct.meridiem=aw;function Pa(c,h,m,_){var I=No(),G=w().set(_,h);return I[m](G,c)}function lf(c,h,m){if(f(c)&&(h=c,c=void 0),c=c||"",h!=null)return Pa(c,h,m,"month");var _,I=[];for(_=0;_<12;_++)I[_]=Pa(c,_,m,"month");return I}function Wc(c,h,m,_){typeof c=="boolean"?(f(h)&&(m=h,h=void 0),h=h||""):(h=c,m=h,c=!1,f(h)&&(m=h,h=void 0),h=h||"");var I=No(),G=c?I._week.dow:0,de,Te=[];if(m!=null)return Pa(h,(m+G)%7,_,"day");for(de=0;de<7;de++)Te[de]=Pa(h,(de+G)%7,_,"day");return Te}function hS(c,h){return lf(c,h,"months")}function fS(c,h){return lf(c,h,"monthsShort")}function pS(c,h,m){return Wc(c,h,m,"weekdays")}function mS(c,h,m){return Wc(c,h,m,"weekdaysShort")}function gS(c,h,m){return Wc(c,h,m,"weekdaysMin")}sr("en",{eras:[{since:"0001-01-01",until:1/0,offset:1,name:"Anno Domini",narrow:"AD",abbr:"AD"},{since:"0000-12-31",until:-1/0,offset:1,name:"Before Christ",narrow:"BC",abbr:"BC"}],dayOfMonthOrdinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(c){var h=c%10,m=qe(c%100/10)===1?"th":h===1?"st":h===2?"nd":h===3?"rd":"th";return c+m}}),o.lang=R("moment.lang is deprecated. Use moment.locale instead.",sr),o.langData=R("moment.langData is deprecated. Use moment.localeData instead.",No);var Ao=Math.abs;function yS(){var c=this._data;return this._milliseconds=Ao(this._milliseconds),this._days=Ao(this._days),this._months=Ao(this._months),c.milliseconds=Ao(c.milliseconds),c.seconds=Ao(c.seconds),c.minutes=Ao(c.minutes),c.hours=Ao(c.hours),c.months=Ao(c.months),c.years=Ao(c.years),this}function cf(c,h,m,_){var I=to(h,m);return c._milliseconds+=_*I._milliseconds,c._days+=_*I._days,c._months+=_*I._months,c._bubble()}function vS(c,h){return cf(this,c,h,1)}function bS(c,h){return cf(this,c,h,-1)}function df(c){return c<0?Math.floor(c):Math.ceil(c)}function wS(){var c=this._milliseconds,h=this._days,m=this._months,_=this._data,I,G,de,Te,Be;return c>=0&&h>=0&&m>=0||c<=0&&h<=0&&m<=0||(c+=df(Hc(m)+h)*864e5,h=0,m=0),_.milliseconds=c%1e3,I=Sn(c/1e3),_.seconds=I%60,G=Sn(I/60),_.minutes=G%60,de=Sn(G/60),_.hours=de%24,h+=Sn(de/24),Be=Sn(uf(h)),m+=Be,h-=df(Hc(Be)),Te=Sn(m/12),m%=12,_.days=h,_.months=m,_.years=Te,this}function uf(c){return c*4800/146097}function Hc(c){return c*146097/4800}function CS(c){if(!this.isValid())return NaN;var h,m,_=this._milliseconds;if(c=Ae(c),c==="month"||c==="quarter"||c==="year")switch(h=this._days+_/864e5,m=this._months+uf(h),c){case"month":return m;case"quarter":return m/3;case"year":return m/12}else switch(h=this._days+Math.round(Hc(this._months)),c){case"week":return h/7+_/6048e5;case"day":return h+_/864e5;case"hour":return h*24+_/36e5;case"minute":return h*1440+_/6e4;case"second":return h*86400+_/1e3;case"millisecond":return Math.floor(h*864e5)+_;default:throw new Error("Unknown unit "+c)}}function Fo(c){return function(){return this.as(c)}}var hf=Fo("ms"),SS=Fo("s"),_S=Fo("m"),xS=Fo("h"),RS=Fo("d"),kS=Fo("w"),TS=Fo("M"),ES=Fo("Q"),PS=Fo("y"),DS=hf;function OS(){return to(this)}function MS(c){return c=Ae(c),this.isValid()?this[c+"s"]():NaN}function Sr(c){return function(){return this.isValid()?this._data[c]:NaN}}var IS=Sr("milliseconds"),NS=Sr("seconds"),AS=Sr("minutes"),FS=Sr("hours"),LS=Sr("days"),$S=Sr("months"),VS=Sr("years");function jS(){return Sn(this.days()/7)}var Lo=Math.round,Jr={ss:44,s:45,m:45,h:22,d:26,w:null,M:11};function BS(c,h,m,_,I){return I.relativeTime(h||1,!!m,c,_)}function WS(c,h,m,_){var I=to(c).abs(),G=Lo(I.as("s")),de=Lo(I.as("m")),Te=Lo(I.as("h")),Be=Lo(I.as("d")),et=Lo(I.as("M")),bn=Lo(I.as("w")),$o=Lo(I.as("y")),ar=G<=m.ss&&["s",G]||G<m.s&&["ss",G]||de<=1&&["m"]||de<m.m&&["mm",de]||Te<=1&&["h"]||Te<m.h&&["hh",Te]||Be<=1&&["d"]||Be<m.d&&["dd",Be];return m.w!=null&&(ar=ar||bn<=1&&["w"]||bn<m.w&&["ww",bn]),ar=ar||et<=1&&["M"]||et<m.M&&["MM",et]||$o<=1&&["y"]||["yy",$o],ar[2]=h,ar[3]=+c>0,ar[4]=_,BS.apply(null,ar)}function HS(c){return c===void 0?Lo:typeof c=="function"?(Lo=c,!0):!1}function zS(c,h){return Jr[c]===void 0?!1:h===void 0?Jr[c]:(Jr[c]=h,c==="s"&&(Jr.ss=h-1),!0)}function YS(c,h){if(!this.isValid())return this.localeData().invalidDate();var m=!1,_=Jr,I,G;return typeof c=="object"&&(h=c,c=!1),typeof c=="boolean"&&(m=c),typeof h=="object"&&(_=Object.assign({},Jr,h),h.s!=null&&h.ss==null&&(_.ss=h.s-1)),I=this.localeData(),G=WS(this,!m,_,I),m&&(G=I.pastFuture(+this,G)),I.postformat(G)}var zc=Math.abs;function es(c){return(c>0)-(c<0)||+c}function Da(){if(!this.isValid())return this.localeData().invalidDate();var c=zc(this._milliseconds)/1e3,h=zc(this._days),m=zc(this._months),_,I,G,de,Te=this.asSeconds(),Be,et,bn,$o;return Te?(_=Sn(c/60),I=Sn(_/60),c%=60,_%=60,G=Sn(m/12),m%=12,de=c?c.toFixed(3).replace(/\.?0+$/,""):"",Be=Te<0?"-":"",et=es(this._months)!==es(Te)?"-":"",bn=es(this._days)!==es(Te)?"-":"",$o=es(this._milliseconds)!==es(Te)?"-":"",Be+"P"+(G?et+G+"Y":"")+(m?et+m+"M":"")+(h?bn+h+"D":"")+(I||_||c?"T":"")+(I?$o+I+"H":"")+(_?$o+_+"M":"")+(c?$o+de+"S":"")):"P0D"}var nt=_a.prototype;nt.isValid=$w,nt.abs=yS,nt.add=vS,nt.subtract=bS,nt.as=CS,nt.asMilliseconds=hf,nt.asSeconds=SS,nt.asMinutes=_S,nt.asHours=xS,nt.asDays=RS,nt.asWeeks=kS,nt.asMonths=TS,nt.asQuarters=ES,nt.asYears=PS,nt.valueOf=DS,nt._bubble=wS,nt.clone=OS,nt.get=MS,nt.milliseconds=IS,nt.seconds=NS,nt.minutes=AS,nt.hours=FS,nt.days=LS,nt.weeks=jS,nt.months=$S,nt.years=VS,nt.humanize=YS,nt.toISOString=Da,nt.toString=Da,nt.toJSON=Da,nt.locale=Zh,nt.localeData=Jh,nt.toIsoString=R("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",Da),nt.lang=Qh,j("X",0,0,"unix"),j("x",0,0,"valueOf"),Re("x",ln),Re("X",Qt),mt("X",function(c,h,m){m._d=new Date(parseFloat(c)*1e3)}),mt("x",function(c,h,m){m._d=new Date(qe(c))});//! moment.js
|
|
298
|
-
return o.version="2.30.1",r(Dt),o.fn=ge,o.min=Nw,o.max=Aw,o.now=Fw,o.utc=w,o.unix=dS,o.months=hS,o.isDate=p,o.locale=sr,o.invalid=x,o.duration=to,o.isMoment=F,o.weekdays=pS,o.parseZone=uS,o.localeData=No,o.isDuration=xa,o.monthsShort=fS,o.weekdaysMin=gS,o.defineLocale=Oc,o.updateLocale=uw,o.locales=hw,o.weekdaysShort=mS,o.normalizeUnits=Ae,o.relativeTimeRounding=HS,o.relativeTimeThreshold=zS,o.calendarFormat=aC,o.prototype=ge,o.HTML5_FMT={DATETIME_LOCAL:"YYYY-MM-DDTHH:mm",DATETIME_LOCAL_SECONDS:"YYYY-MM-DDTHH:mm:ss",DATETIME_LOCAL_MS:"YYYY-MM-DDTHH:mm:ss.SSS",DATE:"YYYY-MM-DD",TIME:"HH:mm",TIME_SECONDS:"HH:mm:ss",TIME_MS:"HH:mm:ss.SSS",WEEK:"GGGG-[W]WW",MONTH:"YYYY-MM"},o})}(al)),al.exports}
|
|
297
|
+
`+new Error().stack),m=!1}return h.apply(this,arguments)},h)}var $={};function K(c,h){o.deprecationHandler!=null&&o.deprecationHandler(c,h),$[c]||(z(h),$[c]=!0)}o.suppressDeprecationWarnings=!1,o.deprecationHandler=null;function X(c){return typeof Function<"u"&&c instanceof Function||Object.prototype.toString.call(c)==="[object Function]"}function q(c){var h,m;for(m in c)l(c,m)&&(h=c[m],X(h)?this[m]=h:this["_"+m]=h);this._config=c,this._dayOfMonthOrdinalParseLenient=new RegExp((this._dayOfMonthOrdinalParse.source||this._ordinalParse.source)+"|"+/\d{1,2}/.source)}function Y(c,h){var m=b({},c),_;for(_ in h)l(h,_)&&(a(c[_])&&a(h[_])?(m[_]={},b(m[_],c[_]),b(m[_],h[_])):h[_]!=null?m[_]=h[_]:delete m[_]);for(_ in c)l(c,_)&&!l(h,_)&&a(c[_])&&(m[_]=b({},m[_]));return m}function H(c){c!=null&&this.set(c)}var le;Object.keys?le=Object.keys:le=function(c){var h,m=[];for(h in c)l(c,h)&&m.push(h);return m};var A={sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"};function M(c,h,m){var _=this._calendar[c]||this._calendar.sameElse;return X(_)?_.call(h,m):_}function V(c,h,m){var _=""+Math.abs(c),I=h-_.length,G=c>=0;return(G?m?"+":"":"-")+Math.pow(10,Math.max(0,I)).toString().substr(1)+_}var B=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,ne=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,oe={},se={};function j(c,h,m,_){var I=_;typeof _=="string"&&(I=function(){return this[_]()}),c&&(se[c]=I),h&&(se[h[0]]=function(){return V(I.apply(this,arguments),h[1],h[2])}),m&&(se[m]=function(){return this.localeData().ordinal(I.apply(this,arguments),c)})}function J(c){return c.match(/\[[\s\S]/)?c.replace(/^\[|\]$/g,""):c.replace(/\\/g,"")}function ee(c){var h=c.match(B),m,_;for(m=0,_=h.length;m<_;m++)se[h[m]]?h[m]=se[h[m]]:h[m]=J(h[m]);return function(I){var G="",de;for(de=0;de<_;de++)G+=X(h[de])?h[de].call(I,c):h[de];return G}}function te(c,h){return c.isValid()?(h=ce(h,c.localeData()),oe[h]=oe[h]||ee(h),oe[h](c)):c.localeData().invalidDate()}function ce(c,h){var m=5;function _(I){return h.longDateFormat(I)||I}for(ne.lastIndex=0;m>=0&&ne.test(c);)c=c.replace(ne,_),ne.lastIndex=0,m-=1;return c}var ie={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"};function he(c){var h=this._longDateFormat[c],m=this._longDateFormat[c.toUpperCase()];return h||!m?h:(this._longDateFormat[c]=m.match(B).map(function(_){return _==="MMMM"||_==="MM"||_==="DD"||_==="dddd"?_.slice(1):_}).join(""),this._longDateFormat[c])}var W="Invalid date";function re(){return this._invalidDate}var Q="%d",fe=/\d{1,2}/;function me(c){return this._ordinal.replace("%d",c)}var Ce={future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",w:"a week",ww:"%d weeks",M:"a month",MM:"%d months",y:"a year",yy:"%d years"};function ve(c,h,m,_){var I=this._relativeTime[m];return X(I)?I(c,h,m,_):I.replace(/%d/i,c)}function xe(c,h){var m=this._relativeTime[c>0?"future":"past"];return X(m)?m(h):m.replace(/%s/i,h)}var Ve={D:"date",dates:"date",date:"date",d:"day",days:"day",day:"day",e:"weekday",weekdays:"weekday",weekday:"weekday",E:"isoWeekday",isoweekdays:"isoWeekday",isoweekday:"isoWeekday",DDD:"dayOfYear",dayofyears:"dayOfYear",dayofyear:"dayOfYear",h:"hour",hours:"hour",hour:"hour",ms:"millisecond",milliseconds:"millisecond",millisecond:"millisecond",m:"minute",minutes:"minute",minute:"minute",M:"month",months:"month",month:"month",Q:"quarter",quarters:"quarter",quarter:"quarter",s:"second",seconds:"second",second:"second",gg:"weekYear",weekyears:"weekYear",weekyear:"weekYear",GG:"isoWeekYear",isoweekyears:"isoWeekYear",isoweekyear:"isoWeekYear",w:"week",weeks:"week",week:"week",W:"isoWeek",isoweeks:"isoWeek",isoweek:"isoWeek",y:"year",years:"year",year:"year"};function Ae(c){return typeof c=="string"?Ve[c]||Ve[c.toLowerCase()]:void 0}function st(c){var h={},m,_;for(_ in c)l(c,_)&&(m=Ae(_),m&&(h[m]=c[_]));return h}var Pe={date:9,day:11,weekday:11,isoWeekday:11,dayOfYear:4,hour:13,millisecond:16,minute:14,month:8,quarter:7,second:15,weekYear:1,isoWeekYear:1,week:5,isoWeek:5,year:1};function ft(c){var h=[],m;for(m in c)l(c,m)&&h.push({unit:m,priority:Pe[m]});return h.sort(function(_,I){return _.priority-I.priority}),h}var Kt=/\d/,it=/\d\d/,Yt=/\d{3}/,Xt=/\d{4}/,on=/[+-]?\d{6}/,Ue=/\d\d?/,tt=/\d\d\d\d?/,Mn=/\d\d\d\d\d\d?/,hn=/\d{1,3}/,Ie=/\d{1,4}/,He=/[+-]?\d{1,6}/,vt=/\d+/,ln=/[+-]?\d+/,ho=/Z|[+-]\d\d:?\d\d/gi,pt=/Z|[+-]\d\d(?::?\d\d)?/gi,Qt=/[+-]?\d+(\.\d{1,3})?/,vn=/[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i,Jt=/^[1-9]\d?/,Ur=/^([1-9]\d|\d)/,qr;qr={};function Re(c,h,m){qr[c]=X(h)?h:function(_,I){return _&&m?m:h}}function xc(c,h){return l(qr,c)?qr[c](h._strict,h._locale):new RegExp(ba(c))}function ba(c){return Vn(c.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(h,m,_,I,G){return m||_||I||G}))}function Vn(c){return c.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function Sn(c){return c<0?Math.ceil(c)||0:Math.floor(c)}function qe(c){var h=+c,m=0;return h!==0&&isFinite(h)&&(m=Sn(h)),m}var Gr={};function mt(c,h){var m,_=h,I;for(typeof c=="string"&&(c=[c]),f(h)&&(_=function(G,de){de[h]=qe(G)}),I=c.length,m=0;m<I;m++)Gr[c[m]]=_}function wr(c,h){mt(c,function(m,_,I,G){I._w=I._w||{},h(m,I._w,I,G)})}function Rc(c,h,m){h!=null&&l(Gr,c)&&Gr[c](h,m._a,m,c)}function Kr(c){return c%4===0&&c%100!==0||c%400===0}var rn=0,U=1,pe=2,we=3,Ne=4,Ye=5,Je=6,Ze=7,Ge=8;j("Y",0,0,function(){var c=this.year();return c<=9999?V(c,4):"+"+c}),j(0,["YY",2],0,function(){return this.year()%100}),j(0,["YYYY",4],0,"year"),j(0,["YYYYY",5],0,"year"),j(0,["YYYYYY",6,!0],0,"year"),Re("Y",ln),Re("YY",Ue,it),Re("YYYY",Ie,Xt),Re("YYYYY",He,on),Re("YYYYYY",He,on),mt(["YYYYY","YYYYYY"],rn),mt("YYYY",function(c,h){h[rn]=c.length===2?o.parseTwoDigitYear(c):qe(c)}),mt("YY",function(c,h){h[rn]=o.parseTwoDigitYear(c)}),mt("Y",function(c,h){h[rn]=parseInt(c,10)});function Ut(c){return Kr(c)?366:365}o.parseTwoDigitYear=function(c){return qe(c)+(qe(c)>68?1900:2e3)};var At=en("FullYear",!0);function Wt(){return Kr(this.year())}function en(c,h){return function(m){return m!=null?(fo(this,c,m),o.updateOffset(this,h),this):jn(this,c)}}function jn(c,h){if(!c.isValid())return NaN;var m=c._d,_=c._isUTC;switch(h){case"Milliseconds":return _?m.getUTCMilliseconds():m.getMilliseconds();case"Seconds":return _?m.getUTCSeconds():m.getSeconds();case"Minutes":return _?m.getUTCMinutes():m.getMinutes();case"Hours":return _?m.getUTCHours():m.getHours();case"Date":return _?m.getUTCDate():m.getDate();case"Day":return _?m.getUTCDay():m.getDay();case"Month":return _?m.getUTCMonth():m.getMonth();case"FullYear":return _?m.getUTCFullYear():m.getFullYear();default:return NaN}}function fo(c,h,m){var _,I,G,de,Te;if(!(!c.isValid()||isNaN(m))){switch(_=c._d,I=c._isUTC,h){case"Milliseconds":return void(I?_.setUTCMilliseconds(m):_.setMilliseconds(m));case"Seconds":return void(I?_.setUTCSeconds(m):_.setSeconds(m));case"Minutes":return void(I?_.setUTCMinutes(m):_.setMinutes(m));case"Hours":return void(I?_.setUTCHours(m):_.setHours(m));case"Date":return void(I?_.setUTCDate(m):_.setDate(m));case"FullYear":break;default:return}G=m,de=c.month(),Te=c.date(),Te=Te===29&&de===1&&!Kr(G)?28:Te,I?_.setUTCFullYear(G,de,Te):_.setFullYear(G,de,Te)}}function fn(c){return c=Ae(c),X(this[c])?this[c]():this}function Hs(c,h){if(typeof c=="object"){c=st(c);var m=ft(c),_,I=m.length;for(_=0;_<I;_++)this[m[_].unit](c[m[_].unit])}else if(c=Ae(c),X(this[c]))return this[c](h);return this}function kc(c,h){return(c%h+h)%h}var Vt;Array.prototype.indexOf?Vt=Array.prototype.indexOf:Vt=function(c){var h;for(h=0;h<this.length;++h)if(this[h]===c)return h;return-1};function Tc(c,h){if(isNaN(c)||isNaN(h))return NaN;var m=kc(h,12);return c+=(h-m)/12,m===1?Kr(c)?29:28:31-m%7%2}j("M",["MM",2],"Mo",function(){return this.month()+1}),j("MMM",0,0,function(c){return this.localeData().monthsShort(this,c)}),j("MMMM",0,0,function(c){return this.localeData().months(this,c)}),Re("M",Ue,Jt),Re("MM",Ue,it),Re("MMM",function(c,h){return h.monthsShortRegex(c)}),Re("MMMM",function(c,h){return h.monthsRegex(c)}),mt(["M","MM"],function(c,h){h[U]=qe(c)-1}),mt(["MMM","MMMM"],function(c,h,m,_){var I=m._locale.monthsParse(c,_,m._strict);I!=null?h[U]=I:v(m).invalidMonth=c});var Sb="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),Ph="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),Dh=/D[oD]?(\[[^\[\]]*\]|\s)+MMMM?/,_b=vn,xb=vn;function Rb(c,h){return c?i(this._months)?this._months[c.month()]:this._months[(this._months.isFormat||Dh).test(h)?"format":"standalone"][c.month()]:i(this._months)?this._months:this._months.standalone}function kb(c,h){return c?i(this._monthsShort)?this._monthsShort[c.month()]:this._monthsShort[Dh.test(h)?"format":"standalone"][c.month()]:i(this._monthsShort)?this._monthsShort:this._monthsShort.standalone}function Tb(c,h,m){var _,I,G,de=c.toLocaleLowerCase();if(!this._monthsParse)for(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[],_=0;_<12;++_)G=w([2e3,_]),this._shortMonthsParse[_]=this.monthsShort(G,"").toLocaleLowerCase(),this._longMonthsParse[_]=this.months(G,"").toLocaleLowerCase();return m?h==="MMM"?(I=Vt.call(this._shortMonthsParse,de),I!==-1?I:null):(I=Vt.call(this._longMonthsParse,de),I!==-1?I:null):h==="MMM"?(I=Vt.call(this._shortMonthsParse,de),I!==-1?I:(I=Vt.call(this._longMonthsParse,de),I!==-1?I:null)):(I=Vt.call(this._longMonthsParse,de),I!==-1?I:(I=Vt.call(this._shortMonthsParse,de),I!==-1?I:null))}function Eb(c,h,m){var _,I,G;if(this._monthsParseExact)return Tb.call(this,c,h,m);for(this._monthsParse||(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[]),_=0;_<12;_++){if(I=w([2e3,_]),m&&!this._longMonthsParse[_]&&(this._longMonthsParse[_]=new RegExp("^"+this.months(I,"").replace(".","")+"$","i"),this._shortMonthsParse[_]=new RegExp("^"+this.monthsShort(I,"").replace(".","")+"$","i")),!m&&!this._monthsParse[_]&&(G="^"+this.months(I,"")+"|^"+this.monthsShort(I,""),this._monthsParse[_]=new RegExp(G.replace(".",""),"i")),m&&h==="MMMM"&&this._longMonthsParse[_].test(c))return _;if(m&&h==="MMM"&&this._shortMonthsParse[_].test(c))return _;if(!m&&this._monthsParse[_].test(c))return _}}function Oh(c,h){if(!c.isValid())return c;if(typeof h=="string"){if(/^\d+$/.test(h))h=qe(h);else if(h=c.localeData().monthsParse(h),!f(h))return c}var m=h,_=c.date();return _=_<29?_:Math.min(_,Tc(c.year(),m)),c._isUTC?c._d.setUTCMonth(m,_):c._d.setMonth(m,_),c}function Mh(c){return c!=null?(Oh(this,c),o.updateOffset(this,!0),this):jn(this,"Month")}function Pb(){return Tc(this.year(),this.month())}function Db(c){return this._monthsParseExact?(l(this,"_monthsRegex")||Ih.call(this),c?this._monthsShortStrictRegex:this._monthsShortRegex):(l(this,"_monthsShortRegex")||(this._monthsShortRegex=_b),this._monthsShortStrictRegex&&c?this._monthsShortStrictRegex:this._monthsShortRegex)}function Ob(c){return this._monthsParseExact?(l(this,"_monthsRegex")||Ih.call(this),c?this._monthsStrictRegex:this._monthsRegex):(l(this,"_monthsRegex")||(this._monthsRegex=xb),this._monthsStrictRegex&&c?this._monthsStrictRegex:this._monthsRegex)}function Ih(){function c(Be,et){return et.length-Be.length}var h=[],m=[],_=[],I,G,de,Te;for(I=0;I<12;I++)G=w([2e3,I]),de=Vn(this.monthsShort(G,"")),Te=Vn(this.months(G,"")),h.push(de),m.push(Te),_.push(Te),_.push(de);h.sort(c),m.sort(c),_.sort(c),this._monthsRegex=new RegExp("^("+_.join("|")+")","i"),this._monthsShortRegex=this._monthsRegex,this._monthsStrictRegex=new RegExp("^("+m.join("|")+")","i"),this._monthsShortStrictRegex=new RegExp("^("+h.join("|")+")","i")}function Mb(c,h,m,_,I,G,de){var Te;return c<100&&c>=0?(Te=new Date(c+400,h,m,_,I,G,de),isFinite(Te.getFullYear())&&Te.setFullYear(c)):Te=new Date(c,h,m,_,I,G,de),Te}function zs(c){var h,m;return c<100&&c>=0?(m=Array.prototype.slice.call(arguments),m[0]=c+400,h=new Date(Date.UTC.apply(null,m)),isFinite(h.getUTCFullYear())&&h.setUTCFullYear(c)):h=new Date(Date.UTC.apply(null,arguments)),h}function wa(c,h,m){var _=7+h-m,I=(7+zs(c,0,_).getUTCDay()-h)%7;return-I+_-1}function Nh(c,h,m,_,I){var G=(7+m-_)%7,de=wa(c,_,I),Te=1+7*(h-1)+G+de,Be,et;return Te<=0?(Be=c-1,et=Ut(Be)+Te):Te>Ut(c)?(Be=c+1,et=Te-Ut(c)):(Be=c,et=Te),{year:Be,dayOfYear:et}}function Ys(c,h,m){var _=wa(c.year(),h,m),I=Math.floor((c.dayOfYear()-_-1)/7)+1,G,de;return I<1?(de=c.year()-1,G=I+Io(de,h,m)):I>Io(c.year(),h,m)?(G=I-Io(c.year(),h,m),de=c.year()+1):(de=c.year(),G=I),{week:G,year:de}}function Io(c,h,m){var _=wa(c,h,m),I=wa(c+1,h,m);return(Ut(c)-_+I)/7}j("w",["ww",2],"wo","week"),j("W",["WW",2],"Wo","isoWeek"),Re("w",Ue,Jt),Re("ww",Ue,it),Re("W",Ue,Jt),Re("WW",Ue,it),wr(["w","ww","W","WW"],function(c,h,m,_){h[_.substr(0,1)]=qe(c)});function Ib(c){return Ys(c,this._week.dow,this._week.doy).week}var Nb={dow:0,doy:6};function Ab(){return this._week.dow}function Fb(){return this._week.doy}function Lb(c){var h=this.localeData().week(this);return c==null?h:this.add((c-h)*7,"d")}function $b(c){var h=Ys(this,1,4).week;return c==null?h:this.add((c-h)*7,"d")}j("d",0,"do","day"),j("dd",0,0,function(c){return this.localeData().weekdaysMin(this,c)}),j("ddd",0,0,function(c){return this.localeData().weekdaysShort(this,c)}),j("dddd",0,0,function(c){return this.localeData().weekdays(this,c)}),j("e",0,0,"weekday"),j("E",0,0,"isoWeekday"),Re("d",Ue),Re("e",Ue),Re("E",Ue),Re("dd",function(c,h){return h.weekdaysMinRegex(c)}),Re("ddd",function(c,h){return h.weekdaysShortRegex(c)}),Re("dddd",function(c,h){return h.weekdaysRegex(c)}),wr(["dd","ddd","dddd"],function(c,h,m,_){var I=m._locale.weekdaysParse(c,_,m._strict);I!=null?h.d=I:v(m).invalidWeekday=c}),wr(["d","e","E"],function(c,h,m,_){h[_]=qe(c)});function Vb(c,h){return typeof c!="string"?c:isNaN(c)?(c=h.weekdaysParse(c),typeof c=="number"?c:null):parseInt(c,10)}function jb(c,h){return typeof c=="string"?h.weekdaysParse(c)%7||7:isNaN(c)?null:c}function Ec(c,h){return c.slice(h,7).concat(c.slice(0,h))}var Bb="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),Ah="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),Wb="Su_Mo_Tu_We_Th_Fr_Sa".split("_"),Hb=vn,zb=vn,Yb=vn;function Ub(c,h){var m=i(this._weekdays)?this._weekdays:this._weekdays[c&&c!==!0&&this._weekdays.isFormat.test(h)?"format":"standalone"];return c===!0?Ec(m,this._week.dow):c?m[c.day()]:m}function qb(c){return c===!0?Ec(this._weekdaysShort,this._week.dow):c?this._weekdaysShort[c.day()]:this._weekdaysShort}function Gb(c){return c===!0?Ec(this._weekdaysMin,this._week.dow):c?this._weekdaysMin[c.day()]:this._weekdaysMin}function Kb(c,h,m){var _,I,G,de=c.toLocaleLowerCase();if(!this._weekdaysParse)for(this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[],_=0;_<7;++_)G=w([2e3,1]).day(_),this._minWeekdaysParse[_]=this.weekdaysMin(G,"").toLocaleLowerCase(),this._shortWeekdaysParse[_]=this.weekdaysShort(G,"").toLocaleLowerCase(),this._weekdaysParse[_]=this.weekdays(G,"").toLocaleLowerCase();return m?h==="dddd"?(I=Vt.call(this._weekdaysParse,de),I!==-1?I:null):h==="ddd"?(I=Vt.call(this._shortWeekdaysParse,de),I!==-1?I:null):(I=Vt.call(this._minWeekdaysParse,de),I!==-1?I:null):h==="dddd"?(I=Vt.call(this._weekdaysParse,de),I!==-1||(I=Vt.call(this._shortWeekdaysParse,de),I!==-1)?I:(I=Vt.call(this._minWeekdaysParse,de),I!==-1?I:null)):h==="ddd"?(I=Vt.call(this._shortWeekdaysParse,de),I!==-1||(I=Vt.call(this._weekdaysParse,de),I!==-1)?I:(I=Vt.call(this._minWeekdaysParse,de),I!==-1?I:null)):(I=Vt.call(this._minWeekdaysParse,de),I!==-1||(I=Vt.call(this._weekdaysParse,de),I!==-1)?I:(I=Vt.call(this._shortWeekdaysParse,de),I!==-1?I:null))}function Xb(c,h,m){var _,I,G;if(this._weekdaysParseExact)return Kb.call(this,c,h,m);for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),_=0;_<7;_++){if(I=w([2e3,1]).day(_),m&&!this._fullWeekdaysParse[_]&&(this._fullWeekdaysParse[_]=new RegExp("^"+this.weekdays(I,"").replace(".","\\.?")+"$","i"),this._shortWeekdaysParse[_]=new RegExp("^"+this.weekdaysShort(I,"").replace(".","\\.?")+"$","i"),this._minWeekdaysParse[_]=new RegExp("^"+this.weekdaysMin(I,"").replace(".","\\.?")+"$","i")),this._weekdaysParse[_]||(G="^"+this.weekdays(I,"")+"|^"+this.weekdaysShort(I,"")+"|^"+this.weekdaysMin(I,""),this._weekdaysParse[_]=new RegExp(G.replace(".",""),"i")),m&&h==="dddd"&&this._fullWeekdaysParse[_].test(c))return _;if(m&&h==="ddd"&&this._shortWeekdaysParse[_].test(c))return _;if(m&&h==="dd"&&this._minWeekdaysParse[_].test(c))return _;if(!m&&this._weekdaysParse[_].test(c))return _}}function Zb(c){if(!this.isValid())return c!=null?this:NaN;var h=jn(this,"Day");return c!=null?(c=Vb(c,this.localeData()),this.add(c-h,"d")):h}function Qb(c){if(!this.isValid())return c!=null?this:NaN;var h=(this.day()+7-this.localeData()._week.dow)%7;return c==null?h:this.add(c-h,"d")}function Jb(c){if(!this.isValid())return c!=null?this:NaN;if(c!=null){var h=jb(c,this.localeData());return this.day(this.day()%7?h:h-7)}else return this.day()||7}function ew(c){return this._weekdaysParseExact?(l(this,"_weekdaysRegex")||Pc.call(this),c?this._weekdaysStrictRegex:this._weekdaysRegex):(l(this,"_weekdaysRegex")||(this._weekdaysRegex=Hb),this._weekdaysStrictRegex&&c?this._weekdaysStrictRegex:this._weekdaysRegex)}function tw(c){return this._weekdaysParseExact?(l(this,"_weekdaysRegex")||Pc.call(this),c?this._weekdaysShortStrictRegex:this._weekdaysShortRegex):(l(this,"_weekdaysShortRegex")||(this._weekdaysShortRegex=zb),this._weekdaysShortStrictRegex&&c?this._weekdaysShortStrictRegex:this._weekdaysShortRegex)}function nw(c){return this._weekdaysParseExact?(l(this,"_weekdaysRegex")||Pc.call(this),c?this._weekdaysMinStrictRegex:this._weekdaysMinRegex):(l(this,"_weekdaysMinRegex")||(this._weekdaysMinRegex=Yb),this._weekdaysMinStrictRegex&&c?this._weekdaysMinStrictRegex:this._weekdaysMinRegex)}function Pc(){function c(bn,$o){return $o.length-bn.length}var h=[],m=[],_=[],I=[],G,de,Te,Be,et;for(G=0;G<7;G++)de=w([2e3,1]).day(G),Te=Vn(this.weekdaysMin(de,"")),Be=Vn(this.weekdaysShort(de,"")),et=Vn(this.weekdays(de,"")),h.push(Te),m.push(Be),_.push(et),I.push(Te),I.push(Be),I.push(et);h.sort(c),m.sort(c),_.sort(c),I.sort(c),this._weekdaysRegex=new RegExp("^("+I.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=new RegExp("^("+_.join("|")+")","i"),this._weekdaysShortStrictRegex=new RegExp("^("+m.join("|")+")","i"),this._weekdaysMinStrictRegex=new RegExp("^("+h.join("|")+")","i")}function Dc(){return this.hours()%12||12}function ow(){return this.hours()||24}j("H",["HH",2],0,"hour"),j("h",["hh",2],0,Dc),j("k",["kk",2],0,ow),j("hmm",0,0,function(){return""+Dc.apply(this)+V(this.minutes(),2)}),j("hmmss",0,0,function(){return""+Dc.apply(this)+V(this.minutes(),2)+V(this.seconds(),2)}),j("Hmm",0,0,function(){return""+this.hours()+V(this.minutes(),2)}),j("Hmmss",0,0,function(){return""+this.hours()+V(this.minutes(),2)+V(this.seconds(),2)});function Fh(c,h){j(c,0,0,function(){return this.localeData().meridiem(this.hours(),this.minutes(),h)})}Fh("a",!0),Fh("A",!1);function Lh(c,h){return h._meridiemParse}Re("a",Lh),Re("A",Lh),Re("H",Ue,Ur),Re("h",Ue,Jt),Re("k",Ue,Jt),Re("HH",Ue,it),Re("hh",Ue,it),Re("kk",Ue,it),Re("hmm",tt),Re("hmmss",Mn),Re("Hmm",tt),Re("Hmmss",Mn),mt(["H","HH"],we),mt(["k","kk"],function(c,h,m){var _=qe(c);h[we]=_===24?0:_}),mt(["a","A"],function(c,h,m){m._isPm=m._locale.isPM(c),m._meridiem=c}),mt(["h","hh"],function(c,h,m){h[we]=qe(c),v(m).bigHour=!0}),mt("hmm",function(c,h,m){var _=c.length-2;h[we]=qe(c.substr(0,_)),h[Ne]=qe(c.substr(_)),v(m).bigHour=!0}),mt("hmmss",function(c,h,m){var _=c.length-4,I=c.length-2;h[we]=qe(c.substr(0,_)),h[Ne]=qe(c.substr(_,2)),h[Ye]=qe(c.substr(I)),v(m).bigHour=!0}),mt("Hmm",function(c,h,m){var _=c.length-2;h[we]=qe(c.substr(0,_)),h[Ne]=qe(c.substr(_))}),mt("Hmmss",function(c,h,m){var _=c.length-4,I=c.length-2;h[we]=qe(c.substr(0,_)),h[Ne]=qe(c.substr(_,2)),h[Ye]=qe(c.substr(I))});function rw(c){return(c+"").toLowerCase().charAt(0)==="p"}var sw=/[ap]\.?m?\.?/i,iw=en("Hours",!0);function aw(c,h,m){return c>11?m?"pm":"PM":m?"am":"AM"}var $h={calendar:A,longDateFormat:ie,invalidDate:W,ordinal:Q,dayOfMonthOrdinalParse:fe,relativeTime:Ce,months:Sb,monthsShort:Ph,week:Nb,weekdays:Bb,weekdaysMin:Wb,weekdaysShort:Ah,meridiemParse:sw},Ft={},Us={},qs;function lw(c,h){var m,_=Math.min(c.length,h.length);for(m=0;m<_;m+=1)if(c[m]!==h[m])return m;return _}function Vh(c){return c&&c.toLowerCase().replace("_","-")}function cw(c){for(var h=0,m,_,I,G;h<c.length;){for(G=Vh(c[h]).split("-"),m=G.length,_=Vh(c[h+1]),_=_?_.split("-"):null;m>0;){if(I=Ca(G.slice(0,m).join("-")),I)return I;if(_&&_.length>=m&&lw(G,_)>=m-1)break;m--}h++}return qs}function dw(c){return!!(c&&c.match("^[^/\\\\]*$"))}function Ca(c){var h=null,m;if(Ft[c]===void 0&&e&&e.exports&&dw(c))try{h=qs._abbr,m=_A,m("./locale/"+c),sr(h)}catch{Ft[c]=null}return Ft[c]}function sr(c,h){var m;return c&&(u(h)?m=No(c):m=Oc(c,h),m?qs=m:typeof console<"u"&&console.warn&&console.warn("Locale "+c+" not found. Did you forget to load it?")),qs._abbr}function Oc(c,h){if(h!==null){var m,_=$h;if(h.abbr=c,Ft[c]!=null)K("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."),_=Ft[c]._config;else if(h.parentLocale!=null)if(Ft[h.parentLocale]!=null)_=Ft[h.parentLocale]._config;else if(m=Ca(h.parentLocale),m!=null)_=m._config;else return Us[h.parentLocale]||(Us[h.parentLocale]=[]),Us[h.parentLocale].push({name:c,config:h}),null;return Ft[c]=new H(Y(_,h)),Us[c]&&Us[c].forEach(function(I){Oc(I.name,I.config)}),sr(c),Ft[c]}else return delete Ft[c],null}function uw(c,h){if(h!=null){var m,_,I=$h;Ft[c]!=null&&Ft[c].parentLocale!=null?Ft[c].set(Y(Ft[c]._config,h)):(_=Ca(c),_!=null&&(I=_._config),h=Y(I,h),_==null&&(h.abbr=c),m=new H(h),m.parentLocale=Ft[c],Ft[c]=m),sr(c)}else Ft[c]!=null&&(Ft[c].parentLocale!=null?(Ft[c]=Ft[c].parentLocale,c===sr()&&sr(c)):Ft[c]!=null&&delete Ft[c]);return Ft[c]}function No(c){var h;if(c&&c._locale&&c._locale._abbr&&(c=c._locale._abbr),!c)return qs;if(!i(c)){if(h=Ca(c),h)return h;c=[c]}return cw(c)}function hw(){return le(Ft)}function Mc(c){var h,m=c._a;return m&&v(c).overflow===-2&&(h=m[U]<0||m[U]>11?U:m[pe]<1||m[pe]>Tc(m[rn],m[U])?pe:m[we]<0||m[we]>24||m[we]===24&&(m[Ne]!==0||m[Ye]!==0||m[Je]!==0)?we:m[Ne]<0||m[Ne]>59?Ne:m[Ye]<0||m[Ye]>59?Ye:m[Je]<0||m[Je]>999?Je:-1,v(c)._overflowDayOfYear&&(h<rn||h>pe)&&(h=pe),v(c)._overflowWeeks&&h===-1&&(h=Ze),v(c)._overflowWeekday&&h===-1&&(h=Ge),v(c).overflow=h),c}var fw=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,pw=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d|))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,mw=/Z|[+-]\d\d(?::?\d\d)?/,Sa=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/],["YYYYMM",/\d{6}/,!1],["YYYY",/\d{4}/,!1]],Ic=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],gw=/^\/?Date\((-?\d+)/i,yw=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/,vw={UT:0,GMT:0,EDT:-4*60,EST:-5*60,CDT:-5*60,CST:-6*60,MDT:-6*60,MST:-7*60,PDT:-7*60,PST:-8*60};function jh(c){var h,m,_=c._i,I=fw.exec(_)||pw.exec(_),G,de,Te,Be,et=Sa.length,bn=Ic.length;if(I){for(v(c).iso=!0,h=0,m=et;h<m;h++)if(Sa[h][1].exec(I[1])){de=Sa[h][0],G=Sa[h][2]!==!1;break}if(de==null){c._isValid=!1;return}if(I[3]){for(h=0,m=bn;h<m;h++)if(Ic[h][1].exec(I[3])){Te=(I[2]||" ")+Ic[h][0];break}if(Te==null){c._isValid=!1;return}}if(!G&&Te!=null){c._isValid=!1;return}if(I[4])if(mw.exec(I[4]))Be="Z";else{c._isValid=!1;return}c._f=de+(Te||"")+(Be||""),Ac(c)}else c._isValid=!1}function bw(c,h,m,_,I,G){var de=[ww(c),Ph.indexOf(h),parseInt(m,10),parseInt(_,10),parseInt(I,10)];return G&&de.push(parseInt(G,10)),de}function ww(c){var h=parseInt(c,10);return h<=49?2e3+h:h<=999?1900+h:h}function Cw(c){return c.replace(/\([^()]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").replace(/^\s\s*/,"").replace(/\s\s*$/,"")}function Sw(c,h,m){if(c){var _=Ah.indexOf(c),I=new Date(h[0],h[1],h[2]).getDay();if(_!==I)return v(m).weekdayMismatch=!0,m._isValid=!1,!1}return!0}function _w(c,h,m){if(c)return vw[c];if(h)return 0;var _=parseInt(m,10),I=_%100,G=(_-I)/100;return G*60+I}function Bh(c){var h=yw.exec(Cw(c._i)),m;if(h){if(m=bw(h[4],h[3],h[2],h[5],h[6],h[7]),!Sw(h[1],m,c))return;c._a=m,c._tzm=_w(h[8],h[9],h[10]),c._d=zs.apply(null,c._a),c._d.setUTCMinutes(c._d.getUTCMinutes()-c._tzm),v(c).rfc2822=!0}else c._isValid=!1}function xw(c){var h=gw.exec(c._i);if(h!==null){c._d=new Date(+h[1]);return}if(jh(c),c._isValid===!1)delete c._isValid;else return;if(Bh(c),c._isValid===!1)delete c._isValid;else return;c._strict?c._isValid=!1:o.createFromInputFallback(c)}o.createFromInputFallback=R("value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are discouraged. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.",function(c){c._d=new Date(c._i+(c._useUTC?" UTC":""))});function Xr(c,h,m){return c??h??m}function Rw(c){var h=new Date(o.now());return c._useUTC?[h.getUTCFullYear(),h.getUTCMonth(),h.getUTCDate()]:[h.getFullYear(),h.getMonth(),h.getDate()]}function Nc(c){var h,m,_=[],I,G,de;if(!c._d){for(I=Rw(c),c._w&&c._a[pe]==null&&c._a[U]==null&&kw(c),c._dayOfYear!=null&&(de=Xr(c._a[rn],I[rn]),(c._dayOfYear>Ut(de)||c._dayOfYear===0)&&(v(c)._overflowDayOfYear=!0),m=zs(de,0,c._dayOfYear),c._a[U]=m.getUTCMonth(),c._a[pe]=m.getUTCDate()),h=0;h<3&&c._a[h]==null;++h)c._a[h]=_[h]=I[h];for(;h<7;h++)c._a[h]=_[h]=c._a[h]==null?h===2?1:0:c._a[h];c._a[we]===24&&c._a[Ne]===0&&c._a[Ye]===0&&c._a[Je]===0&&(c._nextDay=!0,c._a[we]=0),c._d=(c._useUTC?zs:Mb).apply(null,_),G=c._useUTC?c._d.getUTCDay():c._d.getDay(),c._tzm!=null&&c._d.setUTCMinutes(c._d.getUTCMinutes()-c._tzm),c._nextDay&&(c._a[we]=24),c._w&&typeof c._w.d<"u"&&c._w.d!==G&&(v(c).weekdayMismatch=!0)}}function kw(c){var h,m,_,I,G,de,Te,Be,et;h=c._w,h.GG!=null||h.W!=null||h.E!=null?(G=1,de=4,m=Xr(h.GG,c._a[rn],Ys(Dt(),1,4).year),_=Xr(h.W,1),I=Xr(h.E,1),(I<1||I>7)&&(Be=!0)):(G=c._locale._week.dow,de=c._locale._week.doy,et=Ys(Dt(),G,de),m=Xr(h.gg,c._a[rn],et.year),_=Xr(h.w,et.week),h.d!=null?(I=h.d,(I<0||I>6)&&(Be=!0)):h.e!=null?(I=h.e+G,(h.e<0||h.e>6)&&(Be=!0)):I=G),_<1||_>Io(m,G,de)?v(c)._overflowWeeks=!0:Be!=null?v(c)._overflowWeekday=!0:(Te=Nh(m,_,I,G,de),c._a[rn]=Te.year,c._dayOfYear=Te.dayOfYear)}o.ISO_8601=function(){},o.RFC_2822=function(){};function Ac(c){if(c._f===o.ISO_8601){jh(c);return}if(c._f===o.RFC_2822){Bh(c);return}c._a=[],v(c).empty=!0;var h=""+c._i,m,_,I,G,de,Te=h.length,Be=0,et,bn;for(I=ce(c._f,c._locale).match(B)||[],bn=I.length,m=0;m<bn;m++)G=I[m],_=(h.match(xc(G,c))||[])[0],_&&(de=h.substr(0,h.indexOf(_)),de.length>0&&v(c).unusedInput.push(de),h=h.slice(h.indexOf(_)+_.length),Be+=_.length),se[G]?(_?v(c).empty=!1:v(c).unusedTokens.push(G),Rc(G,_,c)):c._strict&&!_&&v(c).unusedTokens.push(G);v(c).charsLeftOver=Te-Be,h.length>0&&v(c).unusedInput.push(h),c._a[we]<=12&&v(c).bigHour===!0&&c._a[we]>0&&(v(c).bigHour=void 0),v(c).parsedDateParts=c._a.slice(0),v(c).meridiem=c._meridiem,c._a[we]=Tw(c._locale,c._a[we],c._meridiem),et=v(c).era,et!==null&&(c._a[rn]=c._locale.erasConvertYear(et,c._a[rn])),Nc(c),Mc(c)}function Tw(c,h,m){var _;return m==null?h:c.meridiemHour!=null?c.meridiemHour(h,m):(c.isPM!=null&&(_=c.isPM(m),_&&h<12&&(h+=12),!_&&h===12&&(h=0)),h)}function Ew(c){var h,m,_,I,G,de,Te=!1,Be=c._f.length;if(Be===0){v(c).invalidFormat=!0,c._d=new Date(NaN);return}for(I=0;I<Be;I++)G=0,de=!1,h=O({},c),c._useUTC!=null&&(h._useUTC=c._useUTC),h._f=c._f[I],Ac(h),P(h)&&(de=!0),G+=v(h).charsLeftOver,G+=v(h).unusedTokens.length*10,v(h).score=G,Te?G<_&&(_=G,m=h):(_==null||G<_||de)&&(_=G,m=h,de&&(Te=!0));b(c,m||h)}function Pw(c){if(!c._d){var h=st(c._i),m=h.day===void 0?h.date:h.day;c._a=y([h.year,h.month,m,h.hour,h.minute,h.second,h.millisecond],function(_){return _&&parseInt(_,10)}),Nc(c)}}function Dw(c){var h=new N(Mc(Wh(c)));return h._nextDay&&(h.add(1,"d"),h._nextDay=void 0),h}function Wh(c){var h=c._i,m=c._f;return c._locale=c._locale||No(c._l),h===null||m===void 0&&h===""?x({nullInput:!0}):(typeof h=="string"&&(c._i=h=c._locale.preparse(h)),F(h)?new N(Mc(h)):(p(h)?c._d=h:i(m)?Ew(c):m?Ac(c):Ow(c),P(c)||(c._d=null),c))}function Ow(c){var h=c._i;u(h)?c._d=new Date(o.now()):p(h)?c._d=new Date(h.valueOf()):typeof h=="string"?xw(c):i(h)?(c._a=y(h.slice(0),function(m){return parseInt(m,10)}),Nc(c)):a(h)?Pw(c):f(h)?c._d=new Date(h):o.createFromInputFallback(c)}function Hh(c,h,m,_,I){var G={};return(h===!0||h===!1)&&(_=h,h=void 0),(m===!0||m===!1)&&(_=m,m=void 0),(a(c)&&d(c)||i(c)&&c.length===0)&&(c=void 0),G._isAMomentObject=!0,G._useUTC=G._isUTC=I,G._l=m,G._i=c,G._f=h,G._strict=_,Dw(G)}function Dt(c,h,m,_){return Hh(c,h,m,_,!1)}var Mw=R("moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var c=Dt.apply(null,arguments);return this.isValid()&&c.isValid()?c<this?this:c:x()}),Iw=R("moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var c=Dt.apply(null,arguments);return this.isValid()&&c.isValid()?c>this?this:c:x()});function zh(c,h){var m,_;if(h.length===1&&i(h[0])&&(h=h[0]),!h.length)return Dt();for(m=h[0],_=1;_<h.length;++_)(!h[_].isValid()||h[_][c](m))&&(m=h[_]);return m}function Nw(){var c=[].slice.call(arguments,0);return zh("isBefore",c)}function Aw(){var c=[].slice.call(arguments,0);return zh("isAfter",c)}var Fw=function(){return Date.now?Date.now():+new Date},Gs=["year","quarter","month","week","day","hour","minute","second","millisecond"];function Lw(c){var h,m=!1,_,I=Gs.length;for(h in c)if(l(c,h)&&!(Vt.call(Gs,h)!==-1&&(c[h]==null||!isNaN(c[h]))))return!1;for(_=0;_<I;++_)if(c[Gs[_]]){if(m)return!1;parseFloat(c[Gs[_]])!==qe(c[Gs[_]])&&(m=!0)}return!0}function $w(){return this._isValid}function Vw(){return to(NaN)}function _a(c){var h=st(c),m=h.year||0,_=h.quarter||0,I=h.month||0,G=h.week||h.isoWeek||0,de=h.day||0,Te=h.hour||0,Be=h.minute||0,et=h.second||0,bn=h.millisecond||0;this._isValid=Lw(h),this._milliseconds=+bn+et*1e3+Be*6e4+Te*1e3*60*60,this._days=+de+G*7,this._months=+I+_*3+m*12,this._data={},this._locale=No(),this._bubble()}function xa(c){return c instanceof _a}function Fc(c){return c<0?Math.round(-1*c)*-1:Math.round(c)}function jw(c,h,m){var _=Math.min(c.length,h.length),I=Math.abs(c.length-h.length),G=0,de;for(de=0;de<_;de++)qe(c[de])!==qe(h[de])&&G++;return G+I}function Yh(c,h){j(c,0,0,function(){var m=this.utcOffset(),_="+";return m<0&&(m=-m,_="-"),_+V(~~(m/60),2)+h+V(~~m%60,2)})}Yh("Z",":"),Yh("ZZ",""),Re("Z",pt),Re("ZZ",pt),mt(["Z","ZZ"],function(c,h,m){m._useUTC=!0,m._tzm=Lc(pt,c)});var Bw=/([\+\-]|\d\d)/gi;function Lc(c,h){var m=(h||"").match(c),_,I,G;return m===null?null:(_=m[m.length-1]||[],I=(_+"").match(Bw)||["-",0,0],G=+(I[1]*60)+qe(I[2]),G===0?0:I[0]==="+"?G:-G)}function $c(c,h){var m,_;return h._isUTC?(m=h.clone(),_=(F(c)||p(c)?c.valueOf():Dt(c).valueOf())-m.valueOf(),m._d.setTime(m._d.valueOf()+_),o.updateOffset(m,!1),m):Dt(c).local()}function Vc(c){return-Math.round(c._d.getTimezoneOffset())}o.updateOffset=function(){};function Ww(c,h,m){var _=this._offset||0,I;if(!this.isValid())return c!=null?this:NaN;if(c!=null){if(typeof c=="string"){if(c=Lc(pt,c),c===null)return this}else Math.abs(c)<16&&!m&&(c=c*60);return!this._isUTC&&h&&(I=Vc(this)),this._offset=c,this._isUTC=!0,I!=null&&this.add(I,"m"),_!==c&&(!h||this._changeInProgress?Kh(this,to(c-_,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,o.updateOffset(this,!0),this._changeInProgress=null)),this}else return this._isUTC?_:Vc(this)}function Hw(c,h){return c!=null?(typeof c!="string"&&(c=-c),this.utcOffset(c,h),this):-this.utcOffset()}function zw(c){return this.utcOffset(0,c)}function Yw(c){return this._isUTC&&(this.utcOffset(0,c),this._isUTC=!1,c&&this.subtract(Vc(this),"m")),this}function Uw(){if(this._tzm!=null)this.utcOffset(this._tzm,!1,!0);else if(typeof this._i=="string"){var c=Lc(ho,this._i);c!=null?this.utcOffset(c):this.utcOffset(0,!0)}return this}function qw(c){return this.isValid()?(c=c?Dt(c).utcOffset():0,(this.utcOffset()-c)%60===0):!1}function Gw(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()}function Kw(){if(!u(this._isDSTShifted))return this._isDSTShifted;var c={},h;return O(c,this),c=Wh(c),c._a?(h=c._isUTC?w(c._a):Dt(c._a),this._isDSTShifted=this.isValid()&&jw(c._a,h.toArray())>0):this._isDSTShifted=!1,this._isDSTShifted}function Xw(){return this.isValid()?!this._isUTC:!1}function Zw(){return this.isValid()?this._isUTC:!1}function Uh(){return this.isValid()?this._isUTC&&this._offset===0:!1}var Qw=/^(-|\+)?(?:(\d*)[. ])?(\d+):(\d+)(?::(\d+)(\.\d*)?)?$/,Jw=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;function to(c,h){var m=c,_=null,I,G,de;return xa(c)?m={ms:c._milliseconds,d:c._days,M:c._months}:f(c)||!isNaN(+c)?(m={},h?m[h]=+c:m.milliseconds=+c):(_=Qw.exec(c))?(I=_[1]==="-"?-1:1,m={y:0,d:qe(_[pe])*I,h:qe(_[we])*I,m:qe(_[Ne])*I,s:qe(_[Ye])*I,ms:qe(Fc(_[Je]*1e3))*I}):(_=Jw.exec(c))?(I=_[1]==="-"?-1:1,m={y:Cr(_[2],I),M:Cr(_[3],I),w:Cr(_[4],I),d:Cr(_[5],I),h:Cr(_[6],I),m:Cr(_[7],I),s:Cr(_[8],I)}):m==null?m={}:typeof m=="object"&&("from"in m||"to"in m)&&(de=eC(Dt(m.from),Dt(m.to)),m={},m.ms=de.milliseconds,m.M=de.months),G=new _a(m),xa(c)&&l(c,"_locale")&&(G._locale=c._locale),xa(c)&&l(c,"_isValid")&&(G._isValid=c._isValid),G}to.fn=_a.prototype,to.invalid=Vw;function Cr(c,h){var m=c&&parseFloat(c.replace(",","."));return(isNaN(m)?0:m)*h}function qh(c,h){var m={};return m.months=h.month()-c.month()+(h.year()-c.year())*12,c.clone().add(m.months,"M").isAfter(h)&&--m.months,m.milliseconds=+h-+c.clone().add(m.months,"M"),m}function eC(c,h){var m;return c.isValid()&&h.isValid()?(h=$c(h,c),c.isBefore(h)?m=qh(c,h):(m=qh(h,c),m.milliseconds=-m.milliseconds,m.months=-m.months),m):{milliseconds:0,months:0}}function Gh(c,h){return function(m,_){var I,G;return _!==null&&!isNaN(+_)&&(K(h,"moment()."+h+"(period, number) is deprecated. Please use moment()."+h+"(number, period). See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info."),G=m,m=_,_=G),I=to(m,_),Kh(this,I,c),this}}function Kh(c,h,m,_){var I=h._milliseconds,G=Fc(h._days),de=Fc(h._months);c.isValid()&&(_=_??!0,de&&Oh(c,jn(c,"Month")+de*m),G&&fo(c,"Date",jn(c,"Date")+G*m),I&&c._d.setTime(c._d.valueOf()+I*m),_&&o.updateOffset(c,G||de))}var tC=Gh(1,"add"),nC=Gh(-1,"subtract");function Xh(c){return typeof c=="string"||c instanceof String}function oC(c){return F(c)||p(c)||Xh(c)||f(c)||sC(c)||rC(c)||c===null||c===void 0}function rC(c){var h=a(c)&&!d(c),m=!1,_=["years","year","y","months","month","M","days","day","d","dates","date","D","hours","hour","h","minutes","minute","m","seconds","second","s","milliseconds","millisecond","ms"],I,G,de=_.length;for(I=0;I<de;I+=1)G=_[I],m=m||l(c,G);return h&&m}function sC(c){var h=i(c),m=!1;return h&&(m=c.filter(function(_){return!f(_)&&Xh(c)}).length===0),h&&m}function iC(c){var h=a(c)&&!d(c),m=!1,_=["sameDay","nextDay","lastDay","nextWeek","lastWeek","sameElse"],I,G;for(I=0;I<_.length;I+=1)G=_[I],m=m||l(c,G);return h&&m}function aC(c,h){var m=c.diff(h,"days",!0);return m<-6?"sameElse":m<-1?"lastWeek":m<0?"lastDay":m<1?"sameDay":m<2?"nextDay":m<7?"nextWeek":"sameElse"}function lC(c,h){arguments.length===1&&(arguments[0]?oC(arguments[0])?(c=arguments[0],h=void 0):iC(arguments[0])&&(h=arguments[0],c=void 0):(c=void 0,h=void 0));var m=c||Dt(),_=$c(m,this).startOf("day"),I=o.calendarFormat(this,_)||"sameElse",G=h&&(X(h[I])?h[I].call(this,m):h[I]);return this.format(G||this.localeData().calendar(I,this,Dt(m)))}function cC(){return new N(this)}function dC(c,h){var m=F(c)?c:Dt(c);return this.isValid()&&m.isValid()?(h=Ae(h)||"millisecond",h==="millisecond"?this.valueOf()>m.valueOf():m.valueOf()<this.clone().startOf(h).valueOf()):!1}function uC(c,h){var m=F(c)?c:Dt(c);return this.isValid()&&m.isValid()?(h=Ae(h)||"millisecond",h==="millisecond"?this.valueOf()<m.valueOf():this.clone().endOf(h).valueOf()<m.valueOf()):!1}function hC(c,h,m,_){var I=F(c)?c:Dt(c),G=F(h)?h:Dt(h);return this.isValid()&&I.isValid()&&G.isValid()?(_=_||"()",(_[0]==="("?this.isAfter(I,m):!this.isBefore(I,m))&&(_[1]===")"?this.isBefore(G,m):!this.isAfter(G,m))):!1}function fC(c,h){var m=F(c)?c:Dt(c),_;return this.isValid()&&m.isValid()?(h=Ae(h)||"millisecond",h==="millisecond"?this.valueOf()===m.valueOf():(_=m.valueOf(),this.clone().startOf(h).valueOf()<=_&&_<=this.clone().endOf(h).valueOf())):!1}function pC(c,h){return this.isSame(c,h)||this.isAfter(c,h)}function mC(c,h){return this.isSame(c,h)||this.isBefore(c,h)}function gC(c,h,m){var _,I,G;if(!this.isValid())return NaN;if(_=$c(c,this),!_.isValid())return NaN;switch(I=(_.utcOffset()-this.utcOffset())*6e4,h=Ae(h),h){case"year":G=Ra(this,_)/12;break;case"month":G=Ra(this,_);break;case"quarter":G=Ra(this,_)/3;break;case"second":G=(this-_)/1e3;break;case"minute":G=(this-_)/6e4;break;case"hour":G=(this-_)/36e5;break;case"day":G=(this-_-I)/864e5;break;case"week":G=(this-_-I)/6048e5;break;default:G=this-_}return m?G:Sn(G)}function Ra(c,h){if(c.date()<h.date())return-Ra(h,c);var m=(h.year()-c.year())*12+(h.month()-c.month()),_=c.clone().add(m,"months"),I,G;return h-_<0?(I=c.clone().add(m-1,"months"),G=(h-_)/(_-I)):(I=c.clone().add(m+1,"months"),G=(h-_)/(I-_)),-(m+G)||0}o.defaultFormat="YYYY-MM-DDTHH:mm:ssZ",o.defaultFormatUtc="YYYY-MM-DDTHH:mm:ss[Z]";function yC(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")}function vC(c){if(!this.isValid())return null;var h=c!==!0,m=h?this.clone().utc():this;return m.year()<0||m.year()>9999?te(m,h?"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYYYY-MM-DD[T]HH:mm:ss.SSSZ"):X(Date.prototype.toISOString)?h?this.toDate().toISOString():new Date(this.valueOf()+this.utcOffset()*60*1e3).toISOString().replace("Z",te(m,"Z")):te(m,h?"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYY-MM-DD[T]HH:mm:ss.SSSZ")}function bC(){if(!this.isValid())return"moment.invalid(/* "+this._i+" */)";var c="moment",h="",m,_,I,G;return this.isLocal()||(c=this.utcOffset()===0?"moment.utc":"moment.parseZone",h="Z"),m="["+c+'("]',_=0<=this.year()&&this.year()<=9999?"YYYY":"YYYYYY",I="-MM-DD[T]HH:mm:ss.SSS",G=h+'[")]',this.format(m+_+I+G)}function wC(c){c||(c=this.isUtc()?o.defaultFormatUtc:o.defaultFormat);var h=te(this,c);return this.localeData().postformat(h)}function CC(c,h){return this.isValid()&&(F(c)&&c.isValid()||Dt(c).isValid())?to({to:this,from:c}).locale(this.locale()).humanize(!h):this.localeData().invalidDate()}function SC(c){return this.from(Dt(),c)}function _C(c,h){return this.isValid()&&(F(c)&&c.isValid()||Dt(c).isValid())?to({from:this,to:c}).locale(this.locale()).humanize(!h):this.localeData().invalidDate()}function xC(c){return this.to(Dt(),c)}function Zh(c){var h;return c===void 0?this._locale._abbr:(h=No(c),h!=null&&(this._locale=h),this)}var Qh=R("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(c){return c===void 0?this.localeData():this.locale(c)});function Jh(){return this._locale}var ka=1e3,Zr=60*ka,Ta=60*Zr,ef=(365*400+97)*24*Ta;function Qr(c,h){return(c%h+h)%h}function tf(c,h,m){return c<100&&c>=0?new Date(c+400,h,m)-ef:new Date(c,h,m).valueOf()}function nf(c,h,m){return c<100&&c>=0?Date.UTC(c+400,h,m)-ef:Date.UTC(c,h,m)}function RC(c){var h,m;if(c=Ae(c),c===void 0||c==="millisecond"||!this.isValid())return this;switch(m=this._isUTC?nf:tf,c){case"year":h=m(this.year(),0,1);break;case"quarter":h=m(this.year(),this.month()-this.month()%3,1);break;case"month":h=m(this.year(),this.month(),1);break;case"week":h=m(this.year(),this.month(),this.date()-this.weekday());break;case"isoWeek":h=m(this.year(),this.month(),this.date()-(this.isoWeekday()-1));break;case"day":case"date":h=m(this.year(),this.month(),this.date());break;case"hour":h=this._d.valueOf(),h-=Qr(h+(this._isUTC?0:this.utcOffset()*Zr),Ta);break;case"minute":h=this._d.valueOf(),h-=Qr(h,Zr);break;case"second":h=this._d.valueOf(),h-=Qr(h,ka);break}return this._d.setTime(h),o.updateOffset(this,!0),this}function kC(c){var h,m;if(c=Ae(c),c===void 0||c==="millisecond"||!this.isValid())return this;switch(m=this._isUTC?nf:tf,c){case"year":h=m(this.year()+1,0,1)-1;break;case"quarter":h=m(this.year(),this.month()-this.month()%3+3,1)-1;break;case"month":h=m(this.year(),this.month()+1,1)-1;break;case"week":h=m(this.year(),this.month(),this.date()-this.weekday()+7)-1;break;case"isoWeek":h=m(this.year(),this.month(),this.date()-(this.isoWeekday()-1)+7)-1;break;case"day":case"date":h=m(this.year(),this.month(),this.date()+1)-1;break;case"hour":h=this._d.valueOf(),h+=Ta-Qr(h+(this._isUTC?0:this.utcOffset()*Zr),Ta)-1;break;case"minute":h=this._d.valueOf(),h+=Zr-Qr(h,Zr)-1;break;case"second":h=this._d.valueOf(),h+=ka-Qr(h,ka)-1;break}return this._d.setTime(h),o.updateOffset(this,!0),this}function TC(){return this._d.valueOf()-(this._offset||0)*6e4}function EC(){return Math.floor(this.valueOf()/1e3)}function PC(){return new Date(this.valueOf())}function DC(){var c=this;return[c.year(),c.month(),c.date(),c.hour(),c.minute(),c.second(),c.millisecond()]}function OC(){var c=this;return{years:c.year(),months:c.month(),date:c.date(),hours:c.hours(),minutes:c.minutes(),seconds:c.seconds(),milliseconds:c.milliseconds()}}function MC(){return this.isValid()?this.toISOString():null}function IC(){return P(this)}function NC(){return b({},v(this))}function AC(){return v(this).overflow}function FC(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}}j("N",0,0,"eraAbbr"),j("NN",0,0,"eraAbbr"),j("NNN",0,0,"eraAbbr"),j("NNNN",0,0,"eraName"),j("NNNNN",0,0,"eraNarrow"),j("y",["y",1],"yo","eraYear"),j("y",["yy",2],0,"eraYear"),j("y",["yyy",3],0,"eraYear"),j("y",["yyyy",4],0,"eraYear"),Re("N",jc),Re("NN",jc),Re("NNN",jc),Re("NNNN",qC),Re("NNNNN",GC),mt(["N","NN","NNN","NNNN","NNNNN"],function(c,h,m,_){var I=m._locale.erasParse(c,_,m._strict);I?v(m).era=I:v(m).invalidEra=c}),Re("y",vt),Re("yy",vt),Re("yyy",vt),Re("yyyy",vt),Re("yo",KC),mt(["y","yy","yyy","yyyy"],rn),mt(["yo"],function(c,h,m,_){var I;m._locale._eraYearOrdinalRegex&&(I=c.match(m._locale._eraYearOrdinalRegex)),m._locale.eraYearOrdinalParse?h[rn]=m._locale.eraYearOrdinalParse(c,I):h[rn]=parseInt(c,10)});function LC(c,h){var m,_,I,G=this._eras||No("en")._eras;for(m=0,_=G.length;m<_;++m){switch(typeof G[m].since){case"string":I=o(G[m].since).startOf("day"),G[m].since=I.valueOf();break}switch(typeof G[m].until){case"undefined":G[m].until=1/0;break;case"string":I=o(G[m].until).startOf("day").valueOf(),G[m].until=I.valueOf();break}}return G}function $C(c,h,m){var _,I,G=this.eras(),de,Te,Be;for(c=c.toUpperCase(),_=0,I=G.length;_<I;++_)if(de=G[_].name.toUpperCase(),Te=G[_].abbr.toUpperCase(),Be=G[_].narrow.toUpperCase(),m)switch(h){case"N":case"NN":case"NNN":if(Te===c)return G[_];break;case"NNNN":if(de===c)return G[_];break;case"NNNNN":if(Be===c)return G[_];break}else if([de,Te,Be].indexOf(c)>=0)return G[_]}function VC(c,h){var m=c.since<=c.until?1:-1;return h===void 0?o(c.since).year():o(c.since).year()+(h-c.offset)*m}function jC(){var c,h,m,_=this.localeData().eras();for(c=0,h=_.length;c<h;++c)if(m=this.clone().startOf("day").valueOf(),_[c].since<=m&&m<=_[c].until||_[c].until<=m&&m<=_[c].since)return _[c].name;return""}function BC(){var c,h,m,_=this.localeData().eras();for(c=0,h=_.length;c<h;++c)if(m=this.clone().startOf("day").valueOf(),_[c].since<=m&&m<=_[c].until||_[c].until<=m&&m<=_[c].since)return _[c].narrow;return""}function WC(){var c,h,m,_=this.localeData().eras();for(c=0,h=_.length;c<h;++c)if(m=this.clone().startOf("day").valueOf(),_[c].since<=m&&m<=_[c].until||_[c].until<=m&&m<=_[c].since)return _[c].abbr;return""}function HC(){var c,h,m,_,I=this.localeData().eras();for(c=0,h=I.length;c<h;++c)if(m=I[c].since<=I[c].until?1:-1,_=this.clone().startOf("day").valueOf(),I[c].since<=_&&_<=I[c].until||I[c].until<=_&&_<=I[c].since)return(this.year()-o(I[c].since).year())*m+I[c].offset;return this.year()}function zC(c){return l(this,"_erasNameRegex")||Bc.call(this),c?this._erasNameRegex:this._erasRegex}function YC(c){return l(this,"_erasAbbrRegex")||Bc.call(this),c?this._erasAbbrRegex:this._erasRegex}function UC(c){return l(this,"_erasNarrowRegex")||Bc.call(this),c?this._erasNarrowRegex:this._erasRegex}function jc(c,h){return h.erasAbbrRegex(c)}function qC(c,h){return h.erasNameRegex(c)}function GC(c,h){return h.erasNarrowRegex(c)}function KC(c,h){return h._eraYearOrdinalRegex||vt}function Bc(){var c=[],h=[],m=[],_=[],I,G,de,Te,Be,et=this.eras();for(I=0,G=et.length;I<G;++I)de=Vn(et[I].name),Te=Vn(et[I].abbr),Be=Vn(et[I].narrow),h.push(de),c.push(Te),m.push(Be),_.push(de),_.push(Te),_.push(Be);this._erasRegex=new RegExp("^("+_.join("|")+")","i"),this._erasNameRegex=new RegExp("^("+h.join("|")+")","i"),this._erasAbbrRegex=new RegExp("^("+c.join("|")+")","i"),this._erasNarrowRegex=new RegExp("^("+m.join("|")+")","i")}j(0,["gg",2],0,function(){return this.weekYear()%100}),j(0,["GG",2],0,function(){return this.isoWeekYear()%100});function Ea(c,h){j(0,[c,c.length],0,h)}Ea("gggg","weekYear"),Ea("ggggg","weekYear"),Ea("GGGG","isoWeekYear"),Ea("GGGGG","isoWeekYear"),Re("G",ln),Re("g",ln),Re("GG",Ue,it),Re("gg",Ue,it),Re("GGGG",Ie,Xt),Re("gggg",Ie,Xt),Re("GGGGG",He,on),Re("ggggg",He,on),wr(["gggg","ggggg","GGGG","GGGGG"],function(c,h,m,_){h[_.substr(0,2)]=qe(c)}),wr(["gg","GG"],function(c,h,m,_){h[_]=o.parseTwoDigitYear(c)});function XC(c){return of.call(this,c,this.week(),this.weekday()+this.localeData()._week.dow,this.localeData()._week.dow,this.localeData()._week.doy)}function ZC(c){return of.call(this,c,this.isoWeek(),this.isoWeekday(),1,4)}function QC(){return Io(this.year(),1,4)}function JC(){return Io(this.isoWeekYear(),1,4)}function eS(){var c=this.localeData()._week;return Io(this.year(),c.dow,c.doy)}function tS(){var c=this.localeData()._week;return Io(this.weekYear(),c.dow,c.doy)}function of(c,h,m,_,I){var G;return c==null?Ys(this,_,I).year:(G=Io(c,_,I),h>G&&(h=G),nS.call(this,c,h,m,_,I))}function nS(c,h,m,_,I){var G=Nh(c,h,m,_,I),de=zs(G.year,0,G.dayOfYear);return this.year(de.getUTCFullYear()),this.month(de.getUTCMonth()),this.date(de.getUTCDate()),this}j("Q",0,"Qo","quarter"),Re("Q",Kt),mt("Q",function(c,h){h[U]=(qe(c)-1)*3});function oS(c){return c==null?Math.ceil((this.month()+1)/3):this.month((c-1)*3+this.month()%3)}j("D",["DD",2],"Do","date"),Re("D",Ue,Jt),Re("DD",Ue,it),Re("Do",function(c,h){return c?h._dayOfMonthOrdinalParse||h._ordinalParse:h._dayOfMonthOrdinalParseLenient}),mt(["D","DD"],pe),mt("Do",function(c,h){h[pe]=qe(c.match(Ue)[0])});var rf=en("Date",!0);j("DDD",["DDDD",3],"DDDo","dayOfYear"),Re("DDD",hn),Re("DDDD",Yt),mt(["DDD","DDDD"],function(c,h,m){m._dayOfYear=qe(c)});function rS(c){var h=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return c==null?h:this.add(c-h,"d")}j("m",["mm",2],0,"minute"),Re("m",Ue,Ur),Re("mm",Ue,it),mt(["m","mm"],Ne);var sS=en("Minutes",!1);j("s",["ss",2],0,"second"),Re("s",Ue,Ur),Re("ss",Ue,it),mt(["s","ss"],Ye);var iS=en("Seconds",!1);j("S",0,0,function(){return~~(this.millisecond()/100)}),j(0,["SS",2],0,function(){return~~(this.millisecond()/10)}),j(0,["SSS",3],0,"millisecond"),j(0,["SSSS",4],0,function(){return this.millisecond()*10}),j(0,["SSSSS",5],0,function(){return this.millisecond()*100}),j(0,["SSSSSS",6],0,function(){return this.millisecond()*1e3}),j(0,["SSSSSSS",7],0,function(){return this.millisecond()*1e4}),j(0,["SSSSSSSS",8],0,function(){return this.millisecond()*1e5}),j(0,["SSSSSSSSS",9],0,function(){return this.millisecond()*1e6}),Re("S",hn,Kt),Re("SS",hn,it),Re("SSS",hn,Yt);var ir,sf;for(ir="SSSS";ir.length<=9;ir+="S")Re(ir,vt);function aS(c,h){h[Je]=qe(("0."+c)*1e3)}for(ir="S";ir.length<=9;ir+="S")mt(ir,aS);sf=en("Milliseconds",!1),j("z",0,0,"zoneAbbr"),j("zz",0,0,"zoneName");function lS(){return this._isUTC?"UTC":""}function cS(){return this._isUTC?"Coordinated Universal Time":""}var ge=N.prototype;ge.add=tC,ge.calendar=lC,ge.clone=cC,ge.diff=gC,ge.endOf=kC,ge.format=wC,ge.from=CC,ge.fromNow=SC,ge.to=_C,ge.toNow=xC,ge.get=fn,ge.invalidAt=AC,ge.isAfter=dC,ge.isBefore=uC,ge.isBetween=hC,ge.isSame=fC,ge.isSameOrAfter=pC,ge.isSameOrBefore=mC,ge.isValid=IC,ge.lang=Qh,ge.locale=Zh,ge.localeData=Jh,ge.max=Iw,ge.min=Mw,ge.parsingFlags=NC,ge.set=Hs,ge.startOf=RC,ge.subtract=nC,ge.toArray=DC,ge.toObject=OC,ge.toDate=PC,ge.toISOString=vC,ge.inspect=bC,typeof Symbol<"u"&&Symbol.for!=null&&(ge[Symbol.for("nodejs.util.inspect.custom")]=function(){return"Moment<"+this.format()+">"}),ge.toJSON=MC,ge.toString=yC,ge.unix=EC,ge.valueOf=TC,ge.creationData=FC,ge.eraName=jC,ge.eraNarrow=BC,ge.eraAbbr=WC,ge.eraYear=HC,ge.year=At,ge.isLeapYear=Wt,ge.weekYear=XC,ge.isoWeekYear=ZC,ge.quarter=ge.quarters=oS,ge.month=Mh,ge.daysInMonth=Pb,ge.week=ge.weeks=Lb,ge.isoWeek=ge.isoWeeks=$b,ge.weeksInYear=eS,ge.weeksInWeekYear=tS,ge.isoWeeksInYear=QC,ge.isoWeeksInISOWeekYear=JC,ge.date=rf,ge.day=ge.days=Zb,ge.weekday=Qb,ge.isoWeekday=Jb,ge.dayOfYear=rS,ge.hour=ge.hours=iw,ge.minute=ge.minutes=sS,ge.second=ge.seconds=iS,ge.millisecond=ge.milliseconds=sf,ge.utcOffset=Ww,ge.utc=zw,ge.local=Yw,ge.parseZone=Uw,ge.hasAlignedHourOffset=qw,ge.isDST=Gw,ge.isLocal=Xw,ge.isUtcOffset=Zw,ge.isUtc=Uh,ge.isUTC=Uh,ge.zoneAbbr=lS,ge.zoneName=cS,ge.dates=R("dates accessor is deprecated. Use date instead.",rf),ge.months=R("months accessor is deprecated. Use month instead",Mh),ge.years=R("years accessor is deprecated. Use year instead",At),ge.zone=R("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",Hw),ge.isDSTShifted=R("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",Kw);function dS(c){return Dt(c*1e3)}function uS(){return Dt.apply(null,arguments).parseZone()}function af(c){return c}var ct=H.prototype;ct.calendar=M,ct.longDateFormat=he,ct.invalidDate=re,ct.ordinal=me,ct.preparse=af,ct.postformat=af,ct.relativeTime=ve,ct.pastFuture=xe,ct.set=q,ct.eras=LC,ct.erasParse=$C,ct.erasConvertYear=VC,ct.erasAbbrRegex=YC,ct.erasNameRegex=zC,ct.erasNarrowRegex=UC,ct.months=Rb,ct.monthsShort=kb,ct.monthsParse=Eb,ct.monthsRegex=Ob,ct.monthsShortRegex=Db,ct.week=Ib,ct.firstDayOfYear=Fb,ct.firstDayOfWeek=Ab,ct.weekdays=Ub,ct.weekdaysMin=Gb,ct.weekdaysShort=qb,ct.weekdaysParse=Xb,ct.weekdaysRegex=ew,ct.weekdaysShortRegex=tw,ct.weekdaysMinRegex=nw,ct.isPM=rw,ct.meridiem=aw;function Pa(c,h,m,_){var I=No(),G=w().set(_,h);return I[m](G,c)}function lf(c,h,m){if(f(c)&&(h=c,c=void 0),c=c||"",h!=null)return Pa(c,h,m,"month");var _,I=[];for(_=0;_<12;_++)I[_]=Pa(c,_,m,"month");return I}function Wc(c,h,m,_){typeof c=="boolean"?(f(h)&&(m=h,h=void 0),h=h||""):(h=c,m=h,c=!1,f(h)&&(m=h,h=void 0),h=h||"");var I=No(),G=c?I._week.dow:0,de,Te=[];if(m!=null)return Pa(h,(m+G)%7,_,"day");for(de=0;de<7;de++)Te[de]=Pa(h,(de+G)%7,_,"day");return Te}function hS(c,h){return lf(c,h,"months")}function fS(c,h){return lf(c,h,"monthsShort")}function pS(c,h,m){return Wc(c,h,m,"weekdays")}function mS(c,h,m){return Wc(c,h,m,"weekdaysShort")}function gS(c,h,m){return Wc(c,h,m,"weekdaysMin")}sr("en",{eras:[{since:"0001-01-01",until:1/0,offset:1,name:"Anno Domini",narrow:"AD",abbr:"AD"},{since:"0000-12-31",until:-1/0,offset:1,name:"Before Christ",narrow:"BC",abbr:"BC"}],dayOfMonthOrdinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(c){var h=c%10,m=qe(c%100/10)===1?"th":h===1?"st":h===2?"nd":h===3?"rd":"th";return c+m}}),o.lang=R("moment.lang is deprecated. Use moment.locale instead.",sr),o.langData=R("moment.langData is deprecated. Use moment.localeData instead.",No);var Ao=Math.abs;function yS(){var c=this._data;return this._milliseconds=Ao(this._milliseconds),this._days=Ao(this._days),this._months=Ao(this._months),c.milliseconds=Ao(c.milliseconds),c.seconds=Ao(c.seconds),c.minutes=Ao(c.minutes),c.hours=Ao(c.hours),c.months=Ao(c.months),c.years=Ao(c.years),this}function cf(c,h,m,_){var I=to(h,m);return c._milliseconds+=_*I._milliseconds,c._days+=_*I._days,c._months+=_*I._months,c._bubble()}function vS(c,h){return cf(this,c,h,1)}function bS(c,h){return cf(this,c,h,-1)}function df(c){return c<0?Math.floor(c):Math.ceil(c)}function wS(){var c=this._milliseconds,h=this._days,m=this._months,_=this._data,I,G,de,Te,Be;return c>=0&&h>=0&&m>=0||c<=0&&h<=0&&m<=0||(c+=df(Hc(m)+h)*864e5,h=0,m=0),_.milliseconds=c%1e3,I=Sn(c/1e3),_.seconds=I%60,G=Sn(I/60),_.minutes=G%60,de=Sn(G/60),_.hours=de%24,h+=Sn(de/24),Be=Sn(uf(h)),m+=Be,h-=df(Hc(Be)),Te=Sn(m/12),m%=12,_.days=h,_.months=m,_.years=Te,this}function uf(c){return c*4800/146097}function Hc(c){return c*146097/4800}function CS(c){if(!this.isValid())return NaN;var h,m,_=this._milliseconds;if(c=Ae(c),c==="month"||c==="quarter"||c==="year")switch(h=this._days+_/864e5,m=this._months+uf(h),c){case"month":return m;case"quarter":return m/3;case"year":return m/12}else switch(h=this._days+Math.round(Hc(this._months)),c){case"week":return h/7+_/6048e5;case"day":return h+_/864e5;case"hour":return h*24+_/36e5;case"minute":return h*1440+_/6e4;case"second":return h*86400+_/1e3;case"millisecond":return Math.floor(h*864e5)+_;default:throw new Error("Unknown unit "+c)}}function Fo(c){return function(){return this.as(c)}}var hf=Fo("ms"),SS=Fo("s"),_S=Fo("m"),xS=Fo("h"),RS=Fo("d"),kS=Fo("w"),TS=Fo("M"),ES=Fo("Q"),PS=Fo("y"),DS=hf;function OS(){return to(this)}function MS(c){return c=Ae(c),this.isValid()?this[c+"s"]():NaN}function Sr(c){return function(){return this.isValid()?this._data[c]:NaN}}var IS=Sr("milliseconds"),NS=Sr("seconds"),AS=Sr("minutes"),FS=Sr("hours"),LS=Sr("days"),$S=Sr("months"),VS=Sr("years");function jS(){return Sn(this.days()/7)}var Lo=Math.round,Jr={ss:44,s:45,m:45,h:22,d:26,w:null,M:11};function BS(c,h,m,_,I){return I.relativeTime(h||1,!!m,c,_)}function WS(c,h,m,_){var I=to(c).abs(),G=Lo(I.as("s")),de=Lo(I.as("m")),Te=Lo(I.as("h")),Be=Lo(I.as("d")),et=Lo(I.as("M")),bn=Lo(I.as("w")),$o=Lo(I.as("y")),ar=G<=m.ss&&["s",G]||G<m.s&&["ss",G]||de<=1&&["m"]||de<m.m&&["mm",de]||Te<=1&&["h"]||Te<m.h&&["hh",Te]||Be<=1&&["d"]||Be<m.d&&["dd",Be];return m.w!=null&&(ar=ar||bn<=1&&["w"]||bn<m.w&&["ww",bn]),ar=ar||et<=1&&["M"]||et<m.M&&["MM",et]||$o<=1&&["y"]||["yy",$o],ar[2]=h,ar[3]=+c>0,ar[4]=_,BS.apply(null,ar)}function HS(c){return c===void 0?Lo:typeof c=="function"?(Lo=c,!0):!1}function zS(c,h){return Jr[c]===void 0?!1:h===void 0?Jr[c]:(Jr[c]=h,c==="s"&&(Jr.ss=h-1),!0)}function YS(c,h){if(!this.isValid())return this.localeData().invalidDate();var m=!1,_=Jr,I,G;return typeof c=="object"&&(h=c,c=!1),typeof c=="boolean"&&(m=c),typeof h=="object"&&(_=Object.assign({},Jr,h),h.s!=null&&h.ss==null&&(_.ss=h.s-1)),I=this.localeData(),G=WS(this,!m,_,I),m&&(G=I.pastFuture(+this,G)),I.postformat(G)}var zc=Math.abs;function es(c){return(c>0)-(c<0)||+c}function Da(){if(!this.isValid())return this.localeData().invalidDate();var c=zc(this._milliseconds)/1e3,h=zc(this._days),m=zc(this._months),_,I,G,de,Te=this.asSeconds(),Be,et,bn,$o;return Te?(_=Sn(c/60),I=Sn(_/60),c%=60,_%=60,G=Sn(m/12),m%=12,de=c?c.toFixed(3).replace(/\.?0+$/,""):"",Be=Te<0?"-":"",et=es(this._months)!==es(Te)?"-":"",bn=es(this._days)!==es(Te)?"-":"",$o=es(this._milliseconds)!==es(Te)?"-":"",Be+"P"+(G?et+G+"Y":"")+(m?et+m+"M":"")+(h?bn+h+"D":"")+(I||_||c?"T":"")+(I?$o+I+"H":"")+(_?$o+_+"M":"")+(c?$o+de+"S":"")):"P0D"}var nt=_a.prototype;nt.isValid=$w,nt.abs=yS,nt.add=vS,nt.subtract=bS,nt.as=CS,nt.asMilliseconds=hf,nt.asSeconds=SS,nt.asMinutes=_S,nt.asHours=xS,nt.asDays=RS,nt.asWeeks=kS,nt.asMonths=TS,nt.asQuarters=ES,nt.asYears=PS,nt.valueOf=DS,nt._bubble=wS,nt.clone=OS,nt.get=MS,nt.milliseconds=IS,nt.seconds=NS,nt.minutes=AS,nt.hours=FS,nt.days=LS,nt.weeks=jS,nt.months=$S,nt.years=VS,nt.humanize=YS,nt.toISOString=Da,nt.toString=Da,nt.toJSON=Da,nt.locale=Zh,nt.localeData=Jh,nt.toIsoString=R("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",Da),nt.lang=Qh,j("X",0,0,"unix"),j("x",0,0,"valueOf"),Re("x",ln),Re("X",Qt),mt("X",function(c,h,m){m._d=new Date(parseFloat(c)*1e3)}),mt("x",function(c,h,m){m._d=new Date(qe(c))});//! moment.js
|
|
298
|
+
return o.version="2.30.1",r(Dt),o.fn=ge,o.min=Nw,o.max=Aw,o.now=Fw,o.utc=w,o.unix=dS,o.months=hS,o.isDate=p,o.locale=sr,o.invalid=x,o.duration=to,o.isMoment=F,o.weekdays=pS,o.parseZone=uS,o.localeData=No,o.isDuration=xa,o.monthsShort=fS,o.weekdaysMin=gS,o.defineLocale=Oc,o.updateLocale=uw,o.locales=hw,o.weekdaysShort=mS,o.normalizeUnits=Ae,o.relativeTimeRounding=HS,o.relativeTimeThreshold=zS,o.calendarFormat=aC,o.prototype=ge,o.HTML5_FMT={DATETIME_LOCAL:"YYYY-MM-DDTHH:mm",DATETIME_LOCAL_SECONDS:"YYYY-MM-DDTHH:mm:ss",DATETIME_LOCAL_MS:"YYYY-MM-DDTHH:mm:ss.SSS",DATE:"YYYY-MM-DD",TIME:"HH:mm",TIME_SECONDS:"HH:mm:ss",TIME_MS:"HH:mm:ss.SSS",WEEK:"GGGG-[W]WW",MONTH:"YYYY-MM"},o})}(al)),al.exports}RA();const kA=`
|
|
299
299
|
html body {
|
|
300
300
|
font-family: "Courier", "sans-serif";
|
|
301
301
|
font-size: 12px;
|
|
@@ -340,16 +340,16 @@ return o.version="2.30.1",r(Dt),o.fn=ge,o.min=Nw,o.max=Aw,o.now=Fw,o.utc=w,o.uni
|
|
|
340
340
|
.align_left {
|
|
341
341
|
text-align: left;
|
|
342
342
|
}
|
|
343
|
-
`;class Rv{constructor(){this.clientId=0,this.clientName="",this.cssStyles=RA}getClientName(){const t=document.createElement("tr"),n=document.createElement("th");return n.classList.add("align_left"),n.setAttribute("colspan","100%"),n.innerText=`${this.clientName} [${this.clientId}]`,t.append(n),t}columnNames(t){const n=document.createElement("tr");return(t.grid?.getColumns()||[]).filter(a=>a.forPrint).forEach(({name:a})=>{const l=document.createElement("th");l.classList.add("column_name"),typeof a=="string"?l.innerText=a:l.innerText=" ",n.append(l)}),n}tableNameAndTime(t){const n=document.createElement("tr");n.classList.add("heading");const o=document.createElement("th");o.setAttribute("colspan","2"),o.classList.add("table_name"),o.innerText=t.name||t.id,n.append(o);const r=document.createElement("th");return r.setAttribute("colspan","100%"),r.classList.add("date_stamp"),r.innerText=_e().format("MM/DD/YYYY h:mm A"),n.append(r),n}createStyleElement(){const t=document.createElement("style");return t.innerHTML=this.cssStyles,t}createTableElement(t){const n=document.createElement("table");return n.append(this.createThead(t)),n.append(this.createTbody(t)),n}createTbody(t){const n=document.createElement("tbody"),o=t.grid;if(!o)return n;const i=o.getColumns().filter(d=>d.forPrint),a=o.getData();return mc(a).forEach((d,u)=>{const f=this.createTr(i,u,o);n.append(f)}),n.append(...this.totals(t)),n}filters(t){const n=[];if(t.filter){const o=t.filter.print(t);if(o.length){const r=document.createElement("tr"),i=document.createElement("th");i.setAttribute("colspan","100%"),i.classList.add("align_left"),i.innerText="Applied filters",r.append(i),n.push(r)}o.forEach(r=>{n.push(r)})}return n}totals(t){return[]}createThead(t){const n=document.createElement("thead");return n.append(this.getClientName()),n.append(this.tableNameAndTime(t)),n.append(...this.filters(t)),n.append(this.columnNames(t)),n}createTr(t,n,o){const r=document.createElement("tr"),i=o.getData(),a=i.getItem(n),l=a.__group,d=a.__groupTotals;if(l){const u=document.createElement("td");u.setAttribute("colspan","100%"),u.innerText=xy(a.title),r.append(u)}else t.forEach(u=>{const f=document.createElement("td");u.cssClass&&f.classList.add(u.cssClass);const p=u.field,b=i.getItemMetadata(n)?.columns?.[p]?.formatter,w=u.printer||b||u.formatter;let g=a[p];if(d){const v=u.groupTotalsFormatter;g=v?v(a,u,o):""}else w&&(g=w(0,0,g,u,a,o));f.innerText=g||"",r.append(f)});return r}print(t,n,o){this.clientId=n,this.clientName=o;const r=window.open(),i=document.createElement("title");i.innerText=t.name||t.id;const a=r.document.querySelector("head");a.append(i),a.append(this.createStyleElement()),r.document.querySelector("body").append(this.createTableElement(t)),r.print()}}function kA(e){const t=document.querySelector(e);if(!t)return!0;const{scrollHeight:n,scrollWidth:o}=document.documentElement,{bottom:r,left:i,right:a,top:l}=t.getBoundingClientRect();return r<=0||i>=o||a<=0||l>=n}class TA{constructor(){this._initialColumns=[],this._visibleColumnIds=[]}get visibleColumnIds(){return this._visibleColumnIds}set visibleColumnIds(t){this._visibleColumnIds=t}get initialColumns(){return this._initialColumns}set initialColumns(t){this.visibleColumnIds.length||(this.visibleColumnIds=t.map(({id:n})=>n)),this._initialColumns=t}}class EA{constructor(t){this.columnPicker=new TA,this.downloadManager=new sD,this.filter=new fN,this.hotKeysBehavior=new aD,this._grid=null,this._grouping={},this._isActive=!1,this._isEdited=!1,this._lastActiveCell={row:0,cell:0},this._observers=[],this._printer=new Rv;const{downloadManager:n,filter:o,hotKeys:r,id:i,name:a,printer:l,totalCalculator:d}=t;this.id=i,this.name=a||"",n&&(this.downloadManager=n),o&&(this.filter=o),r&&(this.hotKeysBehavior=r),l&&(this.printer=l),d&&(this.totalCalculator=d)}createGrid(t,n,o){this.reset();const r=new cA(`#${this.id}`,t,n,o);return this.grid=r,r.onKeyDown.subscribe(Kp(r)),this.filter.register(r,this.id),this.grid}handleKeyboardEvent(t){kA(`#${this.id}`)||this.hotKeysBehavior.handleKeyboardEvent(t,this)}get grid(){return this._grid}get grouping(){return this._grouping}get isEdited(){return this._isEdited}set grid(t){this._grid=t}set grouping(t){if(this._grouping={...this._grouping,...t},!this.grid)return;const n=this.grid.getData();this.grouping.isGrouped?n.setGrouping(this.grouping.groups||[]):n.setGrouping([])}set isEdited(t){this._isEdited=t,this.notifyObservers()}set printer(t){this._printer=t}get printer(){return this._printer}get isActive(){return this._isActive}set isActive(t){this._isActive=t}get lastActiveSell(){return this._lastActiveCell}set lastActiveSell(t){this._lastActiveCell=t}resizeCanvas(){console.log(""),this.grid?.resizeCanvas()}registerObservers(t){~this._observers.indexOf(t)||this._observers.push(t)}notifyObservers(){for(const t of this._observers)t(this)}deleteObserver(t){const n=this._observers.indexOf(t);this._observers.splice(n,1)}reset(){this.grid?.onKeyDown.unsubscribe(Kp(this.grid)),this.grid?.getSelectionModel()&&this.grid.setSelectedRows([]),this.hotKeysBehavior.resetQueue(),this.isEdited=!1,this.isActive=!1,this.grid=null}}class PA extends fc{constructor(){super(...arguments),this.x=0,this.y=0}}const Cn=new PA;class DA extends fc{constructor(){super(...arguments),this.x=0,this.y=0}}const so=new DA,OA=e=>{const t=e.getLength()-1;return e.getItem(t)},kl=e=>{const t=e.getData(),n=t.getIdPropertyName(),o=t.getItems();let r=0;return o.forEach(i=>{i[n]>r&&(r=i[n])}),r+1},fh=()=>{Cv.commitCurrentEdit()};function kv(e){return e.ctrlKey&&e.keyCode===Vs.KeyB}function MA(e){return e.shiftKey&&e.keyCode===Vs.KeyDel}function Tv(e){return e.ctrlKey&&e.keyCode===Vs.KeyY}function Ev(e){return e.ctrlKey&&e.keyCode===Vs.KeyZ}function IA(e){const t=e.getActiveCell();return!e.getSelectedRows().length&&!t}function NA(e){const t=AA(e),o=e.getData().getItems(),r=o.findIndex(a=>a.id===t)+1,i=o.length;return r||i}const mc=e=>{const t=[];for(let n=0;n<e.getLength();n++)t.push(e.getItem(n));return t},Pv=e=>{const t=e.getSelectedRows(),n=e.getData(),o=mc(n),r=n.getItems(),i=[],a=n.getIdPropertyName();t.length?t.forEach(l=>{i.push({...o[l],[a]:kl(e),isEdited:!0,isNew:!0})}):i.push({[a]:kl(e),isEdited:!0,isNew:!0}),r.splice(NA(e),0,...i),n.setItems(r),e.setSelectedRows([]),e.invalidate()},AA=e=>{const t=e.getData(),n=mc(t),o=e.getActiveCell()?.row;return o!==void 0?(n[o]||n[n.length-1])?.id:0};function Dv(e){return function(t){t.preventDefault(),fh(),Cn.table=e,Cn.x=t.pageX||0,Cn.y=t.pageY||0,Cn.notify()}}function FA(e){return function(t){t.preventDefault(),fh(),so.table=e,so.x=t.pageX||0,so.y=t.pageY||0,so.notify()}}class LA extends fc{constructor(){super(...arguments),this._activeTable=null}get activeTable(){return this._activeTable}set activeTable(t){this._activeTable=t}}const ci=new LA,$A=e=>{function t(){if(e.id!==ci.activeTable?.id){e.isActive=!1;const o=e.grid;o?.resetActiveCell(),o?.setSelectedRows([])}}function n(){e.isActive=!0,ci.activeTable=e,ci.notify()}$e.useEffect(()=>{ci.subscribe(t),document.addEventListener("keydown",e.handleKeyboardEvent.bind(e));const o=document.getElementById(e.id);if(o)return o.addEventListener("click",n,!0),()=>{ci.unsubscribe(t),document.removeEventListener("keydown",e.handleKeyboardEvent.bind(e)),o.removeEventListener("click",n,!0)}},[])},VA=e=>{const[t,n]=$e.useState(jA(e));return $e.useEffect(()=>{const o=r=>{n(i=>({...i,[r.id]:r.isEdited}))};return e.forEach(r=>{r.registerObservers(o)}),()=>{e.forEach(r=>{r.deleteObserver(o)})}},[]),Object.values(t).some(o=>o)};function jA(e){const t={};for(const n of e)t[n.id]=n.isEdited;return t}function BA(e){$e.useEffect(()=>{function t(){e.grid?.resizeCanvas()}const n=_y(t);return window.addEventListener("resize",n),()=>{window.removeEventListener("resize",n)}},[])}const WA=e=>{$e.useEffect(()=>{function t(n){const o=n.grid;o&&n.totalCalculator?.calculate(o)}return e.registerObservers(t),()=>{e.deleteObserver(t)}},[])},HA=e=>{if(!e)return 0;if(typeof e=="number")return e;const t=e.replace(/\$|,|\s/g,""),n=t.replace(/\(|\)/g,"");return isNaN(Number(n))?0:t.startsWith("(")&&t.endsWith(")")?0-Number(n):Number(t)},Nr=function(){const e=function(x,S,C,O){for(C=C||{},O=x.length;O--;C[x[O]]=S);return C},t=[1,3],n=[1,4],o=[1,5],r=[1,6],i=[1,7],a=[1,9],l=[1,10],d=[1,11],u=[1,12],f=[1,13],p=[1,14],y=[1,15],b=[5,6,7,8,9,10,11,12,14],w=[5,6,7,14],g=[5,6,7,8,9,14],v={trace:function(){},yy:{},symbols_:{error:2,expressions:3,e:4,EOF:5,"+":6,"-":7,"*":8,"/":9,"^":10,"!":11,"%":12,"(":13,")":14,NUMBER:15,E:16,PI:17,$accept:0,$end:1},terminals_:{2:"error",5:"EOF",6:"+",7:"-",8:"*",9:"/",10:"^",11:"!",12:"%",13:"(",14:")",15:"NUMBER",16:"E",17:"PI"},productions_:[0,[3,2],[4,3],[4,3],[4,3],[4,3],[4,3],[4,2],[4,2],[4,2],[4,3],[4,1],[4,1],[4,1]],performAction:function(S,C,O,N,F,z,R){const $=z.length-1;switch(F){case 1:return z[$-1];case 2:this.$=z[$-2]+z[$];break;case 3:this.$=z[$-2]-z[$];break;case 4:this.$=z[$-2]*z[$];break;case 5:this.$=z[$-2]/z[$];break;case 6:this.$=Math.pow(z[$-2],z[$]);break;case 7:this.$=function K(X){return X==0?1:K(X-1)*X}(z[$-1]);break;case 8:this.$=z[$-1]/100;break;case 9:this.$=-z[$];break;case 10:this.$=z[$-1];break;case 11:this.$=Number(S);break;case 12:this.$=Math.E;break;case 13:this.$=Math.PI;break}},table:[{3:1,4:2,7:t,13:n,15:o,16:r,17:i},{1:[3]},{5:[1,8],6:a,7:l,8:d,9:u,10:f,11:p,12:y},{4:16,7:t,13:n,15:o,16:r,17:i},{4:17,7:t,13:n,15:o,16:r,17:i},e(b,[2,11]),e(b,[2,12]),e(b,[2,13]),{1:[2,1]},{4:18,7:t,13:n,15:o,16:r,17:i},{4:19,7:t,13:n,15:o,16:r,17:i},{4:20,7:t,13:n,15:o,16:r,17:i},{4:21,7:t,13:n,15:o,16:r,17:i},{4:22,7:t,13:n,15:o,16:r,17:i},e(b,[2,7]),e(b,[2,8]),e(b,[2,9]),{6:a,7:l,8:d,9:u,10:f,11:p,12:y,14:[1,23]},e(w,[2,2],{8:d,9:u,10:f,11:p,12:y}),e(w,[2,3],{8:d,9:u,10:f,11:p,12:y}),e(g,[2,4],{10:f,11:p,12:y}),e(g,[2,5],{10:f,11:p,12:y}),e([5,6,7,8,9,10,14],[2,6],{11:p,12:y}),e(b,[2,10])],defaultActions:{8:[2,1]},parseError:function(S,C){if(C.recoverable)this.trace(S);else{const O=new Error(S);throw O.hash=C,O}},parse:function(S){const C=this;let O=[0],N=[null],F=[];const z=this.table;let R="",$=0,K=0;const X=2,q=1,Y=F.slice.call(arguments,1),H=Object.create(this.lexer),le={yy:{}};for(let ie in this.yy)Object.prototype.hasOwnProperty.call(this.yy,ie)&&(le.yy[ie]=this.yy[ie]);H.setInput(S,le.yy),le.yy.lexer=H,le.yy.parser=this,typeof H.yylloc>"u"&&(H.yylloc={});let A=H.yylloc;F.push(A);const M=H.options&&H.options.ranges;typeof le.yy.parseError=="function"?this.parseError=le.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;var V=function(){let ie;return ie=H.lex()||q,typeof ie!="number"&&(ie=C.symbols_[ie]||ie),ie};let B,ne,oe,se;const j={};let J,ee,te,ce;for(;;){if(ne=O[O.length-1],this.defaultActions[ne]?oe=this.defaultActions[ne]:((B===null||typeof B>"u")&&(B=V()),oe=z[ne]&&z[ne][B]),typeof oe>"u"||!oe.length||!oe[0]){let ie="";ce=[];for(J in z[ne])this.terminals_[J]&&J>X&&ce.push("'"+this.terminals_[J]+"'");H.showPosition?ie="Parse error on line "+($+1)+`:
|
|
343
|
+
`;class Rv{constructor(){this.clientId=0,this.clientName="",this.cssStyles=kA}getClientName(){const t=document.createElement("tr"),n=document.createElement("th");return n.classList.add("align_left"),n.setAttribute("colspan","100%"),n.innerText=`${this.clientName} [${this.clientId}]`,t.append(n),t}columnNames(t){const n=document.createElement("tr");return(t.grid?.getColumns()||[]).filter(a=>a.forPrint).forEach(({name:a})=>{const l=document.createElement("th");l.classList.add("column_name"),typeof a=="string"?l.innerText=a:l.innerText=" ",n.append(l)}),n}tableNameAndTime(t){const n=document.createElement("tr");n.classList.add("heading");const o=document.createElement("th");o.setAttribute("colspan","2"),o.classList.add("table_name"),o.innerText=t.name||t.id,n.append(o);const r=document.createElement("th");return r.setAttribute("colspan","100%"),r.classList.add("date_stamp"),r.innerText=_e().format("MM/DD/YYYY h:mm A"),n.append(r),n}createStyleElement(){const t=document.createElement("style");return t.innerHTML=this.cssStyles,t}createTableElement(t){const n=document.createElement("table");return n.append(this.createThead(t)),n.append(this.createTbody(t)),n}createTbody(t){const n=document.createElement("tbody"),o=t.grid;if(!o)return n;const i=o.getColumns().filter(d=>d.forPrint),a=o.getData();return mc(a).forEach((d,u)=>{const f=this.createTr(i,u,o);n.append(f)}),n.append(...this.totals(t)),n}filters(t){const n=[];if(t.filter){const o=t.filter.print(t);if(o.length){const r=document.createElement("tr"),i=document.createElement("th");i.setAttribute("colspan","100%"),i.classList.add("align_left"),i.innerText="Applied filters",r.append(i),n.push(r)}o.forEach(r=>{n.push(r)})}return n}totals(t){return[]}createThead(t){const n=document.createElement("thead");return n.append(this.getClientName()),n.append(this.tableNameAndTime(t)),n.append(...this.filters(t)),n.append(this.columnNames(t)),n}createTr(t,n,o){const r=document.createElement("tr"),i=o.getData(),a=i.getItem(n),l=a.__group,d=a.__groupTotals;if(l){const u=document.createElement("td");u.setAttribute("colspan","100%"),u.innerText=xy(a.title),r.append(u)}else t.forEach(u=>{const f=document.createElement("td");u.cssClass&&f.classList.add(u.cssClass);const p=u.field,b=i.getItemMetadata(n)?.columns?.[p]?.formatter,w=u.printer||b||u.formatter;let g=a[p];if(d){const v=u.groupTotalsFormatter;g=v?v(a,u,o):""}else w&&(g=w(0,0,g,u,a,o));f.innerText=g||"",r.append(f)});return r}print(t,n,o){this.clientId=n,this.clientName=o;const r=window.open(),i=document.createElement("title");i.innerText=t.name||t.id;const a=r.document.querySelector("head");a.append(i),a.append(this.createStyleElement()),r.document.querySelector("body").append(this.createTableElement(t)),r.print()}}function TA(e){const t=document.querySelector(e);if(!t)return!0;const{scrollHeight:n,scrollWidth:o}=document.documentElement,{bottom:r,left:i,right:a,top:l}=t.getBoundingClientRect();return r<=0||i>=o||a<=0||l>=n}class EA{constructor(t){this.columnPicker=null,this.downloadManager=new iD,this.filter=new pN,this.hotKeysBehavior=new lD,this._grid=null,this._grouping={},this._isActive=!1,this._isEdited=!1,this._lastActiveCell={row:0,cell:0},this._observers=[],this._printer=new Rv;const{columnPicker:n,downloadManager:o,filter:r,hotKeys:i,id:a,name:l,printer:d,totalCalculator:u}=t;this.id=a,this.name=l||"",n&&(this.columnPicker=n),o&&(this.downloadManager=o),r&&(this.filter=r),i&&(this.hotKeysBehavior=i),d&&(this.printer=d),u&&(this.totalCalculator=u)}createGrid(t,n,o){this.reset();const r=new dA(`#${this.id}`,t,n,o);return this.grid=r,r.onKeyDown.subscribe(Kp(r)),this.filter.register(r,this.id),this.grid}handleKeyboardEvent(t){TA(`#${this.id}`)||this.hotKeysBehavior.handleKeyboardEvent(t,this)}get grid(){return this._grid}get grouping(){return this._grouping}get isEdited(){return this._isEdited}set grid(t){this._grid=t}set grouping(t){if(this._grouping={...this._grouping,...t},!this.grid)return;const n=this.grid.getData();this.grouping.isGrouped?n.setGrouping(this.grouping.groups||[]):n.setGrouping([])}set isEdited(t){this._isEdited=t,this.notifyObservers()}set printer(t){this._printer=t}get printer(){return this._printer}get isActive(){return this._isActive}set isActive(t){this._isActive=t}get lastActiveSell(){return this._lastActiveCell}set lastActiveSell(t){this._lastActiveCell=t}resizeCanvas(){console.log(""),this.grid?.resizeCanvas()}registerObservers(t){~this._observers.indexOf(t)||this._observers.push(t)}notifyObservers(){for(const t of this._observers)t(this)}deleteObserver(t){const n=this._observers.indexOf(t);this._observers.splice(n,1)}reset(){this.grid?.onKeyDown.unsubscribe(Kp(this.grid)),this.grid?.getSelectionModel()&&this.grid.setSelectedRows([]),this.hotKeysBehavior.resetQueue(),this.isEdited=!1,this.isActive=!1,this.grid=null}}class PA extends fc{constructor(){super(...arguments),this.x=0,this.y=0}}const Cn=new PA;class DA extends fc{constructor(){super(...arguments),this.x=0,this.y=0}}const so=new DA,OA=e=>{const t=e.getLength()-1;return e.getItem(t)},kl=e=>{const t=e.getData(),n=t.getIdPropertyName(),o=t.getItems();let r=0;return o.forEach(i=>{i[n]>r&&(r=i[n])}),r+1},fh=()=>{Cv.commitCurrentEdit()};function kv(e){return e.ctrlKey&&e.keyCode===Vs.KeyB}function MA(e){return e.shiftKey&&e.keyCode===Vs.KeyDel}function Tv(e){return e.ctrlKey&&e.keyCode===Vs.KeyY}function Ev(e){return e.ctrlKey&&e.keyCode===Vs.KeyZ}function IA(e){const t=e.getActiveCell();return!e.getSelectedRows().length&&!t}function NA(e){const t=AA(e),o=e.getData().getItems(),r=o.findIndex(a=>a.id===t)+1,i=o.length;return r||i}const mc=e=>{const t=[];for(let n=0;n<e.getLength();n++)t.push(e.getItem(n));return t},Pv=e=>{const t=e.getSelectedRows(),n=e.getData(),o=mc(n),r=n.getItems(),i=[],a=n.getIdPropertyName();t.length?t.forEach(l=>{i.push({...o[l],[a]:kl(e),isEdited:!0,isNew:!0})}):i.push({[a]:kl(e),isEdited:!0,isNew:!0}),r.splice(NA(e),0,...i),n.setItems(r),e.setSelectedRows([]),e.invalidate()},AA=e=>{const t=e.getData(),n=mc(t),o=e.getActiveCell()?.row;return o!==void 0?(n[o]||n[n.length-1])?.id:0};function Dv(e){return function(t){t.preventDefault(),fh(),Cn.table=e,Cn.x=t.pageX||0,Cn.y=t.pageY||0,Cn.notify()}}function FA(e){return function(t){t.preventDefault(),fh(),so.table=e,so.x=t.pageX||0,so.y=t.pageY||0,so.notify()}}class LA extends fc{constructor(){super(...arguments),this._activeTable=null}get activeTable(){return this._activeTable}set activeTable(t){this._activeTable=t}}const ci=new LA,$A=e=>{function t(){if(e.id!==ci.activeTable?.id){e.isActive=!1;const o=e.grid;o?.resetActiveCell(),o?.setSelectedRows([])}}function n(){e.isActive=!0,ci.activeTable=e,ci.notify()}$e.useEffect(()=>{ci.subscribe(t),document.addEventListener("keydown",e.handleKeyboardEvent.bind(e));const o=document.getElementById(e.id);if(o)return o.addEventListener("click",n,!0),()=>{ci.unsubscribe(t),document.removeEventListener("keydown",e.handleKeyboardEvent.bind(e)),o.removeEventListener("click",n,!0)}},[])},VA=e=>{const[t,n]=$e.useState(jA(e));return $e.useEffect(()=>{const o=r=>{n(i=>({...i,[r.id]:r.isEdited}))};return e.forEach(r=>{r.registerObservers(o)}),()=>{e.forEach(r=>{r.deleteObserver(o)})}},[]),Object.values(t).some(o=>o)};function jA(e){const t={};for(const n of e)t[n.id]=n.isEdited;return t}function BA(e){$e.useEffect(()=>{function t(){e.grid?.resizeCanvas()}const n=_y(t);return window.addEventListener("resize",n),()=>{window.removeEventListener("resize",n)}},[])}const WA=e=>{$e.useEffect(()=>{function t(n){const o=n.grid;o&&n.totalCalculator?.calculate(o)}return e.registerObservers(t),()=>{e.deleteObserver(t)}},[])},HA=e=>{if(!e)return 0;if(typeof e=="number")return e;const t=e.replace(/\$|,|\s/g,""),n=t.replace(/\(|\)/g,"");return isNaN(Number(n))?0:t.startsWith("(")&&t.endsWith(")")?0-Number(n):Number(t)},Nr=function(){const e=function(x,S,C,O){for(C=C||{},O=x.length;O--;C[x[O]]=S);return C},t=[1,3],n=[1,4],o=[1,5],r=[1,6],i=[1,7],a=[1,9],l=[1,10],d=[1,11],u=[1,12],f=[1,13],p=[1,14],y=[1,15],b=[5,6,7,8,9,10,11,12,14],w=[5,6,7,14],g=[5,6,7,8,9,14],v={trace:function(){},yy:{},symbols_:{error:2,expressions:3,e:4,EOF:5,"+":6,"-":7,"*":8,"/":9,"^":10,"!":11,"%":12,"(":13,")":14,NUMBER:15,E:16,PI:17,$accept:0,$end:1},terminals_:{2:"error",5:"EOF",6:"+",7:"-",8:"*",9:"/",10:"^",11:"!",12:"%",13:"(",14:")",15:"NUMBER",16:"E",17:"PI"},productions_:[0,[3,2],[4,3],[4,3],[4,3],[4,3],[4,3],[4,2],[4,2],[4,2],[4,3],[4,1],[4,1],[4,1]],performAction:function(S,C,O,N,F,z,R){const $=z.length-1;switch(F){case 1:return z[$-1];case 2:this.$=z[$-2]+z[$];break;case 3:this.$=z[$-2]-z[$];break;case 4:this.$=z[$-2]*z[$];break;case 5:this.$=z[$-2]/z[$];break;case 6:this.$=Math.pow(z[$-2],z[$]);break;case 7:this.$=function K(X){return X==0?1:K(X-1)*X}(z[$-1]);break;case 8:this.$=z[$-1]/100;break;case 9:this.$=-z[$];break;case 10:this.$=z[$-1];break;case 11:this.$=Number(S);break;case 12:this.$=Math.E;break;case 13:this.$=Math.PI;break}},table:[{3:1,4:2,7:t,13:n,15:o,16:r,17:i},{1:[3]},{5:[1,8],6:a,7:l,8:d,9:u,10:f,11:p,12:y},{4:16,7:t,13:n,15:o,16:r,17:i},{4:17,7:t,13:n,15:o,16:r,17:i},e(b,[2,11]),e(b,[2,12]),e(b,[2,13]),{1:[2,1]},{4:18,7:t,13:n,15:o,16:r,17:i},{4:19,7:t,13:n,15:o,16:r,17:i},{4:20,7:t,13:n,15:o,16:r,17:i},{4:21,7:t,13:n,15:o,16:r,17:i},{4:22,7:t,13:n,15:o,16:r,17:i},e(b,[2,7]),e(b,[2,8]),e(b,[2,9]),{6:a,7:l,8:d,9:u,10:f,11:p,12:y,14:[1,23]},e(w,[2,2],{8:d,9:u,10:f,11:p,12:y}),e(w,[2,3],{8:d,9:u,10:f,11:p,12:y}),e(g,[2,4],{10:f,11:p,12:y}),e(g,[2,5],{10:f,11:p,12:y}),e([5,6,7,8,9,10,14],[2,6],{11:p,12:y}),e(b,[2,10])],defaultActions:{8:[2,1]},parseError:function(S,C){if(C.recoverable)this.trace(S);else{const O=new Error(S);throw O.hash=C,O}},parse:function(S){const C=this;let O=[0],N=[null],F=[];const z=this.table;let R="",$=0,K=0;const X=2,q=1,Y=F.slice.call(arguments,1),H=Object.create(this.lexer),le={yy:{}};for(let ie in this.yy)Object.prototype.hasOwnProperty.call(this.yy,ie)&&(le.yy[ie]=this.yy[ie]);H.setInput(S,le.yy),le.yy.lexer=H,le.yy.parser=this,typeof H.yylloc>"u"&&(H.yylloc={});let A=H.yylloc;F.push(A);const M=H.options&&H.options.ranges;typeof le.yy.parseError=="function"?this.parseError=le.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;var V=function(){let ie;return ie=H.lex()||q,typeof ie!="number"&&(ie=C.symbols_[ie]||ie),ie};let B,ne,oe,se;const j={};let J,ee,te,ce;for(;;){if(ne=O[O.length-1],this.defaultActions[ne]?oe=this.defaultActions[ne]:((B===null||typeof B>"u")&&(B=V()),oe=z[ne]&&z[ne][B]),typeof oe>"u"||!oe.length||!oe[0]){let ie="";ce=[];for(J in z[ne])this.terminals_[J]&&J>X&&ce.push("'"+this.terminals_[J]+"'");H.showPosition?ie="Parse error on line "+($+1)+`:
|
|
344
344
|
`+H.showPosition()+`
|
|
345
345
|
Expecting `+ce.join(", ")+", got '"+(this.terminals_[B]||B)+"'":ie="Parse error on line "+($+1)+": Unexpected "+(B==q?"end of input":"'"+(this.terminals_[B]||B)+"'"),this.parseError(ie,{text:H.match,token:this.terminals_[B]||B,line:H.yylineno,loc:A,expected:ce})}if(oe[0]instanceof Array&&oe.length>1)throw new Error("Parse Error: multiple actions possible at state: "+ne+", token: "+B);switch(oe[0]){case 1:O.push(B),N.push(H.yytext),F.push(H.yylloc),O.push(oe[1]),B=null,K=H.yyleng,R=H.yytext,$=H.yylineno,A=H.yylloc;break;case 2:if(ee=this.productions_[oe[1]][1],j.$=N[N.length-ee],j._$={first_line:F[F.length-(ee||1)].first_line,last_line:F[F.length-1].last_line,first_column:F[F.length-(ee||1)].first_column,last_column:F[F.length-1].last_column},M&&(j._$.range=[F[F.length-(ee||1)].range[0],F[F.length-1].range[1]]),se=this.performAction.apply(j,[R,K,$,le.yy,oe[1],N,F].concat(Y)),typeof se<"u")return se;ee&&(O=O.slice(0,-1*ee*2),N=N.slice(0,-1*ee),F=F.slice(0,-1*ee)),O.push(this.productions_[oe[1]][0]),N.push(j.$),F.push(j._$),te=z[O[O.length-2]][O[O.length-1]],O.push(te);break;case 3:return!0}}return!0}},E=function(){return{EOF:1,parseError:function(C,O){if(this.yy.parser)this.yy.parser.parseError(C,O);else throw new Error(C)},setInput:function(S,C){return this.yy=C||this.yy||{},this._input=S,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},input:function(){const S=this._input[0];return this.yytext+=S,this.yyleng++,this.offset++,this.match+=S,this.matched+=S,S.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),S},unput:function(S){const C=S.length,O=S.split(/(?:\r\n?|\n)/g);this._input=S+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-C),this.offset-=C;const N=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),O.length-1&&(this.yylineno-=O.length-1);const F=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:O?(O.length===N.length?this.yylloc.first_column:0)+N[N.length-O.length].length-O[0].length:this.yylloc.first_column-C},this.options.ranges&&(this.yylloc.range=[F[0],F[0]+this.yyleng-C]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
|
|
346
346
|
`+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},less:function(S){this.unput(this.match.slice(S))},pastInput:function(){const S=this.matched.substr(0,this.matched.length-this.match.length);return(S.length>20?"...":"")+S.substr(-20).replace(/\n/g,"")},upcomingInput:function(){let S=this.match;return S.length<20&&(S+=this._input.substr(0,20-S.length)),(S.substr(0,20)+(S.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){const S=this.pastInput(),C=new Array(S.length+1).join("-");return S+this.upcomingInput()+`
|
|
347
347
|
`+C+"^"},test_match:function(S,C){let O,N,F;if(this.options.backtrack_lexer&&(F={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(F.yylloc.range=this.yylloc.range.slice(0))),N=S[0].match(/(?:\r\n?|\n).*/g),N&&(this.yylineno+=N.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:N?N[N.length-1].length-N[N.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+S[0].length},this.yytext+=S[0],this.match+=S[0],this.matches=S,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(S[0].length),this.matched+=S[0],O=this.performAction.call(this,this.yy,this,C,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),O)return O;if(this._backtrack){for(let z in F)this[z]=F[z];return!1}return!1},next:function(){if(this.done)return this.EOF;this._input||(this.done=!0);let S,C,O,N;this._more||(this.yytext="",this.match="");const F=this._currentRules();for(let z=0;z<F.length;z++)if(O=this._input.match(this.rules[F[z]]),O&&(!C||O[0].length>C[0].length)){if(C=O,N=z,this.options.backtrack_lexer){if(S=this.test_match(O,F[z]),S!==!1)return S;if(this._backtrack){C=!1;continue}else return!1}else if(!this.options.flex)break}return C?(S=this.test_match(C,F[N]),S!==!1?S:!1):this._input===""?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text.
|
|
348
|
-
`+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){const C=this.next();return C||this.lex()},begin:function(C){this.conditionStack.push(C)},popState:function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(C){return C=this.conditionStack.length-1-Math.abs(C||0),C>=0?this.conditionStack[C]:"INITIAL"},pushState:function(C){this.begin(C)},stateStackSize:function(){return this.conditionStack.length},options:{},performAction:function(C,O,N,F){switch(N){case 0:break;case 1:return 15;case 2:return 8;case 3:return 9;case 4:return 7;case 5:return 6;case 6:return 10;case 7:return 11;case 8:return 12;case 9:return 13;case 10:return 14;case 11:return 17;case 12:return 16;case 13:return 5;case 14:return"INVALID"}},rules:[/^(?:\s+)/,/^(?:[0-9]+(\.[0-9]+)?\b)/,/^(?:\*)/,/^(?:\/)/,/^(?:-)/,/^(?:\+)/,/^(?:\^)/,/^(?:!)/,/^(?:%)/,/^(?:\()/,/^(?:\))/,/^(?:PI\b)/,/^(?:E\b)/,/^(?:$)/,/^(?:.)/],conditions:{INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14],inclusive:!0}}}}();v.lexer=E;function P(){this.yy={},this.parse=this.parse.bind(this)}return P.prototype=v,v.Parser=P,new P}();typeof require<"u"&&typeof exports<"u"&&(exports.parser=Nr,exports.Parser=Nr.Parser,exports.parse=function(){return Nr.parse.apply(Nr,arguments)});const Ov=2;class zA extends om{isValueChanged(){const t=HA(this.defaultValue);let n=0;try{n=Nr.parse(this.input.value||"0")}catch{return!0}return!n&&!t?!1:n!==t}loadValue(t){const n=Number(t[this.args.column.field]||"0");this.defaultValue=n.toFixed(Ov),this.input.value=this.defaultValue,this.input.defaultValue=this.input.value,this.input.select()}serializeValue(){let t=Nr.parse(this.input.value||"0");om.AllowEmptyValue?!t&&t!==0&&(t=void 0):t=t||0;const n=this.getDecimalPlaces();return n!==null&&(t||t===0)&&t.toFixed&&(t=parseFloat(t.toFixed(n))),t}validate(){let t=0;try{if(t=Nr.parse(`${this.input.value}`),t===1/0)throw new Error}catch{return{valid:!1,msg:"Please enter a valid number"}}if(this.args.column.validator){const n=this.args.column.validator(t,this.args);if(!n.valid)return n}return{valid:!0,msg:null}}}zA.DefaultDecimalPlaces=Ov;class YA{constructor(){this.currentFocus=-1,this.defaultValue="",this.id="autocomplete",this.input=document.createElement("input"),this.keyCaptureList=[Lr.UP,Lr.DOWN,Lr.ENTER]}applyValue(t,n){t[this.args.column.field]=n}closeAllList(){this.list?.remove(),this.list=void 0,this.currentFocus=-1}destroy(){this.input.removeEventListener("input",this.onInput.bind(this)),this.input.removeEventListener("keydown",this.onKeydown.bind(this)),this.closeAllList(),this.input.remove()}focus(){this.input.focus()}init(){this.navOnLR=this.args.grid.getOptions().editorCellNavOnLRKeys,this.input.setAttribute("type","text"),this.input.classList.add("editor-text"),this.args.container.append(this.input),this.input.addEventListener("input",this.onInput.bind(this)),this.input.addEventListener("keydown",this.onKeydown.bind(this)),this.input.focus(),this.input.select()}isValueChanged(){return!(this.input.value==""&&this.defaultValue==null)&&this.input.value!=this.defaultValue}loadValue(t){this.defaultValue=t[this.args.column.field]||"",this.input.value=this.defaultValue,this.input.defaultValue=this.defaultValue,this.input.focus(),this.input.select()}makeVisible(t){const n=t.closest(".grid-canvas");if(!n)return;const{bottom:o,right:r}=t.getBoundingClientRect(),{bottom:i,right:a}=n.getBoundingClientRect();if(o>=i){const l=this.args.grid.getOptions().rowHeight;t.style.position="absolute",t.style.bottom=`${l}px`}r>=a&&(t.style.position="absolute",t.style.right="0")}onKeydown(t){if(t.key===Or.ArrowLeft){this.navOnLR&&this.args.grid.navigatePrev(),t.stopImmediatePropagation();return}else if(t.key===Or.ArrowRight){this.navOnLR&&this.args.grid.navigateNext(),t.stopImmediatePropagation();return}if(!this.list)return;const n=this.list.getElementsByTagName("div");t.key===Or.ArrowDown?(this.currentFocus++,this.setActive(n)):t.key===Or.ArrowUp?(this.currentFocus--,this.setActive(n)):(t.key===Or.Enter||t.key===Or.Tab)&&(t.preventDefault(),n.length===1&&(this.currentFocus=0),this.currentFocus>-1&&n&&n[this.currentFocus].click())}removeActive(t){for(let n=0;n<t.length;n++)t[n].classList.remove("active")}scrollToElement(t){const n=t.parentElement;if(!n)return;const{clientHeight:o,offsetTop:r}=t,{clientHeight:i,scrollTop:a}=n;r>=a+i?n.scrollTop=r-o*1.5:r-o<=a&&(n.scrollTop=r-i)}serializeValue(){return this.input.value}setActive(t){if(!t.length)return;this.removeActive(t),this.currentFocus>=t.length&&(this.currentFocus=0),this.currentFocus<0&&(this.currentFocus=t.length-1);const n=t[this.currentFocus];n.classList.add("active"),this.scrollToElement(n)}validate(){if(this.args.column.validator){const t=this.args.column.validator(this.input.value,this.args);if(!t.valid)return t}return{valid:!0,msg:null}}}var ll={exports:{}};const UA=GS(
|
|
348
|
+
`+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){const C=this.next();return C||this.lex()},begin:function(C){this.conditionStack.push(C)},popState:function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(C){return C=this.conditionStack.length-1-Math.abs(C||0),C>=0?this.conditionStack[C]:"INITIAL"},pushState:function(C){this.begin(C)},stateStackSize:function(){return this.conditionStack.length},options:{},performAction:function(C,O,N,F){switch(N){case 0:break;case 1:return 15;case 2:return 8;case 3:return 9;case 4:return 7;case 5:return 6;case 6:return 10;case 7:return 11;case 8:return 12;case 9:return 13;case 10:return 14;case 11:return 17;case 12:return 16;case 13:return 5;case 14:return"INVALID"}},rules:[/^(?:\s+)/,/^(?:[0-9]+(\.[0-9]+)?\b)/,/^(?:\*)/,/^(?:\/)/,/^(?:-)/,/^(?:\+)/,/^(?:\^)/,/^(?:!)/,/^(?:%)/,/^(?:\()/,/^(?:\))/,/^(?:PI\b)/,/^(?:E\b)/,/^(?:$)/,/^(?:.)/],conditions:{INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14],inclusive:!0}}}}();v.lexer=E;function P(){this.yy={},this.parse=this.parse.bind(this)}return P.prototype=v,v.Parser=P,new P}();typeof require<"u"&&typeof exports<"u"&&(exports.parser=Nr,exports.Parser=Nr.Parser,exports.parse=function(){return Nr.parse.apply(Nr,arguments)});const Ov=2;class zA extends om{isValueChanged(){const t=HA(this.defaultValue);let n=0;try{n=Nr.parse(this.input.value||"0")}catch{return!0}return!n&&!t?!1:n!==t}loadValue(t){const n=Number(t[this.args.column.field]||"0");this.defaultValue=n.toFixed(Ov),this.input.value=this.defaultValue,this.input.defaultValue=this.input.value,this.input.select()}serializeValue(){let t=Nr.parse(this.input.value||"0");om.AllowEmptyValue?!t&&t!==0&&(t=void 0):t=t||0;const n=this.getDecimalPlaces();return n!==null&&(t||t===0)&&t.toFixed&&(t=parseFloat(t.toFixed(n))),t}validate(){let t=0;try{if(t=Nr.parse(`${this.input.value}`),t===1/0)throw new Error}catch{return{valid:!1,msg:"Please enter a valid number"}}if(this.args.column.validator){const n=this.args.column.validator(t,this.args);if(!n.valid)return n}return{valid:!0,msg:null}}}zA.DefaultDecimalPlaces=Ov;class YA{constructor(){this.currentFocus=-1,this.defaultValue="",this.id="autocomplete",this.input=document.createElement("input"),this.keyCaptureList=[Lr.UP,Lr.DOWN,Lr.ENTER]}applyValue(t,n){t[this.args.column.field]=n}closeAllList(){this.list?.remove(),this.list=void 0,this.currentFocus=-1}destroy(){this.input.removeEventListener("input",this.onInput.bind(this)),this.input.removeEventListener("keydown",this.onKeydown.bind(this)),this.closeAllList(),this.input.remove()}focus(){this.input.focus()}init(){this.navOnLR=this.args.grid.getOptions().editorCellNavOnLRKeys,this.input.setAttribute("type","text"),this.input.classList.add("editor-text"),this.args.container.append(this.input),this.input.addEventListener("input",this.onInput.bind(this)),this.input.addEventListener("keydown",this.onKeydown.bind(this)),this.input.focus(),this.input.select()}isValueChanged(){return!(this.input.value==""&&this.defaultValue==null)&&this.input.value!=this.defaultValue}loadValue(t){this.defaultValue=t[this.args.column.field]||"",this.input.value=this.defaultValue,this.input.defaultValue=this.defaultValue,this.input.focus(),this.input.select()}makeVisible(t){const n=t.closest(".grid-canvas");if(!n)return;const{bottom:o,right:r}=t.getBoundingClientRect(),{bottom:i,right:a}=n.getBoundingClientRect();if(o>=i){const l=this.args.grid.getOptions().rowHeight;t.style.position="absolute",t.style.bottom=`${l}px`}r>=a&&(t.style.position="absolute",t.style.right="0")}onKeydown(t){if(t.key===Or.ArrowLeft){this.navOnLR&&this.args.grid.navigatePrev(),t.stopImmediatePropagation();return}else if(t.key===Or.ArrowRight){this.navOnLR&&this.args.grid.navigateNext(),t.stopImmediatePropagation();return}if(!this.list)return;const n=this.list.getElementsByTagName("div");t.key===Or.ArrowDown?(this.currentFocus++,this.setActive(n)):t.key===Or.ArrowUp?(this.currentFocus--,this.setActive(n)):(t.key===Or.Enter||t.key===Or.Tab)&&(t.preventDefault(),n.length===1&&(this.currentFocus=0),this.currentFocus>-1&&n&&n[this.currentFocus].click())}removeActive(t){for(let n=0;n<t.length;n++)t[n].classList.remove("active")}scrollToElement(t){const n=t.parentElement;if(!n)return;const{clientHeight:o,offsetTop:r}=t,{clientHeight:i,scrollTop:a}=n;r>=a+i?n.scrollTop=r-o*1.5:r-o<=a&&(n.scrollTop=r-i)}serializeValue(){return this.input.value}setActive(t){if(!t.length)return;this.removeActive(t),this.currentFocus>=t.length&&(this.currentFocus=0),this.currentFocus<0&&(this.currentFocus=t.length-1);const n=t[this.currentFocus];n.classList.add("active"),this.scrollToElement(n)}validate(){if(this.args.column.validator){const t=this.args.column.validator(this.input.value,this.args);if(!t.valid)return t}return{valid:!0,msg:null}}}var ll={exports:{}};const UA=GS(uN);/*!
|
|
349
349
|
* Pikaday
|
|
350
350
|
*
|
|
351
351
|
* Copyright © 2014 David Bushell | BSD & MIT license | https://github.com/Pikaday/Pikaday
|
|
352
|
-
*/var qA=ll.exports,um;function GA(){return um||(um=1,function(e,t){(function(n,o){var r;{try{r=UA}catch{}e.exports=o(r)}})(qA,function(n){var o=typeof n=="function",r=!!window.addEventListener,i=window.document,a=window.setTimeout,l=function(A,M,V,B){r?A.addEventListener(M,V,!!B):A.attachEvent("on"+M,V)},d=function(A,M,V,B){r?A.removeEventListener(M,V,!!B):A.detachEvent("on"+M,V)},u=function(A){return A.trim?A.trim():A.replace(/^\s+|\s+$/g,"")},f=function(A,M){return(" "+A.className+" ").indexOf(" "+M+" ")!==-1},p=function(A,M){f(A,M)||(A.className=A.className===""?M:A.className+" "+M)},y=function(A,M){A.className=u((" "+A.className+" ").replace(" "+M+" "," "))},b=function(A){return/Array/.test(Object.prototype.toString.call(A))},w=function(A){return/Date/.test(Object.prototype.toString.call(A))&&!isNaN(A.getTime())},g=function(A){var M=A.getDay();return M===0||M===6},v=function(A){return A%4===0&&A%100!==0||A%400===0},E=function(A,M){return[31,v(A)?29:28,31,30,31,30,31,31,30,31,30,31][M]},P=function(A){w(A)&&A.setHours(0,0,0,0)},x=function(A,M){return A.getTime()===M.getTime()},S=function(A,M,V){var B,ne;for(B in M)ne=A[B]!==void 0,ne&&typeof M[B]=="object"&&M[B]!==null&&M[B].nodeName===void 0?w(M[B])?V&&(A[B]=new Date(M[B].getTime())):b(M[B])?V&&(A[B]=M[B].slice(0)):A[B]=S({},M[B],V):(V||!ne)&&(A[B]=M[B]);return A},C=function(A,M,V){var B;i.createEvent?(B=i.createEvent("HTMLEvents"),B.initEvent(M,!0,!1),B=S(B,V),A.dispatchEvent(B)):i.createEventObject&&(B=i.createEventObject(),B=S(B,V),A.fireEvent("on"+M,B))},O=function(A){return A.month<0&&(A.year-=Math.ceil(Math.abs(A.month)/12),A.month+=12),A.month>11&&(A.year+=Math.floor(Math.abs(A.month)/12),A.month-=12),A},N={field:null,bound:void 0,ariaLabel:"Use the arrow keys to pick a date",position:"bottom left",reposition:!0,format:"YYYY-MM-DD",toString:null,parse:null,defaultDate:null,setDefaultDate:!1,firstDay:0,firstWeekOfYearMinDays:4,formatStrict:!1,minDate:null,maxDate:null,yearRange:10,showWeekNumber:!1,pickWholeWeek:!1,minYear:0,maxYear:9999,minMonth:void 0,maxMonth:void 0,startRange:null,endRange:null,isRTL:!1,yearSuffix:"",showMonthAfterYear:!1,showDaysInNextAndPreviousMonths:!1,enableSelectionDaysInNextAndPreviousMonths:!1,numberOfMonths:1,mainCalendar:"left",container:void 0,blurFieldOnSelect:!0,i18n:{previousMonth:"Previous Month",nextMonth:"Next Month",months:["January","February","March","April","May","June","July","August","September","October","November","December"],weekdays:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],weekdaysShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"]},theme:null,events:[],onSelect:null,onOpen:null,onClose:null,onDraw:null,keyboardInput:!0},F=function(A,M,V){for(M+=A.firstDay;M>=7;)M-=7;return V?A.i18n.weekdaysShort[M]:A.i18n.weekdays[M]},z=function(A){var M=[],V="false";if(A.isEmpty)if(A.showDaysInNextAndPreviousMonths)M.push("is-outside-current-month"),A.enableSelectionDaysInNextAndPreviousMonths||M.push("is-selection-disabled");else return'<td class="is-empty"></td>';return A.isDisabled&&M.push("is-disabled"),A.isToday&&M.push("is-today"),A.isSelected&&(M.push("is-selected"),V="true"),A.hasEvent&&M.push("has-event"),A.isInRange&&M.push("is-inrange"),A.isStartRange&&M.push("is-startrange"),A.isEndRange&&M.push("is-endrange"),'<td data-day="'+A.day+'" class="'+M.join(" ")+'" aria-selected="'+V+'"><button class="pika-button pika-day" type="button" data-pika-year="'+A.year+'" data-pika-month="'+A.month+'" data-pika-day="'+A.day+'">'+A.day+"</button></td>"},R=function(A,M){A.setHours(0,0,0,0);var V=A.getDate(),B=A.getDay(),ne=M,oe=ne-1,se=7,j=function(ie){return(ie+se-1)%se};A.setDate(V+oe-j(B));var J=new Date(A.getFullYear(),0,ne),ee=24*60*60*1e3,te=(A.getTime()-J.getTime())/ee,ce=1+Math.round((te-oe+j(J.getDay()))/se);return ce},$=function(A,M,V,B){var ne=new Date(V,M,A),oe=o?n(ne).isoWeek():R(ne,B);return'<td class="pika-week">'+oe+"</td>"},K=function(A,M,V,B){return'<tr class="pika-row'+(V?" pick-whole-week":"")+(B?" is-selected":"")+'">'+(M?A.reverse():A).join("")+"</tr>"},X=function(A){return"<tbody>"+A.join("")+"</tbody>"},q=function(A){var M,V=[];for(A.showWeekNumber&&V.push("<th></th>"),M=0;M<7;M++)V.push('<th scope="col"><abbr title="'+F(A,M)+'">'+F(A,M,!0)+"</abbr></th>");return"<thead><tr>"+(A.isRTL?V.reverse():V).join("")+"</tr></thead>"},Y=function(A,M,V,B,ne,oe){var se,j,J,ee=A._o,te=V===ee.minYear,ce=V===ee.maxYear,ie='<div id="'+oe+'" class="pika-title" role="heading" aria-live="assertive">',he,W,re=!0,Q=!0;for(J=[],se=0;se<12;se++)J.push('<option value="'+(V===ne?se-M:12+se-M)+'"'+(se===B?' selected="selected"':"")+(te&&se<ee.minMonth||ce&&se>ee.maxMonth?' disabled="disabled"':"")+">"+ee.i18n.months[se]+"</option>");for(he='<div class="pika-label">'+ee.i18n.months[B]+'<select class="pika-select pika-select-month" tabindex="-1">'+J.join("")+"</select></div>",b(ee.yearRange)?(se=ee.yearRange[0],j=ee.yearRange[1]+1):(se=V-ee.yearRange,j=1+V+ee.yearRange),J=[];se<j&&se<=ee.maxYear;se++)se>=ee.minYear&&J.push('<option value="'+se+'"'+(se===V?' selected="selected"':"")+">"+se+"</option>");return W='<div class="pika-label">'+V+ee.yearSuffix+'<select class="pika-select pika-select-year" tabindex="-1">'+J.join("")+"</select></div>",ee.showMonthAfterYear?ie+=W+he:ie+=he+W,te&&(B===0||ee.minMonth>=B)&&(re=!1),ce&&(B===11||ee.maxMonth<=B)&&(Q=!1),M===0&&(ie+='<button class="pika-prev'+(re?"":" is-disabled")+'" type="button">'+ee.i18n.previousMonth+"</button>"),M===A._o.numberOfMonths-1&&(ie+='<button class="pika-next'+(Q?"":" is-disabled")+'" type="button">'+ee.i18n.nextMonth+"</button>"),ie+="</div>"},H=function(A,M,V){return'<table cellpadding="0" cellspacing="0" class="pika-table" role="grid" aria-labelledby="'+V+'">'+q(A)+X(M)+"</table>"},le=function(A){var M=this,V=M.config(A);M._onMouseDown=function(ne){if(M._v){ne=ne||window.event;var oe=ne.target||ne.srcElement;if(oe)if(f(oe,"is-disabled")||(f(oe,"pika-button")&&!f(oe,"is-empty")&&!f(oe.parentNode,"is-disabled")?(M.setDate(new Date(oe.getAttribute("data-pika-year"),oe.getAttribute("data-pika-month"),oe.getAttribute("data-pika-day"))),V.bound&&a(function(){M.hide(),V.blurFieldOnSelect&&V.field&&V.field.blur()},100)):f(oe,"pika-prev")?M.prevMonth():f(oe,"pika-next")&&M.nextMonth()),f(oe,"pika-select"))M._c=!0;else if(ne.preventDefault)ne.preventDefault();else return ne.returnValue=!1,!1}},M._onChange=function(ne){ne=ne||window.event;var oe=ne.target||ne.srcElement;oe&&(f(oe,"pika-select-month")?M.gotoMonth(oe.value):f(oe,"pika-select-year")&&M.gotoYear(oe.value))},M._onKeyChange=function(ne){if(ne=ne||window.event,M.isVisible())switch(ne.keyCode){case 13:case 27:V.field&&V.field.blur();break;case 37:M.adjustDate("subtract",1);break;case 38:M.adjustDate("subtract",7);break;case 39:M.adjustDate("add",1);break;case 40:M.adjustDate("add",7);break;case 8:case 46:M.setDate(null);break}},M._parseFieldValue=function(){if(V.parse)return V.parse(V.field.value,V.format);if(o){var ne=n(V.field.value,V.format,V.formatStrict);return ne&&ne.isValid()?ne.toDate():null}else return new Date(Date.parse(V.field.value))},M._onInputChange=function(ne){var oe;ne.firedBy!==M&&(oe=M._parseFieldValue(),w(oe)&&M.setDate(oe),M._v||M.show())},M._onInputFocus=function(){M.show()},M._onInputClick=function(){M.show()},M._onInputBlur=function(){var ne=i.activeElement;do if(f(ne,"pika-single"))return;while(ne=ne.parentNode);M._c||(M._b=a(function(){M.hide()},50)),M._c=!1},M._onClick=function(ne){ne=ne||window.event;var oe=ne.target||ne.srcElement,se=oe;if(oe){!r&&f(oe,"pika-select")&&(oe.onchange||(oe.setAttribute("onchange","return;"),l(oe,"change",M._onChange)));do if(f(se,"pika-single")||se===V.trigger)return;while(se=se.parentNode);M._v&&oe!==V.trigger&&se!==V.trigger&&M.hide()}},M.el=i.createElement("div"),M.el.className="pika-single"+(V.isRTL?" is-rtl":"")+(V.theme?" "+V.theme:""),l(M.el,"mousedown",M._onMouseDown,!0),l(M.el,"touchend",M._onMouseDown,!0),l(M.el,"change",M._onChange),V.keyboardInput&&l(i,"keydown",M._onKeyChange),V.field&&(V.container?V.container.appendChild(M.el):V.bound?i.body.appendChild(M.el):V.field.parentNode.insertBefore(M.el,V.field.nextSibling),l(V.field,"change",M._onInputChange),V.defaultDate||(V.defaultDate=M._parseFieldValue(),V.setDefaultDate=!0));var B=V.defaultDate;w(B)?V.setDefaultDate?M.setDate(B,!0):M.gotoDate(B):M.gotoDate(new Date),V.bound?(this.hide(),M.el.className+=" is-bound",l(V.trigger,"click",M._onInputClick),l(V.trigger,"focus",M._onInputFocus),l(V.trigger,"blur",M._onInputBlur)):this.show()};return le.prototype={config:function(A){this._o||(this._o=S({},N,!0));var M=S(this._o,A,!0);M.isRTL=!!M.isRTL,M.field=M.field&&M.field.nodeName?M.field:null,M.theme=typeof M.theme=="string"&&M.theme?M.theme:null,M.bound=!!(M.bound!==void 0?M.field&&M.bound:M.field),M.trigger=M.trigger&&M.trigger.nodeName?M.trigger:M.field,M.disableWeekends=!!M.disableWeekends,M.disableDayFn=typeof M.disableDayFn=="function"?M.disableDayFn:null;var V=parseInt(M.numberOfMonths,10)||1;if(M.numberOfMonths=V>4?4:V,w(M.minDate)||(M.minDate=!1),w(M.maxDate)||(M.maxDate=!1),M.minDate&&M.maxDate&&M.maxDate<M.minDate&&(M.maxDate=M.minDate=!1),M.minDate&&this.setMinDate(M.minDate),M.maxDate&&this.setMaxDate(M.maxDate),b(M.yearRange)){var B=new Date().getFullYear()-10;M.yearRange[0]=parseInt(M.yearRange[0],10)||B,M.yearRange[1]=parseInt(M.yearRange[1],10)||B}else M.yearRange=Math.abs(parseInt(M.yearRange,10))||N.yearRange,M.yearRange>100&&(M.yearRange=100);return M},toString:function(A){return A=A||this._o.format,w(this._d)?this._o.toString?this._o.toString(this._d,A):o?n(this._d).format(A):this._d.toDateString():""},getMoment:function(){return o?n(this._d):null},setMoment:function(A,M){o&&n.isMoment(A)&&this.setDate(A.toDate(),M)},getDate:function(){return w(this._d)?new Date(this._d.getTime()):null},setDate:function(A,M){if(!A)return this._d=null,this._o.field&&(this._o.field.value="",C(this._o.field,"change",{firedBy:this})),this.draw();if(typeof A=="string"&&(A=new Date(Date.parse(A))),!!w(A)){var V=this._o.minDate,B=this._o.maxDate;w(V)&&A<V?A=V:w(B)&&A>B&&(A=B),this._d=new Date(A.getTime()),P(this._d),this.gotoDate(this._d),this._o.field&&(this._o.field.value=this.toString(),C(this._o.field,"change",{firedBy:this})),!M&&typeof this._o.onSelect=="function"&&this._o.onSelect.call(this,this.getDate())}},clear:function(){this.setDate(null)},gotoDate:function(A){var M=!0;if(w(A)){if(this.calendars){var V=new Date(this.calendars[0].year,this.calendars[0].month,1),B=new Date(this.calendars[this.calendars.length-1].year,this.calendars[this.calendars.length-1].month,1),ne=A.getTime();B.setMonth(B.getMonth()+1),B.setDate(B.getDate()-1),M=ne<V.getTime()||B.getTime()<ne}M&&(this.calendars=[{month:A.getMonth(),year:A.getFullYear()}],this._o.mainCalendar==="right"&&(this.calendars[0].month+=1-this._o.numberOfMonths)),this.adjustCalendars()}},adjustDate:function(A,M){var V=this.getDate()||new Date,B=parseInt(M)*24*60*60*1e3,ne;A==="add"?ne=new Date(V.valueOf()+B):A==="subtract"&&(ne=new Date(V.valueOf()-B)),this.setDate(ne)},adjustCalendars:function(){this.calendars[0]=O(this.calendars[0]);for(var A=1;A<this._o.numberOfMonths;A++)this.calendars[A]=O({month:this.calendars[0].month+A,year:this.calendars[0].year});this.draw()},gotoToday:function(){this.gotoDate(new Date)},gotoMonth:function(A){isNaN(A)||(this.calendars[0].month=parseInt(A,10),this.adjustCalendars())},nextMonth:function(){this.calendars[0].month++,this.adjustCalendars()},prevMonth:function(){this.calendars[0].month--,this.adjustCalendars()},gotoYear:function(A){isNaN(A)||(this.calendars[0].year=parseInt(A,10),this.adjustCalendars())},setMinDate:function(A){A instanceof Date?(P(A),this._o.minDate=A,this._o.minYear=A.getFullYear(),this._o.minMonth=A.getMonth()):(this._o.minDate=N.minDate,this._o.minYear=N.minYear,this._o.minMonth=N.minMonth,this._o.startRange=N.startRange),this.draw()},setMaxDate:function(A){A instanceof Date?(P(A),this._o.maxDate=A,this._o.maxYear=A.getFullYear(),this._o.maxMonth=A.getMonth()):(this._o.maxDate=N.maxDate,this._o.maxYear=N.maxYear,this._o.maxMonth=N.maxMonth,this._o.endRange=N.endRange),this.draw()},setStartRange:function(A){this._o.startRange=A},setEndRange:function(A){this._o.endRange=A},draw:function(A){if(!(!this._v&&!A)){var M=this._o,V=M.minYear,B=M.maxYear,ne=M.minMonth,oe=M.maxMonth,se="",j;this._y<=V&&(this._y=V,!isNaN(ne)&&this._m<ne&&(this._m=ne)),this._y>=B&&(this._y=B,!isNaN(oe)&&this._m>oe&&(this._m=oe));for(var J=0;J<M.numberOfMonths;J++)j="pika-title-"+Math.random().toString(36).replace(/[^a-z]+/g,"").substr(0,2),se+='<div class="pika-lendar">'+Y(this,J,this.calendars[J].year,this.calendars[J].month,this.calendars[0].year,j)+this.render(this.calendars[J].year,this.calendars[J].month,j)+"</div>";this.el.innerHTML=se,M.bound&&M.field.type!=="hidden"&&a(function(){M.trigger.focus()},1),typeof this._o.onDraw=="function"&&this._o.onDraw(this),M.bound&&M.field.setAttribute("aria-label",M.ariaLabel)}},adjustPosition:function(){var A,M,V,B,ne,oe,se,j,J,ee,te,ce;if(!this._o.container){if(this.el.style.position="absolute",A=this._o.trigger,M=A,V=this.el.offsetWidth,B=this.el.offsetHeight,ne=window.innerWidth||i.documentElement.clientWidth,oe=window.innerHeight||i.documentElement.clientHeight,se=window.pageYOffset||i.body.scrollTop||i.documentElement.scrollTop,te=!0,ce=!0,typeof A.getBoundingClientRect=="function")ee=A.getBoundingClientRect(),j=ee.left+window.pageXOffset,J=ee.bottom+window.pageYOffset;else for(j=M.offsetLeft,J=M.offsetTop+M.offsetHeight;M=M.offsetParent;)j+=M.offsetLeft,J+=M.offsetTop;(this._o.reposition&&j+V>ne||this._o.position.indexOf("right")>-1&&j-V+A.offsetWidth>0)&&(j=j-V+A.offsetWidth,te=!1),(this._o.reposition&&J+B>oe+se||this._o.position.indexOf("top")>-1&&J-B-A.offsetHeight>0)&&(J=J-B-A.offsetHeight,ce=!1),this.el.style.left=j+"px",this.el.style.top=J+"px",p(this.el,te?"left-aligned":"right-aligned"),p(this.el,ce?"bottom-aligned":"top-aligned"),y(this.el,te?"right-aligned":"left-aligned"),y(this.el,ce?"top-aligned":"bottom-aligned")}},render:function(A,M,V){var B=this._o,ne=new Date,oe=E(A,M),se=new Date(A,M,1).getDay(),j=[],J=[];P(ne),B.firstDay>0&&(se-=B.firstDay,se<0&&(se+=7));for(var ee=M===0?11:M-1,te=M===11?0:M+1,ce=M===0?A-1:A,ie=M===11?A+1:A,he=E(ce,ee),W=oe+se,re=W;re>7;)re-=7;W+=7-re;for(var Q=!1,fe=0,me=0;fe<W;fe++){var Ce=new Date(A,M,1+(fe-se)),ve=w(this._d)?x(Ce,this._d):!1,xe=x(Ce,ne),Ve=B.events.indexOf(Ce.toDateString())!==-1,Ae=fe<se||fe>=oe+se,st=1+(fe-se),Pe=M,ft=A,Kt=B.startRange&&x(B.startRange,Ce),it=B.endRange&&x(B.endRange,Ce),Yt=B.startRange&&B.endRange&&B.startRange<Ce&&Ce<B.endRange,Xt=B.minDate&&Ce<B.minDate||B.maxDate&&Ce>B.maxDate||B.disableWeekends&&g(Ce)||B.disableDayFn&&B.disableDayFn(Ce);Ae&&(fe<se?(st=he+st,Pe=ee,ft=ce):(st=st-oe,Pe=te,ft=ie));var on={day:st,month:Pe,year:ft,hasEvent:Ve,isSelected:ve,isToday:xe,isDisabled:Xt,isEmpty:Ae,isStartRange:Kt,isEndRange:it,isInRange:Yt,showDaysInNextAndPreviousMonths:B.showDaysInNextAndPreviousMonths,enableSelectionDaysInNextAndPreviousMonths:B.enableSelectionDaysInNextAndPreviousMonths};B.pickWholeWeek&&ve&&(Q=!0),J.push(z(on)),++me===7&&(B.showWeekNumber&&J.unshift($(fe-se,M,A,B.firstWeekOfYearMinDays)),j.push(K(J,B.isRTL,B.pickWholeWeek,Q)),J=[],me=0,Q=!1)}return H(B,j,V)},isVisible:function(){return this._v},show:function(){this.isVisible()||(this._v=!0,this.draw(),y(this.el,"is-hidden"),this._o.bound&&(l(i,"click",this._onClick),this.adjustPosition()),typeof this._o.onOpen=="function"&&this._o.onOpen.call(this))},hide:function(){var A=this._v;A!==!1&&(this._o.bound&&d(i,"click",this._onClick),this._o.container||(this.el.style.position="static",this.el.style.left="auto",this.el.style.top="auto"),p(this.el,"is-hidden"),this._v=!1,A!==void 0&&typeof this._o.onClose=="function"&&this._o.onClose.call(this))},destroy:function(){var A=this._o;this.hide(),d(this.el,"mousedown",this._onMouseDown,!0),d(this.el,"touchend",this._onMouseDown,!0),d(this.el,"change",this._onChange),A.keyboardInput&&d(i,"keydown",this._onKeyChange),A.field&&(d(A.field,"change",this._onInputChange),A.bound&&(d(A.trigger,"click",this._onInputClick),d(A.trigger,"focus",this._onInputFocus),d(A.trigger,"blur",this._onInputBlur))),this.el.parentNode&&this.el.parentNode.removeChild(this.el)}},le})}(ll)),ll.exports}GA();function KA(e){return`(${XA(e)})`}function XA(e){return e.replace("-","")}function ZA(e,t={}){const{currencySymbol:n="",decimalPlaces:o=2,decimalSeparator:r=".",negativeClass:i,negativeInParentheses:a=!0,noHTML:l=!1,positiveClass:d,thousandsSeparator:u=",",zeroAsBlank:f=!1}=t;if(e==null||e==="")return"";if(!Number(e)&&f)return"";const p=(Number(e)||0)<0,y=Math.abs(Number(e)||0).toFixed(o),b=parseInt(y).toString(),w=b.length>3?b.length%3:0,v=(w?b.slice(0,w)+u:"")+b.slice(w).replace(/(\d{3})(?=\d)/g,`$1${u}`)+(o?r+y.slice(-o):""),E=`${n}${v}`,P=p?`-${E}`:E,x=p&&a?KA(P):P;return l?x:p?i?`<span class="${i}">${x}</span>`:x:d?`<span class="${d}">${x}</span>`:x}const QA=(e,t)=>{const n=e.sum&&e.sum[t.field];return n!==null?`${e.group.level?"total":"TOTAL"}: ${ZA(n)}`:""};function JA(e){if(!e.getSelectionModel())return hm(e);let t=e.getSelectedRows();return t.sort((n,o)=>n-o),t.length===0&&(t=hm(e)),t}function hm(e){const t=e.getData();return Array.from({length:t.getLength()},(n,o)=>o)}var gc=(e=>(e.slickTable="slick-table",e.sorting="sorting",e))(gc||{});function Sd(){return JSON.parse(localStorage.getItem(gc.slickTable)||"{}")}function _d(e){return e[gc.sorting]||{}}function fm(e,t){localStorage.setItem(gc.slickTable,JSON.stringify({...e,sorting:t}))}class eF{getTableSorting(t){const n=Sd();return _d(n)[t]}resetTableSorting(t){const n=Sd(),o=_d(n);delete o[t],fm(n,o)}setTableSorting(t,n,o){const r=Sd(),i=_d(r);i[t]={columnId:n,isAscending:o},fm(r,i)}}const xd=new eF;class tF{constructor(){this.emptyValue="1/1/1970"}dates(t,n){const o=ms(t||this.emptyValue),r=ms(n||this.emptyValue);return o-r}numbers(t,n){return Number(t||0)-Number(n||0)}stringsNumeric(t,n){return!t&&!n?0:t?n?t.localeCompare(n,void 0,{numeric:!0}):1:-1}strings(t,n){return(t||"").toLowerCase()>(n||"").toLowerCase()?1:(t||"").toLowerCase()<(n||"").toLowerCase()?-1:0}numbersWithSymbols(t,n){const o=Number((t||"0").match(/^\d+/g)?.[0]||0);return Number((n||"0").match(/^\d+/g)?.[0]||0)-o}}const nF=new tF;class Mv{constructor(){this.sort=nF,this.withFormatter=[yo.TEXT,yo.NUMBER_FORMATTED]}getSortFunction(t){let n="",o=!1,r;return(i,a)=>{const{grid:l,sortAsc:d,columnId:u}=a,f=a.sortCol;if(!l||!f)return;const p=f.field;if(!p)return;const y=f.sortAs;if(!y)return;const{formatter:b}=f,w=l.getData();d&&n===f?.id?(o=!0,xd.resetTableSorting(t),l.setSortColumns([]),n=""):(o=!1,n=u,xd.setTableSorting(t,u,d));const g=d?-1:1,v=w.getGrouping(),E=v.find(({getter:P})=>P===f.id);if(E){if(r||(r=v.map(({comparer:P})=>P)),o){const P=w.getGrouping(),x=P.findIndex(({getter:S})=>S===f.id);P[x].comparer=r[x],w.refresh();return}E.comparer=(P,x)=>{let S=P.value,C=x.value;return b&&this.withFormatter.includes(y)&&(S=b(0,0,S,f,null,l),C=b(0,0,C,f,null,l)),this.priority(P,x)||this.compare(S,C,g,y)}}else{const P=w.getItems(),x=w.getIdPropertyName();P.sort((S,C)=>{if(o)return S[x]-C[x];let O=S[p],N=C[p];return b&&this.withFormatter.includes(y)&&(O=b(0,0,O,f,S,l),N=b(0,0,N,f,C,l)),this.priority(S,C)||this.compare(O,N,g,y)})}w.refresh()}}priority(t,n){return 0}restoreSorting(t){const n=t.grid;if(!n)return;const o=xd.getTableSorting(t.id);if(o){const{columnId:r,isAscending:i}=o,a=this.getSortFunction(t.id),l=n.getColumns().find(({id:d})=>d===r);l&&(a(null,{grid:n,columnId:r,sortAsc:i,sortCol:l,sortCols:[]}),document.querySelector(`#${t.id} [data-id="${r}"] .slick-sort-indicator`)?.classList.add(`slick-sort-indicator-${i?"asc":"desc"}`),n.invalidate())}}compare(t,n,o,r){switch(r){case yo.DATE:return this.sort.dates(t,n)*o;case yo.NUMBER:case yo.NUMBER_FORMATTED:return this.sort.numbers(t,n)*o;case yo.TEXT_NUMERIC:return this.sort.stringsNumeric(t,n)*o;case yo.TEXT:return this.sort.strings(t,n)*o;default:return 0}}}const oF=new Mv;class rF{constructor(t,n){this.columnsWithTitle=t,this.columnsWithValue=n}calculate(t){let n=t.getColumns().length;for(;n--;)this.calculateColumn(n,t)}calculateColumn(t,n){const r=n.getColumns()[t].field;this.columnsWithTitle.includes(r)?this.addTitle(n,t):this.columnsWithValue.includes(r)&&this.addTotal(n,t)}addTitle(t,n){const r=t.getColumns()[n].id,i=t.getFooterRowColumn(r);i.textContent="TOTAL:"}addTotal(t,n){const o=t.getColumns()[n],r=o.field,i=t.getData(),a=this.displayedRows(i),l=this.totalAmountOf(a,r),d=t.getFooterRowColumn(r),u=o.formatter;d.textContent=`${u?u(0,0,l,o,null,t):l}`}displayedRows(t){const n=[],o=t.getLength();if(!o)return n;for(let r=0;r<o;r++)n.push(t.getItem(r));return n}totalAmountOf(t,n){return t.reduce((o,r)=>(r.isDeleted||(o+=Number(r[n])||0),o),0)}}function sF(e){const{columnId:t,table:n}=wn;if(!t||!n)return;const o=n.filter.args;o.columnFilters&&(n.filter.args={...o,columnFilters:{...o.columnFilters,[t]:{...o.columnFilters[t],value:e}}},e[1]||e[2]?er.highlightColumn(n,t):er.resetColumn(n,t))}const tr=_y(sF),Is={1:"",2:""},Iv="column_filters",oo={filter:"🔎︎ Filter...",from:"🔎︎ From...",to:"🔎︎ To..."};function iF(e){switch(e){case sn.Boolean:return je.Boolean;case sn.Date:return je.DateEqual;case sn.MultipleSelect:return je.MultipleSelect;case sn.Number:case sn.NumberFormatted:return je.NumberEqual;case sn.Text:return je.TextContain}}function aF(e,t,n){$e.useEffect(()=>{if(!e)return;const o=document.getElementById(Iv);if(!o)return;const{columnId:r,group:i,table:a,x:l,y:d}=wn;if(!a?.grid)return;const f=a.filter.args;Vu(o,l,d);const{filterId:p,value:y}=f.columnFilters?.[r]||{},b=p||iF(i),w=y||Is;a.filter.args={...f,columnFilters:{...f.columnFilters,[r]:{filterId:b,group:i,value:w}}},t(b),n(w)},[e])}function lF(e){$e.useEffect(()=>{function t(){e(!0)}return wn.subscribe(t),()=>{wn.unsubscribe(t)}},[])}function nu(e){return{format:jr.ui,value:e?_e(e,uN):null}}const cF=ae(Ho)({width:"5em",alignSelf:"flex-end"}),dF={Button:cF},uF=({setIsOpened:e,setValue:t,value:n})=>{function o(){const{columnId:r,table:i}=wn;if(!i||!i.grid)return;const l=i.filter.args;delete l.columnFilters?.[r],i.filter.args=l,er.resetColumn(i,r),t(Is),e(!1)}return D.jsx(dF.Button,{disabled:!n[1]&&!n[2],onClick:o,variant:"outlined",size:"small",children:"Reset"})},hF=ae(tc)({padding:0}),fF=ae(cy)({margin:"0.5em 0 0 1em"}),Ua={Checkbox:hF,FormGroup:fF},pF=({setValue:e,value:t})=>{function n(o){e(o),tr(o)}return D.jsxs(Ua.FormGroup,{children:[D.jsx(nl,{control:D.jsx(Ua.Checkbox,{checked:!t[1]&&!t[2],onClick:()=>n({1:"",2:""}),size:"small"}),label:"All"}),D.jsx(nl,{control:D.jsx(Ua.Checkbox,{checked:!!t[1],onClick:()=>n({1:"true",2:""}),size:"small"}),label:"Yes"}),D.jsx(nl,{control:D.jsx(Ua.Checkbox,{checked:!!t[2],onClick:()=>n({1:"",2:"true"}),size:"small"}),label:"No"})]})},mF={Y:"year",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"},E:{sectionType:"weekDay",contentType:"digit",maxLength:1},e:{sectionType:"weekDay",contentType:"digit",maxLength:1},d:{sectionType:"weekDay",contentType:"digit",maxLength:1},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"},gF={year:"YYYY",month:"MMMM",monthShort:"MMM",dayOfMonth:"D",dayOfMonthFull:"Do",weekday:"dddd",weekdayShort:"ddd",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"},pm=["Missing timezone plugin","To be able to use timezones, you have to pass the default export from `moment-timezone` to the `dateLibInstance` prop of `LocalizationProvider`","Find more information on https://mui.com/x/react-date-pickers/timezone/#moment-and-timezone"].join(`
|
|
352
|
+
*/var qA=ll.exports,um;function GA(){return um||(um=1,function(e,t){(function(n,o){var r;{try{r=UA}catch{}e.exports=o(r)}})(qA,function(n){var o=typeof n=="function",r=!!window.addEventListener,i=window.document,a=window.setTimeout,l=function(A,M,V,B){r?A.addEventListener(M,V,!!B):A.attachEvent("on"+M,V)},d=function(A,M,V,B){r?A.removeEventListener(M,V,!!B):A.detachEvent("on"+M,V)},u=function(A){return A.trim?A.trim():A.replace(/^\s+|\s+$/g,"")},f=function(A,M){return(" "+A.className+" ").indexOf(" "+M+" ")!==-1},p=function(A,M){f(A,M)||(A.className=A.className===""?M:A.className+" "+M)},y=function(A,M){A.className=u((" "+A.className+" ").replace(" "+M+" "," "))},b=function(A){return/Array/.test(Object.prototype.toString.call(A))},w=function(A){return/Date/.test(Object.prototype.toString.call(A))&&!isNaN(A.getTime())},g=function(A){var M=A.getDay();return M===0||M===6},v=function(A){return A%4===0&&A%100!==0||A%400===0},E=function(A,M){return[31,v(A)?29:28,31,30,31,30,31,31,30,31,30,31][M]},P=function(A){w(A)&&A.setHours(0,0,0,0)},x=function(A,M){return A.getTime()===M.getTime()},S=function(A,M,V){var B,ne;for(B in M)ne=A[B]!==void 0,ne&&typeof M[B]=="object"&&M[B]!==null&&M[B].nodeName===void 0?w(M[B])?V&&(A[B]=new Date(M[B].getTime())):b(M[B])?V&&(A[B]=M[B].slice(0)):A[B]=S({},M[B],V):(V||!ne)&&(A[B]=M[B]);return A},C=function(A,M,V){var B;i.createEvent?(B=i.createEvent("HTMLEvents"),B.initEvent(M,!0,!1),B=S(B,V),A.dispatchEvent(B)):i.createEventObject&&(B=i.createEventObject(),B=S(B,V),A.fireEvent("on"+M,B))},O=function(A){return A.month<0&&(A.year-=Math.ceil(Math.abs(A.month)/12),A.month+=12),A.month>11&&(A.year+=Math.floor(Math.abs(A.month)/12),A.month-=12),A},N={field:null,bound:void 0,ariaLabel:"Use the arrow keys to pick a date",position:"bottom left",reposition:!0,format:"YYYY-MM-DD",toString:null,parse:null,defaultDate:null,setDefaultDate:!1,firstDay:0,firstWeekOfYearMinDays:4,formatStrict:!1,minDate:null,maxDate:null,yearRange:10,showWeekNumber:!1,pickWholeWeek:!1,minYear:0,maxYear:9999,minMonth:void 0,maxMonth:void 0,startRange:null,endRange:null,isRTL:!1,yearSuffix:"",showMonthAfterYear:!1,showDaysInNextAndPreviousMonths:!1,enableSelectionDaysInNextAndPreviousMonths:!1,numberOfMonths:1,mainCalendar:"left",container:void 0,blurFieldOnSelect:!0,i18n:{previousMonth:"Previous Month",nextMonth:"Next Month",months:["January","February","March","April","May","June","July","August","September","October","November","December"],weekdays:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],weekdaysShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"]},theme:null,events:[],onSelect:null,onOpen:null,onClose:null,onDraw:null,keyboardInput:!0},F=function(A,M,V){for(M+=A.firstDay;M>=7;)M-=7;return V?A.i18n.weekdaysShort[M]:A.i18n.weekdays[M]},z=function(A){var M=[],V="false";if(A.isEmpty)if(A.showDaysInNextAndPreviousMonths)M.push("is-outside-current-month"),A.enableSelectionDaysInNextAndPreviousMonths||M.push("is-selection-disabled");else return'<td class="is-empty"></td>';return A.isDisabled&&M.push("is-disabled"),A.isToday&&M.push("is-today"),A.isSelected&&(M.push("is-selected"),V="true"),A.hasEvent&&M.push("has-event"),A.isInRange&&M.push("is-inrange"),A.isStartRange&&M.push("is-startrange"),A.isEndRange&&M.push("is-endrange"),'<td data-day="'+A.day+'" class="'+M.join(" ")+'" aria-selected="'+V+'"><button class="pika-button pika-day" type="button" data-pika-year="'+A.year+'" data-pika-month="'+A.month+'" data-pika-day="'+A.day+'">'+A.day+"</button></td>"},R=function(A,M){A.setHours(0,0,0,0);var V=A.getDate(),B=A.getDay(),ne=M,oe=ne-1,se=7,j=function(ie){return(ie+se-1)%se};A.setDate(V+oe-j(B));var J=new Date(A.getFullYear(),0,ne),ee=24*60*60*1e3,te=(A.getTime()-J.getTime())/ee,ce=1+Math.round((te-oe+j(J.getDay()))/se);return ce},$=function(A,M,V,B){var ne=new Date(V,M,A),oe=o?n(ne).isoWeek():R(ne,B);return'<td class="pika-week">'+oe+"</td>"},K=function(A,M,V,B){return'<tr class="pika-row'+(V?" pick-whole-week":"")+(B?" is-selected":"")+'">'+(M?A.reverse():A).join("")+"</tr>"},X=function(A){return"<tbody>"+A.join("")+"</tbody>"},q=function(A){var M,V=[];for(A.showWeekNumber&&V.push("<th></th>"),M=0;M<7;M++)V.push('<th scope="col"><abbr title="'+F(A,M)+'">'+F(A,M,!0)+"</abbr></th>");return"<thead><tr>"+(A.isRTL?V.reverse():V).join("")+"</tr></thead>"},Y=function(A,M,V,B,ne,oe){var se,j,J,ee=A._o,te=V===ee.minYear,ce=V===ee.maxYear,ie='<div id="'+oe+'" class="pika-title" role="heading" aria-live="assertive">',he,W,re=!0,Q=!0;for(J=[],se=0;se<12;se++)J.push('<option value="'+(V===ne?se-M:12+se-M)+'"'+(se===B?' selected="selected"':"")+(te&&se<ee.minMonth||ce&&se>ee.maxMonth?' disabled="disabled"':"")+">"+ee.i18n.months[se]+"</option>");for(he='<div class="pika-label">'+ee.i18n.months[B]+'<select class="pika-select pika-select-month" tabindex="-1">'+J.join("")+"</select></div>",b(ee.yearRange)?(se=ee.yearRange[0],j=ee.yearRange[1]+1):(se=V-ee.yearRange,j=1+V+ee.yearRange),J=[];se<j&&se<=ee.maxYear;se++)se>=ee.minYear&&J.push('<option value="'+se+'"'+(se===V?' selected="selected"':"")+">"+se+"</option>");return W='<div class="pika-label">'+V+ee.yearSuffix+'<select class="pika-select pika-select-year" tabindex="-1">'+J.join("")+"</select></div>",ee.showMonthAfterYear?ie+=W+he:ie+=he+W,te&&(B===0||ee.minMonth>=B)&&(re=!1),ce&&(B===11||ee.maxMonth<=B)&&(Q=!1),M===0&&(ie+='<button class="pika-prev'+(re?"":" is-disabled")+'" type="button">'+ee.i18n.previousMonth+"</button>"),M===A._o.numberOfMonths-1&&(ie+='<button class="pika-next'+(Q?"":" is-disabled")+'" type="button">'+ee.i18n.nextMonth+"</button>"),ie+="</div>"},H=function(A,M,V){return'<table cellpadding="0" cellspacing="0" class="pika-table" role="grid" aria-labelledby="'+V+'">'+q(A)+X(M)+"</table>"},le=function(A){var M=this,V=M.config(A);M._onMouseDown=function(ne){if(M._v){ne=ne||window.event;var oe=ne.target||ne.srcElement;if(oe)if(f(oe,"is-disabled")||(f(oe,"pika-button")&&!f(oe,"is-empty")&&!f(oe.parentNode,"is-disabled")?(M.setDate(new Date(oe.getAttribute("data-pika-year"),oe.getAttribute("data-pika-month"),oe.getAttribute("data-pika-day"))),V.bound&&a(function(){M.hide(),V.blurFieldOnSelect&&V.field&&V.field.blur()},100)):f(oe,"pika-prev")?M.prevMonth():f(oe,"pika-next")&&M.nextMonth()),f(oe,"pika-select"))M._c=!0;else if(ne.preventDefault)ne.preventDefault();else return ne.returnValue=!1,!1}},M._onChange=function(ne){ne=ne||window.event;var oe=ne.target||ne.srcElement;oe&&(f(oe,"pika-select-month")?M.gotoMonth(oe.value):f(oe,"pika-select-year")&&M.gotoYear(oe.value))},M._onKeyChange=function(ne){if(ne=ne||window.event,M.isVisible())switch(ne.keyCode){case 13:case 27:V.field&&V.field.blur();break;case 37:M.adjustDate("subtract",1);break;case 38:M.adjustDate("subtract",7);break;case 39:M.adjustDate("add",1);break;case 40:M.adjustDate("add",7);break;case 8:case 46:M.setDate(null);break}},M._parseFieldValue=function(){if(V.parse)return V.parse(V.field.value,V.format);if(o){var ne=n(V.field.value,V.format,V.formatStrict);return ne&&ne.isValid()?ne.toDate():null}else return new Date(Date.parse(V.field.value))},M._onInputChange=function(ne){var oe;ne.firedBy!==M&&(oe=M._parseFieldValue(),w(oe)&&M.setDate(oe),M._v||M.show())},M._onInputFocus=function(){M.show()},M._onInputClick=function(){M.show()},M._onInputBlur=function(){var ne=i.activeElement;do if(f(ne,"pika-single"))return;while(ne=ne.parentNode);M._c||(M._b=a(function(){M.hide()},50)),M._c=!1},M._onClick=function(ne){ne=ne||window.event;var oe=ne.target||ne.srcElement,se=oe;if(oe){!r&&f(oe,"pika-select")&&(oe.onchange||(oe.setAttribute("onchange","return;"),l(oe,"change",M._onChange)));do if(f(se,"pika-single")||se===V.trigger)return;while(se=se.parentNode);M._v&&oe!==V.trigger&&se!==V.trigger&&M.hide()}},M.el=i.createElement("div"),M.el.className="pika-single"+(V.isRTL?" is-rtl":"")+(V.theme?" "+V.theme:""),l(M.el,"mousedown",M._onMouseDown,!0),l(M.el,"touchend",M._onMouseDown,!0),l(M.el,"change",M._onChange),V.keyboardInput&&l(i,"keydown",M._onKeyChange),V.field&&(V.container?V.container.appendChild(M.el):V.bound?i.body.appendChild(M.el):V.field.parentNode.insertBefore(M.el,V.field.nextSibling),l(V.field,"change",M._onInputChange),V.defaultDate||(V.defaultDate=M._parseFieldValue(),V.setDefaultDate=!0));var B=V.defaultDate;w(B)?V.setDefaultDate?M.setDate(B,!0):M.gotoDate(B):M.gotoDate(new Date),V.bound?(this.hide(),M.el.className+=" is-bound",l(V.trigger,"click",M._onInputClick),l(V.trigger,"focus",M._onInputFocus),l(V.trigger,"blur",M._onInputBlur)):this.show()};return le.prototype={config:function(A){this._o||(this._o=S({},N,!0));var M=S(this._o,A,!0);M.isRTL=!!M.isRTL,M.field=M.field&&M.field.nodeName?M.field:null,M.theme=typeof M.theme=="string"&&M.theme?M.theme:null,M.bound=!!(M.bound!==void 0?M.field&&M.bound:M.field),M.trigger=M.trigger&&M.trigger.nodeName?M.trigger:M.field,M.disableWeekends=!!M.disableWeekends,M.disableDayFn=typeof M.disableDayFn=="function"?M.disableDayFn:null;var V=parseInt(M.numberOfMonths,10)||1;if(M.numberOfMonths=V>4?4:V,w(M.minDate)||(M.minDate=!1),w(M.maxDate)||(M.maxDate=!1),M.minDate&&M.maxDate&&M.maxDate<M.minDate&&(M.maxDate=M.minDate=!1),M.minDate&&this.setMinDate(M.minDate),M.maxDate&&this.setMaxDate(M.maxDate),b(M.yearRange)){var B=new Date().getFullYear()-10;M.yearRange[0]=parseInt(M.yearRange[0],10)||B,M.yearRange[1]=parseInt(M.yearRange[1],10)||B}else M.yearRange=Math.abs(parseInt(M.yearRange,10))||N.yearRange,M.yearRange>100&&(M.yearRange=100);return M},toString:function(A){return A=A||this._o.format,w(this._d)?this._o.toString?this._o.toString(this._d,A):o?n(this._d).format(A):this._d.toDateString():""},getMoment:function(){return o?n(this._d):null},setMoment:function(A,M){o&&n.isMoment(A)&&this.setDate(A.toDate(),M)},getDate:function(){return w(this._d)?new Date(this._d.getTime()):null},setDate:function(A,M){if(!A)return this._d=null,this._o.field&&(this._o.field.value="",C(this._o.field,"change",{firedBy:this})),this.draw();if(typeof A=="string"&&(A=new Date(Date.parse(A))),!!w(A)){var V=this._o.minDate,B=this._o.maxDate;w(V)&&A<V?A=V:w(B)&&A>B&&(A=B),this._d=new Date(A.getTime()),P(this._d),this.gotoDate(this._d),this._o.field&&(this._o.field.value=this.toString(),C(this._o.field,"change",{firedBy:this})),!M&&typeof this._o.onSelect=="function"&&this._o.onSelect.call(this,this.getDate())}},clear:function(){this.setDate(null)},gotoDate:function(A){var M=!0;if(w(A)){if(this.calendars){var V=new Date(this.calendars[0].year,this.calendars[0].month,1),B=new Date(this.calendars[this.calendars.length-1].year,this.calendars[this.calendars.length-1].month,1),ne=A.getTime();B.setMonth(B.getMonth()+1),B.setDate(B.getDate()-1),M=ne<V.getTime()||B.getTime()<ne}M&&(this.calendars=[{month:A.getMonth(),year:A.getFullYear()}],this._o.mainCalendar==="right"&&(this.calendars[0].month+=1-this._o.numberOfMonths)),this.adjustCalendars()}},adjustDate:function(A,M){var V=this.getDate()||new Date,B=parseInt(M)*24*60*60*1e3,ne;A==="add"?ne=new Date(V.valueOf()+B):A==="subtract"&&(ne=new Date(V.valueOf()-B)),this.setDate(ne)},adjustCalendars:function(){this.calendars[0]=O(this.calendars[0]);for(var A=1;A<this._o.numberOfMonths;A++)this.calendars[A]=O({month:this.calendars[0].month+A,year:this.calendars[0].year});this.draw()},gotoToday:function(){this.gotoDate(new Date)},gotoMonth:function(A){isNaN(A)||(this.calendars[0].month=parseInt(A,10),this.adjustCalendars())},nextMonth:function(){this.calendars[0].month++,this.adjustCalendars()},prevMonth:function(){this.calendars[0].month--,this.adjustCalendars()},gotoYear:function(A){isNaN(A)||(this.calendars[0].year=parseInt(A,10),this.adjustCalendars())},setMinDate:function(A){A instanceof Date?(P(A),this._o.minDate=A,this._o.minYear=A.getFullYear(),this._o.minMonth=A.getMonth()):(this._o.minDate=N.minDate,this._o.minYear=N.minYear,this._o.minMonth=N.minMonth,this._o.startRange=N.startRange),this.draw()},setMaxDate:function(A){A instanceof Date?(P(A),this._o.maxDate=A,this._o.maxYear=A.getFullYear(),this._o.maxMonth=A.getMonth()):(this._o.maxDate=N.maxDate,this._o.maxYear=N.maxYear,this._o.maxMonth=N.maxMonth,this._o.endRange=N.endRange),this.draw()},setStartRange:function(A){this._o.startRange=A},setEndRange:function(A){this._o.endRange=A},draw:function(A){if(!(!this._v&&!A)){var M=this._o,V=M.minYear,B=M.maxYear,ne=M.minMonth,oe=M.maxMonth,se="",j;this._y<=V&&(this._y=V,!isNaN(ne)&&this._m<ne&&(this._m=ne)),this._y>=B&&(this._y=B,!isNaN(oe)&&this._m>oe&&(this._m=oe));for(var J=0;J<M.numberOfMonths;J++)j="pika-title-"+Math.random().toString(36).replace(/[^a-z]+/g,"").substr(0,2),se+='<div class="pika-lendar">'+Y(this,J,this.calendars[J].year,this.calendars[J].month,this.calendars[0].year,j)+this.render(this.calendars[J].year,this.calendars[J].month,j)+"</div>";this.el.innerHTML=se,M.bound&&M.field.type!=="hidden"&&a(function(){M.trigger.focus()},1),typeof this._o.onDraw=="function"&&this._o.onDraw(this),M.bound&&M.field.setAttribute("aria-label",M.ariaLabel)}},adjustPosition:function(){var A,M,V,B,ne,oe,se,j,J,ee,te,ce;if(!this._o.container){if(this.el.style.position="absolute",A=this._o.trigger,M=A,V=this.el.offsetWidth,B=this.el.offsetHeight,ne=window.innerWidth||i.documentElement.clientWidth,oe=window.innerHeight||i.documentElement.clientHeight,se=window.pageYOffset||i.body.scrollTop||i.documentElement.scrollTop,te=!0,ce=!0,typeof A.getBoundingClientRect=="function")ee=A.getBoundingClientRect(),j=ee.left+window.pageXOffset,J=ee.bottom+window.pageYOffset;else for(j=M.offsetLeft,J=M.offsetTop+M.offsetHeight;M=M.offsetParent;)j+=M.offsetLeft,J+=M.offsetTop;(this._o.reposition&&j+V>ne||this._o.position.indexOf("right")>-1&&j-V+A.offsetWidth>0)&&(j=j-V+A.offsetWidth,te=!1),(this._o.reposition&&J+B>oe+se||this._o.position.indexOf("top")>-1&&J-B-A.offsetHeight>0)&&(J=J-B-A.offsetHeight,ce=!1),this.el.style.left=j+"px",this.el.style.top=J+"px",p(this.el,te?"left-aligned":"right-aligned"),p(this.el,ce?"bottom-aligned":"top-aligned"),y(this.el,te?"right-aligned":"left-aligned"),y(this.el,ce?"top-aligned":"bottom-aligned")}},render:function(A,M,V){var B=this._o,ne=new Date,oe=E(A,M),se=new Date(A,M,1).getDay(),j=[],J=[];P(ne),B.firstDay>0&&(se-=B.firstDay,se<0&&(se+=7));for(var ee=M===0?11:M-1,te=M===11?0:M+1,ce=M===0?A-1:A,ie=M===11?A+1:A,he=E(ce,ee),W=oe+se,re=W;re>7;)re-=7;W+=7-re;for(var Q=!1,fe=0,me=0;fe<W;fe++){var Ce=new Date(A,M,1+(fe-se)),ve=w(this._d)?x(Ce,this._d):!1,xe=x(Ce,ne),Ve=B.events.indexOf(Ce.toDateString())!==-1,Ae=fe<se||fe>=oe+se,st=1+(fe-se),Pe=M,ft=A,Kt=B.startRange&&x(B.startRange,Ce),it=B.endRange&&x(B.endRange,Ce),Yt=B.startRange&&B.endRange&&B.startRange<Ce&&Ce<B.endRange,Xt=B.minDate&&Ce<B.minDate||B.maxDate&&Ce>B.maxDate||B.disableWeekends&&g(Ce)||B.disableDayFn&&B.disableDayFn(Ce);Ae&&(fe<se?(st=he+st,Pe=ee,ft=ce):(st=st-oe,Pe=te,ft=ie));var on={day:st,month:Pe,year:ft,hasEvent:Ve,isSelected:ve,isToday:xe,isDisabled:Xt,isEmpty:Ae,isStartRange:Kt,isEndRange:it,isInRange:Yt,showDaysInNextAndPreviousMonths:B.showDaysInNextAndPreviousMonths,enableSelectionDaysInNextAndPreviousMonths:B.enableSelectionDaysInNextAndPreviousMonths};B.pickWholeWeek&&ve&&(Q=!0),J.push(z(on)),++me===7&&(B.showWeekNumber&&J.unshift($(fe-se,M,A,B.firstWeekOfYearMinDays)),j.push(K(J,B.isRTL,B.pickWholeWeek,Q)),J=[],me=0,Q=!1)}return H(B,j,V)},isVisible:function(){return this._v},show:function(){this.isVisible()||(this._v=!0,this.draw(),y(this.el,"is-hidden"),this._o.bound&&(l(i,"click",this._onClick),this.adjustPosition()),typeof this._o.onOpen=="function"&&this._o.onOpen.call(this))},hide:function(){var A=this._v;A!==!1&&(this._o.bound&&d(i,"click",this._onClick),this._o.container||(this.el.style.position="static",this.el.style.left="auto",this.el.style.top="auto"),p(this.el,"is-hidden"),this._v=!1,A!==void 0&&typeof this._o.onClose=="function"&&this._o.onClose.call(this))},destroy:function(){var A=this._o;this.hide(),d(this.el,"mousedown",this._onMouseDown,!0),d(this.el,"touchend",this._onMouseDown,!0),d(this.el,"change",this._onChange),A.keyboardInput&&d(i,"keydown",this._onKeyChange),A.field&&(d(A.field,"change",this._onInputChange),A.bound&&(d(A.trigger,"click",this._onInputClick),d(A.trigger,"focus",this._onInputFocus),d(A.trigger,"blur",this._onInputBlur))),this.el.parentNode&&this.el.parentNode.removeChild(this.el)}},le})}(ll)),ll.exports}GA();function KA(e){return`(${XA(e)})`}function XA(e){return e.replace("-","")}function ZA(e,t={}){const{currencySymbol:n="",decimalPlaces:o=2,decimalSeparator:r=".",negativeClass:i,negativeInParentheses:a=!0,noHTML:l=!1,positiveClass:d,thousandsSeparator:u=",",zeroAsBlank:f=!1}=t;if(e==null||e==="")return"";if(!Number(e)&&f)return"";const p=(Number(e)||0)<0,y=Math.abs(Number(e)||0).toFixed(o),b=parseInt(y).toString(),w=b.length>3?b.length%3:0,v=(w?b.slice(0,w)+u:"")+b.slice(w).replace(/(\d{3})(?=\d)/g,`$1${u}`)+(o?r+y.slice(-o):""),E=`${n}${v}`,P=p?`-${E}`:E,x=p&&a?KA(P):P;return l?x:p?i?`<span class="${i}">${x}</span>`:x:d?`<span class="${d}">${x}</span>`:x}const QA=(e,t)=>{const n=e.sum&&e.sum[t.field];return n!==null?`${e.group.level?"total":"TOTAL"}: ${ZA(n)}`:""};function JA(e){if(!e.getSelectionModel())return hm(e);let t=e.getSelectedRows();return t.sort((n,o)=>n-o),t.length===0&&(t=hm(e)),t}function hm(e){const t=e.getData();return Array.from({length:t.getLength()},(n,o)=>o)}var gc=(e=>(e.slickTable="slick-table",e.sorting="sorting",e))(gc||{});function Sd(){return JSON.parse(localStorage.getItem(gc.slickTable)||"{}")}function _d(e){return e[gc.sorting]||{}}function fm(e,t){localStorage.setItem(gc.slickTable,JSON.stringify({...e,sorting:t}))}class eF{getTableSorting(t){const n=Sd();return _d(n)[t]}resetTableSorting(t){const n=Sd(),o=_d(n);delete o[t],fm(n,o)}setTableSorting(t,n,o){const r=Sd(),i=_d(r);i[t]={columnId:n,isAscending:o},fm(r,i)}}const xd=new eF;class tF{constructor(){this.emptyValue="1/1/1970"}dates(t,n){const o=ms(t||this.emptyValue),r=ms(n||this.emptyValue);return o-r}numbers(t,n){return Number(t||0)-Number(n||0)}stringsNumeric(t,n){return!t&&!n?0:t?n?t.localeCompare(n,void 0,{numeric:!0}):1:-1}strings(t,n){return(t||"").toLowerCase()>(n||"").toLowerCase()?1:(t||"").toLowerCase()<(n||"").toLowerCase()?-1:0}numbersWithSymbols(t,n){const o=Number((t||"0").match(/^\d+/g)?.[0]||0);return Number((n||"0").match(/^\d+/g)?.[0]||0)-o}}const nF=new tF;class Mv{constructor(){this.sort=nF,this.withFormatter=[yo.TEXT,yo.NUMBER_FORMATTED]}getSortFunction(t){let n="",o=!1,r;return(i,a)=>{const{grid:l,sortAsc:d,columnId:u}=a,f=a.sortCol;if(!l||!f)return;const p=f.field;if(!p)return;const y=f.sortAs;if(!y)return;const{formatter:b}=f,w=l.getData();d&&n===f?.id?(o=!0,xd.resetTableSorting(t),l.setSortColumns([]),n=""):(o=!1,n=u,xd.setTableSorting(t,u,d));const g=d?-1:1,v=w.getGrouping(),E=v.find(({getter:P})=>P===f.id);if(E){if(r||(r=v.map(({comparer:P})=>P)),o){const P=w.getGrouping(),x=P.findIndex(({getter:S})=>S===f.id);P[x].comparer=r[x],w.refresh();return}E.comparer=(P,x)=>{let S=P.value,C=x.value;return b&&this.withFormatter.includes(y)&&(S=b(0,0,S,f,null,l),C=b(0,0,C,f,null,l)),this.priority(P,x)||this.compare(S,C,g,y)}}else{const P=w.getItems(),x=w.getIdPropertyName();P.sort((S,C)=>{if(o)return S[x]-C[x];let O=S[p],N=C[p];return b&&this.withFormatter.includes(y)&&(O=b(0,0,O,f,S,l),N=b(0,0,N,f,C,l)),this.priority(S,C)||this.compare(O,N,g,y)})}w.refresh()}}priority(t,n){return 0}restoreSorting(t){const n=t.grid;if(!n)return;const o=xd.getTableSorting(t.id);if(o){const{columnId:r,isAscending:i}=o,a=this.getSortFunction(t.id),l=n.getColumns().find(({id:d})=>d===r);l&&(a(null,{grid:n,columnId:r,sortAsc:i,sortCol:l,sortCols:[]}),document.querySelector(`#${t.id} [data-id="${r}"] .slick-sort-indicator`)?.classList.add(`slick-sort-indicator-${i?"asc":"desc"}`),n.invalidate())}}compare(t,n,o,r){switch(r){case yo.DATE:return this.sort.dates(t,n)*o;case yo.NUMBER:case yo.NUMBER_FORMATTED:return this.sort.numbers(t,n)*o;case yo.TEXT_NUMERIC:return this.sort.stringsNumeric(t,n)*o;case yo.TEXT:return this.sort.strings(t,n)*o;default:return 0}}}const oF=new Mv;class rF{constructor(t,n){this.columnsWithTitle=t,this.columnsWithValue=n}calculate(t){let n=t.getColumns().length;for(;n--;)this.calculateColumn(n,t)}calculateColumn(t,n){const r=n.getColumns()[t].field;this.columnsWithTitle.includes(r)?this.addTitle(n,t):this.columnsWithValue.includes(r)&&this.addTotal(n,t)}addTitle(t,n){const r=t.getColumns()[n].id,i=t.getFooterRowColumn(r);i.textContent="TOTAL:"}addTotal(t,n){const o=t.getColumns()[n],r=o.field,i=t.getData(),a=this.displayedRows(i),l=this.totalAmountOf(a,r),d=t.getFooterRowColumn(r),u=o.formatter;d.textContent=`${u?u(0,0,l,o,null,t):l}`}displayedRows(t){const n=[],o=t.getLength();if(!o)return n;for(let r=0;r<o;r++)n.push(t.getItem(r));return n}totalAmountOf(t,n){return t.reduce((o,r)=>(r.isDeleted||(o+=Number(r[n])||0),o),0)}}function sF(e){const{columnId:t,table:n}=wn;if(!t||!n)return;const o=n.filter.args;o.columnFilters&&(n.filter.args={...o,columnFilters:{...o.columnFilters,[t]:{...o.columnFilters[t],value:e}}},e[1]||e[2]?er.highlightColumn(n,t):er.resetColumn(n,t))}const tr=_y(sF),Is={1:"",2:""},Iv="column_filters",oo={filter:"🔎︎ Filter...",from:"🔎︎ From...",to:"🔎︎ To..."};function iF(e){switch(e){case sn.Boolean:return je.Boolean;case sn.Date:return je.DateEqual;case sn.MultipleSelect:return je.MultipleSelect;case sn.Number:case sn.NumberFormatted:return je.NumberEqual;case sn.Text:return je.TextContain}}function aF(e,t,n){$e.useEffect(()=>{if(!e)return;const o=document.getElementById(Iv);if(!o)return;const{columnId:r,group:i,table:a,x:l,y:d}=wn;if(!a?.grid)return;const f=a.filter.args;Vu(o,l,d);const{filterId:p,value:y}=f.columnFilters?.[r]||{},b=p||iF(i),w=y||Is;a.filter.args={...f,columnFilters:{...f.columnFilters,[r]:{filterId:b,group:i,value:w}}},t(b),n(w)},[e])}function lF(e){$e.useEffect(()=>{function t(){e(!0)}return wn.subscribe(t),()=>{wn.unsubscribe(t)}},[])}function nu(e){return{format:jr.ui,value:e?_e(e,hN):null}}const cF=ae(Ho)({width:"5em",alignSelf:"flex-end"}),dF={Button:cF},uF=({setIsOpened:e,setValue:t,value:n})=>{function o(){const{columnId:r,table:i}=wn;if(!i||!i.grid)return;const l=i.filter.args;delete l.columnFilters?.[r],i.filter.args=l,er.resetColumn(i,r),t(Is),e(!1)}return D.jsx(dF.Button,{disabled:!n[1]&&!n[2],onClick:o,variant:"outlined",size:"small",children:"Reset"})},hF=ae(tc)({padding:0}),fF=ae(cy)({margin:"0.5em 0 0 1em"}),Ua={Checkbox:hF,FormGroup:fF},pF=({setValue:e,value:t})=>{function n(o){e(o),tr(o)}return D.jsxs(Ua.FormGroup,{children:[D.jsx(nl,{control:D.jsx(Ua.Checkbox,{checked:!t[1]&&!t[2],onClick:()=>n({1:"",2:""}),size:"small"}),label:"All"}),D.jsx(nl,{control:D.jsx(Ua.Checkbox,{checked:!!t[1],onClick:()=>n({1:"true",2:""}),size:"small"}),label:"Yes"}),D.jsx(nl,{control:D.jsx(Ua.Checkbox,{checked:!!t[2],onClick:()=>n({1:"",2:"true"}),size:"small"}),label:"No"})]})},mF={Y:"year",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"},E:{sectionType:"weekDay",contentType:"digit",maxLength:1},e:{sectionType:"weekDay",contentType:"digit",maxLength:1},d:{sectionType:"weekDay",contentType:"digit",maxLength:1},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"},gF={year:"YYYY",month:"MMMM",monthShort:"MMM",dayOfMonth:"D",dayOfMonthFull:"Do",weekday:"dddd",weekdayShort:"ddd",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"},pm=["Missing timezone plugin","To be able to use timezones, you have to pass the default export from `moment-timezone` to the `dateLibInstance` prop of `LocalizationProvider`","Find more information on https://mui.com/x/react-date-pickers/timezone/#moment-and-timezone"].join(`
|
|
353
353
|
`);class Nv{constructor({locale:t,formats:n,instance:o}={}){this.isMUIAdapter=!0,this.isTimezoneCompatible=!0,this.lib="moment",this.moment=void 0,this.locale=void 0,this.formats=void 0,this.escapedCharacters={start:"[",end:"]"},this.formatTokenMap=mF,this.setLocaleToValue=r=>{const i=this.getCurrentLocaleCode();return i===r.locale()?r:r.locale(i)},this.hasTimezonePlugin=()=>typeof this.moment.tz<"u",this.createSystemDate=r=>{const i=this.moment(r).local();return this.locale===void 0?i:i.locale(this.locale)},this.createUTCDate=r=>{const i=this.moment.utc(r);return this.locale===void 0?i:i.locale(this.locale)},this.createTZDate=(r,i)=>{if(!this.hasTimezonePlugin())throw new Error(pm);const a=i==="default"?this.moment(r):this.moment.tz(r,i);return this.locale===void 0?a:a.locale(this.locale)},this.date=(r,i="default")=>r===null?null:i==="UTC"?this.createUTCDate(r):i==="system"||i==="default"&&!this.hasTimezonePlugin()?this.createSystemDate(r):this.createTZDate(r,i),this.getInvalidDate=()=>this.moment(new Date("Invalid Date")),this.getTimezone=r=>{const i=r._z?.name,a=r.isUTC()?"UTC":"system";return i??this.moment.defaultZone?.name??a},this.setTimezone=(r,i)=>{if(this.getTimezone(r)===i)return r;if(i==="UTC")return r.clone().utc();if(i==="system")return r.clone().local();if(!this.hasTimezonePlugin()){if(i!=="default")throw new Error(pm);return r}const a=i==="default"?this.moment.defaultZone?.name??"system":i;if(a==="system")return r.clone().local();const l=r.clone();return l.tz(a),l},this.toJsDate=r=>r.toDate(),this.parse=(r,i)=>r===""?null:this.locale?this.moment(r,i,this.locale,!0):this.moment(r,i,!0),this.getCurrentLocaleCode=()=>this.locale||_e.locale(),this.is12HourCycleInCurrentLocale=()=>/A|a/.test(_e.localeData(this.getCurrentLocaleCode()).longDateFormat("LT")),this.expandFormat=r=>{const i=/(\[[^[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})|./g;return r.match(i).map(a=>{const l=a[0];return l==="L"||l===";"?_e.localeData(this.getCurrentLocaleCode()).longDateFormat(a):a}).join("")},this.isValid=r=>r==null?!1:r.isValid(),this.format=(r,i)=>this.formatByString(r,this.formats[i]),this.formatByString=(r,i)=>{const a=r.clone();return a.locale(this.getCurrentLocaleCode()),a.format(i)},this.formatNumber=r=>r,this.isEqual=(r,i)=>r===null&&i===null?!0:r===null||i===null?!1:r.isSame(i),this.isSameYear=(r,i)=>r.isSame(i,"year"),this.isSameMonth=(r,i)=>r.isSame(i,"month"),this.isSameDay=(r,i)=>r.isSame(i,"day"),this.isSameHour=(r,i)=>r.isSame(i,"hour"),this.isAfter=(r,i)=>r.isAfter(i),this.isAfterYear=(r,i)=>r.isAfter(i,"year"),this.isAfterDay=(r,i)=>r.isAfter(i,"day"),this.isBefore=(r,i)=>r.isBefore(i),this.isBeforeYear=(r,i)=>r.isBefore(i,"year"),this.isBeforeDay=(r,i)=>r.isBefore(i,"day"),this.isWithinRange=(r,[i,a])=>r.isBetween(i,a,null,"[]"),this.startOfYear=r=>r.clone().startOf("year"),this.startOfMonth=r=>r.clone().startOf("month"),this.startOfWeek=r=>this.setLocaleToValue(r.clone()).startOf("week"),this.startOfDay=r=>r.clone().startOf("day"),this.endOfYear=r=>r.clone().endOf("year"),this.endOfMonth=r=>r.clone().endOf("month"),this.endOfWeek=r=>this.setLocaleToValue(r.clone()).endOf("week"),this.endOfDay=r=>r.clone().endOf("day"),this.addYears=(r,i)=>i<0?r.clone().subtract(Math.abs(i),"years"):r.clone().add(i,"years"),this.addMonths=(r,i)=>i<0?r.clone().subtract(Math.abs(i),"months"):r.clone().add(i,"months"),this.addWeeks=(r,i)=>i<0?r.clone().subtract(Math.abs(i),"weeks"):r.clone().add(i,"weeks"),this.addDays=(r,i)=>i<0?r.clone().subtract(Math.abs(i),"days"):r.clone().add(i,"days"),this.addHours=(r,i)=>i<0?r.clone().subtract(Math.abs(i),"hours"):r.clone().add(i,"hours"),this.addMinutes=(r,i)=>i<0?r.clone().subtract(Math.abs(i),"minutes"):r.clone().add(i,"minutes"),this.addSeconds=(r,i)=>i<0?r.clone().subtract(Math.abs(i),"seconds"):r.clone().add(i,"seconds"),this.getYear=r=>r.get("year"),this.getMonth=r=>r.get("month"),this.getDate=r=>r.get("date"),this.getHours=r=>r.get("hours"),this.getMinutes=r=>r.get("minutes"),this.getSeconds=r=>r.get("seconds"),this.getMilliseconds=r=>r.get("milliseconds"),this.setYear=(r,i)=>r.clone().year(i),this.setMonth=(r,i)=>r.clone().month(i),this.setDate=(r,i)=>r.clone().date(i),this.setHours=(r,i)=>r.clone().hours(i),this.setMinutes=(r,i)=>r.clone().minutes(i),this.setSeconds=(r,i)=>r.clone().seconds(i),this.setMilliseconds=(r,i)=>r.clone().milliseconds(i),this.getDaysInMonth=r=>r.daysInMonth(),this.getWeekArray=r=>{const i=this.startOfWeek(this.startOfMonth(r)),a=this.endOfWeek(this.endOfMonth(r));let l=0,d=i;const u=[];for(;d.isBefore(a);){const f=Math.floor(l/7);u[f]=u[f]||[],u[f].push(d),d=this.addDays(d,1),l+=1}return u},this.getWeekNumber=r=>r.week(),this.getDayOfWeek=r=>r.day()+1,this.moment=o||_e,this.locale=t,this.formats=Z({},gF,n)}getYearRange([t,n]){const o=this.startOfYear(t),r=this.endOfYear(n),i=[];let a=o;for(;this.isBefore(a,r);)i.push(a),a=this.addYears(a,1);return i}}const di=(e,t)=>e.length!==t.length?!1:t.every(n=>e.includes(n)),yF=({openTo:e,defaultOpenTo:t,views:n,defaultViews:o})=>{const r=n??o;let i;if(e!=null)i=e;else if(r.includes(t))i=t;else if(r.length>0)i=r[0];else throw new Error("MUI X: The `views` prop must contain at least one view.");return{views:r,openTo:i}},Tl=(e,t,n)=>{let o=t;return o=e.setHours(o,e.getHours(n)),o=e.setMinutes(o,e.getMinutes(n)),o=e.setSeconds(o,e.getSeconds(n)),o=e.setMilliseconds(o,e.getMilliseconds(n)),o},Ei=({date:e,disableFuture:t,disablePast:n,maxDate:o,minDate:r,isDateDisabled:i,utils:a,timezone:l})=>{const d=Tl(a,a.date(void 0,l),e);n&&a.isBefore(r,d)&&(r=d),t&&a.isAfter(o,d)&&(o=d);let u=e,f=e;for(a.isBefore(e,r)&&(u=r,f=null),a.isAfter(e,o)&&(f&&(f=o),u=null);u||f;){if(u&&a.isAfter(u,o)&&(u=null),f&&a.isBefore(f,r)&&(f=null),u){if(!i(u))return u;u=a.addDays(u,1)}if(f){if(!i(f))return f;f=a.addDays(f,-1)}}return null},vF=(e,t)=>t==null||!e.isValid(t)?null:t,Xn=(e,t,n)=>t==null||!e.isValid(t)?n:t,bF=(e,t,n)=>!e.isValid(t)&&t!=null&&!e.isValid(n)&&n!=null?!0:e.isEqual(t,n),ph=(e,t)=>{const o=[e.startOfYear(t)];for(;o.length<12;){const r=o[o.length-1];o.push(e.addMonths(r,1))}return o},Av=(e,t,n)=>n==="date"?e.startOfDay(e.date(void 0,t)):e.date(void 0,t),wF=["year","month","day"],mm=e=>wF.includes(e),mh=(e,{format:t,views:n},o)=>{if(t!=null)return t;const r=e.formats;return di(n,["year"])?r.year:di(n,["month"])?r.month:di(n,["day"])?r.dayOfMonth:di(n,["month","year"])?`${r.month} ${r.year}`:di(n,["day","month"])?`${r.month} ${r.dayOfMonth}`:o?/en/.test(e.getCurrentLocaleCode())?r.normalDateWithWeekday:r.normalDate:r.keyboardDate},CF=(e,t)=>{const n=e.startOfWeek(t);return[0,1,2,3,4,5,6].map(o=>e.addDays(n,o))},SF=["hours","minutes","seconds"],_F=e=>SF.includes(e),gm=(e,t)=>t.getHours(e)*3600+t.getMinutes(e)*60+t.getSeconds(e),xF=(e,t)=>(n,o)=>e?t.isAfter(n,o):gm(n,t)>gm(o,t),wo={year:1,month:2,day:3,hours:4,minutes:5,seconds:6,milliseconds:7},RF=e=>Math.max(...e.map(t=>wo[t.type]??1)),ui=(e,t,n)=>{if(t===wo.year)return e.startOfYear(n);if(t===wo.month)return e.startOfMonth(n);if(t===wo.day)return e.startOfDay(n);let o=n;return t<wo.minutes&&(o=e.setMinutes(o,0)),t<wo.seconds&&(o=e.setSeconds(o,0)),t<wo.milliseconds&&(o=e.setMilliseconds(o,0)),o},kF=({props:e,utils:t,granularity:n,timezone:o,getTodayDate:r})=>{let i=r?r():ui(t,n,Av(t,o));e.minDate!=null&&t.isAfterDay(e.minDate,i)&&(i=ui(t,n,e.minDate)),e.maxDate!=null&&t.isBeforeDay(e.maxDate,i)&&(i=ui(t,n,e.maxDate));const a=xF(e.disableIgnoringDatePartForTimeValidation??!1,t);return e.minTime!=null&&a(e.minTime,i)&&(i=ui(t,n,e.disableIgnoringDatePartForTimeValidation?e.minTime:Tl(t,i,e.minTime))),e.maxTime!=null&&a(i,e.maxTime)&&(i=ui(t,n,e.disableIgnoringDatePartForTimeValidation?e.maxTime:Tl(t,i,e.maxTime))),i},gh=(e,t)=>{const n=e.formatTokenMap[t];if(n==null)throw new Error([`MUI X: The token "${t}" 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(`
|
|
354
354
|
`));return typeof n=="string"?{type:n,contentType:n==="meridiem"?"letter":"digit",maxLength:void 0}:{type:n.sectionType,contentType:n.contentType,maxLength:n.maxLength}},TF=e=>{switch(e){case"ArrowUp":return 1;case"ArrowDown":return-1;case"PageUp":return 5;case"PageDown":return-5;default:return 0}},yc=(e,t)=>{const n=[],o=e.date(void 0,"default"),r=e.startOfWeek(o),i=e.endOfWeek(o);let a=r;for(;e.isBefore(a,i);)n.push(a),a=e.addDays(a,1);return n.map(l=>e.formatByString(l,t))},Fv=(e,t,n,o)=>{switch(n){case"month":return ph(e,e.date(void 0,t)).map(r=>e.formatByString(r,o));case"weekDay":return yc(e,o);case"meridiem":{const r=e.date(void 0,t);return[e.startOfDay(r),e.endOfDay(r)].map(i=>e.formatByString(i,o))}default:return[]}},ym="s",EF=["0","1","2","3","4","5","6","7","8","9"],PF=e=>{const t=e.date(void 0);return e.formatByString(e.setSeconds(t,0),ym)==="0"?EF:Array.from({length:10}).map((o,r)=>e.formatByString(e.setSeconds(t,r),ym))},Br=(e,t)=>{if(t[0]==="0")return e;const n=[];let o="";for(let r=0;r<e.length;r+=1){o+=e[r];const i=t.indexOf(o);i>-1&&(n.push(i.toString()),o="")}return n.join("")},yh=(e,t)=>t[0]==="0"?e:e.split("").map(n=>t[Number(n)]).join(""),vm=(e,t)=>{const n=Br(e,t);return n!==" "&&!Number.isNaN(Number(n))},Lv=(e,t)=>{let n=e;for(n=Number(n).toString();n.length<t;)n=`0${n}`;return n},$v=(e,t,n,o,r)=>{if(process.env.NODE_ENV!=="production"&&r.type!=="day"&&r.contentType==="digit-with-letter")throw new Error([`MUI X: The token "${r.format}" is a digit format with letter in it.'
|
|
355
355
|
This type of format is only supported for 'day' sections`].join(`
|
|
@@ -360,4 +360,4 @@ Expecting `+ce.join(", ")+", got '"+(this.terminals_[B]||B)+"'":ie="Parse error
|
|
|
360
360
|
`):e;km.has(n)||(km.add(n),t==="error"?console.error(n):console.warn(n))}const wL=({open:e,onOpen:t,onClose:n})=>{const o=k.useRef(typeof e=="boolean").current,[r,i]=k.useState(!1);k.useEffect(()=>{if(o){if(typeof e!="boolean")throw new Error("You must not mix controlling and uncontrolled mode for `open` prop");i(e)}},[o,e]);const a=k.useCallback(l=>{o||i(l),l&&t&&t(),!l&&n&&n()},[o,t,n]);return{isOpen:r,setIsOpen:a}},bh=({timezone:e,value:t,defaultValue:n,onChange:o,valueManager:r})=>{const i=Nt(),a=k.useRef(n),l=t??a.current??r.emptyValue,d=k.useMemo(()=>r.getTimezone(i,l),[i,r,l]),u=ke(b=>d==null?b:r.setTimezone(i,d,b)),f=e??d??"default",p=k.useMemo(()=>r.setTimezone(i,f,l),[r,i,f,l]),y=ke((b,...w)=>{const g=u(b);o?.(g,...w)});return{value:p,handleValueChange:y,timezone:f}},wh=({name:e,timezone:t,value:n,defaultValue:o,onChange:r,valueManager:i})=>{const[a,l]=ko({name:e,state:"value",controlled:n,default:o??i.emptyValue}),d=ke((u,...f)=>{l(u),r?.(u,...f)});return bh({timezone:t,value:a,defaultValue:void 0,onChange:d,valueManager:i})},CL=e=>{const{action:t,hasChanged:n,dateState:o,isControlled:r}=e,i=!r&&!o.hasBeenModifiedSinceMount;return t.name==="setValueFromField"?!0:t.name==="setValueFromAction"?i&&["accept","today","clear"].includes(t.pickerAction)?!0:n(o.lastPublishedValue):t.name==="setValueFromView"&&t.selectionState!=="shallow"||t.name==="setValueFromShortcut"?i?!0:n(o.lastPublishedValue):!1},SL=e=>{const{action:t,hasChanged:n,dateState:o,isControlled:r,closeOnSelect:i}=e,a=!r&&!o.hasBeenModifiedSinceMount;return t.name==="setValueFromAction"?a&&["accept","today","clear"].includes(t.pickerAction)?!0:n(o.lastCommittedValue):t.name==="setValueFromView"&&t.selectionState==="finish"&&i?a?!0:n(o.lastCommittedValue):t.name==="setValueFromShortcut"?t.changeImportance==="accept"&&n(o.lastCommittedValue):!1},_L=e=>{const{action:t,closeOnSelect:n}=e;return t.name==="setValueFromAction"?!0:t.name==="setValueFromView"?t.selectionState==="finish"&&n:t.name==="setValueFromShortcut"?t.changeImportance==="accept":!1},xL=({props:e,valueManager:t,valueType:n,wrapperVariant:o,validator:r})=>{const{onAccept:i,onChange:a,value:l,defaultValue:d,closeOnSelect:u=o==="desktop",timezone:f}=e,{current:p}=k.useRef(d),{current:y}=k.useRef(l!==void 0);process.env.NODE_ENV!=="production"&&(k.useEffect(()=>{y!==(l!==void 0)&&console.error([`MUI X: A component is changing the ${y?"":"un"}controlled value of a picker to be ${y?"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(`
|
|
361
361
|
`))},[l]),k.useEffect(()=>{!y&&p!==d&&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(`
|
|
362
362
|
`))},[JSON.stringify(p)]));const b=Nt(),w=Yr(),{isOpen:g,setIsOpen:v}=wL(e),{timezone:E,value:P,handleValueChange:x}=bh({timezone:f,value:l,defaultValue:p,onChange:a,valueManager:t}),[S,C]=k.useState(()=>{let j;return P!==void 0?j=P:p!==void 0?j=p:j=t.emptyValue,{draft:j,lastPublishedValue:j,lastCommittedValue:j,lastControlledValue:P,hasBeenModifiedSinceMount:!1}}),{getValidationErrorForNewValue:O}=qv({props:e,validator:r,timezone:E,value:S.draft,onError:e.onError}),N=ke(j=>{const J={action:j,dateState:S,hasChanged:W=>!t.areValuesEqual(b,j.value,W),isControlled:y,closeOnSelect:u},ee=CL(J),te=SL(J),ce=_L(J);C(W=>Z({},W,{draft:j.value,lastPublishedValue:ee?j.value:W.lastPublishedValue,lastCommittedValue:te?j.value:W.lastCommittedValue,hasBeenModifiedSinceMount:!0}));let ie=null;const he=()=>(ie||(ie={validationError:j.name==="setValueFromField"?j.context.validationError:O(j.value)},j.name==="setValueFromShortcut"&&(ie.shortcut=j.shortcut)),ie);ee&&x(j.value,he()),te&&i&&i(j.value,he()),ce&&v(!1)});if(P!==void 0&&(S.lastControlledValue===void 0||!t.areValuesEqual(b,S.lastControlledValue,P))){const j=t.areValuesEqual(b,S.draft,P);C(J=>Z({},J,{lastControlledValue:P},j?{}:{lastCommittedValue:P,lastPublishedValue:P,draft:P,hasBeenModifiedSinceMount:!0}))}const F=ke(()=>{N({value:t.emptyValue,name:"setValueFromAction",pickerAction:"clear"})}),z=ke(()=>{N({value:S.lastPublishedValue,name:"setValueFromAction",pickerAction:"accept"})}),R=ke(()=>{N({value:S.lastPublishedValue,name:"setValueFromAction",pickerAction:"dismiss"})}),$=ke(()=>{N({value:S.lastCommittedValue,name:"setValueFromAction",pickerAction:"cancel"})}),K=ke(()=>{N({value:t.getTodayValue(b,E,n),name:"setValueFromAction",pickerAction:"today"})}),X=ke(j=>{j.preventDefault(),v(!0)}),q=ke(j=>{j?.preventDefault(),v(!1)}),Y=ke((j,J="partial")=>N({name:"setValueFromView",value:j,selectionState:J})),H=ke((j,J,ee)=>N({name:"setValueFromShortcut",value:j,changeImportance:J,shortcut:ee})),le=ke((j,J)=>N({name:"setValueFromField",value:j,context:J})),A={onClear:F,onAccept:z,onDismiss:R,onCancel:$,onSetToday:K,onOpen:X,onClose:q},M={value:S.draft,onChange:le},V=k.useMemo(()=>t.cleanValue(b,S.draft),[b,t,S.draft]),B={value:V,onChange:Y,onClose:q,open:g},oe=Z({},A,{value:V,onChange:Y,onSelectShortcut:H,isValid:j=>{const J=r({adapter:w,value:j,timezone:E,props:e});return!t.hasError(J)}}),se=k.useMemo(()=>({onOpen:X,onClose:q,open:g}),[g,q,X]);return{open:g,fieldProps:M,viewProps:B,layoutProps:oe,actions:A,contextValue:se}};let Rd=!1;function Kv({onChange:e,onViewChange:t,openTo:n,view:o,views:r,autoFocus:i,focusedView:a,onFocusedViewChange:l}){process.env.NODE_ENV!=="production"&&(Rd||(o!=null&&!r.includes(o)&&(console.warn(`MUI X: \`view="${o}"\` is not a valid prop.`,`It must be an element of \`views=["${r.join('", "')}"]\`.`),Rd=!0),o==null&&n!=null&&!r.includes(n)&&(console.warn(`MUI X: \`openTo="${n}"\` is not a valid prop.`,`It must be an element of \`views=["${r.join('", "')}"]\`.`),Rd=!0)));const d=k.useRef(n),u=k.useRef(r),f=k.useRef(r.includes(n)?n:r[0]),[p,y]=ko({name:"useViews",state:"view",controlled:o,default:f.current}),b=k.useRef(i?p:null),[w,g]=ko({name:"useViews",state:"focusedView",controlled:a,default:b.current});k.useEffect(()=>{(d.current&&d.current!==n||u.current&&u.current.some(N=>!r.includes(N)))&&(y(r.includes(n)?n:r[0]),u.current=r,d.current=n)},[n,y,p,r]);const v=r.indexOf(p),E=r[v-1]??null,P=r[v+1]??null,x=ke((N,F)=>{g(F?N:z=>N===z?null:z),l?.(N,F)}),S=ke(N=>{x(N,!0),N!==p&&(y(N),t&&t(N))}),C=ke(()=>{P&&S(P)}),O=ke((N,F,z)=>{const R=F==="finish",$=z?r.indexOf(z)<r.length-1:!!P;if(e(N,R&&$?"partial":F,z),z&&z!==p){const X=r[r.indexOf(z)+1];X&&S(X)}else R&&C()});return{view:p,setView:S,focusedView:w,setFocusedView:x,nextView:P,previousView:E,defaultView:r.includes(n)?n:r[0],goToNextView:C,setValueAndGoToNextView:O}}const RL=["className","sx"],kL=({props:e,propsFromPickerValue:t,additionalViewProps:n,autoFocusView:o,rendererInterceptor:r,fieldRef:i})=>{const{onChange:a,open:l,onClose:d}=t,{view:u,views:f,openTo:p,onViewChange:y,viewRenderers:b,timezone:w}=e,g=We(e,RL),{view:v,setView:E,defaultView:P,focusedView:x,setFocusedView:S,setValueAndGoToNextView:C}=Kv({view:u,views:f,openTo:p,onChange:a,onViewChange:y,autoFocus:o}),{hasUIView:O,viewModeLookup:N}=k.useMemo(()=>f.reduce((q,Y)=>{let H;return b[Y]!=null?H="UI":H="field",q.viewModeLookup[Y]=H,H==="UI"&&(q.hasUIView=!0),q},{hasUIView:!1,viewModeLookup:{}}),[b,f]),F=k.useMemo(()=>f.reduce((q,Y)=>b[Y]!=null&&_F(Y)?q+1:q,0),[b,f]),z=N[v],R=ke(()=>z==="UI"),[$,K]=k.useState(z==="UI"?v:null);return $!==v&&N[v]==="UI"&&K(v),nn(()=>{z==="field"&&l&&(d(),setTimeout(()=>{i?.current?.setSelectedSections(v),i?.current?.focusField(v)}))},[v]),nn(()=>{if(!l)return;let q=v;z==="field"&&$!=null&&(q=$),q!==P&&N[q]==="UI"&&N[P]==="UI"&&(q=P),q!==v&&E(q),S(q,!0)},[l]),{hasUIView:O,shouldRestoreFocus:R,layoutProps:{views:f,view:$,onViewChange:E},renderCurrentView:()=>{if($==null)return null;const q=b[$];if(q==null)return null;const Y=Z({},g,n,t,{views:f,timezone:w,onChange:C,view:$,onViewChange:E,focusedView:x,onFocusedViewChange:S,showViewSwitcher:F>1,timeViewsCount:F});return r?r(b,$,Y):q(Y)}}};function Tm(){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 TL=(e,t)=>{const[n,o]=k.useState(Tm);return nn(()=>{const i=()=>{o(Tm())};return window.addEventListener("orientationchange",i),()=>{window.removeEventListener("orientationchange",i)}},[]),iL(e,["hours","minutes","seconds"])?!1:(t||n)==="landscape"},EL=({props:e,propsFromPickerValue:t,propsFromPickerViews:n,wrapperVariant:o})=>{const{orientation:r}=e,i=TL(n.views,r),a=lo();return{layoutProps:Z({},n,t,{isLandscape:i,isRtl:a,wrapperVariant:o,disabled:e.disabled,readOnly:e.readOnly})}};function PL(e){const{props:t,pickerValueResponse:n}=e;return k.useMemo(()=>({value:n.viewProps.value,open:n.open,disabled:t.disabled??!1,readOnly:t.readOnly??!1}),[n.viewProps.value,n.open,t.disabled,t.readOnly])}const Xv=({props:e,valueManager:t,valueType:n,wrapperVariant:o,additionalViewProps:r,validator:i,autoFocusView:a,rendererInterceptor:l,fieldRef:d})=>{process.env.NODE_ENV!=="production"&&e.renderInput!=null&&bL(["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=xL({props:e,valueManager:t,valueType:n,wrapperVariant:o,validator:i}),f=kL({props:e,additionalViewProps:r,autoFocusView:a,fieldRef:d,propsFromPickerValue:u.viewProps,rendererInterceptor:l}),p=EL({props:e,wrapperVariant:o,propsFromPickerValue:u.layoutProps,propsFromPickerViews:f.layoutProps}),y=PL({props:e,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:y}};function Zv(e){return Oe("MuiPickersLayout",e)}const kr=De("MuiPickersLayout",["root","landscape","contentWrapper","toolbar","actionBar","tabs","shortcuts"]),DL=["onAccept","onClear","onCancel","onSetToday","actions"];function Qv(e){const{onAccept:t,onClear:n,onCancel:o,onSetToday:r,actions:i}=e,a=We(e,DL),l=rr();if(i==null||i.length===0)return null;const d=i?.map(u=>{switch(u){case"clear":return D.jsx(Ho,{onClick:n,children:l.clearButtonLabel},u);case"cancel":return D.jsx(Ho,{onClick:o,children:l.cancelButtonLabel},u);case"accept":return D.jsx(Ho,{onClick:t,children:l.okButtonLabel},u);case"today":return D.jsx(Ho,{onClick:r,children:l.todayButtonLabel},u);default:return null}});return D.jsx(ay,Z({},a,{children:d}))}process.env.NODE_ENV!=="production"&&(Qv.propTypes={actions:s.arrayOf(s.oneOf(["accept","cancel","clear","today"]).isRequired),disableSpacing:s.bool,onAccept:s.func.isRequired,onCancel:s.func.isRequired,onClear:s.func.isRequired,onSetToday:s.func.isRequired,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object])});const Xi=36,wc=2,Cc=320,OL=280,Ch=336,ML=["items","changeImportance","isLandscape","onChange","isValid"],IL=["getValue"];function Jv(e){const{items:t,changeImportance:n="accept",onChange:o,isValid:r}=e,i=We(e,ML);if(t==null||t.length===0)return null;const a=t.map(l=>{let{getValue:d}=l,u=We(l,IL);const f=d({isValid:r});return Z({},u,{label:u.label,onClick:()=>{o(f,n,u)},disabled:!r(f)})});return D.jsx(Au,Z({dense:!0,sx:[{maxHeight:Ch,maxWidth:200,overflow:"auto"},...Array.isArray(i.sx)?i.sx:[i.sx]]},i,{children:a.map(l=>D.jsx(uy,{children:D.jsx(Jg,Z({},l))},l.id??l.label))}))}process.env.NODE_ENV!=="production"&&(Jv.propTypes={changeImportance:s.oneOf(["accept","set"]),className:s.string,component:s.elementType,dense:s.bool,disablePadding:s.bool,isLandscape:s.bool.isRequired,isValid:s.func.isRequired,items:s.arrayOf(s.shape({getValue:s.func.isRequired,id:s.string,label:s.string.isRequired})),onChange:s.func.isRequired,style:s.object,subheader:s.node,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object])});function NL(e){return e.view!==null}const AL=e=>{const{classes:t,isLandscape:n}=e;return Me({root:["root",n&&"landscape"],contentWrapper:["contentWrapper"],toolbar:["toolbar"],actionBar:["actionBar"],tabs:["tabs"],landscape:["landscape"],shortcuts:["shortcuts"]},Zv,t)},FL=e=>{const{wrapperVariant:t,onAccept:n,onClear:o,onCancel:r,onSetToday:i,view:a,views:l,onViewChange:d,value:u,onChange:f,onSelectShortcut:p,isValid:y,isLandscape:b,disabled:w,readOnly:g,children:v,slots:E,slotProps:P}=e,x=AL(e),S=E?.actionBar??Qv,C=dt({elementType:S,externalSlotProps:P?.actionBar,additionalProps:{onAccept:n,onClear:o,onCancel:r,onSetToday:i,actions:t==="desktop"?[]:["cancel","accept"]},className:x.actionBar,ownerState:Z({},e,{wrapperVariant:t})}),O=D.jsx(S,Z({},C)),N=E?.toolbar,F=dt({elementType:N,externalSlotProps:P?.toolbar,additionalProps:{isLandscape:b,onChange:f,value:u,view:a,onViewChange:d,views:l,disabled:w,readOnly:g},className:x.toolbar,ownerState:Z({},e,{wrapperVariant:t})}),z=NL(F)&&N?D.jsx(N,Z({},F)):null,R=v,$=E?.tabs,K=a&&$?D.jsx($,Z({view:a,onViewChange:d,className:x.tabs},P?.tabs)):null,X=E?.shortcuts??Jv,q=dt({elementType:X,externalSlotProps:P?.shortcuts,additionalProps:{isValid:y,isLandscape:b,onChange:p},className:x.shortcuts,ownerState:{isValid:y,isLandscape:b,onChange:p,wrapperVariant:t}}),Y=a&&X?D.jsx(X,Z({},q)):null;return{toolbar:z,content:R,tabs:K,actionBar:O,shortcuts:Y}},LL=e=>{const{isLandscape:t,classes:n}=e;return Me({root:["root",t&&"landscape"],contentWrapper:["contentWrapper"]},Zv,n)},$L=ae("div",{name:"MuiPickersLayout",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"grid",gridAutoColumns:"max-content auto max-content",gridAutoRows:"max-content auto max-content",[`& .${kr.actionBar}`]:{gridColumn:"1 / 4",gridRow:3},variants:[{props:{isLandscape:!0},style:{[`& .${kr.toolbar}`]:{gridColumn:1,gridRow:"2 / 3"},[`.${kr.shortcuts}`]:{gridColumn:"2 / 4",gridRow:1}}},{props:{isLandscape:!0,isRtl:!0},style:{[`& .${kr.toolbar}`]:{gridColumn:3}}},{props:{isLandscape:!1},style:{[`& .${kr.toolbar}`]:{gridColumn:"2 / 4",gridRow:1},[`& .${kr.shortcuts}`]:{gridColumn:1,gridRow:"2 / 3"}}},{props:{isLandscape:!1,isRtl:!0},style:{[`& .${kr.shortcuts}`]:{gridColumn:3}}}]}),VL=ae("div",{name:"MuiPickersLayout",slot:"ContentWrapper",overridesResolver:(e,t)=>t.contentWrapper})({gridColumn:2,gridRow:2,display:"flex",flexDirection:"column"}),Sh=k.forwardRef(function(t,n){const o=Mt({props:t,name:"MuiPickersLayout"}),{toolbar:r,content:i,tabs:a,actionBar:l,shortcuts:d}=FL(o),{sx:u,className:f,isLandscape:p,wrapperVariant:y}=o,b=LL(o);return D.jsxs($L,{ref:n,sx:u,className:Se(b.root,f),ownerState:o,children:[p?d:r,p?r:d,D.jsx(VL,{className:b.contentWrapper,children:y==="desktop"?D.jsxs(k.Fragment,{children:[i,a]}):D.jsxs(k.Fragment,{children:[a,i]})}),l]})});process.env.NODE_ENV!=="production"&&(Sh.propTypes={children:s.node,classes:s.object,className:s.string,disabled:s.bool,isLandscape:s.bool.isRequired,isRtl:s.bool.isRequired,isValid:s.func.isRequired,onAccept:s.func.isRequired,onCancel:s.func.isRequired,onChange:s.func.isRequired,onClear:s.func.isRequired,onClose:s.func.isRequired,onDismiss:s.func.isRequired,onOpen:s.func.isRequired,onSelectShortcut:s.func.isRequired,onSetToday:s.func.isRequired,onViewChange:s.func.isRequired,orientation:s.oneOf(["landscape","portrait"]),readOnly:s.bool,slotProps:s.object,slots:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),value:s.any,view:s.oneOf(["day","hours","meridiem","minutes","month","seconds","year"]),views:s.arrayOf(s.oneOf(["day","hours","meridiem","minutes","month","seconds","year"]).isRequired).isRequired,wrapperVariant:s.oneOf(["desktop","mobile"])});const jL=k.createContext(null);function eb(e){const{contextValue:t,localeText:n,children:o}=e;return D.jsx(jL.Provider,{value:t,children:D.jsx(vc,{localeText:n,children:o})})}const BL=["props","getOpenDialogAriaText"],WL=["ownerState"],HL=["ownerState"],zL=e=>{let{props:t,getOpenDialogAriaText:n}=e,o=We(e,BL);const{slots:r,slotProps:i,className:a,sx:l,format:d,formatDensity:u,enableAccessibleFieldDOMStructure:f,selectedSections:p,onSelectedSectionsChange:y,timezone:b,name:w,label:g,inputRef:v,readOnly:E,disabled:P,autoFocus:x,localeText:S,reduceAnimations:C}=t,O=k.useRef(null),N=k.useRef(null),F=yr(),z=i?.toolbar?.hidden??!1,{open:R,actions:$,hasUIView:K,layoutProps:X,renderCurrentView:q,shouldRestoreFocus:Y,fieldProps:H,contextValue:le,ownerState:A}=Xv(Z({},o,{props:t,fieldRef:N,autoFocusView:!0,additionalViewProps:{},wrapperVariant:"desktop"})),M=r.inputAdornment??Nu,V=dt({elementType:M,externalSlotProps:i?.inputAdornment,additionalProps:{position:"end"},ownerState:t}),B=We(V,WL),ne=r.openPickerButton??$s,oe=dt({elementType:ne,externalSlotProps:i?.openPickerButton,additionalProps:{disabled:P||E,onClick:R?$.onClose:$.onOpen,"aria-label":n(H.value),edge:B.position},ownerState:t}),se=We(oe,HL),j=r.openPickerIcon,J=dt({elementType:j,externalSlotProps:i?.openPickerIcon,ownerState:A}),ee=r.field,te=dt({elementType:ee,externalSlotProps:i?.field,additionalProps:Z({},H,z&&{id:F},{readOnly:E,disabled:P,className:a,sx:l,format:d,formatDensity:u,enableAccessibleFieldDOMStructure:f,selectedSections:p,onSelectedSectionsChange:y,timezone:b,label:g,name:w,autoFocus:x&&!t.open,focused:R?!0:void 0},v?{inputRef:v}:{}),ownerState:t});K&&(te.InputProps=Z({},te.InputProps,{ref:O},!t.disableOpenPicker&&{[`${B.position}Adornment`]:D.jsx(M,Z({},B,{children:D.jsx(ne,Z({},se,{children:D.jsx(j,Z({},J))}))}))}));const ce=Z({textField:r.textField,clearIcon:r.clearIcon,clearButton:r.clearButton},te.slots),ie=r.layout??Sh;let he=F;z&&(g?he=`${F}-label`:he=void 0);const W=Z({},i,{toolbar:Z({},i?.toolbar,{titleId:F}),popper:Z({"aria-labelledby":he},i?.popper)}),re=at(N,te.unstableFieldRef);return{renderPicker:()=>D.jsxs(eb,{contextValue:le,localeText:S,children:[D.jsx(ee,Z({},te,{slots:ce,slotProps:W,unstableFieldRef:re})),D.jsx(vL,Z({role:"dialog",placement:"bottom-start",anchorEl:O.current},$,{open:R,slots:r,slotProps:W,shouldRestoreFocus:Y,reduceAnimations:C,children:D.jsx(ie,Z({},X,W?.layout,{slots:r,slotProps:W,children:q()}))}))]})}},YL=an(D.jsx("path",{d:"M7 10l5 5 5-5z"}),"ArrowDropDown"),UL=an(D.jsx("path",{d:"M15.41 16.59L10.83 12l4.58-4.59L14 6l-6 6 6 6 1.41-1.41z"}),"ArrowLeft"),qL=an(D.jsx("path",{d:"M8.59 16.59L13.17 12 8.59 7.41 10 6l6 6-6 6-1.41-1.41z"}),"ArrowRight"),GL=an(D.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");an(D.jsxs(k.Fragment,{children:[D.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"}),D.jsx("path",{d:"M12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z"})]}),"Clock");an(D.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");an(D.jsxs(k.Fragment,{children:[D.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"}),D.jsx("path",{d:"M12.5 7H11v6l5.25 3.15.75-1.23-4.5-2.67z"})]}),"Time");const KL=an(D.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"),XL=({utils:e,format:t})=>{let n=10,o=t,r=e.expandFormat(t);for(;r!==o;)if(o=r,r=e.expandFormat(o),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 r},ZL=({utils:e,expandedFormat:t})=>{const n=[],{start:o,end:r}=e.escapedCharacters,i=new RegExp(`(\\${o}[^\\${r}]*\\${r})+`,"g");let a=null;for(;a=i.exec(t);)n.push({start:a.index,end:i.lastIndex-1});return n},QL=(e,t,n,o)=>{switch(n.type){case"year":return t.fieldYearPlaceholder({digitAmount:e.formatByString(e.date(void 0,"default"),o).length,format:o});case"month":return t.fieldMonthPlaceholder({contentType:n.contentType,format:o});case"day":return t.fieldDayPlaceholder({format:o});case"weekDay":return t.fieldWeekDayPlaceholder({contentType:n.contentType,format:o});case"hours":return t.fieldHoursPlaceholder({format:o});case"minutes":return t.fieldMinutesPlaceholder({format:o});case"seconds":return t.fieldSecondsPlaceholder({format:o});case"meridiem":return t.fieldMeridiemPlaceholder({format:o});default:return o}},JL=({utils:e,date:t,shouldRespectLeadingZeros:n,localeText:o,localizedDigits:r,now:i,token:a,startSeparator:l})=>{if(a==="")throw new Error("MUI X: Should not call `commitToken` with an empty token");const d=gh(e,a),u=jv(e,d.contentType,d.type,a),f=n?u:d.contentType==="digit",p=t!=null&&e.isValid(t);let y=p?e.formatByString(t,a):"",b=null;if(f)if(u)b=y===""?e.formatByString(i,a).length:y.length;else{if(d.maxLength==null)throw new Error(`MUI X: The token ${a} should have a 'maxDigitNumber' property on it's adapter`);b=d.maxLength,p&&(y=yh(Lv(Br(y,r),b),r))}return Z({},d,{format:a,maxLength:b,value:y,placeholder:QL(e,o,d,a),hasLeadingZerosInFormat:u,hasLeadingZerosInInput:f,startSeparator:l,endSeparator:"",modified:!1})},e$=e=>{const{utils:t,expandedFormat:n,escapedParts:o}=e,r=t.date(void 0),i=[];let a="";const l=Object.keys(t.formatTokenMap).sort((b,w)=>w.length-b.length),d=/^([a-zA-Z]+)/,u=new RegExp(`^(${l.join("|")})*$`),f=new RegExp(`^(${l.join("|")})`),p=b=>o.find(w=>w.start<=b&&w.end>=b);let y=0;for(;y<n.length;){const b=p(y),w=b!=null,g=d.exec(n.slice(y))?.[1];if(!w&&g!=null&&u.test(g)){let v=g;for(;v.length>0;){const E=f.exec(v)[1];v=v.slice(E.length),i.push(JL(Z({},e,{now:r,token:E,startSeparator:a}))),a=""}y+=g.length}else{const v=n[y];w&&b?.start===y||b?.end===y||(i.length===0?a+=v:i[i.length-1].endSeparator+=v),y+=1}}return i.length===0&&a.length>0&&i.push({type:"empty",contentType:"letter",maxLength:null,format:"",value:"",placeholder:"",hasLeadingZerosInFormat:!1,hasLeadingZerosInInput:!1,startSeparator:a,endSeparator:"",modified:!1}),i},t$=({isRtl:e,formatDensity:t,sections:n})=>n.map(o=>{const r=i=>{let a=i;return e&&a!==null&&a.includes(" ")&&(a=`${a}`),t==="spacious"&&["/",".","-"].includes(a)&&(a=` ${a} `),a};return o.startSeparator=r(o.startSeparator),o.endSeparator=r(o.endSeparator),o}),Em=e=>{let t=XL(e);e.isRtl&&e.enableAccessibleFieldDOMStructure&&(t=t.split(" ").reverse().join(" "));const n=ZL(Z({},e,{expandedFormat:t})),o=e$(Z({},e,{expandedFormat:t,escapedParts:n}));return t$(Z({},e,{sections:o}))},n$=e=>{const t=Nt(),n=rr(),o=Yr(),r=lo(),{valueManager:i,fieldValueManager:a,valueType:l,validator:d,internalProps:u,internalProps:{value:f,defaultValue:p,referenceDate:y,onChange:b,format:w,formatDensity:g="dense",selectedSections:v,onSelectedSectionsChange:E,shouldRespectLeadingZeros:P=!1,timezone:x,enableAccessibleFieldDOMStructure:S=!1}}=e,{timezone:C,value:O,handleValueChange:N}=bh({timezone:x,value:f,defaultValue:p,onChange:b,valueManager:i}),F=k.useMemo(()=>PF(t),[t]),z=k.useMemo(()=>NF(t,F,C),[t,F,C]),R=k.useCallback((j,J=null)=>a.getSectionsFromValue(t,j,J,ee=>Em({utils:t,localeText:n,localizedDigits:F,format:w,date:ee,formatDensity:g,shouldRespectLeadingZeros:P,enableAccessibleFieldDOMStructure:S,isRtl:r})),[a,w,n,F,r,P,t,g,S]),[$,K]=k.useState(()=>{const j=R(O);Cm(j,l);const J={sections:j,value:O,referenceValue:i.emptyValue,tempValueStrAndroid:null},ee=RF(j),te=i.getInitialReferenceValue({referenceDate:y,value:O,utils:t,props:u,granularity:ee,timezone:C});return Z({},J,{referenceValue:te})}),[X,q]=ko({controlled:v,default:null,name:"useField",state:"selectedSections"}),Y=j=>{q(j),E?.(j)},H=k.useMemo(()=>ou(X,$.sections),[X,$.sections]),le=H==="all"?0:H,A=({value:j,referenceValue:J,sections:ee})=>{if(K(ce=>Z({},ce,{sections:ee,value:j,referenceValue:J,tempValueStrAndroid:null})),i.areValuesEqual(t,$.value,j))return;const te={validationError:d({adapter:o,value:j,timezone:C,props:u})};N(j,te)},M=(j,J)=>{const ee=[...$.sections];return ee[j]=Z({},ee[j],{value:J,modified:!0}),ee},V=()=>{A({value:i.emptyValue,referenceValue:$.referenceValue,sections:R(i.emptyValue)})},B=()=>{if(le==null)return;const j=$.sections[le],J=a.getActiveDateManager(t,$,j),te=J.getSections($.sections).filter(W=>W.value!=="").length===(j.value===""?0:1),ce=M(le,""),ie=te?null:t.getInvalidDate(),he=J.getNewValuesFromNewActiveDate(ie);A(Z({},he,{sections:ce}))},ne=j=>{const J=(ce,ie)=>{const he=t.parse(ce,w);if(he==null||!t.isValid(he))return null;const W=Em({utils:t,localeText:n,localizedDigits:F,format:w,date:he,formatDensity:g,shouldRespectLeadingZeros:P,enableAccessibleFieldDOMStructure:S,isRtl:r});return _m(t,he,W,ie,!1)},ee=a.parseValueStr(j,$.referenceValue,J),te=a.updateReferenceValue(t,ee,$.referenceValue);A({value:ee,referenceValue:te,sections:R(ee,$.sections)})},oe=({activeSection:j,newSectionValue:J,shouldGoToNextSection:ee})=>{ee&&le<$.sections.length-1&&Y(le+1);const te=a.getActiveDateManager(t,$,j),ce=M(le,J),ie=te.getSections(ce),he=OF(t,ie,F);let W,re;if(he!=null&&t.isValid(he)){const Q=_m(t,he,ie,te.referenceDate,!0);W=te.getNewValuesFromNewActiveDate(Q),re=!0}else W=te.getNewValuesFromNewActiveDate(he),re=(he!=null&&!t.isValid(he))!=(te.date!=null&&!t.isValid(te.date));return re?A(Z({},W,{sections:ce})):K(Q=>Z({},Q,W,{sections:ce,tempValueStrAndroid:null}))},se=j=>K(J=>Z({},J,{tempValueStrAndroid:j}));return k.useEffect(()=>{const j=R($.value);Cm(j,l),K(J=>Z({},J,{sections:j}))},[w,t.locale,r]),k.useEffect(()=>{let j;i.areValuesEqual(t,$.value,O)?j=i.getTimezone(t,$.value)!==i.getTimezone(t,O):j=!0,j&&K(J=>Z({},J,{value:O,referenceValue:a.updateReferenceValue(t,O,J.referenceValue),sections:R(O)}))},[O]),{state:$,activeSectionIndex:le,parsedSelectedSections:H,setSelectedSections:Y,clearValue:V,clearActiveSection:B,updateSectionValue:oe,updateValueFromValueStr:ne,setTempAndroidValueStr:se,getSectionsFromValue:R,sectionsValueBoundaries:z,localizedDigits:F,timezone:C}},o$=5e3,ds=e=>e.saveQuery!=null,r$=({sections:e,updateSectionValue:t,sectionsValueBoundaries:n,localizedDigits:o,setTempAndroidValueStr:r,timezone:i})=>{const a=Nt(),[l,d]=k.useState(null),u=ke(()=>d(null));k.useEffect(()=>{l!=null&&e[l.sectionIndex]?.type!==l.sectionType&&u()},[e,l,u]),k.useEffect(()=>{if(l!=null){const w=setTimeout(()=>u(),o$);return()=>{clearTimeout(w)}}return()=>{}},[l,u]);const f=({keyPressed:w,sectionIndex:g},v,E)=>{const P=w.toLowerCase(),x=e[g];if(l!=null&&(!E||E(l.value))&&l.sectionIndex===g){const C=`${l.value}${P}`,O=v(C,x);if(!ds(O))return d({sectionIndex:g,value:C,sectionType:x.type}),O}const S=v(P,x);return ds(S)&&!S.saveQuery?(u(),null):(d({sectionIndex:g,value:P,sectionType:x.type}),ds(S)?null:S)},p=w=>{const g=(P,x,S)=>{const C=x.filter(O=>O.toLowerCase().startsWith(S));return C.length===0?{saveQuery:!1}:{sectionValue:C[0],shouldGoToNextSection:C.length===1}},v=(P,x,S,C)=>{const O=N=>Fv(a,i,x.type,N);if(x.contentType==="letter")return g(x.format,O(x.format),P);if(S&&C!=null&&gh(a,S).contentType==="letter"){const N=O(S),F=g(S,N,P);return ds(F)?{saveQuery:!1}:Z({},F,{sectionValue:C(F.sectionValue,N)})}return{saveQuery:!1}};return f(w,(P,x)=>{switch(x.type){case"month":{const S=C=>bm(a,C,a.formats.month,x.format);return v(P,x,a.formats.month,S)}case"weekDay":{const S=(C,O)=>O.indexOf(C).toString();return v(P,x,a.formats.weekday,S)}case"meridiem":return v(P,x);default:return{saveQuery:!1}}})},y=w=>{const g=(E,P)=>{const x=Br(E,o),S=Number(x),C=n[P.type]({currentDate:null,format:P.format,contentType:P.contentType});if(S>C.maximum)return{saveQuery:!1};if(S<C.minimum)return{saveQuery:!0};const O=S*10>C.maximum||x.length===C.maximum.toString().length;return{sectionValue:$v(a,S,C,o,P),shouldGoToNextSection:O}};return f(w,(E,P)=>{if(P.contentType==="digit"||P.contentType==="digit-with-letter")return g(E,P);if(P.type==="month"){jv(a,"digit","month","MM");const x=g(E,{type:P.type,format:"MM",hasLeadingZerosInInput:!0,contentType:"digit",maxLength:2});if(ds(x))return x;const S=bm(a,x.sectionValue,"MM",P.format);return Z({},x,{sectionValue:S})}if(P.type==="weekDay"){const x=g(E,P);if(ds(x))return x;const S=yc(a,P.format)[Number(x.sectionValue)-1];return Z({},x,{sectionValue:S})}return{saveQuery:!1}},E=>vm(E,o))};return{applyCharacterEditing:ke(w=>{const g=e[w.sectionIndex],E=vm(w.keyPressed,o)?y(Z({},w,{keyPressed:yh(w.keyPressed,o)})):p(w);if(E==null){r(null);return}t({activeSection:g,newSectionValue:E.sectionValue,shouldGoToNextSection:E.shouldGoToNextSection})}),resetCharacterQuery:u}},s$=e=>{const{internalProps:{disabled:t,readOnly:n=!1},forwardedProps:{sectionListRef:o,onBlur:r,onClick:i,onFocus:a,onInput:l,onPaste:d,focused:u,autoFocus:f=!1},fieldValueManager:p,applyCharacterEditing:y,resetCharacterQuery:b,setSelectedSections:w,parsedSelectedSections:g,state:v,clearActiveSection:E,clearValue:P,updateSectionValue:x,updateValueFromValueStr:S,sectionOrder:C,areAllSectionsEmpty:O,sectionsValueBoundaries:N}=e,F=k.useRef(null),z=at(o,F),R=rr(),$=Nt(),K=yr(),[X,q]=k.useState(!1),Y=k.useMemo(()=>({syncSelectionToDOM:()=>{if(!F.current)return;const re=document.getSelection();if(!re)return;if(g==null){re.rangeCount>0&&F.current.getRoot().contains(re.getRangeAt(0).startContainer)&&re.removeAllRanges(),X&&F.current.getRoot().blur();return}if(!F.current.getRoot().contains(Nn(document)))return;const Q=new window.Range;let fe;g==="all"?fe=F.current.getRoot():v.sections[g].type==="empty"?fe=F.current.getSectionContainer(g):fe=F.current.getSectionContent(g),Q.selectNodeContents(fe),fe.focus(),re.removeAllRanges(),re.addRange(Q)},getActiveSectionIndexFromDOM:()=>{const re=Nn(document);return!re||!F.current||!F.current.getRoot().contains(re)?null:F.current.getSectionIndexFromDOMElement(re)},focusField:(re=0)=>{if(!F.current)return;const Q=ou(re,v.sections);q(!0),F.current.getSectionContent(Q).focus()},setSelectedSections:re=>{if(!F.current)return;const Q=ou(re,v.sections);q((Q==="all"?0:Q)!==null),w(re)},isFieldFocused:()=>{const re=Nn(document);return!!F.current&&F.current.getRoot().contains(re)}}),[g,w,v.sections,X]),H=ke(re=>{if(!F.current)return;const Q=v.sections[re];F.current.getSectionContent(re).innerHTML=Q.value||Q.placeholder,Y.syncSelectionToDOM()}),le=ke((re,...Q)=>{re.isDefaultPrevented()||!F.current||(q(!0),i?.(re,...Q),g==="all"?setTimeout(()=>{const fe=document.getSelection().getRangeAt(0).startOffset;if(fe===0){w(C.startIndex);return}let me=0,Ce=0;for(;Ce<fe&&me<v.sections.length;){const ve=v.sections[me];me+=1,Ce+=`${ve.startSeparator}${ve.value||ve.placeholder}${ve.endSeparator}`.length}w(me-1)}):X?F.current.getRoot().contains(re.target)||w(C.startIndex):(q(!0),w(C.startIndex)))}),A=ke(re=>{if(l?.(re),!F.current||g!=="all")return;const fe=re.target.textContent??"";F.current.getRoot().innerHTML=v.sections.map(me=>`${me.startSeparator}${me.value||me.placeholder}${me.endSeparator}`).join(""),Y.syncSelectionToDOM(),fe.length===0||fe.charCodeAt(0)===10?(b(),P(),w("all")):fe.length>1?S(fe):y({keyPressed:fe,sectionIndex:0})}),M=ke(re=>{if(d?.(re),n||g!=="all"){re.preventDefault();return}const Q=re.clipboardData.getData("text");re.preventDefault(),b(),S(Q)}),V=ke((...re)=>{if(a?.(...re),X||!F.current)return;q(!0),F.current.getSectionIndexFromDOMElement(Nn(document))!=null||w(C.startIndex)}),B=ke((...re)=>{r?.(...re),setTimeout(()=>{if(!F.current)return;const Q=Nn(document);!F.current.getRoot().contains(Q)&&(q(!1),w(null))})}),ne=ke(re=>Q=>{Q.isDefaultPrevented()||w(re)}),oe=ke(re=>{re.preventDefault()}),se=ke(re=>()=>{w(re)}),j=ke(re=>{if(re.preventDefault(),n||t||typeof g!="number")return;const Q=v.sections[g],fe=re.clipboardData.getData("text"),me=/^[a-zA-Z]+$/.test(fe),Ce=/^[0-9]+$/.test(fe),ve=/^(([a-zA-Z]+)|)([0-9]+)(([a-zA-Z]+)|)$/.test(fe);Q.contentType==="letter"&&me||Q.contentType==="digit"&&Ce||Q.contentType==="digit-with-letter"&&ve?(b(),x({activeSection:Q,newSectionValue:fe,shouldGoToNextSection:!0})):!me&&!Ce&&(b(),S(fe))}),J=ke(re=>{re.preventDefault(),re.dataTransfer.dropEffect="none"}),ee=ke(re=>{if(!F.current)return;const Q=re.target,fe=Q.textContent??"",me=F.current.getSectionIndexFromDOMElement(Q),Ce=v.sections[me];if(n||!F.current){H(me);return}if(fe.length===0){if(Ce.value===""){H(me);return}const ve=re.nativeEvent.inputType;if(ve==="insertParagraph"||ve==="insertLineBreak"){H(me);return}b(),E();return}y({keyPressed:fe,sectionIndex:me}),H(me)});nn(()=>{if(!(!X||!F.current)){if(g==="all")F.current.getRoot().focus();else if(typeof g=="number"){const re=F.current.getSectionContent(g);re&&re.focus()}}},[g,X]);const te=k.useMemo(()=>v.sections.reduce((re,Q)=>(re[Q.type]=N[Q.type]({currentDate:null,contentType:Q.contentType,format:Q.format}),re),{}),[N,v.sections]),ce=g==="all",ie=k.useMemo(()=>v.sections.map((re,Q)=>{const fe=!ce&&!t&&!n;return{container:{"data-sectionindex":Q,onClick:ne(Q)},content:{tabIndex:ce||Q>0?-1:0,contentEditable:!ce&&!t&&!n,role:"spinbutton",id:`${K}-${re.type}`,"aria-labelledby":`${K}-${re.type}`,"aria-readonly":n,"aria-valuenow":VF(re,$),"aria-valuemin":te[re.type].minimum,"aria-valuemax":te[re.type].maximum,"aria-valuetext":re.value?$F(re,$):R.empty,"aria-label":R[re.type],"aria-disabled":t,spellCheck:fe?!1:void 0,autoCapitalize:fe?"off":void 0,autoCorrect:fe?"off":void 0,[parseInt(k.version,10)>=17?"enterKeyHint":"enterkeyhint"]:fe?"next":void 0,children:re.value||re.placeholder,onInput:ee,onPaste:j,onFocus:se(Q),onDragOver:J,onMouseUp:oe,inputMode:re.contentType==="letter"?"text":"numeric"},before:{children:re.startSeparator},after:{children:re.endSeparator}}}),[v.sections,se,j,J,ee,ne,oe,t,n,ce,R,$,te,K]),he=ke(re=>{S(re.target.value)}),W=k.useMemo(()=>O?"":p.getV7HiddenInputValueFromSections(v.sections),[O,v.sections,p]);return k.useEffect(()=>{if(F.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(`
|
|
363
|
-
`));f&&F.current&&F.current.getSectionContent(C.startIndex).focus()},[]),{interactions:Y,returnedValue:{autoFocus:f,readOnly:n,focused:u??X,sectionListRef:z,onBlur:B,onClick:le,onFocus:V,onInput:A,onPaste:M,enableAccessibleFieldDOMStructure:!0,elements:ie,tabIndex:g===0?-1:0,contentEditable:ce,value:W,onChange:he,areAllSectionsEmpty:O}}},gs=e=>e.replace(/[\u2066\u2067\u2068\u2069]/g,""),i$=(e,t,n)=>{let o=0,r=n?1:0;const i=[];for(let a=0;a<e.length;a+=1){const l=e[a],d=vh(l,n?"input-rtl":"input-ltr",t),u=`${l.startSeparator}${d}${l.endSeparator}`,f=gs(u).length,p=u.length,y=gs(d),b=r+(y===""?0:d.indexOf(y[0]))+l.startSeparator.length,w=b+y.length;i.push(Z({},l,{start:o,end:o+f,startInInput:b,endInInput:w})),o+=f,r+=p}return i},a$=e=>{const t=lo(),n=k.useRef(),o=k.useRef(),{forwardedProps:{onFocus:r,onClick:i,onPaste:a,onBlur:l,inputRef:d,placeholder:u},internalProps:{readOnly:f=!1,disabled:p=!1},parsedSelectedSections:y,activeSectionIndex:b,state:w,fieldValueManager:g,valueManager:v,applyCharacterEditing:E,resetCharacterQuery:P,updateSectionValue:x,updateValueFromValueStr:S,clearActiveSection:C,clearValue:O,setTempAndroidValueStr:N,setSelectedSections:F,getSectionsFromValue:z,areAllSectionsEmpty:R,localizedDigits:$}=e,K=k.useRef(null),X=at(d,K),q=k.useMemo(()=>i$(w.sections,$,t),[w.sections,$,t]),Y=k.useMemo(()=>({syncSelectionToDOM:()=>{if(!K.current)return;if(y==null){K.current.scrollLeft&&(K.current.scrollLeft=0);return}if(K.current!==Nn(document))return;const ee=K.current.scrollTop;if(y==="all")K.current.select();else{const te=q[y],ce=te.type==="empty"?te.startInInput-te.startSeparator.length:te.startInInput,ie=te.type==="empty"?te.endInInput+te.endSeparator.length:te.endInInput;(ce!==K.current.selectionStart||ie!==K.current.selectionEnd)&&K.current===Nn(document)&&K.current.setSelectionRange(ce,ie),clearTimeout(o.current),o.current=setTimeout(()=>{K.current&&K.current===Nn(document)&&K.current.selectionStart===K.current.selectionEnd&&(K.current.selectionStart!==ce||K.current.selectionEnd!==ie)&&Y.syncSelectionToDOM()})}K.current.scrollTop=ee},getActiveSectionIndexFromDOM:()=>{const ee=K.current.selectionStart??0,te=K.current.selectionEnd??0;if(ee===0&&te===0)return null;const ce=ee<=q[0].startInInput?1:q.findIndex(ie=>ie.startInInput-ie.startSeparator.length>ee);return ce===-1?q.length-1:ce-1},focusField:(ee=0)=>{K.current?.focus(),F(ee)},setSelectedSections:ee=>F(ee),isFieldFocused:()=>K.current===Nn(document)}),[K,y,q,F]),H=()=>{const ee=K.current.selectionStart??0;let te;ee<=q[0].startInInput||ee>=q[q.length-1].endInInput?te=1:te=q.findIndex(ie=>ie.startInInput-ie.startSeparator.length>ee);const ce=te===-1?q.length-1:te-1;F(ce)},le=ke((...ee)=>{r?.(...ee);const te=K.current;clearTimeout(n.current),n.current=setTimeout(()=>{!te||te!==K.current||b==null&&(te.value.length&&Number(te.selectionEnd)-Number(te.selectionStart)===te.value.length?F("all"):H())})}),A=ke((ee,...te)=>{ee.isDefaultPrevented()||(i?.(ee,...te),H())}),M=ke(ee=>{if(a?.(ee),ee.preventDefault(),f||p)return;const te=ee.clipboardData.getData("text");if(typeof y=="number"){const ce=w.sections[y],ie=/^[a-zA-Z]+$/.test(te),he=/^[0-9]+$/.test(te),W=/^(([a-zA-Z]+)|)([0-9]+)(([a-zA-Z]+)|)$/.test(te);if(ce.contentType==="letter"&&ie||ce.contentType==="digit"&&he||ce.contentType==="digit-with-letter"&&W){P(),x({activeSection:ce,newSectionValue:te,shouldGoToNextSection:!0});return}if(ie||he)return}P(),S(te)}),V=ke((...ee)=>{l?.(...ee),F(null)}),B=ke(ee=>{if(f)return;const te=ee.target.value;if(te===""){P(),O();return}const ce=ee.nativeEvent.data,ie=ce&&ce.length>1,he=ie?ce:te,W=gs(he);if(b==null||ie){S(ie?ce:W);return}let re;if(y==="all"&&W.length===1)re=W;else{const Q=gs(g.getV6InputValueFromSections(q,$,t));let fe=-1,me=-1;for(let Ve=0;Ve<Q.length;Ve+=1)fe===-1&&Q[Ve]!==W[Ve]&&(fe=Ve),me===-1&&Q[Q.length-Ve-1]!==W[W.length-Ve-1]&&(me=Ve);const Ce=q[b];if(fe<Ce.start||Q.length-me-1>Ce.end)return;const xe=W.length-Q.length+Ce.end-gs(Ce.endSeparator||"").length;re=W.slice(Ce.start+gs(Ce.startSeparator||"").length,xe)}if(re.length===0){FF()&&N(he),P(),C();return}E({keyPressed:re,sectionIndex:b})}),ne=k.useMemo(()=>u!==void 0?u:g.getV6InputValueFromSections(z(v.emptyValue),$,t),[u,g,z,v.emptyValue,$,t]),oe=k.useMemo(()=>w.tempValueStrAndroid??g.getV6InputValueFromSections(w.sections,$,t),[w.sections,g,w.tempValueStrAndroid,$,t]);k.useEffect(()=>(K.current&&K.current===Nn(document)&&F("all"),()=>{clearTimeout(n.current),clearTimeout(o.current)}),[]);const se=k.useMemo(()=>b==null||w.sections[b].contentType==="letter"?"text":"numeric",[b,w.sections]),J=!(K.current&&K.current===Nn(document))&&R;return{interactions:Y,returnedValue:{readOnly:f,onBlur:V,onClick:A,onFocus:le,onPaste:M,inputRef:X,enableAccessibleFieldDOMStructure:!1,placeholder:ne,inputMode:se,autoComplete:"off",value:J?"":oe,onChange:B}}},l$=e=>{const t=Nt(),{internalProps:n,internalProps:{unstableFieldRef:o,minutesStep:r,enableAccessibleFieldDOMStructure:i=!1,disabled:a=!1,readOnly:l=!1},forwardedProps:{onKeyDown:d,error:u,clearable:f,onClear:p},fieldValueManager:y,valueManager:b,validator:w}=e,g=lo(),v=n$(e),{state:E,activeSectionIndex:P,parsedSelectedSections:x,setSelectedSections:S,clearValue:C,clearActiveSection:O,updateSectionValue:N,setTempAndroidValueStr:F,sectionsValueBoundaries:z,localizedDigits:R,timezone:$}=v,K=r$({sections:E.sections,updateSectionValue:N,sectionsValueBoundaries:z,localizedDigits:R,setTempAndroidValueStr:F,timezone:$}),{resetCharacterQuery:X}=K,q=b.areValuesEqual(t,E.value,b.emptyValue),Y=i?s$:a$,H=k.useMemo(()=>LF(E.sections,g&&!i),[E.sections,g,i]),{returnedValue:le,interactions:A}=Y(Z({},e,v,K,{areAllSectionsEmpty:q,sectionOrder:H})),M=ke(j=>{if(d?.(j),!a)switch(!0){case((j.ctrlKey||j.metaKey)&&String.fromCharCode(j.keyCode)==="A"&&!j.shiftKey&&!j.altKey):{j.preventDefault(),S("all");break}case j.key==="ArrowRight":{if(j.preventDefault(),x==null)S(H.startIndex);else if(x==="all")S(H.endIndex);else{const J=H.neighbors[x].rightIndex;J!==null&&S(J)}break}case j.key==="ArrowLeft":{if(j.preventDefault(),x==null)S(H.endIndex);else if(x==="all")S(H.startIndex);else{const J=H.neighbors[x].leftIndex;J!==null&&S(J)}break}case j.key==="Delete":{if(j.preventDefault(),l)break;x==null||x==="all"?C():O(),X();break}case["ArrowUp","ArrowDown","Home","End","PageUp","PageDown"].includes(j.key):{if(j.preventDefault(),l||P==null)break;const J=E.sections[P],ee=y.getActiveDateManager(t,E,J),te=DF(t,$,J,j.key,z,R,ee.date,{minutesStep:r});N({activeSection:J,newSectionValue:te,shouldGoToNextSection:!1});break}}});nn(()=>{A.syncSelectionToDOM()});const{hasValidationError:V}=qv({props:n,validator:w,timezone:$,value:E.value,onError:n.onError}),B=k.useMemo(()=>u!==void 0?u:V,[V,u]);k.useEffect(()=>{!B&&P==null&&X()},[E.referenceValue,P,B]),k.useEffect(()=>{E.tempValueStrAndroid!=null&&P!=null&&(X(),O())},[E.sections]),k.useImperativeHandle(o,()=>({getSections:()=>E.sections,getActiveSectionIndex:A.getActiveSectionIndexFromDOM,setSelectedSections:A.setSelectedSections,focusField:A.focusField,isFieldFocused:A.isFieldFocused}));const ne=ke((j,...J)=>{j.preventDefault(),p?.(j,...J),C(),A.isFieldFocused()?S(H.startIndex):A.focusField(0)}),oe={onKeyDown:M,onClear:ne,error:B,clearable:!!(f&&!q&&!l&&!a)},se={disabled:a,readOnly:l};return Z({},e.forwardedProps,oe,se,le)},c$=["clearable","onClear","InputProps","sx","slots","slotProps"],d$=["ownerState"],u$=e=>{const t=rr(),{clearable:n,onClear:o,InputProps:r,sx:i,slots:a,slotProps:l}=e,d=We(e,c$),u=a?.clearButton??$s,f=dt({elementType:u,externalSlotProps:l?.clearButton,ownerState:{},className:"clearButton",additionalProps:{title:t.fieldClearLabel}}),p=We(f,d$),y=a?.clearIcon??KL,b=dt({elementType:y,externalSlotProps:l?.clearIcon,ownerState:{}});return Z({},d,{InputProps:Z({},r,{endAdornment:D.jsxs(k.Fragment,{children:[n&&D.jsx(Nu,{position:"end",sx:{marginRight:r?.endAdornment?-1:-1.5},children:D.jsx(u,Z({},p,{onClick:o,children:D.jsx(y,Z({fontSize:"small"},b))}))}),r?.endAdornment]})}),sx:[{"& .clearButton":{opacity:1},"@media (pointer: fine)":{"& .clearButton":{opacity:0},"&:hover, &:focus-within":{".clearButton":{opacity:1}}}},...Array.isArray(i)?i:[i]]})},h$=["value","defaultValue","referenceDate","format","formatDensity","onChange","timezone","onError","shouldRespectLeadingZeros","selectedSections","onSelectedSectionsChange","unstableFieldRef","enableAccessibleFieldDOMStructure","disabled","readOnly","dateSeparator"],f$=(e,t)=>k.useMemo(()=>{const n=Z({},e),o={},r=i=>{n.hasOwnProperty(i)&&(o[i]=n[i],delete n[i])};return h$.forEach(r),Yv.forEach(r),{forwardedProps:n,internalProps:o}},[e,t]),p$=e=>{const t=Nt(),n=ya();return Z({},e,{disablePast:e.disablePast??!1,disableFuture:e.disableFuture??!1,format:e.format??t.formats.keyboardDate,minDate:Xn(t,e.minDate,n.minDate),maxDate:Xn(t,e.maxDate,n.maxDate)})},m$=e=>{const t=p$(e),{forwardedProps:n,internalProps:o}=f$(t,"date");return l$({forwardedProps:n,internalProps:o,valueManager:Po,fieldValueManager:BF,validator:va,valueType:"date"})};function g$(e){return Oe("MuiPickersTextField",e)}De("MuiPickersTextField",["root","focused","disabled","error","required"]);function y$(e){return Oe("MuiPickersInputBase",e)}const _s=De("MuiPickersInputBase",["root","focused","disabled","error","notchedOutline","sectionContent","sectionBefore","sectionAfter","adornedStart","adornedEnd","input"]);function v$(e){return Oe("MuiPickersSectionList",e)}const hi=De("MuiPickersSectionList",["root","section","sectionContent"]),b$=["slots","slotProps","elements","sectionListRef"],tb=ae("div",{name:"MuiPickersSectionList",slot:"Root",overridesResolver:(e,t)=>t.root})({direction:"ltr /*! @noflip */",outline:"none"}),nb=ae("span",{name:"MuiPickersSectionList",slot:"Section",overridesResolver:(e,t)=>t.section})({}),ob=ae("span",{name:"MuiPickersSectionList",slot:"SectionSeparator",overridesResolver:(e,t)=>t.sectionSeparator})({whiteSpace:"pre"}),rb=ae("span",{name:"MuiPickersSectionList",slot:"SectionContent",overridesResolver:(e,t)=>t.sectionContent})({outline:"none"}),w$=e=>{const{classes:t}=e;return Me({root:["root"],section:["section"],sectionContent:["sectionContent"]},v$,t)};function sb(e){const{slots:t,slotProps:n,element:o,classes:r}=e,i=t?.section??nb,a=dt({elementType:i,externalSlotProps:n?.section,externalForwardedProps:o.container,className:r.section,ownerState:{}}),l=t?.sectionContent??rb,d=dt({elementType:l,externalSlotProps:n?.sectionContent,externalForwardedProps:o.content,additionalProps:{suppressContentEditableWarning:!0},className:r.sectionContent,ownerState:{}}),u=t?.sectionSeparator??ob,f=dt({elementType:u,externalSlotProps:n?.sectionSeparator,externalForwardedProps:o.before,ownerState:{position:"before"}}),p=dt({elementType:u,externalSlotProps:n?.sectionSeparator,externalForwardedProps:o.after,ownerState:{position:"after"}});return D.jsxs(i,Z({},a,{children:[D.jsx(u,Z({},f)),D.jsx(l,Z({},d)),D.jsx(u,Z({},p))]}))}process.env.NODE_ENV!=="production"&&(sb.propTypes={classes:s.object.isRequired,element:s.shape({after:s.object.isRequired,before:s.object.isRequired,container:s.object.isRequired,content:s.object.isRequired}).isRequired,slotProps:s.object,slots:s.object});const ib=k.forwardRef(function(t,n){const o=Mt({props:t,name:"MuiPickersSectionList"}),{slots:r,slotProps:i,elements:a,sectionListRef:l}=o,d=We(o,b$),u=w$(o),f=k.useRef(null),p=at(n,f),y=g=>{if(!f.current)throw new Error(`MUI X: Cannot call sectionListRef.${g} before the mount of the component.`);return f.current};k.useImperativeHandle(l,()=>({getRoot(){return y("getRoot")},getSectionContainer(g){return y("getSectionContainer").querySelector(`.${hi.section}[data-sectionindex="${g}"]`)},getSectionContent(g){return y("getSectionContent").querySelector(`.${hi.section}[data-sectionindex="${g}"] .${hi.sectionContent}`)},getSectionIndexFromDOMElement(g){const v=y("getSectionIndexFromDOMElement");if(g==null||!v.contains(g))return null;let E=null;return g.classList.contains(hi.section)?E=g:g.classList.contains(hi.sectionContent)&&(E=g.parentElement),E==null?null:Number(E.dataset.sectionindex)}}));const b=r?.root??tb,w=dt({elementType:b,externalSlotProps:i?.root,externalForwardedProps:d,additionalProps:{ref:p,suppressContentEditableWarning:!0},className:u.root,ownerState:{}});return D.jsx(b,Z({},w,{children:w.contentEditable?a.map(({content:g,before:v,after:E})=>`${v.children}${g.children}${E.children}`).join(""):D.jsx(k.Fragment,{children:a.map((g,v)=>D.jsx(sb,{slots:r,slotProps:i,element:g,classes:u},v))})}))});process.env.NODE_ENV!=="production"&&(ib.propTypes={classes:s.object,contentEditable:s.bool.isRequired,elements:s.arrayOf(s.shape({after:s.object.isRequired,before:s.object.isRequired,container:s.object.isRequired,content:s.object.isRequired})).isRequired,sectionListRef:s.oneOfType([s.func,s.shape({current:s.shape({getRoot:s.func.isRequired,getSectionContainer:s.func.isRequired,getSectionContent:s.func.isRequired,getSectionIndexFromDOMElement:s.func.isRequired})})]),slotProps:s.object,slots:s.object});const C$=["elements","areAllSectionsEmpty","defaultValue","label","value","onChange","id","autoFocus","endAdornment","startAdornment","renderSuffix","slots","slotProps","contentEditable","tabIndex","onInput","onPaste","onKeyDown","fullWidth","name","readOnly","inputProps","inputRef","sectionListRef"],S$=e=>Math.round(e*1e5)/1e5,Sc=ae("div",{name:"MuiPickersInputBase",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>Z({},e.typography.body1,{color:(e.vars||e).palette.text.primary,cursor:"text",padding:0,display:"flex",justifyContent:"flex-start",alignItems:"center",position:"relative",boxSizing:"border-box",letterSpacing:`${S$(.15/16)}em`,variants:[{props:{fullWidth:!0},style:{width:"100%"}}]})),_h=ae(tb,{name:"MuiPickersInputBase",slot:"SectionsContainer",overridesResolver:(e,t)=>t.sectionsContainer})(({theme:e})=>({padding:"4px 0 5px",fontFamily:e.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:t,focused:n,filled:o,label:r})=>!t&&!n&&!o&&r==null,style:e.vars?{opacity:e.vars.opacity.inputPlaceholder}:{opacity:e.palette.mode==="light"?.42:.5}}]})),_$=ae(nb,{name:"MuiPickersInputBase",slot:"Section",overridesResolver:(e,t)=>t.section})(({theme:e})=>({fontFamily:e.typography.fontFamily,fontSize:"inherit",letterSpacing:"inherit",lineHeight:"1.4375em",display:"flex"})),x$=ae(rb,{name:"MuiPickersInputBase",slot:"SectionContent",overridesResolver:(e,t)=>t.content})(({theme:e})=>({fontFamily:e.typography.fontFamily,lineHeight:"1.4375em",letterSpacing:"inherit",width:"fit-content",outline:"none"})),R$=ae(ob,{name:"MuiPickersInputBase",slot:"Separator",overridesResolver:(e,t)=>t.separator})(()=>({whiteSpace:"pre",letterSpacing:"inherit"})),k$=ae("input",{name:"MuiPickersInputBase",slot:"Input",overridesResolver:(e,t)=>t.hiddenInput})(Z({},jx)),T$=e=>{const{focused:t,disabled:n,error:o,classes:r,fullWidth:i,readOnly:a,color:l,size:d,endAdornment:u,startAdornment:f}=e,p={root:["root",t&&!n&&"focused",n&&"disabled",a&&"readOnly",o&&"error",i&&"fullWidth",`color${be(l)}`,d==="small"&&"inputSizeSmall",!!f&&"adornedStart",!!u&&"adornedEnd"],notchedOutline:["notchedOutline"],input:["input"],sectionsContainer:["sectionsContainer"],sectionContent:["sectionContent"],sectionBefore:["sectionBefore"],sectionAfter:["sectionAfter"]};return Me(p,y$,r)},_c=k.forwardRef(function(t,n){const o=Mt({props:t,name:"MuiPickersInputBase"}),{elements:r,areAllSectionsEmpty:i,value:a,onChange:l,id:d,endAdornment:u,startAdornment:f,renderSuffix:p,slots:y,slotProps:b,contentEditable:w,tabIndex:g,onInput:v,onPaste:E,onKeyDown:P,name:x,readOnly:S,inputProps:C,inputRef:O,sectionListRef:N}=o,F=We(o,C$),z=k.useRef(null),R=at(n,z),$=at(C?.ref,O),K=lo(),X=On();if(!X)throw new Error("MUI X: PickersInputBase should always be used inside a PickersTextField component");const q=V=>{if(X.disabled){V.stopPropagation();return}X.onFocus?.(V)};k.useEffect(()=>{X&&X.setAdornedStart(!!f)},[X,f]),k.useEffect(()=>{X&&(i?X.onEmpty():X.onFilled())},[X,i]);const Y=Z({},o,X,{isRtl:K}),H=T$(Y),le=y?.root||Sc,A=dt({elementType:le,externalSlotProps:b?.root,externalForwardedProps:F,additionalProps:{"aria-invalid":X.error,ref:R},className:H.root,ownerState:Y}),M=y?.input||_h;return D.jsxs(le,Z({},A,{children:[f,D.jsx(ib,{sectionListRef:N,elements:r,contentEditable:w,tabIndex:g,className:H.sectionsContainer,onFocus:q,onBlur:X.onBlur,onInput:v,onPaste:E,onKeyDown:P,slots:{root:M,section:_$,sectionContent:x$,sectionSeparator:R$},slotProps:{root:{ownerState:Y},sectionContent:{className:_s.sectionContent},sectionSeparator:({position:V})=>({className:V==="before"?_s.sectionBefore:_s.sectionAfter})}}),u,p?p(Z({},X)):null,D.jsx(k$,Z({name:x,className:H.input,value:a,onChange:l,id:d,"aria-hidden":"true",tabIndex:-1,readOnly:S,required:X.required,disabled:X.disabled},C,{ref:$}))]}))});process.env.NODE_ENV!=="production"&&(_c.propTypes={areAllSectionsEmpty:s.bool.isRequired,className:s.string,component:s.elementType,contentEditable:s.bool.isRequired,elements:s.arrayOf(s.shape({after:s.object.isRequired,before:s.object.isRequired,container:s.object.isRequired,content:s.object.isRequired})).isRequired,endAdornment:s.node,fullWidth:s.bool,id:s.string,inputProps:s.object,inputRef:Bt,label:s.node,margin:s.oneOf(["dense","none","normal"]),name:s.string,onChange:s.func.isRequired,onClick:s.func.isRequired,onInput:s.func.isRequired,onKeyDown:s.func.isRequired,onPaste:s.func.isRequired,ownerState:s.any,readOnly:s.bool,renderSuffix:s.func,sectionListRef:s.oneOfType([s.func,s.shape({current:s.shape({getRoot:s.func.isRequired,getSectionContainer:s.func.isRequired,getSectionContent:s.func.isRequired,getSectionIndexFromDOMElement:s.func.isRequired})})]),slotProps:s.object,slots:s.object,startAdornment:s.node,style:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),value:s.string.isRequired});function E$(e){return Oe("MuiPickersOutlinedInput",e)}const no=Z({},_s,De("MuiPickersOutlinedInput",["root","notchedOutline","input"])),P$=["children","className","label","notched","shrink"],D$=ae("fieldset",{name:"MuiPickersOutlinedInput",slot:"NotchedOutline",overridesResolver:(e,t)=>t.notchedOutline})(({theme:e})=>{const t=e.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:e.vars?`rgba(${e.vars.palette.common.onBackgroundChannel} / 0.23)`:t}}),Pm=ae("span")(({theme:e})=>({fontFamily:e.typography.fontFamily,fontSize:"inherit"})),O$=ae("legend")(({theme:e})=>({float:"unset",width:"auto",overflow:"hidden",variants:[{props:{withLabel:!1},style:{padding:0,lineHeight:"11px",transition:e.transitions.create("width",{duration:150,easing:e.transitions.easing.easeOut})}},{props:{withLabel:!0},style:{display:"block",padding:0,height:11,fontSize:"0.75em",visibility:"hidden",maxWidth:.01,transition:e.transitions.create("max-width",{duration:50,easing:e.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:e.transitions.create("max-width",{duration:100,easing:e.transitions.easing.easeOut,delay:50})}}]}));function M$(e){const{className:t,label:n}=e,o=We(e,P$),r=n!=null&&n!=="",i=Z({},e,{withLabel:r});return D.jsx(D$,Z({"aria-hidden":!0,className:t},o,{ownerState:i,children:D.jsx(O$,{ownerState:i,children:r?D.jsx(Pm,{children:n}):D.jsx(Pm,{className:"notranslate",children:""})})}))}const I$=["label","autoFocus","ownerState","notched"],N$=ae(Sc,{name:"MuiPickersOutlinedInput",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>{const t=e.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return{padding:"0 14px",borderRadius:(e.vars||e).shape.borderRadius,[`&:hover .${no.notchedOutline}`]:{borderColor:(e.vars||e).palette.text.primary},"@media (hover: none)":{[`&:hover .${no.notchedOutline}`]:{borderColor:e.vars?`rgba(${e.vars.palette.common.onBackgroundChannel} / 0.23)`:t}},[`&.${no.focused} .${no.notchedOutline}`]:{borderStyle:"solid",borderWidth:2},[`&.${no.disabled}`]:{[`& .${no.notchedOutline}`]:{borderColor:(e.vars||e).palette.action.disabled},"*":{color:(e.vars||e).palette.action.disabled}},[`&.${no.error} .${no.notchedOutline}`]:{borderColor:(e.vars||e).palette.error.main},variants:Object.keys((e.vars??e).palette).filter(n=>(e.vars??e).palette[n]?.main??!1).map(n=>({props:{color:n},style:{[`&.${no.focused}:not(.${no.error}) .${no.notchedOutline}`]:{borderColor:(e.vars||e).palette[n].main}}}))}}),A$=ae(_h,{name:"MuiPickersOutlinedInput",slot:"SectionsContainer",overridesResolver:(e,t)=>t.sectionsContainer})({padding:"16.5px 0",variants:[{props:{size:"small"},style:{padding:"8.5px 0"}}]}),F$=e=>{const{classes:t}=e,o=Me({root:["root"],notchedOutline:["notchedOutline"],input:["input"]},E$,t);return Z({},t,o)},xh=k.forwardRef(function(t,n){const o=Mt({props:t,name:"MuiPickersOutlinedInput"}),{label:r,ownerState:i,notched:a}=o,l=We(o,I$),d=On(),u=Z({},o,i,d,{color:d?.color||"primary"}),f=F$(u);return D.jsx(_c,Z({slots:{root:N$,input:A$},renderSuffix:p=>D.jsx(M$,{shrink:!!(a||p.adornedStart||p.focused||p.filled),notched:!!(a||p.adornedStart||p.focused||p.filled),className:f.notchedOutline,label:r!=null&&r!==""&&d?.required?D.jsxs(k.Fragment,{children:[r," ","*"]}):r,ownerState:u})},l,{label:r,classes:f,ref:n}))});process.env.NODE_ENV!=="production"&&(xh.propTypes={areAllSectionsEmpty:s.bool.isRequired,className:s.string,component:s.elementType,contentEditable:s.bool.isRequired,elements:s.arrayOf(s.shape({after:s.object.isRequired,before:s.object.isRequired,container:s.object.isRequired,content:s.object.isRequired})).isRequired,endAdornment:s.node,fullWidth:s.bool,id:s.string,inputProps:s.object,inputRef:Bt,label:s.node,margin:s.oneOf(["dense","none","normal"]),name:s.string,notched:s.bool,onChange:s.func.isRequired,onClick:s.func.isRequired,onInput:s.func.isRequired,onKeyDown:s.func.isRequired,onPaste:s.func.isRequired,ownerState:s.any,readOnly:s.bool,renderSuffix:s.func,sectionListRef:s.oneOfType([s.func,s.shape({current:s.shape({getRoot:s.func.isRequired,getSectionContainer:s.func.isRequired,getSectionContent:s.func.isRequired,getSectionIndexFromDOMElement:s.func.isRequired})})]),slotProps:s.object,slots:s.object,startAdornment:s.node,style:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),value:s.string.isRequired});xh.muiName="Input";function L$(e){return Oe("MuiPickersFilledInput",e)}const Tr=Z({},_s,De("MuiPickersFilledInput",["root","underline","input"])),$$=["label","autoFocus","disableUnderline","ownerState"],V$=ae(Sc,{name:"MuiPickersFilledInput",slot:"Root",overridesResolver:(e,t)=>t.root,shouldForwardProp:e=>Ja(e)&&e!=="disableUnderline"})(({theme:e})=>{const t=e.palette.mode==="light",n=t?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)",o=t?"rgba(0, 0, 0, 0.06)":"rgba(255, 255, 255, 0.09)",r=t?"rgba(0, 0, 0, 0.09)":"rgba(255, 255, 255, 0.13)",i=t?"rgba(0, 0, 0, 0.12)":"rgba(255, 255, 255, 0.12)";return{backgroundColor:e.vars?e.vars.palette.FilledInput.bg:o,borderTopLeftRadius:(e.vars||e).shape.borderRadius,borderTopRightRadius:(e.vars||e).shape.borderRadius,transition:e.transitions.create("background-color",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),"&:hover":{backgroundColor:e.vars?e.vars.palette.FilledInput.hoverBg:r,"@media (hover: none)":{backgroundColor:e.vars?e.vars.palette.FilledInput.bg:o}},[`&.${Tr.focused}`]:{backgroundColor:e.vars?e.vars.palette.FilledInput.bg:o},[`&.${Tr.disabled}`]:{backgroundColor:e.vars?e.vars.palette.FilledInput.disabledBg:i},variants:[...Object.keys((e.vars??e).palette).filter(a=>(e.vars??e).palette[a].main).map(a=>({props:{color:a,disableUnderline:!1},style:{"&::after":{borderBottom:`2px solid ${(e.vars||e).palette[a]?.main}`}}})),{props:{disableUnderline:!1},style:{"&::after":{left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:e.transitions.create("transform",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${Tr.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${Tr.error}`]:{"&:before, &:after":{borderBottomColor:(e.vars||e).palette.error.main}},"&::before":{borderBottom:`1px solid ${e.vars?`rgba(${e.vars.palette.common.onBackgroundChannel} / ${e.vars.opacity.inputUnderline})`:n}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:e.transitions.create("border-bottom-color",{duration:e.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${Tr.disabled}, .${Tr.error}):before`]:{borderBottom:`1px solid ${(e.vars||e).palette.text.primary}`},[`&.${Tr.disabled}:before`]:{borderBottomStyle:"dotted"}}},{props:({startAdornment:a})=>!!a,style:{paddingLeft:12}},{props:({endAdornment:a})=>!!a,style:{paddingRight:12}}]}}),j$=ae(_h,{name:"MuiPickersFilledInput",slot:"sectionsContainer",overridesResolver:(e,t)=>t.sectionsContainer})({paddingTop:25,paddingRight:12,paddingBottom:8,paddingLeft:12,variants:[{props:{size:"small"},style:{paddingTop:21,paddingBottom:4}},{props:({startAdornment:e})=>!!e,style:{paddingLeft:0}},{props:({endAdornment:e})=>!!e,style:{paddingRight:0}},{props:{hiddenLabel:!0},style:{paddingTop:16,paddingBottom:17}},{props:{hiddenLabel:!0,size:"small"},style:{paddingTop:8,paddingBottom:9}}]}),B$=e=>{const{classes:t,disableUnderline:n}=e,r=Me({root:["root",!n&&"underline"],input:["input"]},L$,t);return Z({},t,r)},Rh=k.forwardRef(function(t,n){const o=Mt({props:t,name:"MuiPickersFilledInput"}),{label:r,disableUnderline:i=!1,ownerState:a}=o,l=We(o,$$),d=On(),u=Z({},o,a,d,{color:d?.color||"primary"}),f=B$(u);return D.jsx(_c,Z({slots:{root:V$,input:j$},slotProps:{root:{disableUnderline:i}}},l,{label:r,classes:f,ref:n}))});process.env.NODE_ENV!=="production"&&(Rh.propTypes={areAllSectionsEmpty:s.bool.isRequired,className:s.string,component:s.elementType,contentEditable:s.bool.isRequired,disableUnderline:s.bool,elements:s.arrayOf(s.shape({after:s.object.isRequired,before:s.object.isRequired,container:s.object.isRequired,content:s.object.isRequired})).isRequired,endAdornment:s.node,fullWidth:s.bool,hiddenLabel:s.bool,id:s.string,inputProps:s.object,inputRef:Bt,label:s.node,margin:s.oneOf(["dense","none","normal"]),name:s.string,onChange:s.func.isRequired,onClick:s.func.isRequired,onInput:s.func.isRequired,onKeyDown:s.func.isRequired,onPaste:s.func.isRequired,ownerState:s.any,readOnly:s.bool,renderSuffix:s.func,sectionListRef:s.oneOfType([s.func,s.shape({current:s.shape({getRoot:s.func.isRequired,getSectionContainer:s.func.isRequired,getSectionContent:s.func.isRequired,getSectionIndexFromDOMElement:s.func.isRequired})})]),slotProps:s.object,slots:s.object,startAdornment:s.node,style:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),value:s.string.isRequired});Rh.muiName="Input";function W$(e){return Oe("MuiPickersFilledInput",e)}const fi=Z({},_s,De("MuiPickersInput",["root","input"])),H$=["label","autoFocus","disableUnderline","ownerState"],z$=ae(Sc,{name:"MuiPickersInput",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>{let n=e.palette.mode==="light"?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)";return e.vars&&(n=`rgba(${e.vars.palette.common.onBackgroundChannel} / ${e.vars.opacity.inputUnderline})`),{"label + &":{marginTop:16},variants:[...Object.keys((e.vars??e).palette).filter(o=>(e.vars??e).palette[o].main).map(o=>({props:{color:o},style:{"&::after":{borderBottom:`2px solid ${(e.vars||e).palette[o].main}`}}})),{props:{disableUnderline:!1},style:{"&::after":{background:"red",left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:e.transitions.create("transform",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${fi.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${fi.error}`]:{"&:before, &:after":{borderBottomColor:(e.vars||e).palette.error.main}},"&::before":{borderBottom:`1px solid ${n}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:e.transitions.create("border-bottom-color",{duration:e.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${fi.disabled}, .${fi.error}):before`]:{borderBottom:`2px solid ${(e.vars||e).palette.text.primary}`,"@media (hover: none)":{borderBottom:`1px solid ${n}`}},[`&.${fi.disabled}:before`]:{borderBottomStyle:"dotted"}}}]}}),Y$=e=>{const{classes:t,disableUnderline:n}=e,r=Me({root:["root",!n&&"underline"],input:["input"]},W$,t);return Z({},t,r)},kh=k.forwardRef(function(t,n){const o=Mt({props:t,name:"MuiPickersInput"}),{label:r,disableUnderline:i=!1,ownerState:a}=o,l=We(o,H$),d=On(),u=Z({},o,a,d,{disableUnderline:i,color:d?.color||"primary"}),f=Y$(u);return D.jsx(_c,Z({slots:{root:z$}},l,{label:r,classes:f,ref:n}))});process.env.NODE_ENV!=="production"&&(kh.propTypes={areAllSectionsEmpty:s.bool.isRequired,className:s.string,component:s.elementType,contentEditable:s.bool.isRequired,disableUnderline:s.bool,elements:s.arrayOf(s.shape({after:s.object.isRequired,before:s.object.isRequired,container:s.object.isRequired,content:s.object.isRequired})).isRequired,endAdornment:s.node,fullWidth:s.bool,id:s.string,inputProps:s.object,inputRef:Bt,label:s.node,margin:s.oneOf(["dense","none","normal"]),name:s.string,onChange:s.func.isRequired,onClick:s.func.isRequired,onInput:s.func.isRequired,onKeyDown:s.func.isRequired,onPaste:s.func.isRequired,ownerState:s.any,readOnly:s.bool,renderSuffix:s.func,sectionListRef:s.oneOfType([s.func,s.shape({current:s.shape({getRoot:s.func.isRequired,getSectionContainer:s.func.isRequired,getSectionContent:s.func.isRequired,getSectionIndexFromDOMElement:s.func.isRequired})})]),slotProps:s.object,slots:s.object,startAdornment:s.node,style:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),value:s.string.isRequired});kh.muiName="Input";const U$=["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"],q$={standard:kh,filled:Rh,outlined:xh},G$=ae(ca,{name:"MuiPickersTextField",slot:"Root",overridesResolver:(e,t)=>t.root})({}),K$=e=>{const{focused:t,disabled:n,classes:o,required:r}=e;return Me({root:["root",t&&!n&&"focused",n&&"disabled",r&&"required"]},g$,o)},ab=k.forwardRef(function(t,n){const o=Mt({props:t,name:"MuiPickersTextField"}),{onFocus:r,onBlur:i,className:a,color:l="primary",disabled:d=!1,error:u=!1,variant:f="outlined",required:p=!1,InputProps:y,inputProps:b,inputRef:w,sectionListRef:g,elements:v,areAllSectionsEmpty:E,onClick:P,onKeyDown:x,onKeyUp:S,onPaste:C,onInput:O,endAdornment:N,startAdornment:F,tabIndex:z,contentEditable:R,focused:$,value:K,onChange:X,fullWidth:q,id:Y,name:H,helperText:le,FormHelperTextProps:A,label:M,InputLabelProps:V}=o,B=We(o,U$),ne=k.useRef(null),oe=at(n,ne),se=yr(Y),j=le&&se?`${se}-helper-text`:void 0,J=M&&se?`${se}-label`:void 0,ee=Z({},o,{color:l,disabled:d,error:u,focused:$,required:p,variant:f}),te=K$(ee),ce=q$[f];return D.jsxs(G$,Z({className:Se(te.root,a),ref:oe,focused:$,onFocus:r,onBlur:i,disabled:d,variant:f,error:u,color:l,fullWidth:q,required:p,ownerState:ee},B,{children:[D.jsx(da,Z({htmlFor:se,id:J},V,{children:M})),D.jsx(ce,Z({elements:v,areAllSectionsEmpty:E,onClick:P,onKeyDown:x,onKeyUp:S,onInput:O,onPaste:C,endAdornment:N,startAdornment:F,tabIndex:z,contentEditable:R,value:K,onChange:X,id:se,fullWidth:q,inputProps:b,inputRef:w,sectionListRef:g,label:M,name:H,role:"group","aria-labelledby":J},y)),le&&D.jsx(Iu,Z({id:j},A,{children:le}))]}))});process.env.NODE_ENV!=="production"&&(ab.propTypes={areAllSectionsEmpty:s.bool.isRequired,className:s.string,color:s.oneOf(["error","info","primary","secondary","success","warning"]),component:s.elementType,contentEditable:s.bool.isRequired,disabled:s.bool.isRequired,elements:s.arrayOf(s.shape({after:s.object.isRequired,before:s.object.isRequired,container:s.object.isRequired,content:s.object.isRequired})).isRequired,endAdornment:s.node,error:s.bool.isRequired,focused:s.bool,FormHelperTextProps:s.object,fullWidth:s.bool,helperText:s.node,hiddenLabel:s.bool,id:s.string,InputLabelProps:s.object,inputProps:s.object,InputProps:s.object,inputRef:Bt,label:s.node,margin:s.oneOf(["dense","none","normal"]),name:s.string,onBlur:s.func.isRequired,onChange:s.func.isRequired,onClick:s.func.isRequired,onFocus:s.func.isRequired,onInput:s.func.isRequired,onKeyDown:s.func.isRequired,onPaste:s.func.isRequired,readOnly:s.bool,required:s.bool,sectionListRef:s.oneOfType([s.func,s.shape({current:s.shape({getRoot:s.func.isRequired,getSectionContainer:s.func.isRequired,getSectionContent:s.func.isRequired,getSectionIndexFromDOMElement:s.func.isRequired})})]),size:s.oneOf(["medium","small"]),startAdornment:s.node,style:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),value:s.string.isRequired,variant:s.oneOf(["filled","outlined","standard"])});const X$=["enableAccessibleFieldDOMStructure"],Z$=["InputProps","readOnly"],Q$=["onPaste","onKeyDown","inputMode","readOnly","InputProps","inputProps","inputRef"],J$=e=>{let{enableAccessibleFieldDOMStructure:t}=e,n=We(e,X$);if(t){const{InputProps:p,readOnly:y}=n,b=We(n,Z$);return Z({},b,{InputProps:Z({},p??{},{readOnly:y})})}const{onPaste:o,onKeyDown:r,inputMode:i,readOnly:a,InputProps:l,inputProps:d,inputRef:u}=n,f=We(n,Q$);return Z({},f,{InputProps:Z({},l??{},{readOnly:a}),inputProps:Z({},d??{},{inputMode:i,onPaste:o,onKeyDown:r,ref:u})})},eV=["slots","slotProps","InputProps","inputProps"],Th=k.forwardRef(function(t,n){const o=Mt({props:t,name:"MuiDateField"}),{slots:r,slotProps:i,InputProps:a,inputProps:l}=o,d=We(o,eV),u=o,f=r?.textField??(t.enableAccessibleFieldDOMStructure?ab:Ms),p=dt({elementType:f,externalSlotProps:i?.textField,externalForwardedProps:d,additionalProps:{ref:n},ownerState:u});p.inputProps=Z({},l,p.inputProps),p.InputProps=Z({},a,p.InputProps);const y=m$(p),b=J$(y),w=u$(Z({},b,{slots:r,slotProps:i}));return D.jsx(f,Z({},w))});process.env.NODE_ENV!=="production"&&(Th.propTypes={autoFocus:s.bool,className:s.string,clearable:s.bool,color:s.oneOf(["error","info","primary","secondary","success","warning"]),component:s.elementType,defaultValue:s.object,disabled:s.bool,disableFuture:s.bool,disablePast:s.bool,enableAccessibleFieldDOMStructure:s.bool,focused:s.bool,format:s.string,formatDensity:s.oneOf(["dense","spacious"]),FormHelperTextProps:s.object,fullWidth:s.bool,helperText:s.node,hiddenLabel:s.bool,id:s.string,InputLabelProps:s.object,inputProps:s.object,InputProps:s.object,inputRef:Bt,label:s.node,margin:s.oneOf(["dense","none","normal"]),maxDate:s.object,minDate:s.object,name:s.string,onBlur:s.func,onChange:s.func,onClear:s.func,onError:s.func,onFocus:s.func,onSelectedSectionsChange:s.func,readOnly:s.bool,referenceDate:s.object,required:s.bool,selectedSections:s.oneOfType([s.oneOf(["all","day","empty","hours","meridiem","minutes","month","seconds","weekDay","year"]),s.number]),shouldDisableDate:s.func,shouldDisableMonth:s.func,shouldDisableYear:s.func,shouldRespectLeadingZeros:s.bool,size:s.oneOf(["medium","small"]),slotProps:s.object,slots:s.object,style:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),timezone:s.string,unstableFieldRef:s.oneOfType([s.func,s.object]),value:s.object,variant:s.oneOf(["filled","outlined","standard"])});const lb=({shouldDisableDate:e,shouldDisableMonth:t,shouldDisableYear:n,minDate:o,maxDate:r,disableFuture:i,disablePast:a,timezone:l})=>{const d=Yr();return k.useCallback(u=>va({adapter:d,value:u,timezone:l,props:{shouldDisableDate:e,shouldDisableMonth:t,shouldDisableYear:n,minDate:o,maxDate:r,disableFuture:i,disablePast:a}})!==null,[d,e,t,n,o,r,i,a,l])},tV=(e,t,n)=>(o,r)=>{switch(r.type){case"changeMonth":return Z({},o,{slideDirection:r.direction,currentMonth:r.newMonth,isMonthSwitchingAnimating:!e});case"changeMonthTimezone":{const i=r.newTimezone;if(n.getTimezone(o.currentMonth)===i)return o;let a=n.setTimezone(o.currentMonth,i);return n.getMonth(a)!==n.getMonth(o.currentMonth)&&(a=n.setMonth(a,n.getMonth(o.currentMonth))),Z({},o,{currentMonth:a})}case"finishMonthSwitchingAnimation":return Z({},o,{isMonthSwitchingAnimating:!1});case"changeFocusedDay":{if(o.focusedDay!=null&&r.focusedDay!=null&&n.isSameDay(r.focusedDay,o.focusedDay))return o;const i=r.focusedDay!=null&&!t&&!n.isSameMonth(o.currentMonth,r.focusedDay);return Z({},o,{focusedDay:r.focusedDay,isMonthSwitchingAnimating:i&&!e&&!r.withoutMonthSwitchingAnimation,currentMonth:i?n.startOfMonth(r.focusedDay):o.currentMonth,slideDirection:r.focusedDay!=null&&n.isAfterDay(r.focusedDay,o.currentMonth)?"left":"right"})}default:throw new Error("missing support")}},nV=e=>{const{value:t,referenceDate:n,disableFuture:o,disablePast:r,disableSwitchToMonthOnDayFocus:i=!1,maxDate:a,minDate:l,onMonthChange:d,reduceAnimations:u,shouldDisableDate:f,timezone:p}=e,y=Nt(),b=k.useRef(tV(!!u,i,y)).current,w=k.useMemo(()=>Po.getInitialReferenceValue({value:t,utils:y,timezone:p,props:e,referenceDate:n,granularity:wo.day}),[n,p]),[g,v]=k.useReducer(b,{isMonthSwitchingAnimating:!1,focusedDay:w,currentMonth:y.startOfMonth(w),slideDirection:"left"});k.useEffect(()=>{v({type:"changeMonthTimezone",newTimezone:y.getTimezone(w)})},[w,y]);const E=k.useCallback(O=>{v(Z({type:"changeMonth"},O)),d&&d(O.newMonth)},[d]),P=k.useCallback(O=>{const N=O;y.isSameMonth(N,g.currentMonth)||E({newMonth:y.startOfMonth(N),direction:y.isAfterDay(N,g.currentMonth)?"left":"right"})},[g.currentMonth,E,y]),x=lb({shouldDisableDate:f,minDate:l,maxDate:a,disableFuture:o,disablePast:r,timezone:p}),S=k.useCallback(()=>{v({type:"finishMonthSwitchingAnimation"})},[]),C=ke((O,N)=>{x(O)||v({type:"changeFocusedDay",focusedDay:O,withoutMonthSwitchingAnimation:N})});return{referenceDate:w,calendarState:g,changeMonth:P,changeFocusedDay:C,isDateDisabled:x,onMonthSwitchingAnimationEnd:S,handleChangeMonth:E}},oV=e=>Oe("MuiPickersFadeTransitionGroup",e);De("MuiPickersFadeTransitionGroup",["root"]);const rV=e=>{const{classes:t}=e;return Me({root:["root"]},oV,t)},sV=ae(sa,{name:"MuiPickersFadeTransitionGroup",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"block",position:"relative"});function cb(e){const t=Mt({props:e,name:"MuiPickersFadeTransitionGroup"}),{children:n,className:o,reduceAnimations:r,transKey:i}=t,a=rV(t),l=Fs();return r?n:D.jsx(sV,{className:Se(a.root,o),children:D.jsx(Wr,{appear:!1,mountOnEnter:!0,unmountOnExit:!0,timeout:{appear:l.transitions.duration.enteringScreen,enter:l.transitions.duration.enteringScreen,exit:0},children:n},i)})}function iV(e){return Oe("MuiPickersDay",e)}const Er=De("MuiPickersDay",["root","dayWithMargin","dayOutsideMonth","hiddenDaySpacingFiller","today","selected","disabled"]),aV=["autoFocus","className","day","disabled","disableHighlightToday","disableMargin","hidden","isAnimating","onClick","onDaySelect","onFocus","onBlur","onKeyDown","onMouseDown","onMouseEnter","outsideCurrentMonth","selected","showDaysOutsideCurrentMonth","children","today","isFirstVisibleCell","isLastVisibleCell"],lV=e=>{const{selected:t,disableMargin:n,disableHighlightToday:o,today:r,disabled:i,outsideCurrentMonth:a,showDaysOutsideCurrentMonth:l,classes:d}=e,u=a&&!l;return Me({root:["root",t&&!u&&"selected",i&&"disabled",!n&&"dayWithMargin",!o&&r&&"today",a&&l&&"dayOutsideMonth",u&&"hiddenDaySpacingFiller"],hiddenDaySpacingFiller:["hiddenDaySpacingFiller"]},iV,d)},db=({theme:e})=>Z({},e.typography.caption,{width:Xi,height:Xi,borderRadius:"50%",padding:0,backgroundColor:"transparent",transition:e.transitions.create("background-color",{duration:e.transitions.duration.short}),color:(e.vars||e).palette.text.primary,"@media (pointer: fine)":{"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.hoverOpacity})`:ot(e.palette.primary.main,e.palette.action.hoverOpacity)}},"&:focus":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.focusOpacity})`:ot(e.palette.primary.main,e.palette.action.focusOpacity),[`&.${Er.selected}`]:{willChange:"background-color",backgroundColor:(e.vars||e).palette.primary.dark}},[`&.${Er.selected}`]:{color:(e.vars||e).palette.primary.contrastText,backgroundColor:(e.vars||e).palette.primary.main,fontWeight:e.typography.fontWeightMedium,"&:hover":{willChange:"background-color",backgroundColor:(e.vars||e).palette.primary.dark}},[`&.${Er.disabled}:not(.${Er.selected})`]:{color:(e.vars||e).palette.text.disabled},[`&.${Er.disabled}&.${Er.selected}`]:{opacity:.6},variants:[{props:{disableMargin:!1},style:{margin:`0 ${wc}px`}},{props:{outsideCurrentMonth:!0,showDaysOutsideCurrentMonth:!0},style:{color:(e.vars||e).palette.text.secondary}},{props:{disableHighlightToday:!1,today:!0},style:{[`&:not(.${Er.selected})`]:{border:`1px solid ${(e.vars||e).palette.text.secondary}`}}}]}),ub=(e,t)=>{const{ownerState:n}=e;return[t.root,!n.disableMargin&&t.dayWithMargin,!n.disableHighlightToday&&n.today&&t.today,!n.outsideCurrentMonth&&n.showDaysOutsideCurrentMonth&&t.dayOutsideMonth,n.outsideCurrentMonth&&!n.showDaysOutsideCurrentMonth&&t.hiddenDaySpacingFiller]},cV=ae(pr,{name:"MuiPickersDay",slot:"Root",overridesResolver:ub})(db),dV=ae("div",{name:"MuiPickersDay",slot:"Root",overridesResolver:ub})(({theme:e})=>Z({},db({theme:e}),{opacity:0,pointerEvents:"none"})),pi=()=>{},hb=k.forwardRef(function(t,n){const o=Mt({props:t,name:"MuiPickersDay"}),{autoFocus:r=!1,className:i,day:a,disabled:l=!1,disableHighlightToday:d=!1,disableMargin:u=!1,isAnimating:f,onClick:p,onDaySelect:y,onFocus:b=pi,onBlur:w=pi,onKeyDown:g=pi,onMouseDown:v=pi,onMouseEnter:E=pi,outsideCurrentMonth:P,selected:x=!1,showDaysOutsideCurrentMonth:S=!1,children:C,today:O=!1}=o,N=We(o,aV),F=Z({},o,{autoFocus:r,disabled:l,disableHighlightToday:d,disableMargin:u,selected:x,showDaysOutsideCurrentMonth:S,today:O}),z=lV(F),R=Nt(),$=k.useRef(null),K=at($,n);nn(()=>{r&&!l&&!f&&!P&&$.current.focus()},[r,l,f,P]);const X=Y=>{v(Y),P&&Y.preventDefault()},q=Y=>{l||y(a),P&&Y.currentTarget.focus(),p&&p(Y)};return P&&!S?D.jsx(dV,{className:Se(z.root,z.hiddenDaySpacingFiller,i),ownerState:F,role:N.role}):D.jsx(cV,Z({className:Se(z.root,i),ref:K,centerRipple:!0,disabled:l,tabIndex:x?0:-1,onKeyDown:Y=>g(Y,a),onFocus:Y=>b(Y,a),onBlur:Y=>w(Y,a),onMouseEnter:Y=>E(Y,a),onClick:q,onMouseDown:X},N,{ownerState:F,children:C||R.format(a,"dayOfMonth")}))});process.env.NODE_ENV!=="production"&&(hb.propTypes={action:s.oneOfType([s.func,s.shape({current:s.shape({focusVisible:s.func.isRequired})})]),centerRipple:s.bool,classes:s.object,className:s.string,component:s.elementType,day:s.object.isRequired,disabled:s.bool,disableHighlightToday:s.bool,disableMargin:s.bool,disableRipple:s.bool,disableTouchRipple:s.bool,focusRipple:s.bool,focusVisibleClassName:s.string,isAnimating:s.bool,isFirstVisibleCell:s.bool.isRequired,isLastVisibleCell:s.bool.isRequired,onBlur:s.func,onDaySelect:s.func.isRequired,onFocus:s.func,onFocusVisible:s.func,onKeyDown:s.func,onMouseEnter:s.func,outsideCurrentMonth:s.bool.isRequired,selected:s.bool,showDaysOutsideCurrentMonth:s.bool,style:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),tabIndex:s.number,today:s.bool,TouchRippleProps:s.object,touchRippleRef:s.oneOfType([s.func,s.shape({current:s.shape({pulsate:s.func.isRequired,start:s.func.isRequired,stop:s.func.isRequired})})])});const uV=k.memo(hb),hV=e=>Oe("MuiPickersSlideTransition",e),Wn=De("MuiPickersSlideTransition",["root","slideEnter-left","slideEnter-right","slideEnterActive","slideExit","slideExitActiveLeft-left","slideExitActiveLeft-right"]),fV=["children","className","reduceAnimations","slideDirection","transKey","classes"],pV=e=>{const{classes:t,slideDirection:n}=e,o={root:["root"],exit:["slideExit"],enterActive:["slideEnterActive"],enter:[`slideEnter-${n}`],exitActive:[`slideExitActiveLeft-${n}`]};return Me(o,hV,t)},mV=ae(sa,{name:"MuiPickersSlideTransition",slot:"Root",overridesResolver:(e,t)=>[t.root,{[`.${Wn["slideEnter-left"]}`]:t["slideEnter-left"]},{[`.${Wn["slideEnter-right"]}`]:t["slideEnter-right"]},{[`.${Wn.slideEnterActive}`]:t.slideEnterActive},{[`.${Wn.slideExit}`]:t.slideExit},{[`.${Wn["slideExitActiveLeft-left"]}`]:t["slideExitActiveLeft-left"]},{[`.${Wn["slideExitActiveLeft-right"]}`]:t["slideExitActiveLeft-right"]}]})(({theme:e})=>{const t=e.transitions.create("transform",{duration:e.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},[`& .${Wn["slideEnter-left"]}`]:{willChange:"transform",transform:"translate(100%)",zIndex:1},[`& .${Wn["slideEnter-right"]}`]:{willChange:"transform",transform:"translate(-100%)",zIndex:1},[`& .${Wn.slideEnterActive}`]:{transform:"translate(0%)",transition:t},[`& .${Wn.slideExit}`]:{transform:"translate(0%)"},[`& .${Wn["slideExitActiveLeft-left"]}`]:{willChange:"transform",transform:"translate(-100%)",transition:t,zIndex:0},[`& .${Wn["slideExitActiveLeft-right"]}`]:{willChange:"transform",transform:"translate(100%)",transition:t,zIndex:0}}});function gV(e){const t=Mt({props:e,name:"MuiPickersSlideTransition"}),{children:n,className:o,reduceAnimations:r,transKey:i}=t,a=We(t,fV),l=pV(t),d=Fs();if(r)return D.jsx("div",{className:Se(l.root,o),children:n});const u={exit:l.exit,enterActive:l.enterActive,enter:l.enter,exitActive:l.exitActive};return D.jsx(mV,{className:Se(l.root,o),childFactory:f=>k.cloneElement(f,{classNames:u}),role:"presentation",children:D.jsx(Su,Z({mountOnEnter:!0,unmountOnExit:!0,timeout:d.transitions.duration.complex,classNames:u},a,{children:n}),i)})}const yV=e=>Oe("MuiDayCalendar",e);De("MuiDayCalendar",["root","header","weekDayLabel","loadingContainer","slideTransition","monthContainer","weekContainer","weekNumberLabel","weekNumber"]);const vV=["parentProps","day","focusableDay","selectedDays","isDateDisabled","currentMonthNumber","isViewFocused"],bV=["ownerState"],wV=e=>{const{classes:t}=e;return Me({root:["root"],header:["header"],weekDayLabel:["weekDayLabel"],loadingContainer:["loadingContainer"],slideTransition:["slideTransition"],monthContainer:["monthContainer"],weekContainer:["weekContainer"],weekNumberLabel:["weekNumberLabel"],weekNumber:["weekNumber"]},yV,t)},fb=(Xi+wc*2)*6,CV=ae("div",{name:"MuiDayCalendar",slot:"Root",overridesResolver:(e,t)=>t.root})({}),SV=ae("div",{name:"MuiDayCalendar",slot:"Header",overridesResolver:(e,t)=>t.header})({display:"flex",justifyContent:"center",alignItems:"center"}),_V=ae(kn,{name:"MuiDayCalendar",slot:"WeekDayLabel",overridesResolver:(e,t)=>t.weekDayLabel})(({theme:e})=>({width:36,height:40,margin:"0 2px",textAlign:"center",display:"flex",justifyContent:"center",alignItems:"center",color:(e.vars||e).palette.text.secondary})),xV=ae(kn,{name:"MuiDayCalendar",slot:"WeekNumberLabel",overridesResolver:(e,t)=>t.weekNumberLabel})(({theme:e})=>({width:36,height:40,margin:"0 2px",textAlign:"center",display:"flex",justifyContent:"center",alignItems:"center",color:e.palette.text.disabled})),RV=ae(kn,{name:"MuiDayCalendar",slot:"WeekNumber",overridesResolver:(e,t)=>t.weekNumber})(({theme:e})=>Z({},e.typography.caption,{width:Xi,height:Xi,padding:0,margin:`0 ${wc}px`,color:e.palette.text.disabled,fontSize:"0.75rem",alignItems:"center",justifyContent:"center",display:"inline-flex"})),kV=ae("div",{name:"MuiDayCalendar",slot:"LoadingContainer",overridesResolver:(e,t)=>t.loadingContainer})({display:"flex",justifyContent:"center",alignItems:"center",minHeight:fb}),TV=ae(gV,{name:"MuiDayCalendar",slot:"SlideTransition",overridesResolver:(e,t)=>t.slideTransition})({minHeight:fb}),EV=ae("div",{name:"MuiDayCalendar",slot:"MonthContainer",overridesResolver:(e,t)=>t.monthContainer})({overflow:"hidden"}),PV=ae("div",{name:"MuiDayCalendar",slot:"WeekContainer",overridesResolver:(e,t)=>t.weekContainer})({margin:`${wc}px 0`,display:"flex",justifyContent:"center"});function DV(e){let{parentProps:t,day:n,focusableDay:o,selectedDays:r,isDateDisabled:i,currentMonthNumber:a,isViewFocused:l}=e,d=We(e,vV);const{disabled:u,disableHighlightToday:f,isMonthSwitchingAnimating:p,showDaysOutsideCurrentMonth:y,slots:b,slotProps:w,timezone:g}=t,v=Nt(),E=bc(g),P=o!==null&&v.isSameDay(n,o),x=r.some(K=>v.isSameDay(K,n)),S=v.isSameDay(n,E),C=b?.day??uV,O=dt({elementType:C,externalSlotProps:w?.day,additionalProps:Z({disableHighlightToday:f,showDaysOutsideCurrentMonth:y,role:"gridcell",isAnimating:p,"data-timestamp":v.toJsDate(n).valueOf()},d),ownerState:Z({},t,{day:n,selected:x})}),N=We(O,bV),F=k.useMemo(()=>u||i(n),[u,i,n]),z=k.useMemo(()=>v.getMonth(n)!==a,[v,n,a]),R=k.useMemo(()=>{const K=v.startOfMonth(v.setMonth(n,a));return y?v.isSameDay(n,v.startOfWeek(K)):v.isSameDay(n,K)},[a,n,y,v]),$=k.useMemo(()=>{const K=v.endOfMonth(v.setMonth(n,a));return y?v.isSameDay(n,v.endOfWeek(K)):v.isSameDay(n,K)},[a,n,y,v]);return D.jsx(C,Z({},N,{day:n,disabled:F,autoFocus:l&&P,today:S,outsideCurrentMonth:z,isFirstVisibleCell:R,isLastVisibleCell:$,selected:x,tabIndex:P?0:-1,"aria-selected":x,"aria-current":S?"date":void 0}))}function OV(e){const t=Mt({props:e,name:"MuiDayCalendar"}),n=Nt(),{onFocusedDayChange:o,className:r,currentMonth:i,selectedDays:a,focusedDay:l,loading:d,onSelectedDaysChange:u,onMonthSwitchingAnimationEnd:f,readOnly:p,reduceAnimations:y,renderLoading:b=()=>D.jsx("span",{children:"..."}),slideDirection:w,TransitionProps:g,disablePast:v,disableFuture:E,minDate:P,maxDate:x,shouldDisableDate:S,shouldDisableMonth:C,shouldDisableYear:O,dayOfWeekFormatter:N=me=>n.format(me,"weekdayShort").charAt(0).toUpperCase(),hasFocus:F,onFocusedViewChange:z,gridLabelId:R,displayWeekNumber:$,fixedWeekNumber:K,autoFocus:X,timezone:q}=t,Y=bc(q),H=wV(t),le=lo(),A=lb({shouldDisableDate:S,shouldDisableMonth:C,shouldDisableYear:O,minDate:P,maxDate:x,disablePast:v,disableFuture:E,timezone:q}),M=rr(),[V,B]=ko({name:"DayCalendar",state:"hasFocus",controlled:F,default:X??!1}),[ne,oe]=k.useState(()=>l||Y),se=ke(me=>{p||u(me)}),j=me=>{A(me)||(o(me),oe(me),z?.(!0),B(!0))},J=ke((me,Ce)=>{switch(me.key){case"ArrowUp":j(n.addDays(Ce,-7)),me.preventDefault();break;case"ArrowDown":j(n.addDays(Ce,7)),me.preventDefault();break;case"ArrowLeft":{const ve=n.addDays(Ce,le?1:-1),xe=n.addMonths(Ce,le?1:-1),Ve=Ei({utils:n,date:ve,minDate:le?ve:n.startOfMonth(xe),maxDate:le?n.endOfMonth(xe):ve,isDateDisabled:A,timezone:q});j(Ve||ve),me.preventDefault();break}case"ArrowRight":{const ve=n.addDays(Ce,le?-1:1),xe=n.addMonths(Ce,le?-1:1),Ve=Ei({utils:n,date:ve,minDate:le?n.startOfMonth(xe):ve,maxDate:le?ve:n.endOfMonth(xe),isDateDisabled:A,timezone:q});j(Ve||ve),me.preventDefault();break}case"Home":j(n.startOfWeek(Ce)),me.preventDefault();break;case"End":j(n.endOfWeek(Ce)),me.preventDefault();break;case"PageUp":j(n.addMonths(Ce,1)),me.preventDefault();break;case"PageDown":j(n.addMonths(Ce,-1)),me.preventDefault();break}}),ee=ke((me,Ce)=>j(Ce)),te=ke((me,Ce)=>{V&&n.isSameDay(ne,Ce)&&z?.(!1)}),ce=n.getMonth(i),ie=n.getYear(i),he=k.useMemo(()=>a.filter(me=>!!me).map(me=>n.startOfDay(me)),[n,a]),W=`${ie}-${ce}`,re=k.useMemo(()=>k.createRef(),[W]),Q=k.useMemo(()=>{const me=n.startOfMonth(i),Ce=n.endOfMonth(i);return A(ne)||n.isAfterDay(ne,Ce)||n.isBeforeDay(ne,me)?Ei({utils:n,date:ne,minDate:me,maxDate:Ce,disablePast:v,disableFuture:E,isDateDisabled:A,timezone:q}):ne},[i,E,v,ne,A,n,q]),fe=k.useMemo(()=>{const me=n.getWeekArray(i);let Ce=n.addMonths(i,1);for(;K&&me.length<K;){const ve=n.getWeekArray(Ce),xe=n.isSameDay(me[me.length-1][0],ve[0][0]);ve.slice(xe?1:0).forEach(Ve=>{me.length<K&&me.push(Ve)}),Ce=n.addMonths(Ce,1)}return me},[i,K,n]);return D.jsxs(CV,{role:"grid","aria-labelledby":R,className:H.root,children:[D.jsxs(SV,{role:"row",className:H.header,children:[$&&D.jsx(xV,{variant:"caption",role:"columnheader","aria-label":M.calendarWeekNumberHeaderLabel,className:H.weekNumberLabel,children:M.calendarWeekNumberHeaderText}),CF(n,Y).map((me,Ce)=>D.jsx(_V,{variant:"caption",role:"columnheader","aria-label":n.format(me,"weekday"),className:H.weekDayLabel,children:N(me)},Ce.toString()))]}),d?D.jsx(kV,{className:H.loadingContainer,children:b()}):D.jsx(TV,Z({transKey:W,onExited:f,reduceAnimations:y,slideDirection:w,className:Se(r,H.slideTransition)},g,{nodeRef:re,children:D.jsx(EV,{ref:re,role:"rowgroup",className:H.monthContainer,children:fe.map((me,Ce)=>D.jsxs(PV,{role:"row",className:H.weekContainer,"aria-rowindex":Ce+1,children:[$&&D.jsx(RV,{className:H.weekNumber,role:"rowheader","aria-label":M.calendarWeekNumberAriaLabelText(n.getWeekNumber(me[0])),children:M.calendarWeekNumberText(n.getWeekNumber(me[0]))}),me.map((ve,xe)=>D.jsx(DV,{parentProps:t,day:ve,selectedDays:he,focusableDay:Q,onKeyDown:J,onFocus:ee,onBlur:te,onDaySelect:se,isDateDisabled:A,currentMonthNumber:ce,isViewFocused:V,"aria-colindex":xe+1},ve.toString()))]},`week-${me[0]}`))})}))]})}function MV(e){return Oe("MuiPickersMonth",e)}const qa=De("MuiPickersMonth",["root","monthButton","disabled","selected"]),IV=["autoFocus","className","children","disabled","selected","value","tabIndex","onClick","onKeyDown","onFocus","onBlur","aria-current","aria-label","monthsPerRow","slots","slotProps"],NV=e=>{const{disabled:t,selected:n,classes:o}=e;return Me({root:["root"],monthButton:["monthButton",t&&"disabled",n&&"selected"]},MV,o)},AV=ae("div",{name:"MuiPickersMonth",slot:"Root",overridesResolver:(e,t)=>[t.root]})({display:"flex",alignItems:"center",justifyContent:"center",flexBasis:"33.3%",variants:[{props:{monthsPerRow:4},style:{flexBasis:"25%"}}]}),FV=ae("button",{name:"MuiPickersMonth",slot:"MonthButton",overridesResolver:(e,t)=>[t.monthButton,{[`&.${qa.disabled}`]:t.disabled},{[`&.${qa.selected}`]:t.selected}]})(({theme:e})=>Z({color:"unset",backgroundColor:"transparent",border:0,outline:0},e.typography.subtitle1,{margin:"8px 0",height:36,width:72,borderRadius:18,cursor:"pointer","&:focus":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.hoverOpacity})`:ot(e.palette.action.active,e.palette.action.hoverOpacity)},"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.hoverOpacity})`:ot(e.palette.action.active,e.palette.action.hoverOpacity)},"&:disabled":{cursor:"auto",pointerEvents:"none"},[`&.${qa.disabled}`]:{color:(e.vars||e).palette.text.secondary},[`&.${qa.selected}`]:{color:(e.vars||e).palette.primary.contrastText,backgroundColor:(e.vars||e).palette.primary.main,"&:focus, &:hover":{backgroundColor:(e.vars||e).palette.primary.dark}}})),LV=k.memo(function(t){const n=Mt({props:t,name:"MuiPickersMonth"}),{autoFocus:o,className:r,children:i,disabled:a,selected:l,value:d,tabIndex:u,onClick:f,onKeyDown:p,onFocus:y,onBlur:b,"aria-current":w,"aria-label":g,slots:v,slotProps:E}=n,P=We(n,IV),x=k.useRef(null),S=NV(n);nn(()=>{o&&x.current?.focus()},[o]);const C=v?.monthButton??FV,O=dt({elementType:C,externalSlotProps:E?.monthButton,additionalProps:{children:i,disabled:a,tabIndex:u,ref:x,type:"button",role:"radio","aria-current":w,"aria-checked":l,"aria-label":g,onClick:N=>f(N,d),onKeyDown:N=>p(N,d),onFocus:N=>y(N,d),onBlur:N=>b(N,d)},ownerState:n,className:S.monthButton});return D.jsx(AV,Z({className:Se(S.root,r),ownerState:n},P,{children:D.jsx(C,Z({},O))}))});function $V(e){return Oe("MuiMonthCalendar",e)}De("MuiMonthCalendar",["root"]);const VV=["className","value","defaultValue","referenceDate","disabled","disableFuture","disablePast","maxDate","minDate","onChange","shouldDisableMonth","readOnly","disableHighlightToday","autoFocus","onMonthFocus","hasFocus","onFocusedViewChange","monthsPerRow","timezone","gridLabelId","slots","slotProps"],jV=e=>{const{classes:t}=e;return Me({root:["root"]},$V,t)};function BV(e,t){const n=Nt(),o=ya(),r=Mt({props:e,name:t});return Z({disableFuture:!1,disablePast:!1},r,{minDate:Xn(n,r.minDate,o.minDate),maxDate:Xn(n,r.maxDate,o.maxDate)})}const WV=ae("div",{name:"MuiMonthCalendar",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"flex",flexWrap:"wrap",alignContent:"stretch",padding:"0 4px",width:Cc,boxSizing:"border-box"}),pb=k.forwardRef(function(t,n){const o=BV(t,"MuiMonthCalendar"),{className:r,value:i,defaultValue:a,referenceDate:l,disabled:d,disableFuture:u,disablePast:f,maxDate:p,minDate:y,onChange:b,shouldDisableMonth:w,readOnly:g,autoFocus:v=!1,onMonthFocus:E,hasFocus:P,onFocusedViewChange:x,monthsPerRow:S=3,timezone:C,gridLabelId:O,slots:N,slotProps:F}=o,z=We(o,VV),{value:R,handleValueChange:$,timezone:K}=wh({name:"MonthCalendar",timezone:C,value:i,defaultValue:a,onChange:b,valueManager:Po}),X=bc(K),q=lo(),Y=Nt(),H=k.useMemo(()=>Po.getInitialReferenceValue({value:R,utils:Y,props:o,timezone:K,referenceDate:l,granularity:wo.month}),[]),le=o,A=jV(le),M=k.useMemo(()=>Y.getMonth(X),[Y,X]),V=k.useMemo(()=>R!=null?Y.getMonth(R):null,[R,Y]),[B,ne]=k.useState(()=>V||Y.getMonth(H)),[oe,se]=ko({name:"MonthCalendar",state:"hasFocus",controlled:P,default:v??!1}),j=ke(W=>{se(W),x&&x(W)}),J=k.useCallback(W=>{const re=Y.startOfMonth(f&&Y.isAfter(X,y)?X:y),Q=Y.startOfMonth(u&&Y.isBefore(X,p)?X:p),fe=Y.startOfMonth(W);return Y.isBefore(fe,re)||Y.isAfter(fe,Q)?!0:w?w(fe):!1},[u,f,p,y,X,w,Y]),ee=ke((W,re)=>{if(g)return;const Q=Y.setMonth(R??H,re);$(Q)}),te=ke(W=>{J(Y.setMonth(R??H,W))||(ne(W),j(!0),E&&E(W))});k.useEffect(()=>{ne(W=>V!==null&&W!==V?V:W)},[V]);const ce=ke((W,re)=>{switch(W.key){case"ArrowUp":te((12+re-3)%12),W.preventDefault();break;case"ArrowDown":te((12+re+3)%12),W.preventDefault();break;case"ArrowLeft":te((12+re+(q?1:-1))%12),W.preventDefault();break;case"ArrowRight":te((12+re+(q?-1:1))%12),W.preventDefault();break}}),ie=ke((W,re)=>{te(re)}),he=ke((W,re)=>{B===re&&j(!1)});return D.jsx(WV,Z({ref:n,className:Se(A.root,r),ownerState:le,role:"radiogroup","aria-labelledby":O},z,{children:ph(Y,R??H).map(W=>{const re=Y.getMonth(W),Q=Y.format(W,"monthShort"),fe=Y.format(W,"month"),me=re===V,Ce=d||J(W);return D.jsx(LV,{selected:me,value:re,onClick:ee,onKeyDown:ce,autoFocus:oe&&re===B,disabled:Ce,tabIndex:re===B&&!Ce?0:-1,onFocus:ie,onBlur:he,"aria-current":M===re?"date":void 0,"aria-label":fe,monthsPerRow:S,slots:N,slotProps:F,children:Q},Q)})}))});process.env.NODE_ENV!=="production"&&(pb.propTypes={autoFocus:s.bool,classes:s.object,className:s.string,defaultValue:s.object,disabled:s.bool,disableFuture:s.bool,disableHighlightToday:s.bool,disablePast:s.bool,gridLabelId:s.string,hasFocus:s.bool,maxDate:s.object,minDate:s.object,monthsPerRow:s.oneOf([3,4]),onChange:s.func,onFocusedViewChange:s.func,onMonthFocus:s.func,readOnly:s.bool,referenceDate:s.object,shouldDisableMonth:s.func,slotProps:s.object,slots:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),timezone:s.string,value:s.object});function HV(e){return Oe("MuiPickersYear",e)}const Ga=De("MuiPickersYear",["root","yearButton","selected","disabled"]),zV=["autoFocus","className","children","disabled","selected","value","tabIndex","onClick","onKeyDown","onFocus","onBlur","aria-current","yearsPerRow","slots","slotProps"],YV=e=>{const{disabled:t,selected:n,classes:o}=e;return Me({root:["root"],yearButton:["yearButton",t&&"disabled",n&&"selected"]},HV,o)},UV=ae("div",{name:"MuiPickersYear",slot:"Root",overridesResolver:(e,t)=>[t.root]})({display:"flex",alignItems:"center",justifyContent:"center",flexBasis:"33.3%",variants:[{props:{yearsPerRow:4},style:{flexBasis:"25%"}}]}),qV=ae("button",{name:"MuiPickersYear",slot:"YearButton",overridesResolver:(e,t)=>[t.yearButton,{[`&.${Ga.disabled}`]:t.disabled},{[`&.${Ga.selected}`]:t.selected}]})(({theme:e})=>Z({color:"unset",backgroundColor:"transparent",border:0,outline:0},e.typography.subtitle1,{margin:"6px 0",height:36,width:72,borderRadius:18,cursor:"pointer","&:focus":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.focusOpacity})`:ot(e.palette.action.active,e.palette.action.focusOpacity)},"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.hoverOpacity})`:ot(e.palette.action.active,e.palette.action.hoverOpacity)},"&:disabled":{cursor:"auto",pointerEvents:"none"},[`&.${Ga.disabled}`]:{color:(e.vars||e).palette.text.secondary},[`&.${Ga.selected}`]:{color:(e.vars||e).palette.primary.contrastText,backgroundColor:(e.vars||e).palette.primary.main,"&:focus, &:hover":{backgroundColor:(e.vars||e).palette.primary.dark}}})),GV=k.memo(function(t){const n=Mt({props:t,name:"MuiPickersYear"}),{autoFocus:o,className:r,children:i,disabled:a,selected:l,value:d,tabIndex:u,onClick:f,onKeyDown:p,onFocus:y,onBlur:b,"aria-current":w,slots:g,slotProps:v}=n,E=We(n,zV),P=k.useRef(null),x=YV(n);nn(()=>{o&&P.current?.focus()},[o]);const S=g?.yearButton??qV,C=dt({elementType:S,externalSlotProps:v?.yearButton,additionalProps:{children:i,disabled:a,tabIndex:u,ref:P,type:"button",role:"radio","aria-current":w,"aria-checked":l,onClick:O=>f(O,d),onKeyDown:O=>p(O,d),onFocus:O=>y(O,d),onBlur:O=>b(O,d)},ownerState:n,className:x.yearButton});return D.jsx(UV,Z({className:Se(x.root,r),ownerState:n},E,{children:D.jsx(S,Z({},C))}))});function KV(e){return Oe("MuiYearCalendar",e)}De("MuiYearCalendar",["root"]);const XV=["autoFocus","className","value","defaultValue","referenceDate","disabled","disableFuture","disablePast","maxDate","minDate","onChange","readOnly","shouldDisableYear","disableHighlightToday","onYearFocus","hasFocus","onFocusedViewChange","yearsOrder","yearsPerRow","timezone","gridLabelId","slots","slotProps"],ZV=e=>{const{classes:t}=e;return Me({root:["root"]},KV,t)};function QV(e,t){const n=Nt(),o=ya(),r=Mt({props:e,name:t});return Z({disablePast:!1,disableFuture:!1},r,{yearsPerRow:r.yearsPerRow??3,minDate:Xn(n,r.minDate,o.minDate),maxDate:Xn(n,r.maxDate,o.maxDate)})}const JV=ae("div",{name:"MuiYearCalendar",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"flex",flexDirection:"row",flexWrap:"wrap",overflowY:"auto",height:"100%",padding:"0 4px",width:Cc,maxHeight:OL,boxSizing:"border-box",position:"relative"}),mb=k.forwardRef(function(t,n){const o=QV(t,"MuiYearCalendar"),{autoFocus:r,className:i,value:a,defaultValue:l,referenceDate:d,disabled:u,disableFuture:f,disablePast:p,maxDate:y,minDate:b,onChange:w,readOnly:g,shouldDisableYear:v,onYearFocus:E,hasFocus:P,onFocusedViewChange:x,yearsOrder:S="asc",yearsPerRow:C,timezone:O,gridLabelId:N,slots:F,slotProps:z}=o,R=We(o,XV),{value:$,handleValueChange:K,timezone:X}=wh({name:"YearCalendar",timezone:O,value:a,defaultValue:l,onChange:w,valueManager:Po}),q=bc(X),Y=lo(),H=Nt(),le=k.useMemo(()=>Po.getInitialReferenceValue({value:$,utils:H,props:o,timezone:X,referenceDate:d,granularity:wo.year}),[]),A=o,M=ZV(A),V=k.useMemo(()=>H.getYear(q),[H,q]),B=k.useMemo(()=>$!=null?H.getYear($):null,[$,H]),[ne,oe]=k.useState(()=>B||H.getYear(le)),[se,j]=ko({name:"YearCalendar",state:"hasFocus",controlled:P,default:r??!1}),J=ke(ve=>{j(ve),x&&x(ve)}),ee=k.useCallback(ve=>{if(p&&H.isBeforeYear(ve,q)||f&&H.isAfterYear(ve,q)||b&&H.isBeforeYear(ve,b)||y&&H.isAfterYear(ve,y))return!0;if(!v)return!1;const xe=H.startOfYear(ve);return v(xe)},[f,p,y,b,q,v,H]),te=ke((ve,xe)=>{if(g)return;const Ve=H.setYear($??le,xe);K(Ve)}),ce=ke(ve=>{ee(H.setYear($??le,ve))||(oe(ve),J(!0),E?.(ve))});k.useEffect(()=>{oe(ve=>B!==null&&ve!==B?B:ve)},[B]);const ie=S!=="desc"?C*1:C*-1,he=Y&&S==="asc"||!Y&&S==="desc"?-1:1,W=ke((ve,xe)=>{switch(ve.key){case"ArrowUp":ce(xe-ie),ve.preventDefault();break;case"ArrowDown":ce(xe+ie),ve.preventDefault();break;case"ArrowLeft":ce(xe-he),ve.preventDefault();break;case"ArrowRight":ce(xe+he),ve.preventDefault();break}}),re=ke((ve,xe)=>{ce(xe)}),Q=ke((ve,xe)=>{ne===xe&&J(!1)}),fe=k.useRef(null),me=at(n,fe);k.useEffect(()=>{if(r||fe.current===null)return;const ve=fe.current.querySelector('[tabindex="0"]');if(!ve)return;const xe=ve.offsetHeight,Ve=ve.offsetTop,Ae=fe.current.clientHeight,st=fe.current.scrollTop,Pe=Ve+xe;xe>Ae||Ve<st||(fe.current.scrollTop=Pe-Ae/2-xe/2)},[r]);const Ce=H.getYearRange([b,y]);return S==="desc"&&Ce.reverse(),D.jsx(JV,Z({ref:me,className:Se(M.root,i),ownerState:A,role:"radiogroup","aria-labelledby":N},R,{children:Ce.map(ve=>{const xe=H.getYear(ve),Ve=xe===B,Ae=u||ee(ve);return D.jsx(GV,{selected:Ve,value:xe,onClick:te,onKeyDown:W,autoFocus:se&&xe===ne,disabled:Ae,tabIndex:xe===ne&&!Ae?0:-1,onFocus:re,onBlur:Q,"aria-current":V===xe?"date":void 0,yearsPerRow:C,slots:F,slotProps:z,children:H.format(ve,"year")},H.format(ve,"year"))})}))});process.env.NODE_ENV!=="production"&&(mb.propTypes={autoFocus:s.bool,classes:s.object,className:s.string,defaultValue:s.object,disabled:s.bool,disableFuture:s.bool,disableHighlightToday:s.bool,disablePast:s.bool,gridLabelId:s.string,hasFocus:s.bool,maxDate:s.object,minDate:s.object,onChange:s.func,onFocusedViewChange:s.func,onYearFocus:s.func,readOnly:s.bool,referenceDate:s.object,shouldDisableYear:s.func,slotProps:s.object,slots:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),timezone:s.string,value:s.object,yearsOrder:s.oneOf(["asc","desc"]),yearsPerRow:s.oneOf([3,4])});const ej=e=>Oe("MuiPickersCalendarHeader",e),tj=De("MuiPickersCalendarHeader",["root","labelContainer","label","switchViewButton","switchViewIcon"]);function nj(e){return Oe("MuiPickersArrowSwitcher",e)}De("MuiPickersArrowSwitcher",["root","spacer","button","previousIconButton","nextIconButton","leftArrowIcon","rightArrowIcon"]);const oj=["children","className","slots","slotProps","isNextDisabled","isNextHidden","onGoToNext","nextLabel","isPreviousDisabled","isPreviousHidden","onGoToPrevious","previousLabel","labelId"],rj=["ownerState"],sj=["ownerState"],ij=ae("div",{name:"MuiPickersArrowSwitcher",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"flex"}),aj=ae("div",{name:"MuiPickersArrowSwitcher",slot:"Spacer",overridesResolver:(e,t)=>t.spacer})(({theme:e})=>({width:e.spacing(3)})),Dm=ae($s,{name:"MuiPickersArrowSwitcher",slot:"Button",overridesResolver:(e,t)=>t.button})({variants:[{props:{hidden:!0},style:{visibility:"hidden"}}]}),lj=e=>{const{classes:t}=e;return Me({root:["root"],spacer:["spacer"],button:["button"],previousIconButton:["previousIconButton"],nextIconButton:["nextIconButton"],leftArrowIcon:["leftArrowIcon"],rightArrowIcon:["rightArrowIcon"]},nj,t)},cj=k.forwardRef(function(t,n){const o=lo(),r=Mt({props:t,name:"MuiPickersArrowSwitcher"}),{children:i,className:a,slots:l,slotProps:d,isNextDisabled:u,isNextHidden:f,onGoToNext:p,nextLabel:y,isPreviousDisabled:b,isPreviousHidden:w,onGoToPrevious:g,previousLabel:v,labelId:E}=r,P=We(r,oj),x=r,S=lj(x),C={isDisabled:u,isHidden:f,goTo:p,label:y},O={isDisabled:b,isHidden:w,goTo:g,label:v},N=l?.previousIconButton??Dm,F=dt({elementType:N,externalSlotProps:d?.previousIconButton,additionalProps:{size:"medium",title:O.label,"aria-label":O.label,disabled:O.isDisabled,edge:"end",onClick:O.goTo},ownerState:Z({},x,{hidden:O.isHidden}),className:Se(S.button,S.previousIconButton)}),z=l?.nextIconButton??Dm,R=dt({elementType:z,externalSlotProps:d?.nextIconButton,additionalProps:{size:"medium",title:C.label,"aria-label":C.label,disabled:C.isDisabled,edge:"start",onClick:C.goTo},ownerState:Z({},x,{hidden:C.isHidden}),className:Se(S.button,S.nextIconButton)}),$=l?.leftArrowIcon??UL,K=dt({elementType:$,externalSlotProps:d?.leftArrowIcon,additionalProps:{fontSize:"inherit"},ownerState:x,className:S.leftArrowIcon}),X=We(K,rj),q=l?.rightArrowIcon??qL,Y=dt({elementType:q,externalSlotProps:d?.rightArrowIcon,additionalProps:{fontSize:"inherit"},ownerState:x,className:S.rightArrowIcon}),H=We(Y,sj);return D.jsxs(ij,Z({ref:n,className:Se(S.root,a),ownerState:x},P,{children:[D.jsx(N,Z({},F,{children:o?D.jsx(q,Z({},H)):D.jsx($,Z({},X))})),i?D.jsx(kn,{variant:"subtitle1",component:"span",id:E,children:i}):D.jsx(aj,{className:S.spacer,ownerState:x}),D.jsx(z,Z({},R,{children:o?D.jsx($,Z({},X)):D.jsx(q,Z({},H))}))]}))});function dj(e,{disableFuture:t,maxDate:n,timezone:o}){const r=Nt();return k.useMemo(()=>{const i=r.date(void 0,o),a=r.startOfMonth(t&&r.isBefore(i,n)?i:n);return!r.isAfter(a,e)},[t,n,e,r,o])}function uj(e,{disablePast:t,minDate:n,timezone:o}){const r=Nt();return k.useMemo(()=>{const i=r.date(void 0,o),a=r.startOfMonth(t&&r.isAfter(i,n)?i:n);return!r.isBefore(a,e)},[t,n,e,r,o])}const hj=["slots","slotProps","currentMonth","disabled","disableFuture","disablePast","maxDate","minDate","onMonthChange","onViewChange","view","reduceAnimations","views","labelId","className","timezone","format"],fj=["ownerState"],pj=e=>{const{classes:t}=e;return Me({root:["root"],labelContainer:["labelContainer"],label:["label"],switchViewButton:["switchViewButton"],switchViewIcon:["switchViewIcon"]},ej,t)},mj=ae("div",{name:"MuiPickersCalendarHeader",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"flex",alignItems:"center",marginTop:12,marginBottom:4,paddingLeft:24,paddingRight:12,maxHeight:40,minHeight:40}),gj=ae("div",{name:"MuiPickersCalendarHeader",slot:"LabelContainer",overridesResolver:(e,t)=>t.labelContainer})(({theme:e})=>Z({display:"flex",overflow:"hidden",alignItems:"center",cursor:"pointer",marginRight:"auto"},e.typography.body1,{fontWeight:e.typography.fontWeightMedium})),yj=ae("div",{name:"MuiPickersCalendarHeader",slot:"Label",overridesResolver:(e,t)=>t.label})({marginRight:6}),vj=ae($s,{name:"MuiPickersCalendarHeader",slot:"SwitchViewButton",overridesResolver:(e,t)=>t.switchViewButton})({marginRight:"auto",variants:[{props:{view:"year"},style:{[`.${tj.switchViewIcon}`]:{transform:"rotate(180deg)"}}}]}),bj=ae(YL,{name:"MuiPickersCalendarHeader",slot:"SwitchViewIcon",overridesResolver:(e,t)=>t.switchViewIcon})(({theme:e})=>({willChange:"transform",transition:e.transitions.create("transform"),transform:"rotate(0deg)"})),gb=k.forwardRef(function(t,n){const o=rr(),r=Nt(),i=Mt({props:t,name:"MuiPickersCalendarHeader"}),{slots:a,slotProps:l,currentMonth:d,disabled:u,disableFuture:f,disablePast:p,maxDate:y,minDate:b,onMonthChange:w,onViewChange:g,view:v,reduceAnimations:E,views:P,labelId:x,className:S,timezone:C,format:O=`${r.formats.month} ${r.formats.year}`}=i,N=We(i,hj),F=i,z=pj(i),R=a?.switchViewButton??vj,$=dt({elementType:R,externalSlotProps:l?.switchViewButton,additionalProps:{size:"small","aria-label":o.calendarViewSwitchingButtonAriaLabel(v)},ownerState:F,className:z.switchViewButton}),K=a?.switchViewIcon??bj,X=dt({elementType:K,externalSlotProps:l?.switchViewIcon,ownerState:F,className:z.switchViewIcon}),q=We(X,fj),Y=()=>w(r.addMonths(d,1),"left"),H=()=>w(r.addMonths(d,-1),"right"),le=dj(d,{disableFuture:f,maxDate:y,timezone:C}),A=uj(d,{disablePast:p,minDate:b,timezone:C}),M=()=>{if(!(P.length===1||!g||u))if(P.length===2)g(P.find(B=>B!==v)||P[0]);else{const B=P.indexOf(v)!==0?0:1;g(P[B])}};if(P.length===1&&P[0]==="year")return null;const V=r.formatByString(d,O);return D.jsxs(mj,Z({},N,{ownerState:F,className:Se(z.root,S),ref:n,children:[D.jsxs(gj,{role:"presentation",onClick:M,ownerState:F,"aria-live":"polite",className:z.labelContainer,children:[D.jsx(cb,{reduceAnimations:E,transKey:V,children:D.jsx(yj,{id:x,ownerState:F,className:z.label,children:V})}),P.length>1&&!u&&D.jsx(R,Z({},$,{children:D.jsx(K,Z({},q))}))]}),D.jsx(Wr,{in:v==="day",children:D.jsx(cj,{slots:a,slotProps:l,onGoToPrevious:H,isPreviousDisabled:A,previousLabel:o.previousMonth,onGoToNext:Y,isNextDisabled:le,nextLabel:o.nextMonth})})]}))});process.env.NODE_ENV!=="production"&&(gb.propTypes={classes:s.object,className:s.string,currentMonth:s.object.isRequired,disabled:s.bool,disableFuture:s.bool,disablePast:s.bool,format:s.string,labelId:s.string,maxDate:s.object.isRequired,minDate:s.object.isRequired,onMonthChange:s.func.isRequired,onViewChange:s.func,reduceAnimations:s.bool.isRequired,slotProps:s.object,slots:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),timezone:s.string.isRequired,view:s.oneOf(["day","month","year"]).isRequired,views:s.arrayOf(s.oneOf(["day","month","year"]).isRequired).isRequired});const wj=ae("div")({overflow:"hidden",width:Cc,maxHeight:Ch,display:"flex",flexDirection:"column",margin:"0 auto"}),Cj=e=>Oe("MuiDateCalendar",e);De("MuiDateCalendar",["root","viewTransitionContainer"]);const Sj=["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"],_j=e=>{const{classes:t}=e;return Me({root:["root"],viewTransitionContainer:["viewTransitionContainer"]},Cj,t)};function xj(e,t){const n=Nt(),o=ya(),r=Gv(),i=Mt({props:e,name:t});return Z({},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??r,renderLoading:i.renderLoading??(()=>D.jsx("span",{children:"..."})),minDate:Xn(n,i.minDate,o.minDate),maxDate:Xn(n,i.maxDate,o.maxDate)})}const Rj=ae(wj,{name:"MuiDateCalendar",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"flex",flexDirection:"column",height:Ch}),kj=ae(cb,{name:"MuiDateCalendar",slot:"ViewTransitionContainer",overridesResolver:(e,t)=>t.viewTransitionContainer})({}),yb=k.forwardRef(function(t,n){const o=Nt(),r=yr(),i=xj(t,"MuiDateCalendar"),{autoFocus:a,onViewChange:l,value:d,defaultValue:u,referenceDate:f,disableFuture:p,disablePast:y,onChange:b,onYearChange:w,onMonthChange:g,reduceAnimations:v,shouldDisableDate:E,shouldDisableMonth:P,shouldDisableYear:x,view:S,views:C,openTo:O,className:N,disabled:F,readOnly:z,minDate:R,maxDate:$,disableHighlightToday:K,focusedView:X,onFocusedViewChange:q,showDaysOutsideCurrentMonth:Y,fixedWeekNumber:H,dayOfWeekFormatter:le,slots:A,slotProps:M,loading:V,renderLoading:B,displayWeekNumber:ne,yearsOrder:oe,yearsPerRow:se,monthsPerRow:j,timezone:J}=i,ee=We(i,Sj),{value:te,handleValueChange:ce,timezone:ie}=wh({name:"DateCalendar",timezone:J,value:d,defaultValue:u,onChange:b,valueManager:Po}),{view:he,setView:W,focusedView:re,setFocusedView:Q,goToNextView:fe,setValueAndGoToNextView:me}=Kv({view:S,views:C,openTo:O,onChange:ce,onViewChange:l,autoFocus:a,focusedView:X,onFocusedViewChange:q}),{referenceDate:Ce,calendarState:ve,changeFocusedDay:xe,changeMonth:Ve,handleChangeMonth:Ae,isDateDisabled:st,onMonthSwitchingAnimationEnd:Pe}=nV({value:te,referenceDate:f,reduceAnimations:v,onMonthChange:g,minDate:R,maxDate:$,shouldDisableDate:E,disablePast:y,disableFuture:p,timezone:ie}),ft=F&&te||R,Kt=F&&te||$,it=`${r}-grid-label`,Yt=re!==null,Xt=A?.calendarHeader??gb,on=dt({elementType:Xt,externalSlotProps:M?.calendarHeader,additionalProps:{views:C,view:he,currentMonth:ve.currentMonth,onViewChange:W,onMonthChange:(pt,Qt)=>Ae({newMonth:pt,direction:Qt}),minDate:ft,maxDate:Kt,disabled:F,disablePast:y,disableFuture:p,reduceAnimations:v,timezone:ie,labelId:it},ownerState:i}),Ue=ke(pt=>{const Qt=o.startOfMonth(pt),vn=o.endOfMonth(pt),Jt=st(pt)?Ei({utils:o,date:pt,minDate:o.isBefore(R,Qt)?Qt:R,maxDate:o.isAfter($,vn)?vn:$,disablePast:y,disableFuture:p,isDateDisabled:st,timezone:ie}):pt;Jt?(me(Jt,"finish"),g?.(Qt)):(fe(),Ve(Qt)),xe(Jt,!0)}),tt=ke(pt=>{const Qt=o.startOfYear(pt),vn=o.endOfYear(pt),Jt=st(pt)?Ei({utils:o,date:pt,minDate:o.isBefore(R,Qt)?Qt:R,maxDate:o.isAfter($,vn)?vn:$,disablePast:y,disableFuture:p,isDateDisabled:st,timezone:ie}):pt;Jt?(me(Jt,"finish"),w?.(Jt)):(fe(),Ve(Qt)),xe(Jt,!0)}),Mn=ke(pt=>ce(pt&&Tl(o,pt,te??Ce),"finish",he));k.useEffect(()=>{te!=null&&o.isValid(te)&&Ve(te)},[te]);const hn=i,Ie=_j(hn),He={disablePast:y,disableFuture:p,maxDate:$,minDate:R},vt={disableHighlightToday:K,readOnly:z,disabled:F,timezone:ie,gridLabelId:it,slots:A,slotProps:M},ln=k.useRef(he);k.useEffect(()=>{ln.current!==he&&(re===ln.current&&Q(he,!0),ln.current=he)},[re,Q,he]);const ho=k.useMemo(()=>[te],[te]);return D.jsxs(Rj,Z({ref:n,className:Se(Ie.root,N),ownerState:hn},ee,{children:[D.jsx(Xt,Z({},on,{slots:A,slotProps:M})),D.jsx(kj,{reduceAnimations:v,className:Ie.viewTransitionContainer,transKey:he,ownerState:hn,children:D.jsxs("div",{children:[he==="year"&&D.jsx(mb,Z({},He,vt,{value:te,onChange:tt,shouldDisableYear:x,hasFocus:Yt,onFocusedViewChange:pt=>Q("year",pt),yearsOrder:oe,yearsPerRow:se,referenceDate:Ce})),he==="month"&&D.jsx(pb,Z({},He,vt,{hasFocus:Yt,className:N,value:te,onChange:Ue,shouldDisableMonth:P,onFocusedViewChange:pt=>Q("month",pt),monthsPerRow:j,referenceDate:Ce})),he==="day"&&D.jsx(OV,Z({},ve,He,vt,{onMonthSwitchingAnimationEnd:Pe,onFocusedDayChange:xe,reduceAnimations:v,selectedDays:ho,onSelectedDaysChange:Mn,shouldDisableDate:E,shouldDisableMonth:P,shouldDisableYear:x,hasFocus:Yt,onFocusedViewChange:pt=>Q("day",pt),showDaysOutsideCurrentMonth:Y,fixedWeekNumber:H,dayOfWeekFormatter:le,displayWeekNumber:ne,loading:V,renderLoading:B}))]})})]}))});process.env.NODE_ENV!=="production"&&(yb.propTypes={autoFocus:s.bool,classes:s.object,className:s.string,dayOfWeekFormatter:s.func,defaultValue:s.object,disabled:s.bool,disableFuture:s.bool,disableHighlightToday:s.bool,disablePast:s.bool,displayWeekNumber:s.bool,fixedWeekNumber:s.number,focusedView:s.oneOf(["day","month","year"]),loading:s.bool,maxDate:s.object,minDate:s.object,monthsPerRow:s.oneOf([3,4]),onChange:s.func,onFocusedViewChange:s.func,onMonthChange:s.func,onViewChange:s.func,onYearChange:s.func,openTo:s.oneOf(["day","month","year"]),readOnly:s.bool,reduceAnimations:s.bool,referenceDate:s.object,renderLoading:s.func,shouldDisableDate:s.func,shouldDisableMonth:s.func,shouldDisableYear:s.func,showDaysOutsideCurrentMonth:s.bool,slotProps:s.object,slots:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),timezone:s.string,value:s.object,view:s.oneOf(["day","month","year"]),views:s.arrayOf(s.oneOf(["day","month","year"]).isRequired),yearsOrder:s.oneOf(["asc","desc"]),yearsPerRow:s.oneOf([3,4])});const xs=({view:e,onViewChange:t,views:n,focusedView:o,onFocusedViewChange:r,value:i,defaultValue:a,referenceDate:l,onChange:d,className:u,classes:f,disableFuture:p,disablePast:y,minDate:b,maxDate:w,shouldDisableDate:g,shouldDisableMonth:v,shouldDisableYear:E,reduceAnimations:P,onMonthChange:x,monthsPerRow:S,onYearChange:C,yearsOrder:O,yearsPerRow:N,slots:F,slotProps:z,loading:R,renderLoading:$,disableHighlightToday:K,readOnly:X,disabled:q,showDaysOutsideCurrentMonth:Y,dayOfWeekFormatter:H,sx:le,autoFocus:A,fixedWeekNumber:M,displayWeekNumber:V,timezone:B})=>D.jsx(yb,{view:e,onViewChange:t,views:n.filter(mm),focusedView:o&&mm(o)?o:null,onFocusedViewChange:r,value:i,defaultValue:a,referenceDate:l,onChange:d,className:u,classes:f,disableFuture:p,disablePast:y,minDate:b,maxDate:w,shouldDisableDate:g,shouldDisableMonth:v,shouldDisableYear:E,reduceAnimations:P,onMonthChange:x,monthsPerRow:S,onYearChange:C,yearsOrder:O,yearsPerRow:N,slots:F,slotProps:z,loading:R,renderLoading:$,disableHighlightToday:K,readOnly:X,disabled:q,showDaysOutsideCurrentMonth:Y,dayOfWeekFormatter:H,sx:le,autoFocus:A,fixedWeekNumber:M,displayWeekNumber:V,timezone:B}),vb=k.forwardRef(function(t,n){const o=rr(),r=Nt(),i=zv(t,"MuiDesktopDatePicker"),a=Z({day:xs,month:xs,year:xs},i.viewRenderers),l=Z({},i,{viewRenderers:a,format:mh(r,i,!1),yearsPerRow:i.yearsPerRow??4,slots:Z({openPickerIcon:GL,field:Th},i.slots),slotProps:Z({},i.slotProps,{field:u=>Z({},Ul(i.slotProps?.field,u),Uv(i),{ref:n}),toolbar:Z({hidden:!0},i.slotProps?.toolbar)})}),{renderPicker:d}=zL({props:l,valueManager:Po,valueType:"date",getOpenDialogAriaText:Bv({utils:r,formatKey:"fullDate",contextTranslation:o.openDatePickerDialogue,propsTranslation:l.localeText?.openDatePickerDialogue}),validator:va});return d()});vb.propTypes={autoFocus:s.bool,className:s.string,closeOnSelect:s.bool,dayOfWeekFormatter:s.func,defaultValue:s.object,disabled:s.bool,disableFuture:s.bool,disableHighlightToday:s.bool,disableOpenPicker:s.bool,disablePast:s.bool,displayWeekNumber:s.bool,enableAccessibleFieldDOMStructure:s.any,fixedWeekNumber:s.number,format:s.string,formatDensity:s.oneOf(["dense","spacious"]),inputRef:Bt,label:s.node,loading:s.bool,localeText:s.object,maxDate:s.object,minDate:s.object,monthsPerRow:s.oneOf([3,4]),name:s.string,onAccept:s.func,onChange:s.func,onClose:s.func,onError:s.func,onMonthChange:s.func,onOpen:s.func,onSelectedSectionsChange:s.func,onViewChange:s.func,onYearChange:s.func,open:s.bool,openTo:s.oneOf(["day","month","year"]),orientation:s.oneOf(["landscape","portrait"]),readOnly:s.bool,reduceAnimations:s.bool,referenceDate:s.object,renderLoading:s.func,selectedSections:s.oneOfType([s.oneOf(["all","day","empty","hours","meridiem","minutes","month","seconds","weekDay","year"]),s.number]),shouldDisableDate:s.func,shouldDisableMonth:s.func,shouldDisableYear:s.func,showDaysOutsideCurrentMonth:s.bool,slotProps:s.object,slots:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),timezone:s.string,value:s.object,view:s.oneOf(["day","month","year"]),viewRenderers:s.shape({day:s.func,month:s.func,year:s.func}),views:s.arrayOf(s.oneOf(["day","month","year"]).isRequired),yearsOrder:s.oneOf(["asc","desc"]),yearsPerRow:s.oneOf([3,4])};const Tj=ae(iy)({[`& .${Ri.container}`]:{outline:0},[`& .${Ri.paper}`]:{outline:0,minWidth:Cc}}),Ej=ae(ly)({"&:first-of-type":{padding:0}});function Pj(e){const{children:t,onDismiss:n,open:o,slots:r,slotProps:i}=e,a=r?.dialog??Tj,l=r?.mobileTransition??Wr;return D.jsx(a,Z({open:o,onClose:n},i?.dialog,{TransitionComponent:l,TransitionProps:i?.mobileTransition,PaperComponent:r?.mobilePaper,PaperProps:i?.mobilePaper,children:D.jsx(Ej,{children:t})}))}const Dj=["props","getOpenDialogAriaText"],Oj=e=>{let{props:t,getOpenDialogAriaText:n}=e,o=We(e,Dj);const{slots:r,slotProps:i,className:a,sx:l,format:d,formatDensity:u,enableAccessibleFieldDOMStructure:f,selectedSections:p,onSelectedSectionsChange:y,timezone:b,name:w,label:g,inputRef:v,readOnly:E,disabled:P,localeText:x}=t,S=k.useRef(null),C=yr(),O=i?.toolbar?.hidden??!1,{open:N,actions:F,layoutProps:z,renderCurrentView:R,fieldProps:$,contextValue:K}=Xv(Z({},o,{props:t,fieldRef:S,autoFocusView:!0,additionalViewProps:{},wrapperVariant:"mobile"})),X=r.field,q=dt({elementType:X,externalSlotProps:i?.field,additionalProps:Z({},$,O&&{id:C},!(P||E)&&{onClick:F.onOpen,onKeyDown:aL(F.onOpen)},{readOnly:E??!0,disabled:P,className:a,sx:l,format:d,formatDensity:u,enableAccessibleFieldDOMStructure:f,selectedSections:p,onSelectedSectionsChange:y,timezone:b,label:g,name:w},v?{inputRef:v}:{}),ownerState:t});q.inputProps=Z({},q.inputProps,{"aria-label":n($.value)});const Y=Z({textField:r.textField},q.slots),H=r.layout??Sh;let le=C;O&&(g?le=`${C}-label`:le=void 0);const A=Z({},i,{toolbar:Z({},i?.toolbar,{titleId:C}),mobilePaper:Z({"aria-labelledby":le},i?.mobilePaper)}),M=at(S,q.unstableFieldRef);return{renderPicker:()=>D.jsxs(eb,{contextValue:K,localeText:x,children:[D.jsx(X,Z({},q,{slots:Y,slotProps:A,unstableFieldRef:M})),D.jsx(Pj,Z({},F,{open:N,slots:r,slotProps:A,children:D.jsx(H,Z({},z,A?.layout,{slots:r,slotProps:A,children:R()}))}))]})}},bb=k.forwardRef(function(t,n){const o=rr(),r=Nt(),i=zv(t,"MuiMobileDatePicker"),a=Z({day:xs,month:xs,year:xs},i.viewRenderers),l=Z({},i,{viewRenderers:a,format:mh(r,i,!1),slots:Z({field:Th},i.slots),slotProps:Z({},i.slotProps,{field:u=>Z({},Ul(i.slotProps?.field,u),Uv(i),{ref:n}),toolbar:Z({hidden:!1},i.slotProps?.toolbar)})}),{renderPicker:d}=Oj({props:l,valueManager:Po,valueType:"date",getOpenDialogAriaText:Bv({utils:r,formatKey:"fullDate",contextTranslation:o.openDatePickerDialogue,propsTranslation:l.localeText?.openDatePickerDialogue}),validator:va});return d()});bb.propTypes={autoFocus:s.bool,className:s.string,closeOnSelect:s.bool,dayOfWeekFormatter:s.func,defaultValue:s.object,disabled:s.bool,disableFuture:s.bool,disableHighlightToday:s.bool,disableOpenPicker:s.bool,disablePast:s.bool,displayWeekNumber:s.bool,enableAccessibleFieldDOMStructure:s.any,fixedWeekNumber:s.number,format:s.string,formatDensity:s.oneOf(["dense","spacious"]),inputRef:Bt,label:s.node,loading:s.bool,localeText:s.object,maxDate:s.object,minDate:s.object,monthsPerRow:s.oneOf([3,4]),name:s.string,onAccept:s.func,onChange:s.func,onClose:s.func,onError:s.func,onMonthChange:s.func,onOpen:s.func,onSelectedSectionsChange:s.func,onViewChange:s.func,onYearChange:s.func,open:s.bool,openTo:s.oneOf(["day","month","year"]),orientation:s.oneOf(["landscape","portrait"]),readOnly:s.bool,reduceAnimations:s.bool,referenceDate:s.object,renderLoading:s.func,selectedSections:s.oneOfType([s.oneOf(["all","day","empty","hours","meridiem","minutes","month","seconds","weekDay","year"]),s.number]),shouldDisableDate:s.func,shouldDisableMonth:s.func,shouldDisableYear:s.func,showDaysOutsideCurrentMonth:s.bool,slotProps:s.object,slots:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),timezone:s.string,value:s.object,view:s.oneOf(["day","month","year"]),viewRenderers:s.shape({day:s.func,month:s.func,year:s.func}),views:s.arrayOf(s.oneOf(["day","month","year"]).isRequired),yearsOrder:s.oneOf(["asc","desc"]),yearsPerRow:s.oneOf([3,4])};const Mj=["desktopModeMediaQuery"],Pl=k.forwardRef(function(t,n){const o=Mt({props:t,name:"MuiDatePicker"}),{desktopModeMediaQuery:r=lL}=o,i=We(o,Mj);return mg(r,{defaultMatches:!0})?D.jsx(vb,Z({ref:n},i)):D.jsx(bb,Z({ref:n},i))});process.env.NODE_ENV!=="production"&&(Pl.propTypes={autoFocus:s.bool,className:s.string,closeOnSelect:s.bool,dayOfWeekFormatter:s.func,defaultValue:s.object,desktopModeMediaQuery:s.string,disabled:s.bool,disableFuture:s.bool,disableHighlightToday:s.bool,disableOpenPicker:s.bool,disablePast:s.bool,displayWeekNumber:s.bool,enableAccessibleFieldDOMStructure:s.any,fixedWeekNumber:s.number,format:s.string,formatDensity:s.oneOf(["dense","spacious"]),inputRef:Bt,label:s.node,loading:s.bool,localeText:s.object,maxDate:s.object,minDate:s.object,monthsPerRow:s.oneOf([3,4]),name:s.string,onAccept:s.func,onChange:s.func,onClose:s.func,onError:s.func,onMonthChange:s.func,onOpen:s.func,onSelectedSectionsChange:s.func,onViewChange:s.func,onYearChange:s.func,open:s.bool,openTo:s.oneOf(["day","month","year"]),orientation:s.oneOf(["landscape","portrait"]),readOnly:s.bool,reduceAnimations:s.bool,referenceDate:s.object,renderLoading:s.func,selectedSections:s.oneOfType([s.oneOf(["all","day","empty","hours","meridiem","minutes","month","seconds","weekDay","year"]),s.number]),shouldDisableDate:s.func,shouldDisableMonth:s.func,shouldDisableYear:s.func,showDaysOutsideCurrentMonth:s.bool,slotProps:s.object,slots:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),timezone:s.string,value:s.object,view:s.oneOf(["day","month","year"]),viewRenderers:s.shape({day:s.func,month:s.func,year:s.func}),views:s.arrayOf(s.oneOf(["day","month","year"]).isRequired),yearsOrder:s.oneOf(["asc","desc"]),yearsPerRow:s.oneOf([3,4])});const ru=ae(Do)({"& label[data-shrink=false]":{top:"-5px",fontSize:"14px"},"& .MuiOutlinedInput-root":{height:"40px"}}),Ij=({setValue:e,value:t})=>{function n(r){const i=r?.format(jr.db)||"",a={...t,1:i===Jd?Is[1]:i};e(a),tr(a)}function o(r){const i=r?.format(jr.db)||"",a={...t,2:i===Jd?Is[2]:i};e(a),tr(a)}return D.jsxs(vc,{dateAdapter:Nv,children:[D.jsx(ru,{children:D.jsx(Pl,{label:oo.from,onChange:n,...nu(t[1])})}),D.jsx(ru,{children:D.jsx(Pl,{label:oo.to,onChange:o,...nu(t[2])})})]})},kd=({label:e,setValue:t,value:n})=>{function o(r){const i=r?.format(jr.db)||"",a={...n,1:i===Jd?Is[1]:i};t(a),tr(a)}return D.jsx(vc,{dateAdapter:Nv,children:D.jsx(ru,{children:D.jsx(Pl,{label:e,onChange:o,...nu(n[1])})})})},Om={label:"",options:[]};function Nj(){const{columnId:e,table:t}=wn,n=t?.grid;if(!n)return Om;const o=n?.getColumns().find(({id:p})=>p===e);if(!o)return Om;const r=o.name,i=[],{formatter:a,id:l}=o,d=n.getData(),u=new Set;d.getItems().forEach(p=>{u.add(a?a(0,0,p[l],o,null,n):p[l])});for(const p of u)i.push(p);return{label:r,options:i}}function Aj(e,t){return typeof e=="string"&&typeof t=="string"?e.localeCompare(t):typeof e=="number"&&typeof t=="number"?e-t:0}const Fj=ae(tc)({padding:0}),Mm={Checkbox:Fj},Lj=({setValue:e,value:t})=>{const n=JSON.parse(t[1]||'["All"]'),{label:o,options:r}=Nj(),i=a=>{const l=a.target.value;let d;l[l.length-1]==="All"||!l.length?d={1:"",2:""}:(l.length>1&&l[0]==="All"&&l.shift(),d={...t,1:JSON.stringify(l)}),e(d),tr(d)};return D.jsxs(ca,{size:"small",children:[D.jsx(da,{id:"column-filter-multiple-select-label",children:o}),D.jsxs(ua,{labelId:"column-filter-multiple-select-label",id:"column-filter-multiple-select",multiple:!0,value:n,onChange:i,input:D.jsx(Os,{label:o}),renderValue:a=>a.join(", "),children:[D.jsxs(bl,{value:"All",children:[D.jsx(Mm.Checkbox,{checked:n.indexOf("All")>-1}),D.jsx(Wd,{primary:"All"})]},0),r.sort(Aj).map(a=>D.jsxs(bl,{value:a,children:[D.jsx(Mm.Checkbox,{checked:n.indexOf(a)>-1}),D.jsx(Wd,{primary:a})]},a))]})]})},$j=({setValue:e,value:t})=>{function n(r){const i={...t,1:r.target.value};e(i),tr(i)}function o(r){const i={...t,2:r.target.value};e(i),tr(i)}return D.jsxs($e.Fragment,{children:[D.jsx(Ms,{label:oo.from,value:t[1],type:"number",onChange:n,size:"small",autoComplete:"off"}),D.jsx(Ms,{label:oo.to,value:t[2],type:"number",onChange:o,size:"small",autoComplete:"off"})]})},Td=({label:e,setValue:t,value:n})=>{function o(r){const i={...n,1:r.target.value};t(i),tr(i)}return D.jsx(Ms,{label:e,value:n[1],type:"number",onChange:o,size:"small",autoComplete:"off"})},Ka=({setValue:e,value:t})=>{function n(o){const r={...t,1:o.target.value};e(r),tr(r)}return D.jsx(Ms,{label:oo.filter,value:t[1],onChange:n,size:"small",autoComplete:"off"})},Vj=({filterId:e,setValue:t,value:n})=>D.jsxs($e.Fragment,{children:[e===je.Boolean&&D.jsx(pF,{setValue:t,value:n}),e===je.TextEqual&&D.jsx(Ka,{setValue:t,value:n}),e===je.TextNotEqual&&D.jsx(Ka,{setValue:t,value:n}),e===je.TextContain&&D.jsx(Ka,{setValue:t,value:n}),e===je.TextNotContain&&D.jsx(Ka,{setValue:t,value:n}),e===je.MultipleSelect&&D.jsx(Lj,{setValue:t,value:n}),e===je.NumberEqual&&D.jsx(Td,{label:oo.filter,setValue:t,value:n}),e===je.NumberFrom&&D.jsx(Td,{label:oo.from,setValue:t,value:n}),e===je.NumberTo&&D.jsx(Td,{label:oo.to,setValue:t,value:n}),e===je.NumberBetween&&D.jsx($j,{setValue:t,value:n}),e===je.DateEqual&&D.jsx(kd,{label:oo.filter,setValue:t,value:n}),e===je.DateFrom&&D.jsx(kd,{label:oo.from,setValue:t,value:n}),e===je.DateTo&&D.jsx(kd,{label:oo.to,setValue:t,value:n}),e===je.DateBetween&&D.jsx(Ij,{setValue:t,value:n})]}),jj=ae(bl)({fontSize:"12px"}),Im={MenuItem:jj},Bj=({name:e,list:t,onChange:n,defaultValue:o,value:r,showSelect:i=!0,dataTestId:a,width:l="12.8em",height:d,disabled:u=!1})=>D.jsxs(ca,{variant:"outlined",size:"small",children:[D.jsx(da,{id:"reportType",children:e}),D.jsxs(ua,{labelId:"reportType",id:e,label:e,autoWidth:!0,value:`${r??(o||0)}`,defaultValue:`${o||0}`,onChange:n,disabled:u,"data-testid":a,MenuProps:{anchorOrigin:{vertical:"bottom",horizontal:"left"},transformOrigin:{vertical:"top",horizontal:"left"},disableScrollLock:!0},sx:{height:d,width:l},children:[i&&D.jsx(Im.MenuItem,{value:0,id:"Select",children:"Select"}),t.map((f,p)=>D.jsx(Im.MenuItem,{value:f.id,id:"selectedReport",disabled:f.isDisabled,children:f.labelForSelect||f.name},p))]})]}),Wj={id:je.DateBetween,name:"Between"},Hj={id:je.DateEqual,name:"Equal"},zj={id:je.DateFrom,name:"From"},Yj={id:je.DateTo,name:"To"},Uj={id:je.NumberBetween,name:"Between"},qj={id:je.NumberEqual,name:"Equal"},Gj={id:je.NumberFrom,name:"From"},Kj={id:je.NumberTo,name:"To"},Xj={id:je.TextContain,name:"Contains"},Zj={id:je.TextEqual,name:"Equal"},Qj={id:je.TextNotContain,name:"Does not contain"},Jj={id:je.TextNotEqual,name:"Not equal"},Nm=[qj,Gj,Kj,Uj],eB={[sn.Boolean]:[],[sn.Date]:[Hj,zj,Yj,Wj],[sn.MultipleSelect]:[],[sn.Number]:Nm,[sn.NumberFormatted]:Nm,[sn.Text]:[Xj,Qj,Zj,Jj]},tB=({filterId:e,setFilterId:t})=>{const n=eB[wn.group],o=n.some(({id:i})=>i===e)?e:n[0]?.id;function r(i){const{columnId:a,table:l}=wn;if(!a||!l)return;const d=l.filter.args,u=i.target.value;d.columnFilters&&(l.filter.args={...d,columnFilters:{...d.columnFilters,[a]:{...d.columnFilters[a],filterId:u}}},t(u))}return o?D.jsx(Bj,{name:"",list:n,onChange:r,width:"100%",showSelect:!1,value:o}):null},nB=ae(Do)({display:"flex",flexDirection:"column",rowGap:"0.5em",width:"12em"}),oB={Wrapper:nB},rB=()=>{const[e,t]=$e.useState(Is),[n,o]=$e.useState(je.TextContain),[r,i]=$e.useState(!1);return lF(i),aF(r,o,t),r?D.jsxs($e.Fragment,{children:[D.jsx(ju,{setIsOpened:i}),D.jsx(Bu,{id:Iv,children:D.jsxs(oB.Wrapper,{children:[D.jsx(tB,{filterId:n,setFilterId:o}),D.jsx(Vj,{filterId:n,setValue:t,value:e}),D.jsx(uF,{setIsOpened:i,setValue:t,value:e})]})})]}):null},wb="context_menu";function sB(e){$e.useEffect(()=>{function t(){e(!0),setTimeout(()=>{const n=document.getElementById(wb);if(!n)return;const{x:o,y:r}=Cn;Vu(n,o,r)},0)}return Cn.subscribe(t),()=>{Cn.unsubscribe(t)}},[])}const iB=ae("ul")({display:"flex",flexDirection:"column",rowGap:"0.5em",margin:"0",paddingLeft:"0.5em"}),aB=ae("li")({display:"flex",alignItems:"center",columnGap:"0.5em",cursor:"pointer","&:hover":{scale:"1.05"}}),lB=ae("span")({backgroundColor:"#1E456F"}),un={Ul:iB,Li:aB,Icon:lB},cB=({clientId:e,clientName:t,setIsOpened:n})=>{const o=()=>{const r=Cn.table,i=r?.grid;if(!r||!i){n(!1);return}r.downloadManager.download(r,e,t),n(!1)};return D.jsxs(un.Li,{onClick:o,children:[D.jsx(un.Icon,{className:"sgi sgi-download"}),"Download as CSV"]})},dB=({setIsOpened:e})=>{const t=Cn.table;function n(){t&&(t.grouping={isGrouped:!0},e(!1))}return t?.grouping.isGrouped!==!1?null:D.jsxs(un.Li,{onClick:n,children:[D.jsx(un.Icon,{className:"sgi sgi-link"}),"Group"]})};function uB(e){return e?Object.values(e.filter.args.columnFilters||{}).some(({value:t})=>t[1]||t[2]):!1}const hB=({setIsOpened:e})=>{const t=Cn.table;function n(){if(!t){e(!1);return}const o=t.filter.args;delete o.columnFilters,t.filter.args=o,er.highlightAllColumns(o,t.id),e(!1)}return uB(t)?D.jsxs($e.Fragment,{children:[D.jsx(vl,{}),D.jsxs(un.Li,{onClick:n,children:[D.jsx(un.Icon,{className:"sgi sgi-notification-clear-all"}),"Reset column filters"]})]}):null},fB=({setIsOpened:e})=>{const t=Cn.table;function n(){t&&(t.grouping={isGrouped:!1},e(!1))}return t?.grouping.isGrouped?D.jsxs(un.Li,{onClick:n,children:[D.jsx(un.Icon,{className:"sgi sgi-link-off"}),"Ungroup"]}):null},pB=({setIsOpened:e})=>{const t=Cn.table;function n(){const o=t?.grid;if(!o)return;o.getData().collapseAllGroups(),e(!1)}return t?.grouping.isGrouped?D.jsxs(un.Li,{onClick:n,children:[D.jsx(un.Icon,{className:"sgi sgi-collapse-all-outline"}),"Collapse all groups"]}):null},mB=({setIsOpened:e})=>{function t(){const n=Cn.table,o=n?.grid;if(!o||!n){e(!1);return}window.navigator.clipboard.writeText(n.downloadManager.createCSV(n)).then(()=>{}).catch(()=>{}),o.getSelectionModel()&&o.setSelectedRows([]),e(!1)}return D.jsxs(un.Li,{onClick:t,children:[D.jsx(un.Icon,{className:"sgi sgi-content-copy"}),"Copy to clipboard"]})},gB=({setIsOpened:e})=>{const t=Cn.table;function n(){const o=t?.grid;if(!o)return;o.getData().expandAllGroups(),e(!1)}return t?.grouping.isGrouped?D.jsxs(un.Li,{onClick:n,children:[D.jsx(un.Icon,{className:"sgi sgi-expand-all-outline"}),"Expand all groups"]}):null},yB=({clientId:e,clientName:t,setIsOpened:n})=>{function o(){const r=Cn.table;r?.printer.print(r,e,t),n(!1)}return D.jsxs(un.Li,{onClick:o,children:[D.jsx(un.Icon,{className:"sgi sgi-printer"}),"Print"]})},vB=({clientId:e,clientName:t})=>{const[n,o]=$e.useState(!1);return sB(o),n?D.jsxs($e.Fragment,{children:[D.jsx(ju,{setIsOpened:o}),D.jsx(Bu,{id:wb,children:D.jsxs(un.Ul,{children:[D.jsx(yB,{clientId:e,clientName:t,setIsOpened:o}),D.jsx(mB,{setIsOpened:o}),D.jsx(cB,{clientId:e,clientName:t,setIsOpened:o}),D.jsx(hB,{setIsOpened:o}),D.jsx(fB,{setIsOpened:o}),D.jsx(dB,{setIsOpened:o}),D.jsx(gB,{setIsOpened:o}),D.jsx(pB,{setIsOpened:o})]})})]}):null},Cb="header_context_menu";function bB(e){$e.useEffect(()=>{function t(){e(!0),setTimeout(()=>{const n=document.getElementById(Cb);if(!n)return;const{x:o,y:r}=so;Vu(n,o,r)},0)}return so.subscribe(t),()=>{so.unsubscribe(t)}},[])}function Eh(e){const t=so.table;if(!t)return;t.columnPicker.visibleColumnIds=[...e];const n=t.grid;if(!n)return;n.setColumns(t.columnPicker.initialColumns.filter(({id:r})=>e.includes(r)));const o=t.filter.args;t.filter.register(n,t.id),er.highlightAllColumns(o,t.id)}const wB=({setChecked:e})=>{function t(){const n=so.table;if(!n)return;const o=n.columnPicker.initialColumns.map(({id:r})=>r);e(o),Eh(o)}return D.jsx(Ho,{onClick:t,size:"small",sx:{textTransform:"none"},variant:"contained",children:"Check all"})},CB=({checked:e,setChecked:t})=>{function n(){const o=e.filter(r=>r==="_checkbox_selector"||r==="isEdited");t(o),Eh(o)}return D.jsx(Ho,{onClick:n,size:"small",sx:{textTransform:"none"},variant:"contained",children:"Uncheck all"})},SB=ae(Ho)({display:"flex",alignItems:"center",justifyContent:"flex-start",columnGap:"0.5em",textTransform:"none",color:"#1E456F",padding:"0"}),_B=ae(tc)({padding:0}),Am={Checkbox:_B,Button:SB},xB=({checked:e,columnId:t,columnName:n,setChecked:o})=>{function r(){const i=e.indexOf(t),a=[...e];~i?a.splice(i,1):a.push(t),o(a),Eh(a)}return D.jsxs(Am.Button,{onClick:r,children:[D.jsx(Am.Checkbox,{checked:e.includes(t),size:"small"}),D.jsx(Do,{children:n})]})},RB=ae(Do)({color:"#1e456f",marginBottom:"0.5em"}),kB={Wrapper:RB},TB=()=>D.jsx(kB.Wrapper,{children:"Columns"}),EB=ae(Do)({columnGap:"0.5em",display:"flex",justifyContent:"flex-end",marginTop:"0.5em"}),PB=ae(Do)({maxHeight:"20em",overflowY:"auto"}),Fm={ButtonsGroup:EB,ItemsGroup:PB},DB=()=>{const[e,t]=$e.useState([]),[n,o]=$e.useState(!1);if(bB(o),$e.useEffect(()=>{if(!n)return;const i=so.table;i&&t([...i.columnPicker.visibleColumnIds])},[n]),!n)return null;const r=so.table;return r?D.jsxs($e.Fragment,{children:[D.jsx(ju,{setIsOpened:o}),D.jsxs(Bu,{id:Cb,children:[D.jsx(TB,{}),D.jsx(Fm.ItemsGroup,{children:r.columnPicker.initialColumns.filter(({id:i})=>i!=="_checkbox_selector"&&i!=="isEdited").map(({id:i,name:a})=>D.jsx($e.Fragment,{children:D.jsx(xB,{checked:e,columnId:i,columnName:a,setChecked:t})},i))}),D.jsxs(Fm.ButtonsGroup,{children:[D.jsx(wB,{setChecked:t}),D.jsx(CB,{checked:e,setChecked:t})]})]})]}):null};exports.Autocomplete=YA;exports.ColumnFilters=rB;exports.ColumnSorter=Mv;exports.ContextMenu=vB;exports.DecoratorColumnFilter=CA;exports.DecoratorFilter=yv;exports.DefaultHotKeys=iD;exports.DefaultPrinter=Rv;exports.DeletedRowsFilter=hN;exports.EColumnFiltersGroup=sn;exports.ESortType=yo;exports.Filter=gv;exports.HeaderContextMenu=DB;exports.HotKeysDecorator=Wu;exports.PreventCopying=lD;exports.RedoUndoOnly=cD;exports.Skeleton=X1;exports.SlickTable=EA;exports.SlickgridTable=pA;exports.TotalCalculator=rF;exports.columnCheckboxSelector=mA;exports.columnIsEdited=yA;exports.commitCurrentEdit=fh;exports.copySelectedRows=Pv;exports.formatterGroupTotals=QA;exports.getDisplayedRows=mc;exports.getNextId=kl;exports.handleHeaderButtons=vv;exports.headerButtons=er;exports.openColumnFilter=pN;exports.openContextMenu=Dv;exports.useListenIfTablesWereEdited=VA;
|
|
363
|
+
`));f&&F.current&&F.current.getSectionContent(C.startIndex).focus()},[]),{interactions:Y,returnedValue:{autoFocus:f,readOnly:n,focused:u??X,sectionListRef:z,onBlur:B,onClick:le,onFocus:V,onInput:A,onPaste:M,enableAccessibleFieldDOMStructure:!0,elements:ie,tabIndex:g===0?-1:0,contentEditable:ce,value:W,onChange:he,areAllSectionsEmpty:O}}},gs=e=>e.replace(/[\u2066\u2067\u2068\u2069]/g,""),i$=(e,t,n)=>{let o=0,r=n?1:0;const i=[];for(let a=0;a<e.length;a+=1){const l=e[a],d=vh(l,n?"input-rtl":"input-ltr",t),u=`${l.startSeparator}${d}${l.endSeparator}`,f=gs(u).length,p=u.length,y=gs(d),b=r+(y===""?0:d.indexOf(y[0]))+l.startSeparator.length,w=b+y.length;i.push(Z({},l,{start:o,end:o+f,startInInput:b,endInInput:w})),o+=f,r+=p}return i},a$=e=>{const t=lo(),n=k.useRef(),o=k.useRef(),{forwardedProps:{onFocus:r,onClick:i,onPaste:a,onBlur:l,inputRef:d,placeholder:u},internalProps:{readOnly:f=!1,disabled:p=!1},parsedSelectedSections:y,activeSectionIndex:b,state:w,fieldValueManager:g,valueManager:v,applyCharacterEditing:E,resetCharacterQuery:P,updateSectionValue:x,updateValueFromValueStr:S,clearActiveSection:C,clearValue:O,setTempAndroidValueStr:N,setSelectedSections:F,getSectionsFromValue:z,areAllSectionsEmpty:R,localizedDigits:$}=e,K=k.useRef(null),X=at(d,K),q=k.useMemo(()=>i$(w.sections,$,t),[w.sections,$,t]),Y=k.useMemo(()=>({syncSelectionToDOM:()=>{if(!K.current)return;if(y==null){K.current.scrollLeft&&(K.current.scrollLeft=0);return}if(K.current!==Nn(document))return;const ee=K.current.scrollTop;if(y==="all")K.current.select();else{const te=q[y],ce=te.type==="empty"?te.startInInput-te.startSeparator.length:te.startInInput,ie=te.type==="empty"?te.endInInput+te.endSeparator.length:te.endInInput;(ce!==K.current.selectionStart||ie!==K.current.selectionEnd)&&K.current===Nn(document)&&K.current.setSelectionRange(ce,ie),clearTimeout(o.current),o.current=setTimeout(()=>{K.current&&K.current===Nn(document)&&K.current.selectionStart===K.current.selectionEnd&&(K.current.selectionStart!==ce||K.current.selectionEnd!==ie)&&Y.syncSelectionToDOM()})}K.current.scrollTop=ee},getActiveSectionIndexFromDOM:()=>{const ee=K.current.selectionStart??0,te=K.current.selectionEnd??0;if(ee===0&&te===0)return null;const ce=ee<=q[0].startInInput?1:q.findIndex(ie=>ie.startInInput-ie.startSeparator.length>ee);return ce===-1?q.length-1:ce-1},focusField:(ee=0)=>{K.current?.focus(),F(ee)},setSelectedSections:ee=>F(ee),isFieldFocused:()=>K.current===Nn(document)}),[K,y,q,F]),H=()=>{const ee=K.current.selectionStart??0;let te;ee<=q[0].startInInput||ee>=q[q.length-1].endInInput?te=1:te=q.findIndex(ie=>ie.startInInput-ie.startSeparator.length>ee);const ce=te===-1?q.length-1:te-1;F(ce)},le=ke((...ee)=>{r?.(...ee);const te=K.current;clearTimeout(n.current),n.current=setTimeout(()=>{!te||te!==K.current||b==null&&(te.value.length&&Number(te.selectionEnd)-Number(te.selectionStart)===te.value.length?F("all"):H())})}),A=ke((ee,...te)=>{ee.isDefaultPrevented()||(i?.(ee,...te),H())}),M=ke(ee=>{if(a?.(ee),ee.preventDefault(),f||p)return;const te=ee.clipboardData.getData("text");if(typeof y=="number"){const ce=w.sections[y],ie=/^[a-zA-Z]+$/.test(te),he=/^[0-9]+$/.test(te),W=/^(([a-zA-Z]+)|)([0-9]+)(([a-zA-Z]+)|)$/.test(te);if(ce.contentType==="letter"&&ie||ce.contentType==="digit"&&he||ce.contentType==="digit-with-letter"&&W){P(),x({activeSection:ce,newSectionValue:te,shouldGoToNextSection:!0});return}if(ie||he)return}P(),S(te)}),V=ke((...ee)=>{l?.(...ee),F(null)}),B=ke(ee=>{if(f)return;const te=ee.target.value;if(te===""){P(),O();return}const ce=ee.nativeEvent.data,ie=ce&&ce.length>1,he=ie?ce:te,W=gs(he);if(b==null||ie){S(ie?ce:W);return}let re;if(y==="all"&&W.length===1)re=W;else{const Q=gs(g.getV6InputValueFromSections(q,$,t));let fe=-1,me=-1;for(let Ve=0;Ve<Q.length;Ve+=1)fe===-1&&Q[Ve]!==W[Ve]&&(fe=Ve),me===-1&&Q[Q.length-Ve-1]!==W[W.length-Ve-1]&&(me=Ve);const Ce=q[b];if(fe<Ce.start||Q.length-me-1>Ce.end)return;const xe=W.length-Q.length+Ce.end-gs(Ce.endSeparator||"").length;re=W.slice(Ce.start+gs(Ce.startSeparator||"").length,xe)}if(re.length===0){FF()&&N(he),P(),C();return}E({keyPressed:re,sectionIndex:b})}),ne=k.useMemo(()=>u!==void 0?u:g.getV6InputValueFromSections(z(v.emptyValue),$,t),[u,g,z,v.emptyValue,$,t]),oe=k.useMemo(()=>w.tempValueStrAndroid??g.getV6InputValueFromSections(w.sections,$,t),[w.sections,g,w.tempValueStrAndroid,$,t]);k.useEffect(()=>(K.current&&K.current===Nn(document)&&F("all"),()=>{clearTimeout(n.current),clearTimeout(o.current)}),[]);const se=k.useMemo(()=>b==null||w.sections[b].contentType==="letter"?"text":"numeric",[b,w.sections]),J=!(K.current&&K.current===Nn(document))&&R;return{interactions:Y,returnedValue:{readOnly:f,onBlur:V,onClick:A,onFocus:le,onPaste:M,inputRef:X,enableAccessibleFieldDOMStructure:!1,placeholder:ne,inputMode:se,autoComplete:"off",value:J?"":oe,onChange:B}}},l$=e=>{const t=Nt(),{internalProps:n,internalProps:{unstableFieldRef:o,minutesStep:r,enableAccessibleFieldDOMStructure:i=!1,disabled:a=!1,readOnly:l=!1},forwardedProps:{onKeyDown:d,error:u,clearable:f,onClear:p},fieldValueManager:y,valueManager:b,validator:w}=e,g=lo(),v=n$(e),{state:E,activeSectionIndex:P,parsedSelectedSections:x,setSelectedSections:S,clearValue:C,clearActiveSection:O,updateSectionValue:N,setTempAndroidValueStr:F,sectionsValueBoundaries:z,localizedDigits:R,timezone:$}=v,K=r$({sections:E.sections,updateSectionValue:N,sectionsValueBoundaries:z,localizedDigits:R,setTempAndroidValueStr:F,timezone:$}),{resetCharacterQuery:X}=K,q=b.areValuesEqual(t,E.value,b.emptyValue),Y=i?s$:a$,H=k.useMemo(()=>LF(E.sections,g&&!i),[E.sections,g,i]),{returnedValue:le,interactions:A}=Y(Z({},e,v,K,{areAllSectionsEmpty:q,sectionOrder:H})),M=ke(j=>{if(d?.(j),!a)switch(!0){case((j.ctrlKey||j.metaKey)&&String.fromCharCode(j.keyCode)==="A"&&!j.shiftKey&&!j.altKey):{j.preventDefault(),S("all");break}case j.key==="ArrowRight":{if(j.preventDefault(),x==null)S(H.startIndex);else if(x==="all")S(H.endIndex);else{const J=H.neighbors[x].rightIndex;J!==null&&S(J)}break}case j.key==="ArrowLeft":{if(j.preventDefault(),x==null)S(H.endIndex);else if(x==="all")S(H.startIndex);else{const J=H.neighbors[x].leftIndex;J!==null&&S(J)}break}case j.key==="Delete":{if(j.preventDefault(),l)break;x==null||x==="all"?C():O(),X();break}case["ArrowUp","ArrowDown","Home","End","PageUp","PageDown"].includes(j.key):{if(j.preventDefault(),l||P==null)break;const J=E.sections[P],ee=y.getActiveDateManager(t,E,J),te=DF(t,$,J,j.key,z,R,ee.date,{minutesStep:r});N({activeSection:J,newSectionValue:te,shouldGoToNextSection:!1});break}}});nn(()=>{A.syncSelectionToDOM()});const{hasValidationError:V}=qv({props:n,validator:w,timezone:$,value:E.value,onError:n.onError}),B=k.useMemo(()=>u!==void 0?u:V,[V,u]);k.useEffect(()=>{!B&&P==null&&X()},[E.referenceValue,P,B]),k.useEffect(()=>{E.tempValueStrAndroid!=null&&P!=null&&(X(),O())},[E.sections]),k.useImperativeHandle(o,()=>({getSections:()=>E.sections,getActiveSectionIndex:A.getActiveSectionIndexFromDOM,setSelectedSections:A.setSelectedSections,focusField:A.focusField,isFieldFocused:A.isFieldFocused}));const ne=ke((j,...J)=>{j.preventDefault(),p?.(j,...J),C(),A.isFieldFocused()?S(H.startIndex):A.focusField(0)}),oe={onKeyDown:M,onClear:ne,error:B,clearable:!!(f&&!q&&!l&&!a)},se={disabled:a,readOnly:l};return Z({},e.forwardedProps,oe,se,le)},c$=["clearable","onClear","InputProps","sx","slots","slotProps"],d$=["ownerState"],u$=e=>{const t=rr(),{clearable:n,onClear:o,InputProps:r,sx:i,slots:a,slotProps:l}=e,d=We(e,c$),u=a?.clearButton??$s,f=dt({elementType:u,externalSlotProps:l?.clearButton,ownerState:{},className:"clearButton",additionalProps:{title:t.fieldClearLabel}}),p=We(f,d$),y=a?.clearIcon??KL,b=dt({elementType:y,externalSlotProps:l?.clearIcon,ownerState:{}});return Z({},d,{InputProps:Z({},r,{endAdornment:D.jsxs(k.Fragment,{children:[n&&D.jsx(Nu,{position:"end",sx:{marginRight:r?.endAdornment?-1:-1.5},children:D.jsx(u,Z({},p,{onClick:o,children:D.jsx(y,Z({fontSize:"small"},b))}))}),r?.endAdornment]})}),sx:[{"& .clearButton":{opacity:1},"@media (pointer: fine)":{"& .clearButton":{opacity:0},"&:hover, &:focus-within":{".clearButton":{opacity:1}}}},...Array.isArray(i)?i:[i]]})},h$=["value","defaultValue","referenceDate","format","formatDensity","onChange","timezone","onError","shouldRespectLeadingZeros","selectedSections","onSelectedSectionsChange","unstableFieldRef","enableAccessibleFieldDOMStructure","disabled","readOnly","dateSeparator"],f$=(e,t)=>k.useMemo(()=>{const n=Z({},e),o={},r=i=>{n.hasOwnProperty(i)&&(o[i]=n[i],delete n[i])};return h$.forEach(r),Yv.forEach(r),{forwardedProps:n,internalProps:o}},[e,t]),p$=e=>{const t=Nt(),n=ya();return Z({},e,{disablePast:e.disablePast??!1,disableFuture:e.disableFuture??!1,format:e.format??t.formats.keyboardDate,minDate:Xn(t,e.minDate,n.minDate),maxDate:Xn(t,e.maxDate,n.maxDate)})},m$=e=>{const t=p$(e),{forwardedProps:n,internalProps:o}=f$(t,"date");return l$({forwardedProps:n,internalProps:o,valueManager:Po,fieldValueManager:BF,validator:va,valueType:"date"})};function g$(e){return Oe("MuiPickersTextField",e)}De("MuiPickersTextField",["root","focused","disabled","error","required"]);function y$(e){return Oe("MuiPickersInputBase",e)}const _s=De("MuiPickersInputBase",["root","focused","disabled","error","notchedOutline","sectionContent","sectionBefore","sectionAfter","adornedStart","adornedEnd","input"]);function v$(e){return Oe("MuiPickersSectionList",e)}const hi=De("MuiPickersSectionList",["root","section","sectionContent"]),b$=["slots","slotProps","elements","sectionListRef"],tb=ae("div",{name:"MuiPickersSectionList",slot:"Root",overridesResolver:(e,t)=>t.root})({direction:"ltr /*! @noflip */",outline:"none"}),nb=ae("span",{name:"MuiPickersSectionList",slot:"Section",overridesResolver:(e,t)=>t.section})({}),ob=ae("span",{name:"MuiPickersSectionList",slot:"SectionSeparator",overridesResolver:(e,t)=>t.sectionSeparator})({whiteSpace:"pre"}),rb=ae("span",{name:"MuiPickersSectionList",slot:"SectionContent",overridesResolver:(e,t)=>t.sectionContent})({outline:"none"}),w$=e=>{const{classes:t}=e;return Me({root:["root"],section:["section"],sectionContent:["sectionContent"]},v$,t)};function sb(e){const{slots:t,slotProps:n,element:o,classes:r}=e,i=t?.section??nb,a=dt({elementType:i,externalSlotProps:n?.section,externalForwardedProps:o.container,className:r.section,ownerState:{}}),l=t?.sectionContent??rb,d=dt({elementType:l,externalSlotProps:n?.sectionContent,externalForwardedProps:o.content,additionalProps:{suppressContentEditableWarning:!0},className:r.sectionContent,ownerState:{}}),u=t?.sectionSeparator??ob,f=dt({elementType:u,externalSlotProps:n?.sectionSeparator,externalForwardedProps:o.before,ownerState:{position:"before"}}),p=dt({elementType:u,externalSlotProps:n?.sectionSeparator,externalForwardedProps:o.after,ownerState:{position:"after"}});return D.jsxs(i,Z({},a,{children:[D.jsx(u,Z({},f)),D.jsx(l,Z({},d)),D.jsx(u,Z({},p))]}))}process.env.NODE_ENV!=="production"&&(sb.propTypes={classes:s.object.isRequired,element:s.shape({after:s.object.isRequired,before:s.object.isRequired,container:s.object.isRequired,content:s.object.isRequired}).isRequired,slotProps:s.object,slots:s.object});const ib=k.forwardRef(function(t,n){const o=Mt({props:t,name:"MuiPickersSectionList"}),{slots:r,slotProps:i,elements:a,sectionListRef:l}=o,d=We(o,b$),u=w$(o),f=k.useRef(null),p=at(n,f),y=g=>{if(!f.current)throw new Error(`MUI X: Cannot call sectionListRef.${g} before the mount of the component.`);return f.current};k.useImperativeHandle(l,()=>({getRoot(){return y("getRoot")},getSectionContainer(g){return y("getSectionContainer").querySelector(`.${hi.section}[data-sectionindex="${g}"]`)},getSectionContent(g){return y("getSectionContent").querySelector(`.${hi.section}[data-sectionindex="${g}"] .${hi.sectionContent}`)},getSectionIndexFromDOMElement(g){const v=y("getSectionIndexFromDOMElement");if(g==null||!v.contains(g))return null;let E=null;return g.classList.contains(hi.section)?E=g:g.classList.contains(hi.sectionContent)&&(E=g.parentElement),E==null?null:Number(E.dataset.sectionindex)}}));const b=r?.root??tb,w=dt({elementType:b,externalSlotProps:i?.root,externalForwardedProps:d,additionalProps:{ref:p,suppressContentEditableWarning:!0},className:u.root,ownerState:{}});return D.jsx(b,Z({},w,{children:w.contentEditable?a.map(({content:g,before:v,after:E})=>`${v.children}${g.children}${E.children}`).join(""):D.jsx(k.Fragment,{children:a.map((g,v)=>D.jsx(sb,{slots:r,slotProps:i,element:g,classes:u},v))})}))});process.env.NODE_ENV!=="production"&&(ib.propTypes={classes:s.object,contentEditable:s.bool.isRequired,elements:s.arrayOf(s.shape({after:s.object.isRequired,before:s.object.isRequired,container:s.object.isRequired,content:s.object.isRequired})).isRequired,sectionListRef:s.oneOfType([s.func,s.shape({current:s.shape({getRoot:s.func.isRequired,getSectionContainer:s.func.isRequired,getSectionContent:s.func.isRequired,getSectionIndexFromDOMElement:s.func.isRequired})})]),slotProps:s.object,slots:s.object});const C$=["elements","areAllSectionsEmpty","defaultValue","label","value","onChange","id","autoFocus","endAdornment","startAdornment","renderSuffix","slots","slotProps","contentEditable","tabIndex","onInput","onPaste","onKeyDown","fullWidth","name","readOnly","inputProps","inputRef","sectionListRef"],S$=e=>Math.round(e*1e5)/1e5,Sc=ae("div",{name:"MuiPickersInputBase",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>Z({},e.typography.body1,{color:(e.vars||e).palette.text.primary,cursor:"text",padding:0,display:"flex",justifyContent:"flex-start",alignItems:"center",position:"relative",boxSizing:"border-box",letterSpacing:`${S$(.15/16)}em`,variants:[{props:{fullWidth:!0},style:{width:"100%"}}]})),_h=ae(tb,{name:"MuiPickersInputBase",slot:"SectionsContainer",overridesResolver:(e,t)=>t.sectionsContainer})(({theme:e})=>({padding:"4px 0 5px",fontFamily:e.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:t,focused:n,filled:o,label:r})=>!t&&!n&&!o&&r==null,style:e.vars?{opacity:e.vars.opacity.inputPlaceholder}:{opacity:e.palette.mode==="light"?.42:.5}}]})),_$=ae(nb,{name:"MuiPickersInputBase",slot:"Section",overridesResolver:(e,t)=>t.section})(({theme:e})=>({fontFamily:e.typography.fontFamily,fontSize:"inherit",letterSpacing:"inherit",lineHeight:"1.4375em",display:"flex"})),x$=ae(rb,{name:"MuiPickersInputBase",slot:"SectionContent",overridesResolver:(e,t)=>t.content})(({theme:e})=>({fontFamily:e.typography.fontFamily,lineHeight:"1.4375em",letterSpacing:"inherit",width:"fit-content",outline:"none"})),R$=ae(ob,{name:"MuiPickersInputBase",slot:"Separator",overridesResolver:(e,t)=>t.separator})(()=>({whiteSpace:"pre",letterSpacing:"inherit"})),k$=ae("input",{name:"MuiPickersInputBase",slot:"Input",overridesResolver:(e,t)=>t.hiddenInput})(Z({},jx)),T$=e=>{const{focused:t,disabled:n,error:o,classes:r,fullWidth:i,readOnly:a,color:l,size:d,endAdornment:u,startAdornment:f}=e,p={root:["root",t&&!n&&"focused",n&&"disabled",a&&"readOnly",o&&"error",i&&"fullWidth",`color${be(l)}`,d==="small"&&"inputSizeSmall",!!f&&"adornedStart",!!u&&"adornedEnd"],notchedOutline:["notchedOutline"],input:["input"],sectionsContainer:["sectionsContainer"],sectionContent:["sectionContent"],sectionBefore:["sectionBefore"],sectionAfter:["sectionAfter"]};return Me(p,y$,r)},_c=k.forwardRef(function(t,n){const o=Mt({props:t,name:"MuiPickersInputBase"}),{elements:r,areAllSectionsEmpty:i,value:a,onChange:l,id:d,endAdornment:u,startAdornment:f,renderSuffix:p,slots:y,slotProps:b,contentEditable:w,tabIndex:g,onInput:v,onPaste:E,onKeyDown:P,name:x,readOnly:S,inputProps:C,inputRef:O,sectionListRef:N}=o,F=We(o,C$),z=k.useRef(null),R=at(n,z),$=at(C?.ref,O),K=lo(),X=On();if(!X)throw new Error("MUI X: PickersInputBase should always be used inside a PickersTextField component");const q=V=>{if(X.disabled){V.stopPropagation();return}X.onFocus?.(V)};k.useEffect(()=>{X&&X.setAdornedStart(!!f)},[X,f]),k.useEffect(()=>{X&&(i?X.onEmpty():X.onFilled())},[X,i]);const Y=Z({},o,X,{isRtl:K}),H=T$(Y),le=y?.root||Sc,A=dt({elementType:le,externalSlotProps:b?.root,externalForwardedProps:F,additionalProps:{"aria-invalid":X.error,ref:R},className:H.root,ownerState:Y}),M=y?.input||_h;return D.jsxs(le,Z({},A,{children:[f,D.jsx(ib,{sectionListRef:N,elements:r,contentEditable:w,tabIndex:g,className:H.sectionsContainer,onFocus:q,onBlur:X.onBlur,onInput:v,onPaste:E,onKeyDown:P,slots:{root:M,section:_$,sectionContent:x$,sectionSeparator:R$},slotProps:{root:{ownerState:Y},sectionContent:{className:_s.sectionContent},sectionSeparator:({position:V})=>({className:V==="before"?_s.sectionBefore:_s.sectionAfter})}}),u,p?p(Z({},X)):null,D.jsx(k$,Z({name:x,className:H.input,value:a,onChange:l,id:d,"aria-hidden":"true",tabIndex:-1,readOnly:S,required:X.required,disabled:X.disabled},C,{ref:$}))]}))});process.env.NODE_ENV!=="production"&&(_c.propTypes={areAllSectionsEmpty:s.bool.isRequired,className:s.string,component:s.elementType,contentEditable:s.bool.isRequired,elements:s.arrayOf(s.shape({after:s.object.isRequired,before:s.object.isRequired,container:s.object.isRequired,content:s.object.isRequired})).isRequired,endAdornment:s.node,fullWidth:s.bool,id:s.string,inputProps:s.object,inputRef:Bt,label:s.node,margin:s.oneOf(["dense","none","normal"]),name:s.string,onChange:s.func.isRequired,onClick:s.func.isRequired,onInput:s.func.isRequired,onKeyDown:s.func.isRequired,onPaste:s.func.isRequired,ownerState:s.any,readOnly:s.bool,renderSuffix:s.func,sectionListRef:s.oneOfType([s.func,s.shape({current:s.shape({getRoot:s.func.isRequired,getSectionContainer:s.func.isRequired,getSectionContent:s.func.isRequired,getSectionIndexFromDOMElement:s.func.isRequired})})]),slotProps:s.object,slots:s.object,startAdornment:s.node,style:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),value:s.string.isRequired});function E$(e){return Oe("MuiPickersOutlinedInput",e)}const no=Z({},_s,De("MuiPickersOutlinedInput",["root","notchedOutline","input"])),P$=["children","className","label","notched","shrink"],D$=ae("fieldset",{name:"MuiPickersOutlinedInput",slot:"NotchedOutline",overridesResolver:(e,t)=>t.notchedOutline})(({theme:e})=>{const t=e.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:e.vars?`rgba(${e.vars.palette.common.onBackgroundChannel} / 0.23)`:t}}),Pm=ae("span")(({theme:e})=>({fontFamily:e.typography.fontFamily,fontSize:"inherit"})),O$=ae("legend")(({theme:e})=>({float:"unset",width:"auto",overflow:"hidden",variants:[{props:{withLabel:!1},style:{padding:0,lineHeight:"11px",transition:e.transitions.create("width",{duration:150,easing:e.transitions.easing.easeOut})}},{props:{withLabel:!0},style:{display:"block",padding:0,height:11,fontSize:"0.75em",visibility:"hidden",maxWidth:.01,transition:e.transitions.create("max-width",{duration:50,easing:e.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:e.transitions.create("max-width",{duration:100,easing:e.transitions.easing.easeOut,delay:50})}}]}));function M$(e){const{className:t,label:n}=e,o=We(e,P$),r=n!=null&&n!=="",i=Z({},e,{withLabel:r});return D.jsx(D$,Z({"aria-hidden":!0,className:t},o,{ownerState:i,children:D.jsx(O$,{ownerState:i,children:r?D.jsx(Pm,{children:n}):D.jsx(Pm,{className:"notranslate",children:""})})}))}const I$=["label","autoFocus","ownerState","notched"],N$=ae(Sc,{name:"MuiPickersOutlinedInput",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>{const t=e.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return{padding:"0 14px",borderRadius:(e.vars||e).shape.borderRadius,[`&:hover .${no.notchedOutline}`]:{borderColor:(e.vars||e).palette.text.primary},"@media (hover: none)":{[`&:hover .${no.notchedOutline}`]:{borderColor:e.vars?`rgba(${e.vars.palette.common.onBackgroundChannel} / 0.23)`:t}},[`&.${no.focused} .${no.notchedOutline}`]:{borderStyle:"solid",borderWidth:2},[`&.${no.disabled}`]:{[`& .${no.notchedOutline}`]:{borderColor:(e.vars||e).palette.action.disabled},"*":{color:(e.vars||e).palette.action.disabled}},[`&.${no.error} .${no.notchedOutline}`]:{borderColor:(e.vars||e).palette.error.main},variants:Object.keys((e.vars??e).palette).filter(n=>(e.vars??e).palette[n]?.main??!1).map(n=>({props:{color:n},style:{[`&.${no.focused}:not(.${no.error}) .${no.notchedOutline}`]:{borderColor:(e.vars||e).palette[n].main}}}))}}),A$=ae(_h,{name:"MuiPickersOutlinedInput",slot:"SectionsContainer",overridesResolver:(e,t)=>t.sectionsContainer})({padding:"16.5px 0",variants:[{props:{size:"small"},style:{padding:"8.5px 0"}}]}),F$=e=>{const{classes:t}=e,o=Me({root:["root"],notchedOutline:["notchedOutline"],input:["input"]},E$,t);return Z({},t,o)},xh=k.forwardRef(function(t,n){const o=Mt({props:t,name:"MuiPickersOutlinedInput"}),{label:r,ownerState:i,notched:a}=o,l=We(o,I$),d=On(),u=Z({},o,i,d,{color:d?.color||"primary"}),f=F$(u);return D.jsx(_c,Z({slots:{root:N$,input:A$},renderSuffix:p=>D.jsx(M$,{shrink:!!(a||p.adornedStart||p.focused||p.filled),notched:!!(a||p.adornedStart||p.focused||p.filled),className:f.notchedOutline,label:r!=null&&r!==""&&d?.required?D.jsxs(k.Fragment,{children:[r," ","*"]}):r,ownerState:u})},l,{label:r,classes:f,ref:n}))});process.env.NODE_ENV!=="production"&&(xh.propTypes={areAllSectionsEmpty:s.bool.isRequired,className:s.string,component:s.elementType,contentEditable:s.bool.isRequired,elements:s.arrayOf(s.shape({after:s.object.isRequired,before:s.object.isRequired,container:s.object.isRequired,content:s.object.isRequired})).isRequired,endAdornment:s.node,fullWidth:s.bool,id:s.string,inputProps:s.object,inputRef:Bt,label:s.node,margin:s.oneOf(["dense","none","normal"]),name:s.string,notched:s.bool,onChange:s.func.isRequired,onClick:s.func.isRequired,onInput:s.func.isRequired,onKeyDown:s.func.isRequired,onPaste:s.func.isRequired,ownerState:s.any,readOnly:s.bool,renderSuffix:s.func,sectionListRef:s.oneOfType([s.func,s.shape({current:s.shape({getRoot:s.func.isRequired,getSectionContainer:s.func.isRequired,getSectionContent:s.func.isRequired,getSectionIndexFromDOMElement:s.func.isRequired})})]),slotProps:s.object,slots:s.object,startAdornment:s.node,style:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),value:s.string.isRequired});xh.muiName="Input";function L$(e){return Oe("MuiPickersFilledInput",e)}const Tr=Z({},_s,De("MuiPickersFilledInput",["root","underline","input"])),$$=["label","autoFocus","disableUnderline","ownerState"],V$=ae(Sc,{name:"MuiPickersFilledInput",slot:"Root",overridesResolver:(e,t)=>t.root,shouldForwardProp:e=>Ja(e)&&e!=="disableUnderline"})(({theme:e})=>{const t=e.palette.mode==="light",n=t?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)",o=t?"rgba(0, 0, 0, 0.06)":"rgba(255, 255, 255, 0.09)",r=t?"rgba(0, 0, 0, 0.09)":"rgba(255, 255, 255, 0.13)",i=t?"rgba(0, 0, 0, 0.12)":"rgba(255, 255, 255, 0.12)";return{backgroundColor:e.vars?e.vars.palette.FilledInput.bg:o,borderTopLeftRadius:(e.vars||e).shape.borderRadius,borderTopRightRadius:(e.vars||e).shape.borderRadius,transition:e.transitions.create("background-color",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),"&:hover":{backgroundColor:e.vars?e.vars.palette.FilledInput.hoverBg:r,"@media (hover: none)":{backgroundColor:e.vars?e.vars.palette.FilledInput.bg:o}},[`&.${Tr.focused}`]:{backgroundColor:e.vars?e.vars.palette.FilledInput.bg:o},[`&.${Tr.disabled}`]:{backgroundColor:e.vars?e.vars.palette.FilledInput.disabledBg:i},variants:[...Object.keys((e.vars??e).palette).filter(a=>(e.vars??e).palette[a].main).map(a=>({props:{color:a,disableUnderline:!1},style:{"&::after":{borderBottom:`2px solid ${(e.vars||e).palette[a]?.main}`}}})),{props:{disableUnderline:!1},style:{"&::after":{left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:e.transitions.create("transform",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${Tr.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${Tr.error}`]:{"&:before, &:after":{borderBottomColor:(e.vars||e).palette.error.main}},"&::before":{borderBottom:`1px solid ${e.vars?`rgba(${e.vars.palette.common.onBackgroundChannel} / ${e.vars.opacity.inputUnderline})`:n}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:e.transitions.create("border-bottom-color",{duration:e.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${Tr.disabled}, .${Tr.error}):before`]:{borderBottom:`1px solid ${(e.vars||e).palette.text.primary}`},[`&.${Tr.disabled}:before`]:{borderBottomStyle:"dotted"}}},{props:({startAdornment:a})=>!!a,style:{paddingLeft:12}},{props:({endAdornment:a})=>!!a,style:{paddingRight:12}}]}}),j$=ae(_h,{name:"MuiPickersFilledInput",slot:"sectionsContainer",overridesResolver:(e,t)=>t.sectionsContainer})({paddingTop:25,paddingRight:12,paddingBottom:8,paddingLeft:12,variants:[{props:{size:"small"},style:{paddingTop:21,paddingBottom:4}},{props:({startAdornment:e})=>!!e,style:{paddingLeft:0}},{props:({endAdornment:e})=>!!e,style:{paddingRight:0}},{props:{hiddenLabel:!0},style:{paddingTop:16,paddingBottom:17}},{props:{hiddenLabel:!0,size:"small"},style:{paddingTop:8,paddingBottom:9}}]}),B$=e=>{const{classes:t,disableUnderline:n}=e,r=Me({root:["root",!n&&"underline"],input:["input"]},L$,t);return Z({},t,r)},Rh=k.forwardRef(function(t,n){const o=Mt({props:t,name:"MuiPickersFilledInput"}),{label:r,disableUnderline:i=!1,ownerState:a}=o,l=We(o,$$),d=On(),u=Z({},o,a,d,{color:d?.color||"primary"}),f=B$(u);return D.jsx(_c,Z({slots:{root:V$,input:j$},slotProps:{root:{disableUnderline:i}}},l,{label:r,classes:f,ref:n}))});process.env.NODE_ENV!=="production"&&(Rh.propTypes={areAllSectionsEmpty:s.bool.isRequired,className:s.string,component:s.elementType,contentEditable:s.bool.isRequired,disableUnderline:s.bool,elements:s.arrayOf(s.shape({after:s.object.isRequired,before:s.object.isRequired,container:s.object.isRequired,content:s.object.isRequired})).isRequired,endAdornment:s.node,fullWidth:s.bool,hiddenLabel:s.bool,id:s.string,inputProps:s.object,inputRef:Bt,label:s.node,margin:s.oneOf(["dense","none","normal"]),name:s.string,onChange:s.func.isRequired,onClick:s.func.isRequired,onInput:s.func.isRequired,onKeyDown:s.func.isRequired,onPaste:s.func.isRequired,ownerState:s.any,readOnly:s.bool,renderSuffix:s.func,sectionListRef:s.oneOfType([s.func,s.shape({current:s.shape({getRoot:s.func.isRequired,getSectionContainer:s.func.isRequired,getSectionContent:s.func.isRequired,getSectionIndexFromDOMElement:s.func.isRequired})})]),slotProps:s.object,slots:s.object,startAdornment:s.node,style:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),value:s.string.isRequired});Rh.muiName="Input";function W$(e){return Oe("MuiPickersFilledInput",e)}const fi=Z({},_s,De("MuiPickersInput",["root","input"])),H$=["label","autoFocus","disableUnderline","ownerState"],z$=ae(Sc,{name:"MuiPickersInput",slot:"Root",overridesResolver:(e,t)=>t.root})(({theme:e})=>{let n=e.palette.mode==="light"?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)";return e.vars&&(n=`rgba(${e.vars.palette.common.onBackgroundChannel} / ${e.vars.opacity.inputUnderline})`),{"label + &":{marginTop:16},variants:[...Object.keys((e.vars??e).palette).filter(o=>(e.vars??e).palette[o].main).map(o=>({props:{color:o},style:{"&::after":{borderBottom:`2px solid ${(e.vars||e).palette[o].main}`}}})),{props:{disableUnderline:!1},style:{"&::after":{background:"red",left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:e.transitions.create("transform",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${fi.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${fi.error}`]:{"&:before, &:after":{borderBottomColor:(e.vars||e).palette.error.main}},"&::before":{borderBottom:`1px solid ${n}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:e.transitions.create("border-bottom-color",{duration:e.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${fi.disabled}, .${fi.error}):before`]:{borderBottom:`2px solid ${(e.vars||e).palette.text.primary}`,"@media (hover: none)":{borderBottom:`1px solid ${n}`}},[`&.${fi.disabled}:before`]:{borderBottomStyle:"dotted"}}}]}}),Y$=e=>{const{classes:t,disableUnderline:n}=e,r=Me({root:["root",!n&&"underline"],input:["input"]},W$,t);return Z({},t,r)},kh=k.forwardRef(function(t,n){const o=Mt({props:t,name:"MuiPickersInput"}),{label:r,disableUnderline:i=!1,ownerState:a}=o,l=We(o,H$),d=On(),u=Z({},o,a,d,{disableUnderline:i,color:d?.color||"primary"}),f=Y$(u);return D.jsx(_c,Z({slots:{root:z$}},l,{label:r,classes:f,ref:n}))});process.env.NODE_ENV!=="production"&&(kh.propTypes={areAllSectionsEmpty:s.bool.isRequired,className:s.string,component:s.elementType,contentEditable:s.bool.isRequired,disableUnderline:s.bool,elements:s.arrayOf(s.shape({after:s.object.isRequired,before:s.object.isRequired,container:s.object.isRequired,content:s.object.isRequired})).isRequired,endAdornment:s.node,fullWidth:s.bool,id:s.string,inputProps:s.object,inputRef:Bt,label:s.node,margin:s.oneOf(["dense","none","normal"]),name:s.string,onChange:s.func.isRequired,onClick:s.func.isRequired,onInput:s.func.isRequired,onKeyDown:s.func.isRequired,onPaste:s.func.isRequired,ownerState:s.any,readOnly:s.bool,renderSuffix:s.func,sectionListRef:s.oneOfType([s.func,s.shape({current:s.shape({getRoot:s.func.isRequired,getSectionContainer:s.func.isRequired,getSectionContent:s.func.isRequired,getSectionIndexFromDOMElement:s.func.isRequired})})]),slotProps:s.object,slots:s.object,startAdornment:s.node,style:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),value:s.string.isRequired});kh.muiName="Input";const U$=["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"],q$={standard:kh,filled:Rh,outlined:xh},G$=ae(ca,{name:"MuiPickersTextField",slot:"Root",overridesResolver:(e,t)=>t.root})({}),K$=e=>{const{focused:t,disabled:n,classes:o,required:r}=e;return Me({root:["root",t&&!n&&"focused",n&&"disabled",r&&"required"]},g$,o)},ab=k.forwardRef(function(t,n){const o=Mt({props:t,name:"MuiPickersTextField"}),{onFocus:r,onBlur:i,className:a,color:l="primary",disabled:d=!1,error:u=!1,variant:f="outlined",required:p=!1,InputProps:y,inputProps:b,inputRef:w,sectionListRef:g,elements:v,areAllSectionsEmpty:E,onClick:P,onKeyDown:x,onKeyUp:S,onPaste:C,onInput:O,endAdornment:N,startAdornment:F,tabIndex:z,contentEditable:R,focused:$,value:K,onChange:X,fullWidth:q,id:Y,name:H,helperText:le,FormHelperTextProps:A,label:M,InputLabelProps:V}=o,B=We(o,U$),ne=k.useRef(null),oe=at(n,ne),se=yr(Y),j=le&&se?`${se}-helper-text`:void 0,J=M&&se?`${se}-label`:void 0,ee=Z({},o,{color:l,disabled:d,error:u,focused:$,required:p,variant:f}),te=K$(ee),ce=q$[f];return D.jsxs(G$,Z({className:Se(te.root,a),ref:oe,focused:$,onFocus:r,onBlur:i,disabled:d,variant:f,error:u,color:l,fullWidth:q,required:p,ownerState:ee},B,{children:[D.jsx(da,Z({htmlFor:se,id:J},V,{children:M})),D.jsx(ce,Z({elements:v,areAllSectionsEmpty:E,onClick:P,onKeyDown:x,onKeyUp:S,onInput:O,onPaste:C,endAdornment:N,startAdornment:F,tabIndex:z,contentEditable:R,value:K,onChange:X,id:se,fullWidth:q,inputProps:b,inputRef:w,sectionListRef:g,label:M,name:H,role:"group","aria-labelledby":J},y)),le&&D.jsx(Iu,Z({id:j},A,{children:le}))]}))});process.env.NODE_ENV!=="production"&&(ab.propTypes={areAllSectionsEmpty:s.bool.isRequired,className:s.string,color:s.oneOf(["error","info","primary","secondary","success","warning"]),component:s.elementType,contentEditable:s.bool.isRequired,disabled:s.bool.isRequired,elements:s.arrayOf(s.shape({after:s.object.isRequired,before:s.object.isRequired,container:s.object.isRequired,content:s.object.isRequired})).isRequired,endAdornment:s.node,error:s.bool.isRequired,focused:s.bool,FormHelperTextProps:s.object,fullWidth:s.bool,helperText:s.node,hiddenLabel:s.bool,id:s.string,InputLabelProps:s.object,inputProps:s.object,InputProps:s.object,inputRef:Bt,label:s.node,margin:s.oneOf(["dense","none","normal"]),name:s.string,onBlur:s.func.isRequired,onChange:s.func.isRequired,onClick:s.func.isRequired,onFocus:s.func.isRequired,onInput:s.func.isRequired,onKeyDown:s.func.isRequired,onPaste:s.func.isRequired,readOnly:s.bool,required:s.bool,sectionListRef:s.oneOfType([s.func,s.shape({current:s.shape({getRoot:s.func.isRequired,getSectionContainer:s.func.isRequired,getSectionContent:s.func.isRequired,getSectionIndexFromDOMElement:s.func.isRequired})})]),size:s.oneOf(["medium","small"]),startAdornment:s.node,style:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),value:s.string.isRequired,variant:s.oneOf(["filled","outlined","standard"])});const X$=["enableAccessibleFieldDOMStructure"],Z$=["InputProps","readOnly"],Q$=["onPaste","onKeyDown","inputMode","readOnly","InputProps","inputProps","inputRef"],J$=e=>{let{enableAccessibleFieldDOMStructure:t}=e,n=We(e,X$);if(t){const{InputProps:p,readOnly:y}=n,b=We(n,Z$);return Z({},b,{InputProps:Z({},p??{},{readOnly:y})})}const{onPaste:o,onKeyDown:r,inputMode:i,readOnly:a,InputProps:l,inputProps:d,inputRef:u}=n,f=We(n,Q$);return Z({},f,{InputProps:Z({},l??{},{readOnly:a}),inputProps:Z({},d??{},{inputMode:i,onPaste:o,onKeyDown:r,ref:u})})},eV=["slots","slotProps","InputProps","inputProps"],Th=k.forwardRef(function(t,n){const o=Mt({props:t,name:"MuiDateField"}),{slots:r,slotProps:i,InputProps:a,inputProps:l}=o,d=We(o,eV),u=o,f=r?.textField??(t.enableAccessibleFieldDOMStructure?ab:Ms),p=dt({elementType:f,externalSlotProps:i?.textField,externalForwardedProps:d,additionalProps:{ref:n},ownerState:u});p.inputProps=Z({},l,p.inputProps),p.InputProps=Z({},a,p.InputProps);const y=m$(p),b=J$(y),w=u$(Z({},b,{slots:r,slotProps:i}));return D.jsx(f,Z({},w))});process.env.NODE_ENV!=="production"&&(Th.propTypes={autoFocus:s.bool,className:s.string,clearable:s.bool,color:s.oneOf(["error","info","primary","secondary","success","warning"]),component:s.elementType,defaultValue:s.object,disabled:s.bool,disableFuture:s.bool,disablePast:s.bool,enableAccessibleFieldDOMStructure:s.bool,focused:s.bool,format:s.string,formatDensity:s.oneOf(["dense","spacious"]),FormHelperTextProps:s.object,fullWidth:s.bool,helperText:s.node,hiddenLabel:s.bool,id:s.string,InputLabelProps:s.object,inputProps:s.object,InputProps:s.object,inputRef:Bt,label:s.node,margin:s.oneOf(["dense","none","normal"]),maxDate:s.object,minDate:s.object,name:s.string,onBlur:s.func,onChange:s.func,onClear:s.func,onError:s.func,onFocus:s.func,onSelectedSectionsChange:s.func,readOnly:s.bool,referenceDate:s.object,required:s.bool,selectedSections:s.oneOfType([s.oneOf(["all","day","empty","hours","meridiem","minutes","month","seconds","weekDay","year"]),s.number]),shouldDisableDate:s.func,shouldDisableMonth:s.func,shouldDisableYear:s.func,shouldRespectLeadingZeros:s.bool,size:s.oneOf(["medium","small"]),slotProps:s.object,slots:s.object,style:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),timezone:s.string,unstableFieldRef:s.oneOfType([s.func,s.object]),value:s.object,variant:s.oneOf(["filled","outlined","standard"])});const lb=({shouldDisableDate:e,shouldDisableMonth:t,shouldDisableYear:n,minDate:o,maxDate:r,disableFuture:i,disablePast:a,timezone:l})=>{const d=Yr();return k.useCallback(u=>va({adapter:d,value:u,timezone:l,props:{shouldDisableDate:e,shouldDisableMonth:t,shouldDisableYear:n,minDate:o,maxDate:r,disableFuture:i,disablePast:a}})!==null,[d,e,t,n,o,r,i,a,l])},tV=(e,t,n)=>(o,r)=>{switch(r.type){case"changeMonth":return Z({},o,{slideDirection:r.direction,currentMonth:r.newMonth,isMonthSwitchingAnimating:!e});case"changeMonthTimezone":{const i=r.newTimezone;if(n.getTimezone(o.currentMonth)===i)return o;let a=n.setTimezone(o.currentMonth,i);return n.getMonth(a)!==n.getMonth(o.currentMonth)&&(a=n.setMonth(a,n.getMonth(o.currentMonth))),Z({},o,{currentMonth:a})}case"finishMonthSwitchingAnimation":return Z({},o,{isMonthSwitchingAnimating:!1});case"changeFocusedDay":{if(o.focusedDay!=null&&r.focusedDay!=null&&n.isSameDay(r.focusedDay,o.focusedDay))return o;const i=r.focusedDay!=null&&!t&&!n.isSameMonth(o.currentMonth,r.focusedDay);return Z({},o,{focusedDay:r.focusedDay,isMonthSwitchingAnimating:i&&!e&&!r.withoutMonthSwitchingAnimation,currentMonth:i?n.startOfMonth(r.focusedDay):o.currentMonth,slideDirection:r.focusedDay!=null&&n.isAfterDay(r.focusedDay,o.currentMonth)?"left":"right"})}default:throw new Error("missing support")}},nV=e=>{const{value:t,referenceDate:n,disableFuture:o,disablePast:r,disableSwitchToMonthOnDayFocus:i=!1,maxDate:a,minDate:l,onMonthChange:d,reduceAnimations:u,shouldDisableDate:f,timezone:p}=e,y=Nt(),b=k.useRef(tV(!!u,i,y)).current,w=k.useMemo(()=>Po.getInitialReferenceValue({value:t,utils:y,timezone:p,props:e,referenceDate:n,granularity:wo.day}),[n,p]),[g,v]=k.useReducer(b,{isMonthSwitchingAnimating:!1,focusedDay:w,currentMonth:y.startOfMonth(w),slideDirection:"left"});k.useEffect(()=>{v({type:"changeMonthTimezone",newTimezone:y.getTimezone(w)})},[w,y]);const E=k.useCallback(O=>{v(Z({type:"changeMonth"},O)),d&&d(O.newMonth)},[d]),P=k.useCallback(O=>{const N=O;y.isSameMonth(N,g.currentMonth)||E({newMonth:y.startOfMonth(N),direction:y.isAfterDay(N,g.currentMonth)?"left":"right"})},[g.currentMonth,E,y]),x=lb({shouldDisableDate:f,minDate:l,maxDate:a,disableFuture:o,disablePast:r,timezone:p}),S=k.useCallback(()=>{v({type:"finishMonthSwitchingAnimation"})},[]),C=ke((O,N)=>{x(O)||v({type:"changeFocusedDay",focusedDay:O,withoutMonthSwitchingAnimation:N})});return{referenceDate:w,calendarState:g,changeMonth:P,changeFocusedDay:C,isDateDisabled:x,onMonthSwitchingAnimationEnd:S,handleChangeMonth:E}},oV=e=>Oe("MuiPickersFadeTransitionGroup",e);De("MuiPickersFadeTransitionGroup",["root"]);const rV=e=>{const{classes:t}=e;return Me({root:["root"]},oV,t)},sV=ae(sa,{name:"MuiPickersFadeTransitionGroup",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"block",position:"relative"});function cb(e){const t=Mt({props:e,name:"MuiPickersFadeTransitionGroup"}),{children:n,className:o,reduceAnimations:r,transKey:i}=t,a=rV(t),l=Fs();return r?n:D.jsx(sV,{className:Se(a.root,o),children:D.jsx(Wr,{appear:!1,mountOnEnter:!0,unmountOnExit:!0,timeout:{appear:l.transitions.duration.enteringScreen,enter:l.transitions.duration.enteringScreen,exit:0},children:n},i)})}function iV(e){return Oe("MuiPickersDay",e)}const Er=De("MuiPickersDay",["root","dayWithMargin","dayOutsideMonth","hiddenDaySpacingFiller","today","selected","disabled"]),aV=["autoFocus","className","day","disabled","disableHighlightToday","disableMargin","hidden","isAnimating","onClick","onDaySelect","onFocus","onBlur","onKeyDown","onMouseDown","onMouseEnter","outsideCurrentMonth","selected","showDaysOutsideCurrentMonth","children","today","isFirstVisibleCell","isLastVisibleCell"],lV=e=>{const{selected:t,disableMargin:n,disableHighlightToday:o,today:r,disabled:i,outsideCurrentMonth:a,showDaysOutsideCurrentMonth:l,classes:d}=e,u=a&&!l;return Me({root:["root",t&&!u&&"selected",i&&"disabled",!n&&"dayWithMargin",!o&&r&&"today",a&&l&&"dayOutsideMonth",u&&"hiddenDaySpacingFiller"],hiddenDaySpacingFiller:["hiddenDaySpacingFiller"]},iV,d)},db=({theme:e})=>Z({},e.typography.caption,{width:Xi,height:Xi,borderRadius:"50%",padding:0,backgroundColor:"transparent",transition:e.transitions.create("background-color",{duration:e.transitions.duration.short}),color:(e.vars||e).palette.text.primary,"@media (pointer: fine)":{"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.hoverOpacity})`:ot(e.palette.primary.main,e.palette.action.hoverOpacity)}},"&:focus":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.focusOpacity})`:ot(e.palette.primary.main,e.palette.action.focusOpacity),[`&.${Er.selected}`]:{willChange:"background-color",backgroundColor:(e.vars||e).palette.primary.dark}},[`&.${Er.selected}`]:{color:(e.vars||e).palette.primary.contrastText,backgroundColor:(e.vars||e).palette.primary.main,fontWeight:e.typography.fontWeightMedium,"&:hover":{willChange:"background-color",backgroundColor:(e.vars||e).palette.primary.dark}},[`&.${Er.disabled}:not(.${Er.selected})`]:{color:(e.vars||e).palette.text.disabled},[`&.${Er.disabled}&.${Er.selected}`]:{opacity:.6},variants:[{props:{disableMargin:!1},style:{margin:`0 ${wc}px`}},{props:{outsideCurrentMonth:!0,showDaysOutsideCurrentMonth:!0},style:{color:(e.vars||e).palette.text.secondary}},{props:{disableHighlightToday:!1,today:!0},style:{[`&:not(.${Er.selected})`]:{border:`1px solid ${(e.vars||e).palette.text.secondary}`}}}]}),ub=(e,t)=>{const{ownerState:n}=e;return[t.root,!n.disableMargin&&t.dayWithMargin,!n.disableHighlightToday&&n.today&&t.today,!n.outsideCurrentMonth&&n.showDaysOutsideCurrentMonth&&t.dayOutsideMonth,n.outsideCurrentMonth&&!n.showDaysOutsideCurrentMonth&&t.hiddenDaySpacingFiller]},cV=ae(pr,{name:"MuiPickersDay",slot:"Root",overridesResolver:ub})(db),dV=ae("div",{name:"MuiPickersDay",slot:"Root",overridesResolver:ub})(({theme:e})=>Z({},db({theme:e}),{opacity:0,pointerEvents:"none"})),pi=()=>{},hb=k.forwardRef(function(t,n){const o=Mt({props:t,name:"MuiPickersDay"}),{autoFocus:r=!1,className:i,day:a,disabled:l=!1,disableHighlightToday:d=!1,disableMargin:u=!1,isAnimating:f,onClick:p,onDaySelect:y,onFocus:b=pi,onBlur:w=pi,onKeyDown:g=pi,onMouseDown:v=pi,onMouseEnter:E=pi,outsideCurrentMonth:P,selected:x=!1,showDaysOutsideCurrentMonth:S=!1,children:C,today:O=!1}=o,N=We(o,aV),F=Z({},o,{autoFocus:r,disabled:l,disableHighlightToday:d,disableMargin:u,selected:x,showDaysOutsideCurrentMonth:S,today:O}),z=lV(F),R=Nt(),$=k.useRef(null),K=at($,n);nn(()=>{r&&!l&&!f&&!P&&$.current.focus()},[r,l,f,P]);const X=Y=>{v(Y),P&&Y.preventDefault()},q=Y=>{l||y(a),P&&Y.currentTarget.focus(),p&&p(Y)};return P&&!S?D.jsx(dV,{className:Se(z.root,z.hiddenDaySpacingFiller,i),ownerState:F,role:N.role}):D.jsx(cV,Z({className:Se(z.root,i),ref:K,centerRipple:!0,disabled:l,tabIndex:x?0:-1,onKeyDown:Y=>g(Y,a),onFocus:Y=>b(Y,a),onBlur:Y=>w(Y,a),onMouseEnter:Y=>E(Y,a),onClick:q,onMouseDown:X},N,{ownerState:F,children:C||R.format(a,"dayOfMonth")}))});process.env.NODE_ENV!=="production"&&(hb.propTypes={action:s.oneOfType([s.func,s.shape({current:s.shape({focusVisible:s.func.isRequired})})]),centerRipple:s.bool,classes:s.object,className:s.string,component:s.elementType,day:s.object.isRequired,disabled:s.bool,disableHighlightToday:s.bool,disableMargin:s.bool,disableRipple:s.bool,disableTouchRipple:s.bool,focusRipple:s.bool,focusVisibleClassName:s.string,isAnimating:s.bool,isFirstVisibleCell:s.bool.isRequired,isLastVisibleCell:s.bool.isRequired,onBlur:s.func,onDaySelect:s.func.isRequired,onFocus:s.func,onFocusVisible:s.func,onKeyDown:s.func,onMouseEnter:s.func,outsideCurrentMonth:s.bool.isRequired,selected:s.bool,showDaysOutsideCurrentMonth:s.bool,style:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),tabIndex:s.number,today:s.bool,TouchRippleProps:s.object,touchRippleRef:s.oneOfType([s.func,s.shape({current:s.shape({pulsate:s.func.isRequired,start:s.func.isRequired,stop:s.func.isRequired})})])});const uV=k.memo(hb),hV=e=>Oe("MuiPickersSlideTransition",e),Wn=De("MuiPickersSlideTransition",["root","slideEnter-left","slideEnter-right","slideEnterActive","slideExit","slideExitActiveLeft-left","slideExitActiveLeft-right"]),fV=["children","className","reduceAnimations","slideDirection","transKey","classes"],pV=e=>{const{classes:t,slideDirection:n}=e,o={root:["root"],exit:["slideExit"],enterActive:["slideEnterActive"],enter:[`slideEnter-${n}`],exitActive:[`slideExitActiveLeft-${n}`]};return Me(o,hV,t)},mV=ae(sa,{name:"MuiPickersSlideTransition",slot:"Root",overridesResolver:(e,t)=>[t.root,{[`.${Wn["slideEnter-left"]}`]:t["slideEnter-left"]},{[`.${Wn["slideEnter-right"]}`]:t["slideEnter-right"]},{[`.${Wn.slideEnterActive}`]:t.slideEnterActive},{[`.${Wn.slideExit}`]:t.slideExit},{[`.${Wn["slideExitActiveLeft-left"]}`]:t["slideExitActiveLeft-left"]},{[`.${Wn["slideExitActiveLeft-right"]}`]:t["slideExitActiveLeft-right"]}]})(({theme:e})=>{const t=e.transitions.create("transform",{duration:e.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},[`& .${Wn["slideEnter-left"]}`]:{willChange:"transform",transform:"translate(100%)",zIndex:1},[`& .${Wn["slideEnter-right"]}`]:{willChange:"transform",transform:"translate(-100%)",zIndex:1},[`& .${Wn.slideEnterActive}`]:{transform:"translate(0%)",transition:t},[`& .${Wn.slideExit}`]:{transform:"translate(0%)"},[`& .${Wn["slideExitActiveLeft-left"]}`]:{willChange:"transform",transform:"translate(-100%)",transition:t,zIndex:0},[`& .${Wn["slideExitActiveLeft-right"]}`]:{willChange:"transform",transform:"translate(100%)",transition:t,zIndex:0}}});function gV(e){const t=Mt({props:e,name:"MuiPickersSlideTransition"}),{children:n,className:o,reduceAnimations:r,transKey:i}=t,a=We(t,fV),l=pV(t),d=Fs();if(r)return D.jsx("div",{className:Se(l.root,o),children:n});const u={exit:l.exit,enterActive:l.enterActive,enter:l.enter,exitActive:l.exitActive};return D.jsx(mV,{className:Se(l.root,o),childFactory:f=>k.cloneElement(f,{classNames:u}),role:"presentation",children:D.jsx(Su,Z({mountOnEnter:!0,unmountOnExit:!0,timeout:d.transitions.duration.complex,classNames:u},a,{children:n}),i)})}const yV=e=>Oe("MuiDayCalendar",e);De("MuiDayCalendar",["root","header","weekDayLabel","loadingContainer","slideTransition","monthContainer","weekContainer","weekNumberLabel","weekNumber"]);const vV=["parentProps","day","focusableDay","selectedDays","isDateDisabled","currentMonthNumber","isViewFocused"],bV=["ownerState"],wV=e=>{const{classes:t}=e;return Me({root:["root"],header:["header"],weekDayLabel:["weekDayLabel"],loadingContainer:["loadingContainer"],slideTransition:["slideTransition"],monthContainer:["monthContainer"],weekContainer:["weekContainer"],weekNumberLabel:["weekNumberLabel"],weekNumber:["weekNumber"]},yV,t)},fb=(Xi+wc*2)*6,CV=ae("div",{name:"MuiDayCalendar",slot:"Root",overridesResolver:(e,t)=>t.root})({}),SV=ae("div",{name:"MuiDayCalendar",slot:"Header",overridesResolver:(e,t)=>t.header})({display:"flex",justifyContent:"center",alignItems:"center"}),_V=ae(kn,{name:"MuiDayCalendar",slot:"WeekDayLabel",overridesResolver:(e,t)=>t.weekDayLabel})(({theme:e})=>({width:36,height:40,margin:"0 2px",textAlign:"center",display:"flex",justifyContent:"center",alignItems:"center",color:(e.vars||e).palette.text.secondary})),xV=ae(kn,{name:"MuiDayCalendar",slot:"WeekNumberLabel",overridesResolver:(e,t)=>t.weekNumberLabel})(({theme:e})=>({width:36,height:40,margin:"0 2px",textAlign:"center",display:"flex",justifyContent:"center",alignItems:"center",color:e.palette.text.disabled})),RV=ae(kn,{name:"MuiDayCalendar",slot:"WeekNumber",overridesResolver:(e,t)=>t.weekNumber})(({theme:e})=>Z({},e.typography.caption,{width:Xi,height:Xi,padding:0,margin:`0 ${wc}px`,color:e.palette.text.disabled,fontSize:"0.75rem",alignItems:"center",justifyContent:"center",display:"inline-flex"})),kV=ae("div",{name:"MuiDayCalendar",slot:"LoadingContainer",overridesResolver:(e,t)=>t.loadingContainer})({display:"flex",justifyContent:"center",alignItems:"center",minHeight:fb}),TV=ae(gV,{name:"MuiDayCalendar",slot:"SlideTransition",overridesResolver:(e,t)=>t.slideTransition})({minHeight:fb}),EV=ae("div",{name:"MuiDayCalendar",slot:"MonthContainer",overridesResolver:(e,t)=>t.monthContainer})({overflow:"hidden"}),PV=ae("div",{name:"MuiDayCalendar",slot:"WeekContainer",overridesResolver:(e,t)=>t.weekContainer})({margin:`${wc}px 0`,display:"flex",justifyContent:"center"});function DV(e){let{parentProps:t,day:n,focusableDay:o,selectedDays:r,isDateDisabled:i,currentMonthNumber:a,isViewFocused:l}=e,d=We(e,vV);const{disabled:u,disableHighlightToday:f,isMonthSwitchingAnimating:p,showDaysOutsideCurrentMonth:y,slots:b,slotProps:w,timezone:g}=t,v=Nt(),E=bc(g),P=o!==null&&v.isSameDay(n,o),x=r.some(K=>v.isSameDay(K,n)),S=v.isSameDay(n,E),C=b?.day??uV,O=dt({elementType:C,externalSlotProps:w?.day,additionalProps:Z({disableHighlightToday:f,showDaysOutsideCurrentMonth:y,role:"gridcell",isAnimating:p,"data-timestamp":v.toJsDate(n).valueOf()},d),ownerState:Z({},t,{day:n,selected:x})}),N=We(O,bV),F=k.useMemo(()=>u||i(n),[u,i,n]),z=k.useMemo(()=>v.getMonth(n)!==a,[v,n,a]),R=k.useMemo(()=>{const K=v.startOfMonth(v.setMonth(n,a));return y?v.isSameDay(n,v.startOfWeek(K)):v.isSameDay(n,K)},[a,n,y,v]),$=k.useMemo(()=>{const K=v.endOfMonth(v.setMonth(n,a));return y?v.isSameDay(n,v.endOfWeek(K)):v.isSameDay(n,K)},[a,n,y,v]);return D.jsx(C,Z({},N,{day:n,disabled:F,autoFocus:l&&P,today:S,outsideCurrentMonth:z,isFirstVisibleCell:R,isLastVisibleCell:$,selected:x,tabIndex:P?0:-1,"aria-selected":x,"aria-current":S?"date":void 0}))}function OV(e){const t=Mt({props:e,name:"MuiDayCalendar"}),n=Nt(),{onFocusedDayChange:o,className:r,currentMonth:i,selectedDays:a,focusedDay:l,loading:d,onSelectedDaysChange:u,onMonthSwitchingAnimationEnd:f,readOnly:p,reduceAnimations:y,renderLoading:b=()=>D.jsx("span",{children:"..."}),slideDirection:w,TransitionProps:g,disablePast:v,disableFuture:E,minDate:P,maxDate:x,shouldDisableDate:S,shouldDisableMonth:C,shouldDisableYear:O,dayOfWeekFormatter:N=me=>n.format(me,"weekdayShort").charAt(0).toUpperCase(),hasFocus:F,onFocusedViewChange:z,gridLabelId:R,displayWeekNumber:$,fixedWeekNumber:K,autoFocus:X,timezone:q}=t,Y=bc(q),H=wV(t),le=lo(),A=lb({shouldDisableDate:S,shouldDisableMonth:C,shouldDisableYear:O,minDate:P,maxDate:x,disablePast:v,disableFuture:E,timezone:q}),M=rr(),[V,B]=ko({name:"DayCalendar",state:"hasFocus",controlled:F,default:X??!1}),[ne,oe]=k.useState(()=>l||Y),se=ke(me=>{p||u(me)}),j=me=>{A(me)||(o(me),oe(me),z?.(!0),B(!0))},J=ke((me,Ce)=>{switch(me.key){case"ArrowUp":j(n.addDays(Ce,-7)),me.preventDefault();break;case"ArrowDown":j(n.addDays(Ce,7)),me.preventDefault();break;case"ArrowLeft":{const ve=n.addDays(Ce,le?1:-1),xe=n.addMonths(Ce,le?1:-1),Ve=Ei({utils:n,date:ve,minDate:le?ve:n.startOfMonth(xe),maxDate:le?n.endOfMonth(xe):ve,isDateDisabled:A,timezone:q});j(Ve||ve),me.preventDefault();break}case"ArrowRight":{const ve=n.addDays(Ce,le?-1:1),xe=n.addMonths(Ce,le?-1:1),Ve=Ei({utils:n,date:ve,minDate:le?n.startOfMonth(xe):ve,maxDate:le?ve:n.endOfMonth(xe),isDateDisabled:A,timezone:q});j(Ve||ve),me.preventDefault();break}case"Home":j(n.startOfWeek(Ce)),me.preventDefault();break;case"End":j(n.endOfWeek(Ce)),me.preventDefault();break;case"PageUp":j(n.addMonths(Ce,1)),me.preventDefault();break;case"PageDown":j(n.addMonths(Ce,-1)),me.preventDefault();break}}),ee=ke((me,Ce)=>j(Ce)),te=ke((me,Ce)=>{V&&n.isSameDay(ne,Ce)&&z?.(!1)}),ce=n.getMonth(i),ie=n.getYear(i),he=k.useMemo(()=>a.filter(me=>!!me).map(me=>n.startOfDay(me)),[n,a]),W=`${ie}-${ce}`,re=k.useMemo(()=>k.createRef(),[W]),Q=k.useMemo(()=>{const me=n.startOfMonth(i),Ce=n.endOfMonth(i);return A(ne)||n.isAfterDay(ne,Ce)||n.isBeforeDay(ne,me)?Ei({utils:n,date:ne,minDate:me,maxDate:Ce,disablePast:v,disableFuture:E,isDateDisabled:A,timezone:q}):ne},[i,E,v,ne,A,n,q]),fe=k.useMemo(()=>{const me=n.getWeekArray(i);let Ce=n.addMonths(i,1);for(;K&&me.length<K;){const ve=n.getWeekArray(Ce),xe=n.isSameDay(me[me.length-1][0],ve[0][0]);ve.slice(xe?1:0).forEach(Ve=>{me.length<K&&me.push(Ve)}),Ce=n.addMonths(Ce,1)}return me},[i,K,n]);return D.jsxs(CV,{role:"grid","aria-labelledby":R,className:H.root,children:[D.jsxs(SV,{role:"row",className:H.header,children:[$&&D.jsx(xV,{variant:"caption",role:"columnheader","aria-label":M.calendarWeekNumberHeaderLabel,className:H.weekNumberLabel,children:M.calendarWeekNumberHeaderText}),CF(n,Y).map((me,Ce)=>D.jsx(_V,{variant:"caption",role:"columnheader","aria-label":n.format(me,"weekday"),className:H.weekDayLabel,children:N(me)},Ce.toString()))]}),d?D.jsx(kV,{className:H.loadingContainer,children:b()}):D.jsx(TV,Z({transKey:W,onExited:f,reduceAnimations:y,slideDirection:w,className:Se(r,H.slideTransition)},g,{nodeRef:re,children:D.jsx(EV,{ref:re,role:"rowgroup",className:H.monthContainer,children:fe.map((me,Ce)=>D.jsxs(PV,{role:"row",className:H.weekContainer,"aria-rowindex":Ce+1,children:[$&&D.jsx(RV,{className:H.weekNumber,role:"rowheader","aria-label":M.calendarWeekNumberAriaLabelText(n.getWeekNumber(me[0])),children:M.calendarWeekNumberText(n.getWeekNumber(me[0]))}),me.map((ve,xe)=>D.jsx(DV,{parentProps:t,day:ve,selectedDays:he,focusableDay:Q,onKeyDown:J,onFocus:ee,onBlur:te,onDaySelect:se,isDateDisabled:A,currentMonthNumber:ce,isViewFocused:V,"aria-colindex":xe+1},ve.toString()))]},`week-${me[0]}`))})}))]})}function MV(e){return Oe("MuiPickersMonth",e)}const qa=De("MuiPickersMonth",["root","monthButton","disabled","selected"]),IV=["autoFocus","className","children","disabled","selected","value","tabIndex","onClick","onKeyDown","onFocus","onBlur","aria-current","aria-label","monthsPerRow","slots","slotProps"],NV=e=>{const{disabled:t,selected:n,classes:o}=e;return Me({root:["root"],monthButton:["monthButton",t&&"disabled",n&&"selected"]},MV,o)},AV=ae("div",{name:"MuiPickersMonth",slot:"Root",overridesResolver:(e,t)=>[t.root]})({display:"flex",alignItems:"center",justifyContent:"center",flexBasis:"33.3%",variants:[{props:{monthsPerRow:4},style:{flexBasis:"25%"}}]}),FV=ae("button",{name:"MuiPickersMonth",slot:"MonthButton",overridesResolver:(e,t)=>[t.monthButton,{[`&.${qa.disabled}`]:t.disabled},{[`&.${qa.selected}`]:t.selected}]})(({theme:e})=>Z({color:"unset",backgroundColor:"transparent",border:0,outline:0},e.typography.subtitle1,{margin:"8px 0",height:36,width:72,borderRadius:18,cursor:"pointer","&:focus":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.hoverOpacity})`:ot(e.palette.action.active,e.palette.action.hoverOpacity)},"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.hoverOpacity})`:ot(e.palette.action.active,e.palette.action.hoverOpacity)},"&:disabled":{cursor:"auto",pointerEvents:"none"},[`&.${qa.disabled}`]:{color:(e.vars||e).palette.text.secondary},[`&.${qa.selected}`]:{color:(e.vars||e).palette.primary.contrastText,backgroundColor:(e.vars||e).palette.primary.main,"&:focus, &:hover":{backgroundColor:(e.vars||e).palette.primary.dark}}})),LV=k.memo(function(t){const n=Mt({props:t,name:"MuiPickersMonth"}),{autoFocus:o,className:r,children:i,disabled:a,selected:l,value:d,tabIndex:u,onClick:f,onKeyDown:p,onFocus:y,onBlur:b,"aria-current":w,"aria-label":g,slots:v,slotProps:E}=n,P=We(n,IV),x=k.useRef(null),S=NV(n);nn(()=>{o&&x.current?.focus()},[o]);const C=v?.monthButton??FV,O=dt({elementType:C,externalSlotProps:E?.monthButton,additionalProps:{children:i,disabled:a,tabIndex:u,ref:x,type:"button",role:"radio","aria-current":w,"aria-checked":l,"aria-label":g,onClick:N=>f(N,d),onKeyDown:N=>p(N,d),onFocus:N=>y(N,d),onBlur:N=>b(N,d)},ownerState:n,className:S.monthButton});return D.jsx(AV,Z({className:Se(S.root,r),ownerState:n},P,{children:D.jsx(C,Z({},O))}))});function $V(e){return Oe("MuiMonthCalendar",e)}De("MuiMonthCalendar",["root"]);const VV=["className","value","defaultValue","referenceDate","disabled","disableFuture","disablePast","maxDate","minDate","onChange","shouldDisableMonth","readOnly","disableHighlightToday","autoFocus","onMonthFocus","hasFocus","onFocusedViewChange","monthsPerRow","timezone","gridLabelId","slots","slotProps"],jV=e=>{const{classes:t}=e;return Me({root:["root"]},$V,t)};function BV(e,t){const n=Nt(),o=ya(),r=Mt({props:e,name:t});return Z({disableFuture:!1,disablePast:!1},r,{minDate:Xn(n,r.minDate,o.minDate),maxDate:Xn(n,r.maxDate,o.maxDate)})}const WV=ae("div",{name:"MuiMonthCalendar",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"flex",flexWrap:"wrap",alignContent:"stretch",padding:"0 4px",width:Cc,boxSizing:"border-box"}),pb=k.forwardRef(function(t,n){const o=BV(t,"MuiMonthCalendar"),{className:r,value:i,defaultValue:a,referenceDate:l,disabled:d,disableFuture:u,disablePast:f,maxDate:p,minDate:y,onChange:b,shouldDisableMonth:w,readOnly:g,autoFocus:v=!1,onMonthFocus:E,hasFocus:P,onFocusedViewChange:x,monthsPerRow:S=3,timezone:C,gridLabelId:O,slots:N,slotProps:F}=o,z=We(o,VV),{value:R,handleValueChange:$,timezone:K}=wh({name:"MonthCalendar",timezone:C,value:i,defaultValue:a,onChange:b,valueManager:Po}),X=bc(K),q=lo(),Y=Nt(),H=k.useMemo(()=>Po.getInitialReferenceValue({value:R,utils:Y,props:o,timezone:K,referenceDate:l,granularity:wo.month}),[]),le=o,A=jV(le),M=k.useMemo(()=>Y.getMonth(X),[Y,X]),V=k.useMemo(()=>R!=null?Y.getMonth(R):null,[R,Y]),[B,ne]=k.useState(()=>V||Y.getMonth(H)),[oe,se]=ko({name:"MonthCalendar",state:"hasFocus",controlled:P,default:v??!1}),j=ke(W=>{se(W),x&&x(W)}),J=k.useCallback(W=>{const re=Y.startOfMonth(f&&Y.isAfter(X,y)?X:y),Q=Y.startOfMonth(u&&Y.isBefore(X,p)?X:p),fe=Y.startOfMonth(W);return Y.isBefore(fe,re)||Y.isAfter(fe,Q)?!0:w?w(fe):!1},[u,f,p,y,X,w,Y]),ee=ke((W,re)=>{if(g)return;const Q=Y.setMonth(R??H,re);$(Q)}),te=ke(W=>{J(Y.setMonth(R??H,W))||(ne(W),j(!0),E&&E(W))});k.useEffect(()=>{ne(W=>V!==null&&W!==V?V:W)},[V]);const ce=ke((W,re)=>{switch(W.key){case"ArrowUp":te((12+re-3)%12),W.preventDefault();break;case"ArrowDown":te((12+re+3)%12),W.preventDefault();break;case"ArrowLeft":te((12+re+(q?1:-1))%12),W.preventDefault();break;case"ArrowRight":te((12+re+(q?-1:1))%12),W.preventDefault();break}}),ie=ke((W,re)=>{te(re)}),he=ke((W,re)=>{B===re&&j(!1)});return D.jsx(WV,Z({ref:n,className:Se(A.root,r),ownerState:le,role:"radiogroup","aria-labelledby":O},z,{children:ph(Y,R??H).map(W=>{const re=Y.getMonth(W),Q=Y.format(W,"monthShort"),fe=Y.format(W,"month"),me=re===V,Ce=d||J(W);return D.jsx(LV,{selected:me,value:re,onClick:ee,onKeyDown:ce,autoFocus:oe&&re===B,disabled:Ce,tabIndex:re===B&&!Ce?0:-1,onFocus:ie,onBlur:he,"aria-current":M===re?"date":void 0,"aria-label":fe,monthsPerRow:S,slots:N,slotProps:F,children:Q},Q)})}))});process.env.NODE_ENV!=="production"&&(pb.propTypes={autoFocus:s.bool,classes:s.object,className:s.string,defaultValue:s.object,disabled:s.bool,disableFuture:s.bool,disableHighlightToday:s.bool,disablePast:s.bool,gridLabelId:s.string,hasFocus:s.bool,maxDate:s.object,minDate:s.object,monthsPerRow:s.oneOf([3,4]),onChange:s.func,onFocusedViewChange:s.func,onMonthFocus:s.func,readOnly:s.bool,referenceDate:s.object,shouldDisableMonth:s.func,slotProps:s.object,slots:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),timezone:s.string,value:s.object});function HV(e){return Oe("MuiPickersYear",e)}const Ga=De("MuiPickersYear",["root","yearButton","selected","disabled"]),zV=["autoFocus","className","children","disabled","selected","value","tabIndex","onClick","onKeyDown","onFocus","onBlur","aria-current","yearsPerRow","slots","slotProps"],YV=e=>{const{disabled:t,selected:n,classes:o}=e;return Me({root:["root"],yearButton:["yearButton",t&&"disabled",n&&"selected"]},HV,o)},UV=ae("div",{name:"MuiPickersYear",slot:"Root",overridesResolver:(e,t)=>[t.root]})({display:"flex",alignItems:"center",justifyContent:"center",flexBasis:"33.3%",variants:[{props:{yearsPerRow:4},style:{flexBasis:"25%"}}]}),qV=ae("button",{name:"MuiPickersYear",slot:"YearButton",overridesResolver:(e,t)=>[t.yearButton,{[`&.${Ga.disabled}`]:t.disabled},{[`&.${Ga.selected}`]:t.selected}]})(({theme:e})=>Z({color:"unset",backgroundColor:"transparent",border:0,outline:0},e.typography.subtitle1,{margin:"6px 0",height:36,width:72,borderRadius:18,cursor:"pointer","&:focus":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.focusOpacity})`:ot(e.palette.action.active,e.palette.action.focusOpacity)},"&:hover":{backgroundColor:e.vars?`rgba(${e.vars.palette.action.activeChannel} / ${e.vars.palette.action.hoverOpacity})`:ot(e.palette.action.active,e.palette.action.hoverOpacity)},"&:disabled":{cursor:"auto",pointerEvents:"none"},[`&.${Ga.disabled}`]:{color:(e.vars||e).palette.text.secondary},[`&.${Ga.selected}`]:{color:(e.vars||e).palette.primary.contrastText,backgroundColor:(e.vars||e).palette.primary.main,"&:focus, &:hover":{backgroundColor:(e.vars||e).palette.primary.dark}}})),GV=k.memo(function(t){const n=Mt({props:t,name:"MuiPickersYear"}),{autoFocus:o,className:r,children:i,disabled:a,selected:l,value:d,tabIndex:u,onClick:f,onKeyDown:p,onFocus:y,onBlur:b,"aria-current":w,slots:g,slotProps:v}=n,E=We(n,zV),P=k.useRef(null),x=YV(n);nn(()=>{o&&P.current?.focus()},[o]);const S=g?.yearButton??qV,C=dt({elementType:S,externalSlotProps:v?.yearButton,additionalProps:{children:i,disabled:a,tabIndex:u,ref:P,type:"button",role:"radio","aria-current":w,"aria-checked":l,onClick:O=>f(O,d),onKeyDown:O=>p(O,d),onFocus:O=>y(O,d),onBlur:O=>b(O,d)},ownerState:n,className:x.yearButton});return D.jsx(UV,Z({className:Se(x.root,r),ownerState:n},E,{children:D.jsx(S,Z({},C))}))});function KV(e){return Oe("MuiYearCalendar",e)}De("MuiYearCalendar",["root"]);const XV=["autoFocus","className","value","defaultValue","referenceDate","disabled","disableFuture","disablePast","maxDate","minDate","onChange","readOnly","shouldDisableYear","disableHighlightToday","onYearFocus","hasFocus","onFocusedViewChange","yearsOrder","yearsPerRow","timezone","gridLabelId","slots","slotProps"],ZV=e=>{const{classes:t}=e;return Me({root:["root"]},KV,t)};function QV(e,t){const n=Nt(),o=ya(),r=Mt({props:e,name:t});return Z({disablePast:!1,disableFuture:!1},r,{yearsPerRow:r.yearsPerRow??3,minDate:Xn(n,r.minDate,o.minDate),maxDate:Xn(n,r.maxDate,o.maxDate)})}const JV=ae("div",{name:"MuiYearCalendar",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"flex",flexDirection:"row",flexWrap:"wrap",overflowY:"auto",height:"100%",padding:"0 4px",width:Cc,maxHeight:OL,boxSizing:"border-box",position:"relative"}),mb=k.forwardRef(function(t,n){const o=QV(t,"MuiYearCalendar"),{autoFocus:r,className:i,value:a,defaultValue:l,referenceDate:d,disabled:u,disableFuture:f,disablePast:p,maxDate:y,minDate:b,onChange:w,readOnly:g,shouldDisableYear:v,onYearFocus:E,hasFocus:P,onFocusedViewChange:x,yearsOrder:S="asc",yearsPerRow:C,timezone:O,gridLabelId:N,slots:F,slotProps:z}=o,R=We(o,XV),{value:$,handleValueChange:K,timezone:X}=wh({name:"YearCalendar",timezone:O,value:a,defaultValue:l,onChange:w,valueManager:Po}),q=bc(X),Y=lo(),H=Nt(),le=k.useMemo(()=>Po.getInitialReferenceValue({value:$,utils:H,props:o,timezone:X,referenceDate:d,granularity:wo.year}),[]),A=o,M=ZV(A),V=k.useMemo(()=>H.getYear(q),[H,q]),B=k.useMemo(()=>$!=null?H.getYear($):null,[$,H]),[ne,oe]=k.useState(()=>B||H.getYear(le)),[se,j]=ko({name:"YearCalendar",state:"hasFocus",controlled:P,default:r??!1}),J=ke(ve=>{j(ve),x&&x(ve)}),ee=k.useCallback(ve=>{if(p&&H.isBeforeYear(ve,q)||f&&H.isAfterYear(ve,q)||b&&H.isBeforeYear(ve,b)||y&&H.isAfterYear(ve,y))return!0;if(!v)return!1;const xe=H.startOfYear(ve);return v(xe)},[f,p,y,b,q,v,H]),te=ke((ve,xe)=>{if(g)return;const Ve=H.setYear($??le,xe);K(Ve)}),ce=ke(ve=>{ee(H.setYear($??le,ve))||(oe(ve),J(!0),E?.(ve))});k.useEffect(()=>{oe(ve=>B!==null&&ve!==B?B:ve)},[B]);const ie=S!=="desc"?C*1:C*-1,he=Y&&S==="asc"||!Y&&S==="desc"?-1:1,W=ke((ve,xe)=>{switch(ve.key){case"ArrowUp":ce(xe-ie),ve.preventDefault();break;case"ArrowDown":ce(xe+ie),ve.preventDefault();break;case"ArrowLeft":ce(xe-he),ve.preventDefault();break;case"ArrowRight":ce(xe+he),ve.preventDefault();break}}),re=ke((ve,xe)=>{ce(xe)}),Q=ke((ve,xe)=>{ne===xe&&J(!1)}),fe=k.useRef(null),me=at(n,fe);k.useEffect(()=>{if(r||fe.current===null)return;const ve=fe.current.querySelector('[tabindex="0"]');if(!ve)return;const xe=ve.offsetHeight,Ve=ve.offsetTop,Ae=fe.current.clientHeight,st=fe.current.scrollTop,Pe=Ve+xe;xe>Ae||Ve<st||(fe.current.scrollTop=Pe-Ae/2-xe/2)},[r]);const Ce=H.getYearRange([b,y]);return S==="desc"&&Ce.reverse(),D.jsx(JV,Z({ref:me,className:Se(M.root,i),ownerState:A,role:"radiogroup","aria-labelledby":N},R,{children:Ce.map(ve=>{const xe=H.getYear(ve),Ve=xe===B,Ae=u||ee(ve);return D.jsx(GV,{selected:Ve,value:xe,onClick:te,onKeyDown:W,autoFocus:se&&xe===ne,disabled:Ae,tabIndex:xe===ne&&!Ae?0:-1,onFocus:re,onBlur:Q,"aria-current":V===xe?"date":void 0,yearsPerRow:C,slots:F,slotProps:z,children:H.format(ve,"year")},H.format(ve,"year"))})}))});process.env.NODE_ENV!=="production"&&(mb.propTypes={autoFocus:s.bool,classes:s.object,className:s.string,defaultValue:s.object,disabled:s.bool,disableFuture:s.bool,disableHighlightToday:s.bool,disablePast:s.bool,gridLabelId:s.string,hasFocus:s.bool,maxDate:s.object,minDate:s.object,onChange:s.func,onFocusedViewChange:s.func,onYearFocus:s.func,readOnly:s.bool,referenceDate:s.object,shouldDisableYear:s.func,slotProps:s.object,slots:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),timezone:s.string,value:s.object,yearsOrder:s.oneOf(["asc","desc"]),yearsPerRow:s.oneOf([3,4])});const ej=e=>Oe("MuiPickersCalendarHeader",e),tj=De("MuiPickersCalendarHeader",["root","labelContainer","label","switchViewButton","switchViewIcon"]);function nj(e){return Oe("MuiPickersArrowSwitcher",e)}De("MuiPickersArrowSwitcher",["root","spacer","button","previousIconButton","nextIconButton","leftArrowIcon","rightArrowIcon"]);const oj=["children","className","slots","slotProps","isNextDisabled","isNextHidden","onGoToNext","nextLabel","isPreviousDisabled","isPreviousHidden","onGoToPrevious","previousLabel","labelId"],rj=["ownerState"],sj=["ownerState"],ij=ae("div",{name:"MuiPickersArrowSwitcher",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"flex"}),aj=ae("div",{name:"MuiPickersArrowSwitcher",slot:"Spacer",overridesResolver:(e,t)=>t.spacer})(({theme:e})=>({width:e.spacing(3)})),Dm=ae($s,{name:"MuiPickersArrowSwitcher",slot:"Button",overridesResolver:(e,t)=>t.button})({variants:[{props:{hidden:!0},style:{visibility:"hidden"}}]}),lj=e=>{const{classes:t}=e;return Me({root:["root"],spacer:["spacer"],button:["button"],previousIconButton:["previousIconButton"],nextIconButton:["nextIconButton"],leftArrowIcon:["leftArrowIcon"],rightArrowIcon:["rightArrowIcon"]},nj,t)},cj=k.forwardRef(function(t,n){const o=lo(),r=Mt({props:t,name:"MuiPickersArrowSwitcher"}),{children:i,className:a,slots:l,slotProps:d,isNextDisabled:u,isNextHidden:f,onGoToNext:p,nextLabel:y,isPreviousDisabled:b,isPreviousHidden:w,onGoToPrevious:g,previousLabel:v,labelId:E}=r,P=We(r,oj),x=r,S=lj(x),C={isDisabled:u,isHidden:f,goTo:p,label:y},O={isDisabled:b,isHidden:w,goTo:g,label:v},N=l?.previousIconButton??Dm,F=dt({elementType:N,externalSlotProps:d?.previousIconButton,additionalProps:{size:"medium",title:O.label,"aria-label":O.label,disabled:O.isDisabled,edge:"end",onClick:O.goTo},ownerState:Z({},x,{hidden:O.isHidden}),className:Se(S.button,S.previousIconButton)}),z=l?.nextIconButton??Dm,R=dt({elementType:z,externalSlotProps:d?.nextIconButton,additionalProps:{size:"medium",title:C.label,"aria-label":C.label,disabled:C.isDisabled,edge:"start",onClick:C.goTo},ownerState:Z({},x,{hidden:C.isHidden}),className:Se(S.button,S.nextIconButton)}),$=l?.leftArrowIcon??UL,K=dt({elementType:$,externalSlotProps:d?.leftArrowIcon,additionalProps:{fontSize:"inherit"},ownerState:x,className:S.leftArrowIcon}),X=We(K,rj),q=l?.rightArrowIcon??qL,Y=dt({elementType:q,externalSlotProps:d?.rightArrowIcon,additionalProps:{fontSize:"inherit"},ownerState:x,className:S.rightArrowIcon}),H=We(Y,sj);return D.jsxs(ij,Z({ref:n,className:Se(S.root,a),ownerState:x},P,{children:[D.jsx(N,Z({},F,{children:o?D.jsx(q,Z({},H)):D.jsx($,Z({},X))})),i?D.jsx(kn,{variant:"subtitle1",component:"span",id:E,children:i}):D.jsx(aj,{className:S.spacer,ownerState:x}),D.jsx(z,Z({},R,{children:o?D.jsx($,Z({},X)):D.jsx(q,Z({},H))}))]}))});function dj(e,{disableFuture:t,maxDate:n,timezone:o}){const r=Nt();return k.useMemo(()=>{const i=r.date(void 0,o),a=r.startOfMonth(t&&r.isBefore(i,n)?i:n);return!r.isAfter(a,e)},[t,n,e,r,o])}function uj(e,{disablePast:t,minDate:n,timezone:o}){const r=Nt();return k.useMemo(()=>{const i=r.date(void 0,o),a=r.startOfMonth(t&&r.isAfter(i,n)?i:n);return!r.isBefore(a,e)},[t,n,e,r,o])}const hj=["slots","slotProps","currentMonth","disabled","disableFuture","disablePast","maxDate","minDate","onMonthChange","onViewChange","view","reduceAnimations","views","labelId","className","timezone","format"],fj=["ownerState"],pj=e=>{const{classes:t}=e;return Me({root:["root"],labelContainer:["labelContainer"],label:["label"],switchViewButton:["switchViewButton"],switchViewIcon:["switchViewIcon"]},ej,t)},mj=ae("div",{name:"MuiPickersCalendarHeader",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"flex",alignItems:"center",marginTop:12,marginBottom:4,paddingLeft:24,paddingRight:12,maxHeight:40,minHeight:40}),gj=ae("div",{name:"MuiPickersCalendarHeader",slot:"LabelContainer",overridesResolver:(e,t)=>t.labelContainer})(({theme:e})=>Z({display:"flex",overflow:"hidden",alignItems:"center",cursor:"pointer",marginRight:"auto"},e.typography.body1,{fontWeight:e.typography.fontWeightMedium})),yj=ae("div",{name:"MuiPickersCalendarHeader",slot:"Label",overridesResolver:(e,t)=>t.label})({marginRight:6}),vj=ae($s,{name:"MuiPickersCalendarHeader",slot:"SwitchViewButton",overridesResolver:(e,t)=>t.switchViewButton})({marginRight:"auto",variants:[{props:{view:"year"},style:{[`.${tj.switchViewIcon}`]:{transform:"rotate(180deg)"}}}]}),bj=ae(YL,{name:"MuiPickersCalendarHeader",slot:"SwitchViewIcon",overridesResolver:(e,t)=>t.switchViewIcon})(({theme:e})=>({willChange:"transform",transition:e.transitions.create("transform"),transform:"rotate(0deg)"})),gb=k.forwardRef(function(t,n){const o=rr(),r=Nt(),i=Mt({props:t,name:"MuiPickersCalendarHeader"}),{slots:a,slotProps:l,currentMonth:d,disabled:u,disableFuture:f,disablePast:p,maxDate:y,minDate:b,onMonthChange:w,onViewChange:g,view:v,reduceAnimations:E,views:P,labelId:x,className:S,timezone:C,format:O=`${r.formats.month} ${r.formats.year}`}=i,N=We(i,hj),F=i,z=pj(i),R=a?.switchViewButton??vj,$=dt({elementType:R,externalSlotProps:l?.switchViewButton,additionalProps:{size:"small","aria-label":o.calendarViewSwitchingButtonAriaLabel(v)},ownerState:F,className:z.switchViewButton}),K=a?.switchViewIcon??bj,X=dt({elementType:K,externalSlotProps:l?.switchViewIcon,ownerState:F,className:z.switchViewIcon}),q=We(X,fj),Y=()=>w(r.addMonths(d,1),"left"),H=()=>w(r.addMonths(d,-1),"right"),le=dj(d,{disableFuture:f,maxDate:y,timezone:C}),A=uj(d,{disablePast:p,minDate:b,timezone:C}),M=()=>{if(!(P.length===1||!g||u))if(P.length===2)g(P.find(B=>B!==v)||P[0]);else{const B=P.indexOf(v)!==0?0:1;g(P[B])}};if(P.length===1&&P[0]==="year")return null;const V=r.formatByString(d,O);return D.jsxs(mj,Z({},N,{ownerState:F,className:Se(z.root,S),ref:n,children:[D.jsxs(gj,{role:"presentation",onClick:M,ownerState:F,"aria-live":"polite",className:z.labelContainer,children:[D.jsx(cb,{reduceAnimations:E,transKey:V,children:D.jsx(yj,{id:x,ownerState:F,className:z.label,children:V})}),P.length>1&&!u&&D.jsx(R,Z({},$,{children:D.jsx(K,Z({},q))}))]}),D.jsx(Wr,{in:v==="day",children:D.jsx(cj,{slots:a,slotProps:l,onGoToPrevious:H,isPreviousDisabled:A,previousLabel:o.previousMonth,onGoToNext:Y,isNextDisabled:le,nextLabel:o.nextMonth})})]}))});process.env.NODE_ENV!=="production"&&(gb.propTypes={classes:s.object,className:s.string,currentMonth:s.object.isRequired,disabled:s.bool,disableFuture:s.bool,disablePast:s.bool,format:s.string,labelId:s.string,maxDate:s.object.isRequired,minDate:s.object.isRequired,onMonthChange:s.func.isRequired,onViewChange:s.func,reduceAnimations:s.bool.isRequired,slotProps:s.object,slots:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),timezone:s.string.isRequired,view:s.oneOf(["day","month","year"]).isRequired,views:s.arrayOf(s.oneOf(["day","month","year"]).isRequired).isRequired});const wj=ae("div")({overflow:"hidden",width:Cc,maxHeight:Ch,display:"flex",flexDirection:"column",margin:"0 auto"}),Cj=e=>Oe("MuiDateCalendar",e);De("MuiDateCalendar",["root","viewTransitionContainer"]);const Sj=["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"],_j=e=>{const{classes:t}=e;return Me({root:["root"],viewTransitionContainer:["viewTransitionContainer"]},Cj,t)};function xj(e,t){const n=Nt(),o=ya(),r=Gv(),i=Mt({props:e,name:t});return Z({},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??r,renderLoading:i.renderLoading??(()=>D.jsx("span",{children:"..."})),minDate:Xn(n,i.minDate,o.minDate),maxDate:Xn(n,i.maxDate,o.maxDate)})}const Rj=ae(wj,{name:"MuiDateCalendar",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"flex",flexDirection:"column",height:Ch}),kj=ae(cb,{name:"MuiDateCalendar",slot:"ViewTransitionContainer",overridesResolver:(e,t)=>t.viewTransitionContainer})({}),yb=k.forwardRef(function(t,n){const o=Nt(),r=yr(),i=xj(t,"MuiDateCalendar"),{autoFocus:a,onViewChange:l,value:d,defaultValue:u,referenceDate:f,disableFuture:p,disablePast:y,onChange:b,onYearChange:w,onMonthChange:g,reduceAnimations:v,shouldDisableDate:E,shouldDisableMonth:P,shouldDisableYear:x,view:S,views:C,openTo:O,className:N,disabled:F,readOnly:z,minDate:R,maxDate:$,disableHighlightToday:K,focusedView:X,onFocusedViewChange:q,showDaysOutsideCurrentMonth:Y,fixedWeekNumber:H,dayOfWeekFormatter:le,slots:A,slotProps:M,loading:V,renderLoading:B,displayWeekNumber:ne,yearsOrder:oe,yearsPerRow:se,monthsPerRow:j,timezone:J}=i,ee=We(i,Sj),{value:te,handleValueChange:ce,timezone:ie}=wh({name:"DateCalendar",timezone:J,value:d,defaultValue:u,onChange:b,valueManager:Po}),{view:he,setView:W,focusedView:re,setFocusedView:Q,goToNextView:fe,setValueAndGoToNextView:me}=Kv({view:S,views:C,openTo:O,onChange:ce,onViewChange:l,autoFocus:a,focusedView:X,onFocusedViewChange:q}),{referenceDate:Ce,calendarState:ve,changeFocusedDay:xe,changeMonth:Ve,handleChangeMonth:Ae,isDateDisabled:st,onMonthSwitchingAnimationEnd:Pe}=nV({value:te,referenceDate:f,reduceAnimations:v,onMonthChange:g,minDate:R,maxDate:$,shouldDisableDate:E,disablePast:y,disableFuture:p,timezone:ie}),ft=F&&te||R,Kt=F&&te||$,it=`${r}-grid-label`,Yt=re!==null,Xt=A?.calendarHeader??gb,on=dt({elementType:Xt,externalSlotProps:M?.calendarHeader,additionalProps:{views:C,view:he,currentMonth:ve.currentMonth,onViewChange:W,onMonthChange:(pt,Qt)=>Ae({newMonth:pt,direction:Qt}),minDate:ft,maxDate:Kt,disabled:F,disablePast:y,disableFuture:p,reduceAnimations:v,timezone:ie,labelId:it},ownerState:i}),Ue=ke(pt=>{const Qt=o.startOfMonth(pt),vn=o.endOfMonth(pt),Jt=st(pt)?Ei({utils:o,date:pt,minDate:o.isBefore(R,Qt)?Qt:R,maxDate:o.isAfter($,vn)?vn:$,disablePast:y,disableFuture:p,isDateDisabled:st,timezone:ie}):pt;Jt?(me(Jt,"finish"),g?.(Qt)):(fe(),Ve(Qt)),xe(Jt,!0)}),tt=ke(pt=>{const Qt=o.startOfYear(pt),vn=o.endOfYear(pt),Jt=st(pt)?Ei({utils:o,date:pt,minDate:o.isBefore(R,Qt)?Qt:R,maxDate:o.isAfter($,vn)?vn:$,disablePast:y,disableFuture:p,isDateDisabled:st,timezone:ie}):pt;Jt?(me(Jt,"finish"),w?.(Jt)):(fe(),Ve(Qt)),xe(Jt,!0)}),Mn=ke(pt=>ce(pt&&Tl(o,pt,te??Ce),"finish",he));k.useEffect(()=>{te!=null&&o.isValid(te)&&Ve(te)},[te]);const hn=i,Ie=_j(hn),He={disablePast:y,disableFuture:p,maxDate:$,minDate:R},vt={disableHighlightToday:K,readOnly:z,disabled:F,timezone:ie,gridLabelId:it,slots:A,slotProps:M},ln=k.useRef(he);k.useEffect(()=>{ln.current!==he&&(re===ln.current&&Q(he,!0),ln.current=he)},[re,Q,he]);const ho=k.useMemo(()=>[te],[te]);return D.jsxs(Rj,Z({ref:n,className:Se(Ie.root,N),ownerState:hn},ee,{children:[D.jsx(Xt,Z({},on,{slots:A,slotProps:M})),D.jsx(kj,{reduceAnimations:v,className:Ie.viewTransitionContainer,transKey:he,ownerState:hn,children:D.jsxs("div",{children:[he==="year"&&D.jsx(mb,Z({},He,vt,{value:te,onChange:tt,shouldDisableYear:x,hasFocus:Yt,onFocusedViewChange:pt=>Q("year",pt),yearsOrder:oe,yearsPerRow:se,referenceDate:Ce})),he==="month"&&D.jsx(pb,Z({},He,vt,{hasFocus:Yt,className:N,value:te,onChange:Ue,shouldDisableMonth:P,onFocusedViewChange:pt=>Q("month",pt),monthsPerRow:j,referenceDate:Ce})),he==="day"&&D.jsx(OV,Z({},ve,He,vt,{onMonthSwitchingAnimationEnd:Pe,onFocusedDayChange:xe,reduceAnimations:v,selectedDays:ho,onSelectedDaysChange:Mn,shouldDisableDate:E,shouldDisableMonth:P,shouldDisableYear:x,hasFocus:Yt,onFocusedViewChange:pt=>Q("day",pt),showDaysOutsideCurrentMonth:Y,fixedWeekNumber:H,dayOfWeekFormatter:le,displayWeekNumber:ne,loading:V,renderLoading:B}))]})})]}))});process.env.NODE_ENV!=="production"&&(yb.propTypes={autoFocus:s.bool,classes:s.object,className:s.string,dayOfWeekFormatter:s.func,defaultValue:s.object,disabled:s.bool,disableFuture:s.bool,disableHighlightToday:s.bool,disablePast:s.bool,displayWeekNumber:s.bool,fixedWeekNumber:s.number,focusedView:s.oneOf(["day","month","year"]),loading:s.bool,maxDate:s.object,minDate:s.object,monthsPerRow:s.oneOf([3,4]),onChange:s.func,onFocusedViewChange:s.func,onMonthChange:s.func,onViewChange:s.func,onYearChange:s.func,openTo:s.oneOf(["day","month","year"]),readOnly:s.bool,reduceAnimations:s.bool,referenceDate:s.object,renderLoading:s.func,shouldDisableDate:s.func,shouldDisableMonth:s.func,shouldDisableYear:s.func,showDaysOutsideCurrentMonth:s.bool,slotProps:s.object,slots:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),timezone:s.string,value:s.object,view:s.oneOf(["day","month","year"]),views:s.arrayOf(s.oneOf(["day","month","year"]).isRequired),yearsOrder:s.oneOf(["asc","desc"]),yearsPerRow:s.oneOf([3,4])});const xs=({view:e,onViewChange:t,views:n,focusedView:o,onFocusedViewChange:r,value:i,defaultValue:a,referenceDate:l,onChange:d,className:u,classes:f,disableFuture:p,disablePast:y,minDate:b,maxDate:w,shouldDisableDate:g,shouldDisableMonth:v,shouldDisableYear:E,reduceAnimations:P,onMonthChange:x,monthsPerRow:S,onYearChange:C,yearsOrder:O,yearsPerRow:N,slots:F,slotProps:z,loading:R,renderLoading:$,disableHighlightToday:K,readOnly:X,disabled:q,showDaysOutsideCurrentMonth:Y,dayOfWeekFormatter:H,sx:le,autoFocus:A,fixedWeekNumber:M,displayWeekNumber:V,timezone:B})=>D.jsx(yb,{view:e,onViewChange:t,views:n.filter(mm),focusedView:o&&mm(o)?o:null,onFocusedViewChange:r,value:i,defaultValue:a,referenceDate:l,onChange:d,className:u,classes:f,disableFuture:p,disablePast:y,minDate:b,maxDate:w,shouldDisableDate:g,shouldDisableMonth:v,shouldDisableYear:E,reduceAnimations:P,onMonthChange:x,monthsPerRow:S,onYearChange:C,yearsOrder:O,yearsPerRow:N,slots:F,slotProps:z,loading:R,renderLoading:$,disableHighlightToday:K,readOnly:X,disabled:q,showDaysOutsideCurrentMonth:Y,dayOfWeekFormatter:H,sx:le,autoFocus:A,fixedWeekNumber:M,displayWeekNumber:V,timezone:B}),vb=k.forwardRef(function(t,n){const o=rr(),r=Nt(),i=zv(t,"MuiDesktopDatePicker"),a=Z({day:xs,month:xs,year:xs},i.viewRenderers),l=Z({},i,{viewRenderers:a,format:mh(r,i,!1),yearsPerRow:i.yearsPerRow??4,slots:Z({openPickerIcon:GL,field:Th},i.slots),slotProps:Z({},i.slotProps,{field:u=>Z({},Ul(i.slotProps?.field,u),Uv(i),{ref:n}),toolbar:Z({hidden:!0},i.slotProps?.toolbar)})}),{renderPicker:d}=zL({props:l,valueManager:Po,valueType:"date",getOpenDialogAriaText:Bv({utils:r,formatKey:"fullDate",contextTranslation:o.openDatePickerDialogue,propsTranslation:l.localeText?.openDatePickerDialogue}),validator:va});return d()});vb.propTypes={autoFocus:s.bool,className:s.string,closeOnSelect:s.bool,dayOfWeekFormatter:s.func,defaultValue:s.object,disabled:s.bool,disableFuture:s.bool,disableHighlightToday:s.bool,disableOpenPicker:s.bool,disablePast:s.bool,displayWeekNumber:s.bool,enableAccessibleFieldDOMStructure:s.any,fixedWeekNumber:s.number,format:s.string,formatDensity:s.oneOf(["dense","spacious"]),inputRef:Bt,label:s.node,loading:s.bool,localeText:s.object,maxDate:s.object,minDate:s.object,monthsPerRow:s.oneOf([3,4]),name:s.string,onAccept:s.func,onChange:s.func,onClose:s.func,onError:s.func,onMonthChange:s.func,onOpen:s.func,onSelectedSectionsChange:s.func,onViewChange:s.func,onYearChange:s.func,open:s.bool,openTo:s.oneOf(["day","month","year"]),orientation:s.oneOf(["landscape","portrait"]),readOnly:s.bool,reduceAnimations:s.bool,referenceDate:s.object,renderLoading:s.func,selectedSections:s.oneOfType([s.oneOf(["all","day","empty","hours","meridiem","minutes","month","seconds","weekDay","year"]),s.number]),shouldDisableDate:s.func,shouldDisableMonth:s.func,shouldDisableYear:s.func,showDaysOutsideCurrentMonth:s.bool,slotProps:s.object,slots:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),timezone:s.string,value:s.object,view:s.oneOf(["day","month","year"]),viewRenderers:s.shape({day:s.func,month:s.func,year:s.func}),views:s.arrayOf(s.oneOf(["day","month","year"]).isRequired),yearsOrder:s.oneOf(["asc","desc"]),yearsPerRow:s.oneOf([3,4])};const Tj=ae(iy)({[`& .${Ri.container}`]:{outline:0},[`& .${Ri.paper}`]:{outline:0,minWidth:Cc}}),Ej=ae(ly)({"&:first-of-type":{padding:0}});function Pj(e){const{children:t,onDismiss:n,open:o,slots:r,slotProps:i}=e,a=r?.dialog??Tj,l=r?.mobileTransition??Wr;return D.jsx(a,Z({open:o,onClose:n},i?.dialog,{TransitionComponent:l,TransitionProps:i?.mobileTransition,PaperComponent:r?.mobilePaper,PaperProps:i?.mobilePaper,children:D.jsx(Ej,{children:t})}))}const Dj=["props","getOpenDialogAriaText"],Oj=e=>{let{props:t,getOpenDialogAriaText:n}=e,o=We(e,Dj);const{slots:r,slotProps:i,className:a,sx:l,format:d,formatDensity:u,enableAccessibleFieldDOMStructure:f,selectedSections:p,onSelectedSectionsChange:y,timezone:b,name:w,label:g,inputRef:v,readOnly:E,disabled:P,localeText:x}=t,S=k.useRef(null),C=yr(),O=i?.toolbar?.hidden??!1,{open:N,actions:F,layoutProps:z,renderCurrentView:R,fieldProps:$,contextValue:K}=Xv(Z({},o,{props:t,fieldRef:S,autoFocusView:!0,additionalViewProps:{},wrapperVariant:"mobile"})),X=r.field,q=dt({elementType:X,externalSlotProps:i?.field,additionalProps:Z({},$,O&&{id:C},!(P||E)&&{onClick:F.onOpen,onKeyDown:aL(F.onOpen)},{readOnly:E??!0,disabled:P,className:a,sx:l,format:d,formatDensity:u,enableAccessibleFieldDOMStructure:f,selectedSections:p,onSelectedSectionsChange:y,timezone:b,label:g,name:w},v?{inputRef:v}:{}),ownerState:t});q.inputProps=Z({},q.inputProps,{"aria-label":n($.value)});const Y=Z({textField:r.textField},q.slots),H=r.layout??Sh;let le=C;O&&(g?le=`${C}-label`:le=void 0);const A=Z({},i,{toolbar:Z({},i?.toolbar,{titleId:C}),mobilePaper:Z({"aria-labelledby":le},i?.mobilePaper)}),M=at(S,q.unstableFieldRef);return{renderPicker:()=>D.jsxs(eb,{contextValue:K,localeText:x,children:[D.jsx(X,Z({},q,{slots:Y,slotProps:A,unstableFieldRef:M})),D.jsx(Pj,Z({},F,{open:N,slots:r,slotProps:A,children:D.jsx(H,Z({},z,A?.layout,{slots:r,slotProps:A,children:R()}))}))]})}},bb=k.forwardRef(function(t,n){const o=rr(),r=Nt(),i=zv(t,"MuiMobileDatePicker"),a=Z({day:xs,month:xs,year:xs},i.viewRenderers),l=Z({},i,{viewRenderers:a,format:mh(r,i,!1),slots:Z({field:Th},i.slots),slotProps:Z({},i.slotProps,{field:u=>Z({},Ul(i.slotProps?.field,u),Uv(i),{ref:n}),toolbar:Z({hidden:!1},i.slotProps?.toolbar)})}),{renderPicker:d}=Oj({props:l,valueManager:Po,valueType:"date",getOpenDialogAriaText:Bv({utils:r,formatKey:"fullDate",contextTranslation:o.openDatePickerDialogue,propsTranslation:l.localeText?.openDatePickerDialogue}),validator:va});return d()});bb.propTypes={autoFocus:s.bool,className:s.string,closeOnSelect:s.bool,dayOfWeekFormatter:s.func,defaultValue:s.object,disabled:s.bool,disableFuture:s.bool,disableHighlightToday:s.bool,disableOpenPicker:s.bool,disablePast:s.bool,displayWeekNumber:s.bool,enableAccessibleFieldDOMStructure:s.any,fixedWeekNumber:s.number,format:s.string,formatDensity:s.oneOf(["dense","spacious"]),inputRef:Bt,label:s.node,loading:s.bool,localeText:s.object,maxDate:s.object,minDate:s.object,monthsPerRow:s.oneOf([3,4]),name:s.string,onAccept:s.func,onChange:s.func,onClose:s.func,onError:s.func,onMonthChange:s.func,onOpen:s.func,onSelectedSectionsChange:s.func,onViewChange:s.func,onYearChange:s.func,open:s.bool,openTo:s.oneOf(["day","month","year"]),orientation:s.oneOf(["landscape","portrait"]),readOnly:s.bool,reduceAnimations:s.bool,referenceDate:s.object,renderLoading:s.func,selectedSections:s.oneOfType([s.oneOf(["all","day","empty","hours","meridiem","minutes","month","seconds","weekDay","year"]),s.number]),shouldDisableDate:s.func,shouldDisableMonth:s.func,shouldDisableYear:s.func,showDaysOutsideCurrentMonth:s.bool,slotProps:s.object,slots:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),timezone:s.string,value:s.object,view:s.oneOf(["day","month","year"]),viewRenderers:s.shape({day:s.func,month:s.func,year:s.func}),views:s.arrayOf(s.oneOf(["day","month","year"]).isRequired),yearsOrder:s.oneOf(["asc","desc"]),yearsPerRow:s.oneOf([3,4])};const Mj=["desktopModeMediaQuery"],Pl=k.forwardRef(function(t,n){const o=Mt({props:t,name:"MuiDatePicker"}),{desktopModeMediaQuery:r=lL}=o,i=We(o,Mj);return mg(r,{defaultMatches:!0})?D.jsx(vb,Z({ref:n},i)):D.jsx(bb,Z({ref:n},i))});process.env.NODE_ENV!=="production"&&(Pl.propTypes={autoFocus:s.bool,className:s.string,closeOnSelect:s.bool,dayOfWeekFormatter:s.func,defaultValue:s.object,desktopModeMediaQuery:s.string,disabled:s.bool,disableFuture:s.bool,disableHighlightToday:s.bool,disableOpenPicker:s.bool,disablePast:s.bool,displayWeekNumber:s.bool,enableAccessibleFieldDOMStructure:s.any,fixedWeekNumber:s.number,format:s.string,formatDensity:s.oneOf(["dense","spacious"]),inputRef:Bt,label:s.node,loading:s.bool,localeText:s.object,maxDate:s.object,minDate:s.object,monthsPerRow:s.oneOf([3,4]),name:s.string,onAccept:s.func,onChange:s.func,onClose:s.func,onError:s.func,onMonthChange:s.func,onOpen:s.func,onSelectedSectionsChange:s.func,onViewChange:s.func,onYearChange:s.func,open:s.bool,openTo:s.oneOf(["day","month","year"]),orientation:s.oneOf(["landscape","portrait"]),readOnly:s.bool,reduceAnimations:s.bool,referenceDate:s.object,renderLoading:s.func,selectedSections:s.oneOfType([s.oneOf(["all","day","empty","hours","meridiem","minutes","month","seconds","weekDay","year"]),s.number]),shouldDisableDate:s.func,shouldDisableMonth:s.func,shouldDisableYear:s.func,showDaysOutsideCurrentMonth:s.bool,slotProps:s.object,slots:s.object,sx:s.oneOfType([s.arrayOf(s.oneOfType([s.func,s.object,s.bool])),s.func,s.object]),timezone:s.string,value:s.object,view:s.oneOf(["day","month","year"]),viewRenderers:s.shape({day:s.func,month:s.func,year:s.func}),views:s.arrayOf(s.oneOf(["day","month","year"]).isRequired),yearsOrder:s.oneOf(["asc","desc"]),yearsPerRow:s.oneOf([3,4])});const ru=ae(Do)({"& label[data-shrink=false]":{top:"-5px",fontSize:"14px"},"& .MuiOutlinedInput-root":{height:"40px"}}),Ij=({setValue:e,value:t})=>{function n(r){const i=r?.format(jr.db)||"",a={...t,1:i===Jd?Is[1]:i};e(a),tr(a)}function o(r){const i=r?.format(jr.db)||"",a={...t,2:i===Jd?Is[2]:i};e(a),tr(a)}return D.jsxs(vc,{dateAdapter:Nv,children:[D.jsx(ru,{children:D.jsx(Pl,{label:oo.from,onChange:n,...nu(t[1])})}),D.jsx(ru,{children:D.jsx(Pl,{label:oo.to,onChange:o,...nu(t[2])})})]})},kd=({label:e,setValue:t,value:n})=>{function o(r){const i=r?.format(jr.db)||"",a={...n,1:i===Jd?Is[1]:i};t(a),tr(a)}return D.jsx(vc,{dateAdapter:Nv,children:D.jsx(ru,{children:D.jsx(Pl,{label:e,onChange:o,...nu(n[1])})})})},Om={label:"",options:[]};function Nj(){const{columnId:e,table:t}=wn,n=t?.grid;if(!n)return Om;const o=n?.getColumns().find(({id:p})=>p===e);if(!o)return Om;const r=o.name,i=[],{formatter:a,id:l}=o,d=n.getData(),u=new Set;d.getItems().forEach(p=>{u.add(a?a(0,0,p[l],o,null,n):p[l])});for(const p of u)i.push(p);return{label:r,options:i}}function Aj(e,t){return typeof e=="string"&&typeof t=="string"?e.localeCompare(t):typeof e=="number"&&typeof t=="number"?e-t:0}const Fj=ae(tc)({padding:0}),Mm={Checkbox:Fj},Lj=({setValue:e,value:t})=>{const n=JSON.parse(t[1]||'["All"]'),{label:o,options:r}=Nj(),i=a=>{const l=a.target.value;let d;l[l.length-1]==="All"||!l.length?d={1:"",2:""}:(l.length>1&&l[0]==="All"&&l.shift(),d={...t,1:JSON.stringify(l)}),e(d),tr(d)};return D.jsxs(ca,{size:"small",children:[D.jsx(da,{id:"column-filter-multiple-select-label",children:o}),D.jsxs(ua,{labelId:"column-filter-multiple-select-label",id:"column-filter-multiple-select",multiple:!0,value:n,onChange:i,input:D.jsx(Os,{label:o}),renderValue:a=>a.join(", "),children:[D.jsxs(bl,{value:"All",children:[D.jsx(Mm.Checkbox,{checked:n.indexOf("All")>-1}),D.jsx(Wd,{primary:"All"})]},0),r.sort(Aj).map(a=>D.jsxs(bl,{value:a,children:[D.jsx(Mm.Checkbox,{checked:n.indexOf(a)>-1}),D.jsx(Wd,{primary:a})]},a))]})]})},$j=({setValue:e,value:t})=>{function n(r){const i={...t,1:r.target.value};e(i),tr(i)}function o(r){const i={...t,2:r.target.value};e(i),tr(i)}return D.jsxs($e.Fragment,{children:[D.jsx(Ms,{label:oo.from,value:t[1],type:"number",onChange:n,size:"small",autoComplete:"off"}),D.jsx(Ms,{label:oo.to,value:t[2],type:"number",onChange:o,size:"small",autoComplete:"off"})]})},Td=({label:e,setValue:t,value:n})=>{function o(r){const i={...n,1:r.target.value};t(i),tr(i)}return D.jsx(Ms,{label:e,value:n[1],type:"number",onChange:o,size:"small",autoComplete:"off"})},Ka=({setValue:e,value:t})=>{function n(o){const r={...t,1:o.target.value};e(r),tr(r)}return D.jsx(Ms,{label:oo.filter,value:t[1],onChange:n,size:"small",autoComplete:"off"})},Vj=({filterId:e,setValue:t,value:n})=>D.jsxs($e.Fragment,{children:[e===je.Boolean&&D.jsx(pF,{setValue:t,value:n}),e===je.TextEqual&&D.jsx(Ka,{setValue:t,value:n}),e===je.TextNotEqual&&D.jsx(Ka,{setValue:t,value:n}),e===je.TextContain&&D.jsx(Ka,{setValue:t,value:n}),e===je.TextNotContain&&D.jsx(Ka,{setValue:t,value:n}),e===je.MultipleSelect&&D.jsx(Lj,{setValue:t,value:n}),e===je.NumberEqual&&D.jsx(Td,{label:oo.filter,setValue:t,value:n}),e===je.NumberFrom&&D.jsx(Td,{label:oo.from,setValue:t,value:n}),e===je.NumberTo&&D.jsx(Td,{label:oo.to,setValue:t,value:n}),e===je.NumberBetween&&D.jsx($j,{setValue:t,value:n}),e===je.DateEqual&&D.jsx(kd,{label:oo.filter,setValue:t,value:n}),e===je.DateFrom&&D.jsx(kd,{label:oo.from,setValue:t,value:n}),e===je.DateTo&&D.jsx(kd,{label:oo.to,setValue:t,value:n}),e===je.DateBetween&&D.jsx(Ij,{setValue:t,value:n})]}),jj=ae(bl)({fontSize:"12px"}),Im={MenuItem:jj},Bj=({name:e,list:t,onChange:n,defaultValue:o,value:r,showSelect:i=!0,dataTestId:a,width:l="12.8em",height:d,disabled:u=!1})=>D.jsxs(ca,{variant:"outlined",size:"small",children:[D.jsx(da,{id:"reportType",children:e}),D.jsxs(ua,{labelId:"reportType",id:e,label:e,autoWidth:!0,value:`${r??(o||0)}`,defaultValue:`${o||0}`,onChange:n,disabled:u,"data-testid":a,MenuProps:{anchorOrigin:{vertical:"bottom",horizontal:"left"},transformOrigin:{vertical:"top",horizontal:"left"},disableScrollLock:!0},sx:{height:d,width:l},children:[i&&D.jsx(Im.MenuItem,{value:0,id:"Select",children:"Select"}),t.map((f,p)=>D.jsx(Im.MenuItem,{value:f.id,id:"selectedReport",disabled:f.isDisabled,children:f.labelForSelect||f.name},p))]})]}),Wj={id:je.DateBetween,name:"Between"},Hj={id:je.DateEqual,name:"Equal"},zj={id:je.DateFrom,name:"From"},Yj={id:je.DateTo,name:"To"},Uj={id:je.NumberBetween,name:"Between"},qj={id:je.NumberEqual,name:"Equal"},Gj={id:je.NumberFrom,name:"From"},Kj={id:je.NumberTo,name:"To"},Xj={id:je.TextContain,name:"Contains"},Zj={id:je.TextEqual,name:"Equal"},Qj={id:je.TextNotContain,name:"Does not contain"},Jj={id:je.TextNotEqual,name:"Not equal"},Nm=[qj,Gj,Kj,Uj],eB={[sn.Boolean]:[],[sn.Date]:[Hj,zj,Yj,Wj],[sn.MultipleSelect]:[],[sn.Number]:Nm,[sn.NumberFormatted]:Nm,[sn.Text]:[Xj,Qj,Zj,Jj]},tB=({filterId:e,setFilterId:t})=>{const n=eB[wn.group],o=n.some(({id:i})=>i===e)?e:n[0]?.id;function r(i){const{columnId:a,table:l}=wn;if(!a||!l)return;const d=l.filter.args,u=i.target.value;d.columnFilters&&(l.filter.args={...d,columnFilters:{...d.columnFilters,[a]:{...d.columnFilters[a],filterId:u}}},t(u))}return o?D.jsx(Bj,{name:"",list:n,onChange:r,width:"100%",showSelect:!1,value:o}):null},nB=ae(Do)({display:"flex",flexDirection:"column",rowGap:"0.5em",width:"12em"}),oB={Wrapper:nB},rB=()=>{const[e,t]=$e.useState(Is),[n,o]=$e.useState(je.TextContain),[r,i]=$e.useState(!1);return lF(i),aF(r,o,t),r?D.jsxs($e.Fragment,{children:[D.jsx(ju,{setIsOpened:i}),D.jsx(Bu,{id:Iv,children:D.jsxs(oB.Wrapper,{children:[D.jsx(tB,{filterId:n,setFilterId:o}),D.jsx(Vj,{filterId:n,setValue:t,value:e}),D.jsx(uF,{setIsOpened:i,setValue:t,value:e})]})})]}):null},wb="context_menu";function sB(e){$e.useEffect(()=>{function t(){e(!0),setTimeout(()=>{const n=document.getElementById(wb);if(!n)return;const{x:o,y:r}=Cn;Vu(n,o,r)},0)}return Cn.subscribe(t),()=>{Cn.unsubscribe(t)}},[])}const iB=ae("ul")({display:"flex",flexDirection:"column",rowGap:"0.5em",margin:"0",paddingLeft:"0.5em"}),aB=ae("li")({display:"flex",alignItems:"center",columnGap:"0.5em",cursor:"pointer","&:hover":{scale:"1.05"}}),lB=ae("span")({backgroundColor:"#1E456F"}),un={Ul:iB,Li:aB,Icon:lB},cB=({clientId:e,clientName:t,setIsOpened:n})=>{const o=()=>{const r=Cn.table,i=r?.grid;if(!r||!i){n(!1);return}r.downloadManager.download(r,e,t),n(!1)};return D.jsxs(un.Li,{onClick:o,children:[D.jsx(un.Icon,{className:"sgi sgi-download"}),"Download as CSV"]})},dB=({setIsOpened:e})=>{const t=Cn.table;function n(){t&&(t.grouping={isGrouped:!0},e(!1))}return t?.grouping.isGrouped!==!1?null:D.jsxs(un.Li,{onClick:n,children:[D.jsx(un.Icon,{className:"sgi sgi-link"}),"Group"]})};function uB(e){return e?Object.values(e.filter.args.columnFilters||{}).some(({value:t})=>t[1]||t[2]):!1}const hB=({setIsOpened:e})=>{const t=Cn.table;function n(){if(!t){e(!1);return}const o=t.filter.args;delete o.columnFilters,t.filter.args=o,er.highlightAllColumns(o,t.id),e(!1)}return uB(t)?D.jsxs($e.Fragment,{children:[D.jsx(vl,{}),D.jsxs(un.Li,{onClick:n,children:[D.jsx(un.Icon,{className:"sgi sgi-notification-clear-all"}),"Reset column filters"]})]}):null},fB=({setIsOpened:e})=>{const t=Cn.table;function n(){t&&(t.grouping={isGrouped:!1},e(!1))}return t?.grouping.isGrouped?D.jsxs(un.Li,{onClick:n,children:[D.jsx(un.Icon,{className:"sgi sgi-link-off"}),"Ungroup"]}):null},pB=({setIsOpened:e})=>{const t=Cn.table;function n(){const o=t?.grid;if(!o)return;o.getData().collapseAllGroups(),e(!1)}return t?.grouping.isGrouped?D.jsxs(un.Li,{onClick:n,children:[D.jsx(un.Icon,{className:"sgi sgi-collapse-all-outline"}),"Collapse all groups"]}):null},mB=({setIsOpened:e})=>{function t(){const n=Cn.table,o=n?.grid;if(!o||!n){e(!1);return}window.navigator.clipboard.writeText(n.downloadManager.createCSV(n)).then(()=>{}).catch(()=>{}),o.getSelectionModel()&&o.setSelectedRows([]),e(!1)}return D.jsxs(un.Li,{onClick:t,children:[D.jsx(un.Icon,{className:"sgi sgi-content-copy"}),"Copy to clipboard"]})},gB=({setIsOpened:e})=>{const t=Cn.table;function n(){const o=t?.grid;if(!o)return;o.getData().expandAllGroups(),e(!1)}return t?.grouping.isGrouped?D.jsxs(un.Li,{onClick:n,children:[D.jsx(un.Icon,{className:"sgi sgi-expand-all-outline"}),"Expand all groups"]}):null},yB=({clientId:e,clientName:t,setIsOpened:n})=>{function o(){const r=Cn.table;r?.printer.print(r,e,t),n(!1)}return D.jsxs(un.Li,{onClick:o,children:[D.jsx(un.Icon,{className:"sgi sgi-printer"}),"Print"]})},vB=({clientId:e,clientName:t})=>{const[n,o]=$e.useState(!1);return sB(o),n?D.jsxs($e.Fragment,{children:[D.jsx(ju,{setIsOpened:o}),D.jsx(Bu,{id:wb,children:D.jsxs(un.Ul,{children:[D.jsx(yB,{clientId:e,clientName:t,setIsOpened:o}),D.jsx(mB,{setIsOpened:o}),D.jsx(cB,{clientId:e,clientName:t,setIsOpened:o}),D.jsx(hB,{setIsOpened:o}),D.jsx(fB,{setIsOpened:o}),D.jsx(dB,{setIsOpened:o}),D.jsx(gB,{setIsOpened:o}),D.jsx(pB,{setIsOpened:o})]})})]}):null},Cb="header_context_menu";function bB(e){$e.useEffect(()=>{function t(){e(!0),setTimeout(()=>{const n=document.getElementById(Cb);if(!n)return;const{x:o,y:r}=so;Vu(n,o,r)},0)}return so.subscribe(t),()=>{so.unsubscribe(t)}},[])}function Eh(e){const t=so.table;if(!t?.columnPicker)return;t.columnPicker.visibleColumnIds=[...e];const n=t.grid;if(!n)return;n.setColumns(t.columnPicker.initialColumns.filter(({id:r})=>e.includes(r)));const o=t.filter.args;t.filter.register(n,t.id),er.highlightAllColumns(o,t.id),t.totalCalculator?.calculate(n)}const wB=({setChecked:e})=>{function t(){const n=so.table;if(!n?.columnPicker)return;const o=n.columnPicker.initialColumns.map(({id:r})=>r);e(o),Eh(o)}return D.jsx(Ho,{onClick:t,size:"small",sx:{textTransform:"none"},variant:"contained",children:"Check all"})},CB=({checked:e,setChecked:t})=>{function n(){const o=e.filter(r=>r==="_checkbox_selector"||r==="isEdited");t(o),Eh(o)}return D.jsx(Ho,{onClick:n,size:"small",sx:{textTransform:"none"},variant:"contained",children:"Uncheck all"})},SB=ae(Ho)({display:"flex",alignItems:"center",justifyContent:"flex-start",columnGap:"0.5em",textTransform:"none",color:"#1E456F",padding:"0"}),_B=ae(tc)({padding:0}),Am={Checkbox:_B,Button:SB},xB=({checked:e,columnId:t,columnName:n,setChecked:o})=>{function r(){const i=e.indexOf(t),a=[...e];~i?a.splice(i,1):a.push(t),o(a),Eh(a)}return D.jsxs(Am.Button,{onClick:r,children:[D.jsx(Am.Checkbox,{checked:e.includes(t),size:"small"}),D.jsx(Do,{children:n})]})},RB=ae(Do)({color:"#1e456f",marginBottom:"0.5em"}),kB={Wrapper:RB},TB=()=>D.jsx(kB.Wrapper,{children:"Columns"}),EB=ae(Do)({columnGap:"0.5em",display:"flex",justifyContent:"flex-end",marginTop:"0.5em"}),PB=ae(Do)({maxHeight:"20em",overflowY:"auto"}),Fm={ButtonsGroup:EB,ItemsGroup:PB},DB=()=>{const[e,t]=$e.useState([]),[n,o]=$e.useState(!1);if(bB(o),$e.useEffect(()=>{if(!n)return;const i=so.table;i?.columnPicker&&t([...i.columnPicker.visibleColumnIds])},[n]),!n)return null;const r=so.table;return r?.columnPicker?D.jsxs($e.Fragment,{children:[D.jsx(ju,{setIsOpened:o}),D.jsxs(Bu,{id:Cb,children:[D.jsx(TB,{}),D.jsx(Fm.ItemsGroup,{children:r.columnPicker.initialColumns.filter(({id:i})=>i!=="_checkbox_selector"&&i!=="isEdited").map(({id:i,name:a})=>D.jsx($e.Fragment,{children:D.jsx(xB,{checked:e,columnId:i,columnName:a,setChecked:t})},i))}),D.jsxs(Fm.ButtonsGroup,{children:[D.jsx(wB,{setChecked:t}),D.jsx(CB,{checked:e,setChecked:t})]})]})]}):null};exports.Autocomplete=YA;exports.ColumnFilters=rB;exports.ColumnPicker=rD;exports.ColumnSorter=Mv;exports.ContextMenu=vB;exports.DecoratorColumnFilter=SA;exports.DecoratorFilter=yv;exports.DefaultHotKeys=aD;exports.DefaultPrinter=Rv;exports.DeletedRowsFilter=fN;exports.EColumnFiltersGroup=sn;exports.ESortType=yo;exports.Filter=gv;exports.HeaderContextMenu=DB;exports.HotKeysDecorator=Wu;exports.PreventCopying=cD;exports.RedoUndoOnly=dD;exports.Skeleton=X1;exports.SlickTable=EA;exports.SlickgridTable=mA;exports.TotalCalculator=rF;exports.columnCheckboxSelector=gA;exports.columnIsEdited=vA;exports.commitCurrentEdit=fh;exports.copySelectedRows=Pv;exports.formatterGroupTotals=QA;exports.getDisplayedRows=mc;exports.getNextId=kl;exports.handleHeaderButtons=vv;exports.headerButtons=er;exports.openColumnFilter=mN;exports.openContextMenu=Dv;exports.useListenIfTablesWereEdited=VA;
|