@nebula.js/sn-tabbed-container 1.1.4 → 2.0.1
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/api-specification/spec.json +1 -1
- package/core/esm/index.js +2 -2
- package/dist/sn-tabbed-container.js +2 -2
- package/dist/sn-tabbed-container.systemjs.js +3 -3
- package/package.json +7 -7
- package/sn-tabbed-container-ext/dist/sn-tabbed-container.js +2 -2
- package/sn-tabbed-container-ext/sn-tabbed-container.qext +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* @nebula.js/sn-tabbed-container
|
|
2
|
+
* @nebula.js/sn-tabbed-container v2.0.1
|
|
3
3
|
* Copyright (c) 2025 QlikTech International AB
|
|
4
4
|
* Released under the MIT license.
|
|
5
5
|
*/
|
|
@@ -105,4 +105,4 @@
|
|
|
105
105
|
}
|
|
106
106
|
`),yy.rippleVisible,Ry,550,(({theme:e})=>e.transitions.easing.easeInOut),yy.ripplePulsate,(({theme:e})=>e.transitions.duration.shorter),yy.child,yy.childLeaving,_y,550,(({theme:e})=>e.transitions.easing.easeInOut),yy.childPulsate,Ty,(({theme:e})=>e.transitions.easing.easeInOut)),Ay=Y.forwardRef((function(e,t){const n=$l({props:e,name:"MuiTouchRipple"}),{center:r=!1,classes:o={},className:i}=n,a=s(n,xy),[u,c]=Y.useState([]),d=Y.useRef(0),p=Y.useRef(null);Y.useEffect((()=>{p.current&&(p.current(),p.current=null)}),[u]);const f=Y.useRef(!1),h=Bo(),m=Y.useRef(null),g=Y.useRef(null),b=Y.useCallback((e=>{const{pulsate:t,rippleX:n,rippleY:r,rippleSize:i,cb:a}=e;c((e=>[...e,vn.jsx(Py,{classes:{ripple:Wr(o.ripple,yy.ripple),rippleVisible:Wr(o.rippleVisible,yy.rippleVisible),ripplePulsate:Wr(o.ripplePulsate,yy.ripplePulsate),child:Wr(o.child,yy.child),childLeaving:Wr(o.childLeaving,yy.childLeaving),childPulsate:Wr(o.childPulsate,yy.childPulsate)},timeout:550,pulsate:t,rippleX:n,rippleY:r,rippleSize:i},d.current)])),d.current+=1,p.current=a}),[o]),v=Y.useCallback(((e={},t={},n=()=>{})=>{const{pulsate:o=!1,center:i=r||t.pulsate,fakeElement:a=!1}=t;if("mousedown"===(null==e?void 0:e.type)&&f.current)return void(f.current=!1);"touchstart"===(null==e?void 0:e.type)&&(f.current=!0);const l=a?null:g.current,s=l?l.getBoundingClientRect():{width:0,height:0,left:0,top:0};let u,c,d;if(i||void 0===e||0===e.clientX&&0===e.clientY||!e.clientX&&!e.touches)u=Math.round(s.width/2),c=Math.round(s.height/2);else{const{clientX:t,clientY:n}=e.touches&&e.touches.length>0?e.touches[0]:e;u=Math.round(t-s.left),c=Math.round(n-s.top)}if(i)d=Math.sqrt((2*s.width**2+s.height**2)/3),d%2==0&&(d+=1);else{const e=2*Math.max(Math.abs((l?l.clientWidth:0)-u),u)+2,t=2*Math.max(Math.abs((l?l.clientHeight:0)-c),c)+2;d=Math.sqrt(e**2+t**2)}null!=e&&e.touches?null===m.current&&(m.current=()=>{b({pulsate:o,rippleX:u,rippleY:c,rippleSize:d,cb:n})},h.start(80,(()=>{m.current&&(m.current(),m.current=null)}))):b({pulsate:o,rippleX:u,rippleY:c,rippleSize:d,cb:n})}),[r,b,h]),y=Y.useCallback((()=>{v({},{pulsate:!0})}),[v]),x=Y.useCallback(((e,t)=>{if(h.clear(),"touchend"===(null==e?void 0:e.type)&&m.current)return m.current(),m.current=null,void h.start(0,(()=>{x(e,t)}));m.current=null,c((e=>e.length>0?e.slice(1):e)),p.current=t}),[h]);return Y.useImperativeHandle(t,(()=>({pulsate:y,start:v,stop:x})),[y,v,x]),vn.jsx(Ly,l({className:Wr(yy.root,o.root,i),ref:g},a,{children:vn.jsx(py,{component:null,exit:!0,children:u})}))}));function Iy(e){return Kr("MuiButtonBase",e)}const Oy=Xr("MuiButtonBase",["root","disabled","focusVisible"]),My=["action","centerRipple","children","className","component","disabled","disableRipple","disableTouchRipple","focusRipple","focusVisibleClassName","LinkComponent","onBlur","onClick","onContextMenu","onDragLeave","onFocus","onFocusVisible","onKeyDown","onKeyUp","onMouseDown","onMouseLeave","onMouseUp","onTouchEnd","onTouchMove","onTouchStart","tabIndex","TouchRippleProps","touchRippleRef","type"],Ny=wl("button",{name:"MuiButtonBase",slot:"Root",overridesResolver:(e,t)=>t.root})({display:"inline-flex",alignItems:"center",justifyContent:"center",position:"relative",boxSizing:"border-box",WebkitTapHighlightColor:"transparent",backgroundColor:"transparent",outline:0,border:0,margin:0,borderRadius:0,padding:0,cursor:"pointer",userSelect:"none",verticalAlign:"middle",MozAppearance:"none",WebkitAppearance:"none",textDecoration:"none",color:"inherit","&::-moz-focus-inner":{borderStyle:"none"},[`&.${Oy.disabled}`]:{pointerEvents:"none",cursor:"default"},"@media print":{colorAdjust:"exact"}}),zy=Y.forwardRef((function(e,t){const n=$l({props:e,name:"MuiButtonBase"}),{action:r,centerRipple:o=!1,children:i,className:a,component:u="button",disabled:c=!1,disableRipple:d=!1,disableTouchRipple:p=!1,focusRipple:f=!1,LinkComponent:h="a",onBlur:m,onClick:g,onContextMenu:b,onDragLeave:v,onFocus:y,onFocusVisible:x,onKeyDown:E,onKeyUp:S,onMouseDown:w,onMouseLeave:C,onMouseUp:k,onTouchEnd:R,onTouchMove:_,onTouchStart:T,tabIndex:L=0,TouchRippleProps:P,touchRippleRef:A,type:I}=n,O=s(n,My),M=Y.useRef(null),N=Y.useRef(null),z=zo(N,A),{isFocusVisibleRef:j,onFocus:$,onBlur:D,ref:B}=Ko(),[F,H]=Y.useState(!1);c&&F&&H(!1),Y.useImperativeHandle(r,(()=>({focusVisible:()=>{H(!0),M.current.focus()}})),[]);const[U,V]=Y.useState(!1);Y.useEffect((()=>{V(!0)}),[]);const G=U&&!d&&!c;function W(e,t,n=p){return No((r=>{t&&t(r);return!n&&N.current&&N.current[e](r),!0}))}Y.useEffect((()=>{F&&f&&!d&&U&&N.current.pulsate()}),[d,f,F,U]);const q=W("start",w),K=W("stop",b),X=W("stop",v),Q=W("stop",k),Z=W("stop",(e=>{F&&e.preventDefault(),C&&C(e)})),J=W("start",T),ee=W("stop",R),te=W("stop",_),ne=W("stop",(e=>{D(e),!1===j.current&&H(!1),m&&m(e)}),!1),re=No((e=>{M.current||(M.current=e.currentTarget),$(e),!0===j.current&&(H(!0),x&&x(e)),y&&y(e)})),oe=()=>{const e=M.current;return u&&"button"!==u&&!("A"===e.tagName&&e.href)},ie=Y.useRef(!1),ae=No((e=>{f&&!ie.current&&F&&N.current&&" "===e.key&&(ie.current=!0,N.current.stop(e,(()=>{N.current.start(e)}))),e.target===e.currentTarget&&oe()&&" "===e.key&&e.preventDefault(),E&&E(e),e.target===e.currentTarget&&oe()&&"Enter"===e.key&&!c&&(e.preventDefault(),g&&g(e))})),le=No((e=>{f&&" "===e.key&&N.current&&F&&!e.defaultPrevented&&(ie.current=!1,N.current.stop(e,(()=>{N.current.pulsate(e)}))),S&&S(e),g&&e.target===e.currentTarget&&oe()&&" "===e.key&&!e.defaultPrevented&&g(e)}));let se=u;"button"===se&&(O.href||O.to)&&(se=h);const ue={};"button"===se?(ue.type=void 0===I?"button":I,ue.disabled=c):(O.href||O.to||(ue.role="button"),c&&(ue["aria-disabled"]=c));const ce=zo(t,B,M),de=l({},n,{centerRipple:o,component:u,disabled:c,disableRipple:d,disableTouchRipple:p,focusRipple:f,tabIndex:L,focusVisible:F}),pe=(e=>{const{disabled:t,focusVisible:n,focusVisibleClassName:r,classes:o}=e,i=ei({root:["root",t&&"disabled",n&&"focusVisible"]},Iy,o);return n&&r&&(i.root+=` ${r}`),i})(de);return vn.jsxs(Ny,l({as:se,className:Wr(pe.root,a),ownerState:de,onBlur:ne,onClick:g,onContextMenu:K,onFocus:re,onKeyDown:ae,onKeyUp:le,onMouseDown:q,onMouseLeave:Z,onMouseUp:Q,onDragLeave:X,onTouchEnd:ee,onTouchMove:te,onTouchStart:J,ref:ce,tabIndex:c?-1:L,type:I},ue,O,{children:[i,G?vn.jsx(Ay,l({ref:z,center:o},P)):null]}))}));function jy(e){return Kr("MuiTypography",e)}Xr("MuiTypography",["root","h1","h2","h3","h4","h5","h6","subtitle1","subtitle2","body1","body2","inherit","button","caption","overline","alignLeft","alignRight","alignCenter","alignJustify","noWrap","gutterBottom","paragraph"]);const $y=["align","className","component","gutterBottom","noWrap","paragraph","variant","variantMapping"],Dy=wl("span",{name:"MuiTypography",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.variant&&t[n.variant],"inherit"!==n.align&&t[`align${jn(n.align)}`],n.noWrap&&t.noWrap,n.gutterBottom&&t.gutterBottom,n.paragraph&&t.paragraph]}})((({theme:e,ownerState:t})=>l({margin:0},"inherit"===t.variant&&{font:"inherit"},"inherit"!==t.variant&&e.typography[t.variant],"inherit"!==t.align&&{textAlign:t.align},t.noWrap&&{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},t.gutterBottom&&{marginBottom:"0.35em"},t.paragraph&&{marginBottom:16}))),By={h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",subtitle1:"h6",subtitle2:"h6",body1:"p",body2:"p",inherit:"p"},Fy={primary:"primary.main",textPrimary:"text.primary",secondary:"secondary.main",textSecondary:"text.secondary",error:"error.main"},Hy=Y.forwardRef((function(e,t){const n=$l({props:e,name:"MuiTypography"}),r=(e=>Fy[e]||e)(n.color),o=Fr(l({},n,{color:r})),{align:i="inherit",className:a,component:u,gutterBottom:c=!1,noWrap:d=!1,paragraph:p=!1,variant:f="body1",variantMapping:h=By}=o,m=s(o,$y),g=l({},o,{align:i,color:r,className:a,component:u,gutterBottom:c,noWrap:d,paragraph:p,variant:f,variantMapping:h}),b=u||(p?"p":h[f]||By[f])||"span",v=(e=>{const{align:t,gutterBottom:n,noWrap:r,paragraph:o,variant:i,classes:a}=e;return ei({root:["root",i,"inherit"!==e.align&&`align${jn(t)}`,n&&"gutterBottom",r&&"noWrap",o&&"paragraph"]},jy,a)})(g);return vn.jsx(Dy,l({as:b,ref:t,ownerState:g,className:Wr(v.root,a)},m))}));const Uy=Y.forwardRef((function(e,t){const{children:n,container:r,disablePortal:o=!1}=e,[i,a]=Y.useState(null),l=zo(Y.isValidElement(n)?ai(n):null,t);if(So((()=>{o||a(function(e){return"function"==typeof e?e():e}(r)||document.body)}),[r,o]),So((()=>{if(i&&!o)return Ao(t,i),()=>{Ao(t,null)}}),[t,i,o]),o){if(Y.isValidElement(n)){const e={ref:l};return Y.cloneElement(n,e)}return vn.jsx(Y.Fragment,{children:n})}return vn.jsx(Y.Fragment,{children:i?Qv.createPortal(n,i):i})})),Vy=["onChange","maxRows","minRows","style","value"];function Gy(e){return parseInt(e,10)||0}const Wy={visibility:"hidden",position:"absolute",overflow:"hidden",height:0,top:0,left:0,transform:"translateZ(0)"};function Yy(e){return function(e){for(const t in e)return!1;return!0}(e)||0===e.outerHeightStyle&&!e.overflowing}const qy=Y.forwardRef((function(e,t){const{onChange:n,maxRows:r,minRows:o=1,style:i,value:a}=e,u=s(e,Vy),{current:c}=Y.useRef(null!=a),d=Y.useRef(null),p=zo(t,d),f=Y.useRef(null),h=Y.useRef(null),m=Y.useCallback((()=>{const t=d.current,n=h.current;if(!t||!n)return;const i=Po(t).getComputedStyle(t);if("0px"===i.width)return{outerHeightStyle:0,overflowing:!1};n.style.width=i.width,n.value=t.value||e.placeholder||"x","\n"===n.value.slice(-1)&&(n.value+=" ");const a=i.boxSizing,l=Gy(i.paddingBottom)+Gy(i.paddingTop),s=Gy(i.borderBottomWidth)+Gy(i.borderTopWidth),u=n.scrollHeight;n.value="x";const c=n.scrollHeight;let p=u;o&&(p=Math.max(Number(o)*c,p)),r&&(p=Math.min(Number(r)*c,p)),p=Math.max(p,c);return{outerHeightStyle:p+("border-box"===a?l+s:0),overflowing:Math.abs(p-u)<=1}}),[r,o,e.placeholder]),g=No((()=>{const e=d.current,t=m();if(!e||!t||Yy(t))return!1;const n=t.outerHeightStyle;return null!=f.current&&f.current!==n})),b=Y.useCallback((()=>{const e=d.current,t=m();if(!e||!t||Yy(t))return;const n=t.outerHeightStyle;f.current!==n&&(f.current=n,e.style.height=`${n}px`),e.style.overflow=t.overflowing?"hidden":""}),[m]),v=Y.useRef(-1);So((()=>{const e=To(b),t=null==d?void 0:d.current;if(!t)return;const n=Po(t);let r;return n.addEventListener("resize",e),"undefined"!=typeof ResizeObserver&&(r=new ResizeObserver((()=>{g()&&(r.unobserve(t),cancelAnimationFrame(v.current),b(),v.current=requestAnimationFrame((()=>{r.observe(t)})))})),r.observe(t)),()=>{e.clear(),cancelAnimationFrame(v.current),n.removeEventListener("resize",e),r&&r.disconnect()}}),[m,b,g]),So((()=>{b()}));return vn.jsxs(Y.Fragment,{children:[vn.jsx("textarea",l({value:a,onChange:e=>{c||b(),n&&n(e)},ref:p,rows:o,style:i},u)),vn.jsx("textarea",{"aria-hidden":!0,className:e.className,readOnly:!0,ref:h,tabIndex:-1,style:l({},Wy,i,{paddingTop:0,paddingBottom:0})})]})}));const Ky=Y.createContext(void 0);function Xy(){return Y.useContext(Ky)}function Qy(e){return vn.jsx(Dr,l({},e,{defaultTheme:Va,themeId:a}))}function Zy(e){return null!=e&&!(Array.isArray(e)&&0===e.length)}function Jy(e){return Kr("MuiInputBase",e)}const ex=Xr("MuiInputBase",["root","formControl","focused","disabled","adornedStart","adornedEnd","error","sizeSmall","multiline","colorSecondary","fullWidth","hiddenLabel","readOnly","input","inputSizeSmall","inputMultiline","inputTypeSearch","inputAdornedStart","inputAdornedEnd","inputHiddenLabel"]),tx=["aria-describedby","autoComplete","autoFocus","className","color","components","componentsProps","defaultValue","disabled","disableInjectingGlobalStyles","endAdornment","error","fullWidth","id","inputComponent","inputProps","inputRef","margin","maxRows","minRows","multiline","name","onBlur","onChange","onClick","onFocus","onKeyDown","onKeyUp","placeholder","readOnly","renderSuffix","rows","size","slotProps","slots","startAdornment","type","value"],nx=wl("div",{name:"MuiInputBase",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.formControl&&t.formControl,n.startAdornment&&t.adornedStart,n.endAdornment&&t.adornedEnd,n.error&&t.error,"small"===n.size&&t.sizeSmall,n.multiline&&t.multiline,n.color&&t[`color${jn(n.color)}`],n.fullWidth&&t.fullWidth,n.hiddenLabel&&t.hiddenLabel]}})((({theme:e,ownerState:t})=>l({},e.typography.body1,{color:(e.vars||e).palette.text.primary,lineHeight:"1.4375em",boxSizing:"border-box",position:"relative",cursor:"text",display:"inline-flex",alignItems:"center",[`&.${ex.disabled}`]:{color:(e.vars||e).palette.text.disabled,cursor:"default"}},t.multiline&&l({padding:"4px 0 5px"},"small"===t.size&&{paddingTop:1}),t.fullWidth&&{width:"100%"}))),rx=wl("input",{name:"MuiInputBase",slot:"Input",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.input,"small"===n.size&&t.inputSizeSmall,n.multiline&&t.inputMultiline,"search"===n.type&&t.inputTypeSearch,n.startAdornment&&t.inputAdornedStart,n.endAdornment&&t.inputAdornedEnd,n.hiddenLabel&&t.inputHiddenLabel]}})((({theme:e,ownerState:t})=>{const n="light"===e.palette.mode,r=l({color:"currentColor"},e.vars?{opacity:e.vars.opacity.inputPlaceholder}:{opacity:n?.42:.5},{transition:e.transitions.create("opacity",{duration:e.transitions.duration.shorter})}),o={opacity:"0 !important"},i=e.vars?{opacity:e.vars.opacity.inputPlaceholder}:{opacity:n?.42:.5};return l({font:"inherit",letterSpacing:"inherit",color:"currentColor",padding:"4px 0 5px",border:0,boxSizing:"content-box",background:"none",height:"1.4375em",margin:0,WebkitTapHighlightColor:"transparent",display:"block",minWidth:0,width:"100%",animationName:"mui-auto-fill-cancel",animationDuration:"10ms","&::-webkit-input-placeholder":r,"&::-moz-placeholder":r,"&:-ms-input-placeholder":r,"&::-ms-input-placeholder":r,"&:focus":{outline:0},"&:invalid":{boxShadow:"none"},"&::-webkit-search-decoration":{WebkitAppearance:"none"},[`label[data-shrink=false] + .${ex.formControl} &`]:{"&::-webkit-input-placeholder":o,"&::-moz-placeholder":o,"&:-ms-input-placeholder":o,"&::-ms-input-placeholder":o,"&:focus::-webkit-input-placeholder":i,"&:focus::-moz-placeholder":i,"&:focus:-ms-input-placeholder":i,"&:focus::-ms-input-placeholder":i},[`&.${ex.disabled}`]:{opacity:1,WebkitTextFillColor:(e.vars||e).palette.text.disabled},"&:-webkit-autofill":{animationDuration:"5000s",animationName:"mui-auto-fill"}},"small"===t.size&&{paddingTop:1},t.multiline&&{height:"auto",resize:"none",padding:0,paddingTop:0},"search"===t.type&&{MozAppearance:"textfield"})})),ox=vn.jsx(Qy,{styles:{"@keyframes mui-auto-fill":{from:{display:"block"}},"@keyframes mui-auto-fill-cancel":{from:{display:"block"}}}}),ix=Y.forwardRef((function(e,t){var n;const r=$l({props:e,name:"MuiInputBase"}),{"aria-describedby":i,autoComplete:a,autoFocus:u,className:c,components:d={},componentsProps:p={},defaultValue:f,disabled:h,disableInjectingGlobalStyles:m,endAdornment:g,fullWidth:b=!1,id:v,inputComponent:y="input",inputProps:x={},inputRef:E,maxRows:S,minRows:w,multiline:C=!1,name:k,onBlur:R,onChange:_,onClick:T,onFocus:L,onKeyDown:P,onKeyUp:A,placeholder:I,readOnly:O,renderSuffix:M,rows:N,slotProps:z={},slots:j={},startAdornment:$,type:D="text",value:B}=r,F=s(r,tx),H=null!=x.value?x.value:B,{current:U}=Y.useRef(null!=H),V=Y.useRef(),G=Y.useCallback((e=>{}),[]),W=zo(V,E,x.ref,G),[q,K]=Y.useState(!1),X=Xy(),Q=function({props:e,states:t,muiFormControl:n}){return t.reduce(((t,r)=>(t[r]=e[r],n&&void 0===e[r]&&(t[r]=n[r]),t)),{})}({props:r,muiFormControl:X,states:["color","disabled","error","hiddenLabel","size","required","filled"]});Q.focused=X?X.focused:q,Y.useEffect((()=>{!X&&h&&q&&(K(!1),R&&R())}),[X,h,q,R]);const Z=X&&X.onFilled,J=X&&X.onEmpty,ee=Y.useCallback((e=>{!function(e,t=!1){return e&&(Zy(e.value)&&""!==e.value||t&&Zy(e.defaultValue)&&""!==e.defaultValue)}(e)?J&&J():Z&&Z()}),[Z,J]);So((()=>{U&&ee({value:H})}),[H,ee,U]);Y.useEffect((()=>{ee(V.current)}),[]);let te=y,ne=x;C&&"input"===te&&(ne=l(N?{type:void 0,minRows:N,maxRows:N}:{type:void 0,maxRows:S,minRows:w},ne),te=qy);Y.useEffect((()=>{X&&X.setAdornedStart(Boolean($))}),[X,$]);const re=l({},r,{color:Q.color||"primary",disabled:Q.disabled,endAdornment:g,error:Q.error,focused:Q.focused,formControl:X,fullWidth:b,hiddenLabel:Q.hiddenLabel,multiline:C,size:Q.size,startAdornment:$,type:D}),oe=(e=>{const{classes:t,color:n,disabled:r,error:o,endAdornment:i,focused:a,formControl:l,fullWidth:s,hiddenLabel:u,multiline:c,readOnly:d,size:p,startAdornment:f,type:h}=e;return ei({root:["root",`color${jn(n)}`,r&&"disabled",o&&"error",s&&"fullWidth",a&&"focused",l&&"formControl",p&&"medium"!==p&&`size${jn(p)}`,c&&"multiline",f&&"adornedStart",i&&"adornedEnd",u&&"hiddenLabel",d&&"readOnly"],input:["input",r&&"disabled","search"===h&&"inputTypeSearch",c&&"inputMultiline","small"===p&&"inputSizeSmall",u&&"inputHiddenLabel",f&&"inputAdornedStart",i&&"inputAdornedEnd",d&&"readOnly"]},Jy,t)})(re),ie=j.root||d.Root||nx,ae=z.root||p.root||{},le=j.input||d.Input||rx;return ne=l({},ne,null!=(n=z.input)?n:p.input),vn.jsxs(Y.Fragment,{children:[!m&&ox,vn.jsxs(ie,l({},ae,!ti(ie)&&{ownerState:l({},re,ae.ownerState)},{ref:t,onClick:e=>{V.current&&e.currentTarget===e.target&&V.current.focus(),T&&T(e)}},F,{className:Wr(oe.root,ae.className,c,O&&"MuiInputBase-readOnly"),children:[$,vn.jsx(Ky.Provider,{value:null,children:vn.jsx(le,l({ownerState:re,"aria-invalid":Q.error,"aria-describedby":i,autoComplete:a,autoFocus:u,defaultValue:f,disabled:Q.disabled,id:v,onAnimationStart:e=>{ee("mui-auto-fill-cancel"===e.animationName?V.current:{value:"x"})},name:k,placeholder:I,readOnly:O,required:Q.required,rows:N,value:H,onKeyDown:P,onKeyUp:A,type:D},ne,!ti(le)&&{as:te,ownerState:l({},re,ne.ownerState)},{ref:W,className:Wr(oe.input,ne.className,O&&"MuiInputBase-readOnly"),onBlur:e=>{R&&R(e),x.onBlur&&x.onBlur(e),X&&X.onBlur?X.onBlur(e):K(!1)},onChange:(e,...t)=>{if(!U){const t=e.target||V.current;if(null==t)throw new Error(o(1));ee({value:t.value})}x.onChange&&x.onChange(e,...t),_&&_(e,...t)},onFocus:e=>{Q.disabled?e.stopPropagation():(L&&L(e),x.onFocus&&x.onFocus(e),X&&X.onFocus?X.onFocus(e):K(!0))}}))}),g,M?M(l({},Q,{startAdornment:$})):null]}))]})})),ax=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"],lx={entering:{opacity:1},entered:{opacity:1}},sx=Y.forwardRef((function(e,t){const n=Ga(),r={enter:n.transitions.duration.enteringScreen,exit:n.transitions.duration.leavingScreen},{addEndListener:o,appear:i=!0,children:a,easing:u,in:c,onEnter:d,onEntered:p,onEntering:f,onExit:h,onExited:m,onExiting:g,style:b,timeout:v=r,TransitionComponent:y=ay}=e,x=s(e,ax),E=Y.useRef(null),S=zo(E,ai(a),t),w=e=>t=>{if(e){const n=E.current;void 0===t?e(n):e(n,t)}},C=w(f),k=w(((e,t)=>{fy(e);const r=hy({style:b,timeout:v,easing:u},{mode:"enter"});e.style.webkitTransition=n.transitions.create("opacity",r),e.style.transition=n.transitions.create("opacity",r),d&&d(e,t)})),R=w(p),_=w(g),T=w((e=>{const t=hy({style:b,timeout:v,easing:u},{mode:"exit"});e.style.webkitTransition=n.transitions.create("opacity",t),e.style.transition=n.transitions.create("opacity",t),h&&h(e)})),L=w(m);return vn.jsx(y,l({appear:i,in:c,nodeRef:E,onEnter:k,onEntered:R,onEntering:C,onExit:T,onExited:L,onExiting:_,addEndListener:e=>{o&&o(E.current,e)},timeout:v},x,{children:(e,t)=>Y.cloneElement(a,l({style:l({opacity:0,visibility:"exited"!==e||c?void 0:"hidden"},lx[e],b,a.props.style),ref:S},t))}))}));function ux(e){return Kr("MuiBackdrop",e)}Xr("MuiBackdrop",["root","invisible"]);const cx=["children","className","component","components","componentsProps","invisible","open","slotProps","slots","TransitionComponent","transitionDuration"],dx=wl("div",{name:"MuiBackdrop",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.invisible&&t.invisible]}})((({ownerState:e})=>l({position:"fixed",display:"flex",alignItems:"center",justifyContent:"center",right:0,bottom:0,top:0,left:0,backgroundColor:"rgba(0, 0, 0, 0.5)",WebkitTapHighlightColor:"transparent"},e.invisible&&{backgroundColor:"transparent"}))),px=Y.forwardRef((function(e,t){var n,r,o;const i=$l({props:e,name:"MuiBackdrop"}),{children:a,className:u,component:c="div",components:d={},componentsProps:p={},invisible:f=!1,open:h,slotProps:m={},slots:g={},TransitionComponent:b=sx,transitionDuration:v}=i,y=s(i,cx),x=l({},i,{component:c,invisible:f}),E=(e=>{const{classes:t,invisible:n}=e;return ei({root:["root",n&&"invisible"]},ux,t)})(x),S=null!=(n=m.root)?n:p.root;return vn.jsx(b,l({in:h,timeout:v},y,{children:vn.jsx(dx,l({"aria-hidden":!0},S,{as:null!=(r=null!=(o=g.root)?o:d.Root)?r:c,className:Wr(E.root,u,null==S?void 0:S.className),ownerState:l({},x,null==S?void 0:S.ownerState),classes:E,ref:t,children:a}))}))})),fx=Xr("MuiBox",["root"]),hx=Ua(),mx=function(e={}){const{themeId:t,defaultTheme:n,defaultClassName:r="MuiBox-root",generateClassName:o}=e,i=En("div",{shouldForwardProp:e=>"theme"!==e&&"sx"!==e&&"as"!==e})(Pr);return Y.forwardRef((function(e,a){const u=jr(n),c=Fr(e),{className:d,component:p="div"}=c,f=s(c,Yr);return vn.jsx(i,l({as:p,ref:a,className:Wr(d,o?o(r):r),theme:t&&u[t]||u},f))}))}({themeId:a,defaultTheme:hx,defaultClassName:fx.root,generateClassName:Vr.generate});function gx(e){return Kr("MuiButton",e)}const bx=Xr("MuiButton",["root","text","textInherit","textPrimary","textSecondary","textSuccess","textError","textInfo","textWarning","outlined","outlinedInherit","outlinedPrimary","outlinedSecondary","outlinedSuccess","outlinedError","outlinedInfo","outlinedWarning","contained","containedInherit","containedPrimary","containedSecondary","containedSuccess","containedError","containedInfo","containedWarning","disableElevation","focusVisible","disabled","colorInherit","colorPrimary","colorSecondary","colorSuccess","colorError","colorInfo","colorWarning","textSizeSmall","textSizeMedium","textSizeLarge","outlinedSizeSmall","outlinedSizeMedium","outlinedSizeLarge","containedSizeSmall","containedSizeMedium","containedSizeLarge","sizeMedium","sizeSmall","sizeLarge","fullWidth","startIcon","endIcon","icon","iconSizeSmall","iconSizeMedium","iconSizeLarge"]),vx=Y.createContext({}),yx=Y.createContext(void 0),xx=["children","color","component","className","disabled","disableElevation","disableFocusRipple","endIcon","focusVisibleClassName","fullWidth","size","startIcon","type","variant"],Ex=e=>l({},"small"===e.size&&{"& > *:nth-of-type(1)":{fontSize:18}},"medium"===e.size&&{"& > *:nth-of-type(1)":{fontSize:20}},"large"===e.size&&{"& > *:nth-of-type(1)":{fontSize:22}}),Sx=wl(zy,{shouldForwardProp:e=>Sl(e)||"classes"===e,name:"MuiButton",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[n.variant],t[`${n.variant}${jn(n.color)}`],t[`size${jn(n.size)}`],t[`${n.variant}Size${jn(n.size)}`],"inherit"===n.color&&t.colorInherit,n.disableElevation&&t.disableElevation,n.fullWidth&&t.fullWidth]}})((({theme:e,ownerState:t})=>{var n,r;const o="light"===e.palette.mode?e.palette.grey[300]:e.palette.grey[800],i="light"===e.palette.mode?e.palette.grey.A100:e.palette.grey[700];return l({},e.typography.button,{minWidth:64,padding:"6px 16px",borderRadius:(e.vars||e).shape.borderRadius,transition:e.transitions.create(["background-color","box-shadow","border-color","color"],{duration:e.transitions.duration.short}),"&:hover":l({textDecoration:"none",backgroundColor:e.vars?`rgba(${e.vars.palette.text.primaryChannel} / ${e.vars.palette.action.hoverOpacity})`:_i(e.palette.text.primary,e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}},"text"===t.variant&&"inherit"!==t.color&&{backgroundColor:e.vars?`rgba(${e.vars.palette[t.color].mainChannel} / ${e.vars.palette.action.hoverOpacity})`:_i(e.palette[t.color].main,e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}},"outlined"===t.variant&&"inherit"!==t.color&&{border:`1px solid ${(e.vars||e).palette[t.color].main}`,backgroundColor:e.vars?`rgba(${e.vars.palette[t.color].mainChannel} / ${e.vars.palette.action.hoverOpacity})`:_i(e.palette[t.color].main,e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}},"contained"===t.variant&&{backgroundColor:e.vars?e.vars.palette.Button.inheritContainedHoverBg:i,boxShadow:(e.vars||e).shadows[4],"@media (hover: none)":{boxShadow:(e.vars||e).shadows[2],backgroundColor:(e.vars||e).palette.grey[300]}},"contained"===t.variant&&"inherit"!==t.color&&{backgroundColor:(e.vars||e).palette[t.color].dark,"@media (hover: none)":{backgroundColor:(e.vars||e).palette[t.color].main}}),"&:active":l({},"contained"===t.variant&&{boxShadow:(e.vars||e).shadows[8]}),[`&.${bx.focusVisible}`]:l({},"contained"===t.variant&&{boxShadow:(e.vars||e).shadows[6]}),[`&.${bx.disabled}`]:l({color:(e.vars||e).palette.action.disabled},"outlined"===t.variant&&{border:`1px solid ${(e.vars||e).palette.action.disabledBackground}`},"contained"===t.variant&&{color:(e.vars||e).palette.action.disabled,boxShadow:(e.vars||e).shadows[0],backgroundColor:(e.vars||e).palette.action.disabledBackground})},"text"===t.variant&&{padding:"6px 8px"},"text"===t.variant&&"inherit"!==t.color&&{color:(e.vars||e).palette[t.color].main},"outlined"===t.variant&&{padding:"5px 15px",border:"1px solid currentColor"},"outlined"===t.variant&&"inherit"!==t.color&&{color:(e.vars||e).palette[t.color].main,border:e.vars?`1px solid rgba(${e.vars.palette[t.color].mainChannel} / 0.5)`:`1px solid ${_i(e.palette[t.color].main,.5)}`},"contained"===t.variant&&{color:e.vars?e.vars.palette.text.primary:null==(n=(r=e.palette).getContrastText)?void 0:n.call(r,e.palette.grey[300]),backgroundColor:e.vars?e.vars.palette.Button.inheritContainedBg:o,boxShadow:(e.vars||e).shadows[2]},"contained"===t.variant&&"inherit"!==t.color&&{color:(e.vars||e).palette[t.color].contrastText,backgroundColor:(e.vars||e).palette[t.color].main},"inherit"===t.color&&{color:"inherit",borderColor:"currentColor"},"small"===t.size&&"text"===t.variant&&{padding:"4px 5px",fontSize:e.typography.pxToRem(13)},"large"===t.size&&"text"===t.variant&&{padding:"8px 11px",fontSize:e.typography.pxToRem(15)},"small"===t.size&&"outlined"===t.variant&&{padding:"3px 9px",fontSize:e.typography.pxToRem(13)},"large"===t.size&&"outlined"===t.variant&&{padding:"7px 21px",fontSize:e.typography.pxToRem(15)},"small"===t.size&&"contained"===t.variant&&{padding:"4px 10px",fontSize:e.typography.pxToRem(13)},"large"===t.size&&"contained"===t.variant&&{padding:"8px 22px",fontSize:e.typography.pxToRem(15)},t.fullWidth&&{width:"100%"})}),(({ownerState:e})=>e.disableElevation&&{boxShadow:"none","&:hover":{boxShadow:"none"},[`&.${bx.focusVisible}`]:{boxShadow:"none"},"&:active":{boxShadow:"none"},[`&.${bx.disabled}`]:{boxShadow:"none"}})),wx=wl("span",{name:"MuiButton",slot:"StartIcon",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.startIcon,t[`iconSize${jn(n.size)}`]]}})((({ownerState:e})=>l({display:"inherit",marginRight:8,marginLeft:-4},"small"===e.size&&{marginLeft:-2},Ex(e)))),Cx=wl("span",{name:"MuiButton",slot:"EndIcon",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.endIcon,t[`iconSize${jn(n.size)}`]]}})((({ownerState:e})=>l({display:"inherit",marginRight:-4,marginLeft:8},"small"===e.size&&{marginRight:-2},Ex(e)))),kx=Y.forwardRef((function(e,t){const n=Y.useContext(vx),r=Y.useContext(yx),o=$l({props:Eo(n,e),name:"MuiButton"}),{children:i,color:a="primary",component:u="button",className:c,disabled:d=!1,disableElevation:p=!1,disableFocusRipple:f=!1,endIcon:h,focusVisibleClassName:m,fullWidth:g=!1,size:b="medium",startIcon:v,type:y,variant:x="text"}=o,E=s(o,xx),S=l({},o,{color:a,component:u,disabled:d,disableElevation:p,disableFocusRipple:f,fullWidth:g,size:b,type:y,variant:x}),w=(e=>{const{color:t,disableElevation:n,fullWidth:r,size:o,variant:i,classes:a}=e;return l({},a,ei({root:["root",i,`${i}${jn(t)}`,`size${jn(o)}`,`${i}Size${jn(o)}`,`color${jn(t)}`,n&&"disableElevation",r&&"fullWidth"],label:["label"],startIcon:["icon","startIcon",`iconSize${jn(o)}`],endIcon:["icon","endIcon",`iconSize${jn(o)}`]},gx,a))})(S),C=v&&vn.jsx(wx,{className:w.startIcon,ownerState:S,children:v}),k=h&&vn.jsx(Cx,{className:w.endIcon,ownerState:S,children:h}),R=r||"";return vn.jsxs(Sx,l({ownerState:S,className:Wr(n.className,w.root,c,R),component:u,disabled:d,focusRipple:!f,focusVisibleClassName:Wr(w.focusVisible,m),ref:t,type:y},E,{classes:w,children:[C,i,k]}))}));function Rx(e,t){t?e.setAttribute("aria-hidden","true"):e.removeAttribute("aria-hidden")}function _x(e){return parseInt(Po(e).getComputedStyle(e).paddingRight,10)||0}function Tx(e,t,n,r,o){const i=[t,n,...r];[].forEach.call(e.children,(e=>{const t=-1===i.indexOf(e),n=!function(e){const t=-1!==["TEMPLATE","SCRIPT","STYLE","LINK","MAP","META","NOSCRIPT","PICTURE","COL","COLGROUP","PARAM","SLOT","SOURCE","TRACK"].indexOf(e.tagName),n="INPUT"===e.tagName&&"hidden"===e.getAttribute("type");return t||n}(e);t&&n&&Rx(e,o)}))}function Lx(e,t){let n=-1;return e.some(((e,r)=>!!t(e)&&(n=r,!0))),n}function Px(e,t){const n=[],r=e.container;if(!t.disableScrollLock){if(function(e){const t=Lo(e);return t.body===e?Po(e).innerWidth>t.documentElement.clientWidth:e.scrollHeight>e.clientHeight}(r)){const e=Xo(Lo(r));n.push({value:r.style.paddingRight,property:"padding-right",el:r}),r.style.paddingRight=`${_x(r)+e}px`;const t=Lo(r).querySelectorAll(".mui-fixed");[].forEach.call(t,(t=>{n.push({value:t.style.paddingRight,property:"padding-right",el:t}),t.style.paddingRight=`${_x(t)+e}px`}))}let e;if(r.parentNode instanceof DocumentFragment)e=Lo(r).body;else{const t=r.parentElement,n=Po(r);e="HTML"===(null==t?void 0:t.nodeName)&&"scroll"===n.getComputedStyle(t).overflowY?t:r}n.push({value:e.style.overflow,property:"overflow",el:e},{value:e.style.overflowX,property:"overflow-x",el:e},{value:e.style.overflowY,property:"overflow-y",el:e}),e.style.overflow="hidden"}return()=>{n.forEach((({value:e,el:t,property:n})=>{e?t.style.setProperty(n,e):t.style.removeProperty(n)}))}}const Ax=["input","select","textarea","a[href]","button","[tabindex]","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'].join(",");function Ix(e){const t=[],n=[];return Array.from(e.querySelectorAll(Ax)).forEach(((e,r)=>{const o=function(e){const t=parseInt(e.getAttribute("tabindex")||"",10);return Number.isNaN(t)?"true"===e.contentEditable||("AUDIO"===e.nodeName||"VIDEO"===e.nodeName||"DETAILS"===e.nodeName)&&null===e.getAttribute("tabindex")?0:e.tabIndex:t}(e);-1!==o&&function(e){return!(e.disabled||"INPUT"===e.tagName&&"hidden"===e.type||function(e){if("INPUT"!==e.tagName||"radio"!==e.type)return!1;if(!e.name)return!1;const t=t=>e.ownerDocument.querySelector(`input[type="radio"]${t}`);let n=t(`[name="${e.name}"]:checked`);return n||(n=t(`[name="${e.name}"]`)),n!==e}(e))}(e)&&(0===o?t.push(e):n.push({documentOrder:r,tabIndex:o,node:e}))})),n.sort(((e,t)=>e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex)).map((e=>e.node)).concat(t)}function Ox(){return!0}function Mx(e){const{children:t,disableAutoFocus:n=!1,disableEnforceFocus:r=!1,disableRestoreFocus:o=!1,getTabbable:i=Ix,isEnabled:a=Ox,open:l}=e,s=Y.useRef(!1),u=Y.useRef(null),c=Y.useRef(null),d=Y.useRef(null),p=Y.useRef(null),f=Y.useRef(!1),h=Y.useRef(null),m=zo(ai(t),h),g=Y.useRef(null);Y.useEffect((()=>{l&&h.current&&(f.current=!n)}),[n,l]),Y.useEffect((()=>{if(!l||!h.current)return;const e=Lo(h.current);return h.current.contains(e.activeElement)||(h.current.hasAttribute("tabIndex")||h.current.setAttribute("tabIndex","-1"),f.current&&h.current.focus()),()=>{o||(d.current&&d.current.focus&&(s.current=!0,d.current.focus()),d.current=null)}}),[l]),Y.useEffect((()=>{if(!l||!h.current)return;const e=Lo(h.current),t=t=>{g.current=t,!r&&a()&&"Tab"===t.key&&e.activeElement===h.current&&t.shiftKey&&(s.current=!0,c.current&&c.current.focus())},n=()=>{const t=h.current;if(null===t)return;if(!e.hasFocus()||!a()||s.current)return void(s.current=!1);if(t.contains(e.activeElement))return;if(r&&e.activeElement!==u.current&&e.activeElement!==c.current)return;if(e.activeElement!==p.current)p.current=null;else if(null!==p.current)return;if(!f.current)return;let n=[];if(e.activeElement!==u.current&&e.activeElement!==c.current||(n=i(h.current)),n.length>0){var o,l;const e=Boolean((null==(o=g.current)?void 0:o.shiftKey)&&"Tab"===(null==(l=g.current)?void 0:l.key)),t=n[0],r=n[n.length-1];"string"!=typeof t&&"string"!=typeof r&&(e?r.focus():t.focus())}else t.focus()};e.addEventListener("focusin",n),e.addEventListener("keydown",t,!0);const o=setInterval((()=>{e.activeElement&&"BODY"===e.activeElement.tagName&&n()}),50);return()=>{clearInterval(o),e.removeEventListener("focusin",n),e.removeEventListener("keydown",t,!0)}}),[n,r,o,a,l,i]);const b=e=>{null===d.current&&(d.current=e.relatedTarget),f.current=!0};return vn.jsxs(Y.Fragment,{children:[vn.jsx("div",{tabIndex:l?0:-1,onFocus:b,ref:u,"data-testid":"sentinelStart"}),Y.cloneElement(t,{ref:m,onFocus:e=>{null===d.current&&(d.current=e.relatedTarget),f.current=!0,p.current=e.target;const n=t.props.onFocus;n&&n(e)}}),vn.jsx("div",{tabIndex:l?0:-1,onFocus:b,ref:c,"data-testid":"sentinelEnd"})]})}const Nx=new class{constructor(){this.containers=void 0,this.modals=void 0,this.modals=[],this.containers=[]}add(e,t){let n=this.modals.indexOf(e);if(-1!==n)return n;n=this.modals.length,this.modals.push(e),e.modalRef&&Rx(e.modalRef,!1);const r=function(e){const t=[];return[].forEach.call(e.children,(e=>{"true"===e.getAttribute("aria-hidden")&&t.push(e)})),t}(t);Tx(t,e.mount,e.modalRef,r,!0);const o=Lx(this.containers,(e=>e.container===t));return-1!==o?(this.containers[o].modals.push(e),n):(this.containers.push({modals:[e],container:t,restore:null,hiddenSiblings:r}),n)}mount(e,t){const n=Lx(this.containers,(t=>-1!==t.modals.indexOf(e))),r=this.containers[n];r.restore||(r.restore=Px(r,t))}remove(e,t=!0){const n=this.modals.indexOf(e);if(-1===n)return n;const r=Lx(this.containers,(t=>-1!==t.modals.indexOf(e))),o=this.containers[r];if(o.modals.splice(o.modals.indexOf(e),1),this.modals.splice(n,1),0===o.modals.length)o.restore&&o.restore(),e.modalRef&&Rx(e.modalRef,t),Tx(o.container,e.mount,e.modalRef,o.hiddenSiblings,!1),this.containers.splice(r,1);else{const e=o.modals[o.modals.length-1];e.modalRef&&Rx(e.modalRef,!1)}return n}isTopModal(e){return this.modals.length>0&&this.modals[this.modals.length-1]===e}};function zx(e){const{container:t,disableEscapeKeyDown:n=!1,disableScrollLock:r=!1,manager:o=Nx,closeAfterTransition:i=!1,onTransitionEnter:a,onTransitionExited:s,children:u,onClose:c,open:d,rootRef:p}=e,f=Y.useRef({}),h=Y.useRef(null),m=Y.useRef(null),g=zo(m,p),[b,v]=Y.useState(!d),y=function(e){return!!e&&e.props.hasOwnProperty("in")}(u);let x=!0;"false"!==e["aria-hidden"]&&!1!==e["aria-hidden"]||(x=!1);const E=()=>(f.current.modalRef=m.current,f.current.mount=h.current,f.current),S=()=>{o.mount(E(),{disableScrollLock:r}),m.current&&(m.current.scrollTop=0)},w=No((()=>{const e=function(e){return"function"==typeof e?e():e}(t)||Lo(h.current).body;o.add(E(),e),m.current&&S()})),C=Y.useCallback((()=>o.isTopModal(E())),[o]),k=No((e=>{h.current=e,e&&(d&&C()?S():m.current&&Rx(m.current,x))})),R=Y.useCallback((()=>{o.remove(E(),x)}),[x,o]);Y.useEffect((()=>()=>{R()}),[R]),Y.useEffect((()=>{d?w():y&&i||R()}),[d,R,y,i,w]);const _=e=>t=>{var r;null==(r=e.onKeyDown)||r.call(e,t),"Escape"===t.key&&229!==t.which&&C()&&(n||(t.stopPropagation(),c&&c(t,"escapeKeyDown")))},T=e=>t=>{var n;null==(n=e.onClick)||n.call(e,t),t.target===t.currentTarget&&c&&c(t,"backdropClick")};return{getRootProps:(t={})=>{const n=ni(e);delete n.onTransitionEnter,delete n.onTransitionExited;const r=l({},n,t);return l({role:"presentation"},r,{onKeyDown:_(r),ref:g})},getBackdropProps:(e={})=>l({"aria-hidden":!0},e,{onClick:T(e),open:d}),getTransitionProps:()=>({onEnter:_o((()=>{v(!1),a&&a()}),null==u?void 0:u.props.onEnter),onExited:_o((()=>{v(!0),s&&s(),i&&R()}),null==u?void 0:u.props.onExited)}),rootRef:g,portalRef:k,isTopModal:C,exited:b,hasTransition:y}}function jx(e){return Kr("MuiModal",e)}Xr("MuiModal",["root","hidden","backdrop"]);const $x=["BackdropComponent","BackdropProps","classes","className","closeAfterTransition","children","container","component","components","componentsProps","disableAutoFocus","disableEnforceFocus","disableEscapeKeyDown","disablePortal","disableRestoreFocus","disableScrollLock","hideBackdrop","keepMounted","onBackdropClick","onClose","onTransitionEnter","onTransitionExited","open","slotProps","slots","theme"],Dx=wl("div",{name:"MuiModal",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,!n.open&&n.exited&&t.hidden]}})((({theme:e,ownerState:t})=>l({position:"fixed",zIndex:(e.vars||e).zIndex.modal,right:0,bottom:0,top:0,left:0},!t.open&&t.exited&&{visibility:"hidden"}))),Bx=wl(px,{name:"MuiModal",slot:"Backdrop",overridesResolver:(e,t)=>t.backdrop})({zIndex:-1}),Fx=Y.forwardRef((function(e,t){var n,r,o,i,a,u;const c=$l({name:"MuiModal",props:e}),{BackdropComponent:d=Bx,BackdropProps:p,className:f,closeAfterTransition:h=!1,children:m,container:g,component:b,components:v={},componentsProps:y={},disableAutoFocus:x=!1,disableEnforceFocus:E=!1,disableEscapeKeyDown:S=!1,disablePortal:w=!1,disableRestoreFocus:C=!1,disableScrollLock:k=!1,hideBackdrop:R=!1,keepMounted:_=!1,onBackdropClick:T,open:L,slotProps:P,slots:A}=c,I=s(c,$x),O=l({},c,{closeAfterTransition:h,disableAutoFocus:x,disableEnforceFocus:E,disableEscapeKeyDown:S,disablePortal:w,disableRestoreFocus:C,disableScrollLock:k,hideBackdrop:R,keepMounted:_}),{getRootProps:M,getBackdropProps:N,getTransitionProps:z,portalRef:j,isTopModal:$,exited:D,hasTransition:B}=zx(l({},O,{rootRef:t})),F=l({},O,{exited:D}),H=(e=>{const{open:t,exited:n,classes:r}=e;return ei({root:["root",!t&&n&&"hidden"],backdrop:["backdrop"]},jx,r)})(F),U={};if(void 0===m.props.tabIndex&&(U.tabIndex="-1"),B){const{onEnter:e,onExited:t}=z();U.onEnter=e,U.onExited=t}const V=null!=(n=null!=(r=null==A?void 0:A.root)?r:v.Root)?n:Dx,G=null!=(o=null!=(i=null==A?void 0:A.backdrop)?i:v.Backdrop)?o:d,W=null!=(a=null==P?void 0:P.root)?a:y.root,q=null!=(u=null==P?void 0:P.backdrop)?u:y.backdrop,K=ii({elementType:V,externalSlotProps:W,externalForwardedProps:I,getSlotProps:M,additionalProps:{ref:t,as:b},ownerState:F,className:Wr(f,null==W?void 0:W.className,null==H?void 0:H.root,!F.open&&F.exited&&(null==H?void 0:H.hidden))}),X=ii({elementType:G,externalSlotProps:q,additionalProps:p,getSlotProps:e=>N(l({},e,{onClick:t=>{T&&T(t),null!=e&&e.onClick&&e.onClick(t)}})),className:Wr(null==q?void 0:q.className,null==p?void 0:p.className,null==H?void 0:H.backdrop),ownerState:F});return _||L||B&&!D?vn.jsx(Uy,{ref:j,container:g,disablePortal:w,children:vn.jsxs(V,l({},K,{children:[!R&&d?vn.jsx(G,l({},X)):null,vn.jsx(Mx,{disableEnforceFocus:E,disableAutoFocus:x,disableRestoreFocus:C,isEnabled:$,open:L,children:Y.cloneElement(m,U)})]}))}):null}));function Hx(e){return Kr("MuiDivider",e)}const Ux=Xr("MuiDivider",["root","absolute","fullWidth","inset","middle","flexItem","light","vertical","withChildren","withChildrenVertical","textAlignRight","textAlignLeft","wrapper","wrapperVertical"]),Vx=["absolute","children","className","component","flexItem","light","orientation","role","textAlign","variant"],Gx=wl("div",{name:"MuiDivider",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.absolute&&t.absolute,t[n.variant],n.light&&t.light,"vertical"===n.orientation&&t.vertical,n.flexItem&&t.flexItem,n.children&&t.withChildren,n.children&&"vertical"===n.orientation&&t.withChildrenVertical,"right"===n.textAlign&&"vertical"!==n.orientation&&t.textAlignRight,"left"===n.textAlign&&"vertical"!==n.orientation&&t.textAlignLeft]}})((({theme:e,ownerState:t})=>l({margin:0,flexShrink:0,borderWidth:0,borderStyle:"solid",borderColor:(e.vars||e).palette.divider,borderBottomWidth:"thin"},t.absolute&&{position:"absolute",bottom:0,left:0,width:"100%"},t.light&&{borderColor:e.vars?`rgba(${e.vars.palette.dividerChannel} / 0.08)`:_i(e.palette.divider,.08)},"inset"===t.variant&&{marginLeft:72},"middle"===t.variant&&"horizontal"===t.orientation&&{marginLeft:e.spacing(2),marginRight:e.spacing(2)},"middle"===t.variant&&"vertical"===t.orientation&&{marginTop:e.spacing(1),marginBottom:e.spacing(1)},"vertical"===t.orientation&&{height:"100%",borderBottomWidth:0,borderRightWidth:"thin"},t.flexItem&&{alignSelf:"stretch",height:"auto"})),(({ownerState:e})=>l({},e.children&&{display:"flex",whiteSpace:"nowrap",textAlign:"center",border:0,borderTopStyle:"solid",borderLeftStyle:"solid","&::before, &::after":{content:'""',alignSelf:"center"}})),(({theme:e,ownerState:t})=>l({},t.children&&"vertical"!==t.orientation&&{"&::before, &::after":{width:"100%",borderTop:`thin solid ${(e.vars||e).palette.divider}`,borderTopStyle:"inherit"}})),(({theme:e,ownerState:t})=>l({},t.children&&"vertical"===t.orientation&&{flexDirection:"column","&::before, &::after":{height:"100%",borderLeft:`thin solid ${(e.vars||e).palette.divider}`,borderLeftStyle:"inherit"}})),(({ownerState:e})=>l({},"right"===e.textAlign&&"vertical"!==e.orientation&&{"&::before":{width:"90%"},"&::after":{width:"10%"}},"left"===e.textAlign&&"vertical"!==e.orientation&&{"&::before":{width:"10%"},"&::after":{width:"90%"}}))),Wx=wl("span",{name:"MuiDivider",slot:"Wrapper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.wrapper,"vertical"===n.orientation&&t.wrapperVertical]}})((({theme:e,ownerState:t})=>l({display:"inline-block",paddingLeft:`calc(${e.spacing(1)} * 1.2)`,paddingRight:`calc(${e.spacing(1)} * 1.2)`},"vertical"===t.orientation&&{paddingTop:`calc(${e.spacing(1)} * 1.2)`,paddingBottom:`calc(${e.spacing(1)} * 1.2)`}))),Yx=Y.forwardRef((function(e,t){const n=$l({props:e,name:"MuiDivider"}),{absolute:r=!1,children:o,className:i,component:a=(o?"div":"hr"),flexItem:u=!1,light:c=!1,orientation:d="horizontal",role:p=("hr"!==a?"separator":void 0),textAlign:f="center",variant:h="fullWidth"}=n,m=s(n,Vx),g=l({},n,{absolute:r,component:a,flexItem:u,light:c,orientation:d,role:p,textAlign:f,variant:h}),b=(e=>{const{absolute:t,children:n,classes:r,flexItem:o,light:i,orientation:a,textAlign:l,variant:s}=e;return ei({root:["root",t&&"absolute",s,i&&"light","vertical"===a&&"vertical",o&&"flexItem",n&&"withChildren",n&&"vertical"===a&&"withChildrenVertical","right"===l&&"vertical"!==a&&"textAlignRight","left"===l&&"vertical"!==a&&"textAlignLeft"],wrapper:["wrapper","vertical"===a&&"wrapperVertical"]},Hx,r)})(g);return vn.jsx(Gx,l({as:a,className:Wr(b.root,i),role:p,ref:t,ownerState:g},m,{children:o?vn.jsx(Wx,{className:b.wrapper,ownerState:g,children:o}):null}))}));Yx.muiSkipListHighlight=!0;const qx=["addEndListener","appear","children","easing","in","onEnter","onEntered","onEntering","onExit","onExited","onExiting","style","timeout","TransitionComponent"];function Kx(e){return`scale(${e}, ${e**2})`}const Xx={entering:{opacity:1,transform:Kx(1)},entered:{opacity:1,transform:"none"}},Qx="undefined"!=typeof navigator&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),Zx=Y.forwardRef((function(e,t){const{addEndListener:n,appear:r=!0,children:o,easing:i,in:a,onEnter:u,onEntered:c,onEntering:d,onExit:p,onExited:f,onExiting:h,style:m,timeout:g="auto",TransitionComponent:b=ay}=e,v=s(e,qx),y=Bo(),x=Y.useRef(),E=Ga(),S=Y.useRef(null),w=zo(S,ai(o),t),C=e=>t=>{if(e){const n=S.current;void 0===t?e(n):e(n,t)}},k=C(d),R=C(((e,t)=>{fy(e);const{duration:n,delay:r,easing:o}=hy({style:m,timeout:g,easing:i},{mode:"enter"});let a;"auto"===g?(a=E.transitions.getAutoHeightDuration(e.clientHeight),x.current=a):a=n,e.style.transition=[E.transitions.create("opacity",{duration:a,delay:r}),E.transitions.create("transform",{duration:Qx?a:.666*a,delay:r,easing:o})].join(","),u&&u(e,t)})),_=C(c),T=C(h),L=C((e=>{const{duration:t,delay:n,easing:r}=hy({style:m,timeout:g,easing:i},{mode:"exit"});let o;"auto"===g?(o=E.transitions.getAutoHeightDuration(e.clientHeight),x.current=o):o=t,e.style.transition=[E.transitions.create("opacity",{duration:o,delay:n}),E.transitions.create("transform",{duration:Qx?o:.666*o,delay:Qx?n:n||.333*o,easing:r})].join(","),e.style.opacity=0,e.style.transform=Kx(.75),p&&p(e)})),P=C(f);return vn.jsx(b,l({appear:r,in:a,nodeRef:S,onEnter:R,onEntered:_,onEntering:k,onExit:L,onExited:P,onExiting:T,addEndListener:e=>{"auto"===g&&y.start(x.current||0,e),n&&n(S.current,e)},timeout:"auto"===g?null:g},v,{children:(e,t)=>Y.cloneElement(o,l({style:l({opacity:0,transform:Kx(.75),visibility:"exited"!==e||a?void 0:"hidden"},Xx[e],m,o.props.style),ref:w},t))}))}));function Jx(e){return Kr("MuiInputAdornment",e)}Zx.muiSupportAuto=!0;const eE=Xr("MuiInputAdornment",["root","filled","standard","outlined","positionStart","positionEnd","disablePointerEvents","hiddenLabel","sizeSmall"]);var tE;const nE=["children","className","component","disablePointerEvents","disableTypography","position","variant"],rE=wl("div",{name:"MuiInputAdornment",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[`position${jn(n.position)}`],!0===n.disablePointerEvents&&t.disablePointerEvents,t[n.variant]]}})((({theme:e,ownerState:t})=>l({display:"flex",height:"0.01em",maxHeight:"2em",alignItems:"center",whiteSpace:"nowrap",color:(e.vars||e).palette.action.active},"filled"===t.variant&&{[`&.${eE.positionStart}&:not(.${eE.hiddenLabel})`]:{marginTop:16}},"start"===t.position&&{marginRight:8},"end"===t.position&&{marginLeft:8},!0===t.disablePointerEvents&&{pointerEvents:"none"}))),oE=Y.forwardRef((function(e,t){const n=$l({props:e,name:"MuiInputAdornment"}),{children:r,className:o,component:i="div",disablePointerEvents:a=!1,disableTypography:u=!1,position:c,variant:d}=n,p=s(n,nE),f=Xy()||{};let h=d;d&&f.variant,f&&!h&&(h=f.variant);const m=l({},n,{hiddenLabel:f.hiddenLabel,size:f.size,disablePointerEvents:a,position:c,variant:h}),g=(e=>{const{classes:t,disablePointerEvents:n,hiddenLabel:r,position:o,size:i,variant:a}=e;return ei({root:["root",n&&"disablePointerEvents",o&&`position${jn(o)}`,a,r&&"hiddenLabel",i&&`size${jn(i)}`]},Jx,t)})(m);return vn.jsx(Ky.Provider,{value:null,children:vn.jsx(rE,l({as:i,ownerState:m,className:Wr(g.root,o),ref:t},p,{children:"string"!=typeof r||u?vn.jsxs(Y.Fragment,{children:["start"===c?tE||(tE=vn.jsx("span",{className:"notranslate",children:""})):null,r]}):vn.jsx(Hy,{color:"text.secondary",children:r})}))})})),iE=Y.createContext({});function aE(e){return Kr("MuiList",e)}Xr("MuiList",["root","padding","dense","subheader"]);const lE=["children","className","component","dense","disablePadding","subheader"],sE=wl("ul",{name:"MuiList",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,!n.disablePadding&&t.padding,n.dense&&t.dense,n.subheader&&t.subheader]}})((({ownerState:e})=>l({listStyle:"none",margin:0,padding:0,position:"relative"},!e.disablePadding&&{paddingTop:8,paddingBottom:8},e.subheader&&{paddingTop:0}))),uE=Y.forwardRef((function(e,t){const n=$l({props:e,name:"MuiList"}),{children:r,className:o,component:i="ul",dense:a=!1,disablePadding:u=!1,subheader:c}=n,d=s(n,lE),p=Y.useMemo((()=>({dense:a})),[a]),f=l({},n,{component:i,dense:a,disablePadding:u}),h=(e=>{const{classes:t,disablePadding:n,dense:r,subheader:o}=e;return ei({root:["root",!n&&"padding",r&&"dense",o&&"subheader"]},aE,t)})(f);return vn.jsx(iE.Provider,{value:p,children:vn.jsxs(sE,l({as:i,className:Wr(h.root,o),ref:t,ownerState:f},d,{children:[c,r]}))})}));function cE(e){return Kr("MuiListItem",e)}const dE=Xr("MuiListItem",["root","container","focusVisible","dense","alignItemsFlexStart","disabled","divider","gutters","padding","button","secondaryAction","selected"]);function pE(e){return Kr("MuiListItemButton",e)}const fE=Xr("MuiListItemButton",["root","focusVisible","dense","alignItemsFlexStart","disabled","divider","gutters","selected"]),hE=["alignItems","autoFocus","component","children","dense","disableGutters","divider","focusVisibleClassName","selected","className"],mE=wl(zy,{shouldForwardProp:e=>Sl(e)||"classes"===e,name:"MuiListItemButton",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.dense&&t.dense,"flex-start"===n.alignItems&&t.alignItemsFlexStart,n.divider&&t.divider,!n.disableGutters&&t.gutters]}})((({theme:e,ownerState:t})=>l({display:"flex",flexGrow:1,justifyContent:"flex-start",alignItems:"center",position:"relative",textDecoration:"none",minWidth:0,boxSizing:"border-box",textAlign:"left",paddingTop:8,paddingBottom:8,transition:e.transitions.create("background-color",{duration:e.transitions.duration.shortest}),"&:hover":{textDecoration:"none",backgroundColor:(e.vars||e).palette.action.hover,"@media (hover: none)":{backgroundColor:"transparent"}},[`&.${fE.selected}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.selectedOpacity})`:_i(e.palette.primary.main,e.palette.action.selectedOpacity),[`&.${fE.focusVisible}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.focusOpacity}))`:_i(e.palette.primary.main,e.palette.action.selectedOpacity+e.palette.action.focusOpacity)}},[`&.${fE.selected}:hover`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.hoverOpacity}))`:_i(e.palette.primary.main,e.palette.action.selectedOpacity+e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.selectedOpacity})`:_i(e.palette.primary.main,e.palette.action.selectedOpacity)}},[`&.${fE.focusVisible}`]:{backgroundColor:(e.vars||e).palette.action.focus},[`&.${fE.disabled}`]:{opacity:(e.vars||e).palette.action.disabledOpacity}},t.divider&&{borderBottom:`1px solid ${(e.vars||e).palette.divider}`,backgroundClip:"padding-box"},"flex-start"===t.alignItems&&{alignItems:"flex-start"},!t.disableGutters&&{paddingLeft:16,paddingRight:16},t.dense&&{paddingTop:4,paddingBottom:4}))),gE=Y.forwardRef((function(e,t){const n=$l({props:e,name:"MuiListItemButton"}),{alignItems:r="center",autoFocus:o=!1,component:i="div",children:a,dense:u=!1,disableGutters:c=!1,divider:d=!1,focusVisibleClassName:p,selected:f=!1,className:h}=n,m=s(n,hE),g=Y.useContext(iE),b=Y.useMemo((()=>({dense:u||g.dense||!1,alignItems:r,disableGutters:c})),[r,g.dense,u,c]),v=Y.useRef(null);So((()=>{o&&v.current&&v.current.focus()}),[o]);const y=l({},n,{alignItems:r,dense:b.dense,disableGutters:c,divider:d,selected:f}),x=(e=>{const{alignItems:t,classes:n,dense:r,disabled:o,disableGutters:i,divider:a,selected:s}=e;return l({},n,ei({root:["root",r&&"dense",!i&&"gutters",a&&"divider",o&&"disabled","flex-start"===t&&"alignItemsFlexStart",s&&"selected"]},pE,n))})(y),E=zo(v,t);return vn.jsx(iE.Provider,{value:b,children:vn.jsx(mE,l({ref:E,href:m.href||m.to,component:(m.href||m.to)&&"div"===i?"button":i,focusVisibleClassName:Wr(x.focusVisible,p),ownerState:y,className:Wr(x.root,h)},m,{classes:x,children:a}))})}));function bE(e){return Kr("MuiListItemSecondaryAction",e)}Xr("MuiListItemSecondaryAction",["root","disableGutters"]);const vE=["className"],yE=wl("div",{name:"MuiListItemSecondaryAction",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.disableGutters&&t.disableGutters]}})((({ownerState:e})=>l({position:"absolute",right:16,top:"50%",transform:"translateY(-50%)"},e.disableGutters&&{right:0}))),xE=Y.forwardRef((function(e,t){const n=$l({props:e,name:"MuiListItemSecondaryAction"}),{className:r}=n,o=s(n,vE),i=l({},n,{disableGutters:Y.useContext(iE).disableGutters}),a=(e=>{const{disableGutters:t,classes:n}=e;return ei({root:["root",t&&"disableGutters"]},bE,n)})(i);return vn.jsx(yE,l({className:Wr(a.root,r),ownerState:i,ref:t},o))}));xE.muiName="ListItemSecondaryAction";const EE=["className"],SE=["alignItems","autoFocus","button","children","className","component","components","componentsProps","ContainerComponent","ContainerProps","dense","disabled","disableGutters","disablePadding","divider","focusVisibleClassName","secondaryAction","selected","slotProps","slots"],wE=wl("div",{name:"MuiListItem",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.dense&&t.dense,"flex-start"===n.alignItems&&t.alignItemsFlexStart,n.divider&&t.divider,!n.disableGutters&&t.gutters,!n.disablePadding&&t.padding,n.button&&t.button,n.hasSecondaryAction&&t.secondaryAction]}})((({theme:e,ownerState:t})=>l({display:"flex",justifyContent:"flex-start",alignItems:"center",position:"relative",textDecoration:"none",width:"100%",boxSizing:"border-box",textAlign:"left"},!t.disablePadding&&l({paddingTop:8,paddingBottom:8},t.dense&&{paddingTop:4,paddingBottom:4},!t.disableGutters&&{paddingLeft:16,paddingRight:16},!!t.secondaryAction&&{paddingRight:48}),!!t.secondaryAction&&{[`& > .${fE.root}`]:{paddingRight:48}},{[`&.${dE.focusVisible}`]:{backgroundColor:(e.vars||e).palette.action.focus},[`&.${dE.selected}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.selectedOpacity})`:_i(e.palette.primary.main,e.palette.action.selectedOpacity),[`&.${dE.focusVisible}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.focusOpacity}))`:_i(e.palette.primary.main,e.palette.action.selectedOpacity+e.palette.action.focusOpacity)}},[`&.${dE.disabled}`]:{opacity:(e.vars||e).palette.action.disabledOpacity}},"flex-start"===t.alignItems&&{alignItems:"flex-start"},t.divider&&{borderBottom:`1px solid ${(e.vars||e).palette.divider}`,backgroundClip:"padding-box"},t.button&&{transition:e.transitions.create("background-color",{duration:e.transitions.duration.shortest}),"&:hover":{textDecoration:"none",backgroundColor:(e.vars||e).palette.action.hover,"@media (hover: none)":{backgroundColor:"transparent"}},[`&.${dE.selected}:hover`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.hoverOpacity}))`:_i(e.palette.primary.main,e.palette.action.selectedOpacity+e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.selectedOpacity})`:_i(e.palette.primary.main,e.palette.action.selectedOpacity)}}},t.hasSecondaryAction&&{paddingRight:48}))),CE=wl("li",{name:"MuiListItem",slot:"Container",overridesResolver:(e,t)=>t.container})({position:"relative"}),kE=Y.forwardRef((function(e,t){const n=$l({props:e,name:"MuiListItem"}),{alignItems:r="center",autoFocus:o=!1,button:i=!1,children:a,className:u,component:c,components:d={},componentsProps:p={},ContainerComponent:f="li",ContainerProps:{className:h}={},dense:m=!1,disabled:g=!1,disableGutters:b=!1,disablePadding:v=!1,divider:y=!1,focusVisibleClassName:x,secondaryAction:E,selected:S=!1,slotProps:w={},slots:C={}}=n,k=s(n.ContainerProps,EE),R=s(n,SE),_=Y.useContext(iE),T=Y.useMemo((()=>({dense:m||_.dense||!1,alignItems:r,disableGutters:b})),[r,_.dense,m,b]),L=Y.useRef(null);So((()=>{o&&L.current&&L.current.focus()}),[o]);const P=Y.Children.toArray(a),A=P.length&&(I=P[P.length-1],O=["ListItemSecondaryAction"],Y.isValidElement(I)&&-1!==O.indexOf(null!=(M=I.type.muiName)?M:null==(N=I.type)||null==(N=N._payload)||null==(N=N.value)?void 0:N.muiName));var I,O,M,N;const z=l({},n,{alignItems:r,autoFocus:o,button:i,dense:T.dense,disabled:g,disableGutters:b,disablePadding:v,divider:y,hasSecondaryAction:A,selected:S}),j=(e=>{const{alignItems:t,button:n,classes:r,dense:o,disabled:i,disableGutters:a,disablePadding:l,divider:s,hasSecondaryAction:u,selected:c}=e;return ei({root:["root",o&&"dense",!a&&"gutters",!l&&"padding",s&&"divider",i&&"disabled",n&&"button","flex-start"===t&&"alignItemsFlexStart",u&&"secondaryAction",c&&"selected"],container:["container"]},cE,r)})(z),$=zo(L,t),D=C.root||d.Root||wE,B=w.root||p.root||{},F=l({className:Wr(j.root,B.className,u),disabled:g},R);let H=c||"li";return i&&(F.component=c||"div",F.focusVisibleClassName=Wr(dE.focusVisible,x),H=zy),A?(H=F.component||c?H:"div","li"===f&&("li"===H?H="div":"li"===F.component&&(F.component="div")),vn.jsx(iE.Provider,{value:T,children:vn.jsxs(CE,l({as:f,className:Wr(j.container,h),ref:$,ownerState:z},k,{children:[vn.jsx(D,l({},B,!ti(D)&&{as:H,ownerState:l({},z,B.ownerState)},F,{children:P})),P.pop()]}))})):vn.jsx(iE.Provider,{value:T,children:vn.jsxs(D,l({},B,{as:H,ref:$},!ti(D)&&{ownerState:l({},z,B.ownerState)},F,{children:[P,E&&vn.jsx(xE,{children:E})]}))})}));function RE(e){return Kr("MuiListItemIcon",e)}const _E=Xr("MuiListItemIcon",["root","alignItemsFlexStart"]),TE=["className"],LE=wl("div",{name:"MuiListItemIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,"flex-start"===n.alignItems&&t.alignItemsFlexStart]}})((({theme:e,ownerState:t})=>l({minWidth:56,color:(e.vars||e).palette.action.active,flexShrink:0,display:"inline-flex"},"flex-start"===t.alignItems&&{marginTop:8}))),PE=Y.forwardRef((function(e,t){const n=$l({props:e,name:"MuiListItemIcon"}),{className:r}=n,o=s(n,TE),i=l({},n,{alignItems:Y.useContext(iE).alignItems}),a=(e=>{const{alignItems:t,classes:n}=e;return ei({root:["root","flex-start"===t&&"alignItemsFlexStart"]},RE,n)})(i);return vn.jsx(LE,l({className:Wr(a.root,r),ownerState:i,ref:t},o))})),AE=Xr("MuiListItemText",["root","multiline","dense","inset","primary","secondary"]),IE=["actions","autoFocus","autoFocusItem","children","className","disabledItemsFocusable","disableListWrap","onKeyDown","variant"];function OE(e,t,n){return e===t?e.firstChild:t&&t.nextElementSibling?t.nextElementSibling:n?null:e.firstChild}function ME(e,t,n){return e===t?n?e.firstChild:e.lastChild:t&&t.previousElementSibling?t.previousElementSibling:n?null:e.lastChild}function NE(e,t){if(void 0===t)return!0;let n=e.innerText;return void 0===n&&(n=e.textContent),n=n.trim().toLowerCase(),0!==n.length&&(t.repeating?n[0]===t.keys[0]:0===n.indexOf(t.keys.join("")))}function zE(e,t,n,r,o,i){let a=!1,l=o(e,t,!!t&&n);for(;l;){if(l===e.firstChild){if(a)return!1;a=!0}const t=!r&&(l.disabled||"true"===l.getAttribute("aria-disabled"));if(l.hasAttribute("tabindex")&&NE(l,i)&&!t)return l.focus(),!0;l=o(e,l,n)}return!1}const jE=Y.forwardRef((function(e,t){const{actions:n,autoFocus:r=!1,autoFocusItem:o=!1,children:i,className:a,disabledItemsFocusable:u=!1,disableListWrap:c=!1,onKeyDown:d,variant:p="selectedMenu"}=e,f=s(e,IE),h=Y.useRef(null),m=Y.useRef({keys:[],repeating:!0,previousKeyMatched:!0,lastTime:null});So((()=>{r&&h.current.focus()}),[r]),Y.useImperativeHandle(n,(()=>({adjustStyleForScrollbar:(e,{direction:t})=>{const n=!h.current.style.width;if(e.clientHeight<h.current.clientHeight&&n){const n=`${Xo(Lo(e))}px`;h.current.style["rtl"===t?"paddingLeft":"paddingRight"]=n,h.current.style.width=`calc(100% + ${n})`}return h.current}})),[]);const g=zo(h,t);let b=-1;Y.Children.forEach(i,((e,t)=>{Y.isValidElement(e)?(e.props.disabled||("selectedMenu"===p&&e.props.selected||-1===b)&&(b=t),b===t&&(e.props.disabled||e.props.muiSkipListHighlight||e.type.muiSkipListHighlight)&&(b+=1,b>=i.length&&(b=-1))):b===t&&(b+=1,b>=i.length&&(b=-1))}));const v=Y.Children.map(i,((e,t)=>{if(t===b){const t={};return o&&(t.autoFocus=!0),void 0===e.props.tabIndex&&"selectedMenu"===p&&(t.tabIndex=0),Y.cloneElement(e,t)}return e}));return vn.jsx(uE,l({role:"menu",ref:g,className:a,onKeyDown:e=>{const t=h.current,n=e.key,r=Lo(t).activeElement;if("ArrowDown"===n)e.preventDefault(),zE(t,r,c,u,OE);else if("ArrowUp"===n)e.preventDefault(),zE(t,r,c,u,ME);else if("Home"===n)e.preventDefault(),zE(t,null,c,u,OE);else if("End"===n)e.preventDefault(),zE(t,null,c,u,ME);else if(1===n.length){const o=m.current,i=n.toLowerCase(),a=performance.now();o.keys.length>0&&(a-o.lastTime>500?(o.keys=[],o.repeating=!0,o.previousKeyMatched=!0):o.repeating&&i!==o.keys[0]&&(o.repeating=!1)),o.lastTime=a,o.keys.push(i);const l=r&&!o.repeating&&NE(r,o);o.previousKeyMatched&&(l||zE(t,r,!1,u,OE,o))?e.preventDefault():o.previousKeyMatched=!1}d&&d(e)},tabIndex:r?0:-1},f,{children:v}))}));function $E(e){return Kr("MuiPopover",e)}Xr("MuiPopover",["root","paper"]);const DE=["onEntering"],BE=["action","anchorEl","anchorOrigin","anchorPosition","anchorReference","children","className","container","elevation","marginThreshold","open","PaperProps","slots","slotProps","transformOrigin","TransitionComponent","transitionDuration","TransitionProps","disableScrollLock"],FE=["slotProps"];function HE(e,t){let n=0;return"number"==typeof t?n=t:"center"===t?n=e.height/2:"bottom"===t&&(n=e.height),n}function UE(e,t){let n=0;return"number"==typeof t?n=t:"center"===t?n=e.width/2:"right"===t&&(n=e.width),n}function VE(e){return[e.horizontal,e.vertical].map((e=>"number"==typeof e?`${e}px`:e)).join(" ")}function GE(e){return"function"==typeof e?e():e}const WE=wl(Fx,{name:"MuiPopover",slot:"Root",overridesResolver:(e,t)=>t.root})({}),YE=wl(vy,{name:"MuiPopover",slot:"Paper",overridesResolver:(e,t)=>t.paper})({position:"absolute",overflowY:"auto",overflowX:"hidden",minWidth:16,minHeight:16,maxWidth:"calc(100% - 32px)",maxHeight:"calc(100% - 32px)",outline:0}),qE=Y.forwardRef((function(e,t){var n,r,o;const i=$l({props:e,name:"MuiPopover"}),{action:a,anchorEl:u,anchorOrigin:c={vertical:"top",horizontal:"left"},anchorPosition:d,anchorReference:p="anchorEl",children:f,className:h,container:m,elevation:g=8,marginThreshold:b=16,open:v,PaperProps:y={},slots:x,slotProps:E,transformOrigin:S={vertical:"top",horizontal:"left"},TransitionComponent:w=Zx,transitionDuration:C="auto",TransitionProps:{onEntering:k}={},disableScrollLock:R=!1}=i,_=s(i.TransitionProps,DE),T=s(i,BE),L=null!=(n=null==E?void 0:E.paper)?n:y,P=Y.useRef(),A=zo(P,L.ref),I=l({},i,{anchorOrigin:c,anchorReference:p,elevation:g,marginThreshold:b,externalPaperSlotProps:L,transformOrigin:S,TransitionComponent:w,transitionDuration:C,TransitionProps:_}),O=(e=>{const{classes:t}=e;return ei({root:["root"],paper:["paper"]},$E,t)})(I),M=Y.useCallback((()=>{if("anchorPosition"===p)return d;const e=GE(u),t=(e&&1===e.nodeType?e:Lo(P.current).body).getBoundingClientRect();return{top:t.top+HE(t,c.vertical),left:t.left+UE(t,c.horizontal)}}),[u,c.horizontal,c.vertical,d,p]),N=Y.useCallback((e=>({vertical:HE(e,S.vertical),horizontal:UE(e,S.horizontal)})),[S.horizontal,S.vertical]),z=Y.useCallback((e=>{const t={width:e.offsetWidth,height:e.offsetHeight},n=N(t);if("none"===p)return{top:null,left:null,transformOrigin:VE(n)};const r=M();let o=r.top-n.vertical,i=r.left-n.horizontal;const a=o+t.height,l=i+t.width,s=Po(GE(u)),c=s.innerHeight-b,d=s.innerWidth-b;if(null!==b&&o<b){const e=o-b;o-=e,n.vertical+=e}else if(null!==b&&a>c){const e=a-c;o-=e,n.vertical+=e}if(null!==b&&i<b){const e=i-b;i-=e,n.horizontal+=e}else if(l>d){const e=l-d;i-=e,n.horizontal+=e}return{top:`${Math.round(o)}px`,left:`${Math.round(i)}px`,transformOrigin:VE(n)}}),[u,p,M,N,b]),[j,$]=Y.useState(v),D=Y.useCallback((()=>{const e=P.current;if(!e)return;const t=z(e);null!==t.top&&(e.style.top=t.top),null!==t.left&&(e.style.left=t.left),e.style.transformOrigin=t.transformOrigin,$(!0)}),[z]);Y.useEffect((()=>(R&&window.addEventListener("scroll",D),()=>window.removeEventListener("scroll",D))),[u,R,D]);Y.useEffect((()=>{v&&D()})),Y.useImperativeHandle(a,(()=>v?{updatePosition:()=>{D()}}:null),[v,D]),Y.useEffect((()=>{if(!v)return;const e=To((()=>{D()})),t=Po(u);return t.addEventListener("resize",e),()=>{e.clear(),t.removeEventListener("resize",e)}}),[u,v,D]);let B=C;"auto"!==C||w.muiSupportAuto||(B=void 0);const F=m||(u?Lo(GE(u)).body:void 0),H=null!=(r=null==x?void 0:x.root)?r:WE,U=null!=(o=null==x?void 0:x.paper)?o:YE,V=ii({elementType:U,externalSlotProps:l({},L,{style:j?L.style:l({},L.style,{opacity:0})}),additionalProps:{elevation:g,ref:A},ownerState:I,className:Wr(O.paper,null==L?void 0:L.className)}),G=ii({elementType:H,externalSlotProps:(null==E?void 0:E.root)||{},externalForwardedProps:T,additionalProps:{ref:t,slotProps:{backdrop:{invisible:!0}},container:F,open:v},ownerState:I,className:Wr(O.root,h)}),{slotProps:W}=G,q=s(G,FE);return vn.jsx(H,l({},q,!ti(H)&&{slotProps:W,disableScrollLock:R},{children:vn.jsx(w,l({appear:!0,in:v,onEntering:(e,t)=>{k&&k(e,t),D()},onExited:()=>{$(!1)},timeout:B},_,{children:vn.jsx(U,l({},V,{children:f}))}))}))}));function KE(e){return Kr("MuiMenu",e)}Xr("MuiMenu",["root","paper","list"]);const XE=["onEntering"],QE=["autoFocus","children","className","disableAutoFocusItem","MenuListProps","onClose","open","PaperProps","PopoverClasses","transitionDuration","TransitionProps","variant","slots","slotProps"],ZE={vertical:"top",horizontal:"right"},JE={vertical:"top",horizontal:"left"},eS=wl(qE,{shouldForwardProp:e=>Sl(e)||"classes"===e,name:"MuiMenu",slot:"Root",overridesResolver:(e,t)=>t.root})({}),tS=wl(YE,{name:"MuiMenu",slot:"Paper",overridesResolver:(e,t)=>t.paper})({maxHeight:"calc(100% - 96px)",WebkitOverflowScrolling:"touch"}),nS=wl(jE,{name:"MuiMenu",slot:"List",overridesResolver:(e,t)=>t.list})({outline:0}),rS=Y.forwardRef((function(e,t){var n,r;const o=$l({props:e,name:"MuiMenu"}),{autoFocus:i=!0,children:a,className:u,disableAutoFocusItem:c=!1,MenuListProps:d={},onClose:p,open:f,PaperProps:h={},PopoverClasses:m,transitionDuration:g="auto",TransitionProps:{onEntering:b}={},variant:v="selectedMenu",slots:y={},slotProps:x={}}=o,E=s(o.TransitionProps,XE),S=s(o,QE),w=hi(),C=l({},o,{autoFocus:i,disableAutoFocusItem:c,MenuListProps:d,onEntering:b,PaperProps:h,transitionDuration:g,TransitionProps:E,variant:v}),k=(e=>{const{classes:t}=e;return ei({root:["root"],paper:["paper"],list:["list"]},KE,t)})(C),R=i&&!c&&f,_=Y.useRef(null);let T=-1;Y.Children.map(a,((e,t)=>{Y.isValidElement(e)&&(e.props.disabled||("selectedMenu"===v&&e.props.selected||-1===T)&&(T=t))}));const L=null!=(n=y.paper)?n:tS,P=null!=(r=x.paper)?r:h,A=ii({elementType:y.root,externalSlotProps:x.root,ownerState:C,className:[k.root,u]}),I=ii({elementType:L,externalSlotProps:P,ownerState:C,className:k.paper});return vn.jsx(eS,l({onClose:p,anchorOrigin:{vertical:"bottom",horizontal:w?"right":"left"},transformOrigin:w?ZE:JE,slots:{paper:L,root:y.root},slotProps:{root:A,paper:I},open:f,ref:t,transitionDuration:g,TransitionProps:l({onEntering:(e,t)=>{_.current&&_.current.adjustStyleForScrollbar(e,{direction:w?"rtl":"ltr"}),b&&b(e,t)}},E),ownerState:C},S,{classes:m,children:vn.jsx(nS,l({onKeyDown:e=>{"Tab"===e.key&&(e.preventDefault(),p&&p(e,"tabKeyDown"))},actions:_,autoFocus:i&&(-1===T||c),autoFocusItem:R,variant:v},d,{className:Wr(k.list,d.className),children:a}))}))}));function oS(e){return Kr("MuiMenuItem",e)}const iS=Xr("MuiMenuItem",["root","focusVisible","dense","disabled","divider","gutters","selected"]),aS=["autoFocus","component","dense","divider","disableGutters","focusVisibleClassName","role","tabIndex","className"],lS=wl(zy,{shouldForwardProp:e=>Sl(e)||"classes"===e,name:"MuiMenuItem",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.dense&&t.dense,n.divider&&t.divider,!n.disableGutters&&t.gutters]}})((({theme:e,ownerState:t})=>l({},e.typography.body1,{display:"flex",justifyContent:"flex-start",alignItems:"center",position:"relative",textDecoration:"none",minHeight:48,paddingTop:6,paddingBottom:6,boxSizing:"border-box",whiteSpace:"nowrap"},!t.disableGutters&&{paddingLeft:16,paddingRight:16},t.divider&&{borderBottom:`1px solid ${(e.vars||e).palette.divider}`,backgroundClip:"padding-box"},{"&:hover":{textDecoration:"none",backgroundColor:(e.vars||e).palette.action.hover,"@media (hover: none)":{backgroundColor:"transparent"}},[`&.${iS.selected}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.selectedOpacity})`:_i(e.palette.primary.main,e.palette.action.selectedOpacity),[`&.${iS.focusVisible}`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.focusOpacity}))`:_i(e.palette.primary.main,e.palette.action.selectedOpacity+e.palette.action.focusOpacity)}},[`&.${iS.selected}:hover`]:{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / calc(${e.vars.palette.action.selectedOpacity} + ${e.vars.palette.action.hoverOpacity}))`:_i(e.palette.primary.main,e.palette.action.selectedOpacity+e.palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:e.vars?`rgba(${e.vars.palette.primary.mainChannel} / ${e.vars.palette.action.selectedOpacity})`:_i(e.palette.primary.main,e.palette.action.selectedOpacity)}},[`&.${iS.focusVisible}`]:{backgroundColor:(e.vars||e).palette.action.focus},[`&.${iS.disabled}`]:{opacity:(e.vars||e).palette.action.disabledOpacity},[`& + .${Ux.root}`]:{marginTop:e.spacing(1),marginBottom:e.spacing(1)},[`& + .${Ux.inset}`]:{marginLeft:52},[`& .${AE.root}`]:{marginTop:0,marginBottom:0},[`& .${AE.inset}`]:{paddingLeft:36},[`& .${_E.root}`]:{minWidth:36}},!t.dense&&{[e.breakpoints.up("sm")]:{minHeight:"auto"}},t.dense&&l({minHeight:32,paddingTop:4,paddingBottom:4},e.typography.body2,{[`& .${_E.root} svg`]:{fontSize:"1.25rem"}})))),sS=Y.forwardRef((function(e,t){const n=$l({props:e,name:"MuiMenuItem"}),{autoFocus:r=!1,component:o="li",dense:i=!1,divider:a=!1,disableGutters:u=!1,focusVisibleClassName:c,role:d="menuitem",tabIndex:p,className:f}=n,h=s(n,aS),m=Y.useContext(iE),g=Y.useMemo((()=>({dense:i||m.dense||!1,disableGutters:u})),[m.dense,i,u]),b=Y.useRef(null);So((()=>{r&&b.current&&b.current.focus()}),[r]);const v=l({},n,{dense:g.dense,divider:a,disableGutters:u}),y=(e=>{const{disabled:t,dense:n,divider:r,disableGutters:o,selected:i,classes:a}=e;return l({},a,ei({root:["root",n&&"dense",t&&"disabled",!o&&"gutters",r&&"divider",i&&"selected"]},oS,a))})(n),x=zo(b,t);let E;return n.disabled||(E=void 0!==p?p:-1),vn.jsx(iE.Provider,{value:g,children:vn.jsx(lS,l({ref:x,role:d,tabIndex:E,component:o,focusVisibleClassName:Wr(y.focusVisible,c),className:Wr(y.root,f)},h,{ownerState:v,classes:y}))})}));function uS(e){return Kr("MuiTab",e)}const cS=Xr("MuiTab",["root","labelIcon","textColorInherit","textColorPrimary","textColorSecondary","selected","disabled","fullWidth","wrapped","iconWrapper"]),dS=["className","disabled","disableFocusRipple","fullWidth","icon","iconPosition","indicator","label","onChange","onClick","onFocus","selected","selectionFollowsFocus","textColor","value","wrapped"],pS=wl(zy,{name:"MuiTab",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.label&&n.icon&&t.labelIcon,t[`textColor${jn(n.textColor)}`],n.fullWidth&&t.fullWidth,n.wrapped&&t.wrapped,{[`& .${cS.iconWrapper}`]:t.iconWrapper}]}})((({theme:e,ownerState:t})=>l({},e.typography.button,{maxWidth:360,minWidth:90,position:"relative",minHeight:48,flexShrink:0,padding:"12px 16px",overflow:"hidden",whiteSpace:"normal",textAlign:"center"},t.label&&{flexDirection:"top"===t.iconPosition||"bottom"===t.iconPosition?"column":"row"},{lineHeight:1.25},t.icon&&t.label&&{minHeight:72,paddingTop:9,paddingBottom:9,[`& > .${cS.iconWrapper}`]:l({},"top"===t.iconPosition&&{marginBottom:6},"bottom"===t.iconPosition&&{marginTop:6},"start"===t.iconPosition&&{marginRight:e.spacing(1)},"end"===t.iconPosition&&{marginLeft:e.spacing(1)})},"inherit"===t.textColor&&{color:"inherit",opacity:.6,[`&.${cS.selected}`]:{opacity:1},[`&.${cS.disabled}`]:{opacity:(e.vars||e).palette.action.disabledOpacity}},"primary"===t.textColor&&{color:(e.vars||e).palette.text.secondary,[`&.${cS.selected}`]:{color:(e.vars||e).palette.primary.main},[`&.${cS.disabled}`]:{color:(e.vars||e).palette.text.disabled}},"secondary"===t.textColor&&{color:(e.vars||e).palette.text.secondary,[`&.${cS.selected}`]:{color:(e.vars||e).palette.secondary.main},[`&.${cS.disabled}`]:{color:(e.vars||e).palette.text.disabled}},t.fullWidth&&{flexShrink:1,flexGrow:1,flexBasis:0,maxWidth:"none"},t.wrapped&&{fontSize:e.typography.pxToRem(12)}))),fS=Y.forwardRef((function(e,t){const n=$l({props:e,name:"MuiTab"}),{className:r,disabled:o=!1,disableFocusRipple:i=!1,fullWidth:a,icon:u,iconPosition:c="top",indicator:d,label:p,onChange:f,onClick:h,onFocus:m,selected:g,selectionFollowsFocus:b,textColor:v="inherit",value:y,wrapped:x=!1}=n,E=s(n,dS),S=l({},n,{disabled:o,disableFocusRipple:i,selected:g,icon:!!u,iconPosition:c,label:!!p,fullWidth:a,textColor:v,wrapped:x}),w=(e=>{const{classes:t,textColor:n,fullWidth:r,wrapped:o,icon:i,label:a,selected:l,disabled:s}=e;return ei({root:["root",i&&a&&"labelIcon",`textColor${jn(n)}`,r&&"fullWidth",o&&"wrapped",l&&"selected",s&&"disabled"],iconWrapper:["iconWrapper"]},uS,t)})(S),C=u&&p&&Y.isValidElement(u)?Y.cloneElement(u,{className:Wr(w.iconWrapper,u.props.className)}):u;return vn.jsxs(pS,l({focusRipple:!i,className:Wr(w.root,r),ref:t,role:"tab","aria-selected":g,disabled:o,onClick:e=>{!g&&f&&f(e,y),h&&h(e)},onFocus:e=>{b&&!g&&f&&f(e,y),m&&m(e)},ownerState:S,tabIndex:g?0:-1},E,{children:["top"===c||"start"===c?vn.jsxs(Y.Fragment,{children:[C,p]}):vn.jsxs(Y.Fragment,{children:[p,C]}),d]}))}));var hS=Ul(vn.jsx("path",{d:"M15.41 16.09l-4.58-4.59 4.58-4.59L14 5.5l-6 6 6 6z"}),"KeyboardArrowLeft"),mS=Ul(vn.jsx("path",{d:"M8.59 16.34l4.58-4.59-4.58-4.59L10 5.75l6 6-6 6z"}),"KeyboardArrowRight");function gS(e){return(1+Math.sin(Math.PI*e-Math.PI/2))/2}const bS=["onChange"],vS={width:99,height:99,position:"absolute",top:-9999,overflow:"scroll"};function yS(e){return Kr("MuiTabScrollButton",e)}const xS=Xr("MuiTabScrollButton",["root","vertical","horizontal","disabled"]),ES=["className","slots","slotProps","direction","orientation","disabled"],SS=wl(zy,{name:"MuiTabScrollButton",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.orientation&&t[n.orientation]]}})((({ownerState:e})=>l({width:40,flexShrink:0,opacity:.8,[`&.${xS.disabled}`]:{opacity:0}},"vertical"===e.orientation&&{width:"100%",height:40,"& svg":{transform:`rotate(${e.isRtl?-90:90}deg)`}}))),wS=Y.forwardRef((function(e,t){var n,r;const o=$l({props:e,name:"MuiTabScrollButton"}),{className:i,slots:a={},slotProps:u={},direction:c}=o,d=s(o,ES),p=l({isRtl:hi()},o),f=(e=>{const{classes:t,orientation:n,disabled:r}=e;return ei({root:["root",n,r&&"disabled"]},yS,t)})(p),h=null!=(n=a.StartScrollButtonIcon)?n:hS,m=null!=(r=a.EndScrollButtonIcon)?r:mS,g=ii({elementType:h,externalSlotProps:u.startScrollButtonIcon,additionalProps:{fontSize:"small"},ownerState:p}),b=ii({elementType:m,externalSlotProps:u.endScrollButtonIcon,additionalProps:{fontSize:"small"},ownerState:p});return vn.jsx(SS,l({component:"div",className:Wr(f.root,i),ref:t,role:null,ownerState:p,tabIndex:null},d,{children:"left"===c?vn.jsx(h,l({},g)):vn.jsx(m,l({},b))}))}));function CS(e){return Kr("MuiTabs",e)}const kS=Xr("MuiTabs",["root","vertical","flexContainer","flexContainerVertical","centered","scroller","fixed","scrollableX","scrollableY","hideScrollbar","scrollButtons","scrollButtonsHideMobile","indicator"]),RS=["aria-label","aria-labelledby","action","centered","children","className","component","allowScrollButtonsMobile","indicatorColor","onChange","orientation","ScrollButtonComponent","scrollButtons","selectionFollowsFocus","slots","slotProps","TabIndicatorProps","TabScrollButtonProps","textColor","value","variant","visibleScrollbar"],_S=(e,t)=>e===t?e.firstChild:t&&t.nextElementSibling?t.nextElementSibling:e.firstChild,TS=(e,t)=>e===t?e.lastChild:t&&t.previousElementSibling?t.previousElementSibling:e.lastChild,LS=(e,t,n)=>{let r=!1,o=n(e,t);for(;o;){if(o===e.firstChild){if(r)return;r=!0}const t=o.disabled||"true"===o.getAttribute("aria-disabled");if(o.hasAttribute("tabindex")&&!t)return void o.focus();o=n(e,o)}},PS=wl("div",{name:"MuiTabs",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[{[`& .${kS.scrollButtons}`]:t.scrollButtons},{[`& .${kS.scrollButtons}`]:n.scrollButtonsHideMobile&&t.scrollButtonsHideMobile},t.root,n.vertical&&t.vertical]}})((({ownerState:e,theme:t})=>l({overflow:"hidden",minHeight:48,WebkitOverflowScrolling:"touch",display:"flex"},e.vertical&&{flexDirection:"column"},e.scrollButtonsHideMobile&&{[`& .${kS.scrollButtons}`]:{[t.breakpoints.down("sm")]:{display:"none"}}}))),AS=wl("div",{name:"MuiTabs",slot:"Scroller",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.scroller,n.fixed&&t.fixed,n.hideScrollbar&&t.hideScrollbar,n.scrollableX&&t.scrollableX,n.scrollableY&&t.scrollableY]}})((({ownerState:e})=>l({position:"relative",display:"inline-block",flex:"1 1 auto",whiteSpace:"nowrap"},e.fixed&&{overflowX:"hidden",width:"100%"},e.hideScrollbar&&{scrollbarWidth:"none","&::-webkit-scrollbar":{display:"none"}},e.scrollableX&&{overflowX:"auto",overflowY:"hidden"},e.scrollableY&&{overflowY:"auto",overflowX:"hidden"}))),IS=wl("div",{name:"MuiTabs",slot:"FlexContainer",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.flexContainer,n.vertical&&t.flexContainerVertical,n.centered&&t.centered]}})((({ownerState:e})=>l({display:"flex"},e.vertical&&{flexDirection:"column"},e.centered&&{justifyContent:"center"}))),OS=wl("span",{name:"MuiTabs",slot:"Indicator",overridesResolver:(e,t)=>t.indicator})((({ownerState:e,theme:t})=>l({position:"absolute",height:2,bottom:0,width:"100%",transition:t.transitions.create()},"primary"===e.indicatorColor&&{backgroundColor:(t.vars||t).palette.primary.main},"secondary"===e.indicatorColor&&{backgroundColor:(t.vars||t).palette.secondary.main},e.vertical&&{height:"100%",width:2,right:0}))),MS=wl((function(e){const{onChange:t}=e,n=s(e,bS),r=Y.useRef(),o=Y.useRef(null),i=()=>{r.current=o.current.offsetHeight-o.current.clientHeight};return So((()=>{const e=To((()=>{const e=r.current;i(),e!==r.current&&t(r.current)})),n=Po(o.current);return n.addEventListener("resize",e),()=>{e.clear(),n.removeEventListener("resize",e)}}),[t]),Y.useEffect((()=>{i(),t(r.current)}),[t]),vn.jsx("div",l({style:vS},n,{ref:o}))}))({overflowX:"auto",overflowY:"hidden",scrollbarWidth:"none","&::-webkit-scrollbar":{display:"none"}}),NS={},zS=Y.forwardRef((function(e,t){const n=$l({props:e,name:"MuiTabs"}),r=Ga(),o=hi(),{"aria-label":i,"aria-labelledby":a,action:u,centered:c=!1,children:d,className:p,component:f="div",allowScrollButtonsMobile:h=!1,indicatorColor:m="primary",onChange:g,orientation:b="horizontal",ScrollButtonComponent:v=wS,scrollButtons:y="auto",selectionFollowsFocus:x,slots:E={},slotProps:S={},TabIndicatorProps:w={},TabScrollButtonProps:C={},textColor:k="primary",value:R,variant:_="standard",visibleScrollbar:T=!1}=n,L=s(n,RS),P="scrollable"===_,A="vertical"===b,I=A?"scrollTop":"scrollLeft",O=A?"top":"left",M=A?"bottom":"right",N=A?"clientHeight":"clientWidth",z=A?"height":"width",j=l({},n,{component:f,allowScrollButtonsMobile:h,indicatorColor:m,orientation:b,vertical:A,scrollButtons:y,textColor:k,variant:_,visibleScrollbar:T,fixed:!P,hideScrollbar:P&&!T,scrollableX:P&&!A,scrollableY:P&&A,centered:c&&!P,scrollButtonsHideMobile:!h}),$=(e=>{const{vertical:t,fixed:n,hideScrollbar:r,scrollableX:o,scrollableY:i,centered:a,scrollButtonsHideMobile:l,classes:s}=e;return ei({root:["root",t&&"vertical"],scroller:["scroller",n&&"fixed",r&&"hideScrollbar",o&&"scrollableX",i&&"scrollableY"],flexContainer:["flexContainer",t&&"flexContainerVertical",a&&"centered"],indicator:["indicator"],scrollButtons:["scrollButtons",l&&"scrollButtonsHideMobile"],scrollableX:[o&&"scrollableX"],hideScrollbar:[r&&"hideScrollbar"]},CS,s)})(j),D=ii({elementType:E.StartScrollButtonIcon,externalSlotProps:S.startScrollButtonIcon,ownerState:j}),B=ii({elementType:E.EndScrollButtonIcon,externalSlotProps:S.endScrollButtonIcon,ownerState:j}),[F,H]=Y.useState(!1),[U,V]=Y.useState(NS),[G,W]=Y.useState(!1),[q,K]=Y.useState(!1),[X,Q]=Y.useState(!1),[Z,J]=Y.useState({overflow:"hidden",scrollbarWidth:0}),ee=new Map,te=Y.useRef(null),ne=Y.useRef(null),re=()=>{const e=te.current;let t,n;if(e){const n=e.getBoundingClientRect();t={clientWidth:e.clientWidth,scrollLeft:e.scrollLeft,scrollTop:e.scrollTop,scrollLeftNormalized:Jo(e,o?"rtl":"ltr"),scrollWidth:e.scrollWidth,top:n.top,bottom:n.bottom,left:n.left,right:n.right}}if(e&&!1!==R){const e=ne.current.children;if(e.length>0){const t=e[ee.get(R)];n=t?t.getBoundingClientRect():null}}return{tabsMeta:t,tabMeta:n}},oe=No((()=>{const{tabsMeta:e,tabMeta:t}=re();let n,r=0;if(A)n="top",t&&e&&(r=t.top-e.top+e.scrollTop);else if(n=o?"right":"left",t&&e){const i=o?e.scrollLeftNormalized+e.clientWidth-e.scrollWidth:e.scrollLeft;r=(o?-1:1)*(t[n]-e[n]+i)}const i={[n]:r,[z]:t?t[z]:0};if(isNaN(U[n])||isNaN(U[z]))V(i);else{const e=Math.abs(U[n]-i[n]),t=Math.abs(U[z]-i[z]);(e>=1||t>=1)&&V(i)}})),ie=(e,{animation:t=!0}={})=>{t?function(e,t,n,r={},o=()=>{}){const{ease:i=gS,duration:a=300}=r;let l=null;const s=t[e];let u=!1;const c=()=>{u=!0},d=r=>{if(u)return void o(new Error("Animation cancelled"));null===l&&(l=r);const c=Math.min(1,(r-l)/a);t[e]=i(c)*(n-s)+s,c>=1?requestAnimationFrame((()=>{o(null)})):requestAnimationFrame(d)};s===n?o(new Error("Element already at target position")):requestAnimationFrame(d)}(I,te.current,e,{duration:r.transitions.duration.standard}):te.current[I]=e},ae=e=>{let t=te.current[I];A?t+=e:(t+=e*(o?-1:1),t*=o&&"reverse"===Zo()?-1:1),ie(t)},le=()=>{const e=te.current[N];let t=0;const n=Array.from(ne.current.children);for(let r=0;r<n.length;r+=1){const o=n[r];if(t+o[N]>e){0===r&&(t=e);break}t+=o[N]}return t},se=()=>{ae(-1*le())},ue=()=>{ae(le())},ce=Y.useCallback((e=>{J({overflow:null,scrollbarWidth:e})}),[]),de=No((e=>{const{tabsMeta:t,tabMeta:n}=re();if(n&&t)if(n[O]<t[O]){const r=t[I]+(n[O]-t[O]);ie(r,{animation:e})}else if(n[M]>t[M]){const r=t[I]+(n[M]-t[M]);ie(r,{animation:e})}})),pe=No((()=>{P&&!1!==y&&Q(!X)}));Y.useEffect((()=>{const e=To((()=>{te.current&&oe()}));let t;const n=n=>{n.forEach((e=>{e.removedNodes.forEach((e=>{var n;null==(n=t)||n.unobserve(e)})),e.addedNodes.forEach((e=>{var n;null==(n=t)||n.observe(e)}))})),e(),pe()},r=Po(te.current);let o;return r.addEventListener("resize",e),"undefined"!=typeof ResizeObserver&&(t=new ResizeObserver(e),Array.from(ne.current.children).forEach((e=>{t.observe(e)}))),"undefined"!=typeof MutationObserver&&(o=new MutationObserver(n),o.observe(ne.current,{childList:!0})),()=>{var n,i;e.clear(),r.removeEventListener("resize",e),null==(n=o)||n.disconnect(),null==(i=t)||i.disconnect()}}),[oe,pe]),Y.useEffect((()=>{const e=Array.from(ne.current.children),t=e.length;if("undefined"!=typeof IntersectionObserver&&t>0&&P&&!1!==y){const n=e[0],r=e[t-1],o={root:te.current,threshold:.99},i=new IntersectionObserver((e=>{W(!e[0].isIntersecting)}),o);i.observe(n);const a=new IntersectionObserver((e=>{K(!e[0].isIntersecting)}),o);return a.observe(r),()=>{i.disconnect(),a.disconnect()}}}),[P,y,X,null==d?void 0:d.length]),Y.useEffect((()=>{H(!0)}),[]),Y.useEffect((()=>{oe()})),Y.useEffect((()=>{de(NS!==U)}),[de,U]),Y.useImperativeHandle(u,(()=>({updateIndicator:oe,updateScrollButtons:pe})),[oe,pe]);const fe=vn.jsx(OS,l({},w,{className:Wr($.indicator,w.className),ownerState:j,style:l({},U,w.style)}));let he=0;const me=Y.Children.map(d,(e=>{if(!Y.isValidElement(e))return null;const t=void 0===e.props.value?he:e.props.value;ee.set(t,he);const n=t===R;return he+=1,Y.cloneElement(e,l({fullWidth:"fullWidth"===_,indicator:n&&!F&&fe,selected:n,selectionFollowsFocus:x,onChange:g,textColor:k,value:t},1!==he||!1!==R||e.props.tabIndex?{}:{tabIndex:0}))})),ge=(()=>{const e={};e.scrollbarSizeListener=P?vn.jsx(MS,{onChange:ce,className:Wr($.scrollableX,$.hideScrollbar)}):null;const t=P&&("auto"===y&&(G||q)||!0===y);return e.scrollButtonStart=t?vn.jsx(v,l({slots:{StartScrollButtonIcon:E.StartScrollButtonIcon},slotProps:{startScrollButtonIcon:D},orientation:b,direction:o?"right":"left",onClick:se,disabled:!G},C,{className:Wr($.scrollButtons,C.className)})):null,e.scrollButtonEnd=t?vn.jsx(v,l({slots:{EndScrollButtonIcon:E.EndScrollButtonIcon},slotProps:{endScrollButtonIcon:B},orientation:b,direction:o?"left":"right",onClick:ue,disabled:!q},C,{className:Wr($.scrollButtons,C.className)})):null,e})();return vn.jsxs(PS,l({className:Wr($.root,p),ownerState:j,ref:t,as:f},L,{children:[ge.scrollButtonStart,ge.scrollbarSizeListener,vn.jsxs(AS,{className:$.scroller,ownerState:j,style:{overflow:Z.overflow,[A?"margin"+(o?"Left":"Right"):"marginBottom"]:T?void 0:-Z.scrollbarWidth},ref:te,children:[vn.jsx(IS,{"aria-label":i,"aria-labelledby":a,"aria-orientation":"vertical"===b?"vertical":null,className:$.flexContainer,ownerState:j,onKeyDown:e=>{const t=ne.current,n=Lo(t).activeElement;if("tab"!==n.getAttribute("role"))return;let r="horizontal"===b?"ArrowLeft":"ArrowUp",i="horizontal"===b?"ArrowRight":"ArrowDown";switch("horizontal"===b&&o&&(r="ArrowRight",i="ArrowLeft"),e.key){case r:e.preventDefault(),LS(t,n,TS);break;case i:e.preventDefault(),LS(t,n,_S);break;case"Home":e.preventDefault(),LS(t,null,_S);break;case"End":e.preventDefault(),LS(t,null,TS)}},ref:ne,role:"tablist",children:me}),F&&fe]}),ge.scrollButtonEnd]}))}));function jS(e){return vn.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",...e,children:vn.jsx("path",{d:"m8 9 4.5-4.5L14 6l-4.5 4.5L8 12 2 6l1.5-1.5L8 9Z"})})}var $S=function({fontSize:e="medium",children:t=null,className:n=""}={}){const r="small"===e?"16px":"20px",o="small"===e?"-2px 0":void 0;return vn.jsx("i",{style:{fontSize:r,margin:o,display:"inline-block",fontStyle:"normal",lineHeight:"0",textAlign:"center",textTransform:"none",verticalAlign:"-.125em",textRendering:"optimizeLegibility",WebkitFontSmoothing:"antialiased",MozOsxFontSmoothing:"grayscale"},className:n,children:t})};function DS(e={}){return vn.jsx($S,{...e,children:vn.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",fill:"none",viewBox:"0 0 20 20",children:[vn.jsx("rect",{width:"20",height:"20",fill:"currentColor",rx:"3"}),vn.jsx("path",{fill:"#FFFFFF",fillRule:"evenodd",d:"m12.627 6.617-4.206 4.205-1.037-1.035a1.25 1.25 0 1 0-1.768 1.767l1.92 1.919a1.25 1.25 0 0 0 1.769 0l5.09-5.089a1.25 1.25 0 1 0-1.768-1.768Z",clipRule:"evenodd"})]})})}function BS(e={}){return vn.jsx($S,{fontSize:"medium",...e,children:vn.jsxs("svg",{width:"1em",height:"1em",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[vn.jsx("rect",{stroke:"none",width:"16",height:"16",rx:"8",fill:"currentColor"}),vn.jsx("path",{d:"M11 8C11 9.65685 9.65685 11 8 11C6.34315 11 5 9.65685 5 8C5 6.34315 6.34315 5 8 5C9.65685 5 11 6.34315 11 8Z",stroke:"none",fill:"white"})]})})}function FS(e){return vn.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"currentColor",...e,children:vn.jsx("path",{d:"m9.345 8 3.982 3.982a.951.951 0 0 1-1.345 1.345L8 9.345l-3.982 3.982a.951.951 0 0 1-1.345-1.345L6.655 8 2.673 4.018a.951.951 0 0 1 1.345-1.345L8 6.655l3.982-3.982a.951.951 0 1 1 1.345 1.345L9.345 8Z"})})}function HS(e={}){return vn.jsx($S,{...e,children:vn.jsx("svg",{width:"1em",height:"1em",viewBox:"0 0 16 16",version:"1.1",xmlns:"http://www.w3.org/2000/svg",children:vn.jsxs("g",{stroke:"none",strokeWidth:"1",fill:"none",fillRule:"evenodd",children:[vn.jsx("rect",{fill:"currentColor",x:"0",y:"0",width:"16",height:"16",rx:"3"}),vn.jsx("rect",{fill:"#FFFFFF",x:"4",y:"7",width:"8",height:"2",rx:"1"})]})})})}function US(e={}){return vn.jsx($S,{fontSize:"medium",...e,children:vn.jsx("svg",{width:"1em",height:"1em",viewBox:"0 0 16 16",version:"1.1",xmlns:"http://www.w3.org/2000/svg",children:vn.jsx("g",{strokeWidth:"1",fillRule:"evenodd",fillOpacity:"0.603119339",strokeOpacity:"0.146654212",children:vn.jsx("rect",{stroke:"currentStroke",fill:"currentFill",x:"0.5",y:"0.5",width:"15",height:"15",rx:"7.5"})})})})}function VS({className:e}){return vn.jsx($S,{fontSize:"small",className:e,children:vn.jsx("svg",{width:"8px",height:"14px",viewBox:"0 0 8 14",version:"1.1","aria-labelledby":"SortIcon",children:vn.jsx("g",{stroke:"none",strokeWidth:"1",fill:"none",fillRule:"evenodd",children:vn.jsx("g",{transform:"translate(-4.000000, -1.000000)",fill:"#404040",fillRule:"nonzero",children:vn.jsxs("g",{transform:"translate(4.324187, 1.300372)",children:[vn.jsx("path",{d:"M4.06624695,13.2115849 L7.28588573,9.1870364 C7.3893886,9.05765782 7.36841219,8.8688701 7.23903361,8.76536724 C7.18583969,8.72281211 7.11974654,8.69962788 7.05162509,8.69962788 L0.3,8.69962788 C0.134314575,8.69962788 -1.25807407e-14,8.83394246 -1.26010313e-14,8.99962788 C-1.26093738e-14,9.06774933 0.0231842256,9.13384248 0.0657393572,9.1870364 L3.28537814,13.2115849 C3.45788292,13.4272158 3.7725291,13.4621765 3.98816007,13.2896718 C4.01699242,13.2666059 4.04318107,13.2404172 4.06624695,13.2115849 Z",opacity:"0.300390625"}),vn.jsx("path",{d:"M4.06624695,0.187670888 L7.28588573,4.21221937 C7.3893886,4.34159795 7.36841219,4.53038566 7.23903361,4.63388852 C7.18583969,4.67644366 7.11974654,4.69962788 7.05162509,4.69962788 L0.3,4.69962788 C0.134314575,4.69962788 2.1918781e-12,4.56531331 2.19185781e-12,4.39962788 C2.19184946e-12,4.33150643 0.0231842256,4.26541328 0.0657393572,4.21221937 L3.28537814,0.187670888 C3.45788292,-0.0279600799 3.7725291,-0.0629207673 3.98816007,0.109584007 C4.01699242,0.132649888 4.04318107,0.158838536 4.06624695,0.187670888 Z"})]})})})})})}function GS(e={}){return vn.jsx($S,{...e,children:vn.jsx("svg",{width:"1em",height:"1em",viewBox:"0 0 16 16",version:"1.1",xmlns:"http://www.w3.org/2000/svg",children:vn.jsx("g",{stroke:"none",strokeWidth:"1",fill:"none",fillRule:"evenodd",children:vn.jsx("rect",{stroke:_l.GREYSCALE_0_42,fill:"currentColor",x:"0.5",y:"0.5",width:"15",height:"15",rx:"3"})})})})}const WS={MuiButtonBase:{defaultProps:{disableRipple:!0,disableTouchRipple:!0,focusVisibleClassName:"sprout-focus-visible"},styleOverrides:{root:{}}},MuiButton:{defaultProps:{color:"inherit",disableRipple:!0,focusVisibleClassName:"sprout-focus-visible"},styleOverrides:{root:{height:"32px",lineHeight:"16px",minWidth:"24px",fontSize:14,borderRadius:Il,"& > i:only-child, & > svg:only-child":{marginLeft:"-9px",marginRight:"-9px"},transition:"unset",color:"var(--sprout-common-foreground-color-default)",boxShadow:"none","&:hover":{backgroundColor:"var(--sprout-common-background-color-hover)"},"&:active":{backgroundColor:"var(--sprout-common-background-color-pressed)"},"&.Mui-disabled":{backgroundColor:"var(--sprout-common-background-color-disabled)"},"&.Mui-focusVisible":{outline:"var(--sprout-focus-border-default)",outlineOffset:"calc(var(--sprout-focus-border-default-width) / -2)",backgroundColor:"var(--sprout-focus-background-color-default)",zIndex:100}},text:{padding:"8px 16px",backgroundColor:"transparent"},textPrimary:{color:"var(--sprout-brand-primary-color-default)"},textSecondary:{color:"var(--sprout-info-color-default)"},textWarning:{color:"var(--sprout-warning-color-default)"},textError:{color:"var(--sprout-danger-color-default)"},outlined:{padding:"7px 16px",border:"var(--sprout-common-border-moderate)",backgroundColor:"var(--sprout-common-background-color-enabled)","&.Mui-focusVisible":{borderColor:"transparent"},"&:hover":{border:"var(--sprout-common-border-moderate)"}},outlinedPrimary:{borderColor:"var(--sprout-brand-primary-color-default)",color:"var(--sprout-brand-primary-color-default)","&:hover":{borderColor:"var(--sprout-brand-primary-color-default)"}},outlinedSecondary:{borderColor:"var(--sprout-info-color-default)",color:"var(--sprout-info-color-default)","&:hover":{borderColor:"var(--sprout-info-color-default)"}},outlinedWarning:{borderColor:"var(--sprout-warning-color-default)",color:"var(--sprout-warning-color-default)","&:hover":{borderColor:"var(--sprout-warning-color-default)"}},outlinedError:{borderColor:"var(--sprout-danger-color-default)",color:"var(--sprout-danger-color-default)","&:hover":{borderColor:"var(--sprout-danger-color-default)"}},contained:{color:"var(--sprout-brand-primary-color-inverse)",backgroundColor:"var(--sprout-brand-primary-color-default)",padding:"8px 16px","&:hover":{backgroundColor:"var(--sprout-brand-primary-color-hover)"},"&:active":{backgroundColor:"var(--sprout-brand-primary-color-pressed)"},"&.Mui-focusVisible":{outline:"var(--sprout-focus-border-default)",outlineOffset:"var(--sprout-focus-border-default-width)",background:"var(--sprout-brand-primary-color-focus)"}},containedError:{backgroundColor:"var(--sprout-danger-color-default)","&:hover":{backgroundColor:"var(--sprout-danger-color-hover)"},"&:active":{backgroundColor:"var(--sprout-danger-color-pressed)"},"&.Mui-focusVisible":{outlineColor:"var(--sprout-danger-color-inverse)",backgroundColor:"var(--sprout-danger-color-focus)"}},sizeSmall:{fontSize:12,height:"24px","& > svg:only-child, & > i:only-child":{marginLeft:"-7px",marginRight:"-7px"}},sizeLarge:{fontSize:16,height:"40px",lineHeight:"20px","& > i:only-child, & > svg:only-child":{marginLeft:"-9px",marginRight:"-9px"}},textSizeSmall:{padding:"4px 11px"},textSizeLarge:{padding:"10px 19px"},outlinedSizeSmall:{padding:"3px 11px"},outlinedSizeLarge:{padding:"9px 19px"},containedSizeSmall:{padding:"4px 11px"},containedSizeLarge:{padding:"10px 19px"}},variants:[]}};var YS=e=>({MuiAccordion:{styleOverrides:{root:{backgroundColor:_l.GREYSCALE_98,"&:before":{backgroundColor:"unset"},"&.Mui-expanded":{margin:"0px"}}}},MuiAccordionDetails:{styleOverrides:{root:{backgroundColor:_l.WHITE}}},MuiAccordionSummary:{defaultProps:{expandIcon:vn.jsx(jS,{"aria-hidden":"true",viewBox:"0 0 16 16",width:16,height:16})},styleOverrides:{root:{padding:"0px 12px 0px 16px",minHeight:"auto",boxShadow:`inset 0px -1px 0px 0px ${_l.GREYSCALE_0_15}`,"&.Mui-focusVisible":{borderColor:_l.MISC_FOCUS_BORDER,boxShadow:`inset 0 0 0 2px ${_l.MISC_FOCUS_BORDER}`,borderRadius:Il,backgroundColor:_l.GREYSCALE_0_03},"&.Mui-expanded":{minHeight:"auto"}},content:{overflow:"hidden",textOverflow:"ellipsis","&.Mui-expanded":{margin:"12px 0px"}}}},MuiAppBar:{defaultProps:{elevation:0},styleOverrides:{root:{flex:"0 0 48px",boxShadow:`inset 0 -1px 0 0 ${_l.GREYSCALE_0_15}`},colorPrimary:{backgroundColor:_l.WHITE,color:_l.TEXT_PRIMARY}}},MuiBadge:{styleOverrides:{badge:{height:"16px",minWidth:"16px",fontSize:"12px",padding:"0px 5px"},anchorOriginTopRightRectangular:{top:"-3px",right:"-3px"}}},MuiButtonBase:{defaultProps:{disableRipple:!0,disableTouchRipple:!0,focusVisibleClassName:"sprout-focus-visible"}},MuiButtonGroup:{defaultProps:{disableRipple:!0},styleOverrides:{root:{height:"32px",lineHeight:"16px",fontSize:14,borderRadius:Il},text:{padding:"8px 16px","&.Mui-focusVisible":{boxShadow:`0 0 0 2px ${_l.MISC_FOCUS_BORDER}`}},outlined:{padding:"7px 16px",borderColor:_l.GREYSCALE_0_15,backgroundColor:_l.GREYSCALE_100_60,"&.Mui-focusVisible":{borderColor:_l.MISC_FOCUS_BORDER,boxShadow:`0 0 0 1px ${_l.MISC_FOCUS_BORDER}`}},contained:{padding:"8px 16px",boxShadow:"none","&:hover":{boxShadow:"none"},"&:active":{boxShadow:"none"}},groupedContainedPrimary:{"&:hover":{backgroundColor:_l.GREEN_PALE},"&:active":{backgroundColor:_l.GREEN_DARK},"&.Mui-focusVisible":{borderColor:_l.GREEN_PALE,boxShadow:`0 0 0 3px ${Ro(_l.GREEN_PALE,.5)}`}},groupedContainedSecondary:{"&:hover":{backgroundColor:_l.BLUE_PALE},"&:active":{backgroundColor:_l.BLUE_DARK},"&.Mui-focusVisible":{borderColor:_l.BLUE_PALE,boxShadow:`0 0 0 3px ${Ro(_l.BLUE_PALE,.5)}`}}},variants:[{props:{size:"small"},style:{height:"24px"}},{props:{size:"large"},style:{height:"40px"}}]},MuiButton:{defaultProps:{color:"inherit",disableRipple:!0,focusVisibleClassName:"sprout-focus-visible"},styleOverrides:{root:{height:"32px",lineHeight:"16px",minWidth:"24px",fontSize:14,borderRadius:Il,"& > i:only-child, & > svg:only-child":{marginLeft:"-9px",marginRight:"-9px"}},text:{padding:"8px 16px","&:active":{backgroundColor:_l.GREYSCALE_0_10},"&.Mui-focusVisible":{boxShadow:`0 0 0 2px ${_l.MISC_FOCUS_BORDER}`}},outlined:({ownerState:e})=>({padding:"7px 16px",borderColor:_l.GREYSCALE_0_15,backgroundColor:_l.GREYSCALE_100_60,"&:active":{backgroundColor:_l.GREYSCALE_0_10},"&.Mui-focusVisible":{borderColor:_l.MISC_FOCUS_BORDER,boxShadow:`0 0 0 1px ${_l.MISC_FOCUS_BORDER}`},..."amethyst"===e.color&&{borderColor:_l.PURPLE,"&.Mui-focusVisible":{borderColor:_l.PURPLE,boxShadow:`0 0 0 3px ${Ro(_l.PURPLE_PALE,.5)}`}}}),outlinedPrimary:{borderColor:_l.GREEN,"&.Mui-focusVisible":{borderColor:_l.GREEN,boxShadow:`0 0 0 3px ${Ro(_l.GREEN_PALE,.5)}`}},outlinedSecondary:{borderColor:_l.BLUE,"&.Mui-focusVisible":{borderColor:_l.BLUE,boxShadow:`0 0 0 3px ${Ro(_l.BLUE_PALE,.5)}`}},outlinedWarning:{borderColor:_l.ORANGE,"&.Mui-focusVisible":{borderColor:_l.ORANGE,boxShadow:`0 0 0 3px ${Ro(_l.ORANGE_PALE,.5)}`}},outlinedError:{borderColor:_l.RED,"&.Mui-focusVisible":{borderColor:_l.RED,boxShadow:`0 0 0 3px ${Ro(_l.RED_PALE,.5)}`}},contained:({ownerState:e})=>({color:_l.WHITE,padding:"8px 16px",boxShadow:"none","&:hover":{boxShadow:"none"},"&:active":{boxShadow:"none"},..."amethyst"===e.color&&{"&:hover":{backgroundColor:_l.PURPLE_PALE},"&:active":{backgroundColor:_l.PURPLE_DARK},"&.Mui-focusVisible":{borderColor:_l.PURPLE_PALE,boxShadow:`0 0 0 3px ${Ro(_l.PURPLE_PALE,.5)}`}}}),containedPrimary:{"&:hover":{backgroundColor:_l.GREEN_PALE},"&:active":{backgroundColor:_l.GREEN_DARK},"&.Mui-focusVisible":{borderColor:_l.GREEN_PALE,boxShadow:`0 0 0 3px ${Ro(_l.GREEN_PALE,.5)}`}},containedSecondary:{"&:hover":{backgroundColor:_l.BLUE_PALE},"&:active":{backgroundColor:_l.BLUE_DARK},"&.Mui-focusVisible":{borderColor:_l.BLUE_PALE,boxShadow:`0 0 0 3px ${Ro(_l.BLUE_PALE,.5)}`}},containedWarning:{"&:hover":{backgroundColor:_l.ORANGE_PALE},"&:active":{backgroundColor:_l.ORANGE_DARK},"&.Mui-focusVisible":{borderColor:_l.ORANGE_PALE,boxShadow:`0 0 0 3px ${Ro(_l.ORANGE_PALE,.5)}`}},containedError:{"&:hover":{backgroundColor:_l.RED_PALE},"&:active":{backgroundColor:_l.RED_DARK},"&.Mui-focusVisible":{borderColor:_l.RED_PALE,boxShadow:`0 0 0 3px ${Ro(_l.RED_PALE,.5)}`}},sizeSmall:{fontSize:12,height:"24px","& > svg:only-child, & > i:only-child":{marginLeft:"-7px",marginRight:"-7px"}},sizeLarge:{fontSize:16,height:"40px",lineHeight:"20px","& > i:only-child, & > svg:only-child":{marginLeft:"-9px",marginRight:"-9px"}},textSizeSmall:{padding:"4px 11px"},textSizeLarge:{padding:"10px 19px"},outlinedSizeSmall:{padding:"3px 11px"},outlinedSizeLarge:{padding:"9px 19px"},containedSizeSmall:{padding:"4px 11px"},containedSizeLarge:{padding:"10px 19px"}},variants:[]},MuiCardActionArea:{styleOverrides:{root:{height:"100%","&.MuiCardActionArea-focusHighlight":{opacity:0},"&:hover":{boxShadow:"none",backgroundColor:_l.GREYSCALE_0_03,"&.MuiCardActionArea-focusHighlight":{opacity:0}},"&:active":{backgroundColor:_l.GREYSCALE_95,boxShadow:"none"},"&.Mui-focusVisible":{borderRadius:Il,boxShadow:`inset 0 0 0 2px ${_l.MISC_FOCUS_BORDER}`,"&.MuiCardActionArea-focusHighlight":{opacity:0}}}}},MuiChip:{defaultProps:{deleteIcon:vn.jsx(FS,{"aria-hidden":"true",viewBox:"0 0 16 16",width:12,height:12}),variant:"outlined"},styleOverrides:{root:{height:"24px",fontSize:Tl,borderRadius:Il,color:_l.TEXT_PRIMARY,backgroundColor:_l.GREYSCALE_100_15,"&.sprout-focus-visible":{borderColor:_l.MISC_FOCUS_BORDER,boxShadow:`0px 0px 0px 1px ${_l.MISC_FOCUS_BORDER}`},"&.Mui-focusVisible":{backgroundColor:_l.GREYSCALE_0_03},"&.Mui-disabled":{backgroundColor:_l.GREYSCALE_0_05,color:_l.GREYSCALE_0_30,border:"none",opacity:1},"&.MuiChip-outlinedSuccess":{color:_l.GREEN,borderColor:_l.GREEN},"&.MuiChip-outlinedInfo":{color:_l.BLUE,borderColor:_l.BLUE},"&.MuiChip-outlinedWarning":{color:_l.ORANGE,borderColor:_l.ORANGE},"&.MuiChip-outlinedError":{color:_l.RED,borderColor:_l.RED}},outlined:{border:`solid 1px ${_l.GREYSCALE_0_15}`,backgroundColor:_l.GREYSCALE_100_15,".MuiChip-clickable&:active ":{boxSizing:"border-box",borderRadius:Il,boxShadow:"none",backgroundColor:_l.GREYSCALE_0_10},"&.MuiChip-deleteIconSmall":{height:13,color:"inherit"}},outlinedPrimary:{color:_l.GREEN,borderColor:_l.GREEN},outlinedSecondary:{color:_l.BLUE,borderColor:_l.BLUE},label:{fontFamily:jl.FONT_FAMILY,lineHeight:"16px"}}},MuiAutocomplete:{defaultProps:{clearIcon:vn.jsx(FS,{"aria-hidden":"true",viewBox:"0 0 16 16",height:12,width:12}),popupIcon:vn.jsx(jS,{"aria-hidden":"true",viewBox:"0 0 16 16",width:12,height:12}),forcePopupIcon:!0},styleOverrides:{root:{"& .MuiAutocomplete-endAdornment > button":{border:"none",backgroundColor:"unset"}},input:{"&.MuiAutocomplete-input":{padding:"6px 4px"}},inputRoot:{padding:"0px 2px",boxSizing:"border-box",borderRadius:Il},listbox:{padding:"0","& .MuiAutocomplete-option":{height:"32px",minHeight:"32px"}},option:{borderRadius:Il,fontSize:Ll,height:"32px",padding:"6px 16px",minHeight:"32px","&.MuiAutocomplete-option.Mui-focused":{backgroundColor:_l.GREYSCALE_0_03,"&.Mui-focusVisible":{border:`solid 2px ${_l.MISC_FOCUS_BORDER}`,padding:"4px 14px"}},'&.MuiAutocomplete-option[aria-selected="true"]':{backgroundColor:_l.GREYSCALE_0_05,"&.Mui-focused":{backgroundColor:_l.GREYSCALE_0_05},"&.Mui-focusVisible":{backgroundColor:_l.GREYSCALE_0_05}}},popupIndicator:{borderRadius:Il,border:`solid 1px ${_l.GREYSCALE_0_15}`,color:_l.GREYSCALE_0_60,marginRight:0,width:Al,height:Al},paper:{marginTop:"4px",boxShadow:`0px 2px 4px 0px ${_l.GREYSCALE_0_15}`},clearIndicator:{borderRadius:Il,marginRight:"4px"},popupIndicatorOpen:{backgroundColor:_l.GREYSCALE_0_10}}},MuiFormControlLabel:{styleOverrides:{root:{marginLeft:"-10px"},label:{fontSize:Ll}}},MuiFormHelperText:{styleOverrides:{root:{fontSize:Tl,lineHeight:"16px",margin:"4px 0 0 0","&.Mui-error":{color:_l.RED}},contained:{marginLeft:0,marginRight:0}}},MuiFormLabel:{styleOverrides:{root:{color:_l.GREYSCALE_25,fontSize:Tl,fontFamily:jl.FONT_FAMILY,fontWeight:Nl,fontStretch:"normal",fontStyle:"normal",letterSpacing:"normal",lineHeight:1,"&.Mui-focused":{color:_l.TEXT_PRIMARY},"&.Mui-error":{color:_l.TEXT_SECONDARY},"&[optional=true]":{"&:after":{color:_l.TEXT_SECONDARY,content:"'(optional)'",fontWeight:Ml,marginLeft:"4px"}}},asterisk:{visibility:"collapse",display:"inline-flex","&::after":{visibility:"visible",color:_l.TEXT_SECONDARY,content:"'(required)'",fontWeight:Ml,marginLeft:"4px"}}}},MuiOutlinedInput:{defaultProps:{notched:!1},styleOverrides:{root:{fontSize:Ll,lineHeight:"16px",backgroundColor:_l.WHITE,borderRadius:Il,"&:not(.Mui-focused):not(.Mui-error):not(.Mui-disabled):hover .MuiOutlinedInput-notchedOutline":{border:`solid 1px ${_l.GREYSCALE_0_05}`,borderColor:_l.GREYSCALE_0_30},"&.Mui-focused:not(.Mui-error) .MuiOutlinedInput-notchedOutline":{border:`solid 1px ${_l.MISC_FOCUS_BORDER}`,boxShadow:`0px 0px 0px 1px ${_l.MISC_FOCUS_BORDER}, inset 0 2px 0 0 ${_l.GREYSCALE_0_05}`},"&.Mui-focused.Mui-error .MuiOutlinedInput-notchedOutline":{border:`solid 1px ${_l.RED}`,boxShadow:`0px 0px 0px 1px ${_l.RED}, inset 0 2px 0 0 ${_l.GREYSCALE_0_05}`},"&.Mui-disabled":{backgroundColor:"transparent"},"&.Mui-disabled .MuiOutlinedInput-notchedOutline":{border:`solid 1px ${_l.GREYSCALE_0_10}`,borderColor:_l.GREYSCALE_0_10,backgroundColor:_l.GREYSCALE_0_05}},adornedStart:{paddingLeft:0},adornedEnd:{paddingRight:0},input:{color:_l.TEXT_PRIMARY,padding:"6px 12px","&.Mui-disabled":{opacity:.45}},inputSizeSmall:{padding:"0px 12px"},notchedOutline:{borderColor:_l.GREYSCALE_0_15,borderRadius:Il,boxShadow:`inset 0 2px 0 0 ${_l.GREYSCALE_0_05}`},multiline:{padding:"0"}}},MuiSelect:{defaultProps:{IconComponent:e=>vn.jsx(jS,{...e,"aria-hidden":"true",viewBox:"0 0 16 16",width:12,height:12}),MenuProps:{anchorOrigin:{vertical:"bottom",horizontal:"left"},transformOrigin:{vertical:"top",horizontal:"left"}}},styleOverrides:{select:{padding:"7px 12px",borderRadius:"3px !important",minHeight:"1em","& em":{color:_l.TEXT_SECONDARY},"& ~svg":{position:"absolute",right:"12px",top:"unset",cursor:"pointer"},"&[aria-expanded=true]":{backgroundColor:_l.GREYSCALE_0_05},"& ~fieldset":{boxShadow:"none !important",border:"none !important",backgroundColor:"unset !important"},"&:hover":{backgroundColor:_l.GREYSCALE_0_03},"&:active":{backgroundColor:_l.GREYSCALE_0_10},"&:focus":{backgroundColor:_l.GREYSCALE_0_03,borderRadius:"3px !important",border:`solid 1px ${_l.MISC_FOCUS_BORDER}`,boxShadow:`inset 0px 0px 0px 1px ${_l.MISC_FOCUS_BORDER}`},"&.Mui-disabled":{opacity:"unset",color:_l.GREYSCALE_0_30,"&:hover":{backgroundColor:_l.GREYSCALE_0_0,borderColor:_l.GREYSCALE_0_15},"& ~svg":{color:_l.GREYSCALE_0_30}}},outlined:{border:`solid 1px ${_l.GREYSCALE_0_15}`},nativeInput:{height:"42px"}}},MuiIconButton:{styleOverrides:{root:{borderRadius:Il}}},MuiInput:{styleOverrides:{root:{"&.Mui-focused":{borderColor:_l.MISC_FOCUS_BORDER,boxShadow:`0 0 0 2px ${_l.MISC_FOCUS_BORDER}`}}}},MuiInputAdornment:{styleOverrides:{root:{padding:"4px 8px",color:_l.GREYSCALE_55},positionStart:{marginRight:0},positionEnd:{marginLeft:0}}},MuiInputBase:{styleOverrides:{root:{fieldset:{boxShadow:"none"}},input:{height:"20px",fontSize:Ll,padding:"8px 12px",lineHeight:"16px","&.MuiInputBase-inputAdornedStart":{paddingLeft:0},"&.MuiInputBase-inputAdornedEnd":{paddingRight:0}},sizeSmall:{height:"24px",input:{fontSize:Tl,paddingLeft:"8px"}}}},MuiInputLabel:{defaultProps:{shrink:!0},styleOverrides:{outlined:{fontSize:Tl,fontWeight:Nl,color:_l.GREYSCALE_25,"&.MuiInputLabel-shrink":{transform:"translate(0px, -16px)",fontWeight:Nl}}}},MuiPopover:{styleOverrides:{paper:{minWidth:"160px",top:"60px",marginTop:"5px","&ul":{padding:"0px"},boxShadow:`0px 4px 10px ${_l.GREYSCALE_0_15}, 0px 0px 0px 1px ${_l.GREYSCALE_0_05}`}}},MuiRadio:{defaultProps:{size:"small",icon:vn.jsx(US,{}),checkedIcon:vn.jsx(BS,{})},styleOverrides:{root:{"&:hover":{backgroundColor:"unset"},fill:_l.GREYSCALE_100_60,stroke:"black","&.sprout-focus-visible":{borderColor:"transparent",boxShadow:"none"},"&.sprout-focus-visible i":{borderRadius:"50%",boxShadow:`0 0 0 2px ${_l.MISC_FOCUS_BORDER}`},"&.Mui-checked":{"&.MuiRadio-colorPrimary":{"&.sprout-focus-visible i":{borderColor:_l.GREEN_PALE,boxShadow:`0 0 0 3px ${Ro(_l.GREEN_PALE,.5)}`}},"&.MuiRadio-colorSecondary":{"&.sprout-focus-visible i":{borderColor:_l.BLUE_PALE,boxShadow:`0 0 0 3px ${Ro(_l.BLUE_PALE,.5)}`}},"&.Mui-disabled":{color:_l.GREYSCALE_0_20}},"&.Mui-disabled":{fill:_l.GREYSCALE_0_20,stroke:"none"}}}},MuiCheckbox:{defaultProps:{size:"small",icon:vn.jsx(GS,{}),checkedIcon:vn.jsx(DS,{}),indeterminateIcon:vn.jsx(HS,{})},styleOverrides:{root:{borderWidth:1,"&:hover":{backgroundColor:"unset"},"&.sprout-focus-visible":{borderColor:"transparent",boxShadow:"none"},"&.sprout-focus-visible i":{borderRadius:Il,boxShadow:" 0px 0px 0px 2px #FFFFFF, 0px 0px 0px 4px #177FE6"},"&:not(.Mui-disabled)":{"&:not(.Mui-checked)":{"&:not(.MuiCheckbox-indeterminate)":{color:_l.GREYSCALE_100_60,"&:hover":{g:{rect:{stroke:_l.GREYSCALE_0_55,color:_l.GREYSCALE_0_03}}},"&.sprout-focus-visible i":{boxShadow:"0px 0px 0px 2px #0275D9",g:{rect:{stroke:"none"}}}}}},"&.Mui-disabled":{"& i":{pointerEvents:"auto",cursor:"not-allowed !important",color:_l.GREYSCALE_0_15,g:{rect:{stroke:"none"}}}}},colorPrimary:{"&.MuiCheckbox-root":{"&:not(.Mui-disabled)":{"&:hover":{color:_l.GREEN_DARK}}}},colorSecondary:{"&.MuiCheckbox-root":{"&:not(.Mui-disabled)":{color:_l.GREYSCALE_0_55,"&:hover":{color:_l.GREYSCALE_25}}}}}},MuiCircularProgress:{defaultProps:{thickness:3,disableShrink:!0}},MuiDialog:{defaultProps:{fullWidth:!0}},MuiDialogActions:{styleOverrides:{root:{padding:"16px"}}},MuiDialogTitle:{styleOverrides:{root:{display:"flex",alignItems:"center",justifyContent:"space-between",boxSizing:"content-box",minHeight:"31px",padding:"16px 16px 16px 24px",fontSize:"16px",lineHeight:"24px"}}},MuiDialogContentText:{defaultProps:{variant:"body2"},styleOverrides:{root:{marginBottom:0}}},MuiDialogContent:{styleOverrides:{root:{padding:"16px 24px !important"}}},MuiDivider:{styleOverrides:{middle:{margin:"4px 8px"}}},MuiLink:{defaultProps:{underline:"none",color:_l.MISC_FOCUS_BORDER}},MuiListItemIcon:{styleOverrides:{root:{color:_l.GREYSCALE_25,minWidth:"16px",marginRight:"16px"}}},MuiListItemText:{styleOverrides:{root:{fontSize:"12px"},primary:{fontSize:Ll,color:_l.TEXT_PRIMARY,lineHeight:"16px",fontWeight:Nl},secondary:{fontSize:Tl,color:_l.GREYSCALE_45,fontWeight:Ml,lineHeight:"16px"}}},MuiListItem:{styleOverrides:{root:{fontSize:Ll,minHeight:"32px"},gutters:{paddingLeft:"12px",paddingRight:"12px"}}},MuiListItemButton:{styleOverrides:{root:{fontSize:Ll,height:"32px"}}},MuiListSubheader:{styleOverrides:{root:{'&[role="option"]':{color:_l.TEXT_PRIMARY,lineHeight:1.33,padding:"4px 12px",fontWeight:600,fontSize:Tl,borderBottom:`solid 1px ${_l.GREYSCALE_0_15}`,pointerEvents:"none"}}}},MuiList:{styleOverrides:{padding:{paddingTop:"0px",paddingBottom:"0px"}}},MuiMenuItem:{styleOverrides:{root:{fontSize:Ll,color:_l.GREYSCALE_25,height:"32px",'[class*="MuiListItemIcon-root"]':{minWidth:"16px"},"&:hover":{backgroundColor:_l.GREYSCALE_0_03},"&.Mui-selected":{backgroundColor:"unset","&:hover":{backgroundColor:_l.GREYSCALE_0_10},"&.Mui-focusVisible":{backgroundColor:_l.GREYSCALE_0_10},"&:not(.Mui-disabled)":{"&::after":{content:'url(\'data:image/svg+xml,<?xml version="1.0" encoding="UTF-8"?>%0A<svg width="8px" height="7px" viewBox="0 0 8 7" version="1.1"%0A xmlns="http://www.w3.org/2000/svg"%0A xmlns:xlink="http://www.w3.org/1999/xlink" aria-labelledby="Tick">%0A <g stroke="none" stroke-width="1" fill-rule="evenodd">%0A <g transform="translate(0.000000, -1.000000)">%0A <path d="M7.51662484,1.29325 C7.12545778,0.90225 6.49218732,0.90225 6.10202068,1.29325 L2.73658335,4.65725 L1.90722914,3.82925 C1.5170625,3.43825 0.883792042,3.43825 0.492624979,3.82925 C0.102458344,4.21925 0.102458344,4.85225 0.492624979,5.24325 L2.02928127,6.77825 C2.4194479,7.16925 3.05271836,7.16925 3.44388542,6.77825 L7.51662484,2.70725 C7.9077919,2.31725 7.9077919,1.68425 7.51662484,1.29325"></path>%0A </g>%0A </g>%0A</svg>%0A\')',fontFamily:"LUI icons",position:"absolute",fontSize:"10px",right:"10px",color:_l.RED}}},"&.Mui-focusVisible":{backgroundColor:_l.GREYSCALE_0_03}},divider:{marginTop:"8px",marginBottom:"8px"},gutters:{paddingLeft:"12px",paddingRight:"12px"}}},MuiMenu:{styleOverrides:{list:{paddingTop:"4px",paddingBottom:"4px"},paper:{marginTop:"4px !important",marginBottom:"4px",background:_l.WHITE,boxShadow:"0 0 0 1px rgba(0,0,0,0.05), 0 4px 10px 0 rgba(0,0,0,0.15) !important",borderRadius:"2px !important"}}},MuiSlider:{styleOverrides:{root:{color:_l.GREEN,height:"24px","&.Mui-disabled":{color:_l.GREYSCALE_0_15}},rail:{backgroundColor:_l.GREYSCALE_0_05,height:"4px",opacity:"1",border:`solid 1px ${_l.GREYSCALE_0_05}`,borderRadius:Il,boxShadow:`inset 0px 0px 0px 1px ${_l.GREYSCALE_0_05}`},track:{height:"4px",backgroundColor:"currentColor",opacity:"1",border:`solid 1px ${_l.GREYSCALE_0_05}`,borderRadius:Il},thumb:{height:"16px",width:"16px",borderRadius:Il,backgroundColor:_l.WHITE,boxShadow:`0px 1px 2px 0px ${_l.GREYSCALE_0_15}, 0px 0px 0px 1px ${_l.GREYSCALE_0_05}`,"&:hover":{borderRadius:Il,boxShadow:`0 2px 4px 0 ${_l.GREYSCALE_0_30}, 0 0 0 1px ${_l.GREYSCALE_0_06}`},"&:focus":{boxShadow:`0 1px 2px 0 ${_l.GREYSCALE_0_15}, 0 0 0 1px ${_l.GREYSCALE_0_06}, 0 0 0 2px ${_l.MISC_FOCUS_BORDER}`},"&.Mui-focusVisible":{boxShadow:`0 1px 2px 0 ${_l.GREYSCALE_0_15}, 0 0 0 1px ${_l.GREYSCALE_0_06}, 0 0 0 2px ${_l.MISC_FOCUS_BORDER}`},"&.Mui-disabled":{width:"16px",height:"16px",marginTop:"-5px",marginLeft:"-8px",backgroundColor:_l.GREYSCALE_90},"& .custom-bar":{height:"8px",width:"1px",backgroundColor:_l.GREYSCALE_0_30,marginLeft:1,marginRight:1}},mark:{width:"1px",height:"4px",margin:"16px 0px 0px 0px",backgroundColor:_l.GREYSCALE_0_15},markActive:{opacity:1,backgroundColor:_l.GREYSCALE_0_15},markLabel:{color:_l.TEXT_SECONDARY,transform:"translateX(-50%)",top:"35px"},markLabelActive:{color:_l.TEXT_SECONDARY,transform:"translateX(-50%)",top:"35px"}}},MuiSnackbar:{defaultProps:{anchorOrigin:{vertical:"bottom",horizontal:"center"}}},MuiSnackbarContent:{styleOverrides:{root:{backgroundColor:_l.WHITE,color:_l.GREYSCALE_25}}},MuiSwitch:{defaultProps:{color:"primary",size:"small"},styleOverrides:{root:{padding:"10px",width:"60px",height:"40px","& .MuiSwitch-switchBase":{"&:hover":{backgroundColor:"unset"},"&.Mui-checked":{"&:hover":{backgroundColor:"unset"}}}},switchBase:{padding:"12px","&.Mui-disabled":{"&.MuiSwitch-thumb":{backgroundColor:_l.GREYSCALE_100_50}},"&.Mui-checked + .MuiSwitch-track":{opacity:1},"&.Mui-disabled + .MuiSwitch-track":{opacity:.12},"&.sprout-focus-visible":{borderColor:"transparent",boxShadow:"none"}},colorPrimary:{"&.sprout-focus-visible + .MuiSwitch-track":{borderColor:_l.GREEN_PALE,boxShadow:`0 0 0 3px ${Ro(_l.GREEN_PALE,.5)}`}},colorSecondary:{"&.sprout-focus-visible + .MuiSwitch-track":{borderColor:_l.BLUE_PALE,boxShadow:`0 0 0 3px ${Ro(_l.BLUE_PALE,.5)}`}},track:{opacity:1,backgroundColor:_l.GREYSCALE_0_15,borderRadius:Il},thumb:{height:"16px",width:"16px",borderRadius:Il,backgroundColor:_l.GREYSCALE_100},sizeSmall:{height:"32px",width:"52px",padding:"8px 10px","& .MuiSwitch-thumb":{height:"12px",width:"12px"},"& .MuiSwitch-switchBase":{padding:"10px 12px"}}}},MuiTextField:{defaultProps:{margin:"dense",variant:"outlined"},styleOverrides:{root:{marginBottom:0}}},MuiTab:{styleOverrides:{root:{fontSize:Ll,fontWeight:Nl,textTransform:"none",minWidth:"auto",boxSizing:"border-box",paddingBottom:"12px","&:hover":{borderBottom:`2px solid ${_l.GREYSCALE_80}`,paddingBottom:"10px"},"&.sprout-focus-visible":{boxShadow:`inset 0 0 0 2px ${_l.MISC_FOCUS_BORDER}`,backgroundColor:_l.GREYSCALE_0_03,borderRadius:Il},"&.Mui-disabled":{opacity:.3}},textColorPrimary:{color:_l.GREYSCALE_25,"&.Mui-selected":{color:_l.GREYSCALE_25}},textColorInherit:{opacity:"unset"},labelIcon:{minWidth:"40px",minHeight:"48px"}}},MuiTabs:{defaultProps:{indicatorColor:"primary",textColor:"primary"},styleOverrides:{root:{fontSize:Ll,fontWeight:"bold"},scroller:{height:"100%"},flexContainer:{"&:not(.MuiTabs-flexContainerVertical)":{height:"100%",marginLeft:2,marginRight:2}},indicator:{height:2},scrollButtons:{borderRadius:Il,"&:hover":{backgroundColor:_l.GREYSCALE_0_03},"&.Mui-disabled":{opacity:"unset","& .MuiSvgIcon-root":{opacity:.3}}},vertical:{padding:"8px",boxSizing:"border-box","& .MuiTabs-indicator":{left:0,right:"unset",transition:"none",clipPath:"inset(12px 0 12px 0)",marginLeft:"1px"},"& .MuiTabs-scrollButtons":{flexDirection:"column",position:"relative","&:first-child":{marginBottom:"4px","&::before":{content:'""',display:"block",width:"100%",height:"1px",borderBottom:`1px solid ${_l.GREYSCALE_0_15}`,position:"absolute",bottom:0,left:0}},"&:last-child":{marginTop:"4px","&::before":{content:'""',display:"block",width:"100%",height:"1px",borderBottom:`1px solid ${_l.GREYSCALE_0_15}`,position:"absolute",top:0,left:0}}},"& .MuiTab-root":{fontWeight:"normal",borderRadius:Il,marginBlock:"4px","&:first-child":{marginTop:"0px"},"&:last-child":{marginBottom:"0px"},"&.Mui-selected":{backgroundColor:_l.GREYSCALE_0_05},"&:hover":{backgroundColor:_l.GREYSCALE_0_03,borderBottomColor:"transparent"}}}}},MuiTableCell:{styleOverrides:{root:{padding:"0px 8px 0px 16px",borderBottom:`1px solid ${_l.GREYSCALE_85}`,borderRight:`1px solid ${_l.GREYSCALE_85}`,height:"39px"},head:{height:"41px",fontWeight:Nl,backgroundColor:_l.GREYSCALE_98},paddingCheckbox:{width:"40px",padding:"0px"},paddingNone:{padding:"0px"},sizeSmall:{padding:"0px 8px",height:"29px","&.MuiTableCell-head":{height:"31px"},"&.MuiTableCell-paddingCheckbox":{width:"40px",padding:"0px"}},stickyHeader:{backgroundColor:_l.GREYSCALE_98,borderBottom:`1px solid ${_l.GREYSCALE_85}`}}},MuiTableContainer:{styleOverrides:{root:{borderBottom:`1px solid ${_l.GREYSCALE_85}`,borderTop:`1px solid ${_l.GREYSCALE_85}`}}},MuiTableHead:{styleOverrides:{root:{backgroundColor:_l.GREYSCALE_98}}},MuiTableRow:{styleOverrides:{root:{"&.Mui-selected":{backgroundColor:_l.GREYSCALE_0_05,"&:hover":{backgroundColor:_l.GREYSCALE_0_03}},"&&:hover":{backgroundColor:_l.GREYSCALE_0_03}}}},MuiTableSortLabel:{defaultProps:{IconComponent:({className:e})=>vn.jsx(VS,{className:e})},styleOverrides:{root:{display:"flex",justifyContent:"space-between","&:hover":{"& icon":{opacity:.5}},"&.Mui-active":{"&& icon":{opacity:1}}},icon:{opacity:0},iconDirectionDesc:{transform:"rotate(180deg)"},iconDirectionAsc:{transform:"rotate(0deg)"}}},MuiTable:{styleOverrides:{root:{borderLeft:`1px solid ${_l.GREYSCALE_85}`}}},MuiToggleButton:{styleOverrides:{root:{height:32,lineHeight:"16px",width:32,fontSize:Ll,borderRadius:Il,padding:"7px 16px",border:`1px solid ${_l.GREYSCALE_0_15}`,backgroundColor:_l.GREYSCALE_100_60,color:_l.GREYSCALE_25,zIndex:1,"&:active":{backgroundColor:_l.GREYSCALE_0_10,border:`1px solid ${_l.GREYSCALE_0_30}`},"&:hover":{backgroundColor:_l.GREYSCALE_0_03,border:`1px solid ${_l.GREYSCALE_0_30}`},"&.sprout-focus-visible":{backgroundColor:_l.GREYSCALE_0_03,boxShadow:`0 0 0 1px ${_l.MISC_FOCUS_BORDER}`,border:`1px solid ${_l.MISC_FOCUS_BORDER}`,zIndex:2},"&.Mui-selected":{color:_l.GREYSCALE_25,backgroundColor:_l.GREYSCALE_0_10,zIndex:2,"&:hover":{backgroundColor:_l.GREYSCALE_0_10,border:`1px solid ${_l.GREYSCALE_0_15}`}}},sizeSmall:{fontSize:Tl,height:24,width:24,padding:7},sizeLarge:{fontSize:Pl,height:40,width:40,lineHeight:"20px"}}},MuiToggleButtonGroup:{styleOverrides:{root:{height:"32px",lineHeight:"16px",fontSize:Ll,borderRadius:Il}}},MuiToolbar:{defaultProps:{disableGutters:!0},styleOverrides:{root:{display:"flex",flex:1,padding:"0 16px"},dense:{minHeight:"46px",padding:"0 8px"}}},MuiTooltip:{defaultProps:{arrow:!0,enterNextDelay:300,enterDelay:400},styleOverrides:{arrow:{color:_l.GREYSCALE_20},tooltip:{backgroundColor:_l.GREYSCALE_20,fontSize:Tl,lineHeight:"16px"},popper:{whiteSpace:"pre-line"}}},...e?{...WS}:{}});var qS=()=>({mode:"light",primary:{ultraLight:_l.GREEN_ULTRA_LIGHT,light:_l.GREEN_PALE,main:_l.GREEN,dark:_l.GREEN_DARK,extraDark:_l.GREEN_EXTRA_DARK,contrastText:_l.WHITE},secondary:{ultraLight:_l.BLUE_ULTRA_LIGHT,light:_l.BLUE_PALE,main:_l.BLUE,dark:_l.BLUE_DARK,extraDark:_l.BLUE_EXTRA_DARK,contrastText:_l.WHITE},error:{ultraLight:_l.RED_ULTRA_LIGHT,light:_l.RED_PALE,main:_l.RED,dark:_l.RED_DARK,extraDark:_l.RED_EXTRA_DARK,contrastText:_l.WHITE},warning:{ultraLight:_l.ORANGE_ULTRA_LIGHT,light:_l.ORANGE_PALE,main:_l.ORANGE,dark:_l.ORANGE_DARK,extraDark:_l.ORANGE_EXTRA_DARK,contrastText:_l.WHITE},success:{ultraLight:_l.GREEN_ULTRA_LIGHT,light:_l.GREEN_PALE,main:_l.GREEN,dark:_l.GREEN_DARK,extraDark:_l.GREEN_EXTRA_DARK,contrastText:_l.WHITE},info:{ultraLight:_l.BLUE_ULTRA_LIGHT,light:_l.BLUE_PALE,main:_l.BLUE,dark:_l.BLUE_DARK,extraDark:_l.BLUE_EXTRA_DARK,contrastText:_l.WHITE},text:{primary:_l.TEXT_PRIMARY,secondary:_l.TEXT_SECONDARY,disabled:_l.GREYSCALE_0_30},action:{hover:_l.GREYSCALE_0_03,hoverOpacity:.03,selected:_l.GREYSCALE_0_05,selectedOpacity:.05,focus:_l.MISC_FOCUS_BORDER},amethyst:{ultraLight:_l.WHITE,main:_l.PURPLE,light:_l.PURPLE_PALE,dark:_l.PURPLE_DARK,extraDark:_l.GREYSCALE_0_0,contrastText:_l.WHITE},background:{paper:_l.WHITE,default:_l.GREYSCALE_95},divider:_l.GREYSCALE_0_15});var KS=e=>qS();var XS=(e,t=!1)=>{const n=((e,t)=>YS(t))(0,t);return{components:n,palette:KS(e),breakpoints:{keys:["xs","sm","md","lg","xl"],values:{xs:0,sm:600,md:960,lg:1280,xl:1920}},spacing:8,shadows:["none","0px 1px 2px 0px rgba(0,0,0,0.15)","0px 1px 2px 0px rgba(0,0,0,0.15)","0px 1px 2px 0px rgba(0,0,0,0.15)","0px 1px 2px 0px rgba(0,0,0,0.15)","0px 1px 2px 0px rgba(0,0,0,0.15)","0px 1px 2px 0px rgba(0,0,0,0.15)","0px 2px 4px 0px rgba(0,0,0,0.15)","0px 2px 4px 0px rgba(0,0,0,0.15)","0px 2px 4px 0px rgba(0,0,0,0.15)","0px 2px 4px 0px rgba(0,0,0,0.15)","0px 2px 4px 0px rgba(0,0,0,0.15)","0px 2px 4px 0px rgba(0,0,0,0.15)","0px 4px 10px 0px rgba(0,0,0,0.15)","0px 4px 10px 0px rgba(0,0,0,0.15)","0px 4px 10px 0px rgba(0,0,0,0.15)","0px 4px 10px 0px rgba(0,0,0,0.15)","0px 4px 10px 0px rgba(0,0,0,0.15)","0px 4px 10px 0px rgba(0,0,0,0.15)","0px 6px 20px 0px rgba(0,0,0,0.15)","0px 6px 20px 0px rgba(0,0,0,0.15)","0px 6px 20px 0px rgba(0,0,0,0.15)","0px 6px 20px 0px rgba(0,0,0,0.15)","0px 6px 20px 0px rgba(0,0,0,0.15)","0px 6px 20px 0px rgba(0,0,0,0.15)"],transitions:{easing:{easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},duration:{standard:300,short:250,enteringScreen:225,shorter:200,leavingScreen:195,shortest:150,complex:375}},typography:{fontSize:Ll,fontWeightLight:Ol,fontWeightRegular:Ml,fontWeightMedium:Nl,fontWeightBold:zl,htmlFontSize:Ll,fontFamily:jl.FONT_FAMILY,button:{fontWeight:Nl,fontSize:Ll,textTransform:"none"},body1:{fontSize:Pl,lineHeight:"24px"},body2:{fontSize:Ll,lineHeight:"20px"},h1:{fontSize:32,lineHeight:"32px"},h2:{fontSize:28,lineHeight:"32px"},h3:{fontSize:Al,lineHeight:"24px"},h4:{fontSize:20,lineHeight:"24px"},h5:{fontSize:Pl,fontWeight:Nl,lineHeight:"16px"},h6:{fontSize:Ll,fontWeight:Nl,lineHeight:"16px"},caption:{color:_l.TEXT_SECONDARY},subtitle1:{fontSize:Ll,color:_l.TEXT_SECONDARY},subtitle2:{fontSize:Tl,color:_l.TEXT_SECONDARY}},shape:{borderRadius:Il}}};function QS(e){return Ua({...XS("light"),direction:e})}class ZS{constructor({translator:e}){r(this,"translator",void 0),r(this,"muiTheme",void 0),r(this,"containers",{}),r(this,"sync",(({element:e,sharedContainerUtilities:t,translator:n,containerId:r,dataHandler:o,renderHelper:i})=>{this.translator=n,this.containers[r]={element:e,sharedContainerUtilities:t,dataHandler:o,renderHelper:i}})),r(this,"setMuiTheme",(e=>{this.muiTheme=QS(e)})),r(this,"destroy",(e=>{delete this.containers[e]})),this.translator=e}}const JS=["container","sn-layout-container","sn-tabbed-container","listbox","qlik-tabbed-container","qlik-show-hide-container","qlik-trellis-container","qlik-on-demand-reporting","sn-analysis-autochart"];class ew{constructor(e,t){r(this,"embed",void 0),r(this,"translator",void 0),r(this,"charts",{}),r(this,"getCharts",(()=>{var e;return this.charts=(null===(e=this.embed)||void 0===e?void 0:e.getRegisteredTypes()).reduce(((e,t)=>{var n,r;if(!(JS.includes(t.id)||!1===(null===(n=t.libraryInfo)||void 0===n?void 0:n.isLibraryItem)||null!==(r=t.libraryInfo)&&void 0!==r&&r.deprecated)){var o;const n=t;null!==(o=n.libraryInfo)&&void 0!==o&&o.translationKey&&(n.libraryInfo.translation=this.translator.get(n.libraryInfo.translationKey)),e[t.id||t.type]=n}return e}),{}),this.charts})),r(this,"getChart",(e=>(this.charts[e]||this.getCharts(),this.charts[e]))),this.embed=e,this.translator=t}}var tw,nw=Qv;tw=nw.createRoot,nw.hydrateRoot;const rw=(e,t)=>vn.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 16 16",height:"16px",fill:"currentColor","aria-hidden":"true",role:"img",ref:t,...e,children:vn.jsx("path",{d:"M9.057 11.164a6 6 0 1 1 2.112-2.116 1 1 0 0 1 .052.044l4.176 4.08a1 1 0 0 1 .009 1.422l-.707.707a1 1 0 0 1-1.406.008l-4.185-4.087a1 1 0 0 1-.05-.058ZM10.5 6a4.5 4.5 0 1 0-9 0 4.5 4.5 0 0 0 9 0"})}),ow=Y.forwardRef(rw),iw="rgb(89, 89, 89)",aw=sn(mx)({display:"flex",justifyContent:"center",alignItems:"center",flexDirection:"column"}),lw=sn(mx)({display:"flex",justifyContent:"center",alignItems:"center",height:"100%"}),sw=sn(uE,{shouldForwardProp:e=>"width"!==e})((({width:e})=>({"&.MuiList-root":{paddingTop:0,paddingBottom:0,width:e||250,maxHeight:250,overflow:"auto"}}))),uw=sn(Hy)({color:iw,fontSize:"12px",fontFamily:"inherit",lineHeight:"24px",margin:"0px"}),cw=sn(PE)({"&.MuiListItemIcon-root":{minWidth:32,color:iw,marginRight:"0px"}}),dw=sn(Yx)({"&.MuiDivider-root":{borderBottom:"3px solid #595959"}}),pw=sn(kx)({"&.MuiButton-contained":{backgroundColor:iw,color:"rgb(255, 255, 255)"},"&.MuiButton-outlined":{backgroundColor:"rgb(255, 255, 255)",borderColor:iw,color:iw,border:"1px solid rgb(179, 179, 179)","&:hover":{backgroundColor:"rgb(255, 255, 255)",border:`1px solid ${iw}`}}}),fw=sn(Hl)({width:"1em",height:"1em",paddingBottom:"8px"}),hw=sn(Hl)({width:"16px",height:"16px"}),mw=({name:e,items:t,onSelect:n})=>q.createElement(q.Fragment,null,q.createElement(kE,{key:e,dense:!0},q.createElement(uw,{noWrap:!0,fontWeight:"bold"},e)),q.createElement(dw,null),t.map((e=>{var t;return q.createElement(kE,{key:null!==(t=e.qExtendsId)&&void 0!==t?t:e.name,divider:!0,disablePadding:!0,disableGutters:!0},q.createElement(gE,{sx:{minHeight:"32px",height:"auto"},onClick:()=>{n(e)},disableRipple:!0,dense:!0},e.iconPath&&q.createElement(cw,null,e.IconDefinition?q.createElement(e.IconDefinition,null):q.createElement(hw,{viewBox:"0 0 16 16"},q.createElement("path",{d:e.iconPath}))),q.createElement(uw,{noWrap:!0,title:e.translation||e.name},e.translation||e.name)))}))),gw=({categories:e,anchorEl:t,onClose:n,onSelect:r,width:o})=>{const[i,a]=Y.useState(""),l=!!t;return Y.useEffect((()=>{l&&a("")}),[l]),q.createElement(qE,{open:l,anchorEl:t,onClose:n,anchorOrigin:{vertical:"bottom",horizontal:"center"},transformOrigin:{vertical:"top",horizontal:"center"},sx:{marginTop:"5px"}},q.createElement(ix,{fullWidth:!0,onChange:e=>{a(e.target.value)},startAdornment:q.createElement(oE,{position:"start"},q.createElement(ow,null))}),q.createElement(dw,null),q.createElement(sw,{width:o},e.map((e=>{const t=e.items.filter((e=>{const t=e.translation||e.name;return(null==t?void 0:t.toLocaleLowerCase().indexOf(i.toLocaleLowerCase()))>-1}));return t.length>0&&q.createElement(mw,{key:e.name,name:e.name,items:t,onSelect:r})}))))},bw=({anchorEl:e,onClose:t,dataHandler:n,translator:r,sharedContainerUtilities:o,width:i})=>{const[a,l]=Y.useState([]),[s,u]=Y.useState({});Y.useEffect((()=>{if(e&&n){(async()=>{const e=await n.getMasterVizList();l(e),u(n.getCharts())})().catch((()=>{}))}}),[e,n]);const c=[],d=[],p=new Map,f=Object.values(s);if(0===f.length&&0===a.length)return null;f.forEach((e=>{var t;if(!e.libraryInfo||!e.libraryInfo.isThirdParty&&e.libraryInfo.visible)c.push(e);else if(e.libraryInfo.visible)if(null!==(t=e.libraryInfo.bundle)&&void 0!==t&&t.name){const t=e.libraryInfo.bundle.name,n=p.get(t);n?n.push(e):p.set(t,[e])}else d.push(e)}));const h=e=>e.map((e=>{var t,n,r,o;return{iconPath:null===(t=e.libraryInfo)||void 0===t?void 0:t.iconPath,IconDefinition:null===(n=e.libraryInfo)||void 0===n?void 0:n.IconDefinition,name:e.id,translation:(null===(r=e.libraryInfo)||void 0===r?void 0:r.translation)||(null===(o=e.libraryInfo)||void 0===o?void 0:o.name)||e.id||"",type:e.id}})).sort(((e,t)=>(e.translation||e.name).localeCompare(t.translation||t.name))),m=[{name:r.get("LayoutContainer.Object.MasterItems"),items:a.map((e=>{var t,n;return{qExtendsId:e.qExtendsId,iconPath:null===(t=s[e.visualization])||void 0===t||null===(t=t.libraryInfo)||void 0===t?void 0:t.iconPath,IconDefinition:null===(n=s[e.visualization])||void 0===n||null===(n=n.libraryInfo)||void 0===n?void 0:n.IconDefinition,name:e.name,type:e.visualization}})).sort(((e,t)=>e.name.localeCompare(t.name)))},{name:r.get("LayoutContainer.Object.Charts"),items:c.map((e=>{var t,n,r,o,i;return{iconPath:(null===(t=e.libraryInfo)||void 0===t?void 0:t.iconPath)||"",IconDefinition:null===(n=e.libraryInfo)||void 0===n?void 0:n.IconDefinition,name:(null===(r=e.libraryInfo)||void 0===r?void 0:r.name)||e.id,type:(null===(o=e.libraryInfo)||void 0===o?void 0:o.template)||e.id,translation:(null===(i=e.libraryInfo)||void 0===i?void 0:i.translation)||e.id||""}})).sort(((e,t)=>e.translation.localeCompare(t.translation)))},{name:r.get("LayoutContainer.Object.CustomObjects"),items:h(d)}];for(const[e,t]of p)m.push({name:e,items:h(t)});return q.createElement(gw,{categories:m,anchorEl:e,onSelect:e=>{if(!n)return;const{qExtendsId:r}=e;(r?n.addMasterObjectAsChild({initProps:{qExtendsId:r,qInfo:{qType:"undefined"}}}):n.addVizAsChild({type:e.type,objectInitProps:{label:e.translation}})).then((e=>{null!=e&&e.id&&(null==o||o.setSelected([e.id]))})).catch((e=>{console.warn(e)})).finally((()=>{t()}))},onClose:t,width:i})},vw=e=>{var t,n;const r=xw(e);return null!==(t=null===(n=e.objects)||void 0===n?void 0:n.map((e=>{const{childRefId:t}=e;if(!t)return e;const n=r[t];return n?{...e,id:n}:e})))&&void 0!==t?t:[]},yw=(e,t)=>{var n;return null==e||null===(n=e.qChildList)||void 0===n||null===(n=n.qItems)||void 0===n?void 0:n.find((e=>{var n;return(null==e||null===(n=e.qData)||void 0===n?void 0:n.childRefId)===t}))},xw=e=>{var t;return null==e||null===(t=e.qChildList)||void 0===t||null===(t=t.qItems)||void 0===t?void 0:t.reduce(((e,t)=>{var n,r;return e[null==t||null===(n=t.qData)||void 0===n?void 0:n.childRefId]=null==t||null===(r=t.qInfo)||void 0===r?void 0:r.qId,e}),{})};var Ew=yw,Sw=e=>{const t={...e};return t.objects=vw(t),t},ww=e=>{var t;return null==e||null===(t=e.qChildList)||void 0===t||null===(t=t.qItems)||void 0===t?void 0:t.reduce(((e,t)=>{var n,r;return e[null==t||null===(n=t.qInfo)||void 0===n?void 0:n.qId]=null===(r=t.qData)||void 0===r?void 0:r.childRefId,e}),{})},Cw=e=>e.objects.reduce(((e,t)=>(e[t.childRefId]=t,e)),{}),kw=(e,t)=>{var n;if(!e)return t;const r=yw(e,t);return null==r||null===(n=r.qInfo)||void 0===n?void 0:n.qId};class Rw{constructor({app:e,data:t}){r(this,"layout",void 0),r(this,"app",void 0),r(this,"activeId",""),r(this,"data",void 0),r(this,"properties",void 0),r(this,"setSelectedChild",(e=>{var t;null===(t=this.activeContainer)||void 0===t||null===(t=t.sharedContainerUtilities)||void 0===t||t.setSelected(e)})),r(this,"addChild",(({initProps:e,objectInitProps:t,children:n})=>{if(!this.activeContainer)return;const{dataHandler:r}=this.activeContainer;if(null!=e&&e.qExtendsId){const{qExtendsId:o,qInfo:i}=e;return null==r?void 0:r.addMasterObjectAsChild({initProps:{qExtendsId:o,qInfo:i},objectInitProps:t,children:n})}return null==r?void 0:r.addVizAsChild({type:null==e?void 0:e.visualization,initProps:e,objectInitProps:t,children:n})})),r(this,"deleteChild",(async e=>{if(!this.activeContainer)return;const{dataHandler:t}=this.activeContainer;await(null==t?void 0:t.deleteChildren([e]))})),r(this,"duplicateChild",(async e=>{var t;const{childRefId:n,...r}=e,o=this.getEngineId(n);if(!o)return;const i=await(null===(t=this.app)||void 0===t?void 0:t.getObject(o));if(i&&this.activeContainer){const{sharedContainerUtilities:e}=this.activeContainer,t=await i.getFullPropertyTree(),n=t.qProperty,o=t.qChildren,a=await this.addChild({initProps:n,children:o,objectInitProps:r});a&&(null==e||e.setSelected([a.id]))}})),r(this,"openAddChildPopover",(e=>{if(this.activeContainer&&this.activeContainer.dataHandler&&this.data.muiTheme){const t=((e,t)=>{const n=e.getElementsByClassName(t);let r;return 0===n.length?(r=document.createElement("div"),r.className=t,e.appendChild(r)):r=n[0],tw(r)})(this.activeContainer.element,"add-child-popover"),n=()=>{t.unmount()};null==t||t.render(q.createElement(kl,{theme:this.data.muiTheme},q.createElement(bw,{translator:this.data.translator,anchorEl:e,dataHandler:this.activeContainer.dataHandler,onClose:n,width:220,sharedContainerUtilities:this.activeContainer.sharedContainerUtilities})))}})),r(this,"setModel",(e=>{this.activeId=e.id})),r(this,"setLayout",(e=>{this.layout=e})),r(this,"getLayout",(()=>this.layout)),r(this,"getEngineId",(e=>kw(this.layout,e))),r(this,"setProperties",(e=>{this.properties=e})),r(this,"canAddDimension",(()=>!1)),r(this,"canAddMeasure",(()=>!1)),r(this,"canColorBy",(()=>!1)),r(this,"getDimensions",(()=>[])),r(this,"getMeasures",(()=>[])),r(this,"minDimensions",(()=>0)),r(this,"minMeasures",(()=>0)),r(this,"maxDimensions",(()=>0)),r(this,"maxMeasures",(()=>0)),this.app=e,this.data=t}get activeContainer(){return this.data.containers[this.activeId]}getObject(e){const t=this.getEngineId(e);var n;if(t)return null===(n=this.activeContainer)||void 0===n?void 0:n.renderHelper.objectMap.get(t)}}function _w(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function Tw(e,t,n){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Lw(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,l=[],s=!0,u=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);s=!0);}catch(e){u=!0,o=e}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return l}}(e,t)||Aw(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Pw(e){return function(e){if(Array.isArray(e))return _w(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||Aw(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Aw(e,t){if(e){if("string"==typeof e)return _w(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?_w(e,t):void 0}}var Iw,Ow="top",Mw="top-right",Nw="right",zw="bottom-right",jw="bottom",$w="bottom-left",Dw="left",Bw="top-left";Tw(Tw(Tw(Tw(Tw(Tw(Tw(Tw(Tw(Tw(Iw={},"equal-equal",[Ow,jw]),"equal-higher",[jw,zw]),"equal-lower",[Ow,Mw]),"equal-void",[Ow,jw]),"higher-equal",[Dw,$w,Ow,Mw]),"higher-higher-acute",[jw,$w,Dw,Mw]),"higher-higher-obtuse",[jw,Ow]),"higher-lower-negative",[Ow,Mw,Nw]),"higher-lower-positive",[jw,$w,Dw]),"higher-void",[Ow]),Tw(Tw(Tw(Tw(Tw(Tw(Tw(Tw(Tw(Tw(Iw,"lower-equal",[Ow]),"lower-higher-negative",[Ow,Bw]),"lower-higher-positive",[zw]),"lower-lower-acute",[Ow,Bw,Dw,Mw,Nw]),"lower-lower-obtuse",[Ow,jw]),"lower-void",[Ow]),"void-equal",[Ow]),"void-higher",[Ow,jw]),"void-lower",[Ow,jw,Dw]),"void-void",[Ow]),Tw(Iw,"unclassified",[Ow,jw,Nw,Dw,Mw,zw,$w,Bw]);var Fw=["American Typewriter, serif","Andalé Mono, monospace","Arial Black, sans-serif","Arial, sans-serif","Bradley Hand, cursive","Brush Script MT, cursive","Comic Sans MS, cursive","Courier, monospace","Didot, serif","Georgia, serif","Impact, sans-serif","Lucida Console, monospace","Luminari, fantasy","Monaco, monospace","QlikView Sans, sans-serif","Source Sans Pro, sans-serif","Tahoma, sans-serif","Times New Roman, serif","Trebuchet MS, sans-serif","Verdana, sans-serif"],Hw=["Abril Fatface, serif","Bangers, fantasy","Bebas Neue, sans serif","EB Garamond, serif","Fredoka One, fantasy","Graduate, fantasy","Gravitas One, serif","Indie Flower, fantasy","Inter, sans-serif","Lobster, fantasy","Montserrat, sans-serif","Nixie One, sans-serif","Noto Sans, sans-serif","Open Sans, sans-serif","PT Serif, serif","Pacifico, cursive","Permanent Marker, fantasy","QlikView Sans, sans-serif","Raleway, sans-serif","Rammetto One, fantasy","Roboto, sans-serif","Source Sans Pro, sans-serif","Titan One, fantasy","Yanone Kaffeesatz, sans-serif"];var Uw=function(e){return{value:e,label:e.charAt(0).toUpperCase()+e.slice(1),groupHeader:!1,disabled:!1,styles:{fontFamily:e}}};function Vw(e){var t=e.theme,n=e.translator,r=e.defaultValue,o=e.flags,i=[],a=t.getStyle("","","fontFamilies");return Array.isArray(a)&&a.length?i.push.apply(i,Pw(new Set([r].concat(Pw(a.map((function(e){return e.split(",").map((function(e){return e.trim()})).map((function(e){return e.replace(/\s+/g," ").trim()})).filter(Boolean).join(", ")}))))))):i.push(r),[{value:"ThemeHeader",label:n.get("properties.themeFonts"),metaText:n.get("properties.theme"),groupHeader:!0}].concat(Pw(i.map((function(e){return Uw(e)}))),[{value:"DefaultHeader",label:n.get("properties.allFonts"),metaText:n.get("properties.default"),groupHeader:!0}],Pw(function(e){return null!=e&&e.isEnabled("PS_20852_WYSIWYG_FONT_SUPPORT")?Hw:Fw}(o).map((function(e){return Uw(e)}))))}function Gw(e){var t=e.theme,n=e.translator,r=e.id,o=e.path,i=e.flags,a=function(){return t.getStyle(r,o,"fontFamily")};return{getDefaultValue:function(){return a()},getOptions:function(){return Vw({theme:t,translator:n,defaultValue:a(),flags:i})}}}var Ww,Yw,qw=["10px","11px","12px","13px","14px","15px","16px","17px","18px","19px","20px","21px","22px","23px","24px"],Kw=function(e){return{value:e,label:e,groupHeader:!1,disabled:!1}};function Xw(e){var t=e.theme,n=e.translator,r=e.id,o=e.path,i=function(){return t.getStyle(r,o,"fontSize")};return{getDefaultValue:function(){return i()},getOptions:function(){return function(e){var t=e.translator,n=e.defaultValue,r=[],o=e.theme.getStyle("","","fontSizes");return Array.isArray(o)&&o.length?r.push.apply(r,Pw(new Set([n].concat(Pw(o))))):r.push(n),[{value:"ThemeHeader",label:t.get("properties.themeFontSizes"),metaText:t.get("properties.theme"),groupHeader:!0}].concat(Pw(r.map((function(e){return Kw(e)}))),[{value:"DefaultHeader",label:t.get("properties.allFontSizes"),metaText:t.get("properties.default"),groupHeader:!0}],Pw(qw.map((function(e){return Kw(e)}))))}({theme:t,translator:n,defaultValue:i()})}}}function Qw(e){var t=e.theme,n=e.translator,r=e.id,o=e.path;return{fontFamily:Gw({theme:t,translator:n,id:r,path:o,flags:e.flags}),fontSize:Xw({theme:t,translator:n,id:r,path:o})}}var Zw=function(){if(Yw)return Ww;Yw=1;var e=Object.prototype.hasOwnProperty,t=Object.prototype.toString,n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,o=function(e){return"function"==typeof Array.isArray?Array.isArray(e):"[object Array]"===t.call(e)},i=function(n){if(!n||"[object Object]"!==t.call(n))return!1;var r,o=e.call(n,"constructor"),i=n.constructor&&n.constructor.prototype&&e.call(n.constructor.prototype,"isPrototypeOf");if(n.constructor&&!o&&!i)return!1;for(r in n);return void 0===r||e.call(n,r)},a=function(e,t){n&&"__proto__"===t.name?n(e,t.name,{enumerable:!0,configurable:!0,value:t.newValue,writable:!0}):e[t.name]=t.newValue},l=function(t,n){if("__proto__"===n){if(!e.call(t,n))return;if(r)return r(t,n).value}return t[n]};return Ww=function e(){var t,n,r,s,u,c,d=arguments[0],p=1,f=arguments.length,h=!1;for("boolean"==typeof d&&(h=d,d=arguments[1]||{},p=2),(null==d||"object"!=typeof d&&"function"!=typeof d)&&(d={});p<f;++p)if(null!=(t=arguments[p]))for(n in t)r=l(d,n),d!==(s=l(t,n))&&(h&&s&&(i(s)||(u=o(s)))?(u?(u=!1,c=r&&o(r)?r:[]):c=r&&i(r)?r:{},a(d,{name:n,newValue:e(h,c,s)})):void 0!==s&&a(d,{name:n,newValue:s}));return d},Ww}();function Jw(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function eC(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function tC(){}!function(e){e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")&&e.default}(Zw);var nC=1/.7,rC="\\s*([+-]?\\d+)\\s*",oC="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",iC="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",aC=/^#([0-9a-f]{3,8})$/,lC=new RegExp(`^rgb\\(${rC},${rC},${rC}\\)$`),sC=new RegExp(`^rgb\\(${iC},${iC},${iC}\\)$`),uC=new RegExp(`^rgba\\(${rC},${rC},${rC},${oC}\\)$`),cC=new RegExp(`^rgba\\(${iC},${iC},${iC},${oC}\\)$`),dC=new RegExp(`^hsl\\(${oC},${iC},${iC}\\)$`),pC=new RegExp(`^hsla\\(${oC},${iC},${iC},${oC}\\)$`),fC={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function hC(){return this.rgb().formatHex()}function mC(){return this.rgb().formatRgb()}function gC(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=aC.exec(e))?(n=t[1].length,t=parseInt(t[1],16),6===n?bC(t):3===n?new EC(t>>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):8===n?vC(t>>24&255,t>>16&255,t>>8&255,(255&t)/255):4===n?vC(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|240&t,((15&t)<<4|15&t)/255):null):(t=lC.exec(e))?new EC(t[1],t[2],t[3],1):(t=sC.exec(e))?new EC(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=uC.exec(e))?vC(t[1],t[2],t[3],t[4]):(t=cC.exec(e))?vC(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=dC.exec(e))?_C(t[1],t[2]/100,t[3]/100,1):(t=pC.exec(e))?_C(t[1],t[2]/100,t[3]/100,t[4]):fC.hasOwnProperty(e)?bC(fC[e]):"transparent"===e?new EC(NaN,NaN,NaN,0):null}function bC(e){return new EC(e>>16&255,e>>8&255,255&e,1)}function vC(e,t,n,r){return r<=0&&(e=t=n=NaN),new EC(e,t,n,r)}function yC(e){return e instanceof tC||(e=gC(e)),e?new EC((e=e.rgb()).r,e.g,e.b,e.opacity):new EC}function xC(e,t,n,r){return 1===arguments.length?yC(e):new EC(e,t,n,null==r?1:r)}function EC(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}function SC(){return`#${RC(this.r)}${RC(this.g)}${RC(this.b)}`}function wC(){const e=CC(this.opacity);return`${1===e?"rgb(":"rgba("}${kC(this.r)}, ${kC(this.g)}, ${kC(this.b)}${1===e?")":`, ${e})`}`}function CC(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function kC(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function RC(e){return((e=kC(e))<16?"0":"")+e.toString(16)}function _C(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new LC(e,t,n,r)}function TC(e){if(e instanceof LC)return new LC(e.h,e.s,e.l,e.opacity);if(e instanceof tC||(e=gC(e)),!e)return new LC;if(e instanceof LC)return e;var t=(e=e.rgb()).r/255,n=e.g/255,r=e.b/255,o=Math.min(t,n,r),i=Math.max(t,n,r),a=NaN,l=i-o,s=(i+o)/2;return l?(a=t===i?(n-r)/l+6*(n<r):n===i?(r-t)/l+2:(t-n)/l+4,l/=s<.5?i+o:2-i-o,a*=60):l=s>0&&s<1?0:a,new LC(a,l,s,e.opacity)}function LC(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function PC(e){return(e=(e||0)%360)<0?e+360:e}function AC(e){return Math.max(0,Math.min(1,e||0))}function IC(e,t,n){return 255*(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)}Jw(tC,gC,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:hC,formatHex:hC,formatHex8:function(){return this.rgb().formatHex8()},formatHsl:function(){return TC(this).formatHsl()},formatRgb:mC,toString:mC}),Jw(EC,xC,eC(tC,{brighter(e){return e=null==e?nC:Math.pow(nC,e),new EC(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=null==e?.7:Math.pow(.7,e),new EC(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new EC(kC(this.r),kC(this.g),kC(this.b),CC(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:SC,formatHex:SC,formatHex8:function(){return`#${RC(this.r)}${RC(this.g)}${RC(this.b)}${RC(255*(isNaN(this.opacity)?1:this.opacity))}`},formatRgb:wC,toString:wC})),Jw(LC,(function(e,t,n,r){return 1===arguments.length?TC(e):new LC(e,t,n,null==r?1:r)}),eC(tC,{brighter(e){return e=null==e?nC:Math.pow(nC,e),new LC(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=null==e?.7:Math.pow(.7,e),new LC(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+360*(this.h<0),t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,o=2*n-r;return new EC(IC(e>=240?e-240:e+120,o,r),IC(e,o,r),IC(e<120?e+240:e-120,o,r),this.opacity)},clamp(){return new LC(PC(this.h),AC(this.s),AC(this.l),CC(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=CC(this.opacity);return`${1===e?"hsl(":"hsla("}${PC(this.h)}, ${100*AC(this.s)}%, ${100*AC(this.l)}%${1===e?")":`, ${e})`}`}}));const OC=Math.PI/180,MC=180/Math.PI,NC=4/29,zC=6/29,jC=3*zC*zC;function $C(e){if(e instanceof DC)return new DC(e.l,e.a,e.b,e.opacity);if(e instanceof VC)return GC(e);e instanceof EC||(e=yC(e));var t,n,r=UC(e.r),o=UC(e.g),i=UC(e.b),a=BC((.2225045*r+.7168786*o+.0606169*i)/1);return r===o&&o===i?t=n=a:(t=BC((.4360747*r+.3850649*o+.1430804*i)/.96422),n=BC((.0139322*r+.0971045*o+.7141733*i)/.82521)),new DC(116*a-16,500*(t-a),200*(a-n),e.opacity)}function DC(e,t,n,r){this.l=+e,this.a=+t,this.b=+n,this.opacity=+r}function BC(e){return e>.008856451679035631?Math.pow(e,1/3):e/jC+NC}function FC(e){return e>zC?e*e*e:jC*(e-NC)}function HC(e){return 255*(e<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055)}function UC(e){return(e/=255)<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function VC(e,t,n,r){this.h=+e,this.c=+t,this.l=+n,this.opacity=+r}function GC(e){if(isNaN(e.h))return new DC(e.l,0,0,e.opacity);var t=e.h*OC;return new DC(e.l,Math.cos(t)*e.c,Math.sin(t)*e.c,e.opacity)}Jw(DC,(function(e,t,n,r){return 1===arguments.length?$C(e):new DC(e,t,n,null==r?1:r)}),eC(tC,{brighter(e){return new DC(this.l+18*(null==e?1:e),this.a,this.b,this.opacity)},darker(e){return new DC(this.l-18*(null==e?1:e),this.a,this.b,this.opacity)},rgb(){var e=(this.l+16)/116,t=isNaN(this.a)?e:e+this.a/500,n=isNaN(this.b)?e:e-this.b/200;return new EC(HC(3.1338561*(t=.96422*FC(t))-1.6168667*(e=1*FC(e))-.4906146*(n=.82521*FC(n))),HC(-.9787684*t+1.9161415*e+.033454*n),HC(.0719453*t-.2289914*e+1.4052427*n),this.opacity)}})),Jw(VC,(function(e,t,n,r){return 1===arguments.length?function(e){if(e instanceof VC)return new VC(e.h,e.c,e.l,e.opacity);if(e instanceof DC||(e=$C(e)),0===e.a&&0===e.b)return new VC(NaN,0<e.l&&e.l<100?0:NaN,e.l,e.opacity);var t=Math.atan2(e.b,e.a)*MC;return new VC(t<0?t+360:t,Math.sqrt(e.a*e.a+e.b*e.b),e.l,e.opacity)}(e):new VC(e,t,n,null==r?1:r)}),eC(tC,{brighter(e){return new VC(this.h,this.c,this.l+18*(null==e?1:e),this.opacity)},darker(e){return new VC(this.h,this.c,this.l-18*(null==e?1:e),this.opacity)},rgb(){return GC(this).rgb()}}));var WC=e=>()=>e;function YC(e,t){var n=t-e;return n?function(e,t){return function(n){return e+n*t}}(e,n):WC(isNaN(e)?t:e)}!function e(t){var n=function(e){return 1==(e=+e)?YC:function(t,n){return n-t?function(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}(t,n,e):WC(isNaN(t)?n:t)}}(t);function r(e,t){var r=n((e=xC(e)).r,(t=xC(t)).r),o=n(e.g,t.g),i=n(e.b,t.b),a=YC(e.opacity,t.opacity);return function(t){return e.r=r(t),e.g=o(t),e.b=i(t),e.opacity=a(t),e+""}}return r.gamma=e,r}(1);var qC="center",KC="bottom";function XC(e,t,n){if(void 0===e||void 0===t)return n;for(var r=t.split("."),o=e,i=0;i<r.length;++i){var a=r[i];if(void 0===o[a])return n;o=o[a]}return o}[{key:"NoDataExist",alignment:qC,condition:function(e){var t=e.layoutService;if(!t)return!1;var n=t.meta.size;return n.x*n.y==0}},{key:"OnlyNanDataMeasure",translationKey:"OnlyNanData",alignment:qC,condition:function(e){var t=e.layoutService;return!!t&&t.getHyperCubeValue("qMeasureInfo").every((function(e){return"NaN"===e.qMin&&"NaN"===e.qMax}))}},{key:"OnlyNanDataDimensionContinuous",translationKey:"OnlyNanData",alignment:qC,condition:function(e){var t=e.layoutService;if(!t)return!1;if(!t.meta.isContinuous)return!1;var n=t.getHyperCubeValue("qDimensionInfo.0");return n&&(n.qMax<n.qMin||"NaN"===n.qMax)}},{key:"OnlyNegativeOrZeroValues",alignment:qC},{key:"DataRangeIncludingZero",alignment:KC},{key:"LimitedData",alignment:KC},{key:"NegativeOrZeroValues",alignment:KC}].reduce((function(e,t){return e[t.key]=t,e}),{});var QC,ZC=["__proto__","constructor"];function JC(e,t,n){if(void 0!==e&&void 0!==t){var r=t.split("."),o=r[r.length-1];if(!ZC.some((function(e){return r.includes(e)}))){for(var i=e,a=0;a<r.length-1;++a){var l=r[a];void 0===i[l]&&(i[l]=Number.isNaN(+r[a+1])?{}:[]),i=i[l]}void 0!==n?i[o]=n:delete i[o]}}}function ek(e){var t=0,n=e.children,r=n&&n.length;if(r)for(;--r>=0;)t+=n[r].value;else t=1;e.value=t}function tk(e,t){e instanceof Map?(e=[void 0,e],void 0===t&&(t=rk)):void 0===t&&(t=nk);for(var n,r,o,i,a,l=new ak(e),s=[l];n=s.pop();)if((o=t(n.data))&&(a=(o=Array.from(o)).length))for(n.children=o,i=a-1;i>=0;--i)s.push(r=o[i]=new ak(o[i])),r.parent=n,r.depth=n.depth+1;return l.eachBefore(ik)}function nk(e){return e.children}function rk(e){return Array.isArray(e)?e[1]:null}function ok(e){void 0!==e.data.value&&(e.value=e.data.value),e.data=e.data.data}function ik(e){var t=0;do{e.height=t}while((e=e.parent)&&e.height<++t)}function ak(e){this.data=e,this.depth=this.height=0,this.parent=null}ak.prototype=tk.prototype={constructor:ak,count:function(){return this.eachAfter(ek)},each:function(e,t){let n=-1;for(const r of this)e.call(t,r,++n,this);return this},eachAfter:function(e,t){for(var n,r,o,i=this,a=[i],l=[],s=-1;i=a.pop();)if(l.push(i),n=i.children)for(r=0,o=n.length;r<o;++r)a.push(n[r]);for(;i=l.pop();)e.call(t,i,++s,this);return this},eachBefore:function(e,t){for(var n,r,o=this,i=[o],a=-1;o=i.pop();)if(e.call(t,o,++a,this),n=o.children)for(r=n.length-1;r>=0;--r)i.push(n[r]);return this},find:function(e,t){let n=-1;for(const r of this)if(e.call(t,r,++n,this))return r},sum:function(e){return this.eachAfter((function(t){for(var n=+e(t.data)||0,r=t.children,o=r&&r.length;--o>=0;)n+=r[o].value;t.value=n}))},sort:function(e){return this.eachBefore((function(t){t.children&&t.children.sort(e)}))},path:function(e){for(var t=this,n=function(e,t){if(e===t)return e;var n=e.ancestors(),r=t.ancestors(),o=null;for(e=n.pop(),t=r.pop();e===t;)o=e,e=n.pop(),t=r.pop();return o}(t,e),r=[t];t!==n;)t=t.parent,r.push(t);for(var o=r.length;e!==n;)r.splice(o,0,e),e=e.parent;return r},ancestors:function(){for(var e=this,t=[e];e=e.parent;)t.push(e);return t},descendants:function(){return Array.from(this)},leaves:function(){var e=[];return this.eachBefore((function(t){t.children||e.push(t)})),e},links:function(){var e=this,t=[];return e.each((function(n){n!==e&&t.push({source:n.parent,target:n})})),t},copy:function(){return tk(this).eachBefore(ok)},[Symbol.iterator]:function*(){var e,t,n,r,o=this,i=[o];do{for(e=i.reverse(),i=[];o=e.pop();)if(yield o,t=o.children)for(n=0,r=t.length;n<r;++n)i.push(t[n])}while(i.length)}},QC=function(e){
|
|
107
107
|
/*! javascript-number-formatter - v1.1.11 - http://mottie.github.com/javascript-number-formatter/ * © ecava */
|
|
108
|
-
e.exports=function(e,t){if(!e||isNaN(+t))return t;var n,r,o,i,a,l,s,u,c,d,p=e.length,f=e.search(/[0-9\-\+#]/),h=f>0?e.substring(0,f):"",m=e.split("").reverse().join(""),g=m.search(/[0-9\-\+#]/),b=p-g,v=e.substring(b,b+1),y=b+("."===v||","===v?1:0),x=g>0?e.substring(y,p):"";if(n=(t="-"===(e=e.substring(f,y)).charAt(0)?-t:+t)<0?t=-t:0,o=(r=e.match(/[^\d\-\+#]/g))&&r[r.length-1]||".",i=r&&r[1]&&r[0]||",",e=e.split(o),t=+(t=t.toFixed(e[1]&&e[1].length))+"",l=e[1]&&e[1].lastIndexOf("0"),(!(u=t.split("."))[1]||u[1]&&u[1].length<=l)&&(t=(+t).toFixed(l+1)),c=e[0].split(i),e[0]=c.join(""),(a=e[0]&&e[0].indexOf("0"))>-1)for(;u[0].length<e[0].length-a;)u[0]="0"+u[0];else 0==+u[0]&&(u[0]="");if((t=t.split("."))[0]=u[0],s=c[1]&&c[c.length-1].length){for(m="",b=(d=t[0]).length%s,p=d.length,y=0;y<p;y++)m+=d.charAt(y),!((y-b+1)%s)&&y<p-s&&(m+=i);t[0]=m}return t[1]=e[1]&&t[1]?o+t[1]:"","0"!==(r=t.join(""))&&""!==r||(n=!1),h+(n?"-":"")+r+x}},QC({exports:{}});var lk="'Source Sans Pro', 'Arial', 'sans-serif'",sk="#333333",uk="#595959",ck="#737373",dk="#cccccc",pk="#e6e6e6";function fk(e){var t={};return[].concat(Pw(e),Pw([["","","color"],["object","","fontFamily"],["object","axis.label.name","color",uk],["object","axis.label.name","fontFamily",lk],["object","axis.label.name","fontSize","12px"],["object","axis.line.major","color",dk],["object","axis.line.minor","color",pk],["object","axis.title","color"],["object","axis.title","fontFamily",lk],["object","axis.title","fontSize","13px"],["object","grid.line.highContrast","color",pk],["object","grid.line.major","color",dk],["object","grid.line.minor","color",pk],["object","label.value","color",uk],["object","label.value","fontFamily",lk],["object","label.value","fontSize","12px"],[!1,"label.value","darkColor",uk],[!1,"label.value","lightColor",pk],["object","outOfRange","color","#999"],["object","legend.title","color",sk],["object","legend.title","fontFamily",lk],["object","legend.title","fontSize","15px"],["object","legend.label","color",uk],["object","legend.label","fontFamily",lk],["object","legend.label","fontSize","13px"],["object","referenceLine.label.name","color",sk],["object","referenceLine.label.name","fontFamily",lk],["object","referenceLine.label.name","fontSize","12px"],["object","referenceLine.outOfBounds","color",pk],["object","referenceLine.outOfBounds","fontFamily",lk],["object","referenceLine.outOfBounds","fontSize","12px"],["object","referenceLine.outOfBounds","backgroundColor",ck,function(e){return"transparent"===e?ck:e}]])).reduce((function(e,n){var r="".concat(n[0],"-").concat(n[1],"-").concat(n[2],"}");return t[r]||(t[r]=!0,e.push(n)),e}),[]).sort((function(e,t){return(e[0].split?e[0].split(".").length:0)-(t[0].split?t[0].split(".").length:0)}))}var hk=function(e){return e};function mk(e){var t=e.theme,n=e.id,r=e.transform,o=e.extend,i=e.matrix,a={},l=r.reduce((function(e,t){var n=Lw(t,2),r=n[0],o=n[1];return e[r]=o,e}),{});return i.forEach((function(e){var r=Lw(e,5),o=r[0],i=r[1],s=r[2],u=r[3],c=r[4],d=void 0===c?function(e){return e}:c,p=function(e){var t=e.theme,n=e.base,r=e.path,o=e.attribute,i=e.defaultValue,a=void 0===i?void 0:i;if(!t||!1===n)return a;var l=t.getStyle(n,r,o);return void 0===l?a:l}({theme:t,base:"object"===o&&n?"".concat("object",".").concat(n):o,path:i,attribute:s,defaultValue:u}),f=(l["".concat(i,".").concat(s)]||hk)(d(p));JC(a,[i,s].filter(Boolean).join("."),f)})),o.forEach((function(e){var t=Lw(e,2),n=t[0],r=t[1];JC(a,n,r)})),a}const gk={qData:{visualization:"/visualization",qExtendsId:"/qExtendsId",containerChildId:"/containerChildId",title:"/title",childRefId:"/childRefId",showCondition:"/showCondition"}};function bk(e){if(!e.objects)return{};const t=Cw(e);return{container_id:e.qInfo.qId,objects:e.qChildList.qItems.map((n=>{var r;return{chart_type:n.qData.visualization,chart_id:n.qInfo.qId,chart_isMaster:!!n.qData.qExtendsId,tab_isVisible:0!==(null===(r=t[n.qData.childRefId])||void 0===r?void 0:r.condition),tab_isActive:n.qData.childRefId===e.cachedTabId}}))}}const vk=({ref:e,theme:t,change:n})=>({component:"inline-wrapper",items:{bgColorDropdown:{ref:`${e}.useColorExpression`,width:9.5,component:"dropdown",change(t){(XC(t,`${e}.color`)||XC(t,`${e}.colorExpression`))&&(JC(t,`${e}.color`,void 0),JC(t,`${e}.colorExpression`,void 0)),null==n||n(t)},options:[{value:!1,translation:"properties.colorMode.primary"},{value:!0,translation:"properties.colorMode.byExpression"}],defaultValue:!1,placeholder:"properties.colorMode.primary"},bgColorPicker:{component:"color-picker",ref:`${e}.color`,width:1,show:t=>!XC(t,`${e}.useColorExpression`),disableNone:!1,defaultValue:()=>{var n;return{color:null!==(n=null==t?void 0:t.getStyle("object.tabbedContainer",e,"color"))&&void 0!==n?n:"none"}},showAlpha:!0,change:e=>{null==n||n(e)}},bgColorExpression:{component:"input-field-expression",ref:`${e}.colorExpression`,show:t=>XC(t,`${e}.useColorExpression`)}}}),yk=({theme:e})=>({bgColorAllWrapper:vk({ref:"background.unselected"}),selectedTab:{translation:"properties.chartType.selected",component:"text"},bgColorSelectedWrapper:vk({ref:"background.selected"}),colorHoverWrapper:{component:"items",items:{hoverLabel:{translation:"Object.TabbedContainer.Hover",component:"text"},hover:vk({ref:"background.hover",theme:e,change:e=>{JC(e,"indicator.hover.color",XC(e,"background.hover.color")),JC(e,"indicator.hover.useColorExpression",XC(e,"background.hover.useColorExpression"))}})},show:(e,t)=>"left"===t.layout.orientation}}),xk=({paths:e,fontResolver:t,theme:n})=>{const r=`${e.theme}.fontSize`;return{fontWrapperItem:{component:"inline-wrapper",items:{fontSizeItem:{component:"dropdown",ref:`${e.ref}.size`,options:()=>t.getOptions(r),defaultValue:()=>t.getDefaultValue(r),show:e=>{var t;return!1!==(null===(t=e.icon)||void 0===t?void 0:t.show)}},fontColorItem:{component:"color-picker",width:!1,ref:`${e.ref}.color`,defaultValue:()=>({color:n.getStyle("object.tabbedContainer",e.theme,"color")}),show:e=>{var t;return!1!==(null===(t=e.icon)||void 0===t?void 0:t.show)}}}},position:{type:"string",ref:"icon.position",component:"dropdown",options:[{value:"start",translation:"properties.dock.start"},{value:"top",translation:"properties.dock.top"},{value:"end",translation:"properties.dock.end"},{value:"bottom",translation:"properties.dock.bottom"}],defaultValue:(e,{layout:t})=>"left"===t.orientation?"top":"start",show:e=>"tabs"===e.key},hide:{type:"boolean",translation:"properties.show",ref:"icon.show",component:"switch",defaultValue:!0,show:e=>"tab"===e.key}}},Ek=({theme:e})=>({colorWrapper:vk({ref:"indicator.selected",theme:e}),colorHoverWrapper:{component:"items",items:{hoverLabel:{translation:"Object.TabbedContainer.Hover",component:"text"},hover:vk({ref:"indicator.hover",theme:e,change:e=>{JC(e,"background.hover.color",XC(e,"indicator.hover.color")),JC(e,"background.hover.useColorExpression",XC(e,"indicator.hover.useColorExpression"))}})},show:(e,t)=>"left"!==t.layout.orientation}}),Sk=({paths:e,fontResolver:t,theme:n})=>{const r=`${e.theme}.fontFamily`,o=`${e.theme}.fontSize`;return{fontFamilyItem:{component:"dropdown",ref:`${e.ref}.fontFamily`,options:()=>t.getOptions(r),defaultValue:()=>t.getDefaultValue(r),change:(e,t,n)=>{var r;const o=null===(r=e.label)||void 0===r?void 0:r.fontFamily,i=(e=>{const t=[];return e.objects.forEach((e=>{var n,r;const o=null===(n=e.components)||void 0===n?void 0:n.find((e=>"tab"===e.key)),i=null==o||null===(r=o.label)||void 0===r?void 0:r.fontFamily;i&&-1===t.indexOf(i)&&t.push(i)})),t})(n);o&&-1===i.indexOf(o)&&i.push(o),n.fontsUsed=i}},fontWrapperItem:{component:"inline-wrapper",items:{fontSizeItem:{component:"dropdown",ref:`${e.ref}.fontSize`,options:()=>t.getOptions(o),defaultValue:()=>t.getDefaultValue(o)},fontColorItem:{component:"color-picker",width:!1,ref:`${e.ref}.color`,defaultValue:()=>({color:n.getStyle("object.tabbedContainer",e.theme,"color")})}}},alignment:{component:"text-align-buttons",ref:"label.alignment",show:e=>"tabs"===e.key},hide:{type:"boolean",translation:"properties.show",ref:"label.show",component:"switch",defaultValue:!0}}},wk=({ref:e,key:t,fontResolver:n,theme:r})=>({translation:"Object.Container.Props.Label",component:"panel-section",items:{label:{component:"items",ref:e,key:t,items:Sk({paths:{ref:"label",theme:"label.value"},fontResolver:n,theme:r})}}}),Ck=({ref:e,key:t})=>({translation:"Visualizations.Descriptions.Width",component:"panel-section",items:{width:{component:"items",ref:e,key:t,items:{unit:{type:"string",ref:"width.unit",component:"dropdown",options:[{value:"%",translation:"Object.Table.Column.Percentage"},{value:"px",translation:"Object.Table.Column.Pixels"}],defaultValue:"%",change:e=>{var t,n;if(void 0!==(null===(t=e.width)||void 0===t?void 0:t.value)&&"%"===(null===(n=e.width)||void 0===n?void 0:n.unit))for(let t=0;t<e.width.value.length;t++)e.width.value[t]>100?e.width.value[t]=100:e.width.value[t]<5&&(e.width.value[t]=5)}},valuePixel:{translation:"properties.axis.minMax",component:"slider",ref:"width.value",range:!0,step:1,min:0,max:800,show:e=>{var t;return"px"===(null===(t=e.width)||void 0===t?void 0:t.unit)},defaultValue:[0,360]},valuePercentage:{translation:"properties.axis.minMax",component:"slider",type:"array",ref:"width.value",range:!0,step:1,min:5,max:100,show:e=>{var t,n;return!(null!==(t=e.width)&&void 0!==t&&t.unit)||"px"!==(null===(n=e.width)||void 0===n?void 0:n.unit)},defaultValue:[5,20]}}}}}),kk=({theme:e,ref:t,key:n})=>({translation:"Object.TabbedContainer.Indicator",component:"panel-section",items:{indicator:{component:"items",ref:t,key:n,items:Ek({theme:e})}}}),Rk=({ref:e,key:t,fontResolver:n,theme:r})=>({translation:"properties.icon",component:"panel-section",items:{icon:{component:"items",ref:e,key:t,items:xk({paths:{ref:"icon",theme:"icon.value"},fontResolver:n,theme:r})}},show:(e,{layout:t})=>!0===t.showIcons}),_k=({theme:e,ref:t,key:n})=>({translation:"Object.OrgChart.BackgroundColor",component:"panel-section",items:{background:{component:"items",ref:t,key:n,items:"tab"===n?{bgColorWrapper:vk({ref:"background"})}:yk({theme:e})}}}),Tk=({fontResolver:e,theme:t})=>{const n="components",r="tab";return{component:"styling-panel",chartTitle:"Object.Container",tabTitle:"scripteditor.dataconnectors.delimiter.tab",translation:"LayerStyleEditor.component.styling",subtitle:"LayerStyleEditor.component.styling",ref:n,items:{label:wk({ref:n,key:r,fontResolver:e,theme:t}),width:{...Ck({ref:n,key:r}),show:(e,{layout:t})=>"left"!==t.orientation},icon:Rk({ref:n,key:r,fontResolver:e,theme:t}),background:_k({ref:n,key:r,theme:t})}}},Lk={ref:"label",type:"string",translation:"Object.Container.Props.Label",defaultValue:"",expression:"optional"},Pk={ref:"condition",translation:"Object.Container.Props.ShowCondition",component:"expression",defaultValue:{qValueExpression:{qExpr:""}},expressionType:"ValueExpression",expression:"always"},Ak=e=>({component:"button",translation:"Object.Container.Props.EditProperties",disabled:(e,t)=>{var n,r,o;const i=t.getLayout(),a=null===(n=Ew(i,e.childRefId))||void 0===n?void 0:n.qMeta;return!(null!=a&&null!==(r=a.privileges)&&void 0!==r&&r.includes("update")&&null!==(o=i.permissions)&&void 0!==o&&o.update)},action(t,n,{app:r}){const{sense:o}=e.env.anything,i=n.getEngineId(t.childRefId);i&&(o.propertyPanel.show({id:i,app:r,parent:"current",headerLabel:t.label}),n.setSelectedChild([i]))}}),Ik=e=>{const{sense:t}=e.env.anything;return{label:Lk,condition:Pk,styling:Tk({fontResolver:e.fontResolver,theme:null==t?void 0:t.theme}),editProperties:Ak(e)}},Ok={translation:"Object.Container.Props.Chart",component:"text",show:e=>e.objects?e.objects.length<=1:e.children.length<=1},Mk={translation:"Common.Charts",component:"text",show:e=>e.objects?e.objects.length>1:e.children.length>1},Nk=e=>({type:"array",ref:"objects",itemTitleRef:e=>e.label,allowAdd:!0,customAdd:!0,allowMove:!0,allowRemove:!0,customRemove:!0,addTranslation:"Object.Container.Props.Add",cId:"childRefId",grouped:!0,add(e,t,n){const r=document.querySelector(".pp-toplist-add-button");null!==r&&n.openAddChildPopover(r)},remove(e,t,n){n.deleteChild(e.childRefId).catch((()=>{}))},items:Ik(e)}),zk=e=>({type:"items",translation:"Object.Container.Props.Content",items:{chartLabel:Ok,chartsLabel:Mk,chartList:Nk(e)}}),jk={type:"boolean",translation:"Object.Container.Props.ShowTabs",ref:"showTabs",defaultValue:!0,component:"switch",options:[{value:!0,translation:"properties.on"},{value:!1,translation:"properties.off"}]},$k={type:"boolean",translation:"Object.Container.Props.UseDropdown",label:"Menu",ref:"useDropdown",component:"switch",options:[{value:!0,translation:"Common.Auto"},{value:!1,translation:"properties.off"}],defaultValue:!1,show:e=>e.showTabs},Dk={type:"boolean",translation:"Object.Container.Props.UseScrollButtons",ref:"useScrollButton",component:"switch",options:[{value:!0,translation:"Common.Auto"},{value:!1,translation:"properties.off"}],defaultValue:!0,show:e=>e.showTabs},Bk={type:"boolean",translation:"Object.Container.Props.ShowIcons",ref:"showIcons",component:"switch",options:[{value:!0,translation:"properties.on"},{value:!1,translation:"properties.off"}],defaultValue:!1,show:e=>e.showTabs},Fk={type:"string",translation:"Object.Container.Props.DefaultTab",ref:"defaultTabId",component:"dropdown",defaultValue:void 0,options(e,t){const n=t.getLayout();return n?n.objects.map((e=>({translation:e.label,value:e.childRefId}))):[]},change(e,t){const n=kw(t.getLayout(),e.defaultTabId);n&&t.setSelectedChild([n])},show:e=>e.objects.length>0},Hk={type:"string",translation:"properties.orientation",ref:"orientation",component:"dropdown",options:[{value:"top",translation:"properties.orientation.horizontal"},{value:"left",translation:"properties.orientation.vertical"}],defaultValue:"top",show:e=>e.showTabs},Uk=({fontResolver:e,theme:t})=>{const n="components",r="tabs";return{component:"styling-panel",chartTitle:"Object.TabContainer",tabTitle:"Object.Container.Props.ShowTabs",translation:"LayerStyleEditor.component.styling",subtitle:"LayerStyleEditor.component.styling",useGeneral:!0,useBackground:!0,items:{label:wk({ref:n,key:r,fontResolver:e,theme:t}),width:Ck({ref:n,key:r}),indicator:kk({ref:n,key:r,theme:t}),icon:Rk({ref:n,key:r,fontResolver:e,theme:t}),background:_k({ref:n,key:r,theme:t})}}},Vk={items:{details:{show:e=>!0===e.showDetails}}},Gk=e=>{const{sense:t}=e.env.anything;return{type:"items",translation:"properties.presentation",grouped:!0,items:{stylingPanel:Uk({fontResolver:e.fontResolver,theme:null==t?void 0:t.theme}),container:{type:"items",items:{showTabs:jk,useDropdown:$k,useScrollButton:Dk,showIcons:Bk,orientation:Hk,defaultTabId:Fk}}}}},Wk=e=>({uses:"settings",items:{general:Vk,presentation:Gk(e)}}),Yk=e=>({type:"items",component:"accordion",items:{content:zk(e),settings:Wk(e)}}),qk=e=>{const{sense:t}=e.env.anything,n=function(e){var t=e.theme,n=e.translator,r=e.config,o=void 0===r?{}:r,i=e.flags,a=function(e){var t=e.config,n=void 0===t?{}:t,r=n.id,o=n.paths;return{id:void 0===r?"object":"".concat("object",".").concat(r),paths:Array.isArray(o)?o:[]}}({config:o}),l=a.id,s=a.paths,u={};s.forEach((function(e){for(var r=e.split("."),o=u,a=0;a<r.length;a++){var s=r[a];a===r.length-1?o[s]=Qw({theme:t,translator:n,id:l,path:e,flags:i}):void 0===o[s]&&(o[s]={}),o=o[s]}}));var c=function(e){for(var t=e.split("."),n=u,r=0;r<t.length;r++){var o=t[r];if(void 0===n[o])throw new Error("font-resolver: Path '".concat(e,"' could not be resolved."));n=n[o]}return n};return u.getDefaultValue=function(e){return c(e).getDefaultValue()},u.getOptions=function(e){return c(e).getOptions()},u}({theme:null==t?void 0:t.theme,translator:e.env.translator,flags:e.env.flags,config:{id:"tabbedContainer",paths:["label.value","icon.value"]}}),r=function(e){return{async getDropOptions(e,t,n){const{item:r}=t,o=e.getCreatePropertyHandler();if(o.setModel(e.model),"state"===t.item.type){var i;const r=await e.model.getProperties();return o.setProperties(r),o.setLayout(null===(i=e.model)||void 0===i?void 0:i.layout),this.getDropStateOptions(t,o,e.model,n)}if("visualization"===r.type)return t.menu.addItem({translation:["Object.Container.DropItem",r.name],tid:"addvisualization",select(){var e;null===(e=o.addChild({initProps:{qExtendsId:r.id,qInfo:{qType:"undefined"}}}))||void 0===e||e.then((e=>{e&&o.setSelectedChild([e.id])}))}}),void n();const a=await t.item.getDropOption(t.item);"newObject"===(null==a?void 0:a.id)&&t.menu.addItem({translation:["Object.Container.DropItem",r.name],tid:"createvisualization",select(){var e,t;null===(e=o.addChild({initProps:{...a.args.init,visualization:a.args.template},children:null===(t=a.args.children)||void 0===t?void 0:t.map((e=>({qProperty:e})))}))||void 0===e||e.then((e=>{e&&o.setSelectedChild([e.id])}))}}),n()},async addChild(t,n){const{model:r}=this,o=new Rw({app:r.app,data:e.propertyHandlerData});return o.setModel(r),{childModel:await o.addChild({initProps:t,children:n}),handler:o}},canReceive(e){if(this.model.layout.qExtendsId)return!1;if("libraryitem"===e.type){const{item:t}=e;if("template"===t.type&&JS.includes(t.template))return!1;if("visualization"===t.type&&JS.includes(t.visualization))return!1}return"gridcell"!==e.type||!JS.includes(e.cell.model.layout.visualization)}}}(e);return{definition:Yk({...e,fontResolver:n}),support:{snapshot:!1,export:!0,sharing:!1,exportData:!1,viewData:!1},hidePatchPanel:()=>!0,getCreatePropertyHandler:t=>new Rw({app:t,data:e.propertyHandlerData}),...r,addChild:async function(e,t){const{childModel:n,handler:o}=await r.addChild.apply(this,[e,t]);n&&o.setSelectedChild([n.id])},migrate:{properties:(e,t)=>((async(e,t)=>{if(!e.objects){const{objects:n,defaultTabId:r,components:o,orientation:i,showDetails:a}=await t.getEffectiveProperties(),l=await t.getFullPropertyTree();if(!l.qProperty.objects&&n){const s=[];l.qChildren.forEach((e=>{const n=e.qProperty;if(n.qInfo.qId){const r=async r=>{const o=await t.getChild(r),i=await o.getEffectiveProperties();return{...e,qProperty:{...n,childRefId:i.childRefId}}};s.push(r(n.qInfo.qId))}}));const u=await Promise.all(s),c={...e,objects:n,defaultTabId:null!=r?r:"",components:o,qChildListDef:gk,orientation:i,showDetails:a};t.clearSoftPatches(),await t.setFullPropertyTree({...l,qProperty:c,qChildren:u})}}})(e,t),e)},exportProperties:null,importProperties:(e,t)=>{const n={...e.properties};return"masterobject"!==e.properties.qInfo.qType&&(n.qInfo.qType=t.qInfo.qType),n.visualization=t.visualization,{qProperty:n,qChildren:e.qChildren}},extendMetrics:bk}},Kk=e=>e.reduce(((e,{id:t,data:n})=>(n&&(e[t]=n),e)),{}),Xk=async e=>{const t=[];for(const[n,r]of e){const e={id:n,data:void 0},o=r;t.push(o.getViewState().then((e=>({id:n,data:e}))).catch((()=>e)))}const n=await Promise.all(t);return{viewStates:Kk(n)}},Qk=async e=>{const t=[];for(const[n,r]of e){const e={id:n,data:void 0},o=r;t.push(o.getSnapshotLayout().then((e=>({id:n,data:e}))).catch((()=>e)))}const n=await Promise.all(t);return Kk(n)},Zk=(t,n)=>(e.onTakeSnapshot((async e=>{const r=e,{snapshotData:o}=r;if(o){const e=Sw(r),i=n(t.objectMap,e),[a,l]=await Promise.all([Qk(i.objectMap),Xk(i.objectMap)]);o.objectsData={layouts:a},r.objects=i.objects,o.viewState=l}return e})),{getViewState:()=>Xk(t.objectMap)});let Jk=function(e){return e.COPY="ctrl+c",e.CUT="ctrl+x",e.PASTE="ctrl+v",e.OPEN_CONTEXT_MENU="shift+F10",e.ESCAPE="Escape",e.SPACE=" ",e.ENTER="Enter",e.BACKSPACE="Backspace",e.DELETE="Delete",e.SHIFT="Shift",e}({}),eR=function(e){return e.KEY_DOWN="keydown",e.KEY_UP="keyup",e.FOCUS_OUT="focusout",e}({});var tR,nR;!function(e){e.TAB_MENU="tab-menu",e.TAB_MENU_ITEM="tab-menu-item",e.ACTIVE_TAB="active-tab-button",e.TAB_WRAPPER="tab-wrapper",e.TAB="tab-button",e.TAB_EXTRA_PRIO="MuiTab-root",e.TAB_LABEL="tab-label",e.TABS_ICON="tab-icon",e.ACTIVE_TAB_PANEL="active-tab-panel",e.TAB_INDICATOR="MuiTabs-indicator"}(tR||(tR={})),function(e){e.TABS="& .tab-button.MuiTab-root, .tab-button.active-tab-button",e.TABS_HOVER="& .tab-button.MuiTab-root:hover",e.TABS_LABEL="& .tab-label",e.TABS_ICON="& .tab-icon svg",e.TABS_WRAPPER="& .tab-wrapper",e.TAB_INDICATOR="& .MuiTabs-indicator"}(nR||(nR={}));const rR=e=>{var t;return null===(t=e.getElementsByClassName(tR.ACTIVE_TAB))||void 0===t?void 0:t[0]},oR=e=>{var t;return null===(t=e.getElementsByClassName(tR.ACTIVE_TAB_PANEL))||void 0===t?void 0:t[0]},iR=({element:t,setAccessibility:n,accessibility:r,renderHelper:o,interactions:i,env:a,models:l})=>{const{modifiedLayout:{showTabs:s,objects:u,orientation:c},translator:d}=l;e.useEffect((()=>{(()=>{const e="top"===c?d.get("TabContainer.Navigation.Horizontal"):d.get("TabContainer.Navigation.Vertical"),n=((e,t)=>e.map((e=>e.label||t.get("TabContainer.Object.Untitled"))).join(", "))(u,d);t.setAttribute("aria-label",d.get("TabContainer.Object.Description",[n,s?e:""]))})()}),[t,s,u,d,c]);const p=a.flags.isEnabled("VIZ-7_NEW_SHEET"),f=e.useKeyboard(),h=e.useMemo((()=>()=>{var e;(n(!1),f.enabled)&&(null===(e=f.blur)||void 0===e||e.call(f,!0))}),[f,n]),m=e.useMemo((()=>e=>{switch(e.shiftKey?`shift+${e.key}`:e.key){case Jk.ESCAPE:var n;e.stopPropagation(),null===(n=f.blur)||void 0===n||n.call(f,!0);break;case Jk.ENTER:case Jk.SPACE:{e.stopPropagation();const n=e.target;var r;if(null!=n&&n.classList.contains(tR.ACTIVE_TAB))null===(r=oR(t))||void 0===r||r.focus();break}}}),[t,f]),g=e.useMemo((()=>e=>{const n=e.shiftKey?`shift+${e.key}`:e.key,r=o.objectMap.values().next().value,i=o.objectApis.values().next().value;switch(n){case Jk.ESCAPE:{const n=rR(t);p?(({event:e,objectApi:t,activeTab:n})=>{var r;e.stopPropagation(),(null==t?void 0:t.viewDataToggled)&&(null===(r=t.support)||void 0===r?void 0:r.call(t,"viewData"))?t.toggleDataView():null==n||n.focus()})({event:e,objectApi:i,activeTab:n}):(({event:e,objectApi:t,activeTab:n})=>{var r,o;e.stopPropagation(),(null==t?void 0:t.viewDataToggled)&&(null===(r=t.supportViewData)||void 0===r?void 0:r.call(t))?null===(o=t.toggleDataView)||void 0===o||o.call(t):null==n||n.focus()})({event:e,objectApi:r,activeTab:n});break}case Jk.ENTER:case Jk.SPACE:{const n=oR(t);p?(({event:e,objectApi:t,activeTab:n})=>{var r,o,i;if(!t)return;e.stopPropagation(),null===(r=t.setOnBlurHandler)||void 0===r||r.call(t,(()=>{var e;null==n||n.focus(),null===(e=t.setOnBlurHandler)||void 0===e||e.call(t,void 0)})),!t.viewDataToggled&&(null===(o=t.support)||void 0===o?void 0:o.call(t,"viewData"))?t.toggleDataView():null===(i=t.toggleFocus)||void 0===i||i.call(t,!0)})({event:e,objectApi:i,activeTab:n}):(({event:e,objectApi:t,activeTab:n})=>{var r,o,i,a;if(!t)return;e.stopPropagation(),null===(r=t.setOnBlurHandler)||void 0===r||r.call(t,(()=>{var e;null==n||n.focus(),null===(e=t.setOnBlurHandler)||void 0===e||e.call(t,void 0)})),!t.viewDataToggled&&(null===(o=t.supportViewData)||void 0===o?void 0:o.call(t))?null===(a=t.toggleDataView)||void 0===a||a.call(t):t.viewDataToggled&&"function"==typeof(null===(i=t.dataViewObject)||void 0===i?void 0:i.focus)?t.dataViewObject.focus():"function"==typeof t.focus&&t.focus()})({event:e,objectApi:r,activeTab:n});break}case Jk.OPEN_CONTEXT_MENU:e.stopPropagation(),null!=r&&r.viewDataToggled||t!==document.activeElement&&(h(),t.focus())}}),[t,h,p,o]),b=e.useMemo((()=>e=>{const t=e.target;null!=t&&t.classList.contains(tR.ACTIVE_TAB_PANEL)?g(e):m(e)}),[m,g]);e.useEffect((()=>(r&&t.addEventListener(eR.KEY_DOWN,b),()=>{t.removeEventListener(eR.KEY_DOWN,b)})),[t,r,b]);const[v,y]=e.useState(!1);e.useEffect((()=>{v&&(y(!1),window.setTimeout((()=>{var e,n;return null===(e=null!==(n=(e=>{var t;return null===(t=e.getElementsByClassName(tR.TAB_MENU))||void 0===t?void 0:t[0]})(t))&&void 0!==n?n:rR(t))||void 0===e?void 0:e.focus()}),0))}),[t,v]),e.useEffect((()=>{n(!1)}),[i.edit,n]),e.useEffect((()=>{const e=e=>{const n=e.relatedTarget;null!=t&&t.contains(n)||null!=n&&n.classList.contains(tR.TAB_MENU_ITEM)||null==h||h()};return f.enabled&&f.active&&!i.edit&&(n(!0),y(!0),t.addEventListener(eR.FOCUS_OUT,e)),()=>{t.removeEventListener(eR.FOCUS_OUT,e)}}),[f])},aR=t=>{const[n]=e.useState(t);return[n,function(e){Object.assign(n,e)}]},lR={getChar(e){let t,n=e;return n>9?(t=65+n-10,t>90&&(t+=6)):n=`${n}`.charCodeAt(0),!t||[48,111,79,105,73,108].indexOf(t)>-1?this.getChar(n+1):String.fromCharCode(t)},base62(e){const t=this.getChar(e%62),n=Math.floor(e/62);return n>0?this.base62(n)+t:t},id(){return this.base62(Math.round(99e11*Math.random()+1e11)).replace(/\W/g,"")}};const sR={qInfo:{qId:"MasterObjectList",qType:"MasterObjectList"},qAppObjectListDef:{qType:"masterobject",qData:{name:"/qMetaDef/title",labelExpression:"/labelExpression",visualization:"/visualization",tags:"/qMetaDef/tags"}}};class uR{constructor(e){r(this,"sessionObject",void 0),r(this,"getOrCreateSessionObject",(async e=>{const t=sR.qInfo.qId;this.sessionObject=await e.getObject(t).catch((()=>e.createSessionObject(sR)))})),r(this,"getMasterVisualizations",(async()=>{try{if(!this.sessionObject)return[];const e=await this.sessionObject.getLayout();return("qAppObjectList"in e?e.qAppObjectList.qItems:e).map((e=>({...e.qData,qExtendsId:e.qInfo.qId}))).filter((e=>!JS.includes(e.visualization)))}catch(e){return[]}})),this.getOrCreateSessionObject(e).catch((()=>{}))}}let cR=function(e){return e[e.TOP=0]="TOP",e[e.BOTTOM=1]="BOTTOM",e[e.UP=2]="UP",e[e.DOWN=3]="DOWN",e}({});class dR{constructor({embed:e,model:t,app:n,translator:o,mutex:i}){r(this,"model",void 0),r(this,"embed",void 0),r(this,"app",void 0),r(this,"undoRedoModel",void 0),r(this,"chartList",void 0),r(this,"masterVizList",void 0),r(this,"mutex",void 0),r(this,"rememberAsGroup",(async e=>{let t;this.undoRedoModel&&(t=await this.undoRedoModel.startGroup());const n=await e();return t&&this.undoRedoModel&&await this.undoRedoModel.endGroup(t),n})),r(this,"generateProperties",(async(e,t)=>await this.embed.generateProperties({type:e,properties:t}))),r(this,"addVizAsChild",(async({type:e,initProps:t,objectInitProps:n,children:r})=>{try{const o=await this.generateProperties(e,t);let i=(null==n?void 0:n.label)||(null==t?void 0:t.title);if(!i){const n=this.getChart(null==t?void 0:t.visualization),r=null==n?void 0:n.libraryInfo;i=(null==r?void 0:r.translation)||(null==r?void 0:r.name)||e}const a={...n,label:i};return await this.addChild(o,r,a)}catch(e){return}})),r(this,"addMasterObjectAsChild",(async({initProps:e,objectInitProps:t,children:n})=>{try{if(!e||!e.qExtendsId||!this.app)return;const r=await this.app.getObject(e.qExtendsId),o=await r.getProperties(),i=(null==t?void 0:t.label)||o.title||o.qMetaDef.title,a={...e,qInfo:{qType:"childObject"}},l={...t,label:i};return await this.addChild(a,n,l)}catch(e){return}})),r(this,"deleteChildren",(async e=>{const{model:t}=this;if(0===e.length||!t)return!1;try{await this.mutex.lock();const n=await t.getFullPropertyTree(),{qChildren:r,qProperty:o}=n,i=new Set(e);return n.qChildren=r.filter((({qProperty:e})=>{const t=e.childRefId;return!t||!i.has(t)})),n.qProperty.objects=o.objects.filter((e=>!i.has(e.childRefId))),await t.setFullPropertyTree(n),!0}catch(e){return!1}finally{this.mutex.unlock()}})),r(this,"moveChild",(async(e,t)=>{if(this.model)try{await this.mutex.lock();const n=await this.model.getProperties(),{objects:r}=n,o=r.findIndex((e=>e.childRefId===t));let i=!1;switch(e){case cR.TOP:{if(0===o)break;const e=r.splice(o,1)[0];r.unshift(e),i=!0;break}case cR.BOTTOM:{if(o===r.length-1)break;const e=r.splice(o,1)[0];r.push(e),i=!0;break}case cR.UP:{if(0===o)break;const e=r.splice(o,1)[0];r.splice(o-1,0,e),i=!0;break}case cR.DOWN:{if(o===r.length-1)break;const e=r.splice(o,1)[0];r.splice(o+1,0,e),i=!0;break}}i&&await this.model.setProperties(n)}finally{this.mutex.unlock()}})),r(this,"getCharts",(()=>{var e;return(null===(e=this.chartList)||void 0===e?void 0:e.getCharts())||{}})),r(this,"getMasterVizList",(()=>{var e;return(null===(e=this.masterVizList)||void 0===e?void 0:e.getMasterVisualizations())||Promise.resolve([])})),r(this,"getChart",(e=>{var t;return null===(t=this.chartList)||void 0===t?void 0:t.getChart(e)})),r(this,"getChartLabelById",((e,t)=>{var n,r;const o=null==e||null===(n=e.qChildList)||void 0===n?void 0:n.qItems.find((e=>e.qInfo.qId===t));if(!o)return"";const{visualization:i,title:a}=o.qData;if(a)return a;const l=this.getChart(i);return(null==l||null===(r=l.libraryInfo)||void 0===r?void 0:r.translation)||i})),this.model=t,this.embed=e,this.app=n;const a=n;a&&a.getUndoInfoObject&&a.getUndoInfoObject().then((e=>{this.undoRedoModel=e})).catch((()=>{})),n&&(this.masterVizList=new uR(n)),e&&o&&(this.chartList=new ew(e,o)),this.mutex=i}async addChild(e,t,n){if(this.model&&!JS.includes(e.visualization))try{await this.mutex.lock();const{model:r}=this,o=async()=>{e.childRefId=lR.id();const o=await r.createChild(e);if(o){const t=await r.getProperties();t.objects.unshift({childRefId:e.childRefId,...n,condition:{qValueExpression:{qExpr:""}}}),await r.setProperties(t)}return t&&o&&await Promise.all(t.map((({qProperty:e})=>o.createChild(e)))),o};return await this.rememberAsGroup(o)}catch(e){return}finally{this.mutex.unlock()}}}class pR{constructor(e){r(this,"locked",!1),r(this,"tasks",[]),r(this,"id",void 0),r(this,"lock",(async()=>this.locked?new Promise((e=>{this.tasks.push(e)})):(this.locked=!0,!0))),r(this,"unlock",(()=>{if(this.tasks.length>0){const e=this.tasks.shift();null==e||e(!0)}else this.locked=!1})),this.id=e}}const fR={aliceblue:{r:240,g:248,b:255},antiquewhite:{r:250,g:235,b:215},aqua:{r:0,g:255,b:255},aquamarine:{r:127,g:255,b:212},azure:{r:240,g:255,b:255},beige:{r:245,g:245,b:220},bisque:{r:255,g:228,b:196},black:{r:0,g:0,b:0},blanchedalmond:{r:255,g:235,b:205},blue:{r:0,g:0,b:255},blueviolet:{r:138,g:43,b:226},brown:{r:165,g:42,b:42},burlywood:{r:222,g:184,b:135},cadetblue:{r:95,g:158,b:160},chartreuse:{r:127,g:255,b:0},chocolate:{r:210,g:105,b:30},coral:{r:255,g:127,b:80},cornflowerblue:{r:100,g:149,b:237},cornsilk:{r:255,g:248,b:220},crimson:{r:220,g:20,b:60},cyan:{r:0,g:255,b:255},darkblue:{r:0,g:0,b:139},darkcyan:{r:0,g:139,b:139},darkgoldenrod:{r:184,g:134,b:11},darkgray:{r:169,g:169,b:169},darkgreen:{r:0,g:100,b:0},darkgrey:{r:169,g:169,b:169},darkkhaki:{r:189,g:183,b:107},darkmagenta:{r:139,g:0,b:139},darkolivegreen:{r:85,g:107,b:47},darkorange:{r:255,g:140,b:0},darkorchid:{r:153,g:50,b:204},darkred:{r:139,g:0,b:0},darksalmon:{r:233,g:150,b:122},darkseagreen:{r:143,g:188,b:143},darkslateblue:{r:72,g:61,b:139},darkslategray:{r:47,g:79,b:79},darkslategrey:{r:47,g:79,b:79},darkturquoise:{r:0,g:206,b:209},darkviolet:{r:148,g:0,b:211},deeppink:{r:255,g:20,b:147},deepskyblue:{r:0,g:191,b:255},dimgray:{r:105,g:105,b:105},dimgrey:{r:105,g:105,b:105},dodgerblue:{r:30,g:144,b:255},firebrick:{r:178,g:34,b:34},floralwhite:{r:255,g:250,b:240},forestgreen:{r:34,g:139,b:34},fuchsia:{r:255,g:0,b:255},gainsboro:{r:220,g:220,b:220},ghostwhite:{r:248,g:248,b:255},gold:{r:255,g:215,b:0},goldenrod:{r:218,g:165,b:32},gray:{r:128,g:128,b:128},green:{r:0,g:128,b:0},greenyellow:{r:173,g:255,b:47},grey:{r:128,g:128,b:128},honeydew:{r:240,g:255,b:240},hotpink:{r:255,g:105,b:180},indianred:{r:205,g:92,b:92},indigo:{r:75,g:0,b:130},ivory:{r:255,g:255,b:240},khaki:{r:240,g:230,b:140},lavender:{r:230,g:230,b:250},lavenderblush:{r:255,g:240,b:245},lawngreen:{r:124,g:252,b:0},lemonchiffon:{r:255,g:250,b:205},lightblue:{r:173,g:216,b:230},lightcoral:{r:240,g:128,b:128},lightcyan:{r:224,g:255,b:255},lightgoldenrodyellow:{r:250,g:250,b:210},lightgray:{r:211,g:211,b:211},lightgreen:{r:144,g:238,b:144},lightgrey:{r:211,g:211,b:211},lightpink:{r:255,g:182,b:193},lightsalmon:{r:255,g:160,b:122},lightseagreen:{r:32,g:178,b:170},lightskyblue:{r:135,g:206,b:250},lightslategray:{r:119,g:136,b:153},lightslategrey:{r:119,g:136,b:153},lightsteelblue:{r:176,g:196,b:222},lightyellow:{r:255,g:255,b:224},lime:{r:0,g:255,b:0},limegreen:{r:50,g:205,b:50},linen:{r:250,g:240,b:230},magenta:{r:255,g:0,b:255},maroon:{r:128,g:0,b:0},mediumaquamarine:{r:102,g:205,b:170},mediumblue:{r:0,g:0,b:205},mediumorchid:{r:186,g:85,b:211},mediumpurple:{r:147,g:112,b:219},mediumseagreen:{r:60,g:179,b:113},mediumslateblue:{r:123,g:104,b:238},mediumspringgreen:{r:0,g:250,b:154},mediumturquoise:{r:72,g:209,b:204},mediumvioletred:{r:199,g:21,b:133},midnightblue:{r:25,g:25,b:112},mintcream:{r:245,g:255,b:250},mistyrose:{r:255,g:228,b:225},moccasin:{r:255,g:228,b:181},navajowhite:{r:255,g:222,b:173},navy:{r:0,g:0,b:128},oldlace:{r:253,g:245,b:230},olive:{r:128,g:128,b:0},olivedrab:{r:107,g:142,b:35},orange:{r:255,g:165,b:0},orangered:{r:255,g:69,b:0},orchid:{r:218,g:112,b:214},palegoldenrod:{r:238,g:232,b:170},palegreen:{r:152,g:251,b:152},paleturquoise:{r:175,g:238,b:238},palevioletred:{r:219,g:112,b:147},papayawhip:{r:255,g:239,b:213},peachpuff:{r:255,g:218,b:185},peru:{r:205,g:133,b:63},pink:{r:255,g:192,b:203},plum:{r:221,g:160,b:221},powderblue:{r:176,g:224,b:230},purple:{r:128,g:0,b:128},rebeccapurple:{r:102,g:51,b:153},red:{r:255,g:0,b:0},rosybrown:{r:188,g:143,b:143},royalblue:{r:65,g:105,b:225},saddlebrown:{r:139,g:69,b:19},salmon:{r:250,g:128,b:114},sandybrown:{r:244,g:164,b:96},seagreen:{r:46,g:139,b:87},seashell:{r:255,g:245,b:238},sienna:{r:160,g:82,b:45},silver:{r:192,g:192,b:192},skyblue:{r:135,g:206,b:235},slateblue:{r:106,g:90,b:205},slategray:{r:112,g:128,b:144},slategrey:{r:112,g:128,b:144},snow:{r:255,g:250,b:250},springgreen:{r:0,g:255,b:127},steelblue:{r:70,g:130,b:180},tan:{r:210,g:180,b:140},teal:{r:0,g:128,b:128},thistle:{r:216,g:191,b:216},tomato:{r:255,g:99,b:71},transparent:{r:255,g:255,b:255,a:0},turquoise:{r:64,g:224,b:208},violet:{r:238,g:130,b:238},wheat:{r:245,g:222,b:179},white:{r:255,g:255,b:255},whitesmoke:{r:245,g:245,b:245},yellow:{r:255,g:255,b:0},yellowgreen:{r:154,g:205,b:50}},hR={index:-1,color:"none",alpha:1},mR=e=>{let t=parseFloat(e[1]),n=parseFloat(e[3]),r=parseFloat(e[5]);return t%=360,n/=100,r/=100,t=Math.max(0,Math.min(t,360)),n=Math.max(0,Math.min(n,1)),r=Math.max(0,Math.min(r,1)),{h:t,s:n,l:r,v:r}},gR=(e,t,n,r,o=1)=>{let i,a,l,s=[];switch(n=Math.floor(n)){case 0:s=[e,t,0];break;case 1:s=[t,e,0];break;case 2:s=[0,e,t];break;case 3:s=[0,t,e];break;case 4:s=[t,0,e];break;case 5:s=[e,0,t];break;default:s=[0,0,0]}return i=s[0]+r,a=s[1]+r,l=s[2]+r,i=Math.round(255*i),a=Math.round(255*a),l=Math.round(255*l),`rgba(${i},${a},${l},${o})`},bR=e=>{const{h:t,s:n,l:r}=mR(e),o=e.length>7?parseFloat(e[7]):1,i=r<=.5?2*r*n:(2-2*r)*n,a=t/60,l=i*(1-Math.abs(a%2-1));return gR(i,l,a,r-.5*i,o)},vR={resolveExpression:({colorExpression:e=""})=>{let t=/^rgb\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*\)$/i.exec(e);if(t)return`rgb(${t[1]},${t[2]},${t[3]})`;if(t=/^rgba\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d(\.\d+)?)\s*\)$/i.exec(e),t)return`rgba(${t[1]},${t[2]},${t[3]},${t[4]})`;if(t=/^argb\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*\)$/i.exec(e),t){const e=Math.round(Number(t[1])/255*100)/100;return`rgba(${t[2]},${t[3]},${t[4]},${e})`}if(t=/^hsl\(\s*(\d+(\.\d+)?)\s*,\s*(\d+(\.\d+)?%?)\s*,\s*(\d+(\.\d+)?%?)\s*\)$/i.exec(e),t)return bR(t);if(t=/^hsla\(\s*(\d+(\.\d+)?)\s*,\s*(\d+(\.\d+)?%?)\s*,\s*(\d+(\.\d+)?%?)\s*,\s*(\d(\.\d+)?)\s*\)$/i.exec(e),t)return bR(t);if(t=/^hsv\(\s*(\d+(\.\d+)?)\s*,\s*(\d+(\.\d+)?%?)\s*,\s*(\d+(\.\d+)?%?)\s*\)$/i.exec(e),t)return(e=>{const{h:t,s:n,v:r}=mR(e),o=r*n,i=t/60,a=o*(1-Math.abs(i%2-1));return gR(o,a,i,r-o)})(t);if(t=/^#([A-Fa-f0-9]{2})([A-Fa-f0-9]{2})([A-Fa-f0-9]{2})$/i.exec(e),t)return e;if(t=/^#([A-Fa-f0-9])([A-Fa-f0-9])([A-Fa-f0-9])$/i.exec(e),t)return e;const n=e&&fR[e.toLowerCase()];if(n){const e=void 0!==n.a?n.a:1;return`rgba(${n.r},${n.g},${n.b},${e})`}return"none"},getColor({style:e,defaultColor:t,theme:n}){const r=(null==e?void 0:e.color)||hR;let o;return o=null!=e&&e.useColorExpression?vR.resolveExpression(e):"string"==typeof r?r:(null==n?void 0:n.getColorPickerColor(r))||"",o&&"none"!==o?o:t}};class yR{constructor({modifiedLayout:e,themeService:t}){var n;r(this,"modifiedLayout",void 0),r(this,"themeStyle",void 0),r(this,"style",void 0),r(this,"objectMap",void 0),r(this,"activeTabId",void 0),r(this,"theme",void 0),r(this,"getTabsWidth",(e=>{const t=this.resolveComponentStyle({compPath:"width.value",themePath:"tabWidth.value"});if(void 0===t||2!==t.length||e!==this.modifiedLayout.orientation)return{};const n=this.resolveComponentStyle({compPath:"width.unit",themePath:"tabWidth.unit",defaultValue:"%"});return{minWidth:`${t[0]}${n}`,maxWidth:`${t[1]}${n}`}})),r(this,"getTabWidth",(e=>{var t;const n=null==e?void 0:e.value,r=null!==(t=null==e?void 0:e.unit)&&void 0!==t?t:"%";if(void 0===n||2!==n.length||"left"===this.modifiedLayout.orientation)return{};return{minWidth:`${n[0]}${r}`,maxWidth:`${n[1]}${r}`}})),r(this,"getColorStyle",((e,t=e)=>{const n=this.resolveComponentStyle({compPath:e,themePath:t}),r=vR.getColor({style:n,theme:this.theme});return null!=r?r:n})),r(this,"getTabBackgroundStyle",((e,t)=>{let n;if(this.activeTabId===e){const e=this.resolveComponentStyle({compPath:"background.selected",themePath:""});n=vR.getColor({style:e,theme:this.theme})}return null!=n?n:vR.getColor({style:t,theme:this.theme})})),r(this,"createTabClasses",(()=>{var e;return null===(e=this.modifiedLayout.objects)||void 0===e?void 0:e.reduce(((e,t)=>{var n;const r=null==t?void 0:t.childRefId,o=null==t||null===(n=t.components)||void 0===n?void 0:n.find((e=>"tab"===e.key));return e[`#tab-${this.modifiedLayout.qInfo.qId}-${r}`]={textAlign:XC(o,"label.alignment"),backgroundColor:this.getTabBackgroundStyle(r,null==o?void 0:o.background),...this.getTabWidth(null==o?void 0:o.width)},e[`#tab-${this.modifiedLayout.qInfo.qId}-${r}:hover`]={..."left"===this.modifiedLayout.orientation&&{backgroundColor:this.getColorStyle("background.hover","background.hover.color")}},e[`#tab-label-${this.modifiedLayout.qInfo.qId}-${r}`]={fontSize:XC(o,"label.fontSize"),fontFamily:XC(o,"label.fontFamily"),color:vR.getColor({style:XC(o,"label.color"),theme:this.theme})},e[`#tab-icon-${this.modifiedLayout.qInfo.qId}-${r} svg`]={height:XC(o,"icon.size"),color:vR.getColor({style:XC(o,"icon.color"),theme:this.theme})},e}),{})})),r(this,"createTabsClasses",(()=>({[nR.TABS_LABEL]:{fontSize:this.resolveComponentStyle({compPath:"label.fontSize",themePath:"label.value.fontSize"}),fontFamily:this.resolveComponentStyle({compPath:"label.fontFamily",themePath:"label.value.fontFamily"}),color:this.resolveComponentStyle({compPath:"label.color.color",themePath:"label.value.color"})},[nR.TABS_ICON]:{height:this.resolveComponentStyle({compPath:"icon.size",themePath:"icon.value.fontSize"}),color:this.getColorStyle("icon.color","icon.value.color")},[nR.TABS]:{textAlign:this.resolveComponentStyle({compPath:"label.alignment",themePath:"label.textAlignment"}),...this.getTabsWidth("top")},[nR.TABS_HOVER]:{..."top"===this.modifiedLayout.orientation&&{borderBottomColor:this.getColorStyle("indicator.hover","indicator.hover.color")}},[nR.TABS_WRAPPER]:{...this.getTabsWidth("left"),backgroundColor:this.getColorStyle("background.unselected","")},[nR.TAB_INDICATOR]:{backgroundColor:this.getColorStyle("indicator.selected","indicator.selected.color")}}))),r(this,"createStyleClasses",(()=>({...this.createTabsClasses(),...this.createTabClasses()}))),r(this,"resolveComponentStyle",(({key:e="tabs",compPath:t,themePath:n=t,defaultValue:r})=>{var o,i,a;const l=null===(o=this.modifiedLayout.components)||void 0===o?void 0:o.find((t=>t.key===e));return null!==(i=null!==(a=XC(l,t))&&void 0!==a?a:XC(this.themeStyle,n))&&void 0!==i?i:r})),this.modifiedLayout=e;const{cachedTabId:o,defaultTabId:i,objects:a}=this.modifiedLayout;this.activeTabId=o||i||(null===(n=a[0])||void 0===n?void 0:n.childRefId)||"",this.themeStyle=t.getStyles(),this.theme=t.getTheme(),this.objectMap=Cw(this.modifiedLayout),this.style=this.createStyleClasses()}getStyleClasses(){return this.style}getTabStyle(e){var t;return null===(t=this.objectMap[e].components)||void 0===t?void 0:t.find((e=>"tab"===e.key))}}const xR=()=>{const t=e.useElement(),n=e.useApp(),r=e.useStaleLayout(),o=e.useEmbed(),i=e.useModel(),a=e.useTranslator(),l=e.useOptions(),s=e.useEmitter(),u=e.useInteractionState(),c=function(e){var t=e.theme,n=e.config,r=void 0===n?{}:n,o=r.id,i=r.resolve,a=void 0===i?[]:i,l=r.transform,s=void 0===l?[]:l,u=r.extend,c=void 0===u?[]:u,d={theme:t,matrix:fk(a),styles:void 0};return d.styles=mk({theme:t,id:o,transform:s,extend:c,matrix:d.matrix}),{getStyles:function(){return d.styles},getTheme:function(){return d.theme},setTheme:function(e){d.theme=e,d.styles=mk({theme:e,id:o,transform:s,extend:c,matrix:d.matrix})}}}({theme:e.useTheme(),config:{id:"tabbedContainer",resolve:[["object.tabbedContainer","indicator.selected","color"],["object.tabbedContainer","indicator.hover","color"],["object.tabbedContainer","background.hover","color"],["object.tabbedContainer","icon.value","color"],["object.tabbedContainer","icon.value","fontSize"]]}}),d=e.useMemo((()=>new ew(o,a)),[o,a]),[p]=e.useState((()=>new pR(i.id))),[f,h]=e.useState(!1),m=e.useMemo((()=>o&&i&&n?new dR({embed:o,model:i,app:n,translator:a,mutex:p}):void 0),[o,i,n,a,p]),g=e.useMemo((()=>Sw(r)),[r]),b=e.useMemo((()=>new yR({modifiedLayout:g,themeService:c})),[g,c]);return e.useMemo((()=>({app:n,modifiedLayout:g,embed:o,model:i,emitter:s,interactions:u,dataHandler:m,chartList:d,styleModel:b,mutex:p,options:l,accessibility:f,setAccessibility:h,translator:a,element:t})),[g,o,i,n,s,u,m,d,b,p,l,f,a,t])},ER=({dataHandler:e,modifiedLayout:t,translator:n,sharedContainerUtilities:r,Icon:o})=>{const[i,a]=Y.useState(void 0);if(!e||!t)return null;const l=!t.qExtendsId;return q.createElement(lw,null,q.createElement(aw,null,q.createElement(o,null),l?q.createElement(q.Fragment,null,q.createElement(pw,{sx:{width:250,height:32,fontFamily:"inherit"},className:"init-button",variant:i?"contained":"outlined",onClick:e=>{a(e.currentTarget)},"aria-label":n.get("LayoutContainer.EmptyList.AddContent"),disableRipple:!0},n.get("LayoutContainer.EmptyList.AddContent")),q.createElement(bw,{translator:n,anchorEl:i,dataHandler:e,onClose:()=>{a(void 0)},sharedContainerUtilities:r})):q.createElement(Hy,{variant:"inherit"},n.get("LayoutContainer.EmptyList.EmptyHint"))))};class SR{constructor(e){r(this,"_rendered",new Set),r(this,"_objectMap",new Map),r(this,"_objectApis",new Map),r(this,"_resolver",void 0),r(this,"_dependencyData",void 0),r(this,"_recreateMap",new Map),r(this,"createTimerForRendering",(()=>{if(!this.resolver){let e;const t=setTimeout((()=>{this.doResolve()}),9e4),n=new Promise((t=>{e=t}));this._resolver={promise:n,resolve:e,timer:t}}return this._resolver})),r(this,"doResolve",(()=>{var e,t,n;this.resolver&&(clearTimeout(null===(e=this.resolver)||void 0===e?void 0:e.timer),null===(t=(n=this.resolver).resolve)||void 0===t||t.call(n,!0),this._resolver=void 0)})),r(this,"tryToResolve",(()=>{const{visibleLayoutObjects:e}=this._dependencyData;if(this.resolver){(0===e.length||e.every((e=>this.rendered.has(e.id))))&&this.doResolve()}})),this._dependencyData=e}set dependencyData(e){this._dependencyData=e}get rendered(){return this._rendered}get objectMap(){return this._objectMap}get objectApis(){return this._objectApis}get resolver(){return this._resolver}get recreateMap(){return this._recreateMap}syncObjects(e){const t=new Set,n=new Set([...Array.from(this.objectMap.keys()),...Array.from(this.objectApis.keys()),...this.rendered]),r=new Set(n);let o=!1;return e.forEach((e=>{n.has(e.id)?(this.rendered.has(e.id)&&t.add(e.id),r.delete(e.id)):o=!0})),r.forEach((e=>{var t;const n=this.objectMap.get(e);var r;n&&(this.confirmPotentialSelections(n),null===(r=n.destroy)||void 0===r||r.call(n),this.objectMap.delete(e));null===(t=this.objectApis.get(e))||void 0===t||t.destroy(),this.objectApis.delete(e)})),this._rendered=t,this.tryToResolve(),o}destroy(){for(const e of this.objectApis.values())e.destroy();this._objectMap=new Map,this._objectApis=new Map}saveObject(e,t){this.objectMap.set(e,t)}saveObjectApi(e,t){this._objectApis.set(e,t)}onRendered(e){this.rendered.add(e),this.tryToResolve()}getChildrenObjects(){const{visibleLayoutObjects:e}=this._dependencyData,t=[];return e.forEach((e=>{const n=this.objectMap.get(e.id);n&&t.push(n)})),t}getChildLayout(e){const{modifiedLayout:t}=this._dependencyData;return t.qChildList.qItems.find((t=>t.qInfo.qId===e))}getObjectOptions(e){var t,n;const{viewState:r,modifiedLayout:o,options:i}=this._dependencyData,{chartAnimations:a,direction:l,progressiveRendering:s,freeResize:u,navigation:c}=i;return{isReadonly:!1,setController:t=>{this.saveObject(e,t)},onRendered:()=>{this.onRendered(e)},onInitialRender:()=>{this.onRendered(e)},isParentMaster:!(null==o||!o.qExtendsId),isSnapshot:!!o.snapshotData,...!(null==r||null===(t=r.viewStates)||void 0===t||!t[e])&&{viewState:null==r?void 0:r.viewStates[e]},...!(null==r||null===(n=r.layouts)||void 0===n||!n[e])&&{layout:r.layouts[e]},direction:l,chartAnimations:a,progressiveRendering:s,freeResize:u,navigation:c,disableThemeBorder:!1,fallbackToClient:i.fallbackToClient}}confirmPotentialSelections(e){e&&"selectionsApi"in e&&e.selectionsApi.active&&e.selectionsApi.confirm()}}const wR=()=>q.createElement(fw,{viewBox:"0 0 16 16"},q.createElement("path",{d:"M15 6V5H5V2H1.5a.5.5 0 0 0-.5.5V6H0V2a1 1 0 0 1 1-1h14a1 1 0 0 1 1 1v4h-1Zm-5-4H6v2h4V2Zm4.5 0H11v2h4V2.5a.5.5 0 0 0-.5-.5Zm1.5 9h-1V8h1v3Zm0 3a1 1 0 0 1-1 1h-1v-1h.6a.4.4 0 0 0 .4-.4V13h1v1Zm-7 1v-1h3v1H9Zm-5 0v-1h3v1H4Zm-3 0a1 1 0 0 1-1-1v-1h1v.6c0 .22.18.4.4.4H2v1H1ZM0 8h1v3H0V8Zm4-.5a.5.5 0 0 1 .5-.5h7a.5.5 0 0 1 .5.5v4a.5.5 0 0 1-.5.5h-7a.5.5 0 0 1-.5-.5v-4ZM5 11h6V8H5v3Z"})),CR=({libraryInfo:e,style:t,id:n})=>q.createElement("div",{style:t,"data-testid":"tab-chart-icon",id:n,className:tR.TABS_ICON},q.createElement(e.IconDefinition,null)),kR=({style:e,id:t})=>q.createElement("div",{style:e,"data-testid":"tab-hidden-icon",id:t},q.createElement(hw,{viewBox:"0 0 16 16"},q.createElement("path",{d:"m13.441.795.764.646-1.839 2.174c.568.434 1.076.914 1.522 1.385a13.79 13.79 0 0 1 2.109 3 13.798 13.798 0 0 1-2.108 3c-1.382 1.457-3.345 3-5.89 3-1.34 0-2.52-.428-3.536-1.045l-1.904 2.25-.764-.646L13.441.795ZM11.72 4.379l-1.427 1.686a3 3 0 0 1-3.82 4.516l-1.354 1.6c.86.497 1.819.819 2.88.819 2.121 0 3.834-1.287 5.161-2.685A12.666 12.666 0 0 0 14.857 8a12.691 12.691 0 0 0-1.697-2.315c-.35-.37-.727-.73-1.132-1.063l-.308-.243ZM8 2a6.428 6.428 0 0 1 2.242.412l.305.123-.681.805A5.359 5.359 0 0 0 8 3C5.877 3 4.164 4.287 2.837 5.685A12.664 12.664 0 0 0 1.14 8a12.66 12.66 0 0 0 1.697 2.315l.301.308.311.299-.646.765A14.567 14.567 0 0 1 2.109 11 13.791 13.791 0 0 1 0 8a13.801 13.801 0 0 1 2.109-3C3.49 3.543 5.454 2 8 2Zm1.633 4.845-2.5 2.956a1.999 1.999 0 0 0 2.5-2.956Zm-3.917-.793a3 3 0 0 1 2.692-1.025l.202.035-.809.948A2 2 0 0 0 6 7.967l.003.152-.808.947a3 3 0 0 1 .521-3.014Z"}))),RR=()=>q.createElement(hw,{viewBox:"0 0 16 16"},q.createElement("path",{d:"M12 4H6V3h6v1ZM6 8.5h4v-1H6v1Zm9 4.5H6v-1h9v1ZM3 11a1 1 0 0 1 1 1v1a1 1 0 0 1-1 1H2a1 1 0 0 1-1-1v-1a1 1 0 0 1 1-1h1Zm0 1H2v1h1v-1Zm0-5.5a1 1 0 0 1 1 1v1a1 1 0 0 1-1 1H2a1 1 0 0 1-1-1v-1a1 1 0 0 1 1-1h1Zm0 1H2v1h1v-1ZM3 2a1 1 0 0 1 1 1v1a1 1 0 0 1-1 1H2a1 1 0 0 1-1-1V3a1 1 0 0 1 1-1h1Zm0 1H2v1h1V3Z"})),_R=wl(wS)({width:28,overflow:"hidden"}),TR=wl(wS)({height:28,width:"100%",overflow:"hidden",alignItems:"center","&::before":{visibility:"hidden"}}),LR=({chartObject:e,embed:t,renderHelper:n,direction:r,interactions:o,env:i})=>{const a=Y.useRef(null),{id:l}=e;Y.useEffect((()=>{if(l&&a.current){const e=n.getObjectOptions(l)||{};e.disableThemeBorder=!0,t.render({id:l,element:a.current,options:e}).then((e=>{n.saveObjectApi(l,e)})).catch((e=>{var t;const r=null===(t=n.getChildLayout(l))||void 0===t||null===(t=t.qInfo)||void 0===t?void 0:t.qType;console.error("Could not render chart with id",l,r,e)}))}}),[l,t,n,r]);const s=Y.useMemo((()=>()=>{if(null!=e&&e.id&&i.anything){const t=null==e?void 0:e.label,{sense:r}=i.anything,o="current",a=n.objectMap.get(e.id);a&&r.propertyPanel.show({model:a.model,parent:o,headerLabel:t,keepCurrentActiveCell:!0})}}),[i,e,n]);return Y.useEffect((()=>{const e=null==a?void 0:a.current;return e&&null!=o&&o.edit&&e.addEventListener("dblclick",s),()=>{null==e||e.removeEventListener("dblclick",s)}}),[a,s,o]),q.createElement("div",{ref:a,style:{position:"relative",height:"100%",width:"100%"},"data-testid":`tab-panel-${e.childRefId}`})};var PR;!function(e){e.TABS_HEIGHT="36px"}(PR||(PR={}));const AR=(e,t)=>e.find((e=>e.childRefId===t)),IR=(e,t)=>!t.edit&&0===e.condition,OR=({charts:e,handleChangeTab:t,activeTabId:n,element:r,translator:o,accessibility:i,disabled:a})=>{const[l,s]=q.useState(null),u=Boolean(l),c=()=>{s(null)},d=Y.useCallback((e=>{null==e||e.focus()}),[]);return q.createElement(q.Fragment,null,q.createElement(kx,{onClick:e=>{s(e.currentTarget)},disabled:a,"aria-haspopup":"menu","data-testid":"chartTabMenuDropdownButton",tabIndex:i?0:-1,"aria-label":o.get("Container.Label.Visualizations"),className:tR.TAB_MENU,sx:{m:"2px"}},q.createElement(RR,null)),q.createElement(rS,{anchorEl:l,open:u,onClose:c,elevation:0,anchorOrigin:{vertical:"bottom",horizontal:"left"},transformOrigin:{vertical:"top",horizontal:"left"},MenuListProps:{sx:{py:0}},slotProps:{paper:{sx:{maxHeight:"500px",maxWidth:"500px"}}}},e.map((e=>q.createElement(sS,{className:tR.TAB_MENU_ITEM,ref:n===e.childRefId&&u?d:null,key:`chartTabMenu-${e.childRefId}`,onClick:()=>{(e=>{t(e.childRefId),c(),window.setTimeout((()=>{var e;null===(e=r.getElementsByClassName(tR.ACTIVE_TAB_PANEL))||void 0===e||null===(e=e[0])||void 0===e||e.focus()}),0)})(e)},sx:{...n===e.childRefId?{backgroundColor:"rgba(0, 0, 0, 0.1)"}:{}},"aria-label":e.label,title:e.label},q.createElement(Hy,{variant:"inherit",noWrap:!0},e.label))))))},MR=({label:e,id:t})=>q.createElement(mx,{className:tR.TAB_LABEL,id:`tab-label-${t}`,sx:{width:"100%",height:"100%",display:"flex",alignItems:"center",overflow:"hidden",flexWrap:"wrap"}},q.createElement("span",{style:{width:"100%",overflowWrap:"break-word",hyphens:"auto",fontWeight:"bold",display:"-webkit-box",WebkitLineClamp:3,WebkitBoxOrient:"vertical",lineHeight:"normal",overflow:"hidden"}},e)),NR=({libraryInfo:e,chart:t,iconPosition:n,id:r})=>{let o;switch(n){case"bottom":o={marginTop:"6px"};break;case"top":o={marginBottom:"6px"};break;case"end":o={marginInlineStart:"8px"};break;default:o={marginInlineEnd:"8px"}}o.display="flex",o.alignItems="center",o.height="100%",o.flex="1 0 0";return 0===t.condition?q.createElement(kR,{id:`${tR.TABS_ICON}-${r}`,style:o}):e?q.createElement(CR,{id:`${tR.TABS_ICON}-${r}`,libraryInfo:e,style:o}):null},zR=({models:e,activeTabId:t,handleChangeTab:n})=>{const{modifiedLayout:r,chartList:o,interactions:i,accessibility:a}=e,l=null==o?void 0:o.getCharts(),s=r.objects.filter((e=>!IR(e,i))),{orientation:u,tabContainerStyle:c,ScrollButtonComponent:d}=(({orientation:e})=>"left"===e?{orientation:"vertical",tabContainerStyle:{display:"flex",flexDirection:"column",alignItems:"center",maxWidth:"25%",flexShrink:0},ScrollButtonComponent:TR}:{orientation:"horizontal",tabContainerStyle:{display:"flex",flexDirection:"row",alignItems:"center"},ScrollButtonComponent:_R})(r),p=!1===i.active&&!i.edit,[f,h]=Y.useState(!1),m=Y.useCallback((e=>{if(e){const t=e.getElementsByClassName("MuiTabs-flexContainer")[0];if(t)return void h("vertical"===u?t.scrollHeight>t.offsetHeight:t.scrollWidth>t.offsetWidth)}h(!1)}),[u]);return q.createElement(mx,{className:tR.TAB_WRAPPER,sx:c,ref:e=>{m(e)}},r.useDropdown&&f&&q.createElement(OR,{charts:s,handleChangeTab:n,activeTabId:t,accessibility:a,translator:e.translator,element:e.element,disabled:p}),q.createElement(zS,{value:t,onChange:(e,t)=>{n(t)},ScrollButtonComponent:d,variant:"scrollable",orientation:u,scrollButtons:!!r.useScrollButton&&"auto",TabScrollButtonProps:{...p&&{disabled:!0}},sx:{height:"100%",width:"100%",minHeight:PR.TABS_HEIGHT}},s.map((n=>{var o,i,s,c,d;const f=null===(o=Ew(r,n.childRefId))||void 0===o||null===(o=o.qData)||void 0===o?void 0:o.visualization,h=f&&(null==l||null===(i=l[f])||void 0===i?void 0:i.libraryInfo),m=e.styleModel.getTabStyle(n.childRefId),g=0===n.condition||r.showIcons&&h&&!1!==(null==m||null===(s=m.icon)||void 0===s?void 0:s.show),b="vertical"===u?"top":"start",v=e.styleModel.resolveComponentStyle({compPath:"icon.position",defaultValue:b}),y=e.styleModel.resolveComponentStyle({compPath:"label.show"}),x=n.label&&(null!==(c=null==m||null===(d=m.label)||void 0===d?void 0:d.show)&&void 0!==c?c:!1!==y),E=`${r.qInfo.qId}-${n.childRefId}`;return q.createElement(fS,{className:`${tR.TAB} ${t===n.childRefId?tR.ACTIVE_TAB:""}`,disabled:p,id:`tab-${E}`,value:n.childRefId,title:n.label,label:x?q.createElement(MR,{label:n.label,id:E}):void 0,icon:g?q.createElement(NR,{libraryInfo:h,chart:n,iconPosition:v,id:E}):"",iconPosition:v,key:n.childRefId,"data-testid":`container-tab-${n.childRefId}`,sx:{textAlign:"vertical"!==u||r.showIcons?"center":"start",minWidth:"vertical"===u?"100%":void 0,minHeight:PR.TABS_HEIGHT,padding:"6px 16px","&:hover":{paddingBottom:"4px"},"&.Mui-disabled":{opacity:"inherit"}},"aria-label":n.label,"aria-controls":`tab-panel-${E}`,tabIndex:a&&t===n.childRefId?0:-1})}))))},jR=({models:e,renderHelper:t,activeTabId:n,handleChangeTab:r,env:o})=>{const{modifiedLayout:i,embed:a,interactions:l,options:s,styleModel:u,accessibility:c}=e,d=i.objects,p=l.edit||!!d.find((e=>0!==e.condition)),f=i.showTabs&&p,h="left"===i.orientation?"row":"column",m=u.getStyleClasses();return q.createElement(mx,{sx:{display:"flex",flexDirection:h,height:"100%",width:"100%",direction:s.direction,...m}},f&&q.createElement(zR,{models:e,activeTabId:n,handleChangeTab:r}),d.map((e=>{const r=`tab-panel-${i.qInfo.qId}-${e.childRefId}`,u=n===e.childRefId&&!IR(e,l);return q.createElement(mx,{role:"tabpanel",id:r,key:r,"aria-label":e.label,sx:{height:"100%",width:"100%",padding:"2px",boxSizing:"border-box",direction:"ltr",flex:"1 0 0","&:focus-visible":{boxShadow:"inset 0 0 0 2px #0275D9",borderRadius:"3px",zIndex:1200}},...u?{className:tR.ACTIVE_TAB_PANEL,tabIndex:c?0:-1}:{hidden:!0}},u&&q.createElement(LR,{chartObject:e,renderHelper:t,direction:s.direction,embed:a,interactions:l,env:o}))})))};let $R=function(e){return e.COPY="copy",e.PASTE="paste",e.RESET_COPY_BUFFER="resetCopyBuffer",e}({}),DR=function(e){return e.COPY="copy",e.PASTE="paste-and-replace",e.DUPLICATE="duplicate",e.DELETE="delete",e.CUT="cut",e.EDIT_PROPERTIES="edit",e.ZOOM_IN="zoom-in",e.VISUAL_EXPLORATION="visual-exploration",e.MONITOR_IN_HUB="addto",e.TAKE_SNAP_SHOT="take-snapshot",e.SNAP_SHOT_GROUP="snapshotGroup",e.REORDER_LAYERS_GROUP="reorder-layers-group",e.BRING_TO_FRONT="bring-to-front",e.BRING_FORWARD="bring-forward",e.SEND_TO_BACK="send-to-back",e.SEND_BACKWARDS="send-backwards",e.CONTAINER_HEADER="container-header",e.CHART_HEADER="chart-header",e.ALERT_GROUP="alertGroup",e.ADD_TO_MASTER_ITEMS="add-to-master-items",e.UNLINK_VISUALIZATION="unlink",e.DEVELOPER="object-developer",e.SHOW_DETAILS="object-info",e.EXPLAIN_KEY_DRIVERS_OLD_ID="explainKeyDrivers",e.EXPLAIN_KEY_DRIVERS="key-driver",e.SUBSCRIBE="subscribe",e.NOTES_GROUP="notesGroup",e.DOWNLOAD="download",e.SHARE_IMAGE="share",e}({});const BR=[DR.PASTE,DR.ZOOM_IN,DR.VISUAL_EXPLORATION],FR=[DR.VISUAL_EXPLORATION,DR.ALERT_GROUP,DR.SHOW_DETAILS,DR.EXPLAIN_KEY_DRIVERS,DR.EXPLAIN_KEY_DRIVERS_OLD_ID],HR=[DR.DELETE,DR.CUT,DR.ADD_TO_MASTER_ITEMS,DR.UNLINK_VISUALIZATION],UR=[DR.PASTE],VR=(e,t)=>{const{childRefId:n}=e.model.layout,r=t.objects.find((e=>e.childRefId===n));return{...e,additionalData:{label:null==r?void 0:r.label}}},GR=(e,t,n,r,o)=>{const i=t.getSupportFunction(DR.COPY);if(!i)return void e.deleteItem(DR.COPY);const a=()=>{i(VR(n,r)).catch((()=>{}))},l=e.items.find((e=>e.id===DR.COPY));if(l)l.updateItem({select:a});else if(o){const t=e.items.findIndex((e=>e.id===DR.CUT)),n=t>=0?1+t:void 0;e.addItem({translation:"contextMenu.copy",tid:DR.COPY,id:DR.COPY,icon:"copy",select:a,items:[]},n)}},WR=e=>e.interactions.edit&&!e.modifiedLayout.qExtendsId,YR=async(e,t,n,r)=>{const o=t.getBuilder("default");if(!o)return;const i=await o();i.addItem({translation:"contextMenu.containerOptionsHeader",tid:DR.CONTAINER_HEADER,id:DR.CONTAINER_HEADER,bold:!0,items:[]},0);const a=WR(n);i.items.forEach((e=>{(FR.includes(e.id)||!a&&UR.includes(e.id))&&i.deleteItem(e.id)})),a&&await(async(e,t,n)=>{var r;const o=t.getSupportFunction($R.PASTE),i=await(null==o||null===(r=o())||void 0===r?void 0:r.catch((()=>{})));if(!i||JS.includes(i.template))return void e.deleteItem(DR.PASTE);const a=()=>{n()},l=e.items.find((e=>e.id===DR.PASTE));if(l)l.updateItem({translation:"contextMenu.paste",select:a});else{const t=e.items.findLastIndex((e=>e.id===DR.COPY||e.id===DR.DEVELOPER||e.id===DR.CONTAINER_HEADER)),n=t>=0?1+t:void 0;e.addItem({translation:"contextMenu.paste",tid:DR.PASTE,id:DR.PASTE,icon:"paste",select:a,items:[]},n)}})(i,t,r),e.updateItem({items:i.items}),1===e.items.length&&e.deleteItem(DR.CONTAINER_HEADER)},qR=e=>{const t={[DR.MONITOR_IN_HUB]:!0,[DR.SUBSCRIBE]:!0,[DR.NOTES_GROUP]:!0,[DR.DOWNLOAD]:!0,[DR.SHARE_IMAGE]:!0};e.items.forEach((n=>{t[n.id]?e.deleteItem(n.id):n.items&&qR(n)}))},KR=(e,t,n,r,o,i)=>a=>{const{dataHandler:l,modifiedLayout:s}=r;if(WR(r)){n.isInvalid||(((e,t,n,r)=>{const{model:o,modifiedLayout:i}=n,a=e.items.findLastIndex((e=>e.id===DR.CHART_HEADER||e.id===DR.REORDER_LAYERS_GROUP)),l=a>=0?1+a:void 0;e.addItem({translation:"Object.Container.Props.EditProperties",tid:DR.EDIT_PROPERTIES,id:DR.EDIT_PROPERTIES,icon:DR.EDIT_PROPERTIES,items:[],select:()=>{const{childRefId:e}=t.model.layout,n=i.objects.find((t=>t.childRefId===e)),a=null==n?void 0:n.label,{sense:l}=r.anything,s=o;l.propertyPanel.show({model:t.model,parent:s,headerLabel:a})}},l)})(a,n,r,o),((e,t,n,r,o,i)=>{const a=r.getSupportFunction(DR.COPY);if(!a)return void e.deleteItem(DR.CUT);const l=()=>{o&&a(VR(n,i)).then((async()=>{await(null==o?void 0:o.deleteChildren([t]))})).catch((()=>{}))},s=e.items.find((e=>e.id===DR.CUT));if(s)s.updateItem({select:l});else{const t=e.items.findLastIndex((e=>e.id===DR.ADD_TO_MASTER_ITEMS||e.id===DR.UNLINK_VISUALIZATION||e.id===DR.EDIT_PROPERTIES||e.id===DR.REORDER_LAYERS_GROUP||e.id===DR.DEVELOPER)),n=t>=0?1+t:void 0;e.addItem({translation:"contextMenu.cut",tid:DR.CUT,id:DR.CUT,icon:"cut",select:l,items:[]},n)}})(a,t,n,e,l,s),GR(a,e,n,s,!0),((e,t,n,r,o)=>{const i=t.getSupportFunction($R.COPY),a=t.getSupportFunction($R.PASTE);if(!i||!a)return void e.deleteItem(DR.DUPLICATE);const l=()=>{i(VR(n,r)).then((()=>{o()})).catch((()=>{}))},s=e.items.find((e=>e.id===DR.DUPLICATE));if(s)s.updateItem({select:l});else{const t=e.items.findIndex((e=>e.id===DR.COPY)),n=t>=0?1+t:void 0;e.addItem({translation:"Common.Duplicate",tid:DR.DUPLICATE,id:DR.DUPLICATE,icon:DR.DUPLICATE,items:[],select:l},n)}})(a,e,n,s,i)),((e,t,n)=>{const r=()=>{n&&n.deleteChildren([t]).catch((()=>{}))},o=e.items.find((e=>e.id===DR.DELETE));if(o)o.updateItem({select:r});else{const t=e.items.findLastIndex((e=>e.id===DR.DUPLICATE||e.id===DR.ADD_TO_MASTER_ITEMS||e.id===DR.UNLINK_VISUALIZATION||e.id===DR.REORDER_LAYERS_GROUP||e.id===DR.DEVELOPER)),n=t>=0?1+t:void 0;e.addItem({translation:"Common.Delete",tid:DR.DELETE,id:DR.DELETE,icon:"bin",items:[],select:r},n)}})(a,t,l)}else GR(a,e,n,s,!1)},XR=(t,n,r,o)=>{e.onContextMenu((async(e,i,a)=>{var l;if(!a)return!1;const s=((e,t)=>()=>{if(!e)return;const n=t.getSupportFunction($R.PASTE);n&&n().then((async({template:t,init:n,children:r,additionalData:o})=>{const{label:i}=o,a={label:i};n.qExtendsId?await e.addMasterObjectAsChild({initProps:n,children:r,objectInitProps:a}):await e.addVizAsChild({type:t,initProps:n,children:r,objectInitProps:a})})).catch((e=>{e&&t.getSupportFunction($R.RESET_COPY_BUFFER)}))})(r.dataHandler,a);if(await YR(e,a,r,s),qR(e),!(e=>{var t;let n;n="qv-radial-contextmenu"===e.type?null===(t=e.touches[0])||void 0===t?void 0:t.target:e.target;return n&&((e,t)=>{let n=e;for(;n;){var r;if(null!==(r=n.classList)&&void 0!==r&&r.contains(t))return n;n=n.parentNode}return null})(n,tR.ACTIVE_TAB_PANEL)})(i))return!0;const u=null===(l=r.modifiedLayout.objects.find((e=>e.childRefId===t)))||void 0===l?void 0:l.id;if(!u)return!0;const c=n.objectMap.get(u);if(!c)return!0;const d=KR(a,t,c,r,o,s),p=await(async(e,t,n,r)=>{const o=WR(n),i=e.getBuilder("object");if(!i)return;const a=await i(t);return a.addItem({translation:"contextMenu.chartOptionsHeader",tid:DR.CHART_HEADER,id:DR.CHART_HEADER,bold:!0,items:[]},0),r(a),a.items.forEach((e=>{(BR.includes(e.id)||!o&&HR.includes(e.id))&&a.deleteItem(e.id)})),1===a.items.length&&a.deleteItem(DR.CHART_HEADER),a})(a,c,r,d);return!p||(e.items.length>0&&p.addItem({translation:"contextMenu.subMenuContainerOptions",tid:"tabbed-container-menu",id:"tabbed-container-menu",icon:"tabbed-container",items:[...e.items]},p.items.length),e.updateItem({items:p.items}),!0)}))},QR=({element:t,models:n,env:r})=>{var o;const i=((t,n)=>{const[r,o]=e.useState(void 0);return e.useEffect((()=>{if(0===t.getElementsByClassName(n).length){const e=document.createElement("div");e.className=n,t.appendChild(e);const r=tw(e);o(r)}return()=>{null==r||r.unmount()}}),[t,n,r]),r})(t,"init-component"),{options:a,modifiedLayout:l,interactions:s,model:u}=n,{cachedTabId:c,defaultTabId:d,objects:p,qChildList:f}=l,h=QS(a.direction),m=(t=>{const{viewState:n}=e.useOptions(),{snapshotData:r}=t;if(r){var o;const{layouts:e}=r.objectsData;return{layouts:e,viewStates:null===(o=r.viewState)||void 0===o?void 0:o.viewStates}}if(n){const{viewStates:e}=n;return{viewStates:e}}})(l),g=c||d||(null===(o=p[0])||void 0===o?void 0:o.childRefId)||"",b={modifiedLayout:l,activeTabId:g,env:r},[v,y]=aR(b);y(b);const x=e.useMemo((()=>l.objects.filter((e=>g===e.childRefId))),[g,l.objects]),{renderHelper:E}=(t=>{const{visibleLayoutObjects:n,options:r}=t,[o]=e.useState((()=>new SR(t))),[,i]=e.useState(r);return o.dependencyData=t,e.usePromise((async()=>{var e,t;return i((e=>(e!==r&&n.forEach((e=>o.recreateMap.set(e.id,!0))),r))),o.syncObjects(n)?null===(t=o.createTimerForRendering())||void 0===t?void 0:t.promise:null===(e=o.resolver)||void 0===e?void 0:e.promise}),[n,r]),e.useEffect((()=>()=>{o.destroy()}),[o]),{renderHelper:o}})({modifiedLayout:l,visibleLayoutObjects:x,viewState:m,options:a});XR(g,E,n,r);const[S]=e.useState({current:void 0}),w=e.useMemo((()=>e=>{(async({model:e,patchList:t})=>{if(null!=e&&e.applyPatches){const n=await e.getEffectiveProperties(),r=[];t.forEach((e=>{const{newValue:t,propertyName:o}=e,i=void 0!==n[o]?"Replace":"Add";t?r.push({qPath:`/${o}`,qOp:i,qValue:t&&JSON.stringify(t)}):"Replace"===i&&r.push({qPath:`/${o}`,qOp:"Remove"})})),r.length>0&&await e.applyPatches(r,!0)}})({model:u,patchList:[{newValue:e,propertyName:"cachedTabId"}]})}),[u]),C=e.useMemo((()=>({setSelected:e=>{var t;const n=null===(t=v.modifiedLayout.objects.find((t=>t.id===e[0])))||void 0===t?void 0:t.childRefId;n?w(n):S.current=e[0]}})),[w,v,S]);e.useEffect((()=>{const e=(({chartObjects:e,activeTabId:t})=>{var n;return!AR(e,t)&&e.length>0?null===(n=e[0])||void 0===n?void 0:n.childRefId:t})({chartObjects:v.modifiedLayout.objects,activeTabId:v.activeTabId});if(e!==v.activeTabId)w(e);else if(S.current){var t;const e=null===(t=v.modifiedLayout.objects.find((e=>e.id===S.current)))||void 0===t?void 0:t.childRefId;e&&w(e)}S.current=void 0}),[null==l?void 0:l.objects.length,v,S,w]),e.useEffect((()=>{const e=(({chartObjects:e,activeTabId:t,interactions:n})=>{const r=AR(e,t);if(!r||IR(r,n)){const n=e.find((e=>0!==e.condition));return(null==n?void 0:n.childRefId)||t}return t})({chartObjects:v.modifiedLayout.objects,activeTabId:v.activeTabId,interactions:s});e!==v.activeTabId&&w(e)}),[s,null==l?void 0:l.objects,v,w]);const k=0===f.qItems.length&&s.edit;return e.useEffect((()=>{null==i||i.render(q.createElement(kl,{theme:h},k?q.createElement(ER,{Icon:wR,dataHandler:n.dataHandler,modifiedLayout:n.modifiedLayout,translator:n.translator,sharedContainerUtilities:C}):null,!k&&q.createElement(jR,{models:n,renderHelper:E,activeTabId:g,handleChangeTab:w,env:r})))}),[i,n,h,k,E,g,C,w,r]),{renderHelper:E,sharedContainerUtilities:C,activeTabId:g}};var ZR={targets:[]};const JR={showTitles:!0,title:"",subtitle:"",footnote:"",disableNavMenu:!0,showDetails:!1,objects:[],qChildListDef:{qData:{visualization:"/visualization",qExtendsId:"/qExtendsId",title:"/title",childRefId:"/childRefId",showCondition:"/showCondition"}},showTabs:!0,useScrollButton:!0,useDropdown:!1,showIcons:!1,components:[],defaultTabId:"",orientation:"top",fontsUsed:[]};!function(e,t){void 0===t&&(t={});var n=t.insertAt;if("undefined"!=typeof document){var r=document.head||document.getElementsByTagName("head")[0],o=document.createElement("style");o.type="text/css","top"===n&&r.firstChild?r.insertBefore(o,r.firstChild):r.appendChild(o),o.styleSheet?o.styleSheet.cssText=e:o.appendChild(document.createTextNode(e))}}(".init-component {\n height: 100%;\n overflow: hidden;\n}\n");const e_=(e,t)=>{let n=!0;const r=t.objects.reduce(((t,r)=>{const o=r.id;if(0!==r.condition){const i=e.get(o);return i&&(e=>e.supportExport())(i)&&(n=!1,t.objectMap.set(o,i)),t.objects.push(r),t}return t}),{objects:[],objectMap:new Map});return n?{objects:[],objectMap:new Map}:r};return function(t){const r=new ZS({translator:t.translator});return{qae:{properties:JR,data:ZR},ext:qk({env:t,propertyHandlerData:r}),component(){const o=xR(),i=e.useTranslator();e.useMemo((()=>{!function(e){if(e&&e.get&&e.add){const t="LayoutContainer.EmptyList.AddContent";if(e.get(t)!==t)return;Object.keys(n).forEach((t=>{e.add(n[t])}))}}(i)}),[i]);const{dataHandler:a,model:l,accessibility:s,setAccessibility:u,interactions:c,element:d,modifiedLayout:p}=o,{renderHelper:f,sharedContainerUtilities:h,activeTabId:m}=QR({element:d,models:o,env:t});(({propertyHandlerData:t,element:n,sharedContainerUtilities:r,translator:o,containerId:i,dataHandler:a,renderHelper:l})=>{const s=e.useOptions();i&&t.sync({containerId:i,element:n,sharedContainerUtilities:r,translator:o,dataHandler:a,renderHelper:l}),e.useEffect((()=>{t.setMuiTheme(s.direction)}),[s.direction,t]),e.useEffect((()=>()=>{i&&t.destroy(i)}),[i,t,s.direction])})({containerId:(null==l?void 0:l.id)||"",element:d,sharedContainerUtilities:h,translator:i,dataHandler:a,propertyHandlerData:r,renderHelper:f});const[g,b]=e.useState(!0);(({isContainerActive:t,activeTabId:n,modifiedLayout:r,renderHelper:o})=>{const i={modifiedLayout:r,activeTabId:n,renderHelper:o,isContainerActive:t},[a,l]=aR(i);l(i);const s=e.useMemo((()=>()=>{const e=ww(a.modifiedLayout);for(const[t,n]of a.renderHelper.objectMap.entries()){const r=a.isContainerActive&&a.activeTabId===e[t];"setIsActive"in n&&n.setIsActive(r)}}),[a]);e.useEffect((()=>{a.isContainerActive&&s()}),[o.objectMap,s,a]),e.useEffect((()=>{s()}),[t,s])})({isContainerActive:g,activeTabId:m,renderHelper:f,modifiedLayout:p}),iR({element:d,accessibility:s,setAccessibility:u,renderHelper:f,interactions:c,env:t,models:o});const{getViewState:v}=Zk(f,e_);e.useImperativeHandle((()=>({getViewState:v,getChildrenObjects:()=>(e=>e.map((e=>{if(e.canReceive){const t=e=>"libraryitem"===e.type&&("field"===e.item.type||"measure"===e.item.type||"dimension"===e.item.type);return{...e,canReceive:n=>t(n)&&e.canReceive(n)}}return e})))(f.getChildrenObjects()),updateActiveState(e){b(e)}})),[])}}}}));
|
|
108
|
+
e.exports=function(e,t){if(!e||isNaN(+t))return t;var n,r,o,i,a,l,s,u,c,d,p=e.length,f=e.search(/[0-9\-\+#]/),h=f>0?e.substring(0,f):"",m=e.split("").reverse().join(""),g=m.search(/[0-9\-\+#]/),b=p-g,v=e.substring(b,b+1),y=b+("."===v||","===v?1:0),x=g>0?e.substring(y,p):"";if(n=(t="-"===(e=e.substring(f,y)).charAt(0)?-t:+t)<0?t=-t:0,o=(r=e.match(/[^\d\-\+#]/g))&&r[r.length-1]||".",i=r&&r[1]&&r[0]||",",e=e.split(o),t=+(t=t.toFixed(e[1]&&e[1].length))+"",l=e[1]&&e[1].lastIndexOf("0"),(!(u=t.split("."))[1]||u[1]&&u[1].length<=l)&&(t=(+t).toFixed(l+1)),c=e[0].split(i),e[0]=c.join(""),(a=e[0]&&e[0].indexOf("0"))>-1)for(;u[0].length<e[0].length-a;)u[0]="0"+u[0];else 0==+u[0]&&(u[0]="");if((t=t.split("."))[0]=u[0],s=c[1]&&c[c.length-1].length){for(m="",b=(d=t[0]).length%s,p=d.length,y=0;y<p;y++)m+=d.charAt(y),!((y-b+1)%s)&&y<p-s&&(m+=i);t[0]=m}return t[1]=e[1]&&t[1]?o+t[1]:"","0"!==(r=t.join(""))&&""!==r||(n=!1),h+(n?"-":"")+r+x}},QC({exports:{}});var lk="'Source Sans Pro', 'Arial', 'sans-serif'",sk="#333333",uk="#595959",ck="#737373",dk="#cccccc",pk="#e6e6e6";function fk(e){var t={};return[].concat(Pw(e),Pw([["","","color"],["object","","fontFamily"],["object","axis.label.name","color",uk],["object","axis.label.name","fontFamily",lk],["object","axis.label.name","fontSize","12px"],["object","axis.line.major","color",dk],["object","axis.line.minor","color",pk],["object","axis.title","color"],["object","axis.title","fontFamily",lk],["object","axis.title","fontSize","13px"],["object","grid.line.highContrast","color",pk],["object","grid.line.major","color",dk],["object","grid.line.minor","color",pk],["object","label.value","color",uk],["object","label.value","fontFamily",lk],["object","label.value","fontSize","12px"],[!1,"label.value","darkColor",uk],[!1,"label.value","lightColor",pk],["object","outOfRange","color","#999"],["object","legend.title","color",sk],["object","legend.title","fontFamily",lk],["object","legend.title","fontSize","15px"],["object","legend.label","color",uk],["object","legend.label","fontFamily",lk],["object","legend.label","fontSize","13px"],["object","referenceLine.label.name","color",sk],["object","referenceLine.label.name","fontFamily",lk],["object","referenceLine.label.name","fontSize","12px"],["object","referenceLine.outOfBounds","color",pk],["object","referenceLine.outOfBounds","fontFamily",lk],["object","referenceLine.outOfBounds","fontSize","12px"],["object","referenceLine.outOfBounds","backgroundColor",ck,function(e){return"transparent"===e?ck:e}]])).reduce((function(e,n){var r="".concat(n[0],"-").concat(n[1],"-").concat(n[2],"}");return t[r]||(t[r]=!0,e.push(n)),e}),[]).sort((function(e,t){return(e[0].split?e[0].split(".").length:0)-(t[0].split?t[0].split(".").length:0)}))}var hk=function(e){return e};function mk(e){var t=e.theme,n=e.id,r=e.transform,o=e.extend,i=e.matrix,a={},l=r.reduce((function(e,t){var n=Lw(t,2),r=n[0],o=n[1];return e[r]=o,e}),{});return i.forEach((function(e){var r=Lw(e,5),o=r[0],i=r[1],s=r[2],u=r[3],c=r[4],d=void 0===c?function(e){return e}:c,p=function(e){var t=e.theme,n=e.base,r=e.path,o=e.attribute,i=e.defaultValue,a=void 0===i?void 0:i;if(!t||!1===n)return a;var l=t.getStyle(n,r,o);return void 0===l?a:l}({theme:t,base:"object"===o&&n?"".concat("object",".").concat(n):o,path:i,attribute:s,defaultValue:u}),f=(l["".concat(i,".").concat(s)]||hk)(d(p));JC(a,[i,s].filter(Boolean).join("."),f)})),o.forEach((function(e){var t=Lw(e,2),n=t[0],r=t[1];JC(a,n,r)})),a}const gk={qData:{visualization:"/visualization",qExtendsId:"/qExtendsId",containerChildId:"/containerChildId",title:"/title",childRefId:"/childRefId",showCondition:"/showCondition"}};function bk(e){if(!e.objects)return{};const t=Cw(e);return{container_id:e.qInfo.qId,objects:e.qChildList.qItems.map((n=>{var r;return{chart_type:n.qData.visualization,chart_id:n.qInfo.qId,chart_isMaster:!!n.qData.qExtendsId,tab_isVisible:0!==(null===(r=t[n.qData.childRefId])||void 0===r?void 0:r.condition),tab_isActive:n.qData.childRefId===e.cachedTabId}}))}}const vk=({ref:e,theme:t,change:n})=>({component:"inline-wrapper",items:{bgColorDropdown:{ref:`${e}.useColorExpression`,width:9,component:"dropdown",change(t){(XC(t,`${e}.color`)||XC(t,`${e}.colorExpression`))&&(JC(t,`${e}.color`,void 0),JC(t,`${e}.colorExpression`,void 0)),null==n||n(t)},options:[{value:!1,translation:"properties.colorMode.primary"},{value:!0,translation:"properties.colorMode.byExpression"}],defaultValue:!1,placeholder:"properties.colorMode.primary"},bgColorPicker:{component:"color-picker",ref:`${e}.color`,width:3,show:t=>!XC(t,`${e}.useColorExpression`),disableNone:!1,defaultValue:()=>{var n;return{color:null!==(n=null==t?void 0:t.getStyle("object.tabbedContainer",e,"color"))&&void 0!==n?n:"none"}},showAlpha:!0,change:e=>{null==n||n(e)}},bgColorExpression:{component:"input-field-expression",ref:`${e}.colorExpression`,show:t=>XC(t,`${e}.useColorExpression`)}}}),yk=({theme:e})=>({bgColorAllWrapper:vk({ref:"background.unselected"}),selectedTab:{translation:"properties.chartType.selected",component:"text"},bgColorSelectedWrapper:vk({ref:"background.selected"}),colorHoverWrapper:{component:"items",items:{hoverLabel:{translation:"Object.TabbedContainer.Hover",component:"text"},hover:vk({ref:"background.hover",theme:e,change:e=>{JC(e,"indicator.hover.color",XC(e,"background.hover.color")),JC(e,"indicator.hover.useColorExpression",XC(e,"background.hover.useColorExpression"))}})},show:(e,t)=>"left"===t.layout.orientation}}),xk=({paths:e,fontResolver:t,theme:n})=>{const r=`${e.theme}.fontSize`;return{fontWrapperItem:{component:"inline-wrapper",items:{fontSizeItem:{component:"dropdown",ref:`${e.ref}.size`,options:()=>t.getOptions(r),defaultValue:()=>t.getDefaultValue(r),show:e=>{var t;return!1!==(null===(t=e.icon)||void 0===t?void 0:t.show)}},fontColorItem:{component:"color-picker",width:!1,ref:`${e.ref}.color`,defaultValue:()=>({color:n.getStyle("object.tabbedContainer",e.theme,"color")}),show:e=>{var t;return!1!==(null===(t=e.icon)||void 0===t?void 0:t.show)}}}},position:{type:"string",ref:"icon.position",component:"dropdown",options:[{value:"start",translation:"properties.dock.start"},{value:"top",translation:"properties.dock.top"},{value:"end",translation:"properties.dock.end"},{value:"bottom",translation:"properties.dock.bottom"}],defaultValue:(e,{layout:t})=>"left"===t.orientation?"top":"start",show:e=>"tabs"===e.key},hide:{type:"boolean",translation:"properties.show",ref:"icon.show",component:"switch",defaultValue:!0,show:e=>"tab"===e.key}}},Ek=({theme:e})=>({colorWrapper:vk({ref:"indicator.selected",theme:e}),colorHoverWrapper:{component:"items",items:{hoverLabel:{translation:"Object.TabbedContainer.Hover",component:"text"},hover:vk({ref:"indicator.hover",theme:e,change:e=>{JC(e,"background.hover.color",XC(e,"indicator.hover.color")),JC(e,"background.hover.useColorExpression",XC(e,"indicator.hover.useColorExpression"))}})},show:(e,t)=>"left"!==t.layout.orientation}}),Sk=({paths:e,fontResolver:t,theme:n})=>{const r=`${e.theme}.fontFamily`,o=`${e.theme}.fontSize`;return{fontFamilyItem:{component:"dropdown",ref:`${e.ref}.fontFamily`,options:()=>t.getOptions(r),defaultValue:()=>t.getDefaultValue(r),change:(e,t,n)=>{var r;const o=null===(r=e.label)||void 0===r?void 0:r.fontFamily,i=(e=>{const t=[];return e.objects.forEach((e=>{var n,r;const o=null===(n=e.components)||void 0===n?void 0:n.find((e=>"tab"===e.key)),i=null==o||null===(r=o.label)||void 0===r?void 0:r.fontFamily;i&&-1===t.indexOf(i)&&t.push(i)})),t})(n);o&&-1===i.indexOf(o)&&i.push(o),n.fontsUsed=i}},fontWrapperItem:{component:"inline-wrapper",items:{fontSizeItem:{component:"dropdown",ref:`${e.ref}.fontSize`,options:()=>t.getOptions(o),defaultValue:()=>t.getDefaultValue(o)},fontColorItem:{component:"color-picker",width:!1,ref:`${e.ref}.color`,defaultValue:()=>({color:n.getStyle("object.tabbedContainer",e.theme,"color")})}}},alignment:{component:"text-align-buttons",ref:"label.alignment",show:e=>"tabs"===e.key},hide:{type:"boolean",translation:"properties.show",ref:"label.show",component:"switch",defaultValue:!0}}},wk=({ref:e,key:t,fontResolver:n,theme:r})=>({translation:"Object.Container.Props.Label",component:"panel-section",items:{label:{component:"items",ref:e,key:t,items:Sk({paths:{ref:"label",theme:"label.value"},fontResolver:n,theme:r})}}}),Ck=({ref:e,key:t})=>({translation:"Visualizations.Descriptions.Width",component:"panel-section",items:{width:{component:"items",ref:e,key:t,items:{unit:{type:"string",ref:"width.unit",component:"dropdown",options:[{value:"%",translation:"Object.Table.Column.Percentage"},{value:"px",translation:"Object.Table.Column.Pixels"}],defaultValue:"%",change:e=>{var t,n;if(void 0!==(null===(t=e.width)||void 0===t?void 0:t.value)&&"%"===(null===(n=e.width)||void 0===n?void 0:n.unit))for(let t=0;t<e.width.value.length;t++)e.width.value[t]>100?e.width.value[t]=100:e.width.value[t]<5&&(e.width.value[t]=5)}},valuePixel:{translation:"properties.axis.minMax",component:"slider",ref:"width.value",range:!0,step:1,min:0,max:800,show:e=>{var t;return"px"===(null===(t=e.width)||void 0===t?void 0:t.unit)},defaultValue:[0,360]},valuePercentage:{translation:"properties.axis.minMax",component:"slider",type:"array",ref:"width.value",range:!0,step:1,min:5,max:100,show:e=>{var t,n;return!(null!==(t=e.width)&&void 0!==t&&t.unit)||"px"!==(null===(n=e.width)||void 0===n?void 0:n.unit)},defaultValue:[5,20]}}}}}),kk=({theme:e,ref:t,key:n})=>({translation:"Object.TabbedContainer.Indicator",component:"panel-section",items:{indicator:{component:"items",ref:t,key:n,items:Ek({theme:e})}}}),Rk=({ref:e,key:t,fontResolver:n,theme:r})=>({translation:"properties.icon",component:"panel-section",items:{icon:{component:"items",ref:e,key:t,items:xk({paths:{ref:"icon",theme:"icon.value"},fontResolver:n,theme:r})}},show:(e,{layout:t})=>!0===t.showIcons}),_k=({theme:e,ref:t,key:n})=>({translation:"Object.OrgChart.BackgroundColor",component:"panel-section",items:{background:{component:"items",ref:t,key:n,items:"tab"===n?{bgColorWrapper:vk({ref:"background"})}:yk({theme:e})}}}),Tk=({fontResolver:e,theme:t})=>{const n="components",r="tab";return{component:"styling-panel",chartTitle:"Object.Container",tabTitle:"scripteditor.dataconnectors.delimiter.tab",translation:"LayerStyleEditor.component.styling",subtitle:"LayerStyleEditor.component.styling",ref:n,items:{label:wk({ref:n,key:r,fontResolver:e,theme:t}),width:{...Ck({ref:n,key:r}),show:(e,{layout:t})=>"left"!==t.orientation},icon:Rk({ref:n,key:r,fontResolver:e,theme:t}),background:_k({ref:n,key:r,theme:t})}}},Lk={ref:"label",type:"string",translation:"Object.Container.Props.Label",defaultValue:"",expression:"optional"},Pk={ref:"condition",translation:"Object.Container.Props.ShowCondition",component:"expression",defaultValue:{qValueExpression:{qExpr:""}},expressionType:"ValueExpression",expression:"always"},Ak=e=>({component:"button",translation:"Object.Container.Props.EditProperties",disabled:(e,t)=>{var n,r,o;const i=t.getLayout(),a=null===(n=Ew(i,e.childRefId))||void 0===n?void 0:n.qMeta;return!(null!=a&&null!==(r=a.privileges)&&void 0!==r&&r.includes("update")&&null!==(o=i.permissions)&&void 0!==o&&o.update)},action(t,n,{app:r}){const{sense:o}=e.env.anything,i=n.getEngineId(t.childRefId);i&&(o.propertyPanel.show({id:i,app:r,parent:"current",headerLabel:t.label}),n.setSelectedChild([i]))}}),Ik=e=>{const{sense:t}=e.env.anything;return{label:Lk,condition:Pk,styling:Tk({fontResolver:e.fontResolver,theme:null==t?void 0:t.theme}),editProperties:Ak(e)}},Ok={translation:"Object.Container.Props.Chart",component:"text",show:e=>e.objects?e.objects.length<=1:e.children.length<=1},Mk={translation:"Common.Charts",component:"text",show:e=>e.objects?e.objects.length>1:e.children.length>1},Nk=e=>({type:"array",ref:"objects",itemTitleRef:e=>e.label,allowAdd:!0,customAdd:!0,allowMove:!0,allowRemove:!0,customRemove:!0,addTranslation:"Object.Container.Props.Add",cId:"childRefId",grouped:!0,add(e,t,n){const r=document.querySelector(".pp-toplist-add-button");null!==r&&n.openAddChildPopover(r)},remove(e,t,n){n.deleteChild(e.childRefId).catch((()=>{}))},items:Ik(e)}),zk=e=>({type:"items",translation:"Object.Container.Props.Content",items:{chartLabel:Ok,chartsLabel:Mk,chartList:Nk(e)}}),jk={type:"boolean",translation:"Object.Container.Props.ShowTabs",ref:"showTabs",defaultValue:!0,component:"switch",options:[{value:!0,translation:"properties.on"},{value:!1,translation:"properties.off"}]},$k={type:"boolean",translation:"Object.Container.Props.UseDropdown",label:"Menu",ref:"useDropdown",component:"switch",options:[{value:!0,translation:"Common.Auto"},{value:!1,translation:"properties.off"}],defaultValue:!1,show:e=>e.showTabs},Dk={type:"boolean",translation:"Object.Container.Props.UseScrollButtons",ref:"useScrollButton",component:"switch",options:[{value:!0,translation:"Common.Auto"},{value:!1,translation:"properties.off"}],defaultValue:!0,show:e=>e.showTabs},Bk={type:"boolean",translation:"Object.Container.Props.ShowIcons",ref:"showIcons",component:"switch",options:[{value:!0,translation:"properties.on"},{value:!1,translation:"properties.off"}],defaultValue:!1,show:e=>e.showTabs},Fk={type:"string",translation:"Object.Container.Props.DefaultTab",ref:"defaultTabId",component:"dropdown",defaultValue:void 0,options(e,t){const n=t.getLayout();return n?n.objects.map((e=>({translation:e.label,value:e.childRefId}))):[]},change(e,t){const n=kw(t.getLayout(),e.defaultTabId);n&&t.setSelectedChild([n])},show:e=>e.objects.length>0},Hk={type:"string",translation:"properties.orientation",ref:"orientation",component:"dropdown",options:[{value:"top",translation:"properties.orientation.horizontal"},{value:"left",translation:"properties.orientation.vertical"}],defaultValue:"top",show:e=>e.showTabs},Uk=({fontResolver:e,theme:t})=>{const n="components",r="tabs";return{component:"styling-panel",chartTitle:"Object.TabContainer",tabTitle:"Object.Container.Props.ShowTabs",translation:"LayerStyleEditor.component.styling",subtitle:"LayerStyleEditor.component.styling",useGeneral:!0,useBackground:!0,items:{label:wk({ref:n,key:r,fontResolver:e,theme:t}),width:Ck({ref:n,key:r}),indicator:kk({ref:n,key:r,theme:t}),icon:Rk({ref:n,key:r,fontResolver:e,theme:t}),background:_k({ref:n,key:r,theme:t})}}},Vk={items:{details:{show:e=>!0===e.showDetails}}},Gk=e=>{const{sense:t}=e.env.anything;return{type:"items",translation:"properties.presentation",grouped:!0,items:{stylingPanel:Uk({fontResolver:e.fontResolver,theme:null==t?void 0:t.theme}),container:{type:"items",items:{showTabs:jk,useDropdown:$k,useScrollButton:Dk,showIcons:Bk,orientation:Hk,defaultTabId:Fk}}}}},Wk=e=>({uses:"settings",items:{general:Vk,presentation:Gk(e)}}),Yk=e=>({type:"items",component:"accordion",items:{content:zk(e),settings:Wk(e)}}),qk=e=>{const{sense:t}=e.env.anything,n=function(e){var t=e.theme,n=e.translator,r=e.config,o=void 0===r?{}:r,i=e.flags,a=function(e){var t=e.config,n=void 0===t?{}:t,r=n.id,o=n.paths;return{id:void 0===r?"object":"".concat("object",".").concat(r),paths:Array.isArray(o)?o:[]}}({config:o}),l=a.id,s=a.paths,u={};s.forEach((function(e){for(var r=e.split("."),o=u,a=0;a<r.length;a++){var s=r[a];a===r.length-1?o[s]=Qw({theme:t,translator:n,id:l,path:e,flags:i}):void 0===o[s]&&(o[s]={}),o=o[s]}}));var c=function(e){for(var t=e.split("."),n=u,r=0;r<t.length;r++){var o=t[r];if(void 0===n[o])throw new Error("font-resolver: Path '".concat(e,"' could not be resolved."));n=n[o]}return n};return u.getDefaultValue=function(e){return c(e).getDefaultValue()},u.getOptions=function(e){return c(e).getOptions()},u}({theme:null==t?void 0:t.theme,translator:e.env.translator,flags:e.env.flags,config:{id:"tabbedContainer",paths:["label.value","icon.value"]}}),r=function(e){return{async getDropOptions(e,t,n){const{item:r}=t,o=e.getCreatePropertyHandler();if(o.setModel(e.model),"state"===t.item.type){var i;const r=await e.model.getProperties();return o.setProperties(r),o.setLayout(null===(i=e.model)||void 0===i?void 0:i.layout),this.getDropStateOptions(t,o,e.model,n)}if("visualization"===r.type)return t.menu.addItem({translation:["Object.Container.DropItem",r.name],tid:"addvisualization",select(){var e;null===(e=o.addChild({initProps:{qExtendsId:r.id,qInfo:{qType:"undefined"}}}))||void 0===e||e.then((e=>{e&&o.setSelectedChild([e.id])}))}}),void n();const a=await t.item.getDropOption(t.item);"newObject"===(null==a?void 0:a.id)&&t.menu.addItem({translation:["Object.Container.DropItem",r.name],tid:"createvisualization",select(){var e,t;null===(e=o.addChild({initProps:{...a.args.init,visualization:a.args.template},children:null===(t=a.args.children)||void 0===t?void 0:t.map((e=>({qProperty:e})))}))||void 0===e||e.then((e=>{e&&o.setSelectedChild([e.id])}))}}),n()},async addChild(t,n){const{model:r}=this,o=new Rw({app:r.app,data:e.propertyHandlerData});return o.setModel(r),{childModel:await o.addChild({initProps:t,children:n}),handler:o}},canReceive(e){if(this.model.layout.qExtendsId)return!1;if("libraryitem"===e.type){const{item:t}=e;if("template"===t.type&&JS.includes(t.template))return!1;if("visualization"===t.type&&JS.includes(t.visualization))return!1}return"gridcell"!==e.type||!JS.includes(e.cell.model.layout.visualization)}}}(e);return{definition:Yk({...e,fontResolver:n}),support:{snapshot:!1,export:!0,sharing:!1,exportData:!1,viewData:!1},hidePatchPanel:()=>!0,getCreatePropertyHandler:t=>new Rw({app:t,data:e.propertyHandlerData}),...r,addChild:async function(e,t){const{childModel:n,handler:o}=await r.addChild.apply(this,[e,t]);n&&o.setSelectedChild([n.id])},migrate:{properties:(e,t)=>((async(e,t)=>{if(!e.objects){const{objects:n,defaultTabId:r,components:o,orientation:i,showDetails:a}=await t.getEffectiveProperties(),l=await t.getFullPropertyTree();if(!l.qProperty.objects&&n){const s=[];l.qChildren.forEach((e=>{const n=e.qProperty;if(n.qInfo.qId){const r=async r=>{const o=await t.getChild(r),i=await o.getEffectiveProperties();return{...e,qProperty:{...n,childRefId:i.childRefId}}};s.push(r(n.qInfo.qId))}}));const u=await Promise.all(s),c={...e,objects:n,defaultTabId:null!=r?r:"",components:o,qChildListDef:gk,orientation:i,showDetails:a};t.clearSoftPatches(),await t.setFullPropertyTree({...l,qProperty:c,qChildren:u})}}})(e,t),e)},exportProperties:null,importProperties:(e,t)=>{const n={...e.properties};return"masterobject"!==e.properties.qInfo.qType&&(n.qInfo.qType=t.qInfo.qType),n.visualization=t.visualization,{qProperty:n,qChildren:e.qChildren}},extendMetrics:bk}},Kk=e=>e.reduce(((e,{id:t,data:n})=>(n&&(e[t]=n),e)),{}),Xk=async e=>{const t=[];for(const[n,r]of e){const e={id:n,data:void 0},o=r;t.push(o.getViewState().then((e=>({id:n,data:e}))).catch((()=>e)))}const n=await Promise.all(t);return{viewStates:Kk(n)}},Qk=async e=>{const t=[];for(const[n,r]of e){const e={id:n,data:void 0},o=r;t.push(o.getSnapshotLayout().then((e=>({id:n,data:e}))).catch((()=>e)))}const n=await Promise.all(t);return Kk(n)},Zk=(t,n)=>(e.onTakeSnapshot((async e=>{const r=e,{snapshotData:o}=r;if(o){const e=Sw(r),i=n(t.objectMap,e),[a,l]=await Promise.all([Qk(i.objectMap),Xk(i.objectMap)]);o.objectsData={layouts:a},r.objects=i.objects,o.viewState=l}return e})),{getViewState:()=>Xk(t.objectMap)});let Jk=function(e){return e.COPY="ctrl+c",e.CUT="ctrl+x",e.PASTE="ctrl+v",e.OPEN_CONTEXT_MENU="shift+F10",e.ESCAPE="Escape",e.SPACE=" ",e.ENTER="Enter",e.BACKSPACE="Backspace",e.DELETE="Delete",e.SHIFT="Shift",e}({}),eR=function(e){return e.KEY_DOWN="keydown",e.KEY_UP="keyup",e.FOCUS_OUT="focusout",e}({});var tR,nR;!function(e){e.TAB_MENU="tab-menu",e.TAB_MENU_ITEM="tab-menu-item",e.ACTIVE_TAB="active-tab-button",e.TAB_WRAPPER="tab-wrapper",e.TAB="tab-button",e.TAB_EXTRA_PRIO="MuiTab-root",e.TAB_LABEL="tab-label",e.TABS_ICON="tab-icon",e.ACTIVE_TAB_PANEL="active-tab-panel",e.TAB_INDICATOR="MuiTabs-indicator"}(tR||(tR={})),function(e){e.TABS="& .tab-button.MuiTab-root, .tab-button.active-tab-button",e.TABS_HOVER="& .tab-button.MuiTab-root:hover",e.TABS_LABEL="& .tab-label",e.TABS_ICON="& .tab-icon svg",e.TABS_WRAPPER="& .tab-wrapper",e.TAB_INDICATOR="& .MuiTabs-indicator"}(nR||(nR={}));const rR=e=>{var t;return null===(t=e.getElementsByClassName(tR.ACTIVE_TAB))||void 0===t?void 0:t[0]},oR=e=>{var t;return null===(t=e.getElementsByClassName(tR.ACTIVE_TAB_PANEL))||void 0===t?void 0:t[0]},iR=({element:t,setAccessibility:n,accessibility:r,renderHelper:o,interactions:i,env:a,models:l})=>{const{modifiedLayout:{showTabs:s,objects:u,orientation:c},translator:d}=l;e.useEffect((()=>{(()=>{const e="top"===c?d.get("TabContainer.Navigation.Horizontal"):d.get("TabContainer.Navigation.Vertical"),n=((e,t)=>e.map((e=>e.label||t.get("TabContainer.Object.Untitled"))).join(", "))(u,d);t.setAttribute("aria-label",d.get("TabContainer.Object.Description",[n,s?e:""]))})()}),[t,s,u,d,c]);const p=a.flags.isEnabled("VIZ-7_NEW_SHEET"),f=e.useKeyboard(),h=e.useMemo((()=>()=>{var e;(n(!1),f.enabled)&&(null===(e=f.blur)||void 0===e||e.call(f,!0))}),[f,n]),m=e.useMemo((()=>e=>{switch(e.shiftKey?`shift+${e.key}`:e.key){case Jk.ESCAPE:var n;e.stopPropagation(),null===(n=f.blur)||void 0===n||n.call(f,!0);break;case Jk.ENTER:case Jk.SPACE:{e.stopPropagation();const n=e.target;var r;if(null!=n&&n.classList.contains(tR.ACTIVE_TAB))null===(r=oR(t))||void 0===r||r.focus();break}}}),[t,f]),g=e.useMemo((()=>e=>{const n=e.shiftKey?`shift+${e.key}`:e.key,r=o.objectMap.values().next().value,i=o.objectApis.values().next().value;switch(n){case Jk.ESCAPE:{const n=rR(t);p?(({event:e,objectApi:t,activeTab:n})=>{var r;e.stopPropagation(),(null==t?void 0:t.viewDataToggled)&&(null===(r=t.support)||void 0===r?void 0:r.call(t,"viewData"))?t.toggleDataView():null==n||n.focus()})({event:e,objectApi:i,activeTab:n}):(({event:e,objectApi:t,activeTab:n})=>{var r,o;e.stopPropagation(),(null==t?void 0:t.viewDataToggled)&&(null===(r=t.supportViewData)||void 0===r?void 0:r.call(t))?null===(o=t.toggleDataView)||void 0===o||o.call(t):null==n||n.focus()})({event:e,objectApi:r,activeTab:n});break}case Jk.ENTER:case Jk.SPACE:{const n=oR(t);p?(({event:e,objectApi:t,activeTab:n})=>{var r,o,i;if(!t)return;e.stopPropagation(),null===(r=t.setOnBlurHandler)||void 0===r||r.call(t,(()=>{var e;null==n||n.focus(),null===(e=t.setOnBlurHandler)||void 0===e||e.call(t,void 0)})),!t.viewDataToggled&&(null===(o=t.support)||void 0===o?void 0:o.call(t,"viewData"))?t.toggleDataView():null===(i=t.toggleFocus)||void 0===i||i.call(t,!0)})({event:e,objectApi:i,activeTab:n}):(({event:e,objectApi:t,activeTab:n})=>{var r,o,i,a;if(!t)return;e.stopPropagation(),null===(r=t.setOnBlurHandler)||void 0===r||r.call(t,(()=>{var e;null==n||n.focus(),null===(e=t.setOnBlurHandler)||void 0===e||e.call(t,void 0)})),!t.viewDataToggled&&(null===(o=t.supportViewData)||void 0===o?void 0:o.call(t))?null===(a=t.toggleDataView)||void 0===a||a.call(t):t.viewDataToggled&&"function"==typeof(null===(i=t.dataViewObject)||void 0===i?void 0:i.focus)?t.dataViewObject.focus():"function"==typeof t.focus&&t.focus()})({event:e,objectApi:r,activeTab:n});break}case Jk.OPEN_CONTEXT_MENU:e.stopPropagation(),null!=r&&r.viewDataToggled||t!==document.activeElement&&(h(),t.focus())}}),[t,h,p,o]),b=e.useMemo((()=>e=>{const t=e.target;null!=t&&t.classList.contains(tR.ACTIVE_TAB_PANEL)?g(e):m(e)}),[m,g]);e.useEffect((()=>(r&&t.addEventListener(eR.KEY_DOWN,b),()=>{t.removeEventListener(eR.KEY_DOWN,b)})),[t,r,b]);const[v,y]=e.useState(!1);e.useEffect((()=>{v&&(y(!1),window.setTimeout((()=>{var e,n;return null===(e=null!==(n=(e=>{var t;return null===(t=e.getElementsByClassName(tR.TAB_MENU))||void 0===t?void 0:t[0]})(t))&&void 0!==n?n:rR(t))||void 0===e?void 0:e.focus()}),0))}),[t,v]),e.useEffect((()=>{n(!1)}),[i.edit,n]),e.useEffect((()=>{const e=e=>{const n=e.relatedTarget;null!=t&&t.contains(n)||null!=n&&n.classList.contains(tR.TAB_MENU_ITEM)||null==h||h()};return f.enabled&&f.active&&!i.edit&&(n(!0),y(!0),t.addEventListener(eR.FOCUS_OUT,e)),()=>{t.removeEventListener(eR.FOCUS_OUT,e)}}),[f])},aR=t=>{const[n]=e.useState(t);return[n,function(e){Object.assign(n,e)}]},lR={getChar(e){let t,n=e;return n>9?(t=65+n-10,t>90&&(t+=6)):n=`${n}`.charCodeAt(0),!t||[48,111,79,105,73,108].indexOf(t)>-1?this.getChar(n+1):String.fromCharCode(t)},base62(e){const t=this.getChar(e%62),n=Math.floor(e/62);return n>0?this.base62(n)+t:t},id(){return this.base62(Math.round(99e11*Math.random()+1e11)).replace(/\W/g,"")}};const sR={qInfo:{qId:"MasterObjectList",qType:"MasterObjectList"},qAppObjectListDef:{qType:"masterobject",qData:{name:"/qMetaDef/title",labelExpression:"/labelExpression",visualization:"/visualization",tags:"/qMetaDef/tags"}}};class uR{constructor(e){r(this,"sessionObject",void 0),r(this,"getOrCreateSessionObject",(async e=>{const t=sR.qInfo.qId;this.sessionObject=await e.getObject(t).catch((()=>e.createSessionObject(sR)))})),r(this,"getMasterVisualizations",(async()=>{try{if(!this.sessionObject)return[];const e=await this.sessionObject.getLayout();return("qAppObjectList"in e?e.qAppObjectList.qItems:e).map((e=>({...e.qData,qExtendsId:e.qInfo.qId}))).filter((e=>!JS.includes(e.visualization)))}catch(e){return[]}})),this.getOrCreateSessionObject(e).catch((()=>{}))}}let cR=function(e){return e[e.TOP=0]="TOP",e[e.BOTTOM=1]="BOTTOM",e[e.UP=2]="UP",e[e.DOWN=3]="DOWN",e}({});class dR{constructor({embed:e,model:t,app:n,translator:o,mutex:i}){r(this,"model",void 0),r(this,"embed",void 0),r(this,"app",void 0),r(this,"undoRedoModel",void 0),r(this,"chartList",void 0),r(this,"masterVizList",void 0),r(this,"mutex",void 0),r(this,"rememberAsGroup",(async e=>{let t;this.undoRedoModel&&(t=await this.undoRedoModel.startGroup());const n=await e();return t&&this.undoRedoModel&&await this.undoRedoModel.endGroup(t),n})),r(this,"generateProperties",(async(e,t)=>await this.embed.generateProperties({type:e,properties:t}))),r(this,"addVizAsChild",(async({type:e,initProps:t,objectInitProps:n,children:r})=>{try{const o=await this.generateProperties(e,t);let i=(null==n?void 0:n.label)||(null==t?void 0:t.title);if(!i){const n=this.getChart(null==t?void 0:t.visualization),r=null==n?void 0:n.libraryInfo;i=(null==r?void 0:r.translation)||(null==r?void 0:r.name)||e}const a={...n,label:i};return await this.addChild(o,r,a)}catch(e){return}})),r(this,"addMasterObjectAsChild",(async({initProps:e,objectInitProps:t,children:n})=>{try{if(!e||!e.qExtendsId||!this.app)return;const r=await this.app.getObject(e.qExtendsId),o=await r.getProperties(),i=(null==t?void 0:t.label)||o.title||o.qMetaDef.title,a={...e,qInfo:{qType:"childObject"}},l={...t,label:i};return await this.addChild(a,n,l)}catch(e){return}})),r(this,"deleteChildren",(async e=>{const{model:t}=this;if(0===e.length||!t)return!1;try{await this.mutex.lock();const n=await t.getFullPropertyTree(),{qChildren:r,qProperty:o}=n,i=new Set(e);return n.qChildren=r.filter((({qProperty:e})=>{const t=e.childRefId;return!t||!i.has(t)})),n.qProperty.objects=o.objects.filter((e=>!i.has(e.childRefId))),await t.setFullPropertyTree(n),!0}catch(e){return!1}finally{this.mutex.unlock()}})),r(this,"moveChild",(async(e,t)=>{if(this.model)try{await this.mutex.lock();const n=await this.model.getProperties(),{objects:r}=n,o=r.findIndex((e=>e.childRefId===t));let i=!1;switch(e){case cR.TOP:{if(0===o)break;const e=r.splice(o,1)[0];r.unshift(e),i=!0;break}case cR.BOTTOM:{if(o===r.length-1)break;const e=r.splice(o,1)[0];r.push(e),i=!0;break}case cR.UP:{if(0===o)break;const e=r.splice(o,1)[0];r.splice(o-1,0,e),i=!0;break}case cR.DOWN:{if(o===r.length-1)break;const e=r.splice(o,1)[0];r.splice(o+1,0,e),i=!0;break}}i&&await this.model.setProperties(n)}finally{this.mutex.unlock()}})),r(this,"getCharts",(()=>{var e;return(null===(e=this.chartList)||void 0===e?void 0:e.getCharts())||{}})),r(this,"getMasterVizList",(()=>{var e;return(null===(e=this.masterVizList)||void 0===e?void 0:e.getMasterVisualizations())||Promise.resolve([])})),r(this,"getChart",(e=>{var t;return null===(t=this.chartList)||void 0===t?void 0:t.getChart(e)})),r(this,"getChartLabelById",((e,t)=>{var n,r;const o=null==e||null===(n=e.qChildList)||void 0===n?void 0:n.qItems.find((e=>e.qInfo.qId===t));if(!o)return"";const{visualization:i,title:a}=o.qData;if(a)return a;const l=this.getChart(i);return(null==l||null===(r=l.libraryInfo)||void 0===r?void 0:r.translation)||i})),this.model=t,this.embed=e,this.app=n;const a=n;a&&a.getUndoInfoObject&&a.getUndoInfoObject().then((e=>{this.undoRedoModel=e})).catch((()=>{})),n&&(this.masterVizList=new uR(n)),e&&o&&(this.chartList=new ew(e,o)),this.mutex=i}async addChild(e,t,n){if(this.model&&!JS.includes(e.visualization))try{await this.mutex.lock();const{model:r}=this,o=async()=>{e.childRefId=lR.id();const o=await r.createChild(e);if(o){const t=await r.getProperties();t.objects.unshift({childRefId:e.childRefId,...n,condition:{qValueExpression:{qExpr:""}}}),await r.setProperties(t)}return t&&o&&await Promise.all(t.map((({qProperty:e})=>o.createChild(e)))),o};return await this.rememberAsGroup(o)}catch(e){return}finally{this.mutex.unlock()}}}class pR{constructor(e){r(this,"locked",!1),r(this,"tasks",[]),r(this,"id",void 0),r(this,"lock",(async()=>this.locked?new Promise((e=>{this.tasks.push(e)})):(this.locked=!0,!0))),r(this,"unlock",(()=>{if(this.tasks.length>0){const e=this.tasks.shift();null==e||e(!0)}else this.locked=!1})),this.id=e}}const fR={aliceblue:{r:240,g:248,b:255},antiquewhite:{r:250,g:235,b:215},aqua:{r:0,g:255,b:255},aquamarine:{r:127,g:255,b:212},azure:{r:240,g:255,b:255},beige:{r:245,g:245,b:220},bisque:{r:255,g:228,b:196},black:{r:0,g:0,b:0},blanchedalmond:{r:255,g:235,b:205},blue:{r:0,g:0,b:255},blueviolet:{r:138,g:43,b:226},brown:{r:165,g:42,b:42},burlywood:{r:222,g:184,b:135},cadetblue:{r:95,g:158,b:160},chartreuse:{r:127,g:255,b:0},chocolate:{r:210,g:105,b:30},coral:{r:255,g:127,b:80},cornflowerblue:{r:100,g:149,b:237},cornsilk:{r:255,g:248,b:220},crimson:{r:220,g:20,b:60},cyan:{r:0,g:255,b:255},darkblue:{r:0,g:0,b:139},darkcyan:{r:0,g:139,b:139},darkgoldenrod:{r:184,g:134,b:11},darkgray:{r:169,g:169,b:169},darkgreen:{r:0,g:100,b:0},darkgrey:{r:169,g:169,b:169},darkkhaki:{r:189,g:183,b:107},darkmagenta:{r:139,g:0,b:139},darkolivegreen:{r:85,g:107,b:47},darkorange:{r:255,g:140,b:0},darkorchid:{r:153,g:50,b:204},darkred:{r:139,g:0,b:0},darksalmon:{r:233,g:150,b:122},darkseagreen:{r:143,g:188,b:143},darkslateblue:{r:72,g:61,b:139},darkslategray:{r:47,g:79,b:79},darkslategrey:{r:47,g:79,b:79},darkturquoise:{r:0,g:206,b:209},darkviolet:{r:148,g:0,b:211},deeppink:{r:255,g:20,b:147},deepskyblue:{r:0,g:191,b:255},dimgray:{r:105,g:105,b:105},dimgrey:{r:105,g:105,b:105},dodgerblue:{r:30,g:144,b:255},firebrick:{r:178,g:34,b:34},floralwhite:{r:255,g:250,b:240},forestgreen:{r:34,g:139,b:34},fuchsia:{r:255,g:0,b:255},gainsboro:{r:220,g:220,b:220},ghostwhite:{r:248,g:248,b:255},gold:{r:255,g:215,b:0},goldenrod:{r:218,g:165,b:32},gray:{r:128,g:128,b:128},green:{r:0,g:128,b:0},greenyellow:{r:173,g:255,b:47},grey:{r:128,g:128,b:128},honeydew:{r:240,g:255,b:240},hotpink:{r:255,g:105,b:180},indianred:{r:205,g:92,b:92},indigo:{r:75,g:0,b:130},ivory:{r:255,g:255,b:240},khaki:{r:240,g:230,b:140},lavender:{r:230,g:230,b:250},lavenderblush:{r:255,g:240,b:245},lawngreen:{r:124,g:252,b:0},lemonchiffon:{r:255,g:250,b:205},lightblue:{r:173,g:216,b:230},lightcoral:{r:240,g:128,b:128},lightcyan:{r:224,g:255,b:255},lightgoldenrodyellow:{r:250,g:250,b:210},lightgray:{r:211,g:211,b:211},lightgreen:{r:144,g:238,b:144},lightgrey:{r:211,g:211,b:211},lightpink:{r:255,g:182,b:193},lightsalmon:{r:255,g:160,b:122},lightseagreen:{r:32,g:178,b:170},lightskyblue:{r:135,g:206,b:250},lightslategray:{r:119,g:136,b:153},lightslategrey:{r:119,g:136,b:153},lightsteelblue:{r:176,g:196,b:222},lightyellow:{r:255,g:255,b:224},lime:{r:0,g:255,b:0},limegreen:{r:50,g:205,b:50},linen:{r:250,g:240,b:230},magenta:{r:255,g:0,b:255},maroon:{r:128,g:0,b:0},mediumaquamarine:{r:102,g:205,b:170},mediumblue:{r:0,g:0,b:205},mediumorchid:{r:186,g:85,b:211},mediumpurple:{r:147,g:112,b:219},mediumseagreen:{r:60,g:179,b:113},mediumslateblue:{r:123,g:104,b:238},mediumspringgreen:{r:0,g:250,b:154},mediumturquoise:{r:72,g:209,b:204},mediumvioletred:{r:199,g:21,b:133},midnightblue:{r:25,g:25,b:112},mintcream:{r:245,g:255,b:250},mistyrose:{r:255,g:228,b:225},moccasin:{r:255,g:228,b:181},navajowhite:{r:255,g:222,b:173},navy:{r:0,g:0,b:128},oldlace:{r:253,g:245,b:230},olive:{r:128,g:128,b:0},olivedrab:{r:107,g:142,b:35},orange:{r:255,g:165,b:0},orangered:{r:255,g:69,b:0},orchid:{r:218,g:112,b:214},palegoldenrod:{r:238,g:232,b:170},palegreen:{r:152,g:251,b:152},paleturquoise:{r:175,g:238,b:238},palevioletred:{r:219,g:112,b:147},papayawhip:{r:255,g:239,b:213},peachpuff:{r:255,g:218,b:185},peru:{r:205,g:133,b:63},pink:{r:255,g:192,b:203},plum:{r:221,g:160,b:221},powderblue:{r:176,g:224,b:230},purple:{r:128,g:0,b:128},rebeccapurple:{r:102,g:51,b:153},red:{r:255,g:0,b:0},rosybrown:{r:188,g:143,b:143},royalblue:{r:65,g:105,b:225},saddlebrown:{r:139,g:69,b:19},salmon:{r:250,g:128,b:114},sandybrown:{r:244,g:164,b:96},seagreen:{r:46,g:139,b:87},seashell:{r:255,g:245,b:238},sienna:{r:160,g:82,b:45},silver:{r:192,g:192,b:192},skyblue:{r:135,g:206,b:235},slateblue:{r:106,g:90,b:205},slategray:{r:112,g:128,b:144},slategrey:{r:112,g:128,b:144},snow:{r:255,g:250,b:250},springgreen:{r:0,g:255,b:127},steelblue:{r:70,g:130,b:180},tan:{r:210,g:180,b:140},teal:{r:0,g:128,b:128},thistle:{r:216,g:191,b:216},tomato:{r:255,g:99,b:71},transparent:{r:255,g:255,b:255,a:0},turquoise:{r:64,g:224,b:208},violet:{r:238,g:130,b:238},wheat:{r:245,g:222,b:179},white:{r:255,g:255,b:255},whitesmoke:{r:245,g:245,b:245},yellow:{r:255,g:255,b:0},yellowgreen:{r:154,g:205,b:50}},hR={index:-1,color:"none",alpha:1},mR=e=>{let t=parseFloat(e[1]),n=parseFloat(e[3]),r=parseFloat(e[5]);return t%=360,n/=100,r/=100,t=Math.max(0,Math.min(t,360)),n=Math.max(0,Math.min(n,1)),r=Math.max(0,Math.min(r,1)),{h:t,s:n,l:r,v:r}},gR=(e,t,n,r,o=1)=>{let i,a,l,s=[];switch(n=Math.floor(n)){case 0:s=[e,t,0];break;case 1:s=[t,e,0];break;case 2:s=[0,e,t];break;case 3:s=[0,t,e];break;case 4:s=[t,0,e];break;case 5:s=[e,0,t];break;default:s=[0,0,0]}return i=s[0]+r,a=s[1]+r,l=s[2]+r,i=Math.round(255*i),a=Math.round(255*a),l=Math.round(255*l),`rgba(${i},${a},${l},${o})`},bR=e=>{const{h:t,s:n,l:r}=mR(e),o=e.length>7?parseFloat(e[7]):1,i=r<=.5?2*r*n:(2-2*r)*n,a=t/60,l=i*(1-Math.abs(a%2-1));return gR(i,l,a,r-.5*i,o)},vR={resolveExpression:({colorExpression:e=""})=>{let t=/^rgb\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*\)$/i.exec(e);if(t)return`rgb(${t[1]},${t[2]},${t[3]})`;if(t=/^rgba\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d(\.\d+)?)\s*\)$/i.exec(e),t)return`rgba(${t[1]},${t[2]},${t[3]},${t[4]})`;if(t=/^argb\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*\)$/i.exec(e),t){const e=Math.round(Number(t[1])/255*100)/100;return`rgba(${t[2]},${t[3]},${t[4]},${e})`}if(t=/^hsl\(\s*(\d+(\.\d+)?)\s*,\s*(\d+(\.\d+)?%?)\s*,\s*(\d+(\.\d+)?%?)\s*\)$/i.exec(e),t)return bR(t);if(t=/^hsla\(\s*(\d+(\.\d+)?)\s*,\s*(\d+(\.\d+)?%?)\s*,\s*(\d+(\.\d+)?%?)\s*,\s*(\d(\.\d+)?)\s*\)$/i.exec(e),t)return bR(t);if(t=/^hsv\(\s*(\d+(\.\d+)?)\s*,\s*(\d+(\.\d+)?%?)\s*,\s*(\d+(\.\d+)?%?)\s*\)$/i.exec(e),t)return(e=>{const{h:t,s:n,v:r}=mR(e),o=r*n,i=t/60,a=o*(1-Math.abs(i%2-1));return gR(o,a,i,r-o)})(t);if(t=/^#([A-Fa-f0-9]{2})([A-Fa-f0-9]{2})([A-Fa-f0-9]{2})$/i.exec(e),t)return e;if(t=/^#([A-Fa-f0-9])([A-Fa-f0-9])([A-Fa-f0-9])$/i.exec(e),t)return e;const n=e&&fR[e.toLowerCase()];if(n){const e=void 0!==n.a?n.a:1;return`rgba(${n.r},${n.g},${n.b},${e})`}return"none"},getColor({style:e,defaultColor:t,theme:n}){const r=(null==e?void 0:e.color)||hR;let o;return o=null!=e&&e.useColorExpression?vR.resolveExpression(e):"string"==typeof r?r:(null==n?void 0:n.getColorPickerColor(r))||"",o&&"none"!==o?o:t}},yR=()=>q.createElement(fw,{viewBox:"0 0 16 16"},q.createElement("path",{d:"M15 6V5H5V2H1.5a.5.5 0 0 0-.5.5V6H0V2a1 1 0 0 1 1-1h14a1 1 0 0 1 1 1v4h-1Zm-5-4H6v2h4V2Zm4.5 0H11v2h4V2.5a.5.5 0 0 0-.5-.5Zm1.5 9h-1V8h1v3Zm0 3a1 1 0 0 1-1 1h-1v-1h.6a.4.4 0 0 0 .4-.4V13h1v1Zm-7 1v-1h3v1H9Zm-5 0v-1h3v1H4Zm-3 0a1 1 0 0 1-1-1v-1h1v.6c0 .22.18.4.4.4H2v1H1ZM0 8h1v3H0V8Zm4-.5a.5.5 0 0 1 .5-.5h7a.5.5 0 0 1 .5.5v4a.5.5 0 0 1-.5.5h-7a.5.5 0 0 1-.5-.5v-4ZM5 11h6V8H5v3Z"})),xR=({libraryInfo:e,style:t,id:n})=>q.createElement("div",{style:t,"data-testid":"tab-chart-icon",id:n,className:tR.TABS_ICON},q.createElement(e.IconDefinition,null)),ER=({style:e,id:t})=>q.createElement("div",{style:e,"data-testid":"tab-hidden-icon",id:t},q.createElement(hw,{viewBox:"0 0 16 16"},q.createElement("path",{d:"m13.441.795.764.646-1.839 2.174c.568.434 1.076.914 1.522 1.385a13.79 13.79 0 0 1 2.109 3 13.798 13.798 0 0 1-2.108 3c-1.382 1.457-3.345 3-5.89 3-1.34 0-2.52-.428-3.536-1.045l-1.904 2.25-.764-.646L13.441.795ZM11.72 4.379l-1.427 1.686a3 3 0 0 1-3.82 4.516l-1.354 1.6c.86.497 1.819.819 2.88.819 2.121 0 3.834-1.287 5.161-2.685A12.666 12.666 0 0 0 14.857 8a12.691 12.691 0 0 0-1.697-2.315c-.35-.37-.727-.73-1.132-1.063l-.308-.243ZM8 2a6.428 6.428 0 0 1 2.242.412l.305.123-.681.805A5.359 5.359 0 0 0 8 3C5.877 3 4.164 4.287 2.837 5.685A12.664 12.664 0 0 0 1.14 8a12.66 12.66 0 0 0 1.697 2.315l.301.308.311.299-.646.765A14.567 14.567 0 0 1 2.109 11 13.791 13.791 0 0 1 0 8a13.801 13.801 0 0 1 2.109-3C3.49 3.543 5.454 2 8 2Zm1.633 4.845-2.5 2.956a1.999 1.999 0 0 0 2.5-2.956Zm-3.917-.793a3 3 0 0 1 2.692-1.025l.202.035-.809.948A2 2 0 0 0 6 7.967l.003.152-.808.947a3 3 0 0 1 .521-3.014Z"}))),SR=()=>q.createElement(hw,{viewBox:"0 0 16 16"},q.createElement("path",{d:"M12 4H6V3h6v1ZM6 8.5h4v-1H6v1Zm9 4.5H6v-1h9v1ZM3 11a1 1 0 0 1 1 1v1a1 1 0 0 1-1 1H2a1 1 0 0 1-1-1v-1a1 1 0 0 1 1-1h1Zm0 1H2v1h1v-1Zm0-5.5a1 1 0 0 1 1 1v1a1 1 0 0 1-1 1H2a1 1 0 0 1-1-1v-1a1 1 0 0 1 1-1h1Zm0 1H2v1h1v-1ZM3 2a1 1 0 0 1 1 1v1a1 1 0 0 1-1 1H2a1 1 0 0 1-1-1V3a1 1 0 0 1 1-1h1Zm0 1H2v1h1V3Z"})),wR=wl(wS)({width:28,overflow:"hidden"}),CR=wl(wS)({height:28,width:"100%",overflow:"hidden",alignItems:"center","&::before":{visibility:"hidden"}}),kR=(e,t)=>e.find((e=>e.childRefId===t)),RR=(e,t)=>!t.edit&&0===e.condition,_R=e=>{var t;const{objects:n,defaultTabId:r,cachedTabId:o}=e;return o||(r&&n.some((e=>e.childRefId===r))?r:(null===(t=n[0])||void 0===t?void 0:t.childRefId)||"")};class TR{constructor({modifiedLayout:e,themeService:t}){r(this,"modifiedLayout",void 0),r(this,"themeStyle",void 0),r(this,"style",void 0),r(this,"objectMap",void 0),r(this,"activeTabId",void 0),r(this,"theme",void 0),r(this,"getTabsWidth",(e=>{const t=this.resolveComponentStyle({compPath:"width.value",themePath:"tabWidth.value"});if(void 0===t||2!==t.length||e!==this.modifiedLayout.orientation)return{};const n=this.resolveComponentStyle({compPath:"width.unit",themePath:"tabWidth.unit",defaultValue:"%"});return{minWidth:`${t[0]}${n}`,maxWidth:`${t[1]}${n}`}})),r(this,"getTabWidth",(e=>{var t;const n=null==e?void 0:e.value,r=null!==(t=null==e?void 0:e.unit)&&void 0!==t?t:"%";if(void 0===n||2!==n.length||"left"===this.modifiedLayout.orientation)return{};return{minWidth:`${n[0]}${r}`,maxWidth:`${n[1]}${r}`}})),r(this,"getColorStyle",((e,t=e)=>{const n=this.resolveComponentStyle({compPath:e,themePath:t}),r=vR.getColor({style:n,theme:this.theme});return null!=r?r:n})),r(this,"getTabBackgroundStyle",((e,t)=>{let n;if(this.activeTabId===e){const e=this.resolveComponentStyle({compPath:"background.selected",themePath:""});n=vR.getColor({style:e,theme:this.theme})}return null!=n?n:vR.getColor({style:t,theme:this.theme})})),r(this,"createTabClasses",(()=>{var e;return null===(e=this.modifiedLayout.objects)||void 0===e?void 0:e.reduce(((e,t)=>{var n;const r=null==t?void 0:t.childRefId,o=null==t||null===(n=t.components)||void 0===n?void 0:n.find((e=>"tab"===e.key));return e[`#tab-${this.modifiedLayout.qInfo.qId}-${r}`]={textAlign:XC(o,"label.alignment"),backgroundColor:this.getTabBackgroundStyle(r,null==o?void 0:o.background),...this.getTabWidth(null==o?void 0:o.width)},e[`#tab-${this.modifiedLayout.qInfo.qId}-${r}:hover`]={..."left"===this.modifiedLayout.orientation&&{backgroundColor:this.getColorStyle("background.hover","background.hover.color")}},e[`#tab-label-${this.modifiedLayout.qInfo.qId}-${r}`]={fontSize:XC(o,"label.fontSize"),fontFamily:XC(o,"label.fontFamily"),color:vR.getColor({style:XC(o,"label.color"),theme:this.theme})},e[`#tab-icon-${this.modifiedLayout.qInfo.qId}-${r} svg`]={height:XC(o,"icon.size"),color:vR.getColor({style:XC(o,"icon.color"),theme:this.theme})},e}),{})})),r(this,"createTabsClasses",(()=>({[nR.TABS_LABEL]:{fontSize:this.resolveComponentStyle({compPath:"label.fontSize",themePath:"label.value.fontSize"}),fontFamily:this.resolveComponentStyle({compPath:"label.fontFamily",themePath:"label.value.fontFamily"}),color:this.resolveComponentStyle({compPath:"label.color.color",themePath:"label.value.color"})},[nR.TABS_ICON]:{height:this.resolveComponentStyle({compPath:"icon.size",themePath:"icon.value.fontSize"}),color:this.getColorStyle("icon.color","icon.value.color")},[nR.TABS]:{textAlign:this.resolveComponentStyle({compPath:"label.alignment",themePath:"label.textAlignment"}),...this.getTabsWidth("top")},[nR.TABS_HOVER]:{..."top"===this.modifiedLayout.orientation&&{borderBottomColor:this.getColorStyle("indicator.hover","indicator.hover.color")}},[nR.TABS_WRAPPER]:{...this.getTabsWidth("left"),backgroundColor:this.getColorStyle("background.unselected","")},[nR.TAB_INDICATOR]:{backgroundColor:this.getColorStyle("indicator.selected","indicator.selected.color")}}))),r(this,"createStyleClasses",(()=>({...this.createTabsClasses(),...this.createTabClasses()}))),r(this,"resolveComponentStyle",(({key:e="tabs",compPath:t,themePath:n=t,defaultValue:r})=>{var o,i,a;const l=null===(o=this.modifiedLayout.components)||void 0===o?void 0:o.find((t=>t.key===e));return null!==(i=null!==(a=XC(l,t))&&void 0!==a?a:XC(this.themeStyle,n))&&void 0!==i?i:r})),this.modifiedLayout=e,this.activeTabId=_R(this.modifiedLayout),this.themeStyle=t.getStyles(),this.theme=t.getTheme(),this.objectMap=Cw(this.modifiedLayout),this.style=this.createStyleClasses()}getStyleClasses(){return this.style}getTabStyle(e){var t;return null===(t=this.objectMap[e].components)||void 0===t?void 0:t.find((e=>"tab"===e.key))}}const LR=()=>{const t=e.useElement(),n=e.useApp(),r=e.useStaleLayout(),o=e.useEmbed(),i=e.useModel(),a=e.useTranslator(),l=e.useOptions(),s=e.useEmitter(),u=e.useInteractionState(),c=function(e){var t=e.theme,n=e.config,r=void 0===n?{}:n,o=r.id,i=r.resolve,a=void 0===i?[]:i,l=r.transform,s=void 0===l?[]:l,u=r.extend,c=void 0===u?[]:u,d={theme:t,matrix:fk(a),styles:void 0};return d.styles=mk({theme:t,id:o,transform:s,extend:c,matrix:d.matrix}),{getStyles:function(){return d.styles},getTheme:function(){return d.theme},setTheme:function(e){d.theme=e,d.styles=mk({theme:e,id:o,transform:s,extend:c,matrix:d.matrix})}}}({theme:e.useTheme(),config:{id:"tabbedContainer",resolve:[["object.tabbedContainer","indicator.selected","color"],["object.tabbedContainer","indicator.hover","color"],["object.tabbedContainer","background.hover","color"],["object.tabbedContainer","icon.value","color"],["object.tabbedContainer","icon.value","fontSize"]]}}),d=e.useMemo((()=>new ew(o,a)),[o,a]),[p]=e.useState((()=>new pR(i.id))),[f,h]=e.useState(!1),m=e.useMemo((()=>o&&i&&n?new dR({embed:o,model:i,app:n,translator:a,mutex:p}):void 0),[o,i,n,a,p]),g=e.useMemo((()=>Sw(r)),[r]),b=e.useMemo((()=>new TR({modifiedLayout:g,themeService:c})),[g,c]);return e.useMemo((()=>({app:n,modifiedLayout:g,embed:o,model:i,emitter:s,interactions:u,dataHandler:m,chartList:d,styleModel:b,mutex:p,options:l,accessibility:f,setAccessibility:h,translator:a,element:t})),[g,o,i,n,s,u,m,d,b,p,l,f,a,t])},PR=({dataHandler:e,modifiedLayout:t,translator:n,sharedContainerUtilities:r,Icon:o})=>{const[i,a]=Y.useState(void 0);if(!e||!t)return null;const l=!t.qExtendsId;return q.createElement(lw,null,q.createElement(aw,null,q.createElement(o,null),l?q.createElement(q.Fragment,null,q.createElement(pw,{sx:{width:250,height:32,fontFamily:"inherit"},className:"init-button",variant:i?"contained":"outlined",onClick:e=>{a(e.currentTarget)},"aria-label":n.get("LayoutContainer.EmptyList.AddContent"),disableRipple:!0},n.get("LayoutContainer.EmptyList.AddContent")),q.createElement(bw,{translator:n,anchorEl:i,dataHandler:e,onClose:()=>{a(void 0)},sharedContainerUtilities:r})):q.createElement(Hy,{variant:"inherit"},n.get("LayoutContainer.EmptyList.EmptyHint"))))};class AR{constructor(e){r(this,"_rendered",new Set),r(this,"_objectMap",new Map),r(this,"_objectApis",new Map),r(this,"_resolver",void 0),r(this,"_dependencyData",void 0),r(this,"_recreateMap",new Map),r(this,"createTimerForRendering",(()=>{if(!this.resolver){let e;const t=setTimeout((()=>{this.doResolve()}),9e4),n=new Promise((t=>{e=t}));this._resolver={promise:n,resolve:e,timer:t}}return this._resolver})),r(this,"doResolve",(()=>{var e,t,n;this.resolver&&(clearTimeout(null===(e=this.resolver)||void 0===e?void 0:e.timer),null===(t=(n=this.resolver).resolve)||void 0===t||t.call(n,!0),this._resolver=void 0)})),r(this,"tryToResolve",(()=>{const{visibleLayoutObjects:e}=this._dependencyData;if(this.resolver){(0===e.length||e.every((e=>this.rendered.has(e.id))))&&this.doResolve()}})),this._dependencyData=e}set dependencyData(e){this._dependencyData=e}get rendered(){return this._rendered}get objectMap(){return this._objectMap}get objectApis(){return this._objectApis}get resolver(){return this._resolver}get recreateMap(){return this._recreateMap}syncObjects(e){const t=new Set,n=new Set([...Array.from(this.objectMap.keys()),...Array.from(this.objectApis.keys()),...this.rendered]),r=new Set(n);let o=!1;return e.forEach((e=>{n.has(e.id)?(this.rendered.has(e.id)&&t.add(e.id),r.delete(e.id)):o=!0})),r.forEach((e=>{var t;const n=this.objectMap.get(e);var r;n&&(this.confirmPotentialSelections(n),null===(r=n.destroy)||void 0===r||r.call(n),this.objectMap.delete(e));null===(t=this.objectApis.get(e))||void 0===t||t.destroy(),this.objectApis.delete(e)})),this._rendered=t,this.tryToResolve(),o}destroy(){for(const e of this.objectApis.values())e.destroy();this._objectMap=new Map,this._objectApis=new Map}saveObject(e,t){this.objectMap.set(e,t)}saveObjectApi(e,t){this._objectApis.set(e,t)}onRendered(e){this.rendered.add(e),this.tryToResolve()}getChildrenObjects(){const{visibleLayoutObjects:e}=this._dependencyData,t=[];return e.forEach((e=>{const n=this.objectMap.get(e.id);n&&t.push(n)})),t}getChildLayout(e){const{modifiedLayout:t}=this._dependencyData;return t.qChildList.qItems.find((t=>t.qInfo.qId===e))}getObjectOptions(e){var t,n;const{viewState:r,modifiedLayout:o,options:i}=this._dependencyData,{chartAnimations:a,direction:l,progressiveRendering:s,freeResize:u,navigation:c}=i;return{isReadonly:!1,setController:t=>{this.saveObject(e,t)},onRendered:()=>{this.onRendered(e)},onInitialRender:()=>{this.onRendered(e)},isParentMaster:!(null==o||!o.qExtendsId),isSnapshot:!!o.snapshotData,...!(null==r||null===(t=r.viewStates)||void 0===t||!t[e])&&{viewState:null==r?void 0:r.viewStates[e]},...!(null==r||null===(n=r.layouts)||void 0===n||!n[e])&&{layout:r.layouts[e]},direction:l,chartAnimations:a,progressiveRendering:s,freeResize:u,navigation:c,disableThemeBorder:!1,fallbackToClient:i.fallbackToClient}}confirmPotentialSelections(e){e&&"selectionsApi"in e&&e.selectionsApi.active&&e.selectionsApi.confirm()}}const IR=({chartObject:e,embed:t,renderHelper:n,direction:r,interactions:o,env:i})=>{const a=Y.useRef(null),{id:l}=e;Y.useEffect((()=>{if(l&&a.current){const e=n.getObjectOptions(l)||{};e.disableThemeBorder=!0,t.render({id:l,element:a.current,options:e}).then((e=>{n.saveObjectApi(l,e)})).catch((e=>{var t;const r=null===(t=n.getChildLayout(l))||void 0===t||null===(t=t.qInfo)||void 0===t?void 0:t.qType;console.error("Could not render chart with id",l,r,e)}))}}),[l,t,n,r]);const s=Y.useMemo((()=>()=>{if(null!=e&&e.id&&i.anything){const t=null==e?void 0:e.label,{sense:r}=i.anything,o="current",a=n.objectMap.get(e.id);a&&r.propertyPanel.show({model:a.model,parent:o,headerLabel:t,keepCurrentActiveCell:!0})}}),[i,e,n]);return Y.useEffect((()=>{const e=null==a?void 0:a.current;return e&&null!=o&&o.edit&&e.addEventListener("dblclick",s),()=>{null==e||e.removeEventListener("dblclick",s)}}),[a,s,o]),q.createElement("div",{ref:a,style:{position:"relative",height:"100%",width:"100%"},"data-testid":`tab-panel-${e.childRefId}`})};var OR;!function(e){e.TABS_HEIGHT="36px"}(OR||(OR={}));const MR=({charts:e,handleChangeTab:t,activeTabId:n,element:r,translator:o,accessibility:i,disabled:a})=>{const[l,s]=q.useState(null),u=Boolean(l),c=()=>{s(null)},d=Y.useCallback((e=>{null==e||e.focus()}),[]);return q.createElement(q.Fragment,null,q.createElement(kx,{onClick:e=>{s(e.currentTarget)},disabled:a,"aria-haspopup":"menu","data-testid":"chartTabMenuDropdownButton",tabIndex:i?0:-1,"aria-label":o.get("Container.Label.Visualizations"),className:tR.TAB_MENU,sx:{m:"2px"}},q.createElement(SR,null)),q.createElement(rS,{anchorEl:l,open:u,onClose:c,elevation:0,anchorOrigin:{vertical:"bottom",horizontal:"left"},transformOrigin:{vertical:"top",horizontal:"left"},MenuListProps:{sx:{py:0}},slotProps:{paper:{sx:{maxHeight:"500px",maxWidth:"500px"}}}},e.map((e=>q.createElement(sS,{className:tR.TAB_MENU_ITEM,ref:n===e.childRefId&&u?d:null,key:`chartTabMenu-${e.childRefId}`,onClick:()=>{(e=>{t(e.childRefId),c(),window.setTimeout((()=>{var e;null===(e=r.getElementsByClassName(tR.ACTIVE_TAB_PANEL))||void 0===e||null===(e=e[0])||void 0===e||e.focus()}),0)})(e)},sx:{...n===e.childRefId?{backgroundColor:"rgba(0, 0, 0, 0.1)"}:{}},"aria-label":e.label,title:e.label},q.createElement(Hy,{variant:"inherit",noWrap:!0},e.label))))))},NR=({label:e,id:t})=>q.createElement(mx,{className:tR.TAB_LABEL,id:`tab-label-${t}`,sx:{width:"100%",height:"100%",display:"flex",alignItems:"center",overflow:"hidden",flexWrap:"wrap"}},q.createElement("span",{style:{width:"100%",overflowWrap:"break-word",hyphens:"auto",fontWeight:"bold",display:"-webkit-box",WebkitLineClamp:3,WebkitBoxOrient:"vertical",lineHeight:"normal",overflow:"hidden"}},e)),zR=({libraryInfo:e,chart:t,iconPosition:n,id:r})=>{let o;switch(n){case"bottom":o={marginTop:"6px"};break;case"top":o={marginBottom:"6px"};break;case"end":o={marginInlineStart:"8px"};break;default:o={marginInlineEnd:"8px"}}o.display="flex",o.alignItems="center",o.height="100%",o.flex="1 0 0";return 0===t.condition?q.createElement(ER,{id:`${tR.TABS_ICON}-${r}`,style:o}):e?q.createElement(xR,{id:`${tR.TABS_ICON}-${r}`,libraryInfo:e,style:o}):null},jR=({models:e,activeTabId:t,handleChangeTab:n})=>{const{modifiedLayout:r,chartList:o,interactions:i,accessibility:a}=e,l=null==o?void 0:o.getCharts(),s=r.objects.filter((e=>!RR(e,i))),{orientation:u,tabContainerStyle:c,ScrollButtonComponent:d}=(({orientation:e})=>"left"===e?{orientation:"vertical",tabContainerStyle:{display:"flex",flexDirection:"column",alignItems:"center",maxWidth:"25%",flexShrink:0},ScrollButtonComponent:CR}:{orientation:"horizontal",tabContainerStyle:{display:"flex",flexDirection:"row",alignItems:"center"},ScrollButtonComponent:wR})(r),p=!1===i.active&&!i.edit,[f,h]=Y.useState(!1),m=Y.useCallback((e=>{if(e){const t=e.getElementsByClassName("MuiTabs-flexContainer")[0];if(t)return void h("vertical"===u?t.scrollHeight>t.offsetHeight:t.scrollWidth>t.offsetWidth)}h(!1)}),[u]);return q.createElement(mx,{className:tR.TAB_WRAPPER,sx:c,ref:e=>{m(e)}},r.useDropdown&&f&&q.createElement(MR,{charts:s,handleChangeTab:n,activeTabId:t,accessibility:a,translator:e.translator,element:e.element,disabled:p}),q.createElement(zS,{value:t,onChange:(e,t)=>{n(t)},ScrollButtonComponent:d,variant:"scrollable",orientation:u,scrollButtons:!!r.useScrollButton&&"auto",TabScrollButtonProps:{...p&&{disabled:!0}},sx:{height:"100%",width:"100%",minHeight:OR.TABS_HEIGHT}},s.map((n=>{var o,i,s,c,d;const f=null===(o=Ew(r,n.childRefId))||void 0===o||null===(o=o.qData)||void 0===o?void 0:o.visualization,h=f&&(null==l||null===(i=l[f])||void 0===i?void 0:i.libraryInfo),m=e.styleModel.getTabStyle(n.childRefId),g=0===n.condition||r.showIcons&&h&&!1!==(null==m||null===(s=m.icon)||void 0===s?void 0:s.show),b="vertical"===u?"top":"start",v=e.styleModel.resolveComponentStyle({compPath:"icon.position",defaultValue:b}),y=e.styleModel.resolveComponentStyle({compPath:"label.show"}),x=n.label&&(null!==(c=null==m||null===(d=m.label)||void 0===d?void 0:d.show)&&void 0!==c?c:!1!==y),E=`${r.qInfo.qId}-${n.childRefId}`;return q.createElement(fS,{className:`${tR.TAB} ${t===n.childRefId?tR.ACTIVE_TAB:""}`,disabled:p,id:`tab-${E}`,value:n.childRefId,title:n.label,label:x?q.createElement(NR,{label:n.label,id:E}):void 0,icon:g?q.createElement(zR,{libraryInfo:h,chart:n,iconPosition:v,id:E}):"",iconPosition:v,key:n.childRefId,"data-testid":`container-tab-${n.childRefId}`,sx:{textAlign:"vertical"!==u||r.showIcons?"center":"start",minWidth:"vertical"===u?"100%":void 0,minHeight:OR.TABS_HEIGHT,padding:"6px 16px","&:hover":{paddingBottom:"4px"},"&.Mui-disabled":{opacity:"inherit"}},"aria-label":n.label,"aria-controls":`tab-panel-${E}`,tabIndex:a&&t===n.childRefId?0:-1})}))))},$R=({models:e,renderHelper:t,activeTabId:n,handleChangeTab:r,env:o})=>{const{modifiedLayout:i,embed:a,interactions:l,options:s,styleModel:u,accessibility:c}=e,d=i.objects,p=l.edit||!!d.find((e=>0!==e.condition)),f=i.showTabs&&p,h="left"===i.orientation?"row":"column",m=u.getStyleClasses();return q.createElement(mx,{sx:{display:"flex",flexDirection:h,height:"100%",width:"100%",direction:s.direction,...m}},f&&q.createElement(jR,{models:e,activeTabId:n,handleChangeTab:r}),d.map((e=>{const r=`tab-panel-${i.qInfo.qId}-${e.childRefId}`,u=n===e.childRefId&&!RR(e,l);return q.createElement(mx,{role:"tabpanel",id:r,key:r,"aria-label":e.label,sx:{height:"100%",width:"100%",padding:"2px",boxSizing:"border-box",direction:"ltr",flex:"1 0 0","&:focus-visible":{boxShadow:"inset 0 0 0 2px #0275D9",borderRadius:"3px",zIndex:1200}},...u?{className:tR.ACTIVE_TAB_PANEL,tabIndex:c?0:-1}:{hidden:!0}},u&&q.createElement(IR,{chartObject:e,renderHelper:t,direction:s.direction,embed:a,interactions:l,env:o}))})))};let DR=function(e){return e.COPY="copy",e.PASTE="paste",e.RESET_COPY_BUFFER="resetCopyBuffer",e}({}),BR=function(e){return e.COPY="copy",e.PASTE="paste-and-replace",e.DUPLICATE="duplicate",e.DELETE="delete",e.CUT="cut",e.EDIT_PROPERTIES="edit",e.ZOOM_IN="zoom-in",e.VISUAL_EXPLORATION="visual-exploration",e.MONITOR_IN_HUB="addto",e.TAKE_SNAP_SHOT="take-snapshot",e.SNAP_SHOT_GROUP="snapshotGroup",e.REORDER_LAYERS_GROUP="reorder-layers-group",e.BRING_TO_FRONT="bring-to-front",e.BRING_FORWARD="bring-forward",e.SEND_TO_BACK="send-to-back",e.SEND_BACKWARDS="send-backwards",e.CONTAINER_HEADER="container-header",e.CHART_HEADER="chart-header",e.ALERT_GROUP="alertGroup",e.ADD_TO_MASTER_ITEMS="add-to-master-items",e.UNLINK_VISUALIZATION="unlink",e.DEVELOPER="object-developer",e.SHOW_DETAILS="object-info",e.EXPLAIN_KEY_DRIVERS_OLD_ID="explainKeyDrivers",e.EXPLAIN_KEY_DRIVERS="key-driver",e.SUBSCRIBE="subscribe",e.NOTES_GROUP="notesGroup",e.DOWNLOAD="download",e.SHARE_IMAGE="share",e}({});const FR=[BR.PASTE,BR.ZOOM_IN,BR.VISUAL_EXPLORATION],HR=[BR.VISUAL_EXPLORATION,BR.ALERT_GROUP,BR.SHOW_DETAILS,BR.EXPLAIN_KEY_DRIVERS,BR.EXPLAIN_KEY_DRIVERS_OLD_ID],UR=[BR.DELETE,BR.CUT,BR.ADD_TO_MASTER_ITEMS,BR.UNLINK_VISUALIZATION],VR=[BR.PASTE],GR=(e,t)=>{const{childRefId:n}=e.model.layout,r=t.objects.find((e=>e.childRefId===n));return{...e,additionalData:{label:null==r?void 0:r.label}}},WR=(e,t,n,r,o)=>{const i=t.getSupportFunction(BR.COPY);if(!i)return void e.deleteItem(BR.COPY);const a=()=>{i(GR(n,r)).catch((()=>{}))},l=e.items.find((e=>e.id===BR.COPY));if(l)l.updateItem({select:a});else if(o){const t=e.items.findIndex((e=>e.id===BR.CUT)),n=t>=0?1+t:void 0;e.addItem({translation:"contextMenu.copy",tid:BR.COPY,id:BR.COPY,icon:"copy",select:a,items:[]},n)}},YR=e=>e.interactions.edit&&!e.modifiedLayout.qExtendsId,qR=async(e,t,n,r)=>{const o=t.getBuilder("default");if(!o)return;const i=await o();i.addItem({translation:"contextMenu.containerOptionsHeader",tid:BR.CONTAINER_HEADER,id:BR.CONTAINER_HEADER,bold:!0,items:[]},0);const a=YR(n);i.items.forEach((e=>{(HR.includes(e.id)||!a&&VR.includes(e.id))&&i.deleteItem(e.id)})),a&&await(async(e,t,n)=>{var r;const o=t.getSupportFunction(DR.PASTE),i=await(null==o||null===(r=o())||void 0===r?void 0:r.catch((()=>{})));if(!i||JS.includes(i.template))return void e.deleteItem(BR.PASTE);const a=()=>{n()},l=e.items.find((e=>e.id===BR.PASTE));if(l)l.updateItem({translation:"contextMenu.paste",select:a});else{const t=e.items.findLastIndex((e=>e.id===BR.COPY||e.id===BR.DEVELOPER||e.id===BR.CONTAINER_HEADER)),n=t>=0?1+t:void 0;e.addItem({translation:"contextMenu.paste",tid:BR.PASTE,id:BR.PASTE,icon:"paste",select:a,items:[]},n)}})(i,t,r),e.updateItem({items:i.items}),1===e.items.length&&e.deleteItem(BR.CONTAINER_HEADER)},KR=e=>{const t={[BR.MONITOR_IN_HUB]:!0,[BR.SUBSCRIBE]:!0,[BR.NOTES_GROUP]:!0,[BR.DOWNLOAD]:!0,[BR.SHARE_IMAGE]:!0};e.items.forEach((n=>{t[n.id]?e.deleteItem(n.id):n.items&&KR(n)}))},XR=(e,t,n,r,o,i)=>a=>{const{dataHandler:l,modifiedLayout:s}=r;if(YR(r)){n.isInvalid||(((e,t,n,r)=>{const{model:o,modifiedLayout:i}=n,a=e.items.findLastIndex((e=>e.id===BR.CHART_HEADER||e.id===BR.REORDER_LAYERS_GROUP)),l=a>=0?1+a:void 0;e.addItem({translation:"Object.Container.Props.EditProperties",tid:BR.EDIT_PROPERTIES,id:BR.EDIT_PROPERTIES,icon:BR.EDIT_PROPERTIES,items:[],select:()=>{const{childRefId:e}=t.model.layout,n=i.objects.find((t=>t.childRefId===e)),a=null==n?void 0:n.label,{sense:l}=r.anything,s=o;l.propertyPanel.show({model:t.model,parent:s,headerLabel:a})}},l)})(a,n,r,o),((e,t,n,r,o,i)=>{const a=r.getSupportFunction(BR.COPY);if(!a)return void e.deleteItem(BR.CUT);const l=()=>{o&&a(GR(n,i)).then((async()=>{await(null==o?void 0:o.deleteChildren([t]))})).catch((()=>{}))},s=e.items.find((e=>e.id===BR.CUT));if(s)s.updateItem({select:l});else{const t=e.items.findLastIndex((e=>e.id===BR.ADD_TO_MASTER_ITEMS||e.id===BR.UNLINK_VISUALIZATION||e.id===BR.EDIT_PROPERTIES||e.id===BR.REORDER_LAYERS_GROUP||e.id===BR.DEVELOPER)),n=t>=0?1+t:void 0;e.addItem({translation:"contextMenu.cut",tid:BR.CUT,id:BR.CUT,icon:"cut",select:l,items:[]},n)}})(a,t,n,e,l,s),WR(a,e,n,s,!0),((e,t,n,r,o)=>{const i=t.getSupportFunction(DR.COPY),a=t.getSupportFunction(DR.PASTE);if(!i||!a)return void e.deleteItem(BR.DUPLICATE);const l=()=>{i(GR(n,r)).then((()=>{o()})).catch((()=>{}))},s=e.items.find((e=>e.id===BR.DUPLICATE));if(s)s.updateItem({select:l});else{const t=e.items.findIndex((e=>e.id===BR.COPY)),n=t>=0?1+t:void 0;e.addItem({translation:"Common.Duplicate",tid:BR.DUPLICATE,id:BR.DUPLICATE,icon:BR.DUPLICATE,items:[],select:l},n)}})(a,e,n,s,i)),((e,t,n)=>{const r=()=>{n&&n.deleteChildren([t]).catch((()=>{}))},o=e.items.find((e=>e.id===BR.DELETE));if(o)o.updateItem({select:r});else{const t=e.items.findLastIndex((e=>e.id===BR.DUPLICATE||e.id===BR.ADD_TO_MASTER_ITEMS||e.id===BR.UNLINK_VISUALIZATION||e.id===BR.REORDER_LAYERS_GROUP||e.id===BR.DEVELOPER)),n=t>=0?1+t:void 0;e.addItem({translation:"Common.Delete",tid:BR.DELETE,id:BR.DELETE,icon:"bin",items:[],select:r},n)}})(a,t,l)}else WR(a,e,n,s,!1)},QR=(t,n,r,o)=>{e.onContextMenu((async(e,i,a)=>{var l;if(!a)return!1;const s=((e,t)=>()=>{if(!e)return;const n=t.getSupportFunction(DR.PASTE);n&&n().then((async({template:t,init:n,children:r,additionalData:o})=>{const{label:i}=o,a={label:i};n.qExtendsId?await e.addMasterObjectAsChild({initProps:n,children:r,objectInitProps:a}):await e.addVizAsChild({type:t,initProps:n,children:r,objectInitProps:a})})).catch((e=>{e&&t.getSupportFunction(DR.RESET_COPY_BUFFER)}))})(r.dataHandler,a);if(await qR(e,a,r,s),KR(e),!(e=>{var t;let n;n="qv-radial-contextmenu"===e.type?null===(t=e.touches[0])||void 0===t?void 0:t.target:e.target;return n&&((e,t)=>{let n=e;for(;n;){var r;if(null!==(r=n.classList)&&void 0!==r&&r.contains(t))return n;n=n.parentNode}return null})(n,tR.ACTIVE_TAB_PANEL)})(i))return!0;const u=null===(l=r.modifiedLayout.objects.find((e=>e.childRefId===t)))||void 0===l?void 0:l.id;if(!u)return!0;const c=n.objectMap.get(u);if(!c)return!0;const d=XR(a,t,c,r,o,s),p=await(async(e,t,n,r)=>{const o=YR(n),i=e.getBuilder("object");if(!i)return;const a=await i(t);return a.addItem({translation:"contextMenu.chartOptionsHeader",tid:BR.CHART_HEADER,id:BR.CHART_HEADER,bold:!0,items:[]},0),r(a),a.items.forEach((e=>{(FR.includes(e.id)||!o&&UR.includes(e.id))&&a.deleteItem(e.id)})),1===a.items.length&&a.deleteItem(BR.CHART_HEADER),a})(a,c,r,d);return!p||(e.items.length>0&&p.addItem({translation:"contextMenu.subMenuContainerOptions",tid:"tabbed-container-menu",id:"tabbed-container-menu",icon:"tabbed-container",items:[...e.items]},p.items.length),e.updateItem({items:p.items}),!0)}))},ZR=({element:t,models:n,env:r})=>{const o=((t,n)=>{const[r,o]=e.useState(void 0);return e.useEffect((()=>{if(0===t.getElementsByClassName(n).length){const e=document.createElement("div");e.className=n,t.appendChild(e);const r=tw(e);o(r)}return()=>{null==r||r.unmount()}}),[t,n,r]),r})(t,"init-component"),{options:i,modifiedLayout:a,interactions:l,model:s}=n,{qChildList:u}=a,c=QS(i.direction),d=(t=>{const{viewState:n}=e.useOptions(),{snapshotData:r}=t;if(r){var o;const{layouts:e}=r.objectsData;return{layouts:e,viewStates:null===(o=r.viewState)||void 0===o?void 0:o.viewStates}}if(n){const{viewStates:e}=n;return{viewStates:e}}})(a),p=e.useMemo((()=>_R(a)),[a]),f={modifiedLayout:a,activeTabId:p,env:r},[h,m]=aR(f);m(f);const g=e.useMemo((()=>a.objects.filter((e=>p===e.childRefId))),[p,a.objects]),{renderHelper:b}=(t=>{const{visibleLayoutObjects:n,options:r}=t,[o]=e.useState((()=>new AR(t))),[,i]=e.useState(r);return o.dependencyData=t,e.usePromise((async()=>{var e,t;return i((e=>(e!==r&&n.forEach((e=>o.recreateMap.set(e.id,!0))),r))),o.syncObjects(n)?null===(t=o.createTimerForRendering())||void 0===t?void 0:t.promise:null===(e=o.resolver)||void 0===e?void 0:e.promise}),[n,r]),e.useEffect((()=>()=>{o.destroy()}),[o]),{renderHelper:o}})({modifiedLayout:a,visibleLayoutObjects:g,viewState:d,options:i});QR(p,b,n,r);const[v]=e.useState({current:void 0}),y=e.useMemo((()=>e=>{(async({model:e,patchList:t})=>{if(null!=e&&e.applyPatches){const n=await e.getEffectiveProperties(),r=[];t.forEach((e=>{const{newValue:t,propertyName:o}=e,i=void 0!==n[o]?"Replace":"Add";t?r.push({qPath:`/${o}`,qOp:i,qValue:t&&JSON.stringify(t)}):"Replace"===i&&r.push({qPath:`/${o}`,qOp:"Remove"})})),r.length>0&&await e.applyPatches(r,!0)}})({model:s,patchList:[{newValue:e,propertyName:"cachedTabId"}]})}),[s]),x=e.useMemo((()=>({setSelected:e=>{var t;const n=null===(t=h.modifiedLayout.objects.find((t=>t.id===e[0])))||void 0===t?void 0:t.childRefId;n?y(n):v.current=e[0]}})),[y,h,v]);e.useEffect((()=>{const e=(({chartObjects:e,activeTabId:t})=>{var n;return!kR(e,t)&&e.length>0?null===(n=e[0])||void 0===n?void 0:n.childRefId:t})({chartObjects:h.modifiedLayout.objects,activeTabId:h.activeTabId});if(e!==h.activeTabId)y(e);else if(v.current){var t;const e=null===(t=h.modifiedLayout.objects.find((e=>e.id===v.current)))||void 0===t?void 0:t.childRefId;e&&y(e)}v.current=void 0}),[null==a?void 0:a.objects.length,h,v,y]),e.useEffect((()=>{const e=(({chartObjects:e,activeTabId:t,interactions:n})=>{const r=kR(e,t);if(!r||RR(r,n)){const n=e.find((e=>0!==e.condition));return(null==n?void 0:n.childRefId)||t}return t})({chartObjects:h.modifiedLayout.objects,activeTabId:h.activeTabId,interactions:l});e!==h.activeTabId&&y(e)}),[l,null==a?void 0:a.objects,h,y]);const E=0===u.qItems.length&&l.edit;return e.useEffect((()=>{null==o||o.render(q.createElement(kl,{theme:c},E?q.createElement(PR,{Icon:yR,dataHandler:n.dataHandler,modifiedLayout:n.modifiedLayout,translator:n.translator,sharedContainerUtilities:x}):null,!E&&q.createElement($R,{models:n,renderHelper:b,activeTabId:p,handleChangeTab:y,env:r})))}),[o,n,c,E,b,p,x,y,r]),{renderHelper:b,sharedContainerUtilities:x,activeTabId:p}};var JR={targets:[]};const e_={showTitles:!0,title:"",subtitle:"",footnote:"",disableNavMenu:!0,showDetails:!1,objects:[],qChildListDef:{qData:{visualization:"/visualization",qExtendsId:"/qExtendsId",title:"/title",childRefId:"/childRefId",showCondition:"/showCondition"}},showTabs:!0,useScrollButton:!0,useDropdown:!1,showIcons:!1,components:[],defaultTabId:"",orientation:"top",fontsUsed:[]};!function(e,t){void 0===t&&(t={});var n=t.insertAt;if("undefined"!=typeof document){var r=document.head||document.getElementsByTagName("head")[0],o=document.createElement("style");o.type="text/css","top"===n&&r.firstChild?r.insertBefore(o,r.firstChild):r.appendChild(o),o.styleSheet?o.styleSheet.cssText=e:o.appendChild(document.createTextNode(e))}}(".init-component {\n height: 100%;\n overflow: hidden;\n}\n");const t_=(e,t)=>{let n=!0;const r=t.objects.reduce(((t,r)=>{const o=r.id;if(0!==r.condition){const i=e.get(o);return i&&(e=>e.supportExport())(i)&&(n=!1,t.objectMap.set(o,i)),t.objects.push(r),t}return t}),{objects:[],objectMap:new Map});return n?{objects:[],objectMap:new Map}:r};return function(t){const r=new ZS({translator:t.translator});return{qae:{properties:e_,data:JR},ext:qk({env:t,propertyHandlerData:r}),component(){const o=LR(),i=e.useTranslator();e.useMemo((()=>{!function(e){if(e&&e.get&&e.add){const t="LayoutContainer.EmptyList.AddContent";if(e.get(t)!==t)return;Object.keys(n).forEach((t=>{e.add(n[t])}))}}(i)}),[i]);const{dataHandler:a,model:l,accessibility:s,setAccessibility:u,interactions:c,element:d,modifiedLayout:p}=o,{renderHelper:f,sharedContainerUtilities:h,activeTabId:m}=ZR({element:d,models:o,env:t});(({propertyHandlerData:t,element:n,sharedContainerUtilities:r,translator:o,containerId:i,dataHandler:a,renderHelper:l})=>{const s=e.useOptions();i&&t.sync({containerId:i,element:n,sharedContainerUtilities:r,translator:o,dataHandler:a,renderHelper:l}),e.useEffect((()=>{t.setMuiTheme(s.direction)}),[s.direction,t]),e.useEffect((()=>()=>{i&&t.destroy(i)}),[i,t,s.direction])})({containerId:(null==l?void 0:l.id)||"",element:d,sharedContainerUtilities:h,translator:i,dataHandler:a,propertyHandlerData:r,renderHelper:f});const[g,b]=e.useState(!0);(({isContainerActive:t,activeTabId:n,modifiedLayout:r,renderHelper:o})=>{const i={modifiedLayout:r,activeTabId:n,renderHelper:o,isContainerActive:t},[a,l]=aR(i);l(i);const s=e.useMemo((()=>()=>{const e=ww(a.modifiedLayout);for(const[t,n]of a.renderHelper.objectMap.entries()){const r=a.isContainerActive&&a.activeTabId===e[t];"setIsActive"in n&&n.setIsActive(r)}}),[a]);e.useEffect((()=>{a.isContainerActive&&s()}),[o.objectMap,s,a]),e.useEffect((()=>{s()}),[t,s])})({isContainerActive:g,activeTabId:m,renderHelper:f,modifiedLayout:p}),iR({element:d,accessibility:s,setAccessibility:u,renderHelper:f,interactions:c,env:t,models:o});const{getViewState:v}=Zk(f,t_);e.useImperativeHandle((()=>({getViewState:v,getChildrenObjects:()=>(e=>e.map((e=>{if(e.canReceive){const t=e=>"libraryitem"===e.type&&("field"===e.item.type||"measure"===e.item.type||"dimension"===e.item.type);return{...e,canReceive:n=>t(n)&&e.canReceive(n)}}return e})))(f.getChildrenObjects()),updateActiveState(e){b(e)}})),[])}}}}));
|